@markupai/sidebar-adapter 2.3.0 → 2.5.0
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/README.md +96 -11
- package/asyncapi.json +201 -41
- package/dist/adapters/index.d.ts +2 -2
- package/dist/adapters/pluginAdapter.d.ts +15 -3
- package/dist/adapters/pluginAdapter.d.ts.map +1 -1
- package/dist/adapters/sidebarAdapter.d.ts +2 -2
- package/dist/adapters/sidebarAdapter.d.ts.map +1 -1
- package/dist/errors.d.ts +12 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/ipc/call-signatures.d.ts +15 -2
- package/dist/ipc/call-signatures.d.ts.map +1 -1
- package/dist/ipc/deferred-promise.d.ts.map +1 -1
- package/dist/ipc/index.d.ts +8 -8
- package/dist/ipc/index.d.ts.map +1 -1
- package/dist/ipc/ipc-core.d.ts +32 -3
- package/dist/ipc/ipc-core.d.ts.map +1 -1
- package/dist/ipc/message-types.d.ts +35 -4
- package/dist/ipc/message-types.d.ts.map +1 -1
- package/dist/ipc/plugin-ipc-adapter.d.ts +16 -5
- package/dist/ipc/plugin-ipc-adapter.d.ts.map +1 -1
- package/dist/ipc/replace-progress.d.ts +9 -0
- package/dist/ipc/replace-progress.d.ts.map +1 -0
- package/dist/ipc/sidebar-build-info.d.ts +1 -1
- package/dist/ipc/sidebar-ipc-adapter.d.ts +4 -4
- package/dist/ipc/sidebar-ipc-adapter.d.ts.map +1 -1
- package/dist/load-overlay/loadOverlayStyles.d.ts.map +1 -1
- package/dist/load-overlay/sidebarLoadOverlay.d.ts.map +1 -1
- package/dist/main.js +319 -210
- package/dist/main.umd.cjs +7 -7
- package/dist/sidebar-host/createSidebarHost.d.ts +4 -4
- package/dist/types/common.d.ts +30 -0
- package/dist/types/common.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/integrationSettings.d.ts.map +1 -1
- package/dist/types/pluginInterface.d.ts +38 -2
- package/dist/types/pluginInterface.d.ts.map +1 -1
- package/dist/types/progress.d.ts +18 -0
- package/dist/types/progress.d.ts.map +1 -0
- package/package.json +3 -3
package/dist/errors.d.ts
CHANGED
|
@@ -35,6 +35,18 @@ export declare class ReplaceBatchError extends TextLookupError {
|
|
|
35
35
|
readonly failed: ReplaceBatchFailedRange[];
|
|
36
36
|
constructor(message: string, outcome: ReplaceBatchOutcome);
|
|
37
37
|
}
|
|
38
|
+
/** Rejection of an IPC call that got no answer within its timeout. */
|
|
39
|
+
export declare class IpcTimeoutError extends Error {
|
|
40
|
+
readonly name: string;
|
|
41
|
+
/**
|
|
42
|
+
* `requestedMs` is the timeout the caller gave when it could not be used as
|
|
43
|
+
* is (see `MAX_IPC_TIMEOUT_MS`); the message names it, so the caller's bug is
|
|
44
|
+
* visible where the timeout surfaces.
|
|
45
|
+
*/
|
|
46
|
+
constructor(method: string, timeoutMs: number, requestedMs?: number);
|
|
47
|
+
}
|
|
48
|
+
/** Type guard for IpcTimeoutError: the call timed out, and the host may still be working. */
|
|
49
|
+
export declare function isIpcTimeoutError(error: unknown): error is IpcTimeoutError;
|
|
38
50
|
/**
|
|
39
51
|
* Type guard for ReplaceBatchError. Check it before `isTextLookupError` when
|
|
40
52
|
* catching from `replaceMultipleContents`: every ReplaceBatchError is also a
|
package/dist/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAC;AAE9D;;;;;;;GAOG;AACH,qBAAa,eAAgB,SAAQ,KAAK;IACxC,SAAkB,IAAI,EAAE,MAAM,CAAqB;
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,OAAO,KAA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Ae,CAAC;AAElD;;;;GAIG;AACH,MAAM,MAAM,4BAA4B,GAAG,eAAe,GAAG,iBAAiB,CAAC;AAE/E;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAED,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,eAAe,KAAK,KAAK,CAAC;AAErF;;;GAGG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CASrE,CAAC;AAEF;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,eAAe,GAAG,KAAK,CAW/D"}
|
|
@@ -1,5 +1,13 @@
|
|
|
1
|
-
import type { ContentRange, ContentReplacement, ContentInfo, InitConfigResponse, SidebarBuildInfo, AgenticIssuePayload, PluginStatusType } from "../types/common";
|
|
2
|
-
import type {
|
|
1
|
+
import type { CommentRequest, ContentRange, ContentReplacement, ContentInfo, InitConfigResponse, SidebarBuildInfo, AgenticIssuePayload, PluginStatusType } from "../types/common.js";
|
|
2
|
+
import type { ReplaceProgress } from "../types/progress.js";
|
|
3
|
+
import type { IntegrationSettingsValues, IntegrationSettingsChangeMeta, IntegrationSettingsPatch, IntegrationSettingsSnapshot } from "../types/integrationSettings.js";
|
|
4
|
+
/**
|
|
5
|
+
* The payload of a `progress` message, per method that reports progress. A new
|
|
6
|
+
* method that reports adds an entry here.
|
|
7
|
+
*/
|
|
8
|
+
export interface ProgressPayloads {
|
|
9
|
+
replaceMultipleContents: ReplaceProgress;
|
|
10
|
+
}
|
|
3
11
|
/**
|
|
4
12
|
* Call signatures for all bidirectional IPC communication.
|
|
5
13
|
* This interface maps method names to their parameter types and return types.
|
|
@@ -79,6 +87,11 @@ export interface CallSignatures {
|
|
|
79
87
|
* See {@link PluginInterface.copyToClipboard}.
|
|
80
88
|
*/
|
|
81
89
|
copyToClipboard(text: string): Promise<void>;
|
|
90
|
+
/**
|
|
91
|
+
* Ask the plugin to anchor a comment on a span of the document.
|
|
92
|
+
* See {@link PluginInterface.addComment}.
|
|
93
|
+
*/
|
|
94
|
+
addComment(comment: CommentRequest, documentReference?: string | null): Promise<void>;
|
|
82
95
|
/**
|
|
83
96
|
* Notify plugin when the user changes a value in the integration-settings
|
|
84
97
|
* form. Optional on the plugin side; absent handler is a no-op.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"call-signatures.d.ts","sourceRoot":"","sources":["../../src/ipc/call-signatures.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,YAAY,EACZ,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,gBAAgB,EAChB,mBAAmB,EACnB,gBAAgB,EACjB,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,EACV,yBAAyB,EACzB,6BAA6B,EAC7B,wBAAwB,EACxB,2BAA2B,EAC5B,MAAM,6BAA6B,CAAC;AAErC;;;GAGG;AACH,MAAM,WAAW,cAAc;IAK7B;;OAEG;IACH,UAAU,IAAI,OAAO,CAAC,WAAW,CAAC,CAAC;IAEnC;;OAEG;IACH,kBAAkB,IAAI,OAAO,CAAC,WAAW,CAAC,CAAC;IAE3C;;;;;;OAMG;IACH,cAAc,CACZ,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,YAAY,EACnB,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,GAChC,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;;OAMG;IACH,aAAa,CAAC,KAAK,EAAE,YAAY,EAAE,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErF;;OAEG;IACH,uBAAuB,CAAC,YAAY,EAAE,kBAAkB,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE3E;;;;;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AC,CAAC,CAAC;IAChD,2FAA2F;IAC3F,MAAM,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,kBAAkB,CAEhD;IAED;;;;OAIG;IACH,OAAO,EAAG,CAAC,KAAK,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,IAAI,CAAC;IAE9C;;;;OAIG;IACH,MAAM,EAAG,CAAC,MAAM,CAAC,EAAE,GAAG,KAAK,IAAI,CAAC;IAEhC;;;;;;OAMG;
|
|
1
|
+
{"version":3,"file":"deferred-promise.d.ts","sourceRoot":"","sources":["../../src/ipc/deferred-promise.ts"],"names":[],"mappings":"AAEA;;;;;;;;GAQG;AACH,qBAAa,eAAe,CAAC,CAAC,CAAE,SAAQ,OAAO,CAAC,CAAC,CAAC;IAChD,2FAA2F;IAC3F,MAAM,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,kBAAkB,CAEhD;IAED;;;;OAIG;IACH,OAAO,EAAG,CAAC,KAAK,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,IAAI,CAAC;IAE9C;;;;OAIG;IACH,MAAM,EAAG,CAAC,MAAM,CAAC,EAAE,GAAG,KAAK,IAAI,CAAC;IAEhC;;;;;;OAMG;IACH,YACE,QAAQ,GAAE,CACR,OAAO,EAAE,CAAC,KAAK,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,IAAI,EAC5C,MAAM,EAAE,CAAC,MAAM,CAAC,EAAE,GAAG,KAAK,IAAI,KAC3B,IAAmB,EAWzB;CACF"}
|
package/dist/ipc/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export { DeferredPromise } from "./deferred-promise";
|
|
2
|
-
export { IPCCore } from "./ipc-core";
|
|
3
|
-
export type { ReceiverFn } from "./ipc-core";
|
|
4
|
-
export { PluginIPCAdapter } from "./plugin-ipc-adapter";
|
|
5
|
-
export { SidebarIPCAdapter } from "./sidebar-ipc-adapter";
|
|
6
|
-
export type { MessageBase, CallMessage, ResponseMessage, ErrorMessage, IPCMessage, IPCConfig, CallOptions, } from "./message-types";
|
|
7
|
-
export { DEFAULT_IPC_CONFIG } from "./message-types";
|
|
8
|
-
export type { CallSignatures } from "./call-signatures";
|
|
1
|
+
export { DeferredPromise } from "./deferred-promise.js";
|
|
2
|
+
export { IPCCore, LATE_RESULT_WINDOW_MS, MAX_IPC_TIMEOUT_MS } from "./ipc-core.js";
|
|
3
|
+
export type { ReceiverFn, ProgressReceiverFn } from "./ipc-core.js";
|
|
4
|
+
export { PluginIPCAdapter } from "./plugin-ipc-adapter.js";
|
|
5
|
+
export { SidebarIPCAdapter } from "./sidebar-ipc-adapter.js";
|
|
6
|
+
export type { MessageBase, CallMessage, ResponseMessage, ErrorMessage, ProgressMessage, IPCMessage, IPCConfig, CallOptions, ProgressCallOptions, LateResult, } from "./message-types.js";
|
|
7
|
+
export { DEFAULT_IPC_CONFIG } from "./message-types.js";
|
|
8
|
+
export type { CallSignatures, ProgressPayloads } from "./call-signatures.js";
|
|
9
9
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/ipc/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ipc/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ipc/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACpF,YAAY,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACrE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAG9D,YAAY,EACV,WAAW,EACX,WAAW,EACX,eAAe,EACf,YAAY,EACZ,eAAe,EACf,UAAU,EACV,SAAS,EACT,WAAW,EACX,mBAAmB,EACnB,UAAU,GACX,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAGzD,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC"}
|
package/dist/ipc/ipc-core.d.ts
CHANGED
|
@@ -1,12 +1,27 @@
|
|
|
1
|
-
import type { CallSignatures } from "./call-signatures";
|
|
2
|
-
import type { IPCMessage, IPCConfig,
|
|
1
|
+
import type { CallSignatures } from "./call-signatures.js";
|
|
2
|
+
import type { IPCMessage, IPCConfig, ProgressCallOptions } from "./message-types.js";
|
|
3
3
|
export type ReceiverFn<R extends keyof CallSignatures> = (...data: Parameters<NonNullable<CallSignatures[R]>>) => ReturnType<NonNullable<CallSignatures[R]>>;
|
|
4
|
+
/** A receiver that can report progress while it works. Reports expect no reply. */
|
|
5
|
+
export type ProgressReceiverFn<R extends keyof CallSignatures> = (report: (progress: unknown) => void, ...data: Parameters<NonNullable<CallSignatures[R]>>) => ReturnType<NonNullable<CallSignatures[R]>>;
|
|
6
|
+
/**
|
|
7
|
+
* How long a timed-out call that asked for late answers stays registered. A
|
|
8
|
+
* host that hangs, or a sidebar whose answer no longer matters, would
|
|
9
|
+
* otherwise keep the entry and its callbacks for the life of the page.
|
|
10
|
+
*/
|
|
11
|
+
export declare const LATE_RESULT_WINDOW_MS: number;
|
|
12
|
+
/**
|
|
13
|
+
* The longest timeout `setTimeout` can wait (2^31 - 1 ms, about 24.8 days).
|
|
14
|
+
* A longer one, `Infinity` included, would fire at once, so it is clamped to
|
|
15
|
+
* this: "wait as long as it takes" waits as long as it can.
|
|
16
|
+
*/
|
|
17
|
+
export declare const MAX_IPC_TIMEOUT_MS = 2147483647;
|
|
4
18
|
/**
|
|
5
19
|
* Core IPC system managing bidirectional communication
|
|
6
20
|
*/
|
|
7
21
|
export declare class IPCCore {
|
|
8
22
|
private promisesByID;
|
|
9
23
|
private receiversByName;
|
|
24
|
+
private readonly progressReceiverNames;
|
|
10
25
|
private currentID;
|
|
11
26
|
private config;
|
|
12
27
|
private readonly postMessage;
|
|
@@ -32,7 +47,7 @@ export declare class IPCCore {
|
|
|
32
47
|
* @param data - Parameters to send to the receiver
|
|
33
48
|
* @returns Promise that resolves with the receiver's response
|
|
34
49
|
*/
|
|
35
|
-
callWithOptions<T extends keyof CallSignatures>(name: T, options:
|
|
50
|
+
callWithOptions<T extends keyof CallSignatures>(name: T, options: ProgressCallOptions, ...data: Parameters<NonNullable<CallSignatures[T]>>): Promise<ReturnType<NonNullable<CallSignatures[T]>>>;
|
|
36
51
|
/**
|
|
37
52
|
* Registers a function to receive calls with a particular name.
|
|
38
53
|
* The return value will be sent back to the caller.
|
|
@@ -41,6 +56,15 @@ export declare class IPCCore {
|
|
|
41
56
|
* @param fn - The function that will receive calls
|
|
42
57
|
*/
|
|
43
58
|
receive<R extends keyof CallSignatures>(name: R, fn: ReceiverFn<R>): void;
|
|
59
|
+
/**
|
|
60
|
+
* Registers a receiver that can report progress while it handles a call. The
|
|
61
|
+
* report function comes before the call's arguments, so it cannot collide
|
|
62
|
+
* with an optional trailing one.
|
|
63
|
+
*
|
|
64
|
+
* @param name - The name of the receiver
|
|
65
|
+
* @param fn - The function that will receive calls
|
|
66
|
+
*/
|
|
67
|
+
receiveWithProgress<R extends keyof CallSignatures>(name: R, fn: ProgressReceiverFn<R>): void;
|
|
44
68
|
/**
|
|
45
69
|
* Unregisters a receiver for a given call name
|
|
46
70
|
*
|
|
@@ -64,6 +88,11 @@ export declare class IPCCore {
|
|
|
64
88
|
* Handles incoming error messages
|
|
65
89
|
*/
|
|
66
90
|
private handleError;
|
|
91
|
+
/**
|
|
92
|
+
* Hands a progress report to the caller. A report for an unknown call is
|
|
93
|
+
* dropped: the call has its final answer, or its caller did not ask.
|
|
94
|
+
*/
|
|
95
|
+
private handleProgress;
|
|
67
96
|
/**
|
|
68
97
|
* Cleanup all pending promises and receivers
|
|
69
98
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ipc-core.d.ts","sourceRoot":"","sources":["../../src/ipc/ipc-core.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,KAAK,EAGV,UAAU,
|
|
1
|
+
{"version":3,"file":"ipc-core.d.ts","sourceRoot":"","sources":["../../src/ipc/ipc-core.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,KAAK,EAGV,UAAU,EAGV,SAAS,EAET,mBAAmB,EACpB,MAAM,qBAAqB,CAAC;AAK7B,MAAM,MAAM,UAAU,CAAC,CAAC,SAAS,MAAM,cAAc,IAAI,CACvD,GAAG,IAAI,EAAE,UAAU,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,KAChD,UAAU,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAEhD,mFAAmF;AACnF,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,MAAM,cAAc,IAAI,CAC/D,MAAM,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,EACnC,GAAG,IAAI,EAAE,UAAU,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,KAChD,UAAU,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAuEhD;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,QAAa,CAAC;AAEhD;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,aAAgB,CAAC;AAiBhD;;GAEG;AACH,qBAAa,OAAO;IACl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AAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAKhC;IAED;;;OAGG;IACU,aAAa,CAAC,OAAO,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CA0B7D;IAED;;OAEG;YACW,UAAU;IA+DxB;;OAEG;IACH,OAAO,CAAC,cAAc;IAkBtB;;OAEG;IACH,OAAO,CAAC,WAAW;IAoBnB;;;OAGG;IACH,OAAO,CAAC,cAAc;IAMtB;;OAEG;IACI,OAAO,IAAI,IAAI,CAWrB;CACF"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Base message structure for IPC communication
|
|
3
3
|
*/
|
|
4
4
|
export type MessageBase = {
|
|
5
|
-
type: "call" | "response" | "error";
|
|
5
|
+
type: "call" | "response" | "error" | "progress";
|
|
6
6
|
id: number;
|
|
7
7
|
name: string;
|
|
8
8
|
};
|
|
@@ -27,16 +27,27 @@ export type ErrorMessage = MessageBase & {
|
|
|
27
27
|
type: "error";
|
|
28
28
|
errorJSON: string;
|
|
29
29
|
};
|
|
30
|
+
/**
|
|
31
|
+
* Message a receiver sends while it handles a call. `id` is the call's id; no
|
|
32
|
+
* reply is expected. A side that does not know this type ignores it.
|
|
33
|
+
*/
|
|
34
|
+
export type ProgressMessage = MessageBase & {
|
|
35
|
+
type: "progress";
|
|
36
|
+
data: unknown;
|
|
37
|
+
};
|
|
30
38
|
/**
|
|
31
39
|
* Union of all possible message types
|
|
32
40
|
*/
|
|
33
|
-
export type IPCMessage = CallMessage | ResponseMessage | ErrorMessage;
|
|
41
|
+
export type IPCMessage = CallMessage | ResponseMessage | ErrorMessage | ProgressMessage;
|
|
34
42
|
/**
|
|
35
43
|
* Configuration for IPC system
|
|
36
44
|
*/
|
|
37
45
|
export interface IPCConfig {
|
|
38
46
|
/**
|
|
39
|
-
* Timeout in milliseconds for waiting for a response
|
|
47
|
+
* Timeout in milliseconds for waiting for a response. Above 2,147,483,647
|
|
48
|
+
* (`MAX_IPC_TIMEOUT_MS`), `Infinity` included, it is clamped to that; a
|
|
49
|
+
* fraction rounds up to whole milliseconds; `NaN`, 0 or a negative value
|
|
50
|
+
* uses the 10 s default instead.
|
|
40
51
|
* @default 10000 (10 seconds)
|
|
41
52
|
*/
|
|
42
53
|
timeout?: number;
|
|
@@ -46,10 +57,30 @@ export interface IPCConfig {
|
|
|
46
57
|
*/
|
|
47
58
|
export interface CallOptions {
|
|
48
59
|
/**
|
|
49
|
-
* Timeout in milliseconds for this call. Overrides
|
|
60
|
+
* Timeout in milliseconds for this call. Overrides the configured timeout.
|
|
61
|
+
* Above 2,147,483,647 (`MAX_IPC_TIMEOUT_MS`), `Infinity` included, it is
|
|
62
|
+
* clamped to that; a fraction rounds up to whole milliseconds; `NaN`, 0 or a
|
|
63
|
+
* negative value uses the configured timeout instead. A timeout error names
|
|
64
|
+
* a value that was replaced.
|
|
50
65
|
*/
|
|
51
66
|
timeout?: number;
|
|
52
67
|
}
|
|
68
|
+
/** The final answer of a call that had already timed out. */
|
|
69
|
+
export type LateResult = {
|
|
70
|
+
status: "success";
|
|
71
|
+
} | {
|
|
72
|
+
status: "error";
|
|
73
|
+
error: Error;
|
|
74
|
+
};
|
|
75
|
+
/**
|
|
76
|
+
* Callbacks for a call whose receiver may report progress.
|
|
77
|
+
*/
|
|
78
|
+
export interface ProgressCallOptions<TProgress = unknown> extends CallOptions {
|
|
79
|
+
/** Called for every report, also for one that arrives after the timeout. */
|
|
80
|
+
onProgress?: (progress: TProgress) => void;
|
|
81
|
+
/** Called once when the final answer arrives after the timeout. */
|
|
82
|
+
onLateResult?: (result: LateResult) => void;
|
|
83
|
+
}
|
|
53
84
|
/**
|
|
54
85
|
* Default IPC configuration
|
|
55
86
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message-types.d.ts","sourceRoot":"","sources":["../../src/ipc/message-types.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,MAAM,GAAG,UA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AAEnF;;GAEG;AACH,MAAM,WAAW,mBAAmB,CAAC,SAAS,GAAG,OAAO,CAAE,SAAQ,WAAW;IAC3E,4EAA4E;IAC5E,UAAU,CAAC,EAAE,CAAC,QAAQ,EAAE,SAAS,KAAK,IAAI,CAAC;IAC3C,mEAAmE;IACnE,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,UAAU,KAAK,IAAI,CAAC;CAC7C;AAED;;GAEG;AACH,eAAO,MAAM,kBAAkB,EAAE,QAAQ,CAAC,SAAS,CAElD,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import type { CallOptions, IPCConfig } from "./message-types";
|
|
2
|
-
import type {
|
|
3
|
-
import type {
|
|
4
|
-
import type {
|
|
1
|
+
import type { CallOptions, IPCConfig, ProgressCallOptions } from "./message-types.js";
|
|
2
|
+
import type { ProgressPayloads } from "./call-signatures.js";
|
|
3
|
+
import type { CommentRequest, ContentRange, ContentReplacement, ContentInfo, SidebarConfig, SidebarBuildInfo, AgenticIssuePayload } from "../types/common.js";
|
|
4
|
+
import type { IntegrationSettingsValues, IntegrationSettingsChangeMeta } from "../types/integrationSettings.js";
|
|
5
|
+
import type { SidebarInterface } from "../types/sidebarInterface.js";
|
|
5
6
|
/**
|
|
6
7
|
* PluginIPCAdapter - Used in the Sidebar to communicate with the Plugin in the editor
|
|
7
8
|
* Provides async methods to call plugin functions
|
|
@@ -51,8 +52,11 @@ export declare class PluginIPCAdapter {
|
|
|
51
52
|
selectContent(range: ContentRange, documentReference?: string | null): Promise<void>;
|
|
52
53
|
/**
|
|
53
54
|
* Replace multiple contents in the editor
|
|
55
|
+
* @param options - Optional per-call overrides (e.g. timeout in ms; overrides default IPC timeout)
|
|
56
|
+
* and callbacks for the host's progress reports and for an answer after the timeout. They stay
|
|
57
|
+
* on the sidebar side.
|
|
54
58
|
*/
|
|
55
|
-
replaceMultipleContents(replacements: ContentReplacement[]): Promise<void>;
|
|
59
|
+
replaceMultipleContents(replacements: ContentReplacement[], options?: ProgressCallOptions<ProgressPayloads["replaceMultipleContents"]>): Promise<void>;
|
|
56
60
|
/**
|
|
57
61
|
* Notify plugin that one agent's results are available (streaming).
|
|
58
62
|
*/
|
|
@@ -86,6 +90,13 @@ export declare class PluginIPCAdapter {
|
|
|
86
90
|
* back (e.g. to `navigator.clipboard.writeText`).
|
|
87
91
|
*/
|
|
88
92
|
copyToClipboard(text: string): Promise<void>;
|
|
93
|
+
/**
|
|
94
|
+
* Ask the plugin to anchor a comment on a span of the document.
|
|
95
|
+
* Throws if the plugin has not registered a handler, and rethrows the
|
|
96
|
+
* handler's own errors (e.g. `TextLookupError`) so the caller can report
|
|
97
|
+
* them.
|
|
98
|
+
*/
|
|
99
|
+
addComment(comment: CommentRequest, documentReference?: string | null): Promise<void>;
|
|
89
100
|
/**
|
|
90
101
|
* Notify plugin when the user changes a value in the integration-settings
|
|
91
102
|
* form. Throws if the plugin has not registered a handler; callers should
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin-ipc-adapter.d.ts","sourceRoot":"","sources":["../../src/ipc/plugin-ipc-adapter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,SAAS,EAAc,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"plugin-ipc-adapter.d.ts","sourceRoot":"","sources":["../../src/ipc/plugin-ipc-adapter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,SAAS,EAAc,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAEnG,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,KAAK,EACV,cAAc,EACd,YAAY,EACZ,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,gBAAgB,EAChB,mBAAmB,EAEpB,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,EACV,yBAAyB,EACzB,6BAA6B,EAE9B,MAAM,6BAA6B,CAAC;AACrC,OAAO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gress } from "../types/progress.js";
|
|
3
|
+
/**
|
|
4
|
+
* Read a `replaceMultipleContents` report off the wire. It crossed a frame, so
|
|
5
|
+
* it is untrusted: `null` when its shape is wrong, and ranges that were not
|
|
6
|
+
* part of the batch are left out.
|
|
7
|
+
*/
|
|
8
|
+
export declare function sanitizeReplaceProgress(raw: unknown, replacements: readonly ContentReplacement[]): ReplaceProgress | null;
|
|
9
|
+
//# sourceMappingURL=replace-progress.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"replace-progress.d.ts","sourceRoot":"","sources":["../../src/ipc/replace-progress.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAgB,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACvE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAUxD;;;;GAIG;AACH,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,OAAO,EACZ,YAAY,EAAE,SAAS,kBAAkB,EAAE,GAC1C,eAAe,GAAG,IAAI,CAWxB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SidebarBuildInfo } from "../types/common";
|
|
1
|
+
import type { SidebarBuildInfo } from "../types/common.js";
|
|
2
2
|
/** Longest string kept from a sidebar build report; longer values are truncated. */
|
|
3
3
|
export declare const SIDEBAR_BUILD_INFO_MAX_STRING_LENGTH = 64;
|
|
4
4
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type { IPCConfig } from "./message-types";
|
|
2
|
-
import type { PluginStatusType, SidebarBuildInfo } from "../types/common";
|
|
3
|
-
import type { IntegrationSettingsPatch, IntegrationSettingsSnapshot } from "../types/integrationSettings";
|
|
4
|
-
import type { PluginInterface } from "../types/pluginInterface";
|
|
1
|
+
import type { IPCConfig } from "./message-types.js";
|
|
2
|
+
import type { PluginStatusType, SidebarBuildInfo } from "../types/common.js";
|
|
3
|
+
import type { IntegrationSettingsPatch, IntegrationSettingsSnapshot } from "../types/integrationSettings.js";
|
|
4
|
+
import type { PluginInterface } from "../types/pluginInterface.js";
|
|
5
5
|
/**
|
|
6
6
|
* SidebarIPCAdapter - Used in the Plugin to communicate with the Sidebar in the iframe
|
|
7
7
|
* Provides async methods to call sidebar functions and registers receivers for plugin functions
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sidebar-ipc-adapter.d.ts","sourceRoot":"","sources":["../../src/ipc/sidebar-ipc-adapter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAc,MAAM,qBAAqB,CAAC;AAEjE,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"sidebar-ipc-adapter.d.ts","sourceRoot":"","sources":["../../src/ipc/sidebar-ipc-adapter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAc,MAAM,qBAAqB,CAAC;AAEjE,OAAO,KAAK,EAIV,gBAAgB,EAChB,gBAAgB,EACjB,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,EAGV,wBAAwB,EACxB,2BAA2B,EAC5B,MAAM,6BAA6B,CAAC;AACrC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAG/D;;;GAGG;AACH,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAU;IAC9B,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAkB;IACzC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAoB;IAC3C,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAS;IAChC,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAS;IACtC,OAAO,CAAC,sBAAsB,CAAiC;IAE/D,YACE,MAAM,EAAE,eAAe,EACvB,MAAM,EAAE,iBAAiB,EACzB,GAAG,CAAC,EAAE,MAAM,EACZ,MAAM,CAAC,EAAE,SAAS,EAClB,YAAY,GAAE,MAAY,EAmB3B;IAED,OAAO,CAAC,QAAQ,CAAC,aAAa,CAqB5B;IAEF,OAAO,CAAC,iBAAiB;IA4LzB;;;;;;;OAOG;IACU,oBAAoB,CAC/B,OAAO,EAAE,MAAM,EACf,iBAAiB,GAAE,MAAM,GAAG,IAAW,GACtC,OAAO,CAAC,IAAI,CAAC,CAGf;IAED;;OAEG;IACU,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAGlE;IAED;;OAEG;IACU,wBAAwB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAGpE;IAED;;OAEG;IACU,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAG/D;IAED;;;OAGG;IACU,kBAAkB,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC,CAGtF;IAED;;OAEG;IACU,wBAAwB,CAAC,KAAK,EAAE,wBAAwB,GAAG,OAAO,CAAC,IAAI,CAAC,CAGpF;IAED;;OAEG;IACU,sBAAsB,IAAI,OAAO,CAAC,2BAA2B,CAAC,CAG1E;IAED;;;;OAIG;IACU,2BAA2B,CAAC,iBAAiB,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAGxF;IAED;;;;;OAKG;IACI,mBAAmB,IAAI,gBAAgB,GAAG,IAAI,CAEpD;IAED;;OAEG;IACI,SAAS,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CAExC;IAED;;OAEG;IACI,OAAO,IAAI,IAAI,CAIrB;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loadOverlayStyles.d.ts","sourceRoot":"","sources":["../../src/load-overlay/loadOverlayStyles.ts"],"names":[],"mappings":"AAgGA,wFAAwF;AACxF,eAAO,MAAM,8BAA8B,
|
|
1
|
+
{"version":3,"file":"loadOverlayStyles.d.ts","sourceRoot":"","sources":["../../src/load-overlay/loadOverlayStyles.ts"],"names":[],"mappings":"AAgGA,wFAAwF;AACxF,eAAO,MAAM,8BAA8B,oBAAqB,QAAQ,SAOvE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sidebarLoadOverlay.d.ts","sourceRoot":"","sources":["../../src/load-overlay/sidebarLoadOverlay.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,yBAAyB,GAAG;IACtC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B,CAAC;AAKF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,uBAAuB,
|
|
1
|
+
{"version":3,"file":"sidebarLoadOverlay.d.ts","sourceRoot":"","sources":["../../src/load-overlay/sidebarLoadOverlay.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,yBAAyB,GAAG;IACtC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B,CAAC;AAKF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,uBAAuB,cACvB,WAAW,UACd,iBAAiB,YAChB,yBAAyB,eAoHnC,CAAC"}
|