Scaffold containerized Django/Wagtail app with core features

This commit is contained in:
Codex_B
2026-02-28 11:52:59 +00:00
parent 62323abd62
commit b5f0f40c4c
84 changed files with 1647 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
{% extends 'base.html' %}
{% load wagtailimages_tags wagtailcore_tags %}
{% block content %}
<h1>{{ page.title }}</h1>
<p>{{ page.mission_statement }}</p>
{{ page.body|richtext }}
{% if page.featured_author %}
<h2>{{ page.featured_author.name }}</h2>
<p>{{ page.featured_author.bio }}</p>
{% if page.featured_author.avatar %}
{% image page.featured_author.avatar fill-200x200 %}
{% endif %}
{% endif %}
{% endblock %}

View File

@@ -0,0 +1,11 @@
{% extends 'base.html' %}
{% load core_tags %}
{% block title %}Articles | No Hype AI{% endblock %}
{% block content %}
<h1>{{ page.title }}</h1>
{% for article in articles %}
{% include 'components/article_card.html' with article=article %}
{% empty %}
<p>No articles found.</p>
{% endfor %}
{% endblock %}

View File

@@ -0,0 +1,33 @@
{% extends 'base.html' %}
{% load wagtailcore_tags wagtailimages_tags seo_tags %}
{% block title %}{{ page.title }} | No Hype AI{% endblock %}
{% block content %}
<article>
<h1>{{ page.title }}</h1>
<p>{{ page.read_time_mins }} min read</p>
{% if page.hero_image %}
{% image page.hero_image fill-1200x630 %}
{% endif %}
{{ page.body }}
{% article_json_ld page %}
</article>
<section>
<h2>Related</h2>
{% for article in related_articles %}
<a href="{{ article.url }}">{{ article.title }}</a>
{% endfor %}
</section>
{% if page.comments_enabled %}
<section>
<form method="post" action="{% url 'comment_post' %}">
{% csrf_token %}
<input type="hidden" name="article_id" value="{{ page.id }}" />
<input type="text" name="author_name" required />
<input type="email" name="author_email" required />
<textarea name="body" required></textarea>
<input type="text" name="honeypot" style="display:none" />
<button type="submit">Post comment</button>
</form>
</section>
{% endif %}
{% endblock %}

View File

@@ -0,0 +1,4 @@
<div class="callout icon-{{ value.icon }}">
<h3>{{ value.heading }}</h3>
{{ value.body }}
</div>

View File

@@ -0,0 +1,5 @@
{% load wagtailcore_tags %}
<div class="code-block">
{% if value.filename %}<div>{{ value.filename }}</div>{% endif %}
<pre data-lang="{{ value.language }}"><code class="language-{{ value.language }}">{{ value.raw_code }}</code></pre>
</div>

View File

@@ -0,0 +1,5 @@
{% load wagtailimages_tags %}
<figure>
{% image value.image width-1024 alt=value.alt %}
{% if value.caption %}<figcaption>{{ value.caption }}</figcaption>{% endif %}
</figure>

View File

@@ -0,0 +1,4 @@
<blockquote>
<p>{{ value.quote }}</p>
{% if value.attribution %}<cite>{{ value.attribution }}</cite>{% endif %}
</blockquote>

View File

@@ -0,0 +1,21 @@
{% extends 'base.html' %}
{% block title %}No Hype AI{% endblock %}
{% block content %}
<section>
{% if featured_article %}
<h2>{{ featured_article.title }}</h2>
<p>{{ featured_article.author.name }}</p>
<p>{{ featured_article.read_time_mins }} min read</p>
{% endif %}
</section>
<section>
{% for article in latest_articles %}
{% include 'components/article_card.html' with article=article %}
{% endfor %}
</section>
<section>
{% for article in more_articles %}
{% include 'components/article_card.html' with article=article %}
{% endfor %}
</section>
{% endblock %}