UNPKG

sate-lib

Version:

A lightweight and modular React component library designed for modern web interfaces. **SATE Lib** powers the [sate.menu](https://sate.menu) platform with reusable, scalable, and themeable UI components.

1 lines 617 B
import{jsx as e,jsxs as o}from"react/jsx-runtime";import{Icon as i}from"../icon/icon.js";import l from"./button-icon.styles.module.js";import{Noise as m}from"./noise.js";let n={medium:24,small:18,xSmall:16};function s({href:s,variant:t="filled",icon:r,disabled:a,size:c="medium",className:d="",...f}){let u=n[c],j=[l.buttonIcon,l[t],l[c],d].filter(Boolean).join(" ");return s?o("a",{className:j,href:s,...f,children:[e(i,{name:r,size:u}),"filled"===t&&e(m,{className:l.noise})]}):o("button",{className:j,disabled:a,...f,children:[e(i,{name:r,size:u}),"filled"===t&&e(m,{className:l.noise})]})}export{s as ButtonIcon};