@lvce-editor/extension-detail-view 3.42.0 → 3.44.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.
|
@@ -26,7 +26,7 @@ const Installation = 'Installation';
|
|
|
26
26
|
const JsonValidation$1 = 'Json Validation';
|
|
27
27
|
const Label = 'Label';
|
|
28
28
|
const Marketplace = 'Marketplace';
|
|
29
|
-
const None$
|
|
29
|
+
const None$2 = 'None';
|
|
30
30
|
const OpenImageInNewTab = 'Open Image in New Tab';
|
|
31
31
|
const OpenInNewTab = 'Open in New Tab';
|
|
32
32
|
const ProgrammingLanguages$1 = 'Programming Languages';
|
|
@@ -69,7 +69,7 @@ const features$1 = () => {
|
|
|
69
69
|
return i18nString(Features$2);
|
|
70
70
|
};
|
|
71
71
|
const none = () => {
|
|
72
|
-
return i18nString(None$
|
|
72
|
+
return i18nString(None$2);
|
|
73
73
|
};
|
|
74
74
|
const openInNewTab = () => {
|
|
75
75
|
return i18nString(OpenInNewTab);
|
|
@@ -146,11 +146,13 @@ const featureActivationEventsEnabled = extension => {
|
|
|
146
146
|
return Array.isArray(extension.activation);
|
|
147
147
|
};
|
|
148
148
|
|
|
149
|
+
const None$1 = 'none';
|
|
149
150
|
const Panel = 'panel';
|
|
150
151
|
const Tab$1 = 'tab';
|
|
151
152
|
const TabList = 'tablist';
|
|
152
153
|
const AriaRoles = {
|
|
153
154
|
__proto__: null,
|
|
155
|
+
None: None$1,
|
|
154
156
|
Panel,
|
|
155
157
|
Tab: Tab$1,
|
|
156
158
|
TabList};
|
|
@@ -688,10 +690,15 @@ const getScrollToTopVirtualDom = scrollToTopButtonEnabled => {
|
|
|
688
690
|
return [{
|
|
689
691
|
type: VirtualDomElements.Button,
|
|
690
692
|
className: ScrollToTopButton,
|
|
691
|
-
childCount:
|
|
693
|
+
childCount: 1,
|
|
692
694
|
onClick: HandleClickScrollToTop,
|
|
693
695
|
ariaLabel: scrollToTop(),
|
|
694
696
|
name: ScrollToTop
|
|
697
|
+
}, {
|
|
698
|
+
type: VirtualDomElements.Div,
|
|
699
|
+
className: 'MaskIcon MaskIconChevronUp',
|
|
700
|
+
childCount: 0,
|
|
701
|
+
role: AriaRoles.None
|
|
695
702
|
}];
|
|
696
703
|
};
|
|
697
704
|
|
|
@@ -2115,7 +2122,7 @@ const create = (uid, uri, x, y, width, height, platform, assetDir) => {
|
|
|
2115
2122
|
description: '',
|
|
2116
2123
|
detailsVirtualDom: [],
|
|
2117
2124
|
displaySize: '',
|
|
2118
|
-
|
|
2125
|
+
installationEntries: [],
|
|
2119
2126
|
extension: {},
|
|
2120
2127
|
extensionId: '',
|
|
2121
2128
|
extensionVersion: '',
|
|
@@ -2133,7 +2140,7 @@ const create = (uid, uri, x, y, width, height, platform, assetDir) => {
|
|
|
2133
2140
|
resources: [],
|
|
2134
2141
|
scrollSource: 0,
|
|
2135
2142
|
scrollToTopButtonEnabled: false,
|
|
2136
|
-
|
|
2143
|
+
marketplaceEntries: [],
|
|
2137
2144
|
selectedFeature: '',
|
|
2138
2145
|
selectedTab: '',
|
|
2139
2146
|
settings: [],
|
|
@@ -3049,10 +3056,9 @@ const loadContent = async (state, platform, savedState) => {
|
|
|
3049
3056
|
iconSrc,
|
|
3050
3057
|
name
|
|
3051
3058
|
} = headerData;
|
|
3052
|
-
const readmeUrl = join(
|
|
3053
|
-
join(
|
|
3054
|
-
const hasReadme = await existsFile();
|
|
3055
|
-
const hasChangelog = await existsFile();
|
|
3059
|
+
const readmeUrl = join(extensionUri, 'README.md');
|
|
3060
|
+
join(extensionUri, 'CHANGELOG.md');
|
|
3061
|
+
const [hasReadme, hasChangelog] = await Promise.all([existsFile(), existsFile()]);
|
|
3056
3062
|
const readmeContent = await loadReadmeContent(readmeUrl);
|
|
3057
3063
|
const baseUrl = getBaseUrl(extension.path, platform);
|
|
3058
3064
|
const readmeHtml = await renderMarkdown(readmeContent, {
|
|
@@ -3094,7 +3100,7 @@ const loadContent = async (state, platform, savedState) => {
|
|
|
3094
3100
|
description,
|
|
3095
3101
|
detailsVirtualDom,
|
|
3096
3102
|
displaySize,
|
|
3097
|
-
|
|
3103
|
+
installationEntries,
|
|
3098
3104
|
extension,
|
|
3099
3105
|
extensionId,
|
|
3100
3106
|
extensionVersion,
|
|
@@ -3108,7 +3114,7 @@ const loadContent = async (state, platform, savedState) => {
|
|
|
3108
3114
|
resources,
|
|
3109
3115
|
scrollSource: Script,
|
|
3110
3116
|
scrollToTopButtonEnabled: true,
|
|
3111
|
-
|
|
3117
|
+
marketplaceEntries,
|
|
3112
3118
|
selectedTab,
|
|
3113
3119
|
sizeOnDisk: size,
|
|
3114
3120
|
sizeValue,
|
|
@@ -3284,7 +3290,7 @@ const getChildCount = (additionalDetails, scrollToTopEnabled) => {
|
|
|
3284
3290
|
}
|
|
3285
3291
|
return count;
|
|
3286
3292
|
};
|
|
3287
|
-
const getDetailsVirtualDom = (sanitizedReadmeHtml, width, scrollToTopButtonEnabled, categories$1, resources$1, showAdditionalDetailsBreakpoint,
|
|
3293
|
+
const getDetailsVirtualDom = (sanitizedReadmeHtml, width, scrollToTopButtonEnabled, categories$1, resources$1, showAdditionalDetailsBreakpoint, installationEntries, marketplaceEntries) => {
|
|
3288
3294
|
const firstHeading = installation();
|
|
3289
3295
|
const secondHeading = marketplace();
|
|
3290
3296
|
const thirdHeading = categories();
|
|
@@ -3351,7 +3357,7 @@ const getFeaturesVirtualDom = (features, selectedFeature, state) => {
|
|
|
3351
3357
|
const getExtensionDetailContentVirtualDom = (sanitizedReadmeHtml, selectedTab, width, scrollToTopButtonEnabled, categories, resources, breakpoint, changelogDom, state) => {
|
|
3352
3358
|
switch (selectedTab) {
|
|
3353
3359
|
case Details:
|
|
3354
|
-
return getDetailsVirtualDom(sanitizedReadmeHtml, width, scrollToTopButtonEnabled, categories, resources, breakpoint, state.
|
|
3360
|
+
return getDetailsVirtualDom(sanitizedReadmeHtml, width, scrollToTopButtonEnabled, categories, resources, breakpoint, state.installationEntries, state.marketplaceEntries);
|
|
3355
3361
|
case Features:
|
|
3356
3362
|
return getFeaturesVirtualDom(state.features, state.selectedFeature, state);
|
|
3357
3363
|
case Changelog:
|