@geode/opengeodeweb-front 0.0.8 → 0.0.10

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.
@@ -0,0 +1,30 @@
1
+ <template>
2
+ <v-container>
3
+ <h1 class="text-h2 py-2" align="center">
4
+ {{ tool_name }}
5
+ </h1>
6
+ <v-col>
7
+ <v-row class="justify-center">
8
+ <v-col v-for="(card, i) in cards_list" :key="i" cols="11" md="5">
9
+ <v-card class="card" hover elevation="5" :href="card.href" rounded target="_blank">
10
+ <v-card-title primary-title class="justify-center text-h6" align="center">
11
+ {{ card.title }}
12
+ </v-card-title>
13
+ <v-row class="justify-center pa-2">
14
+ <v-col cols="auto">
15
+ <v-icon :icon="card.icon" color="primary" size="70" class="justify-center" />
16
+ </v-col>
17
+ </v-row>
18
+ </v-card>
19
+ </v-col>
20
+ </v-row>
21
+ </v-col>
22
+ </v-container>
23
+ </template>
24
+
25
+ <script setup>
26
+ const props = defineProps({
27
+ tool_name: { type: String, required: true },
28
+ cards_list: { type: Object, required: true }
29
+ })
30
+ </script>
@@ -0,0 +1,56 @@
1
+ <template>
2
+ <v-container justify="space-around">
3
+ <v-row align-content="center" align="center">
4
+ <v-col v-if="!is_captcha_validated" cols="12" align-self="center" align="center">
5
+ <h4 class="pb-3">
6
+ Please complete the recaptcha to launch the app
7
+ </h4>
8
+ <vue-recaptcha ref="recaptcha" :sitekey="config.public.SITE_KEY" :loadRecaptchaScript="true"
9
+ @expired="is_captcha_validated = false" @verify="submit_recaptcha" align-self="center" />
10
+ </v-col>
11
+ <v-col v-if="!is_cloud_running && is_connexion_launched">
12
+ <Loading />
13
+ </v-col>
14
+ </v-row>
15
+ </v-container>
16
+ </template>
17
+
18
+ <script setup>
19
+ import { VueRecaptcha } from "vue-recaptcha"
20
+
21
+ // const ws_link_store = use_ws_link_store()
22
+ const cloud_store = use_cloud_store()
23
+ const { is_cloud_running, is_captcha_validated, is_connexion_launched } = storeToRefs(cloud_store)
24
+
25
+ watch(is_captcha_validated, async (value) => {
26
+ if (value === true) {
27
+ await cloud_store.create_connexion()
28
+ // await ws_link_store.ws_connect()
29
+ }
30
+ })
31
+
32
+ watch(is_cloud_running, (value, oldValue) => {
33
+ if (value === false && oldValue == true) {
34
+ cloud_store.$patch({ internal_error: true })
35
+ }
36
+ })
37
+
38
+ onMounted(() => {
39
+ if (process.client) {
40
+ const config = useRuntimeConfig()
41
+ if (config.public.NODE_ENV !== 'production') {
42
+ cloud_store.$patch({ is_captcha_validated: true })
43
+ }
44
+ }
45
+ })
46
+
47
+ async function submit_recaptcha (token) {
48
+ try {
49
+ const config = useRuntimeConfig()
50
+ const response = await $fetch.raw(`${config.public.SITE_URL}/.netlify/functions/recaptcha?token=${token}`)
51
+ cloud_store.$patch({ is_captcha_validated: response.status == 200 })
52
+ recaptcha.reset()
53
+ } catch (error) {
54
+ }
55
+ }
56
+ </script>
@@ -0,0 +1,24 @@
1
+ <template>
2
+ <v-row justify="center">
3
+ <v-col cols="12" class="ma-3">
4
+ <v-card class="card" loading elevation="5">
5
+ <v-card-title class="text-center">
6
+ Cloud instance is starting...
7
+ </v-card-title>
8
+ <v-card-subtitle class="text-center">
9
+ Why do you have to wait?
10
+ </v-card-subtitle>
11
+ <v-card-text class="text-center">
12
+ We start our server only on demand... and this takes a few minutes before
13
+ you can use our free app.
14
+ <br>
15
+ This is aligned with an energy sobriety strategy. So be patient
16
+ <v-icon color="primary" size="20">
17
+ mdi-emoticon-excited-outline
18
+ </v-icon>
19
+ <br>
20
+ </v-card-text>
21
+ </v-card>
22
+ </v-col>
23
+ </v-row>
24
+ </template>
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <v-card class="card">
3
3
  <div v-for="(step, index) in steps" :key="index" class="pa-3">
4
- <ToolsStep :step_index="index" />
4
+ <Step :step_index="index" />
5
5
  </div>
6
6
  </v-card>
7
7
  </template>
@@ -2,16 +2,16 @@
2
2
  <v-container>
3
3
  <v-row class="flex-column">
4
4
  <v-col>
5
- <ToolsHeader :tool_name="tool_name" :cards_list="cards_list" />
5
+ <Header :tool_name="tool_name" :cards_list="cards_list" />
6
6
  </v-col>
7
7
  <v-col v-if="!is_cloud_running">
8
- <ToolsLauncher />
8
+ <Launcher />
9
9
  </v-col>
10
10
  <v-col v-if="is_cloud_running">
11
- <ToolsStepper />
11
+ <Stepper />
12
12
  </v-col>
13
13
  <v-col v-if="is_cloud_running">
14
- <ToolsPackagesVersions :route_prefix="route_prefix" />
14
+ <PackagesVersions :route_prefix="route_prefix" />
15
15
  </v-col>
16
16
  </v-row>
17
17
  </v-container>
package/package.json CHANGED
@@ -15,17 +15,18 @@
15
15
  },
16
16
  "description": "OpenSource Vue/Vuetify framework for web applications",
17
17
  "type": "module",
18
- "version": "0.0.8",
18
+ "version": "0.0.10",
19
19
  "main": "./nuxt.config.js",
20
20
  "dependencies": {
21
21
  "@mdi/font": "^7.2.96",
22
22
  "@pinia/nuxt": "^0.4.11",
23
- "@types/node": "^20.4.9",
23
+ "@types/node": "^20.5.0",
24
24
  "@vueuse/core": "^10.3.0",
25
25
  "pinia": "^2.1.6",
26
26
  "semver": "^7.5.4",
27
27
  "sass": "^1.65.1",
28
- "vuetify": "^3.3.12"
28
+ "vuetify": "^3.3.13",
29
+ "vue-recaptcha": "^2.0.3"
29
30
  },
30
31
  "repository": {
31
32
  "type": "git",