Size of icon button #6218
-
Hi, I have code like <Button
onClick={() => toggleDrawer()}
aria-label="Open menu"
className="lg:hidden"
variant="link"
size="icon"
>
<Menu /> // icon from lucide-react
</Button> How can I make the icon bigger? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments
-
You can use the fontSize property <Menu style={{fontSize: 40 // '40px' }} /> |
Beta Was this translation helpful? Give feedback.
-
you can use scale instead
|
Beta Was this translation helpful? Give feedback.
-
I also faced the same issue. I ignore the <div role="button" > <Menu size={30} /> </div> // it works fine |
Beta Was this translation helpful? Give feedback.
-
The button base class is configured with the svg icon size, not intuitive at all. You can replace it with: <Button href={`/deck/${id}/${slug}`} variant="ghost" class="[&_svg]:size-6">
<X />
</Button> J |
Beta Was this translation helpful? Give feedback.
I also faced the same issue. I ignore the
Button
and useddiv