Skip to content

feat(planner): add clear week action with confirmation dialog #159 - #162

Merged
GiZano merged 2 commits into
ClimbStack:mainfrom
Gheb6:feat/issue-159-clear-week
Oct 14, 2026
Merged

GiZano merged 2 commits into
ClimbStack:mainfrom
Gheb6:feat/issue-159-clear-week

Conversation

@Gheb6

@Gheb6 Gheb6 commented Oct 13, 2026

Copy link
Copy Markdown
Contributor

Closes #159

Summary

  • Adds a "Clear Week" button in PlannerScreen.tsx (visible when the current week has at least one scheduled block).
  • Triggers a native confirmation dialog before clearing.
  • Implements clearCurrentWeek() in PlannerContext.tsx to clear active week blocks, remove linked Google Calendar events, and persist empty state.
  • Adds localized strings in English, Italian, German, French, and Spanish.
  • Adds comprehensive unit tests for PlannerContext and PlannerScreen.

AI Generation Disclosure

  • Tool / Model: Gemini 3.8 Flash (High) via Antigravity IDE.
  • Generated files:
    • src/utils/i18n.ts (added clearWeek* keys across all languages)
    • src/store/PlannerContext.tsx (clearCurrentWeek implementation and action type)
    • src/screens/PlannerScreen.tsx (clear week button, handler, and styling)
    • src/store/__tests__/PlannerContext.test.tsx (full file)
    • src/screens/__tests__/PlannerScreen.test.tsx (full file)

…erated)

Closes ClimbStack#159

- Add clearCurrentWeek method in PlannerContext to reset active week, remove linked calendar events, and persist empty state

- Add Clear Week action button in PlannerScreen with native confirmation dialog

- Add localized strings across all supported languages

- Add unit tests in PlannerContext.test.tsx and PlannerScreen.test.tsx
@codecov

codecov Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

…Week button (AI-generated)

Cover dark theme styling, pressed opacity state, storage save failure, and calendar event deletion error handling to achieve 100% patch coverage.
@GiZano
GiZano merged commit b3d78ee into ClimbStack:main Oct 14, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

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

2 participants