@eodash/eodash 5.0.0-rc.2.1 → 5.0.0-rc.2.3

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.
Files changed (59) hide show
  1. package/core/client/components/DashboardLayout.vue +3 -2
  2. package/core/client/components/DynamicWebComponent.vue +10 -3
  3. package/core/client/components/EodashOverlay.vue +56 -0
  4. package/core/client/components/Footer.vue +1 -15
  5. package/core/client/components/Header.vue +1 -1
  6. package/core/client/components/MobileLayout.vue +1 -0
  7. package/core/client/composables/DefineTemplate.js +13 -2
  8. package/core/client/composables/DefineWidgets.js +9 -4
  9. package/core/client/composables/EodashMap.js +2 -1
  10. package/core/client/eodash.js +18 -11
  11. package/core/client/eodashSTAC/EodashCollection.js +70 -35
  12. package/core/client/eodashSTAC/createLayers.js +21 -2
  13. package/core/client/eodashSTAC/helpers.js +7 -5
  14. package/core/client/types.ts +18 -13
  15. package/core/client/utils/index.js +112 -32
  16. package/core/client/utils/states.js +43 -0
  17. package/core/client/views/Dashboard.vue +26 -6
  18. package/dist/client/{DashboardLayout-BjUs7mYs.js → DashboardLayout-Reny_s87.js} +6 -6
  19. package/dist/client/{DynamicWebComponent-rIFx5c0f.js → DynamicWebComponent-DQPKIscC.js} +11 -4
  20. package/dist/client/{EodashDatePicker-brJlj1aQ.js → EodashDatePicker-E5GjnQQ2.js} +3 -3
  21. package/dist/client/{EodashItemFilter-C2i4lnM1.js → EodashItemFilter-DN77Uqgg.js} +1 -1
  22. package/dist/client/{EodashLayerControl-DNQzPQQ4.js → EodashLayerControl-DduVhg2O.js} +10 -3
  23. package/dist/client/{EodashLayoutSwitcher-gLe7G8Qn.js → EodashLayoutSwitcher-CeNnYuaC.js} +2 -2
  24. package/dist/client/{EodashMap-LOzTlvrM.js → EodashMap-C3bgcNJk.js} +10 -4
  25. package/dist/client/{EodashMapBtns-UXOupU5J.js → EodashMapBtns-B73UApEn.js} +4 -4
  26. package/dist/client/{EodashProcess-BlkqUdzj.js → EodashProcess-IQPnj17j.js} +14 -14
  27. package/dist/client/{EodashStacInfo-Df3LXKAw.js → EodashStacInfo-CeZqI75-.js} +1 -1
  28. package/dist/client/{EodashTools-BrqH4IDP.js → EodashTools-CAE604ZJ.js} +4 -4
  29. package/dist/client/{ExportState-DVosrSNY.js → ExportState-DXw8Dwvk.js} +4 -4
  30. package/dist/client/Footer-Bl9tQTyj.js +119 -0
  31. package/dist/client/{Header-DYMnh4of.js → Header-qH_kBs-u.js} +5 -5
  32. package/dist/client/{MobileLayout-Df4Z1bMl.js → MobileLayout-Du5n5XyY.js} +11 -11
  33. package/dist/client/{PopUp-BFcSuX3b.js → PopUp-B12NWJHU.js} +3 -3
  34. package/dist/client/{VImg-BO2Ysvsu.js → VImg-CjsuV4n9.js} +2 -2
  35. package/dist/client/{VMain-fx1gaM7Y.js → VMain-B11EjLm6.js} +1 -1
  36. package/dist/client/{VOverlay-CiQn3F6n.js → VOverlay-CLR2s8AQ.js} +3 -3
  37. package/dist/client/{VTooltip-DKOCofTl.js → VTooltip-DqyE5_aG.js} +3 -3
  38. package/dist/client/{WidgetsContainer-DL0bdnjh.js → WidgetsContainer-YI9ZycgC.js} +1 -1
  39. package/dist/client/{asWebComponent-N7ChSAQG.js → asWebComponent-DBkwthjq.js} +382 -115
  40. package/dist/client/eo-dash.css +2 -2
  41. package/dist/client/eo-dash.js +1 -1
  42. package/dist/client/{forwardRefs-C2UOEnvr.js → forwardRefs-BTYtR3pq.js} +1 -1
  43. package/dist/client/{index-BXi80Gr9.js → index-BhfdO0rU.js} +1 -1
  44. package/dist/client/{transition-w_2EtUxa.js → transition-B79onGGb.js} +1 -1
  45. package/dist/types/core/client/components/EodashOverlay.vue.d.ts +2 -0
  46. package/dist/types/core/client/eodashSTAC/EodashCollection.d.ts +36 -7
  47. package/dist/types/core/client/eodashSTAC/createLayers.d.ts +20 -0
  48. package/dist/types/core/client/eodashSTAC/helpers.d.ts +9 -6
  49. package/dist/types/core/client/types.d.ts +15 -11
  50. package/dist/types/core/client/utils/index.d.ts +1 -1
  51. package/dist/types/core/client/utils/states.d.ts +43 -0
  52. package/dist/types/widgets/EodashStacInfo.vue.d.ts +2 -2
  53. package/dist/types/widgets/PopUp.vue.d.ts +2 -2
  54. package/package.json +2 -1
  55. package/widgets/EodashDatePicker.vue +18 -0
  56. package/widgets/EodashLayerControl.vue +7 -0
  57. package/widgets/EodashMap.vue +7 -1
  58. package/widgets/EodashProcess.vue +13 -13
  59. package/dist/client/Footer-tjsscQ7O.js +0 -141
@@ -1,43 +1,123 @@
1
1
  import log from "loglevel";
2
2
  import { collectionsPalette } from "./states";
3
+ import WebFontLoader from "webfontloader";
4
+
3
5
  /**
4
6
  * Loads font in the app using `webfontloader`
5
7
  *
6
- * @param {string} [family]
7
- * @param {string} [link]
8
- * @param {boolean} [isWebComponent]
9
- * @returns {Promise<string>} - Font family name
8
+ * @param {import("@/types").Eodash["brand"]["font"]} fontConfig
9
+ * @param {boolean} isWebComponent
10
+ * @returns {Promise<string[]>} - Font family name
10
11
  * @see {@link "https://github.com/typekit/webfontloader"}
11
12
  */
12
- export const loadFont = async (
13
- family = "",
14
- link = "",
15
- isWebComponent = false,
16
- ) => {
17
- if (family && link) {
18
- const WebFontLoader = (await import("webfontloader")).default;
19
- WebFontLoader.load({
20
- classes: false,
21
- custom: {
22
- // Use FVD notation to include families https://github.com/typekit/fvd
23
- families: [family],
24
- // Path to stylesheet that defines font-face
25
- urls: [link],
26
- },
27
- fontactive(familyName, _fvd) {
28
- const stylesheet = new CSSStyleSheet();
29
- const styles = isWebComponent
30
- ? `eo-dash {font-family: ${familyName};}`
31
- : `* {font-family: ${familyName};}`;
32
- stylesheet.replaceSync(styles);
33
- document.adoptedStyleSheets.push(stylesheet);
34
- },
35
- fontinactive(familyName, _fvd) {
36
- throw new Error(`error loading font: ${familyName}`);
37
- },
38
- });
13
+ export const loadFont = async (fontConfig, isWebComponent) => {
14
+ if (!fontConfig) {
15
+ return [];
16
+ }
17
+
18
+ let headerFamily = "",
19
+ bodyFamily = "",
20
+ headerLink = "",
21
+ bodyLink = "";
22
+ if ("headers" in fontConfig) {
23
+ headerFamily = fontConfig?.headers?.family;
24
+ headerLink = fontConfig.headers.link ?? "";
25
+ bodyFamily = fontConfig?.body?.family;
26
+ bodyLink = fontConfig.body.link ?? "";
27
+ } else {
28
+ headerFamily = fontConfig.family;
29
+ headerLink = fontConfig.link ?? "";
30
+ bodyFamily = fontConfig?.family;
31
+ bodyLink = fontConfig.link ?? "";
32
+ }
33
+ const families =
34
+ headerFamily === bodyFamily ? [headerFamily] : [headerFamily, bodyFamily];
35
+ const urls = [];
36
+ if (bodyLink && headerLink) {
37
+ if (bodyLink !== headerLink) {
38
+ urls.push(bodyLink);
39
+ urls.push(headerLink);
40
+ } else {
41
+ urls.push(bodyLink);
42
+ }
39
43
  }
40
- return family;
44
+
45
+ WebFontLoader.load({
46
+ classes: false,
47
+ custom: {
48
+ // Use FVD notation to include families https://github.com/typekit/fvd
49
+ families,
50
+ // Path to stylesheet that defines font-face
51
+ urls,
52
+ },
53
+ fontactive(familyName, _fvd) {
54
+ const stylesheet = new CSSStyleSheet();
55
+
56
+ const bodyRule = `
57
+ ${isWebComponent ? "eo-dash" : `:root`} {
58
+ font-family: ${bodyFamily};
59
+ --vc-font-family: ${bodyFamily};
60
+ }
61
+ eox-layercontrol,
62
+ eox-map,
63
+ eox-jsonform,
64
+ eox-timecontrol,
65
+ eox-itemfilter,
66
+ eox-chart,
67
+ eox-stacinfo{
68
+ --eox-body-font-family: ${bodyFamily};
69
+ font-family: ${bodyFamily}
70
+ ;
71
+ }
72
+ *[class*="text-body"]{
73
+ font-family: ${bodyFamily}
74
+ }
75
+ `;
76
+
77
+ const headersRule = `
78
+ ${
79
+ isWebComponent
80
+ ? `
81
+ eo-dash h1,
82
+ eo-dash h2,
83
+ eo-dash h3,
84
+ eo-dash h4,
85
+ eo-dash h5,
86
+ eo-dash *[class*="header"]
87
+ `
88
+ : `
89
+ h1,
90
+ h2,
91
+ h3,
92
+ h4,
93
+ h5,
94
+ *[class*="header"]`
95
+ } {
96
+ font-family: ${headerFamily} !important;
97
+ }
98
+ eox-layercontrol,
99
+ eox-map,
100
+ eox-jsonform,
101
+ eox-timecontrol,
102
+ eox-itemfilter,
103
+ eox-chart,
104
+ eox-stacinfo {
105
+ --eox-header-font-family: ${headerFamily};
106
+ `;
107
+ const isOne = headerFamily && headerFamily === bodyFamily;
108
+ const styles = isOne
109
+ ? bodyRule + "\n" + headersRule
110
+ : familyName == bodyFamily
111
+ ? bodyRule
112
+ : headersRule;
113
+ stylesheet.replaceSync(styles);
114
+ document?.adoptedStyleSheets?.push(stylesheet);
115
+ },
116
+ fontinactive(familyName, _fvd) {
117
+ throw new Error(`error loading font: ${familyName}`);
118
+ },
119
+ });
120
+ return families;
41
121
  };
42
122
 
43
123
  /**
@@ -1,3 +1,12 @@
1
+ import {
2
+ mdiBarley,
3
+ mdiCurrencyEur,
4
+ mdiHospitalBoxOutline,
5
+ mdiImageFilterHdr,
6
+ mdiSetCenter,
7
+ mdiWater,
8
+ mdiWeatherWindy,
9
+ } from "@mdi/js";
1
10
  import { reactive, ref, shallowReactive } from "vue";
2
11
 
3
12
  /**
@@ -37,3 +46,37 @@ export const collectionsPalette = reactive([
37
46
  "#56B4E9",
38
47
  "#D55E00",
39
48
  ]);
49
+
50
+ /**
51
+ * Object containing data themes and their associated brand properties (icon and color).
52
+ */
53
+ export const dataThemesBrands = {
54
+ agriculture: {
55
+ icon: mdiBarley,
56
+ color: "#F2AF25",
57
+ },
58
+ water: {
59
+ icon: mdiWater,
60
+ color: "#73A6C7",
61
+ },
62
+ land: {
63
+ icon: mdiImageFilterHdr,
64
+ color: "#019E73",
65
+ },
66
+ health: {
67
+ icon: mdiHospitalBoxOutline,
68
+ color: "#497FA9",
69
+ },
70
+ combined: {
71
+ icon: mdiSetCenter,
72
+ color: "#56B4E9",
73
+ },
74
+ air: {
75
+ icon: mdiWeatherWindy,
76
+ color: "#475faf",
77
+ },
78
+ economy: {
79
+ icon: mdiCurrencyEur,
80
+ color: "#8E81AF",
81
+ },
82
+ };
@@ -1,6 +1,7 @@
1
1
  <template>
2
2
  <HeaderComponent v-if="!eodash.brand.noLayout" />
3
3
  <ErrorAlert v-model="error" />
4
+ <EodashOverlay />
4
5
  <Suspense>
5
6
  <TemplateComponent :style="{ height: templateHeight }" />
6
7
  <template #fallback>
@@ -21,6 +22,7 @@ import { useDisplay } from "vuetify/lib/framework.mjs";
21
22
  import { loadFont } from "@/utils";
22
23
  import Loading from "@/components/Loading.vue";
23
24
  import ErrorAlert from "@/components/ErrorAlert.vue";
25
+ import EodashOverlay from "@/components/EodashOverlay.vue";
24
26
 
25
27
  const props = defineProps({
26
28
  config: {
@@ -31,20 +33,17 @@ const props = defineProps({
31
33
  default: false,
32
34
  },
33
35
  });
34
- const eodash = await useEodashRuntime(props.config);
35
36
 
36
37
  useURLSearchParametersSync();
37
38
 
39
+ const eodash = await useEodashRuntime(props.config);
40
+
38
41
  const theme = useUpdateTheme("dashboardTheme", {
39
42
  ...(eodash.brand?.theme ?? {}),
40
43
  });
41
44
  theme.global.name.value = "dashboardTheme";
42
45
 
43
- await loadFont(
44
- eodash.brand?.font?.family,
45
- eodash.brand?.font?.link,
46
- props.isWebComponent,
47
- );
46
+ await loadFont(eodash.brand?.font, props.isWebComponent);
48
47
 
49
48
  const { loadSTAC } = useSTAcStore();
50
49
  await loadSTAC();
@@ -88,4 +87,25 @@ div.v-application__wrap {
88
87
  eo-dash {
89
88
  overflow: hidden;
90
89
  }
90
+ /* set eox-elements colors css vars to match the theme */
91
+ /*
92
+ eox-layercontrol,
93
+ eox-map,
94
+ eox-drawtools,
95
+ eox-timecontrol,
96
+ eox-jsonform,
97
+ eox-chart,
98
+ eox-stacinfo,
99
+ eox-itemfilter {
100
+ --primary-color: rgb(var(--v-theme-primary));
101
+ --eox-primary-color: rgb(var(--v-theme-primary));
102
+ --eox-secondary-color: rgb(var(--v-theme-secondary));
103
+ --eox-accent-color: rgb(var(--v-theme-accent));
104
+ --eox-error-color: rgb(var(--v-theme-error));
105
+ --eox-info-color: rgb(var(--v-theme-info));
106
+ --eox-success-color: rgb(var(--v-theme-success));
107
+ --eox-warning-color: rgb(var(--v-theme-warning));
108
+ --range-slider-color: rgb(var(--v-theme-primary));
109
+ --range-slider-track-color: rgb(var(--v-theme-on-primary));
110
+ } */
91
111
  </style>
@@ -1,7 +1,7 @@
1
1
  import { openBlock, createBlock, withCtx, createElementVNode, unref, normalizeStyle, createElementBlock, Suspense, resolveDynamicComponent, mergeProps, createCommentVNode, Fragment, renderList, Transition } from 'vue';
2
2
  import '@eox/layout';
3
- import { _ as _export_sfc, F as useDefineTemplate } from './asWebComponent-N7ChSAQG.js';
4
- import { V as VMain } from './VMain-fx1gaM7Y.js';
3
+ import { _ as _export_sfc, F as useDefineTemplate } from './asWebComponent-DBkwthjq.js';
4
+ import { V as VMain } from './VMain-B11EjLm6.js';
5
5
 
6
6
  const _hoisted_1 = ["gap"];
7
7
  const _hoisted_2 = ["id", "h", "w", "x", "y"];
@@ -24,7 +24,7 @@ return (_ctx, _cache) => {
24
24
  }, [
25
25
  (unref(bgWidget)?.component)
26
26
  ? (openBlock(), createElementBlock("eox-layout-item", {
27
- key: 0,
27
+ key: unref(bgWidget).id,
28
28
  class: "bg-panel bg-surface",
29
29
  style: normalizeStyle(`margin: -${unref(gap) + 1}px;`),
30
30
  x: "0",
@@ -32,7 +32,7 @@ return (_ctx, _cache) => {
32
32
  h: "12",
33
33
  w: "12"
34
34
  }, [
35
- (openBlock(), createBlock(Suspense, { suspensible: "" }, {
35
+ (openBlock(), createBlock(Suspense, null, {
36
36
  default: withCtx(() => [
37
37
  (openBlock(), createBlock(resolveDynamicComponent(unref(bgWidget)?.component), mergeProps({ id: "bg-widget" }, unref(bgWidget)?.props), null, 16 /* FULL_PROPS */))
38
38
  ]),
@@ -56,7 +56,7 @@ return (_ctx, _cache) => {
56
56
  x: importedWidget.value.layout.x,
57
57
  y: importedWidget.value.layout.y
58
58
  }, [
59
- (openBlock(), createBlock(Suspense, { suspensible: "" }, {
59
+ (openBlock(), createBlock(Suspense, null, {
60
60
  default: withCtx(() => [
61
61
  (openBlock(), createBlock(resolveDynamicComponent(importedWidget.value.component), mergeProps({
62
62
  key: importedWidget.value.id,
@@ -79,6 +79,6 @@ return (_ctx, _cache) => {
79
79
  }
80
80
 
81
81
  };
82
- const DashboardLayout = /*#__PURE__*/_export_sfc(_sfc_main, [['__scopeId',"data-v-ebeeb1d1"]]);
82
+ const DashboardLayout = /*#__PURE__*/_export_sfc(_sfc_main, [['__scopeId',"data-v-7294ae56"]]);
83
83
 
84
84
  export { DashboardLayout as default };
@@ -1,5 +1,5 @@
1
1
  import { withAsyncContext, ref, onMounted, onUnmounted, openBlock, createElementBlock, createBlock, resolveDynamicComponent, mergeProps } from 'vue';
2
- import { $ as useSTAcStore } from './asWebComponent-N7ChSAQG.js';
2
+ import { $ as useSTAcStore } from './asWebComponent-DBkwthjq.js';
3
3
 
4
4
  const _hoisted_1 = { class: "d-flex flex-column fill-height overflow-auto" };
5
5
 
@@ -36,7 +36,7 @@ const props = /** @type {import("@/types").WebComponentProps} */ (
36
36
  const getWebComponent = async () =>
37
37
  typeof props.link === "string"
38
38
  ? await import(/* @vite-ignore */ props.link)
39
- : await props.link();
39
+ : await props.link?.();
40
40
 
41
41
  const imported = !customElements.get(props.tagName)
42
42
  ? (
@@ -53,8 +53,15 @@ const defined = customElements.get(props.tagName);
53
53
 
54
54
  // if the imported link doesn't define the custom tag provided
55
55
  if (!defined && props.constructorProp) {
56
- const Constructor = imported[props.constructorProp];
57
- customElements.define(props.tagName, Constructor);
56
+ try {
57
+ const Constructor = imported[props.constructorProp];
58
+ customElements.define(props.tagName, Constructor);
59
+ } catch (e) {
60
+ console.error(
61
+ `[eodash] ${props.tagName} is not defined, please add a valid link or constructorProp`,
62
+ );
63
+ console.error(e);
64
+ }
58
65
  }
59
66
 
60
67
  const store = useSTAcStore();
@@ -1,9 +1,9 @@
1
1
  import { resolveComponent, render, h, mergeProps, useCssVars, useTemplateRef, customRef, ref, computed, reactive, toRef, watch, onMounted, openBlock, createElementBlock, createVNode, unref, createSlots, withCtx, createElementVNode, withDirectives, createBlock, createCommentVNode, toHandlers } from 'vue';
2
2
  import { DatePicker } from 'v-calendar';
3
- import { E as isObject, Y as consoleError, t as useDisplay, Z as datetime, $ as useSTAcStore, a0 as eodashCollections, a1 as collectionsPalette, a2 as makePanelTransparent, V as VBtn, y as VIcon } from './asWebComponent-N7ChSAQG.js';
3
+ import { E as isObject, Y as consoleError, t as useDisplay, Z as datetime, $ as useSTAcStore, a0 as eodashCollections, a1 as collectionsPalette, a2 as makePanelTransparent, V as VBtn, y as VIcon } from './asWebComponent-DBkwthjq.js';
4
4
  import { mdiRayEndArrow, mdiRayStartArrow } from '@mdi/js';
5
5
  import log from 'loglevel';
6
- import { V as VTooltip } from './VTooltip-DKOCofTl.js';
6
+ import { V as VTooltip } from './VTooltip-DqyE5_aG.js';
7
7
 
8
8
  // Utilities
9
9
  function useDirectiveComponent(component, props) {
@@ -132,7 +132,7 @@ const _sfc_main = {
132
132
  setup(__props) {
133
133
 
134
134
  useCssVars(_ctx => ({
135
- "45a34dce": (transform.value)
135
+ "f4706d8a": (transform.value)
136
136
  }));
137
137
 
138
138
  const { lgAndDown } = useDisplay();
@@ -1,5 +1,5 @@
1
1
  import { computed, ref, openBlock, createElementBlock, mergeProps, unref, createElementVNode, toDisplayString } from 'vue';
2
- import { t as useDisplay, $ as useSTAcStore } from './asWebComponent-N7ChSAQG.js';
2
+ import { t as useDisplay, $ as useSTAcStore } from './asWebComponent-DBkwthjq.js';
3
3
  import '@eox/itemfilter';
4
4
 
5
5
  const _hoisted_1 = [".items"];
@@ -3,12 +3,17 @@ import '@eox/layercontrol';
3
3
  import '@eox/jsonform';
4
4
  import '@eox/timecontrol';
5
5
  import 'color-legend-element';
6
- import { $ as useSTAcStore, a3 as mapCompareEl, a4 as mapEl, a5 as eodashCompareCollections, a0 as eodashCollections, a6 as layerControlFormValue, a7 as getColFromLayer } from './asWebComponent-N7ChSAQG.js';
6
+ import { $ as useSTAcStore, a3 as mapCompareEl, a4 as mapEl, a5 as eodashCompareCollections, a0 as eodashCollections, a6 as layerControlFormValue, a7 as getColFromLayer } from './asWebComponent-DBkwthjq.js';
7
7
  import { storeToRefs } from 'pinia';
8
8
 
9
9
  const _hoisted_1 = { class: "d-flex flex-column fill-height overflow-auto" };
10
10
  const _hoisted_2 = ["for"];
11
11
 
12
+ const styleOverride = `
13
+ input[type="range"] {
14
+ background:transparent !important;
15
+ }
16
+ `;
12
17
 
13
18
  const _sfc_main = {
14
19
  __name: 'EodashLayerControl',
@@ -105,6 +110,7 @@ const onLayerConfigChange = (evt) => {
105
110
  layerControlFormValue.value = evt.detail.jsonformValue;
106
111
  };
107
112
 
113
+
108
114
  return (_ctx, _cache) => {
109
115
  return (openBlock(), createElementBlock("span", _hoisted_1, [
110
116
  (showControls.value)
@@ -116,8 +122,9 @@ return (_ctx, _cache) => {
116
122
  style: {"--eox-background-color":"transparent"},
117
123
  ref_key: "eoxLayercontrol",
118
124
  ref: eoxLayercontrol,
119
- "on:layerConfig:change": onLayerConfigChange
120
- }), null, 16 /* FULL_PROPS */, _hoisted_2))
125
+ "on:layerConfig:change": onLayerConfigChange,
126
+ ".styleOverride": styleOverride
127
+ }), null, 48 /* FULL_PROPS, NEED_HYDRATION */, _hoisted_2))
121
128
  : createCommentVNode("v-if", true)
122
129
  ]))
123
130
  }
@@ -1,7 +1,7 @@
1
1
  import { ref, openBlock, createElementBlock, createVNode, withCtx, mergeProps } from 'vue';
2
- import { a2 as makePanelTransparent, y as VIcon, al as activeTemplate } from './asWebComponent-N7ChSAQG.js';
2
+ import { a2 as makePanelTransparent, y as VIcon, al as activeTemplate } from './asWebComponent-DBkwthjq.js';
3
3
  import { mdiViewDashboard } from '@mdi/js';
4
- import { V as VTooltip } from './VTooltip-DKOCofTl.js';
4
+ import { V as VTooltip } from './VTooltip-DqyE5_aG.js';
5
5
 
6
6
  const _sfc_main = {
7
7
  __name: 'EodashLayoutSwitcher',
@@ -1,7 +1,7 @@
1
1
  import { onMounted, onUnmounted, watch, nextTick, ref, toRaw, computed, openBlock, createElementBlock, createElementVNode, unref, normalizeStyle } from 'vue';
2
2
  import '@eox/map';
3
3
  import '@eox/map/src/plugins/advancedLayersAndSources';
4
- import { a8 as eoxLayersKey, $ as useSTAcStore, a9 as setMapProjFromCol, aa as posIsSetFromUrl, ab as useOnLayersUpdate, ac as EodashCollection, ad as mapPosition, a4 as mapEl, a3 as mapCompareEl, Z as datetime, a0 as eodashCollections, a5 as eodashCompareCollections, a6 as layerControlFormValue } from './asWebComponent-N7ChSAQG.js';
4
+ import { a8 as eoxLayersKey, $ as useSTAcStore, a9 as setMapProjFromCol, aa as posIsSetFromUrl, ab as useOnLayersUpdate, ac as EodashCollection, ad as mapPosition, a4 as mapEl, a3 as mapCompareEl, Z as datetime, a0 as eodashCollections, a5 as eodashCompareCollections, a6 as layerControlFormValue } from './asWebComponent-DBkwthjq.js';
5
5
  import { storeToRefs } from 'pinia';
6
6
  import log from 'loglevel';
7
7
  import { useEventBus } from '@vueuse/core';
@@ -105,7 +105,7 @@ const createLayersConfig = async (
105
105
  await EodashCollection.getIndicatorLayers(selectedIndicator);
106
106
  const geodbLayer = EodashCollection.getGeoDBLayer(eodashCols);
107
107
  if (geodbLayer) {
108
- dataLayers.layers.push(geodbLayer);
108
+ dataLayers.layers.unshift(geodbLayer);
109
109
  }
110
110
  const baseLayers = {
111
111
  type: "Group",
@@ -425,7 +425,12 @@ const props = __props;
425
425
 
426
426
  /** @type {import("vue").Ref<Exclude<import("@/types").EodashStyleJson["tooltip"], undefined>>} */
427
427
  const tooltipProperties = ref([]);
428
-
428
+ /** @type {import("@eox/map").EOxMap["controls"]} */
429
+ const controls = {
430
+ Attribution: {
431
+ collapsible: true,
432
+ },
433
+ };
429
434
  const initialCenter = toRaw([
430
435
  mapPosition.value?.[0] ?? props.center?.[0],
431
436
  mapPosition.value?.[1] ?? props.center?.[1],
@@ -553,7 +558,8 @@ return (_ctx, _cache) => {
553
558
  ".animationOptions": animationOptions,
554
559
  ".center": unref(initialCenter),
555
560
  ".zoom": unref(initialZoom),
556
- ".layers": eoxMapLayers.value
561
+ ".layers": eoxMapLayers.value,
562
+ ".controls": controls
557
563
  }, [
558
564
  createElementVNode("eox-map-tooltip", {
559
565
  style: normalizeStyle(tooltipStyles.value),
@@ -1,9 +1,9 @@
1
1
  import { computed, ref, openBlock, createElementBlock, createBlock, unref, createCommentVNode, createVNode, withCtx } from 'vue';
2
- import { _ as _export_sfc, t as useDisplay, a2 as makePanelTransparent, V as VBtn, ae as availableMapProjection, af as changeMapProjection, ag as setActiveTemplate } from './asWebComponent-N7ChSAQG.js';
2
+ import { _ as _export_sfc, t as useDisplay, a2 as makePanelTransparent, V as VBtn, ae as availableMapProjection, af as changeMapProjection, ag as setActiveTemplate } from './asWebComponent-DBkwthjq.js';
3
3
  import { mdiMapPlus, mdiEarthBox, mdiCompare } from '@mdi/js';
4
- import ExportState from './ExportState-DVosrSNY.js';
5
- import _sfc_main$1 from './PopUp-BFcSuX3b.js';
6
- import _sfc_main$2 from './EodashItemFilter-C2i4lnM1.js';
4
+ import ExportState from './ExportState-DXw8Dwvk.js';
5
+ import _sfc_main$1 from './PopUp-B12NWJHU.js';
6
+ import _sfc_main$2 from './EodashItemFilter-DN77Uqgg.js';
7
7
 
8
8
  const _sfc_main = {
9
9
  __name: 'EodashMapBtns',
@@ -2,7 +2,7 @@ import { createVNode, watch, onMounted, nextTick, ref, useTemplateRef, computed,
2
2
  import '@eox/chart';
3
3
  import '@eox/drawtools';
4
4
  import '@eox/jsonform';
5
- import { p as propsFactory, b as makeComponentProps, H as makeDimensionProps, c as makeTagProps, g as genericComponent, f as useRtl, J as useDimension, a as useRender, ah as axios, ai as getLayers, a4 as mapEl, aj as extractLayerConfig, a8 as eoxLayersKey, $ as useSTAcStore, ab as useOnLayersUpdate, V as VBtn } from './asWebComponent-N7ChSAQG.js';
5
+ import { p as propsFactory, b as makeComponentProps, H as makeDimensionProps, c as makeTagProps, g as genericComponent, f as useRtl, J as useDimension, a as useRender, ah as axios, ai as getLayers, a4 as mapEl, aj as extractLayerConfig, a8 as eoxLayersKey, $ as useSTAcStore, ab as useOnLayersUpdate, V as VBtn } from './asWebComponent-DBkwthjq.js';
6
6
  import { storeToRefs } from 'pinia';
7
7
  import { useEventBus } from '@vueuse/core';
8
8
  import { isMulti } from '@eox/jsonform/src/custom-inputs/spatial/utils';
@@ -723,7 +723,19 @@ const downloadResults = () => {
723
723
  };
724
724
  onMounted(async () => {
725
725
  // wait for the layers to be rendered
726
- if (mapEl.value?.layers.length <= 1) {
726
+ if (mapEl.value?.layers.length > 1) {
727
+ await initProcess({
728
+ //@ts-expect-error TODO
729
+ selectedStac,
730
+ jsonformEl,
731
+ jsonformSchema,
732
+ chartSpec,
733
+ isProcessed,
734
+ processResults,
735
+ loading,
736
+ isPolling,
737
+ });
738
+ } else {
727
739
  layersEvents.once(async () => {
728
740
  await initProcess({
729
741
  //@ts-expect-error TODO
@@ -737,18 +749,6 @@ onMounted(async () => {
737
749
  isPolling,
738
750
  });
739
751
  });
740
- } else {
741
- await initProcess({
742
- //@ts-expect-error TODO
743
- selectedStac,
744
- jsonformEl,
745
- jsonformSchema,
746
- chartSpec,
747
- isProcessed,
748
- processResults,
749
- loading,
750
- isPolling,
751
- });
752
752
  }
753
753
  });
754
754
 
@@ -1,6 +1,6 @@
1
1
  import { openBlock, createElementBlock, createElementVNode, unref } from 'vue';
2
2
  import '@eox/stacinfo';
3
- import { ak as currentUrl } from './asWebComponent-N7ChSAQG.js';
3
+ import { ak as currentUrl } from './asWebComponent-DBkwthjq.js';
4
4
 
5
5
  const _hoisted_1 = { class: "flex-grow-1 fill-height overflow-auto" };
6
6
  const _hoisted_2 = [".for", ".allowHtml", ".body", ".featured", ".footer", ".styleOverride", ".header", ".subheader", ".tags"];
@@ -1,9 +1,9 @@
1
1
  import { ref, computed, openBlock, createElementBlock, createElementVNode, createBlock, unref, createCommentVNode, createVNode, withCtx, mergeProps } from 'vue';
2
- import _sfc_main$2 from './PopUp-BFcSuX3b.js';
3
- import _sfc_main$3 from './EodashItemFilter-C2i4lnM1.js';
4
- import _sfc_main$1 from './EodashLayoutSwitcher-gLe7G8Qn.js';
2
+ import _sfc_main$2 from './PopUp-B12NWJHU.js';
3
+ import _sfc_main$3 from './EodashItemFilter-DN77Uqgg.js';
4
+ import _sfc_main$1 from './EodashLayoutSwitcher-CeNnYuaC.js';
5
5
  import { mdiViewDashboard, mdiPlus } from '@mdi/js';
6
- import { t as useDisplay, a2 as makePanelTransparent, V as VBtn } from './asWebComponent-N7ChSAQG.js';
6
+ import { t as useDisplay, a2 as makePanelTransparent, V as VBtn } from './asWebComponent-DBkwthjq.js';
7
7
 
8
8
  const _hoisted_1 = { class: "d-flex flex-row justify-space-between pa-4 align-center" };
9
9
 
@@ -1,9 +1,9 @@
1
1
  import { createVNode, Fragment, computed, withDirectives, mergeProps, resolveDirective, toRef, mergeModels, useModel, ref, openBlock, createBlock, withCtx, createElementVNode, createTextVNode, toDisplayString, unref, createElementBlock, createCommentVNode, renderList } from 'vue';
2
2
  import { mdiClipboardCheckOutline, mdiContentCopy } from '@mdi/js';
3
- import _sfc_main$1 from './PopUp-BFcSuX3b.js';
4
- import { an as createSimpleFunctional, g as genericComponent, b as makeComponentProps, D as provideDefaults, a as useRender, p as propsFactory, c as makeTagProps, I as IconValue, K as makeBorderProps, A as makeDensityProps, M as makeRoundedProps, ao as makeSizeProps, d as makeThemeProps, ap as makeVariantProps, e as provideTheme, N as useBorder, aq as useVariant, B as useDensity, P as useRounded, ar as useSize, y as VIcon, Q as VDefaultsProvider, as as genOverlays, H as makeDimensionProps, L as makeElevationProps, at as makeLoaderProps, au as makeLocationProps, av as makePositionProps, aw as makeRouterProps, ax as Ripple, J as useDimension, O as useElevation, ay as useLoader, az as useLocation, aA as usePosition, aB as useLink, aC as LoaderSlot, u as useTextColor, q as convertToUnit, _ as _export_sfc, ai as getLayers, aD as removeUnneededProperties, aE as VRow, aF as VCol, V as VBtn, aG as copyToClipBoard, ad as mapPosition, ae as availableMapProjection } from './asWebComponent-N7ChSAQG.js';
5
- import { a as VExpandTransition } from './index-BXi80Gr9.js';
6
- import { V as VImg } from './VImg-BO2Ysvsu.js';
3
+ import _sfc_main$1 from './PopUp-B12NWJHU.js';
4
+ import { an as createSimpleFunctional, g as genericComponent, b as makeComponentProps, D as provideDefaults, a as useRender, p as propsFactory, c as makeTagProps, I as IconValue, K as makeBorderProps, A as makeDensityProps, M as makeRoundedProps, ao as makeSizeProps, d as makeThemeProps, ap as makeVariantProps, e as provideTheme, N as useBorder, aq as useVariant, B as useDensity, P as useRounded, ar as useSize, y as VIcon, Q as VDefaultsProvider, as as genOverlays, H as makeDimensionProps, L as makeElevationProps, at as makeLoaderProps, au as makeLocationProps, av as makePositionProps, aw as makeRouterProps, ax as Ripple, J as useDimension, O as useElevation, ay as useLoader, az as useLocation, aA as usePosition, aB as useLink, aC as LoaderSlot, u as useTextColor, q as convertToUnit, _ as _export_sfc, ai as getLayers, aD as removeUnneededProperties, aE as VRow, aF as VCol, V as VBtn, aG as copyToClipBoard, ad as mapPosition, ae as availableMapProjection } from './asWebComponent-DBkwthjq.js';
5
+ import { a as VExpandTransition } from './index-BhfdO0rU.js';
6
+ import { V as VImg } from './VImg-CjsuV4n9.js';
7
7
 
8
8
  // Styles
9
9
  const VSpacer = createSimpleFunctional('v-spacer', 'div', 'VSpacer');