Skip to content

Fix agent rule violations#13

Merged
VariableThe merged 2 commits into
mainfrom
fix-agent-rule-violations
Jun 20, 2026
Merged

Fix agent rule violations#13
VariableThe merged 2 commits into
mainfrom
fix-agent-rule-violations

Conversation

@VariableThe

@VariableThe VariableThe commented Jun 20, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • New Features

    • Updated button label from "Reminders" to "Tasks"
  • Bug Fixes

    • Improved cleanup processes when exiting the tasks view
    • Fixed keyboard shortcut listener resource disposal during app navigation

coderabbitai Bot and others added 2 commits June 20, 2026 19:11
Fixed 3 file(s) based on 2 unresolved review comments.

Co-authored-by: CodeRabbit <noreply@coderabbit.ai>
@VariableThe VariableThe merged commit 45f6179 into main Jun 20, 2026
1 of 2 checks passed
@coderabbitai

coderabbitai Bot commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9a6ad06f-29a5-4215-bb3e-1eb60890bd84

📥 Commits

Reviewing files that changed from the base of the PR and between 8d028e6 and 8c43d03.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (3)
  • src/components/MainActionMenu.tsx
  • src/components/RemindersPage.tsx
  • src/hooks/useGlobalHotkey.ts

📝 Walkthrough

Walkthrough

The PR renames the "Reminders" button label to "Tasks" in MainActionMenu, adds an isMounted flag to RemindersPage's setTimeout loop to prevent state updates after unmount, and updates useGlobalHotkey to capture and invoke disposer callbacks from Electron's onTriggerNewNote and onTriggerTasks listeners during effect cleanup.

Changes

Tasks rename and cleanup fixes

Layer / File(s) Summary
Rename Reminders button to Tasks
src/components/MainActionMenu.tsx
Button label changed from "Reminders" to "Tasks"; click handler (setShowRemindersView(true)) is unchanged.
Safe unmount and Electron listener disposal
src/components/RemindersPage.tsx, src/hooks/useGlobalHotkey.ts
RemindersPage adds an isMounted flag checked before calling setNow and rescheduling. useGlobalHotkey now stores disposer handles returned by onTriggerNewNote and onTriggerTasks and calls disposeNewNote?.() and disposeTasks?.() in the effect cleanup alongside the existing removeEventListener.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Possibly related PRs

  • VariableThe/PaperCache#5: Introduced the Tasks/Reminders UI and the initial trigger-tasks Electron IPC wiring that this PR's cleanup and rename directly build upon.

Poem

🐇 A "Reminders" sign once hung on the door,
Now "Tasks" greets the rabbit forevermore.
The timers unmount without leaving a trace,
Disposers called cleanly, each in its place.
Tidy little burrow, no loose ends in sight! 🌿

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix-agent-rule-violations

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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.

1 participant