pukaad-ui-lib 1.175.0 → 1.177.0
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/module.json +1 -1
- package/dist/runtime/components/input/input-OTP.d.vue.ts +4 -1
- package/dist/runtime/components/input/input-OTP.vue +9 -0
- package/dist/runtime/components/input/input-OTP.vue.d.ts +4 -1
- package/dist/runtime/components/input/input-autocomplete.d.vue.ts +1 -1
- package/dist/runtime/components/input/input-autocomplete.vue.d.ts +1 -1
- package/dist/runtime/components/input/input-tag.d.vue.ts +1 -1
- package/dist/runtime/components/input/input-tag.vue.d.ts +1 -1
- package/dist/runtime/components/modal/modal-2FA.vue +2 -1
- package/dist/runtime/components/ui/accordion/Accordion.vue +3 -3
- package/dist/runtime/components/ui/accordion/AccordionContent.vue +9 -9
- package/dist/runtime/components/ui/accordion/AccordionItem.vue +8 -8
- package/dist/runtime/components/ui/accordion/AccordionTrigger.vue +16 -16
- package/package.json +2 -2
package/dist/module.json
CHANGED
|
@@ -11,7 +11,10 @@ type __VLS_ModelProps = {
|
|
|
11
11
|
modelValue?: string;
|
|
12
12
|
};
|
|
13
13
|
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
14
|
-
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
14
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
15
|
+
setErrors: (errMsg: string[]) => void;
|
|
16
|
+
fieldRef: import("vue").Ref<any, any>;
|
|
17
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
18
|
"update:modelValue": (value: string) => any;
|
|
16
19
|
complete: (value: string) => any;
|
|
17
20
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<ShadFormField
|
|
3
|
+
ref="fieldRef"
|
|
3
4
|
:rules="props.rules || defaultRules"
|
|
4
5
|
:name="props.name"
|
|
5
6
|
v-model="modelValue"
|
|
@@ -45,6 +46,7 @@ const pin = ref([]);
|
|
|
45
46
|
const modelValue = defineModel({ type: String, ...{
|
|
46
47
|
default: ""
|
|
47
48
|
} });
|
|
49
|
+
const fieldRef = ref();
|
|
48
50
|
const emit = defineEmits(["complete"]);
|
|
49
51
|
const handleComplete = (v) => {
|
|
50
52
|
const otpValue = v.join("");
|
|
@@ -62,4 +64,11 @@ watch(
|
|
|
62
64
|
immediate: true
|
|
63
65
|
}
|
|
64
66
|
);
|
|
67
|
+
const setErrors = (errMsg) => {
|
|
68
|
+
fieldRef.value?.setErrors(errMsg);
|
|
69
|
+
};
|
|
70
|
+
defineExpose({
|
|
71
|
+
setErrors,
|
|
72
|
+
fieldRef
|
|
73
|
+
});
|
|
65
74
|
</script>
|
|
@@ -11,7 +11,10 @@ type __VLS_ModelProps = {
|
|
|
11
11
|
modelValue?: string;
|
|
12
12
|
};
|
|
13
13
|
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
14
|
-
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
14
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
15
|
+
setErrors: (errMsg: string[]) => void;
|
|
16
|
+
fieldRef: import("vue").Ref<any, any>;
|
|
17
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
18
|
"update:modelValue": (value: string) => any;
|
|
16
19
|
complete: (value: string) => any;
|
|
17
20
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
@@ -37,8 +37,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
|
37
37
|
name: string;
|
|
38
38
|
description: string;
|
|
39
39
|
options: AutocompleteOption[] | string[] | number[];
|
|
40
|
-
placeholder: string;
|
|
41
40
|
limit: number;
|
|
41
|
+
placeholder: string;
|
|
42
42
|
disabledErrorMessage: boolean;
|
|
43
43
|
disabledBorder: boolean;
|
|
44
44
|
showCounter: boolean;
|
|
@@ -37,8 +37,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
|
37
37
|
name: string;
|
|
38
38
|
description: string;
|
|
39
39
|
options: AutocompleteOption[] | string[] | number[];
|
|
40
|
-
placeholder: string;
|
|
41
40
|
limit: number;
|
|
41
|
+
placeholder: string;
|
|
42
42
|
disabledErrorMessage: boolean;
|
|
43
43
|
disabledBorder: boolean;
|
|
44
44
|
showCounter: boolean;
|
|
@@ -26,8 +26,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
26
26
|
}>, {
|
|
27
27
|
name: string;
|
|
28
28
|
state: "user" | "admin";
|
|
29
|
-
placeholder: string;
|
|
30
29
|
limit: number;
|
|
30
|
+
placeholder: string;
|
|
31
31
|
ignore: string[];
|
|
32
32
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
33
33
|
declare const _default: typeof __VLS_export;
|
|
@@ -26,8 +26,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
26
26
|
}>, {
|
|
27
27
|
name: string;
|
|
28
28
|
state: "user" | "admin";
|
|
29
|
-
placeholder: string;
|
|
30
29
|
limit: number;
|
|
30
|
+
placeholder: string;
|
|
31
31
|
ignore: string[];
|
|
32
32
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
33
33
|
declare const _default: typeof __VLS_export;
|
|
@@ -58,7 +58,8 @@ const onVerify2FA = async () => {
|
|
|
58
58
|
emit("complete", data);
|
|
59
59
|
isOpen.value = false;
|
|
60
60
|
} catch (e) {
|
|
61
|
-
|
|
61
|
+
const errorMessage = e?.data?.message || "\u0E23\u0E2B\u0E31\u0E2A\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07";
|
|
62
|
+
twoFaRef.value.setErrors([errorMessage]);
|
|
62
63
|
}
|
|
63
64
|
};
|
|
64
65
|
watch(isOpen, (value) => {
|
|
@@ -20,7 +20,7 @@ const forwarded = useForwardPropsEmits(props, emits);
|
|
|
20
20
|
</script>
|
|
21
21
|
|
|
22
22
|
<template>
|
|
23
|
-
<AccordionRoot v-slot="slotProps" data-slot="accordion" v-bind="forwarded">
|
|
24
|
-
<slot v-bind="slotProps" />
|
|
25
|
-
</AccordionRoot>
|
|
23
|
+
<AccordionRoot v-slot="slotProps" data-slot="accordion" v-bind="forwarded">
|
|
24
|
+
<slot v-bind="slotProps" />
|
|
25
|
+
</AccordionRoot>
|
|
26
26
|
</template>
|
|
@@ -12,13 +12,13 @@ const delegatedProps = reactiveOmit(props, "class");
|
|
|
12
12
|
</script>
|
|
13
13
|
|
|
14
14
|
<template>
|
|
15
|
-
<AccordionContent
|
|
16
|
-
data-slot="accordion-content"
|
|
17
|
-
v-bind="delegatedProps"
|
|
18
|
-
class="data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm"
|
|
19
|
-
>
|
|
20
|
-
<div :class="cn('pt-0 pb-4', props.class)">
|
|
21
|
-
<slot />
|
|
22
|
-
</div>
|
|
23
|
-
</AccordionContent>
|
|
15
|
+
<AccordionContent
|
|
16
|
+
data-slot="accordion-content"
|
|
17
|
+
v-bind="delegatedProps"
|
|
18
|
+
class="data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm"
|
|
19
|
+
>
|
|
20
|
+
<div :class="cn('pt-0 pb-4', props.class)">
|
|
21
|
+
<slot />
|
|
22
|
+
</div>
|
|
23
|
+
</AccordionContent>
|
|
24
24
|
</template>
|
|
@@ -15,12 +15,12 @@ const forwardedProps = useForwardProps(delegatedProps);
|
|
|
15
15
|
</script>
|
|
16
16
|
|
|
17
17
|
<template>
|
|
18
|
-
<AccordionItem
|
|
19
|
-
v-slot="slotProps"
|
|
20
|
-
data-slot="accordion-item"
|
|
21
|
-
v-bind="forwardedProps"
|
|
22
|
-
:class="cn('border-b ', props.class)"
|
|
23
|
-
>
|
|
24
|
-
<slot v-bind="slotProps" />
|
|
25
|
-
</AccordionItem>
|
|
18
|
+
<AccordionItem
|
|
19
|
+
v-slot="slotProps"
|
|
20
|
+
data-slot="accordion-item"
|
|
21
|
+
v-bind="forwardedProps"
|
|
22
|
+
:class="cn('border-b ', props.class)"
|
|
23
|
+
>
|
|
24
|
+
<slot v-bind="slotProps" />
|
|
25
|
+
</AccordionItem>
|
|
26
26
|
</template>
|
|
@@ -11,25 +11,25 @@ const delegatedProps = reactiveOmit(props, "class");
|
|
|
11
11
|
</script>
|
|
12
12
|
|
|
13
13
|
<template>
|
|
14
|
-
<AccordionHeader class="flex">
|
|
15
|
-
<AccordionTrigger
|
|
16
|
-
data-slot="accordion-trigger"
|
|
17
|
-
v-bind="delegatedProps"
|
|
14
|
+
<AccordionHeader class="flex">
|
|
15
|
+
<AccordionTrigger
|
|
16
|
+
data-slot="accordion-trigger"
|
|
17
|
+
v-bind="delegatedProps"
|
|
18
18
|
:class="
|
|
19
19
|
cn(
|
|
20
20
|
'focus-visible:border-ring focus-visible:ring-ring/50 flex flex-1 items-start justify-between gap-4 rounded-md py-4 text-left text-sm font-medium transition-all outline-none hover:underline focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-180',
|
|
21
21
|
props.class
|
|
22
22
|
)
|
|
23
|
-
"
|
|
24
|
-
>
|
|
25
|
-
<slot />
|
|
26
|
-
<slot name="icon">
|
|
27
|
-
<Icon
|
|
28
|
-
name="lucide:chevron-down"
|
|
29
|
-
class="text-gray pointer-events-none shrink-0 translate-y-0.5 transition-transform duration-200"
|
|
30
|
-
:size="24"
|
|
31
|
-
/>
|
|
32
|
-
</slot>
|
|
33
|
-
</AccordionTrigger>
|
|
34
|
-
</AccordionHeader>
|
|
23
|
+
"
|
|
24
|
+
>
|
|
25
|
+
<slot />
|
|
26
|
+
<slot name="icon">
|
|
27
|
+
<Icon
|
|
28
|
+
name="lucide:chevron-down"
|
|
29
|
+
class="text-gray pointer-events-none shrink-0 translate-y-0.5 transition-transform duration-200"
|
|
30
|
+
:size="24"
|
|
31
|
+
/>
|
|
32
|
+
</slot>
|
|
33
|
+
</AccordionTrigger>
|
|
34
|
+
</AccordionHeader>
|
|
35
35
|
</template>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pukaad-ui-lib",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.177.0",
|
|
4
4
|
"description": "pukaad-ui for MeMSG",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -89,4 +89,4 @@
|
|
|
89
89
|
"@types/vue-cropperjs": "^4.1.6",
|
|
90
90
|
"@vue/compiler-sfc": "^3.5.24"
|
|
91
91
|
}
|
|
92
|
-
}
|
|
92
|
+
}
|