@eodash/eodash 5.0.0 → 5.1.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.
Files changed (155) hide show
  1. package/README.md +1 -0
  2. package/core/client/App.vue +8 -2
  3. package/core/client/asWebComponent.js +5 -5
  4. package/core/client/components/DashboardLayout.vue +42 -25
  5. package/core/client/components/EodashOverlay.vue +1 -1
  6. package/core/client/components/ErrorAlert.vue +2 -2
  7. package/core/client/components/Footer.vue +4 -4
  8. package/core/client/components/Header.vue +3 -3
  9. package/core/client/components/MobileLayout.vue +9 -10
  10. package/core/client/composables/DefineEodash.js +38 -43
  11. package/core/client/composables/DefineTemplate.js +4 -2
  12. package/core/client/composables/DefineWidgets.js +14 -8
  13. package/core/client/composables/index.js +273 -23
  14. package/core/client/eodashSTAC/EodashCollection.js +80 -47
  15. package/core/client/eodashSTAC/helpers.js +136 -27
  16. package/core/client/eodashSTAC/parquet.js +145 -0
  17. package/core/client/eodashSTAC/triggers.js +6 -3
  18. package/core/client/plugins/index.js +4 -3
  19. package/core/client/plugins/vuetify.js +3 -0
  20. package/core/client/store/actions.js +21 -4
  21. package/core/client/store/stac.js +93 -56
  22. package/core/client/store/states.js +15 -5
  23. package/core/client/types.ts +59 -43
  24. package/core/client/utils/index.js +79 -0
  25. package/core/client/utils/keys.js +2 -2
  26. package/core/client/utils/states.js +30 -5
  27. package/core/client/views/Dashboard.vue +36 -32
  28. package/core/client/vite-env.d.ts +7 -0
  29. package/dist/client/{DashboardLayout-CkWvOMOW.js → DashboardLayout-ByVs1DrY.js} +23 -12
  30. package/dist/client/{DynamicWebComponent-DYBbpvUK.js → DynamicWebComponent-C3W7HSQm.js} +1 -1
  31. package/dist/client/{EodashDatePicker-CALmW3SI.js → EodashDatePicker-BIAf1sMT.js} +59 -32
  32. package/dist/client/{EodashItemFilter-DlQiE713.js → EodashItemFilter-DPznh8UB.js} +20 -10
  33. package/dist/client/{EodashLayerControl-DEzEbft7.js → EodashLayerControl-Bhxjw4V2.js} +29 -16
  34. package/dist/client/EodashLayoutSwitcher-C5qTEffW.js +61 -0
  35. package/dist/client/EodashMapBtns-WoGq8MuV.js +173 -0
  36. package/dist/client/{EodashStacInfo-DPPxDkF6.js → EodashStacInfo-CSvvF2jI.js} +3 -18
  37. package/dist/client/{EodashTools-CUaL9s4H.js → EodashTools-Cv1SXQ5y.js} +13 -13
  38. package/dist/client/{ExportState-DjyIZVhl.js → ExportState-D-iuwaad.js} +58 -52
  39. package/dist/client/{Footer-DyL0JoWt.js → Footer-CyF0zRAk.js} +15 -13
  40. package/dist/client/{Header-B5Dgty9l.js → Header-CgD8jDKU.js} +33 -28
  41. package/dist/client/{MobileLayout-CRsg_5Q4.js → MobileLayout-EKQ_kpSh.js} +69 -60
  42. package/dist/client/{PopUp-BfB8s_ki.js → PopUp-BsYLvWch.js} +19 -10
  43. package/dist/client/ProcessList-C2xsLU2_.js +191 -0
  44. package/dist/client/{VImg-FD1WVphJ.js → VImg-OHe8YTs2.js} +24 -24
  45. package/dist/client/{VMain-DJKG4SvM.js → VMain-PryTLU4a.js} +7 -7
  46. package/dist/client/{VOverlay-BzOdRu9h.js → VOverlay-yUn7p-Uf.js} +64 -27
  47. package/dist/client/{VTooltip-CfeefrXI.js → VTooltip-DZ0fjpB3.js} +13 -10
  48. package/dist/client/{WidgetsContainer-C2TaTdb6.js → WidgetsContainer-B9LBadcC.js} +1 -1
  49. package/dist/client/asWebComponent-By_7_JjS.js +19193 -0
  50. package/dist/client/async-DkSu_u2K.js +740 -0
  51. package/dist/client/eo-dash.js +1 -1
  52. package/dist/client/{forwardRefs-Bon_Kku1.js → forwardRefs-BXxrv98s.js} +31 -4
  53. package/dist/client/handling-CgmFXkW6.js +1212 -0
  54. package/dist/client/helpers-Dy0Q13tP.js +4534 -0
  55. package/dist/client/{index-Bm9cbtx5.js → index-BuhOHXKv.js} +2 -4
  56. package/dist/client/{index-CIHH_3dW.js → index-Ch_HchK3.js} +39 -32
  57. package/dist/client/{index-4CT7Tz83.js → index-Dqj4tbx2.js} +2 -2
  58. package/dist/client/index-skjhlH8u.js +376 -0
  59. package/dist/client/{ssrBoot-BP7SYRyC.js → ssrBoot-Zgc_Ttvi.js} +2 -2
  60. package/dist/client/templates.js +850 -0
  61. package/dist/client/transition-C98Yn4Vo.js +40 -0
  62. package/dist/node/cli.js +16 -6
  63. package/dist/node/types.d.ts +1 -1
  64. package/dist/types/core/client/App.vue.d.ts +2 -2
  65. package/dist/types/core/client/asWebComponent.d.ts +1 -1
  66. package/dist/types/core/client/components/DynamicWebComponent.vue.d.ts +1 -3
  67. package/dist/types/core/client/components/Footer.vue.d.ts +1 -105
  68. package/dist/types/core/client/components/IframeWrapper.vue.d.ts +1 -1
  69. package/dist/types/core/client/components/MobileLayout.vue.d.ts +1 -324
  70. package/dist/types/core/client/composables/DefineEodash.d.ts +2 -2
  71. package/dist/types/core/client/composables/DefineTemplate.d.ts +1 -1
  72. package/dist/types/core/client/composables/DefineWidgets.d.ts +4 -4
  73. package/dist/types/core/client/composables/index.d.ts +24 -2
  74. package/dist/types/core/client/eodashSTAC/EodashCollection.d.ts +9 -6
  75. package/dist/types/core/client/eodashSTAC/helpers.d.ts +20 -5
  76. package/dist/types/core/client/eodashSTAC/parquet.d.ts +2 -0
  77. package/dist/types/core/client/plugins/vuetify.d.ts +7 -4
  78. package/dist/types/core/client/store/actions.d.ts +3 -2
  79. package/dist/types/core/client/store/stac.d.ts +16 -13
  80. package/dist/types/core/client/store/states.d.ts +14 -4
  81. package/dist/types/core/client/types.d.ts +45 -30
  82. package/dist/types/core/client/utils/index.d.ts +2 -0
  83. package/dist/types/core/client/utils/keys.d.ts +4 -4
  84. package/dist/types/core/client/utils/states.d.ts +59 -47
  85. package/dist/types/core/client/views/Dashboard.vue.d.ts +2 -2
  86. package/dist/types/templates/baseConfig.d.ts +4 -0
  87. package/dist/types/templates/compare.d.ts +210 -0
  88. package/dist/types/templates/expert.d.ts +151 -0
  89. package/dist/types/templates/index.d.ts +6 -0
  90. package/dist/types/templates/light.d.ts +145 -0
  91. package/dist/types/widgets/EodashDatePicker.vue.d.ts +1 -458
  92. package/dist/types/widgets/EodashItemFilter.vue.d.ts +3 -3
  93. package/dist/types/widgets/EodashLayerControl.vue.d.ts +14 -7
  94. package/dist/types/widgets/EodashLayoutSwitcher.vue.d.ts +1 -3
  95. package/dist/types/widgets/EodashMap/index.vue.d.ts +1 -4
  96. package/dist/types/widgets/EodashMapBtns.vue.d.ts +8 -8
  97. package/dist/types/widgets/EodashProcess/ProcessList.vue.d.ts +8 -1
  98. package/dist/types/widgets/EodashProcess/index.vue.d.ts +8 -4
  99. package/dist/types/widgets/EodashProcess/methods/async.d.ts +18 -18
  100. package/dist/types/widgets/EodashProcess/methods/composables.d.ts +3 -2
  101. package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/index.d.ts +1 -0
  102. package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/sentinelhub-endpoint.d.ts +6 -0
  103. package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/veda-endpoint.d.ts +4 -0
  104. package/dist/types/widgets/EodashProcess/methods/custom-endpoints/layers/eoxhub-workspaces-endpoint.d.ts +5 -0
  105. package/dist/types/widgets/EodashProcess/methods/custom-endpoints/layers/index.d.ts +1 -0
  106. package/dist/types/widgets/EodashProcess/methods/handling.d.ts +12 -5
  107. package/dist/types/widgets/EodashProcess/methods/outputs.d.ts +72 -41
  108. package/dist/types/widgets/EodashProcess/methods/utils.d.ts +41 -21
  109. package/dist/types/widgets/EodashProcess/states.d.ts +11 -0
  110. package/dist/types/widgets/EodashProcess/types.d.ts +41 -0
  111. package/dist/types/widgets/EodashStacInfo.vue.d.ts +14 -14
  112. package/dist/types/widgets/EodashTools.vue.d.ts +3 -3
  113. package/dist/types/widgets/ExportState.vue.d.ts +1 -1
  114. package/dist/types/widgets/PopUp.vue.d.ts +11 -16
  115. package/dist/types/widgets/WidgetsContainer.vue.d.ts +3 -6
  116. package/package.json +53 -45
  117. package/templates/baseConfig.js +68 -0
  118. package/templates/compare.js +162 -0
  119. package/templates/expert.js +123 -0
  120. package/templates/index.js +8 -0
  121. package/templates/light.js +130 -0
  122. package/widgets/EodashDatePicker.vue +80 -31
  123. package/widgets/EodashItemFilter.vue +26 -11
  124. package/widgets/EodashLayerControl.vue +20 -11
  125. package/widgets/EodashLayoutSwitcher.vue +6 -3
  126. package/widgets/EodashMap/index.vue +3 -8
  127. package/widgets/EodashMap/methods/create-layers-config.js +4 -3
  128. package/widgets/EodashMap/methods/index.js +33 -23
  129. package/widgets/EodashMapBtns.vue +83 -41
  130. package/widgets/EodashProcess/ProcessList.vue +34 -10
  131. package/widgets/EodashProcess/index.vue +55 -20
  132. package/widgets/EodashProcess/methods/async.js +77 -59
  133. package/widgets/EodashProcess/methods/composables.js +21 -14
  134. package/widgets/EodashProcess/methods/custom-endpoints/chart/index.js +35 -0
  135. package/widgets/EodashProcess/methods/custom-endpoints/chart/sentinelhub-endpoint.js +275 -0
  136. package/widgets/EodashProcess/methods/custom-endpoints/chart/veda-endpoint.js +116 -0
  137. package/widgets/EodashProcess/methods/custom-endpoints/layers/eoxhub-workspaces-endpoint.js +94 -0
  138. package/widgets/EodashProcess/methods/custom-endpoints/layers/index.js +33 -0
  139. package/widgets/EodashProcess/methods/handling.js +127 -80
  140. package/widgets/EodashProcess/methods/outputs.js +376 -125
  141. package/widgets/EodashProcess/methods/utils.js +398 -10
  142. package/widgets/EodashProcess/states.js +13 -0
  143. package/widgets/EodashProcess/types.ts +46 -0
  144. package/widgets/EodashStacInfo.vue +2 -17
  145. package/widgets/EodashTools.vue +13 -13
  146. package/widgets/WidgetsContainer.vue +1 -1
  147. package/core/client/eodash.js +0 -454
  148. package/dist/client/EodashLayoutSwitcher-CDeCV8F-.js +0 -52
  149. package/dist/client/EodashMapBtns-CktQCfa-.js +0 -131
  150. package/dist/client/ProcessList-DTefwQZx.js +0 -484
  151. package/dist/client/asWebComponent-CLhcT715.js +0 -12479
  152. package/dist/client/eo-dash.css +0 -5
  153. package/dist/client/index-DiGDvTQU.js +0 -780
  154. package/dist/client/transition-C5I57hn6.js +0 -37
  155. package/dist/types/core/client/eodash.d.ts +0 -8
@@ -1,454 +0,0 @@
1
- import { mdiViewDashboard, mdiViewDashboardVariant } from "@mdi/js";
2
- import { reactive } from "vue";
3
-
4
- /**
5
- * Reactive Edoash Instance Object. provided globally in the app, and used as an
6
- * intermediate object to make user defined instances config reactive.
7
- *
8
- * @type {import("./types").Eodash}
9
- */
10
- export const eodash = reactive({
11
- id: "demo",
12
- stacEndpoint:
13
- // "https://esa-eodash.github.io/RACE-catalog/RACE/catalog.json",
14
- // "https://gtif-cerulean.github.io/catalog/cerulean/catalog.json",
15
- // "https://eodashcatalog.eox.at/samplecatalog/samples/catalog.json",
16
- // "https://eodashcatalog.eox.at/test-style/trilateral/catalog.json",
17
- // "https://gtif-cerulean.github.io/deside-catalog/deside/catalog.json",
18
- "https://gtif-cerulean.github.io/cerulean-catalog/cerulean/catalog.json",
19
- // "https://gtif-austria.github.io/public-catalog/GTIF-Austria/catalog.json",
20
- brand: {
21
- noLayout: true,
22
- name: "Demo",
23
- font: {
24
- headers: {
25
- family: "Open Sans",
26
- link: "https://eox.at/fonts/opensans/opensans.css",
27
- },
28
- body: {
29
- family: "Sintony",
30
- link: "https://eox.at/fonts/sintony/sintony.css",
31
- },
32
- },
33
- theme: {
34
- colors: {
35
- primary: "#002742",
36
- secondary: "#0071C2",
37
- surface: "#ffff",
38
- },
39
- variables: {
40
- "surface-opacity": 0.6,
41
- "primary-opacity": 0.8,
42
- },
43
- // Bank-Wong palette
44
- collectionsPalette: [
45
- "#009E73",
46
- "#E69F00",
47
- "#56B4E9",
48
- "#009E73",
49
- "#F0E442",
50
- "#0072B2",
51
- "#D55E00",
52
- "#CC79A7",
53
- "#994F00",
54
- ],
55
- },
56
- footerText: "Demo configuration of eodash client",
57
- },
58
- templates: {
59
- light: {
60
- gap: 16,
61
- loading: {
62
- id: Symbol(),
63
- type: "web-component",
64
- widget: {
65
- // https://uiball.com/ldrs/
66
- link: "https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",
67
- tagName: "l-mirage",
68
- properties: {
69
- class: "align-self-center justify-self-center",
70
- size: "120",
71
- speed: "2.5",
72
- color: "#004170",
73
- },
74
- },
75
- },
76
- background: {
77
- id: "background-map",
78
- type: "internal",
79
- widget: {
80
- name: "EodashMap",
81
- properties: {
82
- enableCompare: true,
83
- },
84
- },
85
- },
86
- widgets: [
87
- {
88
- id: Symbol(),
89
- type: "internal",
90
- title: "Tools",
91
- layout: { x: 0, y: 0, w: 3, h: 1 },
92
- widget: {
93
- name: "EodashTools",
94
- properties: {
95
- layoutTarget: "expert",
96
- layoutIcon: mdiViewDashboardVariant,
97
- itemFilterConfig: {
98
- resultType: "cards",
99
- filtersTitle: "",
100
- style: "--padding: 72px",
101
- filterProperties: [],
102
- resultsTitle: "Explore more indicators",
103
- subTitleProperty: "subtitle",
104
- imageProperty: "thumbnail",
105
- },
106
- },
107
- },
108
- },
109
- {
110
- defineWidget: (selectedSTAC) => {
111
- return selectedSTAC
112
- ? {
113
- id: "layercontrol-light",
114
- type: "internal",
115
- title: "Layers",
116
- layout: { x: 0, y: 1, w: 3, h: 3 },
117
- widget: {
118
- name: "EodashLayerControl",
119
- properties: {
120
- slider: false,
121
- tools: ["datetime", "info", "legend"],
122
- cssVars: {
123
- "--list-padding": "0",
124
- "--tools-button-visibility": "none",
125
- "--layer-input-visibility": "none",
126
- "--layer-type-visibility": "none",
127
- "--padding": "16px",
128
- "--padding-vertical": "16px",
129
- "--layer-tools-button-visibility": "none",
130
- "--layer-summary-visibility": "none",
131
- },
132
- },
133
- },
134
- }
135
- : null;
136
- },
137
- },
138
- {
139
- defineWidget: (selectedSTAC) => {
140
- return selectedSTAC
141
- ? {
142
- id: "stacinfo-light",
143
- type: "internal",
144
- title: "Information",
145
- layout: { x: 9, y: 0, w: 3, h: 6 },
146
- widget: {
147
- name: "EodashStacInfo",
148
- properties: {
149
- tags: [],
150
- header: [],
151
- footer: [],
152
- body: ["description"],
153
- styleOverride: "",
154
- featured: [],
155
- },
156
- },
157
- }
158
- : null;
159
- },
160
- },
161
- {
162
- defineWidget: (selectedSTAC) => {
163
- return selectedSTAC
164
- ? {
165
- id: "light-datepicker",
166
- type: "internal",
167
- layout: { x: 5, y: 8, w: 2, h: 4 },
168
- title: "Date",
169
- widget: {
170
- name: "EodashDatePicker",
171
- properties: {
172
- hintText: `<b>Hint:</b> closest available date is displayed <br />
173
- on map (see Analysis Layers)`,
174
- },
175
- },
176
- }
177
- : null;
178
- },
179
- },
180
- ],
181
- },
182
- expert: {
183
- loading: {
184
- id: Symbol(),
185
- type: "web-component",
186
- widget: {
187
- // https://uiball.com/ldrs/
188
- link: "https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",
189
- tagName: "l-mirage",
190
- properties: {
191
- class: "align-self-center justify-self-center",
192
- size: "120",
193
- speed: "2.5",
194
- color: "#004170",
195
- },
196
- },
197
- },
198
- background: {
199
- id: "background-map",
200
- type: "internal",
201
- widget: {
202
- name: "EodashMap",
203
- properties: {
204
- enableCompare: true,
205
- },
206
- },
207
- },
208
- widgets: [
209
- {
210
- id: Symbol(),
211
- type: "internal",
212
- title: "Tools",
213
- layout: { x: 0, y: 0, w: 3, h: 1 },
214
- widget: {
215
- name: "EodashTools",
216
- properties: {
217
- layoutTarget: "light",
218
- layoutIcon: mdiViewDashboard,
219
- itemFilterConfig: {
220
- resultType: "cards",
221
- subTitleProperty: "subtitle",
222
- imageProperty: "thumbnail",
223
- aggregateResults: "collection_group",
224
- style: {
225
- "--form-flex-direction": "row",
226
- },
227
- },
228
- },
229
- },
230
- },
231
- {
232
- id: Symbol(),
233
- type: "internal",
234
- title: "Layers",
235
- layout: { x: 0, y: 1, w: 3, h: 6 },
236
- widget: {
237
- name: "EodashLayerControl",
238
- },
239
- },
240
- {
241
- defineWidget: (selectedSTAC) => {
242
- return selectedSTAC
243
- ? {
244
- id: "Information",
245
- title: "Information",
246
- layout: { x: 9, y: 0, w: 3, h: 6 },
247
- type: "internal",
248
- widget: {
249
- name: "EodashStacInfo",
250
- },
251
- }
252
- : null;
253
- },
254
- },
255
- {
256
- defineWidget: (selectedSTAC) => {
257
- return selectedSTAC
258
- ? {
259
- id: "expert-datepicker",
260
- type: "internal",
261
- layout: { x: 5, y: 11, w: 2, h: 1 },
262
- title: "Date",
263
- widget: {
264
- name: "EodashDatePicker",
265
- properties: {
266
- hintText: `<b>Hint:</b> closest available date is displayed <br />
267
- on map (see Analysis Layers)`,
268
- toggleCalendar: true,
269
- },
270
- },
271
- }
272
- : null;
273
- },
274
- },
275
- {
276
- defineWidget: (selected) => {
277
- return selected
278
- ? {
279
- id: "Buttons",
280
- layout: { x: 8, y: 0, w: 1, h: 2 },
281
- title: "Buttons",
282
- type: "internal",
283
- widget: {
284
- name: "EodashMapBtns",
285
- },
286
- }
287
- : null;
288
- },
289
- },
290
- {
291
- defineWidget: (selectedSTAC) =>
292
- selectedSTAC?.links.some((l) => l.rel === "service")
293
- ? {
294
- id: "Processes",
295
- type: "internal",
296
- title: "Processes",
297
- layout: { x: 9, y: 6, w: 3, h: 5 },
298
- widget: {
299
- name: "EodashProcess",
300
- },
301
- }
302
- : null,
303
- },
304
- ],
305
- },
306
- compare: {
307
- gap: 16,
308
- loading: {
309
- id: Symbol(),
310
- type: "web-component",
311
- widget: {
312
- // https://uiball.com/ldrs/
313
- link: "https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",
314
- tagName: "l-mirage",
315
- properties: {
316
- class: "align-self-center justify-self-center",
317
- size: "120",
318
- speed: "2.5",
319
- color: "#004170",
320
- },
321
- },
322
- },
323
- background: {
324
- id: "background-map",
325
- type: "internal",
326
- widget: {
327
- name: "EodashMap",
328
- properties: {
329
- enableCompare: true,
330
- },
331
- },
332
- },
333
- widgets: [
334
- {
335
- id: Symbol(),
336
- type: "internal",
337
- title: "Tools",
338
- layout: { x: 0, y: 0, w: 3, h: 1 },
339
- widget: {
340
- name: "EodashTools",
341
- properties: {
342
- showLayoutSwitcher: false,
343
- itemFilterConfig: {
344
- cssVars: {
345
- "--form-flex-direction": "row",
346
- },
347
- },
348
- },
349
- },
350
- },
351
- // compare indicators
352
- {
353
- id: Symbol(),
354
- type: "internal",
355
- title: "Tools",
356
- layout: { x: 9, y: 0, w: 3, h: 1 },
357
- widget: {
358
- name: "EodashTools",
359
- properties: {
360
- showLayoutSwitcher: false,
361
- indicatorBtnText: "Select an indicator to compare",
362
- itemFilterConfig: {
363
- enableCompare: true,
364
- // resultsTitle:"Select an indicator to compare",
365
- filtersTitle: "Select an indicator to compare",
366
- // filterProperties: [],
367
- cssVars: {
368
- "--form-flex-direction": "row",
369
- },
370
- },
371
- },
372
- },
373
- },
374
- {
375
- id: Symbol(),
376
- type: "internal",
377
- title: "Layers",
378
- layout: { x: 0, y: 1, w: 3, h: 6 },
379
- widget: {
380
- name: "EodashLayerControl",
381
- },
382
- },
383
- {
384
- id: Symbol(),
385
- title: "Comparison Layers",
386
- layout: { x: 9, y: 1, w: 3, h: 6 },
387
- type: "internal",
388
- widget: {
389
- name: "EodashLayerControl",
390
- properties: {
391
- map: "second",
392
- },
393
- },
394
- },
395
- {
396
- defineWidget: (selectedSTAC) =>
397
- selectedSTAC?.links.some((l) => l.rel === "service")
398
- ? {
399
- id: Symbol(),
400
- type: "internal",
401
- title: "Processes",
402
- layout: { x: 0, y: 7, w: 3, h: 5 },
403
- widget: {
404
- name: "EodashProcess",
405
- },
406
- }
407
- : null,
408
- },
409
- {
410
- defineWidget: (selected) => {
411
- return selected
412
- ? {
413
- id: "Buttons",
414
- layout: { x: 8, y: 0, w: 1, h: 2 },
415
- title: "Buttons",
416
- type: "internal",
417
- widget: {
418
- name: "EodashMapBtns",
419
- properties: {
420
- compareIndicators: {
421
- fallbackTemplate: "expert",
422
- },
423
- },
424
- },
425
- }
426
- : null;
427
- },
428
- },
429
- {
430
- defineWidget: (selectedSTAC) => {
431
- return selectedSTAC
432
- ? {
433
- id: "expert-Datepicker",
434
- type: "internal",
435
- layout: { x: 5, y: 8, w: 2, h: 4 },
436
- title: "Date",
437
- widget: {
438
- name: "EodashDatePicker",
439
- properties: {
440
- hintText: `<b>Hint:</b> closest available date is displayed <br />
441
- on map (see Analysis Layers)`,
442
- toggleCalendar: true,
443
- },
444
- },
445
- }
446
- : null;
447
- },
448
- },
449
- ],
450
- },
451
- },
452
- });
453
-
454
- export default eodash;
@@ -1,52 +0,0 @@
1
- import { ref, createElementBlock, openBlock, createVNode, withCtx, mergeProps } from 'vue';
2
- import { a1 as makePanelTransparent, v as VIcon, ap as activeTemplate } from './asWebComponent-CLhcT715.js';
3
- import { mdiViewDashboard } from '@mdi/js';
4
- import { V as VTooltip } from './VTooltip-CfeefrXI.js';
5
-
6
- const _sfc_main = {
7
- __name: 'EodashLayoutSwitcher',
8
- props: {
9
- target: {
10
- type: String,
11
- default: "main",
12
- },
13
- // mdi/js icon
14
- icon: {
15
- type: String,
16
- default: mdiViewDashboard,
17
- },
18
- },
19
- setup(__props) {
20
-
21
-
22
-
23
- /** @type {import("vue").Ref<HTMLDivElement|null>} */
24
- const rootRef = ref(null);
25
- makePanelTransparent(rootRef);
26
-
27
- return (_ctx, _cache) => {
28
-
29
-
30
-
31
- return (openBlock(), createElementBlock("div", {
32
- ref_key: "rootRef",
33
- ref: rootRef
34
- }, [
35
- createVNode(VTooltip, {
36
- text: `Switch to ${__props.target} mode`
37
- }, {
38
- activator: withCtx(({ props }) => [
39
- createVNode(VIcon, mergeProps(props, {
40
- onClick: _cache[0] || (_cache[0] = $event => (activeTemplate.value = __props.target)),
41
- icon: [__props.icon]
42
- }), null, 16 /* FULL_PROPS */, ["icon"])
43
- ]),
44
- _: 1 /* STABLE */
45
- }, 8 /* PROPS */, ["text"])
46
- ], 512 /* NEED_PATCH */))
47
- }
48
- }
49
-
50
- };
51
-
52
- export { _sfc_main as default };
@@ -1,131 +0,0 @@
1
- import { computed, ref, createElementBlock, openBlock, createBlock, createCommentVNode, createVNode, unref, withCtx, triggerRef } from 'vue';
2
- import { _ as _export_sfc, Z as useSTAcStore, r as useDisplay, ae as switchToCompare, a1 as makePanelTransparent, V as VBtn, af as availableMapProjection, ag as changeMapProjection, ah as setActiveTemplate } from './asWebComponent-CLhcT715.js';
3
- import { mdiCompare, mdiCompareRemove, mdiMapPlus, mdiEarthBox } from '@mdi/js';
4
- import ExportState from './ExportState-DjyIZVhl.js';
5
- import _sfc_main$1 from './PopUp-BfB8s_ki.js';
6
- import _sfc_main$2 from './EodashItemFilter-DlQiE713.js';
7
- import { storeToRefs } from 'pinia';
8
-
9
- const _sfc_main = {
10
- __name: 'EodashMapBtns',
11
- props: {
12
- exportMap: {
13
- type: Boolean,
14
- default: true,
15
- },
16
- changeProjection: {
17
- type: Boolean,
18
- default: true,
19
- },
20
- compareIndicators: {
21
- /** @type {import("vue").PropType<boolean | {compareTemplate?:string;fallbackTemplate?:string}> }*/
22
- type: [Boolean, Object],
23
- default: true,
24
- },
25
- },
26
- setup(__props) {
27
-
28
-
29
- const { selectedStac, selectedCompareStac } = storeToRefs(useSTAcStore());
30
- const { smAndDown } = useDisplay();
31
- const popupWidth = computed(() => (smAndDown ? "70%" : "500px"));
32
- const popupHeight = computed(() => (smAndDown ? "90%" : "500px"));
33
-
34
- const showMapState = ref(false);
35
- const showCompareIndicators = ref(false);
36
- const compareIcon = computed(() =>
37
- switchToCompare.value ? mdiCompare : mdiCompareRemove,
38
- );
39
- const onCompareClick = () => {
40
- if (switchToCompare.value) {
41
- showCompareIndicators.value = !showCompareIndicators.value;
42
- } else {
43
- switchToCompare.value = true;
44
- const fallbackTemplate =
45
- (typeof __props.compareIndicators === "object" &&
46
- __props.compareIndicators.fallbackTemplate) ||
47
- "expert";
48
- selectedCompareStac.value = null;
49
- setActiveTemplate(fallbackTemplate);
50
- triggerRef(selectedStac);
51
- }
52
- };
53
-
54
- /** @type {import("vue").Ref<HTMLDivElement|null>} */
55
- const rootRef = ref(null);
56
-
57
- const onSelectCompareIndicator = () => {
58
- const compareTemplate =
59
- (typeof __props.compareIndicators === "object" &&
60
- __props.compareIndicators.compareTemplate) ||
61
- "compare";
62
- setActiveTemplate(compareTemplate);
63
- showCompareIndicators.value = !showCompareIndicators.value;
64
- };
65
-
66
- makePanelTransparent(rootRef);
67
-
68
- return (_ctx, _cache) => {
69
-
70
-
71
- return (openBlock(), createElementBlock("div", {
72
- ref_key: "rootRef",
73
- ref: rootRef,
74
- class: "d-flex flex-column align-end justify-end my-3 pa-2"
75
- }, [
76
- (__props.exportMap)
77
- ? (openBlock(), createBlock(VBtn, {
78
- key: 0,
79
- class: "map-btn",
80
- icon: [unref(mdiMapPlus)],
81
- onClick: _cache[0] || (_cache[0] = $event => (showMapState.value = !showMapState.value))
82
- }, null, 8 /* PROPS */, ["icon"]))
83
- : createCommentVNode("v-if", true),
84
- (__props.exportMap)
85
- ? (openBlock(), createBlock(ExportState, {
86
- key: 1,
87
- modelValue: showMapState.value,
88
- "onUpdate:modelValue": _cache[1] || (_cache[1] = $event => ((showMapState).value = $event))
89
- }, null, 8 /* PROPS */, ["modelValue"]))
90
- : createCommentVNode("v-if", true),
91
- (__props.changeProjection && !!unref(availableMapProjection))
92
- ? (openBlock(), createBlock(VBtn, {
93
- key: 2,
94
- class: "map-btn",
95
- icon: [unref(mdiEarthBox)],
96
- onClick: _cache[2] || (_cache[2] = $event => (unref(changeMapProjection)(unref(availableMapProjection))))
97
- }, null, 8 /* PROPS */, ["icon"]))
98
- : createCommentVNode("v-if", true),
99
- (__props.compareIndicators)
100
- ? (openBlock(), createBlock(VBtn, {
101
- key: 3,
102
- class: "map-btn",
103
- icon: [compareIcon.value],
104
- onClick: onCompareClick
105
- }, null, 8 /* PROPS */, ["icon"]))
106
- : createCommentVNode("v-if", true),
107
- createVNode(_sfc_main$1, {
108
- modelValue: showCompareIndicators.value,
109
- "onUpdate:modelValue": _cache[3] || (_cache[3] = $event => ((showCompareIndicators).value = $event)),
110
- maxWidth: popupWidth.value,
111
- maxHeight: popupHeight.value
112
- }, {
113
- default: withCtx(() => [
114
- createVNode(_sfc_main$2, {
115
- enableCompare: true,
116
- "filters-title": "",
117
- "results-title": "Select an indicator to compare",
118
- "filter-properties": [],
119
- onSelect: onSelectCompareIndicator
120
- })
121
- ]),
122
- _: 1 /* STABLE */
123
- }, 8 /* PROPS */, ["modelValue", "maxWidth", "maxHeight"])
124
- ], 512 /* NEED_PATCH */))
125
- }
126
- }
127
-
128
- };
129
- const EodashMapBtns = /*#__PURE__*/_export_sfc(_sfc_main, [['__scopeId',"data-v-da630fa1"]]);
130
-
131
- export { EodashMapBtns as default };