Icon Block
A block for icon, emoji, or image display.
🚀
Installation
Options
Size
Use the size
prop to control the size of the button.
🚀
🚀
🚀
🚀
Examples
Lucide Icon
Image Url
Text
J
API Reference
IconBlock
Prop | Type | Default | Description |
---|---|---|---|
icon * | IconData | - | The icon data. |
size | "sm" | "md" | "lg" | "xl" | "sm" | The size of the block. |
fallback | string | - | The fallback string to display when an image can not be loaded. |
type
IconData
There are 4 types of icons:
emoji
: An emoji icon, whosesrc
is simply the emoji string. See Emoji Cheat Sheet.lucide
: A Lucide icon, whosesrc
is the name of the icon. See Lucide Icons.url
: An image URL. The image will be displayed in the block.text
: A text string. Only the first letter ofsrc
will be displayed in the block.
Prop | Type | Description |
---|---|---|
type * | "emoji" | "lucide" | "url" | "text" | The icon type. |
src * | string | The source of the icon. |
color | string | The color of the lucide icon. |