This commit optimizes the data payload generation by replacing the previous slow, generic fingerprinting logic with a fast, specialized one. The previous method using `JSON.stringify` introduced a 20-50ms latency bottleneck; the new implementation uses a targeted string concatenation method to achieve the same payload reduction in about 10ms.
Implements a props templating system to the sidecar reconciler to significantly reduce the initial data payload size. The system now identifies repeating property sets, defines them as a template once, and then applies this template to multiple components, avoiding redundant data transmission. By writing the payload to a log file, we see that initial payload size for the Pokémon extension decreases from 150k to 30k lines
This commit implements zlib compression for large messages sent from the Node.js sidecar to the frontend. A threshold prevents small messages from incurring compression overhead, and a flag in the length-prefix header signals whether a payload is compressed, avoiding protocol changes. By adding a log to the sidecar service, we can measure that the rolling average from loading the Pokémon plugin decreases from 140ms to about 110ms.
This commit moves the current plugin details, previously in api/index.ts, to the state.ts file. This way, it can be accessed in the cache.ts file, which uses it as the "namespace", used to create the cache data directory.
This commit introduces the `FOCUS_ELEMENT` and `RESET_ELEMENT` message schemas and implements corresponding focus and reset functionalities in form components. The imperative bus is utilized to handle these commands, allowing for improved interaction with form elements like TextField, TextArea, and Dropdown.
It also fixes the `onSubmit` logic to pass the values of the form as a single argument, a mapping from IDs to values, as defined in the documentation.
This commit introduces a new `keyboard.ts` module that defines key equivalents, modifiers, and common keyboard shortcuts for the application. The `Keyboard` object is exported for use in other parts of the codebase, enhancing keyboard navigation capabilities.
This commit replaces the stub in `environment.canAccess(AI)`. The access status is now determined by the backend when a command is launched and is passed to the sidecar process. This allows the `canAccess` function within the plugin's environment to synchronously return the correct access status. In the future, we should probably avoid hardcoding it in the parameter somehow.
This commit moves default model mappings into the backend, making it the single source of truth. The `get_ai_settings` command now merges user-defined settings with these defaults, so the UI always receives a complete and correct configuration. The model selection logic in `ai_ask_stream` was also simplified to use the merged settings, which fixes a bug where the system would use a global fallback instead of the correct model-specific default. Additionally, the `set_ai_settings` command now only persists user overrides, keeping the configuration file clean.
This commit introduces a new AI module that includes schemas for AI requests and responses, as well as event handling for streaming AI responses. It adds functions to manage AI API keys, log usage, and handle streaming data from the AI service.
This commit adds support for deeplinks starting with `raycast://extension`, which run a specific command in an extension. It adds the `author` and `owner` fields in the PluginInfo schema, updates the plugin discovery process to include these fields, and implements a new CommandDeeplinkConfirm component for confirming command execution from deep links. Additionally, it modifies the builtin command names, titles, as well as their plugin names and titles to correctly reflect Raycast's implementation. This means that the deeplinks should be interoperable.
Previously, we were passing in only the plugin preferences. This means that when calling `getPreferenceValues`, none of the command preferences would be returned. This commit changes it to return *all* command preferences -- I do not think it will cause any problems, but we'll see I guess ¯\_(ツ)_/¯
This commit introduces support for all remaining preference types as specified in the API, including password, checkbox, appPicker, file, and directory. Eventually, we will probably have to somehow make the password preferences encrypted.
This commit introduces a new `rpc.ts` module to centralize the asynchronous request/response logic between the sidecar and the main Tauri process. Previously, files like `clipboard.ts`, `environment.ts`, and `browserExtension.ts` each had their own duplicate implementation for managing pending requests and timeouts. By abstracting this boilerplate into a single RPC utility, we eliminate redundant code, reduce the surface area for bugs, and simplify the creation of future native API bridges.
This commit introduces new system message schemas and corresponding commands for managing applications, including fetching applications, getting the default application, retrieving the frontmost application, showing an application in Finder, and trashing files.
Originally, removing the literal require call seems to have completely removed the "require" logic from the code, giving a "require is not defined" error. This commit fixes it by reverting to the previous literal `require()` call.
This commit completely redesigns the extension settings page to support both extension-level and command-level preferences. The UI now features a searchable, tree-like view that clearly displays the hierarchy of extensions and their configurable commands, making navigation more intuitive. This new structure allows users to more easily locate and manage the specific settings they need.
This commit adds the HUD API, allowing extensions to display temporary, non-interactive messages on the screen. The implementation adds a `show_hud` Tauri command that manages a dedicated, borderless Svelte window. This window is dynamically resized to fit its content and is automatically hidden after two seconds.
This commit implements the full api for the Raycast browser extension. It introduces a WebSocket server in the Tauri backend to handle JSON-RPC communication with the companion browser extension. The sidecar now exposes the BrowserExtension module with getTabs and getContent methods, which proxy requests through the frontend to the new backend commands.
Updated the plugin loading logic to throw an error if no plugin path is specified. Enhanced the icon resolution function to use path.join for constructing asset paths, and removed hardcoded paths from the DropdownItem component. Introduced a context for assetsPath in the main page to streamline asset management across components.
Added schemas for toast notifications, including show, update, and hide actions. Integrated toast handling into the sidecar's command processing and UI components, allowing for interactive user feedback. Introduced a new Toast API for creating and managing toast instances.
Added schemas and message handling for the new get-selected-finder-items command. Implemented the logic to retrieve selected items from the Finder on macOS, Windows, and Linux, enhancing the application's ability to interact with the file system.
Previously, this function was a shell that always rejected. This commit implements the schemas for a new get-selected-text command and updates the SidecarMessageWithPluginsSchema to include the new message type.
Add OpenMessageSchema and OpenPayloadSchema for handling messages to open an application. Decided to implement actual opening functionality in frontend for Tauri's security model
Added a mode parameter to the plugin execution flow, allowing plugins to run in 'view' or 'no-view' modes. Updated plugin runner to not pass plugin function into React if it is of type `no-view`
Added functionality to manage plugin preferences, including getting and setting preferences through the sidecar. Introduced a PreferencesStore to handle preference persistence and retrieval. Updated relevant components to support preference interactions, enhancing user experience in plugin settings.
Added a request-plugin-list action to the sidecar, which sends plugins to the frontend. Implemented plugin list as a separate view. Plugins now interoperable with Raycast (by copying the `dist` folder). Command discovery implemented by reading `package.json`.
- Introduces a new `environment.ts` file to manage API configuration and file system interactions.
- Implements support path creation and defines the `environment` object with properties for appearance, assets path, and launch type.
- Adds utility functions `getSelectedFinderItems` and `getSelectedText` for handling application-specific interactions.
- Updates `index.ts` to integrate the new environment module, replacing the previously hardcoded object.
- Consolidates navigation logic into a dedicated `navigation.ts` file.
- Introduces `types.ts` for `LaunchType` and `Toast` definitions.
- Implements utility functions in `utils.ts` for local storage and component creation.
- Adds new components: `Action`, `ActionPanel`, `Detail`, `Grid`, and `List`, enhancing the API's modularity and usability.
- Updates `getRaycastApi` to utilize the new structure and components, improving overall organization and maintainability.
Updates the filtering logic in List and Grid components to allow optional filtering props and uses the onSearchTextChange prop for better search handling. Modifies the props schemas accordingly and refactors the filtering implementation in the base view to improve code clarity and maintainability.
Binds the subscribe method in the Cache class to ensure it is correctly referenced, resolving the issue of "cannot read property subscribe of undefined".