pukaad-ui-lib 1.259.0 → 1.261.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
3
  "configKey": "pukaadUI",
4
- "version": "1.259.0",
4
+ "version": "1.261.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -64,12 +64,12 @@ declare const __VLS_export: import("vue").DefineComponent<ImageCropperProps, {
64
64
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ImageCropperProps> & Readonly<{}>, {
65
65
  src: string;
66
66
  center: boolean;
67
- modal: boolean;
68
67
  responsive: boolean;
69
68
  restore: boolean;
70
69
  checkCrossOrigin: boolean;
71
70
  checkOrientation: boolean;
72
71
  crossorigin: "" | "anonymous" | "use-credentials";
72
+ modal: boolean;
73
73
  guides: boolean;
74
74
  highlight: boolean;
75
75
  background: boolean;
@@ -64,12 +64,12 @@ declare const __VLS_export: import("vue").DefineComponent<ImageCropperProps, {
64
64
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ImageCropperProps> & Readonly<{}>, {
65
65
  src: string;
66
66
  center: boolean;
67
- modal: boolean;
68
67
  responsive: boolean;
69
68
  restore: boolean;
70
69
  checkCrossOrigin: boolean;
71
70
  checkOrientation: boolean;
72
71
  crossorigin: "" | "anonymous" | "use-credentials";
72
+ modal: boolean;
73
73
  guides: boolean;
74
74
  highlight: boolean;
75
75
  background: boolean;
@@ -48,11 +48,11 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
48
48
  label: string;
49
49
  required: boolean;
50
50
  name: string;
51
- gap: string;
52
51
  placeholder: string;
53
52
  labelDetail: string;
54
53
  placeholderDetail: string;
55
54
  requiredDetail: boolean;
55
+ gap: string;
56
56
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
57
57
  declare const _default: typeof __VLS_export;
58
58
  export default _default;
@@ -48,11 +48,11 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
48
48
  label: string;
49
49
  required: boolean;
50
50
  name: string;
51
- gap: string;
52
51
  placeholder: string;
53
52
  labelDetail: string;
54
53
  placeholderDetail: string;
55
54
  requiredDetail: boolean;
55
+ gap: string;
56
56
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
57
57
  declare const _default: typeof __VLS_export;
58
58
  export default _default;
@@ -101,11 +101,10 @@
101
101
  </PopoverContent>
102
102
  </Popover>
103
103
  </ShadFormControl>
104
-
104
+ <ShadFormMessage v-if="!props.disabledErrorMessage" />
105
105
  <ShadFormDescription v-if="props.description" class="text-gray">
106
106
  {{ props.description }}
107
107
  </ShadFormDescription>
108
- <ShadFormMessage v-if="!props.disabledErrorMessage" />
109
108
  </ShadFormItem>
110
109
  </ShadFormField>
111
110
  </template>
@@ -35,8 +35,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
35
35
  fullHeight: boolean;
36
36
  name: string;
37
37
  limit: number;
38
- accept: string;
39
38
  disabledErrorMessage: boolean;
39
+ accept: string;
40
40
  labelIcon: string;
41
41
  disabledDrop: boolean;
42
42
  column: boolean;
@@ -35,8 +35,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
35
35
  fullHeight: boolean;
36
36
  name: string;
37
37
  limit: number;
38
- accept: string;
39
38
  disabledErrorMessage: boolean;
39
+ accept: string;
40
40
  labelIcon: string;
41
41
  disabledDrop: boolean;
42
42
  column: boolean;
@@ -22,8 +22,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
22
22
  }>, {
23
23
  id: string;
24
24
  name: string;
25
- disabledForgotPassword: boolean;
26
25
  new: boolean;
26
+ disabledForgotPassword: boolean;
27
27
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
28
28
  declare const _default: typeof __VLS_export;
29
29
  export default _default;
@@ -22,8 +22,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
22
22
  }>, {
23
23
  id: string;
24
24
  name: string;
25
- disabledForgotPassword: boolean;
26
25
  new: boolean;
26
+ disabledForgotPassword: boolean;
27
27
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
28
28
  declare const _default: typeof __VLS_export;
29
29
  export default _default;
@@ -24,8 +24,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
24
24
  }) => any) | undefined;
25
25
  }>, {
26
26
  title: string;
27
- confirmText: string;
28
27
  disabledForgotPassword: boolean;
28
+ confirmText: string;
29
29
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
30
30
  declare const _default: typeof __VLS_export;
31
31
  export default _default;
@@ -24,8 +24,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
24
24
  }) => any) | undefined;
25
25
  }>, {
26
26
  title: string;
27
- confirmText: string;
28
27
  disabledForgotPassword: boolean;
28
+ confirmText: string;
29
29
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
30
30
  declare const _default: typeof __VLS_export;
31
31
  export default _default;
@@ -28,8 +28,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
28
28
  }>, {
29
29
  title: string;
30
30
  mode: "login" | "secure";
31
- confirmText: string;
32
31
  disabledForgotPassword: boolean;
32
+ confirmText: string;
33
33
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
34
  declare const _default: typeof __VLS_export;
35
35
  export default _default;
@@ -28,8 +28,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
28
28
  }>, {
29
29
  title: string;
30
30
  mode: "login" | "secure";
31
- confirmText: string;
32
31
  disabledForgotPassword: boolean;
32
+ confirmText: string;
33
33
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
34
  declare const _default: typeof __VLS_export;
35
35
  export default _default;
@@ -1,5 +1,10 @@
1
1
  <template>
2
- <Modal title="ป้อนรหัสรักษาความปลอดภัย (OTP)" @close="emit('close')" @submit="onVerifyOTP" v-model="isOpen">
2
+ <Modal
3
+ title="ป้อนรหัสรักษาความปลอดภัย (OTP)"
4
+ @close="emit('close')"
5
+ @submit="onVerifyOTP"
6
+ v-model="isOpen"
7
+ >
3
8
  <div class="space-y-[16px]">
4
9
  <div class="text-center font-body-large">
5
10
  <div>
@@ -10,10 +15,14 @@
10
15
  </div>
11
16
 
12
17
  <div class="flex justify-center">
13
- <InputOTP name="otp" columnGap="auto" v-model="valueOTP" :error="otpError" />
18
+ <InputOTP
19
+ name="otp"
20
+ columnGap="auto"
21
+ v-model="valueOTP"
22
+ :error="otpError"
23
+ />
14
24
  </div>
15
25
 
16
-
17
26
  <div class="text-center font-body-large">
18
27
  <template v-if="countdown !== '00:00'">
19
28
  กรุณารอ <span class="text-primary">{{ countdown }}</span> นาที
@@ -21,13 +30,20 @@
21
30
  </template>
22
31
  <template v-else>
23
32
  ไม่ได้รับรหัส?
24
- <Button variant="link" color="primary" @click="onResend">ส่งรหัสอีกครั้ง</Button>
33
+ <Button variant="link" color="primary" @click="onResend"
34
+ >ส่งรหัสอีกครั้ง</Button
35
+ >
25
36
  </template>
26
37
  </div>
27
38
  </div>
28
39
 
29
40
  <template #footer="{ meta }">
30
- <Button type="submit" color="primary" :disabled="!meta.valid || isLoading" class="w-full">
41
+ <Button
42
+ type="submit"
43
+ color="primary"
44
+ :disabled="!meta.valid || isLoading"
45
+ class="w-full"
46
+ >
31
47
  {{ props.confirmedText }}
32
48
  </Button>
33
49
  </template>
@@ -69,7 +85,7 @@ const countdown = CountdownTime(expireAt);
69
85
  const handleSendOTP = async () => {
70
86
  try {
71
87
  isLoading.value = true;
72
- const path = props.requestPath ?? "/me/phone-otp-request";
88
+ const path = props.requestPath ?? "/otp/phone-request";
73
89
  const body = props.requestBody ?? { phone: props.phone };
74
90
  if (!props.requestBody && !props.phone) {
75
91
  throw new Error("\u0E01\u0E23\u0E38\u0E13\u0E32\u0E23\u0E30\u0E1A\u0E38 phone");
@@ -101,7 +117,7 @@ const onResend = () => {
101
117
  const onVerifyOTP = async () => {
102
118
  try {
103
119
  isLoading.value = true;
104
- const path = props.verifyPath ?? "/me/phone-otp-verify";
120
+ const path = props.verifyPath ?? "/otp/phone-verify";
105
121
  const body = props.verifyBody ? { ...props.verifyBody, code: valueOTP.value } : { code: valueOTP.value, phone: props.phone };
106
122
  const response = await api(path, {
107
123
  method: "POST",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
- "version": "1.259.0",
3
+ "version": "1.261.0",
4
4
  "description": "pukaad-ui for MeMSG",
5
5
  "repository": {
6
6
  "type": "git",