Skip to content

Conversation

@elliotekj
Copy link

@elliotekj elliotekj commented Jan 11, 2026

Description

A screenshot browser for quick find-and-paste of screenshots into the foreground app. Built with Claude Code, Codex, etc in mind but works for anything that accepts pasted images.

Screencast

screenshots_demo.mov

Checklist

- feat: screenshots extension v1.0.0
- initial commit
@raycastbot raycastbot added the new extension Label for PRs with new extensions label Jan 11, 2026
@raycastbot
Copy link
Collaborator

Congratulations on your new Raycast extension! 🚀

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

Once the PR is approved and merged, the extension will be available on our Store.

@elliotekj elliotekj marked this pull request as ready for review January 11, 2026 14:34
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Jan 11, 2026

Greptile Overview

Greptile Summary

This PR adds a new Screenshots extension that provides a grid-based browser for macOS screenshots with a paste-first workflow. The extension automatically detects the screenshot directory from macOS system preferences, watches for new screenshots, and supports infinite scrolling.

Key Features:

  • Grid view with thumbnail previews sorted by modification time
  • Auto-detection of screenshot directory (preference → system location → Desktop fallback)
  • Real-time directory watching for auto-refresh
  • Paste action that copies to clipboard and simulates Cmd+V
  • Standard file operations (copy, preview, open, reveal, trash)
  • Infinite scroll with batched loading (20 items at a time)

Architecture:

  • Uses fs.watch for directory monitoring with automatic cleanup
  • Custom useScreenshots hook manages loading state and pagination
  • Leverages image-size package for dimension extraction
  • Properly uses Action.Trash for deletion
  • Correctly relies on auto-generated Preferences interface

Confidence Score: 4/5

  • Generally safe to merge with one logic issue that may affect user experience during paste operations
  • The extension follows Raycast conventions well (uses Action.Trash, auto-generated Preferences, includes metadata screenshots, has CHANGELOG). However, the use of blocking execSync in an async function (line 172) can freeze the UI during paste operations, which is a real UX issue. The "latest" dependency version is a minor maintainability concern but not blocking.
  • extensions/screenshots/src/browse-screenshots.tsx - contains blocking execSync call that should be made async

Important Files Changed

File Analysis

Filename Score Overview
extensions/screenshots/package.json 4/5 New extension manifest with standard configuration. Uses "latest" for @raycast/api instead of semantic version.
extensions/screenshots/src/browse-screenshots.tsx 3/5 Main extension code with screenshot browsing/paste functionality. Uses blocking execSync in async context.
extensions/screenshots/README.md 5/5 Well-structured documentation with feature list and configuration instructions.
extensions/screenshots/CHANGELOG.md 5/5 Comprehensive initial release changelog following conventions.

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.

2 files reviewed, 2 comments

Edit Code Review Agent Settings | Greptile

}
],
"dependencies": {
"@raycast/api": "latest",
Copy link
Contributor

Choose a reason for hiding this comment

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

Use a specific semantic version instead of "latest" for @raycast/api. The "latest" tag can cause unpredictable behavior and breaks reproducible builds. Other extensions in this repo use versions like "^1.104.1" or similar.

await Clipboard.copy({ file: filePath });
await closeMainWindow();
await new Promise((resolve) => setTimeout(resolve, 100));
execSync(`osascript -e 'tell application "System Events" to keystroke "v" using command down'`, { timeout: 5000 });
Copy link
Contributor

Choose a reason for hiding this comment

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

execSync blocks the Node.js event loop, which can freeze the Raycast UI during the paste operation. Use async exec with promisify instead for non-blocking execution in this async function.

@ridemountainpig
Copy link
Contributor

Is this extension different from the Search Screenshots command? They look similar.

Raycast 2026-01-12 at 10 41 25

@0xdhrv 0xdhrv assigned 0xdhrv and unassigned pernielsentikaer Jan 12, 2026
@0xdhrv
Copy link
Contributor

0xdhrv commented Jan 12, 2026

Thanks for your contribution @elliotekj 🔥

We already have multiple extensions in the Store that deal with JWT. Could we consider enhancing one of the existing extensions below instead of creating another one?

If there are unique features or workflows you’re aiming to add, we’d love to hear them and see if they can be integrated into one of these to avoid duplication and improve discoverability.

This would help avoid duplication and keep related functionality consolidated in one place.
As mentioned in our extension guidelines here ↗

@0xdhrv 0xdhrv marked this pull request as draft January 12, 2026 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new extension Label for PRs with new extensions platform: macOS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants