@lvce-editor/extension-host-worker 4.9.0 → 4.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.
@@ -2787,6 +2787,10 @@ const getRemoteUrl$1 = async (uri, options = {}) => {
2787
2787
  };
2788
2788
 
2789
2789
  // TODO pass uuid to allow having multiple webviews open at the same time
2790
+
2791
+ /**
2792
+ * @deprecated use iframe worker instead of creating and querying webviews
2793
+ */
2790
2794
  const createWebView = async (providerId, port, uri, uid, origin, webView) => {
2791
2795
  const provider = getProvider(providerId);
2792
2796
  if (!provider) {
@@ -2818,9 +2822,17 @@ const disposeWebView = id => {
2818
2822
  // TODO race condition
2819
2823
  // const webView=webViews[id]
2820
2824
  };
2825
+
2826
+ /**
2827
+ * @deprecated use iframe worker instead of creating and querying webviews
2828
+ */
2821
2829
  const registerWebViewProvider = provider => {
2822
2830
  setProvider(provider.id, provider);
2823
2831
  };
2832
+
2833
+ /**
2834
+ * @deprecated use iframe worker instead of creating and querying webviews
2835
+ */
2824
2836
  const getWebViewInfo = providerId => {
2825
2837
  const webView = getWebView(providerId);
2826
2838
  if (!webView) {
@@ -4838,6 +4850,10 @@ const getRpcInfo = rpcId => {
4838
4850
  return info;
4839
4851
  };
4840
4852
 
4853
+ const getWebViewInfo2 = providerId => {
4854
+ return invoke('WebView.getWebViewInfo', providerId);
4855
+ };
4856
+
4841
4857
  const getRemoteUrl = uri => {
4842
4858
  return `/remote/${uri}`;
4843
4859
  };
@@ -5328,14 +5344,6 @@ const textSearch$2 = async (scheme, root, query, options, assetDir) => {
5328
5344
  return allResults;
5329
5345
  };
5330
5346
 
5331
- const getChildHandles = async handle => {
5332
- try {
5333
- return await getChildHandles$1(handle);
5334
- } catch (error) {
5335
- throw new VError(error, 'failed to get child handles');
5336
- }
5337
- };
5338
-
5339
5347
  const getDirectoryHandle = async uri => {
5340
5348
  const handle = await getHandle(uri);
5341
5349
  if (handle) {
@@ -5348,6 +5356,14 @@ const getDirectoryHandle = async uri => {
5348
5356
  return getDirectoryHandle(dirname$1);
5349
5357
  };
5350
5358
 
5359
+ const getChildHandles = async handle => {
5360
+ try {
5361
+ return await getChildHandles$1(handle);
5362
+ } catch (error) {
5363
+ throw new VError(error, 'failed to get child handles');
5364
+ }
5365
+ };
5366
+
5351
5367
  const NotReadableError = 'NotReadableError';
5352
5368
 
5353
5369
  const isNotReadableError = error => {
@@ -5390,6 +5406,7 @@ const textSearchRecursively = async (all, parent, handle, query) => {
5390
5406
  }
5391
5407
  await Promise.all(promises);
5392
5408
  };
5409
+
5393
5410
  const textSearch$1 = async (scheme, root, query) => {
5394
5411
  string(scheme);
5395
5412
  string(root);
@@ -5445,11 +5462,27 @@ const commandMap = {
5445
5462
  'ColorTheme.getColorThemeNames': getColorThemeNames,
5446
5463
  'ColorTheme.hydrate': hydrate$1,
5447
5464
  'ExtensionHost.launchIframeWorker': launchIframeWorker,
5465
+ 'ExtensionHostDebug.evaluate': evaluate,
5466
+ 'ExtensionHostDebug.getProperties': getProperties,
5467
+ 'ExtensionHostDebug.listProcesses': listProcesses,
5468
+ 'ExtensionHostDebug.pause': pause,
5469
+ 'ExtensionHostDebug.resume': resume,
5470
+ 'ExtensionHostDebug.setPauseOnException': setPauseOnException,
5471
+ 'ExtensionHostDebug.setPauseOnExceptions': setPauseOnExceptions,
5472
+ 'ExtensionHostDebug.start': start,
5473
+ 'ExtensionHostDebug.stepInto': stepInto,
5474
+ 'ExtensionHostDebug.stepOut': stepOut,
5475
+ 'ExtensionHostDebug.stepOver': stepOver,
5448
5476
  'ExtensionHostRename.executeprepareRenameProvider': executeprepareRenameProvider,
5449
5477
  'ExtensionHostRename.executeRenameProvider': executeRenameProvider,
5450
- 'Extensions.getExtensions': getExtensions,
5451
- 'Extensions.getExtension': getExtension,
5478
+ 'ExtensionHostWebView.create': createWebView,
5479
+ 'ExtensionHostWebView.dispose': disposeWebView,
5480
+ 'ExtensionHostWebView.getWebViewInfo': getWebViewInfo,
5481
+ 'ExtensionHostWebView.getWebViewInfo2': getWebViewInfo2,
5482
+ 'ExtensionHostWebView.load': loadWebView,
5452
5483
  'Extensions.addWebExtension': addWebExtension,
5484
+ 'Extensions.getExtension': getExtension,
5485
+ 'Extensions.getExtensions': getExtensions,
5453
5486
  'FileSystemFetch.chmod': chmod$1,
5454
5487
  'FileSystemFetch.getBlob': getBlob$1,
5455
5488
  'FileSystemFetch.mkdir': mkdir$1,
@@ -5466,6 +5499,8 @@ const commandMap = {
5466
5499
  'FileSystemMemory.readFile': readFile,
5467
5500
  'FileSystemMemory.remove': remove,
5468
5501
  'FileSystemMemory.writeFile': writeFile,
5502
+ 'HandleBeforeUnload.handleBeforeUnload': handleBeforeUnload,
5503
+ 'HandleMessagePort.handleMessagePort': handleMessagePort,
5469
5504
  'IconTheme.getJson': getIconThemeJson,
5470
5505
  'IconTheme.getState': getState,
5471
5506
  'IconTheme.hydrate': hydrate,
@@ -5478,6 +5513,7 @@ const commandMap = {
5478
5513
  'IndexedDb.saveValue': saveValue,
5479
5514
  'IndexedDb.set': set$3,
5480
5515
  'Languages.getLanguages': getLanguages,
5516
+ 'SaveState.saveState': saveState,
5481
5517
  'SearchFileWithFetch.searchFileWithFetch': searchFile$1,
5482
5518
  'SearchFileWithHtml.searchFileWithHtml': searchFile,
5483
5519
  'TextSearchFetch.textSearch': textSearch$2,
@@ -5488,24 +5524,6 @@ const commandMap = {
5488
5524
  'WebView.createWebViewWorkerRpc2': createWebViewWorkerRpc2,
5489
5525
  'WebView.getRpcInfo': getRpcInfo,
5490
5526
  'WebViews.getWebViews': getWebViews,
5491
- ['ExtensionHostDebug.evaluate']: evaluate,
5492
- ['ExtensionHostDebug.getProperties']: getProperties,
5493
- ['ExtensionHostDebug.listProcesses']: listProcesses,
5494
- ['ExtensionHostDebug.pause']: pause,
5495
- ['ExtensionHostDebug.resume']: resume,
5496
- ['ExtensionHostDebug.setPauseOnException']: setPauseOnException,
5497
- ['ExtensionHostDebug.setPauseOnExceptions']: setPauseOnExceptions,
5498
- ['ExtensionHostDebug.start']: start,
5499
- ['ExtensionHostDebug.stepInto']: stepInto,
5500
- ['ExtensionHostDebug.stepOut']: stepOut,
5501
- ['ExtensionHostDebug.stepOver']: stepOver,
5502
- ['ExtensionHostWebView.create']: createWebView,
5503
- ['ExtensionHostWebView.dispose']: disposeWebView,
5504
- ['ExtensionHostWebView.getWebViewInfo']: getWebViewInfo,
5505
- ['ExtensionHostWebView.load']: loadWebView,
5506
- ['HandleBeforeUnload.handleBeforeUnload']: handleBeforeUnload,
5507
- ['HandleMessagePort.handleMessagePort']: handleMessagePort,
5508
- ['SaveState.saveState']: saveState,
5509
5527
  [BraceCompletionExecuteBraceCompletionProvider]: executeBraceCompletionProvider,
5510
5528
  [ClosingTagExecuteClosingTagProvider]: executeClosingTagProvider,
5511
5529
  [CommandExecute]: executeCommand,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/extension-host-worker",
3
- "version": "4.9.0",
3
+ "version": "4.11.0",
4
4
  "description": "Webworker for the extension host functionality in Lvce Editor.",
5
5
  "keywords": [
6
6
  "web-worker"