diff.html
html
| 1 | {% extends "musehub/base.html" %} |
| 2 | |
| 3 | {% block title %}Diff {{ short_id }} · {{ owner }}/{{ repo_slug }}{% endblock %} |
| 4 | |
| 5 | {% block breadcrumb %} |
| 6 | <a href="/{{ owner }}">{{ owner }}</a> / |
| 7 | <a href="{{ base_url }}">{{ repo_slug }}</a> / |
| 8 | <a href="{{ base_url }}/commits/{{ commit_id }}">{{ short_id }}</a> / |
| 9 | diff |
| 10 | {% endblock %} |
| 11 | |
| 12 | {% block repo_nav %}{% include "musehub/partials/repo_nav.html" %}{% endblock %} |
| 13 | |
| 14 | {% block page_json %}{"page": "diff", "repoId": {{ repo_id | tojson }}, "commitId": {{ commit_id | tojson }}, "shortId": {{ short_id | tojson }}, "owner": {{ owner | tojson }}, "repoSlug": {{ repo_slug | tojson }}, "baseUrl": {{ base_url | tojson }}, "parentId": {{ parent_id | tojson }}, "structuredDelta": {{ structured_delta | tojson if structured_delta else 'null' }}, "snapshotDiff": {{ snapshot_diff | tojson }}, "commit": {{ (commit | tojson) if commit else 'null' }}, "viewerType": {{ (domain.viewer_type if domain else 'generic') | tojson }},"domainName": {{ (domain.display_name if domain else 'Generic') | tojson }} |
| 15 | }{% endblock %} |
| 16 | |
| 17 | {% block content %} |
| 18 | <div class="df3-page"> |
| 19 | |
| 20 | {# ── Commit header ─────────────────────────────────────────────────────── #} |
| 21 | <div class="df3-header"> |
| 22 | <a href="{{ base_url }}/commits/{{ commit_id }}" class="df3-back"> |
| 23 | <svg xmlns="http://www.w3.org/2000/svg" width="11" height="11" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="19" y1="12" x2="5" y2="12"/><polyline points="12 19 5 12 12 5"/></svg> |
| 24 | Commit |
| 25 | </a> |
| 26 | {% if commit %} |
| 27 | <span class="df3-sha">{{ short_id }}</span> |
| 28 | <span class="df3-branch"> |
| 29 | <svg xmlns="http://www.w3.org/2000/svg" width="10" height="10" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="6" y1="3" x2="6" y2="15"/><circle cx="18" cy="6" r="3"/><circle cx="6" cy="18" r="3"/><path d="M18 9a9 9 0 0 1-9 9"/></svg> |
| 30 | {{ commit.branch or 'main' }} |
| 31 | </span> |
| 32 | <span class="df3-msg">{{ commit.message.split('\n')[0] | truncate(100) }}</span> |
| 33 | {% endif %} |
| 34 | </div> |
| 35 | |
| 36 | {# ── Filled by diff.ts ─────────────────────────────────────────────────── #} |
| 37 | <div id="df3-content" class="df3-content"> |
| 38 | <div class="df3-loading"> |
| 39 | <span class="spinner"></span> Loading diff… |
| 40 | </div> |
| 41 | </div> |
| 42 | |
| 43 | </div> |
| 44 | {% endblock %} |