@nectary/assets 3.6.11 → 3.6.13
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.
- package/bundle.ts +1 -0
- package/package.json +2 -2
- package/utils/shared/cdn-loader.js +9 -2
package/bundle.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nectary/assets",
|
|
3
|
-
"version": "3.6.
|
|
3
|
+
"version": "3.6.13",
|
|
4
4
|
"files": [
|
|
5
5
|
"**/*/*.css",
|
|
6
6
|
"**/*/*.json",
|
|
@@ -38,6 +38,6 @@
|
|
|
38
38
|
"vite": "^7.0.6"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
|
-
"@nectary/theme-base": "1.16.
|
|
41
|
+
"@nectary/theme-base": "1.16.2"
|
|
42
42
|
}
|
|
43
43
|
}
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
const getNonEsmShModuleFile = (modulePath) => {
|
|
2
|
+
if (modulePath === "bundle") {
|
|
3
|
+
return "bundle.js";
|
|
4
|
+
}
|
|
5
|
+
return `${modulePath}/index.js`;
|
|
6
|
+
};
|
|
1
7
|
const getImportPath = (cdnUrl, version, modulePath) => {
|
|
2
8
|
if (cdnUrl.length === 0) {
|
|
3
9
|
return null;
|
|
@@ -9,10 +15,11 @@ const getImportPath = (cdnUrl, version, modulePath) => {
|
|
|
9
15
|
}
|
|
10
16
|
return `${cdnUrl}/${modulePath}`;
|
|
11
17
|
}
|
|
18
|
+
const moduleFile = getNonEsmShModuleFile(modulePath);
|
|
12
19
|
if (version.length !== 0) {
|
|
13
|
-
return `${cdnUrl}/${version}/${
|
|
20
|
+
return `${cdnUrl}/${version}/${moduleFile}`;
|
|
14
21
|
}
|
|
15
|
-
return `${cdnUrl}/latest/${
|
|
22
|
+
return `${cdnUrl}/latest/${moduleFile}`;
|
|
16
23
|
};
|
|
17
24
|
const getCssImportPath = (cdnUrl, version, modulePath) => {
|
|
18
25
|
if (cdnUrl.length === 0) {
|