@lvce-editor/extension-detail-view 7.19.1 → 7.20.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.
@@ -11,22 +11,26 @@ const i18nString = (key, placeholders = emptyObject) => {
11
11
  };
12
12
 
13
13
  const ActivationEvents$1 = 'Activation Events';
14
+ const ActivationEvent = 'Activation Event';
14
15
  const ActivationTime = 'Activation Time: ';
15
16
  const Categories$1 = 'Categories';
16
17
  const Changelog$2 = 'Changelog';
17
18
  const Commands$1 = 'Commands';
18
19
  const ContentSecurityPolicy = 'Content Security Policy';
19
20
  const Copy = 'Copy';
21
+ const CopyExtensionId = 'Copy Extension ID';
20
22
  const CopyImage = 'Copy Image';
21
23
  const CopyImageUrl = 'Copy Image Url';
22
24
  const CopyLink = 'Copy Link';
23
25
  const Created = 'Created';
26
+ const Description = 'Description';
24
27
  const Details$1 = 'Details';
25
28
  const Disable$1 = 'Disable';
26
29
  const DownloadCount = 'Downloads';
27
30
  const Elements = 'Elements';
28
31
  const EmptyCommandsArray = 'The extension contributes an empty commands array.';
29
32
  const Enable$1 = 'Enable';
33
+ const ExtensionInfoId = 'Id';
30
34
  const ExtensionNotAvailable = 'The extension "{PH1}" is not available in this version of LVCE Editor.';
31
35
  const Features$2 = 'Features';
32
36
  const FileExtensions = 'File Extensions';
@@ -53,6 +57,7 @@ const OpenInNewTab = 'Open in New Tab';
53
57
  const ProgrammingLanguages$1 = 'Programming Languages';
54
58
  const PropertyMustBeOfTypeString = 'Property must be a string';
55
59
  const Published = 'Published';
60
+ const Publisher = 'Publisher';
56
61
  const Rating = 'Rating';
57
62
  const Repository = 'Repository';
58
63
  const Resources$1 = 'Resources';
@@ -75,6 +80,7 @@ const UnableToLoadExtension = 'Unable to load extension';
75
80
  const UnableToLoadExtensionWithError = 'The extension details could not be loaded: {PH1}';
76
81
  const UnsupportedFeature = 'Unsupported Feature';
77
82
  const Version = 'Version';
83
+ const VsMarketplaceLink = 'VS Marketplace Link';
78
84
  const WebViews$1 = 'WebViews';
79
85
 
80
86
  const installation = () => {
@@ -95,6 +101,9 @@ const resources = () => {
95
101
  const copy = () => {
96
102
  return i18nString(Copy);
97
103
  };
104
+ const copyExtensionId$1 = () => {
105
+ return i18nString(CopyExtensionId);
106
+ };
98
107
  const copyImage$1 = () => {
99
108
  return i18nString(CopyImage);
100
109
  };
@@ -107,6 +116,9 @@ const changelog = () => {
107
116
  const details = () => {
108
117
  return i18nString(Details$1);
109
118
  };
119
+ const description = () => {
120
+ return i18nString(Description);
121
+ };
110
122
  const disable = () => {
111
123
  return i18nString(Disable$1);
112
124
  };
@@ -143,6 +155,9 @@ const setColorTheme$2 = () => {
143
155
  const enable = () => {
144
156
  return i18nString(Enable$1);
145
157
  };
158
+ const extensionInfoId = () => {
159
+ return i18nString(ExtensionInfoId);
160
+ };
146
161
  const extensionNotAvailable = extensionId => {
147
162
  return i18nString(ExtensionNotAvailable, {
148
163
  PH1: extensionId
@@ -160,6 +175,9 @@ const webViews = () => {
160
175
  const activationEvents = () => {
161
176
  return i18nString(ActivationEvents$1);
162
177
  };
178
+ const activationEvent = () => {
179
+ return i18nString(ActivationEvent);
180
+ };
163
181
  const runtimeStatus = () => {
164
182
  return i18nString(RuntimeStatus$1);
165
183
  };
@@ -249,9 +267,15 @@ const size = () => {
249
267
  const published = () => {
250
268
  return i18nString(Published);
251
269
  };
270
+ const publisher = () => {
271
+ return i18nString(Publisher);
272
+ };
252
273
  const lastReleased = () => {
253
274
  return i18nString(LastReleased);
254
275
  };
276
+ const vsMarketplaceLink = () => {
277
+ return i18nString(VsMarketplaceLink);
278
+ };
255
279
  const issues = () => {
256
280
  return i18nString(Issues);
257
281
  };
@@ -510,6 +534,7 @@ const RightArrow = 15;
510
534
 
511
535
  const Script$1 = 2;
512
536
 
537
+ const ManageExtension = 8;
513
538
  const ExtensionDetailReadme = 20;
514
539
  const ExtensionDetailIconContextMenu$2 = 4091;
515
540
 
@@ -848,6 +873,7 @@ const FeatureContent = 'FeatureContent';
848
873
  const Features$1 = 'Features';
849
874
  const FeaturesList = 'FeaturesList';
850
875
  const FeatureWebView = 'FeatureWebView';
876
+ const IconButton = 'IconButton';
851
877
  const Large$1 = 'Large';
852
878
  const Link$1 = 'Link';
853
879
  const Markdown = 'Markdown';
@@ -864,7 +890,7 @@ const Sash = 'Sash';
864
890
  const SashVertical = 'SashVertical';
865
891
  const ScrollToTopButton = 'ScrollToTopButton';
866
892
  const SettingsButton = 'SettingsButton';
867
- const SettingsIcon = 'SettingsIcon';
893
+ const MaskIconSettingsGear = 'MaskIconSettingsGear';
868
894
  const Small$1 = 'Small';
869
895
  const Table = 'Table';
870
896
  const TableCell = 'TableCell';
@@ -876,7 +902,7 @@ const li = {
876
902
  childCount: 1,
877
903
  type: Li
878
904
  };
879
- const code = {
905
+ const code$1 = {
880
906
  childCount: 1,
881
907
  type: Code$2
882
908
  };
@@ -892,9 +918,9 @@ const getActivationEventVirtualDom = event => {
892
918
  className: mergeClassNames('ListItem', 'ListItemInvalid'),
893
919
  title: errorMessage,
894
920
  type: Li
895
- }, code, text(stringValue)];
921
+ }, code$1, text(stringValue)];
896
922
  }
897
- return [li, code, text(stringValue)];
923
+ return [li, code$1, text(stringValue)];
898
924
  };
899
925
 
900
926
  const featureContentHeadingNode = {
@@ -1066,6 +1092,8 @@ const getCellLinkVirtualDom = (value, props) => {
1066
1092
  childCount: 1,
1067
1093
  className: Link$1,
1068
1094
  href: props?.href,
1095
+ rel: 'noopener noreferrer',
1096
+ target: '_blank',
1069
1097
  type: A
1070
1098
  }, text(value)];
1071
1099
  };
@@ -2692,29 +2720,22 @@ const create$2 = rpcId => {
2692
2720
  };
2693
2721
 
2694
2722
  const {
2695
- invoke: invoke$6,
2723
+ invoke: invoke$5,
2696
2724
  set: set$b
2697
2725
  } = create$2(ClipBoardWorker);
2698
2726
  const writeText$1 = async text => {
2699
- return invoke$6('ClipBoard.writeText', text);
2727
+ return invoke$5('ClipBoard.writeText', text);
2700
2728
  };
2701
2729
  const writeImage = async image => {
2702
- return invoke$6('ClipBoard.writeImage', image);
2730
+ return invoke$5('ClipBoard.writeImage', image);
2703
2731
  };
2704
2732
 
2705
2733
  const {
2706
- invoke: invoke$5,
2707
2734
  set: set$a
2708
2735
  } = create$2(ExtensionHostWorker);
2709
- const getRuntimeStatus$2 = async extensionId => {
2710
- // @ts-ignore
2711
- return invoke$5('ExtensionHost.getRuntimeStatus', extensionId);
2712
- };
2713
2736
 
2714
2737
  const ExtensionHost = {
2715
2738
  __proto__: null,
2716
- getRuntimeStatus: getRuntimeStatus$2,
2717
- invoke: invoke$5,
2718
2739
  set: set$a
2719
2740
  };
2720
2741
 
@@ -2842,16 +2863,8 @@ const getAllPreferences = async () => {
2842
2863
  return invoke$1('Preferences.getAll');
2843
2864
  };
2844
2865
 
2845
- const {
2846
- getRuntimeStatus: getRuntimeStatus$1,
2847
- set: set$5
2848
- } = ExtensionHost;
2849
-
2850
2866
  const getRuntimeStatus = async extensionId => {
2851
- // @ts-ignore
2852
- const status = await getRuntimeStatus$1(extensionId);
2853
- // @ts-ignore
2854
- return status;
2867
+ return invoke$4('Extensions.getRuntimeStatus', extensionId);
2855
2868
  };
2856
2869
 
2857
2870
  const getRuntimeStatusDetails = async extension => {
@@ -2897,6 +2910,27 @@ const getActivationTimeVirtualDom = (importTime$1, activationTime$1) => {
2897
2910
  return [definitionTermNode, text(importTime()), definitionDescriptionNode, text(formattedImportTime), definitionTermNode, text(activationTime()), definitionDescriptionNode, text(formattedTime)];
2898
2911
  };
2899
2912
 
2913
+ const key$1 = {
2914
+ childCount: 1,
2915
+ className: 'RuntimeStatusDefinitionListKey',
2916
+ type: Dt
2917
+ };
2918
+ const value$1 = {
2919
+ childCount: 1,
2920
+ className: 'RuntimeStatusDefinitionListValue',
2921
+ type: Dd
2922
+ };
2923
+ const code = {
2924
+ childCount: 1,
2925
+ type: Code$2
2926
+ };
2927
+ const getRuntimeActivationEventVirtualDom = activationEvent$1 => {
2928
+ if (!activationEvent$1) {
2929
+ return [];
2930
+ }
2931
+ return [key$1, text(`${activationEvent()}: `), value$1, code, text(activationEvent$1)];
2932
+ };
2933
+
2900
2934
  const None$1 = 0;
2901
2935
  const Importing = 1;
2902
2936
  const Activating = 2;
@@ -2941,9 +2975,12 @@ const featureContentNode$3 = {
2941
2975
  className: FeatureContent,
2942
2976
  type: Div
2943
2977
  };
2944
- const getChildCount$1 = (status, activationTime, importTime) => {
2978
+ const getChildCount$1 = (status, activationEvent, activationTime, importTime) => {
2945
2979
  let childCount = 0;
2946
2980
  childCount += 2; // status
2981
+ if (activationEvent) {
2982
+ childCount += 2;
2983
+ }
2947
2984
  if (importTime || activationTime) {
2948
2985
  childCount += 4;
2949
2986
  }
@@ -2951,17 +2988,18 @@ const getChildCount$1 = (status, activationTime, importTime) => {
2951
2988
  };
2952
2989
  const getRuntimeStatusVirtualDom = state => {
2953
2990
  const {
2954
- activationTime: displayedImportTime,
2955
- importTime: displayedActivationTime,
2956
- status
2991
+ activationTime,
2992
+ importTime,
2993
+ status,
2994
+ wasActivatedByEvent
2957
2995
  } = state;
2958
2996
  const heading = runtimeStatus();
2959
- const childCount = getChildCount$1(status, displayedActivationTime, displayedImportTime);
2997
+ const childCount = getChildCount$1(status, wasActivatedByEvent, activationTime, importTime);
2960
2998
  return [featureContentNode$3, ...getFeatureContentHeadingVirtualDom(heading), {
2961
2999
  childCount,
2962
3000
  className: 'RuntimeStatusDefinitionList',
2963
3001
  type: Dl
2964
- }, ...getStatusVirtualDom(status), ...getActivationTimeVirtualDom(displayedImportTime, displayedActivationTime)];
3002
+ }, ...getStatusVirtualDom(status), ...getRuntimeActivationEventVirtualDom(wasActivatedByEvent), ...getActivationTimeVirtualDom(importTime, activationTime)];
2965
3003
  };
2966
3004
 
2967
3005
  const getSettingsTableEntry = setting => {
@@ -3098,7 +3136,7 @@ const getScrollToTopVirtualDom = scrollToTopButtonEnabled => {
3098
3136
  const {
3099
3137
  getVirtualDom,
3100
3138
  render,
3101
- set: set$4
3139
+ set: set$5
3102
3140
  } = MarkdownWorker;
3103
3141
 
3104
3142
  const addScrollToTopVirtualDom = dom => {
@@ -3182,8 +3220,6 @@ const getMarkdownCacheKey = async (markdown, options) => {
3182
3220
  return `https://-/markdown/${hash}`;
3183
3221
  };
3184
3222
 
3185
- // TODO pass application name from renderer worker to not hardcode it
3186
-
3187
3223
  const cachedCaches = Object.create(null);
3188
3224
  const noopCache = {
3189
3225
  async match() {
@@ -3215,21 +3251,23 @@ const getCache = (cacheName, bucketName) => {
3215
3251
  return cachedCaches[cacheName];
3216
3252
  };
3217
3253
 
3218
- // TODO pass application name from renderer worker to not hardcode it
3219
- const cacheName$1 = 'lvce-editor/markdown-cache';
3220
- const has = async (key, bucketName) => {
3221
- const cache = await getCache(cacheName$1, bucketName);
3254
+ let cacheName$1 = '';
3255
+ const setApplicationName = applicationName => {
3256
+ cacheName$1 = `${applicationName}/markdown-cache`;
3257
+ };
3258
+ const has = async (key, bucketName, getCacheFunction = getCache) => {
3259
+ const cache = await getCacheFunction(cacheName$1, bucketName);
3222
3260
  const response = await cache.match(key);
3223
3261
  return Boolean(response);
3224
3262
  };
3225
- const get$2 = async (key, bucketName) => {
3226
- const cache = await getCache(cacheName$1, bucketName);
3263
+ const get$2 = async (key, bucketName, getCacheFunction = getCache) => {
3264
+ const cache = await getCacheFunction(cacheName$1, bucketName);
3227
3265
  const response = await cache.match(key);
3228
3266
  const text = await response?.text();
3229
3267
  return text || '';
3230
3268
  };
3231
- const set$3 = async (key, bucketName, value) => {
3232
- const cache = await getCache(cacheName$1, bucketName);
3269
+ const set$4 = async (key, bucketName, value, getCacheFunction = getCache) => {
3270
+ const cache = await getCacheFunction(cacheName$1, bucketName);
3233
3271
  await cache.put(key, new Response(value, {
3234
3272
  headers: {
3235
3273
  'Content-Length': `${value.length}`,
@@ -3247,7 +3285,7 @@ const renderMarkdownCached = async (markdown, options) => {
3247
3285
  return value; // TODO validate if it's valid
3248
3286
  }
3249
3287
  const html = await render(markdown, options);
3250
- await set$3(cacheKey, bucketName, html);
3288
+ await set$4(cacheKey, bucketName, html);
3251
3289
  return html;
3252
3290
  };
3253
3291
 
@@ -3733,11 +3771,59 @@ const writeText = async text => {
3733
3771
  await writeText$1(text);
3734
3772
  };
3735
3773
 
3774
+ const copyExtensionId = async state => {
3775
+ await writeText(state.extensionId);
3776
+ return state;
3777
+ };
3778
+
3779
+ const stringifyRow = ({
3780
+ key,
3781
+ value
3782
+ }) => {
3783
+ return `${key}: ${value}`;
3784
+ };
3785
+ const getExtensionInfoText = state => {
3786
+ const {
3787
+ description: description$1,
3788
+ extension,
3789
+ extensionId,
3790
+ extensionVersion,
3791
+ name: name$1
3792
+ } = state;
3793
+ const publisher$1 = extension?.publisherDisplayName || extension?.publisher || 'n/a';
3794
+ const marketplaceLink = typeof extension?.url === 'string' ? extension.url : '';
3795
+ const rows = [{
3796
+ key: name(),
3797
+ value: name$1
3798
+ }, {
3799
+ key: extensionInfoId(),
3800
+ value: extensionId
3801
+ }, {
3802
+ key: description(),
3803
+ value: description$1
3804
+ }, {
3805
+ key: version(),
3806
+ value: extensionVersion
3807
+ }, {
3808
+ key: publisher(),
3809
+ value: publisher$1
3810
+ }, ...(marketplaceLink ? [{
3811
+ key: vsMarketplaceLink(),
3812
+ value: marketplaceLink
3813
+ }] : [])];
3814
+ return rows.map(stringifyRow).join('\n');
3815
+ };
3816
+
3817
+ const copyExtensionInfo = async state => {
3818
+ await writeText(getExtensionInfoText(state));
3819
+ return state;
3820
+ };
3821
+
3736
3822
  const {
3737
3823
  exists,
3738
3824
  invoke,
3739
3825
  readFile: readFile$1,
3740
- set: set$2
3826
+ set: set$3
3741
3827
  } = FileSystemWorker;
3742
3828
  const readFileAsBlob = async uri => {
3743
3829
  // TODO maybe readAsObjectUrl?
@@ -3790,7 +3876,7 @@ const {
3790
3876
  get: get$1,
3791
3877
  getCommandIds,
3792
3878
  registerCommands,
3793
- set: set$1,
3879
+ set: set$2,
3794
3880
  wrapCommand,
3795
3881
  wrapGetter
3796
3882
  } = create$1();
@@ -3871,7 +3957,7 @@ const create = (uid, uri, x, y, width, height, platform, assetDir) => {
3871
3957
  webViews: [],
3872
3958
  width
3873
3959
  };
3874
- set$1(uid, state, state);
3960
+ set$2(uid, state, state);
3875
3961
  };
3876
3962
 
3877
3963
  const isEqual$3 = (oldState, newState) => {
@@ -3983,6 +4069,21 @@ const getMenuEntries2 = (state, props) => {
3983
4069
  if (props.menuId === ExtensionDetailIconContextMenu$2) {
3984
4070
  return getMenuEntriesImage();
3985
4071
  }
4072
+ if (props.menuId === ManageExtension) {
4073
+ return [{
4074
+ args: [],
4075
+ command: 'ExtensionDetail.copyExtensionInfo',
4076
+ flags: None$2,
4077
+ id: 'copy',
4078
+ label: copy()
4079
+ }, {
4080
+ args: [],
4081
+ command: 'ExtensionDetail.copyExtensionId',
4082
+ flags: None$2,
4083
+ id: 'copyExtensionId',
4084
+ label: copyExtensionId$1()
4085
+ }];
4086
+ }
3986
4087
  if (props.menuId === ExtensionDetailReadme && props.href) {
3987
4088
  return [{
3988
4089
  args: [props.href],
@@ -4051,7 +4152,7 @@ const getLinkMenuEntries = props => {
4051
4152
  const getMenuEntries = props => [...getLinkMenuEntries(props), ...getImageMenuEntries(props), getCopyMenuEntry()];
4052
4153
 
4053
4154
  const getMenuIds = () => {
4054
- return [ExtensionDetailReadme, ExtensionDetailIconContextMenu$2];
4155
+ return [ExtensionDetailReadme, ExtensionDetailIconContextMenu$2, ManageExtension];
4055
4156
  };
4056
4157
 
4057
4158
  const getMenuEntriesReadme = () => [{
@@ -4428,8 +4529,13 @@ const handleClickSetColorTheme = async state => {
4428
4529
  return state;
4429
4530
  };
4430
4531
 
4431
- const handleClickSettings = state => {
4432
- // TODO: Implement settings functionality
4532
+ const handleClickSettings = async (state, eventX, eventY) => {
4533
+ const {
4534
+ uid
4535
+ } = state;
4536
+ await show2(uid, ManageExtension, eventX, eventY, {
4537
+ menuId: ManageExtension
4538
+ });
4433
4539
  return state;
4434
4540
  };
4435
4541
 
@@ -5073,7 +5179,9 @@ const getSizeEntries = (showSizeLink, displaySize, extensionUri) => {
5073
5179
  return [];
5074
5180
  }
5075
5181
  return [{
5182
+ code: undefined,
5076
5183
  key: size(),
5184
+ odd: undefined,
5077
5185
  onClick: HandleClickSize,
5078
5186
  title: extensionUri,
5079
5187
  value: displaySize
@@ -5095,20 +5203,34 @@ const getInstallationEntries = (displaySize, extensionId, extensionVersion, exte
5095
5203
  const entries = [{
5096
5204
  code: true,
5097
5205
  key: identifier(),
5206
+ odd: undefined,
5207
+ onClick: undefined,
5208
+ title: undefined,
5098
5209
  value: extensionId
5099
5210
  }, {
5100
5211
  code: true,
5101
5212
  key: version(),
5213
+ odd: undefined,
5214
+ onClick: undefined,
5215
+ title: undefined,
5102
5216
  value: extensionVersion
5103
5217
  }];
5104
5218
  if (created$1 !== null) {
5105
5219
  entries.push({
5220
+ code: undefined,
5106
5221
  key: created(),
5222
+ odd: undefined,
5223
+ onClick: undefined,
5224
+ title: undefined,
5107
5225
  value: formatCreated(created$1)
5108
5226
  });
5109
5227
  }
5110
5228
  entries.push({
5229
+ code: undefined,
5111
5230
  key: lastUpdated(),
5231
+ odd: undefined,
5232
+ onClick: undefined,
5233
+ title: undefined,
5112
5234
  value: formatLastUpdated(lastUpdated$1)
5113
5235
  }, ...getSizeEntries(showSizeLink, displaySize, extensionUri));
5114
5236
  return addOddEntries(entries);
@@ -5119,11 +5241,18 @@ const getMarketplaceEntries = isBuiltin => {
5119
5241
  return [];
5120
5242
  }
5121
5243
  return [{
5244
+ code: undefined,
5122
5245
  key: published(),
5123
5246
  odd: true,
5247
+ onClick: undefined,
5248
+ title: undefined,
5124
5249
  value: 'n/a'
5125
5250
  }, {
5251
+ code: undefined,
5126
5252
  key: lastReleased(),
5253
+ odd: undefined,
5254
+ onClick: undefined,
5255
+ title: undefined,
5127
5256
  value: 'n/a'
5128
5257
  }];
5129
5258
  };
@@ -5453,6 +5582,7 @@ const loadContentInternal = async (state, platform, savedState, isTest = false)
5453
5582
  scrollSource: Script,
5454
5583
  scrollToTopButtonEnabled: true,
5455
5584
  selectedTab,
5585
+ settingsButtonEnabled: true,
5456
5586
  showSideBar,
5457
5587
  showSizeLink,
5458
5588
  sideBarWidth,
@@ -5765,7 +5895,7 @@ const get = async (uri, now = Date.now(), getCacheFunction = getCache) => {
5765
5895
  return undefined;
5766
5896
  }
5767
5897
  };
5768
- const set = async (uri, value, now = Date.now(), getCacheFunction = getCache) => {
5898
+ const set$1 = async (uri, value, now = Date.now(), getCacheFunction = getCache) => {
5769
5899
  try {
5770
5900
  const cache = await getCacheFunction(cacheName, bucketName);
5771
5901
  await cache.put(getCacheKey(uri), new Response(value, {
@@ -5783,7 +5913,7 @@ const set = async (uri, value, now = Date.now(), getCacheFunction = getCache) =>
5783
5913
  const ChangelogCache = {
5784
5914
  __proto__: null,
5785
5915
  get,
5786
- set
5916
+ set: set$1
5787
5917
  };
5788
5918
 
5789
5919
  const error = async error => {
@@ -6172,9 +6302,13 @@ const createExtensionHostWorkerRpc = async () => {
6172
6302
  }
6173
6303
  };
6174
6304
 
6305
+ const {
6306
+ set
6307
+ } = ExtensionHost;
6308
+
6175
6309
  const initializeExtensionHostWorker = async () => {
6176
6310
  const rpc = await createExtensionHostWorkerRpc();
6177
- set$5(rpc);
6311
+ set(rpc);
6178
6312
  };
6179
6313
 
6180
6314
  const createExtensionManagementWorkerRpc = async () => {
@@ -6216,7 +6350,7 @@ const createFileSystemWorkerRpc = async () => {
6216
6350
 
6217
6351
  const initializeFileSystemWorker = async () => {
6218
6352
  const rpc = await createFileSystemWorkerRpc();
6219
- set$2(rpc);
6353
+ set$3(rpc);
6220
6354
  };
6221
6355
 
6222
6356
  const sendMessagePortToMarkdownWorker = async port => {
@@ -6233,10 +6367,11 @@ const createMarkdownWorkerRpc = async () => {
6233
6367
 
6234
6368
  const initializeMarkdownWorker = async () => {
6235
6369
  const rpc = await createMarkdownWorkerRpc();
6236
- set$4(rpc);
6370
+ set$5(rpc);
6237
6371
  };
6238
6372
 
6239
- const initialize = async () => {
6373
+ const initialize = async applicationName => {
6374
+ setApplicationName(applicationName);
6240
6375
  // TODO load markdown worker only when needed
6241
6376
  await Promise.all([initializeMarkdownWorker(), initializeFileSystemWorker(), initializeExtensionHostWorker(), initializeExtensionManagementWorker(), initializeClipBoardWorker()]);
6242
6377
  };
@@ -6257,8 +6392,11 @@ const openImageInNewTab = async state => {
6257
6392
  return state;
6258
6393
  };
6259
6394
 
6395
+ const mapEntry = ([key, value]) => {
6396
+ return ` --${key}: ${value}px;`;
6397
+ };
6260
6398
  const createCss = object => {
6261
- const inner = Object.entries(object).map(([key, value]) => ` --${key}: ${value}px;`).join('\n');
6399
+ const inner = Object.entries(object).map(mapEntry).join('\n');
6262
6400
  const full = `:root {\n${inner}\n}`;
6263
6401
  return full;
6264
6402
  };
@@ -6366,7 +6504,6 @@ const getExtraProps = (title, onClick) => {
6366
6504
  props.title = title;
6367
6505
  }
6368
6506
  if (onClick) {
6369
- props.style = 'color: var(--vscode-textLink-foreground, #3794ff); cursor: pointer; text-decoration: none';
6370
6507
  props.tabIndex = 0;
6371
6508
  }
6372
6509
  return props;
@@ -6663,17 +6800,18 @@ const getButtonVirtualDom = (message, onClick, name, onMouseEnter, onMouseLeave)
6663
6800
  };
6664
6801
 
6665
6802
  const settingsButtonNode = {
6803
+ ariaHasPopup: 'menu',
6804
+ ariaLabel: settings(),
6666
6805
  childCount: 1,
6667
- className: SettingsButton,
6806
+ className: mergeClassNames(IconButton, SettingsButton),
6668
6807
  name: Settings,
6669
6808
  onClick: HandleClickSettings,
6670
- title: 'Settings',
6809
+ title: settings(),
6671
6810
  type: Button$1
6672
6811
  };
6673
6812
  const settingsIconNode = {
6674
6813
  childCount: 0,
6675
- className: SettingsIcon,
6676
- text: '⚙️',
6814
+ className: mergeClassNames(MaskIcon, MaskIconSettingsGear),
6677
6815
  type: Span
6678
6816
  };
6679
6817
  const getSettingsButtonVirtualDom = enabled => {
@@ -6986,7 +7124,7 @@ const render2 = (uid, diffResult) => {
6986
7124
  newState,
6987
7125
  oldState
6988
7126
  } = get$1(uid);
6989
- set$1(uid, newState, newState);
7127
+ set$2(uid, newState, newState);
6990
7128
  const commands = applyRender(oldState, newState, diffResult);
6991
7129
  return commands;
6992
7130
  };
@@ -7047,7 +7185,7 @@ const renderEventListeners = () => {
7047
7185
  preventDefault: true
7048
7186
  }, {
7049
7187
  name: HandleClickSettings,
7050
- params: ['handleClickSettings']
7188
+ params: ['handleClickSettings', ClientX, ClientY]
7051
7189
  }, {
7052
7190
  name: HandleReadmeClick,
7053
7191
  params: ['handleReadmeClick', 'event.target.nodeName', TargetHref],
@@ -7105,6 +7243,8 @@ const saveState = state => {
7105
7243
  };
7106
7244
 
7107
7245
  const commandMap = {
7246
+ 'ExtensionDetail.copyExtensionId': wrapCommand(copyExtensionId),
7247
+ 'ExtensionDetail.copyExtensionInfo': wrapCommand(copyExtensionInfo),
7108
7248
  'ExtensionDetail.copyImage': wrapCommand(copyImage),
7109
7249
  'ExtensionDetail.copyImageUrl': wrapCommand(copyImageUrl),
7110
7250
  'ExtensionDetail.copyReadmeLink': wrapCommand(copyReadmeLink),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/extension-detail-view",
3
- "version": "7.19.1",
3
+ "version": "7.20.0",
4
4
  "description": "Extension Detail View Worker",
5
5
  "repository": {
6
6
  "type": "git",