@aziontech/webkit 1.2.0 → 1.3.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 (37) hide show
  1. package/package.json +3 -2
  2. package/src/components/azion-system-status/azion-system-status.vue +0 -1
  3. package/src/components/azion-system-status/azion-system-status.vue.d.ts.map +1 -1
  4. package/src/core/form/field-auto-complete/field-auto-complete.vue +48 -45
  5. package/src/core/form/field-auto-complete/field-auto-complete.vue.d.ts.map +1 -1
  6. package/src/core/form/field-dropdown/field-dropdown.vue +68 -65
  7. package/src/core/form/field-dropdown/field-dropdown.vue.d.ts.map +1 -1
  8. package/src/core/form/field-dropdown-icon/field-dropdown-icon.vue +49 -46
  9. package/src/core/form/field-dropdown-icon/field-dropdown-icon.vue.d.ts.map +1 -1
  10. package/src/core/form/field-dropdown-lazy-loader/field-dropdown-lazy-loader.vue +116 -113
  11. package/src/core/form/field-dropdown-lazy-loader/field-dropdown-lazy-loader.vue.d.ts.map +1 -1
  12. package/src/core/form/field-dropdown-lazy-loader-dynamic/field-dropdown-lazy-loader-dynamic.vue +93 -90
  13. package/src/core/form/field-dropdown-lazy-loader-dynamic/field-dropdown-lazy-loader-dynamic.vue.d.ts.map +1 -1
  14. package/src/core/form/field-dropdown-lazy-loader-with-filter/field-dropdown-lazy-loader-with-filter.vue +111 -108
  15. package/src/core/form/field-dropdown-lazy-loader-with-filter/field-dropdown-lazy-loader-with-filter.vue.d.ts.map +1 -1
  16. package/src/core/form/field-dropdown-multi-select-lazy-loader/field-dropdown-multi-select-lazy-loader.vue +92 -89
  17. package/src/core/form/field-dropdown-multi-select-lazy-loader/field-dropdown-multi-select-lazy-loader.vue.d.ts.map +1 -1
  18. package/src/core/form/field-input-group/field-input-group.vue +44 -41
  19. package/src/core/form/field-input-group/field-input-group.vue.d.ts.map +1 -1
  20. package/src/core/form/field-multi-select/field-multi-select.vue +2 -2
  21. package/src/core/form/field-number/field-number.vue +46 -43
  22. package/src/core/form/field-number/field-number.vue.d.ts.map +1 -1
  23. package/src/core/form/field-phone-number/field-phone-number.vue +2 -2
  24. package/src/core/form/field-text/field-text.vue +43 -40
  25. package/src/core/form/field-text/field-text.vue.d.ts.map +1 -1
  26. package/src/core/form/field-text-area/field-text-area.vue +61 -58
  27. package/src/core/form/field-text-area/field-text-area.vue.d.ts.map +1 -1
  28. package/src/core/form/field-text-icon/field-text-icon.vue +48 -42
  29. package/src/core/form/field-text-icon/field-text-icon.vue.d.ts.map +1 -1
  30. package/src/core/form/field-text-password/field-text-password.vue +42 -39
  31. package/src/core/form/field-text-password/field-text-password.vue.d.ts.map +1 -1
  32. package/src/core/form/field-text-privacy/field-text-privacy.vue +132 -129
  33. package/src/core/form/field-text-privacy/field-text-privacy.vue.d.ts.map +1 -1
  34. package/src/core/form/slots/input-slot/input-slot.vue +8 -0
  35. package/src/core/form/slots/input-slot/input-slot.vue.d.ts +11 -0
  36. package/src/core/form/slots/input-slot/input-slot.vue.d.ts.map +1 -0
  37. package/src/core/form/slots/input-slot/package.json +11 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aziontech/webkit",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "Reusable UI components and design system utilities for building Azion web interfaces.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -22,7 +22,8 @@
22
22
  "dependencies": {
23
23
  "primevue": "3.35.0",
24
24
  "vee-validate": "^4.15.1",
25
- "vue-tsc": "^3.2.5"
25
+ "vue-tsc": "^3.2.5",
26
+ "@vueuse/core": "^10.11.1"
26
27
  },
27
28
  "devDependencies": {
28
29
  "@semantic-release/changelog": "^6.0.3",
@@ -1,5 +1,4 @@
1
1
  <script setup>
2
- // azion system status button
3
2
  import PrimeButton from 'primevue/button'
4
3
  import { ref, computed, onMounted } from 'vue'
5
4
 
@@ -1 +1 @@
1
- {"version":3,"file":"azion-system-status.vue.d.ts","sourceRoot":"","sources":["azion-system-status.vue"],"names":[],"mappings":"wBA0SqB,OAAO,YAAY;;AAFxC,0SACG"}
1
+ {"version":3,"file":"azion-system-status.vue.d.ts","sourceRoot":"","sources":["azion-system-status.vue"],"names":[],"mappings":"wBAwSqB,OAAO,YAAY;;AAFxC,0SACG"}
@@ -2,6 +2,7 @@
2
2
  import { ref, toRef } from 'vue'
3
3
  import { useField } from 'vee-validate'
4
4
  import AutoComplete from 'primevue/autocomplete'
5
+ import InputSlot from '../slots/input-slot'
5
6
 
6
7
  const props = defineProps({
7
8
  value: {
@@ -67,55 +68,57 @@
67
68
  </script>
68
69
 
69
70
  <template>
70
- <label
71
- :for="props.name"
72
- class="text-color text-base font-medium leading-5"
73
- >
74
- {{ props.label }}
75
- </label>
71
+ <InputSlot>
72
+ <label
73
+ :for="props.name"
74
+ class="text-color text-base font-medium leading-5"
75
+ >
76
+ {{ props.label }}
77
+ </label>
76
78
 
77
- <div
78
- class="p-inputgroup h-fit"
79
- :class="{ 'border border-red-500 rounded-md surface-border': errorMessage }"
80
- >
81
79
  <div
82
- class="p-inputgroup-addon"
83
- :class="{ 'opacity-20': props.disabled }"
80
+ class="p-inputgroup h-fit"
81
+ :class="{ 'border border-red-500 rounded-md surface-border': errorMessage }"
84
82
  >
85
- <i
86
- v-if="props.icon"
87
- :class="props.icon"
88
- class="text-color-secondary"
83
+ <div
84
+ class="p-inputgroup-addon"
85
+ :class="{ 'opacity-20': props.disabled }"
86
+ >
87
+ <i
88
+ v-if="props.icon"
89
+ :class="props.icon"
90
+ class="text-color-secondary"
91
+ />
92
+ </div>
93
+ <AutoComplete
94
+ ref="autoCompleteRef"
95
+ :readonly="props.readonly"
96
+ class="w-full"
97
+ :placeholder="props.placeholder"
98
+ :id="props.name"
99
+ :name="props.name"
100
+ v-model="inputValue"
101
+ :suggestions="props.suggestions"
102
+ @complete="props.onComplete"
103
+ :disabled="props.disabled"
104
+ :completeOnFocus="props.completeOnFocus"
105
+ @input="handleChange"
106
+ @blur="handleBlur"
107
+ v-bind="$attrs"
89
108
  />
90
109
  </div>
91
- <AutoComplete
92
- ref="autoCompleteRef"
93
- :readonly="props.readonly"
94
- class="w-full"
95
- :placeholder="props.placeholder"
96
- :id="props.name"
97
- :name="props.name"
98
- v-model="inputValue"
99
- :suggestions="props.suggestions"
100
- @complete="props.onComplete"
101
- :disabled="props.disabled"
102
- :completeOnFocus="props.completeOnFocus"
103
- @input="handleChange"
104
- @blur="handleBlur"
105
- v-bind="$attrs"
106
- />
107
- </div>
108
110
 
109
- <small
110
- v-if="errorMessage"
111
- class="p-error text-xs font-normal leading-tight"
112
- >
113
- {{ errorMessage }}
114
- </small>
115
- <small
116
- class="text-xs text-color-secondary font-normal leading-5"
117
- v-if="props.description"
118
- >
119
- {{ props.description }}
120
- </small>
111
+ <small
112
+ v-if="errorMessage"
113
+ class="p-error text-xs font-normal leading-tight"
114
+ >
115
+ {{ errorMessage }}
116
+ </small>
117
+ <small
118
+ class="text-xs text-color-secondary font-normal leading-5"
119
+ v-if="props.description"
120
+ >
121
+ {{ props.description }}
122
+ </small>
123
+ </InputSlot>
121
124
  </template>
@@ -1 +1 @@
1
- {"version":3,"file":"field-auto-complete.vue.d.ts","sourceRoot":"","sources":["field-auto-complete.vue"],"names":[],"mappings":"wBA+WqB,OAAO,YAAY;;AAjDxC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAgDG"}
1
+ {"version":3,"file":"field-auto-complete.vue.d.ts","sourceRoot":"","sources":["field-auto-complete.vue"],"names":[],"mappings":"wBAmYqB,OAAO,YAAY;;AAjDxC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAgDG"}
@@ -2,7 +2,8 @@
2
2
  import Dropdown from 'primevue/dropdown'
3
3
  import { useField } from 'vee-validate'
4
4
  import { computed, toRef, useSlots, useAttrs } from 'vue'
5
- import LabelBlock from '../label'
5
+ import Label from '../label'
6
+ import InputSlot from '../slots/input-slot'
6
7
 
7
8
  const props = defineProps({
8
9
  value: {
@@ -172,69 +173,71 @@
172
173
  </script>
173
174
 
174
175
  <template>
175
- <LabelBlock
176
- :for="props.name"
177
- :label="props.label"
178
- :isRequired="$attrs.required"
179
- :data-testid="customTestId.label"
180
- v-if="props.label"
181
- />
182
- <Dropdown
183
- :dropdown-icon="isDisabledIcon"
184
- :editable="props.editable"
185
- appendTo="self"
186
- :id="name"
187
- :name="props.name"
188
- :loading="props.loading"
189
- v-model="inputValue"
190
- :options="props.options"
191
- :optionLabel="props.optionLabel"
192
- :optionDisabled="props.optionDisabled"
193
- :filter="props.filter"
194
- :optionValue="props.optionValue"
195
- :optionGroupLabel="props.optionGroupLabel"
196
- :optionGroupChildren="props.optionGroupChildren"
197
- :placeholder="props.placeholder"
198
- :autoFilterFocus="props.filter"
199
- :emptyMessage="props.emptyMessage"
200
- :emptyFilterMessage="props.emptyFilterMessage"
201
- @change="emitChange"
202
- @blur="emitBlur"
203
- :class="{ 'p-invalid': aditionalError || errorMessage }"
204
- v-bind="$attrs"
205
- :disabled="props.disabled"
206
- class="w-full"
207
- :pt="passThrough"
208
- :data-testid="customTestId.dropdown"
209
- >
210
- <template
211
- v-if="enableCustomLabel"
212
- #value="slotProps"
176
+ <InputSlot>
177
+ <Label
178
+ :for="props.name"
179
+ :label="props.label"
180
+ :isRequired="$attrs.required"
181
+ :data-testid="customTestId.label"
182
+ v-if="props.label"
183
+ />
184
+ <Dropdown
185
+ :dropdown-icon="isDisabledIcon"
186
+ :editable="props.editable"
187
+ appendTo="self"
188
+ :id="name"
189
+ :name="props.name"
190
+ :loading="props.loading"
191
+ v-model="inputValue"
192
+ :options="props.options"
193
+ :optionLabel="props.optionLabel"
194
+ :optionDisabled="props.optionDisabled"
195
+ :filter="props.filter"
196
+ :optionValue="props.optionValue"
197
+ :optionGroupLabel="props.optionGroupLabel"
198
+ :optionGroupChildren="props.optionGroupChildren"
199
+ :placeholder="props.placeholder"
200
+ :autoFilterFocus="props.filter"
201
+ :emptyMessage="props.emptyMessage"
202
+ :emptyFilterMessage="props.emptyFilterMessage"
203
+ @change="emitChange"
204
+ @blur="emitBlur"
205
+ :class="{ 'p-invalid': aditionalError || errorMessage }"
206
+ v-bind="$attrs"
207
+ :disabled="props.disabled"
208
+ class="w-full"
209
+ :pt="passThrough"
210
+ :data-testid="customTestId.dropdown"
213
211
  >
214
- <span :data-testid="customTestId.value">
215
- {{ getLabelBySelectedValue(slotProps.value) }}
216
- </span>
217
- </template>
218
-
219
- <template #footer>
220
- <slot name="footer" />
221
- </template>
222
- </Dropdown>
223
-
224
- <small
225
- v-if="aditionalError || errorMessage"
226
- :data-testid="customTestId.error"
227
- class="p-error text-xs font-normal leading-tight"
228
- >
229
- {{ aditionalError || errorMessage }}
230
- </small>
231
- <small
232
- class="text-xs text-color-secondary font-normal leading-5"
233
- :data-testid="customTestId.description"
234
- v-if="props.description || hasDescriptionSlot"
235
- >
236
- <slot name="description">
237
- {{ props.description }}
238
- </slot>
239
- </small>
212
+ <template
213
+ v-if="enableCustomLabel"
214
+ #value="slotProps"
215
+ >
216
+ <span :data-testid="customTestId.value">
217
+ {{ getLabelBySelectedValue(slotProps.value) }}
218
+ </span>
219
+ </template>
220
+
221
+ <template #footer>
222
+ <slot name="footer" />
223
+ </template>
224
+ </Dropdown>
225
+
226
+ <small
227
+ v-if="aditionalError || errorMessage"
228
+ :data-testid="customTestId.error"
229
+ class="p-error text-xs font-normal leading-tight"
230
+ >
231
+ {{ aditionalError || errorMessage }}
232
+ </small>
233
+ <small
234
+ class="text-xs text-color-secondary font-normal leading-5"
235
+ :data-testid="customTestId.description"
236
+ v-if="props.description || hasDescriptionSlot"
237
+ >
238
+ <slot name="description">
239
+ {{ props.description }}
240
+ </slot>
241
+ </small>
242
+ </InputSlot>
240
243
  </template>
@@ -1 +1 @@
1
- {"version":3,"file":"field-dropdown.vue.d.ts","sourceRoot":"","sources":["field-dropdown.vue"],"names":[],"mappings":"wBA+pBqB,OAAO,YAAY;;AADxC,4BAA2B,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;qBAEtD,CAAC,EAAE,CAAC;;;AAvFzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAoFG"}
1
+ {"version":3,"file":"field-dropdown.vue.d.ts","sourceRoot":"","sources":["field-dropdown.vue"],"names":[],"mappings":"wBAmrBqB,OAAO,YAAY;;AADxC,4BAA2B,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;qBAEtD,CAAC,EAAE,CAAC;;;AAvFzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAoFG"}
@@ -2,6 +2,7 @@
2
2
  import { ref, toRef } from 'vue'
3
3
  import { useField } from 'vee-validate'
4
4
  import Dropdown from 'primevue/dropdown'
5
+ import InputSlot from '../slots/input-slot'
5
6
 
6
7
  const emit = defineEmits(['onChange'])
7
8
 
@@ -74,56 +75,58 @@
74
75
  </script>
75
76
 
76
77
  <template>
77
- <label
78
- :for="props.name"
79
- class="text-color text-base font-medium leading-5"
80
- >
81
- {{ props.label }}
82
- </label>
78
+ <InputSlot>
79
+ <label
80
+ :for="props.name"
81
+ class="text-color text-base font-medium leading-5"
82
+ >
83
+ {{ props.label }}
84
+ </label>
83
85
 
84
- <div
85
- class="p-inputgroup h-fit"
86
- :class="{ 'border border-red-500 rounded-md surface-border': errorMessage }"
87
- >
88
86
  <div
89
- class="p-inputgroup-addon"
90
- :class="{ 'opacity-20': props.disabled }"
87
+ class="p-inputgroup h-fit"
88
+ :class="{ 'border border-red-500 rounded-md surface-border': errorMessage }"
91
89
  >
92
- <i
93
- v-if="props.icon"
94
- :class="props.icon"
95
- class="text-color-secondary"
90
+ <div
91
+ class="p-inputgroup-addon"
92
+ :class="{ 'opacity-20': props.disabled }"
93
+ >
94
+ <i
95
+ v-if="props.icon"
96
+ :class="props.icon"
97
+ class="text-color-secondary"
98
+ />
99
+ </div>
100
+ <Dropdown
101
+ ref="autoCompleteRef"
102
+ :readonly="props.readonly"
103
+ class="w-full"
104
+ :placeholder="props.placeholder"
105
+ :id="props.name"
106
+ :name="props.name"
107
+ v-model="inputValue"
108
+ :suggestions="props.suggestions"
109
+ @complete="props.onComplete"
110
+ :disabled="props.disabled"
111
+ :completeOnFocus="props.completeOnFocus"
112
+ @input="handleChange"
113
+ @blur="handleBlur"
114
+ v-bind="$attrs"
115
+ @change="handleChangeEvent"
96
116
  />
97
117
  </div>
98
- <Dropdown
99
- ref="autoCompleteRef"
100
- :readonly="props.readonly"
101
- class="w-full"
102
- :placeholder="props.placeholder"
103
- :id="props.name"
104
- :name="props.name"
105
- v-model="inputValue"
106
- :suggestions="props.suggestions"
107
- @complete="props.onComplete"
108
- :disabled="props.disabled"
109
- :completeOnFocus="props.completeOnFocus"
110
- @input="handleChange"
111
- @blur="handleBlur"
112
- v-bind="$attrs"
113
- @change="handleChangeEvent"
114
- />
115
- </div>
116
118
 
117
- <small
118
- v-if="errorMessage"
119
- class="p-error text-xs font-normal leading-tight"
120
- >
121
- {{ errorMessage }}
122
- </small>
123
- <small
124
- class="text-xs text-color-secondary font-normal leading-5"
125
- v-if="props.description"
126
- >
127
- {{ props.description }}
128
- </small>
119
+ <small
120
+ v-if="errorMessage"
121
+ class="p-error text-xs font-normal leading-tight"
122
+ >
123
+ {{ errorMessage }}
124
+ </small>
125
+ <small
126
+ class="text-xs text-color-secondary font-normal leading-5"
127
+ v-if="props.description"
128
+ >
129
+ {{ props.description }}
130
+ </small>
131
+ </InputSlot>
129
132
  </template>
@@ -1 +1 @@
1
- {"version":3,"file":"field-dropdown-icon.vue.d.ts","sourceRoot":"","sources":["field-dropdown-icon.vue"],"names":[],"mappings":"wBAuYqB,OAAO,YAAY;;AAlDxC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAiDG"}
1
+ {"version":3,"file":"field-dropdown-icon.vue.d.ts","sourceRoot":"","sources":["field-dropdown-icon.vue"],"names":[],"mappings":"wBA2ZqB,OAAO,YAAY;;AAlDxC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAiDG"}