0.0.12 • Published 3 years ago

@vtex-components/icon v0.0.12

Weekly downloads
51
License
-
Repository
github
Last release
3 years ago

VTEX Components Icon

Elementary accessible component to display svg icons. It renders a svg element.

Install

yarn add @vtex-components/icon

or

npm install @vtex-components/icon

Usage

  • Decorative only
import Icon from '@vtex-components/icon'

function UseCase() {
  return (
    <Icon>
      <path {...} />
    </Icon>
  )
}
  • Grant a11y for standalone usage
import Icon from '@vtex-components/icon'

function UseCase() {
 return (
   <Icon title="Meaningful name">
     <path {...} />
   </Icon>
 )
}

Types

proptypedescriptionrequireddefault
sizenumberIcon height and width🚫24
titlestringIcon title🚫-
sxSxStylePropThemeUI Style prop🚫{}
viewBoxstringSame as svg viewBox🚫'0 0 24 24'

Customization

Use sx to styling the icon. For further reading, you can check the Theme Documentation

0.0.12

3 years ago

0.0.11

3 years ago

0.0.10

3 years ago

0.0.9

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago

0.0.1-alpha.11

4 years ago

0.0.1-alpha.10

4 years ago

0.0.1-alpha.9

4 years ago

0.0.1-alpha.7

4 years ago

0.0.1-alpha.6

4 years ago

0.0.1-alpha.5

4 years ago

0.0.1-alpha.4

4 years ago