Move post-list into a partial; adds a fallback index page
This commit is contained in:
parent
7e667040f6
commit
f310c2671e
|
@ -8,7 +8,7 @@
|
|||
{{content}}
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<section id="contact">
|
||||
<h1>Contact</h1>
|
||||
|
||||
{{@custom.contact_info}}
|
||||
|
|
|
@ -10,30 +10,7 @@ into the {body} of the _default.hbs template --}}
|
|||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<div class="post-feed">
|
||||
{{#foreach posts}}
|
||||
{{!-- Duplicated from ideas.hbs (TODO: use partials) --}}
|
||||
<div class="post-card-content">
|
||||
{{#if featured}}
|
||||
<span class="post-icon">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-text"><path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" x2="8" y1="13" y2="13"></line><line x1="16" x2="8" y1="17" y2="17"></line><line x1="10" x2="8" y1="9" y2="9"></line></svg>
|
||||
</span>
|
||||
{{else}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right-circle"><circle cx="12" cy="12" r="10"></circle><polyline points="12 16 16 12 12 8"></polyline><line x1="8" x2="16" y1="12" y2="12"></line></svg>
|
||||
{{/if}}
|
||||
|
||||
<a class="post-entry-link" href="{{url}}">
|
||||
<span class="post-card-primary-tag">{{title}}</span>
|
||||
</a>
|
||||
|
||||
{{!-- Featured posts actually deserve an excerpt, IMO. --}}
|
||||
{{#if featured}}
|
||||
<div class="post-card-excerpt">{{excerpt}}</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/foreach}}
|
||||
</div>
|
||||
{{> post-list }}
|
||||
|
||||
{{!-- {{pagination}} --}}
|
||||
|
||||
|
|
|
@ -2,35 +2,12 @@
|
|||
|
||||
<section>
|
||||
<h1>Ideas</h1>
|
||||
|
||||
{{{@custom.ideas_flavor_text}}}
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<div class="post-feed">
|
||||
{{#foreach posts}}
|
||||
{{!-- This mirrors the .post-card-content block in index.hbs (the Backrooms) --}}
|
||||
{{!-- We're maintaining both since I don't know how to use partials --}}
|
||||
<div class="post-card-content">
|
||||
{{#if featured}}
|
||||
<span class="post-icon">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-text"><path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" x2="8" y1="13" y2="13"></line><line x1="16" x2="8" y1="17" y2="17"></line><line x1="10" x2="8" y1="9" y2="9"></line></svg>
|
||||
</span>
|
||||
{{else}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right-circle"><circle cx="12" cy="12" r="10"></circle><polyline points="12 16 16 12 12 8"></polyline><line x1="8" x2="16" y1="12" y2="12"></line></svg>
|
||||
{{/if}}
|
||||
|
||||
<a class="post-entry-link" href="{{url}}">
|
||||
<span class="post-card-primary-tag">{{title}}</span>
|
||||
</a>
|
||||
|
||||
{{!-- Featured posts actually deserve an excerpt, IMO. --}}
|
||||
{{#if featured}}
|
||||
<div class="post-card-excerpt">{{excerpt}}</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/foreach}}
|
||||
</div>
|
||||
{{> post-list }}
|
||||
|
||||
{{!-- {{pagination}} --}}
|
||||
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
This index page is rendered when Ghost attempts to render a feed without a template being specified. In the way I use Ghost, this indicates a misconfiguration unknown to me. Please <a href="/#contact">email me</a> and let me know.
|
|
@ -0,0 +1,24 @@
|
|||
<div class="post-feed">
|
||||
{{#foreach posts}}
|
||||
{{!-- This mirrors the .post-card-content block in index.hbs (the Backrooms) --}}
|
||||
{{!-- We're maintaining both since I don't know how to use partials --}}
|
||||
<div class="post-card-content">
|
||||
{{#if featured}}
|
||||
<span class="post-icon">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-text"><path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" x2="8" y1="13" y2="13"></line><line x1="16" x2="8" y1="17" y2="17"></line><line x1="10" x2="8" y1="9" y2="9"></line></svg>
|
||||
</span>
|
||||
{{else}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right-circle"><circle cx="12" cy="12" r="10"></circle><polyline points="12 16 16 12 12 8"></polyline><line x1="8" x2="16" y1="12" y2="12"></line></svg>
|
||||
{{/if}}
|
||||
|
||||
<a class="post-entry-link" href="{{url}}">
|
||||
<span class="post-card-primary-tag">{{title}}</span>
|
||||
</a>
|
||||
|
||||
{{!-- Featured posts actually deserve an excerpt, IMO. --}}
|
||||
{{#if featured}}
|
||||
<div class="post-card-excerpt">{{excerpt}}</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/foreach}}
|
||||
</div>
|
|
@ -2,24 +2,13 @@
|
|||
|
||||
<section>
|
||||
<h1>Projects</h1>
|
||||
|
||||
{{@custom.projects_flavor_text}}
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<div class="post-feed">
|
||||
{{#foreach posts}}
|
||||
<div class="post-card-content">
|
||||
<a class="post-card-content-link" href="{{url}}">
|
||||
<span class="post-card-primary-tag">{{title}}</span>
|
||||
</a>
|
||||
|
||||
{{#if excerpt}}
|
||||
<div class="post-card-excerpt">{{excerpt}}</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/foreach}}
|
||||
</div>
|
||||
{{> post-list }}
|
||||
|
||||
{{!-- {{pagination}} --}}
|
||||
|
||||
|
|
Loading…
Reference in New Issue