pukaad-ui-lib 1.446.0 → 1.448.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.
Files changed (37) hide show
  1. package/dist/module.json +1 -1
  2. package/dist/runtime/components/card/card-file.d.vue.ts +1 -0
  3. package/dist/runtime/components/card/card-file.vue +8 -2
  4. package/dist/runtime/components/card/card-file.vue.d.ts +1 -0
  5. package/dist/runtime/components/chat/chat-conversation-item.d.vue.ts +2 -2
  6. package/dist/runtime/components/chat/chat-conversation-item.vue.d.ts +2 -2
  7. package/dist/runtime/components/display/display-video.d.vue.ts +4 -4
  8. package/dist/runtime/components/display/display-video.vue.d.ts +4 -4
  9. package/dist/runtime/components/image/image-cropper.d.vue.ts +2 -2
  10. package/dist/runtime/components/image/image-cropper.vue.d.ts +2 -2
  11. package/dist/runtime/components/input/input-address.d.vue.ts +1 -1
  12. package/dist/runtime/components/input/input-address.vue.d.ts +1 -1
  13. package/dist/runtime/components/input/input-autocomplete.d.vue.ts +2 -2
  14. package/dist/runtime/components/input/input-autocomplete.vue.d.ts +2 -2
  15. package/dist/runtime/components/input/input-birth-date.d.vue.ts +1 -1
  16. package/dist/runtime/components/input/input-birth-date.vue.d.ts +1 -1
  17. package/dist/runtime/components/input/input-combobox.d.vue.ts +1 -1
  18. package/dist/runtime/components/input/input-combobox.vue.d.ts +1 -1
  19. package/dist/runtime/components/input/input-date-picker.d.vue.ts +1 -1
  20. package/dist/runtime/components/input/input-date-picker.vue.d.ts +1 -1
  21. package/dist/runtime/components/input/input-localized-name.d.vue.ts +1 -1
  22. package/dist/runtime/components/input/input-localized-name.vue.d.ts +1 -1
  23. package/dist/runtime/components/input/input-radio.d.vue.ts +1 -0
  24. package/dist/runtime/components/input/input-radio.vue +9 -2
  25. package/dist/runtime/components/input/input-radio.vue.d.ts +1 -0
  26. package/dist/runtime/components/input/input-suggest.d.vue.ts +1 -1
  27. package/dist/runtime/components/input/input-suggest.vue.d.ts +1 -1
  28. package/dist/runtime/components/input/input-tag-modal.d.vue.ts +1 -1
  29. package/dist/runtime/components/input/input-tag-modal.vue.d.ts +1 -1
  30. package/dist/runtime/components/input/input-tag.d.vue.ts +1 -1
  31. package/dist/runtime/components/input/input-tag.vue.d.ts +1 -1
  32. package/dist/runtime/components/input/input-textarea.d.vue.ts +1 -1
  33. package/dist/runtime/components/input/input-textarea.vue.d.ts +1 -1
  34. package/dist/runtime/components/timeline.d.vue.ts +13 -3
  35. package/dist/runtime/components/timeline.vue +14 -5
  36. package/dist/runtime/components/timeline.vue.d.ts +13 -3
  37. package/package.json +1 -1
package/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
3
  "configKey": "pukaadUI",
4
- "version": "1.446.0",
4
+ "version": "1.448.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -2,6 +2,7 @@ import type { HTMLAttributes } from "vue";
2
2
  export interface CardFileProps {
3
3
  class?: HTMLAttributes["class"];
4
4
  fileName?: string;
5
+ contentType?: string;
5
6
  /** bytes (number) หรือข้อความสำเร็จรูป เช่น "57KB" — แสดงเฉพาะ layout horizontal */
6
7
  fileSize?: number | string;
7
8
  layout?: "horizontal" | "vertical";
@@ -11,7 +11,7 @@
11
11
  :title="props.fileName"
12
12
  >
13
13
  <div class="size-[32px] shrink-0 flex items-center justify-center">
14
- <Icon name="pukaad:file-pdf" class="w-[24px] h-[32px]" />
14
+ <Icon :name="fileIcon" class="w-[24px] h-[32px]" />
15
15
  </div>
16
16
  <span class="font-body-small text-black text-center w-full truncate">
17
17
  {{ props.fileName }}
@@ -30,7 +30,7 @@
30
30
  :title="props.fileName"
31
31
  >
32
32
  <div class="size-[40px] shrink-0 flex items-center justify-center">
33
- <Icon name="pukaad:file-pdf" class="w-[30px] h-[40px]" />
33
+ <Icon :name="fileIcon" class="w-[30px] h-[40px]" />
34
34
  </div>
35
35
 
36
36
  <div class="flex flex-col gap-[4px] items-start justify-center">
@@ -52,10 +52,16 @@ import { cn } from "#pukaad-ui/runtime/plugins/shadcn";
52
52
  const props = defineProps({
53
53
  class: { type: null, required: false },
54
54
  fileName: { type: String, required: false, default: "" },
55
+ contentType: { type: String, required: false },
55
56
  fileSize: { type: [Number, String], required: false, default: "" },
56
57
  layout: { type: String, required: false, default: "horizontal" }
57
58
  });
58
59
  const isVertical = computed(() => props.layout === "vertical");
60
+ const fileIcon = computed(() => {
61
+ const mime = props.contentType?.split(";")[0]?.trim().toLowerCase();
62
+ const isImage = mime ? mime.startsWith("image/") : /\.(jpe?g|png|webp|bmp|gif)$/i.test(props.fileName || "");
63
+ return isImage ? "pukaad:file-jpg" : "pukaad:file-pdf";
64
+ });
59
65
  const displaySize = computed(() => {
60
66
  const size = props.fileSize;
61
67
  if (!size) return "";
@@ -2,6 +2,7 @@ import type { HTMLAttributes } from "vue";
2
2
  export interface CardFileProps {
3
3
  class?: HTMLAttributes["class"];
4
4
  fileName?: string;
5
+ contentType?: string;
5
6
  /** bytes (number) หรือข้อความสำเร็จรูป เช่น "57KB" — แสดงเฉพาะ layout horizontal */
6
7
  fileSize?: number | string;
7
8
  layout?: "horizontal" | "vertical";
@@ -27,12 +27,12 @@ declare const __VLS_export: import("vue").DefineComponent<ChatConversationItemPr
27
27
  avatar: string | null;
28
28
  muted: boolean;
29
29
  disabledMenu: boolean;
30
+ unreadCount: number;
31
+ pinned: boolean;
30
32
  preview: string;
31
33
  to: string;
32
34
  active: boolean;
33
35
  typing: boolean;
34
- unreadCount: number;
35
- pinned: boolean;
36
36
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
37
37
  declare const _default: typeof __VLS_export;
38
38
  export default _default;
@@ -27,12 +27,12 @@ declare const __VLS_export: import("vue").DefineComponent<ChatConversationItemPr
27
27
  avatar: string | null;
28
28
  muted: boolean;
29
29
  disabledMenu: boolean;
30
+ unreadCount: number;
31
+ pinned: boolean;
30
32
  preview: string;
31
33
  to: string;
32
34
  active: boolean;
33
35
  typing: boolean;
34
- unreadCount: number;
35
- pinned: boolean;
36
36
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
37
37
  declare const _default: typeof __VLS_export;
38
38
  export default _default;
@@ -81,16 +81,16 @@ declare const __VLS_base: import("vue").DefineComponent<DisplayVideoProps, {
81
81
  toggle: () => void;
82
82
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
83
83
  close: (payload: DisplayVideoAction) => any;
84
- prev: (payload: DisplayVideoAction) => any;
85
- next: (payload: DisplayVideoAction) => any;
86
84
  fullscreen: (payload: DisplayVideoAction) => any;
87
85
  "play-click": (payload: DisplayVideoAction) => any;
86
+ prev: (payload: DisplayVideoAction) => any;
87
+ next: (payload: DisplayVideoAction) => any;
88
88
  }, string, import("vue").PublicProps, Readonly<DisplayVideoProps> & Readonly<{
89
89
  onClose?: ((payload: DisplayVideoAction) => any) | undefined;
90
- onPrev?: ((payload: DisplayVideoAction) => any) | undefined;
91
- onNext?: ((payload: DisplayVideoAction) => any) | undefined;
92
90
  onFullscreen?: ((payload: DisplayVideoAction) => any) | undefined;
93
91
  "onPlay-click"?: ((payload: DisplayVideoAction) => any) | undefined;
92
+ onPrev?: ((payload: DisplayVideoAction) => any) | undefined;
93
+ onNext?: ((payload: DisplayVideoAction) => any) | undefined;
94
94
  }>, {
95
95
  src: string;
96
96
  fullHeight: boolean;
@@ -81,16 +81,16 @@ declare const __VLS_base: import("vue").DefineComponent<DisplayVideoProps, {
81
81
  toggle: () => void;
82
82
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
83
83
  close: (payload: DisplayVideoAction) => any;
84
- prev: (payload: DisplayVideoAction) => any;
85
- next: (payload: DisplayVideoAction) => any;
86
84
  fullscreen: (payload: DisplayVideoAction) => any;
87
85
  "play-click": (payload: DisplayVideoAction) => any;
86
+ prev: (payload: DisplayVideoAction) => any;
87
+ next: (payload: DisplayVideoAction) => any;
88
88
  }, string, import("vue").PublicProps, Readonly<DisplayVideoProps> & Readonly<{
89
89
  onClose?: ((payload: DisplayVideoAction) => any) | undefined;
90
- onPrev?: ((payload: DisplayVideoAction) => any) | undefined;
91
- onNext?: ((payload: DisplayVideoAction) => any) | undefined;
92
90
  onFullscreen?: ((payload: DisplayVideoAction) => any) | undefined;
93
91
  "onPlay-click"?: ((payload: DisplayVideoAction) => any) | undefined;
92
+ onPrev?: ((payload: DisplayVideoAction) => any) | undefined;
93
+ onNext?: ((payload: DisplayVideoAction) => any) | undefined;
94
94
  }>, {
95
95
  src: string;
96
96
  fullHeight: boolean;
@@ -65,14 +65,14 @@ declare const __VLS_export: import("vue").DefineComponent<ImageCropperProps, {
65
65
  src: string;
66
66
  center: boolean;
67
67
  crossorigin: "" | "anonymous" | "use-credentials";
68
+ background: boolean;
69
+ modal: boolean;
68
70
  responsive: boolean;
69
71
  restore: boolean;
70
72
  checkCrossOrigin: boolean;
71
73
  checkOrientation: boolean;
72
- modal: boolean;
73
74
  guides: boolean;
74
75
  highlight: boolean;
75
- background: boolean;
76
76
  autoCrop: boolean;
77
77
  movable: boolean;
78
78
  rotatable: boolean;
@@ -65,14 +65,14 @@ declare const __VLS_export: import("vue").DefineComponent<ImageCropperProps, {
65
65
  src: string;
66
66
  center: boolean;
67
67
  crossorigin: "" | "anonymous" | "use-credentials";
68
+ background: boolean;
69
+ modal: boolean;
68
70
  responsive: boolean;
69
71
  restore: boolean;
70
72
  checkCrossOrigin: boolean;
71
73
  checkOrientation: boolean;
72
- modal: boolean;
73
74
  guides: boolean;
74
75
  highlight: boolean;
75
- background: boolean;
76
76
  autoCrop: boolean;
77
77
  movable: boolean;
78
78
  rotatable: boolean;
@@ -50,8 +50,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
50
50
  label: string;
51
51
  name: string;
52
52
  required: boolean;
53
- placeholder: string;
54
53
  layout: "vertical" | "horizontal";
54
+ placeholder: string;
55
55
  labelDetail: string;
56
56
  placeholderDetail: string;
57
57
  requiredDetail: boolean;
@@ -50,8 +50,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
50
50
  label: string;
51
51
  name: string;
52
52
  required: boolean;
53
- placeholder: string;
54
53
  layout: "vertical" | "horizontal";
54
+ placeholder: string;
55
55
  labelDetail: string;
56
56
  placeholderDetail: string;
57
57
  requiredDetail: boolean;
@@ -69,10 +69,10 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
69
69
  name: string;
70
70
  required: boolean;
71
71
  description: string;
72
- labelKey: string;
73
- placeholder: string;
74
72
  options: AutocompleteOption[] | string[] | number[];
75
73
  limit: number;
74
+ labelKey: string;
75
+ placeholder: string;
76
76
  disabledErrorMessage: boolean;
77
77
  disabledBorder: boolean;
78
78
  showCounter: boolean;
@@ -69,10 +69,10 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
69
69
  name: string;
70
70
  required: boolean;
71
71
  description: string;
72
- labelKey: string;
73
- placeholder: string;
74
72
  options: AutocompleteOption[] | string[] | number[];
75
73
  limit: number;
74
+ labelKey: string;
75
+ placeholder: string;
76
76
  disabledErrorMessage: boolean;
77
77
  disabledBorder: boolean;
78
78
  showCounter: boolean;
@@ -30,9 +30,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
30
30
  id: string;
31
31
  name: string;
32
32
  required: boolean;
33
+ layout: "month-and-year" | "month-only" | "year-only";
33
34
  locale: string;
34
35
  placeholder: string;
35
- layout: "month-and-year" | "month-only" | "year-only";
36
36
  disabledErrorMessage: boolean;
37
37
  dateFormat: string;
38
38
  minAge: number;
@@ -30,9 +30,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
30
30
  id: string;
31
31
  name: string;
32
32
  required: boolean;
33
+ layout: "month-and-year" | "month-only" | "year-only";
33
34
  locale: string;
34
35
  placeholder: string;
35
- layout: "month-and-year" | "month-only" | "year-only";
36
36
  disabledErrorMessage: boolean;
37
37
  dateFormat: string;
38
38
  minAge: number;
@@ -59,8 +59,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
59
59
  }>, {
60
60
  pageSize: number;
61
61
  name: string;
62
- labelKey: string;
63
62
  limit: number;
63
+ labelKey: string;
64
64
  valueKey: string;
65
65
  multiple: boolean;
66
66
  placeholderSearch: string;
@@ -59,8 +59,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
59
59
  }>, {
60
60
  pageSize: number;
61
61
  name: string;
62
- labelKey: string;
63
62
  limit: number;
63
+ labelKey: string;
64
64
  valueKey: string;
65
65
  multiple: boolean;
66
66
  placeholderSearch: string;
@@ -44,9 +44,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
44
44
  id: string;
45
45
  name: string;
46
46
  required: boolean;
47
+ layout: "month-and-year" | "month-only" | "year-only";
47
48
  locale: string;
48
49
  placeholder: string;
49
- layout: "month-and-year" | "month-only" | "year-only";
50
50
  disabledErrorMessage: boolean;
51
51
  dateFormat: string;
52
52
  showTime: boolean;
@@ -44,9 +44,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
44
44
  id: string;
45
45
  name: string;
46
46
  required: boolean;
47
+ layout: "month-and-year" | "month-only" | "year-only";
47
48
  locale: string;
48
49
  placeholder: string;
49
- layout: "month-and-year" | "month-only" | "year-only";
50
50
  disabledErrorMessage: boolean;
51
51
  dateFormat: string;
52
52
  showTime: boolean;
@@ -11,9 +11,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {
11
11
  label: string;
12
12
  name: string;
13
13
  modelValue: LocalizedNameItem[];
14
- placeholder: string;
15
14
  options: InputSelectItem[];
16
15
  limit: number;
16
+ placeholder: string;
17
17
  showCounter: boolean;
18
18
  addLabel: string;
19
19
  removable: boolean;
@@ -11,9 +11,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {
11
11
  label: string;
12
12
  name: string;
13
13
  modelValue: LocalizedNameItem[];
14
- placeholder: string;
15
14
  options: InputSelectItem[];
16
15
  limit: number;
16
+ placeholder: string;
17
17
  showCounter: boolean;
18
18
  addLabel: string;
19
19
  removable: boolean;
@@ -30,6 +30,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
30
30
  "onUpdate:modelValue"?: ((value: string | number | undefined) => any) | undefined;
31
31
  }>, {
32
32
  size: number | string;
33
+ color: import("#pukaad-ui/types/components/input/input-radio").InputRadioColor;
33
34
  disabled: boolean;
34
35
  items: import("#pukaad-ui/types/components/input/input-radio").InputRadioItem[] | string[] | number[];
35
36
  item: string | number;
@@ -18,7 +18,7 @@
18
18
  </template>
19
19
 
20
20
  <input v-bind="field"
21
- :class="['appearance-none rounded-full border border-black bg-white checked:border-primary checked:bg-primary checked:shadow-[inset_0_0_0_2px_white] cursor-pointer shrink-0', cursor]"
21
+ :class="['appearance-none rounded-full border border-black bg-white checked:shadow-[inset_0_0_0_2px_white] cursor-pointer shrink-0', colorClass, cursor]"
22
22
  type="radio" :name="props.name" :style="{ width: `${props.size}px`, height: `${props.size}px` }"
23
23
  :value="typeof item === 'object' ? item.value : item" :disabled="
24
24
  props.disabled || typeof item === 'object' && item.disabled
@@ -84,9 +84,16 @@ const props = defineProps({
84
84
  item: { type: [String, Number], required: false, default: () => "" },
85
85
  disabled: { type: Boolean, required: false, default: false },
86
86
  standalone: { type: Boolean, required: false, default: false },
87
- disabledErrorMessage: { type: Boolean, required: false, default: false }
87
+ disabledErrorMessage: { type: Boolean, required: false, default: false },
88
+ color: { type: String, required: false, default: "primary" }
88
89
  });
89
90
  const modelValue = defineModel({ type: [String, Number] });
91
+ const colorClass = computed(() => {
92
+ if (props.color === "destructive") {
93
+ return "checked:border-destructive checked:bg-destructive";
94
+ }
95
+ return "checked:border-primary checked:bg-primary";
96
+ });
90
97
  const items = computed(() => {
91
98
  if (!Array.isArray(props.items)) return [];
92
99
  const arr = props.items.map((item) => {
@@ -30,6 +30,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
30
30
  "onUpdate:modelValue"?: ((value: string | number | undefined) => any) | undefined;
31
31
  }>, {
32
32
  size: number | string;
33
+ color: import("#pukaad-ui/types/components/input/input-radio").InputRadioColor;
33
34
  disabled: boolean;
34
35
  items: import("#pukaad-ui/types/components/input/input-radio").InputRadioItem[] | string[] | number[];
35
36
  item: string | number;
@@ -20,9 +20,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
20
20
  name: string;
21
21
  required: boolean;
22
22
  description: string;
23
+ limit: number;
23
24
  labelKey: string;
24
25
  placeholder: string;
25
- limit: number;
26
26
  disabledErrorMessage: boolean;
27
27
  disabledBorder: boolean;
28
28
  showCounter: boolean;
@@ -20,9 +20,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
20
20
  name: string;
21
21
  required: boolean;
22
22
  description: string;
23
+ limit: number;
23
24
  labelKey: string;
24
25
  placeholder: string;
25
- limit: number;
26
26
  disabledErrorMessage: boolean;
27
27
  disabledBorder: boolean;
28
28
  showCounter: boolean;
@@ -40,9 +40,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
40
40
  id: string;
41
41
  name: string;
42
42
  required: boolean;
43
+ options: InputTagModalOption[];
43
44
  labelKey: string;
44
45
  placeholder: string;
45
- options: InputTagModalOption[];
46
46
  disabledErrorMessage: boolean;
47
47
  valueKey: string;
48
48
  searchPlaceholder: string;
@@ -40,9 +40,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
40
40
  id: string;
41
41
  name: string;
42
42
  required: boolean;
43
+ options: InputTagModalOption[];
43
44
  labelKey: string;
44
45
  placeholder: string;
45
- options: InputTagModalOption[];
46
46
  disabledErrorMessage: boolean;
47
47
  valueKey: string;
48
48
  searchPlaceholder: string;
@@ -26,9 +26,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
26
26
  "onUpdate:modelValue"?: ((value: SelectedTag[]) => any) | undefined;
27
27
  }>, {
28
28
  name: string;
29
- placeholder: string;
30
29
  state: "user" | "admin";
31
30
  limit: number;
31
+ placeholder: string;
32
32
  profileScope: "personal" | "business";
33
33
  ignore: string[];
34
34
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
@@ -26,9 +26,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
26
26
  "onUpdate:modelValue"?: ((value: SelectedTag[]) => any) | undefined;
27
27
  }>, {
28
28
  name: string;
29
- placeholder: string;
30
29
  state: "user" | "admin";
31
30
  limit: number;
31
+ placeholder: string;
32
32
  profileScope: "personal" | "business";
33
33
  ignore: string[];
34
34
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
@@ -46,8 +46,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
46
46
  resize: "none" | "both" | "horizontal" | "vertical";
47
47
  fullHeight: boolean;
48
48
  fullWidth: boolean;
49
- rows: number;
50
49
  limit: number;
50
+ rows: number;
51
51
  readonly: boolean;
52
52
  disabledErrorMessage: boolean;
53
53
  disabledBorder: boolean;
@@ -46,8 +46,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
46
46
  resize: "none" | "both" | "horizontal" | "vertical";
47
47
  fullHeight: boolean;
48
48
  fullWidth: boolean;
49
- rows: number;
50
49
  limit: number;
50
+ rows: number;
51
51
  readonly: boolean;
52
52
  disabledErrorMessage: boolean;
53
53
  disabledBorder: boolean;
@@ -20,14 +20,24 @@ type __VLS_Props = {
20
20
  declare var __VLS_1: {
21
21
  item: TimelineItem;
22
22
  index: number;
23
- }, __VLS_8: {
23
+ }, __VLS_3: {
24
+ item: TimelineItem;
25
+ index: number;
26
+ }, __VLS_5: {
27
+ item: TimelineItem;
28
+ index: number;
29
+ }, __VLS_12: {
24
30
  item: TimelineItem;
25
31
  index: number;
26
32
  };
27
33
  type __VLS_Slots = {} & {
28
- content?: (props: typeof __VLS_1) => any;
34
+ dot?: (props: typeof __VLS_1) => any;
35
+ } & {
36
+ line?: (props: typeof __VLS_3) => any;
37
+ } & {
38
+ content?: (props: typeof __VLS_5) => any;
29
39
  } & {
30
- description?: (props: typeof __VLS_8) => any;
40
+ description?: (props: typeof __VLS_12) => any;
31
41
  };
32
42
  declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
33
43
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
@@ -6,11 +6,20 @@
6
6
  class="flex gap-[8px] w-full"
7
7
  >
8
8
  <!-- dot + connecting line (โครงของ component เอง) -->
9
- <div class="flex flex-col items-center w-[8px]">
10
- <div class="w-[20px] h-[26px] flex items-center justify-center">
11
- <div class="w-[10px] h-[10px] rounded-full bg-black shrink-0" />
12
- </div>
13
- <div class="w-[2px] flex-1 bg-bright" />
9
+ <div class="flex flex-col items-center shrink-0">
10
+ <slot name="dot" :item="item" :index="index">
11
+ <div class="w-[20px] h-[26px] flex items-center justify-center shrink-0">
12
+ <div class="w-[10px] h-[10px] rounded-full bg-black shrink-0" />
13
+ </div>
14
+ </slot>
15
+ <slot
16
+ v-if="index < props.items.length - 1"
17
+ name="line"
18
+ :item="item"
19
+ :index="index"
20
+ >
21
+ <div class="w-[2px] flex-1 bg-bright" />
22
+ </slot>
14
23
  </div>
15
24
 
16
25
  <!-- เนื้อหา — ปล่อยให้ผู้ใช้ครอบเองผ่าน slot ได้ ถ้าไม่ส่งมาใช้ default นี้ -->
@@ -20,14 +20,24 @@ type __VLS_Props = {
20
20
  declare var __VLS_1: {
21
21
  item: TimelineItem;
22
22
  index: number;
23
- }, __VLS_8: {
23
+ }, __VLS_3: {
24
+ item: TimelineItem;
25
+ index: number;
26
+ }, __VLS_5: {
27
+ item: TimelineItem;
28
+ index: number;
29
+ }, __VLS_12: {
24
30
  item: TimelineItem;
25
31
  index: number;
26
32
  };
27
33
  type __VLS_Slots = {} & {
28
- content?: (props: typeof __VLS_1) => any;
34
+ dot?: (props: typeof __VLS_1) => any;
35
+ } & {
36
+ line?: (props: typeof __VLS_3) => any;
37
+ } & {
38
+ content?: (props: typeof __VLS_5) => any;
29
39
  } & {
30
- description?: (props: typeof __VLS_8) => any;
40
+ description?: (props: typeof __VLS_12) => any;
31
41
  };
32
42
  declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
33
43
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
- "version": "1.446.0",
3
+ "version": "1.448.0",
4
4
  "description": "pukaad-ui for MeMSG",
5
5
  "repository": {
6
6
  "type": "git",