@lvce-editor/panel-worker 2.10.5 → 2.11.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.
@@ -1651,7 +1651,7 @@ const forwardLayoutCommand = layoutCommand => {
1651
1651
  void invoke('Viewlet.forwardRendererWorkerCommand', layoutCommand);
1652
1652
  }, 0);
1653
1653
  };
1654
- const handleMessagePort = async (port, viewletCommandMap) => {
1654
+ const handleMessagePort = async (port, viewletCommandMap, setAsRendererProcess = true) => {
1655
1655
  const executeViewletCommand = async (uid, command, ...args) => {
1656
1656
  const layoutCommand = layoutCommands[command];
1657
1657
  if (layoutCommand) {
@@ -1672,7 +1672,9 @@ const handleMessagePort = async (port, viewletCommandMap) => {
1672
1672
  },
1673
1673
  messagePort: port
1674
1674
  });
1675
- set(rpc);
1675
+ if (setAsRendererProcess) {
1676
+ set(rpc);
1677
+ }
1676
1678
  };
1677
1679
 
1678
1680
  const setBadgeCount = (state, id, count) => {
@@ -2449,7 +2451,7 @@ const selectName = async (state, name) => {
2449
2451
  return selectIndex(state, index);
2450
2452
  };
2451
2453
 
2452
- const handleDirectMessagePort = port => handleMessagePort(port, commandMap);
2454
+ const handleDirectMessagePort = (port, setAsRendererProcess = true) => handleMessagePort(port, commandMap, setAsRendererProcess);
2453
2455
  const commandMap = {
2454
2456
  'Panel.create': create,
2455
2457
  'Panel.diff2': diff2,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/panel-worker",
3
- "version": "2.10.5",
3
+ "version": "2.11.0",
4
4
  "description": "Panel Worker",
5
5
  "repository": {
6
6
  "type": "git",