S039: relative dates, 12/24-hour clock, date settings

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
This commit is contained in:
astar76 2026-11-18 19:46:15 -06:00
commit f5ba5fdebe

View file

@ -145,5 +145,11 @@ One entry per session, newest last, ≤ 15 lines: done, verified how, not done,
- Verified: workspace build, clippy -D warnings, fmt --check; `cargo run -p tunal-net --example ssh_smoke` with HOME overridden: Include file listed, first-match/negation resolution, plain + hashed + port + revoked + ca entries, accept then Match, write under ~/.ssh refused, sample ~/.ssh unchanged.
- Not done: no real ~/.ssh read; `Match` conditions not evaluated (block skipped); `%h`-style tokens only for HostName; no host-key algorithm negotiation preference.
## S039 — Relative dates and clock
- Done: `format::date` follows `DateStyle` (Relative default: Just now, N minutes/hours ago, Yesterday/weekday + time, `Nov 3, 3:42 PM`, `Nov 3, 2024`; Absolute: `Nov 3, 2025, 3:42 PM`) and `Clock` (12h default, 24h) kept in process-wide atomics (`format::set_dates`). `format::long_date` (Properties) always absolute, with seconds, in the chosen clock. `settings.toml` keys `date_style` (`relative|absolute`), `clock` (`12h|24h`); Settings > General has "Dates" and "Clock" chips; a change redraws every pane at once (`FolderModel::redraw_dates`).
- Tick: one 60 s repeating timer in `SettingsUi` redraws panes that hold an entry under 1 hour old; other ticks repaint nothing (timer itself keeps running).
- Verified: workspace build, clippy -D warnings, fmt --check; screenshot of a scratch folder: 2 hours ago, 5 minutes ago, Just now, Friday, Nov 9, Nov 18 2025, Yesterday, all 12-hour.
- Not done: 24-hour and Absolute not screenshotted; timer not stopped when nothing is fresh; "visible row" check covers all rows of a pane; conflict dialog dates use the same setting but were not looked at.
## Later
-