@kilocode/plugin 7.3.21 → 7.3.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/tui.d.ts CHANGED
@@ -1,8 +1,15 @@
1
1
  import type { AgentPart, KiloClient, Event, FilePart, LspStatus, McpStatus, Todo, Message, Part, Provider, PermissionRequest, QuestionRequest, SessionStatus, BackgroundProcessInfo, TextPart, Config as SdkConfig } from "@kilocode/sdk/v2";
2
- import type { CliRenderer, ParsedKey, RGBA, SlotMode } from "@opentui/core";
2
+ import type { CliRenderer, KeyEvent, RGBA, Renderable, SlotMode } from "@opentui/core";
3
+ import type { Binding, Keymap } from "@opentui/keymap";
4
+ import { type BindingConfig, type CreateBindingLookupOptions, type KeySequenceFormatPart, type SequenceBindingLike } from "@opentui/keymap/extras";
3
5
  import type { JSX, SolidPlugin } from "@opentui/solid";
4
6
  import type { Config as PluginConfig, PluginOptions } from "./index.js";
5
- export type { CliRenderer, SlotMode } from "@opentui/core";
7
+ export type { CliRenderer, KeyEvent, Renderable, SlotMode } from "@opentui/core";
8
+ export { stringifyKeySequence, stringifyKeyStroke } from "@opentui/keymap";
9
+ export type { Binding, KeyLike, KeySequencePart, KeyStringifyInput, StringifyOptions } from "@opentui/keymap";
10
+ export { formatCommandBindings, formatKeySequence } from "@opentui/keymap/extras";
11
+ export type { BindingConfig, BindingLookup, BindingValue, CreateBindingLookupOptions, FormatCommandBindingsOptions, FormatKeySequenceOptions, KeySequenceFormatPart, SequenceBindingLike, } from "@opentui/keymap/extras";
12
+ export declare function createBindingLookup(config: BindingConfig<Renderable, KeyEvent> | undefined, options?: CreateBindingLookupOptions<Renderable, KeyEvent>): import("@opentui/keymap/extras").BindingLookup<Renderable, KeyEvent>;
6
13
  export type TuiRouteCurrent = {
7
14
  name: "home";
8
15
  } | {
@@ -21,36 +28,11 @@ export type TuiRouteDefinition = {
21
28
  params?: Record<string, unknown>;
22
29
  }) => JSX.Element;
23
30
  };
24
- export type TuiCommand = {
25
- title: string;
26
- value: string;
27
- description?: string;
28
- category?: string;
29
- keybind?: string;
30
- suggested?: boolean;
31
- hidden?: boolean;
32
- enabled?: boolean;
33
- slash?: {
34
- name: string;
35
- aliases?: string[];
36
- };
37
- onSelect?: () => void;
38
- };
39
- export type TuiKeybind = {
40
- name: string;
41
- ctrl: boolean;
42
- meta: boolean;
43
- shift: boolean;
44
- super?: boolean;
45
- leader: boolean;
46
- };
47
- export type TuiKeybindMap = Record<string, string>;
48
- export type TuiKeybindSet = {
49
- readonly all: TuiKeybindMap;
50
- get: (name: string) => string;
51
- match: (name: string, evt: ParsedKey) => boolean;
52
- print: (name: string) => string;
31
+ export type TuiKeys = {
32
+ formatSequence: (parts: readonly KeySequenceFormatPart[] | undefined) => string;
33
+ formatBindings: (bindings: readonly SequenceBindingLike[] | undefined) => string | undefined;
53
34
  };
35
+ export type TuiKeymap = Keymap<Renderable, KeyEvent>;
54
36
  export type TuiDialogProps = {
55
37
  size?: "medium" | "large" | "xlarge";
56
38
  onClose: () => void;
@@ -244,8 +226,18 @@ export type TuiState = {
244
226
  lsp: () => ReadonlyArray<TuiSidebarLspItem>;
245
227
  mcp: () => ReadonlyArray<TuiSidebarMcpItem>;
246
228
  };
247
- type TuiConfigView = Pick<PluginConfig, "$schema" | "theme" | "keybinds" | "plugin"> & NonNullable<PluginConfig["tui"]> & {
229
+ type TuiBindingLookupView = {
230
+ readonly bindings: ReadonlyArray<Binding<Renderable, KeyEvent>>;
231
+ get: (command: string) => ReadonlyArray<Binding<Renderable, KeyEvent>>;
232
+ has: (command: string) => boolean;
233
+ gather: (name: string, commands: readonly string[]) => ReadonlyArray<Binding<Renderable, KeyEvent>>;
234
+ pick: (name: string, commands: readonly string[]) => Binding<Renderable, KeyEvent>[];
235
+ omit: (name: string, commands: readonly string[]) => Binding<Renderable, KeyEvent>[];
236
+ };
237
+ type TuiConfigView = Pick<PluginConfig, "$schema" | "theme" | "plugin"> & NonNullable<PluginConfig["tui"]> & {
238
+ leader_timeout: number;
248
239
  plugin_enabled?: Record<string, boolean>;
240
+ keybinds: TuiBindingLookupView;
249
241
  };
250
242
  export type TuiApp = {
251
243
  readonly version: string;
@@ -268,6 +260,7 @@ export type TuiSidebarFileItem = {
268
260
  };
269
261
  export type TuiHostSlotMap = {
270
262
  app: {};
263
+ app_bottom: {};
271
264
  home_logo: {};
272
265
  home_prompt: {
273
266
  workspace_id?: string;
@@ -374,11 +367,8 @@ export type TuiWorkspace = {
374
367
  };
375
368
  export type TuiPluginApi = {
376
369
  app: TuiApp;
377
- command: {
378
- register: (cb: () => TuiCommand[]) => () => void;
379
- trigger: (value: string) => void;
380
- show: () => void;
381
- };
370
+ keys: TuiKeys;
371
+ keymap: TuiKeymap;
382
372
  route: {
383
373
  register: (routes: TuiRouteDefinition[]) => () => void;
384
374
  navigate: (name: string, params?: Record<string, unknown>) => void;
@@ -395,11 +385,6 @@ export type TuiPluginApi = {
395
385
  toast: (input: TuiToast) => void;
396
386
  dialog: TuiDialogStack;
397
387
  };
398
- keybind: {
399
- match: (key: string, evt: ParsedKey) => boolean;
400
- print: (key: string) => string;
401
- create: (defaults: TuiKeybindMap, overrides?: Record<string, unknown>) => TuiKeybindSet;
402
- };
403
388
  readonly tuiConfig: Frozen<TuiConfigView>;
404
389
  kv: TuiKV;
405
390
  state: TuiState;
package/dist/tui.js CHANGED
@@ -1 +1,6 @@
1
- export {};
1
+ import { createBindingLookup as createKeymapBindingLookup, } from "@opentui/keymap/extras";
2
+ export { stringifyKeySequence, stringifyKeyStroke } from "@opentui/keymap";
3
+ export { formatCommandBindings, formatKeySequence } from "@opentui/keymap/extras";
4
+ export function createBindingLookup(config, options) {
5
+ return createKeymapBindingLookup(config ?? {}, options);
6
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@kilocode/plugin",
4
- "version": "7.3.21",
4
+ "version": "7.3.22",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "scripts": {
@@ -26,29 +26,34 @@
26
26
  "dist"
27
27
  ],
28
28
  "dependencies": {
29
- "@kilocode/sdk": "7.3.21",
29
+ "@kilocode/sdk": "7.3.22",
30
30
  "effect": "4.0.0-beta.59",
31
31
  "zod": "4.1.8"
32
32
  },
33
33
  "peerDependencies": {
34
- "@opentui/core": ">=0.2.2",
35
- "@opentui/solid": ">=0.2.2"
34
+ "@opentui/core": ">=0.2.6",
35
+ "@opentui/solid": ">=0.2.6",
36
+ "@opentui/keymap": ">=0.2.6"
36
37
  },
37
38
  "peerDependenciesMeta": {
38
39
  "@opentui/core": {
39
40
  "optional": true
40
41
  },
42
+ "@opentui/keymap": {
43
+ "optional": true
44
+ },
41
45
  "@opentui/solid": {
42
46
  "optional": true
43
47
  }
44
48
  },
45
49
  "devDependencies": {
46
- "@opentui/core": "0.2.2",
47
- "@opentui/solid": "0.2.2",
50
+ "@opentui/core": "0.2.6",
51
+ "@opentui/solid": "0.2.6",
48
52
  "@tsconfig/node22": "22.0.2",
49
53
  "@types/node": "24.12.2",
50
54
  "typescript": "5.8.2",
51
- "@typescript/native-preview": "7.0.0-dev.20260316.1"
55
+ "@typescript/native-preview": "7.0.0-dev.20260316.1",
56
+ "@opentui/keymap": "0.2.6"
52
57
  },
53
58
  "repository": {
54
59
  "type": "git",