Replace the always-visible "Add trigger" inline form + inline per-trigger
editor with a clearer pattern: a header + "Add trigger" button, a list of
compact TriggerListCard entries, and an add/edit dialog. Enable/disable
becomes a switch on each card (single-click toggle, no save step).
ScheduleEditor gains first-class support for the shapes users actually
want: every-N-minutes (with optional hour window and weekdays-only),
every-N-hours, hourly at a minute offset, daily with one or more times
per day, selected-days-of-week with one or more times, and monthly with
one or more dates. The legacy parseCronToPreset/describeSchedule exports
remain backwards-compatible; describeSchedule now unfolds multi-value
hour and day lists into readable sentences instead of returning the raw
cron. Falls back to the raw cron for named-token forms it can't describe.
The CRUD wiring reuses the existing create/update/delete/rotate-secret
mutations, query invalidations, and the secret-material banner. Delete
now goes through a ConfirmDialog instead of firing on trash click.
Files:
- ui/src/components/ScheduleEditor.tsx — richer internal preset model
- ui/src/components/ScheduleEditor.test.ts — cover the new describers
- ui/src/components/TriggerListCard.tsx — new card view per trigger
- ui/src/components/TriggerDialog.tsx — add/edit modal wrapping the editor
- ui/src/components/ConfirmDialog.tsx — small confirm-dialog primitive
- ui/src/pages/RoutineDetail.tsx — swap the triggers tab to the new flow