-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Add razuna extension #21558
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add razuna extension #21558
Conversation
- Fixed: interface conflicts with Raycast\'s autogenerated type & added missing @typescript-eslint/recommended - Fix React types conflict by pinning @raycast/api to 1.86.1 - lib fixes - Pull contributions - Initial commit: Razuna Raycast extension
|
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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Greptile Summary
This PR adds a new Razuna extension to the Raycast extensions repository. The extension allows users to upload, search, and browse files in their Razuna workspace directly from Raycast.
Major changes:
- Complete Razuna integration with file management, search, and upload capabilities
- Proper workspace selection and management
- Grid-based file browsing with thumbnail support
- AI-powered file analysis display
- Comprehensive error handling and user experience
Issues found:
- ESLint configuration doesn't follow the standard Raycast pattern with
defineConfig - Manual Preferences type reference conflicts with autogenerated Raycast types
- Extension includes proper metadata screenshots and follows most Raycast conventions
Confidence score: 4/5
- This PR is generally safe to merge with minor configuration fixes needed
- The extension is well-structured with comprehensive functionality, proper error handling, and follows most Raycast conventions. Only two configuration issues need to be addressed before merging.
- Pay attention to .eslintrc.json and src/types.ts for configuration fixes
Important Files Changed
File Analysis
| Filename | Score | Overview | Issues |
|---|---|---|---|
| extensions/razuna/.eslintrc.json | 2/5 | ESLint config doesn't follow Raycast standard pattern | Should use defineConfig from eslint/config with Raycast config |
| extensions/razuna/package.json | 5/5 | Well-structured package.json with proper dependencies and configuration | None identified |
| extensions/razuna/src/types.ts | 3/5 | Type definitions and utility functions, contains Preferences interface issue | Manual Preferences type reference conflicts with autogenerated types |
| extensions/razuna/src/api.ts | 4/5 | Comprehensive API layer with error handling and proper typing | None identified |
| extensions/razuna/src/browse-files.tsx | 4/5 | File browsing component with grid display and proper navigation | None identified |
| extensions/razuna/src/manage-workspaces.tsx | 5/5 | Workspace management with proper selection and state handling | None identified |
19 files reviewed, 2 comments
extensions/razuna/.eslintrc.json
Outdated
| { | ||
| "env": { | ||
| "browser": true, | ||
| "es2021": true, | ||
| "node": true | ||
| }, | ||
| "extends": [ | ||
| "eslint:recommended", | ||
| "plugin:@typescript-eslint/recommended" | ||
| ], | ||
| "parser": "@typescript-eslint/parser", | ||
| "parserOptions": { | ||
| "ecmaVersion": "latest", | ||
| "sourceType": "module", | ||
| "ecmaFeatures": { | ||
| "jsx": true | ||
| } | ||
| }, | ||
| "plugins": ["@typescript-eslint", "react", "react-hooks"], | ||
| "rules": { | ||
| "@typescript-eslint/no-unused-vars": "warn", | ||
| "@typescript-eslint/no-explicit-any": "warn" | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
syntax: Replace with standard Raycast ESLint configuration using defineConfig from "eslint/config":
| { | |
| "env": { | |
| "browser": true, | |
| "es2021": true, | |
| "node": true | |
| }, | |
| "extends": [ | |
| "eslint:recommended", | |
| "plugin:@typescript-eslint/recommended" | |
| ], | |
| "parser": "@typescript-eslint/parser", | |
| "parserOptions": { | |
| "ecmaVersion": "latest", | |
| "sourceType": "module", | |
| "ecmaFeatures": { | |
| "jsx": true | |
| } | |
| }, | |
| "plugins": ["@typescript-eslint", "react", "react-hooks"], | |
| "rules": { | |
| "@typescript-eslint/no-unused-vars": "warn", | |
| "@typescript-eslint/no-explicit-any": "warn" | |
| } | |
| } | |
| const { defineConfig } = require("eslint/config"); | |
| const raycastConfig = require("@raycast/eslint-config"); | |
| module.exports = defineConfig([ | |
| ...raycastConfig, | |
| // Additional rules if needed | |
| ]); |
Context Used: Rule - ## ESLint Configuration
Import Path for defineConfig
- The correct import path for
defineConfigis"eslint/config", not"eslint" - Do NOT suggest changing imports from
"eslint/config"to"eslint" - Both CommonJS and ES module patterns should use the
/configsubpath
Correct Examples
// ✅ Correct - CommonJS
const { defineConfig } = require("eslint/config");
// ✅ Correct - ES Modules
import { defineConfig } from "eslint/config";
// ❌ Incorrect
const { defineConfig } = require("eslint");
import { defineConfig } from "eslint";Standard Raycast ESLint Configuration
Extensions should follow the established pattern:
const { defineConfig } = require("eslint/config");
const raycastConfig = require("@raycast/eslint-config");
module.exports = defineConfig([
...raycastConfig,
// Additional rules if needed
]);(link)
| export const getPreferences = () => { | ||
| return getPreferenceValues<Preferences>(); | ||
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
syntax: The Preferences type is autogenerated by Raycast and should not be manually defined. Remove the type reference as indicated by the comment:
| export const getPreferences = () => { | |
| return getPreferenceValues<Preferences>(); | |
| }; | |
| export const getPreferences = () => { | |
| return getPreferenceValues(); | |
| }; |
Context Used: Context - You shouldn't create the Preferences interface since it's autogenerated in raycast-env.d.ts when you run the extension. (link)
…son and package-lock.json. Add Raycast-specific files to .gitignore. Fix copy action titles in browse and search files components.
- Removed unused import of `fetch` in `api.ts`. - Simplified imports in `browse-files.tsx` and `search-files.tsx` by consolidating related functions. - Deleted the `search-files-clean.tsx` file as it was redundant. - Added `FileDetail` component export in `index.ts` for better modularity. - Updated utility functions for file handling in `utils.ts` to enhance code clarity.
|
Hi 👋 I updated the PR. Can you take a look to make sure I didn't break anything? |
|
@greptileai, could you please do a fresh review here? 😊 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Greptile Summary
This PR refactors the Razuna extension components following previous PR feedback. Key improvements include:
- ESLint Configuration: Updated to use standard Raycast ESLint config with proper
defineConfigimport fromeslint/config - Preferences Interface: Removed manual
Preferencesinterface definition to rely on Raycast's autogenerated types - Component Structure: Clean refactoring of browse, search, and file management components
- Workspace Management: Enhanced workspace selection and persistence using LocalStorage
- File Operations: Comprehensive file browsing, searching, and upload functionality with proper error handling
- UI/UX: Well-structured Grid layouts with thumbnails, metadata display, and action panels
The extension provides a complete Razuna integration with proper API authentication, file type detection, and Raycast UI patterns. All code follows TypeScript best practices with comprehensive type definitions and error handling.
Confidence score: 5/5
- This PR is safe to merge with minimal risk - clean refactoring following PR feedback
- Score reflects adherence to previous feedback, proper TypeScript implementation, comprehensive error handling, and following Raycast extension standards. No breaking changes or security concerns identified.
- No files require special attention - all components are well-structured and follow best practices
Important Files Changed
File Analysis
| Filename | Score | Overview | Issues |
|---|---|---|---|
| extensions/razuna/eslint.config.js | 5/5 | Updated ESLint configuration to use standard Raycast config with defineConfig | None identified |
| extensions/razuna/src/types.ts | 5/5 | Fixed manual Preferences interface removal as per Raycast standards | None identified |
| extensions/razuna/package.json | 5/5 | Clean package.json with proper dependencies and Raycast extension configuration | None identified |
| extensions/razuna/src/api.ts | 4/5 | Comprehensive Razuna API client with error handling and multi-format response parsing | None identified |
| extensions/razuna/src/browse-files.tsx | 5/5 | Main file browsing component with workspace selection, folder navigation, and file grid display | None identified |
| extensions/razuna/src/search-files.tsx | 5/5 | File search component with workspace-scoped search and proper result pagination | None identified |
| extensions/razuna/src/components/FileDetail.tsx | 5/5 | Comprehensive file detail view with metadata, AI analysis, and action panel | None identified |
12 files reviewed, no comments
|
Published to the Raycast Store: |
|
🎉 🎉 🎉 Such a great contribution deserves a reward, but unfortunately we couldn't find your Raycast account based on your GitHub username (@thenitai). |
Just done so. Thx. |
Description
Please see: #21526
Screencast
Please see: #21526
Checklist
npm run buildand tested this distribution build in Raycastassetsfolder are used by the extension itselfREADMEare placed outside of themetadatafolder