@lvce-editor/editor-worker 18.5.0 → 18.7.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.
@@ -63,7 +63,7 @@ class AssertionError extends Error {
63
63
  const Object$1 = 1;
64
64
  const Number$1 = 2;
65
65
  const Array$1 = 3;
66
- const String = 4;
66
+ const String$1 = 4;
67
67
  const Boolean$1 = 5;
68
68
  const Function$1 = 6;
69
69
  const Null = 7;
@@ -75,7 +75,7 @@ const getType = value => {
75
75
  case 'function':
76
76
  return Function$1;
77
77
  case 'string':
78
- return String;
78
+ return String$1;
79
79
  case 'object':
80
80
  if (value === null) {
81
81
  return Null;
@@ -110,7 +110,7 @@ const array = value => {
110
110
  };
111
111
  const string = value => {
112
112
  const type = getType(value);
113
- if (type !== String) {
113
+ if (type !== String$1) {
114
114
  throw new AssertionError('expected value to be of type string');
115
115
  }
116
116
  };
@@ -553,7 +553,7 @@ const execute$1 = (command, ...args) => {
553
553
 
554
554
  const Two$1 = '2.0';
555
555
  const callbacks = Object.create(null);
556
- const get$9 = id => {
556
+ const get$8 = id => {
557
557
  return callbacks[id];
558
558
  };
559
559
  const remove$9 = id => {
@@ -575,12 +575,12 @@ const getErrorConstructor = (message, type) => {
575
575
  switch (type) {
576
576
  case DomException:
577
577
  return DOMException;
578
- case TypeError$1:
579
- return TypeError;
580
- case SyntaxError$1:
581
- return SyntaxError;
582
578
  case ReferenceError$1:
583
579
  return ReferenceError;
580
+ case SyntaxError$1:
581
+ return SyntaxError;
582
+ case TypeError$1:
583
+ return TypeError;
584
584
  default:
585
585
  return Error;
586
586
  }
@@ -702,7 +702,7 @@ const warn$1 = (...args) => {
702
702
  console.warn(...args);
703
703
  };
704
704
  const resolve = (id, response) => {
705
- const fn = get$9(id);
705
+ const fn = get$8(id);
706
706
  if (!fn) {
707
707
  console.log(response);
708
708
  warn$1(`callback ${id} may already be disposed`);
@@ -736,27 +736,27 @@ const getErrorProperty = (error, prettyError) => {
736
736
  if (error && error.code === E_COMMAND_NOT_FOUND) {
737
737
  return {
738
738
  code: MethodNotFound,
739
- message: error.message,
740
- data: error.stack
739
+ data: error.stack,
740
+ message: error.message
741
741
  };
742
742
  }
743
743
  return {
744
744
  code: Custom,
745
- message: prettyError.message,
746
745
  data: {
747
- stack: getStack(prettyError),
748
- codeFrame: prettyError.codeFrame,
749
- type: getErrorType(prettyError),
750
746
  code: prettyError.code,
751
- name: prettyError.name
752
- }
747
+ codeFrame: prettyError.codeFrame,
748
+ name: prettyError.name,
749
+ stack: getStack(prettyError),
750
+ type: getErrorType(prettyError)
751
+ },
752
+ message: prettyError.message
753
753
  };
754
754
  };
755
755
  const create$1$1 = (id, error) => {
756
756
  return {
757
- jsonrpc: Two$1,
757
+ error,
758
758
  id,
759
- error
759
+ jsonrpc: Two$1
760
760
  };
761
761
  };
762
762
  const getErrorResponse = (id, error, preparePrettyError, logError) => {
@@ -767,8 +767,8 @@ const getErrorResponse = (id, error, preparePrettyError, logError) => {
767
767
  };
768
768
  const create$j = (message, result) => {
769
769
  return {
770
- jsonrpc: Two$1,
771
770
  id: message.id,
771
+ jsonrpc: Two$1,
772
772
  result: result ?? null
773
773
  };
774
774
  };
@@ -778,14 +778,14 @@ const getSuccessResponse = (message, result) => {
778
778
  };
779
779
  const getErrorResponseSimple = (id, error) => {
780
780
  return {
781
- jsonrpc: Two$1,
782
- id,
783
781
  error: {
784
782
  code: Custom,
783
+ data: error,
785
784
  // @ts-ignore
786
- message: error.message,
787
- data: error
788
- }
785
+ message: error.message
786
+ },
787
+ id,
788
+ jsonrpc: Two$1
789
789
  };
790
790
  };
791
791
  const getResponse = async (message, ipc, execute, preparePrettyError, logError, requiresSocket) => {
@@ -815,35 +815,35 @@ const normalizeParams = args => {
815
815
  if (args.length === 1) {
816
816
  const options = args[0];
817
817
  return {
818
+ execute: options.execute,
818
819
  ipc: options.ipc,
820
+ logError: options.logError || defaultLogError,
819
821
  message: options.message,
820
- execute: options.execute,
821
- resolve: options.resolve || defaultResolve,
822
822
  preparePrettyError: options.preparePrettyError || defaultPreparePrettyError,
823
- logError: options.logError || defaultLogError,
824
- requiresSocket: options.requiresSocket || defaultRequiresSocket
823
+ requiresSocket: options.requiresSocket || defaultRequiresSocket,
824
+ resolve: options.resolve || defaultResolve
825
825
  };
826
826
  }
827
827
  return {
828
+ execute: args[2],
828
829
  ipc: args[0],
830
+ logError: args[5],
829
831
  message: args[1],
830
- execute: args[2],
831
- resolve: args[3],
832
832
  preparePrettyError: args[4],
833
- logError: args[5],
834
- requiresSocket: args[6]
833
+ requiresSocket: args[6],
834
+ resolve: args[3]
835
835
  };
836
836
  };
837
837
  const handleJsonRpcMessage = async (...args) => {
838
838
  const options = normalizeParams(args);
839
839
  const {
840
- message,
841
- ipc,
842
840
  execute,
843
- resolve,
844
- preparePrettyError,
841
+ ipc,
845
842
  logError,
846
- requiresSocket
843
+ message,
844
+ preparePrettyError,
845
+ requiresSocket,
846
+ resolve
847
847
  } = options;
848
848
  if ('id' in message) {
849
849
  if ('method' in message) {
@@ -904,7 +904,6 @@ const registerPromise = map => {
904
904
  };
905
905
  };
906
906
 
907
- // @ts-ignore
908
907
  const invokeHelper = async (callbacks, ipc, method, params, useSendAndTransfer) => {
909
908
  const {
910
909
  id,
@@ -986,6 +985,41 @@ const listen$1 = async (module, options) => {
986
985
  return ipc;
987
986
  };
988
987
 
988
+ const create$f = async ({
989
+ commandMap,
990
+ isMessagePortOpen = true,
991
+ messagePort
992
+ }) => {
993
+ // TODO create a commandMap per rpc instance
994
+ register(commandMap);
995
+ const rawIpc = await IpcParentWithMessagePort$1.create({
996
+ isMessagePortOpen,
997
+ messagePort
998
+ });
999
+ const ipc = IpcParentWithMessagePort$1.wrap(rawIpc);
1000
+ handleIpc(ipc);
1001
+ const rpc = createRpc(ipc);
1002
+ messagePort.start();
1003
+ return rpc;
1004
+ };
1005
+
1006
+ const create$e = async ({
1007
+ commandMap,
1008
+ isMessagePortOpen,
1009
+ send
1010
+ }) => {
1011
+ const {
1012
+ port1,
1013
+ port2
1014
+ } = new MessageChannel();
1015
+ await send(port1);
1016
+ return create$f({
1017
+ commandMap,
1018
+ isMessagePortOpen,
1019
+ messagePort: port2
1020
+ });
1021
+ };
1022
+
989
1023
  const createSharedLazyRpc = factory => {
990
1024
  let rpcPromise;
991
1025
  const getOrCreate = () => {
@@ -1014,13 +1048,13 @@ const createSharedLazyRpc = factory => {
1014
1048
  };
1015
1049
  };
1016
1050
 
1017
- const create$f = async ({
1051
+ const create$d = async ({
1018
1052
  commandMap,
1019
1053
  isMessagePortOpen,
1020
1054
  send
1021
1055
  }) => {
1022
1056
  return createSharedLazyRpc(() => {
1023
- return create$c({
1057
+ return create$e({
1024
1058
  commandMap,
1025
1059
  isMessagePortOpen,
1026
1060
  send
@@ -1028,51 +1062,16 @@ const create$f = async ({
1028
1062
  });
1029
1063
  };
1030
1064
 
1031
- const create$e = async ({
1032
- commandMap,
1033
- isMessagePortOpen = true,
1034
- messagePort
1035
- }) => {
1036
- // TODO create a commandMap per rpc instance
1037
- register(commandMap);
1038
- const rawIpc = await IpcParentWithMessagePort$1.create({
1039
- isMessagePortOpen,
1040
- messagePort
1041
- });
1042
- const ipc = IpcParentWithMessagePort$1.wrap(rawIpc);
1043
- handleIpc(ipc);
1044
- const rpc = createRpc(ipc);
1045
- messagePort.start();
1046
- return rpc;
1047
- };
1048
-
1049
- const create$d = async ({
1065
+ const create$c = async ({
1050
1066
  commandMap,
1051
1067
  messagePort
1052
1068
  }) => {
1053
- return create$e({
1069
+ return create$f({
1054
1070
  commandMap,
1055
1071
  messagePort
1056
1072
  });
1057
1073
  };
1058
1074
 
1059
- const create$c = async ({
1060
- commandMap,
1061
- isMessagePortOpen,
1062
- send
1063
- }) => {
1064
- const {
1065
- port1,
1066
- port2
1067
- } = new MessageChannel();
1068
- await send(port1);
1069
- return create$e({
1070
- commandMap,
1071
- isMessagePortOpen,
1072
- messagePort: port2
1073
- });
1074
- };
1075
-
1076
1075
  const create$b = async ({
1077
1076
  commandMap
1078
1077
  }) => {
@@ -1084,6 +1083,74 @@ const create$b = async ({
1084
1083
  return rpc;
1085
1084
  };
1086
1085
 
1086
+ const createMockRpc = ({
1087
+ commandMap
1088
+ }) => {
1089
+ const invocations = [];
1090
+ const invoke = (method, ...params) => {
1091
+ invocations.push([method, ...params]);
1092
+ const command = commandMap[method];
1093
+ if (!command) {
1094
+ throw new Error(`command ${method} not found`);
1095
+ }
1096
+ return command(...params);
1097
+ };
1098
+ const mockRpc = {
1099
+ invocations,
1100
+ invoke,
1101
+ invokeAndTransfer: invoke
1102
+ };
1103
+ return mockRpc;
1104
+ };
1105
+
1106
+ const rpcs = Object.create(null);
1107
+ const set$e = (id, rpc) => {
1108
+ rpcs[id] = rpc;
1109
+ };
1110
+ const get$7 = id => {
1111
+ return rpcs[id];
1112
+ };
1113
+ const remove$8 = id => {
1114
+ delete rpcs[id];
1115
+ };
1116
+
1117
+ /* eslint-disable @typescript-eslint/explicit-function-return-type */
1118
+ const create$a = rpcId => {
1119
+ return {
1120
+ async dispose() {
1121
+ const rpc = get$7(rpcId);
1122
+ await rpc.dispose();
1123
+ },
1124
+ // @ts-ignore
1125
+ invoke(method, ...params) {
1126
+ const rpc = get$7(rpcId);
1127
+ // @ts-ignore
1128
+ return rpc.invoke(method, ...params);
1129
+ },
1130
+ // @ts-ignore
1131
+ invokeAndTransfer(method, ...params) {
1132
+ const rpc = get$7(rpcId);
1133
+ // @ts-ignore
1134
+ return rpc.invokeAndTransfer(method, ...params);
1135
+ },
1136
+ registerMockRpc(commandMap) {
1137
+ const mockRpc = createMockRpc({
1138
+ commandMap
1139
+ });
1140
+ set$e(rpcId, mockRpc);
1141
+ // @ts-ignore
1142
+ mockRpc[Symbol.dispose] = () => {
1143
+ remove$8(rpcId);
1144
+ };
1145
+ // @ts-ignore
1146
+ return mockRpc;
1147
+ },
1148
+ set(rpc) {
1149
+ set$e(rpcId, rpc);
1150
+ }
1151
+ };
1152
+ };
1153
+
1087
1154
  const Text$1 = 12;
1088
1155
  const Reference = 100;
1089
1156
 
@@ -1136,8 +1203,6 @@ const Hover = 6;
1136
1203
  const Rename$1 = 7;
1137
1204
  const SourceAction$1 = 8;
1138
1205
 
1139
- const Script$1 = 2;
1140
-
1141
1206
  const CtrlCmd = 1 << 11 >>> 0;
1142
1207
  const Shift = 1 << 10 >>> 0;
1143
1208
  const Alt$1 = 1 << 9 >>> 0;
@@ -1166,557 +1231,120 @@ const SetPatches = 'Viewlet.setPatches';
1166
1231
  const FocusEditorText$1 = 12;
1167
1232
  const FocusExplorer = 13;
1168
1233
 
1169
- const createMockRpc = ({
1170
- commandMap
1171
- }) => {
1172
- const invocations = [];
1173
- const invoke = (method, ...params) => {
1174
- invocations.push([method, ...params]);
1175
- const command = commandMap[method];
1176
- if (!command) {
1177
- throw new Error(`command ${method} not found`);
1178
- }
1179
- return command(...params);
1180
- };
1181
- const mockRpc = {
1182
- invocations,
1183
- invoke,
1184
- invokeAndTransfer: invoke
1185
- };
1186
- return mockRpc;
1187
- };
1188
-
1189
- const rpcs = Object.create(null);
1190
- const set$f = (id, rpc) => {
1191
- rpcs[id] = rpc;
1192
- };
1193
- const get$8 = id => {
1194
- return rpcs[id];
1195
- };
1196
- const remove$8 = id => {
1197
- delete rpcs[id];
1198
- };
1199
-
1200
- /* eslint-disable @typescript-eslint/explicit-function-return-type */
1201
- const create$a = rpcId => {
1202
- return {
1203
- async dispose() {
1204
- const rpc = get$8(rpcId);
1205
- await rpc.dispose();
1206
- },
1207
- // @ts-ignore
1208
- invoke(method, ...params) {
1209
- const rpc = get$8(rpcId);
1210
- // @ts-ignore
1211
- return rpc.invoke(method, ...params);
1212
- },
1213
- // @ts-ignore
1214
- invokeAndTransfer(method, ...params) {
1215
- const rpc = get$8(rpcId);
1216
- // @ts-ignore
1217
- return rpc.invokeAndTransfer(method, ...params);
1218
- },
1219
- registerMockRpc(commandMap) {
1220
- const mockRpc = createMockRpc({
1221
- commandMap
1222
- });
1223
- set$f(rpcId, mockRpc);
1224
- // @ts-ignore
1225
- mockRpc[Symbol.dispose] = () => {
1226
- remove$8(rpcId);
1227
- };
1228
- // @ts-ignore
1229
- return mockRpc;
1230
- },
1231
- set(rpc) {
1232
- set$f(rpcId, rpc);
1233
- }
1234
- };
1235
- };
1236
-
1237
1234
  const {
1238
- dispose: dispose$3,
1239
1235
  invoke: invoke$f,
1240
- invokeAndTransfer: invokeAndTransfer$2,
1241
- registerMockRpc: registerMockRpc$1,
1242
- set: set$e
1236
+ set: set$d
1243
1237
  } = create$a(ExtensionHostWorker);
1244
- const executeReferenceProvider = async (id, offset) => {
1245
- // @ts-ignore
1246
- return invoke$f('ExtensionHostReference.executeReferenceProvider', id, offset);
1247
- };
1248
- const executeFileReferenceProvider = async id => {
1249
- // @ts-ignore
1250
- return invoke$f('ExtensionHostReference.executeFileReferenceProvider', id);
1251
- };
1252
- const getRuntimeStatus = async extensionId => {
1253
- // @ts-ignore
1254
- return invoke$f('ExtensionHost.getRuntimeStatus', extensionId);
1255
- };
1256
- const getEnabledOutputProviderIds = async () => {
1257
- const channels = await invoke$f('Output.getEnabledProviders');
1258
- return channels;
1259
- };
1260
1238
 
1261
1239
  const ExtensionHost = {
1262
1240
  __proto__: null,
1263
- dispose: dispose$3,
1264
- executeFileReferenceProvider,
1265
- executeReferenceProvider,
1266
- getEnabledOutputProviderIds,
1267
- getRuntimeStatus,
1268
1241
  invoke: invoke$f,
1269
- invokeAndTransfer: invokeAndTransfer$2,
1270
- registerMockRpc: registerMockRpc$1,
1271
- set: set$e
1242
+ set: set$d
1272
1243
  };
1273
1244
 
1274
1245
  const {
1275
1246
  invoke: invoke$e,
1276
- set: set$d
1247
+ set: set$c
1277
1248
  } = create$a(ExtensionManagementWorker);
1278
1249
  const getLanguages$1 = (platform, assetDir) => {
1279
1250
  return invoke$e('Extensions.getLanguages', platform, assetDir);
1280
1251
  };
1281
1252
 
1282
1253
  const {
1283
- dispose: dispose$2,
1284
1254
  invoke: invoke$d,
1285
- invokeAndTransfer: invokeAndTransfer$1,
1286
- registerMockRpc,
1287
- set: set$c
1288
- } = create$a(RendererWorker$1);
1289
- const searchFileHtml = async uri => {
1290
- return invoke$d('ExtensionHost.searchFileWithHtml', uri);
1291
- };
1292
- const getFilePathElectron = async file => {
1293
- return invoke$d('FileSystemHandle.getFilePathElectron', file);
1294
- };
1295
- /**
1296
- * @deprecated
1297
- */
1298
- const showContextMenu = async (x, y, id, ...args) => {
1299
- return invoke$d('ContextMenu.show', x, y, id, ...args);
1255
+ set: set$b
1256
+ } = create$a(OpenerWorker);
1257
+ const openUrl = async (url, platform) => {
1258
+ return invoke$d('Open.openUrl', url, platform);
1300
1259
  };
1260
+
1261
+ const {
1262
+ invoke: invoke$c,
1263
+ invokeAndTransfer,
1264
+ set: set$a
1265
+ } = create$a(RendererWorker$1);
1301
1266
  const showContextMenu2 = async (uid, menuId, x, y, args) => {
1302
1267
  number(uid);
1303
1268
  number(menuId);
1304
1269
  number(x);
1305
1270
  number(y);
1306
- await invoke$d('ContextMenu.show2', uid, menuId, x, y, args);
1307
- };
1308
- const getElectronVersion = async () => {
1309
- return invoke$d('Process.getElectronVersion');
1310
- };
1311
- const applyBulkReplacement = async bulkEdits => {
1312
- await invoke$d('BulkReplacement.applyBulkReplacement', bulkEdits);
1313
- };
1314
- const setColorTheme = async id => {
1315
- return invoke$d(/* ColorTheme.setColorTheme */'ColorTheme.setColorTheme', /* colorThemeId */id);
1316
- };
1317
- const getNodeVersion = async () => {
1318
- return invoke$d('Process.getNodeVersion');
1319
- };
1320
- const getBadgeCounts = async () => {
1321
- return invoke$d('Layout.getBadgeCounts');
1322
- };
1323
- const getChromeVersion = async () => {
1324
- return invoke$d('Process.getChromeVersion');
1325
- };
1326
- const getV8Version = async () => {
1327
- return invoke$d('Process.getV8Version');
1328
- };
1329
- const getFileHandles = async fileIds => {
1330
- const files = await invoke$d('FileSystemHandle.getFileHandles', fileIds);
1331
- return files;
1332
- };
1333
- const setWorkspacePath = async path => {
1334
- await invoke$d('Workspace.setPath', path);
1335
- };
1336
- const registerWebViewInterceptor = async (id, port) => {
1337
- await invokeAndTransfer$1('WebView.registerInterceptor', id, port);
1338
- };
1339
- const unregisterWebViewInterceptor = async id => {
1340
- await invoke$d('WebView.unregisterInterceptor', id);
1341
- };
1342
- const sendMessagePortToEditorWorker = async (port, rpcId) => {
1343
- const command = 'HandleMessagePort.handleMessagePort';
1344
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToEditorWorker', port, command, rpcId);
1345
- };
1346
- const sendMessagePortToClipBoardWorker = async (port, rpcId) => {
1347
- const command = 'ClipBoard.handleMessagePort';
1348
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToClipBoardWorker', port, command, rpcId);
1271
+ await invoke$c('ContextMenu.show2', uid, menuId, x, y, args);
1349
1272
  };
1350
1273
  const sendMessagePortToOpenerWorker = async (port, rpcId) => {
1351
1274
  const command = 'HandleMessagePort.handleMessagePort';
1352
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToOpenerWorker', port, command, rpcId);
1353
- };
1354
- const sendMessagePortToMainAreaWorker = async (port, rpcId) => {
1355
- const command = 'HandleMessagePort.handleMessagePort';
1356
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToMainAreaWorker', port, command, rpcId);
1357
- };
1358
- const sendMessagePortToErrorWorker = async (port, rpcId) => {
1359
- const command = 'Errors.handleMessagePort';
1360
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToErrorWorker', port, command, rpcId);
1361
- };
1362
- const sendMessagePortToMarkdownWorker = async (port, rpcId) => {
1363
- const command = 'Markdown.handleMessagePort';
1364
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToMarkdownWorker', port, command, rpcId);
1365
- };
1366
- const sendMessagePortToIconThemeWorker = async (port, rpcId) => {
1367
- const command = 'IconTheme.handleMessagePort';
1368
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToIconThemeWorker', port, command, rpcId);
1369
- };
1370
- const sendMessagePortToFileSystemWorker = async (port, rpcId) => {
1371
- const command = 'FileSystem.handleMessagePort';
1372
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToFileSystemWorker', port, command, rpcId);
1275
+ await invokeAndTransfer('SendMessagePortToExtensionHostWorker.sendMessagePortToOpenerWorker', port, command, rpcId);
1373
1276
  };
1374
1277
  const readFile = async uri => {
1375
- return invoke$d('FileSystem.readFile', uri);
1376
- };
1377
- const getWebViewSecret = async key => {
1378
- return invoke$d('WebView.getSecret', key);
1379
- };
1380
- const setWebViewPort = async (uid, port, origin, portType) => {
1381
- return invokeAndTransfer$1('WebView.setPort', uid, port, origin, portType);
1382
- };
1383
- const setFocus$1 = key => {
1384
- return invoke$d('Focus.setFocus', key);
1385
- };
1386
- const getFileIcon = async options => {
1387
- return invoke$d('IconTheme.getFileIcon', options);
1388
- };
1389
- const getColorThemeNames = async () => {
1390
- return invoke$d('ColorTheme.getColorThemeNames');
1391
- };
1392
- const disableExtension = async id => {
1393
- return invoke$d('ExtensionManagement.disable', id);
1394
- };
1395
- const enableExtension = async id => {
1396
- return invoke$d('ExtensionManagement.enable', id);
1397
- };
1398
- const handleDebugChange = async params => {
1399
- return invoke$d('Run And Debug.handleChange', params);
1400
- };
1401
- const getFolderIcon = async options => {
1402
- return invoke$d('IconTheme.getFolderIcon', options);
1278
+ return invoke$c('FileSystem.readFile', uri);
1403
1279
  };
1404
1280
  const handleWorkspaceRefresh = async () => {
1405
- return invoke$d('Layout.handleWorkspaceRefresh');
1406
- };
1407
- const closeWidget = async widgetId => {
1408
- return invoke$d('Viewlet.closeWidget', widgetId);
1281
+ return invoke$c('Layout.handleWorkspaceRefresh');
1409
1282
  };
1410
1283
  const sendMessagePortToExtensionHostWorker = async (port, rpcId = 0) => {
1411
1284
  const command = 'HandleMessagePort.handleMessagePort2';
1412
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToExtensionHostWorker', port, command, rpcId);
1413
- };
1414
- const sendMessagePortToFileSearchWorker = async (port, rpcId = 0) => {
1415
- const command = 'QuickPick.handleMessagePort';
1416
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToFileSearchWorker', port, command, rpcId);
1417
- };
1418
- const sendMessagePortToSearchProcess = async port => {
1419
- await invokeAndTransfer$1('SendMessagePortToElectron.sendMessagePortToElectron', port, 'HandleMessagePortForSearchProcess.handleMessagePortForSearchProcess');
1420
- };
1421
- const confirm = async (message, options) => {
1422
- const result = await invoke$d('ConfirmPrompt.prompt', message, options);
1423
- return result;
1424
- };
1425
- const getRecentlyOpened = async () => {
1426
- return invoke$d(/* RecentlyOpened.getRecentlyOpened */'RecentlyOpened.getRecentlyOpened');
1427
- };
1428
- const getKeyBindings$1 = async () => {
1429
- return invoke$d('KeyBindingsInitial.getKeyBindings');
1285
+ await invokeAndTransfer('SendMessagePortToExtensionHostWorker.sendMessagePortToExtensionHostWorker', port, command, rpcId);
1430
1286
  };
1431
1287
  const writeClipBoardText = async text => {
1432
- await invoke$d('ClipBoard.writeText', /* text */text);
1288
+ await invoke$c('ClipBoard.writeText', /* text */text);
1433
1289
  };
1434
1290
  const readClipBoardText = async () => {
1435
- return invoke$d('ClipBoard.readText');
1436
- };
1437
- const writeClipBoardImage = async blob => {
1438
- await invoke$d('ClipBoard.writeImage', /* text */blob);
1439
- };
1440
- const searchFileMemory = async uri => {
1441
- return invoke$d('ExtensionHost.searchFileWithMemory', uri);
1442
- };
1443
- const searchFileFetch = async uri => {
1444
- return invoke$d('ExtensionHost.searchFileWithFetch', uri);
1445
- };
1446
- const showMessageBox = async options => {
1447
- return invoke$d('ElectronDialog.showMessageBox', options);
1448
- };
1449
- const handleDebugResumed = async params => {
1450
- await invoke$d('Run And Debug.handleResumed', params);
1451
- };
1452
- const openWidget = async name => {
1453
- await invoke$d('Viewlet.openWidget', name);
1454
- };
1455
- const getIcons = async requests => {
1456
- const icons = await invoke$d('IconTheme.getIcons', requests);
1457
- return icons;
1291
+ return invoke$c('ClipBoard.readText');
1458
1292
  };
1459
1293
  const activateByEvent$1 = (event, assetDir, platform) => {
1460
- return invoke$d('ExtensionHostManagement.activateByEvent', event, assetDir, platform);
1461
- };
1462
- const setAdditionalFocus = focusKey => {
1463
- return invoke$d('Focus.setAdditionalFocus', focusKey);
1464
- };
1465
- const getActiveEditorId = () => {
1466
- return invoke$d('GetActiveEditor.getActiveEditorId');
1467
- };
1468
- const getWorkspacePath = () => {
1469
- return invoke$d('Workspace.getPath');
1470
- };
1471
- const sendMessagePortToRendererProcess = async port => {
1472
- const command = 'HandleMessagePort.handleMessagePort';
1473
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToRendererProcess', port, command, DebugWorker);
1294
+ return invoke$c('ExtensionHostManagement.activateByEvent', event, assetDir, platform);
1474
1295
  };
1475
1296
  const sendMessagePortToTextMeasurementWorker = async port => {
1476
1297
  const command = 'TextMeasurement.handleMessagePort';
1477
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToTextMeasurementWorker', port, command, 0);
1478
- };
1479
- const sendMessagePortToSourceControlWorker = async port => {
1480
- const command = 'SourceControl.handleMessagePort';
1481
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToSourceControlWorker', port, command, 0);
1482
- };
1483
- const sendMessagePortToSharedProcess = async port => {
1484
- const command = 'HandleElectronMessagePort.handleElectronMessagePort';
1485
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToSharedProcess', port, command, 0);
1486
- };
1487
- const sendMessagePortToFileSystemProcess = async (port, rpcId) => {
1488
- const command = 'HandleMessagePortForFileSystemProcess.handleMessagePortForFileSystemProcess';
1489
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToSharedProcess', port, command, rpcId);
1490
- };
1491
- const sendMessagePortToIframeWorker = async (port, rpcId) => {
1492
- const command = 'Iframes.handleMessagePort';
1493
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToIframeWorker', port, command, rpcId);
1298
+ await invokeAndTransfer('SendMessagePortToExtensionHostWorker.sendMessagePortToTextMeasurementWorker', port, command, 0);
1494
1299
  };
1495
1300
  const sendMessagePortToExtensionManagementWorker = async (port, rpcId) => {
1496
1301
  const command = 'Extensions.handleMessagePort';
1497
- await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToExtensionManagementWorker', port, command, rpcId);
1302
+ await invokeAndTransfer('SendMessagePortToExtensionHostWorker.sendMessagePortToExtensionManagementWorker', port, command, rpcId);
1498
1303
  };
1499
1304
  const getPreference = async key => {
1500
- return await invoke$d('Preferences.get', key);
1501
- };
1502
- const getAllExtensions = async () => {
1503
- return invoke$d('ExtensionManagement.getAllExtensions');
1504
- };
1505
- const rerenderEditor = async key => {
1506
- return invoke$d('Editor.rerender', key);
1507
- };
1508
- const handleDebugPaused = async params => {
1509
- await invoke$d('Run And Debug.handlePaused', params);
1305
+ return await invoke$c('Preferences.get', key);
1510
1306
  };
1511
1307
  const openUri = async (uri, focus, options) => {
1512
- await invoke$d('Main.openUri', uri, focus, options);
1308
+ await invoke$c('Main.openUri', uri, focus, options);
1513
1309
  };
1514
1310
  const sendMessagePortToSyntaxHighlightingWorker$1 = async port => {
1515
- await invokeAndTransfer$1('SendMessagePortToSyntaxHighlightingWorker.sendMessagePortToSyntaxHighlightingWorker', port, 'HandleMessagePort.handleMessagePort2');
1516
- };
1517
- const handleDebugScriptParsed = async script => {
1518
- await invoke$d('Run And Debug.handleScriptParsed', script);
1519
- };
1520
- const getWindowId = async () => {
1521
- return invoke$d('GetWindowId.getWindowId');
1522
- };
1523
- const getBlob = async uri => {
1524
- return invoke$d('FileSystem.getBlob', uri);
1525
- };
1526
- const getExtensionCommands = async () => {
1527
- return invoke$d('ExtensionHost.getCommands');
1528
- };
1529
- const showErrorDialog = async errorInfo => {
1530
- await invoke$d('ErrorHandling.showErrorDialog', errorInfo);
1531
- };
1532
- const getFolderSize = async uri => {
1533
- return await invoke$d('FileSystem.getFolderSize', uri);
1534
- };
1535
- const getExtension = async id => {
1536
- return invoke$d('ExtensionManagement.getExtension', id);
1537
- };
1538
- const getMarkdownDom = async html => {
1539
- return invoke$d('Markdown.getVirtualDom', html);
1540
- };
1541
- const renderMarkdown = async (markdown, options) => {
1542
- return invoke$d('Markdown.renderMarkdown', markdown, options);
1543
- };
1544
- const openNativeFolder = async uri => {
1545
- await invoke$d('OpenNativeFolder.openNativeFolder', uri);
1546
- };
1547
- const uninstallExtension = async id => {
1548
- return invoke$d('ExtensionManagement.uninstall', id);
1549
- };
1550
- const installExtension = async id => {
1551
- return invoke$d('ExtensionManagement.install', id);
1552
- };
1553
- const minimizeWindow = async () => {
1554
- return invoke$d('ElectronWindow.minimize');
1555
- };
1556
- const unmaximizeWindow = async () => {
1557
- return invoke$d('ElectronWindow.unmaximize');
1558
- };
1559
- const maximizeWindow = async () => {
1560
- return invoke$d('ElectronWindow.maximize');
1561
- };
1562
- const closeWindow = async () => {
1563
- return invoke$d('ElectronWindow.close');
1564
- };
1565
- const openExtensionSearch = async () => {
1566
- return invoke$d('SideBar.openViewlet', 'Extensions');
1567
- };
1568
- const setExtensionsSearchValue = async searchValue => {
1569
- return invoke$d('Extensions.handleInput', searchValue, Script$1);
1570
- };
1571
- const openExternal$1 = async uri => {
1572
- await invoke$d('Open.openExternal', uri);
1573
- };
1574
- const openUrl$1 = async uri => {
1575
- await invoke$d('Open.openUrl', uri);
1576
- };
1577
- const getAllPreferences = async () => {
1578
- return invoke$d('Preferences.getAll');
1579
- };
1580
- const showSaveFilePicker = async () => {
1581
- return invoke$d('FilePicker.showSaveFilePicker');
1582
- };
1583
- const getLogsDir = async () => {
1584
- return invoke$d('PlatformPaths.getLogsDir');
1585
- };
1586
- const measureTextBlockHeight$1 = async (actualInput, fontFamily, fontSize, lineHeightPx, width) => {
1587
- return invoke$d(`MeasureTextHeight.measureTextBlockHeight`, actualInput, fontFamily, fontSize, lineHeightPx, width);
1588
- };
1589
- const refreshOutput = async () => {
1590
- await invoke$d('Output.refresh');
1311
+ await invokeAndTransfer('SendMessagePortToSyntaxHighlightingWorker.sendMessagePortToSyntaxHighlightingWorker', port, 'HandleMessagePort.handleMessagePort2');
1591
1312
  };
1592
1313
 
1593
1314
  const RendererWorker = {
1594
1315
  __proto__: null,
1595
1316
  activateByEvent: activateByEvent$1,
1596
- applyBulkReplacement,
1597
- closeWidget,
1598
- closeWindow,
1599
- confirm,
1600
- disableExtension,
1601
- dispose: dispose$2,
1602
- enableExtension,
1603
- getActiveEditorId,
1604
- getAllExtensions,
1605
- getAllPreferences,
1606
- getBadgeCounts,
1607
- getBlob,
1608
- getChromeVersion,
1609
- getColorThemeNames,
1610
- getElectronVersion,
1611
- getExtension,
1612
- getExtensionCommands,
1613
- getFileHandles,
1614
- getFileIcon,
1615
- getFilePathElectron,
1616
- getFolderIcon,
1617
- getFolderSize,
1618
- getIcons,
1619
- getKeyBindings: getKeyBindings$1,
1620
- getLogsDir,
1621
- getMarkdownDom,
1622
- getNodeVersion,
1623
1317
  getPreference,
1624
- getRecentlyOpened,
1625
- getV8Version,
1626
- getWebViewSecret,
1627
- getWindowId,
1628
- getWorkspacePath,
1629
- handleDebugChange,
1630
- handleDebugPaused,
1631
- handleDebugResumed,
1632
- handleDebugScriptParsed,
1633
1318
  handleWorkspaceRefresh,
1634
- installExtension,
1635
- invoke: invoke$d,
1636
- invokeAndTransfer: invokeAndTransfer$1,
1637
- maximizeWindow,
1638
- measureTextBlockHeight: measureTextBlockHeight$1,
1639
- minimizeWindow,
1640
- openExtensionSearch,
1641
- openExternal: openExternal$1,
1642
- openNativeFolder,
1319
+ invoke: invoke$c,
1320
+ invokeAndTransfer,
1643
1321
  openUri,
1644
- openUrl: openUrl$1,
1645
- openWidget,
1646
1322
  readClipBoardText,
1647
1323
  readFile,
1648
- refreshOutput,
1649
- registerMockRpc,
1650
- registerWebViewInterceptor,
1651
- renderMarkdown,
1652
- rerenderEditor,
1653
- searchFileFetch,
1654
- searchFileHtml,
1655
- searchFileMemory,
1656
- sendMessagePortToClipBoardWorker,
1657
- sendMessagePortToEditorWorker,
1658
- sendMessagePortToErrorWorker,
1659
1324
  sendMessagePortToExtensionHostWorker,
1660
1325
  sendMessagePortToExtensionManagementWorker,
1661
- sendMessagePortToFileSearchWorker,
1662
- sendMessagePortToFileSystemProcess,
1663
- sendMessagePortToFileSystemWorker,
1664
- sendMessagePortToIconThemeWorker,
1665
- sendMessagePortToIframeWorker,
1666
- sendMessagePortToMainAreaWorker,
1667
- sendMessagePortToMarkdownWorker,
1668
1326
  sendMessagePortToOpenerWorker,
1669
- sendMessagePortToRendererProcess,
1670
- sendMessagePortToSearchProcess,
1671
- sendMessagePortToSharedProcess,
1672
- sendMessagePortToSourceControlWorker,
1673
1327
  sendMessagePortToSyntaxHighlightingWorker: sendMessagePortToSyntaxHighlightingWorker$1,
1674
1328
  sendMessagePortToTextMeasurementWorker,
1675
- set: set$c,
1676
- setAdditionalFocus,
1677
- setColorTheme,
1678
- setExtensionsSearchValue,
1679
- setFocus: setFocus$1,
1680
- setWebViewPort,
1681
- setWorkspacePath,
1682
- showContextMenu,
1329
+ set: set$a,
1683
1330
  showContextMenu2,
1684
- showErrorDialog,
1685
- showMessageBox,
1686
- showSaveFilePicker,
1687
- uninstallExtension,
1688
- unmaximizeWindow,
1689
- unregisterWebViewInterceptor,
1690
- writeClipBoardImage,
1691
1331
  writeClipBoardText
1692
1332
  };
1693
1333
 
1694
- const {
1695
- invoke: invoke$c,
1696
- set: set$b
1697
- } = create$a(OpenerWorker);
1698
- const openUrl = async (url, platform) => {
1699
- return invoke$c('Open.openUrl', url, platform);
1700
- };
1701
-
1702
1334
  const {
1703
1335
  invoke: invoke$b,
1704
- set: set$a
1336
+ set: set$9
1705
1337
  } = create$a(IconThemeWorker);
1706
1338
 
1707
1339
  const {
1708
- dispose: dispose$1,
1709
1340
  invoke: invoke$a,
1710
- invokeAndTransfer,
1711
- set: set$9
1341
+ set: set$8
1712
1342
  } = create$a(MarkdownWorker);
1713
1343
 
1714
1344
  const SyntaxHighlightingWorker = {
1715
1345
  __proto__: null,
1716
- dispose: dispose$1,
1717
1346
  invoke: invoke$a,
1718
- invokeAndTransfer,
1719
- set: set$9
1347
+ set: set$8
1720
1348
  };
1721
1349
 
1722
1350
  const createLazyRpc = rpcId => {
@@ -1724,7 +1352,7 @@ const createLazyRpc = rpcId => {
1724
1352
  let factory;
1725
1353
  const createRpc = async () => {
1726
1354
  const rpc = await factory();
1727
- set$f(rpcId, rpc);
1355
+ set$e(rpcId, rpc);
1728
1356
  };
1729
1357
  const ensureRpc = async () => {
1730
1358
  if (!rpcPromise) {
@@ -1735,12 +1363,12 @@ const createLazyRpc = rpcId => {
1735
1363
  return {
1736
1364
  async invoke(method, ...params) {
1737
1365
  await ensureRpc();
1738
- const rpc = get$8(rpcId);
1366
+ const rpc = get$7(rpcId);
1739
1367
  return rpc.invoke(method, ...params);
1740
1368
  },
1741
1369
  async invokeAndTransfer(method, ...params) {
1742
1370
  await ensureRpc();
1743
- const rpc = get$8(rpcId);
1371
+ const rpc = get$7(rpcId);
1744
1372
  return rpc.invokeAndTransfer(method, ...params);
1745
1373
  },
1746
1374
  setFactory(value) {
@@ -1789,7 +1417,7 @@ const create$9 = () => {
1789
1417
  },
1790
1418
  getKeys() {
1791
1419
  return Object.keys(states).map(key => {
1792
- return Number.parseInt(key);
1420
+ return Number.parseFloat(key);
1793
1421
  });
1794
1422
  },
1795
1423
  registerCommands(commandMap) {
@@ -1831,6 +1459,37 @@ const create$9 = () => {
1831
1459
  return fn(newState, ...args);
1832
1460
  };
1833
1461
  return wrapped;
1462
+ },
1463
+ wrapLoadContent(fn) {
1464
+ const wrapped = async (uid, ...args) => {
1465
+ const {
1466
+ newState,
1467
+ oldState
1468
+ } = states[uid];
1469
+ const result = await fn(newState, ...args);
1470
+ const {
1471
+ error,
1472
+ state
1473
+ } = result;
1474
+ if (oldState === state || newState === state) {
1475
+ return {
1476
+ error
1477
+ };
1478
+ }
1479
+ const latestOld = states[uid];
1480
+ const latestNew = {
1481
+ ...latestOld.newState,
1482
+ ...state
1483
+ };
1484
+ states[uid] = {
1485
+ newState: latestNew,
1486
+ oldState: latestOld.oldState
1487
+ };
1488
+ return {
1489
+ error
1490
+ };
1491
+ };
1492
+ return wrapped;
1834
1493
  }
1835
1494
  };
1836
1495
  };
@@ -1854,11 +1513,11 @@ const codeGeneratorAccept = state => {
1854
1513
  const ModuleWorkerAndWorkaroundForChromeDevtoolsBug = 6;
1855
1514
 
1856
1515
  const launchWorker = async (name, url, intializeCommand) => {
1857
- const rpc = await create$c({
1516
+ const rpc = await create$e({
1858
1517
  commandMap: {},
1859
1518
  isMessagePortOpen: true,
1860
1519
  async send(port) {
1861
- await invokeAndTransfer$1('IpcParent.create', {
1520
+ await invokeAndTransfer('IpcParent.create', {
1862
1521
  method: ModuleWorkerAndWorkaroundForChromeDevtoolsBug,
1863
1522
  name,
1864
1523
  port,
@@ -1909,14 +1568,23 @@ const loadContent$3 = async (state, parentUid) => {
1909
1568
  };
1910
1569
  };
1911
1570
 
1571
+ const editorStates = create$9();
1912
1572
  const {
1913
- get: get$7,
1914
1573
  getCommandIds,
1915
1574
  registerCommands,
1916
- set: set$8,
1917
- wrapCommand: wrapCommand$1,
1575
+ wrapCommand,
1918
1576
  wrapGetter
1919
- } = create$9();
1577
+ } = editorStates;
1578
+ const get$6 = id => {
1579
+ return editorStates.get(id);
1580
+ };
1581
+ const getKeys$2 = () => {
1582
+ const keys = editorStates.getKeys();
1583
+ return keys.map(String);
1584
+ };
1585
+ const set$7 = (id, oldEditor, newEditor) => {
1586
+ editorStates.set(id, oldEditor, newEditor);
1587
+ };
1920
1588
 
1921
1589
  const emptyIncrementalEdits = [];
1922
1590
 
@@ -2001,7 +1669,7 @@ const createEditor2 = (id, uri, x, y, width, height, platform, assetDir) => {
2001
1669
  x,
2002
1670
  y
2003
1671
  };
2004
- set$8(id, editor, editor);
1672
+ set$7(id, editor, editor);
2005
1673
  };
2006
1674
 
2007
1675
  // TODO use numeric enum
@@ -2024,15 +1692,15 @@ const Rename = 'rename';
2024
1692
  const ToggleBlockComment$1 = 'toggleBlockComment';
2025
1693
 
2026
1694
  const map$1 = Object.create(null);
2027
- const set$7 = (id, widget) => {
1695
+ const set$6 = (id, widget) => {
2028
1696
  map$1[id] = widget;
2029
1697
  };
2030
- const get$6 = id => {
1698
+ const get$5 = id => {
2031
1699
  return map$1[id];
2032
1700
  };
2033
1701
 
2034
1702
  const getModule = id => {
2035
- return get$6(id);
1703
+ return get$5(id);
2036
1704
  };
2037
1705
 
2038
1706
  const applyWidgetChange = async (editor, widget, changes) => {
@@ -2064,23 +1732,6 @@ const applyWidgetChanges = async (editor, changes) => {
2064
1732
  return latestEditor;
2065
1733
  };
2066
1734
 
2067
- const editors = Object.create(null);
2068
- const get$5 = id => {
2069
- number(id);
2070
- return editors[id];
2071
- };
2072
- const getKeys$2 = () => {
2073
- return Object.keys(editors);
2074
- };
2075
- const set$6 = (id, oldEditor, newEditor) => {
2076
- object(oldEditor);
2077
- object(newEditor);
2078
- editors[id] = {
2079
- newState: newEditor,
2080
- oldState: oldEditor
2081
- };
2082
- };
2083
-
2084
1735
  const clamp = (num, min, max) => {
2085
1736
  number(num);
2086
1737
  number(min);
@@ -3378,7 +3029,7 @@ const notifyListeners = async (listenerType, method, ...params) => {
3378
3029
  // Notify all listeners in parallel
3379
3030
  const notifications = rpcIds.map(async rpcId => {
3380
3031
  try {
3381
- const rpc = get$8(rpcId);
3032
+ const rpc = get$7(rpcId);
3382
3033
  if (rpc) {
3383
3034
  await rpc.invoke(method, ...params);
3384
3035
  }
@@ -3819,7 +3470,7 @@ const scheduleDocumentAndCursorsSelections = async (editor, changes, selectionCh
3819
3470
  ...newEditor,
3820
3471
  decorations: linkDecorations
3821
3472
  };
3822
- set$6(editor.uid, editor, newEditorWithDecorations);
3473
+ set$7(editor.uid, editor, newEditorWithDecorations);
3823
3474
 
3824
3475
  // Notify main-area-worker about modified status change
3825
3476
  if (!editor.modified) {
@@ -4228,7 +3879,7 @@ const updateDiagnostics = async newState => {
4228
3879
  // @ts-ignore
4229
3880
  await invoke$6(TextDocumentSyncFull, newState.uri, newState.id, newState.languageId, content);
4230
3881
  const diagnostics = await executeDiagnosticProvider(newState);
4231
- const latest = get$5(newState.id);
3882
+ const latest = get$6(newState.id);
4232
3883
  if (!latest) {
4233
3884
  return newState;
4234
3885
  }
@@ -4244,9 +3895,9 @@ const updateDiagnostics = async newState => {
4244
3895
  diagnostics,
4245
3896
  visualDecorations // Visual decorations (objects with x, y, width, height) for squiggly underlines
4246
3897
  };
4247
- set$6(newState.id, latest.oldState, newEditor);
3898
+ set$7(newState.id, latest.oldState, newEditor);
4248
3899
  // @ts-ignore
4249
- await invoke$d('Editor.rerender', newState.id);
3900
+ await invoke$c('Editor.rerender', newState.id);
4250
3901
  return newEditor;
4251
3902
  } catch (error) {
4252
3903
  // @ts-ignore
@@ -4391,7 +4042,7 @@ const createEditor = async ({
4391
4042
  focused: true,
4392
4043
  textInfos
4393
4044
  };
4394
- set$6(id, emptyEditor, newEditor4);
4045
+ set$7(id, emptyEditor, newEditor4);
4395
4046
 
4396
4047
  // TODO only sync when needed
4397
4048
  // e.g. it might not always be necessary to send text to extension host worker
@@ -4404,7 +4055,7 @@ const createEditor = async ({
4404
4055
  }
4405
4056
  const completionsOnTypeRaw = await get$1('editor.completionsOnType');
4406
4057
  const completionsOnType = Boolean(completionsOnTypeRaw);
4407
- set$6(id, emptyEditor, {
4058
+ set$7(id, emptyEditor, {
4408
4059
  ...newEditor4,
4409
4060
  completionsOnType
4410
4061
  });
@@ -4445,7 +4096,7 @@ const diff2 = uid => {
4445
4096
  const {
4446
4097
  newState,
4447
4098
  oldState
4448
- } = get$7(uid);
4099
+ } = get$6(uid);
4449
4100
  const result = diff(oldState, newState);
4450
4101
  return result;
4451
4102
  };
@@ -4753,6 +4404,7 @@ const at = async (editor, eventX, eventY) => {
4753
4404
  number(eventY);
4754
4405
  const {
4755
4406
  charWidth,
4407
+ deltaX,
4756
4408
  deltaY,
4757
4409
  fontFamily,
4758
4410
  fontSize,
@@ -4762,9 +4414,11 @@ const at = async (editor, eventX, eventY) => {
4762
4414
  lines,
4763
4415
  rowHeight,
4764
4416
  tabSize,
4417
+ x,
4765
4418
  y
4766
4419
  } = editor;
4767
4420
  const rowIndex = Math.floor((eventY - y + deltaY) / rowHeight);
4421
+ const relativeX = eventX - x + deltaX;
4768
4422
  if (rowIndex < 0) {
4769
4423
  return {
4770
4424
  columnIndex: 0,
@@ -4773,7 +4427,7 @@ const at = async (editor, eventX, eventY) => {
4773
4427
  }
4774
4428
  const clampedRowIndex = clamp(rowIndex, 0, lines.length - 1);
4775
4429
  const line = lines[clampedRowIndex];
4776
- const columnIndex = await getAccurateColumnIndex(line, fontWeight, fontSize, fontFamily, letterSpacing, isMonospaceFont, charWidth, tabSize, eventX);
4430
+ const columnIndex = await getAccurateColumnIndex(line, fontWeight, fontSize, fontFamily, letterSpacing, isMonospaceFont, charWidth, tabSize, relativeX);
4777
4431
  return {
4778
4432
  columnIndex,
4779
4433
  rowIndex: clampedRowIndex
@@ -4829,7 +4483,7 @@ const editorShowMessage = async (editor, rowIndex, columnIndex, message, isError
4829
4483
  const y$1 = y(editor, rowIndex);
4830
4484
  const displayErrorMessage = message;
4831
4485
  // @ts-ignore
4832
- await invoke$d('Editor.showOverlayMessage', editor, 'Viewlet.send', editor.uid, 'showOverlayMessage', x$1, y$1, displayErrorMessage);
4486
+ await invoke$c('Editor.showOverlayMessage', editor, 'Viewlet.send', editor.uid, 'showOverlayMessage', x$1, y$1, displayErrorMessage);
4833
4487
  if (!isError) {
4834
4488
  const handleTimeout = () => {
4835
4489
  editorHideMessage(editor);
@@ -4886,7 +4540,7 @@ const braceCompletion = async (editor, text) => {
4886
4540
  // @ts-ignore
4887
4541
  const offset = offsetAt(editor, editor.cursor);
4888
4542
  // @ts-ignore
4889
- const result = await invoke$d('ExtensionHostBraceCompletion.executeBraceCompletionProvider', editor, offset, text);
4543
+ const result = await invoke$c('ExtensionHostBraceCompletion.executeBraceCompletionProvider', editor, offset, text);
4890
4544
  if (result) {
4891
4545
  const closingBrace = getMatchingClosingBrace$1(text);
4892
4546
  const insertText = text + closingBrace;
@@ -5003,7 +4657,7 @@ const closeRename = async editor => {
5003
4657
  }
5004
4658
  const renameWidget = widgets[renameWidgetIndex];
5005
4659
  await invoke$5('Rename.close', renameWidget.newState.uid);
5006
- const latest = get$5(uid);
4660
+ const latest = get$6(uid);
5007
4661
  const {
5008
4662
  newState
5009
4663
  } = latest;
@@ -5819,7 +5473,7 @@ const deleteWordRight = editor => {
5819
5473
 
5820
5474
  const findAllReferences$1 = async editor => {
5821
5475
  // @ts-ignore
5822
- await invoke$d('SideBar.show', 'References', /* focus */true);
5476
+ await invoke$c('SideBar.show', 'References', /* focus */true);
5823
5477
  return editor;
5824
5478
  };
5825
5479
 
@@ -5907,7 +5561,7 @@ const getWordBefore = (editor, rowIndex, columnIndex) => {
5907
5561
  // @ts-ignore
5908
5562
  const getDefinition = async (editor, offset) => {
5909
5563
  // @ts-ignore
5910
- const definition = await invoke$d('ExtensionHostDefinition.executeDefinitionProvider', editor, offset);
5564
+ const definition = await invoke$c('ExtensionHostDefinition.executeDefinitionProvider', editor, offset);
5911
5565
  return definition;
5912
5566
  };
5913
5567
 
@@ -6192,7 +5846,7 @@ const getNoLocationFoundMessage = info => {
6192
5846
 
6193
5847
  const getTypeDefinition = async (editor, offset) => {
6194
5848
  // @ts-ignore
6195
- const definition = await invoke$d('ExtensionHostTypeDefinition.executeTypeDefinitionProvider', editor, offset);
5849
+ const definition = await invoke$c('ExtensionHostTypeDefinition.executeTypeDefinitionProvider', editor, offset);
6196
5850
  return definition;
6197
5851
  };
6198
5852
 
@@ -6973,7 +6627,7 @@ const indentMore = editor => {
6973
6627
 
6974
6628
  const getLanguageConfiguration = async editor => {
6975
6629
  // @ts-ignore
6976
- return invoke$d('Languages.getLanguageConfiguration', {
6630
+ return invoke$c('Languages.getLanguageConfiguration', {
6977
6631
  languageId: editor.languageId,
6978
6632
  uri: editor.uri
6979
6633
  });
@@ -7330,7 +6984,7 @@ const newStateGenerator$4 = async (state, parentUid) => {
7330
6984
  } = state;
7331
6985
  const {
7332
6986
  newState
7333
- } = get$5(parentUid);
6987
+ } = get$6(parentUid);
7334
6988
  const {
7335
6989
  languageId
7336
6990
  } = newState;
@@ -7383,18 +7037,18 @@ const launchFindWidgetWorker = async () => {
7383
7037
  const rpcId = 9002;
7384
7038
  const launch = async () => {
7385
7039
  // TODO race condition
7386
- if (get$8(rpcId)) {
7040
+ if (get$7(rpcId)) {
7387
7041
  return;
7388
7042
  }
7389
7043
  const rpc = await launchFindWidgetWorker();
7390
- set$f(rpcId, rpc);
7044
+ set$e(rpcId, rpc);
7391
7045
  };
7392
7046
  const invoke$3 = async (method, ...params) => {
7393
- const rpc = get$8(rpcId);
7047
+ const rpc = get$7(rpcId);
7394
7048
  return await rpc.invoke(method, ...params);
7395
7049
  };
7396
7050
  const dispose = async () => {
7397
- const rpc = get$8(rpcId);
7051
+ const rpc = get$7(rpcId);
7398
7052
  remove$8(rpcId);
7399
7053
  if (rpc) {
7400
7054
  await rpc.dispose();
@@ -7406,7 +7060,7 @@ const dispose = async () => {
7406
7060
  };
7407
7061
 
7408
7062
  const getEditor = editorUid => {
7409
- const instance = get$5(editorUid);
7063
+ const instance = get$6(editorUid);
7410
7064
  if (!instance) {
7411
7065
  throw new Error(`editor ${editorUid} not found`);
7412
7066
  }
@@ -7500,7 +7154,7 @@ const newStateGenerator$2 = async (state, parentUid) => {
7500
7154
  } = state;
7501
7155
  const {
7502
7156
  newState
7503
- } = get$5(parentUid);
7157
+ } = get$6(parentUid);
7504
7158
  const {
7505
7159
  languageId
7506
7160
  } = newState;
@@ -7692,7 +7346,7 @@ const isUntitledFile = uri => {
7692
7346
  };
7693
7347
 
7694
7348
  const saveNormalFile = async (uri, content) => {
7695
- await invoke$d('FileSystem.writeFile', uri, content);
7349
+ await invoke$c('FileSystem.writeFile', uri, content);
7696
7350
  };
7697
7351
 
7698
7352
  const showFilePicker = async platform => {
@@ -7700,7 +7354,7 @@ const showFilePicker = async platform => {
7700
7354
  const {
7701
7355
  canceled,
7702
7356
  filePath
7703
- } = await invoke$c('Open.showSaveDialog', dialogTitle, [], platform);
7357
+ } = await invoke$d('Open.showSaveDialog', dialogTitle, [], platform);
7704
7358
  if (canceled) {
7705
7359
  return '';
7706
7360
  }
@@ -7712,9 +7366,9 @@ const saveUntitledFile = async (uri, content, platform) => {
7712
7366
  if (!filePath) {
7713
7367
  return;
7714
7368
  }
7715
- await invoke$d('FileSystem.writeFile', filePath, content);
7369
+ await invoke$c('FileSystem.writeFile', filePath, content);
7716
7370
  await handleWorkspaceRefresh();
7717
- await invoke$d('Main.handleUriChange', uri, filePath);
7371
+ await invoke$c('Main.handleUriChange', uri, filePath);
7718
7372
  return filePath;
7719
7373
  };
7720
7374
 
@@ -8051,7 +7705,7 @@ const selectInsideString = editor => {
8051
7705
 
8052
7706
  const getNewSelections = async (editor, selections) => {
8053
7707
  // @ts-ignore
8054
- const newSelections = await invoke$d('ExtensionHostSelection.executeGrowSelection', editor, selections);
7708
+ const newSelections = await invoke$c('ExtensionHostSelection.executeGrowSelection', editor, selections);
8055
7709
  if (newSelections.length === 0) {
8056
7710
  return selections;
8057
7711
  }
@@ -8464,7 +8118,7 @@ const newStateGenerator$1 = async (state, parentUid) => {
8464
8118
  } = state;
8465
8119
  const {
8466
8120
  newState
8467
- } = get$5(parentUid);
8121
+ } = get$6(parentUid);
8468
8122
  const {
8469
8123
  languageId
8470
8124
  } = newState;
@@ -8484,7 +8138,7 @@ const showHover3 = async editor => {
8484
8138
 
8485
8139
  const EditorHover = 'EditorHover';
8486
8140
  const showHover = async state => {
8487
- await invoke$d('Viewlet.openWidget', EditorHover);
8141
+ await invoke$c('Viewlet.openWidget', EditorHover);
8488
8142
  return state;
8489
8143
  };
8490
8144
 
@@ -8548,7 +8202,7 @@ const newStateGenerator = async (state, parentUid) => {
8548
8202
  } = state;
8549
8203
  const {
8550
8204
  newState
8551
- } = get$5(parentUid);
8205
+ } = get$6(parentUid);
8552
8206
  const {
8553
8207
  languageId
8554
8208
  } = newState;
@@ -9165,7 +8819,7 @@ const typeWithAutoClosingQuote = (editor, text) => {
9165
8819
  const typeWithAutoClosingTag = async (editor, text) => {
9166
8820
  const offset = offsetAt(editor, editor.selections[0], editor.selections[1]);
9167
8821
  // @ts-ignore
9168
- const result = await invoke$d('ExtensionHostClosingTagCompletion.executeClosingTagProvider', editor, offset, text);
8822
+ const result = await invoke$c('ExtensionHostClosingTagCompletion.executeClosingTagProvider', editor, offset, text);
9169
8823
  if (!result) {
9170
8824
  const changes = editorReplaceSelections(editor, [text], EditorType);
9171
8825
  return scheduleDocumentAndCursorsSelections(editor, changes);
@@ -9491,7 +9145,7 @@ const createFn = (key, name, widgetId) => {
9491
9145
  ...state,
9492
9146
  commands
9493
9147
  };
9494
- const latest = get$5(editor.uid).newState;
9148
+ const latest = get$6(editor.uid).newState;
9495
9149
  const newEditor = updateWidget(latest, widgetId, newState);
9496
9150
  return newEditor;
9497
9151
  };
@@ -9788,7 +9442,7 @@ const getHoverPositionXy = (editor, rowIndex, wordStart, documentationHeight) =>
9788
9442
  };
9789
9443
  const getEditorHoverInfo = async (editorUid, position) => {
9790
9444
  number(editorUid);
9791
- const instance = get$5(editorUid);
9445
+ const instance = get$6(editorUid);
9792
9446
  const editor = instance.newState;
9793
9447
  const {
9794
9448
  selections
@@ -10184,12 +9838,12 @@ const getEditorSourceActions = async editorId => {
10184
9838
  }
10185
9839
  const {
10186
9840
  newState
10187
- } = get$5(editorId);
9841
+ } = get$6(editorId);
10188
9842
  const {
10189
9843
  languageId
10190
9844
  } = newState;
10191
9845
  // @ts-ignore
10192
- const allActions = await invoke$d('GetEditorSourceActions.getEditorSourceActions');
9846
+ const allActions = await invoke$c('GetEditorSourceActions.getEditorSourceActions');
10193
9847
  const filtered = filterActions(allActions, languageId);
10194
9848
  return filtered;
10195
9849
  };
@@ -10212,14 +9866,14 @@ const getWordAtOffset = editor => {
10212
9866
  };
10213
9867
 
10214
9868
  const setFocus = async focusKey => {
10215
- await invoke$d('Focus.setFocus', focusKey);
9869
+ await invoke$c('Focus.setFocus', focusKey);
10216
9870
  };
10217
9871
  const unsetAdditionalFocus = async focusKey => {
10218
9872
  if (!focusKey) {
10219
9873
  return;
10220
9874
  }
10221
9875
  // @ts-ignore
10222
- await invoke$d('Focus.removeAdditionalFocus', focusKey);
9876
+ await invoke$c('Focus.removeAdditionalFocus', focusKey);
10223
9877
  };
10224
9878
 
10225
9879
  const FocusEditor = 12;
@@ -10289,7 +9943,7 @@ const setSelections2 = (editorUid, selections) => {
10289
9943
  ...editor,
10290
9944
  selections
10291
9945
  };
10292
- set$6(editorUid, editor, newEditor);
9946
+ set$7(editorUid, editor, newEditor);
10293
9947
  };
10294
9948
  const closeWidget2 = async (editorUid, widgetId, widgetName, unsetAdditionalFocus$1) => {
10295
9949
  const editor = getEditor(editorUid);
@@ -10308,7 +9962,7 @@ const closeWidget2 = async (editorUid, widgetId, widgetName, unsetAdditionalFocu
10308
9962
  focused: true,
10309
9963
  widgets: newWidgets
10310
9964
  };
10311
- set$6(editorUid, editor, newEditor);
9965
+ set$7(editorUid, editor, newEditor);
10312
9966
  await setFocus(FocusEditorText);
10313
9967
  if (unsetAdditionalFocus$1) {
10314
9968
  await unsetAdditionalFocus(unsetAdditionalFocus$1);
@@ -10320,7 +9974,7 @@ const closeFind2 = async editorUid => {
10320
9974
  const applyEdits2 = async (editorUid, edits) => {
10321
9975
  const editor = getEditor(editorUid);
10322
9976
  const newEditor = await applyEdit(editor, edits);
10323
- set$6(editorUid, editor, newEditor);
9977
+ set$7(editorUid, editor, newEditor);
10324
9978
  };
10325
9979
  const getSourceActions = async editorUid => {
10326
9980
  const actions = await getEditorSourceActions(editorUid);
@@ -10783,7 +10437,7 @@ const getProblems = async () => {
10783
10437
  const keys = getKeys$2();
10784
10438
  const editors = keys.map(key => {
10785
10439
  const numericKey = parseInt(key);
10786
- const editor = get$5(numericKey);
10440
+ const editor = get$6(numericKey);
10787
10441
  return editor;
10788
10442
  });
10789
10443
  const newEditors = editors.map(editor => editor.newState);
@@ -10893,12 +10547,12 @@ const handleBeforeInput = (editor, inputType, data) => {
10893
10547
  };
10894
10548
 
10895
10549
  const handleMessagePort = async (port, rpcId) => {
10896
- const rpc = await create$d({
10550
+ const rpc = await create$c({
10897
10551
  commandMap: {},
10898
10552
  messagePort: port
10899
10553
  });
10900
10554
  if (rpcId) {
10901
- set$f(rpcId, rpc);
10555
+ set$e(rpcId, rpc);
10902
10556
  }
10903
10557
  };
10904
10558
 
@@ -10931,7 +10585,7 @@ const getWidgetName = widgetId => {
10931
10585
  const saveWidgetState = async keys => {
10932
10586
  const savedStates = Object.create(null);
10933
10587
  for (const key of keys) {
10934
- const editor = get$5(parseInt(key));
10588
+ const editor = get$6(parseInt(key));
10935
10589
  const {
10936
10590
  widgets
10937
10591
  } = editor.newState;
@@ -10950,7 +10604,7 @@ const restoreWidgetState = async (keys, savedStates) => {
10950
10604
  const newEditors = [];
10951
10605
  for (const key of keys) {
10952
10606
  const editorUid = parseInt(key);
10953
- const editor = get$5(editorUid);
10607
+ const editor = get$6(editorUid);
10954
10608
  const {
10955
10609
  widgets
10956
10610
  } = editor.newState;
@@ -10997,12 +10651,12 @@ const hotReload = async () => {
10997
10651
  await relaunchWorkers();
10998
10652
  const newEditors = await restoreWidgetState(keys, savedStates);
10999
10653
  for (const editor of newEditors) {
11000
- set$6(editor.newState.uid, editor.oldState, editor.newState);
10654
+ set$7(editor.newState.uid, editor.oldState, editor.newState);
11001
10655
  }
11002
10656
 
11003
10657
  // TODO ask renderer worker to rerender all editors
11004
10658
  // @ts-ignore
11005
- await invoke$d(`Editor.rerender`);
10659
+ await invoke$c(`Editor.rerender`);
11006
10660
  isReloading = false;
11007
10661
  };
11008
10662
 
@@ -11013,7 +10667,7 @@ const sendMessagePortToExtensionHostWorker2 = async (port, initialCommand, rpcId
11013
10667
  const createExtensionHostRpc = async () => {
11014
10668
  try {
11015
10669
  const initialCommand = 'HandleMessagePort.handleMessagePort2';
11016
- const rpc = await create$c({
10670
+ const rpc = await create$e({
11017
10671
  commandMap: {},
11018
10672
  async send(port) {
11019
10673
  await sendMessagePortToExtensionHostWorker2(port, initialCommand, EditorWorker);
@@ -11032,7 +10686,7 @@ const initializeExtensionHost = async () => {
11032
10686
 
11033
10687
  const createExtensionManagementWorkerRpc = async () => {
11034
10688
  try {
11035
- const rpc = await create$c({
10689
+ const rpc = await create$e({
11036
10690
  commandMap: {},
11037
10691
  async send(port) {
11038
10692
  await sendMessagePortToExtensionManagementWorker(port, EditorWorker);
@@ -11047,7 +10701,7 @@ const createExtensionManagementWorkerRpc = async () => {
11047
10701
  const initializeExtensionManagementWorker = async () => {
11048
10702
  try {
11049
10703
  const rpc = await createExtensionManagementWorkerRpc();
11050
- set$d(rpc);
10704
+ set$c(rpc);
11051
10705
  } catch {
11052
10706
  // ignore
11053
10707
  }
@@ -11059,7 +10713,7 @@ const send$1 = port => {
11059
10713
  };
11060
10714
  const initializeOpenerWorker = async () => {
11061
10715
  try {
11062
- const rpc = await create$f({
10716
+ const rpc = await create$d({
11063
10717
  commandMap: {},
11064
10718
  send: send$1
11065
10719
  });
@@ -11074,7 +10728,7 @@ const sendMessagePortToSyntaxHighlightingWorker = async port => {
11074
10728
  await sendMessagePortToSyntaxHighlightingWorker$1(port);
11075
10729
  } catch {
11076
10730
  // deprecated
11077
- await invokeAndTransfer$1(
10731
+ await invokeAndTransfer(
11078
10732
  // @ts-ignore
11079
10733
  'SendMessagePortToSyntaxHighlightingWorker.sendMessagePortToSyntaxHighlightingWorker', port, 'HandleMessagePort.handleMessagePort');
11080
10734
  }
@@ -11082,7 +10736,7 @@ const sendMessagePortToSyntaxHighlightingWorker = async port => {
11082
10736
 
11083
10737
  const createSyntaxHighlightingWorkerRpc = async () => {
11084
10738
  try {
11085
- const rpc = await create$c({
10739
+ const rpc = await create$e({
11086
10740
  commandMap: {},
11087
10741
  send: sendMessagePortToSyntaxHighlightingWorker
11088
10742
  });
@@ -11107,11 +10761,11 @@ const send = port => {
11107
10761
  return sendMessagePortToTextMeasurementWorker(port);
11108
10762
  };
11109
10763
  const initializeTextMeasurementWorker = async () => {
11110
- const rpc = await create$f({
10764
+ const rpc = await create$d({
11111
10765
  commandMap: {},
11112
10766
  send
11113
10767
  });
11114
- set$a(rpc);
10768
+ set$9(rpc);
11115
10769
  };
11116
10770
 
11117
10771
  const launchCompletionWorker = async () => {
@@ -11920,28 +11574,28 @@ const render2 = (uid, diffResult) => {
11920
11574
  const {
11921
11575
  newState,
11922
11576
  oldState
11923
- } = get$7(uid);
11924
- set$8(uid, newState, newState);
11577
+ } = get$6(uid);
11578
+ set$7(uid, newState, newState);
11925
11579
  const commands = applyRender(oldState, newState, diffResult);
11926
11580
  return commands;
11927
11581
  };
11928
11582
 
11929
11583
  const addWidget = widget => {
11930
- const module = get$6(widget.id);
11584
+ const module = get$5(widget.id);
11931
11585
  if (!module) {
11932
11586
  throw new Error('unsupported widget');
11933
11587
  }
11934
11588
  return module.add(widget);
11935
11589
  };
11936
11590
  const renderWidget = widget => {
11937
- const module = get$6(widget.id);
11591
+ const module = get$5(widget.id);
11938
11592
  if (!module) {
11939
11593
  throw new Error('unsupported widget');
11940
11594
  }
11941
11595
  return module.render(widget);
11942
11596
  };
11943
11597
  const removeWidget = widget => {
11944
- const module = get$6(widget.id);
11598
+ const module = get$5(widget.id);
11945
11599
  if (!module) {
11946
11600
  throw new Error('unsupported widget');
11947
11601
  }
@@ -12123,7 +11777,7 @@ const renderWidgets = {
12123
11777
  };
12124
11778
  const render$6 = [renderLines, renderSelections, renderScrollBarX, renderScrollBarY, renderFocus$1, renderDecorations, renderGutterInfo, renderWidgets, renderFocusContext, renderAdditionalFocusContext];
12125
11779
  const renderEditor = async id => {
12126
- const instance = get$5(id);
11780
+ const instance = get$6(id);
12127
11781
  if (!instance) {
12128
11782
  return [];
12129
11783
  }
@@ -12132,7 +11786,7 @@ const renderEditor = async id => {
12132
11786
  oldState
12133
11787
  } = instance;
12134
11788
  const commands = [];
12135
- set$6(id, newState, newState);
11789
+ set$7(id, newState, newState);
12136
11790
  for (const item of render$6) {
12137
11791
  if (!item.isEqual(oldState, newState)) {
12138
11792
  const result = await item.apply(oldState, newState);
@@ -12209,7 +11863,7 @@ const unregisterListener = (listenerType, rpcId) => {
12209
11863
  };
12210
11864
 
12211
11865
  const invoke = async (method, ...params) => {
12212
- const worker = get$8(DebugWorker);
11866
+ const worker = get$7(DebugWorker);
12213
11867
  return worker.invoke(method, ...params);
12214
11868
  };
12215
11869
 
@@ -12225,7 +11879,7 @@ const getKey = () => {
12225
11879
  const updateDebugInfo = async debugId => {
12226
11880
  const newInfo = await getDebugHighlight(debugId);
12227
11881
  const key = getKey();
12228
- const instance = get$5(key);
11882
+ const instance = get$6(key);
12229
11883
  if (!instance) {
12230
11884
  return;
12231
11885
  }
@@ -12237,90 +11891,69 @@ const updateDebugInfo = async debugId => {
12237
11891
  ...newState,
12238
11892
  highlightedLine: newInfo.rowIndex
12239
11893
  };
12240
- set$6(key, oldState, newEditor);
11894
+ set$7(key, oldState, newEditor);
12241
11895
  // @ts-ignore
12242
- await invoke$d('Editor.rerender', key);
12243
- };
12244
-
12245
- // TODO wrap commands globally, not per editor
12246
- // TODO only store editor state in editor worker, not in renderer worker also
12247
-
12248
- const wrapCommand = fn => async (editorUid, ...args) => {
12249
- const oldInstance = get$5(editorUid);
12250
- const state = oldInstance.newState;
12251
- const newEditor = await fn(state, ...args);
12252
- if (state === newEditor) {
12253
- return newEditor;
12254
- }
12255
- // TODO if editor did not change, no need to update furthur
12256
-
12257
- // TODO combine neweditor with latest editor?
12258
-
12259
- set$6(editorUid, state, newEditor);
12260
- const commands = await renderEditor(editorUid);
12261
- return {
12262
- ...newEditor,
12263
- commands
12264
- };
11896
+ await invoke$c('Editor.rerender', key);
12265
11897
  };
12266
11898
 
11899
+ const wrapCommandOld = wrapCommand;
12267
11900
  const commandMap = {
12268
11901
  'ActivateByEvent.activateByEvent': activateByEvent,
12269
11902
  'CodeGenerator.accept': codeGeneratorAccept,
12270
11903
  'ColorPicker.loadContent': loadContent$3,
12271
- 'Editor.addCursorAbove': wrapCommand(addCursorAbove),
12272
- 'Editor.addCursorBelow': wrapCommand(addCursorBelow),
12273
- 'Editor.applyDocumentEdits': wrapCommand(applyDocumentEdits),
12274
- 'Editor.applyEdit': wrapCommand(applyEdit),
11904
+ 'Editor.addCursorAbove': wrapCommandOld(addCursorAbove),
11905
+ 'Editor.addCursorBelow': wrapCommandOld(addCursorBelow),
11906
+ 'Editor.applyDocumentEdits': wrapCommandOld(applyDocumentEdits),
11907
+ 'Editor.applyEdit': wrapCommandOld(applyEdit),
12275
11908
  'Editor.applyEdit2': applyEdits2,
12276
- 'Editor.applyWorkspaceEdit': wrapCommand(applyWorkspaceEdit),
12277
- 'Editor.braceCompletion': wrapCommand(braceCompletion),
12278
- 'Editor.cancelSelection': wrapCommand(cancelSelection),
12279
- 'Editor.closeCodeGenerator': wrapCommand(closeCodeGenerator),
12280
- 'Editor.closeFind': wrapCommand(closeFind),
11909
+ 'Editor.applyWorkspaceEdit': wrapCommandOld(applyWorkspaceEdit),
11910
+ 'Editor.braceCompletion': wrapCommandOld(braceCompletion),
11911
+ 'Editor.cancelSelection': wrapCommandOld(cancelSelection),
11912
+ 'Editor.closeCodeGenerator': wrapCommandOld(closeCodeGenerator),
11913
+ 'Editor.closeFind': wrapCommandOld(closeFind),
12281
11914
  'Editor.closeFind2': closeFind2,
12282
- 'Editor.closeRename': wrapCommand(closeRename),
12283
- 'Editor.closeSourceAction': wrapCommand(closeSourceAction),
11915
+ 'Editor.closeRename': wrapCommandOld(closeRename),
11916
+ 'Editor.closeSourceAction': wrapCommandOld(closeSourceAction),
12284
11917
  'Editor.closeWidget2': closeWidget2,
12285
- 'Editor.compositionEnd': wrapCommand(compositionEnd),
12286
- 'Editor.compositionStart': wrapCommand(compositionStart),
12287
- 'Editor.compositionUpdate': wrapCommand(compositionUpdate),
12288
- 'Editor.contextMenu': wrapCommand(handleContextMenu),
12289
- 'Editor.copy': wrapCommand(copy$1),
12290
- 'Editor.copyLineDown': wrapCommand(copyLineDown),
12291
- 'Editor.copyLineUp': wrapCommand(copyLineUp),
11918
+ 'Editor.compositionEnd': wrapCommandOld(compositionEnd),
11919
+ 'Editor.compositionStart': wrapCommandOld(compositionStart),
11920
+ 'Editor.compositionUpdate': wrapCommandOld(compositionUpdate),
11921
+ 'Editor.contextMenu': wrapCommandOld(handleContextMenu),
11922
+ 'Editor.copy': wrapCommandOld(copy$1),
11923
+ 'Editor.copyLineDown': wrapCommandOld(copyLineDown),
11924
+ 'Editor.copyLineUp': wrapCommandOld(copyLineUp),
12292
11925
  'Editor.create': createEditor,
12293
11926
  'Editor.create2': createEditor2,
12294
- 'Editor.cursorCharacterLeft': wrapCommand(cursorCharacterLeft),
12295
- 'Editor.cursorCharacterRight': wrapCommand(cursorCharacterRight),
12296
- 'Editor.cursorDown': wrapCommand(cursorDown),
12297
- 'Editor.cursorEnd': wrapCommand(cursorEnd),
12298
- 'Editor.cursorHome': wrapCommand(cursorHome),
12299
- 'Editor.cursorLeft': wrapCommand(cursorCharacterLeft),
12300
- 'Editor.cursorRight': wrapCommand(cursorCharacterRight),
12301
- 'Editor.cursorSet': wrapCommand(cursorSet),
12302
- 'Editor.cursorUp': wrapCommand(cursorUp),
12303
- 'Editor.cursorWordLeft': wrapCommand(cursorWordLeft),
12304
- 'Editor.cursorWordPartLeft': wrapCommand(cursorWordPartLeft),
12305
- 'Editor.cursorWordPartRight': wrapCommand(cursorWordPartRight),
12306
- 'Editor.cursorWordRight': wrapCommand(cursorWordRight),
12307
- 'Editor.cut': wrapCommand(cut$1),
12308
- 'Editor.deleteAll': wrapCommand(deleteAll),
12309
- 'Editor.deleteAllLeft': wrapCommand(deleteAllLeft),
12310
- 'Editor.deleteAllRight': wrapCommand(deleteAllRight),
12311
- 'Editor.deleteCharacterLeft': wrapCommand(deleteCharacterLeft),
12312
- 'Editor.deleteCharacterRight': wrapCommand(deleteCharacterRight),
12313
- 'Editor.deleteHorizontalRight': wrapCommand(editorDeleteHorizontalRight),
12314
- 'Editor.deleteLeft': wrapCommand(deleteCharacterLeft),
12315
- 'Editor.deleteRight': wrapCommand(deleteCharacterRight),
12316
- 'Editor.deleteWordLeft': wrapCommand(deleteWordLeft),
12317
- 'Editor.deleteWordPartLeft': wrapCommand(deleteWordPartLeft),
12318
- 'Editor.deleteWordPartRight': wrapCommand(deleteWordPartRight),
12319
- 'Editor.deleteWordRight': wrapCommand(deleteWordRight),
11927
+ 'Editor.cursorCharacterLeft': wrapCommandOld(cursorCharacterLeft),
11928
+ 'Editor.cursorCharacterRight': wrapCommandOld(cursorCharacterRight),
11929
+ 'Editor.cursorDown': wrapCommandOld(cursorDown),
11930
+ 'Editor.cursorEnd': wrapCommandOld(cursorEnd),
11931
+ 'Editor.cursorHome': wrapCommandOld(cursorHome),
11932
+ 'Editor.cursorLeft': wrapCommandOld(cursorCharacterLeft),
11933
+ 'Editor.cursorRight': wrapCommandOld(cursorCharacterRight),
11934
+ 'Editor.cursorSet': wrapCommandOld(cursorSet),
11935
+ 'Editor.cursorUp': wrapCommandOld(cursorUp),
11936
+ 'Editor.cursorWordLeft': wrapCommandOld(cursorWordLeft),
11937
+ 'Editor.cursorWordPartLeft': wrapCommandOld(cursorWordPartLeft),
11938
+ 'Editor.cursorWordPartRight': wrapCommandOld(cursorWordPartRight),
11939
+ 'Editor.cursorWordRight': wrapCommandOld(cursorWordRight),
11940
+ 'Editor.cut': wrapCommandOld(cut$1),
11941
+ 'Editor.deleteAll': wrapCommandOld(deleteAll),
11942
+ 'Editor.deleteAllLeft': wrapCommandOld(deleteAllLeft),
11943
+ 'Editor.deleteAllRight': wrapCommandOld(deleteAllRight),
11944
+ 'Editor.deleteCharacterLeft': wrapCommandOld(deleteCharacterLeft),
11945
+ 'Editor.deleteCharacterRight': wrapCommandOld(deleteCharacterRight),
11946
+ 'Editor.deleteHorizontalRight': wrapCommandOld(editorDeleteHorizontalRight),
11947
+ 'Editor.deleteLeft': wrapCommandOld(deleteCharacterLeft),
11948
+ 'Editor.deleteRight': wrapCommandOld(deleteCharacterRight),
11949
+ 'Editor.deleteWordLeft': wrapCommandOld(deleteWordLeft),
11950
+ 'Editor.deleteWordPartLeft': wrapCommandOld(deleteWordPartLeft),
11951
+ 'Editor.deleteWordPartRight': wrapCommandOld(deleteWordPartRight),
11952
+ 'Editor.deleteWordRight': wrapCommandOld(deleteWordRight),
12320
11953
  'Editor.diff2': diff2,
12321
- 'Editor.executeWidgetCommand': wrapCommand(executeWidgetCommand),
12322
- 'Editor.findAllReferences': wrapCommand(findAllReferences$1),
12323
- 'Editor.format': wrapCommand(format),
11954
+ 'Editor.executeWidgetCommand': wrapCommandOld(executeWidgetCommand),
11955
+ 'Editor.findAllReferences': wrapCommandOld(findAllReferences$1),
11956
+ 'Editor.format': wrapCommandOld(format),
12324
11957
  'Editor.getCommandIds': getCommandIds,
12325
11958
  'Editor.getDiagnostics': getDiagnostics$1,
12326
11959
  'Editor.getKeyBindings': getKeyBindings,
@@ -12344,103 +11977,103 @@ const commandMap = {
12344
11977
  'Editor.getWordAtOffset2': getWordAtOffset2,
12345
11978
  'Editor.getWordBefore': getWordBefore,
12346
11979
  'Editor.getWordBefore2': getWordBefore2,
12347
- 'Editor.goToDefinition': wrapCommand(goToDefinition),
12348
- 'Editor.goToTypeDefinition': wrapCommand(goToTypeDefinition),
12349
- 'Editor.handleBeforeInput': wrapCommand(handleBeforeInput),
12350
- 'Editor.handleBeforeInputFromContentEditable': wrapCommand(handleBeforeInputFromContentEditable),
12351
- 'Editor.handleBlur': wrapCommand(handleBlur$1),
11980
+ 'Editor.goToDefinition': wrapCommandOld(goToDefinition),
11981
+ 'Editor.goToTypeDefinition': wrapCommandOld(goToTypeDefinition),
11982
+ 'Editor.handleBeforeInput': wrapCommandOld(handleBeforeInput),
11983
+ 'Editor.handleBeforeInputFromContentEditable': wrapCommandOld(handleBeforeInputFromContentEditable),
11984
+ 'Editor.handleBlur': wrapCommandOld(handleBlur$1),
12352
11985
  'Editor.handleClickAtPosition': handleClickAtPosition,
12353
- 'Editor.handleContextMenu': wrapCommand(handleContextMenu),
12354
- 'Editor.handleDoubleClick': wrapCommand(handleDoubleClick),
12355
- 'Editor.handleFocus': wrapCommand(handleFocus$1),
12356
- 'Editor.handleMouseDown': wrapCommand(handleMouseDown),
12357
- 'Editor.handleMouseMove': wrapCommand(handleMouseMove),
12358
- 'Editor.handleMouseMoveWithAltKey': wrapCommand(handleMouseMoveWithAltKey),
11986
+ 'Editor.handleContextMenu': wrapCommandOld(handleContextMenu),
11987
+ 'Editor.handleDoubleClick': wrapCommandOld(handleDoubleClick),
11988
+ 'Editor.handleFocus': wrapCommandOld(handleFocus$1),
11989
+ 'Editor.handleMouseDown': wrapCommandOld(handleMouseDown),
11990
+ 'Editor.handleMouseMove': wrapCommandOld(handleMouseMove),
11991
+ 'Editor.handleMouseMoveWithAltKey': wrapCommandOld(handleMouseMoveWithAltKey),
12359
11992
  'Editor.handleNativeSelectionChange': editorHandleNativeSelectionChange,
12360
- 'Editor.handlePointerCaptureLost': wrapCommand(handlePointerCaptureLost),
11993
+ 'Editor.handlePointerCaptureLost': wrapCommandOld(handlePointerCaptureLost),
12361
11994
  'Editor.handleScrollBarClick': handleScrollBarPointerDown,
12362
- 'Editor.handleScrollBarHorizontalMove': wrapCommand(handleScrollBarHorizontalMove),
12363
- 'Editor.handleScrollBarHorizontalPointerDown': wrapCommand(handleScrollBarHorizontalPointerDown),
12364
- 'Editor.handleScrollBarMove': wrapCommand(handleScrollBarMove),
12365
- 'Editor.handleScrollBarPointerDown': wrapCommand(handleScrollBarPointerDown),
12366
- 'Editor.handleScrollBarVerticalMove': wrapCommand(handleScrollBarVerticalPointerMove),
12367
- 'Editor.handleScrollBarVerticalPointerDown': wrapCommand(handleScrollBarPointerDown),
12368
- 'Editor.handleScrollBarVerticalPointerMove': wrapCommand(handleScrollBarVerticalPointerMove),
12369
- 'Editor.handleSingleClick': wrapCommand(handleSingleClick),
12370
- 'Editor.handleTab': wrapCommand(handleTab),
12371
- 'Editor.handleTouchEnd': wrapCommand(handleTouchEnd),
12372
- 'Editor.handleTouchMove': wrapCommand(handleTouchMove),
12373
- 'Editor.handleTouchStart': wrapCommand(handleTouchStart),
12374
- 'Editor.handleTripleClick': wrapCommand(handleTripleClick),
11995
+ 'Editor.handleScrollBarHorizontalMove': wrapCommandOld(handleScrollBarHorizontalMove),
11996
+ 'Editor.handleScrollBarHorizontalPointerDown': wrapCommandOld(handleScrollBarHorizontalPointerDown),
11997
+ 'Editor.handleScrollBarMove': wrapCommandOld(handleScrollBarMove),
11998
+ 'Editor.handleScrollBarPointerDown': wrapCommandOld(handleScrollBarPointerDown),
11999
+ 'Editor.handleScrollBarVerticalMove': wrapCommandOld(handleScrollBarVerticalPointerMove),
12000
+ 'Editor.handleScrollBarVerticalPointerDown': wrapCommandOld(handleScrollBarPointerDown),
12001
+ 'Editor.handleScrollBarVerticalPointerMove': wrapCommandOld(handleScrollBarVerticalPointerMove),
12002
+ 'Editor.handleSingleClick': wrapCommandOld(handleSingleClick),
12003
+ 'Editor.handleTab': wrapCommandOld(handleTab),
12004
+ 'Editor.handleTouchEnd': wrapCommandOld(handleTouchEnd),
12005
+ 'Editor.handleTouchMove': wrapCommandOld(handleTouchMove),
12006
+ 'Editor.handleTouchStart': wrapCommandOld(handleTouchStart),
12007
+ 'Editor.handleTripleClick': wrapCommandOld(handleTripleClick),
12375
12008
  'Editor.hotReload': hotReload,
12376
- 'Editor.indendLess': wrapCommand(indentLess),
12377
- 'Editor.indentMore': wrapCommand(indentMore),
12378
- 'Editor.insertLineBreak': wrapCommand(insertLineBreak),
12379
- 'Editor.loadContent': wrapCommand$1(loadContent),
12380
- 'Editor.moveLineDown': wrapCommand(moveLineDown),
12381
- 'Editor.moveLineUp': wrapCommand(moveLineUp),
12382
- 'Editor.moveRectangleSelection': wrapCommand(moveRectangleSelection),
12383
- 'Editor.moveRectangleSelectionPx': wrapCommand(moveRectangleSelectionPx),
12384
- 'Editor.moveSelection': wrapCommand(editorMoveSelection),
12385
- 'Editor.moveSelectionPx': wrapCommand(moveSelectionPx),
12009
+ 'Editor.indendLess': wrapCommandOld(indentLess),
12010
+ 'Editor.indentMore': wrapCommandOld(indentMore),
12011
+ 'Editor.insertLineBreak': wrapCommandOld(insertLineBreak),
12012
+ 'Editor.loadContent': wrapCommand(loadContent),
12013
+ 'Editor.moveLineDown': wrapCommandOld(moveLineDown),
12014
+ 'Editor.moveLineUp': wrapCommandOld(moveLineUp),
12015
+ 'Editor.moveRectangleSelection': wrapCommandOld(moveRectangleSelection),
12016
+ 'Editor.moveRectangleSelectionPx': wrapCommandOld(moveRectangleSelectionPx),
12017
+ 'Editor.moveSelection': wrapCommandOld(editorMoveSelection),
12018
+ 'Editor.moveSelectionPx': wrapCommandOld(moveSelectionPx),
12386
12019
  'Editor.offsetAt': offsetAt,
12387
- 'Editor.openCodeGenerator': wrapCommand(openCodeGenerator),
12388
- 'Editor.openColorPicker': wrapCommand(openColorPicker),
12389
- 'Editor.openCompletion': wrapCommand(openCompletion),
12390
- 'Editor.openFind': wrapCommand(openFind),
12391
- 'Editor.openFind2': wrapCommand(openFind2),
12392
- 'Editor.openRename': wrapCommand(openRename),
12393
- 'Editor.organizeImports': wrapCommand(organizeImports),
12394
- 'Editor.paste': wrapCommand(paste),
12395
- 'Editor.pasteText': wrapCommand(pasteText),
12020
+ 'Editor.openCodeGenerator': wrapCommandOld(openCodeGenerator),
12021
+ 'Editor.openColorPicker': wrapCommandOld(openColorPicker),
12022
+ 'Editor.openCompletion': wrapCommandOld(openCompletion),
12023
+ 'Editor.openFind': wrapCommandOld(openFind),
12024
+ 'Editor.openFind2': wrapCommandOld(openFind2),
12025
+ 'Editor.openRename': wrapCommandOld(openRename),
12026
+ 'Editor.organizeImports': wrapCommandOld(organizeImports),
12027
+ 'Editor.paste': wrapCommandOld(paste),
12028
+ 'Editor.pasteText': wrapCommandOld(pasteText),
12396
12029
  'Editor.render': renderEditor,
12397
12030
  'Editor.render2': render2,
12398
12031
  'Editor.renderEventListeners': renderEventListeners,
12399
- 'Editor.replaceRange': wrapCommand(replaceRange),
12400
- 'Editor.rerender': wrapCommand(rerender),
12401
- 'Editor.save': wrapCommand(save),
12032
+ 'Editor.replaceRange': wrapCommandOld(replaceRange),
12033
+ 'Editor.rerender': wrapCommandOld(rerender),
12034
+ 'Editor.save': wrapCommandOld(save),
12402
12035
  'Editor.saveState': wrapGetter(saveState),
12403
- 'Editor.selectAll': wrapCommand(selectAll),
12404
- 'Editor.selectAllLeft': wrapCommand(editorSelectAllLeft),
12405
- 'Editor.selectAllOccurrences': wrapCommand(selectAllOccurrences),
12406
- 'Editor.selectAllRight': wrapCommand(editorSelectAllRight),
12407
- 'Editor.selectCharacterLeft': wrapCommand(selectCharacterLeft),
12408
- 'Editor.selectCharacterRight': wrapCommand(selectCharacterRight),
12409
- 'Editor.selectDown': wrapCommand(selectDown),
12410
- 'Editor.selectInsideString': wrapCommand(selectInsideString),
12411
- 'Editor.selectionGrow': wrapCommand(selectionGrow),
12412
- 'Editor.selectLine': wrapCommand(selectLine),
12413
- 'Editor.selectNextOccurrence': wrapCommand(selectNextOccurrence),
12414
- 'Editor.selectPreviousOccurrence': wrapCommand(selectPreviousOccurrence),
12415
- 'Editor.selectUp': wrapCommand(selectUp),
12416
- 'Editor.selectWord': wrapCommand(selectWord),
12417
- 'Editor.selectWordLeft': wrapCommand(selectWordLeft),
12418
- 'Editor.selectWordRight': wrapCommand(selectWordRight),
12419
- 'Editor.setDebugEnabled': wrapCommand(setDebugEnabled),
12420
- 'Editor.setDecorations': wrapCommand(setDecorations),
12421
- 'Editor.setDelta': wrapCommand(setDelta),
12422
- 'Editor.setDeltaY': wrapCommand(setDeltaY),
12423
- 'Editor.setLanguageId': wrapCommand(setLanguageId),
12424
- 'Editor.setSelections': wrapCommand(setSelections),
12036
+ 'Editor.selectAll': wrapCommandOld(selectAll),
12037
+ 'Editor.selectAllLeft': wrapCommandOld(editorSelectAllLeft),
12038
+ 'Editor.selectAllOccurrences': wrapCommandOld(selectAllOccurrences),
12039
+ 'Editor.selectAllRight': wrapCommandOld(editorSelectAllRight),
12040
+ 'Editor.selectCharacterLeft': wrapCommandOld(selectCharacterLeft),
12041
+ 'Editor.selectCharacterRight': wrapCommandOld(selectCharacterRight),
12042
+ 'Editor.selectDown': wrapCommandOld(selectDown),
12043
+ 'Editor.selectInsideString': wrapCommandOld(selectInsideString),
12044
+ 'Editor.selectionGrow': wrapCommandOld(selectionGrow),
12045
+ 'Editor.selectLine': wrapCommandOld(selectLine),
12046
+ 'Editor.selectNextOccurrence': wrapCommandOld(selectNextOccurrence),
12047
+ 'Editor.selectPreviousOccurrence': wrapCommandOld(selectPreviousOccurrence),
12048
+ 'Editor.selectUp': wrapCommandOld(selectUp),
12049
+ 'Editor.selectWord': wrapCommandOld(selectWord),
12050
+ 'Editor.selectWordLeft': wrapCommandOld(selectWordLeft),
12051
+ 'Editor.selectWordRight': wrapCommandOld(selectWordRight),
12052
+ 'Editor.setDebugEnabled': wrapCommandOld(setDebugEnabled),
12053
+ 'Editor.setDecorations': wrapCommandOld(setDecorations),
12054
+ 'Editor.setDelta': wrapCommandOld(setDelta),
12055
+ 'Editor.setDeltaY': wrapCommandOld(setDeltaY),
12056
+ 'Editor.setLanguageId': wrapCommandOld(setLanguageId),
12057
+ 'Editor.setSelections': wrapCommandOld(setSelections),
12425
12058
  'Editor.setSelections2': setSelections2,
12426
- 'Editor.setText': wrapCommand(setText),
12059
+ 'Editor.setText': wrapCommandOld(setText),
12427
12060
  'Editor.showHover': showHover,
12428
12061
  'Editor.showHover2': showHover3,
12429
12062
  'Editor.showSourceActions': showSourceActions,
12430
12063
  'Editor.showSourceActions2': showSourceActions,
12431
12064
  'Editor.showSourceActions3': showSourceActions,
12432
- 'Editor.sortLinesAscending': wrapCommand(sortLinesAscending),
12433
- 'Editor.tabCompletion': wrapCommand(tabCompletion),
12065
+ 'Editor.sortLinesAscending': wrapCommandOld(sortLinesAscending),
12066
+ 'Editor.tabCompletion': wrapCommandOld(tabCompletion),
12434
12067
  'Editor.terminate': terminate,
12435
- 'Editor.toggleBlockComment': wrapCommand(toggleBlockComment),
12436
- 'Editor.toggleComment': wrapCommand(toggleComment),
12437
- 'Editor.toggleLineComment': wrapCommand(editorToggleLineComment),
12438
- 'Editor.type': wrapCommand(type),
12439
- 'Editor.typeWithAutoClosing': wrapCommand(typeWithAutoClosing),
12440
- 'Editor.undo': wrapCommand(undo),
12441
- 'Editor.unIndent': wrapCommand(editorUnindent),
12068
+ 'Editor.toggleBlockComment': wrapCommandOld(toggleBlockComment),
12069
+ 'Editor.toggleComment': wrapCommandOld(toggleComment),
12070
+ 'Editor.toggleLineComment': wrapCommandOld(editorToggleLineComment),
12071
+ 'Editor.type': wrapCommandOld(type),
12072
+ 'Editor.typeWithAutoClosing': wrapCommandOld(typeWithAutoClosing),
12073
+ 'Editor.undo': wrapCommandOld(undo),
12074
+ 'Editor.unIndent': wrapCommandOld(editorUnindent),
12442
12075
  'Editor.updateDebugInfo': updateDebugInfo,
12443
- 'Editor.updateDiagnostics': wrapCommand(updateDiagnostics),
12076
+ 'Editor.updateDiagnostics': wrapCommandOld(updateDiagnostics),
12444
12077
  'EditorCompletion.close': close$4,
12445
12078
  'EditorCompletion.closeDetails': closeDetails$1,
12446
12079
  'EditorCompletion.focusFirst': focusFirst$1,
@@ -12527,7 +12160,7 @@ const listen = async () => {
12527
12160
  const rpc = await create$b({
12528
12161
  commandMap: commandMap
12529
12162
  });
12530
- set$c(rpc);
12163
+ set$a(rpc);
12531
12164
  };
12532
12165
 
12533
12166
  const CodeGeneratorInput = 'CodeGeneratorInput';
@@ -12825,14 +12458,14 @@ const EditorHoverWidget = {
12825
12458
  };
12826
12459
 
12827
12460
  const registerWidgets = () => {
12828
- set$7(ColorPicker$1, EditorColorPickerWidget);
12829
- set$7(Completion, EditorCompletionWidget);
12830
- set$7(CompletionDetail, EditorCompletionDetailWidget);
12831
- set$7(Find, EditorFindWidget);
12832
- set$7(Hover, EditorHoverWidget);
12833
- set$7(Rename$1, EditorRenameWidget);
12834
- set$7(SourceAction$1, EditorSourceActionWidget);
12835
- set$7(CodeGenerator, EditorCodeGeneratorWidget);
12461
+ set$6(ColorPicker$1, EditorColorPickerWidget);
12462
+ set$6(Completion, EditorCompletionWidget);
12463
+ set$6(CompletionDetail, EditorCompletionDetailWidget);
12464
+ set$6(Find, EditorFindWidget);
12465
+ set$6(Hover, EditorHoverWidget);
12466
+ set$6(Rename$1, EditorRenameWidget);
12467
+ set$6(SourceAction$1, EditorSourceActionWidget);
12468
+ set$6(CodeGenerator, EditorCodeGeneratorWidget);
12836
12469
  };
12837
12470
 
12838
12471
  const handleUnhandledRejection = event => {