pukaad-ui-lib 1.31.0 → 1.32.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-autocomplete.d.vue.ts +1 -1
- package/dist/runtime/components/input/input-autocomplete.vue.d.ts +1 -1
- package/dist/runtime/components/picker/picker-option-menu/picker-option-menu.d.vue.ts +0 -1
- package/dist/runtime/components/picker/picker-option-menu/picker-option-menu.vue +27 -32
- package/dist/runtime/components/picker/picker-option-menu/picker-option-menu.vue.d.ts +0 -1
- package/package.json +1 -1
package/dist/module.json
CHANGED
|
@@ -37,8 +37,8 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
|
37
37
|
name: string;
|
|
38
38
|
placeholder: string;
|
|
39
39
|
description: string;
|
|
40
|
-
limit: number;
|
|
41
40
|
options: AutocompleteOption[] | string[] | number[];
|
|
41
|
+
limit: number;
|
|
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
|
placeholder: string;
|
|
39
39
|
description: string;
|
|
40
|
-
limit: number;
|
|
41
40
|
options: AutocompleteOption[] | string[] | number[];
|
|
41
|
+
limit: number;
|
|
42
42
|
disabledErrorMessage: boolean;
|
|
43
43
|
disabledBorder: boolean;
|
|
44
44
|
showCounter: boolean;
|
|
@@ -1,54 +1,49 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
3
|
-
<
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
2
|
+
<ShadDropdownMenu>
|
|
3
|
+
<ShadDropdownMenuTrigger as-child>
|
|
4
|
+
<Button
|
|
5
|
+
:variant="props.variant"
|
|
6
|
+
:class="[
|
|
7
|
+
props.circle ? 'rounded-full bg-mercury' : 'rounded-md',
|
|
8
|
+
props.disabled ? 'cursor-not-allowed opacity-50' : 'cursor-pointer',
|
|
9
|
+
props.disabledPadding ? 'p-0' : ''
|
|
10
|
+
]"
|
|
11
|
+
>
|
|
12
|
+
<Icon
|
|
13
|
+
:name="
|
|
11
14
|
props.horizontal ? 'lucide:ellipsis' : 'lucide:ellipsis-vertical'
|
|
12
15
|
"
|
|
13
|
-
|
|
14
|
-
|
|
16
|
+
:size="props.iconSize"
|
|
17
|
+
/>
|
|
18
|
+
</Button>
|
|
19
|
+
</ShadDropdownMenuTrigger>
|
|
15
20
|
|
|
16
|
-
<
|
|
17
|
-
<
|
|
18
|
-
<
|
|
19
|
-
|
|
20
|
-
'flex gap-[4px] p-[8px] items-center cursor-pointer hover:bg-smoke',
|
|
21
|
-
i == 0 && 'rounded-t-[8px]',
|
|
22
|
-
i == props.items.length - 1 && 'rounded-b-[8px]'
|
|
23
|
-
]"
|
|
21
|
+
<ShadDropdownMenuContent align="start">
|
|
22
|
+
<template v-for="(item, i) in props.items" :key="i">
|
|
23
|
+
<ShadDropdownMenuItem
|
|
24
|
+
class="flex gap-[4px] items-center cursor-pointer hover:bg-smoke"
|
|
24
25
|
@click="onAction(item)"
|
|
25
26
|
>
|
|
26
|
-
<Icon :name="item.icon" size="16" />
|
|
27
|
-
<
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
</div>
|
|
33
|
-
</template>
|
|
34
|
-
</Dropdown>
|
|
27
|
+
<Icon :name="item.icon" :size="16" />
|
|
28
|
+
<span class="font-body-large">{{ item.label }}</span>
|
|
29
|
+
</ShadDropdownMenuItem>
|
|
30
|
+
</template>
|
|
31
|
+
</ShadDropdownMenuContent>
|
|
32
|
+
</ShadDropdownMenu>
|
|
35
33
|
</template>
|
|
36
34
|
|
|
37
35
|
<script setup>
|
|
38
|
-
import { ref } from "vue";
|
|
39
36
|
const props = defineProps({
|
|
40
37
|
items: { type: Array, required: false, default: () => [] },
|
|
41
38
|
variant: { type: null, required: false, default: "text" },
|
|
42
39
|
circle: { type: Boolean, required: false, default: false },
|
|
43
40
|
horizontal: { type: Boolean, required: false, default: false },
|
|
44
|
-
size: { type: null, required: false
|
|
41
|
+
size: { type: null, required: false },
|
|
45
42
|
iconSize: { type: String, required: false, default: "20" },
|
|
46
43
|
disabledPadding: { type: Boolean, required: false, default: false },
|
|
47
44
|
disabled: { type: Boolean, required: false, default: false }
|
|
48
45
|
});
|
|
49
|
-
const isOpenDrawer = ref(false);
|
|
50
46
|
const onAction = (item) => {
|
|
51
47
|
item.action();
|
|
52
|
-
isOpenDrawer.value = false;
|
|
53
48
|
};
|
|
54
49
|
</script>
|