Skip to content

[FEAT] Add "Clear Week" action with confirmation warning #159

Closed

Description

@GiZano

Is your feature request related to a problem? Please describe.

When planning a week or after accidentally copying the previous week, clearing scheduled blocks requires opening each block individually and deleting it one by one. This causes unnecessary friction and frustration when resetting a week schedule.

Describe the solution you'd like

  1. Add a Clear Week action button in PlannerScreen.tsx (visible when the current week has at least one scheduled block).
  2. When tapped, trigger a native confirmation dialog:
    • Title: "Clear entire week?"
    • Message: "Are you sure you want to remove all scheduled blocks for this week? This action cannot be undone."
  3. Upon confirmation, execute a clearCurrentWeek() context method that:
    • Clears all blocks for the active currentWeekId.
    • Properly removes all linked Google Calendar events via deleteCalendarEvent().
    • Persists the empty state to storage and updates the UI immediately.

Describe alternatives you've considered

Multi-select block deletion, but that adds significant UI complexity compared to a single, clean "Clear Week" button.

Additional Context

  • Related files: src/screens/PlannerScreen.tsx, src/store/PlannerContext.tsx, src/utils/i18n.ts.
  • AI Generation Disclosure: This issue description was generated by an AI agent (Gemini 3.1 Pro).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions