fix: simplify note-input toolbar by using compact mode for label, type selector, and ai button
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 45s
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 45s
This commit is contained in:
@@ -56,11 +56,11 @@ export function LabelSelector({
|
||||
return (
|
||||
<DropdownMenu>
|
||||
<DropdownMenuTrigger asChild>
|
||||
<Button variant="ghost" size="sm" className="h-8 text-gray-500 hover:text-gray-900 dark:text-gray-400 dark:hover:text-gray-100 px-2">
|
||||
<Tag className={cn("h-4 w-4", triggerLabel && "mr-2")} />
|
||||
{triggerLabel || t('labels.title')}
|
||||
<Button variant="ghost" size={variant === 'compact' ? 'icon' : 'sm'} className={cn("h-8 text-gray-500 hover:text-gray-900 dark:text-gray-400 dark:hover:text-gray-100", variant === 'compact' ? "w-8 relative" : "px-2")} title={t('labels.title')}>
|
||||
<Tag className={cn("h-4 w-4", variant !== 'compact' && (triggerLabel || t('labels.title')) ? "mr-2" : "")} />
|
||||
{variant !== 'compact' && (triggerLabel || t('labels.title'))}
|
||||
{selectedLabels.length > 0 && (
|
||||
<Badge variant="secondary" className="ml-2 h-5 min-w-5 px-1.5 bg-gray-200 text-gray-800 dark:bg-zinc-700 dark:text-zinc-300">
|
||||
<Badge variant="secondary" className={cn("h-5 min-w-5 px-1.5 bg-gray-200 text-gray-800 dark:bg-zinc-700 dark:text-zinc-300", variant === 'compact' ? "absolute -top-2 -right-2 scale-75" : "ml-2")}>
|
||||
{selectedLabels.length}
|
||||
</Badge>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user