@lvce-editor/rpc-registry 2.13.1 → 2.14.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/dist/index.d.ts +18 -0
- package/dist/index.js +9 -9
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -19,8 +19,25 @@ declare const invoke: <T extends keyof EditorWorkerApi>(method: T, ...params: Pa
|
|
|
19
19
|
export interface EmbedsProcessApi {
|
|
20
20
|
readonly "ElectronWebContents.dispose": (id: any) => Promise<void>;
|
|
21
21
|
readonly "ElectronWebContentsView.attachEventListeners": (webContentsId: any) => Promise<void>;
|
|
22
|
+
readonly "ElectronWebContentsView.backward": (id: any) => Promise<void>;
|
|
23
|
+
readonly "ElectronWebContentsView.cancelNavigation": (id: any) => Promise<any>;
|
|
24
|
+
readonly "ElectronWebContentsView.copyImageAt": (id: any, x: number, y: number) => Promise<void>;
|
|
22
25
|
readonly "ElectronWebContentsView.createWebContentsView": (webContentsId: any) => Promise<any>;
|
|
23
26
|
readonly "ElectronWebContentsView.disposeWebContentsView": (webContentsId: any) => Promise<void>;
|
|
27
|
+
readonly "ElectronWebContentsView.focus": (id: any) => Promise<void>;
|
|
28
|
+
readonly "ElectronWebContentsView.forward": (id: any) => Promise<void>;
|
|
29
|
+
readonly "ElectronWebContentsView.getDomTree": (id: any) => Promise<string>;
|
|
30
|
+
readonly "ElectronWebContentsView.getStats": (id: any, keyBindings: any) => Promise<any>;
|
|
31
|
+
readonly "ElectronWebContentsView.hide": (id: any) => Promise<void>;
|
|
32
|
+
readonly "ElectronWebContentsView.insertCss": (id: any, css: string) => Promise<void>;
|
|
33
|
+
readonly "ElectronWebContentsView.insertJavaScript": (id: any, code: string) => Promise<any>;
|
|
34
|
+
readonly "ElectronWebContentsView.inspectElement": (id: any, x: number, y: number) => Promise<void>;
|
|
35
|
+
readonly "ElectronWebContentsView.openDevtools": (id: any) => Promise<void>;
|
|
36
|
+
readonly "ElectronWebContentsView.reload": (id: any) => Promise<void>;
|
|
37
|
+
readonly "ElectronWebContentsView.resizeBrowserView": (id: any, x: number, y: number, width: number, height: number) => Promise<void>;
|
|
38
|
+
readonly "ElectronWebContentsView.setIframeSrc": (id: any, iframeSrc: string) => Promise<void>;
|
|
39
|
+
readonly "ElectronWebContentsView.setIframeSrcFallback": (id: any, code: any, error: any) => Promise<void>;
|
|
40
|
+
readonly "ElectronWebContentsView.show": (id: any) => Promise<void>;
|
|
24
41
|
readonly "ElectronWebContentsViewFunctions.getStats": (id: any, ...args: readonly any[]) => Promise<any>;
|
|
25
42
|
readonly "ElectronWebContentsViewFunctions.resizeBrowserView": (id: any, ...args: readonly any[]) => Promise<void>;
|
|
26
43
|
readonly "ElectronWebContentsViewFunctions.setBackgroundColor": (webContentsId: any, backgroundColor: string) => Promise<void>;
|
|
@@ -138,6 +155,7 @@ export interface RendererWorkerApi {
|
|
|
138
155
|
readonly "SearchProcess.invoke": (command: string, ...args: readonly any[]) => Promise<any>;
|
|
139
156
|
readonly "SendMessagePortToElectron.sendMessagePortToElectron": (port: MessagePort, command: string) => Promise<void>;
|
|
140
157
|
readonly "SendMessagePortToExtensionHostWorker.sendMessagePortToExtensionHostWorker": (port: MessagePort, initialCommand: string, rpcId: number) => Promise<void>;
|
|
158
|
+
readonly "SendMessagePortToExtensionHostWorker.sendMessagePortToSharedProcess": (port: MessagePort, outerCommand: string, rpcId: number) => Promise<void>;
|
|
141
159
|
readonly "Viewlet.closeWidget": (id: number | string) => Promise<void>;
|
|
142
160
|
readonly "Viewlet.openWidget": (widgetId: string) => Promise<string>;
|
|
143
161
|
readonly "WebView.getWebViewInfo2": (id: string) => Promise<any>;
|
package/dist/index.js
CHANGED
|
@@ -9,26 +9,19 @@ const remove = id => {
|
|
|
9
9
|
delete rpcs[id];
|
|
10
10
|
};
|
|
11
11
|
|
|
12
|
-
const EditorWorker$1 = 99;
|
|
13
|
-
const ExtensionHostWorker = 44;
|
|
14
|
-
const MainProcess$1 = -5;
|
|
15
|
-
const RendererWorker$1 = 1;
|
|
16
|
-
const SearchProcess$1 = 77;
|
|
17
|
-
const SharedProcess$1 = 1;
|
|
18
|
-
|
|
19
12
|
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
|
20
13
|
|
|
21
14
|
const create = rpcId => {
|
|
22
15
|
return {
|
|
23
16
|
// @ts-ignore
|
|
24
17
|
invoke(method, ...params) {
|
|
25
|
-
const rpc = get(
|
|
18
|
+
const rpc = get(rpcId);
|
|
26
19
|
// @ts-ignore
|
|
27
20
|
return rpc.invoke(method, ...params);
|
|
28
21
|
},
|
|
29
22
|
// @ts-ignore
|
|
30
23
|
invokeAndTransfer(method, ...params) {
|
|
31
|
-
const rpc = get(
|
|
24
|
+
const rpc = get(rpcId);
|
|
32
25
|
// @ts-ignore
|
|
33
26
|
return rpc.invokeAndTransfer(method, ...params);
|
|
34
27
|
},
|
|
@@ -38,6 +31,13 @@ const create = rpcId => {
|
|
|
38
31
|
};
|
|
39
32
|
};
|
|
40
33
|
|
|
34
|
+
const EditorWorker$1 = 99;
|
|
35
|
+
const ExtensionHostWorker = 44;
|
|
36
|
+
const MainProcess$1 = -5;
|
|
37
|
+
const RendererWorker$1 = 1;
|
|
38
|
+
const SearchProcess$1 = 77;
|
|
39
|
+
const SharedProcess$1 = 1;
|
|
40
|
+
|
|
41
41
|
const {
|
|
42
42
|
invoke: invoke$6,
|
|
43
43
|
invokeAndTransfer: invokeAndTransfer$6,
|