mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 20:19:34 +01:00
43 lines
1001 B
TypeScript
43 lines
1001 B
TypeScript
import type { ModuleOptions } from '../module'
|
|
|
|
export default (options: Required<ModuleOptions>) => ({
|
|
slots: {
|
|
root: 'relative min-w-0',
|
|
list: 'flex items-center gap-1.5',
|
|
item: 'flex min-w-0',
|
|
link: 'group relative flex items-center gap-1.5 text-sm min-w-0 focus-visible:outline-primary',
|
|
linkLeadingIcon: 'shrink-0 size-5',
|
|
linkLeadingAvatar: 'shrink-0',
|
|
linkLeadingAvatarSize: '2xs',
|
|
linkLabel: 'truncate',
|
|
separator: 'flex',
|
|
separatorIcon: 'shrink-0 size-5 text-muted'
|
|
},
|
|
variants: {
|
|
active: {
|
|
true: {
|
|
link: 'text-primary font-semibold'
|
|
},
|
|
false: {
|
|
link: 'text-muted font-medium'
|
|
}
|
|
},
|
|
disabled: {
|
|
true: {
|
|
link: 'cursor-not-allowed opacity-75'
|
|
}
|
|
},
|
|
to: {
|
|
true: ''
|
|
}
|
|
},
|
|
compoundVariants: [{
|
|
disabled: false,
|
|
active: false,
|
|
to: true,
|
|
class: {
|
|
link: ['hover:text-default', options.theme.transitions && 'transition-colors']
|
|
}
|
|
}]
|
|
})
|