@accelint/design-toolkit
Version:
An open-source component library to serve as part of the entire ecosystem of UX for Accelint.
4 lines (3 loc) • 668 B
JavaScript
'use client';
import {jsx}from'react/jsx-runtime';import'client-only';import {createContext}from'react';import {useContextProps}from'react-aria-components';import {IconStyles}from'./styles.js';const r=createContext(null);function t({children:o,...e}){return jsx(r.Provider,{value:e,children:o})}t.displayName="Icon.Provider";function n({ref:o,...e}){[e,o]=useContextProps(e,o??null,r);const{children:s,className:p,size:c="medium",...m}=e;return jsx("span",{...m,ref:o,className:IconStyles({className:p}),"data-size":c,children:s})}n.displayName="Icon",n.Provider=t;export{n as Icon,r as IconContext};//# sourceMappingURL=index.js.map
//# sourceMappingURL=index.js.map