pukaad-ui-lib 1.227.3 → 1.229.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.227.3",
4
+ "version": "1.229.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -89,8 +89,8 @@ const listReaction = computed(() => {
89
89
  const reactions = [
90
90
  {
91
91
  name: "liked",
92
- icon: "fa6-regular:thumbs-up",
93
- iconReacted: "fa6-solid:thumbs-up",
92
+ icon: "pukaad:thumbs-up-regular",
93
+ iconReacted: "pukaad:thumbs-up-solid",
94
94
  action: toggleLike
95
95
  },
96
96
  {
@@ -93,7 +93,7 @@ watch(
93
93
  }
94
94
  );
95
95
  const onProfileClick = () => {
96
- router.push(`/${props.item.user.path_name}`);
96
+ router.push(`/@${props.item.user.path_name}`);
97
97
  };
98
98
  const onBlogPin = () => {
99
99
  isPinned.value = true;
@@ -64,15 +64,15 @@ 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
- background: boolean;
68
- modal: boolean;
69
67
  responsive: boolean;
70
68
  restore: boolean;
71
69
  checkCrossOrigin: boolean;
72
70
  checkOrientation: boolean;
73
71
  crossorigin: "" | "anonymous" | "use-credentials";
72
+ modal: boolean;
74
73
  guides: boolean;
75
74
  highlight: boolean;
75
+ background: boolean;
76
76
  autoCrop: boolean;
77
77
  movable: boolean;
78
78
  rotatable: boolean;
@@ -64,15 +64,15 @@ 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
- background: boolean;
68
- modal: boolean;
69
67
  responsive: boolean;
70
68
  restore: boolean;
71
69
  checkCrossOrigin: boolean;
72
70
  checkOrientation: boolean;
73
71
  crossorigin: "" | "anonymous" | "use-credentials";
72
+ modal: boolean;
74
73
  guides: boolean;
75
74
  highlight: boolean;
75
+ background: boolean;
76
76
  autoCrop: boolean;
77
77
  movable: boolean;
78
78
  rotatable: 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
- new: boolean;
26
25
  disabledForgotPassword: boolean;
26
+ new: 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
- new: boolean;
26
25
  disabledForgotPassword: boolean;
26
+ new: boolean;
27
27
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
28
28
  declare const _default: typeof __VLS_export;
29
29
  export default _default;
@@ -7,7 +7,7 @@
7
7
  :read-only="props.readonly"
8
8
  :rating-step="props.ratingStep"
9
9
  :rounded-corners="true"
10
- :rating-size="props.size"
10
+ :rating-size="`${props.size}px`"
11
11
  :rating-content="[
12
12
  12,
13
13
  17.27,
@@ -24,8 +24,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
24
24
  }) => any) | undefined;
25
25
  }>, {
26
26
  title: string;
27
- disabledForgotPassword: boolean;
28
27
  confirmText: string;
28
+ disabledForgotPassword: boolean;
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
- disabledForgotPassword: boolean;
28
27
  confirmText: string;
28
+ disabledForgotPassword: boolean;
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
- disabledForgotPassword: boolean;
32
31
  confirmText: string;
32
+ disabledForgotPassword: boolean;
33
33
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
34
  declare const _default: typeof __VLS_export;
35
35
  export default _default;
@@ -1,30 +1,13 @@
1
1
  <template>
2
- <Modal
3
- :title="props.title"
4
- :loading="loading"
5
- v-model="isOpen"
6
- @close="emit('close')"
7
- @submit="handleSubmit"
8
- >
2
+ <Modal :title="props.title" :loading="loading" v-model="isOpen" @close="emit('close')" @submit="handleSubmit">
9
3
  <div v-if="props.description" class="font-body-large">
10
4
  {{ props.description }}
11
5
  </div>
12
- <InputPassword
13
- ref="inputRef"
14
- disabled-forgot-password
15
- required
16
- label="รหัสผ่าน"
17
- placeholder="กรอกรหัสผ่าน"
18
- v-model="password"
19
- />
6
+ <InputPassword ref="inputRef" disabled-forgot-password required label="รหัสผ่าน" placeholder="กรอกรหัสผ่าน"
7
+ v-model="password" />
20
8
 
21
9
  <template #footer="{ meta }">
22
- <Button
23
- type="submit"
24
- color="primary"
25
- class="w-full"
26
- :disabled="!meta.valid"
27
- >
10
+ <Button type="submit" color="primary" class="w-full" :disabled="!meta.valid">
28
11
  {{ props.confirmText }}
29
12
  </Button>
30
13
  </template>
@@ -63,11 +46,11 @@ const handleSubmit = async () => {
63
46
  loading.value = true;
64
47
  try {
65
48
  if (props.mode === "secure") {
66
- const { status } = await api("/me/password-verify", {
49
+ const res = await api("/me/password-verify", {
67
50
  method: "POST",
68
51
  body: { password: password.value }
69
52
  });
70
- if (status !== "success") throw "\u0E23\u0E2B\u0E31\u0E2A\u0E1C\u0E48\u0E32\u0E19\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07";
53
+ if (res.title !== "\u0E2A\u0E33\u0E40\u0E23\u0E47\u0E08") throw "\u0E23\u0E2B\u0E31\u0E2A\u0E1C\u0E48\u0E32\u0E19\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07";
71
54
  emit("complete", { secId: "" });
72
55
  isOpen.value = false;
73
56
  } else {
@@ -83,8 +66,8 @@ const handleSubmit = async () => {
83
66
  password: password.value
84
67
  }
85
68
  });
86
- if (res.code === 200 && res.data) {
87
- emit("complete", { secId: res.data.sec_id });
69
+ if (res.title === "\u0E2A\u0E33\u0E40\u0E23\u0E47\u0E08") {
70
+ emit("complete", { secId: res.data?.sec_id || "" });
88
71
  isOpen.value = false;
89
72
  } else {
90
73
  inputRef.value?.setErrors?.(res.message || "\u0E23\u0E2B\u0E31\u0E2A\u0E1C\u0E48\u0E32\u0E19\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07");
@@ -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
- disabledForgotPassword: boolean;
32
31
  confirmText: string;
32
+ disabledForgotPassword: boolean;
33
33
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
34
  declare const _default: typeof __VLS_export;
35
35
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
- "version": "1.227.3",
3
+ "version": "1.229.0",
4
4
  "description": "pukaad-ui for MeMSG",
5
5
  "repository": {
6
6
  "type": "git",