diff options
author | EuAndreh <eu@euandre.org> | 2020-02-05 02:17:01 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2020-02-05 02:17:01 -0300 |
commit | de9473df009bdab19ea287af8b18b6c141c2749b (patch) | |
tree | 93dcef5582f070fbc6fdc180427397e72e111160 /_layouts | |
parent | WIP Jekyll (diff) | |
download | euandre.org-de9473df009bdab19ea287af8b18b6c141c2749b.tar.gz euandre.org-de9473df009bdab19ea287af8b18b6c141c2749b.tar.xz |
Reproduce hakyll behaviour
Diffstat (limited to '_layouts')
-rw-r--r-- | _layouts/default.html | 3 | ||||
-rw-r--r-- | _layouts/index.html | 38 | ||||
-rw-r--r-- | _layouts/page.html | 10 | ||||
-rw-r--r-- | _layouts/pastebin.html | 11 | ||||
-rw-r--r-- | _layouts/pastebins.html | 38 | ||||
-rw-r--r-- | _layouts/post.html | 36 |
6 files changed, 42 insertions, 94 deletions
diff --git a/_layouts/default.html b/_layouts/default.html index fc9befd..9fa116e 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -16,7 +16,7 @@ </div> <div id="nav-right"> <a href="/about.html">About</a> - <a href="/feed.atom"> + <a href="/feed.xml"> <img class="simple-icon" src="/images/atom.svg" alt="Blog feed" /> </a> </div> @@ -24,6 +24,7 @@ </header> <main role="main"> + <h1>{{ page.title }}</h1> {{ content }} </main> diff --git a/_layouts/index.html b/_layouts/index.html index 8f8ac79..675d9e0 100644 --- a/_layouts/index.html +++ b/_layouts/index.html @@ -1,34 +1,10 @@ --- layout: default --- - -<div class="home"> - {%- if page.title -%} - <h1 class="page-heading">{{ page.title }}</h1> - {%- endif -%} - - {{ content }} - - {%- if site.posts.size > 0 -%} - <h2 class="post-list-heading">{{ page.list_title | default: "Posts" }}</h2> - <ul class="post-list"> - {%- for post in site.posts -%} - <li> - {%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%} - <span class="post-meta">{{ post.date | date: date_format }}</span> - <h3> - <a class="post-link" href="{{ post.url | relative_url }}"> - {{ post.title | escape }} - </a> - </h3> - {%- if site.show_excerpts -%} - {{ post.excerpt }} - {%- endif -%} - </li> - {%- endfor -%} - </ul> - - <p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | relative_url }}">via RSS</a></p> - {%- endif -%} - -</div> +<ul> + {%- for post in site.posts -%} + <li> + <a href="{{ post.url }}">{{ post.title | escape }}</a> - {{ post.date | date: "%b %-d, %Y" }} + </li> + {%- endfor -%} +</ul> diff --git a/_layouts/page.html b/_layouts/page.html index 01e4b2a..57116c1 100644 --- a/_layouts/page.html +++ b/_layouts/page.html @@ -2,13 +2,5 @@ layout: default --- <article class="post"> - - <header class="post-header"> - <h1 class="post-title">{{ page.title | escape }}</h1> - </header> - - <div class="post-content"> - {{ content }} - </div> - + {{ content }} </article> diff --git a/_layouts/pastebin.html b/_layouts/pastebin.html new file mode 100644 index 0000000..51194d7 --- /dev/null +++ b/_layouts/pastebin.html @@ -0,0 +1,11 @@ +--- +layout: default +--- +<article> + <section class="header"> + Posted on {{ page.date | date: "%b %-d, %Y" }} + </section> + <section> + {{ content }} + </section> +</article> diff --git a/_layouts/pastebins.html b/_layouts/pastebins.html index 0740a04..6b7830c 100644 --- a/_layouts/pastebins.html +++ b/_layouts/pastebins.html @@ -1,34 +1,10 @@ --- layout: default --- - -<div class="home"> - {%- if page.title -%} - <h1 class="page-heading">{{ page.title }}</h1> - {%- endif -%} - - {{ content }} - - {%- if site.posts.size > 0 -%} - <h2 class="post-list-heading">{{ page.list_title | default: "Posts" }}</h2> - <ul class="post-list"> - {%- for post in site.posts -%} - <li> - {%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%} - <span class="post-meta">{{ post.date | date: date_format }}</span> - <h3> - <a class="post-link" href="{{ post.url | relative_url }}"> - {{ post.title | escape }} - </a> - </h3> - {%- if site.show_excerpts -%} - {{ post.excerpt }} - {%- endif -%} - </li> - {%- endfor -%} - </ul> - - <p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | relative_url }}">via RSS</a></p> - {%- endif -%} - -</div> +<ul> + {%- for pastebin in site.pastebins -%} + <li> + <a href="{{ pastebin.url | relative_url }}">{{ pastebin.title | escape }}</a> - {{ pastebin.date | date: "%b %-d, %Y" }} + </li> + {%- endfor -%} +</ul> diff --git a/_layouts/post.html b/_layouts/post.html index abf9696..bdaa3f8 100644 --- a/_layouts/post.html +++ b/_layouts/post.html @@ -1,27 +1,19 @@ --- layout: default --- -<article class="post h-entry" itemscope itemtype="http://schema.org/BlogPosting"> - - <header class="post-header"> - <h1 class="post-title p-name" itemprop="name headline">{{ page.title | escape }}</h1> - <p class="post-meta"> - <time class="dt-published" datetime="{{ page.date | date_to_xmlschema }}" itemprop="datePublished"> - {%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%} - {{ page.date | date: date_format }} - </time> - {%- if page.author -%} - • <span itemprop="author" itemscope itemtype="http://schema.org/Person"><span class="p-author h-card" itemprop="name">{{ page.author }}</span></span> - {%- endif -%}</p> - </header> - - <div class="post-content e-content" itemprop="articleBody"> +<article> + <section class="header"> + Posted on {{ page.date | date: "%b %-d, %Y" }} + </section> + <section> {{ content }} - </div> - - {%- if site.disqus.shortname -%} - {%- include disqus_comments.html -%} - {%- endif -%} - - <a class="u-url" href="{{ page.url | relative_url }}" hidden></a> + </section> + <section> + <p>Have a comment on this post? Start a discussion + in my <a href="https://lists.sr.ht/~euandreh/public-inbox">public inbox</a> + by sending an email to <a href="mailto:~euandreh/public-inbox@lists.sr.ht?Subject=Re%3A%20{{ page.title | escape }}">~euandreh/public-inbox@lists.sr.ht</a> + [<a href="https://man.sr.ht/lists.sr.ht/etiquette.md">mailing list etiquette</a>], + or see <a href="https://lists.sr.ht/~euandreh/public-inbox?search={{ page.title | escape }}">existing discussions</a>. + </p> + </section> </article> |