chore: better attribution in footer, remove commented code

rely on git to compare with upstream instead of comments
This commit is contained in:
dragonwocky 2023-11-09 16:54:37 +11:00
parent 881a2f8faf
commit 246fdb865d
Signed by: dragonwocky
GPG Key ID: 7998D08F7D7BD7A8
9 changed files with 31 additions and 172 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,7 +1,3 @@
{{!--
This template is used for the posts that are marked as pages.
--}}
{{#contentFor "preload"}} {{#contentFor "preload"}}
{{!-- This block preloads specific assets for the post page --}} {{!-- This block preloads specific assets for the post page --}}
<link rel="preload" href="{{asset "css/post.css"}}" as="style" /> <link rel="preload" href="{{asset "css/post.css"}}" as="style" />
@ -52,7 +48,6 @@ into the {body} of the default.hbs template --}}
{{/post}} {{/post}}
</div> </div>
</div> </div>
{{!-- pyv --}}
<div class="l-grid centered"> <div class="l-grid centered">
{{#get "posts" filter="featured:true" include="authors,tags" order="published_at asc" as |featured|}} {{#get "posts" filter="featured:true" include="authors,tags" order="published_at asc" as |featured|}}
{{#if featured}} {{#if featured}}
@ -62,19 +57,6 @@ into the {body} of the default.hbs template --}}
<div class="m-featured-slider__list__item swiper-slide"> <div class="m-featured-slider__list__item swiper-slide">
<article class="m-featured-article {{#unless feature_image}}no-picture{{/unless}}"> <article class="m-featured-article {{#unless feature_image}}no-picture{{/unless}}">
<div class="m-featured-article__picture"> <div class="m-featured-article__picture">
{{!-- {{#if feature_image}}
<style>
#featured-bg-{{id}} {
background-image: url({{img_url feature_image size='l'}});
}
@media(max-width: 768px) {
#featured-bg-{{id}} {
background-image: url({{img_url feature_image size='m'}});
}
}
</style>
<div id="featured-bg-{{id}}"></div>
{{/if}} --}}
{{#if feature_image}} {{#if feature_image}}
<img <img
srcset=" srcset="
@ -130,7 +112,6 @@ into the {body} of the default.hbs template --}}
{{/if}} {{/if}}
{{/get}} {{/get}}
</div> </div>
{{!-- /pyv --}}
</div> </div>
</div> </div>
</article> </article>

View File

@ -1,7 +1,3 @@
{{!--
This template is used for the posts that are marked as pages.
--}}
{{!-- This block preloads specific assets for the post page --}} {{!-- This block preloads specific assets for the post page --}}
{{#contentFor "preload"}} {{#contentFor "preload"}}
<link rel="preload" href="{{asset "css/post.css"}}" as="style" /> <link rel="preload" href="{{asset "css/post.css"}}" as="style" />
@ -39,7 +35,6 @@ into the {body} of the default.hbs template --}}
{{/if}} {{/if}}
{{/if}} {{/if}}
</div> </div>
{{!-- pyv --}}
{{#if @custom.use_wave_separator}} {{#if @custom.use_wave_separator}}
<div class="m-hero__waves"> <div class="m-hero__waves">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120" preserveAspectRatio="none"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120" preserveAspectRatio="none">
@ -61,7 +56,6 @@ into the {body} of the default.hbs template --}}
</div> </div>
</article> </article>
{{/post}} {{/post}}
{{!-- /pyv --}}
</main> </main>
{{!-- The #contentFor helper here will send everything inside it up to the matching #block helper found in default.hbs --}} {{!-- The #contentFor helper here will send everything inside it up to the matching #block helper found in default.hbs --}}

View File

@ -10,7 +10,6 @@ This footer template is shared across all the pages.
</nav> </nav>
{{/if}} {{/if}}
<nav class="m-footer-social"> <nav class="m-footer-social">
{{!-- pyv --}}
{{#if @custom.youtube_url}} {{#if @custom.youtube_url}}
<a href="{{@custom.youtube_url}}" target="_blank" rel="noopener" aria-label="YouTube"> <a href="{{@custom.youtube_url}}" target="_blank" rel="noopener" aria-label="YouTube">
<span class="icon-youtube" aria-hidden="true"></span> <span class="icon-youtube" aria-hidden="true"></span>
@ -21,7 +20,6 @@ This footer template is shared across all the pages.
<span class="icon-instagram" aria-hidden="true"></span> <span class="icon-instagram" aria-hidden="true"></span>
</a> </a>
{{/if}} {{/if}}
{{!-- /pyv --}}
{{#if @site.facebook}} {{#if @site.facebook}}
<a href="{{facebook_url @site.facebook}}" target="_blank" rel="noopener" aria-label="Facebook"> <a href="{{facebook_url @site.facebook}}" target="_blank" rel="noopener" aria-label="Facebook">
<span class="icon-facebook" aria-hidden="true"></span> <span class="icon-facebook" aria-hidden="true"></span>
@ -32,22 +30,18 @@ This footer template is shared across all the pages.
<span class="icon-twitter" aria-hidden="true"></span> <span class="icon-twitter" aria-hidden="true"></span>
</a> </a>
{{/if}} {{/if}}
{{!-- pyv --}}
{{!-- <a href="{{@site.url}}/rss" aria-label="RSS"> {{!-- <a href="{{@site.url}}/rss" aria-label="RSS">
<span class="icon-rss" aria-hidden="true"></span> <span class="icon-rss" aria-hidden="true"></span>
</a> --}} </a> --}}
{{!-- /pyv --}}
</nav> </nav>
<p class="m-footer-copyright"> <p class="m-footer-copyright">
<span>{{@site.title}} &copy; {{date format="YYYY"}}</span> <span>{{@site.title}} &copy; {{date format="YYYY"}}</span><br>
{{!-- pyv --}} <span>{{t "Published with"}} <a href="https://ghost.org" target="_blank" rel="noopener">Ghost</a>
{{!-- <span>{{t "Published with"}} <a href="https://ghost.org" target="_blank" rel="noopener">Ghost</a></span> --}} &amp; <a href="https://github.com/eddiesigner/liebling" target="_blank" rel="noopener">Liebling</a>
{{!-- /pyv --}} &#x2022; {{t "by"}} <a href="https://dragonwocky.me/">Tom Vines</a></span>
</p> </p>
{{!-- pyv --}}
{{!-- <p class="m-footer-copyright jslicense"> {{!-- <p class="m-footer-copyright jslicense">
<a href="{{asset "html/javascript.html"}}" rel="jslicense">{{t "JavaScript license information"}}</a> <a href="{{asset "html/javascript.html"}}" rel="jslicense">{{t "JavaScript license information"}}</a>
</p> --}} </p> --}}
{{!-- /pyv --}}
</div> </div>
</footer> </footer>

View File

@ -53,9 +53,7 @@ This header template is shared across all the pages.
{{navigation}} {{navigation}}
{{/if}} {{/if}}
{{#if @site.secondary_navigation}} {{#if @site.secondary_navigation}}
{{!-- pyv: concatenate primary & secondary nav on mobile --}}
{{navigation type="secondary"}} {{navigation type="secondary"}}
{{!-- /pyv --}}
<li class="more"> <li class="more">
<span> <span>
<a href="javascript:void(0);" class="js-open-secondary-menu"> <a href="javascript:void(0);" class="js-open-secondary-menu">
@ -121,7 +119,6 @@ This header template is shared across all the pages.
</ul> </ul>
</nav> </nav>
<div class="m-nav__right"> <div class="m-nav__right">
{{!-- pyv --}}
{{#if @custom.youtube_url}} {{#if @custom.youtube_url}}
<a href="{{@custom.youtube_url}}" target="_blank" rel="noopener" aria-label="YouTube" <a href="{{@custom.youtube_url}}" target="_blank" rel="noopener" aria-label="YouTube"
class="m-icon-button in-menu-main"> class="m-icon-button in-menu-main">
@ -140,7 +137,6 @@ This header template is shared across all the pages.
<span class="icon-facebook" aria-hidden="true"></span> <span class="icon-facebook" aria-hidden="true"></span>
</a> </a>
{{/if}} {{/if}}
{{!-- /pyv --}}
<button class="m-icon-button in-menu-main {{^if @custom.enable_native_search}}js-open-search{{/if}}" {{#if @custom.enable_native_search}}data-ghost-search{{/if}} aria-label="{{t "Open search"}}"> <button class="m-icon-button in-menu-main {{^if @custom.enable_native_search}}js-open-search{{/if}}" {{#if @custom.enable_native_search}}data-ghost-search{{/if}} aria-label="{{t "Open search"}}">
<span class="icon-search" aria-hidden="true"></span> <span class="icon-search" aria-hidden="true"></span>
</button> </button>

120
post.hbs
View File

@ -48,55 +48,13 @@ into the {body} of the default.hbs template --}}
<header class="m-heading"> <header class="m-heading">
<h1 class="m-heading__title in-post">{{title}}</h1> <h1 class="m-heading__title in-post">{{title}}</h1>
<div class="m-heading__meta"> <div class="m-heading__meta">
{{!-- pyv --}}
{{#if primary_tag}} {{#if primary_tag}}
<span class="m-heading__meta__tag">{{primary_tag.name}}</span> <span class="m-heading__meta__tag">{{primary_tag.name}}</span>
{{!-- <a href="{{primary_tag.url}}" class="m-heading__meta__tag">{{primary_tag.name}}</a> --}}
{{!-- <span class="m-heading__meta__divider" aria-hidden="true">&bull;</span> --}}
{{/if}} {{/if}}
{{!-- <span class="m-heading__meta__time">{{date published_at}}</span> --}}
{{!-- /pyv --}}
</div> </div>
</header> </header>
<div class="pos-relative js-post-content"> <div class="pos-relative js-post-content">
{{!-- pyv --}}
{{!-- <div class="m-share">
<div class="m-share__content js-sticky">
<a href="https://www.facebook.com/sharer/sharer.php?u={{url absolute='true'}}"
class="m-icon-button filled in-share" target="_blank" rel="noopener" aria-label="Facebook">
<span class="icon-facebook" aria-hidden="true"></span>
</a>
<a href="https://twitter.com/intent/tweet?text={{encode title}}&url={{url absolute='true'}}"
class="m-icon-button filled in-share" target="_blank" rel="noopener" aria-label="Twitter">
<span class="icon-twitter" aria-hidden="true"></span>
</a>
<button id="open-share-menu"
class="m-icon-button filled in-share" target="_blank" rel="noopener" aria-label="Share">
<svg aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8" fill="none"/><polyline points="16 6 12 2 8 6" fill="none"/><line x1="12" x2="12" y1="2" y2="15" fill="none"/></svg>
</button>
<button class="m-icon-button filled in-share progress js-scrolltop" aria-label="{{t "Scroll to top"}}">
<span class="icon-arrow-top" aria-hidden="true"></span>
<svg aria-hidden="true">
<circle class="progress-ring__circle js-progress" fill="transparent" r="0" />
</svg>
</button>
</div>
</div> --}}
{{content}} {{content}}
{{!-- List of tags --}}
{{!-- {{#if tags}}
<section class="m-tags in-post">
<h3 class="m-submenu-title">{{t "Tags"}}</h3>
<ul>
{{#foreach tags}}
<li>
<a href="{{url}}" title="{{name}}">{{name}}</a>
</li>
{{/foreach}}
</ul>
</section>
{{/if}} --}}
{{!-- /pyv --}}
</div> </div>
</div> </div>
</div> </div>
@ -118,57 +76,6 @@ into the {body} of the default.hbs template --}}
</div> </div>
</section> </section>
{{/if}} {{/if}}
{{!-- pyv --}}
{{!-- <section class="m-author">
<div class="m-author__content">
<div class="m-author__picture">
<a href="{{primary_author.url}}" class="m-author-picture" aria-label="{{primary_author.name}}">
{{#if primary_author.profile_image}}
<div style="background-image: url({{primary_author.profile_image}});"></div>
{{else}}
<div style="background-image: url({{asset "images/default-avatar-square-small.jpg"}});"></div>
{{/if}}
</a>
</div>
<div class="m-author__info">
<h4 class="m-author__name">
<a href="{{primary_author.url}}">{{primary_author.name}}</a>
</h4>
{{#has author="count:>1"}}
<p class="m-small-text in-author-along-with">
{{authors separator=", " prefix=(t "Among with no break line") from="2"}}
</p>
{{/has}}
{{#if primary_author.bio}}
<p class="m-author__bio">{{primary_author.bio}}</p>
{{/if}}
<ul class="m-author-links">
{{#if primary_author.website}}
<li>
<a href="{{primary_author.website}}" target="_blank" rel="noopener" aria-label="{{t "Website"}}">
<span class="icon-globe" aria-hidden="true"></span>
</a>
</li>
{{/if}}
{{#if primary_author.facebook}}
<li>
<a href="https://facebook.com/{{primary_author.facebook}}" target="_blank" rel="noopener" aria-label="Facebook">
<span class="icon-facebook" aria-hidden="true"></span>
</a>
</li>
{{/if}}
{{#if primary_author.twitter}}
<li>
<a href="https://twitter.com/{{primary_author.twitter}}" target="_blank" rel="noopener" aria-label="Twitter">
<span class="icon-twitter" aria-hidden="true"></span>
</a>
</li>
{{/if}}
</ul>
</div>
</div>
</section> --}}
{{!-- /pyv --}}
{{!-- Native comments --}} {{!-- Native comments --}}
{{#if comments}} {{#if comments}}
<div class="m-comments"> <div class="m-comments">
@ -186,33 +93,6 @@ into the {body} of the default.hbs template --}}
</section> </section>
--}} --}}
{{/post}} {{/post}}
{{!-- Related posts --}}
{{!-- pyv --}}
{{!-- {{#if post.tags.length}}
{{#get "posts" limit="3" filter="tags:[{{post.tags}}]+id:-{{post.id}}" include="tags,authors" order="published_at desc" as |related|}}
{{#if related}}
<section class="m-recommended">
<div class="l-wrapper in-recommended">
<h3 class="m-section-title in-recommended">{{t "Recommended for you"}}</h3>
<div class="m-recommended-articles">
<div class="m-recommended-slider swiper js-recommended-slider">
<div class="swiper-wrapper">
{{> "loop"}}
</div>
<button class="m-icon-button filled in-recommended-articles swiper-button-prev" aria-label="{{t "Previous"}}">
<span class="icon-arrow-left" aria-hidden="true"></span>
</button>
<button class="m-icon-button filled in-recommended-articles swiper-button-next" aria-label="{{t "Next"}}">
<span class="icon-arrow-right" aria-hidden="true"></span>
</button>
</div>
</div>
</div>
</section>
{{/if}}
{{/get}}
{{/if}} --}}
{{!-- /pyv --}}
</div> </div>
</article> </article>
</main> </main>