sprintify-ui 0.0.160 → 0.0.161

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.
@@ -24244,7 +24244,9 @@ const Ey = ["value", "name", "disabled", "required"], Oy = ["value"], Ay = /* @_
24244
24244
  return [...((m = a.value) == null ? void 0 : m.options) ?? []];
24245
24245
  }
24246
24246
  function w() {
24247
- return e.modelValue === o ? !0 : e.options && e.options.length ? e.options.some((m) => Ci(m.value, e.modelValue)) : f.value.some((m) => Ci(m.value, e.modelValue));
24247
+ return e.modelValue === o ? !0 : e.options && e.options.length ? e.options.some(
24248
+ (m) => Ci(m[e.valueKey], e.modelValue)
24249
+ ) : f.value.some((m) => Ci(m.value, e.modelValue));
24248
24250
  }
24249
24251
  function b(m) {
24250
24252
  m === null && h(o);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sprintify-ui",
3
- "version": "0.0.160",
3
+ "version": "0.0.161",
4
4
  "scripts": {
5
5
  "build": "rimraf dist && vue-tsc && vite build",
6
6
  "build-fast": "rimraf dist && vite build",
@@ -103,7 +103,7 @@ export const OptionsAsProps = (args) => ({
103
103
  OptionsAsProps.args = {
104
104
  required: true,
105
105
  labelKey: 'label',
106
- valueKey: 'value',
106
+ valueKey: 'label',
107
107
  };
108
108
 
109
109
  export const Field = createFieldStory({
@@ -159,7 +159,9 @@ function checkIfModelValueIsValid(): boolean {
159
159
  }
160
160
 
161
161
  if (props.options && props.options.length) {
162
- return props.options.some((o) => isEqual(o.value, props.modelValue));
162
+ return props.options.some((o) =>
163
+ isEqual(o[props.valueKey as any], props.modelValue)
164
+ );
163
165
  }
164
166
 
165
167
  return options.value.some((o) => isEqual(o.value, props.modelValue));