"use strict";const l=require("react"),p=require("./SSRProvider-DZRLwxPS.cjs.js"),a=typeof document<"u"?l.useLayoutEffect:()=>{};function y(r){let[e,f]=l.useState(r),n=l.useRef(e),t=l.useRef(null),u=l.useRef(()=>{if(!t.current)return;let d=t.current.next();if(d.done){t.current=null;return}n.current===d.value?u.current():f(d.value)});a(()=>{n.current=e,t.current&&u.current()});let c=l.useCallback(d=>{t.current=d(n.current),u.current()},[u]);return[e,c]}let x=!!(typeof window<"u"&&window.document&&window.document.createElement),o=new Map,i;typeof FinalizationRegistry<"u"&&(i=new FinalizationRegistry(r=>{o.delete(r)}));function s(r){let[e,f]=l.useState(r),n=l.useRef(null),t=p.$b5e257d569688ac6$export$619500959fc48b26(e),u=l.useRef(null);if(i&&i.register(u,t),x){const c=o.get(t);c&&!c.includes(n)?c.push(n):o.set(t,[n])}return a(()=>{let c=t;return()=>{i&&i.unregister(u),o.delete(c)}},[t]),l.useEffect(()=>{let c=n.current;return c&&f(c),()=>{c&&(n.current=null)}}),t}function g(r,e){if(r===e)return r;let f=o.get(r);if(f)return f.forEach(t=>t.current=e),e;let n=o.get(e);return n?(n.forEach(t=>t.current=r),r):e}function R(r=[]){let e=s(),[f,n]=y(e),t=l.useCallback(()=>{n(function*(){yield e,yield document.getElementById(e)?e:void 0})},[e,n]);return a(t,[e,t,...r]),f}function $(...r){return(...e)=>{for(let f of r)typeof f=="function"&&f(...e)}}function b(r){var e,f,n="";if(typeof r=="string"||typeof r=="number")n+=r;else if(typeof r=="object")if(Array.isArray(r)){var t=r.length;for(e=0;e<t;e++)r[e]&&(f=b(r[e]))&&(n&&(n+=" "),n+=f)}else for(f in r)r[f]&&(n&&(n+=" "),n+=f);return n}function v(){for(var r,e,f=0,n="",t=arguments.length;f<t;f++)(r=arguments[f])&&(e=b(r))&&(n&&(n+=" "),n+=e);return n}function m(...r){let e={...r[0]};for(let f=1;f<r.length;f++){let n=r[f];for(let t in n){let u=e[t],c=n[t];typeof u=="function"&&typeof c=="function"&&t[0]==="o"&&t[1]==="n"&&t.charCodeAt(2)>=65&&t.charCodeAt(2)<=90?e[t]=$(u,c):(t==="className"||t==="UNSAFE_className")&&typeof u=="string"&&typeof c=="string"?e[t]=v(u,c):t==="id"&&u&&c?e.id=g(u,c):e[t]=c!==void 0?c:u}}return e}exports.$3ef42575df84b30b$export$9d1611c77c2fe928=m;exports.$bdb11010cef70236$export$b4cc09c592e8fdb8=R;exports.$bdb11010cef70236$export$f680877a34711e37=s;exports.$f0a04ccd8dbdd83b$export$e5c5a5f917a5871c=a;exports.$ff5963eb1fccf552$export$e08e3b67e392101e=$;
//# sourceMappingURL=mergeProps-DD8aR8go.cjs.js.map
