Conversation
The date picker read - and + as day steps, on the theory that neither can appear in YYYY-MM-DD. The hyphen is the format's delimiter, so a date could not be typed at all: the input showed 20260914 and refused it. Only the arrows step now; every printable key reaches the input.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
🟢 Approval recommended
The behavioral change is tightly scoped, aligns with the reported repro, and is covered by a targeted regression test.
Pull request overview
This PR fixes the TUI dateTimePicker so users can type full YYYY-MM-DD dates (including the - delimiter) by limiting “step date by a day” behavior to only the Up/Down arrow keys.
Changes:
- Restrict date stepping to
↑/↓only; allow all printable keys (including-) to flow to the date text input. - Update the existing step-by-day test to use
↑instead of+. - Add a regression test that types a hyphenated date and asserts it parses cleanly.
[!TIP]
If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or rungh pr ready --undo.
Click "Ready for review" or rungh pr readyto reengage.
File summaries
| File | Description |
|---|---|
| internal/tui/datetime.go | Removes +/- stepping bindings so hyphens can be typed into the date field; keeps day-stepping on arrow keys only. |
| internal/tui/datetime_test.go | Updates stepping test to use arrow keys and adds a regression test for typing hyphenated dates. |
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Fixes #368
Repro
The TUI's date field (event form start/end, repeat-until, and every other
dateTimePicker) read-and+as day-step keys, on the theory that neither can appear inYYYY-MM-DD. The hyphen is the format's delimiter, so a date could not be typed: keying2026-09-14left20260914in the field, which the picker then refused with "Date must be YYYY-MM-DD"./reached the input and was refused for the same reason, which is the behaviour the reporter saw.TestDateTimePickerTypesADateWithItsHyphenstypes a date into an emptied field and fails onmainexactly that way.Fix
dateStepanswers only the arrows now; every printable key reaches the text input.+/=went with-: they were an undocumented extra (the help line only ever showed↑↓ day), and keeping one side of the pair would leave an asymmetric binding nobody can discover. The existing step test now steps back with ↑ where it used+.Summary by cubic
Fixes #368: the TUI date field now lets you type hyphens in
YYYY-MM-DDdates instead of treating-as a day-step key. The undocumented+/=step keys are gone too; only the arrow keys step the date.Written for commit 7a62afd. Summary will update on new commits.