Refactor MkDocs blog structure, enhance SCSS watcher, and improve plugin configuration (#103)

- Adjusted `mkdocs.sh` to expand SCSS watcher to include `docs` and `mkdocs.yml`.
- Simplified blog template by extracting post logic to `partials/post.html`.
- Updated `mkdocs.yml` with refined plugins including RSS, meta, and enhanced blog options.
- Improved blog Markdown files with structural changes and better TOC handling.
- Removed unused styles and deprecated logic in blog posts for cleaner maintenance.
This commit is contained in:
mw
2025-06-02 16:01:40 +02:00
committed by GitHub
parent 7cf43df29c
commit ee8eba8549
8 changed files with 81 additions and 66 deletions
+2 -5
View File
@@ -31,13 +31,10 @@
</header>
<div class="md-post__content md-typeset">
<h2>
<a href="{{ post.url | replace('blog/', '') | url }}" title="{{ post.config.title }}">{{ post.config.title }}</a>
<a href="{{ post.url | url }}" title="{{ post.config.title }}">{{ post.config.title }}</a>
</h2>
<!-- Wir zeigen nur die Überschrift an, kein Excerpt oder weiterer Inhalt -->
<nav class="md-post__action">
<a href="{{ post.url | replace('blog/', '') | url }}" class="md-button" title="Weiterlesen: {{ post.config.title }}">
<a href="{{ post.url | url }}" class="md-button" title="Weiterlesen: {{ post.config.title }}">
Weiterlesen
</a>
</nav>
+27
View File
@@ -0,0 +1,27 @@
<article class="md-post md-post--excerpt">
<div class="md-post__meta">
<time datetime="{{ post.config.date.created }}">
{{- post.config.date.created | date -}}
</time>
</div>
<h2 class="md-post__title">
<a href="{{ post.url | url }}" title="{{ post.title }}">{{ post.title }}</a>
</h2>
<!-- Post-Excerpt hinzufügen -->
<div class="md-post__excerpt">
{% if post.excerpt %}
{{ post.excerpt }}
{% elif post.content | length > 0 %}
{{ post.content | striptags | truncate(200, true, "...") }}
{% else %}
<!-- Fallback, falls kein Excerpt oder Inhalt verfügbar ist -->
<p>Mehr Informationen im vollständigen Artikel.</p>
{% endif %}
</div>
<br />
<a href="{{ post.url | url }}" class="md-button" title="Weiterlesen: {{ post.title }}">Weiterlesen</a>
</article>