feat: make month week start configurable

Add a Monday-default --week-start option for every weekday and carry it through domain layout, full and compact rendering, event query windows, print mode, and the interactive TUI.

Preserve byte-compatible Monday output and cover rotated headers, spill dates, invalid input, sanitizer behavior, and live terminal restoration.
This commit is contained in:
2026-07-18 09:58:27 +01:00
parent b524e6e33d
commit 989332ef9a
17 changed files with 430 additions and 23 deletions

View File

@@ -8,7 +8,8 @@ typeface and palette; Nocal owns hierarchy, spacing, and restrained emphasis.
## Product principles
1. **The month is the home screen.** Launching Nocal immediately shows six
complete Monday-first weeks. There is no dashboard or splash screen.
complete weeks, Monday-first by default. `--week-start` can rotate the grid
to any weekday. There is no dashboard or splash screen.
2. **Useful at a glance.** Every visible day shows as many appointments as fit,
ordered as all-day first and then by start time. A final `+N more` line is
used instead of clipping silently.
@@ -98,8 +99,12 @@ exact occurrence in the month grid. `Esc` or `g` closes the agenda without
changing the month selection unless an occurrence was chosen. Hidden calendars
remain filtered there, while calendar selection and search can overlay the
agenda. Agenda navigation never persists state, and add/edit/delete remain in
the month workflow. The next local-data work adds advanced recurrence overrides
and rule editing.
the month workflow. Week-start selection rotates only the month grid, header,
and the visible range used by its month queries; storage, agenda windows, and
recurrence rules are unchanged. The default remains Monday for backward
compatibility. The CLI accepts the exact lowercase values `monday`, `tuesday`,
`wednesday`, `thursday`, `friday`, `saturday`, and `sunday`. The next local-data
work adds advanced recurrence overrides and rule editing.
## Local file interchange