@get-bb/plugin-sdk 0.4.21 → 0.4.24
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/bundled-types/bb-plugin-sdk-app.d.ts +63 -9
- package/bundled-types/bb-plugin-sdk-provider-bridge-testing.d.ts +2 -2
- package/bundled-types/bb-plugin-sdk-testing-app.d.ts +6 -1
- package/bundled-types/bb-plugin-sdk.d.ts +61 -8
- package/dist/app.js +2 -0
- package/dist/provider-bridge-acp.js +41 -8
- package/dist/provider-bridge-testing.js +1 -2
- package/dist/testing/app.js +10 -1
- package/package.json +1 -1
|
@@ -410,15 +410,14 @@ interface PluginThreadListProps {
|
|
|
410
410
|
/** True on phone-width viewports and coarse pointers. */
|
|
411
411
|
isCompactViewport: boolean;
|
|
412
412
|
/**
|
|
413
|
-
* Call after the user opens a thread. It closes the mobile sidebar drawer
|
|
414
|
-
* and it clears the host search field on every viewport. Always call it, or
|
|
415
|
-
* the sidebar stays in search mode after the thread opens.
|
|
413
|
+
* Call after the user opens a thread. It closes the mobile sidebar drawer.
|
|
416
414
|
*/
|
|
417
415
|
onNavigate: () => void;
|
|
418
416
|
/**
|
|
419
|
-
*
|
|
420
|
-
*
|
|
421
|
-
*
|
|
417
|
+
* Compatibility value for the former sidebar search field. BB now searches
|
|
418
|
+
* threads in the quick palette, so the host always supplies "".
|
|
419
|
+
*
|
|
420
|
+
* @deprecated The quick palette owns thread search. Ignore this value.
|
|
422
421
|
*/
|
|
423
422
|
searchQuery: string;
|
|
424
423
|
/**
|
|
@@ -999,6 +998,53 @@ interface PluginProvidersState {
|
|
|
999
998
|
status: "error" | "loading" | "ready";
|
|
1000
999
|
providers: readonly ProviderInfo[];
|
|
1001
1000
|
}
|
|
1001
|
+
/**
|
|
1002
|
+
* One TextMate token rule from the active code theme, in the shape VS Code
|
|
1003
|
+
* theme files author it.
|
|
1004
|
+
*/
|
|
1005
|
+
interface PluginCodeThemeTokenRule {
|
|
1006
|
+
/** Scope(s) the rule paints; absent means the theme's base rule. */
|
|
1007
|
+
scope?: string | readonly string[];
|
|
1008
|
+
settings: {
|
|
1009
|
+
/** `#rrggbb` or `#rrggbbaa`. */
|
|
1010
|
+
foreground?: string;
|
|
1011
|
+
background?: string;
|
|
1012
|
+
/** Space-separated TextMate font styles, e.g. `"bold italic"`. */
|
|
1013
|
+
fontStyle?: string;
|
|
1014
|
+
};
|
|
1015
|
+
}
|
|
1016
|
+
/**
|
|
1017
|
+
* The active code theme as a VS Code theme file: the same document BB's own
|
|
1018
|
+
* highlighter renders from, so a plugin that embeds a third-party editor can
|
|
1019
|
+
* translate it into that editor's theme format rather than guessing colors
|
|
1020
|
+
* from CSS variables.
|
|
1021
|
+
*/
|
|
1022
|
+
interface PluginCodeThemeData {
|
|
1023
|
+
/** Registered theme name — a bundled Shiki name or a BB-registered id. */
|
|
1024
|
+
name: string;
|
|
1025
|
+
type: "dark" | "light";
|
|
1026
|
+
/** Default editor foreground, as `#rrggbb[aa]`. */
|
|
1027
|
+
fg: string;
|
|
1028
|
+
/** Default editor background, as `#rrggbb[aa]`. */
|
|
1029
|
+
bg: string;
|
|
1030
|
+
/** VS Code workbench colors (`editor.background`, `editorCursor.foreground`, …). */
|
|
1031
|
+
colors: Readonly<Record<string, string>>;
|
|
1032
|
+
tokenColors: readonly PluginCodeThemeTokenRule[];
|
|
1033
|
+
}
|
|
1034
|
+
/**
|
|
1035
|
+
* The code theme BB is currently rendering with (see
|
|
1036
|
+
* {@link PluginSdkApp.experimental_useCodeTheme}). `mode` and `name` change
|
|
1037
|
+
* the moment the user switches palette or light/dark; `theme` follows once
|
|
1038
|
+
* the theme file resolves, and keeps the previous document until then so a
|
|
1039
|
+
* consumer never has to paint an unthemed frame. Compare `theme.name` with
|
|
1040
|
+
* `name` to tell a settled state from one still resolving.
|
|
1041
|
+
*/
|
|
1042
|
+
interface PluginCodeThemeState {
|
|
1043
|
+
mode: "dark" | "light";
|
|
1044
|
+
name: string;
|
|
1045
|
+
/** null only before the first theme file resolves. */
|
|
1046
|
+
theme: PluginCodeThemeData | null;
|
|
1047
|
+
}
|
|
1002
1048
|
/**
|
|
1003
1049
|
* Act on threads from a plugin surface. Every method routes to the host's own
|
|
1004
1050
|
* flow, so optimistic updates, toasts, dialogs, pane closing, and route repair
|
|
@@ -1116,7 +1162,7 @@ interface PluginSidebarThreadSplit {
|
|
|
1116
1162
|
* leaving the user with no sidebar.
|
|
1117
1163
|
*
|
|
1118
1164
|
* The plugin gets the scrolling list and nothing else. The New-thread button,
|
|
1119
|
-
* the search
|
|
1165
|
+
* the search action, the plugin nav rows, and the footer stay host-rendered in
|
|
1120
1166
|
* every sidebar — they are shared surfaces (other plugins live in two of
|
|
1121
1167
|
* them), and a replaced list must not be able to remove them.
|
|
1122
1168
|
*/
|
|
@@ -2183,6 +2229,13 @@ interface PluginSdkApp {
|
|
|
2183
2229
|
* see docs/api_to_audit.md.
|
|
2184
2230
|
*/
|
|
2185
2231
|
experimental_useProviders(): PluginProvidersState;
|
|
2232
|
+
/**
|
|
2233
|
+
* The active code theme as a VS Code theme file (see
|
|
2234
|
+
* {@link PluginCodeThemeState}), for a plugin that renders code with an
|
|
2235
|
+
* engine of its own and needs BB's palette to reach it. Experimental: see
|
|
2236
|
+
* docs/api_to_audit.md.
|
|
2237
|
+
*/
|
|
2238
|
+
experimental_useCodeTheme(): PluginCodeThemeState;
|
|
2186
2239
|
/**
|
|
2187
2240
|
* The host-owned chat component (see {@link ThreadChatProps}). Together
|
|
2188
2241
|
* with `Markdown`, the only components the SDK ships — everything else
|
|
@@ -2264,6 +2317,7 @@ declare const experimental_useSidebarThreadActions: () => PluginSidebarThreadAct
|
|
|
2264
2317
|
declare const experimental_useSidebarThreadPullRequest: (threadId: string) => PluginSidebarThreadPullRequestState;
|
|
2265
2318
|
declare const experimental_useSidebarThreadSplit: (threadId: string) => PluginSidebarThreadSplit;
|
|
2266
2319
|
declare const experimental_useProviders: () => PluginProvidersState;
|
|
2320
|
+
declare const experimental_useCodeTheme: () => PluginCodeThemeState;
|
|
2267
2321
|
|
|
2268
|
-
export { Markdown, ThreadChat, UrlLink, definePluginApp, experimental_Diff, experimental_FileLink, experimental_NewThreadComposer, experimental_PermissionModePicker, experimental_ProviderModelPicker, experimental_SourceCode, experimental_useAppPanel, experimental_useFixedTabTarget, experimental_useProviders, experimental_useSidebarThreadActions, experimental_useSidebarThreadPullRequest, experimental_useSidebarThreadSplit, experimental_useSidebarThreads, useBbContext, useBbNavigate, useComposer, useComposerView, useRealtime, useRealtimeConnectionState, useRpc, useSettings };
|
|
2269
|
-
export type { BbContext, BbNavigate, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderIconRegistration, PluginProvidersState, PluginRealtimeConnectionState, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginTargetedPanelActionOpenOptions, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
|
2322
|
+
export { Markdown, ThreadChat, UrlLink, definePluginApp, experimental_Diff, experimental_FileLink, experimental_NewThreadComposer, experimental_PermissionModePicker, experimental_ProviderModelPicker, experimental_SourceCode, experimental_useAppPanel, experimental_useCodeTheme, experimental_useFixedTabTarget, experimental_useProviders, experimental_useSidebarThreadActions, experimental_useSidebarThreadPullRequest, experimental_useSidebarThreadSplit, experimental_useSidebarThreads, useBbContext, useBbNavigate, useComposer, useComposerView, useRealtime, useRealtimeConnectionState, useRpc, useSettings };
|
|
2323
|
+
export type { BbContext, BbNavigate, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginCodeThemeData, PluginCodeThemeState, PluginCodeThemeTokenRule, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderIconRegistration, PluginProvidersState, PluginRealtimeConnectionState, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginTargetedPanelActionOpenOptions, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
|
@@ -4716,8 +4716,8 @@ interface ReplayRecordingOptions {
|
|
|
4716
4716
|
*/
|
|
4717
4717
|
orderTimeoutMs?: number;
|
|
4718
4718
|
/**
|
|
4719
|
-
* Quiet period after the last
|
|
4720
|
-
* An exact current-lane replay waits for every planned event
|
|
4719
|
+
* Quiet period after the last bridge output before the replay is closed.
|
|
4720
|
+
* An exact current-lane replay first waits for every planned event.
|
|
4721
4721
|
*/
|
|
4722
4722
|
settleMs?: number;
|
|
4723
4723
|
/**
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { ReactNode, ComponentType } from 'react';
|
|
9
9
|
import { RenderResult } from '@testing-library/react';
|
|
10
|
-
import { PluginHomepageSectionRegistration, PluginSettingsSectionRegistration, PluginNavPanelRegistration, PluginThreadPanelActionRegistration, PluginNewThreadPanelActionRegistration, ComposerCustomization, PluginPendingInteractionRegistration, PluginSidebarFooterActionRegistration, PluginThreadListRegistration, PluginThreadHeaderActionRegistration, PluginFileOpenerRegistration, PluginSourceCodeRendererRegistration, PluginDiffRendererRegistration, PluginMessageDirectiveRegistration, PluginMessageActionRegistration, PluginProviderIconRegistration, PluginTimelineRendererRegistration, PluginContentScriptRegistration, PluginComposerScope, PluginComposerTextEffect, PluginComposerMention, PluginComposerThreadRowStatus, ExperimentalOpenFixedTabOptions, JsonValue, BbNavigate, ExperimentalFileOpenOptions, PluginAppDefinition, PluginRpcContract, StandardSchemaV1InferInput, PluginRpcResult, PluginRealtimeConnectionState, PluginSidebarThreadsState, PluginProvidersState, PluginSidebarPullRequest, PluginSidebarThreadActions } from '@get-bb/plugin-sdk';
|
|
10
|
+
import { PluginHomepageSectionRegistration, PluginSettingsSectionRegistration, PluginNavPanelRegistration, PluginThreadPanelActionRegistration, PluginNewThreadPanelActionRegistration, ComposerCustomization, PluginPendingInteractionRegistration, PluginSidebarFooterActionRegistration, PluginThreadListRegistration, PluginThreadHeaderActionRegistration, PluginFileOpenerRegistration, PluginSourceCodeRendererRegistration, PluginDiffRendererRegistration, PluginMessageDirectiveRegistration, PluginMessageActionRegistration, PluginProviderIconRegistration, PluginTimelineRendererRegistration, PluginContentScriptRegistration, PluginComposerScope, PluginComposerTextEffect, PluginComposerMention, PluginComposerThreadRowStatus, ExperimentalOpenFixedTabOptions, JsonValue, BbNavigate, ExperimentalFileOpenOptions, PluginAppDefinition, PluginRpcContract, StandardSchemaV1InferInput, PluginRpcResult, PluginRealtimeConnectionState, PluginSidebarThreadsState, PluginProvidersState, PluginCodeThemeState, PluginSidebarPullRequest, PluginSidebarThreadActions } from '@get-bb/plugin-sdk';
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* `@get-bb/plugin-sdk/testing/app` — the frontend plugin test harness. Tests a
|
|
@@ -207,6 +207,11 @@ interface RenderSlotOptions<Contract extends PluginRpcContract = PluginRpcContra
|
|
|
207
207
|
* a ready, empty list. Pass `{ status: "loading" }` to test that branch.
|
|
208
208
|
*/
|
|
209
209
|
providers?: Partial<PluginProvidersState>;
|
|
210
|
+
/**
|
|
211
|
+
* The code theme `experimental_useCodeTheme()` reports. Omitted → a light
|
|
212
|
+
* mode with no resolved document, the state a plugin sees on first paint.
|
|
213
|
+
*/
|
|
214
|
+
codeTheme?: Partial<PluginCodeThemeState>;
|
|
210
215
|
/**
|
|
211
216
|
* Pull requests `experimental_useSidebarThreadPullRequest()` reports, keyed
|
|
212
217
|
* by thread id. Omitted → every thread reports none.
|
|
@@ -12351,15 +12351,14 @@ interface PluginThreadListProps {
|
|
|
12351
12351
|
/** True on phone-width viewports and coarse pointers. */
|
|
12352
12352
|
isCompactViewport: boolean;
|
|
12353
12353
|
/**
|
|
12354
|
-
* Call after the user opens a thread. It closes the mobile sidebar drawer
|
|
12355
|
-
* and it clears the host search field on every viewport. Always call it, or
|
|
12356
|
-
* the sidebar stays in search mode after the thread opens.
|
|
12354
|
+
* Call after the user opens a thread. It closes the mobile sidebar drawer.
|
|
12357
12355
|
*/
|
|
12358
12356
|
onNavigate: () => void;
|
|
12359
12357
|
/**
|
|
12360
|
-
*
|
|
12361
|
-
*
|
|
12362
|
-
*
|
|
12358
|
+
* Compatibility value for the former sidebar search field. BB now searches
|
|
12359
|
+
* threads in the quick palette, so the host always supplies "".
|
|
12360
|
+
*
|
|
12361
|
+
* @deprecated The quick palette owns thread search. Ignore this value.
|
|
12363
12362
|
*/
|
|
12364
12363
|
searchQuery: string;
|
|
12365
12364
|
/**
|
|
@@ -12940,6 +12939,53 @@ interface PluginProvidersState {
|
|
|
12940
12939
|
status: "error" | "loading" | "ready";
|
|
12941
12940
|
providers: readonly ProviderInfo[];
|
|
12942
12941
|
}
|
|
12942
|
+
/**
|
|
12943
|
+
* One TextMate token rule from the active code theme, in the shape VS Code
|
|
12944
|
+
* theme files author it.
|
|
12945
|
+
*/
|
|
12946
|
+
interface PluginCodeThemeTokenRule {
|
|
12947
|
+
/** Scope(s) the rule paints; absent means the theme's base rule. */
|
|
12948
|
+
scope?: string | readonly string[];
|
|
12949
|
+
settings: {
|
|
12950
|
+
/** `#rrggbb` or `#rrggbbaa`. */
|
|
12951
|
+
foreground?: string;
|
|
12952
|
+
background?: string;
|
|
12953
|
+
/** Space-separated TextMate font styles, e.g. `"bold italic"`. */
|
|
12954
|
+
fontStyle?: string;
|
|
12955
|
+
};
|
|
12956
|
+
}
|
|
12957
|
+
/**
|
|
12958
|
+
* The active code theme as a VS Code theme file: the same document BB's own
|
|
12959
|
+
* highlighter renders from, so a plugin that embeds a third-party editor can
|
|
12960
|
+
* translate it into that editor's theme format rather than guessing colors
|
|
12961
|
+
* from CSS variables.
|
|
12962
|
+
*/
|
|
12963
|
+
interface PluginCodeThemeData {
|
|
12964
|
+
/** Registered theme name — a bundled Shiki name or a BB-registered id. */
|
|
12965
|
+
name: string;
|
|
12966
|
+
type: "dark" | "light";
|
|
12967
|
+
/** Default editor foreground, as `#rrggbb[aa]`. */
|
|
12968
|
+
fg: string;
|
|
12969
|
+
/** Default editor background, as `#rrggbb[aa]`. */
|
|
12970
|
+
bg: string;
|
|
12971
|
+
/** VS Code workbench colors (`editor.background`, `editorCursor.foreground`, …). */
|
|
12972
|
+
colors: Readonly<Record<string, string>>;
|
|
12973
|
+
tokenColors: readonly PluginCodeThemeTokenRule[];
|
|
12974
|
+
}
|
|
12975
|
+
/**
|
|
12976
|
+
* The code theme BB is currently rendering with (see
|
|
12977
|
+
* {@link PluginSdkApp.experimental_useCodeTheme}). `mode` and `name` change
|
|
12978
|
+
* the moment the user switches palette or light/dark; `theme` follows once
|
|
12979
|
+
* the theme file resolves, and keeps the previous document until then so a
|
|
12980
|
+
* consumer never has to paint an unthemed frame. Compare `theme.name` with
|
|
12981
|
+
* `name` to tell a settled state from one still resolving.
|
|
12982
|
+
*/
|
|
12983
|
+
interface PluginCodeThemeState {
|
|
12984
|
+
mode: "dark" | "light";
|
|
12985
|
+
name: string;
|
|
12986
|
+
/** null only before the first theme file resolves. */
|
|
12987
|
+
theme: PluginCodeThemeData | null;
|
|
12988
|
+
}
|
|
12943
12989
|
/**
|
|
12944
12990
|
* Act on threads from a plugin surface. Every method routes to the host's own
|
|
12945
12991
|
* flow, so optimistic updates, toasts, dialogs, pane closing, and route repair
|
|
@@ -13057,7 +13103,7 @@ interface PluginSidebarThreadSplit {
|
|
|
13057
13103
|
* leaving the user with no sidebar.
|
|
13058
13104
|
*
|
|
13059
13105
|
* The plugin gets the scrolling list and nothing else. The New-thread button,
|
|
13060
|
-
* the search
|
|
13106
|
+
* the search action, the plugin nav rows, and the footer stay host-rendered in
|
|
13061
13107
|
* every sidebar — they are shared surfaces (other plugins live in two of
|
|
13062
13108
|
* them), and a replaced list must not be able to remove them.
|
|
13063
13109
|
*/
|
|
@@ -14124,6 +14170,13 @@ interface PluginSdkApp {
|
|
|
14124
14170
|
* see docs/api_to_audit.md.
|
|
14125
14171
|
*/
|
|
14126
14172
|
experimental_useProviders(): PluginProvidersState;
|
|
14173
|
+
/**
|
|
14174
|
+
* The active code theme as a VS Code theme file (see
|
|
14175
|
+
* {@link PluginCodeThemeState}), for a plugin that renders code with an
|
|
14176
|
+
* engine of its own and needs BB's palette to reach it. Experimental: see
|
|
14177
|
+
* docs/api_to_audit.md.
|
|
14178
|
+
*/
|
|
14179
|
+
experimental_useCodeTheme(): PluginCodeThemeState;
|
|
14127
14180
|
/**
|
|
14128
14181
|
* The host-owned chat component (see {@link ThreadChatProps}). Together
|
|
14129
14182
|
* with `Markdown`, the only components the SDK ships — everything else
|
|
@@ -16676,4 +16729,4 @@ interface BbPluginApi {
|
|
|
16676
16729
|
}
|
|
16677
16730
|
|
|
16678
16731
|
export { PLUGIN_CLI_OUTPUT_MAX_BYTES, defineRpcContract, experimental_defineHostEntry };
|
|
16679
|
-
export type { BbContext, BbNavigate, BbPluginApi, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalHostCallOptions, ExperimentalHostClient, ExperimentalHostEntry, ExperimentalHostPaths, ExperimentalHostRpcContext, ExperimentalHostRpcHandlers, ExperimentalHostSignalContract, ExperimentalHostSignalEvent, ExperimentalHostSignals, ExperimentalHostWatchChange, ExperimentalHostWatchChangeType, ExperimentalHostWatchEvent, ExperimentalHostWatchListener, ExperimentalHostWatchOptions, ExperimentalHostWatchSubscription, ExperimentalHostWorkerLease, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAgentConfiguration, PluginAgentConfigurationContext, PluginAgentToolContentPart, PluginAgentToolContext, PluginAgentToolLabels, PluginAgentToolPresentation, PluginAgentToolRegistrationBase, PluginAgentToolResult, PluginAgentToolSelection, PluginAgents, PluginAiServiceDeclaration, PluginAiServiceKind, PluginAiServices, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginBackground, PluginCli, PluginCliCommandInfo, PluginCliContext, PluginCliExecutionResult, PluginCliOutputLimitError, PluginCliRegistration, PluginCliResult, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginEvents, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginHosts, PluginHttp, PluginHttpAuthMode, PluginHttpHandler, PluginInteractionCancelReason, PluginInteractionRequest, PluginInteractionResult, PluginKvStorage, PluginLogger, PluginMentionItem, PluginMentionProviderRegistration, PluginMentionSearchContext, PluginMentionTrigger, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderCapabilities, PluginProviderComposerAction, PluginProviderDeclaration, PluginProviderExtensionKindDeclaration, PluginProviderFallbackModel, PluginProviderIconRegistration, PluginProviderMaintenance, PluginProviderModelCatalogScope, PluginProviderNativeRootEntry, PluginProviderNativeRoots, PluginProviderOptionDescriptor, PluginProviderOptionsContext, PluginProviderPermissionMode, PluginProviderReasoningLevel, PluginProviderStrings, PluginProviders, PluginProvidersState, PluginRealtime, PluginRealtimeConnectionState, PluginRpc, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginServerApi, PluginSettingDescriptor, PluginSettingDescriptors, PluginSettingValue, PluginSettings, PluginSettingsHandle, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSettingsValues, PluginSharedPortTunnelIdentity, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginStatusApi, PluginStorage, PluginTargetedPanelActionOpenOptions, PluginThreadEventHandler, PluginThreadEventName, PluginThreadEventPayloads, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, PluginUi, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
|
16732
|
+
export type { BbContext, BbNavigate, BbPluginApi, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalHostCallOptions, ExperimentalHostClient, ExperimentalHostEntry, ExperimentalHostPaths, ExperimentalHostRpcContext, ExperimentalHostRpcHandlers, ExperimentalHostSignalContract, ExperimentalHostSignalEvent, ExperimentalHostSignals, ExperimentalHostWatchChange, ExperimentalHostWatchChangeType, ExperimentalHostWatchEvent, ExperimentalHostWatchListener, ExperimentalHostWatchOptions, ExperimentalHostWatchSubscription, ExperimentalHostWorkerLease, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAgentConfiguration, PluginAgentConfigurationContext, PluginAgentToolContentPart, PluginAgentToolContext, PluginAgentToolLabels, PluginAgentToolPresentation, PluginAgentToolRegistrationBase, PluginAgentToolResult, PluginAgentToolSelection, PluginAgents, PluginAiServiceDeclaration, PluginAiServiceKind, PluginAiServices, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginBackground, PluginCli, PluginCliCommandInfo, PluginCliContext, PluginCliExecutionResult, PluginCliOutputLimitError, PluginCliRegistration, PluginCliResult, PluginCodeThemeData, PluginCodeThemeState, PluginCodeThemeTokenRule, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginEvents, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginHosts, PluginHttp, PluginHttpAuthMode, PluginHttpHandler, PluginInteractionCancelReason, PluginInteractionRequest, PluginInteractionResult, PluginKvStorage, PluginLogger, PluginMentionItem, PluginMentionProviderRegistration, PluginMentionSearchContext, PluginMentionTrigger, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderCapabilities, PluginProviderComposerAction, PluginProviderDeclaration, PluginProviderExtensionKindDeclaration, PluginProviderFallbackModel, PluginProviderIconRegistration, PluginProviderMaintenance, PluginProviderModelCatalogScope, PluginProviderNativeRootEntry, PluginProviderNativeRoots, PluginProviderOptionDescriptor, PluginProviderOptionsContext, PluginProviderPermissionMode, PluginProviderReasoningLevel, PluginProviderStrings, PluginProviders, PluginProvidersState, PluginRealtime, PluginRealtimeConnectionState, PluginRpc, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginServerApi, PluginSettingDescriptor, PluginSettingDescriptors, PluginSettingValue, PluginSettings, PluginSettingsHandle, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSettingsValues, PluginSharedPortTunnelIdentity, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginStatusApi, PluginStorage, PluginTargetedPanelActionOpenOptions, PluginThreadEventHandler, PluginThreadEventName, PluginThreadEventPayloads, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, PluginUi, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
package/dist/app.js
CHANGED
|
@@ -25,6 +25,7 @@ var experimental_useSidebarThreadActions = runtime.experimental_useSidebarThread
|
|
|
25
25
|
var experimental_useSidebarThreadPullRequest = runtime.experimental_useSidebarThreadPullRequest;
|
|
26
26
|
var experimental_useSidebarThreadSplit = runtime.experimental_useSidebarThreadSplit;
|
|
27
27
|
var experimental_useProviders = runtime.experimental_useProviders;
|
|
28
|
+
var experimental_useCodeTheme = runtime.experimental_useCodeTheme;
|
|
28
29
|
export {
|
|
29
30
|
Markdown,
|
|
30
31
|
ThreadChat,
|
|
@@ -37,6 +38,7 @@ export {
|
|
|
37
38
|
experimental_ProviderModelPicker,
|
|
38
39
|
experimental_SourceCode,
|
|
39
40
|
experimental_useAppPanel,
|
|
41
|
+
experimental_useCodeTheme,
|
|
40
42
|
experimental_useFixedTabTarget,
|
|
41
43
|
experimental_useProviders,
|
|
42
44
|
experimental_useSidebarThreadActions,
|
|
@@ -7253,9 +7253,25 @@ function buildAcpModelListParams(launchSpec, options) {
|
|
|
7253
7253
|
...launchSpec.nativeReasoning !== void 0 ? { nativeReasoning: launchSpec.nativeReasoning } : {}
|
|
7254
7254
|
};
|
|
7255
7255
|
}
|
|
7256
|
-
|
|
7256
|
+
var CURSOR_LEGACY_FAMILY_SELECTIONS = {
|
|
7257
|
+
"claude-4-sonnet": { modelId: "claude-sonnet-4" },
|
|
7258
|
+
"claude-4.5-opus": { modelId: "claude-opus-4-5" },
|
|
7259
|
+
"claude-4.5-sonnet": { modelId: "claude-sonnet-4-5" },
|
|
7260
|
+
"claude-4.6-opus": { modelId: "claude-opus-4-6" },
|
|
7261
|
+
"claude-4.6-sonnet": { modelId: "claude-sonnet-4-6" },
|
|
7262
|
+
"gemini-3.6-flash-minimal": {
|
|
7263
|
+
modelId: "gemini-3.6-flash",
|
|
7264
|
+
reasoningLevel: "low"
|
|
7265
|
+
},
|
|
7266
|
+
"gpt-5.1-codex-max": { modelId: "gpt-5.1" }
|
|
7267
|
+
};
|
|
7268
|
+
function cursorParameterizedSelection(model, reasoningLevel) {
|
|
7257
7269
|
const familyId = model === "auto" ? "default" : agentModelFamilyId(model);
|
|
7258
|
-
|
|
7270
|
+
const bareFamilyId = familyId.startsWith("cursor-") ? familyId.slice("cursor-".length) : familyId;
|
|
7271
|
+
const selection = CURSOR_LEGACY_FAMILY_SELECTIONS[bareFamilyId] ?? {
|
|
7272
|
+
modelId: bareFamilyId
|
|
7273
|
+
};
|
|
7274
|
+
return selection.reasoningLevel !== void 0 || reasoningLevel === void 0 ? selection : { ...selection, reasoningLevel };
|
|
7259
7275
|
}
|
|
7260
7276
|
function buildAcpModelSelectionParam(launchSpec, options, parameterizedModelPicker, dialectId) {
|
|
7261
7277
|
const model = options.model;
|
|
@@ -7264,10 +7280,13 @@ function buildAcpModelSelectionParam(launchSpec, options, parameterizedModelPick
|
|
|
7264
7280
|
return {};
|
|
7265
7281
|
}
|
|
7266
7282
|
if (parameterizedModelPicker || !listCommand || !launchSpec.modelCli?.selectFlag) {
|
|
7283
|
+
const modelSelection = parameterizedModelPicker && dialectId === "cursor" ? cursorParameterizedSelection(model, options.reasoningLevel) : {
|
|
7284
|
+
modelId: model,
|
|
7285
|
+
...options.reasoningLevel !== void 0 ? { reasoningLevel: options.reasoningLevel } : {}
|
|
7286
|
+
};
|
|
7267
7287
|
return {
|
|
7268
7288
|
modelSelection: {
|
|
7269
|
-
|
|
7270
|
-
...options.reasoningLevel !== void 0 ? { reasoningLevel: options.reasoningLevel } : {},
|
|
7289
|
+
...modelSelection,
|
|
7271
7290
|
...parameterizedModelPicker && options.serviceTier !== void 0 ? { serviceTier: options.serviceTier } : {}
|
|
7272
7291
|
}
|
|
7273
7292
|
};
|
|
@@ -7395,6 +7414,7 @@ function createAcpAgentConnection(options) {
|
|
|
7395
7414
|
const stderrChunks = [];
|
|
7396
7415
|
let nextRequestId = 1;
|
|
7397
7416
|
let exited = false;
|
|
7417
|
+
let stopping = false;
|
|
7398
7418
|
function rejectAllPending(error) {
|
|
7399
7419
|
for (const [, request] of pending) {
|
|
7400
7420
|
request.reject(error);
|
|
@@ -7416,6 +7436,9 @@ function createAcpAgentConnection(options) {
|
|
|
7416
7436
|
options.onExit({ code: null, signal: null, stderrTail });
|
|
7417
7437
|
}
|
|
7418
7438
|
function writeLine(message) {
|
|
7439
|
+
if (stopping) {
|
|
7440
|
+
return;
|
|
7441
|
+
}
|
|
7419
7442
|
const stdin = child.stdin;
|
|
7420
7443
|
if (!stdin || stdin.destroyed || !stdin.writable) {
|
|
7421
7444
|
closeForAgentStdin(new Error("stdin is not writable"));
|
|
@@ -7427,6 +7450,10 @@ function createAcpAgentConnection(options) {
|
|
|
7427
7450
|
if (!isClosedAgentStdinError(error)) {
|
|
7428
7451
|
throw error;
|
|
7429
7452
|
}
|
|
7453
|
+
if (stopping) {
|
|
7454
|
+
child.kill("SIGKILL");
|
|
7455
|
+
return;
|
|
7456
|
+
}
|
|
7430
7457
|
closeForAgentStdin(error);
|
|
7431
7458
|
});
|
|
7432
7459
|
if (child.stdout) {
|
|
@@ -7524,10 +7551,10 @@ function createAcpAgentConnection(options) {
|
|
|
7524
7551
|
});
|
|
7525
7552
|
return {
|
|
7526
7553
|
get exited() {
|
|
7527
|
-
return exited;
|
|
7554
|
+
return stopping || exited;
|
|
7528
7555
|
},
|
|
7529
7556
|
request({ method, params, resultSchema }) {
|
|
7530
|
-
if (exited) {
|
|
7557
|
+
if (stopping || exited) {
|
|
7531
7558
|
return Promise.reject(
|
|
7532
7559
|
new AcpAgentExitedError(
|
|
7533
7560
|
`ACP agent "${options.command}" is not running`
|
|
@@ -7556,15 +7583,21 @@ function createAcpAgentConnection(options) {
|
|
|
7556
7583
|
});
|
|
7557
7584
|
},
|
|
7558
7585
|
notify(method, params) {
|
|
7559
|
-
if (exited) {
|
|
7586
|
+
if (stopping || exited) {
|
|
7560
7587
|
return;
|
|
7561
7588
|
}
|
|
7562
7589
|
writeLine({ jsonrpc: "2.0", method, params });
|
|
7563
7590
|
},
|
|
7564
7591
|
kill() {
|
|
7565
|
-
if (exited) {
|
|
7592
|
+
if (stopping || exited) {
|
|
7566
7593
|
return;
|
|
7567
7594
|
}
|
|
7595
|
+
stopping = true;
|
|
7596
|
+
rejectAllPending(
|
|
7597
|
+
new AcpAgentExitedError(
|
|
7598
|
+
`ACP agent "${options.command}" is not running`
|
|
7599
|
+
)
|
|
7600
|
+
);
|
|
7568
7601
|
child.kill("SIGTERM");
|
|
7569
7602
|
}
|
|
7570
7603
|
};
|
|
@@ -7111,9 +7111,8 @@ async function replayRecording(options) {
|
|
|
7111
7111
|
`all ${plannedEventCount} planned events before closing the bridge`,
|
|
7112
7112
|
() => events.length >= plannedEventCount
|
|
7113
7113
|
);
|
|
7114
|
-
} else {
|
|
7115
|
-
await waitFor("the stream to settle", () => Date.now() - lastOutputAt >= settleMs);
|
|
7116
7114
|
}
|
|
7115
|
+
await waitFor("the stream to settle", () => Date.now() - lastOutputAt >= settleMs);
|
|
7117
7116
|
child.stdin?.end();
|
|
7118
7117
|
const exitCode = await Promise.race([
|
|
7119
7118
|
exited,
|
package/dist/testing/app.js
CHANGED
|
@@ -1287,6 +1287,9 @@ var testPluginSdkApp = {
|
|
|
1287
1287
|
experimental_useProviders() {
|
|
1288
1288
|
return useSlotEnv("experimental_useProviders").providers;
|
|
1289
1289
|
},
|
|
1290
|
+
experimental_useCodeTheme() {
|
|
1291
|
+
return useSlotEnv("experimental_useCodeTheme").codeTheme;
|
|
1292
|
+
},
|
|
1290
1293
|
experimental_useSidebarThreadActions() {
|
|
1291
1294
|
return useSlotEnv("experimental_useSidebarThreadActions").sidebarActions;
|
|
1292
1295
|
},
|
|
@@ -1597,6 +1600,11 @@ function renderSlot(registration, props, options = {}) {
|
|
|
1597
1600
|
status: options.providers?.status ?? "ready",
|
|
1598
1601
|
providers: options.providers?.providers ?? []
|
|
1599
1602
|
};
|
|
1603
|
+
const codeTheme = {
|
|
1604
|
+
mode: options.codeTheme?.mode ?? "light",
|
|
1605
|
+
name: options.codeTheme?.name ?? "pierre-light",
|
|
1606
|
+
theme: options.codeTheme?.theme ?? null
|
|
1607
|
+
};
|
|
1600
1608
|
const sidebarActions = {
|
|
1601
1609
|
open(threadId2, openOptions) {
|
|
1602
1610
|
sidebarActionCalls.push({
|
|
@@ -1781,7 +1789,8 @@ ${block}
|
|
|
1781
1789
|
sidebarActions,
|
|
1782
1790
|
sidebarActionCalls,
|
|
1783
1791
|
sidebarPullRequests,
|
|
1784
|
-
providers
|
|
1792
|
+
providers,
|
|
1793
|
+
codeTheme
|
|
1785
1794
|
};
|
|
1786
1795
|
const releaseComposerOwnership = () => {
|
|
1787
1796
|
if (!composerOwnership.active) return;
|