@lvce-editor/renderer-process 9.2.0 → 9.4.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.
@@ -836,14 +836,7 @@ const invoke$2 = async (ipc, method, ...params) => {
836
836
  const result = unwrapJsonRpcResult(responseMessage);
837
837
  return result;
838
838
  };
839
-
840
- // TODO deprecated old typings,
841
- // always use automatic transferrable detection
842
- const invokeAndTransfer$1 = async (ipc, handle, method, ...params) => {
843
- if (typeof handle === 'string') {
844
- params = [method, ...params];
845
- method = handle;
846
- }
839
+ const invokeAndTransfer$1 = async (ipc, method, ...params) => {
847
840
  const {
848
841
  message,
849
842
  promise
@@ -11360,7 +11353,7 @@ const setPort = (state, portId, origin) => {
11360
11353
  // TODO wait for load in renderer worker
11361
11354
  // TODO avoid closure
11362
11355
  // TODO use jsonrpc invoke
11363
- frame.addEventListener('load', () => {
11356
+ const handleLoad = () => {
11364
11357
  const {
11365
11358
  contentWindow
11366
11359
  } = frame;
@@ -11369,6 +11362,9 @@ const setPort = (state, portId, origin) => {
11369
11362
  method: 'setPort',
11370
11363
  params: [port]
11371
11364
  }, origin, [port]);
11365
+ };
11366
+ frame.addEventListener('load', handleLoad, {
11367
+ once: true
11372
11368
  });
11373
11369
  };
11374
11370
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/renderer-process",
3
- "version": "9.2.0",
3
+ "version": "9.4.0",
4
4
  "description": "",
5
5
  "main": "dist/diffWorkerMain.js",
6
6
  "type": "module",