Socket
Socket
Sign inDemoInstall

@s-ui/react-atom-icon

Package Overview
Dependencies
8
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @s-ui/react-atom-icon

> Atom Element: Icon


Version published
Weekly downloads
1.9K
decreased by-7.34%
Maintainers
1
Install size
455 kB
Created
Weekly downloads
 

Readme

Source

AtomIcon

Atom Element: Icon

Installation

$ npm install @s-ui/react-atom-icon --save

Usage

<AtomIcon> wraps a <svg> that follows the rules defined on the UX Definition and give you some colors, sizes and interesting features like lazy-load rendering.

Basic usage

import AtomIcon, {
  ATOM_ICON_COLORS,
  ATOM_ICON_SIZES,
  ATOM_ICON_RENDERS
} from '@s-ui/react-atom-icon'

const check = <svg viewBox="0 0 24 24">
  <path d="M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z" />
</svg>

return (
  <>
    <AtomIcon>{check}</AtomIcon>
    <AtomIcon size={ATOM_ICON_SIZES.large}>{check}</AtomIcon>
    <AtomIcon color={ATOM_ICON_COLORS.primary}>{check}</AtomIcon>
    <AtomIcon render={ATOM_ICON_RENDERS.lazy}>{check}</AtomIcon>
  </>
)

Find full description and more examples in the demo page.

FAQs

Last updated on 26 Jul 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc