import{ao as l,bM as S,am as g,Y as h}from"./index-B1H8BCL7.js";function x(e){return typeof e=="string"}function N(e,s,n){return e===void 0||x(e)?s:l({},s,{ownerState:l({},s.ownerState,n)})}function w(e,s=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(t=>t.match(/^on[A-Z]/)&&typeof e[t]=="function"&&!s.includes(t)).forEach(t=>{n[t]=e[t]}),n}function E(e,s){return typeof e=="function"?e(s):e}function P(e){if(e===void 0)return{};const s={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{s[n]=e[n]}),s}function H(e){const{getSlotProps:s,additionalProps:n,externalSlotProps:t,externalForwardedProps:o,className:i}=e;if(!s){const m=S(o==null?void 0:o.className,t==null?void 0:t.className,i,n==null?void 0:n.className),y=l({},n==null?void 0:n.style,o==null?void 0:o.style,t==null?void 0:t.style),v=l({},n,o,t);return m.length>0&&(v.className=m),Object.keys(y).length>0&&(v.style=y),{props:v,internalRef:void 0}}const a=w(l({},o,t)),u=P(t),d=P(o),r=s(a),c=S(r==null?void 0:r.className,n==null?void 0:n.className,i,o==null?void 0:o.className,t==null?void 0:t.className),p=l({},r==null?void 0:r.style,n==null?void 0:n.style,o==null?void 0:o.style,t==null?void 0:t.style),f=l({},r,n,d,u);return c.length>0&&(f.className=c),Object.keys(p).length>0&&(f.style=p),{props:f,internalRef:r.ref}}const k=["elementType","externalSlotProps","ownerState"];function O(e){var s;const{elementType:n,externalSlotProps:t,ownerState:o}=e,i=g(e,k),a=E(t,o),{props:u,internalRef:d}=H(l({},i,{externalSlotProps:a})),r=h(d,a==null?void 0:a.ref,(s=e.additionalProps)==null?void 0:s.ref);return N(n,l({},u,{ref:r}),o)}export{w as e,E as r,O as u};
