vuivui-icons
v1.1.44
Published
vuivui-icons
Downloads
37
Readme
vuivui-icons
VuiVui - Icons component
Vuivui Icon Component :
Installation :
via NPM:
npm i vuivui-icons
via YARN:
yarn add vuivui-icons
Usage :
//index.js
import App from "./App";
import ReactDOM from "react-dom";
import React from "react";
import { iconSheet } from "vuivui-icons";
ReactDOM.render(
<React.StrictMode>
<div>
{iconSheet}
<App />
</div>
</React.StrictMode>,
document.getElementById("root")
);
import {Icon, IconEnum} from "vuivui-icons";
<Icon name={IconEnum.CaretRight} />
<Icon
name={IconEnum.CaretRight}
size={64}
color={'#F05A94'}
fill = "red"
strokeWidth={1}
/>
API References:
| Property | Description | Type | Default | Required |
| ----------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------ | :---------------------------------------------: | :------: |
| name | Name of icon | IconEnum
| | ✅ |
| color | Color of icon (Color's name or #HEX), 'primary' value is for #F05A94
, 'secondary' value is for #009ADA
| string
| #000000
|
| size | Size of icon as pixel
| number
| 32px
|
| className | As same as className in JSX | string
|
| fill | SVG fill color | string
| "none" |
| strokeWidth | value of strokeWidth as pixel | number
| 2px
|
| onClick | Set the handler to handle click
event | (event) => void
|
| onKeyPress | Set the handler to handle key press
event | (event) => void
|
| styleIcon | Inline-styles as for React components | { [key: string
]: React.CSSProperties
} |