From e1e4519be9d7738ce41c3e25314f55af1c4d412d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 13 Nov 2024 07:28:02 +0100 Subject: [PATCH 01/39] quickjs build - take 1 --- .../scripts/esbuild.sh | 4 +- packages/cursorless-jetbrains/TERMINOLOGY.md | 7 +++ packages/cursorless-jetbrains/package.json | 47 +++++++++++++++++++ .../scripts/buildLocal.sh | 5 ++ .../scripts/test-quickjs.sh | 45 ++++++++++++++++++ packages/cursorless-jetbrains/src/index.ts | 7 +++ packages/cursorless-jetbrains/tsconfig.json | 28 +++++++++++ 7 files changed, 141 insertions(+), 2 deletions(-) create mode 100644 packages/cursorless-jetbrains/TERMINOLOGY.md create mode 100644 packages/cursorless-jetbrains/package.json create mode 100644 packages/cursorless-jetbrains/scripts/buildLocal.sh create mode 100644 packages/cursorless-jetbrains/scripts/test-quickjs.sh create mode 100644 packages/cursorless-jetbrains/src/index.ts create mode 100644 packages/cursorless-jetbrains/tsconfig.json diff --git a/packages/cursorless-everywhere-talon/scripts/esbuild.sh b/packages/cursorless-everywhere-talon/scripts/esbuild.sh index ebbf79c1ee..b428a9b5a3 100755 --- a/packages/cursorless-everywhere-talon/scripts/esbuild.sh +++ b/packages/cursorless-everywhere-talon/scripts/esbuild.sh @@ -4,12 +4,12 @@ set -euo pipefail esbuild \ --outfile=out/talon.js \ --platform=neutral \ - --format=esm \ + --format=cjs \ --main-fields=main,module \ --conditions=cursorless:bundler \ --bundle \ --sourcemap \ - --external:talon \ + --external:std \ "$@" # FIXME: Talon javascript files needs to start with an import from Talon before any other code diff --git a/packages/cursorless-jetbrains/TERMINOLOGY.md b/packages/cursorless-jetbrains/TERMINOLOGY.md new file mode 100644 index 0000000000..a8fadf07cc --- /dev/null +++ b/packages/cursorless-jetbrains/TERMINOLOGY.md @@ -0,0 +1,7 @@ +# TextEditor/TextDocument vs Window/Buffer + +1. Each Cursorless "TextDocument" corresponds to a neovim "Buffer" +2. Each Cursorless "TextEditor" corresponds to a neovim "Window" +3. A "TextEditor" corresponds to a view of a "TextDocument". The same "TextDocument" can be opened in two different "TextEditor". +4. When a "Window" changes in neovim, we need to reflect its "TextEditor" +5. When a "Buffer" changes in neovim, we need to reflect its "TextDocument". diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json new file mode 100644 index 0000000000..a7c378d9dc --- /dev/null +++ b/packages/cursorless-jetbrains/package.json @@ -0,0 +1,47 @@ +{ + "name": "@cursorless/cursorless-neovim", + "version": "1.0.0", + "description": "cursorless in neovim", + "main": "./out/index.cjs", + "private": true, + "scripts": { + "build": "pnpm run esbuild:prod && pnpm run populate-dist", + "compile": "tsc --build", + "esbuild:base": "esbuild ./src/index.ts --format=esm --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=node --external:std", + "esbuild": "pnpm run esbuild:base --sourcemap", + "esbuild:prod": "pnpm run esbuild:base --minify", + "populate-dist": "bash ./scripts/populate-dist.sh", + "populate-dist:prod": "bash ./scripts/populate-dist.sh", + "watch:tsc": "pnpm compile --watch", + "watch:esbuild": "pnpm esbuild --watch", + "watch": "pnpm run --filter @cursorless/cursorless-neovim --parallel '/^watch:.*/'", + "clean": "rm -rf ./out tsconfig.tsbuildinfo ./dist ./build" + }, + "keywords": [], + "author": "", + "license": "MIT", + "types": "./out/index.d.ts", + "exports": { + ".": { + "cursorless:bundler": "./src/index.ts", + "default": "./out/index.cjs" + } + }, + "dependencies": { + "@cursorless/common": "workspace:*", + "@cursorless/cursorless-engine": "workspace:*", + "@cursorless/neovim-common": "workspace:*", + "@cursorless/neovim-registry": "workspace:*", + "@cursorless/node-common": "workspace:*", + "@cursorless/test-case-recorder": "workspace:*" + }, + "devDependencies": { + "@types/chai": "^5.0.0", + "@types/js-yaml": "^4.0.9", + "@types/lodash": "4.17.10", + "@types/uuid": "^10.0.0", + "lodash": "^4.17.21", + "neovim": "5.3.0", + "vscode-uri": "^3.0.8" + } +} diff --git a/packages/cursorless-jetbrains/scripts/buildLocal.sh b/packages/cursorless-jetbrains/scripts/buildLocal.sh new file mode 100644 index 0000000000..353904ec6a --- /dev/null +++ b/packages/cursorless-jetbrains/scripts/buildLocal.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +npm run esbuild + +cp out/cursorless.js ../../../../cursorless/cursorless-jetbrains/src/main/resources/cursorless/ diff --git a/packages/cursorless-jetbrains/scripts/test-quickjs.sh b/packages/cursorless-jetbrains/scripts/test-quickjs.sh new file mode 100644 index 0000000000..83125aa022 --- /dev/null +++ b/packages/cursorless-jetbrains/scripts/test-quickjs.sh @@ -0,0 +1,45 @@ +#!/usr/bin/env bash +set -euo pipefail +set -euo pipefail + +QUICKJS_VERSION=2024-01-13 + +echo $ cd out +cd out + +if [[ "$OSTYPE" == "darwin"* ]]; then + brew install quickjs + # Brew doesn't actually publish different versions of the quickjs binary + # brew install quickjs@$QUICKJS_VERSION + + echo $ qjs -I quickjsTest.mjs + qjs -I quickjsTest.mjs + + exit 0 +fi + +QUICKJS_URL_WIN=https://bellard.org/quickjs/binary_releases/quickjs-win-x86_64-$QUICKJS_VERSION.zip +QUICKJS_URL_LINUX=https://bellard.org/quickjs/binary_releases/quickjs-linux-x86_64-$QUICKJS_VERSION.zip +QUICKJS_FILE=quickjs.zip + +if [[ "$OSTYPE" == "linux-gnu"* ]]; then + QUICKJS_URL=$QUICKJS_URL_LINUX +elif [[ "$OSTYPE" == "cygwin" ]]; then + QUICKJS_URL=$QUICKJS_URL_WIN +elif [[ "$OSTYPE" == "msys" ]]; then + QUICKJS_URL=$QUICKJS_URL_WIN +elif [[ "$OSTYPE" == "win32" ]]; then + QUICKJS_URL=$QUICKJS_URL_WIN +else + echo "ERROR Unsupported OS: $OSTYPE" + exit 1 +fi + +echo $ curl -o $QUICKJS_FILE $QUICKJS_URL +curl -o $QUICKJS_FILE $QUICKJS_URL + +echo $ unzip $QUICKJS_FILE +unzip $QUICKJS_FILE + +echo $ ./qjs -I cursorless.js +./qjs --module cursorless.js diff --git a/packages/cursorless-jetbrains/src/index.ts b/packages/cursorless-jetbrains/src/index.ts new file mode 100644 index 0000000000..f90bb6a68a --- /dev/null +++ b/packages/cursorless-jetbrains/src/index.ts @@ -0,0 +1,7 @@ + +import { createCursorlessEngine } from "@cursorless/cursorless-engine"; + +export function entry() { + createCursorlessEngine(); + console.log("foo") +} diff --git a/packages/cursorless-jetbrains/tsconfig.json b/packages/cursorless-jetbrains/tsconfig.json new file mode 100644 index 0000000000..ebb84f2ad6 --- /dev/null +++ b/packages/cursorless-jetbrains/tsconfig.json @@ -0,0 +1,28 @@ +{ + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "out" + }, + "references": [ + { + "path": "../common" + }, + { + "path": "../cursorless-engine" + }, + { + "path": "../neovim-common" + }, + { + "path": "../neovim-registry" + }, + { + "path": "../node-common" + }, + { + "path": "../test-case-recorder" + } + ], + "include": ["src/**/*.ts", "src/**/*.json", "../../typings/**/*.d.ts"] +} From 5f5333238c7069a94edc2fdf303d7ffd51a7d7ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 13 Nov 2024 18:08:46 +0100 Subject: [PATCH 02/39] wip --- packages/cursorless-jetbrains/package.json | 15 +- .../scripts/buildLocal.sh | 2 +- .../scripts/test-quickjs.sh | 0 .../src/ide/JetbrainsCapabilities.ts | 25 ++ .../src/ide/JetbrainsClient.ts | 3 + .../src/ide/JetbrainsCommandServer.ts | 8 + .../src/ide/JetbrainsEvents.ts | 57 +++ .../src/ide/JetbrainsIDE.ts | 328 ++++++++++++++++++ .../src/ide/JetbrainsPlugin.ts | 14 + packages/cursorless-jetbrains/src/index.ts | 26 +- pnpm-lock.yaml | 42 ++- 11 files changed, 498 insertions(+), 22 deletions(-) mode change 100644 => 100755 packages/cursorless-jetbrains/scripts/buildLocal.sh mode change 100644 => 100755 packages/cursorless-jetbrains/scripts/test-quickjs.sh create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index a7c378d9dc..5733042b9c 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -1,8 +1,8 @@ { - "name": "@cursorless/cursorless-neovim", + "name": "@cursorless/cursorless-jetbrains", "version": "1.0.0", - "description": "cursorless in neovim", - "main": "./out/index.cjs", + "description": "cursorless in jetbrains", + "main": "./out/cursorless.js", "private": true, "scripts": { "build": "pnpm run esbuild:prod && pnpm run populate-dist", @@ -14,7 +14,7 @@ "populate-dist:prod": "bash ./scripts/populate-dist.sh", "watch:tsc": "pnpm compile --watch", "watch:esbuild": "pnpm esbuild --watch", - "watch": "pnpm run --filter @cursorless/cursorless-neovim --parallel '/^watch:.*/'", + "watch": "pnpm run --filter @cursorless/cursorless-jetbrains --parallel '/^watch:.*/'", "clean": "rm -rf ./out tsconfig.tsbuildinfo ./dist ./build" }, "keywords": [], @@ -30,9 +30,6 @@ "dependencies": { "@cursorless/common": "workspace:*", "@cursorless/cursorless-engine": "workspace:*", - "@cursorless/neovim-common": "workspace:*", - "@cursorless/neovim-registry": "workspace:*", - "@cursorless/node-common": "workspace:*", "@cursorless/test-case-recorder": "workspace:*" }, "devDependencies": { @@ -40,8 +37,6 @@ "@types/js-yaml": "^4.0.9", "@types/lodash": "4.17.10", "@types/uuid": "^10.0.0", - "lodash": "^4.17.21", - "neovim": "5.3.0", - "vscode-uri": "^3.0.8" + "lodash": "^4.17.21" } } diff --git a/packages/cursorless-jetbrains/scripts/buildLocal.sh b/packages/cursorless-jetbrains/scripts/buildLocal.sh old mode 100644 new mode 100755 index 353904ec6a..a62a5a00cf --- a/packages/cursorless-jetbrains/scripts/buildLocal.sh +++ b/packages/cursorless-jetbrains/scripts/buildLocal.sh @@ -2,4 +2,4 @@ npm run esbuild -cp out/cursorless.js ../../../../cursorless/cursorless-jetbrains/src/main/resources/cursorless/ +cp out/cursorless.js ../../../cursorless-jetbrains/src/main/resources/cursorless/ diff --git a/packages/cursorless-jetbrains/scripts/test-quickjs.sh b/packages/cursorless-jetbrains/scripts/test-quickjs.sh old mode 100644 new mode 100755 diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts new file mode 100644 index 0000000000..234d51a397 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts @@ -0,0 +1,25 @@ +import type { Capabilities, CommandCapabilityMap } from "@cursorless/common"; + +const COMMAND_CAPABILITIES: CommandCapabilityMap = { + clipboardCopy: { acceptsLocation: false }, + clipboardPaste: true, + toggleLineComment: undefined, + indentLine: undefined, + outdentLine: undefined, + rename: undefined, + quickFix: undefined, + revealDefinition: undefined, + revealTypeDefinition: undefined, + showHover: undefined, + showDebugHover: undefined, + extractVariable: undefined, + fold: undefined, + highlight: { acceptsLocation: true }, + unfold: undefined, + showReferences: undefined, + insertLineAfter: undefined, +}; + +export class JetbrainsCapabilities implements Capabilities { + commands = COMMAND_CAPABILITIES; +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts new file mode 100644 index 0000000000..4aeaeab2c2 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -0,0 +1,3 @@ +export interface JetbrainsClient { + +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts new file mode 100644 index 0000000000..3b78de5e07 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts @@ -0,0 +1,8 @@ +import type { CommandServerApi} from "@cursorless/common"; +import { JetbrainsClient } from "./JetbrainsClient"; + +export class JetbrainsCommandServer implements CommandServerApi { + + + +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts new file mode 100644 index 0000000000..41a521bb41 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts @@ -0,0 +1,57 @@ +import type { + Disposable, + TextDocument, + TextDocumentChangeEvent, + TextDocumentContentChangeEvent, +} from "@cursorless/common"; +import { Position, Range } from "@cursorless/common"; + +export function jetbrainsOnDidChangeTextDocument( + listener: (event: TextDocumentChangeEvent) => void, +): Disposable { + return dummyEvent(); +} + +export function jetbrainsOnDidOpenTextDocument( + listener: (event: TextDocument) => any, + _thisArgs?: any, + _disposables?: Disposable[] | undefined, +): Disposable { + return dummyEvent(); +} + +export function fromJetbrainsContentChange( + document: TextDocument, + buffer: Buffer, + firstLine: number, + lastLine: number, + linedata: string[], +): TextDocumentContentChangeEvent[] { + const result = []; + const text = linedata.join("\n"); + console.debug( + `fromJetbrainsContentChange(): document.getText(): '${document.getText()}'`, + ); + const range = new Range( + new Position(firstLine, 0), + new Position(lastLine - 1, document.lineAt(lastLine - 1).text.length), + ); + const rangeOffset = document.offsetAt(range.start); + const rangeLength = document.offsetAt(range.end) - rangeOffset; + result.push({ + range: range, + rangeOffset: rangeOffset, + rangeLength: rangeLength, + text: text, + }); + console.debug(`fromJetbrainsContentChange(): changes=${JSON.stringify(result)}`); + return result; +} + +function dummyEvent() { + return { + dispose() { + // empty + }, + }; +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts new file mode 100644 index 0000000000..2e0dd54a23 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -0,0 +1,328 @@ +import type { + Disposable, + EditableTextEditor, + IDE, + OpenUntitledTextDocumentOptions, + Range, + RunMode, + Selection, + TextDocumentChangeEvent, + TextEditor, + WorkspaceFolder, +} from "@cursorless/common"; +import type { + Event, + FlashDescriptor, + GeneralizedRange, + QuickPickOptions, + TextDocument, + TextEditorSelectionChangeEvent, + TextEditorVisibleRangesChangeEvent, +} from "@cursorless/common"; +import { pull } from "lodash"; +// import type { Buffer, JetbrainsClient, Window } from "jetbrains"; +// import { v4 as uuid } from "uuid"; +import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; +// import JetbrainsClipboard from "./JetbrainsClipboard"; +// import JetbrainsConfiguration from "./JetbrainsConfiguration"; +// import JetbrainsKeyValueStore from "./JetbrainsKeyValueStore"; +// import JetbrainsMessages from "./JetbrainsMessages"; +// import { JetbrainsTextEditorImpl } from "./JetbrainsTextEditorImpl"; +// import path from "path"; +// import { nodeGetRunMode } from "@cursorless/node-common"; + +import { + jetbrainsOnDidChangeTextDocument, + jetbrainsOnDidOpenTextDocument, +} from "./JetbrainsEvents"; + +export class JetbrainsIDE implements IDE { +// readonly configuration: JetbrainsConfiguration; +// readonly keyValueStore: JetbrainsKeyValueStore; +// readonly messages: JetbrainsMessages; +// readonly clipboard: JetbrainsClipboard; + readonly capabilities: JetbrainsCapabilities; +// private editorMap; +// private documentMap; + private activeWindow: Window | undefined; + private activeBuffer: Buffer | undefined; + + cursorlessVersion: string = "0.0.0"; + workspaceFolders: readonly WorkspaceFolder[] | undefined = undefined; + private disposables: Disposable[] = []; + private assetsRoot_: string | undefined; + private cursorlessJetbrainsPath: string | undefined; + private quickPickReturnValue: string | undefined = undefined; + + constructor(private client: JetbrainsClient) { +// this.configuration = new JetbrainsConfiguration(); +// this.keyValueStore = new JetbrainsKeyValueStore(); +// this.messages = new JetbrainsMessages(); +// this.clipboard = new JetbrainsClipboard(this.client); + this.capabilities = new JetbrainsCapabilities(); +// this.editorMap = new Map(); +// this.documentMap = new Map(); + this.activeWindow = undefined; + this.activeBuffer = undefined; + } + + async init() { +// const rootPath = await getCursorlessNvimPath(this.client); +// // we store the assets into a subfolder of cursorless.nvim +// this.assetsRoot_ = path.join(rootPath, "assets"); +// this.cursorlessJetbrainsPath = path.join( +// rootPath, +// "node", +// "cursorless-jetbrains", +// ); + } + + async showQuickPick( + _items: readonly string[], + _options?: QuickPickOptions, + ): Promise { + throw Error("showQuickPick Not implemented"); + } + + async setHighlightRanges( + _highlightId: string | undefined, + _editor: TextEditor, + _ranges: GeneralizedRange[], + ): Promise { + throw Error("setHighlightRanges Not implemented"); + } + + async flashRanges(_flashDescriptors: FlashDescriptor[]): Promise { + console.debug("flashRanges Not implemented"); + } + + get assetsRoot(): string { + if (this.assetsRoot_ == null) { + throw Error("Field `assetsRoot` has not yet been mocked"); + } + + return this.assetsRoot_; + } + + // + get runMode(): RunMode { + return nodeGetRunMode(); + } + + get activeTextEditor(): TextEditor | undefined { + // throw Error("activeTextEditor Not implemented"); + return this.getActiveTextEditor(); + } + + get activeEditableTextEditor(): EditableTextEditor | undefined { + // throw Error("activeEditableTextEditor Not implemented"); + return this.getActiveTextEditor(); + } + + private getActiveTextEditor() { + const editor = this.activeWindow + ? this.getTextEditor(this.activeWindow) + : undefined; + if (editor === undefined) { + console.debug("getActiveTextEditor: editor is undefined"); + } + return editor; + } + + private getTextEditor(w: Window) { + for (const [window, textEditor] of this.editorMap) { + if (window.id === w.id) { + return textEditor; + } + } + return undefined; + } + + public getTextDocument(b: Buffer) { + for (const [buffer, textDocument] of this.documentMap) { + if (buffer.id === b.id) { + return textDocument; + } + } + return undefined; + } + + get visibleTextEditors(): JetbrainsTextEditorImpl[] { +// return Array.from(this.editorMap.values()); + throw Error("visibleTextEditors Not implemented"); + } + + public getEditableTextEditor(editor: TextEditor): EditableTextEditor { +// return editor as EditableTextEditor; + throw Error("getEditableTextEditor Not implemented"); + } + + public async findInDocument( + _query: string, + _editor: TextEditor, + ): Promise { + throw Error("findInDocument Not implemented"); + } + + public async findInWorkspace(_query: string): Promise { + throw Error("findInWorkspace Not implemented"); + } + + public async openTextDocument(_path: string): Promise { + throw Error("openTextDocument Not implemented"); + } + + public async openUntitledTextDocument( + _options: OpenUntitledTextDocumentOptions, + ): Promise { + throw Error("openUntitledTextDocument Not implemented"); + } + + public async showInputBox(_options?: any): Promise { + throw Error("TextDocumentChangeEvent Not implemented"); + } + + public async executeCommand( + _command: string, + ..._args: any[] + ): Promise { + throw new Error("executeCommand Method not implemented."); + } + + public onDidChangeTextDocument( + listener: (event: TextDocumentChangeEvent) => void, + ): Disposable { + return jetbrainsOnDidChangeTextDocument(listener); + } + + public onDidOpenTextDocument( + listener: (event: TextDocument) => any, + thisArgs?: any, + disposables?: Disposable[] | undefined, + ): Disposable { + return jetbrainsOnDidOpenTextDocument(listener, thisArgs, disposables); + } + onDidCloseTextDocument: Event = dummyEvent; + onDidChangeActiveTextEditor: Event = dummyEvent; + onDidChangeVisibleTextEditors: Event = dummyEvent; + onDidChangeTextEditorSelection: Event = + dummyEvent; + onDidChangeTextEditorVisibleRanges: Event = + dummyEvent; + + /** + * Initialize the current editor (and current document). + * If the current editor already exists, it will only update the current document of that editor. + * + * when we receive our first cursorless command, we will initialize an editor an document for it. + * for the following commands, we will only update the document. + * + * Atm, we only initialize one editor(current window) with one document(current buffer) + */ + async updateTextEditor( + minimal: boolean = false, + ): Promise { + const window = await this.client.window; + const buffer = await window.buffer; + const lines = await buffer.lines; + let linesShown = lines; + if (lines.length >= 30) { + linesShown = lines.slice(0, 15).concat(["..."]).concat(lines.slice(-15)); + } + console.debug( + `updateTextEditor(): window:${window.id}, buffer:${buffer.id}, lines=${JSON.stringify(linesShown)}`, + ); + let selections: Selection[]; + let visibleRanges: Range[]; + if (!minimal) { + selections = await bufferGetSelections(window, this.client); + visibleRanges = await windowGetVisibleRanges(window, this.client, lines); + } else { + selections = []; + visibleRanges = []; + } + const editor = this.toJetbrainsEditor( + window, + buffer, + lines, + visibleRanges, + selections, + ); + + getJetbrainsRegistry().emitEvent("onDidOpenTextDocument", editor.document); + + return editor; + } + + toJetbrainsEditor( + window: Window, + buffer: Buffer, + lines: string[], + visibleRanges: Range[], + selections: Selection[], + ): JetbrainsTextEditorImpl { + let document = this.getTextDocument(buffer); + let editor = this.getTextEditor(window); + if (!document) { + console.debug( + `toJetbrainsEditor(): creating new document: buffer=${buffer.id}`, + ); + document = new JetbrainsTextDocumentImpl( + URI.parse(`jetbrains://${buffer.id}`), // URI.parse(`file://${buffer.id}`), + "plaintext", + 1, + "\n", + // "\r\n", + lines, + ); + this.documentMap.set(buffer, document); + } else { + console.debug(`toJetbrainsEditor(): updating document: buffer=${buffer.id}`); + document.update(lines); + } + if (!editor) { + console.debug( + `toJetbrainsEditor(): creating new editor: window=${window.id}`, + ); + editor = new JetbrainsTextEditorImpl( + uuid(), + this.client, + this, + window, + document, + visibleRanges, + selections, + ); + this.editorMap.set(window, editor); + } else { + console.debug(`toJetbrainsEditor(): updating editor: window=${window.id}`); + editor.updateDocument(visibleRanges, selections, document); + } + this.activeBuffer = buffer; + this.activeWindow = window; + + return this.activeTextEditor as JetbrainsTextEditorImpl; + } + + handleCommandError(err: Error) { + // if (err instanceof OutdatedExtensionError) { + // this.showUpdateExtensionErrorMessage(err); + // } else { + void showErrorMessage(this.client, err.message); + // } + } + + disposeOnExit(...disposables: Disposable[]): () => void { + this.disposables.push(...disposables); + + return () => pull(this.disposables, ...disposables); + } +} + +function dummyEvent() { + return { + dispose() { + // empty + }, + }; +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts new file mode 100644 index 0000000000..4f47906265 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts @@ -0,0 +1,14 @@ +import {JetbrainsClient} from "./JetbrainsClient"; +import {JetbrainsCommandServer} from "./JetbrainsCommandServer"; + +export class JetbrainsPlugin { + readonly client: JetbrainsClient + readonly commandServer: JetbrainsCommandServer + + constructor( + private client: JetbrainsClient, + private commandServer: JetbrainsCommandServer + ) { + } + +} diff --git a/packages/cursorless-jetbrains/src/index.ts b/packages/cursorless-jetbrains/src/index.ts index f90bb6a68a..2702d15a63 100644 --- a/packages/cursorless-jetbrains/src/index.ts +++ b/packages/cursorless-jetbrains/src/index.ts @@ -1,7 +1,25 @@ - +import type { + Command, + CommandServerApi, + Hats, + IDE, + ScopeProvider, +} from "@cursorless/common"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; +import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; +import type { JetbrainsIDE } from "./ide/JetbrainsIDE"; + +export function entry(plugin: JetbrainsPlugin) { + const jetbrainsIDE = new JetbrainsIDE(plugin.client); + createCursorlessEngine({ + ide: jetbrainsIDE, + }); + console.log("entry completed"); +} -export function entry() { - createCursorlessEngine(); - console.log("foo") +export function createPlugin(client: JetbrainsClient): JetbrainsPlugin { + return new JetbrainsPlugin(client); } + +export * from "./ide/JetbrainsPlugin"; +export * from "./ide/JetbrainsIDE"; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 77e82a0fed..f26b94e788 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -45,7 +45,7 @@ importers: version: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) eslint-plugin-import: specifier: 2.31.0 - version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) eslint-plugin-mocha: specifier: 10.5.0 version: 10.5.0(eslint@8.57.1) @@ -375,6 +375,34 @@ importers: specifier: ^10.7.3 version: 10.7.3 + packages/cursorless-jetbrains: + dependencies: + '@cursorless/common': + specifier: workspace:* + version: link:../common + '@cursorless/cursorless-engine': + specifier: workspace:* + version: link:../cursorless-engine + '@cursorless/test-case-recorder': + specifier: workspace:* + version: link:../test-case-recorder + devDependencies: + '@types/chai': + specifier: ^5.0.0 + version: 5.0.0 + '@types/js-yaml': + specifier: ^4.0.9 + version: 4.0.9 + '@types/lodash': + specifier: 4.17.10 + version: 4.17.10 + '@types/uuid': + specifier: ^10.0.0 + version: 10.0.0 + lodash: + specifier: ^4.17.21 + version: 4.17.21 + packages/cursorless-neovim: dependencies: '@cursorless/common': @@ -15433,7 +15461,7 @@ snapshots: eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) eslint-plugin-jsx-a11y: 6.10.0(eslint@8.57.1) eslint-plugin-react: 7.37.1(eslint@8.57.1) eslint-plugin-react-hooks: 5.0.0-canary-7118f5dd7-20230705(eslint@8.57.1) @@ -15462,20 +15490,20 @@ snapshots: debug: 4.3.7(supports-color@8.1.1) enhanced-resolve: 5.17.1 eslint: 8.57.1 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) fast-glob: 3.3.2 get-tsconfig: 4.8.1 is-bun-module: 1.2.1 is-glob: 4.0.3 optionalDependencies: - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) transitivePeerDependencies: - '@typescript-eslint/parser' - eslint-import-resolver-node - eslint-import-resolver-webpack - supports-color - eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): + eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): dependencies: debug: 3.2.7 optionalDependencies: @@ -15486,7 +15514,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): + eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.8 @@ -15497,7 +15525,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) hasown: 2.0.2 is-core-module: 2.15.1 is-glob: 4.0.3 From bec1c52017dcf2d5782670d4ebf5ae88603c85a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 13 Nov 2024 21:59:36 +0100 Subject: [PATCH 03/39] add more jetbrains skeleton --- .../scripts/buildLocal.sh | 2 +- .../cursorless-jetbrains/src/extension.ts | 11 ++ .../src/ide/JetbrainsClipboard.ts | 14 ++ .../src/ide/JetbrainsCommandServer.ts | 2 +- .../src/ide/JetbrainsConfiguration.ts | 61 +++++++ .../src/ide/JetbrainsIDE.ts | 156 +++--------------- .../src/ide/JetbrainsKeyValueStore.ts | 22 +++ .../src/ide/JetbrainsMessages.ts | 12 ++ .../src/ide/JetbrainsPlugin.ts | 10 +- packages/cursorless-jetbrains/src/index.ts | 17 +- 10 files changed, 154 insertions(+), 153 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/extension.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsKeyValueStore.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsMessages.ts diff --git a/packages/cursorless-jetbrains/scripts/buildLocal.sh b/packages/cursorless-jetbrains/scripts/buildLocal.sh index a62a5a00cf..8982d8eeac 100755 --- a/packages/cursorless-jetbrains/scripts/buildLocal.sh +++ b/packages/cursorless-jetbrains/scripts/buildLocal.sh @@ -1,5 +1,5 @@ #!/bin/bash -npm run esbuild +npm run compile && npm run esbuild cp out/cursorless.js ../../../cursorless-jetbrains/src/main/resources/cursorless/ diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts new file mode 100644 index 0000000000..0096550328 --- /dev/null +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -0,0 +1,11 @@ +import { createCursorlessEngine } from "@cursorless/cursorless-engine"; +import { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; +import { JetbrainsIDE } from "./ide/JetbrainsIDE"; + +export function entry(plugin: JetbrainsPlugin) { + const jetbrainsIDE = new JetbrainsIDE(plugin.client); + createCursorlessEngine({ + ide: jetbrainsIDE, + }); + console.log("entry completed"); +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts new file mode 100644 index 0000000000..a08c340c42 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts @@ -0,0 +1,14 @@ +import type { Clipboard } from "@cursorless/common"; +import { JetbrainsClient } from "./JetbrainsClient" + +export class JetbrainsClipboard implements Clipboard { + constructor(private client: JetbrainsClient) {} + + async readText(): Promise { + return ""; + } + + async writeText(value: string): Promise { + return; + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts index 3b78de5e07..82bc2ac262 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts @@ -1,7 +1,7 @@ import type { CommandServerApi} from "@cursorless/common"; import { JetbrainsClient } from "./JetbrainsClient"; -export class JetbrainsCommandServer implements CommandServerApi { +export class JetbrainsCommandServer { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts new file mode 100644 index 0000000000..adbea2f11d --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts @@ -0,0 +1,61 @@ + +import { HatStability } from "@cursorless/common"; +import { get } from "lodash"; +import type { + Configuration, + ConfigurationScope, + CursorlessConfiguration, +} from "@cursorless/common"; +import { CONFIGURATION_DEFAULTS } from "@cursorless/common"; +import type { GetFieldType, Paths } from "@cursorless/common"; +import { Notifier } from "@cursorless/common"; + +export class JetbrainsConfiguration implements Configuration { + private notifier = new Notifier(); + + constructor() { + + } + + getOwnConfiguration>( + path: Path, + scope?: ConfigurationScope, + ): GetFieldType { + return get(CONFIGURATION_DEFAULTS, path) as GetFieldType< + CursorlessConfiguration, + Path + >; + } + + onDidChangeConfiguration = this.notifier.registerListener; +} + +/** + * Gets a configuration value from jetbrains, with supported variables expanded. + * For example, `${userHome}` will be expanded to the user's home directory. + * + * We currently only support `${userHome}`. + * + * @param path The path to the configuration value, eg `cursorless.snippetsDir` + * @returns The configuration value, with variables expanded, or undefined if + * the value is not set + */ +export function jetbrainsGetConfigurationString(path: string): string | undefined { + const index = path.lastIndexOf("."); + const section = path.substring(0, index); + const field = path.substring(index + 1); +// const value = "jetbrains.workspace.getConfiguration(section).get(field)"; +// return value != null ? evaluateStringVariables(value) : undefined; + return undefined +} + +function evaluateStringVariables(value: string): string { + return value.replace(/\${(\w+)}/g, (match, variable) => { + switch (variable) { + case "userHome": + return "~/"; + default: + throw Error(`Unknown jetbrains configuration variable '${variable}'`); + } + }); +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 2e0dd54a23..1156e106cb 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -36,11 +36,17 @@ import { jetbrainsOnDidOpenTextDocument, } from "./JetbrainsEvents"; +import { JetbrainsClient } from "./JetbrainsClient" +import { JetbrainsClipboard } from "./JetbrainsClipboard" +import { JetbrainsConfiguration } from "./JetbrainsConfiguration" +import { JetbrainsMessages } from "./JetbrainsMessages" +import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore" + export class JetbrainsIDE implements IDE { -// readonly configuration: JetbrainsConfiguration; -// readonly keyValueStore: JetbrainsKeyValueStore; -// readonly messages: JetbrainsMessages; -// readonly clipboard: JetbrainsClipboard; + readonly configuration: JetbrainsConfiguration; + readonly keyValueStore: JetbrainsKeyValueStore; + readonly messages: JetbrainsMessages; + readonly clipboard: JetbrainsClipboard; readonly capabilities: JetbrainsCapabilities; // private editorMap; // private documentMap; @@ -55,10 +61,10 @@ export class JetbrainsIDE implements IDE { private quickPickReturnValue: string | undefined = undefined; constructor(private client: JetbrainsClient) { -// this.configuration = new JetbrainsConfiguration(); -// this.keyValueStore = new JetbrainsKeyValueStore(); -// this.messages = new JetbrainsMessages(); -// this.clipboard = new JetbrainsClipboard(this.client); + this.configuration = new JetbrainsConfiguration(); + this.keyValueStore = new JetbrainsKeyValueStore(); + this.messages = new JetbrainsMessages(); + this.clipboard = new JetbrainsClipboard(this.client); this.capabilities = new JetbrainsCapabilities(); // this.editorMap = new Map(); // this.documentMap = new Map(); @@ -106,48 +112,22 @@ export class JetbrainsIDE implements IDE { // get runMode(): RunMode { - return nodeGetRunMode(); + return "production"; } get activeTextEditor(): TextEditor | undefined { - // throw Error("activeTextEditor Not implemented"); - return this.getActiveTextEditor(); + throw Error("activeTextEditor Not implemented"); +// return this.getActiveTextEditor(); } get activeEditableTextEditor(): EditableTextEditor | undefined { - // throw Error("activeEditableTextEditor Not implemented"); - return this.getActiveTextEditor(); + throw Error("activeEditableTextEditor Not implemented"); +// return this.getActiveTextEditor(); } - private getActiveTextEditor() { - const editor = this.activeWindow - ? this.getTextEditor(this.activeWindow) - : undefined; - if (editor === undefined) { - console.debug("getActiveTextEditor: editor is undefined"); - } - return editor; - } - - private getTextEditor(w: Window) { - for (const [window, textEditor] of this.editorMap) { - if (window.id === w.id) { - return textEditor; - } - } - return undefined; - } - public getTextDocument(b: Buffer) { - for (const [buffer, textDocument] of this.documentMap) { - if (buffer.id === b.id) { - return textDocument; - } - } - return undefined; - } - get visibleTextEditors(): JetbrainsTextEditorImpl[] { + get visibleTextEditors(): EditableTextEditor[] { // return Array.from(this.editorMap.values()); throw Error("visibleTextEditors Not implemented"); } @@ -210,105 +190,11 @@ export class JetbrainsIDE implements IDE { onDidChangeTextEditorVisibleRanges: Event = dummyEvent; - /** - * Initialize the current editor (and current document). - * If the current editor already exists, it will only update the current document of that editor. - * - * when we receive our first cursorless command, we will initialize an editor an document for it. - * for the following commands, we will only update the document. - * - * Atm, we only initialize one editor(current window) with one document(current buffer) - */ - async updateTextEditor( - minimal: boolean = false, - ): Promise { - const window = await this.client.window; - const buffer = await window.buffer; - const lines = await buffer.lines; - let linesShown = lines; - if (lines.length >= 30) { - linesShown = lines.slice(0, 15).concat(["..."]).concat(lines.slice(-15)); - } - console.debug( - `updateTextEditor(): window:${window.id}, buffer:${buffer.id}, lines=${JSON.stringify(linesShown)}`, - ); - let selections: Selection[]; - let visibleRanges: Range[]; - if (!minimal) { - selections = await bufferGetSelections(window, this.client); - visibleRanges = await windowGetVisibleRanges(window, this.client, lines); - } else { - selections = []; - visibleRanges = []; - } - const editor = this.toJetbrainsEditor( - window, - buffer, - lines, - visibleRanges, - selections, - ); - - getJetbrainsRegistry().emitEvent("onDidOpenTextDocument", editor.document); - - return editor; - } - - toJetbrainsEditor( - window: Window, - buffer: Buffer, - lines: string[], - visibleRanges: Range[], - selections: Selection[], - ): JetbrainsTextEditorImpl { - let document = this.getTextDocument(buffer); - let editor = this.getTextEditor(window); - if (!document) { - console.debug( - `toJetbrainsEditor(): creating new document: buffer=${buffer.id}`, - ); - document = new JetbrainsTextDocumentImpl( - URI.parse(`jetbrains://${buffer.id}`), // URI.parse(`file://${buffer.id}`), - "plaintext", - 1, - "\n", - // "\r\n", - lines, - ); - this.documentMap.set(buffer, document); - } else { - console.debug(`toJetbrainsEditor(): updating document: buffer=${buffer.id}`); - document.update(lines); - } - if (!editor) { - console.debug( - `toJetbrainsEditor(): creating new editor: window=${window.id}`, - ); - editor = new JetbrainsTextEditorImpl( - uuid(), - this.client, - this, - window, - document, - visibleRanges, - selections, - ); - this.editorMap.set(window, editor); - } else { - console.debug(`toJetbrainsEditor(): updating editor: window=${window.id}`); - editor.updateDocument(visibleRanges, selections, document); - } - this.activeBuffer = buffer; - this.activeWindow = window; - - return this.activeTextEditor as JetbrainsTextEditorImpl; - } - handleCommandError(err: Error) { // if (err instanceof OutdatedExtensionError) { // this.showUpdateExtensionErrorMessage(err); // } else { - void showErrorMessage(this.client, err.message); +// void showErrorMessage(this.client, err.message); // } } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsKeyValueStore.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsKeyValueStore.ts new file mode 100644 index 0000000000..ca94a2675f --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsKeyValueStore.ts @@ -0,0 +1,22 @@ +import type { + KeyValueStore, + KeyValueStoreData, + KeyValueStoreKey, +} from "@cursorless/common"; +import { KEY_VALUE_STORE_DEFAULTS } from "@cursorless/common"; + +export class JetbrainsKeyValueStore implements KeyValueStore { + private readonly data: KeyValueStoreData = { ...KEY_VALUE_STORE_DEFAULTS }; + + get(key: K): KeyValueStoreData[K] { + return this.data[key]; + } + + set( + key: K, + value: KeyValueStoreData[K], + ): Promise { + this.data[key] = value; + return Promise.resolve(); + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsMessages.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsMessages.ts new file mode 100644 index 0000000000..ac2b77781c --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsMessages.ts @@ -0,0 +1,12 @@ +import type { MessageId, Messages, MessageType } from "@cursorless/common"; + +export class JetbrainsMessages implements Messages { + async showMessage( + _type: MessageType, + _id: MessageId, + _message: string, + ..._options: string[] + ): Promise { + return undefined; + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts index 4f47906265..285090a731 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts @@ -2,13 +2,15 @@ import {JetbrainsClient} from "./JetbrainsClient"; import {JetbrainsCommandServer} from "./JetbrainsCommandServer"; export class JetbrainsPlugin { - readonly client: JetbrainsClient - readonly commandServer: JetbrainsCommandServer constructor( - private client: JetbrainsClient, - private commandServer: JetbrainsCommandServer + readonly client: JetbrainsClient, + readonly commandServer: JetbrainsCommandServer ) { } } + +export function createPlugin(client: JetbrainsClient, commandServer: JetbrainsCommandServer): JetbrainsPlugin { + return new JetbrainsPlugin(client, commandServer) +} diff --git a/packages/cursorless-jetbrains/src/index.ts b/packages/cursorless-jetbrains/src/index.ts index 2702d15a63..96cf006b39 100644 --- a/packages/cursorless-jetbrains/src/index.ts +++ b/packages/cursorless-jetbrains/src/index.ts @@ -9,17 +9,10 @@ import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import type { JetbrainsIDE } from "./ide/JetbrainsIDE"; -export function entry(plugin: JetbrainsPlugin) { - const jetbrainsIDE = new JetbrainsIDE(plugin.client); - createCursorlessEngine({ - ide: jetbrainsIDE, - }); - console.log("entry completed"); -} - -export function createPlugin(client: JetbrainsClient): JetbrainsPlugin { - return new JetbrainsPlugin(client); -} - export * from "./ide/JetbrainsPlugin"; export * from "./ide/JetbrainsIDE"; +export * from "./extension"; + + + + From 471c428b7c55d3e7bdf83ac7c87df3f7e1f6490c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 16 Nov 2024 08:41:01 +0100 Subject: [PATCH 04/39] wip --- .../scripts/esbuild.sh | 4 +-- packages/cursorless-jetbrains/package.json | 2 +- .../cursorless-jetbrains/src/extension.ts | 8 ++++-- .../src/ide/JetbrainsPlugin.ts | 4 +-- packages/cursorless-jetbrains/src/index.ts | 11 -------- packages/cursorless-jetbrains/src/polyfill.ts | 25 +++++++++++++++++++ packages/cursorless-jetbrains/tsconfig.json | 1 + 7 files changed, 37 insertions(+), 18 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/polyfill.ts diff --git a/packages/cursorless-everywhere-talon/scripts/esbuild.sh b/packages/cursorless-everywhere-talon/scripts/esbuild.sh index b428a9b5a3..ebbf79c1ee 100755 --- a/packages/cursorless-everywhere-talon/scripts/esbuild.sh +++ b/packages/cursorless-everywhere-talon/scripts/esbuild.sh @@ -4,12 +4,12 @@ set -euo pipefail esbuild \ --outfile=out/talon.js \ --platform=neutral \ - --format=cjs \ + --format=esm \ --main-fields=main,module \ --conditions=cursorless:bundler \ --bundle \ --sourcemap \ - --external:std \ + --external:talon \ "$@" # FIXME: Talon javascript files needs to start with an import from Talon before any other code diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 5733042b9c..f4e27a2dad 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -7,7 +7,7 @@ "scripts": { "build": "pnpm run esbuild:prod && pnpm run populate-dist", "compile": "tsc --build", - "esbuild:base": "esbuild ./src/index.ts --format=esm --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=node --external:std", + "esbuild:base": "esbuild ./src/index.ts --format=esm --target=es2020 --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=neutral --external:std", "esbuild": "pnpm run esbuild:base --sourcemap", "esbuild:prod": "pnpm run esbuild:base --minify", "populate-dist": "bash ./scripts/populate-dist.sh", diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 0096550328..3ad19edf8a 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -1,11 +1,15 @@ +import "./polyfill"; + +import type { CursorlessEngine } from "@cursorless/cursorless-engine"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import { JetbrainsIDE } from "./ide/JetbrainsIDE"; -export function entry(plugin: JetbrainsPlugin) { +export async function activate(plugin: JetbrainsPlugin): Promise { const jetbrainsIDE = new JetbrainsIDE(plugin.client); - createCursorlessEngine({ + const engine = await createCursorlessEngine({ ide: jetbrainsIDE, }); + return engine console.log("entry completed"); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts index 285090a731..c619fed530 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts @@ -1,5 +1,5 @@ -import {JetbrainsClient} from "./JetbrainsClient"; -import {JetbrainsCommandServer} from "./JetbrainsCommandServer"; +import type {JetbrainsClient} from "./JetbrainsClient"; +import type {JetbrainsCommandServer} from "./JetbrainsCommandServer"; export class JetbrainsPlugin { diff --git a/packages/cursorless-jetbrains/src/index.ts b/packages/cursorless-jetbrains/src/index.ts index 96cf006b39..0ccc15ecd3 100644 --- a/packages/cursorless-jetbrains/src/index.ts +++ b/packages/cursorless-jetbrains/src/index.ts @@ -1,14 +1,3 @@ -import type { - Command, - CommandServerApi, - Hats, - IDE, - ScopeProvider, -} from "@cursorless/common"; -import { createCursorlessEngine } from "@cursorless/cursorless-engine"; -import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; -import type { JetbrainsIDE } from "./ide/JetbrainsIDE"; - export * from "./ide/JetbrainsPlugin"; export * from "./ide/JetbrainsIDE"; export * from "./extension"; diff --git a/packages/cursorless-jetbrains/src/polyfill.ts b/packages/cursorless-jetbrains/src/polyfill.ts new file mode 100644 index 0000000000..f165d08d6e --- /dev/null +++ b/packages/cursorless-jetbrains/src/polyfill.ts @@ -0,0 +1,25 @@ +const global = globalThis as any; + +// process.env is used by `immer` +if (global.process == null) { + global.process = { + env: {}, + }; +} + +// Allows us to use `console.*` with quickjs +// if (typeof print !== "undefined") { +// global.console = { +// log: print, +// error: print, +// warn: print, +// debug: print, +// }; +// } + +// In quickjs `setTimeout` is not available. +// FIXME: Remove dependency on `setTimeout` in the future. +// https://github.com/cursorless-dev/cursorless/issues/2596 +global.setTimeout = (callback: () => void, _delay: number) => { + callback(); +}; diff --git a/packages/cursorless-jetbrains/tsconfig.json b/packages/cursorless-jetbrains/tsconfig.json index ebb84f2ad6..0ac9478318 100644 --- a/packages/cursorless-jetbrains/tsconfig.json +++ b/packages/cursorless-jetbrains/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "../../tsconfig.base.json", "compilerOptions": { + "target": "ES2020", "rootDir": "src", "outDir": "out" }, From 70fc65386cc68e60d76450ad04bd41e115e7379e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Mon, 18 Nov 2024 06:32:07 +0100 Subject: [PATCH 05/39] wip --- packages/cursorless-jetbrains/src/extension.ts | 8 +++++--- packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 8 -------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 3ad19edf8a..cb121c0da5 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -5,11 +5,13 @@ import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import { JetbrainsIDE } from "./ide/JetbrainsIDE"; -export async function activate(plugin: JetbrainsPlugin): Promise { +export async function activate( + plugin: JetbrainsPlugin, +): Promise { const jetbrainsIDE = new JetbrainsIDE(plugin.client); const engine = await createCursorlessEngine({ ide: jetbrainsIDE, }); - return engine - console.log("entry completed"); + return engine; + console.log("activate completed"); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 1156e106cb..b7a2efbcb5 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -73,14 +73,6 @@ export class JetbrainsIDE implements IDE { } async init() { -// const rootPath = await getCursorlessNvimPath(this.client); -// // we store the assets into a subfolder of cursorless.nvim -// this.assetsRoot_ = path.join(rootPath, "assets"); -// this.cursorlessJetbrainsPath = path.join( -// rootPath, -// "node", -// "cursorless-jetbrains", -// ); } async showQuickPick( From f15e88f3185eb539fee86338db3c1c09d049f17b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 23 Nov 2024 20:14:55 +0100 Subject: [PATCH 06/39] first working hats with javet --- packages/cursorless-jetbrains/package.json | 3 +- .../cursorless-jetbrains/src/extension.ts | 8 +- .../src/ide/JetbrainsClient.ts | 3 +- .../src/ide/JetbrainsEvents.ts | 5 +- .../src/ide/JetbrainsHats.ts | 71 +++++++++ .../src/ide/JetbrainsIDE.ts | 147 +++++++++++++----- .../src/ide/JetbrainsPlugin.ts | 21 +-- 7 files changed, 201 insertions(+), 57 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index f4e27a2dad..00d563424d 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -30,7 +30,8 @@ "dependencies": { "@cursorless/common": "workspace:*", "@cursorless/cursorless-engine": "workspace:*", - "@cursorless/test-case-recorder": "workspace:*" + "@cursorless/test-case-recorder": "workspace:*", + "vscode-uri": "^3.0.8" }, "devDependencies": { "@types/chai": "^5.0.0", diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index cb121c0da5..ec6305c19c 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -1,16 +1,14 @@ -import "./polyfill"; - import type { CursorlessEngine } from "@cursorless/cursorless-engine"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; -import { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; +import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import { JetbrainsIDE } from "./ide/JetbrainsIDE"; export async function activate( plugin: JetbrainsPlugin, ): Promise { - const jetbrainsIDE = new JetbrainsIDE(plugin.client); const engine = await createCursorlessEngine({ - ide: jetbrainsIDE, + ide: plugin.ide, + hats: plugin.hats, }); return engine; console.log("activate completed"); diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 4aeaeab2c2..1f99512bc1 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -1,3 +1,4 @@ export interface JetbrainsClient { - + hatsUpdated(hatsJson: string): void; + documentUpdated(updateJson: string): void; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts index 41a521bb41..690d10858e 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts @@ -22,7 +22,6 @@ export function jetbrainsOnDidOpenTextDocument( export function fromJetbrainsContentChange( document: TextDocument, - buffer: Buffer, firstLine: number, lastLine: number, linedata: string[], @@ -44,7 +43,9 @@ export function fromJetbrainsContentChange( rangeLength: rangeLength, text: text, }); - console.debug(`fromJetbrainsContentChange(): changes=${JSON.stringify(result)}`); + console.debug( + `fromJetbrainsContentChange(): changes=${JSON.stringify(result)}`, + ); return result; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts new file mode 100644 index 0000000000..c63095ae17 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -0,0 +1,71 @@ +import type { + Disposable, + HatRange, + Hats, + HatStyleMap, + Listener, +} from "@cursorless/common"; +import { Notifier } from "@cursorless/common"; +import type { JetbrainsClient } from "./JetbrainsClient"; +import { JetbrainsHatRange } from "../types/jetbrains.types"; + +const HAT_COLORS = [ + "default", + "blue", + "green", + "red", + "pink", + "yellow", +] as const; + +export class JetbrainsHats implements Hats { + private isEnabledNotifier: Notifier<[boolean]> = new Notifier(); + private hatRanges: HatRange[] = []; + private client: JetbrainsClient; + + constructor(client: JetbrainsClient) { + this.client = client; + } + + setHatRanges(hatRanges: HatRange[]): Promise { + console.log("ASOEE/CL: JetbrainsHats.setHatRanges : " + hatRanges.length); + + this.hatRanges = hatRanges; + const jbHatRanges = this.toJetbransHatRanges(hatRanges); + const hatsJson = JSON.stringify(jbHatRanges); + console.log("ASOEE/CL: JetbrainsHats.setHatRanges json: " + hatsJson); + this.client.hatsUpdated(hatsJson); + return Promise.resolve(); + } + + toJetbransHatRanges(hatRanges: HatRange[]): JetbrainsHatRange[] { + return hatRanges.map((range) => { + return { + styleName: range.styleName, + editorId: range.editor.id, + range: range.range, + }; + }); + } + + enabledHatStyles: HatStyleMap = Object.fromEntries( + HAT_COLORS.map((color) => [ + color, + { penalty: color === "default" ? 0 : 1 }, + ]), + ); + + onDidChangeEnabledHatStyles(_listener: Listener<[HatStyleMap]>): Disposable { + return { dispose: () => {} }; + } + + isEnabled: boolean = true; + onDidChangeIsEnabled(_listener: Listener<[boolean]>): Disposable { + return { dispose: () => {} }; + } + + toggle(isEnabled?: boolean) { + this.isEnabled = isEnabled ?? !this.isEnabled; + this.isEnabledNotifier.notifyListeners(this.isEnabled); + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index b7a2efbcb5..82863a6932 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -1,11 +1,11 @@ -import type { +import { Disposable, EditableTextEditor, IDE, + InMemoryTextDocument, + Notifier, OpenUntitledTextDocumentOptions, - Range, RunMode, - Selection, TextDocumentChangeEvent, TextEditor, WorkspaceFolder, @@ -16,6 +16,7 @@ import type { GeneralizedRange, QuickPickOptions, TextDocument, + TextDocumentContentChangeEvent, TextEditorSelectionChangeEvent, TextEditorVisibleRangesChangeEvent, } from "@cursorless/common"; @@ -32,15 +33,19 @@ import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; // import { nodeGetRunMode } from "@cursorless/node-common"; import { - jetbrainsOnDidChangeTextDocument, + fromJetbrainsContentChange, jetbrainsOnDidOpenTextDocument, } from "./JetbrainsEvents"; -import { JetbrainsClient } from "./JetbrainsClient" -import { JetbrainsClipboard } from "./JetbrainsClipboard" -import { JetbrainsConfiguration } from "./JetbrainsConfiguration" -import { JetbrainsMessages } from "./JetbrainsMessages" -import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore" +import type { JetbrainsClient } from "./JetbrainsClient"; +import { JetbrainsClipboard } from "./JetbrainsClipboard"; +import { JetbrainsConfiguration } from "./JetbrainsConfiguration"; +import { JetbrainsMessages } from "./JetbrainsMessages"; +import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore"; +import type { EditorState } from "../types/types"; +import { URI } from "vscode-uri"; +import { createTextEditor } from "./createTextEditor"; +import { JetbrainsEditor } from "./JetbrainsEditor"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -48,32 +53,39 @@ export class JetbrainsIDE implements IDE { readonly messages: JetbrainsMessages; readonly clipboard: JetbrainsClipboard; readonly capabilities: JetbrainsCapabilities; -// private editorMap; -// private documentMap; + readonly runMode: RunMode = "development"; + // private editorMap; + // private documentMap; private activeWindow: Window | undefined; private activeBuffer: Buffer | undefined; - cursorlessVersion: string = "0.0.0"; - workspaceFolders: readonly WorkspaceFolder[] | undefined = undefined; private disposables: Disposable[] = []; private assetsRoot_: string | undefined; private cursorlessJetbrainsPath: string | undefined; private quickPickReturnValue: string | undefined = undefined; + private editors: EditableTextEditor[] = []; + + private onDidChangeTextDocumentNotifier: Notifier<[TextDocumentChangeEvent]> = + new Notifier(); + + private onDidChangeTextDocumentContentNotifier: Notifier< + [TextDocumentContentChangeEvent] + > = new Notifier(); + constructor(private client: JetbrainsClient) { this.configuration = new JetbrainsConfiguration(); this.keyValueStore = new JetbrainsKeyValueStore(); this.messages = new JetbrainsMessages(); this.clipboard = new JetbrainsClipboard(this.client); this.capabilities = new JetbrainsCapabilities(); -// this.editorMap = new Map(); -// this.documentMap = new Map(); + // this.editorMap = new Map(); + // this.documentMap = new Map(); this.activeWindow = undefined; this.activeBuffer = undefined; } - async init() { - } + async init() {} async showQuickPick( _items: readonly string[], @@ -95,38 +107,42 @@ export class JetbrainsIDE implements IDE { } get assetsRoot(): string { - if (this.assetsRoot_ == null) { - throw Error("Field `assetsRoot` has not yet been mocked"); - } + console.log("get assetsRoot"); + throw new Error("assetsRoot not implemented."); + } - return this.assetsRoot_; + get cursorlessVersion(): string { + console.log("get cursorlessVersion"); + throw new Error("cursorlessVersion not implemented."); } - // - get runMode(): RunMode { - return "production"; + get workspaceFolders(): readonly WorkspaceFolder[] | undefined { + console.log("get workspaceFolders"); + throw new Error("workspaceFolders not implemented."); } get activeTextEditor(): TextEditor | undefined { - throw Error("activeTextEditor Not implemented"); -// return this.getActiveTextEditor(); + console.log("get activeEditableTextEditor"); + return this.activeEditableTextEditor; } get activeEditableTextEditor(): EditableTextEditor | undefined { - throw Error("activeEditableTextEditor Not implemented"); -// return this.getActiveTextEditor(); + console.log("get activeEditableTextEditor"); + return this.editors[0]; } - - - get visibleTextEditors(): EditableTextEditor[] { -// return Array.from(this.editorMap.values()); - throw Error("visibleTextEditors Not implemented"); + get visibleTextEditors(): TextEditor[] { + console.log("get activeEditableTextEditor"); + return this.editors; } - public getEditableTextEditor(editor: TextEditor): EditableTextEditor { -// return editor as EditableTextEditor; - throw Error("getEditableTextEditor Not implemented"); + getEditableTextEditor(editor: TextEditor): EditableTextEditor { + console.log("getEditableTextEditor"); + if (editor instanceof JetbrainsEditor) { + console.log("getEditableTextEditor - return current"); + return editor; + } + throw Error(`Unsupported text editor type: ${editor}`); } public async findInDocument( @@ -164,7 +180,7 @@ export class JetbrainsIDE implements IDE { public onDidChangeTextDocument( listener: (event: TextDocumentChangeEvent) => void, ): Disposable { - return jetbrainsOnDidChangeTextDocument(listener); + return this.onDidChangeTextDocumentNotifier.registerListener(listener); } public onDidOpenTextDocument( @@ -182,11 +198,11 @@ export class JetbrainsIDE implements IDE { onDidChangeTextEditorVisibleRanges: Event = dummyEvent; - handleCommandError(err: Error) { + handleCommandError(_err: Error) { // if (err instanceof OutdatedExtensionError) { // this.showUpdateExtensionErrorMessage(err); // } else { -// void showErrorMessage(this.client, err.message); + // void showErrorMessage(this.client, err.message); // } } @@ -195,6 +211,55 @@ export class JetbrainsIDE implements IDE { return () => pull(this.disposables, ...disposables); } + + public documentChanged(editorStateJson: any) { + console.log( + "ASOEE/CL: documentChanged : " + JSON.stringify(editorStateJson), + ); + const editorState = editorStateJson as EditorState; + + this.updateTextEditors(editorState); + + const uri = URI.parse("jetbrains://" + editorState); + const language = editorState.languageId + ? editorState.languageId + : "plaintext"; + const document = new InMemoryTextDocument(uri, language, editorState.text); + const linedata = getLines( + editorState.text, + editorState.firstVisibleLine, + editorState.lastVisibleLine, + ); + const contentChangeEvents = fromJetbrainsContentChange( + document, + editorState.firstVisibleLine, + editorState.lastVisibleLine, + linedata, + ); + const documentChangeEvent: TextDocumentChangeEvent = { + document: document, + contentChanges: contentChangeEvents, + }; + console.log("ASOEE/CL: documentChanged : notify..."); + this.emitDidChangeTextDocument(documentChangeEvent); + console.log("ASOEE/CL: documentChanged : notify complete"); + } + + emitDidChangeTextDocument(event: TextDocumentChangeEvent) { + this.onDidChangeTextDocumentNotifier.notifyListeners(event); + } + + updateTextEditors(editorState: EditorState) { + this.editors = [createTextEditor(this.client, this, editorState)]; + console.log( + "ASOEE/CL: updated editor with document " + editorState.firstVisibleLine, + ); + } +} + +function getLines(text: string, firstLine: number, lastLine: number) { + const lines = text.split("\n"); + return lines.slice(firstLine, lastLine); } function dummyEvent() { @@ -204,3 +269,7 @@ function dummyEvent() { }, }; } + +export function createIDE(client: JetbrainsClient) { + return new JetbrainsIDE(client); +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts index c619fed530..5cdc1f1f0f 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsPlugin.ts @@ -1,16 +1,19 @@ -import type {JetbrainsClient} from "./JetbrainsClient"; -import type {JetbrainsCommandServer} from "./JetbrainsCommandServer"; +import type { JetbrainsClient } from "./JetbrainsClient"; +import { JetbrainsHats } from "./JetbrainsHats"; +import type { JetbrainsIDE } from "./JetbrainsIDE"; export class JetbrainsPlugin { - constructor( readonly client: JetbrainsClient, - readonly commandServer: JetbrainsCommandServer - ) { - } - + readonly ide: JetbrainsIDE, + readonly hats: JetbrainsHats, + ) {} } -export function createPlugin(client: JetbrainsClient, commandServer: JetbrainsCommandServer): JetbrainsPlugin { - return new JetbrainsPlugin(client, commandServer) +export function createPlugin( + client: JetbrainsClient, + ide: JetbrainsIDE, +): JetbrainsPlugin { + const hats = new JetbrainsHats(client); + return new JetbrainsPlugin(client, ide, hats); } From d2f1bf91d09bee8f4fcbb6bc875a53ee5009d061 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 27 Nov 2024 06:19:49 +0100 Subject: [PATCH 07/39] add setSelection callback --- packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts | 1 + packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 1f99512bc1..44fc6d80e2 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -1,4 +1,5 @@ export interface JetbrainsClient { hatsUpdated(hatsJson: string): void; documentUpdated(updateJson: string): void; + setSelection(editorId: string, selectionJson: string): void; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index c63095ae17..a1fab1384a 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -33,7 +33,7 @@ export class JetbrainsHats implements Hats { this.hatRanges = hatRanges; const jbHatRanges = this.toJetbransHatRanges(hatRanges); const hatsJson = JSON.stringify(jbHatRanges); - console.log("ASOEE/CL: JetbrainsHats.setHatRanges json: " + hatsJson); + // console.log("ASOEE/CL: JetbrainsHats.setHatRanges json: " + hatsJson); this.client.hatsUpdated(hatsJson); return Promise.resolve(); } From e325e62642b61ba685b5bfdb35520baeb38f4b75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 27 Nov 2024 06:22:02 +0100 Subject: [PATCH 08/39] add missing files --- .../src/ide/JetbrainsEditor.ts | 161 ++++++++++++++++++ .../src/ide/createTextEditor.ts | 52 ++++++ .../src/ide/jetbrainsPerformEdits.ts | 32 ++++ .../src/ide/setSelections.ts | 19 +++ .../src/testing/JetbrainsTesthelpers.ts | 22 +++ .../src/types/jetbrains.types.ts | 91 ++++++++++ .../cursorless-jetbrains/src/types/types.ts | 42 +++++ 7 files changed, 419 insertions(+) create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts create mode 100644 packages/cursorless-jetbrains/src/ide/createTextEditor.ts create mode 100644 packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts create mode 100644 packages/cursorless-jetbrains/src/ide/setSelections.ts create mode 100644 packages/cursorless-jetbrains/src/testing/JetbrainsTesthelpers.ts create mode 100644 packages/cursorless-jetbrains/src/types/jetbrains.types.ts create mode 100644 packages/cursorless-jetbrains/src/types/types.ts diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts new file mode 100644 index 0000000000..d8fc726b8e --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -0,0 +1,161 @@ +import { + selectionsEqual, + type BreakpointDescriptor, + type Edit, + type EditableTextEditor, + type InMemoryTextDocument, + type OpenLinkOptions, + type Range, + type RevealLineAt, + type Selection, + type SetSelectionsOpts, + type TextEditor, + type TextEditorOptions, +} from "@cursorless/common"; +import { setSelections } from "./setSelections"; +import type { JetbrainsIDE } from "./JetbrainsIDE"; +import { jetbrainsPerformEdits } from "./jetbrainsPerformEdits"; +import type { JetbrainsClient } from "./JetbrainsClient"; + +export class JetbrainsEditor implements EditableTextEditor { + options: TextEditorOptions = { + tabSize: 4, + insertSpaces: true, + }; + + isActive = true; + + constructor( + private client: JetbrainsClient, + private ide: JetbrainsIDE, + public id: string, + public document: InMemoryTextDocument, + public visibleRanges: Range[], + public selections: Selection[], + ) {} + + isEqual(other: TextEditor): boolean { + return this.id === other.id; + } + + async setSelections( + selections: Selection[], + _opts?: SetSelectionsOpts, + ): Promise { + console.log("editor.setSelections"); + if (!selectionsEqual(this.selections, selections)) { + await setSelections(this.client, this.document, this.id, selections); + this.selections = selections; + } + } + + edit(edits: Edit[]): Promise { + console.log("editor.edit"); + jetbrainsPerformEdits(this.client, this.ide, this.document, edits); + return Promise.resolve(true); + } + + async clipboardCopy(_ranges: Range[]): Promise { + throw Error("clipboardCopy not implemented."); + } + + async clipboardPaste(): Promise { + throw Error("clipboardPaste not implemented."); + } + + indentLine(_ranges: Range[]): Promise { + throw Error("indentLine not implemented."); + } + + outdentLine(_ranges: Range[]): Promise { + throw Error("outdentLine not implemented."); + } + + insertLineAfter(_ranges?: Range[]): Promise { + throw Error("insertLineAfter not implemented."); + } + + focus(): Promise { + throw new Error("focus not implemented."); + } + + revealRange(_range: Range): Promise { + return Promise.resolve(); + } + + revealLine(_lineNumber: number, _at: RevealLineAt): Promise { + throw new Error("revealLine not implemented."); + } + + openLink( + _range: Range, + _options?: OpenLinkOptions | undefined, + ): Promise { + throw new Error("openLink not implemented."); + } + + fold(_ranges?: Range[] | undefined): Promise { + throw new Error("fold not implemented."); + } + + unfold(_ranges?: Range[] | undefined): Promise { + throw new Error("unfold not implemented."); + } + + toggleBreakpoint( + _descriptors?: BreakpointDescriptor[] | undefined, + ): Promise { + throw new Error("toggleBreakpoint not implemented."); + } + + toggleLineComment(_ranges?: Range[] | undefined): Promise { + throw new Error("toggleLineComment not implemented."); + } + + insertSnippet( + _snippet: string, + _ranges?: Range[] | undefined, + ): Promise { + throw new Error("insertSnippet not implemented."); + } + + rename(_range?: Range | undefined): Promise { + throw new Error("rename not implemented."); + } + + showReferences(_range?: Range | undefined): Promise { + throw new Error("showReferences not implemented."); + } + + quickFix(_range?: Range | undefined): Promise { + throw new Error("quickFix not implemented."); + } + + revealDefinition(_range?: Range | undefined): Promise { + throw new Error("revealDefinition not implemented."); + } + + revealTypeDefinition(_range?: Range | undefined): Promise { + throw new Error("revealTypeDefinition not implemented."); + } + + showHover(_range?: Range | undefined): Promise { + throw new Error("showHover not implemented."); + } + + showDebugHover(_range?: Range | undefined): Promise { + throw new Error("showDebugHover not implemented."); + } + + extractVariable(_range?: Range | undefined): Promise { + throw new Error("extractVariable not implemented."); + } + + editNewNotebookCellAbove(): Promise<(_selection: Selection) => Selection> { + throw new Error("editNewNotebookCellAbove not implemented."); + } + + editNewNotebookCellBelow(): Promise { + throw new Error("editNewNotebookCellBelow not implemented."); + } +} diff --git a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts new file mode 100644 index 0000000000..18530ee606 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts @@ -0,0 +1,52 @@ +import { + InMemoryTextDocument, + Position, + Selection, + type TextDocument, +} from "@cursorless/common"; +import { URI } from "vscode-uri"; +import type { EditorState, JbPosition, JbSelection } from "../types/types"; +import { JetbrainsEditor } from "./JetbrainsEditor"; +import type { JetbrainsIDE } from "./JetbrainsIDE"; +import type { JetbrainsClient } from "./JetbrainsClient"; + +export function createTextEditor( + client: JetbrainsClient, + ide: JetbrainsIDE, + editorState: EditorState, +): JetbrainsEditor { + console.log("createTextEditor"); + + const id = editorState.id; + const uri = URI.parse(`talon-jetbrains://${id}`); + const languageId = editorState.languageId ?? "plaintext"; + const document = new InMemoryTextDocument(uri, languageId, editorState.text); + const visibleRanges = [document.range]; + const selections = editorState.selections.map((selection) => + createSelection(document, selection), + ); + + return new JetbrainsEditor( + client, + ide, + id, + document, + visibleRanges, + selections, + ); +} + +export function createSelection( + document: TextDocument, + selection: JbSelection, +): Selection { + console.log("createSelection " + JSON.stringify(selection)); + return new Selection( + createPosition(selection.anchor), + createPosition(selection.active), + ); +} + +export function createPosition(jbPosition: JbPosition): Position { + return new Position(jbPosition.line, jbPosition.column); +} diff --git a/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts new file mode 100644 index 0000000000..58d454689d --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts @@ -0,0 +1,32 @@ +import type { Edit } from "@cursorless/common"; +import { type InMemoryTextDocument } from "@cursorless/common"; +import type { Jetbrains } from "../types/jetbrains.types"; +import type { EditorEdit } from "../types/types"; +import type { JetbrainsIDE } from "./JetbrainsIDE"; +import type { JetbrainsClient } from "./JetbrainsClient"; + +export function jetbrainsPerformEdits( + client: JetbrainsClient, + ide: JetbrainsIDE, + document: InMemoryTextDocument, + edits: Edit[], +) { + const changes = document.edit(edits); + + const editorEdit: EditorEdit = { + text: document.text, + changes: changes.map((change) => ({ + rangeOffset: change.rangeOffset, + rangeLength: change.rangeLength, + text: change.text, + })), + }; + + client.documentUpdated(JSON.stringify(editorEdit)); + //jetbrains.actions.user.cursorless_everywhere_edit_text(editorEdit); + + ide.emitDidChangeTextDocument({ + document, + contentChanges: changes, + }); +} diff --git a/packages/cursorless-jetbrains/src/ide/setSelections.ts b/packages/cursorless-jetbrains/src/ide/setSelections.ts new file mode 100644 index 0000000000..98b6ca6149 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/setSelections.ts @@ -0,0 +1,19 @@ +import type { Selection, TextDocument } from "@cursorless/common"; +import type { Jetbrains } from "../types/jetbrains.types"; +import { JetbrainsClient } from "./JetbrainsClient"; +import { SetSelection } from "../../../cursorless-engine/src/actions/SetSelection"; + +export function setSelections( + client: JetbrainsClient, + document: TextDocument, + editorId: string, + selections: Selection[], +): Promise { + console.log("setSelections: " + selections); + const selectionsJson = JSON.stringify(selections); + console.log("setSelections JSON: " + selectionsJson); + client.setSelection(editorId, selectionsJson); + //jetbrains.actions.user.cursorless_everywhere_set_selections(selectionOffsets); + + return Promise.resolve(); +} diff --git a/packages/cursorless-jetbrains/src/testing/JetbrainsTesthelpers.ts b/packages/cursorless-jetbrains/src/testing/JetbrainsTesthelpers.ts new file mode 100644 index 0000000000..19b4e183bb --- /dev/null +++ b/packages/cursorless-jetbrains/src/testing/JetbrainsTesthelpers.ts @@ -0,0 +1,22 @@ +import type { + Command, + CommandResponse, + IDE, + NormalizedIDE, + TestHelpers, +} from "@cursorless/common"; +import type { JetbrainsIDE } from "../ide/JetbrainsIDE"; +import type { StoredTargetMap } from "@cursorless/cursorless-engine"; + +export interface JetbrainsTestHelpers + extends Omit { + talonJsIDE: JetbrainsIDE; + ide: NormalizedIDE; + storedTargets: StoredTargetMap; + injectIde: (ide: IDE) => void; + runCommand(command: Command): Promise; +} + +export interface ActivateReturnValue { + testHelpers?: JetbrainsTestHelpers; +} diff --git a/packages/cursorless-jetbrains/src/types/jetbrains.types.ts b/packages/cursorless-jetbrains/src/types/jetbrains.types.ts new file mode 100644 index 0000000000..e81eb391c4 --- /dev/null +++ b/packages/cursorless-jetbrains/src/types/jetbrains.types.ts @@ -0,0 +1,91 @@ +import { Range } from "@cursorless/common"; +import type { EditorEdit, EditorState, SelectionOffsets } from "./types"; + +export type JetbrainsNamespace = "user"; + +export interface JetbrainsActions { + app: { + notify(body: string, title: string): void; + }; + clip: { + set_text(text: string): void; + text(): string; + }; + edit: { + find(text?: string): void; + }; + user: { + cursorless_everywhere_get_editor_state(): EditorState; + cursorless_everywhere_set_selections(selections: SelectionOffsets[]): void; + cursorless_everywhere_edit_text(edit: EditorEdit): void; + }; +} + +export interface JetbrainsContextActions { + /** + * Executes an RPC command and waits for the result. + * This function is useful when the result of the command is needed + * immediately after execution. + * + * @param commandId - The identifier of the command to be executed. + * @param command - The command object containing necessary parameters. + * @returns A Promise that resolves with the result of the command execution. + */ + private_cursorless_jetbrains_run_and_wait( + commandId: string, + command: unknown, + ): Promise; + /** + * Executes an RPC command without waiting for the result. + * This function is useful for fire-and-forget operations where + * the result is not immediately needed. + * + * @param commandId - The identifier of the command to be executed. + * @param command - The command object containing necessary parameters. + */ + private_cursorless_jetbrains_run_no_wait( + commandId: string, + command: unknown, + ): void; + /** + * Retrieves the response json from the last RPC command execution. + * + * This is useful because Jetbrains doesn't have a way to read the responses from promises, + * but it does wait for them, so we store the response in a global variable and let it be + * read by this action. + * + * @returns The most recent response from an RPC command (JSON stringified). + */ + private_cursorless_jetbrains_get_response_json(): string; +} + +export interface JetbrainsContext { + matches: string; + tags: string[]; + settings: Record; + lists: Record | string[]>; + action_class(name: "user", actions: JetbrainsContextActions): void; +} + +export interface JetbrainsSettings { + get( + name: string, + defaultValue?: T, + ): T | null; +} + +interface JetbrainsContextConstructor { + new (): JetbrainsContext; +} + +export interface Jetbrains { + readonly actions: JetbrainsActions; + readonly settings: JetbrainsSettings; + Context: JetbrainsContextConstructor; +} + +export interface JetbrainsHatRange { + styleName: string; + editorId: string; + range: Range; +} diff --git a/packages/cursorless-jetbrains/src/types/types.ts b/packages/cursorless-jetbrains/src/types/types.ts new file mode 100644 index 0000000000..6837a5cbe2 --- /dev/null +++ b/packages/cursorless-jetbrains/src/types/types.ts @@ -0,0 +1,42 @@ +export interface SelectionOffsets { + // Document offsets + anchor: number; + active: number; +} + +export interface JbSelection { + start: JbPosition; + end: JbPosition; + cursorPosition: JbPosition; + anchor: JbPosition; + active: JbPosition; +} + +export interface JbPosition { + line: number; + column: number; +} + +export interface EditorState { + id: string; + text: string; + languageId?: string; + firstVisibleLine: number; + lastVisibleLine: number; + selections: JbSelection[]; +} + +export interface EditorChange { + readonly text: string; + readonly rangeOffset: number; + readonly rangeLength: number; +} + +export interface EditorEdit { + /** + * The new document content after the edit. We provide this for platforms + * where we can't easily handle {@link changes}. + */ + text: string; + changes: EditorChange[]; +} From 1a935a680d543b56d34bd42cedf4ada69de7a38d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Fri, 29 Nov 2024 20:22:29 +0100 Subject: [PATCH 09/39] fix jetbrains texteditor visible range add multi editor support to jetbrains ide --- .../src/ide/JetbrainsIDE.ts | 25 ++++++++++++------- .../src/ide/createTextEditor.ts | 5 +++- 2 files changed, 20 insertions(+), 10 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 82863a6932..c42993a43f 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -46,6 +46,7 @@ import type { EditorState } from "../types/types"; import { URI } from "vscode-uri"; import { createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; +import { makeNodePairSelection } from "../../../cursorless-engine/src/util/nodeSelectors"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -56,15 +57,18 @@ export class JetbrainsIDE implements IDE { readonly runMode: RunMode = "development"; // private editorMap; // private documentMap; - private activeWindow: Window | undefined; - private activeBuffer: Buffer | undefined; + private activeProject: Window | undefined; + private activeEditor: Buffer | undefined; private disposables: Disposable[] = []; private assetsRoot_: string | undefined; private cursorlessJetbrainsPath: string | undefined; private quickPickReturnValue: string | undefined = undefined; - private editors: EditableTextEditor[] = []; + private editors: Map = new Map< + string, + JetbrainsEditor + >(); private onDidChangeTextDocumentNotifier: Notifier<[TextDocumentChangeEvent]> = new Notifier(); @@ -81,8 +85,8 @@ export class JetbrainsIDE implements IDE { this.capabilities = new JetbrainsCapabilities(); // this.editorMap = new Map(); // this.documentMap = new Map(); - this.activeWindow = undefined; - this.activeBuffer = undefined; + this.activeProject = undefined; + this.activeEditor = undefined; } async init() {} @@ -128,12 +132,12 @@ export class JetbrainsIDE implements IDE { get activeEditableTextEditor(): EditableTextEditor | undefined { console.log("get activeEditableTextEditor"); - return this.editors[0]; + return [...this.editors.values()].find((editor) => editor.isActive); } get visibleTextEditors(): TextEditor[] { - console.log("get activeEditableTextEditor"); - return this.editors; + console.log("get visibleTextEditors"); + return [...this.editors.values()].filter((editor) => editor.isActive); } getEditableTextEditor(editor: TextEditor): EditableTextEditor { @@ -250,7 +254,10 @@ export class JetbrainsIDE implements IDE { } updateTextEditors(editorState: EditorState) { - this.editors = [createTextEditor(this.client, this, editorState)]; + this.editors.set( + editorState.id, + createTextEditor(this.client, this, editorState), + ); console.log( "ASOEE/CL: updated editor with document " + editorState.firstVisibleLine, ); diff --git a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts index 18530ee606..e8e0982f88 100644 --- a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts @@ -1,6 +1,7 @@ import { InMemoryTextDocument, Position, + Range, Selection, type TextDocument, } from "@cursorless/common"; @@ -21,7 +22,9 @@ export function createTextEditor( const uri = URI.parse(`talon-jetbrains://${id}`); const languageId = editorState.languageId ?? "plaintext"; const document = new InMemoryTextDocument(uri, languageId, editorState.text); - const visibleRanges = [document.range]; + const visibleRanges = [ + new Range(editorState.firstVisibleLine, 0, editorState.lastVisibleLine, 0), + ]; const selections = editorState.selections.map((selection) => createSelection(document, selection), ); From eea280cc03c84102928d40eb903c77c0092b6a45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 30 Nov 2024 17:58:36 +0100 Subject: [PATCH 10/39] fix active editor state update existing editors instead of recreating --- .../src/ide/JetbrainsClient.ts | 2 +- .../src/ide/JetbrainsEditor.ts | 2 +- .../src/ide/JetbrainsIDE.ts | 65 +++++++++++++------ .../src/ide/jetbrainsPerformEdits.ts | 3 +- .../cursorless-jetbrains/src/types/types.ts | 1 + 5 files changed, 49 insertions(+), 24 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 44fc6d80e2..ee2aef7428 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -1,5 +1,5 @@ export interface JetbrainsClient { hatsUpdated(hatsJson: string): void; - documentUpdated(updateJson: string): void; + documentUpdated(editorId: string, updateJson: string): void; setSelection(editorId: string, selectionJson: string): void; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index d8fc726b8e..4d03600125 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -51,7 +51,7 @@ export class JetbrainsEditor implements EditableTextEditor { edit(edits: Edit[]): Promise { console.log("editor.edit"); - jetbrainsPerformEdits(this.client, this.ide, this.document, edits); + jetbrainsPerformEdits(this.client, this.ide, this.document, this.id, edits); return Promise.resolve(true); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index c42993a43f..bbeab8b803 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -5,6 +5,7 @@ import { InMemoryTextDocument, Notifier, OpenUntitledTextDocumentOptions, + Range, RunMode, TextDocumentChangeEvent, TextEditor, @@ -44,9 +45,10 @@ import { JetbrainsMessages } from "./JetbrainsMessages"; import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore"; import type { EditorState } from "../types/types"; import { URI } from "vscode-uri"; -import { createTextEditor } from "./createTextEditor"; +import { createSelection, createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; import { makeNodePairSelection } from "../../../cursorless-engine/src/util/nodeSelectors"; +import { elseIfExtractor } from "../../../cursorless-engine/src/languages/elseIfExtractor"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -58,7 +60,7 @@ export class JetbrainsIDE implements IDE { // private editorMap; // private documentMap; private activeProject: Window | undefined; - private activeEditor: Buffer | undefined; + private activeEditor: JetbrainsEditor | undefined; private disposables: Disposable[] = []; private assetsRoot_: string | undefined; @@ -126,18 +128,24 @@ export class JetbrainsIDE implements IDE { } get activeTextEditor(): TextEditor | undefined { - console.log("get activeEditableTextEditor"); + console.log("get activeTextEditor"); return this.activeEditableTextEditor; } get activeEditableTextEditor(): EditableTextEditor | undefined { console.log("get activeEditableTextEditor"); - return [...this.editors.values()].find((editor) => editor.isActive); + return this.activeEditor; } get visibleTextEditors(): TextEditor[] { console.log("get visibleTextEditors"); - return [...this.editors.values()].filter((editor) => editor.isActive); + //return [...this.editors.values()].filter((editor) => editor.isActive); + if (this.activeEditor) { + console.log("visible: " + this.activeEditor.id); + return [this.activeEditor]; + } else { + return []; + } } getEditableTextEditor(editor: TextEditor): EditableTextEditor { @@ -222,26 +230,21 @@ export class JetbrainsIDE implements IDE { ); const editorState = editorStateJson as EditorState; - this.updateTextEditors(editorState); + const editor = this.updateTextEditors(editorState); - const uri = URI.parse("jetbrains://" + editorState); - const language = editorState.languageId - ? editorState.languageId - : "plaintext"; - const document = new InMemoryTextDocument(uri, language, editorState.text); const linedata = getLines( editorState.text, editorState.firstVisibleLine, editorState.lastVisibleLine, ); const contentChangeEvents = fromJetbrainsContentChange( - document, + editor.document, editorState.firstVisibleLine, editorState.lastVisibleLine, linedata, ); const documentChangeEvent: TextDocumentChangeEvent = { - document: document, + document: editor.document, contentChanges: contentChangeEvents, }; console.log("ASOEE/CL: documentChanged : notify..."); @@ -253,17 +256,37 @@ export class JetbrainsIDE implements IDE { this.onDidChangeTextDocumentNotifier.notifyListeners(event); } - updateTextEditors(editorState: EditorState) { - this.editors.set( - editorState.id, - createTextEditor(this.client, this, editorState), - ); - console.log( - "ASOEE/CL: updated editor with document " + editorState.firstVisibleLine, - ); + updateTextEditors(editorState: EditorState): JetbrainsEditor { + let editor = this.editors.get(editorState.id); + if (editor) { + updateEditor(editor, editorState); + } else { + editor = createTextEditor(this.client, this, editorState); + this.editors.set(editorState.id, editor); + } + if (editorState.active) { + this.activeEditor = editor; + } + return editor; } } +function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { + console.log("Updating editor " + editorState.id); + const oldDocument = editor.document; + editor.document = new InMemoryTextDocument( + oldDocument.uri, + oldDocument.languageId, + editorState.text, + ); + editor.visibleRanges = [ + new Range(editorState.firstVisibleLine, 0, editorState.lastVisibleLine, 0), + ]; + editor.selections = editorState.selections.map((selection) => + createSelection(editor.document, selection), + ); +} + function getLines(text: string, firstLine: number, lastLine: number) { const lines = text.split("\n"); return lines.slice(firstLine, lastLine); diff --git a/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts index 58d454689d..a031cf1525 100644 --- a/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts +++ b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts @@ -9,6 +9,7 @@ export function jetbrainsPerformEdits( client: JetbrainsClient, ide: JetbrainsIDE, document: InMemoryTextDocument, + id: string, edits: Edit[], ) { const changes = document.edit(edits); @@ -22,7 +23,7 @@ export function jetbrainsPerformEdits( })), }; - client.documentUpdated(JSON.stringify(editorEdit)); + client.documentUpdated(id, JSON.stringify(editorEdit)); //jetbrains.actions.user.cursorless_everywhere_edit_text(editorEdit); ide.emitDidChangeTextDocument({ diff --git a/packages/cursorless-jetbrains/src/types/types.ts b/packages/cursorless-jetbrains/src/types/types.ts index 6837a5cbe2..99ffd9f490 100644 --- a/packages/cursorless-jetbrains/src/types/types.ts +++ b/packages/cursorless-jetbrains/src/types/types.ts @@ -24,6 +24,7 @@ export interface EditorState { firstVisibleLine: number; lastVisibleLine: number; selections: JbSelection[]; + active: boolean; } export interface EditorChange { From 23caf2d45885fddfbdfb4a0fe465f1b28e294010 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 4 Dec 2024 22:08:01 +0100 Subject: [PATCH 11/39] add clipboard support make configuration injectable --- .../src/ide/JetbrainsCapabilities.ts | 2 +- .../src/ide/JetbrainsClient.ts | 2 ++ .../src/ide/JetbrainsClipboard.ts | 15 ++++++++-- .../src/ide/JetbrainsConfiguration.ts | 29 ++++++++++++++----- .../src/ide/JetbrainsEditor.ts | 6 ++-- .../src/ide/JetbrainsIDE.ts | 17 +++++++---- .../src/ide/setSelections.ts | 6 +--- packages/cursorless-jetbrains/src/index.ts | 5 +--- 8 files changed, 53 insertions(+), 29 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts index 234d51a397..36d304e14e 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts @@ -1,7 +1,7 @@ import type { Capabilities, CommandCapabilityMap } from "@cursorless/common"; const COMMAND_CAPABILITIES: CommandCapabilityMap = { - clipboardCopy: { acceptsLocation: false }, + clipboardCopy: { acceptsLocation: true }, clipboardPaste: true, toggleLineComment: undefined, indentLine: undefined, diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index ee2aef7428..1bad322bed 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -1,4 +1,6 @@ export interface JetbrainsClient { + clipboardCopy(editorId: string, rangesJson: string): void; + clipboardPaste(editorId: string): void; hatsUpdated(hatsJson: string): void; documentUpdated(editorId: string, updateJson: string): void; setSelection(editorId: string, selectionJson: string): void; diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts index a08c340c42..1c94b825fd 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClipboard.ts @@ -1,5 +1,5 @@ -import type { Clipboard } from "@cursorless/common"; -import { JetbrainsClient } from "./JetbrainsClient" +import type { Clipboard, Range } from "@cursorless/common"; +import type { JetbrainsClient } from "./JetbrainsClient"; export class JetbrainsClipboard implements Clipboard { constructor(private client: JetbrainsClient) {} @@ -8,7 +8,16 @@ export class JetbrainsClipboard implements Clipboard { return ""; } - async writeText(value: string): Promise { + async writeText(_value: string): Promise { return; } + + async copy(editorId: string, ranges: Range[]): Promise { + const rangesJson = JSON.stringify(ranges); + this.client.clipboardCopy(editorId, rangesJson); + } + + async paste(editorId: string): Promise { + this.client.clipboardPaste(editorId); + } } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts index adbea2f11d..a7633f17e8 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts @@ -1,4 +1,3 @@ - import { HatStability } from "@cursorless/common"; import { get } from "lodash"; import type { @@ -12,22 +11,34 @@ import { Notifier } from "@cursorless/common"; export class JetbrainsConfiguration implements Configuration { private notifier = new Notifier(); + private configuration: CursorlessConfiguration = CONFIGURATION_DEFAULTS; - constructor() { - + constructor(configuration: CursorlessConfiguration) { + this.configuration = configuration; } getOwnConfiguration>( path: Path, scope?: ConfigurationScope, ): GetFieldType { - return get(CONFIGURATION_DEFAULTS, path) as GetFieldType< + return get(this.configuration, path) as GetFieldType< CursorlessConfiguration, Path >; } onDidChangeConfiguration = this.notifier.registerListener; + + updateConfiguration(configuration: CursorlessConfiguration) { + this.configuration = configuration; + this.notifier.notifyListeners(); + } +} + +export function createJetbrainsConfiguration( + configuration: CursorlessConfiguration, +): JetbrainsConfiguration { + return new JetbrainsConfiguration(configuration); } /** @@ -40,13 +51,15 @@ export class JetbrainsConfiguration implements Configuration { * @returns The configuration value, with variables expanded, or undefined if * the value is not set */ -export function jetbrainsGetConfigurationString(path: string): string | undefined { +export function jetbrainsGetConfigurationString( + path: string, +): string | undefined { const index = path.lastIndexOf("."); const section = path.substring(0, index); const field = path.substring(index + 1); -// const value = "jetbrains.workspace.getConfiguration(section).get(field)"; -// return value != null ? evaluateStringVariables(value) : undefined; - return undefined + // const value = "jetbrains.workspace.getConfiguration(section).get(field)"; + // return value != null ? evaluateStringVariables(value) : undefined; + return undefined; } function evaluateStringVariables(value: string): string { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index 4d03600125..f92b842781 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -55,12 +55,12 @@ export class JetbrainsEditor implements EditableTextEditor { return Promise.resolve(true); } - async clipboardCopy(_ranges: Range[]): Promise { - throw Error("clipboardCopy not implemented."); + async clipboardCopy(ranges: Range[]): Promise { + await this.ide.clipboard.copy(this.id, ranges); } async clipboardPaste(): Promise { - throw Error("clipboardPaste not implemented."); + await this.ide.clipboard.paste(this.id); } indentLine(_ranges: Range[]): Promise { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index bbeab8b803..d9856f1f0a 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -49,6 +49,7 @@ import { createSelection, createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; import { makeNodePairSelection } from "../../../cursorless-engine/src/util/nodeSelectors"; import { elseIfExtractor } from "../../../cursorless-engine/src/languages/elseIfExtractor"; +import { Configuration } from "../../../common/src/ide/types/Configuration"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -79,8 +80,11 @@ export class JetbrainsIDE implements IDE { [TextDocumentContentChangeEvent] > = new Notifier(); - constructor(private client: JetbrainsClient) { - this.configuration = new JetbrainsConfiguration(); + constructor( + private client: JetbrainsClient, + configuration: JetbrainsConfiguration, + ) { + this.configuration = configuration; this.keyValueStore = new JetbrainsKeyValueStore(); this.messages = new JetbrainsMessages(); this.clipboard = new JetbrainsClipboard(this.client); @@ -179,7 +183,7 @@ export class JetbrainsIDE implements IDE { } public async showInputBox(_options?: any): Promise { - throw Error("TextDocumentChangeEvent Not implemented"); + throw Error("showInputBox Not implemented"); } public async executeCommand( @@ -300,6 +304,9 @@ function dummyEvent() { }; } -export function createIDE(client: JetbrainsClient) { - return new JetbrainsIDE(client); +export function createIDE( + client: JetbrainsClient, + configuration: JetbrainsConfiguration, +) { + return new JetbrainsIDE(client, configuration); } diff --git a/packages/cursorless-jetbrains/src/ide/setSelections.ts b/packages/cursorless-jetbrains/src/ide/setSelections.ts index 98b6ca6149..39f7413d9d 100644 --- a/packages/cursorless-jetbrains/src/ide/setSelections.ts +++ b/packages/cursorless-jetbrains/src/ide/setSelections.ts @@ -1,7 +1,5 @@ import type { Selection, TextDocument } from "@cursorless/common"; -import type { Jetbrains } from "../types/jetbrains.types"; -import { JetbrainsClient } from "./JetbrainsClient"; -import { SetSelection } from "../../../cursorless-engine/src/actions/SetSelection"; +import type { JetbrainsClient } from "./JetbrainsClient"; export function setSelections( client: JetbrainsClient, @@ -13,7 +11,5 @@ export function setSelections( const selectionsJson = JSON.stringify(selections); console.log("setSelections JSON: " + selectionsJson); client.setSelection(editorId, selectionsJson); - //jetbrains.actions.user.cursorless_everywhere_set_selections(selectionOffsets); - return Promise.resolve(); } diff --git a/packages/cursorless-jetbrains/src/index.ts b/packages/cursorless-jetbrains/src/index.ts index 0ccc15ecd3..0c195aa550 100644 --- a/packages/cursorless-jetbrains/src/index.ts +++ b/packages/cursorless-jetbrains/src/index.ts @@ -1,7 +1,4 @@ export * from "./ide/JetbrainsPlugin"; +export * from "./ide/JetbrainsConfiguration"; export * from "./ide/JetbrainsIDE"; export * from "./extension"; - - - - From 9bedadd8fcc4f4255f27bf34e293a85fa0e72a0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 5 Dec 2024 06:26:59 +0100 Subject: [PATCH 12/39] remove editor state on close --- packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index d9856f1f0a..1169b276ff 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -228,6 +228,16 @@ export class JetbrainsIDE implements IDE { return () => pull(this.disposables, ...disposables); } + public documentClosed(editorId: string) { + this.editors.delete(editorId); + console.log( + "removed editor " + + editorId + + "remaining after change: " + + this.editors.size, + ); + } + public documentChanged(editorStateJson: any) { console.log( "ASOEE/CL: documentChanged : " + JSON.stringify(editorStateJson), From f16e5952d732bf9f9baa2a1a051471ac44512968 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 5 Dec 2024 09:07:07 +0100 Subject: [PATCH 13/39] remove debug logging --- .../src/ide/JetbrainsIDE.ts | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 1169b276ff..5d7e0fafd1 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -132,17 +132,17 @@ export class JetbrainsIDE implements IDE { } get activeTextEditor(): TextEditor | undefined { - console.log("get activeTextEditor"); + // console.log("get activeTextEditor"); return this.activeEditableTextEditor; } get activeEditableTextEditor(): EditableTextEditor | undefined { - console.log("get activeEditableTextEditor"); + // console.log("get activeEditableTextEditor"); return this.activeEditor; } get visibleTextEditors(): TextEditor[] { - console.log("get visibleTextEditors"); + // console.log("get visibleTextEditors"); //return [...this.editors.values()].filter((editor) => editor.isActive); if (this.activeEditor) { console.log("visible: " + this.activeEditor.id); @@ -153,7 +153,7 @@ export class JetbrainsIDE implements IDE { } getEditableTextEditor(editor: TextEditor): EditableTextEditor { - console.log("getEditableTextEditor"); + // console.log("getEditableTextEditor"); if (editor instanceof JetbrainsEditor) { console.log("getEditableTextEditor - return current"); return editor; @@ -230,18 +230,18 @@ export class JetbrainsIDE implements IDE { public documentClosed(editorId: string) { this.editors.delete(editorId); - console.log( - "removed editor " + - editorId + - "remaining after change: " + - this.editors.size, - ); + // console.log( + // "removed editor " + + // editorId + + // "remaining after change: " + + // this.editors.size, + // ); } public documentChanged(editorStateJson: any) { - console.log( - "ASOEE/CL: documentChanged : " + JSON.stringify(editorStateJson), - ); + // console.log( + // "ASOEE/CL: documentChanged : " + JSON.stringify(editorStateJson), + // ); const editorState = editorStateJson as EditorState; const editor = this.updateTextEditors(editorState); @@ -261,9 +261,9 @@ export class JetbrainsIDE implements IDE { document: editor.document, contentChanges: contentChangeEvents, }; - console.log("ASOEE/CL: documentChanged : notify..."); + // console.log("ASOEE/CL: documentChanged : notify..."); this.emitDidChangeTextDocument(documentChangeEvent); - console.log("ASOEE/CL: documentChanged : notify complete"); + // console.log("ASOEE/CL: documentChanged : notify complete"); } emitDidChangeTextDocument(event: TextDocumentChangeEvent) { @@ -286,7 +286,7 @@ export class JetbrainsIDE implements IDE { } function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { - console.log("Updating editor " + editorState.id); + // console.log("Updating editor " + editorState.id); const oldDocument = editor.document; editor.document = new InMemoryTextDocument( oldDocument.uri, From b63c8c3b437bc28cf0b78ede76cae9b1aaad3789 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 7 Dec 2024 18:15:19 +0100 Subject: [PATCH 14/39] add most of range IDE commands --- .../src/ide/JetbrainsCapabilities.ts | 24 ++-- .../src/ide/JetbrainsClient.ts | 3 + .../src/ide/JetbrainsEditor.ts | 135 +++++++++++++----- 3 files changed, 116 insertions(+), 46 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts index 36d304e14e..8d4d8b1f14 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts @@ -3,21 +3,21 @@ import type { Capabilities, CommandCapabilityMap } from "@cursorless/common"; const COMMAND_CAPABILITIES: CommandCapabilityMap = { clipboardCopy: { acceptsLocation: true }, clipboardPaste: true, - toggleLineComment: undefined, - indentLine: undefined, - outdentLine: undefined, - rename: undefined, - quickFix: undefined, - revealDefinition: undefined, - revealTypeDefinition: undefined, + toggleLineComment: { acceptsLocation: true }, + indentLine: { acceptsLocation: true }, + outdentLine: { acceptsLocation: true }, + rename: { acceptsLocation: true }, + quickFix: { acceptsLocation: true }, + revealDefinition: { acceptsLocation: true }, + revealTypeDefinition: { acceptsLocation: true }, showHover: undefined, showDebugHover: undefined, - extractVariable: undefined, - fold: undefined, + extractVariable: { acceptsLocation: true }, + fold: { acceptsLocation: true }, highlight: { acceptsLocation: true }, - unfold: undefined, - showReferences: undefined, - insertLineAfter: undefined, + unfold: { acceptsLocation: true }, + showReferences: { acceptsLocation: true }, + insertLineAfter: { acceptsLocation: true }, }; export class JetbrainsCapabilities implements Capabilities { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 1bad322bed..5002d558b0 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -4,4 +4,7 @@ export interface JetbrainsClient { hatsUpdated(hatsJson: string): void; documentUpdated(editorId: string, updateJson: string): void; setSelection(editorId: string, selectionJson: string): void; + executeCommand(editorId: string, command: string, jsonArgs: string): string; + executeRangeCommand(editorId: string, commandJson: string): string; + insertLineAfter(editorId: string, rangesJson: string): void; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index f92b842781..c0f11bd375 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -1,3 +1,4 @@ +import type { Selection } from "@cursorless/common"; import { selectionsEqual, type BreakpointDescriptor, @@ -7,7 +8,6 @@ import { type OpenLinkOptions, type Range, type RevealLineAt, - type Selection, type SetSelectionsOpts, type TextEditor, type TextEditorOptions, @@ -16,6 +16,7 @@ import { setSelections } from "./setSelections"; import type { JetbrainsIDE } from "./JetbrainsIDE"; import { jetbrainsPerformEdits } from "./jetbrainsPerformEdits"; import type { JetbrainsClient } from "./JetbrainsClient"; +import { JetbrainsEditorCommand } from "./JetbrainsEditorCommand"; export class JetbrainsEditor implements EditableTextEditor { options: TextEditorOptions = { @@ -63,16 +64,28 @@ export class JetbrainsEditor implements EditableTextEditor { await this.ide.clipboard.paste(this.id); } - indentLine(_ranges: Range[]): Promise { - throw Error("indentLine not implemented."); + async indentLine(ranges: Range[]): Promise { + const command = new JetbrainsEditorCommand( + ranges ? ranges : [], + true, + true, + "EditorIndentSelection", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } - outdentLine(_ranges: Range[]): Promise { - throw Error("outdentLine not implemented."); + async outdentLine(ranges: Range[]): Promise { + const command = new JetbrainsEditorCommand( + ranges ? ranges : [], + true, + true, + "EditorUnindentSelection", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } - insertLineAfter(_ranges?: Range[]): Promise { - throw Error("insertLineAfter not implemented."); + async insertLineAfter(ranges?: Range[]): Promise { + await this.client.insertLineAfter(this.id, JSON.stringify(ranges)); } focus(): Promise { @@ -94,22 +107,40 @@ export class JetbrainsEditor implements EditableTextEditor { throw new Error("openLink not implemented."); } - fold(_ranges?: Range[] | undefined): Promise { - throw new Error("fold not implemented."); + async fold(ranges?: Range[] | undefined): Promise { + const command = new JetbrainsEditorCommand( + ranges ? ranges : [], + true, + false, + "CollapseRegion", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } - unfold(_ranges?: Range[] | undefined): Promise { - throw new Error("unfold not implemented."); + async unfold(ranges?: Range[] | undefined): Promise { + const command = new JetbrainsEditorCommand( + ranges ? ranges : [], + true, + false, + "ExpandRegion", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } - toggleBreakpoint( + async toggleBreakpoint( _descriptors?: BreakpointDescriptor[] | undefined, ): Promise { throw new Error("toggleBreakpoint not implemented."); } - toggleLineComment(_ranges?: Range[] | undefined): Promise { - throw new Error("toggleLineComment not implemented."); + async toggleLineComment(ranges?: Range[] | undefined): Promise { + const command = new JetbrainsEditorCommand( + ranges ? ranges : [], + true, + false, + "CommentByLineComment", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } insertSnippet( @@ -119,24 +150,54 @@ export class JetbrainsEditor implements EditableTextEditor { throw new Error("insertSnippet not implemented."); } - rename(_range?: Range | undefined): Promise { - throw new Error("rename not implemented."); - } - - showReferences(_range?: Range | undefined): Promise { - throw new Error("showReferences not implemented."); - } - - quickFix(_range?: Range | undefined): Promise { - throw new Error("quickFix not implemented."); - } - - revealDefinition(_range?: Range | undefined): Promise { - throw new Error("revealDefinition not implemented."); - } - - revealTypeDefinition(_range?: Range | undefined): Promise { - throw new Error("revealTypeDefinition not implemented."); + async rename(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "RenameElement", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); + } + + async showReferences(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "FindUsages", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); + } + + async quickFix(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "ShowIntentionActions", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); + } + + async revealDefinition(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "QuickImplementations", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); + } + + async revealTypeDefinition(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "QuickImplementations", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } showHover(_range?: Range | undefined): Promise { @@ -147,8 +208,14 @@ export class JetbrainsEditor implements EditableTextEditor { throw new Error("showDebugHover not implemented."); } - extractVariable(_range?: Range | undefined): Promise { - throw new Error("extractVariable not implemented."); + async extractVariable(range?: Range | undefined): Promise { + const command = new JetbrainsEditorCommand( + range ? [range] : [], + true, + false, + "IntroduceVariable", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } editNewNotebookCellAbove(): Promise<(_selection: Selection) => Selection> { From 203e64d26a852315073605b7ec5e46ec97037b25 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 7 Dec 2024 19:35:36 +0100 Subject: [PATCH 15/39] add reveal range --- packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts | 1 + packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 5002d558b0..42ee7eb386 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -7,4 +7,5 @@ export interface JetbrainsClient { executeCommand(editorId: string, command: string, jsonArgs: string): string; executeRangeCommand(editorId: string, commandJson: string): string; insertLineAfter(editorId: string, rangesJson: string): void; + revealLine(editorId: string, line: number, revealAt: string): void; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index c0f11bd375..8089ca320a 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -96,8 +96,8 @@ export class JetbrainsEditor implements EditableTextEditor { return Promise.resolve(); } - revealLine(_lineNumber: number, _at: RevealLineAt): Promise { - throw new Error("revealLine not implemented."); + async revealLine(lineNumber: number, at: RevealLineAt): Promise { + await this.client.revealLine(this.id, lineNumber, at); } openLink( From 52315e2a1d37e5024af1d67bc211cb6e1e66aad4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Mon, 9 Dec 2024 21:43:04 +0100 Subject: [PATCH 16/39] add jetbrains treesitter support --- packages/cursorless-jetbrains/package.json | 5 +- .../cursorless-jetbrains/src/extension.ts | 19 +++++- .../src/ide/JetbrainsClient.ts | 1 + .../src/ide/JetbrainsEditorCommand.ts | 10 ++++ .../src/ide/JetbrainsIDE.ts | 59 +++++++++---------- .../src/ide/JetbrainsTreeSitter.ts | 52 ++++++++++++++++ .../ide/JetbrainsTreeSitterQueryProvider.ts | 27 +++++++++ packages/cursorless-jetbrains/tsconfig.json | 2 +- 8 files changed, 139 insertions(+), 36 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsEditorCommand.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 00d563424d..a06aad6639 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -7,7 +7,7 @@ "scripts": { "build": "pnpm run esbuild:prod && pnpm run populate-dist", "compile": "tsc --build", - "esbuild:base": "esbuild ./src/index.ts --format=esm --target=es2020 --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=neutral --external:std", + "esbuild:base": "esbuild ./src/index.ts --format=esm --target=es2020 --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=neutral --external:std --external:fs --external:path", "esbuild": "pnpm run esbuild:base --sourcemap", "esbuild:prod": "pnpm run esbuild:base --minify", "populate-dist": "bash ./scripts/populate-dist.sh", @@ -31,7 +31,8 @@ "@cursorless/common": "workspace:*", "@cursorless/cursorless-engine": "workspace:*", "@cursorless/test-case-recorder": "workspace:*", - "vscode-uri": "^3.0.8" + "vscode-uri": "^3.0.8", + "web-tree-sitter": "0.24.4" }, "devDependencies": { "@types/chai": "^5.0.0", diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index ec6305c19c..2b74f05f20 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -1,15 +1,30 @@ import type { CursorlessEngine } from "@cursorless/cursorless-engine"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; -import { JetbrainsIDE } from "./ide/JetbrainsIDE"; +import Parser from "web-tree-sitter"; +import { JetbrainsTreeSitter } from "./ide/JetbrainsTreeSitter"; +import { JetbrainsTreeSitterQueryProvider } from "./ide/JetbrainsTreeSitterQueryProvider"; export async function activate( plugin: JetbrainsPlugin, + wasmDirectory: string, ): Promise { + console.log("activate started"); + await Parser.init({ + locateFile(scriptName: string, _scriptDirectory: string) { + console.log("locateFile called for " + scriptName); + return wasmDirectory + scriptName; + }, + }); + console.log("Parser initialized"); + + const queryProvider = new JetbrainsTreeSitterQueryProvider(plugin.ide); const engine = await createCursorlessEngine({ ide: plugin.ide, hats: plugin.hats, + treeSitterQueryProvider: queryProvider, + treeSitter: new JetbrainsTreeSitter(wasmDirectory), }); - return engine; console.log("activate completed"); + return engine; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 42ee7eb386..d08859953a 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -8,4 +8,5 @@ export interface JetbrainsClient { executeRangeCommand(editorId: string, commandJson: string): string; insertLineAfter(editorId: string, rangesJson: string): void; revealLine(editorId: string, line: number, revealAt: string): void; + readQuery(filename: string): string | undefined; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditorCommand.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditorCommand.ts new file mode 100644 index 0000000000..9a057b9c10 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditorCommand.ts @@ -0,0 +1,10 @@ +import type { Range } from "@cursorless/common"; + +export class JetbrainsEditorCommand { + constructor( + private ranges: Range[], + private singleRange: boolean, + private restoreSelection: boolean, + private ideCommand: string, + ) {} +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 5d7e0fafd1..c1a1ba6aed 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -1,16 +1,4 @@ -import { - Disposable, - EditableTextEditor, - IDE, - InMemoryTextDocument, - Notifier, - OpenUntitledTextDocumentOptions, - Range, - RunMode, - TextDocumentChangeEvent, - TextEditor, - WorkspaceFolder, -} from "@cursorless/common"; +import { InMemoryTextDocument, Notifier, Range } from "@cursorless/common"; import type { Event, FlashDescriptor, @@ -20,19 +8,17 @@ import type { TextDocumentContentChangeEvent, TextEditorSelectionChangeEvent, TextEditorVisibleRangesChangeEvent, + Disposable, + EditableTextEditor, + IDE, + OpenUntitledTextDocumentOptions, + RunMode, + TextDocumentChangeEvent, + TextEditor, + WorkspaceFolder, } from "@cursorless/common"; import { pull } from "lodash"; -// import type { Buffer, JetbrainsClient, Window } from "jetbrains"; -// import { v4 as uuid } from "uuid"; import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; -// import JetbrainsClipboard from "./JetbrainsClipboard"; -// import JetbrainsConfiguration from "./JetbrainsConfiguration"; -// import JetbrainsKeyValueStore from "./JetbrainsKeyValueStore"; -// import JetbrainsMessages from "./JetbrainsMessages"; -// import { JetbrainsTextEditorImpl } from "./JetbrainsTextEditorImpl"; -// import path from "path"; -// import { nodeGetRunMode } from "@cursorless/node-common"; - import { fromJetbrainsContentChange, jetbrainsOnDidOpenTextDocument, @@ -40,16 +26,12 @@ import { import type { JetbrainsClient } from "./JetbrainsClient"; import { JetbrainsClipboard } from "./JetbrainsClipboard"; -import { JetbrainsConfiguration } from "./JetbrainsConfiguration"; +import type { JetbrainsConfiguration } from "./JetbrainsConfiguration"; import { JetbrainsMessages } from "./JetbrainsMessages"; import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore"; import type { EditorState } from "../types/types"; -import { URI } from "vscode-uri"; import { createSelection, createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; -import { makeNodePairSelection } from "../../../cursorless-engine/src/util/nodeSelectors"; -import { elseIfExtractor } from "../../../cursorless-engine/src/languages/elseIfExtractor"; -import { Configuration } from "../../../common/src/ide/types/Configuration"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -75,6 +57,8 @@ export class JetbrainsIDE implements IDE { private onDidChangeTextDocumentNotifier: Notifier<[TextDocumentChangeEvent]> = new Notifier(); + private onDidOpenTextDocumentNotifier: Notifier<[TextDocument]> = + new Notifier(); private onDidChangeTextDocumentContentNotifier: Notifier< [TextDocumentContentChangeEvent] @@ -201,10 +185,10 @@ export class JetbrainsIDE implements IDE { public onDidOpenTextDocument( listener: (event: TextDocument) => any, - thisArgs?: any, - disposables?: Disposable[] | undefined, + _thisArgs?: any, + _disposables?: Disposable[] | undefined, ): Disposable { - return jetbrainsOnDidOpenTextDocument(listener, thisArgs, disposables); + return this.onDidOpenTextDocumentNotifier.registerListener(listener); } onDidCloseTextDocument: Event = dummyEvent; onDidChangeActiveTextEditor: Event = dummyEvent; @@ -238,6 +222,15 @@ export class JetbrainsIDE implements IDE { // ); } + public documentCreated(editorStateJson: any) { + this.documentChanged(editorStateJson); + const editorState = editorStateJson as EditorState; + const editor = this.editors.get(editorState.id); + if (editor) { + this.onDidOpenTextDocumentNotifier.notifyListeners(editor.document); + } + } + public documentChanged(editorStateJson: any) { // console.log( // "ASOEE/CL: documentChanged : " + JSON.stringify(editorStateJson), @@ -283,6 +276,10 @@ export class JetbrainsIDE implements IDE { } return editor; } + + readQuery(filename: string): string | undefined { + return this.client.readQuery(filename); + } } function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts new file mode 100644 index 0000000000..89c089ae86 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -0,0 +1,52 @@ +import type { Range, TextDocument, TreeSitter } from "@cursorless/common"; +import type { Language, SyntaxNode, Tree } from "web-tree-sitter"; +import Parser from "web-tree-sitter"; + +export class JetbrainsTreeSitter implements TreeSitter { + constructor(private wasmDirectory: string) {} + + parsers = new Map(); + + getTree(document: TextDocument): Tree { + console.log(`get tree ${document.languageId}`); + if (this.getLanguage(document.languageId)) { + const parser = this.parsers.get(document.languageId); + if (parser) { + return parser.parse(document.getText()); + } + } + throw new Error("Language not supported"); + } + + async loadLanguage(languageId: string): Promise { + console.log(`Loading language ${languageId}`); + const parser = new Parser(); + const language = await Parser.Language.load( + `${this.wasmDirectory}/tree-sitter-${languageId}.wasm`, + ); + parser.setLanguage(language); + this.parsers.set(languageId, parser); + return true; + } + + getLanguage(languageId: string): Language | undefined { + console.log(`get language ${languageId}`); + return this.parsers.get(languageId)?.getLanguage(); + } + + getNodeAtLocation(document: TextDocument, range: Range): SyntaxNode { + console.log(`get node at ${document.languageId}`); + const tree = this.getTree(document); + const node = tree.rootNode.descendantForPosition( + { + row: range.start.line, + column: range.start.character, + }, + { + row: range.end.line, + column: range.end.character, + }, + ); + return node; + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts new file mode 100644 index 0000000000..abb61f0d60 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts @@ -0,0 +1,27 @@ +import { + Notifier, + type Disposable, + type RawTreeSitterQueryProvider, +} from "@cursorless/common"; +import type { JetbrainsIDE } from "./JetbrainsIDE"; + +export class JetbrainsTreeSitterQueryProvider + implements RawTreeSitterQueryProvider +{ + private notifier: Notifier = new Notifier(); + private disposables: Disposable[] = []; + + constructor(private ide: JetbrainsIDE) {} + + onChanges = this.notifier.registerListener; + + async readQuery(filename: string): Promise { + console.log("readQuery", filename); + const queryContents = await this.ide.readQuery(filename); + return queryContents; + } + + dispose() { + this.disposables.forEach((disposable) => disposable.dispose()); + } +} diff --git a/packages/cursorless-jetbrains/tsconfig.json b/packages/cursorless-jetbrains/tsconfig.json index 0ac9478318..8d9093f102 100644 --- a/packages/cursorless-jetbrains/tsconfig.json +++ b/packages/cursorless-jetbrains/tsconfig.json @@ -25,5 +25,5 @@ "path": "../test-case-recorder" } ], - "include": ["src/**/*.ts", "src/**/*.json", "../../typings/**/*.d.ts"] + "include": ["src/**/*.ts", "src/**/*.json", "../../typings/**/object.d.ts"] } From 1798e430cade30f24b4cf59e144c390790172c79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Tue, 10 Dec 2024 07:55:32 +0100 Subject: [PATCH 17/39] Remove neovim references from jetbrains package --- packages/cursorless-jetbrains/TERMINOLOGY.md | 9 +++------ packages/cursorless-jetbrains/tsconfig.json | 6 ------ 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/packages/cursorless-jetbrains/TERMINOLOGY.md b/packages/cursorless-jetbrains/TERMINOLOGY.md index a8fadf07cc..bcad13f7fd 100644 --- a/packages/cursorless-jetbrains/TERMINOLOGY.md +++ b/packages/cursorless-jetbrains/TERMINOLOGY.md @@ -1,7 +1,4 @@ -# TextEditor/TextDocument vs Window/Buffer +# TextEditor/TextDocument vs Project/Editor -1. Each Cursorless "TextDocument" corresponds to a neovim "Buffer" -2. Each Cursorless "TextEditor" corresponds to a neovim "Window" -3. A "TextEditor" corresponds to a view of a "TextDocument". The same "TextDocument" can be opened in two different "TextEditor". -4. When a "Window" changes in neovim, we need to reflect its "TextEditor" -5. When a "Buffer" changes in neovim, we need to reflect its "TextDocument". +1. Each Cursorless "TextDocument" corresponds to a Jetbrains "Editor" tab +2. There is no specific handling of projects diff --git a/packages/cursorless-jetbrains/tsconfig.json b/packages/cursorless-jetbrains/tsconfig.json index 8d9093f102..9b4b0c1914 100644 --- a/packages/cursorless-jetbrains/tsconfig.json +++ b/packages/cursorless-jetbrains/tsconfig.json @@ -12,12 +12,6 @@ { "path": "../cursorless-engine" }, - { - "path": "../neovim-common" - }, - { - "path": "../neovim-registry" - }, { "path": "../node-common" }, From 863103d290812d6aeea5a4459eb42ab2cdb1d846 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Tue, 10 Dec 2024 08:02:47 +0100 Subject: [PATCH 18/39] update pnpm-lock.yaml --- pnpm-lock.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 623716e576..79d1e33e10 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -386,6 +386,12 @@ importers: '@cursorless/test-case-recorder': specifier: workspace:* version: link:../test-case-recorder + vscode-uri: + specifier: ^3.0.8 + version: 3.0.8 + web-tree-sitter: + specifier: 0.24.4 + version: 0.24.4 devDependencies: '@types/chai': specifier: ^5.0.0 @@ -9793,6 +9799,9 @@ packages: web-namespaces@2.0.1: resolution: {integrity: sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==} + web-tree-sitter@0.24.4: + resolution: {integrity: sha512-sETP1Sf9OTd4LusrKBNznNgTt3fWoWhJnAFaKPiGSeVKXJbZ72qoMpxddKMdVI5BgXv32OI7tkKQre5PmF9reA==} + webidl-conversions@3.0.1: resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} @@ -21430,6 +21439,8 @@ snapshots: web-namespaces@2.0.1: {} + web-tree-sitter@0.24.4: {} + webidl-conversions@3.0.1: {} webidl-conversions@7.0.0: {} From 8d3537291319ee8d674ea6094f990218995492e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Tue, 10 Dec 2024 10:53:25 +0100 Subject: [PATCH 19/39] fix various linting issues --- packages/cursorless-jetbrains/package.json | 7 ++----- .../src/ide/JetbrainsCommandServer.ts | 9 +-------- .../src/ide/JetbrainsConfiguration.ts | 1 - .../cursorless-jetbrains/src/ide/JetbrainsEvents.ts | 4 ++-- .../cursorless-jetbrains/src/ide/JetbrainsHats.ts | 2 +- .../cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 5 +---- .../src/ide/jetbrainsPerformEdits.ts | 1 - .../src/types/jetbrains.types.ts | 2 +- packages/cursorless-jetbrains/tsconfig.json | 7 +------ pnpm-lock.yaml | 12 ------------ tsconfig.json | 3 +++ 11 files changed, 12 insertions(+), 41 deletions(-) diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index a06aad6639..74eebe6919 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -4,6 +4,7 @@ "description": "cursorless in jetbrains", "main": "./out/cursorless.js", "private": true, + "type": "module", "scripts": { "build": "pnpm run esbuild:prod && pnpm run populate-dist", "compile": "tsc --build", @@ -35,10 +36,6 @@ "web-tree-sitter": "0.24.4" }, "devDependencies": { - "@types/chai": "^5.0.0", - "@types/js-yaml": "^4.0.9", - "@types/lodash": "4.17.10", - "@types/uuid": "^10.0.0", - "lodash": "^4.17.21" + "@types/chai": "^5.0.0" } } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts index 82bc2ac262..ed891a2d8a 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts @@ -1,8 +1 @@ -import type { CommandServerApi} from "@cursorless/common"; -import { JetbrainsClient } from "./JetbrainsClient"; - -export class JetbrainsCommandServer { - - - -} +export class JetbrainsCommandServer {} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts index a7633f17e8..2cdffe861b 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts @@ -1,4 +1,3 @@ -import { HatStability } from "@cursorless/common"; import { get } from "lodash"; import type { Configuration, diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts index 690d10858e..b478991ed3 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts @@ -7,13 +7,13 @@ import type { import { Position, Range } from "@cursorless/common"; export function jetbrainsOnDidChangeTextDocument( - listener: (event: TextDocumentChangeEvent) => void, + _listener: (event: TextDocumentChangeEvent) => void, ): Disposable { return dummyEvent(); } export function jetbrainsOnDidOpenTextDocument( - listener: (event: TextDocument) => any, + _listener: (event: TextDocument) => any, _thisArgs?: any, _disposables?: Disposable[] | undefined, ): Disposable { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index a1fab1384a..927c37ecb7 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -7,7 +7,7 @@ import type { } from "@cursorless/common"; import { Notifier } from "@cursorless/common"; import type { JetbrainsClient } from "./JetbrainsClient"; -import { JetbrainsHatRange } from "../types/jetbrains.types"; +import type { JetbrainsHatRange } from "../types/jetbrains.types"; const HAT_COLORS = [ "default", diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index c1a1ba6aed..448945b421 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -19,10 +19,7 @@ import type { } from "@cursorless/common"; import { pull } from "lodash"; import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; -import { - fromJetbrainsContentChange, - jetbrainsOnDidOpenTextDocument, -} from "./JetbrainsEvents"; +import { fromJetbrainsContentChange } from "./JetbrainsEvents"; import type { JetbrainsClient } from "./JetbrainsClient"; import { JetbrainsClipboard } from "./JetbrainsClipboard"; diff --git a/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts index a031cf1525..7e7c6a6ab8 100644 --- a/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts +++ b/packages/cursorless-jetbrains/src/ide/jetbrainsPerformEdits.ts @@ -1,6 +1,5 @@ import type { Edit } from "@cursorless/common"; import { type InMemoryTextDocument } from "@cursorless/common"; -import type { Jetbrains } from "../types/jetbrains.types"; import type { EditorEdit } from "../types/types"; import type { JetbrainsIDE } from "./JetbrainsIDE"; import type { JetbrainsClient } from "./JetbrainsClient"; diff --git a/packages/cursorless-jetbrains/src/types/jetbrains.types.ts b/packages/cursorless-jetbrains/src/types/jetbrains.types.ts index e81eb391c4..648f9077e6 100644 --- a/packages/cursorless-jetbrains/src/types/jetbrains.types.ts +++ b/packages/cursorless-jetbrains/src/types/jetbrains.types.ts @@ -1,4 +1,4 @@ -import { Range } from "@cursorless/common"; +import type { Range } from "@cursorless/common"; import type { EditorEdit, EditorState, SelectionOffsets } from "./types"; export type JetbrainsNamespace = "user"; diff --git a/packages/cursorless-jetbrains/tsconfig.json b/packages/cursorless-jetbrains/tsconfig.json index 9b4b0c1914..3782b54e28 100644 --- a/packages/cursorless-jetbrains/tsconfig.json +++ b/packages/cursorless-jetbrains/tsconfig.json @@ -1,9 +1,7 @@ { "extends": "../../tsconfig.base.json", "compilerOptions": { - "target": "ES2020", - "rootDir": "src", - "outDir": "out" + "target": "ES2020" }, "references": [ { @@ -12,9 +10,6 @@ { "path": "../cursorless-engine" }, - { - "path": "../node-common" - }, { "path": "../test-case-recorder" } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 79d1e33e10..ece52e246a 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -396,18 +396,6 @@ importers: '@types/chai': specifier: ^5.0.0 version: 5.0.0 - '@types/js-yaml': - specifier: ^4.0.9 - version: 4.0.9 - '@types/lodash': - specifier: 4.17.10 - version: 4.17.10 - '@types/uuid': - specifier: ^10.0.0 - version: 10.0.0 - lodash: - specifier: ^4.17.21 - version: 4.17.21 packages/cursorless-neovim: dependencies: diff --git a/tsconfig.json b/tsconfig.json index 20ea84c510..29f9d90f93 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -26,6 +26,9 @@ { "path": "./packages/cursorless-everywhere-talon-e2e" }, + { + "path": "./packages/cursorless-jetbrains" + }, { "path": "./packages/cursorless-neovim" }, From 5a8e4a32afa8d1ef2f742d727bd3c69d94491351 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Tue, 10 Dec 2024 12:52:32 +0100 Subject: [PATCH 20/39] fix more linting issues, and missing lodash dependency --- packages/cursorless-jetbrains/package.json | 4 +- .../src/ide/JetbrainsConfiguration.ts | 42 +------------------ .../src/ide/JetbrainsIDE.ts | 2 +- pnpm-lock.yaml | 6 +++ 4 files changed, 12 insertions(+), 42 deletions(-) diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 74eebe6919..9420936128 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -32,10 +32,12 @@ "@cursorless/common": "workspace:*", "@cursorless/cursorless-engine": "workspace:*", "@cursorless/test-case-recorder": "workspace:*", + "lodash-es": "^4.17.21", "vscode-uri": "^3.0.8", "web-tree-sitter": "0.24.4" }, "devDependencies": { - "@types/chai": "^5.0.0" + "@types/chai": "^5.0.0", + "@types/lodash-es": "4.17.12" } } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts index 2cdffe861b..3c8ebf6d72 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts @@ -1,4 +1,3 @@ -import { get } from "lodash"; import type { Configuration, ConfigurationScope, @@ -7,6 +6,7 @@ import type { import { CONFIGURATION_DEFAULTS } from "@cursorless/common"; import type { GetFieldType, Paths } from "@cursorless/common"; import { Notifier } from "@cursorless/common"; +import { get } from "lodash-es"; export class JetbrainsConfiguration implements Configuration { private notifier = new Notifier(); @@ -18,7 +18,7 @@ export class JetbrainsConfiguration implements Configuration { getOwnConfiguration>( path: Path, - scope?: ConfigurationScope, + _scope?: ConfigurationScope, ): GetFieldType { return get(this.configuration, path) as GetFieldType< CursorlessConfiguration, @@ -33,41 +33,3 @@ export class JetbrainsConfiguration implements Configuration { this.notifier.notifyListeners(); } } - -export function createJetbrainsConfiguration( - configuration: CursorlessConfiguration, -): JetbrainsConfiguration { - return new JetbrainsConfiguration(configuration); -} - -/** - * Gets a configuration value from jetbrains, with supported variables expanded. - * For example, `${userHome}` will be expanded to the user's home directory. - * - * We currently only support `${userHome}`. - * - * @param path The path to the configuration value, eg `cursorless.snippetsDir` - * @returns The configuration value, with variables expanded, or undefined if - * the value is not set - */ -export function jetbrainsGetConfigurationString( - path: string, -): string | undefined { - const index = path.lastIndexOf("."); - const section = path.substring(0, index); - const field = path.substring(index + 1); - // const value = "jetbrains.workspace.getConfiguration(section).get(field)"; - // return value != null ? evaluateStringVariables(value) : undefined; - return undefined; -} - -function evaluateStringVariables(value: string): string { - return value.replace(/\${(\w+)}/g, (match, variable) => { - switch (variable) { - case "userHome": - return "~/"; - default: - throw Error(`Unknown jetbrains configuration variable '${variable}'`); - } - }); -} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 448945b421..15bd80060c 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -17,7 +17,7 @@ import type { TextEditor, WorkspaceFolder, } from "@cursorless/common"; -import { pull } from "lodash"; +import { pull } from "lodash-es"; import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; import { fromJetbrainsContentChange } from "./JetbrainsEvents"; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ece52e246a..186e2557f8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -386,6 +386,9 @@ importers: '@cursorless/test-case-recorder': specifier: workspace:* version: link:../test-case-recorder + lodash-es: + specifier: ^4.17.21 + version: 4.17.21 vscode-uri: specifier: ^3.0.8 version: 3.0.8 @@ -396,6 +399,9 @@ importers: '@types/chai': specifier: ^5.0.0 version: 5.0.0 + '@types/lodash-es': + specifier: 4.17.12 + version: 4.17.12 packages/cursorless-neovim: dependencies: From e39d5b80eccdf902cec6e6187e5acfe55682b677 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Tue, 10 Dec 2024 13:24:19 +0100 Subject: [PATCH 21/39] dont break build --- .../scripts/populate-dist.sh | 6 +++ .../scripts/test-quickjs.sh | 45 ------------------- 2 files changed, 6 insertions(+), 45 deletions(-) create mode 100755 packages/cursorless-jetbrains/scripts/populate-dist.sh delete mode 100755 packages/cursorless-jetbrains/scripts/test-quickjs.sh diff --git a/packages/cursorless-jetbrains/scripts/populate-dist.sh b/packages/cursorless-jetbrains/scripts/populate-dist.sh new file mode 100755 index 0000000000..a8c27b8990 --- /dev/null +++ b/packages/cursorless-jetbrains/scripts/populate-dist.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +set -euo pipefail + +echo "Populating dist directory..." + +echo "Nothing to do yet..." diff --git a/packages/cursorless-jetbrains/scripts/test-quickjs.sh b/packages/cursorless-jetbrains/scripts/test-quickjs.sh deleted file mode 100755 index 83125aa022..0000000000 --- a/packages/cursorless-jetbrains/scripts/test-quickjs.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/env bash -set -euo pipefail -set -euo pipefail - -QUICKJS_VERSION=2024-01-13 - -echo $ cd out -cd out - -if [[ "$OSTYPE" == "darwin"* ]]; then - brew install quickjs - # Brew doesn't actually publish different versions of the quickjs binary - # brew install quickjs@$QUICKJS_VERSION - - echo $ qjs -I quickjsTest.mjs - qjs -I quickjsTest.mjs - - exit 0 -fi - -QUICKJS_URL_WIN=https://bellard.org/quickjs/binary_releases/quickjs-win-x86_64-$QUICKJS_VERSION.zip -QUICKJS_URL_LINUX=https://bellard.org/quickjs/binary_releases/quickjs-linux-x86_64-$QUICKJS_VERSION.zip -QUICKJS_FILE=quickjs.zip - -if [[ "$OSTYPE" == "linux-gnu"* ]]; then - QUICKJS_URL=$QUICKJS_URL_LINUX -elif [[ "$OSTYPE" == "cygwin" ]]; then - QUICKJS_URL=$QUICKJS_URL_WIN -elif [[ "$OSTYPE" == "msys" ]]; then - QUICKJS_URL=$QUICKJS_URL_WIN -elif [[ "$OSTYPE" == "win32" ]]; then - QUICKJS_URL=$QUICKJS_URL_WIN -else - echo "ERROR Unsupported OS: $OSTYPE" - exit 1 -fi - -echo $ curl -o $QUICKJS_FILE $QUICKJS_URL -curl -o $QUICKJS_FILE $QUICKJS_URL - -echo $ unzip $QUICKJS_FILE -unzip $QUICKJS_FILE - -echo $ ./qjs -I cursorless.js -./qjs --module cursorless.js From cd4c30a3ea52a792058679c75de886a42567a518 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Fri, 13 Dec 2024 09:52:22 +0100 Subject: [PATCH 22/39] add path shim for cross os path parsing --- packages/cursorless-jetbrains/package.json | 4 ++- .../cursorless-jetbrains/src/extension.ts | 2 +- .../src/ide/JetbrainsConfiguration.ts | 7 +++++ .../src/ide/JetbrainsTreeSitter.ts | 8 +++-- pnpm-lock.yaml | 30 ++++++++++++++----- 5 files changed, 39 insertions(+), 12 deletions(-) diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 9420936128..cbda3b1011 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -33,11 +33,13 @@ "@cursorless/cursorless-engine": "workspace:*", "@cursorless/test-case-recorder": "workspace:*", "lodash-es": "^4.17.21", + "path-browserify": "1.0.1", "vscode-uri": "^3.0.8", "web-tree-sitter": "0.24.4" }, "devDependencies": { "@types/chai": "^5.0.0", - "@types/lodash-es": "4.17.12" + "@types/lodash-es": "4.17.12", + "@types/path-browserify": "1.0.3" } } diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 2b74f05f20..6b1fb45a61 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -9,7 +9,7 @@ export async function activate( plugin: JetbrainsPlugin, wasmDirectory: string, ): Promise { - console.log("activate started"); + console.log("activate started with wasm dir " + wasmDirectory); await Parser.init({ locateFile(scriptName: string, _scriptDirectory: string) { console.log("locateFile called for " + scriptName); diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts index 3c8ebf6d72..803aaa09b4 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsConfiguration.ts @@ -33,3 +33,10 @@ export class JetbrainsConfiguration implements Configuration { this.notifier.notifyListeners(); } } + +export function createJetbrainsConfiguration( + configuration: CursorlessConfiguration, +): JetbrainsConfiguration { + return new JetbrainsConfiguration(configuration); +} + diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts index 89c089ae86..3795354de4 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -1,6 +1,7 @@ import type { Range, TextDocument, TreeSitter } from "@cursorless/common"; import type { Language, SyntaxNode, Tree } from "web-tree-sitter"; import Parser from "web-tree-sitter"; +import path from "path-browserify"; export class JetbrainsTreeSitter implements TreeSitter { constructor(private wasmDirectory: string) {} @@ -21,9 +22,10 @@ export class JetbrainsTreeSitter implements TreeSitter { async loadLanguage(languageId: string): Promise { console.log(`Loading language ${languageId}`); const parser = new Parser(); - const language = await Parser.Language.load( - `${this.wasmDirectory}/tree-sitter-${languageId}.wasm`, - ); + const dir = path.parse(this.wasmDirectory).dir; + const filePath = path.join(dir, `tree-sitter-${languageId}.wasm`); + console.log(`Loading language from ${filePath}`); + const language = await Parser.Language.load(filePath); parser.setLanguage(language); this.parsers.set(languageId, parser); return true; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 186e2557f8..0b33e173ef 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -45,7 +45,7 @@ importers: version: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) eslint-plugin-import: specifier: 2.31.0 - version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) + version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) eslint-plugin-mocha: specifier: 10.5.0 version: 10.5.0(eslint@8.57.1) @@ -389,6 +389,9 @@ importers: lodash-es: specifier: ^4.17.21 version: 4.17.21 + path-browserify: + specifier: 1.0.1 + version: 1.0.1 vscode-uri: specifier: ^3.0.8 version: 3.0.8 @@ -402,6 +405,9 @@ importers: '@types/lodash-es': specifier: 4.17.12 version: 4.17.12 + '@types/path-browserify': + specifier: 1.0.3 + version: 1.0.3 packages/cursorless-neovim: dependencies: @@ -3204,6 +3210,9 @@ packages: '@types/parse-json@4.0.2': resolution: {integrity: sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==} + '@types/path-browserify@1.0.3': + resolution: {integrity: sha512-ZmHivEbNCBtAfcrFeBCiTjdIc2dey0l7oCGNGpSuRTy8jP6UVND7oUowlvDujBy8r2Hoa8bfFUOCiPWfmtkfxw==} + '@types/prismjs@1.26.4': resolution: {integrity: sha512-rlAnzkW2sZOjbqZ743IHUhFcvzaGbqijwOu8QZnZCjfQzBqFE3s4lOTJEsxikImav9uzz/42I+O7YUs1mWgMlg==} @@ -7702,6 +7711,9 @@ packages: resolution: {integrity: sha512-gds5iRhSeOcDtj8gfWkRHLtZKTPsFVuh7utbjYtvnclw4XM+ffRzJrwqMhOD1PVqef7nBLmgsu1vIujjvAJrAw==} engines: {node: '>=4'} + path-browserify@1.0.1: + resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} + path-exists@3.0.0: resolution: {integrity: sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==} engines: {node: '>=4'} @@ -13399,6 +13411,8 @@ snapshots: '@types/parse-json@4.0.2': {} + '@types/path-browserify@1.0.3': {} + '@types/prismjs@1.26.4': {} '@types/prop-types@15.7.13': {} @@ -15464,7 +15478,7 @@ snapshots: eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) eslint-plugin-jsx-a11y: 6.10.0(eslint@8.57.1) eslint-plugin-react: 7.37.1(eslint@8.57.1) eslint-plugin-react-hooks: 5.0.0-canary-7118f5dd7-20230705(eslint@8.57.1) @@ -15493,20 +15507,20 @@ snapshots: debug: 4.3.7(supports-color@8.1.1) enhanced-resolve: 5.17.1 eslint: 8.57.1 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) fast-glob: 3.3.2 get-tsconfig: 4.8.1 is-bun-module: 1.2.1 is-glob: 4.0.3 optionalDependencies: - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) transitivePeerDependencies: - '@typescript-eslint/parser' - eslint-import-resolver-node - eslint-import-resolver-webpack - supports-color - eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): + eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): dependencies: debug: 3.2.7 optionalDependencies: @@ -15517,7 +15531,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): + eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.8 @@ -15528,7 +15542,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) hasown: 2.0.2 is-core-module: 2.15.1 is-glob: 4.0.3 @@ -19169,6 +19183,8 @@ snapshots: path-absolute@1.0.1: {} + path-browserify@1.0.1: {} + path-exists@3.0.0: {} path-exists@4.0.0: {} From d10638aa110c52a3edffae579fe3f76d97dcc730 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Fri, 13 Dec 2024 23:28:25 +0100 Subject: [PATCH 23/39] fix windows was path building --- packages/cursorless-jetbrains/package.json | 4 +-- .../cursorless-jetbrains/src/extension.ts | 7 ++-- .../src/ide/JetbrainsTreeSitter.ts | 12 +++---- pnpm-lock.yaml | 34 +++++-------------- 4 files changed, 19 insertions(+), 38 deletions(-) diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index cbda3b1011..9420936128 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -33,13 +33,11 @@ "@cursorless/cursorless-engine": "workspace:*", "@cursorless/test-case-recorder": "workspace:*", "lodash-es": "^4.17.21", - "path-browserify": "1.0.1", "vscode-uri": "^3.0.8", "web-tree-sitter": "0.24.4" }, "devDependencies": { "@types/chai": "^5.0.0", - "@types/lodash-es": "4.17.12", - "@types/path-browserify": "1.0.3" + "@types/lodash-es": "4.17.12" } } diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 6b1fb45a61..189e2db1f9 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -4,16 +4,17 @@ import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import Parser from "web-tree-sitter"; import { JetbrainsTreeSitter } from "./ide/JetbrainsTreeSitter"; import { JetbrainsTreeSitterQueryProvider } from "./ide/JetbrainsTreeSitterQueryProvider"; +import { pathJoin } from "./ide/pathJoin"; export async function activate( plugin: JetbrainsPlugin, wasmDirectory: string, ): Promise { - console.log("activate started with wasm dir " + wasmDirectory); + console.log("activate started"); await Parser.init({ locateFile(scriptName: string, _scriptDirectory: string) { - console.log("locateFile called for " + scriptName); - return wasmDirectory + scriptName; + const fullPath = pathJoin(wasmDirectory, scriptName); + return fullPath; }, }); console.log("Parser initialized"); diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts index 3795354de4..75d3fe8035 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -1,7 +1,7 @@ import type { Range, TextDocument, TreeSitter } from "@cursorless/common"; import type { Language, SyntaxNode, Tree } from "web-tree-sitter"; import Parser from "web-tree-sitter"; -import path from "path-browserify"; +import { pathJoin } from "./pathJoin"; export class JetbrainsTreeSitter implements TreeSitter { constructor(private wasmDirectory: string) {} @@ -9,7 +9,6 @@ export class JetbrainsTreeSitter implements TreeSitter { parsers = new Map(); getTree(document: TextDocument): Tree { - console.log(`get tree ${document.languageId}`); if (this.getLanguage(document.languageId)) { const parser = this.parsers.get(document.languageId); if (parser) { @@ -22,9 +21,10 @@ export class JetbrainsTreeSitter implements TreeSitter { async loadLanguage(languageId: string): Promise { console.log(`Loading language ${languageId}`); const parser = new Parser(); - const dir = path.parse(this.wasmDirectory).dir; - const filePath = path.join(dir, `tree-sitter-${languageId}.wasm`); - console.log(`Loading language from ${filePath}`); + const filePath = pathJoin( + this.wasmDirectory, + `tree-sitter-${languageId}.wasm`, + ); const language = await Parser.Language.load(filePath); parser.setLanguage(language); this.parsers.set(languageId, parser); @@ -32,12 +32,10 @@ export class JetbrainsTreeSitter implements TreeSitter { } getLanguage(languageId: string): Language | undefined { - console.log(`get language ${languageId}`); return this.parsers.get(languageId)?.getLanguage(); } getNodeAtLocation(document: TextDocument, range: Range): SyntaxNode { - console.log(`get node at ${document.languageId}`); const tree = this.getTree(document); const node = tree.rootNode.descendantForPosition( { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0b33e173ef..49fcc12cce 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -45,7 +45,7 @@ importers: version: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) eslint-plugin-import: specifier: 2.31.0 - version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + version: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) eslint-plugin-mocha: specifier: 10.5.0 version: 10.5.0(eslint@8.57.1) @@ -118,7 +118,7 @@ importers: version: 29.7.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.8))(esbuild@0.24.0)(jest@29.7.0(@types/node@20.16.0)(ts-node@10.9.2(@types/node@20.16.0)(typescript@5.6.3)))(typescript@5.6.3) + version: 29.2.5(@babel/core@7.25.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.8))(esbuild@0.24.0)(jest@29.7.0(@types/node@20.16.0))(typescript@5.6.3) typescript: specifier: ^5.6.3 version: 5.6.3 @@ -389,9 +389,6 @@ importers: lodash-es: specifier: ^4.17.21 version: 4.17.21 - path-browserify: - specifier: 1.0.1 - version: 1.0.1 vscode-uri: specifier: ^3.0.8 version: 3.0.8 @@ -405,9 +402,6 @@ importers: '@types/lodash-es': specifier: 4.17.12 version: 4.17.12 - '@types/path-browserify': - specifier: 1.0.3 - version: 1.0.3 packages/cursorless-neovim: dependencies: @@ -3210,9 +3204,6 @@ packages: '@types/parse-json@4.0.2': resolution: {integrity: sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==} - '@types/path-browserify@1.0.3': - resolution: {integrity: sha512-ZmHivEbNCBtAfcrFeBCiTjdIc2dey0l7oCGNGpSuRTy8jP6UVND7oUowlvDujBy8r2Hoa8bfFUOCiPWfmtkfxw==} - '@types/prismjs@1.26.4': resolution: {integrity: sha512-rlAnzkW2sZOjbqZ743IHUhFcvzaGbqijwOu8QZnZCjfQzBqFE3s4lOTJEsxikImav9uzz/42I+O7YUs1mWgMlg==} @@ -7711,9 +7702,6 @@ packages: resolution: {integrity: sha512-gds5iRhSeOcDtj8gfWkRHLtZKTPsFVuh7utbjYtvnclw4XM+ffRzJrwqMhOD1PVqef7nBLmgsu1vIujjvAJrAw==} engines: {node: '>=4'} - path-browserify@1.0.1: - resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} - path-exists@3.0.0: resolution: {integrity: sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==} engines: {node: '>=4'} @@ -13411,8 +13399,6 @@ snapshots: '@types/parse-json@4.0.2': {} - '@types/path-browserify@1.0.3': {} - '@types/prismjs@1.26.4': {} '@types/prop-types@15.7.13': {} @@ -15478,7 +15464,7 @@ snapshots: eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1))(eslint@8.57.1) - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) eslint-plugin-jsx-a11y: 6.10.0(eslint@8.57.1) eslint-plugin-react: 7.37.1(eslint@8.57.1) eslint-plugin-react-hooks: 5.0.0-canary-7118f5dd7-20230705(eslint@8.57.1) @@ -15507,20 +15493,20 @@ snapshots: debug: 4.3.7(supports-color@8.1.1) enhanced-resolve: 5.17.1 eslint: 8.57.1 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) fast-glob: 3.3.2 get-tsconfig: 4.8.1 is-bun-module: 1.2.1 is-glob: 4.0.3 optionalDependencies: - eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) transitivePeerDependencies: - '@typescript-eslint/parser' - eslint-import-resolver-node - eslint-import-resolver-webpack - supports-color - eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): + eslint-module-utils@2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): dependencies: debug: 3.2.7 optionalDependencies: @@ -15531,7 +15517,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1): + eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.8 @@ -15542,7 +15528,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.57.1 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-plugin-import@2.31.0)(eslint@8.57.1))(eslint@8.57.1) + eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.9.0(eslint@8.57.1)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3)(eslint@8.57.1) hasown: 2.0.2 is-core-module: 2.15.1 is-glob: 4.0.3 @@ -19183,8 +19169,6 @@ snapshots: path-absolute@1.0.1: {} - path-browserify@1.0.1: {} - path-exists@3.0.0: {} path-exists@4.0.0: {} @@ -21046,7 +21030,7 @@ snapshots: ts-interface-checker@0.1.13: {} - ts-jest@29.2.5(@babel/core@7.25.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.8))(esbuild@0.24.0)(jest@29.7.0(@types/node@20.16.0)(ts-node@10.9.2(@types/node@20.16.0)(typescript@5.6.3)))(typescript@5.6.3): + ts-jest@29.2.5(@babel/core@7.25.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.8))(esbuild@0.24.0)(jest@29.7.0(@types/node@20.16.0))(typescript@5.6.3): dependencies: bs-logger: 0.2.6 ejs: 3.1.10 From f6085bafc7cd956fdf507b421bbbbdd8f3833aac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sun, 15 Dec 2024 09:49:35 +0100 Subject: [PATCH 24/39] add missing pathjoin file --- packages/cursorless-jetbrains/src/ide/pathJoin.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 packages/cursorless-jetbrains/src/ide/pathJoin.ts diff --git a/packages/cursorless-jetbrains/src/ide/pathJoin.ts b/packages/cursorless-jetbrains/src/ide/pathJoin.ts new file mode 100644 index 0000000000..4dc6e56151 --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/pathJoin.ts @@ -0,0 +1,11 @@ +export function pathJoin(...segments: string[]): string { + return segments.join(pathSep()); +} + +function pathSep() { + if (/^win/i.test(process.platform)) { + return "\\"; + } else { + return "/"; + } +} From 31c678b9acac3d14f025821e4b7211fe8ba8281b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Mon, 16 Dec 2024 21:36:50 +0100 Subject: [PATCH 25/39] support editor visibility --- .../cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 1 + .../cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 12 ++++-------- packages/cursorless-jetbrains/src/types/types.ts | 1 + 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index 8089ca320a..e920f87a32 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -25,6 +25,7 @@ export class JetbrainsEditor implements EditableTextEditor { }; isActive = true; + isVisible = true; constructor( private client: JetbrainsClient, diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 15bd80060c..5879d06859 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -109,7 +109,7 @@ export class JetbrainsIDE implements IDE { get workspaceFolders(): readonly WorkspaceFolder[] | undefined { console.log("get workspaceFolders"); - throw new Error("workspaceFolders not implemented."); + throw new Error("workspaceFolders not get implemented."); } get activeTextEditor(): TextEditor | undefined { @@ -124,13 +124,7 @@ export class JetbrainsIDE implements IDE { get visibleTextEditors(): TextEditor[] { // console.log("get visibleTextEditors"); - //return [...this.editors.values()].filter((editor) => editor.isActive); - if (this.activeEditor) { - console.log("visible: " + this.activeEditor.id); - return [this.activeEditor]; - } else { - return []; - } + return [...this.editors.values()].filter((editor) => editor.isVisible); } getEditableTextEditor(editor: TextEditor): EditableTextEditor { @@ -293,6 +287,8 @@ function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { editor.selections = editorState.selections.map((selection) => createSelection(editor.document, selection), ); + editor.isActive = editorState.active; + editor.isVisible = editorState.visible; } function getLines(text: string, firstLine: number, lastLine: number) { diff --git a/packages/cursorless-jetbrains/src/types/types.ts b/packages/cursorless-jetbrains/src/types/types.ts index 99ffd9f490..fb0e355c49 100644 --- a/packages/cursorless-jetbrains/src/types/types.ts +++ b/packages/cursorless-jetbrains/src/types/types.ts @@ -25,6 +25,7 @@ export interface EditorState { lastVisibleLine: number; selections: JbSelection[]; active: boolean; + visible: boolean; } export interface EditorChange { From bdf7fdca5c4c9fcd1ebd787192bc6c67c54197ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 18 Dec 2024 08:53:19 +0100 Subject: [PATCH 26/39] implement flashranges for jetbrains --- .../src/ide/JetbrainsClient.ts | 1 + .../src/ide/JetbrainsFlashDescriptor.ts | 7 +++++++ .../cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 16 ++++++++++++++-- 3 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/ide/JetbrainsFlashDescriptor.ts diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index d08859953a..1e38756c29 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -9,4 +9,5 @@ export interface JetbrainsClient { insertLineAfter(editorId: string, rangesJson: string): void; revealLine(editorId: string, line: number, revealAt: string): void; readQuery(filename: string): string | undefined; + flashRanges(flashRangesJson: string): string | undefined; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsFlashDescriptor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsFlashDescriptor.ts new file mode 100644 index 0000000000..065e927b8b --- /dev/null +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsFlashDescriptor.ts @@ -0,0 +1,7 @@ +import type { GeneralizedRange } from "@cursorless/common"; + +export interface JetbrainsFlashDescriptor { + style: string; + editorId: string; + range: GeneralizedRange; +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 5879d06859..7dfb264e49 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -29,6 +29,9 @@ import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore"; import type { EditorState } from "../types/types"; import { createSelection, createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; +import { CharacterRange } from "../../../common/out/types/GeneralizedRange"; +import { ide } from "@cursorless/cursorless-engine"; +import { JetbrainsFlashDescriptor } from "./JetbrainsFlashDescriptor"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; @@ -93,8 +96,17 @@ export class JetbrainsIDE implements IDE { throw Error("setHighlightRanges Not implemented"); } - async flashRanges(_flashDescriptors: FlashDescriptor[]): Promise { - console.debug("flashRanges Not implemented"); + async flashRanges(flashDescriptors: FlashDescriptor[]): Promise { + console.log("flashRangeses"); + const jbfs = flashDescriptors.map((flashDescriptor) => { + const jbf: JetbrainsFlashDescriptor = { + editorId: flashDescriptor.editor.id, + range: flashDescriptor.range, + style: flashDescriptor.style, + }; + return jbf; + }); + this.client.flashRanges(JSON.stringify(jbfs)); } get assetsRoot(): string { From d8bbe845b595c0c1efc413661cbb3cf9af03462d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Wed, 18 Dec 2024 17:17:00 +0100 Subject: [PATCH 27/39] add support for prePhraseVersion --- .../cursorless-jetbrains/src/extension.ts | 3 +++ .../src/ide/JetbrainsClient.ts | 1 + .../src/ide/JetbrainsCommandServer.ts | 26 ++++++++++++++++++- .../src/ide/JetbrainsIDE.ts | 4 +-- 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 189e2db1f9..fab1f08f10 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -5,6 +5,7 @@ import Parser from "web-tree-sitter"; import { JetbrainsTreeSitter } from "./ide/JetbrainsTreeSitter"; import { JetbrainsTreeSitterQueryProvider } from "./ide/JetbrainsTreeSitterQueryProvider"; import { pathJoin } from "./ide/pathJoin"; +import { JetbrainsCommandServer } from "./ide/JetbrainsCommandServer"; export async function activate( plugin: JetbrainsPlugin, @@ -19,12 +20,14 @@ export async function activate( }); console.log("Parser initialized"); + const commandServerApi = new JetbrainsCommandServer(plugin.client); const queryProvider = new JetbrainsTreeSitterQueryProvider(plugin.ide); const engine = await createCursorlessEngine({ ide: plugin.ide, hats: plugin.hats, treeSitterQueryProvider: queryProvider, treeSitter: new JetbrainsTreeSitter(wasmDirectory), + commandServerApi: commandServerApi, }); console.log("activate completed"); return engine; diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts index 1e38756c29..1ac027e3b3 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsClient.ts @@ -1,4 +1,5 @@ export interface JetbrainsClient { + prePhraseVersion(): string | PromiseLike | null; clipboardCopy(editorId: string, rangesJson: string): void; clipboardPaste(editorId: string): void; hatsUpdated(hatsJson: string): void; diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts index ed891a2d8a..af97926609 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCommandServer.ts @@ -1 +1,25 @@ -export class JetbrainsCommandServer {} +import type { JetbrainsClient } from "./JetbrainsClient"; +import type { + CommandServerApi, + FocusedElementType, + InboundSignal, +} from "@cursorless/common"; + +export class JetbrainsCommandServer implements CommandServerApi { + private client!: JetbrainsClient; + readonly signals: { prePhrase: InboundSignal } = { + prePhrase: { + getVersion: async () => { + return this.client.prePhraseVersion(); + }, + }, + }; + + constructor(client: JetbrainsClient) { + this.client = client; + } + + getFocusedElementType(): Promise { + return Promise.resolve(undefined); + } +} diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 7dfb264e49..16de7d7d76 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -29,9 +29,7 @@ import { JetbrainsKeyValueStore } from "./JetbrainsKeyValueStore"; import type { EditorState } from "../types/types"; import { createSelection, createTextEditor } from "./createTextEditor"; import { JetbrainsEditor } from "./JetbrainsEditor"; -import { CharacterRange } from "../../../common/out/types/GeneralizedRange"; -import { ide } from "@cursorless/cursorless-engine"; -import { JetbrainsFlashDescriptor } from "./JetbrainsFlashDescriptor"; +import type { JetbrainsFlashDescriptor } from "./JetbrainsFlashDescriptor"; export class JetbrainsIDE implements IDE { readonly configuration: JetbrainsConfiguration; From 97218fa115e92f873c86ff6b47eca8c280b8d7fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sun, 22 Dec 2024 15:02:22 +0100 Subject: [PATCH 28/39] enable multiple hat styles --- .../src/ide/JetbrainsHats.ts | 43 ++++++++++++++----- .../src/ide/JetbrainsIDE.ts | 7 ++- 2 files changed, 39 insertions(+), 11 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index 927c37ecb7..b119129d30 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -2,6 +2,7 @@ import type { Disposable, HatRange, Hats, + HatStyleInfo, HatStyleMap, Listener, } from "@cursorless/common"; @@ -20,11 +21,16 @@ const HAT_COLORS = [ export class JetbrainsHats implements Hats { private isEnabledNotifier: Notifier<[boolean]> = new Notifier(); + private hatStyleChangedNotifier: Notifier<[HatStyleMap]> = new Notifier(); + private hatRanges: HatRange[] = []; private client: JetbrainsClient; + enabledHatStyles: HatStyleMap; + private enabledHatShapes = ["default"]; constructor(client: JetbrainsClient) { this.client = client; + this.enabledHatStyles = this.generateHatStyles(); } setHatRanges(hatRanges: HatRange[]): Promise { @@ -38,6 +44,12 @@ export class JetbrainsHats implements Hats { return Promise.resolve(); } + setEnabledHatShapes(enabledHatShapes: string[]): void { + this.enabledHatShapes = enabledHatShapes; + this.enabledHatStyles = this.generateHatStyles(); + this.hatStyleChangedNotifier.notifyListeners(this.enabledHatStyles); + } + toJetbransHatRanges(hatRanges: HatRange[]): JetbrainsHatRange[] { return hatRanges.map((range) => { return { @@ -48,20 +60,31 @@ export class JetbrainsHats implements Hats { }); } - enabledHatStyles: HatStyleMap = Object.fromEntries( - HAT_COLORS.map((color) => [ - color, - { penalty: color === "default" ? 0 : 1 }, - ]), - ); + private generateHatStyles(): HatStyleMap { + const res = new Map(); + for (const color of HAT_COLORS) { + const colorPenalty = color === "default" ? 0 : 1; + for (const shape of this.enabledHatShapes) { + const shapePenalty = shape === "default" ? 0 : 2; + let styleName: string; + if (shape === "default") { + styleName = color; + } else { + styleName = `${color}-${shape}`; + } + res.set(styleName, { penalty: colorPenalty + shapePenalty }); + } + } + return Object.fromEntries(res); + } - onDidChangeEnabledHatStyles(_listener: Listener<[HatStyleMap]>): Disposable { - return { dispose: () => {} }; + onDidChangeEnabledHatStyles(listener: Listener<[HatStyleMap]>): Disposable { + return this.hatStyleChangedNotifier.registerListener(listener); } isEnabled: boolean = true; - onDidChangeIsEnabled(_listener: Listener<[boolean]>): Disposable { - return { dispose: () => {} }; + onDidChangeIsEnabled(listener: Listener<[boolean]>): Disposable { + return this.isEnabledNotifier.registerListener(listener); } toggle(isEnabled?: boolean) { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 16de7d7d76..7d6663ce7b 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -292,7 +292,12 @@ function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { editorState.text, ); editor.visibleRanges = [ - new Range(editorState.firstVisibleLine, 0, editorState.lastVisibleLine, 0), + new Range( + editorState.firstVisibleLine, + 0, + editorState.lastVisibleLine + 1, + 0, + ), ]; editor.selections = editorState.selections.map((selection) => createSelection(editor.document, selection), From cfe93f927ebb37827122e9d4cf0c67227d06af25 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 28 Dec 2024 21:51:11 +0100 Subject: [PATCH 29/39] inject colors and shape settings from ide --- .../src/ide/JetbrainsHats.ts | 51 +++++++++++++++++-- 1 file changed, 48 insertions(+), 3 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index b119129d30..9b29a4e454 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -27,6 +27,9 @@ export class JetbrainsHats implements Hats { private client: JetbrainsClient; enabledHatStyles: HatStyleMap; private enabledHatShapes = ["default"]; + private hatShapePenalties: Map = new Map([["default", 0]]); + private enabledHatColors = ["default"]; + private hatColorPenalties: Map = new Map([["default", 0]]); constructor(client: JetbrainsClient) { this.client = client; @@ -50,6 +53,30 @@ export class JetbrainsHats implements Hats { this.hatStyleChangedNotifier.notifyListeners(this.enabledHatStyles); } + setHatShapePenalties(hatShapePenalties: Map): void { + // supplied map is a json map, and not a typescript map, so convert it to typed map + this.hatShapePenalties = new Map( + Object.entries(hatShapePenalties), + ); + this.enabledHatStyles = this.generateHatStyles(); + this.hatStyleChangedNotifier.notifyListeners(this.enabledHatStyles); + } + + setEnabledHatColors(enabledHatColors: string[]): void { + this.enabledHatColors = enabledHatColors; + this.enabledHatStyles = this.generateHatStyles(); + this.hatStyleChangedNotifier.notifyListeners(this.enabledHatStyles); + } + + setHatColorPenalties(hatColorPenalties: Map): void { + // supplied map is a json map, and not a typescript map, so convert it to typed map + this.hatColorPenalties = new Map( + Object.entries(hatColorPenalties), + ); + this.enabledHatStyles = this.generateHatStyles(); + this.hatStyleChangedNotifier.notifyListeners(this.enabledHatStyles); + } + toJetbransHatRanges(hatRanges: HatRange[]): JetbrainsHatRange[] { return hatRanges.map((range) => { return { @@ -62,10 +89,10 @@ export class JetbrainsHats implements Hats { private generateHatStyles(): HatStyleMap { const res = new Map(); - for (const color of HAT_COLORS) { - const colorPenalty = color === "default" ? 0 : 1; + for (const color of this.enabledHatColors) { + const colorPenalty = this.getColorPenalty(color); for (const shape of this.enabledHatShapes) { - const shapePenalty = shape === "default" ? 0 : 2; + const shapePenalty = this.getShapePenalty(shape); let styleName: string; if (shape === "default") { styleName = color; @@ -78,6 +105,24 @@ export class JetbrainsHats implements Hats { return Object.fromEntries(res); } + private getShapePenalty(shape: string) { + let shapePenalty = this.hatShapePenalties.get(shape); + if (shapePenalty == null) { + shapePenalty = shape === "default" ? 0 : 2; + } else { + shapePenalty = shape === "default" ? shapePenalty : shapePenalty + 1; + } + return shapePenalty; + } + + private getColorPenalty(color: string) { + let colorPenalty = this.hatColorPenalties.get(color); + if (colorPenalty == null) { + colorPenalty = color === "default" ? 0 : 1; + } + return colorPenalty; + } + onDidChangeEnabledHatStyles(listener: Listener<[HatStyleMap]>): Disposable { return this.hatStyleChangedNotifier.registerListener(listener); } From 6370683c44cfade5f54f952e4b0513e915b71b96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 9 Jan 2025 07:30:12 +0100 Subject: [PATCH 30/39] jetbrains: use "go to declaration" for "follow" command --- packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 2 +- packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index e920f87a32..8119e0e5f3 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -186,7 +186,7 @@ export class JetbrainsEditor implements EditableTextEditor { range ? [range] : [], true, false, - "QuickImplementations", + "GotoDeclaration", ); await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index 9b29a4e454..a3df17c819 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -10,15 +10,6 @@ import { Notifier } from "@cursorless/common"; import type { JetbrainsClient } from "./JetbrainsClient"; import type { JetbrainsHatRange } from "../types/jetbrains.types"; -const HAT_COLORS = [ - "default", - "blue", - "green", - "red", - "pink", - "yellow", -] as const; - export class JetbrainsHats implements Hats { private isEnabledNotifier: Notifier<[boolean]> = new Notifier(); private hatStyleChangedNotifier: Notifier<[HatStyleMap]> = new Notifier(); From 43ba5ac38b9368458ab597322a08c99034fb1625 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 9 Jan 2025 08:30:00 +0100 Subject: [PATCH 31/39] improve editable editor support - add editable state --- .../src/ide/JetbrainsEditor.ts | 1 + .../cursorless-jetbrains/src/ide/JetbrainsHats.ts | 2 +- .../cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 15 ++++++++++----- packages/cursorless-jetbrains/src/types/types.ts | 1 + 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index 8119e0e5f3..f23c3c2813 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -26,6 +26,7 @@ export class JetbrainsEditor implements EditableTextEditor { isActive = true; isVisible = true; + isEditable = true; constructor( private client: JetbrainsClient, diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index a3df17c819..b9af510e90 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -21,6 +21,7 @@ export class JetbrainsHats implements Hats { private hatShapePenalties: Map = new Map([["default", 0]]); private enabledHatColors = ["default"]; private hatColorPenalties: Map = new Map([["default", 0]]); + isEnabled: boolean = true; constructor(client: JetbrainsClient) { this.client = client; @@ -118,7 +119,6 @@ export class JetbrainsHats implements Hats { return this.hatStyleChangedNotifier.registerListener(listener); } - isEnabled: boolean = true; onDidChangeIsEnabled(listener: Listener<[boolean]>): Disposable { return this.isEnabledNotifier.registerListener(listener); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 7d6663ce7b..4d30043354 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -124,12 +124,12 @@ export class JetbrainsIDE implements IDE { get activeTextEditor(): TextEditor | undefined { // console.log("get activeTextEditor"); - return this.activeEditableTextEditor; + return this.activeEditor; } get activeEditableTextEditor(): EditableTextEditor | undefined { // console.log("get activeEditableTextEditor"); - return this.activeEditor; + return this.activeEditor?.isEditable ? this.activeEditor : undefined; } get visibleTextEditors(): TextEditor[] { @@ -137,11 +137,15 @@ export class JetbrainsIDE implements IDE { return [...this.editors.values()].filter((editor) => editor.isVisible); } - getEditableTextEditor(editor: TextEditor): EditableTextEditor { - // console.log("getEditableTextEditor"); + getEditableTextEditor(editor: TextEditor): EditableTextEditor { + console.log("getEditableTextEditor"); if (editor instanceof JetbrainsEditor) { console.log("getEditableTextEditor - return current"); - return editor; + if (editor.isEditable) { + return editor; + } else { + throw Error(`Editor is not editable: ${editor}`); + } } throw Error(`Unsupported text editor type: ${editor}`); } @@ -304,6 +308,7 @@ function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { ); editor.isActive = editorState.active; editor.isVisible = editorState.visible; + editor.isEditable = editorState.editable; } function getLines(text: string, firstLine: number, lastLine: number) { diff --git a/packages/cursorless-jetbrains/src/types/types.ts b/packages/cursorless-jetbrains/src/types/types.ts index fb0e355c49..b8a4ba44fe 100644 --- a/packages/cursorless-jetbrains/src/types/types.ts +++ b/packages/cursorless-jetbrains/src/types/types.ts @@ -26,6 +26,7 @@ export interface EditorState { selections: JbSelection[]; active: boolean; visible: boolean; + editable: boolean; } export interface EditorChange { From d1334f275804f229ca17b1ec1cd3088e72bb9744 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Fri, 17 Jan 2025 21:32:50 +0100 Subject: [PATCH 32/39] add cursorless tag for jetbrains app --- cursorless-talon/src/apps/cursorless_jetbrains.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 cursorless-talon/src/apps/cursorless_jetbrains.py diff --git a/cursorless-talon/src/apps/cursorless_jetbrains.py b/cursorless-talon/src/apps/cursorless_jetbrains.py new file mode 100644 index 0000000000..fe5ec8727d --- /dev/null +++ b/cursorless-talon/src/apps/cursorless_jetbrains.py @@ -0,0 +1,9 @@ +from talon import Context, actions + +ctx = Context() + +ctx.matches = r""" +app: jetbrains +""" + +ctx.tags = ["user.cursorless"] From f32055d9a8d978b423a0bfbd661485ff224458ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sun, 26 Jan 2025 14:40:31 +0100 Subject: [PATCH 33/39] update to newest cursorless reduce logging. --- .../cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 6 +++--- .../cursorless-jetbrains/src/ide/JetbrainsEvents.ts | 12 ++++++------ .../cursorless-jetbrains/src/ide/JetbrainsHats.ts | 2 +- .../cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 6 ++++-- .../src/ide/JetbrainsTreeSitter.ts | 2 +- .../src/ide/JetbrainsTreeSitterQueryProvider.ts | 2 +- .../cursorless-jetbrains/src/ide/createTextEditor.ts | 4 ++-- .../cursorless-jetbrains/src/ide/setSelections.ts | 4 ++-- .../cursorless-jetbrains/src/settimeout-polyfill.ts | 5 +++++ 9 files changed, 25 insertions(+), 18 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/settimeout-polyfill.ts diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index f23c3c2813..580cfe541b 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -45,7 +45,7 @@ export class JetbrainsEditor implements EditableTextEditor { selections: Selection[], _opts?: SetSelectionsOpts, ): Promise { - console.log("editor.setSelections"); + // console.log("editor.setSelections"); if (!selectionsEqual(this.selections, selections)) { await setSelections(this.client, this.document, this.id, selections); this.selections = selections; @@ -53,7 +53,7 @@ export class JetbrainsEditor implements EditableTextEditor { } edit(edits: Edit[]): Promise { - console.log("editor.edit"); + // console.log("editor.edit"); jetbrainsPerformEdits(this.client, this.ide, this.document, this.id, edits); return Promise.resolve(true); } @@ -220,7 +220,7 @@ export class JetbrainsEditor implements EditableTextEditor { await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } - editNewNotebookCellAbove(): Promise<(_selection: Selection) => Selection> { + editNewNotebookCellAbove(): Promise { throw new Error("editNewNotebookCellAbove not implemented."); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts index b478991ed3..78290ddf8c 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEvents.ts @@ -28,9 +28,9 @@ export function fromJetbrainsContentChange( ): TextDocumentContentChangeEvent[] { const result = []; const text = linedata.join("\n"); - console.debug( - `fromJetbrainsContentChange(): document.getText(): '${document.getText()}'`, - ); + // console.debug( + // `fromJetbrainsContentChange(): document.getText(): '${document.getText()}'`, + // ); const range = new Range( new Position(firstLine, 0), new Position(lastLine - 1, document.lineAt(lastLine - 1).text.length), @@ -43,9 +43,9 @@ export function fromJetbrainsContentChange( rangeLength: rangeLength, text: text, }); - console.debug( - `fromJetbrainsContentChange(): changes=${JSON.stringify(result)}`, - ); + // console.debug( + // `fromJetbrainsContentChange(): changes=${JSON.stringify(result)}`, + // ); return result; } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts index b9af510e90..d39a0112e7 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsHats.ts @@ -29,7 +29,7 @@ export class JetbrainsHats implements Hats { } setHatRanges(hatRanges: HatRange[]): Promise { - console.log("ASOEE/CL: JetbrainsHats.setHatRanges : " + hatRanges.length); + // console.log("ASOEE/CL: JetbrainsHats.setHatRanges : " + hatRanges.length); this.hatRanges = hatRanges; const jbHatRanges = this.toJetbransHatRanges(hatRanges); diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 4d30043354..1934f876e7 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -16,6 +16,7 @@ import type { TextDocumentChangeEvent, TextEditor, WorkspaceFolder, + NotebookEditor, } from "@cursorless/common"; import { pull } from "lodash-es"; import { JetbrainsCapabilities } from "./JetbrainsCapabilities"; @@ -38,6 +39,7 @@ export class JetbrainsIDE implements IDE { readonly clipboard: JetbrainsClipboard; readonly capabilities: JetbrainsCapabilities; readonly runMode: RunMode = "development"; + readonly visibleNotebookEditors: NotebookEditor[] = []; // private editorMap; // private documentMap; private activeProject: Window | undefined; @@ -138,9 +140,9 @@ export class JetbrainsIDE implements IDE { } getEditableTextEditor(editor: TextEditor): EditableTextEditor { - console.log("getEditableTextEditor"); + // console.log("getEditableTextEditor"); if (editor instanceof JetbrainsEditor) { - console.log("getEditableTextEditor - return current"); + // console.log("getEditableTextEditor - return current"); if (editor.isEditable) { return editor; } else { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts index 75d3fe8035..b1ecedf226 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -19,7 +19,7 @@ export class JetbrainsTreeSitter implements TreeSitter { } async loadLanguage(languageId: string): Promise { - console.log(`Loading language ${languageId}`); + // console.log(`Loading language ${languageId}`); const parser = new Parser(); const filePath = pathJoin( this.wasmDirectory, diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts index abb61f0d60..54b98484cf 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitterQueryProvider.ts @@ -16,7 +16,7 @@ export class JetbrainsTreeSitterQueryProvider onChanges = this.notifier.registerListener; async readQuery(filename: string): Promise { - console.log("readQuery", filename); + // console.log("readQuery", filename); const queryContents = await this.ide.readQuery(filename); return queryContents; } diff --git a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts index e8e0982f88..ea6292d763 100644 --- a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts @@ -16,7 +16,7 @@ export function createTextEditor( ide: JetbrainsIDE, editorState: EditorState, ): JetbrainsEditor { - console.log("createTextEditor"); + // console.log("createTextEditor"); const id = editorState.id; const uri = URI.parse(`talon-jetbrains://${id}`); @@ -43,7 +43,7 @@ export function createSelection( document: TextDocument, selection: JbSelection, ): Selection { - console.log("createSelection " + JSON.stringify(selection)); + // console.log("createSelection " + JSON.stringify(selection)); return new Selection( createPosition(selection.anchor), createPosition(selection.active), diff --git a/packages/cursorless-jetbrains/src/ide/setSelections.ts b/packages/cursorless-jetbrains/src/ide/setSelections.ts index 39f7413d9d..80905572c6 100644 --- a/packages/cursorless-jetbrains/src/ide/setSelections.ts +++ b/packages/cursorless-jetbrains/src/ide/setSelections.ts @@ -7,9 +7,9 @@ export function setSelections( editorId: string, selections: Selection[], ): Promise { - console.log("setSelections: " + selections); + // console.log("setSelections: " + selections); const selectionsJson = JSON.stringify(selections); - console.log("setSelections JSON: " + selectionsJson); + // console.log("setSelections JSON: " + selectionsJson); client.setSelection(editorId, selectionsJson); return Promise.resolve(); } diff --git a/packages/cursorless-jetbrains/src/settimeout-polyfill.ts b/packages/cursorless-jetbrains/src/settimeout-polyfill.ts new file mode 100644 index 0000000000..08f59e28bc --- /dev/null +++ b/packages/cursorless-jetbrains/src/settimeout-polyfill.ts @@ -0,0 +1,5 @@ +const global = globalThis as any; + +global.setTimeout = (callback: () => void, _delay: number) => { + callback(); +}; From 3b24f521aa64b33c0575bb939d3a78761f865ed2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sun, 26 Jan 2025 14:58:18 +0100 Subject: [PATCH 34/39] change default runmode to production --- packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 1934f876e7..2bcf2936a2 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -38,7 +38,7 @@ export class JetbrainsIDE implements IDE { readonly messages: JetbrainsMessages; readonly clipboard: JetbrainsClipboard; readonly capabilities: JetbrainsCapabilities; - readonly runMode: RunMode = "development"; + readonly runMode: RunMode = "production"; readonly visibleNotebookEditors: NotebookEditor[] = []; // private editorMap; // private documentMap; From 5a88ab281faadd4eb4b8813fd73bb6a384ebd428 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 28 Jun 2025 21:02:22 +0200 Subject: [PATCH 35/39] map openlink to go to declaration --- .../cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index 580cfe541b..5d694642f4 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -102,11 +102,17 @@ export class JetbrainsEditor implements EditableTextEditor { await this.client.revealLine(this.id, lineNumber, at); } - openLink( - _range: Range, + async openLink( + range: Range, _options?: OpenLinkOptions | undefined, ): Promise { - throw new Error("openLink not implemented."); + const command = new JetbrainsEditorCommand( + [range], + true, + false, + "GotoDeclaration", + ); + await this.client.executeRangeCommand(this.id, JSON.stringify(command)); } async fold(ranges?: Range[] | undefined): Promise { From e421e5cbcade9d9133913cda4c7324f54bb25ab5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sat, 28 Jun 2025 23:39:46 +0200 Subject: [PATCH 36/39] compile fixes after merge from main --- packages/cursorless-jetbrains/package.json | 6 +- .../cursorless-jetbrains/src/extension.ts | 3 +- .../cursorless-jetbrains/src/globals.d.ts | 9 + .../src/ide/JetbrainsCapabilities.ts | 4 + .../src/ide/JetbrainsEditor.ts | 20 +- .../src/ide/JetbrainsTreeSitter.ts | 34 +- pnpm-lock.yaml | 1785 +++++++++++------ 7 files changed, 1203 insertions(+), 658 deletions(-) create mode 100644 packages/cursorless-jetbrains/src/globals.d.ts diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 9420936128..02a17ec58d 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -33,11 +33,11 @@ "@cursorless/cursorless-engine": "workspace:*", "@cursorless/test-case-recorder": "workspace:*", "lodash-es": "^4.17.21", - "vscode-uri": "^3.0.8", - "web-tree-sitter": "0.24.4" + "vscode-uri": "^3.1.0", + "web-tree-sitter": "0.25.6" }, "devDependencies": { - "@types/chai": "^5.0.0", + "@types/chai": "^5.2.2", "@types/lodash-es": "4.17.12" } } diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index fab1f08f10..9aef71a172 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -1,7 +1,8 @@ import type { CursorlessEngine } from "@cursorless/cursorless-engine"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; -import Parser from "web-tree-sitter"; +import { Parser } from "web-tree-sitter"; +import "./globals"; import { JetbrainsTreeSitter } from "./ide/JetbrainsTreeSitter"; import { JetbrainsTreeSitterQueryProvider } from "./ide/JetbrainsTreeSitterQueryProvider"; import { pathJoin } from "./ide/pathJoin"; diff --git a/packages/cursorless-jetbrains/src/globals.d.ts b/packages/cursorless-jetbrains/src/globals.d.ts new file mode 100644 index 0000000000..cebbe43c22 --- /dev/null +++ b/packages/cursorless-jetbrains/src/globals.d.ts @@ -0,0 +1,9 @@ +// Global type declarations for cursorless-jetbrains + +declare global { + interface EmscriptenModule { + locateFile?: (path: string, prefix: string) => string; + } +} + +export {}; \ No newline at end of file diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts index 8d4d8b1f14..f2907ae145 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsCapabilities.ts @@ -18,6 +18,10 @@ const COMMAND_CAPABILITIES: CommandCapabilityMap = { unfold: { acceptsLocation: true }, showReferences: { acceptsLocation: true }, insertLineAfter: { acceptsLocation: true }, + gitAccept: { acceptsLocation: false }, + gitRevert: { acceptsLocation: false }, + gitStage: { acceptsLocation: false }, + gitUnstage: { acceptsLocation: false }, }; export class JetbrainsCapabilities implements Capabilities { diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index 5d694642f4..ab6c0cbb11 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -1,9 +1,9 @@ import type { Selection } from "@cursorless/common"; import { selectionsEqual, - type BreakpointDescriptor, type Edit, type EditableTextEditor, + type GeneralizedRange, type InMemoryTextDocument, type OpenLinkOptions, type Range, @@ -136,7 +136,7 @@ export class JetbrainsEditor implements EditableTextEditor { } async toggleBreakpoint( - _descriptors?: BreakpointDescriptor[] | undefined, + _ranges?: GeneralizedRange[] | undefined, ): Promise { throw new Error("toggleBreakpoint not implemented."); } @@ -233,4 +233,20 @@ export class JetbrainsEditor implements EditableTextEditor { editNewNotebookCellBelow(): Promise { throw new Error("editNewNotebookCellBelow not implemented."); } + + async gitAccept(_range?: Range): Promise { + throw new Error("gitAccept not implemented."); + } + + async gitRevert(_range?: Range): Promise { + throw new Error("gitRevert not implemented."); + } + + async gitStage(_range?: Range): Promise { + throw new Error("gitStage not implemented."); + } + + async gitUnstage(_range?: Range): Promise { + throw new Error("gitUnstage not implemented."); + } } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts index b1ecedf226..83d8b4cdbb 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -1,6 +1,6 @@ import type { Range, TextDocument, TreeSitter } from "@cursorless/common"; -import type { Language, SyntaxNode, Tree } from "web-tree-sitter"; -import Parser from "web-tree-sitter"; +import type { Language, Query, Node, Tree } from "web-tree-sitter"; +import { Parser, Language as ParserLanguage } from "web-tree-sitter"; import { pathJoin } from "./pathJoin"; export class JetbrainsTreeSitter implements TreeSitter { @@ -12,7 +12,11 @@ export class JetbrainsTreeSitter implements TreeSitter { if (this.getLanguage(document.languageId)) { const parser = this.parsers.get(document.languageId); if (parser) { - return parser.parse(document.getText()); + const tree = parser.parse(document.getText()); + if (!tree) { + throw new Error("Failed to parse document"); + } + return tree; } } throw new Error("Language not supported"); @@ -25,17 +29,18 @@ export class JetbrainsTreeSitter implements TreeSitter { this.wasmDirectory, `tree-sitter-${languageId}.wasm`, ); - const language = await Parser.Language.load(filePath); + const language = await ParserLanguage.load(filePath); parser.setLanguage(language); this.parsers.set(languageId, parser); return true; } getLanguage(languageId: string): Language | undefined { - return this.parsers.get(languageId)?.getLanguage(); + const parser = this.parsers.get(languageId); + return parser?.language || undefined; } - getNodeAtLocation(document: TextDocument, range: Range): SyntaxNode { + getNodeAtLocation(document: TextDocument, range: Range): Node { const tree = this.getTree(document); const node = tree.rootNode.descendantForPosition( { @@ -47,6 +52,23 @@ export class JetbrainsTreeSitter implements TreeSitter { column: range.end.character, }, ); + if (!node) { + throw new Error("Node not found at location"); + } return node; } + + createQuery(languageId: string, source: string): Query | undefined { + const language = this.getLanguage(languageId); + if (!language) { + return undefined; + } + + try { + return language.query(source); + } catch (error) { + console.error(`Failed to create query for language ${languageId}:`, error); + return undefined; + } + } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a43ca6adcc..c3e7e8b5ad 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -118,7 +118,7 @@ importers: version: 30.0.0 ts-jest: specifier: 29.4.0 - version: 29.4.0(@babel/core@7.27.4)(@jest/transform@30.0.0)(@jest/types@30.0.0)(babel-jest@30.0.0(@babel/core@7.27.4))(esbuild@0.25.5)(jest-util@30.0.0)(jest@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)))(typescript@5.8.3) + version: 29.4.0(@babel/core@7.27.7)(@jest/transform@30.0.2)(@jest/types@30.0.1)(babel-jest@30.0.2(@babel/core@7.27.7))(esbuild@0.25.5)(jest-util@30.0.2)(jest@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)))(typescript@5.8.3) typescript: specifier: 5.8.3 version: 5.8.3 @@ -137,7 +137,7 @@ importers: devDependencies: '@effortlessmotion/html-webpack-inline-source-plugin': specifier: 1.0.3 - version: 1.0.3(html-webpack-plugin@5.6.3(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 1.0.3(html-webpack-plugin@5.6.3(webpack@5.99.9))(webpack@5.99.9) '@testing-library/dom': specifier: 10.4.0 version: 10.4.0 @@ -158,19 +158,19 @@ importers: version: 19.1.6(@types/react@19.1.8) '@types/webpack': specifier: 5.28.5 - version: 5.28.5(esbuild@0.25.5)(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9)) + version: 5.28.5(esbuild@0.25.5)(webpack-cli@6.0.1) '@webpack-cli/generators': specifier: 3.0.7 - version: 3.0.7(encoding@0.1.13)(mem-fs@2.3.0)(prettier@3.3.3)(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 3.0.7(encoding@0.1.13)(mem-fs@2.3.0)(prettier@3.3.3)(webpack-cli@6.0.1)(webpack@5.99.9) autoprefixer: specifier: 10.4.21 version: 10.4.21(postcss@8.5.5) css-loader: specifier: 7.1.2 - version: 7.1.2(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 7.1.2(webpack@5.99.9) html-webpack-plugin: specifier: 5.6.3 - version: 5.6.3(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 5.6.3(webpack@5.99.9) jest: specifier: 30.0.0 version: 30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)) @@ -179,16 +179,16 @@ importers: version: 8.5.5 postcss-loader: specifier: 8.1.1 - version: 8.1.1(postcss@8.5.5)(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 8.1.1(postcss@8.5.5)(typescript@5.8.3)(webpack@5.99.9) style-loader: specifier: 4.0.0 - version: 4.0.0(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 4.0.0(webpack@5.99.9) tailwindcss: specifier: 3.4.17 version: 3.4.17(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)) ts-loader: specifier: 9.5.2 - version: 9.5.2(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + version: 9.5.2(typescript@5.8.3)(webpack@5.99.9) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@20.17.50)(typescript@5.8.3) @@ -378,6 +378,34 @@ importers: specifier: 11.6.0 version: 11.6.0 + packages/cursorless-jetbrains: + dependencies: + '@cursorless/common': + specifier: workspace:* + version: link:../common + '@cursorless/cursorless-engine': + specifier: workspace:* + version: link:../cursorless-engine + '@cursorless/test-case-recorder': + specifier: workspace:* + version: link:../test-case-recorder + lodash-es: + specifier: ^4.17.21 + version: 4.17.21 + vscode-uri: + specifier: ^3.1.0 + version: 3.1.0 + web-tree-sitter: + specifier: 0.25.6 + version: 0.25.6 + devDependencies: + '@types/chai': + specifier: ^5.2.2 + version: 5.2.2 + '@types/lodash-es': + specifier: 4.17.12 + version: 4.17.12 + packages/cursorless-neovim: dependencies: '@cursorless/common': @@ -590,7 +618,7 @@ importers: version: 8.5.5 tailwindcss: specifier: 3.4.17 - version: 3.4.17(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)) + version: 3.4.17(ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3)) typescript: specifier: 5.8.3 version: 5.8.3 @@ -792,7 +820,7 @@ importers: version: 1.57.5 tailwindcss: specifier: 3.4.17 - version: 3.4.17(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)) + version: 3.4.17(ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3)) packages/meta-updater: dependencies: @@ -1109,6 +1137,10 @@ packages: resolution: {integrity: sha512-bXYxrXFubeYdvB0NhD/NBB3Qi6aZeV20GOWVI47t2dkecCEoneR4NPVcb7abpXDEvejgrUfFtG6vG/zxAKmg+g==} engines: {node: '>=6.9.0'} + '@babel/core@7.27.7': + resolution: {integrity: sha512-BU2f9tlKQ5CAthiMIgpzAh4eDTLWo1mqi9jqE2OxMG0E/OM199VJt2q8BztTxpnSW0i1ymdwLXRJnYzvDM5r2w==} + engines: {node: '>=6.9.0'} + '@babel/generator@7.27.5': resolution: {integrity: sha512-ZGhA37l0e/g2s1Cnzdix0O3aLYm66eF8aufiVteOgnwxgnRP8GoyMj7VWsgWnQbVKXyge7hqrFh2K2TQM6t1Hw==} engines: {node: '>=6.9.0'} @@ -1201,6 +1233,11 @@ packages: engines: {node: '>=6.0.0'} hasBin: true + '@babel/parser@7.27.7': + resolution: {integrity: sha512-qnzXzDXdr/po3bOTbTIQZ7+TxNKxpkN5IifVLXS+r7qwynkZfPyjZfE7hCXbo7IoO9TNcSyibgONsf2HauUd3Q==} + engines: {node: '>=6.0.0'} + hasBin: true + '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.27.1': resolution: {integrity: sha512-QPG3C9cCVRQLxAVwmefEmwdTanECuUBMQZ/ym5kiw3XKCGA7qkuQLcjWWHcrD/GKbn/WmJwaezfuuAOcyKlRPA==} engines: {node: '>=6.9.0'} @@ -1726,10 +1763,18 @@ packages: resolution: {integrity: sha512-oNcu2QbHqts9BtOWJosOVJapWjBDSxGCpFvikNR5TGDYDQf3JwpIoMzIKrvfoti93cLfPJEG4tH9SPVeyCGgdA==} engines: {node: '>=6.9.0'} + '@babel/traverse@7.27.7': + resolution: {integrity: sha512-X6ZlfR/O/s5EQ/SnUSLzr+6kGnkg8HXGMzpgsMsrJVcfDtH1vIp6ctCN4eZ1LS5c0+te5Cb6Y514fASjMRJ1nw==} + engines: {node: '>=6.9.0'} + '@babel/types@7.27.6': resolution: {integrity: sha512-ETyHEk2VHHvl9b9jZP5IHPavHYk57EhanlRRuae9XCpb/j5bDCbPPMOBfCWhnl/7EDJz0jEMCi/RhccCE8r1+Q==} engines: {node: '>=6.9.0'} + '@babel/types@7.27.7': + resolution: {integrity: sha512-8OLQgDScAOHXnAz2cV+RfzzNMipuLVBz2biuAJFMV9bfkNf393je3VM8CLkjQodW5+iWsSJdSgSWT6rsZoXHPw==} + engines: {node: '>=6.9.0'} + '@bcoe/v8-coverage@0.2.3': resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} @@ -2377,12 +2422,12 @@ packages: resolution: {integrity: sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ==} engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} - '@eslint/config-array@0.20.0': - resolution: {integrity: sha512-fxlS1kkIjx8+vy2SjuCB94q3htSNrufYTXubwiBFeaQHbH6Ipi43gFJq2zCMt6PHhImH3Xmr0NksKDvchWlpQQ==} + '@eslint/config-array@0.20.1': + resolution: {integrity: sha512-OL0RJzC/CBzli0DrrR31qzj6d6i6Mm3HByuhflhl4LOBiWxN+3i6/t/ZQQNii4tjksXi8r2CRW1wMpWA2ULUEw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@eslint/config-helpers@0.2.2': - resolution: {integrity: sha512-+GPzk8PlG0sPpzdU5ZvIRMPidzAnZDl/s9L+y13iodqvb8leL53bTannOrQ/Im7UkpsmFU5Ily5U60LWixnmLg==} + '@eslint/config-helpers@0.2.3': + resolution: {integrity: sha512-u180qk2Um1le4yf0ruXH3PYFeEZeYC3p/4wCTKrr2U1CmGdzGi3KtY0nuPDH48UJxlKCC5RDzbcbh4X0XlqgHg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@eslint/core@0.14.0': @@ -2658,6 +2703,10 @@ packages: resolution: {integrity: sha512-k+TpEThzLVXMkbdxf8KHjZ83Wl+G54ytVJoDIGWwS96Ql4xyASRjc6SU1hs5jHVql+hpyK9G8N7WuFhLpGHRpQ==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/pattern@30.0.1': + resolution: {integrity: sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/reporters@30.0.0': resolution: {integrity: sha512-5WHNlLO0Ok+/o6ML5IzgVm1qyERtLHBNhwn67PAq92H4hZ+n5uW/BYj1VVwmTdxIcNrZLxdV9qtpdZkXf16HxA==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -2675,6 +2724,10 @@ packages: resolution: {integrity: sha512-NID2VRyaEkevCRz6badhfqYwri/RvMbiHY81rk3AkK/LaiB0LSxi1RdVZ7MpZdTjNugtZeGfpL0mLs9Kp3MrQw==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/schemas@30.0.1': + resolution: {integrity: sha512-+g/1TKjFuGrf1Hh0QPCv0gISwBxJ+MQSNXmG9zjHy7BmFhtoJ9fdNhWJp3qUKRi93AOZHXtdxZgJ1vAtz6z65w==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/snapshot-utils@30.0.0': resolution: {integrity: sha512-C/QSFUmvZEYptg2Vin84FggAphwHvj6la39vkw1CNOZQORWZ7O/H0BXmdeeeGnvlXDYY8TlFM5jgFnxLAxpFjA==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -2695,6 +2748,10 @@ packages: resolution: {integrity: sha512-8xhpsCGYJsUjqpJOgLyMkeOSSlhqggFZEWAnZquBsvATtueoEs7CkMRxOUmJliF3E5x+mXmZ7gEEsHank029Og==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/transform@30.0.2': + resolution: {integrity: sha512-kJIuhLMTxRF7sc0gPzPtCDib/V9KwW3I2U25b+lYCYMVqHHSrcZopS8J8H+znx9yixuFv+Iozl8raLt/4MoxrA==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/types@29.6.3': resolution: {integrity: sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} @@ -2703,6 +2760,10 @@ packages: resolution: {integrity: sha512-1Nox8mAL52PKPfEnUQWBvKU/bp8FTT6AiDu76bFDEJj/qsRFSAVSldfCH3XYMqialti2zHXKvD5gN0AaHc0yKA==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jest/types@30.0.1': + resolution: {integrity: sha512-HGwoYRVF0QSKJu1ZQX0o5ZrUrrhj0aOOFA8hXrumD7SIzjouevhawbTjmXdwOmURdGluU9DM/XvGm3NyFoiQjw==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + '@jridgewell/gen-mapping@0.3.5': resolution: {integrity: sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==} engines: {node: '>=6.0.0'} @@ -3341,8 +3402,8 @@ packages: '@sinclair/typebox@0.27.8': resolution: {integrity: sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==} - '@sinclair/typebox@0.34.33': - resolution: {integrity: sha512-5HAV9exOMcXRUxo+9iYB5n09XxzCXnfy4VTNW4xnDv+FgjzAGY989C28BIdljKqmF+ZltUwujE3aossvcVtq6g==} + '@sinclair/typebox@0.34.37': + resolution: {integrity: sha512-2TRuQVgQYfy+EzHRTIvkhv2ADEouJ2xNS/Vq+W5EuuewBdOrvATvljZTxHWZSTYr2sTjTHpGvucaGAt67S2akw==} '@sindresorhus/is@4.6.0': resolution: {integrity: sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==} @@ -3619,14 +3680,14 @@ packages: '@types/babel__core@7.20.5': resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==} - '@types/babel__generator@7.6.8': - resolution: {integrity: sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==} + '@types/babel__generator@7.27.0': + resolution: {integrity: sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==} '@types/babel__template@7.4.4': resolution: {integrity: sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==} - '@types/babel__traverse@7.20.6': - resolution: {integrity: sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg==} + '@types/babel__traverse@7.20.7': + resolution: {integrity: sha512-dkO5fhS7+/oos4ciWxyEyjWe48zmG6wbCheo/G2ZnHx4fs3EU6YC6UM8rk56gAjNJ9P3MTH2jo5jb92/K6wbng==} '@types/body-parser@1.19.5': resolution: {integrity: sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==} @@ -3733,6 +3794,9 @@ packages: '@types/lodash@4.17.17': resolution: {integrity: sha512-RRVJ+J3J+WmyOTqnz3PiBLA501eKwXl2noseKOrNo/6+XEHjTAxO4xHvxQB6QuNm+s4WRbn6rSiap8+EA+ykFQ==} + '@types/lodash@4.17.19': + resolution: {integrity: sha512-NYqRyg/hIQrYPT9lbOeYc3kIRabJDn/k4qQHIXUpx88CBDww2fD15Sg5kbXlW86zm2XEW4g0QxkTI3/Kfkc7xQ==} + '@types/mdast@4.0.4': resolution: {integrity: sha512-kGaNbPh1k7AFzgpud/gMdvIm5xuECykRR+JnWKQno9TAXVa6WIVCGTPvYGekIDL4uwCZQSYbUxNBSb1aUo79oA==} @@ -3772,6 +3836,9 @@ packages: '@types/node@20.17.50': resolution: {integrity: sha512-Mxiq0ULv/zo1OzOhwPqOA13I81CV/W3nvd3ChtQZRT5Cwz3cr0FKo/wMSsbTqL3EXpaBAEQhva2B8ByRkOIh9A==} + '@types/node@24.0.7': + resolution: {integrity: sha512-YIEUUr4yf8q8oQoXPpSlnvKNVKDQlPMWrmOcgzoduo7kvA2UF0/BwJ/eMKFTiTtkNL17I0M6Xe2tvwFU7be6iw==} + '@types/normalize-package-data@2.4.4': resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} @@ -3916,6 +3983,12 @@ packages: peerDependencies: typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/tsconfig-utils@8.35.0': + resolution: {integrity: sha512-04k/7247kZzFraweuEirmvUj+W3bJLI9fX6fbo1Qm2YykuBvEhRTPl8tcxlYO8kZZW+HIXfkZNoasVb8EV4jpA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + typescript: '>=4.8.4 <5.9.0' + '@typescript-eslint/type-utils@8.34.0': resolution: {integrity: sha512-n7zSmOcUVhcRYC75W2pnPpbO1iwhJY3NLoHEtbJwJSNlVAZuwqu05zY3f3s2SDWWDSo9FdN5szqc73DCtDObAg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -3927,6 +4000,10 @@ packages: resolution: {integrity: sha512-9V24k/paICYPniajHfJ4cuAWETnt7Ssy+R0Rbcqo5sSFr3QEZ/8TSoUi9XeXVBGXCaLtwTOKSLGcInCAvyZeMA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/types@8.35.0': + resolution: {integrity: sha512-0mYH3emanku0vHw2aRLNGqe7EXh9WHEhi7kZzscrMDf6IIRUQ5Jk4wp1QrledE/36KtdZrVfKnE32eZCf/vaVQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + '@typescript-eslint/typescript-estree@8.34.0': resolution: {integrity: sha512-rOi4KZxI7E0+BMqG7emPSK1bB4RICCpF7QD3KCLXn9ZvWoESsOMlHyZPAHyG04ujVplPaHbmEvs34m+wjgtVtg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -3947,98 +4024,98 @@ packages: '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} - '@unrs/resolver-binding-android-arm-eabi@1.9.0': - resolution: {integrity: sha512-h1T2c2Di49ekF2TE8ZCoJkb+jwETKUIPDJ/nO3tJBKlLFPu+fyd93f0rGP/BvArKx2k2HlRM4kqkNarj3dvZlg==} + '@unrs/resolver-binding-android-arm-eabi@1.9.2': + resolution: {integrity: sha512-tS+lqTU3N0kkthU+rYp0spAYq15DU8ld9kXkaKg9sbQqJNF+WPMuNHZQGCgdxrUOEO0j22RKMwRVhF1HTl+X8A==} cpu: [arm] os: [android] - '@unrs/resolver-binding-android-arm64@1.9.0': - resolution: {integrity: sha512-sG1NHtgXtX8owEkJ11yn34vt0Xqzi3k9TJ8zppDmyG8GZV4kVWw44FHwKwHeEFl07uKPeC4ZoyuQaGh5ruJYPA==} + '@unrs/resolver-binding-android-arm64@1.9.2': + resolution: {integrity: sha512-MffGiZULa/KmkNjHeuuflLVqfhqLv1vZLm8lWIyeADvlElJ/GLSOkoUX+5jf4/EGtfwrNFcEaB8BRas03KT0/Q==} cpu: [arm64] os: [android] - '@unrs/resolver-binding-darwin-arm64@1.9.0': - resolution: {integrity: sha512-nJ9z47kfFnCxN1z/oYZS7HSNsFh43y2asePzTEZpEvK7kGyuShSl3RRXnm/1QaqFL+iP+BjMwuB+DYUymOkA5A==} + '@unrs/resolver-binding-darwin-arm64@1.9.2': + resolution: {integrity: sha512-dzJYK5rohS1sYl1DHdJ3mwfwClJj5BClQnQSyAgEfggbUwA9RlROQSSbKBLqrGfsiC/VyrDPtbO8hh56fnkbsQ==} cpu: [arm64] os: [darwin] - '@unrs/resolver-binding-darwin-x64@1.9.0': - resolution: {integrity: sha512-TK+UA1TTa0qS53rjWn7cVlEKVGz2B6JYe0C++TdQjvWYIyx83ruwh0wd4LRxYBM5HeuAzXcylA9BH2trARXJTw==} + '@unrs/resolver-binding-darwin-x64@1.9.2': + resolution: {integrity: sha512-gaIMWK+CWtXcg9gUyznkdV54LzQ90S3X3dn8zlh+QR5Xy7Y+Efqw4Rs4im61K1juy4YNb67vmJsCDAGOnIeffQ==} cpu: [x64] os: [darwin] - '@unrs/resolver-binding-freebsd-x64@1.9.0': - resolution: {integrity: sha512-6uZwzMRFcD7CcCd0vz3Hp+9qIL2jseE/bx3ZjaLwn8t714nYGwiE84WpaMCYjU+IQET8Vu/+BNAGtYD7BG/0yA==} + '@unrs/resolver-binding-freebsd-x64@1.9.2': + resolution: {integrity: sha512-S7QpkMbVoVJb0xwHFwujnwCAEDe/596xqY603rpi/ioTn9VDgBHnCCxh+UFrr5yxuMH+dliHfjwCZJXOPJGPnw==} cpu: [x64] os: [freebsd] - '@unrs/resolver-binding-linux-arm-gnueabihf@1.9.0': - resolution: {integrity: sha512-bPUBksQfrgcfv2+mm+AZinaKq8LCFvt5PThYqRotqSuuZK1TVKkhbVMS/jvSRfYl7jr3AoZLYbDkItxgqMKRkg==} + '@unrs/resolver-binding-linux-arm-gnueabihf@1.9.2': + resolution: {integrity: sha512-+XPUMCuCCI80I46nCDFbGum0ZODP5NWGiwS3Pj8fOgsG5/ctz+/zzuBlq/WmGa+EjWZdue6CF0aWWNv84sE1uw==} cpu: [arm] os: [linux] - '@unrs/resolver-binding-linux-arm-musleabihf@1.9.0': - resolution: {integrity: sha512-uT6E7UBIrTdCsFQ+y0tQd3g5oudmrS/hds5pbU3h4s2t/1vsGWbbSKhBSCD9mcqaqkBwoqlECpUrRJCmldl8PA==} + '@unrs/resolver-binding-linux-arm-musleabihf@1.9.2': + resolution: {integrity: sha512-sqvUyAd1JUpwbz33Ce2tuTLJKM+ucSsYpPGl2vuFwZnEIg0CmdxiZ01MHQ3j6ExuRqEDUCy8yvkDKvjYFPb8Zg==} cpu: [arm] os: [linux] - '@unrs/resolver-binding-linux-arm64-gnu@1.9.0': - resolution: {integrity: sha512-vdqBh911wc5awE2bX2zx3eflbyv8U9xbE/jVKAm425eRoOVv/VseGZsqi3A3SykckSpF4wSROkbQPvbQFn8EsA==} + '@unrs/resolver-binding-linux-arm64-gnu@1.9.2': + resolution: {integrity: sha512-UYA0MA8ajkEDCFRQdng/FVx3F6szBvk3EPnkTTQuuO9lV1kPGuTB+V9TmbDxy5ikaEgyWKxa4CI3ySjklZ9lFA==} cpu: [arm64] os: [linux] - '@unrs/resolver-binding-linux-arm64-musl@1.9.0': - resolution: {integrity: sha512-/8JFZ/SnuDr1lLEVsxsuVwrsGquTvT51RZGvyDB/dOK3oYK2UqeXzgeyq6Otp8FZXQcEYqJwxb9v+gtdXn03eQ==} + '@unrs/resolver-binding-linux-arm64-musl@1.9.2': + resolution: {integrity: sha512-P/CO3ODU9YJIHFqAkHbquKtFst0COxdphc8TKGL5yCX75GOiVpGqd1d15ahpqu8xXVsqP4MGFP2C3LRZnnL5MA==} cpu: [arm64] os: [linux] - '@unrs/resolver-binding-linux-ppc64-gnu@1.9.0': - resolution: {integrity: sha512-FkJjybtrl+rajTw4loI3L6YqSOpeZfDls4SstL/5lsP2bka9TiHUjgMBjygeZEis1oC8LfJTS8FSgpKPaQx2tQ==} + '@unrs/resolver-binding-linux-ppc64-gnu@1.9.2': + resolution: {integrity: sha512-uKStFlOELBxBum2s1hODPtgJhY4NxYJE9pAeyBgNEzHgTqTiVBPjfTlPFJkfxyTjQEuxZbbJlJnMCrRgD7ubzw==} cpu: [ppc64] os: [linux] - '@unrs/resolver-binding-linux-riscv64-gnu@1.9.0': - resolution: {integrity: sha512-w/NZfHNeDusbqSZ8r/hp8iL4S39h4+vQMc9/vvzuIKMWKppyUGKm3IST0Qv0aOZ1rzIbl9SrDeIqK86ZpUK37w==} + '@unrs/resolver-binding-linux-riscv64-gnu@1.9.2': + resolution: {integrity: sha512-LkbNnZlhINfY9gK30AHs26IIVEZ9PEl9qOScYdmY2o81imJYI4IMnJiW0vJVtXaDHvBvxeAgEy5CflwJFIl3tQ==} cpu: [riscv64] os: [linux] - '@unrs/resolver-binding-linux-riscv64-musl@1.9.0': - resolution: {integrity: sha512-bEPBosut8/8KQbUixPry8zg/fOzVOWyvwzOfz0C0Rw6dp+wIBseyiHKjkcSyZKv/98edrbMknBaMNJfA/UEdqw==} + '@unrs/resolver-binding-linux-riscv64-musl@1.9.2': + resolution: {integrity: sha512-vI+e6FzLyZHSLFNomPi+nT+qUWN4YSj8pFtQZSFTtmgFoxqB6NyjxSjAxEC1m93qn6hUXhIsh8WMp+fGgxCoRg==} cpu: [riscv64] os: [linux] - '@unrs/resolver-binding-linux-s390x-gnu@1.9.0': - resolution: {integrity: sha512-LDtMT7moE3gK753gG4pc31AAqGUC86j3AplaFusc717EUGF9ZFJ356sdQzzZzkBk1XzMdxFyZ4f/i35NKM/lFA==} + '@unrs/resolver-binding-linux-s390x-gnu@1.9.2': + resolution: {integrity: sha512-sSO4AlAYhSM2RAzBsRpahcJB1msc6uYLAtP6pesPbZtptF8OU/CbCPhSRW6cnYOGuVmEmWVW5xVboAqCnWTeHQ==} cpu: [s390x] os: [linux] - '@unrs/resolver-binding-linux-x64-gnu@1.9.0': - resolution: {integrity: sha512-WmFd5KINHIXj8o1mPaT8QRjA9HgSXhN1gl9Da4IZihARihEnOylu4co7i/yeaIpcfsI6sYs33cNZKyHYDh0lrA==} + '@unrs/resolver-binding-linux-x64-gnu@1.9.2': + resolution: {integrity: sha512-jkSkwch0uPFva20Mdu8orbQjv2A3G88NExTN2oPTI1AJ+7mZfYW3cDCTyoH6OnctBKbBVeJCEqh0U02lTkqD5w==} cpu: [x64] os: [linux] - '@unrs/resolver-binding-linux-x64-musl@1.9.0': - resolution: {integrity: sha512-CYuXbANW+WgzVRIl8/QvZmDaZxrqvOldOwlbUjIM4pQ46FJ0W5cinJ/Ghwa/Ng1ZPMJMk1VFdsD/XwmCGIXBWg==} + '@unrs/resolver-binding-linux-x64-musl@1.9.2': + resolution: {integrity: sha512-Uk64NoiTpQbkpl+bXsbeyOPRpUoMdcUqa+hDC1KhMW7aN1lfW8PBlBH4mJ3n3Y47dYE8qi0XTxy1mBACruYBaw==} cpu: [x64] os: [linux] - '@unrs/resolver-binding-wasm32-wasi@1.9.0': - resolution: {integrity: sha512-6Rp2WH0OoitMYR57Z6VE8Y6corX8C6QEMWLgOV6qXiJIeZ1F9WGXY/yQ8yDC4iTraotyLOeJ2Asea0urWj2fKQ==} + '@unrs/resolver-binding-wasm32-wasi@1.9.2': + resolution: {integrity: sha512-EpBGwkcjDicjR/ybC0g8wO5adPNdVuMrNalVgYcWi+gYtC1XYNuxe3rufcO7dA76OHGeVabcO6cSkPJKVcbCXQ==} engines: {node: '>=14.0.0'} cpu: [wasm32] - '@unrs/resolver-binding-win32-arm64-msvc@1.9.0': - resolution: {integrity: sha512-rknkrTRuvujprrbPmGeHi8wYWxmNVlBoNW8+4XF2hXUnASOjmuC9FNF1tGbDiRQWn264q9U/oGtixyO3BT8adQ==} + '@unrs/resolver-binding-win32-arm64-msvc@1.9.2': + resolution: {integrity: sha512-EdFbGn7o1SxGmN6aZw9wAkehZJetFPao0VGZ9OMBwKx6TkvDuj6cNeLimF/Psi6ts9lMOe+Dt6z19fZQ9Ye2fw==} cpu: [arm64] os: [win32] - '@unrs/resolver-binding-win32-ia32-msvc@1.9.0': - resolution: {integrity: sha512-Ceymm+iBl+bgAICtgiHyMLz6hjxmLJKqBim8tDzpX61wpZOx2bPK6Gjuor7I2RiUynVjvvkoRIkrPyMwzBzF3A==} + '@unrs/resolver-binding-win32-ia32-msvc@1.9.2': + resolution: {integrity: sha512-JY9hi1p7AG+5c/dMU8o2kWemM8I6VZxfGwn1GCtf3c5i+IKcMo2NQ8OjZ4Z3/itvY/Si3K10jOBQn7qsD/whUA==} cpu: [ia32] os: [win32] - '@unrs/resolver-binding-win32-x64-msvc@1.9.0': - resolution: {integrity: sha512-k59o9ZyeyS0hAlcaKFezYSH2agQeRFEB7KoQLXl3Nb3rgkqT1NY9Vwy+SqODiLmYnEjxWJVRE/yq2jFVqdIxZw==} + '@unrs/resolver-binding-win32-x64-msvc@1.9.2': + resolution: {integrity: sha512-ryoo+EB19lMxAd80ln9BVf8pdOAxLb97amrQ3SFN9OCRn/5M5wvwDgAe4i8ZjhpbiHoDeP8yavcTEnpKBo7lZg==} cpu: [x64] os: [win32] @@ -4178,6 +4255,11 @@ packages: engines: {node: '>=0.4.0'} hasBin: true + acorn@8.15.0: + resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==} + engines: {node: '>=0.4.0'} + hasBin: true + address@1.2.2: resolution: {integrity: sha512-4B/qKCfeE/ODUaAUpSwfzazo5x29WD4r3vXiWsB7I2mSDAihwEqKO+g8GELZUQSSAo5e1XTYh3ZVfLyxBc12nA==} engines: {node: '>= 10.0.0'} @@ -4318,8 +4400,8 @@ packages: aria-query@5.3.0: resolution: {integrity: sha512-b0P0sZPKtyu8HkeRAfCq0IfURZK+SuwMjY1UXGBU27wpAiTwQAIlq56IbIO+ytk/JjS1fMR14ee5WBBfKi5J6A==} - array-buffer-byte-length@1.0.1: - resolution: {integrity: sha512-ahC5W1xgou+KTXix4sAO8Ki12Q+jf4i0+tmk3sC+zgcynshkHxzpXdImBehiUYKKKDwvfFiJl1tZt6ewscS1Mg==} + array-buffer-byte-length@1.0.2: + resolution: {integrity: sha512-LHE+8BuR7RYGDKvnrmcuSq3tDcKv9OFEXQt/HpbZhY7V6h0zlUXutnAD82GiFx9rdieCMjkvtcsPqBwgUl1Iiw==} engines: {node: '>= 0.4'} array-differ@3.0.0: @@ -4329,8 +4411,8 @@ packages: array-flatten@1.1.1: resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==} - array-includes@3.1.8: - resolution: {integrity: sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==} + array-includes@3.1.9: + resolution: {integrity: sha512-FmeCCAenzH0KH381SPT5FZmiA/TmpndpcaShhfgEN9eCVjnFBqq3l1xrI42y8+PPLI6hypzou4GXw00WHmPBLQ==} engines: {node: '>= 0.4'} array-union@2.1.0: @@ -4341,24 +4423,24 @@ packages: resolution: {integrity: sha512-CVvd6FHg1Z3POpBLxO6E6zr+rSKEQ9L6rZHAaY7lLfhKsWYUBBOuMs0e9o24oopj6H+geRCX0YJ+TJLBK2eHyQ==} engines: {node: '>= 0.4'} - array.prototype.findlastindex@1.2.5: - resolution: {integrity: sha512-zfETvRFA8o7EiNn++N5f/kaCw221hrpGsDmcpndVupkPzEc1Wuf3VgC0qby1BbHs7f5DVYjgtEU2LLh5bqeGfQ==} + array.prototype.findlastindex@1.2.6: + resolution: {integrity: sha512-F/TKATkzseUExPlfvmwQKGITM3DGTK+vkAsCZoDc5daVygbJBnjEUCbgkAvVFsgfXfX4YIqZ/27G3k3tdXrTxQ==} engines: {node: '>= 0.4'} - array.prototype.flat@1.3.2: - resolution: {integrity: sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==} + array.prototype.flat@1.3.3: + resolution: {integrity: sha512-rwG/ja1neyLqCuGZ5YYrznA62D4mZXg0i1cIskIUKSiqF3Cje9/wXAls9B9s1Wa2fomMsIv8czB8jZcPmxCXFg==} engines: {node: '>= 0.4'} - array.prototype.flatmap@1.3.2: - resolution: {integrity: sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==} + array.prototype.flatmap@1.3.3: + resolution: {integrity: sha512-Y7Wt51eKJSyi80hFrJCePGGNo5ktJCslFuboqJsbf57CCPcm5zztluPlc4/aD8sWsKvlwatezpV4U1efk8kpjg==} engines: {node: '>= 0.4'} array.prototype.tosorted@1.1.4: resolution: {integrity: sha512-p6Fx8B7b7ZhL/gmUsAy0D15WhvDccw3mnGNbZpi3pmeJdxtWsj2jEaI4Y6oo3XiHfzuSgPwKc04MYt6KgvC/wA==} engines: {node: '>= 0.4'} - arraybuffer.prototype.slice@1.0.3: - resolution: {integrity: sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==} + arraybuffer.prototype.slice@1.0.4: + resolution: {integrity: sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ==} engines: {node: '>= 0.4'} arrify@1.0.1: @@ -4390,6 +4472,10 @@ packages: resolution: {integrity: sha512-LElXdjswlqjWrPpJFg1Fx4wpkOCxj1TDHlSV4PlaRxHGWko024xICaa97ZkMfs6DRKlCguiAI+rbXv5GWwXIkg==} hasBin: true + async-function@1.0.0: + resolution: {integrity: sha512-hsU18Ae8CDTR6Kgu9DYf0EbCr/a5iGL0rytQDobUcdpYOKokk8LEjVphnXkDkgpi0wYVsqrXuP0bZxJaTqdgoA==} + engines: {node: '>= 0.4'} + async@2.6.4: resolution: {integrity: sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==} @@ -4421,6 +4507,12 @@ packages: peerDependencies: '@babel/core': ^7.11.0 + babel-jest@30.0.2: + resolution: {integrity: sha512-A5kqR1/EUTidM2YC2YMEUDP2+19ppgOwK0IAd9Swc3q2KqFb5f9PtRUXVeZcngu0z5mDMyZ9zH2huJZSOMLiTQ==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + peerDependencies: + '@babel/core': ^7.11.0 + babel-loader@9.2.1: resolution: {integrity: sha512-fqe8naHt46e0yIdkjUZYqddSXfej3AHajX+CSO5X7oy0EmPc6o5Xh+RClNoHjnieWz9AW4kZxW9yyFMhVB1QLA==} engines: {node: '>= 14.15.0'} @@ -4439,6 +4531,10 @@ packages: resolution: {integrity: sha512-DSRm+US/FCB4xPDD6Rnslb6PAF9Bej1DZ+1u4aTiqJnk7ZX12eHsnDiIOqjGvITCq+u6wLqUhgS+faCNbVY8+g==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + babel-plugin-jest-hoist@30.0.1: + resolution: {integrity: sha512-zTPME3pI50NsFW8ZBaVIOeAxzEY7XHlmWeXXu9srI+9kNfzCUTy8MFan46xOGZY8NZThMqq+e3qZUKsvXbasnQ==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + babel-plugin-polyfill-corejs2@0.4.11: resolution: {integrity: sha512-sMEJ27L0gRHShOh5G54uAAPaiCOygY/5ratXuiyb2G46FmlSpc9eFCzYVyDiPxfNbwzA7mYahmjQc5q+CZQ09Q==} peerDependencies: @@ -4465,6 +4561,12 @@ packages: peerDependencies: '@babel/core': ^7.11.0 + babel-preset-jest@30.0.1: + resolution: {integrity: sha512-+YHejD5iTWI46cZmcc/YtX4gaKBtdqCHCVfuVinizVpbmyjO3zYmeuyFdfA8duRqQZfgCAMlsfmkVbJ+e2MAJw==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + peerDependencies: + '@babel/core': ^7.11.0 + bail@2.0.2: resolution: {integrity: sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==} @@ -4619,6 +4721,10 @@ packages: resolution: {integrity: sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==} engines: {node: '>= 0.4'} + call-bind@1.0.8: + resolution: {integrity: sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==} + engines: {node: '>= 0.4'} + call-bound@1.0.4: resolution: {integrity: sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==} engines: {node: '>= 0.4'} @@ -5221,16 +5327,16 @@ packages: resolution: {integrity: sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==} engines: {node: '>=18'} - data-view-buffer@1.0.1: - resolution: {integrity: sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==} + data-view-buffer@1.0.2: + resolution: {integrity: sha512-EmKO5V3OLXh1rtK2wgXRansaK1/mtVdTUEiEI0W8RkvgT05kfxaH29PliLnpLP73yYO6142Q72QNa8Wx/A5CqQ==} engines: {node: '>= 0.4'} - data-view-byte-length@1.0.1: - resolution: {integrity: sha512-4J7wRJD3ABAzr8wP+OcIcqq2dlUKp4DVflx++hs5h5ZKydWMI6/D/fAot+yh6g2tHh8fLFTvNOaVN357NvSrOQ==} + data-view-byte-length@1.0.2: + resolution: {integrity: sha512-tuhGbE6CfTM9+5ANGf+oQb72Ky/0+s3xKUpHvShfiz2RxMFgFPjsXuRLBVMtvMs15awe45SRb83D6wH4ew6wlQ==} engines: {node: '>= 0.4'} - data-view-byte-offset@1.0.0: - resolution: {integrity: sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==} + data-view-byte-offset@1.0.1: + resolution: {integrity: sha512-BS8PfmtDGnrgYdOonGZQdLZslWIeCGFP9tpan0hi1Co2Zr2NKADsvGYA8XxuG/4UWgJ6Cjtv+YJnB6MM69QGlQ==} engines: {node: '>= 0.4'} dateformat@4.6.3: @@ -5542,6 +5648,10 @@ packages: resolution: {integrity: sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg==} engines: {node: '>=10.13.0'} + enhanced-resolve@5.18.2: + resolution: {integrity: sha512-6Jw4sE1maoRJo3q8MsSIn2onJFbLTOjY9hlx4DZXmOKvLRd1Ok2kXmAGXaafL2+ijsJZ1ClYbl/pmqr9+k4iUQ==} + engines: {node: '>=10.13.0'} + enquirer@2.4.1: resolution: {integrity: sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==} engines: {node: '>=8.6'} @@ -5578,8 +5688,8 @@ packages: error@10.4.0: resolution: {integrity: sha512-YxIFEJuhgcICugOUvRx5th0UM+ActZ9sjY0QJmeVwsQdvosZ7kYzc9QqS0Da3R5iUmgU5meGIxh0xBeZpMVeLw==} - es-abstract@1.23.3: - resolution: {integrity: sha512-e+HfNH61Bj1X9/jLc5v1owaLYuHdeHHSQlkhCBiTK8rBvKaULl/beGMxwrMXjpYrv4pz22BlY570vVePA2ho4A==} + es-abstract@1.24.0: + resolution: {integrity: sha512-WSzPgsdLtTcQwm4CROfS5ju2Wa1QQcVeT37jFjYzdFz1r9ahadC8B8/a4qxJxM+09F18iumCdRmlr96ZYkQvEg==} engines: {node: '>= 0.4'} es-define-property@1.0.1: @@ -5604,15 +5714,16 @@ packages: resolution: {integrity: sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==} engines: {node: '>= 0.4'} - es-set-tostringtag@2.0.3: - resolution: {integrity: sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==} + es-set-tostringtag@2.1.0: + resolution: {integrity: sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==} engines: {node: '>= 0.4'} - es-shim-unscopables@1.0.2: - resolution: {integrity: sha512-J3yBRXCzDu4ULnQwxyToo/OjdMx6akgVC7K6few0a7F/0wLtmKKN7I73AH5T2836UuXRqN7Qg+IIUw/+YJksRw==} + es-shim-unscopables@1.1.0: + resolution: {integrity: sha512-d9T8ucsEhh8Bi1woXCf+TIKDIROLG5WCkxg8geBCbvk22kzwC5G2OnXVMO6FUsvQlgUUXQ2itephWDLqDzbeCw==} + engines: {node: '>= 0.4'} - es-to-primitive@1.2.1: - resolution: {integrity: sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==} + es-to-primitive@1.3.0: + resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==} engines: {node: '>= 0.4'} esbuild@0.25.5: @@ -5674,8 +5785,8 @@ packages: eslint-import-resolver-node@0.3.9: resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==} - eslint-import-resolver-typescript@3.6.3: - resolution: {integrity: sha512-ud9aw4szY9cCT1EWWdGv1L1XR6hh2PaRWif0j2QjQ0pgTY/69iw+W0Z4qZv5wHahOl8isEr+k/JnyAqNQkLkIA==} + eslint-import-resolver-typescript@3.10.1: + resolution: {integrity: sha512-A1rHYb06zjMGAxdLSkN2fXPBwuSaQ0iO5M/hdyS0Ajj1VBaRp0sPD3dn1FhME3c/JluGFbwSxyCfqdSbtQLAHQ==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: eslint: '*' @@ -5700,8 +5811,8 @@ packages: eslint-plugin-import-x: optional: true - eslint-module-utils@2.12.0: - resolution: {integrity: sha512-wALZ0HFoytlyh/1+4wuZ9FJCD/leWHQzzrxJ8+rebyReSLk7LApMyd3WJaLVoN+D5+WIdJyDK1c6JnE65V4Zyg==} + eslint-module-utils@2.12.1: + resolution: {integrity: sha512-L8jSWTze7K2mTg0vos/RuLRS5soomksDPoJLXIslC7c8Wmut3bx7CPpJijDcBZtxQ5lrbUdM+s0OlNbz0DCDNw==} engines: {node: '>=4'} peerDependencies: '@typescript-eslint/parser': '*' @@ -5774,8 +5885,8 @@ packages: resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} engines: {node: '>=8.0.0'} - eslint-scope@8.3.0: - resolution: {integrity: sha512-pUNxi75F8MJ/GdeKtVLSbYg4ZI34J6C0C7sbL4YOp2exGwen7ZsuBqKzUhXd0qMQ362yET3z+uPwKeg/0C2XCQ==} + eslint-scope@8.4.0: + resolution: {integrity: sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} eslint-utils@3.0.0: @@ -5792,8 +5903,8 @@ packages: resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - eslint-visitor-keys@4.2.0: - resolution: {integrity: sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==} + eslint-visitor-keys@4.2.1: + resolution: {integrity: sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} eslint@9.28.0: @@ -5806,8 +5917,8 @@ packages: jiti: optional: true - espree@10.3.0: - resolution: {integrity: sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==} + espree@10.4.0: + resolution: {integrity: sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} esprima@4.0.1: @@ -5958,8 +6069,8 @@ packages: fastest-stable-stringify@2.0.2: resolution: {integrity: sha512-bijHueCGd0LqqNK9b5oCMHc0MluJAx0cwqASgbWMvkO01lCYgIhacVRLcaDz3QnyYIRNJRDwMb41VuT6pHJ91Q==} - fastq@1.17.1: - resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==} + fastq@1.19.1: + resolution: {integrity: sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==} fault@2.0.1: resolution: {integrity: sha512-WtySTkS4OKev5JtpHXnib4Gxiurzh5NCGvWrFaZ34m6JehfTUhKZvn9njTfw48t6JumVQOmrKqpmGcdwxnhqBQ==} @@ -6066,8 +6177,9 @@ packages: debug: optional: true - for-each@0.3.3: - resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} + for-each@0.3.5: + resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==} + engines: {node: '>= 0.4'} foreground-child@3.3.1: resolution: {integrity: sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==} @@ -6118,8 +6230,8 @@ packages: function-bind@1.1.2: resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} - function.prototype.name@1.1.6: - resolution: {integrity: sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==} + function.prototype.name@1.1.8: + resolution: {integrity: sha512-e5iwyodOHhbMr/yNrc7fDYG4qlbIvI5gajyzPnb5TCwyhjApznQh1BMFou9b30SevY43gCJKXycoCBjMbsuW0Q==} engines: {node: '>= 0.4'} functions-have-names@1.2.3: @@ -6173,8 +6285,8 @@ packages: resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} - get-symbol-description@1.0.2: - resolution: {integrity: sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==} + get-symbol-description@1.1.0: + resolution: {integrity: sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==} engines: {node: '>= 0.4'} get-tsconfig@4.10.1: @@ -6292,8 +6404,9 @@ packages: resolution: {integrity: sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==} engines: {node: '>=6'} - has-bigints@1.0.2: - resolution: {integrity: sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==} + has-bigints@1.1.0: + resolution: {integrity: sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==} + engines: {node: '>= 0.4'} has-flag@4.0.0: resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} @@ -6302,8 +6415,8 @@ packages: has-property-descriptors@1.0.2: resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} - has-proto@1.0.3: - resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} + has-proto@1.2.0: + resolution: {integrity: sha512-KIL7eQPfHQRC8+XluaIw7BHUwwqL19bQn4hzNgdr+1wXoU0KKj6rufu47lhY7KbJR2C6T6+PfyN0Ea7wkSS+qQ==} engines: {node: '>= 0.4'} has-symbols@1.1.0: @@ -6622,8 +6735,8 @@ packages: resolution: {integrity: sha512-M1WuAmb7pn9zdFRtQYk26ZBoY043Sse0wVDdk4Bppr+JOXyQYybdtvK+l9wUibhtjdjvtoiNy8tk+EgsYIUqKg==} engines: {node: '>=12.0.0'} - internal-slot@1.0.7: - resolution: {integrity: sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==} + internal-slot@1.1.0: + resolution: {integrity: sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==} engines: {node: '>= 0.4'} interpret@1.4.0: @@ -6659,8 +6772,8 @@ packages: resolution: {integrity: sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==} engines: {node: '>= 0.4'} - is-array-buffer@3.0.4: - resolution: {integrity: sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==} + is-array-buffer@3.0.5: + resolution: {integrity: sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==} engines: {node: '>= 0.4'} is-arrayish@0.2.1: @@ -6669,19 +6782,20 @@ packages: is-arrayish@0.3.2: resolution: {integrity: sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==} - is-async-function@2.0.0: - resolution: {integrity: sha512-Y1JXKrfykRJGdlDwdKlLpLyMIiWqWvuSd17TvZk68PLAOGOoF4Xyav1z0Xhoi+gCYjZVeC5SI+hYFOfvXmGRCA==} + is-async-function@2.1.1: + resolution: {integrity: sha512-9dgM/cZBnNvjzaMYHVoxxfPj2QXt22Ev7SuuPrs+xav0ukGB0S6d4ydZdEiM48kLx5kDV+QBPrpVnFyefL8kkQ==} engines: {node: '>= 0.4'} - is-bigint@1.0.4: - resolution: {integrity: sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==} + is-bigint@1.1.0: + resolution: {integrity: sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==} + engines: {node: '>= 0.4'} is-binary-path@2.1.0: resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} engines: {node: '>=8'} - is-boolean-object@1.1.2: - resolution: {integrity: sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==} + is-boolean-object@1.2.2: + resolution: {integrity: sha512-wa56o2/ElJMYqjCjGkXri7it5FbebW5usLw/nPmCMs5DeZ7eziSYZhSmPRn0txqeW4LnAmQQU7FgqLpsEFKM4A==} engines: {node: '>= 0.4'} is-buffer@1.1.6: @@ -6691,9 +6805,6 @@ packages: resolution: {integrity: sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==} engines: {node: '>=6'} - is-bun-module@1.2.1: - resolution: {integrity: sha512-AmidtEM6D6NmUiLOvvU7+IePxjEjOzra2h0pSrsfSAcXwl/83zLLXDByafUJy9k/rKK0pvXMLdwKwGHlX2Ke6Q==} - is-bun-module@2.0.0: resolution: {integrity: sha512-gNCGbnnnnFAUGKeZ9PdbyeGYJqewpmc2aKHUEMO5nQPWU9lOmv7jcmQIv+qHD8fXW6W7qfuCwX4rY9LNRjXrkQ==} @@ -6705,16 +6816,16 @@ packages: resolution: {integrity: sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==} hasBin: true - is-core-module@2.15.1: - resolution: {integrity: sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==} + is-core-module@2.16.1: + resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==} engines: {node: '>= 0.4'} - is-data-view@1.0.1: - resolution: {integrity: sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==} + is-data-view@1.0.2: + resolution: {integrity: sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==} engines: {node: '>= 0.4'} - is-date-object@1.0.5: - resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} + is-date-object@1.1.0: + resolution: {integrity: sha512-PwwhEakHVKTdRNVOw+/Gyh0+MzlCl4R6qKvkhuvLtPMggI1WAHt9sOwZxQLSGpUaDnrdyDsomoRgNnCfKNSXXg==} engines: {node: '>= 0.4'} is-decimal@2.0.1: @@ -6738,8 +6849,9 @@ packages: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} - is-finalizationregistry@1.0.2: - resolution: {integrity: sha512-0by5vtUJs8iFQb5TYUHHPudOR+qXYIMKtiUzvLIZITZUjknFmziyBJuLhVRc+Ds0dREFlskDNJKYIdIzu/9pfw==} + is-finalizationregistry@1.1.1: + resolution: {integrity: sha512-1pC6N8qWJbWoPtEjgcL2xyhQOP491EQjeUo3qTKcmV8YSDDJrOepfG8pcC7h/QgnQHYSv0mJ3Z/ZWxmatVrysg==} + engines: {node: '>= 0.4'} is-fullwidth-code-point@3.0.0: resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} @@ -6749,8 +6861,8 @@ packages: resolution: {integrity: sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==} engines: {node: '>=6'} - is-generator-function@1.0.10: - resolution: {integrity: sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==} + is-generator-function@1.1.0: + resolution: {integrity: sha512-nPUB5km40q9e8UfN/Zc24eLlzdSf9OfKByBw9CIdw4H1giPMeA0OIJvbchsCu4npfI2QcMVBsGEBHKZ7wLTWmQ==} engines: {node: '>= 0.4'} is-glob@4.0.3: @@ -6796,8 +6908,8 @@ packages: resolution: {integrity: sha512-JEjxbSmtPSt1c8XTkVrlujcXdKV1/tvuQ7GwKcAlyiVLeYFQ2VHat8xfrDJsIkhCdF/tZ7CiIR3sy141c6+gPQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - is-number-object@1.0.7: - resolution: {integrity: sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==} + is-number-object@1.1.1: + resolution: {integrity: sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==} engines: {node: '>= 0.4'} is-number@7.0.0: @@ -6846,8 +6958,8 @@ packages: is-reference@3.0.2: resolution: {integrity: sha512-v3rht/LgVcsdZa3O2Nqs+NMowLOxeOm7Ay9+/ARQ2F+qEoANRcqrjAZKGN0v8ymUetZGgkp26LTnGT7H0Qo9Pg==} - is-regex@1.1.4: - resolution: {integrity: sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==} + is-regex@1.2.1: + resolution: {integrity: sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==} engines: {node: '>= 0.4'} is-regexp@1.0.0: @@ -6862,28 +6974,28 @@ packages: resolution: {integrity: sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==} engines: {node: '>= 0.4'} - is-shared-array-buffer@1.0.3: - resolution: {integrity: sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==} + is-shared-array-buffer@1.0.4: + resolution: {integrity: sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==} engines: {node: '>= 0.4'} is-stream@2.0.1: resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==} engines: {node: '>=8'} - is-string@1.0.7: - resolution: {integrity: sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==} + is-string@1.1.1: + resolution: {integrity: sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==} engines: {node: '>= 0.4'} is-subdir@1.2.0: resolution: {integrity: sha512-2AT6j+gXe/1ueqbW6fLZJiIw3F8iXGJtt0yDrZaBhAZEG1raiTxKWU+IPqMCzQAXOUCKdA4UDMgacKH25XG2Cw==} engines: {node: '>=4'} - is-symbol@1.0.4: - resolution: {integrity: sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==} + is-symbol@1.1.1: + resolution: {integrity: sha512-9gGx6GTtCQM73BgmHQXfDmLtfjjTUDSyoxTCbp5WtoixAhfgsDirWIcVQ/IHpvI5Vgd5i/J5F7B9cN/WlVbC/w==} engines: {node: '>= 0.4'} - is-typed-array@1.1.13: - resolution: {integrity: sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==} + is-typed-array@1.1.15: + resolution: {integrity: sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==} engines: {node: '>= 0.4'} is-typedarray@1.0.0: @@ -6908,8 +7020,9 @@ packages: resolution: {integrity: sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==} engines: {node: '>= 0.4'} - is-weakref@1.0.2: - resolution: {integrity: sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==} + is-weakref@1.1.1: + resolution: {integrity: sha512-6i9mGWSlqzNMEqpCp93KwRS1uUOodk2OJ6b+sq7ZPDSy2WuI5NFIxp/254TytR8ftefexkWn5xNiHUNpPOfSew==} + engines: {node: '>= 0.4'} is-weakset@2.0.3: resolution: {integrity: sha512-LvIm3/KWzS9oRFHugab7d+M/GcBXuXX5xZkzPmN+NxihdQlZUQ4dWuSV1xR/sq6upL1TJEDrfBgRepHFdBtSNQ==} @@ -7068,6 +7181,10 @@ packages: resolution: {integrity: sha512-p4bXAhXTawTsADgQgTpbymdLaTyPW1xWNu1oIGG7/N3LIAbZVkH2JMJqS8/IUcnGR8Kc7WFE+vWbJvsqGCWZXw==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-haste-map@30.0.2: + resolution: {integrity: sha512-telJBKpNLeCb4MaX+I5k496556Y2FiKR/QLZc0+MGBYl4k3OO0472drlV2LUe7c1Glng5HuAu+5GLYp//GpdOQ==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-leak-detector@30.0.0: resolution: {integrity: sha512-E/ly1azdVVbZrS0T6FIpyYHvsdek4FNaThJTtggjV/8IpKxh3p9NLndeUZy2+sjAI3ncS+aM0uLLon/dBg8htA==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -7105,6 +7222,10 @@ packages: resolution: {integrity: sha512-rT84010qRu/5OOU7a9TeidC2Tp3Qgt9Sty4pOZ/VSDuEmRupIjKZAb53gU3jr4ooMlhwScrgC9UixJxWzVu9oQ==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-regex-util@30.0.1: + resolution: {integrity: sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-resolve-dependencies@30.0.0: resolution: {integrity: sha512-Yhh7odCAUNXhluK1bCpwIlHrN1wycYaTlZwq1GdfNBEESNNI/z1j1a7dUEWHbmB9LGgv0sanxw3JPmWU8NeebQ==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -7133,6 +7254,10 @@ packages: resolution: {integrity: sha512-fhNBBM9uSUbd4Lzsf8l/kcAdaHD/4SgoI48en3HXcBEMwKwoleKFMZ6cYEYs21SB779PRuRCyNLmymApAm8tZw==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-util@30.0.2: + resolution: {integrity: sha512-8IyqfKS4MqprBuUpZNlFB5l+WFehc8bfCe1HSZFHzft2mOuND8Cvi9r1musli+u6F3TqanCZ/Ik4H4pXUolZIg==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-validate@30.0.0: resolution: {integrity: sha512-d6OkzsdlWItHAikUDs1hlLmpOIRhsZoXTCliV2XXalVQ3ZOeb9dy0CQ6AKulJu/XOZqpOEr/FiMH+FeOBVV+nw==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -7153,6 +7278,10 @@ packages: resolution: {integrity: sha512-VZvxfWIybIvwK8N/Bsfe43LfQgd/rD0c4h5nLUx78CAqPxIQcW2qDjsVAC53iUR8yxzFIeCFFvWOh8en8hGzdg==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest-worker@30.0.2: + resolution: {integrity: sha512-RN1eQmx7qSLFA+o9pfJKlqViwL5wt+OL3Vff/A+/cPsmuw7NPwfgl33AP+/agRmHzPOFgXviRycR9kYwlcRQXg==} + engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} + jest@30.0.0: resolution: {integrity: sha512-/3G2iFwsUY95vkflmlDn/IdLyLWqpQXcftptooaPH4qkyU52V7qVYf1BjmdSPlp1+0fs6BmNtrGaSFwOfV07ew==} engines: {node: ^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0} @@ -7167,6 +7296,10 @@ packages: resolution: {integrity: sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w==} hasBin: true + jiti@1.21.7: + resolution: {integrity: sha512-/imKNG4EbWNrVjoNC/1H5/9GFy+tqjGBHCaSsN+P2RnPqjsLmv6UD3Ej+Kj8nBWaRAwyk7kK5ZUc+OEatnTR3A==} + hasBin: true + jiti@2.4.2: resolution: {integrity: sha512-rg9zJN+G4n2nfJl5MW3BMygZX56zKPNVEYYqq7adpmMh4Jn2QNEwhvQlFy6jPVdcod7txZtKHWnyZiA3a0zP7A==} hasBin: true @@ -7982,8 +8115,8 @@ packages: engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true - napi-postinstall@0.2.4: - resolution: {integrity: sha512-ZEzHJwBhZ8qQSbknHqYcdtQVr8zUgGyM/q6h6qAyhtyVMNrSgDhrC4disf03dYW0e+czXyLnZINnCTEkWy0eJg==} + napi-postinstall@0.2.5: + resolution: {integrity: sha512-kmsgUvCRIJohHjbZ3V8avP0I1Pekw329MVAMDzVxsrkjgdnqiwvMX5XwR+hWV66vsAtZ+iM+fVnq8RTQawUmCQ==} engines: {node: ^12.20.0 || ^14.18.0 || >=16.0.0} hasBin: true @@ -8229,6 +8362,10 @@ packages: resolution: {integrity: sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==} engines: {node: '>= 0.4'} + object.assign@4.1.7: + resolution: {integrity: sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==} + engines: {node: '>= 0.4'} + object.entries@1.1.8: resolution: {integrity: sha512-cmopxi8VwRIAw/fkijJohSfpef5PdN0pMQJN6VC/ZKvn0LIknWD8KtgY6KlQdEc4tIjcQ3HxSMmnvtzIscdaYQ==} engines: {node: '>= 0.4'} @@ -8241,8 +8378,8 @@ packages: resolution: {integrity: sha512-+Lhy3TQTuzXI5hevh8sBGqbmurHbbIjAi0Z4S63nthVLmLxfbj4T54a4CfZrXIrt9iP4mVAPYMo/v99taj3wjQ==} engines: {node: '>= 0.4'} - object.values@1.2.0: - resolution: {integrity: sha512-yBYjY9QX2hnRmZHAjG/f13MzmBzxzYgQhFrke06TTyKY5zSTEqkOeukBzIdVA3j3ulu8Qa3MbVFShV7T2RmGtQ==} + object.values@1.2.1: + resolution: {integrity: sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==} engines: {node: '>= 0.4'} obuf@1.1.2: @@ -8298,6 +8435,10 @@ packages: resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} engines: {node: '>=0.10.0'} + own-keys@1.0.1: + resolution: {integrity: sha512-qFOyK5PjiWZd+QQIh+1jhdb9LpxTF0qs7Pm8o5QHYZ0M3vKqSqzsZaEB6oWlxZ+q2sJBMI/Ktgd2N5ZwQoRHfg==} + engines: {node: '>= 0.4'} + p-cancelable@3.0.0: resolution: {integrity: sha512-mlVgR3PGuzlo0MmTdk4cXqXWlwQDLnONTAg6sm62XkMJEiRxN3GL3SffkYvqwonbkJBcrI7Uvv5Zh9yjvn2iUw==} engines: {node: '>=12.20'} @@ -8532,8 +8673,8 @@ packages: resolution: {integrity: sha512-on2ZJVVDXRADWE6jnQaX0ioEylzgBpQk8r55NE4wjXW1ZxO+BgDlY6DXwj20i0V8eB4SenDQ00WEaxfiIQPcxg==} engines: {node: '>= 0.12.0'} - possible-typed-array-names@1.0.0: - resolution: {integrity: sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==} + possible-typed-array-names@1.1.0: + resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==} engines: {node: '>= 0.4'} postcss-attribute-case-insensitive@7.0.1: @@ -9354,8 +9495,8 @@ packages: resolution: {integrity: sha512-tYkDkVVtYkSVhuQ4zBgfvciymHaeuel+zFKXShfDnFP5SyVEP7qo70Rf1jTOTCx3vGNAbnEi/xFkcfQVMIBWag==} engines: {node: '>=12'} - reflect.getprototypeof@1.0.6: - resolution: {integrity: sha512-fmfw4XgoDke3kdI6h4xcUz1dG8uaiv5q9gcEwLS4Pnth2kxT+GZ7YehS1JTMGBQmtV7Y4GFGbs2re2NqhdozUg==} + reflect.getprototypeof@1.0.10: + resolution: {integrity: sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==} engines: {node: '>= 0.4'} regenerate-unicode-properties@10.2.0: @@ -9369,8 +9510,8 @@ packages: resolution: {integrity: sha512-iETxpjK6YoRWJG5o6hXLwvjYAoW+FEZn9os0PD/b6AP6xQwsa/Y7lCVgIixBbUPMfhu+i2LtdeAqVTgGlQarfA==} hasBin: true - regexp.prototype.flags@1.5.3: - resolution: {integrity: sha512-vqlC04+RQoFalODCbCumG2xIOvapzVMHwsyIGM/SIE8fRhFFsXeH8/QQ+s0T0kDAhKc4k30s73/0ydkHQz6HlQ==} + regexp.prototype.flags@1.5.4: + resolution: {integrity: sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==} engines: {node: '>= 0.4'} regexpu-core@6.2.0: @@ -9512,8 +9653,8 @@ packages: resolution: {integrity: sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==} engines: {node: '>= 4'} - reusify@1.0.4: - resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} + reusify@1.1.0: + resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} rfc4648@1.5.3: @@ -9549,8 +9690,11 @@ packages: rxjs@7.8.1: resolution: {integrity: sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==} - safe-array-concat@1.1.2: - resolution: {integrity: sha512-vj6RsCsWBCf19jIeHEfkRMw8DPiBb+DMXklQ/1SGDHOMlHdPUkZXFQ2YdplS23zESTijAcurb1aSgJA3AgMu1Q==} + rxjs@7.8.2: + resolution: {integrity: sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==} + + safe-array-concat@1.1.3: + resolution: {integrity: sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==} engines: {node: '>=0.4'} safe-buffer@5.1.2: @@ -9567,8 +9711,12 @@ packages: resolution: {integrity: sha512-GI3k4zl4aLC3lxZNEEXAxxcXE6E3TfOsJ5xxJPhcAv9MWwnH2O9I0HrDmZFsVnu/C8wzRYSsTHdoVRmL0VicDw==} engines: {node: '>=12'} - safe-regex-test@1.0.3: - resolution: {integrity: sha512-CdASjNJPvRa7roO6Ra/gLYBTzYzzPyyBXxIMdGW3USQLyjWEls2RgW5UBTXaQVp+OrpeCK3bLem8smtmheoRuw==} + safe-push-apply@1.0.0: + resolution: {integrity: sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==} + engines: {node: '>= 0.4'} + + safe-regex-test@1.1.0: + resolution: {integrity: sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==} engines: {node: '>= 0.4'} safe-stable-stringify@2.5.0: @@ -9674,6 +9822,10 @@ packages: resolution: {integrity: sha512-AhICkFV84tBP1aWqPwLZqFvAwqEoVA9kxNMniGEUvzOlm4vLmOFLiTT3UZ6bziJTy4bOVpzWGTfSCbmaayGx8g==} engines: {node: '>=6.9'} + set-proto@1.0.0: + resolution: {integrity: sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==} + engines: {node: '>= 0.4'} + setimmediate@1.0.5: resolution: {integrity: sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==} @@ -9892,6 +10044,9 @@ packages: resolution: {integrity: sha512-l0x1D6vhnsNUGPFVDx45eif0y6eedVC8nm5uACTrVFJFtl2mLRW17aWtVyxFCpn5t94VUPkjU8vSLwIuwwqtJQ==} engines: {node: '>=12.0.0'} + stable-hash@0.0.5: + resolution: {integrity: sha512-+L3ccpzibovGXFK+Ap/f8LOS0ahMrHTf3xu7mMLSpEGU0EO9ucaysSylKo9eRDFNhWve/y275iPmIZ4z39a9iA==} + stack-generator@2.0.10: resolution: {integrity: sha512-mwnua/hkqM6pF4k8SnmZ2zfETsRUpWXREfA/goT8SLCV4iOFa4bzOX2nDipWAZFPTjLvQB82f5yaodMVhK0yJQ==} @@ -9929,8 +10084,8 @@ packages: resolution: {integrity: sha512-UhDfHmA92YAlNnCfhmq0VeNL5bDbiZGg7sZ2IvPsXubGkiNa9EC+tUTsjBRsYUAz87btI6/1wf4XoVvQ3uRnmQ==} engines: {node: '>=18'} - stop-iteration-iterator@1.0.0: - resolution: {integrity: sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==} + stop-iteration-iterator@1.1.0: + resolution: {integrity: sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==} engines: {node: '>= 0.4'} streamsearch@1.1.0: @@ -9964,12 +10119,13 @@ packages: string.prototype.repeat@1.0.0: resolution: {integrity: sha512-0u/TldDbKD8bFCQ/4f5+mNRrXwZ8hg2w7ZR8wa16e8z9XpePWl3eGEcUD0OXpEH/VJH/2G3gjUtR3ZOiBe2S/w==} - string.prototype.trim@1.2.9: - resolution: {integrity: sha512-klHuCNxiMZ8MlsOihJhJEBJAiMVqU3Z2nEXWfWnIqjN0gEFS9J9+IxKozWWtQGcgoa1WUZzLjKPTr4ZHNFTFxw==} + string.prototype.trim@1.2.10: + resolution: {integrity: sha512-Rs66F0P/1kedk5lyYyH9uBzuiI/kNRmwJAR9quK6VOtIpZ2G+hMZd+HQbbv25MgCA6gEffoMZYxlTod4WcdrKA==} engines: {node: '>= 0.4'} - string.prototype.trimend@1.0.8: - resolution: {integrity: sha512-p73uL5VCHCO2BZZ6krwwQE3kCzM7NKmis8S//xEC6fQonchbum4eP6kR4DLEjQFO3Wnj3Fuo8NM0kOSjVdHjZQ==} + string.prototype.trimend@1.0.9: + resolution: {integrity: sha512-G7Ok5C6E/j4SGfyLCloXTrngQIQU3PWtXGst3yM7Bea9FRURf1S42ZHlZZtsNque2FN2PoUhfZXYLNWwEr4dLQ==} + engines: {node: '>= 0.4'} string.prototype.trimstart@1.0.8: resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==} @@ -10136,6 +10292,10 @@ packages: resolution: {integrity: sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==} engines: {node: '>=6'} + tapable@2.2.2: + resolution: {integrity: sha512-Re10+NauLTMCudc7T5WLFLAwDhQ0JWdrMK+9B2M8zR5hRExKmsRDCBA7/aV/pNJFltmBFO5BAMlQFi/vq3nKOg==} + engines: {node: '>=6'} + tar@6.2.1: resolution: {integrity: sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==} engines: {node: '>=10'} @@ -10413,20 +10573,20 @@ packages: resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} engines: {node: '>= 0.6'} - typed-array-buffer@1.0.2: - resolution: {integrity: sha512-gEymJYKZtKXzzBzM4jqa9w6Q1Jjm7x2d+sh19AdsD4wqnMPDYyvwpsIc2Q/835kHuo3BEQ7CjelGhfTsoBb2MQ==} + typed-array-buffer@1.0.3: + resolution: {integrity: sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==} engines: {node: '>= 0.4'} - typed-array-byte-length@1.0.1: - resolution: {integrity: sha512-3iMJ9q0ao7WE9tWcaYKIptkNBuOIcZCCT0d4MRvuuH88fEoEH62IuQe0OtraD3ebQEoTRk8XCBoknUNc1Y67pw==} + typed-array-byte-length@1.0.3: + resolution: {integrity: sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==} engines: {node: '>= 0.4'} - typed-array-byte-offset@1.0.2: - resolution: {integrity: sha512-Ous0vodHa56FviZucS2E63zkgtgrACj7omjwd/8lTEMEPFFyjfixMZ1ZXenpgCFBBt4EC1J2XsyVS2gkG0eTFA==} + typed-array-byte-offset@1.0.4: + resolution: {integrity: sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==} engines: {node: '>= 0.4'} - typed-array-length@1.0.6: - resolution: {integrity: sha512-/OxDN6OtAk5KBpGb28T+HZc2M+ADtvRxXrKKbUwtsLgdoxgX13hyy7ek6bFRl5+aBs2yZzB0c4CnQfAtVypW/g==} + typed-array-length@1.0.7: + resolution: {integrity: sha512-3KS2b+kL7fsuk/eJZ7EQdnEmQoaho/r6KUef7hxvltNA5DR8NAUM+8wJMbJyZ4G9/7i3v5zPBIMN5aybAh2/Jg==} engines: {node: '>= 0.4'} typedarray-to-buffer@3.1.5: @@ -10437,12 +10597,16 @@ packages: engines: {node: '>=14.17'} hasBin: true - unbox-primitive@1.0.2: - resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} + unbox-primitive@1.1.0: + resolution: {integrity: sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==} + engines: {node: '>= 0.4'} undici-types@6.19.8: resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} + undici-types@7.8.0: + resolution: {integrity: sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw==} + unicode-canonical-property-names-ecmascript@2.0.1: resolution: {integrity: sha512-dA8WbNeb2a6oQzAQ55YlT5vQAWGV9WXOsi3SskE3bcCdM0P4SDd+24zS/OCacdRq5BkdsRj9q3Pg6YyQoxIGqg==} engines: {node: '>=4'} @@ -10533,8 +10697,8 @@ packages: resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} engines: {node: '>= 0.8'} - unrs-resolver@1.9.0: - resolution: {integrity: sha512-wqaRu4UnzBD2ABTC1kLfBjAqIDZ5YUTr/MLGa7By47JV1bJDSW7jq/ZSLigB7enLe7ubNaJhtnBXgrc/50cEhg==} + unrs-resolver@1.9.2: + resolution: {integrity: sha512-VUyWiTNQD7itdiMuJy+EuLEErLj3uwX/EpHQF8EOf33Dq3Ju6VW1GXm+swk6+1h7a49uv9fKZ+dft9jU7esdLA==} untildify@4.0.0: resolution: {integrity: sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw==} @@ -10663,6 +10827,9 @@ packages: web-namespaces@2.0.1: resolution: {integrity: sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==} + web-tree-sitter@0.25.6: + resolution: {integrity: sha512-WG+/YGbxw8r+rLlzzhV+OvgiOJCWdIpOucG3qBf3RCBFMkGDb1CanUi2BxCxjnkpzU3/hLWPT8VO5EKsMk9Fxg==} + webidl-conversions@3.0.1: resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} @@ -10785,11 +10952,12 @@ packages: whatwg-url@5.0.0: resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} - which-boxed-primitive@1.0.2: - resolution: {integrity: sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==} + which-boxed-primitive@1.1.1: + resolution: {integrity: sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==} + engines: {node: '>= 0.4'} - which-builtin-type@1.1.4: - resolution: {integrity: sha512-bppkmBSsHFmIMSl8BO9TbsyzsvGjVoppt8xUiGzwiu/bhDCGxnpOKCxgqj6GuyHE0mINMDecBFPlOm2hzY084w==} + which-builtin-type@1.2.1: + resolution: {integrity: sha512-6iBczoX+kDQ7a3+YJBnh3T+KZRxM/iYNPXicqk66/Qfm1b93iu+yOImkg0zHbj5LNOcNv1TEADiZ0xa34B4q6Q==} engines: {node: '>= 0.4'} which-collection@1.0.2: @@ -10800,8 +10968,8 @@ packages: resolution: {integrity: sha512-MOiaDbA5ZZgUjkeMWM5EkJp4loW5ZRoa5bc3/aeMox/PJelMhE6t7S/mLuiY43DBupyxH+S0U1bTui9kWUlmsw==} engines: {node: '>=8.15'} - which-typed-array@1.1.15: - resolution: {integrity: sha512-oV0jmFtUky6CXfkqehVvBP/LSWJ2sy4vWMioiENyJLePrBO/yKyV9OyJySfAKosh+RYkIl5zJCNZ8/4JncrpdA==} + which-typed-array@1.1.19: + resolution: {integrity: sha512-rEvr90Bck4WZt9HHFC4DJMsjvu7x+r6bImz0/BrbWb7A2djJ8hnZMrWnHo9F8ssv0OMErasDhftrfROTyqSDrw==} engines: {node: '>= 0.4'} which@2.0.2: @@ -10930,9 +11098,9 @@ packages: resolution: {integrity: sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==} engines: {node: '>=18'} - yaml@2.6.0: - resolution: {integrity: sha512-a6ae//JvKDEra2kdi1qzCyrJW/WZCgFi8ydDV+eXExl95t+5R+ijnqHJbz9tmMh8FUjx3iv2fCQ4dclAQlO2UQ==} - engines: {node: '>= 14'} + yaml@2.8.0: + resolution: {integrity: sha512-4lLa/EcQCB0cJkyts+FpIRx5G/llPxfP6VQU5KByHEhLxY3IJCH0f0Hy1MHI8sClTvsIb8qwRJ6R/ZdlDJ/leQ==} + engines: {node: '>= 14.6'} hasBin: true yargs-parser@21.1.1: @@ -10969,8 +11137,8 @@ packages: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} - yocto-queue@1.1.1: - resolution: {integrity: sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==} + yocto-queue@1.2.1: + resolution: {integrity: sha512-AyeEbWOu/TAXdxlV9wmGcR0+yh2j3vYPGOECcIj2S7MkrLyC7ne+oye2BKTItt0ii2PHk4cDy+95+LshzbXnGg==} engines: {node: '>=12.20'} zod@3.25.64: @@ -11152,6 +11320,26 @@ snapshots: transitivePeerDependencies: - supports-color + '@babel/core@7.27.7': + dependencies: + '@ampproject/remapping': 2.3.0 + '@babel/code-frame': 7.27.1 + '@babel/generator': 7.27.5 + '@babel/helper-compilation-targets': 7.27.2 + '@babel/helper-module-transforms': 7.27.3(@babel/core@7.27.7) + '@babel/helpers': 7.27.6 + '@babel/parser': 7.27.7 + '@babel/template': 7.27.2 + '@babel/traverse': 7.27.7 + '@babel/types': 7.27.7 + convert-source-map: 2.0.0 + debug: 4.4.1(supports-color@8.1.1) + gensync: 1.0.0-beta.2 + json5: 2.2.3 + semver: 6.3.1 + transitivePeerDependencies: + - supports-color + '@babel/generator@7.27.5': dependencies: '@babel/parser': 7.27.5 @@ -11206,7 +11394,7 @@ snapshots: '@babel/helper-member-expression-to-functions@7.27.1': dependencies: '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color @@ -11226,9 +11414,18 @@ snapshots: transitivePeerDependencies: - supports-color + '@babel/helper-module-transforms@7.27.3(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 + '@babel/helper-module-imports': 7.27.1 + '@babel/helper-validator-identifier': 7.27.1 + '@babel/traverse': 7.27.4 + transitivePeerDependencies: + - supports-color + '@babel/helper-optimise-call-expression@7.27.1': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@babel/helper-plugin-utils@7.27.1': {} @@ -11253,7 +11450,7 @@ snapshots: '@babel/helper-skip-transparent-expression-wrappers@7.27.1': dependencies: '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color @@ -11267,7 +11464,7 @@ snapshots: dependencies: '@babel/template': 7.27.2 '@babel/traverse': 7.27.4 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 transitivePeerDependencies: - supports-color @@ -11280,6 +11477,10 @@ snapshots: dependencies: '@babel/types': 7.27.6 + '@babel/parser@7.27.7': + dependencies: + '@babel/types': 7.27.7 + '@babel/plugin-bugfix-firefox-class-in-computed-class-key@7.27.1(@babel/core@7.27.4)': dependencies: '@babel/core': 7.27.4 @@ -11319,24 +11520,24 @@ snapshots: dependencies: '@babel/core': 7.27.4 - '@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.27.4)': + '@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.27.4)': + '@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.27.4)': + '@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.27.4)': @@ -11354,14 +11555,19 @@ snapshots: '@babel/core': 7.27.4 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.27.4)': + '@babel/plugin-syntax-import-attributes@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 + '@babel/helper-plugin-utils': 7.27.1 + + '@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/plugin-syntax-jsx@7.27.1(@babel/core@7.27.4)': @@ -11369,44 +11575,49 @@ snapshots: '@babel/core': 7.27.4 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.27.4)': + '@babel/plugin-syntax-jsx@7.27.1(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.27.4)': + '@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.27.4)': + '@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.27.4)': + '@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 - '@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.27.4)': + '@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.27.7)': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 + '@babel/helper-plugin-utils': 7.27.1 + + '@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 '@babel/helper-plugin-utils': 7.27.1 '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.27.4)': @@ -11414,6 +11625,11 @@ snapshots: '@babel/core': 7.27.4 '@babel/helper-plugin-utils': 7.27.1 + '@babel/plugin-syntax-typescript@7.27.1(@babel/core@7.27.7)': + dependencies: + '@babel/core': 7.27.7 + '@babel/helper-plugin-utils': 7.27.1 + '@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.27.4)': dependencies: '@babel/core': 7.27.4 @@ -11924,11 +12140,28 @@ snapshots: transitivePeerDependencies: - supports-color + '@babel/traverse@7.27.7': + dependencies: + '@babel/code-frame': 7.27.1 + '@babel/generator': 7.27.5 + '@babel/parser': 7.27.7 + '@babel/template': 7.27.2 + '@babel/types': 7.27.7 + debug: 4.4.1(supports-color@8.1.1) + globals: 11.12.0 + transitivePeerDependencies: + - supports-color + '@babel/types@7.27.6': dependencies: '@babel/helper-string-parser': 7.27.1 '@babel/helper-validator-identifier': 7.27.1 + '@babel/types@7.27.7': + dependencies: + '@babel/helper-string-parser': 7.27.1 + '@babel/helper-validator-identifier': 7.27.1 + '@bcoe/v8-coverage@0.2.3': {} '@colors/colors@1.5.0': @@ -12956,7 +13189,7 @@ snapshots: github-slugger: 1.5.0 globby: 11.1.0 gray-matter: 4.0.3 - jiti: 1.21.6 + jiti: 1.21.7 js-yaml: 4.1.0 lodash: 4.17.21 micromatch: 4.0.8 @@ -12976,10 +13209,10 @@ snapshots: - uglify-js - webpack-cli - '@effortlessmotion/html-webpack-inline-source-plugin@1.0.3(html-webpack-plugin@5.6.3(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1))': + '@effortlessmotion/html-webpack-inline-source-plugin@1.0.3(html-webpack-plugin@5.6.3(webpack@5.99.9))(webpack@5.99.9)': dependencies: escape-string-regexp: 4.0.0 - html-webpack-plugin: 5.6.3(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + html-webpack-plugin: 5.6.3(webpack@5.99.9) slash: 3.0.0 source-map-url: 0.4.1 webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) @@ -13082,7 +13315,7 @@ snapshots: '@eslint-community/regexpp@4.12.1': {} - '@eslint/config-array@0.20.0': + '@eslint/config-array@0.20.1': dependencies: '@eslint/object-schema': 2.1.6 debug: 4.4.1(supports-color@8.1.1) @@ -13090,7 +13323,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@eslint/config-helpers@0.2.2': {} + '@eslint/config-helpers@0.2.3': {} '@eslint/core@0.14.0': dependencies: @@ -13100,7 +13333,7 @@ snapshots: dependencies: ajv: 6.12.6 debug: 4.4.1(supports-color@8.1.1) - espree: 10.3.0 + espree: 10.4.0 globals: 14.0.0 ignore: 5.3.2 import-fresh: 3.3.1 @@ -13375,6 +13608,12 @@ snapshots: '@types/node': 20.17.50 jest-regex-util: 30.0.0 + '@jest/pattern@30.0.1': + dependencies: + '@types/node': 20.17.50 + jest-regex-util: 30.0.1 + optional: true + '@jest/reporters@30.0.0': dependencies: '@bcoe/v8-coverage': 0.2.3 @@ -13409,7 +13648,12 @@ snapshots: '@jest/schemas@30.0.0': dependencies: - '@sinclair/typebox': 0.34.33 + '@sinclair/typebox': 0.34.37 + + '@jest/schemas@30.0.1': + dependencies: + '@sinclair/typebox': 0.34.37 + optional: true '@jest/snapshot-utils@30.0.0': dependencies: @@ -13440,7 +13684,7 @@ snapshots: '@jest/transform@30.0.0': dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@jest/types': 30.0.0 '@jridgewell/trace-mapping': 0.3.25 babel-plugin-istanbul: 7.0.0 @@ -13458,6 +13702,27 @@ snapshots: transitivePeerDependencies: - supports-color + '@jest/transform@30.0.2': + dependencies: + '@babel/core': 7.27.7 + '@jest/types': 30.0.1 + '@jridgewell/trace-mapping': 0.3.25 + babel-plugin-istanbul: 7.0.0 + chalk: 4.1.2 + convert-source-map: 2.0.0 + fast-json-stable-stringify: 2.1.0 + graceful-fs: 4.2.11 + jest-haste-map: 30.0.2 + jest-regex-util: 30.0.1 + jest-util: 30.0.2 + micromatch: 4.0.8 + pirates: 4.0.7 + slash: 3.0.0 + write-file-atomic: 5.0.1 + transitivePeerDependencies: + - supports-color + optional: true + '@jest/types@29.6.3': dependencies: '@jest/schemas': 29.6.3 @@ -13477,6 +13742,17 @@ snapshots: '@types/yargs': 17.0.33 chalk: 4.1.2 + '@jest/types@30.0.1': + dependencies: + '@jest/pattern': 30.0.1 + '@jest/schemas': 30.0.1 + '@types/istanbul-lib-coverage': 2.0.6 + '@types/istanbul-reports': 3.0.4 + '@types/node': 20.17.50 + '@types/yargs': 17.0.33 + chalk: 4.1.2 + optional: true + '@jridgewell/gen-mapping@0.3.5': dependencies: '@jridgewell/set-array': 1.2.1 @@ -13621,7 +13897,7 @@ snapshots: '@nodelib/fs.walk@1.2.8': dependencies: '@nodelib/fs.scandir': 2.1.5 - fastq: 1.17.1 + fastq: 1.19.1 '@nolyfill/is-core-module@1.0.39': {} @@ -13870,7 +14146,7 @@ snapshots: '@pnpm/catalogs.resolver@0.1.1': dependencies: '@pnpm/catalogs.protocol-parser': 0.1.0 - '@pnpm/error': 6.0.3 + '@pnpm/error': 6.0.2 '@pnpm/catalogs.types@0.1.0': {} @@ -13985,7 +14261,7 @@ snapshots: pretty-bytes: 5.6.0 pretty-ms: 7.0.1 ramda: '@pnpm/ramda@0.28.1' - rxjs: 7.8.1 + rxjs: 7.8.2 semver: 7.7.2 stacktracey: 2.1.8 string-length: 4.0.2 @@ -14379,7 +14655,7 @@ snapshots: '@sinclair/typebox@0.27.8': {} - '@sinclair/typebox@0.34.33': {} + '@sinclair/typebox@0.34.37': {} '@sindresorhus/is@4.6.0': {} @@ -14525,7 +14801,7 @@ snapshots: '@tailwindcss/node@4.1.10': dependencies: '@ampproject/remapping': 2.3.0 - enhanced-resolve: 5.18.1 + enhanced-resolve: 5.18.2 jiti: 2.4.2 lightningcss: 1.30.1 magic-string: 0.30.17 @@ -14651,24 +14927,24 @@ snapshots: '@types/babel__core@7.20.5': dependencies: - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 - '@types/babel__generator': 7.6.8 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 + '@types/babel__generator': 7.27.0 '@types/babel__template': 7.4.4 - '@types/babel__traverse': 7.20.6 + '@types/babel__traverse': 7.20.7 - '@types/babel__generator@7.6.8': + '@types/babel__generator@7.27.0': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@types/babel__template@7.4.4': dependencies: - '@babel/parser': 7.27.5 - '@babel/types': 7.27.6 + '@babel/parser': 7.27.7 + '@babel/types': 7.27.7 - '@types/babel__traverse@7.20.6': + '@types/babel__traverse@7.20.7': dependencies: - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@types/body-parser@1.19.5': dependencies: @@ -14792,10 +15068,12 @@ snapshots: '@types/lodash-es@4.17.12': dependencies: - '@types/lodash': 4.17.17 + '@types/lodash': 4.17.19 '@types/lodash@4.17.17': {} + '@types/lodash@4.17.19': {} + '@types/mdast@4.0.4': dependencies: '@types/unist': 3.0.3 @@ -14828,6 +15106,11 @@ snapshots: dependencies: undici-types: 6.19.8 + '@types/node@24.0.7': + dependencies: + undici-types: 7.8.0 + optional: true + '@types/normalize-package-data@2.4.4': {} '@types/normalize-path@3.0.2': {} @@ -14931,7 +15214,7 @@ snapshots: '@types/vscode@1.82.0': {} - '@types/webpack@5.28.5(esbuild@0.25.5)(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))': + '@types/webpack@5.28.5(esbuild@0.25.5)(webpack-cli@6.0.1)': dependencies: '@types/node': 20.17.50 tapable: 2.2.1 @@ -14983,8 +15266,8 @@ snapshots: '@typescript-eslint/project-service@8.34.0(typescript@5.8.3)': dependencies: - '@typescript-eslint/tsconfig-utils': 8.34.0(typescript@5.8.3) - '@typescript-eslint/types': 8.34.0 + '@typescript-eslint/tsconfig-utils': 8.35.0(typescript@5.8.3) + '@typescript-eslint/types': 8.35.0 debug: 4.4.1(supports-color@8.1.1) typescript: 5.8.3 transitivePeerDependencies: @@ -14999,6 +15282,10 @@ snapshots: dependencies: typescript: 5.8.3 + '@typescript-eslint/tsconfig-utils@8.35.0(typescript@5.8.3)': + dependencies: + typescript: 5.8.3 + '@typescript-eslint/type-utils@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3)': dependencies: '@typescript-eslint/typescript-estree': 8.34.0(typescript@5.8.3) @@ -15012,6 +15299,8 @@ snapshots: '@typescript-eslint/types@8.34.0': {} + '@typescript-eslint/types@8.35.0': {} + '@typescript-eslint/typescript-estree@8.34.0(typescript@5.8.3)': dependencies: '@typescript-eslint/project-service': 8.34.0(typescript@5.8.3) @@ -15042,67 +15331,67 @@ snapshots: '@typescript-eslint/visitor-keys@8.34.0': dependencies: '@typescript-eslint/types': 8.34.0 - eslint-visitor-keys: 4.2.0 + eslint-visitor-keys: 4.2.1 '@ungap/structured-clone@1.3.0': {} - '@unrs/resolver-binding-android-arm-eabi@1.9.0': + '@unrs/resolver-binding-android-arm-eabi@1.9.2': optional: true - '@unrs/resolver-binding-android-arm64@1.9.0': + '@unrs/resolver-binding-android-arm64@1.9.2': optional: true - '@unrs/resolver-binding-darwin-arm64@1.9.0': + '@unrs/resolver-binding-darwin-arm64@1.9.2': optional: true - '@unrs/resolver-binding-darwin-x64@1.9.0': + '@unrs/resolver-binding-darwin-x64@1.9.2': optional: true - '@unrs/resolver-binding-freebsd-x64@1.9.0': + '@unrs/resolver-binding-freebsd-x64@1.9.2': optional: true - '@unrs/resolver-binding-linux-arm-gnueabihf@1.9.0': + '@unrs/resolver-binding-linux-arm-gnueabihf@1.9.2': optional: true - '@unrs/resolver-binding-linux-arm-musleabihf@1.9.0': + '@unrs/resolver-binding-linux-arm-musleabihf@1.9.2': optional: true - '@unrs/resolver-binding-linux-arm64-gnu@1.9.0': + '@unrs/resolver-binding-linux-arm64-gnu@1.9.2': optional: true - '@unrs/resolver-binding-linux-arm64-musl@1.9.0': + '@unrs/resolver-binding-linux-arm64-musl@1.9.2': optional: true - '@unrs/resolver-binding-linux-ppc64-gnu@1.9.0': + '@unrs/resolver-binding-linux-ppc64-gnu@1.9.2': optional: true - '@unrs/resolver-binding-linux-riscv64-gnu@1.9.0': + '@unrs/resolver-binding-linux-riscv64-gnu@1.9.2': optional: true - '@unrs/resolver-binding-linux-riscv64-musl@1.9.0': + '@unrs/resolver-binding-linux-riscv64-musl@1.9.2': optional: true - '@unrs/resolver-binding-linux-s390x-gnu@1.9.0': + '@unrs/resolver-binding-linux-s390x-gnu@1.9.2': optional: true - '@unrs/resolver-binding-linux-x64-gnu@1.9.0': + '@unrs/resolver-binding-linux-x64-gnu@1.9.2': optional: true - '@unrs/resolver-binding-linux-x64-musl@1.9.0': + '@unrs/resolver-binding-linux-x64-musl@1.9.2': optional: true - '@unrs/resolver-binding-wasm32-wasi@1.9.0': + '@unrs/resolver-binding-wasm32-wasi@1.9.2': dependencies: '@napi-rs/wasm-runtime': 0.2.11 optional: true - '@unrs/resolver-binding-win32-arm64-msvc@1.9.0': + '@unrs/resolver-binding-win32-arm64-msvc@1.9.2': optional: true - '@unrs/resolver-binding-win32-ia32-msvc@1.9.0': + '@unrs/resolver-binding-win32-ia32-msvc@1.9.2': optional: true - '@unrs/resolver-binding-win32-x64-msvc@1.9.0': + '@unrs/resolver-binding-win32-x64-msvc@1.9.2': optional: true '@vscode/test-electron@2.5.2': @@ -15191,12 +15480,12 @@ snapshots: '@webassemblyjs/ast': 1.14.1 '@xtuc/long': 4.2.2 - '@webpack-cli/configtest@3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1))': + '@webpack-cli/configtest@3.0.1(webpack-cli@6.0.1)(webpack@5.99.9)': dependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) webpack-cli: 6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9) - '@webpack-cli/generators@3.0.7(encoding@0.1.13)(mem-fs@2.3.0)(prettier@3.3.3)(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1))': + '@webpack-cli/generators@3.0.7(encoding@0.1.13)(mem-fs@2.3.0)(prettier@3.3.3)(webpack-cli@6.0.1)(webpack@5.99.9)': dependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) webpack-cli: 6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9) @@ -15210,12 +15499,12 @@ snapshots: - mem-fs - supports-color - '@webpack-cli/info@3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1))': + '@webpack-cli/info@3.0.1(webpack-cli@6.0.1)(webpack@5.99.9)': dependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) webpack-cli: 6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9) - '@webpack-cli/serve@3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack-dev-server@5.2.2(webpack-cli@6.0.1)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1))': + '@webpack-cli/serve@3.0.1(webpack-cli@6.0.1)(webpack-dev-server@5.2.2)(webpack@5.99.9)': dependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) webpack-cli: 6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9) @@ -15251,9 +15540,9 @@ snapshots: mime-types: 2.1.35 negotiator: 0.6.3 - acorn-jsx@5.3.2(acorn@8.14.1): + acorn-jsx@5.3.2(acorn@8.15.0): dependencies: - acorn: 8.14.1 + acorn: 8.15.0 acorn-walk@8.3.4: dependencies: @@ -15261,6 +15550,8 @@ snapshots: acorn@8.14.1: {} + acorn@8.15.0: {} + address@1.2.2: {} agent-base@6.0.2: @@ -15402,76 +15693,78 @@ snapshots: dependencies: dequal: 2.0.3 - array-buffer-byte-length@1.0.1: + array-buffer-byte-length@1.0.2: dependencies: - call-bind: 1.0.7 - is-array-buffer: 3.0.4 + call-bound: 1.0.4 + is-array-buffer: 3.0.5 array-differ@3.0.0: {} array-flatten@1.1.1: {} - array-includes@3.1.8: + array-includes@3.1.9: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-object-atoms: 1.1.1 get-intrinsic: 1.3.0 - is-string: 1.0.7 + is-string: 1.1.1 + math-intrinsics: 1.1.0 array-union@2.1.0: {} array.prototype.findlast@1.2.5: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 es-object-atoms: 1.1.1 - es-shim-unscopables: 1.0.2 + es-shim-unscopables: 1.1.0 - array.prototype.findlastindex@1.2.5: + array.prototype.findlastindex@1.2.6: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 es-object-atoms: 1.1.1 - es-shim-unscopables: 1.0.2 + es-shim-unscopables: 1.1.0 - array.prototype.flat@1.3.2: + array.prototype.flat@1.3.3: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 - es-shim-unscopables: 1.0.2 + es-abstract: 1.24.0 + es-shim-unscopables: 1.1.0 - array.prototype.flatmap@1.3.2: + array.prototype.flatmap@1.3.3: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 - es-shim-unscopables: 1.0.2 + es-abstract: 1.24.0 + es-shim-unscopables: 1.1.0 array.prototype.tosorted@1.1.4: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 - es-shim-unscopables: 1.0.2 + es-shim-unscopables: 1.1.0 - arraybuffer.prototype.slice@1.0.3: + arraybuffer.prototype.slice@1.0.4: dependencies: - array-buffer-byte-length: 1.0.1 - call-bind: 1.0.7 + array-buffer-byte-length: 1.0.2 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 get-intrinsic: 1.3.0 - is-array-buffer: 3.0.4 - is-shared-array-buffer: 1.0.3 + is-array-buffer: 3.0.5 arrify@1.0.1: {} @@ -15491,6 +15784,8 @@ snapshots: astring@1.9.0: {} + async-function@1.0.0: {} + async@2.6.4: dependencies: lodash: 4.17.21 @@ -15509,25 +15804,39 @@ snapshots: available-typed-arrays@1.0.7: dependencies: - possible-typed-array-names: 1.0.0 + possible-typed-array-names: 1.1.0 axe-core@4.10.0: {} axobject-query@4.1.0: {} - babel-jest@30.0.0(@babel/core@7.27.4): + babel-jest@30.0.0(@babel/core@7.27.7): dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@jest/transform': 30.0.0 '@types/babel__core': 7.20.5 babel-plugin-istanbul: 7.0.0 - babel-preset-jest: 30.0.0(@babel/core@7.27.4) + babel-preset-jest: 30.0.0(@babel/core@7.27.7) chalk: 4.1.2 graceful-fs: 4.2.11 slash: 3.0.0 transitivePeerDependencies: - supports-color + babel-jest@30.0.2(@babel/core@7.27.7): + dependencies: + '@babel/core': 7.27.7 + '@jest/transform': 30.0.2 + '@types/babel__core': 7.20.5 + babel-plugin-istanbul: 7.0.0 + babel-preset-jest: 30.0.1(@babel/core@7.27.7) + chalk: 4.1.2 + graceful-fs: 4.2.11 + slash: 3.0.0 + transitivePeerDependencies: + - supports-color + optional: true + babel-loader@9.2.1(@babel/core@7.27.4)(webpack@5.99.9(esbuild@0.25.5)): dependencies: '@babel/core': 7.27.4 @@ -15552,9 +15861,16 @@ snapshots: babel-plugin-jest-hoist@30.0.0: dependencies: '@babel/template': 7.27.2 - '@babel/types': 7.27.6 + '@babel/types': 7.27.7 '@types/babel__core': 7.20.5 + babel-plugin-jest-hoist@30.0.1: + dependencies: + '@babel/template': 7.27.2 + '@babel/types': 7.27.7 + '@types/babel__core': 7.20.5 + optional: true + babel-plugin-polyfill-corejs2@0.4.11(@babel/core@7.27.4): dependencies: '@babel/compat-data': 7.27.5 @@ -15579,30 +15895,37 @@ snapshots: transitivePeerDependencies: - supports-color - babel-preset-current-node-syntax@1.1.0(@babel/core@7.27.4): - dependencies: - '@babel/core': 7.27.4 - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.27.4) - '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.27.4) - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.27.4) - '@babel/plugin-syntax-import-attributes': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.27.4) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.27.4) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.27.4) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.27.4) - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.27.4) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.27.4) - - babel-preset-jest@30.0.0(@babel/core@7.27.4): - dependencies: - '@babel/core': 7.27.4 + babel-preset-current-node-syntax@1.1.0(@babel/core@7.27.7): + dependencies: + '@babel/core': 7.27.7 + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.27.7) + '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.27.7) + '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.27.7) + '@babel/plugin-syntax-import-attributes': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.27.7) + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.27.7) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.27.7) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.27.7) + '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.27.7) + '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.27.7) + + babel-preset-jest@30.0.0(@babel/core@7.27.7): + dependencies: + '@babel/core': 7.27.7 babel-plugin-jest-hoist: 30.0.0 - babel-preset-current-node-syntax: 1.1.0(@babel/core@7.27.4) + babel-preset-current-node-syntax: 1.1.0(@babel/core@7.27.7) + + babel-preset-jest@30.0.1(@babel/core@7.27.7): + dependencies: + '@babel/core': 7.27.7 + babel-plugin-jest-hoist: 30.0.1 + babel-preset-current-node-syntax: 1.1.0(@babel/core@7.27.7) + optional: true bail@2.0.2: {} @@ -15853,6 +16176,13 @@ snapshots: get-intrinsic: 1.3.0 set-function-length: 1.2.2 + call-bind@1.0.8: + dependencies: + call-bind-apply-helpers: 1.0.2 + es-define-property: 1.0.1 + get-intrinsic: 1.3.0 + set-function-length: 1.2.2 + call-bound@1.0.4: dependencies: call-bind-apply-helpers: 1.0.2 @@ -16290,7 +16620,7 @@ snapshots: optionalDependencies: webpack: 5.99.9(esbuild@0.25.5) - css-loader@7.1.2(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + css-loader@7.1.2(webpack@5.99.9): dependencies: icss-utils: 5.1.0(postcss@8.5.5) postcss: 8.5.5 @@ -16436,23 +16766,23 @@ snapshots: whatwg-mimetype: 4.0.0 whatwg-url: 14.2.0 - data-view-buffer@1.0.1: + data-view-buffer@1.0.2: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 es-errors: 1.3.0 - is-data-view: 1.0.1 + is-data-view: 1.0.2 - data-view-byte-length@1.0.1: + data-view-byte-length@1.0.2: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 es-errors: 1.3.0 - is-data-view: 1.0.1 + is-data-view: 1.0.2 - data-view-byte-offset@1.0.0: + data-view-byte-offset@1.0.1: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 es-errors: 1.3.0 - is-data-view: 1.0.1 + is-data-view: 1.0.2 dateformat@4.6.3: {} @@ -16501,24 +16831,24 @@ snapshots: deep-equal@2.2.3: dependencies: - array-buffer-byte-length: 1.0.1 - call-bind: 1.0.7 + array-buffer-byte-length: 1.0.2 + call-bind: 1.0.8 es-get-iterator: 1.1.3 get-intrinsic: 1.3.0 is-arguments: 1.1.1 - is-array-buffer: 3.0.4 - is-date-object: 1.0.5 - is-regex: 1.1.4 - is-shared-array-buffer: 1.0.3 + is-array-buffer: 3.0.5 + is-date-object: 1.1.0 + is-regex: 1.2.1 + is-shared-array-buffer: 1.0.4 isarray: 2.0.5 object-is: 1.1.6 object-keys: 1.1.1 - object.assign: 4.1.5 - regexp.prototype.flags: 1.5.3 + object.assign: 4.1.7 + regexp.prototype.flags: 1.5.4 side-channel: 1.1.0 - which-boxed-primitive: 1.0.2 + which-boxed-primitive: 1.1.1 which-collection: 1.0.2 - which-typed-array: 1.1.15 + which-typed-array: 1.1.19 deep-extend@0.6.0: {} @@ -16723,6 +17053,11 @@ snapshots: graceful-fs: 4.2.11 tapable: 2.2.1 + enhanced-resolve@5.18.2: + dependencies: + graceful-fs: 4.2.11 + tapable: 2.2.2 + enquirer@2.4.1: dependencies: ansi-colors: 4.1.3 @@ -16750,54 +17085,62 @@ snapshots: error@10.4.0: {} - es-abstract@1.23.3: + es-abstract@1.24.0: dependencies: - array-buffer-byte-length: 1.0.1 - arraybuffer.prototype.slice: 1.0.3 + array-buffer-byte-length: 1.0.2 + arraybuffer.prototype.slice: 1.0.4 available-typed-arrays: 1.0.7 - call-bind: 1.0.7 - data-view-buffer: 1.0.1 - data-view-byte-length: 1.0.1 - data-view-byte-offset: 1.0.0 + call-bind: 1.0.8 + call-bound: 1.0.4 + data-view-buffer: 1.0.2 + data-view-byte-length: 1.0.2 + data-view-byte-offset: 1.0.1 es-define-property: 1.0.1 es-errors: 1.3.0 es-object-atoms: 1.1.1 - es-set-tostringtag: 2.0.3 - es-to-primitive: 1.2.1 - function.prototype.name: 1.1.6 + es-set-tostringtag: 2.1.0 + es-to-primitive: 1.3.0 + function.prototype.name: 1.1.8 get-intrinsic: 1.3.0 - get-symbol-description: 1.0.2 + get-proto: 1.0.1 + get-symbol-description: 1.1.0 globalthis: 1.0.4 gopd: 1.2.0 has-property-descriptors: 1.0.2 - has-proto: 1.0.3 + has-proto: 1.2.0 has-symbols: 1.1.0 hasown: 2.0.2 - internal-slot: 1.0.7 - is-array-buffer: 3.0.4 + internal-slot: 1.1.0 + is-array-buffer: 3.0.5 is-callable: 1.2.7 - is-data-view: 1.0.1 + is-data-view: 1.0.2 is-negative-zero: 2.0.3 - is-regex: 1.1.4 - is-shared-array-buffer: 1.0.3 - is-string: 1.0.7 - is-typed-array: 1.1.13 - is-weakref: 1.0.2 + is-regex: 1.2.1 + is-set: 2.0.3 + is-shared-array-buffer: 1.0.4 + is-string: 1.1.1 + is-typed-array: 1.1.15 + is-weakref: 1.1.1 + math-intrinsics: 1.1.0 object-inspect: 1.13.4 object-keys: 1.1.1 - object.assign: 4.1.5 - regexp.prototype.flags: 1.5.3 - safe-array-concat: 1.1.2 - safe-regex-test: 1.0.3 - string.prototype.trim: 1.2.9 - string.prototype.trimend: 1.0.8 + object.assign: 4.1.7 + own-keys: 1.0.1 + regexp.prototype.flags: 1.5.4 + safe-array-concat: 1.1.3 + safe-push-apply: 1.0.0 + safe-regex-test: 1.1.0 + set-proto: 1.0.0 + stop-iteration-iterator: 1.1.0 + string.prototype.trim: 1.2.10 + string.prototype.trimend: 1.0.9 string.prototype.trimstart: 1.0.8 - typed-array-buffer: 1.0.2 - typed-array-byte-length: 1.0.1 - typed-array-byte-offset: 1.0.2 - typed-array-length: 1.0.6 - unbox-primitive: 1.0.2 - which-typed-array: 1.1.15 + typed-array-buffer: 1.0.3 + typed-array-byte-length: 1.0.3 + typed-array-byte-offset: 1.0.4 + typed-array-length: 1.0.7 + unbox-primitive: 1.1.0 + which-typed-array: 1.1.19 es-define-property@1.0.1: {} @@ -16805,32 +17148,32 @@ snapshots: es-get-iterator@1.1.3: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 get-intrinsic: 1.3.0 has-symbols: 1.1.0 is-arguments: 1.1.1 is-map: 2.0.3 is-set: 2.0.3 - is-string: 1.0.7 + is-string: 1.1.1 isarray: 2.0.5 - stop-iteration-iterator: 1.0.0 + stop-iteration-iterator: 1.1.0 es-iterator-helpers@1.1.0: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 - es-set-tostringtag: 2.0.3 + es-set-tostringtag: 2.1.0 function-bind: 1.1.2 get-intrinsic: 1.3.0 globalthis: 1.0.4 has-property-descriptors: 1.0.2 - has-proto: 1.0.3 + has-proto: 1.2.0 has-symbols: 1.1.0 - internal-slot: 1.0.7 + internal-slot: 1.1.0 iterator.prototype: 1.1.3 - safe-array-concat: 1.1.2 + safe-array-concat: 1.1.3 es-module-lexer@1.5.4: {} @@ -16838,21 +17181,22 @@ snapshots: dependencies: es-errors: 1.3.0 - es-set-tostringtag@2.0.3: + es-set-tostringtag@2.1.0: dependencies: + es-errors: 1.3.0 get-intrinsic: 1.3.0 has-tostringtag: 1.0.2 hasown: 2.0.2 - es-shim-unscopables@1.0.2: + es-shim-unscopables@1.1.0: dependencies: hasown: 2.0.2 - es-to-primitive@1.2.1: + es-to-primitive@1.3.0: dependencies: is-callable: 1.2.7 - is-date-object: 1.0.5 - is-symbol: 1.0.4 + is-date-object: 1.1.0 + is-symbol: 1.1.1 esbuild@0.25.5: optionalDependencies: @@ -16904,7 +17248,7 @@ snapshots: '@typescript-eslint/parser': 8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3) eslint: 9.28.0(jiti@2.4.2) eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.3(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)) + eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)) eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)) eslint-plugin-jsx-a11y: 6.10.0(eslint@9.28.0(jiti@2.4.2)) eslint-plugin-react: 7.37.1(eslint@9.28.0(jiti@2.4.2)) @@ -16920,67 +17264,52 @@ snapshots: dependencies: eslint: 9.28.0(jiti@2.4.2) - eslint-import-context@0.1.8(unrs-resolver@1.9.0): + eslint-import-context@0.1.8(unrs-resolver@1.9.2): dependencies: get-tsconfig: 4.10.1 stable-hash-x: 0.1.1 optionalDependencies: - unrs-resolver: 1.9.0 + unrs-resolver: 1.9.2 eslint-import-resolver-node@0.3.9: dependencies: debug: 3.2.7 - is-core-module: 2.15.1 + is-core-module: 2.16.1 resolve: 1.22.8 transitivePeerDependencies: - supports-color - eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)): + eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)): dependencies: '@nolyfill/is-core-module': 1.0.39 debug: 4.4.1(supports-color@8.1.1) - enhanced-resolve: 5.18.1 eslint: 9.28.0(jiti@2.4.2) - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)))(eslint@9.28.0(jiti@2.4.2)) - fast-glob: 3.3.3 get-tsconfig: 4.10.1 - is-bun-module: 1.2.1 - is-glob: 4.0.3 + is-bun-module: 2.0.0 + stable-hash: 0.0.5 + tinyglobby: 0.2.14 + unrs-resolver: 1.9.2 optionalDependencies: eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)) transitivePeerDependencies: - - '@typescript-eslint/parser' - - eslint-import-resolver-node - - eslint-import-resolver-webpack - supports-color eslint-import-resolver-typescript@4.4.3(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)): dependencies: debug: 4.4.1(supports-color@8.1.1) eslint: 9.28.0(jiti@2.4.2) - eslint-import-context: 0.1.8(unrs-resolver@1.9.0) + eslint-import-context: 0.1.8(unrs-resolver@1.9.2) get-tsconfig: 4.10.1 is-bun-module: 2.0.0 stable-hash-x: 0.1.1 tinyglobby: 0.2.14 - unrs-resolver: 1.9.0 + unrs-resolver: 1.9.2 optionalDependencies: eslint-plugin-import: 2.31.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)) transitivePeerDependencies: - supports-color - eslint-module-utils@2.12.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.3(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)))(eslint@9.28.0(jiti@2.4.2)): - dependencies: - debug: 3.2.7 - optionalDependencies: - '@typescript-eslint/parser': 8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3) - eslint: 9.28.0(jiti@2.4.2) - eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.3(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)) - transitivePeerDependencies: - - supports-color - - eslint-module-utils@2.12.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.3(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)))(eslint@9.28.0(jiti@2.4.2)): + eslint-module-utils@2.12.1(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)): dependencies: debug: 3.2.7 optionalDependencies: @@ -16994,24 +17323,24 @@ snapshots: eslint-plugin-import@2.31.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)): dependencies: '@rtsao/scc': 1.1.0 - array-includes: 3.1.8 - array.prototype.findlastindex: 1.2.5 - array.prototype.flat: 1.3.2 - array.prototype.flatmap: 1.3.2 + array-includes: 3.1.9 + array.prototype.findlastindex: 1.2.6 + array.prototype.flat: 1.3.3 + array.prototype.flatmap: 1.3.3 debug: 3.2.7 doctrine: 2.1.0 eslint: 9.28.0(jiti@2.4.2) eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.12.0(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.3(eslint-plugin-import@2.31.0)(eslint@9.28.0(jiti@2.4.2)))(eslint@9.28.0(jiti@2.4.2)) + eslint-module-utils: 2.12.1(@typescript-eslint/parser@8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@4.4.3)(eslint@9.28.0(jiti@2.4.2)) hasown: 2.0.2 - is-core-module: 2.15.1 + is-core-module: 2.16.1 is-glob: 4.0.3 minimatch: 3.1.2 object.fromentries: 2.0.8 object.groupby: 1.0.3 - object.values: 1.2.0 + object.values: 1.2.1 semver: 6.3.1 - string.prototype.trimend: 1.0.8 + string.prototype.trimend: 1.0.9 tsconfig-paths: 3.15.0 optionalDependencies: '@typescript-eslint/parser': 8.34.0(eslint@9.28.0(jiti@2.4.2))(typescript@5.8.3) @@ -17023,8 +17352,8 @@ snapshots: eslint-plugin-jsx-a11y@6.10.0(eslint@9.28.0(jiti@2.4.2)): dependencies: aria-query: 5.1.3 - array-includes: 3.1.8 - array.prototype.flatmap: 1.3.2 + array-includes: 3.1.9 + array.prototype.flatmap: 1.3.3 ast-types-flow: 0.0.8 axe-core: 4.10.0 axobject-query: 4.1.0 @@ -17037,7 +17366,7 @@ snapshots: language-tags: 1.0.9 minimatch: 3.1.2 object.fromentries: 2.0.8 - safe-regex-test: 1.0.3 + safe-regex-test: 1.1.0 string.prototype.includes: 2.0.1 eslint-plugin-mocha@10.5.0(eslint@9.28.0(jiti@2.4.2)): @@ -17053,9 +17382,9 @@ snapshots: eslint-plugin-react@7.37.1(eslint@9.28.0(jiti@2.4.2)): dependencies: - array-includes: 3.1.8 + array-includes: 3.1.9 array.prototype.findlast: 1.2.5 - array.prototype.flatmap: 1.3.2 + array.prototype.flatmap: 1.3.3 array.prototype.tosorted: 1.1.4 doctrine: 2.1.0 es-iterator-helpers: 1.1.0 @@ -17066,7 +17395,7 @@ snapshots: minimatch: 3.1.2 object.entries: 1.1.8 object.fromentries: 2.0.8 - object.values: 1.2.0 + object.values: 1.2.1 prop-types: 15.8.1 resolve: 2.0.0-next.5 semver: 6.3.1 @@ -17104,7 +17433,7 @@ snapshots: esrecurse: 4.3.0 estraverse: 4.3.0 - eslint-scope@8.3.0: + eslint-scope@8.4.0: dependencies: esrecurse: 4.3.0 estraverse: 5.3.0 @@ -17118,14 +17447,14 @@ snapshots: eslint-visitor-keys@3.4.3: {} - eslint-visitor-keys@4.2.0: {} + eslint-visitor-keys@4.2.1: {} eslint@9.28.0(jiti@2.4.2): dependencies: '@eslint-community/eslint-utils': 4.7.0(eslint@9.28.0(jiti@2.4.2)) '@eslint-community/regexpp': 4.12.1 - '@eslint/config-array': 0.20.0 - '@eslint/config-helpers': 0.2.2 + '@eslint/config-array': 0.20.1 + '@eslint/config-helpers': 0.2.3 '@eslint/core': 0.14.0 '@eslint/eslintrc': 3.3.1 '@eslint/js': 9.28.0 @@ -17140,9 +17469,9 @@ snapshots: cross-spawn: 7.0.6 debug: 4.4.1(supports-color@8.1.1) escape-string-regexp: 4.0.0 - eslint-scope: 8.3.0 - eslint-visitor-keys: 4.2.0 - espree: 10.3.0 + eslint-scope: 8.4.0 + eslint-visitor-keys: 4.2.1 + espree: 10.4.0 esquery: 1.6.0 esutils: 2.0.3 fast-deep-equal: 3.1.3 @@ -17162,11 +17491,11 @@ snapshots: transitivePeerDependencies: - supports-color - espree@10.3.0: + espree@10.4.0: dependencies: - acorn: 8.14.1 - acorn-jsx: 5.3.2(acorn@8.14.1) - eslint-visitor-keys: 4.2.0 + acorn: 8.15.0 + acorn-jsx: 5.3.2(acorn@8.15.0) + eslint-visitor-keys: 4.2.1 esprima@4.0.1: {} @@ -17356,9 +17685,9 @@ snapshots: fastest-stable-stringify@2.0.2: {} - fastq@1.17.1: + fastq@1.19.1: dependencies: - reusify: 1.0.4 + reusify: 1.1.0 fault@2.0.1: dependencies: @@ -17460,7 +17789,7 @@ snapshots: follow-redirects@1.15.9: {} - for-each@0.3.3: + for-each@0.3.5: dependencies: is-callable: 1.2.7 @@ -17502,12 +17831,14 @@ snapshots: function-bind@1.1.2: {} - function.prototype.name@1.1.6: + function.prototype.name@1.1.8: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 define-properties: 1.2.1 - es-abstract: 1.23.3 functions-have-names: 1.2.3 + hasown: 2.0.2 + is-callable: 1.2.7 functions-have-names@1.2.3: {} @@ -17571,9 +17902,9 @@ snapshots: get-stream@6.0.1: {} - get-symbol-description@1.0.2: + get-symbol-description@1.1.0: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 es-errors: 1.3.0 get-intrinsic: 1.3.0 @@ -17723,7 +18054,7 @@ snapshots: hard-rejection@2.1.0: {} - has-bigints@1.0.2: {} + has-bigints@1.1.0: {} has-flag@4.0.0: {} @@ -17731,7 +18062,9 @@ snapshots: dependencies: es-define-property: 1.0.1 - has-proto@1.0.3: {} + has-proto@1.2.0: + dependencies: + dunder-proto: 1.0.1 has-symbols@1.1.0: {} @@ -17921,7 +18254,7 @@ snapshots: html-void-elements@3.0.0: {} - html-webpack-plugin@5.6.3(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + html-webpack-plugin@5.6.3(webpack@5.99.9(esbuild@0.25.5)): dependencies: '@types/html-minifier-terser': 6.1.0 html-minifier-terser: 6.1.0 @@ -17929,9 +18262,9 @@ snapshots: pretty-error: 4.0.0 tapable: 2.2.1 optionalDependencies: - webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) + webpack: 5.99.9(esbuild@0.25.5) - html-webpack-plugin@5.6.3(webpack@5.99.9(esbuild@0.25.5)): + html-webpack-plugin@5.6.3(webpack@5.99.9): dependencies: '@types/html-minifier-terser': 6.1.0 html-minifier-terser: 6.1.0 @@ -17939,7 +18272,7 @@ snapshots: pretty-error: 4.0.0 tapable: 2.2.1 optionalDependencies: - webpack: 5.99.9(esbuild@0.25.5) + webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) htmlparser2@6.1.0: dependencies: @@ -18166,7 +18499,7 @@ snapshots: through: 2.3.8 wrap-ansi: 6.2.0 - internal-slot@1.0.7: + internal-slot@1.1.0: dependencies: es-errors: 1.3.0 hasown: 2.0.2 @@ -18198,33 +18531,38 @@ snapshots: is-arguments@1.1.1: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 has-tostringtag: 1.0.2 - is-array-buffer@3.0.4: + is-array-buffer@3.0.5: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 get-intrinsic: 1.3.0 is-arrayish@0.2.1: {} is-arrayish@0.3.2: {} - is-async-function@2.0.0: + is-async-function@2.1.1: dependencies: + async-function: 1.0.0 + call-bound: 1.0.4 + get-proto: 1.0.1 has-tostringtag: 1.0.2 + safe-regex-test: 1.1.0 - is-bigint@1.0.4: + is-bigint@1.1.0: dependencies: - has-bigints: 1.0.2 + has-bigints: 1.1.0 is-binary-path@2.1.0: dependencies: binary-extensions: 2.3.0 - is-boolean-object@1.1.2: + is-boolean-object@1.2.2: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 has-tostringtag: 1.0.2 is-buffer@1.1.6: {} @@ -18233,10 +18571,6 @@ snapshots: dependencies: builtin-modules: 3.3.0 - is-bun-module@1.2.1: - dependencies: - semver: 7.7.2 - is-bun-module@2.0.0: dependencies: semver: 7.7.2 @@ -18247,16 +18581,19 @@ snapshots: dependencies: ci-info: 3.9.0 - is-core-module@2.15.1: + is-core-module@2.16.1: dependencies: hasown: 2.0.2 - is-data-view@1.0.1: + is-data-view@1.0.2: dependencies: - is-typed-array: 1.1.13 + call-bound: 1.0.4 + get-intrinsic: 1.3.0 + is-typed-array: 1.1.15 - is-date-object@1.0.5: + is-date-object@1.1.0: dependencies: + call-bound: 1.0.4 has-tostringtag: 1.0.2 is-decimal@2.0.1: {} @@ -18269,17 +18606,20 @@ snapshots: is-extglob@2.1.1: {} - is-finalizationregistry@1.0.2: + is-finalizationregistry@1.1.1: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 is-fullwidth-code-point@3.0.0: {} is-generator-fn@2.1.0: {} - is-generator-function@1.0.10: + is-generator-function@1.1.0: dependencies: + call-bound: 1.0.4 + get-proto: 1.0.1 has-tostringtag: 1.0.2 + safe-regex-test: 1.1.0 is-glob@4.0.3: dependencies: @@ -18310,8 +18650,9 @@ snapshots: is-npm@6.0.0: {} - is-number-object@1.0.7: + is-number-object@1.1.1: dependencies: + call-bound: 1.0.4 has-tostringtag: 1.0.2 is-number@7.0.0: {} @@ -18342,10 +18683,12 @@ snapshots: dependencies: '@types/estree': 1.0.7 - is-regex@1.1.4: + is-regex@1.2.1: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 + gopd: 1.2.0 has-tostringtag: 1.0.2 + hasown: 2.0.2 is-regexp@1.0.0: {} @@ -18355,27 +18698,30 @@ snapshots: is-set@2.0.3: {} - is-shared-array-buffer@1.0.3: + is-shared-array-buffer@1.0.4: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 is-stream@2.0.1: {} - is-string@1.0.7: + is-string@1.1.1: dependencies: + call-bound: 1.0.4 has-tostringtag: 1.0.2 is-subdir@1.2.0: dependencies: better-path-resolve: 1.0.0 - is-symbol@1.0.4: + is-symbol@1.1.1: dependencies: + call-bound: 1.0.4 has-symbols: 1.1.0 + safe-regex-test: 1.1.0 - is-typed-array@1.1.13: + is-typed-array@1.1.15: dependencies: - which-typed-array: 1.1.15 + which-typed-array: 1.1.19 is-typedarray@1.0.0: {} @@ -18389,13 +18735,13 @@ snapshots: is-weakmap@2.0.2: {} - is-weakref@1.0.2: + is-weakref@1.1.1: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 is-weakset@2.0.3: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 get-intrinsic: 1.3.0 is-windows@1.0.2: {} @@ -18428,8 +18774,8 @@ snapshots: istanbul-lib-instrument@6.0.3: dependencies: - '@babel/core': 7.27.4 - '@babel/parser': 7.27.5 + '@babel/core': 7.27.7 + '@babel/parser': 7.27.7 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.2 semver: 7.7.2 @@ -18460,7 +18806,7 @@ snapshots: define-properties: 1.2.1 get-intrinsic: 1.3.0 has-symbols: 1.1.0 - reflect.getprototypeof: 1.0.6 + reflect.getprototypeof: 1.0.10 set-function-name: 2.0.2 itertools@2.4.1: {} @@ -18537,12 +18883,12 @@ snapshots: jest-config@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)): dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@jest/get-type': 30.0.0 '@jest/pattern': 30.0.0 '@jest/test-sequencer': 30.0.0 '@jest/types': 30.0.0 - babel-jest: 30.0.0(@babel/core@7.27.4) + babel-jest: 30.0.0(@babel/core@7.27.7) chalk: 4.1.2 ci-info: 4.2.0 deepmerge: 4.3.1 @@ -18633,6 +18979,22 @@ snapshots: optionalDependencies: fsevents: 2.3.3 + jest-haste-map@30.0.2: + dependencies: + '@jest/types': 30.0.1 + '@types/node': 20.17.50 + anymatch: 3.1.3 + fb-watchman: 2.0.2 + graceful-fs: 4.2.11 + jest-regex-util: 30.0.1 + jest-util: 30.0.2 + jest-worker: 30.0.2 + micromatch: 4.0.8 + walker: 1.0.8 + optionalDependencies: + fsevents: 2.3.3 + optional: true + jest-leak-detector@30.0.0: dependencies: '@jest/get-type': 30.0.0 @@ -18688,6 +19050,9 @@ snapshots: jest-regex-util@30.0.0: {} + jest-regex-util@30.0.1: + optional: true + jest-resolve-dependencies@30.0.0: dependencies: jest-regex-util: 30.0.0 @@ -18704,7 +19069,7 @@ snapshots: jest-util: 30.0.0 jest-validate: 30.0.0 slash: 3.0.0 - unrs-resolver: 1.9.0 + unrs-resolver: 1.9.2 jest-runner@30.0.0: dependencies: @@ -18762,17 +19127,17 @@ snapshots: jest-snapshot@30.0.0: dependencies: - '@babel/core': 7.27.4 + '@babel/core': 7.27.7 '@babel/generator': 7.27.5 - '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.4) - '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.27.4) - '@babel/types': 7.27.6 + '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.27.7) + '@babel/plugin-syntax-typescript': 7.27.1(@babel/core@7.27.7) + '@babel/types': 7.27.7 '@jest/expect-utils': 30.0.0 '@jest/get-type': 30.0.0 '@jest/snapshot-utils': 30.0.0 '@jest/transform': 30.0.0 '@jest/types': 30.0.0 - babel-preset-current-node-syntax: 1.1.0(@babel/core@7.27.4) + babel-preset-current-node-syntax: 1.1.0(@babel/core@7.27.7) chalk: 4.1.2 expect: 30.0.0 graceful-fs: 4.2.11 @@ -18804,6 +19169,16 @@ snapshots: graceful-fs: 4.2.11 picomatch: 4.0.2 + jest-util@30.0.2: + dependencies: + '@jest/types': 30.0.1 + '@types/node': 20.17.50 + chalk: 4.1.2 + ci-info: 4.2.0 + graceful-fs: 4.2.11 + picomatch: 4.0.2 + optional: true + jest-validate@30.0.0: dependencies: '@jest/get-type': 30.0.0 @@ -18845,6 +19220,15 @@ snapshots: merge-stream: 2.0.0 supports-color: 8.1.1 + jest-worker@30.0.2: + dependencies: + '@types/node': 20.17.50 + '@ungap/structured-clone': 1.3.0 + jest-util: 30.0.2 + merge-stream: 2.0.0 + supports-color: 8.1.1 + optional: true + jest@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)): dependencies: '@jest/core': 30.0.0(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)) @@ -18860,6 +19244,8 @@ snapshots: jiti@1.21.6: {} + jiti@1.21.7: {} + jiti@2.4.2: {} joi@17.13.3: @@ -18952,10 +19338,10 @@ snapshots: jsx-ast-utils@3.3.5: dependencies: - array-includes: 3.1.8 - array.prototype.flat: 1.3.2 - object.assign: 4.1.5 - object.values: 1.2.0 + array-includes: 3.1.9 + array.prototype.flat: 1.3.3 + object.assign: 4.1.7 + object.values: 1.2.1 jszip@3.10.1: dependencies: @@ -19652,8 +20038,8 @@ snapshots: micromark-extension-mdxjs@3.0.0: dependencies: - acorn: 8.14.1 - acorn-jsx: 5.3.2(acorn@8.14.1) + acorn: 8.15.0 + acorn-jsx: 5.3.2(acorn@8.15.0) micromark-extension-mdx-expression: 3.0.0 micromark-extension-mdx-jsx: 3.0.1 micromark-extension-mdx-md: 2.0.0 @@ -20024,7 +20410,7 @@ snapshots: nanoid@3.3.11: {} - napi-postinstall@0.2.4: {} + napi-postinstall@0.2.5: {} natural-compare@1.4.0: {} @@ -20159,21 +20545,21 @@ snapshots: normalize-package-data@3.0.3: dependencies: hosted-git-info: 4.1.0 - is-core-module: 2.15.1 + is-core-module: 2.16.1 semver: 7.7.2 validate-npm-package-license: 3.0.4 normalize-package-data@4.0.1: dependencies: hosted-git-info: 5.2.1 - is-core-module: 2.15.1 + is-core-module: 2.16.1 semver: 7.7.2 validate-npm-package-license: 3.0.4 normalize-package-data@5.0.0: dependencies: hosted-git-info: 6.1.3 - is-core-module: 2.15.1 + is-core-module: 2.16.1 semver: 7.7.2 validate-npm-package-license: 3.0.4 @@ -20316,7 +20702,7 @@ snapshots: object-is@1.1.6: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 object-keys@1.1.1: {} @@ -20328,28 +20714,38 @@ snapshots: has-symbols: 1.1.0 object-keys: 1.1.1 + object.assign@4.1.7: + dependencies: + call-bind: 1.0.8 + call-bound: 1.0.4 + define-properties: 1.2.1 + es-object-atoms: 1.1.1 + has-symbols: 1.1.0 + object-keys: 1.1.1 + object.entries@1.1.8: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 es-object-atoms: 1.1.1 object.fromentries@2.0.8: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-object-atoms: 1.1.1 object.groupby@1.0.3: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 - object.values@1.2.0: + object.values@1.2.1: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 define-properties: 1.2.1 es-object-atoms: 1.1.1 @@ -20427,6 +20823,12 @@ snapshots: os-tmpdir@1.0.2: {} + own-keys@1.0.1: + dependencies: + get-intrinsic: 1.3.0 + object-keys: 1.1.1 + safe-push-apply: 1.0.0 + p-cancelable@3.0.0: {} p-defer@1.0.0: {} @@ -20447,7 +20849,7 @@ snapshots: p-limit@4.0.0: dependencies: - yocto-queue: 1.1.1 + yocto-queue: 1.2.1 p-locate@4.1.0: dependencies: @@ -20689,7 +21091,7 @@ snapshots: transitivePeerDependencies: - supports-color - possible-typed-array-names@1.0.0: {} + possible-typed-array-names@1.1.0: {} postcss-attribute-case-insensitive@7.0.1(postcss@8.5.5): dependencies: @@ -20848,22 +21250,30 @@ snapshots: postcss-load-config@4.0.2(postcss@8.5.5)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)): dependencies: lilconfig: 3.1.3 - yaml: 2.6.0 + yaml: 2.8.0 optionalDependencies: postcss: 8.5.5 ts-node: 10.9.2(@types/node@20.17.50)(typescript@5.8.3) + postcss-load-config@4.0.2(postcss@8.5.5)(ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3)): + dependencies: + lilconfig: 3.1.3 + yaml: 2.8.0 + optionalDependencies: + postcss: 8.5.5 + ts-node: 10.9.2(@types/node@24.0.7)(typescript@5.8.3) + postcss-loader@7.3.4(postcss@8.5.5)(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)): dependencies: cosmiconfig: 8.3.6(typescript@5.8.3) - jiti: 1.21.6 + jiti: 1.21.7 postcss: 8.5.5 semver: 7.7.2 webpack: 5.99.9(esbuild@0.25.5) transitivePeerDependencies: - typescript - postcss-loader@8.1.1(postcss@8.5.5)(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + postcss-loader@8.1.1(postcss@8.5.5)(typescript@5.8.3)(webpack@5.99.9): dependencies: cosmiconfig: 9.0.0(typescript@5.8.3) jiti: 1.21.6 @@ -21522,15 +21932,16 @@ snapshots: indent-string: 5.0.0 strip-indent: 4.0.0 - reflect.getprototypeof@1.0.6: + reflect.getprototypeof@1.0.10: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 + es-object-atoms: 1.1.1 get-intrinsic: 1.3.0 - globalthis: 1.0.4 - which-builtin-type: 1.1.4 + get-proto: 1.0.1 + which-builtin-type: 1.2.1 regenerate-unicode-properties@10.2.0: dependencies: @@ -21540,11 +21951,13 @@ snapshots: regexp-tree@0.1.27: {} - regexp.prototype.flags@1.5.3: + regexp.prototype.flags@1.5.4: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 es-errors: 1.3.0 + get-proto: 1.0.1 + gopd: 1.2.0 set-function-name: 2.0.2 regexpu-core@6.2.0: @@ -21689,13 +22102,13 @@ snapshots: resolve@1.22.8: dependencies: - is-core-module: 2.15.1 + is-core-module: 2.16.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 resolve@2.0.0-next.5: dependencies: - is-core-module: 2.15.1 + is-core-module: 2.16.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 @@ -21719,7 +22132,7 @@ snapshots: retry@0.13.1: {} - reusify@1.0.4: {} + reusify@1.1.0: {} rfc4648@1.5.3: {} @@ -21752,9 +22165,14 @@ snapshots: dependencies: tslib: 2.8.1 - safe-array-concat@1.1.2: + rxjs@7.8.2: dependencies: - call-bind: 1.0.7 + tslib: 2.8.1 + + safe-array-concat@1.1.3: + dependencies: + call-bind: 1.0.8 + call-bound: 1.0.4 get-intrinsic: 1.3.0 has-symbols: 1.1.0 isarray: 2.0.5 @@ -21775,11 +22193,16 @@ snapshots: execa: 5.1.1 path-name: 1.0.0 - safe-regex-test@1.0.3: + safe-push-apply@1.0.0: dependencies: - call-bind: 1.0.7 es-errors: 1.3.0 - is-regex: 1.1.4 + isarray: 2.0.5 + + safe-regex-test@1.1.0: + dependencies: + call-bound: 1.0.4 + es-errors: 1.3.0 + is-regex: 1.2.1 safe-stable-stringify@2.5.0: {} @@ -21911,6 +22334,12 @@ snapshots: set-harmonic-interval@1.0.1: {} + set-proto@1.0.0: + dependencies: + dunder-proto: 1.0.1 + es-errors: 1.3.0 + es-object-atoms: 1.1.1 + setimmediate@1.0.5: {} setprototypeof@1.1.0: {} @@ -22184,6 +22613,8 @@ snapshots: stable-hash-x@0.1.1: {} + stable-hash@0.0.5: {} + stack-generator@2.0.10: dependencies: stackframe: 1.3.4 @@ -22220,9 +22651,10 @@ snapshots: stdin-discarder@0.2.2: {} - stop-iteration-iterator@1.0.0: + stop-iteration-iterator@1.1.0: dependencies: - internal-slot: 1.0.7 + es-errors: 1.3.0 + internal-slot: 1.1.0 streamsearch@1.1.0: {} @@ -22251,46 +22683,50 @@ snapshots: string.prototype.includes@2.0.1: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 string.prototype.matchall@4.0.11: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-errors: 1.3.0 es-object-atoms: 1.1.1 get-intrinsic: 1.3.0 gopd: 1.2.0 has-symbols: 1.1.0 - internal-slot: 1.0.7 - regexp.prototype.flags: 1.5.3 + internal-slot: 1.1.0 + regexp.prototype.flags: 1.5.4 set-function-name: 2.0.2 side-channel: 1.1.0 string.prototype.repeat@1.0.0: dependencies: define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 - string.prototype.trim@1.2.9: + string.prototype.trim@1.2.10: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 + define-data-property: 1.1.4 define-properties: 1.2.1 - es-abstract: 1.23.3 + es-abstract: 1.24.0 es-object-atoms: 1.1.1 + has-property-descriptors: 1.0.2 - string.prototype.trimend@1.0.8: + string.prototype.trimend@1.0.9: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 + call-bound: 1.0.4 define-properties: 1.2.1 es-object-atoms: 1.1.1 string.prototype.trimstart@1.0.8: dependencies: - call-bind: 1.0.7 + call-bind: 1.0.8 define-properties: 1.2.1 es-object-atoms: 1.1.1 @@ -22358,7 +22794,7 @@ snapshots: strnum@2.1.1: {} - style-loader@4.0.0(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + style-loader@4.0.0(webpack@5.99.9): dependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) @@ -22457,7 +22893,7 @@ snapshots: fast-glob: 3.3.3 glob-parent: 6.0.2 is-glob: 4.0.3 - jiti: 1.21.6 + jiti: 1.21.7 lilconfig: 3.1.3 micromatch: 4.0.8 normalize-path: 3.0.0 @@ -22474,12 +22910,41 @@ snapshots: transitivePeerDependencies: - ts-node + tailwindcss@3.4.17(ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3)): + dependencies: + '@alloc/quick-lru': 5.2.0 + arg: 5.0.2 + chokidar: 3.6.0 + didyoumean: 1.2.2 + dlv: 1.1.3 + fast-glob: 3.3.3 + glob-parent: 6.0.2 + is-glob: 4.0.3 + jiti: 1.21.7 + lilconfig: 3.1.3 + micromatch: 4.0.8 + normalize-path: 3.0.0 + object-hash: 3.0.0 + picocolors: 1.1.1 + postcss: 8.5.5 + postcss-import: 15.1.0(postcss@8.5.5) + postcss-js: 4.0.1(postcss@8.5.5) + postcss-load-config: 4.0.2(postcss@8.5.5)(ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3)) + postcss-nested: 6.2.0(postcss@8.5.5) + postcss-selector-parser: 6.1.2 + resolve: 1.22.8 + sucrase: 3.35.0 + transitivePeerDependencies: + - ts-node + tailwindcss@4.1.10: {} talon-snippets@1.3.0: {} tapable@2.2.1: {} + tapable@2.2.2: {} + tar@6.2.1: dependencies: chownr: 2.0.0 @@ -22498,32 +22963,32 @@ snapshots: mkdirp: 3.0.1 yallist: 5.0.0 - terser-webpack-plugin@5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + terser-webpack-plugin@5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)): dependencies: '@jridgewell/trace-mapping': 0.3.25 jest-worker: 27.5.1 schema-utils: 4.3.2 serialize-javascript: 6.0.2 terser: 5.35.0 - webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) + webpack: 5.99.9(esbuild@0.25.5) optionalDependencies: esbuild: 0.25.5 - terser-webpack-plugin@5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)): + terser-webpack-plugin@5.3.14(esbuild@0.25.5)(webpack@5.99.9): dependencies: '@jridgewell/trace-mapping': 0.3.25 jest-worker: 27.5.1 schema-utils: 4.3.2 serialize-javascript: 6.0.2 terser: 5.35.0 - webpack: 5.99.9(esbuild@0.25.5) + webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) optionalDependencies: esbuild: 0.25.5 terser@5.35.0: dependencies: '@jridgewell/source-map': 0.3.6 - acorn: 8.14.1 + acorn: 8.15.0 commander: 2.20.3 source-map-support: 0.5.21 @@ -22635,7 +23100,7 @@ snapshots: ts-interface-checker@0.1.13: {} - ts-jest@29.4.0(@babel/core@7.27.4)(@jest/transform@30.0.0)(@jest/types@30.0.0)(babel-jest@30.0.0(@babel/core@7.27.4))(esbuild@0.25.5)(jest-util@30.0.0)(jest@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)))(typescript@5.8.3): + ts-jest@29.4.0(@babel/core@7.27.7)(@jest/transform@30.0.2)(@jest/types@30.0.1)(babel-jest@30.0.2(@babel/core@7.27.7))(esbuild@0.25.5)(jest-util@30.0.2)(jest@30.0.0(@types/node@20.17.50)(ts-node@10.9.2(@types/node@20.17.50)(typescript@5.8.3)))(typescript@5.8.3): dependencies: bs-logger: 0.2.6 ejs: 3.1.10 @@ -22649,14 +23114,14 @@ snapshots: typescript: 5.8.3 yargs-parser: 21.1.1 optionalDependencies: - '@babel/core': 7.27.4 - '@jest/transform': 30.0.0 - '@jest/types': 30.0.0 - babel-jest: 30.0.0(@babel/core@7.27.4) + '@babel/core': 7.27.7 + '@jest/transform': 30.0.2 + '@jest/types': 30.0.1 + babel-jest: 30.0.2(@babel/core@7.27.7) esbuild: 0.25.5 - jest-util: 30.0.0 + jest-util: 30.0.2 - ts-loader@9.5.2(typescript@5.8.3)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + ts-loader@9.5.2(typescript@5.8.3)(webpack@5.99.9): dependencies: chalk: 4.1.2 enhanced-resolve: 5.18.1 @@ -22684,6 +23149,25 @@ snapshots: v8-compile-cache-lib: 3.0.1 yn: 3.1.1 + ts-node@10.9.2(@types/node@24.0.7)(typescript@5.8.3): + dependencies: + '@cspotcode/source-map-support': 0.8.1 + '@tsconfig/node10': 1.0.11 + '@tsconfig/node12': 1.0.11 + '@tsconfig/node14': 1.0.3 + '@tsconfig/node16': 1.0.4 + '@types/node': 24.0.7 + acorn: 8.14.1 + acorn-walk: 8.3.4 + arg: 4.1.3 + create-require: 1.1.1 + diff: 4.0.2 + make-error: 1.3.6 + typescript: 5.8.3 + v8-compile-cache-lib: 3.0.1 + yn: 3.1.1 + optional: true + ts-toolbelt@9.6.0: {} tsconfig-paths@3.15.0: @@ -22732,37 +23216,38 @@ snapshots: media-typer: 0.3.0 mime-types: 2.1.35 - typed-array-buffer@1.0.2: + typed-array-buffer@1.0.3: dependencies: - call-bind: 1.0.7 + call-bound: 1.0.4 es-errors: 1.3.0 - is-typed-array: 1.1.13 + is-typed-array: 1.1.15 - typed-array-byte-length@1.0.1: + typed-array-byte-length@1.0.3: dependencies: - call-bind: 1.0.7 - for-each: 0.3.3 + call-bind: 1.0.8 + for-each: 0.3.5 gopd: 1.2.0 - has-proto: 1.0.3 - is-typed-array: 1.1.13 + has-proto: 1.2.0 + is-typed-array: 1.1.15 - typed-array-byte-offset@1.0.2: + typed-array-byte-offset@1.0.4: dependencies: available-typed-arrays: 1.0.7 - call-bind: 1.0.7 - for-each: 0.3.3 + call-bind: 1.0.8 + for-each: 0.3.5 gopd: 1.2.0 - has-proto: 1.0.3 - is-typed-array: 1.1.13 + has-proto: 1.2.0 + is-typed-array: 1.1.15 + reflect.getprototypeof: 1.0.10 - typed-array-length@1.0.6: + typed-array-length@1.0.7: dependencies: - call-bind: 1.0.7 - for-each: 0.3.3 + call-bind: 1.0.8 + for-each: 0.3.5 gopd: 1.2.0 - has-proto: 1.0.3 - is-typed-array: 1.1.13 - possible-typed-array-names: 1.0.0 + is-typed-array: 1.1.15 + possible-typed-array-names: 1.1.0 + reflect.getprototypeof: 1.0.10 typedarray-to-buffer@3.1.5: dependencies: @@ -22770,15 +23255,18 @@ snapshots: typescript@5.8.3: {} - unbox-primitive@1.0.2: + unbox-primitive@1.1.0: dependencies: - call-bind: 1.0.7 - has-bigints: 1.0.2 + call-bound: 1.0.4 + has-bigints: 1.1.0 has-symbols: 1.1.0 - which-boxed-primitive: 1.0.2 + which-boxed-primitive: 1.1.1 undici-types@6.19.8: {} + undici-types@7.8.0: + optional: true + unicode-canonical-property-names-ecmascript@2.0.1: {} unicode-emoji-modifier-base@1.0.0: {} @@ -22873,29 +23361,29 @@ snapshots: unpipe@1.0.0: {} - unrs-resolver@1.9.0: + unrs-resolver@1.9.2: dependencies: - napi-postinstall: 0.2.4 + napi-postinstall: 0.2.5 optionalDependencies: - '@unrs/resolver-binding-android-arm-eabi': 1.9.0 - '@unrs/resolver-binding-android-arm64': 1.9.0 - '@unrs/resolver-binding-darwin-arm64': 1.9.0 - '@unrs/resolver-binding-darwin-x64': 1.9.0 - '@unrs/resolver-binding-freebsd-x64': 1.9.0 - '@unrs/resolver-binding-linux-arm-gnueabihf': 1.9.0 - '@unrs/resolver-binding-linux-arm-musleabihf': 1.9.0 - '@unrs/resolver-binding-linux-arm64-gnu': 1.9.0 - '@unrs/resolver-binding-linux-arm64-musl': 1.9.0 - '@unrs/resolver-binding-linux-ppc64-gnu': 1.9.0 - '@unrs/resolver-binding-linux-riscv64-gnu': 1.9.0 - '@unrs/resolver-binding-linux-riscv64-musl': 1.9.0 - '@unrs/resolver-binding-linux-s390x-gnu': 1.9.0 - '@unrs/resolver-binding-linux-x64-gnu': 1.9.0 - '@unrs/resolver-binding-linux-x64-musl': 1.9.0 - '@unrs/resolver-binding-wasm32-wasi': 1.9.0 - '@unrs/resolver-binding-win32-arm64-msvc': 1.9.0 - '@unrs/resolver-binding-win32-ia32-msvc': 1.9.0 - '@unrs/resolver-binding-win32-x64-msvc': 1.9.0 + '@unrs/resolver-binding-android-arm-eabi': 1.9.2 + '@unrs/resolver-binding-android-arm64': 1.9.2 + '@unrs/resolver-binding-darwin-arm64': 1.9.2 + '@unrs/resolver-binding-darwin-x64': 1.9.2 + '@unrs/resolver-binding-freebsd-x64': 1.9.2 + '@unrs/resolver-binding-linux-arm-gnueabihf': 1.9.2 + '@unrs/resolver-binding-linux-arm-musleabihf': 1.9.2 + '@unrs/resolver-binding-linux-arm64-gnu': 1.9.2 + '@unrs/resolver-binding-linux-arm64-musl': 1.9.2 + '@unrs/resolver-binding-linux-ppc64-gnu': 1.9.2 + '@unrs/resolver-binding-linux-riscv64-gnu': 1.9.2 + '@unrs/resolver-binding-linux-riscv64-musl': 1.9.2 + '@unrs/resolver-binding-linux-s390x-gnu': 1.9.2 + '@unrs/resolver-binding-linux-x64-gnu': 1.9.2 + '@unrs/resolver-binding-linux-x64-musl': 1.9.2 + '@unrs/resolver-binding-wasm32-wasi': 1.9.2 + '@unrs/resolver-binding-win32-arm64-msvc': 1.9.2 + '@unrs/resolver-binding-win32-ia32-msvc': 1.9.2 + '@unrs/resolver-binding-win32-x64-msvc': 1.9.2 untildify@4.0.0: {} @@ -23037,6 +23525,8 @@ snapshots: web-namespaces@2.0.1: {} + web-tree-sitter@0.25.6: {} + webidl-conversions@3.0.1: {} webidl-conversions@7.0.0: {} @@ -23062,9 +23552,9 @@ snapshots: webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9): dependencies: '@discoveryjs/json-ext': 0.6.3 - '@webpack-cli/configtest': 3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) - '@webpack-cli/info': 3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) - '@webpack-cli/serve': 3.0.1(webpack-cli@6.0.1(webpack-dev-server@5.2.2)(webpack@5.99.9))(webpack-dev-server@5.2.2(webpack-cli@6.0.1)(webpack@5.99.9))(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + '@webpack-cli/configtest': 3.0.1(webpack-cli@6.0.1)(webpack@5.99.9) + '@webpack-cli/info': 3.0.1(webpack-cli@6.0.1)(webpack@5.99.9) + '@webpack-cli/serve': 3.0.1(webpack-cli@6.0.1)(webpack-dev-server@5.2.2)(webpack@5.99.9) colorette: 2.0.20 commander: 12.1.0 cross-spawn: 7.0.6 @@ -23087,7 +23577,7 @@ snapshots: schema-utils: 4.3.2 webpack: 5.99.9(esbuild@0.25.5) - webpack-dev-middleware@7.4.2(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)): + webpack-dev-middleware@7.4.2(webpack@5.99.9): dependencies: colorette: 2.0.20 memfs: 4.17.2 @@ -23166,7 +23656,7 @@ snapshots: serve-index: 1.9.1 sockjs: 0.3.24 spdy: 4.0.2 - webpack-dev-middleware: 7.4.2(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + webpack-dev-middleware: 7.4.2(webpack@5.99.9) ws: 8.18.2 optionalDependencies: webpack: 5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1) @@ -23245,7 +23735,7 @@ snapshots: neo-async: 2.6.2 schema-utils: 4.3.2 tapable: 2.2.1 - terser-webpack-plugin: 5.3.14(esbuild@0.25.5)(webpack@5.99.9(esbuild@0.25.5)(webpack-cli@6.0.1)) + terser-webpack-plugin: 5.3.14(esbuild@0.25.5)(webpack@5.99.9) watchpack: 2.4.2 webpack-sources: 3.2.3 optionalDependencies: @@ -23295,28 +23785,29 @@ snapshots: tr46: 0.0.3 webidl-conversions: 3.0.1 - which-boxed-primitive@1.0.2: + which-boxed-primitive@1.1.1: dependencies: - is-bigint: 1.0.4 - is-boolean-object: 1.1.2 - is-number-object: 1.0.7 - is-string: 1.0.7 - is-symbol: 1.0.4 + is-bigint: 1.1.0 + is-boolean-object: 1.2.2 + is-number-object: 1.1.1 + is-string: 1.1.1 + is-symbol: 1.1.1 - which-builtin-type@1.1.4: + which-builtin-type@1.2.1: dependencies: - function.prototype.name: 1.1.6 + call-bound: 1.0.4 + function.prototype.name: 1.1.8 has-tostringtag: 1.0.2 - is-async-function: 2.0.0 - is-date-object: 1.0.5 - is-finalizationregistry: 1.0.2 - is-generator-function: 1.0.10 - is-regex: 1.1.4 - is-weakref: 1.0.2 + is-async-function: 2.1.1 + is-date-object: 1.1.0 + is-finalizationregistry: 1.1.1 + is-generator-function: 1.1.0 + is-regex: 1.2.1 + is-weakref: 1.1.1 isarray: 2.0.5 - which-boxed-primitive: 1.0.2 + which-boxed-primitive: 1.1.1 which-collection: 1.0.2 - which-typed-array: 1.1.15 + which-typed-array: 1.1.19 which-collection@1.0.2: dependencies: @@ -23330,11 +23821,13 @@ snapshots: load-yaml-file: 0.2.0 path-exists: 4.0.0 - which-typed-array@1.1.15: + which-typed-array@1.1.19: dependencies: available-typed-arrays: 1.0.7 - call-bind: 1.0.7 - for-each: 0.3.3 + call-bind: 1.0.8 + call-bound: 1.0.4 + for-each: 0.3.5 + get-proto: 1.0.1 gopd: 1.2.0 has-tostringtag: 1.0.2 @@ -23455,7 +23948,7 @@ snapshots: yallist@5.0.0: {} - yaml@2.6.0: {} + yaml@2.8.0: {} yargs-parser@21.1.1: {} @@ -23548,7 +24041,7 @@ snapshots: yocto-queue@0.1.0: {} - yocto-queue@1.1.1: {} + yocto-queue@1.2.1: {} zod@3.25.64: {} From cc09d286ae11f0c4cce14642c3b3af3f79f3109f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Sun, 29 Jun 2025 00:04:31 +0200 Subject: [PATCH 37/39] esbuild fixes --- packages/cursorless-jetbrains/package.json | 2 +- packages/cursorless-jetbrains/src/extension.ts | 2 +- packages/cursorless-jetbrains/src/{ => types}/globals.d.ts | 0 3 files changed, 2 insertions(+), 2 deletions(-) rename packages/cursorless-jetbrains/src/{ => types}/globals.d.ts (100%) diff --git a/packages/cursorless-jetbrains/package.json b/packages/cursorless-jetbrains/package.json index 02a17ec58d..57b4249d52 100644 --- a/packages/cursorless-jetbrains/package.json +++ b/packages/cursorless-jetbrains/package.json @@ -8,7 +8,7 @@ "scripts": { "build": "pnpm run esbuild:prod && pnpm run populate-dist", "compile": "tsc --build", - "esbuild:base": "esbuild ./src/index.ts --format=esm --target=es2020 --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=neutral --external:std --external:fs --external:path", + "esbuild:base": "esbuild ./src/index.ts --format=esm --target=es2020 --conditions=cursorless:bundler --bundle --main-fields=main,module --outfile=./out/cursorless.js --platform=neutral --external:std --external:module --external:fs --external:path", "esbuild": "pnpm run esbuild:base --sourcemap", "esbuild:prod": "pnpm run esbuild:base --minify", "populate-dist": "bash ./scripts/populate-dist.sh", diff --git a/packages/cursorless-jetbrains/src/extension.ts b/packages/cursorless-jetbrains/src/extension.ts index 9aef71a172..d96aef9496 100644 --- a/packages/cursorless-jetbrains/src/extension.ts +++ b/packages/cursorless-jetbrains/src/extension.ts @@ -2,7 +2,7 @@ import type { CursorlessEngine } from "@cursorless/cursorless-engine"; import { createCursorlessEngine } from "@cursorless/cursorless-engine"; import type { JetbrainsPlugin } from "./ide/JetbrainsPlugin"; import { Parser } from "web-tree-sitter"; -import "./globals"; +import "./types/globals.d.ts"; import { JetbrainsTreeSitter } from "./ide/JetbrainsTreeSitter"; import { JetbrainsTreeSitterQueryProvider } from "./ide/JetbrainsTreeSitterQueryProvider"; import { pathJoin } from "./ide/pathJoin"; diff --git a/packages/cursorless-jetbrains/src/globals.d.ts b/packages/cursorless-jetbrains/src/types/globals.d.ts similarity index 100% rename from packages/cursorless-jetbrains/src/globals.d.ts rename to packages/cursorless-jetbrains/src/types/globals.d.ts From 913df77ef6799a99f9025d1b5228b1f208051dc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 31 Jul 2025 07:18:19 +0200 Subject: [PATCH 38/39] support selecting in readonly documents --- .../cursorless-jetbrains/src/ide/JetbrainsEditor.ts | 4 ++++ packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts | 1 + .../cursorless-jetbrains/src/ide/createTextEditor.ts | 10 +++++++++- packages/cursorless-jetbrains/src/types/types.ts | 1 + 4 files changed, 15 insertions(+), 1 deletion(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts index ab6c0cbb11..47d9aa3fdb 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsEditor.ts @@ -27,6 +27,7 @@ export class JetbrainsEditor implements EditableTextEditor { isActive = true; isVisible = true; isEditable = true; + isWritable = true; constructor( private client: JetbrainsClient, @@ -54,6 +55,9 @@ export class JetbrainsEditor implements EditableTextEditor { edit(edits: Edit[]): Promise { // console.log("editor.edit"); + if (!this.isWritable) { + return Promise.resolve(false); + } jetbrainsPerformEdits(this.client, this.ide, this.document, this.id, edits); return Promise.resolve(true); } diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts index 2bcf2936a2..642b6d6f33 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsIDE.ts @@ -311,6 +311,7 @@ function updateEditor(editor: JetbrainsEditor, editorState: EditorState) { editor.isActive = editorState.active; editor.isVisible = editorState.visible; editor.isEditable = editorState.editable; + editor.isWritable = editorState.writable; } function getLines(text: string, firstLine: number, lastLine: number) { diff --git a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts index ea6292d763..1426503305 100644 --- a/packages/cursorless-jetbrains/src/ide/createTextEditor.ts +++ b/packages/cursorless-jetbrains/src/ide/createTextEditor.ts @@ -29,7 +29,7 @@ export function createTextEditor( createSelection(document, selection), ); - return new JetbrainsEditor( + const editor = new JetbrainsEditor( client, ide, id, @@ -37,6 +37,14 @@ export function createTextEditor( visibleRanges, selections, ); + + // Set editor properties based on editor state + editor.isActive = editorState.active; + editor.isVisible = editorState.visible; + editor.isEditable = editorState.editable; + editor.isWritable = editorState.writable; + + return editor; } export function createSelection( diff --git a/packages/cursorless-jetbrains/src/types/types.ts b/packages/cursorless-jetbrains/src/types/types.ts index b8a4ba44fe..0208f7e7d3 100644 --- a/packages/cursorless-jetbrains/src/types/types.ts +++ b/packages/cursorless-jetbrains/src/types/types.ts @@ -27,6 +27,7 @@ export interface EditorState { active: boolean; visible: boolean; editable: boolean; + writable: boolean; } export interface EditorChange { From 403849ba38b71c123dbad0c4beb54bb179ed1589 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20S=C3=B8e?= Date: Thu, 31 Jul 2025 08:21:54 +0200 Subject: [PATCH 39/39] use new Query contructor for treesitter --- packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts index 83d8b4cdbb..2114efed43 100644 --- a/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts +++ b/packages/cursorless-jetbrains/src/ide/JetbrainsTreeSitter.ts @@ -1,5 +1,6 @@ import type { Range, TextDocument, TreeSitter } from "@cursorless/common"; -import type { Language, Query, Node, Tree } from "web-tree-sitter"; +import type { Language, Node, Tree } from "web-tree-sitter"; +import { Query } from "web-tree-sitter"; import { Parser, Language as ParserLanguage } from "web-tree-sitter"; import { pathJoin } from "./pathJoin"; @@ -65,7 +66,7 @@ export class JetbrainsTreeSitter implements TreeSitter { } try { - return language.query(source); + return new Query(language, source); } catch (error) { console.error(`Failed to create query for language ${languageId}:`, error); return undefined;