First cut of myWebLog v3-compatible theme

This commit is contained in:
2026-07-19 16:53:15 -04:00
parent 595bbd3917
commit 4c8109b676
6 changed files with 68 additions and 61 deletions
+8 -7
View File
@@ -4,11 +4,11 @@
<p>{{ subtitle }}</p>
{%- endif %}
{% endif %}
{%- for post in model.posts %}
{%- for post in posts.posts %}
<article class="auto">
<div>
<h1 class="home-title">
<small class="home-lead">{{ post.published_on | date: "dddd, MMMM d, yyyy" }}</small><br>
<small class="home-lead">{{ post.published_on | format_date: "dddd, MMMM d, yyyy" }}</small><br>
&nbsp;
<a href="{{ post | relative_link }}"
id="{{ post.title | strip_html | downcase | replace: " ", "-" | replace: ":", "" }}"
@@ -42,15 +42,16 @@
{%- if logged_on %}<small><a hx-boost="false" href="{{ post | edit_post_link }}">Edit Post</a></small>{% endif %}
</article>
{%- endfor %}
<div class="bottom-nav" role="navigation">
<div class="bottom-nav" role="navigation" hx-boost:inherited=true hx-target:inherited="#content"
hx-swap:inherited="innerHTML show:top showTarget:#top" hx-indicator:inherited="#loadOverlay">
<div class="nav-previous">
{% if model.newer_link -%}
<a href="{{ model.newer_link.value }}">&laquo; Newer Posts</a>
{% if posts.newer_link -%}
<a href="{{ posts.newer_link.value }}">&laquo; Newer Posts</a>
{% endif %}
</div>
<div class="nav-next">
{% if model.older_link -%}
<a href="{{ model.older_link.value }}">Older Posts &raquo;</a>
{% if posts.older_link -%}
<a href="{{ posts.older_link.value }}">Older Posts &raquo;</a>
{% endif %}
</div>
</div>
+2 -2
View File
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html lang="en">
<html lang=en>
<head>
<meta charset="utf-8">
<meta charset=utf-8>
<title>
{%- if is_home -%}
{{ web_log.name }}{% if web_log.subtitle %} | {{ web_log.subtitle.value }}{% endif %}
+29 -29
View File
@@ -1,9 +1,9 @@
<!DOCTYPE html>
<html lang="en">
<html lang=en>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta charset=utf-8>
<meta http-equiv=X-UA-Compatible content="IE=edge">
<meta name=viewport content="width=device-width, initial-scale=1">
<title>
{%- if is_home -%}
{{ web_log.name }}{% if web_log.subtitle %} | {{ web_log.subtitle.value }}{% endif %}
@@ -14,18 +14,18 @@
{% page_head -%}
</head>
<body>
<header class="site-header" id="top">
<div class="header-logo">
<a href="{{ "" | relative_link }}" hx-boost="true" hx-target="#content" hx-swap="innerHTML show:#top:top"
hx-indicator="#loadOverlay">
<header class=site-header id=top>
<div class=header-logo>
<a href="{{ "" | relative_link }}" hx-boost=true hx-target="#content"
hx-swap="innerHTML show:top showTarget:#top" hx-indicator="#loadOverlay">
<img src="{{ "img/bitbadger.png" | theme_asset }}"
alt="A cartoon badger looking at a computer screen, with his paw on a mouse"
title="Bit Badger Solutions">
</a>
</div>
<div class="header-title">
<a href="{{ "" | relative_link }}" hx-boost="true" hx-target="#content" hx-swap="innerHTML show:#top:top"
hx-indicator="#loadOverlay">
<div class=header-title>
<a href="{{ "" | relative_link }}" hx-boost=true hx-target="#content"
hx-swap="innerHTML show:top showTarget:#top" hx-indicator="#loadOverlay">
The Bit Badger Blog
</a>
</div>
@@ -34,54 +34,54 @@
<a href="{{ "feed.xml" | relative_link }}" title="Subscribe to The Bit Badger Blog via RSS">
<img src="{{ "img/rss.png" | theme_asset }}" alt="RSS">
</a> &nbsp; &nbsp;
<a href="https://twitter.com/Bit_Badger" title="Bit_Badger on Twitter">
<a href="https://twitter.com/Bit_Badger" title="Bit_Badger on Twitter" target=_blank>
<img src="{{ "img/twitter.png" | theme_asset }}" alt="Twitter">
</a> &nbsp; &nbsp;
<a href="https://www.facebook.com/bitbadger.solutions" title="Bit Badger Solutions on Facebook">
<a href="https://www.facebook.com/bitbadger.solutions" title="Bit Badger Solutions on Facebook" target=_blank>
<img src="{{ "img/facebook.png" | theme_asset }}" alt="Facebook">
</a>
</div>
</header>
<div class="content-wrapper" hx-boost="true" hx-target="#content" hx-swap="innerHTML show:#top:top"
<div class=content-wrapper hx-boost=true hx-target="#content" hx-swap="innerHTML show:top showTarget:#top"
hx-indicator="#loadOverlay">
<div class="load-overlay" id="loadOverlay">
<div class=load-overlay id=loadOverlay>
<h1>Loading&hellip;</h1>
</div>
<main class="content" id="content" role="main">
<main class=content id=content role=main>
{{ content }}
</main>
<aside class="blog-sidebar">
<aside class=blog-sidebar>
<div>
<div class="sidebar-head">Linux Resources</div>
<div class=sidebar-head>Linux Resources</div>
<ul><li><a href="{{ "linux/" | relative_link }}">Browse Resources</a></li></ul>
</div>
<div>
<div class="sidebar-head">Categories</div>
<ul class="cat-list">
<div class=sidebar-head>Categories</div>
<ul class=cat-list hx-boost:inherited=true hx-target:inherited="#content"
hx-swap:inherited="innerHTML show:top showTarget:#top" hx-indicator:inherited="#loadOverlay">
{% for cat in categories -%}
{%- assign indent = cat.parent_names | size -%}
<li class="cat-list-item"{% if indent > 0 %} style="padding-left:{{ indent }}rem;"{% endif %}>
<a href="{{ cat | category_link }}" class="cat-list-link">{{ cat.name }}</a>
<span class="cat-list-count">{{ cat.post_count }}</span>
<li class=cat-list-item{% if indent > 0 %} style="padding-left:{{ indent }}rem;"{% endif %}>
<a href="{{ cat | category_link }}" class=cat-list-link>{{ cat.name }}</a>
<span class=cat-list-count>{{ cat.post_count }}</span>
</li>
{%- endfor %}
</ul>
</div>
</aside>
</div>
<footer class="site-footer">
<footer class=site-footer>
<span>
A production of
<a href="https://bitbadger.solutions" title="Bit Badger Solutions" target="_blank" rel="noopener"
class="no-wrap">
<a href=https://bitbadger.solutions title="Bit Badger Solutions" target=_blank rel=noopener class=no-wrap>
Bit Badger Solutions
</a>
</span>
<span>
Powered by <a href="https://github.com/bit-badger/myWebLog/tree/v2" target="_blank" rel="noopener">myWebLog</a>
Powered by <a href=https://bitbadger.solutions/open-source/myweblog target=_blank rel=noopener>myWebLog</a>
&bull;
{% if logged_on %}
<a href="{{ "admin" | relative_link }}">Dashboard</a>
{% if is_logged_on %}
<a href="{{ "admin/dashboard" | relative_link }}">Dashboard</a>
{% else %}
<a href="{{ "user/log-on" | relative_link }}">Log On</a>
{%- endif %}
+6 -6
View File
@@ -1,7 +1,7 @@
<article class="auto">
<h1 class="entry-title">{{ page.title }}</h1>
<div class="entry-content">{{ page.text }}</div>
{%- if logged_on %}
<p><small><a hx-boost="false" href="{{ page | edit_page_link }}">Edit Page</a></small></p>
<article class=auto>
<h1 class=entry-title>{{ page.title }}</h1>
<div class=entry-content>{{ page.text }}</div>
{%- if is_logged_on %}
<p><small><a href="{{ page | edit_page_link }}">Edit Page</a></small></p>
{% endif -%}
</article>
</article>
+21 -16
View File
@@ -1,49 +1,52 @@
{%- assign post = model.posts | first -%}
<article class="auto">
<h1 class="entry-title">
<article class=auto>
<h1 class=entry-title>
{{ post.title }}
</h1>
<header class="entry-header">
<header class=entry-header>
<p>
Posted by {{ model.authors | value: post.author_id }} on {{ post.published_on | date: "dddd, MMMM d, yyyy" }}
at {{ post.published_on | date: "h:mm tt" | downcase }}
Posted by {{ model.authors | value: post.author_id }}
on {{ post.published_on | format_date: "dddd, MMMM d, yyyy" }}
at {{ post.published_on | format_date: "h:mm tt" | downcase }}
</p>
{%- assign cat_count = post.category_ids | size -%}
{%- if cat_count > 0 %}
<p>
<p hx-boost:inherited=true hx-target:inherited="#content" hx-swap:inherited="innerHTML show:top showTarget:#top"
hx-indicator:inherited="#loadOverlay">
<small>
Categorized under
{% for cat_id in post.category_ids -%}
{%- assign cat = categories | where: "Id", cat_id | first -%}
<a href="{{ cat | category_link }}" title="Categorized under {{ cat.name | strip_html | escape }}"
rel="tag">{{ cat.name }}</a>{% unless forloop.last %}, {% endunless %}
rel=tag>{{ cat.name }}</a>{% unless forloop.last %}, {% endunless %}
{%- endfor %}
</small>
</p>
{%- endif %}
</header>
<div class="entry-content">{{ post.text }}</div>
<footer class="entry-footer">
<div class=entry-content>{{ post.text }}</div>
<footer class=entry-footer>
{%- assign tag_count = post.tags | size -%}
{%- if tag_count > 0 %}
<p>
<p hx-boost:inherited=true hx-target:inheritied="#content" hx-swap:inherited="innerHTML show:top showTarget:#top"
hx-indicator:inherited="#loadOverlay">
Tagged:
{% for tag in post.tags -%}
<a href="{{ tag | tag_link }}" title="Tagged &ldquo;{{ tag | escape }}&rdquo;"
rel="tag">{{ tag }}</a>{% unless forloop.last %}, {% endunless %}
rel=tag>{{ tag }}</a>{% unless forloop.last %}, {% endunless %}
{%- endfor %}
</p>
{%- endif %}
<p>
Bookmark:
<a href="{{ post | absolute_link }}" rel="bookmark"
<a href="{{ post | absolute_link }}" rel=bookmark
title="Permanent link to &ldquo;{{ post.title | strip_html | escape }}&rdquo;">
the permalink
</a>
</p>
<p>
{%- if logged_on %}
Edit: <a hx-boost="false" href="{{ post | edit_post_link }}">this post</a>
{%- if is_logged_on %}
Edit: <a href="{{ post | edit_post_link }}">this post</a>
{% else %}
&nbsp;
{% endif -%}
@@ -51,13 +54,15 @@
{% if model.newer_link -%}
<p>
Next Newer Post:
<a href="{{ model.newer_link.value | relative_link }}">{{ model.newer_name.value }}</a>
<a href="{{ model.newer_link.value | relative_link }}" hx-boost=true hx-target="#content"
hx-swap="innerHTML show:top showTarget:#top" hx-indicator="#loadOverlay">{{ model.newer_name.value }}</a>
</p>
{% endif %}
{% if model.older_link -%}
<p>
Next Older Post:
<a href="{{ model.older_link.value | relative_link }}">{{ model.older_name.value }}</a>
<a href="{{ model.older_link.value | relative_link }}" hx-boost=true hx-target="#content"
hx-swap="innerHTML show:top showTarget:#top" hx-indicator="#loadOverlay">{{ model.older_name.value }}</a>
</p>
{%- endif -%}
</footer>