feat: side-by-side diff view + auto-save skips backup
CI / lint (push) Failing after 7s
CI / test (push) Has been skipped
CI / build (push) Has been skipped
CI / security (push) Successful in 10s

- Side-by-side diff: toggle button (columns-2/align-justify icon) in toolbar
  switches between unified and side-by-side view
- Backend: diff endpoint returns left_content + right_content for side-by-side
- Frontend: SequenceMatcher-based LCS diff for two-column rendering
- CSS: .backup-diff-sidebyside with left/right borders, empty cell styling
- Auto-save: PUT /save?backup=false skips backup creation (auto-save=no backup)
- Footer text updated to reflect backup-on-manual-save behavior
This commit is contained in:
2026-06-04 18:37:14 -04:00
parent 1e9ecf656f
commit 8c5a5fd6b2
4 changed files with 177 additions and 5 deletions
+41
View File
@@ -7458,3 +7458,44 @@ body.popup-mode .content-area {
font-size: 0.7rem;
color: var(--text-muted);
}
/* ── Side-by-side diff view ── */
.backup-diff-sidebyside .sidebyside {
table-layout: fixed;
}
.backup-diff-sidebyside td.sidebyside-left {
border-right: 1px solid var(--border);
}
.backup-diff-sidebyside td.sidebyside-right {
border-left: 1px solid var(--border);
}
.backup-diff-sidebyside td.diff-empty-cell {
background: var(--bg-tertiary);
}
.backup-diff-mode-btn {
padding: 6px 10px;
border: 1px solid var(--border);
border-radius: 6px;
background: transparent;
color: var(--text-secondary);
cursor: pointer;
display: inline-flex;
align-items: center;
gap: 4px;
font-size: 0.8rem;
transition: all 150ms ease;
}
.backup-diff-mode-btn:hover {
color: var(--accent);
border-color: var(--accent);
}
.backup-diff-mode-btn .icon-sm {
width: 14px;
height: 14px;
}