Skip to content

feat: Add Tasks feature#5

Merged
VariableThe merged 1 commit into
mainfrom
feature/tasks
Jun 19, 2026
Merged

feat: Add Tasks feature#5
VariableThe merged 1 commit into
mainfrom
feature/tasks

Conversation

@VariableThe

@VariableThe VariableThe commented Jun 19, 2026

Copy link
Copy Markdown
Owner

Adds Tasks feature and onboarding docs

Summary by CodeRabbit

  • New Features
    • Introduced Tasks & Reminders: Create tasks using the /task command with optional due dates and times
    • Access the unified Tasks view via Cmd+T (or Ctrl+T on Windows/Linux) to view all tasks
    • Overdue tasks are highlighted in red for easy identification
    • Receive OS notifications when task reminders come due
    • Added "Reminders" button to the main action menu
    • Updated documentation with Tasks feature details

@VariableThe VariableThe merged commit 05a2010 into main Jun 19, 2026
@VariableThe VariableThe deleted the feature/tasks branch June 19, 2026 18:51
@coderabbitai

coderabbitai Bot commented Jun 19, 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: 6992e55a-1878-4d86-819a-f36c2352aa6f

📥 Commits

Reviewing files that changed from the base of the PR and between c0d1328 and e36a94c.

📒 Files selected for processing (7)
  • README.md
  • electron/main.ts
  • electron/preload.ts
  • features.md
  • src/App.css
  • src/App.tsx
  • src/components/RemindersPage.tsx

📝 Walkthrough

Walkthrough

Adds a Tasks & Reminders system: /task inline tokens in CodeMirror are decorated with a ReminderWidget (checked/overdue states), auto-timestamped via remConverterPlugin, and aggregated in a new RemindersPage overlay. OS notifications fire for due reminders. Cmd+T is wired end-to-end via Electron IPC through preload to toggle the Tasks view.

Changes

Tasks & Reminders Feature

Layer / File(s) Summary
Electron Cmd+T IPC wiring and help docs
electron/main.ts, electron/preload.ts
Adds a web-contents-created listener intercepting Ctrl/Cmd+T and forwarding trigger-tasks IPC to the renderer; exposes onTriggerTasks via contextBridge; writes commands/tasks.md help file; updates welcome checklist with a [7. Tasks] entry.
ReminderWidget and inline task decoration
src/App.tsx, src/App.css
Introduces ReminderWidget (checked/overdue states, click-to-toggle dispatch) and extends the CodeMirror decoration builder to recognize /task//task-done, compute overdue status from an optional (YYYY-MM-DD HH:MM) datetime, and apply per-line styling; adds CSS for all rem widget states including overdue red.
remConverterPlugin: auto-timestamp insertion
src/App.tsx
Adds remConverterPlugin ViewPlugin that auto-inserts the current timestamp after /task//task-done + space, and converts shorthand suffixes (@ 10m, @ tmrw, etc.) into absolute YYYY-MM-DD HH:MM strings via async document dispatch.
RemindersPage component
src/components/RemindersPage.tsx
New React overlay that parses all notes via regex into ReminderItem structs with done state, timestamps, and match metadata; sorts by done/target precedence; renders a themed full-screen panel with overdue/imminent coloring, toggle-reminder marker, and navigate-to-note row click.
App state, notification polling, and RemindersPage wiring
src/App.tsx
Adds showRemindersView state, Cmd/Ctrl+T keyboard shortcut, onTriggerTasks Electron callback, OS notification permission request with a 10-second polling interval that fires deduplicated notifications via localStorage, conditional RemindersPage render with note-edit and CodeMirror dispatch callbacks, and a Reminders action-menu entry.
Documentation
README.md, features.md
Adds /task command description and Cmd+T shortcut entry to README.md; adds Tasks & Reminders bullet to features.md.

Sequence Diagram

sequenceDiagram
  participant User
  participant Electron as electron/main.ts
  participant Preload as electron/preload.ts
  participant App as App.tsx
  participant RemindersPage as RemindersPage.tsx
  participant OS as OS Notifications

  User->>App: types /task + space in editor
  App->>App: remConverterPlugin inserts timestamp

  User->>Electron: presses Cmd+T
  Electron->>App: contents.send('trigger-tasks')
  Preload->>App: onTriggerTasks callback
  App->>RemindersPage: renders overlay (showRemindersView=true)
  RemindersPage->>RemindersPage: parses notes into ReminderItems

  App->>App: 10s interval scans due reminders
  App->>OS: Notification (deduplicated via localStorage)

  User->>RemindersPage: clicks task row
  RemindersPage->>App: onNavigateToNote + onClose
  App->>App: navigate to note, hide overlay

  User->>RemindersPage: clicks circle marker
  RemindersPage->>App: onToggleReminder(noteId, from, to, insert)
  App->>App: saveNote + dispatch CodeMirror change
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

  • VariableThe/PaperCache#3: Adds a similar inline CodeMirror widget system (/check tokens) using the same decoration builder and widget dispatch pattern that this PR extends for /task//task-done tokens.

Poem

🐇 A rabbit hops by, timer in paw,
/task in the editor, no deadline left raw.
Cmd+T swings open a Tasks page so neat,
Overdue glows red — no reminder's defeat.
🔔 Ding! The OS notifies, "Time's come to hop!"
Your tasks are all tracked now — the forgetting must stop.

✨ 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 feature/tasks

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