const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/browser-q024jlz1.js","assets/rolldown-runtime-nx40z1zs.js","assets/entry.client-mpghtlrl.js"])))=>i.map(i=>d[i]);
try{let e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`6d215219-5983-4f36-9a97-fce207b14513`,e._sentryDebugIdIdentifier=`sentry-dbid-6d215219-5983-4f36-9a97-fce207b14513`)}catch{}import{o as e}from"./rolldown-runtime-nx40z1zs.js";import{Lh as t,jg as n,yg as r}from"./entry.client-mpghtlrl.js";import{tt as i}from"./xds-react-components-ihgca01z.js";var a=e(n(),1),o=(n,o)=>{let[s,c]=(0,a.useState)(),l=(0,a.useMemo)(()=>new r(`useGenerateQrCode`),[]),u=i();return(0,a.useEffect)(()=>{async function r(n,r){let{toDataURL:i}=await t(async()=>{let{toDataURL:t}=await import(`./browser-q024jlz1.js`).then(t=>e(t.default,1));return{toDataURL:t}},__vite__mapDeps([0,1,2]));if(u.current)try{let e=await i(n,{margin:1,width:r,type:`image/webp`,color:{dark:`#000000`,light:`#FFFFFF`}});u.current&&c(e)}catch(e){l.warn(`An unexpected error occurred while generating QR code image`,e)}}r(n,o)},[n,o,l,u]),s};export{o as t};