@kiva/kv-components 3.102.1 → 3.102.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.
- package/CHANGELOG.md +11 -0
- package/package.json +2 -2
- package/vue/KvSelect.vue +12 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [3.102.2](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@3.102.1...@kiva/kv-components@3.102.2) (2024-09-26)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* change how model value is handled for select component ([5626a8f](https://github.com/kiva/kv-ui-elements/commit/5626a8fcb2a464d72abbda06968dec56496e4204))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
## [3.102.1](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@3.102.0...@kiva/kv-components@3.102.1) (2024-09-23)
|
|
7
18
|
|
|
8
19
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kiva/kv-components",
|
|
3
|
-
"version": "3.102.
|
|
3
|
+
"version": "3.102.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -83,5 +83,5 @@
|
|
|
83
83
|
"optional": true
|
|
84
84
|
}
|
|
85
85
|
},
|
|
86
|
-
"gitHead": "
|
|
86
|
+
"gitHead": "045a91050100e52132289efff23cd542ac1ae89d"
|
|
87
87
|
}
|
package/vue/KvSelect.vue
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
<select
|
|
10
10
|
:id="id"
|
|
11
11
|
v-bind="inputAttrs"
|
|
12
|
+
v-model="inputValue"
|
|
12
13
|
:disabled="disabled"
|
|
13
|
-
:value="modelValue"
|
|
14
14
|
class="tw-text-base tw-bg-primary tw-h-6 tw-pr-4 tw-pl-2 tw-border tw-border-tertiary tw-rounded-sm tw-appearance-none tw-w-full tw-ring-inset focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-action focus:tw-border-transparent"
|
|
15
15
|
:class="{ 'tw-opacity-low': disabled }"
|
|
16
16
|
@change="onChange"
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
</template>
|
|
29
29
|
|
|
30
30
|
<script>
|
|
31
|
-
import 'vue-demi';
|
|
31
|
+
import { ref, watch } from 'vue-demi';
|
|
32
32
|
import { mdiChevronDown } from '@mdi/js';
|
|
33
33
|
import KvMaterialIcon from './KvMaterialIcon.vue';
|
|
34
34
|
import { useAttrs } from '../utils/attrs';
|
|
@@ -82,6 +82,14 @@ export default {
|
|
|
82
82
|
inputListeners,
|
|
83
83
|
} = useAttrs(context, emits);
|
|
84
84
|
|
|
85
|
+
const inputValue = ref(props.modelValue);
|
|
86
|
+
|
|
87
|
+
watch(() => props.modelValue, (newValue) => {
|
|
88
|
+
if (newValue !== inputValue.value) {
|
|
89
|
+
inputValue.value = newValue;
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
|
|
85
93
|
const onChange = (event) => {
|
|
86
94
|
/**
|
|
87
95
|
* The value that the select has changed to
|
|
@@ -91,6 +99,7 @@ export default {
|
|
|
91
99
|
emit('change', event.target.value);
|
|
92
100
|
emit('update:modelValue', event.target.value);
|
|
93
101
|
};
|
|
102
|
+
|
|
94
103
|
return {
|
|
95
104
|
mdiChevronDown,
|
|
96
105
|
onChange,
|
|
@@ -98,6 +107,7 @@ export default {
|
|
|
98
107
|
styles,
|
|
99
108
|
inputAttrs,
|
|
100
109
|
inputListeners,
|
|
110
|
+
inputValue,
|
|
101
111
|
};
|
|
102
112
|
},
|
|
103
113
|
};
|