@dcl/explore-site 0.0.1-24353156203.commit-157a41c → 0.0.1-24478945478.commit-fbe29bc

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (131) hide show
  1. package/assets/HomePage-4HQ75L-m.js +5 -0
  2. package/assets/{QueryClientProvider-DIya0AJE.js → QueryClientProvider--leuT0BF.js} +1 -1
  3. package/assets/SensorsRounded-H2-cTBMr.js +15 -0
  4. package/assets/{__federation_expose_App-C1e3Md3H.js → __federation_expose_App-BV1W9Nsg.js} +1 -1
  5. package/assets/{__federation_fn_import-Ht3m1qpn.js → __federation_fn_import-DiM-2p0X.js} +1 -1
  6. package/assets/__federation_shared_@dcl/hooks-BPbDbik5.js +520 -0
  7. package/assets/__federation_shared_@dcl/schemas-NoE3FR6c.js +1 -0
  8. package/assets/__federation_shared_@emotion/react-BxgzYDzF.js +1 -0
  9. package/assets/__federation_shared_@emotion/{styled-BS5dedBi.js → styled-J4z9BTTi.js} +1 -1
  10. package/assets/__federation_shared_decentraland-ui2-CKEsU5_w.js +357 -0
  11. package/assets/{__federation_shared_react-redux-W6mfh1Yq.js → __federation_shared_react-redux-Da7H9TvO.js} +1 -1
  12. package/assets/{__federation_shared_react-router-dom-BJBxUtHV.js → __federation_shared_react-router-dom-C19SKiqW.js} +1 -1
  13. package/assets/{__federation_shared_viem-D92oJAhA.js → __federation_shared_viem-CjVgxkdA.js} +1 -1
  14. package/assets/{__federation_shared_wagmi-Mn9i9XHL.js → __federation_shared_wagmi-Do7OgkKc.js} +1 -1
  15. package/assets/{add-Pf2mtDVd.js → add-Daid8Noh.js} +1 -1
  16. package/assets/{all-wallets-yTWm-7l0.js → all-wallets-DiZQK82j.js} +1 -1
  17. package/assets/{app-store-CHNvFr8x.js → app-store-CV27MXOj.js} +1 -1
  18. package/assets/{apple-Cl30qHkG.js → apple-WY66pyZC.js} +1 -1
  19. package/assets/{arrow-bottom-DTZt60fy.js → arrow-bottom-CGAu2sUq.js} +1 -1
  20. package/assets/{arrow-bottom-circle-zZ7DVvhp.js → arrow-bottom-circle-Bg41XMJ4.js} +1 -1
  21. package/assets/{arrow-left-D5G-F2Mr.js → arrow-left-BC8WX0E0.js} +1 -1
  22. package/assets/{arrow-right-CQp0OKbr.js → arrow-right-BKbdbJmP.js} +1 -1
  23. package/assets/{arrow-top-Dov1vQPn.js → arrow-top-DBBJA8uy.js} +1 -1
  24. package/assets/{auto-track-CJ-hNq0s.js → auto-track-DqNnSbTw.js} +1 -1
  25. package/assets/{bank-CzpOQOqg.js → bank-BqhRWSQZ.js} +1 -1
  26. package/assets/{basic-BaHwLXYW.js → basic-DkiFeXIZ.js} +1 -1
  27. package/assets/{browser-DmlzKjDH.js → browser-_VNJ0ZVD.js} +1 -1
  28. package/assets/{card-DjnQpz1T.js → card-Do28FZIN.js} +1 -1
  29. package/assets/{ccip-fLeNA6wc.js → ccip-DM-gN1AQ.js} +1 -1
  30. package/assets/{checkmark-Cv7bJNZW.js → checkmark-DkZh9Zlf.js} +1 -1
  31. package/assets/{checkmark-bold-Crr_qeUj.js → checkmark-bold-BpmrZTfW.js} +1 -1
  32. package/assets/{chevron-bottom-DjPxwSAz.js → chevron-bottom-BR7imf61.js} +1 -1
  33. package/assets/{chevron-left-DRFM7Kjo.js → chevron-left-BgSUIV8s.js} +1 -1
  34. package/assets/{chevron-right-C3dXKRLK.js → chevron-right-DWD5TLbn.js} +1 -1
  35. package/assets/{chevron-top-DkPXzMT9.js → chevron-top-D7S-CScU.js} +1 -1
  36. package/assets/{chrome-store-C1j87a0E.js → chrome-store-B8uTCWo4.js} +1 -1
  37. package/assets/{clock-Ii2gOHOm.js → clock-BD6s_KdG.js} +1 -1
  38. package/assets/{close-mveIoSo7.js → close-CnBVyDqH.js} +1 -1
  39. package/assets/{coinPlaceholder-BgCUmbQq.js → coinPlaceholder-81U7X6av.js} +1 -1
  40. package/assets/{compass-CFoHHJhs.js → compass-Ts-lPb2L.js} +1 -1
  41. package/assets/{copy-CECL7vci.js → copy-DCH8C6zc.js} +1 -1
  42. package/assets/{core-rob3DE1K.js → core-Dhd6Iy8d.js} +3 -3
  43. package/assets/{createClient-DIPdlHW_.js → createClient-BcYkZyGj.js} +1 -1
  44. package/assets/{cursor-CVJFIzVK.js → cursor-BLKnhkE9.js} +1 -1
  45. package/assets/{cursor-transparent-OkqQkD5X.js → cursor-transparent-C0zsz7H9.js} +1 -1
  46. package/assets/{desktop-SqravDGB.js → desktop-Bh7_tRbW.js} +1 -1
  47. package/assets/{disconnect-C438cKH2.js → disconnect-4_am9qYp.js} +1 -1
  48. package/assets/{discord-C342vjF7.js → discord-Dt-NMkqj.js} +1 -1
  49. package/assets/{emotion-react.browser.esm-BZuSnvT8.js → emotion-react.browser.esm-BDrOZpgV.js} +1 -1
  50. package/assets/{emotion-use-insertion-effect-with-fallbacks.browser.esm-CLJKjSo3.js → emotion-use-insertion-effect-with-fallbacks.browser.esm-l2IiBxl6.js} +1 -1
  51. package/assets/{etherscan-Bnt1d9db.js → etherscan-B4BDfsL8.js} +1 -1
  52. package/assets/{exclamation-triangle-tMBULVvu.js → exclamation-triangle-D3NIlu-T.js} +1 -1
  53. package/assets/{extension-BSzqi0r5.js → extension-tsRob_2k.js} +1 -1
  54. package/assets/{external-link-j8SaBF13.js → external-link-ugbgKjeM.js} +1 -1
  55. package/assets/{facebook-CDHF3Kvl.js → facebook-D_V0Apmn.js} +1 -1
  56. package/assets/{farcaster-BOEIT-PC.js → farcaster-CbYsxa-c.js} +1 -1
  57. package/assets/{filters-DV0FUhQ0.js → filters-CXoaKLPf.js} +1 -1
  58. package/assets/{github-C4Va2GNy.js → github-BQ6AFC-x.js} +1 -1
  59. package/assets/{google-Cje22T1c.js → google-CgCrWyXU.js} +1 -1
  60. package/assets/{help-circle-Bff4zjju.js → help-circle-CeKyhCzL.js} +1 -1
  61. package/assets/{id-Dd0qqSfM.js → id-Be2iQFlL.js} +1 -1
  62. package/assets/{image-Cn6H6ai6.js → image-BKga-nIx.js} +1 -1
  63. package/assets/index-BoL1wX4e.js +1 -0
  64. package/assets/{index-l-nOLSLJ.js → index-Cp1PC8Pr.js} +2 -2
  65. package/assets/{index-CmM7TlDV.js → index-D6uTuLeA.js} +1 -1
  66. package/assets/index-DRqFUSF2.js +1 -0
  67. package/assets/index-DVftV2UM.js +16 -0
  68. package/assets/{index-CVDO0kXc.js → index-DX4cgVhx.js} +1 -1
  69. package/assets/{index-BOVA3Ef2.js → index-DYHBL5dz.js} +1 -1
  70. package/assets/{index-IsljfPdd.js → index-DoYKMzm-.js} +1 -1
  71. package/assets/index-Dy0yjznp.js +1 -1
  72. package/assets/{index-DK6XZ4Dz.js → index-T-kj4HwN.js} +1 -1
  73. package/assets/index-VfkM29PH.js +1 -1
  74. package/assets/{index-MKDM4ZR3.js → index-jJtvvIhT.js} +3 -3
  75. package/assets/{index.es-BHi5bjgi.js → index.es-PqkS6yPf.js} +3 -3
  76. package/assets/{info-CNp7Y95X.js → info-HGWeWzHM.js} +1 -1
  77. package/assets/{info-circle-7DQwkSlJ.js → info-circle-41LCT2sF.js} +1 -1
  78. package/assets/jsx-runtime-B1l0k91v.js +1 -1
  79. package/assets/{lightbulb-B0gzSEGz.js → lightbulb-NDbKHlTB.js} +1 -1
  80. package/assets/{localBatchGatewayRequest-xkDsPGG7.js → localBatchGatewayRequest-BYwDa5vQ.js} +1 -1
  81. package/assets/{mail-dRKM5FXT.js → mail-Bu8ml1Ak.js} +1 -1
  82. package/assets/{mobile-LB_FN_RV.js → mobile-DbRhum7U.js} +1 -1
  83. package/assets/{more-CYum3xAb.js → more-CEIXJ-1N.js} +1 -1
  84. package/assets/{network-placeholder-BtyRBLps.js → network-placeholder-Bw3MHqfg.js} +1 -1
  85. package/assets/{nftPlaceholder-BEMgcchY.js → nftPlaceholder-DFUxL8_Z.js} +1 -1
  86. package/assets/{off-C5JcUbXr.js → off-CpTo0-ZF.js} +1 -1
  87. package/assets/{play-store-CN5oe3Vf.js → play-store-4qrK4s4s.js} +1 -1
  88. package/assets/{plus-CKUKfnQj.js → plus-Co84Q6A5.js} +1 -1
  89. package/assets/{preload-helper-ByFjl-a5.js → preload-helper-DiN7JEdv.js} +1 -1
  90. package/assets/{qr-code-BzLqVM5j.js → qr-code-l130WBRh.js} +1 -1
  91. package/assets/{recycle-horizontal-dPdqs2_u.js → recycle-horizontal-BwIgvOD_.js} +1 -1
  92. package/assets/{refresh-DSde0C6e.js → refresh-hIpJOVfw.js} +1 -1
  93. package/assets/remoteEntry.js +1 -1
  94. package/assets/{reown-logo-BR03HbJl.js → reown-logo-BJLVCKGg.js} +1 -1
  95. package/assets/{search-CedcKcSQ.js → search-D_oIgFxh.js} +1 -1
  96. package/assets/{secp256k1-B4W1DvAE.js → secp256k1-DbMaKmYo.js} +1 -1
  97. package/assets/{send-GPwvH8UU.js → send-BQV4iaQs.js} +1 -1
  98. package/assets/{swapHorizontal-BR-8g9B3.js → swapHorizontal-Daw-5sVy.js} +1 -1
  99. package/assets/{swapHorizontalBold-B7LIXZ0L.js → swapHorizontalBold-B1g2xssk.js} +1 -1
  100. package/assets/{swapHorizontalMedium-fAXgriAI.js → swapHorizontalMedium-CPL2Mejm.js} +1 -1
  101. package/assets/{swapHorizontalRoundedBold-DcpI4Y0u.js → swapHorizontalRoundedBold-C1XtN2m3.js} +1 -1
  102. package/assets/{swapVertical-yx4f2BAH.js → swapVertical-BpuAciPK.js} +1 -1
  103. package/assets/{telegram-DBD185Ye.js → telegram-Csbx1gWz.js} +1 -1
  104. package/assets/{three-dots-DeQeOnEw.js → three-dots-DiK_h83n.js} +1 -1
  105. package/assets/{twitch-0WtoG5d0.js → twitch-CIjcFlBZ.js} +1 -1
  106. package/assets/{twitterIcon-atCsdkp8.js → twitterIcon-CUp0tT8q.js} +1 -1
  107. package/assets/{uid-EJg3CBmY.js → uid-CYtpXYTM.js} +3 -3
  108. package/assets/{verify-KQXFAoty.js → verify-Cu6b7W7W.js} +1 -1
  109. package/assets/{verify-filled-CM5tIwPd.js → verify-filled-wGbCMaxP.js} +1 -1
  110. package/assets/{w3m-modal-NP2Fg3Od.js → w3m-modal-eGJ9MIKg.js} +1 -1
  111. package/assets/{wallet-D_D97dGa.js → wallet-D9jO_EWu.js} +1 -1
  112. package/assets/{wallet-placeholder-CqVcvVD2.js → wallet-placeholder-Crncam5C.js} +1 -1
  113. package/assets/{walletconnect-CumO8EDV.js → walletconnect-DqK21liB.js} +1 -1
  114. package/assets/{warning-circle-PdDzpbOz.js → warning-circle-CKSKNtxx.js} +1 -1
  115. package/assets/{webSocket-CrIirM3J.js → webSocket-Cg90KmKh.js} +1 -1
  116. package/assets/{x-CA1Ri3bW.js → x-B_nPooQD.js} +1 -1
  117. package/index.html +17 -14
  118. package/package.json +3 -3
  119. package/assets/HomePage-gvYCE7Us.js +0 -5
  120. package/assets/SensorsRounded-CofDOJXy.js +0 -15
  121. package/assets/__federation_shared_@dcl/hooks-CxuIIRDv.js +0 -535
  122. package/assets/__federation_shared_@dcl/schemas-FcJQcJ28.js +0 -1
  123. package/assets/__federation_shared_@emotion/react-u6J4D45G.js +0 -1
  124. package/assets/__federation_shared_decentraland-ui2-DpbLoOhx.js +0 -357
  125. package/assets/create-submenu-Bu20F8-Z.webp +0 -0
  126. package/assets/explore-submenu-BFVuYMi9.webp +0 -0
  127. package/assets/governance-submenu-VTIKvCIL.webp +0 -0
  128. package/assets/index-Biwg5bHN.js +0 -1
  129. package/assets/index-TGKJ-nWH.js +0 -1
  130. package/assets/learn-submenu-sfxVP5Db.webp +0 -0
  131. package/assets/marketplace-submenu-CixWTv8_.webp +0 -0
@@ -0,0 +1,520 @@
1
+ const __vite__fileDeps=["assets/index-Cp1PC8Pr.js","assets/preload-helper-DiN7JEdv.js","assets/tslib.es6-DbvBTznf.js","assets/_commonjsHelpers-C4iS2aBk.js","assets/inherits_browser-BlmhoU4v.js"],__vite__mapDeps=i=>i.map(i=>__vite__fileDeps[i]);
2
+ import{l as Cg}from"../index-DVftV2UM.js";import{_ as Rg}from"../preload-helper-DiN7JEdv.js";import{importShared as Je}from"../__federation_fn_import-DiM-2p0X.js";import{j as hf}from"../jsx-runtime-B1l0k91v.js";import{b as $,d as yt,e as Ag,c as Ot}from"../tslib.es6-DbvBTznf.js";const Mg=50,Ng=e=>({...e,timestamp:Number(e.timestamp)}),Og=(e,t)=>{const n=e,{url:r,limit:i=Mg}=t,s=Cg.signedFetchFactory();return{getNotifications:async()=>{const c=new URLSearchParams;c.append("limit",String(i));const u=`${r}/notifications?${c.toString()}`,d=await s(u,{identity:n,headers:{"Content-Type":"application/json"}});if(!d.ok)throw new Error(`Failed to fetch notifications: ${d.status}`);return((await d.json()).notifications??[]).map(Ng)},markNotificationsAsRead:async c=>{const u=`${r}/notifications/read`,d=await s(u,{method:"PUT",identity:n,body:JSON.stringify({notificationIds:c}),headers:{"Content-Type":"application/json"}});if(!d.ok)throw new Error(`Failed to mark notifications as read: ${d.status}`)}}};var Lg=" daum[ /]| deusu/|(?:^|[^g])news(?!sapphire)|(?<! (?:channel/|google/))google(?!(app|/google| pixel))|(?<! cu)bots?(?:\\b|_)|(?<!(?:lib))http|(?<![hg]m)score|(?<!cam)scan|24x7|@[a-z][\\w-]+\\.|\\(\\)|\\.com\\b|\\bperl\\b|\\btime/|\\||^[\\w \\.\\-\\(?:\\):%]+(?:/v?\\d+(?:\\.\\d+)?(?:\\.\\d{1,10})*?)?(?:,|$)|^[^ ]{50,}$|^\\d+\\b|^\\W|^\\w*search\\b|^\\w+/[\\w\\(\\)]*$|^active|^ad muncher|^amaya|^avsdevicesdk/|^azure|^biglotron|^bot|^bw/|^clamav[ /]|^client/|^cobweb/|^custom|^ddg[_-]android|^discourse|^dispatch/\\d|^downcast/|^duckduckgo|^email|^facebook|^getright/|^gozilla/|^hobbit|^hotzonu|^hwcdn/|^igetter/|^jeode/|^jetty/|^jigsaw|^microsoft bits|^movabletype|^mozilla/\\d\\.\\d\\s[\\w\\.-]+$|^mozilla/\\d\\.\\d\\s\\(compatible;?(?:\\s\\w+\\/\\d+\\.\\d+)?\\)$|^navermailapp|^netsurf|^offline|^openai/|^owler|^php|^postman|^python|^rank|^read|^reed|^rest|^rss|^snapchat|^space bison|^svn|^swcd |^taringa|^thumbor/|^track|^w3c|^webbandit/|^webcopier|^wget|^whatsapp|^wordpress|^xenu link sleuth|^yahoo|^yandex|^zdm/\\d|^zoom marketplace/|agent\\b|analyzer|archive|ask jeeves/teoma|audit|bit\\.ly/|bluecoat drtr|browsex|burpcollaborator|capture|catch|check\\b|checker|chrome-lighthouse|chromeframe|classifier|cloudflare|convertify|crawl|cypress/|dareboost|datanyze|dejaclick|detect|dmbrowser|download|evc-batch/|exaleadcloudview|feed|fetcher|firephp|functionize|grab|headless|httrack|hubspot marketing grader|hydra|ibisbrowser|infrawatch|insight|inspect|iplabel|java(?!;)|library|linkcheck|mail\\.ru/|manager|measure|neustar wpm|node\\b|nutch|offbyone|onetrust|optimize|pageburst|pagespeed|parser|phantomjs|pingdom|powermarks|preview|proxy|ptst[ /]\\d|retriever|rexx;|rigor|rss\\b|scrape|server|sogou|sparkler/|speedcurve|spider|splash|statuscake|supercleaner|synapse|synthetic|tools|torrent|transcoder|url|validator|virtuoso|wappalyzer|webglance|webkit2png|whatcms/|xtate/",Pg=/bot|crawl|http|lighthouse|scan|search|spider/i,Hr;function Dg(){if(Hr instanceof RegExp)return Hr;try{Hr=new RegExp(Lg,"i")}catch{Hr=Pg}return Hr}function Fg(e){return!!e&&Dg().test(e)}const D=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,q=globalThis,Dt="9.47.1";function Vt(){return li(q),q}function li(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||Dt,t[Dt]=t[Dt]||{}}function di(e,t,n=q){const r=n.__SENTRY__=n.__SENTRY__||{},i=r[Dt]=r[Dt]||{};return i[e]||(i[e]=t())}const mc=["debug","info","warn","error","log","assert","trace"],Hg="Sentry Logger ",Is={};function un(e){if(!("console"in q))return e();const t=q.console,n={},r=Object.keys(Is);r.forEach(i=>{const s=Is[i];n[i]=t[i],t[i]=s});try{return e()}finally{r.forEach(i=>{t[i]=n[i]})}}function Bg(){_c().enabled=!0}function Ug(){_c().enabled=!1}function pf(){return _c().enabled}function $g(...e){gc("log",...e)}function Wg(...e){gc("warn",...e)}function Gg(...e){gc("error",...e)}function gc(e,...t){D&&pf()&&un(()=>{q.console[e](`${Hg}[${e}]:`,...t)})}function _c(){return D?di("loggerSettings",()=>({enabled:!1})):{enabled:!1}}const y={enable:Bg,disable:Ug,isEnabled:pf,log:$g,warn:Wg,error:Gg},mf=50,kt="?",vu=/\(error: (.*)\)/,wu=/captureMessage|captureException/;function gf(...e){const t=e.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,i=0)=>{const s=[],o=n.split(`
3
+ `);for(let a=r;a<o.length;a++){const c=o[a];if(c.length>1024)continue;const u=vu.test(c)?c.replace(vu,"$1"):c;if(!u.match(/\S*Error: /)){for(const d of t){const l=d(u);if(l){s.push(l);break}}if(s.length>=mf+i)break}}return jg(s.slice(i))}}function zg(e){return Array.isArray(e)?gf(...e):e}function jg(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(Ni(t).function||"")&&t.pop(),t.reverse(),wu.test(Ni(t).function||"")&&(t.pop(),wu.test(Ni(t).function||"")&&t.pop()),t.slice(0,mf).map(n=>({...n,filename:n.filename||Ni(t).filename,function:n.function||kt}))}function Ni(e){return e[e.length-1]||{}}const Co="<anonymous>";function Bt(e){try{return!e||typeof e!="function"?Co:e.name||Co}catch{return Co}}function ya(e){const t=e.exception;if(t){const n=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}const os={},Tu={};function ln(e,t){os[e]=os[e]||[],os[e].push(t)}function dn(e,t){if(!Tu[e]){Tu[e]=!0;try{t()}catch(n){D&&y.error(`Error while instrumenting ${e}`,n)}}}function it(e,t){const n=e&&os[e];if(n)for(const r of n)try{r(t)}catch(i){D&&y.error(`Error while triggering instrumentation handler.
4
+ Type: ${e}
5
+ Name: ${Bt(r)}
6
+ Error:`,i)}}let Ro=null;function _f(e){const t="error";ln(t,e),dn(t,qg)}function qg(){Ro=q.onerror,q.onerror=function(e,t,n,r,i){return it("error",{column:r,error:i,line:n,msg:e,url:t}),Ro?Ro.apply(this,arguments):!1},q.onerror.__SENTRY_INSTRUMENTED__=!0}let Ao=null;function yf(e){const t="unhandledrejection";ln(t,e),dn(t,Vg)}function Vg(){Ao=q.onunhandledrejection,q.onunhandledrejection=function(e){return it("unhandledrejection",e),Ao?Ao.apply(this,arguments):!0},q.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const bf=Object.prototype.toString;function nn(e){switch(bf.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return $t(e,Error)}}function Cr(e,t){return bf.call(e)===`[object ${t}]`}function Sf(e){return Cr(e,"ErrorEvent")}function Iu(e){return Cr(e,"DOMError")}function Xg(e){return Cr(e,"DOMException")}function ht(e){return Cr(e,"String")}function eo(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function or(e){return e===null||eo(e)||typeof e!="object"&&typeof e!="function"}function Ut(e){return Cr(e,"Object")}function to(e){return typeof Event<"u"&&$t(e,Event)}function Yg(e){return typeof Element<"u"&&$t(e,Element)}function Jg(e){return Cr(e,"RegExp")}function fi(e){return!!(e?.then&&typeof e.then=="function")}function Kg(e){return Ut(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function $t(e,t){try{return e instanceof t}catch{return!1}}function Ef(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}function vf(e){return typeof Request<"u"&&$t(e,Request)}const yc=q,Zg=80;function st(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,i=[];let s=0,o=0;const a=" > ",c=a.length;let u;const d=Array.isArray(t)?t:t.keyAttrs,l=!Array.isArray(t)&&t.maxStringLength||Zg;for(;n&&s++<r&&(u=Qg(n,d),!(u==="html"||s>1&&o+i.length*c+u.length>=l));)i.push(u),o+=u.length,n=n.parentNode;return i.reverse().join(a)}catch{return"<unknown>"}}function Qg(e,t){const n=e,r=[];if(!n?.tagName)return"";if(yc.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const i=t?.length?t.filter(o=>n.getAttribute(o)).map(o=>[o,n.getAttribute(o)]):null;if(i?.length)i.forEach(o=>{r.push(`[${o[0]}="${o[1]}"]`)});else{n.id&&r.push(`#${n.id}`);const o=n.className;if(o&&ht(o)){const a=o.split(/\s+/);for(const c of a)r.push(`.${c}`)}}const s=["aria-label","type","name","title","alt"];for(const o of s){const a=n.getAttribute(o);a&&r.push(`[${o}="${a}"]`)}return r.join("")}function Pn(){try{return yc.document.location.href}catch{return""}}function wf(e){if(!yc.HTMLElement)return null;let t=e;const n=5;for(let r=0;r<n;r++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function ar(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function Mo(e,t){let n=e;const r=n.length;if(r<=150)return n;t>r&&(t=r);let i=Math.max(t-60,0);i<5&&(i=0);let s=Math.min(i+140,r);return s>r-5&&(s=r),s===r&&(i=Math.max(s-140,0)),n=n.slice(i,s),i>0&&(n=`'{snip} ${n}`),s<r&&(n+=" {snip}"),n}function xs(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const i=e[r];try{Ef(i)?n.push("[VueViewModel]"):n.push(String(i))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function e_(e,t,n=!1){return ht(e)?Jg(t)?t.test(e):ht(t)?n?e===t:e.includes(t):!1:!1}function pt(e,t=[],n=!1){return t.some(r=>e_(e,r,n))}function ze(e,t,n){if(!(t in e))return;const r=e[t];if(typeof r!="function")return;const i=n(r);typeof i=="function"&&Tf(i,r);try{e[t]=i}catch{D&&y.log(`Failed to replace method "${t}" in object`,e)}}function Ye(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{D&&y.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function Tf(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,Ye(e,"__sentry_original__",t)}catch{}}function bc(e){return e.__sentry_original__}function If(e){if(nn(e))return{message:e.message,name:e.name,stack:e.stack,...ku(e)};if(to(e)){const t={type:e.type,target:xu(e.target),currentTarget:xu(e.currentTarget),...ku(e)};return typeof CustomEvent<"u"&&$t(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function xu(e){try{return Yg(e)?st(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function ku(e){if(typeof e=="object"&&e!==null){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}else return{}}function t_(e,t=40){const n=Object.keys(If(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return ar(r,t);for(let i=n.length;i>0;i--){const s=n.slice(0,i).join(", ");if(!(s.length>t))return i===n.length?s:ar(s,t)}return""}function n_(){const e=q;return e.crypto||e.msCrypto}function je(e=n_()){let t=()=>Math.random()*16;try{if(e?.randomUUID)return e.randomUUID().replace(/-/g,"");e?.getRandomValues&&(t=()=>{const n=new Uint8Array(1);return e.getRandomValues(n),n[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,n=>(n^(t()&15)>>n/4).toString(16))}function xf(e){return e.exception?.values?.[0]}function bn(e){const{message:t,event_id:n}=e;if(t)return t;const r=xf(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function ba(e,t,n){const r=e.exception=e.exception||{},i=r.values=r.values||[],s=i[0]=i[0]||{};s.value||(s.value=t||""),s.type||(s.type="Error")}function sn(e,t){const n=xf(e);if(!n)return;const r={type:"generic",handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&"data"in t){const s={...i?.data,...t.data};n.mechanism.data=s}}function r_(e,t,n=5){if(t.lineno===void 0)return;const r=e.length,i=Math.max(Math.min(r-1,t.lineno-1),0);t.pre_context=e.slice(Math.max(0,i-n),i).map(o=>Mo(o,0));const s=Math.min(r-1,i);t.context_line=Mo(e[s],t.colno||0),t.post_context=e.slice(Math.min(i+1,r),i+1+n).map(o=>Mo(o,0))}function Cu(e){if(i_(e))return!0;try{Ye(e,"__sentry_captured__",!0)}catch{}return!1}function i_(e){try{return e.__sentry_captured__}catch{}}const kf=1e3;function Dn(){return Date.now()/kf}function s_(){const{performance:e}=q;if(!e?.now||!e.timeOrigin)return Dn;const t=e.timeOrigin;return()=>(t+e.now())/kf}let Ru;function xe(){return(Ru??(Ru=s_()))()}let No;function o_(){const{performance:e}=q;if(!e?.now)return[void 0,"none"];const t=3600*1e3,n=e.now(),r=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,s=i<t,o=e.timing?.navigationStart,c=typeof o=="number"?Math.abs(o+n-r):t,u=c<t;return s||u?i<=c?[e.timeOrigin,"timeOrigin"]:[o,"navigationStart"]:[r,"dateNow"]}function Be(){return No||(No=o_()),No[0]}function a_(e){const t=xe(),n={sid:je(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>u_(n)};return e&&cr(n,e),n}function cr(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||xe(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:je()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function c_(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),cr(e,n)}function u_(e){return{sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}}}function hi(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&Object.keys(t).length===0)return e;const r={...e};for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=hi(r[i],t[i],n-1));return r}function Wt(){return je()}function pi(){return je().substring(16)}const Sa="_sentrySpan";function Rn(e,t){t?Ye(e,Sa,t):delete e[Sa]}function ti(e){return e[Sa]}const l_=100;class mt{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:Wt(),sampleRand:Math.random()}}clone(){const t=new mt;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,Rn(t,ti(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&cr(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const n=typeof t=="function"?t(this):t,r=n instanceof mt?n.getScopeData():Ut(n)?t:void 0,{tags:i,extra:s,user:o,contexts:a,level:c,fingerprint:u=[],propagationContext:d}=r||{};return this._tags={...this._tags,...i},this._extra={...this._extra,...s},this._contexts={...this._contexts,...a},o&&Object.keys(o).length&&(this._user=o),c&&(this._level=c),u.length&&(this._fingerprint=u),d&&(this._propagationContext=d),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,Rn(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Wt(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(t,n){const r=typeof n=="number"?n:l_;if(r<=0)return this;const i={timestamp:Dn(),...t,message:t.message?ar(t.message,2048):t.message};return this._breadcrumbs.push(i),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),this._client?.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:ti(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=hi(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=n?.event_id||je();if(!this._client)return D&&y.warn("No client configured on scope - will not capture exception!"),r;const i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...n,event_id:r},this),r}captureMessage(t,n,r){const i=r?.event_id||je();if(!this._client)return D&&y.warn("No client configured on scope - will not capture message!"),i;const s=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:s,...r,event_id:i},this),i}captureEvent(t,n){const r=n?.event_id||je();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(D&&y.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}function d_(){return di("defaultCurrentScope",()=>new mt)}function f_(){return di("defaultIsolationScope",()=>new mt)}class h_{constructor(t,n){let r;t?r=t:r=new mt;let i;n?i=n:i=new mt,this._stack=[{scope:r}],this._isolationScope=i}withScope(t){const n=this._pushScope();let r;try{r=t(n)}catch(i){throw this._popScope(),i}return fi(r)?r.then(i=>(this._popScope(),i),i=>{throw this._popScope(),i}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function ur(){const e=Vt(),t=li(e);return t.stack=t.stack||new h_(d_(),f_())}function p_(e){return ur().withScope(e)}function m_(e,t){const n=ur();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function Au(e){return ur().withScope(()=>e(ur().getIsolationScope()))}function g_(){return{withIsolationScope:Au,withScope:p_,withSetScope:m_,withSetIsolationScope:(e,t)=>Au(t),getCurrentScope:()=>ur().getScope(),getIsolationScope:()=>ur().getIsolationScope()}}function fn(e){const t=li(e);return t.acs?t.acs:g_()}function Q(){const e=Vt();return fn(e).getCurrentScope()}function Le(){const e=Vt();return fn(e).getIsolationScope()}function no(){return di("globalScope",()=>new mt)}function ot(...e){const t=Vt(),n=fn(t);if(e.length===2){const[r,i]=e;return r?n.withSetScope(r,i):n.withScope(i)}return n.withScope(e[0])}function __(...e){const t=Vt(),n=fn(t);if(e.length===2){const[r,i]=e;return r?n.withSetIsolationScope(r,i):n.withIsolationScope(i)}return n.withIsolationScope(e[0])}function H(){return Q().getClient()}function Cf(e){const t=e.getPropagationContext(),{traceId:n,parentSpanId:r,propagationSpanId:i}=t,s={trace_id:n,span_id:i||pi()};return r&&(s.parent_span_id=r),s}const tt="sentry.source",ro="sentry.sample_rate",Rf="sentry.previous_trace_sample_rate",rt="sentry.op",Se="sentry.origin",ks="sentry.idle_span_finish_reason",mi="sentry.measurement_unit",gi="sentry.measurement_value",Ea="sentry.custom_span_name",Sc="sentry.profile_id",Rr="sentry.exclusive_time",y_="http.request.method",b_="url.full",S_="sentry.link.type",E_=0,Ec=1,we=2;function Af(e){if(e<400&&e>=100)return{code:Ec};if(e>=400&&e<500)switch(e){case 401:return{code:we,message:"unauthenticated"};case 403:return{code:we,message:"permission_denied"};case 404:return{code:we,message:"not_found"};case 409:return{code:we,message:"already_exists"};case 413:return{code:we,message:"failed_precondition"};case 429:return{code:we,message:"resource_exhausted"};case 499:return{code:we,message:"cancelled"};default:return{code:we,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:we,message:"unimplemented"};case 503:return{code:we,message:"unavailable"};case 504:return{code:we,message:"deadline_exceeded"};default:return{code:we,message:"internal_error"}}return{code:we,message:"unknown_error"}}function ni(e,t){e.setAttribute("http.response.status_code",t);const n=Af(t);n.message!=="unknown_error"&&e.setStatus(n)}const Mf="_sentryScope",Nf="_sentryIsolationScope";function v_(e,t,n){e&&(Ye(e,Nf,n),Ye(e,Mf,t))}function Cs(e){return{scope:e[Mf],isolationScope:e[Nf]}}const vc="sentry-",w_=/^sentry-/,T_=8192;function Of(e){const t=I_(e);if(!t)return;const n=Object.entries(t).reduce((r,[i,s])=>{if(i.match(w_)){const o=i.slice(vc.length);r[o]=s}return r},{});if(Object.keys(n).length>0)return n}function Lf(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,i])=>(i&&(n[`${vc}${r}`]=i),n),{});return x_(t)}function I_(e){if(!(!e||!ht(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=Mu(n);return Object.entries(r).forEach(([i,s])=>{t[i]=s}),t},{}):Mu(e)}function Mu(e){return e.split(",").map(t=>t.split("=").map(n=>{try{return decodeURIComponent(n.trim())}catch{return}})).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function x_(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],i)=>{const s=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,o=i===0?s:`${t},${s}`;return o.length>T_?(D&&y.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):o},"")}function An(e){if(typeof e=="boolean")return Number(e);const t=typeof e=="string"?parseFloat(e):e;if(!(typeof t!="number"||isNaN(t)||t<0||t>1))return t}const Pf=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function k_(e){if(!e)return;const t=e.match(Pf);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function Df(e,t){const n=k_(e),r=Of(t);if(!n?.traceId)return{traceId:Wt(),sampleRand:Math.random()};const i=C_(n,r);r&&(r.sample_rand=i.toString());const{traceId:s,parentSpanId:o,parentSampled:a}=n;return{traceId:s,parentSpanId:o,sampled:a,dsc:r||{},sampleRand:i}}function Ff(e=Wt(),t=pi(),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}function C_(e,t){const n=An(t?.sample_rand);if(n!==void 0)return n;const r=An(t?.sample_rate);return r&&e?.parentSampled!==void 0?e.parentSampled?Math.random()*r:r+Math.random()*(1-r):Math.random()}const Hf=0,wc=1;let Nu=!1;function R_(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:s,status:o,origin:a,links:c}=Z(e);return{parent_span_id:s,span_id:t,trace_id:n,data:r,op:i,status:o,origin:a,links:c}}function Bf(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:Z(e).parent_span_id,s=Cs(e).scope,o=r?s?.getPropagationContext().propagationSpanId||pi():t;return{parent_span_id:i,span_id:o,trace_id:n}}function Uf(e){const{traceId:t,spanId:n}=e.spanContext(),r=Fn(e);return Ff(t,n,r)}function $f(e){if(e&&e.length>0)return e.map(({context:{spanId:t,traceId:n,traceFlags:r,...i},attributes:s})=>({span_id:t,trace_id:n,sampled:r===wc,attributes:s,...i}))}function xn(e){return typeof e=="number"?Ou(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?Ou(e.getTime()):xe()}function Ou(e){return e>9999999999?e/1e3:e}function Z(e){if(M_(e))return e.getSpanJSON();const{spanId:t,traceId:n}=e.spanContext();if(A_(e)){const{attributes:r,startTime:i,name:s,endTime:o,status:a,links:c}=e,u="parentSpanId"in e?e.parentSpanId:"parentSpanContext"in e?e.parentSpanContext?.spanId:void 0;return{span_id:t,trace_id:n,data:r,description:s,parent_span_id:u,start_timestamp:xn(i),timestamp:xn(o)||void 0,status:Wf(a),op:r[rt],origin:r[Se],links:$f(c)}}return{span_id:t,trace_id:n,start_timestamp:0,data:{}}}function A_(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function M_(e){return typeof e.getSpanJSON=="function"}function Fn(e){const{traceFlags:t}=e.spanContext();return t===wc}function Wf(e){if(!(!e||e.code===E_))return e.code===Ec?"ok":e.message||"unknown_error"}const kn="_sentryChildSpans",va="_sentryRootSpan";function Gf(e,t){const n=e[va]||e;Ye(t,va,n),e[kn]?e[kn].add(t):Ye(e,kn,new Set([t]))}function N_(e,t){e[kn]&&e[kn].delete(t)}function Yr(e){const t=new Set;function n(r){if(!t.has(r)&&Fn(r)){t.add(r);const i=r[kn]?Array.from(r[kn]):[];for(const s of i)n(s)}}return n(e),Array.from(t)}function Oe(e){return e[va]||e}function Pe(){const e=Vt(),t=fn(e);return t.getActiveSpan?t.getActiveSpan():ti(Q())}function wa(){Nu||(un(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly.")}),Nu=!0)}function O_(e,t){e.updateName(t),e.setAttributes({[tt]:"custom",[Ea]:t})}let Lu=!1;function zf(){if(Lu)return;function e(){const t=Pe(),n=t&&Oe(t);if(n){const r="internal_error";D&&y.log(`[Tracing] Root span: ${r} -> Global error occurred`),n.setStatus({code:we,message:r})}}e.tag="sentry_tracingErrorCallback",Lu=!0,_f(e),yf(e)}function on(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=e||H()?.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}const io="production",L_=/^o(\d+)\./,P_=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function D_(e){return e==="http"||e==="https"}function Hn(e,t=!1){const{host:n,path:r,pass:i,port:s,projectId:o,protocol:a,publicKey:c}=e;return`${a}://${c}${t&&i?`:${i}`:""}@${n}${s?`:${s}`:""}/${r&&`${r}/`}${o}`}function jf(e){const t=P_.exec(e);if(!t){un(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,i="",s="",o="",a=""]=t.slice(1);let c="",u=a;const d=u.split("/");if(d.length>1&&(c=d.slice(0,-1).join("/"),u=d.pop()),u){const l=u.match(/^\d+/);l&&(u=l[0])}return qf({host:s,pass:i,path:c,projectId:u,port:o,protocol:n,publicKey:r})}function qf(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function F_(e){if(!D)return!0;const{port:t,projectId:n,protocol:r}=e;return["protocol","publicKey","host","projectId"].find(o=>e[o]?!1:(y.error(`Invalid Sentry Dsn: ${o} missing`),!0))?!1:n.match(/^\d+$/)?D_(r)?t&&isNaN(parseInt(t,10))?(y.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(y.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(y.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function H_(e){return e.match(L_)?.[1]}function Vf(e){const t=typeof e=="string"?jf(e):qf(e);if(!(!t||!F_(t)))return t}const Xf="_frozenDsc";function as(e,t){Ye(e,Xf,t)}function Yf(e,t){const n=t.getOptions(),{publicKey:r,host:i}=t.getDsn()||{};let s;n.orgId?s=String(n.orgId):i&&(s=H_(i));const o={environment:n.environment||io,release:n.release,public_key:r,trace_id:e,org_id:s};return t.emit("createDsc",o),o}function Tc(e,t){const n=t.getPropagationContext();return n.dsc||Yf(n.traceId,e)}function gt(e){const t=H();if(!t)return{};const n=Oe(e),r=Z(n),i=r.data,s=n.spanContext().traceState,o=s?.get("sentry.sample_rate")??i[ro]??i[Rf];function a(p){return(typeof o=="number"||typeof o=="string")&&(p.sample_rate=`${o}`),p}const c=n[Xf];if(c)return a(c);const u=s?.get("sentry.dsc"),d=u&&Of(u);if(d)return a(d);const l=Yf(e.spanContext().traceId,t),f=i[tt],h=r.description;return f!=="url"&&h&&(l.transaction=h),on()&&(l.sampled=String(Fn(n)),l.sample_rand=s?.get("sentry.sample_rand")??Cs(n).scope?.getPropagationContext().sampleRand.toString()),a(l),t.emit("createDsc",l,n),l}function B_(e){const t=gt(e);return Lf(t)}class Gt{constructor(t={}){this._traceId=t.traceId||Wt(),this._spanId=t.spanId||pi()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:Hf}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,r){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}function Ze(e,t=100,n=1/0){try{return Ta("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function Jf(e,t=3,n=100*1024){const r=Ze(e,t);return G_(r)>n?Jf(e,t-1,n):r}function Ta(e,t,n=1/0,r=1/0,i=z_()){const[s,o]=i;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const a=U_(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;const c=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(c===0)return a.replace("object ","");if(s(t))return"[Circular ~]";const u=t;if(u&&typeof u.toJSON=="function")try{const h=u.toJSON();return Ta("",h,c-1,r,i)}catch{}const d=Array.isArray(t)?[]:{};let l=0;const f=If(t);for(const h in f){if(!Object.prototype.hasOwnProperty.call(f,h))continue;if(l>=r){d[h]="[MaxProperties ~]";break}const p=f[h];d[h]=Ta(h,p,c-1,r,i),l++}return o(t),d}function U_(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Ef(t))return"[VueViewModel]";if(Kg(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${Bt(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=$_(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function $_(e){const t=Object.getPrototypeOf(e);return t?.constructor?t.constructor.name:"null prototype"}function W_(e){return~-encodeURI(e).split(/%..|./).length}function G_(e){return W_(JSON.stringify(e))}function z_(){const e=new WeakSet;function t(r){return e.has(r)?!0:(e.add(r),!1)}function n(r){e.delete(r)}return[t,n]}function Xt(e,t=[]){return[e,t]}function j_(e,t){const[n,r]=e;return[n,[...r,t]]}function Mn(e,t){const n=e[1];for(const r of n){const i=r[0].type;if(t(r,i))return!0}return!1}function Pu(e,t){return Mn(e,(n,r)=>t.includes(r))}function Rs(e){const t=li(q);return t.encodePolyfill?t.encodePolyfill(e):new TextEncoder().encode(e)}function q_(e){const t=li(q);return t.decodePolyfill?t.decodePolyfill(e):new TextDecoder().decode(e)}function As(e){const[t,n]=e;let r=JSON.stringify(t);function i(s){typeof r=="string"?r=typeof s=="string"?r+s:[Rs(r),s]:r.push(typeof s=="string"?Rs(s):s)}for(const s of n){const[o,a]=s;if(i(`
7
+ ${JSON.stringify(o)}
8
+ `),typeof a=="string"||a instanceof Uint8Array)i(a);else{let c;try{c=JSON.stringify(a)}catch{c=JSON.stringify(Ze(a))}i(c)}}return typeof r=="string"?r:V_(r)}function V_(e){const t=e.reduce((i,s)=>i+s.length,0),n=new Uint8Array(t);let r=0;for(const i of e)n.set(i,r),r+=i.length;return n}function X_(e){let t=typeof e=="string"?Rs(e):e;function n(o){const a=t.subarray(0,o);return t=t.subarray(o+1),a}function r(){let o=t.indexOf(10);return o<0&&(o=t.length),JSON.parse(q_(n(o)))}const i=r(),s=[];for(;t.length;){const o=r(),a=typeof o.length=="number"?o.length:void 0;s.push([o,a?n(a):r()])}return[i,s]}function Y_(e){return[{type:"span"},e]}function J_(e){const t=typeof e.data=="string"?Rs(e.data):e.data;return[{type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType},t]}const K_={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",raw_security:"security",log:"log_item"};function Du(e){return K_[e]}function Ic(e){if(!e?.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function Kf(e,t,n,r){const i=e.sdkProcessingMetadata?.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Hn(r)},...i&&{trace:i}}}function Z_(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function Q_(e,t,n,r){const i=Ic(n),s={sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:Hn(t)}},o="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return Xt(s,[o])}function ey(e,t,n,r){const i=Ic(n),s=e.type&&e.type!=="replay_event"?e.type:"event";Z_(e,n?.sdk);const o=Kf(e,i,r,t);return delete e.sdkProcessingMetadata,Xt(o,[[{type:s},e]])}function ty(e,t){function n(d){return!!d.trace_id&&!!d.public_key}const r=gt(e[0]),i=t?.getDsn(),s=t?.getOptions().tunnel,o={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!s&&i&&{dsn:Hn(i)}},a=t?.getOptions().beforeSendSpan,c=a?d=>{const l=Z(d),f=a(l);return f||(wa(),l)}:Z,u=[];for(const d of e){const l=c(d);l&&u.push(Y_(l))}return Xt(o,u)}function ny(e){if(!D)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=Z(e),{spanId:i}=e.spanContext(),s=Fn(e),o=Oe(e),a=o===e,c=`[Tracing] Starting ${s?"sampled":"unsampled"} ${a?"root ":""}span`,u=[`op: ${n}`,`name: ${t}`,`ID: ${i}`];if(r&&u.push(`parent ID: ${r}`),!a){const{op:d,description:l}=Z(o);u.push(`root ID: ${o.spanContext().spanId}`),d&&u.push(`root op: ${d}`),l&&u.push(`root description: ${l}`)}y.log(`${c}
9
+ ${u.join(`
10
+ `)}`)}function ry(e){if(!D)return;const{description:t="< unknown name >",op:n="< unknown op >"}=Z(e),{spanId:r}=e.spanContext(),s=Oe(e)===e,o=`[Tracing] Finishing "${n}" ${s?"root ":""}span "${t}" with ID ${r}`;y.log(o)}function Zf(e,t,n,r=Pe()){const i=r&&Oe(r);i&&(D&&y.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),i.addEvent(e,{[gi]:t,[mi]:n}))}function Fu(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},i=r[mi],s=r[gi];typeof i=="string"&&typeof s=="number"&&(t[n.name]={value:s,unit:i})}),t}const Hu=1e3;class so{constructor(t={}){this._traceId=t.traceId||Wt(),this._spanId=t.spanId||pi(),this._startTime=t.startTimestamp||xe(),this._links=t.links,this._attributes={},this.setAttributes({[Se]:"manual",[rt]:t.op,...t.attributes}),this._name=t.name,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.endTimestamp&&(this._endTime=t.endTimestamp),this._events=[],this._isStandaloneSpan=t.isStandalone,this._endTime&&this._onSpanEnded()}addLink(t){return this._links?this._links.push(t):this._links=[t],this}addLinks(t){return this._links?this._links.push(...t):this._links=t,this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?wc:Hf}}setAttribute(t,n){return n===void 0?delete this._attributes[t]:this._attributes[t]=n,this}setAttributes(t){return Object.keys(t).forEach(n=>this.setAttribute(n,t[n])),this}updateStartTime(t){this._startTime=xn(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(tt,"custom"),this}end(t){this._endTime||(this._endTime=xn(t),ry(this),this._onSpanEnded())}getSpanJSON(){return{data:this._attributes,description:this._name,op:this._attributes[rt],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:Wf(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[Se],profile_id:this._attributes[Sc],exclusive_time:this._attributes[Rr],measurements:Fu(this._events),is_segment:this._isStandaloneSpan&&Oe(this)===this||void 0,segment_id:this._isStandaloneSpan?Oe(this).spanContext().spanId:void 0,links:$f(this._links)}}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){D&&y.log("[Tracing] Adding an event to span:",t);const i=Bu(n)?n:r||xe(),s=Bu(n)?{}:n||{},o={name:t,time:xn(i),attributes:s};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=H();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===Oe(this)))return;if(this._isStandaloneSpan){this._sampled?sy(ty([this],t)):(D&&y.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),t&&t.recordDroppedEvent("sample_rate","span"));return}const r=this._convertSpanToTransaction();r&&(Cs(this).scope||Q()).captureEvent(r)}_convertSpanToTransaction(){if(!Uu(Z(this)))return;this._name||(D&&y.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=Cs(this),r=t?.getScopeData().sdkProcessingMetadata?.normalizedRequest;if(this._sampled!==!0)return;const s=Yr(this).filter(d=>d!==this&&!iy(d)).map(d=>Z(d)).filter(Uu),o=this._attributes[tt];delete this._attributes[Ea],s.forEach(d=>{delete d.data[Ea]});const a={contexts:{trace:R_(this)},spans:s.length>Hu?s.sort((d,l)=>d.start_timestamp-l.start_timestamp).slice(0,Hu):s,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,dynamicSamplingContext:gt(this)},request:r,...o&&{transaction_info:{source:o}}},c=Fu(this._events);return c&&Object.keys(c).length&&(D&&y.log("[Measurements] Adding measurements to transaction event",JSON.stringify(c,void 0,2)),a.measurements=c),a}}function Bu(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function Uu(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function iy(e){return e instanceof so&&e.isStandaloneSpan()}function sy(e){const t=H();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}function Qf(e,t,n=()=>{}){let r;try{r=e()}catch(i){throw t(i),n(),i}return oy(r,t,n)}function oy(e,t,n){return fi(e)?e.then(r=>(n(),r),r=>{throw t(r),n(),r}):(n(),e)}function ay(e,t,n){if(!on(e))return[!1];let r,i;typeof e.tracesSampler=="function"?(i=e.tracesSampler({...t,inheritOrSampleWith:a=>typeof t.parentSampleRate=="number"?t.parentSampleRate:typeof t.parentSampled=="boolean"?Number(t.parentSampled):a}),r=!0):t.parentSampled!==void 0?i=t.parentSampled:typeof e.tracesSampleRate<"u"&&(i=e.tracesSampleRate,r=!0);const s=An(i);if(s===void 0)return D&&y.warn(`[Tracing] Discarding root span because of invalid sample rate. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(i)} of type ${JSON.stringify(typeof i)}.`),[!1];if(!s)return D&&y.log(`[Tracing] Discarding transaction because ${typeof e.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,s,r];const o=n<s;return o||D&&y.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(i)})`),[o,s,r]}const Ms="__SENTRY_SUPPRESS_TRACING__";function oo(e,t){const n=yi();if(n.startSpan)return n.startSpan(e,t);const r=kc(e),{forceTransaction:i,parentSpan:s,scope:o}=e,a=o?.clone();return ot(a,()=>eh(s)(()=>{const u=Q(),d=Cc(u,s),f=e.onlyIfParent&&!d?new Gt:xc({parentSpan:d,spanArguments:r,forceTransaction:i,scope:u});return Rn(u,f),Qf(()=>t(f),()=>{const{status:h}=Z(f);f.isRecording()&&(!h||h==="ok")&&f.setStatus({code:we,message:"internal_error"})},()=>{f.end()})}))}function cy(e,t){const n=yi();if(n.startSpanManual)return n.startSpanManual(e,t);const r=kc(e),{forceTransaction:i,parentSpan:s,scope:o}=e,a=o?.clone();return ot(a,()=>eh(s)(()=>{const u=Q(),d=Cc(u,s),f=e.onlyIfParent&&!d?new Gt:xc({parentSpan:d,spanArguments:r,forceTransaction:i,scope:u});return Rn(u,f),Qf(()=>t(f,()=>f.end()),()=>{const{status:h}=Z(f);f.isRecording()&&(!h||h==="ok")&&f.setStatus({code:we,message:"internal_error"})})}))}function Bn(e){const t=yi();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=kc(e),{forceTransaction:r,parentSpan:i}=e;return(e.scope?o=>ot(e.scope,o):i!==void 0?o=>_i(i,o):o=>o())(()=>{const o=Q(),a=Cc(o,i);return e.onlyIfParent&&!a?new Gt:xc({parentSpan:a,spanArguments:n,forceTransaction:r,scope:o})})}const uy=(e,t)=>{const n=Vt(),r=fn(n);if(r.continueTrace)return r.continueTrace(e,t);const{sentryTrace:i,baggage:s}=e;return ot(o=>{const a=Df(i,s);return o.setPropagationContext(a),t()})};function _i(e,t){const n=yi();return n.withActiveSpan?n.withActiveSpan(e,t):ot(r=>(Rn(r,e||void 0),t(r)))}function ly(e){const t=yi();return t.suppressTracing?t.suppressTracing(e):ot(n=>{n.setSDKProcessingMetadata({[Ms]:!0});const r=e();return n.setSDKProcessingMetadata({[Ms]:void 0}),r})}function dy(e){return ot(t=>(t.setPropagationContext({traceId:Wt(),sampleRand:Math.random()}),D&&y.log(`Starting a new trace with id ${t.getPropagationContext().traceId}`),_i(null,e)))}function xc({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!on()){const o=new Gt;if(n||!e){const a={sampled:"false",sample_rate:"0",transaction:t.name,...gt(o)};as(o,a)}return o}const i=Le();let s;if(e&&!n)s=fy(e,r,t),Gf(e,s);else if(e){const o=gt(e),{traceId:a,spanId:c}=e.spanContext(),u=Fn(e);s=$u({traceId:a,parentSpanId:c,...t},r,u),as(s,o)}else{const{traceId:o,dsc:a,parentSpanId:c,sampled:u}={...i.getPropagationContext(),...r.getPropagationContext()};s=$u({traceId:o,parentSpanId:c,...t},r,u),a&&as(s,a)}return ny(s),v_(s,r,i),s}function kc(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=xn(e.startTime),delete r.startTime,r}return n}function yi(){const e=Vt();return fn(e)}function $u(e,t,n){const r=H(),i=r?.getOptions()||{},{name:s=""}=e,o={spanAttributes:{...e.attributes},spanName:s,parentSampled:n};r?.emit("beforeSampling",o,{decision:!1});const a=o.parentSampled??n,c=o.spanAttributes,u=t.getPropagationContext(),[d,l,f]=t.getScopeData().sdkProcessingMetadata[Ms]?[!1]:ay(i,{name:s,parentSampled:a,attributes:c,parentSampleRate:An(u.dsc?.sample_rate)},u.sampleRand),h=new so({...e,attributes:{[tt]:"custom",[ro]:l!==void 0&&f?l:void 0,...c},sampled:d});return!d&&r&&(D&&y.log("[Tracing] Discarding root span because its trace was not chosen to be sampled."),r.recordDroppedEvent("sample_rate","transaction")),r&&r.emit("spanStart",h),h}function fy(e,t,n){const{spanId:r,traceId:i}=e.spanContext(),s=t.getScopeData().sdkProcessingMetadata[Ms]?!1:Fn(e),o=s?new so({...n,parentSpanId:r,traceId:i,sampled:s}):new Gt({traceId:i});Gf(e,o);const a=H();return a&&(a.emit("spanStart",o),n.endTimestamp&&a.emit("spanEnd",o)),o}function Cc(e,t){if(t)return t;if(t===null)return;const n=ti(e);if(!n)return;const r=H();return(r?r.getOptions():{}).parentSpanIsAlwaysRootSpan?Oe(n):n}function eh(e){return e!==void 0?t=>_i(e,t):t=>t()}const cs={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},hy="heartbeatFailed",py="idleTimeout",my="finalTimeout",gy="externalFinish";function th(e,t={}){const n=new Map;let r=!1,i,s=gy,o=!t.disableAutoFinish;const a=[],{idleTimeout:c=cs.idleTimeout,finalTimeout:u=cs.finalTimeout,childSpanTimeout:d=cs.childSpanTimeout,beforeSpanEnd:l}=t,f=H();if(!f||!on()){const T=new Gt,C={sample_rate:"0",sampled:"false",...gt(T)};return as(T,C),T}const h=Q(),p=Pe(),m=_y(e);m.end=new Proxy(m.end,{apply(T,C,M){if(l&&l(m),C instanceof Gt)return;const[x,...R]=M,P=x||xe(),k=xn(P),F=Yr(m).filter(G=>G!==m);if(!F.length)return O(k),Reflect.apply(T,C,[k,...R]);const X=F.map(G=>Z(G).timestamp).filter(G=>!!G),U=X.length?Math.max(...X):void 0,J=Z(m).start_timestamp,N=Math.min(J?J+u/1e3:1/0,Math.max(J||-1/0,Math.min(k,U||1/0)));return O(N),Reflect.apply(T,C,[N,...R])}});function g(){i&&(clearTimeout(i),i=void 0)}function _(T){g(),i=setTimeout(()=>{!r&&n.size===0&&o&&(s=py,m.end(T))},c)}function v(T){i=setTimeout(()=>{!r&&o&&(s=hy,m.end(T))},d)}function L(T){g(),n.set(T,!0);const C=xe();v(C+d/1e3)}function A(T){if(n.has(T)&&n.delete(T),n.size===0){const C=xe();_(C+c/1e3)}}function O(T){r=!0,n.clear(),a.forEach(k=>k()),Rn(h,p);const C=Z(m),{start_timestamp:M}=C;if(!M)return;C.data[ks]||m.setAttribute(ks,s),y.log(`[Tracing] Idle span "${C.op}" finished`);const R=Yr(m).filter(k=>k!==m);let P=0;R.forEach(k=>{k.isRecording()&&(k.setStatus({code:we,message:"cancelled"}),k.end(T),D&&y.log("[Tracing] Cancelling span since span ended early",JSON.stringify(k,void 0,2)));const F=Z(k),{timestamp:X=0,start_timestamp:U=0}=F,J=U<=T,N=(u+c)/1e3,G=X-U<=N;if(D){const B=JSON.stringify(k,void 0,2);J?G||y.log("[Tracing] Discarding span since it finished after idle span final timeout",B):y.log("[Tracing] Discarding span since it happened after idle span was finished",B)}(!G||!J)&&(N_(m,k),P++)}),P>0&&m.setAttribute("sentry.idle_span_discarded_spans",P)}return a.push(f.on("spanStart",T=>{if(r||T===m||Z(T).timestamp||T instanceof so&&T.isStandaloneSpan())return;Yr(m).includes(T)&&L(T.spanContext().spanId)})),a.push(f.on("spanEnd",T=>{r||A(T.spanContext().spanId)})),a.push(f.on("idleSpanEnableAutoFinish",T=>{T===m&&(o=!0,_(),n.size&&v())})),t.disableAutoFinish||_(),setTimeout(()=>{r||(m.setStatus({code:we,message:"deadline_exceeded"}),s=my,m.end())},u),m}function _y(e){const t=Bn(e);return Rn(Q(),t),D&&y.log("[Tracing] Started span is an idle span"),t}const Oo=0,Wu=1,Gu=2;function zt(e){return new an(t=>{t(e)})}function Ns(e){return new an((t,n)=>{n(e)})}class an{constructor(t){this._state=Oo,this._handlers=[],this._runExecutor(t)}then(t,n){return new an((r,i)=>{this._handlers.push([!1,s=>{if(!t)r(s);else try{r(t(s))}catch(o){i(o)}},s=>{if(!n)i(s);else try{r(n(s))}catch(o){i(o)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new an((n,r)=>{let i,s;return this.then(o=>{s=!1,i=o,t&&t()},o=>{s=!0,i=o,t&&t()}).then(()=>{if(s){r(i);return}n(i)})})}_executeHandlers(){if(this._state===Oo)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===Wu&&n[1](this._value),this._state===Gu&&n[2](this._value),n[0]=!0)})}_runExecutor(t){const n=(s,o)=>{if(this._state===Oo){if(fi(o)){o.then(r,i);return}this._state=s,this._value=o,this._executeHandlers()}},r=s=>{n(Wu,s)},i=s=>{n(Gu,s)};try{t(r,i)}catch(s){i(s)}}}function Ia(e,t,n,r=0){return new an((i,s)=>{const o=e[r];if(t===null||typeof o!="function")i(t);else{const a=o({...t},n);D&&o.id&&a===null&&y.log(`Event processor "${o.id}" dropped event`),fi(a)?a.then(c=>Ia(e,c,n,r+1).then(i)).then(null,s):Ia(e,a,n,r+1).then(i).then(null,s)}})}function yy(e,t){const{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:s}=t;by(e,t),r&&vy(e,r),wy(e,n),Sy(e,i),Ey(e,s)}function Os(e,t){const{extra:n,tags:r,user:i,contexts:s,level:o,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:u,eventProcessors:d,attachments:l,propagationContext:f,transactionName:h,span:p}=t;Oi(e,"extra",n),Oi(e,"tags",r),Oi(e,"user",i),Oi(e,"contexts",s),e.sdkProcessingMetadata=hi(e.sdkProcessingMetadata,a,2),o&&(e.level=o),h&&(e.transactionName=h),p&&(e.span=p),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),l.length&&(e.attachments=[...e.attachments,...l]),e.propagationContext={...e.propagationContext,...f}}function Oi(e,t,n){e[t]=hi(e[t],n,1)}function by(e,t){const{extra:n,tags:r,user:i,contexts:s,level:o,transactionName:a}=t;Object.keys(n).length&&(e.extra={...n,...e.extra}),Object.keys(r).length&&(e.tags={...r,...e.tags}),Object.keys(i).length&&(e.user={...i,...e.user}),Object.keys(s).length&&(e.contexts={...s,...e.contexts}),o&&(e.level=o),a&&e.type!=="transaction"&&(e.transaction=a)}function Sy(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function Ey(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function vy(e,t){e.contexts={trace:Bf(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:gt(t),...e.sdkProcessingMetadata};const n=Oe(t),r=Z(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function wy(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint.length||delete e.fingerprint}let Li,zu,Pi;function nh(e){const t=q._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return Pi&&n.length===zu||(zu=n.length,Pi=n.reduce((r,i)=>{Li||(Li={});const s=Li[i];if(s)r[s[0]]=s[1];else{const o=e(i);for(let a=o.length-1;a>=0;a--){const u=o[a]?.filename,d=t[i];if(u&&d){r[u]=d,Li[i]=[u,d];break}}}return r},{})),Pi}function Ty(e,t){const n=nh(e);if(!n)return[];const r=[];for(const i of t)i&&n[i]&&r.push({type:"sourcemap",code_file:i,debug_id:n[i]});return r}function rh(e,t,n,r,i,s){const{normalizeDepth:o=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||je(),timestamp:t.timestamp||Dn()},u=n.integrations||e.integrations.map(g=>g.name);Iy(c,e),Cy(c,u),i&&i.emit("applyFrameMetadata",t),t.type===void 0&&xy(c,e.stackParser);const d=Ay(r,n.captureContext);n.mechanism&&sn(c,n.mechanism);const l=i?i.getEventProcessors():[],f=no().getScopeData();if(s){const g=s.getScopeData();Os(f,g)}if(d){const g=d.getScopeData();Os(f,g)}const h=[...n.attachments||[],...f.attachments];h.length&&(n.attachments=h),yy(c,f);const p=[...l,...f.eventProcessors];return Ia(p,c,n).then(g=>(g&&ky(g),typeof o=="number"&&o>0?Ry(g,o,a):g))}function Iy(e,t){const{environment:n,release:r,dist:i,maxValueLength:s=250}=t;e.environment=e.environment||n||io,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i);const o=e.request;o?.url&&(o.url=ar(o.url,s))}function xy(e,t){const n=nh(t);e.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.filename&&(i.debug_id=n[i.filename])})})}function ky(e){const t={};if(e.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})}),Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach(([r,i])=>{n.push({type:"sourcemap",code_file:r,debug_id:i})})}function Cy(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function Ry(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:Ze(i.data,t,n)}}))},...e.user&&{user:Ze(e.user,t,n)},...e.contexts&&{contexts:Ze(e.contexts,t,n)},...e.extra&&{extra:Ze(e.extra,t,n)}};return e.contexts?.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=Ze(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(i=>({...i,...i.data&&{data:Ze(i.data,t,n)}}))),e.contexts?.flags&&r.contexts&&(r.contexts.flags=Ze(e.contexts.flags,3,n)),r}function Ay(e,t){if(!t)return e;const n=e?e.clone():new mt;return n.update(t),n}function My(e){if(e)return Ny(e)?{captureContext:e}:Ly(e)?{captureContext:e}:e}function Ny(e){return e instanceof mt||typeof e=="function"}const Oy=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function Ly(e){return Object.keys(e).some(t=>Oy.includes(t))}function Nn(e,t){return Q().captureException(e,My(t))}function Ls(e,t){const n=typeof t=="string"?t:void 0,r=typeof t!="string"?{captureContext:t}:void 0;return Q().captureMessage(e,n,r)}function bi(e,t){return Q().captureEvent(e,t)}function ih(e,t){Le().setContext(e,t)}function Py(e){Le().setExtras(e)}function Dy(e,t){Le().setExtra(e,t)}function Fy(e){Le().setTags(e)}function Hy(e,t){Le().setTag(e,t)}function By(e){Le().setUser(e)}function sh(){return Le().lastEventId()}async function Uy(e){const t=H();return t?t.flush(e):(D&&y.warn("Cannot flush events. No client defined."),Promise.resolve(!1))}async function $y(e){const t=H();return t?t.close(e):(D&&y.warn("Cannot flush events and disable SDK. No client defined."),Promise.resolve(!1))}function Wy(){return!!H()}function oh(){const e=H();return e?.getOptions().enabled!==!1&&!!e?.getTransport()}function ah(e){Le().addEventProcessor(e)}function xa(e){const t=Le(),n=Q(),{userAgent:r}=q.navigator||{},i=a_({user:n.getUser()||t.getUser(),...r&&{userAgent:r},...e}),s=t.getSession();return s?.status==="ok"&&cr(s,{status:"exited"}),Rc(),t.setSession(i),i}function Rc(){const e=Le(),n=Q().getSession()||e.getSession();n&&c_(n),ch(),e.setSession()}function ch(){const e=Le(),t=H(),n=e.getSession();n&&t&&t.captureSession(n)}function ka(e=!1){if(e){Rc();return}ch()}const Gy="7";function uh(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function zy(e){return`${uh(e)}${e.projectId}/envelope/`}function jy(e,t){const n={sentry_version:Gy};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function lh(e,t,n){return t||`${zy(e)}?${jy(e,n)}`}function qy(e,t){const n=Vf(e);if(!n)return"";const r=`${uh(n)}embed/error-page/`;let i=`dsn=${Hn(n)}`;for(const s in t)if(s!=="dsn"&&s!=="onClose")if(s==="user"){const o=t.user;if(!o)continue;o.name&&(i+=`&name=${encodeURIComponent(o.name)}`),o.email&&(i+=`&email=${encodeURIComponent(o.email)}`)}else i+=`&${encodeURIComponent(s)}=${encodeURIComponent(t[s])}`;return`${r}?${i}`}const ju=[];function Vy(e){const t={};return e.forEach(n=>{const{name:r}=n,i=t[r];i&&!i.isDefaultInstance&&n.isDefaultInstance||(t[r]=n)}),Object.values(t)}function Xy(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(i=>{i.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const i=n(t);r=Array.isArray(i)?i:[i]}else r=t;return Vy(r)}function Yy(e,t){const n={};return t.forEach(r=>{r&&dh(e,r,n)}),n}function qu(e,t){for(const n of t)n?.afterAllSetup&&n.afterAllSetup(e)}function dh(e,t,n){if(n[t.name]){D&&y.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,ju.indexOf(t.name)===-1&&typeof t.setupOnce=="function"&&(t.setupOnce(),ju.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(i,s)=>r(i,s,e))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),i=Object.assign((s,o)=>r(s,o,e),{id:t.name});e.addEventProcessor(i)}D&&y.log(`Integration installed: ${t.name}`)}function Ca(e){const t=H();if(!t){D&&y.warn(`Cannot add integration "${e.name}" because no SDK Client is available.`);return}t.addIntegration(e)}function Jy(e,t,n){const r=[{type:"client_report"},{timestamp:Dn(),discarded_events:e}];return Xt(t?{dsn:t}:{},[r])}function fh(e){const t=[];e.message&&t.push(e.message);try{const n=e.exception.values[e.exception.values.length-1];n?.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`))}catch{}return t}function Ky(e){const{trace_id:t,parent_span_id:n,span_id:r,status:i,origin:s,data:o,op:a}=e.contexts?.trace??{};return{data:o??{},description:e.transaction,op:a,parent_span_id:n,span_id:r??"",start_timestamp:e.start_timestamp??0,status:i,timestamp:e.timestamp,trace_id:t??"",origin:s,profile_id:o?.[Sc],exclusive_time:o?.[Rr],measurements:e.measurements,is_segment:!0}}function Zy(e){return{type:"transaction",timestamp:e.timestamp,start_timestamp:e.start_timestamp,transaction:e.description,contexts:{trace:{trace_id:e.trace_id,span_id:e.span_id,parent_span_id:e.parent_span_id,op:e.op,status:e.status,origin:e.origin,data:{...e.data,...e.profile_id&&{[Sc]:e.profile_id},...e.exclusive_time&&{[Rr]:e.exclusive_time}}}},measurements:e.measurements}}const Vu="Not capturing exception because it's already been captured.",Xu="Discarded session because of missing or non-string release",hh=Symbol.for("SentryInternalError"),ph=Symbol.for("SentryDoNotSendEventError");function us(e){return{message:e,[hh]:!0}}function Lo(e){return{message:e,[ph]:!0}}function Yu(e){return!!e&&typeof e=="object"&&hh in e}function Ju(e){return!!e&&typeof e=="object"&&ph in e}class Qy{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=Vf(t.dsn):D&&y.warn("No DSN provided, client will not send events."),this._dsn){const n=lh(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:n})}}captureException(t,n,r){const i=je();if(Cu(t))return D&&y.log(Vu),i;const s={event_id:i,...n};return this._process(this.eventFromException(t,s).then(o=>this._captureEvent(o,s,r))),s.event_id}captureMessage(t,n,r,i){const s={event_id:je(),...r},o=eo(t)?t:String(t),a=or(t)?this.eventFromMessage(o,n,s):this.eventFromException(t,s);return this._process(a.then(c=>this._captureEvent(c,s,i))),s.event_id}captureEvent(t,n,r){const i=je();if(n?.originalException&&Cu(n.originalException))return D&&y.log(Vu),i;const s={event_id:i,...n},o=t.sdkProcessingMetadata||{},a=o.capturedSpanScope,c=o.capturedSpanIsolationScope;return this._process(this._captureEvent(t,s,a||r,c)),s.event_id}captureSession(t){this.sendSession(t),cr(t,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const n=this._transport;return n?(this.emit("flush"),this._isClientDoneProcessing(t).then(r=>n.flush(t).then(i=>r&&i))):zt(!0)}close(t){return this.flush(t).then(n=>(this.getOptions().enabled=!1,this.emit("close"),n))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];dh(this,t,this._integrations),n||qu(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=ey(t,this._dsn,this._options._metadata,this._options.tunnel);for(const s of n.attachments||[])r=j_(r,J_(s));const i=this.sendEnvelope(r);i&&i.then(s=>this.emit("afterSendEvent",t,s),null)}sendSession(t){const{release:n,environment:r=io}=this._options;if("aggregates"in t){const s=t.attrs||{};if(!s.release&&!n){D&&y.warn(Xu);return}s.release=s.release||n,s.environment=s.environment||r,t.attrs=s}else{if(!t.release&&!n){D&&y.warn(Xu);return}t.release=t.release||n,t.environment=t.environment||r}this.emit("beforeSendSession",t);const i=Q_(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(i)}recordDroppedEvent(t,n,r=1){if(this._options.sendClientReports){const i=`${t}:${n}`;D&&y.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(t,n){const r=this._hooks[t]=this._hooks[t]||[];return r.push(n),()=>{const i=r.indexOf(n);i>-1&&r.splice(i,1)}}emit(t,...n){const r=this._hooks[t];r&&r.forEach(i=>i(...n))}sendEnvelope(t){return this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport?this._transport.send(t).then(null,n=>(D&&y.error("Error while sending envelope:",n),n)):(D&&y.error("Transport disabled"),zt({}))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=Yy(this,t),qu(this,t)}_updateSessionFromEvent(t,n){let r=n.level==="fatal",i=!1;const s=n.exception?.values;if(s){i=!0;for(const c of s)if(c.mechanism?.handled===!1){r=!0;break}}const o=t.status==="ok";(o&&t.errors===0||o&&r)&&(cr(t,{...r&&{status:"crashed"},errors:t.errors||Number(i||r)}),this.captureSession(t))}_isClientDoneProcessing(t){return new an(n=>{let r=0;const i=1,s=setInterval(()=>{this._numProcessing==0?(clearInterval(s),n(!0)):(r+=i,t&&r>=t&&(clearInterval(s),n(!1)))},i)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,n,r,i){const s=this.getOptions(),o=Object.keys(this._integrations);return!n.integrations&&o?.length&&(n.integrations=o),this.emit("preprocessEvent",t,n),t.type||i.setLastEventId(t.event_id||n.event_id),rh(s,t,n,r,this,i).then(a=>{if(a===null)return a;this.emit("postprocessEvent",a,n),a.contexts={trace:Cf(r),...a.contexts};const c=Tc(this,r);return a.sdkProcessingMetadata={dynamicSamplingContext:c,...a.sdkProcessingMetadata},a})}_captureEvent(t,n={},r=Q(),i=Le()){return D&&Ra(t)&&y.log(`Captured error event \`${fh(t)[0]||"<unknown>"}\``),this._processEvent(t,n,r,i).then(s=>s.event_id,s=>{D&&(Ju(s)?y.log(s.message):Yu(s)?y.warn(s.message):y.warn(s))})}_processEvent(t,n,r,i){const s=this.getOptions(),{sampleRate:o}=s,a=mh(t),c=Ra(t),u=t.type||"error",d=`before send for type \`${u}\``,l=typeof o>"u"?void 0:An(o);if(c&&typeof l=="number"&&Math.random()>l)return this.recordDroppedEvent("sample_rate","error"),Ns(Lo(`Discarding event because it's not included in the random sample (sampling rate = ${o})`));const f=u==="replay_event"?"replay":u;return this._prepareEvent(t,n,r,i).then(h=>{if(h===null)throw this.recordDroppedEvent("event_processor",f),Lo("An event processor returned `null`, will not send event.");if(n.data&&n.data.__sentry__===!0)return h;const m=tb(this,s,h,n);return eb(m,d)}).then(h=>{if(h===null){if(this.recordDroppedEvent("before_send",f),a){const _=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",_)}throw Lo(`${d} returned \`null\`, will not send event.`)}const p=r.getSession()||i.getSession();if(c&&p&&this._updateSessionFromEvent(p,h),a){const g=h.sdkProcessingMetadata?.spanCountBeforeProcessing||0,_=h.spans?h.spans.length:0,v=g-_;v>0&&this.recordDroppedEvent("before_send","span",v)}const m=h.transaction_info;if(a&&m&&h.transaction!==t.transaction){const g="custom";h.transaction_info={...m,source:g}}return this.sendEvent(h,n),h}).then(null,h=>{throw Ju(h)||Yu(h)?h:(this.captureException(h,{data:{__sentry__:!0},originalException:h}),us(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
11
+ Reason: ${h}`))})}_process(t){this._numProcessing++,t.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[i,s]=n.split(":");return{reason:i,category:s,quantity:r}})}_flushOutcomes(){D&&y.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){D&&y.log("No outcomes to send");return}if(!this._dsn){D&&y.log("No dsn provided, will not send outcomes");return}D&&y.log("Sending outcomes:",t);const n=Jy(t,this._options.tunnel&&Hn(this._dsn));this.sendEnvelope(n)}}function eb(e,t){const n=`${t} must return \`null\` or a valid event.`;if(fi(e))return e.then(r=>{if(!Ut(r)&&r!==null)throw us(n);return r},r=>{throw us(`${t} rejected with ${r}`)});if(!Ut(e)&&e!==null)throw us(n);return e}function tb(e,t,n,r){const{beforeSend:i,beforeSendTransaction:s,beforeSendSpan:o}=t;let a=n;if(Ra(a)&&i)return i(a,r);if(mh(a)){if(o){const c=o(Ky(a));if(c?a=hi(n,Zy(c)):wa(),a.spans){const u=[];for(const d of a.spans){const l=o(d);l?u.push(l):(wa(),u.push(d))}a.spans=u}}if(s){if(a.spans){const c=a.spans.length;a.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:c}}return s(a,r)}}return a}function Ra(e){return e.type===void 0}function mh(e){return e.type==="transaction"}function nb(e,t){return t?ot(t,()=>{const n=Pe(),r=n?Bf(n):Cf(t);return[n?gt(n):Tc(e,t),r]}):[void 0,void 0]}const rb={trace:1,debug:5,info:9,warn:13,error:17,fatal:21};function ib(e){return[{type:"log",item_count:e.length,content_type:"application/vnd.sentry.items.log+json"},{items:e}]}function sb(e,t,n,r){const i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=Hn(r)),Xt(i,[ib(e)])}const ob=100;function ab(e){switch(typeof e){case"number":return Number.isInteger(e)?{value:e,type:"integer"}:{value:e,type:"double"};case"boolean":return{value:e,type:"boolean"};case"string":return{value:e,type:"string"};default:{let t="";try{t=JSON.stringify(e)??""}catch{}return{value:t,type:"string"}}}}function Yt(e,t,n,r=!0){n&&(!e[t]||r)&&(e[t]=n)}function cb(e,t){const n=Ac(),r=gh(e);r===void 0?n.set(e,[t]):r.length>=ob?(ls(e,r),n.set(e,[t])):n.set(e,[...r,t])}function Aa(e,t=H(),n=Q(),r=cb){if(!t){D&&y.warn("No client available to capture log.");return}const{release:i,environment:s,enableLogs:o,beforeSendLog:a,_experiments:c}=t.getOptions();if(!(o??c?.enableLogs)){D&&y.warn("logging option not enabled, log will not be captured.");return}const d=a??c?.beforeSendLog,[,l]=nb(t,n),f={...e.attributes},{user:{id:h,email:p,username:m}}=ub(n);Yt(f,"user.id",h,!1),Yt(f,"user.email",p,!1),Yt(f,"user.name",m,!1),Yt(f,"sentry.release",i),Yt(f,"sentry.environment",s);const{name:g,version:_}=t.getSdkMetadata()?.sdk??{};Yt(f,"sentry.sdk.name",g),Yt(f,"sentry.sdk.version",_);const v=e.message;if(eo(v)){const{__sentry_template_string__:P,__sentry_template_values__:k=[]}=v;f["sentry.message.template"]=P,k.forEach((F,X)=>{f[`sentry.message.parameter.${X}`]=F})}const L=ti(n);Yt(f,"sentry.trace.parent_span_id",L?.spanContext().spanId);const A={...e,attributes:f};t.emit("beforeCaptureLog",A);const O=d?un(()=>d(A)):A;if(!O){t.recordDroppedEvent("before_send","log_item",1),D&&y.warn("beforeSendLog returned null, log will not be captured.");return}const{level:T,message:C,attributes:M={},severityNumber:x}=O,R={timestamp:xe(),level:T,body:C,trace_id:l?.trace_id,severity_number:x??rb[T],attributes:Object.keys(M).reduce((P,k)=>(P[k]=ab(M[k]),P),{})};r(t,R),t.emit("afterCaptureLog",O)}function ls(e,t){const n=t??gh(e)??[];if(n.length===0)return;const r=e.getOptions(),i=sb(n,r._metadata,r.tunnel,e.getDsn());Ac().set(e,[]),e.emit("flushLogs"),e.sendEnvelope(i)}function gh(e){return Ac().get(e)}function ub(e){const t=no().getScopeData();return Os(t,Le().getScopeData()),Os(t,e.getScopeData()),t}function Ac(){return di("clientToLogBufferMap",()=>new WeakMap)}function lb(e,t){t.debug===!0&&(D?y.enable():un(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),Q().update(t.initialScope);const r=new e(t);return _h(r),r.init(),r}function _h(e){Q().setClient(e)}const yh=Symbol.for("SentryBufferFullError");function db(e){const t=[];function n(){return e===void 0||t.length<e}function r(o){return t.splice(t.indexOf(o),1)[0]||Promise.resolve(void 0)}function i(o){if(!n())return Ns(yh);const a=o();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function s(o){return new an((a,c)=>{let u=t.length;if(!u)return a(!0);const d=setTimeout(()=>{o&&o>0&&a(!1)},o);t.forEach(l=>{zt(l).then(()=>{--u||(clearTimeout(d),a(!0))},c)})})}return{$:t,add:i,drain:s}}const fb=60*1e3;function bh(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?fb:r-t}function hb(e,t){return e[t]||e.all||0}function Sh(e,t,n=Date.now()){return hb(e,t)>n}function Eh(e,{statusCode:t,headers:n},r=Date.now()){const i={...e},s=n?.["x-sentry-rate-limits"],o=n?.["retry-after"];if(s)for(const a of s.trim().split(",")){const[c,u,,,d]=a.split(":",5),l=parseInt(c,10),f=(isNaN(l)?60:l)*1e3;if(!u)i.all=r+f;else for(const h of u.split(";"))h==="metric_bucket"?(!d||d.split(";").includes("custom"))&&(i[h]=r+f):i[h]=r+f}else o?i.all=r+bh(o,r):t===429&&(i.all=r+60*1e3);return i}const pb=64;function vh(e,t,n=db(e.bufferSize||pb)){let r={};const i=o=>n.drain(o);function s(o){const a=[];if(Mn(o,(l,f)=>{const h=Du(f);Sh(r,h)?e.recordDroppedEvent("ratelimit_backoff",h):a.push(l)}),a.length===0)return zt({});const c=Xt(o[0],a),u=l=>{Mn(c,(f,h)=>{e.recordDroppedEvent(l,Du(h))})},d=()=>t({body:As(c)}).then(l=>(l.statusCode!==void 0&&(l.statusCode<200||l.statusCode>=300)&&D&&y.warn(`Sentry responded with status code ${l.statusCode} to sent event.`),r=Eh(r,l),l),l=>{throw u("network_error"),D&&y.error("Encountered error running transport request:",l),l});return n.add(d).then(l=>l,l=>{if(l===yh)return D&&y.error("Skipped sending event because buffer is full."),u("queue_overflow"),zt({});throw l})}return{send:s,flush:i}}const Po=100,Do=5e3,mb=36e5;function gb(e){function t(...n){D&&y.log("[Offline]:",...n)}return n=>{const r=e(n);if(!n.createStore)throw new Error("No `createStore` function was provided");const i=n.createStore(n);let s=Do,o;function a(l,f,h){return Pu(l,["client_report"])?!1:n.shouldStore?n.shouldStore(l,f,h):!0}function c(l){o&&clearTimeout(o),o=setTimeout(async()=>{o=void 0;const f=await i.shift();f&&(t("Attempting to send previously queued event"),f[0].sent_at=new Date().toISOString(),d(f,!0).catch(h=>{t("Failed to retry sending",h)}))},l),typeof o!="number"&&o.unref&&o.unref()}function u(){o||(c(s),s=Math.min(s*2,mb))}async function d(l,f=!1){if(!f&&Pu(l,["replay_event","replay_recording"]))return await i.push(l),c(Po),{};try{if(n.shouldSend&&await n.shouldSend(l)===!1)throw new Error("Envelope not sent because `shouldSend` callback returned false");const h=await r.send(l);let p=Po;if(h){if(h.headers?.["retry-after"])p=bh(h.headers["retry-after"]);else if(h.headers?.["x-sentry-rate-limits"])p=6e4;else if((h.statusCode||0)>=400)return h}return c(p),s=Do,h}catch(h){if(await a(l,h,s))return f?await i.unshift(l):await i.push(l),u(),t("Error sending. Event queued.",h),{};throw h}}return n.flushAtStartup&&u(),{send:d,flush:l=>(l===void 0&&(s=Do,c(Po)),r.flush(l))}}}function wh(e,t){let n;return Mn(e,(r,i)=>(t.includes(i)&&(n=Array.isArray(r)?r[1]:void 0),!!n)),n}function _b(e,t){return n=>{const r=e(n);return{...r,send:async i=>{const s=wh(i,["event","transaction","profile","replay_event"]);return s&&(s.release=t),r.send(i)}}}}function yb(e,t){return Xt(t?{...e[0],dsn:t}:e[0],e[1])}function bb(e,t){return n=>{const r=e(n),i=new Map;function s(c,u){const d=u?`${c}:${u}`:c;let l=i.get(d);if(!l){const f=jf(c);if(!f)return;const h=lh(f,n.tunnel);l=u?_b(e,u)({...n,url:h}):e({...n,url:h}),i.set(d,l)}return[c,l]}async function o(c){function u(h){const p=h?.length?h:["event"];return wh(c,p)}const d=t({envelope:c,getEvent:u}).map(h=>typeof h=="string"?s(h,void 0):s(h.dsn,h.release)).filter(h=>!!h),l=d.length?d:[["",r]];return(await Promise.all(l.map(([h,p])=>p.send(yb(c,h)))))[0]}async function a(c){const u=[...i.values(),r];return(await Promise.all(u.map(l=>l.flush(c)))).every(l=>l)}return{send:o,flush:a}}}function Th(e,t){const n=t?.getDsn(),r=t?.getOptions().tunnel;return Eb(e,n)||Sb(e,r)}function Sb(e,t){return t?Ku(e)===Ku(t):!1}function Eb(e,t){return t?e.includes(t.host):!1}function Ku(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function Ih(e,...t){const n=new String(String.raw(e,...t));return n.__sentry_template_string__=e.join("\0").replace(/%/g,"%%").replace(/\0/g,"%s"),n.__sentry_template_values__=t,n}const vb=Ih;function wb(e){e.user?.ip_address===void 0&&(e.user={...e.user,ip_address:"{{auto}}"})}function Tb(e){"aggregates"in e?e.attrs?.ip_address===void 0&&(e.attrs={...e.attrs,ip_address:"{{auto}}"}):e.ipAddress===void 0&&(e.ipAddress="{{auto}}")}function Ib(e,t,n=[t],r="npm"){const i=e._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${t}`,packages:n.map(s=>({name:`${r}:@sentry/${s}`,version:Dt})),version:Dt}),e._metadata=i}function Mc(e={}){const t=e.client||H();if(!oh()||!t)return{};const n=Vt(),r=fn(n);if(r.getTraceData)return r.getTraceData(e);const i=e.scope||Q(),s=e.span||Pe(),o=s?Uf(s):xb(i),a=s?gt(s):Tc(t,i),c=Lf(a);return Pf.test(o)?{"sentry-trace":o,baggage:c}:(y.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}function xb(e){const{traceId:t,sampled:n,propagationSpanId:r}=e.getPropagationContext();return Ff(t,r,n)}function kb(e,t,n){let r,i,s;const o=n?.maxWait?Math.max(n.maxWait,t):0,a=n?.setTimeoutImpl||setTimeout;function c(){return u(),r=e(),r}function u(){i!==void 0&&clearTimeout(i),s!==void 0&&clearTimeout(s),i=s=void 0}function d(){return i!==void 0||s!==void 0?c():r}function l(){return i&&clearTimeout(i),i=a(c,t),o&&s===void 0&&(s=a(c,o)),r}return l.cancel=u,l.flush=d,l}const Cb=100;function Ct(e,t){const n=H(),r=Le();if(!n)return;const{beforeBreadcrumb:i=null,maxBreadcrumbs:s=Cb}=n.getOptions();if(s<=0)return;const a={timestamp:Dn(),...e},c=i?un(()=>i(a,t)):a;c!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",c,t),r.addBreadcrumb(c,s))}let Zu;const Rb="FunctionToString",Qu=new WeakMap,Ab=()=>({name:Rb,setupOnce(){Zu=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=bc(this),n=Qu.has(H())&&t!==void 0?t:this;return Zu.apply(n,e)}}catch{}},setup(e){Qu.set(e,!0)}}),xh=Ab,Mb=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,`can't redefine non-configurable property "solana"`,"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/,/^Java exception was raised during method invocation$/],Nb="EventFilters",kh=(e={})=>{let t;return{name:Nb,setup(n){const r=n.getOptions();t=el(e,r)},processEvent(n,r,i){if(!t){const s=i.getOptions();t=el(e,s)}return Ob(n,t)?null:n}}},Ch=(e={})=>({...kh(e),name:"InboundFilters"});function el(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Mb],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function Ob(e,t){if(e.type){if(e.type==="transaction"&&Pb(e,t.ignoreTransactions))return D&&y.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
12
+ Event: ${bn(e)}`),!0}else{if(Lb(e,t.ignoreErrors))return D&&y.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
13
+ Event: ${bn(e)}`),!0;if(Bb(e))return D&&y.warn(`Event dropped due to not having an error message, error type or stacktrace.
14
+ Event: ${bn(e)}`),!0;if(Db(e,t.denyUrls))return D&&y.warn(`Event dropped due to being matched by \`denyUrls\` option.
15
+ Event: ${bn(e)}.
16
+ Url: ${Ps(e)}`),!0;if(!Fb(e,t.allowUrls))return D&&y.warn(`Event dropped due to not being matched by \`allowUrls\` option.
17
+ Event: ${bn(e)}.
18
+ Url: ${Ps(e)}`),!0}return!1}function Lb(e,t){return t?.length?fh(e).some(n=>pt(n,t)):!1}function Pb(e,t){if(!t?.length)return!1;const n=e.transaction;return n?pt(n,t):!1}function Db(e,t){if(!t?.length)return!1;const n=Ps(e);return n?pt(n,t):!1}function Fb(e,t){if(!t?.length)return!0;const n=Ps(e);return n?pt(n,t):!0}function Hb(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function Ps(e){try{const n=[...e.exception?.values??[]].reverse().find(r=>r.mechanism?.parent_id===void 0&&r.stacktrace?.frames?.length)?.stacktrace?.frames;return n?Hb(n):null}catch{return D&&y.error(`Cannot extract url for event ${bn(e)}`),null}}function Bb(e){return e.exception?.values?.length?!e.message&&!e.exception.values.some(t=>t.stacktrace||t.type&&t.type!=="Error"||t.value):!1}function Ub(e,t,n,r,i,s){if(!i.exception?.values||!s||!$t(s.originalException,Error))return;const o=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;o&&(i.exception.values=Ma(e,t,r,s.originalException,n,i.exception.values,o,0))}function Ma(e,t,n,r,i,s,o,a){if(s.length>=n+1)return s;let c=[...s];if($t(r[i],Error)){tl(o,a);const u=e(t,r[i]),d=c.length;nl(u,i,d,a),c=Ma(e,t,n,r[i],i,[u,...c],u,d)}return Array.isArray(r.errors)&&r.errors.forEach((u,d)=>{if($t(u,Error)){tl(o,a);const l=e(t,u),f=c.length;nl(l,`errors[${d}]`,f,a),c=Ma(e,t,n,u,i,[l,...c],l,f)}}),c}function tl(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function nl(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}const Rh=new Map,rl=new Set;function $b(e){if(q._sentryModuleMetadata)for(const t of Object.keys(q._sentryModuleMetadata)){const n=q._sentryModuleMetadata[t];if(rl.has(t))continue;rl.add(t);const r=e(t);for(const i of r.reverse())if(i.filename){Rh.set(i.filename,n);break}}}function Wb(e,t){return $b(e),Rh.get(t)}function Ah(e,t){try{t.exception.values.forEach(n=>{if(n.stacktrace)for(const r of n.stacktrace.frames||[]){if(!r.filename||r.module_metadata)continue;const i=Wb(e,r.filename);i&&(r.module_metadata=i)}})}catch{}}function Mh(e){try{e.exception.values.forEach(t=>{if(t.stacktrace)for(const n of t.stacktrace.frames||[])delete n.module_metadata})}catch{}}const Gb=()=>({name:"ModuleMetadata",setup(e){e.on("beforeEnvelope",t=>{Mn(t,(n,r)=>{if(r==="event"){const i=Array.isArray(n)?n[1]:void 0;i&&(Mh(i),n[1]=i)}})}),e.on("applyFrameMetadata",t=>{if(t.type)return;const n=e.getOptions().stackParser;Ah(n,t)})}});function Nc(e){const t="console";ln(t,e),dn(t,zb)}function zb(){"console"in q&&mc.forEach(function(e){e in q.console&&ze(q.console,e,function(t){return Is[e]=t,function(...n){it("console",{args:n,level:e}),Is[e]?.apply(q.console,n)}})})}function Oc(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const jb="CaptureConsole",qb=(e={})=>{const t=e.levels||mc,n=e.handled??!0;return{name:jb,setup(r){"console"in q&&Nc(({args:i,level:s})=>{H()!==r||!t.includes(s)||Xb(i,s,n)})}}},Vb=qb;function Xb(e,t,n){const r={level:Oc(t),extra:{arguments:e}};ot(i=>{if(i.addEventProcessor(a=>(a.logger="console",sn(a,{handled:n,type:"console"}),a)),t==="assert"){if(!e[0]){const a=`Assertion failed: ${xs(e.slice(1)," ")||"console.assert"}`;i.setExtra("arguments",e.slice(1)),Ls(a,r)}return}const s=e.find(a=>a instanceof Error);if(s){Nn(s,r);return}const o=xs(e," ");Ls(o,r)})}const Yb="Dedupe",Jb=()=>{let e;return{name:Yb,processEvent(t){if(t.type)return t;try{if(Kb(t,e))return D&&y.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},Nh=Jb;function Kb(e,t){return t?!!(Zb(e,t)||Qb(e,t)):!1}function Zb(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!Lh(e,t)||!Oh(e,t))}function Qb(e,t){const n=il(t),r=il(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!Lh(e,t)||!Oh(e,t))}function Oh(e,t){let n=ya(e),r=ya(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let i=0;i<r.length;i++){const s=r[i],o=n[i];if(s.filename!==o.filename||s.lineno!==o.lineno||s.colno!==o.colno||s.function!==o.function)return!1}return!0}function Lh(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function il(e){return e.exception?.values?.[0]}const eS="ExtraErrorData",tS=(e={})=>{const{depth:t=3,captureErrorCause:n=!0}=e;return{name:eS,processEvent(r,i,s){const{maxValueLength:o=250}=s.getOptions();return rS(r,i,t,n,o)}}},nS=tS;function rS(e,t={},n,r,i){if(!t.originalException||!nn(t.originalException))return e;const s=t.originalException.name||t.originalException.constructor.name,o=iS(t.originalException,r,i);if(o){const a={...e.contexts},c=Ze(o,n);return Ut(c)&&(Ye(c,"__sentry_skip_normalization__",!0),a[s]=c),{...e,contexts:a}}return e}function iS(e,t,n){try{const r=["name","message","stack","line","column","fileName","lineNumber","columnNumber","toJSON"],i={};for(const s of Object.keys(e)){if(r.indexOf(s)!==-1)continue;const o=e[s];i[s]=nn(o)||typeof o=="string"?ar(`${o}`,n):o}if(t&&e.cause!==void 0&&(i.cause=nn(e.cause)?e.cause.toString():e.cause),typeof e.toJSON=="function"){const s=e.toJSON();for(const o of Object.keys(s)){const a=s[o];i[o]=nn(a)?a.toString():a}}return i}catch(r){D&&y.error("Unable to extract extra data from the Error object:",r)}return null}function sS(e,t){let n=0;for(let r=e.length-1;r>=0;r--){const i=e[r];i==="."?e.splice(r,1):i===".."?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}const oS=/^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;function aS(e){const t=e.length>1024?`<truncated>${e.slice(-1024)}`:e,n=oS.exec(t);return n?n.slice(1):[]}function sl(...e){let t="",n=!1;for(let r=e.length-1;r>=-1&&!n;r--){const i=r>=0?e[r]:"/";i&&(t=`${i}/${t}`,n=i.charAt(0)==="/")}return t=sS(t.split("/").filter(r=>!!r),!n).join("/"),(n?"/":"")+t||"."}function ol(e){let t=0;for(;t<e.length&&e[t]==="";t++);let n=e.length-1;for(;n>=0&&e[n]==="";n--);return t>n?[]:e.slice(t,n-t+1)}function cS(e,t){e=sl(e).slice(1),t=sl(t).slice(1);const n=ol(e.split("/")),r=ol(t.split("/")),i=Math.min(n.length,r.length);let s=i;for(let a=0;a<i;a++)if(n[a]!==r[a]){s=a;break}let o=[];for(let a=s;a<n.length;a++)o.push("..");return o=o.concat(r.slice(s)),o.join("/")}function uS(e,t){return aS(e)[2]||""}const lS="RewriteFrames",dS=(e={})=>{const t=e.root,n=e.prefix||"app:///",r="window"in q&&!!q.window,i=e.iteratee||fS({isBrowser:r,root:t,prefix:n});function s(a){try{return{...a,exception:{...a.exception,values:a.exception.values.map(c=>({...c,...c.stacktrace&&{stacktrace:o(c.stacktrace)}}))}}}catch{return a}}function o(a){return{...a,frames:a?.frames?.map(c=>i(c))}}return{name:lS,processEvent(a){let c=a;return a.exception&&Array.isArray(a.exception.values)&&(c=s(c)),c}}};function fS({isBrowser:e,root:t,prefix:n}){return r=>{if(!r.filename)return r;const i=/^[a-zA-Z]:\\/.test(r.filename)||r.filename.includes("\\")&&!r.filename.includes("/"),s=/^\//.test(r.filename);if(e){if(t){const o=r.filename;o.indexOf(t)===0&&(r.filename=o.replace(t,n))}}else if(i||s){const o=i?r.filename.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/"):r.filename,a=t?cS(t,o):uS(o);r.filename=`${n}${a}`}return r}}const hS=["reauthenticate","signInAnonymously","signInWithOAuth","signInWithIdToken","signInWithOtp","signInWithPassword","signInWithSSO","signOut","signUp","verifyOtp"],pS=["createUser","deleteUser","listUsers","getUserById","updateUserById","inviteUserByEmail"],mS={eq:"eq",neq:"neq",gt:"gt",gte:"gte",lt:"lt",lte:"lte",like:"like","like(all)":"likeAllOf","like(any)":"likeAnyOf",ilike:"ilike","ilike(all)":"ilikeAllOf","ilike(any)":"ilikeAnyOf",is:"is",in:"in",cs:"contains",cd:"containedBy",sr:"rangeGt",nxl:"rangeGte",sl:"rangeLt",nxr:"rangeLte",adj:"rangeAdjacent",ov:"overlaps",fts:"",plfts:"plain",phfts:"phrase",wfts:"websearch",not:"not"},Ph=["select","insert","upsert","update","delete"];function ao(e){try{e.__SENTRY_INSTRUMENTED__=!0}catch{}}function co(e){try{return e.__SENTRY_INSTRUMENTED__}catch{return!1}}function gS(e,t={}){switch(e){case"GET":return"select";case"POST":return t.Prefer?.includes("resolution=")?"upsert":"insert";case"PATCH":return"update";case"DELETE":return"delete";default:return"<unknown-op>"}}function _S(e,t){if(t===""||t==="*")return"select(*)";if(e==="select")return`select(${t})`;if(e==="or"||e.endsWith(".or"))return`${e}${t}`;const[n,...r]=t.split(".");let i;return n?.startsWith("fts")?i="textSearch":n?.startsWith("plfts")?i="textSearch[plain]":n?.startsWith("phfts")?i="textSearch[phrase]":n?.startsWith("wfts")?i="textSearch[websearch]":i=n&&mS[n]||"filter",`${i}(${e}, ${r.join(".")})`}function al(e,t=!1){return new Proxy(e,{apply(n,r,i){return oo({name:`auth ${t?"(admin) ":""}${e.name}`,attributes:{[Se]:"auto.db.supabase",[rt]:"db","db.system":"postgresql","db.operation":`auth.${t?"admin.":""}${e.name}`}},s=>Reflect.apply(n,r,i).then(o=>(o&&typeof o=="object"&&"error"in o&&o.error?(s.setStatus({code:we}),Nn(o.error,{mechanism:{handled:!1}})):s.setStatus({code:Ec}),s.end(),o)).catch(o=>{throw s.setStatus({code:we}),s.end(),Nn(o,{mechanism:{handled:!1}}),o}).then(...i))}})}function yS(e){const t=e.auth;if(!(!t||co(e.auth))){for(const n of hS){const r=t[n];r&&typeof e.auth[n]=="function"&&(e.auth[n]=al(r))}for(const n of pS){const r=t.admin[n];r&&typeof e.auth.admin[n]=="function"&&(e.auth.admin[n]=al(r,!0))}ao(e.auth)}}function bS(e){co(e.prototype.from)||(e.prototype.from=new Proxy(e.prototype.from,{apply(t,n,r){const i=Reflect.apply(t,n,r),s=i.constructor;return ES(s),i}}),ao(e.prototype.from))}function SS(e){co(e.prototype.then)||(e.prototype.then=new Proxy(e.prototype.then,{apply(t,n,r){const i=Ph,s=n,o=gS(s.method,s.headers);if(!i.includes(o)||!s?.url?.pathname||typeof s.url.pathname!="string")return Reflect.apply(t,n,r);const a=s.url.pathname.split("/"),c=a.length>0?a[a.length-1]:"",u=[];for(const[h,p]of s.url.searchParams.entries())u.push(_S(h,p));const d=Object.create(null);if(Ut(s.body))for(const[h,p]of Object.entries(s.body))d[h]=p;const l=`${o==="select"?"":`${o}${d?"(...) ":""}`}${u.join(" ")} from(${c})`,f={"db.table":c,"db.schema":s.schema,"db.url":s.url.origin,"db.sdk":s.headers["X-Client-Info"],"db.system":"postgresql","db.operation":o,[Se]:"auto.db.supabase",[rt]:"db"};return u.length&&(f["db.query"]=u),Object.keys(d).length&&(f["db.body"]=d),oo({name:l,attributes:f},h=>Reflect.apply(t,n,[]).then(p=>{if(h&&(p&&typeof p=="object"&&"status"in p&&ni(h,p.status||500),h.end()),p.error){const _=new Error(p.error.message);p.error.code&&(_.code=p.error.code),p.error.details&&(_.details=p.error.details);const v={};u.length&&(v.query=u),Object.keys(d).length&&(v.body=d),Nn(_,{contexts:{supabase:v}})}const m={type:"supabase",category:`db.${o}`,message:l},g={};return u.length&&(g.query=u),Object.keys(d).length&&(g.body=d),Object.keys(g).length&&(m.data=g),Ct(m),p},p=>{throw h&&(ni(h,500),h.end()),p}).then(...r))}}),ao(e.prototype.then))}function ES(e){for(const t of Ph)co(e.prototype[t])||(e.prototype[t]=new Proxy(e.prototype[t],{apply(n,r,i){const s=Reflect.apply(n,r,i),o=s.constructor;return D&&y.log(`Instrumenting ${t} operation's PostgRESTFilterBuilder`),SS(o),s}}),ao(e.prototype[t]))}const Dh=e=>{if(!e){D&&y.warn("Supabase integration was not installed because no Supabase client was provided.");return}const t=e.constructor===Function?e:e.constructor;bS(t),yS(e)},vS="Supabase",wS=e=>({setupOnce(){Dh(e)},name:vS}),TS=e=>wS(e.supabaseClient),IS=10,xS="ZodErrors";function kS(e){return nn(e)&&e.name==="ZodError"&&Array.isArray(e.issues)}function CS(e){return{...e,path:"path"in e&&Array.isArray(e.path)?e.path.join("."):void 0,keys:"keys"in e?JSON.stringify(e.keys):void 0,unionErrors:"unionErrors"in e?JSON.stringify(e.unionErrors):void 0}}function RS(e){return e.map(t=>typeof t=="number"?"<array>":t).join(".")}function AS(e){const t=new Set;for(const r of e.issues){const i=RS(r.path);i.length>0&&t.add(i)}const n=Array.from(t);if(n.length===0){let r="variable";if(e.issues.length>0){const i=e.issues[0];i!==void 0&&"expected"in i&&typeof i.expected=="string"&&(r=i.expected)}return`Failed to validate ${r}`}return`Failed to validate keys: ${ar(n.join(", "),100)}`}function MS(e,t=!1,n,r){if(!n.exception?.values||!r.originalException||!kS(r.originalException)||r.originalException.issues.length===0)return n;try{const s=(t?r.originalException.issues:r.originalException.issues.slice(0,e)).map(CS);return t&&(Array.isArray(r.attachments)||(r.attachments=[]),r.attachments.push({filename:"zod_issues.json",data:JSON.stringify({issues:s})})),{...n,exception:{...n.exception,values:[{...n.exception.values[0],value:AS(r.originalException)},...n.exception.values.slice(1)]},extra:{...n.extra,"zoderror.issues":s.slice(0,e)}}}catch(i){return{...n,extra:{...n.extra,"zoderrors sentry integration parse error":{message:"an exception was thrown while processing ZodError within applyZodErrorsToEvent()",error:i instanceof Error?`${i.name}: ${i.message}
19
+ ${i.stack}`:"unknown"}}}}}const NS=(e={})=>{const t=e.limit??IS;return{name:xS,processEvent(n,r){return MS(t,e.saveZodIssuesAsAttachment,n,r)}}},OS=NS,LS=e=>({name:"ThirdPartyErrorsFilter",setup(t){t.on("beforeEnvelope",n=>{Mn(n,(r,i)=>{if(i==="event"){const s=Array.isArray(r)?r[1]:void 0;s&&(Mh(s),r[1]=s)}})}),t.on("applyFrameMetadata",n=>{if(n.type)return;const r=t.getOptions().stackParser;Ah(r,n)})},processEvent(t){const n=PS(t);if(n){const r=e.behaviour==="drop-error-if-contains-third-party-frames"||e.behaviour==="apply-tag-if-contains-third-party-frames"?"some":"every";if(n[r](s=>!s.some(o=>e.filterKeys.includes(o)))){if(e.behaviour==="drop-error-if-contains-third-party-frames"||e.behaviour==="drop-error-if-exclusively-contains-third-party-frames")return null;t.tags={...t.tags,third_party_code:!0}}}return t}});function PS(e){const t=ya(e);if(t)return t.filter(n=>!!n.filename).map(n=>n.module_metadata?Object.keys(n.module_metadata).filter(r=>r.startsWith(cl)).map(r=>r.slice(cl.length)):[])}const cl="_sentryBundlerPluginAppKey:",DS=100,FS=10,Di="flag.evaluation.";function Si(e){const n=Q().getScopeData().contexts.flags,r=n?n.values:[];return r.length&&(e.contexts===void 0&&(e.contexts={}),e.contexts.flags={values:[...r]}),e}function lr(e,t,n=DS){const r=Q().getScopeData().contexts;r.flags||(r.flags={values:[]});const i=r.flags.values;HS(i,e,t,n)}function HS(e,t,n,r){if(typeof n!="boolean")return;if(e.length>r){D&&y.error(`[Feature Flags] insertToFlagBuffer called on a buffer larger than maxSize=${r}`);return}const i=e.findIndex(s=>s.flag===t);i!==-1&&e.splice(i,1),e.length===r&&e.shift(),e.push({flag:t,result:n})}function dr(e,t,n=FS){if(typeof t!="boolean")return;const r=Pe();if(!r)return;const i=Z(r).data;if(`${Di}${e}`in i){r.setAttribute(`${Di}${e}`,t);return}Object.keys(i).filter(o=>o.startsWith(Di)).length<n&&r.setAttribute(`${Di}${e}`,t)}const BS=()=>({name:"FeatureFlags",processEvent(e,t,n){return Si(e)},addFeatureFlag(e,t){lr(e,t),dr(e,t)}}),US="thismessage:/";function Fh(e){return"isRelative"in e}function Hh(e,t){const n=e.indexOf("://")<=0&&e.indexOf("//")!==0,r=n?US:void 0;try{if("canParse"in URL&&!URL.canParse(e,r))return;const i=new URL(e,r);return n?{isRelative:n,pathname:i.pathname,search:i.search,hash:i.hash}:i}catch{}}function $S(e){if(Fh(e))return e.pathname;const t=new URL(e);return t.search="",t.hash="",["80","443"].includes(t.port)&&(t.port=""),t.password&&(t.password="%filtered%"),t.username&&(t.username="%filtered%"),t.toString()}function Cn(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Bh(e){return e.split(/[?#]/,1)[0]}function WS(e,t,n,r,i="auto.http.browser"){if(!e.fetchData)return;const{method:s,url:o}=e.fetchData,a=on()&&t(o);if(e.endTimestamp&&a){const l=e.fetchData.__span;if(!l)return;const f=r[l];f&&(zS(f,e),delete r[l]);return}const c=!!Pe(),u=a&&c?Bn(qS(o,s,i)):new Gt;if(e.fetchData.__span=u.spanContext().spanId,r[u.spanContext().spanId]=u,n(e.fetchData.url)){const l=e.args[0],f=e.args[1]||{},h=GS(l,f,on()&&c?u:void 0);h&&(e.args[1]=f,f.headers=h)}const d=H();if(d){const l={input:e.args,response:e.response,startTimestamp:e.startTimestamp,endTimestamp:e.endTimestamp};d.emit("beforeOutgoingRequestSpan",u,l)}return u}function GS(e,t,n){const r=Mc({span:n}),i=r["sentry-trace"],s=r.baggage;if(!i)return;const o=t.headers||(vf(e)?e.headers:void 0);if(o)if(jS(o)){const a=new Headers(o);if(a.get("sentry-trace")||a.set("sentry-trace",i),s){const c=a.get("baggage");c?Fi(c)||a.set("baggage",`${c},${s}`):a.set("baggage",s)}return a}else if(Array.isArray(o)){const a=[...o];o.find(u=>u[0]==="sentry-trace")||a.push(["sentry-trace",i]);const c=o.find(u=>u[0]==="baggage"&&Fi(u[1]));return s&&!c&&a.push(["baggage",s]),a}else{const a="sentry-trace"in o?o["sentry-trace"]:void 0,c="baggage"in o?o.baggage:void 0,u=c?Array.isArray(c)?[...c]:[c]:[],d=c&&(Array.isArray(c)?c.find(l=>Fi(l)):Fi(c));return s&&!d&&u.push(s),{...o,"sentry-trace":a??i,baggage:u.length>0?u.join(","):void 0}}else return{...r}}function zS(e,t){if(t.response){ni(e,t.response.status);const n=t.response?.headers?.get("content-length");if(n){const r=parseInt(n);r>0&&e.setAttribute("http.response_content_length",r)}}else t.error&&e.setStatus({code:we,message:"internal_error"});e.end()}function Fi(e){return e.split(",").some(t=>t.trim().startsWith(vc))}function jS(e){return typeof Headers<"u"&&$t(e,Headers)}function qS(e,t,n){const r=Hh(e);return{name:r?`${t} ${$S(r)}`:t,attributes:VS(e,r,t,n)}}function VS(e,t,n,r){const i={url:e,type:"fetch","http.method":n,[Se]:r,[rt]:"http.client"};return t&&(Fh(t)||(i["http.url"]=t.href,i["server.address"]=t.host),t.search&&(i["http.query"]=t.search),t.hash&&(i["http.fragment"]=t.hash)),i}function Uh(e,t={},n=Q()){const{message:r,name:i,email:s,url:o,source:a,associatedEventId:c,tags:u}=e,d={contexts:{feedback:{contact_email:s,name:i,message:r,url:o,source:a,associated_event_id:c}},type:"feedback",level:"info",tags:u},l=n?.getClient()||H();return l&&l.emit("beforeSendFeedback",d,t),n.captureEvent(d,t)}const XS="ConsoleLogs",ul={[Se]:"auto.console.logging"},YS=(e={})=>{const t=e.levels||mc;return{name:XS,setup(n){const{enableLogs:r,_experiments:i,normalizeDepth:s=3,normalizeMaxBreadth:o=1e3}=n.getOptions();if(!(r??i?.enableLogs)){D&&y.warn("`enableLogs` is not enabled, ConsoleLogs integration disabled");return}Nc(({args:c,level:u})=>{if(H()!==n||!t.includes(u))return;if(u==="assert"){if(!c[0]){const l=c.slice(1),f=l.length>0?`Assertion failed: ${ll(l,s,o)}`:"Assertion failed";Aa({level:"error",message:f,attributes:ul})}return}const d=u==="log";Aa({level:d?"info":u,message:ll(c,s,o),severityNumber:d?10:void 0,attributes:ul})})}}},JS=YS;function ll(e,t,n){return"util"in q&&typeof q.util.format=="function"?q.util.format(...e):KS(e,t,n)}function KS(e,t,n){return e.map(r=>or(r)?String(r):JSON.stringify(Ze(r,t,n))).join(" ")}function $h(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const fr=q;function ZS(){return"history"in fr&&!!fr.history}function QS(){if(!("fetch"in fr))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Na(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function Wh(){if(typeof EdgeRuntime=="string")return!0;if(!QS())return!1;if(Na(fr.fetch))return!0;let e=!1;const t=fr.document;if(t&&typeof t.createElement=="function")try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow?.fetch&&(e=Na(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){D&&y.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function e0(){return"ReportingObserver"in fr}function Lc(e,t){const n="fetch";ln(n,e),dn(n,()=>Gh(void 0,t))}function t0(e){const t="fetch-body-resolved";ln(t,e),dn(t,()=>Gh(r0))}function Gh(e,t=!1){t&&!Wh()||ze(q,"fetch",function(n){return function(...r){const i=new Error,{method:s,url:o}=i0(r),a={args:r,fetchData:{method:s,url:o},startTimestamp:xe()*1e3,virtualError:i,headers:s0(r)};return e||it("fetch",{...a}),n.apply(q,r).then(async c=>(e?e(c):it("fetch",{...a,endTimestamp:xe()*1e3,response:c}),c),c=>{if(it("fetch",{...a,endTimestamp:xe()*1e3,error:c}),nn(c)&&c.stack===void 0&&(c.stack=i.stack,Ye(c,"framesToPop",1)),c instanceof TypeError&&(c.message==="Failed to fetch"||c.message==="Load failed"||c.message==="NetworkError when attempting to fetch resource."))try{const u=new URL(a.fetchData.url);c.message=`${c.message} (${u.host})`}catch{}throw c})}})}async function n0(e,t){if(e?.body){const n=e.body,r=n.getReader(),i=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let s=!0;for(;s;){let o;try{o=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(o),a&&(t(),s=!1)}catch{s=!1}finally{clearTimeout(o)}}clearTimeout(i),r.releaseLock(),n.cancel().then(null,()=>{})}}function r0(e){let t;try{t=e.clone()}catch{return}n0(t,()=>{it("fetch-body-resolved",{endTimestamp:xe()*1e3,response:e})})}function Oa(e,t){return!!e&&typeof e=="object"&&!!e[t]}function dl(e){return typeof e=="string"?e:e?Oa(e,"url")?e.url:e.toString?e.toString():"":""}function i0(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:dl(n),method:Oa(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:dl(t),method:Oa(t,"method")?String(t.method).toUpperCase():"GET"}}function s0(e){const[t,n]=e;try{if(typeof n=="object"&&n!==null&&"headers"in n&&n.headers)return new Headers(n.headers);if(vf(t))return new Headers(t.headers)}catch{}}function o0(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function a0(){return"npm"}function c0(){return!o0()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function La(){return typeof window<"u"&&(!c0()||u0())}function u0(){return q.process?.type==="renderer"}const dt=q,fe=dt.document,Vr=dt.navigator,zh="Report a Bug",l0="Cancel",d0="Send Bug Report",f0="Confirm",h0="Report a Bug",p0="your.email@example.org",m0="Email",g0="What's the bug? What did you expect?",_0="Description",y0="Your Name",b0="Name",S0="Thank you for your report!",E0="(required)",v0="Add a screenshot",w0="Remove screenshot",T0="widget",I0="api",x0=5e3,jh=(e,t={includeReplay:!0})=>{if(!e.message)throw new Error("Unable to submit feedback with empty message");const n=H();if(!n)throw new Error("No client setup, cannot send feedback.");e.tags&&Object.keys(e.tags).length&&Q().setTags(e.tags);const r=Uh({source:I0,url:Pn(),...e},t);return new Promise((i,s)=>{const o=setTimeout(()=>s("Unable to determine if Feedback was correctly sent."),3e4),a=n.on("afterSendEvent",(c,u)=>{if(c.event_id===r)return clearTimeout(o),a(),u&&typeof u.statusCode=="number"&&u.statusCode>=200&&u.statusCode<300?i(r):u&&typeof u.statusCode=="number"&&u.statusCode===0?s("Unable to send Feedback. This is because of network issues, or because you are using an ad-blocker."):u&&typeof u.statusCode=="number"&&u.statusCode===403?s("Unable to send Feedback. This could be because this domain is not in your list of allowed domains."):s("Unable to send Feedback. This could be because of network issues, or because you are using an ad-blocker")})})},ds=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function k0(){return!(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(Vr.userAgent)||/Macintosh/i.test(Vr.userAgent)&&Vr.maxTouchPoints&&Vr.maxTouchPoints>1||!isSecureContext)}function Hi(e,t){return{...e,...t,tags:{...e.tags,...t.tags},onFormOpen:()=>{t.onFormOpen?.(),e.onFormOpen?.()},onFormClose:()=>{t.onFormClose?.(),e.onFormClose?.()},onSubmitSuccess:(n,r)=>{t.onSubmitSuccess?.(n,r),e.onSubmitSuccess?.(n,r)},onSubmitError:n=>{t.onSubmitError?.(n),e.onSubmitError?.(n)},onFormSubmitted:()=>{t.onFormSubmitted?.(),e.onFormSubmitted?.()},themeDark:{...e.themeDark,...t.themeDark},themeLight:{...e.themeLight,...t.themeLight}}}function C0(e){const t=fe.createElement("style");return t.textContent=`
20
+ .widget__actor {
21
+ position: fixed;
22
+ z-index: var(--z-index);
23
+ margin: var(--page-margin);
24
+ inset: var(--actor-inset);
25
+
26
+ display: flex;
27
+ align-items: center;
28
+ gap: 8px;
29
+ padding: 16px;
30
+
31
+ font-family: inherit;
32
+ font-size: var(--font-size);
33
+ font-weight: 600;
34
+ line-height: 1.14em;
35
+ text-decoration: none;
36
+
37
+ background: var(--actor-background, var(--background));
38
+ border-radius: var(--actor-border-radius, 1.7em/50%);
39
+ border: var(--actor-border, var(--border));
40
+ box-shadow: var(--actor-box-shadow, var(--box-shadow));
41
+ color: var(--actor-color, var(--foreground));
42
+ fill: var(--actor-color, var(--foreground));
43
+ cursor: pointer;
44
+ opacity: 1;
45
+ transition: transform 0.2s ease-in-out;
46
+ transform: translate(0, 0) scale(1);
47
+ }
48
+ .widget__actor[aria-hidden="true"] {
49
+ opacity: 0;
50
+ pointer-events: none;
51
+ visibility: hidden;
52
+ transform: translate(0, 16px) scale(0.98);
53
+ }
54
+
55
+ .widget__actor:hover {
56
+ background: var(--actor-hover-background, var(--background));
57
+ filter: var(--interactive-filter);
58
+ }
59
+
60
+ .widget__actor svg {
61
+ width: 1.14em;
62
+ height: 1.14em;
63
+ }
64
+
65
+ @media (max-width: 600px) {
66
+ .widget__actor span {
67
+ display: none;
68
+ }
69
+ }
70
+ `,e&&t.setAttribute("nonce",e),t}function et(e,t){return Object.entries(t).forEach(([n,r])=>{e.setAttributeNS(null,n,r)}),e}const jn=20,R0="http://www.w3.org/2000/svg";function A0(){const e=a=>dt.document.createElementNS(R0,a),t=et(e("svg"),{width:`${jn}`,height:`${jn}`,viewBox:`0 0 ${jn} ${jn}`,fill:"var(--actor-color, var(--foreground))"}),n=et(e("g"),{clipPath:"url(#clip0_57_80)"}),r=et(e("path"),{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M15.6622 15H12.3997C12.2129 14.9959 12.031 14.9396 11.8747 14.8375L8.04965 12.2H7.49956V19.1C7.4875 19.3348 7.3888 19.5568 7.22256 19.723C7.05632 19.8892 6.83435 19.9879 6.59956 20H2.04956C1.80193 19.9968 1.56535 19.8969 1.39023 19.7218C1.21511 19.5467 1.1153 19.3101 1.11206 19.0625V12.2H0.949652C0.824431 12.2017 0.700142 12.1783 0.584123 12.1311C0.468104 12.084 0.362708 12.014 0.274155 11.9255C0.185602 11.8369 0.115689 11.7315 0.0685419 11.6155C0.0213952 11.4995 -0.00202913 11.3752 -0.00034808 11.25V3.75C-0.00900498 3.62067 0.0092504 3.49095 0.0532651 3.36904C0.0972798 3.24712 0.166097 3.13566 0.255372 3.04168C0.344646 2.94771 0.452437 2.87327 0.571937 2.82307C0.691437 2.77286 0.82005 2.74798 0.949652 2.75H8.04965L11.8747 0.1625C12.031 0.0603649 12.2129 0.00407221 12.3997 0H15.6622C15.9098 0.00323746 16.1464 0.103049 16.3215 0.278167C16.4966 0.453286 16.5964 0.689866 16.5997 0.9375V3.25269C17.3969 3.42959 18.1345 3.83026 18.7211 4.41679C19.5322 5.22788 19.9878 6.32796 19.9878 7.47502C19.9878 8.62209 19.5322 9.72217 18.7211 10.5333C18.1345 11.1198 17.3969 11.5205 16.5997 11.6974V14.0125C16.6047 14.1393 16.5842 14.2659 16.5395 14.3847C16.4948 14.5035 16.4268 14.6121 16.3394 14.7042C16.252 14.7962 16.147 14.8698 16.0307 14.9206C15.9144 14.9714 15.7891 14.9984 15.6622 15ZM1.89695 10.325H1.88715V4.625H8.33715C8.52423 4.62301 8.70666 4.56654 8.86215 4.4625L12.6872 1.875H14.7247V13.125H12.6872L8.86215 10.4875C8.70666 10.3835 8.52423 10.327 8.33715 10.325H2.20217C2.15205 10.3167 2.10102 10.3125 2.04956 10.3125C1.9981 10.3125 1.94708 10.3167 1.89695 10.325ZM2.98706 12.2V18.1625H5.66206V12.2H2.98706ZM16.5997 9.93612V5.01393C16.6536 5.02355 16.7072 5.03495 16.7605 5.04814C17.1202 5.13709 17.4556 5.30487 17.7425 5.53934C18.0293 5.77381 18.2605 6.06912 18.4192 6.40389C18.578 6.73866 18.6603 7.10452 18.6603 7.47502C18.6603 7.84552 18.578 8.21139 18.4192 8.54616C18.2605 8.88093 18.0293 9.17624 17.7425 9.41071C17.4556 9.64518 17.1202 9.81296 16.7605 9.90191C16.7072 9.91509 16.6536 9.9265 16.5997 9.93612Z"});t.appendChild(n).appendChild(r);const i=e("defs"),s=et(e("clipPath"),{id:"clip0_57_80"}),o=et(e("rect"),{width:`${jn}`,height:`${jn}`,fill:"white"});return s.appendChild(o),i.appendChild(s),t.appendChild(i).appendChild(s).appendChild(o),t}function M0({triggerLabel:e,triggerAriaLabel:t,shadow:n,styleNonce:r}){const i=fe.createElement("button");if(i.type="button",i.className="widget__actor",i.ariaHidden="false",i.ariaLabel=t||e||zh,i.appendChild(A0()),e){const o=fe.createElement("span");o.appendChild(fe.createTextNode(e)),i.appendChild(o)}const s=C0(r);return{el:i,appendToDom(){n.appendChild(s),n.appendChild(i)},removeFromDom(){i.remove(),s.remove()},show(){i.ariaHidden="false"},hide(){i.ariaHidden="true"}}}const qh="rgba(88, 74, 192, 1)",N0={foreground:"#2b2233",background:"#ffffff",accentForeground:"white",accentBackground:qh,successColor:"#268d75",errorColor:"#df3338",border:"1.5px solid rgba(41, 35, 47, 0.13)",boxShadow:"0px 4px 24px 0px rgba(43, 34, 51, 0.12)",outline:"1px auto var(--accent-background)",interactiveFilter:"brightness(95%)"},fl={foreground:"#ebe6ef",background:"#29232f",accentForeground:"white",accentBackground:qh,successColor:"#2da98c",errorColor:"#f55459",border:"1.5px solid rgba(235, 230, 239, 0.15)",boxShadow:"0px 4px 24px 0px rgba(43, 34, 51, 0.12)",outline:"1px auto var(--accent-background)",interactiveFilter:"brightness(150%)"};function hl(e){return`
71
+ --foreground: ${e.foreground};
72
+ --background: ${e.background};
73
+ --accent-foreground: ${e.accentForeground};
74
+ --accent-background: ${e.accentBackground};
75
+ --success-color: ${e.successColor};
76
+ --error-color: ${e.errorColor};
77
+ --border: ${e.border};
78
+ --box-shadow: ${e.boxShadow};
79
+ --outline: ${e.outline};
80
+ --interactive-filter: ${e.interactiveFilter};
81
+ `}function O0({colorScheme:e,themeDark:t,themeLight:n,styleNonce:r}){const i=fe.createElement("style");return i.textContent=`
82
+ :host {
83
+ --font-family: system-ui, 'Helvetica Neue', Arial, sans-serif;
84
+ --font-size: 14px;
85
+ --z-index: 100000;
86
+
87
+ --page-margin: 16px;
88
+ --inset: auto 0 0 auto;
89
+ --actor-inset: var(--inset);
90
+
91
+ font-family: var(--font-family);
92
+ font-size: var(--font-size);
93
+
94
+ ${e!=="system"?"color-scheme: only light;":""}
95
+
96
+ ${hl(e==="dark"?{...fl,...t}:{...N0,...n})}
97
+ }
98
+
99
+ ${e==="system"?`
100
+ @media (prefers-color-scheme: dark) {
101
+ :host {
102
+ ${hl({...fl,...t})}
103
+ }
104
+ }`:""}
105
+ }
106
+ `,r&&i.setAttribute("nonce",r),i}const Vh=({lazyLoadIntegration:e,getModalIntegration:t,getScreenshotIntegration:n})=>({id:i="sentry-feedback",autoInject:s=!0,showBranding:o=!0,isEmailRequired:a=!1,isNameRequired:c=!1,showEmail:u=!0,showName:d=!0,enableScreenshot:l=!0,useSentryUser:f={email:"email",name:"username"},tags:h,styleNonce:p,scriptNonce:m,colorScheme:g="system",themeLight:_={},themeDark:v={},addScreenshotButtonLabel:L=v0,cancelButtonLabel:A=l0,confirmButtonLabel:O=f0,emailLabel:T=m0,emailPlaceholder:C=p0,formTitle:M=h0,isRequiredLabel:x=E0,messageLabel:R=_0,messagePlaceholder:P=g0,nameLabel:k=b0,namePlaceholder:F=y0,removeScreenshotButtonLabel:X=w0,submitButtonLabel:U=d0,successMessageText:J=S0,triggerLabel:N=zh,triggerAriaLabel:G="",onFormOpen:B,onFormClose:re,onSubmitSuccess:ce,onSubmitError:Ae,onFormSubmitted:Me}={})=>{const ke={id:i,autoInject:s,showBranding:o,isEmailRequired:a,isNameRequired:c,showEmail:u,showName:d,enableScreenshot:l,useSentryUser:f,tags:h,styleNonce:p,scriptNonce:m,colorScheme:g,themeDark:v,themeLight:_,triggerLabel:N,triggerAriaLabel:G,cancelButtonLabel:A,submitButtonLabel:U,confirmButtonLabel:O,formTitle:M,emailLabel:T,emailPlaceholder:C,messageLabel:R,messagePlaceholder:P,nameLabel:k,namePlaceholder:F,successMessageText:J,isRequiredLabel:x,addScreenshotButtonLabel:L,removeScreenshotButtonLabel:X,onFormClose:re,onFormOpen:B,onSubmitError:Ae,onSubmitSuccess:ce,onFormSubmitted:Me};let Ke=null,At=[];const Wn=be=>{if(!Ke){const De=fe.createElement("div");De.id=String(be.id),fe.body.appendChild(De),Ke=De.attachShadow({mode:"open"}),Ke.appendChild(O0(be))}return Ke},Gn=async be=>{const De=be.enableScreenshot&&k0();let bt,Te;try{bt=(t?t():await e("feedbackModalIntegration",m))(),Ca(bt)}catch{throw ds&&y.error("[Feedback] Error when trying to load feedback integrations. Try using `feedbackSyncIntegration` in your `Sentry.init`."),new Error("[Feedback] Missing feedback modal integration!")}try{const St=De?n?n():await e("feedbackScreenshotIntegration",m):void 0;St&&(Te=St(),Ca(Te))}catch{ds&&y.error("[Feedback] Missing feedback screenshot integration. Proceeding without screenshots.")}const Ne=bt.createDialog({options:{...be,onFormClose:()=>{Ne?.close(),be.onFormClose?.()},onFormSubmitted:()=>{Ne?.close(),be.onFormSubmitted?.()}},screenshotIntegration:Te,sendFeedback:jh,shadow:Wn(be)});return Ne},Dr=(be,De={})=>{const bt=Hi(ke,De),Te=typeof be=="string"?fe.querySelector(be):typeof be.addEventListener=="function"?be:null;if(!Te)throw ds&&y.error("[Feedback] Unable to attach to target element"),new Error("Unable to attach to target element");let Ne=null;const St=async()=>{Ne||(Ne=await Gn({...bt,onFormSubmitted:()=>{Ne?.removeFromDom(),bt.onFormSubmitted?.()}})),Ne.appendToDom(),Ne.open()};Te.addEventListener("click",St);const mn=()=>{At=At.filter(zn=>zn!==mn),Ne?.removeFromDom(),Ne=null,Te.removeEventListener("click",St)};return At.push(mn),mn},Mt=(be={})=>{const De=Hi(ke,be),bt=Wn(De),Te=M0({triggerLabel:De.triggerLabel,triggerAriaLabel:De.triggerAriaLabel,shadow:bt,styleNonce:p});return Dr(Te.el,{...De,onFormOpen(){Te.hide()},onFormClose(){Te.show()},onFormSubmitted(){Te.show()}}),Te};return{name:"Feedback",setupOnce(){!La()||!ke.autoInject||(fe.readyState==="loading"?fe.addEventListener("DOMContentLoaded",()=>Mt().appendToDom()):Mt().appendToDom())},attachTo:Dr,createWidget(be={}){const De=Mt(Hi(ke,be));return De.appendToDom(),De},async createForm(be={}){return Gn(Hi(ke,be))},remove(){Ke&&(Ke.parentElement?.remove(),Ke=null),At.forEach(be=>be()),At=[]}}};function L0(){return H()?.getIntegrationByName("Feedback")}var uo,pe,Xh,Sn,pl,Yh,Pa,ri={},Pc=[],P0=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Dc=Array.isArray;function en(e,t){for(var n in t)e[n]=t[n];return e}function Jh(e){var t=e.parentNode;t&&t.removeChild(e)}function te(e,t,n){var r,i,s,o={};for(s in t)s=="key"?r=t[s]:s=="ref"?i=t[s]:o[s]=t[s];if(arguments.length>2&&(o.children=arguments.length>3?uo.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(s in e.defaultProps)o[s]===void 0&&(o[s]=e.defaultProps[s]);return fs(e,o,r,i,null)}function fs(e,t,n,r,i){var s={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:i??++Xh,__i:-1,__u:0};return i==null&&pe.vnode!=null&&pe.vnode(s),s}function Ei(e){return e.children}function hs(e,t){this.props=e,this.context=t}function hr(e,t){if(t==null)return e.__?hr(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?hr(e):null}function D0(e,t,n){var r,i=e.__v,s=i.__e,o=e.__P;if(o)return(r=en({},i)).__v=i.__v+1,pe.vnode&&pe.vnode(r),Fc(o,r,i,e.__n,o.ownerSVGElement!==void 0,32&i.__u?[s]:null,t,s??hr(i),!!(32&i.__u),n),r.__.__k[r.__i]=r,r.__d=void 0,r.__e!=s&&Kh(r),r}function Kh(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Kh(e)}}function ml(e){(!e.__d&&(e.__d=!0)&&Sn.push(e)&&!Ds.__r++||pl!==pe.debounceRendering)&&((pl=pe.debounceRendering)||Yh)(Ds)}function Ds(){var e,t,n,r=[],i=[];for(Sn.sort(Pa);e=Sn.shift();)e.__d&&(n=Sn.length,t=D0(e,r,i)||t,n===0||Sn.length>n?(Da(r,t,i),i.length=r.length=0,t=void 0,Sn.sort(Pa)):t&&pe.__c&&pe.__c(t,Pc));t&&Da(r,t,i),Ds.__r=0}function Zh(e,t,n,r,i,s,o,a,c,u,d){var l,f,h,p,m,g=r&&r.__k||Pc,_=t.length;for(n.__d=c,F0(n,t,g),c=n.__d,l=0;l<_;l++)(h=n.__k[l])!=null&&typeof h!="boolean"&&typeof h!="function"&&(f=h.__i===-1?ri:g[h.__i]||ri,h.__i=l,Fc(e,h,f,i,s,o,a,c,u,d),p=h.__e,h.ref&&f.ref!=h.ref&&(f.ref&&Hc(f.ref,null,h),d.push(h.ref,h.__c||p,h)),m==null&&p!=null&&(m=p),65536&h.__u||f.__k===h.__k?c=Qh(h,c,e):typeof h.type=="function"&&h.__d!==void 0?c=h.__d:p&&(c=p.nextSibling),h.__d=void 0,h.__u&=-196609);n.__d=c,n.__e=m}function F0(e,t,n){var r,i,s,o,a,c=t.length,u=n.length,d=u,l=0;for(e.__k=[],r=0;r<c;r++)(i=e.__k[r]=(i=t[r])==null||typeof i=="boolean"||typeof i=="function"?null:typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?fs(null,i,null,null,i):Dc(i)?fs(Ei,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?fs(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)!=null?(i.__=e,i.__b=e.__b+1,a=H0(i,n,o=r+l,d),i.__i=a,s=null,a!==-1&&(d--,(s=n[a])&&(s.__u|=131072)),s==null||s.__v===null?(a==-1&&l--,typeof i.type!="function"&&(i.__u|=65536)):a!==o&&(a===o+1?l++:a>o?d>c-o?l+=a-o:l--:l=a<o&&a==o-1?a-o:0,a!==r+l&&(i.__u|=65536))):(s=n[r])&&s.key==null&&s.__e&&(s.__e==e.__d&&(e.__d=hr(s)),Fa(s,s,!1),n[r]=null,d--);if(d)for(r=0;r<u;r++)(s=n[r])!=null&&!(131072&s.__u)&&(s.__e==e.__d&&(e.__d=hr(s)),Fa(s,s))}function Qh(e,t,n){var r,i;if(typeof e.type=="function"){for(r=e.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=e,t=Qh(r[i],t,n));return t}e.__e!=t&&(n.insertBefore(e.__e,t||null),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType===8);return t}function H0(e,t,n,r){var i=e.key,s=e.type,o=n-1,a=n+1,c=t[n];if(c===null||c&&i==c.key&&s===c.type)return n;if(r>(c!=null&&!(131072&c.__u)?1:0))for(;o>=0||a<t.length;){if(o>=0){if((c=t[o])&&!(131072&c.__u)&&i==c.key&&s===c.type)return o;o--}if(a<t.length){if((c=t[a])&&!(131072&c.__u)&&i==c.key&&s===c.type)return a;a++}}return-1}function gl(e,t,n){t[0]==="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||P0.test(t)?n:n+"px"}function Bi(e,t,n,r,i){var s;e:if(t==="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof r=="string"&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||gl(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||gl(e.style,t,n[t])}else if(t[0]==="o"&&t[1]==="n")s=t!==(t=t.replace(/(PointerCapture)$|Capture$/i,"$1")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+s]=n,n?r?n.u=r.u:(n.u=Date.now(),e.addEventListener(t,s?yl:_l,s)):e.removeEventListener(t,s?yl:_l,s);else{if(i)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!=="width"&&t!=="height"&&t!=="href"&&t!=="list"&&t!=="form"&&t!=="tabIndex"&&t!=="download"&&t!=="rowSpan"&&t!=="colSpan"&&t!=="role"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!=="-"?e.removeAttribute(t):e.setAttribute(t,n))}}function _l(e){if(this.l){var t=this.l[e.type+!1];if(e.t){if(e.t<=t.u)return}else e.t=Date.now();return t(pe.event?pe.event(e):e)}}function yl(e){if(this.l)return this.l[e.type+!0](pe.event?pe.event(e):e)}function Fc(e,t,n,r,i,s,o,a,c,u){var d,l,f,h,p,m,g,_,v,L,A,O,T,C,M,x=t.type;if(t.constructor!==void 0)return null;128&n.__u&&(c=!!(32&n.__u),s=[a=t.__e=n.__e]),(d=pe.__b)&&d(t);e:if(typeof x=="function")try{if(_=t.props,v=(d=x.contextType)&&r[d.__c],L=d?v?v.props.value:d.__:r,n.__c?g=(l=t.__c=n.__c).__=l.__E:("prototype"in x&&x.prototype.render?t.__c=l=new x(_,L):(t.__c=l=new hs(_,L),l.constructor=x,l.render=U0),v&&v.sub(l),l.props=_,l.state||(l.state={}),l.context=L,l.__n=r,f=l.__d=!0,l.__h=[],l._sb=[]),l.__s==null&&(l.__s=l.state),x.getDerivedStateFromProps!=null&&(l.__s==l.state&&(l.__s=en({},l.__s)),en(l.__s,x.getDerivedStateFromProps(_,l.__s))),h=l.props,p=l.state,l.__v=t,f)x.getDerivedStateFromProps==null&&l.componentWillMount!=null&&l.componentWillMount(),l.componentDidMount!=null&&l.__h.push(l.componentDidMount);else{if(x.getDerivedStateFromProps==null&&_!==h&&l.componentWillReceiveProps!=null&&l.componentWillReceiveProps(_,L),!l.__e&&(l.shouldComponentUpdate!=null&&l.shouldComponentUpdate(_,l.__s,L)===!1||t.__v===n.__v)){for(t.__v!==n.__v&&(l.props=_,l.state=l.__s,l.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(R){R&&(R.__=t)}),A=0;A<l._sb.length;A++)l.__h.push(l._sb[A]);l._sb=[],l.__h.length&&o.push(l);break e}l.componentWillUpdate!=null&&l.componentWillUpdate(_,l.__s,L),l.componentDidUpdate!=null&&l.__h.push(function(){l.componentDidUpdate(h,p,m)})}if(l.context=L,l.props=_,l.__P=e,l.__e=!1,O=pe.__r,T=0,"prototype"in x&&x.prototype.render){for(l.state=l.__s,l.__d=!1,O&&O(t),d=l.render(l.props,l.state,l.context),C=0;C<l._sb.length;C++)l.__h.push(l._sb[C]);l._sb=[]}else do l.__d=!1,O&&O(t),d=l.render(l.props,l.state,l.context),l.state=l.__s;while(l.__d&&++T<25);l.state=l.__s,l.getChildContext!=null&&(r=en(en({},r),l.getChildContext())),f||l.getSnapshotBeforeUpdate==null||(m=l.getSnapshotBeforeUpdate(h,p)),Zh(e,Dc(M=d!=null&&d.type===Ei&&d.key==null?d.props.children:d)?M:[M],t,n,r,i,s,o,a,c,u),l.base=t.__e,t.__u&=-161,l.__h.length&&o.push(l),g&&(l.__E=l.__=null)}catch(R){t.__v=null,c||s!=null?(t.__e=a,t.__u|=c?160:32,s[s.indexOf(a)]=null):(t.__e=n.__e,t.__k=n.__k),pe.__e(R,t,n)}else s==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=B0(n.__e,t,n,r,i,s,o,c,u);(d=pe.diffed)&&d(t)}function Da(e,t,n){for(var r=0;r<n.length;r++)Hc(n[r],n[++r],n[++r]);pe.__c&&pe.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(s){s.call(i)})}catch(s){pe.__e(s,i.__v)}})}function B0(e,t,n,r,i,s,o,a,c){var u,d,l,f,h,p,m,g=n.props,_=t.props,v=t.type;if(v==="svg"&&(i=!0),s!=null){for(u=0;u<s.length;u++)if((h=s[u])&&"setAttribute"in h==!!v&&(v?h.localName===v:h.nodeType===3)){e=h,s[u]=null;break}}if(e==null){if(v===null)return document.createTextNode(_);e=i?document.createElementNS("http://www.w3.org/2000/svg",v):document.createElement(v,_.is&&_),s=null,a=!1}if(v===null)g===_||a&&e.data===_||(e.data=_);else{if(s=s&&uo.call(e.childNodes),g=n.props||ri,!a&&s!=null)for(g={},u=0;u<e.attributes.length;u++)g[(h=e.attributes[u]).name]=h.value;for(u in g)h=g[u],u=="children"||(u=="dangerouslySetInnerHTML"?l=h:u==="key"||u in _||Bi(e,u,null,h,i));for(u in _)h=_[u],u=="children"?f=h:u=="dangerouslySetInnerHTML"?d=h:u=="value"?p=h:u=="checked"?m=h:u==="key"||a&&typeof h!="function"||g[u]===h||Bi(e,u,h,g[u],i);if(d)a||l&&(d.__html===l.__html||d.__html===e.innerHTML)||(e.innerHTML=d.__html),t.__k=[];else if(l&&(e.innerHTML=""),Zh(e,Dc(f)?f:[f],t,n,r,i&&v!=="foreignObject",s,o,s?s[0]:n.__k&&hr(n,0),a,c),s!=null)for(u=s.length;u--;)s[u]!=null&&Jh(s[u]);a||(u="value",p!==void 0&&(p!==e[u]||v==="progress"&&!p||v==="option"&&p!==g[u])&&Bi(e,u,p,g[u],!1),u="checked",m!==void 0&&m!==e[u]&&Bi(e,u,m,g[u],!1))}return e}function Hc(e,t,n){try{typeof e=="function"?e(t):e.current=t}catch(r){pe.__e(r,n)}}function Fa(e,t,n){var r,i;if(pe.unmount&&pe.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Hc(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(s){pe.__e(s,t)}r.base=r.__P=null,e.__c=void 0}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&Fa(r[i],t,n||typeof e.type!="function");n||e.__e==null||Jh(e.__e),e.__=e.__e=e.__d=void 0}function U0(e,t,n){return this.constructor(e,n)}function $0(e,t,n){var r,i,s,o;pe.__&&pe.__(e,t),i=(r=!1)?null:t.__k,s=[],o=[],Fc(t,e=t.__k=te(Ei,null,[e]),i||ri,ri,t.ownerSVGElement!==void 0,i?null:t.firstChild?uo.call(t.childNodes):null,s,i?i.__e:t.firstChild,r,o),e.__d=void 0,Da(s,e,o)}uo=Pc.slice,pe={__e:function(e,t,n,r){for(var i,s,o;t=t.__;)if((i=t.__c)&&!i.__)try{if((s=i.constructor)&&s.getDerivedStateFromError!=null&&(i.setState(s.getDerivedStateFromError(e)),o=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),o=i.__d),o)return i.__E=i}catch(a){e=a}throw e}},Xh=0,hs.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=en({},this.state),typeof e=="function"&&(e=e(en({},n),this.props)),e&&en(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),ml(this))},hs.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),ml(this))},hs.prototype.render=Ei,Sn=[],Yh=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Pa=function(e,t){return e.__v.__b-t.__v.__b},Ds.__r=0;var jt,he,Fo,bl,pr=0,ep=[],ps=[],Ee=pe,Sl=Ee.__b,El=Ee.__r,vl=Ee.diffed,wl=Ee.__c,Tl=Ee.unmount,Il=Ee.__;function Un(e,t){Ee.__h&&Ee.__h(he,e,pr||t),pr=0;var n=he.__H||(he.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({__V:ps}),n.__[e]}function wn(e){return pr=1,tp(rp,e)}function tp(e,t,n){var r=Un(jt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):rp(void 0,t),function(a){var c=r.__N?r.__N[0]:r.__[0],u=r.t(c,a);c!==u&&(r.__N=[u,r.__[1]],r.__c.setState({}))}],r.__c=he,!he.u)){var i=function(a,c,u){if(!r.__c.__H)return!0;var d=r.__c.__H.__.filter(function(f){return!!f.__c});if(d.every(function(f){return!f.__N}))return!s||s.call(this,a,c,u);var l=!1;return d.forEach(function(f){if(f.__N){var h=f.__[0];f.__=f.__N,f.__N=void 0,h!==f.__[0]&&(l=!0)}}),!(!l&&r.__c.props===a)&&(!s||s.call(this,a,c,u))};he.u=!0;var s=he.shouldComponentUpdate,o=he.componentWillUpdate;he.componentWillUpdate=function(a,c,u){if(this.__e){var d=s;s=void 0,i(a,c,u),s=d}o&&o.call(this,a,c,u)},he.shouldComponentUpdate=i}return r.__N||r.__}function W0(e,t){var n=Un(jt++,3);!Ee.__s&&Bc(n.__H,t)&&(n.__=e,n.i=t,he.__H.__h.push(n))}function np(e,t){var n=Un(jt++,4);!Ee.__s&&Bc(n.__H,t)&&(n.__=e,n.i=t,he.__h.push(n))}function G0(e){return pr=5,vi(function(){return{current:e}},[])}function z0(e,t,n){pr=6,np(function(){return typeof e=="function"?(e(t()),function(){return e(null)}):e?(e.current=t(),function(){return e.current=null}):void 0},n==null?n:n.concat(e))}function vi(e,t){var n=Un(jt++,7);return Bc(n.__H,t)?(n.__V=e(),n.i=t,n.__h=e,n.__V):n.__}function sr(e,t){return pr=8,vi(function(){return e},t)}function j0(e){var t=he.context[e.__c],n=Un(jt++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(he)),t.props.value):e.__}function q0(e,t){Ee.useDebugValue&&Ee.useDebugValue(t?t(e):e)}function V0(e){var t=Un(jt++,10),n=wn();return t.__=e,he.componentDidCatch||(he.componentDidCatch=function(r,i){t.__&&t.__(r,i),n[1](r)}),[n[0],function(){n[1](void 0)}]}function X0(){var e=Un(jt++,11);if(!e.__){for(var t=he.__v;t!==null&&!t.__m&&t.__!==null;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function Y0(){for(var e;e=ep.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(ms),e.__H.__h.forEach(Ha),e.__H.__h=[]}catch(t){e.__H.__h=[],Ee.__e(t,e.__v)}}Ee.__b=function(e){he=null,Sl&&Sl(e)},Ee.__=function(e,t){t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Il&&Il(e,t)},Ee.__r=function(e){El&&El(e),jt=0;var t=(he=e.__c).__H;t&&(Fo===he?(t.__h=[],he.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=ps,n.__N=n.i=void 0})):(t.__h.forEach(ms),t.__h.forEach(Ha),t.__h=[],jt=0)),Fo=he},Ee.diffed=function(e){vl&&vl(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(ep.push(t)!==1&&bl===Ee.requestAnimationFrame||((bl=Ee.requestAnimationFrame)||J0)(Y0)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==ps&&(n.__=n.__V),n.i=void 0,n.__V=ps})),Fo=he=null},Ee.__c=function(e,t){t.some(function(n){try{n.__h.forEach(ms),n.__h=n.__h.filter(function(r){return!r.__||Ha(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],Ee.__e(r,n.__v)}}),wl&&wl(e,t)},Ee.unmount=function(e){Tl&&Tl(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{ms(r)}catch(i){t=i}}),n.__H=void 0,t&&Ee.__e(t,n.__v))};var xl=typeof requestAnimationFrame=="function";function J0(e){var t,n=function(){clearTimeout(r),xl&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);xl&&(t=requestAnimationFrame(n))}function ms(e){var t=he,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),he=t}function Ha(e){var t=he;e.__c=e.__(),he=t}function Bc(e,t){return!e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function rp(e,t){return typeof t=="function"?t(e):t}const K0=Object.defineProperty({__proto__:null,useCallback:sr,useContext:j0,useDebugValue:q0,useEffect:W0,useErrorBoundary:V0,useId:X0,useImperativeHandle:z0,useLayoutEffect:np,useMemo:vi,useReducer:tp,useRef:G0,useState:wn},Symbol.toStringTag,{value:"Module"}),Z0="http://www.w3.org/2000/svg";function Q0(){const e=r=>fe.createElementNS(Z0,r),t=et(e("svg"),{width:"32",height:"30",viewBox:"0 0 72 66",fill:"inherit"}),n=et(e("path"),{transform:"translate(11, 11)",d:"M29,2.26a4.67,4.67,0,0,0-8,0L14.42,13.53A32.21,32.21,0,0,1,32.17,40.19H27.55A27.68,27.68,0,0,0,12.09,17.47L6,28a15.92,15.92,0,0,1,9.23,12.17H4.62A.76.76,0,0,1,4,39.06l2.94-5a10.74,10.74,0,0,0-3.36-1.9l-2.91,5a4.54,4.54,0,0,0,1.69,6.24A4.66,4.66,0,0,0,4.62,44H19.15a19.4,19.4,0,0,0-8-17.31l2.31-4A23.87,23.87,0,0,1,23.76,44H36.07a35.88,35.88,0,0,0-16.41-31.8l4.67-8a.77.77,0,0,1,1.05-.27c.53.29,20.29,34.77,20.66,35.17a.76.76,0,0,1-.68,1.13H40.6q.09,1.91,0,3.81h4.78A4.59,4.59,0,0,0,50,39.43a4.49,4.49,0,0,0-.62-2.28Z"});return t.appendChild(n),t}function eE({options:e}){const t=vi(()=>({__html:Q0().outerHTML}),[]);return te("h2",{class:"dialog__header"},te("span",{class:"dialog__title"},e.formTitle),e.showBranding?te("a",{class:"brand-link",target:"_blank",href:"https://sentry.io/welcome/",title:"Powered by Sentry",rel:"noopener noreferrer",dangerouslySetInnerHTML:t}):null)}function tE(e,t){const n=[];return t.isNameRequired&&!e.name&&n.push(t.nameLabel),t.isEmailRequired&&!e.email&&n.push(t.emailLabel),e.message||n.push(t.messageLabel),n}function Ho(e,t){const n=e.get(t);return typeof n=="string"?n.trim():""}function nE({options:e,defaultEmail:t,defaultName:n,onFormClose:r,onSubmit:i,onSubmitSuccess:s,onSubmitError:o,showEmail:a,showName:c,screenshotInput:u}){const{tags:d,addScreenshotButtonLabel:l,removeScreenshotButtonLabel:f,cancelButtonLabel:h,emailLabel:p,emailPlaceholder:m,isEmailRequired:g,isNameRequired:_,messageLabel:v,messagePlaceholder:L,nameLabel:A,namePlaceholder:O,submitButtonLabel:T,isRequiredLabel:C}=e,[M,x]=wn(!1),[R,P]=wn(null),[k,F]=wn(!1),X=u?.input,[U,J]=wn(null),N=sr(re=>{J(re),F(!1)},[]),G=sr(re=>{const ce=tE(re,{emailLabel:p,isEmailRequired:g,isNameRequired:_,messageLabel:v,nameLabel:A});return ce.length>0?P(`Please enter in the following required fields: ${ce.join(", ")}`):P(null),ce.length===0},[p,g,_,v,A]),B=sr(async re=>{x(!0);try{if(re.preventDefault(),!(re.target instanceof HTMLFormElement))return;const ce=new FormData(re.target),Ae=await(u&&k?u.value():void 0),Me={name:Ho(ce,"name"),email:Ho(ce,"email"),message:Ho(ce,"message"),attachments:Ae?[Ae]:void 0};if(!G(Me))return;try{const ke=await i({name:Me.name,email:Me.email,message:Me.message,source:T0,tags:d},{attachments:Me.attachments});s(Me,ke)}catch(ke){ds&&y.error(ke),P(ke),o(ke)}}finally{x(!1)}},[u&&k,s,o]);return te("form",{class:"form",onSubmit:B},X&&k?te(X,{onError:N}):null,te("fieldset",{class:"form__right","data-sentry-feedback":!0,disabled:M},te("div",{class:"form__top"},R?te("div",{class:"form__error-container"},R):null,c?te("label",{for:"name",class:"form__label"},te(Bo,{label:A,isRequiredLabel:C,isRequired:_}),te("input",{class:"form__input",defaultValue:n,id:"name",name:"name",placeholder:O,required:_,type:"text"})):te("input",{"aria-hidden":!0,value:n,name:"name",type:"hidden"}),a?te("label",{for:"email",class:"form__label"},te(Bo,{label:p,isRequiredLabel:C,isRequired:g}),te("input",{class:"form__input",defaultValue:t,id:"email",name:"email",placeholder:m,required:g,type:"email"})):te("input",{"aria-hidden":!0,value:t,name:"email",type:"hidden"}),te("label",{for:"message",class:"form__label"},te(Bo,{label:v,isRequiredLabel:C,isRequired:!0}),te("textarea",{autoFocus:!0,class:"form__input form__input--textarea",id:"message",name:"message",placeholder:L,required:!0,rows:5})),X?te("label",{for:"screenshot",class:"form__label"},te("button",{class:"btn btn--default",disabled:M,type:"button",onClick:()=>{J(null),F(re=>!re)}},k?f:l),U?te("div",{class:"form__error-container"},U.message):null):null),te("div",{class:"btn-group"},te("button",{class:"btn btn--primary",disabled:M,type:"submit"},T),te("button",{class:"btn btn--default",disabled:M,type:"button",onClick:r},h))))}function Bo({label:e,isRequired:t,isRequiredLabel:n}){return te("span",{class:"form__label__text"},e,t&&te("span",{class:"form__label__text--required"},n))}const Ui=16,kl=17,rE="http://www.w3.org/2000/svg";function iE(){const e=c=>dt.document.createElementNS(rE,c),t=et(e("svg"),{width:`${Ui}`,height:`${kl}`,viewBox:`0 0 ${Ui} ${kl}`,fill:"inherit"}),n=et(e("g"),{clipPath:"url(#clip0_57_156)"}),r=et(e("path"),{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M3.55544 15.1518C4.87103 16.0308 6.41775 16.5 8 16.5C10.1217 16.5 12.1566 15.6571 13.6569 14.1569C15.1571 12.6566 16 10.6217 16 8.5C16 6.91775 15.5308 5.37103 14.6518 4.05544C13.7727 2.73985 12.5233 1.71447 11.0615 1.10897C9.59966 0.503466 7.99113 0.34504 6.43928 0.653721C4.88743 0.962403 3.46197 1.72433 2.34315 2.84315C1.22433 3.96197 0.462403 5.38743 0.153721 6.93928C-0.15496 8.49113 0.00346625 10.0997 0.608967 11.5615C1.21447 13.0233 2.23985 14.2727 3.55544 15.1518ZM4.40546 3.1204C5.46945 2.40946 6.72036 2.03 8 2.03C9.71595 2.03 11.3616 2.71166 12.575 3.92502C13.7883 5.13838 14.47 6.78405 14.47 8.5C14.47 9.77965 14.0905 11.0306 13.3796 12.0945C12.6687 13.1585 11.6582 13.9878 10.476 14.4775C9.29373 14.9672 7.99283 15.0953 6.73777 14.8457C5.48271 14.596 4.32987 13.9798 3.42502 13.075C2.52018 12.1701 1.90397 11.0173 1.65432 9.76224C1.40468 8.50718 1.5328 7.20628 2.0225 6.02404C2.5122 4.8418 3.34148 3.83133 4.40546 3.1204Z"}),i=et(e("path"),{d:"M6.68775 12.4297C6.78586 12.4745 6.89218 12.4984 7 12.5C7.11275 12.4955 7.22315 12.4664 7.32337 12.4145C7.4236 12.3627 7.51121 12.2894 7.58 12.2L12 5.63999C12.0848 5.47724 12.1071 5.28902 12.0625 5.11098C12.0178 4.93294 11.9095 4.77744 11.7579 4.67392C11.6064 4.57041 11.4221 4.52608 11.24 4.54931C11.0579 4.57254 10.8907 4.66173 10.77 4.79999L6.88 10.57L5.13 8.56999C5.06508 8.49566 4.98613 8.43488 4.89768 8.39111C4.80922 8.34735 4.713 8.32148 4.61453 8.31498C4.51605 8.30847 4.41727 8.32147 4.32382 8.35322C4.23038 8.38497 4.14413 8.43484 4.07 8.49999C3.92511 8.63217 3.83692 8.81523 3.82387 9.01092C3.81083 9.2066 3.87393 9.39976 4 9.54999L6.43 12.24C6.50187 12.3204 6.58964 12.385 6.68775 12.4297Z"});t.appendChild(n).append(i,r);const s=e("defs"),o=et(e("clipPath"),{id:"clip0_57_156"}),a=et(e("rect"),{width:`${Ui}`,height:`${Ui}`,fill:"white",transform:"translate(0 0.5)"});return o.appendChild(a),s.appendChild(o),t.appendChild(s).appendChild(o).appendChild(a),t}function sE({open:e,onFormSubmitted:t,...n}){const r=n.options,i=vi(()=>({__html:iE().outerHTML}),[]),[s,o]=wn(null),a=sr(()=>{s&&(clearTimeout(s),o(null)),t()},[s]),c=sr((u,d)=>{n.onSubmitSuccess(u,d),o(setTimeout(()=>{t(),o(null)},x0))},[t]);return te(Ei,null,s?te("div",{class:"success__position",onClick:a},te("div",{class:"success__content"},r.successMessageText,te("span",{class:"success__icon",dangerouslySetInnerHTML:i}))):te("dialog",{class:"dialog",onClick:r.onFormClose,open:e},te("div",{class:"dialog__position"},te("div",{class:"dialog__content",onClick:u=>{u.stopPropagation()}},te(eE,{options:r}),te(nE,{...n,onSubmitSuccess:c})))))}const oE=`
107
+ .dialog {
108
+ position: fixed;
109
+ z-index: var(--z-index);
110
+ margin: 0;
111
+ inset: 0;
112
+
113
+ display: flex;
114
+ align-items: center;
115
+ justify-content: center;
116
+ padding: 0;
117
+ height: 100vh;
118
+ width: 100vw;
119
+
120
+ color: var(--dialog-color, var(--foreground));
121
+ fill: var(--dialog-color, var(--foreground));
122
+ line-height: 1.75em;
123
+
124
+ background-color: rgba(0, 0, 0, 0.05);
125
+ border: none;
126
+ inset: 0;
127
+ opacity: 1;
128
+ transition: opacity 0.2s ease-in-out;
129
+ }
130
+
131
+ .dialog__position {
132
+ position: fixed;
133
+ z-index: var(--z-index);
134
+ inset: var(--dialog-inset);
135
+ padding: var(--page-margin);
136
+ display: flex;
137
+ max-height: calc(100vh - (2 * var(--page-margin)));
138
+ }
139
+ @media (max-width: 600px) {
140
+ .dialog__position {
141
+ inset: var(--page-margin);
142
+ padding: 0;
143
+ }
144
+ }
145
+
146
+ .dialog__position:has(.editor) {
147
+ inset: var(--page-margin);
148
+ padding: 0;
149
+ }
150
+
151
+ .dialog:not([open]) {
152
+ opacity: 0;
153
+ pointer-events: none;
154
+ visibility: hidden;
155
+ }
156
+ .dialog:not([open]) .dialog__content {
157
+ transform: translate(0, -16px) scale(0.98);
158
+ }
159
+
160
+ .dialog__content {
161
+ display: flex;
162
+ flex-direction: column;
163
+ gap: 16px;
164
+ padding: var(--dialog-padding, 24px);
165
+ max-width: 100%;
166
+ width: 100%;
167
+ max-height: 100%;
168
+ overflow: auto;
169
+
170
+ background: var(--dialog-background, var(--background));
171
+ border-radius: var(--dialog-border-radius, 20px);
172
+ border: var(--dialog-border, var(--border));
173
+ box-shadow: var(--dialog-box-shadow, var(--box-shadow));
174
+ transform: translate(0, 0) scale(1);
175
+ transition: transform 0.2s ease-in-out;
176
+ }
177
+
178
+ `,aE=`
179
+ .dialog__header {
180
+ display: flex;
181
+ gap: 4px;
182
+ justify-content: space-between;
183
+ font-weight: var(--dialog-header-weight, 600);
184
+ margin: 0;
185
+ }
186
+ .dialog__title {
187
+ align-self: center;
188
+ width: var(--form-width, 272px);
189
+ }
190
+
191
+ @media (max-width: 600px) {
192
+ .dialog__title {
193
+ width: auto;
194
+ }
195
+ }
196
+
197
+ .dialog__position:has(.editor) .dialog__title {
198
+ width: auto;
199
+ }
200
+
201
+
202
+ .brand-link {
203
+ display: inline-flex;
204
+ }
205
+ .brand-link:focus-visible {
206
+ outline: var(--outline);
207
+ }
208
+ `,cE=`
209
+ .form {
210
+ display: flex;
211
+ overflow: auto;
212
+ flex-direction: row;
213
+ gap: 16px;
214
+ flex: 1 0;
215
+ }
216
+
217
+ .form fieldset {
218
+ border: none;
219
+ margin: 0;
220
+ padding: 0;
221
+ }
222
+
223
+ .form__right {
224
+ flex: 0 0 auto;
225
+ display: flex;
226
+ overflow: auto;
227
+ flex-direction: column;
228
+ justify-content: space-between;
229
+ gap: 20px;
230
+ width: var(--form-width, 100%);
231
+ }
232
+
233
+ .dialog__position:has(.editor) .form__right {
234
+ width: var(--form-width, 272px);
235
+ }
236
+
237
+ .form__top {
238
+ display: flex;
239
+ flex-direction: column;
240
+ gap: 8px;
241
+ }
242
+
243
+ .form__error-container {
244
+ color: var(--error-color);
245
+ fill: var(--error-color);
246
+ }
247
+
248
+ .form__label {
249
+ display: flex;
250
+ flex-direction: column;
251
+ gap: 4px;
252
+ margin: 0px;
253
+ }
254
+
255
+ .form__label__text {
256
+ display: flex;
257
+ gap: 4px;
258
+ align-items: center;
259
+ }
260
+
261
+ .form__label__text--required {
262
+ font-size: 0.85em;
263
+ }
264
+
265
+ .form__input {
266
+ font-family: inherit;
267
+ line-height: inherit;
268
+ background: transparent;
269
+ box-sizing: border-box;
270
+ border: var(--input-border, var(--border));
271
+ border-radius: var(--input-border-radius, 6px);
272
+ color: var(--input-color, inherit);
273
+ fill: var(--input-color, inherit);
274
+ font-size: var(--input-font-size, inherit);
275
+ font-weight: var(--input-font-weight, 500);
276
+ padding: 6px 12px;
277
+ }
278
+
279
+ .form__input::placeholder {
280
+ opacity: 0.65;
281
+ color: var(--input-placeholder-color, inherit);
282
+ filter: var(--interactive-filter);
283
+ }
284
+
285
+ .form__input:focus-visible {
286
+ outline: var(--input-focus-outline, var(--outline));
287
+ }
288
+
289
+ .form__input--textarea {
290
+ font-family: inherit;
291
+ resize: vertical;
292
+ }
293
+
294
+ .error {
295
+ color: var(--error-color);
296
+ fill: var(--error-color);
297
+ }
298
+ `,uE=`
299
+ .btn-group {
300
+ display: grid;
301
+ gap: 8px;
302
+ }
303
+
304
+ .btn {
305
+ line-height: inherit;
306
+ border: var(--button-border, var(--border));
307
+ border-radius: var(--button-border-radius, 6px);
308
+ cursor: pointer;
309
+ font-family: inherit;
310
+ font-size: var(--button-font-size, inherit);
311
+ font-weight: var(--button-font-weight, 600);
312
+ padding: var(--button-padding, 6px 16px);
313
+ }
314
+ .btn[disabled] {
315
+ opacity: 0.6;
316
+ pointer-events: none;
317
+ }
318
+
319
+ .btn--primary {
320
+ color: var(--button-primary-color, var(--accent-foreground));
321
+ fill: var(--button-primary-color, var(--accent-foreground));
322
+ background: var(--button-primary-background, var(--accent-background));
323
+ border: var(--button-primary-border, var(--border));
324
+ border-radius: var(--button-primary-border-radius, 6px);
325
+ font-weight: var(--button-primary-font-weight, 500);
326
+ }
327
+ .btn--primary:hover {
328
+ color: var(--button-primary-hover-color, var(--accent-foreground));
329
+ fill: var(--button-primary-hover-color, var(--accent-foreground));
330
+ background: var(--button-primary-hover-background, var(--accent-background));
331
+ filter: var(--interactive-filter);
332
+ }
333
+ .btn--primary:focus-visible {
334
+ background: var(--button-primary-hover-background, var(--accent-background));
335
+ filter: var(--interactive-filter);
336
+ outline: var(--button-primary-focus-outline, var(--outline));
337
+ }
338
+
339
+ .btn--default {
340
+ color: var(--button-color, var(--foreground));
341
+ fill: var(--button-color, var(--foreground));
342
+ background: var(--button-background, var(--background));
343
+ border: var(--button-border, var(--border));
344
+ border-radius: var(--button-border-radius, 6px);
345
+ font-weight: var(--button-font-weight, 500);
346
+ }
347
+ .btn--default:hover {
348
+ color: var(--button-color, var(--foreground));
349
+ fill: var(--button-color, var(--foreground));
350
+ background: var(--button-hover-background, var(--background));
351
+ filter: var(--interactive-filter);
352
+ }
353
+ .btn--default:focus-visible {
354
+ background: var(--button-hover-background, var(--background));
355
+ filter: var(--interactive-filter);
356
+ outline: var(--button-focus-outline, var(--outline));
357
+ }
358
+ `,lE=`
359
+ .success__position {
360
+ position: fixed;
361
+ inset: var(--dialog-inset);
362
+ padding: var(--page-margin);
363
+ z-index: var(--z-index);
364
+ }
365
+ .success__content {
366
+ background: var(--success-background, var(--background));
367
+ border: var(--success-border, var(--border));
368
+ border-radius: var(--success-border-radius, 1.7em/50%);
369
+ box-shadow: var(--success-box-shadow, var(--box-shadow));
370
+ font-weight: var(--success-font-weight, 600);
371
+ color: var(--success-color);
372
+ fill: var(--success-color);
373
+ padding: 12px 24px;
374
+ line-height: 1.75em;
375
+
376
+ display: grid;
377
+ align-items: center;
378
+ grid-auto-flow: column;
379
+ gap: 6px;
380
+ cursor: default;
381
+ }
382
+
383
+ .success__icon {
384
+ display: flex;
385
+ }
386
+ `;function dE(e){const t=fe.createElement("style");return t.textContent=`
387
+ :host {
388
+ --dialog-inset: var(--inset);
389
+ }
390
+
391
+ ${oE}
392
+ ${aE}
393
+ ${cE}
394
+ ${uE}
395
+ ${lE}
396
+ `,e&&t.setAttribute("nonce",e),t}function fE(){const e=Q().getUser(),t=Le().getUser(),n=no().getUser();return e&&Object.keys(e).length?e:t&&Object.keys(t).length?t:n}const hE=()=>({name:"FeedbackModal",setupOnce(){},createDialog:({options:e,screenshotIntegration:t,sendFeedback:n,shadow:r})=>{const i=r,s=e.useSentryUser,o=fE(),a=fe.createElement("div"),c=dE(e.styleNonce);let u="";const d={get el(){return a},appendToDom(){!i.contains(c)&&!i.contains(a)&&(i.appendChild(c),i.appendChild(a))},removeFromDom(){a.remove(),c.remove(),fe.body.style.overflow=u},open(){f(!0),e.onFormOpen?.(),H()?.emit("openFeedbackWidget"),u=fe.body.style.overflow,fe.body.style.overflow="hidden"},close(){f(!1),fe.body.style.overflow=u}},l=t?.createInput({h:te,hooks:K0,dialog:d,options:e}),f=h=>{$0(te(sE,{options:e,screenshotInput:l,showName:e.showName||e.isNameRequired,showEmail:e.showEmail||e.isEmailRequired,defaultName:s&&o?.[s.name]||"",defaultEmail:s&&o?.[s.email]||"",onFormClose:()=>{f(!1),e.onFormClose?.()},onSubmit:n,onSubmitSuccess:(p,m)=>{f(!1),e.onSubmitSuccess?.(p,m)},onSubmitError:p=>{e.onSubmitError?.(p)},onFormSubmitted:()=>{e.onFormSubmitted?.()},open:h}),a)};return d}});function pE({h:e}){return function(){return e("svg",{"data-test-id":"icon-close",viewBox:"0 0 16 16",fill:"#2B2233",height:"25px",width:"25px"},e("circle",{r:"7",cx:"8",cy:"8",fill:"white"}),e("path",{strokeWidth:"1.5",d:"M8,16a8,8,0,1,1,8-8A8,8,0,0,1,8,16ZM8,1.53A6.47,6.47,0,1,0,14.47,8,6.47,6.47,0,0,0,8,1.53Z"}),e("path",{strokeWidth:"1.5",d:"M5.34,11.41a.71.71,0,0,1-.53-.22.74.74,0,0,1,0-1.06l5.32-5.32a.75.75,0,0,1,1.06,1.06L5.87,11.19A.74.74,0,0,1,5.34,11.41Z"}),e("path",{strokeWidth:"1.5",d:"M10.66,11.41a.74.74,0,0,1-.53-.22L4.81,5.87A.75.75,0,0,1,5.87,4.81l5.32,5.32a.74.74,0,0,1,0,1.06A.71.71,0,0,1,10.66,11.41Z"}))}}function mE(e){const t=fe.createElement("style"),n="#1A141F",r="#302735";return t.textContent=`
397
+ .editor {
398
+ display: flex;
399
+ flex-grow: 1;
400
+ flex-direction: column;
401
+ }
402
+
403
+ .editor__image-container {
404
+ justify-items: center;
405
+ padding: 15px;
406
+ position: relative;
407
+ height: 100%;
408
+ border-radius: var(--menu-border-radius, 6px);
409
+
410
+ background-color: ${n};
411
+ background-image: repeating-linear-gradient(
412
+ -145deg,
413
+ transparent,
414
+ transparent 8px,
415
+ ${n} 8px,
416
+ ${n} 11px
417
+ ),
418
+ repeating-linear-gradient(
419
+ -45deg,
420
+ transparent,
421
+ transparent 15px,
422
+ ${r} 15px,
423
+ ${r} 16px
424
+ );
425
+ }
426
+
427
+ .editor__canvas-container {
428
+ width: 100%;
429
+ height: 100%;
430
+ position: relative;
431
+ display: flex;
432
+ align-items: center;
433
+ justify-content: center;
434
+ }
435
+
436
+ .editor__canvas-container > * {
437
+ object-fit: contain;
438
+ position: absolute;
439
+ }
440
+
441
+ .editor__tool-container {
442
+ padding-top: 8px;
443
+ display: flex;
444
+ justify-content: center;
445
+ }
446
+
447
+ .editor__tool-bar {
448
+ display: flex;
449
+ gap: 8px;
450
+ }
451
+
452
+ .editor__tool {
453
+ display: flex;
454
+ padding: 8px 12px;
455
+ justify-content: center;
456
+ align-items: center;
457
+ border: var(--button-border, var(--border));
458
+ border-radius: var(--button-border-radius, 6px);
459
+ background: var(--button-background, var(--background));
460
+ color: var(--button-color, var(--foreground));
461
+ }
462
+
463
+ .editor__tool--active {
464
+ background: var(--button-primary-background, var(--accent-background));
465
+ color: var(--button-primary-color, var(--accent-foreground));
466
+ }
467
+
468
+ .editor__rect {
469
+ position: absolute;
470
+ z-index: 2;
471
+ }
472
+
473
+ .editor__rect button {
474
+ opacity: 0;
475
+ position: absolute;
476
+ top: -12px;
477
+ right: -12px;
478
+ cursor: pointer;
479
+ padding: 0;
480
+ z-index: 3;
481
+ border: none;
482
+ background: none;
483
+ }
484
+
485
+ .editor__rect:hover button {
486
+ opacity: 1;
487
+ }
488
+ `,e&&t.setAttribute("nonce",e),t}function gE({h:e}){return function({action:n,setAction:r}){return e("div",{class:"editor__tool-container"},e("div",{class:"editor__tool-bar"},e("button",{type:"button",class:`editor__tool ${n==="highlight"?"editor__tool--active":""}`,onClick:()=>{r(n==="highlight"?"":"highlight")}},"Highlight"),e("button",{type:"button",class:`editor__tool ${n==="hide"?"editor__tool--active":""}`,onClick:()=>{r(n==="hide"?"":"hide")}},"Hide")))}}function _E({hooks:e}){function t(){const[n,r]=e.useState(dt.devicePixelRatio??1);return e.useEffect(()=>{const i=()=>{r(dt.devicePixelRatio)},s=matchMedia(`(resolution: ${dt.devicePixelRatio}dppx)`);return s.addEventListener("change",i),()=>{s.removeEventListener("change",i)}},[]),n}return function({onBeforeScreenshot:r,onScreenshot:i,onAfterScreenshot:s,onError:o}){const a=t();e.useEffect(()=>{(async()=>{r();const u=await Vr.mediaDevices.getDisplayMedia({video:{width:dt.innerWidth*a,height:dt.innerHeight*a},audio:!1,monitorTypeSurfaces:"exclude",preferCurrentTab:!0,selfBrowserSurface:"include",surfaceSwitching:"exclude"}),d=fe.createElement("video");await new Promise((l,f)=>{d.srcObject=u,d.onloadedmetadata=()=>{i(d,a),u.getTracks().forEach(h=>h.stop()),l()},d.play().catch(f)}),s()})().catch(o)},[])}}function yE(e,t,n){switch(e.type){case"highlight":{t.shadowColor="rgba(0, 0, 0, 0.7)",t.shadowBlur=50,t.fillStyle=n,t.fillRect(e.x-1,e.y-1,e.w+2,e.h+2),t.clearRect(e.x,e.y,e.w,e.h);break}case"hide":t.fillStyle="rgb(0, 0, 0)",t.fillRect(e.x,e.y,e.w,e.h);break}}function Kt(e,t,n){if(!e)return;const r=e.getContext("2d",t);r&&n(e,r)}function Uo(e,t){Kt(e,{alpha:!0},(n,r)=>{r.drawImage(t,0,0,t.width,t.height,0,0,n.width,n.height)})}function $o(e,t,n){Kt(e,{alpha:!0},(r,i)=>{n.length&&(i.fillStyle="rgba(0, 0, 0, 0.25)",i.fillRect(0,0,r.width,r.height)),n.forEach(s=>{yE(s,i,t)})})}function bE({h:e,hooks:t,outputBuffer:n,dialog:r,options:i}){const s=_E({hooks:t}),o=gE({h:e}),a=pE({h:e}),c={__html:mE(i.styleNonce).innerText},u=r.el.style,d=({screenshot:l})=>{const[f,h]=t.useState("highlight"),[p,m]=t.useState([]),g=t.useRef(null),_=t.useRef(null),v=t.useRef(null),L=t.useRef(null),[A,O]=t.useState(1),T=t.useMemo(()=>{const k=fe.getElementById(i.id);if(!k)return"white";const F=getComputedStyle(k);return F.getPropertyValue("--button-primary-background")||F.getPropertyValue("--accent-background")},[i.id]);t.useLayoutEffect(()=>{const k=()=>{const F=g.current;F&&(Kt(l.canvas,{alpha:!1},X=>{const U=Math.min(F.clientWidth/X.width,F.clientHeight/X.height);O(U)}),(F.clientHeight===0||F.clientWidth===0)&&setTimeout(k,0))};return k(),dt.addEventListener("resize",k),()=>{dt.removeEventListener("resize",k)}},[l]);const C=t.useCallback((k,F)=>{Kt(k,{alpha:!0},(X,U)=>{U.scale(F,F),X.width=l.canvas.width,X.height=l.canvas.height})},[l]);t.useEffect(()=>{C(_.current,l.dpi),Uo(_.current,l.canvas)},[l]),t.useEffect(()=>{C(v.current,l.dpi),Kt(v.current,{alpha:!0},(k,F)=>{F.clearRect(0,0,k.width,k.height)}),$o(v.current,T,p)},[p,T]),t.useEffect(()=>{C(n,l.dpi),Uo(n,l.canvas),Kt(fe.createElement("canvas"),{alpha:!0},(k,F)=>{F.scale(l.dpi,l.dpi),k.width=l.canvas.width,k.height=l.canvas.height,$o(k,T,p),Uo(n,k)})},[p,l,T]);const M=k=>{if(!f||!L.current)return;const F=L.current.getBoundingClientRect(),X={type:f,x:k.offsetX/A,y:k.offsetY/A},U=(G,B)=>{const re=(B.clientX-F.x)/A,ce=(B.clientY-F.y)/A;return{type:G.type,x:Math.min(G.x,re),y:Math.min(G.y,ce),w:Math.abs(re-G.x),h:Math.abs(ce-G.y)}},J=G=>{Kt(v.current,{alpha:!0},(B,re)=>{re.clearRect(0,0,B.width,B.height)}),$o(v.current,T,[...p,U(X,G)])},N=G=>{const B=U(X,G);B.w*A>=1&&B.h*A>=1&&m(re=>[...re,B]),fe.removeEventListener("mousemove",J),fe.removeEventListener("mouseup",N)};fe.addEventListener("mousemove",J),fe.addEventListener("mouseup",N)},x=t.useCallback(k=>F=>{F.preventDefault(),F.stopPropagation(),m(X=>{const U=[...X];return U.splice(k,1),U})},[]),R={width:`${l.canvas.width*A}px`,height:`${l.canvas.height*A}px`},P=k=>{k.stopPropagation()};return e("div",{class:"editor"},e("style",{nonce:i.styleNonce,dangerouslySetInnerHTML:c}),e("div",{class:"editor__image-container"},e("div",{class:"editor__canvas-container",ref:g},e("canvas",{ref:_,id:"background",style:R}),e("canvas",{ref:v,id:"foreground",style:R}),e("div",{ref:L,onMouseDown:M,style:R},p.map((k,F)=>e("div",{key:F,class:"editor__rect",style:{top:`${k.y*A}px`,left:`${k.x*A}px`,width:`${k.w*A}px`,height:`${k.h*A}px`}},e("button",{"aria-label":"Remove",onClick:x(F),onMouseDown:P,onMouseUp:P,type:"button"},e(a,null))))))),e(o,{action:f,setAction:h}))};return function({onError:f}){const[h,p]=t.useState();return s({onBeforeScreenshot:t.useCallback(()=>{u.display="none"},[]),onScreenshot:t.useCallback((m,g)=>{Kt(fe.createElement("canvas"),{alpha:!1},(_,v)=>{v.scale(g,g),_.width=m.videoWidth,_.height=m.videoHeight,v.drawImage(m,0,0,_.width,_.height),p({canvas:_,dpi:g})}),n.width=m.videoWidth,n.height=m.videoHeight},[]),onAfterScreenshot:t.useCallback(()=>{u.display="block"},[]),onError:t.useCallback(m=>{u.display="block",f(m)},[])}),h?e(d,{screenshot:h}):e("div",null)}}const SE=()=>({name:"FeedbackScreenshot",setupOnce(){},createInput:({h:e,hooks:t,dialog:n,options:r})=>{const i=fe.createElement("canvas");return{input:bE({h:e,hooks:t,outputBuffer:i,dialog:n,options:r}),value:async()=>{const s=await new Promise(o=>{i.toBlob(o,"image/png")});if(s)return{data:new Uint8Array(await s.arrayBuffer()),filename:"screenshot.png",contentType:"application/png"}}}}}),W=q;let Ba=0;function ip(){return Ba>0}function EE(){Ba++,setTimeout(()=>{Ba--})}function mr(e,t={}){function n(i){return typeof i=="function"}if(!n(e))return e;try{const i=e.__sentry_wrapped__;if(i)return typeof i=="function"?i:e;if(bc(e))return e}catch{return e}const r=function(...i){try{const s=i.map(o=>mr(o,t));return e.apply(this,s)}catch(s){throw EE(),ot(o=>{o.addEventProcessor(a=>(t.mechanism&&(ba(a,void 0),sn(a,t.mechanism)),a.extra={...a.extra,arguments:i},a)),Nn(s)}),s}};try{for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&(r[i]=e[i])}catch{}Tf(r,e),Ye(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}function Uc(){const e=Pn(),{referrer:t}=W.document||{},{userAgent:n}=W.navigator||{},r={...t&&{Referer:t},...n&&{"User-Agent":n}};return{url:e,headers:r}}const vE={replayIntegration:"replay",replayCanvasIntegration:"replay-canvas",feedbackIntegration:"feedback",feedbackModalIntegration:"feedback-modal",feedbackScreenshotIntegration:"feedback-screenshot",captureConsoleIntegration:"captureconsole",contextLinesIntegration:"contextlines",linkedErrorsIntegration:"linkederrors",dedupeIntegration:"dedupe",extraErrorDataIntegration:"extraerrordata",graphqlClientIntegration:"graphqlclient",httpClientIntegration:"httpclient",reportingObserverIntegration:"reportingobserver",rewriteFramesIntegration:"rewriteframes",browserProfilingIntegration:"browserprofiling",moduleMetadataIntegration:"modulemetadata"},Cl=W;async function sp(e,t){const n=vE[e],r=Cl.Sentry=Cl.Sentry||{};if(!n)throw new Error(`Cannot lazy load integration: ${e}`);const i=r[e];if(typeof i=="function"&&!("_isShim"in i))return i;const s=wE(n),o=W.document.createElement("script");o.src=s,o.crossOrigin="anonymous",o.referrerPolicy="strict-origin",t&&o.setAttribute("nonce",t);const a=new Promise((l,f)=>{o.addEventListener("load",()=>l()),o.addEventListener("error",f)}),c=W.document.currentScript,u=W.document.body||W.document.head||c?.parentElement;if(u)u.appendChild(o);else throw new Error(`Could not find parent element to insert lazy-loaded ${e} script`);try{await a}catch{throw new Error(`Error when loading integration: ${e}`)}const d=r[e];if(typeof d!="function")throw new Error(`Could not load integration: ${e}`);return d}function wE(e){const n=H()?.getOptions()?.cdnBaseUrl||"https://browser.sentry-cdn.com";return new URL(`/${Dt}/${e}.min.js`,n).toString()}const TE=Vh({lazyLoadIntegration:sp}),Rl=Vh({getModalIntegration:()=>hE,getScreenshotIntegration:()=>SE});function Ar(e,t,n,r){Aa({level:e,message:t,attributes:n,severityNumber:r})}function IE(e,t){Ar("trace",e,t)}function xE(e,t){Ar("debug",e,t)}function kE(e,t){Ar("info",e,t)}function CE(e,t){Ar("warn",e,t)}function RE(e,t){Ar("error",e,t)}function AE(e,t){Ar("fatal",e,t)}const ME=Object.freeze(Object.defineProperty({__proto__:null,debug:xE,error:RE,fatal:AE,fmt:vb,info:kE,trace:IE,warn:CE},Symbol.toStringTag,{value:"Module"}));function lo(e,t){const n=$c(e,t),r={type:DE(t),value:FE(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function NE(e,t,n,r){const s=H()?.getOptions().normalizeDepth,o=UE(t),a={__serialized__:Jf(t,s)};if(o)return{exception:{values:[lo(e,o)]},extra:a};const c={exception:{values:[{type:to(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:HE(t,{isUnhandledRejection:r})}]},extra:a};if(n){const u=$c(e,n);u.length&&(c.exception.values[0].stacktrace={frames:u})}return c}function Wo(e,t){return{exception:{values:[lo(e,t)]}}}function $c(e,t){const n=t.stacktrace||t.stack||"",r=LE(t),i=PE(t);try{return e(n,r,i)}catch{}return[]}const OE=/Minified React error #\d+;/i;function LE(e){return e&&OE.test(e.message)?1:0}function PE(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function op(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function DE(e){const t=e?.name;return!t&&op(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function FE(e){const t=e?.message;return op(e)?Array.isArray(e.message)&&e.message.length==2?e.message[1]:"wasm exception":t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function ap(e,t,n,r){const i=n?.syntheticException||void 0,s=Wc(e,t,i,r);return sn(s),s.level="error",n?.event_id&&(s.event_id=n.event_id),zt(s)}function cp(e,t,n="info",r,i){const s=r?.syntheticException||void 0,o=Ua(e,t,s,i);return o.level=n,r?.event_id&&(o.event_id=r.event_id),zt(o)}function Wc(e,t,n,r,i){let s;if(Sf(t)&&t.error)return Wo(e,t.error);if(Iu(t)||Xg(t)){const o=t;if("stack"in t)s=Wo(e,t);else{const a=o.name||(Iu(o)?"DOMError":"DOMException"),c=o.message?`${a}: ${o.message}`:a;s=Ua(e,c,n,r),ba(s,c)}return"code"in o&&(s.tags={...s.tags,"DOMException.code":`${o.code}`}),s}return nn(t)?Wo(e,t):Ut(t)||to(t)?(s=NE(e,t,n,i),sn(s,{synthetic:!0}),s):(s=Ua(e,t,n,r),ba(s,`${t}`),sn(s,{synthetic:!0}),s)}function Ua(e,t,n,r){const i={};if(r&&n){const s=$c(e,n);s.length&&(i.exception={values:[{value:t,stacktrace:{frames:s}}]}),sn(i,{synthetic:!0})}if(eo(t)){const{__sentry_template_string__:s,__sentry_template_values__:o}=t;return i.logentry={message:s,params:o},i}return i.message=t,i}function HE(e,{isUnhandledRejection:t}){const n=t_(e),r=t?"promise rejection":"exception";return Sf(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:to(e)?`Event \`${BE(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function BE(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function UE(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}const $E=5e3;class up extends Qy{constructor(t){const n=WE(t),r=W.SENTRY_SDK_SOURCE||a0();Ib(n,"browser",["browser"],r),super(n);const{sendDefaultPii:i,sendClientReports:s,enableLogs:o,_experiments:a}=this._options,c=o??a?.enableLogs;W.document&&(s||c)&&W.document.addEventListener("visibilitychange",()=>{W.document.visibilityState==="hidden"&&(s&&this._flushOutcomes(),c&&ls(this))}),c&&(this.on("flush",()=>{ls(this)}),this.on("afterCaptureLog",()=>{this._logFlushIdleTimeout&&clearTimeout(this._logFlushIdleTimeout),this._logFlushIdleTimeout=setTimeout(()=>{ls(this)},$E)})),i&&(this.on("postprocessEvent",wb),this.on("beforeSendSession",Tb))}eventFromException(t,n){return ap(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return cp(this._options.stackParser,t,n,r,this._options.attachStacktrace)}_prepareEvent(t,n,r,i){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r,i)}}function WE(e){return{release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:W.SENTRY_RELEASE?.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...e}}const gr=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,K=q,GE=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Mr=(e,t,n,r)=>{let i,s;return o=>{t.value>=0&&(o||r)&&(s=t.value-(i??0),(s||i===void 0)&&(i=t.value,t.delta=s,t.rating=GE(t.value,n),e(t)))}},zE=()=>`v5-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,wi=(e=!0)=>{const t=K.performance?.getEntriesByType?.("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},Nr=()=>wi()?.activationStart??0,Or=(e,t=-1)=>{const n=wi();let r="navigate";return n&&(K.document?.prerendering||Nr()>0?r="prerender":K.document?.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:t,rating:"good",delta:0,entries:[],id:zE(),navigationType:r}},Go=new WeakMap;function Gc(e,t){return Go.get(e)||Go.set(e,new t),Go.get(e)}class Fs{constructor(){Fs.prototype.__init.call(this),Fs.prototype.__init2.call(this)}__init(){this._sessionValue=0}__init2(){this._sessionEntries=[]}_processEntry(t){if(t.hadRecentInput)return;const n=this._sessionEntries[0],r=this._sessionEntries[this._sessionEntries.length-1];this._sessionValue&&n&&r&&t.startTime-r.startTime<1e3&&t.startTime-n.startTime<5e3?(this._sessionValue+=t.value,this._sessionEntries.push(t)):(this._sessionValue=t.value,this._sessionEntries=[t]),this._onAfterProcessingUnexpectedShift?.(t)}}const $n=(e,t,n={})=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver(i=>{Promise.resolve().then(()=>{t(i.getEntries())})});return r.observe({type:e,buffered:!0,...n}),r}}catch{}},fo=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let Jr=-1;const jE=()=>K.document?.visibilityState==="hidden"&&!K.document?.prerendering?0:1/0,Hs=e=>{K.document.visibilityState==="hidden"&&Jr>-1&&(Jr=e.type==="visibilitychange"?e.timeStamp:0,VE())},qE=()=>{addEventListener("visibilitychange",Hs,!0),addEventListener("prerenderingchange",Hs,!0)},VE=()=>{removeEventListener("visibilitychange",Hs,!0),removeEventListener("prerenderingchange",Hs,!0)},ho=()=>{if(K.document&&Jr<0){const e=Nr();Jr=(K.document.prerendering?void 0:globalThis.performance.getEntriesByType("visibility-state").filter(n=>n.name==="hidden"&&n.startTime>e)[0]?.startTime)??jE(),qE()}return{get firstHiddenTime(){return Jr}}},Ti=e=>{K.document?.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},XE=[1800,3e3],YE=(e,t={})=>{Ti(()=>{const n=ho(),r=Or("FCP");let i;const o=$n("paint",a=>{for(const c of a)c.name==="first-contentful-paint"&&(o.disconnect(),c.startTime<n.firstHiddenTime&&(r.value=Math.max(c.startTime-Nr(),0),r.entries.push(c),i(!0)))});o&&(i=Mr(e,r,XE,t.reportAllChanges))})},JE=[.1,.25],KE=(e,t={})=>{YE(fo(()=>{const n=Or("CLS",0);let r;const i=Gc(t,Fs),s=a=>{for(const c of a)i._processEntry(c);i._sessionValue>n.value&&(n.value=i._sessionValue,n.entries=i._sessionEntries,r())},o=$n("layout-shift",s);o&&(r=Mr(e,n,JE,t.reportAllChanges),K.document?.addEventListener("visibilitychange",()=>{K.document?.visibilityState==="hidden"&&(s(o.takeRecords()),r(!0))}),K?.setTimeout?.(r))}))},po=e=>{const t=n=>{(n.type==="pagehide"||K.document?.visibilityState==="hidden")&&e(n)};K.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},ZE=[100,300],QE=(e,t={})=>{Ti(()=>{const n=ho(),r=Or("FID");let i;const s=c=>{c.startTime<n.firstHiddenTime&&(r.value=c.processingStart-c.startTime,r.entries.push(c),i(!0))},o=c=>{c.forEach(s)},a=$n("first-input",o);i=Mr(e,r,ZE,t.reportAllChanges),a&&po(fo(()=>{o(a.takeRecords()),a.disconnect()}))})};let lp=0,zo=1/0,$i=0;const ev=e=>{e.forEach(t=>{t.interactionId&&(zo=Math.min(zo,t.interactionId),$i=Math.max($i,t.interactionId),lp=$i?($i-zo)/7+1:0)})};let $a;const dp=()=>$a?lp:performance.interactionCount||0,tv=()=>{"interactionCount"in performance||$a||($a=$n("event",ev,{type:"event",buffered:!0,durationThreshold:0}))},jo=10;let fp=0;const nv=()=>dp()-fp;class Bs{constructor(){Bs.prototype.__init.call(this),Bs.prototype.__init2.call(this)}__init(){this._longestInteractionList=[]}__init2(){this._longestInteractionMap=new Map}_resetInteractions(){fp=dp(),this._longestInteractionList.length=0,this._longestInteractionMap.clear()}_estimateP98LongestInteraction(){const t=Math.min(this._longestInteractionList.length-1,Math.floor(nv()/50));return this._longestInteractionList[t]}_processEntry(t){if(this._onBeforeProcessingEntry?.(t),!(t.interactionId||t.entryType==="first-input"))return;const n=this._longestInteractionList.at(-1);let r=this._longestInteractionMap.get(t.interactionId);if(r||this._longestInteractionList.length<jo||t.duration>n._latency){if(r?t.duration>r._latency?(r.entries=[t],r._latency=t.duration):t.duration===r._latency&&t.startTime===r.entries[0].startTime&&r.entries.push(t):(r={id:t.interactionId,entries:[t],_latency:t.duration},this._longestInteractionMap.set(r.id,r),this._longestInteractionList.push(r)),this._longestInteractionList.sort((i,s)=>s._latency-i._latency),this._longestInteractionList.length>jo){const i=this._longestInteractionList.splice(jo);for(const s of i)this._longestInteractionMap.delete(s.id)}this._onAfterProcessingINPCandidate?.(r)}}}const hp=e=>{const t=K.requestIdleCallback||K.setTimeout;K.document?.visibilityState==="hidden"?e():(e=fo(e),t(e),po(e))},rv=[200,500],iv=40,sv=(e,t={})=>{globalThis.PerformanceEventTiming&&"interactionId"in PerformanceEventTiming.prototype&&Ti(()=>{tv();const n=Or("INP");let r;const i=Gc(t,Bs),s=a=>{hp(()=>{for(const u of a)i._processEntry(u);const c=i._estimateP98LongestInteraction();c&&c._latency!==n.value&&(n.value=c._latency,n.entries=c.entries,r())})},o=$n("event",s,{durationThreshold:t.durationThreshold??iv});r=Mr(e,n,rv,t.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),po(()=>{s(o.takeRecords()),r(!0)}))})};class ov{_processEntry(t){this._onBeforeProcessingEntry?.(t)}}const av=[2500,4e3],cv=(e,t={})=>{Ti(()=>{const n=ho(),r=Or("LCP");let i;const s=Gc(t,ov),o=c=>{t.reportAllChanges||(c=c.slice(-1));for(const u of c)s._processEntry(u),u.startTime<n.firstHiddenTime&&(r.value=Math.max(u.startTime-Nr(),0),r.entries=[u],i())},a=$n("largest-contentful-paint",o);if(a){i=Mr(e,r,av,t.reportAllChanges);const c=fo(()=>{o(a.takeRecords()),a.disconnect(),i(!0)});for(const u of["keydown","click","visibilitychange"])K.document&&addEventListener(u,()=>hp(c),{capture:!0,once:!0})}})},uv=[800,1800],Wa=e=>{K.document?.prerendering?Ti(()=>Wa(e)):K.document?.readyState!=="complete"?addEventListener("load",()=>Wa(e),!0):setTimeout(e)},lv=(e,t={})=>{const n=Or("TTFB"),r=Mr(e,n,uv,t.reportAllChanges);Wa(()=>{const i=wi();i&&(n.value=Math.max(i.responseStart-Nr(),0),n.entries=[i],r(!0))})},Kr={},Us={};let pp,mp,gp,_p,yp;function zc(e,t=!1){return Ii("cls",e,fv,pp,t)}function jc(e,t=!1){return Ii("lcp",e,pv,gp,t)}function bp(e){return Ii("fid",e,hv,mp)}function dv(e){return Ii("ttfb",e,mv,_p)}function Sp(e){return Ii("inp",e,gv,yp)}function On(e,t){return Ep(e,t),Us[e]||(_v(e),Us[e]=!0),vp(e,t)}function Lr(e,t){const n=Kr[e];if(n?.length)for(const r of n)try{r(t)}catch(i){gr&&y.error(`Error while triggering instrumentation handler.
489
+ Type: ${e}
490
+ Name: ${Bt(r)}
491
+ Error:`,i)}}function fv(){return KE(e=>{Lr("cls",{metric:e}),pp=e},{reportAllChanges:!0})}function hv(){return QE(e=>{Lr("fid",{metric:e}),mp=e})}function pv(){return cv(e=>{Lr("lcp",{metric:e}),gp=e},{reportAllChanges:!0})}function mv(){return lv(e=>{Lr("ttfb",{metric:e}),_p=e})}function gv(){return sv(e=>{Lr("inp",{metric:e}),yp=e})}function Ii(e,t,n,r,i=!1){Ep(e,t);let s;return Us[e]||(s=n(),Us[e]=!0),r&&t({metric:r}),vp(e,t,i?s:void 0)}function _v(e){const t={};e==="event"&&(t.durationThreshold=0),$n(e,n=>{Lr(e,{entries:n})},t)}function Ep(e,t){Kr[e]=Kr[e]||[],Kr[e].push(t)}function vp(e,t,n){return()=>{n&&n();const r=Kr[e];if(!r)return;const i=r.indexOf(t);i!==-1&&r.splice(i,1)}}function yv(e){return"duration"in e}function qo(e){return typeof e=="number"&&isFinite(e)}function qt(e,t,n,{...r}){const i=Z(e).start_timestamp;return i&&i>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),_i(e,()=>{const s=Bn({startTime:t,...r});return s&&s.end(n),s})}function qc(e){const t=H();if(!t)return;const{name:n,transaction:r,attributes:i,startTime:s}=e,{release:o,environment:a,sendDefaultPii:c}=t.getOptions(),d=t.getIntegrationByName("Replay")?.getReplayId(),l=Q(),f=l.getUser(),h=f!==void 0?f.email||f.id||f.ip_address:void 0;let p;try{p=l.getScopeData().contexts.profile.profile_id}catch{}const m={release:o,environment:a,user:h||void 0,profile_id:p||void 0,replay_id:d||void 0,transaction:r,"user_agent.original":K.navigator?.userAgent,"client.address":c?"{{auto}}":void 0,...i};return Bn({name:n,attributes:m,startTime:s,experimental:{standalone:!0}})}function mo(){return K.addEventListener&&K.performance}function ye(e){return e/1e3}function wp(e){let t="unknown",n="unknown",r="";for(const i of e){if(i==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(i))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=i}return r===e&&(t=r),{name:t,version:n}}function Tp(e){try{return PerformanceObserver.supportedEntryTypes.includes(e)}catch{return!1}}function Ip(e,t){let n,r=!1;function i(a){!r&&n&&t(a,n),r=!0}po(()=>{i("pagehide")});const s=e.on("beforeStartNavigationSpan",(a,c)=>{c?.isRedirect||(i("navigation"),s?.(),o?.())}),o=e.on("afterStartPageLoadSpan",a=>{n=a.spanContext().spanId,o?.()})}function bv(e){let t=0,n;if(!Tp("layout-shift"))return;const r=zc(({metric:i})=>{const s=i.entries[i.entries.length-1];s&&(t=i.value,n=s)},!0);Ip(e,(i,s)=>{Sv(t,n,s,i),r()})}function Sv(e,t,n,r){gr&&y.log(`Sending CLS span (${e})`);const i=ye((Be()||0)+(t?.startTime||0)),s=Q().getScopeData().transactionName,o=t?st(t.sources[0]?.node):"Layout shift",a={[Se]:"auto.http.browser.cls",[rt]:"ui.webvital.cls",[Rr]:t?.duration||0,"sentry.pageload.span_id":n,"sentry.report_event":r};t?.sources&&t.sources.forEach((u,d)=>{a[`cls.source.${d+1}`]=st(u.node)});const c=qc({name:o,transaction:s,attributes:a,startTime:i});c&&(c.addEvent("cls",{[mi]:"",[gi]:e}),c.end(i))}function Ev(e){let t=0,n;if(!Tp("largest-contentful-paint"))return;const r=jc(({metric:i})=>{const s=i.entries[i.entries.length-1];s&&(t=i.value,n=s)},!0);Ip(e,(i,s)=>{vv(t,n,s,i),r()})}function vv(e,t,n,r){gr&&y.log(`Sending LCP span (${e})`);const i=ye((Be()||0)+(t?.startTime||0)),s=Q().getScopeData().transactionName,o=t?st(t.element):"Largest contentful paint",a={[Se]:"auto.http.browser.lcp",[rt]:"ui.webvital.lcp",[Rr]:0,"sentry.pageload.span_id":n,"sentry.report_event":r};t&&(t.element&&(a["lcp.element"]=st(t.element)),t.id&&(a["lcp.id"]=t.id),t.url&&(a["lcp.url"]=t.url.trim().slice(0,200)),t.loadTime!=null&&(a["lcp.loadTime"]=t.loadTime),t.renderTime!=null&&(a["lcp.renderTime"]=t.renderTime),t.size!=null&&(a["lcp.size"]=t.size));const c=qc({name:o,transaction:s,attributes:a,startTime:i});c&&(c.addEvent("lcp",{[mi]:"millisecond",[gi]:e}),c.end(i))}const wv=2147483647;let Al=0,He={},qe,$s;function Tv({recordClsStandaloneSpans:e,recordLcpStandaloneSpans:t,client:n}){const r=mo();if(r&&Be()){r.mark&&K.performance.mark("sentry-tracing-init");const i=Av(),s=t?Ev(n):Rv(),o=Mv(),a=e?bv(n):Cv();return()=>{i(),s?.(),o(),a?.()}}return()=>{}}function Iv(){On("longtask",({entries:e})=>{const t=Pe();if(!t)return;const{op:n,start_timestamp:r}=Z(t);for(const i of e){const s=ye(Be()+i.startTime),o=ye(i.duration);n==="navigation"&&r&&s<r||qt(t,s,s+o,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[Se]:"auto.ui.browser.metrics"}})}})}function xv(){new PerformanceObserver(t=>{const n=Pe();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const i=ye(Be()+r.startTime),{start_timestamp:s,op:o}=Z(n);if(o==="navigation"&&s&&i<s)continue;const a=ye(r.duration),c={[Se]:"auto.ui.browser.metrics"},u=r.scripts[0],{invoker:d,invokerType:l,sourceURL:f,sourceFunctionName:h,sourceCharPosition:p}=u;c["browser.script.invoker"]=d,c["browser.script.invoker_type"]=l,f&&(c["code.filepath"]=f),h&&(c["code.function"]=h),p!==-1&&(c["browser.script.source_char_position"]=p),qt(n,i,i+a,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:c})}}).observe({type:"long-animation-frame",buffered:!0})}function kv(){On("event",({entries:e})=>{const t=Pe();if(t){for(const n of e)if(n.name==="click"){const r=ye(Be()+n.startTime),i=ye(n.duration),s={name:st(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[Se]:"auto.ui.browser.metrics"}},o=wf(n.target);o&&(s.attributes["ui.component_name"]=o),qt(t,r,r+i,s)}}})}function Cv(){return zc(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(He.cls={value:e.value,unit:""},$s=t)},!0)}function Rv(){return jc(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(He.lcp={value:e.value,unit:"millisecond"},qe=t)},!0)}function Av(){return bp(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const n=ye(Be()),r=ye(t.startTime);He.fid={value:e.value,unit:"millisecond"},He["mark.fid"]={value:n+r,unit:"second"}})}function Mv(){return dv(({metric:e})=>{e.entries[e.entries.length-1]&&(He.ttfb={value:e.value,unit:"millisecond"})})}function Nv(e,t){const n=mo(),r=Be();if(!n?.getEntries||!r)return;const i=ye(r),s=n.getEntries(),{op:o,start_timestamp:a}=Z(e);if(s.slice(Al).forEach(c=>{const u=ye(c.startTime),d=ye(Math.max(0,c.duration));if(!(o==="navigation"&&a&&i+u<a))switch(c.entryType){case"navigation":{Pv(e,c,i);break}case"mark":case"paint":case"measure":{Ov(e,c,u,d,i,t.ignorePerformanceApiSpans);const l=ho(),f=c.startTime<l.firstHiddenTime;c.name==="first-paint"&&f&&(He.fp={value:c.startTime,unit:"millisecond"}),c.name==="first-contentful-paint"&&f&&(He.fcp={value:c.startTime,unit:"millisecond"});break}case"resource":{Hv(e,c,c.name,u,d,i,t.ignoreResourceSpans);break}}}),Al=Math.max(s.length-1,0),Bv(e),o==="pageload"){$v(He);const c=He["mark.fid"];c&&He.fid&&(qt(e,c.value,c.value+ye(He.fid.value),{name:"first input delay",op:"ui.action",attributes:{[Se]:"auto.ui.browser.metrics"}}),delete He["mark.fid"]),t.recordClsOnPageloadSpan||delete He.cls,t.recordLcpOnPageloadSpan||delete He.lcp,Object.entries(He).forEach(([u,d])=>{Zf(u,d.value,d.unit)}),e.setAttribute("performance.timeOrigin",i),e.setAttribute("performance.activationStart",Nr()),Uv(e,t)}qe=void 0,$s=void 0,He={}}function Ov(e,t,n,r,i,s){if(["mark","measure"].includes(t.entryType)&&pt(t.name,s))return;const o=wi(!1),a=ye(o?o.requestStart:0),c=i+Math.max(n,a),u=i+n,d=u+r,l={[Se]:"auto.resource.browser.metrics"};c!==u&&(l["sentry.browser.measure_happened_before_request"]=!0,l["sentry.browser.measure_start_time"]=c),Lv(l,t),c<=d&&qt(e,c,d,{name:t.name,op:t.entryType,attributes:l})}function Lv(e,t){try{const n=t.detail;if(!n)return;if(typeof n=="object"){for(const[r,i]of Object.entries(n))if(i&&or(i))e[`sentry.browser.measure.detail.${r}`]=i;else if(i!==void 0)try{e[`sentry.browser.measure.detail.${r}`]=JSON.stringify(i)}catch{}return}if(or(n)){e["sentry.browser.measure.detail"]=n;return}try{e["sentry.browser.measure.detail"]=JSON.stringify(n)}catch{}}catch{}}function Pv(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{Wi(e,t,r,n)}),Wi(e,t,"secureConnection",n,"TLS/SSL"),Wi(e,t,"fetch",n,"cache"),Wi(e,t,"domainLookup",n,"DNS"),Fv(e,t,n)}function Wi(e,t,n,r,i=n){const s=Dv(n),o=t[s],a=t[`${n}Start`];!a||!o||qt(e,r+ye(a),r+ye(o),{op:`browser.${i}`,name:t.name,attributes:{[Se]:"auto.ui.browser.metrics",...n==="redirect"&&t.redirectCount!=null?{"http.redirect_count":t.redirectCount}:{}}})}function Dv(e){return e==="secureConnection"?"connectEnd":e==="fetch"?"domainLookupStart":`${e}End`}function Fv(e,t,n){const r=n+ye(t.requestStart),i=n+ye(t.responseEnd),s=n+ye(t.responseStart);t.responseEnd&&(qt(e,r,i,{op:"browser.request",name:t.name,attributes:{[Se]:"auto.ui.browser.metrics"}}),qt(e,s,i,{op:"browser.response",name:t.name,attributes:{[Se]:"auto.ui.browser.metrics"}}))}function Hv(e,t,n,r,i,s,o){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const a=t.initiatorType?`resource.${t.initiatorType}`:"resource.other";if(o?.includes(a))return;const c=Cn(n),u={[Se]:"auto.resource.browser.metrics"};Vo(u,t,"transferSize","http.response_transfer_size"),Vo(u,t,"encodedBodySize","http.response_content_length"),Vo(u,t,"decodedBodySize","http.decoded_response_content_length");const d=t.deliveryType;d!=null&&(u["http.response_delivery_type"]=d);const l=t.renderBlockingStatus;if(l&&(u["resource.render_blocking_status"]=l),c.protocol&&(u["url.scheme"]=c.protocol.split(":").pop()),c.host&&(u["server.address"]=c.host),u["url.same_origin"]=n.includes(K.location.origin),t.nextHopProtocol!=null){const{name:p,version:m}=wp(t.nextHopProtocol);u["network.protocol.name"]=p,u["network.protocol.version"]=m}const f=s+r,h=f+i;qt(e,f,h,{name:n.replace(K.location.origin,""),op:a,attributes:u})}function Bv(e){const t=K.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),qo(n.rtt)&&(He["connection.rtt"]={value:n.rtt,unit:"millisecond"})),qo(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),qo(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function Uv(e,t){qe&&t.recordLcpOnPageloadSpan&&(qe.element&&e.setAttribute("lcp.element",st(qe.element)),qe.id&&e.setAttribute("lcp.id",qe.id),qe.url&&e.setAttribute("lcp.url",qe.url.trim().slice(0,200)),qe.loadTime!=null&&e.setAttribute("lcp.loadTime",qe.loadTime),qe.renderTime!=null&&e.setAttribute("lcp.renderTime",qe.renderTime),e.setAttribute("lcp.size",qe.size)),$s?.sources&&t.recordClsOnPageloadSpan&&$s.sources.forEach((n,r)=>e.setAttribute(`cls.source.${r+1}`,st(n.node)))}function Vo(e,t,n,r){const i=t[n];i!=null&&i<wv&&(e[r]=i)}function $v(e){const t=wi(!1);if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}function Wv(){return mo()&&Be()?On("element",Gv):()=>{}}const Gv=({entries:e})=>{const t=Pe(),n=t?Oe(t):void 0,r=n?Z(n).description:Q().getScopeData().transactionName;e.forEach(i=>{const s=i;if(!s.identifier)return;const o=s.name,a=s.renderTime,c=s.loadTime,[u,d]=c?[ye(c),"load-time"]:a?[ye(a),"render-time"]:[xe(),"entry-emission"],l=o==="image-paint"?ye(Math.max(0,(a??0)-(c??0))):0,f={[Se]:"auto.ui.browser.elementtiming",[rt]:"ui.elementtiming",[tt]:"component","sentry.span_start_time_source":d,"sentry.transaction_name":r,"element.id":s.id,"element.type":s.element?.tagName?.toLowerCase()||"unknown","element.size":s.naturalWidth&&s.naturalHeight?`${s.naturalWidth}x${s.naturalHeight}`:void 0,"element.render_time":a,"element.load_time":c,"element.url":s.url||void 0,"element.identifier":s.identifier,"element.paint_type":o};oo({name:`element[${s.identifier}]`,attributes:f,startTime:u,onlyIfParent:!0},h=>{h.end(u+l)})})},zv=1e3;let Ml,Ga,za;function xp(e){const t="dom";ln(t,e),dn(t,jv)}function jv(){if(!K.document)return;const e=it.bind(null,"dom"),t=Nl(e,!0);K.document.addEventListener("click",t,!1),K.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const i=K[n]?.prototype;i?.hasOwnProperty?.("addEventListener")&&(ze(i,"addEventListener",function(s){return function(o,a,c){if(o==="click"||o=="keypress")try{const u=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},d=u[o]=u[o]||{refCount:0};if(!d.handler){const l=Nl(e);d.handler=l,s.call(this,o,l,c)}d.refCount++}catch{}return s.call(this,o,a,c)}}),ze(i,"removeEventListener",function(s){return function(o,a,c){if(o==="click"||o=="keypress")try{const u=this.__sentry_instrumentation_handlers__||{},d=u[o];d&&(d.refCount--,d.refCount<=0&&(s.call(this,o,d.handler,c),d.handler=void 0,delete u[o]),Object.keys(u).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return s.call(this,o,a,c)}}))})}function qv(e){if(e.type!==Ga)return!1;try{if(!e.target||e.target._sentryId!==za)return!1}catch{}return!0}function Vv(e,t){return e!=="keypress"?!1:t?.tagName?!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable):!0}function Nl(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=Xv(n);if(Vv(n.type,r))return;Ye(n,"_sentryCaptured",!0),r&&!r._sentryId&&Ye(r,"_sentryId",je());const i=n.type==="keypress"?"input":n.type;qv(n)||(e({event:n,name:i,global:t}),Ga=n.type,za=r?r._sentryId:void 0),clearTimeout(Ml),Ml=K.setTimeout(()=>{za=void 0,Ga=void 0},zv)}}function Xv(e){try{return e.target}catch{return null}}let Gi;function go(e){const t="history";ln(t,e),dn(t,Yv)}function Yv(){if(K.addEventListener("popstate",()=>{const t=K.location.href,n=Gi;if(Gi=t,n===t)return;it("history",{from:n,to:t})}),!ZS())return;function e(t){return function(...n){const r=n.length>2?n[2]:void 0;if(r){const i=Gi,s=Jv(String(r));if(Gi=s,i===s)return t.apply(this,n);it("history",{from:i,to:s})}return t.apply(this,n)}}ze(K.history,"pushState",e),ze(K.history,"replaceState",e)}function Jv(e){try{return new URL(e,K.location.origin).toString()}catch{return e}}const gs={};function Vc(e){const t=gs[e];if(t)return t;let n=K[e];if(Na(n))return gs[e]=n.bind(K);const r=K.document;if(r&&typeof r.createElement=="function")try{const i=r.createElement("iframe");i.hidden=!0,r.head.appendChild(i);const s=i.contentWindow;s?.[e]&&(n=s[e]),r.head.removeChild(i)}catch(i){gr&&y.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,i)}return n&&(gs[e]=n.bind(K))}function Ol(e){gs[e]=void 0}function xi(...e){return Vc("setTimeout")(...e)}const Lt="__sentry_xhr_v3__";function Xc(e){const t="xhr";ln(t,e),dn(t,Kv)}function Kv(){if(!K.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const i=new Error,s=xe()*1e3,o=ht(r[0])?r[0].toUpperCase():void 0,a=Zv(r[1]);if(!o||!a)return t.apply(n,r);n[Lt]={method:o,url:a,request_headers:{}},o==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const u=n[Lt];if(u&&n.readyState===4){try{u.status_code=n.status}catch{}const d={endTimestamp:xe()*1e3,startTimestamp:s,xhr:n,virtualError:i};it("xhr",d)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(u,d,l){return c(),u.apply(d,l)}}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(u,d,l){const[f,h]=l,p=d[Lt];return p&&ht(f)&&ht(h)&&(p.request_headers[f.toLowerCase()]=h),u.apply(d,l)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const i=n[Lt];if(!i)return t.apply(n,r);r[0]!==void 0&&(i.body=r[0]);const s={startTimestamp:xe()*1e3,xhr:n};return it("xhr",s),t.apply(n,r)}})}function Zv(e){if(ht(e))return e;try{return e.toString()}catch{}}function kp(e){return new URLSearchParams(e).toString()}function Ws(e,t=y){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[kp(e)];if(!e)return[void 0]}catch(n){return gr&&t.error(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return gr&&t.log("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function Yc(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}const Xo=[],_s=new Map,Qv=60;function ew(){if(mo()&&Be()){const t=tw();return()=>{t()}}return()=>{}}const Ll={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function tw(){return Sp(nw)}const nw=({metric:e})=>{if(e.value==null)return;const t=ye(e.value);if(t>Qv)return;const n=e.entries.find(p=>p.duration===e.value&&Ll[p.name]);if(!n)return;const{interactionId:r}=n,i=Ll[n.name],s=ye(Be()+n.startTime),o=Pe(),a=o?Oe(o):void 0,u=(r!=null?_s.get(r):void 0)||a,d=u?Z(u).description:Q().getScopeData().transactionName,l=st(n.target),f={[Se]:"auto.http.browser.inp",[rt]:`ui.interaction.${i}`,[Rr]:n.duration},h=qc({name:l,transaction:d,attributes:f,startTime:s});h&&(h.addEvent("inp",{[mi]:"millisecond",[gi]:e.value}),h.end(s+t))};function rw(){const e=({entries:t})=>{const n=Pe(),r=n&&Oe(n);t.forEach(i=>{if(!yv(i)||!r)return;const s=i.interactionId;if(s!=null&&!_s.has(s)){if(Xo.length>10){const o=Xo.shift();_s.delete(o)}Xo.push(s),_s.set(s,r)}})};On("event",e),On("first-input",e)}function Jc(e,t=Vc("fetch")){let n=0,r=0;function i(s){const o=s.body.length;n+=o,r++;const a={body:s.body,method:"POST",referrerPolicy:"strict-origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return Ol("fetch"),Ns("No fetch implementation available");try{return t(e.url,a).then(c=>(n-=o,r--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return Ol("fetch"),n-=o,r--,Ns(c)}}return vh(e,i)}const iw=10,sw=20,ow=30,aw=40,cw=50;function _r(e,t,n,r){const i={filename:e,function:t==="<anonymous>"?kt:t,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}const uw=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,lw=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,dw=/\((\S*)(?::(\d+))(?::(\d+))\)/,fw=e=>{const t=uw.exec(e);if(t){const[,r,i,s]=t;return _r(r,kt,+i,+s)}const n=lw.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const o=dw.exec(n[2]);o&&(n[2]=o[1],n[3]=o[2],n[4]=o[3])}const[i,s]=Np(n[1]||kt,n[2]);return _r(s,i,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},Cp=[ow,fw],hw=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,pw=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,mw=e=>{const t=hw.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const s=pw.exec(t[3]);s&&(t[1]=t[1]||"eval",t[3]=s[1],t[4]=s[2],t[5]="")}let r=t[3],i=t[1]||kt;return[i,r]=Np(i,r),_r(r,i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},Rp=[cw,mw],gw=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,_w=e=>{const t=gw.exec(e);return t?_r(t[2],t[1]||kt,+t[3],t[4]?+t[4]:void 0):void 0},yw=[aw,_w],bw=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,Sw=e=>{const t=bw.exec(e);return t?_r(t[2],t[3]||kt,+t[1]):void 0},Ew=[iw,Sw],vw=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,ww=e=>{const t=vw.exec(e);return t?_r(t[5],t[3]||t[4]||kt,+t[1],+t[2]):void 0},Tw=[sw,ww],Ap=[Cp,Rp],Mp=gf(...Ap),Np=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:kt,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]};function Iw(e,{metadata:t,tunnel:n,dsn:r}){const i={event_id:e.event_id,sent_at:new Date().toISOString(),...t?.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:Hn(r)}},s=xw(e);return Xt(i,[s])}function xw(e){return[{type:"user_report"},e]}const ne=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,zi=1024,kw="Breadcrumbs",Cw=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:kw,setup(n){t.console&&Nc(Mw(n)),t.dom&&xp(Aw(n,t.dom)),t.xhr&&Xc(Nw(n)),t.fetch&&Lc(Ow(n)),t.history&&go(Lw(n)),t.sentry&&n.on("beforeSendEvent",Rw(n))}}},Op=Cw;function Rw(e){return function(n){H()===e&&Ct({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:bn(n)},{event:n})}}function Aw(e,t){return function(r){if(H()!==e)return;let i,s,o=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>zi&&(ne&&y.warn(`\`dom.maxStringLength\` cannot exceed ${zi}, but a value of ${a} was configured. Sentry will use ${zi} instead.`),a=zi),typeof o=="string"&&(o=[o]);try{const u=r.event,d=Pw(u)?u.target:u;i=st(d,{keyAttrs:o,maxStringLength:a}),s=wf(d)}catch{i="<unknown>"}if(i.length===0)return;const c={category:`ui.${r.name}`,message:i};s&&(c.data={"ui.component_name":s}),Ct(c,{event:r.event,name:r.name,global:r.global})}}function Mw(e){return function(n){if(H()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:Oc(n.level),message:xs(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${xs(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Ct(r,{input:n.args,level:n.level})}}function Nw(e){return function(n){if(H()!==e)return;const{startTimestamp:r,endTimestamp:i}=n,s=n.xhr[Lt];if(!r||!i||!s)return;const{method:o,url:a,status_code:c,body:u}=s,d={method:o,url:a,status_code:c},l={xhr:n.xhr,input:u,startTimestamp:r,endTimestamp:i},f={category:"xhr",data:d,type:"http",level:$h(c)};e.emit("beforeOutgoingRequestBreadcrumb",f,l),Ct(f,l)}}function Ow(e){return function(n){if(H()!==e)return;const{startTimestamp:r,endTimestamp:i}=n;if(i&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.fetchData.method,n.fetchData.url,n.error){const s=n.fetchData,o={data:n.error,input:n.args,startTimestamp:r,endTimestamp:i},a={category:"fetch",data:s,level:"error",type:"http"};e.emit("beforeOutgoingRequestBreadcrumb",a,o),Ct(a,o)}else{const s=n.response,o={...n.fetchData,status_code:s?.status};n.fetchData.request_body_size,n.fetchData.response_body_size,s?.status;const a={input:n.args,response:s,startTimestamp:r,endTimestamp:i},c={category:"fetch",data:o,type:"http",level:$h(o.status_code)};e.emit("beforeOutgoingRequestBreadcrumb",c,a),Ct(c,a)}}}function Lw(e){return function(n){if(H()!==e)return;let r=n.from,i=n.to;const s=Cn(W.location.href);let o=r?Cn(r):void 0;const a=Cn(i);o?.path||(o=s),s.protocol===a.protocol&&s.host===a.host&&(i=a.relative),s.protocol===o.protocol&&s.host===o.host&&(r=o.relative),Ct({category:"navigation",data:{from:r,to:i}})}}function Pw(e){return!!e&&!!e.target}const Dw=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],Fw="BrowserApiErrors",Hw=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...e};return{name:Fw,setupOnce(){t.setTimeout&&ze(W,"setTimeout",Pl),t.setInterval&&ze(W,"setInterval",Pl),t.requestAnimationFrame&&ze(W,"requestAnimationFrame",Bw),t.XMLHttpRequest&&"XMLHttpRequest"in W&&ze(XMLHttpRequest.prototype,"send",Uw);const n=t.eventTarget;n&&(Array.isArray(n)?n:Dw).forEach(i=>$w(i,t))}}},Lp=Hw;function Pl(e){return function(...t){const n=t[0];return t[0]=mr(n,{mechanism:{data:{function:Bt(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function Bw(e){return function(t){return e.apply(this,[mr(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Bt(e)},handled:!1,type:"instrument"}})])}}function Uw(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in n&&typeof n[i]=="function"&&ze(n,i,function(s){const o={mechanism:{data:{function:i,handler:Bt(s)},handled:!1,type:"instrument"}},a=bc(s);return a&&(o.mechanism.data.handler=Bt(a)),mr(s,o)})}),e.apply(this,t)}}function $w(e,t){const r=W[e]?.prototype;r?.hasOwnProperty?.("addEventListener")&&(ze(r,"addEventListener",function(i){return function(s,o,a){try{Ww(o)&&(o.handleEvent=mr(o.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Bt(o),target:e},handled:!1,type:"instrument"}}))}catch{}return t.unregisterOriginalCallbacks&&Gw(this,s,o),i.apply(this,[s,mr(o,{mechanism:{data:{function:"addEventListener",handler:Bt(o),target:e},handled:!1,type:"instrument"}}),a])}}),ze(r,"removeEventListener",function(i){return function(s,o,a){try{const c=o.__sentry_wrapped__;c&&i.call(this,s,c,a)}catch{}return i.call(this,s,o,a)}}))}function Ww(e){return typeof e.handleEvent=="function"}function Gw(e,t,n){e&&typeof e=="object"&&"removeEventListener"in e&&typeof e.removeEventListener=="function"&&e.removeEventListener(t,n)}const Pp=()=>({name:"BrowserSession",setupOnce(){if(typeof W.document>"u"){ne&&y.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}xa({ignoreDuration:!0}),ka(),go(({from:e,to:t})=>{e!==void 0&&e!==t&&(xa({ignoreDuration:!0}),ka())})}}),zw="GlobalHandlers",jw=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:zw,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(qw(n),Dl("onerror")),t.onunhandledrejection&&(Vw(n),Dl("onunhandledrejection"))}}},Dp=jw;function qw(e){_f(t=>{const{stackParser:n,attachStacktrace:r}=Fp();if(H()!==e||ip())return;const{msg:i,url:s,line:o,column:a,error:c}=t,u=Jw(Wc(n,c||i,void 0,r,!1),s,o,a);u.level="error",bi(u,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function Vw(e){yf(t=>{const{stackParser:n,attachStacktrace:r}=Fp();if(H()!==e||ip())return;const i=Xw(t),s=or(i)?Yw(i):Wc(n,i,void 0,r,!0);s.level="error",bi(s,{originalException:i,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function Xw(e){if(or(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function Yw(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Jw(e,t,n,r){const i=e.exception=e.exception||{},s=i.values=i.values||[],o=s[0]=s[0]||{},a=o.stacktrace=o.stacktrace||{},c=a.frames=a.frames||[],u=r,d=n,l=ht(t)&&t.length>0?t:Pn();return c.length===0&&c.push({colno:u,filename:l,function:kt,in_app:!0,lineno:d}),e}function Dl(e){ne&&y.log(`Global Handler attached: ${e}`)}function Fp(){return H()?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Hp=()=>({name:"HttpContext",preprocessEvent(e){if(!W.navigator&&!W.location&&!W.document)return;const t=Uc(),n={...t.headers,...e.request?.headers};e.request={...t,...e.request,headers:n}}}),Kw="cause",Zw=5,Qw="LinkedErrors",eT=(e={})=>{const t=e.limit||Zw,n=e.key||Kw;return{name:Qw,preprocessEvent(r,i,s){const o=s.getOptions();Ub(lo,o.stackParser,n,t,r,i)}}},Bp=eT;function tT(){return nT()?(ne&&un(()=>{console.error("[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}),!0):!1}function nT(){if(typeof W.window>"u")return!1;const e=W;if(e.nw||!(e.chrome||e.browser)?.runtime?.id)return!1;const n=Pn(),r=["chrome-extension","moz-extension","ms-browser-extension","safari-web-extension"];return!(W===W.top&&r.some(s=>n.startsWith(`${s}://`)))}function Up(e){return[Ch(),xh(),Lp(),Op(),Dp(),Bp(),Nh(),Hp(),Pp()]}function rT(e={}){const t=!e.skipBrowserExtensionCheck&&tT(),n={...e,enabled:t?!1:e.enabled,stackParser:zg(e.stackParser||Mp),integrations:Xy({integrations:e.integrations,defaultIntegrations:e.defaultIntegrations==null?Up():e.defaultIntegrations}),transport:e.transport||Jc};return lb(up,n)}function iT(){}function sT(e){e()}function oT(e={}){const t=W.document,n=t?.head||t?.body;if(!n){ne&&y.error("[showReportDialog] Global document not defined");return}const r=Q(),s=H()?.getDsn();if(!s){ne&&y.error("[showReportDialog] DSN not configured");return}const o={...e,user:{...r.getUser(),...e.user},eventId:e.eventId||sh()},a=W.document.createElement("script");a.async=!0,a.crossOrigin="anonymous",a.src=qy(s,o);const{onLoad:c,onClose:u}=o;if(c&&(a.onload=c),u){const d=l=>{if(l.data==="__sentry_reportdialog_closed__")try{u()}finally{W.removeEventListener("message",d)}};W.addEventListener("message",d)}n.appendChild(a)}const aT=q,cT="ReportingObserver",Fl=new WeakMap,uT=(e={})=>{const t=e.types||["crash","deprecation","intervention"];function n(r){if(Fl.has(H()))for(const i of r)ot(s=>{s.setExtra("url",i.url);const o=`ReportingObserver [${i.type}]`;let a="No details available";if(i.body){const c={};for(const u in i.body)c[u]=i.body[u];if(s.setExtra("body",c),i.type==="crash"){const u=i.body;a=[u.crashId||"",u.reason||""].join(" ").trim()||a}else a=i.body.message||a}Ls(`${o}: ${a}`)})}return{name:cT,setupOnce(){if(!e0())return;new aT.ReportingObserver(n,{buffered:!0,types:t}).observe()},setup(r){Fl.set(r,!0)}}},lT=uT,dT="HttpClient",fT=(e={})=>{const t={failedRequestStatusCodes:[[500,599]],failedRequestTargets:[/.*/],...e};return{name:dT,setup(n){ET(n,t),vT(n,t)}}},hT=fT;function pT(e,t,n,r,i){if(Wp(e,n.status,n.url)){const s=wT(t,r);let o,a,c,u;zp()&&([o,c]=Hl("Cookie",s),[a,u]=Hl("Set-Cookie",n));const d=Gp({url:s.url,method:s.method,status:n.status,requestHeaders:o,responseHeaders:a,requestCookies:c,responseCookies:u,error:i});bi(d)}}function Hl(e,t){const n=_T(t.headers);let r;try{const i=n[e]||n[e.toLowerCase()]||void 0;i&&(r=$p(i))}catch{}return[n,r]}function mT(e,t,n,r,i){if(Wp(e,t.status,t.responseURL)){let s,o,a;if(zp()){try{const u=t.getResponseHeader("Set-Cookie")||t.getResponseHeader("set-cookie")||void 0;u&&(o=$p(u))}catch{}try{a=yT(t)}catch{}s=r}const c=Gp({url:t.responseURL,method:n,status:t.status,requestHeaders:s,responseHeaders:a,responseCookies:o,error:i});bi(c)}}function gT(e){if(e){const t=e["Content-Length"]||e["content-length"];if(t)return parseInt(t,10)}}function $p(e){return e.split("; ").reduce((t,n)=>{const[r,i]=n.split("=");return r&&i&&(t[r]=i),t},{})}function _T(e){const t={};return e.forEach((n,r)=>{t[r]=n}),t}function yT(e){const t=e.getAllResponseHeaders();return t?t.split(`\r
492
+ `).reduce((n,r)=>{const[i,s]=r.split(": ");return i&&s&&(n[i]=s),n},{}):{}}function bT(e,t){return e.some(n=>typeof n=="string"?t.includes(n):n.test(t))}function ST(e,t){return e.some(n=>typeof n=="number"?n===t:t>=n[0]&&t<=n[1])}function ET(e,t){Wh()&&Lc(n=>{if(H()!==e)return;const{response:r,args:i,error:s,virtualError:o}=n,[a,c]=i;r&&pT(t,a,r,c,s||o)},!1)}function vT(e,t){"XMLHttpRequest"in q&&Xc(n=>{if(H()!==e)return;const{error:r,virtualError:i}=n,s=n.xhr,o=s[Lt];if(!o)return;const{method:a,request_headers:c}=o;try{mT(t,s,a,c,r||i)}catch(u){ne&&y.warn("Error while extracting response event form XHR response",u)}})}function Wp(e,t,n){return ST(e.failedRequestStatusCodes,t)&&bT(e.failedRequestTargets,n)&&!Th(n,H())}function Gp(e){const t=H(),n=t&&e.error&&e.error instanceof Error?e.error.stack:void 0,r=n&&t?t.getOptions().stackParser(n,0,1):void 0,i=`HTTP Client Error with status code: ${e.status}`,s={message:i,exception:{values:[{type:"Error",value:i,stacktrace:r?{frames:r}:void 0}]},request:{url:e.url,method:e.method,headers:e.requestHeaders,cookies:e.requestCookies},contexts:{response:{status_code:e.status,headers:e.responseHeaders,cookies:e.responseCookies,body_size:gT(e.responseHeaders)}}};return sn(s,{type:"http.client",handled:!1}),s}function wT(e,t){return!t&&e instanceof Request||e instanceof Request&&e.bodyUsed?e:new Request(e,t)}function zp(){const e=H();return e?!!e.getOptions().sendDefaultPii:!1}const Yo=q,TT=7,IT="ContextLines",xT=(e={})=>{const t=e.frameContextLines!=null?e.frameContextLines:TT;return{name:IT,processEvent(n){return CT(n,t)}}},kT=xT;function CT(e,t){const n=Yo.document,r=Yo.location&&Bh(Yo.location.href);if(!n||!r)return e;const i=e.exception?.values;if(!i?.length)return e;const s=n.documentElement.innerHTML;if(!s)return e;const o=["<!DOCTYPE html>","<html>",...s.split(`
493
+ `),"</html>"];return i.forEach(a=>{const c=a.stacktrace;c?.frames&&(c.frames=c.frames.map(u=>RT(u,o,r,t)))}),e}function RT(e,t,n,r){return e.filename!==n||!e.lineno||!t.length||r_(t,e,r),e}const AT="GraphQLClient",MT=e=>({name:AT,setup(t){NT(t,e),OT(t,e)}});function NT(e,t){e.on("beforeOutgoingRequestSpan",(n,r)=>{const s=Z(n).data||{};if(!(s[rt]==="http.client"))return;const c=s[b_]||s["http.url"],u=s[y_]||s["http.method"];if(!ht(c)||!ht(u))return;const{endpoints:d}=t,l=pt(c,d),f=qp(r);if(l&&f){const h=Vp(f);if(h){const p=jp(h);n.updateName(`${u} ${c} (${p})`),n.setAttribute("graphql.document",f)}}})}function OT(e,t){e.on("beforeOutgoingRequestBreadcrumb",(n,r)=>{const{category:i,type:s,data:o}=n;if(s==="http"&&(i==="fetch"||i==="xhr")){const d=o?.url,{endpoints:l}=t,f=pt(d,l),h=qp(r);if(f&&o&&h){const p=Vp(h);if(!o.graphql&&p){const m=jp(p);o["graphql.document"]=p.query,o["graphql.operation"]=m}}}})}function jp(e){const{query:t,operationName:n}=e,{operationName:r=n,operationType:i}=LT(t);return r?`${i} ${r}`:`${i}`}function qp(e){const t="xhr"in e;let n;if(t){const r=e.xhr[Lt];n=r&&Ws(r.body)[0]}else{const r=Yc(e.input);n=Ws(r)[0]}return n}function LT(e){const t=/^(?:\s*)(query|mutation|subscription)(?:\s*)(\w+)(?:\s*)[{(]/,n=/^(?:\s*)(query|mutation|subscription)(?:\s*)[{(]/,r=e.match(t);if(r)return{operationType:r[1],operationName:r[2]};const i=e.match(n);return i?{operationType:i[1],operationName:void 0}:{operationType:void 0,operationName:void 0}}function Vp(e){let t;try{const n=JSON.parse(e);!!n.query&&(t=n)}finally{return t}}const PT=MT,ge=q,Kc="sentryReplaySession",DT="replay_event",Zc="Unable to send Replay",FT=3e5,HT=9e5,BT=5e3,UT=5500,$T=6e4,WT=5e3,GT=3,Bl=15e4,ji=5e3,zT=3e3,jT=300,Qc=2e7,qT=4999,VT=15e3,Ul=36e5;var XT=Object.defineProperty,YT=(e,t,n)=>t in e?XT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$l=(e,t,n)=>YT(e,typeof t!="symbol"?t+"":t,n),Re=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(Re||{});function JT(e){return e.nodeType===e.ELEMENT_NODE}function Zr(e){return e?.host?.shadowRoot===e}function Qr(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function KT(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function ZT(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function Gs(e){try{const t=e.rules||e.cssRules;return t?KT(Array.from(t,Xp).join("")):null}catch{return null}}function QT(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,i=r[n],s=r.getPropertyPriority(i);t+=`${i}:${r.getPropertyValue(i)}${s?" !important":""};`}return`${e.selectorText} { ${t} }`}function Xp(e){let t;if(tI(e))try{t=Gs(e.styleSheet)||ZT(e)}catch{}else if(nI(e)){let n=e.cssText;const r=e.selectorText.includes(":"),i=typeof e.style.all=="string"&&e.style.all;if(i&&(n=QT(e)),r&&(n=eI(n)),r||i)return n}return t||e.cssText}function eI(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function tI(e){return"styleSheet"in e}function nI(e){return"selectorText"in e}let Yp=class{constructor(){$l(this,"idNodeMap",new Map),$l(this,"nodeMetaMap",new WeakMap)}getId(t){return t?this.getMeta(t)?.id??-1:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const i=this.nodeMetaMap.get(r);i&&this.nodeMetaMap.set(n,i)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function rI(){return new Yp}function _o({maskInputOptions:e,tagName:t,type:n}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||n==="password"||t==="INPUT"&&!n&&e.text)}function ii({isMasked:e,element:t,value:n,maskInputFn:r}){let i=n||"";return e?(r&&(i=r(i,t)),"*".repeat(i.length)):i}function yr(e){return e.toLowerCase()}function ja(e){return e.toUpperCase()}const Wl="__rrweb_original__";function iI(e){const t=e.getContext("2d");if(!t)return!0;const n=50;for(let r=0;r<e.width;r+=n)for(let i=0;i<e.height;i+=n){const s=t.getImageData,o=Wl in s?s[Wl]:s;if(new Uint32Array(o.call(t,r,i,Math.min(n,e.width-r),Math.min(n,e.height-i)).data.buffer).some(c=>c!==0))return!1}return!0}function eu(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?yr(t):null}function zs(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function Jp(e,t){let n;try{n=new URL(e,t??window.location.href)}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i;return n.pathname.match(r)?.[1]??null}const Gl={};function Kp(e){const t=Gl[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const s=i.contentWindow;s&&s[e]&&(r=s[e]),n.head.removeChild(i)}catch{}return Gl[e]=r.bind(window)}function qa(...e){return Kp("setTimeout")(...e)}function Zp(...e){return Kp("clearTimeout")(...e)}function Qp(e){try{return e.contentDocument}catch{}}let sI=1;const oI=new RegExp("[^a-z0-9-_:]"),si=-2;function tu(){return sI++}function aI(e){if(e instanceof HTMLFormElement)return"form";const t=yr(e.tagName);return oI.test(t)?"div":t}function cI(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let qn,zl;const uI=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,lI=/^(?:[a-z+]+:)?\/\//i,dI=/^www\..*/i,fI=/^(data:)([^,]*),(.*)/i;function js(e,t){return(e||"").replace(uI,(n,r,i,s,o,a)=>{const c=i||o||a,u=r||s||"";if(!c)return n;if(lI.test(c)||dI.test(c))return`url(${u}${c}${u})`;if(fI.test(c))return`url(${u}${c}${u})`;if(c[0]==="/")return`url(${u}${cI(t)+c}${u})`;const d=t.split("/"),l=c.split("/");d.pop();for(const f of l)f!=="."&&(f===".."?d.pop():d.push(f));return`url(${u}${d.join("/")}${u})`})}const hI=/^[^ \t\n\r\u000c]+/,pI=/^[, \t\n\r\u000c]+/;function mI(e,t){if(t.trim()==="")return t;let n=0;function r(s){let o;const a=s.exec(t.substring(n));return a?(o=a[0],n+=o.length,o):""}const i=[];for(;r(pI),!(n>=t.length);){let s=r(hI);if(s.slice(-1)===",")s=er(e,s.substring(0,s.length-1)),i.push(s);else{let o="";s=er(e,s);let a=!1;for(;;){const c=t.charAt(n);if(c===""){i.push((s+o).trim());break}else if(a)c===")"&&(a=!1);else if(c===","){n+=1,i.push((s+o).trim());break}else c==="("&&(a=!0);o+=c,n+=1}}}return i.join(", ")}const jl=new WeakMap;function er(e,t){return!t||t.trim()===""?t:yo(e,t)}function gI(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function yo(e,t){let n=jl.get(e);if(n||(n=e.createElement("a"),jl.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function em(e,t,n,r,i,s){return r&&(n==="src"||n==="href"&&!(t==="use"&&r[0]==="#")||n==="xlink:href"&&r[0]!=="#"||n==="background"&&(t==="table"||t==="td"||t==="th")?er(e,r):n==="srcset"?mI(e,r):n==="style"?js(r,yo(e)):t==="object"&&n==="data"?er(e,r):typeof s=="function"?s(n,r,i):r)}function tm(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function _I(e,t,n,r){try{if(r&&e.matches(r))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let i=e.classList.length;i--;){const s=e.classList[i];if(t.test(s))return!0}if(n)return e.matches(n)}catch{}return!1}function yI(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function Tn(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:Tn(e.parentNode,t,n,r+1)}function tr(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if(yI(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function br(e,t,n,r,i,s){try{const o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(o===null)return!1;if(o.tagName==="INPUT"){const u=o.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(u))return!0}let a=-1,c=-1;if(s){if(c=Tn(o,tr(r,i)),c<0)return!0;a=Tn(o,tr(t,n),c>=0?c:1/0)}else{if(a=Tn(o,tr(t,n)),a<0)return!1;c=Tn(o,tr(r,i),a>=0?a:1/0)}return a>=0?c>=0?a<=c:!0:c>=0?!1:!!s}catch{}return!!s}function bI(e,t,n){const r=e.contentWindow;if(!r)return;let i=!1,s;try{s=r.document.readyState}catch{return}if(s!=="complete"){const a=qa(()=>{i||(t(),i=!0)},n);e.addEventListener("load",()=>{Zp(a),i=!0,t()});return}const o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return qa(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function SI(e,t,n){let r=!1,i;try{i=e.sheet}catch{return}if(i)return;const s=qa(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{Zp(s),r=!0,t()})}function EI(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskAttributeFn:c,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f,inlineStylesheet:h,maskInputOptions:p={},maskTextFn:m,maskInputFn:g,dataURLOptions:_={},inlineImages:v,recordCanvas:L,keepIframeSrcFn:A,newlyAddedElement:O=!1}=t,T=vI(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Re.Document,childNodes:[],compatMode:e.compatMode}:{type:Re.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Re.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:T};case e.ELEMENT_NODE:return TI(e,{doc:n,blockClass:i,blockSelector:s,unblockSelector:o,inlineStylesheet:h,maskAttributeFn:c,maskInputOptions:p,maskInputFn:g,dataURLOptions:_,inlineImages:v,recordCanvas:L,keepIframeSrcFn:A,newlyAddedElement:O,rootId:T,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f});case e.TEXT_NODE:return wI(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f,maskTextFn:m,maskInputOptions:p,maskInputFn:g,rootId:T});case e.CDATA_SECTION_NODE:return{type:Re.CDATA,textContent:"",rootId:T};case e.COMMENT_NODE:return{type:Re.Comment,textContent:e.textContent||"",rootId:T};default:return!1}}function vI(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function wI(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:i,maskTextSelector:s,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:c,maskInputFn:u,rootId:d}=t,l=e.parentNode&&e.parentNode.tagName;let f=e.textContent;const h=l==="STYLE"?!0:void 0,p=l==="SCRIPT"?!0:void 0,m=l==="TEXTAREA"?!0:void 0;if(h&&f){try{e.nextSibling||e.previousSibling||e.parentNode.sheet?.cssRules&&(f=Gs(e.parentNode.sheet))}catch(_){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${_}`,e)}f=js(f,yo(t.doc))}p&&(f="SCRIPT_PLACEHOLDER");const g=br(e,r,s,i,o,n);if(!h&&!p&&!m&&f&&g&&(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),m&&f&&(c.textarea||g)&&(f=u?u(f,e.parentNode):f.replace(/[\S]/g,"*")),l==="OPTION"&&f){const _=_o({type:null,tagName:l,maskInputOptions:c});f=ii({isMasked:br(e,r,s,i,o,_),element:e,value:f,maskInputFn:u})}return{type:Re.Text,textContent:f||"",isStyle:h,rootId:d}}function TI(e,t){const{doc:n,blockClass:r,blockSelector:i,unblockSelector:s,inlineStylesheet:o,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:u,dataURLOptions:d={},inlineImages:l,recordCanvas:f,keepIframeSrcFn:h,newlyAddedElement:p=!1,rootId:m,maskTextClass:g,unmaskTextClass:_,maskTextSelector:v,unmaskTextSelector:L}=t,A=_I(e,r,i,s),O=aI(e);let T={};const C=e.attributes.length;for(let x=0;x<C;x++){const R=e.attributes[x];R.name&&!tm(O,R.name,R.value)&&(T[R.name]=em(n,O,yr(R.name),R.value,e,c))}if(O==="link"&&o){const x=Array.from(n.styleSheets).find(P=>P.href===e.href);let R=null;x&&(R=Gs(x)),R&&(T.rel=null,T.href=null,T.crossorigin=null,T._cssText=js(R,x.href))}if(O==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const x=Gs(e.sheet);x&&(T._cssText=js(x,yo(n)))}if(O==="input"||O==="textarea"||O==="select"||O==="option"){const x=e,R=eu(x),P=zs(x,ja(O),R),k=x.checked;if(R!=="submit"&&R!=="button"&&P){const F=br(x,g,v,_,L,_o({type:R,tagName:ja(O),maskInputOptions:a}));T.value=ii({isMasked:F,element:x,value:P,maskInputFn:u})}k&&(T.checked=k)}if(O==="option"&&(e.selected&&!a.select?T.selected=!0:delete T.selected),O==="canvas"&&f){if(e.__context==="2d")iI(e)||(T.rr_dataURL=e.toDataURL(d.type,d.quality));else if(!("__context"in e)){const x=e.toDataURL(d.type,d.quality),R=n.createElement("canvas");R.width=e.width,R.height=e.height;const P=R.toDataURL(d.type,d.quality);x!==P&&(T.rr_dataURL=x)}}if(O==="img"&&l){qn||(qn=n.createElement("canvas"),zl=qn.getContext("2d"));const x=e,R=x.currentSrc||x.getAttribute("src")||"<unknown-src>",P=x.crossOrigin,k=()=>{x.removeEventListener("load",k);try{qn.width=x.naturalWidth,qn.height=x.naturalHeight,zl.drawImage(x,0,0),T.rr_dataURL=qn.toDataURL(d.type,d.quality)}catch(F){if(x.crossOrigin!=="anonymous"){x.crossOrigin="anonymous",x.complete&&x.naturalWidth!==0?k():x.addEventListener("load",k);return}else console.warn(`Cannot inline img src=${R}! Error: ${F}`)}x.crossOrigin==="anonymous"&&(P?T.crossOrigin=P:x.removeAttribute("crossorigin"))};x.complete&&x.naturalWidth!==0?k():x.addEventListener("load",k)}if((O==="audio"||O==="video")&&(T.rr_mediaState=e.paused?"paused":"played",T.rr_mediaCurrentTime=e.currentTime),p||(e.scrollLeft&&(T.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(T.rr_scrollTop=e.scrollTop)),A){const{width:x,height:R}=e.getBoundingClientRect();T={class:T.class,rr_width:`${x}px`,rr_height:`${R}px`}}O==="iframe"&&!h(T.src)&&(!A&&!Qp(e)&&(T.rr_src=T.src),delete T.src);let M;try{customElements.get(O)&&(M=!0)}catch{}return{type:Re.Element,tagName:O,attributes:T,childNodes:[],isSVG:gI(e)||void 0,needBlock:A,rootId:m,isCustom:M}}function me(e){return e==null?"":e.toLowerCase()}function II(e,t){if(t.comment&&e.type===Re.Comment)return!0;if(e.type===Re.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Jp(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(me(e.attributes.name).match(/^msapplication-tile(image|color)$/)||me(e.attributes.name)==="application-name"||me(e.attributes.rel)==="icon"||me(e.attributes.rel)==="apple-touch-icon"||me(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&me(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(me(e.attributes.property).match(/^(og|twitter|fb):/)||me(e.attributes.name).match(/^(og|twitter):/)||me(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(me(e.attributes.name)==="robots"||me(e.attributes.name)==="googlebot"||me(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(me(e.attributes.name)==="author"||me(e.attributes.name)==="generator"||me(e.attributes.name)==="framework"||me(e.attributes.name)==="publisher"||me(e.attributes.name)==="progid"||me(e.attributes.property).match(/^article:/)||me(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(me(e.attributes.name)==="google-site-verification"||me(e.attributes.name)==="yandex-verification"||me(e.attributes.name)==="csrf-token"||me(e.attributes.name)==="p:domain_verify"||me(e.attributes.name)==="verify-v1"||me(e.attributes.name)==="verification"||me(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function nr(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:f=!1,inlineStylesheet:h=!0,maskInputOptions:p={},maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:v,dataURLOptions:L={},inlineImages:A=!1,recordCanvas:O=!1,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:M=5e3,onBlockedImageLoad:x,onStylesheetLoad:R,stylesheetLoadTimeout:P=5e3,keepIframeSrcFn:k=()=>!1,newlyAddedElement:F=!1}=t;let{preserveWhiteSpace:X=!0}=t;const U=EI(e,{doc:n,mirror:r,blockClass:i,blockSelector:s,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,dataURLOptions:L,inlineImages:A,recordCanvas:O,keepIframeSrcFn:k,newlyAddedElement:F});if(!U)return console.warn(e,"not serialized"),null;let J;r.hasNode(e)?J=r.getId(e):II(U,v)||!X&&U.type===Re.Text&&!U.isStyle&&!U.textContent.replace(/^\s+|\s+$/gm,"").length?J=si:J=tu();const N=Object.assign(U,{id:J});if(r.add(e,N),J===si)return null;T&&T(e);let G=!f;if(N.type===Re.Element){G=G&&!N.needBlock;const B=e.shadowRoot;B&&Qr(B)&&(N.isShadowHost=!0)}if((N.type===Re.Document||N.type===Re.Element)&&G){v.headWhitespace&&N.type===Re.Element&&N.tagName==="head"&&(X=!1);const B={doc:n,mirror:r,blockClass:i,blockSelector:s,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:f,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:v,dataURLOptions:L,inlineImages:A,recordCanvas:O,preserveWhiteSpace:X,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:M,onBlockedImageLoad:x,onStylesheetLoad:R,stylesheetLoadTimeout:P,keepIframeSrcFn:k},re=e.childNodes?Array.from(e.childNodes):[];for(const ce of re){const Ae=nr(ce,B);Ae&&N.childNodes.push(Ae)}if(JT(e)&&e.shadowRoot)for(const ce of Array.from(e.shadowRoot.childNodes)){const Ae=nr(ce,B);Ae&&(Qr(e.shadowRoot)&&(Ae.isShadow=!0),N.childNodes.push(Ae))}}if(e.parentNode&&Zr(e.parentNode)&&Qr(e.parentNode)&&(N.isShadow=!0),N.type===Re.Element&&N.tagName==="iframe"&&!N.needBlock&&bI(e,()=>{const B=Qp(e);if(B&&C){const re=nr(B,{doc:B,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:v,dataURLOptions:L,inlineImages:A,recordCanvas:O,preserveWhiteSpace:X,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:M,onStylesheetLoad:R,stylesheetLoadTimeout:P,keepIframeSrcFn:k});re&&C(e,re)}},M),N.type===Re.Element&&N.tagName==="img"&&!e.complete&&N.needBlock){const B=e,re=()=>{if(B.isConnected&&!B.complete&&x)try{const ce=B.getBoundingClientRect();ce.width>0&&ce.height>0&&x(B,N,ce)}catch{}B.removeEventListener("load",re)};B.isConnected&&B.addEventListener("load",re)}return N.type===Re.Element&&N.tagName==="link"&&typeof N.attributes.rel=="string"&&(N.attributes.rel==="stylesheet"||N.attributes.rel==="preload"&&typeof N.attributes.href=="string"&&Jp(N.attributes.href)==="css")&&SI(e,()=>{if(R){const B=nr(e,{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:v,dataURLOptions:L,inlineImages:A,recordCanvas:O,preserveWhiteSpace:X,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:M,onStylesheetLoad:R,stylesheetLoadTimeout:P,keepIframeSrcFn:k});B&&R(e,B)}},P),N.type===Re.Element&&delete N.needBlock,N}function xI(e,t){const{mirror:n=new Yp,blockClass:r="rr-block",blockSelector:i=null,unblockSelector:s=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:u=null,unmaskTextSelector:d=null,inlineStylesheet:l=!0,inlineImages:f=!1,recordCanvas:h=!1,maskAllInputs:p=!1,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOM:v=!1,dataURLOptions:L,preserveWhiteSpace:A,onSerialize:O,onIframeLoad:T,iframeLoadTimeout:C,onBlockedImageLoad:M,onStylesheetLoad:x,stylesheetLoadTimeout:R,keepIframeSrcFn:P=()=>!1}=t||{};return nr(e,{doc:e,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,maskAllText:o,maskTextClass:a,unmaskTextClass:c,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:l,maskInputOptions:p===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:p===!1?{}:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:v===!0||v==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:v==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:v===!1?{}:v,dataURLOptions:L,inlineImages:f,recordCanvas:h,preserveWhiteSpace:A,onSerialize:O,onIframeLoad:T,iframeLoadTimeout:C,onBlockedImageLoad:M,onStylesheetLoad:x,stylesheetLoadTimeout:R,keepIframeSrcFn:P,newlyAddedElement:!1})}function Ge(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const Kn=`Please stop import mirror directly. Instead of that,\r
494
+ now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
495
+ or you can use record.mirror to access the mirror instance during recording.`;let ql={map:{},getId(){return console.error(Kn),-1},getNode(){return console.error(Kn),null},removeNodeFromMap(){console.error(Kn)},has(){return console.error(Kn),!1},reset(){console.error(Kn)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(ql=new Proxy(ql,{get(e,t,n){return t==="map"&&console.error(Kn),Reflect.get(e,t,n)}}));function oi(e,t,n={}){let r=null,i=0;return function(...s){const o=Date.now();!i&&n.leading===!1&&(i=o);const a=t-(o-i),c=this;a<=0||a>t?(r&&(OI(r),r=null),i=o,e.apply(c,s)):!r&&n.trailing!==!1&&(r=bo(()=>{i=n.leading===!1?0:Date.now(),r=null,e.apply(c,s)},a))}}function nm(e,t,n,r,i=window){const s=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,r?n:{set(o){bo(()=>{n.set.call(this,o)},0),s&&s.set&&s.set.call(this,o)}}),()=>nm(e,t,s||{},!0)}function nu(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],i=n(r);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=i,()=>{e[t]=r}}catch{return()=>{}}}let qs=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(qs=()=>new Date().getTime());function rm(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:t?.documentElement.scrollLeft||t?.body?.parentElement?.scrollLeft||t?.body?.scrollLeft||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:t?.documentElement.scrollTop||t?.body?.parentElement?.scrollTop||t?.body?.scrollTop||0}}function im(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function sm(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function om(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function Qe(e,t,n,r,i){if(!e)return!1;const s=om(e);if(!s)return!1;const o=tr(t,n);if(!i){const u=r&&s.matches(r);return o(s)&&!u}const a=Tn(s,o);let c=-1;return a<0?!1:(r&&(c=Tn(s,tr(null,r))),a>-1&&c<0?!0:a<c)}function kI(e,t){return t.getId(e)!==-1}function Jo(e,t){return t.getId(e)===si}function am(e,t){if(Zr(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?am(e.parentNode,t):!0:!0}function Va(e){return!!e.changedTouches}function CI(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let n=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===n)return!0;while(n=n&&n.parentNode);return!1})}function cm(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function um(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Xa(e){return!!e?.shadowRoot}class RI{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return this.styleIDMap.get(t)??-1}has(t){return this.styleIDMap.has(t)}add(t,n){if(this.has(t))return this.getId(t);let r;return n===void 0?r=this.id++:r=n,this.styleIDMap.set(t,r),this.idStyleMap.set(r,t),r}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function lm(e){let t=null;return e.getRootNode?.()?.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function AI(e){let t=e,n;for(;n=lm(t);)t=n;return t}function MI(e){const t=e.ownerDocument;if(!t)return!1;const n=AI(e);return t.contains(n)}function dm(e){const t=e.ownerDocument;return t?t.contains(e)||MI(e):!1}const Vl={};function ru(e){const t=Vl[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const s=i.contentWindow;s&&s[e]&&(r=s[e]),n.head.removeChild(i)}catch{}return Vl[e]=r.bind(window)}function NI(...e){return ru("requestAnimationFrame")(...e)}function bo(...e){return ru("setTimeout")(...e)}function OI(...e){return ru("clearTimeout")(...e)}var ee=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(ee||{}),V=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(V||{}),Ue=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(Ue||{}),Nt=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Nt||{}),Zn=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(Zn||{});function iu(e){try{return e.contentDocument}catch{}}function LI(e){try{return e.contentWindow}catch{}}function Xl(e){return"__ln"in e}class PI{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let n=this.head;for(let r=0;r<t;r++)n=n?.next||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&Xl(t.previousSibling)){const r=t.previousSibling.__ln.next;n.next=r,n.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=n,r&&(r.previous=n)}else if(t.nextSibling&&Xl(t.nextSibling)&&t.nextSibling.__ln.previous){const r=t.nextSibling.__ln.previous;n.previous=r,n.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=n,r&&(r.next=n)}else this.head&&(this.head.previous=n),n.next=this.head,this.head=n;n.next===null&&(this.tail=n),this.length++}removeNode(t){const n=t.__ln;this.head&&(n.previous?(n.previous.next=n.next,n.next?n.next.previous=n.previous:this.tail=n.previous):(this.head=n.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const Yl=(e,t)=>`${e}@${t}`;class DI{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],n=new Set,r=new PI,i=c=>{let u=c,d=si;for(;d===si;)u=u&&u.nextSibling,d=u&&this.mirror.getId(u);return d},s=c=>{if(!c.parentNode||!dm(c))return;const u=Zr(c.parentNode)?this.mirror.getId(lm(c)):this.mirror.getId(c.parentNode),d=i(c);if(u===-1||d===-1)return r.addNode(c);const l=nr(c,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:f=>{cm(f,this.mirror)&&!Qe(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(f),um(f,this.mirror)&&this.stylesheetManager.trackLinkElement(f),Xa(c)&&this.shadowDomManager.addShadowRoot(c.shadowRoot,this.doc)},onIframeLoad:(f,h)=>{Qe(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(f,h),f.contentWindow&&this.canvasManager.addWindow(f.contentWindow),this.shadowDomManager.observeAttachShadow(f))},onStylesheetLoad:(f,h)=>{this.stylesheetManager.attachLinkElement(f,h)},onBlockedImageLoad:(f,h,{width:p,height:m})=>{this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:h.id,attributes:{style:{width:`${p}px`,height:`${m}px`}}}]})}});l&&(t.push({parentId:u,nextId:d,node:l}),n.add(l.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const c of this.movedSet)Jl(this.removes,c,this.mirror)&&!this.movedSet.has(c.parentNode)||s(c);for(const c of this.addedSet)!Kl(this.droppedSet,c)&&!Jl(this.removes,c,this.mirror)||Kl(this.movedSet,c)?s(c):this.droppedSet.add(c);let o=null;for(;r.length;){let c=null;if(o){const u=this.mirror.getId(o.value.parentNode),d=i(o.value);u!==-1&&d!==-1&&(c=o)}if(!c){let u=r.tail;for(;u;){const d=u;if(u=u.previous,d){const l=this.mirror.getId(d.value.parentNode);if(i(d.value)===-1)continue;if(l!==-1){c=d;break}else{const h=d.value;if(h.parentNode&&h.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const p=h.parentNode.host;if(this.mirror.getId(p)!==-1){c=d;break}}}}}}if(!c){for(;r.head;)r.removeNode(r.head.value);break}o=c.previous,r.removeNode(c.value),s(c.value)}const a={texts:this.texts.map(c=>({id:this.mirror.getId(c.node),value:c.value})).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),attributes:this.attributes.map(c=>{const{attributes:u}=c;if(typeof u.style=="string"){const d=JSON.stringify(c.styleDiff),l=JSON.stringify(c._unchangedStyles);d.length<u.style.length&&(d+l).split("var(").length===u.style.split("var(").length&&(u.style=c.styleDiff)}return{id:this.mirror.getId(c.node),attributes:u}}).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),removes:this.removes,adds:t};!a.texts.length&&!a.attributes.length&&!a.removes.length&&!a.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(a))},this.processMutation=t=>{if(!Jo(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!Qe(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:br(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,om(t.target)):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let r=t.attributeName,i=t.target.getAttribute(r);if(r==="value"){const o=eu(n),a=n.tagName;i=zs(n,a,o);const c=_o({maskInputOptions:this.maskInputOptions,tagName:a,type:o}),u=br(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,c);i=ii({isMasked:u,element:n,value:i,maskInputFn:this.maskInputFn})}if(Qe(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||i===t.oldValue)return;let s=this.attributeMap.get(t.target);if(n.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(i))if(!iu(n))r="rr_src";else return;if(s||(s={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(s),this.attributeMap.set(t.target,s)),r==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!tm(n.tagName,r)&&(s.attributes[r]=em(this.doc,yr(n.tagName),yr(r),i,n,this.maskAttributeFn),r==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const o=this.unattachedDoc.createElement("span");t.oldValue&&o.setAttribute("style",t.oldValue);for(const a of Array.from(n.style)){const c=n.style.getPropertyValue(a),u=n.style.getPropertyPriority(a);c!==o.style.getPropertyValue(a)||u!==o.style.getPropertyPriority(a)?u===""?s.styleDiff[a]=c:s.styleDiff[a]=[c,u]:s._unchangedStyles[a]=[c,u]}for(const a of Array.from(o.style))n.style.getPropertyValue(a)===""&&(s.styleDiff[a]=!1)}break}case"childList":{if(Qe(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const r=this.mirror.getId(n),i=Zr(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);Qe(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||Jo(n,this.mirror)||!kI(n,this.mirror)||(this.addedSet.has(n)?(Ya(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||am(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[Yl(r,i)]?Ya(this.movedSet,n):this.removes.push({parentId:i,id:r,isShadow:Zr(t.target)&&Qr(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,n)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Jo(t,this.mirror))return;this.movedSet.add(t);let r=null;n&&this.mirror.hasNode(n)&&(r=this.mirror.getId(n)),r&&r!==-1&&(this.movedMap[Yl(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);Qe(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes&&t.childNodes.forEach(r=>this.genAdds(r)),Xa(t)&&t.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,t)}))}}}init(t){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(n=>{this[n]=t[n]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function Ya(e,t){e.delete(t),t.childNodes?.forEach(n=>Ya(e,n))}function Jl(e,t,n){return e.length===0?!1:FI(e,t,n)}function FI(e,t,n){let r=t.parentNode;for(;r;){const i=n.getId(r);if(e.some(s=>s.id===i))return!0;r=r.parentNode}return!1}function Kl(e,t){return e.size===0?!1:fm(e,t)}function fm(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:fm(e,n):!1}let ei;function HI(e){ei=e}function BI(){ei=void 0}const ae=e=>ei?(...n)=>{try{return e(...n)}catch(r){if(ei&&ei(r)===!0)return()=>{};throw r}}:e,rr=[];function ki(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function hm(e,t){const n=new DI;rr.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const i=window?.Zone?.__symbol__?.("MutationObserver");i&&window[i]&&(r=window[i]);const s=new r(ae(o=>{e.onMutation&&e.onMutation(o)===!1||n.processMutations.bind(n)(o)}));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function UI({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,s=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],a;const c=oi(ae(l=>{const f=Date.now()-a;e(o.map(h=>(h.timeOffset-=f,h)),l),o=[],a=null}),s),u=ae(oi(ae(l=>{const f=ki(l),{clientX:h,clientY:p}=Va(l)?l.changedTouches[0]:l;a||(a=qs()),o.push({x:h,y:p,id:r.getId(f),timeOffset:qs()-a}),c(typeof DragEvent<"u"&&l instanceof DragEvent?V.Drag:l instanceof MouseEvent?V.MouseMove:V.TouchMove)}),i,{trailing:!1})),d=[Ge("mousemove",u,n),Ge("touchmove",u,n),Ge("drag",u,n)];return ae(()=>{d.forEach(l=>l())})}function $I({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const a=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,c=[];let u=null;const d=l=>f=>{const h=ki(f);if(Qe(h,r,i,s,!0))return;let p=null,m=l;if("pointerType"in f){switch(f.pointerType){case"mouse":p=Nt.Mouse;break;case"touch":p=Nt.Touch;break;case"pen":p=Nt.Pen;break}p===Nt.Touch?Ue[l]===Ue.MouseDown?m="TouchStart":Ue[l]===Ue.MouseUp&&(m="TouchEnd"):Nt.Pen}else Va(f)&&(p=Nt.Touch);p!==null?(u=p,(m.startsWith("Touch")&&p===Nt.Touch||m.startsWith("Mouse")&&p===Nt.Mouse)&&(p=null)):Ue[l]===Ue.Click&&(p=u,u=null);const g=Va(f)?f.changedTouches[0]:f;if(!g)return;const _=n.getId(h),{clientX:v,clientY:L}=g;ae(e)({type:Ue[m],id:_,x:v,y:L,...p!==null&&{pointerType:p}})};return Object.keys(Ue).filter(l=>Number.isNaN(Number(l))&&!l.endsWith("_Departed")&&a[l]!==!1).forEach(l=>{let f=yr(l);const h=d(l);if(window.PointerEvent)switch(Ue[l]){case Ue.MouseDown:case Ue.MouseUp:f=f.replace("mouse","pointer");break;case Ue.TouchStart:case Ue.TouchEnd:return}c.push(Ge(f,h,t))}),ae(()=>{c.forEach(l=>l())})}function pm({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,sampling:o}){const a=ae(oi(ae(c=>{const u=ki(c);if(!u||Qe(u,r,i,s,!0))return;const d=n.getId(u);if(u===t&&t.defaultView){const l=rm(t.defaultView);e({id:d,x:l.left,y:l.top})}else e({id:d,x:u.scrollLeft,y:u.scrollTop})}),o.scroll||100));return Ge("scroll",a,t)}function WI({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const i=ae(oi(ae(()=>{const s=im(),o=sm();(n!==s||r!==o)&&(e({width:Number(o),height:Number(s)}),n=s,r=o)}),200));return Ge("resize",i,t)}const GI=["INPUT","TEXTAREA","SELECT"],Zl=new WeakMap;function zI({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,ignoreClass:o,ignoreSelector:a,maskInputOptions:c,maskInputFn:u,sampling:d,userTriggeredOnInput:l,maskTextClass:f,unmaskTextClass:h,maskTextSelector:p,unmaskTextSelector:m}){function g(C){let M=ki(C);const x=C.isTrusted,R=M&&ja(M.tagName);if(R==="OPTION"&&(M=M.parentElement),!M||!R||GI.indexOf(R)<0||Qe(M,r,i,s,!0))return;const P=M;if(P.classList.contains(o)||a&&P.matches(a))return;const k=eu(M);let F=zs(P,R,k),X=!1;const U=_o({maskInputOptions:c,tagName:R,type:k}),J=br(M,f,p,h,m,U);(k==="radio"||k==="checkbox")&&(X=M.checked),F=ii({isMasked:J,element:M,value:F,maskInputFn:u}),_(M,l?{text:F,isChecked:X,userTriggered:x}:{text:F,isChecked:X});const N=M.name;k==="radio"&&N&&X&&t.querySelectorAll(`input[type="radio"][name="${N}"]`).forEach(G=>{if(G!==M){const B=ii({isMasked:J,element:G,value:zs(G,R,k),maskInputFn:u});_(G,l?{text:B,isChecked:!X,userTriggered:!1}:{text:B,isChecked:!X})}})}function _(C,M){const x=Zl.get(C);if(!x||x.text!==M.text||x.isChecked!==M.isChecked){Zl.set(C,M);const R=n.getId(C);ae(e)({...M,id:R})}}const L=(d.input==="last"?["change"]:["input","change"]).map(C=>Ge(C,ae(g),t)),A=t.defaultView;if(!A)return()=>{L.forEach(C=>C())};const O=A.Object.getOwnPropertyDescriptor(A.HTMLInputElement.prototype,"value"),T=[[A.HTMLInputElement.prototype,"value"],[A.HTMLInputElement.prototype,"checked"],[A.HTMLSelectElement.prototype,"value"],[A.HTMLTextAreaElement.prototype,"value"],[A.HTMLSelectElement.prototype,"selectedIndex"],[A.HTMLOptionElement.prototype,"selected"]];return O&&O.set&&L.push(...T.map(C=>nm(C[0],C[1],{set(){ae(g)({target:this,isTrusted:!1})}},!1,A))),ae(()=>{L.forEach(C=>C())})}function Vs(e){const t=[];function n(r,i){if(qi("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||qi("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||qi("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||qi("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const o=Array.from(r.parentRule.cssRules).indexOf(r);i.unshift(o)}else if(r.parentStyleSheet){const o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);i.unshift(o)}return i}return n(e,t)}function Zt(e,t,n){let r,i;return e?(e.ownerNode?r=t.getId(e.ownerNode):i=n.getId(e),{styleId:i,id:r}):{}}function jI({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const i=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:ae((d,l,f)=>{const[h,p]=f,{id:m,styleId:g}=Zt(l,t,n.styleMirror);return(m&&m!==-1||g&&g!==-1)&&e({id:m,styleId:g,adds:[{rule:h,index:p}]}),d.apply(l,f)})});const s=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(s,{apply:ae((d,l,f)=>{const[h]=f,{id:p,styleId:m}=Zt(l,t,n.styleMirror);return(p&&p!==-1||m&&m!==-1)&&e({id:p,styleId:m,removes:[{index:h}]}),d.apply(l,f)})});let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:ae((d,l,f)=>{const[h]=f,{id:p,styleId:m}=Zt(l,t,n.styleMirror);return(p&&p!==-1||m&&m!==-1)&&e({id:p,styleId:m,replace:h}),d.apply(l,f)})}));let a;r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:ae((d,l,f)=>{const[h]=f,{id:p,styleId:m}=Zt(l,t,n.styleMirror);return(p&&p!==-1||m&&m!==-1)&&e({id:p,styleId:m,replaceSync:h}),d.apply(l,f)})}));const c={};Vi("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(Vi("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),Vi("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),Vi("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(c).forEach(([d,l])=>{u[d]={insertRule:l.prototype.insertRule,deleteRule:l.prototype.deleteRule},l.prototype.insertRule=new Proxy(u[d].insertRule,{apply:ae((f,h,p)=>{const[m,g]=p,{id:_,styleId:v}=Zt(h.parentStyleSheet,t,n.styleMirror);return(_&&_!==-1||v&&v!==-1)&&e({id:_,styleId:v,adds:[{rule:m,index:[...Vs(h),g||0]}]}),f.apply(h,p)})}),l.prototype.deleteRule=new Proxy(u[d].deleteRule,{apply:ae((f,h,p)=>{const[m]=p,{id:g,styleId:_}=Zt(h.parentStyleSheet,t,n.styleMirror);return(g&&g!==-1||_&&_!==-1)&&e({id:g,styleId:_,removes:[{index:[...Vs(h),m]}]}),f.apply(h,p)})})}),ae(()=>{r.CSSStyleSheet.prototype.insertRule=i,r.CSSStyleSheet.prototype.deleteRule=s,o&&(r.CSSStyleSheet.prototype.replace=o),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach(([d,l])=>{l.prototype.insertRule=u[d].insertRule,l.prototype.deleteRule=u[d].deleteRule})})}function mm({mirror:e,stylesheetManager:t},n){let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const i=n.nodeName==="#document"?n.defaultView?.Document:n.ownerDocument?.defaultView?.ShadowRoot,s=i?.prototype?Object.getOwnPropertyDescriptor(i?.prototype,"adoptedStyleSheets"):void 0;return r===null||r===-1||!i||!s?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){return s.get?.call(this)},set(o){const a=s.set?.call(this,o);if(r!==null&&r!==-1)try{t.adoptStyleSheets(o,r)}catch{}return a}}),ae(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})}))}function qI({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:i}){const s=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:ae((a,c,u)=>{const[d,l,f]=u;if(n.has(d))return s.apply(c,[d,l,f]);const{id:h,styleId:p}=Zt(c.parentRule?.parentStyleSheet,t,r.styleMirror);return(h&&h!==-1||p&&p!==-1)&&e({id:h,styleId:p,set:{property:d,value:l,priority:f},index:Vs(c.parentRule)}),a.apply(c,u)})});const o=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:ae((a,c,u)=>{const[d]=u;if(n.has(d))return o.apply(c,[d]);const{id:l,styleId:f}=Zt(c.parentRule?.parentStyleSheet,t,r.styleMirror);return(l&&l!==-1||f&&f!==-1)&&e({id:l,styleId:f,remove:{property:d},index:Vs(c.parentRule)}),a.apply(c,u)})}),ae(()=>{i.CSSStyleDeclaration.prototype.setProperty=s,i.CSSStyleDeclaration.prototype.removeProperty=o})}function VI({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:i,sampling:s,doc:o}){const a=ae(u=>oi(ae(d=>{const l=ki(d);if(!l||Qe(l,t,n,r,!0))return;const{currentTime:f,volume:h,muted:p,playbackRate:m}=l;e({type:u,id:i.getId(l),currentTime:f,volume:h,muted:p,playbackRate:m})}),s.media||500)),c=[Ge("play",a(Zn.Play),o),Ge("pause",a(Zn.Pause),o),Ge("seeked",a(Zn.Seeked),o),Ge("volumechange",a(Zn.VolumeChange),o),Ge("ratechange",a(Zn.RateChange),o)];return ae(()=>{c.forEach(u=>u())})}function XI({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],i=new WeakMap,s=n.FontFace;n.FontFace=function(c,u,d){const l=new s(c,u,d);return i.set(l,{family:c,buffer:typeof u!="string",descriptors:d,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),l};const o=nu(t.fonts,"add",function(a){return function(c){return bo(ae(()=>{const u=i.get(c);u&&(e(u),i.delete(c))}),0),a.apply(this,[c])}});return r.push(()=>{n.FontFace=s}),r.push(o),ae(()=>{r.forEach(a=>a())})}function YI(e){const{doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,selectionCb:o}=e;let a=!0;const c=ae(()=>{const u=t.getSelection();if(!u||a&&u?.isCollapsed)return;a=u.isCollapsed||!1;const d=[],l=u.rangeCount||0;for(let f=0;f<l;f++){const h=u.getRangeAt(f),{startContainer:p,startOffset:m,endContainer:g,endOffset:_}=h;Qe(p,r,i,s,!0)||Qe(g,r,i,s,!0)||d.push({start:n.getId(p),startOffset:m,end:n.getId(g),endOffset:_})}o({ranges:d})});return c(),Ge("selectionchange",c)}function JI({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:nu(n.customElements,"define",function(i){return function(s,o,a){try{t({define:{name:s}})}catch{}return i.apply(this,[s,o,a])}})}function KI(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=hm(e,e.doc));const i=UI(e),s=$I(e),o=pm(e),a=WI(e,{win:n}),c=zI(e),u=VI(e);let d=()=>{},l=()=>{},f=()=>{},h=()=>{};e.recordDOM&&(d=jI(e,{win:n}),l=mm(e,e.doc),f=qI(e,{win:n}),e.collectFonts&&(h=XI(e)));const p=YI(e),m=JI(e),g=[];for(const _ of e.plugins)g.push(_.observer(_.callback,n,_.options));return ae(()=>{rr.forEach(_=>_.reset()),r?.disconnect(),i(),s(),o(),a(),c(),u(),d(),l(),f(),h(),p(),m(),g.forEach(_=>_())})}function qi(e){return typeof window[e]<"u"}function Vi(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Ja{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,n,r,i){const s=r||this.getIdToRemoteIdMap(t),o=i||this.getRemoteIdToIdMap(t);let a=s.get(n);return a||(a=this.generateIdFn(),s.set(n,a),o.set(a,n)),a}getIds(t,n){const r=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return n.map(s=>this.getId(t,s,r,i))}getRemoteId(t,n,r){const i=r||this.getRemoteIdToIdMap(t);if(typeof n!="number")return n;const s=i.get(n);return s||-1}getRemoteIds(t,n){const r=this.getRemoteIdToIdMap(t);return n.map(i=>this.getRemoteId(t,i,r))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let n=this.iframeIdToRemoteIdMap.get(t);return n||(n=new Map,this.iframeIdToRemoteIdMap.set(t,n)),n}getRemoteIdToIdMap(t){let n=this.iframeRemoteIdToIdMap.get(t);return n||(n=new Map,this.iframeRemoteIdToIdMap.set(t,n)),n}}class ZI{constructor(){this.crossOriginIframeMirror=new Ja(tu),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class QI{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Ja(tu),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Ja(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,n){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&t.contentWindow?.addEventListener("message",this.handleMessage.bind(this)),this.loadListener?.(t);const r=iu(t);r&&r.adoptedStyleSheets&&r.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(r.adoptedStyleSheets,this.mirror.getId(r))}handleMessage(t){const n=t;if(n.data.type!=="rrweb"||n.origin!==n.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const s=this.transformCrossOriginEvent(i,n.data.event);s&&this.wrappedEmit(s,n.data.isCheckout)}transformCrossOriginEvent(t,n){switch(n.type){case ee.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const r=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,r),this.patchRootIdOnNode(n.data.node,r),{timestamp:n.timestamp,type:ee.IncrementalSnapshot,data:{source:V.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:n.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case ee.Meta:case ee.Load:case ee.DomContentLoaded:return!1;case ee.Plugin:return n;case ee.Custom:return this.replaceIds(n.data.payload,t,["id","parentId","previousId","nextId"]),n;case ee.IncrementalSnapshot:switch(n.data.source){case V.Mutation:return n.data.adds.forEach(r=>{this.replaceIds(r,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(r.node,t);const i=this.crossOriginIframeRootIdMap.get(t);i&&this.patchRootIdOnNode(r.node,i)}),n.data.removes.forEach(r=>{this.replaceIds(r,t,["parentId","id"])}),n.data.attributes.forEach(r=>{this.replaceIds(r,t,["id"])}),n.data.texts.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case V.Drag:case V.TouchMove:case V.MouseMove:return n.data.positions.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case V.ViewportResize:return!1;case V.MediaInteraction:case V.MouseInteraction:case V.Scroll:case V.CanvasMutation:case V.Input:return this.replaceIds(n.data,t,["id"]),n;case V.StyleSheetRule:case V.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case V.Font:return n;case V.Selection:return n.data.ranges.forEach(r=>{this.replaceIds(r,t,["start","end"])}),n;case V.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),n.data.styles?.forEach(r=>{this.replaceStyleIds(r,t,["styleId"])}),n}}return!1}replace(t,n,r,i){for(const s of i)!Array.isArray(n[s])&&typeof n[s]!="number"||(Array.isArray(n[s])?n[s]=t.getIds(r,n[s]):n[s]=t.getId(r,n[s]));return n}replaceIds(t,n,r){return this.replace(this.crossOriginIframeMirror,t,n,r)}replaceStyleIds(t,n,r){return this.replace(this.crossOriginIframeStyleMirror,t,n,r)}replaceIdOnNode(t,n){this.replaceIds(t,n,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(r=>{this.replaceIdOnNode(r,n)})}patchRootIdOnNode(t,n){t.type!==Re.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class e1{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class t1{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,n){if(!Qr(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=hm({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(pm({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),bo(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(mm({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){const n=iu(t),r=LI(t);!n||!r||this.patchAttachShadow(r.Element,n)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(nu(t.prototype,"attachShadow",function(i){return function(s){const o=i.call(this,s);return this.shadowRoot&&dm(this)&&r.addShadowRoot(this.shadowRoot,n),o}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}var Ql="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n1=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var Xi=0;Xi<Ql.length;Xi++)n1[Ql.charCodeAt(Xi)]=Xi;class ed{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class r1{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new RI,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,n){"_cssText"in n.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:n.id,attributes:n.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,n){if(t.length===0)return;const r={id:n,styleIds:[]},i=[];for(const s of t){let o;this.styleMirror.has(s)?o=this.styleMirror.getId(s):(o=this.styleMirror.add(s),i.push({styleId:o,rules:Array.from(s.rules||CSSRule,(a,c)=>({rule:Xp(a),index:c}))})),r.styleIds.push(o)}i.length>0&&(r.styles=i),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class i1{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(t,n){const r=this.nodeMap.get(t);return r&&Array.from(r).some(i=>i!==n)}add(t,n){this.active||(this.active=!0,NI(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let ve,Xs;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=e.contentWindow?.Array.from||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const ut=rI();function Ft(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:i="rr-block",blockSelector:s=null,unblockSelector:o=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:u=!1,maskTextClass:d="rr-mask",unmaskTextClass:l=null,maskTextSelector:f=null,unmaskTextSelector:h=null,inlineStylesheet:p=!0,maskAllInputs:m,maskInputOptions:g,slimDOMOptions:_,maskAttributeFn:v,maskInputFn:L,maskTextFn:A,maxCanvasSize:O=null,packFn:T,sampling:C={},dataURLOptions:M={},mousemoveWait:x,recordDOM:R=!0,recordCanvas:P=!1,recordCrossOriginIframes:k=!1,recordAfter:F=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:X=!1,collectFonts:U=!1,inlineImages:J=!1,plugins:N,keepIframeSrcFn:G=()=>!1,ignoreCSSAttributes:B=new Set([]),errorHandler:re,onMutation:ce,getCanvasManager:Ae}=e;HI(re);const Me=k?window.parent===window:!0;let ke=!1;if(!Me)try{window.parent.document&&(ke=!1)}catch{ke=!0}if(Me&&!t)throw new Error("emit function is required");if(!Me&&!ke)return()=>{};x!==void 0&&C.mousemove===void 0&&(C.mousemove=x),ut.reset();const Ke=m===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:g!==void 0?g:{},At=_===!0||_==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:_==="all",headMetaDescKeywords:_==="all"}:_||{};CI();let Wn,Gn=0;const Dr=ue=>{for(const ct of N||[])ct.eventProcessor&&(ue=ct.eventProcessor(ue));return T&&!ke&&(ue=T(ue)),ue};ve=(ue,ct)=>{const ie=ue;if(ie.timestamp=qs(),rr[0]?.isFrozen()&&ie.type!==ee.FullSnapshot&&!(ie.type===ee.IncrementalSnapshot&&ie.data.source===V.Mutation)&&rr.forEach(Fe=>Fe.unfreeze()),Me)t?.(Dr(ie),ct);else if(ke){const Fe={type:"rrweb",event:Dr(ie),origin:window.location.origin,isCheckout:ct};window.parent.postMessage(Fe,"*")}if(ie.type===ee.FullSnapshot)Wn=ie,Gn=0;else if(ie.type===ee.IncrementalSnapshot){if(ie.data.source===V.Mutation&&ie.data.isAttachIframe)return;Gn++;const Fe=r&&Gn>=r,le=n&&Wn&&ie.timestamp-Wn.timestamp>n;(Fe||le)&&ko(!0)}};const Mt=ue=>{ve({type:ee.IncrementalSnapshot,data:{source:V.Mutation,...ue}})},be=ue=>ve({type:ee.IncrementalSnapshot,data:{source:V.Scroll,...ue}}),De=ue=>ve({type:ee.IncrementalSnapshot,data:{source:V.CanvasMutation,...ue}}),bt=ue=>ve({type:ee.IncrementalSnapshot,data:{source:V.AdoptedStyleSheet,...ue}}),Te=new r1({mutationCb:Mt,adoptedStyleSheetCb:bt}),Ne=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new ZI:new QI({mirror:ut,mutationCb:Mt,stylesheetManager:Te,recordCrossOriginIframes:k,wrappedEmit:ve});for(const ue of N||[])ue.getMirror&&ue.getMirror({nodeMirror:ut,crossOriginIframeMirror:Ne.crossOriginIframeMirror,crossOriginIframeStyleMirror:Ne.crossOriginIframeStyleMirror});const St=new i1,mn=o1(Ae,{mirror:ut,win:window,mutationCb:ue=>ve({type:ee.IncrementalSnapshot,data:{source:V.CanvasMutation,...ue}}),recordCanvas:P,blockClass:i,blockSelector:s,unblockSelector:o,maxCanvasSize:O,sampling:C.canvas,dataURLOptions:M,errorHandler:re}),zn=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new e1:new t1({mutationCb:Mt,scrollCb:be,bypassOptions:{onMutation:ce,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:h,inlineStylesheet:p,maskInputOptions:Ke,dataURLOptions:M,maskAttributeFn:v,maskTextFn:A,maskInputFn:L,recordCanvas:P,inlineImages:J,sampling:C,slimDOMOptions:At,iframeManager:Ne,stylesheetManager:Te,canvasManager:mn,keepIframeSrcFn:G,processedNodeManager:St},mirror:ut}),ko=(ue=!1)=>{if(!R)return;ve({type:ee.Meta,data:{href:window.location.href,width:sm(),height:im()}},ue),Te.reset(),zn.init(),rr.forEach(ie=>ie.lock());const ct=xI(document,{mirror:ut,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:h,inlineStylesheet:p,maskAllInputs:Ke,maskAttributeFn:v,maskInputFn:L,maskTextFn:A,slimDOM:At,dataURLOptions:M,recordCanvas:P,inlineImages:J,onSerialize:ie=>{cm(ie,ut)&&Ne.addIframe(ie),um(ie,ut)&&Te.trackLinkElement(ie),Xa(ie)&&zn.addShadowRoot(ie.shadowRoot,document)},onIframeLoad:(ie,Fe)=>{Ne.attachIframe(ie,Fe),ie.contentWindow&&mn.addWindow(ie.contentWindow),zn.observeAttachShadow(ie)},onStylesheetLoad:(ie,Fe)=>{Te.attachLinkElement(ie,Fe)},onBlockedImageLoad:(ie,Fe,{width:le,height:Fr})=>{Mt({adds:[],removes:[],texts:[],attributes:[{id:Fe.id,attributes:{style:{width:`${le}px`,height:`${Fr}px`}}}]})},keepIframeSrcFn:G});if(!ct)return console.warn("Failed to snapshot the document");ve({type:ee.FullSnapshot,data:{node:ct,initialOffset:rm(window)}}),rr.forEach(ie=>ie.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Te.adoptStyleSheets(document.adoptedStyleSheets,ut.getId(document))};Xs=ko;try{const ue=[],ct=Fe=>ae(KI)({onMutation:ce,mutationCb:Mt,mousemoveCb:(le,Fr)=>ve({type:ee.IncrementalSnapshot,data:{source:Fr,positions:le}}),mouseInteractionCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.MouseInteraction,...le}}),scrollCb:be,viewportResizeCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.ViewportResize,...le}}),inputCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.Input,...le}}),mediaInteractionCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.MediaInteraction,...le}}),styleSheetRuleCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.StyleSheetRule,...le}}),styleDeclarationCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.StyleDeclaration,...le}}),canvasMutationCb:De,fontCb:le=>ve({type:ee.IncrementalSnapshot,data:{source:V.Font,...le}}),selectionCb:le=>{ve({type:ee.IncrementalSnapshot,data:{source:V.Selection,...le}})},customElementCb:le=>{ve({type:ee.IncrementalSnapshot,data:{source:V.CustomElement,...le}})},blockClass:i,ignoreClass:a,ignoreSelector:c,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:h,maskInputOptions:Ke,inlineStylesheet:p,sampling:C,recordDOM:R,recordCanvas:P,inlineImages:J,userTriggeredOnInput:X,collectFonts:U,doc:Fe,maskAttributeFn:v,maskInputFn:L,maskTextFn:A,keepIframeSrcFn:G,blockSelector:s,unblockSelector:o,slimDOMOptions:At,dataURLOptions:M,mirror:ut,iframeManager:Ne,stylesheetManager:Te,shadowDomManager:zn,processedNodeManager:St,canvasManager:mn,ignoreCSSAttributes:B,plugins:N?.filter(le=>le.observer)?.map(le=>({observer:le.observer,options:le.options,callback:Fr=>ve({type:ee.Plugin,data:{plugin:le.name,payload:Fr}})}))||[]},{});Ne.addLoadListener(Fe=>{try{ue.push(ct(Fe.contentDocument))}catch(le){console.warn(le)}});const ie=()=>{ko(),ue.push(ct(document))};return document.readyState==="interactive"||document.readyState==="complete"?ie():(ue.push(Ge("DOMContentLoaded",()=>{ve({type:ee.DomContentLoaded,data:{}}),F==="DOMContentLoaded"&&ie()})),ue.push(Ge("load",()=>{ve({type:ee.Load,data:{}}),F==="load"&&ie()},window))),()=>{ue.forEach(Fe=>Fe()),St.destroy(),Xs=void 0,BI()}}catch(ue){console.warn(ue)}}function s1(e){if(!Xs)throw new Error("please take full snapshot after start recording");Xs(e)}Ft.mirror=ut;Ft.takeFullSnapshot=s1;function o1(e,t){try{return e?e(t):new ed}catch{return console.warn("Unable to initialize CanvasManager"),new ed}}var td;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(td||(td={}));const a1=3,c1=5;function su(e){return e>9999999999?e:e*1e3}function Ko(e){return e>9999999999?e/1e3:e}function Ci(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:ee.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:Ze(t,10,1e3)}}),t.category==="console")))}const u1="button,a";function gm(e){return e.closest(u1)||e}function _m(e){const t=ym(e);return!t||!(t instanceof Element)?t:gm(t)}function ym(e){return l1(e)?e.target:e}function l1(e){return typeof e=="object"&&!!e&&"target"in e}let Qt;function d1(e){return Qt||(Qt=[],f1()),Qt.push(e),()=>{const t=Qt?Qt.indexOf(e):-1;t>-1&&Qt.splice(t,1)}}function f1(){ze(ge,"open",function(e){return function(...t){if(Qt)try{Qt.forEach(n=>n())}catch{}return e.apply(ge,t)}})}const h1=new Set([V.Mutation,V.StyleSheetRule,V.StyleDeclaration,V.AdoptedStyleSheet,V.CanvasMutation,V.Selection,V.MediaInteraction]);function p1(e,t,n){e.handleClick(t,n)}class m1{constructor(t,n,r=Ci){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=n.timeout/1e3,this._threshold=n.threshold/1e3,this._scrollTimeout=n.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=n.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){const t=d1(()=>{this._lastMutation=nd()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,n){if(_1(n,this._ignoreSelector)||!y1(t))return;const r={timestamp:Ko(t.timestamp),clickBreadcrumb:t,clickCount:0,node:n};this._clicks.some(i=>i.node===r.node&&Math.abs(i.timestamp-r.timestamp)<1)||(this._clicks.push(r),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=Ko(t)}registerScroll(t=Date.now()){this._lastScroll=Ko(t)}registerClick(t){const n=gm(t);this._handleMultiClick(n)}_handleMultiClick(t){this._getClicks(t).forEach(n=>{n.clickCount++})}_getClicks(t){return this._clicks.filter(n=>n.node===t)}_checkClicks(){const t=[],n=nd();this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=n&&t.push(r)});for(const r of t){const i=this._clicks.indexOf(r);i>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(i,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const n=this._replay,r=t.scrollAfter&&t.scrollAfter<=this._scrollTimeout,i=t.mutationAfter&&t.mutationAfter<=this._threshold,s=!r&&!i,{clickCount:o,clickBreadcrumb:a}=t;if(s){const c=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,u=c<this._timeout*1e3?"mutation":"timeout",d={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:ge.location.href,route:n.getCurrentRoute(),timeAfterClickMs:c,endReason:u,clickCount:o||1}};this._addBreadcrumbEvent(n,d);return}if(o>1){const c={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:ge.location.href,route:n.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(n,c)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=xi(()=>this._checkClicks(),1e3)}}const g1=["A","BUTTON","INPUT"];function _1(e,t){return!!(!g1.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function y1(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function nd(){return Date.now()/1e3}function b1(e,t){try{if(!S1(t))return;const{source:n}=t.data;if(h1.has(n)&&e.registerMutation(t.timestamp),n===V.Scroll&&e.registerScroll(t.timestamp),E1(t)){const{type:r,id:i}=t.data,s=Ft.mirror.getNode(i);s instanceof HTMLElement&&r===Ue.Click&&e.registerClick(s)}}catch{}}function S1(e){return e.type===a1}function E1(e){return e.data.source===V.MouseInteraction}function It(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var ou=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(ou||{});const v1=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function w1(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(v1.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const T1=e=>t=>{if(!e.isEnabled())return;const n=I1(t);if(!n)return;const r=t.name==="click",i=r?t.event:void 0;r&&e.clickDetector&&i?.target&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&p1(e.clickDetector,n,_m(t.event)),Ci(e,n)};function bm(e,t){const n=Ft.mirror.getId(e),r=n&&Ft.mirror.getNode(n),i=r&&Ft.mirror.getMeta(r),s=i&&k1(i)?i:null;return{message:t,data:s?{nodeId:n,node:{id:n,tagName:s.tagName,textContent:Array.from(s.childNodes).map(o=>o.type===ou.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:w1(s.attributes)}}:{}}}function I1(e){const{target:t,message:n}=x1(e);return It({category:`ui.${e.name}`,...bm(t,n)})}function x1(e){const t=e.name==="click";let n,r=null;try{r=t?_m(e.event):ym(e.event),n=st(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function k1(e){return e.type===ou.Element}function C1(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=R1(t);n&&Ci(e,n)}function R1(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:s,target:o}=e;if(!o||A1(o)||!s)return null;const a=t||r||i,c=s.length===1;if(!a&&c)return null;const u=st(o,{maxStringLength:200})||"<unknown>",d=bm(o,u);return It({category:"ui.keyDown",message:u,data:{...d.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:s}})}function A1(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const M1={resource:D1,paint:L1,navigation:P1};function Yi(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function N1(e){return e.map(O1).filter(Boolean)}function O1(e){const t=M1[e.entryType];return t?t(e):null}function Sr(e){return((Be()||ge.performance.timeOrigin)+e)/1e3}function L1(e){const{duration:t,entryType:n,name:r,startTime:i}=e,s=Sr(i);return{type:n,name:r,start:s,end:s+t,data:void 0}}function P1(e){const{entryType:t,name:n,decodedBodySize:r,duration:i,domComplete:s,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:u,loadEventStart:d,loadEventEnd:l,redirectCount:f,startTime:h,transferSize:p,type:m}=e;return i===0?null:{type:`${t}.${m}`,start:Sr(h),end:Sr(s),name:n,data:{size:p,decodedBodySize:r,encodedBodySize:o,duration:i,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:d,loadEventEnd:l,domComplete:s,redirectCount:f}}}function D1(e){const{entryType:t,initiatorType:n,name:r,responseEnd:i,startTime:s,decodedBodySize:o,encodedBodySize:a,responseStatus:c,transferSize:u}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:Sr(s),end:Sr(i),name:r,data:{size:u,statusCode:c,decodedBodySize:o,encodedBodySize:a}}}function F1(e){const t=e.entries[e.entries.length-1],n=t?.element?[t.element]:void 0;return So(e,"largest-contentful-paint",n)}function H1(e){return e.sources!==void 0}function B1(e){const t=[],n=[];for(const r of e.entries)if(H1(r)){const i=[];for(const s of r.sources)if(s.node){n.push(s.node);const o=Ft.mirror.getId(s.node);o&&i.push(o)}t.push({value:r.value,nodeIds:i.length?i:void 0})}return So(e,"cumulative-layout-shift",n,t)}function U1(e){const t=e.entries[e.entries.length-1],n=t?.target?[t.target]:void 0;return So(e,"first-input-delay",n)}function $1(e){const t=e.entries[e.entries.length-1],n=t?.target?[t.target]:void 0;return So(e,"interaction-to-next-paint",n)}function So(e,t,n,r){const i=e.value,s=e.rating,o=Sr(i);return{type:"web-vital",name:t,start:o,end:o,data:{value:i,size:i,rating:s,nodeIds:n?n.map(a=>Ft.mirror.getId(a)):void 0,attributions:r}}}function W1(e){function t(i){e.performanceEntries.includes(i)||e.performanceEntries.push(i)}function n({entries:i}){i.forEach(t)}const r=[];return["navigation","paint","resource"].forEach(i=>{r.push(On(i,n))}),r.push(jc(Yi(F1,e)),zc(Yi(B1,e)),bp(Yi(U1,e)),Sp(Yi($1,e))),()=>{r.forEach(i=>i())}}const z=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,G1='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),s=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),a=function(t,e){for(var i=new n(31),s=0;s<31;++s)i[s]=e+=1<<t[s-1];var a=new r(i[30]);for(s=1;s<30;++s)for(var o=i[s];o<i[s+1];++o)a[o]=o-i[s]<<5|s;return{b:i,r:a}},o=a(e,2),h=o.b,f=o.r;h[28]=258,f[258]=28;for(var l=a(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,s=0,a=new n(r);s<i;++s)t[s]&&++a[t[s]-1];var o,h=new n(r);for(s=1;s<r;++s)h[s]=h[s-1]+a[s-1]<<1;if(e){o=new n(1<<r);var f=15-r;for(s=0;s<i;++s)if(t[s])for(var l=s<<4|t[s],c=r-t[s],v=h[t[s]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>f]=l}else for(o=new n(i),s=0;s<i;++s)t[s]&&(o[s]=u[h[t[s]-1]++]>>15-t[s]);return o},p=new t(288);for(c=0;c<144;++c)p[c]=8;for(c=144;c<256;++c)p[c]=9;for(c=256;c<280;++c)p[c]=7;for(c=280;c<288;++c)p[c]=8;var g=new t(32);for(c=0;c<32;++c)g[c]=5;var w=d(p,9,0),y=d(g,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],s=0;s<r.length;++s)r[s]&&i.push({s:s,f:r[s]});var a=i.length,o=i.slice();if(!a)return{t:F,l:0};if(1==a){var h=new t(i[0].s+1);return h[i[0].s]=1,{t:h,l:1}}i.sort(function(t,n){return t.f-n.f}),i.push({s:-1,f:25001});var f=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:f.f+l.f,l:f,r:l};c!=a-1;)f=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:f.f+l.f,l:f,r:l};var d=o[0].s;for(s=1;s<a;++s)o[s].s>d&&(d=o[s].s);var p=new n(d+1),g=A(i[c-1],p,0);if(g>e){s=0;var w=0,y=g-e,m=1<<y;for(o.sort(function(t,n){return p[n.s]-p[t.s]||t.f-n.f});s<a;++s){var b=o[s].s;if(!(p[b]>e))break;w+=m-(1<<g-p[b]),p[b]=e}for(w>>=y;w>0;){var M=o[s].s;p[M]<e?w-=1<<e-p[M]++-1:++s}for(;s>=0&&w;--s){var E=o[s].s;p[E]==e&&(--p[E],++w)}g=e}return{t:new t(p),l:g}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,s=t[0],a=1,o=function(t){e[i++]=t},h=1;h<=r;++h)if(t[h]==s&&h!=r)++a;else{if(!s&&a>2){for(;a>138;a-=138)o(32754);a>2&&(o(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(o(s),--a;a>6;a-=6)o(8304);a>2&&(o(a-3<<5|8208),a=0)}for(;a--;)o(s);a=1,s=t[h]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var s=0;s<e;++s)t[i+s+4]=r[s];return 8*(i+4+e)},U=function(t,r,a,o,h,f,l,u,c,v,m){z(r,m++,a),++h[256];for(var b=x(h,15),M=b.t,E=b.l,A=x(f,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[s[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(h,p)+T(f,g)+l,X=T(h,M)+T(f,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[s[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=w,P=p,Q=y,R=g;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,s=0|r.length,a=0;a!=s;){for(var o=Math.min(a+2655,s);a<o;++a)i+=e+=r[a];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},L=function(s,a,o,h,u){if(!u&&(u={l:1},a.dictionary)){var c=a.dictionary.subarray(-32768),v=new t(c.length+s.length);v.set(c),v.set(s,c.length),s=v,u.w=c.length}return function(s,a,o,h,u,c){var v=c.z||s.length,d=new t(h+v+5*(1+Math.ceil(v/7e3))+u),p=d.subarray(h,d.length-u),g=c.l,w=7&(c.r||0);if(a){w&&(p[0]=c.r>>3);for(var y=C[a-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(s[t]^s[t+1]<<A^s[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!g)){w=U(s,p,0,F,I,S,O,q,G,j-G,w),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(s[j+Q]==s[j+Q-W]){for(var $=0;$<Z&&s[j+$]==s[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|f[Q]<<18|l[R];var it=31&f[Q],st=31&l[R];O+=e[it]+i[st],++I[257+it],++S[st],B=j+Q,++L}else F[q++]=s[j],++I[s[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=s[j],++I[s[j]];w=U(s,p,g,F,I,S,O,q,G,j-G,w),g||(c.r=7&w|p[w/8|0]<<3,w-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+g;j+=65535){var at=j+65535;at>=v&&(p[w/8|0]=g,at=v),w=k(p,w+1,s.subarray(j,at))}c.i=v}return b(d,0,h+m(w)+u)}(s,null==a.level?6:a.level,null==a.mem?u.l?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(s.length)))):20:12+a.mem,o,h,u)},O=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},j=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(L(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var s=this.b.length-this.s.z;this.b.set(n.subarray(0,s),this.s.z),this.s.z=this.b.length,this.p(this.b,!1),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(s),32768),this.s.z=n.length-s+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n.prototype.flush=function(){this.ondata||E(5),this.s.l&&E(4),this.p(this.b,!1),this.s.w=this.s.i,this.s.i-=2},n}();function q(t,n){n||(n={});var r=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}}(),e=t.length;r.p(t);var i,s=L(t,n,10+((i=n).filename?i.filename.length+1:0),8),a=s.length;return function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&O(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}}(s,n),O(s,a-8,r.d()),O(s,a-4,e),s}var B=function(){function t(t,n){this.c=S(),this.v=1,j.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),j.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=L(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=S();i.p(n.dictionary),O(t,2,i.d())}}(r,this.o),this.v=0),n&&O(r,r.length-4,this.c.d()),this.ondata(r,n)},t.prototype.flush=function(){j.prototype.flush.call(this)},t}(),G="undefined"!=typeof TextEncoder&&new TextEncoder,H="undefined"!=typeof TextDecoder&&new TextDecoder;try{H.decode(F,{stream:!0})}catch(t){}var J=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(K(t),this.d=n||!1)},t}();function K(n,r){if(G)return G.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),s=0,a=function(t){i[s++]=t},o=0;o<e;++o){if(s+5>i.length){var h=new t(s+8+(e-o<<1));h.set(i),i=h}var f=n.charCodeAt(o);f<128||r?a(f):f<2048?(a(192|f>>6),a(128|63&f)):f>55295&&f<57344?(a(240|(f=65536+(1047552&f)|1023&n.charCodeAt(++o))>>18),a(128|f>>12&63),a(128|f>>6&63),a(128|63&f)):(a(224|f>>12),a(128|f>>6&63),a(128|63&f))}return b(i,0,s)}const N=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new B,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new J((t,n)=>{this.deflate.push(t,n)}),this.stream.push("[")}},P={clear:()=>{N.clear()},addEvent:t=>N.addEvent(t),finish:()=>N.finish(),compress:t=>function(t){return q(K(t))}(t)};addEventListener("message",function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in P&&"function"==typeof P[n])try{const t=P[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}}),postMessage({id:void 0,method:"init",success:!0,response:void 0});';function z1(){const e=new Blob([G1]);return URL.createObjectURL(e)}const rd=["log","warn","error"],ys="[Replay] ";function Zo(e,t="info"){Ct({category:"console",data:{logger:"replay"},level:t,message:`${ys}${e}`},{level:t})}function j1(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=!!r.captureExceptions,t=!!r.traceInternals}};return z?(rd.forEach(r=>{n[r]=(...i)=>{y[r](ys,...i),t&&Zo(i.join(""),Oc(r))}}),n.exception=(r,...i)=>{i.length&&n.error&&n.error(...i),y.error(ys,r),e?Nn(r):t&&Zo(r,"error")},n.infoTick=(...r)=>{y.log(ys,...r),t&&setTimeout(()=>Zo(r[0]),0)}):rd.forEach(r=>{n[r]=()=>{}}),n}const j=j1();class au extends Error{constructor(){super(`Event buffer exceeded maximum size of ${Qc}.`)}}class Sm{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(t){const n=JSON.stringify(t).length;if(this._totalSize+=n,this._totalSize>Qc)throw new au;this.events.push(t)}finish(){return new Promise(t=>{const n=this.events;this.clear(),t(JSON.stringify(n))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(n=>n.timestamp).sort()[0];return t?su(t):null}}class q1{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,n)=>{this._worker.addEventListener("message",({data:r})=>{r.success?t():n()},{once:!0}),this._worker.addEventListener("error",r=>{n(r)},{once:!0})}),this._ensureReadyPromise)}destroy(){z&&j.log("Destroying compression worker"),this._worker.terminate()}postMessage(t,n){const r=this._getAndIncrementId();return new Promise((i,s)=>{const o=({data:a})=>{const c=a;if(c.method===t&&c.id===r){if(this._worker.removeEventListener("message",o),!c.success){z&&j.error("Error in compression worker: ",c.response),s(new Error("Error in compression worker"));return}i(c.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:r,method:t,arg:n})})}_getAndIncrementId(){return this._id++}}class V1{constructor(t){this._worker=new q1(t),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(t){const n=su(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>Qc?Promise.reject(new au):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{z&&j.exception(t,'Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class X1{constructor(t){this._fallback=new Sm,this._compression=new V1(t),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(t){this._used.hasCheckout=t}set waitForCheckout(t){this._used.waitForCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(t){z&&j.exception(t,"Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:n,waitForCheckout:r}=this._fallback,i=[];for(const s of t)i.push(this._compression.addEvent(s));this._compression.hasCheckout=n,this._compression.waitForCheckout=r,this._used=this._compression;try{await Promise.all(i),this._fallback.clear()}catch(s){z&&j.exception(s,"Failed to add events when switching buffers.")}}}function Y1({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=J1(t);if(n)return n}return z&&j.log("Using simple buffer"),new Sm}function J1(e){try{const t=e||K1();if(!t)return;z&&j.log(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new X1(n)}catch(t){z&&j.exception(t,"Failed to create compression worker")}}function K1(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?z1():""}function cu(){try{return"sessionStorage"in ge&&!!ge.sessionStorage}catch{return!1}}function Z1(e){Q1(),e.session=void 0}function Q1(){if(cu())try{ge.sessionStorage.removeItem(Kc)}catch{}}function Em(e){return e===void 0?!1:Math.random()<e}function uu(e){if(cu())try{ge.sessionStorage.setItem(Kc,JSON.stringify(e))}catch{}}function vm(e){const t=Date.now(),n=e.id||je(),r=e.started||t,i=e.lastActivity||t,s=e.segmentId||0,o=e.sampled,a=e.previousSessionId;return{id:n,started:r,lastActivity:i,segmentId:s,sampled:o,previousSessionId:a}}function ex(e,t){return Em(e)?"session":t?"buffer":!1}function id({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const i=ex(e,t),s=vm({sampled:i,previousSessionId:r});return n&&uu(s),s}function tx(){if(!cu())return null;try{const e=ge.sessionStorage.getItem(Kc);if(!e)return null;const t=JSON.parse(e);return z&&j.infoTick("Loading existing session"),vm(t)}catch{return null}}function Ka(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function wm(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return Ka(e.started,t,r)||Ka(e.lastActivity,n,r)}function Tm(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!wm(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function Qo({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const i=r.stickySession&&tx();return i?Tm(i,{sessionIdleExpire:e,maxReplayDuration:t})?(z&&j.infoTick("Session in sessionStorage is expired, creating new one..."),id(r,{previousSessionId:i.id})):i:(z&&j.infoTick("Creating new session"),id(r,{previousSessionId:n}))}function nx(e){return e.type===ee.Custom}function lu(e,t,n){return xm(e,t)?(Im(e,t,n),!0):!1}function rx(e,t,n){return xm(e,t)?Im(e,t,n):Promise.resolve(null)}async function Im(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const i=e.recordingMode==="buffer";try{n&&i&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const s=e.getOptions(),o=ix(t,s.beforeAddRecordingEvent);return o?await r.addEvent(o):void 0}catch(s){const o=s&&s instanceof au,a=o?"addEventSizeExceeded":"addEvent";if(o&&i)return r.clear(),r.waitForCheckout=!0,null;e.handleException(s),await e.stop({reason:a});const c=H();c&&c.recordDroppedEvent("internal_sdk_error","replay")}}function xm(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=su(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(z&&j.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function ix(e,t){try{if(typeof t=="function"&&nx(e))return t(e)}catch(n){return z&&j.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function du(e){return!e.type}function Za(e){return e.type==="transaction"}function sx(e){return e.type==="replay_event"}function sd(e){return e.type==="feedback"}function ox(e){return(t,n)=>{if(!e.isEnabled()||!du(t)&&!Za(t))return;const r=n?.statusCode;if(!(!r||r<200||r>=300)){if(Za(t)){ax(e,t);return}cx(e,t)}}}function ax(e,t){const n=e.getContext();t.contexts?.trace?.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function cx(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();typeof r=="function"&&!r(t)||xi(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(i){e.handleException(i)}})}function ux(e){return t=>{!e.isEnabled()||!du(t)||lx(e,t)}}function lx(e,t){const n=t.exception?.values?.[0]?.value;if(typeof n=="string"&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){const r=It({category:"replay.hydrate-error",data:{url:Pn()}});Ci(e,r)}}function dx(e){const t=H();t&&t.on("beforeAddBreadcrumb",n=>fx(e,n))}function fx(e,t){if(!e.isEnabled()||!km(t))return;const n=hx(t);n&&Ci(e,n)}function hx(e){return!km(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?px(e):It(e)}function px(e){const t=e.data?.arguments;if(!Array.isArray(t)||t.length===0)return It(e);let n=!1;const r=t.map(i=>{if(!i)return i;if(typeof i=="string")return i.length>ji?(n=!0,`${i.slice(0,ji)}…`):i;if(typeof i=="object")try{const s=Ze(i,7);return JSON.stringify(s).length>ji?(n=!0,`${JSON.stringify(s,null,2).slice(0,ji)}…`):s}catch{}return i});return It({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function km(e){return!!e.category}function mx(e,t){return e.type||!e.exception?.values?.length?!1:!!t.originalException?.__rrweb__}function Cm(){const e=Q().getPropagationContext().dsc;e&&delete e.replay_id;const t=Pe();if(t){const n=gt(t);delete n.replay_id}}function gx(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:ee.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function _x(e,t){return e.recordingMode!=="buffer"||t.message===Zc||!t.exception||t.type?!1:Em(e.getOptions().errorSampleRate)}function yx(e){return Object.assign((t,n)=>!e.isEnabled()||e.isPaused()?t:sx(t)?(delete t.breadcrumbs,t):!du(t)&&!Za(t)&&!sd(t)?t:e.checkAndHandleExpiredSession()?sd(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),gx(e,t),t):mx(t,n)&&!e.getOptions()._experiments.captureExceptions?(z&&j.log("Ignoring error from rrweb internals",t),null):((_x(e,t)||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(Cm(),t),{id:"Replay"})}function Eo(e,t){return t.map(({type:n,start:r,end:i,name:s,data:o})=>{const a=e.throttledAddEvent({type:ee.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:n,description:s,startTimestamp:r,endTimestamp:i,data:o}}});return typeof a=="string"?Promise.resolve(null):a})}function bx(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function Sx(e){return t=>{if(!e.isEnabled())return;const n=bx(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(Eo(e,[n]),!1)))}}function Ex(e,t){return z&&e.getOptions()._experiments.traceInternals?!1:Th(t,H())}function Rm(e,t){e.isEnabled()&&t!==null&&(Ex(e,t.name)||e.addUpdate(()=>(Eo(e,[t]),!0)))}function vo(e){if(!e)return;const t=new TextEncoder;try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=kp(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function Am(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function Ys(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function Mm(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:i,method:s,statusCode:o,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:i,data:{method:s,statusCode:o,request:a,response:c}}}function ai(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function rn(e,t,n){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:i,warnings:s}=vx(n);return r.body=i,s?.length&&(r._meta={warnings:s}),r}function Qa(e,t){return Object.entries(e).reduce((n,[r,i])=>{const s=r.toLowerCase();return t.includes(s)&&e[r]&&(n[s]=i),n},{})}function vx(e){if(!e||typeof e!="string")return{body:e};const t=e.length>Bl,n=wx(e);if(t){const r=e.slice(0,Bl);return n?{body:r,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${r}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function wx(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function Js(e,t){const n=Tx(e);return pt(n,t)}function Tx(e,t=ge.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(ge.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function Ix(e,t,n){try{const r=await kx(e,t,n),i=Mm("resource.fetch",r);Rm(n.replay,i)}catch(r){z&&j.exception(r,"Failed to capture fetch breadcrumb")}}function xx(e,t){const{input:n,response:r}=t,i=n?Yc(n):void 0,s=vo(i),o=r?Am(r.headers.get("content-length")):void 0;s!==void 0&&(e.data.request_body_size=s),o!==void 0&&(e.data.response_body_size=o)}async function kx(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:s=r}=t,{url:o,method:a,status_code:c=0,request_body_size:u,response_body_size:d}=e.data,l=Js(o,n.networkDetailAllowUrls)&&!Js(o,n.networkDetailDenyUrls),f=l?Cx(n,t.input,u):ai(u),h=await Rx(l,n,t.response,d);return{startTimestamp:i,endTimestamp:s,url:o,method:a,statusCode:c,request:f,response:h}}function Cx({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const i=n?Nx(n,t):{};if(!e)return rn(i,r,void 0);const s=Yc(n),[o,a]=Ws(s,j),c=rn(i,r,o);return a?Ys(c,a):c}async function Rx(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,i){if(!e&&i!==void 0)return ai(i);const s=r?Nm(r.headers,n):{};if(!r||!t&&i!==void 0)return rn(s,i,void 0);const[o,a]=await Mx(r),c=Ax(o,{networkCaptureBodies:t,responseBodySize:i,captureDetails:e,headers:s});return a?Ys(c,a):c}function Ax(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:i}){try{const s=e?.length&&n===void 0?vo(e):n;return r?t?rn(i,s,e):rn(i,s,void 0):ai(s)}catch(s){return z&&j.exception(s,"Failed to serialize response body"),rn(i,n,void 0)}}async function Mx(e){const t=Ox(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await Lx(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(z&&j.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(z&&j.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function Nm(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}function Nx(e,t){return e.length===1&&typeof e[0]!="string"?od(e[0],t):e.length===2?od(e[1],t):{}}function od(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?Nm(n,t):Array.isArray(n)?{}:Qa(n,t):{}}function Ox(e){try{return e.clone()}catch(t){z&&j.exception(t,"Failed to clone response body")}}function Lx(e){return new Promise((t,n)=>{const r=xi(()=>n(new Error("Timeout while trying to read response body")),500);Px(e).then(i=>t(i),i=>n(i)).finally(()=>clearTimeout(r))})}async function Px(e){return await e.text()}async function Dx(e,t,n){try{const r=Hx(e,t,n),i=Mm("resource.xhr",r);Rm(n.replay,i)}catch(r){z&&j.exception(r,"Failed to capture xhr breadcrumb")}}function Fx(e,t){const{xhr:n,input:r}=t;if(!n)return;const i=vo(r),s=n.getResponseHeader("content-length")?Am(n.getResponseHeader("content-length")):Wx(n.response,n.responseType);i!==void 0&&(e.data.request_body_size=i),s!==void 0&&(e.data.response_body_size=s)}function Hx(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:s=r,input:o,xhr:a}=t,{url:c,method:u,status_code:d=0,request_body_size:l,response_body_size:f}=e.data;if(!c)return null;if(!a||!Js(c,n.networkDetailAllowUrls)||Js(c,n.networkDetailDenyUrls)){const T=ai(l),C=ai(f);return{startTimestamp:i,endTimestamp:s,url:c,method:u,statusCode:d,request:T,response:C}}const h=a[Lt],p=h?Qa(h.request_headers,n.networkRequestHeaders):{},m=Qa(Bx(a),n.networkResponseHeaders),[g,_]=n.networkCaptureBodies?Ws(o,j):[void 0],[v,L]=n.networkCaptureBodies?Ux(a):[void 0],A=rn(p,l,g),O=rn(m,f,v);return{startTimestamp:i,endTimestamp:s,url:c,method:u,statusCode:d,request:_?Ys(A,_):A,response:L?Ys(O,L):O}}function Bx(e){const t=e.getAllResponseHeaders();return t?t.split(`\r
496
+ `).reduce((n,r)=>{const[i,s]=r.split(": ");return s&&(n[i.toLowerCase()]=s),n},{}):{}}function Ux(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return $x(e.response,e.responseType)}catch(n){t.push(n)}return z&&j.warn("Failed to get xhr response body",...t),[void 0]}function $x(e,t){try{if(typeof e=="string")return[e];if(e instanceof Document)return[e.body.outerHTML];if(t==="json"&&e&&typeof e=="object")return[JSON.stringify(e)];if(!e)return[void 0]}catch(n){return z&&j.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return z&&j.log("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function Wx(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return vo(n)}catch{return}}function Gx(e){const t=H();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o};t&&t.on("beforeAddBreadcrumb",(c,u)=>zx(a,c,u))}catch{}}function zx(e,t,n){if(t.data)try{jx(t)&&Vx(n)&&(Fx(t,n),Dx(t,n,e)),qx(t)&&Xx(n)&&(xx(t,n),Ix(t,n,e))}catch(r){z&&j.exception(r,"Error when enriching network breadcrumb")}}function jx(e){return e.category==="xhr"}function qx(e){return e.category==="fetch"}function Vx(e){return e?.xhr}function Xx(e){return e?.response}function Yx(e){const t=H();xp(T1(e)),go(Sx(e)),dx(e),Gx(e);const n=yx(e);ah(n),t&&(t.on("beforeSendEvent",ux(e)),t.on("afterSendEvent",ox(e)),t.on("createDsc",r=>{const i=e.getSessionId();i&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(r.replay_id=i)}),t.on("spanStart",r=>{e.lastActiveSpan=r}),t.on("spanEnd",r=>{e.lastActiveSpan=r}),t.on("beforeSendFeedback",async(r,i)=>{const s=e.getSessionId();i?.includeReplay&&e.isEnabled()&&s&&r.contexts?.feedback&&(r.contexts.feedback.source==="api"&&await e.sendBufferedReplayOrFlush(),r.contexts.feedback.replay_id=s)}),t.on("openFeedbackWidget",async()=>{await e.sendBufferedReplayOrFlush()}))}async function Jx(e){try{return Promise.all(Eo(e,[Kx(ge.performance.memory)]))}catch{return[]}}function Kx(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,i=Date.now()/1e3;return{type:"memory",name:"memory",start:i,end:i,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function Zx(e,t,n){return kb(e,t,{...n,setTimeoutImpl:xi})}const Ji=q.navigator;function Qx(){return/iPhone|iPad|iPod/i.test(Ji?.userAgent??"")||/Macintosh/i.test(Ji?.userAgent??"")&&Ji?.maxTouchPoints&&Ji?.maxTouchPoints>1?{sampling:{mousemove:!1}}:{}}function ek(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){z&&j.warn("Received replay event after session expired.");return}const i=r||!t;t=!0,e.clickDetector&&b1(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&i&&e.setInitialState(),!lu(e,n,i))return!0;if(!i)return!1;const s=e.session;if(nk(e,i),e.recordingMode==="buffer"&&s&&e.eventBuffer){const o=e.eventBuffer.getEarliestTimestamp();o&&(z&&j.log(`Updating session start time to earliest event in buffer to ${new Date(o)}`),s.started=o,e.getOptions().stickySession&&uu(s))}return s?.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function tk(e){const t=e.getOptions();return{type:ee.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:e.eventBuffer?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function nk(e,t){!t||!e.session||e.session.segmentId!==0||lu(e,tk(e),!1)}function rk(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function ik(e,t,n,r){return Xt(Kf(e,Ic(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function sk({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}
497
+ `;if(typeof e=="string")n=`${r}${e}`;else{const s=new TextEncoder().encode(r);n=new Uint8Array(s.length+e.length),n.set(s),n.set(e,s.length)}return n}async function ok({client:e,scope:t,replayId:n,event:r}){const i=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,s={event_id:n,integrations:i};e.emit("preprocessEvent",r,s);const o=await rh(e.getOptions(),r,s,t,e,Le());if(!o)return null;e.emit("postprocessEvent",o,s),o.platform=o.platform||"javascript";const a=e.getSdkMetadata(),{name:c,version:u}=a?.sdk||{};return o.sdk={...o.sdk,name:c||"sentry.javascript.unknown",version:u||"0.0.0"},o}async function ak({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:i,session:s}){const o=sk({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:c,traceIds:u,initialTimestamp:d}=r,l=H(),f=Q(),h=l?.getTransport(),p=l?.getDsn();if(!l||!h||!p||!s.sampled)return zt({});const m={type:DT,replay_start_timestamp:d/1e3,timestamp:i/1e3,error_ids:c,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:s.sampled},g=await ok({scope:f,client:l,replayId:t,event:m});if(!g)return l.recordDroppedEvent("event_processor","replay"),z&&j.log("An event processor returned `null`, will not send event."),zt({});delete g.sdkProcessingMetadata;const _=ik(g,o,p,l.getOptions().tunnel);let v;try{v=await h.send(_)}catch(A){const O=new Error(Zc);try{O.cause=A}catch{}throw O}if(typeof v.statusCode=="number"&&(v.statusCode<200||v.statusCode>=300))throw new Om(v.statusCode);const L=Eh({},v);if(Sh(L,"replay"))throw new fu(L);return v}class Om extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class fu extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function Lm(e,t={count:0,interval:WT}){const{recordingData:n,onError:r}=e;if(n.length)try{return await ak(e),!0}catch(i){if(i instanceof Om||i instanceof fu)throw i;if(ih("Replays",{_retryCount:t.count}),r&&r(i),t.count>=GT){const s=new Error(`${Zc} - max retries exceeded`);try{s.cause=i}catch{}throw s}return t.interval*=++t.count,new Promise((s,o)=>{xi(async()=>{try{await Lm(e,t),s(!0)}catch(a){o(a)}},t.interval)})}}const Pm="__THROTTLED",ck="__SKIPPED";function uk(e,t,n){const r=new Map,i=a=>{const c=a-n;r.forEach((u,d)=>{d<c&&r.delete(d)})},s=()=>[...r.values()].reduce((a,c)=>a+c,0);let o=!1;return(...a)=>{const c=Math.floor(Date.now()/1e3);if(i(c),s()>=t){const d=o;return o=!0,d?ck:Pm}o=!1;const u=r.get(c)||0;return r.set(c,u+1),e(...a)}}class lk{constructor({options:t,recordingOptions:n}){this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:FT,sessionIdleExpire:HT},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=n,this._options=t,this._debouncedFlush=Zx(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=uk((o,a)=>rx(this,o,a),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:i}=this.getOptions(),s=r?{threshold:Math.min(zT,r),timeout:r,scrollTimeout:jT,ignoreSelector:i?i.join(","):""}:void 0;if(s&&(this.clickDetector=new m1(this,s)),z){const o=t._experiments;j.setConfig({captureExceptions:!!o.captureExceptions,traceInternals:!!o.traceInternals})}this._handleVisibilityChange=()=>{ge.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()},this._handleWindowBlur=()=>{const o=It({category:"ui.blur"});this._doChangeToBackgroundTasks(o)},this._handleWindowFocus=()=>{const o=It({category:"ui.focus"});this._doChangeToForegroundTasks(o)},this._handleKeyboardEvent=o=>{C1(this,o)}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){z&&j.exception(t),this._options.onError&&this._options.onError(t)}initializeSampling(t){const{errorSampleRate:n,sessionSampleRate:r}=this._options,i=n<=0&&r<=0;if(this._requiresManualStart=i,!i){if(this._initializeSessionForSampling(t),!this.session){z&&j.exception(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",z&&j.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session"){z&&j.log("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){z&&j.log("Buffering is in progress, call `flush()` to save the replay");return}z&&j.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=Qo({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this.recordingMode="session",this._initializeRecording()}startBuffering(){if(this._isEnabled){z&&j.log("Buffering is in progress, call `flush()` to save the replay");return}z&&j.infoTick("Starting replay in buffer mode");const t=Qo({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const t=this._canvas;this._stopRecording=Ft({...this._recordingOptions,...this.recordingMode==="buffer"?{checkoutEveryNms:$T}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:ek(this),...Qx(),onMutation:this._onMutationHandler.bind(this),...t?{recordCanvas:t.recordCanvas,getCanvasManager:t.getCanvasManager,sampling:t.sampling,dataURLOptions:t.dataURLOptions}:{}})}catch(t){this.handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this.handleException(t),!1}}async stop({forceFlush:t=!1,reason:n}={}){if(this._isEnabled){this._isEnabled=!1,this.recordingMode="buffer";try{z&&j.log(`Stopping Replay${n?` triggered by ${n}`:""}`),Cm(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer?.destroy(),this.eventBuffer=null,Z1(this)}catch(r){this.handleException(r)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),z&&j.log("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),z&&j.log("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();z&&j.log("Converting buffer to session"),await this.flushImmediate();const r=this.stopRecording();!t||!r||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this._updateUserActivity(n),this._updateSessionActivity(n),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const n=t();this.recordingMode==="buffer"||!this._isEnabled||n!==!0&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return this.recordingMode==="buffer"?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session?.id}checkAndHandleExpiredSession(){if(this._lastActivity&&Ka(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${ge.location.pathname}${ge.location.hash}${ge.location.search}`,n=`${ge.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=n,this._context.initialTimestamp=Date.now(),this._context.urls.push(n)}throttledAddEvent(t,n){const r=this._throttledAddEvent(t,n);if(r===Pm){const i=It({category:"replay.throttled"});this.addUpdate(()=>!lu(this,{type:c1,timestamp:i.timestamp||0,data:{tag:"breadcrumb",payload:i,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||Pe(),n=t&&Oe(t),i=(n&&Z(n).data||{})[tt];if(!(!n||!i||!["route","custom"].includes(i)))return Z(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=Y1({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(t){const n=this._options.errorSampleRate>0,r=Qo({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:n});this.session=r}_checkSession(){if(!this.session)return!1;const t=this.session;return Tm(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{ge.document.addEventListener("visibilitychange",this._handleVisibilityChange),ge.addEventListener("blur",this._handleWindowBlur),ge.addEventListener("focus",this._handleWindowFocus),ge.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(Yx(this),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=W1(this)}_removeListeners(){try{ge.document.removeEventListener("visibilitychange",this._handleVisibilityChange),ge.removeEventListener("blur",this._handleWindowBlur),ge.removeEventListener("focus",this._handleWindowFocus),ge.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}_doChangeToBackgroundTasks(t){!this.session||wm(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){z&&j.log("Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:ee.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){let t=N1(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const n=this._context.initialTimestamp/1e3;t=t.filter(r=>r.start>=n)}return Promise.all(Eo(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:n}=this;if(!t||!n||this._requiresManualStart||t.segmentId)return;const r=n.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}_popEventContext(){const t={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),t}async _runFlush(){const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){z&&j.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!!this.eventBuffer?.hasEvents&&(await Jx(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const n=Date.now();if(n-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const r=this._popEventContext(),i=this.session.segmentId++;this._maybeSaveSession();const s=await this.eventBuffer.finish();await Lm({replayId:t,recordingData:s,segmentId:i,eventContext:r,session:this.session,timestamp:n,onError:o=>this.handleException(o)})}catch(n){this.handleException(n),this.stop({reason:"sendReplay"});const r=H();if(r){const i=n instanceof fu?"ratelimit_backoff":"send_error";r.recordDroppedEvent(i,"replay")}}}async _flush({force:t=!1}={}){if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){z&&j.error("Attempting to finish replay event after session expired.");return}if(!this.session)return;const n=this.session.started,i=Date.now()-n;this._debouncedFlush.cancel();const s=i<this._options.minReplayDuration,o=i>this._options.maxReplayDuration+5e3;if(s||o){z&&j.log(`Session duration (${Math.floor(i/1e3)}s) is too ${s?"short":"long"}, not sending replay.`),s&&this._debouncedFlush();return}const a=this.eventBuffer;a&&this.session.segmentId===0&&!a.hasCheckout&&z&&j.log("Flushing initial segment without checkout.");const c=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(u){this.handleException(u)}finally{this._flushLock=void 0,c&&this._debouncedFlush()}}_maybeSaveSession(){this.session&&this._options.stickySession&&uu(this.session)}_onMutationHandler(t){const{ignoreMutations:n}=this._options._experiments;if(n?.length&&t.some(a=>{const c=rk(a.target),u=n.join(",");return c?.matches(u)}))return!1;const r=t.length,i=this._options.mutationLimit,s=this._options.mutationBreadcrumbLimit,o=i&&r>i;if(r>s||o){const a=It({category:"replay.mutations",data:{count:r,limit:o}});this._createCustomBreadcrumb(a)}return o?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}function Br(e,t){return[...e,...t].join(",")}function dk({mask:e,unmask:t,block:n,unblock:r,ignore:i}){const s=["base","iframe[srcdoc]:not([src])"],o=Br(e,[".sentry-mask","[data-sentry-mask]"]),a=Br(t,[]);return{maskTextSelector:o,unmaskTextSelector:a,blockSelector:Br(n,[".sentry-block","[data-sentry-block]",...s]),unblockSelector:Br(r,[]),ignoreSelector:Br(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function fk({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:i,value:s}){return!r||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?s:n.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?s.replace(/[\S]/g,"*"):s}const ad='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',hk=["content-length","content-type","accept"];let cd=!1;const pk=e=>new mk(e);class mk{constructor({flushMinDelay:t=BT,flushMaxDelay:n=UT,minReplayDuration:r=qT,maxReplayDuration:i=Ul,stickySession:s=!0,useCompression:o=!0,workerUrl:a,_experiments:c={},maskAllText:u=!0,maskAllInputs:d=!0,blockAllMedia:l=!0,mutationBreadcrumbLimit:f=750,mutationLimit:h=1e4,slowClickTimeout:p=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:g=[],networkDetailDenyUrls:_=[],networkCaptureBodies:v=!0,networkRequestHeaders:L=[],networkResponseHeaders:A=[],mask:O=[],maskAttributes:T=["title","placeholder","aria-label"],unmask:C=[],block:M=[],unblock:x=[],ignore:R=[],maskFn:P,beforeAddRecordingEvent:k,beforeErrorSampling:F,onError:X}={}){this.name="Replay";const U=dk({mask:O,unmask:C,block:M,unblock:x,ignore:R});if(this._recordingOptions={maskAllInputs:d,maskAllText:u,maskInputOptions:{password:!0},maskTextFn:P,maskInputFn:P,maskAttributeFn:(J,N,G)=>fk({maskAttributes:T,maskAllText:u,privacyOptions:U,key:J,value:N,el:G}),...U,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:J=>{try{J.__rrweb__=!0}catch{}},recordCrossOriginIframes:!!c.recordCrossOriginIframes},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,VT),maxReplayDuration:Math.min(i,Ul),stickySession:s,useCompression:o,workerUrl:a,blockAllMedia:l,maskAllInputs:d,maskAllText:u,mutationBreadcrumbLimit:f,mutationLimit:h,slowClickTimeout:p,slowClickIgnoreSelectors:m,networkDetailAllowUrls:g,networkDetailDenyUrls:_,networkCaptureBodies:v,networkRequestHeaders:ud(L),networkResponseHeaders:ud(A),beforeAddRecordingEvent:k,beforeErrorSampling:F,onError:X,_experiments:c},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${ad}`:ad),this._isInitialized&&La())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return cd}set _isInitialized(t){cd=t}afterAllSetup(t){!La()||this._replay||(this._setup(t),this._initialize(t))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(t):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(this._replay?.isEnabled())return this._replay.getSessionId()}getRecordingMode(){if(this._replay?.isEnabled())return this._replay.recordingMode}_initialize(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=gk(this._initialOptions,t);this._replay=new lk({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}function gk(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...e},i=An(n.replaysSessionSampleRate),s=An(n.replaysOnErrorSampleRate);return i==null&&s==null&&un(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),i!=null&&(r.sessionSampleRate=i),s!=null&&(r.errorSampleRate=s),r}function ud(e){return[...hk,...e.map(t=>t.toLowerCase())]}function _k(){return H()?.getIntegrationByName("Replay")}var yk=Object.defineProperty,bk=(e,t,n)=>t in e?yk(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ld=(e,t,n)=>bk(e,typeof t!="symbol"?t+"":t,n);class Sk{constructor(){ld(this,"idNodeMap",new Map),ld(this,"nodeMetaMap",new WeakMap)}getId(t){return t?this.getMeta(t)?.id??-1:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const i=this.nodeMetaMap.get(r);i&&this.nodeMetaMap.set(n,i)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Ek(){return new Sk}function vk(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function ec(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:ec(e.parentNode,t,n,r+1)}function dd(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if(vk(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}const Qn=`Please stop import mirror directly. Instead of that,\r
498
+ now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
499
+ or you can use record.mirror to access the mirror instance during recording.`;let fd={map:{},getId(){return console.error(Qn),-1},getNode(){return console.error(Qn),null},removeNodeFromMap(){console.error(Qn)},has(){return console.error(Qn),!1},reset(){console.error(Qn)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(fd=new Proxy(fd,{get(e,t,n){return t==="map"&&console.error(Qn),Reflect.get(e,t,n)}}));function hu(e,t,n,r,i=window){const s=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,r?n:{set(o){Fm(()=>{n.set.call(this,o)},0),s&&s.set&&s.set.call(this,o)}}),()=>hu(e,t,s||{},!0)}function pu(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],i=n(r);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=i,()=>{e[t]=r}}catch{return()=>{}}}Date.now().toString();function wk(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function wo(e,t,n,r,i){if(!e)return!1;const s=wk(e);if(!s)return!1;const o=dd(t,n),a=ec(s,o);let c=-1;return a<0?!1:(r&&(c=ec(s,dd(null,r))),a>-1&&c<0?!0:a<c)}const hd={};function Dm(e){const t=hd[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const s=i.contentWindow;s&&s[e]&&(r=s[e]),n.head.removeChild(i)}catch{}return hd[e]=r.bind(window)}function gn(...e){return Dm("requestAnimationFrame")(...e)}function Fm(...e){return Dm("setTimeout")(...e)}var Er=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(Er||{});let bs;function Tk(e){bs=e}const ea=e=>bs?(...n)=>{try{return e(...n)}catch(r){if(bs&&bs(r)===!0)return()=>{};throw r}}:e;var ir="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Ik=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var Ki=0;Ki<ir.length;Ki++)Ik[ir.charCodeAt(Ki)]=Ki;var xk=function(e){var t=new Uint8Array(e),n,r=t.length,i="";for(n=0;n<r;n+=3)i+=ir[t[n]>>2],i+=ir[(t[n]&3)<<4|t[n+1]>>4],i+=ir[(t[n+1]&15)<<2|t[n+2]>>6],i+=ir[t[n+2]&63];return r%3===2?i=i.substring(0,i.length-1)+"=":r%3===1&&(i=i.substring(0,i.length-2)+"=="),i};const pd=new Map;function kk(e,t){let n=pd.get(e);return n||(n=new Map,pd.set(e,n)),n.has(t)||n.set(t,[]),n.get(t)}const Hm=(e,t,n)=>{if(!e||!(Um(e,t)||typeof e=="object"))return;const r=e.constructor.name,i=kk(n,r);let s=i.indexOf(e);return s===-1&&(s=i.length,i.push(e)),s};function Ss(e,t,n){if(e instanceof Array)return e.map(r=>Ss(r,t,n));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return{rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){const r=e.constructor.name,i=xk(e);return{rr_type:r,base64:i}}else{if(e instanceof DataView)return{rr_type:e.constructor.name,args:[Ss(e.buffer,t,n),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){const r=e.constructor.name,{src:i}=e;return{rr_type:r,src:i}}else if(e instanceof HTMLCanvasElement){const r="HTMLImageElement",i=e.toDataURL();return{rr_type:r,src:i}}else{if(e instanceof ImageData)return{rr_type:e.constructor.name,args:[Ss(e.data,t,n),e.width,e.height]};if(Um(e,t)||typeof e=="object"){const r=e.constructor.name,i=Hm(e,t,n);return{rr_type:r,index:i}}}}return e}const Bm=(e,t,n)=>e.map(r=>Ss(r,t,n)),Um=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(i=>typeof t[i]=="function").find(i=>e instanceof t[i]);function Ck(e,t,n,r,i){const s=[],o=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(const a of o)try{if(typeof t.CanvasRenderingContext2D.prototype[a]!="function")continue;const c=pu(t.CanvasRenderingContext2D.prototype,a,function(u){return function(...d){return wo(this.canvas,n,r,i,!0)||Fm(()=>{const l=Bm(d,t,this);e(this.canvas,{type:Er["2D"],property:a,args:l})},0),u.apply(this,d)}});s.push(c)}catch{const c=hu(t.CanvasRenderingContext2D.prototype,a,{set(u){e(this.canvas,{type:Er["2D"],property:a,args:[u],setter:!0})}});s.push(c)}return()=>{s.forEach(a=>a())}}function Rk(e){return e==="experimental-webgl"?"webgl":e}function md(e,t,n,r,i){const s=[];try{const o=pu(e.HTMLCanvasElement.prototype,"getContext",function(a){return function(c,...u){if(!wo(this,t,n,r,!0)){const d=Rk(c);if("__context"in this||(this.__context=d),i&&["webgl","webgl2"].includes(d))if(u[0]&&typeof u[0]=="object"){const l=u[0];l.preserveDrawingBuffer||(l.preserveDrawingBuffer=!0)}else u.splice(0,1,{preserveDrawingBuffer:!0})}return a.apply(this,[c,...u])}});s.push(o)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{s.forEach(o=>o())}}function gd(e,t,n,r,i,s,o,a){const c=[],u=Object.getOwnPropertyNames(e);for(const d of u)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(d))try{if(typeof e[d]!="function")continue;const l=pu(e,d,function(f){return function(...h){const p=f.apply(this,h);if(Hm(p,a,this),"tagName"in this.canvas&&!wo(this.canvas,r,i,s,!0)){const m=Bm(h,a,this),g={type:t,property:d,args:m};n(this.canvas,g)}return p}});c.push(l)}catch{const l=hu(e,d,{set(f){n(this.canvas,{type:t,property:d,args:[f],setter:!0})}});c.push(l)}return c}function Ak(e,t,n,r,i,s){const o=[];return o.push(...gd(t.WebGLRenderingContext.prototype,Er.WebGL,e,n,r,i,s,t)),typeof t.WebGL2RenderingContext<"u"&&o.push(...gd(t.WebGL2RenderingContext.prototype,Er.WebGL2,e,n,r,i,s,t)),()=>{o.forEach(a=>a())}}const Mk='for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t="undefined"==typeof Uint8Array?[]:new Uint8Array(256),a=0;a<64;a++)t[e.charCodeAt(a)]=a;var n=function(t){var a,n=new Uint8Array(t),r=n.length,s="";for(a=0;a<r;a+=3)s+=e[n[a]>>2],s+=e[(3&n[a])<<4|n[a+1]>>4],s+=e[(15&n[a+1])<<2|n[a+2]>>6],s+=e[63&n[a+2]];return r%3==2?s=s.substring(0,s.length-1)+"=":r%3==1&&(s=s.substring(0,s.length-2)+"=="),s};const r=new Map,s=new Map;const i=self;i.onmessage=async function(e){if(!("OffscreenCanvas"in globalThis))return i.postMessage({id:e.data.id});{const{id:t,bitmap:a,width:o,height:f,maxCanvasSize:c,dataURLOptions:g}=e.data,u=async function(e,t,a){const r=e+"-"+t;if("OffscreenCanvas"in globalThis){if(s.has(r))return s.get(r);const i=new OffscreenCanvas(e,t);i.getContext("2d");const o=await i.convertToBlob(a),f=await o.arrayBuffer(),c=n(f);return s.set(r,c),c}return""}(o,f,g),[h,d]=function(e,t,a){if(!a)return[e,t];const[n,r]=a;if(e<=n&&t<=r)return[e,t];let s=e,i=t;return s>n&&(i=Math.floor(n*t/e),s=n),i>r&&(s=Math.floor(r*e/t),i=r),[s,i]}(o,f,c),l=new OffscreenCanvas(h,d),w=l.getContext("bitmaprenderer"),p=h===o&&d===f?a:await createImageBitmap(a,{resizeWidth:h,resizeHeight:d,resizeQuality:"low"});w?.transferFromImageBitmap(p),a.close();const y=await l.convertToBlob(g),v=y.type,b=await y.arrayBuffer(),m=n(b);if(p.close(),!r.has(t)&&await u===m)return r.set(t,m),i.postMessage({id:t});if(r.get(t)===m)return i.postMessage({id:t});i.postMessage({id:t,type:v,base64:m,width:o,height:f}),r.set(t,m)}};';function Nk(){const e=new Blob([Mk]);return URL.createObjectURL(e)}class Ok{constructor(t){this.pendingCanvasMutations=new Map,this.rafStamps={latestId:0,invokeId:null},this.shadowDoms=new Set,this.windowsSet=new WeakSet,this.windows=[],this.restoreHandlers=[],this.frozen=!1,this.locked=!1,this.snapshotInProgressMap=new Map,this.worker=null,this.lastSnapshotTime=0,this.processMutation=(a,c)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(a)||this.pendingCanvasMutations.set(a,[]),this.pendingCanvasMutations.get(a).push(c)};const{enableManualSnapshot:n,sampling:r="all",win:i,recordCanvas:s,errorHandler:o}=t;t.sampling=r,this.mutationCb=t.mutationCb,this.mirror=t.mirror,this.options=t,o&&Tk(o),(s&&typeof r=="number"||n)&&(this.worker=this.initFPSWorker()),this.addWindow(i),!n&&ea(()=>{s&&r==="all"&&(this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher()),s&&typeof r=="number"&&this.initCanvasFPSObserver()})()}reset(){this.pendingCanvasMutations.clear(),this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.windowsSet=new WeakSet,this.windows=[],this.shadowDoms=new Set,this.worker?.terminate(),this.worker=null,this.snapshotInProgressMap=new Map}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}addWindow(t){const{sampling:n="all",blockClass:r,blockSelector:i,unblockSelector:s,recordCanvas:o,enableManualSnapshot:a}=this.options;if(!this.windowsSet.has(t)){if(a){this.windowsSet.add(t),this.windows.push(new WeakRef(t));return}ea(()=>{if(o&&n==="all"&&this.initCanvasMutationObserver(t,r,i,s),o&&typeof n=="number"){const c=md(t,r,i,s,!0);this.restoreHandlers.push(()=>{c()})}})(),this.windowsSet.add(t),this.windows.push(new WeakRef(t))}}addShadowRoot(t){this.shadowDoms.add(new WeakRef(t))}resetShadowRoots(){this.shadowDoms=new Set}snapshot(t,n){if(n?.skipRequestAnimationFrame){this.takeSnapshot(performance.now(),!0,t);return}gn(r=>this.takeSnapshot(r,!0,t))}initFPSWorker(){const t=new Worker(Nk());return t.onmessage=n=>{const r=n.data,{id:i}=r;if(this.snapshotInProgressMap.set(i,!1),!("base64"in r))return;const{base64:s,type:o,width:a,height:c}=r;this.mutationCb({id:i,type:Er["2D"],commands:[{property:"clearRect",args:[0,0,a,c]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:s}],type:o}]},0,0,a,c]}]})},t}initCanvasFPSObserver(){let t;if(!this.windows.length&&!this.shadowDoms.size)return;const n=r=>{this.takeSnapshot(r,!1),t=gn(n)};t=gn(n),this.restoreHandlers.push(()=>{t&&cancelAnimationFrame(t)})}initCanvasMutationObserver(t,n,r,i){const s=md(t,n,r,i,!1),o=Ck(this.processMutation.bind(this),t,n,r,i),a=Ak(this.processMutation.bind(this),t,n,r,i,this.mirror);this.restoreHandlers.push(()=>{s(),o(),a()})}getCanvasElements(t,n,r){const i=[],s=o=>{o.querySelectorAll("canvas").forEach(a=>{wo(a,t,n,r)||i.push(a)})};for(const o of this.windows){const a=o.deref();let c;try{c=a&&a.document}catch{}c&&s(c)}for(const o of this.shadowDoms){const a=o.deref();a&&s(a)}return i}takeSnapshot(t,n,r){const{sampling:i,blockClass:s,blockSelector:o,unblockSelector:a,dataURLOptions:c,maxCanvasSize:u}=this.options,l=1e3/(i==="all"?2:i||2);return this.lastSnapshotTime&&t-this.lastSnapshotTime<l?!1:(this.lastSnapshotTime=t,(r?[r]:this.getCanvasElements(s,o,a)).forEach(p=>{const m=this.mirror.getId(p);if(!(!this.mirror.hasNode(p)||!p.width||!p.height||this.snapshotInProgressMap.get(m))){if(this.snapshotInProgressMap.set(m,!0),!n&&["webgl","webgl2"].includes(p.__context)){const g=p.getContext(p.__context);g?.getContextAttributes()?.preserveDrawingBuffer===!1&&g.clear(g.COLOR_BUFFER_BIT)}createImageBitmap(p).then(g=>{this.worker?.postMessage({id:m,bitmap:g,width:p.width,height:p.height,dataURLOptions:c,maxCanvasSize:u},[g])}).catch(g=>{ea(()=>{throw this.snapshotInProgressMap.delete(m),g})()})}}),!0)}startPendingCanvasMutationFlusher(){gn(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){const t=n=>{this.rafStamps.latestId=n,gn(t)};gn(t)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,n)=>{const r=this.mirror.getId(n);this.flushPendingCanvasMutationFor(n,r)}),gn(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(t,n){if(this.frozen||this.locked)return;const r=this.pendingCanvasMutations.get(t);if(!r||n===-1)return;const i=r.map(o=>{const{type:a,...c}=o;return c}),{type:s}=r[0];this.mutationCb({id:n,type:s,commands:i}),this.pendingCanvasMutations.delete(t)}}try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=e.contentWindow?.Array.from||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}Ek();var _d;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(_d||(_d={}));const yd={low:{sampling:{canvas:1},dataURLOptions:{type:"image/webp",quality:.25}},medium:{sampling:{canvas:2},dataURLOptions:{type:"image/webp",quality:.4}},high:{sampling:{canvas:4},dataURLOptions:{type:"image/webp",quality:.5}}},Lk="ReplayCanvas",Zi=1280,Pk=(e={})=>{const[t,n]=e.maxCanvasSize||[],r={quality:e.quality||"medium",enableManualSnapshot:e.enableManualSnapshot,maxCanvasSize:[t?Math.min(t,Zi):Zi,n?Math.min(n,Zi):Zi]};let i;const s=new Promise(o=>i=o);return{name:Lk,getOptions(){const{quality:o,enableManualSnapshot:a,maxCanvasSize:c}=r;return{enableManualSnapshot:a,recordCanvas:!0,getCanvasManager:u=>{const d=new Ok({...u,enableManualSnapshot:a,maxCanvasSize:c,errorHandler:l=>{try{typeof l=="object"&&(l.__rrweb__=!0)}catch{}}});return i(d),d},...yd[o]||yd.medium}},async snapshot(o,a){(await s).snapshot(o,a)}}},Dk=Pk;function Et(e=0){return((Be()||performance.timeOrigin)+e)/1e3}function Fk(e){const t=[];if(e.nextHopProtocol!=null){const{name:n,version:r}=wp(e.nextHopProtocol);t.push(["network.protocol.version",r],["network.protocol.name",n])}return Be()?[...t,["http.request.redirect_start",Et(e.redirectStart)],["http.request.fetch_start",Et(e.fetchStart)],["http.request.domain_lookup_start",Et(e.domainLookupStart)],["http.request.domain_lookup_end",Et(e.domainLookupEnd)],["http.request.connect_start",Et(e.connectStart)],["http.request.secure_connection_start",Et(e.secureConnectionStart)],["http.request.connection_end",Et(e.connectEnd)],["http.request.request_start",Et(e.requestStart)],["http.request.response_start",Et(e.responseStart)],["http.request.response_end",Et(e.responseEnd)]]:t}const bd=new WeakMap,ta=new Map,mu={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function $m(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:i,shouldCreateSpanForRequest:s,enableHTTPTimings:o,tracePropagationTargets:a,onRequestSpanStart:c}={...mu,...t},u=typeof s=="function"?s:f=>!0,d=f=>Bk(f,a),l={};n&&(e.addEventProcessor(f=>(f.type==="transaction"&&f.spans&&f.spans.forEach(h=>{if(h.op==="http.client"){const p=ta.get(h.span_id);p&&(h.timestamp=p/1e3,ta.delete(h.span_id))}}),f)),i&&t0(f=>{if(f.response){const h=bd.get(f.response);h&&f.endTimestamp&&ta.set(h,f.endTimestamp)}}),Lc(f=>{const h=WS(f,u,d,l);if(f.response&&f.fetchData.__span&&bd.set(f.response,f.fetchData.__span),h){const p=Wm(f.fetchData.url),m=p?Cn(p).host:void 0;h.setAttributes({"http.url":p,"server.address":m}),o&&Sd(h),c?.(h,{headers:f.headers})}})),r&&Xc(f=>{const h=Uk(f,u,d,l);if(h){o&&Sd(h);let p;try{p=new Headers(f.xhr.__sentry_xhr_v3__?.request_headers)}catch{}c?.(h,{headers:p})}})}function Hk(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function Sd(e){const{url:t}=Z(e).data;if(!t||typeof t!="string")return;const n=On("resource",({entries:r})=>{r.forEach(i=>{Hk(i)&&i.name.endsWith(t)&&(Fk(i).forEach(o=>e.setAttribute(...o)),setTimeout(n))})})}function Bk(e,t){const n=Pn();if(n){let r,i;try{r=new URL(e,n),i=new URL(n).origin}catch{return!1}const s=r.origin===i;return t?pt(r.toString(),t)||s&&pt(r.pathname,t):s}else{const r=!!e.match(/^\/(?!\/)/);return t?pt(e,t):r}}function Uk(e,t,n,r){const i=e.xhr,s=i?.[Lt];if(!i||i.__sentry_own_request__||!s)return;const{url:o,method:a}=s,c=on()&&t(o);if(e.endTimestamp&&c){const m=i.__sentry_xhr_span_id__;if(!m)return;const g=r[m];g&&s.status_code!==void 0&&(ni(g,s.status_code),g.end(),delete r[m]);return}const u=Wm(o),d=Cn(u||o),l=Bh(o),f=!!Pe(),h=c&&f?Bn({name:`${a} ${l}`,attributes:{url:o,type:"xhr","http.method":a,"http.url":u,"server.address":d?.host,[Se]:"auto.http.browser",[rt]:"http.client",...d?.search&&{"http.query":d?.search},...d?.hash&&{"http.fragment":d?.hash}}}):new Gt;i.__sentry_xhr_span_id__=h.spanContext().spanId,r[i.__sentry_xhr_span_id__]=h,n(o)&&$k(i,on()&&f?h:void 0);const p=H();return p&&p.emit("beforeOutgoingRequestSpan",h,e),h}function $k(e,t){const{"sentry-trace":n,baggage:r}=Mc({span:t});n&&Wk(e,n,r)}function Wk(e,t,n){const r=e.__sentry_xhr_v3__?.request_headers;if(!r?.["sentry-trace"])try{if(e.setRequestHeader("sentry-trace",t),n){const i=r?.baggage;(!i||!Gk(i))&&e.setRequestHeader("baggage",n)}}catch{}}function Gk(e){return e.split(",").some(t=>t.trim().startsWith("sentry-"))}function Wm(e){try{return new URL(e,W.location.origin).href}catch{return}}function zk(){W.document?W.document.addEventListener("visibilitychange",()=>{const e=Pe();if(!e)return;const t=Oe(e);if(W.document.hidden&&t){const n="cancelled",{op:r,status:i}=Z(t);ne&&y.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),i||t.setStatus({code:we,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):ne&&y.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const jk=3600,Gm="sentry_previous_trace",qk="sentry.previous_trace";function Vk(e,{linkPreviousTrace:t,consistentTraceSampling:n}){const r=t==="session-storage";let i=r?Jk():void 0;e.on("spanStart",o=>{if(Oe(o)!==o)return;const a=Q().getPropagationContext();i=Xk(i,o,a),r&&Yk(i)});let s=!0;n&&e.on("beforeSampling",o=>{if(!i)return;const a=Q(),c=a.getPropagationContext();if(s&&c.parentSpanId){s=!1;return}a.setPropagationContext({...c,dsc:{...c.dsc,sample_rate:String(i.sampleRate),sampled:String(tc(i.spanContext))},sampleRand:i.sampleRand}),o.parentSampled=tc(i.spanContext),o.parentSampleRate=i.sampleRate,o.spanAttributes={...o.spanAttributes,[Rf]:i.sampleRate}})}function Xk(e,t,n){const r=Z(t);function i(){try{return Number(n.dsc?.sample_rate)??Number(r.data?.[ro])}catch{return 0}}const s={spanContext:t.spanContext(),startTimestamp:r.start_timestamp,sampleRate:i(),sampleRand:n.sampleRand};if(!e)return s;const o=e.spanContext;return o.traceId===r.trace_id?e:(Date.now()/1e3-e.startTimestamp<=jk&&(ne&&y.log(`Adding previous_trace ${o} link to span ${{op:r.op,...t.spanContext()}}`),t.addLink({context:o,attributes:{[S_]:"previous_trace"}}),t.setAttribute(qk,`${o.traceId}-${o.spanId}-${tc(o)?1:0}`)),s)}function Yk(e){try{W.sessionStorage.setItem(Gm,JSON.stringify(e))}catch(t){ne&&y.warn("Could not store previous trace in sessionStorage",t)}}function Jk(){try{const e=W.sessionStorage?.getItem(Gm);return JSON.parse(e)}catch{return}}function tc(e){return e.traceFlags===1}const Kk="BrowserTracing",Zk={...cs,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,enableElementTiming:!0,ignoreResourceSpans:[],ignorePerformanceApiSpans:[],detectRedirects:!0,linkPreviousTrace:"in-memory",consistentTraceSampling:!1,_experiments:{},...mu},Qk=(e={})=>{const t={name:void 0,source:void 0},n=W.document,{enableInp:r,enableElementTiming:i,enableLongTask:s,enableLongAnimationFrame:o,_experiments:{enableInteractions:a,enableStandaloneClsSpans:c,enableStandaloneLcpSpans:u},beforeStartSpan:d,idleTimeout:l,finalTimeout:f,childSpanTimeout:h,markBackgroundSpan:p,traceFetch:m,traceXHR:g,trackFetchStreamPerformance:_,shouldCreateSpanForRequest:v,enableHTTPTimings:L,ignoreResourceSpans:A,ignorePerformanceApiSpans:O,instrumentPageLoad:T,instrumentNavigation:C,detectRedirects:M,linkPreviousTrace:x,consistentTraceSampling:R,onRequestSpanStart:P}={...Zk,...e};let k,F;function X(U,J,N=!0){const G=J.op==="pageload",B=d?d(J):J,re=B.attributes||{};if(J.name!==B.name&&(re[tt]="custom",B.attributes=re),!N){const Me=Dn();Bn({...B,startTime:Me}).end(Me);return}t.name=B.name,t.source=re[tt];const ce=th(B,{idleTimeout:l,finalTimeout:f,childSpanTimeout:h,disableAutoFinish:G,beforeSpanEnd:Me=>{k?.(),Nv(Me,{recordClsOnPageloadSpan:!c,recordLcpOnPageloadSpan:!u,ignoreResourceSpans:A,ignorePerformanceApiSpans:O}),vd(U,void 0);const ke=Q(),Ke=ke.getPropagationContext();ke.setPropagationContext({...Ke,traceId:ce.spanContext().traceId,sampled:Fn(ce),dsc:gt(Me)})}});vd(U,ce);function Ae(){n&&["interactive","complete"].includes(n.readyState)&&U.emit("idleSpanEnableAutoFinish",ce)}G&&n&&(n.addEventListener("readystatechange",()=>{Ae()}),Ae())}return{name:Kk,setup(U){if(zf(),k=Tv({recordClsStandaloneSpans:c||!1,recordLcpStandaloneSpans:u||!1,client:U}),r&&ew(),i&&Wv(),o&&q.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?xv():s&&Iv(),a&&kv(),M&&n){const N=()=>{F=xe()};addEventListener("click",N,{capture:!0}),addEventListener("keydown",N,{capture:!0,passive:!0})}function J(){const N=ci(U);N&&!Z(N).timestamp&&(ne&&y.log(`[Tracing] Finishing current active span with op: ${Z(N).op}`),N.setAttribute(ks,"cancelled"),N.end())}U.on("startNavigationSpan",(N,G)=>{if(H()!==U)return;if(G?.isRedirect){ne&&y.warn("[Tracing] Detected redirect, navigation span will not be the root span, but a child span."),X(U,{op:"navigation.redirect",...N},!1);return}J(),Le().setPropagationContext({traceId:Wt(),sampleRand:Math.random()});const B=Q();B.setPropagationContext({traceId:Wt(),sampleRand:Math.random()}),B.setSDKProcessingMetadata({normalizedRequest:void 0}),X(U,{op:"navigation",...N})}),U.on("startPageLoadSpan",(N,G={})=>{if(H()!==U)return;J();const B=G.sentryTrace||Ed("sentry-trace"),re=G.baggage||Ed("baggage"),ce=Df(B,re),Ae=Q();Ae.setPropagationContext(ce),Ae.setSDKProcessingMetadata({normalizedRequest:Uc()}),X(U,{op:"pageload",...N})})},afterAllSetup(U){let J=Pn();if(x!=="off"&&Vk(U,{linkPreviousTrace:x,consistentTraceSampling:R}),W.location){if(T){const N=Be();zm(U,{name:W.location.pathname,startTime:N?N/1e3:void 0,attributes:{[tt]:"url",[Se]:"auto.pageload.browser"}})}C&&go(({to:N,from:G})=>{if(G===void 0&&J?.indexOf(N)!==-1){J=void 0;return}J=void 0;const B=Hh(N),re=ci(U),ce=re&&M&&tC(re,F);jm(U,{name:B?.pathname||W.location.pathname,attributes:{[tt]:"url",[Se]:"auto.navigation.browser"}},{url:N,isRedirect:ce})})}p&&zk(),a&&eC(U,l,f,h,t),r&&rw(),$m(U,{traceFetch:m,traceXHR:g,trackFetchStreamPerformance:_,tracePropagationTargets:U.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:v,enableHTTPTimings:L,onRequestSpanStart:P})}}};function zm(e,t,n){e.emit("startPageLoadSpan",t,n),Q().setTransactionName(t.name);const r=ci(e);return r&&e.emit("afterStartPageLoadSpan",r),r}function jm(e,t,n){const{url:r,isRedirect:i}=n||{};e.emit("beforeStartNavigationSpan",t,{isRedirect:i}),e.emit("startNavigationSpan",t,{isRedirect:i});const s=Q();return s.setTransactionName(t.name),r&&!i&&s.setSDKProcessingMetadata({normalizedRequest:{...Uc(),url:r}}),ci(e)}function Ed(e){return W.document?.querySelector(`meta[name=${e}]`)?.getAttribute("content")||void 0}function eC(e,t,n,r,i){const s=W.document;let o;const a=()=>{const c="ui.action.click",u=ci(e);if(u){const d=Z(u).op;if(["navigation","pageload"].includes(d)){ne&&y.warn(`[Tracing] Did not create ${c} span because a pageload or navigation span is in progress.`);return}}if(o&&(o.setAttribute(ks,"interactionInterrupted"),o.end(),o=void 0),!i.name){ne&&y.warn(`[Tracing] Did not create ${c} transaction because _latestRouteName is missing.`);return}o=th({name:i.name,op:c,attributes:{[tt]:i.source||"url"}},{idleTimeout:t,finalTimeout:n,childSpanTimeout:r})};s&&addEventListener("click",a,{capture:!0})}const qm="_sentry_idleSpan";function ci(e){return e[qm]}function vd(e,t){Ye(e,qm,t)}const wd=.3;function tC(e,t){const n=Z(e),r=Dn(),i=n.start_timestamp;return!(r-i>wd||t&&r-t<=wd)}function vr(e){return new Promise((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)})}function nC(e,t){const n=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);const r=vr(n);return i=>r.then(s=>i(s.transaction(t,"readwrite").objectStore(t)))}function gu(e){return vr(e.getAllKeys())}function rC(e,t,n){return e(r=>gu(r).then(i=>{if(!(i.length>=n))return r.put(t,Math.max(...i,0)+1),vr(r.transaction)}))}function iC(e,t,n){return e(r=>gu(r).then(i=>{if(!(i.length>=n))return r.put(t,Math.min(...i,0)-1),vr(r.transaction)}))}function sC(e){return e(t=>gu(t).then(n=>{const r=n[0];if(r!=null)return vr(t.get(r)).then(i=>(t.delete(r),vr(t.transaction).then(()=>i)))}))}function oC(e){let t;function n(){return t==null&&(t=nC(e.dbName||"sentry-offline",e.storeName||"queue")),t}return{push:async r=>{try{const i=await As(r);await rC(n(),i,e.maxQueueSize||30)}catch{}},unshift:async r=>{try{const i=await As(r);await iC(n(),i,e.maxQueueSize||30)}catch{}},shift:async()=>{try{const r=await sC(n());if(r)return X_(r)}catch{}}}}function aC(e){return t=>{const n=e({...t,createStore:oC});return W.addEventListener("online",async r=>{await n.flush()}),n}}function cC(e=Jc){return aC(gb(e))}const Td=1e6,Es=String(0),uC="main",Ks=W.navigator;let Vm="",Xm="",Ym="",nc=Ks?.userAgent||"",Jm="";const lC=Ks?.language||Ks?.languages?.[0]||"";function dC(e){return typeof e=="object"&&e!==null&&"getHighEntropyValues"in e}const Id=Ks?.userAgentData;dC(Id)&&Id.getHighEntropyValues(["architecture","model","platform","platformVersion","fullVersionList"]).then(e=>{if(Vm=e.platform||"",Ym=e.architecture||"",Jm=e.model||"",Xm=e.platformVersion||"",e.fullVersionList?.length){const t=e.fullVersionList[e.fullVersionList.length-1];nc=`${t.brand} ${t.version}`}}).catch(e=>{});function fC(e){return!("thread_metadata"in e)}function hC(e){return fC(e)?gC(e):e}function pC(e){const t=e.contexts?.trace?.trace_id;return typeof t=="string"&&t.length!==32&&ne&&y.log(`[Profiling] Invalid traceId: ${t} on profiled event`),typeof t!="string"?"":t}function mC(e,t,n,r){if(r.type!=="transaction")throw new TypeError("Profiling events may only be attached to transactions, this should never occur.");if(n==null)throw new TypeError(`Cannot construct profiling event envelope without a valid profile. Got ${n} instead.`);const i=pC(r),s=hC(n),o=t||(typeof r.start_timestamp=="number"?r.start_timestamp*1e3:xe()*1e3),a=typeof r.timestamp=="number"?r.timestamp*1e3:xe()*1e3;return{event_id:e,timestamp:new Date(o).toISOString(),platform:"javascript",version:"1",release:r.release||"",environment:r.environment||io,runtime:{name:"javascript",version:W.navigator.userAgent},os:{name:Vm,version:Xm,build_number:nc},device:{locale:lC,model:Jm,manufacturer:nc,architecture:Ym,is_emulator:!1},debug_meta:{images:bC(n.resources)},profile:s,transactions:[{name:r.transaction||"",id:r.event_id||je(),trace_id:i,active_thread_id:Es,relative_start_ns:"0",relative_end_ns:((a-o)*1e6).toFixed(0)}]}}function Km(e){return Z(e).op==="pageload"}function gC(e){let t,n=0;const r={samples:[],stacks:[],frames:[],thread_metadata:{[Es]:{name:uC}}},i=e.samples[0];if(!i)return r;const s=i.timestamp,o=Be(),a=typeof performance.timeOrigin=="number"?performance.timeOrigin:o||0,c=a-(o||a);return e.samples.forEach((u,d)=>{if(u.stackId===void 0){t===void 0&&(t=n,r.stacks[t]=[],n++),r.samples[d]={elapsed_since_start_ns:((u.timestamp+c-s)*Td).toFixed(0),stack_id:t,thread_id:Es};return}let l=e.stacks[u.stackId];const f=[];for(;l;){f.push(l.frameId);const p=e.frames[l.frameId];p&&r.frames[l.frameId]===void 0&&(r.frames[l.frameId]={function:p.name,abs_path:typeof p.resourceId=="number"?e.resources[p.resourceId]:void 0,lineno:p.line,colno:p.column}),l=l.parentId===void 0?void 0:e.stacks[l.parentId]}const h={elapsed_since_start_ns:((u.timestamp+c-s)*Td).toFixed(0),stack_id:n,thread_id:Es};r.stacks[n]=f,r.samples[d]=h,n++}),r}function _C(e,t){if(!t.length)return e;for(const n of t)e[1].push([{type:"profile"},n]);return e}function yC(e){const t=[];return Mn(e,(n,r)=>{if(r==="transaction")for(let i=1;i<n.length;i++)n[i]?.contexts?.profile?.profile_id&&t.push(n[i])}),t}function bC(e){const r=H()?.getOptions()?.stackParser;return r?Ty(r,e):[]}function SC(e){return typeof e!="number"&&typeof e!="boolean"||typeof e=="number"&&isNaN(e)?(ne&&y.warn(`[Profiling] Invalid sample rate. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`),!1):e===!0||e===!1?!0:e<0||e>1?(ne&&y.warn(`[Profiling] Invalid sample rate. Sample rate must be between 0 and 1. Got ${e}.`),!1):!0}function EC(e){return e.samples.length<2?(ne&&y.log("[Profiling] Discarding profile because it contains less than 2 samples"),!1):e.frames.length?!0:(ne&&y.log("[Profiling] Discarding profile because it contains no frames"),!1)}let Zm=!1;const Qm=3e4;function vC(e){return typeof e=="function"}function wC(){const e=W.Profiler;if(!vC(e)){ne&&y.log("[Profiling] Profiling is not supported by this browser, Profiler interface missing on window object.");return}const t=10,n=Math.floor(Qm/t);try{return new e({sampleInterval:t,maxBufferSize:n})}catch{ne&&(y.log("[Profiling] Failed to initialize the Profiling constructor, this is likely due to a missing 'Document-Policy': 'js-profiling' header."),y.log("[Profiling] Disabling profiling for current user session.")),Zm=!0}}function xd(e){if(Zm)return ne&&y.log("[Profiling] Profiling has been disabled for the duration of the current user session."),!1;if(!e.isRecording())return ne&&y.log("[Profiling] Discarding profile because transaction was not sampled."),!1;const n=H()?.getOptions();if(!n)return ne&&y.log("[Profiling] Profiling disabled, no options found."),!1;const r=n.profilesSampleRate;return SC(r)?r?(r===!0?!0:Math.random()<r)?!0:(ne&&y.log(`[Profiling] Discarding profile because it's not included in the random sample (sampling rate = ${Number(r)})`),!1):(ne&&y.log("[Profiling] Discarding profile because a negative sampling decision was inherited or profileSampleRate is set to 0"),!1):(ne&&y.warn("[Profiling] Discarding profile because of invalid sample rate."),!1)}function TC(e,t,n,r){return EC(n)?mC(e,t,n,r):null}const In=new Map;function IC(){return In.size}function xC(e){const t=In.get(e);return t&&In.delete(e),t}function kC(e,t){if(In.set(e,t),In.size>30){const n=In.keys().next().value;In.delete(n)}}function kd(e){let t;Km(e)&&(t=xe()*1e3);const n=wC();if(!n)return;ne&&y.log(`[Profiling] started profiling span: ${Z(e).description}`);const r=je();Q().setContext("profile",{profile_id:r,start_timestamp:t});async function i(){if(e&&n)return n.stop().then(c=>{if(s&&(W.clearTimeout(s),s=void 0),ne&&y.log(`[Profiling] stopped profiling of span: ${Z(e).description}`),!c){ne&&y.log(`[Profiling] profiler returned null profile for: ${Z(e).description}`,"this may indicate an overlapping span or a call to stopProfiling with a profile title that was never started");return}kC(r,c)}).catch(c=>{ne&&y.log("[Profiling] error while stopping profiler:",c)})}let s=W.setTimeout(()=>{ne&&y.log("[Profiling] max profile duration elapsed, stopping profiling for:",Z(e).description),i()},Qm);const o=e.end.bind(e);function a(){return e?(i().then(()=>{o()},()=>{o()}),e):o()}e.end=a}const CC="BrowserProfiling",RC=()=>({name:CC,setup(e){const t=Pe(),n=t&&Oe(t);n&&Km(n)&&xd(n)&&kd(n),e.on("spanStart",r=>{r===Oe(r)&&xd(r)&&kd(r)}),e.on("beforeEnvelope",r=>{if(!IC())return;const i=yC(r);if(!i.length)return;const s=[];for(const o of i){const a=o?.contexts,c=a?.profile?.profile_id,u=a?.profile?.start_timestamp;if(typeof c!="string"){ne&&y.log("[Profiling] cannot find profile for a span without a profile context");continue}if(!c){ne&&y.log("[Profiling] cannot find profile for a span without a profile context");continue}a?.profile&&delete a.profile;const d=xC(c);if(!d){ne&&y.log(`[Profiling] Could not retrieve profile for span: ${c}`);continue}const l=TC(c,u,d,o);l&&s.push(l)}_C(r,s)})}}),AC=RC,MC="SpotlightBrowser",NC=(e={})=>{const t=e.sidecarUrl||"http://localhost:8969/stream";return{name:MC,setup:()=>{ne&&y.log("Using Sidecar URL",t)},processEvent:n=>PC(n)?null:n,afterAllSetup:n=>{OC(n,t)}}};function OC(e,t){const n=Vc("fetch");let r=0;e.on("beforeEnvelope",i=>{if(r>3){y.warn("[Spotlight] Disabled Sentry -> Spotlight integration due to too many failed requests:",r);return}n(t,{method:"POST",body:As(i),headers:{"Content-Type":"application/x-sentry-envelope"},mode:"cors"}).then(s=>{s.status>=200&&s.status<400&&(r=0)},s=>{r++,y.error("Sentry SDK can't connect to Sidecar is it running? See: https://spotlightjs.com/sidecar/npx/",s)})})}const LC=NC;function PC(e){return!!(e.type==="transaction"&&e.spans&&e.contexts?.trace&&e.contexts.trace.op==="ui.action.click"&&e.spans.some(({description:t})=>t?.includes("#sentry-spotlight")))}const DC=()=>({name:"LaunchDarkly",processEvent(e,t,n){return Si(e)}});function FC(){return{name:"sentry-flag-auditor",type:"flag-used",synchronous:!0,method:(e,t,n)=>{lr(e,t.value),dr(e,t.value)}}}const HC=()=>({name:"OpenFeature",processEvent(e,t,n){return Si(e)}});class BC{after(t,n){lr(n.flagKey,n.value),dr(n.flagKey,n.value)}error(t,n,r){lr(t.flagKey,t.defaultValue),dr(t.flagKey,t.defaultValue)}}const UC=({featureFlagClientClass:e})=>({name:"Unleash",setupOnce(){const t=e.prototype;ze(t,"isEnabled",$C)},processEvent(t,n,r){return Si(t)}});function $C(e){return function(...t){const n=t[0],r=e.apply(this,t);return typeof n=="string"&&typeof r=="boolean"?(lr(n,r),dr(n,r)):ne&&y.error(`[Feature Flags] UnleashClient.isEnabled does not match expected signature. arg0: ${n} (${typeof n}), result: ${r} (${typeof r})`),r}}const WC=({featureFlagClient:e})=>({name:"Statsig",setup(t){e.on("gate_evaluation",n=>{lr(n.gate.name,n.gate.value),dr(n.gate.name,n.gate.value)})},processEvent(t,n,r){return Si(t)}});async function GC(){const e=H();if(!e)return"no-client-active";if(!e.getDsn())return"no-dsn-configured";try{await fetch("https://o447951.ingest.sentry.io/api/4509632503087104/envelope/?sentry_version=7&sentry_key=c1dfb07d783ad5325c245c1fd3725390&sentry_client=sentry.javascript.browser%2F1.33.7",{body:"{}",method:"POST",mode:"cors",credentials:"omit"})}catch{return"sentry-unreachable"}}const zC="WebWorker",jC=({worker:e})=>({name:zC,setupOnce:()=>{(Array.isArray(e)?e:[e]).forEach(t=>Cd(t))},addWorker:t=>Cd(t)});function Cd(e){e.addEventListener("message",t=>{VC(t.data)&&(t.stopImmediatePropagation(),ne&&y.log("Sentry debugId web worker message received",t.data),W._sentryDebugIds={...t.data._sentryDebugIds,...W._sentryDebugIds})})}function qC({self:e}){e.postMessage({_sentryMessage:!0,_sentryDebugIds:e._sentryDebugIds??void 0})}function VC(e){return Ut(e)&&e._sentryMessage===!0&&"_sentryDebugIds"in e&&(Ut(e._sentryDebugIds)||e._sentryDebugIds===void 0)}const XC=Object.freeze(Object.defineProperty({__proto__:null,BrowserClient:up,OpenFeatureIntegrationHook:BC,SDK_VERSION:Dt,SEMANTIC_ATTRIBUTE_SENTRY_OP:rt,SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN:Se,SEMANTIC_ATTRIBUTE_SENTRY_SAMPLE_RATE:ro,SEMANTIC_ATTRIBUTE_SENTRY_SOURCE:tt,Scope:mt,WINDOW:W,addBreadcrumb:Ct,addEventProcessor:ah,addIntegration:Ca,breadcrumbsIntegration:Op,browserApiErrorsIntegration:Lp,browserProfilingIntegration:AC,browserSessionIntegration:Pp,browserTracingIntegration:Qk,buildLaunchDarklyFlagUsedHandler:FC,captureConsoleIntegration:Vb,captureEvent:bi,captureException:Nn,captureFeedback:Uh,captureMessage:Ls,captureSession:ka,chromeStackLineParser:Cp,close:$y,consoleLoggingIntegration:JS,contextLinesIntegration:kT,continueTrace:uy,createTransport:vh,createUserFeedbackEnvelope:Iw,dedupeIntegration:Nh,defaultRequestInstrumentationOptions:mu,defaultStackLineParsers:Ap,defaultStackParser:Mp,diagnoseSdkConnectivity:GC,endSession:Rc,eventFiltersIntegration:kh,eventFromException:ap,eventFromMessage:cp,exceptionFromError:lo,extraErrorDataIntegration:nS,featureFlagsIntegration:BS,feedbackAsyncIntegration:TE,feedbackIntegration:Rl,feedbackSyncIntegration:Rl,flush:Uy,forceLoad:iT,functionToStringIntegration:xh,geckoStackLineParser:Rp,getActiveSpan:Pe,getClient:H,getCurrentScope:Q,getDefaultIntegrations:Up,getFeedback:L0,getGlobalScope:no,getIsolationScope:Le,getReplay:_k,getRootSpan:Oe,getSpanDescendants:Yr,getSpanStatusFromHttpCode:Af,getTraceData:Mc,globalHandlersIntegration:Dp,graphqlClientIntegration:PT,httpClientIntegration:hT,httpContextIntegration:Hp,inboundFiltersIntegration:Ch,init:rT,instrumentOutgoingRequests:$m,instrumentSupabaseClient:Dh,isEnabled:oh,isInitialized:Wy,lastEventId:sh,launchDarklyIntegration:DC,lazyLoadIntegration:sp,linkedErrorsIntegration:Bp,logger:ME,makeBrowserOfflineTransport:cC,makeFetchTransport:Jc,makeMultiplexedTransport:bb,moduleMetadataIntegration:Gb,onLoad:sT,openFeatureIntegration:HC,opera10StackLineParser:Ew,opera11StackLineParser:Tw,parameterize:Ih,registerSpanErrorInstrumentation:zf,registerWebWorker:qC,replayCanvasIntegration:Dk,replayIntegration:pk,reportingObserverIntegration:lT,rewriteFramesIntegration:dS,sendFeedback:jh,setContext:ih,setCurrentClient:_h,setExtra:Dy,setExtras:Py,setHttpStatus:ni,setMeasurement:Zf,setTag:Hy,setTags:Fy,setUser:By,showReportDialog:oT,spanToBaggageHeader:B_,spanToJSON:Z,spanToTraceHeader:Uf,spotlightBrowserIntegration:LC,startBrowserTracingNavigationSpan:jm,startBrowserTracingPageLoadSpan:zm,startInactiveSpan:Bn,startNewTrace:dy,startSession:xa,startSpan:oo,startSpanManual:cy,statsigIntegration:WC,supabaseIntegration:TS,suppressTracing:ly,thirdPartyErrorFilterIntegration:LS,unleashIntegration:UC,updateSpanName:O_,webWorkerIntegration:jC,winjsStackLineParser:yw,withActiveSpan:_i,withIsolationScope:__,withScope:ot,zodErrorsIntegration:OS},Symbol.toStringTag,{value:"Module"})),To=e=>{typeof window<"u"&&window.Sentry&&e(XC)},{useEffect:YC}=await Je("react"),eg=(e,t)=>YC(()=>{const n=e().catch(r=>{console.error("AsyncEffect error: ",r),To(i=>i.captureException("AsyncEffect error: "+r.message,{extra:r}))});return function(){n.then(r=>{typeof r=="function"&&r()})}},t),{createContext:JC,useMemo:KC,useRef:ZC,useState:QC}=await Je("react"),tg=JC(null),lM=e=>{const{writeKey:t,userId:n,traits:r,children:i}=e,s=ZC(null),[o,a]=QC(!1);eg(async()=>{if(!t){console.log("[Analytics] No writeKey provided");return}const u=navigator.userAgent;if(Fg(u)){console.log("[Analytics] Skipping load: bot detected");return}try{const{AnalyticsBrowser:l}=await Rg(async()=>{const{AnalyticsBrowser:f}=await import("../index-Cp1PC8Pr.js").then(h=>h.q);return{AnalyticsBrowser:f}},__vite__mapDeps([0,1,2,3,4]));s.current=l.load({writeKey:t}),n&&s.current.identify(n,r),a(!0)}catch(l){console.error("[Analytics] Failed to initialize:",l),s.current=null}},[t,n,r]);const c=KC(()=>!s.current||!o?{isInitialized:!1,track:()=>{},identify:()=>{},page:()=>{}}:{isInitialized:!0,track:(u,d)=>{s.current?.track(u,d)},identify:(u,d)=>{s.current?.identify(u,d)},page:(u,d)=>{s.current?.page(u,d)}},[o]);return hf.jsx(tg.Provider,{value:c,children:i})},{createContext:eR}=await Je("react"),ng=eR(null);function wt(e,t){var n=t&&t.cache?t.cache:aR,r=t&&t.serializer?t.serializer:sR,i=t&&t.strategy?t.strategy:nR;return i(e,{cache:n,serializer:r})}function tR(e){return e==null||typeof e=="number"||typeof e=="boolean"}function rg(e,t,n,r){var i=tR(r)?r:n(r),s=t.get(i);return typeof s>"u"&&(s=e.call(this,r),t.set(i,s)),s}function ig(e,t,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),s=t.get(i);return typeof s>"u"&&(s=e.apply(this,r),t.set(i,s)),s}function _u(e,t,n,r,i){return n.bind(t,e,r,i)}function nR(e,t){var n=e.length===1?rg:ig;return _u(e,this,n,t.cache.create(),t.serializer)}function rR(e,t){return _u(e,this,ig,t.cache.create(),t.serializer)}function iR(e,t){return _u(e,this,rg,t.cache.create(),t.serializer)}var sR=function(){return JSON.stringify(arguments)},oR=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(t){return this.cache[t]},e.prototype.set=function(t,n){this.cache[t]=n},e}(),aR={create:function(){return new oR}},Tt={variadic:rR,monadic:iR},se;(function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"})(se||(se={}));var _e;(function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"})(_e||(_e={}));var wr;(function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"})(wr||(wr={}));function Rd(e){return e.type===_e.literal}function cR(e){return e.type===_e.argument}function sg(e){return e.type===_e.number}function og(e){return e.type===_e.date}function ag(e){return e.type===_e.time}function cg(e){return e.type===_e.select}function ug(e){return e.type===_e.plural}function uR(e){return e.type===_e.pound}function lg(e){return e.type===_e.tag}function dg(e){return!!(e&&typeof e=="object"&&e.type===wr.number)}function rc(e){return!!(e&&typeof e=="object"&&e.type===wr.dateTime)}var fg=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,lR=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function dR(e){var t={};return e.replace(lR,function(n){var r=n.length;switch(n[0]){case"G":t.era=r===4?"long":r===5?"narrow":"short";break;case"y":t.year=r===2?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][r-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][r-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=r===4?"long":r===5?"narrow":"short";break;case"e":if(r<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"c":if(r<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][r-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][r-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][r-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][r-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][r-1];break;case"s":t.second=["numeric","2-digit"][r-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=r<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var fR=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function hR(e){if(e.length===0)throw new Error("Number skeleton cannot be empty");for(var t=e.split(fR).filter(function(f){return f.length>0}),n=[],r=0,i=t;r<i.length;r++){var s=i[r],o=s.split("/");if(o.length===0)throw new Error("Invalid number skeleton");for(var a=o[0],c=o.slice(1),u=0,d=c;u<d.length;u++){var l=d[u];if(l.length===0)throw new Error("Invalid number skeleton")}n.push({stem:a,options:c})}return n}function pR(e){return e.replace(/^(.*?)-/,"")}var Ad=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,hg=/^(@+)?(\+|#+)?[rs]?$/g,mR=/(\*)(0+)|(#+)(0+)|(0+)/g,pg=/^(0+)$/;function Md(e){var t={};return e[e.length-1]==="r"?t.roundingPriority="morePrecision":e[e.length-1]==="s"&&(t.roundingPriority="lessPrecision"),e.replace(hg,function(n,r,i){return typeof i!="string"?(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length):i==="+"?t.minimumSignificantDigits=r.length:r[0]==="#"?t.maximumSignificantDigits=r.length:(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length+(typeof i=="string"?i.length:0)),""}),t}function mg(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function gR(e){var t;if(e[0]==="E"&&e[1]==="E"?(t={notation:"engineering"},e=e.slice(2)):e[0]==="E"&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if(n==="+!"?(t.signDisplay="always",e=e.slice(2)):n==="+?"&&(t.signDisplay="exceptZero",e=e.slice(2)),!pg.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function Nd(e){var t={},n=mg(e);return n||t}function _R(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n];switch(i.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=i.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=pR(i.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=$($($({},t),{notation:"scientific"}),i.options.reduce(function(c,u){return $($({},c),Nd(u))},{}));continue;case"engineering":t=$($($({},t),{notation:"engineering"}),i.options.reduce(function(c,u){return $($({},c),Nd(u))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(i.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(mR,function(c,u,d,l,f,h){if(u)t.minimumIntegerDigits=d.length;else{if(l&&f)throw new Error("We currently do not support maximum integer digits");if(h)throw new Error("We currently do not support exact integer digits")}return""});continue}if(pg.test(i.stem)){t.minimumIntegerDigits=i.stem.length;continue}if(Ad.test(i.stem)){if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(Ad,function(c,u,d,l,f,h){return d==="*"?t.minimumFractionDigits=u.length:l&&l[0]==="#"?t.maximumFractionDigits=l.length:f&&h?(t.minimumFractionDigits=f.length,t.maximumFractionDigits=f.length+h.length):(t.minimumFractionDigits=u.length,t.maximumFractionDigits=u.length),""});var s=i.options[0];s==="w"?t=$($({},t),{trailingZeroDisplay:"stripIfInteger"}):s&&(t=$($({},t),Md(s)));continue}if(hg.test(i.stem)){t=$($({},t),Md(i.stem));continue}var o=mg(i.stem);o&&(t=$($({},t),o));var a=gR(i.stem);a&&(t=$($({},t),a))}return t}var Qi={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function yR(e,t){for(var n="",r=0;r<e.length;r++){var i=e.charAt(r);if(i==="j"){for(var s=0;r+1<e.length&&e.charAt(r+1)===i;)s++,r++;var o=1+(s&1),a=s<2?1:3+(s>>1),c="a",u=bR(t);for((u=="H"||u=="k")&&(a=0);a-- >0;)n+=c;for(;o-- >0;)n=u+n}else i==="J"?n+="H":n+=i}return n}function bR(e){var t=e.hourCycle;if(t===void 0&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n=e.language,r;n!=="root"&&(r=e.maximize().region);var i=Qi[r||""]||Qi[n||""]||Qi["".concat(n,"-001")]||Qi["001"];return i[0]}var na,SR=new RegExp("^".concat(fg.source,"*")),ER=new RegExp("".concat(fg.source,"*$"));function oe(e,t){return{start:e,end:t}}var vR=!!String.prototype.startsWith&&"_a".startsWith("a",1),wR=!!String.fromCodePoint,TR=!!Object.fromEntries,IR=!!String.prototype.codePointAt,xR=!!String.prototype.trimStart,kR=!!String.prototype.trimEnd,CR=!!Number.isSafeInteger,RR=CR?Number.isSafeInteger:function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},ic=!0;try{var AR=_g("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");ic=((na=AR.exec("a"))===null||na===void 0?void 0:na[0])==="a"}catch{ic=!1}var Od=vR?function(t,n,r){return t.startsWith(n,r)}:function(t,n,r){return t.slice(r,r+n.length)===n},sc=wR?String.fromCodePoint:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r="",i=t.length,s=0,o;i>s;){if(o=t[s++],o>1114111)throw RangeError(o+" is not a valid code point");r+=o<65536?String.fromCharCode(o):String.fromCharCode(((o-=65536)>>10)+55296,o%1024+56320)}return r},Ld=TR?Object.fromEntries:function(t){for(var n={},r=0,i=t;r<i.length;r++){var s=i[r],o=s[0],a=s[1];n[o]=a}return n},gg=IR?function(t,n){return t.codePointAt(n)}:function(t,n){var r=t.length;if(!(n<0||n>=r)){var i=t.charCodeAt(n),s;return i<55296||i>56319||n+1===r||(s=t.charCodeAt(n+1))<56320||s>57343?i:(i-55296<<10)+(s-56320)+65536}},MR=xR?function(t){return t.trimStart()}:function(t){return t.replace(SR,"")},NR=kR?function(t){return t.trimEnd()}:function(t){return t.replace(ER,"")};function _g(e,t){return new RegExp(e,t)}var oc;if(ic){var Pd=_g("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");oc=function(t,n){var r;Pd.lastIndex=n;var i=Pd.exec(t);return(r=i[1])!==null&&r!==void 0?r:""}}else oc=function(t,n){for(var r=[];;){var i=gg(t,n);if(i===void 0||yg(i)||DR(i))break;r.push(i),n+=i>=65536?2:1}return sc.apply(void 0,r)};var OR=function(){function e(t,n){n===void 0&&(n={}),this.message=t,this.position={offset:0,line:1,column:1},this.ignoreTag=!!n.ignoreTag,this.locale=n.locale,this.requiresOtherClause=!!n.requiresOtherClause,this.shouldParseSkeletons=!!n.shouldParseSkeletons}return e.prototype.parse=function(){if(this.offset()!==0)throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(t,n,r){for(var i=[];!this.isEOF();){var s=this.char();if(s===123){var o=this.parseArgument(t,r);if(o.err)return o;i.push(o.val)}else{if(s===125&&t>0)break;if(s===35&&(n==="plural"||n==="selectordinal")){var a=this.clonePosition();this.bump(),i.push({type:_e.pound,location:oe(a,this.clonePosition())})}else if(s===60&&!this.ignoreTag&&this.peek()===47){if(r)break;return this.error(se.UNMATCHED_CLOSING_TAG,oe(this.clonePosition(),this.clonePosition()))}else if(s===60&&!this.ignoreTag&&ac(this.peek()||0)){var o=this.parseTag(t,n);if(o.err)return o;i.push(o.val)}else{var o=this.parseLiteral(t,n);if(o.err)return o;i.push(o.val)}}}return{val:i,err:null}},e.prototype.parseTag=function(t,n){var r=this.clonePosition();this.bump();var i=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:_e.literal,value:"<".concat(i,"/>"),location:oe(r,this.clonePosition())},err:null};if(this.bumpIf(">")){var s=this.parseMessage(t+1,n,!0);if(s.err)return s;var o=s.val,a=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!ac(this.char()))return this.error(se.INVALID_TAG,oe(a,this.clonePosition()));var c=this.clonePosition(),u=this.parseTagName();return i!==u?this.error(se.UNMATCHED_CLOSING_TAG,oe(c,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:_e.tag,value:i,children:o,location:oe(r,this.clonePosition())},err:null}:this.error(se.INVALID_TAG,oe(a,this.clonePosition())))}else return this.error(se.UNCLOSED_TAG,oe(r,this.clonePosition()))}else return this.error(se.INVALID_TAG,oe(r,this.clonePosition()))},e.prototype.parseTagName=function(){var t=this.offset();for(this.bump();!this.isEOF()&&PR(this.char());)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(t,n){for(var r=this.clonePosition(),i="";;){var s=this.tryParseQuote(n);if(s){i+=s;continue}var o=this.tryParseUnquoted(t,n);if(o){i+=o;continue}var a=this.tryParseLeftAngleBracket();if(a){i+=a;continue}break}var c=oe(r,this.clonePosition());return{val:{type:_e.literal,value:i,location:c},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return!this.isEOF()&&this.char()===60&&(this.ignoreTag||!LR(this.peek()||0))?(this.bump(),"<"):null},e.prototype.tryParseQuote=function(t){if(this.isEOF()||this.char()!==39)return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if(t==="plural"||t==="selectordinal")break;return null;default:return null}this.bump();var n=[this.char()];for(this.bump();!this.isEOF();){var r=this.char();if(r===39)if(this.peek()===39)n.push(39),this.bump();else{this.bump();break}else n.push(r);this.bump()}return sc.apply(void 0,n)},e.prototype.tryParseUnquoted=function(t,n){if(this.isEOF())return null;var r=this.char();return r===60||r===123||r===35&&(n==="plural"||n==="selectordinal")||r===125&&t>0?null:(this.bump(),sc(r))},e.prototype.parseArgument=function(t,n){var r=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(se.EXPECT_ARGUMENT_CLOSING_BRACE,oe(r,this.clonePosition()));if(this.char()===125)return this.bump(),this.error(se.EMPTY_ARGUMENT,oe(r,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(se.MALFORMED_ARGUMENT,oe(r,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(se.EXPECT_ARGUMENT_CLOSING_BRACE,oe(r,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:_e.argument,value:i,location:oe(r,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(se.EXPECT_ARGUMENT_CLOSING_BRACE,oe(r,this.clonePosition())):this.parseArgumentOptions(t,n,i,r);default:return this.error(se.MALFORMED_ARGUMENT,oe(r,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var t=this.clonePosition(),n=this.offset(),r=oc(this.message,n),i=n+r.length;this.bumpTo(i);var s=this.clonePosition(),o=oe(t,s);return{value:r,location:o}},e.prototype.parseArgumentOptions=function(t,n,r,i){var s,o=this.clonePosition(),a=this.parseIdentifierIfPossible().value,c=this.clonePosition();switch(a){case"":return this.error(se.EXPECT_ARGUMENT_TYPE,oe(o,c));case"number":case"date":case"time":{this.bumpSpace();var u=null;if(this.bumpIf(",")){this.bumpSpace();var d=this.clonePosition(),l=this.parseSimpleArgStyleIfPossible();if(l.err)return l;var f=NR(l.val);if(f.length===0)return this.error(se.EXPECT_ARGUMENT_STYLE,oe(this.clonePosition(),this.clonePosition()));var h=oe(d,this.clonePosition());u={style:f,styleLocation:h}}var p=this.tryParseArgumentClose(i);if(p.err)return p;var m=oe(i,this.clonePosition());if(u&&Od(u?.style,"::",0)){var g=MR(u.style.slice(2));if(a==="number"){var l=this.parseNumberSkeletonFromString(g,u.styleLocation);return l.err?l:{val:{type:_e.number,value:r,location:m,style:l.val},err:null}}else{if(g.length===0)return this.error(se.EXPECT_DATE_TIME_SKELETON,m);var _=g;this.locale&&(_=yR(g,this.locale));var f={type:wr.dateTime,pattern:_,location:u.styleLocation,parsedOptions:this.shouldParseSkeletons?dR(_):{}},v=a==="date"?_e.date:_e.time;return{val:{type:v,value:r,location:m,style:f},err:null}}}return{val:{type:a==="number"?_e.number:a==="date"?_e.date:_e.time,value:r,location:m,style:(s=u?.style)!==null&&s!==void 0?s:null},err:null}}case"plural":case"selectordinal":case"select":{var L=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(se.EXPECT_SELECT_ARGUMENT_OPTIONS,oe(L,$({},L)));this.bumpSpace();var A=this.parseIdentifierIfPossible(),O=0;if(a!=="select"&&A.value==="offset"){if(!this.bumpIf(":"))return this.error(se.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,oe(this.clonePosition(),this.clonePosition()));this.bumpSpace();var l=this.tryParseDecimalInteger(se.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,se.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(l.err)return l;this.bumpSpace(),A=this.parseIdentifierIfPossible(),O=l.val}var T=this.tryParsePluralOrSelectOptions(t,a,n,A);if(T.err)return T;var p=this.tryParseArgumentClose(i);if(p.err)return p;var C=oe(i,this.clonePosition());return a==="select"?{val:{type:_e.select,value:r,options:Ld(T.val),location:C},err:null}:{val:{type:_e.plural,value:r,options:Ld(T.val),offset:O,pluralType:a==="plural"?"cardinal":"ordinal",location:C},err:null}}default:return this.error(se.INVALID_ARGUMENT_TYPE,oe(o,c))}},e.prototype.tryParseArgumentClose=function(t){return this.isEOF()||this.char()!==125?this.error(se.EXPECT_ARGUMENT_CLOSING_BRACE,oe(t,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var t=0,n=this.clonePosition();!this.isEOF();){var r=this.char();switch(r){case 39:{this.bump();var i=this.clonePosition();if(!this.bumpUntil("'"))return this.error(se.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,oe(i,this.clonePosition()));this.bump();break}case 123:{t+=1,this.bump();break}case 125:{if(t>0)t-=1;else return{val:this.message.slice(n.offset,this.offset()),err:null};break}default:this.bump();break}}return{val:this.message.slice(n.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(t,n){var r=[];try{r=hR(t)}catch{return this.error(se.INVALID_NUMBER_SKELETON,n)}return{val:{type:wr.number,tokens:r,location:n,parsedOptions:this.shouldParseSkeletons?_R(r):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(t,n,r,i){for(var s,o=!1,a=[],c=new Set,u=i.value,d=i.location;;){if(u.length===0){var l=this.clonePosition();if(n!=="select"&&this.bumpIf("=")){var f=this.tryParseDecimalInteger(se.EXPECT_PLURAL_ARGUMENT_SELECTOR,se.INVALID_PLURAL_ARGUMENT_SELECTOR);if(f.err)return f;d=oe(l,this.clonePosition()),u=this.message.slice(l.offset,this.offset())}else break}if(c.has(u))return this.error(n==="select"?se.DUPLICATE_SELECT_ARGUMENT_SELECTOR:se.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,d);u==="other"&&(o=!0),this.bumpSpace();var h=this.clonePosition();if(!this.bumpIf("{"))return this.error(n==="select"?se.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:se.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,oe(this.clonePosition(),this.clonePosition()));var p=this.parseMessage(t+1,n,r);if(p.err)return p;var m=this.tryParseArgumentClose(h);if(m.err)return m;a.push([u,{value:p.val,location:oe(h,this.clonePosition())}]),c.add(u),this.bumpSpace(),s=this.parseIdentifierIfPossible(),u=s.value,d=s.location}return a.length===0?this.error(n==="select"?se.EXPECT_SELECT_ARGUMENT_SELECTOR:se.EXPECT_PLURAL_ARGUMENT_SELECTOR,oe(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(se.MISSING_OTHER_CLAUSE,oe(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(t,n){var r=1,i=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(r=-1);for(var s=!1,o=0;!this.isEOF();){var a=this.char();if(a>=48&&a<=57)s=!0,o=o*10+(a-48),this.bump();else break}var c=oe(i,this.clonePosition());return s?(o*=r,RR(o)?{val:o,err:null}:this.error(n,c)):this.error(t,c)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var t=this.position.offset;if(t>=this.message.length)throw Error("out of bound");var n=gg(this.message,t);if(n===void 0)throw Error("Offset ".concat(t," is at invalid UTF-16 code unit boundary"));return n},e.prototype.error=function(t,n){return{val:null,err:{kind:t,message:this.message,location:n}}},e.prototype.bump=function(){if(!this.isEOF()){var t=this.char();t===10?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=t<65536?1:2)}},e.prototype.bumpIf=function(t){if(Od(this.message,t,this.offset())){for(var n=0;n<t.length;n++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(t){var n=this.offset(),r=this.message.indexOf(t,n);return r>=0?(this.bumpTo(r),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(t){if(this.offset()>t)throw Error("targetOffset ".concat(t," must be greater than or equal to the current offset ").concat(this.offset()));for(t=Math.min(t,this.message.length);;){var n=this.offset();if(n===t)break;if(n>t)throw Error("targetOffset ".concat(t," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&yg(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var t=this.char(),n=this.offset(),r=this.message.charCodeAt(n+(t>=65536?2:1));return r??null},e}();function ac(e){return e>=97&&e<=122||e>=65&&e<=90}function LR(e){return ac(e)||e===47}function PR(e){return e===45||e===46||e>=48&&e<=57||e===95||e>=97&&e<=122||e>=65&&e<=90||e==183||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function yg(e){return e>=9&&e<=13||e===32||e===133||e>=8206&&e<=8207||e===8232||e===8233}function DR(e){return e>=33&&e<=35||e===36||e>=37&&e<=39||e===40||e===41||e===42||e===43||e===44||e===45||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||e===91||e===92||e===93||e===94||e===96||e===123||e===124||e===125||e===126||e===161||e>=162&&e<=165||e===166||e===167||e===169||e===171||e===172||e===174||e===176||e===177||e===182||e===187||e===191||e===215||e===247||e>=8208&&e<=8213||e>=8214&&e<=8215||e===8216||e===8217||e===8218||e>=8219&&e<=8220||e===8221||e===8222||e===8223||e>=8224&&e<=8231||e>=8240&&e<=8248||e===8249||e===8250||e>=8251&&e<=8254||e>=8257&&e<=8259||e===8260||e===8261||e===8262||e>=8263&&e<=8273||e===8274||e===8275||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||e===8608||e>=8609&&e<=8610||e===8611||e>=8612&&e<=8613||e===8614||e>=8615&&e<=8621||e===8622||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||e===8658||e===8659||e===8660||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||e===8968||e===8969||e===8970||e===8971||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||e===9001||e===9002||e>=9003&&e<=9083||e===9084||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||e===9655||e>=9656&&e<=9664||e===9665||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||e===9839||e>=9840&&e<=10087||e===10088||e===10089||e===10090||e===10091||e===10092||e===10093||e===10094||e===10095||e===10096||e===10097||e===10098||e===10099||e===10100||e===10101||e>=10132&&e<=10175||e>=10176&&e<=10180||e===10181||e===10182||e>=10183&&e<=10213||e===10214||e===10215||e===10216||e===10217||e===10218||e===10219||e===10220||e===10221||e===10222||e===10223||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||e===10627||e===10628||e===10629||e===10630||e===10631||e===10632||e===10633||e===10634||e===10635||e===10636||e===10637||e===10638||e===10639||e===10640||e===10641||e===10642||e===10643||e===10644||e===10645||e===10646||e===10647||e===10648||e>=10649&&e<=10711||e===10712||e===10713||e===10714||e===10715||e>=10716&&e<=10747||e===10748||e===10749||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||e===11158||e>=11159&&e<=11263||e>=11776&&e<=11777||e===11778||e===11779||e===11780||e===11781||e>=11782&&e<=11784||e===11785||e===11786||e===11787||e===11788||e===11789||e>=11790&&e<=11798||e===11799||e>=11800&&e<=11801||e===11802||e===11803||e===11804||e===11805||e>=11806&&e<=11807||e===11808||e===11809||e===11810||e===11811||e===11812||e===11813||e===11814||e===11815||e===11816||e===11817||e>=11818&&e<=11822||e===11823||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||e===11840||e===11841||e===11842||e>=11843&&e<=11855||e>=11856&&e<=11857||e===11858||e>=11859&&e<=11903||e>=12289&&e<=12291||e===12296||e===12297||e===12298||e===12299||e===12300||e===12301||e===12302||e===12303||e===12304||e===12305||e>=12306&&e<=12307||e===12308||e===12309||e===12310||e===12311||e===12312||e===12313||e===12314||e===12315||e===12316||e===12317||e>=12318&&e<=12319||e===12320||e===12336||e===64830||e===64831||e>=65093&&e<=65094}function cc(e){e.forEach(function(t){if(delete t.location,cg(t)||ug(t))for(var n in t.options)delete t.options[n].location,cc(t.options[n].value);else sg(t)&&dg(t.style)||(og(t)||ag(t))&&rc(t.style)?delete t.style.location:lg(t)&&cc(t.children)})}function FR(e,t){t===void 0&&(t={}),t=$({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new OR(e,t).parse();if(n.err){var r=SyntaxError(se[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return t?.captureLocation||cc(n.val),n.val}var Rt;(function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"})(Rt||(Rt={}));var hn=function(e){yt(t,e);function t(n,r,i){var s=e.call(this,n)||this;return s.code=r,s.originalMessage=i,s}return t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),Dd=function(e){yt(t,e);function t(n,r,i,s){return e.call(this,'Invalid values for "'.concat(n,'": "').concat(r,'". Options are "').concat(Object.keys(i).join('", "'),'"'),Rt.INVALID_VALUE,s)||this}return t}(hn),HR=function(e){yt(t,e);function t(n,r,i){return e.call(this,'Value for "'.concat(n,'" must be of type ').concat(r),Rt.INVALID_VALUE,i)||this}return t}(hn),BR=function(e){yt(t,e);function t(n,r){return e.call(this,'The intl string context variable "'.concat(n,'" was not provided to the string "').concat(r,'"'),Rt.MISSING_VALUE,r)||this}return t}(hn),$e;(function(e){e[e.literal=0]="literal",e[e.object=1]="object"})($e||($e={}));function UR(e){return e.length<2?e:e.reduce(function(t,n){var r=t[t.length-1];return!r||r.type!==$e.literal||n.type!==$e.literal?t.push(n):r.value+=n.value,t},[])}function $R(e){return typeof e=="function"}function vs(e,t,n,r,i,s,o){if(e.length===1&&Rd(e[0]))return[{type:$e.literal,value:e[0].value}];for(var a=[],c=0,u=e;c<u.length;c++){var d=u[c];if(Rd(d)){a.push({type:$e.literal,value:d.value});continue}if(uR(d)){typeof s=="number"&&a.push({type:$e.literal,value:n.getNumberFormat(t).format(s)});continue}var l=d.value;if(!(i&&l in i))throw new BR(l,o);var f=i[l];if(cR(d)){(!f||typeof f=="string"||typeof f=="number")&&(f=typeof f=="string"||typeof f=="number"?String(f):""),a.push({type:typeof f=="string"?$e.literal:$e.object,value:f});continue}if(og(d)){var h=typeof d.style=="string"?r.date[d.style]:rc(d.style)?d.style.parsedOptions:void 0;a.push({type:$e.literal,value:n.getDateTimeFormat(t,h).format(f)});continue}if(ag(d)){var h=typeof d.style=="string"?r.time[d.style]:rc(d.style)?d.style.parsedOptions:r.time.medium;a.push({type:$e.literal,value:n.getDateTimeFormat(t,h).format(f)});continue}if(sg(d)){var h=typeof d.style=="string"?r.number[d.style]:dg(d.style)?d.style.parsedOptions:void 0;h&&h.scale&&(f=f*(h.scale||1)),a.push({type:$e.literal,value:n.getNumberFormat(t,h).format(f)});continue}if(lg(d)){var p=d.children,m=d.value,g=i[m];if(!$R(g))throw new HR(m,"function",o);var _=vs(p,t,n,r,i,s),v=g(_.map(function(O){return O.value}));Array.isArray(v)||(v=[v]),a.push.apply(a,v.map(function(O){return{type:typeof O=="string"?$e.literal:$e.object,value:O}}))}if(cg(d)){var L=d.options[f]||d.options.other;if(!L)throw new Dd(d.value,f,Object.keys(d.options),o);a.push.apply(a,vs(L.value,t,n,r,i));continue}if(ug(d)){var L=d.options["=".concat(f)];if(!L){if(!Intl.PluralRules)throw new hn(`Intl.PluralRules is not available in this environment.
500
+ Try polyfilling it using "@formatjs/intl-pluralrules"
501
+ `,Rt.MISSING_INTL_API,o);var A=n.getPluralRules(t,{type:d.pluralType}).select(f-(d.offset||0));L=d.options[A]||d.options.other}if(!L)throw new Dd(d.value,f,Object.keys(d.options),o);a.push.apply(a,vs(L.value,t,n,r,i,f-(d.offset||0)));continue}}return UR(a)}function WR(e,t){return t?$($($({},e||{}),t||{}),Object.keys(e).reduce(function(n,r){return n[r]=$($({},e[r]),t[r]||{}),n},{})):e}function GR(e,t){return t?Object.keys(e).reduce(function(n,r){return n[r]=WR(e[r],t[r]),n},$({},e)):e}function ra(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function zR(e){return e===void 0&&(e={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:wt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.NumberFormat).bind.apply(t,Ot([void 0],n,!1)))},{cache:ra(e.number),strategy:Tt.variadic}),getDateTimeFormat:wt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.DateTimeFormat).bind.apply(t,Ot([void 0],n,!1)))},{cache:ra(e.dateTime),strategy:Tt.variadic}),getPluralRules:wt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.PluralRules).bind.apply(t,Ot([void 0],n,!1)))},{cache:ra(e.pluralRules),strategy:Tt.variadic})}}var bg=function(){function e(t,n,r,i){n===void 0&&(n=e.defaultLocale);var s=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(c){var u=s.formatToParts(c);if(u.length===1)return u[0].value;var d=u.reduce(function(l,f){return!l.length||f.type!==$e.literal||typeof l[l.length-1]!="string"?l.push(f.value):l[l.length-1]+=f.value,l},[]);return d.length<=1?d[0]||"":d},this.formatToParts=function(c){return vs(s.ast,s.locales,s.formatters,s.formats,c,void 0,s.message)},this.resolvedOptions=function(){var c;return{locale:((c=s.resolvedLocale)===null||c===void 0?void 0:c.toString())||Intl.NumberFormat.supportedLocalesOf(s.locales)[0]}},this.getAst=function(){return s.ast},this.locales=n,this.resolvedLocale=e.resolveLocale(n),typeof t=="string"){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var o=i||{};o.formatters;var a=Ag(o,["formatters"]);this.ast=e.__parse(t,$($({},a),{locale:this.resolvedLocale}))}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=GR(e.formats,r),this.formatters=i&&i.formatters||zR(this.formatterCache)}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=new Intl.NumberFormat().resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.resolveLocale=function(t){if(!(typeof Intl.Locale>"u")){var n=Intl.NumberFormat.supportedLocalesOf(t);return n.length>0?new Intl.Locale(n[0]):new Intl.Locale(typeof t=="string"?t:t[0])}},e.__parse=FR,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}(),Ln;(function(e){e.FORMAT_ERROR="FORMAT_ERROR",e.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",e.INVALID_CONFIG="INVALID_CONFIG",e.MISSING_DATA="MISSING_DATA",e.MISSING_TRANSLATION="MISSING_TRANSLATION"})(Ln||(Ln={}));var Ri=function(e){yt(t,e);function t(n,r,i){var s=this,o=i?i instanceof Error?i:new Error(String(i)):void 0;return s=e.call(this,"[@formatjs/intl Error ".concat(n,"] ").concat(r,`
502
+ `).concat(o?`
503
+ `.concat(o.message,`
504
+ `).concat(o.stack):""))||this,s.code=n,typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(s,t),s}return t}(Error),jR=function(e){yt(t,e);function t(n,r){return e.call(this,Ln.UNSUPPORTED_FORMATTER,n,r)||this}return t}(Ri),qR=function(e){yt(t,e);function t(n,r){return e.call(this,Ln.INVALID_CONFIG,n,r)||this}return t}(Ri),Fd=function(e){yt(t,e);function t(n,r){return e.call(this,Ln.MISSING_DATA,n,r)||this}return t}(Ri),at=function(e){yt(t,e);function t(n,r,i){var s=e.call(this,Ln.FORMAT_ERROR,"".concat(n,`
505
+ Locale: `).concat(r,`
506
+ `),i)||this;return s.locale=r,s}return t}(Ri),ia=function(e){yt(t,e);function t(n,r,i,s){var o=e.call(this,"".concat(n,`
507
+ MessageID: `).concat(i?.id,`
508
+ Default Message: `).concat(i?.defaultMessage,`
509
+ Description: `).concat(i?.description,`
510
+ `),r,s)||this;return o.descriptor=i,o.locale=r,o}return t}(at),VR=function(e){yt(t,e);function t(n,r){var i=e.call(this,Ln.MISSING_TRANSLATION,'Missing message: "'.concat(n.id,'" for locale "').concat(r,'", using ').concat(n.defaultMessage?"default message (".concat(typeof n.defaultMessage=="string"?n.defaultMessage:n.defaultMessage.map(function(s){var o;return(o=s.value)!==null&&o!==void 0?o:JSON.stringify(s)}).join(),")"):"id"," as fallback."))||this;return i.descriptor=n,i}return t}(Ri);function XR(e,t,n){if(n===void 0&&(n=Error),!e)throw new n(t)}function Pr(e,t,n){return n===void 0&&(n={}),t.reduce(function(r,i){return i in e?r[i]=e[i]:i in n&&(r[i]=n[i]),r},{})}var YR=function(e){},JR=function(e){},KR={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:YR,onWarn:JR};function Sg(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function _n(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function ZR(e){e===void 0&&(e=Sg());var t=Intl.RelativeTimeFormat,n=Intl.ListFormat,r=Intl.DisplayNames,i=wt(function(){for(var a,c=[],u=0;u<arguments.length;u++)c[u]=arguments[u];return new((a=Intl.DateTimeFormat).bind.apply(a,Ot([void 0],c,!1)))},{cache:_n(e.dateTime),strategy:Tt.variadic}),s=wt(function(){for(var a,c=[],u=0;u<arguments.length;u++)c[u]=arguments[u];return new((a=Intl.NumberFormat).bind.apply(a,Ot([void 0],c,!1)))},{cache:_n(e.number),strategy:Tt.variadic}),o=wt(function(){for(var a,c=[],u=0;u<arguments.length;u++)c[u]=arguments[u];return new((a=Intl.PluralRules).bind.apply(a,Ot([void 0],c,!1)))},{cache:_n(e.pluralRules),strategy:Tt.variadic});return{getDateTimeFormat:i,getNumberFormat:s,getMessageFormat:wt(function(a,c,u,d){return new bg(a,c,u,$({formatters:{getNumberFormat:s,getDateTimeFormat:i,getPluralRules:o}},d||{}))},{cache:_n(e.message),strategy:Tt.variadic}),getRelativeTimeFormat:wt(function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];return new(t.bind.apply(t,Ot([void 0],a,!1)))},{cache:_n(e.relativeTime),strategy:Tt.variadic}),getPluralRules:o,getListFormat:wt(function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];return new(n.bind.apply(n,Ot([void 0],a,!1)))},{cache:_n(e.list),strategy:Tt.variadic}),getDisplayNames:wt(function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];return new(r.bind.apply(r,Ot([void 0],a,!1)))},{cache:_n(e.displayNames),strategy:Tt.variadic})}}function yu(e,t,n,r){var i=e&&e[t],s;if(i&&(s=i[n]),s)return s;r(new jR("No ".concat(t," format named: ").concat(n)))}function es(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=$({timeZone:t},e[r]),n},{})}function Hd(e,t){var n=Object.keys($($({},e),t));return n.reduce(function(r,i){return r[i]=$($({},e[i]||{}),t[i]||{}),r},{})}function Bd(e,t){if(!t)return e;var n=bg.formats;return $($($({},n),e),{date:Hd(es(n.date,t),es(e.date||{},t)),time:Hd(es(n.time,t),es(e.time||{},t))})}var Ud=function(e,t,n,r,i){var s=e.locale,o=e.formats,a=e.messages,c=e.defaultLocale,u=e.defaultFormats,d=e.fallbackOnEmptyString,l=e.onError,f=e.timeZone,h=e.defaultRichTextElements;n===void 0&&(n={id:""});var p=n.id,m=n.defaultMessage;XR(!!p,"[@formatjs/intl] An `id` must be provided to format a message. You can either:\n1. Configure your build toolchain with [babel-plugin-formatjs](https://formatjs.github.io/docs/tooling/babel-plugin)\nor [@formatjs/ts-transformer](https://formatjs.github.io/docs/tooling/ts-transformer) OR\n2. Configure your `eslint` config to include [eslint-plugin-formatjs](https://formatjs.github.io/docs/tooling/linter#enforce-id)\nto autofix this issue");var g=String(p),_=a&&Object.prototype.hasOwnProperty.call(a,g)&&a[g];if(Array.isArray(_)&&_.length===1&&_[0].type===_e.literal)return _[0].value;if(!r&&_&&typeof _=="string"&&!h)return _.replace(/'\{(.*?)\}'/gi,"{$1}");if(r=$($({},h),r||{}),o=Bd(o,f),u=Bd(u,f),!_){if(d===!1&&_==="")return _;if((!m||s&&s.toLowerCase()!==c.toLowerCase())&&l(new VR(n,s)),m)try{var v=t.getMessageFormat(m,c,u,i);return v.format(r)}catch(L){return l(new ia('Error formatting default message for: "'.concat(g,'", rendering default message verbatim'),s,n,L)),typeof m=="string"?m:g}return g}try{var v=t.getMessageFormat(_,s,o,$({formatters:t},i||{}));return v.format(r)}catch(L){l(new ia('Error formatting message: "'.concat(g,'", using ').concat(m?"default message":"id"," as fallback."),s,n,L))}if(m)try{var v=t.getMessageFormat(m,c,u,i);return v.format(r)}catch(L){l(new ia('Error formatting the default message for: "'.concat(g,'", rendering message verbatim'),s,n,L))}return typeof _=="string"?_:typeof m=="string"?m:g},QR=["formatMatcher","timeZone","hour12","weekday","era","year","month","day","hour","minute","second","timeZoneName","hourCycle","dateStyle","timeStyle","calendar","numberingSystem","fractionalSecondDigits"];function Ai(e,t,n,r){var i=e.locale,s=e.formats,o=e.onError,a=e.timeZone;r===void 0&&(r={});var c=r.format,u=$($({},a&&{timeZone:a}),c&&yu(s,t,c,o)),d=Pr(r,QR,u);return t==="time"&&!d.hour&&!d.minute&&!d.second&&!d.timeStyle&&!d.dateStyle&&(d=$($({},d),{hour:"numeric",minute:"numeric"})),n(i,d)}function eA(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=n[0],s=n[1],o=s===void 0?{}:s,a=typeof i=="string"?new Date(i||0):i;try{return Ai(e,"date",t,o).format(a)}catch(c){e.onError(new at("Error formatting date.",e.locale,c))}return String(a)}function tA(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=n[0],s=n[1],o=s===void 0?{}:s,a=typeof i=="string"?new Date(i||0):i;try{return Ai(e,"time",t,o).format(a)}catch(c){e.onError(new at("Error formatting time.",e.locale,c))}return String(a)}function nA(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=n[0],s=n[1],o=n[2],a=o===void 0?{}:o,c=typeof i=="string"?new Date(i||0):i,u=typeof s=="string"?new Date(s||0):s;try{return Ai(e,"dateTimeRange",t,a).formatRange(c,u)}catch(d){e.onError(new at("Error formatting date time range.",e.locale,d))}return String(c)}function rA(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=n[0],s=n[1],o=s===void 0?{}:s,a=typeof i=="string"?new Date(i||0):i;try{return Ai(e,"date",t,o).formatToParts(a)}catch(c){e.onError(new at("Error formatting date.",e.locale,c))}return[]}function iA(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=n[0],s=n[1],o=s===void 0?{}:s,a=typeof i=="string"?new Date(i||0):i;try{return Ai(e,"time",t,o).formatToParts(a)}catch(c){e.onError(new at("Error formatting time.",e.locale,c))}return[]}var sA=["style","type","fallback","languageDisplay"];function oA(e,t,n,r){var i=e.locale,s=e.onError,o=Intl.DisplayNames;o||s(new hn(`Intl.DisplayNames is not available in this environment.
511
+ Try polyfilling it using "@formatjs/intl-displaynames"
512
+ `,Rt.MISSING_INTL_API));var a=Pr(r,sA);try{return t(i,a).of(n)}catch(c){s(new at("Error formatting display name.",i,c))}}var aA=["type","style"],$d=Date.now();function cA(e){return"".concat($d,"_").concat(e,"_").concat($d)}function uA(e,t,n,r){r===void 0&&(r={});var i=Eg(e,t,n,r).reduce(function(s,o){var a=o.value;return typeof a!="string"?s.push(a):typeof s[s.length-1]=="string"?s[s.length-1]+=a:s.push(a),s},[]);return i.length===1?i[0]:i.length===0?"":i}function Eg(e,t,n,r){var i=e.locale,s=e.onError;r===void 0&&(r={});var o=Intl.ListFormat;o||s(new hn(`Intl.ListFormat is not available in this environment.
513
+ Try polyfilling it using "@formatjs/intl-listformat"
514
+ `,Rt.MISSING_INTL_API));var a=Pr(r,aA);try{var c={},u=Array.from(n).map(function(d,l){if(typeof d=="object"&&d!==null){var f=cA(l);return c[f]=d,f}return String(d)});return t(i,a).formatToParts(u).map(function(d){return d.type==="literal"?d:$($({},d),{value:c[d.value]||d.value})})}catch(d){s(new at("Error formatting list.",i,d))}return n}var lA=["type"];function dA(e,t,n,r){var i=e.locale,s=e.onError;r===void 0&&(r={}),Intl.PluralRules||s(new hn(`Intl.PluralRules is not available in this environment.
515
+ Try polyfilling it using "@formatjs/intl-pluralrules"
516
+ `,Rt.MISSING_INTL_API));var o=Pr(r,lA);try{return t(i,o).select(n)}catch(a){s(new at("Error formatting plural.",i,a))}return"other"}var fA=["numeric","style"];function hA(e,t,n){var r=e.locale,i=e.formats,s=e.onError;n===void 0&&(n={});var o=n.format,a=!!o&&yu(i,"relative",o,s)||{},c=Pr(n,fA,a);return t(r,c)}function pA(e,t,n,r,i){i===void 0&&(i={}),r||(r="second");var s=Intl.RelativeTimeFormat;s||e.onError(new hn(`Intl.RelativeTimeFormat is not available in this environment.
517
+ Try polyfilling it using "@formatjs/intl-relativetimeformat"
518
+ `,Rt.MISSING_INTL_API));try{return hA(e,t,i).format(n,r)}catch(o){e.onError(new at("Error formatting relative time.",e.locale,o))}return String(n)}var mA=["style","currency","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","currencyDisplay","currencySign","notation","signDisplay","unit","unitDisplay","numberingSystem","trailingZeroDisplay","roundingPriority","roundingIncrement","roundingMode"];function vg(e,t,n){var r=e.locale,i=e.formats,s=e.onError;n===void 0&&(n={});var o=n.format,a=o&&yu(i,"number",o,s)||{},c=Pr(n,mA,a);return t(r,c)}function gA(e,t,n,r){r===void 0&&(r={});try{return vg(e,t,r).format(n)}catch(i){e.onError(new at("Error formatting number.",e.locale,i))}return String(n)}function _A(e,t,n,r){r===void 0&&(r={});try{return vg(e,t,r).formatToParts(n)}catch(i){e.onError(new at("Error formatting number.",e.locale,i))}return[]}function yA(e){var t=e?e[Object.keys(e)[0]]:void 0;return typeof t=="string"}function bA(e){e.onWarn&&e.defaultRichTextElements&&yA(e.messages||{})&&e.onWarn(`[@formatjs/intl] "defaultRichTextElements" was specified but "message" was not pre-compiled.
519
+ Please consider using "@formatjs/cli" to pre-compile your messages for performance.
520
+ For more details see https://formatjs.github.io/docs/getting-started/message-distribution`)}function sa(e,t){var n=ZR(t),r=$($({},KR),e),i=r.locale,s=r.defaultLocale,o=r.onError;return i?!Intl.NumberFormat.supportedLocalesOf(i).length&&o?o(new Fd('Missing locale data for locale: "'.concat(i,'" in Intl.NumberFormat. Using default locale: "').concat(s,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):!Intl.DateTimeFormat.supportedLocalesOf(i).length&&o&&o(new Fd('Missing locale data for locale: "'.concat(i,'" in Intl.DateTimeFormat. Using default locale: "').concat(s,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):(o&&o(new qR('"locale" was not configured, using "'.concat(s,'" as fallback. See https://formatjs.github.io/docs/react-intl/api#intlshape for more details'))),r.locale=r.defaultLocale||"en"),bA(r),$($({},r),{formatters:n,formatNumber:gA.bind(null,r,n.getNumberFormat),formatNumberToParts:_A.bind(null,r,n.getNumberFormat),formatRelativeTime:pA.bind(null,r,n.getRelativeTimeFormat),formatDate:eA.bind(null,r,n.getDateTimeFormat),formatDateToParts:rA.bind(null,r,n.getDateTimeFormat),formatTime:tA.bind(null,r,n.getDateTimeFormat),formatDateTimeRange:nA.bind(null,r,n.getDateTimeFormat),formatTimeToParts:iA.bind(null,r,n.getDateTimeFormat),formatPlural:dA.bind(null,r,n.getPluralRules),formatMessage:Ud.bind(null,r,n),$t:Ud.bind(null,r,n),formatList:uA.bind(null,r,n.getListFormat),formatListToParts:Eg.bind(null,r,n.getListFormat),formatDisplayName:oA.bind(null,r,n.getDisplayNames)})}const{useCallback:Wd,useContext:SA,useMemo:Gd,useState:EA}=await Je("react"),oa=Sg(),wg=(e,t="",n={})=>(Object.entries(e).forEach(([r,i])=>{const s=t?`${t}.${r}`:r;if(typeof i=="string"){n[s]=i;return}if(i&&typeof i=="object"&&!Array.isArray(i)){wg(i,s,n);return}console.error(`Invalid translation value for key "${s}". Expected string or nested object.`)}),n),vA=e=>{const t=SA(ng);if(!e&&!t)throw new Error("useTranslation must be used with either options or within a TranslationProvider");if(!e&&t)return t;if(e&&!e.locale)throw new Error("locale is required when using useTranslation with options");if(e&&!e.translations)throw new Error("translations is required when using useTranslation with options");const n=e,[r,i]=EA({locale:n.locale,translations:n.translations,error:null}),s=Gd(()=>{const u={};return Object.entries(r.translations).forEach(([d,l])=>{u[d]=wg(l)}),u},[r.translations]),o=Gd(()=>{const u=s[r.locale],d=n.fallbackLocale&&s[n.fallbackLocale];if(!u&&d)return console.error(`No translations found for locale "${r.locale}". Using fallback locale "${n.fallbackLocale}".`),sa({locale:r.locale,messages:d},oa);if(!u)return console.error(`No translations found for locale "${r.locale}". Using empty translations.`),sa({locale:r.locale,messages:{}},oa);const f=n.fallbackLocale&&r.locale!==n.fallbackLocale&&d?{...d,...u}:u;return sa({locale:r.locale,messages:f},oa)},[r.locale,s,n.fallbackLocale]),a=Wd((u,d)=>o.formatMessage({id:u},d),[o]),c=Wd(u=>{if(!r.translations[u]){console.error(`Locale "${u}" not found in translations. Available locales: ${Object.keys(r.translations).join(", ")}`),i(d=>({...d,error:`Locale "${u}" not found`}));return}i(d=>({...d,locale:u,error:null}))},[r.translations]);return{t:a,intl:o,locale:r.locale,setLocale:c,error:r.error}},{useMemo:wA}=await Je("react"),dM=e=>{const{locale:t,translations:n,fallbackLocale:r,children:i}=e,s=vA({locale:t,translations:n,fallbackLocale:r}),o=wA(()=>s,[s]);return hf.jsx(ng.Provider,{value:o,children:i})};var TA="2.0.7",IA=500,zd="user-agent",Tr="",jd="?",Ie={FUNCTION:"function",OBJECT:"object",STRING:"string",UNDEFINED:"undefined"},Xe="browser",Ht="cpu",xt="device",ft="engine",nt="os",Ir="result",E="name",b="type",w="vendor",I="version",We="architecture",ui="major",S="model",ws="console",Y="mobile",de="tablet",Ce="smarttv",vt="wearable",ts="xr",Xr="embedded",Vn="inapp",bu="brands",En="formFactors",Su="fullVersionList",xr="platform",Eu="platformVersion",Io="bitness",pn="sec-ch-ua",xA=pn+"-full-version-list",kA=pn+"-arch",CA=pn+"-"+Io,RA=pn+"-form-factors",AA=pn+"-"+Y,MA=pn+"-"+S,Tg=pn+"-"+xr,NA=Tg+"-version",Ig=[bu,Su,Y,S,xr,Eu,We,En,Io],ns="Amazon",Xn="Apple",qd="ASUS",Vd="BlackBerry",yn="Google",Xd="Huawei",aa="Lenovo",Yd="Honor",rs="LG",ca="Microsoft",ua="Motorola",Jd="Nvidia",Kd="OnePlus",la="OPPO",Ur="Samsung",Zd="Sharp",$r="Sony",da="Xiaomi",fa="Zebra",Qd="Chrome",ef="Chromium",Jt="Chromecast",Ts="Edge",Wr="Firefox",Gr="Opera",ha="Facebook",tf="Sogou",Yn="Mobile ",zr=" Browser",uc="Windows",OA=typeof window!==Ie.UNDEFINED,Ve=OA&&window.navigator?window.navigator:void 0,vn=Ve&&Ve.userAgentData?Ve.userAgentData:void 0,LA=function(e,t){var n={},r=t;if(!Zs(t)){r={};for(var i in t)for(var s in t[i])r[s]=t[i][s].concat(r[s]?r[s]:[])}for(var o in e)n[o]=r[o]&&r[o].length%2===0?r[o].concat(e[o]):e[o];return n},xo=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},lc=function(e,t){if(typeof e===Ie.OBJECT&&e.length>0){for(var n in e)if(tn(t)==tn(e[n]))return!0;return!1}return Mi(e)?tn(t)==tn(e):!1},Zs=function(e,t){for(var n in e)return/^(browser|cpu|device|engine|os)$/.test(n)||(t?Zs(e[n]):!1)},Mi=function(e){return typeof e===Ie.STRING},pa=function(e){if(e){for(var t=[],n=kr(/\\?\"/g,e).split(","),r=0;r<n.length;r++)if(n[r].indexOf(";")>-1){var i=Qs(n[r]).split(";v=");t[r]={brand:i[0],version:i[1]}}else t[r]=Qs(n[r]);return t}},tn=function(e){return Mi(e)?e.toLowerCase():e},dc=function(e){return Mi(e)?kr(/[^\d\.]/g,e).split(".")[0]:void 0},Pt=function(e){for(var t in e)if(e.hasOwnProperty(t)){var n=e[t];typeof n==Ie.OBJECT&&n.length==2?this[n[0]]=n[1]:this[n]=void 0}return this},kr=function(e,t){return Mi(t)?t.replace(e,Tr):t},jr=function(e){return kr(/\\?\"/g,e)},Qs=function(e,t){return e=kr(/^\s\s*/,String(e)),typeof t===Ie.UNDEFINED?e:e.substring(0,t)},fc=function(e,t){if(!(!e||!t))for(var n=0,r,i,s,o,a,c;n<t.length&&!a;){var u=t[n],d=t[n+1];for(r=i=0;r<u.length&&!a&&u[r];)if(a=u[r++].exec(e),a)for(s=0;s<d.length;s++)c=a[++i],o=d[s],typeof o===Ie.OBJECT&&o.length>0?o.length===2?typeof o[1]==Ie.FUNCTION?this[o[0]]=o[1].call(this,c):this[o[0]]=o[1]:o.length>=3&&(typeof o[1]===Ie.FUNCTION&&!(o[1].exec&&o[1].test)?o.length>3?this[o[0]]=c?o[1].apply(this,o.slice(2)):void 0:this[o[0]]=c?o[1].call(this,c,o[2]):void 0:o.length==3?this[o[0]]=c?c.replace(o[1],o[2]):void 0:o.length==4?this[o[0]]=c?o[3].call(this,c.replace(o[1],o[2])):void 0:o.length>4&&(this[o[0]]=c?o[3].apply(this,[c.replace(o[1],o[2])].concat(o.slice(4))):void 0)):this[o]=c||void 0;n+=2}},lt=function(e,t){for(var n in t)if(typeof t[n]===Ie.OBJECT&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(lc(t[n][r],e))return n===jd?void 0:n}else if(lc(t[n],e))return n===jd?void 0:n;return t.hasOwnProperty("*")?t["*"]:e},nf={ME:"4.90","NT 3.51":"3.51","NT 4.0":"4.0",2e3:["5.0","5.01"],XP:["5.1","5.2"],Vista:"6.0",7:"6.1",8:"6.2","8.1":"6.3",10:["6.4","10.0"],NT:""},rf={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},PA={Chrome:"Google Chrome",Edge:"Microsoft Edge","Edge WebView2":"Microsoft Edge WebView2","Chrome WebView":"Android WebView","Chrome Headless":"HeadlessChrome","Huawei Browser":"HuaweiBrowser","MIUI Browser":"Miui Browser","Opera Mobi":"OperaMobile",Yandex:"YaBrowser"},sf={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[I,[E,Yn+"Chrome"]],[/webview.+edge\/([\w\.]+)/i],[I,[E,Ts+" WebView"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[I,[E,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[E,I],[/opios[\/ ]+([\w\.]+)/i],[I,[E,Gr+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[I,[E,Gr+" GX"]],[/\bopr\/([\w\.]+)/i],[I,[E,Gr]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[I,[E,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[I,[E,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(atlas|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon|otter|dooble|(?:lg |qute)browser|palemoon)\/([-\w\.]+)/i,/(heytap|ovi|115|surf|qwant)browser\/([\d\.]+)/i,/(qwant)(?:ios|mobile)\/([\d\.]+)/i,/(ecosia|weibo)(?:__| \w+@)([\d\.]+)/i],[E,I],[/quark(?:pc)?\/([-\w\.]+)/i],[I,[E,"Quark"]],[/\bddg\/([\w\.]+)/i],[I,[E,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[I,[E,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[I,[E,"WeChat"]],[/konqueror\/([\w\.]+)/i],[I,[E,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[I,[E,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[I,[E,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[I,[E,"Smart "+aa+zr]],[/(avast|avg)\/([\w\.]+)/i],[[E,/(.+)/,"$1 Secure"+zr],I],[/\bfocus\/([\w\.]+)/i],[I,[E,Wr+" Focus"]],[/\bopt\/([\w\.]+)/i],[I,[E,Gr+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[I,[E,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[I,[E,"Dolphin"]],[/coast\/([\w\.]+)/i],[I,[E,Gr+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[I,[E,"MIUI"+zr]],[/fxios\/([\w\.-]+)/i],[I,[E,Yn+Wr]],[/\bqihoobrowser\/?([\w\.]*)/i],[I,[E,"360"]],[/\b(qq)\/([\w\.]+)/i],[[E,/(.+)/,"$1Browser"],I],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[E,/(.+)/,"$1"+zr],I],[/samsungbrowser\/([\w\.]+)/i],[I,[E,Ur+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[I,[E,tf+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[E,tf+" Mobile"],I],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[E,I],[/(lbbrowser|rekonq|steam(?= (clie|tenf|gameo)))/i],[E],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[I,E],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[E,ha],I,[b,Vn]],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(bing)(?:web|sapphire)\/([\w\.]+)/i,/(instagram|snapchat|klarna)[\/ ]([-\w\.]+)/i],[E,I,[b,Vn]],[/\bgsa\/([\w\.]+) .*safari\//i],[I,[E,"GSA"],[b,Vn]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[I,[E,"TikTok"],[b,Vn]],[/\[(linkedin)app\]/i],[E,[b,Vn]],[/(zalo(?:app)?)[\/\sa-z]*([\w\.-]+)/i],[[E,/(.+)/,"Zalo"],I,[b,Vn]],[/(chromium)[\/ ]([-\w\.]+)/i],[E,I],[/headlesschrome(?:\/([\w\.]+)| )/i],[I,[E,Qd+" Headless"]],[/wv\).+chrome\/([\w\.]+).+edgw\//i],[I,[E,Ts+" WebView2"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[E,Qd+" WebView"],I],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[I,[E,"Android"+zr]],[/chrome\/([\w\.]+) mobile/i],[I,[E,Yn+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[E,I],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[I,[E,Yn+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[E,Yn+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[I,E],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[E,[I,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[E,I],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[E,Yn+Wr],I],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[E,"Netscape"],I],[/(wolvic|librewolf)\/([\w\.]+)/i],[E,I],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[I,[E,Wr+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+(?= .+rv\:.+gecko\/\d+)|[0-4][\w\.]+(?!.+compatible))/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[E,[I,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[E,[I,/[^\d\.]+./,Tr]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[We,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[We,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[We,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[We,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[We,"arm"]],[/ sun4\w[;\)]/i],[[We,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i,/((ppc|powerpc)(64)?)( mac|;|\))/i,/(?:osf1|[freopnt]{3,4}bsd) (alpha)/i],[[We,/ower/,Tr,tn]],[/mc680.0/i],[[We,"68k"]],[/winnt.+\[axp/i],[[We,"alpha"]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[S,[w,Ur],[b,de]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr]|browser)[-\w]+)/i,/sec-(sgh\w+)/i],[S,[w,Ur],[b,Y]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)[\/\);]/i],[S,[w,Xn],[b,Y]],[/\b(?:ios|apple\w+)\/.+[\(\/](ipad)/i,/\b(ipad)[\d,]*[;\] ].+(mac |i(pad)?)os/i],[S,[w,Xn],[b,de]],[/(macintosh);/i],[S,[w,Xn]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[S,[w,Zd],[b,Y]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[S,[w,Yd],[b,de]],[/honor([-\w ]+)[;\)]/i],[S,[w,Yd],[b,Y]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[S,[w,Xd],[b,de]],[/(?:huawei) ?([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][\dc][adnt]?)\b(?!.+d\/s)/i],[S,[w,Xd],[b,Y]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b(?:xiao)?((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[S,/_/g," "],[w,da],[b,de]],[/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/oid[^\)]+; (redmi[\-_ ]?(?:note|k)?[\w_ ]+|m?[12]\d[01]\d\w{3,6}|poco[\w ]+|(shark )?\w{3}-[ah]0|qin ?[1-3](s\+|ultra| pro)?)( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note|max|cc)?[_ ]?(?:\d{0,2}\w?)[_ ]?(?:plus|se|lite|pro)?( 5g|lte)?)(?: bui|\))/i,/ ([\w ]+) miui\/v?\d/i],[[S,/_/g," "],[w,da],[b,Y]],[/droid.+; (cph2[3-6]\d[13579]|((gm|hd)19|(ac|be|in|kb)20|(d[en]|eb|le|mt)21|ne22)[0-2]\d|p[g-k]\w[1m]10)\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[S,[w,Kd],[b,Y]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[S,[w,la],[b,Y]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[S,[w,lt,{OnePlus:["203","304","403","404","413","415"],"*":la}],[b,de]],[/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i],[S,[w,"BLU"],[b,Y]],[/; vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[S,[w,"Vivo"],[b,Y]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[S,[w,"Realme"],[b,Y]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[S,[w,aa],[b,de]],[/lenovo[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i],[S,[w,aa],[b,Y]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ]([\w\s]+)(\)| bui)/i,/((?:moto(?! 360)[-\w\(\) ]+|xt\d{3,4}[cgkosw\+]?[-\d]*|nexus 6)(?= bui|\)))/i],[S,[w,ua],[b,Y]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[S,[w,ua],[b,de]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[S,[w,rs],[b,de]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch|webos))(\w+)/i,/\blg-?([\d\w]+) bui/i],[S,[w,rs],[b,Y]],[/(nokia) (t[12][01])/i],[w,S,[b,de]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*?))( bui|\)|;|\/)/i],[[S,/_/g," "],[b,Y],[w,"Nokia"]],[/(pixel (c|tablet))\b/i],[S,[w,yn],[b,de]],[/droid.+;(?: google)? (g(01[13]a|020[aem]|025[jn]|1b60|1f8f|2ybb|4s1m|576d|5nz6|8hhn|8vou|a02099|c15s|d1yq|e2ae|ec77|gh2x|kv4x|p4bc|pj41|r83y|tt9q|ur25|wvk6)|pixel[\d ]*a?( pro)?( xl)?( fold)?( \(5g\))?)( bui|\))/i],[S,[w,yn],[b,Y]],[/(google) (pixelbook( go)?)/i],[w,S],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-\w\w\d\d)(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[S,[w,$r],[b,Y]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[S,"Xperia Tablet"],[w,$r],[b,de]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[S,[w,ns],[b,de]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[S,/(.+)/g,"Fire Phone $1"],[w,ns],[b,Y]],[/(playbook);[-\w\),; ]+(rim)/i],[S,w,[b,de]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/(?:blackberry|\(bb10;) (\w+)/i],[S,[w,Vd],[b,Y]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[S,[w,qd],[b,de]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[S,[w,qd],[b,Y]],[/(nexus 9)/i],[S,[w,"HTC"],[b,de]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[w,[S,/_/g," "],[b,Y]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[S,[w,"TCL"],[b,de]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[S,[w,"TCL"],[b,Y]],[/(itel) ((\w+))/i],[[w,tn],S,[b,lt,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[S,[w,"Acer"],[b,de]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[S,[w,"Meizu"],[b,Y]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[S,[w,"Ulefone"],[b,Y]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[S,[w,"Energizer"],[b,Y]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[S,[w,"Cat"],[b,Y]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[S,[w,"Smartfren"],[b,Y]],[/droid.+; (a(in)?(0(15|59|6[35])|142)p?)/i],[S,[w,"Nothing"],[b,Y]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[S,[w,"Archos"],[b,de]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[S,[w,"Archos"],[b,Y]],[/; (n159v)/i],[S,[w,"HMD"],[b,Y]],[/(imo) (tab \w+)/i,/(infinix|tecno) (x1101b?|p904|dp(7c|8d|10a)( pro)?|p70[1-3]a?|p904|t1101)/i],[w,S,[b,de]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (blu|hmd|imo|infinix|lava|oneplus|tcl|wiko)[_ ]([\w\+ ]+?)(?: bui|\)|; r)/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(oppo) ?([\w ]+) bui/i,/(hisense) ([ehv][\w ]+)\)/i,/droid[^;]+; (philips)[_ ]([sv-x][\d]{3,4}[xz]?)/i],[w,S,[b,Y]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[w,S,[b,de]],[/(surface duo)/i],[S,[w,ca],[b,de]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[S,[w,"Fairphone"],[b,Y]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[S,[w,Jd],[b,de]],[/(sprint) (\w+)/i],[w,S,[b,Y]],[/(kin\.[onetw]{3})/i],[[S,/\./g," "],[w,ca],[b,Y]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[S,[w,fa],[b,de]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[S,[w,fa],[b,Y]],[/(philips)[\w ]+tv/i,/smart-tv.+(samsung)/i],[w,[b,Ce]],[/hbbtv.+maple;(\d+)/i],[[S,/^/,"SmartTV"],[w,Ur],[b,Ce]],[/(vizio)(?: |.+model\/)(\w+-\w+)/i,/tcast.+(lg)e?. ([-\w]+)/i],[w,S,[b,Ce]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[w,rs],[b,Ce]],[/(apple) ?tv/i],[w,[S,Xn+" TV"],[b,Ce]],[/crkey.*devicetype\/chromecast/i],[[S,Jt+" Third Generation"],[w,yn],[b,Ce]],[/crkey.*devicetype\/([^/]*)/i],[[S,/^/,"Chromecast "],[w,yn],[b,Ce]],[/fuchsia.*crkey/i],[[S,Jt+" Nest Hub"],[w,yn],[b,Ce]],[/crkey/i],[[S,Jt],[w,yn],[b,Ce]],[/(portaltv)/i],[S,[w,ha],[b,Ce]],[/droid.+aft(\w+)( bui|\))/i],[S,[w,ns],[b,Ce]],[/(shield \w+ tv)/i],[S,[w,Jd],[b,Ce]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[S,[w,Zd],[b,Ce]],[/(bravia[\w ]+)( bui|\))/i],[S,[w,$r],[b,Ce]],[/(mi(tv|box)-?\w+) bui/i],[S,[w,da],[b,Ce]],[/Hbbtv.*(technisat) (.*);/i],[w,S,[b,Ce]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[w,/.+\/(\w+)/,"$1",lt,{LG:"lge"}],[S,Qs],[b,Ce]],[/(playstation \w+)/i],[S,[w,$r],[b,ws]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[S,[w,ca],[b,ws]],[/(ouya)/i,/(nintendo) (\w+)/i,/(retroid) (pocket ([^\)]+))/i,/(valve).+(steam deck)/i,/droid.+; ((shield|rgcube|gr0006))( bui|\))/i],[[w,lt,{Nvidia:"Shield",Anbernic:"RGCUBE",Logitech:"GR0006"}],S,[b,ws]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[S,[w,Ur],[b,vt]],[/((pebble))app/i,/(asus|google|lg|oppo|xiaomi) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[w,S,[b,vt]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[S,[w,la],[b,vt]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[S,[w,Xn],[b,vt]],[/(opwwe\d{3})/i],[S,[w,Kd],[b,vt]],[/(moto 360)/i],[S,[w,ua],[b,vt]],[/(smartwatch 3)/i],[S,[w,$r],[b,vt]],[/(g watch r)/i],[S,[w,rs],[b,vt]],[/droid.+; (wt63?0{2,3})\)/i],[S,[w,fa],[b,vt]],[/droid.+; (glass) \d/i],[S,[w,yn],[b,ts]],[/(pico) ([\w ]+) os\d/i],[w,S,[b,ts]],[/(quest( \d| pro)?s?).+vr/i],[S,[w,ha],[b,ts]],[/mobile vr; rv.+firefox/i],[[b,ts]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[w,[b,Xr]],[/(aeobc)\b/i],[S,[w,ns],[b,Xr]],[/(homepod).+mac os/i],[S,[w,Xn],[b,Xr]],[/windows iot/i],[[b,Xr]],[/droid.+; ([\w- ]+) (4k|android|smart|google)[- ]?tv/i],[S,[b,Ce]],[/\b((4k|android|smart|opera)[- ]?tv|tv; rv:|large screen[\w ]+safari)\b/i],[[b,Ce]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew|; hmsc).+?(mobile|vr|\d) safari/i],[S,[b,lt,{mobile:"Mobile",xr:"VR","*":de}]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[b,de]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[b,Y]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[S,[w,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[I,[E,Ts+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[E,I],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[I,[E,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[E,I],[/ladybird\//i],[[E,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[I,E]],os:[[/(windows nt) (6\.[23]); arm/i],[[E,/N/,"R"],[I,lt,nf]],[/(windows (?:phone|mobile|iot))(?: os)?[\/ ]?([\d\.]*( se)?)/i,/(windows)[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i],[E,I],[/windows nt ?([\d\.\)]*)(?!.+xbox)/i,/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d\.;]*)/i],[[I,/(;|\))/g,"",lt,nf],[E,uc]],[/(windows ce)\/?([\d\.]*)/i],[E,I],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv|ios(?=.+ip(?:ad|hone)|.+apple ?tv)|ip(?:ad|hone)(?: |.+i(?:pad)?)os|apple ?tv.+ios)[\/ ]([\w\.]+)/i,/\btvos ?([\w\.]+)/i,/cfnetwork\/.+darwin/i],[[I,/_/g,"."],[E,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i],[[E,"macOS"],[I,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[I,[E,Jt+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[I,[E,Jt+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[I,[E,Jt+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[I,[E,Jt+" Linux"]],[/crkey\/([\d\.]+)/i],[I,[E,Jt]],[/droid ([\w\.]+)\b.+(android[- ]x86)/i],[I,E],[/(ubuntu) ([\w\.]+) like android/i],[[E,/(.+)/,"$1 Touch"],I],[/(harmonyos)[\/ ]?([\d\.]*)/i,/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen)\w*[-\/\.; ]?([\d\.]*)/i],[E,I],[/\(bb(10);/i],[I,[E,Vd]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[I,[E,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[I,[E,Wr+" OS"]],[/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i,/webos(?:[ \/]?|\.tv-20(?=2[2-9]))(\d[\d\.]*)/i],[I,[E,"webOS"]],[/web0s;.+?(?:chr[o0]me|safari)\/(\d+)/i],[[I,lt,{25:"120",24:"108",23:"94",22:"87",6:"79",5:"68",4:"53",3:"38",2:"538",1:"537","*":"TV"}],[E,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[I,[E,"watchOS"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[E,"Chrome OS"],I],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/linux.+(mint)[\/\(\) ]?([\w\.]*)/i,/(mageia|vectorlinux|fuchsia|arcaos|arch(?= ?linux))[;l ]([\d\.]*)/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire|knoppix)(?: gnu[\/ ]linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/\b(aix)[; ]([1-9\.]{0,4})/i,/(hurd|linux|morphos)(?: (?:arm|x86|ppc)\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) ?(r\d)?/i],[E,I],[/(sunos) ?([\d\.]*)/i],[[E,"Solaris"],I],[/\b(beos|os\/2|amigaos|openvms|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[E,I]]},is=function(){var e={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return Pt.call(e.init,[[Xe,[E,I,ui,b]],[Ht,[We]],[xt,[b,S,w]],[ft,[E,I]],[nt,[E,I]]]),Pt.call(e.isIgnore,[[Xe,[I,ui]],[ft,[I]],[nt,[I]]]),Pt.call(e.isIgnoreRgx,[[Xe,/ ?browser$/i],[nt,/ ?os$/i]]),Pt.call(e.toString,[[Xe,[E,I]],[Ht,[We]],[xt,[w,S]],[ft,[E,I]],[nt,[E,I]]]),e}(),DA=function(e,t){var n=is.init[t],r=is.isIgnore[t]||0,i=is.isIgnoreRgx[t]||0,s=is.toString[t]||0;function o(){Pt.call(this,n)}return o.prototype.getItem=function(){return e},o.prototype.withClientHints=function(){return vn?vn.getHighEntropyValues(Ig).then(function(a){return e.setCH(new xg(a,!1)).parseCH().get()}):e.parseCH().get()},o.prototype.withFeatureCheck=function(){return e.detectFeature().get()},t!=Ir&&(o.prototype.is=function(a){var c=!1;for(var u in this)if(this.hasOwnProperty(u)&&!lc(r,u)&&tn(i?kr(i,this[u]):this[u])==tn(i?kr(i,a):a)){if(c=!0,a!=Ie.UNDEFINED)break}else if(a==Ie.UNDEFINED&&c){c=!c;break}return c},o.prototype.toString=function(){var a=Tr;for(var c in s)typeof this[s[c]]!==Ie.UNDEFINED&&(a+=(a?" ":Tr)+this[s[c]]);return a||Ie.UNDEFINED}),o.prototype.then=function(a){var c=this,u=function(){for(var l in c)c.hasOwnProperty(l)&&(this[l]=c[l])};u.prototype={is:o.prototype.is,toString:o.prototype.toString,withClientHints:o.prototype.withClientHints,withFeatureCheck:o.prototype.withFeatureCheck};var d=new u;return a(d),d},new o};function xg(e,t){if(e=e||{},Pt.call(this,Ig),t)Pt.call(this,[[bu,pa(e[pn])],[Su,pa(e[xA])],[Y,/\?1/.test(e[AA])],[S,jr(e[MA])],[xr,jr(e[Tg])],[Eu,jr(e[NA])],[We,jr(e[kA])],[En,pa(e[RA])],[Io,jr(e[CA])]]);else for(var n in e)this.hasOwnProperty(n)&&typeof e[n]!==Ie.UNDEFINED&&(this[n]=e[n])}function cn(e,t,n,r){return Pt.call(this,[["itemType",e],["ua",t],["uaCH",r],["rgxMap",n],["data",DA(this,e)]]),this}cn.prototype.get=function(e){return e?this.data.hasOwnProperty(e)?this.data[e]:void 0:this.data};cn.prototype.set=function(e,t){return this.data[e]=t,this};cn.prototype.setCH=function(e){return this.uaCH=e,this};cn.prototype.detectFeature=function(){if(Ve&&Ve.userAgent==this.ua)switch(this.itemType){case Xe:Ve.brave&&typeof Ve.brave.isBrave==Ie.FUNCTION&&this.set(E,"Brave");break;case xt:!this.get(b)&&vn&&vn[Y]&&this.set(b,Y),this.get(S)=="Macintosh"&&Ve&&typeof Ve.standalone!==Ie.UNDEFINED&&Ve.maxTouchPoints&&Ve.maxTouchPoints>2&&this.set(S,"iPad").set(b,de);break;case nt:!this.get(E)&&vn&&vn[xr]&&this.set(E,vn[xr]);break;case Ir:var e=this.data,t=function(n){return e[n].getItem().detectFeature().get()};this.set(Xe,t(Xe)).set(Ht,t(Ht)).set(xt,t(xt)).set(ft,t(ft)).set(nt,t(nt))}return this};cn.prototype.parseUA=function(){switch(this.itemType!=Ir&&fc.call(this.data,this.ua,this.rgxMap),this.itemType){case Xe:this.set(ui,dc(this.get(I)));break;case nt:if(this.get(E)=="iOS"&&this.get(I)=="18.6"){var e=/\) Version\/([\d\.]+)/.exec(this.ua);e&&parseInt(e[1].substring(0,2),10)>=26&&this.set(I,e[1])}break}return this};cn.prototype.parseCH=function(){var e=this.uaCH,t=this.rgxMap;switch(this.itemType){case Xe:case ft:var n=e[Su]||e[bu],r;if(n)for(var i=0;i<n.length;i++){var s=n[i].brand||n[i],o=n[i].version;this.itemType==Xe&&!/not.a.brand/i.test(s)&&(!r||/Chrom/.test(r)&&s!=ef||r==Ts&&/WebView2/.test(s))&&(s=lt(s,PA),r=this.get(E),r&&!/Chrom/.test(r)&&/Chrom/.test(s)||this.set(E,s).set(I,o).set(ui,dc(o)),r=s),this.itemType==ft&&s==ef&&this.set(I,o)}break;case Ht:var a=e[We];a&&(a&&e[Io]=="64"&&(a+="64"),fc.call(this.data,a+";",t));break;case xt:if(e[Y]&&this.set(b,Y),e[S]&&(this.set(S,e[S]),!this.get(b)||!this.get(w))){var c={};fc.call(c,"droid 9; "+e[S]+")",t),!this.get(b)&&c.type&&this.set(b,c.type),!this.get(w)&&c.vendor&&this.set(w,c.vendor)}if(e[En]){var u;if(typeof e[En]!="string")for(var d=0;!u&&d<e[En].length;)u=lt(e[En][d++],rf);else u=lt(e[En],rf);this.set(b,u)}break;case nt:var l=e[xr];if(l){var f=e[Eu];l==uc&&(f=parseInt(dc(f),10)>=13?"11":"10"),this.set(E,l).set(I,f)}this.get(E)==uc&&e[S]=="Xbox"&&this.set(E,"Xbox").set(I,void 0);break;case Ir:var h=this.data,p=function(m){return h[m].getItem().setCH(e).parseCH().get()};this.set(Xe,p(Xe)).set(Ht,p(Ht)).set(xt,p(xt)).set(ft,p(ft)).set(nt,p(nt))}return this};function _t(e,t,n){if(typeof e===Ie.OBJECT?(Zs(e,!0)?(typeof t===Ie.OBJECT&&(n=t),t=e):(n=e,t=void 0),e=void 0):typeof e===Ie.STRING&&!Zs(t,!0)&&(n=t,t=void 0),n)if(typeof n.append===Ie.FUNCTION){var r={};n.forEach(function(d,l){r[String(l).toLowerCase()]=d}),n=r}else{var i={};for(var s in n)n.hasOwnProperty(s)&&(i[String(s).toLowerCase()]=n[s]);n=i}if(!(this instanceof _t))return new _t(e,t,n).getResult();var o=typeof e===Ie.STRING?e:n&&n[zd]?n[zd]:Ve&&Ve.userAgent?Ve.userAgent:Tr,a=new xg(n,!0),c=t?LA(sf,t):sf,u=function(d){return d==Ir?function(){return new cn(d,o,c,a).set("ua",o).set(Xe,this.getBrowser()).set(Ht,this.getCPU()).set(xt,this.getDevice()).set(ft,this.getEngine()).set(nt,this.getOS()).get()}:function(){return new cn(d,o,c[d],a).parseUA().get()}};return Pt.call(this,[["getBrowser",u(Xe)],["getCPU",u(Ht)],["getDevice",u(xt)],["getEngine",u(ft)],["getOS",u(nt)],["getResult",u(Ir)],["getUA",function(){return o}],["setUA",function(d){return Mi(d)&&(o=Qs(d,IA)),this}]]).setUA(o),this}_t.VERSION=TA;_t.BROWSER=xo([E,I,ui,b]);_t.CPU=xo([We]);_t.DEVICE=xo([S,w,b,ws,Y,Ce,de,vt,Xr]);_t.ENGINE=_t.OS=xo([E,I]);const FA=Object.freeze({"68K":"68k",ALPHA:"alpha",ARM:"arm",ARM_64:"arm64",ARM_HF:"armhf",AVR:"avr",AVR_32:"avr32",IA64:"ia64",IRIX:"irix",IRIX_64:"irix64",MIPS:"mips",MIPS_64:"mips64",PA_RISC:"pa-risc",PPC:"ppc",SPARC:"sparc",SPARC_64:"sparc64",X86:"ia32",X86_64:"amd64"}),HA=Object.freeze({AIX:"AIX",AMIGA_OS:"Amiga OS",ANDROID:"Android",ANDROID_X86:"Android-x86",ARCAOS:"ArcaOS",ARCH:"Arch",BADA:"Bada",BEOS:"BeOS",BLACKBERRY:"BlackBerry",CENTOS:"CentOS",CHROME_OS:"Chrome OS",CHROMECAST:"Chromecast",CHROMECAST_ANDROID:"Chromecast Android",CHROMECAST_FUCHSIA:"Chromecast Fuchsia",CHROMECAST_LINUX:"Chromecast Linux",CHROMECAST_SMARTSPEAKER:"Chromecast SmartSpeaker",CONTIKI:"Contiki",DEBIAN:"Debian",DEEPIN:"Deepin",DRAGONFLY:"DragonFly",ELEMENTARY_OS:"elementary OS",FEDORA:"Fedora",FIREFOX_OS:"Firefox OS",FREEBSD:"FreeBSD",FUCHSIA:"Fuchsia",GENTOO:"Gentoo",GHOSTBSD:"GhostBSD",GNU:"GNU",HAIKU:"Haiku",HARMONYOS:"HarmonyOS",HP_UX:"HP-UX",HURD:"Hurd",IOS:"iOS",JOLI:"Joli",KAIOS:"KaiOS",KNOPPIX:"Knoppix",KUBUNTU:"Kubuntu",LINPUS:"Linpus",LINSPIRE:"Linspire",LINUX:"Linux",MACOS:"macOS",MAEMO:"Maemo",MAGEIA:"Mageia",MANDRIVA:"Mandriva",MANJARO:"Manjaro",MEEGO:"MeeGo",MINIX:"Minix",MINT:"Mint",MORPH_OS:"Morph OS",NETBSD:"NetBSD",NETRANGE:"NetRange",NETTV:"NetTV",NINTENDO:"Nintendo",OPENHARMONY:"OpenHarmony",OPENBSD:"OpenBSD",OPENVMS:"OpenVMS",OS2:"OS/2",PALM:"Palm",PC_BSD:"PC-BSD",PCLINUXOS:"PCLinuxOS",PICO:"Pico",PLAN9:"Plan9",PLAYSTATION:"PlayStation",QNX:"QNX",RASPBIAN:"Raspbian",REDHAT:"RedHat",RIM_TABLET_OS:"RIM Tablet OS",RISC_OS:"RISC OS",SABAYON:"Sabayon",SAILFISH:"Sailfish",SERENITYOS:"SerenityOS",SERIES40:"Series40",SLACKWARE:"Slackware",SOLARIS:"Solaris",SUSE:"SUSE",SYMBIAN:"Symbian",TIZEN:"Tizen",UBUNTU:"Ubuntu",UBUNTU_TOUCH:"Ubuntu Touch",UNIX:"Unix",VECTORLINUX:"VectorLinux",WATCHOS:"watchOS",WEBOS:"WebOS",WINDOWS:"Windows",WINDOWS_CE:"Windows CE",WINDOWS_IOT:"Windows IoT",WINDOWS_MOBILE:"Windows Mobile",WINDOWS_PHONE:"Windows Phone",WINDOWS_RT:"Windows RT",XBOX:"Xbox",XUBUNTU:"Xubuntu",ZENWALK:"Zenwalk"}),BA=e=>{const{os:t,cpu:n}=typeof e!="string"?e:{os:new _t(e).getOS(),cpu:new _t(e).getCPU()};if(t.is(HA.MACOS)){if(n.is(FA.ARM))return!0;if(typeof window<"u")try{const r=document.createElement("canvas"),i=r.getContext("webgl2")||r.getContext("webgl")||r.getContext("experimental-webgl");return i.getParameter(i.getExtension("WEBGL_debug_renderer_info").UNMASKED_RENDERER_WEBGL).match(/apple m\d/i)}catch{return!1}}return!1},{useState:of}=await Je("react"),Jn="Unknown";let ma,ga=!1;function fM(){const[e,t]=of(!ga),[n,r]=of(ma);return eg(async()=>{if(ga)return;t(!0);const i=new _t(navigator.userAgent),s=i.getResult(),o={name:s.browser.name??Jn,version:s.browser.version??Jn},a={name:s.engine.name??Jn,version:s.engine.version??Jn},[c,u,d]=await Promise.all([s.withClientHints(),i.getOS().withClientHints(),i.getCPU().withClientHints()]),l={name:u.name??Jn,version:u.version??Jn};let f;d.architecture?f=d.architecture:f=l.name==="macOS"&&BA(c)?"arm64":"Unknown";const h={browser:o,engine:a,os:l,cpu:{architecture:f},mobile:i.getDevice().is("mobile"),tablet:i.getDevice().is("tablet")};ma=h,ga=!0,r(h),t(!1)},[]),[e,ma??n]}const{useContext:UA}=await Je("react"),$A=()=>{const e=UA(tg);if(!e)throw new Error("useAnalytics must be used within AnalyticsProvider");return e.isInitialized?{isInitialized:!0,track:e.track,identify:e.identify,page:e.page}:{isInitialized:!1,track:()=>{},identify:()=>{},page:()=>{}}},{useCallback:af,useEffect:cf,useMemo:WA,useState:GA}=await Je("react"),hM=()=>({version:0,loading:!1,time:0,error:null,loaded:!1,reload:()=>{},set:()=>{}}),zA=(e,t=[],n={})=>{const[r,i]=GA({version:0,loading:!1,value:n.initialValue??null,time:0,error:null}),s=af(()=>{n.callWithTruthyDeps&&t.some(c=>!c)||i(c=>({...c,loading:!0,version:c.version+1}))},[r,n.callWithTruthyDeps,...t]);cf(()=>{s()},t),cf(()=>{if(!r.loading)return;let c=!1;const u=!1,d=Date.now();return Promise.resolve().then(()=>e()).then(l=>{c||i(f=>({...f,value:l,error:null,loading:u,time:Date.now()-d}))}).catch(l=>{console.error(l),To(f=>f.captureException(l)),!c&&i(f=>({...f,value:f.value,error:l,loading:u,time:Date.now()-d}))}),()=>{c=!0}},[r]);const o=af(c=>{const u=typeof c=="function"?c(r.value):c;i(d=>({...d,value:u}))},[r]),a=WA(()=>({version:r.version,loading:r.loading,error:r.error,time:r.time,loaded:r.version!==0,reload:s,set:o}),[r,s,o]);return[r.value,a]},pM=zA,{useCallback:jA,useEffect:qA,useState:VA}=await Je("react"),mM=(e,t)=>{const[{loading:n,args:r},i]=VA({loading:!1,args:null});qA(()=>{if(!n||r===null)return;let o=!1;return Promise.resolve().then(()=>e(...r)).then(()=>{o||i({loading:!1,args:null})}).catch(a=>{console.error(a),To(c=>c.captureException(a)),!o&&i({loading:!1,args:null})}),()=>{o=!0}},[n]);const s=jA((...o)=>{i({loading:!0,args:o})},[n,r,...t]);return[n,s]},{useCallback:XA,useMemo:YA,useState:JA}=await Je("react"),gM=(e,t)=>{const[n,r]=JA([]),i=YA(()=>n.map(([o])=>o),[n]),s=XA((o,...a)=>{if(n.find(([u])=>u===o))return;const c=Promise.resolve().then(()=>e(o,...a)).then(()=>{r(u=>u.filter(([d])=>d!==o))}).catch(u=>{console.error(u),To(d=>d.captureException(u)),r(d=>d.filter(([l])=>l!==o))});r(u=>[...u,[o,c]])},[n,...t]);return[i,s]},{useEffect:uf,useRef:lf}=await Je("react"),_M=({onLoadMore:e,hasMore:t,isLoading:n,threshold:r=500,debounceMs:i=500})=>{const s=lf(e),o=lf(0);uf(()=>{s.current=e},[e]),uf(()=>{const a=()=>{const u=Date.now();if(u-o.current<i)return;const d=document.documentElement.scrollHeight,l=document.documentElement.scrollTop,f=document.documentElement.clientHeight;d-(l+f)<r&&t&&!n&&(o.current=u,s.current())};window.addEventListener("scroll",a,{passive:!0});const c=setTimeout(a,500);return()=>{window.removeEventListener("scroll",a),clearTimeout(c)}},[t,n,r,i])};var hc;(function(e){e.NEWEST="newest",e.READ="read"})(hc||(hc={}));const KA=(e,t)=>{try{const n=localStorage.getItem(e);return n===null?t:JSON.parse(n)}catch{return t}},kg=(e,t)=>{try{localStorage.setItem(e,JSON.stringify(t))}catch{}},yM=e=>{try{localStorage.removeItem(e)}catch{}},{useCallback:qr,useEffect:ss,useMemo:ZA,useRef:df,useState:_a}=await Je("react"),QA=6e4,pc="dcl_notifications_onboarding",eM=()=>{const e=KA(pc,null);return e===null?(kg(pc,!0),!0):e},ff=()=>{kg(pc,!1)},bM=e=>{const{identity:t,isNotificationsEnabled:n,notificationsUrl:r,availableNotificationTypes:i,queryIntervalMs:s=QA,initialActiveTab:o=hc.NEWEST,onError:a,renderProfile:c}=e,[u,d]=_a({isLoading:!1,notifications:[]}),[l,f]=_a(()=>({activeTab:o,isOnboarding:eM(),isOpen:!1})),[h,p]=_a(null),m=df([]),g=df(null);ss(()=>{m.current=u.notifications},[u.notifications]),ss(()=>{g.current=h},[h]);const _=ZA(()=>i?new Set(i):null,[i]),v=qr(C=>Promise.resolve().then(()=>C.getNotifications()).then(M=>{const x=_?M.filter(P=>_.has(P.type)):M,R=x.some(P=>P.read);d(P=>({...P,isLoading:!1,notifications:x})),R&&(ff(),f(P=>P.isOnboarding?{...P,isOnboarding:!1}:P))}).catch(M=>{const x=M instanceof Error?M:new Error("Unknown error");console.error("Error fetching notifications:",x),a&&a(x),d(R=>({...R,isLoading:!1}))}),[_,a]);ss(()=>{if(!t){p(null);return}if(!r){const P=new Error("notificationsUrl is required");console.error("Notifications URL missing:",P),a&&a(P),p(null);return}const C=Og(t,{url:r});if(p(C),!n)return;let M=!1;d(P=>({...P,isLoading:!0}));const x=()=>{M||v(C)};x();const R=setInterval(x,s);return()=>{M=!0,clearInterval(R)}},[t,n,r,a,v,s]),ss(()=>{if(!!l.isOpen)return;const M=m.current,x=g.current;if(!x)return;const R=M.filter(k=>!k.read).map(k=>k.id);if(R.length===0)return;let P=!1;return Promise.resolve().then(()=>x.markNotificationsAsRead(R)).then(()=>{P||d(k=>({...k,notifications:k.notifications.map(F=>({...F,read:R.includes(F.id)?!0:F.read}))}))}).catch(k=>{if(P)return;const F=k instanceof Error?k:new Error("Unknown error");console.error("Error marking notifications as read:",F),a&&a(F)}),()=>{P=!0}},[l.isOpen,a]);const L=qr(()=>{ff(),f(C=>({...C,isOnboarding:!1}))},[]),A=qr(()=>{f(C=>({...C,isOpen:!C.isOpen}))},[]),O=qr(C=>{f(M=>({...M,activeTab:C}))},[]),T=qr(C=>c?c(C):null,[c]);return{notifications:u.notifications,isLoading:u.isLoading,isModalOpen:l.isOpen,modalActiveTab:l.activeTab,isNotificationsOnboarding:l.isOnboarding,handleOnBegin:L,handleNotificationsOpen:A,handleOnChangeModalTab:O,handleRenderProfile:T}},{useEffect:tM}=await Je("react"),SM=e=>{const{page:t}=$A();tM(()=>{t(e)},[t,e])},{useCallback:nM,useState:rM}=await Je("react"),EM=e=>{const[t,n]=rM(e),r=nM(i=>n(s=>({...s,...i})),[]);return[t,r]};export{tg as AnalyticsContext,lM as AnalyticsProvider,ng as TranslationContext,dM as TranslationProvider,eM as checkIsOnboarding,hM as createAsyncMemoState,hM as createAsyncStateState,Og as createNotificationsClient,KA as getStorageItem,yM as removeStorageItem,ff as setOnboardingDone,kg as setStorageItem,fM as useAdvancedUserAgentData,$A as useAnalytics,eg as useAsyncEffect,pM as useAsyncMemo,zA as useAsyncState,mM as useAsyncTask,gM as useAsyncTasks,_M as useInfiniteScroll,bM as useNotifications,SM as usePageTracking,EM as usePatchState,vA as useTranslation};