@wikicasa-dev/components 2.6.9-alpha.0 → 2.6.9-alpha.2
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/UIKit/BaseAutocomplete.vue.js +37 -35
- package/dist/UIKit/BaseInput.d.ts +58 -60
- package/dist/UIKit/BaseInput.js +2 -2
- package/dist/UIKit/BaseInput.vue.js +9 -10
- package/dist/UIKit/BaseToggle.d.ts +17 -18
- package/dist/UIKit/BaseToggle.vue.js +17 -27
- package/dist/assets/BaseInput2.css +1 -1
- package/dist/assets/SwiperCarousel.css +1 -1
- package/dist/assets/SwiperCarousel2.css +1 -0
- package/dist/components/carousel/Primitive/SwiperPaginationPrimitive.js +1 -1
- package/dist/components/carousel/SwiperCarousel.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -1
- package/dist/lazyModules/Swiper/Autoplay/index.js +1 -1
- package/dist/lazyModules/Swiper/Controller/index.js +1 -1
- package/dist/lazyModules/Swiper/Keyboard/index.js +1 -1
- package/dist/lazyModules/Swiper/Thumbs/index.js +1 -1
- package/dist/types/index.d.ts +0 -1
- package/package.json +1 -1
- package/dist/assets/SwiperPaginationPrimitive.css +0 -1
- /package/dist/assets/{swiper-autoplay.css → swiper-thumbs.css} +0 -0
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as x, useModel as F, shallowRef as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import { defineComponent as x, useModel as F, shallowRef as s, useTemplateRef as L, computed as k, onBeforeMount as T, watch as f, openBlock as w, createBlock as y, normalizeClass as H, withCtx as c, createElementBlock as K, Fragment as R, renderList as z, unref as N, renderSlot as p, createElementVNode as U, createVNode as A, mergeModels as $ } from "vue";
|
|
2
|
+
import W from "./BaseInput.js";
|
|
3
|
+
import j from "./BaseDropDown.vue.js";
|
|
4
4
|
import '../assets/BaseDropDown.css';/* empty css */
|
|
5
|
-
import { debounce as
|
|
6
|
-
import
|
|
7
|
-
import { useKeyboardController as
|
|
8
|
-
const
|
|
5
|
+
import { debounce as q } from "@wikicasa-dev/utilities";
|
|
6
|
+
import G from "./BaseSelect/SelectItem.vue.js";
|
|
7
|
+
import { useKeyboardController as J } from "@wikicasa-dev/vue-composables";
|
|
8
|
+
const Q = ["innerHTML"], ae = /* @__PURE__ */ x({
|
|
9
9
|
__name: "BaseAutocomplete",
|
|
10
|
-
props: /* @__PURE__ */
|
|
10
|
+
props: /* @__PURE__ */ $({
|
|
11
11
|
isValid: { type: [Boolean, null], default: null },
|
|
12
12
|
theme: { default: "" },
|
|
13
13
|
label: { default: "" },
|
|
@@ -29,13 +29,13 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
29
29
|
},
|
|
30
30
|
modelModifiers: {}
|
|
31
31
|
}),
|
|
32
|
-
emits: /* @__PURE__ */
|
|
33
|
-
setup(t, { expose:
|
|
34
|
-
const u = F(t, "modelValue"),
|
|
35
|
-
|
|
36
|
-
v.value =
|
|
32
|
+
emits: /* @__PURE__ */ $(["update:dropdownState", "changedValue", "click", "keydown", "keydownEnterPressed"], ["update:modelValue"]),
|
|
33
|
+
setup(t, { expose: g, emit: V }) {
|
|
34
|
+
const u = F(t, "modelValue"), d = V, i = s(""), o = s([]), v = s(null), b = s(!1), n = s(!1), B = L("baseInput"), S = k(() => o.value.length);
|
|
35
|
+
T(() => {
|
|
36
|
+
v.value = q({ delay: 300 }, t.onInputChangeCb);
|
|
37
37
|
});
|
|
38
|
-
const { activeIdx: m, selectedIdx: h } =
|
|
38
|
+
const { activeIdx: m, selectedIdx: h } = J({
|
|
39
39
|
optionsLength: S,
|
|
40
40
|
isDropdownOpen: n,
|
|
41
41
|
disableSpaceHandler: !0
|
|
@@ -74,14 +74,14 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
74
74
|
return "";
|
|
75
75
|
}
|
|
76
76
|
}), D = async (e) => {
|
|
77
|
-
if (i.value !== e && (
|
|
77
|
+
if (i.value !== e && (d("changedValue", e), i.value = e, !!t.onInputChangeCb)) {
|
|
78
78
|
if (!e || b.value) {
|
|
79
79
|
o.value = [], b.value = !1, h.value = -1, m.value = -1, u.value && (u.value.label = ""), n.value = !1, await v.value?.(null);
|
|
80
80
|
return;
|
|
81
81
|
}
|
|
82
82
|
t.disableCb || (o.value = await v.value?.(e) || [], n.value = !!o.value.length);
|
|
83
83
|
}
|
|
84
|
-
},
|
|
84
|
+
}, C = (e, l) => {
|
|
85
85
|
t.onOptionSelectedCb && t.onOptionSelectedCb(e), t.cleanupOnClose && (o.value = []), b.value = !0, i.value = e.label, u.value = e, n.value = !1, h.value = l;
|
|
86
86
|
}, E = () => {
|
|
87
87
|
o.value.length && t.keepState !== "closed" && (n.value = !0);
|
|
@@ -95,19 +95,19 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
95
95
|
), f(h, (e) => {
|
|
96
96
|
if (e === -1 || !o.value.length) return;
|
|
97
97
|
const l = o.value[e];
|
|
98
|
-
b.value && l.label === u.value?.label ||
|
|
98
|
+
b.value && l.label === u.value?.label || C(l, e);
|
|
99
99
|
}), f(
|
|
100
100
|
() => t.keepState,
|
|
101
101
|
(e) => {
|
|
102
102
|
e === "closed" ? (n.value = !1, t.cleanupOnClose && (o.value = [])) : e === "open" && o.value.length && (n.value = !0);
|
|
103
103
|
}
|
|
104
104
|
), f(n, (e) => {
|
|
105
|
-
|
|
106
|
-
}),
|
|
105
|
+
d("update:dropdownState", e);
|
|
106
|
+
}), g({
|
|
107
107
|
select: () => {
|
|
108
|
-
|
|
108
|
+
B.value?.select();
|
|
109
109
|
}
|
|
110
|
-
}), (e, l) => (w(),
|
|
110
|
+
}), (e, l) => (w(), y(j, {
|
|
111
111
|
class: H(["uikit-autocomplete", e.$attrs["root-classes"]]),
|
|
112
112
|
"data-cy": t.dataCy ? t.dataCy : `ac_${e.$attrs.id}`,
|
|
113
113
|
"dropdown-element": "ul",
|
|
@@ -128,14 +128,13 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
128
128
|
"activate-keyboard-controller": !1,
|
|
129
129
|
"onUpdate:open": l[3] || (l[3] = (a) => n.value = a),
|
|
130
130
|
onClick: l[4] || (l[4] = (a) => {
|
|
131
|
-
|
|
131
|
+
d("click"), E();
|
|
132
132
|
})
|
|
133
133
|
}, {
|
|
134
134
|
btn_slot: c(() => [
|
|
135
|
-
A(
|
|
135
|
+
A(W, {
|
|
136
136
|
id: e.$attrs.id ? `ac_input_${e.$attrs.id}` : "",
|
|
137
|
-
|
|
138
|
-
ref: C,
|
|
137
|
+
ref: "baseInput",
|
|
139
138
|
"data-cy": t.dataCy ? `ac_input_${t.dataCy}` : `ac_input_${e.$attrs.id}`,
|
|
140
139
|
"label-text": t.label,
|
|
141
140
|
"model-value": i.value,
|
|
@@ -151,8 +150,8 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
151
150
|
],
|
|
152
151
|
"fieldset-classes": [I.value, t.fieldsetClasses],
|
|
153
152
|
"onUpdate:modelValue": l[0] || (l[0] = (a) => D(a === void 0 ? "" : `${a}`)),
|
|
154
|
-
onKeydown: l[1] || (l[1] = (a) =>
|
|
155
|
-
onKeydownEnterPressed: l[2] || (l[2] = () =>
|
|
153
|
+
onKeydown: l[1] || (l[1] = (a) => d("keydown", a)),
|
|
154
|
+
onKeydownEnterPressed: l[2] || (l[2] = () => d("keydownEnterPressed"))
|
|
156
155
|
}, {
|
|
157
156
|
leftIcon: c(() => [
|
|
158
157
|
p(e.$slots, "lefticon")
|
|
@@ -164,21 +163,24 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
164
163
|
}, 8, ["id", "data-cy", "label-text", "model-value", "is-valid", "disabled", "placeholder", "with-left-icon", "with-right-icon", "input-class", "fieldset-classes"])
|
|
165
164
|
]),
|
|
166
165
|
default: c(() => [
|
|
167
|
-
(w(!0), K(
|
|
168
|
-
key:
|
|
169
|
-
active: N(m) ===
|
|
166
|
+
(w(!0), K(R, null, z(o.value, (a, r) => (w(), y(G, {
|
|
167
|
+
key: r,
|
|
168
|
+
active: N(m) === r,
|
|
170
169
|
class: "uikit-m-1 uikit-rounded-[5px] uikit-px-5 uikit-py-10px hover:uikit-cursor-pointer",
|
|
171
|
-
onClick: (P) =>
|
|
172
|
-
|
|
170
|
+
onClick: (P) => C(
|
|
171
|
+
a,
|
|
172
|
+
r
|
|
173
|
+
),
|
|
174
|
+
onMouseover: (P) => m.value = r
|
|
173
175
|
}, {
|
|
174
176
|
default: c(() => [
|
|
175
177
|
p(e.$slots, "option-content", {
|
|
176
178
|
option: a,
|
|
177
|
-
idx:
|
|
179
|
+
idx: r
|
|
178
180
|
}, () => [
|
|
179
181
|
U("span", {
|
|
180
182
|
innerHTML: a.label
|
|
181
|
-
}, null, 8,
|
|
183
|
+
}, null, 8, Q)
|
|
182
184
|
])
|
|
183
185
|
]),
|
|
184
186
|
_: 2
|
|
@@ -189,5 +191,5 @@ const J = ["innerHTML"], ne = /* @__PURE__ */ x({
|
|
|
189
191
|
}
|
|
190
192
|
});
|
|
191
193
|
export {
|
|
192
|
-
|
|
194
|
+
ae as default
|
|
193
195
|
};
|
|
@@ -1,65 +1,63 @@
|
|
|
1
|
-
import { Nullable,
|
|
1
|
+
import { InputTypeHTMLAttribute, Nullable, Numberish } from '@wikicasa-dev/types';
|
|
2
2
|
import { ClassType, ClassTypeProp, FeedbackLabels } from './types';
|
|
3
|
-
type
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
isValid?: Nullable<boolean>;
|
|
9
|
-
keepFloatingLabel?: boolean;
|
|
10
|
-
formatter?: Nullable<Partial<{
|
|
11
|
-
formatFn: (n: number | string) => string;
|
|
12
|
-
unFormatFn: (v: string) => string | number | null;
|
|
13
|
-
}>>;
|
|
14
|
-
labelClasses?: ClassTypeProp;
|
|
15
|
-
fieldsetClasses?: ClassTypeProp;
|
|
16
|
-
labelTextClasses?: ClassTypeProp;
|
|
17
|
-
withLeftIcon?: boolean;
|
|
18
|
-
withRightIcon?: boolean;
|
|
19
|
-
dataCy?: string;
|
|
20
|
-
};
|
|
21
|
-
type __VLS_ModelProps = {
|
|
22
|
-
modelValue?: string | number | undefined;
|
|
23
|
-
};
|
|
24
|
-
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
25
|
-
declare var __VLS_1: {}, __VLS_3: {
|
|
26
|
-
handleClean: () => void;
|
|
27
|
-
handleShowPasswd: () => void;
|
|
28
|
-
curType: InputTypeHTMLAttribute;
|
|
29
|
-
}, __VLS_10: {}, __VLS_12: {};
|
|
30
|
-
type __VLS_Slots = {} & {
|
|
31
|
-
leftIcon?: (props: typeof __VLS_1) => any;
|
|
32
|
-
} & {
|
|
33
|
-
righticon?: (props: typeof __VLS_3) => any;
|
|
34
|
-
} & {
|
|
35
|
-
feedback?: (props: typeof __VLS_10) => any;
|
|
36
|
-
} & {
|
|
37
|
-
'under-label'?: (props: typeof __VLS_12) => any;
|
|
38
|
-
};
|
|
39
|
-
declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {
|
|
40
|
-
select: () => void;
|
|
41
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
42
|
-
"update:modelValue": (value: string | number | undefined) => any;
|
|
43
|
-
click: (args_0: MouseEvent) => any;
|
|
44
|
-
keydown: (args_0: KeyboardEvent) => any;
|
|
45
|
-
focusin: () => any;
|
|
46
|
-
focusout: () => any;
|
|
47
|
-
keyup: (args_0: KeyboardEvent) => any;
|
|
48
|
-
keydownEnterPressed: () => any;
|
|
49
|
-
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
50
|
-
"onUpdate:modelValue"?: ((value: string | number | undefined) => any) | undefined;
|
|
51
|
-
onClick?: ((args_0: MouseEvent) => any) | undefined;
|
|
52
|
-
onKeydown?: ((args_0: KeyboardEvent) => any) | undefined;
|
|
53
|
-
onFocusin?: (() => any) | undefined;
|
|
54
|
-
onFocusout?: (() => any) | undefined;
|
|
55
|
-
onKeyup?: ((args_0: KeyboardEvent) => any) | undefined;
|
|
56
|
-
onKeydownEnterPressed?: (() => any) | undefined;
|
|
57
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
58
|
-
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
3
|
+
export type BaseInputModelValue = Numberish | undefined | null;
|
|
4
|
+
export type BaseInputFormatter<ModelValue extends BaseInputModelValue> = Partial<{
|
|
5
|
+
formatFn: (value: string) => string;
|
|
6
|
+
unFormatFn: (value: string) => Nullable<ModelValue>;
|
|
7
|
+
}>;
|
|
59
8
|
declare const _default: typeof __VLS_export;
|
|
60
9
|
export default _default;
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
10
|
+
declare const __VLS_export: <ModelValue extends BaseInputModelValue = string>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
11
|
+
props: import('vue').PublicProps & __VLS_PrettifyLocal<({
|
|
12
|
+
id?: string;
|
|
13
|
+
inputClass?: ClassType | ClassType[];
|
|
14
|
+
labelText?: string;
|
|
15
|
+
feedback?: FeedbackLabels;
|
|
16
|
+
isValid?: Nullable<boolean>;
|
|
17
|
+
keepFloatingLabel?: boolean;
|
|
18
|
+
formatter?: Nullable<BaseInputFormatter<ModelValue>>;
|
|
19
|
+
labelClasses?: ClassTypeProp;
|
|
20
|
+
fieldsetClasses?: ClassTypeProp;
|
|
21
|
+
labelTextClasses?: ClassTypeProp;
|
|
22
|
+
withLeftIcon?: boolean;
|
|
23
|
+
withRightIcon?: boolean;
|
|
24
|
+
dataCy?: string;
|
|
25
|
+
} & {
|
|
26
|
+
modelValue?: ModelValue;
|
|
27
|
+
}) & {
|
|
28
|
+
"onUpdate:modelValue"?: ((value: ModelValue) => any) | undefined;
|
|
29
|
+
onClick?: ((args_0: MouseEvent) => any) | undefined;
|
|
30
|
+
onKeydown?: ((args_0: KeyboardEvent) => any) | undefined;
|
|
31
|
+
onFocusin?: (() => any) | undefined;
|
|
32
|
+
onFocusout?: (() => any) | undefined;
|
|
33
|
+
onKeyup?: ((args_0: KeyboardEvent) => any) | undefined;
|
|
34
|
+
onKeydownEnterPressed?: (() => any) | undefined;
|
|
35
|
+
}> & (typeof globalThis extends {
|
|
36
|
+
__VLS_PROPS_FALLBACK: infer P;
|
|
37
|
+
} ? P : {});
|
|
38
|
+
expose: (exposed: import('vue').ShallowUnwrapRef<{
|
|
39
|
+
select: () => void;
|
|
40
|
+
}>) => void;
|
|
41
|
+
attrs: any;
|
|
42
|
+
slots: {
|
|
43
|
+
leftIcon?: (props: {}) => any;
|
|
44
|
+
} & {
|
|
45
|
+
righticon?: (props: {
|
|
46
|
+
handleClean: () => void;
|
|
47
|
+
handleShowPasswd: () => void;
|
|
48
|
+
curType: InputTypeHTMLAttribute;
|
|
49
|
+
}) => any;
|
|
50
|
+
} & {
|
|
51
|
+
feedback?: (props: {}) => any;
|
|
52
|
+
} & {
|
|
53
|
+
'under-label'?: (props: {}) => any;
|
|
64
54
|
};
|
|
55
|
+
emit: (((evt: "click", args_0: MouseEvent) => void) & ((evt: "keydown", args_0: KeyboardEvent) => void) & ((evt: "focusin") => void) & ((evt: "focusout") => void) & ((evt: "keyup", args_0: KeyboardEvent) => void) & ((evt: "keydownEnterPressed") => void)) & ((event: "update:modelValue", value: ModelValue) => void);
|
|
56
|
+
}>) => import('vue').VNode & {
|
|
57
|
+
__ctx?: Awaited<typeof __VLS_setup>;
|
|
65
58
|
};
|
|
59
|
+
type __VLS_PrettifyLocal<T> = (T extends any ? {
|
|
60
|
+
[K in keyof T]: T[K];
|
|
61
|
+
} : {
|
|
62
|
+
[K in keyof T as K]: T[K];
|
|
63
|
+
}) & {};
|
package/dist/UIKit/BaseInput.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./BaseInput.vue.js";
|
|
2
2
|
import '../assets/BaseInput2.css';/* empty css */
|
|
3
3
|
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-f25fc601"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
a as default
|
|
7
7
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as A, useModel as N, ref as m, useId as O, computed as j, watch as y, useAttrs as D, openBlock as u, createElementBlock as r, normalizeClass as v, unref as d, renderSlot as h, createElementVNode as g, withKeys as G, withModifiers as J, createBlock as Q, createCommentVNode as x, Fragment as C, renderList as T, mergeModels as B } from "vue";
|
|
2
2
|
import W from "./BaseFloatingLabel.js";
|
|
3
3
|
import { useFloatingLabel as X } from "../composables/useFloatingLabel.js";
|
|
4
|
-
const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "
|
|
4
|
+
const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "readonly", "type", "pattern", "min", "max", "maxlength", "inputmode", "placeholder", "value"], Z = { class: "uikit-invisible uikit-float-none uikit-mb-2 uikit-ml-2 uikit-block uikit-h-3 uikit-w-auto uikit-max-w-full uikit-overflow-hidden uikit-whitespace-nowrap uikit-p-0 uikit-text uikit-transition-[max-width] uikit-duration-[50ms] uikit-ease-out" }, U = ["innerHTML"], p = ["innerHTML"], _ = ["innerHTML"], ee = {
|
|
5
5
|
key: 1,
|
|
6
6
|
class: "under-label uikit-absolute uikit-text-12"
|
|
7
7
|
}, ne = /* @__PURE__ */ A({
|
|
@@ -35,8 +35,8 @@ const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby
|
|
|
35
35
|
handleFocusOut: $,
|
|
36
36
|
setInlineLabel: I,
|
|
37
37
|
setFloatingLabel: V
|
|
38
|
-
} = X(k), R = O(),
|
|
39
|
-
e.feedback && (
|
|
38
|
+
} = X(k), R = O(), b = j(() => e.id || R), n = m("text"), f = m({}), c = m(null), P = () => {
|
|
39
|
+
e.feedback && (f.value = e.feedback, e.feedback.valid && typeof e.feedback.valid == "string" && (f.value.valid = [e.feedback.valid]), e.feedback.invalid && typeof e.feedback.invalid == "string" && (f.value.invalid = [e.feedback.invalid]));
|
|
40
40
|
}, L = (t, i) => {
|
|
41
41
|
if (!e.formatter || !e.formatter.formatFn)
|
|
42
42
|
return a.value = t, "";
|
|
@@ -110,7 +110,7 @@ const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby
|
|
|
110
110
|
curType: n.value
|
|
111
111
|
}, void 0, !0),
|
|
112
112
|
g("input", {
|
|
113
|
-
id:
|
|
113
|
+
id: b.value,
|
|
114
114
|
ref_key: "baseInputEl",
|
|
115
115
|
ref: c,
|
|
116
116
|
"data-cy": e.dataCy,
|
|
@@ -130,7 +130,6 @@ const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby
|
|
|
130
130
|
]]),
|
|
131
131
|
autocomplete: t.$attrs.autocomplete === "on" ? "on" : "off",
|
|
132
132
|
disabled: t.$attrs.disabled,
|
|
133
|
-
"aria-labelledby": f.value,
|
|
134
133
|
readonly: t.$attrs.readonly,
|
|
135
134
|
type: n.value,
|
|
136
135
|
pattern: t.$attrs.pattern,
|
|
@@ -178,7 +177,7 @@ const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby
|
|
|
178
177
|
], 2),
|
|
179
178
|
e.labelText ? (u(), Q(W, {
|
|
180
179
|
key: 0,
|
|
181
|
-
for:
|
|
180
|
+
for: b.value,
|
|
182
181
|
"label-text": e.labelText,
|
|
183
182
|
"label-state": d(s),
|
|
184
183
|
"is-valid": e.isValid,
|
|
@@ -191,12 +190,12 @@ const Y = ["id", "data-cy", "name", "autocomplete", "disabled", "aria-labelledby
|
|
|
191
190
|
"label-text-classes": e.labelTextClasses
|
|
192
191
|
}, null, 8, ["for", "label-text", "label-state", "is-valid", "required", "disabled", "label-classes", "label-text-classes"])) : x("", !0),
|
|
193
192
|
h(t.$slots, "feedback", {}, () => [
|
|
194
|
-
e.isValid === !1 ? (u(!0), r(C, { key: 0 }, T(
|
|
195
|
-
key: `${
|
|
193
|
+
e.isValid === !1 ? (u(!0), r(C, { key: 0 }, T(f.value.invalid, (l, w) => (u(), r("div", {
|
|
194
|
+
key: `${b.value}_invalid_${w}`,
|
|
196
195
|
class: "uikit-mt-1 uikit-text-12 uikit-text-w-danger",
|
|
197
196
|
innerHTML: l
|
|
198
|
-
}, null, 8, p))), 128)) : e.isValid === !0 ? (u(!0), r(C, { key: 1 }, T(
|
|
199
|
-
key: `${
|
|
197
|
+
}, null, 8, p))), 128)) : e.isValid === !0 ? (u(!0), r(C, { key: 1 }, T(f.value.valid, (l, w) => (u(), r("div", {
|
|
198
|
+
key: `${b.value}_valid_${w}`,
|
|
200
199
|
class: "uikit-mt-1 uikit-text-12 uikit-text-w-primary",
|
|
201
200
|
innerHTML: l
|
|
202
201
|
}, null, 8, _))), 128)) : x("", !0)
|
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
import { Optional } from '@wikicasa-dev/types';
|
|
2
|
-
|
|
3
|
-
export type BaseToggleProps = Omit<_SwitchRootProps, "modelValue">;
|
|
4
|
-
declare const _default: typeof __VLS_export;
|
|
5
|
-
export default _default;
|
|
6
|
-
declare const __VLS_export: __VLS_WithSlots<import('vue').DefineComponent<{
|
|
2
|
+
type __VLS_Props = {
|
|
7
3
|
label?: string;
|
|
8
4
|
dataCy?: string;
|
|
9
|
-
}
|
|
5
|
+
};
|
|
6
|
+
type __VLS_ModelProps = {
|
|
10
7
|
modelValue?: Optional<boolean>;
|
|
11
|
-
}
|
|
8
|
+
};
|
|
9
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
10
|
+
declare var __VLS_1: {}, __VLS_14: {};
|
|
11
|
+
type __VLS_Slots = {} & {
|
|
12
|
+
leftLabel?: (props: typeof __VLS_1) => any;
|
|
13
|
+
} & {
|
|
14
|
+
rightLabel?: (props: typeof __VLS_14) => any;
|
|
15
|
+
};
|
|
16
|
+
declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
12
17
|
"update:modelValue": (value: Optional<boolean>) => any;
|
|
13
|
-
}, string, import('vue').PublicProps, Readonly<{
|
|
14
|
-
label?: string;
|
|
15
|
-
dataCy?: string;
|
|
16
|
-
} & BaseToggleProps & {
|
|
17
|
-
modelValue?: Optional<boolean>;
|
|
18
|
-
}> & Readonly<{
|
|
18
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
19
19
|
"onUpdate:modelValue"?: ((value: Optional<boolean>) => any) | undefined;
|
|
20
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}>;
|
|
20
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
21
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
22
|
+
declare const _default: typeof __VLS_export;
|
|
23
|
+
export default _default;
|
|
25
24
|
type __VLS_WithSlots<T, S> = T & {
|
|
26
25
|
new (): {
|
|
27
26
|
$slots: S;
|
|
@@ -1,42 +1,32 @@
|
|
|
1
|
-
import { defineComponent as d, useModel as
|
|
2
|
-
import { SwitchRoot as
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as d, useModel as s, openBlock as n, createElementBlock as k, renderSlot as a, createVNode as u, unref as o, withCtx as c, createElementVNode as m, createCommentVNode as f, mergeModels as p } from "vue";
|
|
2
|
+
import { SwitchRoot as b, SwitchThumb as h } from "reka-ui";
|
|
3
|
+
const g = { class: "uikit-flex uikit-items-center uikit-gap-[8px]" }, w = ["innerHTML"], V = /* @__PURE__ */ d({
|
|
4
4
|
__name: "BaseToggle",
|
|
5
|
-
props: /* @__PURE__ */
|
|
5
|
+
props: /* @__PURE__ */ p({
|
|
6
6
|
label: {},
|
|
7
|
-
dataCy: {}
|
|
8
|
-
defaultValue: {},
|
|
9
|
-
disabled: { type: Boolean },
|
|
10
|
-
id: {},
|
|
11
|
-
value: {},
|
|
12
|
-
trueValue: {},
|
|
13
|
-
falseValue: {},
|
|
14
|
-
asChild: { type: Boolean },
|
|
15
|
-
as: {},
|
|
16
|
-
name: {},
|
|
17
|
-
required: { type: Boolean }
|
|
7
|
+
dataCy: {}
|
|
18
8
|
}, {
|
|
19
9
|
modelValue: { type: Boolean, default: !1 },
|
|
20
10
|
modelModifiers: {}
|
|
21
11
|
}),
|
|
22
12
|
emits: ["update:modelValue"],
|
|
23
13
|
setup(e) {
|
|
24
|
-
const i =
|
|
25
|
-
return (t,
|
|
26
|
-
|
|
27
|
-
u(o(
|
|
14
|
+
const i = s(e, "modelValue");
|
|
15
|
+
return (t, l) => (n(), k("div", g, [
|
|
16
|
+
a(t.$slots, "leftLabel"),
|
|
17
|
+
u(o(b), {
|
|
28
18
|
modelValue: i.value,
|
|
29
|
-
"onUpdate:modelValue":
|
|
19
|
+
"onUpdate:modelValue": l[0] || (l[0] = (r) => i.value = r),
|
|
30
20
|
"data-cy": e.dataCy,
|
|
31
21
|
class: "uikit-flex uikit-h-[20px] uikit-w-[40px] uikit-cursor-pointer uikit-rounded-full uikit-p-0 uikit-transition-[background] uikit-will-change-[background] focus-visible:uikit-outline-w-primary data-[state=checked]:uikit-bg-w-primary data-[state=unchecked]:uikit-bg-w-cultured"
|
|
32
|
-
},
|
|
33
|
-
default:
|
|
34
|
-
u(o(
|
|
22
|
+
}, {
|
|
23
|
+
default: c(() => [
|
|
24
|
+
u(o(h), { class: "uikit-box-border uikit-flex uikit-size-[20px] uikit-translate-x-0 uikit-items-center uikit-justify-center uikit-rounded-full uikit-border uikit-border-solid uikit-border-w-lightgray uikit-bg-white uikit-shadow-xl uikit-transition-transform uikit-will-change-transform data-[state=checked]:uikit-translate-x-full" })
|
|
35
25
|
]),
|
|
36
26
|
_: 1
|
|
37
|
-
},
|
|
38
|
-
t.$slots.leftLabel ?
|
|
39
|
-
|
|
27
|
+
}, 8, ["modelValue", "data-cy"]),
|
|
28
|
+
t.$slots.leftLabel ? f("", !0) : a(t.$slots, "rightLabel", { key: 0 }, () => [
|
|
29
|
+
m("span", {
|
|
40
30
|
class: "uikit-ml-[10px]",
|
|
41
31
|
innerHTML: e.label
|
|
42
32
|
}, null, 8, w)
|
|
@@ -45,5 +35,5 @@ const V = { class: "uikit-flex uikit-items-center uikit-gap-[8px]" }, w = ["inne
|
|
|
45
35
|
}
|
|
46
36
|
});
|
|
47
37
|
export {
|
|
48
|
-
|
|
38
|
+
V as default
|
|
49
39
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.input-wrapper[data-v-
|
|
1
|
+
.input-wrapper[data-v-f25fc601]{--icon-default-size: 44px}.invalid-bg[data-v-f25fc601]{--invalid-img: url(data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHdpZHRoPScxMicgaGVpZ2h0PScxMicgZmlsbD0nbm9uZScgc3Ryb2tlPScjRkE0RjY0Jz48Y2lyY2xlIGN4PSc2JyBjeT0nNicgcj0nNC41Jy8+PHBhdGggc3Ryb2tlLWxpbmVqb2luPSdyb3VuZCcgZD0nTTUuOCAzLjZoLjRMNiA2LjV6Jy8+PGNpcmNsZSBjeD0nNicgY3k9JzguMicgcj0nLjYnIGZpbGw9JyNGQTRGNjQnIHN0cm9rZT0nbm9uZScvPjwvc3ZnPg==);background-image:var(--invalid-img)}.valid-bg[data-v-f25fc601]{--valid-img: url(data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHZpZXdCb3g9JzAgMCA4IDgnPjxwYXRoIGZpbGw9JyMyQjVERkYnIGQ9J00yLjMgNi43My42IDQuNTNjLS40LTEuMDQuNDYtMS40IDEuMS0uOGwxLjEgMS40IDMuNC0zLjhjLjYtLjYzIDEuNi0uMjcgMS4yLjdsLTQgNC42Yy0uNDMuNS0uOC40LTEuMS4xeicvPjwvc3ZnPg==);background-image:var(--valid-img)}.invalid-bg[data-v-f25fc601],.valid-bg[data-v-f25fc601]{background-position:top 10px right 12px;background-size:20px}.has-right-icon[data-v-f25fc601]>label.inline-label{right:var(--icon-default-size)}.has-left-icon[data-v-f25fc601]>label.inline-label{left:var(--icon-default-size)}[data-v-f25fc601] .text-input-icon{position:absolute;z-index:20;box-sizing:border-box;--icon-size-sm: 16px;--icon-size-md: 20px;--icon-size-lg: 25px}[data-v-f25fc601] .text-input-icon.left{left:5px}[data-v-f25fc601] .text-input-icon.right{right:5px}[data-v-f25fc601] .text-input-icon{--icon-top: 5px;--icon-size: var(--icon-size-sm);width:var(--icon-default-size);height:var(--icon-default-size);padding:calc((var(--icon-default-size) - var(--icon-size)) / 2);top:var(--icon-top)}[data-v-f25fc601] .text-input-icon.md{--icon-size: var(--icon-size-md)}[data-v-f25fc601] .text-input-icon.lg{--icon-top: 0;--icon-size: var(--icon-size-lg)}.under-label[data-v-f25fc601]{left:4px;font-style:italic}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
.swiper-pagination-bullet{--swiper-pagination-color: #ccc}.swiper-pagination-bullet-active{--swiper-pagination-color: #fff}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.no-transition[data-v-c4229b26]{transition-duration:0ms!important}.disable-select[data-v-c4229b26]{-webkit-user-select:none;-moz-user-select:none;user-select:none}.swiper-button-disabled[data-v-c4229b26]{pointer-events:auto!important}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import o from "./SwiperCarousel.vue.js";
|
|
2
|
-
import '../../assets/
|
|
2
|
+
import '../../assets/SwiperCarousel2.css';import '../../assets/SwiperCarousel.css';/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
import r from "../../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-c4229b26"]]);
|
package/dist/index.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export { default as BaseComplexToggle } from './UIKit/BaseComplexToggle';
|
|
|
34
34
|
export { default as BaseDropDown } from './UIKit/BaseDropDown';
|
|
35
35
|
export { default as BaseFloatingLabel } from './UIKit/BaseFloatingLabel';
|
|
36
36
|
export { default as BaseInput } from './UIKit/BaseInput';
|
|
37
|
+
export type { BaseInputModelValue, BaseInputFormatter, } from './UIKit/BaseInput';
|
|
37
38
|
export { default as BasePagination } from './UIKit/BasePagination';
|
|
38
39
|
export { default as BaseSlider } from './UIKit/BaseSlider';
|
|
39
40
|
export { default as BaseTextarea } from './UIKit/BaseTextarea';
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { default as P } from "./UIKit/Accordion/BaseAccordion.vue.js";
|
|
2
2
|
import { default as S } from "./UIKit/Accordion/BaseAccordionItem.vue.js";
|
|
3
|
-
import './assets/baseCard.css';import './assets/SwiperSlideImagePrimitive.css';import './assets/
|
|
3
|
+
import './assets/baseCard.css';import './assets/SwiperSlideImagePrimitive.css';import './assets/SwiperCarousel.css';import './assets/BaseSnackbar.css';import './assets/baseModal.css';import './assets/BaseDropDown.css';import './assets/BaseBadge.css';import './assets/ClearableAutocomplete.css';import './assets/BaseAutocomplete.css';import './assets/baseAlert.css';import './assets/AccessibleSelect.css';import './assets/RadioButtonItem.css';import './assets/BaseTabsIndicator.css';import './assets/BaseTabs.css';import './assets/CheckboxBtn.css';import './assets/BaseAccordionItem.css';/* empty css */
|
|
4
4
|
import { default as I } from "./UIKit/Accordion/AccordionItemPrimitive.vue.js";
|
|
5
5
|
import { default as h } from "./UIKit/Accordion/AccordionHeaderPrimitive.vue.js";
|
|
6
6
|
import { default as w } from "./UIKit/Accordion/AccordionTriggerPrimitive.vue.js";
|
package/dist/types/index.d.ts
CHANGED
|
@@ -31,4 +31,3 @@ export type { SwiperSlideImagePrimitiveProps } from '../components/carousel/Prim
|
|
|
31
31
|
export type { IntersectionObserverProviderProps } from '../components/IntersectionObserver/v2/IntersectionObserverProvider';
|
|
32
32
|
export type { BaseCardRootProps, CardRootTypes, } from '../UIKit/Card/CardRootPrimitive';
|
|
33
33
|
export type { CardTypes } from '../UIKit/Card/type';
|
|
34
|
-
export type { BaseToggleProps } from '../UIKit/BaseToggle';
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.swiper-pagination-bullet{--swiper-pagination-color: #ccc}.swiper-pagination-bullet-active{--swiper-pagination-color: #fff}
|
|
File without changes
|