{#
mdb-engine framework base template.
Provides correct script ordering so MDB.BASE (and friends) are always
available in {% block base_js %} and {% block extra_js %}.
Block hierarchy (in render order):
title — page
(auto-filled from seo.title when present)
seo_meta — Open Graph, Twitter Card, JSON-LD (auto-rendered from seo)
head — content (CSS, extra meta tags, fonts, etc.)
body — full visual structure; scripts here MUST NOT use MDB
content — main page content (nested inside body)
base_js — app-level base scripts (logout, nav helpers) — MDB available
extra_js — page-level scripts — MDB available
SEO context (populated automatically by SSR routes with a "seo" config):
{{ seo.title }} — resolved page title
{{ seo.description }} — resolved meta description
{{ seo.og_type }} — Open Graph type (defaults to "website")
{{ seo.og_image }} — Open Graph image URL
{{ seo.site_name }} — site name from manifest
{{ seo.json_ld }} — JSON-LD structured data string
Template globals injected by the engine (always available):
{{ base_path }} — app mount path, e.g. "/ai-chat"
{{ auth_hub_url }} — auth hub URL, e.g. "/auth-hub"
{{ app_slug }} — app slug, e.g. "ai-chat"
JavaScript globals (available in base_js / extra_js):
MDB.BASE — same as {{ base_path }}
MDB.AUTH_HUB — same as {{ auth_hub_url }}
MDB.APP_SLUG — same as {{ app_slug }}
MDB.csrfToken() — current CSRF token from cookie
getCookie(name) — read any cookie by name
BASE — alias for MDB.BASE (backwards-compatible)
#}
{% block title %}{{ seo.title if seo is defined and seo.title else '' }}{% endblock %}
{% block seo_meta %}
{% if seo is defined and seo %}
{% if seo.canonical %}
{% endif %}
{% if seo.og_image %}
{% else %}
{% endif %}
{% if seo.og_image %}
{% endif %}
{% if seo.json_ld %}
{% endif %}
{% if seo.pagination_prev %}
{% endif %}
{% if seo.pagination_next %}
{% endif %}
{% if seo.feed_links %}
{% for feed in seo.feed_links %}
{% endfor %}
{% endif %}
{% endif %}
{% endblock %}
{% block head %}{% endblock %}
{% block body %}
{% block content %}{% endblock %}
{% endblock %}
{% block base_js %}{% endblock %}
{% block extra_js %}{% endblock %}