{% extends "base.html" %} {% block title %}Editor — Canon{% endblock %} {% block content %} {% if mode == "list" %}

Spec Editor

{% if github_user %} Connected as {{ github_user.login }} {% endif %}
{% if repos %}
{% for repo in repos %}

{{ repo.full_name }}

{{ repo.description or 'No description' }}

New Spec
{% endfor %}
{% else %}

No repositories found. Connect your GitHub account to get started.

{% endif %} {% else %}

{% if mode == "new" %}New Spec{% else %}Editing {{ file_path }}{% endif %}

Frontmatter

{% if mode == "new" %}
{% endif %}

Body

{% if posthog_key %} {# NOTE: Client-side 'editor_saved' fires here; server-side 'spec_saved' fires in editor_routes.py. Use 'spec_saved' for authoritative save counts (server-validated). #} {% endif %} {% endif %} {% endblock %}