fix: make Line tool button static next to Rect and Span
This commit is contained in:
parent
04a8303f4f
commit
0ba3592679
1 changed files with 10 additions and 15 deletions
|
|
@ -183,21 +183,16 @@ export default function Toolbox({
|
|||
>
|
||||
<Layers className="w-3.5 h-3.5" /> Span
|
||||
</button>
|
||||
{annotationTypes
|
||||
.filter((t) => t.category === 'line')
|
||||
.map((type) => (
|
||||
<button
|
||||
key={type.id}
|
||||
onClick={() => handleToolClick(type.name)}
|
||||
className={`flex-1 flex items-center justify-center gap-1 px-1.5 py-1.5 text-xs rounded transition-colors ${
|
||||
activeTool === type.name
|
||||
? 'bg-primary text-primary-foreground'
|
||||
: 'bg-secondary/50 hover:bg-secondary text-muted-foreground hover:text-foreground'
|
||||
}`}
|
||||
>
|
||||
<Minus className="w-3.5 h-3.5" /> Line
|
||||
</button>
|
||||
))}
|
||||
<button
|
||||
onClick={() => handleToolClick('line')}
|
||||
className={`flex-1 flex items-center justify-center gap-1 px-1.5 py-1.5 text-xs rounded transition-colors ${
|
||||
activeTool === 'line'
|
||||
? 'bg-primary text-primary-foreground'
|
||||
: 'bg-secondary/50 hover:bg-secondary text-muted-foreground hover:text-foreground'
|
||||
}`}
|
||||
>
|
||||
<Minus className="w-3.5 h-3.5" /> Line
|
||||
</button>
|
||||
<button
|
||||
onClick={() => handleToolClick('delete')}
|
||||
className={`flex-1 flex items-center justify-center gap-1 px-1.5 py-1.5 text-xs rounded transition-colors ${
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue