Diff -- /var/www/vhosts/3dshawn.com/site1/TEMPLATES/diff.html
Diff
/var/www/vhosts/3dshawn.com/site1/TEMPLATES/diff.html
modified on local at 2026-07-11 23:34:36
Added
+6
lines
Removed
-0
lines
Context
45
unchanged
Blobs
from 5cfd896e2a84
to 4bae2d788795
to 4bae2d788795
Unified diff
Naive LCS-based line diff. Additions in emerald, deletions in rose. Both sides decompressed live from BLOB_STORE.| 1 | 1 | <div class="page-head"> |
| 2 | 2 | <span class="page-eyebrow"><span class="dot"></span> Diff</span> |
| 3 | 3 | <h1 class="page-title">$title</h1> |
| 4 | 4 | <p class="page-subtitle">$subtitle</p> |
| 5 | 5 | </div> |
| 6 | 6 | |
| 7 | 7 | <div class="dash-grid" style="grid-template-columns:repeat(4,1fr);margin-bottom:16px"> |
| 8 | 8 | <div class="module glow-emerald"><div class="module-head"><div class="left"><div class="module-title">Added</div></div></div><div class="module-body kpi kpi-emerald"><div class="num">+$ct_add</div><div class="lbl">lines</div></div></div> |
| 9 | 9 | <div class="module glow-rose"><div class="module-head"><div class="left"><div class="module-title">Removed</div></div></div><div class="module-body kpi kpi-rose"><div class="num">-$ct_del</div><div class="lbl">lines</div></div></div> |
| 10 | 10 | <div class="module glow-teal"><div class="module-head"><div class="left"><div class="module-title">Context</div></div></div><div class="module-body kpi kpi-teal"><div class="num">$ct_context</div><div class="lbl">unchanged</div></div></div> |
| 11 | 11 | <div class="module glow-sky"><div class="module-head"><div class="left"><div class="module-title">Blobs</div></div></div><div class="module-body kpi kpi-sky"><div class="num" style="font-size:14px;letter-spacing:0"><span class="dim">from</span> $prev_sha<br><span class="dim">to</span> $curr_sha</div></div></div> |
| 12 | </div> | |
| 13 | ||
| 14 | [if:$restore_url] | |
| 15 | <div style="display:flex;justify-content:flex-end;margin:-4px 0 12px"> | |
| 16 | <a href="$restore_url" class="tr-chip" style="border-color:var(--accent);color:var(--accent-hi)">Restore this content →</a> | |
| 12 | 17 | </div> |
| 18 | [/if] | |
| 13 | 19 | |
| 14 | 20 | <div class="module glow-teal"> |
| 15 | 21 | <div class="module-head"><div class="left"><div class="module-title">Unified diff</div><span class="module-subtitle">Naive LCS-based line diff. Additions in emerald, deletions in rose. Both sides decompressed live from BLOB_STORE.</span></div></div> |
| 16 | 22 | <div class="module-body tight"> |
| 17 | 23 | [if:$has_diff] |
| 18 | 24 | <style> |
| 19 | 25 | .diff-tbl { width:100%; border-collapse:collapse; font-family:var(--mono); font-size:12.5px; line-height:1.5; } |
| 20 | 26 | .diff-tbl td { padding:1px 8px; vertical-align:top; white-space:pre-wrap; word-wrap:break-word; } |
| 21 | 27 | .diff-tbl .ln { color:var(--text-muted); text-align:right; width:44px; user-select:none; border-right:1px solid var(--border); font-size:11px; } |
| 22 | 28 | .diff-tbl tr.op-add td.text { background:rgba(52,211,153,.10); color:#a7f3d0; } |
| 23 | 29 | .diff-tbl tr.op-add td.ln { background:rgba(52,211,153,.05); color:var(--accent-ok); } |
| 24 | 30 | .diff-tbl tr.op-add td.text::before { content:'+'; color:var(--accent-ok); padding-right:6px; } |
| 25 | 31 | .diff-tbl tr.op-del td.text { background:rgba(244,63,94,.10); color:var(--accent-danger-hi); } |
| 26 | 32 | .diff-tbl tr.op-del td.ln { background:rgba(244,63,94,.05); color:var(--accent-danger); } |
| 27 | 33 | .diff-tbl tr.op-del td.text::before { content:'-'; color:var(--accent-danger); padding-right:6px; } |
| 28 | 34 | .diff-tbl tr.op-ctx td { color:var(--text-dim); } |
| 29 | 35 | .diff-tbl tr.op-ctx td.text::before { content:' '; padding-right:6px; } |
| 30 | 36 | </style> |
| 31 | 37 | <div style="max-height:70vh;overflow:auto"> |
| 32 | 38 | <table class="diff-tbl"> |
| 33 | 39 | <tbody> |
| 34 | 40 | [loop:@lines]<tr class="op-$op"><td class="ln">$old_n</td><td class="ln">$new_n</td><td class="text">$text</td></tr>[/loop] |
| 35 | 41 | </tbody> |
| 36 | 42 | </table> |
| 37 | 43 | </div> |
| 38 | 44 | [/if] |
| 39 | 45 | [if:!$has_diff] |
| 40 | 46 | <div style="padding:36px 14px;text-align:center;color:var(--text-dim);font-size:13.5px"> |
| 41 | 47 | Nothing to diff. Blob may have been auto-purged, or this is the first snapshot. |
| 42 | 48 | </div> |
| 43 | 49 | [/if] |
| 44 | 50 | </div> |
| 45 | 51 | </div> |