@nmorph/nmorph-ui-kit 2.2.37 → 2.2.38

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 (52) hide show
  1. package/dist/components/data/nmorph-card/NmorphCard.vue2.js +19 -16
  2. package/dist/components/form/nmorph-autocomplete/NmorphAutocomplete.vue2.js +67 -65
  3. package/dist/components/form/nmorph-checkbox/NmorphCheckbox.css +1 -1
  4. package/dist/components/form/nmorph-checkbox/NmorphCheckbox.vue2.js +28 -26
  5. package/dist/components/form/nmorph-checkbox-group/NmorphCheckboxGroup.vue2.js +25 -20
  6. package/dist/components/form/nmorph-color-picker/NmorphColorPicker.vue2.js +43 -42
  7. package/dist/components/form/nmorph-date-picker/NmorphDatePicker.vue2.js +52 -40
  8. package/dist/components/form/nmorph-file-upload/NmorphFileUpload.vue.js +20 -16
  9. package/dist/components/form/nmorph-file-upload/NmorphFileUpload.vue2.js +113 -86
  10. package/dist/components/form/nmorph-form/NmorphForm.vue2.js +9 -9
  11. package/dist/components/form/nmorph-form/components/nmorph-form-item/NmorphFormItem.vue2.js +33 -24
  12. package/dist/components/form/nmorph-form/use-form-item-input.js +29 -8
  13. package/dist/components/form/nmorph-number-input/NmorphNumberInput.vue2.js +41 -35
  14. package/dist/components/form/nmorph-otp-input/NmorphOTPInput.vue2.js +65 -61
  15. package/dist/components/form/nmorph-radio/NmorphRadio.css +1 -1
  16. package/dist/components/form/nmorph-radio-group/NmorphRadioGroup.vue2.js +24 -22
  17. package/dist/components/form/nmorph-select/NmorphSelect.css +1 -1
  18. package/dist/components/form/nmorph-select/NmorphSelect.vue2.js +91 -81
  19. package/dist/components/form/nmorph-select-button/NmorphSelectButton.vue2.js +28 -26
  20. package/dist/components/form/nmorph-slider/NmorphSlider.vue2.js +49 -48
  21. package/dist/components/form/nmorph-switch/NmorphSwitch.vue2.js +37 -36
  22. package/dist/components/form/nmorph-text-input/NmorphTextInput.css +1 -1
  23. package/dist/components/form/nmorph-text-input/NmorphTextInput.vue.js +1 -1
  24. package/dist/components/form/nmorph-text-input/NmorphTextInput.vue2.js +34 -30
  25. package/dist/components/form/nmorph-textarea/NmorphTextarea.vue.js +1 -1
  26. package/dist/components/form/nmorph-textarea/NmorphTextarea.vue2.js +29 -25
  27. package/dist/components/form/nmorph-time-picker/NmorphTimePicker.vue.js +1 -1
  28. package/dist/components/form/nmorph-time-picker/NmorphTimePicker.vue2.js +69 -68
  29. package/dist/hooks/use-field-validation.js +71 -42
  30. package/dist/hooks/use-form-validation.js +62 -24
  31. package/dist/index.umd.js +26 -26
  32. package/dist/package.json.js +1 -1
  33. package/dist/src/components/basic/nmorph-button/NmorphButton.vue.d.ts +1 -1
  34. package/dist/src/components/basic/nmorph-link/NmorphLink.vue.d.ts +1 -1
  35. package/dist/src/components/data/nmorph-avatar/NmorphAvatar.vue.d.ts +1 -1
  36. package/dist/src/components/data/nmorph-badge/NmorphBadge.vue.d.ts +1 -1
  37. package/dist/src/components/data/nmorph-empty/NmorphEmpty.vue.d.ts +1 -1
  38. package/dist/src/components/data/nmorph-progress/NmorphProgress.vue.d.ts +1 -1
  39. package/dist/src/components/data/nmorph-table/NmorphTable.vue.d.ts +1 -1
  40. package/dist/src/components/feedback/nmorph-callout/NmorphCallout.vue.d.ts +1 -1
  41. package/dist/src/components/form/nmorph-checkbox-group/NmorphCheckboxGroup.vue.d.ts +2 -2
  42. package/dist/src/components/form/nmorph-date-picker/NmorphDatePicker.vue.d.ts +2 -2
  43. package/dist/src/components/form/nmorph-file-upload/NmorphFileUpload.vue.d.ts +6 -3
  44. package/dist/src/components/form/nmorph-file-upload/types.d.ts +4 -0
  45. package/dist/src/components/form/nmorph-form/types.d.ts +15 -5
  46. package/dist/src/components/form/nmorph-form/use-form-item-input.d.ts +10 -0
  47. package/dist/src/components/form/nmorph-radio-group/NmorphRadioGroup.vue.d.ts +2 -2
  48. package/dist/src/hooks/use-field-validation.d.ts +15 -0
  49. package/dist/src/hooks/use-form-validation.d.ts +5 -0
  50. package/dist/style.css +1 -1
  51. package/dist/utils/common.js +6 -7
  52. package/package.json +1 -1
@@ -1,10 +1,10 @@
1
1
  import './NmorphOTPInput.css';
2
- import { defineComponent as te, ref as b, computed as c, watch as D, nextTick as O } from "vue";
3
- import { useModifiers as ae } from "../../../utils/create-modifiers.js";
4
- import { NmorphComponentHeight as le } from "../../../types/index.js";
5
- import { useFormItemInput as ue } from "../nmorph-form/use-form-item-input.js";
6
- import oe from "../nmorph-text-input/NmorphTextInput.vue.js";
7
- const de = /* @__PURE__ */ te({
2
+ import { defineComponent as le, ref as M, computed as c, watch as O, nextTick as R } from "vue";
3
+ import { useModifiers as ue } from "../../../utils/create-modifiers.js";
4
+ import { NmorphComponentHeight as oe } from "../../../types/index.js";
5
+ import { useFormItemInput as re, useFormItemModel as ne } from "../nmorph-form/use-form-item-input.js";
6
+ import se from "../nmorph-text-input/NmorphTextInput.vue.js";
7
+ const pe = /* @__PURE__ */ le({
8
8
  __name: "NmorphOTPInput",
9
9
  props: {
10
10
  modelValue: { type: String, required: !1, default: "" },
@@ -20,128 +20,132 @@ const de = /* @__PURE__ */ te({
20
20
  tabindex: { type: Number, required: !1 }
21
21
  },
22
22
  emits: ["update:model-value", "focus", "blur", "complete"],
23
- setup(I, { expose: R, emit: j }) {
24
- const l = I, f = j, { id: V, name: w, autocomplete: q, tabindex: p } = ue(l), i = b([]), n = b([]), d = b(!1), o = b([]), u = c(() => Math.max(1, l.length)), v = (e = "") => {
23
+ setup(j, { expose: w, emit: N }) {
24
+ const l = j, f = N, { id: V, name: T, autocomplete: A, tabindex: p } = re(l), { modelValue: v, updateModelValue: F } = ne(
25
+ l,
26
+ (e) => f("update:model-value", e),
27
+ ""
28
+ ), i = M([]), n = M([]), d = M(!1), o = M([]), u = c(() => Math.max(1, l.length)), g = (e = "") => {
25
29
  const t = `${e ?? ""}`;
26
30
  return l.mode === "numeric" ? Array.from(t.replace(/\D/g, "")) : l.mode === "alphanumeric" ? Array.from(t.replace(/[^a-zA-Z0-9]/g, "")) : Array.from(t);
27
- }, A = (e = l.modelValue) => {
28
- const t = v(e).slice(0, u.value);
31
+ }, S = (e = v.value) => {
32
+ const t = g(e).slice(0, u.value);
29
33
  return Array.from({ length: u.value }, (a, s) => t[s] || "");
30
- }, g = (e, t = !1) => {
31
- if (o.value = Array.from({ length: u.value }, (s, y) => e[y] || ""), !t) return;
34
+ }, h = (e, t = !1) => {
35
+ if (o.value = Array.from({ length: u.value }, (s, b) => e[b] || ""), !t) return;
32
36
  const a = o.value.join("");
33
- f("update:model-value", a), o.value.includes("") || f("complete", a);
37
+ F(a), o.value.includes("") || f("complete", a);
34
38
  };
35
- D(
36
- [() => l.modelValue, () => l.mode, u],
39
+ O(
40
+ [v, () => l.mode, u],
37
41
  () => {
38
- const e = A(l.modelValue);
39
- (e.join("") !== o.value.join("") || e.length !== o.value.length) && g(e);
42
+ const e = S(v.value);
43
+ (e.join("") !== o.value.join("") || e.length !== o.value.length) && h(e);
40
44
  },
41
45
  { immediate: !0 }
42
46
  );
43
- const N = c(
44
- () => ae({
45
- nmorph: [le[l.height], d.value && "focused"],
47
+ const E = c(
48
+ () => ue({
49
+ nmorph: [oe[l.height], d.value && "focused"],
46
50
  "nmorph-otp-input": [l.disabled && "disabled"]
47
51
  })
48
- ), T = c(
52
+ ), B = c(
49
53
  () => Array.from({ length: u.value }, (e, t) => t === 0 ? V.value : `${V.value}-${t + 1}`)
50
- ), E = c(() => l.mode === "numeric" ? "numeric" : "text"), B = c(() => q.value || "one-time-code"), C = c(() => {
54
+ ), C = c(() => l.mode === "numeric" ? "numeric" : "text"), P = c(() => A.value || "one-time-code"), $ = c(() => {
51
55
  if (l.mode === "numeric") return "[0-9]*";
52
56
  if (l.mode === "alphanumeric") return "[A-Za-z0-9]*";
53
- }), h = (e) => {
57
+ }), y = (e) => {
54
58
  n.value[e] = i.value[e]?.inputDOMRef ?? null;
55
- }, P = (e, t) => {
56
- i.value[t] = e, O(() => {
57
- h(t);
59
+ }, x = (e, t) => {
60
+ i.value[t] = e, R(() => {
61
+ y(t);
58
62
  });
59
63
  }, _ = (e) => {
60
- h(e), i.value[e]?.select?.(), n.value[e]?.select();
64
+ y(e), i.value[e]?.select?.(), n.value[e]?.select();
61
65
  }, r = (e = 0) => {
62
- O(() => {
66
+ R(() => {
63
67
  const t = Math.min(Math.max(e, 0), u.value - 1);
64
- h(t), i.value[t]?.focus?.(), n.value[t]?.focus(), _(t);
68
+ y(t), i.value[t]?.focus?.(), n.value[t]?.focus(), _(t);
65
69
  });
66
- }, F = () => {
70
+ }, k = () => {
67
71
  i.value.forEach((e, t) => {
68
72
  e?.blur?.(), n.value[t]?.blur();
69
73
  });
70
74
  };
71
- R({
75
+ w({
72
76
  inputDOMRefs: n,
73
77
  focus: r,
74
- blur: F
78
+ blur: k
75
79
  });
76
80
  const m = (e, t = "") => {
77
81
  const a = [...o.value];
78
- a[e] = t, g(a, !0);
82
+ a[e] = t, h(a, !0);
79
83
  }, H = (e, t) => {
80
- const a = v(e).slice(0, u.value - t);
84
+ const a = g(e).slice(0, u.value - t);
81
85
  if (!a.length) {
82
86
  m(t, "");
83
87
  return;
84
88
  }
85
89
  const s = [...o.value];
86
- a.forEach((Y, ee) => {
87
- s[t + ee] = Y;
88
- }), g(s, !0);
89
- const y = t + a.length;
90
- y < u.value ? r(y) : r(u.value - 1);
91
- }, S = (e, t) => {
90
+ a.forEach((te, ae) => {
91
+ s[t + ae] = te;
92
+ }), h(s, !0);
93
+ const b = t + a.length;
94
+ b < u.value ? r(b) : r(u.value - 1);
95
+ }, z = (e, t) => {
92
96
  H(e, t);
93
- }, M = /* @__PURE__ */ new Map(), $ = (e) => {
94
- const t = M.get(e);
97
+ }, q = /* @__PURE__ */ new Map(), L = (e) => {
98
+ const t = q.get(e);
95
99
  if (t) return t;
96
100
  const a = c({
97
101
  get: () => o.value[e] || "",
98
- set: (s) => S(s, e)
102
+ set: (s) => z(s, e)
99
103
  });
100
- return M.set(e, a), a;
101
- }, k = (e) => {
104
+ return q.set(e, a), a;
105
+ }, D = (e) => {
102
106
  if (o.value[e]) {
103
107
  m(e);
104
108
  return;
105
109
  }
106
110
  e > 0 && (m(e - 1), r(e - 1));
107
- }, x = (e, t) => {
111
+ }, Z = (e, t) => {
108
112
  if (e.key === "Backspace") {
109
- k(t);
113
+ D(t);
110
114
  return;
111
115
  }
112
116
  m(t);
113
- }, L = (e) => {
117
+ }, K = (e) => {
114
118
  r(e - 1);
115
- }, Z = (e) => {
119
+ }, G = (e) => {
116
120
  r(e + 1);
117
- }, K = () => {
121
+ }, J = () => {
118
122
  r(0);
119
- }, G = () => {
123
+ }, Q = () => {
120
124
  r(u.value - 1);
121
- }, J = (e) => {
122
- e.key.length === 1 && !v(e.key).length && e.preventDefault();
123
- }, Q = (e, t) => {
125
+ }, U = (e) => {
126
+ e.key.length === 1 && !g(e.key).length && e.preventDefault();
127
+ }, W = (e, t) => {
124
128
  const a = e.clipboardData?.getData("text") || "";
125
129
  H(a, t);
126
- }, U = (e) => {
130
+ }, X = (e) => {
127
131
  d.value || (d.value = !0, f("focus")), _(e);
128
- }, W = () => {
132
+ }, Y = () => {
129
133
  setTimeout(() => {
130
134
  const e = document.activeElement;
131
135
  !n.value.some((a) => a === e) && d.value && (d.value = !1, f("blur"));
132
136
  });
133
- }, X = (e) => p.value > 0 ? p.value + e : p.value;
134
- D(
137
+ }, ee = (e) => p.value > 0 ? p.value + e : p.value;
138
+ O(
135
139
  () => l.autofocus,
136
140
  (e) => {
137
141
  e && !l.disabled && r(0);
138
142
  },
139
143
  { immediate: !0 }
140
144
  );
141
- const z = { props: l, emit: f, id: V, name: w, autocomplete: q, tabindex: p, inputRefs: i, inputDOMRefs: n, focused: d, otpValue: o, normalizedLength: u, sanitizeValue: v, normalizeOtpValue: A, syncOtpValue: g, modifiers: N, fieldIds: T, inputMode: E, resolvedAutocomplete: B, inputPattern: C, syncInputDOMRef: h, setInputRef: P, selectField: _, focusField: r, blurFields: F, updateCharAt: m, insertValue: H, inputHandler: S, fieldModels: M, getFieldModel: $, backspaceHandler: k, deleteKeyHandler: x, arrowLeftHandler: L, arrowRightHandler: Z, homeHandler: K, endHandler: G, keydownHandler: J, pasteHandler: Q, focusHandler: U, blurHandler: W, getFieldTabindex: X, NmorphTextInput: oe };
142
- return Object.defineProperty(z, "__isScriptSetup", { enumerable: !1, value: !0 }), z;
145
+ const I = { props: l, emit: f, id: V, name: T, autocomplete: A, tabindex: p, modelValue: v, updateModelValue: F, inputRefs: i, inputDOMRefs: n, focused: d, otpValue: o, normalizedLength: u, sanitizeValue: g, normalizeOtpValue: S, syncOtpValue: h, modifiers: E, fieldIds: B, inputMode: C, resolvedAutocomplete: P, inputPattern: $, syncInputDOMRef: y, setInputRef: x, selectField: _, focusField: r, blurFields: k, updateCharAt: m, insertValue: H, inputHandler: z, fieldModels: q, getFieldModel: L, backspaceHandler: D, deleteKeyHandler: Z, arrowLeftHandler: K, arrowRightHandler: G, homeHandler: J, endHandler: Q, keydownHandler: U, pasteHandler: W, focusHandler: X, blurHandler: Y, getFieldTabindex: ee, NmorphTextInput: se };
146
+ return Object.defineProperty(I, "__isScriptSetup", { enumerable: !1, value: !0 }), I;
143
147
  }
144
148
  });
145
149
  export {
146
- de as default
150
+ pe as default
147
151
  };
@@ -1 +1 @@
1
- .nmorph-radio{--size: var(--height);display:inline-flex;align-items:center;cursor:pointer}.nmorph-radio .nmorph-radio__content{position:relative;display:flex;justify-content:center;align-items:center}.nmorph-radio span{margin-top:2px}.nmorph-radio .nmorph-radio__input-wrapper{position:relative;width:var(--size);height:var(--size)}.nmorph-radio input{position:absolute;top:0;left:0;width:100%;height:100%}.nmorph-radio input:focus-visible{background:var(--nmorph-main-color);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio .nmorph-radio__fake{position:absolute;top:0;left:0;width:100%;height:100%;background:var(--nmorph-main-color);border-radius:var(--border-radius-circular);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio .nmorph-radio__fake span,.nmorph-radio .nmorph-radio__label{font-weight:400;font-size:var(--font-size-small);line-height:var(--line-height-regular)}.nmorph-radio .nmorph-radio__fake-checked{position:absolute;top:50%;left:50%;width:50%;height:50%;background:var(--nmorph-accent-color);border-radius:var(--border-radius-circular);transform:translate(-50%,-50%)}.nmorph-radio .nmorph-radio__label{margin-left:var(--indentation-02)}.nmorph-radio.nmorph-radio--button .nmorph-radio__fake{position:relative;display:flex;justify-content:center;align-items:center;height:var(--size);padding:var(--indentation-03);white-space:nowrap;background:var(--nmorph-main-color);border-radius:var(--default-border-radius);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio.nmorph--extra-thin-component .nmorph-radio__fake span,.nmorph-radio.nmorph--extra-thin-component .nmorph-radio__label{font-size:var(--font-size-tiny);line-height:var(--line-height-line)}.nmorph-radio.nmorph--extra-thin-component.nmorph-radio--button .nmorph-radio__fake{padding:var(--indentation-02)}.nmorph-radio.nmorph-radio--checked .nmorph-radio__fake{background:var(--nmorph-main-color);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio.nmorph-radio--disabled{cursor:not-allowed;opacity:.6}
1
+ .nmorph-radio{--size: var(--height);--nmorph-selection-control-font-size: var(--font-size-small);--nmorph-selection-control-line-height: var(--line-height-regular);--nmorph-selection-control-inline-padding: var(--indentation-03);display:inline-flex;align-items:center;cursor:pointer}.nmorph-radio.nmorph{height:auto;min-height:var(--size)}.nmorph-radio .nmorph-radio__content{position:relative;display:flex;justify-content:center;align-items:center;min-height:var(--size)}.nmorph-radio span{margin-top:2px}.nmorph-radio .nmorph-radio__input-wrapper{position:relative;width:var(--size);height:var(--size)}.nmorph-radio input{position:absolute;top:0;left:0;width:100%;height:100%}.nmorph-radio input:focus-visible{background:var(--nmorph-main-color);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio .nmorph-radio__fake{position:absolute;top:0;left:0;width:100%;height:100%;background:var(--nmorph-main-color);border-radius:var(--border-radius-circular);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio .nmorph-radio__fake span,.nmorph-radio .nmorph-radio__label{font-weight:400;font-size:var(--nmorph-selection-control-font-size);line-height:var(--nmorph-selection-control-line-height)}.nmorph-radio .nmorph-radio__fake-checked{position:absolute;top:50%;left:50%;width:50%;height:50%;background:var(--nmorph-accent-color);border-radius:var(--border-radius-circular);transform:translate(-50%,-50%)}.nmorph-radio .nmorph-radio__label{margin-left:var(--indentation-02)}.nmorph-radio.nmorph-radio--button .nmorph-radio__fake{position:relative;display:flex;justify-content:center;align-items:center;height:var(--size);padding:var(--nmorph-selection-control-inline-padding);white-space:nowrap;background:var(--nmorph-main-color);border-radius:var(--default-border-radius);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio.nmorph--extra-thin-component{--nmorph-selection-control-font-size: var(--font-size-tiny);--nmorph-selection-control-line-height: var(--line-height-line);--nmorph-selection-control-inline-padding: var(--indentation-02)}.nmorph-radio.nmorph--thin-component{--nmorph-selection-control-font-size: var(--font-size-extra-small)}.nmorph-radio.nmorph--basic-component{--nmorph-selection-control-font-size: var(--font-size-small)}.nmorph-radio.nmorph--thick-component{--nmorph-selection-control-font-size: var(--font-size-base)}.nmorph-radio.nmorph-radio--checked .nmorph-radio__fake{background:var(--nmorph-main-color);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-radio.nmorph-radio--disabled{cursor:not-allowed;opacity:.6}
@@ -1,11 +1,12 @@
1
1
  import './NmorphRadioGroup.css';
2
- import { defineComponent as m, ref as c, watch as h, computed as d, provide as o } from "vue";
3
- import { useModifiers as y } from "../../../utils/create-modifiers.js";
4
- import g from "../nmorph-radio/NmorphRadio.vue.js";
5
- const b = /* @__PURE__ */ m({
2
+ import { defineComponent as h, ref as y, watch as g, computed as n, provide as a } from "vue";
3
+ import { useModifiers as q } from "../../../utils/create-modifiers.js";
4
+ import { useFormItemModel as v } from "../nmorph-form/use-form-item-input.js";
5
+ import _ from "../nmorph-radio/NmorphRadio.vue.js";
6
+ const x = /* @__PURE__ */ h({
6
7
  __name: "NmorphRadioGroup",
7
8
  props: {
8
- modelValue: { type: String, required: !0, default: "" },
9
+ modelValue: { type: String, required: !1, default: "" },
9
10
  options: { type: Array, required: !1, default: () => [] },
10
11
  styleType: { type: null, required: !1, default: "button" },
11
12
  direction: { type: null, required: !1, default: "row" },
@@ -17,25 +18,26 @@ const b = /* @__PURE__ */ m({
17
18
  tabindex: { type: Number, required: !1 }
18
19
  },
19
20
  emits: ["update:model-value"],
20
- setup(n, { expose: p, emit: s }) {
21
- p();
22
- const e = n, t = c(e.modelValue);
23
- h(
24
- () => e.modelValue,
25
- (r) => {
26
- t.value = r;
27
- }
28
- );
29
- const a = s, i = (r) => {
30
- t.value = r, a("update:model-value", t.value);
31
- }, f = d(() => y({ "nmorph-radio-group": [e.styleType, e.direction] })), u = d(() => e.height);
32
- o("radio-group-selected-value", t), o("change-radio-button-value-handler", i), o("radio-group-height", u);
33
- const l = { props: e, initialValue: t, emit: a, changeHandler: i, modifiers: f, height: u, get NmorphRadio() {
34
- return g;
21
+ setup(s, { expose: m, emit: f }) {
22
+ m();
23
+ const e = s, i = f, { modelValue: o, updateModelValue: l } = v(
24
+ e,
25
+ (r) => i("update:model-value", r),
26
+ ""
27
+ ), t = y(o.value);
28
+ g(o, (r) => {
29
+ t.value = r;
30
+ });
31
+ const u = (r) => {
32
+ t.value = r, l(t.value);
33
+ }, c = n(() => q({ "nmorph-radio-group": [e.styleType, e.direction] })), d = n(() => e.height);
34
+ a("radio-group-selected-value", t), a("change-radio-button-value-handler", u), a("radio-group-height", d);
35
+ const p = { props: e, emit: i, modelValue: o, updateModelValue: l, initialValue: t, changeHandler: u, modifiers: c, height: d, get NmorphRadio() {
36
+ return _;
35
37
  } };
36
- return Object.defineProperty(l, "__isScriptSetup", { enumerable: !1, value: !0 }), l;
38
+ return Object.defineProperty(p, "__isScriptSetup", { enumerable: !1, value: !0 }), p;
37
39
  }
38
40
  });
39
41
  export {
40
- b as default
42
+ x as default
41
43
  };
@@ -1 +1 @@
1
- .nmorph-select{--base-width: 200px;width:var(--base-width);height:var(--height);cursor:pointer}.nmorph-select .nmorph-select__content{position:relative;height:100%;background:var(--nmorph-main-color);box-shadow:var(--nmorph-shadow-outset)}.nmorph-select .nmorph-select__selected-values-line{display:flex;justify-content:space-between;align-items:center;height:100%;padding:var(--indentation-00) var(--default-indentation-input);border-radius:var(--default-border-radius)}.nmorph-select .nmorph-select__selected-value{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.nmorph-select select,.nmorph-select option{position:absolute;width:0;height:0;padding:0;border:none;opacity:0}.nmorph-select.nmorph-select--loading .nmorph-select__options{display:flex;justify-content:center;padding:16px}.nmorph-select.nmorph-select--disabled{cursor:not-allowed;opacity:.6}.nmorph-select.nmorph-select--fill{width:100%}.nmorph-select.nmorph-select--options-auto-width .nmorph-select__options{width:max-content;max-width:calc(100vw - var(--indentation-02) * 2)}.nmorph-select .nmorph-select__virtual-list{overflow-y:auto}.nmorph-select .nmorph-select__virtual-spacer{position:relative}.nmorph-select .nmorph-select__virtual-content{position:absolute;top:0;right:0;left:0}.nmorph-select.nmorph-select--open .nmorph-select__chevron{transform:rotate(180deg)}.nmorph-select.nmorph-select--open .nmorph-select__content{background:var(--nmorph-main-color);box-shadow:var(--nmorph-shadow-inset)}.nmorph-select.nmorph-select--selected-line-outset .nmorph-select__content{background:var(--nmorph-main-color);box-shadow:var(--nmorph-shadow-outset)}.nmorph-select.nmorph-select--focus{outline:2px solid var(--nmorph-accent-color)}.nmorph-select.nmorph-select--focus .nmorph-select__content{box-shadow:none}
1
+ .nmorph-select{--base-width: 200px;width:var(--base-width);height:var(--height);border-radius:var(--default-border-radius);cursor:pointer}.nmorph-select .nmorph-select__content{position:relative;height:100%;background:var(--nmorph-main-color);border-radius:inherit;box-shadow:var(--nmorph-shadow-outset)}.nmorph-select .nmorph-select__selected-values-line{display:flex;justify-content:space-between;align-items:center;height:100%;padding:var(--indentation-00) var(--default-indentation-input);border-radius:inherit}.nmorph-select .nmorph-select__selected-value{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.nmorph-select select,.nmorph-select option{position:absolute;width:0;height:0;padding:0;border:none;opacity:0}.nmorph-select.nmorph-select--loading .nmorph-select__options{display:flex;justify-content:center;padding:16px}.nmorph-select.nmorph-select--disabled{cursor:not-allowed;opacity:.6}.nmorph-select.nmorph-select--fill{width:100%}.nmorph-select.nmorph-select--options-auto-width .nmorph-select__options{width:max-content;max-width:calc(100vw - var(--indentation-02) * 2)}.nmorph-select .nmorph-select__virtual-list{overflow-y:auto}.nmorph-select .nmorph-select__virtual-spacer{position:relative}.nmorph-select .nmorph-select__virtual-content{position:absolute;top:0;right:0;left:0}.nmorph-select.nmorph-select--open .nmorph-select__chevron{transform:rotate(180deg)}.nmorph-select.nmorph-select--open .nmorph-select__content{background:var(--nmorph-main-color);box-shadow:var(--nmorph-shadow-inset)}.nmorph-select.nmorph-select--selected-line-outset .nmorph-select__content{background:var(--nmorph-main-color);box-shadow:var(--nmorph-shadow-outset)}.nmorph-select.nmorph-select--focus{outline:2px solid var(--nmorph-accent-color)}.nmorph-select.nmorph-select--focus .nmorph-select__content{box-shadow:none}
@@ -1,18 +1,18 @@
1
1
  import './NmorphSelect.css';
2
- import { defineComponent as ne, computed as a, ref as d, watch as f, nextTick as B, onMounted as ue, onUnmounted as oe, provide as S, toRef as ie } from "vue";
3
- import { NmorphComponentHeight as se } from "../../../types/index.js";
4
- import { useModifiers as de } from "../../../utils/create-modifiers.js";
5
- import { toCssSize as L, getNmorphOptionHeight as ve, resolveDomElement as ce } from "../../../utils/common.js";
6
- import { useI18n as fe } from "vue-i18n";
7
- import { useFormItemInput as pe } from "../nmorph-form/use-form-item-input.js";
8
- import { useVirtualList as me } from "../../../hooks/use-virtual-list.js";
9
- import he from "../../navigation/nmorph-dropdown/NmorphDropdown.vue.js";
10
- import ge from "./components/nmorph-select-option/NmorphSelectOption.vue.js";
11
- import ye from "../../basic/nmorph-icon/NmorphIcon.vue.js";
12
- import He from "../../data/nmorph-tag-list/components/nmorph-tag-item/NmorphTagItem.vue.js";
13
- import be from "../../../assets/icons/chevron-down.svg.js";
14
- import qe from "../../../assets/icons/loader.svg.js";
15
- const Ue = /* @__PURE__ */ ne({
2
+ import { defineComponent as oe, computed as a, ref as d, watch as c, nextTick as R, onMounted as ie, onUnmounted as se, provide as w, toRef as de } from "vue";
3
+ import { NmorphComponentHeight as ve } from "../../../types/index.js";
4
+ import { useModifiers as ce } from "../../../utils/create-modifiers.js";
5
+ import { toCssSize as C, getNmorphOptionHeight as fe, resolveDomElement as pe } from "../../../utils/common.js";
6
+ import { useI18n as me } from "vue-i18n";
7
+ import { useFormItemModel as he, useFormItemInput as ge } from "../nmorph-form/use-form-item-input.js";
8
+ import { useVirtualList as ye } from "../../../hooks/use-virtual-list.js";
9
+ import He from "../../navigation/nmorph-dropdown/NmorphDropdown.vue.js";
10
+ import be from "./components/nmorph-select-option/NmorphSelectOption.vue.js";
11
+ import qe from "../../basic/nmorph-icon/NmorphIcon.vue.js";
12
+ import Ie from "../../data/nmorph-tag-list/components/nmorph-tag-item/NmorphTagItem.vue.js";
13
+ import xe from "../../../assets/icons/chevron-down.svg.js";
14
+ import Ne from "../../../assets/icons/loader.svg.js";
15
+ const je = /* @__PURE__ */ oe({
16
16
  __name: "NmorphSelect",
17
17
  props: {
18
18
  noElementPlaceholder: { type: String, required: !1, default: "" },
@@ -39,103 +39,113 @@ const Ue = /* @__PURE__ */ ne({
39
39
  tabindex: { type: Number, required: !1 }
40
40
  },
41
41
  emits: ["update:model-value"],
42
- setup(R, { expose: C, emit: P }) {
43
- C();
44
- const { t: w } = fe(), t = R, D = a(
45
- () => t.noElementPlaceholder ? t.noElementPlaceholder : w("noElementPlaceholder")
46
- ), m = P, l = d(t.modelValue), r = d(t.open), v = a(() => t.disabled || t.loading), h = a(() => t.optionsWidth === "auto"), g = d(!0), { id: y, name: T, autocomplete: W, tabindex: k } = pe(t), H = (e) => {
42
+ setup(P, { expose: T, emit: W }) {
43
+ T();
44
+ const { t: M } = me(), l = P, D = a(
45
+ () => l.noElementPlaceholder ? l.noElementPlaceholder : M("noElementPlaceholder")
46
+ ), A = W, { modelValue: p, updateModelValue: h } = he(
47
+ l,
48
+ (e) => A("update:model-value", e),
49
+ ""
50
+ ), t = d(p.value), r = d(l.open), v = a(() => l.disabled || l.loading), g = a(() => l.optionsWidth === "auto"), y = d(!0), { id: H, name: k, autocomplete: $, tabindex: F } = ge(l), b = (e) => {
47
51
  if (!v.value) {
48
- if (r.value = !1, typeof l.value == "string" && (!t.valueRequired && l.value === e ? l.value = "" : l.value = e, m("update:model-value", l.value)), Array.isArray(l.value)) {
49
- const n = l.value.includes(e), ae = l.value.length === 1 && n;
50
- if (t.valueRequired && ae) return;
51
- n ? l.value = l.value.filter((re) => re !== e) : l.value = [...l.value, e];
52
+ if (r.value = !1, typeof t.value == "string" && (!l.valueRequired && t.value === e ? t.value = "" : t.value = e, h(t.value)), Array.isArray(t.value)) {
53
+ const n = t.value.includes(e), ne = t.value.length === 1 && n;
54
+ if (l.valueRequired && ne) return;
55
+ n ? t.value = t.value.filter((ue) => ue !== e) : t.value = [...t.value, e];
52
56
  }
53
- m("update:model-value", l.value);
57
+ h(t.value);
54
58
  }
55
- }, p = d(!1), $ = () => {
56
- p.value = !0;
57
- }, U = () => {
58
- p.value = !1;
59
- }, z = a(
60
- () => de({
61
- nmorph: [se[t.height]],
59
+ }, m = d(!1), U = () => {
60
+ m.value = !0;
61
+ }, z = () => {
62
+ m.value = !1;
63
+ }, j = a(
64
+ () => ce({
65
+ nmorph: [ve[l.height]],
62
66
  "nmorph-select": [
63
- t.disabled && "disabled",
64
- t.modelValue ? "on" : "off",
65
- t.loading && "loading",
67
+ l.disabled && "disabled",
68
+ p.value ? "on" : "off",
69
+ l.loading && "loading",
66
70
  r.value && !v.value && "open",
67
- t.fill && "fill",
68
- h.value && "options-auto-width",
69
- g.value ? "selected-line-outset" : "selected-line-inset",
70
- p.value && "focus"
71
+ l.fill && "fill",
72
+ g.value && "options-auto-width",
73
+ y.value ? "selected-line-outset" : "selected-line-inset",
74
+ m.value && "focus"
71
75
  ]
72
76
  })
73
- ), F = a(() => ({
74
- ...t.width !== void 0 && { "--base-width": L(t.width) }
75
- })), j = () => {
77
+ ), G = a(() => ({
78
+ ...l.width !== void 0 && { "--base-width": C(l.width) }
79
+ })), J = () => {
76
80
  v.value || (r.value = !r.value);
77
81
  };
78
- f(
82
+ c(
79
83
  r,
80
84
  (e) => {
81
- e && (g.value = !1);
85
+ e && (y.value = !1);
82
86
  },
83
87
  { immediate: !0 }
84
88
  );
85
- const b = () => {
89
+ const q = () => {
86
90
  r.value = !1;
87
91
  };
88
- f(
89
- () => t.loading,
92
+ c(
93
+ () => l.loading,
90
94
  (e) => {
91
95
  e && (r.value = !1);
92
96
  }
97
+ ), c(
98
+ p,
99
+ (e) => {
100
+ t.value = e;
101
+ },
102
+ { deep: !0 }
93
103
  );
94
- const i = a(() => t.options.length > 0 ? t.options : t.optionsMap), q = d(null), I = d([]), x = a(() => t.options), c = a(() => t.virtual && x.value.length > 0), M = a(() => t.virtualItemHeight || ve(t.height)), A = a(() => t.virtualOverscan), E = a(() => t.virtualDynamicHeight), s = me(x, {
95
- enabled: c,
96
- itemHeight: M,
97
- overscan: A,
98
- dynamic: E
99
- }), G = a(() => s.virtualItems.value), J = s.spacerStyle, K = s.contentStyle, Q = a(() => L(t.virtualMaxHeight)), N = () => {
100
- i.value.length > 0 || !q.value || (I.value = Array.from(q.value.querySelectorAll(".nmorph-select-option")).map((e) => e.getAttribute("value")).filter((e) => !!e));
104
+ const i = a(() => l.options.length > 0 ? l.options : l.optionsMap), I = d(null), x = d([]), N = a(() => l.options), f = a(() => l.virtual && N.value.length > 0), E = a(() => l.virtualItemHeight || fe(l.height)), V = a(() => l.virtualOverscan), _ = a(() => l.virtualDynamicHeight), s = ye(N, {
105
+ enabled: f,
106
+ itemHeight: E,
107
+ overscan: V,
108
+ dynamic: _
109
+ }), K = a(() => s.virtualItems.value), Q = s.spacerStyle, X = s.contentStyle, Y = a(() => C(l.virtualMaxHeight)), O = () => {
110
+ i.value.length > 0 || !I.value || (x.value = Array.from(I.value.querySelectorAll(".nmorph-select-option")).map((e) => e.getAttribute("value")).filter((e) => !!e));
101
111
  }, o = a(
102
- () => i.value.length > 0 ? i.value.map((e) => e.value) : I.value
103
- ), X = a(() => c.value ? Array.isArray(l.value) ? l.value : l.value ? [l.value] : [] : o.value), u = d(0), O = a(() => o.value[u.value] || ""), Y = a(() => `${y.value}-listbox`), Z = (e) => `${y.value}-option-${e.replace(/\s+/g, "-")}`;
104
- f(u, (e) => {
105
- r.value && c.value && s.scrollToIndex(e);
106
- }), f(
112
+ () => i.value.length > 0 ? i.value.map((e) => e.value) : x.value
113
+ ), Z = a(() => f.value ? Array.isArray(t.value) ? t.value : t.value ? [t.value] : [] : o.value), u = d(0), S = a(() => o.value[u.value] || ""), ee = a(() => `${H.value}-listbox`), te = (e) => `${H.value}-option-${e.replace(/\s+/g, "-")}`;
114
+ c(u, (e) => {
115
+ r.value && f.value && s.scrollToIndex(e);
116
+ }), c(
107
117
  o,
108
118
  (e) => {
109
119
  u.value >= e.length && (u.value = Math.max(e.length - 1, 0));
110
120
  },
111
121
  { immediate: !0 }
112
- ), f(r, async (e) => {
122
+ ), c(r, async (e) => {
113
123
  if (e) {
114
- if (await B(), N(), typeof l.value == "string") {
115
- const n = o.value.indexOf(l.value);
124
+ if (await R(), O(), typeof t.value == "string") {
125
+ const n = o.value.indexOf(t.value);
116
126
  n !== -1 && (u.value = n);
117
127
  }
118
- s.refresh(), c.value && s.scrollToIndex(u.value);
128
+ s.refresh(), f.value && s.scrollToIndex(u.value);
119
129
  }
120
- }), ue(async () => {
121
- await B(), N(), document.addEventListener("click", b);
122
- }), oe(() => {
123
- document.removeEventListener("click", b);
130
+ }), ie(async () => {
131
+ await R(), O(), document.addEventListener("click", q);
132
+ }), se(() => {
133
+ document.removeEventListener("click", q);
124
134
  });
125
- const ee = a(() => typeof l.value == "string" ? l.value === "" ? D.value : i.value.find((e) => e.value === l.value)?.label : i.value.find((e) => e.value === l.value)?.label), te = a(() => i.value.length > 0 ? i.value.filter((n) => l.value.includes(n.value)).map((n) => ({ text: n.label, value: n.value })) : Array.isArray(l.value) ? l.value.map((n) => ({ text: n, value: n })) : [{ text: l.value, value: l.value }]);
126
- S("select-selected-value", l), S("select-change-selected-value", H), S("select-height", ie(t, "height"));
127
- const V = d(null), le = a(
128
- () => h.value ? `${V.value?.clientWidth || 0}px` : void 0
129
- ), _ = { t: w, props: t, computedNoElementPlaceholder: D, emit: m, initialValue: l, open: r, disabledInput: v, autoOptionsWidth: h, selectedLineOutset: g, id: y, name: T, autocomplete: W, tabindex: k, changeHandler: H, focus: p, focusHandler: $, blurHandler: U, modifiers: z, styles: F, clickHandler: j, closeHandler: b, optionsMap: i, optionsDOMRef: q, slotDomOptions: I, renderedOptions: x, virtualEnabled: c, virtualItemHeight: M, virtualOverscan: A, virtualDynamicHeight: E, virtualList: s, virtualOptions: G, virtualSpacerStyle: J, virtualContentStyle: K, virtualMaxHeight: Q, refreshDomOptions: N, domOptions: o, nativeOptions: X, currentIndex: u, currentFocusedEl: O, listboxId: Y, getOptionId: Z, selectedValueTitle: ee, tags: te, nmorphSelectDOMRef: V, optionsMinWidth: le, spaceHandler: () => {
135
+ const le = a(() => typeof t.value == "string" ? t.value === "" ? D.value : i.value.find((e) => e.value === t.value)?.label : i.value.find((e) => e.value === t.value)?.label), ae = a(() => i.value.length > 0 ? i.value.filter((n) => t.value.includes(n.value)).map((n) => ({ text: n.label, value: n.value })) : Array.isArray(t.value) ? t.value.map((n) => ({ text: n, value: n })) : [{ text: t.value, value: t.value }]);
136
+ w("select-selected-value", t), w("select-change-selected-value", b), w("select-height", de(l, "height"));
137
+ const B = d(null), re = a(
138
+ () => g.value ? `${B.value?.clientWidth || 0}px` : void 0
139
+ ), L = { t: M, props: l, computedNoElementPlaceholder: D, emit: A, modelValue: p, updateModelValue: h, initialValue: t, open: r, disabledInput: v, autoOptionsWidth: g, selectedLineOutset: y, id: H, name: k, autocomplete: $, tabindex: F, changeHandler: b, focus: m, focusHandler: U, blurHandler: z, modifiers: j, styles: G, clickHandler: J, closeHandler: q, optionsMap: i, optionsDOMRef: I, slotDomOptions: x, renderedOptions: N, virtualEnabled: f, virtualItemHeight: E, virtualOverscan: V, virtualDynamicHeight: _, virtualList: s, virtualOptions: K, virtualSpacerStyle: Q, virtualContentStyle: X, virtualMaxHeight: Y, refreshDomOptions: O, domOptions: o, nativeOptions: Z, currentIndex: u, currentFocusedEl: S, listboxId: ee, getOptionId: te, selectedValueTitle: le, tags: ae, nmorphSelectDOMRef: B, optionsMinWidth: re, spaceHandler: () => {
130
140
  v.value || (r.value = !r.value);
131
141
  }, arrowDownHandler: () => {
132
142
  v.value || o.value.length !== 0 && (r.value || (r.value = !0), u.value = (u.value + 1) % o.value.length);
133
143
  }, arrowUpHandler: () => {
134
144
  v.value || o.value.length !== 0 && (r.value || (r.value = !0), u.value = (u.value - 1 + o.value.length) % o.value.length);
135
145
  }, enterHandler: () => {
136
- r.value && O.value && H(O.value);
146
+ r.value && S.value && b(S.value);
137
147
  }, setVirtualOptionRef: (e, n) => {
138
- s.measureElement(n, ce(e));
148
+ s.measureElement(n, pe(e));
139
149
  }, escapeHandler: () => {
140
150
  r.value = !1;
141
151
  }, homeHandler: () => {
@@ -143,21 +153,21 @@ const Ue = /* @__PURE__ */ ne({
143
153
  }, endHandler: () => {
144
154
  u.value = Math.max(o.value.length - 1, 0);
145
155
  }, get NmorphTagItem() {
146
- return He;
156
+ return Ie;
147
157
  }, get NmorphIcon() {
148
- return ye;
158
+ return qe;
149
159
  }, get NmorphSelectOption() {
150
- return ge;
160
+ return be;
151
161
  }, get NmorphDropdown() {
152
- return he;
162
+ return He;
153
163
  }, get NmorphIconLoaderDots() {
154
- return qe;
164
+ return Ne;
155
165
  }, get NmorphIconChevronDown() {
156
- return be;
166
+ return xe;
157
167
  } };
158
- return Object.defineProperty(_, "__isScriptSetup", { enumerable: !1, value: !0 }), _;
168
+ return Object.defineProperty(L, "__isScriptSetup", { enumerable: !1, value: !0 }), L;
159
169
  }
160
170
  });
161
171
  export {
162
- Ue as default
172
+ je as default
163
173
  };
@@ -1,9 +1,10 @@
1
1
  import './NmorphSelectButton.css';
2
- import { defineComponent as c, ref as S, watch as g, computed as d, provide as o } from "vue";
3
- import { useModifiers as y } from "../../../utils/create-modifiers.js";
4
- import { toCssSize as u } from "../../../utils/common.js";
5
- import b from "./components/nmorph-select-button-item/NmorphSelectButtonItem.vue.js";
6
- const z = /* @__PURE__ */ c({
2
+ import { defineComponent as g, ref as y, watch as b, computed as u, provide as n } from "vue";
3
+ import { useModifiers as v } from "../../../utils/create-modifiers.js";
4
+ import { toCssSize as s } from "../../../utils/common.js";
5
+ import { useFormItemModel as h } from "../nmorph-form/use-form-item-input.js";
6
+ import q from "./components/nmorph-select-button-item/NmorphSelectButtonItem.vue.js";
7
+ const F = /* @__PURE__ */ g({
7
8
  __name: "NmorphSelectButton",
8
9
  props: {
9
10
  modelValue: { type: String, required: !1, default: "" },
@@ -20,33 +21,34 @@ const z = /* @__PURE__ */ c({
20
21
  tabindex: { type: Number, required: !1 }
21
22
  },
22
23
  emits: ["update:model-value"],
23
- setup(n, { expose: s, emit: m }) {
24
- s();
25
- const e = n, r = m, t = S(e.modelValue);
26
- g(
27
- () => e.modelValue,
28
- (i) => {
29
- t.value = i;
30
- }
31
- );
32
- const f = d(
33
- () => y({
24
+ setup(m, { expose: f, emit: p }) {
25
+ f();
26
+ const e = m, l = p, { modelValue: r, updateModelValue: a } = h(
27
+ e,
28
+ (t) => l("update:model-value", t),
29
+ ""
30
+ ), i = y(r.value);
31
+ b(r, (t) => {
32
+ i.value = t;
33
+ });
34
+ const c = u(
35
+ () => v({
34
36
  "nmorph-select-button": [e.disabled && "disabled", e.fill && "fill", e.height]
35
37
  })
36
- ), p = d(() => ({
37
- ...e.trackPadding !== void 0 && { "--track-padding": u(e.trackPadding) },
38
- ...e.itemSize !== void 0 && { "--item-size": u(e.itemSize) },
38
+ ), S = u(() => ({
39
+ ...e.trackPadding !== void 0 && { "--track-padding": s(e.trackPadding) },
40
+ ...e.itemSize !== void 0 && { "--item-size": s(e.itemSize) },
39
41
  ...e.itemFontSize !== void 0 && { "--item-font-size": e.itemFontSize }
40
- })), l = (i) => {
41
- e.disabled || (t.value = i, r("update:model-value", i));
42
+ })), o = (t) => {
43
+ e.disabled || (i.value = t, a(t));
42
44
  };
43
- o("select-button-selected-value", t), o("select-button-change-handler", l);
44
- const a = { props: e, emit: r, initialValue: t, modifiers: f, styles: p, changeHandler: l, get NmorphSelectButtonItem() {
45
- return b;
45
+ n("select-button-selected-value", i), n("select-button-change-handler", o);
46
+ const d = { props: e, emit: l, modelValue: r, updateModelValue: a, initialValue: i, modifiers: c, styles: S, changeHandler: o, get NmorphSelectButtonItem() {
47
+ return q;
46
48
  } };
47
- return Object.defineProperty(a, "__isScriptSetup", { enumerable: !1, value: !0 }), a;
49
+ return Object.defineProperty(d, "__isScriptSetup", { enumerable: !1, value: !0 }), d;
48
50
  }
49
51
  });
50
52
  export {
51
- z as default
53
+ F as default
52
54
  };