Add task persistence and per-task reminder notifications

Tasks now survive app restarts via UserDefaults JSON. Each task with a
due time fires a notification at that exact time; date-only tasks fire
at 9am on the due date. Completing or deleting a task cancels its
pending notification. ContentView now reschedules on any task change.
This commit is contained in:
kutesir
2026-05-29 10:33:55 +03:00
parent bc55d27f45
commit 1d4d7f07c5
4 changed files with 97 additions and 29 deletions

View File

@@ -1096,7 +1096,7 @@ struct AddTaskSheet: View {
private func submit() {
guard canAdd else { return }
taskVM.addTask(title: cleanTitle, dueDate: parsed.date,
taskVM.addTask(title: cleanTitle, dueDate: parsed.date, hasTime: parsed.hasTime,
quadrant: selectedQuadrant, category: selectedCategory)
dismiss()
}