Skip to content

Conversation

@ScH01ar
Copy link
Contributor

@ScH01ar ScH01ar commented Jan 12, 2026

Description

Resolve #24221: Extract and open all URLs from Reminders.
This PR improves the Apple Reminders integration by surfacing all attached URLs:

  • Extracts the native EKReminder.url and parses additional links from notes via NSDataDetector.

  • Adds "Open Attached URL(s)" to the Action Panel and Menu Bar, supporting batch opening.

Screencast

image ## Checklist

- feat: open all attached reminder URLs
- feat: add action to open attached reminder URLs
@raycastbot raycastbot added extension fix / improvement Label for PRs with extension's fix improvements extension: apple-reminders Issues related to the apple-reminders extension AI Extension platform: macOS labels Jan 12, 2026
@raycastbot
Copy link
Collaborator

raycastbot commented Jan 12, 2026

Thank you for your contribution! 🎉

🔔 @thomaslombart @tmwrnr @irangarcia @jondelga @phil1995 @michalzuch @ridemountainpig @maxnyby @vmrjnvc @ramith123 you might want to have a look.

You can use this guide to learn how to check out the Pull Request locally in order to test it.

📋 Quick checkout commands
BRANCH="ext/apple-reminders"
FORK_URL="https://github.com/ScH01ar/raycast-extensions.git"
EXTENSION_NAME="apple-reminders"
REPO_NAME="raycast-extensions"

git clone -n --depth=1 --filter=tree:0 -b $BRANCH $FORK_URL
cd $REPO_NAME
git sparse-checkout set --no-cone "extensions/$EXTENSION_NAME"
git checkout
cd "extensions/$EXTENSION_NAME"
npm install && npm run dev

Due to our current reduced availability, the initial review may take up to 10-15 business days.

@ScH01ar ScH01ar marked this pull request as ready for review January 12, 2026 12:39
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Jan 12, 2026

Greptile Overview

Greptile Summary

This PR successfully implements URL extraction and batch opening functionality for Apple Reminders. The implementation:

What Changed:

  • Extracts URLs from both the native EKReminder.url property and additional URLs parsed from reminder notes using NSDataDetector
  • Deduplicates URLs before storing them in the attachedUrls array
  • Adds "Open Attached URL(s)" action to both the main action panel and menu bar
  • Properly handles pluralization in the UI ("URL" vs "URLs")
  • Adds the new contributor to package.json

Technical Implementation:

  • Swift: Uses NSDataDetector with proper type checking to extract all URLs from notes, combines with native reminder URL, and deduplicates
  • TypeScript: Filters out falsy values and conditionally renders the action only when URLs exist
  • Opens URLs sequentially using await open(url) in a loop

Areas for Improvement:
The implementation lacks error handling and user feedback that are standard patterns in this codebase. Other actions in both ReminderActions.tsx and menu-bar.tsx consistently use try-catch blocks with toast notifications. The search-router extension demonstrates the expected pattern for opening multiple URLs with proper error handling and success feedback.

Additionally, the CHANGELOG description mentions "the first URL" when the implementation actually extracts and opens all URLs found.

Confidence Score: 3/5

  • This PR is functionally safe but lacks error handling best practices present elsewhere in the codebase
  • The core functionality is solid: URL extraction using NSDataDetector is appropriate, deduplication works correctly, and the UI integration is clean. However, the lack of error handling for the open() calls is inconsistent with patterns used throughout the rest of this extension and similar extensions in the repo. While URLs from NSDataDetector should be valid, network issues or system errors could still cause open() to fail, leaving users without feedback. The CHANGELOG inaccuracy is minor but should be corrected.
  • ReminderActions.tsx and menu-bar.tsx need error handling added to the URL opening loops to match the error handling patterns used in other actions within the same files

Important Files Changed

File Analysis

Filename Score Overview
extensions/apple-reminders/CHANGELOG.md 4/5 Updated with new feature entry, but description mentions "first URL" when code extracts all URLs
extensions/apple-reminders/src/components/ReminderActions.tsx 3/5 Adds URL opening action but lacks error handling and user feedback for multiple URLs
extensions/apple-reminders/src/menu-bar.tsx 3/5 Implements URL opening in menu bar but lacks error handling for failed opens
extensions/apple-reminders/swift/AppleReminders/Sources/EventKit+Additions.swift 4/5 URL extraction logic is solid with NSDataDetector and deduplication, minor: silent failure on detector init

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3 files reviewed, 3 comments

Edit Code Review Agent Settings | Greptile


## [Add action to open attached URL] - {PR_MERGE_DATE}

- Detect the first URL in reminder notes (or Reminder URL when available) and expose an “Open Attached URL” action in the list and menu bar.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CHANGELOG description says "Detect the first URL in reminder notes" but the implementation actually extracts and allows opening all URLs found in the reminder (both from EKReminder.url and all URLs parsed from notes).

Consider updating to: "Detect all URLs in reminder notes (and Reminder URL when available) and expose an 'Open Attached URL(s)' action in the list and menu bar."

Comment on lines +223 to +227
onAction={async () => {
for (const url of attachedUrls) {
await open(url);
}
}}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The loop opening multiple URLs lacks error handling. If opening one URL fails, subsequent URLs may not open and the user gets no feedback about what went wrong.

Other actions in this file (like toggleReminder, setPriority) wrap their operations in try-catch blocks with toast notifications. Consider adding similar error handling here:

onAction={async () => {
  try {
    for (const url of attachedUrls) {
      await open(url);
    }
    if (attachedUrls.length > 1) {
      await showToast({
        style: Toast.Style.Success,
        title: `Opened ${attachedUrls.length} URLs`,
      });
    }
  } catch (error) {
    await showToast({
      style: Toast.Style.Failure,
      title: "Unable to open URL(s)",
    });
  }
}}

Reference: The search-router extension (extensions/search-router/src/search.tsx) uses this pattern when opening multiple URLs.

Comment on lines +244 to +248
onAction={async () => {
for (const url of attachedUrls) {
await open(url);
}
}}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to ReminderActions.tsx, this URL opening loop lacks error handling. If opening a URL fails, the user receives no feedback.

Consider wrapping in try-catch with toast notifications for consistency with other operations in this file (see setPriority, setDueDate, deleteReminder which all have proper error handling).

Additionally, when opening multiple URLs, consider showing a success toast to confirm the action completed (see the search-router extension for reference: extensions/search-router/src/search.tsx lines 40-46).

Copy link
Contributor

@0xdhrv 0xdhrv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ScH01ar 👋

Thanks for your contribution 💪

Could you look into the suggestions from Greptile

I'm looking forward to reviwing this extension again 🔥

I converted this PR into a draft until it's ready for the review, please press the button Ready for review when it's ready and we'll have a look 😊

Feel free to contact me here or at Slack if you have any questions.

@0xdhrv 0xdhrv marked this pull request as draft January 12, 2026 13:50
@0xdhrv 0xdhrv assigned 0xdhrv and unassigned pernielsentikaer Jan 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AI Extension extension: apple-reminders Issues related to the apple-reminders extension extension fix / improvement Label for PRs with extension's fix improvements platform: macOS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Apple Reminders] Action Open URL

4 participants