@vcmap/ui 6.1.4 → 6.1.5
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/build/build.js +18 -3
- package/dist/.htaccess +1 -1
- package/dist/assets/cesium.js +1 -1
- package/dist/assets/{core-413b148f.js → core-865657d3.js} +2076 -2065
- package/dist/assets/core.js +1 -1
- package/dist/assets/ol.js +1 -1
- package/dist/assets/start.js +3 -0
- package/dist/assets/{ui-005255f5.css → ui-1641b3cc.css} +1 -1
- package/dist/assets/{ui-005255f5.js → ui-1641b3cc.js} +742 -743
- package/dist/assets/ui.js +1 -1
- package/dist/assets/vue.js +1 -1
- package/dist/assets/{vuetify-a662f5cc.js → vuetify-42302ee6.js} +1 -1
- package/dist/assets/vuetify.js +1 -1
- package/dist/index.html +1 -5
- package/package.json +2 -2
- package/src/components/vector-properties/VcsVectorPropertiesComponent.vue +2 -2
- package/src/contentTree/wmsGroupContentTreeItem.js +1 -0
- package/src/navigation/MapNavigation.vue +3 -4
- package/src/navigation/MapNavigation.vue.d.ts +1 -1
- package/src/vuePlugins/vuetify.js +1 -0
- /package/dist/assets/{cesium-b1e1b462.js → cesium-0a40465b.js} +0 -0
- /package/dist/assets/{ol-b61e7f7b.js → ol-0f71b1f1.js} +0 -0
- /package/dist/assets/{vue-9b8dc9d0.js → vue-4c430de5.js} +0 -0
- /package/dist/assets/{vuetify-a662f5cc.css → vuetify-42302ee6.css} +0 -0
package/build/build.js
CHANGED
@@ -206,8 +206,23 @@ indexHTMLContent = indexHTMLContent.replace(
|
|
206
206
|
/<link[^>]*href=".*materialdesignicons\.min\.css"[^>]*>/,
|
207
207
|
'',
|
208
208
|
);
|
209
|
-
|
210
|
-
|
209
|
+
|
210
|
+
// replace @vcmap/ui with './assets/ui.js' and outsource to start.js
|
211
|
+
// We do not want to have a script tag in the index.html, because of CSP Policies.
|
212
|
+
// see https://content-security-policy.com/unsafe-inline/
|
213
|
+
const scriptRegex = /<script type="module">([\s\S]*?)<\/script>/;
|
214
|
+
const match = indexHTMLContent.match(scriptRegex);
|
215
|
+
if (match && match[1]) {
|
216
|
+
let scriptContent = match[1].trim();
|
217
|
+
scriptContent = scriptContent.replace(/@vcmap\/ui/, './ui.js');
|
218
|
+
await writeFile(path.join(assetsFolder, 'start.js'), scriptContent, {
|
219
|
+
encoding: 'utf8',
|
220
|
+
});
|
221
|
+
indexHTMLContent = indexHTMLContent.replace(
|
222
|
+
scriptRegex,
|
223
|
+
'<script src="./assets/start.js" type="module"></script>',
|
224
|
+
);
|
225
|
+
}
|
211
226
|
await writeFile(path.join(distFolder, 'index.html'), indexHTMLContent, {
|
212
227
|
encoding: 'utf8',
|
213
228
|
});
|
@@ -215,7 +230,7 @@ const htaccessContent = `
|
|
215
230
|
<FilesMatch "-[\\w\\d]{8}\\.(js|css)$">
|
216
231
|
Header set Cache-Control "public, max-age=31540000, immutable"
|
217
232
|
</FilesMatch>
|
218
|
-
<FilesMatch "(index\\.html|
|
233
|
+
<FilesMatch "(index\\.html|start\\.js|ui\\.js|vue\\.js|vuetify\\.js|ol\\.js|cesium\\.js|core\\.js)$">
|
219
234
|
Header set Cache-Control "no-store, max-age=0"
|
220
235
|
</FilesMatch>
|
221
236
|
`;
|
package/dist/.htaccess
CHANGED
@@ -2,6 +2,6 @@
|
|
2
2
|
<FilesMatch "-[\w\d]{8}\.(js|css)$">
|
3
3
|
Header set Cache-Control "public, max-age=31540000, immutable"
|
4
4
|
</FilesMatch>
|
5
|
-
<FilesMatch "(index\.html|
|
5
|
+
<FilesMatch "(index\.html|start\.js|ui\.js|vue\.js|vuetify\.js|ol\.js|cesium\.js|core\.js)$">
|
6
6
|
Header set Cache-Control "no-store, max-age=0"
|
7
7
|
</FilesMatch>
|
package/dist/assets/cesium.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export * from "./cesium-
|
1
|
+
export * from "./cesium-0a40465b.js";
|