Skip to main content

Icon

SVG icon component with theme-aware colors and optional press handling.

Basic Usage

import { Icon } from '@multinaire/ui';

<Icon icon="Home" />

<Icon icon="Settings" size={32} color="primary" />

Props

PropTypeDefaultDescription
iconIconNameIcon name from the Iconsax library or the built-in custom icon set
sizenumber20Size of the icon in pixels. Defaults to 20
colorColorKeysIcon color key from the active theme palette
typeIconType'Linear'Iconsax icon style variant. Defaults to 'Linear'
marginSpacingProps2Margin around the icon. Defaults to 2
isLoadingbooleanfalseShow a circular loading skeleton in place of the icon
testIDstringTest identifier for UI automation
onPress() => voidPress handler for interactive icons

Available Icons

Custom Icons (Icons)

Built-in branded icons for common social and brand use cases:

NameDescription
CustomAppleApple logo
CustomFacebookFacebook logo
CustomGithubGitHub logo
CustomGoogleGoogle logo
CustomInstagramInstagram logo
CustomLinkedInLinkedIn logo
CustomPlanPlan/pricing icon
CustomXX (formerly Twitter) logo

Iconsax Icons

993 icons available via the Iconsax library. Common icons include:

  • Navigation: Home, Back, Forward, Menu, Close
  • Actions: Add, Edit, Delete, Save, Share
  • Media: Camera, Image, Video, Play, Pause
  • Communication: Message, Email, Phone, Notification
  • UI: Check, Search, Filter, Settings, More

Examples

Different Sizes

<Icon icon="Star" size={16} />
<Icon icon="Star" size={24} />
<Icon icon="Star" size={32} />

Colors

<Icon icon="Heart" color="primary" />
<Icon icon="Heart" color="error" />
<Icon icon="Heart" color="neutral" />

Pressable Icon

<Icon
icon="Settings"
size={28}
onPress={() => navigation.navigate('Settings')}
/>

Custom (Brand) Icons

<Icon icon="CustomApple" size={24} />
<Icon icon="CustomGoogle" size={24} />
<Icon icon="CustomGithub" size={24} />

Loading State

<Icon icon="User" isLoading />