@oub/fusion 0.2.35 → 0.2.36

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.
@@ -41,10 +41,11 @@ declare const _default: import("vue").DefineComponent<{
41
41
  }, unknown, {
42
42
  focus: boolean;
43
43
  hover: boolean;
44
+ fusionButtonEl: import("vue").Ref<HTMLButtonElement | undefined>;
44
45
  }, {
45
46
  isDisabled(): boolean;
46
47
  isLoading(): boolean;
47
- spinnerColourValue(): string;
48
+ spinnerColourValue(): string | undefined;
48
49
  variantTypeClass(): "" | "fusion-button-primary" | "fusion-button-danger";
49
50
  variantStyleClass(): "" | "fusion-button-filled" | "fusion-button-outline" | "fusion-button-ghost";
50
51
  buttonSizeClass(): "fusion-button-small" | "fusion-button-regular" | "text-label-base";
package/dist/fusion.js CHANGED
@@ -1,4 +1,4 @@
1
- import { defineComponent as Ce, useCssVars as Eo, openBlock as v, createElementBlock as k, pushScopeId as Mr, popScopeId as Lr, createElementVNode as D, resolveComponent as Pe, normalizeClass as ne, createBlock as ke, renderSlot as ie, createTextVNode as ut, toDisplayString as fe, createCommentVNode as Q, withDirectives as Qt, withKeys as ye, vModelText as Hr, createVNode as Se, resolveDynamicComponent as Ea, withCtx as Ae, vModelDynamic as Jo, getCurrentScope as Rr, onScopeDispose as qr, unref as b, toRef as ya, readonly as Xo, customRef as Yo, ref as te, watch as ct, h as Er, computed as z, Fragment as Te, renderList as Re, createSlots as tt, withScopeId as Wo, Transition as jt, vShow as ma, reactive as Da, useSlots as Gt, onMounted as it, nextTick as Lt, onUnmounted as Bn, mergeProps as $e, isRef as or, normalizeProps as je, guardReactiveProps as rt, Teleport as Ko, render as ir, withModifiers as He, normalizeStyle as mt, onBeforeUpdate as zo } from "vue";
1
+ import { defineComponent as Ce, useCssVars as Eo, openBlock as v, createElementBlock as k, pushScopeId as Mr, popScopeId as Lr, createElementVNode as D, ref as ee, resolveComponent as Pe, normalizeClass as ne, createBlock as ke, renderSlot as ie, createTextVNode as ut, toDisplayString as fe, createCommentVNode as Q, withDirectives as Qt, withKeys as ye, vModelText as Hr, createVNode as Se, resolveDynamicComponent as Ea, withCtx as Ae, vModelDynamic as Jo, getCurrentScope as Rr, onScopeDispose as qr, unref as b, toRef as ya, readonly as Xo, customRef as Yo, watch as ct, h as Er, computed as z, Fragment as Te, renderList as Re, createSlots as tt, withScopeId as Wo, Transition as jt, vShow as ma, reactive as Da, useSlots as Gt, onMounted as it, nextTick as Lt, onUnmounted as Bn, mergeProps as $e, isRef as or, normalizeProps as je, guardReactiveProps as rt, Teleport as Ko, render as ir, withModifiers as He, normalizeStyle as mt, onBeforeUpdate as zo } from "vue";
2
2
  const Fn = Ce({
3
3
  name: "FusionLoadingSpinner",
4
4
  props: {
@@ -81,7 +81,8 @@ const Xr = /* @__PURE__ */ Le(Fn, [["render", $o], ["__scopeId", "data-v-fa260d7
81
81
  data() {
82
82
  return {
83
83
  focus: !1,
84
- hover: !1
84
+ hover: !1,
85
+ fusionButtonEl: ee()
85
86
  };
86
87
  },
87
88
  computed: {
@@ -92,8 +93,10 @@ const Xr = /* @__PURE__ */ Le(Fn, [["render", $o], ["__scopeId", "data-v-fa260d7
92
93
  return this.loading;
93
94
  },
94
95
  spinnerColourValue() {
95
- const e = getComputedStyle(this.$el);
96
- return this.variantStyle === "filled" ? e.getPropertyValue("--colour-icon-body-plain-base") : e.getPropertyValue("--colour-icon-body-primary-base");
96
+ if (!this.fusionButtonEl)
97
+ return;
98
+ const e = getComputedStyle(this.fusionButtonEl);
99
+ return this.variantStyle === "filled" ? e.getPropertyValue("--colour-icon-body-plain-base") || void 0 : e.getPropertyValue("--colour-icon-body-primary-base");
97
100
  },
98
101
  variantTypeClass() {
99
102
  switch (this.variantType) {
@@ -128,6 +131,9 @@ const Xr = /* @__PURE__ */ Le(Fn, [["render", $o], ["__scopeId", "data-v-fa260d7
128
131
  }
129
132
  }
130
133
  },
134
+ mounted() {
135
+ this.fusionButtonEl = this.$refs.fusionButtonEl;
136
+ },
131
137
  methods: {
132
138
  onClick() {
133
139
  this.$emit("click");
@@ -139,6 +145,7 @@ function ni(e, t, n, r, a, o) {
139
145
  const i = Pe("FusionLoadingSpinner");
140
146
  return v(), k("button", {
141
147
  id: "fusion-btn",
148
+ ref: "fusionButtonEl",
142
149
  disabled: e.isDisabled || e.isLoading,
143
150
  class: ne(["fusion-button", [e.variantTypeClass, e.variantStyleClass, e.buttonSizeClass]]),
144
151
  "data-test": e.dataTest,
@@ -158,7 +165,7 @@ function ni(e, t, n, r, a, o) {
158
165
  ]))
159
166
  ], 42, ti);
160
167
  }
161
- const ri = /* @__PURE__ */ Le(ei, [["render", ni], ["__scopeId", "data-v-eed3cbea"]]), oi = Ce({
168
+ const ri = /* @__PURE__ */ Le(ei, [["render", ni], ["__scopeId", "data-v-3deb49da"]]), oi = Ce({
162
169
  name: "SVGExclamationTriangle"
163
170
  }), ii = {
164
171
  width: "20",
@@ -977,7 +984,7 @@ function cl(...e) {
977
984
  if (e.length !== 1)
978
985
  return ya(...e);
979
986
  const t = e[0];
980
- return typeof t == "function" ? Xo(Yo(() => ({ get: t, set: ba }))) : te(t);
987
+ return typeof t == "function" ? Xo(Yo(() => ({ get: t, set: ba }))) : ee(t);
981
988
  }
982
989
  function va(e) {
983
990
  var t;
@@ -1052,7 +1059,7 @@ const fl = /* @__PURE__ */ Ce({
1052
1059
  props: ["as", "options"],
1053
1060
  emits: ["trigger"],
1054
1061
  setup(e, { slots: t, emit: n }) {
1055
- const r = te();
1062
+ const r = ee();
1056
1063
  return pl(r, (a) => {
1057
1064
  n("trigger", a);
1058
1065
  }, e.options), () => {
@@ -1108,7 +1115,7 @@ function hl(e) {
1108
1115
  }
1109
1116
  const Oa = /* @__PURE__ */ new WeakMap();
1110
1117
  function yl(e, t = !1) {
1111
- const n = te(t);
1118
+ const n = ee(t);
1112
1119
  let r = null, a;
1113
1120
  ct(cl(e), (l) => {
1114
1121
  const u = tn(Xt(l));
@@ -1145,7 +1152,7 @@ function yl(e, t = !1) {
1145
1152
  }
1146
1153
  function bl() {
1147
1154
  let e = !1;
1148
- const t = te(!1);
1155
+ const t = ee(!1);
1149
1156
  return (n, r) => {
1150
1157
  if (t.value = r.value, e)
1151
1158
  return;
@@ -6326,9 +6333,9 @@ function kn(e, t, n, r) {
6326
6333
  }), C = pe(n);
6327
6334
  if (isNaN(C.getTime()))
6328
6335
  return /* @__PURE__ */ new Date(NaN);
6329
- var V = ao(C, Ma(C)), G = {}, ee = hr(s), O;
6336
+ var V = ao(C, Ma(C)), G = {}, te = hr(s), O;
6330
6337
  try {
6331
- for (ee.s(); !(O = ee.n()).done; ) {
6338
+ for (te.s(); !(O = te.n()).done; ) {
6332
6339
  var g = O.value;
6333
6340
  if (!g.validate(V, q))
6334
6341
  return /* @__PURE__ */ new Date(NaN);
@@ -6336,9 +6343,9 @@ function kn(e, t, n, r) {
6336
6343
  Array.isArray(se) ? (V = se[0], Ud(G, se[1])) : V = se;
6337
6344
  }
6338
6345
  } catch (ue) {
6339
- ee.e(ue);
6346
+ te.e(ue);
6340
6347
  } finally {
6341
- ee.f();
6348
+ te.f();
6342
6349
  }
6343
6350
  return V;
6344
6351
  }
@@ -7337,7 +7344,7 @@ const Fp = (e, t, n) => {
7337
7344
  1: []
7338
7345
  },
7339
7346
  monthPicker: []
7340
- }), fn = te(null), Qa = te(!1), vn = te(!1), mn = te(!1), gn = te(!1), at = te(0), Ze = te(0), Rt = () => {
7347
+ }), fn = ee(null), Qa = ee(!1), vn = ee(!1), mn = ee(!1), gn = ee(!1), at = ee(0), Ze = ee(0), Rt = () => {
7341
7348
  const e = z(() => Qa.value ? [...qe.selectionGrid, qe.actionRow].filter((f) => f.length) : vn.value ? [
7342
7349
  ...qe.timePicker[0],
7343
7350
  ...qe.timePicker[1],
@@ -7503,7 +7510,7 @@ const Fp = (e, t, n) => {
7503
7510
  getDefaultStartTime: a
7504
7511
  };
7505
7512
  }, nf = (e, t, n) => {
7506
- const r = te(), { defaultedTextInput: a, getDefaultPattern: o } = Ke(t), i = te(""), l = ya(t, "format");
7513
+ const r = ee(), { defaultedTextInput: a, getDefaultPattern: o } = Ke(t), i = ee(""), l = ya(t, "format");
7507
7514
  ct(r, () => {
7508
7515
  e("internal-model-change", r.value);
7509
7516
  }), ct(l, () => {
@@ -7636,10 +7643,10 @@ const of = ({
7636
7643
  props: i,
7637
7644
  slots: l
7638
7645
  }) => {
7639
- const u = te({}), c = te(!1), d = te({
7646
+ const u = ee({}), c = ee(!1), d = ee({
7640
7647
  top: "0",
7641
7648
  left: "0"
7642
- }), f = te(!1), m = ya(i, "teleportCenter");
7649
+ }), f = ee(!1), m = ya(i, "teleportCenter");
7643
7650
  ct(m, () => {
7644
7651
  d.value = JSON.parse(JSON.stringify({})), P();
7645
7652
  });
@@ -7743,7 +7750,7 @@ const of = ({
7743
7750
  s.setAttribute("id", "dp--temp-container");
7744
7751
  const V = (E = r.value) != null && E.clientWidth ? r.value : document.body;
7745
7752
  V.append(s);
7746
- const G = U(C), ee = Er(
7753
+ const G = U(C), te = Er(
7747
7754
  h,
7748
7755
  {
7749
7756
  ...B,
@@ -7754,7 +7761,7 @@ const of = ({
7754
7761
  Object.keys(l).filter((O) => ["right-sidebar", "left-sidebar"].includes(O)).map((O) => [O, l[O]])
7755
7762
  )
7756
7763
  );
7757
- ir(ee, s), u.value = (p = ee.el) == null ? void 0 : p.getBoundingClientRect(), ir(null, s), V.removeChild(s);
7764
+ ir(te, s), u.value = (p = te.el) == null ? void 0 : p.getBoundingClientRect(), ir(null, s), V.removeChild(s);
7758
7765
  }
7759
7766
  };
7760
7767
  }, It = [
@@ -7813,7 +7820,7 @@ const of = ({
7813
7820
  const t = z(() => (r) => e.value ? r ? e.value.open : e.value.close : ""), n = z(() => (r) => e.value ? r ? e.value.menuAppearTop : e.value.menuAppearBottom : "");
7814
7821
  return { transitionName: t, showTransition: !!e.value, menuTransition: n };
7815
7822
  }, xa = (e, t) => {
7816
- const n = J(yt(/* @__PURE__ */ new Date(), e.timezone)), r = te([{ month: Oe(n), year: De(n) }]), a = Da({
7823
+ const n = J(yt(/* @__PURE__ */ new Date(), e.timezone)), r = ee([{ month: Oe(n), year: De(n) }]), a = Da({
7817
7824
  hours: e.range ? [ht(n), ht(n)] : ht(n),
7818
7825
  minutes: e.range ? [Dt(n), Dt(n)] : Dt(n),
7819
7826
  seconds: e.range ? [0, 0] : 0
@@ -7835,7 +7842,7 @@ const of = ({
7835
7842
  year: l
7836
7843
  };
7837
7844
  }, uf = (e, t) => {
7838
- const { defaultedMultiCalendars: n, defaultedHighlight: r } = Ke(t), { isDisabled: a, matchDate: o } = Zt(t), i = te(null), l = te(J(yt(/* @__PURE__ */ new Date(), t.timezone))), u = (p) => {
7845
+ const { defaultedMultiCalendars: n, defaultedHighlight: r } = Ke(t), { isDisabled: a, matchDate: o } = Zt(t), i = ee(null), l = ee(J(yt(/* @__PURE__ */ new Date(), t.timezone))), u = (p) => {
7839
7846
  !p.current && t.hideOffsetDates || (i.value = p.value);
7840
7847
  }, c = () => {
7841
7848
  i.value = null;
@@ -8028,7 +8035,7 @@ const of = ({
8028
8035
  const e = z(() => (r, a) => r == null ? void 0 : r.includes(a)), t = z(() => (r, a) => r.count ? r.solo ? !0 : a === 0 : !0), n = z(() => (r, a) => r.count ? r.solo ? !0 : a === r.count - 1 : !0);
8029
8036
  return { hideNavigationButtons: e, showLeftIcon: t, showRightIcon: n };
8030
8037
  }, df = (e, t, n) => {
8031
- const r = te(0), a = Da({
8038
+ const r = ee(0), a = Da({
8032
8039
  [Wt.timePicker]: !e.enableTimePicker || e.timePicker || e.monthPicker,
8033
8040
  [Wt.calendar]: !1,
8034
8041
  [Wt.header]: !1
@@ -8228,7 +8235,7 @@ const of = ({
8228
8235
  defaultedConfig: u,
8229
8236
  getDefaultPattern: c,
8230
8237
  getDefaultStartTime: d
8231
- } = Ke(a), { checkMinMaxRange: f } = Zt(a), m = te(), A = te(null), S = te(!1), L = te(!1), W = z(
8238
+ } = Ke(a), { checkMinMaxRange: f } = Zt(a), m = ee(), A = ee(null), S = ee(!1), L = ee(!1), W = z(
8232
8239
  () => ({
8233
8240
  dp__pointer: !a.disabled && !a.readonly && !o.value.enabled,
8234
8241
  dp__disabled: a.disabled,
@@ -8392,7 +8399,7 @@ const of = ({
8392
8399
  defaultedTextInput: l,
8393
8400
  defaultedInline: u,
8394
8401
  getDefaultPattern: c
8395
- } = Ke(r), { isValidTime: d } = Zt(r), { buildMatrix: f } = Rt(), m = te(null), A = te(null);
8402
+ } = Ke(r), { isValidTime: d } = Zt(r), { buildMatrix: f } = Rt(), m = ee(null), A = ee(null);
8396
8403
  it(() => {
8397
8404
  r.arrowNavigation && f([ze(m), ze(A)], "actionRow");
8398
8405
  });
@@ -8525,7 +8532,7 @@ const of = ({
8525
8532
  setup(e, { expose: t, emit: n }) {
8526
8533
  const { setSelectionGrid: r, buildMultiLevelMatrix: a, setMonthPicker: o } = Rt(), i = n, l = e, { defaultedAriaLabels: u, defaultedTextInput: c, defaultedConfig: d } = Ke(
8527
8534
  l
8528
- ), { hideNavigationButtons: f } = Xa(), m = te(!1), A = te(null), S = te(null), L = te([]), W = te(), F = te(null), I = te(0), Y = te(null);
8535
+ ), { hideNavigationButtons: f } = Xa(), m = ee(!1), A = ee(null), S = ee(null), L = ee([]), W = ee(), F = ee(null), I = ee(0), Y = ee(null);
8529
8536
  zo(() => {
8530
8537
  A.value = null;
8531
8538
  }), it(() => {
@@ -8623,31 +8630,31 @@ const of = ({
8623
8630
  class: ne(["dp__overlay_row", { dp__flex_row: p.items.length >= 3 }]),
8624
8631
  role: "row"
8625
8632
  }, [
8626
- (v(!0), k(Te, null, Re(V, (ee, O) => (v(), k("div", {
8627
- key: ee.value,
8633
+ (v(!0), k(Te, null, Re(V, (te, O) => (v(), k("div", {
8634
+ key: te.value,
8628
8635
  ref_for: !0,
8629
- ref: (g) => h(g, ee, G, O),
8636
+ ref: (g) => h(g, te, G, O),
8630
8637
  role: "gridcell",
8631
8638
  class: ne(ce.value),
8632
- "aria-selected": ee.active,
8633
- "aria-disabled": ee.disabled || void 0,
8639
+ "aria-selected": te.active,
8640
+ "aria-disabled": te.disabled || void 0,
8634
8641
  tabindex: "0",
8635
- onClick: (g) => q(ee),
8642
+ onClick: (g) => q(te),
8636
8643
  onKeydown: [
8637
- ye(He((g) => q(ee), ["prevent"]), ["enter"]),
8638
- ye(He((g) => q(ee), ["prevent"]), ["space"])
8644
+ ye(He((g) => q(te), ["prevent"]), ["enter"]),
8645
+ ye(He((g) => q(te), ["prevent"]), ["space"])
8639
8646
  ],
8640
- onMouseover: (g) => E(ee.value)
8647
+ onMouseover: (g) => E(te.value)
8641
8648
  }, [
8642
8649
  D("div", {
8643
- class: ne(ee.className)
8650
+ class: ne(te.className)
8644
8651
  }, [
8645
8652
  p.$slots.item ? ie(p.$slots, "item", {
8646
8653
  key: 0,
8647
- item: ee
8654
+ item: te
8648
8655
  }) : Q("", !0),
8649
8656
  p.$slots.item ? Q("", !0) : (v(), k(Te, { key: 1 }, [
8650
- ut(fe(ee.text), 1)
8657
+ ut(fe(te.text), 1)
8651
8658
  ], 64))
8652
8659
  ], 2)
8653
8660
  ], 42, kf))), 128))
@@ -8715,7 +8722,7 @@ const of = ({
8715
8722
  },
8716
8723
  emits: ["activate", "set-ref"],
8717
8724
  setup(e, { emit: t }) {
8718
- const n = t, r = te(null);
8725
+ const n = t, r = ee(null);
8719
8726
  return it(() => n("set-ref", r)), (a, o) => (v(), k("button", {
8720
8727
  ref_key: "elRef",
8721
8728
  ref: r,
@@ -8866,7 +8873,7 @@ const of = ({
8866
8873
  month: i,
8867
8874
  emit: l
8868
8875
  }) => {
8869
- const u = z(() => er(a.yearRange, a.reverseYears)), c = te([!1]), d = z(() => (P, H) => {
8876
+ const u = z(() => er(a.yearRange, a.reverseYears)), c = ee([!1]), d = z(() => (P, H) => {
8870
8877
  const R = Ee(vt(/* @__PURE__ */ new Date()), {
8871
8878
  month: i.value(P),
8872
8879
  year: o.value(P)
@@ -8919,7 +8926,7 @@ const of = ({
8919
8926
  handleYear: I
8920
8927
  };
8921
8928
  }, Pf = (e, t) => {
8922
- const { defaultedMultiCalendars: n, defaultedAriaLabels: r, defaultedTransitions: a, defaultedConfig: o, defaultedHighlight: i } = Ke(e), { modelValue: l, year: u, month: c, calendars: d } = xa(e, t), f = z(() => Do(e.formatLocale, e.locale, e.monthNameFormat)), m = te(null), {
8929
+ const { defaultedMultiCalendars: n, defaultedAriaLabels: r, defaultedTransitions: a, defaultedConfig: o, defaultedHighlight: i } = Ke(e), { modelValue: l, year: u, month: c, calendars: d } = xa(e, t), f = z(() => Do(e.formatLocale, e.locale, e.monthNameFormat)), m = ee(null), {
8923
8930
  selectYear: A,
8924
8931
  groupedYears: S,
8925
8932
  showYearPicker: L,
@@ -9101,7 +9108,7 @@ const of = ({
9101
9108
  }, 8, ["multi-calendars"]));
9102
9109
  }
9103
9110
  }), xf = (e, t) => {
9104
- const { modelValue: n } = xa(e, t), r = te(null), { defaultedHighlight: a } = Ke(e), o = te();
9111
+ const { modelValue: n } = xa(e, t), r = ee(null), { defaultedHighlight: a } = Ke(e), o = ee();
9105
9112
  it(() => {
9106
9113
  e.startDate && (n.value && e.focusStartDate || !n.value) && (o.value = De(J(e.startDate)));
9107
9114
  });
@@ -9205,7 +9212,7 @@ const of = ({
9205
9212
  hours: !1,
9206
9213
  minutes: !1,
9207
9214
  seconds: !1
9208
- }), S = te("AM"), L = te(null), W = te([]);
9215
+ }), S = ee("AM"), L = ee(null), W = ee([]);
9209
9216
  it(() => {
9210
9217
  r("mounted");
9211
9218
  });
@@ -9267,7 +9274,7 @@ const of = ({
9267
9274
  S.value === "PM" ? (S.value = "AM", r("update:hours", a.hours - 12)) : (S.value = "PM", r("update:hours", a.hours + 12)), r("am-pm-change", S.value);
9268
9275
  }, G = (g) => {
9269
9276
  A[g] = !0;
9270
- }, ee = (g, se, ue) => {
9277
+ }, te = (g, se, ue) => {
9271
9278
  if (g && a.arrowNavigation) {
9272
9279
  Array.isArray(W.value[se]) ? W.value[se][ue] = g : W.value[se] = [g];
9273
9280
  const X = W.value.reduce(
@@ -9291,7 +9298,7 @@ const of = ({
9291
9298
  ], 64)) : (v(), k(Te, { key: 1 }, [
9292
9299
  D("button", {
9293
9300
  ref_for: !0,
9294
- ref: (we) => ee(we, ve, 0),
9301
+ ref: (we) => te(we, ve, 0),
9295
9302
  type: "button",
9296
9303
  class: ne({
9297
9304
  dp__btn: !0,
@@ -9318,7 +9325,7 @@ const of = ({
9318
9325
  ], 42, Of),
9319
9326
  D("button", {
9320
9327
  ref_for: !0,
9321
- ref: (we) => ee(we, ve, 1),
9328
+ ref: (we) => te(we, ve, 1),
9322
9329
  type: "button",
9323
9330
  "aria-label": (N = b(l)) == null ? void 0 : N.openTpOverlay(X.type),
9324
9331
  class: ne({
@@ -9347,7 +9354,7 @@ const of = ({
9347
9354
  ], 42, Qf),
9348
9355
  D("button", {
9349
9356
  ref_for: !0,
9350
- ref: (we) => ee(we, ve, 2),
9357
+ ref: (we) => te(we, ve, 2),
9351
9358
  type: "button",
9352
9359
  class: ne({
9353
9360
  dp__btn: !0,
@@ -9466,11 +9473,11 @@ const of = ({
9466
9473
  "am-pm-change"
9467
9474
  ],
9468
9475
  setup(e, { expose: t, emit: n }) {
9469
- const r = n, a = e, { buildMatrix: o, setTimePicker: i } = Rt(), l = Gt(), { defaultedTransitions: u, defaultedAriaLabels: c, defaultedTextInput: d, defaultedConfig: f } = Ke(a), { transitionName: m, showTransition: A } = Ta(u), { hideNavigationButtons: S } = Xa(), L = te(null), W = te(null), F = te([]), I = te(null);
9476
+ const r = n, a = e, { buildMatrix: o, setTimePicker: i } = Rt(), l = Gt(), { defaultedTransitions: u, defaultedAriaLabels: c, defaultedTextInput: d, defaultedConfig: f } = Ke(a), { transitionName: m, showTransition: A } = Ta(u), { hideNavigationButtons: S } = Xa(), L = ee(null), W = ee(null), F = ee([]), I = ee(null);
9470
9477
  it(() => {
9471
9478
  r("mount"), !a.timePicker && a.arrowNavigation ? o([ze(L.value)], "time") : i(!0, a.timePicker);
9472
9479
  });
9473
- const Y = z(() => a.range && a.modelAuto ? Po(a.internalModelValue) : !0), P = te(!1), H = (h) => ({
9480
+ const Y = z(() => a.range && a.modelAuto ? Po(a.internalModelValue) : !0), P = ee(!1), H = (h) => ({
9474
9481
  hours: Array.isArray(a.hours) ? a.hours[h] : a.hours,
9475
9482
  minutes: Array.isArray(a.minutes) ? a.minutes[h] : a.minutes,
9476
9483
  seconds: Array.isArray(a.seconds) ? a.seconds[h] : a.seconds
@@ -9794,7 +9801,7 @@ const of = ({
9794
9801
  defaultedFilters: u,
9795
9802
  defaultedConfig: c,
9796
9803
  defaultedHighlight: d
9797
- } = Ke(a), { transitionName: f, showTransition: m } = Ta(o), { buildMatrix: A } = Rt(), { handleMonthYearChange: S, isDisabled: L, updateMonthYear: W } = rf(a, r), { showLeftIcon: F, showRightIcon: I } = Xa(), Y = te(!1), P = te(!1), H = te([null, null, null, null]);
9804
+ } = Ke(a), { transitionName: f, showTransition: m } = Ta(o), { buildMatrix: A } = Rt(), { handleMonthYearChange: S, isDisabled: L, updateMonthYear: W } = rf(a, r), { showLeftIcon: F, showRightIcon: I } = Xa(), Y = ee(!1), P = ee(!1), H = ee([null, null, null, null]);
9798
9805
  it(() => {
9799
9806
  r("mount");
9800
9807
  });
@@ -9863,7 +9870,7 @@ const of = ({
9863
9870
  toggleYearPicker: h,
9864
9871
  handleMonthYearChange: S
9865
9872
  }), (s, C) => {
9866
- var V, G, ee;
9873
+ var V, G, te;
9867
9874
  return v(), k("div", Kf, [
9868
9875
  s.$slots["month-year"] ? ie(s.$slots, "month-year", je($e({ key: 0 }, { month: e.month, year: e.year, months: e.months, years: e.years, updateMonthYear: b(W), handleMonthYearChange: b(S), instance: e.instance }))) : (v(), k(Te, { key: 1 }, [
9869
9876
  b(F)(b(l), e.instance) && !s.vertical ? (v(), ke(ha, {
@@ -9983,7 +9990,7 @@ const of = ({
9983
9990
  key: 2,
9984
9991
  ref: "rightIcon",
9985
9992
  disabled: b(L)(!0),
9986
- "aria-label": (ee = b(i)) == null ? void 0 : ee.nextMonth,
9993
+ "aria-label": (te = b(i)) == null ? void 0 : te.nextMonth,
9987
9994
  onActivate: C[3] || (C[3] = (O) => b(S)(!0, !0)),
9988
9995
  onSetRef: C[4] || (C[4] = (O) => T(O, s.disableYearSelect ? 2 : 3))
9989
9996
  }, {
@@ -10037,11 +10044,11 @@ const of = ({
10037
10044
  defaultedAriaLabels: u,
10038
10045
  defaultedMultiCalendars: c,
10039
10046
  defaultedWeekNumbers: d
10040
- } = Ke(a), f = te(null), m = te({
10047
+ } = Ke(a), f = ee(null), m = ee({
10041
10048
  bottom: "",
10042
10049
  left: "",
10043
10050
  transform: ""
10044
- }), A = te([]), S = te(null), L = te(!0), W = te(""), F = te({ startX: 0, endX: 0, startY: 0, endY: 0 }), I = te([]), Y = te({ left: "50%" }), P = z(() => a.calendar ? a.calendar(a.mappedDates) : a.mappedDates), H = z(() => a.dayNames ? Array.isArray(a.dayNames) ? a.dayNames : a.dayNames(a.locale, +a.weekStart) : Fp(a.formatLocale, a.locale, +a.weekStart));
10051
+ }), A = ee([]), S = ee(null), L = ee(!0), W = ee(""), F = ee({ startX: 0, endX: 0, startY: 0, endY: 0 }), I = ee([]), Y = ee({ left: "50%" }), P = z(() => a.calendar ? a.calendar(a.mappedDates) : a.mappedDates), H = z(() => a.dayNames ? Array.isArray(a.dayNames) ? a.dayNames : a.dayNames(a.locale, +a.weekStart) : Fp(a.formatLocale, a.locale, +a.weekStart));
10045
10052
  it(() => {
10046
10053
  r("mount", { cmp: "calendar", refs: A }), l.value.noSwipe || S.value && (S.value.addEventListener("touchstart", h, { passive: !1 }), S.value.addEventListener("touchend", B, { passive: !1 }), S.value.addEventListener("touchmove", T, { passive: !1 })), a.monthChangeOnScroll && S.value && S.value.addEventListener("wheel", s, { passive: !1 });
10047
10054
  });
@@ -10104,7 +10111,7 @@ const of = ({
10104
10111
  return d.value.hideOnOffsetDates ? O.some((se) => se.current) ? C(g) : "" : C(g);
10105
10112
  }, G = (O, g) => {
10106
10113
  Nt(O, l.value), r("select-date", g);
10107
- }, ee = (O) => {
10114
+ }, te = (O) => {
10108
10115
  Nt(O, l.value);
10109
10116
  };
10110
10117
  return t({ triggerTransition: M }), (O, g) => {
@@ -10214,7 +10221,7 @@ const of = ({
10214
10221
  (ae = de.marker) != null && ae.tooltip ? (v(), k("div", {
10215
10222
  key: 0,
10216
10223
  class: "dp__tooltip_content",
10217
- onClick: ee
10224
+ onClick: te
10218
10225
  }, [
10219
10226
  (v(!0), k(Te, null, Re(de.marker.tooltip, (Ne, lt) => (v(), k("div", {
10220
10227
  key: lt,
@@ -10254,7 +10261,7 @@ const of = ({
10254
10261
  };
10255
10262
  }
10256
10263
  }), Vr = (e) => Array.isArray(e), o0 = (e, t, n, r) => {
10257
- const a = te([]), { modelValue: o, calendars: i, time: l } = xa(e, t), { defaultedMultiCalendars: u, defaultedStartTime: c } = Ke(e), { validateMonthYearInRange: d, isDisabled: f, isDateRangeAllowed: m, checkMinMaxRange: A } = Zt(e), { updateTimeValues: S, getSetDateTime: L, setTime: W, assignStartTime: F, validateTime: I, disabledTimesConfig: Y } = Ro(e, l, o, r), P = z(
10264
+ const a = ee([]), { modelValue: o, calendars: i, time: l } = xa(e, t), { defaultedMultiCalendars: u, defaultedStartTime: c } = Ke(e), { validateMonthYearInRange: d, isDisabled: f, isDateRangeAllowed: m, checkMinMaxRange: A } = Zt(e), { updateTimeValues: S, getSetDateTime: L, setTime: W, assignStartTime: F, validateTime: I, disabledTimesConfig: Y } = Ro(e, l, o, r), P = z(
10258
10265
  () => (w) => i.value[w] ? i.value[w].month : 0
10259
10266
  ), H = z(
10260
10267
  () => (w) => i.value[w] ? i.value[w].year : 0
@@ -10340,7 +10347,7 @@ const of = ({
10340
10347
  e.monthChangeOnArrows && e.vertical === ge && G(w, K);
10341
10348
  }, G = (w, K) => {
10342
10349
  T(w === "right" ? -1 : 1, K);
10343
- }, ee = (w) => e.markers.find(
10350
+ }, te = (w) => e.markers.find(
10344
10351
  (K) => Qe(Rp(w.value), yt(J(K.date), e.timezone))
10345
10352
  ), O = (w, K) => {
10346
10353
  switch (e.sixWeeks === !0 ? "append" : e.sixWeeks) {
@@ -10469,7 +10476,7 @@ const of = ({
10469
10476
  disabledTimesConfig: Y,
10470
10477
  validateTime: I,
10471
10478
  getCalendarDays: ue,
10472
- getMarker: ee,
10479
+ getMarker: te,
10473
10480
  handleScroll: C,
10474
10481
  handleSwipe: G,
10475
10482
  handleArrow: V,
@@ -10528,7 +10535,7 @@ const of = ({
10528
10535
  presetDate: Y,
10529
10536
  selectCurrentDate: P,
10530
10537
  updateTime: H
10531
- } = o0(a, r, p, s), R = Gt(), { setHoverDate: M, getDayClassData: ce, clearHoverDate: j } = uf(u, a), { defaultedMultiCalendars: y } = Ke(a), x = te([]), q = te([]), $ = te(null), U = st(R, "calendar"), h = st(R, "monthYear"), B = st(R, "timePicker"), T = (V) => {
10538
+ } = o0(a, r, p, s), R = Gt(), { setHoverDate: M, getDayClassData: ce, clearHoverDate: j } = uf(u, a), { defaultedMultiCalendars: y } = Ke(a), x = ee([]), q = ee([]), $ = ee(null), U = st(R, "calendar"), h = st(R, "monthYear"), B = st(R, "timePicker"), T = (V) => {
10532
10539
  a.shadow || r("mount", V);
10533
10540
  };
10534
10541
  ct(
@@ -10542,11 +10549,11 @@ const of = ({
10542
10549
  );
10543
10550
  const E = z(() => (V) => m(i.value(V), l.value(V)).map((G) => ({
10544
10551
  ...G,
10545
- days: G.days.map((ee) => (ee.marker = A(ee), ee.classData = ce(ee), ee))
10552
+ days: G.days.map((te) => (te.marker = A(te), te.classData = ce(te), te))
10546
10553
  })));
10547
10554
  function p(V) {
10548
10555
  var G;
10549
- V || V === 0 ? (G = q.value[V]) == null || G.triggerTransition(i.value(V), l.value(V)) : q.value.forEach((ee, O) => ee.triggerTransition(i.value(O), l.value(O)));
10556
+ V || V === 0 ? (G = q.value[V]) == null || G.triggerTransition(i.value(V), l.value(V)) : q.value.forEach((te, O) => te.triggerTransition(i.value(O), l.value(O)));
10550
10557
  }
10551
10558
  function s() {
10552
10559
  r("update-flow-step");
@@ -10558,17 +10565,17 @@ const of = ({
10558
10565
  clearHoverDate: j,
10559
10566
  presetDate: Y,
10560
10567
  selectCurrentDate: P,
10561
- toggleMonthPicker: (V, G, ee = 0) => {
10568
+ toggleMonthPicker: (V, G, te = 0) => {
10562
10569
  var O;
10563
- (O = x.value[ee]) == null || O.toggleMonthPicker(V, G);
10570
+ (O = x.value[te]) == null || O.toggleMonthPicker(V, G);
10564
10571
  },
10565
- toggleYearPicker: (V, G, ee = 0) => {
10572
+ toggleYearPicker: (V, G, te = 0) => {
10566
10573
  var O;
10567
- (O = x.value[ee]) == null || O.toggleYearPicker(V, G);
10574
+ (O = x.value[te]) == null || O.toggleYearPicker(V, G);
10568
10575
  },
10569
- toggleTimePicker: (V, G, ee) => {
10576
+ toggleTimePicker: (V, G, te) => {
10570
10577
  var O;
10571
- (O = $.value) == null || O.toggleTimePicker(V, G, ee);
10578
+ (O = $.value) == null || O.toggleTimePicker(V, G, te);
10572
10579
  },
10573
10580
  handleArrow: S,
10574
10581
  updateMonthYear: I,
@@ -10586,7 +10593,7 @@ const of = ({
10586
10593
  Se(Wa, {
10587
10594
  "multi-calendars": b(y).count
10588
10595
  }, {
10589
- default: Ae(({ instance: ee, index: O }) => [
10596
+ default: Ae(({ instance: te, index: O }) => [
10590
10597
  V.disableMonthYearSelect ? Q("", !0) : (v(), ke(jf, $e({
10591
10598
  key: 0,
10592
10599
  ref: (g) => {
@@ -10594,13 +10601,13 @@ const of = ({
10594
10601
  },
10595
10602
  months: b(Do)(V.formatLocale, V.locale, V.monthNameFormat),
10596
10603
  years: b(er)(V.yearRange, V.reverseYears),
10597
- month: b(i)(ee),
10598
- year: b(l)(ee),
10599
- instance: ee
10604
+ month: b(i)(te),
10605
+ year: b(l)(te),
10606
+ instance: te
10600
10607
  }, V.$props, {
10601
10608
  onMount: G[0] || (G[0] = (g) => T(b(Wt).header)),
10602
10609
  onResetFlow: G[1] || (G[1] = (g) => V.$emit("reset-flow")),
10603
- onUpdateMonthYear: (g) => b(I)(ee, g),
10610
+ onUpdateMonthYear: (g) => b(I)(te, g),
10604
10611
  onOverlayClosed: G[2] || (G[2] = (g) => V.$emit("focus-menu"))
10605
10612
  }), tt({ _: 2 }, [
10606
10613
  Re(b(h), (g, se) => ({
@@ -10614,16 +10621,16 @@ const of = ({
10614
10621
  ref: (g) => {
10615
10622
  g && (q.value[O] = g);
10616
10623
  },
10617
- "mapped-dates": E.value(ee),
10618
- month: b(i)(ee),
10619
- year: b(l)(ee),
10620
- instance: ee
10624
+ "mapped-dates": E.value(te),
10625
+ month: b(i)(te),
10626
+ year: b(l)(te),
10627
+ instance: te
10621
10628
  }, V.$props, {
10622
- onSelectDate: (g) => b(F)(g, ee !== 1),
10623
- onHandleSpace: (g) => C(g, ee !== 1),
10629
+ onSelectDate: (g) => b(F)(g, te !== 1),
10630
+ onHandleSpace: (g) => C(g, te !== 1),
10624
10631
  onSetHoverDate: G[3] || (G[3] = (g) => b(M)(g)),
10625
- onHandleScroll: (g) => b(L)(g, ee),
10626
- onHandleSwipe: (g) => b(W)(g, ee),
10632
+ onHandleScroll: (g) => b(L)(g, te),
10633
+ onHandleSwipe: (g) => b(W)(g, te),
10627
10634
  onMount: G[4] || (G[4] = (g) => T(b(Wt).calendar)),
10628
10635
  onResetFlow: G[5] || (G[5] = (g) => V.$emit("reset-flow")),
10629
10636
  onTooltipOpen: G[6] || (G[6] = (g) => V.$emit("tooltip-open", g)),
@@ -10651,19 +10658,19 @@ const of = ({
10651
10658
  "internal-model-value": V.internalModelValue,
10652
10659
  "disabled-times-config": b(d),
10653
10660
  "validate-time": b(f),
10654
- onMount: G[8] || (G[8] = (ee) => T(b(Wt).timePicker)),
10655
- "onUpdate:hours": G[9] || (G[9] = (ee) => b(H)(ee)),
10656
- "onUpdate:minutes": G[10] || (G[10] = (ee) => b(H)(ee, !1)),
10657
- "onUpdate:seconds": G[11] || (G[11] = (ee) => b(H)(ee, !1, !0)),
10658
- onResetFlow: G[12] || (G[12] = (ee) => V.$emit("reset-flow")),
10659
- onOverlayClosed: G[13] || (G[13] = (ee) => V.$emit("time-picker-close")),
10660
- onOverlayOpened: G[14] || (G[14] = (ee) => V.$emit("time-picker-open", ee)),
10661
- onAmPmChange: G[15] || (G[15] = (ee) => V.$emit("am-pm-change", ee))
10661
+ onMount: G[8] || (G[8] = (te) => T(b(Wt).timePicker)),
10662
+ "onUpdate:hours": G[9] || (G[9] = (te) => b(H)(te)),
10663
+ "onUpdate:minutes": G[10] || (G[10] = (te) => b(H)(te, !1)),
10664
+ "onUpdate:seconds": G[11] || (G[11] = (te) => b(H)(te, !1, !0)),
10665
+ onResetFlow: G[12] || (G[12] = (te) => V.$emit("reset-flow")),
10666
+ onOverlayClosed: G[13] || (G[13] = (te) => V.$emit("time-picker-close")),
10667
+ onOverlayOpened: G[14] || (G[14] = (te) => V.$emit("time-picker-open", te)),
10668
+ onAmPmChange: G[15] || (G[15] = (te) => V.$emit("am-pm-change", te))
10662
10669
  }), tt({ _: 2 }, [
10663
- Re(b(B), (ee, O) => ({
10664
- name: ee,
10670
+ Re(b(B), (te, O) => ({
10671
+ name: te,
10665
10672
  fn: Ae((g) => [
10666
- ie(V.$slots, ee, je(rt(g)))
10673
+ ie(V.$slots, te, je(rt(g)))
10667
10674
  ])
10668
10675
  }))
10669
10676
  ]), 1040, ["hours", "minutes", "seconds", "internal-model-value", "disabled-times-config", "validate-time"]))
@@ -10671,7 +10678,7 @@ const of = ({
10671
10678
  ], 64));
10672
10679
  }
10673
10680
  }), s0 = (e, t) => {
10674
- const n = te(), { defaultedMultiCalendars: r, defaultedConfig: a, defaultedHighlight: o } = Ke(e), { modelValue: i, year: l, month: u, calendars: c } = xa(e, t), { isDisabled: d } = Zt(e), { selectYear: f, groupedYears: m, showYearPicker: A, isDisabled: S, toggleYearPicker: L, handleYearSelect: W, handleYear: F } = Lo({
10681
+ const n = ee(), { defaultedMultiCalendars: r, defaultedConfig: a, defaultedHighlight: o } = Ke(e), { modelValue: i, year: l, month: u, calendars: c } = xa(e, t), { isDisabled: d } = Zt(e), { selectYear: f, groupedYears: m, showYearPicker: A, isDisabled: S, toggleYearPicker: L, handleYearSelect: W, handleYear: F } = Lo({
10675
10682
  modelValue: i,
10676
10683
  multiCalendars: r,
10677
10684
  highlight: o,
@@ -10886,7 +10893,7 @@ const of = ({
10886
10893
  flowStep: ce.value,
10887
10894
  noOverlayFocus: a.noOverlayFocus
10888
10895
  };
10889
- }), { setMenuFocused: i, setShiftKey: l, control: u } = Vo(), c = Gt(), { defaultedTextInput: d, defaultedInline: f, defaultedConfig: m } = Ke(a), A = te(null), S = te(0), L = te(null), W = te(null), F = te(!1), I = te(null);
10896
+ }), { setMenuFocused: i, setShiftKey: l, control: u } = Vo(), c = Gt(), { defaultedTextInput: d, defaultedInline: f, defaultedConfig: m } = Ke(a), A = ee(null), S = ee(0), L = ee(null), W = ee(null), F = ee(!1), I = ee(null);
10890
10897
  it(() => {
10891
10898
  if (!a.shadow) {
10892
10899
  F.value = !0, Y(), window.addEventListener("resize", Y);
@@ -10938,7 +10945,7 @@ const of = ({
10938
10945
  return P();
10939
10946
  } else
10940
10947
  N === "left" || N === "up" ? ue("handleArrow", "left", 0, N === "up") : ue("handleArrow", "right", 0, N === "down");
10941
- }, ee = (N) => {
10948
+ }, te = (N) => {
10942
10949
  l(N.shiftKey), !a.disableMonthYearSelect && N.code === "Tab" && N.target.classList.contains("dp__menu") && u.value.shiftKeyInMenu && (N.preventDefault(), Nt(N, m.value, !0), r("close-picker"));
10943
10950
  }, O = () => {
10944
10951
  $(), r("time-picker-close");
@@ -10980,7 +10987,7 @@ const of = ({
10980
10987
  _[19] || (_[19] = ye(He((ae) => G("up"), ["prevent"]), ["up"])),
10981
10988
  _[20] || (_[20] = ye(He((ae) => G("down"), ["prevent"]), ["down"])),
10982
10989
  _[21] || (_[21] = ye(He((ae) => G("right"), ["prevent"]), ["right"])),
10983
- ee
10990
+ te
10984
10991
  ]
10985
10992
  }, [
10986
10993
  (N.disabled || N.readonly) && b(f).enabled ? (v(), k("div", {
@@ -11150,7 +11157,7 @@ const of = ({
11150
11157
  "invalid-date"
11151
11158
  ],
11152
11159
  setup(e, { expose: t, emit: n }) {
11153
- const r = n, a = e, o = Gt(), i = te(!1), l = ya(a, "modelValue"), u = ya(a, "timezone"), c = te(null), d = te(null), f = te(null), m = te(!1), A = te(null), S = te(!1), { setMenuFocused: L, setShiftKey: W } = Vo(), { clearArrowNav: F } = Rt(), { mapDatesArrToMap: I, validateDate: Y, isValidTime: P } = Zt(a), { defaultedTransitions: H, defaultedTextInput: R, defaultedInline: M, defaultedConfig: ce } = Ke(a), { menuTransition: j, showTransition: y } = Ta(H);
11160
+ const r = n, a = e, o = Gt(), i = ee(!1), l = ya(a, "modelValue"), u = ya(a, "timezone"), c = ee(null), d = ee(null), f = ee(null), m = ee(!1), A = ee(null), S = ee(!1), { setMenuFocused: L, setShiftKey: W } = Vo(), { clearArrowNav: F } = Rt(), { mapDatesArrToMap: I, validateDate: Y, isValidTime: P } = Zt(a), { defaultedTransitions: H, defaultedTextInput: R, defaultedInline: M, defaultedConfig: ce } = Ke(a), { menuTransition: j, showTransition: y } = Ta(H);
11154
11161
  it(() => {
11155
11162
  V(a.modelValue), Lt().then(() => {
11156
11163
  M.value.enabled || (E(A.value).addEventListener("scroll", ve), window.addEventListener("resize", de));
@@ -11186,7 +11193,7 @@ const of = ({
11186
11193
  internalModelValue: C,
11187
11194
  parseExternalModelValue: V,
11188
11195
  emitModelValue: G,
11189
- formatInputValue: ee,
11196
+ formatInputValue: te,
11190
11197
  checkBeforeEmit: O
11191
11198
  } = nf(r, a, m), g = z(
11192
11199
  () => ({
@@ -11237,7 +11244,7 @@ const of = ({
11237
11244
  }, Fa = () => i.value ? dt() : _(), Ga = (Z) => {
11238
11245
  C.value = Z;
11239
11246
  }, Za = () => {
11240
- R.value.enabled && (m.value = !0, ee()), r("focus");
11247
+ R.value.enabled && (m.value = !0, te()), r("focus");
11241
11248
  }, _a = () => {
11242
11249
  if (R.value.enabled && (m.value = !1, V(a.modelValue), S.value)) {
11243
11250
  const Z = Mp(A.value);
@@ -11261,7 +11268,7 @@ const of = ({
11261
11268
  clearValue: we,
11262
11269
  openMenu: _,
11263
11270
  onScroll: ve,
11264
- formatInputValue: ee,
11271
+ formatInputValue: te,
11265
11272
  // exposed for testing purposes
11266
11273
  updateInternalModelValue: Ga,
11267
11274
  // modify internal modelValue