diff --git a/README.md b/README.md index 075ee8f..b3b0661 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,7 @@ A Flask-based webcomic website with server-side rendering using Jinja2 templates - Archive page with thumbnail grid - RSS feed support - JSON API for programmatic access +- Open Graph and Twitter Card metadata for social sharing - Responsive design - Server-side rendering with Jinja2 - Clean, comic-focused layout diff --git a/templates/base.html b/templates/base.html index f4a061e..ed2f505 100644 --- a/templates/base.html +++ b/templates/base.html @@ -4,6 +4,24 @@ {% block title %}{{ title }}{% endblock %} - Sunday Comics + + + + + + + + + + + + + + + + + + {% block extra_css %}{% endblock %} diff --git a/templates/comic.html b/templates/comic.html index 604f396..2e9a368 100644 --- a/templates/comic.html +++ b/templates/comic.html @@ -1,5 +1,9 @@ {% extends "base.html" %} +{% block meta_description %}{{ comic.alt_text }}{% if comic.author_note %} - {{ comic.author_note }}{% endif %}{% endblock %} + +{% block og_image %}{{ request.url_root }}static/images/thumbs/{{ comic.filename }}{% endblock %} + {% block content %}
diff --git a/templates/index.html b/templates/index.html index ab96381..6c734c1 100644 --- a/templates/index.html +++ b/templates/index.html @@ -1,5 +1,11 @@ {% extends "base.html" %} +{% if comic %} +{% block meta_description %}{{ comic.alt_text }}{% if comic.author_note %} - {{ comic.author_note }}{% endif %}{% endblock %} + +{% block og_image %}{{ request.url_root }}static/images/thumbs/{{ comic.filename }}{% endblock %} +{% endif %} + {% block content %}