mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-23 00:15:05 +01:00
chore(Button): remove truncate prop to always use on label
This commit is contained in:
@@ -19,7 +19,6 @@ export interface ButtonProps extends UseComponentIconsProps, Omit<LinkProps, 'cu
|
||||
size?: ButtonVariants['size']
|
||||
square?: boolean
|
||||
block?: boolean
|
||||
truncate?: boolean
|
||||
class?: any
|
||||
ui?: Partial<typeof button.slots>
|
||||
}
|
||||
@@ -51,7 +50,6 @@ const ui = computed(() => tv({ extend: button, slots: props.ui })({
|
||||
variant: props.variant,
|
||||
size: buttonSize.value,
|
||||
loading: props.loading,
|
||||
truncate: props.truncate,
|
||||
block: props.block,
|
||||
square: props.square || (!slots.default && !props.label),
|
||||
leading: isLeading.value,
|
||||
|
||||
@@ -4,7 +4,7 @@ import { buttonGroupVariant } from './button-group'
|
||||
export default (options: Required<ModuleOptions>) => ({
|
||||
slots: {
|
||||
base: ['rounded-md font-medium inline-flex items-center focus:outline-none disabled:cursor-not-allowed disabled:opacity-75', options.transitions && 'transition-colors'],
|
||||
label: '',
|
||||
label: 'truncate',
|
||||
leadingIcon: 'shrink-0',
|
||||
leadingAvatar: 'shrink-0',
|
||||
trailingIcon: 'shrink-0'
|
||||
@@ -52,11 +52,6 @@ export default (options: Required<ModuleOptions>) => ({
|
||||
trailingIcon: 'size-6'
|
||||
}
|
||||
},
|
||||
truncate: {
|
||||
true: {
|
||||
label: 'truncate'
|
||||
}
|
||||
},
|
||||
block: {
|
||||
true: {
|
||||
base: 'w-full',
|
||||
|
||||
Reference in New Issue
Block a user