bitboss-ui 2.1.10 → 2.1.12
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/BaseDatePickerInput/BaseDatePickerInput.vue.d.ts +2 -2
- package/dist/index.css +1 -1
- package/dist/index106.js +7 -7
- package/dist/index111.js +1 -1
- package/dist/index113.js +1 -1
- package/dist/index121.js +9 -9
- package/dist/index13.js +1 -1
- package/dist/index131.js +4 -4
- package/dist/index137.js +2 -2
- package/dist/index138.js +1 -1
- package/dist/index15.js +8 -8
- package/dist/index17.js +3 -3
- package/dist/index19.js +8 -8
- package/dist/index206.js +138 -2
- package/dist/index208.js +2 -138
- package/dist/index209.js +5 -3
- package/dist/index21.js +16 -16
- package/dist/index210.js +5 -2
- package/dist/index211.js +5 -2
- package/dist/index212.js +5 -18
- package/dist/index213.js +5 -12
- package/dist/index214.js +5 -51
- package/dist/index215.js +2 -15
- package/dist/index216.js +2 -12
- package/dist/index217.js +2 -17
- package/dist/index218.js +13 -29
- package/dist/index219.js +11 -13
- package/dist/index220.js +19 -15
- package/dist/index221.js +65 -5
- package/dist/index223.js +13 -106
- package/dist/index224.js +115 -0
- package/dist/index226.js +5 -0
- package/dist/index227.js +2 -66
- package/dist/{index222.js → index228.js} +1 -1
- package/dist/index229.js +2 -13
- package/dist/index23.js +155 -153
- package/dist/index230.js +83 -110
- package/dist/index232.js +28 -229
- package/dist/index233.js +17 -2
- package/dist/index234.js +51 -2
- package/dist/index235.js +15 -2
- package/dist/index236.js +3 -7
- package/dist/index237.js +12 -7
- package/dist/index238.js +16 -5
- package/dist/index239.js +2 -5
- package/dist/index240.js +2 -5
- package/dist/index241.js +7 -5
- package/dist/index242.js +7 -5
- package/dist/index243.js +106 -5
- package/dist/index245.js +100 -11
- package/dist/index247.js +4 -2
- package/dist/index248.js +197 -5
- package/dist/index25.js +3 -3
- package/dist/index250.js +32 -6
- package/dist/index251.js +180 -247
- package/dist/index252.js +16 -50
- package/dist/index253.js +12 -44
- package/dist/index254.js +6 -5
- package/dist/index255.js +224 -54
- package/dist/index256.js +12 -85
- package/dist/index257.js +7 -0
- package/dist/index258.js +5 -34
- package/dist/index259.js +8 -4
- package/dist/index260.js +239 -186
- package/dist/index261.js +54 -0
- package/dist/index262.js +44 -3
- package/dist/index263.js +5 -13
- package/dist/index264.js +59 -182
- package/dist/index267.js +9 -3
- package/dist/index268.js +23 -9
- package/dist/index269.js +10 -23
- package/dist/index27.js +1 -1
- package/dist/index270.js +3 -9
- package/dist/index271.js +3 -10
- package/dist/index272.js +9 -3
- package/dist/index273.js +1 -1
- package/dist/index277.js +1 -1
- package/dist/index278.js +1 -1
- package/dist/index279.js +1 -1
- package/dist/index280.js +280 -3
- package/dist/index281.js +2 -3
- package/dist/index282.js +125 -3
- package/dist/index283.js +4 -0
- package/dist/index284.js +15 -7
- package/dist/index285.js +2 -17
- package/dist/index286.js +15 -27
- package/dist/index287.js +2 -4
- package/dist/index288.js +16 -3
- package/dist/index289.js +2 -2
- package/dist/index29.js +3 -3
- package/dist/index290.js +19 -7
- package/dist/index291.js +2 -11
- package/dist/index292.js +3 -4
- package/dist/index294.js +7 -2
- package/dist/index295.js +3 -16
- package/dist/index296.js +7 -2
- package/dist/index297.js +10 -15
- package/dist/index298.js +5 -2
- package/dist/index299.js +4 -19
- package/dist/index300.js +6 -2
- package/dist/index301.js +3 -14
- package/dist/index302.js +3 -2
- package/dist/index303.js +17 -19
- package/dist/index304.js +28 -2
- package/dist/index305.js +3 -27
- package/dist/index306.js +3 -2
- package/dist/index307.js +3 -2
- package/dist/index308.js +1 -1
- package/dist/index309.js +1 -1
- package/dist/index31.js +2 -2
- package/dist/index310.js +19 -2
- package/dist/index311.js +2 -22
- package/dist/index312.js +29 -0
- package/dist/index313.js +2 -2
- package/dist/index314.js +2 -3
- package/dist/index315.js +2 -6
- package/dist/index316.js +2 -125
- package/dist/index317.js +2 -2
- package/dist/index318.js +22 -3
- package/dist/index323.js +2 -2
- package/dist/index324.js +2 -33
- package/dist/index325.js +33 -28
- package/dist/index326.js +30 -0
- package/dist/index328.js +227 -6
- package/dist/index329.js +57 -18
- package/dist/index33.js +8 -8
- package/dist/index330.js +58 -47
- package/dist/index331.js +128 -6
- package/dist/index332.js +353 -113
- package/dist/index333.js +44 -366
- package/dist/index334.js +7 -227
- package/dist/index335.js +5 -7
- package/dist/index336.js +8 -6
- package/dist/index337.js +7 -8
- package/dist/index338.js +17 -91
- package/dist/index339.js +7 -58
- package/dist/index340.js +92 -57
- package/dist/index342.js +1 -1
- package/dist/index343.js +124 -483
- package/dist/index344.js +483 -45
- package/dist/index345.js +427 -120
- package/dist/index346.js +113 -422
- package/dist/index347.js +48 -125
- package/dist/index35.js +4 -4
- package/dist/index37.js +20 -20
- package/dist/index39.js +7 -7
- package/dist/index41.js +2 -2
- package/dist/index43.js +8 -8
- package/dist/index45.js +8 -8
- package/dist/index47.js +2 -2
- package/dist/index49.js +3 -3
- package/dist/index53.js +1 -1
- package/dist/index55.js +1 -1
- package/dist/index57.js +2 -2
- package/dist/index61.js +3 -3
- package/dist/index67.js +1 -1
- package/dist/index79.js +4 -4
- package/dist/index81.js +1 -1
- package/dist/index85.js +1 -1
- package/dist/index87.js +1 -1
- package/dist/index90.js +3 -3
- package/dist/index92.js +2 -2
- package/dist/index94.js +3 -3
- package/package.json +1 -1
- package/dist/index225.js +0 -102
- package/dist/index244.js +0 -4
- package/dist/index246.js +0 -22
- package/dist/index249.js +0 -7
- package/dist/index293.js +0 -282
- package/dist/index319.js +0 -7
- package/dist/index327.js +0 -4
package/dist/index23.js
CHANGED
@@ -1,27 +1,27 @@
|
|
1
|
-
import { defineComponent as K, watchEffect as Q, ref as
|
1
|
+
import { defineComponent as K, watchEffect as Q, ref as i, computed as g, watch as D, createBlock as C, openBlock as Y, normalizeClass as w, withCtx as s, createElementVNode as n, createVNode as B, createCommentVNode as X, unref as r, withDirectives as x, mergeProps as S, withModifiers as ee, toDisplayString as E, renderSlot as c } from "vue";
|
2
2
|
import { _config as te } from "./index4.js";
|
3
|
-
import o from "./
|
4
|
-
import ae from "./
|
5
|
-
import oe from "./
|
6
|
-
import ne from "./
|
7
|
-
import re from "./
|
8
|
-
import le from "./
|
9
|
-
import { identity as ie } from "./
|
10
|
-
import { isEmpty as se } from "./
|
11
|
-
import { last as de } from "./
|
3
|
+
import o from "./index209.js";
|
4
|
+
import ae from "./index210.js";
|
5
|
+
import oe from "./index211.js";
|
6
|
+
import ne from "./index212.js";
|
7
|
+
import re from "./index213.js";
|
8
|
+
import le from "./index214.js";
|
9
|
+
import { identity as ie } from "./index215.js";
|
10
|
+
import { isEmpty as se } from "./index216.js";
|
11
|
+
import { last as de } from "./index217.js";
|
12
12
|
import { useId as ue } from "./index8.js";
|
13
|
-
import { useLocale as pe } from "./
|
13
|
+
import { useLocale as pe } from "./index218.js";
|
14
14
|
import { useMobile as ce } from "./index9.js";
|
15
|
-
import { useUntil as me } from "./
|
16
|
-
import { vMaska as fe } from "./
|
15
|
+
import { useUntil as me } from "./index219.js";
|
16
|
+
import { vMaska as fe } from "./index220.js";
|
17
17
|
import be from "./index21.js";
|
18
18
|
/* empty css */
|
19
|
-
import ke from "./
|
19
|
+
import ke from "./index221.js";
|
20
20
|
/* empty css */
|
21
|
-
import ge from "./
|
22
|
-
import ye from "./
|
21
|
+
import ge from "./index223.js";
|
22
|
+
import ye from "./index224.js";
|
23
23
|
/* empty css */
|
24
|
-
const ve =
|
24
|
+
const ve = { class: "bb-base-date-picker-input__inner-wrapper" }, Ve = ["id", "aria-describedby", "autocomplete", "autofocus", "data-maska", "disabled", "inputmode", "name", "placeholder", "readonly", "required", "value"], he = ["aria-label", "disabled"], Me = ["id"], De = ["inert"], Ze = /* @__PURE__ */ K({
|
25
25
|
__name: "BaseDatePickerInput",
|
26
26
|
props: {
|
27
27
|
allowWriting: { type: [Boolean, String], default: !0 },
|
@@ -47,12 +47,12 @@ const ve = ["inert"], Ve = ["id", "aria-describedby", "autocomplete", "autofocus
|
|
47
47
|
selectable: {}
|
48
48
|
},
|
49
49
|
emits: ["active", "error", "focus", "inactive", "update:modelValue"],
|
50
|
-
setup(I, { emit:
|
51
|
-
const
|
50
|
+
setup(I, { emit: _ }) {
|
51
|
+
const $ = { it: le, en: oe };
|
52
52
|
o.extend(ae), o.extend(ne), o.extend(re), Q(() => {
|
53
|
-
o.locale(
|
53
|
+
o.locale($[te.locale]);
|
54
54
|
});
|
55
|
-
const t = I, d =
|
55
|
+
const t = I, d = _, { t: u } = pe(), v = i(null), y = i(null), L = i(null), O = i(null), m = i(null), V = i(), f = t.id || `bdpi-${ue().id.value}`, { isMobile: P } = ce(), F = g(
|
56
56
|
() => t.allowWriting === "not-mobile" && P.value ? "none" : "numeric"
|
57
57
|
), j = g(() => ({
|
58
58
|
"bb-base-date-picker-input": !0,
|
@@ -70,12 +70,12 @@ const ve = ["inert"], Ve = ["id", "aria-describedby", "autocomplete", "autofocus
|
|
70
70
|
Z(a) ? (e.target.value = "", d("update:modelValue", null), d("error", "invalid_date_typed")) : d("update:modelValue", a.toISOString());
|
71
71
|
} else e.target.value === "" && d("update:modelValue", null);
|
72
72
|
}
|
73
|
-
}, b =
|
73
|
+
}, b = i(!1), H = () => {
|
74
74
|
b.value || (d("active"), b.value = !0, document.addEventListener("focusin", k), document.addEventListener("click", k));
|
75
75
|
}, k = (e) => {
|
76
76
|
var a, p;
|
77
77
|
e.target instanceof HTMLElement && (a = y.value) != null && a.$el && !y.value.$el.contains(e.target) && !((p = v.value) != null && p.contains(e.target)) && (b.value = !1, d("inactive"), document.removeEventListener("focusin", k), document.removeEventListener("click", k));
|
78
|
-
},
|
78
|
+
}, h = (e) => {
|
79
79
|
if (e)
|
80
80
|
if (Array.isArray(e)) {
|
81
81
|
let a, p;
|
@@ -83,26 +83,26 @@ const ve = ["inert"], Ve = ["id", "aria-describedby", "autocomplete", "autofocus
|
|
83
83
|
} else
|
84
84
|
return o(e).format("DD/MM/YYYY");
|
85
85
|
return null;
|
86
|
-
}, W = g(() => m.value ? m.value :
|
86
|
+
}, W = g(() => m.value ? m.value : h(t.modelValue));
|
87
87
|
D(
|
88
88
|
() => t.modelValue,
|
89
89
|
(e) => {
|
90
|
-
m.value =
|
90
|
+
m.value = h(e);
|
91
91
|
}
|
92
92
|
);
|
93
|
-
const
|
93
|
+
const l = i(!1), q = me(l), M = (e) => {
|
94
94
|
const a = e.target;
|
95
|
-
a && a instanceof HTMLDialogElement && (
|
95
|
+
a && a instanceof HTMLDialogElement && (l.value = !1);
|
96
96
|
}, R = async () => {
|
97
|
-
t.disabled || t.readonly || (
|
97
|
+
t.disabled || t.readonly || (l.value = !0);
|
98
98
|
};
|
99
|
-
D(
|
99
|
+
D(l, (e) => {
|
100
100
|
var a;
|
101
|
-
e ? document.addEventListener("click",
|
101
|
+
e ? document.addEventListener("click", M, { passive: !0 }) : ((a = V.value) == null || a.resetStatus(), document.removeEventListener("click", M));
|
102
102
|
});
|
103
|
-
const N =
|
103
|
+
const N = i(!t.allowWriting || t.range), T = (e) => t.range && Array.isArray(e) && e.length === 2 || !t.range && !!e, U = {
|
104
104
|
"onUpdate:modelValue": (e) => {
|
105
|
-
d("update:modelValue", e), T(e) && (N.value = !1,
|
105
|
+
d("update:modelValue", e), T(e) && (N.value = !1, l.value = !1);
|
106
106
|
}
|
107
107
|
}, z = g(() => {
|
108
108
|
if (t.range) {
|
@@ -129,138 +129,140 @@ const ve = ["inert"], Ve = ["id", "aria-describedby", "autocomplete", "autofocus
|
|
129
129
|
class: w(j.value),
|
130
130
|
onFocusin: H
|
131
131
|
}, {
|
132
|
-
"prepend-outer":
|
132
|
+
"prepend-outer": s(() => [
|
133
133
|
c(e.$slots, "prepend-outer")
|
134
134
|
]),
|
135
|
-
"append-outer":
|
135
|
+
"append-outer": s(() => [
|
136
136
|
c(e.$slots, "append-outer")
|
137
137
|
]),
|
138
|
-
default:
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
"first-day-of-week": e.firstDayOfWeek,
|
182
|
-
max: e.max,
|
183
|
-
min: e.min,
|
184
|
-
"model-value": e.modelValue,
|
185
|
-
range: e.range,
|
186
|
-
readonly: e.readonly,
|
187
|
-
selectable: e.selectable
|
188
|
-
}), null, 16, ["id", "disabled", "first-day-of-week", "max", "min", "model-value", "range", "readonly", "selectable"])
|
189
|
-
], 10, ve)
|
138
|
+
default: s(() => [
|
139
|
+
n("div", ve, [
|
140
|
+
B(ke, {
|
141
|
+
ref_key: "innerContainer",
|
142
|
+
ref: L,
|
143
|
+
"append:icon": t["append:icon"],
|
144
|
+
clearable: t.clearable && !r(se)(e.modelValue),
|
145
|
+
"prepend:icon": t["prepend:icon"],
|
146
|
+
"onClick:clear": G
|
147
|
+
}, {
|
148
|
+
prepend: s(() => [
|
149
|
+
c(e.$slots, "prepend")
|
150
|
+
]),
|
151
|
+
prefix: s(() => [
|
152
|
+
c(e.$slots, "prefix")
|
153
|
+
]),
|
154
|
+
append: s(() => [
|
155
|
+
c(e.$slots, "append")
|
156
|
+
]),
|
157
|
+
suffix: s(() => [
|
158
|
+
c(e.$slots, "suffix")
|
159
|
+
]),
|
160
|
+
default: s(() => [
|
161
|
+
x(n("input", S({
|
162
|
+
id: r(f),
|
163
|
+
ref_key: "input",
|
164
|
+
ref: O,
|
165
|
+
"aria-describedby": `bdpi-description_${r(f)}`,
|
166
|
+
autocomplete: e.autocomplete,
|
167
|
+
autofocus: e.autofocus,
|
168
|
+
"data-maska": t.range ? "##/##/#### - ##/##/####" : "##/##/####",
|
169
|
+
disabled: e.disabled,
|
170
|
+
inputmode: F.value,
|
171
|
+
name: e.name,
|
172
|
+
placeholder: e.placeholder,
|
173
|
+
readonly: e.readonly || e.range || !e.allowWriting,
|
174
|
+
required: e.required
|
175
|
+
}, A, {
|
176
|
+
size: "1",
|
177
|
+
type: "text",
|
178
|
+
value: W.value
|
179
|
+
}), null, 16, Ve), [
|
180
|
+
[r(fe)]
|
190
181
|
]),
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
182
|
+
n("button", {
|
183
|
+
"aria-label": z.value,
|
184
|
+
class: "bb-base-date-picker-input__calendar-btn",
|
185
|
+
disabled: e.disabled || e.readonly,
|
186
|
+
type: "button",
|
187
|
+
onClick: ee(R, ["stop"])
|
188
|
+
}, a[1] || (a[1] = [
|
189
|
+
n("svg", {
|
190
|
+
fill: "none",
|
191
|
+
viewBox: "0 0 16 16",
|
192
|
+
xmlns: "http://www.w3.org/2000/svg"
|
193
|
+
}, [
|
194
|
+
n("path", {
|
195
|
+
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",
|
196
|
+
stroke: "currentColor",
|
197
|
+
"stroke-linecap": "round",
|
198
|
+
"stroke-linejoin": "round"
|
199
|
+
}),
|
200
|
+
n("path", {
|
201
|
+
d: "M10.6667 1.33333V3.99999",
|
202
|
+
stroke: "currentColor",
|
203
|
+
"stroke-linecap": "round",
|
204
|
+
"stroke-linejoin": "round"
|
205
|
+
}),
|
206
|
+
n("path", {
|
207
|
+
d: "M5.33333 1.33333V3.99999",
|
208
|
+
stroke: "currentColor",
|
209
|
+
"stroke-linecap": "round",
|
210
|
+
"stroke-linejoin": "round"
|
211
|
+
}),
|
212
|
+
n("path", {
|
213
|
+
d: "M2 6.66667H14",
|
214
|
+
stroke: "currentColor",
|
215
|
+
"stroke-linecap": "round",
|
216
|
+
"stroke-linejoin": "round"
|
217
|
+
})
|
218
|
+
], -1)
|
219
|
+
]), 8, he),
|
220
|
+
n("span", {
|
221
|
+
id: `bdpi-description_${r(f)}`,
|
222
|
+
class: "bb-base-date-picker-input__accessible-description sr-only"
|
223
|
+
}, E(r(u)("baseDatePickerInput.dateFormat")) + " " + E(t.range ? r(u)("baseDatePickerInput.dateFormatRange") : r(u)("baseDatePickerInput.dateFormatSingle")), 9, Me)
|
213
224
|
]),
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
+
_: 3
|
226
|
+
}, 8, ["append:icon", "clearable", "prepend:icon"]),
|
227
|
+
r(q) ? (Y(), C(ye, {
|
228
|
+
key: 0,
|
229
|
+
modelValue: l.value,
|
230
|
+
"onUpdate:modelValue": a[0] || (a[0] = (p) => l.value = p),
|
231
|
+
block: !0,
|
232
|
+
dialog: "",
|
233
|
+
offset: 4
|
234
|
+
}, {
|
235
|
+
default: s(() => [
|
236
|
+
n("div", {
|
237
|
+
ref_key: "calendar",
|
238
|
+
ref: v,
|
239
|
+
class: w(["bb-base-date-picker-input__calendar", {
|
240
|
+
"bb-base-date-picker-input__calendar--shown": l.value
|
241
|
+
}]),
|
242
|
+
inert: !l.value
|
225
243
|
}, [
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
"
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
}),
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
}),
|
244
|
-
s("path", {
|
245
|
-
d: "M2 6.66667H14",
|
246
|
-
stroke: "currentColor",
|
247
|
-
"stroke-linecap": "round",
|
248
|
-
"stroke-linejoin": "round"
|
249
|
-
})
|
250
|
-
], -1)
|
251
|
-
]), 8, Me),
|
252
|
-
s("span", {
|
253
|
-
id: `bdpi-description_${n(f)}`,
|
254
|
-
class: "bb-base-date-picker-input__accessible-description sr-only"
|
255
|
-
}, E(n(u)("baseDatePickerInput.dateFormat")) + " " + E(t.range ? n(u)("baseDatePickerInput.dateFormatRange") : n(u)("baseDatePickerInput.dateFormatSingle")), 9, he)
|
256
|
-
]),
|
257
|
-
_: 3
|
258
|
-
}, 8, ["append:icon", "clearable", "prepend:icon"])
|
244
|
+
B(be, S({ id: r(f) }, U, {
|
245
|
+
ref_key: "basedatepicker",
|
246
|
+
ref: V,
|
247
|
+
disabled: e.disabled,
|
248
|
+
"first-day-of-week": e.firstDayOfWeek,
|
249
|
+
max: e.max,
|
250
|
+
min: e.min,
|
251
|
+
"model-value": e.modelValue,
|
252
|
+
range: e.range,
|
253
|
+
readonly: e.readonly,
|
254
|
+
selectable: e.selectable
|
255
|
+
}), null, 16, ["id", "disabled", "first-day-of-week", "max", "min", "model-value", "range", "readonly", "selectable"])
|
256
|
+
], 10, De)
|
257
|
+
]),
|
258
|
+
_: 1
|
259
|
+
}, 8, ["modelValue"])) : X("", !0)
|
260
|
+
])
|
259
261
|
]),
|
260
262
|
_: 3
|
261
263
|
}, 8, ["class"]));
|
262
264
|
}
|
263
265
|
});
|
264
266
|
export {
|
265
|
-
|
267
|
+
Ze as default
|
266
268
|
};
|
package/dist/index230.js
CHANGED
@@ -1,115 +1,88 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import {
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
}]),
|
71
|
-
style: z({
|
72
|
-
"--transition-duration": `${o.transitionDuration}ms`
|
73
|
-
})
|
74
|
-
}, {
|
75
|
-
default: w(() => {
|
76
|
-
var m, c, f;
|
77
|
-
return [
|
78
|
-
y(e.$slots, "activator"),
|
79
|
-
e.renderContent ? (v(), b(g(e.dialog ? "dialog" : e.tag), h({
|
80
|
-
key: 0,
|
81
|
-
ref_key: "content",
|
82
|
-
ref: t,
|
83
|
-
class: ["bb-common-popover__bubble-container", {
|
84
|
-
"bb-common-popover__bubble-container--open": a.value && !!t.value
|
85
|
-
}],
|
86
|
-
popover: "manual",
|
87
|
-
style: {
|
88
|
-
...((m = e.containerAttributes) == null ? void 0 : m.style) ?? {},
|
89
|
-
...n(k),
|
90
|
-
"--arrow-offset-x": Math.round(((f = (c = n(l)) == null ? void 0 : c.arrow) == null ? void 0 : f.x) ?? 0) + "px",
|
91
|
-
"--page-padding": `${e.padding}px`
|
92
|
-
},
|
93
|
-
tabindex: a.value ? void 0 : -1
|
94
|
-
}, e.containerAttributes, { onClose: n(B) }), {
|
95
|
-
default: w(() => [
|
96
|
-
C("span", h({
|
97
|
-
ref_key: "bubblearrow",
|
98
|
-
ref: p,
|
99
|
-
class: "bb-common-popover__arrow"
|
100
|
-
}, $.value), null, 16),
|
101
|
-
C("span", K, [
|
102
|
-
y(e.$slots, "default")
|
1
|
+
import { defineComponent as h, createElementBlock as n, openBlock as s, normalizeClass as r, createElementVNode as l, renderSlot as t, createCommentVNode as p, createTextVNode as o, toDisplayString as d, unref as b, Fragment as m, renderList as u } from "vue";
|
2
|
+
import { useLocale as g } from "./index218.js";
|
3
|
+
const k = { class: "bb-cr-container__container" }, y = {
|
4
|
+
key: 0,
|
5
|
+
class: "bb-cr-container__loading-container"
|
6
|
+
}, $ = {
|
7
|
+
key: 1,
|
8
|
+
class: "bb-cr-container__no-data-container"
|
9
|
+
}, C = /* @__PURE__ */ h({
|
10
|
+
__name: "OptionsContainer",
|
11
|
+
props: {
|
12
|
+
direction: {},
|
13
|
+
hasErrors: { type: Boolean },
|
14
|
+
hideLabel: { type: Boolean },
|
15
|
+
loadingText: {},
|
16
|
+
loading: { type: Boolean },
|
17
|
+
noDataText: {},
|
18
|
+
options: {}
|
19
|
+
},
|
20
|
+
setup(f) {
|
21
|
+
const { t: i } = g();
|
22
|
+
return (a, T) => (s(), n("span", {
|
23
|
+
ref: "container",
|
24
|
+
class: r(["bb-cr-container", {
|
25
|
+
"bb-cr-container--errors": a.hasErrors,
|
26
|
+
"bb-cr-container--horizontal": a.direction === "horizontal",
|
27
|
+
"bb-cr-container--vertical": a.direction === "vertical"
|
28
|
+
}])
|
29
|
+
}, [
|
30
|
+
l("span", k, [
|
31
|
+
t(a.$slots, "prepend"),
|
32
|
+
!a.options.length && a.loading ? (s(), n("span", y, [
|
33
|
+
t(a.$slots, "loading", {}, () => [
|
34
|
+
o(d(a.loadingText || b(i)("common.loadingText")), 1)
|
35
|
+
])
|
36
|
+
])) : a.options.length ? p("", !0) : (s(), n("span", $, [
|
37
|
+
t(a.$slots, "no-data", {}, () => [
|
38
|
+
o(d(a.noDataText || b(i)("common.noDataText")), 1)
|
39
|
+
])
|
40
|
+
])),
|
41
|
+
(s(!0), n(m, null, u(a.options, (e, c) => (s(), n(m, {
|
42
|
+
key: (e == null ? void 0 : e.valueHash) || c
|
43
|
+
}, [
|
44
|
+
t(a.$slots, "option:prepend", {
|
45
|
+
id: e.valueHash,
|
46
|
+
checked: !!e.selected,
|
47
|
+
disabled: !!e.disabled,
|
48
|
+
item: e.item,
|
49
|
+
text: e.text
|
50
|
+
}),
|
51
|
+
l("label", {
|
52
|
+
class: r(["bb-cr-container-option", { "bb-base-radio-selected": e.selected }])
|
53
|
+
}, [
|
54
|
+
t(a.$slots, "input", {
|
55
|
+
index: c,
|
56
|
+
option: e
|
57
|
+
}),
|
58
|
+
l("span", {
|
59
|
+
class: r({
|
60
|
+
"bb-cr-container-option__text": !0,
|
61
|
+
"sr-only": a.hideLabel
|
62
|
+
})
|
63
|
+
}, [
|
64
|
+
t(a.$slots, "label", {
|
65
|
+
checked: !!e.selected,
|
66
|
+
item: e.item,
|
67
|
+
text: e.text
|
68
|
+
}, () => [
|
69
|
+
o(d(e.text), 1)
|
103
70
|
])
|
104
|
-
])
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
71
|
+
], 2)
|
72
|
+
], 2),
|
73
|
+
t(a.$slots, "option:append", {
|
74
|
+
id: e.valueHash,
|
75
|
+
checked: !!e.selected,
|
76
|
+
disabled: !!e.disabled,
|
77
|
+
item: e.item,
|
78
|
+
text: e.text
|
79
|
+
})
|
80
|
+
], 64))), 128)),
|
81
|
+
t(a.$slots, "append")
|
82
|
+
])
|
83
|
+
], 2));
|
111
84
|
}
|
112
85
|
});
|
113
86
|
export {
|
114
|
-
|
87
|
+
C as default
|
115
88
|
};
|