@eodash/eodash 5.0.0-alpha.1.8 → 5.0.0-alpha.2

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 (80) hide show
  1. package/README.md +1 -1
  2. package/bin/app.js +1 -4
  3. package/bin/cli.js +26 -29
  4. package/bin/main.js +9 -0
  5. package/bin/serverConfig.js +65 -35
  6. package/bin/types.d.ts +52 -0
  7. package/bin/utils.js +91 -21
  8. package/core/App.vue +10 -12
  9. package/core/SuspensedDashboard.ce.vue +59 -0
  10. package/core/asWebComponent.d.ts +18 -0
  11. package/core/asWebComponent.js +12 -0
  12. package/core/components/DashboardLayout.vue +23 -27
  13. package/core/components/DynamicWebComponent.vue +6 -6
  14. package/core/components/Footer.vue +11 -12
  15. package/core/components/Header.vue +5 -29
  16. package/core/components/Loading.vue +27 -0
  17. package/core/components/MobileLayout.vue +34 -63
  18. package/core/composables/DefineEodash.js +57 -0
  19. package/core/composables/DefineWidgets.js +26 -15
  20. package/core/composables/index.js +139 -67
  21. package/core/eodash.js +100 -0
  22. package/core/main.js +2 -4
  23. package/core/plugins/index.js +3 -12
  24. package/core/plugins/vuetify.js +5 -2
  25. package/core/store/Actions.js +0 -28
  26. package/core/store/States.js +12 -3
  27. package/core/store/stac.js +7 -5
  28. package/core/types.d.ts +148 -124
  29. package/core/utils/eodashSTAC.js +164 -0
  30. package/core/utils/helpers.js +40 -0
  31. package/core/utils/index.js +28 -0
  32. package/core/utils/keys.js +6 -0
  33. package/core/views/Dashboard.vue +33 -23
  34. package/core/vite-env.d.ts +16 -2
  35. package/dist/.gitkeep +0 -0
  36. package/dist/DashboardLayout-YLfAa8wH.js +168 -0
  37. package/dist/DynamicWebComponent-BDOQsEcj.js +57 -0
  38. package/dist/EodashDatePicker-DlehqSgz.js +1645 -0
  39. package/dist/EodashItemFilter-TSp7XRGy.js +51 -0
  40. package/dist/EodashMap-DInb9cfS.js +53405 -0
  41. package/dist/Footer-CIzHgJbK.js +118 -0
  42. package/dist/Header-C5PSB8Uc.js +609 -0
  43. package/dist/IframeWrapper-DYHQQRUh.js +19 -0
  44. package/dist/MobileLayout-DZmqrpub.js +523 -0
  45. package/dist/VBtn-CFPhsIX8.js +1106 -0
  46. package/dist/VMain-deI9jyIf.js +35 -0
  47. package/dist/WidgetsContainer-D_PLP1qf.js +122 -0
  48. package/dist/_commonjsHelpers-DaMA6jEr.js +8 -0
  49. package/dist/asWebComponent-BKe6Spni.js +11323 -0
  50. package/dist/basedecoder-Qm25PwVp-CHo5Pomv.js +89 -0
  51. package/dist/color-D72nEBIR.js +115 -0
  52. package/dist/decoder-kAoyGIq9-HAkjSTCt.js +10 -0
  53. package/dist/deflate-Be2Arps5-hDqMz3RA.js +10 -0
  54. package/dist/dimensions-BZkmIizV.js +53 -0
  55. package/dist/eo-dash.js +6 -0
  56. package/dist/eox-itemfilter-DcQkRD2l.js +7537 -0
  57. package/dist/eox-map-BJ9SIixs.js +36205 -0
  58. package/dist/eox-stacinfo-B-YrT7Ug.js +13698 -0
  59. package/dist/forwardRefs-Bxeu9Obx.js +142 -0
  60. package/dist/index-8ch8xKfa.js +152 -0
  61. package/dist/index-DIt8GjSR.js +65 -0
  62. package/dist/jpeg-DNfUpLwy-Fjan-04T.js +515 -0
  63. package/dist/lerc-C9VL9kri-DyVxBvsf.js +1029 -0
  64. package/dist/lzw-BOMhmEDy-Dboc93VO.js +84 -0
  65. package/dist/packbits-DaUD6MLm-Bu1PoTGa.js +24 -0
  66. package/dist/pako.esm-C3kYPGGQ-BMki8cQY.js +1087 -0
  67. package/dist/raw-CcGKjn8q-DFOt-i8n.js +9 -0
  68. package/dist/ssrBoot-Cm5pWM14.js +17 -0
  69. package/dist/style.css +5 -0
  70. package/dist/webfontloader-CyOFAuFB.js +471 -0
  71. package/dist/webimage-D2c098k3-DLj1LQxB.js +19 -0
  72. package/package.json +41 -12
  73. package/widgets/EodashDatePicker.vue +56 -0
  74. package/widgets/EodashItemFilter.vue +60 -0
  75. package/widgets/EodashMap.vue +82 -0
  76. package/widgets/WidgetsContainer.vue +1 -1
  77. package/core/composables/DefineConfig.js +0 -45
  78. package/core/eodashConfig.js +0 -136
  79. package/core/plugins/router.js +0 -20
  80. package/core/store/Keys.js +0 -6
@@ -1,23 +1,23 @@
1
1
  // functions of this folder can only be consumed inside setup stores,
2
2
  // setup functions or vue composition api components
3
3
 
4
- import { reactive } from "vue"
5
- import { currentUrl } from "@/store/States"
6
- import eodashConfig from "@/eodashConfig"
7
- import { useTheme } from "vuetify/lib/framework.mjs"
8
-
4
+ import { reactive } from "vue";
5
+ import { currentUrl, indicator, mapPosition } from "@/store/States";
6
+ import eodash from "@/eodash";
7
+ import { useTheme } from "vuetify/lib/framework.mjs";
8
+ import { onMounted, watch } from "vue";
9
9
 
10
10
  /**
11
11
  * Creates an absolute URL from a relative link and assignes it to `currentUrl`
12
12
  * @param {string} [rel = '']
13
- * @param {string} [base = eodashConfig.stacEndpoint] - base URL, default value is the root stac catalog
13
+ * @param {string} [base = eodash.stacEndpoint] - base URL, default value is the root stac catalog
14
14
  * @returns {import('vue').Ref<string>} - returns `currentUrl`
15
15
  * @see {@link '@/store/States.js'}
16
16
  */
17
- export const useAbsoluteUrl = (rel = '', base = eodashConfig.stacEndpoint) => {
18
- if (!rel || rel.includes('http')) {
19
- currentUrl.value = base
20
- return currentUrl
17
+ export const useAbsoluteUrl = (rel = "", base = eodash.stacEndpoint) => {
18
+ if (!rel || rel.includes("http")) {
19
+ currentUrl.value = base;
20
+ return currentUrl;
21
21
  }
22
22
 
23
23
  const st = base.split("/");
@@ -25,102 +25,122 @@ export const useAbsoluteUrl = (rel = '', base = eodashConfig.stacEndpoint) => {
25
25
  st.pop();
26
26
 
27
27
  for (let i = 0; i < arr.length; i++) {
28
- if (arr[i] == ".")
29
- continue;
30
- if (arr[i] == "..")
31
- st.pop();
32
- else
33
- st.push(arr[i]);
28
+ if (arr[i] == ".") continue;
29
+ if (arr[i] == "..") st.pop();
30
+ else st.push(arr[i]);
34
31
  }
35
32
 
36
33
  currentUrl.value = st.join("/");
37
- return currentUrl
38
- }
34
+ return currentUrl;
35
+ };
39
36
 
40
37
  /**
41
38
  * Adds slide in and out functionality to Elements
42
39
  * @param {import('vue').Ref<HTMLElement[]|null>} elements - elements to add the functionality to
43
- * @param {import("@/types").WidgetConfig[]} configs
40
+ * @param {import("@/types").Widget[]} configs
44
41
  */
45
42
  export const useSlidePanels = (elements, configs) => {
46
-
47
43
  /**
48
44
  * Sliding direction
49
45
  */
50
- const slideDirs = configs.map(m => m.layout.x == 0 ? 'left' : m.layout.x == 12 - m.layout.w ? 'right' : m.layout.y < 6 ? 'up' : 'down')
46
+ const slideDirs = configs.map((m) =>
47
+ m.layout.x == 0
48
+ ? "left"
49
+ : m.layout.x == 12 - m.layout.w
50
+ ? "right"
51
+ : m.layout.y < 6
52
+ ? "up"
53
+ : "down"
54
+ );
51
55
 
52
56
  /**
53
57
  * Array of sliding button's style and icons
54
58
  */
55
- const slideBtns = slideDirs.map(d => {
56
- const btn = reactive({ style: {}, icon: { in: '', out: '' }, active: false })
57
- switch (d) {
58
- case 'left':
59
- btn.style = { 'top': '50%', 'right': '-11%' }
60
- btn.icon.in = 'mdi-chevron-double-right'
61
- btn.icon.out = 'mdi-chevron-double-left'
59
+ const slideBtns = slideDirs.map((dir, idx) => {
60
+ const btn = reactive({
61
+ style: {},
62
+ icon: { in: "", out: "" },
63
+ active: false,
64
+ enabled: true,
65
+ });
66
+ if (configs[idx].slidable === false) {
67
+ btn.enabled = false;
68
+ return btn;
69
+ }
70
+
71
+ switch (dir) {
72
+ case "left":
73
+ btn.style = { top: "50%", right: "-11%" };
74
+ btn.icon.in = "mdi-chevron-double-right";
75
+ btn.icon.out = "mdi-chevron-double-left";
62
76
 
63
77
  break;
64
- case 'right':
65
- btn.style = { 'top': '50%', 'left': '-11%' }
66
- btn.icon.in = 'mdi-chevron-double-left'
67
- btn.icon.out = 'mdi-chevron-double-right'
78
+ case "right":
79
+ btn.style = { top: "50%", left: "-11%" };
80
+ btn.icon.in = "mdi-chevron-double-left";
81
+ btn.icon.out = "mdi-chevron-double-right";
68
82
 
69
83
  break;
70
- case 'up':
71
- btn.style = { 'right': '50%', 'bottom': '-17%' }
72
- btn.icon.in = 'mdi-chevron-double-down'
73
- btn.icon.out = 'mdi-chevron-double-up'
84
+ case "up":
85
+ btn.style = { right: "50%", bottom: "-17%" };
86
+ btn.icon.in = "mdi-chevron-double-down";
87
+ btn.icon.out = "mdi-chevron-double-up";
74
88
 
75
89
  break;
76
- case 'down':
77
- btn.style = { 'right': '50%', 'top': '-17%' }
78
- btn.icon.in = 'mdi-chevron-double-up'
79
- btn.icon.out = 'mdi-chevron-double-down'
90
+ case "down":
91
+ btn.style = { right: "50%", top: "-17%" };
92
+ btn.icon.in = "mdi-chevron-double-up";
93
+ btn.icon.out = "mdi-chevron-double-down";
80
94
  break;
81
95
 
82
96
  default:
83
- console.error('sliding error')
97
+ console.error("sliding error");
84
98
  break;
85
99
  }
86
- return btn
87
- })
100
+ return btn;
101
+ });
88
102
 
89
103
  /**
90
104
  * Transforms the element's position based on the direction
91
105
  * @param {number} idx - index of the pressed element
92
106
  */
93
107
  const slideInOut = (idx) => {
94
- const parentStyle = /** @type {CSSStyleDeclaration} */ (elements.value?.[idx].style)
108
+ const parentStyle = /** @type {CSSStyleDeclaration} */ (
109
+ elements.value?.[idx].style
110
+ );
95
111
  if (parentStyle?.transform.length) {
96
- slideBtns[idx].active = false
112
+ slideBtns[idx].active = false;
97
113
  parentStyle.transform = "";
98
114
  } else {
99
- slideBtns[idx].active = true
100
- parentStyle.transition = "transform 0.3s ease-in-out"
115
+ slideBtns[idx].active = true;
116
+ parentStyle.transition = "transform 0.3s ease-in-out";
101
117
  switch (slideDirs[idx]) {
102
- case 'left':
103
- parentStyle.transform = "translateX(-100%)"
118
+ case "left":
119
+ parentStyle.transform = "translateX(-100%)";
104
120
  break;
105
- case 'right':
106
- parentStyle.transform = "translateX(100%)"
121
+ case "right":
122
+ parentStyle.transform = "translateX(100%)";
107
123
  break;
108
- case 'up':
109
- parentStyle.transform = `translateY(-${((configs[idx].layout.y / configs[idx].layout.h) * 100) + 100}%)`
124
+ case "up":
125
+ parentStyle.transform = `translateY(-${(configs[idx].layout.y / configs[idx].layout.h) * 100 + 100
126
+ }%)`;
110
127
  break;
111
- case 'down':
112
- parentStyle.transform = `translateY(${((Math.max(0, 12 - configs[idx].layout.y - configs[idx].layout.h) / configs[idx].layout.h) * 100) + 100}%)`;
128
+ case "down":
129
+ parentStyle.transform = `translateY(${(Math.max(0, 12 - configs[idx].layout.y - configs[idx].layout.h) /
130
+ configs[idx].layout.h) *
131
+ 100 +
132
+ 100
133
+ }%)`;
113
134
  break;
114
135
 
115
136
  default:
116
- console.error('sliding error')
137
+ console.error("sliding error");
117
138
  break;
118
139
  }
119
140
  }
120
- }
121
- return { slideBtns, slideInOut }
122
- }
123
-
141
+ };
142
+ return { slideBtns, slideInOut };
143
+ };
124
144
 
125
145
  /**
126
146
  * Updates an existing Vuetify theme.
@@ -132,16 +152,68 @@ export const useSlidePanels = (elements, configs) => {
132
152
  export const useUpdateTheme = (themeName, themeDefinition = {}) => {
133
153
  const theme = useTheme();
134
154
 
135
- /** @type {Array<keyof import('vuetify').ThemeDefinition>} */(Object.keys(themeDefinition)).forEach((key) => {
136
- if (key === 'dark') {
137
- theme.themes.value[themeName][key] = /** @type {Boolean} */ (themeDefinition[key])
155
+ /** @type {Array<keyof import('vuetify').ThemeDefinition>} */ (
156
+ Object.keys(themeDefinition)
157
+ ).forEach((key) => {
158
+ if (key === "dark") {
159
+ theme.themes.value[themeName][key] = /** @type {Boolean} */ (
160
+ themeDefinition[key]
161
+ );
138
162
  } else {
139
163
  //@ts-expect-error
140
164
  theme.themes.value[themeName][key] = {
141
165
  ...theme.themes.value[themeName][key],
142
- ...themeDefinition[key]
166
+ ...themeDefinition[key],
167
+ };
168
+ }
169
+ });
170
+ return theme;
171
+ };
172
+
173
+ /**
174
+ * Composable that syncs store and URLSearchParameters
175
+ */
176
+
177
+ export const useURLSearchParametersSync = () => {
178
+ onMounted(() => {
179
+ // Analyze currently set url params when first loaded and set them in the store
180
+ if ('URLSearchParams' in window) {
181
+ const searchParams = new URLSearchParams(window.location.search);
182
+ let x, y, z;
183
+ searchParams.forEach((value, key) => {
184
+ if (key === "indicator") {
185
+ indicator.value = value;
186
+ }
187
+ if (key === "x") {
188
+ x = value;
189
+ }
190
+ if (key === "y") {
191
+ y = value;
192
+ }
193
+ if (key === "z") {
194
+ z = value;
195
+ }
196
+ })
197
+ if (x !== undefined && y !== undefined && z !== undefined) {
198
+ mapPosition.value = [x, y, z];
143
199
  }
144
200
  }
145
- })
146
- return theme
147
- }
201
+ watch(
202
+ [indicator, mapPosition],
203
+ ([updatedIndicator, updatedMapPosition]) => {
204
+ if ('URLSearchParams' in window) {
205
+ const searchParams = new URLSearchParams(window.location.search);
206
+ if (updatedIndicator !== "") {
207
+ searchParams.set("indicator", updatedIndicator);
208
+ }
209
+ if (updatedMapPosition && updatedMapPosition.length === 3) {
210
+ searchParams.set("x", updatedMapPosition[0]?.toFixed(4) ?? '');
211
+ searchParams.set("y", updatedMapPosition[1]?.toFixed(4) ?? '');
212
+ searchParams.set("z", updatedMapPosition[2]?.toFixed(4) ?? '');
213
+ }
214
+ const newRelativePathQuery = window.location.pathname + '?' + searchParams.toString();
215
+ history.pushState(null, '', newRelativePathQuery);
216
+ }
217
+ })
218
+ });
219
+ };
package/core/eodash.js ADDED
@@ -0,0 +1,100 @@
1
+ import { reactive } from "vue";
2
+ import { currentUrl } from "./store/States";
3
+
4
+ /**
5
+ * Reactive Edoash Instance Object. provided globally in the app,
6
+ * and used as an intermediate object to make user defined instances config reactive.
7
+ * @type {import("./types").Eodash}
8
+ */
9
+ export const eodash = reactive({
10
+ id: "demo",
11
+ stacEndpoint: "https://esa-eodash.github.io/RACE-catalog/RACE/catalog.json",
12
+ brand: {
13
+ noLayout: true,
14
+ name: "Demo",
15
+ font: {
16
+ family: "Roboto",
17
+ },
18
+ theme: {
19
+ colors: {
20
+ primary: "#fff",
21
+ secondary: "#fff",
22
+ surface: "#fff",
23
+ },
24
+ },
25
+ footerText: "Demo configuration of eodash client",
26
+ },
27
+ template: {
28
+ loading: {
29
+ id: Symbol(),
30
+ type: "web-component",
31
+ widget: {
32
+ // https://uiball.com/ldrs/
33
+ link: "https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",
34
+ tagName: "l-mirage",
35
+ properties: {
36
+ class: "align-self-center justify-self-center",
37
+ size: "120",
38
+ speed: "2.5",
39
+ color: "#004170"
40
+ }
41
+ }
42
+ },
43
+ background: {
44
+ id: Symbol(),
45
+ type: "internal",
46
+ widget: {
47
+ name: "EodashMap",
48
+ },
49
+ },
50
+ widgets: [
51
+ {
52
+ id: Symbol(),
53
+ type: "internal",
54
+ title: "itemfilter",
55
+ layout: { x: 0, y: 0, w: 3, h: 12 },
56
+ slidable: false,
57
+ widget: {
58
+ name: "EodashItemFilter",
59
+ },
60
+ },
61
+ {
62
+ id: Symbol(),
63
+ type: "internal",
64
+ title: "datepicker",
65
+ layout: { x: 5, y: 11, w: 2, h: 1 },
66
+ slidable: false,
67
+ widget: {
68
+ name: "EodashDatePicker",
69
+ properties: {
70
+ inline: true,
71
+ },
72
+ },
73
+ },
74
+ {
75
+ id: Symbol(),
76
+ title: "Information",
77
+ layout: { x: 9, y: 0, w: 3, h: 12 },
78
+ widget: {
79
+ link: async () => await import("@eox/stacinfo"),
80
+ properties: {
81
+ for: currentUrl,
82
+ allowHtml: "true",
83
+ styleOverride:
84
+ "#properties li > .value {font-weight: normal !important;}",
85
+ header: "[]",
86
+
87
+ subheader: "[]",
88
+ properties: '["description"]',
89
+ featured: "[]",
90
+ footer: "[]",
91
+ },
92
+ tagName: "eox-stacinfo",
93
+ },
94
+ type: "web-component",
95
+ },
96
+ ],
97
+ },
98
+ });
99
+
100
+ export default eodash;
package/core/main.js CHANGED
@@ -1,4 +1,2 @@
1
- // Plugins
2
- import { defineCompiletimeConfig } from '@/composables/DefineConfig';
3
-
4
- export { defineCompiletimeConfig as defineConfig }
1
+ export { createEodash } from '@/composables/DefineEodash';
2
+ export { default as store } from "@/store"
@@ -1,15 +1,7 @@
1
- /**
2
- * plugins/index.ts
3
- *
4
- * Automatically included in `./src/main.ts`
5
- */
6
-
7
- // Plugins
8
1
  import vuetify from './vuetify';
9
- import router from './router';
10
2
  import { createPinia } from 'pinia';
11
- import eodashConfig from '@/eodashConfig';
12
- import { eodashConfigKey } from '@/store/Keys';
3
+ import eodash from '@/eodash';
4
+ import { eodashKey } from '@/utils/keys';
13
5
  import store from '../store';
14
6
 
15
7
  export const pinia = createPinia();
@@ -21,7 +13,6 @@ export function registerPlugins(app) {
21
13
  window.eodashStore = store;
22
14
 
23
15
  app.use(vuetify)
24
- .use(router)
25
16
  .use(pinia)
26
- .provide(eodashConfigKey, eodashConfig);
17
+ .provide(eodashKey, eodash);
27
18
  }
@@ -10,9 +10,10 @@ import 'vuetify/styles';
10
10
 
11
11
 
12
12
  import { createVuetify } from 'vuetify';
13
+ // import {} from "vuetify"
13
14
 
14
15
  // https://vuetifyjs.com/en/introduction/why-vuetify/#feature-guides
15
- export default createVuetify({
16
+ const vuetify = createVuetify({
16
17
  theme: {
17
18
  themes: {
18
19
  dashboardTheme: {},
@@ -24,4 +25,6 @@ export default createVuetify({
24
25
  },
25
26
  },
26
27
  },
27
- });
28
+ })
29
+
30
+ export default vuetify
@@ -1,28 +0,0 @@
1
- /**
2
- * loads font in the app using `webfontloader`
3
- * @param {string} [family="Roboto"]
4
- * @param {string} [link]
5
- * @returns {Promise<string>} - font family name
6
- * @see {@link "https://github.com/typekit/webfontloader "}
7
- */
8
- export const loadFont = async (family = "Roboto", link) => {
9
- const WebFontLoader = (await import('webfontloader')).default;
10
- if (link) {
11
- WebFontLoader.load({
12
- custom: {
13
- // Use FVD notation to include families https://github.com/typekit/fvd
14
- families: [family],
15
- // Path to stylesheet that defines font-face
16
- urls: [link],
17
- },
18
- });
19
- }
20
- else {
21
- WebFontLoader.load({
22
- google: {
23
- families: [family]
24
- }
25
- });
26
- }
27
- return family;
28
- };
@@ -4,9 +4,18 @@ import { ref } from "vue";
4
4
  * currently selected STAC endpoint
5
5
  */
6
6
  export const currentUrl = ref('');
7
+ /**
8
+ * currently selected datetime
9
+ */
10
+ export const datetime = ref(new Date().toISOString());
11
+
12
+ /**
13
+ * Currently selected indicator
14
+ */
15
+ export const indicator = ref("")
7
16
 
8
17
  /**
9
- * ol map object. Updated by the config file.
10
- * @type {import("vue").Ref<import('openlayers').Map | null>}
18
+ * Current map position
19
+ * @type {import("vue").Ref<(number|undefined)[]>}
11
20
  */
12
- export const mapInstance = ref(null);
21
+ export const mapPosition = ref([])
@@ -2,7 +2,8 @@ import { defineStore } from 'pinia';
2
2
  import { inject, ref } from 'vue';
3
3
  import axios from 'axios';
4
4
  import { useAbsoluteUrl } from '@/composables/index';
5
- import { eodashConfigKey } from '@/store/Keys';
5
+ import { eodashKey } from '@/utils/keys';
6
+ import { indicator } from '@/store/States';
6
7
 
7
8
  export const useSTAcStore = defineStore('stac', () => {
8
9
  /**
@@ -14,22 +15,22 @@ export const useSTAcStore = defineStore('stac', () => {
14
15
  /**
15
16
  * selected STAC object.
16
17
  * @type {import('vue').Ref<import('stac-ts').StacCatalog |
17
- * import('stac-ts').StacCollection |import('stac-ts').StacItem
18
+ * import('stac-ts').StacCollection |import('stac-ts').StacItem
18
19
  * | null>}
19
20
  */
20
21
  const selectedStac = ref(null);
21
22
 
22
23
 
23
- const eodashConfig = /** @type {import("@/types").EodashConfig} */(inject(eodashConfigKey));
24
+ const eodash = /** @type {import("@/types").Eodash} */(inject(eodashKey));
24
25
 
25
26
  /**
26
27
  * fetches root stac catalog and assign it to `stac`
27
28
  * @async
28
- * @param {import("@/types").StacEndpoint} [url = eodashConfig.stacEndpoint]
29
+ * @param {import("@/types").StacEndpoint} [url = eodash.stacEndpoint]
29
30
  * @returns {Promise<void>}
30
31
  * @see {@link stac}
31
32
  */
32
- async function loadSTAC(url = eodashConfig.stacEndpoint) {
33
+ async function loadSTAC(url = eodash.stacEndpoint) {
33
34
  await axios.get(url).then(resp => {
34
35
  const links = /** @type {import('stac-ts').StacCatalog} */(resp.data).links.map(link => {
35
36
  if (!link.title) {
@@ -54,6 +55,7 @@ export const useSTAcStore = defineStore('stac', () => {
54
55
 
55
56
  await axios.get(absoluteUrl.value).then(resp => {
56
57
  selectedStac.value = resp.data;
58
+ indicator.value = selectedStac.value?.id ?? "";
57
59
  }).catch(err => console.error(err));
58
60
  }
59
61