b59893091c
refs https://github.com/TryGhost/Team/issues/332
refs 870a09b109
- The {{@labs.members}} always evaluates to "true" starting with Ghost 4.0 and will be "null" coercing to "false" starting Ghost 5.0
- Enabled all conditionals be default to pass the build in main Ghost repository. These changes should be reviewed - special attentio to the left out RSS feed which was surrounded with {{unless @labs.members}} condition
115 lines
4.4 KiB
Handlebars
115 lines
4.4 KiB
Handlebars
<!DOCTYPE html>
|
|
<html lang="{{@site.lang}}">
|
|
<head>
|
|
|
|
{{!-- Document Settings --}}
|
|
<meta charset="utf-8" />
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
|
|
{{!-- Base Meta --}}
|
|
<title>{{meta_title}}</title>
|
|
<meta name="HandheldFriendly" content="True" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
{{!-- Styles'n'Scripts --}}
|
|
<link rel="stylesheet" type="text/css" href="{{asset "built/screen.css"}}" />
|
|
|
|
{{#if @site.accent_color}}
|
|
<style>
|
|
:root {
|
|
--brand: {{@site.accent_color}};
|
|
}
|
|
</style>
|
|
{{/if}}
|
|
|
|
{{!-- This tag outputs SEO meta+structured data and other important settings --}}
|
|
{{ghost_head}}
|
|
|
|
</head>
|
|
<body class="{{body_class}}">
|
|
|
|
<div class="site-wrapper">
|
|
|
|
{{!-- All the main content gets inserted here, index.hbs, post.hbs, etc --}}
|
|
{{{body}}}
|
|
|
|
{{!-- The footer at the very bottom of the screen --}}
|
|
<footer class="site-footer outer">
|
|
<div class="site-footer-content inner">
|
|
<section class="copyright"><a href="{{@site.url}}">{{@site.title}}</a> © {{date format="YYYY"}}</section>
|
|
<nav class="site-footer-nav">
|
|
<a href="{{@site.url}}">Latest Posts</a>
|
|
{{#if @site.facebook}}<a href="{{facebook_url @site.facebook}}" target="_blank" rel="noopener">Facebook</a>{{/if}}
|
|
{{#if @site.twitter}}<a href="{{twitter_url @site.twitter}}" target="_blank" rel="noopener">Twitter</a>{{/if}}
|
|
<a href="https://ghost.org/" target="_blank" rel="noopener">Ghost</a>
|
|
</nav>
|
|
</div>
|
|
</footer>
|
|
|
|
</div>
|
|
|
|
{{!-- The big email subscribe modal content --}}
|
|
<div class="subscribe-notification subscribe-success-message">
|
|
<a class="subscribe-close-button" href="javascript:;"></a>
|
|
You've successfully subscribed to {{@site.title}}!
|
|
</div>
|
|
<div class="subscribe-notification subscribe-failure-message">
|
|
<a class="subscribe-close-button" href="javascript:;"></a>
|
|
Could not sign up! Invalid sign up link.
|
|
</div>
|
|
|
|
{{!-- jQuery, required for fitvids --}}
|
|
<script
|
|
src="https://code.jquery.com/jquery-3.5.1.min.js"
|
|
integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0="
|
|
crossorigin="anonymous">
|
|
</script>
|
|
{{!-- Fitvids (for responsive video embeds), infinite scroll, floating header, and gallery card support --}}
|
|
<script src="{{asset "built/casper.js"}}"></script>
|
|
|
|
{{!-- Scripts for Members subscription --}}
|
|
<script>
|
|
// Parse the URL parameter
|
|
function getParameterByName(name, url) {
|
|
if (!url) url = window.location.href;
|
|
name = name.replace(/[\[\]]/g, "\\$&");
|
|
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
|
|
results = regex.exec(url);
|
|
if (!results) return null;
|
|
if (!results[2]) return '';
|
|
return decodeURIComponent(results[2].replace(/\+/g, " "));
|
|
}
|
|
|
|
// Give the parameter a variable name
|
|
var action = getParameterByName('action');
|
|
var success = getParameterByName('success');
|
|
|
|
$(document).ready(function () {
|
|
if (action == 'subscribe' && (success === null || success === 'true')) {
|
|
$('body').addClass('subscribe-success');
|
|
}
|
|
|
|
if (action == 'subscribe' && success === 'false') {
|
|
$('body').addClass('subscribe-failure');
|
|
}
|
|
|
|
$('.subscribe-notification .subscribe-close-button').click(function () {
|
|
$('.subscribe-notification').addClass('close');
|
|
});
|
|
|
|
// Reset form on opening subscrion overlay
|
|
$('.subscribe-button').click(function() {
|
|
$('.subscribe-overlay form').removeClass();
|
|
$('.subscribe-email').val('');
|
|
});
|
|
});
|
|
</script>
|
|
|
|
{{!-- The #block helper will pull in data from the #contentFor other template files. In this case, there's some JavaScript which we only want to use in post.hbs, but it needs to be included down here, after jQuery has already loaded. --}}
|
|
{{{block "scripts"}}}
|
|
|
|
{{!-- Ghost outputs important scripts and data with this tag - it should always be the very last thing before the closing body tag --}}
|
|
{{ghost_foot}}
|
|
|
|
</body>
|
|
</html>
|