"use strict";const y=require("react/jsx-runtime"),_=require("react"),j=require("./icon-utils-DrY1PlFZ.cjs");function l(...i){return i.filter(Boolean).join(" ")}const E="_icon_yamd4_2",L="_iconXs_yamd4_20",N="_iconSm_yamd4_25",R="_iconMd_yamd4_30",T="_iconLg_yamd4_35",$="_iconXl_yamd4_40",k="_iconPrimary_yamd4_46",q="_iconSecondary_yamd4_50",w="_iconTertiary_yamd4_54",U="_iconInverted_yamd4_58",B="_iconInteractive_yamd4_63",H="_iconDisabled_yamd4_76",n={icon:E,iconXs:L,iconSm:N,iconMd:R,iconLg:T,iconXl:$,iconPrimary:k,iconSecondary:q,iconTertiary:w,iconInverted:U,iconInteractive:B,iconDisabled:H},t=_.forwardRef(({name:i,size:o="md",tone:v="primary",className:I,style:S,interactive:g=!1,disabled:c=!1,"aria-label":a,"aria-hidden":p,onClick:r,...f},h)=>{const s=j.getIconUrl(i),d=a!==void 0,x=p??!d,X=e=>{if(c){e.preventDefault(),e.stopPropagation();return}r==null||r(e)},m=typeof o=="number",b=m?{width:`${o}px`,height:`${o}px`}:void 0,D=m?void 0:{xs:n.iconXs,sm:n.iconSm,md:n.iconMd,lg:n.iconLg,xl:n.iconXl}[o],M={primary:n.iconPrimary,secondary:n.iconSecondary,tertiary:n.iconTertiary,inverted:n.iconInverted}[v],P={...{WebkitMaskImage:`url(${s})`,maskImage:`url(${s})`},...b,...S};return y.jsx("span",{ref:h,role:d?"img":void 0,"aria-label":a,"aria-hidden":x||void 0,"aria-disabled":c||void 0,className:l(n.icon,D,M,g&&!c&&n.iconInteractive,c&&n.iconDisabled,I),style:P,onClick:X,...f})});t.displayName="Icon";const u=_.forwardRef((i,o)=>y.jsx(t,{ref:o,name:"error",...i}));u.displayName="Error";exports.Error=u;exports.Icon=t;exports.cn=l;
