refactor: change button variant from 'ghost' to 'text' across multiple components for consistency
This commit is contained in:
@ -17,7 +17,7 @@ const buttonVariants = cva(
|
||||
"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",
|
||||
secondary:
|
||||
"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",
|
||||
ghost: "hover:bg-accent hover:text-accent-foreground",
|
||||
text: "bg-transparent p-0 rounded-none hover:text-muted-foreground", // Instead of ghost (matches app better)
|
||||
link: "text-primary underline-offset-4 hover:underline",
|
||||
},
|
||||
size: {
|
||||
|
@ -43,7 +43,7 @@ function Calendar({
|
||||
: "[&:has([aria-selected])]:rounded-md"
|
||||
),
|
||||
day: cn(
|
||||
buttonVariants({ variant: "ghost" }),
|
||||
buttonVariants({ variant: "text" }),
|
||||
"h-8 w-8 p-0 font-normal aria-selected:opacity-100"
|
||||
),
|
||||
day_range_start: "day-range-start",
|
||||
|
@ -41,7 +41,7 @@ const Input = React.forwardRef<HTMLInputElement, InputProps>(
|
||||
{showPasswordToggle && (
|
||||
<Button
|
||||
type="button"
|
||||
variant="ghost"
|
||||
variant="text"
|
||||
size="icon"
|
||||
onClick={() => onShowPasswordChange?.(!showPassword)}
|
||||
className="absolute right-0 top-0 h-full px-3 text-muted-foreground hover:text-foreground"
|
||||
|
@ -49,7 +49,7 @@ const PaginationLink = ({
|
||||
aria-current={isActive ? "page" : undefined}
|
||||
className={cn(
|
||||
buttonVariants({
|
||||
variant: isActive ? "outline" : "ghost",
|
||||
variant: isActive ? "outline" : "text",
|
||||
size,
|
||||
}),
|
||||
className
|
||||
|
@ -269,7 +269,7 @@ const SidebarTrigger = React.forwardRef<
|
||||
<Button
|
||||
ref={ref}
|
||||
data-sidebar="trigger"
|
||||
variant="ghost"
|
||||
variant="text"
|
||||
size="icon"
|
||||
className={cn("h-8 w-8", className)}
|
||||
onClick={(event) => {
|
||||
|
Reference in New Issue
Block a user