@geode/opengeodeweb-front 9.2.2 → 9.2.3-rc.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.
@@ -2,18 +2,7 @@
2
2
  <ClientOnly>
3
3
  <div style="position: relative; width: 100%; height: 100%">
4
4
  <view-toolbar />
5
- <div
6
- style="
7
- position: absolute;
8
- z-index: 2;
9
- left: 0;
10
- top: 0;
11
- background-color: transparent;
12
- border-radius: 16px;
13
- "
14
- >
15
- <slot name="tree-object"></slot>
16
- </div>
5
+ <slot name="ui"></slot>
17
6
  <v-col
18
7
  ref="viewer"
19
8
  style="
@@ -26,9 +15,7 @@
26
15
  class="pa-0"
27
16
  @click="get_x_y"
28
17
  @keydown.esc="app_store.toggle_picking_mode(false)"
29
- >
30
- <slot name="ui"></slot>
31
- </v-col>
18
+ />
32
19
  </div>
33
20
  </ClientOnly>
34
21
  </template>
@@ -1,7 +1,11 @@
1
1
  <template>
2
- <v-card class="pa-5">
3
- <v-row align="center" @click="set_current_step(step_index)">
4
- <v-col cols="auto">
2
+ <v-stepper-content :step="step_index + 1">
3
+ <v-row
4
+ align="center"
5
+ class="step-container"
6
+ @click="set_current_step(step_index)"
7
+ >
8
+ <v-col cols="auto" class="icon-container">
5
9
  <v-icon
6
10
  v-if="current_step_index > step_index"
7
11
  icon="mdi-check-circle"
@@ -18,8 +22,8 @@
18
22
  color="grey"
19
23
  />
20
24
  </v-col>
21
- <v-col cols="auto">
22
- <p class="font-weight-bold">
25
+ <v-col class="title-container">
26
+ <p class="step-title font-weight-bold">
23
27
  {{ steps[step_index].step_title }}
24
28
  </p>
25
29
  </v-col>
@@ -27,34 +31,34 @@
27
31
  v-if="
28
32
  steps[step_index].chips.length && current_step_index >= step_index
29
33
  "
34
+ class="chips-container"
30
35
  >
31
36
  <v-chip
32
37
  v-for="(chip, chip_index) in steps[step_index].chips"
33
38
  :key="chip_index"
39
+ class="step-chip"
34
40
  >
35
41
  {{ chip }}
36
42
  </v-chip>
37
43
  </v-col>
38
44
  </v-row>
39
- <Transition name="slide-fade">
40
- <v-col v-if="step_index == current_step_index">
41
- <component
42
- :is="steps[step_index].component.component_name"
43
- v-bind="steps[step_index].component.component_options"
44
- @update_values="update_values_event"
45
- @increment_step="increment_step()"
46
- @decrement_step="decrement_step()"
47
- />
48
- </v-col>
49
- </Transition>
50
- </v-card>
45
+ <component
46
+ v-if="step_index == current_step_index"
47
+ :key="step_index"
48
+ :is="steps[step_index].component.component_name"
49
+ v-bind="steps[step_index].component.component_options"
50
+ @update_values="update_values_event"
51
+ @increment_step="increment_step"
52
+ @decrement_step="decrement_step"
53
+ />
54
+ </v-stepper-content>
51
55
  </template>
52
56
 
53
57
  <script setup>
54
58
  const props = defineProps({
55
59
  step_index: { type: Number, required: true },
56
60
  })
57
- const { step_index } = props
61
+
58
62
  const stepper_tree = inject("stepper_tree")
59
63
  const { current_step_index, steps } = toRefs(stepper_tree)
60
64
 
@@ -78,17 +82,31 @@
78
82
  </script>
79
83
 
80
84
  <style scoped>
81
- .slide-fade-enter-active {
82
- transition: all 0.5s ease-out;
85
+ .step-container {
86
+ margin-bottom: 16px;
87
+ padding: 8px;
88
+ }
89
+
90
+ .icon-container {
91
+ display: flex;
92
+ justify-content: center;
93
+ align-items: center;
94
+ }
95
+
96
+ .title-container {
97
+ margin-left: 8px;
98
+ }
99
+
100
+ .step-title {
101
+ margin: 0;
83
102
  }
84
103
 
85
- .slide-fade-leave-active {
86
- transition: all 0.5s ease-in;
104
+ .chips-container {
105
+ display: flex;
106
+ gap: 4px;
87
107
  }
88
108
 
89
- .slide-fade-enter-from,
90
- .slide-fade-leave-to {
91
- transform: translateX(50px);
92
- opacity: 0;
109
+ .step-chip {
110
+ background-color: #f5f5f5;
93
111
  }
94
112
  </style>
@@ -1,12 +1,23 @@
1
1
  <template>
2
- <v-card class="card">
3
- <div v-for="(step, index) in steps" :key="index" class="pa-3">
4
- <Step :step_index="index" />
5
- </div>
6
- </v-card>
2
+ <v-stepper-vertical v-model="current_step_index" class="stepper-container">
3
+ <v-stepper-items>
4
+ <Step v-for="(step, index) in steps" :key="step" :step_index="index" />
5
+ </v-stepper-items>
6
+ </v-stepper-vertical>
7
7
  </template>
8
8
 
9
9
  <script setup>
10
10
  const stepper_tree = inject("stepper_tree")
11
- const { steps } = stepper_tree
11
+ const { steps, current_step_index } = toRefs(stepper_tree)
12
12
  </script>
13
+
14
+ <style scoped>
15
+ .stepper-container {
16
+ max-width: 600px;
17
+ margin: 0 auto;
18
+ padding: 16px;
19
+ background-color: #f9f9f9;
20
+ border-radius: 8px;
21
+ border: 1px solid #e0e0e0;
22
+ }
23
+ </style>
package/package.json CHANGED
@@ -37,7 +37,7 @@
37
37
  },
38
38
  "description": "OpenSource Vue/Vuetify framework for web applications",
39
39
  "type": "module",
40
- "version": "9.2.2",
40
+ "version": "9.2.3-rc.2",
41
41
  "main": "./nuxt.config.js",
42
42
  "dependencies": {
43
43
  "@geode/opengeodeweb-back": "5.4.0",
@@ -97,7 +97,7 @@ describe("FileSelector.vue", async () => {
97
97
  })
98
98
 
99
99
  await flushPromises()
100
- expect(wrapper.componentVM.files).toEqual(files)
100
+ expect(wrapper.componentVM.props.files).toEqual(files)
101
101
  expect(wrapper.emitted()).toHaveProperty("update_values")
102
102
  expect(wrapper.emitted().update_values).toHaveLength(1)
103
103
  expect(wrapper.emitted().update_values[0][0]).toEqual({
@@ -123,8 +123,7 @@ describe("FileSelector.vue", async () => {
123
123
  await flushPromises()
124
124
 
125
125
  const file_uploader = wrapper.findComponent(FileUploader)
126
- console.log("wrapper", wrapper)
127
- expect(wrapper.vm.files).toEqual(files)
126
+ expect(wrapper.vm.props.files).toEqual(files)
128
127
  const upload_files = vi.spyOn(file_uploader.vm, "upload_files")
129
128
  expect(upload_files).not.toHaveBeenCalled()
130
129
  })