const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/browser-ltec02fx.js","assets/rolldown-runtime-eb2nym32.js","assets/entry.client-dr7r6s9a.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]=`c377caf6-e803-4165-a9cf-139f732070b9`,e._sentryDebugIdIdentifier=`sentry-dbid-c377caf6-e803-4165-a9cf-139f732070b9`)}catch{}import{o as e}from"./rolldown-runtime-eb2nym32.js";import{Ig as t,Io as n,Jh as r,pg as i}from"./entry.client-dr7r6s9a.js";var a=e(t(),1),o=(t,o)=>{let[s,c]=(0,a.useState)(),l=(0,a.useMemo)(()=>new i(`useGenerateQrCode`),[]),u=n();return(0,a.useEffect)(()=>{async function n(t,n){let{toDataURL:i}=await r(async()=>{let{toDataURL:t}=await import(`./browser-ltec02fx.js`).then(t=>e(t.default,1));return{toDataURL:t}},__vite__mapDeps([0,1,2]));if(u.current)try{let e=await i(t,{margin:1,width:n,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)}}n(t,o)},[t,o,l,u]),s};export{o as t};