@eodash/eodash 5.0.0-alpha.1.1 → 5.0.0-alpha.1.12

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.
@@ -5,16 +5,15 @@
5
5
  </template>
6
6
 
7
7
  <script setup>
8
- import { useEodashRuntimeConfig } from "@/composables/DefineConfig";
8
+ import { useEodashRuntime } from "@/composables/DefineEodash";
9
9
  import { useUpdateTheme } from "@/composables";
10
10
  import { useSTAcStore } from '@/store/stac';
11
11
  import { defineAsyncComponent } from "vue";
12
12
  import { useDisplay, useLayout } from "vuetify/lib/framework.mjs";
13
13
  import { loadFont } from '@/store/Actions'
14
- import { onUnmounted } from "vue";
15
14
 
16
15
 
17
- const eodashConfig = await useEodashRuntimeConfig()
16
+ const eodashConfig = await useEodashRuntime()
18
17
 
19
18
  const theme = useUpdateTheme('dashboardTheme', eodashConfig.brand?.theme)
20
19
  theme.global.name.value = 'dashboardTheme'
@@ -31,15 +30,6 @@ const TemplateComponent = smAndDown.value ?
31
30
  const HeaderComponent = defineAsyncComponent(() => import(`@/components/Header.vue`))
32
31
  const FooterComponent = defineAsyncComponent(() => import(`@/components/Footer.vue`))
33
32
  const { mainRect } = useLayout()
34
-
35
- onUnmounted(() => {
36
- theme.global.name.value = 'light'
37
- })
38
-
39
- import.meta.hot?.on('reload', () => {
40
- window.location.reload()
41
- })
42
-
43
33
  </script>
44
34
 
45
35
  <style scoped lang="scss">
@@ -6,30 +6,12 @@ declare module '*.vue' {
6
6
  export default component
7
7
  }
8
8
  declare interface Window {
9
- eodashStore: EodashStore
10
- }
11
- declare module '@eox/itemfilter' {
12
- export const EOxItemFilter: CustomElementConstructor
9
+ eodashStore: import("@/types").EodashStore
13
10
  }
14
11
  declare module '@eox/stacinfo' {
15
12
  export const EOxStacInfo: CustomElementConstructor
16
13
  }
17
- declare module '@eox/map' {
18
- export const EOxMap: CustomElementConstructor
19
- }
20
- declare module '@eox/chart' {
21
- export const EOxChart: CustomElementConstructor
22
- }
23
- declare module '@eox/layercontrol' {
24
- export const EOxLayerControl: CustomElementConstructor
25
- }
26
- declare module '@eox/timecontrol' {
27
- export const EOxTimeControl: CustomElementConstructor
28
- }
29
- declare module '@eox/jsonform' {
30
- export const EOxJSONForm: CustomElementConstructor
31
- }
32
14
  declare module 'user:config' {
33
- const config: EodashConfig;
34
- export default config
15
+ const eodash: import("@/types").Eodash | Promise<import("@/types").Eodash>;
16
+ export default eodash
35
17
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eodash/eodash",
3
- "version": "5.0.0-alpha.1.1",
3
+ "version": "5.0.0-alpha.1.12",
4
4
  "type": "module",
5
5
  "types": "./core/types.d.ts",
6
6
  "files": [
@@ -16,7 +16,7 @@
16
16
  },
17
17
  "browser": "./core/main.js",
18
18
  "scripts": {
19
- "dev": "npx eodash dev",
19
+ "dev": "npx eodash dev --entryPoint core/eodash.js",
20
20
  "build": "npx eodash build",
21
21
  "check": "vue-tsc --noEmit --skipLibCheck && eslint .",
22
22
  "check:lint": "eslint .",
@@ -32,17 +32,17 @@
32
32
  "@vitejs/plugin-vue": "^5.0.0",
33
33
  "animated-details": "gist:2912bb049fa906671807415eb0e87188",
34
34
  "axios": "^1.6.2",
35
+ "commander": "^12.0.0",
35
36
  "core-js": "^3.29.0",
36
37
  "pinia": "^2.0.0",
37
- "roboto-fontface": "*",
38
+ "sass": "^1.60.0",
39
+ "stac-ts": "^1.0.3",
38
40
  "vite": "^5.1.5",
39
- "vite-plugin-virtual": "^0.3.0",
40
41
  "vite-plugin-vuetify": "^2.0.0",
41
42
  "vue": "^3.2.0",
42
43
  "vue-router": "^4.0.0",
43
44
  "vuetify": "^3.5.1",
44
- "webfontloader": "^1.6.28",
45
- "sass": "^1.60.0"
45
+ "webfontloader": "^1.6.28"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@babel/types": "^7.21.4",
@@ -51,7 +51,6 @@
51
51
  "@vue/eslint-config-typescript": "^11.0.0",
52
52
  "eslint": "^8.56.0",
53
53
  "eslint-plugin-vue": "^9.19.2",
54
- "stac-ts": "^1.0.3",
55
54
  "typedoc": "^0.25.7",
56
55
  "typedoc-plugin-markdown": "^3.17.1",
57
56
  "typescript": "^5.0.0",
@@ -63,4 +62,4 @@
63
62
  "bin": {
64
63
  "eodash": "./bin/app.js"
65
64
  }
66
- }
65
+ }
@@ -16,7 +16,7 @@ import 'animated-details'
16
16
 
17
17
  const props = defineProps({
18
18
  widgets: {
19
- /** @type {import('vue').PropType<Omit<WidgetConfig,'layout'>[]>} */
19
+ /** @type {import('vue').PropType<Omit<import("@/types").Widget,'layout'>[]>} */
20
20
  type: Array,
21
21
  required: true,
22
22
  }
package/bin/update.js DELETED
@@ -1,17 +0,0 @@
1
- import { cp } from "fs/promises";
2
- import { rootPublicPath, appPath, runtimeConfigPath, appPublicPath } from "./utils.js";
3
- import { existsSync } from "fs";
4
- import path from "path";
5
-
6
- export async function update() {
7
- if (rootPublicPath !== appPublicPath) {
8
- await cp(rootPublicPath, appPublicPath, { recursive: true }).catch(err => {
9
- console.error(err)
10
- })
11
- if (existsSync(runtimeConfigPath)) {
12
- await cp(runtimeConfigPath, path.join(appPath, '/public/config.js')).catch((e) => {
13
- console.error(e)
14
- })
15
- }
16
- }
17
- }
@@ -1,44 +0,0 @@
1
- import { eodashConfigKey } from "@/store/Keys"
2
- import { inject } from "vue"
3
- import store from '@/store'
4
-
5
- /**
6
- * Sets user defined configuration on runtime.
7
- * Consumes `/config.js` file from the base URL, and assign it to `eodashConfig`
8
- * @async
9
- * @returns {Promise<EodashConfig>}
10
- * @see {@linkplain '@/eodashConfig.js'}
11
- */
12
- export const useEodashRuntimeConfig = async () => {
13
- const eodashConfig = /** @type {EodashConfig} */(inject(eodashConfigKey))
14
- /**
15
- * @param {EodashConfig} updatedConfig
16
- */
17
- const assignConfig = (updatedConfig) => {
18
- /** @type {(keyof EodashConfig)[]} */(Object.keys(eodashConfig))
19
- .forEach((key) => {
20
- //@ts-expect-error
21
- eodashConfig[key] = updatedConfig[key]
22
- })
23
- }
24
-
25
- try {
26
- assignConfig(
27
- (await import( /* @vite-ignore */new URL('/config.js', import.meta.url).href)).default
28
- )
29
- } catch {
30
- try {
31
- assignConfig((await import("user:config")).default)
32
- } catch {
33
- console.error('no dashboard configuration assigned')
34
- }
35
- }
36
- return eodashConfig
37
- }
38
-
39
- /**
40
- * @param {(store:EodashStore)=>EodashConfig} configCallback
41
- */
42
- export const defineCompiletimeConfig = (configCallback) => {
43
- return configCallback(store)
44
- }