PageSourceSearch

https://xterns.ai/assets/index-DLd_kDlx.js

js xterns.ai collected 2026-10-05 13:23:15 UTC 830,255 bytes, 420 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/Index-BNtBY6eu.js","assets/Layout-B4HKaXoo.js","assets/proxy-D0Q57V63.js","assets/arrow-up-right-B3Cmyp3C.js","assets/eye-CRDofLPH.js","assets/shield-check-C7sUiJPm.js","assets/briefcase-business-CphIeAJd.js","assets/earth-tODT83zM.js","assets/trophy-DBX-jNOC.js","assets/book-open-BSYsXyfC.js","assets/timer-CZhDpZys.js","assets/trending-up-BU4cR3Ys.js","assets/index.esm-ebI4J_C1.js","assets/label-D4-ENrYn.js","assets/select-RSrodAEw.js","assets/index-BdQq_4o_.js","assets/index-Deh-4PO1.js","assets/chevron-down-DpJJsCer.js","assets/chevron-up-M4SAwIjf.js","assets/index-Da4Am1jz.js","assets/UnifiedLogin-YUrSOTuv.js","assets/loader-circle-D2miE2xB.js","assets/arrow-left-BXtn7MCa.js","assets/mail-BVn2o8AP.js","assets/XternSignup-DtyrLBeh.js","assets/input-otp-lmz2zhuN.js","assets/TechLeadSignup-Bohl5S-i.js","assets/users-round-DunEH6L6.js","assets/ResetPassword-CHQOHUNY.js","assets/PrivacyPolicy-CeJeR_tA.js","assets/Seo-Diny__Ix.js","assets/CookiePolicy-C7hR8njQ.js","assets/About-C8a7Tahq.js","assets/code-xml-BUecDWl6.js","assets/award-MEJfpupD.js","assets/SkillsAccelerator-DVr_F28n.js","assets/TechLeads-DPw8Ni7-.js","assets/PodSponsorship-CblYYbnK.js","assets/shield-T2sbDX4y.js","assets/circle-x-C4PFt3c3.js","assets/message-square-CtxeCfRz.js","assets/star-
1BH1OFEcs.js","assets/heart-CmTva1zz.js","assets/monitor-CcmP4yDI.js","assets/Terms-Cg0WPBn8.js","assets/EnterpriseLanding-D_8j6hI6.js","assets/EnterpriseVerify-BB2AeEq2.js","assets/SuperAdminDashboard-ujQK_7bI.js","assets/SuperAdminLayout-BsUvQU2j.js","assets/NotificationIcon-C1wwYnH5.js","assets/popover-BMD5FOmU.js","assets/scroll-area-BXTuUF24.js","assets/NotificationItem-Dc2WXW-y.js","assets/formatDistanceToNow-57P64IbE.js","assets/en-US-9SRVm7yB.js","assets/differenceInCalendarMonths-BA0TPVs2.js","assets/endOfDay-DkR3ZXc8.js","assets/endOfMonth-CYn6pTOm.js","assets/triangle-alert-Chqk_WK7.js","assets/dropdown-menu-DSd1c3Vk.js","assets/index-lTaZyIGy.js","assets/chevron-right-CD1gvy-q.js","assets/crown-hzm_bRIt.js","assets/user-check-DxoAQXwU.js","assets/globe-C057RQ73.js","assets/key-round-B79BulHq.js","assets/search-DFH5eAlA.js","assets/trending-down-BvA8vA3u.js","assets/external-link-D0CFvOTk.js","assets/alert-CyfKy7ls.js","assets/generateCategoricalChart-ByDL-d9M.js","assets/findIndex-Cos7Fxsp.js","assets/tiny-invariant-CopsF_GD.js","assets/BarChart-mmA8KDsJ.js","assets/YAxis-BtEb5zMI.js","assets/CartesianGrid-ChidKd9i.js","assets/PieChart-Bcnc_bSW.js","assets/PolarAngleAxis-Blx3t8Nb.js","assets/LineChart-BqKg5nac.js","assets/calendar-CX7fcgXP.js","assets/endOfWeek-6cC00CtY.js","assets/format-BTXglRCX.js","assets/subDays-B5afKHU7.js","assets/isAfter-DDRF2ylA.js","assets/chevron-left-Wewsh5d7.js","assets/parseISO-B4sJZ6AV.js","assets/AreaChart-DvsyYnZ8.js","assets/useSuperAdminPods-DR7Jcl7M.js","assets/SuperAdminUsers-Cf9xJPXT.js","assets/useMutation-CotV56Sa.js","assets/table-BOJIo-OD.js","assets/textarea-C6X-I43k.js","assets/download-Cr0jatld.js","assets/InvitationStatusBadge-DHSAISAb.js","assets/upload-CCEcMTV9.js","assets/user-plus-CSalqUlO.js","assets/filter-BMeMiGQo.js","assets/SuperAdminTechLeadReviews-B0h7kr5L.js","assets/warning-vNLIDCnk.js","assets/collapsible-i67bJVO7.js","assets/index-D7uKcQzO.js","assets/refresh-cw-CoPjtj5-.js","assets/linkedin-C3YpjTq8.js","assets/SuperAdminTechLeadReviews-CJcKS1eY.css","assets/SuperAdminMetricDetail-Bwe-MULn.js","assets/SuperAdminNotifications-BdNAY343.js","assets/switch-7Twrb7Os.js","assets/useNotificationPreferences-DhCaj2cc.js","assets/alert-dialog-Ct5JsrY0.js","assets/git-branch-C-twpC7K.js","assets/trash-2-0uuZSTFd.js","assets/SuperAdminCalendar-D50fTUCN.js","assets/tabs-DKw2ItQa.js","assets/useGooglePostAuthResume-D2LXR_8h.js","assets/getDay-qh2J2e9D.js","assets/useGooglePostAuthResume-DEpV2Nr3.css","assets/link-_ZZxygmy.js","assets/square-pen-Ce4P3TUP.js","assets/plus-0WhrdjYO.js","assets/SuperAdminOngoingPods-DNoc-84j.js","assets/SuperAdminCompletedPods-B0OWYJJa.js","assets/SuperAdminSprintBoardPods-DB8K4kQ5.js","assets/SuperAdminSprintAnalytics-D5I63ZkJ.js","assets/businessManagement-BTTXtuIj.js","assets/rotate-ccw-Bx1C64Ur.js","assets/calendar-clock-BWm3z0fh.js","assets/clock-3-De2r9tJK.js","assets/SuperAdminPodAnalytics-BWX-hqUk.js","assets/PodCreationWizard-CdgIUX8C.js","assets/lightbulb-BpXO0eKD.js","assets/PodNameGenerator-DUSAq0St.js","assets/useTechLeads-Cmw-XrPs.js","assets/mail-plus-CkuPXPSq.js","assets/ProjectTemplatePickerDialog-mLjdszR_.js","assets/useSuperAdminPodCreation-YSaez4bb.js","assets/useAIDeliveryPlanning-CTW9zPaD.js","assets/useSuperAdminPodAnalytics-BxT6ZDlV.js","assets/layers-xSe-BphI.js","assets/user-cog-BjzUwQIe.js","assets/route-Rd_Np_3d.js","assets/shield-alert-CVqPbwtZ.js","assets/arrow-up-down-DPtOSMqM.js","assets/SuperAdminPodAnalyticsDetail-_YWZuqfB.js","assets/SuperAdminPodSprintBoard-D1QYh_gj.js","assets/usePodManagement-CP5ffjdL.js","assets/usePodDetails-C9Suehy1.js","assets/usePodMembers-8OtOtFCP.js","assets/useSprintManagement-C4IIF8L2.js","assets/useRoadmapData-uoMx8Hqe.js","assets/PodTechLeadCollaborationPanel-DOXEgUVe.js","assets/useMultilateralTechLeadInvitations-CzvKFiLJ.js","assets/TechLeadPicker-DENSUSgV.js","assets/command-BReSBG4f.js","assets/SuperAdminPodSetup-B2GnJE0z.js","assets/user-round-check-syjRkPJS.js","assets/save-DnzFMk1L.js","assets/SuperAdminPodSprintSwimlanes-wu_BFpR7.js","assets/useSprintBoardPermissions-Dk-ManBg.js","assets/send-DsBTdW9L.js","assets/useEIScore-C48npH32.js","assets/KanbanSprintBoard-D4eJV4C-.js","assets/core.esm-CBNPzdJB.js","assets/useAILearningRecommendations-jJczlYHr.js","assets/useLearningResources-UHJHnByl.js","assets/play-rljZUdXx.js","assets/book-D_JgnLFI.js","assets/video-DM4J6B9K.js","assets/copy-B3ncjnG6.js","assets/link-2-DxGcptQD.js","assets/pencil-CYx02MS_.js","assets/grip-D8CWfeHW.js","assets/SuperAdminProjects-DQnGexO2.js","assets/ProjectDetailsModal-inVluIgr.js","assets/WizardMockContainer-Dn7sEr7R.js","assets/info-BLiu1f4f.js","assets/radio-group-BU56MLP7.js","assets/SuperAdminBusinesses-DnLyYOi-.js","assets/SuperAdminBusinessNew-CKwOSYCU.js","assets/SuperAdminBusinessDetail-D9PeAjwx.js","assets/SuperAdminPodAccessCodes-BcRC4ZQF.js","assets/shield-off-nhS97Oaj.js","assets/SuperAdminTalentPipeline-WYfnlo-O.js","assets/XternDetailPanel-BJRSNvku.js","assets/usePublicCVData-BloADn1S.js","assets/VerifiedSkillsSection-BPTGucj2.js","assets/map-pin-ChCNbN_o.js","assets/phone-rtR4Bg4j.js","assets/SuperAdminSponsorshipInquiries-BgWNsTqw.js","assets/SuperAdminTechLeadRatings-BErUnCqK.js","assets/DareyScoreDiagnostics-GKKJOUkh.js","assets/zap-Cs6U3-LC.js","assets/gauge-BaUzh1VV.js","assets/Dashboard-pd69jBl5.js","assets/DashboardLayout-Bnmkd53o.js","assets/git-pull-request-__1fAqC3.js","assets/XternsDashboard-B61CJlUF.js","assets/useXternPods-vMByMFnp.js","assets/useMultiPodSprints-vPyFVg5i.js","assets/usePodSprintsQuery-DeeP5xKS.js","assets/usePodRealtimeSync-Bju8NttL.js","assets/XternTopbar-CTWW4Hoo.js","assets/arrow-right-left-C4CM-5rU.js","assets/AssessmentUI-DW2eB-aa.js","assets/circle-play-CGUr0fM_.js","assets/numberFormat-zOUS8IHU.js","assets/SignalScoreTiers-CimoV002.js","assets/PodApplicationDialog-j01fAaDf.js","assets/EmptyState-DNi4BV7D.js","assets/ConnectGitHubButton-DLktnEM_.js","assets/useGitHubIdentity-DDmb0Jwt.js","assets/useXternProfile-C3z298Ah.js","assets/badge-check-BG9dn4bq.js","assets/acceleratorApplicationForm-Df61pn3H.js","assets/XternProjects-CEKraU1a.js","assets/useProjects-D0lM2jIR.js","assets/AcquireExperienceDialog-gZslbKSr.js","assets/XternPods-BJOFv3o9.js","assets/XternProjectHub-_J-YDvAQ.js","assets/XternEITracker-DHMZWjot.js","assets/XternCV-DDkKOkwE.js","assets/useXternCVData-DVgkff8K.js","assets/PublicCVLayout-BhhwDZLk.js","assets/share-2-BPEjAYf2.js","assets/share-C1adk9AK.js","assets/XternLearning-TWxfJ1Iz.js","assets/XternLearningResourceDetail-CBlGx2T1.js","assets/XternCareer-B_IKp0xz.js","assets/XternJobs-D8xQYRae.js","assets/EmployerIntroVideo-EY6CLzfQ.js","assets/useEmployerOpp
1ortunities-CGJnNoIG.js","assets/useEnterpriseAccount-DtG-D-iC.js","assets/wallet-CO3sf0mI.js","assets/bot-B7Ux8HTI.js","assets/XternSimulationWorkspace-CkrMMSTH.js","assets/CreateRepoDialog-CS0zHZ02.js","assets/XternCommunity-CZJbzcLb.js","assets/XternNotifications-SyyDk_9z.js","assets/XternRecognition-D88FqvJI.js","assets/XternProfile-C7CieAUy.js","assets/dareyScoreProfileSync-Bj-bhG5E.js","assets/brain-pqum15ho.js","assets/ProfilePictureUpload-C75uCAIp.js","assets/camera-CjU4dBqw.js","assets/git-commit-horizontal-CQF5yVsh.js","assets/XternSettings-BhWYti7C.js","assets/palette-Yz0ov0aN.js","assets/XternSettingsEnhanced-BE10EBND.js","assets/XternSprintSwimlanes-CsZGV9qx.js","assets/SprintBoardLoadingState-oqR8eYJw.js","assets/XternSprintBoard-BbTlGy6M.js","assets/XternSprintSelection-vIZwZafo.js","assets/XternCalendar-ByelJxFK.js","assets/MeetingDetailsDialog-BvSFQFXX.js","assets/XternSprintAssessment-MjKowxR2.js","assets/useEnhancedTabSwitchDetection-ClrbZUeT.js","assets/XternSprintHistory-D8Gf_JDk.js","assets/XternSkillUpdateWizard-BiXGiUbs.js","assets/useSkillUpdateSession-COerTTEz.js","assets/XternSkillUpdateAssessment-Cl4oP-Tn.js","assets/ClientDashboard-DsLi1PoL.js","assets/ClientBusinessGate-CKL9R3zX.js","assets/ClientProjects-C60_XiOH.js","assets/useClientPodCreation-BdAaEieM.js","assets/ClientPods-BhqSY6RV.js","assets/ClientPodDetail-BgqkRqbp.js","assets/ClientPodSetup-Dha9s84G.js","assets/ClientSprints-DMAdoaF2.js","assets/ClientAnalytics-Bya2es0J.js","assets/ClientAccelerator-NEPkoYiH.js","assets/acceleratorManagement-jGdrPuKl.js","assets/settings-2-DN7526sA.js","assets/ClientAcceleratorSetup-06UxDYRN.js","assets/ClientAcceleratorLandingEditor-Dl2WwNXK.js","assets/acceleratorLandingPage-B3GZhId_.js","assets/circle-help-BvQiO2mW.js","assets/ClientAcceleratorApplicationFormEditor-XQa99PKt.js","assets/ClientAcceleratorApplicationReviews-S393237K.js","assets/ClientAcceleratorPodAssignments-Cb5SuraL.js","assets/history-KR3h33bt.js","assets/PublicAcceleratorApplicationForm-DVyvdmE0.js","assets/PublicAcceleratorLandingPage-wvVjocnA.js","assets/ClientInvitationAccept-OJiOXpVJ.js","assets/TechLeadDashboard-BWhsLmJ9.js","assets/TechLeadHeader-eLOg3V3h.js","assets/useTechLeadPods-CLIvfpn7.js","assets/useTechLeadTickets-BZiR5I3Y.js","assets/useTechLeadUpcomingMeetings-BFtzxFDC.js","assets/TechLeadProjectHub-1dtyuLMp.js","assets/usePodCreation-D6Vw7gOo.js","assets/TechLeadMyPods-CckB-0kM.js","assets/TechLeadPodManagement-CAGguWAJ.js","assets/usePodDeliveryPlan-Qtfzkd_A.js","assets/TechLeadGithubIntegration-fsaOHO7l.js","assets/TechLeadInvitations-BLiaBUzS.js","assets/TechLeadCalendar-CpMjfAtX.js","assets/TechLeadProfile-ChOM-5qB.js","assets/url-input-Dei4E79g.js","assets/linkValidation-XNJaCD7E.js","assets/TechLeadDeliveryPlanCreation-C67pGt3L.js","assets/TechLeadSprintBoardPodList-D2rswWc9.js","assets/TechLeadSprintBoard-fOAq91yr.js","assets/ellipsis-BUCYa95L.js","assets/TechLeadSprintSwimlanes-CWoNkvo5.js","assets/TechLeadNotifications-BEmQyl72.js","assets/TechLeadSLADashboard-DAsn9F_w.js","assets/TechLeadCSATDashboard-OglYJHo5.js","assets/AssessmentWelcome-CYyOdDAT.js","assets/AssessmentStage1-C4fC--Kf.js","assets/AssessmentStage2-BwZE7bHu.js","assets/countries-D6ab3bU5.js","assets/AssessmentStage3-BYZgFBuW.js","assets/AssessmentConfirmation-Ceyjh03k.js","assets/TechAssessment-GiVAbL24.js","assets/AssessmentNavigation-oLmPgHzP.js","assets/TechAssessmentResults-B-B8iPbN.js","assets/QuizReview-DWONuWez.js","assets/AssessmentHistory-DpCkuzoJ.js","assets/AssessmentLockdown-OwSQPW2q.js","assets/AssessmentTake-Cq9UMmSm.js","assets/AssessmentTimer-DKEZNVCu.js","assets/useTabSwitchDetection-xbPzZd34.js","assets/TechLeadAssessmentWelcome-BOIZX1N9.js","assets/TechLeadAssessmentStage1-Cqr5DUTm.js","assets/TechLeadAssessmentStage2-Dyr9J731.js","assets/TechLeadAssessmentStage3-3uB8Ds4M.js","assets/techLeadAssessmentLevels-BOFrDf7q.js","assets/TechLeadAssessmentConfirmation-Dv6gh5sZ.js","assets/TechLeadAssessmentLockdown-CjthC3Pl.js","assets/TechLeadTechAssessment-CDdjjtUH.js","assets/TechLeadAssessmentResults-w0mpzy3N.js","assets/TechLeadSkillUpdateAssessment-CFsvCob3.js","assets/useTechLeadSkillUpdateSession-B4tcNeM4.js","assets/TechLeadSkillUpdateAssessmentLevel-CbARLlUO.js","assets/TechLeadSkillUpdate
vendor: 4,518 bytes, lines 1-10
1Confirmation-BQcjyE83.js","assets/TechLeadSkillUpdateResults-XaMf6Yds.js","assets/TechLeadOnboardingWizard-J1Pb8MGC.js","assets/useTechLeadOnboardingSession-DgxbZ-OB.js","assets/TechLeadOnboardingAssessment-BlajUR_c.js","assets/TechLeadOnboardingResults-Cop5_Zwx.js","assets/TechLeadPendingReview-CGo-DpPh.js","assets/PublicCV-DyTSow5t.js","assets/CVSectionDetail-DxwgYVXc.js","assets/PodParticipationAwardVerify-CPJfnwD-.js","assets/Projects-DR8YehL9.js","assets/Templates-BYLTpA40.js","assets/Talent-Jjbxugvn.js","assets/EnterpriseOpportunities-V5aL8M8v.js","assets/EnterpriseOpportunityCreate-DiapA1Xv.js","assets/EnterpriseOpportunityDetail-BPAzyzPo.js","assets/PracticeAssessments-CjIGCR9t.js","assets/PracticeAssessment-wVGFZ3TP.js","assets/AssessmentAnalytics-C1Oi8GBx.js","assets/AssessmentResults-BVk4y1p9.js","assets/ProjectPublish-BDJ3xnoH.js","assets/InviteCandidates-CkWvGzKk.js","assets/AdminInviteCandidates-ty9uz7D9.js","assets/Roadmap-BlPVI3Z4.js","assets/EnterpriseSponsorships-Bm3UlfhG.js","assets/PodMarketplace-ln8PpcXA.js"])))=>i.map(i=>d[i]);
2var hy=e=>{throw TypeError(e)};var Xf=(e,t,r)=>t.has(e)||hy("Cannot "+r);var L=(e,t,r)=>(Xf(e,t,"read from private field"),r?r.call(e):t.get(e)),De=(e,t,r)=>t.has(e)?hy("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ve=(e,t,r,n)=>(Xf(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),Ke=(e,t,r)=>(Xf(e,t,"access private method"),r);var Vc=(e,t,r,n)=>({set _(i){ve(e,t,i,r)},get _(){return L(e,t,n)}});function vk(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in e)){const a=Object.getOwnPropertyDescriptor(n,i);a&&Object.defineProperty(e,i,a.get?a:{enumerable:!0,get:()=>n[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const l of a.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&n(l)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();var CU=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Co(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Zf={exports:{}},Da={},eh={exports:{}},We={};/**
3 * @license React
4 * react.production.min.js
5 *
6 * Copyright (c) Facebook, Inc. and its affiliates.
7 *
8 * This source code is licensed under the MIT license found in the
9 * LICENSE file in the root directory of this source tree.
10 */var py;function yk(){if(py)return We;py=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),l=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.iterator;function b(N){return N===null||typeof N!="object"?null:(N=g&&N[g]||N["@@iterator"],typeof N=="function"?N:null)}var w={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,_={};function E(N,U,X){this.props=N,this.context=U,this.refs=_,this.updater=X||w}E.prototype.isReactComponent={},E.prototype.setState=function(N,U){if(typeof N!="object"&&typeof N!="function"&&N!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,N,U,"setState")},E.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function k(){}k.prototype=E.prototype;function T(N,U,X){this.props=N,this.context=U,this.refs=_,this.updater=X||w}var R=T.prototype=new k;R.constructor=T,S(R,E.prototype),R.isPureReactComponent=!0;var P=Array.isArray,O=Object.prototype.hasOwnProperty,I={current:null},M={key:!0,ref:!0,__self:!0,__source:!0};
vendor: 5,148 bytes, line 10
10function Y(N,U,X){var fe,Oe={},Fe=null,Re=null;if(U!=null)for(fe in U.ref!==void 0&&(Re=U.ref),U.key!==void 0&&(Fe=""+U.key),U)O.call(U,fe)&&!M.hasOwnProperty(fe)&&(Oe[fe]=U[fe]);var Ve=arguments.length-2;if(Ve===1)Oe.children=X;else if(1<Ve){for(var Qe=Array(Ve),F=0;F<Ve;F++)Qe[F]=arguments[F+2];Oe.children=Qe}if(N&&N.defaultProps)for(fe in Ve=N.defaultProps,Ve)Oe[fe]===void 0&&(Oe[fe]=Ve[fe]);return{$$typeof:e,type:N,key:Fe,ref:Re,props:Oe,_owner:I.current}}function ae(N,U){return{$$typeof:e,type:N.type,key:U,ref:N.ref,props:N.props,_owner:N._owner}}function he(N){return typeof N=="object"&&N!==null&&N.$$typeof===e}function Ee(N){var U={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(X){return U[X]})}var ue=/\/+/g;function je(N,U){return typeof N=="object"&&N!==null&&N.key!=null?Ee(""+N.key):U.toString(36)}function le(N,U,X,fe,Oe){var Fe=typeof N;(Fe==="undefined"||Fe==="boolean")&&(N=null);var Re=!1;if(N===null)Re=!0;else switch(Fe){case"string":case"number":Re=!0;break;case"object":switch(N.$$typeof){case e:case t:Re=!0}}if(Re)return Re=N,Oe=Oe(Re),N=fe===""?"."+je(Re,0):fe,P(Oe)?(X="",N!=null&&(X=N.replace(ue,"$&/")+"/"),le(Oe,U,X,"",function(F){return F})):Oe!=null&&(he(Oe)&&(Oe=ae(Oe,X+(!Oe.key||Re&&Re.key===Oe.key?"":(""+Oe.key).replace(ue,"$&/")+"/")+N)),U.push(Oe)),1;if(Re=0,fe=fe===""?".":fe+":",P(N))for(var Ve=0;Ve<N.length;Ve++){Fe=N[Ve];var Qe=fe+je(Fe,Ve);Re+=le(Fe,U,X,Qe,Oe)}else if(Qe=b(N),typeof Qe=="function")for(N=Qe.call(N),Ve=0;!(Fe=N.next()).done;)Fe=Fe.value,Qe=fe+je(Fe,Ve++),Re+=le(Fe,U,X,Qe,Oe);else if(Fe==="object")throw U=String(N),Error("Objects are not valid as a React child (found: "+(U==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":U)+"). If you meant to render a collection of children, use an array instead.");return Re}function Ae(N,U,X){if(N==null)return N;var fe=[],Oe=0;return le(N,fe,"","",function(Fe){return U.call(X,Fe,Oe++)}),fe}function Te(N){if(N._status===-1){var U=N._result;U=U(),U.then(function(X){(N._status===0||N._status===-1)&&(N._status=1,N._result=X)},function(X){(N._status===0||N._status===-1)&&(N._status=2,N._result=X)}),N._status===-1&&(N._status=0,N._result=U)}if(N._status===1)return N._result.default;throw N._result}var re={current:null},z={transition:null},W={ReactCurrentDispatcher:re,ReactCurrentBatchConfig:z,ReactCurrentOwner:I};function K(){throw Error("act(...) is not supported in production builds of React.")}return We.Children={map:Ae,forEach:function(N,U,X){Ae(N,function(){U.apply(this,arguments)},X)},count:function(N){var U=0;return Ae(N,function(){U++}),U},toArray:function(N){return Ae(N,function(U){return U})||[]},only:function(N){if(!he(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},We.Component=E,We.Fragment=r,We.Profiler=i,We.PureComponent=T,We.StrictMode=n,We.Suspense=f,We.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=W,We.act=K,We.cloneElement=function(N,U,X){if(N==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+N+".");var fe=S({},N.props),Oe=N.key,Fe=N.ref,Re=N._owner;if(U!=null){if(U.ref!==void 0&&(Fe=U.ref,Re=I.current),U.key!==void 0&&(Oe=""+U.key),N.type&&N.type.defaultProps)var Ve=N.type.defaultProps;for(Qe in U)O.call(U,Qe)&&!M.hasOwnProperty(Qe)&&(fe[Qe]=U[Qe]===void 0&&Ve!==void 0?Ve[Qe]:U[Qe])}var Qe=arguments.length-2;if(Qe===1)fe.children=X;else if(1<Qe){Ve=Array(Qe);for(var F=0;F<Qe;F++)Ve[F]=arguments[F+2];fe.children=Ve}return{$$typeof:e,type:N.type,key:Oe,ref:Fe,props:fe,_owner:Re}},We.createContext=function(N){return N={$$typeof:l,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},N.Provider={$$typeof:a,_context:N},N.Consumer=N},We.createElement=Y,We.createFactory=function(N){var U=Y.bind(null,N);return U.type=N,U},We.createRef=function(){return{current:null}},We.forwardRef=function(N){return{$$typeof:u,render:N}},We.isValidElement=he,We.lazy=function(N){return{$$typeof:m,_payload:{_status:-1,_result:N},_init:Te}},We.memo=function(N,U){return{$$typeof:p,type:N,compare:U===void 0?null:U}},We.startTransition=function(N){var U=z.transition;z.transition={};try{N()}finally{z.transition=U}},We.unstable_act=K,We.useCallback=function(N,U){return re.current.useCallback(N,U)},We.useContext=function(N){return re.current.useContext(N)},We.useDebugValue=function(){},We.useDeferredValue=function(N){return re.current.useDeferredValue(N)},We.useEffect=function(N,U){return re.current.useEffect(N,U)},We.useId=function(){return re.current.useId()},We.useImperativeHandle=function(N,U,X){return re.current.useImperativeHandle(N,U,X)},We.useInsertionEffect=function(N,U){return re.current.useInsertionEffect(N,U)},We.useLayoutEffect=function(N,U){return re.current.useLayoutEffect(N,U)},We.useMemo=function(N,U){return re.current.useMemo(N,U)},We.useReducer=function(N,U,X){return re.current.useReducer(N,U,X)},We.useRef=function(N){return re.current.useRef(N)},We.useState=function(N){return re.current.useState(N)},We.useSyncExternalStore=function(N,U,X){return re.current.useSyncExternalStore(N,U,X
vendor: 6,962 bytes, lines 10-34
10)},We.useTransition=function(){return re.current.useTransition()},We.version="18.3.1",We}var my;function $u(){return my||(my=1,eh.exports=yk()),eh.exports}/**
11 * @license React
12 * react-jsx-runtime.production.min.js
13 *
14 * Copyright (c) Facebook, Inc. and its affiliates.
15 *
16 * This source code is licensed under the MIT license found in the
17 * LICENSE file in the root directory of this source tree.
18 */var gy;function wk(){if(gy)return Da;gy=1;var e=$u(),t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function l(u,f,p){var m,g={},b=null,w=null;p!==void 0&&(b=""+p),f.key!==void 0&&(b=""+f.key),f.ref!==void 0&&(w=f.ref);for(m in f)n.call(f,m)&&!a.hasOwnProperty(m)&&(g[m]=f[m]);if(u&&u.defaultProps)for(m in f=u.defaultProps,f)g[m]===void 0&&(g[m]=f[m]);return{$$typeof:t,type:u,key:b,ref:w,props:g,_owner:i.current}}return Da.Fragment=r,Da.jsx=l,Da.jsxs=l,Da}var vy;function bk(){return vy||(vy=1,Zf.exports=wk()),Zf.exports}var d=bk(),Wc={},th={exports:{}},mr={},rh={exports:{}},nh={};/**
19 * @license React
20 * scheduler.production.min.js
21 *
22 * Copyright (c) Facebook, Inc. and its affiliates.
23 *
24 * This source code is licensed under the MIT license found in the
25 * LICENSE file in the root directory of this source tree.
26 */var yy;function xk(){return yy||(yy=1,(function(e){function t(z,W){var K=z.length;z.push(W);e:for(;0<K;){var N=K-1>>>1,U=z[N];if(0<i(U,W))z[N]=W,z[K]=U,K=N;else break e}}function r(z){return z.length===0?null:z[0]}function n(z){if(z.length===0)return null;var W=z[0],K=z.pop();if(K!==W){z[0]=K;e:for(var N=0,U=z.length,X=U>>>1;N<X;){var fe=2*(N+1)-1,Oe=z[fe],Fe=fe+1,Re=z[Fe];if(0>i(Oe,K))Fe<U&&0>i(Re,Oe)?(z[N]=Re,z[Fe]=K,N=Fe):(z[N]=Oe,z[fe]=K,N=fe);else if(Fe<U&&0>i(Re,K))z[N]=Re,z[Fe]=K,N=Fe;else break e}}return W}function i(z,W){var K=z.sortIndex-W.sortIndex;return K!==0?K:z.id-W.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var l=Date,u=l.now();e.unstable_now=function(){return l.now()-u}}var f=[],p=[],m=1,g=null,b=3,w=!1,S=!1,_=!1,E=typeof setTimeout=="function"?setTimeout:null,k=typeof clearTimeout=="function"?clearTimeout:null,T=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(z){for(var W=r(p);W!==null;){if(W.callback===null)n(p);else if(W.startTime<=z)n(p),W.sortIndex=W.expirationTime,t(f,W);else break;W=r(p)}}function P(z){if(_=!1,R(z),!S)if(r(f)!==null)S=!0,Te(O);else{var W=r(p);W!==null&&re(P,W.startTime-z)}}function O(z,W){S=!1,_&&(_=!1,k(Y),Y=-1),w=!0;var K=b;try{for(R(W),g=r(f);g!==null&&(!(g.expirationTime>W)||z&&!Ee());){var N=g.callback;if(typeof N=="function"){g.callback=null,b=g.priorityLevel;var U=N(g.expirationTime<=W);W=e.unstable_now(),typeof U=="function"?g.callback=U:g===r(f)&&n(f),R(W)}else n(f);g=r(f)}if(g!==null)var X=!0;else{var fe=r(p);fe!==null&&re(P,fe.startTime-W),X=!1}return X}finally{g=null,b=K,w=!1}}var I=!1,M=null,Y=-1,ae=5,he=-1;function Ee(){return!(e.unstable_now()-he<ae)}function ue(){if(M!==null){var z=e.unstable_now();he=z;var W=!0;try{W=M(!0,z)}finally{W?je():(I=!1,M=null)}}else I=!1}var je;if(typeof T=="function")je=function(){T(ue)};else if(typeof MessageChannel<"u"){var le=new MessageChannel,Ae=le.port2;le.port1.onmessage=ue,je=function(){Ae.postMessage(null)}}else je=function(){E(ue,0)};function Te(z){M=z,I||(I=!0,je())}function re(z,W){Y=E(function(){z(e.unstable_now())},W)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(z){z.callback=null},e.unstable_continueExecution=function(){S||w||(S=!0,Te(O))},e.unstable_forceFrameRate=function(z){0>z||125<z?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ae=0<z?Math.floor(1e3/z):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_getFirstCallbackNode=function(){return r(f)},e.unstable_next=function(z){switch(b){case 1:case 2:case 3:var W=3;break;default:W=b}var K=b;b=W;try{return z()}finally{b=K}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(z,W){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3}var K=b;b=z;try{return W()}finally{b=K}},e.unstable_scheduleCallback=function(z,W,K){var N=e.unstable_now();switch(typeof K=="object"&&K!==null?(K=K.delay,K=typeof K=="number"&&0<K?N+K:N):K=N,z){case 1:var U=-1;break;case 2:U=250;break;case 5:U=1073741823;break;case 4:U=1e4;break;default:U=5e3}return U=K+U,z={id:m++,callback:W,priorityLevel:z,startTime:K,expirationTime:U,sortIndex:-1},K>N?(z.sortIndex=K,t(p,z),r(f)===null&&z===r(p)&&(_?(k(Y),Y=-1):_=!0,re(P,K-N))):(z.sortIndex=U,t(f,z),S||w||(S=!0,Te(O))),z},e.unstable_shouldYield=Ee,e.unstable_wrapCallback=function(z){var W=b;return function(){var K=b;b=W;try{return z.apply(this,arguments)}finally{b=K}}}})(nh)),nh}var wy;function _k(){return wy||(wy=1,rh.exports=xk()),rh.exports}/**
27 * @license React
28 * react-dom.production.min.js
29 *
30 * Copyright (c) Facebook, Inc. and its affiliates.
31 *
32 * This source code is licensed under the MIT license found in the
33 * LICENSE file in the root directory of this source tree.
34 */var by;function Sk(){if(by)return mr;by=1;var e=$u(),t=_k();function r(s){for(var o="https://reactjs.org/docs/error-decoder.html?invariant="+s,c=1;c<arguments.length;c++)o+="&args[]="+encodeURIComponent(arguments[c]);return"Minified React error #"+s+"; visit "+o+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var n=new Set,i={};function a(s,o){l(s,o),l(s+"Capture",o)}function l(s,o){for(i[s]=o,s=0;s<o.length;s++)n.add(o[s])}var u=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),f=Object.prototype.hasOwnProperty,p=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,m={},g={};function b(s){return f.call(g,s)?!0:f.call(m,s)?!1:p.test(s)?g[s]=!0:(m[s]=!0,!1)}function w(s,o,c,h){if(c!==null&&c.type===0)return!1;switch(typeof o){case"function":case"symbol":return!0;case"boolean":return h?!1:c!==null?!c.acceptsBooleans:(s=s.toLowerCase().slice(0,5),s!=="data-"&&s!=="aria-");default:return!1}}function S(s,o,c,h){if(o===null||typeof o>"u"||w(s,o,c,h))return!0;
vendor: 27,765 bytes, lines 34-38
34if(h)return!1;if(c!==null)switch(c.type){case 3:return!o;case 4:return o===!1;case 5:return isNaN(o);case 6:return isNaN(o)||1>o}return!1}function _(s,o,c,h,y,x,C){this.acceptsBooleans=o===2||o===3||o===4,this.attributeName=h,this.attributeNamespace=y,this.mustUseProperty=c,this.propertyName=s,this.type=o,this.sanitizeURL=x,this.removeEmptyString=C}var E={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(s){E[s]=new _(s,0,!1,s,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(s){var o=s[0];E[o]=new _(o,1,!1,s[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(s){E[s]=new _(s,2,!1,s.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(s){E[s]=new _(s,2,!1,s,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(s){E[s]=new _(s,3,!1,s.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(s){E[s]=new _(s,3,!0,s,null,!1,!1)}),["capture","download"].forEach(function(s){E[s]=new _(s,4,!1,s,null,!1,!1)}),["cols","rows","size","span"].forEach(function(s){E[s]=new _(s,6,!1,s,null,!1,!1)}),["rowSpan","start"].forEach(function(s){E[s]=new _(s,5,!1,s.toLowerCase(),null,!1,!1)});var k=/[\-:]([a-z])/g;function T(s){return s[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(s){var o=s.replace(k,T);E[o]=new _(o,1,!1,s,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(s){var o=s.replace(k,T);E[o]=new _(o,1,!1,s,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(s){var o=s.replace(k,T);E[o]=new _(o,1,!1,s,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(s){E[s]=new _(s,1,!1,s.toLowerCase(),null,!1,!1)}),E.xlinkHref=new _("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(s){E[s]=new _(s,1,!1,s.toLowerCase(),null,!0,!0)});function R(s,o,c,h){var y=E.hasOwnProperty(o)?E[o]:null;(y!==null?y.type!==0:h||!(2<o.length)||o[0]!=="o"&&o[0]!=="O"||o[1]!=="n"&&o[1]!=="N")&&(S(o,c,y,h)&&(c=null),h||y===null?b(o)&&(c===null?s.removeAttribute(o):s.setAttribute(o,""+c)):y.mustUseProperty?s[y.propertyName]=c===null?y.type===3?!1:"":c:(o=y.attributeName,h=y.attributeNamespace,c===null?s.removeAttribute(o):(y=y.type,c=y===3||y===4&&c===!0?"":""+c,h?s.setAttributeNS(h,o,c):s.setAttribute(o,c))))}var P=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,O=Symbol.for("react.element"),I=Symbol.for("react.portal"),M=Symbol.for("react.fragment"),Y=Symbol.for("react.strict_mode"),ae=Symbol.for("react.profiler"),he=Symbol.for("react.provider"),Ee=Symbol.for("react.context"),ue=Symbol.for("react.forward_ref"),je=Symbol.for("react.suspense"),le=Symbol.for("react.suspense_list"),Ae=Symbol.for("react.memo"),Te=Symbol.for("react.lazy"),re=Symbol.for("react.offscreen"),z=Symbol.iterator;function W(s){return s===null||typeof s!="object"?null:(s=z&&s[z]||s["@@iterator"],typeof s=="function"?s:null)}var K=Object.assign,N;function U(s){if(N===void 0)try{throw Error()}catch(c){var o=c.stack.trim().match(/\n( *(at )?)/);N=o&&o[1]||""}return`
35`+N+s}var X=!1;function fe(s,o){if(!s||X)return"";X=!0;var c=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(o)if(o=function(){throw Error()},Object.defineProperty(o.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(o,[])}catch(V){var h=V}Reflect.construct(s,[],o)}else{try{o.call()}catch(V){h=V}s.call(o.prototype)}else{try{throw Error()}catch(V){h=V}s()}}catch(V){if(V&&h&&typeof V.stack=="string"){for(var y=V.stack.split(`
36`),x=h.stack.split(`
37`),C=y.length-1,j=x.length-1;1<=C&&0<=j&&y[C]!==x[j];)j--;for(;1<=C&&0<=j;C--,j--)if(y[C]!==x[j]){if(C!==1||j!==1)do if(C--,j--,0>j||y[C]!==x[j]){var A=`
38`+y[C].replace(" at new "," at ");return s.displayName&&A.includes("<anonymous>")&&(A=A.replace("<anonymous>",s.displayName)),A}while(1<=C&&0<=j);break}}}finally{X=!1,Error.prepareStackTrace=c}return(s=s?s.displayName||s.name:"")?U(s):""}function Oe(s){switch(s.tag){case 5:return U(s.type);case 16:return U("Lazy");case 13:return U("Suspense");case 19:return U("SuspenseList");case 0:case 2:case 15:return s=fe(s.type,!1),s;case 11:return s=fe(s.type.render,!1),s;case 1:return s=fe(s.type,!0),s;default:return""}}function Fe(s){if(s==null)return null;if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case M:return"Fragment";case I:return"Portal";case ae:return"Profiler";case Y:return"StrictMode";case je:return"Suspense";case le:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case Ee:return(s.displayName||"Context")+".Consumer";case he:return(s._context.displayName||"Context")+".Provider";case ue:var o=s.render;return s=s.displayName,s||(s=o.displayName||o.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case Ae:return o=s.displayName||null,o!==null?o:Fe(s.type)||"Memo";case Te:o=s._payload,s=s._init;try{return Fe(s(o))}catch{}}return null}function Re(s){var o=s.type;switch(s.tag){case 24:return"Cache";case 9:return(o.displayName||"Context")+".Consumer";case 10:return(o._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return s=o.render,s=s.displayName||s.name||"",o.displayName||(s!==""?"ForwardRef("+s+")":"ForwardRef");case 7:return"Fragment";case 5:return o;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Fe(o);case 8:return o===Y?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof o=="function")return o.displayName||o.name||null;if(typeof o=="string")return o}return null}function Ve(s){switch(typeof s){case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function Qe(s){var o=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(o==="checkbox"||o==="radio")}function F(s){var o=Qe(s)?"checked":"value",c=Object.getOwnPropertyDescriptor(s.constructor.prototype,o),h=""+s[o];if(!s.hasOwnProperty(o)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var y=c.get,x=c.set;return Object.defineProperty(s,o,{configurable:!0,get:function(){return y.call(this)},set:function(C){h=""+C,x.call(this,C)}}),Object.defineProperty(s,o,{enumerable:c.enumerable}),{getValue:function(){return h},setValue:function(C){h=""+C},stopTracking:function(){s._valueTracker=null,delete s[o]}}}}function oe(s){s._valueTracker||(s._valueTracker=F(s))}function J(s){if(!s)return!1;var o=s._valueTracker;if(!o)return!0;var c=o.getValue(),h="";return s&&(h=Qe(s)?s.checked?"true":"false":s.value),s=h,s!==c?(o.setValue(s),!0):!1}function Z(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}function pe(s,o){var c=o.checked;return K({},o,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:c??s._wrapperState.initialChecked})}function ne(s,o){var c=o.defaultValue==null?"":o.defaultValue,h=o.checked!=null?o.checked:o.defaultChecked;c=Ve(o.value!=null?o.value:c),s._wrapperState={initialChecked:h,initialValue:c,controlled:o.type==="checkbox"||o.type==="radio"?o.checked!=null:o.value!=null}}function ot(s,o){o=o.checked,o!=null&&R(s,"checked",o,!1)}function Tt(s,o){ot(s,o);var c=Ve(o.value),h=o.type;if(c!=null)h==="number"?(c===0&&s.value===""||s.value!=c)&&(s.value=""+c):s.value!==""+c&&(s.value=""+c);else if(h==="submit"||h==="reset"){s.removeAttribute("value");return}o.hasOwnProperty("value")?Be(s,o.type,c):o.hasOwnProperty("defaultValue")&&Be(s,o.type,Ve(o.defaultValue)),o.checked==null&&o.defaultChecked!=null&&(s.defaultChecked=!!o.defaultChecked)}function vt(s,o,c){if(o.hasOwnProperty("value")||o.hasOwnProperty("defaultValue")){var h=o.type;if(!(h!=="submit"&&h!=="reset"||o.value!==void 0&&o.value!==null))return;o=""+s._wrapperState.initialValue,c||o===s.value||(s.value=o),s.defaultValue=o}c=s.name,c!==""&&(s.name=""),s.defaultChecked=!!s._wrapperState.initialChecked,c!==""&&(s.name=c)}function Be(s,o,c){(o!=="number"||Z(s.ownerDocument)!==s)&&(c==null?s.defaultValue=""+s._wrapperState.initialValue:s.defaultValue!==""+c&&(s.defaultValue=""+c))}var rt=Array.isArray;function Dt(s,o,c,h){if(s=s.options,o){o={};for(var y=0;y<c.length;y++)o["$"+c[y]]=!0;for(c=0;c<s.length;c++)y=o.hasOwnProperty("$"+s[c].value),s[c].selected!==y&&(s[c].selected=y),y&&h&&(s[c].defaultSelected=!0)}else{for(c=""+Ve(c),o=null,y=0;y<s.length;y++){if(s[y].value===c){s[y].selected=!0,h&&(s[y].defaultSelected=!0);return}o!==null||s[y].disabled||(o=s[y])}o!==null&&(o.selected=!0)}}function _t(s,o){if(o.dangerouslySetInnerHTML!=null)throw Error(r(91));return K({},o,{value:void 0,defaultValue:void 0,children:""+s._wrapperState.initialValue})}function br(s,o){var c=o.value;if(c==null){if(c=o.children,o=o.defaultValue,c!=null){if(o!=null)throw Error(r(92));if(rt(c)){if(1<c.length)throw Error(r(93));c=c[0]}o=c}o==null&&(o=""),c=o}s._wrapperState={initialValue:Ve(c)}}function No(s,o){var c=Ve(o.value),h=Ve(o.defaultValue);c!=null&&(c=""+c,c!==s.value&&(s.value=c),o.defaultValue==null&&s.defaultValue!==c&&(s.defaultValue=c)),h!=null&&(s.defaultValue=""+h)}function Al(s){var o=s.textContent;o===s._wrapperState.initialValue&&o!==""&&o!==null&&(s.value=o)}function tr(s){switch(s){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function cn(s,o){return s==null||s==="http://www.w3.org/1999/xhtml"?tr(o):s==="http://www.w3.org/2000/svg"&&o==="foreignObject"?"http://www.w3.org/1999/xhtml":s}var Io,Nl=(function(s){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(o,c,h,y){MSApp.execUnsafeLocalFunction(function(){return s(o,c,h,y)})}:s})(function(s,o){if(s.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in s)s.innerHTML=o;else{for(Io=Io||document.createElement("div"),Io.innerHTML="<svg>"+o.valueOf().toString()+"</svg>",o=Io.firstChild;s.firstChild;)s.removeChild(s.firstChild);for(;o.firstChild;)s.appendChild(o.firstChild)}});function un(s,o){if(o){var c=s.firstChild;if(c&&c===s.lastChild&&c.nodeType===3){c.nodeValue=o;return}}s.textContent=o}var Vs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Il=["Webkit","ms","Moz","O"];Object.keys(Vs).forEach(function(s){Il.forEach(function(o){o=o+s.charAt(0).toUpperCase()+s.substring(1),Vs[o]=Vs[s]})});function Lo(s,o,c){return o==null||typeof o=="boolean"||o===""?"":c||typeof o!="number"||o===0||Vs.hasOwnProperty(s)&&Vs[s]?(""+o).trim():o+"px"}function On(s,o){s=s.style;for(var c in o)if(o.hasOwnProperty(c)){var h=c.indexOf("--")===0,y=Lo(c,o[c],h);c==="float"&&(c="cssFloat"),h?s.setProperty(c,y):s[c]=y}}var Ll=K({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function dn(s,o){if(o){if(Ll[s]&&(o.children!=null||o.dangerouslySetInnerHTML!=null))throw Error(r(137,s));if(o.dangerouslySetInnerHTML!=null){if(o.children!=null)throw Error(r(60));if(typeof o.dangerouslySetInnerHTML!="object"||!("__html"in o.dangerouslySetInnerHTML))throw Error(r(61))}if(o.style!=null&&typeof o.style!="object")throw Error(r(62))}}function ea(s,o){if(s.indexOf("-")===-1)return typeof o.is=="string";switch(s){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var ta=null;function Do(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var Mo=null,Jn=null,fn=null;function Ur(s){if(s=xa(s)){if(typeof Mo!="function")throw Error(r(280));var o=s.stateNode;o&&(o=oc(o),Mo(s.stateNode,s.type,o))}}function Dl(s){Jn?fn?fn.push(s):fn=[s]:Jn=s}function Ue(){if(Jn){var s=Jn,o=fn;if(fn=Jn=null,Ur(s),o)for(s=0;s<o.length;s++)Ur(o[s])}}function et(s,o){return s(o)}function at(){}var rr=!1;function lr(s,o,c){if(rr)return s(o,c);rr=!0;try{return et(s,o,c)}finally{rr=!1,(Jn!==null||fn!==null)&&(at(),Ue())}}function cr(s,o){var c=s.stateNode;if(c===null)return null;var h=oc(c);if(h===null)return null;c=h[o];e:switch(o){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(h=!h.disabled)||(s=s.type,h=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!h;break e;default:s=!1}if(s)return null;if(c&&typeof c!="function")throw Error(r(231,o,typeof c));return c}var zr=!1;if(u)try{var zt={};Object.defineProperty(zt,"passive",{get:function(){zr=!0}}),window.addEventListener("test",zt,zt),window.removeEventListener("test",zt,zt)}catch{zr=!1}function hn(s,o,c,h,y,x,C,j,A){var V=Array.prototype.slice.call(arguments,3);try{o.apply(c,V)}catch(se){this.onError(se)}}var ra=!1,Ml=null,$l=!1,gd=null,EE={onError:function(s){ra=!0,Ml=s}};function kE(s,o,c,h,y,x,C,j,A){ra=!1,Ml=null,hn.apply(EE,arguments)}function TE(s,o,c,h,y,x,C,j,A){if(kE.apply(this,arguments),ra){if(ra){var V=Ml;ra=!1,Ml=null}else throw Error(r(198));$l||($l=!0,gd=V)}}function Ws(s){var o=s,c=s;if(s.alternate)for(;o.return;)o=o.return;else{s=o;do o=s,(o.flags&4098)!==0&&(c=o.return),s=o.return;while(s)}return o.tag===3?c:null}function Dm(s){if(s.tag===13){var o=s.memoizedState;if(o===null&&(s=s.alternate,s!==null&&(o=s.memoizedState)),o!==null)return o.dehydrated}return null}function Mm(s){if(Ws(s)!==s)throw Error(r(188))}function CE(s){var o=s.alternate;if(!o){if(o=Ws(s),o===null)throw Error(r(188));return o!==s?null:s}for(var c=s,h=o;;){var y=c.return;if(y===null)break;var x=y.alternate;if(x===null){if(h=y.return,h!==null){c=h;continue}break}if(y.child===x.child){for(x=y.child;x;){if(x===c)return Mm(y),s;if(x===h)return Mm(y),o;x=x.sibling}throw Error(r(188))}if(c.return!==h.return)c=y,h=x;else{for(var C=!1,j=y.child;j;){if(j===c){C=!0,c=y,h=x;break}if(j===h){C=!0,h=y,c=x;break}j=j.sibling}if(!C){for(j=x.child;j;){if(j===c){C=!0,c=x,h=y;break}if(j===h){C=!0,h=x,c=y;break}j=j.sibling}if(!C)throw Error(r(189))}}if(c.alternate!==h)throw Error(r(190))}if(c.tag!==3)throw Error(r(188));return c.stateNode.current===c?s:o}function $m(s){return s=CE(s),s!==null?Fm(s):null}function Fm(s){if(s.tag===5||s.tag===6)return s;for(s=s.child;s!==null;){var o=Fm(s);if(o!==null)return o;s=s.sibling}return null}var Um=t.unstable_scheduleCallback,zm=t.unstable_cancelCallback,RE=t.unstable_shouldYield,PE=t.unstable_requestPaint,Ct=t.unstable_now,jE=t.unstable_getCurrentPriorityLevel,vd=t.unstable_ImmediatePriority,Bm=t.unstable_UserBlockingPriority,Fl=t.unstable_NormalPriority,OE=t.unstable_LowPriority,qm=t.unstable_IdlePriority,Ul=null,pn=null;function AE(s){if(pn&&typeof pn.onCommitFiberRoot=="function")try{pn.onCommitFiberRoot(Ul,s,void 0,(s.current.flags&128)===128)}catch{}}var Br=Math.clz32?Math.clz32:LE,NE=Math.log,IE=Math.LN2;function LE(s){return s>>>=0,s===0?32:31-(NE(s)/IE|0)|0}var zl=64,Bl=4194304;function na(s){switch(s&-s){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return s&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return s}}function ql(s,o){var c=s.pendingLanes;if(c===0)return 0;var h=0,y=s.suspendedLanes,x=s.pingedLanes,C=c&268435455;if(C!==0){var j=C&~y;j!==0?h=na(j):(x&=C,x!==0&&(h=na(x)))}else C=c&~y,C!==0?h=na(C):x!==0&&(h=na(x));if(h===0)return 0;if(o!==0&&o!==h&&(o&y)===0&&(y=h&-h,x=o&-o,y>=x||y===16&&(x&4194240)!==0))return o;if((h&4)!==0&&(h|=c&16),o=s.entangledLanes,o!==0)for(s=s.entanglements,o&=h;0<o;)c=31-Br(o),y=1<<c,h|=s[c],o&=~y;return h}function DE(s,o){switch(s){case 1:case 2:case 4:return o+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return o+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function ME(s,o){for(var c=s.suspendedLanes,h=s.pingedLanes,y=s.expirationTimes,x=s.pendingLanes;0<x;){var C=31-Br(x),j=1<<C,A=y[C];A===-1?((j&c)===0||(j&h)!==0)&&(y[C]=DE(j,o)):A<=o&&(s.expiredLanes|=j),x&=~j}}function yd(s){return s=s.pendingLanes&-1073741825,s!==0?s:s&1073741824?1073741824:0}function Vm(){var s=zl;return zl<<=1,(zl&4194240)===0&&(zl=64),s}function wd(s){for(var o=[],c=0;31>c;c++)o.push(s);return o}function sa(s,o,c){s.pendingLanes|=o,o!==536870912&&(s.suspendedLanes=0,s.pingedLanes=0),s=s.eventTimes,o=31-Br(o),s[o]=c}function $E(s,o){var c=s.pendingLanes&~o;s.pendingLanes=o,s.suspendedLanes=0,s.pingedLanes=0,s.expiredLanes&=o,s.mutableReadLanes&=o,s.entangledLanes&=o,o=s.entanglements;var h=s.eventTimes;for(s=s.expirationTimes;0<c;){var y=31-Br(c),x=1<<y;o[y]=0,h[y]=-1,s[y]=-1,c&=~x}}function bd(s,o){var c=s.entangledLanes|=o;for(s=s.entanglements;c;){var h=31-Br(c),y=1<<h;y&o|s[h]&o&&(s[h]|=o),c&=~y}}var it=0;function Wm(s){return s&=-s,1<s?4<s?(s&268435455)!==0?16:536870912:4:1}var Hm,xd,Km,Gm,Qm,_d=!1,Vl=[],Xn=null,Zn=null,es=null,oa=new Map,ia=new Map,ts=[],FE="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Ym(s,o){switch(s){case"focusin":case"focusout":Xn=null;break;case"dragenter":case"dragleave":Zn=null;break;case"mouseover":case"mouseout":es=null;break;case"pointerover":case"pointerout":oa.delete(o.pointerId);break;case"gotpointercapture":case"lostpointercapture":ia.delete(o.pointerId)}}function aa(s,o,c,h,y,x){return s===null||s.nativeEvent!==x?(s={blockedOn:o,domEventName:c,eventSystemFlags:h,nativeEvent:x,targetContainers:[y]},o!==null&&(o=xa(o),o!==null&&xd(o)),s):(s.eventSystemFlags|=h,o=s.targetContainers,y!==null&&o.indexOf(y)===-1&&o.push(y),s)}function UE(s,o,c,h,y){switch(o){case"focusin":return Xn=aa(Xn,s,o,c,h,y),!0;case"dragenter":return Zn=aa(Zn,s,o,c,h,y),!0;case"mouseover":return es=aa(es,s,o,c,h,y),!0;case"pointerover":var x=y.pointerId;return oa.set(x,aa(oa.get(x)||null,s,o,c,h,y)),!0;case"gotpointercapture":return x=y.pointerId,ia.set(x,aa(ia.get(x)||null,s,o,c,h,y)),!0}return!1}function Jm(s){var o=Hs(s.target);if(o!==null){var c=Ws(o);if(c!==null){if(o=c.tag,o===13){if(o=Dm(c),o!==null){s.blockedOn=o,Qm(s.priority,function(){Km(c)});return}}else if(o===3&&c.stateNode.current.memoizedState.isDehydrated){s.blockedOn=c.tag===3?c.stateNode.containerInfo:null;return}}}s.blockedOn=null}function Wl(s){if(s.blockedOn!==null)return!1;for(var o=s.targetContainers;0<o.length;){var c=Ed(s.domEventName,s.eventSystemFlags,o[0],s.nativeEvent);if(c===null){c=s.nativeEvent;var h=new c.constructor(c.type,c);ta=h,c.target.dispatchEvent(h),ta=null}else return o=xa(c),o!==null&&xd(o),s.blockedOn=c,!1;o.shift()}return!0}function Xm(s,o,c){Wl(s)&&c.delete(o)}function zE(){_d=!1,Xn!==null&&Wl(Xn)&&(Xn=null),Zn!==null&&Wl(Zn)&&(Zn=null),es!==null&&Wl(es)&&(es=null),oa.forEach(Xm),ia.forEach(Xm)}function la(s,o){s.blockedOn===o&&(s.blockedOn=null,_d||(_d=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,zE)))}function ca(s){function o(y){return la(y,s)}if(0<Vl.length){la(Vl[0],s);for(var c=1;c<Vl.length;c++){var h=Vl[c];h.blockedOn===s&&(h.blockedOn=null)}}for(Xn!==null&&la(Xn,s),Zn!==null&&la(Zn,s),es!==null&&la(es,s),oa.forEach(o),ia.forEach(o),c=0;c<ts.length;c++)h=ts[c],h.blockedOn===s&&(h.blockedOn=null);for(;0<ts.length&&(c=ts[0],c.blockedOn===null);)Jm(c),c.blockedOn===null&&ts.shift()}var $o=P.ReactCurrentBatchConfig,Hl=!0;function BE(s,o,c,h){var y=it,x=$o.transition;$o.transition=null;try{it=1,Sd(s,o,c,h)}finally{it=y,$o.transition=x}}function qE(s,o,c,h){var y=it,x=$o.transition;$o.transition=null;try{it=4,Sd(s,o,c,h)}finally{it=y,$o.transition=x}}function Sd(s,o,c,h){if(Hl){var y=Ed(s,o,c,h);if(y===null)zd(s,o,h,Kl,c),Ym(s,h);else if(UE(y,s,o,c,h))h.stopPropagation();else if(Ym(s,h),o&4&&-1<FE.indexOf(s)){for(;y!==null;){var x=xa(y);if(x!==null&&Hm(x),x=Ed(s,o,c,h),x===null&&zd(s,o,h,Kl,c),x===y)break;y=x}y!==null&&h.stopPropagation()}else zd(s,o,h,null,c)}}var Kl=null;function Ed(s,o,c,h){if(Kl=null,s=Do(h),s=Hs(s),s!==null)if(o=Ws(s),o===null)s=null;else if(c=o.tag,c===13){if(s=Dm(o),s!==null)return s;s=null}else if(c===3){if(o.stateNode.current.memoizedState.isDehydrated)return o.tag===3?o.stateNode.containerInfo:null;s=null}else o!==s&&(s=null);return Kl=s,null}function Zm(s){switch(s){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(jE()){case vd:return 1;case Bm:return 4;case Fl:case OE:return 16;case qm:return 536870912;default:return 16}default:return 16}}var rs=null,kd=null,Gl=null;function eg(){if(Gl)return Gl;var s,o=kd,c=o.length,h,y="value"in rs?rs.value:rs.textContent,x=y.length;for(s=0;s<c&&o[s]===y[s];s++);var C=c-s;for(h=1;h<=C&&o[c-h]===y[x-h];h++);return Gl=y.slice(s,1<h?1-h:void 0)}function Ql(s){var o=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&o===13&&(s=13)):s=o,s===10&&(s=13),32<=s||s===13?s:0}function Yl(){return!0}function tg(){return!1}function xr(s){function o(c,h,y,x,C){this._reactName=c,this._targetInst=y,this.type=h,this.nativeEvent=x,this.target=C,this.currentTarget=null;for(var j in s)s.hasOwnProperty(j)&&(c=s[j],this[j]=c?c(x):x[j]);return this.isDefaultPrevented=(x.defaultPrevented!=null?x.defaultPrevented:x.returnValue===!1)?Yl:tg,this.isPropagationStopped=tg,this}return K(o.prototype,{preventDefault:function(){this.defaultPrevented=!0;var c=this.nativeEvent;c&&(c.preventDefault?c.preventDefault():typeof c.returnValue!="unknown"&&(c.returnValue=!1),this.isDefaultPrevented=Yl)},stopPropagation:function(){var c=this.nativeEvent;c&&(c.stopPropagation?c.stopPropagation():typeof c.cancelBubble!="unknown"&&(c.cancelBubble=!0),this.isPropagationStopped=Yl)},persist:function(){},isPersistent:Yl}),o}var Fo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Td=xr(Fo),ua=K({},Fo,{view:0,detail:0}),VE=xr(ua),Cd,Rd,da,Jl=K({},ua,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:jd,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==da&&(da&&s.type==="mousemove"?(Cd=s.screenX-da.screenX,Rd=s.screenY-da.screenY):Rd=Cd=0,da=s),Cd)},movementY:function(s){return"movementY"in s?s.movementY:Rd}}),rg=xr(Jl),WE=K({},Jl,{dataTransfer:0}),HE=xr(WE),KE=K({},ua,{relatedTarget:0}),Pd=xr(KE),GE=K({},Fo,{animationName:0,elapsedTime:0,pseudoElement:0}),QE=xr(GE),YE=K({},Fo,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),JE=xr(YE),XE=K({},Fo,{data:0}),ng=xr(XE),ZE={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},e1={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},t1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function r1(s){var o=this.nativeEvent;return o.getModifierState?o.getModifierState(s):(s=t1[s])?!!o[s]:!1}function jd(){return r1}var n1=K({},ua,{key:function(s){if(s.key){var o=ZE[s.key]||s.key;if(o!=="Unidentified")return o}return s.type==="keypress"?(s=Ql(s),s===13?"Enter":String.fromCharCode(s)):s.type==="
38keydown"||s.type==="keyup"?e1[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:jd,charCode:function(s){return s.type==="keypress"?Ql(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?Ql(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),s1=xr(n1),o1=K({},Jl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),sg=xr(o1),i1=K({},ua,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:jd}),a1=xr(i1),l1=K({},Fo,{propertyName:0,elapsedTime:0,pseudoElement:0}),c1=xr(l1),u1=K({},Jl,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),d1=xr(u1),f1=[9,13,27,32],Od=u&&"CompositionEvent"in window,fa=null;u&&"documentMode"in document&&(fa=document.documentMode);var h1=u&&"TextEvent"in window&&!fa,og=u&&(!Od||fa&&8<fa&&11>=fa),ig=" ",ag=!1;function lg(s,o){switch(s){case"keyup":return f1.indexOf(o.keyCode)!==-1;case"keydown":return o.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function cg(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var Uo=!1;function p1(s,o){switch(s){case"compositionend":return cg(o);case"keypress":return o.which!==32?null:(ag=!0,ig);case"textInput":return s=o.data,s===ig&&ag?null:s;default:return null}}function m1(s,o){if(Uo)return s==="compositionend"||!Od&&lg(s,o)?(s=eg(),Gl=kd=rs=null,U
vendor: 17,518 bytes, lines 38-39
38o=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(o.ctrlKey||o.altKey||o.metaKey)||o.ctrlKey&&o.altKey){if(o.char&&1<o.char.length)return o.char;if(o.which)return String.fromCharCode(o.which)}return null;case"compositionend":return og&&o.locale!=="ko"?null:o.data;default:return null}}var g1={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function ug(s){var o=s&&s.nodeName&&s.nodeName.toLowerCase();return o==="input"?!!g1[s.type]:o==="textarea"}function dg(s,o,c,h){Dl(h),o=rc(o,"onChange"),0<o.length&&(c=new Td("onChange","change",null,c,h),s.push({event:c,listeners:o}))}var ha=null,pa=null;function v1(s){Pg(s,0)}function Xl(s){var o=Wo(s);if(J(o))return s}function y1(s,o){if(s==="change")return o}var fg=!1;if(u){var Ad;if(u){var Nd="oninput"in document;if(!Nd){var hg=document.createElement("div");hg.setAttribute("oninput","return;"),Nd=typeof hg.oninput=="function"}Ad=Nd}else Ad=!1;fg=Ad&&(!document.documentMode||9<document.documentMode)}function pg(){ha&&(ha.detachEvent("onpropertychange",mg),pa=ha=null)}function mg(s){if(s.propertyName==="value"&&Xl(pa)){var o=[];dg(o,pa,s,Do(s)),lr(v1,o)}}function w1(s,o,c){s==="focusin"?(pg(),ha=o,pa=c,ha.attachEvent("onpropertychange",mg)):s==="focusout"&&pg()}function b1(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return Xl(pa)}function x1(s,o){if(s==="click")return Xl(o)}function _1(s,o){if(s==="input"||s==="change")return Xl(o)}function S1(s,o){return s===o&&(s!==0||1/s===1/o)||s!==s&&o!==o}var qr=typeof Object.is=="function"?Object.is:S1;function ma(s,o){if(qr(s,o))return!0;if(typeof s!="object"||s===null||typeof o!="object"||o===null)return!1;var c=Object.keys(s),h=Object.keys(o);if(c.length!==h.length)return!1;for(h=0;h<c.length;h++){var y=c[h];if(!f.call(o,y)||!qr(s[y],o[y]))return!1}return!0}function gg(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function vg(s,o){var c=gg(s);s=0;for(var h;c;){if(c.nodeType===3){if(h=s+c.textContent.length,s<=o&&h>=o)return{node:c,offset:o-s};s=h}e:{for(;c;){if(c.nextSibling){c=c.nextSibling;break e}c=c.parentNode}c=void 0}c=gg(c)}}function yg(s,o){return s&&o?s===o?!0:s&&s.nodeType===3?!1:o&&o.nodeType===3?yg(s,o.parentNode):"contains"in s?s.contains(o):s.compareDocumentPosition?!!(s.compareDocumentPosition(o)&16):!1:!1}function wg(){for(var s=window,o=Z();o instanceof s.HTMLIFrameElement;){try{var c=typeof o.contentWindow.location.href=="string"}catch{c=!1}if(c)s=o.contentWindow;else break;o=Z(s.document)}return o}function Id(s){var o=s&&s.nodeName&&s.nodeName.toLowerCase();return o&&(o==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||o==="textarea"||s.contentEditable==="true")}function E1(s){var o=wg(),c=s.focusedElem,h=s.selectionRange;if(o!==c&&c&&c.ownerDocument&&yg(c.ownerDocument.documentElement,c)){if(h!==null&&Id(c)){if(o=h.start,s=h.end,s===void 0&&(s=o),"selectionStart"in c)c.selectionStart=o,c.selectionEnd=Math.min(s,c.value.length);else if(s=(o=c.ownerDocument||document)&&o.defaultView||window,s.getSelection){s=s.getSelection();var y=c.textContent.length,x=Math.min(h.start,y);h=h.end===void 0?x:Math.min(h.end,y),!s.extend&&x>h&&(y=h,h=x,x=y),y=vg(c,x);var C=vg(c,h);y&&C&&(s.rangeCount!==1||s.anchorNode!==y.node||s.anchorOffset!==y.offset||s.focusNode!==C.node||s.focusOffset!==C.offset)&&(o=o.createRange(),o.setStart(y.node,y.offset),s.removeAllRanges(),x>h?(s.addRange(o),s.extend(C.node,C.offset)):(o.setEnd(C.node,C.offset),s.addRange(o)))}}for(o=[],s=c;s=s.parentNode;)s.nodeType===1&&o.push({element:s,left:s.scrollLeft,top:s.scrollTop});for(typeof c.focus=="function"&&c.focus(),c=0;c<o.length;c++)s=o[c],s.element.scrollLeft=s.left,s.element.scrollTop=s.top}}var k1=u&&"documentMode"in document&&11>=document.documentMode,zo=null,Ld=null,ga=null,Dd=!1;function bg(s,o,c){var h=c.window===c?c.document:c.nodeType===9?c:c.ownerDocument;Dd||zo==null||zo!==Z(h)||(h=zo,"selectionStart"in h&&Id(h)?h={start:h.selectionStart,end:h.selectionEnd}:(h=(h.ownerDocument&&h.ownerDocument.defaultView||window).getSelection(),h={anchorNode:h.anchorNode,anchorOffset:h.anchorOffset,focusNode:h.focusNode,focusOffset:h.focusOffset}),ga&&ma(ga,h)||(ga=h,h=rc(Ld,"onSelect"),0<h.length&&(o=new Td("onSelect","select",null,o,c),s.push({event:o,listeners:h}),o.target=zo)))}function Zl(s,o){var c={};return c[s.toLowerCase()]=o.toLowerCase(),c["Webkit"+s]="webkit"+o,c["Moz"+s]="moz"+o,c}var Bo={animationend:Zl("Animation","AnimationEnd"),animationiteration:Zl("Animation","AnimationIteration"),animationstart:Zl("Animation","AnimationStart"),transitionend:Zl("Transition","TransitionEnd")},Md={},xg={};u&&(xg=document.createElement("div").style,"AnimationEvent"in window||(delete Bo.animationend.animation,delete Bo.animationiteration.animation,delete Bo.animationstart.animation),"TransitionEvent"in window||delete Bo.transitionend.transition);function ec(s){if(Md[s])return Md[s];if(!Bo[s])return s;var o=Bo[s],c;for(c in o)if(o.hasOwnProperty(c)&&c in xg)return Md[s]=o[c];return s}var _g=ec("animationend"),Sg=ec("animationiteration"),Eg=ec("animationstart"),kg=ec("transitionend"),Tg=new Map,Cg="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function ns(s,o){Tg.set(s,o),a(o,[s])}for(var $d=0;$d<Cg.length;$d++){var Fd=Cg[$d],T1=Fd.toLowerCase(),C1=Fd[0].toUpperCase()+Fd.slice(1);ns(T1,"on"+C1)}ns(_g,"onAnimationEnd"),ns(Sg,"onAnimationIteration"),ns(Eg,"onAnimationStart"),ns("dblclick","onDoubleClick"),ns("focusin","onFocus"),ns("focusout","onBlur"),ns(kg,"onTransitionEnd"),l("onMouseEnter",["mouseout","mouseover"]),l("onMouseLeave",["mouseout","mouseover"]),l("onPointerEnter",["pointerout","pointerover"]),l("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var va="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),R1=new Set("cancel close invalid load scroll toggle".split(" ").concat(va));function Rg(s,o,c){var h=s.type||"unknown-event";s.currentTarget=c,TE(h,o,void 0,s),s.currentTarget=null}function Pg(s,o){o=(o&4)!==0;for(var c=0;c<s.length;c++){var h=s[c],y=h.event;h=h.listeners;e:{var x=void 0;if(o)for(var C=h.length-1;0<=C;C--){var j=h[C],A=j.instance,V=j.currentTarget;if(j=j.listener,A!==x&&y.isPropagationStopped())break e;Rg(y,j,V),x=A}else for(C=0;C<h.length;C++){if(j=h[C],A=j.instance,V=j.currentTarget,j=j.listener,A!==x&&y.isPropagationStopped())break e;Rg(y,j,V),x=A}}}if($l)throw s=gd,$l=!1,gd=null,s}function dt(s,o){var c=o[Kd];c===void 0&&(c=o[Kd]=new Set);var h=s+"__bubble";c.has(h)||(jg(o,s,2,!1),c.add(h))}function Ud(s,o,c){var h=0;o&&(h|=4),jg(c,s,h,o)}var tc="_reactListening"+Math.random().toString(36).slice(2);function ya(s){if(!s[tc]){s[tc]=!0,n.forEach(function(c){c!=="selectionchange"&&(R1.has(c)||Ud(c,!1,s),Ud(c,!0,s))});var o=s.nodeType===9?s:s.ownerDocument;o===null||o[tc]||(o[tc]=!0,Ud("selectionchange",!1,o))}}function jg(s,o,c,h){switch(Zm(o)){case 1:var y=BE;break;case 4:y=qE;break;default:y=Sd}c=y.bind(null,o,c,s),y=void 0,!zr||o!=="touchstart"&&o!=="touchmove"&&o!=="wheel"||(y=!0),h?y!==void 0?s.addEventListener(o,c,{capture:!0,passive:y}):s.addEventListener(o,c,!0):y!==void 0?s.addEventListener(o,c,{passive:y}):s.addEventListener(o,c,!1)}function zd(s,o,c,h,y){var x=h;if((o&1)===0&&(o&2)===0&&h!==null)e:for(;;){if(h===null)return;var C=h.tag;if(C===3||C===4){var j=h.stateNode.containerInfo;if(j===y||j.nodeType===8&&j.parentNode===y)break;if(C===4)for(C=h.return;C!==null;){var A=C.tag;if((A===3||A===4)&&(A=C.stateNode.containerInfo,A===y||A.nodeType===8&&A.parentNode===y))return;C=C.return}for(;j!==null;){if(C=Hs(j),C===null)return;if(A=C.tag,A===5||A===6){h=x=C;continue e}j=j.parentNode}}h=h.return}lr(function(){var V=x,se=Do(c),ie=[];e:{var ee=Tg.get(s);if(ee!==void 0){var ge=Td,be=s;switch(s){case"keypress":if(Ql(c)===0)break e;case"keydown":case"keyup":ge=s1;break;case"focusin":be="focus",ge=Pd;break;case"focusout":be="blur",ge=Pd;break;case"beforeblur":case"afterblur":ge=Pd;break;case"click":if(c.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ge=rg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ge=HE;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ge=a1;break;case _g:case Sg:case Eg:ge=QE;break;case kg:ge=c1;break;case"scroll":ge=VE;break;case"wheel":ge=d1;break;case"copy":case"cut":case"paste":ge=JE;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ge=sg}var ke=(o&4)!==0,Rt=!ke&&s==="scroll",$=ke?ee!==null?ee+"Capture":null:ee;ke=[];for(var D=V,B;D!==null;){B=D;var ce=B.stateNode;if(B.tag===5&&ce!==null&&(B=ce,$!==null&&(ce=cr(D,$),ce!=null&&ke.push(wa(D,ce,B)))),Rt)break;D=D.return}0<ke.length&&(ee=new ge(ee,be,null,c,se),ie.push({event:ee,listeners:ke}))}}if((o&7)===0){e:{if(ee=s==="mouseover"||s==="pointerover",ge=s==="mouseout"||s==="pointerout",ee&&c!==ta&&(be=c.relatedTarget||c.fromElement)&&(Hs(be)||be[An]))break e;if((ge||ee)&&(ee=se.window===se?se:(ee=se.ownerDocument)?ee.defaultView||ee.parentWindow:window,ge?(be=c.relatedTarget||c.toElement,ge=V,be=be?Hs(be):null,be!==null&&(Rt=Ws(be),be!==Rt||be.tag!==5&&be.tag!==6)&&(be=null)):(ge=null,be=V),ge!==be)){if(ke=rg,ce="onMouseLeave",$="onMouseEnter",D="mouse",(s==="pointerout"||s==="pointerover")&&(ke=sg,ce="onPointerLeave",$="onPointerEnter",D="pointer"),Rt=ge==null?ee:Wo(ge),B=be==null?ee:Wo(be),ee=new ke(ce,D+"leave",ge,c,se),ee.target=Rt,ee.relatedTarget=B,ce=null,Hs(se)===V&&(ke=new ke($,D+"enter",be,c,se),ke.target=B,ke.relatedTarget=Rt,ce=ke),Rt=ce,ge&&be)t:{for(ke=ge,$=be,D=0,B=ke;B;B=qo(B))D++;for(B=0,ce=$;ce;ce=qo(ce))B++;for(;0<D-B;)ke=qo(ke),D--;for(;0<B-D;)$=qo($),B--;for(;D--;){if(ke===$||$!==null&&ke===$.alternate)break t;ke=qo(ke),$=qo($)}ke=null}else ke=null;ge!==null&&Og(ie,ee,ge,ke,!1),be!==null&&Rt!==null&&Og(ie,Rt,be,ke,!0)}}e:{if(ee=V?Wo(V):window,ge=ee.nodeName&&ee.nodeName.toLowerCase(),ge==="select"||ge==="input"&&ee.type==="file")var Ce=y1;else if(ug(ee))if(fg)Ce=_1;else{Ce=b1;var Ie=w1}else(ge=ee.nodeName)&&ge.toLowerCase()==="input"&&(ee.type==="checkbox"||ee.type==="radio")&&(Ce=x1);if(Ce&&(Ce=Ce(s,V))){dg(ie,Ce,c,se);break e}Ie&&Ie(s,ee,V),s==="focusout"&&(Ie=ee._wrapperState)&&Ie.controlled&&ee.type==="number"&&Be(ee,"number",ee.value)}switch(Ie=V?Wo(V):window,s){case"focusin":(ug(Ie)||Ie.contentEditable==="true")&&(zo=Ie,Ld=V,ga=null);break;case"focusout":ga=Ld=zo=null;break;case"mousedown":Dd=!0;break;case"contextmenu":case"mouseup":case"dragend":Dd=!1,bg(ie,c,se);break;case"selectionchange":if(k1)break;case"keydown":case"keyup":bg(ie,c,se)}var Le;if(Od)e:{switch(s){case"compositionstart":var $e="onCompositionStart";break e;case"compositionend":$e="onCompositionEnd";break e;case"compositionupdate":$e="onCompositionUpdate";break e}$e=void 0}else Uo?lg(s,c)&&($e="onCompositionEnd"):s==="keydown"&&c.keyCode===229&&($e="onCompositionStart");$e&&(og&&c.locale!=="ko"&&(Uo||$e!=="onCompositionStart"?$e==="onCompositionEnd"&&Uo&&(Le=eg()):(rs=se,kd="value"in rs?rs.value:rs.textContent,Uo=!0)),Ie=rc(V,$e),0<Ie.length&&($e=new ng($e,s,null,c,se),ie.push({event:$e,listeners:Ie}),Le?$e.data=Le:(Le=cg(c),Le!==null&&($e.data=Le)))),(Le=h1?p1(s,c):m1(s,c))&&(V=rc(V,"onBeforeInput"),0<V.length&&(se=new ng("onBeforeInput","beforeinput",null,c,se),ie.push({event:se,listeners:V}),se.data=Le))}Pg(ie,o)})}function wa(s,o,c){return{instance:s,listener:o,currentTarget:c}}function rc(s,o){for(var c=o+"Capture",h=[];s!==null;){var y=s,x=y.stateNode;y.tag===5&&x!==null&&(y=x,x=cr(s,c),x!=null&&h.unshift(wa(s,x,y)),x=cr(s,o),x!=null&&h.push(wa(s,x,y))),s=s.return}return h}function qo(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5);return s||null}function Og(s,o,c,h,y){for(var x=o._reactName,C=[];c!==null&&c!==h;){var j=c,A=j.alternate,V=j.stateNode;if(A!==null&&A===h)break;j.tag===5&&V!==null&&(j=V,y?(A=cr(c,x),A!=null&&C.unshift(wa(c,A,j))):y||(A=cr(c,x),A!=null&&C.push(wa(c,A,j)))),c=c.return}C.length!==0&&s.push({event:o,listeners:C})}var P1=/\r\n?/g,j1=/\u0000|\uFFFD/g;function Ag(s){return(typeof s=="string"?s:""+s).replace(P1,`
39`).replace(j1,"")}function nc(s,o,c){if(o=Ag(o),Ag(s)!==o&&c)throw Error(r(425))}function sc(){}var Bd=null,qd=null;function Vd(s,o){return s==="textarea"||s==="noscript"||typeof o.children=="string"||typeof o.children=="number"||typeof o.dangerouslySetInnerHTML=="object"&&o.dangerouslySetInnerHTML!==null&&o.dangerouslySetInnerHTML.__html!=null}var Wd=typeof setTimeout=="function"?setTimeout:void 0,O1=typeof clearTimeout=="function"?clearTimeout:void 0,Ng=typeof Promise=="function"?Promise:void 0,A1=typeof queueMicrotask=="function"?queueMicrotask:typeof Ng<"u"?function(s){return Ng.resolve(null).then(s).catch(N1)}:Wd;function N1(s){setTimeout(function(){throw s})}function Hd(s,o){var c=o,h=0;do{var y=c.nextSibling;if(s.removeChild(c),y&&y.nodeType===8)if(c=y.data,c==="/$"){if(h===0){s.removeChild(y),ca(o);return}h--}else c!=="$"&&c!=="$?"&&c!=="$!"||h++;c=y}while(c);ca(o)}function ss(s){for(;s!=null;s=s.nextSibling){var o=s.nodeType;if(o===1||o===3)break;if(o===8){if(o=s.data,o==="$"||o==="$!"||o==="$?")break;if(o==="/$")return null}}return s}function Ig(s){s=s.previousSibling;for(var o=0;s;){if(s.nodeType===8){var c=s.data;if(c==="$"||c==="$!"||c==="$?"){if(o===0)return s;o--}else c==="/$"&&o++}s=s.previousSibling}return null}var Vo=Math.random().toString(36).slice(2),mn="__reactFiber$"+Vo,ba="__reactProps$"+Vo,An="__reactContainer$"+Vo,Kd="__reactEvents$"+Vo,I1="__reactListeners$"+Vo,L1="__reactHandles$"+Vo;function Hs(s){var o=s[mn];if(o)return o;for(var c=s.parentNode;c;){if(o=c[An]||c[mn]){if(c=o.alternate,o.child!==null||c!==null&&c.child!==null)for(s=Ig(s);s!==null;){if(c=s[mn])return c;s=Ig(s)}return o}s=c,c=s.parentNode}return null}function xa(s){return s=s[mn]||s[An],!s||s.tag!==5&&s.tag!==6&&s.tag!==13&&s.tag!==3?null:s}function Wo(s){if(s.tag===5||s.tag===6)return s.stateNode;throw Error(r(33))}function oc(s){return s[ba]||null}var Gd=[],Ho=-1;function os(s){return{current:s}}function ft(s){0>Ho||(s.current=Gd[Ho],Gd[Ho]=null,Ho--)}function lt(s,o){Ho++,Gd[Ho]=s.current,s.current=o}var is={},Qt=os(is),ur=os(!1),Ks=is;function Ko(s,o){var c=s.type.contextTypes;if(!c)return is;var h=s.stateNode;if(h&&h.__reactInternalMemoizedUnmaskedChildContext===o)return h.__reactInternalMemoizedMaskedChildContext;var y={},x;for(x in c)y[x]=o[x];return h&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=o,s.__reactInternalMemoizedMaskedChildContext=y),y}function dr(s){return s=s.childContextTypes,s!=null}function ic(){ft(ur),ft(Qt)}function Lg(s,o,c){if(Qt.current!==is)throw Error(r(168));lt(Qt,o),lt(ur,c)}function Dg(s,o,c){var h=s.stateNode;if(o=o.childContextTypes,typeof h.getChildContext!="function")return c;h=h.getChildContext();for(var y in h)if(!(y in o))throw Error(r(108,Re(s)||"Unknown",y));return K({},c,h)}function ac(s){return s=(s=s.stateNode)&&s.__reactInternalMemoizedMergedChildContext||is,Ks=Qt.current,lt(Qt,s),lt(ur,ur.current),!0}function Mg(s,o,c){var h=s.stateNode;if(!h)throw Error(r(169));c?(s=Dg(s,o,Ks),h.__reactInternalMemoizedMergedChildContext=s,ft(ur),ft(Qt),lt(Qt,s)):ft(ur),lt(ur,c)}var Nn=null,lc=!1,Qd=!1;function $g(s){Nn===null?Nn=[s]:Nn.push(s)}function D1(s){lc=!0,$g(s)}function as(){if(!Qd&&Nn!==null){Qd=!0;var s=0,o=it;try{var c=Nn;for(it=1;s<c.length;s++){var h=c[s];do h=h(!0);while(h!==null)}Nn=null,lc=!1}catch(y){throw Nn!==null&&(Nn=Nn.slice(s+1)),Um(vd,as),y}finally{it=o,Qd=!1}}return null}var Go=[],Qo=0,cc=null,uc=0,jr=[],Or=0,Gs=null,In=1,Ln="";function Qs(s,o){Go[Qo++]=uc,Go[Qo++]=cc,cc=s,uc=o}function Fg(s,o,c){jr[Or++]=In,jr[Or++]=Ln,jr[Or++]=Gs,Gs=s;var h=In;s=Ln;var y=32-Br(h)-1;h&=~(1<<y),c+=1;var x=32-Br(o)+y;if(30<x){var C=y-y%5;x=(h&(1<<C)-1).toString(32),h>>=C,y-=C,In=1<<32-Br(o)+y|c<<y|h,Ln=x+s}else In=1<<x|c<<y|h,Ln=s}function Yd(s){s.return!==null&&(Qs(s,1),Fg(s,1,0))}function Jd(s){for(;s===cc;)cc=Go[--Qo],Go[Qo]=null,uc=Go[--Qo],Go[Qo]=null;for(;s===Gs;
vendor: 3,839 bytes, line 39
39)Gs=jr[--Or],jr[Or]=null,Ln=jr[--Or],jr[Or]=null,In=jr[--Or],jr[Or]=null}var _r=null,Sr=null,pt=!1,Vr=null;function Ug(s,o){var c=Lr(5,null,null,0);c.elementType="DELETED",c.stateNode=o,c.return=s,o=s.deletions,o===null?(s.deletions=[c],s.flags|=16):o.push(c)}function zg(s,o){switch(s.tag){case 5:var c=s.type;return o=o.nodeType!==1||c.toLowerCase()!==o.nodeName.toLowerCase()?null:o,o!==null?(s.stateNode=o,_r=s,Sr=ss(o.firstChild),!0):!1;case 6:return o=s.pendingProps===""||o.nodeType!==3?null:o,o!==null?(s.stateNode=o,_r=s,Sr=null,!0):!1;case 13:return o=o.nodeType!==8?null:o,o!==null?(c=Gs!==null?{id:In,overflow:Ln}:null,s.memoizedState={dehydrated:o,treeContext:c,retryLane:1073741824},c=Lr(18,null,null,0),c.stateNode=o,c.return=s,s.child=c,_r=s,Sr=null,!0):!1;default:return!1}}function Xd(s){return(s.mode&1)!==0&&(s.flags&128)===0}function Zd(s){if(pt){var o=Sr;if(o){var c=o;if(!zg(s,o)){if(Xd(s))throw Error(r(418));o=ss(c.nextSibling);var h=_r;o&&zg(s,o)?Ug(h,c):(s.flags=s.flags&-4097|2,pt=!1,_r=s)}}else{if(Xd(s))throw Error(r(418));s.flags=s.flags&-4097|2,pt=!1,_r=s}}}function Bg(s){for(s=s.return;s!==null&&s.tag!==5&&s.tag!==3&&s.tag!==13;)s=s.return;_r=s}function dc(s){if(s!==_r)return!1;if(!pt)return Bg(s),pt=!0,!1;var o;if((o=s.tag!==3)&&!(o=s.tag!==5)&&(o=s.type,o=o!=="head"&&o!=="body"&&!Vd(s.type,s.memoizedProps)),o&&(o=Sr)){if(Xd(s))throw qg(),Error(r(418));for(;o;)Ug(s,o),o=ss(o.nextSibling)}if(Bg(s),s.tag===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));e:{for(s=s.nextSibling,o=0;s;){if(s.nodeType===8){var c=s.data;if(c==="/$"){if(o===0){Sr=ss(s.nextSibling);break e}o--}else c!=="$"&&c!=="$!"&&c!=="$?"||o++}s=s.nextSibling}Sr=null}}else Sr=_r?ss(s.stateNode.nextSibling):null;return!0}function qg(){for(var s=Sr;s;)s=ss(s.nextSibling)}function Yo(){Sr=_r=null,pt=!1}function ef(s){Vr===null?Vr=[s]:Vr.push(s)}var M1=P.ReactCurrentBatchConfig;function _a(s,o,c){if(s=c.ref,s!==null&&typeof s!="function"&&typeof s!="object"){if(c._owner){if(c=c._owner,c){if(c.tag!==1)throw Error(r(309));var h=c.stateNode}if(!h)throw Error(r(147,s));var y=h,x=""+s;return o!==null&&o.ref!==null&&typeof o.ref=="function"&&o.ref._stringRef===x?o.ref:(o=function(C){var j=y.refs;C===null?delete j[x]:j[x]=C},o._stringRef=x,o)}if(typeof s!="string")throw Error(r(284));if(!c._owner)throw Error(r(290,s))}return s}function fc(s,o){throw s=Object.prototype.toString.call(o),Error(r(31,s==="[object Object]"?"object with keys {"+Object.keys(o).join(", ")+"}":s))}function Vg(s){var o=s._init;return o(s._payload)}function Wg(s){function o($,D){if(s){var B=$.deletions;B===null?($.deletions=[D],$.flags|=16):B.push(D)}}function c($,D){if(!s)return null;for(;D!==null;)o($,D),D=D.sibling;return null}function h($,D){for($=new Map;D!==null;)D.key!==null?$.set(D.key,D):$.set(D.index,D),D=D.sibling;return $}function y($,D){return $=ms($,D),$.index=0,$.sibling=null,$}function x($,D,B){return $.index=B,s?(B=$.alternate,B!==null?(B=B.index,B<D?($.flags|=2,D):B):($.flags|=2,D)):($.flags|=1048576,D)}function C($){return s&&$.alternate===null&&($.flags|=2),$}function j($,D,B,ce){return D===null||D.tag!==6?(D=Hf(B,$.mode,ce),D.return=$,D):(D=y(D,B),D.return=$,D)}function A($,D,B,ce){var Ce=B.type;return Ce===M?se($,D,B.props.children,ce,B.key):D!==null&&(D.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===Te&&Vg(Ce)===D.type)?(ce=y(D,B.props),ce.ref=_a($,D,B),ce.return=$,ce):(ce=Dc(B.type,B.key,B.props,null,$.mode,ce),ce.ref=_a($,D,B),ce.return=$,ce)}function V($,D,B,ce){return D===null||D.tag!==4||D.stateNode.containerInfo!==B.containerInfo||D.stateNode.implementation!==B.implementation?(D=Kf(B,$.mode,ce),D.return=$,D):(D=y(D,B.children||[]),D.return=$,D)}function se($,D,B,ce,Ce){return D===null||D.tag!==7?(D=no(B,$.mode,ce,Ce),D.return=$,D):(D=y(D,B),D.return=$,D)}
vendor: 11,901 bytes, line 39
39function ie($,D,B){if(typeof D=="string"&&D!==""||typeof D=="number")return D=Hf(""+D,$.mode,B),D.return=$,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case O:return B=Dc(D.type,D.key,D.props,null,$.mode,B),B.ref=_a($,null,D),B.return=$,B;case I:return D=Kf(D,$.mode,B),D.return=$,D;case Te:var ce=D._init;return ie($,ce(D._payload),B)}if(rt(D)||W(D))return D=no(D,$.mode,B,null),D.return=$,D;fc($,D)}return null}function ee($,D,B,ce){var Ce=D!==null?D.key:null;if(typeof B=="string"&&B!==""||typeof B=="number")return Ce!==null?null:j($,D,""+B,ce);if(typeof B=="object"&&B!==null){switch(B.$$typeof){case O:return B.key===Ce?A($,D,B,ce):null;case I:return B.key===Ce?V($,D,B,ce):null;case Te:return Ce=B._init,ee($,D,Ce(B._payload),ce)}if(rt(B)||W(B))return Ce!==null?null:se($,D,B,ce,null);fc($,B)}return null}function ge($,D,B,ce,Ce){if(typeof ce=="string"&&ce!==""||typeof ce=="number")return $=$.get(B)||null,j(D,$,""+ce,Ce);if(typeof ce=="object"&&ce!==null){switch(ce.$$typeof){case O:return $=$.get(ce.key===null?B:ce.key)||null,A(D,$,ce,Ce);case I:return $=$.get(ce.key===null?B:ce.key)||null,V(D,$,ce,Ce);case Te:var Ie=ce._init;return ge($,D,B,Ie(ce._payload),Ce)}if(rt(ce)||W(ce))return $=$.get(B)||null,se(D,$,ce,Ce,null);fc(D,ce)}return null}function be($,D,B,ce){for(var Ce=null,Ie=null,Le=D,$e=D=0,Ft=null;Le!==null&&$e<B.length;$e++){Le.index>$e?(Ft=Le,Le=null):Ft=Le.sibling;var Ze=ee($,Le,B[$e],ce);if(Ze===null){Le===null&&(Le=Ft);break}s&&Le&&Ze.alternate===null&&o($,Le),D=x(Ze,D,$e),Ie===null?Ce=Ze:Ie.sibling=Ze,Ie=Ze,Le=Ft}if($e===B.length)return c($,Le),pt&&Qs($,$e),Ce;if(Le===null){for(;$e<B.length;$e++)Le=ie($,B[$e],ce),Le!==null&&(D=x(Le,D,$e),Ie===null?Ce=Le:Ie.sibling=Le,Ie=Le);return pt&&Qs($,$e),Ce}for(Le=h($,Le);$e<B.length;$e++)Ft=ge(Le,$,$e,B[$e],ce),Ft!==null&&(s&&Ft.alternate!==null&&Le.delete(Ft.key===null?$e:Ft.key),D=x(Ft,D,$e),Ie===null?Ce=Ft:Ie.sibling=Ft,Ie=Ft);return s&&Le.forEach(function(gs){return o($,gs)}),pt&&Qs($,$e),Ce}function ke($,D,B,ce){var Ce=W(B);if(typeof Ce!="function")throw Error(r(150));if(B=Ce.call(B),B==null)throw Error(r(151));for(var Ie=Ce=null,Le=D,$e=D=0,Ft=null,Ze=B.next();Le!==null&&!Ze.done;$e++,Ze=B.next()){Le.index>$e?(Ft=Le,Le=null):Ft=Le.sibling;var gs=ee($,Le,Ze.value,ce);if(gs===null){Le===null&&(Le=Ft);break}s&&Le&&gs.alternate===null&&o($,Le),D=x(gs,D,$e),Ie===null?Ce=gs:Ie.sibling=gs,Ie=gs,Le=Ft}if(Ze.done)return c($,Le),pt&&Qs($,$e),Ce;if(Le===null){for(;!Ze.done;$e++,Ze=B.next())Ze=ie($,Ze.value,ce),Ze!==null&&(D=x(Ze,D,$e),Ie===null?Ce=Ze:Ie.sibling=Ze,Ie=Ze);return pt&&Qs($,$e),Ce}for(Le=h($,Le);!Ze.done;$e++,Ze=B.next())Ze=ge(Le,$,$e,Ze.value,ce),Ze!==null&&(s&&Ze.alternate!==null&&Le.delete(Ze.key===null?$e:Ze.key),D=x(Ze,D,$e),Ie===null?Ce=Ze:Ie.sibling=Ze,Ie=Ze);return s&&Le.forEach(function(gk){return o($,gk)}),pt&&Qs($,$e),Ce}function Rt($,D,B,ce){if(typeof B=="object"&&B!==null&&B.type===M&&B.key===null&&(B=B.props.children),typeof B=="object"&&B!==null){switch(B.$$typeof){case O:e:{for(var Ce=B.key,Ie=D;Ie!==null;){if(Ie.key===Ce){if(Ce=B.type,Ce===M){if(Ie.tag===7){c($,Ie.sibling),D=y(Ie,B.props.children),D.return=$,$=D;break e}}else if(Ie.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===Te&&Vg(Ce)===Ie.type){c($,Ie.sibling),D=y(Ie,B.props),D.ref=_a($,Ie,B),D.return=$,$=D;break e}c($,Ie);break}else o($,Ie);Ie=Ie.sibling}B.type===M?(D=no(B.props.children,$.mode,ce,B.key),D.return=$,$=D):(ce=Dc(B.type,B.key,B.props,null,$.mode,ce),ce.ref=_a($,D,B),ce.return=$,$=ce)}return C($);case I:e:{for(Ie=B.key;D!==null;){if(D.key===Ie)if(D.tag===4&&D.stateNode.containerInfo===B.containerInfo&&D.stateNode.implementation===B.implementation){c($,D.sibling),D=y(D,B.children||[]),D.return=$,$=D;break e}else{c($,D);break}else o($,D);D=D.sibling}D=Kf(B,$.mode,ce),D.return=$,$=D}return C($);case Te:return Ie=B._init,Rt($,D,Ie(B._payload),ce)}if(rt(B))return be($,D,B,ce);if(W(B))return ke($,D,B,ce);fc($,B)}return typeof B=="string"&&B!==""||typeof B=="number"?(B=""+B,D!==null&&D.tag===6?(c($,D.sibling),D=y(D,B),D.return=$,$=D):(c($,D),D=Hf(B,$.mode,ce),D.return=$,$=D),C($)):c($,D)}return Rt}var Jo=Wg(!0),Hg=Wg(!1),hc=os(null),pc=null,Xo=null,tf=null;function rf(){tf=Xo=pc=null}function nf(s){var o=hc.current;ft(hc),s._currentValue=o}function sf(s,o,c){for(;s!==null;){var h=s.alternate;if((s.childLanes&o)!==o?(s.childLanes|=o,h!==null&&(h.childLanes|=o)):h!==null&&(h.childLanes&o)!==o&&(h.childLanes|=o),s===c)break;s=s.return}}function Zo(s,o){pc=s,tf=Xo=null,s=s.dependencies,s!==null&&s.firstContext!==null&&((s.lanes&o)!==0&&(fr=!0),s.firstContext=null)}function Ar(s){var o=s._currentValue;if(tf!==s)if(s={context:s,memoizedValue:o,next:null},Xo===null){if(pc===null)throw Error(r(308));Xo=s,pc.dependencies={lanes:0,firstContext:s}}else Xo=Xo.next=s;return o}var Ys=null;function of(s){Ys===null?Ys=[s]:Ys.push(s)}function Kg(s,o,c,h){var y=o.interleaved;return y===null?(c.next=c,of(o)):(c.next=y.next,y.next=c),o.interleaved=c,Dn(s,h)}function Dn(s,o){s.lanes|=o;var c=s.alternate;for(c!==null&&(c.lanes|=o),c=s,s=s.return;s!==null;)s.childLanes|=o,c=s.alternate,c!==null&&(c.childLanes|=o),c=s,s=s.return;return c.tag===3?c.stateNode:null}var ls=!1;function af(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Gg(s,o){s=s.updateQueue,o.updateQueue===s&&(o.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,effects:s.effects})}function Mn(s,o){return{eventTime:s,lane:o,tag:0,payload:null,callback:null,next:null}}function cs(s,o,c){var h=s.updateQueue;if(h===null)return null;if(h=h.shared,(Xe&2)!==0){var y=h.pending;return y===null?o.next=o:(o.next=y.next,y.next=o),h.pending=o,Dn(s,c)}return y=h.interleaved,y===null?(o.next=o,of(h)):(o.next=y.next,y.next=o),h.interleaved=o,Dn(s,c)}function mc(s,o,c){if(o=o.updateQueue,o!==null&&(o=o.shared,(c&4194240)!==0)){var h=o.lanes;h&=s.pendingLanes,c|=h,o.lanes=c,bd(s,c)}}function Qg(s,o){var c=s.updateQueue,h=s.alternate;if(h!==null&&(h=h.updateQueue,c===h)){var y=null,x=null;if(c=c.firstBaseUpdate,c!==null){do{var C={eventTime:c.eventTime,lane:c.lane,tag:c.tag,payload:c.payload,callback:c.callback,next:null};x===null?y=x=C:x=x.next=C,c=c.next}while(c!==null);x===null?y=x=o:x=x.next=o}else y=x=o;c={baseState:h.baseState,firstBaseUpdate:y,lastBaseUpdate:x,shared:h.shared,effects:h.effects},s.updateQueue=c;return}s=c.lastBaseUpdate,s===null?c.firstBaseUpdate=o:s.next=o,c.lastBaseUpdate=o}function gc(s,o,c,h){var y=s.updateQueue;ls=!1;var x=y.firstBaseUpdate,C=y.lastBaseUpdate,j=y.shared.pending;if(j!==null){y.shared.pending=null;var A=j,V=A.next;A.next=null,C===null?x=V:C.next=V,C=A;var se=s.alternate;se!==null&&(se=se.updateQueue,j=se.lastBaseUpdate,j!==C&&(j===null?se.firstBaseUpdate=V:j.next=V,se.lastBaseUpdate=A))}if(x!==null){var ie=y.baseState;C=0,se=V=A=null,j=x;do{var ee=j.lane,ge=j.eventTime;if((h&ee)===ee){se!==null&&(se=se.next={eventTime:ge,lane:0,tag:j.tag,payload:j.payload,callback:j.callback,next:null});e:{var be=s,ke=j;switch(ee=o,ge=c,ke.tag){case 1:if(be=ke.payload,typeof be=="function"){ie=be.call(ge,ie,ee);break e}ie=be;break e;case 3:be.flags=be.flags&-65537|128;case 0:if(be=ke.payload,ee=typeof be=="function"?be.call(ge,ie,ee):be,ee==null)break e;ie=K({},ie,ee);break e;case 2:ls=!0}}j.callback!==null&&j.lane!==0&&(s.flags|=64,ee=y.effects,ee===null?y.effects=[j]:ee.push(j))}else ge={eventTime:ge,lane:ee,tag:j.tag,payload:j.payload,callback:j.callback,next:null},se===null?(V=se=ge,A=ie):se=se.next=ge,C|=ee;if(j=j.next,j===null){if(j=y.shared.pending,j===null)break;ee=j,j=ee.next,ee.next=null,y.lastBaseUpdate=ee,y.shared.pending=null}}while(!0);if(se===null&&(A=ie),y.baseState=A,y.firstBaseUpdate=V,y.lastBaseUpdate=se,o=y.shared.interleaved,o!==null){y=o;do C|=y.lane,y=y.next;while(y!==o)}else x===null&&(y.shared.lanes=0);Zs|=C,s.lanes=C,s.memoizedState=ie}}function Yg(s,o,c){if(s=o.effects,o.effects=null,s!==null)for(o=0;o<s.length;o++){var h=s[o],y=h.callback;if(y!==null){if(h.callback=null,h=c,typeof y!="function")throw Error(r(191,y));y.call(h)}}}var Sa={},gn=os(Sa),Ea=os(Sa),ka=os(Sa);function Js(s){if(s===Sa)throw Error(r(174));return s}function lf(s,o){switch(lt(ka,o),lt(Ea,s),lt(gn,Sa),s=o.nodeType,s){case 9:case 11:o=(o=o.documentElement)?o.namespaceURI:cn(null,"");break;default:s=s===8?o.parentNode:o,o=s.namespaceURI||null,s=s.tagName,o=cn(o,s)}ft(gn),lt(gn,o)}function ei(){ft(gn),ft(Ea),ft(ka)}function Jg(s){Js(ka.current);var o=Js(gn.current),c=cn(o,s.type);o!==c&&(lt(Ea,s),lt(gn,c))}function cf(s){Ea.current===s&&(ft(gn),ft(Ea))}var yt=os(0);function vc(s){for(var o=s;o!==null;){if(o.tag===13){var c=o.memoizedState;if(c!==null&&(c=c.dehydrated,c===null||c.data==="$?"||c.data==="$!"))return o}else if(o.tag===19&&o.memoizedProps.revealOrder!==void 0){if((o.flags&128)!==0)return o}else if(o.child!==null){o.child.return=o,o=o.child;continue}if(o===s)break;for(;o.sibling===null;){if(o.return===null||o.return===s)return null;o=o.return}o.sibling.return=o.return,o=o.sibling}return null}var uf=[];function df(){for(var s=0;s<uf.length;s++)uf[s]._workInProgressVersionPrimary=null;uf.length=0}var yc=P.ReactCurrentDispatcher,ff=P.ReactCurrentBatchConfig,Xs=0,wt=null,At=null,Mt=null,wc=!1,Ta=!1,Ca=0,$1=0;function Yt(){throw Error(r(321))}function hf(s,o){if(o===null)return!1;for(var c=0;c<o.length&&c<s.length;c++)if(!qr(s[c],o[c]))return!1;return!0}function pf(s,o,c,h,y,x){if(Xs=x,wt=o,o.memoizedState=null,o.updateQueue=null,o.lanes=0,yc.current=s===null||s.memoizedState===null?B1:q1,s=c(h,y),Ta){x=0;do{if(Ta=!1,Ca=0,25<=x)throw Error(r(301));x+=1,Mt=At=null,o.updateQueue=null,yc.current=V1,s=c(h,y)}while(Ta)}if(yc.current=_c,o=At!==null&&At.next!==null,Xs=0,Mt=At=wt=null,wc=!1,o)throw Error(r(300));return s}function mf(){var s=Ca!==0;return Ca=0,s}function vn(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Mt===null?wt.memoizedState=Mt=s:Mt=Mt.next=s,Mt}function Nr(){if(At===null){var s=wt.alternate;s=s!==null?s.memoizedState:null}else s=At.next;var o=Mt===null?wt.memoizedState:Mt.next;if(o!==null)Mt=o,At=s;else{if(s===null)throw Error(r(310));At=s,s={memoizedState:At.memoizedState,baseState:At.baseState,baseQueue:At.baseQueue,queue:At.queue,next:null},Mt===null?wt.memoizedState=Mt=s:Mt=Mt.next=s}return Mt}function Ra(s,o){return typeof o=="function"?o(s):o}function gf(s){var o=Nr(),c=o.queue;if(c===null)throw Error(r(311));c.lastRenderedReducer=s;var h=At,y=h.baseQueue,x=c.pending;if(x!==null){if(y!==null){var C=y.next;y.next=x.next,x.next=C}h.baseQueue=y=x,c.pending=null}if(y!==null){x=y.next,h=h.baseState;var j=C=null,A=null,V=x;do{var se=V.lane;if((Xs&se)===se)A!==null&&(A=A.next={lane:0,action:V.action,hasEagerState:V.hasEagerState,eagerState:V.eagerState,next:null}),h=V.hasEagerState?V.eagerState:s(h,V.action);else{var ie={lane:se,action:V.action,hasEagerState:V.hasEagerState,eagerState:V.eagerState,next:null};A===null?(j=A=ie,C=h):A=A.next=ie,wt.lanes|=se,Zs|=se}V=V.next}while(V!==null&&V!==x);A===null?C=h:A.next=j,qr(h,o.memoizedState)||(fr=!0),o.memoizedState=h,o.baseState=C,o.baseQueue=A,c.lastRenderedState=h}if(s=c.interleaved,s!==null){y=s;do x=y.lane,wt.lanes|=x,Zs|=x,y=y.next;while(y!==s)}else y===null&&(c.lanes=0);return[o.memoizedState,c.dispatch]}function vf(s){var o=Nr(),c=o.queue;if(c===null)throw Error(r(311));c.lastRenderedReducer=s;var h=c.dispatch,y=c.pending,x=o.memoizedState;if(y!==null){c.pending=null;var C=y=y.next;do x=s(x,C.action),C=C.next;while(C!==y);qr(x,o.memoizedState)||(fr=!0),o.memoizedState=x,o.baseQueue===null&&(o.baseState=x),c.lastRenderedState=x}return[x,h]}function Xg(){}function Zg(s,o){var c=wt,h=Nr(),y=o(),x=!qr(h.memoizedState,y);if(x&&(h.memoizedState=y,fr=!0),h=h.queue,yf(rv.bind(null,c,h,s),[s]),h.get
vendor: 4,386 bytes, line 39
39Snapshot!==o||x||Mt!==null&&Mt.memoizedState.tag&1){if(c.flags|=2048,Pa(9,tv.bind(null,c,h,y,o),void 0,null),$t===null)throw Error(r(349));(Xs&30)!==0||ev(c,o,y)}return y}function ev(s,o,c){s.flags|=16384,s={getSnapshot:o,value:c},o=wt.updateQueue,o===null?(o={lastEffect:null,stores:null},wt.updateQueue=o,o.stores=[s]):(c=o.stores,c===null?o.stores=[s]:c.push(s))}function tv(s,o,c,h){o.value=c,o.getSnapshot=h,nv(o)&&sv(s)}function rv(s,o,c){return c(function(){nv(o)&&sv(s)})}function nv(s){var o=s.getSnapshot;s=s.value;try{var c=o();return!qr(s,c)}catch{return!0}}function sv(s){var o=Dn(s,1);o!==null&&Gr(o,s,1,-1)}function ov(s){var o=vn();return typeof s=="function"&&(s=s()),o.memoizedState=o.baseState=s,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ra,lastRenderedState:s},o.queue=s,s=s.dispatch=z1.bind(null,wt,s),[o.memoizedState,s]}function Pa(s,o,c,h){return s={tag:s,create:o,destroy:c,deps:h,next:null},o=wt.updateQueue,o===null?(o={lastEffect:null,stores:null},wt.updateQueue=o,o.lastEffect=s.next=s):(c=o.lastEffect,c===null?o.lastEffect=s.next=s:(h=c.next,c.next=s,s.next=h,o.lastEffect=s)),s}function iv(){return Nr().memoizedState}function bc(s,o,c,h){var y=vn();wt.flags|=s,y.memoizedState=Pa(1|o,c,void 0,h===void 0?null:h)}function xc(s,o,c,h){var y=Nr();h=h===void 0?null:h;var x=void 0;if(At!==null){var C=At.memoizedState;if(x=C.destroy,h!==null&&hf(h,C.deps)){y.memoizedState=Pa(o,c,x,h);return}}wt.flags|=s,y.memoizedState=Pa(1|o,c,x,h)}function av(s,o){return bc(8390656,8,s,o)}function yf(s,o){return xc(2048,8,s,o)}function lv(s,o){return xc(4,2,s,o)}function cv(s,o){return xc(4,4,s,o)}function uv(s,o){if(typeof o=="function")return s=s(),o(s),function(){o(null)};if(o!=null)return s=s(),o.current=s,function(){o.current=null}}function dv(s,o,c){return c=c!=null?c.concat([s]):null,xc(4,4,uv.bind(null,o,s),c)}function wf(){}function fv(s,o){var c=Nr();o=o===void 0?null:o;var h=c.memoizedState;return h!==null&&o!==null&&hf(o,h[1])?h[0]:(c.memoizedState=[s,o],s)}function hv(s,o){var c=Nr();o=o===void 0?null:o;var h=c.memoizedState;return h!==null&&o!==null&&hf(o,h[1])?h[0]:(s=s(),c.memoizedState=[s,o],s)}function pv(s,o,c){return(Xs&21)===0?(s.baseState&&(s.baseState=!1,fr=!0),s.memoizedState=c):(qr(c,o)||(c=Vm(),wt.lanes|=c,Zs|=c,s.baseState=!0),o)}function F1(s,o){var c=it;it=c!==0&&4>c?c:4,s(!0);var h=ff.transition;ff.transition={};try{s(!1),o()}finally{it=c,ff.transition=h}}function mv(){return Nr().memoizedState}function U1(s,o,c){var h=hs(s);if(c={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null},gv(s))vv(o,c);else if(c=Kg(s,o,c,h),c!==null){var y=sr();Gr(c,s,h,y),yv(c,o,h)}}function z1(s,o,c){var h=hs(s),y={lane:h,action:c,hasEagerState:!1,eagerState:null,next:null};if(gv(s))vv(o,y);else{var x=s.alternate;if(s.lanes===0&&(x===null||x.lanes===0)&&(x=o.lastRenderedReducer,x!==null))try{var C=o.lastRenderedState,j=x(C,c);if(y.hasEagerState=!0,y.eagerState=j,qr(j,C)){var A=o.interleaved;A===null?(y.next=y,of(o)):(y.next=A.next,A.next=y),o.interleaved=y;return}}catch{}finally{}c=Kg(s,o,y,h),c!==null&&(y=sr(),Gr(c,s,h,y),yv(c,o,h))}}function gv(s){var o=s.alternate;return s===wt||o!==null&&o===wt}function vv(s,o){Ta=wc=!0;var c=s.pending;c===null?o.next=o:(o.next=c.next,c.next=o),s.pending=o}function yv(s,o,c){if((c&4194240)!==0){var h=o.lanes;h&=s.pendingLanes,c|=h,o.lanes=c,bd(s,c)}}var _c={readContext:Ar,useCallback:Yt,useContext:Yt,useEffect:Yt,useImperativeHandle:Yt,useInsertionEffect:Yt,useLayoutEffect:Yt,useMemo:Yt,useReducer:Yt,useRef:Yt,useState:Yt,useDebugValue:Yt,useDeferredValue:Yt,useTransition:Yt,useMutableSource:Yt,useSyncExternalStore:Yt,useId:Yt,unstable_isNewReconciler:!1},B1={readContext:Ar,useCallback:function(s,o){return vn().memoizedState=[s,o===void 0?null:o],s},useContext:Ar,useEffect:av,useImperativeHandle:function(s,o,c){return c=c!=null?c.concat([s]):null,bc(4194308,4,uv.bind(null,o,s),c)},useLayoutEffect:function(s,o){return bc(4194308,4,s,o)},useInsertionEffect:function(s,o){return bc(4,2,s,o)},useMemo:function(s,o){var c=vn();return o=o===void 0?null:o,s=s(),c.memoizedState=[s,o],s},useReducer:function(s,o,c){var h=vn();return o=c!==void 0?c(o):o,h.memoizedState=h.baseState=o,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:o},h.queue=s,s=s.dispatch=U1.bind(null,wt,s),[h.memoizedState,s]}
vendor: 7,454 bytes, lines 39-41
39,useRef:function(s){var o=vn();return s={current:s},o.memoizedState=s},useState:ov,useDebugValue:wf,useDeferredValue:function(s){return vn().memoizedState=s},useTransition:function(){var s=ov(!1),o=s[0];return s=F1.bind(null,s[1]),vn().memoizedState=s,[o,s]},useMutableSource:function(){},useSyncExternalStore:function(s,o,c){var h=wt,y=vn();if(pt){if(c===void 0)throw Error(r(407));c=c()}else{if(c=o(),$t===null)throw Error(r(349));(Xs&30)!==0||ev(h,o,c)}y.memoizedState=c;var x={value:c,getSnapshot:o};return y.queue=x,av(rv.bind(null,h,x,s),[s]),h.flags|=2048,Pa(9,tv.bind(null,h,x,c,o),void 0,null),c},useId:function(){var s=vn(),o=$t.identifierPrefix;if(pt){var c=Ln,h=In;c=(h&~(1<<32-Br(h)-1)).toString(32)+c,o=":"+o+"R"+c,c=Ca++,0<c&&(o+="H"+c.toString(32)),o+=":"}else c=$1++,o=":"+o+"r"+c.toString(32)+":";return s.memoizedState=o},unstable_isNewReconciler:!1},q1={readContext:Ar,useCallback:fv,useContext:Ar,useEffect:yf,useImperativeHandle:dv,useInsertionEffect:lv,useLayoutEffect:cv,useMemo:hv,useReducer:gf,useRef:iv,useState:function(){return gf(Ra)},useDebugValue:wf,useDeferredValue:function(s){var o=Nr();return pv(o,At.memoizedState,s)},useTransition:function(){var s=gf(Ra)[0],o=Nr().memoizedState;return[s,o]},useMutableSource:Xg,useSyncExternalStore:Zg,useId:mv,unstable_isNewReconciler:!1},V1={readContext:Ar,useCallback:fv,useContext:Ar,useEffect:yf,useImperativeHandle:dv,useInsertionEffect:lv,useLayoutEffect:cv,useMemo:hv,useReducer:vf,useRef:iv,useState:function(){return vf(Ra)},useDebugValue:wf,useDeferredValue:function(s){var o=Nr();return At===null?o.memoizedState=s:pv(o,At.memoizedState,s)},useTransition:function(){var s=vf(Ra)[0],o=Nr().memoizedState;return[s,o]},useMutableSource:Xg,useSyncExternalStore:Zg,useId:mv,unstable_isNewReconciler:!1};function Wr(s,o){if(s&&s.defaultProps){o=K({},o),s=s.defaultProps;for(var c in s)o[c]===void 0&&(o[c]=s[c]);return o}return o}function bf(s,o,c,h){o=s.memoizedState,c=c(h,o),c=c==null?o:K({},o,c),s.memoizedState=c,s.lanes===0&&(s.updateQueue.baseState=c)}var Sc={isMounted:function(s){return(s=s._reactInternals)?Ws(s)===s:!1},enqueueSetState:function(s,o,c){s=s._reactInternals;var h=sr(),y=hs(s),x=Mn(h,y);x.payload=o,c!=null&&(x.callback=c),o=cs(s,x,y),o!==null&&(Gr(o,s,y,h),mc(o,s,y))},enqueueReplaceState:function(s,o,c){s=s._reactInternals;var h=sr(),y=hs(s),x=Mn(h,y);x.tag=1,x.payload=o,c!=null&&(x.callback=c),o=cs(s,x,y),o!==null&&(Gr(o,s,y,h),mc(o,s,y))},enqueueForceUpdate:function(s,o){s=s._reactInternals;var c=sr(),h=hs(s),y=Mn(c,h);y.tag=2,o!=null&&(y.callback=o),o=cs(s,y,h),o!==null&&(Gr(o,s,h,c),mc(o,s,h))}};function wv(s,o,c,h,y,x,C){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(h,x,C):o.prototype&&o.prototype.isPureReactComponent?!ma(c,h)||!ma(y,x):!0}function bv(s,o,c){var h=!1,y=is,x=o.contextType;return typeof x=="object"&&x!==null?x=Ar(x):(y=dr(o)?Ks:Qt.current,h=o.contextTypes,x=(h=h!=null)?Ko(s,y):is),o=new o(c,x),s.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,o.updater=Sc,s.stateNode=o,o._reactInternals=s,h&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=y,s.__reactInternalMemoizedMaskedChildContext=x),o}function xv(s,o,c,h){s=o.state,typeof o.componentWillReceiveProps=="function"&&o.componentWillReceiveProps(c,h),typeof o.UNSAFE_componentWillReceiveProps=="function"&&o.UNSAFE_componentWillReceiveProps(c,h),o.state!==s&&Sc.enqueueReplaceState(o,o.state,null)}function xf(s,o,c,h){var y=s.stateNode;y.props=c,y.state=s.memoizedState,y.refs={},af(s);var x=o.contextType;typeof x=="object"&&x!==null?y.context=Ar(x):(x=dr(o)?Ks:Qt.current,y.context=Ko(s,x)),y.state=s.memoizedState,x=o.getDerivedStateFromProps,typeof x=="function"&&(bf(s,o,x,c),y.state=s.memoizedState),typeof o.getDerivedStateFromProps=="function"||typeof y.getSnapshotBeforeUpdate=="function"||typeof y.UNSAFE_componentWillMount!="function"&&typeof y.componentWillMount!="function"||(o=y.state,typeof y.componentWillMount=="function"&&y.componentWillMount(),typeof y.UNSAFE_componentWillMount=="function"&&y.UNSAFE_componentWillMount(),o!==y.state&&Sc.enqueueReplaceState(y,y.state,null),gc(s,c,y,h),y.state=s.memoizedState),typeof y.componentDidMount=="function"&&(s.flags|=4194308)}function ti(s,o){try{var c="",h=o;do c+=Oe(h),h=h.return;while(h);var y=c}catch(x){y=`
40Error generating stack: `+x.message+`
41`+x.stack}return{value:s,source:o,stack:y,digest:null}}function _f(s,o,c){return{value:s,source:null,stack:c??null,digest:o??null}}function Sf(s,o){try{console.error(o.value)}catch(c){setTimeout(function(){throw c})}}var W1=typeof WeakMap=="function"?WeakMap:Map;function _v(s,o,c){c=Mn(-1,c),c.tag=3,c.payload={element:null};var h=o.value;return c.callback=function(){jc||(jc=!0,$f=h),Sf(s,o)},c}function Sv(s,o,c){c=Mn(-1,c),c.tag=3;var h=s.type.getDerivedStateFromError;if(typeof h=="function"){var y=o.value;c.payload=function(){return h(y)},c.callback=function(){Sf(s,o)}}var x=s.stateNode;return x!==null&&typeof x.componentDidCatch=="function"&&(c.callback=function(){Sf(s,o),typeof h!="function"&&(ds===null?ds=new Set([this]):ds.add(this));var C=o.stack;this.componentDidCatch(o.value,{componentStack:C!==null?C:""})}),c}function Ev(s,o,c){var h=s.pingCache;if(h===null){h=s.pingCache=new W1;var y=new Set;h.set(o,y)}else y=h.get(o),y===void 0&&(y=new Set,h.set(o,y));y.has(c)||(y.add(c),s=ok.bind(null,s,o,c),o.then(s,s))}function kv(s){do{var o;if((o=s.tag===13)&&(o=s.memoizedState,o=o!==null?o.dehydrated!==null:!0),o)return s;s=s.return}while(s!==null);return null}function Tv(s,o,c,h,y){return(s.mode&1)===0?(s===o?s.flags|=65536:(s.flags|=128,c.flags|=131072,c.flags&=-52805,c.tag===1&&(c.alternate===null?c.tag=17:(o=Mn(-1,1),o.tag=2,cs(c,o,1))),c.lanes|=1),s):(s.flags|=65536,s.lanes=y,s)}var H1=P.ReactCurrentOwner,fr=!1;function nr(s,o,c,h){o.child=s===null?Hg(o,null,c,h):Jo(o,s.child,c,h)}function Cv(s,o,c,h,y){c=c.render;var x=o.ref;return Zo(o,y),h=pf(s,o,c,h,x,y),c=mf(),s!==null&&!fr?(o.updateQueue=s.updateQueue,o.flags&=-2053,s.lanes&=~y,$n(s,o,y)):(pt&&c&&Yd(o),o.flags|=1,nr(s,o,h,y),o.child)}function Rv(s,o,c,h,y){if(s===null){var x=c.type;return typeof x=="function"&&!Wf(x)&&x.defaultProps===void 0&&c.compare===null&&c.defaultProps===void 0?(o.tag=15,o.type=x,Pv(s,o,x,h,y)):(s=Dc(c.type,null,h,o,o.mode,y),s.ref=o.ref,s.return=o,o.child=s)}if(x=s.child,(s.lanes&y)===0){var C=x.memoizedProps;if(c=c.compare,c=c!==null?c:ma,c(C,h)&&s.ref===o.ref)return $n(s,o,y)}return o.flags|=1,s=ms(x,h),s.ref=o.ref,s.return=o,o.child=s}function Pv(s,o,c,h,y){if(s!==null){var x=s.memoizedProps;if(ma(x,h)&&s.ref===o.ref)if(fr=!1,o.pendingProps=h=x,(s.lanes&y)!==0)(s.flags&131072)!==0&&(fr=!0);else return o.lanes=s.lanes,$n(s,o,y)}return Ef(s,o,c,h,y)}function jv(s,o,c){var h=o.pendingProps,y=h.children,x=s!==null?s.memoizedState:null;if(h.mode==="hidden")if((o.mode&1)===0)o.memoizedState={baseLanes:0,cachePool:null,transitions:null},lt(ni,Er),Er|=c;else{if((c&1073741824)===0)return s=x!==null?x.baseLanes|c:c,o.lanes=o.childLanes=1073741824,o.memoizedState={baseLanes:s,cachePool:null,transitions:null},o.updateQueue=null,lt(ni,Er),Er|=s,null;o.memoizedState={baseLanes:0,cachePool:null,transitions:null},h=x!==null?x.baseLanes:c,lt(ni,Er),Er|=h}else x!==null?(h=x.baseLanes|c,o.memoizedState=null):h=c,lt(ni,Er),Er|=h;return nr(s,o,y,c),o.child}function Ov(s,o){var c=o.ref;(s===null&&c!==null||s!==null&&s.ref!==c)&&(o.flags|=512,o.flags|=2097152)}
vendor: 13,728 bytes, line 41
41function Ef(s,o,c,h,y){var x=dr(c)?Ks:Qt.current;return x=Ko(o,x),Zo(o,y),c=pf(s,o,c,h,x,y),h=mf(),s!==null&&!fr?(o.updateQueue=s.updateQueue,o.flags&=-2053,s.lanes&=~y,$n(s,o,y)):(pt&&h&&Yd(o),o.flags|=1,nr(s,o,c,y),o.child)}function Av(s,o,c,h,y){if(dr(c)){var x=!0;ac(o)}else x=!1;if(Zo(o,y),o.stateNode===null)kc(s,o),bv(o,c,h),xf(o,c,h,y),h=!0;else if(s===null){var C=o.stateNode,j=o.memoizedProps;C.props=j;var A=C.context,V=c.contextType;typeof V=="object"&&V!==null?V=Ar(V):(V=dr(c)?Ks:Qt.current,V=Ko(o,V));var se=c.getDerivedStateFromProps,ie=typeof se=="function"||typeof C.getSnapshotBeforeUpdate=="function";ie||typeof C.UNSAFE_componentWillReceiveProps!="function"&&typeof C.componentWillReceiveProps!="function"||(j!==h||A!==V)&&xv(o,C,h,V),ls=!1;var ee=o.memoizedState;C.state=ee,gc(o,h,C,y),A=o.memoizedState,j!==h||ee!==A||ur.current||ls?(typeof se=="function"&&(bf(o,c,se,h),A=o.memoizedState),(j=ls||wv(o,c,j,h,ee,A,V))?(ie||typeof C.UNSAFE_componentWillMount!="function"&&typeof C.componentWillMount!="function"||(typeof C.componentWillMount=="function"&&C.componentWillMount(),typeof C.UNSAFE_componentWillMount=="function"&&C.UNSAFE_componentWillMount()),typeof C.componentDidMount=="function"&&(o.flags|=4194308)):(typeof C.componentDidMount=="function"&&(o.flags|=4194308),o.memoizedProps=h,o.memoizedState=A),C.props=h,C.state=A,C.context=V,h=j):(typeof C.componentDidMount=="function"&&(o.flags|=4194308),h=!1)}else{C=o.stateNode,Gg(s,o),j=o.memoizedProps,V=o.type===o.elementType?j:Wr(o.type,j),C.props=V,ie=o.pendingProps,ee=C.context,A=c.contextType,typeof A=="object"&&A!==null?A=Ar(A):(A=dr(c)?Ks:Qt.current,A=Ko(o,A));var ge=c.getDerivedStateFromProps;(se=typeof ge=="function"||typeof C.getSnapshotBeforeUpdate=="function")||typeof C.UNSAFE_componentWillReceiveProps!="function"&&typeof C.componentWillReceiveProps!="function"||(j!==ie||ee!==A)&&xv(o,C,h,A),ls=!1,ee=o.memoizedState,C.state=ee,gc(o,h,C,y);var be=o.memoizedState;j!==ie||ee!==be||ur.current||ls?(typeof ge=="function"&&(bf(o,c,ge,h),be=o.memoizedState),(V=ls||wv(o,c,V,h,ee,be,A)||!1)?(se||typeof C.UNSAFE_componentWillUpdate!="function"&&typeof C.componentWillUpdate!="function"||(typeof C.componentWillUpdate=="function"&&C.componentWillUpdate(h,be,A),typeof C.UNSAFE_componentWillUpdate=="function"&&C.UNSAFE_componentWillUpdate(h,be,A)),typeof C.componentDidUpdate=="function"&&(o.flags|=4),typeof C.getSnapshotBeforeUpdate=="function"&&(o.flags|=1024)):(typeof C.componentDidUpdate!="function"||j===s.memoizedProps&&ee===s.memoizedState||(o.flags|=4),typeof C.getSnapshotBeforeUpdate!="function"||j===s.memoizedProps&&ee===s.memoizedState||(o.flags|=1024),o.memoizedProps=h,o.memoizedState=be),C.props=h,C.state=be,C.context=A,h=V):(typeof C.componentDidUpdate!="function"||j===s.memoizedProps&&ee===s.memoizedState||(o.flags|=4),typeof C.getSnapshotBeforeUpdate!="function"||j===s.memoizedProps&&ee===s.memoizedState||(o.flags|=1024),h=!1)}return kf(s,o,c,h,x,y)}function kf(s,o,c,h,y,x){Ov(s,o);var C=(o.flags&128)!==0;if(!h&&!C)return y&&Mg(o,c,!1),$n(s,o,x);h=o.stateNode,H1.current=o;var j=C&&typeof c.getDerivedStateFromError!="function"?null:h.render();return o.flags|=1,s!==null&&C?(o.child=Jo(o,s.child,null,x),o.child=Jo(o,null,j,x)):nr(s,o,j,x),o.memoizedState=h.state,y&&Mg(o,c,!0),o.child}function Nv(s){var o=s.stateNode;o.pendingContext?Lg(s,o.pendingContext,o.pendingContext!==o.context):o.context&&Lg(s,o.context,!1),lf(s,o.containerInfo)}function Iv(s,o,c,h,y){return Yo(),ef(y),o.flags|=256,nr(s,o,c,h),o.child}var Tf={dehydrated:null,treeContext:null,retryLane:0};function Cf(s){return{baseLanes:s,cachePool:null,transitions:null}}function Lv(s,o,c){var h=o.pendingProps,y=yt.current,x=!1,C=(o.flags&128)!==0,j;if((j=C)||(j=s!==null&&s.memoizedState===null?!1:(y&2)!==0),j?(x=!0,o.flags&=-129):(s===null||s.memoizedState!==null)&&(y|=1),lt(yt,y&1),s===null)return Zd(o),s=o.memoizedState,s!==null&&(s=s.dehydrated,s!==null)?((o.mode&1)===0?o.lanes=1:s.data==="$!"?o.lanes=8:o.lanes=1073741824,null):(C=h.children,s=h.fallback,x?(h=o.mode,x=o.child,C={mode:"hidden",children:C},(h&1)===0&&x!==null?(x.childLanes=0,x.pendingProps=C):x=Mc(C,h,0,null),s=no(s,h,c,null),x.return=o,s.return=o,x.sibling=s,o.child=x,o.child.memoizedState=Cf(c),o.memoizedState=Tf,s):Rf(o,C));if(y=s.memoizedState,y!==null&&(j=y.dehydrated,j!==null))return K1(s,o,C,h,j,y,c);if(x){x=h.fallback,C=o.mode,y=s.child,j=y.sibling;var A={mode:"hidden",children:h.children};return(C&1)===0&&o.child!==y?(h=o.child,h.childLanes=0,h.pendingProps=A,o.deletions=null):(h=ms(y,A),h.subtreeFlags=y.subtreeFlags&14680064),j!==null?x=ms(j,x):(x=no(x,C,c,null),x.flags|=2),x.return=o,h.return=o,h.sibling=x,o.child=h,h=x,x=o.child,C=s.child.memoizedState,C=C===null?Cf(c):{baseLanes:C.baseLanes|c,cachePool:null,transitions:C.transitions},x.memoizedState=C,x.childLanes=s.childLanes&~c,o.memoizedState=Tf,h}return x=s.child,s=x.sibling,h=ms(x,{mode:"visible",children:h.children}),(o.mode&1)===0&&(h.lanes=c),h.return=o,h.sibling=null,s!==null&&(c=o.deletions,c===null?(o.deletions=[s],o.flags|=16):c.push(s)),o.child=h,o.memoizedState=null,h}function Rf(s,o){return o=Mc({mode:"visible",children:o},s.mode,0,null),o.return=s,s.child=o}function Ec(s,o,c,h){return h!==null&&ef(h),Jo(o,s.child,null,c),s=Rf(o,o.pendingProps.children),s.flags|=2,o.memoizedState=null,s}function K1(s,o,c,h,y,x,C){if(c)return o.flags&256?(o.flags&=-257,h=_f(Error(r(422))),Ec(s,o,C,h)):o.memoizedState!==null?(o.child=s.child,o.flags|=128,null):(x=h.fallback,y=o.mode,h=Mc({mode:"visible",children:h.children},y,0,null),x=no(x,y,C,null),x.flags|=2,h.return=o,x.return=o,h.sibling=x,o.child=h,(o.mode&1)!==0&&Jo(o,s.child,null,C),o.child.memoizedState=Cf(C),o.memoizedState=Tf,x);if((o.mode&1)===0)return Ec(s,o,C,null);if(y.data==="$!"){if(h=y.nextSibling&&y.nextSibling.dataset,h)var j=h.dgst;return h=j,x=Error(r(419)),h=_f(x,h,void 0),Ec(s,o,C,h)}if(j=(C&s.childLanes)!==0,fr||j){if(h=$t,h!==null){switch(C&-C){case 4:y=2;break;case 16:y=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:y=32;break;case 536870912:y=268435456;break;default:y=0}y=(y&(h.suspendedLanes|C))!==0?0:y,y!==0&&y!==x.retryLane&&(x.retryLane=y,Dn(s,y),Gr(h,s,y,-1))}return Vf(),h=_f(Error(r(421))),Ec(s,o,C,h)}return y.data==="$?"?(o.flags|=128,o.child=s.child,o=ik.bind(null,s),y._reactRetry=o,null):(s=x.treeContext,Sr=ss(y.nextSibling),_r=o,pt=!0,Vr=null,s!==null&&(jr[Or++]=In,jr[Or++]=Ln,jr[Or++]=Gs,In=s.id,Ln=s.overflow,Gs=o),o=Rf(o,h.children),o.flags|=4096,o)}function Dv(s,o,c){s.lanes|=o;var h=s.alternate;h!==null&&(h.lanes|=o),sf(s.return,o,c)}function Pf(s,o,c,h,y){var x=s.memoizedState;x===null?s.memoizedState={isBackwards:o,rendering:null,renderingStartTime:0,last:h,tail:c,tailMode:y}:(x.isBackwards=o,x.rendering=null,x.renderingStartTime=0,x.last=h,x.tail=c,x.tailMode=y)}function Mv(s,o,c){var h=o.pendingProps,y=h.revealOrder,x=h.tail;if(nr(s,o,h.children,c),h=yt.current,(h&2)!==0)h=h&1|2,o.flags|=128;else{if(s!==null&&(s.flags&128)!==0)e:for(s=o.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&Dv(s,c,o);else if(s.tag===19)Dv(s,c,o);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===o)break e;for(;s.sibling===null;){if(s.return===null||s.return===o)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}h&=1}if(lt(yt,h),(o.mode&1)===0)o.memoizedState=null;else switch(y){case"forwards":for(c=o.child,y=null;c!==null;)s=c.alternate,s!==null&&vc(s)===null&&(y=c),c=c.sibling;c=y,c===null?(y=o.child,o.child=null):(y=c.sibling,c.sibling=null),Pf(o,!1,y,c,x);break;case"backwards":for(c=null,y=o.child,o.child=null;y!==null;){if(s=y.alternate,s!==null&&vc(s)===null){o.child=y;break}s=y.sibling,y.sibling=c,c=y,y=s}Pf(o,!0,c,null,x);break;case"together":Pf(o,!1,null,null,void 0);break;default:o.memoizedState=null}return o.child}function kc(s,o){(o.mode&1)===0&&s!==null&&(s.alternate=null,o.alternate=null,o.flags|=2)}function $n(s,o,c){if(s!==null&&(o.dependencies=s.dependencies),Zs|=o.lanes,(c&o.childLanes)===0)return null;if(s!==null&&o.child!==s.child)throw Error(r(153));if(o.child!==null){for(s=o.child,c=ms(s,s.pendingProps),o.child=c,c.return=o;s.sibling!==null;)s=s.sibling,c=c.sibling=ms(s,s.pendingProps),c.return=o;c.sibling=null}return o.child}function G1(s,o,c){switch(o.tag){case 3:Nv(o),Yo();break;case 5:Jg(o);break;case 1:dr(o.type)&&ac(o);break;case 4:lf(o,o.stateNode.containerInfo);break;case 10:var h=o.type._context,y=o.memoizedProps.value;lt(hc,h._currentValue),h._currentValue=y;break;case 13:if(h=o.memoizedState,h!==null)return h.dehydrated!==null?(lt(yt,yt.current&1),o.flags|=128,null):(c&o.child.childLanes)!==0?Lv(s,o,c):(lt(yt,yt.current&1),s=$n(s,o,c),s!==null?s.sibling:null);lt(yt,yt.current&1);break;case 19:if(h=(c&o.childLanes)!==0,(s.flags&128)!==0){if(h)return Mv(s,o,c);o.flags|=128}if(y=o.memoizedState,y!==null&&(y.rendering=null,y.tail=null,y.lastEffect=null),lt(yt,yt.current),h)break;return null;case 22:case 23:return o.lanes=0,jv(s,o,c)}return $n(s,o,c)}var $v,jf,Fv,Uv;$v=function(s,o){for(var c=o.child;c!==null;){if(c.tag===5||c.tag===6)s.appendChild(c.stateNode);else if(c.tag!==4&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===o)break;for(;c.sibling===null;){if(c.return===null||c.return===o)return;c=c.return}c.sibling.return=c.return,c=c.sibling}},jf=function(){},Fv=function(s,o,c,h){var y=s.memoizedProps;if(y!==h){s=o.stateNode,Js(gn.current);var x=null;switch(c){case"input":y=pe(s,y),h=pe(s,h),x=[];break;case"select":y=K({},y,{value:void 0}),h=K({},h,{value:void 0}),x=[];break;case"textarea":y=_t(s,y),h=_t(s,h),x=[];break;default:typeof y.onClick!="function"&&typeof h.onClick=="function"&&(s.onclick=sc)}dn(c,h);var C;c=null;for(V in y)if(!h.hasOwnProperty(V)&&y.hasOwnProperty(V)&&y[V]!=null)if(V==="style"){var j=y[V];for(C in j)j.hasOwnProperty(C)&&(c||(c={}),c[C]="")}else V!=="dangerouslySetInnerHTML"&&V!=="children"&&V!=="suppressContentEditableWarning"&&V!=="suppressHydrationWarning"&&V!=="autoFocus"&&(i.hasOwnProperty(V)?x||(x=[]):(x=x||[]).push(V,null));for(V in h){var A=h[V];if(j=y!=null?y[V]:void 0,h.hasOwnProperty(V)&&A!==j&&(A!=null||j!=null))if(V==="style")if(j){for(C in j)!j.hasOwnProperty(C)||A&&A.hasOwnProperty(C)||(c||(c={}),c[C]="");for(C in A)A.hasOwnProperty(C)&&j[C]!==A[C]&&(c||(c={}),c[C]=A[C])}else c||(x||(x=[]),x.push(V,c)),c=A;else V==="dangerouslySetInnerHTML"?(A=A?A.__html:void 0,j=j?j.__html:void 0,A!=null&&j!==A&&(x=x||[]).push(V,A)):V==="children"?typeof A!="string"&&typeof A!="number"||(x=x||[]).push(V,""+A):V!=="suppressContentEditableWarning"&&V!=="suppressHydrationWarning"&&(i.hasOwnProperty(V)?(A!=null&&V==="onScroll"&&dt("scroll",s),x||j===A||(x=[])):(x=x||[]).push(V,A))}c&&(x=x||[]).push("style",c);var V=x;(o.updateQueue=V)&&(o.flags|=4)}},Uv=function(s,o,c,h){c!==h&&(o.flags|=4)};function ja(s,o){if(!pt)switch(s.tailMode){case"hidden":o=s.tail;for(var c=null;o!==null;)o.alternate!==null&&(c=o),o=o.sibling;c===null?s.tail=null:c.sibling=null;break;case"collapsed":c=s.tail;for(var h=null;c!==null;)c.alternate!==null&&(h=c),c=c.sibling;h===null?o||s.tail===null?s.tail=null:s.tail.sibling=null:h.sibling=null}}function Jt(s){var o=s.alternate!==null&&s.alternate.child===s.child,c=0,h=0;if(o)for(var y=s.child;y!==null;)c|=y.lanes|y.childLanes,h|=y.subtreeFlags&14680064,h|=y.flags&14680064,y.return=s,y=y.sibling;else for(y=s.child;y!==null;)c|=y.lanes|y.childLanes,h|=y.subtreeFlags,h|=y.flags,y.return=s,y=y.sibling;return s.subtreeFlags|=h,s.childLanes=c,o}function Q1(s,o,c){var h=o.pendingProps;switch(Jd(o),o.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Jt(o),null;case 1:return dr(o.type)&&ic(),Jt(o),null;case 3:return h=o.stateNode,ei(),ft(ur),ft(Qt),df(),h.pendingContext&&(h.context=h.pendingContext,h.pendingContext=null),(s===null||s.child===null)&&(dc(o)?o.flags|=4:s===null||s.memoizedState.isDehydrated&&(o.flags&256)===0||(o.flags|=1024,Vr!==null&&(zf(Vr),Vr=null))),jf(s,o),Jt(o),null;case 5:cf(o);var y=Js(ka.current);if(c=o.type,s!==null&&o.stateNode!=null)Fv(s,o,c,h,y),s.ref!==o.ref&&(o.flags|=512,o.flags|=2097152);else{if(!h){if(o.stateNode===null)throw Error(r(166));return Jt(o),null}if(s=Js(gn.current),dc(o)){h=o.stateNode,c=o.type;var x=o.memoizedProps;switch(h[mn]=o,h[ba]=x,s=(o.mode&1)!==0,c){case"dialog":dt("cancel",h),dt("close",h);break;case"iframe":case"object":case"embed":dt("load",h);break;case"video":case"audio":for(y=0;y<va.length;y++)dt(va[y],h);break;case"source":dt("error",h);break;case"img":case"image":case"link":dt("error",h),dt("load",h);break;case"details":dt("toggle",h);break;case"input":ne(h,x),dt("invalid",h);break;case"select":h._wrapperState={wasMultiple:!!x.multiple},dt("invalid",h);break;case"textarea":br(h,x),dt("invalid",h)}dn(c,x),y=null;for(var C in x)if(x.hasOwnProperty(C)){var j=x[C];C==="children"?typeof j=="string"?h.textContent!==j&&(x.suppressHydrationWarning!==!0&&nc(h.textContent,j,s),y=["children",j]):typeof j=="number"&&h.textContent!==""+j&&(x.suppressHydrationWarning!==!0&&nc(h.textContent,j,s),y=["children",""+j]):i.hasOwnProperty(C)&&j!=null&&C==="onScroll"&&dt("scroll",h)}switch(c){case"input":oe(h),vt(h,x,!0);break;case"textarea":oe(h),Al(h);break;case"select":case"option":break;default:typeof x.onClick=="function"&&(h.onclick=sc)}h=y,o.updateQueue=h,h!==null&&(o.flags|=4)}else{C=y.nodeType===9?y:y.ownerDocument,s==="http://www.w3.org/1999/xhtml"&&(s=tr(c)),s==="http://www.w3.org/1999/xhtml"?c==="script"?(s=C.createElement("div"),s.innerHTML="<script><\/script>
41",s=s.removeChild(s.firstChild)):typeof h.is=="string"?s=C.createElement(c,{is:h.is}):(s=C.createElement(c),c==="select"&&(C=s,h.multiple?C.multiple=!0:h.size&&(C.size=h.size))):s=C.createElementNS(s,c),s[mn]=o,s[ba]=h,$v(s,o,!1,!1),o.stateNode=s;e:{switch(C=ea(c,h),c){case"dialog":dt("cancel",s),dt("close",s),y=h;break;case"iframe":case"object":case"embed":dt("load",s),y=h;break;case"video":case"audio":for(y=0;y<va.length;y++)dt(va[y],s);y=h;break;case"source":dt("error",s),y=h;break;case"img":case"image":case"link":dt("error",s),dt("load",s),y=h;break;case"details":dt("toggle",s),y=h;break;case"input":ne(s,h),y=pe(s,h),dt("invalid",s);break;case"option":y=h;break;case"select":s._wrapperState={wasMultiple:!!h.multiple},y=K({},h,{value:void 0}),dt("invalid",s);break;case"textarea":br(s,h),y=_t(s,h),dt("invalid",s);break;default:y=h}dn(c,y),j=y;for(x in j)if(j.hasOwnProperty(x)){var A=j[x];x==="style"?On(s,A):x==="dangerouslySetInnerHTML"?(A=A?A.__html:void 0,A!=null&&Nl(s,A)):x==="children"?typeof A=="string"?(c!=="textarea"||A!=="")&&un(s,A):typeof A=="number"&&un(s,""+A):x!=="suppressContentEditableWarning"&&x!=="suppressHydrationWarning"&&x!=="autoFocus"&&(i.hasOwnProperty(x)?A!=null&&x==="onScroll"&&dt("scroll",s):A!=null&&R(s,x,A,C))}switch(c){case"input":oe(s),vt(s,h,!1);break;case"textarea":oe(s),Al(s);break;case"option":h.value!=null&&s.setAttribute("value",""+Ve(h.value));break;case"select":s.multiple=!!h.multiple,x=h.value,x!=null?Dt(s,!!h.multiple,x,!1):h.defaultValue!=null&&Dt(s,!!h.multiple,h.defaultValue,!0);break;default:typeof y.onClick=="function"&&(s.onclick=sc)}switch(c){case"button":case"input":case"select":case"textarea":h=!!h.autoFocus;break e;case"img":h=!0;break e;default:h=!1}}h&&(o.flags|=4)}o.ref!==null&&(o.flags|=512,o.flags|=2097152)}return Jt(o),null;case 6:if(s&&o.stateNode!=null)Uv(s,o,s.memoizedProps,h);else{if(typeof h!="string"&&o.stateNode===null)throw Error(r(166));if(c=Js(ka.current),Js(gn.current),dc(o)){if(h=o.stateNode,c=o.memoizedProps,h[mn]=o,(x=h.nodeValue!==c)&&(s=_r,s!==null))switch(s.tag){case 3:nc(h.nodeValue,c,(s.mode&1)!==0);break;case 5:s.memoizedProps.suppressHydrationWarning!==!0&&nc(h.nodeValue,c,(s.mode&1)!==0)}x&&(o.flags|=4)}else h=(c.nodeType===9?c:c.ownerDocument).createTextNode(h),h[mn]=o,o.stateNode=h}return Jt(o),null;case 13:if(ft(yt),h=o.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(pt&&Sr!==null&&(o.mode&1)!==0&&(o.flags&128)===0)qg(),Yo(),o.flags|=98560,x=!1;else if(x=dc(o),h!==null&&h.dehydrated!==null){if(s===null){if(!x)throw Error(r(318));if(x=o.memoizedState,x=x!==null?x.dehydrated:null,!x)throw Error(r(317));x[mn]=o}else Yo(),(o.flags&128)===0&&(o.memoizedState=null),o.flags|=4;Jt(o),x=!1}else Vr!==null&&(zf(Vr),Vr=null),x=!0;if(!x)return o.flags&65536?o:null}return(o.flags&128)!==0?(o.lanes=c,o):(h=h!==null,h!==(s!==null&&s.memoizedState!==null)&&h&&(o.child.flags|=8192,(o.mode&1)!==0&&(s===null||(yt.current&1)!==0?Nt===0&&(Nt=3):Vf())),o.updateQueue!==null&&(o.flags|=4),Jt(o),null);case 4:return ei(),jf(s,o),s===null&&ya(o.stateNode.containerInfo),Jt(o),null;case 10:return nf(o.type._context),Jt(o),null;case 17:return dr(o.type)&&ic(),Jt(o),null;case 19:if(ft(yt),x=o.memoizedState,x===null)return Jt(o),null;if(h=(o.flags&128)!==0,C=x.rendering,C===null)if(h)ja(x,!1);else{if(Nt!==0||s!==null&&(s.flags&128)!==0)for(s=o.child;s!==null;){if(C=vc(s),C!==null){for(o.flags|=128,ja(x,!1),h=C.updateQueue,h!==null&&(o.updateQueue=h,o.flags|=4),o.subtreeFlags=0,h=c,c=o.child;c!==null;)x=c,s=h,x.flags&=14680066,C=x.alternate,C===null?(x.childLanes=0,x.lanes=s,x.child=null,x.subtreeFlags=0,x.memoizedProps=null,x.memoizedState=null,x.updateQueue=null,x.dependencies=null,x.stateNode=null):(x.childLanes=C.childLanes,x.lanes=C.lanes,x.child=C.child,x.subtreeFlags=0,x.deletions=null,x.memoizedProps=C.memoizedProps,x.memoizedState=C.memoizedState,x.updateQueue=C.updateQueue,x.type=C.type,s=C.dependencies,x.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),c=c.sibling;return lt(yt,yt.current&1|2),o.child}s=s.sibling}x.tail!==null&&Ct()>si&&(o.flags|=128,h=!0,ja(x,!1),o.lanes=4194304)}else{if(!h)if(s=vc(C),s!==null){if(o.flags|=128,h=!0,c=s.updateQueue,c!==null&&(o.updateQueue=c,o.flags|=4),ja(x,!0),x.tail===null&&x.tailMode==="hidden"&&!C.alternate&&!pt)return Jt(o),null}else 2*Ct()-x.renderingStartTime>si&&c!==1073741824&&(o.flags|=128,h=!0,ja(x,!1),o.lanes=4194304);x.isBackwards?(C.sibling=o.child,o.child=C):(c=x.last,c!==null?c.sibling=C:o.child=C,x.last=C)}return x.tail!==null?(o=x.tail,x.rendering=o,x.tail=o.sibling,x.renderingStartTime=Ct(),o.sibling=null,c=yt.current,lt(yt,h?c&1|2
vendor: 19,012 bytes, line 41
41:c&1),o):(Jt(o),null);case 22:case 23:return qf(),h=o.memoizedState!==null,s!==null&&s.memoizedState!==null!==h&&(o.flags|=8192),h&&(o.mode&1)!==0?(Er&1073741824)!==0&&(Jt(o),o.subtreeFlags&6&&(o.flags|=8192)):Jt(o),null;case 24:return null;case 25:return null}throw Error(r(156,o.tag))}function Y1(s,o){switch(Jd(o),o.tag){case 1:return dr(o.type)&&ic(),s=o.flags,s&65536?(o.flags=s&-65537|128,o):null;case 3:return ei(),ft(ur),ft(Qt),df(),s=o.flags,(s&65536)!==0&&(s&128)===0?(o.flags=s&-65537|128,o):null;case 5:return cf(o),null;case 13:if(ft(yt),s=o.memoizedState,s!==null&&s.dehydrated!==null){if(o.alternate===null)throw Error(r(340));Yo()}return s=o.flags,s&65536?(o.flags=s&-65537|128,o):null;case 19:return ft(yt),null;case 4:return ei(),null;case 10:return nf(o.type._context),null;case 22:case 23:return qf(),null;case 24:return null;default:return null}}var Tc=!1,Xt=!1,J1=typeof WeakSet=="function"?WeakSet:Set,we=null;function ri(s,o){var c=s.ref;if(c!==null)if(typeof c=="function")try{c(null)}catch(h){St(s,o,h)}else c.current=null}function Of(s,o,c){try{c()}catch(h){St(s,o,h)}}var zv=!1;function X1(s,o){if(Bd=Hl,s=wg(),Id(s)){if("selectionStart"in s)var c={start:s.selectionStart,end:s.selectionEnd};else e:{c=(c=s.ownerDocument)&&c.defaultView||window;var h=c.getSelection&&c.getSelection();if(h&&h.rangeCount!==0){c=h.anchorNode;var y=h.anchorOffset,x=h.focusNode;h=h.focusOffset;try{c.nodeType,x.nodeType}catch{c=null;break e}var C=0,j=-1,A=-1,V=0,se=0,ie=s,ee=null;t:for(;;){for(var ge;ie!==c||y!==0&&ie.nodeType!==3||(j=C+y),ie!==x||h!==0&&ie.nodeType!==3||(A=C+h),ie.nodeType===3&&(C+=ie.nodeValue.length),(ge=ie.firstChild)!==null;)ee=ie,ie=ge;for(;;){if(ie===s)break t;if(ee===c&&++V===y&&(j=C),ee===x&&++se===h&&(A=C),(ge=ie.nextSibling)!==null)break;ie=ee,ee=ie.parentNode}ie=ge}c=j===-1||A===-1?null:{start:j,end:A}}else c=null}c=c||{start:0,end:0}}else c=null;for(qd={focusedElem:s,selectionRange:c},Hl=!1,we=o;we!==null;)if(o=we,s=o.child,(o.subtreeFlags&1028)!==0&&s!==null)s.return=o,we=s;else for(;we!==null;){o=we;try{var be=o.alternate;if((o.flags&1024)!==0)switch(o.tag){case 0:case 11:case 15:break;case 1:if(be!==null){var ke=be.memoizedProps,Rt=be.memoizedState,$=o.stateNode,D=$.getSnapshotBeforeUpdate(o.elementType===o.type?ke:Wr(o.type,ke),Rt);$.__reactInternalSnapshotBeforeUpdate=D}break;case 3:var B=o.stateNode.containerInfo;B.nodeType===1?B.textContent="":B.nodeType===9&&B.documentElement&&B.removeChild(B.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(r(163))}}catch(ce){St(o,o.return,ce)}if(s=o.sibling,s!==null){s.return=o.return,we=s;break}we=o.return}return be=zv,zv=!1,be}function Oa(s,o,c){var h=o.updateQueue;if(h=h!==null?h.lastEffect:null,h!==null){var y=h=h.next;do{if((y.tag&s)===s){var x=y.destroy;y.destroy=void 0,x!==void 0&&Of(o,c,x)}y=y.next}while(y!==h)}}function Cc(s,o){if(o=o.updateQueue,o=o!==null?o.lastEffect:null,o!==null){var c=o=o.next;do{if((c.tag&s)===s){var h=c.create;c.destroy=h()}c=c.next}while(c!==o)}}function Af(s){var o=s.ref;if(o!==null){var c=s.stateNode;switch(s.tag){case 5:s=c;break;default:s=c}typeof o=="function"?o(s):o.current=s}}function Bv(s){var o=s.alternate;o!==null&&(s.alternate=null,Bv(o)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(o=s.stateNode,o!==null&&(delete o[mn],delete o[ba],delete o[Kd],delete o[I1],delete o[L1])),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}function qv(s){return s.tag===5||s.tag===3||s.tag===4}function Vv(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||qv(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function Nf(s,o,c){var h=s.tag;if(h===5||h===6)s=s.stateNode,o?c.nodeType===8?c.parentNode.insertBefore(s,o):c.insertBefore(s,o):(c.nodeType===8?(o=c.parentNode,o.insertBefore(s,c)):(o=c,o.appendChild(s)),c=c._reactRootContainer,c!=null||o.onclick!==null||(o.onclick=sc));else if(h!==4&&(s=s.child,s!==null))for(Nf(s,o,c),s=s.sibling;s!==null;)Nf(s,o,c),s=s.sibling}function If(s,o,c){var h=s.tag;if(h===5||h===6)s=s.stateNode,o?c.insertBefore(s,o):c.appendChild(s);else if(h!==4&&(s=s.child,s!==null))for(If(s,o,c),s=s.sibling;s!==null;)If(s,o,c),s=s.sibling}var Bt=null,Hr=!1;function us(s,o,c){for(c=c.child;c!==null;)Wv(s,o,c),c=c.sibling}function Wv(s,o,c){if(pn&&typeof pn.onCommitFiberUnmount=="function")try{pn.onCommitFiberUnmount(Ul,c)}catch{}switch(c.tag){case 5:Xt||ri(c,o);case 6:var h=Bt,y=Hr;Bt=null,us(s,o,c),Bt=h,Hr=y,Bt!==null&&(Hr?(s=Bt,c=c.stateNode,s.nodeType===8?s.parentNode.removeChild(c):s.removeChild(c)):Bt.removeChild(c.stateNode));break;case 18:Bt!==null&&(Hr?(s=Bt,c=c.stateNode,s.nodeType===8?Hd(s.parentNode,c):s.nodeType===1&&Hd(s,c),ca(s)):Hd(Bt,c.stateNode));break;case 4:h=Bt,y=Hr,Bt=c.stateNode.containerInfo,Hr=!0,us(s,o,c),Bt=h,Hr=y;break;case 0:case 11:case 14:case 15:if(!Xt&&(h=c.updateQueue,h!==null&&(h=h.lastEffect,h!==null))){y=h=h.next;do{var x=y,C=x.destroy;x=x.tag,C!==void 0&&((x&2)!==0||(x&4)!==0)&&Of(c,o,C),y=y.next}while(y!==h)}us(s,o,c);break;case 1:if(!Xt&&(ri(c,o),h=c.stateNode,typeof h.componentWillUnmount=="function"))try{h.props=c.memoizedProps,h.state=c.memoizedState,h.componentWillUnmount()}catch(j){St(c,o,j)}us(s,o,c);break;case 21:us(s,o,c);break;case 22:c.mode&1?(Xt=(h=Xt)||c.memoizedState!==null,us(s,o,c),Xt=h):us(s,o,c);break;default:us(s,o,c)}}function Hv(s){var o=s.updateQueue;if(o!==null){s.updateQueue=null;var c=s.stateNode;c===null&&(c=s.stateNode=new J1),o.forEach(function(h){var y=ak.bind(null,s,h);c.has(h)||(c.add(h),h.then(y,y))})}}function Kr(s,o){var c=o.deletions;if(c!==null)for(var h=0;h<c.length;h++){var y=c[h];try{var x=s,C=o,j=C;e:for(;j!==null;){switch(j.tag){case 5:Bt=j.stateNode,Hr=!1;break e;case 3:Bt=j.stateNode.containerInfo,Hr=!0;break e;case 4:Bt=j.stateNode.containerInfo,Hr=!0;break e}j=j.return}if(Bt===null)throw Error(r(160));Wv(x,C,y),Bt=null,Hr=!1;var A=y.alternate;A!==null&&(A.return=null),y.return=null}catch(V){St(y,o,V)}}if(o.subtreeFlags&12854)for(o=o.child;o!==null;)Kv(o,s),o=o.sibling}function Kv(s,o){var c=s.alternate,h=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:if(Kr(o,s),yn(s),h&4){try{Oa(3,s,s.return),Cc(3,s)}catch(ke){St(s,s.return,ke)}try{Oa(5,s,s.return)}catch(ke){St(s,s.return,ke)}}break;case 1:Kr(o,s),yn(s),h&512&&c!==null&&ri(c,c.return);break;case 5:if(Kr(o,s),yn(s),h&512&&c!==null&&ri(c,c.return),s.flags&32){var y=s.stateNode;try{un(y,"")}catch(ke){St(s,s.return,ke)}}if(h&4&&(y=s.stateNode,y!=null)){var x=s.memoizedProps,C=c!==null?c.memoizedProps:x,j=s.type,A=s.updateQueue;if(s.updateQueue=null,A!==null)try{j==="input"&&x.type==="radio"&&x.name!=null&&ot(y,x),ea(j,C);var V=ea(j,x);for(C=0;C<A.length;C+=2){var se=A[C],ie=A[C+1];se==="style"?On(y,ie):se==="dangerouslySetInnerHTML"?Nl(y,ie):se==="children"?un(y,ie):R(y,se,ie,V)}switch(j){case"input":Tt(y,x);break;case"textarea":No(y,x);break;case"select":var ee=y._wrapperState.wasMultiple;y._wrapperState.wasMultiple=!!x.multiple;var ge=x.value;ge!=null?Dt(y,!!x.multiple,ge,!1):ee!==!!x.multiple&&(x.defaultValue!=null?Dt(y,!!x.multiple,x.defaultValue,!0):Dt(y,!!x.multiple,x.multiple?[]:"",!1))}y[ba]=x}catch(ke){St(s,s.return,ke)}}break;case 6:if(Kr(o,s),yn(s),h&4){if(s.stateNode===null)throw Error(r(162));y=s.stateNode,x=s.memoizedProps;try{y.nodeValue=x}catch(ke){St(s,s.return,ke)}}break;case 3:if(Kr(o,s),yn(s),h&4&&c!==null&&c.memoizedState.isDehydrated)try{ca(o.containerInfo)}catch(ke){St(s,s.return,ke)}break;case 4:Kr(o,s),yn(s);break;case 13:Kr(o,s),yn(s),y=s.child,y.flags&8192&&(x=y.memoizedState!==null,y.stateNode.isHidden=x,!x||y.alternate!==null&&y.alternate.memoizedState!==null||(Mf=Ct())),h&4&&Hv(s);break;case 22:if(se=c!==null&&c.memoizedState!==null,s.mode&1?(Xt=(V=Xt)||se,Kr(o,s),Xt=V):Kr(o,s),yn(s),h&8192){if(V=s.memoizedState!==null,(s.stateNode.isHidden=V)&&!se&&(s.mode&1)!==0)for(we=s,se=s.child;se!==null;){for(ie=we=se;we!==null;){switch(ee=we,ge=ee.child,ee.tag){case 0:case 11:case 14:case 15:Oa(4,ee,ee.return);break;case 1:ri(ee,ee.return);var be=ee.stateNode;if(typeof be.componentWillUnmount=="function"){h=ee,c=ee.return;try{o=h,be.props=o.memoizedProps,be.state=o.memoizedState,be.componentWillUnmount()}catch(ke){St(h,c,ke)}}break;case 5:ri(ee,ee.return);break;case 22:if(ee.memoizedState!==null){Yv(ie);continue}}ge!==null?(ge.return=ee,we=ge):Yv(ie)}se=se.sibling}e:for(se=null,ie=s;;){if(ie.tag===5){if(se===null){se=ie;try{y=ie.stateNode,V?(x=y.style,typeof x.setProperty=="function"?x.setProperty("display","none","important"):x.display="none"):(j=ie.stateNode,A=ie.memoizedProps.style,C=A!=null&&A.hasOwnProperty("display")?A.display:null,j.style.display=Lo("display",C))}catch(ke){St(s,s.return,ke)}}}else if(ie.tag===6){if(se===null)try{ie.stateNode.nodeValue=V?"":ie.memoizedProps}catch(ke){St(s,s.return,ke)}}else if((ie.tag!==22&&ie.tag!==23||ie.memoizedState===null||ie===s)&&ie.child!==null){ie.child.return=ie,ie=ie.child;continue}if(ie===s)break e;for(;ie.sibling===null;){if(ie.return===null||ie.return===s)break e;se===ie&&(se=null),ie=ie.return}se===ie&&(se=null),ie.sibling.return=ie.return,ie=ie.sibling}}break;case 19:Kr(o,s),yn(s),h&4&&Hv(s);break;case 21:break;default:Kr(o,s),yn(s)}}function yn(s){var o=s.flags;if(o&2){try{e:{for(var c=s.return;c!==null;){if(qv(c)){var h=c;break e}c=c.return}throw Error(r(160))}switch(h.tag){case 5:var y=h.stateNode;h.flags&32&&(un(y,""),h.flags&=-33);var x=Vv(s);If(s,x,y);break;case 3:case 4:var C=h.stateNode.containerInfo,j=Vv(s);Nf(s,j,C);break;default:throw Error(r(161))}}catch(A){St(s,s.return,A)}s.flags&=-3}o&4096&&(s.flags&=-4097)}function Z1(s,o,c){we=s,Gv(s)}function Gv(s,o,c){for(var h=(s.mode&1)!==0;we!==null;){var y=we,x=y.child;if(y.tag===22&&h){var C=y.memoizedState!==null||Tc;if(!C){var j=y.alternate,A=j!==null&&j.memoizedState!==null||Xt;j=Tc;var V=Xt;if(Tc=C,(Xt=A)&&!V)for(we=y;we!==null;)C=we,A=C.child,C.tag===22&&C.memoizedState!==null?Jv(y):A!==null?(A.return=C,we=A):Jv(y);for(;x!==null;)we=x,Gv(x),x=x.sibling;we=y,Tc=j,Xt=V}Qv(s)}else(y.subtreeFlags&8772)!==0&&x!==null?(x.return=y,we=x):Qv(s)}}function Qv(s){for(;we!==null;){var o=we;if((o.flags&8772)!==0){var c=o.alternate;try{if((o.flags&8772)!==0)switch(o.tag){case 0:case 11:case 15:Xt||Cc(5,o);break;case 1:var h=o.stateNode;if(o.flags&4&&!Xt)if(c===null)h.componentDidMount();else{var y=o.elementType===o.type?c.memoizedProps:Wr(o.type,c.memoizedProps);h.componentDidUpdate(y,c.memoizedState,h.__reactInternalSnapshotBeforeUpdate)}var x=o.updateQueue;x!==null&&Yg(o,x,h);break;case 3:var C=o.updateQueue;if(C!==null){if(c=null,o.child!==null)switch(o.child.tag){case 5:c=o.child.stateNode;break;case 1:c=o.child.stateNode}Yg(o,C,c)}break;case 5:var j=o.stateNode;if(c===null&&o.flags&4){c=j;var A=o.memoizedProps;switch(o.type){case"button":case"input":case"select":case"textarea":A.autoFocus&&c.focus();break;case"img":A.src&&(c.src=A.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(o.memoizedState===null){var V=o.alternate;if(V!==null){var se=V.memoizedState;if(se!==null){var ie=se.dehydrated;ie!==null&&ca(ie)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(r(163))}Xt||o.flags&512&&Af(o)}catch(ee){St(o,o.return,ee)}}if(o===s){we=null;break}if(c=o.sibling,c!==null){c.return=o.return,we=c;break}we=o.return}}function Yv(s){for(;we!==null;){var o=we;if(o===s){we=null;break}var c=o.sibling;if(c!==null){c.return=o.return,we=c;break}we=o.return}}function Jv(s){for(;we!==null;){var o=we;try{switch(o.tag){case 0:case 11:case 15:var c=o.return;try{Cc(4,o)}catch(A){St(o,c,A)}break;case 1:var h=o.stateNode;if(typeof h.componentDidMount=="function"){var y=o.return;try{h.componentDidMount()}catch(A){St(o,y,A)}}var x=o.return;try{Af(o)}catch(A){St(o,x,A)}break;case 5:var C=o.return;try{Af(o)}catch(A){St(o,C,A)}}}catch(A){St(o,o.return,A)}if(o===s){we=null;break}var j=o.sibling;if(j!==null){j.return=o.return,we=j;break}we=o.return}}var ek=Math.ceil,Rc=P.ReactCurrentDispatcher,Lf=P.ReactCurrentOwner,Ir=P.ReactCurrentBatchConfig,Xe=0,$t=null,Pt=null,qt=0,Er=0,ni=os(0),Nt=0,Aa=null,Zs=0,Pc=0,Df=0,Na=null,hr=null,Mf=0,si=1/0,Fn=null,jc=!1,$f=null,ds=null,Oc=!1,fs=null,Ac=0,Ia=0,Ff=null,Nc=-1,Ic=0;function sr(){return(Xe&6)!==0?Ct():Nc!==-1?Nc:Nc=Ct()}function hs(s){return(s.mode&1)===0?1:(Xe&2)!==0&&qt!==0?qt&-qt:M1.transition!==null?(Ic===0&&(Ic=Vm()),Ic):(s=it,s!==0||(s=window.event,s=s===void 0?16:Zm(s.type)),s)}function Gr(s,o,c,h){if(50<Ia)throw Ia=0,Ff=null,Error(r(185));sa(s,c,h),((Xe&2)===0||s!==$t)&&(s===$t&&((Xe&2)===0&&(Pc|=c),Nt===4&&ps(s,qt)),pr(s,h),c===1&&Xe===0&&(o.mode&1)===0&&(si=Ct()+500,lc&&as()))}function pr(s,o){var c=s.callbackNode;ME(s,o);var h=ql(s,s===$t?qt:0);if(h===0)c!==null&&zm(c),s.callbackNode=null,s.callbackPriority=0;else if(o=h&-h,s.callbackPriority!==o){if(c!=null&&zm(c),o===1)s.tag===0?D1(Zv.bind(null,s)):$g(Zv.bind(null,s)),A1(function(){(Xe&6)===0&&as()}),c=null;else{switch(Wm(h)){case 1:c=vd;break;case 4:c=Bm;break;case 16:c=Fl;break;case 536870912:c=qm;break;default:c=Fl}c=ay(c,Xv.bind(null,s))}s.callbackPriority=o,s.callbackNode=c}}function Xv(s,o){if(Nc=-1,Ic=0,(Xe&6)!==0)throw Error(r(327));var c=s.callbackNode;if(oi()&&s.callbackNode!==c)return null;var h=ql(s,s===$t?qt:0);if(h===0)return null;if((h&30)!==0||(h&s.expiredLanes)!==0||o)o=Lc(s,h);else{o=h;var y=Xe;Xe|=2;var x=ty();($t!==s||qt!==o)&&(Fn=null,si=Ct()+500,to(s,o));do try{nk();break}catch(j){ey(s,j)}while(!0);rf(),Rc.current=x,Xe=y,Pt!==null?o=0:($t=null,qt=0,o=Nt)}if(o!==0){if(o===2&&(y=yd(s),y!==0&&(h=y,o=Uf(s,y))),o===1)throw c=Aa,to(s,0),ps(s,h),pr(s,Ct()),c;if(o===6)ps(s,h);else{if(y=s.current.alternate,(h&30)===0&&!tk(y)&&(o=Lc(s,h),o===2&&(x=yd(s),x!==0&&(h=x,o=Uf(s,x))),o===1))throw c=Aa,to(s,0),ps(s,h),pr(s,Ct()),c;switch(s.finishedWork=y,s.finishedLanes=h,o){case 0:case 1:throw Error(r(345));case 2:ro(s,hr,Fn);break;case 3:if(ps(s,h),(h&130023424)===h&&(o=Mf+500-Ct(),10<o)){if(ql(s,0)!==0)break;if(y=s.suspendedLanes,(y&h)!==h){sr(),s.pingedLanes|=s.suspendedLanes&y;break}s.timeoutHandle=Wd(ro.bind(null,s,hr,Fn),o);break}ro(s,hr,Fn);break;case 4:if(ps(s,h),(h&4194240)===h)break;for(o=s.eventTimes,y=-1;0<h;){var C=31-Br(h);x=1<<C,C=o[C],C>y&&(y=C),h&=~x}if(h=y,h=Ct()-h,h=(120>h?120:480>h?480:1080>h?1080:1920>h?1920:3e3>h?3e3:4320>h?4320:1960*ek(h/1960))-h,10<h){s.timeoutHandle=Wd(ro.bind(null,s,hr,Fn),h);break}ro(s,hr,Fn);break;case 5:ro(s,hr,Fn);break;default:throw Error(r(329))}}}return pr(s,Ct()),s.callbackNode===c?Xv.bind(null,s):null}function Uf(s,o){var c=Na;return s.current.memoizedState.isDehydrated&&(to(s,o).flags|=256),s=Lc(s,o),s!==2&&(o=hr,hr=c,o!==null&&zf(o)),s}function zf(s){hr===null?hr=s:hr.push.apply(hr,s)}function tk(s){for(var o=s;;){if(o.flags&16384){var c=o.updateQueue;if(c!==null&&(c=c.stores,c!==null))for(var h=0;h<c.length;h++){var y=c[h],x=y.getSnapshot;y=y.value;try{if(!qr(x(),y))return!1}catch{return!1}}}if(c=o.child,o.subtreeFlags&16384&&c!==null)c.return=o,o=c;else{if(o===s)break;for(;o.sibling===null;){if(o.return===null||o.return===s)return!0;o=o.return}o.sibling.return=o.return,o=o.sibling}}return!0}function ps(s,o){for(o&=~Df,o&=~Pc,s.suspendedLanes|=o,s.pingedLanes&=~o,s=s.expirationTimes;0<o;){var c=31-Br(o),h=1<<c;s[c]=-1,o&=~h}}function Zv(s){if((Xe&6)!==0)throw Error(r(327));oi();var o=ql(s,0);if((o&1)===0)return pr(s,Ct()),null;var c=Lc(s,o);if(s.tag!==0&&c===2){var h=yd(s);h!==0&&(o=h,c=Uf(s,h))}if(c===1)throw c=Aa,to(s,0),ps(s,o),pr(s,Ct()),c;if(c===6)throw Error(r(345));return s.finishedWork=s.current.alternate,s.finishedLanes=o,ro(s,hr,Fn),pr(s,Ct()),null}function Bf(s,o){var c=Xe;Xe|=1;try{return s(o)}finally{Xe=c,Xe===0&&(si=Ct()+500,lc&&as())}}function eo(s){fs!==null&&fs.tag===0&&(Xe&6)===0&&oi();var o=Xe;Xe|=1;var c=Ir.transition,h=it;try{if(Ir.transition=null,it=1,s)return s()}finally{it=h,Ir.transition=c,Xe=o,(Xe&6)===0&&as()}}function qf(){Er=ni.current,ft(ni)}function to(s,o){s.finishedWork=null,s.finishedLanes=0;var c=s.timeoutHandle;if(c!==-1&&(s.timeoutHandle=-1,O1(c)),Pt!==null)for(c=Pt.return;c!==null;){var h=c;switch(Jd(h),h.tag){case 1:h=h.type.childContextTypes,h!=null&&ic();break;case 3:ei(),ft(ur),ft(Qt),df();break;case 5:cf(h);break;case 4:ei();break;case 13:ft(yt);break;case 19:ft(yt);break;case 10:nf(h.type._context);break;case 22:case 23:qf()}c=c.return}if($t=s,Pt=s=ms(s.current,null),qt=Er=o,Nt=0,Aa=null,Df=Pc=Zs=0,hr=Na=null,Ys!==null){for(o=0;o<Ys.length;o++)if(c=Ys[o],h=c.interleaved,h!==null){c.interleaved=null;var y=h.next,x=c.pending;if(x!==null){var C=x.next;x.next=y,h.next=C}c.pending=h}Ys=null}return s}function ey(s,o){do{var c=Pt;try{if(rf(),yc.current=_c,wc){for(var h=wt.memoizedState;h!==null;){var y=h.queue;y!==null&&(y.pending=null),h=h.next}wc=!1}if(Xs=0,Mt=At=wt=null,Ta=!1,Ca=0,Lf.current=null,c===null||c.return===null){Nt=1,Aa=o,Pt=null;break}e:{var x=s,C=c.return,j=c,A=o;if(o=qt,j.flags|=32768,A!==null&&typeof A=="object"&&typeof A.then=="function"){var V=A,se=j,ie=se.tag;if((se.mode&1)===0&&(ie===0||ie===11||ie===15)){var ee=se.alternate;ee?(se.updateQueue=ee.updateQueue,se.memoizedState=ee.memoizedState,se.lanes=ee.lanes):(se.updateQueue=null,se.memoizedState=null)}var ge=kv(C);if(ge!==null){ge.flags&=-257,Tv(ge,C,j,x,o),ge.mode&1&&Ev(x,V,o),o=ge,A=V;var be=o.updateQueue;if(be===null){var ke=new Set;ke.add(A),o.updateQueue=ke}else be.add(A);break e}else{if((o&1)===0){Ev(x,V,o),Vf();break e}A=Error(r(426))}}else if(pt&&j.mode&1){var Rt=kv(C);if(Rt!==null){(Rt.flags&65536)===0&&(Rt.flags|=256),Tv(Rt,C,j,x,o),ef(ti(A,j));break e}}x=A=ti(A,j),Nt!==4&&(Nt=2),Na===null?Na=[x]:Na.push(x),x=C;do{switch(x.tag){case 3:x.flags|=65536,o&=-o,x.lanes|=o;var $=_v(x,A,o);Qg(x,$);break e;case 1:j=A;var D=x.type,B=x.stateNode;if((x.flags&128)===0&&(typeof D.getDerivedStateFromError=="function"||B!==null&&typeof B.componentDidCatch=="function"&&(ds===null||!ds.has(B)))){x.flags|=65536,o&=-o,x.lanes|=o;var ce=Sv(x,j,o);Qg(x,ce);break e}}x=x.return}while(x!==null)}ny(c)}catch(Ce){o=Ce,Pt===c&&c!==null&&(Pt=c=c.return);continue}break}while(!0)}function ty(){var s=Rc.current;return Rc.current=_c,s===null?_c:s}function Vf(){(Nt===0||Nt===3||Nt===2)&&(Nt=4),$t===null||(Zs&268435455)===0&&(Pc&268435455)===0||ps($t,qt)}function Lc(s,o){var c=Xe;Xe|=2;var h=ty();($t!==s||qt!==o)&&(Fn=null,to(s,o));do try{rk();break}catch(y){ey(s,y)}while(!0);if(rf(),Xe=c,Rc.current=h,Pt!==null)throw Error(r(261));return $t=null,qt=0,Nt}function rk(){for(;Pt!==null;)ry(Pt)}function nk(){for(;Pt!==null&&!RE();)ry(Pt)}function ry(s){var o=iy(s.alternate,s,Er);s.memoizedProps=s.pendingProps,o===null?ny(s):Pt=o,Lf.current=null}function ny(s){var o=s;do{var c=o.alternate;if(s=o.return,(o.flags&32768)===0){if(c=Q1(c,o,Er),c!==null){Pt=c;return}}else{if(c=Y1(c,o),c!==null){c.flags&=32767,Pt=c;return}
vendor: 5,009 bytes, line 41
41if(s!==null)s.flags|=32768,s.subtreeFlags=0,s.deletions=null;else{Nt=6,Pt=null;return}}if(o=o.sibling,o!==null){Pt=o;return}Pt=o=s}while(o!==null);Nt===0&&(Nt=5)}function ro(s,o,c){var h=it,y=Ir.transition;try{Ir.transition=null,it=1,sk(s,o,c,h)}finally{Ir.transition=y,it=h}return null}function sk(s,o,c,h){do oi();while(fs!==null);if((Xe&6)!==0)throw Error(r(327));c=s.finishedWork;var y=s.finishedLanes;if(c===null)return null;if(s.finishedWork=null,s.finishedLanes=0,c===s.current)throw Error(r(177));s.callbackNode=null,s.callbackPriority=0;var x=c.lanes|c.childLanes;if($E(s,x),s===$t&&(Pt=$t=null,qt=0),(c.subtreeFlags&2064)===0&&(c.flags&2064)===0||Oc||(Oc=!0,ay(Fl,function(){return oi(),null})),x=(c.flags&15990)!==0,(c.subtreeFlags&15990)!==0||x){x=Ir.transition,Ir.transition=null;var C=it;it=1;var j=Xe;Xe|=4,Lf.current=null,X1(s,c),Kv(c,s),E1(qd),Hl=!!Bd,qd=Bd=null,s.current=c,Z1(c),PE(),Xe=j,it=C,Ir.transition=x}else s.current=c;if(Oc&&(Oc=!1,fs=s,Ac=y),x=s.pendingLanes,x===0&&(ds=null),AE(c.stateNode),pr(s,Ct()),o!==null)for(h=s.onRecoverableError,c=0;c<o.length;c++)y=o[c],h(y.value,{componentStack:y.stack,digest:y.digest});if(jc)throw jc=!1,s=$f,$f=null,s;return(Ac&1)!==0&&s.tag!==0&&oi(),x=s.pendingLanes,(x&1)!==0?s===Ff?Ia++:(Ia=0,Ff=s):Ia=0,as(),null}function oi(){if(fs!==null){var s=Wm(Ac),o=Ir.transition,c=it;try{if(Ir.transition=null,it=16>s?16:s,fs===null)var h=!1;else{if(s=fs,fs=null,Ac=0,(Xe&6)!==0)throw Error(r(331));var y=Xe;for(Xe|=4,we=s.current;we!==null;){var x=we,C=x.child;if((we.flags&16)!==0){var j=x.deletions;if(j!==null){for(var A=0;A<j.length;A++){var V=j[A];for(we=V;we!==null;){var se=we;switch(se.tag){case 0:case 11:case 15:Oa(8,se,x)}var ie=se.child;if(ie!==null)ie.return=se,we=ie;else for(;we!==null;){se=we;var ee=se.sibling,ge=se.return;if(Bv(se),se===V){we=null;break}if(ee!==null){ee.return=ge,we=ee;break}we=ge}}}var be=x.alternate;if(be!==null){var ke=be.child;if(ke!==null){be.child=null;do{var Rt=ke.sibling;ke.sibling=null,ke=Rt}while(ke!==null)}}we=x}}if((x.subtreeFlags&2064)!==0&&C!==null)C.return=x,we=C;else e:for(;we!==null;){if(x=we,(x.flags&2048)!==0)switch(x.tag){case 0:case 11:case 15:Oa(9,x,x.return)}var $=x.sibling;if($!==null){$.return=x.return,we=$;break e}we=x.return}}var D=s.current;for(we=D;we!==null;){C=we;var B=C.child;if((C.subtreeFlags&2064)!==0&&B!==null)B.return=C,we=B;else e:for(C=D;we!==null;){if(j=we,(j.flags&2048)!==0)try{switch(j.tag){case 0:case 11:case 15:Cc(9,j)}}catch(Ce){St(j,j.return,Ce)}if(j===C){we=null;break e}var ce=j.sibling;if(ce!==null){ce.return=j.return,we=ce;break e}we=j.return}}if(Xe=y,as(),pn&&typeof pn.onPostCommitFiberRoot=="function")try{pn.onPostCommitFiberRoot(Ul,s)}catch{}h=!0}return h}finally{it=c,Ir.transition=o}}return!1}function sy(s,o,c){o=ti(c,o),o=_v(s,o,1),s=cs(s,o,1),o=sr(),s!==null&&(sa(s,1,o),pr(s,o))}function St(s,o,c){if(s.tag===3)sy(s,s,c);else for(;o!==null;){if(o.tag===3){sy(o,s,c);break}else if(o.tag===1){var h=o.stateNode;if(typeof o.type.getDerivedStateFromError=="function"||typeof h.componentDidCatch=="function"&&(ds===null||!ds.has(h))){s=ti(c,s),s=Sv(o,s,1),o=cs(o,s,1),s=sr(),o!==null&&(sa(o,1,s),pr(o,s));break}}o=o.return}}function ok(s,o,c){var h=s.pingCache;h!==null&&h.delete(o),o=sr(),s.pingedLanes|=s.suspendedLanes&c,$t===s&&(qt&c)===c&&(Nt===4||Nt===3&&(qt&130023424)===qt&&500>Ct()-Mf?to(s,0):Df|=c),pr(s,o)}function oy(s,o){o===0&&((s.mode&1)===0?o=1:(o=Bl,Bl<<=1,(Bl&130023424)===0&&(Bl=4194304)));var c=sr();s=Dn(s,o),s!==null&&(sa(s,o,c),pr(s,c))}function ik(s){var o=s.memoizedState,c=0;o!==null&&(c=o.retryLane),oy(s,c)}function ak(s,o){var c=0;switch(s.tag){case 13:var h=s.stateNode,y=s.memoizedState;y!==null&&(c=y.retryLane);break;case 19:h=s.stateNode;break;default:throw Error(r(314))}h!==null&&h.delete(o),oy(s,c)}var iy;iy=function(s,o,c){if(s!==null)if(s.memoizedProps!==o.pendingProps||ur.current)fr=!0;else{if((s.lanes&c)===0&&(o.flags&128)===0)return fr=!1,G1(s,o,c);fr=(s.flags&131072)!==0}else fr=!1,pt&&(o.flags&1048576)!==0&&Fg(o,uc,o.index);switch(o.lanes=0,o.tag){case 2:var h=o.type;kc(s,o),s=o.pendingProps;var y=Ko(o,Qt.current);Zo(o,c),y=pf(null,o,h,s,y,c);var x=mf();return o.flags|=1,typeof y=="object"&&y!==null&&typeof y.render=="function"&&y.$$typeof===void 0?(o.tag=1,o.memoizedState=null,o.updateQueue=null,dr(h)?(x=!0,ac(o)):x=!1,o.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,af(o),y.updater=Sc,o.stateNode=y,y._reactInternals=o,xf(o,h,s,c),o=kf(null,o,h,!0,x,c)):(o.tag=0,pt&&x&&Yd(o),nr(null,o,y,c),o=o.child),o;case 16:h=o.elementType;e:{switch(kc(s,o),s=o.pendingProps,y=h._init,h=y(h._payload),o.type=h,y=o.tag=ck(h),s=Wr(h,s),y){case 0:o=Ef(null,o,h,s,c);break e;case 1:o=Av(null,o,h,s,c);break e;case 11:o=Cv(null,o,h,s,c);break e;case 14:o=Rv(null,o,h,Wr(h.type,s),c);break e}throw Error(r(306,h,""))}return o;case 0:return h=o.type,y=o.pendingProps,y=o.elementType===h?y:Wr(h,y),Ef(s,o,h,y,c);case 1:return h=o.type,y=o.pendingProps,y=o.elementType===h?y:Wr(h,y),Av(s,o,h,y,c);
vendor: 10,415 bytes, line 41
41case 3:e:{if(Nv(o),s===null)throw Error(r(387));h=o.pendingProps,x=o.memoizedState,y=x.element,Gg(s,o),gc(o,h,null,c);var C=o.memoizedState;if(h=C.element,x.isDehydrated)if(x={element:h,isDehydrated:!1,cache:C.cache,pendingSuspenseBoundaries:C.pendingSuspenseBoundaries,transitions:C.transitions},o.updateQueue.baseState=x,o.memoizedState=x,o.flags&256){y=ti(Error(r(423)),o),o=Iv(s,o,h,c,y);break e}else if(h!==y){y=ti(Error(r(424)),o),o=Iv(s,o,h,c,y);break e}else for(Sr=ss(o.stateNode.containerInfo.firstChild),_r=o,pt=!0,Vr=null,c=Hg(o,null,h,c),o.child=c;c;)c.flags=c.flags&-3|4096,c=c.sibling;else{if(Yo(),h===y){o=$n(s,o,c);break e}nr(s,o,h,c)}o=o.child}return o;case 5:return Jg(o),s===null&&Zd(o),h=o.type,y=o.pendingProps,x=s!==null?s.memoizedProps:null,C=y.children,Vd(h,y)?C=null:x!==null&&Vd(h,x)&&(o.flags|=32),Ov(s,o),nr(s,o,C,c),o.child;case 6:return s===null&&Zd(o),null;case 13:return Lv(s,o,c);case 4:return lf(o,o.stateNode.containerInfo),h=o.pendingProps,s===null?o.child=Jo(o,null,h,c):nr(s,o,h,c),o.child;case 11:return h=o.type,y=o.pendingProps,y=o.elementType===h?y:Wr(h,y),Cv(s,o,h,y,c);case 7:return nr(s,o,o.pendingProps,c),o.child;case 8:return nr(s,o,o.pendingProps.children,c),o.child;case 12:return nr(s,o,o.pendingProps.children,c),o.child;case 10:e:{if(h=o.type._context,y=o.pendingProps,x=o.memoizedProps,C=y.value,lt(hc,h._currentValue),h._currentValue=C,x!==null)if(qr(x.value,C)){if(x.children===y.children&&!ur.current){o=$n(s,o,c);break e}}else for(x=o.child,x!==null&&(x.return=o);x!==null;){var j=x.dependencies;if(j!==null){C=x.child;for(var A=j.firstContext;A!==null;){if(A.context===h){if(x.tag===1){A=Mn(-1,c&-c),A.tag=2;var V=x.updateQueue;if(V!==null){V=V.shared;var se=V.pending;se===null?A.next=A:(A.next=se.next,se.next=A),V.pending=A}}x.lanes|=c,A=x.alternate,A!==null&&(A.lanes|=c),sf(x.return,c,o),j.lanes|=c;break}A=A.next}}else if(x.tag===10)C=x.type===o.type?null:x.child;else if(x.tag===18){if(C=x.return,C===null)throw Error(r(341));C.lanes|=c,j=C.alternate,j!==null&&(j.lanes|=c),sf(C,c,o),C=x.sibling}else C=x.child;if(C!==null)C.return=x;else for(C=x;C!==null;){if(C===o){C=null;break}if(x=C.sibling,x!==null){x.return=C.return,C=x;break}C=C.return}x=C}nr(s,o,y.children,c),o=o.child}return o;case 9:return y=o.type,h=o.pendingProps.children,Zo(o,c),y=Ar(y),h=h(y),o.flags|=1,nr(s,o,h,c),o.child;case 14:return h=o.type,y=Wr(h,o.pendingProps),y=Wr(h.type,y),Rv(s,o,h,y,c);case 15:return Pv(s,o,o.type,o.pendingProps,c);case 17:return h=o.type,y=o.pendingProps,y=o.elementType===h?y:Wr(h,y),kc(s,o),o.tag=1,dr(h)?(s=!0,ac(o)):s=!1,Zo(o,c),bv(o,h,y),xf(o,h,y,c),kf(null,o,h,!0,s,c);case 19:return Mv(s,o,c);case 22:return jv(s,o,c)}throw Error(r(156,o.tag))};function ay(s,o){return Um(s,o)}function lk(s,o,c,h){this.tag=s,this.key=c,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=o,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=h,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Lr(s,o,c,h){return new lk(s,o,c,h)}function Wf(s){return s=s.prototype,!(!s||!s.isReactComponent)}function ck(s){if(typeof s=="function")return Wf(s)?1:0;if(s!=null){if(s=s.$$typeof,s===ue)return 11;if(s===Ae)return 14}return 2}function ms(s,o){var c=s.alternate;return c===null?(c=Lr(s.tag,o,s.key,s.mode),c.elementType=s.elementType,c.type=s.type,c.stateNode=s.stateNode,c.alternate=s,s.alternate=c):(c.pendingProps=o,c.type=s.type,c.flags=0,c.subtreeFlags=0,c.deletions=null),c.flags=s.flags&14680064,c.childLanes=s.childLanes,c.lanes=s.lanes,c.child=s.child,c.memoizedProps=s.memoizedProps,c.memoizedState=s.memoizedState,c.updateQueue=s.updateQueue,o=s.dependencies,c.dependencies=o===null?null:{lanes:o.lanes,firstContext:o.firstContext},c.sibling=s.sibling,c.index=s.index,c.ref=s.ref,c}function Dc(s,o,c,h,y,x){var C=2;if(h=s,typeof s=="function")Wf(s)&&(C=1);else if(typeof s=="string")C=5;else e:switch(s){case M:return no(c.children,y,x,o);case Y:C=8,y|=8;break;case ae:return s=Lr(12,c,o,y|2),s.elementType=ae,s.lanes=x,s;case je:return s=Lr(13,c,o,y),s.elementType=je,s.lanes=x,s;case le:return s=Lr(19,c,o,y),s.elementType=le,s.lanes=x,s;case re:return Mc(c,y,x,o);default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case he:C=10;break e;case Ee:C=9;break e;case ue:C=11;break e;case Ae:C=14;break e;case Te:C=16,h=null;break e}throw Error(r(130,s==null?s:typeof s,""))}return o=Lr(C,c,o,y),o.elementType=s,o.type=h,o.lanes=x,o}function no(s,o,c,h){return s=Lr(7,s,h,o),s.lanes=c,s}function Mc(s,o,c,h){return s=Lr(22,s,h,o),s.elementType=re,s.lanes=c,s.stateNode={isHidden:!1},s}function Hf(s,o,c){return s=Lr(6,s,null,o),s.lanes=c,s}function Kf(s,o,c){return o=Lr(4,s.children!==null?s.children:[],s.key,o),o.lanes=c,o.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},o}function uk(s,o,c,h,y){this.tag=o,this.containerInfo=s,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wd(0),this.expirationTimes=wd(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wd(0),this.identifierPrefix=h,this.onRecoverableError=y,this.mutableSourceEagerHydrationData=null}function Gf(s,o,c,h,y,x,C,j,A){return s=new uk(s,o,c,j,A),o===1?(o=1,x===!0&&(o|=8)):o=0,x=Lr(3,null,null,o),s.current=x,x.stateNode=s,x.memoizedState={element:h,isDehydrated:c,cache:null,transitions:null,pendingSuspenseBoundaries:null},af(x),s}function dk(s,o,c){var h=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:I,key:h==null?null:""+h,children:s,containerInfo:o,implementation:c}}function ly(s){if(!s)return is;s=s._reactInternals;e:{if(Ws(s)!==s||s.tag!==1)throw Error(r(170));var o=s;do{switch(o.tag){case 3:o=o.stateNode.context;break e;case 1:if(dr(o.type)){o=o.stateNode.__reactInternalMemoizedMergedChildContext;break e}}o=o.return}while(o!==null);throw Error(r(171))}if(s.tag===1){var c=s.type;if(dr(c))return Dg(s,c,o)}return o}function cy(s,o,c,h,y,x,C,j,A){return s=Gf(c,h,!0,s,y,x,C,j,A),s.context=ly(null),c=s.current,h=sr(),y=hs(c),x=Mn(h,y),x.callback=o??null,cs(c,x,y),s.current.lanes=y,sa(s,y,h),pr(s,h),s}function $c(s,o,c,h){var y=o.current,x=sr(),C=hs(y);return c=ly(c),o.context===null?o.context=c:o.pendingContext=c,o=Mn(x,C),o.payload={element:s},h=h===void 0?null:h,h!==null&&(o.callback=h),s=cs(y,o,C),s!==null&&(Gr(s,y,C,x),mc(s,y,C)),C}function Fc(s){if(s=s.current,!s.child)return null;switch(s.child.tag){case 5:return s.child.stateNode;default:return s.child.stateNode}}function uy(s,o){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var c=s.retryLane;s.retryLane=c!==0&&c<o?c:o}}function Qf(s,o){uy(s,o),(s=s.alternate)&&uy(s,o)}function fk(){return null}var dy=typeof reportError=="function"?reportError:function(s){console.error(s)};function Yf(s){this._internalRoot=s}Uc.prototype.render=Yf.prototype.render=function(s){var o=this._internalRoot;if(o===null)throw Error(r(409));$c(s,o,null,null)},Uc.prototype.unmount=Yf.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var o=s.containerInfo;eo(function(){$c(null,s,null,null)}),o[An]=null}};function Uc(s){this._internalRoot=s}Uc.prototype.unstable_scheduleHydration=function(s){if(s){var o=Gm();s={blockedOn:null,target:s,priority:o};for(var c=0;c<ts.length&&o!==0&&o<ts[c].priority;c++);ts.splice(c,0,s),c===0&&Jm(s)}};function Jf(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function zc(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11&&(s.nodeType!==8||s.nodeValue!==" react-mount-point-unstable "))}function fy(){}function hk(s,o,c,h,y){if(y){if(typeof h=="function"){var x=h;h=function(){var V=Fc(C);x.call(V)}}var C=cy(o,h,s,0,null,!1,!1,"",fy);return s._reactRootContainer=C,s[An]=C.current,ya(s.nodeType===8?s.parentNode:s),eo(),C}for(;y=s.lastChild;)s.removeChild(y);if(typeof h=="function"){var j=h;h=function(){var V=Fc(A);j.call(V)}}var A=Gf(s,0,!1,null,null,!1,!1,"",fy);return s._reactRootContainer=A,s[An]=A.current,ya(s.nodeType===8?s.parentNode:s),eo(function(){$c(o,A,c,h)}),A}function Bc(s,o,c,h,y){var x=c._reactRootContainer;if(x){var C=x;if(typeof y=="function"){var j=y;y=function(){var A=Fc(C);j.call(A)}}$c(o,C,s,y)}else C=hk(c,o,s,y,h);return Fc(C)}Hm=function(s){switch(s.tag){case 3:var o=s.stateNode;if(o.current.memoizedState.isDehydrated){var c=na(o.pendingLanes);c!==0&&(bd(o,c|1),pr(o,Ct()),(Xe&6)===0&&(si=Ct()+500,as()))}break;case 13:eo(function(){var h=Dn(s,1);if(h!==null){var y=sr();Gr(h,s,1,y)}}),Qf(s,1)}},xd=function(s){if(s.tag===13){var o=Dn(s,134217728);if(o!==null){var c=sr();Gr(o,s,134217728,c)}Qf(s,134217728)}},Km=function(s){if(s.tag===13){var o=hs(s),c=Dn(s,o);if(c!==null){var h=sr();Gr(c,s,o,h)}Qf(s,o)}},Gm=function(){return it},Qm=function(s,o){var c=it;try{return it=s,o()}finally{it=c}},Mo=function(s,o,c){switch(o){case"input":if(Tt(s,c),o=c.name,c.type==="radio"&&o!=null){for(c=s;c.parentNode;)c=c.parentNode;for(c=c.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),o=0;o<c.length;o++){var h=c[o];if(h!==s&&h.form===s.form){var y=oc(h);if(!y)throw Error(r(90));J(h),Tt(h,y)}}}break;case"textarea":No(s,c);break;case"select":o=c.value,o!=null&&Dt(s,!!c.multiple,o,!1)}},et=Bf,at=eo;var pk={usingClientEntryPoint:!1,Events:[xa,Wo,oc,Dl,Ue,Bf]},La={findFiberByHostInstance:Hs,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},mk={bundleType:La.bundleType,version:La.version,rendererPackageName:La.rendererPackageName,rendererConfig:La.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:P.ReactCurrentDispatcher,findHostInstanceByFiber:function(s){return s=$m(s),s===null?null:s.stateNode},findFiberByHostInstance:La.findFiberByHostInstance||fk,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};
41if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var qc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!qc.isDisabled&&qc.supportsFiber)try{Ul=qc.inject(mk),pn=qc}catch{}}return mr.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=pk,mr.createPortal=function(s,o){var c=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Jf(o))throw Error(r(200));return dk(s,o,null,c)},mr.createRoot=function(s,o){if(!Jf(s))throw Error(r(299));var c=!1,h="",y=dy;return o!=null&&(o.unstable_strictMode===!0&&(c=!0),o.identifierPrefix!==void 0&&(h=o.identifierPrefix),o.onRecoverableError!==void 0&&(y=o.onRecoverableError)),o=Gf(s,1,!1,null,null,c,!1,h,y),s[An]=o.current,ya(s.nodeType===8?s.parentNode:s),new Yf(o)},mr.findDOMNode=function(s){if(s==null)return null;if(s.nodeType===1)return s;var o=s._reactInternals;if(o===void 0)throw typeof s.render=="function"?Error(r(188)):(s=Object.keys(s).join(","),Error(r(268,s)));return s=$m(o),s=s===null?null:s.stateNode,s},mr.flushSync=function(s){return eo(s)},mr.hydrate=function(s,o,c){if(!zc(o))throw Error(r(200));return Bc(null,s,o,!0,c)},mr.hydrateRoot=function(s,o,c){if(!Jf(s))throw Error(r(405));var h=c!=null&&c.hydratedSources||null,y=!1,x="",C=dy;if(c!=null&&(c.unstable_strictMode===!0&&(y=!0),c.identifierPrefix!==void 0&&(x=c.identifierPrefix),c.onRecoverableError!==void 0&&(C=c.onRecoverableError)),o=cy(o,null,s,1,c??null,y,!1,x,C),s[An]=o.current,ya(s),h)for(s=0;s<h.length;s++)c=h[s],y=c._getVersion,y=y(c._source),o.mutableSourceEagerHydrationData==null?o.mutableSourceEagerHydrationData=[c,y]:o.mutableSourceEagerHydrationData.push(c,y);return new Uc(o)},mr.render=function(s,o,c){if(!zc(o))throw Error(r(200));return Bc(null,s,o,!1,c)},mr.unmountComponentAtNode=function(s){if(!zc(s))throw Error(r(40));return s._reactRootContainer?(eo(function(){Bc(null,null,s,!1,function(){s._reactRootContainer=null,s[An]=null})}),!0):!1},mr.unstable_batchedUpdates=Bf,mr.unstable_renderSubtreeIntoContainer=function(s,o,c,h){if(!zc(c))throw Error(r(200));if(s==null||s._reactInternals===void 0)throw Error(r(38));return Bc(s,o,c,!1,h)},mr.version="18.3.1-next-f1338f8080-20240426",mr}var xy;function db(){if(xy)return th.exports;xy=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),th.exports=Sk(),th.exports}var _y;function Ek(){if(_y)return Wc;_y=1;var e=db();return Wc.createRoot=e.createRoot,Wc.hydrateRoot=e.hydrateRoot,Wc}var kk=Ek(),yl=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},po,Es,ki,tb,Tk=(tb=class extends yl{constructor(){super();De(this,po);De(this,Es);De(this,ki);ve(this,ki,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){L(this,Es)||this.setEventListener(L(this,ki))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,Es))==null||t.call(this),ve(this,Es,void 0))}setEventListener(t){var r;ve(this,ki,t),(r=L(this,Es))==null||r.call(this),ve(this,Es,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){L(this,po)!==t&&(ve(this,po,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof L(this,po)=="boolean"?L(this,po):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},po=new WeakMap,Es=new WeakMap,ki=new WeakMap,tb),Fp=new Tk,Ck={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},ks,$p,rb,Rk=(rb=class{constructor(){De(this,ks,Ck);De(this,$p,!1)}setTimeoutProvider(e){ve(this,ks,e)}setTimeout(e,t){return L(this,ks).setTimeout(e,t)}clearTimeout(e){L(this,ks).clearTimeout(e)}setInterval(e,t){return L(this,ks).setInterval(e,t)}clearInterval(e){L(this,ks).clearInterval(e)}},ks=new WeakMap,$p=new WeakMap,rb),uo=new Rk;function Pk(e){setTimeout(e,0)}var jk=typeof window>"u"||"Deno"in globalThis;function yr(){}function Ok(e,t){return typeof e=="function"?e(t):e}function Bh(e){return typeof e=="number"&&e>=0&&e!==1/0}function fb(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Ns(e,t){return typeof e=="function"?e(t):e}function Mr(e,t){return typeof e=="function"?e(t):e}function Sy(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:l,stale:u}=e;if(l){if(n){if(t.queryHash!==Up(l,t.options))return!1}else if(!Xa(t.queryKey,l))return!1}if(r!=="all"){const f=t.isActive();
41if(r==="active"&&!f||r==="inactive"&&f)return!1}return!(typeof u=="boolean"&&t.isStale()!==u||i&&i!==t.state.fetchStatus||a&&!a(t))}function Ey(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(Ja(t.options.mutationKey)!==Ja(a))return!1}else if(!Xa(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function Up(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ja)(e)}function Ja(e){return JSON.stringify(e,(t,r)=>Vh(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function Xa(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>Xa(e[r],t[r])):!1}var Ak=Object.prototype.hasOwnProperty;function hb(e,t,r=0){if(e===t)return e;if(r>500)return t;const n=ky(e)&&ky(t);if(!n&&!(Vh(e)&&Vh(t)))return t;const a=(n?e:Object.keys(e)).length,l=n?t:Object.keys(t),u=l.length,f=n?new Array(u):{};let p=0;for(let m=0;m<u;m++){const g=n?m:l[m],b=e[g],w=t[g];if(b===w){f[g]=b,(n?m<a:Ak.call(e,g))&&p++;continue}if(b===null||w===null||typeof b!="object"||typeof w!="object"){f[g]=w;continue}const S=hb(b,w,r+1);f[g]=S,S===b&&p++}return a===u&&p===a?e:f}function qh(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function ky(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Vh(e){if(!Ty(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!Ty(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Ty(e){return Object.prototype.toString.call(e)==="[object Object]"}function Nk(e){return new Promise(t=>{uo.setTimeout(t,e)})}function Wh(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?hb(e,t):t}function Ik(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function Lk(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var zp=Symbol();function pb(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===zp?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function mb(e,t){return typeof e=="function"?e(...t):!!e}function Dk(e,t,r){let n=!1,i;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(i??(i=t()),n||(n=!0,i.aborted?r():i.addEventListener("abort",r,{once:!0})),i)}),e}var Za=(()=>{let e=()=>jk;return{isServer(){return e()},setIsServer(t){e=t}}})();function Hh(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}var Mk=Pk;function $k(){let e=[],t=0,r=u=>{u()},n=u=>{u()},i=Mk;const a=u=>{t?e.push(u):i(()=>{r(u)})},l=()=>{const u=e;e=[],u.length&&i(()=>{n(()=>{u.forEach(f=>{r(f)})})})};return{batch:u=>{let f;t++;try{f=u()}finally{t--,t||l()}return f},batchCalls:u=>(...f)=>{a(()=>{u(...f)})},schedule:a,setNotifyFunction:u=>{r=u},setBatchNotifyFunction:u=>{n=u},setScheduler:u=>{i=u}}}var Kt=$k(),Ti,Ts,Ci,nb,Fk=(nb=class extends yl{constructor(){super();De(this,Ti,!0);De(this,Ts);De(this,Ci);ve(this,Ci,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){L(this,Ts)||this.setEventListener(L(this,Ci))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,Ts))==null||t.call(this),ve(this,Ts,void 0))}setEventListener(t){var r;ve(this,Ci,t),(r=L(this,Ts))==null||r.call(this),ve(this,Ts,t(this.setOnline.bind(this)))}setOnline(t){L(this,Ti)!==t&&(ve(this,Ti,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return L(this,Ti)}},Ti=new WeakMap,Ts=new WeakMap,Ci=new WeakMap,nb),bu=new Fk;function Uk(e){return Math.min(1e3*2**e,3e4)}function gb(e){return(e??"online")==="online"?bu.isOnline():!0}
vendor: 5,150 bytes, line 41
41var Kh=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function vb(e){let t=!1,r=0,n;const i=Hh(),a=()=>i.status!=="pending",l=_=>{var E;if(!a()){const k=new Kh(_);b(k),(E=e.onCancel)==null||E.call(e,k)}},u=()=>{t=!0},f=()=>{t=!1},p=()=>Fp.isFocused()&&(e.networkMode==="always"||bu.isOnline())&&e.canRun(),m=()=>gb(e.networkMode)&&e.canRun(),g=_=>{a()||(n==null||n(),i.resolve(_))},b=_=>{a()||(n==null||n(),i.reject(_))},w=()=>new Promise(_=>{var E;n=k=>{(a()||p())&&_(k)},(E=e.onPause)==null||E.call(e)}).then(()=>{var _;n=void 0,a()||(_=e.onContinue)==null||_.call(e)}),S=()=>{if(a())return;let _;const E=r===0?e.initialPromise:void 0;try{_=E??e.fn()}catch(k){_=Promise.reject(k)}Promise.resolve(_).then(g).catch(k=>{var I;if(a())return;const T=e.retry??(Za.isServer()?0:3),R=e.retryDelay??Uk,P=typeof R=="function"?R(r,k):R,O=T===!0||typeof T=="number"&&r<T||typeof T=="function"&&T(r,k);if(t||!O){b(k);return}r++,(I=e.onFail)==null||I.call(e,r,k),Nk(P).then(()=>p()?void 0:w()).then(()=>{t?b(k):S()})})};return{promise:i,status:()=>i.status,cancel:l,continue:()=>(n==null||n(),i),cancelRetry:u,continueRetry:f,canStart:m,start:()=>(m()?S():w().then(S),i)}}var mo,sb,yb=(sb=class{constructor(){De(this,mo)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Bh(this.gcTime)&&ve(this,mo,uo.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Za.isServer()?1/0:300*1e3))}clearGcTimeout(){L(this,mo)&&(uo.clearTimeout(L(this,mo)),ve(this,mo,void 0))}},mo=new WeakMap,sb),go,Ri,Dr,vo,Ut,hl,yo,Tr,wb,zn,ob,zk=(ob=class extends yb{constructor(t){super();De(this,Tr);De(this,go);De(this,Ri);De(this,Dr);De(this,vo);De(this,Ut);De(this,hl);De(this,yo);ve(this,yo,!1),ve(this,hl,t.defaultOptions),this.setOptions(t.options),this.observers=[],ve(this,vo,t.client),ve(this,Dr,L(this,vo).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,ve(this,go,Ry(this.options)),this.state=t.state??L(this,go),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=L(this,Ut))==null?void 0:t.promise}setOptions(t){if(this.options={...L(this,hl),...t},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const r=Ry(this.options);r.data!==void 0&&(this.setState(Cy(r.data,r.dataUpdatedAt)),ve(this,go,r))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&L(this,Dr).remove(this)}setData(t,r){const n=Wh(this.state.data,t,this.options);return Ke(this,Tr,zn).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){Ke(this,Tr,zn).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=L(this,Ut))==null?void 0:n.promise;return(i=L(this,Ut))==null||i.cancel(t),r?r.then(yr).catch(yr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return L(this,go)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(t=>Mr(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===zp||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Ns(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!fb(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=L(this,Ut))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=L(this,Ut))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),L(this,Dr).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(L(this,Ut)&&(L(this,yo)||Ke(this,Tr,wb).call(this)?L(this,Ut).cancel({revert:!0}):L(this,Ut).cancelRetry()),this.scheduleGc()),L(this,Dr).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ke(this,Tr,zn).call(this,{type:"invalidate"})}async fetch(t,r){var f,p,m,g,b,w,S,_,E,k,T,R;if(this.state.fetchStatus!=="idle"&&((f=L(this,Ut))==null?void 0:f.status())!=="rejected"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(L(this,Ut))return L(this,Ut).continueRetry(),L(this,Ut).promise}if(t&&this.setOptions(t),!this.options.queryFn){const P=this.observers.find(O=>O.options.queryFn);P&&this.setOptions(P.options)}const n=new AbortController,i=P=>{Object.defineProperty(P,"signal",{enumerable:!0,get:()=>(ve(this,yo,!0),n.signal)}
41)},a=()=>{const P=pb(this.options,r),I=(()=>{const M={client:L(this,vo),queryKey:this.queryKey,meta:this.meta};return i(M),M})();return ve(this,yo,!1),this.options.persister?this.options.persister(P,I,this):P(I)},u=(()=>{const P={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:L(this,vo),state:this.state,fetchFn:a};return i(P),P})();(p=this.options.behavior)==null||p.onFetch(u,this),ve(this,Ri,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((m=u.fetchOptions)==null?void 0:m.meta))&&Ke(this,Tr,zn).call(this,{type:"fetch",meta:(g=u.fetchOptions)==null?void 0:g.meta}),ve(this,Ut,vb({initialPromise:r==null?void 0:r.initialPromise,fn:u.fetchFn,onCancel:P=>{P instanceof Kh&&P.revert&&this.setState({...L(this,Ri),fetchStatus:"idle"}),n.abort()},onFail:(P,O)=>{Ke(this,Tr,zn).call(this,{type:"failed",failureCount:P,error:O})},onPause:()=>{Ke(this,Tr,zn).call(this,{type:"pause"})},onContinue:()=>{Ke(this,Tr,zn).call(this,{type:"continue"})},retry:u.options.retry,retryDelay:u.options.retryDelay,networkMode:u.options.networkMode,canRun:()=>!0}));try{const P=await L(this,Ut).start();if(P===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(P),(w=(b=L(this,Dr).config).onSuccess)==null||w.call(b,P,this),(_=(S=L(this,Dr).config).onSettled)==null||_.call(S,P,this.state.error,this),P}catch(P){if(P instanceof Kh){if(P.silent)return L(this,Ut).promise;if(P.revert){if(this.state.data===void 0)throw P;return this.state.data}}throw Ke(this,Tr,zn).call(this,{type:"error",error:P}),(k=(E=L(this,Dr).config).onError)==null||k.call(E,P,this),(R=(T=L(this,Dr).config).onSettled)==null||R.call(T,this.state.data,P,this),P}finally{this.scheduleGc()}}},go=new WeakMap,Ri=new WeakMap,Dr=new WeakMap,vo=new WeakMap,Ut=new WeakMap,hl=new WeakMap,yo=new WeakMap,Tr=new WeakSet,wb=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},zn=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...bb(n.data,this.options),fetchMeta:t.meta??null};case"success":const i={...n,...Cy(t.data,t.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return ve(this,Ri,t.manual?i:void 0),i;case"error":const a=t.error;return{...n,error:a,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Kt.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),L(this,Dr).notify({query:this,type:"updated",action:t})})},ob);function bb(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:gb(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Cy(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function Ry(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var gr,Ye,pl,or,wo,Pi,Vn,Cs,ml,ji,Oi,bo,xo,Rs,Ai,st,Wa,Gh,Qh,Yh,Jh,Xh,Zh,ep,xb,ib,Bk=(ib=class extends yl{constructor(t,r){super();De(this,st);De(this,gr);De(this,Ye);De(this,pl);De(this,or);De(this,wo);De(this,Pi);De(this,Vn);De(this,Cs);De(this,ml);De(this,ji);De(this,Oi);De(this,bo);De(this,xo);De(this,Rs);De(this,Ai,new Set);this.options=r,ve(this,gr,t),ve(this,Cs,null),ve(this,Vn,Hh()),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(L(this,Ye).addObserver(this),Py(L(this,Ye),this.options)?Ke(this,st,Wa).call(this):this.updateResult(),Ke(this,st,Jh).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return tp(L(this,Ye),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return tp(L(this,Ye),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Ke(this,st,Xh).call(this),Ke(this,st,Zh).call(this),L(this,Ye).removeObserver(this)}setOptions(t){const r=this.options,n=L(this,Ye);if(this.options=L(this,gr).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Mr(this.options.enabled,L(this,Ye))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Ke(this,st,ep).call(this),L(this,Ye).setOptions(this.options),r._defaulted&&!qh(this.options,r)&&L(this,gr).getQueryCache().notify({type:"observerOptionsUpdated",query:L(this,Ye),observer:this});const i=this.hasListeners();i&&jy(L(this,Ye),n,this.options,r)&&Ke(this,st,Wa).call(this),this.updateResult(),i&&(L(this,Ye)!==n||Mr(this.options.enabled,L(this,Ye))!==Mr(r.enabled,L(this,Ye))||Ns(this.options.staleTime,L(this,Ye))!==Ns(r.staleTime,L(this,Ye)))&&Ke(this,st,Gh).call(this);const a=Ke(this,st,Qh).call(this);i&&(L(this,Ye)!==n||Mr(this.options.enabled,L(this,Ye))!==Mr(r.enabled,L(this,Ye))||a!==L(this,Rs))&&Ke(this,st,Yh).call(this,a)}getOptimisticResult(t){const r=L(this,gr).getQueryCache().build(L(this,gr),t),n=this.createResult(r,t);return Vk(this,n)&&(ve(this,or,n),ve(this,Pi,this.options),ve(this,wo,L(this,Ye).state)),n}getCurrentResult(){return L(this,or)}trackResult(t,r){return new Proxy(t,{get:(n,i)=>(this.trackProp(i),r==null||r(i),i==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&L(this,Vn).status==="pending"&&L(this,Vn).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,i))})}trackProp(t){L(this,Ai).add(t)}getCurrentQuery(){return L(this,Ye)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=L(this,gr).defaultQueryOptions(t),n=L(this,gr).getQueryCache().build(L(this,gr),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return Ke(this,st,Wa).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),L(this,or)))}createResult(t,r){var ae;const n=L(this,Ye),i=this.options,a=L(this,or),l=L(this,wo),u=L(this,Pi),p=t!==n?t.state:L(this,pl),{state:m}=t;let g={...m},b=!1,w;if(r._optimisticResults){const he=this.hasListeners(),Ee=!he&&Py(t,r),ue=he&&jy(t,n,r,i);(Ee||ue)&&(g={...g,...bb(m.data,t.options)}),r._optimisticResults==="isRestoring"&&(g.fetchStatus="idle")}let{error:S,errorUpdatedAt:_,status:E}=g;w=g.data;let k=!1;if(r.placeholderData!==void 0&&w===void 0&&E==="pending"){let he;a!=null&&a.isPlaceholderData&&r.placeholderData===(u==null?void 0:u.placeholderData)?(he=a.data,k=!0):he=typeof r.placeholderData=="function"?r.placeholderData((ae=L(this,Oi))==null?void 0:ae.state.data,L(this,Oi)):r.placeholderData,he!==void 0&&(E="success",w=Wh(a==null?void 0:a.data,he,r),b=!0)}if(r.select&&w!==void 0&&!k)if(a&&w===(l==null?void 0:l.data)&&r.select===L(this,ml))w=L(this,ji);else try{ve(this,ml,r.select),w=r.select(w),w=Wh(a==null?void 0:a.data,w,r),ve(this,ji,w),ve(this,Cs,null)}catch(he){ve(this,Cs,he)}L(this,Cs)&&(S=L(this,Cs),w=L(this,ji),_=Date.now(),E="error");const T=g.fetchStatus==="fetching",R=E==="pending",P=E==="error",O=R&&T,I=w!==void 0,Y={status:E,fetchStatus:g.fetchStatus,isPending:R,isSuccess:E==="success",isError:P,isInitialLoading:O,isLoading:O,data:w,dataUpdatedAt:g.dataUpdatedAt,error:S,errorUpdatedAt:_,failureCount:g.fetchFailureCount,failureReason:g.fetchFailureReason,errorUpdate
vendor: 4,753 bytes, line 41
41Count:g.errorUpdateCount,isFetched:t.isFetched(),isFetchedAfterMount:g.dataUpdateCount>p.dataUpdateCount||g.errorUpdateCount>p.errorUpdateCount,isFetching:T,isRefetching:T&&!R,isLoadingError:P&&!I,isPaused:g.fetchStatus==="paused",isPlaceholderData:b,isRefetchError:P&&I,isStale:Bp(t,r),refetch:this.refetch,promise:L(this,Vn),isEnabled:Mr(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const he=Y.data!==void 0,Ee=Y.status==="error"&&!he,ue=Ae=>{Ee?Ae.reject(Y.error):he&&Ae.resolve(Y.data)},je=()=>{const Ae=ve(this,Vn,Y.promise=Hh());ue(Ae)},le=L(this,Vn);switch(le.status){case"pending":t.queryHash===n.queryHash&&ue(le);break;case"fulfilled":(Ee||Y.data!==le.value)&&je();break;case"rejected":(!Ee||Y.error!==le.reason)&&je();break}}return Y}updateResult(){const t=L(this,or),r=this.createResult(L(this,Ye),this.options);if(ve(this,wo,L(this,Ye).state),ve(this,Pi,this.options),L(this,wo).data!==void 0&&ve(this,Oi,L(this,Ye)),qh(r,t))return;ve(this,or,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!L(this,Ai).size)return!0;const l=new Set(a??L(this,Ai));return this.options.throwOnError&&l.add("error"),Object.keys(L(this,or)).some(u=>{const f=u;return L(this,or)[f]!==t[f]&&l.has(f)})};Ke(this,st,xb).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Ke(this,st,Jh).call(this)}},gr=new WeakMap,Ye=new WeakMap,pl=new WeakMap,or=new WeakMap,wo=new WeakMap,Pi=new WeakMap,Vn=new WeakMap,Cs=new WeakMap,ml=new WeakMap,ji=new WeakMap,Oi=new WeakMap,bo=new WeakMap,xo=new WeakMap,Rs=new WeakMap,Ai=new WeakMap,st=new WeakSet,Wa=function(t){Ke(this,st,ep).call(this);let r=L(this,Ye).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(yr)),r},Gh=function(){Ke(this,st,Xh).call(this);const t=Ns(this.options.staleTime,L(this,Ye));if(Za.isServer()||L(this,or).isStale||!Bh(t))return;const n=fb(L(this,or).dataUpdatedAt,t)+1;ve(this,bo,uo.setTimeout(()=>{L(this,or).isStale||this.updateResult()},n))},Qh=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(L(this,Ye)):this.options.refetchInterval)??!1},Yh=function(t){Ke(this,st,Zh).call(this),ve(this,Rs,t),!(Za.isServer()||Mr(this.options.enabled,L(this,Ye))===!1||!Bh(L(this,Rs))||L(this,Rs)===0)&&ve(this,xo,uo.setInterval(()=>{(this.options.refetchIntervalInBackground||Fp.isFocused())&&Ke(this,st,Wa).call(this)},L(this,Rs)))},Jh=function(){Ke(this,st,Gh).call(this),Ke(this,st,Yh).call(this,Ke(this,st,Qh).call(this))},Xh=function(){L(this,bo)&&(uo.clearTimeout(L(this,bo)),ve(this,bo,void 0))},Zh=function(){L(this,xo)&&(uo.clearInterval(L(this,xo)),ve(this,xo,void 0))},ep=function(){const t=L(this,gr).getQueryCache().build(L(this,gr),this.options);if(t===L(this,Ye))return;const r=L(this,Ye);ve(this,Ye,t),ve(this,pl,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},xb=function(t){Kt.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(L(this,or))}),L(this,gr).getQueryCache().notify({query:L(this,Ye),type:"observerResultsUpdated"})})},ib);function qk(e,t){return Mr(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Py(e,t){return qk(e,t)||e.state.data!==void 0&&tp(e,t,t.refetchOnMount)}function tp(e,t,r){if(Mr(t.enabled,e)!==!1&&Ns(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&Bp(e,t)}return!1}function jy(e,t,r,n){return(e!==t||Mr(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&Bp(e,r)}function Bp(e,t){return Mr(t.enabled,e)!==!1&&e.isStaleByTime(Ns(t.staleTime,e))}function Vk(e,t){return!qh(e.getCurrentResult(),t)}function Oy(e){return{onFetch:(t,r)=>{var m,g,b,w,S;const n=t.options,i=(b=(g=(m=t.fetchOptions)==null?void 0:m.meta)==null?void 0:g.fetchMore)==null?void 0:b.direction,a=((w=t.state.data)==null?void 0:w.pages)||[],l=((S=t.state.data)==null?void 0:S.pageParams)||[];let u={pages:[],pageParams:[]},f=0;const p=async()=>{let _=!1;const E=R=>{Dk(R,()=>t.signal,()=>_=!0)},k=pb(t.options,t.fetchOptions),T=async(R,P,O)=>{if(_)return Promise.reject();if(P==null&&R.pages.length)return Promise.resolve(R);const M=(()=>{const Ee={client:t.client,queryKey:t.queryKey,pageParam:P,direction:O?"backward":"forward",meta:t.options.meta};return E(Ee),Ee})(),Y=await k(M),{maxPages:ae}=t.options,he=O?Lk:Ik;return{pages:he(R.pages,Y,ae),pageParams:he(R.pageParams,P,ae)}};if(i&&a.length){const R=i==="backward",P=R?Wk:Ay,O={pages:a,pageParams:l},I=P(n,O);u=await T(O,I,R)}else{const R=e??a.length;do{const P=f===0?l[0]??n.initialPageParam:Ay(n,u);if(f>0&&P==null)break;u=await T(u,P),f++}while(f<R)}return u};t.options.persister?t.fetchFn=()=>{var _,E;
41return(E=(_=t.options).persister)==null?void 0:E.call(_,p,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=p}}}function Ay(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function Wk(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var gl,bn,Zt,_o,xn,ws,ab,Hk=(ab=class extends yb{constructor(t){super();De(this,xn);De(this,gl);De(this,bn);De(this,Zt);De(this,_o);ve(this,gl,t.client),this.mutationId=t.mutationId,ve(this,Zt,t.mutationCache),ve(this,bn,[]),this.state=t.state||Kk(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){L(this,bn).includes(t)||(L(this,bn).push(t),this.clearGcTimeout(),L(this,Zt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){ve(this,bn,L(this,bn).filter(r=>r!==t)),this.scheduleGc(),L(this,Zt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){L(this,bn).length||(this.state.status==="pending"?this.scheduleGc():L(this,Zt).remove(this))}continue(){var t;return((t=L(this,_o))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var l,u,f,p,m,g,b,w,S,_,E,k,T,R,P,O,I,M;const r=()=>{Ke(this,xn,ws).call(this,{type:"continue"})},n={client:L(this,gl),meta:this.options.meta,mutationKey:this.options.mutationKey};ve(this,_o,vb({fn:()=>this.options.mutationFn?this.options.mutationFn(t,n):Promise.reject(new Error("No mutationFn found")),onFail:(Y,ae)=>{Ke(this,xn,ws).call(this,{type:"failed",failureCount:Y,error:ae})},onPause:()=>{Ke(this,xn,ws).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>L(this,Zt).canRun(this)}));const i=this.state.status==="pending",a=!L(this,_o).canStart();try{if(i)r();else{Ke(this,xn,ws).call(this,{type:"pending",variables:t,isPaused:a}),L(this,Zt).config.onMutate&&await L(this,Zt).config.onMutate(t,this,n);const ae=await((u=(l=this.options).onMutate)==null?void 0:u.call(l,t,n));ae!==this.state.context&&Ke(this,xn,ws).call(this,{type:"pending",context:ae,variables:t,isPaused:a})}const Y=await L(this,_o).start();return await((p=(f=L(this,Zt).config).onSuccess)==null?void 0:p.call(f,Y,t,this.state.context,this,n)),await((g=(m=this.options).onSuccess)==null?void 0:g.call(m,Y,t,this.state.context,n)),await((w=(b=L(this,Zt).config).onSettled)==null?void 0:w.call(b,Y,null,this.state.variables,this.state.context,this,n)),await((_=(S=this.options).onSettled)==null?void 0:_.call(S,Y,null,t,this.state.context,n)),Ke(this,xn,ws).call(this,{type:"success",data:Y}),Y}catch(Y){try{await((k=(E=L(this,Zt).config).onError)==null?void 0:k.call(E,Y,t,this.state.context,this,n))}catch(ae){Promise.reject(ae)}try{await((R=(T=this.options).onError)==null?void 0:R.call(T,Y,t,this.state.context,n))}catch(ae){Promise.reject(ae)}try{await((O=(P=L(this,Zt).config).onSettled)==null?void 0:O.call(P,void 0,Y,this.state.variables,this.state.context,this,n))}catch(ae){Promise.reject(ae)}try{await((M=(I=this.options).onSettled)==null?void 0:M.call(I,void 0,Y,t,this.state.context,n))}catch(ae){Promise.reject(ae)}throw Ke(this,xn,ws).call(this,{type:"error",error:Y}),Y}finally{L(this,Zt).runNext(this)}}},gl=new WeakMap,bn=new WeakMap,Zt=new WeakMap,_o=new WeakMap,xn=new WeakSet,ws=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Kt.batch(()=>
41{L(this,bn).forEach(n=>{n.onMutationUpdate(t)}),L(this,Zt).notify({mutation:this,type:"updated",action:t})})},ab);function Kk(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Wn,Xr,vl,lb,Gk=(lb=class extends yl{constructor(t={}){super();De(this,Wn);De(this,Xr);De(this,vl);this.config=t,ve(this,Wn,new Set),ve(this,Xr,new Map),ve(this,vl,0)}build(t,r,n){const i=new Hk({client:t,mutationCache:this,mutationId:++Vc(this,vl)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){L(this,Wn).add(t);const r=Hc(t);if(typeof r=="string"){const n=L(this,Xr).get(r);n?n.push(t):L(this,Xr).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(L(this,Wn).delete(t)){const r=Hc(t);if(typeof r=="string"){const n=L(this,Xr).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&L(this,Xr).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=Hc(t);if(typeof r=="string"){const n=L(this,Xr).get(r),i=n==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n;const r=Hc(t);if(typeof r=="string"){const i=(n=L(this,Xr).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Kt.batch(()=>{L(this,Wn).forEach(t=>{this.notify({type:"removed",mutation:t})}),L(this,Wn).clear(),L(this,Xr).clear()})}getAll(){return Array.from(L(this,Wn))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>Ey(r,n))}findAll(t={}){return this.getAll().filter(r=>Ey(t,r))}notify(t){Kt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>
vendor: 5,767 bytes, line 41
41r.state.isPaused);return Kt.batch(()=>Promise.all(t.map(r=>r.continue().catch(yr))))}},Wn=new WeakMap,Xr=new WeakMap,vl=new WeakMap,lb);function Hc(e){var t;return(t=e.options.scope)==null?void 0:t.id}var _n,cb,Qk=(cb=class extends yl{constructor(t={}){super();De(this,_n);this.config=t,ve(this,_n,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??Up(i,r);let l=this.get(a);return l||(l=new zk({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(l)),l}add(t){L(this,_n).has(t.queryHash)||(L(this,_n).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=L(this,_n).get(t.queryHash);r&&(t.destroy(),r===t&&L(this,_n).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Kt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return L(this,_n).get(t)}getAll(){return[...L(this,_n).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>Sy(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>Sy(t,n)):r}notify(t){Kt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Kt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Kt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},_n=new WeakMap,cb),Et,Ps,js,Ni,Ii,Os,Li,Di,ub,Yk=(ub=class{constructor(e={}){De(this,Et);De(this,Ps);De(this,js);De(this,Ni);De(this,Ii);De(this,Os);De(this,Li);De(this,Di);ve(this,Et,e.queryCache||new Qk),ve(this,Ps,e.mutationCache||new Gk),ve(this,js,e.defaultOptions||{}),ve(this,Ni,new Map),ve(this,Ii,new Map),ve(this,Os,0)}mount(){Vc(this,Os)._++,L(this,Os)===1&&(ve(this,Li,Fp.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,Et).onFocus())})),ve(this,Di,bu.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,Et).onOnline())})))}unmount(){var e,t;Vc(this,Os)._--,L(this,Os)===0&&((e=L(this,Li))==null||e.call(this),ve(this,Li,void 0),(t=L(this,Di))==null||t.call(this),ve(this,Di,void 0))}isFetching(e){return L(this,Et).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return L(this,Ps).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=L(this,Et).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=L(this,Et).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Ns(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return L(this,Et).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),i=L(this,Et).get(n.queryHash),a=i==null?void 0:i.state.data,l=Ok(t,a);if(l!==void 0)return L(this,Et).build(this,n).setData(l,{...r,manual:!0})}setQueriesData(e,t,r){return Kt.batch(()=>L(this,Et).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=L(this,Et).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=L(this,Et);Kt.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=L(this,Et);return Kt.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Kt.batch(()=>L(this,Et).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(yr).catch(yr)}invalidateQueries(e,t={}){return Kt.batch(()=>(L(this,Et).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Kt.batch(()=>L(this,Et).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(yr)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(yr)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=L(this,Et).build(this,t);return r.isStaleByTime(Ns(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(yr).catch(yr)}fetchInfiniteQuery(e){return e.behavior=Oy(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(yr).catch(yr)}ensureInfiniteQueryData(e){return e.behavior=Oy(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return bu.isOnline()?L(this,Ps).resumePausedMutations():Promise.resolve()}getQueryCache(){return L(this,Et)}getMutationCache(){return L(this,Ps)}getDefaultOptions(){return L(this,js)}setDefaultOptions(e){ve(this,js,e)}setQueryDefaults(e,t){L(this,Ni).set(Ja(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...L(this,Ni).values()],r={};return t.forEach(n=>{Xa(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){L(this,Ii).set(Ja(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...L(this,Ii).values()],r={};return t.forEach(n=>{Xa(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...L(this,js).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Up(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===zp&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...L(this,js).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}
41clear(){L(this,Et).clear(),L(this,Ps).clear()}},Et=new WeakMap,Ps=new WeakMap,js=new WeakMap,Ni=new WeakMap,Ii=new WeakMap,Os=new WeakMap,Li=new WeakMap,Di=new WeakMap,ub),v=$u();const G=Co(v),Fu=vk({__proto__:null,default:G},[v]);var _b=v.createContext(void 0),qp=e=>{const t=v.useContext(_b);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Jk=({client:e,children:t})=>(v.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),d.jsx(_b.Provider,{value:e,children:t})),Sb=v.createContext(!1),Xk=()=>v.useContext(Sb);Sb.Provider;function Zk(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var eT=v.createContext(Zk()),tT=()=>v.useContext(eT),rT=(e,t,r)=>{const n=r!=null&&r.state.error&&typeof e.throwOnError=="function"?mb(e.throwOnError,[r.state.error,r]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||n)&&(t.isReset()||(e.retryOnMount=!1))},nT=e=>{v.useEffect(()=>{e.clearReset()},[e])},sT=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||mb(r,[e.error,n])),oT=e=>{if(e.suspense){const r=i=>i==="static"?i:Math.max(i??1e3,1e3),n=e.staleTime;e.staleTime=typeof n=="function"?(...i)=>r(n(...i)):r(n),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},iT=(e,t)=>e.isLoading&&e.isFetching&&!t,aT=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,Ny=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function lT(e,t,r){var b,w,S,_;const n=Xk(),i=tT(),a=qp(),l=a.defaultQueryOptions(e);(w=(b=a.getDefaultOptions().queries)==null?void 0:b._experimental_beforeQuery)==null||w.call(b,l);const u=a.getQueryCache().get(l.queryHash);l._optimisticResults=n?"isRestoring":"optimistic",oT(l),rT(l,i,u),nT(i);const f=!a.getQueryCache().get(l.queryHash),[p]=v.useState(()=>new t(a,l)),m=p.getOptimisticResult(l),g=!n&&e.subscribed!==!1;if(v.useSyncExternalStore(v.useCallback(E=>{const k=g?p.subscribe(Kt.batchCalls(E)):yr;return p.updateResult(),k},[p,g]),()=>p.getCurrentResult(),()=>p.getCurrentResult()),v.useEffect(()=>{p.setOptions(l)},[l,p]),aT(l,m))throw Ny(l,p,i);if(sT({result:m,errorResetBoundary:i,throwOnError:l.throwOnError,query:u,suspense:l.suspense}))throw m.error;if((_=(S=a.getDefaultOptions().queries)==null?void 0:S._experimental_afterQuery)==null||_.call(S,l,m),l.experimental_prefetchInRender&&!Za.isServer()&&iT(m,n)){const E=f?Ny(l,p,i):u==null?void 0:u.promise;E==null||E.catch(yr).finally(()=>{p.updateResult()})}return l.notifyOnChangeProps?m:p.trackResult(m)}function Eb(e,t){return lT(e,Bk)}var Is=db();const wi=Co(Is);/**
42 * @remix-run/router v1.23.3
43 *
44 * Copyright (c) Remix Software Inc.
45 *
46 * This source code is licensed under the MIT license found in the
47 * LICENSE.md file in the root directory of this source tree.
48 *
49 * @license MIT
50 */function el(){return el=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},el.apply(null,arguments)}var As;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(As||(As={}));const Iy="popstate";function cT(e){e===void 0&&(e={});function t(n,i){let{pathname:a,search:l,hash:u}=n.location;return rp("",{pathname:a,search:l,hash:u},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function r(n,i){return typeof i=="string"?i:xu(i)}return dT(t,r,null,e)}function Ot(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Vp(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function uT(){return Math.random().toString(36).substr(2,8)}function Ly(e,t){return{usr:e.state,key:e.key,idx:t}}function rp(e,t,r,n){return r===void 0&&(r=null),el({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?qi(t):t,{state:r,key:t&&t.key||n||uT()})}function xu(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function qi(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function dT(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:a=!1}=n,l=i.history,u=As.Pop,f=null,p=m();p==null&&(p=0,l.replaceState(el({},l.state,{idx:p}),""));function m(){return(l.state||{idx:null}).idx}function g(){u=As.Pop;let E=m(),k=E==null?null:E-p;p=E,f&&f({action:u,location:_.location,delta:k})}function b(E,k){u=As.Push;let T=rp(_.location,E,k);p=m()+1;let R=Ly(T,p),P=_.createHref(T);try{l.pushState(R,"",P)}catch(O){if(O instanceof DOMException&&O.name==="DataCloneError")throw O;i.location.assign(P)}a&&f&&f({action:u,location:_.location,delta:1})}function w(E,k){u=As.Replace;let T=rp(_.location,E,k);p=m();let R=Ly(T,p),P=_.createHref(T);l.replaceState(R,"",P),a&&f&&f({action:u,location:_.location,delta:0})}function S(E){let k=i.location.origin!=="null"?i.location.origin:i.location.href,T=typeof E=="string"?E:xu(E);return T=T.replace(/ $/,"%20"),Ot(k,"No window.location.(origin|href) available to create URL for href: "+T),new URL(T,k)}let _={get action(){return u},get location(){return e(i,l)},listen(E){if(f)throw new Error("A history only accepts one active listener");return i.addEventListener(Iy,g),f=E,()=>{i.removeEventListener(Iy,g),f=null}},createHref(E){return t(i,E)},createURL:S,encodeLocation(E){let k=S(E);return{pathname:k.pathname,search:k.search,hash:k.hash}},push:b,replace:w,go(E){return l.go(E)}};return _}var Dy;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Dy||(Dy={}));function fT(e,t,r){return r===void 0&&(r="/"),hT(e,t,r)}function hT(e,t,r,n){let i=typeof t=="string"?qi(t):t,a=Wp(i.pathname||"/",r);if(a==null)return null;let l=kb(e);pT(l);let u=null,f=TT(a);for(let p=0;u==null&&p<l.length;++p)u=ST(l[p],f);return u}function kb(e,t,r,n){t===void 0&&(t=[]),r===void 0&&(r=[]),n===void 0&&(n="");let i=(a,l,u)=>{let f={relativePath:u===void 0?a.path||"":u,caseSensitive:a.caseSensitive===!0,childrenIndex:l,route:a};f.relativePath.startsWith("/")&&(Ot(f.relativePath.startsWith(n),'Absolute route path "'+f.relativePath+'" nested under path '+('"'+n+'" is not val
50id. An absolute child route path ')+"must start with the combined path of all its parent routes."),f.relativePath=f.relativePath.slice(n.length));let p=Ls([n,f.relativePath]),m=r.concat(f);a.children&&a.children.length>0&&(Ot(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+p+'".')),kb(a.children,t,m,p)),!(a.path==null&&!a.index)&&t.push({path:p,score:xT(p,a.index),routesMeta:m})};return e.forEach((a,l)=>{var u;if(a.path===""||!((u=a.path)!=null&&u.includes("?")))i(a,l);else for(let f of Tb(a.path))i(a,l,f)}),t}function Tb(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),a=r.replace(/\?$/,"");if(n.length===0)return i?[a,""]:[a];let l=Tb(n.join("/")),u=[];return u.push(...l.map(f=>f===""?a:[a,f].join("/"))),i&&u.push(...l),u.map(f=>e.startsWith("/")&&f===""?"/":f)}function pT(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:_T(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const mT=/^:[\w-]+$/,gT=3,vT=2,yT=1,wT=10,bT=-2,My=e=>e==="*";function xT(e,t){let r=e.split("/"),n=r.length;
vendor: 10,209 bytes, lines 50-59
50return r.some(My)&&(n+=bT),t&&(n+=vT),r.filter(i=>!My(i)).reduce((i,a)=>i+(mT.test(a)?gT:a===""?yT:wT),n)}function _T(e,t){return e.length===t.length&&e.slice(0,-1).every((n,i)=>n===t[i])?e[e.length-1]-t[t.length-1]:0}function ST(e,t,r){let{routesMeta:n}=e,i={},a="/",l=[];for(let u=0;u<n.length;++u){let f=n[u],p=u===n.length-1,m=a==="/"?t:t.slice(a.length)||"/",g=ET({path:f.relativePath,caseSensitive:f.caseSensitive,end:p},m),b=f.route;if(!g)return null;Object.assign(i,g.params),l.push({params:i,pathname:Ls([a,g.pathname]),pathnameBase:OT(Ls([a,g.pathnameBase])),route:b}),g.pathnameBase!=="/"&&(a=Ls([a,g.pathnameBase]))}return l}function ET(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=kT(e.path,e.caseSensitive,e.end),i=t.match(r);if(!i)return null;let a=i[0],l=a.replace(/(.)\/+$/,"$1"),u=i.slice(1);return{params:n.reduce((p,m,g)=>{let{paramName:b,isOptional:w}=m;if(b==="*"){let _=u[g]||"";l=a.slice(0,a.length-_.length).replace(/(.)\/+$/,"$1")}const S=u[g];return w&&!S?p[b]=void 0:p[b]=(S||"").replace(/%2F/g,"/"),p},{}),pathname:a,pathnameBase:l,pattern:e}}function kT(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),Vp(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,u,f)=>(n.push({paramName:u,isOptional:f!=null}),f?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function TT(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Vp(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Wp(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}const CT=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,RT=e=>CT.test(e);function PT(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?qi(e):e,a;if(r)if(RT(r))a=r;else{if(r.includes("//")){let l=r;r=Pb(r),Vp(!1,"Pathnames cannot have embedded double slashes - normalizing "+(l+" -> "+r))}r.startsWith("/")?a=$y(r.substring(1),"/"):a=$y(r,t)}else a=t;return{pathname:a,search:AT(n),hash:NT(i)}}function $y(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function sh(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"].  Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function jT(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function Cb(e,t){let r=jT(e);return t?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function Rb(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=qi(e):(i=el({},e),Ot(!i.pathname||!i.pathname.includes("?"),sh("?","pathname","search",i)),Ot(!i.pathname||!i.pathname.includes("#"),sh("#","pathname","hash",i)),Ot(!i.search||!i.search.includes("#"),sh("#","search","hash",i)));let a=e===""||i.pathname==="",l=a?"/":i.pathname,u;if(l==null)u=r;else{let g=t.length-1;if(!n&&l.startsWith("..")){let b=l.split("/");for(;b[0]==="..";)b.shift(),g-=1;i.pathname=b.join("/")}u=g>=0?t[g]:"/"}let f=PT(i,u),p=l&&l!=="/"&&l.endsWith("/"),m=(a||l===".")&&r.endsWith("/");return!f.pathname.endsWith("/")&&(p||m)&&(f.pathname+="/"),f}const Pb=e=>e.replace(/\/\/+/g,"/"),Ls=e=>Pb(e.join("/")),OT=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),AT=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,NT=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function IT(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const jb=["post","put","patch","delete"];new Set(jb);const LT=["get",...jb];new Set(LT);/**
51 * React Router v6.30.4
52 *
53 * Copyright (c) Remix Software Inc.
54 *
55 * This source code is licensed under the MIT license found in the
56 * LICENSE.md file in the root directory of this source tree.
57 *
58 * @license MIT
59 */function tl(){return tl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},tl.apply(null,arguments)}const Hp=v.createContext(null),DT=v.createContext(null),Ro=v.createContext(null),Uu=v.createContext(null),qs=v.createContext({outlet:null,matches:[],isDataRoute:!1}),Ob=v.createContext(null);function MT(e,t){let{relative:r}=t===void 0?{}:t;wl()||Ot(!1);let{basename:n,navigator:i}=v.useContext(Ro),{hash:a,pathname:l,search:u}=Nb(e,{relative:r}),f=l;return n!=="/"&&(f=l==="/"?n:Ls([n,l])),i.createHref({pathname:f,search:u,hash:a})}function wl(){return v.useContext(Uu)!=null}function Po(){return wl()||Ot(!1),v.useContext(Uu).location}function Ab(e){v.useContext(Ro).static||v.useLayoutEffect(e)}function jo(){let{isDataRoute:e}=v.useContext(qs);return e?YT():$T()}function $T(){wl()||Ot(!1);let e=v.useContext(Hp),{basename:t,future:r,navigator:n}=v.useContext(Ro),{matches:i}=v.useContext(qs),{pathname:a}=Po(),l=JSON.stringify(Cb(i,r.v7_relativeSplatPath)),u=v.useRef(!1);return Ab(()=>{u.current=!0}),v.useCallback(function(p,m){if(m===void 0&&(m={}),!u.current)return;if(typeof p=="number"){n.go(p);return}let g=Rb(p,JSON.parse(l),a,m.relative==="path");e==null&&t!=="/"&&(g.pathname=g.pathname==="/"?t:Ls([t,g.pathname])),(m.replace?n.replace:n.push)(g,m.state,m)},[t,n,l,a,e])}function RU(){let{matches:e}=v.useContext(qs),t=e[e.length-1];return t?t.params:{}}function Nb(e,t){let{relative:r}=t===void 0?{}:t,{future:n}=v.useContext(Ro),{matches:i}=v.useContext(qs),{pathname:a}=Po(),l=JSON.stringify(Cb(i,n.v7_relativeSplatPath));return v.useMemo(()=>Rb(e,JSON.parse(l),a,r==="path"),[e,l,a,r])}function FT(e,t){return UT(e,t)}function UT(e,t,r,n){wl()||Ot(!1);let{navigator:i}=v.useContext(Ro),{matches:a}=v.useContext(qs),l=a[a.length-1],u=l?l.params:{};l&&l.pathname;let f=l?l.pathnameBase:"/";l&&l.route;let p=Po(),m;if(t){var g;let E=typeof t=="string"?qi(t):t;f==="/"||(g=E.pathname)!=null&&g.startsWith(f)||Ot(!1),m=E}else m=p;let b=m.pathname||"/",w=b;if(f!=="/"){let E=f.replace(/^\//,"").split("/");w="/"+b.replace(/^\//,"").split("/").slice(E.length).join("/")}let S=fT(e,{pathname:w}),_=WT(S&&S.map(E=>Object.assign({},E,{params:Object.assign({},u,E.params),pathname:Ls([f,i.encodeLocation?i.encodeLocation(E.pathname).pathname:E.pathname]),pathnameBase:E.pathnameBase==="/"?f:Ls([f,i.encodeLocation?i.encodeLocation(E.pathnameBase).pathname:E.pathnameBase])})),a,r,n);return t&&_?v.createElement(Uu.Provider,{value:{location:tl({pathname:"/",search:"",hash:"",state:null,key:"default"},m),navigationType:As.Pop}},_):_}function zT(){let e=QT(),t=IT(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return v.createElement(v.Fragment,null,v.createElement("h2",null,"Unexpected Application Error!"),v.createElement("h3",{style:{fontStyle:"italic"}},t),r?v.createElement("pre",{style:i},r):null,null)}const BT=v.createElement(zT,null);class qT extends v.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?v.createElement(qs.Provider,{value:this.props.routeContext},v.createElement(Ob.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function VT(e){let{routeContext:t,match:r,children:n}=e,i=v.useContext(Hp);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),v.createElement(qs.Provider,{value:t},n)}function WT(e,t,r,n){var i;if(t===void 0&&(t=[]),r===void 0&&(r=null),n===void 0&&(n=null),e==null){var a;if(!r)return null;if(r.errors)e=r.matches;else if((a=n)!=null&&a.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let l=e,u=(i=r)==null?void 0:i.errors;if(u!=null){let m=l.findIndex(g=>g.route.id&&(u==null?void 0:u[g.route.id])!==void 0);m>=0||Ot(!1),l=l.slice(0,Math.min(l.length,m+1))}let f=!1,p=-1;if(r&&n&&n.v7_partialHydration)for(let m=0;m<l.length;m++){let g=l[m];if((g.route.HydrateFallback||g.route.hydrateFallbackElement)&&(p=m),g.route.id){let{loaderData:b,errors:w}=r,S=g.route.loader&&b[g.route.id]===void 0&&(!w||w[g.route.id]===void 0);if(g.route.lazy||S){f=!0,p>=0?l=l.slice(0,p+1):l=[l[0]];break}}}return l.reduceRight((m,g,b)=>{let w,S=!1,_=null,E=null;r&&(w=u&&g.route.id?u[g.route.id]:void 0,_=g.route.errorElement||BT,f&&(p<0&&b===0?(JT("route-fallback"),S=!0,E=null):p===b&&(S=!0,E=g.route.hydrateFallbackElement||null)));let k=t.concat(l.slice(0,b+1)),T=()=>{let R;return w?R=_:S?R=E:g.route.Component?R=v.createElement(g.route.Component,null):g.route.element?R=g.route.element:R=m,v.createElement(VT,{match:g,routeContext:{outlet:m,matches:k,isDataRoute:r!=null},children:R})};return r&&(g.route.ErrorBoundary||g.route.errorElement||b===0)?v.createElement(qT,{location:r.location,revalidation:r.revalidation,component:_,error:w,children:T(),routeC
59ontext:{outlet:null,matches:k,isDataRoute:!0}}):T()},null)}var Ib=(function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e})(Ib||{}),Lb=(function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e})(Lb||{});function HT(e){let t=v.useContext(Hp);return t||Ot(!1),t}function KT(e){let t=v.useContext(DT);return t||Ot(!1),t}function GT(e){let t=v.useContext(qs);return t||Ot(!1),t}function Db(e){let t=GT(),r=t.matches[t.matches.length-1];return r.route.id||Ot(!1),r.route.id}function QT(){var e;let t=v.useContext(Ob),r=KT(),n=Db();return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function YT(){let{router:e}=HT(Ib.UseNavigateStable),t=Db(Lb.UseNavigateStable),r=v.useRef(!1);return Ab(()=>{r.current=!0}),v.useCallback(function(i,a){a===void 0&&(a={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,tl({fromRouteId:t},a)))},[e,t])}const Fy={};function JT(e,t,r){Fy[e]||(Fy[e]=!0)}function XT(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function q(e){Ot(!1)}function ZT(e){let{basename:t="/",children:r=null,location:n,navigationType:i=As.Pop,navigator:a,static:l=!1,future:u}=e;wl()&&Ot(!1);let f=t.replace(/^\/*/,"/"),p=v.useMemo(()=>({basename:f,navigator:a,static:l,future:tl({v7_relativeSplatPath:!1},u)}),[f,u,a,l]);typeof n=="string"&&(n=qi(n));let{pathname:m="/",search:g="",hash:b="",state:w=null,key:S="default"}=n,_=v.useMemo(()=>{let E=Wp(m,f);return E==null?null:{location:{pathname:E,search:g,hash:b,state:w,key:S},navigationType:i}},[f,m,g,b,w,S,i]);return _==null?null:v.createElement(Ro.Provider,{value:p},v.createElement(Uu.Provider,{children:r,value:_}))}function eC(e){let{children:t,location:r}=e;return FT(np(t),r)}new Promise(()=>{});function np(e,t){t===void 0&&(t=[]);let r=[];return v.Children.forEach(e,(n,i)=>{if(!v.isValidElement(n))return;let a=[...t,i];if(n.type===v.Fragment){r.push.apply(r,np(n.props.children,a));return}n.type!==q&&Ot(!1),!n.props.index||!n.props.children||Ot(!1);let l={id:n.props.id||a.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,loader:n.props.loader,action:n.props.action,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(l.children=np(n.props.children,a)),r.push(l)}),r}/**
60 * React Router DOM v6.30.4
61 *
62 * Copyright (c) Remix Software Inc.
63 *
64 * This source code is licensed under the MIT license found in the
65 * LICENSE.md file in the root directory of this source tree.
66 *
67 * @license MIT
68 */function sp(){return sp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},sp.apply(null,arguments)}function tC(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function rC(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function nC(e,t){return e.button===0&&(!t||t==="_self")&&!rC(e)}function op(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let n=e[r];return t.concat(Array.isArray(n)?n.map(i=>[r,i]):[[r,n]])},[]))}function sC(e,t){let r=op(e);return t&&t.forEach((n,i)=>{r.has(i)||t.getAll(i).forEach(a=>{r.append(i,a)})}),r}const oC=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],iC="6";try{window.__reactRouterVersion=iC}catch{}const aC="startTransition",Uy=Fu[aC];function lC(e){let{basename:t,children:r,future:n,window:i}=e,a=v.useRef();a.current==null&&(a.current=cT({window:i,v5Compat:!0}));let l=a.current,[u,f]=v.useState({action:l.action,location:l.location}),{v7_startTransition:p}=n||{},m=v.useCallback(g=>{p&&Uy?Uy(()=>f(g)):f(g)},[f,p]);return v.useLayoutEffect(()=>l.listen(m),[l,m]),v.useEffect(()=>XT(n),[n]),v.createElement(ZT,{basename:t,children:r,location:u.location,navigationType:u.action,navigator:l,future:n})}const cC=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",uC=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Lt=v.forwardRef(function(t,r){let{onClick:n,relative:i,reloadDocument:a,replace:l,state:u,target:f,to:p,preventScrollReset:m,viewTransition:g}=t,b=tC(t,oC),{basename:w}=v.useContext(Ro),S,_=!1;if(typeof p=="string"&&uC.test(p)&&(S=p,cC))try{let R=new URL(window.location.href),P=p.startsWith("//")?new URL(R.protocol+p):new URL(p),O=Wp(P.pathname,w);P.origin===R.origin&&O!=null?p=O+P.search+P.hash:_=!0}catch{}let E=MT(p,{relative:i}),k=dC(p,{replace:l,state:u,target:f,preventScrollReset:m,relative:i,viewTransition:g});function T(R){n&&n(R),R.defaultPrevented||k(R)}return v.createElement("a",sp({},b,{href:S||E,onClick:_||a?n:T,ref:r,target:f}))});var zy;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(zy||(zy={}));var By;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(By||(By={}));function dC(e,t){let{target:r,replace:n,state:i,preventScrollReset:a,relative:l,viewTransition:u}=t===void 0?{}:t,f=jo(),p=Po(),m=Nb(e,{relative:l});return v.useCallback(g=>{if(nC(g,r)){g.preventDefault();let b=n!==void 0?n:xu(p)===xu(m);f(e,{replace:b,state:i,preventScrollReset:a,relative:l,viewTransition:u})}},[p,f,m,n,i,r,e,a,l,u])}function PU(e){let t=v.useRef(op(e)),r=v.useRef(!1),n=Po(),i=v.useMemo(()=>sC(n.search,r.current?null:t.current),[n.search]),a=jo(),l=v.useCallback((u,f)=>{const p=op(typeof u=="function"?u(i):u);r.current=!0,a("?"+p,f)},[a,i]);return[i,l]}var qy=["light","dark"],fC="(prefers-color-scheme: dark)",hC=v.createContext(void 0),pC={setTheme:e=>{},themes:[]},mC=()=>{var e;return(e=v.useContext(hC))!=null?e:pC};v.memo(({forcedTheme:e,storageKey:t,attribute:r,enableSystem:n,enableColorScheme:i,defaultTheme:a,value:l,attrs:u,nonce:f})=>{let p=a==="system",m=r==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${u.map(S=>`'${S}'`).join(",")})`};`:`var d=document.documentElement,n='${r}',s='setAttribute';`,g=i?qy.includes(a)&&a?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${a}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",b=(S,_=!1,E=!0)=>{let k=l?l[S]:S,T=_?S+"|| ''":`'${k}'`,R="";return i&&E&&!_&&qy.includes(S)&&(R+=`d.style.colorScheme = '${S}';`),r==="class"?_||k?R+=`c.add(${T})`:R+="null":k&&(R+=`d[s](n,${T})`),R},w=e?`!function(){${m}${b(e)}}()`:n?`!function(){try{${m}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${p})){var t='${fC}',m=window.matchMedia(t);if(m.media!==t||m.matches){${b("dark")}}else{${b("light")}}}else if(e){${l?`var x=${JSON.stringify(l)};`:""}${b(l?"x[e]":"e",!0)}}${p?"":"else{"+b(a,!1,!1)+"}"}${g}}catch(e){}}()`:`!function(){try{${m}var e=localStorage.getItem('${t}');if(e){${l?`var x=${JSON.stringify(l)};`:""}${b(l?"x[e]":"e",!0)}}else{${b(a,!1,!1)};}${g}}catch(t){}}();`;return v.createElement("script",{nonce:f,dangerouslySetInnerHTML:{__html:w}})});var gC=e=>{switch(e){case"success":return wC;case"info":return xC;case"warning":return bC;case"error":return _C;default:return null}},vC=Array(12).fill(0),yC=({visible:e,className:t})=>G.createElement("div",{className:["sonner-loading-wrapper",t].filter(
68Boolean).join(" "),"data-visible":e},G.createElement("div",{className:"sonner-spinner"},vC.map((r,n)=>G.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),wC=G.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},G.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),bC=G.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},G.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),xC=G.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},G.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),_C=G.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},G.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),SC=G.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},G.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),G.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),EC=()=>{let[e,t]=G.useState(document.hidden);return G.useEffect(()=>{let r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e},ip=1,kC=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:r,...n}=e,i=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:ip++,a=this.toasts.find(u=>u.id===i),l=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),a?this.toasts=this.toasts.map(u=>u.id===i?(this.publish({...u,...e,id:i,title:r}),{...u,...e,id:i,dismissible:l,title:r}):u):this.addToast({title:r,...n,dismissible:l,id:i}),i},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(r=>r({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>
68this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let r;t.loading!==void 0&&(r=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let n=e instanceof Promise?e:e(),i=r!==void 0,a,l=n.then(async f=>{if(a=["resolve",f],G.isValidElement(f))i=!1,this.create({id:r,type:"default",message:f});else if(CC(f)&&!f.ok){i=!1;let p=typeof t.error=="function"?await t.error(`HTTP error! status: ${f.status}`):t.error,m=typeof t.description=="function"?await t.description(`HTTP error! status: ${f.status}`):t.description;this.create({id:r,type:"error",message:p,description:m})}else if(t.success!==void 0){i=!1;let p=typeof t.success=="function"?await t.success(f):t.success,m=typeof t.description=="function"?await t.description(f):t.description;this.create({id:r,type:"success",message:p,description:m})}}).catch(async f=>{if(a=["reject",f],t.error!==void 0){i=!1;let p=typeof t.error=="function"?await t.error(f):t.error,m=typeof t.description=="function"?await t.description(f):t.description;this.create({id:r,type:"error",message:p,description:m})}}).finally(()=>{var f;i&&(this.dismiss(r),r=void 0),(f=t.finally)==null||f.call(t)}),u=()=>new Promise((f,p)=>l.then(()=>a[0]==="reject"?p(a[1]):f(a[1])).catch(p));return typeof r!="string"&&typeof r!="number"?{unwrap:u}:Object.assign(r,{unwrap:u})},this.custom=(e,t)=>{let r=(t==null?void 0:t.id)||ip++;return this.create({jsx:e(r),id:r,...t}),r},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},vr=new kC,TC=(e,t)=>{let r=(t==null?void 0:t.id)||ip++;return vr.addToast({title:e,...t,id:r}),r},CC=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",RC=TC,PC=()=>vr.toasts,jC=()=>vr.getActiveToasts(),ap=Object.assign(RC,{success:vr.success,info:vr.info,warning:vr.warning,error:vr.error,custom:vr.custom,message:vr.message,promise:vr.promise,dismiss:vr.dismiss,loading:vr.loading},{getHistory:PC,getToasts:jC});function OC(e,{insertAt:t}={}){if(typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t==="top"&&r.firstChild?r.insertBefore(n,r.firstChild):r.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}OC(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;
68left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}
68:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);
68--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
69`);function Kc(e){return e.label!==void 0}var AC=3,NC="32px",IC="16px",Vy=4e3,LC=356,DC=14,MC=20,$C=200;function Qr(...e){return e.filter(Boolean).join(" ")}function FC(e){let[t,r]=e.split("-"),n=[];return t&&n.push(t),r&&n.push(r),n}var UC=e=>{var t,r,n,i,a,l,u,f,p,m,g;let{invert:b,toast:w,unstyled:S,interacting:_,setHeights:E,visibleToasts:k,heights:T,index:R,toasts:P,expanded:O,removeToast:I,defaultRichColors:M,closeButton:Y,style:ae,cancelButtonStyle:he,actionButtonStyle:Ee,className:ue="",descriptionClassName:je="",duration:le,position:Ae,gap:Te,loadingIcon:re,expandByDefault:z,classNames:W,icons:K,closeButtonAriaLabel:N="Close toast",pauseWhenPageIsHidden:U}=e,[X,fe]=G.useState(null),[Oe,Fe]=G.useState(null),[Re,Ve]=G.useState(!1),[Qe,F]=G.useState(!1),[oe,J]=G.useState(!1),[Z,pe]=G.useState(!1),[ne,ot]=G.useState(!1),[Tt,vt]=G.useState(0),[Be,rt]=G.useState(0),Dt=G.useRef(w.duration||le||Vy),_t=G.useRef(null),br=G.useRef(null),No=R===0,Al=R+1<=k,tr=w.type,cn=w.dismissible!==!1,Io=w.className||"",Nl=w.descriptionClassName||"",un=G.useMemo(()=>T.findIndex(Ue=>Ue.toastId===w.id)||0,[T,w.id]),Vs=G.useMemo(()=>{var Ue;return(Ue=w.closeButton)!=null?Ue:Y},[w.closeButton,Y]),Il=G.useMemo(()=>w.duration||le||Vy,[w.duration,le]),Lo=G.useRef(0),On=G.useRef(0),Ll=G.useRef(0),dn=G.useRef(null),[ea,ta]=Ae.split("-"),Do=G.useMemo(()=>T.reduce((Ue,et,at)=>at>=un?Ue:Ue+et.height,0),[T,un]),Mo=EC(),Jn=w.invert||b,fn=tr==="loading";On.current=G.useMemo(()=>un*Te+Do,[un,Do]),G.useEffect(()=>{Dt.current=Il},[Il]),G.useEffect(()=>{Ve(!0)},[]),G.useEffect(()=>{let Ue=br.current;if(Ue){let et=Ue.getBoundingClientRect().height;return rt(et),E(at=>[{toastId:w.id,height:et,position:w.position},...at]),()=>E(at=>at.filter(rr=>rr.toastId!==w.id))}},[E,w.id]),G.useLayoutEffect(()=>{if(!Re)return;let Ue=br.current,et=Ue.style.height;Ue.style.height="auto";let at=Ue.getBoundingClientRect().height;Ue.style.height=et,rt(at),E(rr=>rr.find(lr=>lr.toastId===w.id)?rr.map(lr=>lr.toastId===w.id?{...lr,height:at}:lr):[{toastId:w.id,height:at,position:w.position},...rr])},[Re,w.title,w.description,E,w.id]);let Ur=G.useCallback(()=>{F(!0),vt(On.current),E(Ue=>Ue.filter(et=>et.toastId!==w.id)),setTimeout(()=>{I(w)},$C)},[w,I,E,On]);G.useEffect(()=>{if(w.promise&&tr==="loading"||w.duration===1/0||w.type==="loading")return;let Ue;return O||_||U&&Mo?(()=>{if(Ll.current<Lo.current){let et=new Date().getTime()-Lo.current;Dt.current=Dt.current-et}
69Ll.current=new Date().getTime()})():Dt.current!==1/0&&(Lo.current=new Date().getTime(),Ue=setTimeout(()=>{var et;(et=w.onAutoClose)==null||et.call(w,w),Ur()},Dt.current)),()=>clearTimeout(Ue)},[O,_,w,tr,U,Mo,Ur]),G.useEffect(()=>{w.delete&&Ur()},[Ur,w.delete]);function Dl(){var Ue,et,at;return K!=null&&K.loading?G.createElement("div",{className:Qr(W==null?void 0:W.loader,(Ue=w==null?void 0:w.classNames)==null?void 0:Ue.loader,"sonner-loader"),"data-visible":tr==="loading"},K.loading):re?G.createElement("div",{className:Qr(W==null?void 0:W.loader,(et=w==null?void 0:w.classNames)==null?void 0:et.loader,"sonner-loader"),"data-visible":tr==="loading"},re):G.createElement(yC,{className:Qr(W==null?void 0:W.loader,(at=w==null?void 0:w.classNames)==null?void 0:at.loader),visible:tr==="loading"})}return G.createElement("li",{tabIndex:0,ref:br,className:Qr(ue,Io,W==null?void 0:W.toast,(t=w==null?void 0:w.classNames)==null?void 0:t.toast,W==null?void 0:W.default,W==null?void 0:W[tr],(r=w==null?void 0:w.classNames)==null?void 0:r[tr]),"data-sonner-toast":"","data-rich-colors":(n=w.richColors)!=null?n:M,"data-styled":!(w.jsx||w.unstyled||S),"data-mounted":Re,"data-promise":!!w.promise,"data-swiped":ne,"data-removed":Qe,"data-visible":Al,"data-y-position":ea,"data-x-position":ta,"data-index":R,"data-front":No,"data-swiping":oe,"data-dismissible":cn,"data-type":tr,"data-invert":Jn,"data-swipe-out":Z,"data-swipe-direction":Oe,"data-expanded":!!(O||z&&Re),style:{"--index":R,"--toasts-before":R,"--z-index":P.length-R,"--offset":`${Qe?Tt:On.current}px`,"--initial-height":z?"auto":`${Be}px`,...ae,...w.style},onDragEnd:()=>{J(!1),fe(null),dn.current=null},onPointerDown:Ue=>{fn||!cn||(_t.current=new Date,vt(On.current),Ue.target.setPointerCapture(Ue.pointerId),Ue.target.tagName!=="BUTTON"&&(J(!0),dn.current={x:Ue.clientX,y:Ue.clientY}))},onPointerUp:()=>{var Ue,et,at,rr;if(Z||!cn)return;dn.current=null;let lr=Number(((Ue=br.current)==null?void 0:Ue.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),cr=Number(((et=br.current)==null?void 0:et.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),zr=new Date().getTime()-((at=_t.current)==null?void 0:at.getTime()),zt=X==="x"?lr:cr,hn=Math.abs(zt)/zr;if(Math.abs(zt)>=MC||hn>.11){vt(On.current),(rr=w.onDismiss)==null||rr.call(w,w),Fe(X==="x"?lr>0?"right":"left":cr>0?"down":"up"),Ur(),pe(!0),ot(!1);return}J(!1),fe(null)},onPointerMove:Ue=>{var et,at,rr,lr;if(!dn.current||!cn||((et=window.getSelection())==null?void 0:et.toString().length)>0)return;let cr=Ue.clientY-dn.current.y,zr=Ue.clientX-dn.current.x,zt=(at=e.swipeDirections)!=null?at:FC(Ae);!X&&(Math.abs(zr)>1||Math.abs(cr)>1)&&fe(Math.abs(zr)>Math.abs(cr)?"x":"y");let hn={x:0,y:0};X==="y"?(zt.includes("top")||zt.includes("bottom"))&&(zt.includes("top")&&cr<0||zt.includes("bottom")&&cr>0)&&(hn.y=cr):X==="x"&&(zt.includes("left")||zt.includes("right"))&&(zt.includes("left")&&zr<0||zt.includes("right")&&zr>0)&&(hn.x=zr),(Math.abs(hn.x)>0||Math.abs(hn.y)>0)&&ot(!0),(rr=br.current)==null||rr.style.setProperty("--swipe-amount-x",`${hn.x}px`),(lr=br.current)==null||lr.style.setProperty("--swipe-amount-y",`${hn.y}px`)}},Vs&&!w.jsx?G.createElement("button",{"aria-label":N,"data-disabled":fn,"data-close-button":!0,onClick:fn||!cn?()=>{}:()=>{var Ue;Ur(),(Ue=w.onDismiss)==null||Ue.call(w,w)},className:Qr(W==null?void 0:W.closeButton,(i=w==null?void 0:w.classNames)==null?void 0:i.closeButton)},(a=K==null?void 0:K.close)!=null?a:SC):null,w.jsx||v.isValidElement(w.title)?w.jsx?w.jsx:typeof w.title=="function"?w.title():w.title:G.createElement(G.Fragment,null,tr||w.icon||w.promise?G.createElement("div",{"data-icon":"",className:Qr(W==null?void 0:W.icon,(l=w==null?void 0:w.classNames)==null?void 0:l.icon)},w.promise||w.type==="loading"&&!w.icon?w.icon||Dl():null,w.type!=="loading"?w.icon||(K==null?void 0:K[tr])||gC(tr):null):null,G.createElement("div",{"data-content":"",className:Qr(W==null?void 0:W.content,(u=w==null?void 0:w.classNames)==null?void 0:u.content)},G.createElement("div",{"data-title":"",className:Qr(W==null?void 0:W.title,(f=w==null?void 0:w.classNames)==null?void 0:f.title)},typeof w.title=="function"?w.title():w.title),w.description?G.createElement("div",{"data-description":"",className:Qr(je,Nl,W==null?void 0:W.description,(p=w==null?void 0:w.classNames)==null?void 0:p.description)},typeof w.description=="function"?w.description():w.description):null),v.isValidElement(w.cancel)?w.cancel:w.cancel&&Kc(w.cancel)?G.createElement("button",{"data-button":!0,"data-cancel":!0,style:w.cancelButtonStyle||he,onClick:Ue=>{var et,at;Kc(w.cancel)&&cn&&((at=(et=w.cancel).onClick)==null||at.call(et,Ue),Ur())},className:Qr(W==null?void 0:W.cancelButton,(m=w==null?void 0:w.classNames)==null?void 0:m.cancelButton)},w.cancel.label):null,v.isValidElement(w.action)?w.action:w.action&&Kc(w.action)?G.createElement("button",{"data-button":!0,"data-action":!0,style:w.actionButtonStyle||Ee,onClick:Ue=>{var et,at;Kc(w.action)&&((at=(et=w.action).onClick)==null||at.call(et,Ue),!Ue.defaultPrevented&&Ur())},className:Qr(W==null?void 0:W.actionButton,(g=w==null?void 0:w.classNames)==null?void 0:g.actionButton)},w.action.label):null))};function Wy(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function zC(e,t){let r={};return[e,t].forEach((n,i)=>{let a=i===1,l=a?"--mobile-offset":"--offset",u=a?IC:NC;function f(p){["top","right","bottom","left"].forEach(m=>{r[`${l}-${m}`]=typeof p=="number"?`${p}px`:p})}typeof n=="number"||typeof n=="string"?f(n):typeof n=="object"?["top","right","bottom","left"].forEach(p=>{n[p]===void 0?r[`${l}-${p}`]=u:r[`${l}-${p}`]=typeof n[p]=="number"?`${n[p]}px`:n[p]}):f(u)}),r}var BC=v.forwardRef(function(e,t){let{invert:r,position:n="bottom-right",hotkey:i=["altKey","KeyT"],expand:a,closeButton:l,className:u,offset:f,mobileOffset:p,theme:m="light",richColors:g,duration:b,style:w,visibleToasts:S=AC,toastOptions:_,dir:E=Wy(),gap:k=DC,loadingIcon:T,icons:R,containerAriaLabel:P="Notifications",pauseWhenPageIsHidden:O}=e,[I,M]=G.useState([]),Y=G.useMemo(()=>Array.from(new Set([n].concat(I.filter(U=>U.position).map(U=>U.position)))),[I,n]),[ae,he]=G.useState([]),[Ee,ue]=G.useState(!1),[je,le]=G.useState(!1),[Ae,Te]=G.useState(m!=="system"?m:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dar
69k":"light"),re=G.useRef(null),z=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),W=G.useRef(null),K=G.useRef(!1),N=G.useCallback(U=>{M(X=>{var fe;return(fe=X.find(Oe=>Oe.id===U.id))!=null&&fe.delete||vr.dismiss(U.id),X.filter(({id:Oe})=>Oe!==U.id)})},[]);return G.useEffect(()=>vr.subscribe(U=>{if(U.dismiss){M(X=>X.map(fe=>fe.id===U.id?{...fe,delete:!0}:fe));return}setTimeout(()=>{wi.flushSync(()=>{M(X=>{let fe=X.findIndex(Oe=>Oe.id===U.id);return fe!==-1?[...X.slice(0,fe),{...X[fe],...U},...X.slice(fe+1)]:[U,...X]})})})}),[]),G.useEffect(()=>{if(m!=="system"){Te(m);return}if(m==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?Te("dark"):Te("light")),typeof window>"u")return;let U=window.matchMedia("(prefers-color-scheme: dark)");try{U.addEventListener("change",({matches:X})=>{Te(X?"dark":"light")})}catch{U.addListener(({matches:fe})=>{try{Te(fe?"dark":"light")}catch(Oe){console.error(Oe)}})}},[m]),G.useEffect(()=>{I.length<=1&&ue(!1)},[I]),G.useEffect(()=>{let U=X=>{var fe,Oe;i.every(Fe=>X[Fe]||X.code===Fe)&&(ue(!0),(fe=re.current)==null||fe.focus()),X.code==="Escape"&&(document.activeElement===re.current||(Oe=re.current)!=null&&Oe.contains(document.activeElement))&&ue(!1)};return document.addEventListener("keydown",U),()=>document.removeEventListener("keydown",U)},[i]),G.useEffect(()=>{if(re.current)return()=>{W.current&&(W.current.focus({preventScroll:!0}),W.current=null,K.current=!1)}},[re.current]),G.createElement("section",{ref:t,"aria-label":`${P} ${z}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},Y.map((U,X)=>{var fe;let[Oe,Fe]=U.split("-");return I.length?G.createElement("ol",{key:U,dir:E==="auto"?Wy():E,tabIndex:-1,ref:re,className:u,"data-sonner-toaster":!0,"data-theme":Ae,"data-y-position":Oe,"data-lifted":Ee&&I.length>1&&!a,"data-x-position":Fe,style:{"--front-toast-height":`${((fe=ae[0])==null?void 0:fe.height)||0}px`,"--width":`${LC}px`,"--gap":`${k}px`,...w,...zC(f,p)},onBlur:Re=>{K.current&&!Re.currentTarget.contains(Re.relatedTarget)&&(K.current=!1,W.current&&(W.current.focus({preventScroll:!0}),W.current=null))},onFocus:Re=>{Re.target instanceof HTMLElement&&Re.target.dataset.dismissible==="false"||K.current||(K.current=!0,W.current=Re.relatedTarget)},onMouseEnter:()=>ue(!0),onMouseMove:()=>ue(!0),onMouseLeave:()=>{je||ue(!1)},onDragEnd:()=>ue(!1),onPointerDown:Re=>{Re.target instanceof HTMLElement&&Re.target.dataset.dismissible==="false"||le(!0)},onPointerUp:()=>le(!1)},I.filter(Re=>!Re.position&&X===0||Re.position===U).map((Re,Ve)=>{var Qe,F;return G.createElement(UC,{key:Re.id,icons:R,index:Ve,toast:Re,defaultRichColors:g,duration:(Qe=_==null?void 0:_.duration)!=null?Qe:b,className:_==null?void 0:_.className,descriptionClassName:_==null?void 0:_.descriptionClassName,invert:r,visibleToasts:S,closeButton:(F=_==null?void 0:_.closeButton)!=null?F:l,interacting:je,position:U,style:_==null?void 0:_.style,unstyled:_==null?void 0:_.unstyled,classNames:_==null?void 0:_.classNames,cancelButtonStyle:_==null?void 0:_.cancelButtonStyle,actionButtonStyle:_==null?void 0:_.actionButtonStyle,removeToast:N,toasts:I.filter(oe=>oe.position==Re.position),heights:ae.filter(oe=>oe.position==Re.position),setHeights:he,expandByDefault:a,gap:k,loadingIcon:T,expanded:Ee,pauseWhenPageIsHidden:O,swipeDirections:e.swipeDirections})})):null}))});const qC=({...e})=>{const{theme:t="system"}=mC();return d.jsx(BC,{theme:t,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})},VC=1,WC=1e6;let oh=0;function HC(){return oh=(oh+1)%Number.MAX_SAFE_INTEGER,oh.toString()}const ih=new Map,Hy=e=>{if(ih.has(e))return;const t=setTimeout(()=>{ih.delete(e),Ka({type:"REMOVE_TOAST",toastId:e})},WC);ih.set(e,t)},Mb=(e,t)=>
69{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,VC)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case"DISMISS_TOAST":{const{toastId:r}=t;return r?Hy(r):e.toasts.forEach(n=>{Hy(n.id)}),{...e,toasts:e.toasts.map(n=>n.id===r||r===void 0?{...n,open:!1}:n)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)}}},uu=[];let du={toasts:[]};function Ka(e){du=Mb(du,e),uu.forEach(t=>{t(du)})}function $b({...e}){const t=HC(),r=i=>Ka({type:"UPDATE_TOAST",toast:{...i,id:t}}),n=()=>Ka({type:"DISMISS_TOAST",toastId:t});return Ka({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:i=>{i||n()}}}),{id:t,dismiss:n,update:r}}function zu(){const[e,t]=v.useState(du);return v.useEffect(()=>(uu.push(t),()=>{const r=uu.indexOf(t);r>-1&&uu.splice(r,1)}),[e]),{...e,toast:$b,dismiss:r=>Ka({type:"DISMISS_TOAST",toastId:r})}}const jU=Object.freeze(Object.defineProperty({__proto__:null,reducer:Mb,toast:$b,useToast:zu},Symbol.toStringTag,{value:"Module"}));function ut(e,t,{checkForDefaultPrevented:r=!0}={}){return function(i){if(e==null||e(i),r===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function Ky(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function bl(...e){return t=>{let r=!1;const n=e.map(i=>{const a=Ky(i,t);return!r&&typeof a=="function"&&(r=!0),a});if(r)return()=>{for(let i=0;i<n.length;i++){const a=n[i];typeof a=="function"?a():Ky(e[i],null)}}}}function Gt(...e){return v.useCallback(bl(...e),e)}function KC(e,t){const r=v.createContext(t),n=a=>{const{children:l,...u}=a,f=v.useMemo(()=>u,Object.values(u));return d.jsx(r.Provider,{value:f,children:l})};n.displayName=e+"Provider";function i(a){const l=v.useContext(r);if(l)return l;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[n,i]}function Vi(e,t=[]){let r=[];function n(a,l){const u=v.createContext(l),f=r.length;r=[...r,l];const p=g=>{var k;const{scope:b,children:w,...S}=g,_=((k=b==null?void 0:b[e])==null?void 0:k[f])||u,E=v.useMemo(()=>S,Object.values(S));return d.jsx(_.Provider,{value:E,children:w})};p.displayName=a+"Provider";function m(g,b){var _;const w=((_=b==null?void 0:b[e])==null?void 0:_[f])||u,S=v.useContext(w);if(S)return S;if(l!==void 0)return l;throw new Error(`\`${g}\` must be used within \`${a}\``)}return[p,m]}const i=()=>{const a=r.map(l=>v.createContext(l));return function(u){const f=(u==null?void 0:u[e])||a;return v.useMemo(()=>({[`__scope${e}`]:{...u,[e]:f}}),[u,f])}};return i.scopeName=e,[n,GC(i,...t)]}function GC(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const l=n.reduce((u,{useScope:f,scopeName:p})=>{const g=f(a)[`__scope${p}`];return{...u,...g}},{});return v.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return r.scopeName=t.scopeName,r}function Gy(e){const t=QC(e),r=v.forwardRef((n,i)=>{const{children:a,...l}=n,u=v.Children.toArray(a),f=u.find(JC);if(f){const p=f.props.children,m=u.map(g=>g===f?v.Children.count(p)>1?v.Children.only(null):v.isValidElement(p)?p.props.children:null:g);return d.jsx(t,{...l,ref:i,children:v.isValidElement(p)?v.cloneElement(p,void 0,m):null})}return d.jsx(t,{...l,ref:i,children:a})});return r.displayName=`${e}.Slot`,r}function QC(e){const t=v.forwardRef((r,n)=>{const{children:i,...a}=r;if(v.isValidElement(i)){const l=ZC(i),u=XC(a,i.props);return i.type!==v.Fragment&&(u.ref=n?bl(n,l):l),v.cloneElement(i,u)}return v.Children.count(i)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var YC=Symbol("radix.slottable");function JC(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===YC}function XC(e,t){const r={...t};for(const n in t){const i=e[n],a=t[n];/^on[A-Z]/.test(n)?i&&a?r[n]=(...u)=>{const f=a(...u);return i(...u),f}:i&&(r[n]=i):n==="style"?r[n]={...i,...a}:n==="className"&&(r[n]=[i,a].filter(Boolean).join(" "))}return{...e,...r}}function ZC(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function eR(e){const t=e+"CollectionProvider",[r,n]=Vi(t),[i,a]=r(t,{collectionRef:{current:null},itemMap:new Map}),l=_=>{const{scope:E,children:k}=_,T=G.useRef(null),R=G.useRef(new Map).current;return d.jsx(i,{scope:E,itemMap:R,collectionRef:T,children:k})};l.displayName=t;const u=e+"CollectionSlot",f=Gy(u),p=G.forwardRef((_,E)=>{const{scope:k,children:T}=_,R=a(u,k),P=Gt(E,R.collectionRef);return d.jsx(f,{ref:P,children:T})});p.displayName=u;const m=e+"CollectionItemSlot",g="data-radix-collection-item",b=Gy(m),w=G.forwardRef((_,E)=>{const{scope:k,children:T,...R}=_,P=G.useRef(null),O=Gt(E,P),I=a(m,k);return G.useEffect(()=>(I.itemMap.set(P,{ref:P,...R}),()=>void I.itemMap.delete(P))),d.jsx(b,{[g]:"",ref:O,children:T})});w.displayName=m;function S(_){const E=a(e+"CollectionConsumer",_);return G.useCallback(()=>{const T=E.collectionRef.current;if(!T)return[];const R=Array.from(T.querySelectorAll(`[${g}]`));return Array.from(E.itemMap.values()).sort((I,M)=>R.indexOf(I.ref.current)-R.indexOf(M.ref.current))},[E.collectionRef,E.itemMap])}return[{Provider:l,Slot:p,ItemSlot:w},S,n]}function tR(e){const t=rR(e),r=v.forwardRef((n,i)=>{const{children:a,...l}=n,u=v.Children.toArray(a),f=u.find(sR);if(f){const p=f.props.children,m=u.map(g=>g===f?v.Children.count(p)>1?v.Children.only(null):v.isValidElement(p)?p.props.children:null:g);return d.jsx(t,{...l,ref:i,children:v.isValidElement(p)?v.cloneElement(p,void 0,m):null})}return d.jsx(t,{...l,ref:i,children:a})});return r.displayName=`${e}.Slot`,r}function rR(e){const t=v.forwardRef((r,n)=>{const{children:i,...a}=r;if(v.isValidElement(i)){const l=iR(i),u=oR(a,i.props);return i.type!==v.Fragment&&(u.ref=n?bl(n,l):l),v.cloneElement(i,u)}return v.Children.count(i)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var nR=Symbol("radix.slottable");function sR(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===nR}function oR(e,t){const r={...t};for(const n in t){const i=e[n],a=t[n];/^on[A-Z]/.test(n)?i&&a?r[n]=(...u)=>{const f=a(...u);return i(...u),f}:i&&(r[n]=i):n==="style"?r[n]={...i,...a}
vendor: 8,287 bytes, line 69
69:n==="className"&&(r[n]=[i,a].filter(Boolean).join(" "))}return{...e,...r}}function iR(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var aR=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],xt=aR.reduce((e,t)=>{const r=tR(`Primitive.${t}`),n=v.forwardRef((i,a)=>{const{asChild:l,...u}=i,f=l?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(f,{...u,ref:a})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Fb(e,t){e&&Is.flushSync(()=>e.dispatchEvent(t))}function rn(e){const t=v.useRef(e);return v.useEffect(()=>{t.current=e}),v.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function lR(e,t=globalThis==null?void 0:globalThis.document){const r=rn(e);v.useEffect(()=>{const n=i=>{i.key==="Escape"&&r(i)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var cR="DismissableLayer",lp="dismissableLayer.update",uR="dismissableLayer.pointerDownOutside",dR="dismissableLayer.focusOutside",Qy,Ub=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Bu=v.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:l,onDismiss:u,...f}=e,p=v.useContext(Ub),[m,g]=v.useState(null),b=(m==null?void 0:m.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,w]=v.useState({}),S=Gt(t,M=>g(M)),_=Array.from(p.layers),[E]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),k=_.indexOf(E),T=m?_.indexOf(m):-1,R=p.layersWithOutsidePointerEventsDisabled.size>0,P=T>=k,O=hR(M=>{const Y=M.target,ae=[...p.branches].some(he=>he.contains(Y));!P||ae||(i==null||i(M),l==null||l(M),M.defaultPrevented||u==null||u())},b),I=pR(M=>{const Y=M.target;[...p.branches].some(he=>he.contains(Y))||(a==null||a(M),l==null||l(M),M.defaultPrevented||u==null||u())},b);return lR(M=>{T===p.layers.size-1&&(n==null||n(M),!M.defaultPrevented&&u&&(M.preventDefault(),u()))},b),v.useEffect(()=>{if(m)return r&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(Qy=b.body.style.pointerEvents,b.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(m)),p.layers.add(m),Yy(),()=>{r&&p.layersWithOutsidePointerEventsDisabled.size===1&&(b.body.style.pointerEvents=Qy)}},[m,b,r,p]),v.useEffect(()=>()=>{m&&(p.layers.delete(m),p.layersWithOutsidePointerEventsDisabled.delete(m),Yy())},[m,p]),v.useEffect(()=>{const M=()=>w({});return document.addEventListener(lp,M),()=>document.removeEventListener(lp,M)},[]),d.jsx(xt.div,{...f,ref:S,style:{pointerEvents:R?P?"auto":"none":void 0,...e.style},onFocusCapture:ut(e.onFocusCapture,I.onFocusCapture),onBlurCapture:ut(e.onBlurCapture,I.onBlurCapture),onPointerDownCapture:ut(e.onPointerDownCapture,O.onPointerDownCapture)})});Bu.displayName=cR;var fR="DismissableLayerBranch",zb=v.forwardRef((e,t)=>{const r=v.useContext(Ub),n=v.useRef(null),i=Gt(t,n);return v.useEffect(()=>{const a=n.current;if(a)return r.branches.add(a),()=>{r.branches.delete(a)}},[r.branches]),d.jsx(xt.div,{...e,ref:i})});zb.displayName=fR;function hR(e,t=globalThis==null?void 0:globalThis.document){const r=rn(e),n=v.useRef(!1),i=v.useRef(()=>{});return v.useEffect(()=>{const a=u=>{if(u.target&&!n.current){let f=function(){Bb(uR,r,p,{discrete:!0})};const p={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=f,t.addEventListener("click",i.current,{once:!0})):f()}else t.removeEventListener("click",i.current);n.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",a),t.removeEventListener("click",i.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function pR(e,t=globalThis==null?void 0:globalThis.document){const r=rn(e),n=v.useRef(!1);return v.useEffect(()=>{const i=a=>{a.target&&!n.current&&Bb(dR,r,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function Yy(){const e=new CustomEvent(lp);document.dispatchEvent(e)}function Bb(e,t,r,{discrete:n}){const i=r.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?Fb(i,a):i.dispatchEvent(a)}var mR=Bu,gR=zb,Fr=globalThis!=null&&globalThis.document?v.useLayoutEffect:()=>{},vR="Portal",Kp=v.forwardRef((e,t)=>{var u;const{container:r,...n}=e,[i,a]=v.useState(!1);Fr(()=>a(!0),[]);const l=r||i&&((u=globalThis==null?void 0:globalThis.document)==null?void 0:u.body);return l?wi.createPortal(d.jsx(xt.div,{...n,ref:t}),l):null});Kp.displayName=vR;function yR(e,t){return v.useReducer((r,n)=>t[r][n]??r,e)}var Oo=e=>{const{present:t,children:r}=e,n=wR(t),i=typeof r=="function"?r({present:n.isPresent}):v.Children.only(r),a=Gt(n.ref,bR(i));return typeof r=="function"||n.isPresent?v.cloneElement(i,{ref:a}):null};Oo.displayName="Presence";function wR(e){const[t,r]=v.useState(),n=v.useRef(null),i=v.useRef(e),a=v.useRef("none"),l=e?"mounted":"unmounted",[u,f]=yR(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const p=Gc(n.current);a.current=u==="mounted"?p:"none"},[u]),Fr(()=>{const p=n.current,m=i.current;if(m!==e){const b=a.current,w=Gc(p);e?f("MOUNT"):w==="none"||(p==null?void 0:p.display)==="none"?f("UNMOUNT"):f(m&&b!==w?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,f]),Fr(()=>{if(t){let p;const m=t.ownerDocument.defaultView??window,g=w=>{const _=Gc(n.current).includes(CSS.escape(w.animationName));if(w.target===t&&_&&(f("ANIMATION_END"),!i.current)){const E=t.style.animationFillMode;t.style.animationFillMode="forwards",p=m.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=E)})}},b=w=>{w.target===t&&(a.current=Gc(n.current))};return t.addEventListener("animationstart",b),t.addEventListener("animationcancel",g),t.addEventListener("animationend",g),()=>{m.clearTimeout(p),t.removeEventListener("animationstart",b),t.removeEventListener("animationcancel",g),t.removeEventListener("animationend",g)}}else f("ANIMATION_END")},[t,f]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:v.useCallback(p=>{n.current=p?getComputedStyle(p):null,r(p)},[])}}function Gc(e){return(e==null?void 0:e.animationName)||"none"}function bR(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var xR=Fu[" useInsertionEffect ".trim().toString()]||Fr;function qu({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[i,a,l]=_R({defaultProp:t,onChange:r}),u=e!==void 0,f=u?e:i;{const m=v.useRef(e!==void 0);v.useEffect(()=>{const g=m.current;g!==u&&console.warn(`${n} is changing from ${g?"controlled":"uncontrolled"} to ${u?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),m.current=u},[u,n])}const p=v.useCallback(m=>{var g;if(u){const b=SR(m)?m(e):m;b!==e&&((g=l.current)==null||g.call(l,b))}else a(m)},[u,e,a,l]);return[f,p]}function _R({defaultProp:e,onChange:t}){const[r,n]=v.useState(e),i=v.useRef(r),a=v.useRef(t);return xR(()=>{a.current=t},[t]),v.useEffect(()=>{var l;i.current!==r&&((l=a.current)==null||l.call(a,r),i.current=r)},[r,i]),[r,n,a]}function SR(e){return typeof e=="function"}var ER=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),kR="VisuallyHidden",Vu=v.forwardRef((e,t)=>d.jsx(xt.span,{...e,ref:t,style:{...ER,...e.style}}));
69Vu.displayName=kR;var TR=Vu,Gp="ToastProvider",[Qp,CR,RR]=eR("Toast"),[qb]=Vi("Toast",[RR]),[PR,Wu]=qb(Gp),Vb=e=>{const{__scopeToast:t,label:r="Notification",duration:n=5e3,swipeDirection:i="right",swipeThreshold:a=50,children:l}=e,[u,f]=v.useState(null),[p,m]=v.useState(0),g=v.useRef(!1),b=v.useRef(!1);return r.trim()||console.error(`Invalid prop \`label\` supplied to \`${Gp}\`. Expected non-empty \`string\`.`),d.jsx(Qp.Provider,{scope:t,children:d.jsx(PR,{scope:t,label:r,duration:n,swipeDirection:i,swipeThreshold:a,toastCount:p,viewport:u,onViewportChange:f,onToastAdd:v.useCallback(()=>m(w=>w+1),[]),onToastRemove:v.useCallback(()=>m(w=>w-1),[]),isFocusedToastEscapeKeyDownRef:g,isClosePausedRef:b,children:l})})};Vb.displayName=Gp;var Wb="ToastViewport",jR=["F8"],cp="toast.viewportPause",up="toast.viewportResume",Hb=v.forwardRef((e,t)=>{const{__scopeToast:r,hotkey:n=jR,label:i="Notifications ({hotkey})",...a}=e,l=Wu(Wb,r),u=CR(r),f=v.useRef(null),p=v.useRef(null),m=v.useRef(null),g=v.useRef(null),b=Gt(t,g,l.onViewportChange),w=n.join("+").replace(/Key/g,"").replace(/Digit/g,""),S=l.toastCount>0;v.useEffect(()=>{const E=k=>{var R;n.length!==0&&n.every(P=>k[P]||k.code===P)&&((R=g.current)==null||R.focus())};return document.addEventListener("keydown",E),()=>document.removeEventListener("keydown",E)},[n]),v.useEffect(()=>{const E=f.current,k=g.current;if(S&&E&&k){const T=()=>{if(!l.isClosePausedRef.current){const I=new CustomEvent(cp);k.dispatchEvent(I),l.isClosePausedRef.current=!0}},R=()=>{if(l.isClosePausedRef.current){const I=new CustomEvent(up);k.dispatchEvent(I),l.isClosePausedRef.current=!1}},P=I=>{!E.contains(I.relatedTarget)&&R()},O=()=>{E.contains(document.activeElement)||R()};return E.addEventListener("focusin",T),E.addEventListener("focusout",P),E.addEventListener("pointermove",T),E.addEventListener("pointerleave",O),window.addEventListener("blur",T),window.addEventListener("focus",R),()=>{E.removeEventListener("focusin",T),E.removeEventListener("focusout",P),E.removeEventListener("pointermove",T),E.removeEventListener("pointerleave",O),window.removeEventListener("blur",T),window.removeEventListener("focus",R)}}},[S,l.isClosePausedRef]);const _=v.useCallback(({tabbingDirection:E})=>{const T=u().map(R=>{const P=R.ref.current,O=[P,...qR(P)];return E==="forwards"?O:O.reverse()});return(E==="forwards"?T.reverse():T).flat()},[u]);return v.useEffect(()=>{const E=g.current;if(E){const k=T=>{var O,I,M;const R=T.altKey||T.ctrlKey||T.metaKey;if(T.key==="Tab"&&!R){const Y=document.activeElement,ae=T.shiftKey;if(T.target===E&&ae){(O=p.current)==null||O.focus();return}const ue=_({tabbingDirection:ae?"backwards":"forwards"}),je=ue.findIndex(le=>le===Y);ah(ue.slice(je+1))?T.preventDefault():ae?(I=p.current)==null||I.focus():(M=m.current)==null||M.focus()}};return E.addEventListener("keydown",k),()=>E.removeEventListener("keydown",k)}},[u,_]),d.jsxs(gR,{ref:f,role:"region","aria-label":i.replace("{hotkey}",w),tabIndex:-1,style:{pointerEvents:S?void 0:"none"},children:[S&&d.jsx(dp,{ref:p,onFocusFromOutsideViewport:()=>{const E=_({tabbingDirection:"forwards"});ah(E)}}),d.jsx(Qp.Slot,{scope:r,children:d.jsx(xt.ol,{tabIndex:-1,...a,ref:b})}),S&&d.jsx(dp,{ref:m,onFocusFromOutsideViewport:()=>{const E=_({tabbingDirection:"backwards"});ah(E)}})]})});Hb.displayName=Wb;var Kb="ToastFocusProxy",dp=v.forwardRef((e,t)=>{const{__scopeToast:r,onFocusFromOutsideViewport:n,...i}=e,a=Wu(Kb,r);return d.jsx(Vu,{tabIndex:0,...i,ref:t,style:{position:"fixed"},onFocus:l=>{var p;const u=l.relatedTarget;!((p=a.viewport)!=null&&p.contains(u))&&n()}})});dp.displayName=Kb;var xl="Toast",OR="toast.swipeStart",AR="toast.swipeMove",NR="toast.swipeCancel",IR="toast.swipeEnd",Gb=v.forwardRef((e,t)=>{const{forceMount:r,open:n,defaultOpen:i,onOpenChange:a,...l}=e,[u,f]=qu({prop:n,defaultProp:i??!0,onChange:a,caller:xl});return d.jsx(Oo,{present:r||u,children:d.jsx(MR,{open:u,...l,ref:t,onClose:()=>f(!1),onPause:rn(e.onPause),onResume:rn(e.onResume),onSwipeStart:ut(e.onSwipeStart,p=>{p.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:ut(e.onSwipeMove,p=>{const{x:m,y:g}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","move"),p.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${m}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${g}px`)}),onSwipeCancel:ut(e.onSwipeCancel,p=>{p.currentTarget.setAttribute("data-swipe","cancel"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:ut(e.onSwipeEnd,p=>{const{x:m,y:g}=p.detail.delta;p.currentTarget.setAttribute("data-swipe","end"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),p.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),p.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${m}px`),p.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${g}px`),f(!1)})})})});Gb.displayName=xl;var[LR,DR]=qb(xl,{onClose(){}}),MR=v.forwardRef((e,t)=>
69{const{__scopeToast:r,type:n="foreground",duration:i,open:a,onClose:l,onEscapeKeyDown:u,onPause:f,onResume:p,onSwipeStart:m,onSwipeMove:g,onSwipeCancel:b,onSwipeEnd:w,...S}=e,_=Wu(xl,r),[E,k]=v.useState(null),T=Gt(t,le=>k(le)),R=v.useRef(null),P=v.useRef(null),O=i||_.duration,I=v.useRef(0),M=v.useRef(O),Y=v.useRef(0),{onToastAdd:ae,onToastRemove:he}=_,Ee=rn(()=>{var Ae;(E==null?void 0:E.contains(document.activeElement))&&((Ae=_.viewport)==null||Ae.focus()),l()}),ue=v.useCallback(le=>{!le||le===1/0||(window.clearTimeout(Y.current),I.current=new Date().getTime(),Y.current=window.setTimeout(Ee,le))},[Ee]);v.useEffect(()=>{const le=_.viewport;if(le){const Ae=()=>{ue(M.current),p==null||p()},Te=()=>{const re=new Date().getTime()-I.current;M.current=M.current-re,window.clearTimeout(Y.current),f==null||f()};return le.addEventListener(cp,Te),le.addEventListener(up,Ae),()=>{le.removeEventListener(cp,Te),le.removeEventListener(up,Ae)}}},[_.viewport,O,f,p,ue]),v.useEffect(()=>{a&&!_.isClosePausedRef.current&&ue(O)},[a,O,_.isClosePausedRef,ue]),v.useEffect(()=>(ae(),()=>he()),[ae,he]);const je=v.useMemo(()=>E?tx(E):null,[E]);return _.viewport?d.jsxs(d.Fragment,{children:[je&&d.jsx($R,{__scopeToast:r,role:"status","aria-live":n==="foreground"?"assertive":"polite",children:je}),d.jsx(LR,{scope:r,onClose:Ee,children:Is.createPortal(d.jsx(Qp.ItemSlot,{scope:r,children:d.jsx(mR,{asChild:!0,onEscapeKeyDown:ut(u,()=>{_.isFocusedToastEscapeKeyDownRef.current||Ee(),_.isFocusedToastEscapeKeyDownRef.current=!1}),children:d.jsx(xt.li,{tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":_.swipeDirection,...S,ref:T,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:ut(e.onKeyDown,le=>{le.key==="Escape"&&(u==null||u(le.nativeEvent),le.nativeEvent.defaultPrevented||(_.isFocusedToastEscapeKeyDownRef.current=!0,Ee()))}),onPointerDown:ut(e.onPointerDown,le=>{le.button===0&&(R.current={x:le.clientX,y:le.clientY})}),onPointerMove:ut(e.onPointerMove,le=>{if(!R.current)return;const Ae=le.clientX-R.current.x,Te=le.clientY-R.current.y,re=!!P.current,z=["left","right"].includes(_.swipeDirection),W=["left","up"].includes(_.swipeDirection)?Math.min:Math.max,K=z?W(0,Ae):0,N=z?0:W(0,Te),U=le.pointerType==="touch"?10:2,X={x:K,y:N},fe={originalEvent:le,delta:X};re?(P.current=X,Qc(AR,g,fe,{discrete:!1})):Jy(X,_.swipeDirection,U)?(P.current=X,Qc(OR,m,fe,{discrete:!1}),le.target.setPointerCapture(le.pointerId)):(Math.abs(Ae)>U||Math.abs(Te)>U)&&(R.current=null)}),onPointerUp:ut(e.onPointerUp,le=>{const Ae=P.current,Te=le.target;if(Te.hasPointerCapture(le.pointerId)&&Te.releasePointerCapture(le.pointerId),P.current=null,R.current=null,Ae){const re=le.currentTarget,z={originalEvent:le,delta:Ae};Jy(Ae,_.swipeDirection,_.swipeThreshold)?Qc(IR,w,z,{discrete:!0}):Qc(NR,b,z,{discrete:!0}),re.addEventListener("click",W=>W.preventDefault(),{once:!0})}})})})}),_.viewport)})]}):null}),$R=e=>{const{__scopeToast:t,children:r,...n}=e,i=Wu(xl,t),[a,l]=v.useState(!1),[u,f]=v.useState(!1);return zR(()=>l(!0)),v.useEffect(()=>{const p=window.setTimeout(()=>f(!0),1e3);return()=>window.clearTimeout(p)},[]),u?null:d.jsx(Kp,{asChild:!0,children:d.jsx(Vu,{...n,children:a&&d.jsxs(d.Fragment,{children:[i.label," ",r]})})})},FR="ToastTitle",Qb=v.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return d.jsx(xt.div,{...n,ref:t})});Qb.displayName=FR;var UR="ToastDescription",Yb=v.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return d.jsx(xt.div,{...n,ref:t})});Yb.displayName=UR;var Jb="ToastAction",Xb=v.forwardRef((e,t)=>{const{altText:r,...n}=e;return r.trim()?d.jsx(ex,{altText:r,asChild:!0,children:d.jsx(Yp,{...n,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${Jb}\`. Expected non-empty \`string\`.`),null)});Xb.displayName=Jb;var Zb="ToastClose",Yp=v.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e,i=DR(Zb,r);return d.jsx(ex,{asChild:!0,children:d.jsx(xt.button,{type:"button",...n,ref:t,onClick:ut(e.onClick,i.onClose)})})});Yp.displayName=Zb;var ex=v.forwardRef((e,t)=>{const{__scopeToast:r,altText:n,...i}=e;return d.jsx(xt.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":n||void 0,...i,ref:t})});function tx(e){const t=[];
vendor: 4,279 bytes, lines 69-94
69return Array.from(e.childNodes).forEach(n=>{if(n.nodeType===n.TEXT_NODE&&n.textContent&&t.push(n.textContent),BR(n)){const i=n.ariaHidden||n.hidden||n.style.display==="none",a=n.dataset.radixToastAnnounceExclude==="";if(!i)if(a){const l=n.dataset.radixToastAnnounceAlt;l&&t.push(l)}else t.push(...tx(n))}}),t}function Qc(e,t,r,{discrete:n}){const i=r.originalEvent.currentTarget,a=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?Fb(i,a):i.dispatchEvent(a)}var Jy=(e,t,r=0)=>{const n=Math.abs(e.x),i=Math.abs(e.y),a=n>i;return t==="left"||t==="right"?a&&n>r:!a&&i>r};function zR(e=()=>{}){const t=rn(e);Fr(()=>{let r=0,n=0;return r=window.requestAnimationFrame(()=>n=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(r),window.cancelAnimationFrame(n)}},[t])}function BR(e){return e.nodeType===e.ELEMENT_NODE}function qR(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const i=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||i?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function ah(e){const t=document.activeElement;return e.some(r=>r===t?!0:(r.focus(),document.activeElement!==t))}var VR=Vb,rx=Hb,nx=Gb,sx=Qb,ox=Yb,ix=Xb,ax=Yp;function lx(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=lx(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function cx(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=lx(e))&&(n&&(n+=" "),n+=t);return n}const Xy=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Zy=cx,_l=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return Zy(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:i,defaultVariants:a}=t,l=Object.keys(i).map(p=>{const m=r==null?void 0:r[p],g=a==null?void 0:a[p];if(m===null)return null;const b=Xy(m)||Xy(g);return i[p][b]}),u=r&&Object.entries(r).reduce((p,m)=>{let[g,b]=m;return b===void 0||(p[g]=b),p},{}),f=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((p,m)=>{let{class:g,className:b,...w}=m;return Object.entries(w).every(S=>{let[_,E]=S;return Array.isArray(E)?E.includes({...a,...u}[_]):{...a,...u}[_]===E})?[...p,g,b]:p},[]);return Zy(e,l,f,r==null?void 0:r.class,r==null?void 0:r.className)};/**
70 * @license lucide-react v0.462.0 - ISC
71 *
72 * This source code is licensed under the ISC license.
73 * See the LICENSE file in the root directory of this source tree.
74 */const WR=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),ux=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim();/**
75 * @license lucide-react v0.462.0 - ISC
76 *
77 * This source code is licensed under the ISC license.
78 * See the LICENSE file in the root directory of this source tree.
79 */var HR={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
80 * @license lucide-react v0.462.0 - ISC
81 *
82 * This source code is licensed under the ISC license.
83 * See the LICENSE file in the root directory of this source tree.
84 */const KR=v.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:i="",children:a,iconNode:l,...u},f)=>v.createElement("svg",{ref:f,...HR,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:ux("lucide",i),...u},[...l.map(([p,m])=>v.createElement(p,m)),...Array.isArray(a)?a:[a]]));/**
85 * @license lucide-react v0.462.0 - ISC
86 *
87 * This source code is licensed under the ISC license.
88 * See the LICENSE file in the root directory of this source tree.
89 */const Ge=(e,t)=>{const r=v.forwardRef(({className:n,...i},a)=>v.createElement(KR,{ref:a,iconNode:t,className:ux(`lucide-${WR(e)}`,n),...i}));return r.displayName=`${e}`,r};/**
90 * @license lucide-react v0.462.0 - ISC
91 *
92 * This source code is licensed under the ISC license.
93 * See the LICENSE file in the root directory of this source tree.
94 */const GR=Ge("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l
94-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
95 * @license lucide-react v0.462.0 - ISC
96 *
97 * This source code is licensed under the ISC license.
98 * See the LICENSE file in the root directory of this source tree.
99 */const dx=Ge("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
100 * @license lucide-react v0.462.0 - ISC
101 *
102 * This source code is licensed under the ISC license.
103 * See the LICENSE file in the root directory of this source tree.
104 */const QR=Ge("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/**
105 * @license lucide-react v0.462.0 - ISC
106 *
107 * This source code is licensed under the ISC license.
108 * See the LICENSE file in the root directory of this source tree.
109 */const fu=Ge("Briefcase",[["path",{d:"M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16",key:"jecpp"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]]);/**
110 * @license lucide-react v0.462.0 - ISC
111 *
112 * This source code is licensed under the ISC license.
113 * See the LICENSE file in the root directory of this source tree.
114 */const YR=Ge("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]);/**
115 * @license lucide-react v0.462.0 - ISC
116 *
117 * This source code is licensed under the ISC license.
118 * See the LICENSE file in the root directory of this source tree.
119 */const JR=Ge("CalendarDays",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]]);/**
120 * @license lucide-react v0.462.0 - ISC
121 *
122 * This source code is licensed under the ISC license.
123 * See the LICENSE file in the root directory of this source tree.
124 */const e0=Ge("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);/**
125 * @license lucide-react v0.462.0 - ISC
126 *
127 * This source code is licensed under the ISC license.
128 * See the LICENSE file in the root directory of this source tree.
129 */const XR=Ge("ChartColumn",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
130 * @license lucide-react v0.462.0 - ISC
131 *
132 * This source code is licensed under the ISC license.
133 * See the LICENSE file in the root directory of this source tree.
134 */const ZR=Ge("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
135 * @license lucide-react v0.462.0 - ISC
136 *
137 * This source code is licensed under the ISC license.
138 * See the LICENSE file in the root directory of this source tree.
139 */const eP=Ge("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
140 * @license lucide-react v0.462.0 - ISC
141 *
142 * This source code is licensed under the ISC license.
143 * See the LICENSE file in the root directory of this source tree.
144 */const hu=Ge("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
145 * @license lucide-react v0.462.0 - ISC
146 *
147 * This source code is licensed under the ISC license.
148 * See the LICENSE file in the root directory of this source tree.
149 */const t0=Ge("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
150 * @license lucide-react v0.462.0 - ISC
151 *
152 * This source code is licensed under the ISC license.
153 * See the LICENSE file in the root directory of this source tree.
154 */const tP=Ge("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
155 * @license lucide-react v0.462.0 - ISC
156 *
157 * This source code is licensed under the ISC license.
158 * See the LICENSE file in the root directory of this source tree.
159 */const fx=Ge("ClipboardCheck",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"m9 14 2 2 4-4",key:"df797q"}]]);/**
160 * @license lucide-react v0.462.0 - ISC
161 *
162 * This source code is licensed under the ISC license.
163 * See the LICENSE file in the root directory of this source tree.
164 */const lh=Ge("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
165 * @license lucide-react v0.462.0 - ISC
166 *
167 * This source code is licensed under the ISC license.
168 * See the LICENSE file in the root directory of this source tree.
169 */const rP=Ge("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);/**
170 * @license lucide-react v0.462.0 - ISC
171 *
172 * This source code is licensed under the ISC license.
173 * See the LICENSE file in the root directory of this source tree.
174 */const nP=Ge("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
175 * @license lucide-react v0.462.0 - ISC
176 *
177 * This source code is licensed under the ISC license.
178 * See the LICENSE file in the root directory of this source tree.
179 */const sP=Ge("FolderKanban",[["path",{d:"M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z",key:"1fr9dc"}],["path",{d:"M8 10v4",key:"tgpxqk"}],["path",{d:"M12 10v2",key:"hh53o1"}],["path",{d:"M16 10v6",key:"1d6xys"}]]);/**
180 * @license lucide-react v0.462.0 - ISC
181 *
182 * This source code is licensed under the ISC license.
183 * See the LICENSE file in the root directory of this source tree.
184 */const oP=Ge("Github",[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]]);/**
185 * @license lucide-react v0.462.0 - ISC
186 *
187 * This source code is licensed under the ISC license.
188 * See the LICENSE file in the root directory of this source tree.
189 */const iP=Ge("GraduationCap",[["path",{d:"M21.42 10.922a1 1 0 0 0-.019-1.838L12.83 5.18a2 2 0 0 0-1.66 0L2.6 9.08a1 1 0 0 0 0 1.832l8.57 3.908a2 2 0 0 0 1.66 0z",key:"j76jl0"}],["path",{d:"M22 10v6",key:"1lu8f3"}],["path",{d:"M6 12.5V16a6 3 0 0 0 12 0v-3.5",key:"1r8lef"}]]);/**
190 * @license lucide-react v0.462.0 - ISC
191 *
192 * This source code is licensed under the ISC license.
193 * See the LICENSE file in the root directory of this source tree.
194 */const aP=Ge("House",[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]]);/**
195 * @license lucide-react v0.462.0 - ISC
196 *
197 * This source code is licensed under the ISC license.
198 * See the LICENSE file in the root directory of this source tree.
199 */const lP=Ge("Inbox",[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]);/**
200 * @license lucide-react v0.462.0 - ISC
201 *
202 * This source code is licensed under the ISC license.
203 * See the LICENSE file in the root directory of this source tree.
204 */const cP=Ge("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/**
205 * @license lucide-react v0.462.0 - ISC
206 *
207 * This source code is licensed under the ISC license.
208 * See the LICENSE file in the root directory of this source tree.
209 */const uP=Ge("Library",[["path",{d:"m16 6 4 14",key:"ji33uf"}],["path",{d:"M12 6v14",key:"1n7gus"}
209],["path",{d:"M8 8v12",key:"1gg7y9"}],["path",{d:"M4 4v16",key:"6qkkli"}]]);/**
210 * @license lucide-react v0.462.0 - ISC
211 *
212 * This source code is licensed under the ISC license.
213 * See the LICENSE file in the root directory of this source tree.
214 */const dP=Ge("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
215 * @license lucide-react v0.462.0 - ISC
216 *
217 * This source code is licensed under the ISC license.
218 * See the LICENSE file in the root directory of this source tree.
219 */const hx=Ge("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
220 * @license lucide-react v0.462.0 - ISC
221 *
222 * This source code is licensed under the ISC license.
223 * See the LICENSE file in the root directory of this source tree.
224 */const fP=Ge("PanelLeft",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]]);/**
225 * @license lucide-react v0.462.0 - ISC
226 *
227 * This source code is licensed under the ISC license.
228 * See the LICENSE file in the root directory of this source tree.
229 */const hP=Ge("PersonStanding",[["circle",{cx:"12",cy:"5",r:"1",key:"gxeob9"}],["path",{d:"m9 20 3-6 3 6",key:"se2kox"}],["path",{d:"m6 8 6 2 6-2",key:"4o3us4"}],["path",{d:"M12 10v4",key:"1kjpxc"}]]);/**
230 * @license lucide-react v0.462.0 - ISC
231 *
232 * This source code is licensed under the ISC license.
233 * See the LICENSE file in the root directory of this source tree.
234 */const px=Ge("Rocket",[["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z",key:"m3kijz"}],["path",{d:"m12 15-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z",key:"1fmvmk"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0",key:"1f8sc4"}],["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}]]);/**
235 * @license lucide-react v0.462.0 - ISC
236 *
237 * This source code is licensed under the ISC license.
238 * See the LICENSE file in the root directory of this source tree.
239 */const mx=Ge("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
240 * @license lucide-react v0.462.0 - ISC
241 *
242 * This source code is licensed under the ISC license.
243 * See the LICENSE file in the root directory of this source tree.
244 */const Jp=Ge("ShieldX",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m14.5 9.5-5 5",key:"17q4r4"}],["path",{d:"m9.5 9.5 5 5",key:"18nt4w"}]]);/**
245 * @license lucide-react v0.462.0 - ISC
246 *
247 * This source code is licensed under the ISC license.
248 * See the LICENSE file in the root directory of this source tree.
249 */const fp=Ge("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
250 * @license lucide-react v0.462.0 - ISC
251 *
252 * This source code is licensed under the ISC license.
253 * See the LICENSE file in the root directory of this source tree.
254 */const pP=Ge("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/**
255 * @license lucide-react v0.462.0 - ISC
256 *
257 * This source code is licensed under the ISC license.
258 * See the LICENSE file in the root directory of this source tree.
259 */const gx=Ge("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
260 * @license lucide-react v0.462.0 - ISC
261 *
262 * This source code is licensed under the ISC license.
263 * See the LICENSE file in the root directory of this source tree.
264 */const vx=Ge("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
265 * @license lucide-react v0.462.0 - ISC
266 *
267 * This source code is licensed under the ISC license.
268 * See the LICENSE file in the root directory of this source tree.
269 */const Hu=Ge("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}
vendor: 12,298 bytes, line 269
269],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Xp="-",mP=e=>{const t=vP(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:l=>{const u=l.split(Xp);return u[0]===""&&u.length!==1&&u.shift(),yx(u,t)||gP(l)},getConflictingClassGroupIds:(l,u)=>{const f=r[l]||[];return u&&n[l]?[...f,...n[l]]:f}}},yx=(e,t)=>{var l;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),i=n?yx(e.slice(1),n):void 0;if(i)return i;if(t.validators.length===0)return;const a=e.join(Xp);return(l=t.validators.find(({validator:u})=>u(a)))==null?void 0:l.classGroupId},r0=/^\[(.+)\]$/,gP=e=>{if(r0.test(e)){const t=r0.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},vP=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return wP(Object.entries(e.classGroups),r).forEach(([a,l])=>{hp(l,n,a,t)}),n},hp=(e,t,r,n)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?t:n0(t,i);a.classGroupId=r;return}if(typeof i=="function"){if(yP(i)){hp(i(n),t,r,n);return}t.validators.push({validator:i,classGroupId:r});return}Object.entries(i).forEach(([a,l])=>{hp(l,n0(t,a),r,n)})})},n0=(e,t)=>{let r=e;return t.split(Xp).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},yP=e=>e.isThemeGetter,wP=(e,t)=>t?e.map(([r,n])=>{const i=n.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([l,u])=>[t+l,u])):a);return[r,i]}):e,bP=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const i=(a,l)=>{r.set(a,l),t++,t>e&&(t=0,n=r,r=new Map)};return{get(a){let l=r.get(a);if(l!==void 0)return l;if((l=n.get(a))!==void 0)return i(a,l),l},set(a,l){r.has(a)?r.set(a,l):i(a,l)}}},wx="!",xP=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,i=t[0],a=t.length,l=u=>{const f=[];let p=0,m=0,g;for(let E=0;E<u.length;E++){let k=u[E];if(p===0){if(k===i&&(n||u.slice(E,E+a)===t)){f.push(u.slice(m,E)),m=E+a;continue}if(k==="/"){g=E;continue}}k==="["?p++:k==="]"&&p--}const b=f.length===0?u:u.substring(m),w=b.startsWith(wx),S=w?b.substring(1):b,_=g&&g>m?g-m:void 0;return{modifiers:f,hasImportantModifier:w,baseClassName:S,maybePostfixModifierPosition:_}};return r?u=>r({className:u,parseClassName:l}):l},_P=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},SP=e=>({cache:bP(e.cacheSize),parseClassName:xP(e),...mP(e)}),EP=/\s+/,kP=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:i}=t,a=[],l=e.trim().split(EP);let u="";for(let f=l.length-1;f>=0;f-=1){const p=l[f],{modifiers:m,hasImportantModifier:g,baseClassName:b,maybePostfixModifierPosition:w}=r(p);let S=!!w,_=n(S?b.substring(0,w):b);if(!_){if(!S){u=p+(u.length>0?" "+u:u);continue}if(_=n(b),!_){u=p+(u.length>0?" "+u:u);continue}S=!1}const E=_P(m).join(":"),k=g?E+wx:E,T=k+_;if(a.includes(T))continue;a.push(T);const R=i(_,S);for(let P=0;P<R.length;++P){const O=R[P];a.push(k+O)}u=p+(u.length>0?" "+u:u)}return u};function TP(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=bx(t))&&(n&&(n+=" "),n+=r);return n}const bx=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=bx(e[n]))&&(r&&(r+=" "),r+=t);return r};function CP(e,...t){let r,n,i,a=l;function l(f){const p=t.reduce((m,g)=>g(m),e());return r=SP(p),n=r.cache.get,i=r.cache.set,a=u,u(f)}function u(f){const p=n(f);if(p)return p;const m=kP(f,r);return i(f,m),m}return function(){return a(TP.apply(null,arguments))}}const ht=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},xx=/^\[(?:([a-z-]+):)?(.+)\]$/i,RP=/^\d+\/\d+$/,PP=new Set(["px","full","screen"]),jP=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,OP=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,AP=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,NP=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,IP=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Un=e=>bi(e)||PP.has(e)||RP.test(e),vs=e=>Wi(e,"length",BP),bi=e=>!!e&&!Number.isNaN(Number(e)),ch=e=>Wi(e,"number",bi),Ma=e=>!!e&&Number.isInteger(Number(e)),LP=e=>e.endsWith("%")&&bi(e.slice(0,-1)),qe=e=>xx.test(e),ys=e=>jP.test(e),DP=new Set(["length","size","percentage"]),MP=e=>Wi(e,DP,_x),$P=e=>Wi(e,"position",_x),FP=new Set(["image","url"]),UP=e=>Wi(e,FP,VP),zP=e=>Wi(e,"",qP),$a=()=>!0,Wi=(e,t,r)=>{const n=xx.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},BP=e=>OP.test(e)&&!AP.test(e),_x=()=>!1,qP=e=>NP.test(e),VP=e=>IP.test(e),WP=()=>{const e=ht("colors"),t=ht("spacing"),r=ht("blur"),n=ht("brightness"),i=ht("borderColor"),a=ht("borderRadius"),l=ht("borderSpacing"),u=ht("borderWidth"),f=ht("contrast"),p=ht("grayscale"),m=ht("hueRotate"),g=ht("invert"),b=ht("gap"),w=ht("gradientColorStops"),S=ht("gradientColorStopPositions"),_=ht("inset"),E=ht("margin"),k=ht("opacity"),T=ht("padding"),R=ht("saturate"),P=ht("scale"),O=ht("sepia"),I=ht("skew"),M=ht("space"),Y=ht("translate"),ae=()=>["auto","contain","none"],he=()=>["auto","hidden","clip","visible","scroll"],Ee=()=>["auto",qe,t],ue=()=>[qe,t],je=()=>["",Un,vs],le=()=>["auto",bi,qe],Ae=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],Te=()=>["solid","dashed","dotted","double","none"],re=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],z=()=>["start","end","center","between","around","evenly","stretch"],W=()=>["","0",qe],K=()=>["auto","avoid","all","avoid-page","page","left","right","column"],N=()=>[bi,qe];return{cacheSize:500,separator:":",theme:{colors:[$a],spacing:[Un,vs],blur:["none","",ys,qe],brightness:N(),borderColor:[e],borderRadius:["none","","full",ys,qe],borderSpacing:ue(),borderWidth:je(),contrast:N(),grayscale:W(),hueRotate:N(),invert:W(),gap:ue(),gradientColorStops:[e],gradientColorStopPositions:[LP,vs],inset:Ee(),margin:Ee(),opacity:N(),padding:ue(),saturate:N(),scale:N(),sepia:W(),skew:N(),space:ue(),translate:ue()},classGroups:{aspect:[{aspect:["auto","square","video",qe]}],container:["container"],columns:[{columns:[ys]}],"break-after":[{"break-after":K()}],"break-before":[{"break-before":K()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...Ae(),qe]}],overflow:[{overflow:he()}],"overflow-x":[{"overflow-x":he()}],"overflow-y":[{"overflow-y":he()}],overscroll:[{overscroll:ae()}],"overscroll-x":[{"overscroll-x":ae()}],"overscroll-y":[{"overscroll-y":ae()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[_]}],"inset-x":[{"inset-x":[_]}],"inset-y":[{"inset-y":[_]}],start:[{start:[_]}],end:[{end:[_]}],top:[{top:[_]}],right:[{right:[_]}],bottom:[{bottom:[_]}],left:[{left:[_]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ma,qe]}],basis:[{basis:Ee()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",qe]}],grow:[{grow:W()}],shrink:[{shrink:W()}],order:[{order:["first","last","none",Ma,qe]}],"grid-cols":[{"grid-cols":[$a]}],"col-start-end":[{col:["auto",{span:["full",Ma,qe]},qe]}],"col-start":[{"col-start":le()}],"col-end":[{"col-end":le()}],"grid-rows":[{"grid-rows":[$a]}],"row-start-end":[{row:["auto",{span:[Ma,qe]},qe]}],"row-start":[{"row-start":le()}],"row-end":[{"row-end":le()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",qe]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",qe]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...z()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...z(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...z(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[T]}],px:[{px:[T]}],py:[{py:[T]}],ps:[{ps:[T]}],pe:[{pe:[T]}],pt:[{pt:[T]}],pr:[{pr:[T]}],pb:[{pb:[T]}],pl:[{pl:[T]}],m:[{m:[E]}],mx:[{mx:[E]}],my:[{my:[E]}],ms:[{ms:[E]}],me:[{me:[E]}],mt:[{mt:[E]}],mr:[{mr:[E]}],mb:[{mb:[E]}],ml:[{ml:[E]}],"space-x":[{"space-x":[M]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[M]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",qe,t]}],"min-w":[{"min-w":[qe,t,"min","max","fit"]}],"max-w":[{"max-w":[qe,t,"none","full","min","max","fit","prose",{screen:[ys]},ys]}],h:[{h:[qe,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[qe,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[qe,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[qe,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ys,vs]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ch]}],"font-family":[{font:[$a]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",qe]}],"line-clamp":[{"line-clamp":["none",bi,ch]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Un,qe]}],"list-image":[{"list-image":["none",qe]}],"list-style-type":[{list:["none","disc","decimal",qe]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[k]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[k]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Te(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Un,vs]}],"underline-offset":[{"underline-offset":["auto",Un,qe]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:ue()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",qe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",qe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[k]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Ae(),$P]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",MP]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},UP]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[S]}
vendor: 5,204 bytes, line 269
269],"gradient-via-pos":[{via:[S]}],"gradient-to-pos":[{to:[S]}],"gradient-from":[{from:[w]}],"gradient-via":[{via:[w]}],"gradient-to":[{to:[w]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[u]}],"border-w-x":[{"border-x":[u]}],"border-w-y":[{"border-y":[u]}],"border-w-s":[{"border-s":[u]}],"border-w-e":[{"border-e":[u]}],"border-w-t":[{"border-t":[u]}],"border-w-r":[{"border-r":[u]}],"border-w-b":[{"border-b":[u]}],"border-w-l":[{"border-l":[u]}],"border-opacity":[{"border-opacity":[k]}],"border-style":[{border:[...Te(),"hidden"]}],"divide-x":[{"divide-x":[u]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[u]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[k]}],"divide-style":[{divide:Te()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...Te()]}],"outline-offset":[{"outline-offset":[Un,qe]}],"outline-w":[{outline:[Un,vs]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:je()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[k]}],"ring-offset-w":[{"ring-offset":[Un,vs]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ys,zP]}],"shadow-color":[{shadow:[$a]}],opacity:[{opacity:[k]}],"mix-blend":[{"mix-blend":[...re(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":re()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[f]}],"drop-shadow":[{"drop-shadow":["","none",ys,qe]}],grayscale:[{grayscale:[p]}],"hue-rotate":[{"hue-rotate":[m]}],invert:[{invert:[g]}],saturate:[{saturate:[R]}],sepia:[{sepia:[O]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[f]}],"backdrop-grayscale":[{"backdrop-grayscale":[p]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[m]}],"backdrop-invert":[{"backdrop-invert":[g]}],"backdrop-opacity":[{"backdrop-opacity":[k]}],"backdrop-saturate":[{"backdrop-saturate":[R]}],"backdrop-sepia":[{"backdrop-sepia":[O]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",qe]}],duration:[{duration:N()}],ease:[{ease:["linear","in","out","in-out",qe]}],delay:[{delay:N()}],animate:[{animate:["none","spin","ping","pulse","bounce",qe]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[P]}],"scale-x":[{"scale-x":[P]}],"scale-y":[{"scale-y":[P]}],rotate:[{rotate:[Ma,qe]}],"translate-x":[{"translate-x":[Y]}],"translate-y":[{"translate-y":[Y]}],"skew-x":[{"skew-x":[I]}],"skew-y":[{"skew-y":[I]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",qe]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",qe]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":ue()}],"scroll-mx":[{"scroll-mx":ue()}],"scroll-my":[{"scroll-my":ue()}],"scroll-ms":[{"scroll-ms":ue()}],"scroll-me":[{"scroll-me":ue()}],"scroll-mt":[{"scroll-mt":ue()}],"scroll-mr":[{"scroll-mr":ue()}],"scroll-mb":[{"scroll-mb":ue()}],"scroll-ml":[{"scroll-ml":ue()}],"scroll-p":[{"scroll-p":ue()}],"scroll-px":[{"scroll-px":ue()}],"scroll-py":[{"scroll-py":ue()}],"scroll-ps":[{"scroll-ps":ue()}],"scroll-pe":[{"scroll-pe":ue()}],"scroll-pt":[{"scroll-pt":ue()}],"scroll-pr":[{"scroll-pr":ue()}],"scroll-pb":[{"scroll-pb":ue()}],"scroll-pl":[{"scroll-pl":ue()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
vendor: 4,492 bytes, line 269
269],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",qe]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Un,vs,ch]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},HP=CP(WP);function Pe(...e){return HP(cx(e))}const KP=VR,Sx=v.forwardRef(({className:e,...t},r)=>d.jsx(rx,{ref:r,className:Pe("fixed top-0 z-[100] flex max-h-screen w-full flex-col p-4 sm:top-0 sm:right-0 sm:flex-col md:max-w-[420px]",e),...t}));Sx.displayName=rx.displayName;const GP=_l("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-top-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Ex=v.forwardRef(({className:e,variant:t,...r},n)=>d.jsx(nx,{ref:n,className:Pe(GP({variant:t}),e),...r}));Ex.displayName=nx.displayName;const QP=v.forwardRef(({className:e,...t},r)=>d.jsx(ix,{ref:r,className:Pe("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors hover:bg-secondary focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...t}));QP.displayName=ix.displayName;
269const kx=v.forwardRef(({className:e,...t},r)=>d.jsx(ax,{ref:r,className:Pe("absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:d.jsx(Hu,{className:"h-4 w-4"})}));kx.displayName=ax.displayName;const Tx=v.forwardRef(({className:e,...t},r)=>d.jsx(sx,{ref:r,className:Pe("text-sm font-semibold",e),...t}));Tx.displayName=sx.displayName;const Cx=v.forwardRef(({className:e,...t},r)=>d.jsx(ox,{ref:r,className:Pe("text-sm opacity-90",e),...t}));Cx.displayName=ox.displayName;function YP(){const{toasts:e}=zu();return d.jsxs(KP,{children:[e.map(function({id:t,title:r,description:n,action:i,...a}){return d.jsxs(Ex,{...a,children:[d.jsxs("div",{className:"grid gap-1",children:[r&&d.jsx(Tx,{children:r}),n&&d.jsx(Cx,{children:n})]}),i,d.jsx(kx,{})]},t)}),d.jsx(Sx,{})]})}var kn=function(){return kn=Object.assign||function(t){for(var r,n=1,i=arguments.length;n<i;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},kn.apply(this,arguments)};function Hi(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r}function JP(e,t,r,n){function i(a){return a instanceof r?a:new r(function(l){l(a)})}return new(r||(r=Promise))(function(a,l){function u(m){try{p(n.next(m))}catch(g){l(g)}}function f(m){try{p(n.throw(m))}catch(g){l(g)}}function p(m){m.done?a(m.value):i(m.value).then(u,f)}p((n=n.apply(e,t||[])).next())})}function XP(e,t,r){if(r||arguments.length===2)for(var n=0,i=t.length,a;n<i;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}const ZP=e=>e?(...t)=>e(...t):(...t)=>fetch(...t);class Zp extends Error{constructor(t,r="FunctionsError",n){super(t),this.name=r,this.context=n}}class ej extends Zp{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class s0 extends Zp{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class o0 extends Zp{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var pp;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(pp||(pp={}));class tj{constructor(t,{headers:r={},customFetch:n,region:i=pp.Any}={}){this.url=t,this.headers=r,this.region=i,this.fetch=ZP(n)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return JP(this,arguments,void 0,function*(r,n={}){var i;let a,l;try{const{headers:u,method:f,body:p,signal:m,timeout:g}=n;let b={},{region:w}=n;w||(w=this.region);const S=new URL(`${this.url}/${r}`);w&&w!=="any"&&(b["x-region"]=w,S.searchParams.set("forceFunctionRegion",w));let _;p&&(u&&!Object.prototype.hasOwnProperty.call(u,"Content-Type")||!u)?typeof Blob<"u"&&p instanceof Blob||p instanceof ArrayBuffer?(b["Content-Type"]="application/octet-stream",_=p):typeof p=="string"?(b["Content-Type"]="text/plain",_=p):typeof FormData<"u"&&p instanceof FormData?_=p:(b["Content-Type"]="application/json",_=JSON.stringify(p)):p&&typeof p!="string"&&!(typeof Blob<"u"&&p instanceof Blob)&&!(p instanceof ArrayBuffer)&&!(typeof FormData<"u"&&p instanceof FormData)?_=JSON.stringify(p):_=p;let E=m;g&&(l=new AbortController,a=setTimeout(()=>l.abort(),g),m?(E=l.signal,m.addEventListener("abort",()=>l.abort())):E=l.signal);const k=yield this.fetch(S.toString(),{method:f||"POST",headers:Object.assign(Object.assign(Object.assign({},b),this.headers),u),body:_,signal:E}).catch(O=>{throw new ej(O)}),T=k.headers.get("x-relay-error");
269if(T&&T==="true")throw new s0(k);if(!k.ok)throw new o0(k);let R=((i=k.headers.get("Content-Type"))!==null&&i!==void 0?i:"text/plain").split(";")[0].trim(),P;return R==="application/json"?P=yield k.json():R==="application/octet-stream"||R==="application/pdf"?P=yield k.blob():R==="text/event-stream"?P=k:R==="multipart/form-data"?P=yield k.formData():P=yield k.text(),{data:P,error:null,response:k}}catch(u){return{data:null,error:u,response:u instanceof o0||u instanceof s0?u.context:void 0}}finally{a&&clearTimeout(a)}})}}var rj=class extends Error{constructor(e){super(e.message),this.name="PostgrestError",this.details=e.details,this.hint=e.hint,this.code=e.code}},nj=class{constructor(e){var t,r,n;this.shouldThrowOnError=!1,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=(t=e.shouldThrowOnError)!==null&&t!==void 0?t:!1,this.signal=e.signal,this.isMaybeSingle=(r=e.isMaybeSingle)!==null&&r!==void 0?r:!1,this.urlLengthLimit=(n=e.urlLengthLimit)!==null&&n!==void 0?n:8e3,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}then(e,t){var r=this;this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers.set("Accept-Profile",this.schema):this.headers.set("Content-Profile",this.schema)),this.method!=="GET"&&this.method!=="HEAD"&&this.headers.set("Content-Type","application/json");const n=this.fetch;let i=n(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async a=>{let l=null,u=null,f=null,p=a.status,m=a.statusText;if(a.ok){var g,b;if(r.method!=="HEAD"){var w;const k=await a.text();k===""||(r.headers.get("Accept")==="text/csv"||r.headers.get("Accept")&&(!((w=r.headers.get("Accept"))===null||w===void 0)&&w.includes("application/vnd.pgrst.plan+text"))?u=k:u=JSON.parse(k))}const _=(g=r.headers.get("Prefer"))===null||g===void 0?void 0:g.match(/count=(exact|planned|estimated)/),E=(b=a.headers.get("content-range"))===null||b===void 0?void 0:b.split("/");_&&E&&E.length>1&&(f=parseInt(E[1])),r.isMaybeSingle&&r.method==="GET"&&Array.isArray(u)&&(u.length>1?(l={code:"PGRST116",details:`Results contain ${u.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},u=null,f=null,p=406,m="Not Acceptable"):u.length===1?u=u[0]:u=null)}else{var S;const _=await a.text();try{l=JSON.parse(_),Array.isArray(l)&&a.status===404&&(u=[],l=null,p=200,m="OK")}catch{a.status===404&&_===""?(p=204,m="No Content"):l={message:_}}if(l&&r.isMaybeSingle&&(!(l==null||(S=l.details)===null||S===void 0)&&S.includes("0 rows"))&&(l=null,p=200,m="OK"),l&&r.shouldThrowOnError)throw new rj(l)}return{error:l,data:u,count:f,status:p,statusText:m}});return this.shouldThrowOnError||(i=i.catch(a=>{var l;let u="",f="",p="";const m=a==null?void 0:a.cause;if(m){var g,b,w,S;const k=(g=m==null?void 0:m.message)!==null&&g!==void 0?g:"",T=(b=m==null?void 0:m.code)!==null&&b!==void 0?b:"";u=`${(w=a==null?void 0:a.name)!==null&&w!==void 0?w:"FetchError"}: ${a==null?void 0:a.message}`,u+=`
270
271Caused by: ${(S=m==null?void 0:m.name)!==null&&S!==void 0?S:"Error"}: ${k}`,T&&(u+=` (${T})`),m!=null&&m.stack&&(u+=`
272${m.stack}`)}else{var _;u=(_=a==null?void 0:a.stack)!==null&&_!==void 0?_:""}const E=this.url.toString().length;return(a==null?void 0:a.name)==="AbortError"||(a==null?void 0:a.code)==="ABORT_ERR"?(p="",f="Request was aborted (timeout or manual cancellation)",E>this.urlLengthLimit&&(f+=`. Note: Your request URL is ${E} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):((m==null?void 0:m.name)==="HeadersOverflowError"||(m==null?void 0:m.code)==="UND_ERR_HEADERS_OVERFLOW")&&(p="",f="HTTP headers exceeded server limits (typically 16KB)",E>this.urlLengthLimit&&(f+=`. Your request URL is ${E} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{error:{message:`${(l=a==null?void 0:a.name)!==null&&l!==void 0?l:"FetchError"}: ${a==null?void 0:a.message}`,details:u,hint:f,code:p},data:null,count:null,status:0,statusText:""}}
272)),i.then(e,t)}returns(){return this}overrideTypes(){return this}},sj=class extends nj{select(e){let t=!1;const r=(e??"*").split("").map(n=>/\s/.test(n)&&!t?"":(n==='"'&&(t=!t),n)).join("");return this.url.searchParams.set("select",r),this.headers.append("Prefer","return=representation"),this}order(e,{ascending:t=!0,nullsFirst:r,foreignTable:n,referencedTable:i=n}={}){const a=i?`${i}.order`:"order",l=this.url.searchParams.get(a);return this.url.searchParams.set(a,`${l?`${l},`:""}${e}.${t?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(e,{foreignTable:t,referencedTable:r=t}={}){const n=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(n,`${e}`),this}range(e,t,{foreignTable:r,referencedTable:n=r}={}){const i=typeof n>"u"?"offset":`${n}.offset`,a=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(i,`${e}`),this.url.searchParams.set(a,`${t-e+1}`),this}abortSignal(e){return this.signal=e,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}explain({analyze:e=!1,verbose:t=!1,settings:r=!1,buffers:n=!1,wal:i=!1,format:a="text"}={}){var l;const u=[e?"analyze":null,t?"verbose":null,r?"settings":null,n?"buffers":null,i?"wal":null].filter(Boolean).join("|"),f=(l=this.headers.get("Accept"))!==null&&l!==void 0?l:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${a}; for="${f}"; options=${u};`),a==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(e){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${e}`),this}};const i0=new RegExp("[,()]");var mi=class extends sj{eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(",")}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(",")}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(",")}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){const r=Array.from(new Set(t)).map(n=>typeof n=="string"&&i0.test(n)?`"${n}"`:`${n}`).join(",");return this.url.searchParams.append(e,`in.(${r})`),this}notIn(e,t){const r=Array.from(new Set(t)).map(n=>typeof n=="string"&&i0.test(n)?`"${n}"`:`${n}`).join(",");return this.url.searchParams.append(e,`not.in.(${r})`),this}contains(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(",")}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(",")}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t=="string"?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(",")}}`),this}textSearch(e,t,{config:r,type:n}={}){let i="";n==="plain"?i="pl":n==="phrase"?i="ph":n==="websearch"&&(i="w");const a=r===void 0?"":`(${r})`;return this.url.searchParams.append(e,`${i}fts${a}.${t}`),this}match(e){return Object.entries(e).filter(([t,r])=>
272r!==void 0).forEach(([t,r])=>{this.url.searchParams.append(t,`eq.${r}`)}),this}not(e,t,r){return this.url.searchParams.append(e,`not.${t}.${r}`),this}or(e,{foreignTable:t,referencedTable:r=t}={}){const n=r?`${r}.or`:"or";return this.url.searchParams.append(n,`(${e})`),this}filter(e,t,r){return this.url.searchParams.append(e,`${t}.${r}`),this}},oj=class{constructor(e,{headers:t={},schema:r,fetch:n,urlLengthLimit:i=8e3}){this.url=e,this.headers=new Headers(t),this.schema=r,this.fetch=n,this.urlLengthLimit=i}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){const{head:r=!1,count:n}=t??{},i=r?"HEAD":"GET";let a=!1;const l=(e??"*").split("").map(p=>/\s/.test(p)&&!a?"":(p==='"'&&(a=!a),p)).join(""),{url:u,headers:f}=this.cloneRequestState();return u.searchParams.set("select",l),n&&f.append("Prefer",`count=${n}`),new mi({method:i,url:u,headers:f,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}insert(e,{count:t,defaultToNull:r=!0}={}){var n;const i="POST",{url:a,headers:l}=this.cloneRequestState();if(t&&l.append("Prefer",`count=${t}`),r||l.append("Prefer","missing=default"),Array.isArray(e)){const u=e.reduce((f,p)=>f.concat(Object.keys(p)),[]);if(u.length>0){const f=[...new Set(u)].map(p=>`"${p}"`);a.searchParams.set("columns",f.join(","))}}return new mi({method:i,url:a,headers:l,schema:this.schema,body:e,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch,urlLengthLimit:this.urlLengthLimit})}upsert(e,{onConflict:t,ignoreDuplicates:r=!1,count:n,defaultToNull:i=!0}={}){var a;const l="POST",{url:u,headers:f}=this.cloneRequestState();if(f.append("Prefer",`resolution=${r?"ignore":"merge"}-duplicates`),t!==void 0&&u.searchParams.set("on_conflict",t),n&&f.append("Prefer",`count=${n}`),i||f.append("Prefer","missing=default"),Array.isArray(e)){const p=e.reduce((m,g)=>m.concat(Object.keys(g)),[]);if(p.length>0){const m=[...new Set(p)].map(g=>`"${g}"`);u.searchParams.set("columns",m.join(","))}}return new mi({method:l,url:u,headers:f,schema:this.schema,body:e,fetch:(a=this.fetch)!==null&&a!==void 0?a:fetch,urlLengthLimit:this.urlLengthLimit})}update(e,{count:t}={}){var r;const n="PATCH",{url:i,headers:a}=this.cloneRequestState();return t&&a.append("Prefer",`count=${t}`),new mi({method:n,url:i,headers:a,schema:this.schema,body:e,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch,urlLengthLimit:this.urlLengthLimit})}delete({count:e}={}){var t;const r="DELETE",{url:n,headers:i}=this.cloneRequestState();return e&&i.append("Prefer",`count=${e}`),new mi({method:r,url:n,headers:i,schema:this.schema,fetch:(t=this.fetch)!==null&&t!==void 0?t:fetch,urlLengthLimit:this.urlLengthLimit})}};function rl(e){"@babel/helpers - typeof";return rl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rl(e)}function ij(e,t){if(rl(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(rl(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function aj(e){var t=ij(e,"string");return rl(t)=="symbol"?t:t+""}function lj(e,t,r){return(t=aj(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function a0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Yc(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?a0(Object(r),!0).forEach(function(n){lj(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var cj=class Rx{constructor(t,{headers:r={},schema:n,fetch:i,timeout:a,urlLengthLimit:l=8e3}={}){this.url=t,this.headers=new Headers(r),this.schemaName=n,this.urlLengthLimit=l;const u=i??globalThis.fetch;a!==void 0&&a>0?this.fetch=(f,p)=>{const m=new AbortController,g=setTimeout(()=>m.abort(),a),b=p==null?void 0:p.signal;if(b){if(b.aborted)return clearTimeout(g),u(f,p);const w=()=>{clearTimeout(g),m.abort()};return b.addEventListener("abort",w,{once:!0}),u(f,Yc(Yc({},p),{},{signal:m.signal})).finally(()=>{clearTimeout(g),b.removeEventListener("abort",w)})}return u(f,Yc(Yc({},p),{},{signal:m.signal})).finally(()=>clearTimeout(g))}:this.fetch=u}from(t){if(!t||typeof t!="string"||t.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new oj(new URL(`${this.url}/${t}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}schema(t){return new Rx(this.url,{headers:this.headers,schema:t,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}rpc(t,r={},{head:n=!1,get:i=!1,count:a}={}){var l;let u;const f=new URL(`${this.url}/rpc/${t}`);let p;const m=w=>w!==null&&typeof w=="object"&&(!Array.isArray(w)||w.some(m)),g=n&&Object.values(r).some(m);g?(u="POST",p=r):n||i?(u=n?"HEAD":"GET",Object.entries(r).filter(([w,S])=>S!==void 0).map(([w,S])=>[w,Array.isArray(S)?`{${S.join(",")}}`:`${S}
272`]).forEach(([w,S])=>{f.searchParams.append(w,S)})):(u="POST",p=r);const b=new Headers(this.headers);return g?b.set("Prefer",a?`count=${a},return=minimal`:"return=minimal"):a&&b.set("Prefer",`count=${a}`),new mi({method:u,url:f,headers:b,schema:this.schemaName,body:p,fetch:(l=this.fetch)!==null&&l!==void 0?l:fetch,urlLengthLimit:this.urlLengthLimit})}};class uj{constructor(){}static detectEnvironment(){var t;if(typeof WebSocket<"u")return{type:"native",constructor:WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocket<"u")return{type:"native",constructor:globalThis.WebSocket};if(typeof global<"u"&&typeof global.WebSocket<"u")return{type:"native",constructor:global.WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocketPair<"u"&&typeof globalThis.WebSocket>"u")return{type:"cloudflare",error:"Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.",workaround:"Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime."};if(typeof globalThis<"u"&&globalThis.EdgeRuntime||typeof navigator<"u"&&(!((t=navigator.userAgent)===null||t===void 0)&&t.includes("Vercel-Edge")))return{type:"unsupported",error:"Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.",workaround:"Use serverless functions or a different deployment target for WebSocket functionality."};const r=globalThis.process;if(r){const n=r.versions;if(n&&n.node){const i=n.node,a=parseInt(i.replace(/^v/,"").split(".")[0]);return a>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${a} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${a} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option:
273import ws from "ws"
274new RealtimeClient(url, { transport: ws })`}}}return{type:"unsupported",error:"Unknown JavaScript runtime without WebSocket support.",workaround:"Ensure you're running in a supported environment (browser, Node.js, Deno) or provide a custom WebSocket implementation."}}static getWebSocketConstructor(){const t=this.detectEnvironment();if(t.constructor)return t.constructor;let r=t.error||"WebSocket not supported in this environment.";throw t.workaround&&(r+=`
275
276Suggested solution: ${t.workaround}`),new Error(r)}static createWebSocket(t,r){const n=this.getWebSocketConstructor();return new n(t,r)}static isWebSocketSupported(){try{const t=this.detectEnvironment();return t.type==="native"||t.type==="ws"}catch{return!1}}}const dj="2.99.3",fj=`realtime-js/${dj}`,hj="1.0.0",Px="2.0.0",l0=Px,mp=1e4,pj=1e3,mj=100;var xs;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(xs||(xs={}));var It;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(It||(It={}));var Zr;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(Zr||(Zr={}));var gp;(function(e){e.websocket="websocket"})(gp||(gp={}));var lo;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(lo||(lo={}));class gj{constructor(t){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT="broadcast",this.allowedMetadataKeys=[],this.allowedMetadataKeys=t??[]}encode(t,r){if(t.event===this.BROADCAST_EVENT&&!(t.payload instanceof ArrayBuffer)&&typeof t.payload.event=="string")return r(this._binaryEncodeUserBroadcastPush(t));let n=[t.join_ref,t.ref,t.topic,t.event,t.payload];return r(JSON.stringify(n))}_binaryEncodeUserBroadcastPush(t){var r;return this._isArrayBuffer((r=t.payload)===null||r===void 0?void 0:r.payload)?this._encodeBinaryUserBroadcastPush(t):this._encodeJsonUserBroadcastPush(t)}_encodeBinaryUserBroadcastPush(t){var r,n;const i=(n=(r=t.payload)===null||r===void 0?void 0:r.payload)!==null&&n!==void 0?n:new ArrayBuffer(0);return this._encodeUserBroadcastPush(t,this.BINARY_ENCODING,i)}_encodeJsonUserBroadcastPush(t){var r,n;const i=(n=(r=t.payload)===null||r===void 0?void 0:r.payload)!==null&&n!==void 0?n:{},l=new TextEncoder().encode(JSON.stringify(i)).buffer;return this._encodeUserBroadcastPush(t,this.JSON_ENCODING,l)}_encodeUserBroadcastPush(t,r,n){var i,a;const l=t.topic,u=(i=t.ref)!==null&&i!==void 0?i:"",f=(a=t.join_ref)!==null&&a!==void 0?a:"",p=t.payload.event,m=this.allowedMetadataKeys?this._pick(t.payload,this.allowedMetadataKeys):{},g=Object.keys(m).length===0?"":JSON.stringify(m);if(f.length>255)throw new Error(`joinRef length ${f.length} exceeds maximum of 255`);if(u.length>255)throw new Error(`ref length ${u.length} exceeds maximum of 255`);if(l.length>255)throw new Error(`topic length ${l.length} exceeds maximum of 255`);if(p.length>255)throw new Error(`userEvent length ${p.length} exceeds maximum of 255`);if(g.length>255)throw new Error(`metadata length ${g.length} exceeds maximum of 255`);const b=this.USER_BROADCAST_PUSH_META_LENGTH+f.length+u.length+l.length+p.length+g.length,w=new ArrayBuffer(this.HEADER_LENGTH+b);let S=new DataView(w),_=0;S.setUint8(_++,this.KINDS.userBroadcastPush),S.setUint8(_++,f.length),S.setUint8(_++,u.length),S.setUint8(_++,l.length),S.setUint8(_++,p.length),S.setUint8(_++,g.length),S.setUint8(_++,r),Array.from(f,k=>
276S.setUint8(_++,k.charCodeAt(0))),Array.from(u,k=>S.setUint8(_++,k.charCodeAt(0))),Array.from(l,k=>S.setUint8(_++,k.charCodeAt(0))),Array.from(p,k=>S.setUint8(_++,k.charCodeAt(0))),Array.from(g,k=>S.setUint8(_++,k.charCodeAt(0)));var E=new Uint8Array(w.byteLength+n.byteLength);return E.set(new Uint8Array(w),0),E.set(new Uint8Array(n),w.byteLength),E.buffer}decode(t,r){if(this._isArrayBuffer(t)){let n=this._binaryDecode(t);return r(n)}if(typeof t=="string"){const n=JSON.parse(t),[i,a,l,u,f]=n;return r({join_ref:i,ref:a,topic:l,event:u,payload:f})}return r({})}_binaryDecode(t){const r=new DataView(t),n=r.getUint8(0),i=new TextDecoder;switch(n){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(t,r,i)}}_decodeUserBroadcast(t,r,n){const i=r.getUint8(1),a=r.getUint8(2),l=r.getUint8(3),u=r.getUint8(4);let f=this.HEADER_LENGTH+4;const p=n.decode(t.slice(f,f+i));f=f+i;const m=n.decode(t.slice(f,f+a));f=f+a;const g=n.decode(t.slice(f,f+l));f=f+l;const b=t.slice(f,t.byteLength),w=u===this.JSON_ENCODING?JSON.parse(n.decode(b)):b,S={type:this.BROADCAST_EVENT,event:m,payload:w};return l>0&&(S.meta=JSON.parse(g)),{join_ref:null,ref:null,topic:p,event:this.BROADCAST_EVENT,payload:S}}_isArrayBuffer(t){var r;return t instanceof ArrayBuffer||((r=t==null?void 0:t.constructor)===null||r===void 0?void 0:r.name)==="ArrayBuffer"}_pick(t,r){return!t||typeof t!="object"?{}:Object.fromEntries(Object.entries(t).filter(([n])=>r.includes(n)))}}class jx{constructor(t,r){this.callback=t,this.timerCalc=r,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=r}reset(){this.tries=0,clearTimeout(this.timer),this.timer=void 0}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}var ct;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})(ct||(ct={}));const c0=(e,t,r={})=>{var n;const i=(n=r.skipTypes)!==null&&n!==void 0?n:[];return t?Object.keys(t).reduce((a,l)=>(a[l]=vj(l,e,t,i),a),{}):{}},vj=(e,t,r,n)=>{const i=t.find(u=>u.name===e),a=i==null?void 0:i.type,l=r[e];return a&&!n.includes(a)?Ox(a,l):vp(l)},Ox=(e,t)=>{if(e.charAt(0)==="_"){const r=e.slice(1,e.length);return xj(t,r)}switch(e){case ct.bool:return yj(t);case ct.float4:case ct.float8:case ct.int2:case ct.int4:case ct.int8:case ct.numeric:case ct.oid:return wj(t);case ct.json:case ct.jsonb:return bj(t);case ct.timestamp:return _j(t);case ct.abstime:case ct.date:case ct.daterange:case ct.int4range:case ct.int8range:case ct.money:case ct.reltime:case ct.text:case ct.time:case ct.timestamptz:case ct.timetz:case ct.tsrange:case ct.tstzrange:return vp(t);default:return vp(t)}},vp=e=>e,yj=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},wj=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},bj=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},xj=(e,t)=>{if(typeof e!="string")return e;const r=e.length-1,n=e[r];if(e[0]==="{"&&n==="}"){let a;const l=e.slice(1,r);try{a=JSON.parse("["+l+"]")}catch{a=l?l.split(","):[]}return a.map(u=>Ox(t,u))}return e},_j=e=>typeof e=="string"?e.replace(" ","T"):e,Ax=e=>{const t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,"http"),t.pathname=t.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),t.pathname===""||t.pathname==="/"?t.pathname="/api/broadcast":t.pathname=t.pathname+"/api/broadcast",t.href};class uh{constructor(t,r,n={},i=mp){this.channel=t,this.event=r,this.payload=n,this.timeout=i,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,j
vendor: 3,976 bytes, line 276
276oin_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,r){var n;return this._hasReceived(t)&&r((n=this.receivedResp)===null||n===void 0?void 0:n.response),this.recHooks.push({status:t,callback:r}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=r=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=r,this._matchReceive(r)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,r){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:r})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:r}){this.recHooks.filter(n=>n.status===t).forEach(n=>n.callback(r))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var u0;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(u0||(u0={}));class Ga{constructor(t,r){this.channel=t,this.state={},this.pendingDiffs=[],this.joinRef=null,this.enabled=!1,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const n=(r==null?void 0:r.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(n.state,{},i=>{const{onJoin:a,onLeave:l,onSync:u}=this.caller;this.joinRef=this.channel._joinRef(),this.state=Ga.syncState(this.state,i,a,l),this.pendingDiffs.forEach(f=>{this.state=Ga.syncDiff(this.state,f,a,l)}),this.pendingDiffs=[],u()}),this.channel._on(n.diff,{},i=>{const{onJoin:a,onLeave:l,onSync:u}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(i):(this.state=Ga.syncDiff(this.state,i,a,l),u())}),this.onJoin((i,a,l)=>{this.channel._trigger("presence",{event:"join",key:i,currentPresences:a,newPresences:l})}),this.onLeave((i,a,l)=>{this.channel._trigger("presence",{event:"leave",key:i,currentPresences:a,leftPresences:l})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,r,n,i){const a=this.cloneDeep(t),l=this.transformState(r),u={},f={};return this.map(a,(p,m)=>{l[p]||(f[p]=m)}),this.map(l,(p,m)=>{const g=a[p];if(g){const b=m.map(E=>E.presence_ref),w=g.map(E=>E.presence_ref),S=m.filter(E=>w.indexOf(E.presence_ref)<0),_=g.filter(E=>b.indexOf(E.presence_ref)<0);S.length>0&&(u[p]=S),_.length>0&&(f[p]=_)}else u[p]=m}),this.syncDiff(a,{joins:u,leaves:f},n,i)}static syncDiff(t,r,n,i){const{joins:a,leaves:l}={joins:this.transformState(r.joins),leaves:this.transformState(r.leaves)};return n||(n=()=>{}),i||(i=()=>{}),this.map(a,(u,f)=>{var p;const m=(p=t[u])!==null&&p!==void 0?p:[];if(t[u]=this.cloneDeep(f),m.length>0){const g=t[u].map(w=>w.presence_ref),b=m.filter(w=>g.indexOf(w.presence_ref)<0);t[u].unshift(...b)}n(u,m,f)}),this.map(l,(u,f)=>{let p=t[u];if(!p)return;const m=f.map(g=>g.presence_ref);p=p.filter(g=>m.indexOf(g.presence_ref)<0),t[u]=p,i(u,p,f),p.length===0&&delete t[u]}),t}static map(t,r){return Object.getOwnPropertyNames(t).map(n=>r(n,t[n]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((r,n)=>{const i=t[n];return"metas"in i?r[n]=i.metas.map(a=>(a.presence_ref=a.phx_ref,delete a.phx_ref,delete a.phx_ref_prev,a)):r[n]=i,r},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var d0;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(d0||(d0={}));var Qa;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})(Qa||(Qa={}));var qn;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"}
276)(qn||(qn={}));class yi{constructor(t,r={config:{}},n){var i,a;if(this.topic=t,this.params=r,this.socket=n,this.bindings={},this.state=It.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:"",enabled:!1},private:!1},r.config),this.timeout=this.socket.timeout,this.joinPush=new uh(this,Zr.join,this.params,this.timeout),this.rejoinTimer=new jx(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=It.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(l=>l.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=It.closed,this.socket._remove(this)}),this._onError(l=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,l),this.state=It.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=It.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",l=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,l),this.state=It.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Zr.reply,{},(l,u)=>{this._trigger(this._replyEventName(u),l)}),this.presence=new Ga(this),this.broadcastEndpointURL=Ax(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((a=(i=this.params.config)===null||i===void 0?void 0:i.broadcast)===null||a===void 0)&&a.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(t,r=this.timeout){var n,i,a;if(this.socket.isConnected()||this.socket.connect(),this.state==It.closed){const{config:{broadcast:l,presence:u,private:f}}=this.params,p=(i=(n=this.bindings.postgres_changes)===null||n===void 0?void 0:n.map(w=>w.filter))!==null&&i!==void 0?i:[],m=!!this.bindings[Qa.PRESENCE]&&this.bindings[Qa.PRESENCE].length>0||((a=this.params.config.presence)===null||a===void 0?void 0:a.enabled)===!0,g={},b={broadcast:l,presence:Object.assign(Object.assign({},u),{enabled:m}),postgres_changes:p,private:f};this.socket.accessTokenValue&&(g.access_token=this.socket.accessTokenValue),this._onError(w=>t==null?void 0:t(qn.CHANNEL_ERROR,w)),this._onClose(()=>t==null?void 0:t(qn.CLOSED)),this.updateJoinPayload(Object.assign({config:b},g)),this.joinedOnce=!0,this._rejoin(r),this.joinPush.receive("ok",async({postgres_changes:w})=>{var S;if(this.socket._isManualToken()||this.socket.setAuth(),w===void 0){t==null||t(qn.SUBSCRIBED);return}else{const _=this.bindings.postgres_changes,E=(S=_==null?void 0:_.length)!==null&&S!==void 0?S:0,k=[];for(let T=0;T<E;T++){const R=_[T],{filter:{event:P,schema:O,table:I,filter:M}}=R,Y=w&&w[T];if(Y&&Y.event===P&&yi.isFilterValueEqual(Y.schema,O)&&yi.isFilterValueEqual(Y.table,I)&&yi.isFilterValueEqual(Y.filter,M))k.push(Object.assign(Object.assign({},R),{id:Y.id}));else{this.unsubscribe(),this.state=It.errored,t==null||t(qn.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=k,t&&t(qn.SUBSCRIBED);return}}).receive("error",w=>{this.state=It.errored,t==null||t(qn.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(w).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(qn.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(t,r={}){return await this.send({type:"presence",event:"track",payload:t},r.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,r,n){return this.state===It.joined&&t===Qa.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(async()=>await this.subscribe())),this._on(t,r,n)}async httpSend(t,r,n={}){var i;if(r==null)return Promise.reject("Payload is required for httpSend()");const a={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(a.Authorization=`Bearer ${this.socket.accessTokenValue}`);const l={method:"POST",headers:a,body:JSON.stringify({messages:[{topic:this.subTopic,event:t,payload:r,private:this.private}]})},u=await this._fetchWithTimeout(this.broadcastEndpointURL,l,(i=n.timeout)!==null&&i!==void 0?i:this.timeout);if(u.status===202)return{success:!0};let f=u.statusText;
276try{const p=await u.json();f=p.error||p.message||f}catch{}return Promise.reject(new Error(f))}async send(t,r={}){var n,i;if(!this._canPush()&&t.type==="broadcast"){console.warn("Realtime send() is automatically falling back to REST API. This behavior will be deprecated in the future. Please use httpSend() explicitly for REST delivery.");const{event:a,payload:l}=t,u={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(u.Authorization=`Bearer ${this.socket.accessTokenValue}`);const f={method:"POST",headers:u,body:JSON.stringify({messages:[{topic:this.subTopic,event:a,payload:l,private:this.private}]})};try{const p=await this._fetchWithTimeout(this.broadcastEndpointURL,f,(n=r.timeout)!==null&&n!==void 0?n:this.timeout);return await((i=p.body)===null||i===void 0?void 0:i.cancel()),p.ok?"ok":"error"}catch(p){return p.name==="AbortError"?"timed out":"error"}}else return new Promise(a=>{var l,u,f;const p=this._push(t.type,t,r.timeout||this.timeout);t.type==="broadcast"&&!(!((f=(u=(l=this.params)===null||l===void 0?void 0:l.config)===null||u===void 0?void 0:u.broadcast)===null||f===void 0)&&f.ack)&&a("ok"),p.receive("ok",()=>a("ok")),p.receive("error",()=>a("error")),p.receive("timeout",()=>a("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=It.leaving;const r=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Zr.close,"leave",this._joinRef())};this.joinPush.destroy();let n=null;return new Promise(i=>{n=new uh(this,Zr.leave,{},t),n.receive("ok",()=>{r(),i("ok")}).receive("timeout",()=>{r(),i("timed out")}).receive("error",()=>{i("error")}),n.send(),this._canPush()||n.trigger("ok",{})}).finally(()=>{n==null||n.destroy()})}teardown(){this.pushBuffer.forEach(t=>t.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=It.closed,this.bindings={}}async _fetchWithTimeout(t,r,n){const i=new AbortController,a=setTimeout(()=>i.abort(),n),l=await this.socket.fetch(t,Object.assign(Object.assign({},r),{signal:i.signal}));return clearTimeout(a),l}_push(t,r,n=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let i=new uh(this,t,r,n);return this._canPush()?i.send():this._addToPushBuffer(i),i}_addToPushBuffer(t){if(t.startTimeout(),this.pushBuffer.push(t),this.pushBuffer.length>mj){const r=this.pushBuffer.shift();r&&(r.destroy(),this.socket.log("channel",`discarded push due to buffer overflow: ${r.event}`,r.payload))}}_onMessage(t,r,n){return r}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,r,n){var i,a;const l=t.toLocaleLowerCase(),{close:u,error:f,leave:p,join:m}=Zr;if(n&&[u,f,p,m].indexOf(l)>=0&&n!==this._joinRef())return;let b=this._onMessage(l,r,n);if(r&&!b)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(l)?(i=this.bindings.postgres_changes)===null||i===void 0||i.filter(w=>{var S,_,E;return((S=w.filter)===null||S===void 0?void 0:S.event)==="*"||((E=(_=w.filter)===null||_===void 0?void 0:_.event)===null||E===void 0?void 0:E.toLocaleLowerCase())===l}).map(w=>w.callback(b,n)):(a=this.bindings[l])===null||a===void 0||a.filter(w=>{var S,_,E,k,T,R;if(["broadcast","presence","postgres_changes"].includes(l))if("id"in w){const P=w.id,O=(S=w.filter)===null||S===void 0?void 0:S.event;return P&&((_=r.ids)===null||_===void 0?void 0:_.includes(P))&&(O==="*"||(O==null?void 0:O.toLocaleLowerCase())===((E=r.data)===null||E===void 0?void 0:E.type.toLocaleLowerCase()))}else{const P=(T=(k=w==null?void 0:w.filter)===null||k===void 0?void 0:k.event)===null||T===void 0?void 0:T.toLocaleLowerCase();return P==="*"||P===((R=r==null?void 0:r.event)===null||R===void 0?void 0:R.toLocaleLowerCase())}else return w.type.toLocaleLowerCase()===l}).map(w=>{if(typeof b=="object"&&"ids"in b){const S=b.data,{schema:_,table:E,commit_timestamp:k,type:T,errors:R}=S;b=Object.assign(Object.assign({},{schema:_,table:E,commit_timestamp:k,eventType:T,new:{},old:{},errors:R}),this._getPayloadRecords(S))}w.callback(b,n)})}_isClosed(){return this.state===It.closed}_isJoined(){return this.state===It.joined}_isJoining(){return this.state===It.joining}_isLeaving(){return this.state===It.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,r,n){const i=t.toLocaleLowerCase(),a={type:i,filter:r,callback:n};return this.bindings[i]?this.bindings[i].push(a):this.bindings[i]=[a],this}_off(t,r){const n=t.toLocaleLowerCase();return this.bindings[n]&&(this.bindings[n]=this.bindings[n].filter(i=>{var a;return!(((a=i.type)===null||a===void 0?void 0:a.toLocaleLowerCase())===n&&yi.isEqual(i.filter,r))})),this}static isEqual(t,r){if(Object.keys(t).length!==Object.keys(r).length)return!1;for(const n in t)if(t[n]!==r[n])return!1;return!0}static isFilterValueEqual(t,r){return(t??void 0)===(r??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Zr.close,{},t)}_onError(t){this._on(Zr.error,{},r=>t(r))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=It.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const r={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(r.new=c0(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(r.old=c0(t.columns,t.old_record)),r}}const dh=()=>{},Jc={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},Sj=[1e3,2e3,5e3,1e4],Ej=1e4,kj=`
277  addEventListener("message", (e) => {
278    if (e.data.event === "start") {
279      setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval);
280    }
281  });`;class Tj{constructor(t,r){var n;if(this.accessTokenValue=null,this.apiKey=null,this._manuallySetToken=!1,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={},this.timeout=mp,this.transport=null,this.heartbeatIntervalMs=Jc.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=dh,this.ref=0,this.reconnectTimer=null,this.vsn=l0,this.logger=
281dh,this.conn=null,this.sendBuffer=[],this.serializer=new gj,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=i=>i?(...a)=>i(...a):(...a)=>fetch(...a),!(!((n=r==null?void 0:r.params)===null||n===void 0)&&n.apikey))throw new Error("API key is required to connect to Realtime");this.apiKey=r.params.apikey,this.endPoint=`${t}/${gp.websocket}`,this.httpEndpoint=Ax(t),this._initializeOptions(r),this._setupReconnectionTimer(),this.fetch=this._resolveFetch(r==null?void 0:r.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.conn!==null&&this.isConnected())){if(this._setConnectionState("connecting"),this.accessToken&&!this._authPromise&&this._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=uj.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const r=t.message;throw r.includes("Node.js")?new Error(`${r}
282
283To use Realtime in Node.js, you need to provide a WebSocket implementation:
284
285Option 1: Use Node.js 22+ which has native WebSocket support
286Option 2: Install and provide the "ws" package:
287
288  npm install ws
289
290  import ws from "ws"
291  const client = new RealtimeClient(url, {
292    ...options,
293    transport: ws
294  })`):new Error(`WebSocket not available: ${r}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(t,r){if(!this.isDisconnecting())if(this._setConnectionState("disconnecting",!0),this.conn){const n=setTimeout(()=>{this._setConnectionState("disconnected")},100);this.conn.onclose=()=>{clearTimeout(n),this._setConnectionState("disconnected")},typeof this.conn.close=="function"&&(t?this.conn.close(t,r??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(t){const r=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),r}async removeAllChannels(){const t=await Promise.all(this.channels.map(r=>r.unsubscribe()));return this.channels=[],this.disconnect(),t}log(t,r,n){this.logger(t,r,n)}connectionState(){switch(this.conn&&this.conn.readyState){case xs.connecting:return lo.Connecting;case xs.open:return lo.Open;case xs.closing:return lo.Closing;default:return lo.Closed}}isConnected(){return this.connectionState()===lo.Open}isConnecting(){return this._connectionState==="connecting"}isDisconnecting(){return this._connectionState==="disconnecting"}channel(t,r={config:{}}){const n=`realtime:${t}`,i=this.getChannels().find(a=>a.topic===n);if(i)return i;{const a=new yi(`realtime:${t}`,r,this);return this.channels.push(a),a}}push(t){const{topic:r,event:n,payload:i,ref:a}=t,l=()=>{this.encode(t,u=>{var f;(f=this.conn)===null||f===void 0||f.send(u)})};this.log("push",`${r} ${n} (${a})`,i),this.isConnected()?l():this.sendBuffer.push(l)}async setAuth(t=null){this._authPromise=this._performAuth(t);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var t;if(!this.isConnected()){try{this.heartbeatCallback("disconnected")}catch(r){this.log("error","error in heartbeat callback",r)}return}if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this._heartbeatSentAt=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection");try{this.heartbeatCallback("timeout")}catch(r){this.log("error","error in heartbeat callback",r)}this._wasManualDisconnect=!1,(t=this.conn)===null||t===void 0||t.close(pj,"heartbeat timeout"),setTimeout(()=>{var r;this.isConnected()||(r=this.reconnectTimer)===null||r===void 0||r.sc
294heduleTimeout()},Jc.HEARTBEAT_TIMEOUT_FALLBACK);return}this._heartbeatSentAt=Date.now(),this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback("sent")}catch(r){this.log("error","error in heartbeat callback",r)}this._setAuthSafely("heartbeat")}onHeartbeat(t){this.heartbeatCallback=t}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let r=this.channels.find(n=>n.topic===t&&(n._isJoined()||n._isJoining()));r&&(this.log("transport",`leaving duplicate topic "${t}"`),r.unsubscribe())}_remove(t){this.channels=this.channels.filter(r=>r.topic!==t.topic)}_onConnMessage(t){this.decode(t.data,r=>{if(r.topic==="phoenix"&&r.event==="phx_reply"&&r.ref&&r.ref===this.pendingHeartbeatRef){const p=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(r.payload.status==="ok"?"ok":"error",p)}catch(m){this.log("error","error in heartbeat callback",m)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:n,event:i,payload:a,ref:l}=r,u=l?`(${l})`:"",f=a.status||"";this.log("receive",`${f} ${n} ${i} ${u}`.trim(),a),this.channels.filter(p=>p._isMember(n)).forEach(p=>p._trigger(i,a,l)),this._triggerStateCallbacks("message",r)})}_clearTimer(t){var r;t==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):t==="reconnect"&&((r=this.reconnectTimer)===null||r===void 0||r.reset())}_clearAllTimers(){this._clearTimer("heartbeat"),this._clearTimer("reconnect")}_setupConnectionHandlers(){this.conn&&("binaryType"in this.conn&&(this.conn.binaryType="arraybuffer"),this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t),this.conn.readyState===xs.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===xs.open||this.conn.readyState===xs.connecting)try{this.conn.close()}catch(t){this.log("error","Error closing connection",t)}this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null}this._clearAllTimers(),this._terminateWorker(),this.channels.forEach(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{this.accessTokenValue&&(this.channels.forEach(r=>{r.updateJoinPayload({access_token:this.accessTokenValue})}),this.sendBuffer=[],this.channels.forEach(r=>{r._isJoining()&&(r.joinPush.sent=!1,r.joinPush.send())})),this.flushSendBuffer()}).catch(r=>{this.log("error","error waiting for auth on connect",r),this.flushSendBuffer()}),this._clearTimer("reconnect"),this.worker?this.workerRef||this._startWorkerHeartbeat():this._startHeartbeat(),this._triggerStateCallbacks("open")}_startHeartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)}_startWorkerHeartbeat(){this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");const t=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(t),this.workerRef.onerror=r=>{this.log("worker","worker error",r.message),this._terminateWorker()},this.workerRef.onmessage=r=>{r.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&(this.log("worker","terminating worker"),this.workerRef.terminate(),this.workerRef=void 0)}_onConnClose(t){var r;this._setConnectionState("disconnected"),this.log("transport","close",t),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(r=this.reconnectTimer)===null||r===void 0||r.sc
294heduleTimeout(),this._triggerStateCallbacks("close",t)}_onConnError(t){this._setConnectionState("disconnected"),this.log("transport",`${t}`),this._triggerChanError(),this._triggerStateCallbacks("error",t);try{this.heartbeatCallback("error")}catch(r){this.log("error","error in heartbeat callback",r)}}_triggerChanError(){this.channels.forEach(t=>t._trigger(Zr.error))}_appendParams(t,r){if(Object.keys(r).length===0)return t;const n=t.match(/\?/)?"&":"?",i=new URLSearchParams(r);return`${t}${n}${i}`}_workerObjectUrl(t){let r;if(t)r=t;else{const n=new Blob([kj],{type:"application/javascript"});r=URL.createObjectURL(n)}return r}_setConnectionState(t,r=!1){this._connectionState=t,t==="connecting"?this._wasManualDisconnect=!1:t==="disconnecting"&&(this._wasManualDisconnect=r)}async _performAuth(t=null){let r,n=!1;if(t)r=t,n=!0;else if(this.accessToken)try{r=await this.accessToken()}catch(i){this.log("error","Error fetching access token from callback",i),r=this.accessTokenValue}else r=this.accessTokenValue;n?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=r&&(this.accessTokenValue=r,this.channels.forEach(i=>{const a={access_token:r,version:fj};r&&i.updateJoinPayload(a),i.joinedOnce&&i._isJoined()&&i._push(Zr.access_token,{access_token:r})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){this._isManualToken()||this.setAuth().catch(r=>{this.log("error",`Error setting auth in ${t}`,r)})}_triggerStateCallbacks(t,r){try{this.stateChangeCallbacks[t].forEach(n=>{try{n(r)}catch(i){this.log("error",`error in ${t} callback`,i)}})}catch(n){this.log("error",`error triggering ${t} callbacks`,n)}}_setupReconnectionTimer(){this.reconnectTimer=new jx(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},Jc.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var r,n,i,a,l,u,f,p,m,g,b,w;switch(this.transport=(r=t==null?void 0:t.transport)!==null&&r!==void 0?r:null,this.timeout=(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:mp,this.heartbeatIntervalMs=(i=t==null?void 0:t.heartbeatIntervalMs)!==null&&i!==void 0?i:Jc.HEARTBEAT_INTERVAL,this.worker=(a=t==null?void 0:t.worker)!==null&&a!==void 0?a:!1,this.accessToken=(l=t==null?void 0:t.accessToken)!==null&&l!==void 0?l:null,this.heartbeatCallback=(u=t==null?void 0:t.heartbeatCallback)!==null&&u!==void 0?u:dh,this.vsn=(f=t==null?void 0:t.vsn)!==null&&f!==void 0?f:l0,t!=null&&t.params&&(this.params=t.params),t!=null&&t.logger&&(this.logger=t.logger),(t!=null&&t.logLevel||t!=null&&t.log_level)&&(this.logLevel=t.logLevel||t.log_level,this.params=Object.assign(Object.assign({},this.params),{log_level:this.logLevel})),this.reconnectAfterMs=(p=t==null?void 0:t.reconnectAfterMs)!==null&&p!==void 0?p:(S=>Sj[S-1]||Ej),this.vsn){case hj:this.encode=(m=t==null?void 0:t.encode)!==null&&m!==void 0?m:((S,_)=>_(JSON.stringify(S))),this.decode=(g=t==null?void 0:t.decode)!==null&&g!==void 0?g:((S,_)=>_(JSON.parse(S)));break;case Px:this.encode=(b=t==null?void 0:t.encode)!==null&&b!==void 0?b:this.serializer.encode.bind(this.serializer),this.decode=(w=t==null?void 0:t.decode)!==null&&w!==void 0?w:this.serializer.decode.bind(this.serializer);break;default:throw new Error(`Unsupported serializer version: ${this.vsn}`)}if(this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=t==null?void 0:t.workerUrl}}}var nl=class extends Error{constructor(e,t){var r;super(e),this.name="IcebergError",this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType==="CommitStateUnknownException"||[500,502,504].includes(t.status)&&((r=t.icebergType)==null?void 0:r.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function Cj(e,t,r){const n=new URL(t,e);if(r)for(const[i,a]of Object.entries(r))a!==void 0&&n.searchParams.set(i,a);return n.toString()}async function Rj(e){return!e||e.type==="none"?{}:e.type==="bearer"?{Authorization:`Bearer ${e.token}`}:e.type==="header"?{[e.name]:e.value}:e.type==="custom"?await e.getHeaders():{}}function Pj(e){const t=e.fetchImpl??globalThis.fetch;return{async request({method:r,path:n,query:i,body:a,headers:l}){const u=Cj(e.baseUrl,n,i),f=await Rj(e.auth),p=await t(u,{method:r,headers:{...a?{"Content-Type":"application/json"}:{},...f,...l},body:a?JSON.stringify(a):void 0}),m=await p.text(),g=(p.headers.get("content-type")||"").includes("application/json"),b=g&&m?JSON.parse(m):m;if(!p.ok){const w=g?b:void 0,S=w==null?void 0:w.error;throw new nl((S==null?void 0:S.message)??`Request failed with status ${p.status}`,{status:p.status,icebergType:S==null?void 0:S.type,icebergCode:S==null?void 0:S.code,details:w})}return{status:p.status,headers:p.headers,data:b}}}}function Xc(e){return e.join("�")}var jj=class{constructor(e,t=""){this.client=e,this.prefix=t}async listNamespaces(e){const t=e?{parent:Xc(e.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(n=>({namespace:n}))}async createNamespace(e,t){const r={namespace:e.namespace,properties:t==null?void 0:t.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:r})).data}async dropNamespace(e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Xc(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Xc(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Xc(e.namespace)}`}),!0}catch(t){if(t instanceof nl&&t.status===404)return!1;throw t}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(r){if(r instanceof nl&&r.status===409)return;throw r}}};function ii(e){return e.join("�")}var Oj=class{constructor(e,t="",r){this.client=e,this.prefix=t,this.accessDelegation=r}async listTables(e){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){const r={};return this.accessDelegation&&(r["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables`,body:t,headers:r})).data.metadata}async updateTable(e,t){const r=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":r.data["metadata-location"],metadata:r.data.metadata}}async dropTable(e,t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String((t==null?void 0:t.purge)??!1)}})}async loadTable(e){const t={};return this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){const t={};this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${ii(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(r){if(r instanceof nl&&r.status===404)return!1;throw r}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(r){if(r instanceof nl&&r.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw r}}},Aj=class{constructor(e){var n;let t="v1";e.catalogName&&(t+=`/${e.catalogName}`);const r=e.baseUrl.endsWith("/")?e.baseUrl:`${e.baseUrl}/`;this.client=Pj({baseUrl:r,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=(n=e.accessDelegation)==null?void 0:n.join(","),this.namespaceOps=new jj(this.client,t),this.tableOps=new Oj(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
294async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}},Ku=class extends Error{constructor(e,t="storage",r,n){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t==="vectors"?"StorageVectorsError":"StorageError",this.status=r,this.statusCode=n}};function Gu(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var yp=class extends Ku{constructor(e,t,r,n="storage"){super(e,n,t,r),this.name=n==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=t,this.statusCode=r}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},Nx=class extends Ku{constructor(e,t,r="storage"){super(e,r),this.name=r==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=t}};const Nj=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),Ij=e=>{if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},wp=e=>{if(Array.isArray(e))return e.map(r=>wp(r));if(typeof e=="function"||e!==Object(e))return e;const t={};return Object.entries(e).forEach(([r,n])=>{const i=r.replace(/([-_][a-z])/gi,a=>a.toUpperCase().replace(/[-_]/g,""));t[i]=wp(n)}),t},Lj=e=>!e||typeof e!="string"||e.length===0||e.length>100||e.trim()!==e||e.includes("/")||e.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e);function sl(e){"@babel/helpers - typeof";return sl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sl(e)}function Dj(e,t){if(sl(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(sl(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mj(e){var t=Dj(e,"string");return sl(t)=="symbol"?t:t+""}function $j(e,t,r){return(t=Mj(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function f0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Me(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?f0(Object(r),!0).forEach(function(n){$j(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):f0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}const h0=e=>{var t;return e.msg||e.message||e.error_description||(typeof e.error=="string"?e.error:(t=e.error)===null||t===void 0?void 0:t.message)||JSON.stringify(e)},Fj=async(e,t,r,n)=>{if(e!==null&&typeof e=="object"&&typeof e.json=="function"){const i=e;let a=parseInt(i.status,10);Number.isFinite(a)||(a=500),i.json().then(l=>{const u=(l==null?void 0:l.statusCode)||(l==null?void 0:l.code)||a+"";t(new yp(h0(l),a,u,n))}).catch(()=>{const l=a+"";t(new yp(i.statusText||`HTTP ${a} error`,a,l,n))})}else t(new Nx(h0(e),e,n))},Uj=(e,t,r,n)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||e==="HEAD"||!n?Me(Me({},i),r):(Ij(n)?(i.headers=Me({"Content-Type":"application/json"},t==null?void 0:t.headers),i.body=JSON.stringify(n)):i.body=n,t!=null&&t.duplex&&(i.duplex=t.duplex),Me(Me({},i),r))};async function Fa(e,t,r,n,i,a,l){return new Promise((u,f)=>{e(r,Uj(t,n,i,a)).then(p=>{if(!p.ok)throw p;if(n!=null&&n.noResolveJson)return p;if(l==="vectors"){const m=p.headers.get("content-type");if(p.headers.get("content-length")==="0"||p.status===204)return{};if(!m||!m.includes("application/json"))return{}}return p.json()}).then(p=>u(p)).catch(p=>Fj(p,f,n,l))})}function Ix(e="storage"){return{get:async(t,r,n,i)=>Fa(t,"GET",r,n,i,void 0,e),post:async(t,r,n,i,a)=>Fa(t,"POST",r,i,a,n,e),put:async(t,r,n,i,a)=>Fa(t,"PUT",r,i,a,n,e),head:async(t,r,n,i)=>Fa(t,"HEAD",r,Me(Me({},n),{},{noResolveJson:!0}),i,void 0,e),remove:async(t,r,n,i,a)=>Fa(t,"DELETE",r,i,a,n,e)}}const zj=Ix("storage"),{get:ol,post:Jr,put:bp,head:Bj,remove:em}=zj,Rr=Ix("vectors");var Ki=class{constructor(e,t={},r,n="storage"){this.shouldThrowOnError=!1,this.url=e,this.headers=t,this.fetch=Nj(r),this.namespace=n}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=Me(Me({},this.headers),{},{[e]:t}),this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(r){if(t.shouldThrowOnError)throw r;if(Gu(r))return{data:null,error:r};throw r}}},qj=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t}then(e,t){return this.execute().then(e,t)}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(Gu(t))return{data:null,error:t};throw t}}};let Lx;Lx=Symbol.toStringTag;var Vj=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[Lx]="BlobDownloadBuilder",this.promise=null}asStream(){return new qj(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(Gu(t))return{data:null,error:t};throw t}}};const Wj={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},p0={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var Hj=class extends Ki{constructor(e,t={},r,n){super(e,t,n,"storage"),this.bucketId=r}async uploadOrUpdate(e,t,r,n){var i=this;return i.handleOperation(async()=>{let a;const l=Me(Me({},p0),n);let u=Me(Me({},i.headers),e==="POST"&&{"x-upsert":String(l.upsert)});const f=l.metadata;typeof Blob<"u"&&r instanceof Blob?(a=new FormData,a.append("cacheControl",l.cacheControl),f&&a.append("metadata",i.encodeMetadata(f)),a.append("",r)):typeof FormData<"u"&&r instanceof FormData?(a=r,a.has("cacheControl")||a.append("cacheControl",l.cacheControl),f&&!a.has("metadata")&&a.append("metadata",i.encodeMetadata(f))):(a=r,u["cache-control"]=`max-age=${l.cacheControl}`,u["content-type"]=l.contentType,f&&(u["x-metadata"]=i.toBase64(i.encodeMetadata(f))),(typeof ReadableStream<"u"&&a 
294instanceof ReadableStream||a&&typeof a=="object"&&"pipe"in a&&typeof a.pipe=="function")&&!l.duplex&&(l.duplex="half")),n!=null&&n.headers&&(u=Me(Me({},u),n.headers));const p=i._removeEmptyFolders(t),m=i._getFinalPath(p),g=await(e=="PUT"?bp:Jr)(i.fetch,`${i.url}/object/${m}`,a,Me({headers:u},l!=null&&l.duplex?{duplex:l.duplex}:{}));return{path:p,id:g.Id,fullPath:g.Key}})}async upload(e,t,r){return this.uploadOrUpdate("POST",e,t,r)}async uploadToSignedUrl(e,t,r,n){var i=this;const a=i._removeEmptyFolders(e),l=i._getFinalPath(a),u=new URL(i.url+`/object/upload/sign/${l}`);return u.searchParams.set("token",t),i.handleOperation(async()=>{let f;const p=Me({upsert:p0.upsert},n),m=Me(Me({},i.headers),{"x-upsert":String(p.upsert)});return typeof Blob<"u"&&r instanceof Blob?(f=new FormData,f.append("cacheControl",p.cacheControl),f.append("",r)):typeof FormData<"u"&&r instanceof FormData?(f=r,f.append("cacheControl",p.cacheControl)):(f=r,m["cache-control"]=`max-age=${p.cacheControl}`,m["content-type"]=p.contentType),{path:a,fullPath:(await bp(i.fetch,u.toString(),f,{headers:m})).Key}})}async createSignedUploadUrl(e,t){var r=this;return r.handleOperation(async()=>{let n=r._getFinalPath(e);const i=Me({},r.headers);t!=null&&t.upsert&&(i["x-upsert"]="true");const a=await Jr(r.fetch,`${r.url}/object/upload/sign/${n}`,{},{headers:i}),l=new URL(r.url+a.url),u=l.searchParams.get("token");if(!u)throw new Ku("No token returned by API");return{signedUrl:l.toString(),path:e,token:u}})}async update(e,t,r){return this.uploadOrUpdate("PUT",e,t,r)}async move(e,t,r){var n=this;return n.handleOperation(async()=>await Jr(n.fetch,`${n.url}/object/move`,{bucketId:n.bucketId,sourceKey:e,destinationKey:t,de
294stinationBucket:r==null?void 0:r.destinationBucket},{headers:n.headers}))}async copy(e,t,r){var n=this;return n.handleOperation(async()=>({path:(await Jr(n.fetch,`${n.url}/object/copy`,{bucketId:n.bucketId,sourceKey:e,destinationKey:t,destinationBucket:r==null?void 0:r.destinationBucket},{headers:n.headers})).Key}))}async createSignedUrl(e,t,r){var n=this;return n.handleOperation(async()=>{let i=n._getFinalPath(e);const a=typeof(r==null?void 0:r.transform)=="object"&&r.transform!==null&&Object.keys(r.transform).length>0;let l=await Jr(n.fetch,`${n.url}/object/sign/${i}`,Me({expiresIn:t},a?{transform:r.transform}:{}),{headers:n.headers});const u=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"",f=a&&l.signedURL.includes("/object/sign/")?l.signedURL.replace("/object/sign/","/render/image/sign/"):l.signedURL;return{signedUrl:encodeURI(`${n.url}${f}${u}`)}})}async createSignedUrls(e,t,r){var n=this;return n.handleOperation(async()=>{const i=await Jr(n.fetch,`${n.url}/object/sign/${n.bucketId}`,{expiresIn:t,paths:e},{headers:n.headers}),a=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return i.map(l=>Me(Me({},l),{},{signedUrl:l.signedURL?encodeURI(`${n.url}${l.signedURL}${a}`):null}))})}download(e,t,r){const n=typeof(t==null?void 0:t.transform)<"u"?"render/image/authenticated":"object",i=this.transformOptsToQueryString((t==null?void 0:t.transform)||{}),a=i?`?${i}`:"",l=this._getFinalPath(e),u=()=>ol(this.fetch,`${this.url}/${n}/${l}${a}`,{headers:this.headers,noResolveJson:!0},r);return new Vj(u,this.shouldThrowOnError)}async info(e){var t=this;const r=t._getFinalPath(e);return t.handleOperation(async()=>wp(await ol(t.fetch,`${t.url}/object/info/${r}`,{headers:t.headers})))}async exists(e){var t=this;const r=t._getFinalPath(e);try{return await Bj(t.fetch,`${t.url}/object/${r}`,{headers:t.headers}),{data:!0,error:null}}catch(i){if(t.shouldThrowOnError)throw i;if(Gu(i)){var n;const a=i instanceof yp?i.status:i instanceof Nx?(n=i.originalError)===null||n===void 0?void 0:n.status:void 0;if(a!==void 0&&[400,404].includes(a))return{data:!1,error:i}}throw i}}getPublicUrl(e,t){const r=this._getFinalPath(e),n=[],i=t!=null&&t.download?`download=${t.download===!0?"":t.download}`:"";i!==""&&n.push(i);const a=typeof(t==null?void 0:t.transform)<"u"?"render/image":"object",l=this.transformOptsToQueryString((t==null?void 0:t.transform)||{});l!==""&&n.push(l);let u=n.join("&");return u!==""&&(u=`?${u}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${r}${u}`)}}}async remove(e){var t=this;return t.handleOperation(async()=>await em(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,r){var n=this;return n.handleOperation(async()=>{const i=Me(Me(Me({},Wj),t),{},{prefix:e||""});return await Jr(n.fetch,`${n.url}/object/list/${n.bucketId}`,i,{headers:n.headers},r)})}async listV2(e,t){var r=this;return r.handleOperation(async()=>{const n=Me({},e);return await Jr(r.fetch,`${r.url}/object/list-v2/${r.bucketId}`,n,{headers:r.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<"u"?Buffer.from(e).toString("base64"):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,"")}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(e){const t=[];return e.width&&t.push(`width=${e.width}`),e.height&&t.push(`height=${e.height}`),e.resize&&t.push(`resize=${e.resize}`),e.format&&t.push(`format=${e.format}`),e.quality&&t.push(`quality=${e.quality}`),t.join("&")}};const Kj="2.99.3",Sl={"X-Client-Info":`storage-js/${Kj}`};var Gj=class extends Ki{constructor(e,t={},r,n){const i=new URL(e);n!=null&&n.useNewHostname&&/supabase\.(co|in|red)$/.test(i.hostname)&&!i.hostname.includes("storage.supabase.")&&(i.hostname=i.hostname.replace("supabase.","storage.supabase."));const a=i.href.replace(/\/$/,""),l=Me(Me({},Sl),t);super(a,l,r,"storage")}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const r=t.listBucketOptionsToQueryString(e);return await ol(t.fetch,`${t.url}/bucket${r}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await ol(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var r=this;return r.handleOperation(async()=>await Jr(r.fetch,`${r.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:r.headers}))}async updateBucket(e,t){var r=this;return r.handleOperation(async()=>await bp(r.fetch,`${r.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:r.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await Jr(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await em(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){const t={};return e&&("limit"in e&&(t.limit=String(e.limit)),"offset"in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>0?"?"+new URLSearchParams(t).toString():""}},Qj=class extends Ki{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=Me(Me({},Sl),t);super(n,i,r,"storage")}async createBucket(e){var t=this;return t.handleOperation(async()=>await Jr(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>
294{const r=new URLSearchParams;(e==null?void 0:e.limit)!==void 0&&r.set("limit",e.limit.toString()),(e==null?void 0:e.offset)!==void 0&&r.set("offset",e.offset.toString()),e!=null&&e.sortColumn&&r.set("sortColumn",e.sortColumn),e!=null&&e.sortOrder&&r.set("sortOrder",e.sortOrder),e!=null&&e.search&&r.set("search",e.search);const n=r.toString(),i=n?`${t.url}/bucket?${n}`:`${t.url}/bucket`;return await ol(t.fetch,i,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await em(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!Lj(e))throw new Ku("Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.");const r=new Aj({baseUrl:this.url,catalogName:e,auth:{type:"custom",getHeaders:async()=>t.headers},fetch:this.fetch}),n=this.shouldThrowOnError;return new Proxy(r,{get(i,a){const l=i[a];return typeof l!="function"?l:async(...u)=>{try{return{data:await l.apply(i,u),error:null}}catch(f){if(n)throw f;return{data:null,error:f}}}}})}},Yj=class extends Ki{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=Me(Me({},Sl),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async createIndex(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var r=this;return r.handleOperation(async()=>await Rr.post(r.fetch,`${r.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:r.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var r=this;return r.handleOperation(async()=>await Rr.post(r.fetch,`${r.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:r.headers})||{})}},Jj=class extends Ki{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=Me(Me({},Sl),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw new Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},Xj=class extends Ki{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=Me(Me({},Sl),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async createBucket(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Rr.post(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},Zj=class extends Xj{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new eO(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,r=this;return t().call(r,e)}async getBucket(e){var t=()=>super.getBucket,r=this;return t().call(r,e)}async listBuckets(e={}){var t=()=>super.listBuckets,r=this;return t().call(r,e)}async deleteBucket(e){var t=()=>super.deleteBucket,r=this;return t().call(r,e)}},eO=class extends Yj{constructor(e,t,r,n){super(e,t,n),this.vectorBucketName=r}async createIndex(e){var t=()=>super.createIndex,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName}))}
294async listIndexes(e={}){var t=()=>super.listIndexes,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,r=this;return t().call(r,r.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,r=this;return t().call(r,r.vectorBucketName,e)}index(e){return new tO(this.url,this.headers,this.vectorBucketName,e,this.fetch)}},tO=class extends Jj{constructor(e,t,r,n,i){super(e,t,i),this.vectorBucketName=r,this.indexName=n}async putVectors(e){var t=()=>super.putVectors,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async getVectors(e){var t=()=>super.getVectors,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,r=this;return t().call(r,Me(Me({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}},rO=class extends Gj{constructor(e,t={},r,n){super(e,t,r,n)}from(e){return new Hj(this.url,this.headers,e,this.fetch)}get vectors(){return new Zj(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new Qj(this.url+"/iceberg",this.headers,this.fetch)}};const Dx="2.99.3",gi=30*1e3,xp=3,fh=xp*gi,nO="http://localhost:9999",sO="supabase.auth.token",oO={"X-Client-Info":`gotrue-js/${Dx}`},_p="X-Supabase-Api-Version",Mx={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},iO=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,aO=600*1e3;class il extends Error{constructor(t,r,n){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=r,this.code=n}}function xe(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class lO extends il{constructor(t,r,n){super(t,r,n),this.name="AuthApiError",this.status=r,this.code=n}}function cO(e){return xe(e)&&e.name==="AuthApiError"}class co extends il{constructor(t,r){super(t),this.name="AuthUnknownError",this.originalError=r}}class Qn extends il{constructor(t,r,n,i){super(t,n,i),this.name=r,this.status=n}}class kr extends Qn{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function hh(e){return xe(e)&&e.name==="AuthSessionMissingError"}class ai extends Qn{constructor(){super("Auth session or user missing","AuthInvalidToken
294ResponseError",500,void 0)}}class Zc extends Qn{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class eu extends Qn{constructor(t,r=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=r}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}function uO(e){return xe(e)&&e.name==="AuthImplicitGrantRedirectError"}class m0 extends Qn{constructor(t,r=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=r}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class dO extends Qn{constructor(){super("PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.","AuthPKCECodeVerifierMissingError",400,"pkce_code_verifier_not_found")}}class Sp extends Qn{constructor(t,r){super(t,"AuthRetryableFetchError",r,void 0)}}function ph(e){return xe(e)&&e.name==="AuthRetryableFetchError"}class g0 extends Qn{constructor(t,r,n){super(t,"AuthWeakPasswordError",r,"weak_password"),this.reasons=n}}class Ep extends Qn{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const _u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),v0=` 	
295\r=`.split(""),fO=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<v0.length;t+=1)e[v0[t].charCodeAt(0)]=-2;for(let t=0;t<_u.length;t+=1)e[_u[t].charCodeAt(0)]=t;return e})();function y0(e,t,r){if(e!==null)for(t.queue=t.queue<<8|e,t.queuedBits+=8;t.queuedBits>=6;){const n=t.queue>>t.queuedBits-6&63;r(_u[n]),t.queuedBits-=6}else if(t.queuedBits>0)for(t.queue=t.queue<<6-t.queuedBits,t.queuedBits=6;t.queuedBits>=6;){const n=t.queue>>t.queuedBits-6&63;r(_u[n]),t.queuedBits-=6}}function $x(e,t,r){const n=fO[e];if(n>-1)for(t.queue=t.queue<<6|n,t.queuedBits+=6;t.queuedBits>=8;)r(t.queue>>t.queuedBits-8&255),t.queuedBits-=8;else{if(n===-2)return;throw new Error(`Invalid Base64-URL character "${String.fromCharCode(e)}"`)}}function w0(e){const t=[],r=l=>{t.push(String.fromCodePoint(l))},n={utf8seq:0,codepoint:0},i={queue:0,queuedBits:0},a=l=>{mO(l,n,r)};for(let l=0;l<e.length;l+=1)$x(e.charCodeAt(l),i,a);return t.join("")}function hO(e,t){if(e<=127){t(e);return}else if(e<=2047){t(192|e>>6),t(128|e&63);return}else if(e<=65535){t(224|e>>12),t(128|e>>6&63),t(128|e&63);return}else if(e<=1114111){t(240|e>>18),t(128|e>>12&63),t(128|e>>6&63),t(128|e&63);return}throw new Error(`Unrecognized Unicode codepoint: ${e.toString(16)}`)}function pO(e,t){for(let r=0;r<e.length;r+=1){let n=e.charCodeAt(r);if(n>55295&&n<=56319){const i=(n-55296)*1024&65535;n=(e.charCodeAt(r+1)-56320&65535|i)+65536,r+=1}hO(n,t)}}function mO(e,t,r){if(t.utf8seq===0){if(e<=127){r(e);return}for(let n=1;n<6;n+=1)if((e>>7-n&1)===0){t.utf8seq=n;break}if(t.utf8seq===2)t.codepoint=e&31;else if(t.utf8seq===3)t.codepoint=e&15;else if(t.utf8seq===4)t.codepoint=e&7;else throw new Error("Invalid UTF-8 sequence");t.utf8seq-=1}else if(t.utf8seq>0){if(e<=127)throw new Error("Invalid UTF-8 sequence");t.codepoint=t.codepoint<<6|e&63,t.utf8seq-=1,t.utf8seq===0&&r(t.codepoint)}}function xi(e){const t=[],r={queue:0,queuedBits:0},n=i=>{t.push(i)};for(let i=0;i<e.length;i+=1)$x(e.charCodeAt(i),r,n);return new Uint8Array(t)}function gO(e){const t=[];return pO(e,r=>t.push(r)),new Uint8Array(t)}function fo(e){const t=[],r={queue:0,queuedBits:0},n=i=>{t.push(i)};return e.forEach(i=>y0(i,r,n)),y0(null,r,n),t.join("")}function vO(e){return Math.round(Date.now()/1e3)+e}function yO(){return Symbol("auth-callback")}const Ht=()=>typeof window<"u"&&typeof document<"u",so={tested:!1,writable:!1},Fx=()=>{if(!Ht())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(so.tested)return so.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),so.tested=!0,so.writable=!0}catch{so.tested=!0,so.writable=!1}return so.writable};function wO(e){const t={},r=new URL(e);if(r.hash&&r.hash[0]==="#")try{new URLSearchParams(r.hash.substring(1)).forEac
295h((i,a)=>{t[a]=i})}catch{}return r.searchParams.forEach((n,i)=>{t[i]=n}),t}const Ux=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),bO=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",vi=async(e,t,r)=>{await e.setItem(t,JSON.stringify(r))},oo=async(e,t)=>{const r=await e.getItem(t);if(!r)return null;try{return JSON.parse(r)}catch{return r}},Vt=async(e,t)=>{await e.removeItem(t)};class Qu{constructor(){this.promise=new Qu.promiseConstructor((t,r)=>{this.resolve=t,this.reject=r})}}Qu.promiseConstructor=Promise;function tu(e){const t=e.split(".");if(t.length!==3)throw new Ep("Invalid JWT structure");for(let n=0;n<t.length;n++)if(!iO.test(t[n]))throw new Ep("JWT not in base64url format");return{header:JSON.parse(w0(t[0])),payload:JSON.parse(w0(t[1])),signature:xi(t[2]),raw:{header:t[0],payload:t[1]}}}async function xO(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function _O(e,t){return new Promise((n,i)=>{(async()=>{for(let a=0;a<1/0;a++)try{const l=await e(a);if(!t(a,null,l)){n(l);return}}catch(l){if(!t(a,l)){i(l);return}}})()})}function SO(e){return("0"+e.toString(16)).substr(-2)}function EO(){const t=new Uint32Array(56);if(typeof crypto>"u"){const r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",n=r.length;let i="";for(let a=0;a<56;a++)i+=r.charAt(Math.floor(Math.random()*n));return i}return crypto.getRandomValues(t),Array.from(t,SO).join("")}async function kO(e){const r=new TextEncoder().encode(e),n=await crypto.subtle.digest("SHA-256",r),i=new Uint8Array(n);return Array.from(i).map(a=>String.fromCharCode(a)).join("")}async function TO(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const r=await kO(e);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function li(e,t,r=!1){const n=EO();let i=n;r&&(i+="/PASSWORD_RECOVERY"),await vi(e,`${t}-code-verifier`,i);const a=await TO(n);return[a,n===a?"plain":"s256"]}const CO=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function RO(e){const t=e.headers.get(_p);if(!t||!t.match(CO))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function PO(e){if(!e)throw new Error("Missing exp claim");const t=Math.floor(Date.now()/1e3);if(e<=t)throw new Error("JWT has expired")}function jO(e){switch(e){case"RS256":return{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}};case"ES256":return{name:"ECDSA",namedCurve:"P-256",hash:{name:"SHA-256"}};default:throw new Error("Invalid alg claim")}}const OO=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function ci(e){if(!OO.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function mh(){const e={};return new Proxy(e,{get:(t,r)=>{if(r==="__isUserNotAvailableProxy")return!0;if(typeof r=="symbol"){const n=r.toString();if(n==="Symbol(Symbol.toPrimitive)"||n==="Symbol(Symbol.toStringTag)"||n==="Symbol(util.inspect.custom)")return}throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Accessing the "${r}" property of the session object is not supported. Please use getUser() instead.`)},set:(t,r)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Setting the "${r}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)},deleteProperty:(t,r)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Deleting the "${r}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)}})}function AO(e,t){return new Proxy(e,{get:(r,n,i)=>{if(n==="__isInsecureUserWarningProxy")return!0;if(typeof n=="symbol"){const a=n.toString();if(a==="Symbol(Symbol.toPrimitive)"||a==="Symbol(Symbol.toStringTag)"||a==="Symbol(util.inspect.custom)"||a==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(r,n,i)}return!t.value&&typeof n=="string"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),t.value=!0),Reflect.get(r,n,i)}})}function b0(e){return JSON.parse(JSON.stringify(e))}const ao=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),NO=[502,503,504];async function x0(e){var t;if(!bO(e))throw new Sp(ao(e),0);if(NO.includes(e.status))throw new Sp(ao(e),e.status);let r;try{r=await e.json()}catch(a){throw new co(ao(a),a)}let n;const i=RO(e);if(i&&i.getTime()>=Mx["2024-01-01"].timestamp&&typeof r=="object"&&r&&typeof r.code=="string"?n=r.code:typeof r=="object"&&r&&typeof r.error_code=="string"&&(n=r.error_code),n){if(n==="weak_password")throw new g0(ao(r),e.status,((t=r.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(n==="session_not_found")throw new kr}else if(typeof r=="object"&&r&&typeof r.weak_password=="object"&&r.weak_password&&Array.isArray(r.weak_password.reasons)&&r.weak_password.reasons.length&&r.weak_password.reasons.reduce((a,l)=>a&&typeof l=="string",!0))throw new g0(ao(r),e.status,r.weak_password.reasons);throw new lO(ao(r),e.status||500,n)}const IO=(e,t,r,n)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),i.body=JSON.stringify(n),Object.assign(Object.assign({},i),r))};async function Ne(e,t,r,n){var i;const a=Object.assign({},n==null?void 0:n.headers);a[_p]||(a[_p]=Mx["2024-01-01"].name),n!=null&&n.jwt&&(a.Authorization=`Bearer ${n.jwt}`);const l=(i=n==null?void 0:n.query)!==null&&i!==void 0?i:{};n!=null&&n.redirectTo&&(l.redirect_to=n.redirectTo);const u=Object.keys(l).length?"?"+new URLSearchParams(l).toString():"",f=await LO(e,t,r+u,{headers:a,noResolveJson:n==null?void 0:n.noResolveJson},{},n==null?void 0:n.body);return n!=null&&n.xform?n==null?void 0:n.xform(f):{data:Object.assign({},f),error:null}}async function LO(e,t,r,n,i,a){const l=IO(t,n,i,a);let u;
295try{u=await e(r,Object.assign({},l))}catch(f){throw console.error(f),new Sp(ao(f),0)}if(u.ok||await x0(u),n!=null&&n.noResolveJson)return u;try{return await u.json()}catch(f){await x0(f)}}function Yr(e){var t;let r=null;$O(e)&&(r=Object.assign({},e),e.expires_at||(r.expires_at=vO(e.expires_in)));const n=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:r,user:n},error:null}}function _0(e){const t=Yr(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((r,n)=>r&&typeof n=="string",!0)&&(t.data.weak_password=e.weak_password),t}function _s(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function DO(e){return{data:e,error:null}}function MO(e){const{action_link:t,email_otp:r,hashed_token:n,redirect_to:i,verification_type:a}=e,l=Hi(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),u={action_link:t,email_otp:r,hashed_token:n,redirect_to:i,verification_type:a},f=Object.assign({},l);return{data:{properties:u,user:f},error:null}}function S0(e){return e}function $O(e){return e.access_token&&e.refresh_token&&e.expires_in}const gh=["global","local","others"];class FO{constructor({url:t="",headers:r={},fetch:n}){this.url=t,this.headers=r,this.fetch=Ux(n),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)},this.customProviders={listProviders:this._listCustomProviders.bind(this),createProvider:this._createCustomProvider.bind(this),getProvider:this._getCustomProvider.bind(this),updateProvider:this._updateCustomProvider.bind(this),deleteProvider:this._deleteCustomProvider.bind(this)}}async signOut(t,r=gh[0]){if(gh.indexOf(r)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${gh.join(", ")}`);try{return await Ne(this.fetch,"POST",`${this.url}/logout?scope=${r}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(n){if(xe(n))return{data:null,error:n};throw n}}async inviteUserByEmail(t,r={}){try{return await Ne(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:r.data},headers:this.headers,redirectTo:r.redirectTo,xform:_s})}catch(n){if(xe(n))return{data:{user:null},error:n};throw n}}async generateLink(t){try{const{options:r}=t,n=Hi(t,["options"]),i=Object.assign(Object.assign({},n),r);return"newEmail"in n&&(i.new_email=n==null?void 0:n.newEmail,delete i.newEmail),await Ne(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:i,headers:this.headers,xform:MO,redirectTo:r==null?void 0:r.redirectTo})}catch(r){if(xe(r))return{data:{properties:null,user:null},error:r};throw r}}async createUser(t){try{return await Ne(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:_s})}catch(r){if(xe(r))return{data:{user:null},error:r};throw r}}async listUsers(t){var r,n,i,a,l,u,f;try{const p={nextPage:null,lastPage:0,total:0},m=await Ne(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(n=(r=t==null?void 0:t.page)===null||r===void 0?void 0:r.toString())!==null&&n!==void 0?n:"",per_page:(a=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&a!==void 0?a:""},xform:S0});if(m.error)throw m.error;const g=await m.json(),b=(l=m.headers.get("x-total-count"))!==null&&l!==void 0?l:0,w=(f=(u=m.headers.get("link"))===null||u===void 0?void 0:u.split(","))!==null&&f!==void 0?f:[];return w.length>0&&(w.forEach(S=>{const _=parseInt(S.split(";")[0].split("=")[1].substring(0,1)),E=JSON.parse(S.split(";")[1].split("=")[1]);p[`${E}Page`]=_}),p.total=parseInt(b)),{data:Object.assign(Object.assign({},g),p),error:null}}catch(p){if(xe(p))return{data:{users:[]},error:p};throw p}}async getUserById(t){ci(t);try{return await Ne(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:_s})}catch(r){if(xe(r))return{data:{user:null},error:r};throw r}}async updateUserById(t,r){ci(t);try{return await Ne(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:r,headers:this.headers,xform:_s})}catch(n){if(xe(n))return{data:{user:null},error:n};throw n}}async deleteUser(t,r=!1){ci(t);
295try{return await Ne(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:r},xform:_s})}catch(n){if(xe(n))return{data:{user:null},error:n};throw n}}async _listFactors(t){ci(t.userId);try{const{data:r,error:n}=await Ne(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:i=>({data:{factors:i},error:null})});return{data:r,error:n}}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _deleteFactor(t){ci(t.userId),ci(t.id);try{return{data:await Ne(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _listOAuthClients(t){var r,n,i,a,l,u,f;try{const p={nextPage:null,lastPage:0,total:0},m=await Ne(this.fetch,"GET",`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(n=(r=t==null?void 0:t.page)===null||r===void 0?void 0:r.toString())!==null&&n!==void 0?n:"",per_page:(a=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&a!==void 0?a:""},xform:S0});if(m.error)throw m.error;const g=await m.json(),b=(l=m.headers.get("x-total-count"))!==null&&l!==void 0?l:0,w=(f=(u=m.headers.get("link"))===null||u===void 0?void 0:u.split(","))!==null&&f!==void 0?f:[];return w.length>0&&(w.forEach(S=>{const _=parseInt(S.split(";")[0].split("=")[1].substring(0,1)),E=JSON.parse(S.split(";")[1].split("=")[1]);p[`${E}Page`]=_}),p.total=parseInt(b)),{data:Object.assign(Object.assign({},g),p),error:null}}catch(p){if(xe(p))return{data:{clients:[]},error:p};throw p}}async _createOAuthClient(t){try{return await Ne(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _getOAuthClient(t){try{return await Ne(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _updateOAuthClient(t,r){try{return await Ne(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${t}`,{body:r,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(xe(n))return{data:null,error:n};throw n}}async _deleteOAuthClient(t){try{return await Ne(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _regenerateOAuthClientSecret(t){try{return await Ne(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _listCustomProviders(t){try{const r={};return t!=null&&t.type&&(r.type=t.type),await Ne(this.fetch,"GET",`${this.url}/admin/custom-providers`,{headers:this.headers,query:r,xform:n=>{var i;return{data:{providers:(i=n==null?void 0:n.providers)!==null&&i!==void 0?i:[]},error:null}}})}catch(r){if(xe(r))return{data:{providers:[]},error:r};throw r}}async _createCustomProvider(t){try{return await Ne(this.fetch,"POST",`${this.url}/admin/custom-providers`,{body:t,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _getCustomProvider(t){try{return await Ne(this.fetch,"GET",`${this.url}/admin/custom-providers/${t}`,{headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(xe(r))return{data:null,error:r};throw r}}async _updateCustomProvider(t,r){try{return await Ne(this.fetch,"PUT",`${this.url}/admin/custom-providers/${t}`,{body:r,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(xe(n))return{data:null,error:n};throw n}}async _deleteCustomProvider(t){try{return await Ne(this.fetch,"DELETE",`${this.url}/admin/custom-providers/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(r){if(xe(r))return{data:null,error:r};throw r}}}function E0(e={}){return{getItem:t=>e[t]||null,setItem:(t,r)=>{e[t]=r},removeItem:t=>{delete e[t]}}}const wn={debug:!!(globalThis&&Fx()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};
295class zx extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class k0 extends zx{}async function UO(e,t,r){wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const n=new globalThis.AbortController;let i;t>0&&(i=setTimeout(()=>{n.abort(),wn.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t)),await Promise.resolve();try{return await globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:n.signal},async a=>{if(a){clearTimeout(i),wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,a.name);try{return await r()}finally{wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,a.name)}}else{if(t===0)throw wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new k0(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(wn.debug)try{const l=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(l,null,"  "))}catch(l){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",l)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),clearTimeout(i),await r()}})}catch(a){if(t>0&&clearTimeout(i),(a==null?void 0:a.name)==="AbortError"&&t>0){if(n.signal.aborted)return wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire timeout, recovering by stealing lock",e),console.warn(`@supabase/gotrue-js: Lock "${e}" was not released within ${t}ms. This may indicate an orphaned lock from a component unmount (e.g., React Strict Mode). Forcefully acquiring the lock to recover.`),await Promise.resolve().then(()=>globalThis.navigator.locks.request(e,{mode:"exclusive",steal:!0},async l=>{if(l){wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: recovered (stolen)",e,l.name);try{return await r()}finally{wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: released (stolen)",e,l.name)}}else return console.warn("@supabase/gotrue-js: Navigator LockManager returned null lock even with steal: true"),await r()}));throw wn.debug&&console.log("@supabase/gotrue-js: navigatorLock: lock was stolen by another request",e),new k0(`Lock "${e}" was released because another request stole it`)}throw a}}function zO(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}function Bx(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}" is invalid.`);return e.toLowerCase()}function BO(e){return parseInt(e,16)}function qO(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,n=>n.toString(16).padStart(2,"0")).join("")}function VO(e){var t;const{chainId:r,domain:n,expirationTime:i,issuedAt:a=new Date,nonce:l,notBefore:u,requestId:f,resources:p,scheme:m,uri:g,version:b}=e;{if(!Number.isInteger(r))throw new Error(`@supabase/auth-js: Invalid SIWE message field "chainId". Chain ID must be a EIP-155 chain ID. Provided value: ${r}`);if(!n)throw new Error('@supabase/auth-js: Invalid SIWE message field "domain". Domain must be provided.');if(l&&l.length<8)throw new Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${l}`);if(!g)throw new Error('@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.');if(b!=="1")throw new Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${b}`);if(!((t=e.statement)===null||t===void 0)&&t.includes(`
296`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const w=Bx(e.address),S=m?`${m}://${n}`:n,_=e.statement?`${e.statement}
297`:"",E=`${S} wants you to sign in with your Ethereum account:
298${w}
299
300${_}`;let k=`URI: ${g}
301Version: ${b}
302Chain ID: ${r}${l?`
303Nonce: ${l}`:""}
304Issued At: ${a.toISOString()}`;if(i&&(k+=`
305Expiration Time: ${i.toISOString()}`),u&&(k+=`
306Not Before: ${u.toISOString()}`),f&&(k+=`
307Request ID: ${f}`),p){let T=`
308Resources:`;for(const R of p){if(!R||typeof R!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${R}`);T+=`
309- ${R}`}k+=T}return`${E}
310${k}`}
310class jt extends Error{constructor({message:t,code:r,cause:n,name:i}){var a;super(t,{cause:n}),this.__isWebAuthnError=!0,this.name=(a=i??(n instanceof Error?n.name:void 0))!==null&&a!==void 0?a:"Unknown Error",this.code=r}}class Su extends jt{constructor(t,r){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:r,message:t}),this.name="WebAuthnUnknownError",this.originalError=r}}function WO({error:e,options:t}){var r,n,i;const{publicKey:a}=t;if(!a)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new jt({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else if(e.name==="ConstraintError"){if(((r=a.authenticatorSelection)===null||r===void 0?void 0:r.requireResidentKey)===!0)return new jt({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:e});if(t.mediation==="conditional"&&((n=a.authenticatorSelection)===null||n===void 0?void 0:n.userVerification)==="required")return new jt({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:e});if(((i=a.authenticatorSelection)===null||i===void 0?void 0:i.userVerification)==="required")return new jt({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:e})}else{if(e.name==="InvalidStateError")return new jt({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new jt({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="NotSupportedError")return a.pubKeyCredParams.filter(u=>u.type==="public-key").length===0?new jt({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new jt({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:e});if(e.name==="SecurityError"){const l=window.location.hostname;if(qx(l)){if(a.rp.id!==l)return new jt({message:`The RP ID "${a.rp.id}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new jt({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="TypeError"){if(a.user.id.byteLength<1||a.user.id.byteLength>64)return new jt({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:e})}else if(e.name==="UnknownError")return new jt({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new jt({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function HO({error:e,options:t}){const{publicKey:r}=t;if(!r)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new jt({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new jt({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const n=window.location.hostname;if(qx(n)){if(r.rpId!==n)return new jt({message:`The RP ID "${r.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new jt({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new jt({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new jt({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}class KO{createNewAbortSignal(){if(this.controller){const r=new Error("Cancelling existing WebAuthn API call for new one");r.name="AbortError",this.controller.abort(r)}const t=new AbortController;return this.controller=t,t.signal}cancelCeremony(){if(this.controller){const t=new Error("Manually cancelling existing WebAuthn API call");t.name="AbortError",this.controller.abort(t),this.controller=void 0}}}const GO=new KO;function QO(e){if(!e)throw new Error("Credential creation options are required");if(typeof PublicKeyCredential<"u"&&"parseCreationOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const{challenge:t,user:r,excludeCredentials:n}=e,i=Hi(e,["challenge","user","excludeCredentials"]),a=xi(t).buffer,l=Object.assign(Object.assign({},r),{id:xi(r.id).buffer}),u=Object.assign(Object.assign({},i),{challenge:a,user:l});if(n&&n.length>0){u.excludeCredentials=new Array(n.length);for(let f=0;f<n.length;f++){const p=n[f];u.excludeCredentials[f]=Object.assign(Object.assign({},p),{id:xi(p.id).buffer,type:p.type||"public-key",transports:p.transports})}}return u}function YO(e){if(!e)throw new Error("Credential request options are required");if(typeof PublicKeyCredential<"u"&&"parseRequestOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const{challenge:t,allowCredentials:r}=e,n=Hi(e,["challenge","allowCredentials"]),i=xi(t).buffer,a=Object.assign(Object.assign({}
310,n),{challenge:i});if(r&&r.length>0){a.allowCredentials=new Array(r.length);for(let l=0;l<r.length;l++){const u=r[l];a.allowCredentials[l]=Object.assign(Object.assign({},u),{id:xi(u.id).buffer,type:u.type||"public-key",transports:u.transports})}}return a}function JO(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const r=e;return{id:e.id,rawId:e.id,response:{attestationObject:fo(new Uint8Array(e.response.attestationObject)),clientDataJSON:fo(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=r.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function XO(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const r=e,n=e.getClientExtensionResults(),i=e.response;return{id:e.id,rawId:e.id,response:{authenticatorData:fo(new Uint8Array(i.authenticatorData)),clientDataJSON:fo(new Uint8Array(i.clientDataJSON)),signature:fo(new Uint8Array(i.signature)),userHandle:i.userHandle?fo(new Uint8Array(i.userHandle)):void 0},type:"public-key",clientExtensionResults:n,authenticatorAttachment:(t=r.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function qx(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function T0(){var e,t;return!!(Ht()&&"PublicKeyCredential"in window&&window.PublicKeyCredential&&"credentials"in navigator&&typeof((e=navigator==null?void 0:navigator.credentials)===null||e===void 0?void 0:e.create)=="function"&&typeof((t=navigator==null?void 0:navigator.credentials)===null||t===void 0?void 0:t.get)=="function")}async function ZO(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Su("Browser returned unexpected credential type",t)}:{data:null,error:new Su("Empty credential response",t)}}catch(t){return{data:null,error:WO({error:t,options:e})}}}async function eA(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Su("Browser returned unexpected credential type",t)}:{data:null,error:new Su("Empty credential response",t)}}catch(t){return{data:null,error:HO({error:t,options:e})}}}const tA={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},rA={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function Eu(...e){const t=i=>i!==null&&typeof i=="object"&&!Array.isArray(i),r=i=>i instanceof ArrayBuffer||ArrayBuffer.isView(i),n={};for(const i of e)if(i)for(const a in i){const l=i[a];if(l!==void 0)if(Array.isArray(l))n[a]=l;else if(r(l))n[a]=l;else if(t(l)){const u=n[a];t(u)?n[a]=Eu(u,l):n[a]=Eu(l)}else n[a]=l}return n}function nA(e,t){return Eu(tA,e,t||{})}function sA(e,t){return Eu(rA,e,t||{})}class oA{constructor(t){this.client=t,this.enroll=this._enroll.bind(this),this.challenge=this._challenge.bind(this),this.verify=this._verify.bind(this),this.authenticate=this._authenticate.bind(this),this.register=this._register.bind(this)}async _enroll(t){return this.client.mfa.enroll(Object.assign(Object.assign({},t),{factorType:"webauthn"}))}async _challenge({factorId:t,webauthn:r,friendlyName:n,signal:i},a){var l;try{const{data:u,error:f}=await this.client.mfa.challenge({factorId:t,webauthn:r});if(!u)return{data:null,error:f};const p=i??GO.createNewAbortSignal();if(u.webauthn.type==="create"){const{user:m}=u.webauthn.credential_options.publicKey;if(!m.name){const g=n;if(g)m.name=`${m.id}:${g}`;else{const w=(await this.client.getUser()).data.user,S=((l=w==null?void 0:w.user_metadata)===null||l===void 0?void 0:l.name)||(w==null?void 0:w.email)||(w==null?void 0:w.id)||"User";m.name=`${m.id}:${S}`}}m.displayName||(m.displayName=m.name)}switch(u.webauthn.type){case"create":{const m=nA(u.webauthn.credential_options.publicKey,a==null?void 0:a.create),{data:g,error:b}=await ZO({publicKey:m,signal:p});return g?{data:{factorId:t,challengeId:u.id,webauthn:{type:u.webauthn.type,credential_response:g}},error:null}:{data:null,error:b}}case"request":{const m=sA(u.webauthn.credential_options.publicKey,a==null?void 0:a.request),{data:g,error:b}=await eA(Object.assign(Object.assign({},u.webauthn.credential_options),{publicKey:m,signal:p}));return g?{data:{factorId:t,challengeId:u.id,webauthn:{type:u.webauthn.type,credential_response:g}},error:null}:{data:null,error:b}}}}catch(u){return xe(u)?{data:null,error:u}:{data:null,error:new co("Unexpected error in challenge",u)}}}async _verify({challengeId:t,factorId:r,webauthn:n}){return this.client.mfa.verify({factorId:r,challengeId:t,webauthn:n})}async _authenticate({factorId:t,webauthn:{rpId:r=typeof window<"u"?window.location.hostname:void 0,rpOrigins:n=typeof window<"u"?[window.location.origin]:void 0,signal:i}={}},a){if(!r)return{data:null,error:new il("rpId is required for WebAuthn authentication")};try{if(!T0())return{data:null,error:new co("Browser does not support WebAuthn",null)};const{data:l,error:u}=await this.challenge({factorId:t,webauthn:{rpId:r,rpOrigins:n},signal:i},{request:a});if(!l)return{data:null,error:u};const{webauthn:f}=l;return this._verify({factorId:t,challengeId:l.challengeId,webauthn:{type:f.type,rpId:r,rpOrigins:n,credential_response:f.credential_response}})}catch(l){return xe(l)?{data:null,error:l}:{data:null,error:new co("Unexpected error in authenticate",l)}
310}}async _register({friendlyName:t,webauthn:{rpId:r=typeof window<"u"?window.location.hostname:void 0,rpOrigins:n=typeof window<"u"?[window.location.origin]:void 0,signal:i}={}},a){if(!r)return{data:null,error:new il("rpId is required for WebAuthn registration")};try{if(!T0())return{data:null,error:new co("Browser does not support WebAuthn",null)};const{data:l,error:u}=await this._enroll({friendlyName:t});if(!l)return await this.client.mfa.listFactors().then(m=>{var g;return(g=m.data)===null||g===void 0?void 0:g.all.find(b=>b.factor_type==="webauthn"&&b.friendly_name===t&&b.status!=="unverified")}).then(m=>m?this.client.mfa.unenroll({factorId:m==null?void 0:m.id}):void 0),{data:null,error:u};const{data:f,error:p}=await this._challenge({factorId:l.id,friendlyName:l.friendly_name,webauthn:{rpId:r,rpOrigins:n},signal:i},{create:a});return f?this._verify({factorId:l.id,challengeId:f.challengeId,webauthn:{rpId:r,rpOrigins:n,type:f.webauthn.type,credential_response:f.webauthn.credential_response}}):{data:null,error:p}}catch(l){return xe(l)?{data:null,error:l}:{data:null,error:new co("Unexpected error in register",l)}}}}zO();const iA={url:nO,storageKey:sO,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:oO,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:5e3,skipAutoInitialize:!1};async function C0(e,t,r){return await r()}const ui={};class al{get jwks(){var t,r;return(r=(t=ui[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&r!==void 0?r:{keys:[]}}set jwks(t){ui[this.storageKey]=Object.assign(Object.assign({},ui[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,r;return(r=(t=ui[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&r!==void 0?r:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){ui[this.storageKey]=Object.assign(Object.assign({},ui[this.storageKey]),{cachedAt:t})}constructor(t){var r,n,i;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;const a=Object.assign(Object.assign({},iA),t);if(this.storageKey=a.storageKey,this.instanceID=(r=al.nextInstanceID[this.storageKey])!==null&&r!==void 0?r:0,al.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!a.debug,typeof a.debug=="function"&&(this.logger=a.debug),this.instanceID>0&&Ht()){const l=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(l),this.logDebugMessages&&console.trace(l)}if(this.persistSession=a.persistSession,this.autoRefreshToken=a.autoRefreshToken,this.admin=new FO({url:a.url,headers:a.headers,fetch:a.fetch}),this.url=a.url,this.headers=a.headers,this.fetch=Ux(a.fetch),this.lock=a.lock||C0,this.detectSessionInUrl=a.detectSessionInUrl,this.flowType=a.flowType,this.hasCustomAuthorizationHeader=a.hasCustomAuthorizationHeader,this.throwOnError=a.throwOnError,this.lockAcquireTimeout=a.lockAcquireTimeout,a.lock?this.lock=a.lock:this.persistSession&&Ht()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=UO:this.lock=C0,this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=Number.MIN_SAFE_INTEGER),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this),webauthn:new oA(this)},this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.persistSession?(a.storage?this.storage=a.storage:Fx()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=E0(this.memoryStorage)),a.userStorage&&(this.userStorage=a.userStorage)):(this.memoryStorage={},this.storage=E0(this.memoryStorage)),Ht()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(l){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",l)}(i=this.broadcastChannel)===null||i===void 0||i.addEventListener("message",async l=>{this._debug("received broadcast notification from other tab or client",l);try{await this._notifyAllSubscribers(l.data.event,l.data.session,!1)}catch(u){this._debug("#broadcastChannel","error",u)}})}a.skipAutoInitialize||this.initialize().catch(l=>{this._debug("#initialize()","error",l)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(t){if(this.throwOnError&&t&&t.error)throw t.error;return t}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${Dx}) ${new Date().toISOString()}`}_debug(...t){return this.logDebugMessages&&this.logger(this._logPrefix(),...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var t;try{let r={},n="none";if(Ht()&&(r=wO(window.location.href),this._isImplicitGrantCallback(r)?n="implicit":await this._isPKCECallback(r)&&(n="pkce")),Ht()&&this.detectSessionInUrl&&n!=="none"){const{data:i,error:a}=await this._getSessionFromURL(r,n);if(a){if(this._debug("#_initialize()","error detecting session from URL",a),uO(a
310)){const f=(t=a.details)===null||t===void 0?void 0:t.code;if(f==="identity_already_exists"||f==="identity_not_found"||f==="single_identity_not_deletable")return{error:a}}return{error:a}}const{session:l,redirectType:u}=i;return this._debug("#_initialize()","detected session in URL",l,"redirect type",u),await this._saveSession(l),setTimeout(async()=>{u==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",l):await this._notifyAllSubscribers("SIGNED_IN",l)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(r){return xe(r)?this._returnResult({error:r}):this._returnResult({error:new co("Unexpected error during initialization",r)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var r,n,i;try{const a=await Ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(n=(r=t==null?void 0:t.options)===null||r===void 0?void 0:r.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:(i=t==null?void 0:t.options)===null||i===void 0?void 0:i.captchaToken}},xform:Yr}),{data:l,error:u}=a;if(u||!l)return this._returnResult({data:{user:null,session:null},error:u});const f=l.session,p=l.user;return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",f)),this._returnResult({data:{user:p,session:f},error:null})}catch(a){if(xe(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signUp(t){var r,n,i;try{let a;if("email"in t){const{email:m,password:g,options:b}=t;let w=null,S=null;this.flowType==="pkce"&&([w,S]=await li(this.storage,this.storageKey)),a=await Ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:b==null?void 0:b.emailRedirectTo,body:{email:m,password:g,data:(r=b==null?void 0:b.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:b==null?void 0:b.captchaToken},code_challenge:w,code_challenge_method:S},xform:Yr})}else if("phone"in t){const{phone:m,password:g,options:b}=t;a=await Ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:m,password:g,data:(n=b==null?void 0:b.data)!==null&&n!==void 0?n:{},channel:(i=b==null?void 0:b.channel)!==null&&i!==void 0?i:"sms",gotrue_meta_security:{captcha_token:b==null?void 0:b.captchaToken}},xform:Yr})}else throw new Zc("You must provide either an email or phone number and a password");const{data:l,error:u}=a;if(u||!l)return await Vt(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:u});const f=l.session,p=l.user;return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",f)),this._returnResult({data:{user:p,session:f},error:null})}catch(a){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signInWithPassword(t){try{let r;if("email"in t){const{email:a,password:l,options:u}=t;r=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:a,password:l,gotrue_meta_security:{captcha_token:u==null?void 0:u.captchaToken}},xform:_0})}else if("phone"in t){const{phone:a,password:l,options:u}=t;r=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:a,password:l,gotrue_meta_security:{captcha_token:u==null?void 0:u.captchaToken}},xform:_0})}else throw new Zc("You must provide either an email or phone number and a password");const{data:n,error:i}=r;if(i)return this._returnResult({data:{user:null,session:null},error:i});if(!n||!n.session||!n.user){const a=new ai;return this._returnResult({data:{user:null,session:null},error:a})}return n.session&&(await this._saveSession(n.session),await this._notifyAllSubscribers("SIGNED_IN",n.session)),this._returnResult({data:Object.assign({user:n.user,session:n.session},n.weak_password?{weakPassword:n.weak_password}:null),error:i})}catch(r){if(xe(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async signInWithOAuth(t){var r,n,i,a;return await this._handleProviderSignIn(t.provider,{redirectTo:(r=t.options)===null||r===void 0?void 0:r.redirectTo,scopes:(n=t.options)===null||n===void 0?void 0:n.scopes,queryParams:(i=t.options)===null||i===void 0?void 0:i.queryParams,skipBrowserRedirect:(a=t.o
310ptions)===null||a===void 0?void 0:a.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(t))}async signInWithWeb3(t){const{chain:r}=t;switch(r){case"ethereum":return await this.signInWithEthereum(t);case"solana":return await this.signInWithSolana(t);default:throw new Error(`@supabase/auth-js: Unsupported chain "${r}"`)}}async signInWithEthereum(t){var r,n,i,a,l,u,f,p,m,g,b;let w,S;if("message"in t)w=t.message,S=t.signature;else{const{chain:_,wallet:E,statement:k,options:T}=t;let R;if(Ht())if(typeof E=="object")R=E;else{const ae=window;if("ethereum"in ae&&typeof ae.ethereum=="object"&&"request"in ae.ethereum&&typeof ae.ethereum.request=="function")R=ae.ethereum;else throw new Error("@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.")}else{if(typeof E!="object"||!(T!=null&&T.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");R=E}const P=new URL((r=T==null?void 0:T.url)!==null&&r!==void 0?r:window.location.href),O=await R.request({method:"eth_requestAccounts"}).then(ae=>ae).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!O||O.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const I=Bx(O[0]);let M=(n=T==null?void 0:T.signInWithEthereum)===null||n===void 0?void 0:n.chainId;if(!M){const ae=await R.request({method:"eth_chainId"});M=BO(ae)}const Y={domain:P.host,address:I,statement:k,uri:P.href,version:"1",chainId:M,nonce:(i=T==null?void 0:T.signInWithEthereum)===null||i===void 0?void 0:i.nonce,issuedAt:(l=(a=T==null?void 0:T.signInWithEthereum)===null||a===void 0?void 0:a.issuedAt)!==null&&l!==void 0?l:new Date,expirationTime:(u=T==null?void 0:T.signInWithEthereum)===null||u===void 0?void 0:u.expirationTime,notBefore:(f=T==null?void 0:T.signInWithEthereum)===null||f===void 0?void 0:f.notBefore,requestId:(p=T==null?void 0:T.signInWithEthereum)===null||p===void 0?void 0:p.requestId,resources:(m=T==null?void 0:T.signInWithEthereum)===null||m===void 0?void 0:m.resources};w=VO(Y),S=await R.request({method:"personal_sign",params:[qO(w),I]})}try{const{data:_,error:E}=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:w,signature:S},!((g=t.options)===null||g===void 0)&&g.captchaToken?{gotrue_meta_security:{captcha_token:(b=t.options)===null||b===void 0?void 0:b.captchaToken}}:null),xform:Yr});if(E)throw E;if(!_||!_.session||!_.user){const k=new ai;return this._returnResult({data:{user:null,session:null},error:k})}return _.session&&(await this._saveSession(_.session),await this._notifyAllSubscribers("SIGNED_IN",_.session)),this._returnResult({data:Object.assign({},_),error:E})}catch(_){if(xe(_))return this._returnResult({data:{user:null,session:null},error:_});throw _}}async signInWithSolana(t){var r,n,i,a,l,u,f,p,m,g,b,w;let S,_;if("message"in t)S=t.message,_=t.signature;else{const{chain:E,wallet:k,statement:T,options:R}=t;let P;if(Ht())if(typeof k=="object")P=k;else{const I=window;if("solana"in I&&typeof I.solana=="object"&&("signIn"in I.solana&&typeof I.solana.signIn=="function"||"signMessage"in I.solana&&typeof I.solana.signMessage=="function"))P=I.solana;else throw new Error("@supabase/auth-js: No compatible Solana wallet interface on the window object (window.solana) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'solana', wallet: resolvedUserWallet }) instead.")}else{if(typeof k!="object"||!(R!=null&&R.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");P=k}
310const O=new URL((r=R==null?void 0:R.url)!==null&&r!==void 0?r:window.location.href);if("signIn"in P&&P.signIn){const I=await P.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},R==null?void 0:R.signInWithSolana),{version:"1",domain:O.host,uri:O.href}),T?{statement:T}:null));let M;if(Array.isArray(I)&&I[0]&&typeof I[0]=="object")M=I[0];else if(I&&typeof I=="object"&&"signedMessage"in I&&"signature"in I)M=I;else throw new Error("@supabase/auth-js: Wallet method signIn() returned unrecognized value");if("signedMessage"in M&&"signature"in M&&(typeof M.signedMessage=="string"||M.signedMessage instanceof Uint8Array)&&M.signature instanceof Uint8Array)S=typeof M.signedMessage=="string"?M.signedMessage:new TextDecoder().decode(M.signedMessage),_=M.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in P)||typeof P.signMessage!="function"||!("publicKey"in P)||typeof P!="object"||!P.publicKey||!("toBase58"in P.publicKey)||typeof P.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");S=[`${O.host} wants you to sign in with your Solana account:`,P.publicKey.toBase58(),...T?["",T,""]:[""],"Version: 1",`URI: ${O.href}`,`Issued At: ${(i=(n=R==null?void 0:R.signInWithSolana)===null||n===void 0?void 0:n.issuedAt)!==null&&i!==void 0?i:new Date().toISOString()}`,...!((a=R==null?void 0:R.signInWithSolana)===null||a===void 0)&&a.notBefore?[`Not Before: ${R.signInWithSolana.notBefore}`]:[],...!((l=R==null?void 0:R.signInWithSolana)===null||l===void 0)&&l.expirationTime?[`Expiration Time: ${R.signInWithSolana.expirationTime}`]:[],...!((u=R==null?void 0:R.signInWithSolana)===null||u===void 0)&&u.chainId?[`Chain ID: ${R.signInWithSolana.chainId}`]:[],...!((f=R==null?void 0:R.signInWithSolana)===null||f===void 0)&&f.nonce?[`Nonce: ${R.signInWithSolana.nonce}`]:[],...!((p=R==null?void 0:R.signInWithSolana)===null||p===void 0)&&p.requestId?[`Request ID: ${R.signInWithSolana.requestId}`]:[],...!((g=(m=R==null?void 0:R.signInWithSolana)===null||m===void 0?void 0:m.resources)===null||g===void 0)&&g.length?["Resources",...R.signInWithSolana.resources.map(M=>`- ${M}`)]:[]].join(`
311`);const I=await P.signMessage(new TextEncoder().encode(S),"utf8");if(!I||!(I instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");_=I}}try{const{data:E,error:k}=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:S,signature:fo(_)},!((b=t.options)===null||b===void 0)&&b.captchaToken?{gotrue_meta_security:{captcha_token:(w=t.options)===null||w===void 0?void 0:w.captchaToken}}:null),xform:Yr});if(k)throw k;if(!E||!E.session||!E.user){const T=new ai;return this._returnResult({data:{user:null,session:null},error:T})}return E.session&&(await this._saveSession(E.session),await this._notifyAllSubscribers("SIGNED_IN",E.session)),this._returnResult({data:Object.assign({},E),error:k})}catch(E){if(xe(E))return this._returnResult({data:{user:null,session:null},error:E});throw E}}async _exchangeCodeForSession(t){const r=await oo(this.storage,`${this.storageKey}-code-verifier`),[n,i]=(r??"").split("/");try{if(!n&&this.flowType==="pkce")throw new dO;const{data:a,error:l}=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:n},xform:Yr});if(await Vt(this.storage,`${this.storageKey}-code-verifier`),l)throw l;if(!a||!a.session||!a.user){const u=new ai;return this._returnResult({data:{user:null,session:null,redirectType:null},error:u})}return a.session&&(await this._saveSession(a.session),await this._notifyAllSubscribers("SIGNED_IN",a.session)),this._returnResult({data:Object.assign(Object.assign({},a),{redirectType:i??null}),error:l})}catch(a){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(a))return this._returnResult({data:{user:null,session:null,redirectType:null},error:a});throw a}}async signInWithIdToken(t){try{const{options:r,provider:n,token:i,access_token:a,nonce:l}=t,u=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:n,id_token:i,access_token:a,nonce:l,gotrue_meta_security:{captcha_token:r==null?void 0:r.captchaToken}},xform:Yr}),{data:f,error:p}=u;if(p)return this._returnResult({data:{user:null,session:null},error:p});if(!f||!f.session||!f.user){const m=new ai;return this._returnResult({data:{user:null,session:null},error:m})}return f.session&&(await this._saveSession(f.session),await this._notifyAllSubscribers("SIGNED_IN",f.session)),this._returnResult({data:f,error:p})}catch(r){if(xe(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async signInWithOtp(t){var r,n,i,a,l;try{if("email"in t){const{email:u,options:f}=t;let p=null,m=null;this.flowType==="pkce"&&([p,m]=await li(this.storage,this.storageKey));const{error:g}=await Ne(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:u,data:(r=f==null?void 0:f.data)!==null&&r!==void 0?r:{},create_user:(n=f==null?void 0:f.shouldCreateUser)!==null&&n!==void 0?n:!0,gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken},code_challenge:p,code_challenge_method:m},redirectTo:f==null?void 0:f.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:g})}if("phone"in t){const{phone:u,options:f}=t,{data:p,error:m}=await Ne(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:u,data:(i=f==null?void 0:f.data)!==null&&i!==void 0?i:{},create_user:(a=f==null?void 0:f.shouldCreateUser)!==null&&a!==void 0?a:!0,gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken},channel:(l=f==null?void 0:f.channel)!==null&&l!==void 0?l:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:p==null?void 0:p.message_id},error:m})}throw new Zc("You must provide either an email or phone number.")}catch(u){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(u))return this._returnResult({data:{user:null,session:null},error:u});throw u}}async verifyOtp(t){var r,n;try{let i,a;"options"in t&&(i=(r=t.options)===null||r===void 0?void 0:r.redirectTo,a=(n=t.options)===null||n===void 0?void 0:n.captchaToken);const{data:l,error:u}=await Ne(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:a}}),redirectTo:i,xform:Yr});if(u)throw u;if(!l)throw new Error("An error occurred on token verification.");const f=l.session,p=l.user;return f!=null&&f.access_token&&(await this._saveSession(f),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",f)),this._returnResult({data:{user:p,session:f},error:null})}catch(i){if(xe(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signInWithSSO(t){var r,n,i,a,l;try{let u=null,f=null;this.flowType==="pkce"&&([u,f]=await li(this.storage,this.storageKey));const p=await Ne(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(n=(r=t.options)===null||r===void 0?void 0:r.redirectTo)!==null&&n!==void 0?n:void 0}),!((i=t==null?void 0:t.options)===null||i===void 0)&&i.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:u,code_challenge_method:f}),headers:this.headers,xform:DO});return!((a=p.data)===null||a===void 0)&&a.url&&Ht()&&!(!((l=t.options)===null||l===void 0)&&l.skipBrowserRedirect)&&window.location.assign(p.data.url),this._returnResult(p)}catch(u){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(u))return this._returnResult({data:null,error:u});throw u}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:r},error:n}=t;if(n)throw n;if(!r)throw new kr;const{error:i}=await Ne(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:r.access_token});return this._returnResult({data:{user:null,session:null},error:i})})}catch(t){if(xe(t))return this._returnResult({data:{user:null,session:null},error:t});throw t}}async resend(t){try{const r=`${this.url}/resend`;if("email"in t){const{email:n,type:i,options:a}=t,{error:l}=await Ne(this.fetch,"POST",r,{headers:this.headers,body:{email:n,type:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},redirectTo:a==null?void 0:a.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:l})}else if("phone"in t){const{phone:n,type:i,options:a}=t,{data:l,error:u}=await Ne(this.fetch,"POST",r,{headers:this.headers,body:{phone:n,type:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:l==null?void 0:l.message_id},error:u})}throw new Zc("You must provide either an email or phone number and a type")}catch(r){if(xe(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async getSession(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async r=>r))}async _acquireLock(t,r){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const n=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),i=(async()=>(await n,await r()))();return this.pendingInLock.push((async()=>{try{await i}catch{}})()),i}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const n=r();for(this.pendingInLock.push((async()=>{try{await n}catch{}})()),await n;this.pendingInLock.length;){const i=[...this.pendingInLock];await Promise.all(i),this.pendingInLock.splice(0,i.length)}return await n}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const r=await this.__loadSession();return await t(r)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const r=await oo(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",r),r!==null&&(this._isValidSession(r)?t=r:(this._debug("#getSession()","session from storage is not val
311id"),await this._removeSession())),!t)return{data:{session:null},error:null};const n=t.expires_at?t.expires_at*1e3-Date.now()<fh:!1;if(this._debug("#__loadSession()",`session has${n?"":" not"} expired`,"expires_at",t.expires_at),!n){if(this.userStorage){const l=await oo(this.userStorage,this.storageKey+"-user");l!=null&&l.user?t.user=l.user:t.user=mh()}if(this.storage.isServer&&t.user&&!t.user.__isUserNotAvailableProxy){const l={value:this.suppressGetSessionWarning};t.user=AO(t.user,l),l.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:t},error:null}}const{data:i,error:a}=await this._callRefreshToken(t.refresh_token);return a?this._returnResult({data:{session:null},error:a}):this._returnResult({data:{session:i},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(t){if(t)return await this._getUser(t);await this.initializePromise;const r=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return r.data.user&&(this.suppressGetSessionWarning=!0),r}async _getUser(t){try{return t?await Ne(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:_s}):await this._useSession(async r=>{var n,i,a;const{data:l,error:u}=r;if(u)throw u;return!(!((n=l.session)===null||n===void 0)&&n.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new kr}:await Ne(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(a=(i=l.session)===null||i===void 0?void 0:i.access_token)!==null&&a!==void 0?a:void 0,xform:_s})})}catch(r){if(xe(r))return hh(r)&&(await this._removeSession(),await Vt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:r});throw r}}async updateUser(t,r={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(t,r))}async _updateUser(t,r={}){try{return await this._useSession(async n=>{const{data:i,error:a}=n;if(a)throw a;if(!i.session)throw new kr;const l=i.session;let u=null,f=null;this.flowType==="pkce"&&t.email!=null&&([u,f]=await li(this.storage,this.storageKey));const{data:p,error:m}=await Ne(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:r==null?void 0:r.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:u,code_challenge_method:f}),jwt:l.access_token,xform:_s});if(m)throw m;return l.user=p.user,await this._saveSession(l),await this._notifyAllSubscribers("USER_UPDATED",l),this._returnResult({data:{user:l.user},error:null})})}catch(n){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(n))return this._returnResult({data:{user:null},error:n});throw n}}async setSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new kr;const r=Date.now()/1e3;let n=r,i=!0,a=null;const{payload:l}=tu(t.access_token);if(l.exp&&(n=l.exp,i=n<=r),i){const{data:u,error:f}=await this._callRefreshToken(t.refresh_token);if(f)return this._returnResult({data:{user:null,session:null},error:f});if(!u)return{data:{user:null,session:null},error:null};a=u}else{const{data:u,error:f}=await this._getUser(t.access_token);if(f)return this._returnResult({data:{user:null,session:null},error:f});a={access_token:t.access_token,refresh_token:t.refresh_token,user:u.user,token_type:"bearer",expires_in:n-r,expires_at:n},await this._saveSession(a),await this._notifyAllSubscribers("SIGNED_IN",a)}return this._returnResult({data:{user:a.user,session:a},error:null})}catch(r){if(xe(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async r=>{var n;if(!t){const{data:l,error:u}=r;if(u)throw u;t=(n=l.session)!==null&&n!==void 0?n:void 0}if(!(t!=null&&t.refresh_token))throw new kr;const{data:i,error:a}=await this._callRefreshToken(t.refresh_token);return a?this._returnResult({data:{user:null,session:null},error:a}):i?this._returnResult({data:{user:i.user,session:i},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(r){if(xe(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async _getSessionFromURL(t,r){try{if(!Ht())throw new eu("No browser detected.");
311if(t.error||t.error_description||t.error_code)throw new eu(t.error_description||"Error in URL with unspecified error_description",{error:t.error||"unspecified_error",code:t.error_code||"unspecified_code"});switch(r){case"implicit":if(this.flowType==="pkce")throw new m0("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new eu("Not a valid implicit grant flow url.");break;default:}if(r==="pkce"){if(this._debug("#_initialize()","begin","is PKCE flow",!0),!t.code)throw new m0("No code detected.");const{data:T,error:R}=await this._exchangeCodeForSession(t.code);if(R)throw R;const P=new URL(window.location.href);return P.searchParams.delete("code"),window.history.replaceState(window.history.state,"",P.toString()),{data:{session:T.session,redirectType:null},error:null}}const{provider_token:n,provider_refresh_token:i,access_token:a,refresh_token:l,expires_in:u,expires_at:f,token_type:p}=t;if(!a||!u||!l||!p)throw new eu("No session defined in URL");const m=Math.round(Date.now()/1e3),g=parseInt(u);let b=m+g;f&&(b=parseInt(f));const w=b-m;w*1e3<=gi&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${w}s, should have been closer to ${g}s`);const S=b-g;m-S>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",S,b,m):m-S<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",S,b,m);const{data:_,error:E}=await this._getUser(a);if(E)throw E;const k={provider_token:n,provider_refresh_token:i,access_token:a,expires_in:g,expires_at:b,refresh_token:l,token_type:p,user:_.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:k,redirectType:t.type},error:null})}catch(n){if(xe(n))return this._returnResult({data:{session:null,redirectType:null},error:n});throw n}}_isImplicitGrantCallback(t){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),t):!!(t.access_token||t.error_description)}async _isPKCECallback(t){const r=await oo(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&r)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a&&!hh(a))return this._returnResult({error:a});const l=(n=i.session)===null||n===void 0?void 0:n.access_token;if(l){const{error:u}=await this.admin.signOut(l,t);if(u&&!(cO(u)&&(u.status===404||u.status===401||u.status===403)||hh(u)))return this._returnResult({error:u})}return t!=="others"&&(await this._removeSession(),await Vt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(t){const r=yO(),n={id:r,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",r),this.stateChangeEmitters.delete(r)}};return this._debug("#onAuthStateChange()","registered callback with id",r),this.stateChangeEmitters.set(r,n),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(r)})))(),{data:{subscription:n}}}async _emitInitialSession(t){return await this._useSession(async r=>{var n,i;try{const{data:{session:a},error:l}=r;if(l)throw l;await((n=this.stateChangeEmitters.get(t))===null||n===void 0?void 0:n.callback("INITIAL_SESSION",a)),this._debug("INITIAL_SESSION","callback id",t,"session",a)}catch(a){await((i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",a),console.error(a)}})}async resetPasswordForEmail(t,r={}){let n=null,i=null;this.flowType==="pkce"&&([n,i]=await li(this.storage,this.storageKey,!0));try{return await Ne(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:n,code_challenge_method:i,gotrue_meta_security:{captcha_token:r.captchaToken}},headers:this.headers,redirectTo:r.redirectTo})}catch(a){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(a))return this._returnResult({data:null,error:a});throw a}}async getUserIdentities(){var t;try{const{data:r,error:n}=await this.getUser();if(n)throw n;return this._returnResult({data:{identities:(t=r.user.identities)!==null&&t!==void 0?t:[]},error:null})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async linkIdentity(t){return"token"in t?this.linkIdentityIdToken(t):this.linkIdentityOAuth(t)}async linkIdentityOAuth(t){var r;try{const{data:n,error:i}=await this._useSession(async a=>{var l,u,f,p,m;const{data:g,error:b}=a;if(b)throw b;const w=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(l=t.options)===null||l===void 0?void 0:l.redirectTo,scopes:(u=t.options)===null||u===void 0?void 0:u.scopes,queryParams:(f=t.options)===null||f===void 0?void 0:f.queryParams,skipBrowserRedirect:!0});return await Ne(this.fetch,"GET",w,{headers:this.headers,jwt:(m=(p=g.session)===null||p===void 0?void 0:p.access_token)!==null&&m!==void 0?m:void 0})});if(i)throw i;return Ht()&&!(!((r=t.options)===null||r===void 0)&&r.skipBrowserRedirect)&&window.location.assign(n==null?void 0:n.url),this._returnResult({data:{provider:t.provider,url:n==null?void 0:n.url},error:null})}catch(n){if(xe(n))return this._returnResult({data:{provider:t.provider,url:null},error:n});throw n}}async linkIdentityIdToken(t){return await this._useSession(async r=>{var n;try{const{error:i,data:{session:a}}=r;if(i)throw i;const{options:l,provider:u,token:f,access_token:p,nonce:m}
311=t,g=await Ne(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:(n=a==null?void 0:a.access_token)!==null&&n!==void 0?n:void 0,body:{provider:u,id_token:f,access_token:p,nonce:m,link_identity:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Yr}),{data:b,error:w}=g;return w?this._returnResult({data:{user:null,session:null},error:w}):!b||!b.session||!b.user?this._returnResult({data:{user:null,session:null},error:new ai}):(b.session&&(await this._saveSession(b.session),await this._notifyAllSubscribers("USER_UPDATED",b.session)),this._returnResult({data:b,error:w}))}catch(i){if(await Vt(this.storage,`${this.storageKey}-code-verifier`),xe(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}})}async unlinkIdentity(t){try{return await this._useSession(async r=>{var n,i;const{data:a,error:l}=r;if(l)throw l;return await Ne(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(i=(n=a.session)===null||n===void 0?void 0:n.access_token)!==null&&i!==void 0?i:void 0})})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async _refreshAccessToken(t){const r=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(r,"begin");try{const n=Date.now();return await _O(async i=>(i>0&&await xO(200*Math.pow(2,i-1)),this._debug(r,"refreshing attempt",i),await Ne(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Yr})),(i,a)=>{const l=200*Math.pow(2,i);return a&&ph(a)&&Date.now()+l-n<gi})}catch(n){if(this._debug(r,"error",n),xe(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}finally{this._debug(r,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,r){const n=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:r.redirectTo,scopes:r.scopes,queryParams:r.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",r,"url",n),Ht()&&!r.skipBrowserRedirect&&window.location.assign(n),{data:{provider:t,url:n},error:null}}async _recoverAndRefresh(){var t,r;const n="#_recoverAndRefresh()";this._debug(n,"begin");try{const i=await oo(this.storage,this.storageKey);if(i&&this.userStorage){let l=await oo(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!l&&(l={user:i.user},await vi(this.userStorage,this.storageKey+"-user",l)),i.user=(t=l==null?void 0:l.user)!==null&&t!==void 0?t:mh()}else if(i&&!i.user&&!i.user){const l=await oo(this.storage,this.storageKey+"-user");l&&(l!=null&&l.user)?(i.user=l.user,await Vt(this.storage,this.storageKey+"-user"),await vi(this.storage,this.storageKey,i)):i.user=mh()}if(this._debug(n,"session from storage",i),!this._isValidSession(i)){this._debug(n,"session is not valid"),i!==null&&await this._removeSession();return}const a=((r=i.expires_at)!==null&&r!==void 0?r:1/0)*1e3-Date.now()<fh;if(this._debug(n,`session has${a?"":" not"} expired with margin of ${fh}s`),a){if(this.autoRefreshToken&&i.refresh_token){const{error:l}=await this._callRefreshToken(i.refresh_token);l&&(console.error(l),ph(l)||(this._debug(n,"refresh failed with a non-retryable error, removing the session",l),await this._removeSession()))}}else if(i.user&&i.user.__isUserNotAvailableProxy===!0)try{const{data:l,error:u}=await this._getUser(i.access_token);!u&&(l!=null&&l.user)?(i.user=l.user,await this._saveSession(i),await this._notifyAllSubscribers("SIGNED_IN",i)):this._debug(n,"could not get user data, skipping SIGNED_IN notification")}catch(l){console.error("Error getting user data:",l),this._debug(n,"error getting user data, skipping SIGNED_IN notification",l)}else await this._notifyAllSubscribers("SIGNED_IN",i)}catch(i){this._debug(n,"error",i),console.error(i);return}finally{this._debug(n,"end")}}async _callRefreshToken(t){var r,n;if(!t)throw new kr;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const i=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(i,"begin");try{this.refreshingDeferred=new Qu;const{data:a,error:l}=await this._refreshAccessToken(t);if(l)throw l;if(!a.session)throw new kr;await this._saveSession(a.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",a.session);const u={data:a.session,error:null};return this.refreshingDeferred.resolve(u),u}catch(a){if(this._debug(i,"error",a),xe(a)){const l={data:null,error:a};return ph(a)||await this._removeSession(),(r=this.refreshingDeferred)===null||r===void 0||r.resolve(l),l}throw(n=this.refreshingDeferred)===null||n===void 0||n.reject(a),a}finally{this.refreshingDeferred=null,this._debug(i,"end")}}async _notifyAllSubscribers(t,r,n=!0){const i=`#_notifyAllSubscribers(${t})`;this._debug(i,"begin",r,`broadcast = ${n}`);try{this.broadcastChannel&&n&&this.broadcastChannel.postMessage({event:t,session:r});const a=[],l=Array.from(this.stateChangeEmitters.values()).map(async u=>{try{await u.callback(t,r)}catch(f){a.push(f)}});if(await Promise.all(l),a.length>0){for(let u=0;u<a.length;u+=1)console.error(a[u]);throw a[0]}}finally{this._debug(i,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await Vt(this.storage,`${this.storageKey}-code-verifier`);const r=Object.assign({},t),n=r.user&&r.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!n&&r.user&&await vi(this.userStorage,this.storageKey+"-user",{user:r.user});const i=Object.assign({},r);delete i.user;const a=b0(i);await vi(this.storage,this.storageKey,a)}else{const i=b0(r);await vi(this.storage,this.storageKey,i)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await Vt(this.storage,this.storageKey),await Vt(this.storage,this.storageKey+"-code-verifier"),await Vt(this.storage,this.storageKey+"-user"),this.userStorage&&await Vt(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&Ht()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}
311catch(r){console.error("removing visibilitychange callback failed",r)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),gi);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t);const r=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=r,r&&typeof r=="object"&&typeof r.unref=="function"?r.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(r)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t);const r=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,r&&clearTimeout(r)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async r=>{const{data:{session:n}}=r;if(!n||!n.refresh_token||!n.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const i=Math.floor((n.expires_at*1e3-t)/gi);this._debug("#_autoRefreshTokenTick()",`access token expires in ${i} ticks, a tick lasts ${gi}ms, refresh threshold is ${xp} ticks`),i<=xp&&await this._callRefreshToken(n.refresh_token)})}catch(r){console.error("Auto refresh tick failed with error. This is likely a transient error.",r)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof zx)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!Ht()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(t){this._debug("#visibilityChangedCallback","error",t)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const r=`#_onVisibilityChanged(${t})`;this._debug(r,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{if(document.visibilityState!=="visible"){this._debug(r,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,r,n){const i=[`provider=${encodeURIComponent(r)}`];if(n!=null&&n.redirectTo&&i.push(`redirect_to=${encodeURIComponent(n.redirectTo)}`),n!=null&&n.scopes&&i.push(`scopes=${encodeURIComponent(n.scopes)}`),this.flowType==="pkce"){const[a,l]=await li(this.storage,this.storageKey),u=new URLSearchParams({code_challenge:`${encodeURIComponent(a)}`,code_challenge_method:`${encodeURIComponent(l)}`});i.push(u.toString())}if(n!=null&&n.queryParams){const a=new URLSearchParams(n.queryParams);i.push(a.toString())}return n!=null&&n.skipBrowserRedirect&&i.push(`skip_http_redirect=${n.skipBrowserRedirect}`),`${t}?${i.join("&")}`}async _unenroll(t){try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;return a?this._returnResult({data:null,error:a}):await Ne(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token})})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async _enroll(t){try{return await this._useSession(async r=>{var n,i;const{data:a,error:l}=r;if(l)return this._returnResult({data:null,error:l});const u=Object.assign({friendly_name:t.friendlyName,factor_type:t.factorType},t.factorType==="phone"?{phone:t.phone}:t.factorType==="totp"?{issuer:t.issuer}:{}),{data:f,error:p}=await Ne(this.fetch,"POST",`${this.url}/factors`,{body:u,headers:this.headers,jwt:(n=a==null?void 0:a.session)===null||n===void 0?void 0:n.access_token});return p?this._returnResult({data:null,error:p}):(t.factorType==="totp"&&f.type==="totp"&&(!((i=f==null?void 0:f.totp)===null||i===void 0)&&i.qr_code)&&(f.totp.qr_code=`data:image/svg+xml;utf-8,${f.totp.qr_code}`),this._returnResult({data:f,error:null}))})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async _verify(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a)return this._returnResult({data:null,error:a});const l=Object.assign({challenge_id:t.challengeId},"webauthn"in t?{webauthn:Object.assign(Object.assign({},t.webauthn),{credential_response:t.webauthn.type==="create"?JO(t.webauthn.credential_response):XO(t.webauthn.credential_response)})}:{code:t.code}),{data:u,error:f}=await Ne(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:l,headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token});return f?this._returnResult({data:null,error:f}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+u.expires_in},u)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",u),this._returnResult({data:u,error:f}))})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}})}async _challenge(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a)return this._returnResult({data:null,error:a});const l=await Ne(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{body:t,headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token});if(l.error)return l;const{data:u}=l;if(u.type!=="webauthn")return{data:u,error:null};switch(u.webauthn.type){case"create":return{data:Object.assign(Object.assign({},u),{webauthn:Object.assign(Object.assign({},u.webauthn),{credential_options:Object.assign(Object.assign({},u.webauthn.credential_options),{publicKey:QO(u.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},u),{webauthn:Object.assign(Object.assign({},u.webauthn),{credential_options:Object.assign(Object.assign({},u.webauthn.credential_options),{publicKey:YO(u.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}})}async _challengeAndVerify(t){const{data:r,error:n}=await this._challenge({factorId:t.factorId});return n?this._returnResult({data:null,error:n}):await this._verify({factorId:t.factorId,challengeId:r.id,code:t.code})}async _listFactors(){var t;const{data:{user:r},error:n}=await this.getUser();if(n)return{data:null,error:n};const i={all:[],phone:[],totp:[],webauthn:[]};for(const a of(t=r==null?void 0:r.factors)!==null&&t!==void 0?t:[])i.all.push(a),a.status==="verified"&&i[a.factor_type].push(a);return{data:i,error:null}}async _getAuthenticatorAssuranceLevel(t){var r,n,i,a;if(t)try{const{payload:w}=tu(t);let S=null;w.aal&&(S=w.aal);let _=S;const{data:{user:E},error:k}=await this.getUser(t);if(k)return this._returnResult({data:null,error:k});((n=(r=E==null?void 0:E.factors)===null||r===void 0?void 0:r.filter(P=>P.status==="verified"))!==null&&n!==void 0?n:[]).length>0&&(_="aal2");const R=w.amr||[];return{data:{currentLevel:S,nextLevel:_,currentAuthenticationMethods:R},error:null}}catch(w){if(xe(w))return this._returnResult({data:null,error:w});throw w}const{data:{session:l},error:u}
311=await this.getSession();if(u)return this._returnResult({data:null,error:u});if(!l)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:f}=tu(l.access_token);let p=null;f.aal&&(p=f.aal);let m=p;((a=(i=l.user.factors)===null||i===void 0?void 0:i.filter(w=>w.status==="verified"))!==null&&a!==void 0?a:[]).length>0&&(m="aal2");const b=f.amr||[];return{data:{currentLevel:p,nextLevel:m,currentAuthenticationMethods:b},error:null}}async _getAuthorizationDetails(t){try{return await this._useSession(async r=>{const{data:{session:n},error:i}=r;return i?this._returnResult({data:null,error:i}):n?await Ne(this.fetch,"GET",`${this.url}/oauth/authorizations/${t}`,{headers:this.headers,jwt:n.access_token,xform:a=>({data:a,error:null})}):this._returnResult({data:null,error:new kr})})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async _approveAuthorization(t,r){try{return await this._useSession(async n=>{const{data:{session:i},error:a}=n;if(a)return this._returnResult({data:null,error:a});if(!i)return this._returnResult({data:null,error:new kr});const l=await Ne(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:i.access_token,body:{action:"approve"},xform:u=>({data:u,error:null})});return l.data&&l.data.redirect_url&&Ht()&&!(r!=null&&r.skipBrowserRedirect)&&window.location.assign(l.data.redirect_url),l})}catch(n){if(xe(n))return this._returnResult({data:null,error:n});throw n}}async _denyAuthorization(t,r){try{return await this._useSession(async n=>{const{data:{session:i},error:a}=n;if(a)return this._returnResult({data:null,error:a});if(!i)return this._returnResult({data:null,error:new kr});const l=await Ne(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:i.access_token,body:{action:"deny"},xform:u=>({data:u,error:null})});return l.data&&l.data.redirect_url&&Ht()&&!(r!=null&&r.skipBrowserRedirect)&&window.location.assign(l.data.redirect_url),l})}catch(n){if(xe(n))return this._returnResult({data:null,error:n});throw n}}async _listOAuthGrants(){try{return await this._useSession(async t=>{const{data:{session:r},error:n}=t;return n?this._returnResult({data:null,error:n}):r?await Ne(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,xform:i=>({data:i,error:null})}):this._returnResult({data:null,error:new kr})})}catch(t){if(xe(t))return this._returnResult({data:null,error:t});throw t}}async _revokeOAuthGrant(t){try{return await this._useSession(async r=>{const{data:{session:n},error:i}=r;return i?this._returnResult({data:null,error:i}):n?(await Ne(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,query:{client_id:t.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new kr})})}catch(r){if(xe(r))return this._returnResult({data:null,error:r});throw r}}async fetchJwk(t,r={keys:[]}){let n=r.keys.find(u=>u.kid===t);if(n)return n;const i=Date.now();if(n=this.jwks.keys.find(u=>u.kid===t),n&&this.jwks_cached_at+aO>i)return n;const{data:a,error:l}=await Ne(this.fetch,"GET",`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(l)throw l;return!a.keys||a.keys.length===0||(this.jwks=a,this.jwks_cached_at=i,n=a.keys.find(u=>u.kid===t),!n)?null:n}async getClaims(t,r={}){try{let n=t;if(!n){const{data:w,error:S}
311=await this.getSession();if(S||!w.session)return this._returnResult({data:null,error:S});n=w.session.access_token}const{header:i,payload:a,signature:l,raw:{header:u,payload:f}}=tu(n);r!=null&&r.allowExpired||PO(a.exp);const p=!i.alg||i.alg.startsWith("HS")||!i.kid||!("crypto"in globalThis&&"subtle"in globalThis.crypto)?null:await this.fetchJwk(i.kid,r!=null&&r.keys?{keys:r.keys}:r==null?void 0:r.jwks);if(!p){const{error:w}=await this.getUser(n);if(w)throw w;return{data:{claims:a,header:i,signature:l},error:null}}const m=jO(i.alg),g=await crypto.subtle.importKey("jwk",p,m,!0,["verify"]);if(!await crypto.subtle.verify(m,g,l,gO(`${u}.${f}`)))throw new Ep("Invalid JWT signature");return{data:{claims:a,header:i,signature:l},error:null}}catch(n){if(xe(n))return this._returnResult({data:null,error:n});throw n}}}al.nextInstanceID={};const aA=al,lA="2.99.3";let Ha="";typeof Deno<"u"?Ha="deno":typeof document<"u"?Ha="web":typeof navigator<"u"&&navigator.product==="ReactNative"?Ha="react-native":Ha="node";const cA={"X-Client-Info":`supabase-js-${Ha}/${lA}`},uA={headers:cA},dA={schema:"public"},fA={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},hA={};function ll(e){"@babel/helpers - typeof";return ll=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ll(e)}function pA(e,t){if(ll(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ll(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function mA(e){var t=pA(e,"string");return ll(t)=="symbol"?t:t+""}function gA(e,t,r){return(t=mA(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function R0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function kt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?R0(Object(r),!0).forEach(function(n){gA(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):R0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}const vA=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),yA=()=>Headers,wA=(e,t,r)=>{const n=vA(r),i=yA();return async(a,l)=>{var u;const f=(u=await t())!==null&&u!==void 0?u:e;let p=new i(l==null?void 0:l.headers);return p.has("apikey")||p.set("apikey",e),p.has("Authorization")||p.set("Authorization",`Bearer ${f}`),n(a,kt(kt({},l),{},{headers:p}))}};function bA(e){return e.endsWith("/")?e:e+"/"}function xA(e,t){var r,n;const{db:i,auth:a,realtime:l,global:u}=e,{db:f,auth:p,realtime:m,global:g}=t,b={db:kt(kt({},f),i),auth:kt(kt({},p),a),realtime:kt(kt({},m),l),storage:{},global:kt(kt(kt({},g),u),{},{headers:kt(kt({},(r=g==null?void 0:g.headers)!==null&&r!==void 0?r:{}),(n=u==null?void 0:u.headers)!==null&&n!==void 0?n:{})}),accessToken:async()=>""};return e.accessToken?b.accessToken=e.accessToken:delete b.accessToken,b}function _A(e){const t=e==null?void 0:e.trim();if(!t)throw new Error("supabaseUrl is required.");if(!t.match(/^https?:\/\//i))throw new Error("Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.");try{return new URL(bA(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var SA=class extends aA{constructor(e){super(e)}},EA=class{constructor(e,t,r){var n,i;this.supabaseUrl=e,this.supabaseKey=t;const a=_A(e);if(!t)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",a),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",a),this.storageUrl=new URL("storage/v1",a),this.functionsUrl=new URL("functions/v1",a);const l=`sb-${a.hostname.split(".")[0]}-auth-token`,u={db:dA,realtime:hA,auth:kt(kt({},fA),{},{storageKey:l}),global:uA},f=xA(r??{},u);
311if(this.storageKey=(n=f.auth.storageKey)!==null&&n!==void 0?n:"",this.headers=(i=f.global.headers)!==null&&i!==void 0?i:{},f.accessToken)this.accessToken=f.accessToken,this.auth=new Proxy({},{get:(m,g)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(g)} is not possible`)}});else{var p;this.auth=this._initSupabaseAuthClient((p=f.auth)!==null&&p!==void 0?p:{},this.headers,f.global.fetch)}this.fetch=wA(t,this._getAccessToken.bind(this),f.global.fetch),this.realtime=this._initRealtimeClient(kt({headers:this.headers,accessToken:this._getAccessToken.bind(this)},f.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(m=>this.realtime.setAuth(m)).catch(m=>console.warn("Failed to set initial Realtime auth token:",m)),this.rest=new cj(new URL("rest/v1",a).href,{headers:this.headers,schema:f.db.schema,fetch:this.fetch,timeout:f.db.timeout,urlLengthLimit:f.db.urlLengthLimit}),this.storage=new rO(this.storageUrl.href,this.headers,this.fetch,r==null?void 0:r.storage),f.accessToken||this._listenForAuthEvents()}get functions(){return new tj(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},r={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,r)}channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this,t,r;if(e.accessToken)return await e.accessToken();const{data:n}=await e.auth.getSession();return(t=(r=n.session)===null||r===void 0?void 0:r.access_token)!==null&&t!==void 0?t:e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:r,storage:n,userStorage:i,storageKey:a,flowType:l,lock:u,debug:f,throwOnError:p},m,g){const b={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new SA({url:this.authUrl.href,headers:kt(kt({},b),m),storageKey:a,autoRefreshToken:e,persistSession:t,detectSessionInUrl:r,storage:n,userStorage:i,flowType:l,lock:u,debug:f,throwOnError:p,fetch:g,hasCustomAuthorizationHeader:Object.keys(this.headers).some(w=>w.toLowerCase()==="authorization")})}_initRealtimeClient(e){return new Tj(this.realtimeUrl.href,kt(kt({},e),{},{params:kt(kt({},{apikey:this.supabaseKey}),e==null?void 0:e.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,"CLIENT",t==null?void 0:t.access_token)})}_handleTokenChanged(e,t,r){(e==="TOKEN_REFRESHED"||e==="SIGNED_IN")&&this.changedAccessToken!==r?(this.changedAccessToken=r,this.realtime.setAuth(r)):e==="SIGNED_OUT"&&(this.realtime.setAuth(),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const kA=(e,t,r)=>new EA(e,t,r);function TA(){if(typeof window<"u")return!1;const e=globalThis.process;if(!e)return!1;const t=e.version;if(t==null)return!1;const r=t.match(/^v(\d+)\./);return r?parseInt(r[1],10)<=18:!1}TA()&&console.warn("⚠️  Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");const CA="https://cfcvcgojltawrodgtjnc.supabase.co",RA="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImNmY3ZjZ29qbHRhd3JvZGd0am5jIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NTg0OTU1MjksImV4cCI6MjA3NDA3MTUyOX0.YG-pSEey0pIB3RlbFcLvuAzPLrZZGfT_RIjIyoy-Jhg",me=kA(CA,RA),OU=Object.freeze(Object.defineProperty({__proto__:null,supabase:me},Symbol.toStringTag,{value:"Module"})),Vx=v.createContext(void 0),ar=()=>{const e=v.useContext(Vx);if(e===void 0)throw new Error("useAuth must be used within an AuthProvider");return e},PA=({children:e})=>{const[t,r]=v.useState(null),[n,i]=v.useState(!0),[a,l]=v.useState("tech-lead"),[u,f]=v.useState(!1),[,p]=v.useState(!0),[,m]=v.useState(!1),[,g]=v.useState(!1),[b,w]=v.useState(!1),S=v.useRef(!1),_=v.useRef(null),E=jo(),{toast:k}=zu();v.useEffect(()=>{(()=>{try{const oe="https://cfcvcgojltawrodgtjnc.supabase.co",J=new URL(oe).hostname.split(".")[0],pe
311=Object.keys(localStorage).filter(ne=>ne.startsWith("sb-")&&!ne.includes(J));pe.length>0&&(console.log("🧹 Cleaning up sessions from other environments:",pe),pe.forEach(ne=>localStorage.removeItem(ne)),me.auth.signOut(),k({title:"Environment Updated",description:"Please sign in again."}))}catch(oe){console.error("Failed to cleanup cross-environment sessions:",oe)}})()},[]);const T=F=>{localStorage.setItem("intended_user_type",F)},R=()=>{console.log("🔍 Getting intended user type...");const F=localStorage.getItem("intended_user_type");if(console.log("📦 LocalStorage intended_user_type:",F),F&&["xtern","enterprise","tech_lead","enterprise","client"].includes(F))return localStorage.removeItem("intended_user_type"),console.log("✅ Found valid user type in localStorage:",F),F;const J=new URLSearchParams(window.location.search).get("user_type");if(console.log("🔗 URL query user_type:",J),J&&["xtern","enterprise","tech_lead","enterprise","client"].includes(J))return console.log("✅ Found valid user type in URL query:",J),J;const Z=window.location.hash;if(console.log("🔗 Full URL hash:",Z),Z){const ne=new URLSearchParams(Z.substring(1)).get("user_type");if(console.log("🔗 Hash user_type:",ne),ne&&["xtern","enterprise","tech_lead","enterprise","client"].includes(ne))return console.log("✅ Found valid user type in URL hash:",ne),ne}return console.log("❌ No valid user type found anywhere"),null},P=async F=>{try{const{data:oe,error:J}=await me.from("profiles").select("user_type, full_name, avatar_url, provider, preferred_dashboard_role").eq("id",F).single();if(J)return console.error("Error fetching user profile:",J),null;const{data:Z,error:pe}=await me.from("user_roles").select("role").eq("user_id",F).eq("is_active",!0).order("assigned_at",{ascending:!0});return pe?(console.error("Error fetching user roles:",pe),null):{profile:oe,roles:(Z==null?void 0:Z.map(ne=>ne.role))||[]}}catch(oe){return console.error("Error in fetchUserProfileAndRoles:",oe),null}},O=(F,oe,J,Z)=>{var ot,Tt,vt,Be;const pe=J.length>0?J:[oe.user_type],ne=Z||pe[0];return{id:F.user.id,email:F.user.email||"",name:oe.full_name||((ot=F.user.email)==null?void 0:ot.split("@")[0])||"User",type:oe.user_type,roles:pe,activeRole:ne,profilePicture:oe.avatar_url||((Tt=F.user.user_metadata)==null?void 0:Tt.avatar_url)||((vt=F.user.user_metadata)==null?void 0:vt.picture)||"",provider:oe.provider||((Be=F.user.app_metadata)==null?void 0:Be.provider)}},I=(F,oe)=>{var J,Z,pe,ne;return console.log("👤 Creating fallback user with type:",oe),{id:F.user.id,email:F.user.email||"",name:((J=F.user.email)==null?void 0:J.split("@")[0])||"User",type:oe,roles:[oe],activeRole:oe,profilePicture:((Z=F.user.user_metadata)==null?void 0:Z.avatar_url)||((pe=F.user.user_metadata)==null?void 0:pe.picture)||"",provider:(ne=F.user.app_metadata)==null?void 0:ne.provider}},M=async F=>{var oe,J,Z,pe,ne,ot,Tt,vt;try{console.log("🔧 Starting profile operations for user:",F.user.id);const Be=await P(F.user.id);if(Be&&Be.profile){if(console.log("📋 Found existing profile:",Be.profile),console.log("📋 Found roles:",Be.roles),!Be.profile.user_type)throw console.error("⚠️ Profile exists but has invalid user_type:",Be.profile.user_type),new Error("Profile has invalid user type");const _t=R();if(console.log("🎯 Intended user type for existing profile:",_t),_t&&!Be.roles.includes(_t)){if(console.log(`➕ Attempting to add new role '${_t}' to existing profile`),Be.roles.length===1&&Be.roles[0]==="xtern"&&_t!=="xtern")throw console.log("🚫 Xtern-only account attempting to access non-xtern role"),new Error("XTERN_ONLY_ACCOUNT: This account is only available for Xtern access. Please login as an Xtern instead.");if((_t==="corporate"||_t==="enterprise")&&!re(F.user.email||"",_t))throw new Error("Corporate accounts must use a business email address. Personal email domains are not allowed.");await me.from("user_roles").insert({user_id:F.user.id,role:_t}),Be.roles.push(_t),console.log("✅ New role added successfully")}const br=localStorage.getItem("preferred_active_role"),No=Be.roles.includes(br)?br:void 0;return O(F,Be.profile,Be.roles,No)}const rt=R();if(console.log("🎯 Intended user type for new profile:",rt),!rt)throw console.error("❌ No intended user type found - cannot create profile automatically"),new Error("Cannot determine user type for new profile creation");if((rt==="corporate"||rt==="enterprise")&&!re(F.user.email||"",rt))throw new Error("Corporate accounts must use a business email address. Personal email domains are not allowed.");if((oe=F.user.app_metadata)!=null&&oe.provider){console.log("🔗 Creating profile for social auth user");const Dt={full_name:((J=F.user.user_metadata)==null?void 0:J.full_name)||((Z=F.user.user_metadata)==null?void 0:Z.name),avatar_url:((pe=F.user.user_metadata)==null?void 0:pe.avatar_url)||((ne
311=F.user.user_metadata)==null?void 0:ne.picture),provider:F.user.app_metadata.provider,provider_id:((ot=F.user.user_metadata)==null?void 0:ot.provider_id)||F.user.id};await Y(F.user.id,F.user.email,Dt,rt)}else console.log("📧 Creating profile for email/password user"),await me.from("profiles").insert({id:F.user.id,user_type:rt,full_name:((Tt=F.user.user_metadata)==null?void 0:Tt.full_name)||((vt=F.user.email)==null?void 0:vt.split("@")[0])||""});return await me.from("user_roles").insert({user_id:F.user.id,role:rt}),console.log("✅ Profile and role created successfully with type:",rt),I(F,rt)}catch(Be){throw console.error("💥 Profile operations failed:",Be),Be}},Y=async(F,oe,J,Z)=>{try{const pe={id:F,user_type:Z,full_name:J.full_name||J.name||oe.split("@")[0],avatar_url:J.avatar_url||J.picture,provider:J.provider,provider_id:J.provider_id},{error:ne}=await me.from("profiles").upsert(pe);return ne&&console.error("Error upserting profile:",ne),pe}catch(pe){return console.error("Error in createOrUpdateProfile:",pe),null}},ae=F=>{switch(F){case"xtern":return"/xterns/dashboard";case"tech_lead":return"/tech-lead/dashboard";case"corporate":case"enterprise":return"/enterprise/dashboard";case"super_admin":return"/super-admin/dashboard";case"client":return"/client/dashboard";default:return"/dashboard"}},he=async F=>{E(ae(F))},Ee=()=>{const F=window.location.hash,oe=F.includes("access_token="),J=F.includes("user_t
311ype=")||new URLSearchParams(window.location.search).has("user_type");return oe||J},ue=F=>{if(window.location.pathname==="/reset-password"||window.location.pathname==="/enterprise/verify")return!1;if(["/xterns/","/tech-lead/","/enterprise/","/super-admin/","/client/"].some(ne=>window.location.pathname.startsWith(ne)))return console.log("🔄 Already on authenticated route - not navigating"),!1;const J=Ee(),Z=["/","/login","/unified-login","/signup","/signup/tech-lead"].includes(window.location.pathname);return F==="SIGNED_IN"&&!S.current||J||Z},je=async F=>{if(t&&t.roles.includes(F)){const oe={...t,activeRole:F};r(oe),localStorage.setItem("preferred_active_role",F);try{await me.from("profiles").update({preferred_dashboard_role:F}).eq("id",t.id)}catch(J){console.error("Error updating dashboard preference:",J)}he(F)}},le=async(F,oe)=>{if(oe&&(localStorage.setItem("preferred_active_role",F),t!=null&&t.id))try{await me.from("profiles").update({preferred_dashboard_role:F}).eq("id",t.id)}catch(J){console.error("Error saving dashboard preference:",J)}if(t){const J={...t,activeRole:F};r(J)}sessionStorage.setItem("dashboard_modal_shown","true"),f(!1),he(F)},Ae=async F=>{const oe=F||(t==null?void 0:t.id);if(!oe)return console.log("🔒 No user ID provided for lockdown check"),!1;try{console.log("🔒 Checking assessment lockdown for user:",oe);let J=!1;if((t==null?void 0:t.activeRole)==="tech_lead"){const{data:Z,error:pe}=await me.rpc("is_tech_lead_in_tech_assessment_lockdown",{p_user_id:oe});if(pe)return console.error("🔒 Error checking tech lead assessment lockdown:",pe),!1;J=!!Z,console.log("🔒 Tech lead lockdown status:",J)}else{const{data:Z,error:pe}=await me.rpc("is_user_in_assessment_lockdown",{p_user_id:oe});if(pe)return console.error("🔒 Error checking xtern assessment lockdown:",pe),!1;J=!!Z,console.log("🔒 Xtern lockdown status:",J)}return w(J),J}catch(J){return console.error("🔒 Error in checkAssessmentLockdown:",J),!1}},Te=async F=>{if(!t)throw new Error("No authenticated user");try{const{error:oe}=await me.from("user_roles").insert({user_id:t.id,role:F});if(oe)throw oe;const J=[...t.roles,F],Z={...t,roles:J,activeRole:F};r(Z),localStorage.setItem("preferred_active_role",F);try{await me.from("profiles").update({preferred_dashboard_role:F}).eq("id",t.id)}catch(pe){console.error("Error updating dashboard preference:",pe)}console.log(`✅ Successfully added role '${F}' to user`)}catch(oe){throw console.error("Failed to add user role:",oe),oe}};v.useEffect(()=>{localStorage.getItem("auth_cleanup_v2_done")||(console.log("🧹 Running one-time comprehensive auth cleanup"),Object.keys(localStorage).forEach(J=>{J.startsWith("sb-")&&localStorage.removeItem(J)}),["preferred_active_role","intended_user_type","xterns-admin"].forEach(J=>{localStorage.removeItem(J)}),["auth_session_processed","dashboard_modal_shown","auth_event_id"].forEach(J=>{sessionStorage.removeItem(J)}),localStorage.setItem("auth_cleanup_v2_done","true"),console.log("✅ Comprehensive auth cleanup completed"))},[]),v.useEffect(()=>{let F=!0;const{data:{subscription:oe}}=me.auth.onAuthStateChange(async(J,Z)=>{var pe;if(console.log("Auth state change:",J,(pe=Z==null?void 0:Z.user)==null?void 0:pe.id),!!F){if(Z!=null&&Z.access_token)try{const ne=JSON.parse(atob(Z.access_token.split(".")[1])),Tt="https://cfcvcgojltawrodgtjnc.supabase.co/auth/v1";if(ne.iss!==Tt){console.error("❌ Token from wrong environment:",ne.iss),console.log("✅ Expected issuer:",Tt),Object.keys(localStorage).forEach(rt=>{rt.startsWith("sb-")&&localStorage.removeItem(rt)}),localStorage.removeItem("preferred_active_role"),localStorage.removeItem("intended_user_type"),await me.auth.signOut(),k({title:"Session Invalid",description:"Please sign in again.",variant:"destructive"});return}if(!ne.sub){console.error("❌ Token missing sub claim"),await me.auth.signOut(),Object.keys(localStorage).forEach(rt=>{rt.startsWith("sb-")&&localStorage.removeItem(rt)}),k({title:"Session Corrupted",description:"Please sign in again.",variant:"destructive"});return}const vt=Math.floor(Date.now()/1e3);if(ne.exp&&ne.exp<vt){console.error("❌ Token expired:",new Date(ne.exp*1e3)),await me.auth.signOut();return}console.log("✅ Token validated successfully:",{issuer:ne.iss,sub:ne.sub,exp:new Date(ne.exp*1e3)})}catch(ne){console.error("Failed to validate token:",ne),await me.auth.signOut(),Object.keys(localStorage).forEach(Tt=>{Tt.startsWith("sb-")&&localStorage.removeItem(Tt)});return}if(J==="SIGNED_OUT"||J==="TOKEN_REFRESHED"&&!Z){r(null),i(!1),f(!1),m(!1),g(!1),S.current=!1,w(!1),sessionStorage.removeItem("auth_session_processed"),sessionStorage.removeItem("dashboard_modal_shown");return}Z!=null&&Z.user?(i(!1),console.log("🚀 Processing authenticated user:",Z.user.id),setTimeout(()=>{M(Z).then(async ne=>{if(F){const ot=Z.user.email;if(ot){const vt=sessionStorage.getItem(`otp:pw:${ot}`);vt&&(console.log("🔗 Magic link used - setting password from stored value"),await me.auth.updateUser({password:vt}),sessionStorage.removeItem(`otp:pw:${ot}`),console.log("✅ Password set successfully via magic link"))}if(console.log("✅ Setting user with profile:",ne),r(ne),ne.activeRole==="xtern"||ne.activeRole==="tech_lead"){console.log("🔒 Checking lockdown for user:",ne.id,"role:",ne.activeRole);const vt=await Ae(ne.id);if(console.log("🔒 Lockdown check result:",vt),vt){const Be=ne.activeRole==="tech_lead"?"/tech-lead/assessment-lockdown":"/assessment-lockdown";if(window.location.pathname!==Be){console.log("🔒 User is in asse
311ssment lockdown - redirecting to:",Be),E(Be);return}}}const Tt=J==="SIGNED_IN"&&ue(J);if(S.current||(S.current=!0,g(!0),m(!0)),Tt)if(console.log("🎯 SIGNED_IN event - user roles:",ne.roles),sessionStorage.setItem("auth_session_processed","true"),window.location.hash.includes("access_token=")&&(console.log("🧹 Cleaning up OAuth hash from URL"),window.history.replaceState(null,"",window.location.pathname)),ne.roles.length>1)try{const{data:Be}=await me.from("profiles").select("preferred_dashboard_role").eq("id",ne.id).single(),rt=Be==null?void 0:Be.preferred_dashboard_role,Dt=localStorage.getItem("preferred_active_role"),_t=rt||Dt;rt&&rt!==Dt&&localStorage.setItem("preferred_active_role",rt),_t&&ne.roles.includes(_t)?(ne={...ne,activeRole:_t},r(ne),setTimeout(()=>{he(_t)},100)):(console.log("🎯 Showing dashboard selection modal"),sessionStorage.setItem("dashboard_modal_shown","true"),f(!0))}catch(Be){console.error("Error checking preferences:",Be),f(!0)}else ne.roles.length===1&&setTimeout(()=>{he(ne.activeRole)},100);else console.log("🔄 Session restored - staying on current page")}}).catch(async ne=>{var ot;if(console.error("💥 Failed to handle profile operations:",ne),(ot=ne.message)!=null&&ot.includes("XTERN_ONLY_ACCOUNT:")){console.log("🚫 Signing out user due to role validation error"),localStorage.removeItem("intended_user_type"),k({variant:"destructive",title:"Account Access Restricted",description:"This account is only available for Xtern access. Please login as an Xtern instead."}),await me.auth.signOut(),r(null),i(!1);return}i(!1)})},0)):(r(null),i(!1))}});return me.auth.getSession().then(({data:{session:J}})=>{F&&(p(!1),J!=null&&J.user?(console.log("🔄 Found existing session on mount for user:",J.user.id),i(!1),m(!0),M(J).then(async Z=>{if(F){try{const{data:pe}=await me.from("profiles").select("preferred_dashboard_role").eq("id",Z.id).single(),ne=pe==null?void 0:pe.preferred_dashboard_role,ot=localStorage.getItem("preferred_active_role");ne&&ne!==ot&&(localStorage.setItem("preferred_active_role",ne),Z.roles.includes(ne)&&(Z={...Z,activeRole:ne}))}catch(pe){console.error("Error loading dashboard preference:",pe)}if(r(Z),Z.activeRole==="xtern"||Z.activeRole==="tech_lead"){console.log("🔒 Checking lockdown for existing user:",Z.id,"role:",Z.activeRole);const pe=await Ae(Z.id);if(console.log("🔒 Existing session lockdown check result:",pe),pe){const ne=Z.activeRole==="tech_lead"?"/tech-lead/assessment-lockdown":"/assessment-lockdown";window.location.pathname!==ne&&(console.log("🔒 Existing user is in assessment lockdown - redirecting to:",ne),E(ne))}}}}).catch(async Z=>{var pe;if(console.error("💥 Failed to handle existing session profile operations:",Z),(pe=Z.message)!=null&&pe.includes("XTERN_ONLY_ACCOUNT:")){console.log("🚫 Signing out user due to role validation error in existing session"),localStorage.removeItem("intended_user_type"),k({variant:"destructive",title:"Account Access Restricted",description:"This account is only available for Xtern access. Please login as an Xtern instead."}),await me.auth.signOut(),r(null),i(!1);return}i(!1)})):i(!1))}),()=>{F=!1,oe.unsubscribe()}},[]),v.useEffect(()=>{if(!t)return;const oe=setInterval(async()=>{try{const{data:{session:J}}=await me.auth.getSession();if(!J){console.log("🔍 Session lost - logging out"),r(null);return}J.user.id!==t.id&&(console.error("❌ Session user mismatch!",{sessionUser:J.user.id,contextUser:t.id}),k({title:"Session Changed",description:"Your session has been updated."}),window.location.reload())}catch(J){console.error("Session validation failed:",J)}},3e5);return()=>clearInterval(oe)},[t]);const re=(F,oe)=>{var J;if(oe==="corporate"||oe==="enterprise"){const Z=["gmail.com","yahoo.com","hotmail.com","outlook.com","aol.com","icloud.com","protonmail.com","zoho.com","yandex.com","mail.com","gmx.com","live.com","msn.com","me.com","yahoo.co.uk","googlemail.com"],pe=(J=F.split("@")[1])==null?void 0:J.toLowerCase();return!Z.includes(pe)}return!0},z=async F=>{let oe=F;const J=await me.from("profiles").select("preferred_dashboard_role").eq("id",F.id).single().then(({data:ne})=>ne==null?void 0:ne.preferred_dashboard_role).catch(ne=>(console.error("Error loading dashboard preference:",ne),null)),Z=localStorage.getItem("preferred_active_role"),pe=J||Z;return pe&&F.roles.includes(pe)?(J&&J!==Z&&localStorage.setItem("preferred_active_role",J),oe={...F,activeRole:pe},r(oe),{user:oe,roles:oe.roles,activeRole:oe.activeRole,requiresDashboardSelection:!1,dashboardPath:ae(oe.activeRole)}):F.roles.length>1?(f(!0),{user:F,roles:F.roles,activeRole:F.activeRole,requiresDashboardSelection:!0,dashboardPath:null}):{user:F,roles:F.roles,activeRole:F.activeRole,requiresDashboardSelection:!1,dashboardPath:ae(F.activeRole)}},W=async(F,oe,J)=>{try{if(J&&!re(F,J))throw new Error("Corporate accounts must use a business email address. Personal email domains are not allowed.");J&&localStorage.setItem("intended_user_type",J);const{error:Z}=await me.auth.signInWithPassword({email:F,password:oe});if(Z){if(Z.message==="Email not confirmed"){console.log("📧 Email not confirmed, sending fresh OTP for verification"),sessionStorage.setItem(`otp:pw:${F}`,oe);const{error:ot}=await me.auth.signInWithOtp({email:F,options:{shouldCreateUser:!1,emailRedirectTo:`${window.location.origin}/`,data:J?{user_type:J}:void 0}});throw ot?(sessionStorage.removeItem(`otp:pw:${F}`),ot):new Error("EMAIL_NOT_CONFIRMED_OTP_SENT")}throw Z}const{data:{session:pe}}=await me.auth.getSession();if(!(pe!=null&&pe.user))throw new Error("Unable to establish a session. Please try again.");const ne=await M(pe);return r(ne),ne.roles.includes("super_admin")&&localStorage.setItem("preferred_active_role","super_admin"),await z(ne)}catch(Z){throw console.error("Login error:",Z),Z}},K=async(F,oe,J,Z)=>{try{if(!re(F,J))throw new Error("Corporate accounts must use a business email address. Personal email domains are not allowed.");localStorage.setItem("intended_user_type",J),sessionStorage.setItem(`otp:pw:${F}`,oe);const{error:pe}=await me.auth.signInWithOtp({email:F,options:{shouldCreateUser:!0,emailRedirectTo:(Z==null?void 0:Z.redirectTo)||`${window.location.origin}/`,data:{user_type:J,full_name:Z==null?void 0:Z.fullName}}});if(pe)throw sessionStorage.removeItem(`otp:pw:${F}`),pe;
311console.log("📧 OTP signup initiated - verification code sent")}catch(pe){throw console.error("Signup error:",pe),pe}},N=async(F,oe,J)=>{try{localStorage.setItem("intended_user_type",J);const{error:Z}=await me.auth.verifyOtp({email:F,token:oe,type:"email"});if(Z)throw Z;const pe=sessionStorage.getItem(`otp:pw:${F}`);pe&&(await me.auth.updateUser({password:pe}),sessionStorage.removeItem(`otp:pw:${F}`),console.log("✅ Password set successfully after OTP verification"))}catch(Z){throw console.error("OTP verification error:",Z),Z}},U=async(F,oe,J)=>{try{localStorage.setItem("intended_user_type",oe);const{error:Z}=await me.auth.signInWithOtp({email:F,options:{shouldCreateUser:!0,emailRedirectTo:(J==null?void 0:J.redirectTo)||`${window.location.origin}/`,data:{user_type:oe,full_name:J==null?void 0:J.fullName}}});if(Z)throw Z;console.log("📧 OTP resent successfully")}catch(Z){throw console.error("Resend OTP error:",Z),Z}},X=async F=>{T(F);const{error:oe}=await me.auth.signInWithOAuth({provider:"google",options:{redirectTo:`${window.location.origin}/?user_type=${F}`}});if(oe)throw console.error("Google login error:",oe),oe},fe=async F=>{T(F);const{error:oe}=await me.auth.signInWithOAuth({provider:"github",options:{redirectTo:`${window.location.origin}/?user_type=${F}`}});if(oe)throw console.error("GitHub login error:",oe),oe},Oe=async F=>{T(F);const{error:oe}=await me.auth.signInWithOAuth({provider:"linkedin_oidc",options:{redirectTo:`${window.location.origin}/?user_type=${F}`}});if(oe)throw console.error("LinkedIn login error:",oe),oe},Fe=async F=>{},Re=async()=>{if(!(t!=null&&t.id))return;const{data:F,error:oe}=await me.from("employer_opportunity_candidates").select("id, metadata").eq("talent_user_id",t.id).neq("stage","completed");if(oe){console.error("Failed to load active opportunity timers before logout:",oe);return}const J=(F??[]).map(Z=>{const pe=Z.metadata&&typeof Z.metadata=="object"?Z.metadata:{},ne=pe.simulation_workspace&&typeof pe.simulation_workspace=="object"?pe.simulation_workspace:null;if(!ne||ne.last_worked_at==null)return null;const ot={...pe,simulation_workspace:{...ne,last_worked_at:null,saved_at:new Date().toISOString()}};return me.from("employer_opportunity_candidates").update({metadata:ot,updated_by:t.id}).eq("id",Z.id).eq("talent_user_id",t.id)}).filter(Boolean);J.length>0&&await Promise.allSettled(J)};v.useEffect(()=>{!(t!=null&&t.id)||_.current===t.id||(_.current=t.id,Fe(t.id).catch(F=>{console.error("Failed to resume active opportunity timers:",F)}))},[t==null?void 0:t.id]);const Ve=async()=>{try{const F=[];window.dispatchEvent(new CustomEvent("xtern:before-logout",{detail:{promises:F}})),F.length>0&&await Promise.allSettled(F),await Re(),await me.auth.signOut(),r(null),f(!1),w(!1),S.current=!1,_.current=null,["preferred_active_role","intended_user_type","xterns-admin"].forEach(ne=>localStorage.removeItem(ne)),["auth_session_processed","dashboard_modal_shown","auth_event_id"].forEach(ne=>sessionStorage.removeItem(ne)),Object.keys(sessionStorage).forEach(ne=>{ne.startsWith("otp:pw:")&&sessionStorage.removeItem(ne)}),Object.keys(localStorage).forEach(ne=>{ne.startsWith("sb-")&&localStorage.removeItem(ne),ne.startsWith("xtern:opportunity-timers-resumed:")&&localStorage.removeItem(ne)}),window.location.href="/"}catch(F){console.error("Logout error:",F),window.location.href="/"}},Qe=async()=>{try{localStorage.removeItem("preferred_active_role"),t!=null&&t.id&&await me.from("profiles").update({preferred_dashboard_role:null}).eq("id",t.id)}catch(F){console.error("Error clearing dashboard preference:",F)}};return d.jsx(Vx.Provider,{value:{user:t,login:W,signup:K,verifySignupOtp:N,resendSignupOtp:U,loginWithGoogle:X,loginWithGitHub:fe,loginWithLinkedIn:Oe,logout:Ve,isLoading:n,currentMode:a,setCurrentMode:l,switchRole:je,showDashboardModal:u,setShowDashboardModal:f,handleDashboardSelection:le,clearDashboardPreference:Qe,addUserRole:Te,isInAssessmentLockdown:b,checkAssessmentLockdown:Ae},children:e})},Wx=v.createContext(null),jA=({children:e})=>{const[t,r]=v.useState([]),[n,i]=v.useState(0),[a,l]=v.useState(!0),{user:u}=ar(),{toast:f}=zu(),p=v.useRef(null),m=v.useRef(`notifications-provider-${Date.now()}`),g=v.useRef([]),b=v.useRef(null),w=v.useCallback(()=>{try{const O=new Audio("/notification-sound.mp3");O.volume=.3,O.play().catch(I=>{console.log("Could not play notification sound:",I)})}catch(O){console.log("Notification sound not available:",O)}},[]),S=v.useCallback(()=>{const O=g.current;if(g.current=[],b.current=null,O.length!==0)if(w(),O.length===1){const I=O[0];
311f({title:I.title,description:I.message,duration:I.type==="meeting"?6e3:void 0})}else{const I=O[O.length-1];f({title:`${O.length} new notifications`,description:I.title})}},[f,w]),_=v.useCallback(O=>{g.current.push(O),b.current&&clearTimeout(b.current),b.current=setTimeout(S,500)},[S]),E=v.useCallback(async()=>{if(!u){l(!1);return}try{const{data:O,error:I}=await me.from("notifications").select("id, user_id, title, message, type, priority, read_at, action_required, action_url, metadata, created_at, expires_at, updated_at").eq("user_id",u.id).order("created_at",{ascending:!1}).limit(50);if(I)throw I;r(O||[]),i((O==null?void 0:O.filter(M=>!M.read_at).length)||0)}catch(O){console.error("Error fetching notifications:",O)}finally{l(!1)}},[u]),k=v.useCallback(async O=>{if(u)try{const{error:I}=await me.from("notifications").update({read_at:new Date().toISOString()}).eq("id",O).eq("user_id",u.id);if(I)throw I;r(M=>M.map(Y=>Y.id===O?{...Y,read_at:new Date().toISOString()}:Y)),i(M=>Math.max(0,M-1))}catch(I){console.error("Error marking notification as read:",I)}},[u]),T=v.useCallback(async()=>{if(u)try{const O=t.filter(M=>!M.read_at).map(M=>M.id);if(O.length===0)return;const{error:I}=await me.from("notifications").update({read_at:new Date().toISOString()}).in("id",O).eq("user_id",u.id);if(I)throw I;r(M=>M.map(Y=>Y.read_at?Y:{...Y,read_at:new Date().toISOString()})),i(0),f({title:"All notifications marked as read",description:`${O.length} notifications marked as read.`})}catch(O){console.error("Error marking all notifications as read:",O),f({title:"Error",description:"Failed to mark notifications as read.",variant:"destructive"})}},[u,t,f]),R=v.useCallback(()=>t.filter(O=>!O.read_at).slice(0,5),[t]);v.useEffect(()=>{if(!(u!=null&&u.id)){l(!1);return}if(p.current){console.log("Subscription already exists, skipping...");return}return console.log(`Setting up centralized notifications subscription for user ${u.id}`),(async()=>{try{await E();const I=me.channel(m.current).on("postgres_changes",{event:"INSERT",schema:"public",table:"notifications",filter:`user_id=eq.${u.id}`},M=>{const Y=M.new;r(ae=>[Y,...ae]),i(ae=>ae+1),_(Y)}).on("postgres_changes",{event:"UPDATE",schema:"public",table:"notifications",filter:`user_id=eq.${u.id}`},M=>{var Ee;console.log("Notification updated:",M);const Y=M.new;r(ue=>ue.map(je=>je.id===Y.id?Y:je));const ae=(Ee=M.old)==null?void 0:Ee.read_at,he=Y.read_at;!ae&&he?i(ue=>Math.max(0,ue-1)):ae&&!he&&i(ue=>ue+1)});I.subscribe(M=>{console.log("Centralized subscription status:",M),M==="SUBSCRIBED"?p.current=I:M==="CLOSED"&&(p.current=null)})}catch(I){console.error("Error initializing notifications:",I),l(!1)}})(),()=>{console.log("Cleaning up centralized subscription"),p.current&&(me.removeChannel(p.current),p.current=null),b.current&&(clearTimeout(b.current),b.current=null),g.current=[]}},[u==null?void 0:u.id,E,_]);const P={notifications:t,unreadCount:n,loading:a,markAsRead:k,markAllAsRead:T,getRecentNotifications:R,refetch:E};return d.jsx(Wx.Provider,{value:P,children:e})},AU=()=>{const e=v.useContext(Wx);if(!e)throw new Error("useNotificationsContext must be used within NotificationsProvider");return e};function Hx(e){return t=>typeof t===e}var OA=Hx("function"),AA=e=>e===null,P0=e=>Object.prototype.toString.call(e).slice(8,-1)==="RegExp",j0=e=>!NA(e)&&!AA(e)&&(OA(e)||typeof e=="object"),NA=Hx("undefined");function IA(e,t){const{length:r}=e;if(r!==t.length)return!1;for(let n=r;n--!==0;)if(!ir(e[n],t[n]))return!1;return!0}function LA(e,t){if(e.byteLength!==t.byteLength)return!1;const r=new DataView(e.buffer),n=new DataView(t.buffer);let i=e.byteLength;for(;i--;)if(r.getUint8(i)!==n.getUint8(i))return!1;return!0}function DA(e,t){if(e.size!==t.size)return!1;for(const r of e.entries())if(!t.has(r[0]))return!1;for(const r of e.entries())if(!ir(r[1],t.get(r[0])))return!1;return!0}function MA(e,t){if(e.size!==t.size)return!1;for(const r of e.entries())if(!t.has(r[0]))return!1;return!0}function ir(e,t){if(e===t)return!0;if(e&&j0(e)&&t&&j0(t)){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)&&Array.isArray(t))return IA(e,t);if(e instanceof Map&&t instanceof Map)return DA(e,t);if(e instanceof Set&&t instanceof Set)return MA(e,t);if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t))return LA(e,t);if(P0(e)&&P0(t))return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(let i=r.length;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,r[i]))return!1;for(let i=r.length;i--!==0;){const a=r[i];if(!(a==="_owner"&&e.$$typeof)&&!ir(e[a],t[a]))return!1}return!0}return Number.isNaN(e)&&Number.isNaN(t)?!0:e===t}var $A=["Array","ArrayBuffer","AsyncFunction","AsyncGenerator","AsyncGeneratorFunction","Date","Error","Function","Generator","GeneratorFunction","HTMLElement","Map","Object","Promise","RegExp","Set","WeakMap","WeakSet"],FA=["bigint","boolean","null","number","string","symbol","undefined"];function Yu(e){const t=Object.prototype.toString.call(e).slice(8,-1);if(/HTML\w+Element/.test(t))return"HTMLElement";if(UA(t))return t}function on(e){return t=>Yu(t)===e}function UA(e){return $A.includes(e)}function Gi(e){return t=>typeof t===e}function zA(e){return FA.includes(e)}var BA=["innerHTML","ownerDocument","style","attributes","nodeValue"];function ye(e){if(e===null)return"null";switch(typeof e){case"bigint":return"bigint";case"boolean":return"boolean";case"number":return"number";case"string":return"string";case"symbol":return"symbol";case"undefined":return"undefined"}if(ye.array(e))return"Array";if(ye.plainFunction(e))return"Function";const t=Yu(e);return t||"Object"}ye.array=Array.isArray;ye.arrayOf=(e,t)=>!ye.array(e)&&!ye.function(t)?!1:e.every(r=>t(r));ye.asyncGeneratorFunction=e=>Yu(e)==="AsyncGeneratorFunction";ye.asyncFunction=on("AsyncFunction");ye.bigint=Gi("bigint");ye.boolean=e=>e===!0||e===!1;ye.date=on("Date");ye.defined=e=>!ye.undefined(e);ye.domElement=e=>ye.object(e)&&!ye.plainObject(e)&&e.nodeType===1&&ye.string(e.nodeName)&&BA.every(t=>t in e);ye.empty=e=>ye.string(e)&&e.length===0||ye.array(e)&&e.length===0||ye.object(e)&&!ye.map(e)&&!ye.set(e)&&Object.keys(e).length===0||ye.set(e)&&e.size===0||ye.map(e)&&e.size===0;ye.error=on("Error");ye.function=Gi("function");ye.generator=e=>ye.iterable(e)&&ye.function(e.next)&&ye.function(e.throw);ye.generatorFunction=on("GeneratorFunction");ye.instanceOf=(e,t)=>!e||!t?!1:Object.getPrototypeOf(e)===t.prototype;ye.iterable=e=>!ye.nullOrUndefined(e)&&ye.function(e[Symbol.iterator]);ye.map=on("Map");ye.nan=e=>Number.isNaN(e);ye.null=e=>e===null;ye.nullOrUndefined=e=>ye.null(e)||ye.undefined(e);ye.number=e=>Gi("number")(e)&&!ye.nan(e);ye.numericString=e=>ye.string(e)&&e.length>0&&!Number.isNaN(Number(e));ye.object=e=>!ye.nullOrUndefined(e)&&(ye.function(e)||typeof e=="object");ye.oneOf=(e,t)=>ye.array(e)?e.indexOf(t)>-1:!1;ye.plainFunction=on("Function");ye.plainObject=e=>{if(Yu(e)!=="Object")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.getPrototypeOf({})};ye.primitive=e=>ye.null(e)||zA(typeof e);ye.promise=on("Promise");ye.propertyOf=(e,t,r)=>{if(!ye.object(e)||!t)return!1;const n=e[t];return ye.function(r)?r(n):ye.defined(n)};ye.regexp=on("RegExp");ye.set=on("Set");ye.string=Gi("string");ye.symbol=Gi("symbol");ye.undefined=Gi("undefined");ye.weakMap=on("WeakMap");ye.weakSet=on("WeakSet");var _e=ye;function qA(...e){return e.every(t=>_e.string(t)||_e.array(t)||_e.plainObject(t))}function VA(e,t,r){return Kx(e,t)?[e,t].every(_e.array)?!e.some(L0(r))&&t.some(L0(r)):[e,t].every(_e.plainObject)?!Object.entries(e).some(I0(r))&&Object.entries(t).some(I0(r)):t===r:!1}function O0(e,t,r){const{actual:n,key:i,previous:a,type:l}=r,u=Tn(e,i),f=Tn(t,i);let p=[u,f].every(_e.number)&&(l==="increased"?u<f:u>f);return _e.undefined(n)||(p=p&&f===n),_e.undefined(a)||(p=p&&u===a),p}function A0(e,t,r){const{key:n,type:i,value:a}=r,l=Tn(e,n),u=Tn(t,n),f=i==="added"?l:u,p=i==="added"?u:l;if(!_e.nullOrUndefined(a)){if(_e.defined(f)){if(_e.array(f)||_e.plainObject(f))return VA(f,p,a)}else return ir(p,a);return!1}return[l,u].every(_e.array)?!p.every(tm(f)):[l,u].every(_e.plainObject)?WA(Object.keys(f),Object.keys(p)):![l,u].every(m=>_e.primitive(m)&&_e.defined(m))&&(i==="added"?!_e.defined(l)&&_e.defined(u):_e.defined(l)&&!_e.defined(u))}function N0(e,t,{key:r}={}){let n=Tn(e,r),i=Tn(t,r);if(!Kx(n,i))throw new TypeError("Inputs have different types");if(!qA(n,i))throw new TypeError("Inputs don't have length");return[n,i].every(_e.plainObject)&&(n=Object.keys(n),i=Object.keys(i)),[n,i]}function I0(e){return([t,r])=>_e.array(e)?ir(e,r)||e.some(n=>ir(n,r)||_e.array(r)&&tm(r)(n)):_e.plainObject(e)&&e[t]?!!e[t]&&ir(e[t],r):ir(e,r)}function WA(e,t){return t.some(r=>!e.includes(r))}function L0(e){return t=>_e.array(e)?e.some(r=>ir(r,t)||_e.array(t)&&tm(t)(r)):ir(e,t)}function Ua(e,t){return _e.array(e)?e.some(r=>
311ir(r,t)):ir(e,t)}function tm(e){return t=>e.some(r=>ir(r,t))}function Kx(...e){return e.every(_e.array)||e.every(_e.number)||e.every(_e.plainObject)||e.every(_e.string)}function Tn(e,t){return _e.plainObject(e)||_e.array(e)?_e.string(t)?t.split(".").reduce((n,i)=>n&&n[i],e):_e.number(t)?e[t]:e:e}function ku(e,t){if([e,t].some(_e.nullOrUndefined))throw new Error("Missing required parameters");if(![e,t].every(m=>_e.plainObject(m)||_e.array(m)))throw new Error("Expected plain objects or array");return{added:(m,g)=>{try{return A0(e,t,{key:m,type:"added",value:g})}catch{return!1}},changed:(m,g,b)=>{try{const w=Tn(e,m),S=Tn(t,m),_=_e.defined(g),E=_e.defined(b);if(_||E){const k=E?Ua(b,w):!Ua(g,w),T=Ua(g,S);return k&&T}return[w,S].every(_e.array)||[w,S].every(_e.plainObject)?!ir(w,S):w!==S}catch{return!1}},changedFrom:(m,g,b)=>{if(!_e.defined(m))return!1;try{const w=Tn(e,m),S=Tn(t,m),_=_e.defined(b);return Ua(g,w)&&(_?Ua(b,S):!_)}catch{return!1}},decreased:(m,g,b)=>{if(!_e.defined(m))return!1;try{return O0(e,t,{key:m,actual:g,previous:b,type:"decreased"})}catch{return!1}},emptied:m=>{try{const[g,b]=N0(e,t,{key:m});return!!g.length&&!b.length}catch{return!1}},filled:m=>{try{const[g,b]=N0(e,t,{key:m});return!g.length&&!!b.length}catch{return!1}},increased:(m,g,b)=>{if(!_e.defined(m))return!1;try{return O0(e,t,{key:m,actual:g,previous:b,type:"increased"})}catch{return!1}},removed:(m,g)=>{try{return A0(e,t,{key:m,type:"removed",value:g})}catch{return!1}}}}var vh,D0;function HA(){if(D0)return vh;D0=1;var e=new Error("Element already at target scroll position"),t=new Error("Scroll cancelled"),r=Math.min,n=Date.now;vh={left:i("scrollLeft"),top:i("scrollTop")};function i(u){return function(p,m,g,b){g=g||{},typeof g=="function"&&(b=g,g={}),typeof b!="function"&&(b=l);var w=n(),S=p[u],_=g.ease||a,E=isNaN(g.duration)?350:+g.duration,k=!1;return S===m?b(e,p[u]):requestAnimationFrame(R),T;function T(){k=!0}function R(P){if(k)return b(t,p[u]);var O=n(),I=r(1,(O-w)/E),M=_(I);p[u]=M*(m-S)+S,I<1?requestAnimationFrame(R):requestAnimationFrame(function(){b(null,p[u])})}}}function a(u){return .5*(1-Math.cos(Math.PI*u))}function l(){}return vh}var KA=HA();const GA=Co(KA);var pu={exports:{}},QA=pu.exports,M0;function YA(){return M0||(M0=1,(function(e){(function(t,r){e.exports?e.exports=r():t.Scrollparent=r()})(QA,function(){function t(n){var i=getComputedStyle(n,null).getPropertyValue("overflow");return i.indexOf("scroll")>-1||i.indexOf("auto")>-1}function r(n){if(n instanceof HTMLElement||n instanceof SVGElement){for(var i=n.parentNode;i.parentNode;){if(t(i))return i;i=i.parentNode}return document.scrollingElement||document.documentElement}}return r})})(pu)),pu.exports}var JA=YA();const Gx=Co(JA);var yh,$0;function XA(){if($0)return yh;$0=1;var e=function(n){return Object.prototype.hasOwnProperty.call(n,"props")},t=function(n,i){return n+r(i)},r=function(n){return n===null||typeof n=="boolean"||typeof n>"u"?"":typeof n=="number"?n.toString():typeof n=="string"?n:Array.isArray(n)?n.reduce(t,""):e(n)&&Object.prototype.hasOwnProperty.call(n.props,"children")?r(n.props.children):""};return r.default=r,yh=r,yh}var ZA=XA();const F0=Co(ZA);var wh,U0;function eN(){if(U0)return wh;U0=1;var e=function(T){return t(T)&&!r(T)};function t(k){return!!k&&typeof k=="object"}function r(k){var T=Object.prototype.toString.call(k);return T==="[object RegExp]"||T==="[object Date]"||a(k)}var n=typeof Symbol=="function"&&Symbol.for,i=n?Symbol.for("react.element"):60103;function a(k){return k.$$typeof===i}function l(k){return Array.isArray(k)?[]:{}}function u(k,T){return T.clone!==!1&&T.isMergeableObject(k)?_(l(k),k,T):k}function f(k,T,R){return k.concat(T).map(function(P){return u(P,R)})}function p(k,T){if(!T.customMerge)return _;var R=T.customMerge(k);return typeof R=="function"?R:_}function m(k){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(k).filter(function(T){return Object.propertyIsEnumerable.call(k,T)}):[]}function g(k){return Object.keys(k).concat(m(k))}function b(k,T){try{return T in k}catch{return!1}}function w(k,T){return b(k,T)&&!(Object.hasOwnProperty.call(k,T)&&Object.propertyIsEnumerable.call(k,T))}function S(k,T,R){var P={};
vendor: 6,358 bytes, lines 311-334
311return R.isMergeableObject(k)&&g(k).forEach(function(O){P[O]=u(k[O],R)}),g(T).forEach(function(O){w(k,O)||(b(k,O)&&R.isMergeableObject(T[O])?P[O]=p(O,R)(k[O],T[O],R):P[O]=u(T[O],R))}),P}function _(k,T,R){R=R||{},R.arrayMerge=R.arrayMerge||f,R.isMergeableObject=R.isMergeableObject||e,R.cloneUnlessOtherwiseSpecified=u;var P=Array.isArray(T),O=Array.isArray(k),I=P===O;return I?P?R.arrayMerge(k,T,R):S(k,T,R):u(T,R)}_.all=function(T,R){if(!Array.isArray(T))throw new Error("first argument should be an array");return T.reduce(function(P,O){return _(P,O,R)},{})};var E=_;return wh=E,wh}var tN=eN();const tn=Co(tN);var bh={exports:{}},xh,z0;function rN(){if(z0)return xh;z0=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return xh=e,xh}var _h,B0;function nN(){if(B0)return _h;B0=1;var e=rN();function t(){}function r(){}return r.resetWarningCache=t,_h=function(){function n(l,u,f,p,m,g){if(g!==e){var b=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw b.name="Invariant Violation",b}}n.isRequired=n;function i(){return n}var a={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return a.PropTypes=a,a},_h}var q0;function sN(){return q0||(q0=1,bh.exports=nN()()),bh.exports}var oN=sN();const de=Co(oN);/**!
312 * @fileOverview Kickass library to create and place poppers near their reference elements.
313 * @version 1.16.1
314 * @license
315 * Copyright (c) 2016 Federico Zivolo and contributors
316 *
317 * Permission is hereby granted, free of charge, to any person obtaining a copy
318 * of this software and associated documentation files (the "Software"), to deal
319 * in the Software without restriction, including without limitation the rights
320 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
321 * copies of the Software, and to permit persons to whom the Software is
322 * furnished to do so, subject to the following conditions:
323 *
324 * The above copyright notice and this permission notice shall be included in all
325 * copies or substantial portions of the Software.
326 *
327 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
328 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
329 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
330 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
331 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
332 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
333 * SOFTWARE.
334 */var El=typeof window<"u"&&typeof document<"u"&&typeof navigator<"u",iN=(function(){for(var e=["Edge","Trident","Firefox"],t=0;t<e.length;t+=1)if(El&&navigator.userAgent.indexOf(e[t])>=0)return 1;return 0})();function aN(e){var t=!1;return function(){t||(t=!0,window.Promise.resolve().then(function(){t=!1,e()}))}}function lN(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},iN))}}var cN=El&&window.Promise,uN=cN?aN:lN;function Qx(e){var t={};return e&&t.toString.call(e)==="[object Function]"}function Ao(e,t){if(e.nodeType!==1)return[];var r=e.ownerDocument.defaultView,n=r.getComputedStyle(e,null);return t?n[t]:n}function rm(e){return e.nodeName==="HTML"?e:e.parentNode||e.host}function kl(e){if(!e)return document.body;switch(e.nodeName){case"HTML":case"BODY":return e.ownerDocument.body;case"#document":return e.body}var t=Ao(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/(auto|scroll|overlay)/.test(r+i+n)?e:kl(rm(e))}function Yx(e){return e&&e.referenceNode?e.referenceNode:e}var V0=El&&!!(window.MSInputMethodContext&&document.documentMode),W0=El&&/MSIE 10/.test(navigator.userAgent);function Qi(e){return e===11?V0:e===10?W0:V0||W0}function Mi(e){if(!e)return document.documentElement;for(var t=Qi(10)?document.body:null,r=e.offsetParent||null;r===t&&e.nextElementSibling;)r=(e=e.nextElementSibling).offsetParent;var n=r&&r.nodeName;return!n||n==="BODY"||n==="HTML"?e?e.ownerDocument.documentElement:document.documentElement:["TH","TD","TABLE"].indexOf(r.nodeName)!==-1&&Ao(r,"position")==="static"?Mi(r):r}function dN(e){var t=e.nodeName;return t==="BODY"?!1:t==="HTML"||Mi(e.firstElementChild)===e}function kp(e){return e.parentNode!==null?kp(e.parentNode):e}function Tu(e,t){if(!e||!e.nodeType||!t||!t.nodeType)return document.documentElement;var r=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,n=r?e:t,i=r?t:e,a=document.createRange();a.setStart(n,0),a.setEnd(i,0);var l=a.commonAncestorContainer;if(e!==l&&t!==l||n.contains(i))return dN(l)?l:Mi(l);var u=kp(e);return u.host?Tu(u.host,t):Tu(e,kp(t).host)}function $i(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"top",r=t==="top"?"scrollTop":"scrollLeft",n=e.nodeName;if(n==="BODY"||n==="HTML"){var i=e.ownerDocument.documentElement,a=e.ownerDocument.scrollingElement||i;return a[r]}return e[r]}function fN(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=$i(t,"top"),i=$i(t,"left"),a=r?-1:1;return e.top+=n*a,e.bottom+=n*a,e.left+=i*a,e.right+=i*a,e}function H0(e,t){var r=t==="x"?"Left":"Top",n=r==="Left"?"Right":"Bottom";return parseFloat(e["border"+r+"Width"])+parseFloat(e["border"+n+"Width"])}function K0(e,t,r,n){return Math.max(t["offset"+e],t["scroll"+e],r["client"+e],r["offset"+e],r["scroll"+e],Qi(10)?parseInt(r["offset"+e])+parseInt(n["margin"+(e==="Height"?"Top":"Left")])+parseInt(n["margin"+(e==="Height"?"Bottom":"Right")]):0)}function Jx(e){var t=e.body,r=e.documentElement,n=Qi(10)&&getComputedStyle(r);return{height:K0("Height",t,r,n),width:K0("Width",t,r,n)}}var hN=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},pN=(function(){function e(t,r){for(var n=0;n<r.length;n++){var i=r[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}})(),Fi=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},$r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];
vendor: 13,660 bytes, line 334
334for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e};function Ms(e){return $r({},e,{right:e.left+e.width,bottom:e.top+e.height})}function Tp(e){var t={};try{if(Qi(10)){t=e.getBoundingClientRect();var r=$i(e,"top"),n=$i(e,"left");t.top+=r,t.left+=n,t.bottom+=r,t.right+=n}else t=e.getBoundingClientRect()}catch{}var i={left:t.left,top:t.top,width:t.right-t.left,height:t.bottom-t.top},a=e.nodeName==="HTML"?Jx(e.ownerDocument):{},l=a.width||e.clientWidth||i.width,u=a.height||e.clientHeight||i.height,f=e.offsetWidth-l,p=e.offsetHeight-u;if(f||p){var m=Ao(e);f-=H0(m,"x"),p-=H0(m,"y"),i.width-=f,i.height-=p}return Ms(i)}function nm(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=Qi(10),i=t.nodeName==="HTML",a=Tp(e),l=Tp(t),u=kl(e),f=Ao(t),p=parseFloat(f.borderTopWidth),m=parseFloat(f.borderLeftWidth);r&&i&&(l.top=Math.max(l.top,0),l.left=Math.max(l.left,0));var g=Ms({top:a.top-l.top-p,left:a.left-l.left-m,width:a.width,height:a.height});if(g.marginTop=0,g.marginLeft=0,!n&&i){var b=parseFloat(f.marginTop),w=parseFloat(f.marginLeft);g.top-=p-b,g.bottom-=p-b,g.left-=m-w,g.right-=m-w,g.marginTop=b,g.marginLeft=w}return(n&&!r?t.contains(u):t===u&&u.nodeName!=="BODY")&&(g=fN(g,t)),g}function mN(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=e.ownerDocument.documentElement,n=nm(e,r),i=Math.max(r.clientWidth,window.innerWidth||0),a=Math.max(r.clientHeight,window.innerHeight||0),l=t?0:$i(r),u=t?0:$i(r,"left"),f={top:l-n.top+n.marginTop,left:u-n.left+n.marginLeft,width:i,height:a};return Ms(f)}function Xx(e){var t=e.nodeName;if(t==="BODY"||t==="HTML")return!1;if(Ao(e,"position")==="fixed")return!0;var r=rm(e);return r?Xx(r):!1}function Zx(e){if(!e||!e.parentElement||Qi())return document.documentElement;for(var t=e.parentElement;t&&Ao(t,"transform")==="none";)t=t.parentElement;return t||document.documentElement}function sm(e,t,r,n){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,a={top:0,left:0},l=i?Zx(e):Tu(e,Yx(t));if(n==="viewport")a=mN(l,i);else{var u=void 0;n==="scrollParent"?(u=kl(rm(t)),u.nodeName==="BODY"&&(u=e.ownerDocument.documentElement)):n==="window"?u=e.ownerDocument.documentElement:u=n;var f=nm(u,l,i);if(u.nodeName==="HTML"&&!Xx(l)){var p=Jx(e.ownerDocument),m=p.height,g=p.width;a.top+=f.top-f.marginTop,a.bottom=m+f.top,a.left+=f.left-f.marginLeft,a.right=g+f.left}else a=f}r=r||0;var b=typeof r=="number";return a.left+=b?r:r.left||0,a.top+=b?r:r.top||0,a.right-=b?r:r.right||0,a.bottom-=b?r:r.bottom||0,a}function gN(e){var t=e.width,r=e.height;return t*r}function e_(e,t,r,n,i){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0;if(e.indexOf("auto")===-1)return e;var l=sm(r,n,a,i),u={top:{width:l.width,height:t.top-l.top},right:{width:l.right-t.right,height:l.height},bottom:{width:l.width,height:l.bottom-t.bottom},left:{width:t.left-l.left,height:l.height}},f=Object.keys(u).map(function(b){return $r({key:b},u[b],{area:gN(u[b])})}).sort(function(b,w){return w.area-b.area}),p=f.filter(function(b){var w=b.width,S=b.height;return w>=r.clientWidth&&S>=r.clientHeight}),m=p.length>0?p[0].key:f[0].key,g=e.split("-")[1];return m+(g?"-"+g:"")}function t_(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null,i=n?Zx(t):Tu(t,Yx(r));return nm(r,i,n)}function r_(e){var t=e.ownerDocument.defaultView,r=t.getComputedStyle(e),n=parseFloat(r.marginTop||0)+parseFloat(r.marginBottom||0),i=parseFloat(r.marginLeft||0)+parseFloat(r.marginRight||0),a={width:e.offsetWidth+i,height:e.offsetHeight+n};return a}function Cu(e){var t={left:"right",right:"left",bottom:"top",top:"bottom"};return e.replace(/left|right|bottom|top/g,function(r){return t[r]})}function n_(e,t,r){r=r.split("-")[0];var n=r_(e),i={width:n.width,height:n.height},a=["right","left"].indexOf(r)!==-1,l=a?"top":"left",u=a?"left":"top",f=a?"height":"width",p=a?"width":"height";return i[l]=t[l]+t[f]/2-n[f]/2,r===u?i[u]=t[u]-n[p]:i[u]=t[Cu(u)],i}function Tl(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function vN(e,t,r){if(Array.prototype.findIndex)return e.findIndex(function(i){return i[t]===r});var n=Tl(e,function(i){return i[t]===r});return e.indexOf(n)}function s_(e,t,r){var n=r===void 0?e:e.slice(0,vN(e,"name",r));return n.forEach(function(i){i.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var a=i.function||i.fn;i.enabled&&Qx(a)&&(t.offsets.popper=Ms(t.offsets.popper),t.offsets.reference=Ms(t.offsets.reference),t=a(t,i))}),t}function yN(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=t_(this.state,this.popper,this.reference,this.options.positionFixed),e.placement=e_(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.positionFixed=this.options.positionFixed,e.offsets.popper=n_(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",e=s_(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}function o_(e,t){return e.some(function(r){var n=r.name,i=r.enabled;return i&&n===t})}function om(e){for(var t=[!1,"ms","Webkit","Moz","O"],r=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<t.length;n++){var i=t[n],a=i?""+i+r:e;if(typeof document.body.style[a]<"u")return a}return null}function wN(){return this.state.isDestroyed=!0,o_(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.position="",this.popper.style.top="",this.popper.style.left="",this.popper.style.right="",this.popper.style.bottom="",this.popper.style.willChange="",this.popper.style[om("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function i_(e){var t=e.ownerDocument;return t?t.defaultView:window}function a_(e,t,r,n){var i=e.nodeName==="BODY",a=i?e.ownerDocument.defaultView:e;a.addEventListener(t,r,{passive:!0}),i||a_(kl(a.parentNode),t,r,n),n.push(a)}function bN(e,t,r,n){r.updateBound=n,i_(e).addEventListener("resize",r.updateBound,{passive:!0});var i=kl(e);return a_(i,"scroll",r.updateBound,r.scrollParents),r.scrollElement=i,r.eventsEnabled=!0,r}function xN(){this.state.eventsEnabled||(this.state=bN(this.reference,this.options,this.state,this.scheduleUpdate))}function _N(e,t){return i_(e).removeEventListener("resize",t.updateBound),t.scrollParents.forEach(function(r){r.removeEventListener("scroll",t.updateBound)}),t.updateBound=null,t.scrollParents=[],t.scrollElement=null,t.eventsEnabled=!1,t}function SN(){this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=_N(this.reference,this.state))}function im(e){return e!==""&&!isNaN(parseFloat(e))&&isFinite(e)}function Cp(e,t){Object.keys(t).forEach(function(r){var n="";["width","height","top","right","bottom","left"].indexOf(r)!==-1&&im(t[r])&&(n="px"),e.style[r]=t[r]+n})}function EN(e,t){Object.keys(t).forEach(function(r){var n=t[r];n!==!1?e.setAttribute(r,t[r]):e.removeAttribute(r)})}function kN(e){return Cp(e.instance.popper,e.styles),EN(e.instance.popper,e.attributes),e.arrowElement&&Object.keys(e.arrowStyles).length&&Cp(e.arrowElement,e.arrowStyles),e}function TN(e,t,r,n,i){var a=t_(i,t,e,r.positionFixed),l=e_(r.placement,a,t,e,r.modifiers.flip.boundariesElement,r.modifiers.flip.padding);return t.setAttribute("x-placement",l),Cp(t,{position:r.positionFixed?"fixed":"absolute"}),r}function CN(e,t){var r=e.offsets,n=r.popper,i=r.reference,a=Math.round,l=Math.floor,u=function(k){return k},f=a(i.width),p=a(n.width),m=["left","right"].indexOf(e.placement)!==-1,g=e.placement.indexOf("-")!==-1,b=f%2===p%2,w=f%2===1&&p%2===1,S=t?m||g||b?a:l:u,_=t?a:u;return{left:S(w&&!g&&t?n.left-1:n.left),top:_(n.top),bottom:_(n.bottom),right:S(n.right)}}var RN=El&&/Firefox/i.test(navigator.userAgent);function PN(e,t){var r=t.x,n=t.y,i=e.offsets.popper,a=Tl(e.instance.modifiers,function(R){return R.name==="applyStyle"}).gpuAcceleration;a!==void 0&&console.warn("WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!");var l=a!==void 0?a:t.gpuAcceleration,u=Mi(e.instance.popper),f=Tp(u),p={position:i.position},m=CN(e,window.devicePixelRatio<2||!RN),g=r==="bottom"?"top":"bottom",b=n==="right"?"left":"right",w=om("transform"),S=void 0,_=void 0;if(g==="bottom"?u.nodeName==="HTML"?_=-u.clientHeight+m.bottom:_=-f.height+m.bottom:_=m.top,b==="right"?u.nodeName==="HTML"?S=-u.clientWidth+m.right:S=-f.width+m.right:S=m.left,l&&w)p[w]="translate3d("+S+"px, "+_+"px, 0)",p[g]=0,p[b]=0,p.willChange="transform";else{var E=g==="bottom"?-1:1,k=b==="right"?-1:1;p[g]=_*E,p[b]=S*k,p.willChange=g+", "+b}var T={"x-placement":e.placement};return e.attributes=$r({},T,e.attributes),e.styles=$r({},p,e.styles),e.arrowStyles=$r({},e.offsets.arrow,e.arrowStyles),e}function l_(e,t,r){var n=Tl(e,function(u){var f=u.name;return f===t}),i=!!n&&e.some(function(u){return u.name===r&&u.enabled&&u.order<n.order});if(!i){var a="`"+t+"`",l="`"+r+"`";console.warn(l+" modifier is required by "+a+" modifier in order to work, be sure to include it before "+a+"!")}return i}function jN(e,t){var r;if(!l_(e.instance.modifiers,"arrow","keepTogether"))return e;var n=t.element;if(typeof n=="string"){if(n=e.instance.popper.querySelector(n),!n)return e}else if(!e.instance.popper.contains(n))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),e;var i=e.placement.split("-")[0],a=e.offsets,l=a.popper,u=a.reference,f=["left","right"].indexOf(i)!==-1,p=f?"height":"width",m=f?"Top":"Left",g=m.toLowerCase(),b=f?"left":"top",w=f?"bottom":"right",S=r_(n)[p];u[w]-S<l[g]&&(e.offsets.popper[g]-=l[g]-(u[w]-S)),u[g]+S>l[w]&&(e.offsets.popper[g]+=u[g]+S-l[w]),e.offsets.popper=Ms(e.offsets.popper);var _=u[g]+u[p]/2-S/2,E=Ao(e.instance.popper),k=parseFloat(E["margin"+m]),T=parseFloat(E["border"+m+"Width"]),R=_-e.offsets.popper[g]-k-T;return R=Math.max(Math.min(l[p]-S,R),0),e.arrowElement=n,e.offsets.arrow=(r={},Fi(r,g,Math.round(R)),Fi(r,b,""),r),e}function ON(e){return e==="end"?"start":e==="start"?"end":e}var c_=["auto-start","auto","auto-end","top-start","top","top-end","right-start","right","right-end","bottom-end","bottom","bottom-start","left-end","left","left-start"],Sh=c_.slice(3);function G0(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=Sh.indexOf(e),n=Sh.slice(r+1).concat(Sh.slice(0,r));return t?n.reverse():n}var Eh={FLIP:"flip",CLOCKWISE:"clockwise",COUNTERCLOCKWISE:"counterclockwise"};function AN(e,t){if(o_(e.instance.modifiers,"inner")||e.flipped&&e.placement===e.originalPlacement)return e;var r=sm(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement,e.positionFixed),n=e.placement.split("-")[0],i=Cu(n),a=e.placement.split("-")[1]||"",l=[];switch(t.behavior){case Eh.FLIP:l=[n,i];break;case Eh.CLOCKWISE:l=G0(n);break;case Eh.COUNTERCLOCKWISE:l=G0(n,!0);break;default:l=t.behavior}return l.forEach(function(u,f){if(n!==u||l.length===f+1)return e;n=e.placement.split("-")[0],i=Cu(n);var p=e.offsets.popper,m=e.offsets.reference,g=Math.floor,b=n==="left"&&g(p.right)>g(m.left)||n==="right"&&g(p.left)<g(m.right)||n==="top"&&g(p.bottom)>g(m.top)||n==="bottom"&&g(p.top)<g(m.bottom),w=g(p.left)<g(r.left),S=g(p.right)>g(r.right),_=g(p.top)<g(r.top),E=g(p.bottom)>g(r.bottom),k=n==="left"&&w||n==="right"&&S||n==="top"&&_||n==="bottom"&&E,T=["top","bottom"].indexOf(n)!==-1,R=!!t.flipVariations&&(T&&a==="start"&&w||T&&a==="end"&&S||!T&&a==="start"&&_||!T&&a==="end"&&E),P=!!t.flipVariationsByContent&&(T&&a==="start"&&S||T&&a==="end"&&w||!T&&a==="start"&&E||!T&&a==="end"&&_),O=R||P;(b||k||O)&&(e.flipped=!0,(b||k)&&(n=l[f+1]),O&&(a=ON(a)),e.placement=n+(a?"-"+a:""),e.offsets.popper=$r({},e.offsets.popper,n_(e.instance.popper,e.offsets.reference,e.placement)),e=s_(e.instance.modifiers,e,"flip"))}),e}function NN(e){var t=e.offsets,r=t.popper,n=t.reference,i=e.placement.split("-")[0],a=Math.floor,l=["top","bottom"].indexOf(i)!==-1,u=l?"right":"bottom",f=l?"left":"top",p=l?"width":"height";return r[u]<a(n[f])&&(e.offsets.popper[f]=a(n[f])-r[p]),r[f]>a(n[u])&&(e.offsets.popper[f]=a(n[u])),e}function IN(e,t,r,n){var i=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),a=+i[1],l=i[2];if(!a)return e;if(l.indexOf("%")===0){var u=void 0;switch(l){case"%p":u=r;break;case"%":case"%r":default:u=n}var f=Ms(u);return f[t]/100*a}else if(l==="vh"||l==="vw"){var p=void 0;return l==="vh"?p=Math.max(document.documentElement.clientHeight,window.innerHeight||0):p=Math.max(document.documentElement.clientWidth,window.innerWidth||0),p/100*a}else return a}function LN(e,t,r,n){var i=[0,0],a=["right","left"].indexOf(n)!==-1,l=e.split(/(\+|\-)/).map(function(m){return m.trim()}),u=l.indexOf(Tl(l,function(m){return m.search(/,|\s/)!==-1}));l[u]&&l[u].indexOf(",")===-1&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var f=/\s*,\s*|\s+/,p=u!==-1?[l.slice(0,u).concat([l[u].split(f)[0]]),[l[u].split(f)[1]].concat(l.slice(u+1))]:[l];return p=p.map(function(m,g){var b=(g===1?!a:a)?"height":"width",w=!1;return m.reduce(function(S,_){return S[S.length-1]===""&&["+","-"].indexOf(_)!==-1?(S[S.length-1]=_,w=!0,S):w?(S[S.length-1]+=_,w=!1,S):S.concat(_)},[]).map(function(S){return IN(S,b,t,r)})}),p.forEach(function(m,g){m.forEach(function(b,w){im(b)&&(i[g]+=b*(m[w-1]==="-"?-1:1))})}),i}function DN(e,t){var r=t.offset,n=e.placement,i=e.offsets,a=i.popper,l=i.reference,u=n.split("-")[0],f=void 0;
vendor: 6,921 bytes, line 334
334return im(+r)?f=[+r,0]:f=LN(r,a,l,u),u==="left"?(a.top+=f[0],a.left-=f[1]):u==="right"?(a.top+=f[0],a.left+=f[1]):u==="top"?(a.left+=f[0],a.top-=f[1]):u==="bottom"&&(a.left+=f[0],a.top+=f[1]),e.popper=a,e}function MN(e,t){var r=t.boundariesElement||Mi(e.instance.popper);e.instance.reference===r&&(r=Mi(r));var n=om("transform"),i=e.instance.popper.style,a=i.top,l=i.left,u=i[n];i.top="",i.left="",i[n]="";var f=sm(e.instance.popper,e.instance.reference,t.padding,r,e.positionFixed);i.top=a,i.left=l,i[n]=u,t.boundaries=f;var p=t.priority,m=e.offsets.popper,g={primary:function(w){var S=m[w];return m[w]<f[w]&&!t.escapeWithReference&&(S=Math.max(m[w],f[w])),Fi({},w,S)},secondary:function(w){var S=w==="right"?"left":"top",_=m[S];return m[w]>f[w]&&!t.escapeWithReference&&(_=Math.min(m[S],f[w]-(w==="right"?m.width:m.height))),Fi({},S,_)}};return p.forEach(function(b){var w=["left","top"].indexOf(b)!==-1?"primary":"secondary";m=$r({},m,g[w](b))}),e.offsets.popper=m,e}function $N(e){var t=e.placement,r=t.split("-")[0],n=t.split("-")[1];if(n){var i=e.offsets,a=i.reference,l=i.popper,u=["bottom","top"].indexOf(r)!==-1,f=u?"left":"top",p=u?"width":"height",m={start:Fi({},f,a[f]),end:Fi({},f,a[f]+a[p]-l[p])};e.offsets.popper=$r({},l,m[n])}return e}function FN(e){if(!l_(e.instance.modifiers,"hide","preventOverflow"))return e;var t=e.offsets.reference,r=Tl(e.instance.modifiers,function(n){return n.name==="preventOverflow"}).boundaries;if(t.bottom<r.top||t.left>r.right||t.top>r.bottom||t.right<r.left){if(e.hide===!0)return e;e.hide=!0,e.attributes["x-out-of-boundaries"]=""}else{if(e.hide===!1)return e;e.hide=!1,e.attributes["x-out-of-boundaries"]=!1}return e}function UN(e){var t=e.placement,r=t.split("-")[0],n=e.offsets,i=n.popper,a=n.reference,l=["left","right"].indexOf(r)!==-1,u=["top","left"].indexOf(r)===-1;return i[l?"left":"top"]=a[r]-(u?i[l?"width":"height"]:0),e.placement=Cu(t),e.offsets.popper=Ms(i),e}var zN={shift:{order:100,enabled:!0,fn:$N},offset:{order:200,enabled:!0,fn:DN,offset:0},preventOverflow:{order:300,enabled:!0,fn:MN,priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:NN},arrow:{order:500,enabled:!0,fn:jN,element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:AN,behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:UN},hide:{order:800,enabled:!0,fn:FN},computeStyle:{order:850,enabled:!0,fn:PN,gpuAcceleration:!0,x:"bottom",y:"right"},applyStyle:{order:900,enabled:!0,fn:kN,onLoad:TN,gpuAcceleration:void 0}},BN={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:zN},cl=(function(){function e(t,r){var n=this,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};hN(this,e),this.scheduleUpdate=function(){return requestAnimationFrame(n.update)},this.update=uN(this.update.bind(this)),this.options=$r({},e.Defaults,i),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t&&t.jquery?t[0]:t,this.popper=r&&r.jquery?r[0]:r,this.options.modifiers={},Object.keys($r({},e.Defaults.modifiers,i.modifiers)).forEach(function(l){n.options.modifiers[l]=$r({},e.Defaults.modifiers[l]||{},i.modifiers?i.modifiers[l]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(l){return $r({name:l},n.options.modifiers[l])}).sort(function(l,u){return l.order-u.order}),this.modifiers.forEach(function(l){l.enabled&&Qx(l.onLoad)&&l.onLoad(n.reference,n.popper,n.options,l,n.state)}),this.update();var a=this.options.eventsEnabled;a&&this.enableEventListeners(),this.state.eventsEnabled=a}return pN(e,[{key:"update",value:function(){return yN.call(this)}},{key:"destroy",value:function(){return wN.call(this)}},{key:"enableEventListeners",value:function(){return xN.call(this)}},{key:"disableEventListeners",value:function(){return SN.call(this)}}]),e})();cl.Utils=(typeof window<"u"?window:global).PopperUtils;cl.placements=c_;cl.Defaults=BN;var qN=["innerHTML","ownerDocument","style","attributes","nodeValue"],VN=["Array","ArrayBuffer","AsyncFunction","AsyncGenerator","AsyncGeneratorFunction","Date","Error","Function","Generator","GeneratorFunction","HTMLElement","Map","Object","Promise","RegExp","Set","WeakMap","WeakSet"],WN=["bigint","boolean","null","number","string","symbol","undefined"];function Ju(e){var t=Object.prototype.toString.call(e).slice(8,-1);if(/HTML\w+Element/.test(t))return"HTMLElement";if(HN(t))return t}function an(e){return function(t){return Ju(t)===e}}function HN(e){return VN.includes(e)}function Yi(e){return function(t){return typeof t===e}}function KN(e){return WN.includes(e)}function Q(e){if(e===null)return"null";switch(typeof e){case"bigint":return"bigint";case"boolean":return"boolean";case"number":return"number";case"string":return"string";case"symbol":return"symbol";case"undefined":return"undefined"}if(Q.array(e))return"Array";if(Q.plainFunction(e))return"Function";var t=Ju(e);return t||"Object"}Q.array=Array.isArray;Q.arrayOf=function(e,t){return!Q.array(e)&&!Q.function(t)?!1:e.every(function(r){return t(r)})};Q.asyncGeneratorFunction=function(e){return Ju(e)==="AsyncGeneratorFunction"};Q.asyncFunction=an("AsyncFunction");Q.bigint=Yi("bigint");Q.boolean=function(e){return e===!0||e===!1};Q.date=an("Date");Q.defined=function(e){return!Q.undefined(e)};Q.domElement=function(e){return Q.object(e)&&!Q.plainObject(e)&&e.nodeType===1&&Q.string(e.nodeName)&&qN.every(function(t){return t in e})};Q.empty=function(e){return Q.string(e)&&e.length===0||Q.array(e)&&e.length===0||Q.object(e)&&!Q.map(e)&&!Q.set(e)&&Object.keys(e).length===0||Q.set(e)&&e.size===0||Q.map(e)&&e.size===0};Q.error=an("Error");Q.function=Yi("function");Q.generator=function(e){return Q.iterable(e)&&Q.function(e.next)&&Q.function(e.throw)};Q.generatorFunction=an("GeneratorFunction");Q.instanceOf=function(e,t){return!e||!t?!1:Object.getPrototypeOf(e)===t.prototype};Q.iterable=function(e){return!Q.nullOrUndefined(e)&&Q.function(e[Symbol.iterator])};Q.map=an("Map");Q.nan=function(e){return Number.isNaN(e)};Q.null=function(e){return e===null};Q.nullOrUndefined=function(e){return Q.null(e)||Q.undefined(e)};Q.number=function(e){return Yi("number")(e)&&!Q.nan(e)};Q.numericString=function(e){return Q.string(e)&&e.length>0&&!Number.isNaN(Number(e))};Q.object=function(e){return!Q.nullOrUndefined(e)&&(Q.function(e)||typeof e=="object")};Q.oneOf=function(e,t){return Q.array(e)?e.indexOf(t)>-1:!1};Q.plainFunction=an("Function");Q.plainObject=function(e){if(Ju(e)!=="Object")return!1;var t=Object.getPrototypeOf(e);return t===null||t===Object.getPrototypeOf({})};Q.primitive=function(e){return Q.null(e)||KN(typeof e)};Q.promise=an("Promise");Q.propertyOf=function(e,t,r){if(!Q.object(e)||!t)return!1;var n=e[t];return Q.function(r)?r(n):Q.defined(n)};Q.regexp=an("RegExp");Q.set=an("Set");Q.string=Yi("string");
334Q.symbol=Yi("symbol");Q.undefined=Yi("undefined");Q.weakMap=an("WeakMap");Q.weakSet=an("WeakSet");function u_(e){return function(t){return typeof t===e}}var GN=u_("function"),QN=function(e){return e===null},Q0=function(e){return Object.prototype.toString.call(e).slice(8,-1)==="RegExp"},Y0=function(e){return!YN(e)&&!QN(e)&&(GN(e)||typeof e=="object")},YN=u_("undefined"),Rp=function(e){var t=typeof Symbol=="function"&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};function JN(e,t){var r=e.length;if(r!==t.length)return!1;for(var n=r;n--!==0;)if(!wr(e[n],t[n]))return!1;return!0}function XN(e,t){if(e.byteLength!==t.byteLength)return!1;for(var r=new DataView(e.buffer),n=new DataView(t.buffer),i=e.byteLength;i--;)if(r.getUint8(i)!==n.getUint8(i))return!1;return!0}function ZN(e,t){var r,n,i,a;if(e.size!==t.size)return!1;try{for(var l=Rp(e.entries()),u=l.next();!u.done;u=l.next()){var f=u.value;if(!t.has(f[0]))return!1}}catch(g){r={error:g}}finally{try{u&&!u.done&&(n=l.return)&&n.call(l)}finally{if(r)throw r.error}}try{for(var p=Rp(e.entries()),m=p.next();!m.done;m=p.next()){var f=m.value;if(!wr(f[1],t.get(f[0])))return!1}}catch(g){i={error:g}}finally{try{m&&!m.done&&(a=p.return)&&a.call(p)}finally{if(i)throw i.error}}return!0}function eI(e,t){var r,n;if(e.size!==t.size)return!1;try{for(var i=Rp(e.entries()),a=i.next();!a.done;a=i.next()){var l=a.value;if(!t.has(l[0]))return!1}}catch(u){r={error:u}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return!0}function wr(e,t){if(e===t)return!0;if(e&&Y0(e)&&t&&Y0(t)){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)&&Array.isArray(t))return JN(e,t);if(e instanceof Map&&t instanceof Map)return ZN(e,t);if(e instanceof Set&&t instanceof Set)return eI(e,t);if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t))return XN(e,t);if(Q0(e)&&Q0(t))return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(var i=r.length;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,r[i]))return!1;for(var i=r.length;i--!==0;){var a=r[i];if(!(a==="_owner"&&e.$$typeof)&&!wr(e[a],t[a]))return!1}return!0}return Number.isNaN(e)&&Number.isNaN(t)?!0:e===t}function tI(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.every(function(r){return Q.string(r)||Q.array(r)||Q.plainObject(r)})}function rI(e,t,r){return d_(e,t)?[e,t].every(Q.array)?!e.some(tw(r))&&t.some(tw(r)):[e,t].every(Q.plainObject)?!Object.entries(e).some(ew(r))&&Object.entries(t).some(ew(r)):t===r:!1}function J0(e,t,r){var n=r.actual,i=r.key,a=r.previous,l=r.type,u=Cn(e,i),f=Cn(t,i),p=[u,f].every(Q.number)&&(l==="increased"?u<f:u>f);return Q.undefined(n)||(p=p&&f===n),Q.undefined(a)||(p=p&&u===a),p}function X0(e,t,r){var n=r.key,i=r.type,a=r.value,l=Cn(e,n),u=Cn(t,n),f=i==="added"?l:u,p=i==="added"?u:l;if(!Q.nullOrUndefined(a)){if(Q.defined(f)){if(Q.array(f)||Q.plainObject(f))return rI(f,p,a)}else return wr(p,a);return!1}return[l,u].every(Q.array)?!p.every(am(f)):[l,u].every(Q.plainObject)?nI(Object.keys(f),Object.keys(p)):![l,u].every(function(m){return Q.primitive(m)&&Q.defined(m)})&&(i==="added"?!Q.defined(l)&&Q.defined(u):Q.defined(l)&&!Q.defined(u))}function Z0(e,t,r){var n=r===void 0?{}:r,i=n.key,a=Cn(e,i),l=Cn(t,i);if(!d_(a,l))throw new TypeError("Inputs have different types");if(!tI(a,l))throw new TypeError("Inputs don't have length");return[a,l].every(Q.plainObject)&&(a=Object.keys(a),l=Object.keys(l)),[a,l]}function ew(e){return function(t){var r=t[0],n=t[1];return Q.array(e)?wr(e,n)||e.some(function(i){return wr(i,n)||Q.array(n)&&am(n)(i)}):Q.plainObject(e)&&e[r]?!!e[r]&&wr(e[r],n):wr(e,n)}}function nI(e,t){return t.some(function(r){return!e.includes(r)})}function tw(e){return function(t){return Q.array(e)?e.some(function(r){return wr(r,t)||Q.array(t)&&am(t)(r)}):wr(e,t)}}function za(e,t){return Q.array(e)?e.some(function(r){return wr(r,t)}):wr(e,t)}function am(e){return function(t){return e.some(function(r){return wr(r,t)})}}function d_(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.every(Q.array)||e.every(Q.number)||e.every(Q.plainObject)||e.every(Q.string)}function Cn(e,t){if(Q.plainObject(e)||Q.array(e)){if(Q.string(t)){var r=t.split(".");return r.reduce(function(n,i){return n&&n[i]},e)}return Q.number(t)?e[t]:e}return e}function sI(e,t){if([e,t].some(Q.nullOrUndefined))throw new Error("Missing required parameters");if(![e,t].every(function(g){return Q.plainObject(g)||Q.array(g)}))throw new Error("Expected plain objects or array");var r=function(g,b){try{return X0(e,t,{key:g,type:"added",value:b})}catch{return!1}},n=function(g,b,w){try{var S=Cn(e,g),_=Cn(t,g),E=Q.defined(b),k=Q.defined(w);if(E||k){var T=k?za(w,S):!za(b,S),R=za(b,_);return T&&R}return[S,_].every(Q.array)||[S,_].every(Q.plainObject)?!wr(S,_):S!==_}catch{return!1}},i=function(g,b,w){if(!Q.defined(g))return!1;try{var S=Cn(e,g),_=Cn(t,g),E=Q.defined(w);return za(b,S)&&(E?za(w,_):!E)}catch{return!1}},a=function(g,b){return Q.defined(g)?n(g,b):!1},l=function(g,b,w){if(!Q.defined(g))return!1;try{return J0(e,t,{key:g,actual:b,previous:w,type:"decreased"})}catch{return!1}},u=function(g){try{var b=Z0(e,t,{key:g}),w=b[0],S=b[1];return!!w.length&&!S.length}catch{return!1}},f=function(g){try{var b=Z0(e,t,{key:g}),w=b[0],S=b[1];return!w.length&&!!S.length}catch{return!1}},p=function(g,b,w){if(!Q.defined(g))return!1;try{return J0(e,t,{key:g,actual:b,previous:w,type:"increased"})}catch{return!1}},m=function(g,b){try{return X0(e,t,{key:g,type:"removed",value:b})}catch{return!1}};return{added:r,changed:n,changedFrom:i,changedTo:a,decreased:l,emptied:u,filled:f,increased:p,removed:m}}function rw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function gt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};
vendor: 4,734 bytes, line 334
334t%2?rw(Object(r),!0).forEach(function(n){er(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Cl(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function oI(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,h_(n.key),n)}}function Rl(e,t,r){return t&&oI(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function er(e,t,r){return t=h_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Pl(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Pp(e,t)}function Ru(e){return Ru=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ru(e)}function Pp(e,t){return Pp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},Pp(e,t)}function iI(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function aI(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a<n.length;a++)i=n[a],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function f_(e,t){if(e==null)return{};var r=aI(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Bn(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function lI(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Bn(e)}function jl(e){var t=iI();return function(){var n=Ru(e),i;if(t){var a=Ru(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return lI(this,i)}}function cI(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function h_(e){var t=cI(e,"string");return typeof t=="symbol"?t:String(t)}var uI={flip:{padding:20},preventOverflow:{padding:10}},dI="The typeValidator argument must be a function with the signature function(props, propName, componentName).",fI="The error message is optional, but must be a string if provided.";function hI(e,t,r,n){return typeof e=="boolean"?e:typeof e=="function"?e(t,r,n):e?!!e:!1}function pI(e,t){return Object.hasOwnProperty.call(e,t)}function mI(e,t,r,n){return new Error("Required ".concat(e[t]," `").concat(t,"` was not specified in `").concat(r,"`."))}function gI(e,t){if(typeof e!="function")throw new TypeError(dI);if(t&&typeof t!="string")throw new TypeError(fI)}function nw(e,t,r){return gI(e,r),function(n,i,a){for(var l=arguments.length,u=new Array(l>3?l-3:0),f=3;f<l;f++)u[f-3]=arguments[f];return hI(t,n,i,a)?pI(n,i)?e.apply(void 0,[n,i,a].concat(u)):mI(n,i,a):e.apply(void 0,[n,i,a].concat(u))}}var Je={INIT:"init",IDLE:"idle",OPENING:"opening",OPEN:"open",CLOSING:"closing"},Ba=wi.createPortal!==void 0;function Sn(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function kh(){return"ontouchstart"in window&&/Mobi/.test(navigator.userAgent)}function ru(e){var t=e.title,r=e.data,n=e.warn,i=n===void 0?!1:n,a=e.debug,l=a===void 0?!1:a,u=i?console.warn||console.error:console.log;l&&t&&r&&(console.groupCollapsed("%creact-floater: ".concat(t),"color: #9b00ff; font-weight: bold; font-size: 12px;"),Array.isArray(r)?r.forEach(function(f){Q.plainObject(f)&&f.key?u.apply(console,[f.key,f.value]):u.apply(console,[f])}):u.apply(console,[r]),console.groupEnd())}function vI(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;e.addEventListener(t,r,n)}function yI(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;e.removeEventListener(t,r,n)}function wI(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,i;i=function(l){r(l),yI(e,t,i)},vI(e,t,i,n)}function sw(){}var p_=(function(e){Pl(r,e);var t=jl(r);function r(){return Cl(this,r),t.apply(this,arguments)}
334return Rl(r,[{key:"componentDidMount",value:function(){Sn()&&(this.node||this.appendNode(),Ba||this.renderPortal())}},{key:"componentDidUpdate",value:function(){Sn()&&(Ba||this.renderPortal())}},{key:"componentWillUnmount",value:function(){!Sn()||!this.node||(Ba||wi.unmountComponentAtNode(this.node),this.node&&this.node.parentNode===document.body&&(document.body.removeChild(this.node),this.node=void 0))}},{key:"appendNode",value:function(){var i=this.props,a=i.id,l=i.zIndex;this.node||(this.node=document.createElement("div"),a&&(this.node.id=a),l&&(this.node.style.zIndex=l),document.body.appendChild(this.node))}},{key:"renderPortal",value:function(){if(!Sn())return null;var i=this.props,a=i.children,l=i.setRef;if(this.node||this.appendNode(),Ba)return wi.createPortal(a,this.node);var u=wi.unstable_renderSubtreeIntoContainer(this,a.length>1?G.createElement("div",null,a):a[0],this.node);return l(u),null}},{key:"renderReact16",value:function(){var i=this.props,a=i.hasChildren,l=i.placement,u=i.target;return a?this.renderPortal():u||l==="center"?this.renderPortal():null}},{key:"render",value:function(){return Ba?this.renderReact16():null}}]),r})(G.Component);er(p_,"propTypes",{children:de.oneOfType([de.element,de.array]),hasChildren:de.bool,id:de.oneOfType([de.string,de.number]),placement:de.string,setRef:de.func.isRequired,target:de.oneOfType([de.object,de.string]),zIndex:de.number});var m_=(function(e){Pl(r,e);var t=jl(r);function r(){return Cl(this,r),t.apply(this,arguments)}return Rl(r,[{key:"parentStyle",get:function(){var i=this.props,a=i.placement,l=i.styles,u=l.arrow.length,f={pointerEvents:"none",position:"absolute",width:"100%"};return a.startsWith("top")?(f.bottom=0,f.left=0,f.right=0,f.height=u):a.startsWith("bottom")?(f.left=0,f.right=0,f.top=0,f.height=u):a.startsWith("left")?(f.right=0,f.top=0,f.bottom=0):a.startsWith("right")&&(f.left=0,f.top=0),f}},{key:"render",value:function(){var i=this.props,a=i.placement,l=i.setArrowRef,u=i.styles,f=u.arrow,p=f.color,m=f.display,g=f.length,b=f.margin,w=f.position,S=f.spread,_={display:m,position:w},E,k=S,T=g;return a.startsWith("top")?(E="0,0 ".concat(k/2,",").concat(T," ").concat(k,",0"),_.bottom=0,_.marginLeft=b,_.marginRight=b):a.startsWith("bottom")?(E="".concat(k,",").concat(T," ").concat(k/2,",0 0,").concat(T),_.top=0,_.marginLeft=b,_.marginRight=b):a.startsWith("left")?(T=S,k=g,E="0,0 ".concat(k,",").concat(T/2," 0,").concat(T),_.right=0,_.marginTop=b,_.marginBottom=b):a.startsWith("right")&&(T=S,k=g,E="".concat(k,",").concat(T," ").concat(k,",0 0,").concat(T/2),_.left=0,_.marginTop=b,_.marginBottom=b),G.createElement("div",{className:"__floater__arrow",style:this.parentStyle},G.createElement("span",{ref:l,style:_},G.createElement("svg",{width:k,height:T,version:"1.1",xmlns:"http://www.w3.org/2000/svg"},G.createElement("polygon",{points:E,fill:p}))))}}]),r})(G.Component);er(m_,"propTypes",{placement:de.string.isRequired,setArrowRef:de.func.isRequired,styles:de.object.isRequired});var bI=["color","height","width"];function g_(e){var t=e.handleClick,r=e.styles,n=r.color,i=r.height,a=r.width,l=f_(r,bI);return G.createElement("button",{"aria-label":"close",onClick:t,style:l,type:"button"},G.createElement("svg",{width:"".concat(a,"px"),height:"".concat(i,"px"),viewBox:"0 0 18 18",version:"1.1",xmlns:"http://www.w3.org/2000/svg",preserveAspectRatio:"xMidYMid"},G.createElement("g",null,G.createElement("path",{d:"M8.13911129,9.00268191 L0.171521827,17.0258467 C-0.0498027049,17.248715 -0.0498027049,17.6098394 0.171521827,17.8327545 C0.28204354,17.9443526 0.427188206,17.9998706 0.572051765,17.9998706 C0.71714958,17.9998706 0.862013139,17.9443526 0.972581703,17.8327545 L9.0000937,9.74924618 L17.0276057,17.8327545 C17.1384085,17.9443526 17.2832721,17.9998706 17.4281356,17.9998706 C17.5729992,17.9998706 17.718097,17.9443526 17.8286656,17.8327545 C18.0499901,17.6098862 18.0499901,17.2487618 17.8286656,17.0258467 L9.86135722,9.00268191 L17.8340066,0.973848225 C18.0553311,0.750979934 18.0553311,0.389855532 17.8340066,0.16694039 C17.6126821,-0.0556467968 17.254037,-0.0556467968 17.0329467,0.16694039 L9.00042166,8.25611765 L0.967006424,0.167268345 C0.745681892,-0.0553188426 0.387317931,-0.0553188426 0.165993399,0.167268345 C-0.0553311331,0.390136635 -0.0553311331,0.751261038 0.165993399,0.974176179 L8.13920499,9.00268191 L8.13911129,9.00268191 Z",fill:n}))))}g_.propTypes={handleClick:de.func.isRequired,styles:de.object.isRequired};function v_(e){var t=e.content,r=e.footer,n=e.handleClick,i=e.open,a=e.positionWrapper,l=e.showCloseButton,u=e.title,f=e.styles,p={content:G.isValidElement(t)?t:G.createElement("div",{className:"__floater__c
334ontent",style:f.content},t)};return u&&(p.title=G.isValidElement(u)?u:G.createElement("div",{className:"__floater__title",style:f.title},u)),r&&(p.footer=G.isValidElement(r)?r:G.createElement("div",{className:"__floater__footer",style:f.footer},r)),(l||a)&&!Q.boolean(i)&&(p.close=G.createElement(g_,{styles:f.close,handleClick:n})),G.createElement("div",{className:"__floater__container",style:f.container},p.close,p.title,p.content,p.footer)}v_.propTypes={content:de.node.isRequired,footer:de.node,handleClick:de.func.isRequired,open:de.bool,positionWrapper:de.bool.isRequired,showCloseButton:de.bool.isRequired,styles:de.object.isRequired,title:de.node};var y_=(function(e){Pl(r,e);var t=jl(r);function r(){return Cl(this,r),t.apply(this,arguments)}return Rl(r,[{key:"style",get:function(){var i=this.props,a=i.disableAnimation,l=i.component,u=i.placement,f=i.hideArrow,p=i.status,m=i.styles,g=m.arrow.length,b=m.floater,w=m.floaterCentered,S=m.floaterClosing,_=m.floaterOpening,E=m.floaterWithAnimation,k=m.floaterWithComponent,T={};return f||(u.startsWith("top")?T.padding="0 0 ".concat(g,"px"):u.startsWith("bottom")?T.padding="".concat(g,"px 0 0"):u.startsWith("left")?T.padding="0 ".concat(g,"px 0 0"):u.startsWith("right")&&(T.padding="0 0 0 ".concat(g,"px"))),[Je.OPENING,Je.OPEN].indexOf(p)!==-1&&(T=gt(gt({},T),_)),p===Je.CLOSING&&(T=gt(gt({},T),S)),p===Je.OPEN&&!a&&(T=gt(gt({},T),E)),u==="center"&&(T=gt(gt({},T),w)),l&&(T=gt(gt({},T),k)),gt(gt({},b),T)}},{key:"render",value:function(){var i=this.props,a=i.component,l=i.handleClick,u=i.hideArrow,f=i.setFloaterRef,p=i.status,m={},g=["__floater"];return a?G.isValidElement(a)?m.content=G.cloneElement(a,{closeFn:l}):m.content=a({closeFn:l}):m.content=G.createElement(v_,this.props),p===Je.OPEN&&g.push("__floater__open"),u||(m.arrow=G.createElement(m_,this.props)),G.createElement("div",{ref:f,className:g.join(" "),style:this.style},G.createElement("div",{className:"__floater__body"},m.content,m.arrow))}}]),r})(G.Component);er(y_,"propTypes",{component:de.oneOfType([de.func,de.element]),content:de.node,disableAnimation:de.bool.isRequired,footer:de.node,handleClick:de.func.isRequired,hideArrow:de.bool.isRequired,open:de.bool,placement:de.string.isRequired,positionWrapper:de.bool.isRequired,setArrowRef:de.func.isRequired,setFloaterRef:de.func.isRequired,showCloseButton:de.bool,status:de.string.isRequired,styles:de.object.isRequired,title:de.node});var w_=(function(e){Pl(r,e);var t=jl(r);function r(){return Cl(this,r),t.apply(this,arguments)}return Rl(r,[{key:"render",value:function(){var i=this.props,a=i.children,l=i.handleClick,u=i.handleMouseEnter,f=i.handleMouseLeave,p=i.setChildRef,m=i.setWrapperRef,g=i.style,b=i.styles,w;if(a)if(G.Children.count(a)===1)if(!G.isValidElement(a))w=G.createElement("span",null,a);else{var S=Q.function(a.type)?"innerRef":"ref";w=G.cloneElement(G.Children.only(a),er({},S,p))}else w=a;return w?G.createElement("span",{ref:m,style:gt(gt({},b),g),onClick:l,onMouseEnter:u,onMouseLeave:f},w):null}}]),r})(G.Component);er(w_,"propTypes",{children:de.node,handleClick:de.func.isRequired,handleMouseEnter:de.func.isRequired,handleMouseLeave:de.func.isRequired,setChildRef:de.func.isRequired,setWrapperRef:de.func.isRequired,style:de.object,styles:de.object.isRequired});var xI={zIndex:100};function _I(e){var t=tn(xI,e.options||{});return{wrapper:{cursor:"help",display:"inline-flex",flexDirection:"column",zIndex:t.zIndex},wrapperPosition:{left:-1e3,position:"absolute",top:-1e3,visibility:"hidden"},floater:{display:"inline-block",filter:"drop-shadow(0 0 3px rgba(0, 0, 0, 0.3))",maxWidth:300,opacity:0,position:"relative",transition:"opacity 0.3s",visibility:"hidden",zIndex:t.zIndex},floaterOpening:{opacity:1,visibility:"visible"},floaterWithAnimation:{opacity:1,transition:"opacity 0.3s, transform 0.2s",visibility:"visible"},floaterWithComponent:{maxWidth:"100%"},floaterClosing:{opacity:0,visibility:"visible"},floaterCentered:{left:"50%",position:"fixed",top:"50%",transform:"translate(-50%, -50%)"},container:{backgroundColor:"#fff",color:"#666",minHeight:60,minWidth:200,padding:20,position:"relative",zIndex:10},title:{borderBottom:"1px solid #555",color:"#555",fontSize:18,marginBottom:5,paddingBottom:6,paddingRight:18},content:{fontSize:15},close:{backgroundColor:"transparent",border:0,borderRadius:0,color:"#555",fontSize:0,height:15,outline:"none",padding:10,position:"absolute",right:0,top:0,width:15,WebkitAppearance:"none"},footer:{borderTop:"1px solid #ccc",fontSize:13,marginTop:10,paddingTop:5},arrow:{color:"#fff",display:"inline-flex",length:16,margin:8,position:"absolute",spread:32},options:t}}var SI=["arrow","flip","offset"],EI=["position","top","right","bottom","left"],lm=(function(e){Pl(r,e);var t=jl(r);function r(n){var i;return Cl(this,r),i=t.call(this,n),er(Bn(i),"setArrowRef",function(a){i.arrowRef=a}),er(Bn(i),"setChildRef",function(a){i.childRef=a}),er(Bn(i),"setFloaterRef",function(a){i.floaterRef=a}),er(Bn(i),"setWrapperRef",function(a){i.wrapperRef=a}),er(Bn(i),"handleTransitionEnd",function(){var a=i.state.status,l=i.props.callback;
vendor: 3,216 bytes, line 334
334i.wrapperPopper&&i.wrapperPopper.instance.update(),i.setState({status:a===Je.OPENING?Je.OPEN:Je.IDLE},function(){var u=i.state.status;l(u===Je.OPEN?"open":"close",i.props)})}),er(Bn(i),"handleClick",function(){var a=i.props,l=a.event,u=a.open;if(!Q.boolean(u)){var f=i.state,p=f.positionWrapper,m=f.status;(i.event==="click"||i.event==="hover"&&p)&&(ru({title:"click",data:[{event:l,status:m===Je.OPEN?"closing":"opening"}],debug:i.debug}),i.toggle())}}),er(Bn(i),"handleMouseEnter",function(){var a=i.props,l=a.event,u=a.open;if(!(Q.boolean(u)||kh())){var f=i.state.status;i.event==="hover"&&f===Je.IDLE&&(ru({title:"mouseEnter",data:[{key:"originalEvent",value:l}],debug:i.debug}),clearTimeout(i.eventDelayTimeout),i.toggle())}}),er(Bn(i),"handleMouseLeave",function(){var a=i.props,l=a.event,u=a.eventDelay,f=a.open;if(!(Q.boolean(f)||kh())){var p=i.state,m=p.status,g=p.positionWrapper;i.event==="hover"&&(ru({title:"mouseLeave",data:[{key:"originalEvent",value:l}],debug:i.debug}),u?[Je.OPENING,Je.OPEN].indexOf(m)!==-1&&!g&&!i.eventDelayTimeout&&(i.eventDelayTimeout=setTimeout(function(){delete i.eventDelayTimeout,i.toggle()},u*1e3)):i.toggle(Je.IDLE))}}),i.state={currentPlacement:n.placement,needsUpdate:!1,positionWrapper:n.wrapperOptions.position&&!!n.target,status:Je.INIT,statusWrapper:Je.INIT},i._isMounted=!1,i.hasMounted=!1,Sn()&&window.addEventListener("load",function(){i.popper&&i.popper.instance.update(),i.wrapperPopper&&i.wrapperPopper.instance.update()}),i}return Rl(r,[{key:"componentDidMount",value:function(){if(Sn()){var i=this.state.positionWrapper,a=this.props,l=a.children,u=a.open,f=a.target;this._isMounted=!0,ru({title:"init",data:{hasChildren:!!l,hasTarget:!!f,isControlled:Q.boolean(u),positionWrapper:i,target:this.target,floater:this.floaterRef},debug:this.debug}),this.hasMounted||(this.initPopper(),this.hasMounted=!0),!l&&f&&Q.boolean(u)}}},{key:"componentDidUpdate",value:function(i,a){if(Sn()){var l=this.props,u=l.autoOpen,f=l.open,p=l.target,m=l.wrapperOptions,g=sI(a,this.state),b=g.changedFrom,w=g.changed;if(i.open!==f){var S;Q.boolean(f)&&(S=f?Je.OPENING:Je.CLOSING),this.toggle(S)}(i.wrapperOptions.position!==m.position||i.target!==p)&&this.changeWrapperPosition(this.props),w("status",Je.IDLE)&&f?this.toggle(Je.OPEN):b("status",Je.INIT,Je.IDLE)&&u&&this.toggle(Je.OPEN),this.popper&&w("status",Je.OPENING)&&this.popper.instance.update(),this.floaterRef&&(w("status",Je.OPENING)||w("status",Je.CLOSING))&&wI(this.floaterRef,"transitionend",this.handleTransitionEnd),w("needsUpdate",!0)&&this.rebuildPopper()}}},{key:"componentWillUnmount",value:function(){Sn()&&(this._isMounted=!1,this.popper&&this.popper.instance.destroy(),this.wrapperPopper&&this.wrapperPopper.instance.destroy())}},{key:"initPopper",value:function(){var i=this,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.target,l=this.state.positionWrapper,u=this.props,f=u.disableFlip,p=u.getPopper,m=u.hideArrow,g=u.offset,b=u.placement,w=u.wrapperOptions,S=b==="top"||b==="bottom"?"flip":["right","bottom-end","top-end","left","top-start","bottom-start"];if(b==="center")this.setState({status:Je.IDLE});else if(a&&this.floaterRef){var _=this.options,E=_.arrow,k=_.flip,T=_.offset,R=f_(_,
334SI);new cl(a,this.floaterRef,{placement:b,modifiers:gt({arrow:gt({enabled:!m,element:this.arrowRef},E),flip:gt({enabled:!f,behavior:S},k),offset:gt({offset:"0, ".concat(g,"px")},T)},R),onCreate:function(I){var M;if(i.popper=I,!((M=i.floaterRef)!==null&&M!==void 0&&M.isConnected)){i.setState({needsUpdate:!0});return}p(I,"floater"),i._isMounted&&i.setState({currentPlacement:I.placement,status:Je.IDLE}),b!==I.placement&&setTimeout(function(){I.instance.update()},1)},onUpdate:function(I){i.popper=I;var M=i.state.currentPlacement;i._isMounted&&I.placement!==M&&i.setState({currentPlacement:I.placement})}})}if(l){var P=Q.undefined(w.offset)?0:w.offset;new cl(this.target,this.wrapperRef,{placement:w.placement||b,modifiers:{arrow:{enabled:!1},offset:{offset:"0, ".concat(P,"px")},flip:{enabled:!1}},onCreate:function(I){i.wrapperPopper=I,i._isMounted&&i.setState({statusWrapper:Je.IDLE}),p(I,"wrapper"),b!==I.placement&&setTimeout(function(){I.instance.update()},1)}})}}},{key:"rebuildPopper",value:function(){var i=this;this.floaterRefInterval=setInterval(function(){var a;(a=i.floaterRef)!==null&&a!==void 0&&a.isConnected&&(clearInterval(i.floaterRefInterval),i.setState({needsUpdate:!1}),i.initPopper())},50)}},{key:"changeWrapperPosition",value:function(i){var a=i.target,l=i.wrapperOptions;this.setState({positionWrapper:l.position&&!!a})}},{key:"toggle",value:function(i){var a=this.state.status,l=a===Je.OPEN?Je.CLOSING:Je.OPENING;Q.undefined(i)||(l=i),this.setState({status:l})}},{key:"debug",get:function(){var i=this.props.debug;return i||Sn()&&"ReactFloaterDebug"in window&&!!window.ReactFloaterDebug}},{key:"event",get:function(){var i=this.props,a=i.disableHoverToClick,l=i.event;return l==="hover"&&kh()&&!a?"click":l}},{key:"options",get:function(){var i=this.props.options;return tn(uI,i||{})}},{key:"styles",get:function(){var i=this,a=this.state,l=a.status,u=a.positionWrapper,f=a.statusWrapper,p=this.props.styles,m=tn(_I(p),p);if(u){var g;[Je.IDLE].indexOf(l)===-1||[Je.IDLE].indexOf(f)===-1?g=m.wrapperPosition:g=this.wrapperPopper.styles,m.wrapper=gt(gt({},m.wrapper),g)}if(this.target){var b=window.getComputedStyle(this.target);this.wrapperStyles?m.wrapper=gt(gt({},m.wrapper),this.wrapperStyles):["relative","static"].indexOf(b.position)===-1&&(this.wrapperStyles={},u||(EI.forEach(function(w){i.wrapperStyles[w]=b[w]}),m.wrapper=gt(gt({},m.wrapper),this.wrapperStyles),this.target.style.position="relative",this.target.style.top="auto",this.target.style.right="auto",this.target.style.bottom="auto",this.target.style.left="auto"))}return m}},{key:"target",get:function(){if(!Sn())return null;var i=this.props.target;return i?Q.domElement(i)?i:document.querySelector(i):this.childRef||this.wrapperRef}},{key:"render",value:function(){var i=this.state,a=i.currentPlacement,l=i.positionWrapper,u=i.status,f=this.props,p=f.children,m=f.component,g=f.content,b=f.disableAnimation,w=f.footer,S=f.hideArrow,_=f.id,E=f.open,k=f.showCloseButton,T=f.style,R=f.target,P=f.title,O=G.createElement(w_,{handleClick:this.handleClick,handleMouseEnter:this.handleMouseEnter,handleMouseLeave:this.handleMouseLeave,setChildRef:this.setChildRef,setWrapperRef:this.setWrapperRef,style:T,styles:this.styles.wrapper},p),I={};return l?I.wrapperInPortal=O:I.wrapperAsChildren=O,G.createElement("span",null,G.createElement(p_,{hasChildren:!!p,id:_,placement:a,setRef:this.setFloaterRef,target:R,zIndex:this.styles.options.zIndex},G.createElement(y_,{component:m,content:g,disableAnimation:b,footer:w,handleClick:this.handleClick,hideArrow:S||a==="center",open:E,placement:a,positionWrapper:l,setArrowRef:this.setArrowRef,setFloaterRef:this.setFloaterRef,showCloseButton:k,status:u,styles:this.styles,title:P}),I.wrapperInPortal),I.wrapperAsChildren)}}]),r})(G.Component);er(lm,"propTypes",{autoOpen:de.bool,callback:de.func,children:de.node,component:nw(de.oneOfType([de.func,de.element]),function(e){return!e.content}),content:nw(de.node,function(e){return!e.component}),debug:de.bool,disableAnimation:de.bool,disableFlip:de.bool,disableHoverToClick:de.bool,event:de.oneOf(["hover","click"]),eventDelay:de.number,footer:de.node,getPopper:de.func,hideArrow:de.bool,id:de.oneOfType([de.string,de.number]),offset:de.number,open:de.bool,options:de.object,placement:de.oneOf(["top","top-start","to
334p-end","bottom","bottom-start","bottom-end","left","left-start","left-end","right","right-start","right-end","auto","center"]),showCloseButton:de.bool,style:de.object,styles:de.object,target:de.oneOfType([de.object,de.string]),title:de.node,wrapperOptions:de.shape({offset:de.number,placement:de.oneOf(["top","top-start","top-end","bottom","bottom-start","bottom-end","left","left-start","left-end","right","right-start","right-end","auto"]),position:de.bool})});er(lm,"defaultProps",{autoOpen:!1,callback:sw,debug:!1,disableAnimation:!1,disableFlip:!1,disableHoverToClick:!1,event:"click",eventDelay:.4,getPopper:sw,hideArrow:!1,offset:15,placement:"bottom",showCloseButton:!1,styles:{},target:null,wrapperOptions:{position:!1}});var kI=Object.defineProperty,TI=(e,t,r)=>t in e?kI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Se=(e,t,r)=>TI(e,typeof t!="symbol"?t+"":t,r),nt={INIT:"init",START:"start",STOP:"stop",RESET:"reset",PREV:"prev",NEXT:"next",GO:"go",CLOSE:"close",SKIP:"skip",UPDATE:"update"},en={TOUR_START:"tour:start",STEP_BEFORE:"step:before",BEACON:"beacon",TOOLTIP:"tooltip",STEP_AFTER:"step:after",TOUR_END:"tour:end",TOUR_STATUS:"tour:status",TARGET_NOT_FOUND:"error:target_not_found"},ze={INIT:"init",READY:"ready",BEACON:"beacon",TOOLTIP:"tooltip",COMPLETE:"complete",ERROR:"error"},He={IDLE:"idle",READY:"ready",WAITING:"waiting",RUNNING:"running",PAUSED:"paused",SKIPPED:"skipped",FINISHED:"finished"};function Ss(){var e;return!!(typeof window<"u"&&((e=window.document)!=null&&e.createElement))}function b_(e){return e?e.getBoundingClientRect():null}function CI(e=!1){const{body:t,documentElement:r}=document;if(!t||!r)return 0;if(e){const n=[t.scrollHeight,t.offsetHeight,r.clientHeight,r.scrollHeight,r.offsetHeight].sort((a,l)=>a-l),i=Math.floor(n.length/2);return n.length%2===0?(n[i-1]+n[i])/2:n[i]}return Math.max(t.scrollHeight,t.offsetHeight,r.clientHeight,r.scrollHeight,r.offsetHeight)}function Hn(e){if(typeof e=="string")try{return document.querySelector(e)}catch{return null}return e}function RI(e){return!e||e.nodeType!==1?null:getComputedStyle(e)}function ul(e,t,r){if(!e)return ho();const n=Gx(e);if(n){if(n.isSameNode(ho()))return r?document:ho();if(!(n.scrollHeight>n.offsetHeight)&&!t)return n.style.overflow="initial",ho()}return n}function Xu(e,t){if(!e)return!1;const r=ul(e,t);return r?!r.isSameNode(ho()):!1}function PI(e){return e.offsetParent!==document.body}function Ui(e,t="fixed"){if(!e||!(e instanceof HTMLElement))return!1;const{nodeName:r}=e,n=RI(e);return r==="BODY"||r==="HTML"?!1:n&&n.position===t?!0:e.parentNode?Ui(e.parentNode,t):!1}function jI(e){var t;if(!e)return!1;let r=e;for(;r&&r!==document.body;){if(r instanceof HTMLElement){const{display:n,visibility:i}=getComputedStyle(r);if(n==="none"||i==="hidden")return!1}r=(t=r.parentElement)!=null?t:null}return!0}function OI(e,t,r){var n,i,a;const l=b_(e),u=ul(e,r),f=Xu(e,r),p=Ui(e);let m=0,g=(n=l==null?void 0:l.top)!=null?n:0;if(f&&p){const b=(i=e==null?void 0:e.offsetTop)!=null?i:0,w=(a=u==null?void 0:u.scrollTop)!=null?a:0;g=b-w}else u instanceof HTMLElement&&(m=u.scrollTop,!f&&!Ui(e)&&(g+=m),u.isSameNode(ho())||(g+=ho().scrollTop));return Math.floor(g-t)}function AI(e,t,r){var n;if(!e)return 0;const{offsetTop:i=0,scrollTop:a=0}=(n=Gx(e))!=null?n:{};let l=e.getBoundingClientRect().top+a;i&&(Xu(e,r)||PI(e))&&(l-=i);const u=Math.floor(l-t);return u<0?0:u}function ho(){var e;return(e=document.scrollingElement)!=null?e:document.documentElement}function NI(e,t){const{duration:r,element:n}=t;return new Promise((i,a)=>{const{scrollTop:l}=n,u=e>l?e-l:l-e;GA.top(n,e,{duration:u<100?50:r},f=>f&&f.message!=="Element already at target scroll position"?a(f):i())})}var qa=Is.createPortal!==void 0;function x_(e=navigator.userAgent){let t=e;return typeof window>"u"?t="node":document.documentMode?t="ie":/Edge/.test(e)?t="edge":window.opera||e.includes(" OPR/")?t="opera":typeof window.InstallTrigger<"u"?t="firefox":window.chrome?t="chrome":/(Version\/([\d._]+).*Safari|CriOS|FxiOS| Mobile\/)/.test(e)&&(t="safari"),t}function mu(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function En(e,t={}){const{defaultValue:r,step:n,steps:i}=t;let a=F0(e);if(a)(a.includes("{step}")||a.includes("{steps}"))&&n&&i&&(a=a.replace("{step}",n.toString()).replace("{steps}",i.toString()));else if(v.isValidElement(e)&&!Object.values(e.props).length&&mu(e.type)==="function"){const l=e.type({});a=En(l,t)}else a=F0(r);return a}function II(e,t){return!_e.plainObject(e)||!_e.array(t)?!1:Object.keys(e).every(r=>t.includes(r))}function LI(e){const t=/^#?([\da-f])([\da-f])([\da-f])$/i,r=e.replace(t,(i,a,l,u)=>a+a+l+l+u+u),n=/^#?([\da-f]{2})([\da-f]{2})([\da-f]{2})$/i.exec(r);return n?[parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16)]:[]}function ow(e){return e.disableBeacon||e.placement==="center"}function iw(){return!["chrome","safari","firefox","opera"].includes(x_())}function So({data:e,debug:t=!1,title:r,warn:n=!1}){const i=n?console.warn||console.error:console.log;t&&(r&&e?(console.groupCollapsed(`%creact-joyride: ${r}`,"color: #ff0044; font-weight: bold; font-size: 12px;"),Array.isArray(e)?e.forEach(a=>{_e.plainObject(a)&&a.key?i.apply(console,[a.key,a.value]):i.apply(console,[a])}):i.apply(console,[e]),console.groupEnd()):console.error("Missing title or data props"))}function DI(e){return Object.keys(e)}function __(e,...t){if(!_e.plainObject(e))throw new TypeError("Expected an object");const r={};for(const n in e)({}).hasOwnProperty.call(e,n)&&(t.includes(n)||(r[n]=e[n]));return r}function MI(e,...t){if(!_e.plainObject(e))throw new TypeError("Expected an object");
334if(!t.length)return e;const r={};for(const n in e)({}).hasOwnProperty.call(e,n)&&t.includes(n)&&(r[n]=e[n]);return r}function jp(e,t,r){const n=a=>a.replace("{step}",String(t)).replace("{steps}",String(r));if(mu(e)==="string")return n(e);if(!v.isValidElement(e))return e;const{children:i}=e.props;if(mu(i)==="string"&&i.includes("{step}"))return v.cloneElement(e,{children:n(i)});if(Array.isArray(i))return v.cloneElement(e,{children:i.map(a=>typeof a=="string"?n(a):jp(a,t,r))});if(mu(e.type)==="function"&&!Object.values(e.props).length){const a=e.type({});return jp(a,t,r)}return e}function $I(e){const{isFirstStep:t,lifecycle:r,previousLifecycle:n,scrollToFirstStep:i,step:a,target:l}=e;return!a.disableScrolling&&(!t||i||r===ze.TOOLTIP)&&a.placement!=="center"&&(!a.isFixed||!Ui(l))&&n!==r&&[ze.BEACON,ze.TOOLTIP].includes(r)}var FI={options:{preventOverflow:{boundariesElement:"scrollParent"}},wrapperOptions:{offset:-18,position:!0}},S_={back:"Back",close:"Close",last:"Last",next:"Next",nextLabelWithProgress:"Next (Step {step} of {steps})",open:"Open the dialog",skip:"Skip"},UI={event:"click",placement:"bottom",offset:10,disableBeacon:!1,disableCloseOnEsc:!1,disableOverlay:!1,disableOverlayClose:!1,disableScrollParentFix:!1,disableScrolling:!1,hideBackButton:!1,hideCloseButton:!1,hideFooter:!1,isFixed:!1,locale:S_,showProgress:!1,showSkipButton:!1,spotlightClicks:!1,spotlightPadding:10},zI={continuous:!1,debug:!1,disableCloseOnEsc:!1,disableOverlay:!1,disableOverlayClose:!1,disableScrolling:!1,disableScrollParentFix:!1,getHelpers:void 0,hideBackButton:!1,run:!0,scrollOffset:20,scrollDuration:300,scrollToFirstStep:!1,showSkipButton:!1,showProgress:!1,spotlightClicks:!1,spotlightPadding:10,steps:[]},BI={arrowColor:"#fff",backgroundColor:"#fff",beaconSize:36,overlayColor:"rgba(0, 0, 0, 0.5)",primaryColor:"#f04",spotlightShadow:"0 0 15px rgba(0, 0, 0, 0.5)",textColor:"#333",width:380,zIndex:100},Va={backgroundColor:"transparent",border:0,borderRadius:0,color:"#555",cursor:"pointer",fontSize:16,lineHeight:1,padding:8,WebkitAppearance:"none"},aw={borderRadius:4,position:"absolute"};function qI(e,t){var r,n,i,a,l;const{floaterProps:u,styles:f}=e,p=tn((r=t.floaterProps)!=null?r:{},u??{}),m=tn(f??{},(n=t.styles)!=null?n:{}),g=tn(BI,m.options||{}),b=t.placement==="center"||t.disableBeacon;let{width:w}=g;window.innerWidth>480&&(w=380),"width"in g&&(w=typeof g.width=="number"&&window.innerWidth<g.width?window.innerWidth-30:g.width);const S={bottom:0,left:0,overflow:"hidden",position:"absolute",right:0,top:0,zIndex:g.zIndex},_={beacon:{...Va,display:b?"none":"inline-block",height:g.beaconSize,position:"relative",width:g.beaconSize,zIndex:g.zIndex},beaconInner:{animation:"joyride-beacon-inner 1.2s infinite ease-in-out",backgroundColor:g.primaryColor,borderRadius:"50%",display:"block",height:"50%",left:"50%",opacity:.7,position:"absolute",top:"50%",transform:"translate(-50%, -50%)",width:"50%"},beaconOuter:{animation:"joyride-beacon-outer 1.2s infinite ease-in-out",backgroundColor:`rgba(${LI(g.primaryColor).join(",")}, 0.2)`,border:`2px solid ${g.primaryColor}`,borderRadius:"50%",boxSizing:"border-box",display:"block",height:"100%",left:0,opacity:.9,position:"absolute",top:0,transformOrigin:"center",width:"100%"},tooltip:{backgroundColor:g.backgroundColor,borderRadius:5,boxSizing:"border-box",color:g.textColor,fontSize:16,maxWidth:"100%",padding:15,position:"relative",width:w},tooltipContainer:{lineHeight:1.4,textAlign:"center"},tooltipTitle:{fontSize:18,margin:0},tooltipContent:{padding:"20px 10px"},tooltipFooter:{alignItems:"center",display:"flex",justifyContent:"flex-end",marginTop:15},tooltipFooterSpacer:{flex:1},buttonNext:{...Va,backgroundColor:g.primaryColor,borderRadius:4,color:"#fff"},buttonBack:{...Va,color:g.primaryColor,marginLeft:"auto",marginRight:5},buttonClose:{...Va,color:g.textColor,height:14,padding:15,position:"absolute",right:0,top:0,width:14},buttonSkip:{...Va,color:g.textColor,fontSize:14},overlay:{...S,backgroundColor:g.overlayColor,mixBlendMode:"hard-light"},overlayLegacy:{...S},overlayLegacyCenter:{...S,backgroundColor:g.overlayColor},spotlight:{...aw,backgroundColor:"gray"},spotlightLegacy:{...aw,boxShadow:`0 0 0 9999px ${g.overlayColor}, ${g.spotlightShadow}`},floaterStyles:{arrow:{color:(l=(a=(i=p==null?void 0:p.styles)==null?void 0:i.arrow)==null?void 0:a.color)!=null?l:g.arrowColor},options:{zIndex:g.zIndex+100}},options:g};return tn(_,m)}function VI(e){return MI(e,"beaconComponent","disableCloseOnEsc","disableOverlay","disableOverlayClose","disableScrolling","disableScrollParentFix","floaterProps","hideBackButton","hideCloseButton","locale","showProgress","showSkipButton","spotlightClicks","spotlightPadding","styles","tooltipComponent")}function di(e,t){var r,n,i,a,l,u;const f=t??{},p=tn.all([UI,VI(e),f],{isMergeableObject:_e.plainObject}),m=qI(e,p),g=Xu(Hn(p.target),p.disableScrollParentFix),b=tn.all([FI,(r=e.floaterProps)!=null?r:{},(n=p.floaterProps)!=null?n:{}]);return b.offset=p.offset,b.styles=tn((i=b.styles)!=null?i:{},m.floaterStyles),b.offset+=(l=(a=e.spotlightPadding)!=null?a:p.spotlightPadding)!=null?l:0,p.placementBeacon&&b.wrapperOptions&&(b.wrapperOptions.placement=p.placementBeacon),g&&b.options.preventOverflow&&(b.options.preventOverflow.boundariesElement="window"),{...p,locale:tn.all([S_,(u=e.locale)!=null?u:{},p.locale||{}]),floaterProps:b,styles:__(m,"floaterStyles")}}function E_(e,t=!1){return _e.plainObject(e)?e.target?!0:(So({title:"validateStep",data:"target is missing from the step",warn:!0,debug:t}),!1):(So({title:"validateStep",data:"step must be an object",warn:!0,debug:t}),!1)}function lw(e,t=!1){return _e.array(e)?e.every(r=>E_(r,t)):(So({title:"validateSteps",data:"steps must be an array",warn:!0,debug:t}),!1)}var k_={action:"init",controlled:!1,index:0,lifecycle:ze.INIT,origin:null,size:0,status:He.IDLE},cw=DI(__(k_,"controlled","size")),WI=class{constructor(e){Se(this,"beaconPopper"),Se(this,"tooltipPopper"),Se(this,"data",new Map),Se(this,"listener"),Se(this,"store",new Map),Se(this,"addListener",i=>{this.listener=i}),Se(this,"setSteps",i=>{const{size:a,status:l}=this.getState(),u={size:i.length,status:l};this.data.set("steps",i),l===He.WAITING&&!a&&i.length&&(u.status=He.RUNNING),this.setState(u)}),Se(this,"getPopper",i=>i==="beacon"?this.beaconPopper:this.tooltipPopper),Se(this,"setPopper",(i,a)=>{i==="beacon"?this.beaconPopper=a:this.tooltipPopper=a}),Se(this,"cleanupPoppers",()=>{this.beaconPopper=null,this.tooltipPopper=null}),Se(this,"close",(i=null)=>{const{index:a,status:l}=this.getState();l===He.RUNNING&&this.setState({...this.getNextState({action:nt.CLOSE,index:a+1,origin:i})})}),Se(this,"go",i=>{const{controlled:a,status:l}=this.getState();if(a||l!==He.RUNNING)return;const u=this.getSteps()[i];this.setState({...this.getNextState({action:nt.GO,index:i}),status:u?l:He.FINISHED})}),Se(this,"info",()=>this.getState()),Se(this,"next",()=>{const{index:i,status:a}=this.getState();a===He.RUNNING&&this.setState(this.getNextState({action:nt.NEXT,index:i+1}))}),Se(this,"open",()=>{const{status:i}=this.getState();i===He.RUNNING&&this.setState({...this.getNextState({action:nt.UPDATE,lifecycle:ze.TOOLTIP})})}),Se(this,"prev",()=>{const{index:i,status:a}=this.getState();a===He.RUNNING&&this.setState({...this.getNextState({action:nt.PREV,index:i-1})})}),Se(this,"reset",(i=!1)=>{const{controlled:a}=this.getState();a||this.setState({...this.getNextState({action:nt.RESET,index:0}),status:i?He.RUNNING:He.READY})}),Se(this,"skip",()=>{const{status:i}=this.getState();i===He.RUNNING&&this.setState({action:nt.SKIP,lifecycle:ze.INIT,status:He.SKIPPED})}),Se(this,"start",i=>{const{index:a,size:l}=this.getState();this.setState({...this.getNextState({action:nt.START,index:_e.number(i)?i:a},!0),status:l?He.RUNNING:He.WAITING})}),Se(this,"stop",(i=!1)=>{const{index:a,status:l}=this.getState();
334[He.FINISHED,He.SKIPPED].includes(l)||this.setState({...this.getNextState({action:nt.STOP,index:a+(i?1:0)}),status:He.PAUSED})}),Se(this,"update",i=>{var a,l;if(!II(i,cw))throw new Error(`State is not valid. Valid keys: ${cw.join(", ")}`);this.setState({...this.getNextState({...this.getState(),...i,action:(a=i.action)!=null?a:nt.UPDATE,origin:(l=i.origin)!=null?l:null},!0)})});const{continuous:t=!1,stepIndex:r,steps:n=[]}=e??{};this.setState({action:nt.INIT,controlled:_e.number(r),continuous:t,index:_e.number(r)?r:0,lifecycle:ze.INIT,origin:null,status:n.length?He.READY:He.IDLE},!0),this.beaconPopper=null,this.tooltipPopper=null,this.listener=null,this.setSteps(n)}getState(){return this.store.size?{action:this.store.get("action")||"",controlled:this.store.get("controlled")||!1,index:parseInt(this.store.get("index"),10),lifecycle:this.store.get("lifecycle")||"",origin:this.store.get("origin")||null,size:this.store.get("size")||0,status:this.store.get("status")||""}:{...k_}}getNextState(e,t=!1){var r,n,i,a,l;const{action:u,controlled:f,index:p,size:m,status:g}=this.getState(),b=_e.number(e.index)?e.index:p,w=f&&!t?p:Math.min(Math.max(b,0),m);return{action:(r=e.action)!=null?r:u,controlled:f,index:w,lifecycle:(n=e.lifecycle)!=null?n:ze.INIT,origin:(i=e.origin)!=null?i:null,size:(a=e.size)!=null?a:m,status:w===m?He.FINISHED:(l=e.status)!=null?l:g}}getSteps(){const e=this.data.get("steps");return Array.isArray(e)?e:[]}hasUpdatedState(e){const t=JSON.stringify(e),r=JSON.stringify(this.getState());return t!==r}setState(e,t=!1){const r=this.getState(),{action:n,index:i,lifecycle:a,origin:l=null,size:u,status:f}={...r,...e};this.store.set("action",n),this.store.set("index",i),this.store.set("lifecycle",a),this.store.set("origin",l),this.store.set("size",u),this.store.set("status",f),t&&(this.store.set("controlled",e.controlled),this.store.set("continuous",e.continuous)),this.listener&&this.hasUpdatedState(r)&&this.listener(this.getState())}getHelpers(){return{close:this.close,go:this.go,info:this.info,next:this.next,open:this.open,prev:this.prev,reset:this.reset,skip:this.skip}}};function HI(e){return new WI(e)}function KI({styles:e}){return v.createElement("div",{key:"JoyrideSpotlight",className:"react-joyride__spotlight","data-test-id":"spotlight",style:e})}var GI=KI,QI=class extends v.Component{constructor(){super(...arguments),Se(this,"isActive",!1),Se(this,"resizeTimeout"),Se(this,"scrollTimeout"),Se(this,"scrollParent"),Se(this,"state",{isScrolling:!1,mouseOverSpotlight:!1,showSpotlight:!0}),Se(this,"hideSpotlight",()=>{const{continuous:e,disableOverlay:t,lifecycle:r}=this.props,n=[ze.INIT,ze.BEACON,ze.COMPLETE,ze.ERROR];return t||(e?n.includes(r):r!==ze.TOOLTIP)}),Se(this,"handleMouseMove",e=>{const{mouseOverSpotlight:t}=this.state,{height:r,left:n,position:i,top:a,width:l}=this.spotlightStyles,u=i==="fixed"?e.clientY:e.pageY,f=i==="fixed"?e.clientX:e.pageX,p=u>=a&&u<=a+r,g=f>=n&&f<=n+l&&p;g!==t&&this.updateState({mouseOverSpotlight:g})}),Se(this,"handleScroll",()=>{const{target:e}=this.props,t=Hn(e);if(this.scrollParent!==document){const{isScrolling:r}=this.state;r||this.updateState({isScrolling:!0,showSpotlight:!1}),clearTimeout(this.scrollTimeout),this.scrollTimeout=window.setTimeout(()=>{this.updateState({isScrolling:!1,showSpotlight:!0})},50)}else Ui(t,"sticky")&&this.updateState({})}),Se(this,"handleResize",()=>{clearTimeout(this.resizeTimeout),this.resizeTimeout=window.setTimeout(()=>{this.isActive&&this.forceUpdate()},100)})}componentDidMount(){const{debug:e,disableScrolling:t,disableScrollParentFix:r=!1,target:n}=this.props,i=Hn(n);this.scrollParent=ul(i??document.body,r,!0),this.isActive=!0,window.addEventListener("resize",this.handleResize)}componentDidUpdate(e){var t;const{disableScrollParentFix:r,lifecycle:n,spotlightClicks:i,target:a}=this.props,{changed:l}=ku(e,this.props);if(l("target")||l("disableScrollParentFix")){const u=Hn(a);this.scrollParent=ul(u??document.body,r,!0)}l("lifecycle",ze.TOOLTIP)&&((t=this.scrollParent)==null||t.addEventListener("scroll",this.handleScroll,{passive:!0}),setTimeout(()=>{const{isScrolling:u}=this.state;u||this.updateState({showSpotlight:!0})},100)),(l("spotlightClicks")||l("disableOverlay")||l("lifecycle"))&&(i&&n===ze.TOOLTIP?window.addEventListener("mousemove",this.handleMouseMove,!1):n!==ze.TOOLTIP&&window.removeEventListener("mousemove",this.handleMouseMove))}componentWillUnmount(){var e;this.isActive=!1,window.removeEventListener("mousemove",this.handleMouseMove),window.removeEventListener("resize",this.handleResize),clearTimeout(this.resizeTimeout),clearTimeout(this.scrollTimeout),(e=this.scrollParent)==null||e.removeEventListener("scroll",this.handleScroll)}
334get overlayStyles(){const{mouseOverSpotlight:e}=this.state,{disableOverlayClose:t,placement:r,styles:n}=this.props;let i=n.overlay;return iw()&&(i=r==="center"?n.overlayLegacyCenter:n.overlayLegacy),{cursor:t?"default":"pointer",height:CI(),pointerEvents:e?"none":"auto",...i}}get spotlightStyles(){var e,t,r;const{showSpotlight:n}=this.state,{disableScrollParentFix:i=!1,spotlightClicks:a,spotlightPadding:l=0,styles:u,target:f}=this.props,p=Hn(f),m=b_(p),g=Ui(p),b=OI(p,l,i);return{...iw()?u.spotlightLegacy:u.spotlight,height:Math.round(((e=m==null?void 0:m.height)!=null?e:0)+l*2),left:Math.round(((t=m==null?void 0:m.left)!=null?t:0)-l),opacity:n?1:0,pointerEvents:a?"none":"auto",position:g?"fixed":"absolute",top:b,transition:"opacity 0.2s",width:Math.round(((r=m==null?void 0:m.width)!=null?r:0)+l*2)}}updateState(e){this.isActive&&this.setState(t=>({...t,...e}))}render(){const{showSpotlight:e}=this.state,{onClickOverlay:t,placement:r}=this.props,{hideSpotlight:n,overlayStyles:i,spotlightStyles:a}=this;if(n())return null;let l=r!=="center"&&e&&v.createElement(GI,{styles:a});if(x_()==="safari"){const{mixBlendMode:u,zIndex:f,...p}=i;l=v.createElement("div",{style:{...p}},l),delete i.backgroundColor}return v.createElement("div",{className:"react-joyride__overlay","data-test-id":"overlay",onClick:t,role:"presentation",style:i},l)}},YI=class extends v.Component{constructor(){super(...arguments),Se(this,"node",null)}componentDidMount(){const{id:e}=this.props;Ss()&&(this.node=document.createElement("div"),this.node.id=e,document.body.appendChild(this.node),qa||this.renderReact15())}componentDidUpdate(){Ss()&&(qa||this.renderReact15())}componentWillUnmount(){!Ss()||!this.node||(qa||Is.unmountComponentAtNode(this.node),this.node.parentNode===document.body&&(document.body.removeChild(this.node),this.node=null))}renderReact15(){if(!Ss())return;const{children:e}=this.props;this.node&&Is.unstable_renderSubtreeIntoContainer(this,e,this.node)}renderReact16(){if(!Ss()||!qa)return null;const{children:e}=this.props;return this.node?Is.createPortal(e,this.node):null}render(){return qa?this.renderReact16():null}},JI=class{constructor(e,t){if(Se(this,"element"),Se(this,"options"),Se(this,"canBeTabbed",r=>{const{tabIndex:n}=r;return n===null||n<0?!1:this.canHaveFocus(r)}),Se(this,"canHaveFocus",r=>{const n=/input|select|textarea|button|object/,i=r.nodeName.toLowerCase();return(n.test(i)&&!r.getAttribute("disabled")||i==="a"&&!!r.getAttribute("href"))&&this.isVisible(r)}),Se(this,"findValidTabElements",()=>[].slice.call(this.element.querySelectorAll("*"),0).filter(this.canBeTabbed)),Se(this,"handleKeyDown",r=>{const{code:n="Tab"}=this.options;r.code===n&&this.interceptTab(r)}),Se(this,"interceptTab",r=>{r.preventDefault();const n=this.findValidTabElements(),{shiftKey:i}=r;if(!n.length)return;let a=document.activeElement?n.indexOf(document.activeElement):0;a===-1||!i&&a+1===n.length?a=0:i&&a===0?a=n.length-1:a+=i?-1:1,n[a].focus()}),Se(this,"isHidden",r=>{const n=r.offsetWidth<=0&&r.offsetHeight<=0,i=window.getComputedStyle(r);return n&&!r.innerHTML?!0:n&&i.getPropertyValue("overflow")!=="visible"||i.getPropertyValue("display")==="none"}),Se(this,"isVisible",r=>{let n=r;for(;n;)if(n instanceof HTMLElement){if(n===document.body)break;if(this.isHidden(n))return!1;n=n.parentNode}return!0}),Se(this,"removeScope",()=>{window.removeEventListener("keydown",this.handleKeyDown)}),Se(this,"checkFocus",r=>{document.activeElement!==r&&(r.focus(),window.requestAnimationFrame(()=>this.checkFocus(r)))}),Se(this,"setFocus",()=>{const{selector:r}=this.options;if(!r)return;const n=this.element.querySelector(r);n&&window.requestAnimationFrame(()=>this.checkFocus(n))}),!(e instanceof HTMLElement))throw new TypeError("Invalid parameter: element must be an HTMLElement");this.element=e,this.options=t,window.addEventListener("keydown",this.handleKeyDown,!1),this.setFocus()}},XI=class extends v.Component{constructor(e){if(super(e),Se(this,"beacon",null),Se(this,"setBeaconRef",i=>{this.beacon=i}),e.beaconComponent)return;const t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.id="joyride-beacon-animation",e.nonce&&r.setAttribute("nonce",e.nonce),r.appendChild(document.createTextNode(`
335        @keyframes joyride-beacon-inner {
336          20% {
337            opacity: 0.9;
338          }
339        
340          90% {
341            opacity: 0.7;
342          }
343        }
344        
345        @keyframes joyride-beacon-outer {
346          0% {
347            transform: scale(1);
348          }
349        
350          45% {
351            opacity: 0.7;
352            transform: scale(0.75);
353          }
354        
355          100% {
356            opacity: 0.9;
357            transform: scale(1);
358          }
359        }
360      `)),t.appendChild(r)}componentDidMount(){const{shouldFocus:e}=this.props;setTimeout(()=>{_e.domElement(this.beacon)&&e&&this.beacon.focus()},0)}componentWillUnmount(){const e=document.getElementById("joyride-beacon-animation");e!=null&&e.parentNode&&e.parentNode.removeChild(e)}render(){const{beaconComponent:e,continuous:t,index:r,isLastStep:n,locale:i,onClickOrHover:a,size:l,step:u,styles:f}=this.props,p=En(i.open),m={"aria-label":p,onClick:a,onMouseEnter:a,ref:this.setBeaconRef,title:p};let g;if(e){const b=e;g=v.createElement(b,{continuous:t,index:r,isLastStep:n,size:l,step:u,...m})}else g=v.createElement("button",{key:"JoyrideBeacon",className:"react-joyride__beacon","data-test-id":"button-beacon",style:f.beacon,type:"button",...m},v.createElement("span",{style:f.beaconInner}),v.createElement("span",{style:f.beaconOuter}));return g}};function ZI({styles:e,...t}){const{color:r,height:n,width:i,...a}=e;return G.createElement("button",{style:a,type:"button",...t},G.createElement("svg",{height:typeof n=="number"?`${n}px`:n,preserveAspectRatio:"xMidYMid",version:"1.1",viewBox:"0 0 18 18",width:typeof i=="number"?`${i}px`:i,xmlns:"http://www.w3.org/2000/svg"},G.createElement("g",null,G.createElement("path",{d:"M8.13911129,9.00268191 L0.171521827,17.0258467 C-0.0498027049,17.248715 -0.0498027049,17.6098394 0.171521827,17.8327545 C0.28204354,17.9443526 0.427188206,17.9998706 0.572051765,17.9998706 C0.71714958,17.9998706 0.862013139,17.9443526 0.972581703,17.8327545 L9.0000937,9.74924618 L17.0276057,17.8327545 C17.1384085,17.9443526 17.2832721,17.9998706 17.4281356,17.9998706 C17.5729992,17.9998706 17.718097,17.9443526 17.8286656,17.8327545 C18.0499901,17.6098862 18.0499901,17.2487618 17.8286656,17.0258467 L9.86135722,9.00268191 L17.8340066,0.973848225 C18.0553311,0.750979934 18.0553311,0.389855532 17.8340066,0.16694039 C17.6126821,-0.0556467968 17.254037,-0.0556467968 17.0329467,0.16694039 L9.00042166,8.25611765 L0.967006424,0.167268345 C0.745681892,-0.0553188426 0.387317931,-0.0553188426 0.165993399,0.167268345 C-0.0553311331,0.390136635 -0.0553311331,0.751261038 0.165993399,0.974176179 L8.13920499,9.00268191 L8.13911129,9.00268191 Z",fill:r}))))}var e2=ZI;function t2(e){const{backProps:t,closeProps:r,index:n,isLastStep:i,primaryProps:a,skipProps:l,step:u,tooltipProps:f}=e,{content:p,hideBackButton:m,hideCloseButton:g,hideFooter:b,showSkipButton:w,styles:S,title:_}=u,E={};return E.primary=v.createElement("button",{"data-test-id":"button-primary",style:S.buttonNext,type:"button",...a}),w&&!i&&(E.skip=v.createElement("button",{"aria-live":"off","data-test-id":"button-skip",style:S.buttonSkip,type:"button",...l})),!m&&n>0&&(E.back=v.createElement("button",{"data-test-id":"button-back",style:S.buttonBack,type:"button",...t})),E.close=!g&&v.createElement(e2,{"data-test-id":"button-close",styles:S.buttonClose,...r}),v.createElement("div",{key:"JoyrideTooltip","aria-label":En(_??p),className:"react-joyride__tooltip",style:S.tooltip,...f},v.createElement("div",{style:S.tooltipContainer},_&&v.createElement("h1",{"aria-label":En(_),style:S.tooltipTitle},_),v.createElement("div",{style:S.tooltipContent},p)),!b&&v.createElement("div",{style:S.tooltipFooter},v.createElement("div",{style:S.tooltipFooterSpacer},E.skip),E.back,E.primary),E.close)}var r2=t2,n2=class extends v.Component{constructor(){super(...arguments),Se(this,"handleClickBack",e=>{e.preventDefault();const{helpers:t}=this.props;t.prev()}),Se(this,"handleClickClose",e=>{e.preventDefault();const{helpers:t}=this.props;t.close("button_close")}),Se(this,"handleClickPrimary",e=>{e.preventDefault();const{continuous:t,helpers:r}=this.props;if(!t){r.close("button_primary");return}r.next()}),Se(this,"handleClickSkip",e=>{e.preventDefault();const{helpers:t}=this.props;t.skip()}),Se(this,"getElementsProps",()=>{const{continuous:e,index:t,isLastStep:r,setTooltipRef:n,size:i,step:a}=this.props,{back:l,close:u,last:f,next:p,nextLabelWithProgress:m,skip:g}=a.locale,b=En(l),w=En(u),S=En(f),_=En(p),E=En(g);let k=u,T=w;if(e){if(k=p,T=_,a.showProgress&&!r){const R=En(m,{step:t+1,steps:i});k=jp(m,t+1,i),T=R}r&&(k=f,T=S)}return{backProps:{"aria-label":b,children:l,"data-action":"back",onClick:this.handleClickBack,role:"button",title:b},closeProps:{"aria-label":w,children:u,"data-action":"close",onClick:this.handleClickClose,role:"button",title:w},primaryProps:{"aria-label":T,children:k,"data-action":"primary",onClick:this.handleClickPrimary,role:"button",title:T},skipProps:{"aria-label":E,children:g,"data-action":"skip",onClick:this.handleClickSkip,role:"button",title:E},tooltipProps:{"aria-modal":!0,ref:n,role:"alertdialog"}}})}render(){const{continuous:e,index:t,isLastStep:r,setTooltipRef:n,size:i,step:a}=this.props,{beaconComponent:l,tooltipComponent:u,...f}=a;let p;if(u){const m={...this.getElementsProps(),continuous:e,index:t,isLastStep:r,size:i,step:f,setTooltipRef:n},g=u;p=v.createElement(g,{...m})}else p=v.createElement(r2,{...this.getElementsProps(),continuous:e,index:t,isLastStep:r,size:i,step:a});return p}},s2=class extends v.Component{constructor(){super(...arguments),Se(this,"scope",null),Se(this,"tooltip",null),Se(this,"handleClickHoverBeacon",e=>
360{const{step:t,store:r}=this.props;e.type==="mouseenter"&&t.event!=="hover"||r.update({lifecycle:ze.TOOLTIP})}),Se(this,"setTooltipRef",e=>{this.tooltip=e}),Se(this,"setPopper",(e,t)=>{var r;const{action:n,lifecycle:i,step:a,store:l}=this.props;t==="wrapper"?l.setPopper("beacon",e):l.setPopper("tooltip",e),l.getPopper("beacon")&&(l.getPopper("tooltip")||a.placement==="center")&&i===ze.INIT&&l.update({action:n,lifecycle:ze.READY}),(r=a.floaterProps)!=null&&r.getPopper&&a.floaterProps.getPopper(e,t)}),Se(this,"renderTooltip",e=>{const{continuous:t,helpers:r,index:n,size:i,step:a}=this.props;return v.createElement(n2,{continuous:t,helpers:r,index:n,isLastStep:n+1===i,setTooltipRef:this.setTooltipRef,size:i,step:a,...e})})}componentDidMount(){const{debug:e,index:t}=this.props;So({title:`step:${t}`,data:[{key:"props",value:this.props}],debug:e})}componentDidUpdate(e){var t;const{action:r,callback:n,continuous:i,controlled:a,debug:l,helpers:u,index:f,lifecycle:p,shouldScroll:m,status:g,step:b,store:w}=this.props,{changed:S,changedFrom:_}=ku(e,this.props),E=u.info(),k=i&&r!==nt.CLOSE&&(f>0||r===nt.PREV),T=S("action")||S("index")||S("lifecycle")||S("status"),R=_("lifecycle",[ze.TOOLTIP,ze.INIT],ze.INIT),P=S("action",[nt.NEXT,nt.PREV,nt.SKIP,nt.CLOSE]),O=a&&f===e.index;if(P&&(R||O)&&n({...E,index:e.index,lifecycle:ze.COMPLETE,step:e.step,type:en.STEP_AFTER}),b.placement==="center"&&g===He.RUNNING&&S("index")&&r!==nt.START&&p===ze.INIT&&w.update({lifecycle:ze.READY}),T){const I=Hn(b.target),M=!!I;M&&jI(I)?(_("status",He.READY,He.RUNNING)||_("lifecycle",ze.INIT,ze.READY))&&n({...E,step:b,type:en.STEP_BEFORE}):(console.warn(M?"Target not visible":"Target not mounted",b),n({...E,type:en.TARGET_NOT_FOUND,step:b}),a||w.update({index:f+(r===nt.PREV?-1:1)}))}_("lifecycle",ze.INIT,ze.READY)&&w.update({lifecycle:ow(b)||k?ze.TOOLTIP:ze.BEACON}),S("index")&&So({title:`step:${p}`,data:[{key:"props",value:this.props}],debug:l}),S("lifecycle",ze.BEACON)&&n({...E,step:b,type:en.BEACON}),S("lifecycle",ze.TOOLTIP)&&(n({...E,step:b,type:en.TOOLTIP}),m&&this.tooltip&&(this.scope=new JI(this.tooltip,{selector:"[data-action=primary]"}),this.scope.setFocus())),_("lifecycle",[ze.TOOLTIP,ze.INIT],ze.INIT)&&((t=this.scope)==null||t.removeScope(),w.cleanupPoppers())}componentWillUnmount(){var e;(e=this.scope)==null||e.removeScope()}get open(){const{lifecycle:e,step:t}=this.props;return ow(t)||e===ze.TOOLTIP}render(){const{continuous:e,debug:t,index:r,nonce:n,shouldScroll:i,size:a,step:l}=this.props,u=Hn(l.target);return!E_(l)||!_e.domElement(u)?null:v.createElement("div",{key:`JoyrideStep-${r}`,className:"react-joyride__step"},v.createElement(lm,{...l.floaterProps,component:this.renderTooltip,debug:t,getPopper:this.setPopper,id:`react-joyride-step-${r}`,open:this.open,placement:l.placement,target:l.target},v.createElement(XI,{beaconComponent:l.beaconComponent,continuous:e,index:r,isLastStep:r+1===a,locale:l.locale,nonce:n,onClickOrHover:this.handleClickHoverBeacon,shouldFocus:i,size:a,step:l,styles:l.styles})))}},T_=class extends v.Component{constructor(e){super(e),Se(this,"helpers"),Se(this,"store"),Se(this,"callback",l=>{const{callback:u}=this.props;_e.function(u)&&u(l)}),Se(this,"handleKeyboard",l=>{const{index:u,lifecycle:f}=this.state,{steps:p}=this.props,m=p[u];f===ze.TOOLTIP&&l.code==="Escape"&&m&&!m.disableCloseOnEsc&&this.store.close("keyboard")}),Se(this,"handleClickOverlay",()=>{const{index:l}=this.state,{steps:u}=this.props;di(this.props,u[l]).disableOverlayClose||this.helpers.close("overlay")}),Se(this,"syncState",l=>{this.setState(l)});const{debug:t,getHelpers:r,run:n=!0,stepIndex:i}=e;this.store=HI({...e,controlled:n&&_e.number(i)}),this.helpers=this.store.getHelpers();const{addListener:a}=this.store;So({title:"init",data:[{key:"props",value:this.props},{key:"state",value:this.state}],debug:t}),a(this.syncState),r&&r(this.helpers),this.state=this.store.getState()}componentDidMount(){if(!Ss())return;const{debug:e,disableCloseOnEsc:t,run:r,steps:n}=this.props,{start:i}=this.store;lw(n,e)&&r&&i(),t||document.body.addEventListener("keydown",this.handleKeyboard,{passive:!0})}componentDidUpdate(e,t){if(!Ss())return;const{action:r,controlled:n,index:i,status:a}=this.state,{debug:l,run:u,stepIndex:f,steps:p}=this.props,{stepIndex:m,steps:g}=e,{reset:b,setSteps:w,start:S,stop:_,update:E}=this.store,{changed:k}=ku(e,this.props),{changed:T,changedFrom:R}=ku(t,this.state),P=di(this.props,p[i]),O=!ir(g,p),I=_e.number(f)&&k("stepIndex"),M=Hn(P.target);if(O&&(lw(p,l)?w(p):console.warn("Steps are not valid",p)),k("run")&&(u?S(f):_()),I){let he=_e.number(m)&&m<f?nt.NEXT:nt.PREV;
360r===nt.STOP&&(he=nt.START),[He.FINISHED,He.SKIPPED].includes(a)||E({action:r===nt.CLOSE?nt.CLOSE:he,index:f,lifecycle:ze.INIT})}!n&&a===He.RUNNING&&i===0&&!M&&(this.store.update({index:i+1}),this.callback({...this.state,type:en.TARGET_NOT_FOUND,step:P}));const Y={...this.state,index:i,step:P};if(T("action",[nt.NEXT,nt.PREV,nt.SKIP,nt.CLOSE])&&T("status",He.PAUSED)){const he=di(this.props,p[t.index]);this.callback({...Y,index:t.index,lifecycle:ze.COMPLETE,step:he,type:en.STEP_AFTER})}if(T("status",[He.FINISHED,He.SKIPPED])){const he=di(this.props,p[t.index]);n||this.callback({...Y,index:t.index,lifecycle:ze.COMPLETE,step:he,type:en.STEP_AFTER}),this.callback({...Y,type:en.TOUR_END,step:he,index:t.index}),b()}else R("status",[He.IDLE,He.READY],He.RUNNING)?this.callback({...Y,type:en.TOUR_START}):(T("status")||T("action",nt.RESET))&&this.callback({...Y,type:en.TOUR_STATUS});this.scrollToStep(t)}componentWillUnmount(){const{disableCloseOnEsc:e}=this.props;e||document.body.removeEventListener("keydown",this.handleKeyboard)}scrollToStep(e){const{index:t,lifecycle:r,status:n}=this.state,{debug:i,disableScrollParentFix:a=!1,scrollDuration:l,scrollOffset:u=20,scrollToFirstStep:f=!1,steps:p}=this.props,m=di(this.props,p[t]),g=Hn(m.target),b=$I({isFirstStep:t===0,lifecycle:r,previousLifecycle:e.lifecycle,scrollToFirstStep:f,step:m,target:g});if(n===He.RUNNING&&b){const w=Xu(g,a),S=ul(g,a);let _=Math.floor(AI(g,u,a))||0;So({title:"scrollToStep",data:[{key:"index",value:t},{key:"lifecycle",value:r},{key:"status",value:n}],debug:i});const E=this.store.getPopper("beacon"),k=this.store.getPopper("tooltip");if(r===ze.BEACON&&E){const{offsets:T,placement:R}=E;!["bottom"].includes(R)&&!w&&(_=Math.floor(T.popper.top-u))}else if(r===ze.TOOLTIP&&k){const{flipped:T,offsets:R,placement:P}=k;["top","right","left"].includes(P)&&!T&&!w?_=Math.floor(R.popper.top-u):_-=m.spotlightPadding}_=_>=0?_:0,n===He.RUNNING&&NI(_,{element:S,duration:l}).then(()=>{setTimeout(()=>{var T;(T=this.store.getPopper("tooltip"))==null||T.instance.update()},10)})}}render(){if(!Ss())return null;const{index:e,lifecycle:t,status:r}=this.state,{continuous:n=!1,debug:i=!1,nonce:a,scrollToFirstStep:l=!1,steps:u}=this.props,f=r===He.RUNNING,p={};if(f&&u[e]){const m=di(this.props,u[e]);p.step=v.createElement(s2,{...this.state,callback:this.callback,continuous:n,debug:i,helpers:this.helpers,nonce:a,shouldScroll:!m.disableScrolling&&(e!==0||l),step:m,store:this.store}),p.overlay=v.createElement(YI,{id:"react-joyride-portal"},v.createElement(QI,{...m,continuous:n,debug:i,lifecycle:t,onClickOverlay:this.handleClickOverlay}))}return v.createElement("div",{className:"react-joyride"},p.step,p.overlay)}};Se(T_,"defaultProps",zI);var o2=T_;const Th=[{target:"#dashboard-overview",content:"Your dashboard is your home base! Here you'll find a snapshot of your pods, sprints, and pending actions. Think of it as your control center—everything you need at a glance.",placement:"bottom",disableBeacon:!0},{target:"#ei-score-card",content:"Track your professional growth with your Signal Score. This shows your progress across technical skills, soft skills, and project experience.",placement:"bottom"},{target:"#notifications-icon",content:"Your notification center keeps you informed about activities that matter most—new assignments, pod updates, and important announcements.",placement:"bottom-start"},{target:"#active-pods",content:"View and manage your current pod assignments. See progress, recruiting status, and jump directly into your work.",placement:"top"},{target:"#upcoming-events",content:"Keep track of upcoming events, meetings, and deadlines. Never miss an important session or sprint review!",placement:"top"}],i2=[{target:"#profile-picture",content:"Your profile is how the community knows you. Update your profile picture to make it personal and help others recognize you.",placement:"right",disableBeacon:!0},{target:"#edit-profile-button",content:"Use the Edit Profile button to update your bio, contact details, and other personal information. A complete profile builds credibility.",placement:"bottom"},{target:"#tech-stacks-section",content:"Showcase your tech stack and skills to highlight your expertise. This helps you get matched with the right opportunities.",placement:"top"},{target:"#links-section",content:"Add your portfolio, GitHub, and LinkedIn links so others can connect with you and see your work. These links are essential for networking.",placement:"top"}],a2=[{target:"#pod-search",content:"Pods are where collaboration happens! Search for pods by keywords, skills, or categories to find projects that interest you.",placement:"bottom",disableBeacon:!0},{target:"#pod-difficulty-filter",content:"Filter pods by difficulty level to find projects that match your current skill level and learning goals.",placement:"bottom"},{target:"#recommended-pods-tab",content:"Switch between recommended pods (matched to your career path) and all available pods to explore different opportunities.",placement:"bottom"},{target:"#available-pods-grid",content:`This is where you'll find pods to join! Complete your profile to get personalized recommendations, or switch to "All Pods" to browse everything available.`,placement:"top"},{target:"#apply-to-pod",content:"Apply to join pods that interest you. You can write a motivation letter explaining why you want to join the project.",placement:"top"},{target:"#pending-applications-section",content:"Check pending applications to track y
360our status. You can withdraw applications if your interests change.",placement:"bottom"},{target:"#my-active-pods",content:"Access active pods once you're accepted and start collaborating. Pods are your teamwork hubs—where learning and building happen together.",placement:"bottom"}],l2=[{target:"#pods-page-header",content:"Sprint boards are where you collaborate with your pod team. They help you track tasks, manage progress, and work together effectively.",placement:"bottom",disableBeacon:!0},{target:"#active-pods-section",content:"Once you join a pod, you'll access sprint boards to see your assigned tasks and move them through different stages.",placement:"bottom"},{target:"#pod-search-filter",content:"Find and apply to pods that match your skills and interests. Each pod has its own sprint board for project management.",placement:"top"},{target:"#available-pods-grid",content:"Sprint boards contain tickets assigned to you, which you can comment on, update, and move to review once completed.",placement:"top"}],c2=[{target:"#skill-tracker-header",content:"Welcome to your Signal Score Tracker! This is where you can monitor your performance and find ways to improve.",placement:"bottom",disableBeacon:!0},{target:"#skill-tracker-tabs",content:"Use these tabs to explore different views: Overview for a summary, Timeline for history, Activity for recent events, Impacts to understand scoring, and Improve for personalized tips.",placement:"bottom"},{target:"#score-components-card",content:"Your score is built from three components: Technical Skills (40%), Engagement (30%), and Collaboration (30%). Each section shows your current points.",placement:"left"},{target:"#score-bands-section",content:"See where you stand in the score bands - from Beginner to Elite. Complete activities to progress to higher bands!",placement:"top"}],u2=[{target:"#learning-hub-header",content:"The Learning Hub is your built-in learning assistant.",placement:"bottom",disableBeacon:!0},{target:"#learning-projects-tab",content:"My Projects: View your assigned projects and generate learning recommendations based on project requirements.",placement:"bottom"},{target:"#learning-recommendations-tab",content:"Task-Based Recommendations: Get resources suggested based on the tickets or skills you're working on.",placement:"bottom"},{target:"#custom-search-tab",content:"Custom Search: Search for tutorials and guides related to any topic you want to learn.",placement:"bottom"},{target:"#learning-hub-content",content:"No more getting stuck—you'll always have the right resources at your fingertips. As you take on new tasks, the hub evolves to match your learning journey.",placement:"top"}];var d2=Fu[" useId ".trim().toString()]||(()=>{}),f2=0;function gu(e){const[t,r]=v.useState(d2());return Fr(()=>{r(n=>n??String(f2++))},[e]),e||(t?`radix-${t}`:"")}var Ch="focusScope.autoFocusOnMount",Rh="focusScope.autoFocusOnUnmount",uw={bubbles:!1,cancelable:!0},h2="FocusScope",C_=v.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...l}=e,[u,f]=v.useState(null),p=rn(i),m=rn(a),g=v.useRef(null),b=Gt(t,_=>f(_)),w=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect(()=>{if(n){let _=function(R){if(w.paused||!u)return;const P=R.target;u.contains(P)?g.current=P:bs(g.current,{select:!0})},E=function(R){if(w.paused||!u)return;const P=R.relatedTarget;P!==null&&(u.contains(P)||bs(g.current,{select:!0}))},k=function(R){if(document.activeElement===document.body)for(const O of R)O.removedNodes.length>0&&bs(u)};document.addEventListener("focusin",_),document.addEventListener("focusout",E);const T=new MutationObserver(k);return u&&T.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",_),document.removeEventListener("focusout",E),T.disconnect()}}},[n,u,w.paused]),v.useEffect(()=>{if(u){fw.add(w);const _=document.activeElement;if(!u.contains(_)){const k=new CustomEvent(Ch,uw);u.addEventListener(Ch,p),u.dispatchEvent(k),k.defaultPrevented||(p2(w2(R_(u)),{select:!0}),document.activeElement===_&&bs(u))}return()=>{u.removeEventListener(Ch,p),setTimeout(()=>{const k=new CustomEvent(Rh,uw);u.addEventListener(Rh,m),u.dispatchEvent(k),k.defaultPrevented||bs(_??document.body,{select:!0}),u.removeEventListener(Rh,m),fw.remove(w)},0)}}},[u,p,m,w]);const S=v.useCallback(_=>{if(!r&&!n||w.paused)return;const E=_.key==="Tab"&&!_.altKey&&!_.ctrlKey&&!_.metaKey,k=document.activeElement;if(E&&k){const T=_.currentTarget,[R,P]=m2(T);R&&P?!_.shiftKey&&k===P?(_.preventDefault(),r&&bs(R,{select:!0})):_.shiftKey&&k===R&&(_.preventDefault(),r&&bs(P,{select:!0})):k===T&&_.preventDefault()}},[r,n,w.paused]);return d.jsx(xt.div,{tabIndex:-1,...l,ref:b,onKeyDown:S})});C_.displayName=h2;function p2(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(bs(n,{select:t}),document.activeElement!==r)return}function m2(e){const t=R_(e),r=dw(t,e),n=dw(t.reverse(),e);return[r,n]}function R_(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const i=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||i?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function dw(e,t){for(const r of e)if(!g2(r,{upTo:t}))return r}function g2(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function v2(e){return e instanceof HTMLInputElement&&"select"in e}function bs(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&v2(e)&&t&&e.select()}}
vendor: 1,504 bytes, line 360
360var fw=y2();function y2(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=hw(e,t),e.unshift(t)},remove(t){var r;e=hw(e,t),(r=e[0])==null||r.resume()}}}function hw(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function w2(e){return e.filter(t=>t.tagName!=="A")}var Ph=0;function b2(){v.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??pw()),document.body.insertAdjacentElement("beforeend",e[1]??pw()),Ph++,()=>{Ph===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Ph--}},[])}function pw(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var vu="right-scroll-bar-position",yu="width-before-scroll-bar",x2="with-scroll-bars-hidden",_2="--removed-body-scroll-bar-size";function jh(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function S2(e,t){var r=v.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var i=r.value;i!==n&&(r.value=n,r.callback(n,i))}}}})[0];return r.callback=t,r.facade}var E2=typeof window<"u"?v.useLayoutEffect:v.useEffect,mw=new WeakMap;function k2(e,t){var r=S2(null,function(n){return e.forEach(function(i){return jh(i,n)})});return E2(function(){var n=mw.get(r);if(n){var i=new Set(n),a=new Set(e),l=r.current;
vendor: 4,196 bytes, lines 360-375
360i.forEach(function(u){a.has(u)||jh(u,null)}),a.forEach(function(u){i.has(u)||jh(u,l)})}mw.set(r,e)},[e]),r}function T2(e){return e}function C2(e,t){t===void 0&&(t=T2);var r=[],n=!1,i={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(a){var l=t(a,n);return r.push(l),function(){r=r.filter(function(u){return u!==l})}},assignSyncMedium:function(a){for(n=!0;r.length;){var l=r;r=[],l.forEach(a)}r={push:function(u){return a(u)},filter:function(){return r}}},assignMedium:function(a){n=!0;var l=[];if(r.length){var u=r;r=[],u.forEach(a),l=r}var f=function(){var m=l;l=[],m.forEach(a)},p=function(){return Promise.resolve().then(f)};p(),r={push:function(m){l.push(m),p()},filter:function(m){return l=l.filter(m),r}}}};return i}function R2(e){e===void 0&&(e={});var t=C2(null);return t.options=kn({async:!0,ssr:!1},e),t}var P_=function(e){var t=e.sideCar,r=Hi(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return v.createElement(n,kn({},r))};P_.isSideCarExport=!0;function P2(e,t){return e.useMedium(t),P_}var j_=R2(),Oh=function(){},Zu=v.forwardRef(function(e,t){var r=v.useRef(null),n=v.useState({onScrollCapture:Oh,onWheelCapture:Oh,onTouchMoveCapture:Oh}),i=n[0],a=n[1],l=e.forwardProps,u=e.children,f=e.className,p=e.removeScrollBar,m=e.enabled,g=e.shards,b=e.sideCar,w=e.noRelative,S=e.noIsolation,_=e.inert,E=e.allowPinchZoom,k=e.as,T=k===void 0?"div":k,R=e.gapMode,P=Hi(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),O=b,I=k2([r,t]),M=kn(kn({},P),i);return v.createElement(v.Fragment,null,m&&v.createElement(O,{sideCar:j_,removeScrollBar:p,shards:g,noRelative:w,noIsolation:S,inert:_,setCallbacks:a,allowPinchZoom:!!E,lockRef:r,gapMode:R}),l?v.cloneElement(v.Children.only(u),kn(kn({},M),{ref:I})):v.createElement(T,kn({},M,{className:f,ref:I}),u))});Zu.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Zu.classNames={fullWidth:yu,zeroRight:vu};var j2=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function O2(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=j2();return t&&e.setAttribute("nonce",t),e}function A2(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function N2(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var I2=function(){var e=0,t=null;return{add:function(r){e==0&&(t=O2())&&(A2(t,r),N2(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},L2=function(){var e=I2();return function(t,r){v.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},O_=function(){var e=L2(),t=function(r){var n=r.styles,i=r.dynamic;return e(n,i),null};return t},D2={left:0,top:0,right:0,gap:0},Ah=function(e){return parseInt(e||"",10)||0},M2=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[Ah(r),Ah(n),Ah(i)]},$2=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return D2;var t=M2(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},F2=O_(),_i="data-scroll-locked",U2=function(e,t,r,n){var i=e.left,a=e.top,l=e.right,u=e.gap;return r===void 0&&(r="margin"),`
361  .`.concat(x2,` {
362   overflow: hidden `).concat(n,`;
363   padding-right: `).concat(u,"px ").concat(n,`;
364  }
365  body[`).concat(_i,`] {
366    overflow: hidden `).concat(n,`;
367    overscroll-behavior: contain;
368    `).concat([t&&"position: relative ".concat(n,";"),r==="margin"&&`
369    padding-left: `.concat(i,`px;
370    padding-top: `).concat(a,`px;
371    padding-right: `).concat(l,`px;
372    margin-left:0;
373    margin-top:0;
374    margin-right: `).concat(u,"px ").concat(n,`;
375    `),r==="padding"&&"padding-right: ".concat(u,"px ").concat(n,";
375")].filter(Boolean).join(""),`
376  }
377  
378  .`).concat(vu,` {
379    right: `).concat(u,"px ").concat(n,`;
380  }
381  
382  .`).concat(yu,` {
383    margin-right: `).concat(u,"px ").concat(n,`;
384  }
385  
386  .`).concat(vu," .").concat(vu,` {
387    right: 0 `).concat(n,`;
388  }
389  
390  .`).concat(yu," .").concat(yu,` {
391    margin-right: 0 `).concat(n,`;
392  }
393  
394  body[`).concat(_i,`] {
395    `).concat(_2,": ").concat(u,`px;
396  }
397`)},gw=function(){var e=parseInt(document.body.getAttribute(_i)||"0",10);return isFinite(e)?e:0},z2=function(){v.useEffect(function(){return document.body.setAttribute(_i,(gw()+1).toString()),function(){var e=gw()-1;e<=0?document.body.removeAttribute(_i):document.body.setAttribute(_i,e.toString())}},[])},B2=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,i=n===void 0?"margin":n;z2();var a=v.useMemo(function(){return $2(i)},[i]);return v.createElement(F2,{styles:U2(a,!t,i,r?"":"!important")})},Op=!1;if(typeof window<"u")try{var nu=Object.defineProperty({},"passive",{get:function(){return Op=!0,!0}});window.addEventListener("test",nu,nu),window.removeEventListener("test",nu,nu)}catch{Op=!1}var fi=Op?{passive:!1}:!1,q2=function(e){return e.tagName==="TEXTAREA"},A_=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!q2(e)&&r[t]==="visible")},V2=function(e){return A_(e,"overflowY")},W2=function(e){return A_(e,"overflowX")},vw=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var i=N_(e,n);if(i){var a=I_(e,n),l=a[1],u=a[2];if(l>u)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},H2=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},K2=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},N_=function(e,t){return e==="v"?V2(t):W2(t)},I_=function(e,t){return e==="v"?H2(t):K2(t)},G2=function(e,t){return e==="h"&&t==="rtl"?-1:1},Q2=function(e,t,r,n,i){var a=G2(e,window.getComputedStyle(t).direction),l=a*n,u=r.target,f=t.contains(u),p=!1,m=l>0,g=0,b=0;do{if(!u)break;var w=I_(e,u),S=w[0],_=w[1],E=w[2],k=_-E-a*S;(S||k)&&N_(e,u)&&(g+=k,b+=S);var T=u.parentNode;u=T&&T.nodeType===Node.DOCUMENT_FRAGMENT_NODE?T.host:T}while(!f&&u!==document.body||f&&(t.contains(u)||t===u));return(m&&Math.abs(g)<1||!m&&Math.abs(b)<1)&&(p=!0),p},su=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},yw=function(e){return[e.deltaX,e.deltaY]},ww=function(e){return e&&"current"in e?e.current:e},Y2=function(e,t){return e[0]===t[0]&&e[1]===t[1]},J2=function(e){return`
398  .block-interactivity-`.concat(e,` {pointer-events: none;}
399  .allow-interactivity-`).concat(e,` {pointer-events: all;}
400`)},X2=0,hi=[];function Z2(e){var t=v.useRef([]),r=v.useRef([0,0]),n=v.useRef(),i=v.useState(X2++)[0],a=v.useState(O_)[0],l=v.useRef(e);v.useEffect(function(){l.current=e},[e]),v.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var _=XP([e.lockRef.current],(e.shards||[]).map(ww),!0).filter(Boolean);return _.forEach(function(E){return E.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),_.forEach(function(E){return E.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var u=v.useCallback(function(_,E){if("touches"in _&&_.touches.length===2||_.type==="wheel"&&_.ctrlKey)return!l.current.allowPinchZoom;var k=su(_),T=r.current,R="deltaX"in _?_.deltaX:T[0]-k[0],P="deltaY"in _?_.deltaY:T[1]-k[1],O,I=_.target,M=Math.abs(R)>Math.abs(P)?"h":"v";if("touches"in _&&M==="h"&&I.type==="range")return!1;var Y=window.getSelection(),ae=Y&&Y.anchorNode,he=ae?ae===I||ae.contains(I):!1;if(he)return!1;var Ee=vw(M,I);if(!Ee)return!0;if(Ee?O=M:(O=M==="v"?"h":"v",Ee=vw(M,I)),!Ee)return!1;if(!n.current&&"changedTouches"in _&&(R||P)&&(n.current=O),!O)return!0;var ue=n.current||O;return Q2(ue,E,_,ue==="h"?R:P)},[]),f=v.useCallback(function(_){var E=_;if(!(!hi.length||hi[hi.length-1]!==a)){var k="deltaY"in E?yw(E):su(E),T=t.current.filter(function(O){return O.name===E.type&&(O.target===E.target||E.target===O.shadowParent)&&Y2(O.delta,k)})[0];
vendor: 4,074 bytes, line 400
400if(T&&T.should){E.cancelable&&E.preventDefault();return}if(!T){var R=(l.current.shards||[]).map(ww).filter(Boolean).filter(function(O){return O.contains(E.target)}),P=R.length>0?u(E,R[0]):!l.current.noIsolation;P&&E.cancelable&&E.preventDefault()}}},[]),p=v.useCallback(function(_,E,k,T){var R={name:_,delta:E,target:k,should:T,shadowParent:eL(k)};t.current.push(R),setTimeout(function(){t.current=t.current.filter(function(P){return P!==R})},1)},[]),m=v.useCallback(function(_){r.current=su(_),n.current=void 0},[]),g=v.useCallback(function(_){p(_.type,yw(_),_.target,u(_,e.lockRef.current))},[]),b=v.useCallback(function(_){p(_.type,su(_),_.target,u(_,e.lockRef.current))},[]);v.useEffect(function(){return hi.push(a),e.setCallbacks({onScrollCapture:g,onWheelCapture:g,onTouchMoveCapture:b}),document.addEventListener("wheel",f,fi),document.addEventListener("touchmove",f,fi),document.addEventListener("touchstart",m,fi),function(){hi=hi.filter(function(_){return _!==a}),document.removeEventListener("wheel",f,fi),document.removeEventListener("touchmove",f,fi),document.removeEventListener("touchstart",m,fi)}},[]);var w=e.removeScrollBar,S=e.inert;return v.createElement(v.Fragment,null,S?v.createElement(a,{styles:J2(i)}):null,w?v.createElement(B2,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function eL(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const tL=P2(j_,Z2);var L_=v.forwardRef(function(e,t){return v.createElement(Zu,kn({},e,{ref:t,sideCar:tL}))});L_.classNames=Zu.classNames;var rL=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},pi=new WeakMap,ou=new WeakMap,iu={},Nh=0,D_=function(e){return e&&(e.host||D_(e.parentNode))},nL=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=D_(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},sL=function(e,t,r,n){var i=nL(t,Array.isArray(e)?e:[e]);iu[r]||(iu[r]=new WeakMap);var a=iu[r],l=[],u=new Set,f=new Set(i),p=function(g){!g||u.has(g)||(u.add(g),p(g.parentNode))};i.forEach(p);var m=function(g){!g||f.has(g)||Array.prototype.forEach.call(g.children,function(b){if(u.has(b))m(b);else try{var w=b.getAttribute(n),S=w!==null&&w!=="false",_=(pi.get(b)||0)+1,E=(a.get(b)||0)+1;pi.set(b,_),a.set(b,E),l.push(b),_===1&&S&&ou.set(b,!0),E===1&&b.setAttribute(r,"true"),S||b.setAttribute(n,"true")}catch(k){console.error("aria-hidden: cannot operate on ",b,k)}})};return m(t),u.clear(),Nh++,function(){l.forEach(function(g){var b=pi.get(g)-1,w=a.get(g)-1;pi.set(g,b),a.set(g,w),b||(ou.has(g)||g.removeAttribute(n),ou.delete(g)),w||g.removeAttribute(r)}),Nh--,Nh||(pi=new WeakMap,pi=new WeakMap,ou=new WeakMap,iu={})}},oL=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),i=rL(e);return i?(n.push.apply(n,Array.from(i.querySelectorAll("[aria-live], script"))),sL(n,i,r,"aria-hidden")):function(){return null}};function iL(e){const t=aL(e),r=v.forwardRef((n,i)=>{const{children:a,...l}=n,u=v.Children.toArray(a),f=u.find(cL);if(f){const p=f.props.children,m=u.map(g=>g===f?v.Children.count(p)>1?v.Children.only(null):v.isValidElement(p)?p.props.children:null:g);return d.jsx(t,{...l,ref:i,children:v.isValidElement(p)?v.cloneElement(p,void 0,m):null})}return d.jsx(t,{...l,ref:i,children:a})});return r.displayName=`${e}.Slot`,r}function aL(e){const t=v.forwardRef((r,n)=>{const{children:i,...a}=r;if(v.isValidElement(i)){const l=dL(i),u=uL(a,i.props);return i.type!==v.Fragment&&(u.ref=n?bl(n,l):l),v.cloneElement(i,u)}return v.Children.count(i)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var lL=Symbol("radix.slottable");function cL(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===lL}function uL(e,t){const r={...t};for(const n in t){const i=e[n],a=t[n];/^on[A-Z]/.test(n)?i&&a?r[n]=(...u)=>{const f=a(...u);return i(...u),f}:i&&(r[n]=i):n==="style"?r[n]={...i,...a}
vendor: 4,212 bytes, line 400
400:n==="className"&&(r[n]=[i,a].filter(Boolean).join(" "))}return{...e,...r}}function dL(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var ed="Dialog",[M_,NU]=Vi(ed),[fL,ln]=M_(ed),$_=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:i,onOpenChange:a,modal:l=!0}=e,u=v.useRef(null),f=v.useRef(null),[p,m]=qu({prop:n,defaultProp:i??!1,onChange:a,caller:ed});return d.jsx(fL,{scope:t,triggerRef:u,contentRef:f,contentId:gu(),titleId:gu(),descriptionId:gu(),open:p,onOpenChange:m,onOpenToggle:v.useCallback(()=>m(g=>!g),[m]),modal:l,children:r})};$_.displayName=ed;var F_="DialogTrigger",U_=v.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=ln(F_,r),a=Gt(t,i.triggerRef);return d.jsx(xt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":dm(i.open),...n,ref:a,onClick:ut(e.onClick,i.onOpenToggle)})});U_.displayName=F_;var cm="DialogPortal",[hL,z_]=M_(cm,{forceMount:void 0}),B_=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:i}=e,a=ln(cm,t);return d.jsx(hL,{scope:t,forceMount:r,children:v.Children.map(n,l=>d.jsx(Oo,{present:r||a.open,children:d.jsx(Kp,{asChild:!0,container:i,children:l})}))})};B_.displayName=cm;var Pu="DialogOverlay",q_=v.forwardRef((e,t)=>{const r=z_(Pu,e.__scopeDialog),{forceMount:n=r.forceMount,...i}=e,a=ln(Pu,e.__scopeDialog);return a.modal?d.jsx(Oo,{present:n||a.open,children:d.jsx(mL,{...i,ref:t})}):null});q_.displayName=Pu;var pL=iL("DialogOverlay.RemoveScroll"),mL=v.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=ln(Pu,r);return d.jsx(L_,{as:pL,allowPinchZoom:!0,shards:[i.contentRef],children:d.jsx(xt.div,{"data-state":dm(i.open),...n,ref:t,style:{pointerEvents:"auto",...n.style}})})}),Eo="DialogContent",V_=v.forwardRef((e,t)=>{const r=z_(Eo,e.__scopeDialog),{forceMount:n=r.forceMount,...i}=e,a=ln(Eo,e.__scopeDialog);return d.jsx(Oo,{present:n||a.open,children:a.modal?d.jsx(gL,{...i,ref:t}):d.jsx(vL,{...i,ref:t})})});V_.displayName=Eo;var gL=v.forwardRef((e,t)=>{const r=ln(Eo,e.__scopeDialog),n=v.useRef(null),i=Gt(t,r.contentRef,n);return v.useEffect(()=>{const a=n.current;if(a)return oL(a)},[]),d.jsx(W_,{...e,ref:i,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ut(e.onCloseAutoFocus,a=>{var l;a.preventDefault(),(l=r.triggerRef.current)==null||l.focus()}),onPointerDownOutside:ut(e.onPointerDownOutside,a=>{const l=a.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0;(l.button===2||u)&&a.preventDefault()}),onFocusOutside:ut(e.onFocusOutside,a=>a.preventDefault())})}),vL=v.forwardRef((e,t)=>{const r=ln(Eo,e.__scopeDialog),n=v.useRef(!1),i=v.useRef(!1);return d.jsx(W_,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var l,u;(l=e.onCloseAutoFocus)==null||l.call(e,a),a.defaultPrevented||(n.current||(u=r.triggerRef.current)==null||u.focus(),a.preventDefault()),n.current=!1,i.current=!1},onInteractOutside:a=>{var f,p;(f=e.onInteractOutside)==null||f.call(e,a),a.defaultPrevented||(n.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const l=a.target;((p=r.triggerRef.current)==null?void 0:p.contains(l))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),W_=v.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:i,onCloseAutoFocus:a,...l}=e,u=ln(Eo,r),f=v.useRef(null),p=Gt(t,f);return b2(),d.jsxs(d.Fragment,{children:[d.jsx(C_,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:i,onUnmountAutoFocus:a,children:d.jsx(Bu,{role:"dialog",id:u.contentId,"aria-describedby":u.descriptionId,"aria-labelledby":u.titleId,"data-state":dm(u.open),...l,ref:p,onDismiss:()=>u.onOpenChange(!1)})}),d.jsxs(d.Fragment,{children:[d.jsx(yL,{titleId:u.titleId}),d.jsx(bL,{contentRef:f,descriptionId:u.descriptionId})]})]})}),um="DialogTitle",H_=v.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=ln(um,r);return d.jsx(xt.h2,{id:i.titleId,...n,ref:t})});H_.displayName=um;var K_="DialogDescription",G_=v.forwardRef((e,t)=>
400{const{__scopeDialog:r,...n}=e,i=ln(K_,r);return d.jsx(xt.p,{id:i.descriptionId,...n,ref:t})});G_.displayName=K_;var Q_="DialogClose",Y_=v.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=ln(Q_,r);return d.jsx(xt.button,{type:"button",...n,ref:t,onClick:ut(e.onClick,()=>i.onOpenChange(!1))})});Y_.displayName=Q_;function dm(e){return e?"open":"closed"}var J_="DialogTitleWarning",[IU,X_]=KC(J_,{contentName:Eo,titleName:um,docsSlug:"dialog"}),yL=({titleId:e})=>{const t=X_(J_),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
401
402If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
403
404For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return v.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},wL="DialogDescriptionWarning",bL=({contentRef:e,descriptionId:t})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${X_(wL).contentName}}.`;return v.useEffect(()=>{var a;const i=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&i&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},Z_=$_,xL=U_,eS=B_,td=q_,rd=V_,nd=H_,sd=G_,tS=Y_;const fm=Z_,LU=xL,_L=eS,rS=v.forwardRef(({className:e,...t},r)=>d.jsx(td,{ref:r,className:Pe("fixed inset-0 z-50 bg-black/80  data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));rS.displayName=td.displayName;const od=v.forwardRef(({className:e,children:t,...r},n)=>d.jsxs(_L,{children:[d.jsx(rS,{}),d.jsxs(rd,{ref:n,className:Pe("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),"aria-describedby":void 0,...r,children:[t,d.jsxs(tS,{className:"absolute right-4 top-4 roun
404ded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[d.jsx(Hu,{className:"h-4 w-4"}),d.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));od.displayName=rd.displayName;const hm=({className:e,...t})=>d.jsx("div",{className:Pe("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});hm.displayName="DialogHeader";const SL=({className:e,...t})=>d.jsx("div",{className:Pe("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});SL.displayName="DialogFooter";const pm=v.forwardRef(({className:e,...t},r)=>d.jsx(nd,{ref:r,className:Pe("text-lg font-semibold leading-none tracking-tight",e),...t}));pm.displayName=nd.displayName;const EL=v.forwardRef(({className:e,...t},r)=>d.jsx(sd,{ref:r,className:Pe("text-sm text-muted-foreground",e),...t}));EL.displayName=sd.displayName;var kL=Symbol.for("react.lazy"),ju=Fu[" use ".trim().toString()];function TL(e){return typeof e=="object"&&e!==null&&"then"in e}function nS(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===kL&&"_payload"in e&&TL(e._payload)}function id(e){const t=CL(e),r=v.forwardRef((n,i)=>{let{children:a,...l}=n;nS(a)&&typeof ju=="function"&&(a=ju(a._payload));const u=v.Children.toArray(a),f=u.find(PL);if(f){const p=f.props.children,m=u.map(g=>g===f?v.Children.count(p)>1?v.Children.only(null):v.isValidElement(p)?p.props.children:null:g);return d.jsx(t,{...l,ref:i,children:v.isValidElement(p)?v.cloneElement(p,void 0,m):null})}return d.jsx(t,{...l,ref:i,children:a})});return r.displayName=`${e}.Slot`,r}var Ji=id("Slot");function CL(e){const t=v.forwardRef((r,n)=>{let{children:i,...a}=r;if(nS(i)&&typeof ju=="function"&&(i=ju(i._payload)),v.isValidElement(i)){const l=OL(i),u=jL(a,i.props);return i.type!==v.Fragment&&(u.ref=n?bl(n,l):l),v.cloneElement(i,u)}return v.Children.count(i)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var RL=Symbol("radix.slottable");function PL(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===RL}function jL(e,t){const r={...t};for(const n in t){const i=e[n],a=t[n];/^on[A-Z]/.test(n)?i&&a?r[n]=(...u)=>{const f=a(...u);return i(...u),f}:i&&(r[n]=i):n==="style"?r[n]={...i,...a}:n==="className"&&(r[n]=[i,a].filter(Boolean).join(" "))}return{...e,...r}}function OL(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}const AL=_l("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),bt=v.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...i},a)=>{const l=n?Ji:"button";return d.jsx(l,{className:Pe(AL({variant:t,size:r,className:e})),ref:a,...i})});bt.displayName="Button";const NL=({isOpen:e,onClose:t,onStartTour:r})=>{const n=()=>{r()},i=()=>{t()};return d.jsx(fm,{open:e,onOpenChange:t,children:d.jsxs(od,{className:"sm:max-w-md",children:[d.jsx(hm,{children:d.jsxs(pm,{className:"flex items-center gap-2 text-xl",children:[d.jsxs("div",{className:"relative",children:[d.jsx(fp,{className:"h-6 w-6 text-primary animate-pulse"}),d.jsx("div",{className:"absolute inset-0 h-6 w-6 text-primary animate-ping opacity-75",children:d.jsx(fp,{className:"h-6 w-6"})})]}),"Welcome to Xterns.ai!"]})}),d.jsxs("div",{className:"space-y-4 py-4",children:[d.jsx("p",{className:"text-muted-foreground",children:"Welcome to the Xtern platform! Let's take a comprehensive interactive tour to help you get familiar with all the key features and maximize your experience."}),d.jsxs("div",{className:"bg-gradient-to-r from-primary/10 to-secondary/10 rounded-lg p-4 space-y-2",children:[d.jsx("h4",{className:"font-semibold text-sm",children:"This 6-part tour covers:"}),d.jsxs("ul",{className:"text-sm text-muted-foreground space-y-1",children:[d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Dashboard:"})," Your Signal Score, notifications, and active pods"]}),d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Profile:"})," Updating your picture, skills, and portfolio links"]}),d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Pods:"})," Searching, applying, and collaborating in pods"]}),d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Sprint Board:"})," Task management and team collaboration"]}),d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Skill Tracker:"})," Monitor your growth and progress metrics"]}),d.jsxs("li",{children:["• ",d.jsx("strong",{children:"Learning Hub:"})," Access resources and personalized recommendations"]})]})]}),d.jsx("div",{className:"bg-amber-50 dark:bg-amber-950/30 border border-amber-200 dark:border-amber-800 rounded-lg p-3",children:d.jsxs("p",{className:"text-sm text-amber-800 dark:text-amber-200",children:[d.jsx("strong",{children:"Important:"})," You'll need to complete the full tour to continue using the platform. You can skip for now, but the tour will appear again until completed."]})})]}),d.jsxs("div",{className:"flex gap-2 pt-4",children:[d.jsxs(bt,{variant:"outline",onClick:i,className:"flex-1",children:[d.jsx(Hu,{className:"h-4 w-4 mr-2"}),"Skip for now"]}),d.jsxs(bt,{onClick:n,className:"flex-1",children:[d.jsx(dx,{className:"h-4 w-4 mr-2"}),"Start Tour"]})]})]})})},IL=({isOpen:e,onClose:t})=>d.jsx(fm,{open:e,onOpenChange:t,children:d.jsx(od,{className:"max-w-md mx-auto bg-gradient-to-br from-primary/5 to-accent/5 border-primary/20",children:d.jsxs("div",{className:"text-center space-y-6 p-6",children:[d.jsxs("div",{className:"relative",children:[d.jsx("div",{className:"mx-auto w-16 h-16 bg-primary/10 rounded-full flex items-center justify-center animate-scale-in",children:d.jsx(hu,{className:"w-8 h-8 text-primary"})}),d.jsx("div",{className:"absolute -top-1 -right-1",children:d.jsx(fp,{className:"w-6 h-6 text-accent animate-pulse"})})]}),d.jsxs("div",{className:"space-y-4",children:[d.jsx("h2",{className:"text-2xl font-bold text-foreground",children:"You're Ready! 🎉"}),d.jsx("p",{className:"text-muted-foreground leading-relaxed",children:"And that's your onboarding tour! You're now ready to explore, collaborate, and grow. Remember, you can revisit these guides anytime from the Help Center."}),d.jsx("p",{className:"text-primary font-medium",children:"Welcome again to Xterns—let's build your amazing portfolio together!"})]}),d.jsx(bt,{onClick:t,className:"w-full bg-gradient-to-r from-primary to-primary/80 hover:from-primary/90 hover:to-primary/70 text-primary-foreground font-medium",children:"Start Building! ✨"})]})})}),sS=v.createContext(void 0),DU=()=>{const e=v.useContext(sS);if(!e)throw new Error("useOnboardingTour must be used within OnboardingTourProvider");return e},au=3,LL=({children:e})=>{const{user:t}=ar(),r=jo(),[n,i]=v.useState(!1),[a,l]=v.useState(0),[u,f]=v.useState([]),[p,m]=v.useState(!1),[g,b]=v.useState(!1),[w,S]=v.useState(!0),[_,E]=v.useState(!1),k=v.useRef(!1),T=["dashboard","profile","pods","sprintBoard","skillTracker","learningHub"],R={dashboard:"/xterns/dashboard",profile:"/xterns/profile",pods:"/xterns/pods",sprintBoard:"/xterns/pods",skillTracker:"/xterns/ei-tracker",learningHub:"/xterns/learning"},P={dashboard:Th,profile:i2,pods:a2,sprintBoard:l2,skillTracker:c2,learningHub:u2};v.useEffect(()=>{(async()=>
404{if(!t){S(!1);return}try{const{data:z,error:W}=await me.from("xterns_profiles").select("onboarding_tour_completed, onboarding_tour_version, assessment_completed").eq("user_id",t.id).maybeSingle();if(W){console.error("Error fetching tour status:",W),S(!1);return}if(z){const K=z.onboarding_tour_version!==au,N=z.assessment_completed&&(!z.onboarding_tour_completed||K);if(b(z.onboarding_tour_completed&&!K),N){const U=localStorage.getItem("xtern_onboarding_tour_state");if(U)try{const X=JSON.parse(U);if(X.version===au&&typeof X.currentIndex=="number"&&X.currentIndex<T.length){m(!1),O(X);return}}catch(X){console.warn("Invalid saved tour state:",X)}m(!0)}}}catch(z){console.error("Error checking tour status:",z)}finally{S(!1)}})()},[t]);const O=async re=>{const{currentIndex:z,stepIndex:W}=re,K=T[z],N=R[K];r(N),setTimeout(async()=>{console.log(`Resuming tour: ${K}`);const U=P[K],X=[];for(const fe of U)fe.target&&typeof fe.target=="string"?await M(fe.target,3e3)?X.push(fe):console.warn(`Skipping step with missing target: ${fe.target}`):X.push(fe);X.length>0?(f(X),l(typeof W=="number"?Math.min(W,X.length-1):0),i(!0)):(console.error("No available tour steps found, skipping tour"),localStorage.removeItem("xtern_onboarding_tour_state"))},1500)},I=(re,z)=>{if(console.log("Starting tour:",{tourType:re,tourName:z}),re==="sequence"){const W={version:au,sequence:T,currentIndex:0,stepIndex:0};localStorage.setItem("xtern_onboarding_tour_state",JSON.stringify(W)),r("/xterns/dashboard"),setTimeout(async()=>{console.log("Checking for dashboard elements...");const K=await Y(["#dashboard-overview","#ei-score-card","#notifications-icon"]);K?(console.log(`Dashboard element found: ${K}, starting tour`),f(Th),l(0),i(!0),m(!1)):(console.warn("No dashboard elements found, starting tour anyway"),f(Th),l(0),i(!0),m(!1))},800)}else if(re==="single"&&z){const W=P[z];W?(f(W),l(0),i(!0),m(!1)):console.warn(`Tour "${z}" not found`)}},M=(re,z=15e3)=>new Promise(W=>{if(console.log(`Waiting for selector: ${re}`),document.querySelector(re)){console.log(`Found element immediately: ${re}`),W(!0);return}let N;const U=new MutationObserver(()=>{document.querySelector(re)&&(console.log(`Found element after waiting: ${re}`),U.disconnect(),clearTimeout(N),W(!0))});N=setTimeout(()=>{console.warn(`Timeout waiting for selector: ${re}`),U.disconnect(),W(!1)},z),U.observe(document.body,{childList:!0,subtree:!0})}),Y=(re,z=15e3)=>new Promise(W=>{console.log(`Waiting for any selector: ${re.join(", ")}`);for(const U of re)if(document.querySelector(U)){console.log(`Found element immediately: ${U}`),W(U);return}let K;const N=new MutationObserver(()=>{for(const U of re)if(document.querySelector(U)){console.log(`Found element after waiting: ${U}`),N.disconnect(),clearTimeout(K),W(U);return}});K=setTimeout(()=>{console.warn(`Timeout waiting for selectors: ${re.join(", ")}`),N.disconnect(),W(null)},z),N.observe(document.body,{childList:!0,subtree:!0})}),ae=async()=>{if(k.current)return;k.current=!0,console.log("Transitioning to next tour..."),i(!1);const re=localStorage.getItem("xtern_onboarding_tour_state");if(re)try{const z=JSON.parse(re),W=z.currentIndex+1;if(W<T.length){console.log("Moving to next tour in sequence:",T[W]),z.currentIndex=W,z.stepIndex=0,localStorage.setItem("xtern_onboarding_tour_state",JSON.stringify(z));const K=T[W],N=R[K],U=P[K];r(N),setTimeout(async()=>{console.log(`Starting tour: ${K}`);const X=[];for(const fe of U)fe.target&&typeof fe.target=="string"?await M(fe.target,3e3)?X.push(fe):console.warn(`Skipping step with missing target: ${fe.target}`):X.push(fe);X.length>0?(f(X),l(0),i(!0)):(console.error("No available tour steps found, skipping to next tour"),z.currentIndex=W+1,localStorage.setItem("xtern_onboarding_tour_state",JSON.stringify(z)),await ae()),k.current=!1},1500)}else console.log("Completed entire tour sequence"),i(!1),E(!0),await Ee(),k.current=!1}catch(z){console.warn("Failed to process tour sequence:",z),await Ee(),k.current=!1}else await Ee(),k.current=!1},he=async re=>{const{status:z,action:W,index:K,type:N}=re;if(console.log("Tour callback:",{status:z,action:W,index:K,type:N,currentTourLength:u.length,tourStep:a}),z==="error"){console.warn("Tour error detected, likely target not found. Attempting to wait and retry...");const X=u[K];if(X!=null&&X.target&&typeof X.target=="string")try{await M(X.target,3e3),console.log("Target found after waiting, continuing tour...");return}catch{console.warn("Target still not found after waiting, skipping step...");const Oe=K+1;if(Oe<u.length){l(Oe);const Fe=localStorage.getItem("xtern_onboarding_tour_state");if(Fe)try{const Re=JSON.parse(Fe);Re.stepIndex=Oe,localStorage.setItem("xtern_onboarding_tour_state",JSON.stringify(Re))}catch(Re){console.warn("Failed to update tour state:",Re)}}else await ae();return}}if(k.current){console.log("Ignoring callback during transition");return}if(N==="step:after")if(W==="next"){const X=K>=u.length-1;if(console.log("Next action:",{index:K,isLastStep:X,currentTourLength:u.length}),X){console.log("On last step, transitioning to next tour..."),await ae();return}else l(K+1)}else W==="prev"&&l(Math.max(0,K-1));const U=localStorage.getItem("xtern_onboarding_tour_state");if(U)try{const X=JSON.parse(U);X.stepIndex=W==="next"?K+1:W==="prev"?Math.max(0,K-1):K,localStorage.setItem("xtern_onboarding_tour_state",JSON.stringify(X))}catch(X){console.warn("Failed to update tour state:",X)}z===He.FINISHED?(console.log("Tour finished via STATUS.FINISHED"),await ae()):z===He.SKIPPED&&(i(!1),l(0))},Ee=async()=>
404{if(t)try{const{error:re}=await me.from("xterns_profiles").update({onboarding_tour_completed:!0,onboarding_tour_version:au,onboarding_tour_completed_at:new Date().toISOString()}).eq("user_id",t.id);re?console.error("Error marking tour as completed:",re):(b(!0),m(!1),localStorage.removeItem("xtern_onboarding_tour_state"))}catch(re){console.error("Error updating tour completion:",re)}},ue={startTour:I,isRunning:n,tourStep:a,showWelcome:p,setShowWelcome:m,tourCompleted:g,loading:w},je=localStorage.getItem("xtern_onboarding_tour_state");let le=0;try{je&&(le=JSON.parse(je).currentIndex||0)}catch(re){console.warn("Failed to parse tour state:",re)}const Te=le>=T.length-1?"Finish Tour":"Next Tour";return d.jsxs(sS.Provider,{value:ue,children:[e,d.jsx(NL,{isOpen:p,onClose:()=>m(!1),onStartTour:()=>I("sequence")}),d.jsx(IL,{isOpen:_,onClose:()=>E(!1)}),n&&u.length>0&&!k.current&&a<u.length&&d.jsx(o2,{steps:u.filter(re=>re.target&&typeof re.target=="string"),run:!0,continuous:!0,showProgress:!0,showSkipButton:!0,stepIndex:Math.min(a,u.length-1),callback:he,disableOverlayClose:!0,disableScrollParentFix:!0,hideBackButton:a===0,spotlightClicks:!0,locale:{last:Te,back:"Back",close:"Close",next:"Next",skip:"Skip"},styles:{options:{primaryColor:"hsl(var(--primary))",backgroundColor:"hsl(var(--background))",textColor:"hsl(var(--foreground))",overlayColor:"rgba(0, 0, 0, 0.4)",arrowColor:"hsl(var(--background))",beaconSize:36,zIndex:1e3},tooltip:{borderRadius:8,fontSize:14},tooltipContainer:{textAlign:"left"},buttonNext:{backgroundColor:"hsl(var(--primary))",color:"hsl(var(--primary-foreground))",borderRadius:6,padding:"8px 16px",fontSize:14},buttonBack:{color:"hsl(var(--muted-foreground))",marginRight:8},buttonSkip:{color:"hsl(var(--muted-foreground))"}}})]})},DL="modulepreload",ML=function(e){return"/"+e},bw={},H=function(t,r,n){let i=Promise.resolve();if(r&&r.length>0){let l=function(p){return Promise.all(p.map(m=>Promise.resolve(m).then(g=>({status:"fulfilled",value:g}),g=>({status:"rejected",reason:g}))))};document.getElementsByTagName("link");const u=document.querySelector("meta[property=csp-nonce]"),f=(u==null?void 0:u.nonce)||(u==null?void 0:u.getAttribute("nonce"));i=l(r.map(p=>{if(p=ML(p),p in bw)return;bw[p]=!0;const m=p.endsWith(".css"),g=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${g}`))return;const b=document.createElement("link");if(b.rel=m?"stylesheet":DL,m||(b.as="script"),b.crossOrigin="",b.href=p,f&&b.setAttribute("nonce",f),document.head.appendChild(b),m)return new Promise((w,S)=>{b.addEventListener("load",w),b.addEventListener("error",()=>S(new Error(`Unable to preload CSS for ${p}`)))})}))}function a(l){const u=new Event("vite:preloadError",{cancelable:!0});if(u.payload=l,window.dispatchEvent(u),!u.defaultPrevented)throw l}return i.then(l=>{for(const u of l||[])u.status==="rejected"&&a(u.reason);return t().catch(a)})},$s=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,className:Pe("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));$s.displayName="Card";const Fs=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,className:Pe("flex flex-col space-y-1.5 p-6",e),...t}));Fs.displayName="CardHeader";const Us=v.forwardRef(({className:e,...t},r)=>d.jsx("h3",{ref:r,className:Pe("text-2xl font-semibold leading-none tracking-tight",e),...t}));Us.displayName="CardTitle";const mm=v.forwardRef(({className:e,...t},r)=>d.jsx("p",{ref:r,className:Pe("text-sm text-muted-foreground",e),...t}));mm.displayName="CardDescription";const ko=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,className:Pe("p-6 pt-0",e),...t}));ko.displayName="CardContent";const $L=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,className:Pe("flex items-center p-6 pt-0",e),...t}));$L.displayName="CardFooter";function FL(e){const t=v.useRef({value:e,previous:e});return v.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function oS(e){const[t,r]=v.useState(void 0);return Fr(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const a=i[0];let l,u;if("borderBoxSize"in a){const f=a.borderBoxSize,p=Array.isArray(f)?f[0]:f;l=p.inlineSize,u=p.blockSize}else l=e.offsetWidth,u=e.offsetHeight;r({width:l,height:u})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var ad="Checkbox",[UL]=Vi(ad),[zL,gm]=UL(ad);function BL(e){const{__scopeCheckbox:t,checked:r,children:n,defaultChecked:i,disabled:a,form:l,name:u,onCheckedChange:f,required:p,value:m="on",internal_do_not_use_render:g}=e,[b,w]=qu({prop:r,defaultProp:i??!1,onChange:f,caller:ad}),[S,_]=v.useState(null),[E,k]=v.useState(null),T=v.useRef(!1),R=S?!!l||!!S.closest("form"):!0,P={checked:b,disabled:a,setChecked:w,control:S,setControl:_,name:u,form:l,value:m,hasConsumerStoppedPropagationRef:T,required:p,defaultChecked:Ds(i)?!1:i,isFormControl:R,bubbleInput:E,setBubbleInput:k};return d.jsx(zL,{scope:t,...P,children:qL(g)?g(P):n})}var iS="CheckboxTrigger",aS=v.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:r,...n},i)=>{const{control:a,value:l,disabled:u,checked:f,required:p,setControl:m,setChecked:g,hasConsumerStoppedPropagationRef:b,isFormControl:w,bubbleInput:S}=gm(iS,e),_=Gt(i,m),E=v.useRef(f);return v.useEffect(()=>{const k=a==null?void 0:a.form;if(k){const T=()=>g(E.current);return k.addEventListener("reset",T),()=>k.removeEventListener("reset",T)}},[a,g]),d.jsx(xt.button,{type:"button",role:"checkbox","aria-checked":Ds(f)?"mixed":f,"aria-required":p,"data-state":fS(f),"data-disabled":u?"":void 0,disabled:u,value:l,...n,ref:_,onKeyDown:ut(t,k=>{k.key==="Enter"&&k.preventDefault()}),onClick:ut(r,k=>{g(T=>Ds(T)?!0:!T),S&&w&&(b.current=k.isPropagationStopped(),b.current||k.stopPropagation())})})});aS.displayName=iS;var vm=v.forwardRef((e,t)=>
404{const{__scopeCheckbox:r,name:n,checked:i,defaultChecked:a,required:l,disabled:u,value:f,onCheckedChange:p,form:m,...g}=e;return d.jsx(BL,{__scopeCheckbox:r,checked:i,defaultChecked:a,disabled:u,required:l,onCheckedChange:p,name:n,form:m,value:f,internal_do_not_use_render:({isFormControl:b})=>d.jsxs(d.Fragment,{children:[d.jsx(aS,{...g,ref:t,__scopeCheckbox:r}),b&&d.jsx(dS,{__scopeCheckbox:r})]})})});vm.displayName=ad;var lS="CheckboxIndicator",cS=v.forwardRef((e,t)=>{const{__scopeCheckbox:r,forceMount:n,...i}=e,a=gm(lS,r);return d.jsx(Oo,{present:n||Ds(a.checked)||a.checked===!0,children:d.jsx(xt.span,{"data-state":fS(a.checked),"data-disabled":a.disabled?"":void 0,...i,ref:t,style:{pointerEvents:"none",...e.style}})})});cS.displayName=lS;var uS="CheckboxBubbleInput",dS=v.forwardRef(({__scopeCheckbox:e,...t},r)=>{const{control:n,hasConsumerStoppedPropagationRef:i,checked:a,defaultChecked:l,required:u,disabled:f,name:p,value:m,form:g,bubbleInput:b,setBubbleInput:w}=gm(uS,e),S=Gt(r,w),_=FL(a),E=oS(n);v.useEffect(()=>{const T=b;if(!T)return;const R=window.HTMLInputElement.prototype,O=Object.getOwnPropertyDescriptor(R,"checked").set,I=!i.current;if(_!==a&&O){const M=new Event("click",{bubbles:I});T.indeterminate=Ds(a),O.call(T,Ds(a)?!1:a),T.dispatchEvent(M)}},[b,_,a,i]);const k=v.useRef(Ds(a)?!1:a);return d.jsx(xt.input,{type:"checkbox","aria-hidden":!0,defaultChecked:l??k.current,required:u,disabled:f,name:p,value:m,form:g,...t,tabIndex:-1,ref:S,style:{...t.style,...E,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});dS.displayName=uS;function qL(e){return typeof e=="function"}function Ds(e){return e==="indeterminate"}function fS(e){return Ds(e)?"indeterminate":e?"checked":"unchecked"}const hS=v.forwardRef(({className:e,...t},r)=>d.jsx(vm,{ref:r,className:Pe("peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...t,children:d.jsx(cS,{className:Pe("flex items-center justify-center text-current"),children:d.jsx(ZR,{className:"h-4 w-4"})})}));hS.displayName=vm.displayName;const VL=({isOpen:e,onSelect:t,availableRoles:r})=>{const[n,i]=v.useState(null),[a,l]=v.useState(!1),u={xtern:{title:"Xtern Dashboard",description:"Access your learning dashboard, projects, and development opportunities",icon:gx,color:"bg-blue-50 border-blue-200 hover:bg-blue-100",iconColor:"text-blue-600"},tech_lead:{title:"Tech Lead Dashboard",description:"Manage your pods, mentor xterns, and oversee project development",icon:px,color:"bg-purple-50 border-purple-200 hover:bg-purple-100",iconColor:"text-purple-600"},corporate:{title:"Corporate Dashboard",description:"Access hiring tools, manage assessments, and find top talent",icon:fu,color:"bg-green-50 border-green-200 hover:bg-green-100",iconColor:"text-green-600"},enterprise:{title:"Enterprise Dashboard",description:"Access hiring tools, manage assessments, and find top talent",icon:fu,color:"bg-green-50 border-green-200 hover:bg-green-100",iconColor:"text-green-600"},super_admin:{title:"Super Admin Dashboard",description:"Platform administration and system management",icon:fu,color:"bg-red-50 border-red-200 hover:bg-red-100",iconColor:"text-red-600"}},f=()=>{n&&t(n,a)},p=()=>{localStorage.removeItem("preferred_active_role"),n&&t(n,!1)};return d.jsx(fm,{open:e,onOpenChange:()=>{},children:d.jsxs(od,{className:"max-w-2xl",children:[d.jsxs(hm,{children:[d.jsx(pm,{className:"text-2xl font-bold text-center mb-2",children:"Choose Your Dashboard"}),d.jsx("p",{className:"text-muted-foreground text-center",children:"You have multiple roles. Select which dashboard you'd like to access."})]}),d.jsx("div",{className:"space-y-4 mt-6",children:r.map(m=>{const g=u[m],b=g.icon;return d.jsx($s,{className:`cursor-pointer transition-all ${g.color} ${n===m?"ring-2 ring-primary":""}`,onClick:()=>i(m),children:d.jsx(Fs,{className:"pb-3",children:d.jsxs("div",{className:"flex items-center space-x-3",children:[d.jsx("div",{className:"p-2 rounded-lg bg-white",children:d.jsx(b,{className:`h-6 w-6 ${g.iconColor}`})}),d.jsxs("div",{className:"flex-1",children:[d.jsx(Us,{className:"text-lg",children:g.title}),d.jsx(mm,{className:"text-sm mt-1",children:g.description})]}),d.jsx("div",{className:"w-5 h-5 rounded-full border-2 border-gray-300 flex items-center justify-center",children:n===m&&d.jsx("div",{className:"w-3 h-3 rounded-full bg-primary"})})]})})},m)})}),d.jsxs("div",{className:"flex items-center space-x-2 mt-6",children:[d.jsx(hS,{id:"remember",checked:a,onCheckedChange:m=>l(m)}),d.jsx("label",{htmlFor:"remember",className:"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",children:"Remember my choice (you can change this later in your profile)"})]}),d.jsxs("div",{className:"flex gap-3 mt-6",children:[d.jsx(bt,{onClick:p,disabled:!n,variant:"outline",className:"flex-1",children:"Ask Me Next Time"}),d.jsx(bt,{onClick:f,disabled:!n,className:"flex-1",children:"Continue to Dashboard"})]})]})})},te=({children:e,requiredUserType:t="any"})=>{const{user:r,isLoading:n,isInAssessmentLockdown:i,checkAssessmentLockdown:a}=ar(),[l,u]=v.useState(!1);if(v.useEffect(()=>{((r==null?void 0:r.activeRole)==="xtern"||(r==null?void 0:r.activeRole)==="tech_lead")&&!l?(console.log("🔒 AuthGuard: Additional lockdown check for user:",r.activeRole),a(r.id).then(p=>{if(console.log("🔒 AuthGuard: Lockdown check result:",p),u(!0),p){const m=r.activeRole==="tech_lead"?"/tech-lead/assessment-lockdown":"/assessment-lockdown";window.location.pathname!==m&&(console.log("🔒 AuthGuard: Redirecting to lockdown page:",m),window.location.href=m)}})):(r==null?void 0:r.activeRole)!=="xtern"&&(r==null?void 0:r.activeRole)!=="tech_lead"&&u(!0)},[r,a,l]),n||((r==null?void 0:r.activeRole)==="xtern"||(r==null?void 0:r.activeRole)==="tech_lead")&&!l)return d.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center p-4",children:d.jsxs("div",{className:"text-center",children:[d.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary mx-auto mb-4"}),d.jsx("p",{className:"text-muted-foreground",children:!l&&((r==null?void 0:r.activeRole)==="xtern"||(r==null?void 0:r.activeRole)==="tech_lead")?"Checking account status...":"Authenticating..."})]})});if(!r)return d.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center p-4",children:d.jsxs($s,{className:"w-full max-w-md",children:[d.jsxs(Fs,{className:"text-center",children:[d.jsx("div",{className:"mx-auto w-16 h-16 bg-gray-100 rounded-full flex items-center justify-center mb-4",children:d.jsx(Jp,{className:"h-8 w-8 text-gray-500"})}),d.jsx(Us,{className:"text-xl",children:"Authentication Required 🔐"})]}),d.jsxs(ko,{className:"text-center space-y-4",children:[d.jsx("p",{className:"text-gray-600",children:"Please log in to access this page."}),d.jsxs("div",{className:"space-y-2",children:[d.jsx(Lt,{to:"/login",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Log In"})}),d.jsx(Lt,{to:"/",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Return Home"})})]})]})]})});if((r==null?void 0:r.activeRole)==="xtern"&&i&&window.location.pathname!=="/assessment-lockdown")return console.log("🔒 AuthGuard: User is locked, redirecting to lockdown page"),window.location.href="/assessment-lockdown",null;if(t==="any")return d.jsx(d.Fragment,{children:e});if(!(r.roles.includes(t)||t==="corporate"&&r.roles.includes("enterprise")||t==="enterprise"&&r.roles.includes("corporate"))){const p=r.roles.includes("xtern"),m=r.roles.includes("tech_lead"),g=p&&(t==="enterprise"||t==="corporate"),b=p&&t==="tech_lead",w=m&&t!=="tech_lead";return d.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center p-4",children:d.jsxs($s,{className:"w-full max-w-md",children:[d.jsxs(Fs,{className:"text-center",children:[d.jsx("div",{className:"mx-auto w-16 h-16 bg-blue-50 rounded-full flex items-center justify-center mb-4",children:d.jsx(YR,{className:"h-8 w-8 text-blue-500"})}),d.jsxs(Us,{className:"text-xl",children:[(t==="enterprise"||t==="corporate")&&"Corporate Access Required 🏢",t==="tech_lead"&&"Tech Lead Access Required 👨‍💻",t==="xtern"&&"Xtern Access Required 🎓",t
404==="client"&&"Client Access Required"]})]}),d.jsxs(ko,{className:"text-center space-y-4",children:[d.jsx("p",{className:"text-gray-600",children:g?"This page is restricted to corporate users. Please sign in with your corporate account to access the roadmap.":b?"This page is restricted to tech leads. Please sign in with your tech lead account.":w?"You don't have permission to access this page as a tech lead.":"You don't have permission to access this page."}),d.jsx("div",{className:"space-y-2",children:g?d.jsxs(d.Fragment,{children:[d.jsx(Lt,{to:"/login",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Sign In as Corporate User"})}),d.jsx(Lt,{to:"/xterns/dashboard",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Go to Xtern Dashboard"})})]}):b?d.jsxs(d.Fragment,{children:[d.jsx(Lt,{to:"/login",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Sign In as Tech Lead"})}),d.jsx(Lt,{to:"/xterns/dashboard",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Go to Xtern Dashboard"})})]}):d.jsxs(d.Fragment,{children:[d.jsx(Lt,{to:r.roles.includes("xtern")?"/xterns/dashboard":r.roles.includes("tech_lead")?"/tech-lead/dashboard":r.roles.includes("client")?"/client/dashboard":"/enterprise/dashboard",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Go to Your Dashboard"})}),d.jsx(Lt,{to:"/",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Return Home"})})]})})]})]})})}return d.jsx(d.Fragment,{children:e})},WL=v.createContext(void 0),HL=()=>{const e=v.useContext(WL);if(e===void 0)throw new Error("useAdminAuth must be used within an AdminAuthProvider");return e},KL=({children:e})=>{const{admin:t}=HL();return t?d.jsx(d.Fragment,{children:e}):d.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center p-4",children:d.jsxs($s,{className:"w-full max-w-md",children:[d.jsxs(Fs,{className:"text-center",children:[d.jsx("div",{className:"mx-auto w-16 h-16 bg-gray-100 rounded-full flex items-center justify-center mb-4",children:d.jsx(Jp,{className:"h-8 w-8 text-gray-500"})}),d.jsx(Us,{className:"text-xl",children:"Admin Access Required 🔐"})]}),d.jsxs(ko,{className:"text-center space-y-4",children:[d.jsx("p",{className:"text-gray-600",children:"Please log in as an administrator to access this page."}),d.jsxs("div",{className:"space-y-2",children:[d.jsx(Lt,{to:"/admin/login",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Admin Login"})}),d.jsx(Lt,{to:"/",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Return Home"})})]})]})]})})},mt=({children:e})=>{const{user:t}=ar();return!t||t.activeRole!=="super_admin"?d.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center p-4",children:d.jsxs($s,{className:"w-full max-w-md",children:[d.jsxs(Fs,{className:"text-center",children:[d.jsx("div",{className:"mx-auto w-16 h-16 bg-purple-100 rounded-full flex items-center justify-center mb-4",children:d.jsx(Jp,{className:"h-8 w-8 text-primary"})}),d.jsx(Us,{className:"text-xl",children:"Super Admin Access Required 🔐"})]}),d.jsxs(ko,{className:"text-center space-y-4",children:[d.jsx("p",{className:"text-gray-600",children:"Please log in as a super administrator to access this page."}),d.jsxs("div",{className:"space-y-2",children:[d.jsx(Lt,{to:"/login",className:"block",children:d.jsx(bt,{className:"w-full bg-primary hover:bg-opacity-90",children:"Login"})}),d.jsx(Lt,{to:"/",className:"block",children:d.jsx(bt,{variant:"outline",className:"w-full",children:"Return Home"})})]})]})]})}):d.jsx(d.Fragment,{children:e})},GL=()=>d.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:d.jsxs("div",{className:"flex flex-col items-center gap-4",children:[d.jsx("div",{className:"animate-spin rounded-full h-10 w-10 border-b-2 border-primary"}),d.jsx("p",{className:"text-sm text-muted-foreground",children:"Loading..."})]})}),pS="assessment-status",xw=e=>[pS,e??"anon"],QL=[pS];async function YL(e){var p;const[t,r,n]=await Promise.all([me.from("xterns_profiles").select("assessment_completed").eq("user_id",e).maybeSingle(),me.from("xtern_assessments").select("*").eq("user_id",e).eq("assessment_type","onboarding").eq("tech_assessment_passed",!0).order("created_at",{ascending:!1}).limit(1).maybeSingle(),me.from("xtern_assessments").select("*").eq("user_id",e).eq("assessment_type","onboarding").order("created_at",{ascending:!1}).limit(1).maybeSingle()]);if(t.error)throw t.error;if(r.error)throw r.error;if(n.error)throw n.error;const i=!!((p=t.data)!=null&&p.assessment_completed),l=r.data??n.data,u=!!(l!=null&&l.assessment_completed&&(l!=null&&l.tech_assessment_passed));if(i!==u&&console.warn("[useAssessmentStatus] Drift between xterns_profiles.assessment_completed and xtern_assessments status",{profileSaysComplete:i,assessmentSaysComplete:u,userId:e}),i||u)return{id:(l==null?void 0:l.id)??null,currentStage:4,stage1Completed:!0,stage2Completed:!0,stage3Completed:!0,assessmentCompleted:!0,techAssessmentPassed:!0,readyForTechAssessment:!1,startedAt:(l==null?void 0:l.started_at)??null,completedAt:(l==null?void 0:l.completed_at)??null};if(l){const m=l.stage_1_completed&&l.stage_2_completed&&l.stage_3_completed;return{id:l.id,currentStage:l.current_stage,stage1Completed:l.stage_1_completed,stage2Completed:l.stage_2_completed,stage3Completed:l.stage_3_completed,assessmentCompleted:!1,techAssessmentPassed:l.tech_assessment_passed||!1,readyForTechAssessment:m&&!l.tech_assessment_passed,startedAt:l.started_at,completedAt:l.completed_at}}return{id:null,currentStage:1,stage1Completed:!1,stage2Completed:!1,stage3Completed:!1,assessmentCompleted:!1,techAssessmentPassed:!1,readyForTechAssessment:!1,startedAt:null,completedAt:null}}const ym=()=>{const{user:e}=ar(),t=qp(),r=Eb({queryKey:xw(e==null?void 0:e.id),queryFn:()=>YL(e.id),enabled:!!e,staleTime:5*6e4,gcTime:30*6e4,refetchOnWindowFocus:!1,refetchOnReconnect:!0}),n=()=>
404t.invalidateQueries({queryKey:QL}),i=f=>t.setQueryData(xw(e==null?void 0:e.id),f),a=async()=>{if(!e)return null;try{const{data:f}=await me.from("xtern_assessments").select("*").eq("user_id",e.id).eq("assessment_type","onboarding").order("created_at",{ascending:!1}).limit(1).maybeSingle();if(f)return i({id:f.id,currentStage:f.current_stage,stage1Completed:f.stage_1_completed,stage2Completed:f.stage_2_completed,stage3Completed:f.stage_3_completed,assessmentCompleted:f.assessment_completed,techAssessmentPassed:f.tech_assessment_passed||!1,readyForTechAssessment:!1,startedAt:f.started_at,completedAt:f.completed_at}),f;const{data:p,error:m}=await me.from("xtern_assessments").insert({user_id:e.id,current_stage:1,stage_1_completed:!1,stage_2_completed:!1,stage_3_completed:!1,assessment_completed:!1,assessment_type:"onboarding"}).select().single();if(m)throw m;return i({id:p.id,currentStage:1,stage1Completed:!1,stage2Completed:!1,stage3Completed:!1,assessmentCompleted:!1,techAssessmentPassed:!1,readyForTechAssessment:!1,startedAt:p.started_at,completedAt:null}),p}catch(f){return console.error("Error creating assessment:",f),null}},l=async(f,p)=>{var m;if((m=r.data)!=null&&m.id)try{const g={current_stage:f,[`stage_${f}_completed`]:p},{error:b}=await me.from("xtern_assessments").update(g).eq("id",r.data.id);if(b)throw b;await n()}catch(g){console.error("Error updating assessment stage:",g)}},u=async(f,p,m)=>{if(e)try{const{error:g}=await me.rpc("complete_tech_assessment",{p_user_id:e.id,p_tech_assessment_id:f,p_passed:p,p_assessment_type:"onboarding",p_tech_stack_scores:m||null});if(g)throw g;await n()}catch(g){console.error("Error marking tech assessment complete:",g)}};return{assessmentStatus:r.data??null,isLoading:r.isPending&&!!e,error:r.error?r.error.message:null,createAssessment:a,updateAssessmentStage:l,markTechAssessmentComplete:u,refetchStatus:n}},_w=({featureName:e,message:t="Complete your assessment to unlock paid opportunities and stronger employer visibility."})=>{const{assessmentStatus:r}=ym(),n=()=>{if(!r)return"You haven't started your assessment yet.";const{stage1Completed:a,stage2Completed:l,stage3Completed:u}=r;return u?"Your assessment is almost complete! Just a few more steps.":l?"Great progress! You're on Stage 3 of your assessment.":a?"You're making progress! You're on Stage 2 of your assessment.":"You're on Stage 1 of your assessment."},i=()=>{if(!r)return 0;const{stage1Completed:a,stage2Completed:l,stage3Completed:u}=r;return u?100:l?75:a?50:25};return d.jsxs($s,{className:"border-warning bg-warning/5",children:[d.jsxs(Fs,{className:"pb-3",children:[d.jsxs("div",{className:"flex items-center space-x-2",children:[d.jsx(eP,{className:"w-5 h-5 text-warning"}),d.jsxs(Us,{className:"text-lg",children:[e," - Verification Required"]})]}),d.jsx(mm,{children:t})]}),d.jsxs(ko,{className:"space-y-4",children:[d.jsx("div",{className:"text-sm text-muted-foreground",children:n()}),d.jsx("div",{className:"w-full bg-secondary rounded-full h-2",children:d.jsx("div",{className:"bg-primary h-2 rounded-full transition-all duration-300",style:{width:`${i()}%`}})}),d.jsxs("div",{className:"flex justify-between items-center text-xs text-muted-foreground",children:[d.jsxs("div",{className:"flex items-center space-x-1",children:[r!=null&&r.stage1Completed?d.jsx(hu,{className:"w-3 h-3 text-success"}):d.jsx(lh,{className:"w-3 h-3"}),d.jsx("span",{children:"Experience"})]}),d.jsxs("div",{className:"flex items-center space-x-1",children:[r!=null&&r.stage2Completed?d.jsx(hu,{className:"w-3 h-3 text-success"}):d.jsx(lh,{className:"w-3 h-3"}),d.jsx("span",{children:"Bio Data"})]}),d.jsxs("div",{className:"flex items-center space-x-1",children:[r!=null&&r.stage3Completed?d.jsx(hu,{className:"w-3 h-3 text-success"}):d.jsx(lh,{className:"w-3 h-3"}),d.jsx("span",{children:"Skills"})]})]}),d.jsx("div",{className:"flex gap-2",children:d.jsx(bt,{asChild:!0,size:"sm",className:"flex-1",children:d.jsx(Lt,{to:"/assessment",children:r!=null&&r.id?"Continue Assessment":"Start Assessment"})})}),d.jsx("p",{className:"text-xs text-muted-foreground",children:"You can still build your profile and start simulations while this verification is in progress."})]})]})},Ih=768;function JL(){const[e,t]=v.useState(void 0);return v.useEffect(()=>{const r=window.matchMedia(`(max-width: ${Ih-1}px)`),n=()=>{t(window.innerWidth<Ih)};return r.addEventListener("change",n),t(window.innerWidth<Ih),()=>r.removeEventListener("change",n)},[]),!!e}const mS=v.forwardRef(({className:e,type:t,...r},n)=>d.jsx("input",{type:t,className:Pe("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:n,...r}));mS.displayName="Input";var XL=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ZL=XL.reduce((e,t)=>
404{const r=id(`Primitive.${t}`),n=v.forwardRef((i,a)=>{const{asChild:l,...u}=i,f=l?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(f,{...u,ref:a})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),eD="Separator",Sw="horizontal",tD=["horizontal","vertical"],gS=v.forwardRef((e,t)=>{const{decorative:r,orientation:n=Sw,...i}=e,a=rD(n)?n:Sw,u=r?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return d.jsx(ZL.div,{"data-orientation":a,...u,...i,ref:t})});gS.displayName=eD;function rD(e){return tD.includes(e)}var vS=gS;const yS=v.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...n},i)=>d.jsx(vS,{ref:i,decorative:r,orientation:t,className:Pe("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...n}));yS.displayName=vS.displayName;const nD=Z_,sD=eS,wS=v.forwardRef(({className:e,...t},r)=>d.jsx(td,{className:Pe("fixed inset-0 z-50 bg-black/80  data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));wS.displayName=td.displayName;const oD=_l("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4  border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),bS=v.forwardRef(({side:e="right",className:t,children:r,...n},i)=>d.jsxs(sD,{children:[d.jsx(wS,{}),d.jsxs(rd,{ref:i,className:Pe(oD({side:e}),t),...n,children:[r,d.jsxs(tS,{className:"absolute right-4 top-4 roun
404ded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[d.jsx(Hu,{className:"h-4 w-4"}),d.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));bS.displayName=rd.displayName;const iD=({className:e,...t})=>d.jsx("div",{className:Pe("flex flex-col space-y-2 text-center sm:text-left",e),...t});iD.displayName="SheetHeader";const aD=v.forwardRef(({className:e,...t},r)=>d.jsx(nd,{ref:r,className:Pe("text-lg font-semibold text-foreground",e),...t}));aD.displayName=nd.displayName;const lD=v.forwardRef(({className:e,...t},r)=>d.jsx(sd,{ref:r,className:Pe("text-sm text-muted-foreground",e),...t}));lD.displayName=sd.displayName;function Ew({className:e,...t}){return d.jsx("div",{className:Pe("animate-pulse rounded-md bg-muted",e),...t})}const cD=["top","right","bottom","left"],zs=Math.min,Cr=Math.max,Ou=Math.round,lu=Math.floor,Pn=e=>({x:e,y:e}),uD={left:"right",right:"left",bottom:"top",top:"bottom"};function Ap(e,t,r){return Cr(e,zs(t,r))}function Kn(e,t){return typeof e=="function"?e(t):e}function Gn(e){return e.split("-")[0]}function Xi(e){return e.split("-")[1]}function wm(e){return e==="x"?"y":"x"}function bm(e){return e==="y"?"height":"width"}function Rn(e){const t=e[0];return t==="t"||t==="b"?"y":"x"}function xm(e){return wm(Rn(e))}function dD(e,t,r){r===void 0&&(r=!1);const n=Xi(e),i=xm(e),a=bm(i);let l=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(l=Au(l)),[l,Au(l)]}function fD(e){const t=Au(e);return[Np(e),t,Np(t)]}function Np(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const kw=["left","right"],Tw=["right","left"],hD=["top","bottom"],pD=["bottom","top"];function mD(e,t,r){switch(e){case"top":case"bottom":return r?t?Tw:kw:t?kw:Tw;case"left":case"right":return t?hD:pD;default:return[]}}function gD(e,t,r,n){const i=Xi(e);let a=mD(Gn(e),r==="start",n);return i&&(a=a.map(l=>l+"-"+i),t&&(a=a.concat(a.map(Np)))),a}function Au(e){const t=Gn(e);return uD[t]+e.slice(t.length)}function vD(e){return{top:0,right:0,bottom:0,left:0,...e}}function xS(e){return typeof e!="number"?vD(e):{top:e,right:e,bottom:e,left:e}}function Nu(e){const{x:t,y:r,width:n,height:i}=e;return{width:n,height:i,top:r,left:t,right:t+n,bottom:r+i,x:t,y:r}}function Cw(e,t,r){let{reference:n,floating:i}=e;const a=Rn(t),l=xm(t),u=bm(l),f=Gn(t),p=a==="y",m=n.x+n.width/2-i.width/2,g=n.y+n.height/2-i.height/2,b=n[u]/2-i[u]/2;let w;switch(f){case"top":w={x:m,y:n.y-i.height};break;case"bottom":w={x:m,y:n.y+n.height};break;case"right":w={x:n.x+n.width,y:g};break;case"left":w={x:n.x-i.width,y:g};break;default:w={x:n.x,y:n.y}}switch(Xi(t)){case"start":w[l]-=b*(r&&p?-1:1);break;case"end":w[l]+=b*(r&&p?-1:1);break}return w}async function yD(e,t){var r;t===void 0&&(t={});const{x:n,y:i,platform:a,rects:l,elements:u,strategy:f}=e,{boundary:p="clippingAncestors",rootBoundary:m="viewport",elementContext:g="floating",altBoundary:b=!1,padding:w=0}=Kn(t,e),S=xS(w),E=u[b?g==="floating"?"reference":"floating":g],k=Nu(await a.getClippingRect({element:(r=await(a.isElement==null?void 0:a.isElement(E)))==null||r?E:E.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(u.floating)),boundary:p,rootBoundary:m,strategy:f})),T=g==="floating"?{x:n,y:i,width:l.floating.width,height:l.floating.height}:l.reference,R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u.floating)),P=await(a.isElement==null?void 0:a.isElement(R))?await(a.getScale==null?void 0:a.getScale(R))||{x:1,y:1}:{x:1,y:1},O=Nu(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:T,offsetParent:R,strategy:f}):T);return{top:(k.top-O.top+S.top)/P.y,bottom:(O.bottom-k.bottom+S.bottom)/P.y,left:(k.left-O.left+S.left)/P.x,right:(O.right-k.right+S.right)/P.x}}const wD=50,bD=async(e,t,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:a=[],platform:l}=r,u=l.detectOverflow?l:{...l,detectOverflow:yD},f=await(l.isRTL==null?void 0:l.isRTL(t));let p=await l.getElementRects({reference:e,floating:t,strategy:i}
vendor: 6,287 bytes, line 404
404),{x:m,y:g}=Cw(p,n,f),b=n,w=0;const S={};for(let _=0;_<a.length;_++){const E=a[_];if(!E)continue;const{name:k,fn:T}=E,{x:R,y:P,data:O,reset:I}=await T({x:m,y:g,initialPlacement:n,placement:b,strategy:i,middlewareData:S,rects:p,platform:u,elements:{reference:e,floating:t}});m=R??m,g=P??g,S[k]={...S[k],...O},I&&w<wD&&(w++,typeof I=="object"&&(I.placement&&(b=I.placement),I.rects&&(p=I.rects===!0?await l.getElementRects({reference:e,floating:t,strategy:i}):I.rects),{x:m,y:g}=Cw(p,b,f)),_=-1)}return{x:m,y:g,placement:b,strategy:i,middlewareData:S}},xD=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:i,rects:a,platform:l,elements:u,middlewareData:f}=t,{element:p,padding:m=0}=Kn(e,t)||{};if(p==null)return{};const g=xS(m),b={x:r,y:n},w=xm(i),S=bm(w),_=await l.getDimensions(p),E=w==="y",k=E?"top":"left",T=E?"bottom":"right",R=E?"clientHeight":"clientWidth",P=a.reference[S]+a.reference[w]-b[w]-a.floating[S],O=b[w]-a.reference[w],I=await(l.getOffsetParent==null?void 0:l.getOffsetParent(p));let M=I?I[R]:0;(!M||!await(l.isElement==null?void 0:l.isElement(I)))&&(M=u.floating[R]||a.floating[S]);const Y=P/2-O/2,ae=M/2-_[S]/2-1,he=zs(g[k],ae),Ee=zs(g[T],ae),ue=he,je=M-_[S]-Ee,le=M/2-_[S]/2+Y,Ae=Ap(ue,le,je),Te=!f.arrow&&Xi(i)!=null&&le!==Ae&&a.reference[S]/2-(le<ue?he:Ee)-_[S]/2<0,re=Te?le<ue?le-ue:le-je:0;return{[w]:b[w]+re,data:{[w]:Ae,centerOffset:le-Ae-re,...Te&&{alignmentOffset:re}},reset:Te}}}),_D=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:i,middlewareData:a,rects:l,initialPlacement:u,platform:f,elements:p}=t,{mainAxis:m=!0,crossAxis:g=!0,fallbackPlacements:b,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:_=!0,...E}=Kn(e,t);if((r=a.arrow)!=null&&r.alignmentOffset)return{};const k=Gn(i),T=Rn(u),R=Gn(u)===u,P=await(f.isRTL==null?void 0:f.isRTL(p.floating)),O=b||(R||!_?[Au(u)]:fD(u)),I=S!=="none";!b&&I&&O.push(...gD(u,_,S,P));const M=[u,...O],Y=await f.detectOverflow(t,E),ae=[];let he=((n=a.flip)==null?void 0:n.overflows)||[];if(m&&ae.push(Y[k]),g){const le=dD(i,l,P);ae.push(Y[le[0]],Y[le[1]])}if(he=[...he,{placement:i,overflows:ae}],!ae.every(le=>le<=0)){var Ee,ue;const le=(((Ee=a.flip)==null?void 0:Ee.index)||0)+1,Ae=M[le];if(Ae&&(!(g==="alignment"?T!==Rn(Ae):!1)||he.every(z=>Rn(z.placement)===T?z.overflows[0]>0:!0)))return{data:{index:le,overflows:he},reset:{placement:Ae}};let Te=(ue=he.filter(re=>re.overflows[0]<=0).sort((re,z)=>re.overflows[1]-z.overflows[1])[0])==null?void 0:ue.placement;if(!Te)switch(w){case"bestFit":{var je;const re=(je=he.filter(z=>{if(I){const W=Rn(z.placement);return W===T||W==="y"}return!0}).map(z=>[z.placement,z.overflows.filter(W=>W>0).reduce((W,K)=>W+K,0)]).sort((z,W)=>z[1]-W[1])[0])==null?void 0:je[0];re&&(Te=re);break}case"initialPlacement":Te=u;break}if(i!==Te)return{reset:{placement:Te}}}return{}}}};function Rw(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Pw(e){return cD.some(t=>e[t]>=0)}const SD=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r,platform:n}=t,{strategy:i="referenceHidden",...a}=Kn(e,t);switch(i){case"referenceHidden":{const l=await n.detectOverflow(t,{...a,elementContext:"reference"}),u=Rw(l,r.reference);return{data:{referenceHiddenOffsets:u,referenceHidden:Pw(u)}}}case"escaped":{const l=await n.detectOverflow(t,{...a,altBoundary:!0}),u=Rw(l,r.floating);return{data:{escapedOffsets:u,escaped:Pw(u)}}}default:return{}}}}},_S=new Set(["left","top"]);async function ED(e,t){const{placement:r,platform:n,elements:i}=e,a=await(n.isRTL==null?void 0:n.isRTL(i.floating)),l=Gn(r),u=Xi(r),f=Rn(r)==="y",p=_S.has(l)?-1:1,m=a&&f?-1:1,g=Kn(t,e);let{mainAxis:b,crossAxis:w,alignmentAxis:S}=typeof g=="number"?{mainAxis:g,crossAxis:0,alignmentAxis:null}:{mainAxis:g.mainAxis||0,crossAxis:g.crossAxis||0,alignmentAxis:g.alignmentAxis};return u&&typeof S=="number"&&(w=u==="end"?S*-1:S),f?{x:w*m,y:b*p}:{x:b*p,y:w*m}}const kD=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:i,y:a,placement:l,middlewareData:u}=t,f=await ED(t,e);return l===((r=u.offset)==null?void 0:r.placement)&&(n=u.arrow)!=null&&n.alignmentOffset?{}:{x:i+f.x,y:a+f.y,data:{...f,placement:l}}}}},TD=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:i,platform:a}=t,{mainAxis:l=!0,crossAxis:u=!1,limiter:f={fn:k=>{let{x:T,y:R}=k;return{x:T,y:R}}},...p}=Kn(e,t),m={x:r,y:n},g=await a.detectOverflow(t,p),b=Rn(Gn(i)),w=wm(b);let S=m[w],_=m[b];if(l){const k=w==="y"?"top":"left",T=w==="y"?"bottom":"right",R=S+g[k],P=S-g[T];S=Ap(R,S,P)}if(u){const k=b==="y"?"top":"left",T=b==="y"?"bottom":"right",R=_+g[k],P=_-g[T];_=Ap(R,_,P)}const E=f.fn({...t,[w]:S,[b]:_});return{...E,data:{x:E.x-r,y:E.y-n,enabled:{[w]:l,[b]:u}}}}}},CD=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:i,rects:a,middlewareData:l}=t,{offset:u=0,mainAxis:f=!0,crossAxis:p=!0}=Kn(e,t),m={x:r,y:n},g=Rn(i),b=wm(g);let w=m[b],S=m[g];const _=Kn(u,t),E=typeof _=="number"?{mainAxis:_,crossAxis:0}:{mainAxis:0,crossAxis:0,..._};if(f){const R=b==="y"?"height":"width",P=a.reference[b]-a.floating[R]+E.mainAxis,O=a.reference[b]+a.reference[R]-E.mainAxis;w<P?w=P:w>O&&(w=O)}if(p){var k,T;const R=b==="y"?"width":"height",P=_S.has(Gn(i)),O=a.reference[g]-a.floating[R]+(P&&((k=l.offset)==null?void 0:k[g])||0)+(P?0:E.crossAxis),I=a.reference[g]+a.reference[R]+(P?0:((T=l.offset)==null?void 0:T[g])||0)-(P?E.crossAxis:0);S<O?S=O:S>I&&(S=I)}return{[b]:w,[g]:S}}}},RD=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:i,rects:a,platform:l,elements:u}=t,{apply:f=()=>{},...p}=Kn(e,t),m=await l.detectOverflow(t,p),g=Gn(i),b=Xi(i),w=Rn(i)==="y",{width:S,height:_}=a.floating;let E,k;g==="top"||g==="bottom"?(E=g,k=b===(await(l.isRTL==null?void 0:l.isRTL(u.floating))?"start":"end")?"left":"right"):(k=g,E=b==="end"?"top":"bottom");const T=_-m.top-m.bottom,R=S-m.left-m.right,P=zs(_-m[E],T),O=zs(S-m[k],R),I=!t.middlewareData.shift;let M=P,Y=O;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(Y=R),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(M=T),I&&!b){const he=Cr(m.left,0),Ee=Cr(m.right,0),ue=Cr(m.top,0),je=Cr
vendor: 17,822 bytes, line 404
404(m.bottom,0);w?Y=S-2*(he!==0||Ee!==0?he+Ee:Cr(m.left,m.right)):M=_-2*(ue!==0||je!==0?ue+je:Cr(m.top,m.bottom))}await f({...t,availableWidth:Y,availableHeight:M});const ae=await l.getDimensions(u.floating);return S!==ae.width||_!==ae.height?{reset:{rects:!0}}:{}}}};function ld(){return typeof window<"u"}function Zi(e){return SS(e)?(e.nodeName||"").toLowerCase():"#document"}function Pr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function jn(e){var t;return(t=(SS(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function SS(e){return ld()?e instanceof Node||e instanceof Pr(e).Node:!1}function nn(e){return ld()?e instanceof Element||e instanceof Pr(e).Element:!1}function Yn(e){return ld()?e instanceof HTMLElement||e instanceof Pr(e).HTMLElement:!1}function jw(e){return!ld()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Pr(e).ShadowRoot}function Ol(e){const{overflow:t,overflowX:r,overflowY:n,display:i}=sn(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&i!=="inline"&&i!=="contents"}function PD(e){return/^(table|td|th)$/.test(Zi(e))}function cd(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const jD=/transform|translate|scale|rotate|perspective|filter/,OD=/paint|layout|strict|content/,io=e=>!!e&&e!=="none";let Lh;function _m(e){const t=nn(e)?sn(e):e;return io(t.transform)||io(t.translate)||io(t.scale)||io(t.rotate)||io(t.perspective)||!Sm()&&(io(t.backdropFilter)||io(t.filter))||jD.test(t.willChange||"")||OD.test(t.contain||"")}function AD(e){let t=Bs(e);for(;Yn(t)&&!zi(t);){if(_m(t))return t;if(cd(t))return null;t=Bs(t)}return null}function Sm(){return Lh==null&&(Lh=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Lh}function zi(e){return/^(html|body|#document)$/.test(Zi(e))}function sn(e){return Pr(e).getComputedStyle(e)}function ud(e){return nn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Bs(e){if(Zi(e)==="html")return e;const t=e.assignedSlot||e.parentNode||jw(e)&&e.host||jn(e);return jw(t)?t.host:t}function ES(e){const t=Bs(e);return zi(t)?e.ownerDocument?e.ownerDocument.body:e.body:Yn(t)&&Ol(t)?t:ES(t)}function dl(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const i=ES(e),a=i===((n=e.ownerDocument)==null?void 0:n.body),l=Pr(i);if(a){const u=Ip(l);return t.concat(l,l.visualViewport||[],Ol(i)?i:[],u&&r?dl(u):[])}else return t.concat(i,dl(i,[],r))}function Ip(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function kS(e){const t=sn(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const i=Yn(e),a=i?e.offsetWidth:r,l=i?e.offsetHeight:n,u=Ou(r)!==a||Ou(n)!==l;return u&&(r=a,n=l),{width:r,height:n,$:u}}function Em(e){return nn(e)?e:e.contextElement}function Si(e){const t=Em(e);if(!Yn(t))return Pn(1);const r=t.getBoundingClientRect(),{width:n,height:i,$:a}=kS(t);let l=(a?Ou(r.width):r.width)/n,u=(a?Ou(r.height):r.height)/i;return(!l||!Number.isFinite(l))&&(l=1),(!u||!Number.isFinite(u))&&(u=1),{x:l,y:u}}const ND=Pn(0);function TS(e){const t=Pr(e);return!Sm()||!t.visualViewport?ND:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function ID(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==Pr(e)?!1:t}function To(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const i=e.getBoundingClientRect(),a=Em(e);let l=Pn(1);t&&(n?nn(n)&&(l=Si(n)):l=Si(e));const u=ID(a,r,n)?TS(a):Pn(0);let f=(i.left+u.x)/l.x,p=(i.top+u.y)/l.y,m=i.width/l.x,g=i.height/l.y;if(a){const b=Pr(a),w=n&&nn(n)?Pr(n):n;let S=b,_=Ip(S);for(;_&&n&&w!==S;){const E=Si(_),k=_.getBoundingClientRect(),T=sn(_),R=k.left+(_.clientLeft+parseFloat(T.paddingLeft))*E.x,P=k.top+(_.clientTop+parseFloat(T.paddingTop))*E.y;f*=E.x,p*=E.y,m*=E.x,g*=E.y,f+=R,p+=P,S=Pr(_),_=Ip(S)}}return Nu({width:m,height:g,x:f,y:p})}function dd(e,t){const r=ud(e).scrollLeft;return t?t.left+r:To(jn(e)).left+r}function CS(e,t){const r=e.getBoundingClientRect(),n=r.left+t.scrollLeft-dd(e,r),i=r.top+t.scrollTop;return{x:n,y:i}}function LD(e){let{elements:t,rect:r,offsetParent:n,strategy:i}=e;const a=i==="fixed",l=jn(n),u=t?cd(t.floating):!1;if(n===l||u&&a)return r;let f={scrollLeft:0,scrollTop:0},p=Pn(1);const m=Pn(0),g=Yn(n);if((g||!g&&!a)&&((Zi(n)!=="body"||Ol(l))&&(f=ud(n)),g)){const w=To(n);p=Si(n),m.x=w.x+n.clientLeft,m.y=w.y+n.clientTop}const b=l&&!g&&!a?CS(l,f):Pn(0);return{width:r.width*p.x,height:r.height*p.y,x:r.x*p.x-f.scrollLeft*p.x+m.x+b.x,y:r.y*p.y-f.scrollTop*p.y+m.y+b.y}}function DD(e){return Array.from(e.getClientRects())}function MD(e){const t=jn(e),r=ud(e),n=e.ownerDocument.body,i=Cr(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),a=Cr(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let l=-r.scrollLeft+dd(e);const u=-r.scrollTop;return sn(n).direction==="rtl"&&(l+=Cr(t.clientWidth,n.clientWidth)-i),{width:i,height:a,x:l,y:u}}const Ow=25;function $D(e,t){const r=Pr(e),n=jn(e),i=r.visualViewport;let a=n.clientWidth,l=n.clientHeight,u=0,f=0;if(i){a=i.width,l=i.height;const m=Sm();(!m||m&&t==="fixed")&&(u=i.offsetLeft,f=i.offsetTop)}const p=dd(n);if(p<=0){const m=n.ownerDocument,g=m.body,b=getComputedStyle(g),w=m.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,S=Math.abs(n.clientWidth-g.clientWidth-w);S<=Ow&&(a-=S)}else p<=Ow&&(a+=p);return{width:a,height:l,x:u,y:f}}function FD(e,t){const r=To(e,!0,t==="fixed"),n=r.top+e.clientTop,i=r.left+e.clientLeft,a=Yn(e)?Si(e):Pn(1),l=e.clientWidth*a.x,u=e.clientHeight*a.y,f=i*a.x,p=n*a.y;return{width:l,height:u,x:f,y:p}}function Aw(e,t,r){let n;if(t==="viewport")n=$D(e,r);else if(t==="document")n=MD(jn(e));else if(nn(t))n=FD(t,r);else{const i=TS(e);n={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Nu(n)}function RS(e,t){const r=Bs(e);return r===t||!nn(r)||zi(r)?!1:sn(r).position==="fixed"||RS(r,t)}function UD(e,t){const r=t.get(e);if(r)return r;let n=dl(e,[],!1).filter(u=>nn(u)&&Zi(u)!=="body"),i=null;const a=sn(e).position==="fixed";let l=a?Bs(e):e;for(;nn(l)&&!zi(l);){const u=sn(l),f=_m(l);!f&&u.position==="fixed"&&(i=null),(a?!f&&!i:!f&&u.position==="static"&&!!i&&(i.position==="absolute"||i.position==="fixed")||Ol(l)&&!f&&RS(e,l))?n=n.filter(m=>m!==l):i=u,l=Bs(l)}return t.set(e,n),n}function zD(e){let{element:t,boundary:r,rootBoundary:n,strategy:i}=e;const l=[...r==="clippingAncestors"?cd(t)?[]:UD(t,this._c):[].concat(r),n],u=Aw(t,l[0],i);let f=u.top,p=u.right,m=u.bottom,g=u.left;for(let b=1;b<l.length;b++){const w=Aw(t,l[b],i);f=Cr(w.top,f),p=zs(w.right,p),m=zs(w.bottom,m),g=Cr(w.left,g)}return{width:p-g,height:m-f,x:g,y:f}}function BD(e){const{width:t,height:r}=kS(e);return{width:t,height:r}}function qD(e,t,r){const n=Yn(t),i=jn(t),a=r==="fixed",l=To(e,!0,a,t);let u={scrollLeft:0,scrollTop:0};const f=Pn(0);function p(){f.x=dd(i)}if(n||!n&&!a)if((Zi(t)!=="body"||Ol(i))&&(u=ud(t)),n){const w=To(t,!0,a,t);f.x=w.x+t.clientLeft,f.y=w.y+t.clientTop}else i&&p();a&&!n&&i&&p();const m=i&&!n&&!a?CS(i,u):Pn(0),g=l.left+u.scrollLeft-f.x-m.x,b=l.top+u.scrollTop-f.y-m.y;return{x:g,y:b,width:l.width,height:l.height}}function Dh(e){return sn(e).position==="static"}function Nw(e,t){if(!Yn(e)||sn(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return jn(e)===r&&(r=r.ownerDocument.body),r}function PS(e,t){const r=Pr(e);if(cd(e))return r;if(!Yn(e)){let i=Bs(e);for(;i&&!zi(i);){if(nn(i)&&!Dh(i))return i;i=Bs(i)}return r}let n=Nw(e,t);for(;n&&PD(n)&&Dh(n);)n=Nw(n,t);return n&&zi(n)&&Dh(n)&&!_m(n)?r:n||AD(e)||r}const VD=async function(e){const t=this.getOffsetParent||PS,r=this.getDimensions,n=await r(e.floating);return{reference:qD(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function WD(e){return sn(e).direction==="rtl"}const HD={convertOffsetParentRelativeRectToViewportRelativeRect:LD,getDocumentElement:jn,getClippingRect:zD,getOffsetParent:PS,getElementRects:VD,getClientRects:DD,getDimensions:BD,getScale:Si,isElement:nn,isRTL:WD};function jS(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function KD(e,t){let r=null,n;const i=jn(e);function a(){var u;clearTimeout(n),(u=r)==null||u.disconnect(),r=null}function l(u,f){u===void 0&&(u=!1),f===void 0&&(f=1),a();const p=e.getBoundingClientRect(),{left:m,top:g,width:b,height:w}=p;if(u||t(),!b||!w)return;const S=lu(g),_=lu(i.clientWidth-(m+b)),E=lu(i.clientHeight-(g+w)),k=lu(m),R={rootMargin:-S+"px "+-_+"px "+-E+"px "+-k+"px",threshold:Cr(0,zs(1,f))||1};let P=!0;function O(I){const M=I[0].intersectionRatio;if(M!==f){if(!P)return l();M?l(!1,M):n=setTimeout(()=>{l(!1,1e-7)},1e3)}M===1&&!jS(p,e.getBoundingClientRect())&&l(),P=!1}try{r=new IntersectionObserver(O,{...R,root:i.ownerDocument})}catch{r=new IntersectionObserver(O,R)}r.observe(e)}return l(!0),a}function GD(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:u=typeof IntersectionObserver=="function",animationFrame:f=!1}=n,p=Em(e),m=i||a?[...p?dl(p):[],...t?dl(t):[]]:[];m.forEach(k=>{i&&k.addEventListener("scroll",r,{passive:!0}),a&&k.addEventListener("resize",r)});const g=p&&u?KD(p,r):null;let b=-1,w=null;l&&(w=new ResizeObserver(k=>{let[T]=k;T&&T.target===p&&w&&t&&(w.unobserve(t),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var R;(R=w)==null||R.observe(t)})),r()}),p&&!f&&w.observe(p),t&&w.observe(t));let S,_=f?To(e):null;f&&E();function E(){const k=To(e);_&&!jS(_,k)&&r(),_=k,S=requestAnimationFrame(E)}return r(),()=>{var k;m.forEach(T=>{i&&T.removeEventListener("scroll",r),a&&T.removeEventListener("resize",r)}),g==null||g(),(k=w)==null||k.disconnect(),w=null,f&&cancelAnimationFrame(S)}}const QD=kD,YD=TD,JD=_D,XD=RD,ZD=SD,Iw=xD,eM=CD,tM=(e,t,r)=>{const n=new Map,i={platform:HD,...r},a={...i.platform,_c:n};return bD(e,t,{...i,platform:a})};var rM=typeof document<"u",nM=function(){},wu=rM?v.useLayoutEffect:nM;function Iu(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,n,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!Iu(e[n],t[n]))return!1;return!0}if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,i[n]))return!1;for(n=r;n--!==0;){const a=i[n];if(!(a==="_owner"&&e.$$typeof)&&!Iu(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function OS(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Lw(e,t){const r=OS(e);return Math.round(t*r)/r}function Mh(e){const t=v.useRef(e);return wu(()=>{t.current=e}),t}function sM(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:i,elements:{reference:a,floating:l}={},transform:u=!0,whileElementsMounted:f,open:p}=e,[m,g]=v.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[b,w]=v.useState(n);Iu(b,n)||w(n);const[S,_]=v.useState(null),[E,k]=v.useState(null),T=v.useCallback(z=>{z!==I.current&&(I.current=z,_(z))},[]),R=v.useCallback(z=>{z!==M.current&&(M.current=z,k(z))},[]),P=a||S,O=l||E,I=v.useRef(null),M=v.useRef(null),Y=v.useRef(m),ae=f!=null,he=Mh(f),Ee=Mh(i),ue=Mh(p),je=v.useCallback(()=>{if(!I.current||!M.current)return;const z={placement:t,strategy:r,middleware:b};Ee.current&&(z.platform=Ee.current),tM(I.current,M.current,z).then(W=>{const K={...W,isPositioned:ue.current!==!1};le.current&&!Iu(Y.current,K)&&(Y.current=K,Is.flushSync(()=>{g(K)}))})},[b,t,r,Ee,ue]);wu(()=>{p===!1&&Y.current.isPositioned&&(Y.current.isPositioned=!1,g(z=>({...z,isPositioned:!1})))},[p]);const le=v.useRef(!1);wu(()=>(le.current=!0,()=>{le.current=!1}),[]),wu(()=>{if(P&&(I.current=P),O&&(M.current=O),P&&O){if(he.current)return he.current(P,O,je);je()}},[P,O,je,he,ae]);const Ae=v.useMemo(()=>({reference:I,floating:M,setReference:T,setFloating:R}),[T,R]),Te=v.useMemo(()=>({reference:P,floating:O}),[P,O]),re=v.useMemo(()=>{const z={position:r,left:0,top:0};if(!Te.floating)return z;const W=Lw(Te.floating,m.x),K=Lw(Te.floating,m.y);return u?{...z,transform:"translate("+W+"px, "+K+"px)",...OS(Te.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:W,top:K}},[r,u,Te.floating,m.x,m.y]);return v.useMemo(()=>({...m,update:je,refs:Ae,elements:Te,floatingStyles:re}),[m,je,Ae,Te,re])}const oM=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:i}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Iw({element:n.current,padding:i}).fn(r):{}:n?Iw({element:n,padding:i}).fn(r):{}}}},iM=(e,t)=>{const r=QD(e);return{name:r.name,fn:r.fn,options:[e,t]}},aM=(e,t)=>{const r=YD(e);return{name:r.name,fn:r.fn,options:[e,t]}},lM=(e,t)=>({fn:eM(e).fn,options:[e,t]}),cM=(e,t)=>{const r=JD(e);return{name:r.name,fn:r.fn,options:[e,t]}},uM=(e,t)=>{const r=XD(e);return{name:r.name,fn:r.fn,options:[e,t]}},dM=(e,t)=>{const r=ZD(e);return{name:r.name,fn:r.fn,options:[e,t]}},fM=(e,t)=>{const r=oM(e);return{name:r.name,fn:r.fn,options:[e,t]}};var hM="Arrow",AS=v.forwardRef((e,t)=>{const{children:r,width:n=10,height:i=5,...a}=e;return d.jsx(xt.svg,{...a,ref:t,width:n,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:d.jsx("polygon",{points:"0,0 30,0 15,10"})})});AS.displayName=hM;var pM=AS,km="Popper",[NS,IS]=Vi(km),[mM,LS]=NS(km),DS=e=>{const{__scopePopper:t,children:r}=e,[n,i]=v.useState(null);return d.jsx(mM,{scope:t,anchor:n,onAnchorChange:i,children:r})};DS.displayName=km;var MS="PopperAnchor",$S=v.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...i}=e,a=LS(MS,r),l=v.useRef(null),u=Gt(t,l),f=v.useRef(null);return v.useEffect(()=>{const p=f.current;f.current=(n==null?void 0:n.current)||l.current,p!==f.current&&a.onAnchorChange(f.current)}),n?null:d.jsx(xt.div,{...i,ref:u})});$S.displayName=MS;var Tm="PopperContent",[gM,vM]=NS(Tm),FS=v.forwardRef((e,t)=>{var Re,Ve,Qe,F,oe,J;const{__scopePopper:r,side:n="bottom",sideOffset:i=0,align:a="center",alignOffset:l=0,arrowPadding:u=0,avoidCollisions:f=!0,collisionBoundary:p=[],collisionPadding:m=0,sticky:g="partial",hideWhenDetached:b=!1,updatePositionStrategy:w="optimized",onPlaced:S,..._}=e,E=LS(Tm,r),[k,T]=v.useState(null),R=Gt(t,Z=>T(Z)),[P,O]=v.useState(null),I=oS(P),M=(I==null?void 0:I.width)??0,Y=(I==null?void 0:I.height)??0,ae=n+(a!=="center"?"-"+a:""),he=typeof m=="number"?m:{top:0,right:0,bottom:0,left:0,...m},Ee=Array.isArray(p)?p:[p],ue=Ee.length>0,je={padding:he,boundary:Ee.filter(wM),altBoundary:ue},{refs:le,floatingStyles:Ae,placement:Te,isPositioned:re,middlewareData:z}=sM({strategy:"fixed",placement:ae,whileElementsMounted:(...Z)=>GD(...Z,{animationFrame:w==="always"}),elements:{reference:E.anchor},middleware:[iM({mainAxis:i+Y,alignmentAxis:l}),f&&aM({mainAxis:!0,crossAxis:!1,limiter:g==="partial"?lM():void 0,...je}),f&&cM({...je}),uM({...je,apply:({elements:Z,rects:pe,availableWidth:ne,availableHeight:ot})=>{const{width:Tt,height:vt}=pe.reference,Be=Z.floating.style;Be.setProperty("--radix-popper-available-width",`${ne}px`),Be.setProperty("--radix-popper-available-height",`${ot}px`),Be.setProperty("--radix-popper-anchor-width",`${Tt}px`),Be.setProperty("--radix-popper-anchor-height",`${vt}px`)}}),P&&fM({element:P,padding:u}),bM({arrowWidth:M,arrowHeight:Y}),b&&dM({strategy:"referenceHidden",...je})]}),[W,K]=BS(Te),N=rn(S);Fr(()=>{re&&(N==null||N())},[re,N]);const U=(Re=z.arrow)==null?void 0:Re.x,X=(Ve=z.arrow)==null?void 0:Ve.y,fe=((Qe=z.arrow)==null?void 0:Qe.centerOffset)!==0,[Oe,Fe]=v.useState();return Fr(()=>{k&&Fe(window.getComputedStyle(k).zIndex)},[k]),d.jsx("div",{ref:le.setFloating,"data-radix-popper-content-wrapper":"",style:{...Ae,transform:re?Ae.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Oe,"--radix-popper-transform-origin":[(F=z.transformOrigin)==null?void 0:F.x,(oe=z.transformOrigin)==null?void 0:oe.y].join(" "),...((J=z.hide)==null?void 0:J.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:d.jsx(gM,{scope:r,placedSide:W,onArrowChange:O,arrowX:U,arrowY:X,shouldHideArrow:fe,children:d.jsx(xt.div,{"data-side":W,"data-align":K,..._,ref:R,style:{..._.style,animation:re?void 0:"none"}})})})});FS.displayName=Tm;var US="PopperArrow",yM={top:"bottom",right:"left",bottom:"top",left:"right"},zS=v.forwardRef(function(t,r){const{__scopePopper:n,...i}=t,a=vM(US,n),l=yM[a.placedSide];return d.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[l]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:d.jsx(pM,{...i,ref:r,style:{...i.style,display:"block"}})})});zS.displayName=US;function wM(e){return e!==null}var bM=e=>({name:"transformOrigin",options:e,fn(t){var E,k,T;const{placement:r,rects:n,middlewareData:i}=t,l=((E=i.arrow)==null?void 0:E.centerOffset)!==0,u=l?0:e.arrowWidth,f=l?0:e.arrowHeight,[p,m]=BS(r),g={start:"0%",center:"50%",end:"100%"}[m],b=(((k=i.arrow)==null?void 0:k.x)??0)+u/2,w=(((T=i.arrow)==null?void 0:T.y)??0)+f/2;let S="",_="";return p==="bottom"?(S=l?g:`${b}px`,_=`${-f}px`):p==="top"?(S=l?g:`${b}px`,_=`${n.floating.height+f}px`):p==="right"?(S=`${-f}px`,_=l?g:`${w}px`):p==="left"&&(S=`${n.floating.width+f}px`,_=l?g:`${w}px`),{data:{x:S,y:_}}}});function BS(e){const[t,r="center"]=e.split("-");return[t,r]}var xM=DS,_M=$S,SM=FS,EM=zS,kM=Symbol("radix.slottable");function TM(e){const t=({children:r})=>d.jsx(d.Fragment,{children:r});return t.displayName=`${e}.Slottable`,t.__radixId=kM,t}
vendor: 8,356 bytes, line 404
404var[fd]=Vi("Tooltip",[IS]),hd=IS(),qS="TooltipProvider",CM=700,Lp="tooltip.open",[RM,Cm]=fd(qS),VS=e=>{const{__scopeTooltip:t,delayDuration:r=CM,skipDelayDuration:n=300,disableHoverableContent:i=!1,children:a}=e,l=v.useRef(!0),u=v.useRef(!1),f=v.useRef(0);return v.useEffect(()=>{const p=f.current;return()=>window.clearTimeout(p)},[]),d.jsx(RM,{scope:t,isOpenDelayedRef:l,delayDuration:r,onOpen:v.useCallback(()=>{window.clearTimeout(f.current),l.current=!1},[]),onClose:v.useCallback(()=>{window.clearTimeout(f.current),f.current=window.setTimeout(()=>l.current=!0,n)},[n]),isPointerInTransitRef:u,onPointerInTransitChange:v.useCallback(p=>{u.current=p},[]),disableHoverableContent:i,children:a})};VS.displayName=qS;var fl="Tooltip",[PM,pd]=fd(fl),WS=e=>{const{__scopeTooltip:t,children:r,open:n,defaultOpen:i,onOpenChange:a,disableHoverableContent:l,delayDuration:u}=e,f=Cm(fl,e.__scopeTooltip),p=hd(t),[m,g]=v.useState(null),b=gu(),w=v.useRef(0),S=l??f.disableHoverableContent,_=u??f.delayDuration,E=v.useRef(!1),[k,T]=qu({prop:n,defaultProp:i??!1,onChange:M=>{M?(f.onOpen(),document.dispatchEvent(new CustomEvent(Lp))):f.onClose(),a==null||a(M)},caller:fl}),R=v.useMemo(()=>k?E.current?"delayed-open":"instant-open":"closed",[k]),P=v.useCallback(()=>{window.clearTimeout(w.current),w.current=0,E.current=!1,T(!0)},[T]),O=v.useCallback(()=>{window.clearTimeout(w.current),w.current=0,T(!1)},[T]),I=v.useCallback(()=>{window.clearTimeout(w.current),w.current=window.setTimeout(()=>{E.current=!0,T(!0),w.current=0},_)},[_,T]);return v.useEffect(()=>()=>{w.current&&(window.clearTimeout(w.current),w.current=0)},[]),d.jsx(xM,{...p,children:d.jsx(PM,{scope:t,contentId:b,open:k,stateAttribute:R,trigger:m,onTriggerChange:g,onTriggerEnter:v.useCallback(()=>{f.isOpenDelayedRef.current?I():P()},[f.isOpenDelayedRef,I,P]),onTriggerLeave:v.useCallback(()=>{S?O():(window.clearTimeout(w.current),w.current=0)},[O,S]),onOpen:P,onClose:O,disableHoverableContent:S,children:r})})};WS.displayName=fl;var Dp="TooltipTrigger",HS=v.forwardRef((e,t)=>{const{__scopeTooltip:r,...n}=e,i=pd(Dp,r),a=Cm(Dp,r),l=hd(r),u=v.useRef(null),f=Gt(t,u,i.onTriggerChange),p=v.useRef(!1),m=v.useRef(!1),g=v.useCallback(()=>p.current=!1,[]);return v.useEffect(()=>()=>document.removeEventListener("pointerup",g),[g]),d.jsx(_M,{asChild:!0,...l,children:d.jsx(xt.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...n,ref:f,onPointerMove:ut(e.onPointerMove,b=>{b.pointerType!=="touch"&&!m.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),m.current=!0)}),onPointerLeave:ut(e.onPointerLeave,()=>{i.onTriggerLeave(),m.current=!1}),onPointerDown:ut(e.onPointerDown,()=>{i.open&&i.onClose(),p.current=!0,document.addEventListener("pointerup",g,{once:!0})}),onFocus:ut(e.onFocus,()=>{p.current||i.onOpen()}),onBlur:ut(e.onBlur,i.onClose),onClick:ut(e.onClick,i.onClose)})})});HS.displayName=Dp;var jM="TooltipPortal",[MU,OM]=fd(jM,{forceMount:void 0}),Bi="TooltipContent",KS=v.forwardRef((e,t)=>{const r=OM(Bi,e.__scopeTooltip),{forceMount:n=r.forceMount,side:i="top",...a}=e,l=pd(Bi,e.__scopeTooltip);return d.jsx(Oo,{present:n||l.open,children:l.disableHoverableContent?d.jsx(GS,{side:i,...a,ref:t}):d.jsx(AM,{side:i,...a,ref:t})})}),AM=v.forwardRef((e,t)=>{const r=pd(Bi,e.__scopeTooltip),n=Cm(Bi,e.__scopeTooltip),i=v.useRef(null),a=Gt(t,i),[l,u]=v.useState(null),{trigger:f,onClose:p}=r,m=i.current,{onPointerInTransitChange:g}=n,b=v.useCallback(()=>{u(null),g(!1)},[g]),w=v.useCallback((S,_)=>{const E=S.currentTarget,k={x:S.clientX,y:S.clientY},T=MM(k,E.getBoundingClientRect()),R=$M(k,T),P=FM(_.getBoundingClientRect()),O=zM([...R,...P]);u(O),g(!0)},[g]);return v.useEffect(()=>()=>b(),[b]),v.useEffect(()=>{if(f&&m){const S=E=>w(E,m),_=E=>w(E,f);return f.addEventListener("pointerleave",S),m.addEventListener("pointerleave",_),()=>{f.removeEventListener("pointerleave",S),m.removeEventListener("pointerleave",_)}}},[f,m,w,b]),v.useEffect(()=>{if(l){const S=_=>{const E=_.target,k={x:_.clientX,y:_.clientY},T=(f==null?void 0:f.contains(E))||(m==null?void 0:m.contains(E)),R=!UM(k,l);T?b():R&&(b(),p())};return document.addEventListener("pointermove",S),()=>document.removeEventListener("pointermove",S)}},[f,m,l,p,b]),d.jsx(GS,{...e,ref:a})}),[NM,IM]=fd(fl,{isInside:!1}),LM=TM("TooltipContent"),GS=v.forwardRef((e,t)=>{const{__scopeTooltip:r,children:n,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:l,...u}=e,f=pd(Bi,r),p=hd(r),{onClose:m}=f;return v.useEffect(()=>(document.addEventListener(Lp,m),()=>document.removeEventListener(Lp,m)),[m]),v.useEffect(()=>{if(f.trigger){const g=b=>{const w=b.target;w!=null&&w.contains(f.trigger)&&m()};return window.addEventListener("scroll",g,{capture:!0}),()=>window.removeEventListener("scroll",g,{capture:!0})}},[f.trigger,m]),d.jsx(Bu,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:g=>g.preventDefault(),onDismiss:m,children:d.jsxs(SM,{"data-state":f.stateAttribute,...p,...u,ref:t,style:{...u.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[d.jsx(LM,{children:n}),d.jsx(NM,{scope:r,isInside:!0,children:d.jsx(TR,{id:f.contentId,role:"tooltip",children:i||n})})]})})});KS.displayName=Bi;var QS="TooltipArrow",DM=v.forwardRef((e,t)=>{const{__scopeTooltip:r,...n}=e,i=hd(r);return IM(QS,r).isInside?null:d.jsx(EM,{...i,...n,ref:t})});DM.displayName=QS;function MM(e,t){const r=Math.abs(t.top-e.y),n=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(r,n,i,a)){case a:return"left";case i:return"right";case r:return"top";case n:return"bottom";default:throw new Error("unreachable")}}function $M(e,t,r=5){const n=[];switch(t){case"top":n.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":n.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":n.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":n.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return n}function FM(e){const{top:t,right:r,bottom:n,left:i}=e;return[{x:i,y:t},{x:r,y:t},{x:r,y:n},{x:i,y:n}]}function UM(e,t){const{x:r,y:n}=e;let i=!1;for(let a=0,l=t.length-1;a<t.length;l=a++){const u=t[a],f=t[l],p=u.x,m=u.y,g=f.x,b=f.y;m>n!=b>n&&r<(g-p)*(n-m)/(b-m)+p&&(i=!i)}return i}function zM(e){const t=e.slice();return t.sort((r,n)=>r.x<n.x?-1:r.x>n.x?1:r.y<n.y?-1:r.y>n.y?1:0),BM(t)}function BM(e){if(e.length<=1)return e.slice();const t=[];for(let n=0;n<e.length;n++){const i=e[n];for(;t.length>=2;){const a=t[t.length-1],l=t[t.length-2];if((a.x-l.x)*(i.y-l.y)>=(a.y-l.y)*(i.x-l.x))t.pop();else break}t.push(i)}t.pop();const r=[];for(let n=e.length-1;n>=0;n--){const i=e[n];for(;r.length>=2;){const a=r[r.length-1],l=r[r.length-2];if((a.x-l.x)*(i.y-l.y)>=(a.y-l.y)*(i.x-l.x))r.pop();else break}r.push(i)}return r.pop(),t.length===1&&r.length===1&&t[0].x===r[0].x&&t[0].y===r[0].y?t:t.concat(r)}var qM=VS,VM=WS,WM=HS,YS=KS;const HM=qM,KM=VM,GM=WM,JS=v.forwardRef(({className:e,sideOffset:t=4,...r},n)=>d.jsx(YS,{ref:n,sideOffset:t,className:Pe("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r}));JS.displayName=YS.displayName;const QM="sidebar:state",YM=3600*24*7,JM="16rem",XM="18rem",ZM="3rem",e$="b",XS=v.createContext(null);function md(){const e=v.useContext(XS);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Ei=v.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:r,className:n,style:i,children:a,...l},u)=>{const f=JL(),[p,m]=v.useState(!1),[g,b]=v.useState(e),w=t??g,S=v.useCallback(T=>{const R=typeof T=="function"?T(w):T;r?r(R):b(R),document.cookie=`${QM}=${R}; path=/; max-age=${YM}`},[r,w]),_=v.useCallback(()=>f?m(T=>!T):S(T=>!T),[f,S,m]);v.useEffect(()=>{const T=R=>
404{R.key===e$&&(R.metaKey||R.ctrlKey)&&(R.preventDefault(),_())};return window.addEventListener("keydown",T),()=>window.removeEventListener("keydown",T)},[_]);const E=w?"expanded":"collapsed",k=v.useMemo(()=>({state:E,open:w,setOpen:S,isMobile:f,openMobile:p,setOpenMobile:m,toggleSidebar:_}),[E,w,S,f,p,m,_]);return d.jsx(XS.Provider,{value:k,children:d.jsx(HM,{delayDuration:0,children:d.jsx("div",{style:{"--sidebar-width":JM,"--sidebar-width-icon":ZM,...i},className:Pe("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",n),ref:u,...l,children:a})})})});Ei.displayName="SidebarProvider";const Rm=v.forwardRef(({side:e="left",variant:t="sidebar",collapsible:r="offcanvas",className:n,children:i,...a},l)=>{const{isMobile:u,state:f,openMobile:p,setOpenMobile:m}=md();return r==="none"?d.jsx("div",{className:Pe("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",n),ref:l,...a,children:i}):u?d.jsx(nD,{open:p,onOpenChange:m,...a,children:d.jsx(bS,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":XM},side:e,children:d.jsx("div",{className:"flex h-full w-full flex-col",children:i})})}):d.jsxs("div",{ref:l,className:"group peer hidden md:block text-sidebar-foreground","data-state":f,"data-collapsible":f==="collapsed"?r:"","data-variant":t,"data-side":e,children:[d.jsx("div",{className:Pe("duration-200 relative h-svh w-[--sidebar-width] bg-transparent transition-[width] ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),d.jsx("div",{className:Pe("duration-200 fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",n),...a,children:d.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:i})})]})});Rm.displayName="Sidebar";const t$=v.forwardRef(({className:e,onClick:t,...r},n)=>{const{toggleSidebar:i}=md();return d.jsxs(bt,{ref:n,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:Pe("h-7 w-7",e),onClick:a=>{t==null||t(a),i()},...r,children:[d.jsx(fP,{}),d.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})});t$.displayName="SidebarTrigger";const r$=v.forwardRef(({className:e,...t},r)=>{const{toggleSidebar:n}=md();return d.jsx("button",{ref:r,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:Pe("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})});r$.displayName="SidebarRail";const n$=v.forwardRef(({className:e,...t},r)=>d.jsx("main",{ref:r,className:Pe("relative flex min-h-svh flex-1 flex-col bg-background","peer-data-[variant=inset]:min-
404h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",e),...t}));n$.displayName="SidebarInset";const s$=v.forwardRef(({className:e,...t},r)=>d.jsx(mS,{ref:r,"data-sidebar":"input",className:Pe("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t}));s$.displayName="SidebarInput";const Pm=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"header",className:Pe("flex flex-col gap-2 p-2",e),...t}));Pm.displayName="SidebarHeader";const jm=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"footer",className:Pe("flex flex-col gap-2 p-2",e),...t}));jm.displayName="SidebarFooter";const o$=v.forwardRef(({className:e,...t},r)=>d.jsx(yS,{ref:r,"data-sidebar":"separator",className:Pe("mx-2 w-auto bg-sidebar-border",e),...t}));o$.displayName="SidebarSeparator";const Om=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"content",className:Pe("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t}));Om.displayName="SidebarContent";const ZS=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"group",className:Pe("relative flex w-full min-w-0 flex-col p-2",e),...t}));ZS.displayName="SidebarGroup";const eE=v.forwardRef(({className:e,asChild:t=!1,...r},n)=>{const i=t?Ji:"div";return d.jsx(i,{ref:n,"data-sidebar":"group-label",className:Pe("duration-200 flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...r})});eE.displayName="SidebarGroupLabel";const i$=v.forwardRef(({className:e,asChild:t=!1,...r},n)=>{const i=t?Ji:"button";return d.jsx(i,{ref:n,"data-sidebar":"group-action",className:Pe("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...r})});i$.displayName="SidebarGroupAction";const tE=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"group-content",className:Pe("w-full text-sm",e),...t}));tE.displayName="SidebarGroupContent";const Lu=v.forwardRef(({className:e,...t},r)=>d.jsx("ul",{ref:r,"data-sidebar":"menu",className:Pe("flex w-full min-w-0 flex-col gap-1",e),...t}));Lu.displayName="SidebarMenu";const Ya=v.forwardRef(({className:e,...t},r)=>d.jsx("li",{ref:r,"data-sidebar":"menu-item",className:Pe("group/menu-item relative",e),...t}));Ya.displayName="SidebarMenuItem";const a$=_l("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Du=v.forwardRef(({asChild:e=!1,isActive:t=!1,variant:r="default",size:n="default",tooltip:i,className:a,...l},u)=>{const f=e?Ji:"button",{isMobile:p,state:m}=md(),g=d.jsx(f,{ref:u,"data-sidebar":"menu-button","data-size":n,"data-active":t,className:Pe(a$({variant:r,size:n}),a),...l});return i?(typeof i=="string"&&(i={children:i}),d.jsxs(KM,{children:[d.jsx(GM,{asChild:!0,children:g}),d.jsx(JS,{side:"right",align:"center",hidden:m!=="collapsed"||p,...i})]})):g});Du.displayName="SidebarMenuButton";const l$=v.forwardRef(({className:e,asChild:t=!1,showOnHover:r=!1,...n},i)=>{const a=t?Ji:"button";return d.jsx(a,{ref:i,"data-sidebar":"menu-action",className:Pe("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",r&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",e),...n})});l$.displayName="SidebarMenuAction";const c$=v.forwardRef(({className:e,...t},r)=>d.jsx("div",{ref:r,"data-sidebar":"menu-badge",className:Pe("absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground select-none pointer-events-none","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t}));c$.displayName="SidebarMenuBadge";const u$=v.forwardRef(({className:e,showIcon:t=!1,...r},n)=>{const i=v.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return d.jsxs("div",{ref:n,"data-sidebar":"menu-skeleton",className:Pe("rounded-md h-8 flex gap-2 px-2 items-center",e),...r,children:[t&&d.jsx(Ew,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),d.jsx(Ew,{className:"h-4 flex-1 max-w-[--skeleton-width]","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":i}})]})});u$.displayName="SidebarMenuSkeleton";const d$=v.forwardRef(({className:e,...t},r)=>d.jsx("ul",{ref:r,"data-sidebar":"menu-sub",className:Pe("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t}));d$.displayName="SidebarMenuSub";const f$=v.forwardRef(({...e},t)=>d.jsx("li",{ref:t,...e}));f$.displayName="SidebarMenuSubItem";const h$=v.forwardRef(({asChild:e=!1,size:t="md",isActive:r,className:n,...i},a)=>{const l=e?Ji:"a";return d.jsx(l,{ref:a,"data-sidebar":"menu-sub-button","data-size":t,"data-active":r,className:Pe("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",n),...i})});h$.displayName="SidebarMenuSubButton";const p$=6e4,m$=480,g$=18e5,v$=()=>{const{user:e}=ar(),[t,r]=v.useState(0),[n,i]=v.useState(!1),a=v.useRef(Date.now()),l=v.useRef(null),u=v.useRef(null),f=v.useRef(0),p=v.useRef(0),m=()=>{a.current=Date.now(),n||i(!0)},g=async()=>
404{if(!(!(e!=null&&e.id)||p.current===0))try{const b=p.current,{error:w}=await me.from("ei_metrics").insert({user_id:e.id,metric_type:"platform_activity_minutes",metric_value:b,recorded_at:new Date().toISOString(),metadata:{session_start:new Date(Date.now()-b*6e4).toISOString(),session_end:new Date().toISOString()}});w?console.error("Failed to sync activity metrics:",w):(console.log(`✅ Synced ${b} activity minutes to database`),p.current=0)}catch(b){console.error("Error syncing metrics:",b)}};return v.useEffect(()=>{if(!(e!=null&&e.id))return;const b=["mousedown","keydown","scroll","touchstart","click"];b.forEach(S=>{window.addEventListener(S,m,{passive:!0})}),l.current=setInterval(()=>{Date.now()-a.current<p$&&f.current<m$?(f.current+=1,p.current+=1,r(_=>_+1)):i(!1)},6e4),u.current=setInterval(()=>{g()},g$);const w=()=>{document.hidden?i(!1):a.current=Date.now()};return document.addEventListener("visibilitychange",w),()=>{p.current>0&&g(),b.forEach(S=>{window.removeEventListener(S,m)}),l.current&&clearInterval(l.current),u.current&&clearInterval(u.current),document.removeEventListener("visibilitychange",w)}},[e==null?void 0:e.id]),{activeMinutes:t,isActive:n}},y$=["signup_completed","profile_completed","login"],Dw={immediate:100,normal:0},w$=()=>{const{user:e}=ar(),t=async(n,i,a)=>{const l=i.platform_user_id||(e==null?void 0:e.id);if(!l){console.warn("Cannot queue event: no target user ID");return}const u=(a==null?void 0:a.immediate)||y$.includes(n),f=u?Dw.immediate:Dw.normal;try{const{error:p}=await me.from("dareyscore_event_queue").insert({user_id:l,event_id:i.event_id||crypto.randomUUID(),event_type:n,event_data:i,priority:f});if(p){if(p.code==="23505"){console.log(`Event ${i.event_id} already queued (duplicate)`);return}console.error("Failed to queue event:",p);return}console.log(`✅ Queued ${n} event (priority: ${f})`),u&&await r()}catch(p){console.error("Error queuing event:",p)}},r=async()=>{try{const{data:n,error:i}=await me.functions.invoke("send-dareyscore-batch",{body:{immediate:!0}});i?console.error("Failed to trigger immediate batch:",i):console.log("✅ Immediate batch triggered:",n)}catch(n){console.error("Error triggering immediate batch:",n)}};return{queueEvent:t,triggerImmediateBatch:r}};let cu=null;const b$=()=>{const{user:e}=ar(),{queueEvent:t}=w$(),r=v.useRef(!1);v.useRef(!1);const n=v.useRef(!1),i=async()=>{if(n.current)return!0;if(!(e!=null&&e.id))return!1;try{console.log("🔗 Linking Signal Score identity for user:",e.id);const{data:p,error:m}=await me.functions.invoke("link-dareyscore-identity",{body:{user_id:e.id}});return m?(console.error("Failed to link Signal Score identity:",m),!1):(n.current=!0,console.log("✅ Signal Score identity linked:",p),!0)}catch(p){return console.error("Error linking Signal Score identity:",p),!1}},a=async(p,m)=>{if(!(e!=null&&e.id)||!(e!=null&&e.email))return;if(!await i()){console.warn(`Skipping ${p} event - identity not linked`);return}try{let b;p==="signup_completed"?b=`signup-${e.id}`:p==="profile_completed"?b=`profile-${e.id}`:b=crypto.randomUUID();const w={event_id:b,occurred_at:new Date().toISOString(),platform:"xterns",platform_user_id:e.id,email:e.email.toLowerCase(),event_type:p,payload:m||{},points_local:0,rules_version:"xterns_v1.0"};console.log(`Queuing ${p} event to Signal Score (event_id: ${b})`),await t(p,w)}catch(b){console.error(`Error tracking ${p}:`,b)}};return v.useEffect(()=>{if(!(e!=null&&e.id))return;(async()=>{var g;const m=`dareyscore_signup_tracked_${e.id}`;if(localStorage.getItem(m)==="true"){r.current=!0;return}if(cu===e.id){console.log("⏭️ Signup tracking already in progress for user:",e.id);return}if(!r.current){cu=e.id,localStorage.setItem(m,"true"),r.current=!0;try{const{data:b}=await me.auth.getUser();if(!b.user){localStorage.removeItem(m),cu=null,r.current=!1;return}const w=new Date(b.user.created_at).getTime(),S=Date.now(),_=300*1e3;S-w<_?(console.log("📝 Tracking signup_completed event for new user"),await a("signup_completed",{signup_method:((g=b.user.app_metadata)==null?void 0:g.provider)||"email",created_at:b.user.created_at})):console.log("⏭️ User not newly created, skipping signup event")}catch(b){console.error("Error tracking signup:",b)}finally{cu=null}}})()},[e==null?void 0:e.id]),{trackProfileCompleted:async()=>{e!=null&&e.id&&await a("profile_completed",{completed_at:new Date().toISOString()})},trackDeadlineMissed:async p=>{e!=null&&e.id&&await a("deadline_missed",{...p,missed_at:new Date().toISOString()})},trackNegativeFeedback:async p=>{e!=null&&e.id&&await a("negative_feedback",{...p,recorded_at:new Date().toISOString()})}}},x$=()=>{const{user:e}=ar(),t=v.useRef(!1),r=async()=>
404{if(t.current)return!0;if(!(e!=null&&e.id))return!1;try{const{data:i,error:a}=await me.functions.invoke("link-dareyscore-identity",{body:{user_id:e.id}});return a?(console.error("Failed to link Signal Score identity:",a),!1):(t.current=!0,!0)}catch(i){return console.error("Error linking Signal Score identity:",i),!1}},n=async()=>{if(!(e!=null&&e.id)||!(e!=null&&e.email))return;if(!await r()){console.warn("Skipping deadline check - identity not linked");return}try{const a=new Date().toISOString(),{data:l}=await me.from("roadmap_stories").select("id, title, end_date, assignee_id").eq("assignee_id",e.id).lt("end_date",a).neq("status","done");if(l&&l.length>0){const f=l.map(p=>{const m=new Date(p.end_date),g=Math.floor((Date.now()-m.getTime())/(1e3*60*60*24));return{event_id:crypto.randomUUID(),occurred_at:a,platform:"xterns",platform_user_id:e.id,email:e.email.toLowerCase(),event_type:"deadline_missed",payload:{item_type:"story",item_id:p.id,item_title:p.title,due_date:p.end_date,days_overdue:g},rules_version:"xterns_v1.0"}});await me.functions.invoke("send-dareyscore-event",{body:{events:f}}),console.log(`✅ Tracked ${l.length} missed story deadlines`)}const{data:u}=await me.from("roadmap_tasks").select("id, title, end_date, assignee_id").eq("assignee_id",e.id).lt("end_date",a).neq("status","done");if(u&&u.length>0){const f=u.map(p=>{const m=new Date(p.end_date),g=Math.floor((Date.now()-m.getTime())/(1e3*60*60*24));return{event_id:crypto.randomUUID(),occurred_at:a,platform:"xterns",platform_user_id:e.id,email:e.email.toLowerCase(),event_type:"deadline_missed",payload:{item_type:"task",item_id:p.id,item_title:p.title,due_date:p.end_date,days_overdue:g},rules_version:"xterns_v1.0"}});await me.functions.invoke("send-dareyscore-event",{body:{events:f}}),console.log(`✅ Tracked ${u.length} missed task deadlines`)}}catch(a){console.error("Error tracking deadlines:",a)}};return v.useEffect(()=>{if(!(e!=null&&e.id))return;n();const i=setInterval(n,14400*1e3);return()=>clearInterval(i)},[e==null?void 0:e.id]),{checkAndTrackDeadlines:n}},_$=()=>(v$(),b$(),x$(),null),S$=_l("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function Mp({className:e,variant:t,...r}){return d.jsx("div",{className:Pe(S$({variant:t}),e),...r})}const E$=[{groupLabel:"Start here",items:[{label:"Opportunities",url:"/xterns/jobs",icon:fu,emphasis:!0},{label:"Dashboard",url:"/xterns/dashboard",icon:aP},{label:"Profile",url:"/xterns/profile",icon:hP}]},{groupLabel:"Build proof",items:[{label:"Sprint Board",url:"/xterns/sprint-board",icon:e0},{label:"Skill Tracker",url:"/xterns/ei-tracker",icon:pP},{label:"Pods",url:"/xterns/pods",icon:vx}]},{groupLabel:"Profile",items:[{label:"My CV",url:"/xterns/cv",icon:uP},{label:"Learning",url:"/xterns/learning",icon:iP}]},{groupLabel:"Updates",items:[{label:"Notifications",url:"/xterns/notifications",icon:QR},{label:"Calendar",url:"/xterns/calendar",icon:e0}]}],$h={label:"Settings",url:"/xterns/settings",icon:mx};function Mw(){const e=Po(),{logout:t}=ar(),{assessmentStatus:r}=ym(),n=!!(r!=null&&r.assessmentCompleted);return d.jsxs(d.Fragment,{children:[d.jsx(_$,{}),d.jsxs(Rm,{className:"border-r border-gray-200",children:[d.jsx(Pm,{className:"p-4",children:d.jsxs(Lt,{to:"/xterns/dashboard",className:"flex items-center gap-3",children:[d.jsx("div",{className:"w-10 h-10 bg-gradient-to-br from-purple-600 to-indigo-600 rounded-lg flex items-center justify-center",children:d.jsx("span",{className:"text-white font-bold text-lg",children:"X"})}),d.jsxs("div",{children:[d.jsx("h2",{className:"font-bold text-lg text-gray-900",children:"Xtern"}),d.jsx("p",{className:"text-sm text-gray-500",children:"Your Project Journey"})]})]})}),d.jsxs(Om,{className:"px-3 space-y-3",children:[!n&&d.jsxs("div",{className:"rounded-xl border border-purple-200 bg-gradient-to-br from-purple-50 to-blue-50 p-3 shadow-sm",children:[d.jsxs("div",{className:"flex items-center justify-between gap-2",children:[d.jsxs("div",{className:"flex items-center gap-2 text-sm font-semibold text-gray-950",children:[d.jsx(px,{className:"h-4 w-4 text-purple-700"}),"Xterns Accelerator"]}),d.jsx(Mp,{className:"bg-purple-100 text-purple-800 hover:bg-purple-100",children:"Next"})]}),d.jsx("p",{className:"mt-2 text-xs leading-5 text-gray-600",children:"Take the assessment to unlock pods, sprints, and accelerator applications."}),d.jsx(bt,{asChild:!0,size:"sm",className:"mt-3 w-full bg-purple-700 hover:bg-purple-800",children:d.jsxs(Lt,{to:"/assessment",children:[d.jsx(fx,{className:"mr-2 h-4 w-4"}),"Start assessment"]})})]}),E$.map(({groupLabel:i,items:a})=>d.jsxs(ZS,{children:[d.jsx(eE,{className:"px-2 text-[11px] font-semibold uppercase tracking-[0.12em] text-gray-400",children:i}
404),d.jsx(tE,{children:d.jsx(Lu,{children:a.map(l=>{const u=e.pathname===l.url||e.pathname.startsWith(`${l.url}/`);return d.jsx(Ya,{children:d.jsx(Du,{asChild:!0,isActive:u,children:d.jsxs(Lt,{to:l.url,"aria-current":u?"page":void 0,className:`group relative flex items-center gap-2.5 rounded-xl px-3 py-2.5 text-sm font-medium transition-all duration-200 ${u?"bg-xterns-blue text-white shadow-[0_6px_18px_-6px_hsl(var(--blue)/0.7)] hover:bg-xterns-blue hover:text-white":"text-gray-700 hover:bg-gray-100 hover:text-gray-900"} ${"emphasis"in l&&l.emphasis&&!u?"text-xterns-blue":""}`,children:[u&&d.jsx("span",{"aria-hidden":!0,className:"absolute -left-3 top-1/2 h-6 w-1 -translate-y-1/2 rounded-r-full bg-xterns-blue"}),d.jsx(l.icon,{className:"h-4.5 w-4.5 shrink-0"}),d.jsx("span",{className:"truncate",children:l.label})]})})},l.url)})})})]},i))]}),d.jsx(jm,{className:"p-4 flex flex-col gap-2",children:d.jsxs(Lu,{children:[d.jsx(Ya,{children:d.jsx(Du,{asChild:!0,children:d.jsxs(Lt,{to:$h.url,className:"flex items-center gap-2 p-2 rounded-lg",children:[d.jsx($h.icon,{className:"h-4 w-4"}),d.jsx("span",{children:$h.label})]})})}),d.jsx(Ya,{children:d.jsxs("button",{onClick:t,className:"flex items-center gap-2 p-2 rounded-lg text-red-600 hover:bg-red-50 w-full transition-colors",type:"button",children:[d.jsx(hx,{className:"h-4 w-4"}),d.jsx("span",{children:"Log out"})]})})]})})]})]})}const tt=({children:e,requiredForFeature:t="this feature",showInlinePrompt:r=!1,accessLevel:n="verified"})=>{const{assessmentStatus:i,isLoading:a}=ym(),l=!!(i!=null&&i.assessmentCompleted&&(i!=null&&i.techAssessmentPassed));return n==="open"||l?d.jsx(d.Fragment,{children:e}):a?d.jsx(Ei,{children:d.jsxs("div",{className:"min-h-screen flex w-full bg-gray-50",children:[d.jsx(Mw,{}),d.jsxs("main",{className:"flex-1 p-8 space-y-6",children:[d.jsx("div",{className:"h-8 w-48 bg-muted rounded animate-pulse"}),d.jsx("div",{className:"h-32 w-full bg-muted/60 rounded animate-pulse"}),d.jsx("div",{className:"h-64 w-full bg-muted/40 rounded animate-pulse"})]})]})}):r?d.jsxs("div",{className:"space-y-4",children:[d.jsx(_w,{featureName:t}),d.jsx("div",{className:"opacity-50 pointer-events-none",children:e})]}):d.jsx(Ei,{children:d.jsxs("div",{className:"min-h-screen flex w-full bg-gradient-to-br from-slate-50 via-blue-50 to-indigo-50",children:[d.jsx(Mw,{}),d.jsx("main",{className:"flex-1 p-8",children:d.jsx(_w,{featureName:t})})]})})},rE="tech-lead-assessment-status",$w=e=>[rE,e??"anon"],k$=[rE],nE=e=>e.stage_1_completed?e.stage_2_completed?(e.stage_3_completed,3):2:1;async function T$(e){const{data:t,error:r}=await me.from("tech_lead_assessments").select("*").eq("user_id",e).not("assessment_type","eq","skill_update").order("created_at",{ascending:!1}).limit(1);if(r)throw r;if(!t||t.length===0)return null;const n=t[0];let i;if(n.tech_assessment_passed){const{data:a}=await me.from("tech_lead_tech_assessments").select("id").eq("assessment_id",n.id).single();if(a){const{data:l}=await me.from("tech_lead_tech_assessment_attempts").select("id").eq("tech_assessment_id",a.id).order("created_at",{ascending:!1}).limit(1).single();l&&(i=l.id)}}return{id:n.id,currentStage:nE(n),stage1Completed:n.stage_1_completed,stage2Completed:n.stage_2_completed,stage3Completed:n.stage_3_completed,assessmentCompleted:n.assessment_completed,techAssessmentPassed:n.tech_assessment_passed,readyForTechAssessment:n.stage_1_completed&&n.stage_2_completed&&n.stage_3_completed&&!n.tech_assessment_passed,approvalStatus:n.approval_status,createdAt:n.created_at,completedAt:n.completed_at,latestAttemptId:i}}const sE=()=>{const{user:e}=ar(),t=qp(),r=Eb({queryKey:$w(e==null?void 0:e.id),queryFn:()=>T$(e.id),enabled:!!(e!=null&&e.id),staleTime:5*6e4,gcTime:30*6e4,refetchOnWindowFocus:!1,refetchOnReconnect:!0}),n=()=>t.invalidateQueries({queryKey:k$}),i=g=>t.setQueryData($w(e==null?void 0:e.id),g),a=async()=>{if(!(e!=null&&e.id))return null;try{const{data:g,error:b}=await me.from("tech_lead_assessments").insert({user_id:e.id,stage_1_completed:!1,stage_2_completed:!1,stage_3_completed:!1,assessment_completed:!1,tech_assessment_passed:!1}).select().single();if(b)throw b;const w={id:g.id,currentStage:1,stage1Completed:!1,stage2Completed:!1,stage3Completed:!1,assessmentCompleted:!1,techAssessmentPassed:!1,readyForTechAssessment:!1,approvalStatus:g.a
404pproval_status,createdAt:g.created_at,completedAt:g.completed_at};return i(w),w}catch(g){return console.error("Error creating assessment:",g),ap.error("Failed to create assessment. Please try again."),null}},l=async(g,b,w)=>{var _;let S=w||((_=r.data)==null?void 0:_.id);if(!S){const E=await a();if(!E)throw new Error("Failed to create assessment");S=E.id}try{const E={};E[`stage_${g}_completed`]=b;const{error:k}=await me.from("tech_lead_assessments").update(E).eq("id",S);if(k)throw k;if(r.data){const T={...r.data};g===1&&(T.stage1Completed=b),g===2&&(T.stage2Completed=b),g===3&&(T.stage3Completed=b),T.currentStage=nE({stage_1_completed:T.stage1Completed,stage_2_completed:T.stage2Completed,stage_3_completed:T.stage3Completed}),T.readyForTechAssessment=T.stage1Completed&&T.stage2Completed&&T.stage3Completed&&!T.techAssessmentPassed,i(T)}await n()}catch(E){throw console.error("Error updating assessment stage:",E),E}},u=async g=>{const{data:b,error:w}=await me.from("tech_lead_assessment_biodata").select("*").eq("assessment_id",g).maybeSingle();if(w&&w.code!=="PGRST116")throw w;return b},f=async g=>{const{data:b,error:w}=await me.from("tech_lead_assessment_skills").select("*").eq("assessment_id",g).maybeSingle();if(w&&w.code!=="PGRST116")throw w;return b?{selectedCareerPaths:Array.isArray(b.selected_career_paths)?b.selected_career_paths:[],skillProficiencies:Array.isArray(b.skill_proficiencies)?b.skill_proficiencies:[]}:null},p=async(g,b)=>{const{error:w}=await me.from("tech_lead_assessment_biodata").upsert({assessment_id:g,...b},{onConflict:"assessment_id"});return w?(console.error("Error saving biodata:",w),!1):!0},m=async(g,b)=>{const{error:w}=await me.from("tech_lead_assessment_skills").upsert({assessment_id:g,selected_career_paths:b.selectedCareerPaths,skill_proficiencies:b.skillProficiencies},{onConflict:"assessment_id"});return w?(console.error("Error saving skills:",w),!1):!0};return{assessmentStatus:r.data??null,isLoading:r.isPending&&!!(e!=null&&e.id),createAssessment:a,updateAssessmentStage:l,loadBiodata:u,loadSkills:f,saveBiodata:p,saveSkills:m,refreshStatus:n}};function C$(e,t=[]){let r=[];function n(a,l){const u=v.createContext(l);u.displayName=a+"Context";const f=r.length;r=[...r,l];const p=g=>{var k;const{scope:b,children:w,...S}=g,_=((k=b==null?void 0:b[e])==null?void 0:k[f])||u,E=v.useMemo(()=>S,Object.values(S));return d.jsx(_.Provider,{value:E,children:w})};p.displayName=a+"Provider";function m(g,b){var _;const w=((_=b==null?void 0:b[e])==null?void 0:_[f])||u,S=v.useContext(w);if(S)return S;if(l!==void 0)return l;throw new Error(`\`${g}\` must be used within \`${a}\``)}return[p,m]}const i=()=>{const a=r.map(l=>v.createContext(l));return function(u){const f=(u==null?void 0:u[e])||a;return v.useMemo(()=>({[`__scope${e}`]:{...u,[e]:f}}),[u,f])}};return i.scopeName=e,[n,R$(i,...t)]}function R$(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const l=n.reduce((u,{useScope:f,scopeName:p})=>{const g=f(a)[`__scope${p}`];return{...u,...g}},{});return v.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return r.scopeName=t.scopeName,r}var P$=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],oE=P$.reduce((e,t)=>{const r=id(`Primitive.${t}`),n=v.forwardRef((i,a)=>{const{asChild:l,...u}=i,f=l?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(f,{...u,ref:a})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),Am="Progress",Nm=100,[j$]=C$(Am),[O$,A$]=j$(Am),iE=v.forwardRef((e,t)=>{const{__scopeProgress:r,value:n=null,max:i,getValueLabel:a=N$,...l}=e;(i||i===0)&&!Fw(i)&&console.error(I$(`${i}`,"Progress"));const u=Fw(i)?i:Nm;n!==null&&!Uw(n,u)&&console.error(L$(`${n}`,"Progress"));const f=Uw(n,u)?n:null,p=Mu(f)?a(f,u):void 0;return d.jsx(O$,{scope:r,value:f,max:u,children:d.jsx(oE.div,{"aria-valuemax":u,"aria-valuemin":0,"aria-valuenow":Mu(f)?f:void 0,"aria-valuetext":p,role:"progressbar","data-state":cE(f,u),"data-value":f??void 0,"data-max":u,...l,ref:t})})});iE.displayName=Am;var aE="ProgressIndicator",lE=v.forwardRef((e,t)=>
404{const{__scopeProgress:r,...n}=e,i=A$(aE,r);return d.jsx(oE.div,{"data-state":cE(i.value,i.max),"data-value":i.value??void 0,"data-max":i.max,...n,ref:t})});lE.displayName=aE;function N$(e,t){return`${Math.round(e/t*100)}%`}function cE(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function Mu(e){return typeof e=="number"}function Fw(e){return Mu(e)&&!isNaN(e)&&e>0}function Uw(e,t){return Mu(e)&&!isNaN(e)&&e<=t&&e>=0}function I$(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${Nm}\`.`}function L$(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
405  - a positive number
406  - less than the value passed to \`max\` (or ${Nm} if no \`max\` prop is set)
407  - \`null\` or \`undefined\` if the progress is indeterminate.
408
409Defaulting to \`null\`.`}var uE=iE,D$=lE;const dE=v.forwardRef(({className:e,value:t,...r},n)=>d.jsx(uE,{ref:n,className:Pe("relative h-4 w-full overflow-hidden rounded-full bg-secondary",e),...r,children:d.jsx(D$,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));dE.displayName=uE.displayName;const zw=({featureName:e="this feature"})=>{const t=jo(),{assessmentStatus:r}=sE(),n=()=>r?r.stage1Completed||r.stage2Completed||r.stage3Completed:!1,i=()=>{if(!r)return 0;let p=0;return r.stage1Completed&&p++,r.stage2Completed&&p++,r.stage3Completed&&p++,p/3*100},a=()=>!r||!n()||!r.stage1Completed?1:r.stage2Completed?r.stage3Completed?4:3:2,l=[{number:1,title:"Experience & Background",description:"Share your professional experience and leadership background",icon:gx,completed:(r==null?void 0:r.stage1Completed)||!1,route:"/tech-lead/assessment/stage-1"},{number:2,title:"Personal Information",description:"Complete your professional profile",icon:nP,completed:(r==null?void 0:r.stage2Completed)||!1,route:"/tech-lead/assessment/stage-2"},{number:3,title:"Technical Skills",description:"Showcase your technical expertise and specializations",icon:rP,completed:(r==null?void 0:r.stage3Completed)||!1,route:"/tech-lead/assessment/stage-3"}],u=a(),f=l.find(p=>p.number===u);return d.jsxs($s,{className:"bg-gradient-to-br from-orange-50 to-red-50 border-orange-200",children:[d.jsx(Fs,{children:d.jsxs("div",{className:"flex items-center gap-3",children:[d.jsx("div",{className:"p-2 bg-orange-100 rounded-lg",children:d.jsx(dP,{className:"w-5 h-5 text-orange-600"})}),d.jsxs("div",{children:[d.jsx(Us,{className:"text-orange-900",children:"Complete Tech Lead Assessment Required"}),d.jsxs("p",{className:"text-sm text-orange-700 mt-1",children:["Complete your tech lead assessment to unlock ",e]})]})]})}),d.jsxs(ko,{className:"space-y-6",children:[d.jsxs("div",{className:"space-y-3",children:[d.jsxs("div",{className:"flex items-center justify-between",children:[d.jsx("span",{className:"text-sm font-medium text-orange-900",children:"Assessment Progress"}),d.jsxs(Mp,{variant:"secondary",className:"bg-orange-100 text-orange-800",children:[Math.round(i()),"% Complete"]})]}),d.jsx(dE,{value:i(),className:"h-2"})]}),d.jsxs("div",{className:"space-y-3",children:[d.jsx("h4",{className:"font-medium text-orange-900",children:"Assessment Stages"}),d.jsx("div",{className:"space-y-2",children:l.map(p=>d.jsxs("div",{className:`flex items-center gap-3 p-3 rounded-lg transition-colors ${p.completed?"bg-green-50 border border-green-200":p.number===u?"bg-orange-100 border border-orange-300":"bg-gray-50 border border-gray-200"}`,children:[d.jsx("div",{className:"flex-shrink-0",children:p.completed?d.jsx(t0,{className:"w-5 h-5 text-green-600"}):d.jsx(tP,{className:"w-5 h-5 text-gray-400"})}),d.jsx(p.icon,{className:`w-4 h-4 ${p.completed?"text-green-600":"text-gray-500"}`}),d.jsxs("div",{className:"flex-1 min-w-0",children:[d.jsxs("p",{className:`text-sm font-medium ${p.completed?"text-green-900":"text-gray-900"}`,children:["Stage ",p.number,": ",p.title]}),d.jsx("p",{className:"text-xs text-gray-600",children:p.description})]}),p.number===u&&!p.completed&&d.jsx(Mp,{variant:"outline",className:"border-orange-300 text-orange-700",children:"Next"})]},p.number))})]}),d.jsx("div",{className:"flex flex-col sm:flex-row gap-3 pt-4 border-t border-orange-200",children:r!=null&&r.assessmentCompleted?d.jsxs("div",{className:"flex items-center gap-2 text-green-700 font-medium",children:[d.jsx(t0,{className:"w-5 h-5"}),d.jsx("span",{children:"Assessment Complete! Refreshing access..."})]}):d.jsxs(d.Fragment,{children:[d.jsxs(bt,{onClick:()=>{t(f?f.route:"/tech-lead/assessment")},className:"flex-1 bg-orange-600 hover:bg-orange-700 text-white",children:[!r||!n()?"Start Assessment":f?`Continue to Stage ${f.number}`:"Continue Assessment",d.jsx(dx,{className:"w-4 h-4 ml-2"})]}),d.jsx(bt,{variant:"outline",onClick:()=>t("/tech-lead/assessment"),className:"border-orange-300 text-orange-700 hover:bg-orange-50",children:"View Full Assessment"})]})}),d.jsxs("div",{className:"text-xs text-orange-600 bg-orange-50 p-3 rounded-lg border border-orange-200",children:[d.jsx("strong",{children:"Note:"})," As a Tech Lead, completing this assessment helps us match you with the right projects and Xtern teams based on your expertise and leadership style."]})]})]})};function M$(e,t=[]){let r=[];function n(a,l){const u=v.createContext(l);u.displayName=a+"Context";const f=r.length;r=[...r,l];const p=g=>{var k;const{scope:b,children:w,...S}=g,_=((k=b==null?void 0:b[e])==null?void 0:k[f])||u,E=v.useMemo(()=>S,Object.values(S));return d.jsx(_.Provider,{value:E,children:w})};p.displayName=a+"Provider";function m(g,b){var _;const w=((_=b==null?void 0:b[e])==null?void 0:_[f])||u,S=v.useContext(w);if(S)return S;if(l!==void 0)return l;throw new Error(`\`${g}\` must be used within \`${a}\``)}return[p,m]}const i=()=>{const a=r.map(l=>v.createContext(l));return function(u){const f=(u==null?void 0:u[e])||a;return v.useMemo(()=>({[`__scope${e}`]:{...u,[e]:f}}),[u,f])}};return i.scopeName=e,[n,$$(i,...t)]}function $$(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const l=n.reduce((u,{useScope:f,scopeName:p})=>{const g=f(a)[`__scope${p}`];return{...u,...g}},{});return v.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return r.scopeName=t.scopeName,r}var F$=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Im=F$.reduce((e,t)=>
409{const r=id(`Primitive.${t}`),n=v.forwardRef((i,a)=>{const{asChild:l,...u}=i,f=l?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(f,{...u,ref:a})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),Fh={exports:{}},Uh={};/**
410 * @license React
411 * use-sync-external-store-shim.production.js
412 *
413 * Copyright (c) Meta Platforms, Inc. and affiliates.
414 *
415 * This source code is licensed under the MIT license found in the
416 * LICENSE file in the root directory of this source tree.
417 */var Bw;function U$(){if(Bw)return Uh;Bw=1;var e=$u();function t(g,b){return g===b&&(g!==0||1/g===1/b)||g!==g&&b!==b}var r=typeof Object.is=="function"?Object.is:t,n=e.useState,i=e.useEffect,a=e.useLayoutEffect,l=e.useDebugValue;function u(g,b){var w=b(),S=n({inst:{value:w,getSnapshot:b}}),_=S[0].inst,E=S[1];return a(function(){_.value=w,_.getSnapshot=b,f(_)&&E({inst:_})},[g,w,b]),i(function(){return f(_)&&E({inst:_}),g(function(){f(_)&&E({inst:_})})},[g]),l(w),w}function f(g){var b=g.getSnapshot;g=g.value;try{var w=b();return!r(g,w)}catch{return!0}}function p(g,b){return b()}var m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?p:u;return Uh.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:m,Uh}var qw;function z$(){return qw||(qw=1,Fh.exports=U$()),Fh.exports}var B$=z$();function q$(){return B$.useSyncExternalStore(V$,()=>!0,()=>!1)}function V$(){return()=>{}}var Lm="Avatar",[W$]=M$(Lm),[H$,fE]=W$(Lm),hE=v.forwardRef((e,t)=>{const{__scopeAvatar:r,...n}=e,[i,a]=v.useState("idle");return d.jsx(H$,{scope:r,imageLoadingStatus:i,onImageLoadingStatusChange:a,children:d.jsx(Im.span,{...n,ref:t})})});hE.displayName=Lm;var pE="AvatarImage",mE=v.forwardRef((e,t)=>{const{__scopeAvatar:r,src:n,onLoadingStatusChange:i=()=>{},...a}=e,l=fE(pE,r),u=K$(n,a),f=rn(p=>{i(p),l.onImageLoadingStatusChange(p)});return Fr(()=>{u!=="idle"&&f(u)},[u,f]),u==="loaded"?d.jsx(Im.img,{...a,ref:t,src:n}):null});mE.displayName=pE;var gE="AvatarFallback",vE=v.forwardRef((e,t)=>{const{__scopeAvatar:r,delayMs:n,...i}=e,a=fE(gE,r),[l,u]=v.useState(n===void 0);return v.useEffect(()=>{if(n!==void 0){const f=window.setTimeout(()=>u(!0),n);return()=>window.clearTimeout(f)}},[n]),l&&a.imageLoadingStatus!=="loaded"?d.jsx(Im.span,{...i,ref:t}):null});vE.displayName=gE;function Vw(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function K$(e,{referrerPolicy:t,crossOrigin:r}){const n=q$(),i=v.useRef(null),a=n?(i.current||(i.current=new window.Image),i.current):null,[l,u]=v.useState(()=>Vw(a,e));return Fr(()=>{u(Vw(a,e))},[a,e]),Fr(()=>{const f=g=>()=>{u(g)};if(!a)return;const p=f("loaded"),m=f("error");return a.addEventListener("load",p),a.addEventListener("error",m),t&&(a.referrerPolicy=t),typeof r=="string"&&(a.crossOrigin=r),()=>{a.removeEventListener("load",p),a.removeEventListener("error",m)}},[a,r,t]),l}var yE=hE,wE=mE,bE=vE;const xE=v.forwardRef(({className:e,...t},r)=>d.jsx(yE,{ref:r,className:Pe("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));xE.displayName=yE.displayName;const _E=v.forwardRef(({className:e,...t},r)=>d.jsx(wE,{ref:r,className:Pe("aspect-square h-full w-full",e),...t}));_E.displayName=wE.displayName;const SE=v.forwardRef(({className:e,...t},r)=>d.jsx(bE,{ref:r,className:Pe("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));SE.displayName=bE.displayName;const G$=()=>{const{user:e}=ar(),[t,r]=v.useState(null),[n,i]=v.useState(!0),[a,l]=v.useState(null),[u,f]=v.useState(null),p=async()=>{var b;if(e)try{i(!0),l(null);const{data:w,error:S}=await me.from("tech_leads").select("*").eq("user_id",e.id).single();if(S&&S.code!=="PGRST116")throw S;const{data:_,error:E}=await me.from("profiles").select("avatar_url").eq("id",e.id).single();E&&E.code!=="PGRST116"&&console.warn("Could not fetch profile data:",E);let k=[];if(w!=null&&w.skill_proficiencies)k=w.skill_proficiencies;else if(w){const{data:T,error:R}=await me.from("tech_lead_assessments").select(`
418            id,
419            tech_lead_assessment_skills(skill_proficiencies)
420          `).eq("user_id",e.id).eq("assessment_completed",!0).order("completed_at",{ascending:!1}).limit(1).single();R&&R.code!=="PGRST116"?console.warn("Could not fetch skill proficiencies:",R):(b=T==null?void 0:T.tech_lead_assessment_skills)!=null&&b.skill_proficiencies&&(k=T.tech_lead_assessment_skills.skill_proficiencies)}r(w?{...w,avatar_url:_==null?void 0:_.avatar_url,skill_proficiencies:k}:null),f((_==null?void 0:_.avatar_url)||null)}catch(w){console.error("Error fetching tech lead profile:",w),l(w instanceof Error?w.message:"Failed to fetch profile")}finally{i(!1)}},m=async b=>{if(!e)throw new Error("User not authenticated");try{const w={user_id:e.id,full_name:b.full_name||"",bio:b.bio||"",expertise_areas:b.expertise_areas||[],career_paths:b.career_paths||[],years_experience:b.years_experience||0,linkedin_url:b.linkedin_url,github_url:b.github_url,portfolio_url:b.portfolio_url,company:b.company,position:b.position,phone:b.phone,location:b.location,is_available:b.is_available??!0},{data:S,error:_}=await me.from("tech_leads").upsert(w,{onConflict:"user_id"}).select().single();if(_)throw _;await me.from("profiles").update({full_name:b.full_name}).eq("id",e.id);const E={...S,skill_proficiencies:S.skill_proficiencies||[]};return r(E),ap.success("Profile updated successfully"),E}catch(w){console.error("Error updating tech lead profile:",w);const S=w instanceof Error?w.message:"Failed to update profile";throw ap.error(S),w}};return v.useEffect(()=>{p()},[e]),{profile:t,isLoading:n,error:a,avatarUrl:u,createOrUpdateProfile:m,refreshProfile:p,updateAvatar:b=>{f(b),t&&r({...t,avatar_url:b})}}},Q$=[{id:"fullstack-engineering",name:"Fullstack Engineering",description:"Full-stack development, React, Node.js, databases, REST APIs"},{id:"cloud-aws",name:"Cloud Computing AWS",description:"AWS services, Lambda, EC2, S3, cloud infrastru
420cture"},{id:"cloud-azure",name:"Cloud Computing Azure",description:"Azure services, ARM templates, Azure DevOps, cloud architecture"},{id:"devops-engineering",name:"DevOps Engineering",description:"CI/CD pipelines, Docker, Kubernetes, automation, infrastructure"},{id:"data-analysis",name:"Data Analysis",description:"Data analytics, SQL, Python, visualization, business intelligence"},{id:"cybersecurity",name:"Cybersecurity",description:"Security audits, penetration testing, compliance, threat analysis"},{id:"ai-ml-engineering",name:"AI/ML Engineering",description:"Machine learning, LLMs, neural networks, data pipelines, AI applications"},{id:"ui-ux-designer",name:"UI/UX Designer",description:"Wireframes, prototypes, user research, design systems, accessibility"},{id:"product-manager",name:"Product Manager",description:"User stories, roadmaps, stakeholder management, prioritisation, discovery"},{id:"technical-writer",name:"Technical Writer",description:"Documentation, tutorials, API docs, style guides, knowledge bases"},{id:"technical-researcher",name:"Technical Researcher",description:"Research methods, technical analysis, evidence synthesis, market and product insights"},{id:"content-creation-communication",name:"Content Creation & Communication",description:"Content planning, storytelling, copywriting, social media, audience communication"},{id:"customer-success-sales",name:"Customer Success and Sales",description:"CRM, customer onboarding, account management, sales discovery, retention"},{id:"qa-engineer",name:"QA Engineer",description:"Test plans, bug reports, test automation, quality processes, risk analysis"},{id:"marketing",name:"Marketing",description:"Content strategy, campaigns, growth analytics, brand, community"}],Y$=[{label:"Dashboard",url:"/tech-lead/dashboard",icon:cP},{label:"Analytics",url:"/tech-lead/sla-dashboard",icon:XR},{label:"Pods",url:"/tech-lead/pods",icon:vx},{label:"Sprint Boards",url:"/tech-lead/sprint-board-pods",icon:sP},{label:"Projects",url:"/tech-lead/project-hub",icon:fx},{label:"Xtern Invitations",url:"/tech-lead/invitations",icon:lP},{label:"GitHub Integration",url:"/tech-lead/github-integration",icon:oP},{label:"Meetings",url:"/tech-lead/calendar",icon:JR},{label:"My Ratings",url:"/tech-lead/csat-dashboard",icon:GR},{label:"Settings",url:"/tech-lead/profile",icon:mx}];function J$(e){return(e||"Tech Lead").split(" ").map(t=>t[0]).join("").slice(0,2).toUpperCase()}function zh(){var p,m;const e=Po(),t=jo(),{user:r,logout:n}=ar(),{profile:i,avatarUrl:a}=G$(),l=(i==null?void 0:i.full_name)||(r==null?void 0:r.name)||(r==null?void 0:r.email)||"Tech Lead",u=(p=i==null?void 0:i.career_paths)==null?void 0:p[0],f=u?((m=Q$.find(g=>g.id===u))==null?void 0:m.name)||u:null;return d.jsx(Rm,{className:"w-[260px] border-0 bg-transparent p-3",children:d.jsxs("div",{className:"flex h-full flex-col overflow-hidden rounded-[24px] border border-slate-200/70 bg-white/92 shadow-[0_24px_70px_rgba(15,23,42,0.08)] backdrop-blur-xl",children:[d.jsx(Pm,{className:"p-5",children:d.jsxs(Lt,{to:"/tech-lead/dashboard",className:"flex items-center gap-3",children:[d.jsx("div",{className:"flex h-11 w-11 items-center justify-center rounded-2xl bg-gradient-to-br from-xterns-navy to-xterns-navy2 text-sm font-bold text-white shadow-lg shadow-slate-900/20",children:"TL"}),d.jsxs("div",{className:"min-w-0",children:[d.jsx("h2",{className:"truncate text-base font-semibold text-slate-950",children:"Tech Lead"}),d.jsx("p",{className:"truncate text-xs text-slate-500",children:"Delivery command"})]})]})}),d.jsx(Om,{className:"flex-1 px-3 pb-3",children:d.jsx(Lu,{className:"space-y-1",children:Y$.map(g=>{const b=e.pathname===g.url||g.label==="Sprint Boards"&&(e.pathname==="/tech-lead/sprint-board"||e.pathname==="/tech-lead/sprint-board-swimlanes");return d.jsx(Ya,{children:d.jsx(Du,{asChild:!0,isActive:b,className:"h-11 rounded-2xl px-3 transition-all data-[active=true]:bg-xterns-navy data-[active=true]:text-white data-[active=true]:shadow-lg data-[active=true]:shadow-slate-900/20",children:d.jsxs(Lt,{to:g.url,className:"flex items-center gap-3",children:[d.jsx(g.icon,{className:"h-4 w-4"}),d.jsx("span",{className:"text-sm font-medium",children:g.label})]})})},`${g.label}-${g.url}`)})})}),d.jsxs(jm,{className:"space-y-3 border-t border-slate-100 p-4",children:[d.jsxs("button",{type:"button",onClick:()=>t("/tech-lead/profile"),className:"flex w-full items-center gap-3 rounded-2xl bg-slate-50 p-3 text-left transition hover:bg-slate-100",children:[d.jsxs(xE,{className:"h-10 w-10",children:[d.jsx(_E,{src:a||(r==null?void 0:r.profilePicture)}),d.jsx(SE,{className:"bg-slate-100 text-xterns-navy",children:J$(l)})]}),d.jsxs("div",{className:"min-w-0 flex-1",children:[d.jsx("p",{className:"truncate text-sm font-semibold text-slate-950",children:l}),f&&d.jsx("p",{className:"truncate text-xs text-slate-500",children:f})]})]}),d.jsxs("button",{type:"button",onClick:n,className:"flex h-10 w-full items-center justify-center gap-2 rounded-2xl text-sm font-medium text-slate-500 transition hover:bg-red-50 hover:text-red-600",children:[d.jsx(hx,{className:"h-4 w-4"}),"Logout"]})]})]})})}const Wt=({children:e,requiredForFeature:t="this feature",showInlinePrompt:r=!1})=>{const{user:n,isInAssessmentLockdown:i}=ar(),{assessmentStatus:a,isLoading:l}=sE(),u=jo();return v.useEffect(()=>{if(!(!n||l)){if(i){u("/tech-lead/assessment-lockdown");return}if(!r&&!(a!=null&&a.assessmentCompleted)){u("/tech-lead/assessment");return}if(a!=null&&a.assessmentCompleted&&(a==null?void 0:a.approvalStatus)==="pending_review"){u("/tech-lead/pending-review");return}}},[n,l,a,i,u,r]),l?d.jsx(Ei,{children:d.jsxs("div",{className:"min-h-screen flex w-full bg-gradient-to-br from-slate-50 via-blue-50 to-indigo-50",children:[d.jsx(zh,{}),d.jsxs("main",{className:"flex-1 p-8 space-y-6",children:[d.jsx("div",{className:"h-8 w-48 bg-muted rounded animate-pulse"}),d.jsx("div",{className:"h-32 w-full bg-muted/60 rounded animate-pulse"}),d.jsx("div",{className:"h-64 w-full bg-muted/40 rounded animate-pulse"})]})]})}):i||a!=null&&a.assessmentCompleted&&(a==null?void 0:a.approvalStatus)==="pending_review"?null:a!=null&&a.assessmentCompleted&&(a==null?void 0:a.approvalStatus)==="approved"?d.jsx(d.Fragment,{children:e}):r?d.jsx(Ei,{children:d.jsxs("div",{className:"min-h-screen flex w-full bg-gradient-to-br from-slate-50 via-blue-50 to-indigo-50",children:[d.jsx(zh,{}),d.jsx("main",{className:"flex-1 p-8",children:d.jsx(zw,{featureName:t})})]})}):d.jsx(Ei,{children:d.jsxs("div",{className:"min-h-screen flex w-full bg-gradient-to-br from-slate-50 via-blue-50 to-indigo-50",children:[d.jsx(zh,{}),d.jsx("main",{className:"flex-1 p-8",children:d.jsx(zw,{featureName:t})})]})})},X$=v.lazy(()=>H(()=>import("./Index-BNtBY6eu.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19]))),Z$=v.lazy(()=>H(()=>import("./UnifiedLogin-YUrSOTuv.js"),__vite__mapDeps([20,13,1,21,22,23]))),Ww=v.lazy(()=>H(()=>import("./XternSignup-DtyrLBeh.js"),__vite__mapDeps([24,13,1,25,22,23,21]))),eF=v.lazy(()=>H(()=>import("./TechLeadSignup-Bohl5S-i.js"),__vite__mapDeps([26,13,1,25,22,23,21,27]))),tF=v.lazy(()=>H(()=>import("./ResetPassword-CHQOHUNY.js"),__vite__mapDeps([28,13,1,21]))),rF=v.lazy(()=>H(()=>import("./PrivacyPolicy-CeJeR_tA.js"),__vite__mapDeps([29,1,30]))),nF=v.lazy(()=>H(()=>import("./CookiePolicy-C7hR8njQ.js"),__vite__mapDeps([31,1,30]))),sF=v.lazy(()=>H(()=>import("./About-C8a7Tahq.js"),__vite__mapDeps([32,1,30,33,7,11,34]))),oF=v.lazy(()=>H(()=>import("./SkillsAccelerator-DVr_F28n.js"),__vite__mapDeps([35,1,30,11]))),iF=v.lazy(()=>H(()=>import("./TechLeads-DPw8Ni7-.js"),__vite__mapDeps([36,1,30,5]))),aF=v.lazy(()=>H(()=>import("./PodSponsorship-CblYYbnK.js"),__vite__mapDeps([37,30,12,13,14,15,16,17,18,2,38,39,40,4,41,42,43]))),lF=v.lazy(()=>H(()=>import("./Terms-Cg0WPBn8.js"),__vite__mapDeps([44,1,30]))),cF=v.lazy(()=>H(()=>import("./NotFound-CTZvcp09.js"),[])),uF=v.lazy(()=>H(()=>import("./EnterpriseLanding-D_8j6hI6.js"),__vite__mapDeps([45,1,30]))),dF=v.lazy(()=>H(()=>import("./EnterpriseVerify-BB2AeEq2.js"),__vite__mapDeps([46,1,13,25,23,21,22]))),fF=v.lazy(()=>H(()=>import("./SuperAdminDashboard-ujQK_7bI.js"),__vite__mapDeps([47,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,11,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,21,27]))),hF=v.lazy(()=>H(()=>import("./SuperAdminUsers-Cf9xJPXT.js"),__vite__mapDeps([88,89,90,14,15,16,17,18,48,49,50,51,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,13,91,69,92,21,9,34,11,93,94,95,96]))),pF=v.lazy(()=>H(()=>import("./SuperAdminTechLeadReviews-B0h7kr5L.js"),__vite__mapDeps([97,72,98,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,99,100,101,34,23,102,68,21,39,17,92,81,103]))),mF=v.lazy(()=>H(()=>import("./SuperAdminMetricDetail-Bwe-MULn.js"),__vite__mapDeps([104,90,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,14,17,18,21,70,71,72,78,74,75,22,92]))),gF=v.lazy(()=>H(()=>import("./SuperAdminNotifications-BdNAY343.js"),__vite__mapDeps([105,106,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,107,108,23,38,109,110]))),vF=v.lazy(()=>H(()=>import("./SuperAdminCalendar-D50fTUCN.js"),__vite__mapDeps([111,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,112,113,71,98,114,81,91,13,89,115,21,116,68,110,117,108,30,14,17,18,84,118,96,80]))),yF=v.lazy(()=>H(()=>import("./SuperAdminOngoingPods-DNoc-84j.js"),__vite__mapDeps([119,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,87,90,22,21,81]))),wF=v.lazy(()=>H(()=>import("./SuperAdminCompletedPods-B0OWYJJa.js"),__vite__mapDeps([120,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,87,90,22,21,81]))),bF=v.lazy(()=>H(()=>import("./SuperAdminSprintBoardPods-DB8K4kQ5.js"),__vite__mapDeps([121,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,87,112,90,21,4,81]))),xF=v.lazy(()=>H(()=>import("./SuperAdminSprintAnalytics-D5I63ZkJ.js"),__vite__mapDeps([122,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,123,13,14,17,18,90,21,101,96,124,125,126]))),_F=v.lazy(()=>H(()=>import("./SuperAdminPodAnalytics-BWX-hqUk.js"),__vite__mapDeps([127,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,128,69,129,13,14,17,18,91,130,90,101,131,132,68,133,134,135,136,124,92,109,70,71,72,76,77,73,74,75,86,137,34,138,139,140,84,141,21,118]))),SF=v.lazy(()=>H(()=>import("./SuperAdminPodAnalyticsDetail-_YWZuqfB.js"),__vite__mapDeps([142,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,136,22,68]))),EF=v.lazy(()=>H(()=>import("./SuperAdminPodSprintBoard-D1QYh_gj.js"),__vite__mapDeps([143,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,144,145,146,147,148,149,13,14,17,18,150,131,151,152,91,108,138,140,132,109,101,22,21,4,81]))),kF=v.lazy(()=>H(()=>import("./SuperAdminPodSetup-B2GnJE0z.js"),__vite__mapDeps([153,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,151,152,13,14,17,18,131,21,22,154,110,118,109,155]))),TF=v.lazy(()=>H(()=>import("./SuperAdminPodSprintSwimlanes-wu_BFpR7.js"),__vite__mapDeps([156,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,147,148,157,158,159,81,160,161,91,79,80,82,83,84,118,14,17,18,162,163,19,2,9,68,164,165,166,101,102,21,167,106,168,169,110,4,137,170,13,22]))),CF=v.lazy(()=>H(()=>import("./SuperAdminProjects-DQnGexO2.js"),__vite__mapDeps([171,14,15,16,17,18,48,49,50,51,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,134,135,172,9,109,118,128,69,129,13,91,130,90,101,131,132,68,173,174,175,139,155,110,33,21,140]))),RF=v.lazy(()=>H(()=>import("./SuperAdminBusinesses-DnLyYOi-.js"),__vite__mapDeps([176,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,123,118,21,4]))),PF=v.lazy(()=>H(()=>import("./SuperAdminBusinessNew-CKwOSYCU.js"),__vite__mapDeps([177,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,123,13,91,106,22,21]))),jF=v.lazy(()=>H(()=>import("./SuperAdminBusinessDetail-D9PeAjwx.js"),__vite__mapDeps([178,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,123,13,14,17,18,91,106,21,22,155,95,23,168,167]))),OF=v.lazy(()=>H(()=>import("./SuperAdminPodAccessCodes-BcRC4ZQF.js"),__vite__mapDeps([179,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,123,90,21,101,167,180])
420)),AF=v.lazy(()=>H(()=>import("./SuperAdminTalentPipeline-WYfnlo-O.js"),__vite__mapDeps([181,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,182,112,183,184,5,185,23,186,102,68,21,9,92,14,17,18,101,84]))),NF=v.lazy(()=>H(()=>import("./SuperAdminSponsorshipInquiries-BgWNsTqw.js"),__vite__mapDeps([187,89,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,90,14,17,18,84,81]))),IF=v.lazy(()=>H(()=>import("./SuperAdminTechLeadRatings-BErUnCqK.js"),__vite__mapDeps([188,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,90,14,17,18,79,80,81,82,83,84,96,4]))),LF=v.lazy(()=>H(()=>import("./DareyScoreDiagnostics-GKKJOUkh.js"),__vite__mapDeps([189,48,49,50,51,16,15,52,53,54,55,56,57,40,8,58,59,60,61,62,63,41,64,10,6,65,66,112,14,17,18,90,89,13,106,21,164,116,190,124,101,110,191]))),Hw=v.lazy(()=>H(()=>import("./Dashboard-pd69jBl5.js"),__vite__mapDeps([192,193,59,16,60,61,6,118,95,11,194,40,66,70,71,72,78,74,75,76,77]))),DF=v.lazy(()=>H(()=>import("./XternsDashboard-B61CJlUF.js"),__vite__mapDeps([195,112,60,16,196,159,81,54,163,197,198,199,200,49,50,51,15,52,53,55,56,57,40,8,58,201,202,124,203,4,39,204,19,2,11,67,89,91,41,21,61,205,137,206,13,69,175,207,129,101,190,208,209,68,210,34,70,71,72,77,22,140,158,211,212,27,9,62]))),MF=v.lazy(()=>H(()=>import("./XternProjects-CEKraU1a.js"),__vite__mapDeps([213,14,15,16,17,18,112,60,214,196,215,66,185,190,172,9,109,118,101,21]))),$F=v.lazy(()=>H(()=>import("./XternPods-BJOFv3o9.js"),__vite__mapDeps([216,13,14,15,16,17,18,112,60,84,61,196,206,91,69,175,147,148,41,27,65,53,54,55,56,57,123,145,212,101,8,66,96,141,21]))),FF=v.lazy(()=>H(()=>import("./XternProjectHub-_J-YDvAQ.js"),__vite__mapDeps([217,14,15,16,17,18,214,172,9,109,118,215,66,64,96,11]))),UF=v.lazy(()=>H(()=>import("./XternEITracker-DHMZWjot.js"),__vite__mapDeps([218,200,49,50,51,16,15,52,53,54,55,56,57,40,8,58,201,112,60,159,81,204,70,71,72,77,11,67,61,174,78,74,75,82,85,185,68,101,18,17,129,205]))),zF=v.lazy(()=>H(()=>import("./XternCV-DDkKOkwE.js"),__vite__mapDeps([219,220,159,81,54,221,2,211,185,23,102,64,92,222,5,41,11,8,6,168,101,106,13,91,169,118,110,155,21,223,4,174,167,116]))),BF=v.lazy(()=>H(()=>import("./XternLearning-TWxfJ1Iz.js"),__vite__mapDeps([224,162,163,9,41,68,164,165,166,21,112,60,16,91,66,129,200,49,50,51,15,52,53,54,55,56,57,40,8,58,201,101]))),qF=v.lazy(()=>H(()=>import("./XternLearningResourceDetail-CBlGx2T1.js"),__vite__mapDeps([225,22,41,58,68,164,162,163]))),VF=v.lazy(()=>H(()=>import("./XternCareer-B_IKp0xz.js"),__vite__mapDeps([226,166,40,34]))),Kw=v.lazy(()=>H(()=>import("./XternJobs-D8xQYRae.js"),__vite__mapDeps([227,228,203,229,89,230,210,34,66,5,185,126,231,4,232,11,21,22,140,68,125,191,39]))),WF=v.lazy(()=>H(()=>import("./XternSimulationWorkspace-CkrMMSTH.js"),__vite__mapDeps([233,13,14,15,16,17,18,91,118,68,110,168,101,161,234,106,209,21,109,7,126,170,228,203,229,89,230,22,102,5,232,34,155,158]))),HF=v.lazy(()=>H(()=>import("./XternCommunity-CZJbzcLb.js"),__vite__mapDeps([235,40,42,223,34,11]))),KF=v.lazy(()=>H(()=>import("./XternNotifications-SyyDk_9z.js"),__vite__mapDeps([236,106,108,52,53,54,55,56,57,40,8,58,107,96,23,109,34,110,92]))),GF=v.lazy(()=>H(()=>import("./XternRecognition-D88FqvJI.js"),__vite__mapDeps([237,8,34,41,11]))),QF=v.lazy(()=>H(()=>import("./XternProfile-C7CieAUy.js"),__vite__mapDeps([238,13,91,210,239,159,81,54,69,240,41,21,241,14,15,16,17,18,43,124,242,94,208,209,68,82,114,85,243,194,11,2,207,19,9,34,40,4,83,53,55,56,57,204,70,71,72,86,74,8,185,23,117,102,64,186,101,33,211,118]))),YF=v.lazy(()=>H(()=>import("./XternSettings-BhWYti7C.js"),__vite__mapDeps([244,64,102,38,245,124]))),JF=v.lazy(()=>H(()=>import("./XternSettingsEnhanced-BE10EBND.js"),__vite__mapDeps([246,64,102,38,245,34]))),XF=v.lazy(()=>H(()=>import("./XternSprintSwimlanes-CsZGV9qx.js"),__vite__mapDeps([247,145,147,148,157,158,159,81,54,248,21,160,161,91,79,80,57,55,82,83,61,84,50,118,14,15,16,17,18,162,163,41,19,2,9,68,164,165,166,101,102,167,106,168,169,110,4,137,170,40,13,22]))),ZF=v.lazy(()=>H(()=>import("./XternSprintBoard-BbTlGy6M.js"),__vite__mapDeps([249,69,196,198,199,21,11,53,54,55,56,57,49,50,51,16,15,52,40,8,58,203]))),e3=v.lazy(()=>H(()=>import("./XternSprintSelection-vIZwZafo.js"),__vite__mapDeps([250,144,145,146,147,148,49,50,51,16,15,52,53,54,55,56,57,40,8,58,22,21,203]))),t3=v.lazy(()=>H(()=>import("./XternCalendar-ByelJxFK.js"),__vite__mapDeps([251,112,60,16,113,71,98,114,54,81,91,13,89,115,30,252,17,21,58,116,68,117,84,61,118,96,57,80,56]))),r3=v.lazy(()=>H(()=>import("./XternSprintAssessment-MjKowxR2.js"),__vite__mapDeps([253,175,60,16,13,69,254,39,58]))),n3=v.lazy(()=>H(()=>import("./XternSprintHistory-D8Gf_JDk.js"),__vite__mapDeps([255,197,198,196,222,92,167,102,22,203,53,54,55,56,57]))),s3=v.lazy(()=>H(()=>import("./XternSkillUpdateWizard-BiXGiUbs.js"),__vite__mapDeps([256,257,239,21,84,118,240,41]))),o3=v.lazy(()=>H(()=>import("./XternSkillUpdateAssessment-Cl4oP-Tn.js"),__vite__mapDeps([258,210,159,81,54,257,239,175,60,16,13,155,124,8,22,254,21,58,84,61]))),i3=v.lazy(()=>H(()=>import("./ClientDashboard-DsLi1PoL.js"),__vite__mapDeps([259,260,10,6,123,21,58]))),a3=v.lazy(()=>H(()=>import("./ClientProjects-C60_XiOH.js"),__vite__mapDeps([261,260,10,
4206,123,21,173,14,15,16,17,18,51,69,174,129,175,60,139,58,91,101,118,155,110,33,140,9,172,109,128,13,64,130,90,131,132,41,68,262,135,66,4]))),l3=v.lazy(()=>H(()=>import("./ClientPods-BhqSY6RV.js"),__vite__mapDeps([263,260,10,6,123,21,128,69,129,13,14,15,16,17,18,91,64,130,90,101,58,131,132,41,68,262,135,133,118,66,154,4]))),c3=v.lazy(()=>H(()=>import("./ClientPodDetail-BgqkRqbp.js"),__vite__mapDeps([264,260,10,6,123,21,22,154,118,65,167,101,180]))),u3=v.lazy(()=>H(()=>import("./ClientPodSetup-Dha9s84G.js"),__vite__mapDeps([265,260,10,6,123,21,151,152,66,50,41,13,14,15,16,17,18,131,22,154,110,118,109,155]))),d3=v.lazy(()=>H(()=>import("./ClientSprints-DMAdoaF2.js"),__vite__mapDeps([266,260,10,6,123,21,13,14,15,16,17,18,90,101,96,124,58,125,126]))),f3=v.lazy(()=>H(()=>import("./ClientAnalytics-Bya2es0J.js"),__vite__mapDeps([267,260,10,6,123,21,90,112,60,16,11,65,63]))),h3=v.lazy(()=>H(()=>import("./ClientAccelerator-NEPkoYiH.js"),__vite__mapDeps([268,260,10,6,123,21,269,118,270]))),Gw=v.lazy(()=>H(()=>import("./ClientAcceleratorSetup-06UxDYRN.js"),__vite__mapDeps([271,260,10,6,123,21,13,14,15,16,17,18,112,60,91,269,22,270,7,155]))),p3=v.lazy(()=>H(()=>import("./ClientAcceleratorLandingEditor-Dl2WwNXK.js"),__vite__mapDeps([272,260,10,6,123,21,273,100,16,17,95,211,23,186,13,91,269,22,68,4,155,158,274,245,94,110,118]))),m3=v.lazy(()=>H(()=>import("./ClientAcceleratorApplicationFormEditor-XQa99PKt.js"),__vite__mapDeps([275,260,10,6,123,21,13,14,15,16,17,18,106,212,22,155,118,110]))),g3=v.lazy(()=>H(()=>import("./ClientAcceleratorApplicationReviews-S393237K.js"),__vite__mapDeps([276,260,10,6,123,21,14,15,16,17,18,90,212,22,126,39,66,240]))),v3=v.lazy(()=>H(()=>import("./ClientAcceleratorPodAssignments-Cb5SuraL.js"),__vite__mapDeps([277,260,10,6,123,21,13,106,90,112,60,16,201,95,14,15,17,18,278,58,212,22,232]))),y3=v.lazy(()=>H(()=>import("./PublicAcceleratorApplicationForm-DVyvdmE0.js"),__vite__mapDeps([279,13,175,60,16,14,15,17,18,91,212,21,22,158]))),w3=v.lazy(()=>H(()=>import("./PublicAcceleratorLandingPage-wvVjocnA.js"),__vite__mapDeps([280,273,100,16,17,95,211,23,186,21]))),b3=v.lazy(()=>H(()=>import("./ClientInvitationAccept-OJiOXpVJ.js"),__vite__mapDeps([281,123,69,25,13,6,21,58,23]))),x3=v.lazy(()=>H(()=>import("./TechLeadDashboard-BWhsLmJ9.js"),__vite__mapDeps([282,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,203,284,285,286,194,2,3,21,11,81]))),Qw=v.lazy(()=>H(()=>import("./TechLeadProjectHub-1dtyuLMp.js"),__vite__mapDeps([287,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,14,17,18,214,172,9,109,118,173,69,174,129,175,139,91,101,155,110,33,21,140,128,13,64,130,90,131,132,41,68,288,135,150,2,70,71,72,73,74,76,77,66,96]))),_3=v.lazy(()=>H(()=>import("./TechLeadMyPods-CckB-0kM.js"),__vite__mapDeps([289,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,284,214,288,130,135,150,285,286,128,69,129,13,14,17,18,91,64,90,101,131,132,41,68,194,2,5,190,126,21,70,71,72,78,74,81]))),S3=v.lazy(()=>H(()=>import("./TechLeadPodManagement-CAGguWAJ.js"),__vite__mapDeps([290,90,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,284,291,101,68]))),E3=v.lazy(()=>H(()=>import("./TechLeadGithubIntegration-fsaOHO7l.js"),__vite__mapDeps([292,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,208,209,21,68,243,194,4,152,66,64,234,13,106,118,89,95,109,168,101]))),k3=v.lazy(()=>H(()=>import("./TechLeadInvitations-BLiaBUzS.js"),__vite__mapDeps([293,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,39,150]))),T3=v.lazy(()=>H(()=>import("./TechLeadCalendar-CpMjfAtX.js"),__vite__mapDeps([294,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,112,113,71,98,114,81,91,13,89,115,30,252,17,21,116,68,117,84,118,96,80]))),C3=v.lazy(()=>H(()=>import("./TechLeadProfile-ChOM-5qB.js"),__vite__mapDeps([295,13,91,296,297,68,21,241,14,15,16,17,18,43,124,242,94,41,117,185,23,186,102,64,283,59,60,61,49,50,51,52,53,54,55,56,57,40,8,58]))),R3=v.lazy(()=>H(()=>import("./TechLeadDeliveryPlanCreation-C67pGt3L.js"),__vite__mapDeps([298,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,135,21,240,13,144,145,146,291]))),P3=v.lazy(()=>H(()=>import("./TechLeadSprintBoardPodList-D2rswWc9.js"),__vite__mapDeps([299,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,284,285,288,130,135,150,21,101,81]))),j3=v.lazy(()=>H(()=>import("./TechLeadSprintBoard-fOAq91yr.js"),__vite__mapDeps([300,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,145,146,147,148,234,13,106,209,118,68,21,22,109,99,100,14,17,18,69,126,164,201,101,301,81,149,150,131,151,152,66,41,91,108,138,140,132]))),O3=v.lazy(()=>H(()=>import("./TechLeadSprintSwimlanes-CWoNkvo5.js"),__vite__mapDeps([302,144,145,146,147,148,157,158,159,81,54,248,21,160,161,91,79,80,57,55,82,83,61,84,50,118,14,15,16,17,18,162,163,41,19,2,9,68,164,165,166,101,102,167,106,168,169,110,4,137,170,40,13,22]))),A3=v.lazy(()=>H(()=>import("./TechLeadNotifications-BEmQyl72.js"),__vite__mapDeps([303,106,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,107,108,23,109,34,110]))),N3=v.lazy(()=>H(()=>import("./TechLeadSLADashboard-DAsn9F_w.js"),__vite__mapDeps([304,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,14,17,18,191,101,92,39,70,71,72,78,74,66,11,67,86,81]))),I3=v.lazy(()=>H(()=>import("./TechLeadCSATDashboard-OglYJHo5.js"),__vite__mapDeps([305,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,14,17,18,41,81,101,92,34,70,71,72,76,77,11,78,74,4,66,86]))),L3=v.lazy(()=>H(()=>import("./AssessmentWelcome-CYyOdDAT.js"),__vite__mapDeps([306,202,41])
420)),D3=v.lazy(()=>H(()=>import("./AssessmentStage1-C4fC--Kf.js"),__vite__mapDeps([307,13,91,296,297,68,21,202,94,118,22,155]))),M3=v.lazy(()=>H(()=>import("./AssessmentStage2-BwZE7bHu.js"),__vite__mapDeps([308,13,14,15,16,17,18,79,80,54,57,81,55,82,83,61,84,50,202,309,242,94,22,155]))),$3=v.lazy(()=>H(()=>import("./AssessmentStage3-BYZgFBuW.js"),__vite__mapDeps([310,69,202,240,22,155]))),F3=v.lazy(()=>H(()=>import("./AssessmentConfirmation-Ceyjh03k.js"),__vite__mapDeps([311,202,38,58]))),U3=v.lazy(()=>H(()=>import("./TechAssessment-GiVAbL24.js"),__vite__mapDeps([312,175,60,16,13,254,313,202,210,239,159,81,54,58]))),z3=v.lazy(()=>H(()=>import("./TechAssessmentResults-B-B8iPbN.js"),__vite__mapDeps([314,159,81,54,315,99,100,39,96,4,124,18,17,208,209,21,68,202,8,11,9,101,278]))),B3=v.lazy(()=>H(()=>import("./AssessmentHistory-DpCkuzoJ.js"),__vite__mapDeps([316,200,49,50,51,16,15,52,53,54,55,56,57,40,8,58,201,202,11,4,39]))),q3=v.lazy(()=>H(()=>import("./AssessmentLockdown-OwSQPW2q.js"),__vite__mapDeps([317,202,58]))),V3=v.lazy(()=>H(()=>import("./AssessmentTake-Cq9UMmSm.js"),__vite__mapDeps([318,319,175,60,16,13,91,274,320,58,101,313,202,164]))),W3=v.lazy(()=>H(()=>import("./TechLeadAssessmentWelcome-BOIZX1N9.js"),__vite__mapDeps([321,41]))),H3=v.lazy(()=>H(()=>import("./TechLeadAssessmentStage1-Cqr5DUTm.js"),__vite__mapDeps([322,13,296,297,68,21,91,118,22,94]))),K3=v.lazy(()=>H(()=>import("./TechLeadAssessmentStage2-Dyr9J731.js"),__vite__mapDeps([323,13,91,14,15,16,17,18,50,79,80,54,57,81,55,82,83,61,84,309,22,94,185,186,155]))),G3=v.lazy(()=>H(()=>import("./TechLeadAssessmentStage3-3uB8Ds4M.js"),__vite__mapDeps([324,69,325,240,174,22,155]))),Q3=v.lazy(()=>H(()=>import("./TechLeadAssessmentConfirmation-Dv6gh5sZ.js"),__vite__mapDeps([326,325,155,38,58,174,39]))),Y3=v.lazy(()=>H(()=>import("./TechLeadAssessmentLockdown-CjthC3Pl.js"),__vite__mapDeps([327,101,58,95]))),J3=v.lazy(()=>H(()=>import("./TechLeadTechAssessment-CDdjjtUH.js"),__vite__mapDeps([328,254,319,175,60,16,13,91,274,58]))),X3=v.lazy(()=>H(()=>import("./TechLeadAssessmentResults-w0mpzy3N.js"),__vite__mapDeps([329,315,99,100,39,96,4,124,18,17,8,11,9,101,117]))),Z3=v.lazy(()=>H(()=>import("./TechLeadSkillUpdateAssessment-CFsvCob3.js"),__vite__mapDeps([330,69,283,59,16,60,61,49,50,51,15,52,53,54,55,56,57,40,8,58,124,331,325,21,164,11,118,41]))),eU=v.lazy(()=>H(()=>import("./TechLeadSkillUpdateAssessmentLevel-CbARLlUO.js"),__vite__mapDeps([332,331,325,175,60,16,13,155,124,8,22,254,283,59,61,49,50,51,15,52,53,54,55,56,57,40,58,21,84]))),tU=v.lazy(()=>H(()=>import("./TechLeadSkillUpdateConfirmation-BQcjyE83.js"),__vite__mapDeps([333,38,58]))),rU=v.lazy(()=>H(()=>import("./TechLeadSkillUpdateResults-XaMf6Yds.js"),__vite__mapDeps([334,39,11,41]))),nU=v.lazy(()=>H(()=>import("./TechLeadOnboardingWizard-J1Pb8MGC.js"),__vite__mapDeps([335,336,325,164,124]))),sU=v.lazy(()=>H(()=>import("./TechLeadOnboardingAssessment-BlajUR_c.js"),__vite__mapDeps([337,336,325,39,175,60,16,13,99,100,4,18,17,58,22,84,61]))),oU=v.lazy(()=>H(()=>import("./TechLeadOnboardingResults-Cop5_Zwx.js"),__vite__mapDeps([338,336,325,58,39,95]))),iU=v.lazy(()=>H(()=>import("./TechLeadPendingReview-CGo-DpPh.js"),__vite__mapDeps([339,23]))),aU=v.lazy(()=>H(()=>import("./PublicCV-DyTSow5t.js"),__vite__mapDeps([340,183,221,2,211,185,23,102,64,92,222,5,41,11,8,6,168,30,21]))),Yw=v.lazy(()=>H(()=>import("./CVSectionDetail-DxwgYVXc.js"),__vite__mapDeps([341,183,220,159,81,54,184,5,99,100,17,243,194,41,21,22]))),lU=v.lazy(()=>H(()=>import("./PodParticipationAwardVerify-CPJfnwD-.js"),__vite__mapDeps([342,5,39,34]))),cU=v.lazy(()=>H(()=>import("./Projects-DR8YehL9.js"),__vite__mapDeps([343,193,59,16,60,61,6,118,95,11,194,40,66,112,14,15,17,18,96]))),Jw=v.lazy(()=>H(()=>import("./Templates-BYLTpA40.js"),__vite__mapDeps([344,193,59,16,60,61,6,118,95,11,194,40,66,90,301,4,158]))),Xw=v.lazy(()=>H(()=>import("./Talent-Jjbxugvn.js"),__vite__mapDeps([345,193,59,16,60,61,6,118,95,11,194,40,66,182,112,183,184,5,185,23,186,41,102,64,68,21,9,92,14,15,17,18,84]))),uU=v.lazy(()=>H(()=>import("./EnterpriseOpportunities-V5aL8M8v.js"),__vite__mapDeps([346,193,59,16,60,61,6,118,95,11,194,40,66,5,140,166,185,126,23
4201,229,89,230,112,21]))),dU=v.lazy(()=>H(()=>import("./EnterpriseOpportunityCreate-DiapA1Xv.js"),__vite__mapDeps([347,193,59,16,60,61,6,118,95,11,194,40,66,229,89,230,13,14,15,17,18,91,106,22,21]))),fU=v.lazy(()=>H(()=>import("./EnterpriseOpportunityDetail-BPAzyzPo.js"),__vite__mapDeps([348,193,59,16,60,61,6,118,95,11,194,40,66,229,89,230,21,22,231,125]))),hU=v.lazy(()=>H(()=>import("./PracticeAssessments-CjIGCR9t.js"),__vite__mapDeps([349,193,59,16,60,61,6,118,95,11,194,40,66,89,9,164]))),pU=v.lazy(()=>H(()=>import("./PracticeAssessment-wVGFZ3TP.js"),__vite__mapDeps([350,319,175,60,16,13,91,274,320,58,101,313,202]))),mU=v.lazy(()=>H(()=>import("./AssessmentAnalytics-C1Oi8GBx.js"),__vite__mapDeps([351,193,59,16,60,61,6,118,95,11,194,40,66,13,129,58,39,41,22,4,158]))),gU=v.lazy(()=>H(()=>import("./AssessmentResults-BVk4y1p9.js"),__vite__mapDeps([352,193,59,16,60,61,6,118,95,11,194,40,66,90,39,301,4,92]))),vU=v.lazy(()=>H(()=>import("./ProjectPublish-BDJ3xnoH.js"),__vite__mapDeps([353,193,59,16,60,61,6,118,95,11,194,40,66,13,91,14,15,17,18,175,69,21,94,4,155,99,100,22]))),Zw=v.lazy(()=>H(()=>import("./InviteCandidates-CkWvGzKk.js"),__vite__mapDeps([354,193,59,16,60,61,6,118,95,11,194,40,66,89,13,91,14,15,17,18,68,101,112,94,158,93,4]))),yU=v.lazy(()=>H(()=>import("./AdminInviteCandidates-ty9uz7D9.js"),__vite__mapDeps([355,59,16,60,61,38,66,13,14,15,17,18,91,23,94,118,158,22]))),wU=v.lazy(()=>H(()=>import("./Roadmap-BlPVI3Z4.js"),__vite__mapDeps([356,144,145,146,148,118,91,13,14,15,16,17,18,117,90,161,4,164,109,157,158,159,81,54,101,169,110,40,297,9,68,58]))),bU=v.lazy(()=>H(()=>import("./EnterpriseSponsorships-Bm3UlfhG.js"),__vite__mapDeps([357,193,59,16,60,61,6,118,95,11,194,40,66,13,91,14,15,17,18,230,42]))),eb=v.lazy(()=>H(()=>import("./PodMarketplace-ln8PpcXA.js"),__vite__mapDeps([358,193,59,16,60,61,6,118,95,11,194,40,66,91,81,54]))),xU=()=>{const{user:e,showDashboardModal:t,handleDashboardSelection:r}=ar(),n=()=>e?e.roles.filter(i=>["xtern","tech_lead"].includes(i)):[];return d.jsxs(d.Fragment,{children:[d.jsx(v.Suspense,{fallback:d.jsx(GL,{}),children:d.jsxs(eC,{children:[d.jsx(q,{path:"/",element:d.jsx(X$,{})}),d.jsx(q,{path:"/login",element:d.jsx(Z$,{})}),d.jsx(q,{path:"/signup",element:d.jsx(Ww,{})}),d.jsx(q,{path:"/signup/xtern",element:d.jsx(Ww,{})}),d.jsx(q,{path:"/signup/tech-lead",element:d.jsx(eF,{})}),d.jsx(q,{path:"/reset-password",element:d.jsx(tF,{})}),d.jsx(q,{path:"/privacy",element:d.jsx(rF,{})}),d.jsx(q,{path:"/cookies",element:d.jsx(nF,{})}),d.jsx(q,{path:"/about",element:d.jsx(sF,{})}),d.jsx(q,{path:"/skills-accelerator",element:d.jsx(oF,{})}),d.jsx(q,{path:"/accelerators/:slug",element:d.jsx(w3,{})}),d.jsx(q,{path:"/accelerators/:slug/apply",element:d.jsx(y3,{})}),d.jsx(q,{path:"/tech-leads",element:d.jsx(iF,{})}),d.jsx(q,{path:"/pod-sponsorship",element:d.jsx(aF,{})}),d.jsx(q,{path:"/terms",element:d.jsx(lF,{})}),d.jsx(q,{path:"/enterprise",element:d.jsx(uF,{})}),d.jsx(q,{path:"/enterprise/verify",element:d.jsx(dF,{})}),d.jsx(q,{path:"/client/invitation/:token",element:d.jsx(b3,{})}),d.jsx(q,{path:"/xtern/:slug/:section",element:d.jsx(Yw,{})}),d.jsx(q,{path:"/xtern/:slug",element:d.jsx(aU,{})}),d.jsx(q,{path:"/awards/pod-participation/:verificationId",element:d.jsx(lU,{})}),d.jsx(q,{path:"/super-admin/dashboard",element:d.jsx(mt,{children:d.jsx(fF,{})})}),d.jsx(q,{path:"/super-admin/users",element:d.jsx(mt,{children:d.jsx(hF,{})})}),d.jsx(q,{path:"/super-admin/metrics/:metricType",element:d.jsx(mt,{children:d.jsx(mF,{})})}),d.jsx(q,{path:"/super-admin/tech-lead-reviews",element:d.jsx(mt,{children:d.jsx(pF,{})})}),d.jsx(q,{path:"/super-admin/notifications",element:d.jsx(mt,{children:d.jsx(gF,{})})}),d.jsx(q,{path:"/super-admin/calendar",element:d.jsx(mt,{children:d.jsx(vF,{})})}),d.jsx(q,{path:"/super-admin/sprint-boards-pods/ongoing",element:d.jsx(mt,{children:d.jsx(yF,{})})}),d.jsx(q,{path:"/super-admin/sprint-boards-pods/completed",element:d.jsx(mt,{children:d.jsx(wF,{})})}),d.jsx(q,{path:"/super-admin/sprint-boards-pods",element:d.jsx(mt,{children:d.jsx(bF,{})})}),d.jsx(q,{path:"/super-admin/sprint-analytics",element:d.jsx(mt,{children:d.jsx(xF,{})})}),d.jsx(q,{path:"/super-admin/pod-analytics",element:d.jsx(mt,{children:d.jsx(_F,{})})}),d.jsx(q,{path:"/super-admin/pod-analytics/:podId",element:d.jsx(mt,{children:d.jsx(SF,{})})}),d.jsx(q,{path:"/super-admin/sprint-boards-pods/:podId/sprint-board",element:d.jsx(mt,{children:d.jsx(EF,{})})}),d.jsx(q,{path:"/super-admin/pods/:podId/setup",element:d.jsx(mt,{children:d.jsx(kF,{})})}),d.jsx(q,{path:"/super-admin/sprint-boards-pods/:podId/sprint-board/:sprintId",element:d.jsx(mt,{children:d.jsx(TF,{})})}),d.jsx(q,{path:"/super-admin/projects",element:d.jsx(mt,{children:d.jsx(CF,{})})}),d.jsx(q,{path:"/super-admin/businesses",element:d.jsx(mt,{children:d.jsx(RF,{})})}),d.jsx(q,{path:"/super-admin/businesses/new",element:d.jsx(mt,{children:d.jsx(PF,{})})}),d.jsx(q,{path:"/super-admin/businesses/:businessId",element:d.jsx(mt,{children:d.jsx(jF,{})})}),d.jsx(q,{path:"/super-admin/pod-access-codes",element:d.jsx(mt,{children:d.jsx(OF,{})})}),d.jsx(q,{path:"/super-admin/talent-pipeline",element:d.jsx(mt,{children:d.jsx(AF,{})})}),d.jsx(q,{path:"/super-admin/sponsorship-inquiries",element:d.jsx(mt,{children:d.jsx(NF,{})})}),d.jsx(q,{path:"/super-admin/tech-lead-ratings",element:d.jsx(mt,{children:d.jsx(IF,{})})}),d.jsx(q,{path:"/super-admin/dareyscore-diagnostics",element:d.jsx(mt,{children:d.jsx(LF,{})})}),d.jsx(q,{path:"/assessment",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(L3,{})})}),d.jsx(q,{path:"/assessment/stage-1",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(D3,{})})}),d.jsx(q,{path:"/assessment/stage-2",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(M3,{})})}),d.jsx(q,{path:"/assessment/stage-3",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx($3,{})})}),d.jsx(q,{path:"/xtern/assessment-confirmation",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(F3,{})})}),d.jsx(q,{path:"/xtern/tech-assessment/:techAssessmentId",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(U3,{})})}),d.jsx(q,{path:"/xtern/assessment-results/:attemptId",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(z3,{})})}),d.jsx(q,{path:"/xtern/assessment-history",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(B3,{})})}),d.jsx(q,{path:"/assessment/:token",element:d.jsx(V3,{})}),d.jsx(q,{path:"/assessment-lockdown",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(q3,{})})}),d.jsx(q,{path:"/tech-lead/assessment",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(W3,{})})}),d.jsx(q,{path:"/tech-lead/assessment/stage-1",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(H3,{})})}),d.jsx(q,{path:"/tech-lead/assessment/stage-2",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(K3,{})})}),d.jsx(q,{path:"/tech-lead/assessment/stage-3",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(G3,{})})}),d.jsx(q,{path:"/tech-lead/assessment-confirmation",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Q3,{})})}),d.jsx(q,{path:"/tech-lead/assessment-lockdown",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Y3,{})})}),d.jsx(q,{path:"/tech-lead/tech-assessment/:techAssessmentId",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(J3,{})})}),d.jsx(q,{path:"/tech-lead/assessment/results/:attemptId",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(X3,{})})}),d.jsx(q,{path:"/tech-lead/skill-update-assessment",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Skill Update Assessment",children:d.jsx(Z3,{})})})}),d.jsx(q,{path:"/tech-lead/skill-update-assessment-level",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Skill Update Assessment",children:d.jsx(eU,{})})})}),d.jsx(q,{path:"/tech-lead/skill-update-confirmation/:assessmentId",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(tU,{})})}),d.jsx(q,{path:"/tech-lead/skill-update-results/:attemptId",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(rU,{})})}),d.jsx(q,{path:"/tech-lead/onboarding-wizard",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(nU,{})})}),d.jsx(q,{path:"/tech-lead/onboarding-assessment",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(sU,{})})}),d.jsx(q,{path:"/tech-lead/onboarding-results",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(oU,{})})}),d.jsx(q,{path:"/tech-lead/pending-review",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(iU,{})})}),d.jsx(q,{path:"/dashboard",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(Hw,{})})}),d.jsx(q,{path:"/xterns/dashboard",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(DF,{})})}),d.jsx(q,{path:"/xterns/project-hub",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Project Hub",children:d.jsx(FF,{})})})}),d.jsx(q,{path:"/xterns/profile",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Profile",accessLevel:"open",children:d.jsx(QF,{})})})}),d.jsx(q,{path:"/xterns/projects",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Projects",children:d.jsx(MF,{})})})}),d.jsx(q,{path:"/xterns/pods",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Pod Collaboration",children:d.jsx($F,{})})})}),d.jsx(q,{path:"/xterns/sprint-board",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Sprint Board",children:d.jsx(ZF,{})})})}),d.jsx(q,{path:"/xterns/sprint-history",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Sprint History",children:d.jsx(n3,{})})})}),d.jsx(q,{path:"/xterns/sprint-selection",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Sprint Selection",children:d.jsx(e3,{})})})}),d.jsx(q,{path:"/xterns/ei-tracker",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Signal Score",children:d.jsx(UF,{})})})}),d.jsx(q,{path:"/xterns/skill-update-wizard",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Skill Update",children:d.jsx(s3,{})})})}),d.jsx(q,{path:"/xterns/skill-update-assessment",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Skill Update Assessment",children:d.jsx(o3,{})})})}),d.jsx(q,{path:"/xterns/cv/:section",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"CV Builder",accessLevel:"open",children:d.jsx(Yw,{})})})}),d.jsx(q,{path:"/xterns/cv",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"CV Builder",accessLevel:"open",children:d.jsx(zF,{})})})}),d.jsx(q,{path:"/xterns/learning",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Learning Resources",accessLevel:"open",children:d.jsx(BF,{})})})}),d.jsx(q,{path:"/xterns/learning/resource/:resourceId",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Learning Resources",accessLevel:"open",children:d.jsx(qF,{})})})}),d.jsx(q,{path:"/xterns/career",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Career Development",accessLevel:"open",children:d.jsx(VF,{})})})}),d.jsx(q,{path:"/xterns/jobs",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Job Opportunities",accessLevel:"open",children:d.jsx(Kw,{})})})}),d.jsx(q,{path:"/xterns/jobs/:opportunityId",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Job Opportunities",accessLevel:"open",children:d.jsx(Kw,{})})})}
420),d.jsx(q,{path:"/xterns/opportunities/:opportunityId/workspace/:section?",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Simulation Workspace",accessLevel:"open",children:d.jsx(WF,{})})})}),d.jsx(q,{path:"/xterns/community",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Community",children:d.jsx(HF,{})})})}),d.jsx(q,{path:"/xterns/notifications",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Notifications",children:d.jsx(KF,{})})})}),d.jsx(q,{path:"/xterns/recognition",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Recognition",children:d.jsx(GF,{})})})}),d.jsx(q,{path:"/xterns/settings",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Settings",accessLevel:"open",children:d.jsx(YF,{})})})}),d.jsx(q,{path:"/xterns/settings-enhanced",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Settings",accessLevel:"open",children:d.jsx(JF,{})})})}),d.jsx(q,{path:"/xterns/sprint-board-swimlanes",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Sprint Swimlanes",children:d.jsx(XF,{})})})}),d.jsx(q,{path:"/xterns/calendar",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Calendar and Meetings",children:d.jsx(t3,{})})})}),d.jsx(q,{path:"/xterns/sprint-assessment/:sprintAssessmentId",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Sprint Assessment",children:d.jsx(r3,{})})})}),d.jsx(q,{path:"/templates",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Templates",children:d.jsx(Jw,{})})})}),d.jsx(q,{path:"/talent",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Talent Search",children:d.jsx(Xw,{})})})}),d.jsx(q,{path:"/project/publish",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Project Publishing",children:d.jsx(vU,{})})})}),d.jsx(q,{path:"/roadmap",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(tt,{children:d.jsx(wU,{})})})}),d.jsx(q,{path:"/assessments",element:d.jsx(te,{requiredUserType:"any",children:d.jsx(hU,{})})}),d.jsx(q,{path:"/practice-assessment/:id",element:d.jsx(te,{requiredUserType:"any",children:d.jsx(pU,{})})}),d.jsx(q,{path:"/enterprise/dashboard",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(Hw,{})})}),d.jsx(q,{path:"/enterprise/projects",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(cU,{})})}),d.jsx(q,{path:"/enterprise/templates",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(Jw,{})})}),d.jsx(q,{path:"/enterprise/talent",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(Xw,{})})}),d.jsx(q,{path:"/enterprise/opportunities",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(uU,{})})}),d.jsx(q,{path:"/enterprise/opportunities/create",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(dU,{})})}),d.jsx(q,{path:"/enterprise/opportunities/:opportunityId",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(fU,{})})}),d.jsx(q,{path:"/enterprise/invite-candidates",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(Zw,{})})}),d.jsx(q,{path:"/invite-candidates",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(Zw,{})})}),d.jsx(q,{path:"/enterprise/assessment-analytics/:invitationId",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(mU,{})})}),d.jsx(q,{path:"/enterprise/assessment-results",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(gU,{})})}),d.jsx(q,{path:"/enterprise/sponsorships",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(bU,{})})}),d.jsx(q,{path:"/enterprise/marketplace",element:d.jsx(te,{requiredUserType:"corporate",children:d.jsx(eb,{})})}),d.jsx(q,{path:"/xterns/marketplace",element:d.jsx(te,{requiredUserType:"xtern",children:d.jsx(tt,{requiredForFeature:"Pod Marketplace",children:d.jsx(eb,{})})})}),d.jsx(q,{path:"/admin/invite-candidates",element:d.jsx(KL,{children:d.jsx(yU,{})})}),d.jsx(q,{path:"/client/dashboard",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(i3,{})})}),d.jsx(q,{path:"/client/projects",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(a3,{})})}),d.jsx(q,{path:"/client/pods",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(l3,{})})}),d.jsx(q,{path:"/client/pods/:podId/setup",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(u3,{})})}),d.jsx(q,{path:"/client/pods/:podId",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(c3,{})})}),d.jsx(q,{path:"/client/sprints",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(d3,{})})}),d.jsx(q,{path:"/client/analytics",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(f3,{})})}),d.jsx(q,{path:"/client/accelerator",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(h3,{})})}),d.jsx(q,{path:"/client/accelerator/new",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(Gw,{})})}),d.jsx(q,{path:"/client/accelerator/:programmeId/setup",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(Gw,{})})}),d.jsx(q,{path:"/client/accelerator/:programmeId/landing-page",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(p3,{})})}),d.jsx(q,{path:"/client/accelerator/:programmeId/application-form",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(m3,{})})}),d.jsx(q,{path:"/client/accelerator/:programmeId/application-review",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(g3,{})})}),d.jsx(q,{path:"/client/accelerator/:programmeId/pod-assignments",element:d.jsx(te,{requiredUserType:"client",children:d.jsx(v3,{})})}),d.jsx(q,{path:"/tech-lead/dashboard",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(x3,{})})}),d.jsx(q,{path:"/tech-lead/project-hub",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Project Hub",children:d.jsx(Qw,{})})})}),d.jsx(q,{path:"/techlead-project-hub",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Project Hub",children:d.jsx(Qw,{})})})}),d.jsx(q,{path:"/tech-lead/pods",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Pod Management",children:d.jsx(_3,{})})})}),d.jsx(q,{path:"/tech-lead/pod-management",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Pod Management",children:d.jsx(S3,{})})})}),d.jsx(q,{path:"/tech-lead/invitations",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Invitation Management",children:d.jsx(k3,{})})})}),d.jsx(q,{path:"/tech-lead/github-integration",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"GitHub Integration",children:d.jsx(E3,{})})})}
420),d.jsx(q,{path:"/tech-lead/sprint-board-pods",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Sprint Boards",children:d.jsx(P3,{})})})}),d.jsx(q,{path:"/tech-lead/sprint-board",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Sprint Board",children:d.jsx(j3,{})})})}),d.jsx(q,{path:"/tech-lead/sprint-board-swimlanes",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Sprint Swimlanes",children:d.jsx(O3,{})})})}),d.jsx(q,{path:"/tech-lead/delivery-plan-creation",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Delivery Plan Creation",children:d.jsx(R3,{})})})}),d.jsx(q,{path:"/tech-lead/calendar",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Calendar and Meetings",children:d.jsx(T3,{})})})}),d.jsx(q,{path:"/tech-lead/notifications",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Notifications",children:d.jsx(A3,{})})})}),d.jsx(q,{path:"/tech-lead/sla-dashboard",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"SLA Dashboard",children:d.jsx(N3,{})})})}),d.jsx(q,{path:"/tech-lead/csat-dashboard",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"My Ratings",children:d.jsx(I3,{})})})}),d.jsx(q,{path:"/tech-lead/profile",element:d.jsx(te,{requiredUserType:"tech_lead",children:d.jsx(Wt,{showInlinePrompt:!0,requiredForFeature:"Profile Management",children:d.jsx(C3,{})})})}),d.jsx(q,{path:"*",element:d.jsx(cF,{})})]})}),d.jsx(VL,{isOpen:t,onSelect:r,availableRoles:n()})]})},_U=()=>{const[e,t]=v.useState(!1),r=()=>{t(!e)};return d.jsxs(d.Fragment,{children:[d.jsx("button",{onClick:r,style:{position:"fixed",bottom:"24px",right:"24px",width:"60px",height:"60px",borderRadius:"50%",backgroundColor:"#0066cc",color:"white",border:"none",cursor:"pointer",boxShadow:"0 4px 12px rgba(0, 102, 204, 0.4)",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"24px",zIndex:9998,transition:"all 0.3s ease"},onMouseOver:n=>{n.currentTarget.style.transform="scale(1.1)",n.currentTarget.style.backgroundColor="#0052a3"},onFocus:n=>{n.currentTarget.style.transform="scale(1.1)",n.currentTarget.style.backgroundColor="#0052a3"},onMouseOut:n=>{n.currentTarget.style.transform="scale(1)",n.currentTarget.style.backgroundColor="#0066cc"},onBlur:n=>{n.currentTarget.style.transform="scale(1)",n.currentTarget.style.backgroundColor="#0066cc"},"aria-label":"Open support chat",children:e?"✕":"💬"}),e&&d.jsxs(d.Fragment,{children:[d.jsx("div",{role:"button",tabIndex:0,"aria-label":"Close support chat overlay",onClick:r,onKeyDown:n=>{(n.key==="Enter"||n.key===" "||n.key==="Spacebar"||n.keyCode===13||n.keyCode===32)&&(n.preventDefault(),r())},style:{position:"fixed",top:0,left:0,right:0,bottom:0,backgroundColor:"rgba(0, 0, 0, 0.5)",zIndex:9998}}),d.jsxs("div",{style:{position:"fixed",bottom:"100px",right:"24px",width:"580px",maxWidth:"calc(100vw - 48px)",height:"600px",maxHeight:"calc(100vh - 150px)",backgroundColor:"white",borderRadius:"12px",boxShadow:"0 8px 24px rgba(0, 0, 0, 0.2)",zIndex:9999,overflow:"hidden",display:"flex",flexDirection:"column"},children:[d.jsxs("div",{style:{backgroundColor:"#0066cc",color:"white",padding:"16px 20px",display:"flex",justifyContent:"space-between",alignItems:"center"},children:[d.jsxs("div",{children:[d.jsx("h3",{style:{margin:0,fontSize:"18px",fontWeight:"600"},children:"Contact Support"}),d.jsx("p",{style:{margin:"4px 0 0 0",fontSize:"13px",opacity:.9},children:"We're here to help"})]}),d.jsx("button",{onClick:r,style:{background:"transparent",border:"none",color:"white",fontSize:"24px",cursor:"pointer",padding:"0",width:"32px",height:"32px",display:"flex",alignItems:"center",justifyContent:"center"},"aria-label":"Close",children:"✕"})]}),d.jsx("iframe",{id:"zsfeedbackFrame",name:"zsfeedbackFrame",scrolling:"no",frameBorder:"0",src:"https://desk.zoho.com/support/fbw?formType=AdvancedWebForm&fbwId=edbsn147788405a6b3cd8b979b79fbb0d95218d684d92018c215929cdc5a4584cd666&xnQsjsdp=edbsnec088c9ab42567ea64eaf3e95cfadf17&mode=showNewWidget&displayType=iframe",title:"Zoho Desk Feedback Widget",style:{width:"100%",height:"100%",border:"none",flex:1}})]})]})]})},SU=({children:e})=>{const[t,r]=v.useState(!0),[n,i]=v.useState(0),[a,l]=v.useState(0),u=v.useRef(null),f=v.useRef(null),p=3e4,m=v.useCallback(async()=>{try{const{error:b}=await me.from("platform_settings").select("id").limit(1);return!(b&&(console.warn("[HealthGuard] Supabase query error:",b.message),b.message.includes("fetch")||b.message.includes("network")||b.message.includes("522")))}catch(b){return console.warn("[HealthGuard] Supabase unreachable:",b),!1}},[]),g=v.useCallback(b=>{const w=Math.min(2e3*Math.pow(2,b),p);l(Math.ceil(w/1e3)),f.current&&clearInterval(f.current);let S=Math.ceil(w/1e3);f.current=setInterval(()=>{S-=1,l(Math.max(0,S)),S<=0&&f.current&&clearInterval(f.current)},1e3),u.current=setTimeout(async()=>
420{if(await m())r(!0),i(0),l(0);else{const E=b+1;i(E),g(E)}},w)},[m]);return v.useEffect(()=>{const b="https://cfcvcgojltawrodgtjnc.supabase.co",w=window.fetch;return window.fetch=async(...S)=>{var _,E;try{const k=await w(...S);return(typeof S[0]=="string"?S[0]:((_=S[0])==null?void 0:_.url)||"").startsWith(b)&&k.status===522&&(console.error("[HealthGuard] 522 detected from Supabase"),r(!1),i(0),g(0)),k}catch(k){throw(typeof S[0]=="string"?S[0]:((E=S[0])==null?void 0:E.url)||"").startsWith(b)&&(console.error("[HealthGuard] Network error to Supabase:",k),r(!1),i(0),g(0)),k}},()=>{window.fetch=w,u.current&&clearTimeout(u.current),f.current&&clearInterval(f.current)}},[g]),t?d.jsx(d.Fragment,{children:e}):d.jsxs(d.Fragment,{children:[e,d.jsx("div",{className:"fixed inset-0 z-[9999] flex items-center justify-center bg-background/80 backdrop-blur-sm",children:d.jsxs("div",{className:"mx-4 max-w-md rounded-lg border border-border bg-card p-8 text-center shadow-xl",children:[d.jsx("div",{className:"mx-auto mb-4 h-12 w-12 animate-pulse rounded-full bg-destructive/20 flex items-center justify-center",children:d.jsx("svg",{className:"h-6 w-6 text-destructive",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 9v2m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})})}),d.jsx("h2",{className:"mb-2 text-lg font-semibold text-foreground",children:"Service Temporarily Unavailable"}),d.jsx("p",{className:"mb-4 text-sm text-muted-foreground",children:"We're having trouble connecting to our servers. This is usually temporary."}),d.jsx("p",{className:"text-xs text-muted-foreground",children:a>0?`Retrying in ${a}s... (attempt ${n+1})`:"Retrying now..."}),d.jsx("button",{onClick:()=>{u.current&&clearTimeout(u.current),f.current&&clearInterval(f.current),m().then(b=>{b?(r(!0),i(0)):g(n)})},className:"mt-4 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground hover:bg-primary/90 transition-colors",children:"Retry Now"})]})})]})};function EU(){return d.jsxs(d.Fragment,{children:[d.jsx(_U,{}),d.jsx(SU,{children:d.jsx(lC,{children:d.jsx(PA,{children:d.jsx(jA,{children:d.jsxs(LL,{children:[d.jsx(qC,{}),d.jsx(YP,{}),d.jsx(xU,{})]})})})})})]})}const kU=new Yk({defaultOptions:{queries:{staleTime:1e3*60*5,retry:1}}});kk.createRoot(document.getElementById("root")).render(d.jsx(Jk,{client:kU,children:d.jsx(EU,{})}));export{cx as $,dx as A,bt as B,rP as C,YR as D,zu as E,eP as F,iP as G,e0 as H,mS as I,Mp as J,GR as K,Lt as L,Eb as M,fm as N,od as O,dE as P,hm as Q,px as R,fp as S,pP as T,vx as U,pm as V,gx as W,Hu as X,EL as Y,qp as Z,LU as _,fu as a,Oo as a$,Ew as a0,xE as a1,_E as a2,SE as a3,lh as a4,oP as a5,yS as a6,nP as a7,RU as a8,QR as a9,Is as aA,Vi as aB,rn as aC,oL as aD,b2 as aE,L_ as aF,C_ as aG,Bu as aH,SM as aI,EM as aJ,Ei as aK,HM as aL,md as aM,Rm as aN,Pm as aO,Om as aP,ZS as aQ,eE as aR,tE as aS,Lu as aT,Ya as aU,Du as aV,cP as aW,o$ as aX,jm as aY,t$ as aZ,hx as a_,KM as aa,GM as ab,JS as ac,Q$ as ad,$b as ae,nD as af,bS as ag,iD as ah,aD as ai,tP as aj,id as ak,_l as al,bl as am,qu as an,xM as ao,gu as ap,Gt as aq,Fr as ar,xt as as,IS as at,eR as au,FL as av,ER as aw,_M as ax,ut as ay,Kp as az,ZR as b,Fb as b0,Co as b1,de as b2,AL as b3,AU as b4,CU as b5,yl as b6,qh as b7,Ja as b8,Kk as b9,rT as bA,nT as bB,aT as bC,Ny as bD,sT as bE,tt as bF,lP as bG,DU as bH,sP as bI,sE as bJ,zh as bK,G$ as bL,H as bM,aP as bN,$L as bO,HL as bP,jU as bQ,OU as bR,Kt as ba,yr as bb,mb as bc,oS as bd,Z_ as be,xL as bf,NU as bg,eS as bh,IU as bi,rd as bj,nd as bk,sd as bl,tS as bm,td as bn,wi as bo,w$ as bp,SL as bq,fx as br,ym as bs,Mw as bt,n$ as bu,hb as bv,Bk as bw,Xk as bx,tT as by,oT as bz,Ge as c,XR as d,hu as e,ar as f,ap as g,$s as h,Fs as i,d as j,Us as k,mm as l,ko as m,hS as n,PU as o,dP as p,JR as q,v as r,me as s,Pe as t,jo as u,Ji as v,G as w,t0 as x,mx as y,Po as z};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.