@nilloq/ouds-web 0.1.6 → 0.1.7
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/README.md +17 -115
- package/dist/{alert-bsnEmrzb.js → alert-B4w3fDHo.js} +2 -2
- package/dist/{alert-By364Om4.js → alert-Chns046l.js} +1 -1
- package/dist/alert.js +1 -1
- package/dist/{badge-fffoaFuZ.js → badge-CDpWg-AO.js} +1 -1
- package/dist/badge.js +1 -1
- package/dist/{button-BUziAVbu.js → button-rgIJZsYq.js} +1 -1
- package/dist/button.js +1 -1
- package/dist/checkbox-D7TFFuw3.js +196 -0
- package/dist/checkbox-DfYlHYR2.js +155 -0
- package/dist/checkbox.js +1 -1
- package/dist/chip-B3v4pWZD.js +92 -0
- package/dist/chip-DGfqitrQ.js +115 -0
- package/dist/chip.js +2 -0
- package/dist/{control-item-slots-BNXNsI1e.js → control-item-slots-BDoeNuk4.js} +5 -2
- package/dist/{control-item-slots-XV8Gjvf1.js → control-item-slots-Ddp7c8w8.js} +4 -1
- package/dist/elements-alert.js +1 -1
- package/dist/elements-badge.js +1 -1
- package/dist/elements-button.js +1 -1
- package/dist/elements-checkbox.js +1 -1
- package/dist/elements-chip.js +2 -0
- package/dist/elements-modal.js +1 -1
- package/dist/elements-radio.js +1 -1
- package/dist/elements-select.js +1 -1
- package/dist/elements-switch.js +1 -1
- package/dist/elements-tag.js +1 -1
- package/dist/elements-text-area.js +1 -1
- package/dist/elements-text-input.js +1 -1
- package/dist/elements.js +14 -13
- package/dist/index.js +13 -12
- package/dist/{modal-IEXNB8St.js → modal-BAvMVUIE.js} +2 -2
- package/dist/{modal-CHjaB_yR.js → modal-BnT5Kxjg.js} +1 -1
- package/dist/modal.js +1 -1
- package/dist/radio-CDq4r1_L.js +155 -0
- package/dist/radio-TaYThYkI.js +199 -0
- package/dist/radio.js +1 -1
- package/dist/{runtime-dom.esm-bundler-BeOO_l6v.js → runtime-dom.esm-bundler-DLryEdgJ.js} +1 -1
- package/dist/select--O3jL-En.js +134 -0
- package/dist/select-NiIx8bVD.js +191 -0
- package/dist/select.js +1 -1
- package/dist/switch-BmxLKPbL.js +179 -0
- package/dist/switch-D5N-j5F7.js +140 -0
- package/dist/switch.js +1 -1
- package/dist/{tag-BdB0YDBJ.js → tag-BvOt0v-c.js} +1 -1
- package/dist/tag.js +1 -1
- package/dist/text-area-BdmAyh3N.js +163 -0
- package/dist/text-area-BgYNtAMx.js +107 -0
- package/dist/text-area.js +1 -1
- package/dist/text-input-DgFIuIOA.js +235 -0
- package/dist/text-input-i559HVOP.js +163 -0
- package/dist/text-input.js +1 -1
- package/dist/types/chip.d.ts +1 -0
- package/dist/types/components/alert/Alert.vue.d.ts +3 -3
- package/dist/types/components/badge/Badge.vue.d.ts +1 -1
- package/dist/types/components/button/Button.vue.d.ts +1 -1
- package/dist/types/components/checkbox/Checkbox.vue.d.ts +4 -15
- package/dist/types/components/checkbox/VueCheckbox.vue.d.ts +9 -3
- package/dist/types/components/checkbox/checkbox.types.d.ts +16 -0
- package/dist/types/components/chip/Chip.vue.d.ts +38 -0
- package/dist/types/components/chip/VueChip.vue.d.ts +32 -0
- package/dist/types/components/chip/chip.context.d.ts +2 -0
- package/dist/types/components/chip/chip.types.d.ts +27 -0
- package/dist/types/components/modal/Modal.vue.d.ts +8 -8
- package/dist/types/components/radio/Radio.vue.d.ts +2 -17
- package/dist/types/components/radio/VueRadio.vue.d.ts +8 -6
- package/dist/types/components/radio/radio.types.d.ts +16 -0
- package/dist/types/components/select/Select.vue.d.ts +2 -19
- package/dist/types/components/select/VueSelect.vue.d.ts +9 -3
- package/dist/types/components/select/select.types.d.ts +18 -0
- package/dist/types/components/shared/control-item-slots.d.ts +1 -0
- package/dist/types/components/switch/Switch.vue.d.ts +2 -14
- package/dist/types/components/switch/VueSwitch.vue.d.ts +9 -3
- package/dist/types/components/switch/switch.types.d.ts +13 -0
- package/dist/types/components/tag/Tag.vue.d.ts +1 -1
- package/dist/types/components/text-area/TextArea.vue.d.ts +2 -16
- package/dist/types/components/text-area/VueTextArea.vue.d.ts +9 -3
- package/dist/types/components/text-area/text-area.types.d.ts +15 -0
- package/dist/types/components/text-input/TextInput.vue.d.ts +2 -19
- package/dist/types/components/text-input/VueTextInput.vue.d.ts +9 -3
- package/dist/types/components/text-input/text-input.types.d.ts +25 -0
- package/dist/types/elements/chip.d.ts +4 -0
- package/dist/types/elements/index.d.ts +2 -0
- package/dist/types/vue/checkbox.d.ts +1 -1
- package/dist/types/vue/chip.d.ts +2 -0
- package/dist/types/vue/index.d.ts +8 -6
- package/dist/types/vue/radio.d.ts +1 -1
- package/dist/types/vue/select.d.ts +1 -1
- package/dist/types/vue/switch.d.ts +1 -1
- package/dist/types/vue/text-area.d.ts +1 -1
- package/dist/types/vue/text-input.d.ts +1 -1
- package/dist/vue-alert.js +1 -1
- package/dist/vue-checkbox.js +1 -1
- package/dist/vue-chip.js +2 -0
- package/dist/vue-modal.js +1 -1
- package/dist/vue-radio.js +1 -1
- package/dist/vue-select.js +1 -1
- package/dist/vue-switch.js +1 -1
- package/dist/vue-text-area.js +1 -1
- package/dist/vue-text-input.js +1 -1
- package/dist/vue.js +10 -9
- package/package.json +15 -2
- package/dist/checkbox-PAgQqiIw.js +0 -145
- package/dist/checkbox-g6cqR6wz.js +0 -170
- package/dist/radio-Cmrtred_.js +0 -147
- package/dist/radio-CqVqsZ7n.js +0 -175
- package/dist/select-Bpou1HIY.js +0 -167
- package/dist/select-CWjTpHGb.js +0 -126
- package/dist/switch-CFv0JUeq.js +0 -132
- package/dist/switch-DEYsTCw5.js +0 -157
- package/dist/text-area-DkjEGpHg.js +0 -99
- package/dist/text-area-DqBoz2_d.js +0 -139
- package/dist/text-input-DnWjB1vE.js +0 -207
- package/dist/text-input-DxzwRS2R.js +0 -157
package/dist/radio-Cmrtred_.js
DELETED
|
@@ -1,147 +0,0 @@
|
|
|
1
|
-
import { A as e, M as t, T as n, a as r, b as i, c as a, d as o, f as s, g as c, j as l, k as u, l as d, o as f, p, s as m, t as h, u as g, v as _, x as v, y } from "./runtime-dom.esm-bundler-BeOO_l6v.js";
|
|
2
|
-
import { n as b, t as x } from "./control-item-slots-BNXNsI1e.js";
|
|
3
|
-
//#region src/components/radio/radio.context.ts
|
|
4
|
-
var S = Symbol("ouds-radio-element-id"), C = { class: "control-item-assets-container" }, w = [
|
|
5
|
-
"id",
|
|
6
|
-
"name",
|
|
7
|
-
"value",
|
|
8
|
-
"checked",
|
|
9
|
-
"disabled",
|
|
10
|
-
"required",
|
|
11
|
-
"aria-describedby",
|
|
12
|
-
"aria-invalid"
|
|
13
|
-
], T = [
|
|
14
|
-
"id",
|
|
15
|
-
"aria-checked",
|
|
16
|
-
"aria-labelledby",
|
|
17
|
-
"aria-describedby",
|
|
18
|
-
"aria-invalid"
|
|
19
|
-
], E = { class: "control-item-text-container" }, D = ["id"], O = ["id"], k = {
|
|
20
|
-
key: 0,
|
|
21
|
-
class: "control-item-assets-container"
|
|
22
|
-
}, A = /* @__PURE__ */ o({
|
|
23
|
-
inheritAttrs: !1,
|
|
24
|
-
__name: "Radio",
|
|
25
|
-
props: {
|
|
26
|
-
label: { default: "Radio" },
|
|
27
|
-
description: { default: "" },
|
|
28
|
-
value: { default: "" },
|
|
29
|
-
checked: {
|
|
30
|
-
type: Boolean,
|
|
31
|
-
default: !1
|
|
32
|
-
},
|
|
33
|
-
disabled: {
|
|
34
|
-
type: Boolean,
|
|
35
|
-
default: !1
|
|
36
|
-
},
|
|
37
|
-
required: {
|
|
38
|
-
type: Boolean,
|
|
39
|
-
default: !1
|
|
40
|
-
},
|
|
41
|
-
divider: {
|
|
42
|
-
type: Boolean,
|
|
43
|
-
default: !1
|
|
44
|
-
},
|
|
45
|
-
outlined: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: !1
|
|
48
|
-
},
|
|
49
|
-
extraLabel: { default: "" },
|
|
50
|
-
name: { default: "" },
|
|
51
|
-
readonly: {
|
|
52
|
-
type: Boolean,
|
|
53
|
-
default: !1
|
|
54
|
-
},
|
|
55
|
-
invalid: {
|
|
56
|
-
type: Boolean,
|
|
57
|
-
default: !1
|
|
58
|
-
},
|
|
59
|
-
reverse: {
|
|
60
|
-
type: Boolean,
|
|
61
|
-
default: !1
|
|
62
|
-
},
|
|
63
|
-
maxWidth: {
|
|
64
|
-
type: Boolean,
|
|
65
|
-
default: !1
|
|
66
|
-
}
|
|
67
|
-
},
|
|
68
|
-
setup(o) {
|
|
69
|
-
let h = i(), x = u(() => h.id), A = v(), j = s(S, void 0), M = b(j !== void 0), N = u(() => j ? `${x.value || j}-input` : x.value || `ouds-radio-${A}`), P = u(() => `${N.value}-label`), F = u(() => `${N.value}-extra-label`), I = u(() => `${N.value}-description`);
|
|
70
|
-
function L() {
|
|
71
|
-
let e = [h["aria-describedby"]];
|
|
72
|
-
return (o.extraLabel || M("extra-label")) && e.push(F.value), (o.description || M("description")) && e.push(I.value), e.filter(Boolean).join(" ") || void 0;
|
|
73
|
-
}
|
|
74
|
-
function R() {
|
|
75
|
-
return [h["aria-labelledby"], P.value].filter(Boolean).join(" ");
|
|
76
|
-
}
|
|
77
|
-
let z = r(() => ["radio-button-item", {
|
|
78
|
-
"control-item-divider": o.divider,
|
|
79
|
-
"radio-button-item-outlined": o.outlined,
|
|
80
|
-
"control-item-reverse": o.reverse,
|
|
81
|
-
"component-max-width": o.maxWidth
|
|
82
|
-
}]);
|
|
83
|
-
return (r, i) => (c(), d("div", { class: l(z.value) }, [
|
|
84
|
-
f("div", C, [o.readonly ? (c(), d("span", p({ key: 1 }, e(h), {
|
|
85
|
-
id: N.value,
|
|
86
|
-
class: "control-item-indicator",
|
|
87
|
-
role: "radio",
|
|
88
|
-
"aria-disabled": "true",
|
|
89
|
-
tabindex: "0",
|
|
90
|
-
"aria-checked": o.checked,
|
|
91
|
-
"aria-labelledby": R(),
|
|
92
|
-
"aria-describedby": L(),
|
|
93
|
-
"aria-invalid": o.invalid || e(h)["aria-invalid"]
|
|
94
|
-
}), null, 16, T)) : (c(), d("input", p({ key: 0 }, e(h), {
|
|
95
|
-
id: N.value,
|
|
96
|
-
class: "control-item-indicator",
|
|
97
|
-
type: "radio",
|
|
98
|
-
name: o.name,
|
|
99
|
-
value: o.value,
|
|
100
|
-
checked: o.checked,
|
|
101
|
-
disabled: o.disabled,
|
|
102
|
-
required: o.required,
|
|
103
|
-
"aria-describedby": L(),
|
|
104
|
-
"aria-invalid": o.invalid || e(h)["aria-invalid"]
|
|
105
|
-
}), null, 16, w))]),
|
|
106
|
-
f("div", E, [
|
|
107
|
-
(c(), m(y(o.readonly ? "span" : "label"), {
|
|
108
|
-
id: P.value,
|
|
109
|
-
class: l(["control-item-label", { "is-required": o.required }]),
|
|
110
|
-
for: o.readonly ? void 0 : N.value
|
|
111
|
-
}, {
|
|
112
|
-
default: n(() => [_(r.$slots, "label", {}, () => [g(t(o.label), 1)])]),
|
|
113
|
-
_: 3
|
|
114
|
-
}, 8, [
|
|
115
|
-
"id",
|
|
116
|
-
"class",
|
|
117
|
-
"for"
|
|
118
|
-
])),
|
|
119
|
-
o.extraLabel || e(M)("extra-label") ? (c(), d("p", {
|
|
120
|
-
key: 0,
|
|
121
|
-
id: F.value,
|
|
122
|
-
class: "radio-button-extra-label"
|
|
123
|
-
}, [_(r.$slots, "extra-label", {}, () => [g(t(o.extraLabel), 1)])], 8, D)) : a("", !0),
|
|
124
|
-
o.description || e(M)("description") ? (c(), d("p", {
|
|
125
|
-
key: 1,
|
|
126
|
-
id: I.value,
|
|
127
|
-
class: "control-item-description"
|
|
128
|
-
}, [_(r.$slots, "description", {}, () => [g(t(o.description), 1)])], 8, O)) : a("", !0)
|
|
129
|
-
]),
|
|
130
|
-
e(M)("asset") ? (c(), d("div", k, [_(r.$slots, "asset")])) : a("", !0)
|
|
131
|
-
], 2));
|
|
132
|
-
}
|
|
133
|
-
}), j = 0, M = h(A, {
|
|
134
|
-
shadowRoot: !1,
|
|
135
|
-
configureApp(e) {
|
|
136
|
-
e.provide(S, `ouds-radio-element-${j++}`);
|
|
137
|
-
}
|
|
138
|
-
}), N = class extends M {
|
|
139
|
-
connectedCallback() {
|
|
140
|
-
x(this), super.connectedCallback();
|
|
141
|
-
}
|
|
142
|
-
};
|
|
143
|
-
function P() {
|
|
144
|
-
typeof customElements < "u" && (customElements.get("ouds-radio") || customElements.define("ouds-radio", N));
|
|
145
|
-
}
|
|
146
|
-
//#endregion
|
|
147
|
-
export { P as n, N as t };
|
package/dist/radio-CqVqsZ7n.js
DELETED
|
@@ -1,175 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./control-item-slots-XV8Gjvf1.js";
|
|
2
|
-
import { computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, createTextVNode as s, defineComponent as c, inject as l, mergeModels as u, mergeProps as d, normalizeClass as f, openBlock as p, renderSlot as m, resolveDynamicComponent as h, toDisplayString as g, toRef as _, unref as v, useAttrs as y, useId as b, useModel as x, withCtx as S } from "vue";
|
|
3
|
-
//#region src/components/radio/radio.context.ts
|
|
4
|
-
var C = Symbol("ouds-radio-element-id"), w = { class: "control-item-assets-container" }, T = [
|
|
5
|
-
"id",
|
|
6
|
-
"name",
|
|
7
|
-
"value",
|
|
8
|
-
"checked",
|
|
9
|
-
"disabled",
|
|
10
|
-
"required",
|
|
11
|
-
"aria-describedby",
|
|
12
|
-
"aria-invalid"
|
|
13
|
-
], E = [
|
|
14
|
-
"id",
|
|
15
|
-
"aria-checked",
|
|
16
|
-
"aria-labelledby",
|
|
17
|
-
"aria-describedby",
|
|
18
|
-
"aria-invalid"
|
|
19
|
-
], D = { class: "control-item-text-container" }, O = ["id"], k = ["id"], A = {
|
|
20
|
-
key: 0,
|
|
21
|
-
class: "control-item-assets-container"
|
|
22
|
-
}, j = /* @__PURE__ */ c({
|
|
23
|
-
inheritAttrs: !1,
|
|
24
|
-
__name: "Radio",
|
|
25
|
-
props: {
|
|
26
|
-
label: { default: "Radio" },
|
|
27
|
-
description: { default: "" },
|
|
28
|
-
value: { default: "" },
|
|
29
|
-
checked: {
|
|
30
|
-
type: Boolean,
|
|
31
|
-
default: !1
|
|
32
|
-
},
|
|
33
|
-
disabled: {
|
|
34
|
-
type: Boolean,
|
|
35
|
-
default: !1
|
|
36
|
-
},
|
|
37
|
-
required: {
|
|
38
|
-
type: Boolean,
|
|
39
|
-
default: !1
|
|
40
|
-
},
|
|
41
|
-
divider: {
|
|
42
|
-
type: Boolean,
|
|
43
|
-
default: !1
|
|
44
|
-
},
|
|
45
|
-
outlined: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: !1
|
|
48
|
-
},
|
|
49
|
-
extraLabel: { default: "" },
|
|
50
|
-
name: { default: "" },
|
|
51
|
-
readonly: {
|
|
52
|
-
type: Boolean,
|
|
53
|
-
default: !1
|
|
54
|
-
},
|
|
55
|
-
invalid: {
|
|
56
|
-
type: Boolean,
|
|
57
|
-
default: !1
|
|
58
|
-
},
|
|
59
|
-
reverse: {
|
|
60
|
-
type: Boolean,
|
|
61
|
-
default: !1
|
|
62
|
-
},
|
|
63
|
-
maxWidth: {
|
|
64
|
-
type: Boolean,
|
|
65
|
-
default: !1
|
|
66
|
-
}
|
|
67
|
-
},
|
|
68
|
-
setup(o) {
|
|
69
|
-
let c = y(), u = _(() => c.id), x = b(), j = l(C, void 0), M = e(j !== void 0), N = _(() => j ? `${u.value || j}-input` : u.value || `ouds-radio-${x}`), P = _(() => `${N.value}-label`), F = _(() => `${N.value}-extra-label`), I = _(() => `${N.value}-description`);
|
|
70
|
-
function L() {
|
|
71
|
-
let e = [c["aria-describedby"]];
|
|
72
|
-
return (o.extraLabel || M("extra-label")) && e.push(F.value), (o.description || M("description")) && e.push(I.value), e.filter(Boolean).join(" ") || void 0;
|
|
73
|
-
}
|
|
74
|
-
function R() {
|
|
75
|
-
return [c["aria-labelledby"], P.value].filter(Boolean).join(" ");
|
|
76
|
-
}
|
|
77
|
-
let z = t(() => ["radio-button-item", {
|
|
78
|
-
"control-item-divider": o.divider,
|
|
79
|
-
"radio-button-item-outlined": o.outlined,
|
|
80
|
-
"control-item-reverse": o.reverse,
|
|
81
|
-
"component-max-width": o.maxWidth
|
|
82
|
-
}]);
|
|
83
|
-
return (e, t) => (p(), i("div", { class: f(z.value) }, [
|
|
84
|
-
a("div", w, [o.readonly ? (p(), i("span", d({ key: 1 }, v(c), {
|
|
85
|
-
id: N.value,
|
|
86
|
-
class: "control-item-indicator",
|
|
87
|
-
role: "radio",
|
|
88
|
-
"aria-disabled": "true",
|
|
89
|
-
tabindex: "0",
|
|
90
|
-
"aria-checked": o.checked,
|
|
91
|
-
"aria-labelledby": R(),
|
|
92
|
-
"aria-describedby": L(),
|
|
93
|
-
"aria-invalid": o.invalid || v(c)["aria-invalid"]
|
|
94
|
-
}), null, 16, E)) : (p(), i("input", d({ key: 0 }, v(c), {
|
|
95
|
-
id: N.value,
|
|
96
|
-
class: "control-item-indicator",
|
|
97
|
-
type: "radio",
|
|
98
|
-
name: o.name,
|
|
99
|
-
value: o.value,
|
|
100
|
-
checked: o.checked,
|
|
101
|
-
disabled: o.disabled,
|
|
102
|
-
required: o.required,
|
|
103
|
-
"aria-describedby": L(),
|
|
104
|
-
"aria-invalid": o.invalid || v(c)["aria-invalid"]
|
|
105
|
-
}), null, 16, T))]),
|
|
106
|
-
a("div", D, [
|
|
107
|
-
(p(), n(h(o.readonly ? "span" : "label"), {
|
|
108
|
-
id: P.value,
|
|
109
|
-
class: f(["control-item-label", { "is-required": o.required }]),
|
|
110
|
-
for: o.readonly ? void 0 : N.value
|
|
111
|
-
}, {
|
|
112
|
-
default: S(() => [m(e.$slots, "label", {}, () => [s(g(o.label), 1)])]),
|
|
113
|
-
_: 3
|
|
114
|
-
}, 8, [
|
|
115
|
-
"id",
|
|
116
|
-
"class",
|
|
117
|
-
"for"
|
|
118
|
-
])),
|
|
119
|
-
o.extraLabel || v(M)("extra-label") ? (p(), i("p", {
|
|
120
|
-
key: 0,
|
|
121
|
-
id: F.value,
|
|
122
|
-
class: "radio-button-extra-label"
|
|
123
|
-
}, [m(e.$slots, "extra-label", {}, () => [s(g(o.extraLabel), 1)])], 8, O)) : r("", !0),
|
|
124
|
-
o.description || v(M)("description") ? (p(), i("p", {
|
|
125
|
-
key: 1,
|
|
126
|
-
id: I.value,
|
|
127
|
-
class: "control-item-description"
|
|
128
|
-
}, [m(e.$slots, "description", {}, () => [s(g(o.description), 1)])], 8, k)) : r("", !0)
|
|
129
|
-
]),
|
|
130
|
-
v(M)("asset") ? (p(), i("div", A, [m(e.$slots, "asset")])) : r("", !0)
|
|
131
|
-
], 2));
|
|
132
|
-
}
|
|
133
|
-
}), M = /* @__PURE__ */ c({
|
|
134
|
-
inheritAttrs: !1,
|
|
135
|
-
__name: "VueRadio",
|
|
136
|
-
props: /*@__PURE__*/ u({ value: { default: "" } }, {
|
|
137
|
-
modelValue: { default: "" },
|
|
138
|
-
modelModifiers: {}
|
|
139
|
-
}),
|
|
140
|
-
emits: /*@__PURE__*/ u(["change"], ["update:modelValue"]),
|
|
141
|
-
setup(e, { emit: t }) {
|
|
142
|
-
let r = x(e, "modelValue"), i = t;
|
|
143
|
-
function a(e) {
|
|
144
|
-
r.value = e.target.value, i("change", e);
|
|
145
|
-
}
|
|
146
|
-
return (t, i) => (p(), n(j, d(t.$attrs, {
|
|
147
|
-
value: e.value,
|
|
148
|
-
checked: r.value === e.value,
|
|
149
|
-
onChange: a
|
|
150
|
-
}), o({ _: 2 }, [
|
|
151
|
-
t.$slots.label ? {
|
|
152
|
-
name: "label",
|
|
153
|
-
fn: S(() => [m(t.$slots, "label")]),
|
|
154
|
-
key: "0"
|
|
155
|
-
} : void 0,
|
|
156
|
-
t.$slots.asset ? {
|
|
157
|
-
name: "asset",
|
|
158
|
-
fn: S(() => [m(t.$slots, "asset")]),
|
|
159
|
-
key: "1"
|
|
160
|
-
} : void 0,
|
|
161
|
-
t.$slots["extra-label"] ? {
|
|
162
|
-
name: "extra-label",
|
|
163
|
-
fn: S(() => [m(t.$slots, "extra-label")]),
|
|
164
|
-
key: "2"
|
|
165
|
-
} : void 0,
|
|
166
|
-
t.$slots.description ? {
|
|
167
|
-
name: "description",
|
|
168
|
-
fn: S(() => [m(t.$slots, "description")]),
|
|
169
|
-
key: "3"
|
|
170
|
-
} : void 0
|
|
171
|
-
]), 1040, ["value", "checked"]));
|
|
172
|
-
}
|
|
173
|
-
});
|
|
174
|
-
//#endregion
|
|
175
|
-
export { M as t };
|
package/dist/select-Bpou1HIY.js
DELETED
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
import { Fragment as e, computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, createTextVNode as s, defineComponent as c, mergeModels as l, mergeProps as u, normalizeClass as d, openBlock as f, renderList as p, renderSlot as m, toDisplayString as h, toRef as g, unref as _, useAttrs as v, useId as y, useModel as b, useSlots as x, withCtx as S } from "vue";
|
|
2
|
-
//#region src/components/select/Select.vue?vue&type=script&setup=true&lang.ts
|
|
3
|
-
var C = ["id", "for"], w = [
|
|
4
|
-
"id",
|
|
5
|
-
"aria-describedby",
|
|
6
|
-
"aria-invalid",
|
|
7
|
-
"value",
|
|
8
|
-
"disabled",
|
|
9
|
-
"required"
|
|
10
|
-
], T = ["selected"], E = ["value", "selected"], D = ["id"], O = ["id"], k = ["id"], A = [
|
|
11
|
-
"id",
|
|
12
|
-
"href",
|
|
13
|
-
"aria-labelledby"
|
|
14
|
-
], j = /* @__PURE__ */ c({
|
|
15
|
-
inheritAttrs: !1,
|
|
16
|
-
__name: "Select",
|
|
17
|
-
props: {
|
|
18
|
-
label: { default: "Select" },
|
|
19
|
-
options: { default: () => [] },
|
|
20
|
-
helperText: { default: "" },
|
|
21
|
-
errorText: { default: "" },
|
|
22
|
-
helperLink: { default: "" },
|
|
23
|
-
helperLinkHref: { default: "" },
|
|
24
|
-
value: { default: "" },
|
|
25
|
-
outlined: {
|
|
26
|
-
type: Boolean,
|
|
27
|
-
default: !1
|
|
28
|
-
},
|
|
29
|
-
disabled: {
|
|
30
|
-
type: Boolean,
|
|
31
|
-
default: !1
|
|
32
|
-
},
|
|
33
|
-
required: {
|
|
34
|
-
type: Boolean,
|
|
35
|
-
default: !1
|
|
36
|
-
},
|
|
37
|
-
invalid: {
|
|
38
|
-
type: Boolean,
|
|
39
|
-
default: !1
|
|
40
|
-
},
|
|
41
|
-
maxWidth: {
|
|
42
|
-
type: Boolean,
|
|
43
|
-
default: !1
|
|
44
|
-
},
|
|
45
|
-
loading: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: !1
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
setup(n) {
|
|
51
|
-
let o = v(), c = g(() => o.id), l = x(), b = y(), S = g(() => c.value || `ouds-select-${b}`), j = g(() => `${S.value}-label`), M = g(() => `${S.value}-helper`), N = g(() => `${S.value}-error`), P = g(() => `${S.value}-helper-link`), F = g(() => `${S.value}-loading`);
|
|
52
|
-
function I() {
|
|
53
|
-
let e = [o["aria-describedby"]];
|
|
54
|
-
return (n.helperText || l["helper-text"]) && !n.invalid && e.push(M.value), n.invalid && (n.errorText || l["error-text"]) && e.push(N.value), n.helperLinkHref && (n.helperLink || l["helper-link"]) && e.push(P.value), n.loading && e.push(F.value), e.filter(Boolean).join(" ") || void 0;
|
|
55
|
-
}
|
|
56
|
-
let L = t(() => ["select-input-container", { "select-input-container-outlined": n.outlined }]), R = t(() => ["select-input", { "component-max-width": n.maxWidth }]), z = t(() => ["select-input-field", { "loading-indeterminate": n.loading }]);
|
|
57
|
-
return (t, c) => (f(), i("div", { class: d(R.value) }, [
|
|
58
|
-
a("div", { class: d(L.value) }, [
|
|
59
|
-
m(t.$slots, "leading-icon"),
|
|
60
|
-
a("label", {
|
|
61
|
-
id: j.value,
|
|
62
|
-
for: S.value,
|
|
63
|
-
class: d({ "is-required": n.required })
|
|
64
|
-
}, [m(t.$slots, "label", {}, () => [s(h(n.label), 1)])], 10, C),
|
|
65
|
-
a("select", u(_(o), {
|
|
66
|
-
id: S.value,
|
|
67
|
-
"aria-describedby": I(),
|
|
68
|
-
"aria-invalid": n.invalid || _(o)["aria-invalid"],
|
|
69
|
-
class: z.value,
|
|
70
|
-
value: n.value,
|
|
71
|
-
disabled: n.disabled,
|
|
72
|
-
required: n.required
|
|
73
|
-
}), [a("option", {
|
|
74
|
-
value: "",
|
|
75
|
-
disabled: "",
|
|
76
|
-
selected: n.value === ""
|
|
77
|
-
}, null, 8, T), m(t.$slots, "default", {}, () => [(f(!0), i(e, null, p(n.options, (e) => (f(), i("option", {
|
|
78
|
-
key: e.value,
|
|
79
|
-
value: e.value,
|
|
80
|
-
selected: e.value === n.value
|
|
81
|
-
}, h(e.label), 9, E))), 128))])], 16, w),
|
|
82
|
-
n.loading ? (f(), i(e, { key: 0 }, [c[0] ||= a("svg", {
|
|
83
|
-
viewBox: "0 0 40 40",
|
|
84
|
-
class: "loader",
|
|
85
|
-
"aria-hidden": "true"
|
|
86
|
-
}, [a("circle", {
|
|
87
|
-
class: "loader-inner",
|
|
88
|
-
cx: "20",
|
|
89
|
-
cy: "20",
|
|
90
|
-
r: "17"
|
|
91
|
-
})], -1), a("span", {
|
|
92
|
-
id: F.value,
|
|
93
|
-
role: "status",
|
|
94
|
-
class: "visually-hidden"
|
|
95
|
-
}, "Loading", 8, D)], 64)) : r("", !0)
|
|
96
|
-
], 2),
|
|
97
|
-
(n.helperText || t.$slots["helper-text"]) && !n.invalid ? (f(), i("p", {
|
|
98
|
-
key: 0,
|
|
99
|
-
id: M.value,
|
|
100
|
-
class: "helper-text"
|
|
101
|
-
}, [m(t.$slots, "helper-text", {}, () => [s(h(n.helperText), 1)])], 8, O)) : r("", !0),
|
|
102
|
-
n.invalid && (n.errorText || t.$slots["error-text"]) ? (f(), i("p", {
|
|
103
|
-
key: 1,
|
|
104
|
-
id: N.value,
|
|
105
|
-
class: "error-text"
|
|
106
|
-
}, [m(t.$slots, "error-text", {}, () => [s(h(n.errorText), 1)])], 8, k)) : r("", !0),
|
|
107
|
-
n.helperLinkHref && (n.helperLink || t.$slots["helper-link"]) ? (f(), i("a", {
|
|
108
|
-
key: 2,
|
|
109
|
-
id: P.value,
|
|
110
|
-
href: n.helperLinkHref,
|
|
111
|
-
"aria-labelledby": `${P.value} ${j.value}`,
|
|
112
|
-
class: "link link-small"
|
|
113
|
-
}, [m(t.$slots, "helper-link", {}, () => [s(h(n.helperLink), 1)]), c[1] ||= a("span", { class: "visually-hidden" }, "on", -1)], 8, A)) : r("", !0)
|
|
114
|
-
], 2));
|
|
115
|
-
}
|
|
116
|
-
}), M = /* @__PURE__ */ c({
|
|
117
|
-
inheritAttrs: !1,
|
|
118
|
-
__name: "VueSelect",
|
|
119
|
-
props: {
|
|
120
|
-
modelValue: { default: "" },
|
|
121
|
-
modelModifiers: {}
|
|
122
|
-
},
|
|
123
|
-
emits: /*@__PURE__*/ l(["change"], ["update:modelValue"]),
|
|
124
|
-
setup(e, { emit: t }) {
|
|
125
|
-
let r = b(e, "modelValue"), i = t;
|
|
126
|
-
function a(e) {
|
|
127
|
-
r.value = e.target.value, i("change", e);
|
|
128
|
-
}
|
|
129
|
-
return (e, t) => (f(), n(j, u(e.$attrs, {
|
|
130
|
-
value: r.value,
|
|
131
|
-
onChange: a
|
|
132
|
-
}), o({ _: 2 }, [
|
|
133
|
-
e.$slots.label ? {
|
|
134
|
-
name: "label",
|
|
135
|
-
fn: S(() => [m(e.$slots, "label")]),
|
|
136
|
-
key: "0"
|
|
137
|
-
} : void 0,
|
|
138
|
-
e.$slots["leading-icon"] ? {
|
|
139
|
-
name: "leading-icon",
|
|
140
|
-
fn: S(() => [m(e.$slots, "leading-icon")]),
|
|
141
|
-
key: "1"
|
|
142
|
-
} : void 0,
|
|
143
|
-
e.$slots["helper-text"] ? {
|
|
144
|
-
name: "helper-text",
|
|
145
|
-
fn: S(() => [m(e.$slots, "helper-text")]),
|
|
146
|
-
key: "2"
|
|
147
|
-
} : void 0,
|
|
148
|
-
e.$slots["error-text"] ? {
|
|
149
|
-
name: "error-text",
|
|
150
|
-
fn: S(() => [m(e.$slots, "error-text")]),
|
|
151
|
-
key: "3"
|
|
152
|
-
} : void 0,
|
|
153
|
-
e.$slots["helper-link"] ? {
|
|
154
|
-
name: "helper-link",
|
|
155
|
-
fn: S(() => [m(e.$slots, "helper-link")]),
|
|
156
|
-
key: "4"
|
|
157
|
-
} : void 0,
|
|
158
|
-
e.$slots.default ? {
|
|
159
|
-
name: "default",
|
|
160
|
-
fn: S(() => [m(e.$slots, "default")]),
|
|
161
|
-
key: "5"
|
|
162
|
-
} : void 0
|
|
163
|
-
]), 1040, ["value"]));
|
|
164
|
-
}
|
|
165
|
-
});
|
|
166
|
-
//#endregion
|
|
167
|
-
export { M as t };
|
package/dist/select-CWjTpHGb.js
DELETED
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
import { A as e, M as t, S as n, _ as r, a as i, b as a, c as o, d as s, g as c, i as l, j as u, k as d, l as f, o as p, p as m, t as h, u as g, v as _, x as v } from "./runtime-dom.esm-bundler-BeOO_l6v.js";
|
|
2
|
-
//#region src/components/select/Select.vue?vue&type=script&setup=true&lang.ts
|
|
3
|
-
var y = ["id", "for"], b = [
|
|
4
|
-
"id",
|
|
5
|
-
"aria-describedby",
|
|
6
|
-
"aria-invalid",
|
|
7
|
-
"value",
|
|
8
|
-
"disabled",
|
|
9
|
-
"required"
|
|
10
|
-
], x = ["selected"], S = ["value", "selected"], C = ["id"], w = ["id"], T = ["id"], E = [
|
|
11
|
-
"id",
|
|
12
|
-
"href",
|
|
13
|
-
"aria-labelledby"
|
|
14
|
-
], D = h(/* @__PURE__ */ s({
|
|
15
|
-
inheritAttrs: !1,
|
|
16
|
-
__name: "Select",
|
|
17
|
-
props: {
|
|
18
|
-
label: { default: "Select" },
|
|
19
|
-
options: { default: () => [] },
|
|
20
|
-
helperText: { default: "" },
|
|
21
|
-
errorText: { default: "" },
|
|
22
|
-
helperLink: { default: "" },
|
|
23
|
-
helperLinkHref: { default: "" },
|
|
24
|
-
value: { default: "" },
|
|
25
|
-
outlined: {
|
|
26
|
-
type: Boolean,
|
|
27
|
-
default: !1
|
|
28
|
-
},
|
|
29
|
-
disabled: {
|
|
30
|
-
type: Boolean,
|
|
31
|
-
default: !1
|
|
32
|
-
},
|
|
33
|
-
required: {
|
|
34
|
-
type: Boolean,
|
|
35
|
-
default: !1
|
|
36
|
-
},
|
|
37
|
-
invalid: {
|
|
38
|
-
type: Boolean,
|
|
39
|
-
default: !1
|
|
40
|
-
},
|
|
41
|
-
maxWidth: {
|
|
42
|
-
type: Boolean,
|
|
43
|
-
default: !1
|
|
44
|
-
},
|
|
45
|
-
loading: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: !1
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
setup(s) {
|
|
51
|
-
let h = a(), D = d(() => h.id), O = n(), k = v(), A = d(() => D.value || `ouds-select-${k}`), j = d(() => `${A.value}-label`), M = d(() => `${A.value}-helper`), N = d(() => `${A.value}-error`), P = d(() => `${A.value}-helper-link`), F = d(() => `${A.value}-loading`);
|
|
52
|
-
function I() {
|
|
53
|
-
let e = [h["aria-describedby"]];
|
|
54
|
-
return (s.helperText || O["helper-text"]) && !s.invalid && e.push(M.value), s.invalid && (s.errorText || O["error-text"]) && e.push(N.value), s.helperLinkHref && (s.helperLink || O["helper-link"]) && e.push(P.value), s.loading && e.push(F.value), e.filter(Boolean).join(" ") || void 0;
|
|
55
|
-
}
|
|
56
|
-
let L = i(() => ["select-input-container", { "select-input-container-outlined": s.outlined }]), R = i(() => ["select-input", { "component-max-width": s.maxWidth }]), z = i(() => ["select-input-field", { "loading-indeterminate": s.loading }]);
|
|
57
|
-
return (n, i) => (c(), f("div", { class: u(R.value) }, [
|
|
58
|
-
p("div", { class: u(L.value) }, [
|
|
59
|
-
_(n.$slots, "leading-icon"),
|
|
60
|
-
p("label", {
|
|
61
|
-
id: j.value,
|
|
62
|
-
for: A.value,
|
|
63
|
-
class: u({ "is-required": s.required })
|
|
64
|
-
}, [_(n.$slots, "label", {}, () => [g(t(s.label), 1)])], 10, y),
|
|
65
|
-
p("select", m(e(h), {
|
|
66
|
-
id: A.value,
|
|
67
|
-
"aria-describedby": I(),
|
|
68
|
-
"aria-invalid": s.invalid || e(h)["aria-invalid"],
|
|
69
|
-
class: z.value,
|
|
70
|
-
value: s.value,
|
|
71
|
-
disabled: s.disabled,
|
|
72
|
-
required: s.required
|
|
73
|
-
}), [p("option", {
|
|
74
|
-
value: "",
|
|
75
|
-
disabled: "",
|
|
76
|
-
selected: s.value === ""
|
|
77
|
-
}, null, 8, x), _(n.$slots, "default", {}, () => [(c(!0), f(l, null, r(s.options, (e) => (c(), f("option", {
|
|
78
|
-
key: e.value,
|
|
79
|
-
value: e.value,
|
|
80
|
-
selected: e.value === s.value
|
|
81
|
-
}, t(e.label), 9, S))), 128))])], 16, b),
|
|
82
|
-
s.loading ? (c(), f(l, { key: 0 }, [i[0] ||= p("svg", {
|
|
83
|
-
viewBox: "0 0 40 40",
|
|
84
|
-
class: "loader",
|
|
85
|
-
"aria-hidden": "true"
|
|
86
|
-
}, [p("circle", {
|
|
87
|
-
class: "loader-inner",
|
|
88
|
-
cx: "20",
|
|
89
|
-
cy: "20",
|
|
90
|
-
r: "17"
|
|
91
|
-
})], -1), p("span", {
|
|
92
|
-
id: F.value,
|
|
93
|
-
role: "status",
|
|
94
|
-
class: "visually-hidden"
|
|
95
|
-
}, "Loading", 8, C)], 64)) : o("", !0)
|
|
96
|
-
], 2),
|
|
97
|
-
(s.helperText || n.$slots["helper-text"]) && !s.invalid ? (c(), f("p", {
|
|
98
|
-
key: 0,
|
|
99
|
-
id: M.value,
|
|
100
|
-
class: "helper-text"
|
|
101
|
-
}, [_(n.$slots, "helper-text", {}, () => [g(t(s.helperText), 1)])], 8, w)) : o("", !0),
|
|
102
|
-
s.invalid && (s.errorText || n.$slots["error-text"]) ? (c(), f("p", {
|
|
103
|
-
key: 1,
|
|
104
|
-
id: N.value,
|
|
105
|
-
class: "error-text"
|
|
106
|
-
}, [_(n.$slots, "error-text", {}, () => [g(t(s.errorText), 1)])], 8, T)) : o("", !0),
|
|
107
|
-
s.helperLinkHref && (s.helperLink || n.$slots["helper-link"]) ? (c(), f("a", {
|
|
108
|
-
key: 2,
|
|
109
|
-
id: P.value,
|
|
110
|
-
href: s.helperLinkHref,
|
|
111
|
-
"aria-labelledby": `${P.value} ${j.value}`,
|
|
112
|
-
class: "link link-small"
|
|
113
|
-
}, [_(n.$slots, "helper-link", {}, () => [g(t(s.helperLink), 1)]), i[1] ||= p("span", { class: "visually-hidden" }, "on", -1)], 8, E)) : o("", !0)
|
|
114
|
-
], 2));
|
|
115
|
-
}
|
|
116
|
-
}), { shadowRoot: !1 }), O = class extends D {
|
|
117
|
-
connectedCallback() {
|
|
118
|
-
for (let e of Array.from(this.childNodes)) (e.nodeType === 8 || e.nodeType === 3 && !e.textContent?.trim()) && e.remove();
|
|
119
|
-
super.connectedCallback();
|
|
120
|
-
}
|
|
121
|
-
};
|
|
122
|
-
function k() {
|
|
123
|
-
typeof customElements < "u" && (customElements.get("ouds-select") || customElements.define("ouds-select", O));
|
|
124
|
-
}
|
|
125
|
-
//#endregion
|
|
126
|
-
export { k as n, O as t };
|