feat(DropdownMenu): add #item slot for consistency

This commit is contained in:
Benjamin Canac
2024-04-17 12:18:37 +02:00
parent ea19a3061f
commit 1dcc1f5074
6 changed files with 184 additions and 36 deletions

View File

@@ -19,9 +19,9 @@ export interface DropdownMenuItem extends Omit<LinkProps, 'type'> {
shortcuts?: string[] | KbdProps[]
/**
* The item type.
* @defaultValue "item"
* @defaultValue "link"
*/
type?: 'label' | 'item'
type?: 'label' | 'link'
slot?: string
open?: boolean
defaultOpen?: boolean
@@ -48,6 +48,8 @@ export interface DropdownMenuSlots<T> {
leading: SlotProps<T>
label: SlotProps<T>
trailing: SlotProps<T>
item: SlotProps<T>
[key: string]: SlotProps<T>
}
</script>