guanghu/docs/adr/0032-status-bar-for-git-actions.md
冰朔 8739805f99
Some checks failed
Auto-update PR branches / Update open PR branches (push) Has been cancelled
CI / Frontend Static Quality Checks (push) Has been cancelled
CI / Frontend Tests & Coverage (push) Has been cancelled
CI / Rust Tests & Quality Checks (push) Has been cancelled
CI / Linux build verification (push) Has been cancelled
Release (Alpha) / Compute alpha version (push) Has been cancelled
Release (Alpha) / Build release artifacts (push) Has been cancelled
Release (Alpha) / GitHub Release (alpha) (push) Has been cancelled
Release (Alpha) / Update docs and release pages (push) Has been cancelled
Deploy docs / Build VitePress site (push) Has been cancelled
Deploy docs / Deploy to GitHub Pages (push) Has been cancelled
光湖开源源码快照 · Tolaria AGPL 分叉基线 · 独立更新链
2026-07-05 17:45:16 +08:00

2.1 KiB

type, id, title, status, date
type id title status date
ADR 0032 0032 Status Bar For Git Actions active 2026-03-31

Subfolder scanning and folder tree navigation

Context

The Laputa sidebar originally surfaced git-related affordances — a "Changes" nav item (visible when modified files > 0), a "Pulse" nav item, and a "Commit & Push" button — alongside the note-type navigation filters and sections. This mixed two concerns in the sidebar: navigation (where to go) and git status / actions (what changed, what to do). As the sidebar grew, the git items created visual noise and made the nav hierarchy harder to scan.

Decision

Move Changes, Pulse, and Commit & Push out of the sidebar and into the bottom status bar. The status bar shows a GitDiff icon with an orange count badge for modified files; a Pulse icon sits next to it. Commit & Push is accessible via an icon button beside the Changes indicator. The sidebar now contains only navigation items (filters and type sections).

Options considered

  • Keep git items in sidebar (status quo): familiar placement, visible at all times. Rejected — mixes navigation and action concerns; sidebar becomes harder to scan.
  • Status bar (chosen): consistent with app conventions (build number, sync status, vault switcher already live there); persistent but unobtrusive; follows macOS app patterns where status/action items live at window bottom.
  • Toolbar / breadcrumb bar: would require a new chrome layer or polluting the per-note breadcrumb with global git state. Rejected.

Consequences

  • Sidebar props modifiedCount, onCommitPush, isGitVault removed; sidebar renders navigation-only
  • StatusBar gains onClickPending, onClickPulse, onCommitPush, isGitVault props
  • Sidebar tests for Changes/Pulse/Commit button removed; StatusBar tests extended
  • Users find Commit & Push in the status bar (same location as sync indicators) rather than bottom of sidebar — small discoverability change, offset by status bar being always visible regardless of sidebar collapsed state
  • Triggers re-evaluation if: user research shows git actions are hard to discover in the status bar