mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-23 08:20:39 +01:00
docs(command-palette): update
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
<script setup lang="ts">
|
||||
const labels = [{
|
||||
label: 'bug',
|
||||
chip: {
|
||||
color: 'red' as const
|
||||
}
|
||||
}, {
|
||||
label: 'feature',
|
||||
chip: {
|
||||
color: 'green' as const
|
||||
}
|
||||
}, {
|
||||
label: 'enhancement',
|
||||
chip: {
|
||||
color: 'blue' as const
|
||||
}
|
||||
}]
|
||||
const label = ref([])
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<UPopover :content="{ side: 'right', align: 'start' }">
|
||||
<UButton
|
||||
icon="i-heroicons-tag"
|
||||
label="Select labels"
|
||||
color="gray"
|
||||
variant="subtle"
|
||||
/>
|
||||
|
||||
<template #content>
|
||||
<UCommandPalette
|
||||
v-model="label"
|
||||
multiple
|
||||
placeholder="Search labels..."
|
||||
:groups="[{ id: 'labels', items: labels }]"
|
||||
:ui="{ input: '[&>input]:h-8' }"
|
||||
/>
|
||||
</template>
|
||||
</UPopover>
|
||||
</template>
|
||||
Reference in New Issue
Block a user