pukaad-ui-lib 1.361.0 → 1.362.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.361.0",
4
+ "version": "1.362.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -1,3 +1,4 @@
1
+ import { type HTMLAttributes } from "vue";
1
2
  export interface MediaItem {
2
3
  id?: string | number;
3
4
  url: string;
@@ -10,6 +11,7 @@ type __VLS_Props = {
10
11
  state?: "personal" | "office" | "business";
11
12
  title?: string;
12
13
  placeId?: string | number;
14
+ class?: HTMLAttributes["class"];
13
15
  };
14
16
  declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
15
17
  title: string;
@@ -2,7 +2,7 @@
2
2
  <!-- Personal state → Featured layout — 1 รูป: w-full -->
3
3
  <div
4
4
  v-if="layoutMode === 'featured' && photos.length === 1"
5
- class="h-[360px]"
5
+ :class="cn('h-[360px]', props.class)"
6
6
  >
7
7
  <div
8
8
  class="w-full h-full rounded-[8px] overflow-hidden cursor-pointer"
@@ -20,7 +20,7 @@
20
20
  <!-- Personal state → Featured layout — 2 รูป: แบ่งครึ่ง w-full -->
21
21
  <div
22
22
  v-else-if="layoutMode === 'featured' && photos.length === 2"
23
- class="flex gap-[8px] h-[360px]"
23
+ :class="cn('flex gap-[8px] h-[360px]', props.class)"
24
24
  >
25
25
  <div
26
26
  class="flex-1 rounded-[8px] overflow-hidden cursor-pointer"
@@ -47,7 +47,10 @@
47
47
  </div>
48
48
 
49
49
  <!-- Personal state → Featured layout — 3+ รูป: layout เดิม -->
50
- <div v-else-if="layoutMode === 'featured'" class="flex gap-[8px] h-[360px]">
50
+ <div
51
+ v-else-if="layoutMode === 'featured'"
52
+ :class="cn('flex gap-[8px] h-[360px]', props.class)"
53
+ >
51
54
  <div
52
55
  v-if="photos[0]"
53
56
  class="w-[620px] shrink-0 rounded-[8px] overflow-hidden cursor-pointer"
@@ -140,7 +143,10 @@
140
143
  </div>
141
144
 
142
145
  <!-- Office / Business state → Album layout -->
143
- <div v-else-if="layoutMode === 'album'" class="grid grid-cols-5 gap-[10px]">
146
+ <div
147
+ v-else-if="layoutMode === 'album'"
148
+ :class="cn('grid grid-cols-5 gap-[10px]', props.class)"
149
+ >
144
150
  <!-- Row 1: photos[0..3] -->
145
151
  <div
146
152
  v-for="(photo, i) in galleryRow1"
@@ -229,6 +235,8 @@
229
235
  <script setup>
230
236
  import { computed, ref } from "vue";
231
237
  import { useConvert } from "../../composables/useConvert";
238
+ import { cn } from "../../plugins/shadcn";
239
+ defineOptions({ inheritAttrs: false });
232
240
  const { convertNumber } = useConvert();
233
241
  const props = defineProps({
234
242
  photos: { type: Array, required: false, default: () => [] },
@@ -236,7 +244,8 @@ const props = defineProps({
236
244
  variant: { type: String, required: false },
237
245
  state: { type: String, required: false, default: "personal" },
238
246
  title: { type: String, required: false, default: "" },
239
- placeId: { type: [String, Number], required: false }
247
+ placeId: { type: [String, Number], required: false },
248
+ class: { type: null, required: false }
240
249
  });
241
250
  const layoutMode = computed(() => {
242
251
  if (props.variant) return props.variant;
@@ -1,3 +1,4 @@
1
+ import { type HTMLAttributes } from "vue";
1
2
  export interface MediaItem {
2
3
  id?: string | number;
3
4
  url: string;
@@ -10,6 +11,7 @@ type __VLS_Props = {
10
11
  state?: "personal" | "office" | "business";
11
12
  title?: string;
12
13
  placeId?: string | number;
14
+ class?: HTMLAttributes["class"];
13
15
  };
14
16
  declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
15
17
  title: string;
@@ -58,7 +58,7 @@ const props = defineProps({
58
58
  });
59
59
  const placeEditOptions = [
60
60
  { label: "\u0E1B\u0E34\u0E14\u0E2B\u0E23\u0E37\u0E2D\u0E2B\u0E22\u0E38\u0E14\u0E01\u0E34\u0E08\u0E01\u0E32\u0E23\u0E41\u0E25\u0E49\u0E27", value: "closed" },
61
- { label: "\u0E44\u0E21\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E17\u0E35\u0E48\u0E19\u0E35\u0E48", value: "not_exist" },
61
+ { label: "\u0E44\u0E21\u0E48\u0E21\u0E35\u0E2D\u0E22\u0E39\u0E48\u0E17\u0E35\u0E48\u0E19\u0E35\u0E48", value: "not_exist" },
62
62
  { label: "\u0E0B\u0E49\u0E33\u0E01\u0E31\u0E1A\u0E2A\u0E16\u0E32\u0E19\u0E17\u0E35\u0E48\u0E2D\u0E37\u0E48\u0E19", value: "duplicate" },
63
63
  { label: "\u0E22\u0E49\u0E32\u0E22\u0E44\u0E1B\u0E22\u0E31\u0E07\u0E15\u0E33\u0E41\u0E2B\u0E19\u0E48\u0E07\u0E17\u0E35\u0E48\u0E15\u0E31\u0E49\u0E07\u0E43\u0E2B\u0E21\u0E48\u0E41\u0E25\u0E49\u0E27", value: "relocated" },
64
64
  { label: "\u0E2D\u0E37\u0E48\u0E19\u0E46", value: "other" }
@@ -67,7 +67,10 @@ const mediaOptions = [
67
67
  { label: "\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E\u0E2B\u0E23\u0E37\u0E2D\u0E27\u0E34\u0E14\u0E35\u0E42\u0E2D\u0E44\u0E21\u0E48\u0E40\u0E2B\u0E21\u0E32\u0E30\u0E2A\u0E21", value: "inappropriate" },
68
68
  { label: "\u0E02\u0E49\u0E2D\u0E01\u0E31\u0E07\u0E27\u0E25\u0E40\u0E01\u0E35\u0E48\u0E22\u0E27\u0E01\u0E31\u0E1A\u0E04\u0E27\u0E32\u0E21\u0E40\u0E1B\u0E47\u0E19\u0E2A\u0E48\u0E27\u0E19\u0E15\u0E31\u0E27", value: "privacy" },
69
69
  { label: "\u0E04\u0E38\u0E13\u0E20\u0E32\u0E1E\u0E15\u0E48\u0E33", value: "low_quality" },
70
- { label: "\u0E40\u0E19\u0E37\u0E49\u0E2D\u0E2B\u0E32\u0E17\u0E35\u0E48\u0E21\u0E38\u0E48\u0E07\u0E23\u0E49\u0E32\u0E22 \u0E40\u0E1B\u0E47\u0E19\u0E2D\u0E31\u0E19\u0E15\u0E23\u0E32\u0E22 \u0E2B\u0E23\u0E37\u0E2D\u0E21\u0E35\u0E04\u0E27\u0E32\u0E21\u0E23\u0E38\u0E19\u0E41\u0E23\u0E07", value: "harmful" },
70
+ {
71
+ label: "\u0E40\u0E19\u0E37\u0E49\u0E2D\u0E2B\u0E32\u0E17\u0E35\u0E48\u0E21\u0E38\u0E48\u0E07\u0E23\u0E49\u0E32\u0E22 \u0E40\u0E1B\u0E47\u0E19\u0E2D\u0E31\u0E19\u0E15\u0E23\u0E32\u0E22 \u0E2B\u0E23\u0E37\u0E2D\u0E21\u0E35\u0E04\u0E27\u0E32\u0E21\u0E23\u0E38\u0E19\u0E41\u0E23\u0E07",
72
+ value: "harmful"
73
+ },
71
74
  { label: "\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E\u0E2B\u0E23\u0E37\u0E2D\u0E27\u0E34\u0E14\u0E35\u0E42\u0E2D\u0E02\u0E2D\u0E07\u0E2A\u0E16\u0E32\u0E19\u0E17\u0E35\u0E48\u0E19\u0E35\u0E49", value: "wrong_place" },
72
75
  { label: "\u0E2D\u0E37\u0E48\u0E19\u0E46", value: "other" }
73
76
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pukaad-ui-lib",
3
- "version": "1.361.0",
3
+ "version": "1.362.0",
4
4
  "description": "pukaad-ui for MeMSG",
5
5
  "repository": {
6
6
  "type": "git",