bitboss-ui 2.0.115 → 2.0.117
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/dist/components/BaseCheckboxGroup/BaseCheckboxGroup.vue.d.ts +31 -58
- package/dist/components/BaseColorInput/BaseColorInput.vue.d.ts +4 -0
- package/dist/components/BaseDatePickerInput/BaseDatePickerInput.vue.d.ts +17 -8
- package/dist/components/BaseNumberInput/BaseNumberInput.vue.d.ts +4 -0
- package/dist/components/BaseSelect/BaseSelect.vue.d.ts +22 -3
- package/dist/components/BaseSlider/BaseSlider.vue.d.ts +1 -1
- package/dist/components/BaseSwitchGroup/BaseSwitchGroup.vue.d.ts +8 -167
- package/dist/components/BaseTag/BaseTag.vue.d.ts +17 -3
- package/dist/components/BaseTextInput/BaseTextInput.vue.d.ts +4 -0
- package/dist/components/BaseTextarea/BaseTextarea.vue.d.ts +4 -0
- package/dist/components/BbAccordion/BbAccordion.vue.d.ts +1 -1
- package/dist/components/BbButton/BbButton.vue.d.ts +4 -4
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +4 -0
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +4 -0
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +5 -0
- package/dist/components/BbSelect/BbSelect.vue.d.ts +9 -0
- package/dist/components/BbTag/BbTag.vue.d.ts +4 -0
- package/dist/components/BbTextInput/BbTextInput.vue.d.ts +4 -0
- package/dist/components/BbTextarea/BbTextarea.vue.d.ts +4 -0
- package/dist/components/BbTooltip/BbTooltip.vue.d.ts +0 -1
- package/dist/components/ClearableButton.vue.d.ts +2 -0
- package/dist/components/CommonInputInnerContainer.vue.d.ts +9 -1
- package/dist/index100.js +9 -9
- package/dist/index101.js +41 -37
- package/dist/index111.js +11 -11
- package/dist/index113.js +6 -4
- package/dist/index115.js +17 -15
- package/dist/index117.js +14 -12
- package/dist/index119.js +2 -2
- package/dist/index121.js +59 -61
- package/dist/index123.js +1 -1
- package/dist/index125.js +1 -1
- package/dist/index127.js +1 -1
- package/dist/index128.js +1 -1
- package/dist/index129.js +1 -1
- package/dist/index13.js +2 -2
- package/dist/index133.js +2 -2
- package/dist/index15.js +38 -33
- package/dist/index17.js +3 -3
- package/dist/index19.js +8 -8
- package/dist/index207.js +58 -79
- package/dist/index209.js +13 -25
- package/dist/index21.js +12 -12
- package/dist/index210.js +19 -16
- package/dist/index211.js +4 -48
- package/dist/index212.js +13 -15
- package/dist/index213.js +3 -3
- package/dist/index214.js +126 -12
- package/dist/index215.js +5 -16
- package/dist/index216.js +125 -5
- package/dist/index217.js +2 -2
- package/dist/index218.js +2 -2
- package/dist/index219.js +3 -3
- package/dist/index220.js +2 -2
- package/dist/index221.js +2 -19
- package/dist/index222.js +2 -27
- package/dist/index223.js +41 -2
- package/dist/index224.js +5 -7
- package/dist/index225.js +11 -246
- package/dist/index226.js +5 -52
- package/dist/index227.js +2 -44
- package/dist/index228.js +369 -5
- package/dist/index229.js +80 -54
- package/dist/index23.js +111 -107
- package/dist/index231.js +25 -2
- package/dist/index232.js +17 -4
- package/dist/index233.js +51 -2
- package/dist/index234.js +15 -53
- package/dist/index235.js +5 -0
- package/dist/index236.js +12 -13
- package/dist/index237.js +15 -19
- package/dist/index238.js +2 -4
- package/dist/index239.js +4 -3
- package/dist/index240.js +2 -41
- package/dist/index241.js +19 -6
- package/dist/index242.js +27 -7
- package/dist/index243.js +6 -13
- package/dist/index244.js +250 -3
- package/dist/index245.js +49 -123
- package/dist/index246.js +44 -125
- package/dist/index247.js +5 -2
- package/dist/index248.js +60 -5
- package/dist/index249.js +3 -369
- package/dist/index25.js +7 -7
- package/dist/index250.js +7 -2
- package/dist/index251.js +2 -2
- package/dist/index252.js +2 -2
- package/dist/index253.js +2 -18
- package/dist/index254.js +17 -105
- package/dist/index255.js +108 -0
- package/dist/{index256.js → index257.js} +2 -2
- package/dist/index259.js +11 -9
- package/dist/index260.js +9 -2
- package/dist/index261.js +3 -6
- package/dist/index262.js +6 -16
- package/dist/index263.js +15 -8
- package/dist/index264.js +9 -23
- package/dist/index265.js +23 -90
- package/dist/index266.js +92 -0
- package/dist/index268.js +9 -17
- package/dist/index269.js +224 -9
- package/dist/index27.js +1 -1
- package/dist/index270.js +3 -28
- package/dist/index272.js +7 -6
- package/dist/index273.js +176 -2
- package/dist/index274.js +7 -2
- package/dist/index275.js +11 -2
- package/dist/index276.js +281 -2
- package/dist/index277.js +6 -2
- package/dist/index278.js +2 -2
- package/dist/index279.js +2 -2
- package/dist/index280.js +2 -2
- package/dist/index281.js +2 -2
- package/dist/index282.js +2 -2
- package/dist/index283.js +2 -2
- package/dist/index284.js +125 -21
- package/dist/index285.js +433 -0
- package/dist/index286.js +2 -7
- package/dist/index287.js +22 -7
- package/dist/index289.js +3 -4
- package/dist/index29.js +48 -40
- package/dist/index290.js +17 -3
- package/dist/index291.js +11 -0
- package/dist/index292.js +23 -171
- package/dist/index293.js +3 -430
- package/dist/index294.js +436 -2
- package/dist/index295.js +125 -87
- package/dist/index296.js +200 -224
- package/dist/index297.js +2 -200
- package/dist/index298.js +2 -8
- package/dist/index299.js +2 -9
- package/dist/index300.js +2 -2
- package/dist/index301.js +2 -126
- package/dist/index302.js +1 -21
- package/dist/index303.js +24 -0
- package/dist/index305.js +8 -127
- package/dist/index306.js +89 -3
- package/dist/index307.js +1 -1
- package/dist/index308.js +3 -214
- package/dist/index309.js +214 -3
- package/dist/index31.js +2 -2
- package/dist/index310.js +2 -3
- package/dist/index311.js +3 -58
- package/dist/index312.js +3 -5
- package/dist/index313.js +57 -7
- package/dist/index314.js +5 -53
- package/dist/index315.js +65 -51
- package/dist/index316.js +6 -32
- package/dist/index317.js +17 -5
- package/dist/index318.js +2 -66
- package/dist/index319.js +32 -6
- package/dist/index320.js +25 -18
- package/dist/index321.js +53 -4
- package/dist/index322.js +53 -5
- package/dist/index323.js +5 -2
- package/dist/index324.js +8 -3
- package/dist/index325.js +6 -46
- package/dist/index326.js +6 -0
- package/dist/index327.js +47 -2
- package/dist/index328.js +2 -480
- package/dist/index33.js +8 -8
- package/dist/index331.js +480 -2
- package/dist/{index329.js → index332.js} +1 -1
- package/dist/index334.js +4 -0
- package/dist/index35.js +4 -4
- package/dist/index37.js +200 -189
- package/dist/index39.js +4 -4
- package/dist/index41.js +2 -2
- package/dist/index43.js +8 -8
- package/dist/index45.js +92 -85
- package/dist/index47.js +40 -36
- package/dist/index49.js +39 -35
- package/dist/index51.js +11 -12
- package/dist/index53.js +1 -1
- package/dist/index55.js +1 -1
- package/dist/index57.js +2 -2
- package/dist/index61.js +11 -10
- package/dist/index67.js +14 -12
- package/dist/index71.js +5 -3
- package/dist/index75.js +3 -3
- package/dist/index77.js +1 -1
- package/dist/index79.js +2 -2
- package/dist/index81.js +1 -1
- package/dist/index82.js +11 -9
- package/dist/index84.js +4 -4
- package/dist/index86.js +2 -2
- package/dist/index88.js +4 -4
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/index230.js +0 -15
- package/dist/index258.js +0 -14
- package/dist/index267.js +0 -5
- package/dist/index271.js +0 -283
- package/dist/index288.js +0 -13
- package/dist/index304.js +0 -438
- /package/dist/{index330.js → index333.js} +0 -0
package/dist/index23.js
CHANGED
@@ -1,37 +1,39 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import { useFloating as ce } from "./
|
3
|
-
import
|
4
|
-
import pe from "./
|
1
|
+
import { defineComponent as oe, watchEffect as ne, ref as r, computed as v, watch as le, openBlock as D, createBlock as V, normalizeClass as $, withCtx as n, renderSlot as p, createVNode as E, unref as l, withDirectives as ie, createElementVNode as s, mergeProps as P, withModifiers as se, toDisplayString as _, normalizeStyle as ue, KeepAlive as de, createCommentVNode as A } from "vue";
|
2
|
+
import { useFloating as ce } from "./index214.js";
|
3
|
+
import o from "./index215.js";
|
4
|
+
import pe from "./index216.js";
|
5
5
|
import me from "./index217.js";
|
6
6
|
import fe from "./index218.js";
|
7
7
|
import be from "./index219.js";
|
8
8
|
import ve from "./index220.js";
|
9
|
-
import { identity as
|
10
|
-
import { last as
|
11
|
-
import { useFocusTrap as ke } from "./
|
9
|
+
import { identity as ye } from "./index221.js";
|
10
|
+
import { last as ge } from "./index222.js";
|
11
|
+
import { useFocusTrap as ke } from "./index223.js";
|
12
12
|
import { useId as he } from "./index8.js";
|
13
13
|
import { useIntersectionObserver as Me } from "./index132.js";
|
14
|
-
import { useLocale as
|
15
|
-
import { useMobile as
|
16
|
-
import { vMaska as
|
17
|
-
import { wait as
|
18
|
-
import { waitFor as
|
14
|
+
import { useLocale as De } from "./index212.js";
|
15
|
+
import { useMobile as Ve } from "./index9.js";
|
16
|
+
import { vMaska as we } from "./index210.js";
|
17
|
+
import { wait as Ce } from "./index130.js";
|
18
|
+
import { waitFor as Ye } from "./index224.js";
|
19
19
|
import Se from "./index21.js";
|
20
20
|
/* empty css */
|
21
|
-
import
|
22
|
-
import
|
21
|
+
import Be from "./index225.js";
|
22
|
+
import Ie from "./index207.js";
|
23
23
|
/* empty css */
|
24
|
-
import Oe from "./
|
25
|
-
import $e from "./
|
26
|
-
import { _config as
|
27
|
-
import {
|
28
|
-
|
24
|
+
import Oe from "./index209.js";
|
25
|
+
import $e from "./index226.js";
|
26
|
+
import { _config as Ee } from "./index4.js";
|
27
|
+
import { isEmpty as Pe } from "./index227.js";
|
28
|
+
import { autoUpdate as _e, flip as Ae, offset as Fe, shift as Le, hide as je } from "./index228.js";
|
29
|
+
const qe = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska", "disabled", "inputmode", "name", "placeholder", "readonly", "required", "value"], We = ["aria-label", "disabled"], He = ["id"], vt = /* @__PURE__ */ oe({
|
29
30
|
__name: "BaseDatePickerInput",
|
30
31
|
props: {
|
31
32
|
allowWriting: { type: [Boolean, String], default: !0 },
|
32
33
|
"append:icon": {},
|
33
34
|
autocomplete: { default: "off" },
|
34
35
|
autofocus: {},
|
36
|
+
clearable: { type: Boolean },
|
35
37
|
compact: { type: Boolean },
|
36
38
|
disabled: { type: Boolean },
|
37
39
|
firstDayOfWeek: {},
|
@@ -48,80 +50,80 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
48
50
|
readonly: { type: Boolean },
|
49
51
|
required: { type: Boolean },
|
50
52
|
selectable: {},
|
51
|
-
teleportTarget: {}
|
52
|
-
width: { default: 290 }
|
53
|
+
teleportTarget: {}
|
53
54
|
},
|
54
55
|
emits: ["active", "error", "focus", "inactive", "update:modelValue"],
|
55
|
-
setup(
|
56
|
-
const
|
57
|
-
|
58
|
-
|
56
|
+
setup(F, { emit: L }) {
|
57
|
+
const j = { it: be, en: ve };
|
58
|
+
o.extend(pe), o.extend(me), o.extend(fe), ne(() => {
|
59
|
+
o.locale(j[Ee.locale]);
|
59
60
|
});
|
60
|
-
const t =
|
61
|
-
() => t.allowWriting === "not-mobile" &&
|
62
|
-
), C =
|
61
|
+
const t = F, u = L, { t: d } = De(), c = r(null), w = r(null), m = r(null), q = r(null), y = r(null), S = r(), g = t.id || `bdpi-${he().id.value}`, { isMobile: W } = Ve(), H = v(
|
62
|
+
() => t.allowWriting === "not-mobile" && W.value ? "none" : "numeric"
|
63
|
+
), C = r(!0);
|
63
64
|
Me(
|
65
|
+
// @ts-expect-error wrong inferred type
|
64
66
|
m,
|
65
67
|
([{ intersectionRatio: e }]) => {
|
66
|
-
e === 1 ? C.value = !0 : (C.value = !1, f.value && (
|
68
|
+
e === 1 ? C.value = !0 : (C.value = !1, f.value && (O(), m.value && m.value.$el.querySelector(
|
67
69
|
".bb-base-date-picker-input__calendar-btn"
|
68
|
-
).focus(),
|
70
|
+
).focus(), M()));
|
69
71
|
},
|
70
72
|
{ threshold: [0, 1] }
|
71
73
|
);
|
72
|
-
const
|
74
|
+
const T = v(() => ({
|
73
75
|
"bb-base-date-picker-input": !0,
|
74
|
-
"bb-base-date-picker-input--active":
|
76
|
+
"bb-base-date-picker-input--active": k.value,
|
75
77
|
"bb-base-date-picker-input--errors": t.hasErrors,
|
76
78
|
"bb-base-date-picker-input--loading": t.loading,
|
77
79
|
"bb-base-date-picker-input--readonly": t.readonly,
|
78
80
|
"bb-base-date-picker-input--disabled": t.disabled,
|
79
81
|
"bb-base-date-picker-input--compact": t.compact
|
80
|
-
})),
|
82
|
+
})), R = {
|
81
83
|
onInput: (e) => {
|
82
84
|
if (!t.range && e.target instanceof HTMLInputElement)
|
83
85
|
if (y.value = e.target.value, /\d{2}\/\d{2}\/\d{4}/.test(e.target.value)) {
|
84
|
-
const a =
|
85
|
-
|
86
|
+
const a = o(e.target.value, "DD/MM/YYYY");
|
87
|
+
te(a) ? (e.target.value = "", u("update:modelValue", null), u("error", "invalid_date_typed")) : u("update:modelValue", a.toISOString());
|
86
88
|
} else e.target.value === "" && u("update:modelValue", null);
|
87
89
|
}
|
88
|
-
},
|
89
|
-
|
90
|
-
},
|
91
|
-
var a,
|
92
|
-
b.value || e.target instanceof HTMLElement && (a =
|
90
|
+
}, k = r(!1), z = () => {
|
91
|
+
k.value || (u("active"), k.value = !0, document.addEventListener("focusin", h), document.addEventListener("click", h));
|
92
|
+
}, h = (e) => {
|
93
|
+
var a, i;
|
94
|
+
b.value || e.target instanceof HTMLElement && (a = w.value) != null && a.$el && !w.value.$el.contains(e.target) && !((i = c.value) != null && i.contains(e.target)) && (k.value = !1, u("inactive"), document.removeEventListener("focusin", h), document.removeEventListener("click", h));
|
93
95
|
}, B = (e) => {
|
94
96
|
if (e)
|
95
97
|
if (Array.isArray(e)) {
|
96
|
-
let a,
|
97
|
-
return e.length && (a = e[0]), e.length > 1 && (
|
98
|
+
let a, i;
|
99
|
+
return e.length && (a = e[0]), e.length > 1 && (i = ge(e)), [a, i].filter(ye).map((re) => o(re).format("DD/MM/YYYY")).join(" - ");
|
98
100
|
} else
|
99
|
-
return
|
101
|
+
return o(e).format("DD/MM/YYYY");
|
100
102
|
return null;
|
101
|
-
},
|
103
|
+
}, N = v(() => y.value ? y.value : B(t.modelValue));
|
102
104
|
le(
|
103
105
|
() => t.modelValue,
|
104
106
|
(e) => {
|
105
107
|
y.value = B(e);
|
106
108
|
}
|
107
109
|
);
|
108
|
-
const { floatingStyles:
|
110
|
+
const { floatingStyles: U, placement: K } = ce(m, c, {
|
109
111
|
placement: "bottom",
|
110
|
-
whileElementsMounted:
|
111
|
-
middleware: [
|
112
|
-
}),
|
112
|
+
whileElementsMounted: _e,
|
113
|
+
middleware: [Ae(), Fe(5), Le({ padding: 6 }), je()]
|
114
|
+
}), Z = v(() => {
|
113
115
|
const e = {
|
114
|
-
...
|
116
|
+
...U.value
|
115
117
|
};
|
116
118
|
return c.value, e;
|
117
|
-
}), f =
|
119
|
+
}), f = r(!1), G = async () => {
|
118
120
|
f.value = !0;
|
119
|
-
},
|
121
|
+
}, M = async () => {
|
120
122
|
var e;
|
121
123
|
f.value = !1, (e = S.value) == null || e.resetStatus();
|
122
|
-
},
|
123
|
-
b.value || (
|
124
|
-
}, b =
|
124
|
+
}, I = r(!1), J = async () => {
|
125
|
+
b.value || (I.value = !0, await Ye(() => !!c.value), await G(), Q());
|
126
|
+
}, b = r(!1), { activate: Q, deactivate: O } = ke(c, {
|
125
127
|
onActivate: () => b.value = !0,
|
126
128
|
// On post activation focus on current date
|
127
129
|
onPostActivate: () => {
|
@@ -131,44 +133,45 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
131
133
|
)) == null || e.focus();
|
132
134
|
},
|
133
135
|
onPostDeactivate: async () => {
|
134
|
-
await
|
136
|
+
await Ce(200), b.value = !1;
|
135
137
|
},
|
136
138
|
/* On esc deactivate the trap, return focus and then close the modal */
|
137
|
-
escapeDeactivates: () => (
|
138
|
-
clickOutsideDeactivates: () => (
|
139
|
+
escapeDeactivates: () => (Y.value = !1, M(), !0),
|
140
|
+
clickOutsideDeactivates: () => (Y.value = !1, M(), !0),
|
139
141
|
allowOutsideClick: !0,
|
140
142
|
preventScroll: !0
|
141
|
-
}),
|
142
|
-
u("focus", e), v.value && $(), v.value = !t.allowWriting || t.allowWriting === "not-mobile" && I.value || t.range;
|
143
|
-
}, x = (e) => t.range && Array.isArray(e) && e.length === 2 || !t.range && !!e, ee = {
|
143
|
+
}), Y = r(!t.allowWriting || t.range), X = (e) => t.range && Array.isArray(e) && e.length === 2 || !t.range && !!e, x = {
|
144
144
|
"onUpdate:modelValue": (e) => {
|
145
|
-
u("update:modelValue", e),
|
145
|
+
u("update:modelValue", e), X(e) && (Y.value = !1, O({
|
146
146
|
onPostDeactivate: () => {
|
147
|
-
b.value = !1,
|
147
|
+
b.value = !1, M();
|
148
148
|
}
|
149
149
|
}));
|
150
150
|
}
|
151
|
-
},
|
151
|
+
}, ee = v(() => {
|
152
152
|
if (t.range) {
|
153
153
|
if (!t.modelValue || t.modelValue.length < 2)
|
154
154
|
return d("baseDatePickerInput.emptyRange").value;
|
155
|
-
const e =
|
155
|
+
const e = o(t.modelValue[0]).format("D MMMM YYYY"), a = o(t.modelValue[1]).format("D MMMM YYYY");
|
156
156
|
if (t.range && t.modelValue.length === 2)
|
157
157
|
return d("baseDatePickerInput.changeSelectionRange", e, a).value;
|
158
158
|
} else if (typeof t.modelValue == "string") {
|
159
|
-
const e =
|
159
|
+
const e = o(t.modelValue).format("D MMMM YYYY");
|
160
160
|
return d("baseDatePickerInput.changeSelection", e).value;
|
161
161
|
}
|
162
162
|
return d("baseDatePickerInput.emptySelection").value;
|
163
|
-
}),
|
163
|
+
}), te = (e) => {
|
164
164
|
let a = !0;
|
165
|
-
return t.min && a && (a = e.isSameOrAfter(
|
165
|
+
return t.min && a && (a = e.isSameOrAfter(o(t.min).startOf("day"))), t.max && a && (a = e.isSameOrBefore(o(t.max).startOf("day"))), typeof t.selectable == "function" && a && (a = t.selectable(e.toDate())), !a;
|
166
|
+
}, ae = () => {
|
167
|
+
let e = null;
|
168
|
+
t.range && (e = []), u("update:modelValue", e);
|
166
169
|
};
|
167
170
|
return (e, a) => (D(), V(Oe, {
|
168
171
|
ref_key: "outerContainer",
|
169
|
-
ref:
|
170
|
-
class:
|
171
|
-
onFocusin:
|
172
|
+
ref: w,
|
173
|
+
class: $(T.value),
|
174
|
+
onFocusin: z
|
172
175
|
}, {
|
173
176
|
"prepend-outer": n(() => [
|
174
177
|
p(e.$slots, "prepend-outer")
|
@@ -177,11 +180,13 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
177
180
|
p(e.$slots, "append-outer")
|
178
181
|
]),
|
179
182
|
default: n(() => [
|
180
|
-
E(
|
183
|
+
E(Ie, {
|
181
184
|
ref_key: "innerContainer",
|
182
185
|
ref: m,
|
183
186
|
"append:icon": t["append:icon"],
|
184
|
-
|
187
|
+
clearable: t.clearable && !l(Pe)(e.modelValue),
|
188
|
+
"prepend:icon": t["prepend:icon"],
|
189
|
+
"onClick:clear": ae
|
185
190
|
}, {
|
186
191
|
prepend: n(() => [
|
187
192
|
p(e.$slots, "prepend")
|
@@ -196,98 +201,97 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
196
201
|
p(e.$slots, "suffix")
|
197
202
|
]),
|
198
203
|
default: n(() => [
|
199
|
-
ie(
|
200
|
-
id:
|
204
|
+
ie(s("input", P({
|
205
|
+
id: l(g),
|
201
206
|
ref_key: "input",
|
202
|
-
ref:
|
203
|
-
"aria-describedby": `bdpi-description_${
|
207
|
+
ref: q,
|
208
|
+
"aria-describedby": `bdpi-description_${l(g)}`,
|
204
209
|
autocomplete: e.autocomplete,
|
205
210
|
autofocus: e.autofocus,
|
206
211
|
"data-maska": t.range ? "##/##/#### - ##/##/####" : "##/##/####",
|
207
212
|
disabled: e.disabled,
|
208
|
-
inputmode:
|
213
|
+
inputmode: H.value,
|
209
214
|
name: e.name,
|
210
215
|
placeholder: e.placeholder,
|
211
216
|
readonly: e.readonly || e.range || !e.allowWriting,
|
212
217
|
required: e.required
|
213
|
-
},
|
218
|
+
}, R, {
|
214
219
|
size: "1",
|
215
220
|
type: "text",
|
216
|
-
value:
|
217
|
-
|
218
|
-
|
219
|
-
[s(Ve)]
|
221
|
+
value: N.value
|
222
|
+
}), null, 16, qe), [
|
223
|
+
[l(we)]
|
220
224
|
]),
|
221
|
-
|
222
|
-
"aria-label":
|
225
|
+
s("button", {
|
226
|
+
"aria-label": ee.value,
|
223
227
|
class: "bb-base-date-picker-input__calendar-btn",
|
224
228
|
disabled: e.disabled || e.readonly || !C.value,
|
225
229
|
type: "button",
|
226
|
-
onClick: se(
|
230
|
+
onClick: se(J, ["stop"])
|
227
231
|
}, a[0] || (a[0] = [
|
228
|
-
|
232
|
+
s("svg", {
|
229
233
|
fill: "none",
|
230
234
|
viewBox: "0 0 16 16",
|
231
235
|
xmlns: "http://www.w3.org/2000/svg"
|
232
236
|
}, [
|
233
|
-
|
237
|
+
s("path", {
|
234
238
|
d: "M12.6667 2.66667H3.33333C2.59695 2.66667 2 3.26363 2 4.00001V13.3333C2 14.0697 2.59695 14.6667 3.33333 14.6667H12.6667C13.403 14.6667 14 14.0697 14 13.3333V4.00001C14 3.26363 13.403 2.66667 12.6667 2.66667Z",
|
235
239
|
stroke: "currentColor",
|
236
240
|
"stroke-linecap": "round",
|
237
241
|
"stroke-linejoin": "round"
|
238
242
|
}),
|
239
|
-
|
243
|
+
s("path", {
|
240
244
|
d: "M10.6667 1.33333V3.99999",
|
241
245
|
stroke: "currentColor",
|
242
246
|
"stroke-linecap": "round",
|
243
247
|
"stroke-linejoin": "round"
|
244
248
|
}),
|
245
|
-
|
249
|
+
s("path", {
|
246
250
|
d: "M5.33333 1.33333V3.99999",
|
247
251
|
stroke: "currentColor",
|
248
252
|
"stroke-linecap": "round",
|
249
253
|
"stroke-linejoin": "round"
|
250
254
|
}),
|
251
|
-
|
255
|
+
s("path", {
|
252
256
|
d: "M2 6.66667H14",
|
253
257
|
stroke: "currentColor",
|
254
258
|
"stroke-linecap": "round",
|
255
259
|
"stroke-linejoin": "round"
|
256
260
|
})
|
257
261
|
], -1)
|
258
|
-
]), 8,
|
259
|
-
|
260
|
-
id: `bdpi-description_${
|
262
|
+
]), 8, We),
|
263
|
+
s("span", {
|
264
|
+
id: `bdpi-description_${l(g)}`,
|
261
265
|
class: "bb-base-date-picker-input__accessible-description sr-only"
|
262
|
-
},
|
266
|
+
}, _(l(d)("baseDatePickerInput.dateFormat")) + " " + _(t.range ? l(d)("baseDatePickerInput.dateFormatRange") : l(d)("baseDatePickerInput.dateFormatSingle")), 9, He)
|
263
267
|
]),
|
264
268
|
_: 3
|
265
|
-
}, 8, ["append:icon", "prepend:icon"]),
|
266
|
-
|
269
|
+
}, 8, ["append:icon", "clearable", "prepend:icon"]),
|
270
|
+
I.value ? (D(), V(Be, {
|
267
271
|
key: 0,
|
268
272
|
target: e.teleportTarget
|
269
273
|
}, {
|
270
274
|
default: n(() => {
|
271
|
-
var
|
275
|
+
var i;
|
272
276
|
return [
|
273
|
-
|
277
|
+
s("div", {
|
274
278
|
ref_key: "calendar",
|
275
279
|
ref: c,
|
276
|
-
class:
|
280
|
+
class: $(["bb-base-date-picker-input__calendar", {
|
277
281
|
"bb-base-date-picker-input__calendar--shown": f.value
|
278
282
|
}]),
|
279
|
-
style: ue(
|
283
|
+
style: ue(Z.value)
|
280
284
|
}, [
|
281
285
|
E($e, {
|
282
|
-
direction: (
|
286
|
+
direction: (i = l(K)) != null && i.includes("top") ? "bottom" : "top",
|
283
287
|
duration: 300
|
284
288
|
}, {
|
285
289
|
default: n(() => [
|
286
290
|
(D(), V(de, null, [
|
287
|
-
f.value ? (D(), V(Se,
|
291
|
+
f.value ? (D(), V(Se, P({
|
288
292
|
key: 0,
|
289
|
-
id:
|
290
|
-
},
|
293
|
+
id: l(g)
|
294
|
+
}, x, {
|
291
295
|
ref_key: "basedatepicker",
|
292
296
|
ref: S,
|
293
297
|
disabled: e.disabled,
|
@@ -298,7 +302,7 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
298
302
|
range: e.range,
|
299
303
|
readonly: e.readonly,
|
300
304
|
selectable: e.selectable
|
301
|
-
}), null, 16, ["id", "disabled", "first-day-of-week", "max", "min", "model-value", "range", "readonly", "selectable"])) :
|
305
|
+
}), null, 16, ["id", "disabled", "first-day-of-week", "max", "min", "model-value", "range", "readonly", "selectable"])) : A("", !0)
|
302
306
|
], 1024))
|
303
307
|
]),
|
304
308
|
_: 1
|
@@ -307,12 +311,12 @@ const We = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska",
|
|
307
311
|
];
|
308
312
|
}),
|
309
313
|
_: 1
|
310
|
-
}, 8, ["target"])) :
|
314
|
+
}, 8, ["target"])) : A("", !0)
|
311
315
|
]),
|
312
316
|
_: 3
|
313
317
|
}, 8, ["class"]));
|
314
318
|
}
|
315
319
|
});
|
316
320
|
export {
|
317
|
-
|
321
|
+
vt as default
|
318
322
|
};
|
package/dist/index231.js
CHANGED
@@ -1,4 +1,27 @@
|
|
1
|
-
|
1
|
+
import { ref as n, computed as a, unref as v } from "vue";
|
2
|
+
import { useDebounceFn as f } from "./index205.js";
|
3
|
+
const p = (o) => {
|
4
|
+
const e = n(0), r = a(() => v(o.items)), t = n([]), u = async (...s) => {
|
5
|
+
if (Array.isArray(r.value))
|
6
|
+
t.value = r.value;
|
7
|
+
else if (typeof r.value == "function") {
|
8
|
+
const l = ++e.value;
|
9
|
+
try {
|
10
|
+
if (t.value = await r.value(...s), l < e.value)
|
11
|
+
return;
|
12
|
+
} catch (i) {
|
13
|
+
console.error(i);
|
14
|
+
}
|
15
|
+
e.value--;
|
16
|
+
}
|
17
|
+
}, c = f(u, o.debounce || 0);
|
18
|
+
return {
|
19
|
+
getter: u,
|
20
|
+
debouncedGetter: c,
|
21
|
+
items: t,
|
22
|
+
loading: a(() => !!e.value)
|
23
|
+
};
|
24
|
+
};
|
2
25
|
export {
|
3
|
-
|
26
|
+
p as useItemsGetter
|
4
27
|
};
|
package/dist/index232.js
CHANGED
@@ -1,6 +1,19 @@
|
|
1
|
-
import {
|
2
|
-
|
1
|
+
import { computed as i, unref as m } from "vue";
|
2
|
+
import { hash as s } from "./index235.js";
|
3
|
+
const p = ({ items: a, key: r }) => {
|
4
|
+
const n = i(() => {
|
5
|
+
const t = {}, c = new Array().concat(m(a));
|
6
|
+
for (let e = 0; e < c.length; e++) {
|
7
|
+
const o = c[e], u = r ? String(o[r]) : s(o);
|
8
|
+
t[u] = o;
|
9
|
+
}
|
10
|
+
return t;
|
11
|
+
});
|
12
|
+
return {
|
13
|
+
data: n,
|
14
|
+
get: (t) => r ? n.value[String(t[r])] : n.value[s(t)]
|
15
|
+
};
|
16
|
+
};
|
3
17
|
export {
|
4
|
-
|
5
|
-
s as when
|
18
|
+
p as useIndexById
|
6
19
|
};
|
package/dist/index233.js
CHANGED
@@ -1,4 +1,53 @@
|
|
1
|
-
|
1
|
+
import { computed as c, unref as n } from "vue";
|
2
|
+
import { useItemText as y } from "./index290.js";
|
3
|
+
import { useItemValue as x } from "./index291.js";
|
4
|
+
import { hash as w } from "./index235.js";
|
5
|
+
import { useLogger as D } from "./index243.js";
|
6
|
+
const { getItemText: O } = y(), { getItemValue: V } = x(), { warn: H } = D(), T = (i, d, t, a, f, u) => u ? !1 : d || i.disabled ? !0 : typeof t == "function" ? !t(i) : !!(typeof t == "boolean" && !t || a && f >= a), q = ({
|
7
|
+
items: i,
|
8
|
+
disabled: d,
|
9
|
+
selectable: t,
|
10
|
+
itemText: a,
|
11
|
+
itemValue: f,
|
12
|
+
selectedIndexedByHash: u,
|
13
|
+
max: b = 1 / 0
|
14
|
+
}) => {
|
15
|
+
const v = c(() => n(d)), p = c(() => n(i)), h = c(
|
16
|
+
() => Object.keys(u.value).length
|
17
|
+
), g = n(b), m = (e) => {
|
18
|
+
const r = V(e, n(f)), o = w(r), l = O(e, n(a)), s = u.value[o] !== void 0, I = T(
|
19
|
+
e,
|
20
|
+
v.value,
|
21
|
+
t,
|
22
|
+
g,
|
23
|
+
h.value,
|
24
|
+
s
|
25
|
+
);
|
26
|
+
return {
|
27
|
+
item: e,
|
28
|
+
text: l,
|
29
|
+
value: r,
|
30
|
+
valueHash: o,
|
31
|
+
selected: s,
|
32
|
+
disabled: n(I)
|
33
|
+
};
|
34
|
+
};
|
35
|
+
return {
|
36
|
+
options: c(() => {
|
37
|
+
const e = [], r = /* @__PURE__ */ new Set();
|
38
|
+
for (let o = 0; o < p.value.length; o++) {
|
39
|
+
const l = p.value[o];
|
40
|
+
l.disabled && H(
|
41
|
+
"Disabling an item by passing a disabled option to the item itself is deprecated and will be removed in a future version. Use the `disabled` prop or the `selectable` iteratee prop instead."
|
42
|
+
);
|
43
|
+
const s = m(l);
|
44
|
+
r.has(s.valueHash) || (r.add(s.valueHash), e.push(s));
|
45
|
+
}
|
46
|
+
return e;
|
47
|
+
}),
|
48
|
+
createOption: m
|
49
|
+
};
|
50
|
+
};
|
2
51
|
export {
|
3
|
-
|
52
|
+
q as useBaseOptions
|
4
53
|
};
|
package/dist/index234.js
CHANGED
@@ -1,55 +1,17 @@
|
|
1
|
-
import {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
},
|
16
|
-
setup(m) {
|
17
|
-
const u = m, o = d(), l = () => {
|
18
|
-
var n;
|
19
|
-
!o.value || u.preventFocus || (n = o.value.querySelector("input")) == null || n.focus();
|
20
|
-
};
|
21
|
-
return (n, C) => (r(), _("span", {
|
22
|
-
ref_key: "container",
|
23
|
-
ref: o,
|
24
|
-
class: "bb-common-input-inner-container",
|
25
|
-
onClick: l
|
26
|
-
}, [
|
27
|
-
e(n.$slots, "prepend", {}, () => [
|
28
|
-
t("span", y, [
|
29
|
-
e(n.$slots, "prefix")
|
30
|
-
])
|
31
|
-
]),
|
32
|
-
n.$props["prepend:icon"] ? (r(), s(p(a), {
|
33
|
-
key: 0,
|
34
|
-
class: "bb-common-input-inner-container__prepend-icon",
|
35
|
-
type: n.$props["prepend:icon"]
|
36
|
-
}, null, 8, ["type"])) : i("", !0),
|
37
|
-
e(n.$slots, "default"),
|
38
|
-
n.$props["append:icon"] ? (r(), s(p(a), {
|
39
|
-
key: 1,
|
40
|
-
class: "bb-common-input-inner-container__append-icon",
|
41
|
-
type: n.$props["append:icon"]
|
42
|
-
}, null, 8, ["type"])) : i("", !0),
|
43
|
-
c(p($)),
|
44
|
-
c(b),
|
45
|
-
e(n.$slots, "append", {}, () => [
|
46
|
-
t("span", k, [
|
47
|
-
e(n.$slots, "suffix")
|
48
|
-
])
|
49
|
-
])
|
50
|
-
], 512));
|
51
|
-
}
|
52
|
-
});
|
1
|
+
import { isNil as f } from "./index252.js";
|
2
|
+
import { computed as t, unref as o } from "vue";
|
3
|
+
const a = ({ modelValue: e, iteratee: h, multiple: u }) => {
|
4
|
+
const i = t(
|
5
|
+
() => new Array().concat(o(e))
|
6
|
+
), s = t(() => i.value.reduce(
|
7
|
+
(r, n) => (h(n) ? r.coherent.push(n) : r.incoherent.push(n), r),
|
8
|
+
{ coherent: [], incoherent: [] }
|
9
|
+
)), c = t(() => u && !o(e).length || !u && f(o(e)) ? !0 : !s.value.incoherent.length);
|
10
|
+
return {
|
11
|
+
status: s,
|
12
|
+
coherent: c
|
13
|
+
};
|
14
|
+
};
|
53
15
|
export {
|
54
|
-
|
16
|
+
a as useCoherence
|
55
17
|
};
|
package/dist/index235.js
ADDED
package/dist/index236.js
CHANGED
@@ -1,15 +1,14 @@
|
|
1
|
-
import {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
}
|
12
|
-
const i = /* @__PURE__ */ r(s, [["render", p]]);
|
1
|
+
import { hash as e } from "./index235.js";
|
2
|
+
import { debouncedWatch as s } from "./index205.js";
|
3
|
+
const n = (o, c, h) => {
|
4
|
+
s(
|
5
|
+
o,
|
6
|
+
(r, t) => {
|
7
|
+
e(r) !== e(t) && c(r, t);
|
8
|
+
},
|
9
|
+
h
|
10
|
+
);
|
11
|
+
};
|
13
12
|
export {
|
14
|
-
|
13
|
+
n as useHashedWatcher
|
15
14
|
};
|