ryugi-artifacts 1.113.3 → 1.115.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. package/dist/cli.cjs +180 -177
  2. package/dist/document-engine.cjs +381 -381
  3. package/dist/output-bootstrap.cjs +18 -3
  4. package/dist/viewer/{AgentDock-DO3wjCT6.js → AgentDock-CH6Ykvym.js} +1 -1
  5. package/dist/viewer/{ArtboardLayout-CWx1_DVU.js → ArtboardLayout-BoYjJscp.js} +4 -4
  6. package/dist/viewer/ArtifactList-uj-q3W1q.js +2 -0
  7. package/dist/viewer/{ArtifactModal-DfZqI4AY.js → ArtifactModal-C5mrDL4r.js} +1 -1
  8. package/dist/viewer/{BottomSheet-DHasPJPu.js → BottomSheet-IPyTloz4.js} +1 -1
  9. package/dist/viewer/{RyugiMark-Dyu4ej9h.js → BrandingMark-BMinTxVM.js} +1 -1
  10. package/dist/viewer/{Canvas-C5NJh3wF.js → Canvas-CCJt5GBL.js} +1 -1
  11. package/dist/viewer/{CommentPopover-GqGMqaHP.js → CommentPopover-BgaTBWoa.js} +1 -1
  12. package/dist/viewer/{DocumentExportMenu-8sZID_nO.js → DocumentExportMenu-BRaYTbF_.js} +1 -1
  13. package/dist/viewer/DocumentLayout-Cz3hhXPR.js +2 -0
  14. package/dist/viewer/{DocumentPage-CcmkTxH-.js → DocumentPage-CZiEPrnj.js} +3 -3
  15. package/dist/viewer/{DraggablePanel-BuFi6njZ.js → DraggablePanel-DpBrlowL.js} +1 -1
  16. package/dist/viewer/{DropdownMenu-CM7q1CMp.js → DropdownMenu-NA_XxVZB.js} +1 -1
  17. package/dist/viewer/{GroupVerdict-DeeQUfkG.js → GroupVerdict-itgmpXO9.js} +1 -1
  18. package/dist/viewer/{HtmlLayout-vlPq4J9Y.js → HtmlLayout-DBJCJRWj.js} +1 -1
  19. package/dist/viewer/{Input-CVcfIqt2.js → Input-CIa1R1G9.js} +1 -1
  20. package/dist/viewer/{MenuSubmenuTrigger-BczoxS9k.js → MenuSubmenuTrigger-B1GRjbbe.js} +1 -1
  21. package/dist/viewer/{PhoneArtboardBar-BK3M_psy.js → PhoneArtboardBar-BQw7xexp.js} +1 -1
  22. package/dist/viewer/{Popover-O6mMCn1S.js → Popover-D8lFLEo-.js} +1 -1
  23. package/dist/viewer/PreviewArtifactLayout-BIGmZXGw.js +1 -0
  24. package/dist/viewer/{PreviewLayout-C5knCbv-.js → PreviewLayout-BmJ39T9v.js} +2 -2
  25. package/dist/viewer/{ReportLayout-BD1bNPfi.js → ReportLayout-68jrSHuE.js} +2 -2
  26. package/dist/viewer/{Segmented-Clhtb1CD.js → Segmented-Bbax5uqk.js} +1 -1
  27. package/dist/viewer/{SelectScrollUpArrow-CTGOrluu.js → SelectScrollUpArrow-BbJtTBmP.js} +1 -1
  28. package/dist/viewer/{SlidesLayout-8j14xYA-.js → SlidesLayout-vo3ppRgW.js} +4 -4
  29. package/dist/viewer/{SnapshotDocument-CnqXgo4y.js → SnapshotDocument-DS6l1jwP.js} +1 -1
  30. package/dist/viewer/{SplitFrame-CQ3lXrch.js → SplitFrame-D6BLXuFm.js} +1 -1
  31. package/dist/viewer/{StoryboardLayout-zpUwF5xF.js → StoryboardLayout-BqJngaoz.js} +1 -1
  32. package/dist/viewer/{StoryboardRender--NOzkhyN.js → StoryboardRender-0aFMSadj.js} +1 -1
  33. package/dist/viewer/{ThreadView-OBDIwTkP.js → ThreadView-ChVeZPH-.js} +1 -1
  34. package/dist/viewer/{Tooltip-DX1QlxEQ.js → Tooltip-Cd3a5ILg.js} +1 -1
  35. package/dist/viewer/{VerifyLayout-Usn3NkOU.js → VerifyLayout-CaugP8cx.js} +1 -1
  36. package/dist/viewer/{VirtualizedEditor-uWe43zaI-C5Sahl_l.js → VirtualizedEditor-uWe43zaI-Fu03GlYD.js} +1 -1
  37. package/dist/viewer/{VirtualizedRenderer-C_d95FXi-BpaHPQz0.js → VirtualizedRenderer-C_d95FXi-Cv8_J1w4.js} +1 -1
  38. package/dist/viewer/{WarningsBadge-DGnz2zmy.js → WarningsBadge-6ZtNX9sd.js} +1 -1
  39. package/dist/viewer/{WhiteboardEditor-DrHOvXez-JWa5PVHK.js → WhiteboardEditor-DrHOvXez-BewOBKRS.js} +1 -1
  40. package/dist/viewer/WhiteboardLayout-C9oGhpGn.js +4 -0
  41. package/dist/viewer/{WritingCursor-CRzyzaVO.js → WritingCursor-DauvJIme.js} +1 -1
  42. package/dist/viewer/{agentLook-CU806djA.js → agentLook-B5foAwJ4.js} +1 -1
  43. package/dist/viewer/app-icon-CEU9ZLB-.png +0 -0
  44. package/dist/viewer/app-icon-DYGC0Tkn.svg +1 -0
  45. package/dist/viewer/{artifact-list-B9KTDzUh.js → artifact-list-9ZLo_0qZ.js} +1 -1
  46. package/dist/viewer/{auto-publish-GJrN3H-Y.js → auto-publish-89R-LJph.js} +1 -1
  47. package/dist/viewer/{channel-CF9EHtSL.js → channel-C1USfAvL.js} +3 -3
  48. package/dist/viewer/{crop-encode-C1SdKlik.js → crop-encode-BOXz_WBQ.js} +1 -1
  49. package/dist/viewer/{dist-CzD--XrY.js → dist--Z_ipYl1.js} +1 -1
  50. package/dist/viewer/{dist-CiMWQRhQ.js → dist--yOSqFYM.js} +1 -1
  51. package/dist/viewer/{dist-DxngwfWH.js → dist-51i-jmw9.js} +1 -1
  52. package/dist/viewer/{dist-BHga6o7i.js → dist-6il6ungj.js} +1 -1
  53. package/dist/viewer/{dist-DTD3yXBi.js → dist-BB2CzNH5.js} +1 -1
  54. package/dist/viewer/{dist-BaGZx4vf.js → dist-BL2zRMAs.js} +1 -1
  55. package/dist/viewer/{dist-D4as0PD-.js → dist-BaxTLfF9.js} +1 -1
  56. package/dist/viewer/{dist-BNB-dtd1.js → dist-BoWoFylE.js} +1 -1
  57. package/dist/viewer/{dist-_D5xLBBO.js → dist-ByQtqN_D.js} +1 -1
  58. package/dist/viewer/{dist-B0qXxOuX.js → dist-ByuHK6Lu.js} +1 -1
  59. package/dist/viewer/{dist-B_dCTH8c.js → dist-CIIWl59b.js} +1 -1
  60. package/dist/viewer/{dist-Dfck1z2n.js → dist-CUIIyopw.js} +1 -1
  61. package/dist/viewer/{dist-BDGp5lli.js → dist-CYF35EdI.js} +1 -1
  62. package/dist/viewer/{dist-Bgia1wnJ.js → dist-CaPAmSdE.js} +1 -1
  63. package/dist/viewer/{dist-Dmr_aVAS.js → dist-CjC2787O.js} +1 -1
  64. package/dist/viewer/{dist-BWDri6GH.js → dist-CuvOSXJh.js} +1 -1
  65. package/dist/viewer/{dist-CsBIrCGx.js → dist-DCrTJsdu.js} +1 -1
  66. package/dist/viewer/{dist-Cj74Rdec.js → dist-DHXQnea3.js} +1 -1
  67. package/dist/viewer/{dist-Dn_o36dG.js → dist-DSuLHq_u.js} +1 -1
  68. package/dist/viewer/dist-Dow23TfB.js +1 -0
  69. package/dist/viewer/{dist-B3-vnt93.js → dist-DtXXt7a4.js} +1 -1
  70. package/dist/viewer/{dist-C4H1ECie.js → dist-MC6I6nQE.js} +1 -1
  71. package/dist/viewer/{dist-vsF0cCGK.js → dist-iRVjkEzT.js} +1 -1
  72. package/dist/viewer/{dist-CJucIoCR.js → dist-uI-2T5ED.js} +1 -1
  73. package/dist/viewer/{editor-DHJQC-c0.js → editor-BA7mo2fo.js} +4 -4
  74. package/dist/viewer/{fit-BgVy5mbn.js → fit-DF-RHcFl.js} +1 -1
  75. package/dist/viewer/{icons-BwlHhLMH.js → icons-CaBMvHC2.js} +1 -1
  76. package/dist/viewer/{imperative-D1UIq_CR.js → imperative-BNlnuZ6l.js} +1 -1
  77. package/dist/viewer/index.html +16 -16
  78. package/dist/viewer/index.js +2 -2
  79. package/dist/viewer/index5.css +164 -106
  80. package/dist/viewer/{local-CvTEMav_.js → local-DGEGKhEk.js} +1 -1
  81. package/dist/viewer/{local-split-host-DOfRlsgx.js → local-split-host-BtzqQOET.js} +1 -1
  82. package/dist/viewer/plugin-_bGVeqI0-ajuQLIjY.js +2 -0
  83. package/dist/viewer/preview.html +3 -3
  84. package/dist/viewer/preview.js +1 -1
  85. package/dist/viewer/{printDocument-CUNshxwb.js → printDocument-DTucYRWz.js} +1 -1
  86. package/dist/viewer/{ref-Bj5JiHki.js → ref-Cv0JhjU5.js} +1 -1
  87. package/dist/viewer/{route-Csi4PU7w.js → route-C7yP-PEQ.js} +10 -10
  88. package/dist/viewer/{route-messages-DeWSMVNI.js → route-messages-Cd15UR6N.js} +1 -1
  89. package/dist/viewer/{settings-Ccw15Eyz.js → settings-BZwlhQsp.js} +1 -1
  90. package/dist/viewer/{snap-B7T8Fi-t.js → snap-DD8dHw6I.js} +1 -1
  91. package/dist/viewer/{split-DYwwKqIa.js → split-Clr7jYGP.js} +2 -2
  92. package/dist/viewer/{stable-CwENW2fR.js → stable-DU_-8Jo1.js} +1 -1
  93. package/dist/viewer/{styles-clvPUBbJ.js → styles-CdPIply-.js} +1 -1
  94. package/dist/viewer/{transport-CSbo3sV6.js → transport-DusCV1zV.js} +1 -1
  95. package/dist/viewer/{url-D8qiZRqE.js → url-CCmcoMys.js} +1 -1
  96. package/dist/viewer/{useArtifactFeed-1e4jVUAL.js → useArtifactFeed-jfvAzTGY.js} +1 -1
  97. package/dist/viewer/{useArtifactSocket-wqYKSfgz.js → useArtifactSocket-BA04npYU.js} +1 -1
  98. package/dist/viewer/{useLayerZIndex-D4jsmz12.js → useLayerZIndex-xDNOdXYr.js} +1 -1
  99. package/dist/viewer/{useStoryboardData-aWqqHGVH.js → useStoryboardData-CiapuT5g.js} +1 -1
  100. package/dist/viewer/{view-ClWzCAjM.js → view-BeeaUcIu.js} +1 -1
  101. package/dist/viewer/{viewport-CFJHn_Y6--n1vZkKz.js → viewport-CFJHn_Y6-BjAPnbEH.js} +1 -1
  102. package/package.json +2 -2
  103. package/dist/viewer/ArtifactList-DtgRku6l.js +0 -2
  104. package/dist/viewer/DocumentLayout-CJ59MGXp.js +0 -2
  105. package/dist/viewer/PreviewArtifactLayout-KGeS-A9y.js +0 -1
  106. package/dist/viewer/WhiteboardLayout-Dd8Uh61C.js +0 -4
  107. package/dist/viewer/app-icon-6WJOuhLx.svg +0 -1
  108. package/dist/viewer/app-icon-Bm9-i4yr.png +0 -0
  109. package/dist/viewer/dist-CyHqzrxc.js +0 -1
  110. package/dist/viewer/plugin-_bGVeqI0-DZgj9wju.js +0 -2
@@ -1,2 +1,2 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./AgentDock-DO3wjCT6.js","./rolldown-runtime-XKyaHtl9.js","./route-Csi4PU7w.js","./bem-vbke-3KC.js","./react-DlmbjZJV.js","./jsx-runtime-LKYXHABd.js","./types-BCsOeYI6.js","./index2.css","./BottomSheet-DHasPJPu.js","./motion-Cy65kd7X.js","./useMedia-CFebB4XU.js","./agentLook-CU806djA.js","./icons-BwlHhLMH.js","./MotionConfigContext-HC2vqcJO.js","./arrow-up-right-0KreI6kY.js","./chevron-left-C5itNrp5.js","./url-D8qiZRqE.js","./useLayerZIndex-D4jsmz12.js","./is-html-element-DvgHo_1h.js","./chevron-right-xNdXLJg6.js","./ArtboardLayout-CWx1_DVU.js","./useArtifactFeed-1e4jVUAL.js","./transport-CSbo3sV6.js","./useArtifactSocket-wqYKSfgz.js","./view-ClWzCAjM.js","./rounds-BLj-tfMG.js","./imperative-D1UIq_CR.js","./Popover-O6mMCn1S.js","./sliders-horizontal-CuS3-UwA.js","./Canvas-C5NJh3wF.js","./cssVar.stylex-CGbpAC1Y.js","./WritingCursor-CRzyzaVO.js","./maximize-2-Bc0lXBg6.js","./PlaybackIcon-D-vfZnSv.js","./elements-CmGVWYag.js","./snap-B7T8Fi-t.js","./local-CvTEMav_.js","./SelectScrollUpArrow-CTGOrluu.js","./undo-2-B-JiyKIl.js","./stable-CwENW2fR.js","./Tooltip-DX1QlxEQ.js","./styles-clvPUBbJ.js","./stringifyLocale-D0juOOnH.js","./Input-CVcfIqt2.js","./PhoneArtboardBar-BK3M_psy.js","./DropdownMenu-CM7q1CMp.js","./MenuSubmenuTrigger-BczoxS9k.js","./index5.css","./crop-encode-C1SdKlik.js","./ThreadView-OBDIwTkP.js","./comments-DUAz1Q9X.js","./folder-BViSPo7g.js","./ruler-CYb0HZGT.js","./mouse-pointer-2-B-OF_fcG.js","./play-6FAfeM1L.js","./Segmented-Clhtb1CD.js","./useTypeFavicon-yXOsFZBx.js","./type-icons-CxYXZlMj.js","./CommentPopover-GqGMqaHP.js","./GroupVerdict-DeeQUfkG.js","./artifact-list-B9KTDzUh.js","./film-A6SU1RGC.js","./code-xml-c9QCqmhY.js","./store-D3ROW536.js","./selection-BWCQd_Fn.js","./ArtboardLayout-DLyi-yDq.css","./DocumentLayout-CJ59MGXp.js","./HtmlLayout-vlPq4J9Y.js","./WarningsBadge-DGnz2zmy.js","./useSandboxFrame-CJmSnwgG.js","./WhiteboardLayout-Dd8Uh61C.js","./shims-s-YVfIlz.js","./pages-DWkRbog-.js","./WhiteboardEditor-DrHOvXez-JWa5PVHK.js","./code-DnmQyGiF.js","./zoom-out-DsmGFv1v.js","./text-align-start-CRhecbJR.js","./plus-DZJ2BVkK.js","./index3.css","./preference-oNdcNeml.js","./DotGrid-DKKr_PyM.js","./message-square-Yl8PoPy_.js","./backlinks-C_k8-LL2.js","./WhiteboardLayout-SRFXrlmW.css","./VerifyLayout-Usn3NkOU.js","./useAssetBase-4Ut9QhBI.js","./editor-DHJQC-c0.js","./pen-tool-BfwjhXQW.js","./underline-CT_nGhA9.js","./external-link-D382oEvK.js","./table-2-D90vZ04E.js","./presentation-DXrcAbwM.js","./search-DTrfkTpJ.js","./upload-DffL3XsM.js","./video-DKoRqEZW.js","./ref-Bj5JiHki.js","./index4.css","./fit-BgVy5mbn.js","./VerifyLayout-B9e4RHAZ.css","./SlidesLayout-8j14xYA-.js","./local-split-host-DOfRlsgx.js","./monitor-DRrnx_H5.js","./DocumentExportMenu-8sZID_nO.js","./DraggablePanel-BuFi6njZ.js","./embed-src-CmyqZplg.js","./SlidesLayout-Bjds2UXz.css","./ReportLayout-BD1bNPfi.js","./StoryboardLayout-zpUwF5xF.js","./useStoryboardData-aWqqHGVH.js","./clapperboard-BfpJ7tpa.js","./StoryboardRender--NOzkhyN.js","./PreviewArtifactLayout-KGeS-A9y.js","./RyugiMark-Dyu4ej9h.js","./auto-publish-GJrN3H-Y.js","./cloud-upload-D8TpApTr.js","./settings-Ccw15Eyz.js","./read-marks-CVVWpIvf.js","./ArtifactList-DtgRku6l.js","./split-DYwwKqIa.js","./SplitFrame-CQ3lXrch.js","./route-messages-DeWSMVNI.js","./PreviewLayout-C5knCbv-.js"])))=>i.map(i=>d[i]);
2
- import{n as e,r as t}from"./rolldown-runtime-XKyaHtl9.js";import{C as n,D as r,E as i,M as a,N as o,S as s,T as c,_ as l,a as u,b as d,f,h as p,m,n as h,o as g,p as _,s as v,t as y,v as b,w as x,x as S}from"./route-Csi4PU7w.js";/* empty css */import{An as C,Ar as w,At as T,Bt as E,C as D,Cr as O,Ct as k,Dt as A,Er as j,Et as ee,Ft as M,Gt as te,Ht as N,It as P,J as ne,Kt as re,Mr as ie,Mt as F,N as ae,Nt as I,On as oe,Ot as se,Pt as ce,Qt as le,Rt as ue,Sr as de,St as fe,Tr as pe,Tt as me,Ut as he,Vt as ge,Wt as _e,Xt as ve,Y as ye,Yt as be,Zt as xe,_ as Se,_t as Ce,at as L,b as we,bt as Te,dt as Ee,ft as De,g as Oe,gr as ke,gt as Ae,hr as je,ht as Me,i as Ne,in as Pe,it as R,j as Fe,jn as Ie,jr as Le,jt as Re,kr as ze,kt as Be,lr as Ve,mr as He,mt as Ue,ot as We,pr as Ge,pt as Ke,qt as qe,rt as Je,sr as Ye,tn as Xe,u as Ze,ur as Qe,ut as $e,v as et,vr as tt,vt as nt,w as rt,wn as it,wr as at,wt as ot,xt as st,yr as ct,yt as lt,zt as ut}from"./url-D8qiZRqE.js";import{$r as dt,C as ft,Dn as pt,En as mt,Fn as ht,Ft as gt,Gr as _t,Hr as vt,It as yt,Kr as bt,Pn as xt,Sn as St,Tn as Ct,Vr as wt,Xr as Tt,Yr as Et,Zr as Dt,ii as z,kr as Ot,oi as kt,or as At,qn as jt,ri as B,rr as Mt,t as Nt,zr as Pt}from"./useLayerZIndex-D4jsmz12.js";import{n as Ft,r as V,t as It}from"./bem-vbke-3KC.js";import{t as Lt}from"./react-DlmbjZJV.js";import{a as Rt,i as zt,l as Bt,n as Vt,o as Ht,r as Ut,s as Wt,t as Gt}from"./DropdownMenu-CM7q1CMp.js";import{A as Kt,f as qt,t as Jt}from"./Popover-O6mMCn1S.js";import{t as Yt}from"./jsx-runtime-LKYXHABd.js";import{a as Xt,i as Zt,n as Qt,o as $t,r as en,s as tn,t as nn}from"./store-D3ROW536.js";import{n as rn,t as an}from"./imperative-D1UIq_CR.js";import{$ as on,B as sn,Ct as cn,Dt as ln,Et as un,G as dn,I as fn,J as pn,M as mn,N as hn,P as gn,St as _n,Tt as vn,U as yn,W as H,_t as bn,a as xn,bt as Sn,c as Cn,ct as wn,d as Tn,dt as En,et as Dn,gt as On,h as kn,ht as An,i as jn,l as Mn,m as Nn,mt as Pn,o as Fn,p as In,r as Ln,s as Rn,st as zn,t as Bn,u as Vn,ut as Hn,wt as Un,xt as Wn}from"./MotionConfigContext-HC2vqcJO.js";import{$ as Gn,$n as Kn,$t as qn,A as Jn,An as Yn,At as Xn,B as Zn,Bn as Qn,Bt as $n,C as er,Cn as tr,Cr as nr,Ct as rr,D as ir,Dn as ar,Dt as or,E as sr,En as cr,Et as lr,F as ur,Fn as dr,Ft as fr,G as pr,Gn as mr,Gt as hr,H as gr,Hn as _r,Ht as vr,I as yr,In as br,It as xr,J as Sr,Jn as Cr,Jt as wr,K as Tr,Kn as Er,Kt as Dr,L as Or,Ln as kr,Lt as Ar,M as jr,Mn as Mr,Mt as Nr,N as Pr,Nn as Fr,Nt as Ir,O as Lr,On as Rr,Ot as zr,P as Br,Pn as Vr,Pt as Hr,Q as Ur,Qn as Wr,Qt as Gr,R as Kr,Rn as qr,Rt as Jr,S as Yr,Sn as Xr,Sr as Zr,St as Qr,T as $r,Tn as ei,Tr as ti,Tt as ni,U as ri,Un as ii,Ut as ai,V as oi,Vn as si,Vt as ci,W as li,Wn as ui,Wt as di,X as fi,Xn as pi,Xt as mi,Y as hi,Yn as gi,Yt as _i,Z as vi,Zn as yi,Zt as bi,_ as xi,_n as Si,_r as Ci,_t as wi,a as Ti,an as Ei,ar as Di,at as Oi,b as ki,bn as Ai,br as U,bt as ji,c as Mi,cn as Ni,cr as Pi,ct as Fi,d as Ii,dn as Li,dr as Ri,dt as zi,en as Bi,er as Vi,et as Hi,f as Ui,fn as Wi,fr as Gi,ft as Ki,g as qi,gn as Ji,gr as Yi,gt as Xi,h as Zi,hn as Qi,hr as $i,ht as ea,i as ta,in as na,ir as ra,it as ia,j as aa,jn as oa,jt as sa,k as ca,kn as la,kt as ua,l as da,ln as fa,lr as pa,lt as ma,m as ha,mn as ga,mr as _a,mt as va,n as ya,nn as ba,nr as xa,nt as Sa,o as Ca,on as wa,or as Ta,ot as Ea,p as Da,pn as Oa,pr as ka,pt as Aa,q as ja,qn as Ma,qt as Na,r as Pa,rn as Fa,rr as Ia,rt as La,s as Ra,sn as za,sr as Ba,st as Va,t as Ha,tn as Ua,tr as Wa,tt as Ga,u as Ka,un as qa,ur as Ja,ut as Ya,v as Xa,vn as Za,vr as Qa,vt as $a,w as eo,wn as to,wr as no,wt as ro,x as io,xn as ao,xr as oo,xt as so,y as co,yn as lo,yr as uo,yt as fo,z as po,zn as mo,zt as ho}from"./elements-CmGVWYag.js";import{t as go}from"./is-html-element-DvgHo_1h.js";import{m as _o,p as vo,t as yo}from"./local-CvTEMav_.js";import{r as bo,t as xo}from"./useArtifactSocket-wqYKSfgz.js";import{t as So}from"./DocumentExportMenu-8sZID_nO.js";import{t as Co}from"./arrow-up-right-0KreI6kY.js";import{F as wo,P as To}from"./SelectScrollUpArrow-CTGOrluu.js";import{t as Eo}from"./cloud-upload-D8TpApTr.js";import{t as Do}from"./Tooltip-DX1QlxEQ.js";import{S as Oo,a as ko,c as Ao,d as jo,f as Mo,h as No,i as Po,l as Fo,m as Io,n as Lo,s as Ro,t as zo,u as Bo,x as Vo}from"./MenuSubmenuTrigger-BczoxS9k.js";var Ho={name:`clock-3`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6h4`,key:`135r8i`}]]};Ho.node;var Uo=ln(Ho),Wo={name:`cloud`,size:24,node:[[`path`,{d:`M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z`,key:`p7xjir`}]]};Wo.node;var Go=ln(Wo),Ko={name:`columns-2`,size:24,node:[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M12 3v18`,key:`108xh3`}]],aliases:[`columns`]};Ko.node;var qo=ln(Ko),Jo={name:`credit-card`,size:24,node:[[`rect`,{width:`20`,height:`14`,x:`2`,y:`5`,rx:`2`,key:`ynyp8z`}],[`line`,{x1:`2`,x2:`22`,y1:`10`,y2:`10`,key:`1b3vmo`}],[`path`,{d:`M6 14h2`,key:`mk7k0u`}]]};Jo.node;var Yo=ln(Jo),Xo={name:`key-round`,size:24,node:[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]};Xo.node;var Zo=ln(Xo),Qo={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};Qo.node;var $o=ln(Qo),es={name:`refresh-cw`,size:24,node:[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]};es.node;var ts=ln(es),ns={name:`rotate-cw`,size:24,node:[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]};ns.node;var rs=ln(ns),is={name:`settings`,size:24,node:[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]};is.node;var as=ln(is),os={name:`smartphone`,size:24,node:[[`rect`,{width:`14`,height:`20`,x:`5`,y:`2`,rx:`2`,ry:`2`,key:`1yt0o3`}],[`path`,{d:`M12 18h.01`,key:`mhygvu`}]]};os.node;var ss=ln(os);function cs(e,t,n,r=0,i=1){let a=Array.from(e).sort((e,t)=>e.sortNodePosition(t)).indexOf(t),o=e.size,s=(o-1)*r;return typeof n==`function`?n(a,o):i===1?a*r:s-a*r}function ls(e,t,n){return ti(e.getProps(),t,n,e)}var us=(e,t)=>t===`exit`?e.presenceContext?.custom:void 0,ds=e=>Array.isArray(e);function fs(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Nn(n))}function ps(e){return ds(e)?e[e.length-1]||0:e}function ms(e,t){let{transitionEnd:n={},transition:r={},...i}=ls(e,t)||{};i={...i,...n};for(let t in i)fs(e,t,ps(i[t]))}function hs(e){return!!(Tn(e)&&e.add)}function gs(e,t){let n=e.getValue(`willChange`);if(hs(n))return n.add(t);if(!n&&Sn.WillChange){let n=new Sn.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function _s(e){return e.props[no]}var vs=typeof window<`u`;function ys({protectedKeys:e,needsAnimating:t},n){let r=n in e&&!t[n];return t[n]=!1,r}function bs(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a,transitionEnd:o,...s}=t,c=e.getDefaultTransition();a=a?P(a,c):c;let l=a?.reduceMotion,u=a?.skipAnimations;r&&(a=r);let d=[],f=i&&e.animationState?.getState()[i],p=a?.path;p&&(p.animateValues?p.animateValues(t=>e.getValue(t,e.latestValues[t]??0),s,a,n,d):p.animateVisualElement?.(e,s,a,n,d));for(let t in s){let r=e.getValue(t,e.latestValues[t]??null),i=s[t];if(i===void 0||f&&ys(f,t))continue;let o={delay:n,...M(f?.out[t]||a||{},t)};u&&(o.skipAnimations=!0);let c=r.get();if(c!==void 0&&!r.isAnimating()&&!Array.isArray(i)&&i===c&&!o.velocity){H.update(()=>r.set(i));continue}let p=!1;if(vs&&window.MotionHandoffAnimation){let n=_s(e);if(n){let e=window.MotionHandoffAnimation(n,t,H);e!==null&&(o.startTime=e,p=!0)}}gs(e,t);let m=l??e.shouldReduceMotion;r.run(ce(t,r,i,m&&F.has(t)?{type:!1}:o,e,p));let h=r.animation;h&&d.push(h)}if(o){let t=()=>H.update(()=>{o&&ms(e,o)});d.length?Promise.all(d).then(t):t()}return d}function xs(e,t,n={}){let r=ls(e,t,us(e,n.type)),i=n.transitionOverride||(r?.transition??(e.getDefaultTransition()||{})),a=()=>Promise.all(r?bs(e,r,n):[]),o=(r=0)=>{let{variantChildren:a}=e,{delayChildren:o=0,staggerChildren:s,staggerDirection:c}=i,l=[];return a?.forEach(e=>{e.notify(`AnimationStart`,t),l.push(xs(e,t,{...n,delay:r+(typeof o==`function`?0:o)+cs(a,e,o,s,c)}).then(()=>e.notify(`AnimationComplete`,t)))}),Promise.all(l)},{when:s}=i;return s?s===`beforeChildren`?a().then(()=>o()):o().then(a):Promise.all([a(),o(n.delay)])}function Ss(e,t,n={}){return e.notify(`AnimationStart`,t),(Array.isArray(t)?Promise.all(t.map(t=>xs(e,t,n))):typeof t==`string`?xs(e,t,n):Promise.all(bs(e,ls(e,t,n.custom),n))).then(()=>{e.notify(`AnimationComplete`,t)})}var Cs=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomRightRadius`,`borderBottomLeftRadius`],ws={value:null,addProjectionMetrics:null,countProjection:void 0};function Ts(e,t){let n=Hn.now();e=Be(e);let r=({timestamp:i})=>{let a=i-n;a>=t&&(yn(r),e(a-t))};return H.setup(r,!0),se(()=>yn(r))}function Es(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function Ds(e){return T(e)&&e.tagName===`svg`}var Os=e=>typeof e==`number`?e:parseFloat(e),ks=Cs.length,As=e=>typeof e==`number`||Dn.test(e);function js(e,t,n,r,i,a){i?(e.opacity=N(0,n.opacity??1,Ns(r)),e.opacityExit=N(t.opacity??1,0,Ps(r))):a&&(e.opacity=N(t.opacity??1,n.opacity??1,r));for(let i=0;i<ks;i++){let a=Cs[i],o=Ms(t,a),s=Ms(n,a);(o!==void 0||s!==void 0)&&(o||=0,s||=0,o===0||s===0||As(o)===As(s)?(e[a]=Math.max(N(Os(o),Os(s),r),0),(on.test(s)||on.test(o))&&(e[a]+=`%`)):e[a]=s)}for(let i=0;i<lt.length;i++){let a=lt[i];(t[a]||n[a])&&(e[a]=N(t[a]||0,n[a]||0,r))}}function Ms(e,t){return e[t]===void 0?e.borderRadius:e[t]}var Ns=Fs(0,.5,he),Ps=Fs(.5,.95,bn);function Fs(e,t,n){return r=>r<e?0:r>t?1:n(_e(e,t,r))}var Is=(e,t,{x:n,y:r})=>{let i=e*e+t*t;return i<1?0:-1e3*(n*e+r*t)/i},Ls=(e,t=300)=>{let n=Wn(.25,2,t/300),{stiffness:r,damping:i}=ut({...e,duration:e.duration&&An(e.duration)});return{...e,stiffness:r,damping:i*Math.sqrt(n),mass:n}};function Rs(e,t){e.min=t.min,e.max=t.max}function zs(e,t){Rs(e.x,t.x),Rs(e.y,t.y)}function Bs(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var Vs=.9999,Hs=1.0001,Us=-.01,Ws=.01;function W(e){return e.max-e.min}function Gs(e,t,n){return Math.abs(e-t)<=n}function Ks(e,t,n,r=.5){e.origin=r,e.originPoint=N(t.min,t.max,e.origin),e.scale=W(n)/W(t),e.translate=N(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Vs&&e.scale<=Hs||isNaN(e.scale))&&(e.scale=1),(e.translate>=Us&&e.translate<=Ws||isNaN(e.translate))&&(e.translate=0)}function qs(e,t,n,r){Ks(e.x,t.x,n.x,r?.originX),Ks(e.y,t.y,n.y,r?.originY)}function Js(e,t,n,r=0){e.min=(r?N(n.min,n.max,r):n.min)+t.min,e.max=e.min+W(t)}function Ys(e,t,n,r){Js(e.x,t.x,n.x,r?.x),Js(e.y,t.y,n.y,r?.y)}function Xs(e,t,n,r=0){let i=r?N(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+W(t)}function Zs(e,t,n,r){Xs(e.x,t.x,n.x,r?.x),Xs(e.y,t.y,n.y,r?.y)}function Qs(e,t,n,r,i){return e-=t,e=Ae(e,1/n,r),i!==void 0&&(e=Ae(e,1/i,r)),e}function $s(e,t=0,n=1,r=.5,i,a=e,o=e){if(on.test(t)&&(t=parseFloat(t),t=N(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=N(a.min,a.max,r);e===a&&(s-=t),e.min=Qs(e.min,t,n,s,i),e.max=Qs(e.max,t,n,s,i)}function ec(e,t,[n,r,i],a,o){$s(e,t[n],t[r],t[i],t.scale,a,o)}var tc=[`x`,`scaleX`,`originX`],nc=[`y`,`scaleY`,`originY`];function rc(e,t,n,r){ec(e.x,t,tc,n?.x,r?.x),ec(e.y,t,nc,n?.y,r?.y)}var ic=e=>typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),ac=ic(`applewebkit/`)&&!ic(`chrome/`)?Math.round:bn;function oc(e){e.min=ac(e.min),e.max=ac(e.max)}function sc(e){oc(e.x),oc(e.y)}function cc(e){return e.translate===0&&e.scale===1}function lc(e){return cc(e.x)&&cc(e.y)}function uc(e,t){return e.min===t.min&&e.max===t.max}function dc(e,t){return uc(e.x,t.x)&&uc(e.y,t.y)}function fc(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function pc(e,t){return fc(e.x,t.x)&&fc(e.y,t.y)}function mc(e){return W(e.x)/W(e.y)}function hc(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var gc=class{constructor(){this.members=[]}add(e){_n(this.members,e);for(let t=this.members.length-1;t>=0;t--){let n=this.members[t];if(n===e||n===this.lead||n===this.prevLead)continue;let r=n.instance;r&&r.isConnected!==!1||n.snapshot||(Un(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(Un(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){for(let t=this.members.indexOf(e)-1;t>=0;t--){let e=this.members[t];if(e.isPresent!==!1&&e.instance?.isConnected!==!1)return this.promote(e),!0}return!1}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.updateSnapshot(),e.scheduleRender();let{layoutDependency:r}=n.options,{layoutDependency:i}=e.options;(r===void 0||r!==i)&&(e.resumeFrom=n,t&&(n.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root?.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{e.options.onExitComplete?.(),e.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}};function _c(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var vc={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`){if(Dn.test(e))e=parseFloat(e);else return e}return`${_c(e,t.target.x)}% ${_c(e,t.target.y)}%`}},yc={borderRadius:Object.assign({},vc,{applyTo:Cs.slice()}),borderTopLeftRadius:vc,borderTopRightRadius:vc,borderBottomLeftRadius:vc,borderBottomRightRadius:vc,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=pn.parse(e);if(i.length>5)return r;let a=pn.createTransformer(e),o=typeof i[0]==`number`?0:1,s=n.x.scale*t.x,c=n.y.scale*t.y;i[0+o]/=s,i[1+o]/=c;let l=N(s,c,.5);return typeof i[2+o]==`number`&&(i[2+o]/=l),typeof i[3+o]==`number`&&(i[3+o]/=l),a(i)}}};function bc(e,t,n){let r=``,i=e.x.translate/t.x,a=e.y.translate/t.y,o=n?.z||0;(i||a||o)&&(r=`translate3d(${i}px, ${a}px, ${o}px) `);let s=``;if(n){let{transformPerspective:e}=n;e&&(r=`perspective(${e}px) ${r}`);for(let e=0;e<lt.length;e++){let t=lt[e],r=n[t];r&&(s+=`${t}(${r}deg) `),!e&&n.pathRotation&&(s+=`rotate(${n.pathRotation}deg) `)}}if(s){(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),r+=s;let n=e.x.scale*t.x,i=e.y.scale*t.y;(n!==1||i!==1)&&(r+=`scale(${n}, ${i})`)}else e.x.scale!==1||e.y.scale!==1?r+=`scale(${e.x.scale}, ${e.y.scale})`:r||t.x===1&&t.y===1||(r=`scale(1, 1)`);return r||`none`}function xc(e){return[e(`x`),e(`y`)]}var Sc=(e,t)=>e.depth-t.depth,Cc=class{constructor(){this.children=[],this.isDirty=!1}add(e){_n(this.children,e),this.isDirty=!0}remove(e){Un(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(Sc),this.isDirty=!1,this.children.forEach(e)}},wc={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Tc=[`z`,`skew`,`skewZ`],Ec=1e3,Dc=0;function Oc(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}var kc=e=>e.instance&&kn.get(e.instance)?.demote()&&e.resetSkewAndRotation();function Ac(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=_s(t);if(window.MotionHasOptimisedAnimation(n,`transform`)){let{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,`transform`,H,!(t||r))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Ac(r)}function jc(e){if(e)return e.options.allowProjection===!1?jc(e.parent):e.projection}function Mc({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return Object.assign(nr,{...yc,...nr}),class{static create(e,t,n){let{layoutId:r,layout:i,drag:a,dragConstraints:o,layoutScroll:s,layoutRoot:c,layoutAnchor:l,layoutCrossfade:u}=t,d=e.projection=new this(e.latestValues,t[`data-framer-portal-id`]?void 0:jc(e.parent));d.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!a||o&&Es(o),visualElement:e,animationType:typeof i==`string`?i:`both`,initialPromotionConfig:n,crossfade:u,layoutScroll:s,layoutRoot:c,layoutAnchor:l});let f=d.getStack()?.lead;f&&!d.root.isUpdateBlocked()&&(f.willUpdate(),f.scheduleCheckAfterUnmount())}constructor(e={},n=t?.()){this.id=Dc++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Fc),this.nodes.forEach(Kc),this.nodes.forEach(qc),this.nodes.forEach(Ic),ws.countProjection?.()},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new Cc)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new On),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){this.eventHandlers.get(e)?.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t){if(this.instance)return;this.isSVG=T(t)&&!Ds(t),this.instance=t;let{layoutId:n,layout:r,visualElement:i}=this.options;if(i&&!i.current&&i.mount(t),this.root.nodes.add(this),this.parent?.children.add(this),this.root.hasTreeAnimated&&(r||n)&&(this.isLayoutDirty=!0),e){let n,r=0,i=()=>this.root.updateBlockedByResize=!1;H.read(()=>{r=window.innerWidth}),e(t,()=>{let e=window.innerWidth;e!==r&&(r=e,this.root.updateBlockedByResize=!0,n?.(),n=Ts(i,250),wc.hasAnimatedSinceResize&&(wc.hasAnimatedSinceResize=!1,this.nodes.forEach(Gc)))})}n&&this.root.registerSharedNode(n,this),this.addLayoutListener()}addLayoutListener(){let{layoutId:e,layout:t,visualElement:n,animate:r}=this.options;this.instance&&!this.hasLayoutListener&&r!==!1&&n&&(e||t)&&(this.hasLayoutListener=!0,this.addEventListener(`didUpdate`,({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:r,layout:i})=>{if(this.isAnimationBlocked){this.target=void 0,this.relativeTarget=void 0;return}let a=this.options.transition||n.getDefaultTransition()||el,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=n.getProps(),c=!this.targetLayout||!pc(this.targetLayout,i),l=!t&&r;if(this.options.layoutRoot||this.resumeFrom||l||t&&(c||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let t={...M(a,`layout`),onPlay:o,onComplete:s};(n.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t),this.setAnimationOrigin(e,l,t.path)}else t||Gc(this),this.isLead()&&this.options.onExitComplete?.();this.targetLayout=i}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this),this.getStack()?.remove(this),this.parent?.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),this.hasLayoutListener=!1,yn(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes?.forEach(Jc),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete?.();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Ac(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;kc(this),this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,kc(t),(typeof t.latestValues.x==`string`||typeof t.latestValues.y==`string`)&&(t.isLayoutDirty=!0),t.updateScroll(`snapshot`),t.options.layoutRoot&&t.willUpdate(!1),t.isAnimationBlocked&&(t.dragSnapshot||=t.measure(),this.dragAncestor=t)}let{layoutId:t,layout:n}=this.options;if(t===void 0&&!n)return;let r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,``):void 0,this.updateSnapshot(),e&&this.notifyListeners(`willUpdate`)}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){let e=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),e&&this.nodes.forEach(zc),this.nodes.forEach(Rc);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Bc);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Hc),this.nodes.forEach(Uc),this.nodes.forEach(Wc),this.nodes.forEach(Nc),this.nodes.forEach(Pc)):this.nodes.forEach(Bc),this.clearAllSnapshots();let e=Hn.now();En.delta=Wn(0,1e3/60,e-En.timestamp),En.timestamp=e,En.isProcessing=!0,dn.update.process(En),dn.preRender.process(En),dn.render.process(En),En.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Rn.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Lc),this.sharedNodes.forEach((e,t)=>e.members.length?e.removeLeadSnapshot():this.sharedNodes.delete(t))}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,H.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){H.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){if(!this.snapshot&&this.instance&&(this.snapshot=this.measure(),this.snapshot&&!W(this.snapshot.measuredBox.x)&&!W(this.snapshot.measuredBox.y)&&(this.snapshot=void 0),this.snapshot)){let{visualElement:e}=this.options,t=this.currentAnimation?.state===`running`,n=t&&this.animationEdges;t&&this.relativeTarget&&(this.snapshot.relativeVelocity=this.relativeVelocity?.slice()||[]);let r=n&&this.motionValue?.getVelocity()||0,i=[0,1,2,3,4,5].map(t=>(t<4?n&&(this.edgeValues?this.edgeVelocity(t):-n[t]*r/1e3):e?.getValue(t<5?`x`:`y`)?.getVelocity())||0);i.some(Boolean)&&(this.snapshot.velocity=i)}}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutCorrected||=U(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners(`measure`,this.layout.layoutBox);let{visualElement:t}=this.options;t?.notify(`LayoutMeasure`,this.layout.layoutBox,e?.layoutBox)}updateScroll(e=`measure`){let{scroll:t,instance:i}=this,{animationId:a}=this.root;if(this.options.layoutScroll&&i&&!(t&&t.animationId===a&&t.phase===e)){let o=r(i);this.scroll={animationId:a,phase:e,isRoot:o,offset:n(i),wasRoot:t?t.isRoot:o}}}resetTransform(){if(!i)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout;e&&kc(this);let t=this.projectionDelta&&!lc(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,``):void 0,a=r!==this.prevTransformTemplateValue;e&&this.instance&&(t||k(this.latestValues)||a)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){let t=this.measurePageBox(),n=this.removeElementScroll(t);return e&&(n=this.removeTransform(n)),sc(n),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:e}=this.options;if(!e)return U();let t=e.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(rl))){let{scroll:e}=this.root;e&&(nt(t.x,e.offset.x),nt(t.y,e.offset.y))}return t}removeElementScroll(e){let t=U();if(zs(t,e),this.scroll?.wasRoot)return t;for(let n=0;n<this.path.length;n++){let r=this.path[n],{scroll:i,options:a}=r;r!==this.root&&i&&a.layoutScroll&&(i.wasRoot&&zs(t,e),nt(t.x,i.offset.x),nt(t.y,i.offset.y))}return t}applyTransform(e,t=!1,n,r,i=0){let a=n||U();zs(a,e);for(let e=i;e<this.path.length;e++){let n=this.path[e];!t&&n.options.layoutScroll&&n.scroll&&n!==n.root&&(nt(a.x,-n.scroll.offset.x),nt(a.y,-n.scroll.offset.y)),k(n.latestValues)&&Ce(a,n.latestValues,n.layout?.layoutBox)}return!r&&k(this.latestValues)&&Ce(a,this.latestValues,this.layout?.layoutBox),a}removeTransform(e){let t=U();zs(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!k(n.latestValues))continue;let r;n.instance&&(fe(n.latestValues)&&n.updateSnapshot(),r=U(),zs(r,n.measurePageBox())),rc(t,n.latestValues,n.snapshot?.layoutBox,r)}return k(this.latestValues)&&rc(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:e.crossfade===void 0||e.crossfade},this.addLayoutListener()}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==En.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){let t=this.getLead();this.isProjectionDirty||=t.isProjectionDirty,this.isTransformDirty||=t.isTransformDirty,this.isSharedProjectionDirty||=t.isSharedProjectionDirty;let n=!!this.resumingFrom||this!==t;if(!(e||n&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:r,layoutId:i}=this.options;if(!this.layout||!(r||i))return;this.resolvedRelativeTargetAt=En.timestamp;let a=this.getClosestProjectingParent();!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&a&&a.layout?this.createRelativeTarget(a,this.layout.layoutBox,a.layout.layoutBox):this.removeRelativeTarget()),(this.relativeTarget||this.targetDelta)&&(this.target||(this.target=U(),this.targetWithTransforms=U()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Ys(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target,!0):zs(this.target,this.layout.layoutBox),Ue(this.target,this.targetDelta)):zs(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&a&&(!a.resumingFrom==!this.resumingFrom||a.options.layoutRoot&&!a.resumingFrom)&&!a.options.layoutScroll&&a.target&&this.animationProgress!==1?this.createRelativeTarget(a,this.target,a.target):this.relativeParent=this.relativeTarget=void 0),ws.countProjection?.(1))}getClosestProjectingParent(){if(!(!this.parent||fe(this.parent.latestValues)||Te(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(e,t,n){this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=U(),this.relativeTargetOrigin=U(),Zs(this.relativeTargetOrigin,t,n,this.options.layoutAnchor||void 0),zs(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let e=this.getLead(),t=!!this.resumingFrom||this!==e,n=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(n=!1),t&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(n=!1),this.resolvedRelativeTargetAt===En.timestamp&&(n=!1),n)return;let{layout:r,layoutId:i}=this.options;if(this.isTreeAnimating=!!(this.parent?.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(r||i))return;zs(this.layoutCorrected,this.layout.layoutBox);let a=this.treeScale.x,o=this.treeScale.y;Me(this.layoutCorrected,this.treeScale,this.path,t&&(e.relativeTarget&&!e.relativeParent.resumingFrom?e.relativeParent:!0)),e.layout&&!e.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(e.target=e.layout.layoutBox,e.targetWithTransforms=U());let{target:s}=e;s?(!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Bs(this.prevProjectionDelta.x,this.projectionDelta.x),Bs(this.prevProjectionDelta.y,this.projectionDelta.y)),qs(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.treeScale.x===a&&this.treeScale.y===o&&hc(this.projectionDelta.x,this.prevProjectionDelta.x)&&hc(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners(`projectionUpdate`,s)),ws.countProjection?.(2)):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){this.options.visualElement?.scheduleRender(),e&&this.getStack()?.scheduleRender(),this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=oo(),this.projectionDelta=oo(),this.projectionDeltaWithTransform=oo()}setAnimationOrigin(e,t=!1,n){let r=this.snapshot,i=r?r.latestValues:{},a={...this.latestValues},o=oo();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let s=U(),c=r?.source!==this.layout?.source,l=this.getStack(),u=!l||l.members.length<=1,d=!(!c||u||this.options.crossfade!==!0||this.path.some($c));this.animationProgress=0;let f,p=n?.interpolateProjection(e),m=this.layout?.layoutBox,h=m&&[m.x.min,m.x.max,m.y.min,m.y.max].map((t,n)=>{let{translate:r,scale:i,originPoint:a}=e[n<2?`x`:`y`];return(t-a)*(i-1)+r});h?.every(isFinite)||(h=void 0),this.animationEdges=h,this.edgeValues=this.startVelocity=this.impulse=this.relativeVelocity=this.relativeStart=void 0;let g=r?.velocity,_=r?.relativeVelocity||g;if(_?.slice(0,4).some(Boolean)&&this.getClosestProjectingParent()&&(this.relativeStart=_),g&&h){let t=g.slice(0,4).map((e,t)=>e+(c?g[4+(t>>1)]:0));t.some(Boolean)&&(this.startVelocity=p?Is(e.x.translate,e.y.translate,{x:(t[0]+t[1])/2,y:(t[2]+t[3])/2}):t)}this.mixTargetDelta=t=>{let n=t/1e3,r=p?.(n),l=this.edgeValues;for(let t=0;t<2;t++){let r=t?`y`:`x`;l?Yc(o[r],e[r],this.layout.layoutBox[r],l[t*2],l[t*2+1]):Xc(o[r],e[r],n)}if(r&&(o.x.translate=r.x,o.y.translate=r.y),this.setTargetDelta(o),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){Zs(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0);let e=this.relativeTargetOrigin,t=s;if(Qc(this.relativeTarget,e,t,n),this.isSpringLayout){let e=this.relativeTarget,t=this.impulse||0,n=this.relativeStart,r=Hn.now(),i=(r-this.relativeTime)/1e3;this.relativeTime=r;let a=this.relativeVelocity||=[0,0,0,0];for(let r=0;r<4;r++){let o=r<2?`x`:`y`,s=r&1?`max`:`min`;n&&(e[o][s]+=n[r]*t),f&&i>0&&(a[r]=(e[o][s]-f[o][s])/i)}}f&&dc(this.relativeTarget,f)&&(this.isProjectionDirty=!1),f||=U(),zs(f,this.relativeTarget)}c&&(this.animationValues=a,js(a,i,this.latestValues,n,d,u)),r?.rotate!==void 0&&(this.animationValues||=a,this.animationValues.pathRotation=r.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners(`animationStart`);let t=this.isSpringLayout=e.type===`spring`;this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.resumingFrom&&(this.resumingFrom.edgeValues=void 0),this.pendingAnimation&&=(yn(this.pendingAnimation),void 0),this.pendingAnimation=H.update(()=>{wc.hasAnimatedSinceResize=!0,this.motionValue||=Nn(0),this.motionValue.jump(0,!1);let n=this.startVelocity;this.startVelocity=void 0;let r=e,i=0;if(t){if(e.mass===`auto`){let t=this.layout?.layoutBox;r=Ls(e,t&&Math.sqrt(W(t.x)*W(t.y)))}let t=this.relativeStart;if((n||t)&&!e.repeat){if(typeof n==`number`)i=n;else{let e=n&&this.animationEdges;r={...r,type:r=>{let i=[r.velocity,...n||[]].map((t,n)=>E({...r,keyframes:n?[e[n-1],0]:r.keyframes,velocity:t})),a=i.length;t&&i.push(E({...r,keyframes:[0,0],velocity:1e3,restDelta:.5,restSpeed:5}));let o=0,s=[],c={calculatedDuration:null,next:t=>{o=t;let n=i[0].next(t),r=n.done;for(let e=1;e<i.length;e++){let{value:n,done:o}=i[e].next(t);e<a?s[e-1]=n:this.impulse=n/1e3,r&&=o}return e&&(this.edgeValues=s),n.done=r,n}};return c.calculatedDuration=ge(c),c.next(0),this.edgeVelocity=e=>i[e+1].velocity(o),c}}}}}let a=$e(this.motionValue,[0,1e3],{...r,velocity:i,isSync:!0,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}});this.currentAnimation=a,sn(this.currentAnimation,this),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=this.edgeValues=this.edgeVelocity=this.impulse=void 0,this.notifyListeners(`animationComplete`)}finishAnimation(){this.currentAnimation&&(this.edgeValues=this.impulse=void 0,this.mixTargetDelta?.(Ec),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,layout:n,latestValues:r}=e,{target:i}=e;if(t&&i&&n){if(this!==e&&this.layout&&n&&nl(this.options.animationType,this.layout.layoutBox,n.layoutBox)){let{layoutBox:e}=this.layout,t=i;i=this.target||U(),tl(i.x,t.x,e.x),tl(i.y,t.y,e.y)}zs(t,i),Ce(t,r),qs(this.projectionDeltaWithTransform,this.layoutCorrected,t,r)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new gc),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?.transition,preserveFollowOpacity:n?.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){let{layoutId:e}=this.options;return e&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:e}=this.options;return e?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){this.getStack()?.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){return this.getStack()?.relegate(this)||!1}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let{latestValues:t}=e;if(!st(t))return;let n={};for(let t=0;t<Tc.length;t++)Oc(Tc[t],e,n,this.animationValues);for(let t=0;t<lt.length;t++)Oc(lt[t],e,n,this.animationValues);e.render();for(let t in n)e.setStaticValue(t,n[t]),this.animationValues&&(this.animationValues[t]=n[t]);e.scheduleRender()}applyProjectionStyles(e,t){if(!this.instance||this.isSVG)return;let n=this.getLead();if(!this.isVisible&&n!==this){e.visibility=`hidden`;return}let r=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,e.visibility=``,e.opacity=``,e.pointerEvents=Zr(t?.pointerEvents)||``,e.transform=r?r(this.latestValues,``):`none`;return}if(!this.projectionDelta||!this.layout||!n.target){(this.options.layoutId||this.needsShow)&&(this.needsShow=!1,e.visibility=``,e.opacity=this.latestValues.opacity===void 0?1:this.latestValues.opacity,e.pointerEvents=Zr(t?.pointerEvents)||``),this.hasProjected&&!k(this.latestValues)&&(e.transform=r?r({},``):`none`,this.hasProjected=!1);return}e.visibility=``;let i=n.animationValues||n.latestValues;this.applyTransformsToTarget();let a=bc(this.projectionDeltaWithTransform,this.treeScale,i);r&&(a=r(i,a)),e.transform=a;let{x:o,y:s}=this.projectionDelta;e.transformOrigin=`${o.origin*100}% ${s.origin*100}% 0`,e.opacity=n.animationValues?n===this?i.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:i.opacityExit:n===this?i.opacity===void 0?``:i.opacity:i.opacityExit===void 0?0:i.opacityExit;for(let t in nr){if(i[t]===void 0)continue;let{correct:r,applyTo:o,isCSSVariable:s}=nr[t],c=a===`none`?i[t]:r(i[t],n);if(o){let t=o.length;for(let n=0;n<t;n++)e[o[n]]=c}else s?this.options.visualElement.renderState.vars[t]=c:e[t]=c}this.options.layoutId&&(e.pointerEvents=n===this?Zr(t?.pointerEvents)||``:`none`)}clearSnapshot(){this.resumeFrom=this.snapshot=this.dragSnapshot=this.dragAncestor=void 0}resetTree(){this.root.nodes.forEach(e=>e.currentAnimation?.stop()),this.root.nodes.forEach(Rc),this.root.sharedNodes.clear()}}}function Nc(e){e.updateLayout(),Vc(e)}function Pc(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners(`didUpdate`)){let{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,a=t.source!==e.layout.source,o=(r,a)=>{if(i===`size`)xc(e=>{let t=W(r[e]);r[e].min=a[e].min,r[e].max=r[e].min+t});else if(i===`x`||i===`y`){let e=i===`x`?`y`:`x`;Rs(r[e],a[e])}else nl(i,t.layoutBox,n)&&xc(t=>{let n=W(a[t]);r[t].max=r[t].min+n,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[t].max=e.relativeTarget[t].min+n)})},s=a?t.measuredBox:t.layoutBox;o(s,n);let c=oo();qs(c,n,t.layoutBox);let l=oo();qs(l,a?e.applyTransform(r,!0):n,s);let u=!lc(c),d=!1,f=e.getClosestProjectingParent();if((!a||f?.options.layoutRoot&&e.resumeFrom?.path.includes(f))&&f&&!f.resumeFrom){let{snapshot:r,layout:i}=f;if(r&&i){let s=e.options.layoutAnchor||void 0,c=U();Zs(c,a?e.resumeFrom.applyTransform(t.layoutBox,!0,void 0,!0,f.depth+1):t.layoutBox,r.layoutBox,s);let l=U();Zs(l,n,i.layoutBox,s),a&&o(c,l),pc(c,l)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=l,e.relativeTargetOrigin=c,e.relativeParent=f)}}e.notifyListeners(`didUpdate`,{layout:n,snapshot:t,delta:l,layoutDelta:c,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else e.isLead()&&e.options.onExitComplete?.();e.options.transition=void 0}function Fc(e){ws.countProjection?.(0),e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty),e.isTransformDirty||=e.parent.isTransformDirty)}function Ic(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Lc(e){e.clearSnapshot()}function Rc(e){e.clearMeasurements()}function zc(e){e.isLayoutDirty=!0,e.updateLayout()}function Bc(e){e.isLayoutDirty=!1}function Vc(e){let{snapshot:t,dragAncestor:n}=e,r=n?.isAnimationBlocked&&n.layout;if(!t||!r||e.resumeFrom||e.isAnimationBlocked)return;let i=n.dragSnapshot;xc(e=>nt(t.layoutBox[e],r.layoutBox[e].min-i.layoutBox[e].min))}function Hc(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.dragSnapshot||e.layout,e.isLayoutDirty=!0)}function Uc(e){e.relativeTarget&&e.relativeParent?.isLayoutDirty&&(e.currentAnimation?e.isLayoutDirty=!0:(e.targetDelta=void 0,e.removeRelativeTarget()))}function Wc(e){let{visualElement:t}=e.options;t?.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function Gc(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Kc(e){e.resolveTargetDelta()}function qc(e){e.calcProjection()}function Jc(e){e.resetSkewAndRotation()}function Yc(e,t,n,r,i){let a=n.max-n.min,o=a?Math.max(0,(a+i-r)/a):1,s=e.originPoint=t.originPoint;e.origin=t.origin,e.scale=o,e.translate=n.min+r-(s+(n.min-s)*o)}function Xc(e,t,n){e.translate=N(t.translate,0,n),e.scale=N(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Zc(e,t,n,r){e.min=N(t.min,n.min,r),e.max=N(t.max,n.max,r)}function Qc(e,t,n,r){Zc(e.x,t.x,n.x,r),Zc(e.y,t.y,n.y,r)}function $c(e){return e.animationValues?.opacityExit!==void 0}var el={duration:.45,ease:[.4,0,.1,1]};function tl(e,t,n){e.max=W(n)+(e.min=t.min)}function nl(e,t,n){return e===`position`||e===`preserve-aspect`&&!Gs(mc(t),mc(n),.2)}function rl(e){return e!==e.root&&e.scroll?.wasRoot}function il(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}var al=Mc({attachResizeListener:(e,t)=>il(e,`resize`,t),measureScroll:Ee,checkIsScrollRoot:()=>!0}),ol=Mc({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!uo.current){let e=new al({});e.mount(window),e.setOptions({layoutScroll:!0}),uo.current=e}return uo.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>window.getComputedStyle(e).position===`fixed`}),sl=class extends Gi{constructor(){super(...arguments),this.KeyframeResolver=Re}sortInstanceNodePosition(e,t){return e.compareDocumentPosition(t)&2?1:-1}getBaseTargetFromProps(e,t){let n=e.style;return n?n[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;Tn(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}};function cl(e,{style:t,vars:n},r,i){let a=e.style,o;for(o in t)a[o]=t[o];for(o in i?.applyProjectionStyles(a,r),n)a.setProperty(o,n[o])}function ll(e){return window.getComputedStyle(e)}var ul=class extends sl{constructor(){super(...arguments),this.type=`html`,this.renderInstance=cl}mount(e){super.mount(e)}readValueFromInstance(e,t){if(mn.has(t))return this.projection?.isProjecting?hn(t):gn(e,t);{let n=ll(e),r=(zn(t)?n.getPropertyValue(t):n[t])||0;return typeof r==`string`?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return Ke(e,t)}build(e,t,n){Vn(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return Ri(e,t,n)}},dl=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1;function fl(e){return{point:{x:e.pageX,y:e.pageY}}}var pl=e=>t=>dl(t)&&e(t,fl(t));function ml(e,t,n,r){return il(e,t,pl(n),r)}var hl=new WeakMap,gl,_l=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:T(r)&&`getBBox`in r?r.getBBox()[t]:r[n],vl=_l(`inline`,`width`,`offsetWidth`),yl=_l(`block`,`height`,`offsetHeight`);function bl({target:e,borderBoxSize:t}){hl.get(e)?.forEach(n=>{n(e,{get width(){return vl(e,t)},get height(){return yl(e,t)}})})}function xl(e){e.forEach(bl)}function Sl(){typeof ResizeObserver<`u`&&(gl=new ResizeObserver(xl))}function Cl(e,t){gl||Sl();let n=A(e);return n.forEach(e=>{let n=hl.get(e);n||(n=new Set,hl.set(e,n)),n.add(t),gl?.observe(e)}),()=>{n.forEach(e=>{let n=hl.get(e);n?.delete(t),n?.size||gl?.unobserve(e)})}}var wl=new Set,Tl;function El(){Tl=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};wl.forEach(t=>t(e))},window.addEventListener(`resize`,Tl)}function Dl(e){return wl.add(e),Tl||El(),()=>{wl.delete(e),!wl.size&&typeof Tl==`function`&&(window.removeEventListener(`resize`,Tl),Tl=void 0)}}function Ol(e,t){return se(typeof e==`function`?Dl(e):Cl(e,t))}var kl=(e,t)=>Math.abs(e-t);function Al(e,t){let n=kl(e.x,t.x),r=kl(e.y,t.y);return Math.sqrt(n**2+r**2)}var jl=new Set([`auto`,`scroll`]),Ml=class{constructor(e,t,{transformPagePoint:n,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:a=3,element:o,immediate:s}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.onElementScroll=e=>{this.handleScroll(e.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.hasPendingMove=!1,this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Pl(this.lastRawMoveEventInfo,this.transformPagePoint));let e=Il(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=Al(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e;this.history.push({...r,timestamp:Hn.now()});let{onStart:i,onMove:a}=this.handlers;t||(i?.(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),a?.(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.handleScroll(window),this.lastMoveEvent=e,this.lastRawMoveEventInfo=t,this.lastMoveEventInfo=Pl(t,this.transformPagePoint),this.hasPendingMove=!0,H.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.hasPendingMove&&this.updatePoint(),this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&i?.(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let a=Il(e.type===`pointercancel`?this.lastMoveEventInfo:Pl(t,this.transformPagePoint),this.history);this.startEvent&&n?.(e,a),r?.(e,a)},!dl(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=s?0:a,this.contextWindow=r||window;let c=fl(e),l=Pl(c,this.transformPagePoint),{point:u}=l;this.history=[{...u,timestamp:Hn.now()}];let{onSessionStart:d}=t;d&&d(e,Il(l,this.history));let f={passive:!0,capture:!0};this.removeListeners=te(ml(this.contextWindow,`pointermove`,this.handlePointerMove,f),ml(this.contextWindow,`pointerup`,this.handlePointerUp,f),ml(this.contextWindow,`pointercancel`,this.handlePointerUp,f)),o&&this.startScrollTracking(o),s&&(this.handlePointerMove(e,c),this.updatePoint())}startScrollTracking(e){let t=e.parentElement;for(;t;){let e=getComputedStyle(t);(jl.has(e.overflowX)||jl.has(e.overflowY))&&this.scrollPositions.set(t,Nl(t)),t=t.parentElement}this.scrollPositions.set(window,Nl(window)),this.removeScrollListeners=te(il(window,`scroll`,this.onElementScroll,{capture:!0}),il(window,`scroll`,this.onWindowScroll,{}))}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===window,r=Nl(e),i={x:r.x-t.x,y:r.y-t.y};(i.x!==0||i.y!==0)&&(n?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(e,r),H.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners?.(),this.removeScrollListeners?.(),this.scrollPositions.clear(),yn(this.updatePoint)}},Nl=e=>e===window?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop};function Pl(e,t){return t?{point:t(e.point)}:e}function Fl(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Il({point:e},t){return{point:e,delta:Fl(e,Rl(t)),offset:Fl(e,Ll(t)),velocity:zl(t,.1)}}function Ll(e){return e[0]}function Rl(e){return e[e.length-1]}function zl(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=Rl(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>An(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>An(t)*2&&(r=e[1]);let a=Pn(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};let o={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}var Bl=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]);function Vl(e){return Bl.has(e.tagName)||e.isContentEditable===!0}var Hl=new Set([`INPUT`,`SELECT`,`TEXTAREA`]);function Ul(e){return Hl.has(e.tagName)||e.isContentEditable===!0}var Wl={x:!1,y:!1};function Gl(){return Wl.x||Wl.y}function Kl(e){return e===`x`||e===`y`?Wl[e]?null:(Wl[e]=!0,()=>{Wl[e]=!1}):Wl.x||Wl.y?null:(Wl.x=Wl.y=!0,()=>{Wl.x=Wl.y=!1})}function ql(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?N(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?N(n,e,r.max):Math.min(e,n)),e}function Jl(e,t,n){return{min:t===void 0?void 0:e.min+t,max:n===void 0?void 0:e.max+n-(e.max-e.min)}}function Yl(e,{top:t,left:n,bottom:r,right:i}){return{x:Jl(e.x,n,i),y:Jl(e.y,t,r)}}function Xl(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function Zl(e,t){return{x:Xl(e.x,t.x),y:Xl(e.y,t.y)}}function Ql(e,t){let n=.5,r=W(e),i=W(t);return i>r?n=_e(t.min,t.max-r,e.min):r>i&&(n=_e(e.min,e.max-i,t.min)),Wn(0,1,n)}function $l(e,t){let n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}var eu=.35;function tu(e=eu){return e===!1?e=0:e===!0&&(e=eu),{x:nu(e,`left`,`right`),y:nu(e,`top`,`bottom`)}}function nu(e,t,n){return{min:ru(e,t),max:ru(e,n)}}function ru(e,t){return typeof e==`number`?e:e[t]||0}function iu(e){let t=``;for(let n of e.path){n.scroll=void 0,n.updateScroll();let{scroll:r}=n;n!==e.root&&r&&(t+=r.offset.x+`,`+r.offset.y+`,`)}return t}var au=new WeakMap,ou=class{constructor(e,t=()=>e.getProps()){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=U(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e,this.readProps=t}start(e,t={}){if(this.visualElement.presenceContext?.isPresent===!1)return;let n=e=>{t.snapToCursor&&this.snapToCursor(e),this.stopAnimation()},r=(e,t)=>{let{drag:n,dragConstraints:r,dragPropagation:i,onDragStart:a}=this.getProps();if(n&&!i&&(this.openDragLock?.(),this.openDragLock=Kl(n),!this.openDragLock))return;this.latestPointerEvent=e,this.latestPanInfo=t,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints();let{projection:o}=this.visualElement;o&&(o.isAnimationBlocked=!0,o.target=void 0),xc(e=>{let t=this.getAxisMotionValue(e).get()||0;if(wn(t)&&(t=I(t,this.visualElement.current)||0),Dn.test(t))t=parseFloat(t);else if(on.test(t)){let n=o?.layout?.layoutBox[e];n&&(t=W(n)*(parseFloat(t)/100))}this.originPoint[e]=t}),this.point=typeof r==`function`&&r(this),a&&H.update(()=>a(e,t),!1,!0),gs(this.visualElement,`transform`),this.visualElement.animationState?.setActive(`whileDrag`,!0)},i=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t;let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:a}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:o}=t;if(r&&this.currentDirection===null){if(this.currentDirection=fu(o),this.currentDirection===null)return;i&&i(this.currentDirection)}this.updateAxis(`x`,o),this.updateAxis(`y`,o),this.point&&this.point.move(),this.visualElement.render(),a&&H.update(()=>a(e,t),!1,!0)},a=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t,this.stop(e,t),this.latestPointerEvent=null,this.latestPanInfo=null},o=()=>{let{dragSnapToOrigin:e}=this.getProps();(e||this.constraints||this.point)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:s}=this.getProps();this.panSession=new Ml(e,{onSessionStart:n,onStart:r,onMove:i,onSessionEnd:a,resumeAnimation:o},{...t,transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:s,contextWindow:this.visualElement.current?.ownerDocument.defaultView,element:this.visualElement.current})}stop(e,t,n){let r=e||this.latestPointerEvent,i=t||this.latestPanInfo,a=this.isDragging;if(this.cancel(),!a||!i||!r)return;let{velocity:o}=i;this.startAnimation(o,n);let{onDragEnd:s}=this.getProps();s&&H.postRender(()=>s(r,i))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession(),!this.getProps().dragPropagation&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t?.setActive(`whileDrag`,!1)}endPanSession(){this.panSession?.end(),this.panSession=void 0}updateAxis(e,t){let{drag:n}=this.readProps();if(!t||!du(e,n,this.currentDirection))return;let r=this.getAxisMotionValue(e),i=this.originPoint[e]+t[e],a=this.constraints&&this.constraints[e];a&&(i=ql(i,a,this.elastic[e])),this.point?this.point[e]=i:r.set(i)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),{projection:n}=this.visualElement,r=n&&(n.layout||n.measure(!1)),i=this.constraints;su(e)?this.constraints&&this.scroll===iu(n)||(this.constraints=this.resolveRefConstraints()):this.constraints=e&&r&&typeof e==`object`?Yl(r.layoutBox,e):!1,this.elastic=tu(t),i!==this.constraints&&!su(e)&&r&&this.constraints&&!this.hasMutatedConstraints&&xc(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=$l(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!su(e))return!1;let n=cu(e),{projection:r}=this.visualElement;if(!r||!r.layout)return!1;this.scroll=iu(r);let i=De(n,r.root,this.visualElement.getTransformPagePoint()),a=Zl(r.layout.layoutBox,r.removeElementScroll(i));if(t){let e=t(me(a));this.hasMutatedConstraints=!!e,e&&(a=ot(e))}return a}startAnimation(e,t){let{drag:n,dragMomentum:r,dragElastic:i,dragTransition:a,dragSnapToOrigin:o,onDragTransitionEnd:s}=this.getProps(),c={bounceStiffness:i?200:1e6,bounceDamping:i?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...a},l=i=>r&&!(this.point&&o)&&du(i,t||n,this.currentDirection)?e[i]:0;if(this.point&&!o)return this.point.release({x:l(`x`),y:l(`y`)},c).then(s);let u=this.constraints||{},d=xc(e=>{if(!du(e,t||n,this.currentDirection))return;let r=u[e]||{};(o===!0||o===e)&&(r={min:0,max:0});let i={type:`inertia`,velocity:l(e),...c,...r};return this.startAxisValueAnimation(e,i)});return Promise.all(d).then(s)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return gs(this.visualElement,e),n.start(ce(e,n,0,t,this.visualElement,!1))}stopAnimation(){xc(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`;return this.readProps()[t]||this.visualElement.getValue(e,this.visualElement.latestValues[e]??0)}snapToCursor({clientX:e,clientY:t}){let{drag:n}=this.getProps(),r={x:e,y:t},i=this.visualElement.getTransformPagePoint()?.(r)||r,a=this.visualElement.measureViewportBox();xc(e=>{if(!du(e,n,this.currentDirection))return;let t=this.getAxisMotionValue(e),{min:r,max:o}=a[e];t.set((t.get()||0)+i[e]-N(r,o,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!su(t)||!n||!this.constraints)return;this.stopAnimation();let r=this.constraints,i={x:0,y:0};xc(e=>{let t=this.getAxisMotionValue(e).get();i[e]=Ql({min:t,max:t},r[e])});let{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},``):`none`,n.root?.updateScroll(),n.updateLayout(),this.constraints=!1,this.resolveConstraints(),xc(t=>{let n=this.getAxisMotionValue(t);if(!du(t,e,null)||!n.get())return;let{min:r,max:a}=this.constraints[t];n.set(N(r,a,i[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;au.set(this.visualElement,this);let e=this.visualElement.current,t=ml(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&Ul(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps(),r=su(t)&&cu(t);r&&(this.constraints=this.resolveRefConstraints(),n||=uu(e,r,()=>this.scalePositionWithinConstraints()))},{projection:i}=this.visualElement,a=i.addEventListener(`measure`,r);i.layout||(i.root?.updateScroll(),i.updateLayout()),H.read(r);let o=il(window,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(xc(t=>{if(!du(t,this.getProps().drag,this.currentDirection))return;let n=this.getAxisMotionValue(t);this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate)}),this.visualElement.render())}));return()=>{o(),t(),a(),s(),n?.()}}getProps(){let e=this.readProps(),{dragElastic:t=eu,dragMomentum:n=!0}=e;return{...e,dragElastic:t,dragMomentum:n}}};function su(e){return!!e&&typeof e==`object`&&(`current`in e||`nodeType`in e)}var cu=e=>`current`in e?e.current:e;function lu(e){let t=!0;return()=>{t?t=!1:e()}}function uu(e,t,n){let r=Ol(e,lu(n)),i=Ol(t,lu(n));return()=>{r(),i()}}function du(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function fu(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}function pu(e,t){let n=A(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},se(()=>r.abort())]}function mu(e){return!(e.pointerType===`touch`||Gl())}function hu(e,t,n={}){t=Be(t);let[r,i,a]=pu(e,n);return r.forEach(e=>{let n=!1,r=!1,a,o=()=>{e.removeEventListener(`pointerleave`,u)},s=e=>{a&&=(a(e),void 0),o()},c=e=>{n=!1,window.removeEventListener(`pointerup`,c),window.removeEventListener(`pointercancel`,c),r&&(r=!1,s(e))},l=()=>{n=!0,window.addEventListener(`pointerup`,c,i),window.addEventListener(`pointercancel`,c,i)},u=e=>{e.pointerType!==`touch`&&(n?r=!0:s(e))};e.addEventListener(`pointerenter`,n=>{if(!mu(n))return;r=!1;let o=t(e,n);typeof o==`function`&&(a=o,e.addEventListener(`pointerleave`,u,i))},i),e.addEventListener(`pointerdown`,l,i)}),a}var gu=(e,t)=>t?e===t||gu(e,t.parentElement):!1,_u=new WeakSet;function vu(e){return t=>{t.key===`Enter`&&e(t)}}function yu(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}var bu=(e,t)=>{let n=!1,r=vu(()=>{n||_u.has(e)||(n=!0,yu(e,`down`))}),i=vu(()=>{n&&(n=!1,yu(e,`up`))});e.addEventListener(`keydown`,r,t),e.addEventListener(`keyup`,i,t),e.addEventListener(`blur`,()=>{e.removeEventListener(`keydown`,r),e.removeEventListener(`keyup`,i),n&&yu(e,`cancel`)},{...t,once:!0})};function xu(e){return dl(e)&&!Gl()}var Su=new WeakSet,Cu=100,wu=8,Tu=(e,t,n)=>Math.hypot(e.clientX-t.clientX,e.clientY-t.clientY)>n,Eu=e=>e.preventDefault();function Du(e,t,n={}){t=Be(t);let[r,i,a]=pu(e,n),o=new WeakMap,s=e=>{let r=e.currentTarget;if(!xu(e)||Su.has(e))return;n.stopPropagation&&Su.add(e);let{count:a=1,countTimeout:s=.3,hold:c=0,repeat:l}=n,u=Hn.now(),d=An(c),f=An(s),p=o.get(r);p?.expire(Tu(p.event,e,Cu))?p=void 0:p&&(yn(p.expire),o.delete(r));let m=p?p.count+1:1,h=m>=a,g=h&&(c||l),_=!c,v=0,y;if(_u.add(r),p)y=p.handlers;else{let n=t(r,e);y=typeof n==`function`?{onComplete:n}:n||{}}h&&_&&y.onActive?.();let b=An(l),x=d||b,S=u+x,C=!0,w=()=>{if(i.signal.aborted)return yn(w);let e=Math.min(1-(S-Hn.now())/x,1);C&&e<1&&(e=0),C=!1,y.onHold?.(e),e<1||(_?y.onRepeat?.(++v):(_=!0,y.onActive?.()),l?(C=!0,S+=x=b):yn(w))},T={...i,capture:!0},E=(t,n)=>{if(dl(t)){if(window.removeEventListener(`pointerup`,D,T),window.removeEventListener(`pointercancel`,O,T),window.removeEventListener(`pointermove`,k,T),r.removeEventListener(`contextmenu`,Eu),yn(w),_u.delete(r),Gl()&&(n=!1),n&&!h){let n=Hn.now(),a=e=>{let s=i.signal.aborted;if(s||e===!0||Hn.now()-n>f)return yn(a),o.delete(r),s||y.onComplete?.(t,{success:!1}),!0};o.set(r,{count:m,event:e,handlers:y,expire:a}),H.update(a,!0)}else y.onComplete?.(t,{success:n&&_})}},D=e=>{E(e,r===window||r===document||n.useGlobalTarget||gu(r,e.target))},O=e=>{E(e,!1)},k=t=>{dl(t)&&((l||!_)&&Tu(e,t,wu)||a>1&&Gl())&&O(t)};window.addEventListener(`pointerup`,D,T),window.addEventListener(`pointercancel`,O,T),(g||a>1)&&window.addEventListener(`pointermove`,k,T),g&&(H.update(w,!0),r.addEventListener(`contextmenu`,Eu,{...i,passive:!1}))};return r.forEach(e=>{(n.useGlobalTarget?window:e).addEventListener(`pointerdown`,s,i),go(e)&&(e.addEventListener(`focus`,()=>bu(e,i),i),!Vl(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function Ou(...e){let t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],a=e[2+n],o=e[3+n],s=ue(i,a,o);return t?s(r):s}var ku=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},Au=new Set([`baseFrequency`,`diffuseConstant`,`kernelMatrix`,`kernelUnitLength`,`keySplines`,`keyTimes`,`limitingConeAngle`,`markerHeight`,`markerWidth`,`numOctaves`,`targetX`,`targetY`,`surfaceScale`,`specularConstant`,`specularExponent`,`stdDeviation`,`tableValues`,`viewBox`,`gradientTransform`,`pathLength`,`startOffset`,`textLength`,`lengthAdjust`]);function ju(e,t,n,r){cl(e,t,void 0,r);for(let n in t.attrs)e.setAttribute(Au.has(n)?n:ee(n),t.attrs[n])}var Mu=class extends sl{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=U}getBaseTargetFromProps(e,t){return mn.has(t)?super.getBaseTargetFromProps(e,t)??hn(t):e[t]}getDefaultValue(e){return mn.has(e)?this.latestValues[e]??hn(e):void 0}readValueFromInstance(e,t){if(mn.has(t)){let e=fn(t);return e&&e.default||0}if(Mn.includes(t)){let n=getComputedStyle(e)[t];if(typeof n==`string`&&n)return n.trim()}return t=Au.has(t)?t:ee(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return pa(e,t,n)}build(e,t,n){Cn(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){ju(e,t,n,r)}mount(e){this.isSVGTag=Ja(e.tagName),super.mount(e)}};function Nu(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}var Pu=[...Yi].reverse(),Fu=e=>e?.out===!0?e:e?.out;function Iu(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>Ss(e,t,n))),n=Ru(),r=!0,i=!1;function a(a){let{props:o,parent:s,manuallyAnimateOnMount:c}=e,{initial:l}=o,u=r||i,d=[],f=(t=l)=>typeof t!=`boolean`&&ls(e,Array.isArray(t)?t[0]:t,e.presenceContext?.custom)||void 0,p=new Map,m={},h=1/0,g=e;do g=g.props.inherit!==!1&&g.parent;while(g&&!g.isControllingVariants);let _=u&&Fu(f(l??(g&&g.props.initial))?.transition);if(Pu.forEach((t,r)=>{let i=n[t],l=o[t],f=g&&g.props[t],v=l===void 0?Ci(f)||f===!1?f:void 0:l,y=Ci(v),b=t===a?i.isActive:null,x=y&&l===void 0&&!(u&&c);if(i.protectedKeys={...m},!i.isActive&&b===null||!v&&!i.prevProp||Qa(v)||typeof v==`boolean`)return;if(b===!1&&(h=r),t===`exit`&&i.isActive&&b!==!0){m={...m,...i.prevResolvedValues};return}let S=Lu(i.prevProp,v),C=S||y&&(b&&!x||r>h),w=!1,T=Array.isArray(v)?v:[v],E={},D;if(b!==!1)for(let n of T){let{transition:r,transitionEnd:i,...a}=ls(e,n,us(e,t))||{};E={...E,...a,...i},D=Fu(r)||D}let{prevResolvedValues:O}=i;for(let t in{...O,...E}){if(t in m)continue;let n=E[t],r=O[t],a=Array.isArray(n)&&Array.isArray(r)?!Nu(n,r)||S:n!==r,o;if(a&&n==null)p.has(t)||p.set(t,i.prevOut);else if(a||n!==void 0&&p.has(t)){C=!0,o=p.get(t)||_,p.delete(t)&&(w=!0),i.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)}else i.protectedKeys[t]=!0;i.out[t]=o}if(i.prevProp=v,i.prevResolvedValues=E,i.prevOut=D,i.isActive&&(m={...m,...E}),C&&(!(x&&S)||w))for(let n of T){let r={type:t};if(typeof n==`string`&&u&&c&&s?.enteringChildren){let t=ls(s,n)?.transition?.delayChildren;r.delay=cs(s.enteringChildren,e,t)}d.push({animation:n,options:r})}}),p.size){let t={},n=f(),r=n?.transition;p.forEach((i,a)=>{i&&(r={...r||e.getDefaultTransition(),[a]:i});let s=e.getValue(a);s&&(s.liveStyle=!0);let c=n&&!Array.isArray(l)?n[a]:void 0,u=e.getBaseTargetFromProps(o,a);t[a]=(c===void 0?u!==void 0&&!Tn(u)?u:e.initialValues[a]===void 0?e.baseTarget[a]:void 0:c)??null}),r&&(t.transition=r),d.push({animation:t})}let v=u&&e.blockInitialAnimation||r&&!c&&(o.initial===!1||o.initial===o.animate);return r=i=!1,!v&&d.length?t(d):Promise.resolve()}function o(t,r){if(n[t].isActive===r)return Promise.resolve();e.variantChildren?.forEach(e=>e.animationState?.setActive(t,r)),n[t].isActive=r;let i=a(t);for(let e in n)n[e].protectedKeys={};return i}return{animateChanges:a,setActive:o,setAnimateFunction:n=>{t=n(e)},getState:()=>n,reset:()=>{n=Ru(),i=!0}}}function Lu(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!Nu(t,e):!1}function Ru(){let e={};for(let t of Yi)e[t]={isActive:t===`animate`,protectedKeys:{},needsAnimating:{},prevResolvedValues:{},out:{}};return e}var zu=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,Bu=e=>{let t=zu();return e.match(t)?.[0]},G=Yt(),K=t(Lt(),1),Vu=e=>{let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t=(t<<5)-t+r,t&=t}return Math.abs(t)},Hu=(e,t)=>Math.floor(e/10**t%10),Uu=(e,t)=>!(Hu(e,t)%2),q=(e,t,n)=>{let r=e%t;return n&&Hu(e,n)%2==0?-r:r},Wu=(e,t,n)=>t[e%n],Gu=e=>{e.slice(0,1)===`#`&&(e=e.slice(1));let t=parseInt(e.substr(0,2),16),n=parseInt(e.substr(2,2),16),r=parseInt(e.substr(4,2),16);return(t*299+n*587+r*114)/1e3>=128?`#000000`:`#FFFFFF`},Ku=4,J=80;function qu(e,t){let n=Vu(e),r=t&&t.length;return Array.from({length:Ku},(e,i)=>({color:Wu(n+i,t,r),translateX:q(n*(i+1),J/2-(i+17),1),translateY:q(n*(i+1),J/2-(i+17),2),rotate:q(n*(i+1),360),isSquare:Uu(n,2)}))}var Ju=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=qu(e,t),s=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:J,height:J,children:(0,G.jsx)(`rect`,{width:J,height:J,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:J,height:J,fill:o[0].color}),(0,G.jsx)(`rect`,{x:10,y:30,width:J,height:o[1].isSquare?J:J/8,fill:o[1].color,transform:`translate(`+o[1].translateX+` `+o[1].translateY+`) rotate(`+o[1].rotate+` 40 40)`}),(0,G.jsx)(`circle`,{cx:J/2,cy:J/2,fill:o[2].color,r:J/5,transform:`translate(`+o[2].translateX+` `+o[2].translateY+`)`}),(0,G.jsx)(`line`,{x1:0,y1:J/2,x2:J,y2:J/2,strokeWidth:2,stroke:o[3].color,transform:`translate(`+o[3].translateX+` `+o[3].translateY+`) rotate(`+o[3].rotate+` 40 40)`})]})]})},Yu=90,Xu=5;function Zu(e,t){let n=Vu(e),r=t&&t.length,i=Array.from({length:Xu},(e,i)=>Wu(n+i,t,r)),a=[];return a[0]=i[0],a[1]=i[1],a[2]=i[1],a[3]=i[2],a[4]=i[2],a[5]=i[3],a[6]=i[3],a[7]=i[0],a[8]=i[4],a}var Qu=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Zu(e,t),s=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 90 90`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:Yu,height:Yu,children:(0,G.jsx)(`rect`,{width:Yu,height:Yu,rx:r?void 0:180,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`path`,{d:`M0 0h90v45H0z`,fill:o[0]}),(0,G.jsx)(`path`,{d:`M0 45h90v45H0z`,fill:o[1]}),(0,G.jsx)(`path`,{d:`M83 45a38 38 0 00-76 0h76z`,fill:o[2]}),(0,G.jsx)(`path`,{d:`M83 45a38 38 0 01-76 0h76z`,fill:o[3]}),(0,G.jsx)(`path`,{d:`M77 45a32 32 0 10-64 0h64z`,fill:o[4]}),(0,G.jsx)(`path`,{d:`M77 45a32 32 0 11-64 0h64z`,fill:o[5]}),(0,G.jsx)(`path`,{d:`M71 45a26 26 0 00-52 0h52z`,fill:o[6]}),(0,G.jsx)(`path`,{d:`M71 45a26 26 0 01-52 0h52z`,fill:o[7]}),(0,G.jsx)(`circle`,{cx:45,cy:45,r:23,fill:o[8]})]})]})},$u=64,ed=80;function td(e,t){let n=Vu(e),r=t&&t.length;return Array.from({length:$u},(e,i)=>Wu(n%(i+1),t,r))}var nd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=td(e,t),s=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:s,"mask-type":`alpha`,maskUnits:`userSpaceOnUse`,x:0,y:0,width:ed,height:ed,children:(0,G.jsx)(`rect`,{width:ed,height:ed,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:10,height:10,fill:o[0]}),(0,G.jsx)(`rect`,{x:20,width:10,height:10,fill:o[1]}),(0,G.jsx)(`rect`,{x:40,width:10,height:10,fill:o[2]}),(0,G.jsx)(`rect`,{x:60,width:10,height:10,fill:o[3]}),(0,G.jsx)(`rect`,{x:10,width:10,height:10,fill:o[4]}),(0,G.jsx)(`rect`,{x:30,width:10,height:10,fill:o[5]}),(0,G.jsx)(`rect`,{x:50,width:10,height:10,fill:o[6]}),(0,G.jsx)(`rect`,{x:70,width:10,height:10,fill:o[7]}),(0,G.jsx)(`rect`,{y:10,width:10,height:10,fill:o[8]}),(0,G.jsx)(`rect`,{y:20,width:10,height:10,fill:o[9]}),(0,G.jsx)(`rect`,{y:30,width:10,height:10,fill:o[10]}),(0,G.jsx)(`rect`,{y:40,width:10,height:10,fill:o[11]}),(0,G.jsx)(`rect`,{y:50,width:10,height:10,fill:o[12]}),(0,G.jsx)(`rect`,{y:60,width:10,height:10,fill:o[13]}),(0,G.jsx)(`rect`,{y:70,width:10,height:10,fill:o[14]}),(0,G.jsx)(`rect`,{x:20,y:10,width:10,height:10,fill:o[15]}),(0,G.jsx)(`rect`,{x:20,y:20,width:10,height:10,fill:o[16]}),(0,G.jsx)(`rect`,{x:20,y:30,width:10,height:10,fill:o[17]}),(0,G.jsx)(`rect`,{x:20,y:40,width:10,height:10,fill:o[18]}),(0,G.jsx)(`rect`,{x:20,y:50,width:10,height:10,fill:o[19]}),(0,G.jsx)(`rect`,{x:20,y:60,width:10,height:10,fill:o[20]}),(0,G.jsx)(`rect`,{x:20,y:70,width:10,height:10,fill:o[21]}),(0,G.jsx)(`rect`,{x:40,y:10,width:10,height:10,fill:o[22]}),(0,G.jsx)(`rect`,{x:40,y:20,width:10,height:10,fill:o[23]}),(0,G.jsx)(`rect`,{x:40,y:30,width:10,height:10,fill:o[24]}),(0,G.jsx)(`rect`,{x:40,y:40,width:10,height:10,fill:o[25]}),(0,G.jsx)(`rect`,{x:40,y:50,width:10,height:10,fill:o[26]}),(0,G.jsx)(`rect`,{x:40,y:60,width:10,height:10,fill:o[27]}),(0,G.jsx)(`rect`,{x:40,y:70,width:10,height:10,fill:o[28]}),(0,G.jsx)(`rect`,{x:60,y:10,width:10,height:10,fill:o[29]}),(0,G.jsx)(`rect`,{x:60,y:20,width:10,height:10,fill:o[30]}),(0,G.jsx)(`rect`,{x:60,y:30,width:10,height:10,fill:o[31]}),(0,G.jsx)(`rect`,{x:60,y:40,width:10,height:10,fill:o[32]}),(0,G.jsx)(`rect`,{x:60,y:50,width:10,height:10,fill:o[33]}),(0,G.jsx)(`rect`,{x:60,y:60,width:10,height:10,fill:o[34]}),(0,G.jsx)(`rect`,{x:60,y:70,width:10,height:10,fill:o[35]}),(0,G.jsx)(`rect`,{x:10,y:10,width:10,height:10,fill:o[36]}),(0,G.jsx)(`rect`,{x:10,y:20,width:10,height:10,fill:o[37]}),(0,G.jsx)(`rect`,{x:10,y:30,width:10,height:10,fill:o[38]}),(0,G.jsx)(`rect`,{x:10,y:40,width:10,height:10,fill:o[39]}),(0,G.jsx)(`rect`,{x:10,y:50,width:10,height:10,fill:o[40]}),(0,G.jsx)(`rect`,{x:10,y:60,width:10,height:10,fill:o[41]}),(0,G.jsx)(`rect`,{x:10,y:70,width:10,height:10,fill:o[42]}),(0,G.jsx)(`rect`,{x:30,y:10,width:10,height:10,fill:o[43]}),(0,G.jsx)(`rect`,{x:30,y:20,width:10,height:10,fill:o[44]}),(0,G.jsx)(`rect`,{x:30,y:30,width:10,height:10,fill:o[45]}),(0,G.jsx)(`rect`,{x:30,y:40,width:10,height:10,fill:o[46]}),(0,G.jsx)(`rect`,{x:30,y:50,width:10,height:10,fill:o[47]}),(0,G.jsx)(`rect`,{x:30,y:60,width:10,height:10,fill:o[48]}),(0,G.jsx)(`rect`,{x:30,y:70,width:10,height:10,fill:o[49]}),(0,G.jsx)(`rect`,{x:50,y:10,width:10,height:10,fill:o[50]}),(0,G.jsx)(`rect`,{x:50,y:20,width:10,height:10,fill:o[51]}),(0,G.jsx)(`rect`,{x:50,y:30,width:10,height:10,fill:o[52]}),(0,G.jsx)(`rect`,{x:50,y:40,width:10,height:10,fill:o[53]}),(0,G.jsx)(`rect`,{x:50,y:50,width:10,height:10,fill:o[54]}),(0,G.jsx)(`rect`,{x:50,y:60,width:10,height:10,fill:o[55]}),(0,G.jsx)(`rect`,{x:50,y:70,width:10,height:10,fill:o[56]}),(0,G.jsx)(`rect`,{x:70,y:10,width:10,height:10,fill:o[57]}),(0,G.jsx)(`rect`,{x:70,y:20,width:10,height:10,fill:o[58]}),(0,G.jsx)(`rect`,{x:70,y:30,width:10,height:10,fill:o[59]}),(0,G.jsx)(`rect`,{x:70,y:40,width:10,height:10,fill:o[60]}),(0,G.jsx)(`rect`,{x:70,y:50,width:10,height:10,fill:o[61]}),(0,G.jsx)(`rect`,{x:70,y:60,width:10,height:10,fill:o[62]}),(0,G.jsx)(`rect`,{x:70,y:70,width:10,height:10,fill:o[63]})]})]})},rd=36;function id(e,t){let n=Vu(e),r=t&&t.length,i=Wu(n,t,r),a=q(n,10,1),o=a<5?a+rd/9:a,s=q(n,10,2),c=s<5?s+rd/9:s;return{wrapperColor:i,faceColor:Gu(i),backgroundColor:Wu(n+13,t,r),wrapperTranslateX:o,wrapperTranslateY:c,wrapperRotate:q(n,360),wrapperScale:1+q(n,rd/12)/10,isMouthOpen:Uu(n,2),isCircle:Uu(n,1),eyeSpread:q(n,5),mouthSpread:q(n,3),faceRotate:q(n,10,3),faceTranslateX:o>rd/6?o/2:q(n,8,1),faceTranslateY:c>rd/6?c/2:q(n,7,2)}}var ad=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=id(e,t),s=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 36 36`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:rd,height:rd,children:(0,G.jsx)(`rect`,{width:rd,height:rd,rx:r?void 0:72,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:rd,height:rd,fill:o.backgroundColor}),(0,G.jsx)(`rect`,{x:`0`,y:`0`,width:rd,height:rd,transform:`translate(`+o.wrapperTranslateX+` `+o.wrapperTranslateY+`) rotate(`+o.wrapperRotate+` 18 18) scale(`+o.wrapperScale+`)`,fill:o.wrapperColor,rx:o.isCircle?rd:rd/6}),(0,G.jsxs)(`g`,{transform:`translate(`+o.faceTranslateX+` `+o.faceTranslateY+`) rotate(`+o.faceRotate+` 18 18)`,children:[o.isMouthOpen?(0,G.jsx)(`path`,{d:`M15 `+(19+o.mouthSpread)+`c2 1 4 1 6 0`,stroke:o.faceColor,fill:`none`,strokeLinecap:`round`}):(0,G.jsx)(`path`,{d:`M13,`+(19+o.mouthSpread)+` a1,0.75 0 0,0 10,0`,fill:o.faceColor}),(0,G.jsx)(`rect`,{x:14-o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor}),(0,G.jsx)(`rect`,{x:20+o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor})]})]})]})},od=4,sd=80;function cd(e,t){let n=Vu(e),r=t&&t.length;return Array.from({length:od},(e,i)=>Wu(n+i,t,r))}var ld=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=cd(e,t),s=e.replace(/\s/g,``),c=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:c,maskUnits:`userSpaceOnUse`,x:0,y:0,width:sd,height:sd,children:(0,G.jsx)(`rect`,{width:sd,height:sd,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${c})`,children:[(0,G.jsx)(`path`,{fill:`url(#gradient_paint0_linear_`+s+`)`,d:`M0 0h80v40H0z`}),(0,G.jsx)(`path`,{fill:`url(#gradient_paint1_linear_`+s+`)`,d:`M0 40h80v40H0z`})]}),(0,G.jsxs)(`defs`,{children:[(0,G.jsxs)(`linearGradient`,{id:`gradient_paint0_linear_`+s,x1:sd/2,y1:0,x2:sd/2,y2:sd/2,gradientUnits:`userSpaceOnUse`,children:[(0,G.jsx)(`stop`,{stopColor:o[0]}),(0,G.jsx)(`stop`,{offset:1,stopColor:o[1]})]}),(0,G.jsxs)(`linearGradient`,{id:`gradient_paint1_linear_`+s,x1:sd/2,y1:sd/2,x2:sd/2,y2:sd,gradientUnits:`userSpaceOnUse`,children:[(0,G.jsx)(`stop`,{stopColor:o[2]}),(0,G.jsx)(`stop`,{offset:1,stopColor:o[3]})]})]})]})},ud=3,dd=80;function fd(e,t){let n=Vu(e),r=t&&t.length;return Array.from({length:ud},(e,i)=>({color:Wu(n+i,t,r),translateX:q(n*(i+1),dd/10,1),translateY:q(n*(i+1),dd/10,2),scale:1.2+q(n*(i+1),dd/20)/10,rotate:q(n*(i+1),360,1)}))}var pd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=fd(e,t),s=K.useId();return(0,G.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,G.jsx)(`title`,{children:e}),(0,G.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:dd,height:dd,children:(0,G.jsx)(`rect`,{width:dd,height:dd,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:dd,height:dd,fill:o[0].color}),(0,G.jsx)(`path`,{filter:`url(#filter_${s})`,d:`M32.414 59.35L50.376 70.5H72.5v-71H33.728L26.5 13.381l19.057 27.08L32.414 59.35z`,fill:o[1].color,transform:`translate(`+o[1].translateX+` `+o[1].translateY+`) rotate(`+o[1].rotate+` 40 40) scale(`+o[2].scale+`)`}),(0,G.jsx)(`path`,{filter:`url(#filter_${s})`,style:{mixBlendMode:`overlay`},d:`M22.216 24L0 46.75l14.108 38.129L78 86l-3.081-59.276-22.378 4.005 12.972 20.186-23.35 27.395L22.215 24z`,fill:o[2].color,transform:`translate(`+o[2].translateX+` `+o[2].translateY+`) rotate(`+o[2].rotate+` 40 40) scale(`+o[2].scale+`)`})]}),(0,G.jsx)(`defs`,{children:(0,G.jsxs)(`filter`,{id:`filter_${s}`,filterUnits:`userSpaceOnUse`,colorInterpolationFilters:`sRGB`,children:[(0,G.jsx)(`feFlood`,{floodOpacity:0,result:`BackgroundImageFix`}),(0,G.jsx)(`feBlend`,{in:`SourceGraphic`,in2:`BackgroundImageFix`,result:`shape`}),(0,G.jsx)(`feGaussianBlur`,{stdDeviation:7,result:`effect1_foregroundBlur`})]})})]})},md={pixel:nd,bauhaus:Ju,ring:Qu,beam:ad,sunset:ld,marble:pd,geometric:ad,abstract:Ju},hd=({variant:e=`marble`,colors:t=[`#92A1C6`,`#146A7C`,`#F0AB3D`,`#C271B4`,`#C20D90`],name:n=`Clara Barton`,title:r=!1,size:i=`40px`,square:a=!1,...o})=>{let s=md[e]||pd;return(0,G.jsx)(s,{colors:t,name:n,title:r,size:i,square:a,...o})},gd=It({block:`img`,elements:[]}),_d=e=>(0,K.memo)(t=>(0,K.createElement)(e,t)),vd=({unoptimized:e,...t})=>{let n=(0,K.use)(w),r=n?.imgAs||`img`,i=(0,K.useMemo)(()=>_d(r),[r]);return(0,G.jsx)(i,{unoptimized:e===void 0?n?.imgUnoptimized:e,...t,className:V(gd(),t.className)})};vd.displayName=`Img`;var yd=It({block:`fluent-emoji`,elements:[]}),bd={container:{kLWn49:`lbo5v014`,kVAEAm:`lb1n2onr6`,k9WMMc:`lb2b8uid`,$$css:!0}};function xd(e){return[...e].map(e=>e?.codePointAt(0)?.toString(16)).join(`-`)}function Sd(e){let t=xd(e).split(`-`)[0];return t<`1f469`?`@lobehub/fluent-emoji-anim-1`:t>=`1f469`&&t<`1f620`?`@lobehub/fluent-emoji-anim-2`:t>=`1f620`&&t<`1f9a0`?`@lobehub/fluent-emoji-anim-3`:`@lobehub/fluent-emoji-anim-4`}var Cd=(e,t)=>{let n=[`anim`,`3d`].includes(t)?`webp`:`svg`;switch(t){case`raw`:return null;case`anim`:return{path:`assets/${xd(e)}.${n}`,pkg:Sd(e),version:`latest`};case`3d`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-3d`,version:`latest`};case`flat`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-flat`,version:`latest`};case`modern`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-modern`,version:`latest`};case`mono`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-mono`,version:`latest`}}},wd=({emoji:e,className:t,style:n,type:r=`3d`,size:i=40,unoptimized:a,ref:o,...s})=>{let[c,l]=(0,K.useState)(!1),u=ie(),d=(0,K.useMemo)(()=>Cd(e,r),[r,e]);return r===`raw`||!d||c?(0,G.jsx)(vn,{flex:`none`,height:i,ref:o,role:`img`,width:i,...s,...B(bd.container,V(yd(),t),{fontSize:i*.9,...n}),children:e}):(0,G.jsx)(vd,{alt:e,className:V(yd(),t),height:i,loading:`lazy`,ref:o,src:u(d),style:{flex:`none`,...n},unoptimized:a,width:i,onError:()=>l(!0),...s})};wd.displayName=`FluentEmoji`;var Td=e=>`oklch(from ${e} clamp(0, (l - 0.62) * -1000, 1) 0 h / 1)`,Ed=It({block:`avatar`,dataAttributes:[`shape`,`variant`,`shadow`],elements:[`loading`,`img`,`content`,`fallback`]}),Dd=It({block:`avatar-group`,elements:[`avatar`,`count`,`item`,`badge`]}),Od={circle:{kaIpWk:`lb16rqkct`,$$css:!0},clickable:{kkrTdU:`lb1ypdohk`,$$css:!0},defaultBackground:{kWkggS:`lb1yqcoyj`,$$css:!0},defaultColor:{kMwMTN:`lb6dwly7`,$$css:!0},defaultEmojiFont:{kGuDYH:`lbh7pmyk`,$$css:!0},defaultSize:{kGuDYH:`lb1pvqxga`,kZKoxP:`lbsdox4t`,kzqmXN:`lb1useyqa`,$$css:!0},defaultSquare:{kaIpWk:`lbur7f20`,$$css:!0},content:{kmVPX3:`lb1717udv`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kMwMTN:`lb1heor9g`,k1xSpc:`lb78zum5`,kGuDYH:`lb1qlqyl8`,k63SB2:`lbjs9k72`,kjj79g:`lbl56j7k`,kLWn49:`lbo5v014`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},fallback:{kUk6DE:`lb1okw0bk`,k1xSpc:`lb1lliihq`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},img:{kUk6DE:`lb1okw0bk`,kVIFPx:`lbl1xv1r`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},loading:{kpwlN0:`lb10a8y8t`,kWkggS:`lb1a3x57l`,kMwMTN:`lbfungia`,kVAEAm:`lb10l6tqk`,$$css:!0},root:{kUk6DE:`lb1okw0bk`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kWkggS:`lbjbqb8w`,k1xSpc:`lb78zum5`,kjj79g:`lbl56j7k`,kVAEAm:`lb1n2onr6`,kfSwDN:`lb87ps6o`,$$css:!0},shadow:{kGVxlE:`lbpjwdtl`,$$css:!0}},kd=e=>e?!!(typeof e==`string`&&[`/`,`http`,`data:`].some(t=>e.startsWith(t))||(0,K.isValidElement)(e)):!1,Ad=e=>!!(e&&e!==`transparent`&&e!==`rgba(0,0,0,0)`&&e!==null),jd=(e,t)=>{if(!e)return``;let n=e.toUpperCase();return t?n.slice(0,2):n},Md=(e,t,n)=>n?t?e*.85:e:e*.85,Nd=[`#383838`,`#7858f9`,`#f8f7bf`,`#ffdd1f`,`#f88c13`],Pd=(e,t,n)=>(t||n||typeof e==`string`&&e||void 0)?.trim().replaceAll(/[\s"'()#\\]+/g,`_`)||void 0,Fd={borderless:oe.variantBorderlessWithoutHover,filled:oe.variantFilledWithoutHover,outlined:oe.variantOutlinedWithoutHover},Id=(0,K.memo)(({alt:e,animation:t,avatar:n,background:r,bordered:i,borderedColor:a,className:o,classNames:s,crossOrigin:c,draggable:l=!1,emojiScaleWithBackground:u=!0,fallbackColors:d,fallbackVariant:f=`marble`,loading:p,ref:m,shadow:h,shape:g=`square`,size:_,sliceText:v=!0,style:y,styles:b,title:x,tooltipProps:S,unoptimized:C,variant:w=`borderless`,xstyle:T,contentXstyle:E,nativeTitle:D,...O})=>{let k=_??48,A=typeof n==`string`,[j,ee]=(0,K.useState)(!1),M=(0,K.useMemo)(()=>kd(n),[n]),te=(0,K.useMemo)(()=>n&&A&&!M?Bu(n):void 0,[n,A,M]),N=M?x:typeof n==`string`?n:void 0,P=e||x||`avatar`,ne=Ad(r),re=M&&A&&!j,ie=M&&!A&&!j,F=Pd(n,x,e),ae=f!==`text`&&!!F&&!te&&!re&&!ie,I=d?.length?d:Nd,oe=(0,K.useMemo)(()=>te?(0,G.jsx)(wd,{emoji:te,size:Md(k,ne,u),type:t?`anim`:`3d`,unoptimized:C}):jd(N||x,v),[t,te,ne,k,v,N,x,C,u]),se=_!==void 0,ce=!r&&!ae&&!(M&&!j||te);return(0,G.jsxs)(`div`,{...Ft({shadow:h,shape:g,variant:w}),...O,ref:m,title:D,className:B([Od.root,Fd[w],h&&Od.shadow,!se&&Od.defaultSize,!se&&!!te&&Od.defaultEmojiFont,g===`circle`?Od.circle:!se&&Od.defaultSquare,ce&&Od.defaultBackground,!r&&Od.defaultColor,!!O?.onClick&&Od.clickable,T],V(Ed(),o,s?.root)).className,style:{...r&&{backgroundColor:r,color:Td(r)},...se&&{fontSize:k*(te?.7:.5),height:k,width:k,...g!==`circle`&&{borderRadius:k<24?`33%`:Math.max(k/6,2)}},...i&&{boxShadow:`${Ve.colorBgLayout} 0 0 0 2px, ${a||Ve.colorTextTertiary} 0 0 0 4px`},...y,...b?.root},children:[p&&(0,G.jsx)(vn,{flex:`none`,height:`100%`,width:`100%`,...B(Od.loading,V(Ed(`loading`),s?.loading),b?.loading),children:(0,G.jsx)(St,{spin:!0,icon:He})}),typeof n==`string`&&re&&(0,G.jsx)(`img`,{alt:P,crossOrigin:c,draggable:l,height:k,loading:`lazy`,src:n,width:k,...B(Od.img,V(Ed(`img`),s?.img),b?.img),onError:()=>ee(!0)}),ae&&(0,G.jsx)(hd,{square:!0,"aria-label":P,colors:I,name:F,size:`100%`,variant:f,...B(Od.fallback,V(Ed(`fallback`),s?.fallback),b?.fallback)}),!re&&!ae&&(0,G.jsx)(`span`,{...B([Od.content,E],V(Ed(`content`),s?.content),b?.content),children:ie?n:oe})]})});Id.displayName=`Avatar`;var Ld=Id,Rd={avatar:{kVAM5u:`lbfbyuaw`,ksu8eU:`lb1y0btm7`,kMzoRj:`lbdh2fpr`,$$css:!0},root:{kVAEAm:`lb1n2onr6`,$$css:!0},count:{kMwMTN:`lb15g0kca`,kGuDYH:`lbsfzzmd`,$$css:!0},item:{kUk6DE:`lb1okw0bk`,k1xSpc:`lb3nfvp2`,kVAEAm:`lb1n2onr6`,$$css:!0},badge:{k1xSpc:`lb78zum5`,kt4wiu:`lbtijo5x`,kfzvcC:`lb47corl`,kVAEAm:`lb10l6tqk`,k3aq6I:`lbdu4413`,krVfgx:`lb1ey2m1c`,$$css:!0}},zd=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.currentTarget.click())},Bd=(0,K.memo)(({items:e,max:t,gap:n,variant:r=`borderless`,bordered:i,shadow:a,size:o,background:s,animation:c,draggable:l,fallbackColors:u,fallbackVariant:d,classNames:f,shape:p,styles:m,onClick:h,ref:g,zIndexReverse:_,className:v,...y})=>{let b=o??48,x=t?e.slice(0,t):e,S=e.slice(t,e.length),C=n??Math.floor(-b/4),w=S.map(e=>e.title??e.label??e.alt).filter(Boolean).join(`, `),T={animation:c,background:s,bordered:i,draggable:l,fallbackColors:u,fallbackVariant:d,shadow:a,shape:p,size:o,variant:r};return(0,G.jsxs)(un,{horizontal:!0,gap:n,ref:g,...B(Rd.root,V(Dd(),v)),...y,children:[x.map((t,n)=>{let{key:r,style:i,className:a,ringColor:o,label:s,pressed:c,disabled:l,badge:u,onClick:d,...p}=t,g=!l&&(!!h||!!d),v={marginLeft:n===0?0:C,zIndex:u?e.length+1:_?e.length-n:n},y=(0,G.jsx)(Id,{"aria-disabled":l||void 0,"aria-label":s,"aria-pressed":g?!!c:void 0,className:V(Dd(`avatar`),f?.avatar,a),nativeTitle:s,role:g?`button`:void 0,tabIndex:g?0:void 0,xstyle:Rd.avatar,style:{...!u&&v,...o&&{boxShadow:`0 0 0 2px ${o}`},...m?.avatar,...i},onKeyDown:g?zd:void 0,onClick:g?d??(()=>h?.({item:t,key:r})):void 0,...T,...p},u?void 0:r);if(!u)return y;let b=B(Rd.item,Dd(`item`));return(0,G.jsxs)(`span`,{className:b.className,style:{...b.style,...v},children:[y,(0,G.jsx)(`span`,{...B(Rd.badge,Dd(`badge`)),children:u})]},r)}),t&&S.length>0&&(0,G.jsx)(Id,{...T,"aria-label":w||void 0,avatar:`+${S.length}`,background:Ve.colorText,className:V(Dd(`count`),f?.count),contentXstyle:Rd.count,fallbackVariant:`text`,nativeTitle:w||void 0,sliceText:!1,xstyle:Rd.avatar,style:{marginLeft:C,zIndex:_?0:x.length,...m?.count}})]})});Bd.displayName=`AvatarGroup`;var Vd=Ld;Vd.Group=Bd;function Hd({children:e,features:t,strict:n=!1}){let[,r]=(0,K.useState)(!Ud(t)),i=(0,K.useRef)(void 0);if(!Ud(t)){let{renderer:e,...n}=t;i.current=e,Ba(n)}return(0,K.useEffect)(()=>{Ud(t)&&t().then(({renderer:e,...t})=>{Ba(t),i.current=e,r(!0)})},[]),(0,G.jsx)(Pi.Provider,{value:{renderer:i.current,strict:n},children:e})}function Ud(e){return typeof e==`function`}function Wd(e,t){if(typeof Proxy>`u`)return ra;let n=new Map,r=(n,r)=>ra(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,ra(a,void 0,e,t)),n.get(a))})}var Gd=Wd(),Kd=(e,t)=>t.isSVG??Ta(e)?new Mu(t):new ul(t,{allowProjection:e!==K.Fragment}),qd=class extends ku{constructor(e){super(e),e.animationState||=Iu(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();Qa(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){this.node.getProps().animate!==this.node.prevProps?.animate&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}},Jd=0,Yd={animation:{Feature:qd},exit:{Feature:class extends ku{constructor(){super(...arguments),this.id=Jd++}update(){let{presenceContext:e,animationState:t}=this.node;if(!e||!t)return;let{isPresent:n,onExitComplete:r}=e;if(n===!this.exit)return;if(n){if(this.exit===!0){let{initial:e}=this.node.getProps();if(e&&!Array.isArray(e)){let{transition:t,transitionEnd:n,...r}=ls(this.node,e)||{};for(let e in r)this.node.getValue(e)?.jump(r[e])}this.node.blockInitialAnimation=!1,t.reset(),t.animateChanges()}else t.setActive(`exit`,!1);this.exit=void 0;return}let i=this.exit=t.setActive(`exit`,!0);r&&i.then(()=>{this.exit===i&&(this.exit=!0,r(this.id))})}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id,this.node)),this.update()}unmount(){}}}},Xd=class extends ku{constructor(e){super(e),this.removeGroupControls=bn,this.removeListeners=bn,this.controls=new ou(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||bn}update(){let{dragControls:e,drag:t}=this.node.getProps(),{dragControls:n,drag:r}=this.node.prevProps||{};e!==n&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls))),r&&!t&&this.controls.stop(void 0,void 0,r)}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}},Zd=e=>(t,n)=>{e&&H.update(()=>e(t,n),!1,!0)},Qd=class extends ku{constructor(){super(...arguments),this.removePointerDownListener=bn}onPointerDown(e){this.session=new Ml(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:this.node.current?.ownerDocument.defaultView})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Zd(e),onStart:Zd(t),onMove:Zd(n),onEnd:(e,t)=>{delete this.session,r&&H.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=ml(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session?.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session?.end()}},$d=!1,ef=({layout:e,layoutDependency:t,layoutAnchor:n})=>({layout:e,layoutDependency:t,layoutAnchor:n,animationType:typeof e==`string`?e:`both`}),tf=(e,t)=>{let{snapshot:n}=e,r=e.getStack();r?.remove(e);let i=r?.lead;if(r?.prevLead===e&&i.resumeFrom===e&&(i.resumeFrom=i.currentAnimation=e.resumingFrom=void 0),e.options.layoutId=t,!t)e.needsShow=!0;else return e.root.registerSharedNode(t,e),()=>{let{resumeFrom:t}=e;t?.isPresent!==!1&&e.getStack().members.includes(t)&&(t.hide(),e.resumeFrom=void 0,e.snapshot=n)}},nf=class extends K.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;i&&(t.group?.add(i),r&&n?.register?.(i),$d&&i.root.didUpdate(),i.options.layoutId!==r&&tf(i,r)?.(),i.addEventListener(`animationComplete`,()=>this.safeToRemove()),i.setOptions({...i.options,...ef(this.props),onExitComplete:()=>this.safeToRemove()})),wc.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,layoutId:n,visualElement:r,drag:i,isPresent:a}=this.props,{projection:o}=r;return o&&(o.isPresent=a,this.takeOver=e.layoutId===n?void 0:(o.willUpdate(),tf(o,n)),o.setOptions({...o.options,...ef(this.props)}),$d=!0,i||e.layoutDependency!==t||t===void 0||e.isPresent!==a?o.willUpdate():this.safeToRemove(),e.isPresent!==a&&(a?o.promote():o.relegate()||H.postRender(()=>{o.getStack()?.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(this.takeOver?.(),e.root.didUpdate(),Rn.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;$d=!0,r&&(r.scheduleCheckAfterUnmount(),t.group?.remove(r),n?.deregister?.(r))}safeToRemove(){this.props.safeToRemove?.()}render(){return null}};function rf(e){let[t,n]=ye(),r=(0,K.useContext)(xn);return(0,G.jsx)(nf,{...e,layoutGroup:r,switchLayoutGroup:(0,K.useContext)(Di),isPresent:t,safeToRemove:n})}var af={pan:{Feature:Qd},drag:{Feature:Xd,ProjectionNode:ol,MeasureLayout:rf}};function of(e,t,n,r,i){let{props:a}=e,o=`while`+n;!i&&e.animationState&&a[o]&&e.animationState.setActive(o,r===`Start`);let s=a[`on`+n+r];s&&H.postRender(()=>s(t,fl(t)))}var sf=class extends ku{mount(){let{current:e}=this.node;e&&(this.unmount=hu(e,(e,t)=>(of(this.node,t,`Hover`,`Start`),e=>of(this.node,e,`Hover`,`End`))))}unmount(){}},cf=class extends ku{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(`:focus-visible`)}catch{e=!0}e&&this.node.animationState&&(this.node.animationState.setActive(`whileFocus`,!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive(`whileFocus`,!1),this.isActive=!1)}mount(){this.unmount=te(il(this.node.current,`focus`,()=>this.onFocus()),il(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}};function lf(e,t,n,r){e.current instanceof HTMLButtonElement&&e.current.disabled||of(e,t,`Tap`,n,r)}var uf=class extends ku{constructor(){super(...arguments),this.options={}}mount(){let{current:e}=this.node;e&&(this.update(),this.unmount=Du(e,(e,t)=>(lf(this.node,t,`Start`),{onComplete:(e,{success:t})=>lf(this.node,e,t?``:`Cancel`),onRepeat:()=>lf(this.node,t,``,!0)}),this.options))}update(){let{options:e,node:t}=this,{globalTapTarget:n,propagate:r,tap:i}=t.props;for(let t in e)delete e[t];Object.assign(e,i,{useGlobalTarget:n,stopPropagation:r?.tap===!1})}unmount(){}},df=new WeakMap,ff=new WeakMap,pf=e=>{let t=df.get(e.target);t&&t(e)},mf=e=>{e.forEach(pf)};function hf({root:e,...t}){let n=e||document;ff.has(n)||ff.set(n,{});let r=ff.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(mf,{root:e,...t})),r[i]}function gf(e,t,n){let r=hf(t);return df.set(e,n),r.observe(e),()=>{df.delete(e),r.unobserve(e)}}var _f={some:0,all:1},vf=class extends ku{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r=`some`,once:i}=e,a={root:t?t.current:void 0,rootMargin:n,threshold:typeof r==`number`?r:_f[r]},o=e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive(`whileInView`,t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),a=t?n:r;a&&a(e)};this.stopObserver=gf(this.node.current,a,o)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>`u`)return;let{props:e,prevProps:t}=this.node;[`amount`,`margin`,`root`].some(yf(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function yf({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}var bf=Object.assign({},Object.assign({renderer:Kd},Yd,{inView:{Feature:vf},tap:{Feature:uf},focus:{Feature:cf},hover:{Feature:sf}}),af,{layout:{ProjectionNode:ol,MeasureLayout:rf}});function xf(e){let t=jn(()=>Nn(e)),{isStatic:n}=(0,K.useContext)(Bn);if(n){let[,n]=(0,K.useState)(e);(0,K.useEffect)(()=>t.on(`change`,n),[])}return t}function Sf(e,t){let n=xf(t()),r=()=>n.set(t());return r(),Ln(()=>{let t=()=>H.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return r(),()=>{n.forEach(e=>e()),yn(r)}}),n}function Cf(e){In.current=[],e();let t=Sf(In.current,e);return In.current=void 0,t}function wf(e,t,n,r){if(typeof e==`function`)return Cf(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return Ef(e,t,n,r);let i=typeof t==`function`?t:Ou(t,n,r),a=Array.isArray(e)?Tf(e,i):Tf([e],([e])=>i(e)),o=Array.isArray(e)?void 0:e.accelerate;if(o&&!o.isTransformed&&typeof t!=`function`&&Array.isArray(n)&&r?.clamp!==!1&&!r?.mixer){let e=r?.ease;a.accelerate={...o,times:[0,...t,1],keyframes:[n[0],...n,n[n.length-1]],isTransformed:!0,...e?{ease:Array.isArray(e)?[e[0],...e]:e}:{}}}return a}function Tf(e,t){let n=jn(()=>[]);return Sf(e,()=>{n.length=0;let r=e.length;for(let t=0;t<r;t++)n[t]=e[t].get();return t(n)})}function Ef(e,t,n,r){let i=jn(()=>Object.keys(n)),a=jn(()=>({}));for(let o of i)a[o]=wf(e,t,n[o],r);return a}function Df(){!_a.current&&ka();let[e]=(0,K.useState)($i.current);return e}var Of=(0,K.createContext)(null),kf=(0,K.createContext)(null);function Af(e,t,n,r,i,a=`ltr`){let o=e.findIndex(e=>e.value===t);if(o===-1)return e;if(i===`xy`){let{layout:t}=e[o],r={x:Mf(t.x)+n.x,y:Mf(t.y)+n.y},i=Nf(e),s=i.find(t=>t.items.includes(e[o])),c=i.reduce((e,t)=>Pf(r.y,t)<Pf(r.y,e)?t:e);if(c!==s)return Ff(e,o,r.x,c,a);let l=If(r,t),u=-1,d=l;return e.forEach((e,t)=>{if(t===o)return;let n=If(r,e.layout);n<d&&(u=t,d=n)}),u===-1?e:cn(e,o,o+Math.sign(u-o))}if(!r[i])return e;let s=r[i]>0?1:-1,c=e[o+s];if(!c)return e;let l=e[o].layout[i],u=c.layout[i],d=Mf(u);return s===1&&l.max+n[i]>d||s===-1&&l.min+n[i]<d?cn(e,o,o+s):e}function jf(e,t,n,r,i){let a=n>1==!!(n%2&&i)?-1:1,o=n>3?(n-4)*(e.length-1):t+a;if(r===`xy`&&n<4&&!(n%2)&&t>-1){let n=Nf(e).sort((e,t)=>e.min-t.min),r=n[n.findIndex(({items:n})=>n.includes(e[t]))+a],i=n=>Math.abs(Mf(n.layout.x)-Mf(e[t].layout.x));o=r?e.indexOf(r.items.reduce((e,t)=>i(t)<i(e)?t:e)):-1}return t>-1&&o!==t&&e[o]?o:-1}var Mf=({min:e,max:t})=>N(e,t,.5);function Nf(e){let t=[];return e.forEach(e=>{let{min:n,max:r}=e.layout.y,i=t[t.length-1];!i||n>=i.max||r<=i.min?t.push({items:[e],min:n,max:r}):(i.items.push(e),i.min=Math.min(i.min,n),i.max=Math.max(i.max,r))}),t}function Pf(e,t){return e<t.min?t.min-e:e>t.max?e-t.max:0}function Ff(e,t,n,r,i){let a=e.filter((e,n)=>n!==t),o=r.items.find(e=>{let t=Mf(e.layout.x);return i===`ltr`?n<t:n>t}),s=o?a.indexOf(o):a.indexOf(r.items[r.items.length-1])+1,c=[...a];return c.splice(s,0,e[t]),c.every((t,n)=>t===e[n])?e:c}function If(e,t){let n=Math.max(t.x.min-e.x,0,e.x-t.x.max),r=Math.max(t.y.min-e.y,0,e.y-t.y.max);return n*n+r*r}var Lf=(e,t)=>e.max<=t.min||t.max<=e.min;function Rf(e){let t=!1,n=!1;for(let r=0;r<e.length;r++)for(let i=r+1;i<e.length;i++)if(t||=Lf(e[r].x,e[i].x),n||=Lf(e[r].y,e[i].y),t&&n)return`xy`;return t?`x`:`y`}var zf=(e,t)=>n=>{e.current=n;let r=typeof t==`function`?t(n):t&&(t.current=n);if(typeof r==`function`)return()=>{e.current=null,r()}};function Bf({children:e,as:t=`ul`,axis:n,onReorder:r,values:i,onPointerDownCapture:a,onClickCapture:o,...s},c,l){let u=jn(()=>l[t]),d=(0,K.useContext)(Of),f=(0,K.useRef)(new Map),p=(0,K.useRef)(new Map),[m,h]=(0,K.useState)(),[g,_]=(0,K.useState)(`y`),v=(0,K.useRef)(!1),y=(0,K.useRef)(!1),b=(0,K.useRef)(null),x=n||g,S=new Set(i);for(let e of[f.current,p.current])e.forEach((t,n)=>S.has(n)||e.delete(n));let C=S.has(m)?m:i[0],w=e=>p.current.get(e)?.current?.isConnected,T=e=>S.has(e)&&h(e),E=()=>{w(C)||T(i.find(w))};(0,K.useEffect)(E);let D=()=>i.flatMap(e=>f.current.get(e)||[]),O=()=>b.current?.ownerDocument.defaultView?.getComputedStyle(b.current).direction===`rtl`,k=(e,t)=>{let n=0,a=i.map(t=>f.current.has(t)?e[n++].value:t);a.some((e,t)=>e!==i[t])&&r(a,t)},A={axis:x,proxy:l,groupRef:b,hasReordered:y,values:i,onReorder:r,getOrder:D,isTabStop:e=>e===C||!S.has(e),setActive:T,checkTabStop:E,elements:p.current,onKeyDown:(e,t,n,r)=>{let{key:a,currentTarget:o}=e;if(e.defaultPrevented||e.target!==o||e.altKey||e.ctrlKey||e.metaKey)return;let s=D(),c=[`ArrowUp`,`ArrowLeft`,`ArrowDown`,`ArrowRight`,`Home`,`End`].indexOf(a),l=c%2;if(a===` `)e.repeat||r(o,n?void 0:i);else if(c<0&&!(a===`Escape`&&n))return;else if(!d?.isMoving(o)){if(a===`Escape`&&n){if(r(o),!d?.restore(A,t,o,n)){let e=n.flatMap(e=>s.filter(t=>t.value===e));k(s.map(t=>n.includes(t.value)?e.shift():t),t)}}else{let e=c>3||x===`xy`||x===(l?`x`:`y`),r=n?s:s.filter(({value:e})=>w(e)),i=r.findIndex(({value:e})=>e===t),a=e?jf(r,i,c,x,!!l&&O()):-1;if(a>-1)n?k(cn(s,i,a),t):p.current.get(r[a].value)?.current?.focus();else if(!(n&&c<4&&d?.key(A,t,c,o,n))&&!e)return}}e.preventDefault()},registerItem:(e,t,r)=>{if(f.current.set(e,{value:e,layout:t,ref:r}),!n){let e=Rf(D().map(e=>e.layout));e!==g&&_(e)}},updateOrder:(e,t,n)=>{if(v.current)return;let r=D(),i=Af(r,e,t,n,x,O()?`rtl`:`ltr`);r!==i&&(v.current=!0,y.current=!0,k(i,e))}};(0,K.useEffect)(()=>{v.current=!1},[i]),Ln(()=>d?.add(A));let j={overflowAnchor:`none`,...s.style};return(0,G.jsx)(u,{...s,style:j,ref:zf(b,c),onPointerDownCapture:e=>{y.current=!1,a?.(e)},onClickCapture:e=>{y.current&&e.detail&&(y.current=!1,e.stopPropagation(),e.preventDefault()),o?.(e)},ignoreStrict:!0,children:(0,G.jsx)(kf.Provider,{value:A,children:e})})}var Vf=e=>(0,K.forwardRef)((t,n)=>Bf(t,n,e)),Hf=50,Uf=1.5,Wf=new Set([`auto`,`scroll`]),Gf={x:new Map,y:new Map};function Kf(){Gf.x.clear(),Gf.y.clear()}function qf(e,t){let n=getComputedStyle(e),r=t===`x`?n.overflowX:n.overflowY;return e===document.body||e===document.documentElement||Wf.has(r)&&(t===`x`?e.scrollWidth>e.clientWidth:e.scrollHeight>e.clientHeight)}function Jf(e,t){let n=e?.parentElement;for(;n;){if(qf(n,t))return n;n=n.parentElement}return null}function Yf(e){let t=Math.min(1,1-e/Hf);return Uf*t*t*En.delta}function Xf(e,t,n){let r=t.getBoundingClientRect(),i=n===`x`?Math.max(0,r.left):Math.max(0,r.top),a=n===`x`?Math.min(window.innerWidth,r.right):Math.min(window.innerHeight,r.bottom),o=e-i,s=a-e;return o<Hf?{amount:-Yf(o),edge:`start`}:s<Hf?{amount:Yf(s),edge:`end`}:{amount:0,edge:null}}function Zf(e,t,n,r){if(!e)return;let i=Jf(e,n);if(!i)return;let{amount:a,edge:o}=Xf(t-(n===`x`?window.scrollX:window.scrollY),i,n),s=Gf[n];if(o===null){s.delete(i);return}let c=s.get(i),l=i===document.body||i===document.documentElement;if(c?.edge!==o){if(!(o===`start`&&r<0||o===`end`&&r>0))return;c={edge:o,limit:n===`x`?i.scrollWidth-(l?window.innerWidth:i.clientWidth):i.scrollHeight-(l?window.innerHeight:i.clientHeight)},s.set(i,c)}a>0&&(n===`x`?l?window.scrollX:i.scrollLeft:l?window.scrollY:i.scrollTop)>=c.limit||(n===`x`?l?window.scrollBy({left:a}):i.scrollLeft+=a:l?window.scrollBy({top:a}):i.scrollTop+=a)}function Qf(e,t=0){return Tn(e)?e:xf(t)}function $f({children:e,style:t={},value:n,as:r=`li`,onDragStart:i,onDrag:a,onDragEnd:o,onKeyDown:s,onFocus:c,onBlur:l,layout:u=!0,...d},f){let p=(0,K.useContext)(kf),m=(0,K.useContext)(Of),h=(0,K.useRef)(null),g=jn(()=>p.proxy[r]),_=(0,K.useRef)(),v={x:Qf(t.x),y:Qf(t.y)},y=wf([v.x,v.y],([e,t])=>e||t?1:`unset`),{axis:b,registerItem:x,updateOrder:S,groupRef:C,hasReordered:w,isTabStop:T,setActive:E,checkTabStop:D,elements:O,onKeyDown:k}=p,A=b===`xy`||m?!0:b;O.set(n,h),(0,K.useEffect)(()=>D);let j=(e,t)=>{_.current=t,t||m?.end(n),Fn.get(e)?.animationState?.setActive(`whileDrag`,!!t)},ee=(0,K.useRef)(!1);return Ln(()=>{m?.receive(p,n,h.current,j)&&(ee.current=!0)},[]),(0,G.jsx)(g,{drag:A,tabIndex:T(n)?0:-1,...d,dragSnapToOrigin:!0,style:{...t,x:v.x,y:v.y,zIndex:y},layout:u,onDragStart:(e,t)=>{ee.current?ee.current=!1:i?.(e,t)},onDrag:(e,t)=>{let{velocity:r,point:i}=t,o={x:v.x.get(),y:v.y.get()};m?.drag(p,n,h.current,e)||S(n,o,r);let s=m?[`x`,`y`]:[b===`xy`?Math.abs(r.x)>Math.abs(r.y)?`x`:`y`:b];for(let e of s)Zf(m&&!b.includes(e)?m.column(p):C.current,i[e],e,r[e]);a&&a(e,t)},onDragEnd:(e,t)=>{w.current=!1,Kf(),m?.end(n),o&&o(e,t)},onKeyDown:e=>{s?.(e),k(e,n,_.current,j)},onFocus:e=>{c?.(e),E(n)},onBlur:e=>{l?.(e),_.current&&j(e.currentTarget)},onLayoutMeasure:e=>{x(n,e,h)},ref:zf(h,f),ignoreStrict:!0,children:e})}var ep=(0,K.forwardRef)($f),tp=e=>{let{left:t,top:n,width:r,height:i}=e.getBoundingClientRect();return{x:t+r/2,y:n+i/2}},np=e=>{let{x:t,y:n}=tp(e),{scrollX:r,scrollY:i}=e.ownerDocument.defaultView;return{x:t+r,y:n+i}};function rp(e,t,n,r){let{left:i,right:a,top:o,bottom:s}=t.getBoundingClientRect(),c=r?e.x>(i+a)/2:e.x<=(i+a)/2,l=e.y<=(o+s)/2;return n===`x`?c:n===`y`?l:e.y<o||e.y<s&&c}var ip=(e,t)=>{let n=e.groupRef.current,r=t.groupRef.current;return n.contains(r)||r.contains(n)};function ap(e){let t=new Set,n,r=(t,n,r)=>!ip(t,n)&&e.current.canMove?.(r,t.values,n.values)!==!1,i,a=(e,t,r,i,a,o)=>{let s=tp(i),{values:c}=t;if(o===void 0){let e=t.getOrder().filter(e=>e.ref?.current?.isConnected),n=getComputedStyle(t.groupRef.current).direction===`rtl`,r=e.find(e=>rp(s,e.ref.current,t.axis,n)),i=e[e.length-1];o=r?c.indexOf(r.value):i?c.indexOf(i.value)+1:c.length}n={value:r,to:t.groupRef,element:i,centre:np(i),...a},t.hasReordered.current=!0,e.onReorder(e.values.filter(e=>e!==r),r),t.onReorder([...c.slice(0,o),r,...c.slice(o)],r)};return{add:e=>(t.add(e),()=>t.delete(e)),drag:(e,i,o,s)=>{if(!o?.isConnected)return!1;if(n?.controls?.isDragging)return n.value===i&&(n.centre=np(o),n.event=s),!0;let c=tp(o),l;for(let e of o.ownerDocument.elementsFromPoint(c.x,c.y))if(!o.contains(e)){for(let n of t)n.groupRef.current===e&&(l=n);if(l)break}if(!l||!r(e,l,i))return!1;let u=Fn.get(o);return a(e,l,i,o,{controls:u&&au.get(u),event:s}),!0},key:(e,n,o,s,c)=>{let l=tp(s),u=o%2?`x`:`y`,d=o>1?1:-1,f,p=1/0;for(let i of t){let t=i.groupRef.current;if(!t)continue;let{left:a,right:s,top:c,bottom:m,width:h,height:g}=t.getBoundingClientRect();if(!h&&!g||([m,s,c,a][o]-l[u])*d<=0)continue;let _=Math.max(a-l.x,0,l.x-s),v=Math.max(c-l.y,0,l.y-m);_*_+v*v<p&&r(e,i,n)&&(p=_*_+v*v,f=i)}return f?(i?.from!==c&&(i={group:e.groupRef,from:c}),a(e,f,n,s,{keys:!0,from:c}),!0):!1},restore:(e,n,r,o)=>{let s=i?.from===o&&[...t].find(e=>e.groupRef===i.group);if(!s||s.groupRef===e.groupRef)return!1;let c=o.slice(o.indexOf(n)+1),l=s.values.findIndex(e=>c.includes(e));return i=void 0,a(e,s,n,r,{keys:!0},l<0?s.values.length:l),!0},end:e=>{n?.value===e&&(n=void 0)},isMoving:e=>n?.element===e,receive:(e,t,r,i)=>{let a=Fn.get(r),o=a&&au.get(a);o?.isDragging&&a.animationState?.setActive(`whileDrag`,!0);let s=n;if(!s||s.value!==t||s.to!==e.groupRef)return!1;let{keys:c,from:l,controls:u}=s,d=!s.element.isConnected;if(c){n=void 0;let{activeElement:e,body:t}=r.ownerDocument;return d&&(!e||e===t)&&(r.focus(),i(r,l)),!1}return!o||!u?.isDragging?!1:(Rn.read(()=>{if(n!==s)return;n=void 0,Fn.get(s.element)?.values.forEach((e,t)=>{let n=e.get();a.getValue(t,a.readValue(t,n))?.set(n)});let e=a.getTransformPagePoint()||(e=>e),t=e(s.centre),i=e(np(r));a.getValue(`x`).set(t.x-i.x),a.getValue(`y`).set(t.y-i.y),a.render(),d?u.cancel():u.stop(),o.start(s.event,{immediate:!0})}),d)},column:({groupRef:e})=>{let n=e.current,r=n=>[...t].some(t=>t.groupRef!==e&&n.contains(t.groupRef.current));for(;n?.parentElement?.parentElement&&!r(n.parentElement);)n=n.parentElement;return n}}}function op({children:e,...t}){let n=(0,K.useRef)(t);return Ln(()=>{n.current=t}),(0,G.jsx)(Of.Provider,{value:jn(()=>ap(n)),children:e})}var sp=(e,t,n)=>{let[r,i]=(0,K.useState)(!1),a=typeof t==`object`&&t.tooltipWhenOverflow;return(0,K.useEffect)(()=>{if(!a)return;let n=()=>{let n=e.current;if(!n)return;let r=typeof t==`object`?t.rows:void 0;i(r&&r>1?n.scrollHeight>n.clientHeight:n.scrollWidth>n.clientWidth)};n();let r=new ResizeObserver(n);return e.current&&r.observe(e.current),()=>r.disconnect()},[a,t,n,e]),r},cp=It({block:`text`,dataAttributes:[`type`],elements:[]}),lp={code:{kMv6JI:`lb2xbw48`,$$css:!0},danger:{kMwMTN:`lb12ap7uz`,$$css:!0},delete:{kybGjl:`lbmqliwb`,$$css:!0},disabled:{kMwMTN:`lbv7q1j6`,kkrTdU:`lb1h6gzvc`,$$css:!0},ellipsis:{kVQacm:`lbb3r6kr`,kg5iWk:`lblyipyv`,khDVqt:`lbuxw1ft`,$$css:!0},ellipsisMulti:{kVQacm:`lbb3r6kr`,kgKLqz:`lb1ua5tub`,k1xSpc:`lb104kibb`,kg5iWk:`lblyipyv`,$$css:!0},h1:{kGuDYH:`lb1xiv2dn`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h2:{kGuDYH:`lb2ziyne`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h3:{kGuDYH:`lbowuowh`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h4:{kGuDYH:`lbkf6u7v`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h5:{kGuDYH:`lb1pzwcx8`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},info:{kMwMTN:`lbapv1it`,$$css:!0},italic:{kKX8nH:`lb1k4tb9n`,$$css:!0},mark:{kWkggS:`lb10l2l1g`,kMwMTN:`lbod0wng`,$$css:!0},p:{kqGvvJ:`lb10im51j`,$$css:!0},secondary:{kMwMTN:`lb19ppog9`,$$css:!0},shiny:{"--shiny-color":`lb1yqjya6`,"--shiny-duration":`lb13qpc1j`,k44tkh:`lbpzn028`,ko0y90:`lba4qsjk`,kKVMdj:`lbj1bqtc`,kyAemX:`lb1esw782`,kHypHr:`lb1ta4xzc`,kKwaWg:`lb1k0woq6`,kgSjnq:`lbakli9p`,kMwMTN:`lb1g83pbf`,kfSwDN:`lb87ps6o`,$$css:!0},strong:{k63SB2:`lb117nqv4`,$$css:!0},success:{kMwMTN:`lbs9y9h1`,$$css:!0},text:{kMwMTN:`lb66ogz0`,$$css:!0},underline:{kybGjl:`lb1bvjpef`,$$css:!0},warning:{kMwMTN:`lbgyvj36`,$$css:!0}};({className:`lb2xbw48`}).className,{className:`lb12ap7uz`}.className,{className:`lbmqliwb`}.className,{className:`lbv7q1j6 lb1h6gzvc`}.className,{className:`lbb3r6kr lblyipyv lbuxw1ft`}.className,{className:`lbb3r6kr lb1ua5tub lb104kibb lblyipyv`}.className,{className:`lb1xiv2dn lb117nqv4 lb132q4wb`}.className,{className:`lb2ziyne lb117nqv4 lb132q4wb`}.className,{className:`lbowuowh lb117nqv4 lb132q4wb`}.className,{className:`lbkf6u7v lb117nqv4 lb132q4wb`}.className,{className:`lb1pzwcx8 lb117nqv4 lb132q4wb`}.className,{className:`lbapv1it`}.className,{className:`lb1k4tb9n`}.className,{className:`lb10l2l1g lbod0wng`}.className,{className:`lb10im51j`}.className,{className:`lb19ppog9`}.className,{className:`lb117nqv4`}.className,{className:`lbs9y9h1`}.className,{className:`lb66ogz0`}.className,{className:`lb1bvjpef`}.className,{className:`lbgyvj36`}.className,V((e=>B(e).className)(lp.shiny),`lobe-text-shiny`);var up=(e={})=>[lp.text,e.as&&lp[e.as],e.code&&lp.code,e.delete&&lp.delete,e.disabled&&lp.disabled,e.ellipsis===`multi`&&lp.ellipsisMulti,e.ellipsis===!0&&lp.ellipsis,e.italic&&lp.italic,e.mark&&lp.mark,e.shiny&&lp.shiny,e.strong&&lp.strong,e.type&&lp[e.type],e.underline&&lp.underline],dp=(0,K.memo)(({align:e,as:t=`div`,children:n,className:r,classNames:i,code:a,color:o,delete:s,disabled:c,ellipsis:l,fontSize:u,italic:d,lineClamp:f,lineHeight:p,mark:m,noWrap:h,ref:g,shiny:_,shinyDuration:v,strong:y,style:b,styles:x,textDecoration:S,textTransform:C,type:w,underline:T,weight:E,whiteSpace:D,wordBreak:O,...k})=>{let A=(0,K.useRef)(null),j=sp(A,l,n),ee=typeof l==`object`&&!!l.rows&&l.rows>1,M=typeof l==`object`&&l.tooltipWhenOverflow,te=e=>{A.current=e,typeof g==`function`?g(e):g&&(g.current=e)},N={...o&&{color:o},...E&&{fontWeight:E},...p&&{lineHeight:p},...C&&{textTransform:C},...S&&{textDecoration:S},...O&&{wordBreak:O},...typeof l==`object`&&l.rows&&{WebkitLineClamp:l.rows},...!l&&!!f&&{WebkitBoxOrient:`vertical`,WebkitLineClamp:f,display:`-webkit-box`,overflow:`hidden`,textOverflow:`ellipsis`},..._&&v&&{"--shiny-duration":v},...u&&{fontSize:u},...e&&{textAlign:e},...!ee&&h&&{whiteSpace:`nowrap`},...D&&{whiteSpace:D},...b,...x?.root},P=(0,G.jsx)(t,{...Ft({type:w}),...k,ref:te,style:N,className:B(up({as:[`h1`,`h2`,`h3`,`h4`,`h5`,`p`].includes(t)?t:void 0,code:a,delete:s,disabled:c,ellipsis:l?typeof l==`object`&&l.rows?`multi`:!0:void 0,italic:d,mark:m,shiny:_,strong:y,type:w,underline:T}),V(cp(),_&&`lobe-text-shiny`,r,i?.root)).className,children:n});if(l&&typeof l==`object`&&(l.tooltip||l.tooltipWhenOverflow)){if(M&&!j)return P;let e=typeof l.tooltip==`string`?l.tooltip:n;return l.tooltip&&typeof l.tooltip==`object`?(0,G.jsx)(Do,{...l.tooltip,title:l.tooltip?.title||e,children:P}):(0,G.jsx)(Do,{title:e,children:P})}return P});dp.displayName=`Text`;var fp=dp,pp=e=>{e.stopPropagation()},mp=e=>{e.preventDefault(),e.stopPropagation(),e.preventBaseUIHandler?.()},hp=K.createContext({disabled:!1});function gp(){return K.useContext(hp)}function _p(e){let[t,n]=K.useState({getBoundingClientRect(){return DOMRect.fromRect({width:0,height:0,x:0,y:0})}}),r=K.useRef(null),i=K.useRef(null),a=K.useRef(null),o=K.useRef(null),s=K.useRef(!0),c=K.useRef(null),l=vt(),u=K.useMemo(()=>({anchor:t,setAnchor:n,actionsRef:a,backdropRef:r,internalBackdropRef:i,positionerRef:o,allowMouseUpTriggerRef:s,initialCursorPointRef:c,rootId:l}),[t,l]);return(0,G.jsx)(Vo.Provider,{value:u,children:(0,G.jsx)(Oo.Provider,{value:void 0,children:(0,G.jsx)(ko,{...e})})})}var vp=Ro,Y=It({block:`context-menu`,elements:[`trigger`,`positioner`,`header`,`viewport`,`footer`,`item`,`item-content`,`icon`,`label-group`,`label`,`desc`,`extra`,`submenu-arrow`,`checkbox-indicator`,`switch`,`separator`,`group`,`group-label`]}),yp=(0,K.memo)(({collisionPadding:e,style:t,...n})=>{let r=typeof t!=`function`&&t?.zIndex!=null&&typeof t.zIndex==`number`?t.zIndex:void 0,{zIndex:i,ref:a}=Nt(`floating`,r),o=typeof t==`function`?e=>({zIndex:i,...t(e)}):{zIndex:i,...t};return(0,G.jsx)(vp,{...n,className:V(R.positioner,Y(`positioner`)),collisionPadding:e??C(),ref:a,style:o})});yp.displayName=`ContextMenuSubmenuPositioner`;var bp=(0,K.memo)(()=>{let{t:e}=qt(ne);return(0,G.jsx)(Bo,{disabled:!0,className:V(z(L.item,L.empty).className,Y(`item`)),children:(0,G.jsx)(`div`,{className:V(R.itemContent,Y(`item-content`)),children:(0,G.jsx)(`span`,{className:V(R.label,Y(`label`)),children:e(`common.empty`)})})})});bp.displayName=`EmptyMenuItem`;var xp=({checked:e,children:t,closeOnClick:n=!1,danger:r,defaultChecked:i,disabled:a,label:o,onCheckedChange:s})=>{let[c,l]=(0,K.useState)(i??!1),u=e!==void 0,d=u?e:c,f=(0,K.useCallback)(e=>{u||l(e),s?.(e)},[u,s]);return(0,G.jsxs)(Bo,{closeOnClick:n,disabled:a,label:o,className:V(z(L.item,r&&L.danger).className,Y(`item`)),onClick:e=>{e.preventDefault(),a||f(!d)},children:[t,(0,G.jsx)(`span`,{className:V(R.switchWrap,Y(`switch`)),onFocus:e=>e.stopPropagation(),children:(0,G.jsx)(We,{checked:d,disabled:a,size:`small`,tabIndex:-1,onChange:f,onClick:(e,t)=>t.stopPropagation()})})]})},Sp=(e,t,n)=>{let r=zt(e),i=`desc`in e?e.desc:void 0,a=`extra`in e?e.extra:void 0,o=t?.indicatorOnRight,s=!!i&&t?.iconAlign===`start`,c=n!==void 0&&!o,l=c?!!n:!!e.icon,u=c?!!(t?.reserveIconSpace||n):!!(l||t?.reserveIconSpace),d=i?(0,G.jsxs)(`div`,{className:V(R.labelGroup,Y(`label-group`)),children:[(0,G.jsx)(`span`,{className:V(R.label,Y(`label`)),children:r}),(0,G.jsx)(`span`,{className:V(R.desc,Y(`desc`)),children:i})]}):(0,G.jsx)(`span`,{className:V(R.label,Y(`label`)),children:r});return(0,G.jsxs)(`div`,{className:V(z(L.itemContent,s&&L.itemContentAlignStart).className,Y(`item-content`)),children:[u?(0,G.jsx)(`span`,{"aria-hidden":!l,className:V(z(L.icon,s&&L.iconAlignStart).className,Je.icon,Y(`icon`)),children:c?n:l?Wt(e.icon,`small`):null}):null,d,a?(0,G.jsx)(`span`,{className:V(R.extra,Y(`extra`)),children:a}):null,o&&n?n:null,t?.submenu?(0,G.jsx)(`span`,{className:V(R.submenuArrow,Y(`submenu-arrow`)),children:(0,G.jsx)(Vt,{})}):null]})},Cp=(e,t,n)=>{if(!e.onClick)return;let r=e.key??t.at(-1)??``,i={domEvent:n,item:n.currentTarget,key:String(r),keyPath:t};e.onClick(i)},wp=(e,t=[],n)=>{let r=n?.iconAlign,i=n?.iconSpaceMode??`global`,a=n?.reserveIconSpace??Rt(e,i===`global`),o=n?.indicatorOnRight??Ht(e);return e.map((e,n)=>{if(!e)return null;let s=`${t.join(`-`)||`root`}-${n}`,c=Ut(e,s),l=[...t,String(c)];if(e.type===`checkbox`){let t=e,n=zt(t),i=typeof n==`string`?n:void 0,s=!!t.danger,l=(0,G.jsx)(Io,{className:Y(`checkbox-indicator`),children:(0,G.jsx)(St,{icon:j,size:`small`})});return(0,G.jsx)(No,{checked:t.checked,closeOnClick:t.closeOnClick,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,className:V(z(L.item,s&&L.danger).className,Y(`item`)),onCheckedChange:e=>t.onCheckedChange?.(e),children:Sp(t,{iconAlign:r,indicatorOnRight:o,reserveIconSpace:a},l)},c)}if(e.type===`switch`){let t=e,n=zt(t),i=typeof n==`string`?n:void 0,o=!!t.danger;return(0,G.jsx)(xp,{checked:t.checked,closeOnClick:t.closeOnClick,danger:o,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,onCheckedChange:t.onCheckedChange,children:Sp(t,{iconAlign:r,reserveIconSpace:a})},c)}if(e.type===`divider`)return(0,G.jsx)(Lo,{className:V(R.separator,Y(`separator`))},c);if(e.type===`group`){let t=e,n=i===`group`?t.children?Rt(t.children):!1:a,o=t.children?Ht(t.children):!1;return(0,G.jsxs)(Mo,{className:Y(`group`),children:[t.label?(0,G.jsx)(jo,{className:V(R.groupLabel,Y(`group-label`)),children:t.label}):null,t.children?wp(t.children,l,{iconAlign:r,iconSpaceMode:i,indicatorOnRight:o,reserveIconSpace:n}):null]},c)}if(e.type===`submenu`||`children`in e&&e.children){let t=e,n=zt(t),o=typeof n==`string`?n:void 0,s=`danger`in t&&!!t.danger,u=t.header!=null||t.footer!=null,d=t.children&&t.children.length>0?wp(t.children,l,{iconAlign:r,iconSpaceMode:i}):(0,G.jsx)(bp,{});return(0,G.jsxs)(Po,{defaultOpen:t.defaultOpen,open:t.open,onOpenChange:t.onOpenChange,children:[(0,G.jsx)(zo,{...t.triggerProps,closeDelay:t.closeDelay,delay:t.delay,disabled:t.disabled,label:o,openOnHover:t.openOnHover,className:V(z(L.item,s&&L.danger).className,Y(`item`)),onClick:t.onClick,children:Sp(t,{iconAlign:r,reserveIconSpace:a,submenu:!0})}),(0,G.jsx)(Ao,{children:(0,G.jsx)(yp,{alignOffset:-4,"data-submenu":``,sideOffset:-1,onContextMenu:mp,children:(0,G.jsxs)(Fo,{className:V(z(L.popup,u&&L.popupWithSlots).className,Je.popup,Y()),children:[t.header==null?null:(0,G.jsx)(`div`,{className:V(R.header,Y(`header`)),children:t.header}),u?(0,G.jsx)(`div`,{className:V(R.slotViewport,Y(`viewport`)),children:d}):d,t.footer==null?null:(0,G.jsx)(`div`,{className:V(R.footer,Y(`footer`)),children:t.footer})]})})})]},c)}let u=e,d=zt(u),f=typeof d==`string`?d:void 0,p=`danger`in u&&!!u.danger;return(0,G.jsx)(Bo,{closeOnClick:u.closeOnClick,disabled:u.disabled,label:f,className:V(z(L.item,p&&L.danger).className,Y(`item`)),onClick:e=>Cp(u,l,e),children:Sp(u,{iconAlign:r,reserveIconSpace:a})},c)})},Tp={"--lobe-dropdown-animation-duration":`0ms`},Ep=(0,K.memo)(()=>{let e=Ie(),t=kt(),n=(0,K.useSyncExternalStore)($t,en,Qt);(0,K.useEffect)(()=>{},[e]),(0,K.useEffect)(()=>{let e=e=>tn(e);return window.addEventListener(`pointerdown`,e,!0),window.addEventListener(`contextmenu`,e,!0),()=>{window.removeEventListener(`pointerdown`,e,!0),window.removeEventListener(`contextmenu`,e,!0)}},[]);let r=(0,K.useMemo)(()=>wp(n.items,[],{iconAlign:n.iconAlign,iconSpaceMode:n.iconSpaceMode}),[n.items,n.iconAlign,n.iconSpaceMode]),{zIndex:i,ref:a}=Nt(`floating`),o=n.header!=null||n.footer!=null;return!e||!n.open&&n.items.length===0?null:(0,G.jsx)(_p,{open:n.open,onOpenChange:e=>{e?Zt({open:e}):nn()},children:(0,G.jsx)(Ao,{container:t,children:(0,G.jsx)(vp,{anchor:n.anchor??void 0,className:V(R.positioner,Y(`positioner`)),collisionPadding:C(),ref:a,sideOffset:6,style:{...Tp,zIndex:i},children:(0,G.jsxs)(Fo,{"data-has-footer":n.footer==null?void 0:``,"data-has-header":n.header==null?void 0:``,className:V(z(L.popup,o&&L.popupWithSlots).className,Je.popup,Y()),onContextMenu:mp,children:[n.header==null?null:(0,G.jsx)(`div`,{className:V(R.header,Y(`header`)),children:n.header}),n.virtual?(0,G.jsx)(Bt,{className:Y(`viewport`),itemSize:n.listItemHeight,children:r}):o?(0,G.jsx)(`div`,{className:V(R.slotViewport,Y(`viewport`)),children:r}):r,n.footer==null?null:(0,G.jsx)(`div`,{className:V(R.footer,Y(`footer`)),children:n.footer})]})})})})});Ep.displayName=`ContextMenuHost`;var Dp={circle:{kaIpWk:`lb16rqkct`,$$css:!0},defaultSize:{kZKoxP:`lblup9mm`,kzqmXN:`lb1kky2od`,$$css:!0},defaultSquare:{kaIpWk:`lb12oqio5`,$$css:!0},group:{kOIVth:`lb1v2ro7d`,k1xSpc:`lb78zum5`,kXwgrk:`lb1q0g3np`,kwnvtZ:`lb1a02dak`,$$css:!0},groupVertical:{kXwgrk:`lbdt5ytf`,$$css:!0},iconCircle:{k3aq6I:`lb10078c2`,$$css:!0},iconSquare:{k3aq6I:`lb1nrvvgt`,$$css:!0},indicator:{kGNEyG:`lb6s0dn4`,k1xSpc:`lb78zum5`,kjj79g:`lbl56j7k`,$$css:!0},label:{kOIVth:`lb167g77z`,kGNEyG:`lb6s0dn4`,kkrTdU:`lb1ypdohk lb1r4mgf1`,k1xSpc:`lb3nfvp2`,kfSwDN:`lb87ps6o`,$$css:!0},root:{kogj98:`lb1ghz6dp`,kmVPX3:`lb1717udv`,kVAM5u:`lb1ri2ox9 lb10cypdb lb18hgaxl lb14dg99k`,ksu8eU:`lb1y0btm7`,kMzoRj:`lbmkeg23`,kUk6DE:`lb1okw0bk`,kI3sdo:`lb1a2a7pz`,kmkexE:`lb1mlet35`,kGNEyG:`lb6s0dn4`,kWkggS:`lbpbwnwz lb6yijhg lb1ppu4m2`,kMwMTN:`lb15g0kca lbcdmxi5`,kkrTdU:`lb1ypdohk lb5ezrf1`,k1xSpc:`lb3nfvp2`,kjj79g:`lbl56j7k`,kSiTet:`lb12zwbr1`,$$css:!0}};({className:`lb16rqkct`}).className,{className:`lblup9mm lb1kky2od`}.className,{className:`lb12oqio5`}.className,{className:`lb1v2ro7d lb78zum5 lb1q0g3np lb1a02dak`}.className,{className:`lbdt5ytf`}.className,{className:`lb10078c2`}.className,{className:`lb1nrvvgt`}.className,{className:`lb6s0dn4 lb78zum5 lbl56j7k`}.className,{className:`lb167g77z lb6s0dn4 lb1ypdohk lb1r4mgf1 lb3nfvp2 lb87ps6o`}.className,{className:`lb1ghz6dp lb1717udv lb1ri2ox9 lb10cypdb lb18hgaxl lb14dg99k lb1y0btm7 lbmkeg23 lb1okw0bk lb1a2a7pz lb1mlet35 lb6s0dn4 lbpbwnwz lb6yijhg lb1ppu4m2 lb15g0kca lbcdmxi5 lb1ypdohk lb5ezrf1 lb3nfvp2 lbl56j7k lb12zwbr1`}.className;function Op(e){if(!e)return null;for(let t of e.elements){let e=t.tagName;if(e===`BUTTON`||e===`INPUT`){let e=t;if(e.type===`submit`)return e}}return null}var kp=`data-checked`,Ap=`data-unchecked`;function jp(e){return{checked(t){return e.indeterminate?{}:t?{[kp]:``}:{[Ap]:``}},...Pe}}var Mp=K.createContext(void 0);function Np(){return K.useContext(Mp)}var Pp=K.createContext(void 0);function Fp(){let e=K.useContext(Pp);if(e===void 0)throw Error(Tt(14));return e}var Ip=`data-parent`,Lp=K.forwardRef(function(e,t){let{checked:n,className:r,defaultChecked:i=!1,"aria-labelledby":a,disabled:o=!1,form:s,id:c,indeterminate:l=!1,inputRef:u,name:d,onCheckedChange:f,parent:p=!1,readOnly:m=!1,render:h,required:g=!1,uncheckedValue:_,value:v,nativeButton:y=!1,style:b,...x}=e,{clearErrors:S}=ve(),{disabled:C,name:w,setDirty:T,setFilled:E,setTouched:D,state:O,validationMode:k,validityData:A,validation:j}=Xe(),ee=gp(),{labelId:M,registerControlId:te,getDescriptionProps:N}=be(),P=Np(),ne=P?.allValues===void 0?void 0:P.parent,ie=ne!==void 0,F=C||ee.disabled||P?.disabled||o,ae=w??d,I=v??ae,oe=wt(),se=P?.registerControlId!==te,ce=re({id:c||void 0,enabled:se}),ue=y?ce:oe,de={};ie&&(p?de=ne.getParentProps():I!==void 0&&(de=ne.getChildProps(I)));let{checked:fe=n,indeterminate:pe=l,onCheckedChange:me,...he}=de,ge=P?.value,_e=K.useRef(null),ye=le(F,_e),{getButtonProps:Se,buttonRef:Ce}=xt({disabled:F,native:y}),L=P?.validation??j,[we,Te]=ze({controlled:I!==void 0&&ge!==void 0&&!p?ge.includes(I):fe,default:i,name:`Checkbox`,state:`checked`}),Ee=ie?!!fe:we,De=ie&&pe||l;xe(_e,oe,we,void 0,!P&&!F,d);let Oe=ne?.registerChildId,ke=K.useRef(null),Ae=L.registerInput,je=P?I:void 0,Me=K.useCallback(e=>Ae(e,{controlRef:_e,value:je}),[Ae,je]),Ne=Et(u,ke,p?void 0:Me),Pe=qe(a,M,ke,!y,ce,x[`aria-label`]);Dt(()=>{ke.current&&(ke.current.indeterminate=De),P||E(we)},[we,De,P,E]),it(we,()=>{P||(S(ae),T(we!==A.initialValue),L.change(we))});let R=bt({checked:we,disabled:F,form:s,name:p?void 0:ae,id:y?void 0:ce,required:g,ref:Ne,style:ae?yt:gt,tabIndex:-1,type:`checkbox`,"aria-hidden":!0,onChange(e){if(e.nativeEvent.defaultPrevented)return;if(m){e.preventDefault();return}let t=e.currentTarget.checked,n=Pt(Ot,e.nativeEvent);if(f?.(t,n),!n.isCanceled&&(me?.(t,n),!n.isCanceled&&(Te(t),I!==void 0&&P!==void 0&&!p&&!ie))){let e=t?[...P.value,I]:P.value.filter(e=>e!==I);P.setValue(e,n)}},onClick(e){e.stopPropagation()},onFocus(){_e.current?.focus()}},v===void 0?dt:{value:(P?we&&v:v)||``},N,e=>L.getValidationProps(F,e));K.useEffect(()=>{if(!ne||I===void 0)return;let e=ne.disabledStatesRef.current;return e.set(I,F),()=>{e.delete(I)}},[ne,F,I]);let Fe=K.useMemo(()=>({...O,checked:Ee,disabled:F,readOnly:m,required:g,indeterminate:De}),[O,Ee,F,m,g,De]),Ie=jp(Fe),Le=_t(`span`,e,{state:Fe,ref:[Ce,_e,t],props:[{id:ue,role:`checkbox`,"aria-checked":De?`mixed`:Ee,"aria-readonly":m||void 0,"aria-required":g||void 0,"aria-labelledby":Pe,[Ip]:p?``:void 0,onFocus(){ye(!0)},onBlur(){let e=ke.current;e&&(D(!0),ye(!1),k===`onBlur`&&L.commit(P?ge:e.checked))},onKeyDown(e){if(e.key!==`Enter`||(e.preventBaseUIHandler(),e.defaultPrevented))return;let t=ke.current?.form??null,n=e.currentTarget,r=e.nativeEvent,i=e.preventDefault,a=r.preventDefault,o=!1;e.preventDefault=()=>{o=!0,i.call(e)},r.preventDefault=()=>{o=!0,a.call(r)},a.call(r),jt(n).queueMicrotask(()=>{e.preventDefault=i,r.preventDefault=a,o||Op(t)?.click()})},onClick(e){if(m||F)return;e.preventDefault();let t=ke.current;t&&ht(t,e)}},x,he,Se,N,e=>L.getValidationProps(F,e)],stateAttributesMapping:Ie}),Re=Le.props.id;return Dt(()=>{if(Oe&&!p&&I!==void 0&&Re!==void 0)return Oe(I,Re)},[Oe,p,I,Re]),(0,G.jsxs)(Pp.Provider,{value:Fe,children:[Le,!we&&!P&&ae&&!p&&_!==void 0&&(0,G.jsx)(`input`,{type:`hidden`,form:s,name:ae,value:_,disabled:F}),(0,G.jsx)(`input`,{...R,suppressHydrationWarning:!0})]})}),Rp=K.forwardRef(function(e,t){let{render:n,className:r,style:i,keepMounted:a=!1,...o}=e,s=Fp(),c=s.checked||s.indeterminate,{mounted:l,transitionStatus:u,setMounted:d}=At(c),f=K.useRef(null),p={...s,transitionStatus:u};pt({batch:!0,enabled:!c,open:c,ref:f,onComplete(){c||d(!1)}});let m={...jp(s),...Mt},h=a||l,g=_t(`span`,e,{ref:[t,f],state:p,stateAttributesMapping:m,props:o});return h?g:null}),zp=It({block:`checkbox`,dataAttributes:[`shape`],elements:[`checkbox`,`indicator`,`text`]});It({block:`checkbox-group`,dataAttributes:[`horizontal`],elements:[`item`]});var Bp=(0,K.memo)(({size:e,shape:t=`square`,backgroundColor:n,children:r,className:i,classNames:a,styles:o,style:s,textProps:c,onChange:l,disabled:u,indeterminate:d,...f})=>{let p=e??16,m=e!==void 0,h={...m&&{height:p,width:p},...m&&t===`square`&&{borderRadius:`max(4px, ${Math.round(p/4)}px)`},...n?{"--lobe-checkbox-bg":n}:{},...r?{}:s,...o?.checkbox},g=t===`square`?Dp.iconSquare:Dp.iconCircle,_=(0,G.jsx)(Lp,{disabled:u,indeterminate:d,onCheckedChange:l,...r?void 0:Ft({shape:t}),...f,...B([Dp.root,Ct.info,!m&&Dp.defaultSize,t===`square`?!m&&Dp.defaultSquare:Dp.circle],V(!r&&zp(),zp(`checkbox`),r?a?.checkbox:i,a?.checkbox),h),children:(0,G.jsx)(Rp,{...B(Dp.indicator,zp(`indicator`)),children:d?(0,G.jsx)(Ge,{size:p,strokeWidth:3,...z(g)}):(0,G.jsx)(j,{size:p,strokeWidth:3,...z(g)})})});return r?(0,G.jsxs)(`label`,{...Ft({shape:t}),...B(Dp.label,V(zp(),i,a?.wrapper),{...m&&{gap:Math.floor(p/2)},...s,...o?.wrapper}),children:[_,(0,G.jsx)(fp,{as:`span`,className:V(zp(`text`),a?.text),style:o?.text,...c,type:u?`secondary`:c?.type,children:r})]}):_});Bp.displayName=`Checkbox`;var Vp=Object.assign(Bp,{formBinding:{valueProp:`checked`}}),X={glyph:{k1xSpc:`lb3nfvp2`,$$css:!0},glyphBox:{k1xSpc:`lb3nfvp2`,$$css:!0},network:{k1xSpc:`lb1rg5ohu`,kVAEAm:`lb1n2onr6`,$$css:!0},networkBox:{k87sOh:`lb13vifvy`,kLqNvP:`lb1o0tod`,kVAEAm:`lb10l6tqk`,k3nNDw:`lb1hj3fc7`,kZKoxP:`lbpyat2d`,kzqmXN:`lb1exxlbk`,$$css:!0},networkCore:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1ygz6qe lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kWkggS:`lb1h45990`,k87sOh:`lbyszfof`,kLqNvP:`lb4500kp`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbols6we`,kzqmXN:`lb1v4s8kt`,$$css:!0},networkLine:{kjVXCG:`lb68wf4t`,kfJifR:`lbpmuf5a`,kSiTet:`lbuzhngd`,$$css:!0},networkLines:{kpwlN0:`lb10a8y8t`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbpyat2d`,kzqmXN:`lb1exxlbk`,$$css:!0},networkNode:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1mw1q8i lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kogj98:`lbzvvh78`,kaIpWk:`lb16rqkct`,kWkggS:`lb1h45990`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbxdy7cf`,kzqmXN:`lb165gwbr`,$$css:!0},networkParticle:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb15d5rfv lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kogj98:`lb1rmkima`,kaIpWk:`lb16rqkct`,kWkggS:`lb1h45990`,k87sOh:`lbbssg55`,kLqNvP:`lbemjqv4`,kVAEAm:`lb10l6tqk`,kZKoxP:`lb11vverv`,kzqmXN:`lbsblaa2`,$$css:!0},networkRing:{k44tkh:`lb6q96wx lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1v0ides lb1aquc0h`,kyAemX:`lb1esw782 lb1uea3p4`,kpwlN0:`lb1vdmwfg`,kVAM5u:`lb181nr7w`,kaIpWk:`lb16rqkct`,ksu8eU:`lbbsl7fq`,kMzoRj:`lbmkeg23`,kSiTet:`lbti2d7y`,kVAEAm:`lb10l6tqk`,$$css:!0},overlay:{kpwlN0:`lb10a8y8t`,kOIVth:`lb167g77z`,kGNEyG:`lb6s0dn4`,kWkggS:`lb1c0b5dz`,kMwMTN:`lbc77et8`,k1xSpc:`lb78zum5`,kXwgrk:`lbdt5ytf`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,$$css:!0},ring:{k4XH5M:`lbwsa1kb`,$$css:!0},ringProgress:{kjVXCG:`lb1q6ff6i`,$$css:!0},ringTrack:{kjVXCG:`lb12pnydc`,$$css:!0},root:{kGNEyG:`lb6s0dn4`,kMwMTN:`lbc77et8`,k1xSpc:`lb3nfvp2`,$$css:!0},tip:{kMwMTN:`lbc77et8`,kGuDYH:`lbxobqjj`,$$css:!0},wrapper:{kVAEAm:`lb1n2onr6`,$$css:!0}},Hp=[0,1,2],Up=25,Wp=Hp.flatMap(e=>Hp.map(t=>({x:Up+e*Up,y:Up+t*Up}))),Gp=Hp.slice(0,-1).flatMap(e=>Hp.flatMap(t=>Hp.map(n=>({x1:Up+e*Up,x2:Up+(e+1)*Up,y1:Up+t*Up,y2:Up+n*Up})))),Kp=[0,1,2],qp=(e,t,n)=>Math.max(e,n*100/t),Jp=(0,K.memo)(({px:e})=>{let t={"--spin-node-size":`${qp(6,e,2)}px`,"--spin-particle-size":`${qp(3,e,1.5)}px`,transform:`scale(${e/100})`};return(0,G.jsx)(`span`,{...z(X.network),style:{height:e,width:e},children:(0,G.jsxs)(`span`,{...z(X.networkBox),style:t,children:[(0,G.jsx)(`svg`,{...z(X.networkLines),viewBox:`0 0 100 100`,children:Gp.map(e=>(0,G.jsx)(`line`,{...e,...z(X.networkLine)},`${e.x1}-${e.y1}-${e.y2}`))}),Wp.map(({x:e,y:t},n)=>(0,G.jsx)(`i`,{...z(X.networkNode),style:{animationDelay:`${n*.2}s`,left:e,top:t}},`${e}-${t}`)),Kp.map(e=>(0,G.jsx)(`i`,{...z(X.networkParticle),style:{animationDelay:`${e*.6}s`}},e)),(0,G.jsx)(`b`,{...z(X.networkCore)}),(0,G.jsx)(`u`,{...z(X.networkRing)})]})})});Jp.displayName=`NetworkGlyph`;var Yp=It({block:`spin`,dataAttributes:[`size`,`variant`],elements:[`indicator`,`overlay`,`tip`]}),Xp={large:32,middle:20,small:14},Zp=e=>typeof e==`number`?e:Xp[e],Qp=(0,K.memo)(({children:e,className:t,indicator:n,percent:r,ref:i,size:a=`middle`,spinning:o=!0,style:s,tip:c,variant:l=`default`,...u})=>{let d=(0,K.useMemo)(()=>Zp(a),[a]),f=(0,K.useMemo)(()=>{if(n)return n;if(l===`network`)return(0,G.jsx)(Jp,{px:d});if(typeof r==`number`){let e=Math.min(100,Math.max(0,r)),t=2*Math.PI*9,n=t*(1-e/100);return(0,G.jsxs)(`svg`,{...z(X.glyph,X.ring),height:d,viewBox:`0 0 24 24`,width:d,children:[(0,G.jsx)(`circle`,{...z(X.ringTrack),cx:12,cy:12,fill:`none`,r:9,strokeWidth:2.5}),(0,G.jsx)(`circle`,{...z(X.ringProgress),cx:12,cy:12,fill:`none`,r:9,strokeDasharray:t,strokeDashoffset:n,strokeLinecap:`round`,strokeWidth:2.5})]})}return(0,G.jsx)(St,{spin:!0,...z(X.glyph),icon:He,size:d})},[n,l,r,d]);if(!o)return e??null;let p=Ft({size:typeof a==`string`?a:void 0,variant:l});return e?(0,G.jsxs)(`div`,{ref:i,...B(X.wrapper,V(Yp(),t),s),...p,...u,children:[e,(0,G.jsxs)(`div`,{"aria-busy":!0,"aria-live":`polite`,...B(X.overlay,Yp(`overlay`)),role:`status`,children:[(0,G.jsx)(`span`,{"aria-hidden":!0,...B(X.glyphBox,Yp(`indicator`)),children:f}),c&&(0,G.jsx)(`span`,{...B(X.tip,Yp(`tip`)),children:c})]})]}):(0,G.jsx)(`div`,{"aria-busy":!0,"aria-live":`polite`,ref:i,role:`status`,...B(X.root,V(Yp(),t),s),...p,...u,children:(0,G.jsx)(`span`,{"aria-hidden":!0,...B(X.glyphBox,Yp(`indicator`)),children:f})})});Qp.displayName=`Spin`;var $p=(e=>(e[e.Border=-1]=`Border`,e[e.Data=0]=`Data`,e[e.Function=1]=`Function`,e[e.Position=2]=`Position`,e[e.Timing=3]=`Timing`,e[e.Alignment=4]=`Alignment`,e))($p||{}),em=[0,1],tm=[1,0],nm=[2,3],rm=[3,2],im={L:em,M:tm,Q:nm,H:rm},am=/^\d*$/,om=/^[A-Z0-9 $%*+./:-]*$/,sm=`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:`,cm=1,lm=40,um=3,dm=3,fm=40,pm=10,mm=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],hm=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],gm=class{constructor(e,t,n,r){if(this.version=e,this.ecc=t,e<cm||e>lm)throw RangeError(`Version value out of range`);if(r<-1||r>7)throw RangeError(`Mask value out of range`);this.size=e*4+17;let i=Array.from({length:this.size}).fill(!1);for(let e=0;e<this.size;e++)this.modules.push(i.slice()),this.types.push(i.map(()=>0));this.drawFunctionPatterns();let a=this.addEccAndInterleave(n);if(this.drawCodewords(a),r===-1){let e=1e9;for(let t=0;t<8;t++){this.applyMask(t),this.drawFormatBits(t);let n=this.getPenaltyScore();n<e&&(r=t,e=n),this.applyMask(t)}}this.mask=r,this.applyMask(r),this.drawFormatBits(r)}size;mask;modules=[];types=[];getModule(e,t){return e>=0&&e<this.size&&t>=0&&t<this.size&&this.modules[t][e]}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0,$p.Timing),this.setFunctionModule(e,6,e%2==0,$p.Timing);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);let e=this.getAlignmentPatternPositions(),t=e.length;for(let n=0;n<t;n++)for(let r=0;r<t;r++)n===0&&r===0||n===0&&r===t-1||n===t-1&&r===0||this.drawAlignmentPattern(e[n],e[r]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(e){let t=this.ecc[1]<<3|e,n=t;for(let e=0;e<10;e++)n=n<<1^(n>>>9)*1335;let r=(t<<10|n)^21522;for(let e=0;e<=5;e++)this.setFunctionModule(8,e,vm(r,e));this.setFunctionModule(8,7,vm(r,6)),this.setFunctionModule(8,8,vm(r,7)),this.setFunctionModule(7,8,vm(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,vm(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,vm(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,vm(r,e));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let e=this.version;for(let t=0;t<12;t++)e=e<<1^(e>>>11)*7973;let t=this.version<<12|e;for(let e=0;e<18;e++){let n=vm(t,e),r=this.size-11+e%3,i=Math.floor(e/3);this.setFunctionModule(r,i,n),this.setFunctionModule(i,r,n)}}drawFinderPattern(e,t){for(let n=-4;n<=4;n++)for(let r=-4;r<=4;r++){let i=Math.max(Math.abs(r),Math.abs(n)),a=e+r,o=t+n;a>=0&&a<this.size&&o>=0&&o<this.size&&this.setFunctionModule(a,o,i!==2&&i!==4,$p.Position)}}drawAlignmentPattern(e,t){for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)this.setFunctionModule(e+r,t+n,Math.max(Math.abs(r),Math.abs(n))!==1,$p.Alignment)}setFunctionModule(e,t,n,r=$p.Function){this.modules[t][e]=n,this.types[t][e]=r}addEccAndInterleave(e){let t=this.version,n=this.ecc;if(e.length!==Nm(t,n))throw RangeError(`Invalid argument`);let r=hm[n[0]][t],i=mm[n[0]][t],a=Math.floor(Mm(t)/8),o=r-a%r,s=Math.floor(a/r),c=[],l=Pm(i);for(let t=0,n=0;t<r;t++){let r=e.slice(n,n+s-i+(t<o?0:1));n+=r.length;let a=Fm(r,l);t<o&&r.push(0),c.push(r.concat(a))}let u=[];for(let e=0;e<c[0].length;e++)c.forEach((t,n)=>{(e!==s-i||n>=o)&&u.push(t[e])});return u}drawCodewords(e){if(e.length!==Math.floor(Mm(this.version)/8))throw RangeError(`Invalid argument`);let t=0;for(let n=this.size-1;n>=1;n-=2){n===6&&(n=5);for(let r=0;r<this.size;r++)for(let i=0;i<2;i++){let a=n-i,o=n+1&2?r:this.size-1-r;!this.types[o][a]&&t<e.length*8&&(this.modules[o][a]=vm(e[t>>>3],7-(t&7)),t++)}}}applyMask(e){if(e<0||e>7)throw RangeError(`Mask value out of range`);for(let t=0;t<this.size;t++)for(let n=0;n<this.size;n++){let r;switch(e){case 0:r=(n+t)%2==0;break;case 1:r=t%2==0;break;case 2:r=n%3==0;break;case 3:r=(n+t)%3==0;break;case 4:r=(Math.floor(n/3)+Math.floor(t/2))%2==0;break;case 5:r=n*t%2+n*t%3==0;break;case 6:r=(n*t%2+n*t%3)%2==0;break;case 7:r=((n+t)%2+n*t%3)%2==0;break;default:throw Error(`Unreachable`)}!this.types[t][n]&&r&&(this.modules[t][n]=!this.modules[t][n])}}getPenaltyScore(){let e=0;for(let t=0;t<this.size;t++){let n=!1,r=0,i=[0,0,0,0,0,0,0];for(let a=0;a<this.size;a++)this.modules[t][a]===n?(r++,r===5?e+=um:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*fm),n=this.modules[t][a],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*fm}for(let t=0;t<this.size;t++){let n=!1,r=0,i=[0,0,0,0,0,0,0];for(let a=0;a<this.size;a++)this.modules[a][t]===n?(r++,r===5?e+=um:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*fm),n=this.modules[a][t],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*fm}for(let t=0;t<this.size-1;t++)for(let n=0;n<this.size-1;n++){let r=this.modules[t][n];r===this.modules[t][n+1]&&r===this.modules[t+1][n]&&r===this.modules[t+1][n+1]&&(e+=dm)}let t=0;for(let e of this.modules)t=e.reduce((e,t)=>e+ +!!t,t);let n=this.size*this.size,r=Math.ceil(Math.abs(t*20-n*10)/n)-1;return e+=r*pm,e}getAlignmentPatternPositions(){if(this.version===1)return[];{let e=Math.floor(this.version/7)+2,t=this.version===32?26:Math.ceil((this.version*4+4)/(e*2-2))*2,n=[6];for(let r=this.size-7;n.length<e;r-=t)n.splice(1,0,r);return n}}finderPenaltyCountPatterns(e){let t=e[1],n=t>0&&e[2]===t&&e[3]===t*3&&e[4]===t&&e[5]===t;return(n&&e[0]>=t*4&&e[6]>=t?1:0)+(n&&e[6]>=t*4&&e[0]>=t?1:0)}finderPenaltyTerminateAndCount(e,t,n){return e&&(this.finderPenaltyAddHistory(t,n),t=0),t+=this.size,this.finderPenaltyAddHistory(t,n),this.finderPenaltyCountPatterns(n)}finderPenaltyAddHistory(e,t){t[0]===0&&(e+=this.size),t.pop(),t.unshift(e)}};function _m(e,t,n){if(t<0||t>31||e>>>t)throw RangeError(`Value out of range`);for(let r=t-1;r>=0;r--)n.push(e>>>r&1)}function vm(e,t){return!!(e>>>t&1)}var ym=class{constructor(e,t,n){if(this.mode=e,this.numChars=t,this.bitData=n,t<0)throw RangeError(`Invalid argument`);this.bitData=n.slice()}getData(){return this.bitData.slice()}},bm=[1,10,12,14],xm=[2,9,11,13],Sm=[4,8,16,16];function Cm(e,t){return e[Math.floor((t+7)/17)+1]}function wm(e){let t=[];for(let n of e)_m(n,8,t);return new ym(Sm,e.length,t)}function Tm(e){if(!Om(e))throw RangeError(`String contains non-numeric characters`);let t=[];for(let n=0;n<e.length;){let r=Math.min(e.length-n,3);_m(Number.parseInt(e.substring(n,n+r),10),r*3+1,t),n+=r}return new ym(bm,e.length,t)}function Em(e){if(!km(e))throw RangeError(`String contains unencodable characters in alphanumeric mode`);let t=[],n=0;for(;n+2<=e.length;n+=2){let r=sm.indexOf(e.charAt(n))*45;r+=sm.indexOf(e.charAt(n+1)),_m(r,11,t)}return n<e.length&&_m(sm.indexOf(e.charAt(n)),6,t),new ym(xm,e.length,t)}function Dm(e){return e===``?[]:Om(e)?[Tm(e)]:km(e)?[Em(e)]:[wm(jm(e))]}function Om(e){return am.test(e)}function km(e){return om.test(e)}function Am(e,t){let n=0;for(let r of e){let e=Cm(r.mode,t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}function jm(e){e=encodeURI(e);let t=[];for(let n=0;n<e.length;n++)e.charAt(n)===`%`?(t.push(Number.parseInt(e.substring(n+1,n+3),16)),n+=2):t.push(e.charCodeAt(n));return t}function Mm(e){if(e<cm||e>lm)throw RangeError(`Version number out of range`);let t=(16*e+128)*e+64;if(e>=2){let n=Math.floor(e/7)+2;t-=(25*n-10)*n-55,e>=7&&(t-=36)}return t}function Nm(e,t){return Math.floor(Mm(e)/8)-mm[t[0]][e]*hm[t[0]][e]}function Pm(e){if(e<1||e>255)throw RangeError(`Degree out of range`);let t=[];for(let n=0;n<e-1;n++)t.push(0);t.push(1);let n=1;for(let r=0;r<e;r++){for(let e=0;e<t.length;e++)t[e]=Im(t[e],n),e+1<t.length&&(t[e]^=t[e+1]);n=Im(n,2)}return t}function Fm(e,t){let n=t.map(e=>0);for(let r of e){let e=r^n.shift();n.push(0),t.forEach((t,r)=>n[r]^=Im(t,e))}return n}function Im(e,t){if(e>>>8||t>>>8)throw RangeError(`Byte out of range`);let n=0;for(let r=7;r>=0;r--)n=n<<1^(n>>>7)*285,n^=(t>>>r&1)*e;return n}function Lm(e,t,n=1,r=40,i=-1,a=!0){if(!(cm<=n&&n<=r&&r<=lm)||i<-1||i>7)throw RangeError(`Invalid value`);let o,s;for(o=n;;o++){let n=Nm(o,t)*8,i=Am(e,o);if(i<=n){s=i;break}if(o>=r)throw RangeError(`Data too long`)}for(let e of[tm,nm,rm])a&&s<=Nm(o,e)*8&&(t=e);let c=[];for(let t of e){_m(t.mode[0],4,c),_m(t.numChars,Cm(t.mode,o),c);for(let e of t.getData())c.push(e)}let l=Nm(o,t)*8;_m(0,Math.min(4,l-c.length),c),_m(0,(8-c.length%8)%8,c);for(let e=236;c.length<l;e^=253)_m(e,8,c);let u=Array.from({length:Math.ceil(c.length/8)},()=>0);return c.forEach((e,t)=>u[t>>>3]|=e<<7-(t&7)),new gm(o,t,u,i)}function Rm(e,t){let{ecc:n=`L`,boostEcc:r=!1,minVersion:i=1,maxVersion:a=40,maskPattern:o=-1,border:s=1}=t||{},c=typeof e==`string`?Dm(e):Array.isArray(e)?[wm(e)]:void 0;if(!c)throw Error(`uqr only supports encoding string and binary data, but got: ${typeof e}`);let l=Lm(c,im[n],i,a,o,r),u=zm({version:l.version,maskPattern:l.mask,size:l.size,data:l.modules,types:l.types},s);return t?.invert&&(u.data=u.data.map(e=>e.map(e=>!e))),t?.onEncoded?.(u),u}function zm(e,t=1){if(!t)return e;let{size:n}=e,r=n+t*2;e.size=r,e.data.forEach(e=>{for(let n=0;n<t;n++)e.unshift(!1),e.push(!1)});for(let n=0;n<t;n++)e.data.unshift(Array.from({length:r},e=>!1)),e.data.push(Array.from({length:r},e=>!1));let i=$p.Border;e.types.forEach(e=>{for(let n=0;n<t;n++)e.unshift(i),e.push(i)});for(let n=0;n<t;n++)e.types.unshift(Array.from({length:r},e=>i)),e.types.push(Array.from({length:r},e=>i));return e}var Bm={"qrCode.expired":`Expired`,"qrCode.loading":`Loading`,"qrCode.refresh":`Refresh`},Vm=(e,t)=>{let n=e.length,r=Math.floor((n-t)/2),i=r+t,a=``;for(let o=0;o<n;o++)for(let s=0;s<n;s++)t>0&&s>=r&&s<i&&o>=r&&o<i||e[o][s]&&(a+=`M${s} ${o}h1v1h-1z`);return a},Hm=It({block:`qr-code`,dataAttributes:[`status`,`bordered`],elements:[`code`,`icon`,`overlay`,`title`,`refresh`]}),Um={bordered:{kGVxlE:`lbnug1en`,$$css:!0},icon:{kaIpWk:`lb16rqkct`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kGVxlE:`lbgffery`,k1xSpc:`lb78zum5`,k87sOh:`lbwa60dl`,kLqNvP:`lbbudbmw`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,k3aq6I:`lb11lhmoz`,$$css:!0},iconDefaultSize:{kZKoxP:`lb1iafx81`,kzqmXN:`lb1tzk97j`,$$css:!0},overlay:{kpwlN0:`lb10a8y8t`,kaIpWk:`lbgqmno8`,kOIVth:`lb1v2ro7d`,kGNEyG:`lb6s0dn4`,kWkggS:`lbsuhtdx`,kMwMTN:`lb1a94cpc`,k1xSpc:`lb78zum5`,kXwgrk:`lbdt5ytf`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,$$css:!0},overlayTitle:{kGuDYH:`lb19d36u7`,k63SB2:`lb1s688f`,$$css:!0},refresh:{kaIpWk:`lb1e6avla`,ksu8eU:`lbng3xce`,kMzoRj:`lbc342km`,kjAs5C:`lb1aazh3f`,kOIVth:`lb17d4w8g`,kg3NbH:`lbqin4a2`,kGNEyG:`lb6s0dn4`,kWkggS:`lb1qtvmyh`,kMwMTN:`lbfungia`,kkrTdU:`lb1ypdohk`,k1xSpc:`lb3nfvp2`,kMv6JI:`lbjb2p0i`,kGuDYH:`lb4z9k3i`,kQqvRs:`lb1xh6y1q`,kKX8nH:`lb1t35e8`,k63SB2:`lbk50ysn`,kjj79g:`lbl56j7k`,kLWn49:`lb15bjb6t`,kZKoxP:`lb10w6t97`,$$css:!0},root:{kmVPX3:`lb1tamke2`,kaIpWk:`lbgqmno8`,kWkggS:`lb83z2og`,k1xSpc:`lb3nfvp2`,kVAEAm:`lb1n2onr6`,$$css:!0},spin:{kMwMTN:`lb33gn0b`,$$css:!0}},Wm=.22,Gm=(0,K.memo)(({bgColor:e,bordered:t=!0,className:n,color:r=`#000`,errorLevel:i=`M`,icon:a,onRefresh:o,ref:s,size:c,status:l=`active`,style:u,value:d,...f})=>{let{t:p}=qt(Bm),m=c??160,{count:h,path:g}=(0,K.useMemo)(()=>{try{let{data:e}=Rm(d,{border:0,ecc:a?`H`:i}),t=a?Math.ceil(e.length*Wm)|1:0;return{count:e.length,path:Vm(e,t)}}catch{return{count:0,path:``}}},[d,a,i]);return(0,G.jsxs)(`div`,{ref:s,...B([Um.root,t&&Um.bordered],V(Hm(),n),e===void 0?u:{background:e,...u}),...Ft({bordered:t,status:l}),...f,children:[(0,G.jsxs)(`svg`,{"aria-label":d,className:Hm(`code`),height:m,role:`img`,shapeRendering:`crispEdges`,viewBox:`0 0 ${h} ${h}`,width:m,children:[(0,G.jsx)(`rect`,{fill:e??`#fff`,height:h,width:h}),(0,G.jsx)(`path`,{d:g,fill:r})]}),a&&(0,G.jsx)(`span`,{...B([Um.icon,c===void 0&&Um.iconDefaultSize],Hm(`icon`),c===void 0?void 0:{height:m*Wm,width:m*Wm}),children:a}),l===`loading`&&(0,G.jsx)(`span`,{"aria-label":p(`qrCode.loading`),...B(Um.overlay,Hm(`overlay`)),role:`status`,children:(0,G.jsx)(Qp,{className:B(Um.spin).className})}),l===`expired`&&(0,G.jsxs)(`span`,{...B(Um.overlay,Hm(`overlay`)),children:[(0,G.jsx)(`span`,{...B(Um.overlayTitle,Hm(`title`)),children:p(`qrCode.expired`)}),o&&(0,G.jsxs)(`button`,{...B([Ct.info,Um.refresh],Hm(`refresh`)),type:`button`,onClick:o,children:[(0,G.jsx)(St,{icon:rs,size:14}),p(`qrCode.refresh`)]})]})]})});Gm.displayName=`QRCode`;var Km=e({Board:()=>op,Group:()=>qm,Item:()=>ep}),qm=Vf(Gd),Jm=e({Reorder:()=>Km,a:()=>Ha,abbr:()=>ya,address:()=>Pa,animate:()=>ta,area:()=>Ti,article:()=>Ca,aside:()=>Ra,audio:()=>Mi,b:()=>da,base:()=>Ka,bdi:()=>Ii,bdo:()=>Ui,big:()=>Da,blockquote:()=>ha,body:()=>Zi,button:()=>qi,canvas:()=>xi,caption:()=>Xa,circle:()=>co,cite:()=>ki,clipPath:()=>io,code:()=>Yr,col:()=>er,colgroup:()=>eo,create:()=>Ia,data:()=>$r,datalist:()=>sr,dd:()=>ir,defs:()=>Lr,del:()=>ca,desc:()=>Jn,details:()=>aa,dfn:()=>jr,dialog:()=>Pr,div:()=>Br,dl:()=>ur,dt:()=>yr,ellipse:()=>Or,em:()=>Kr,embed:()=>po,feBlend:()=>Zn,feColorMatrix:()=>oi,feComponentTransfer:()=>gr,feComposite:()=>ri,feConvolveMatrix:()=>li,feDiffuseLighting:()=>pr,feDisplacementMap:()=>Tr,feDistantLight:()=>ja,feDropShadow:()=>Sr,feFlood:()=>hi,feFuncA:()=>fi,feFuncB:()=>vi,feFuncG:()=>Ur,feFuncR:()=>Gn,feGaussianBlur:()=>Hi,feImage:()=>Ga,feMerge:()=>Sa,feMergeNode:()=>La,feMorphology:()=>ia,feOffset:()=>Oi,fePointLight:()=>Ea,feSpecularLighting:()=>Va,feSpotLight:()=>Fi,feTile:()=>ma,feTurbulence:()=>Ya,fieldset:()=>zi,figcaption:()=>Ki,figure:()=>Aa,filter:()=>va,footer:()=>ea,foreignObject:()=>Xi,form:()=>wi,g:()=>$a,h1:()=>fo,h2:()=>ji,h3:()=>so,h4:()=>Qr,h5:()=>rr,h6:()=>ro,head:()=>ni,header:()=>lr,hgroup:()=>or,hr:()=>zr,html:()=>ua,i:()=>Xn,iframe:()=>sa,image:()=>Nr,img:()=>Ir,input:()=>Hr,ins:()=>fr,kbd:()=>xr,keygen:()=>Ar,label:()=>Jr,legend:()=>ho,li:()=>$n,line:()=>ci,linearGradient:()=>vr,link:()=>ai,main:()=>di,map:()=>hr,mark:()=>Dr,marker:()=>Na,mask:()=>wr,menu:()=>_i,menuitem:()=>mi,metadata:()=>bi,meter:()=>Gr,nav:()=>qn,object:()=>Bi,ol:()=>Ua,optgroup:()=>ba,option:()=>Fa,output:()=>na,p:()=>Ei,param:()=>wa,path:()=>za,pattern:()=>Ni,picture:()=>fa,polygon:()=>qa,polyline:()=>Li,pre:()=>Wi,progress:()=>Oa,q:()=>ga,radialGradient:()=>Qi,rect:()=>Ji,rp:()=>Si,rt:()=>Za,ruby:()=>lo,s:()=>Ai,samp:()=>ao,script:()=>Xr,section:()=>tr,select:()=>to,small:()=>ei,source:()=>cr,span:()=>ar,stop:()=>Rr,strong:()=>la,style:()=>Yn,sub:()=>oa,summary:()=>Mr,sup:()=>Fr,svg:()=>Vr,symbol:()=>dr,table:()=>br,tbody:()=>kr,td:()=>qr,text:()=>mo,textPath:()=>Qn,textarea:()=>si,tfoot:()=>_r,th:()=>ii,thead:()=>ui,time:()=>mr,title:()=>Er,tr:()=>Ma,track:()=>Cr,tspan:()=>gi,u:()=>pi,ul:()=>yi,use:()=>Wr,video:()=>Kn,view:()=>Vi,wbr:()=>Wa,webview:()=>xa}),Ym=i();function Xm(e,t){if(e instanceof RegExp)return{keys:!1,pattern:e};var n,r,i,a,o=[],s=``,c=e.split(`/`);for(c[0]||c.shift();i=c.shift();)n=i[0],n===`*`?(o.push(n),s+=i[1]===`?`?`(?:/(.*))?`:`/(.*)`):n===`:`?(r=i.indexOf(`?`,1),a=i.indexOf(`.`,1),o.push(i.substring(1,~r?r:~a?a:i.length)),s+=~r&&!~a?`(?:/([^/]+?))?`:`/([^/]+?)`,~a&&(s+=(~r?`?`:``)+`\\`+i.substring(a))):s+=`/`+i;return{keys:o,pattern:RegExp(`^`+s+(t?`(?=$|/)`:`/?$`),`i`)}}var Zm=ft(),Qm=K.useInsertionEffect,$m=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0?K.useLayoutEffect:K.useEffect,eh=Qm||$m,th=e=>{let t=K.useRef([e,(...e)=>t[0](...e)]).current;return eh(()=>{t[0]=e}),t[1]},nh=[`popstate`,`pushState`,`replaceState`,`hashchange`],rh=[],ih=()=>rh.forEach(e=>e()),ah=e=>(rh.push(e)===1&&nh.forEach(e=>addEventListener(e,ih)),()=>{rh=rh.filter(t=>t!==e),rh.length||nh.forEach(e=>removeEventListener(e,ih))}),oh=(e,t)=>(0,Zm.useSyncExternalStore)(ah,e,t),sh=()=>location.search,ch=({ssrSearch:e}={})=>oh(sh,e==null?sh:()=>e),lh=()=>location.pathname,uh=({ssrPath:e}={})=>oh(lh,e==null?lh:()=>e),dh=(e,{replace:t=!1,state:n=null}={})=>history[t?`replaceState`:`pushState`](n,``,e),fh=e=>[uh(e),dh],ph=Symbol.for(`wouter_v3`);if(typeof history<`u`&&window[ph]===void 0){for(let e of[`pushState`,`replaceState`]){let t=history[e];history[e]=function(){let n=t.apply(this,arguments),r=new Event(e);return r.arguments=arguments,dispatchEvent(r),n}}Object.defineProperty(window,ph,{value:!0})}var mh=(e=``)=>e===`/`?``:e,hh=(e,t)=>e[0]===`~`?e.slice(1):mh(t)+e,gh=(e,t)=>(e=_h(mh(e)),t=_h(t),!e||(t.toLowerCase()+`/`).startsWith(e.toLowerCase()+`/`)?t.slice(e.length)||`/`:`~`+t),_h=e=>{try{return e.includes(`%`)?decodeURI(e):e}catch{return e}},vh={hook:fh,searchHook:ch,parser:Xm,base:``,ssrPath:void 0,ssrSearch:void 0,ssrContext:void 0,hrefs:e=>e,aroundNav:(e,t,n)=>e(t,n)},yh=(0,K.createContext)(vh),bh=()=>(0,K.useContext)(yh);(0,K.createContext)({});var xh=e=>{let[t,n]=e.hook(e);return[gh(e.base,t),th((t,r)=>e.aroundNav(n,hh(t,e.base),r))]},Sh=()=>xh(bh());(0,K.forwardRef)((e,t)=>{let n=bh(),[r,i]=xh(n),{to:a=``,href:o=a,onClick:s,asChild:c,children:l,className:u,replace:d,state:f,transition:p,...m}=e;return m.onClick=th(t=>{t.ctrlKey||t.metaKey||t.altKey||t.shiftKey||t.button!==0||(s?.(t),t.defaultPrevented||(t.preventDefault(),i(o,e)))}),m.href=n.hrefs(o[0]===`~`?o.slice(1):n.base+o,n),u!==void 0&&(m.className=u?.call?u(r===o):u),t&&(m.ref=t),c&&(0,K.isValidElement)(l)?(0,K.cloneElement)(l,m):(0,K.createElement)(`a`,m,l)});var Ch=0,wh=0,Th=new Set;function Eh(){wh||Ch>0||Th.size===0||(wh=requestAnimationFrame(()=>{if(wh=0,Ch>0)return;let e=[...Th];Th.clear();for(let t of e)t()}))}function Dh(){return Ch+=1,()=>{--Ch,Eh()}}function Oh({label:e}){return(0,K.useEffect)(Dh,[]),(0,G.jsx)(f,{stack:!0,label:e,size:32})}var kh={claude:`Claude Code`,codex:`Codex`,antigravity:`Antigravity`};function Ah(e,t){return e.harness===`claude`?t.find(t=>t.host===`claude`&&t.id===e.sessionId)?.id??null:t.filter(t=>t.host===e.harness).sort((e,t)=>t.since-e.since)[0]?.id??null}var jh=e=>e.kind!==`none`&&e.kind!==`login`,Mh=e=>e.kind===`quiet`||e.kind===`command`&&e.stuck===!0,Nh=e=>e.kind===`menu`||e.kind===`login`||e.kind===`error`?`amber`:e.kind===`quiet`||e.kind===`command`&&e.stuck?`grey`:null,Ph=(e,t)=>Math.max(1,Math.floor((t-e)/6e4));function Fh(e,t,n,r){let i=Ph(e.since,t);switch(e.kind){case`menu`:return n(`daemon.waiting`);case`login`:return n(`daemon.login`);case`error`:return n(`daemon.error`);case`quiet`:return n(`daemon.quiet`,{minutes:i});case`command`:return e.stuck?n(`daemon.commandStuck`,{minutes:i}):n(`daemon.command`,{command:e.line??``,minutes:i});default:return r}}var Ih=new Set([`thinking`,`running`,`your-turn`,`needs-approval`]),Lh=new Set([`starting`,`queued`]),Rh=e=>e.daemon!==null&&Nh(e.daemon.attention)===`amber`;function zh(e){return(e.daemon?Nh(e.daemon.attention)??(Lh.has(e.daemon.state)?`grey`:null):null)??(e.state===`needs-approval`?`amber`:null)}var Bh={"needs-approval":1,running:2,thinking:3,"your-turn":5};function Vh(e){if(Rh(e))return 0;let t=zh(e);return e.state?t===`grey`&&e.state!==`needs-approval`?4:Bh[e.state]:t===`grey`?4:e.daemon?.state===`running`?2:5}function Hh(e,t){let n=e.filter(e=>Ih.has(e.state)),r=t&&t.state!==`ended`?t:null,i=r?Ah(r,n):null,a=n.map((e,t)=>({key:e.host&&e.id?`${e.host}:${e.id}`:`hook:${t}`,agent:e.agent,state:e.state,since:e.since,turn:e.turn??null,daemon:r&&i!==null&&e.id===i?r:null}));return r&&i===null&&a.push({key:`daemon:${r.taskId}`,agent:kh[r.harness]??r.harness,state:null,since:r.attention.since,turn:null,daemon:r}),a.sort((e,t)=>Vh(e)-Vh(t))}async function Uh(e){let t=await fetch(`/api/agent/daemon`,{method:`POST`,credentials:`same-origin`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),n=await t.json().catch(()=>null);if(!t.ok||!n?.ok)throw Error(n?.error??`HTTP ${t.status}`);return n.data}function Wh(e){return{screen:async()=>{let t=await Uh({artifact:e,op:`agent-screen`});return Array.isArray(t?.lines)?t.lines.filter(e=>typeof e==`string`):[]},input:async t=>{await Uh({artifact:e,op:`agent-input`,...t})}}}var Gh=e=>new URLSearchParams(e).get(`agent`)===`1`;function Kh(){let[e,t]=(0,K.useState)([]),[n,r]=(0,K.useState)([]);return(0,K.useEffect)(()=>{let e=null,n,i=!1,a=()=>{e=new WebSocket(xo(location)),e.onmessage=e=>{let n=JSON.parse(String(e.data));n.type===`agent-status`&&(t(n.sessions),r(n.daemon??[]))},e.onclose=()=>{t([]),r([]),i||(n=setTimeout(a,1e3))}};return a(),()=>{i=!0,clearTimeout(n),e?.close()}},[]),{sessions:e,daemon:n}}var qh=(0,K.lazy)(()=>r(async()=>{let{AgentDock:e}=await import(`./AgentDock-DO3wjCT6.js`);return{AgentDock:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19]),import.meta.url).then(({AgentDock:e})=>({default:e})));function Jh({artifact:e}){let{sessions:t,daemon:n}=Kh(),r=n.find(t=>t.artifact===e)??null,i=(0,K.useMemo)(()=>Wh(e),[e]),a=Hh(t.filter(t=>t.artifacts.includes(e)),r);return a.length===0?null:(0,G.jsx)(K.Suspense,{fallback:null,children:(0,G.jsx)(qh,{trusted:!0,rows:a,transport:r?i:null})})}var Yh=[`private`,`public`,`total`,`publishes`,`storage`,`objects`],Xh=e=>e===`preparing`||e===`uploading`||e===`publishing`;function Zh(e){if(!e||typeof e!=`object`)return null;let t=e;return typeof t.phase!=`string`||![`waiting`,`preparing`,`uploading`,`publishing`,`not-ready`,`failed`,`published`].includes(t.phase)||t.publishedAt!==null&&(typeof t.publishedAt!=`string`||!Number.isFinite(Date.parse(t.publishedAt)))||typeof t.autoPublish!=`boolean`||t.message!==void 0&&typeof t.message!=`string`||t.reasons!==void 0&&(!Array.isArray(t.reasons)||!t.reasons.every(e=>typeof e==`string`))?null:t}var Qh=[`1d`,`7d`,`30d`,`never`],$h=(e,t)=>!!e?.expiresAt&&Date.parse(e.expiresAt)<=t;function eg(e){let t=e?.visibility??`private`,n=e?.cloud,r=!!n?.publishedAt;return{published:r,visibility:t,access:t===`private`&&n?.keyed?`key`:t,onProfile:n?.onProfile===!0,url:r?n.url:null,synced:!r||n.visibility===t}}function tg(e,t){return e===null?null:e?`upToDate`:t?`localChangesAuto`:`localChanges`}var ng=2e3,rg=1e3,ig=3e5;async function Z(e,t,n){try{let r=await fetch(v(`/api/cloud/${t}`),{method:e,cache:`no-store`,headers:n===void 0?{}:{"Content-Type":`application/json`},body:n===void 0?void 0:JSON.stringify(n)}),i=await r.json().catch(()=>({}));return{ok:r.ok,status:r.status,json:i}}catch(e){return{ok:!1,status:0,json:{error:e.message}}}}var ag=null,og=null,sg,cg=null,lg=new Set;function ug(){return og??=Z(`GET`,`status`).then(e=>{if(og=null,!e.ok)return null;ag=e.json;for(let e of lg)e(ag);return ag}),og}function dg(e){return lg.add(e),cg??=bo(e=>{(e.type===`cloud-publication`||e.type===`cloud-published`)&&(clearTimeout(sg),sg=setTimeout(()=>void ug(),rg))}),()=>{lg.delete(e),lg.size>0||(cg?.(),cg=null,clearTimeout(sg))}}function fg(){let[e,t]=(0,K.useState)(ag),[n,r]=(0,K.useState)(!1),i=(0,K.useRef)(null),a=(0,K.useCallback)(()=>ug(),[]),o=(0,K.useCallback)(()=>{i.current!==null&&window.clearInterval(i.current),i.current=null,r(!1)},[]),s=(0,K.useCallback)(async e=>{let t=e??(await Z(`POST`,`login`,{source:`viewer`})).json.url;if(!t)return;window.open(t,`_blank`,`noopener`),o(),r(!0);let n=Date.now();i.current=window.setInterval(async()=>{((await a())?.signedIn||Date.now()-n>ig)&&o()},ng)},[a,o]);return(0,K.useEffect)(()=>{let e=dg(t);return a(),()=>{e(),o()}},[a,o]),{status:e,refresh:a,login:s,waitingForLogin:n}}var pg=(0,K.createContext)(null);function mg({pageWindow:e,children:t}){return(0,G.jsx)(pg.Provider,{value:e??null,children:t})}var hg=()=>(0,K.useContext)(pg)??window;function gg(e,t){if(t===null)return e;let n=new URL(e);return n.searchParams.set(`page`,t),n.href}function _g(){let e=hg(),t=(0,K.useCallback)(t=>(e.addEventListener(`popstate`,t),e.addEventListener(`ryugi:pagechange`,t),()=>{e.removeEventListener(`popstate`,t),e.removeEventListener(`ryugi:pagechange`,t)}),[e]);return[(0,K.useSyncExternalStore)(t,()=>new URLSearchParams(e.location.search).get(`page`)),(0,K.useCallback)((t,n)=>{let r=new URL(e.location.href);r.searchParams.get(`page`)!==t&&(t===null?r.searchParams.delete(`page`):r.searchParams.set(`page`,t),e.history[n?`replaceState`:`pushState`](e.history.state,``,r),e.dispatchEvent(new Event(`ryugi:pagechange`)))},[e])]}var vg=[`B`,`KB`,`MB`,`GB`];function yg(e){let t=e,n=0;for(;t>=1024&&n<vg.length-1;)t/=1024,n++;return`${n===0?t:Number(t.toFixed(1))} ${vg[n]}`}function bg(e,t){return typeof e==`string`&&s.exists(`errors.${e}`)?s.t(`errors.${e}`):t}var xg=e=>typeof e==`object`&&!!e&&Yh.includes(e.kind)&&typeof e.max==`number`;function Sg({kind:e,max:t}){return s.t(`planLimit.${e}`,{max:e===`storage`?yg(t):t})}function Cg(e,t){return e.code===`plan_limit`&&xg(e.limit)?Sg(e.limit):bg(e.code,typeof e.error==`string`?e.error:t)}var wg=!1,Tg=new Set,Eg=e=>{if(wg!==e){wg=e;for(let e of Tg)e()}},Dg=()=>Eg(!0),Og=()=>Eg(!1),kg=()=>wg,Ag=e=>(Tg.add(e),()=>Tg.delete(e)),jg=()=>(0,K.useSyncExternalStore)(Ag,kg,kg),Mg=e=>e?e.replace(/\/+$/,``):null,Ng=(e,t)=>{let n=Mg(e);return n?`${n}${t?.toLowerCase().startsWith(`zh`)?`/zh`:``}`:null},Pg=e=>{let t=Mg(e);return t?`${t}/`:null},Fg=(e,t)=>{let n=Mg(e);return n?`${n}/u/${encodeURIComponent(t)}`:null},Ig=e=>{let t=Mg(e);return t?`${t}/billing`:null},Lg={summary:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kGuDYH:`xfifm61`,khDVqt:`xuxw1ft`,kMwMTN:`x7zghnd`,$$css:!0},card:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x167g77z`,kmVPX3:`xc7ga6q`,k1K539:`xod5an3`,kaIpWk:`xu4hgxq`,kWkggS:`xqdcvd7`,kMwMTN:`x7zghnd`,$$css:!0},success:{kWkggS:`xsf6uxt`,kMwMTN:`xh0clw4`,$$css:!0},failed:{kWkggS:`x8yy6z1`,kMwMTN:`xpt3syw`,$$css:!0}};function Rg({publication:e,published:t,publishedAt:n,online:r,onPublish:i,compact:a=!1,busy:o=!1}){let{t:s,i18n:c}=x(),l=Df(),u=e?.phase??(t?`published`:`waiting`),d=t&&u!==`published`,f=Xh(u),p=s(`publication.${d?`update_${u}`:u}`),m=f?He:u===`failed`?de:u===`published`?O:Uo,h=u===`failed`?Lg.failed:u===`published`?Lg.success:void 0,g=(0,G.jsx)(St,{"aria-hidden":`true`,icon:m,size:a?14:16,spin:f&&!l});if(a)return(0,G.jsxs)(`span`,{role:`status`,...S(Lg.summary,h),children:[g,p]});let _=e?.publishedAt??n,v=i&&!f&&u!==`published`&&u!==`not-ready`;return(0,G.jsxs)(`section`,{"aria-label":s(`publication.label`),...S(Lg.card,h),children:[(0,G.jsxs)(`div`,{role:`status`,className:`x78zum5 x6s0dn4 x167g77z xfifm61 x1s688f`,children:[g,p]}),(0,G.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:s(d&&u===`waiting`?`publication.updateWaitingDescription`:d&&u===`failed`?`publication.updateFailedDescription`:`publication.${u}Description`)}),e?.message?(0,G.jsx)(`p`,{role:`alert`,className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:e.message}):null,e?.reasons?.length?(0,G.jsx)(`ul`,{className:`x1ghz6dp xwn43p0 x1j6dyjg x4q1cud`,children:e.reasons.map((e,t)=>(0,G.jsx)(`li`,{children:e},t))}):null,v?(0,G.jsxs)(`button`,{disabled:o,type:`button`,onClick:i,className:`x78zum5 x6s0dn4 xl56j7k x17d4w8g x1rz828m x36usyh xc342km x1sxf85j x19ckca5 xs0jrwl xln7xf2 xfifm61 x1ypdohk`,children:[(0,G.jsx)(Eo,{"aria-hidden":`true`,size:14}),s(u===`failed`?`publication.retry`:`publication.publishNow`)]}):null,!f&&u!==`published`?(0,G.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:s(r===!1?`publication.offline`:!i&&r===!0?`publication.updateLocal`:e?.autoPublish?u===`failed`?`publication.autoPublishRetry`:`publication.autoPublish`:`publication.manualPublish`)}):null,d?(0,G.jsxs)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud x1y1aw1k x178xt8z x13fuv20 xxu5053`,children:[s(`publication.previousVersion`),_?(0,G.jsxs)(G.Fragment,{children:[` `,(0,G.jsx)(`time`,{dateTime:_,children:new Date(_).toLocaleString(c.language)})]}):null]}):null]})}var zg=(e,t)=>e===`public`&&(t===`private`||t===`unpublished`),Q={root:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x195vfkc`,keoZOQ:`x1xmf6yo`,kLKAdn:`x1y1aw1k`,kEafiO:`x178xt8z`,kPef9Z:`x13fuv20`,kLZC3w:`xxu5053`,$$css:!0},summary:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x167g77z`,kzqmXN:`xh8yej3`,kmVPX3:`x14zjhkh`,kMzoRj:`xc342km`,kaIpWk:`xu4hgxq`,kWkggS:`xjbqb8w x9jwiqo`,kMwMTN:`xo2rkog`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,k9WMMc:`x1yc453h`,kkrTdU:`x1ypdohk`,$$css:!0},icon:{k1xSpc:`xrvj5dj`,kgQiWS:`x1ku5rj1`,kUk6DE:`x1okw0bk`,kzqmXN:`xvy4d1p`,kZKoxP:`xxk0z11`,kaIpWk:`x1kogg8i`,kWkggS:`xahzvm9`,kMwMTN:`x1bo0w0s`,$$css:!0},text:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,kLWn49:`x1xfvgam`,$$css:!0},lead:{k1xSpc:`x1lliihq`,k63SB2:`x1s688f`,$$css:!0},sub:{k1xSpc:`x1lliihq`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,$$css:!0},chevron:{kMwMTN:`xddlp02`,$$css:!0},group:{k1xSpc:`x78zum5`,kjj79g:`x1qughib`,kogj98:`x12dmwbt`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,k63SB2:`xk50ysn`,$$css:!0},item:{k1xSpc:`x78zum5`,kGNEyG:`x1cy8zhl`,kOIVth:`x167g77z`,kmVPX3:`x14zjhkh`,$$css:!0},check:{kUk6DE:`x1okw0bk`,keoZOQ:`xvijh9v`,$$css:!0},body:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,$$css:!0},name:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,k63SB2:`xk50ysn`,kLWn49:`x1xfvgam`,$$css:!0},title:{k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,$$css:!0},type:{kUk6DE:`x1okw0bk`,kg3NbH:`xm9j1uf`,kaIpWk:`x12oqio5`,kWkggS:`xahzvm9`,kMwMTN:`x1bo0w0s`,kMv6JI:`x1fao0z8`,kGuDYH:`x1k6wstc`,$$css:!0},tag:{kUk6DE:`x1okw0bk`,kg3NbH:`xm9j1uf`,kaIpWk:`x12oqio5`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kMwMTN:`x1bo0w0s`,kGuDYH:`x1k6wstc`,$$css:!0},warnTag:{kVAM5u:`x9r1u3d`,kMwMTN:`x7zghnd`,$$css:!0},meta:{keoZOQ:`xvijh9v`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,kLWn49:`x37zpob`,$$css:!0},warn:{kMwMTN:`x7zghnd`,$$css:!0},error:{kMwMTN:`x12vcgws`,$$css:!0},action:{keoZOQ:`x1k70j0n`,$$css:!0}},Bg={pad:{kg3NbH:`x5k8d2m`,$$css:!0}},Vg=[{value:`private`,label:`share.onlyMe`,Icon:To},{value:`public`,label:`share.anyone`,Icon:ct}];function Hg({busy:e,error:t,onCopyFailed:n,onPublish:r,onVisibility:i,readOnly:a,rootVisibility:o,state:s,title:c,type:l,url:u,uses:d}){let{t:f}=x(),p=zg(o,s),m=f(s===`public`?`cascade.tag.public`:s===`private`?`cascade.tag.private`:s===`unpublished`?`beside.unpublished`:`beside.unsupported`),h=async()=>{if(u)try{await navigator.clipboard.writeText(u)}catch{n?.()}},g=!a&&s!==`unsupported`,_=Q;return(0,G.jsxs)(`div`,{"data-beside-card":``,className:`x78zum5 xdt5ytf x195vfkc x1xmf6yo xe8ttls xmkeg23 x1y0btm7 x12xov25 xhpnuu7`,children:[(0,G.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x1nejdyq xdd8z9q xddlp02 x1j6dyjg xk50ysn`,children:[(0,G.jsx)(qo,{size:12}),f(`beside.title`)]}),(0,G.jsxs)(`span`,{...S(_.name,Bg.pad),children:[(0,G.jsx)(`span`,{...S(_.type),children:l}),(0,G.jsx)(`span`,{...S(_.title),children:c}),(0,G.jsx)(`span`,{...S(_.tag,p&&_.warnTag),children:m})]}),d||p?(0,G.jsxs)(`span`,{...S(_.meta,p&&_.warn,Bg.pad),children:[d?f(`referrers.uses`,{count:d}):null,d&&p?` · `:null,p?(0,G.jsx)(`span`,{"data-beside-hidden":``,children:f(`beside.hidden`)}):null]}):null,g||s!==`unsupported`?(0,G.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n x5k8d2m`,children:[g&&s===`unpublished`?(0,G.jsx)(Ye,{"data-beside-publish":``,disabled:e,size:`small`,onClick:()=>r?.(),children:f(`beside.publish`)}):null,g&&s!==`unpublished`?(0,G.jsx)(`span`,{role:`radiogroup`,className:`x3nfvp2 x1i3ajwb x1kogg8i xahzvm9`,children:Vg.map(({value:t,label:n,Icon:r})=>(0,G.jsxs)(`button`,{"aria-checked":t===s,"data-beside-visibility":t,disabled:e,role:`radio`,type:`button`,onClick:()=>t!==s&&i?.(t),...{0:{className:`x3nfvp2 x6s0dn4 x1jnr06f xf4egzd xdqyycr xc342km x1sxf85j xjbqb8w x1bo0w0s xqfszdh x1j6dyjg x1ypdohk`},1:{className:`x3nfvp2 x6s0dn4 x1jnr06f xf4egzd xdqyycr xc342km x1sxf85j xqfszdh x1j6dyjg x1ypdohk x1rozbrz xo2rkog`}}[t===s|0],children:[(0,G.jsx)(r,{size:11}),f(n)]},t))}):null,(0,G.jsx)(`span`,{className:`x98rzlu`}),(0,G.jsx)(Ye,{"aria-label":f(`beside.copyLink`),"data-beside-copy":``,disabled:!u,icon:je,size:`small`,onClick:()=>void h()})]}):null,t?(0,G.jsx)(`span`,{"data-beside-error":``,...S(_.meta,_.error,Bg.pad),children:t}):null]})}var Ug=[`unpublished`,`stale`,`private`,`withdrawn`],Wg=[`unpublished`,`stale`];function Gg(e,t,n){let r=new Map(e.map(e=>[e.artifact,e])),i=e=>Ug.includes(e.state)&&(t[e.artifact]??Wg.includes(e.state)),a=e=>n?e===n:!r.has(e),o=new Set,s=e=>{if(a(e))return!0;let t=r.get(e);return!!t&&o.has(e)&&(t.open||i(t))};for(let t=!0;t;){t=!1;for(let n of e)!o.has(n.artifact)&&n.parents.some(s)&&(o.add(n.artifact),t=!0)}return e.map(e=>{let{reason:t,upstream:n,...r}=e,a=e.state===`blocked`?e.blocked:void 0;return o.has(e.artifact)?{...r,checked:i(e),selectable:Ug.includes(e.state),...a?{reason:a}:{}}:{...r,checked:!1,selectable:!1,reason:`upstream`,upstream:e.via??e.parents[0]}})}var Kg=e=>e.selectable?e.state===`private`?`private`:e.state===`withdrawn`?`skipped`:`publish`:e.state===`ready`?`ready`:`skipped`;function qg({busy:e,error:t,includeRoot:n,items:r,offline:i,onPublish:a,results:o,rootVisibility:s}){let{t:c}=x(),[l,u]=(0,K.useState)(!1),[d,f]=(0,K.useState)({}),p=(0,K.useMemo)(()=>{let e=Gg(r,d);return i?e.map(e=>e.state===`private`?e:{...e,checked:!1,selectable:!1,reason:e.reason??`offline`}):e},[r,d,i]);if(!r.length)return null;let m=e=>r.find(t=>t.artifact===e)?.title??e,h=p.filter(e=>e.state!==`ready`&&e.state!==`private`).length,g=p.filter(e=>e.state===`private`&&!e.checked).length,_=p.filter(e=>e.checked),v=new Map((o??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),y=p.some(e=>e.state!==`ready`),b=()=>a(_.filter(e=>e.state!==`private`).map(e=>e.artifact),_.filter(e=>e.state===`private`).map(e=>e.artifact)),C=e=>{let t=v.get(e.artifact);return t?.error?{text:t.error.error,tone:Q.error}:e.reason===`offline`?{text:c(`cascade.offline`),tone:null}:e.reason===`upstream`?{text:c(`cascade.upstream`,{via:m(e.upstream??``)}),tone:null}:{text:[e.state===`blocked`?e.reason??``:e.state===`private`?c(`cascade.private`):e.state===`ready`?``:c(`cascade.${e.state}`),e.via?c(`cascade.via`,{via:m(e.via)}):``].filter(Boolean).join(` · `),tone:e.state===`private`?Q.warn:null}},w=[`publish`,`private`,`skipped`,`ready`],T=y?(0,G.jsx)(Ye,{block:!0,"data-cascade-publish":``,disabled:!_.length||e,loading:e,type:n?`primary`:`default`,onClick:b,...S(Q.action),children:c(n?`cascade.publishWithRoot`:`cascade.publish`,{count:_.length})}):null;return(0,G.jsxs)(`div`,{...S(Q.root),children:[(0,G.jsxs)(`button`,{"aria-expanded":l,"data-cascade-summary":``,type:`button`,onClick:()=>u(e=>!e),...S(Q.summary),children:[(0,G.jsx)(`span`,{...S(Q.icon),children:(0,G.jsx)(ke,{size:13})}),(0,G.jsxs)(`span`,{...S(Q.text),children:[(0,G.jsx)(`span`,{...S(Q.lead),children:h?c(`cascade.summaryPending`,{total:r.length,pending:h}):c(`cascade.summaryReady`,{total:r.length})}),g?(0,G.jsx)(`span`,{...S(Q.sub),children:c(`cascade.summaryLocked`,{count:g})}):null,i?(0,G.jsx)(`span`,{...S(Q.sub),children:c(`cascade.offlineHint`)}):null]}),l?(0,G.jsx)(at,{size:14,...S(Q.chevron)}):(0,G.jsx)(pe,{size:14,...S(Q.chevron)})]}),l?w.map(t=>{let n=p.filter(e=>Kg(e)===t);if(!n.length)return null;let r=c(t===`publish`?`cascade.group.publish.${s}`:`cascade.group.${t}`);return(0,G.jsxs)(`div`,{"data-cascade-group":t,children:[(0,G.jsxs)(`div`,{...S(Q.group),children:[(0,G.jsx)(`span`,{children:r}),(0,G.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=C(t);return(0,G.jsxs)(`label`,{"data-cascade-item":t.artifact,...S(Q.item),children:[(0,G.jsx)(`span`,{...S(Q.check),children:(0,G.jsx)(Vp,{checked:t.checked,disabled:!t.selectable||e,onChange:e=>f(n=>({...n,[t.artifact]:e}))})}),(0,G.jsxs)(`span`,{...S(Q.body),children:[(0,G.jsxs)(`span`,{...S(Q.name),children:[(0,G.jsx)(`span`,{...S(Q.type),children:t.artifact.split(`/`)[0]}),(0,G.jsx)(`span`,{...S(Q.title),children:t.title}),t.state===`private`?(0,G.jsx)(`span`,{...S(Q.tag,Q.warnTag),children:c(`cascade.tag.private`)}):t.state===`ready`?(0,G.jsx)(`span`,{...S(Q.tag),children:c(`cascade.tag.${s}`)}):null]}),n.text?(0,G.jsx)(`span`,{...S(Q.meta,n.tone),children:n.text}):null]})]},t.artifact)})]},t)}):null,t?(0,G.jsx)(`span`,{...S(Q.meta,Q.error),children:t}):null,T]})}function Jg(e,t,n){let r=n?e.filter(e=>e.artifact!==n&&e.cloudId!==n):e,i=r.filter(e=>e.state!==`ready`);return{shown:r,hidden:i.length,allPrivate:i.length>0&&i.every(e=>e.state===`private`),visible:t===`public`&&i.length>0}}var Yg=[`private`,`unpublished`,`unlinked`,`ready`,`skipped`],Xg=e=>e===`withdrawn`||e===`blocked`?`skipped`:e;function Zg({busy:e,cloudUnavailable:t,error:n,exclude:r,items:i,onPublish:a,results:o,rootVisibility:s}){let{t:c}=x(),[l,u]=(0,K.useState)(!1),[d,f]=(0,K.useState)({}),{shown:p,hidden:m,allPrivate:h,visible:g}=Jg(i,s,r);if(!g)return null;let _=e=>e.selectable&&(d[e.artifact]??e.checked),v=p.filter(_),y=new Map((o??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),b=e=>{let t=y.get(e.artifact)?.error?.error;if(t)return{text:t,tone:Q.error};let n=e.state===`blocked`?e.reason:e.state===`withdrawn`?c(`referrers.withdrawn`):``;return{text:[c(`referrers.uses`,{count:e.uses}),n].filter(Boolean).join(` · `),tone:null}},C=()=>a(v.filter(e=>e.state!==`private`).map(e=>e.artifact),v.filter(e=>e.state===`private`).map(e=>e.artifact));return(0,G.jsxs)(`div`,{...S(Q.root),children:[(0,G.jsxs)(`button`,{"aria-expanded":l,"data-referrer-summary":``,type:`button`,onClick:()=>u(e=>!e),...S(Q.summary),children:[(0,G.jsx)(`span`,{...S(Q.icon),children:(0,G.jsx)(Kt,{size:13})}),(0,G.jsxs)(`span`,{...S(Q.text),children:[(0,G.jsx)(`span`,{...S(Q.lead),children:c(`referrers.summary`,{total:p.length})}),(0,G.jsx)(`span`,{...S(Q.sub,Q.warn),children:c(h?`referrers.hiddenPrivate`:`referrers.hidden`,{count:m})}),t?(0,G.jsx)(`span`,{...S(Q.sub),children:c(`referrers.cloudUnavailable`)}):null]}),l?(0,G.jsx)(at,{size:14,...S(Q.chevron)}):(0,G.jsx)(pe,{size:14,...S(Q.chevron)})]}),l?Yg.map(t=>{let n=p.filter(e=>Xg(e.state)===t);return n.length?(0,G.jsxs)(`div`,{"data-referrer-group":t,children:[(0,G.jsxs)(`div`,{...S(Q.group),children:[(0,G.jsx)(`span`,{children:c(`referrers.group.${t}`)}),(0,G.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=b(t);return(0,G.jsxs)(`label`,{"data-referrer-item":t.artifact,...S(Q.item),children:[(0,G.jsx)(`span`,{...S(Q.check),children:(0,G.jsx)(Vp,{checked:_(t),disabled:!t.selectable||e,onChange:e=>f(n=>({...n,[t.artifact]:e}))})}),(0,G.jsxs)(`span`,{...S(Q.body),children:[(0,G.jsxs)(`span`,{...S(Q.name),children:[(0,G.jsx)(`span`,{...S(Q.type),children:`document`}),(0,G.jsx)(`span`,{...S(Q.title),children:t.title}),t.state===`private`?(0,G.jsx)(`span`,{...S(Q.tag,Q.warnTag),children:c(`cascade.tag.private`)}):t.state===`ready`?(0,G.jsx)(`span`,{...S(Q.tag),children:c(`cascade.tag.public`)}):null]}),(0,G.jsx)(`span`,{...S(Q.meta,n.tone),children:n.text})]})]},t.artifact)})]},t):null}):null,n?(0,G.jsx)(`span`,{...S(Q.meta,Q.error),children:n}):null,l?(0,G.jsx)(Ye,{block:!0,"data-referrer-publish":``,disabled:!v.length||e,loading:e,onClick:C,...S(Q.action),children:c(`referrers.publish`,{count:v.length})}):null]})}var Qg=864e5;function $g({text:e,action:t,onConfirm:n,onCancel:r}){let{t:i}=x();return(0,G.jsxs)(`div`,{"data-share-confirm":``,className:`x1k70j0n xe8ttls xmkeg23 x1y0btm7 x12xov25 xu4hgxq x2fo67v`,children:[(0,G.jsx)(`p`,{className:`x1q6ys4k x1j6dyjg x37zpob`,children:e}),(0,G.jsxs)(`div`,{className:`x78zum5 x13a6bvl x17d4w8g`,children:[(0,G.jsx)(Ye,{"data-confirm":`no`,size:`small`,onClick:r,children:i(`common.cancel`)}),(0,G.jsx)(Ye,{"data-confirm":`yes`,size:`small`,type:`primary`,onClick:n,children:t})]})]})}function e_({value:e,disabled:t,onExpiry:n,onRegenerate:r}){let{t:i,i18n:a}=x(),[o]=(0,K.useState)(()=>Date.now()),s=$h(e,o),c=e.expiresAt?new Date(e.expiresAt).toLocaleDateString(a.language,{month:`short`,day:`numeric`}):null,l=e.expiresAt?s?i(`share.expired`,{date:c}):i(`share.expiresIn`,{count:Math.max(1,Math.ceil((Date.parse(e.expiresAt)-o)/Qg)),date:c}):i(`share.neverExpires`),u=Qh.map(e=>({value:e,label:i(`share.expiry.${e}`)}));return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(`div`,{className:`x78zum5 x1a02dak x6s0dn4 x1qughib x167g77z xwkmoec x1bo0w0s xfifm61`,children:[(0,G.jsxs)(`label`,{"data-key-expired":s?``:void 0,"data-key-expiry":``,className:`x1n2onr6 x3nfvp2 xeuugli xss6m8b`,children:[(0,G.jsx)(`span`,{className:`x10l6tqk x1i1rx1s xjm9jq1 xb3r6kr xuxw1ft x1hyvwdk`,children:i(`share.expiryLabel`)}),(0,G.jsx)(yo,{disabled:t,options:u,placeholder:(0,G.jsx)(`span`,{...{0:{},1:{className:`x12vcgws`}}[!!s|0],children:l}),prefix:_o,size:`small`,style:{width:`auto`,minWidth:0,fontSize:11},value:null,onSelect:e=>n(e)})]}),(0,G.jsx)(Ye,{"data-key-regenerate":``,disabled:t,icon:ts,outdent:`end`,size:`small`,style:{fontSize:11},type:`text`,onClick:r,children:i(`share.regenerate`)})]}),s?(0,G.jsx)(`p`,{className:`x8k27cj x1bo0w0s x1j6dyjg x37zpob`,children:i(`share.expiredNote`)}):null]})}var t_=[{value:`private`,label:`share.onlyMe`,hint:`share.onlyMeHint`,Icon:To},{value:`key`,label:`share.keyHolders`,hint:`share.keyHint`,Icon:Zo},{value:`public`,label:`share.anyone`,hint:`share.anyoneHint`,Icon:ct}],n_={private:{text:`share.removeKeyConfirm`,action:`share.removeKey`},public:{text:`share.makePublicConfirm`,action:`share.makePublic`},regenerate:{text:`share.regenerateConfirm`,action:`share.regenerate`}};function r_({beside:e,cascade:t,children:n,foot:r,onCopyFailed:i,onVisibility:a,profile:o,referrers:s,saving:c=!1,shareKey:l,status:u,url:d,visibility:f}){let{t:p}=x(),[m,h]=(0,K.useState)(!1),[g,_]=(0,K.useState)(null),[v]=(0,K.useState)(()=>Date.now());(0,K.useEffect)(()=>{if(!m)return;let e=setTimeout(()=>h(!1),2e3);return()=>clearTimeout(e)},[m]);let y=l?.active?`key`:f,b=y===`key`?l?.value?.url??null:d,S=async()=>{if(b)try{await navigator.clipboard.writeText(b),h(!0)}catch{i?.()}},C=e=>{e!==y&&(e===`key`?l?.onSelect():y===`key`?_(e):a(e))},w=()=>{g===`private`?l?.onRemove():g===`public`?a(`public`):g===`regenerate`&&l?.onRegenerate(),_(null)},T=y===`key`?l?.value??null:null,E=$h(T,v);return(0,G.jsxs)(`div`,{className:`x78zum5 xdt5ytf x195vfkc x58rd6w xqfszdh xfifm61`,children:[u,(0,G.jsx)(`p`,{className:`x1coi2bq xfifm61 x1s688f`,children:p(`share.whoCanSee`)}),(0,G.jsx)(`div`,{"aria-label":p(`share.whoCanSee`),role:`radiogroup`,className:`x78zum5 xdt5ytf x195vfkc`,children:t_.filter(({value:e})=>e!==`key`||l).map(({value:e,label:t,hint:n,Icon:r})=>(0,G.jsxs)(`button`,{"aria-checked":e===y,"data-visibility":e,disabled:c,role:`radio`,type:`button`,onClick:()=>C(e),...{0:{className:`x78zum5 xh8yej3 x6s0dn4 x167g77z x1ruevkc xmkeg23 x1y0btm7 x9r1u3d xu4hgxq xjbqb8w x9jwiqo xo2rkog xqfszdh x1yc453h x1ypdohk`},1:{className:`x78zum5 xh8yej3 x6s0dn4 x167g77z x1ruevkc xmkeg23 x1y0btm7 xu4hgxq xo2rkog xqfszdh x1yc453h x1ypdohk xgcsv5v x15dg6x3`}}[e===y|0],children:[(0,G.jsx)(`span`,{...{0:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i xahzvm9`},1:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i x19ckca5 xs0jrwl`}}[e===y|0],children:(0,G.jsx)(r,{size:12})}),(0,G.jsxs)(`span`,{children:[(0,G.jsxs)(`span`,{className:`x1lliihq xfifm61 x1s688f xwn7fz2`,children:[p(t),e===`key`&&l?.locked?(0,G.jsx)(`span`,{"data-pro-badge":``,className:`xdzw4kq xm9j1uf xmkeg23 x1y0btm7 xgcsv5v x12oqio5 x1bo0w0s x1k6wstc x1s688f x1xxsxie`,children:p(`share.proBadge`)}):null]}),(0,G.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:p(n)})]})]},e))}),y===`public`&&o?(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z x16ngw23 x12ulsxz x1icxu4v x1bo0w0s x1j6dyjg xwn7fz2`,children:[(0,G.jsxs)(`span`,{children:[p(`share.showOnProfile`),o.path?(0,G.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:o.path}):null]}),(0,G.jsx)(`button`,{"aria-checked":o.shown,"aria-label":p(`share.showOnProfile`),"data-profile-switch":``,disabled:c,role:`switch`,type:`button`,onClick:()=>o.onChange(!o.shown),...{0:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x15dg6x3 x1ypdohk`},1:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x1ypdohk x19ckca5`}}[!!o.shown|0],children:(0,G.jsx)(`span`,{...{0:{className:`x10l6tqk xs7f9wi xaoy8p5 x1fsd2vl x170jfvy x16rqkct x1rozbrz x2hifos xgdialr`},1:{className:`x10l6tqk xs7f9wi x1fsd2vl x170jfvy x16rqkct x1rozbrz x2hifos xgdialr x1r4y97`}}[!!o.shown|0]})})]}):null,(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n`,children:[(0,G.jsx)(`input`,{readOnly:!0,"aria-label":p(`share.linkLabel`),"data-share-url":``,"data-struck":E?``:void 0,placeholder:p(y===`key`?`share.keyPending`:`share.linkPending`),value:b??``,onFocus:e=>e.currentTarget.select(),...{0:{className:`x98rzlu xeuugli xc342km x1a2a7pz xifx94n xdqyycr x1sxf85j x2fo67v x1bo0w0s x1fao0z8 x1j6dyjg xb3r6kr xlyipyv xuxw1ft`},1:{className:`x98rzlu xeuugli xc342km x1a2a7pz xifx94n xdqyycr x1sxf85j x2fo67v x1fao0z8 x1j6dyjg xb3r6kr xlyipyv xuxw1ft xc7n51q x5lhwog`}}[!!E|0]}),(0,G.jsx)(Ye,{disabled:!b,icon:wo,size:`small`,type:`primary`,onClick:()=>void S(),children:p(m?`share.copied`:`share.copy`)})]}),g?(0,G.jsx)($g,{action:p(n_[g].action),text:p(n_[g].text),onCancel:()=>_(null),onConfirm:w}):T&&l?(0,G.jsx)(e_,{disabled:c,value:T,onExpiry:l.onExpiry,onRegenerate:()=>_(`regenerate`)}):null,r&&y!==`key`?(0,G.jsx)(`div`,{className:`x8k27cj xddlp02 x1j6dyjg`,children:r}):null,e?(0,G.jsx)(Hg,{...e}):null,t?(0,G.jsx)(qg,{...t}):null,s?(0,G.jsx)(Zg,{...s}):null,n]})}var i_=`ryugi.pendingCloudIntent`,a_=6e5;function o_(e,t){try{let n={artifact:e,intent:t,at:Date.now()};window.sessionStorage.setItem(i_,JSON.stringify(n))}catch{}}function s_(e){try{let t=window.sessionStorage.getItem(i_);if(!t)return null;let n=JSON.parse(t);return n.artifact!==e||n.intent!==`share`&&n.intent!==`phone`&&n.intent!==`sync`||typeof n.at!=`number`||Date.now()-n.at>a_?(typeof n.at==`number`&&Date.now()-n.at>a_&&window.sessionStorage.removeItem(i_),null):(window.sessionStorage.removeItem(i_),n.intent)}catch{return null}}function c_({origin:e}){let{t,i18n:n}=x(),r=e.replace(/\/+$/,``),i=n.language?.toLowerCase().startsWith(`zh`)?`/zh`:``;return(0,G.jsxs)(`p`,{className:`x1ghz6dp x1j6dyjg x1evy7pa xddlp02`,children:[t(`common.authLegalPrefix`),(0,G.jsx)(`a`,{href:`${r}${i}/terms`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.terms`)}),t(`common.authLegalAnd`),(0,G.jsx)(`a`,{href:`${r}${i}/privacy`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.privacy`)}),t(`common.authLegalSuffix`)]})}var l_=[{id:`share`,icon:ke,titleKey:`cloudIntent.shareTitle`,descKey:`cloudIntent.shareDesc`},{id:`phone`,icon:ss,titleKey:`cloudIntent.phoneTitle`,descKey:`cloudIntent.phoneDesc`},{id:`sync`,icon:Eo,titleKey:`cloudIntent.syncTitle`,descKey:`cloudIntent.syncDesc`}],u_={share:`cloudIntent.shareCta`,phone:`cloudIntent.phoneCta`,sync:`cloudIntent.syncCta`},d_={share:`cloudIntent.sharePrivacy`,phone:`cloudIntent.phonePrivacy`,sync:`cloudIntent.syncPrivacy`};function f_({origin:e,landingUrl:t,waitingForLogin:n,onStartIntent:r}){let{t:i}=x(),[a,o]=(0,K.useState)(`share`);return(0,G.jsxs)(`div`,{"data-intent-login-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x168biu4 xw7nakj xqfszdh xfifm61 xo2rkog`,children:[(0,G.jsxs)(`div`,{className:`x78zum5 x1cy8zhl x1qughib x167g77z`,children:[(0,G.jsxs)(`div`,{children:[(0,G.jsx)(`span`,{className:`x1lliihq x2ouz8m x1s688f xo2rkog`,children:i(`cloudIntent.heading`)}),(0,G.jsx)(`span`,{className:`x1lliihq x1qt5hsa x1bo0w0s xr9ek0c`,children:i(`cloudIntent.subheading`)})]}),(0,G.jsx)(`span`,{className:`x1s31vzs x1s688f x1o8fvuk x6z2zk2 xj8oexa xlkn9b3 x1e6avla xuxw1ft x2lah0s`,children:i(`cloudIntent.badge`)})]}),(0,G.jsx)(`div`,{"aria-label":i(`cloudIntent.heading`),role:`radiogroup`,className:`x78zum5 xdt5ytf x1j9xkj6`,children:l_.map(({id:e,icon:t,titleKey:n,descKey:r})=>{let s=a===e;return(0,G.jsxs)(`button`,{"aria-checked":s,"data-cloud-intent":e,role:`radio`,type:`button`,...{0:{className:`xh8yej3 x1yc453h x78zum5 x1cy8zhl x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x12xov25 x1qj25k6 x1q4ynmn x1rozbrz x9jwiqo x1ypdohk xqfszdh x1mimgl9`},1:{className:`xh8yej3 x1yc453h x78zum5 x1cy8zhl x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x1q4ynmn x1ypdohk xqfszdh x1mimgl9 x1ektstd x1xrkum6`}}[!!s|0],onClick:()=>o(e),children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,...{0:{className:`x23j0i4 xd7y6wv xu4hgxq xahzvm9 xo2rkog xrvj5dj x1ku5rj1 x2lah0s xvijh9v`},1:{className:`x23j0i4 xd7y6wv xu4hgxq xrvj5dj x1ku5rj1 x2lah0s xvijh9v x1teopom x1cge3fn`}}[!!s|0],children:(0,G.jsx)(t,{size:14})}),(0,G.jsxs)(`span`,{className:`x98rzlu xeuugli`,children:[(0,G.jsx)(`span`,{className:`x1lliihq x1ct8sxb x1s688f xo2rkog`,children:i(n)}),(0,G.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4 xvijh9v`,children:i(r)})]}),(0,G.jsx)(`span`,{"aria-hidden":`true`,...{0:{className:`x1a00udw xx3o462 x16rqkct xvndefy x1y0btm7 xgcsv5v x2lah0s x1gslohp xrvj5dj x1ku5rj1 x9f619`},1:{className:`x1a00udw xx3o462 x16rqkct xvndefy x1y0btm7 x2lah0s x1gslohp xrvj5dj x1ku5rj1 x9f619 x1ektstd x15az74h`}}[!!s|0],children:s?(0,G.jsx)(`span`,{className:`x1ftt334 x1ycjhwn x16rqkct x1vi11w0`}):null})]},e)})}),(0,G.jsx)(Ye,{className:{className:`xh8yej3 x90ne7k x15az74h x12s0oaj x1ektstd x1w8fas2 xt9vybz xh88oxj`}.className,"data-cloud-intent-submit":``,icon:vo,loading:n,type:`primary`,onClick:()=>r(a),children:i(n?`publish.waitingLogin`:u_[a])}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g xknfcqp x1q4txso xur7f20 x2fo67v x1j6dyjg x1bo0w0s xfrs9s4`,children:[(0,G.jsx)(To,{"aria-hidden":`true`,size:12,style:{flexShrink:0}}),(0,G.jsx)(`span`,{children:i(d_[a])})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,G.jsx)(c_,{origin:e}),t?(0,G.jsxs)(`a`,{href:t,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[i(`cloudEntry.learnShort`),(0,G.jsx)(Co,{"aria-hidden":`true`,size:11})]}):null]})]})}var p_={bar:{kbCHJM:`x1nrll8i`,krVfgx:`xjnlgov`,k3aq6I:`xuuh30`,k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x1v2ro7d`,ks0D6T:`x4d2062`,kZKoxP:`xn3w4p2`,kB7OPa:`x9f619`,kZCmMZ:`x106a9eq`,kwRFfy:`x1icxu4v`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kaIpWk:`x1e6avla`,kWkggS:`x12ilycc`,kMwMTN:`xo2rkog`,kGVxlE:`x1gxogt1`,kGuDYH:`x4z9k3i`,kLWn49:`x37zpob`,khDVqt:`xuxw1ft`,$$css:!0},absolute:{kVAEAm:`x10l6tqk`,kY2c9j:`x1n327nk`,$$css:!0},fixed:{kVAEAm:`xixxii4`,kY2c9j:`x68pp3s`,$$css:!0},text:{k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,$$css:!0},muted:{kMwMTN:`x1bo0w0s`,$$css:!0},changed:{kMwMTN:`xr46axq`,$$css:!0},agent:{kMwMTN:`x1yz8712`,$$css:!0},success:{kMwMTN:`xcqng5w`,$$css:!0},rule:{kzqmXN:`x1i1rx1s`,kZKoxP:`xlup9mm`,kmuXW:`x2lah0s`,kWkggS:`xh6qj2i`,$$css:!0},button:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kmuXW:`x2lah0s`,kZKoxP:`x10w6t97`,kMzoRj:`xc342km`,kaIpWk:`x1e6avla`,kMv6JI:`xjb2p0i`,kGuDYH:`x4z9k3i`,kkrTdU:`x1ypdohk`,$$css:!0},anchor:{kMnn75:`xkrqix3`,$$css:!0},primary:{kg3NbH:`xqin4a2`,kWkggS:`x19ckca5`,kMwMTN:`xs0jrwl`,k63SB2:`xk50ysn`,kSiTet:`x1hc1fzr x1k29llp`,$$css:!0},quiet:{kg3NbH:`xaope02`,kWkggS:`xjbqb8w xj0l527`,kMwMTN:`x1bo0w0s`,$$css:!0},link:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x1jnr06f`,kmuXW:`x2lah0s`,kmVPX3:`x1717udv`,kMzoRj:`xc342km`,kWkggS:`xjbqb8w`,kMwMTN:`x1bo0w0s xytdrwj`,kMv6JI:`xjb2p0i`,kGuDYH:`x4z9k3i`,kMnn75:`xujl8zx`,k1TLXF:`x1tdp7nx`,kcSHmL:`xda060z`,kkrTdU:`x1ypdohk`,$$css:!0}};function m_({position:e,children:t,style:n,...r}){return(0,G.jsx)(`div`,{"data-action-bar":!0,...r,...S(p_.bar,p_[e]),style:n,children:t})}function h_({children:e,tone:t=`default`,limit:n}){return(0,G.jsx)(`span`,{...S(p_.text,t!=="default"&&p_[t]),style:n?{maxWidth:n}:void 0,children:e})}function g_(){return(0,G.jsx)(`span`,{className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})}function __({variant:e,children:t,...n}){return(0,G.jsx)(`a`,{...n,...S(p_.button,p_.anchor,p_[e]),children:t})}function v_({variant:e,children:t,...n}){return(0,G.jsx)(`button`,{type:`button`,...n,...S(e===`link`?p_.link:[p_.button,p_[e]]),children:t})}function y_({result:e,onDismiss:t,onOpenSharePanel:n}){let{t:r}=x(),[i,a]=(0,K.useState)(!1),[o,s]=(0,K.useState)(!!e.copied),c=async()=>{if(e.url)try{await navigator.clipboard.writeText(e.url),s(!0)}catch{}};return e.error?(0,G.jsxs)(m_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[(0,G.jsx)(h_,{limit:380,tone:`muted`,children:e.error}),(0,G.jsx)(v_,{variant:`primary`,onClick:n,children:r(`cloudIntent.viewDetails`)}),(0,G.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xgd8bvy x1fgtraw x1717udv xc342km x1e6avla xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk x2lah0s`,onClick:t,children:(0,G.jsx)(mt,{size:13})})]}):(0,G.jsxs)(G.Fragment,{children:[i&&e.url?(0,G.jsxs)(`aside`,{"aria-label":r(`cloudIntent.qrTitle`),"data-intent-qr-popover":``,role:`dialog`,className:`xixxii4 x1nrll8i xhjxwu4 xuuh30 x12tvco5 x149cmgi xw7nakj x1tamke2 xmkeg23 x1y0btm7 x12xov25 xixl9f9 x12ilycc x1ytezby xo2rkog xqfszdh xfifm61 x78zum5 xdt5ytf x1v2ro7d`,children:[(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,G.jsx)(`span`,{className:`x4z9k3i x1s688f`,children:r(`cloudIntent.qrTitle`)}),(0,G.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xvy4d1p xxk0z11 x1717udv xc342km x1kogg8i xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk`,onClick:()=>a(!1),children:(0,G.jsx)(mt,{size:13})})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1af02g3`,children:[(0,G.jsx)(`div`,{className:`x1ruevkc xmkeg23 x1y0btm7 x12xov25 x1q4ynmn xqm9i1m x2lah0s xrvj5dj x1ku5rj1`,children:(0,G.jsx)(Gm,{bgColor:`#ffffff`,bordered:!1,color:`#141416`,size:108,value:e.url})}),(0,G.jsxs)(`div`,{className:`x78zum5 xdt5ytf x167g77z xeuugli x98rzlu`,children:[(0,G.jsx)(`p`,{className:`x1ghz6dp x1qt5hsa x1jjo3f5 x1bo0w0s`,children:r(`cloudIntent.qrDesc`)}),(0,G.jsx)(`div`,{children:(0,G.jsx)(Ye,{icon:(0,G.jsx)(wo,{size:12}),size:`small`,onClick:()=>void c(),children:r(o?`cloudIntent.copied`:`cloudIntent.copyPhoneLink`)})})]})]}),e.billingUrl?(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x1jw0pk6 xhpnuu7 x1xrkum6 x1qt5hsa`,children:[(0,G.jsx)(`span`,{className:`x1bo0w0s xfrs9s4`,children:r(`cloudIntent.proRelayHint`)}),(0,G.jsxs)(`a`,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 xd7y6wv x1awh872 x1kogg8i x15az74h x12s0oaj xt9vybz x1qt5hsa xh88oxj x1hl2dhg xuxw1ft x2lah0s`,children:[r(`cloudIntent.proRelayCta`),` ↗`]})]}):null]}):null,(0,G.jsxs)(m_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[e.intent===`share`?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(h_,{limit:380,tone:`success`,children:e.copied?r(`cloudIntent.toastShareCopied`,{login:e.login}):r(`cloudIntent.toastShare`,{login:e.login})}),(0,G.jsx)(v_,{variant:`quiet`,onClick:n,children:r(`cloudIntent.changeAccess`)}),e.url?(0,G.jsxs)(__,{href:e.url,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudIntent.openLink`),` ↗`]}):null]}):e.intent===`phone`?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(h_,{limit:360,tone:`success`,children:r(`cloudIntent.toastPhone`)}),e.billingUrl?(0,G.jsx)(__,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`quiet`,children:r(`cloudIntent.learnRelay`)}):null,e.url?(0,G.jsx)(v_,{variant:`primary`,onClick:()=>a(e=>!e),children:r(i?`cloudIntent.hideQr`:`cloudIntent.showQr`)}):null]}):(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(h_,{limit:380,tone:`success`,children:r(`cloudIntent.toastSync`,{login:e.login})}),(0,G.jsx)(v_,{variant:`quiet`,onClick:Dg,children:r(`cloudIntent.projectConfig`)}),e.dashboardUrl?(0,G.jsxs)(__,{href:e.dashboardUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudEntry.openShort`),` ↗`]}):null]}),(0,G.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xgd8bvy x1fgtraw x1717udv xc342km x1e6avla xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk x2lah0s`,onClick:()=>{a(!1),t()},children:(0,G.jsx)(mt,{size:13})})]})]})}var $={trigger:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kZKoxP:`x1gnnpzl`,kg3NbH:`x1awh872`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kaIpWk:`xur7f20`,kWkggS:`x12ilycc xj0l527`,kMwMTN:`xo2rkog`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,kkrTdU:`x1ypdohk`,khDVqt:`xuxw1ft`,$$css:!0},shellCta:{kZKoxP:`x1fgtraw`,kZCmMZ:`xe2zdcy`,kwRFfy:`xpdmqnj`,kaIpWk:`x1e6avla`,kVAM5u:`x1rqon0r`,kWkggS:`x19ckca5 x1et1poy`,kMwMTN:`xs0jrwl`,k63SB2:`xk50ysn`,$$css:!0},brandDot:{kzqmXN:`x1v4s8kt`,kZKoxP:`xols6we`,kaIpWk:`x16rqkct`,kWkggS:`x1iug7pk`,kmuXW:`x2lah0s`,$$css:!0},floating:{kVAEAm:`xixxii4`,k87sOh:`x1tk7jg1`,kCIrl2:`xlftelb`,kY2c9j:`x1n327nk`,kGVxlE:`x1cqdj14`,$$css:!0},dot:{kzqmXN:`x1v4s8kt`,kZKoxP:`xols6we`,kaIpWk:`x16rqkct`,kWkggS:`xzkukvh`,$$css:!0},panel:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x1v2ro7d`,kzqmXN:`x1m258z3`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,$$css:!0},row:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kjj79g:`x1qughib`,kOIVth:`x167g77z`,$$css:!0},muted:{kMwMTN:`x1bo0w0s`,kLWn49:`x1dbl2gt`,$$css:!0},link:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,kMv6JI:`x1fao0z8`,kGuDYH:`x1j6dyjg`,kMwMTN:`x9f21nr`,$$css:!0},textButton:{kmVPX3:`x1717udv`,kMzoRj:`xc342km`,kWkggS:`xjbqb8w`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,kkrTdU:`x1ypdohk`,$$css:!0},danger:{kMwMTN:`x12vcgws`,$$css:!0},error:{kogj98:`x1ghz6dp`,kZCmMZ:`xwn43p0`,kMwMTN:`x12vcgws`,kLWn49:`x1dbl2gt`,$$css:!0},warning:{kMwMTN:`x7zghnd`,$$css:!0}};async function b_(e,t){let n=await fetch(`/api/artifacts`,{cache:`no-store`}).catch(()=>null);return n?.ok?(await n.json().catch(()=>null))?.artifacts?.find(n=>n.type===e&&n.id===t)?.title??null:null}function x_(e,t,n,r){let i=e?.id?`${e.type}/${e.id}`:null,[a,o]=(0,K.useState)(null);if((0,K.useEffect)(()=>{if(!e?.id||!i)return;let t=!1;return b_(e.type,e.id).then(e=>{!t&&e&&o({key:i,text:e})}),()=>{t=!0}},[i]),!e||!i)return null;let s=eg(t?.artifacts[i]),c=s.published?s.visibility:`unpublished`;return{key:i,card:{type:e.type,title:a?.key===i?a.text:e.id,state:c,rootVisibility:n,url:s.published?s.url:null,uses:r.find(e=>e.artifact===i)?.uses??null},hidden:zg(n,c)}}var S_=800;function C_(e,t){let[n,r]=(0,K.useState)(null),i=(0,K.useCallback)(async()=>{if(!t)return;let n=await Z(`GET`,`sync/${e}`);n.ok&&r(typeof n.json.upToDate==`boolean`?n.json.upToDate:null)},[e,t]);return(0,K.useEffect)(()=>{if(!t){r(null);return}i();let n,a=bo(t=>{t.artifact!==e||t.type!==`change`&&t.type!==`cloud-published`||(clearTimeout(n),n=setTimeout(()=>void i(),S_))});return()=>{clearTimeout(n),a()}},[e,t,i]),{upToDate:n,refresh:i}}function w_(e,t){let[n,r]=(0,K.useState)(null);return(0,K.useEffect)(()=>{if(!t){r(null);return}let n=!1,i=0,a=async()=>{let t=++i,a=await Z(`GET`,`publication/${e}`),o=a.ok&&Zh(a.json);!n&&t===i&&o&&r(o)};a();let o=bo(t=>{t.artifact===e&&(t.type===`cloud-publication`&&(i++,r(t.publication)),(t.type===`change`||t.type===`cloud-published`)&&a())});return()=>{n=!0,o()}},[e,t]),n}var T_=e=>e.json.results??null;function E_(e){let[t,n]=(0,K.useState)([]),[r,i]=(0,K.useState)(null),[a,o]=(0,K.useState)([]),[s,c]=(0,K.useState)(null),[l,u]=(0,K.useState)(!1);return{refs:t,results:r,referrers:a,referrerResults:s,cloudUnavailable:l,load:(0,K.useCallback)(async()=>{let t=await Z(`GET`,`refs/${e}`);t.ok&&(Array.isArray(t.json.items)&&n(t.json.items),o(Array.isArray(t.json.referrers)?t.json.referrers:[]),u(t.json.cloudUnavailable===!0))},[e]),publishRefs:async(t,n,r,a)=>{if(!t){let t=await Z(`POST`,`publish/${e}`);if(!t.ok)return t}let o=await Z(`POST`,`publish-refs/${e}`,{visibility:n,refs:r,makePublic:a});return o.ok&&i(T_(o)),o},publishReferrers:async(t,n)=>{let r=await Z(`POST`,`publish-referrers/${e}`,{publish:t,makePublic:n});return r.ok&&c(T_(r)),r}}}var D_={private:`publish.hintPrivate`,public:`publish.hintPublic`};function O_({artifact:e,floating:t=!1,shell:n=!1}){let{t:r,i18n:i}=x(),{status:a,refresh:o,login:s,waitingForLogin:c}=fg(),l=Se(),[u,d]=(0,K.useState)(!1),[f,p]=(0,K.useState)(!1),[m,h]=(0,K.useState)([]),[g,_]=(0,K.useState)(null),[v,y]=(0,K.useState)(null),[b,C]=(0,K.useState)(null),w=(0,K.useRef)(!1),T=a?.artifacts?.[e],E=eg(T),D=w_(e,!!a?.signedIn),O=D&&Xh(D.phase),[k]=_g(),A=E.url?gg(E.url,k):null,j=C_(e,!!a?.signedIn&&E.published),ee=tg(j.upToDate,!!a?.autoPublish?.enabled&&T?.autoPublish!==!1),M=E_(e),{refs:te,referrers:N}=M,P=async e=>{p(!0),h([]),_(null);let t=await e();if(`shareKey`in t.json&&y(t.ok?t.json.shareKey:null),t.status===401)s(t.json.loginUrl);else if(!t.ok){t.json.code===`plan_required`&&typeof t.json.upgradeUrl==`string`&&_(t.json.upgradeUrl);let e=Array.isArray(t.json.reasons)?t.json.reasons:[];h([Cg(t.json,r(`common.requestFailed`,{status:t.status})),...e])}await Promise.all([o(),j.refresh(),M.load()]),p(!1)},ne=!E.published&&te.some(e=>e.checked),re=E.published?E.visibility:null,ie=x_(l.role===`primary`?l.other:null,a,re,N),F=t=>P(()=>Z(`POST`,`visibility/${e}`,{visibility:t})),ae=(t={})=>P(()=>Z(`PUT`,`share-key/${e}`,t)),I=async t=>{if(d(t),t&&a?.signedIn&&M.load(),t&&a?.signedIn&&E.published){if(j.refresh(),E.access===`key`){let t=await Z(`GET`,`share-key/${e}`);t.ok&&y(t.json.shareKey)}(await Z(`GET`,`artifacts`)).ok&&await o()}},oe=t=>{o_(e,t),s()};(0,K.useEffect)(()=>{if(!a?.signedIn||!a.login||w.current)return;let t=s_(e);if(!t)return;w.current=!0;let n=a.login,i=a.origin;(async()=>{d(!1),p(!0),h([]),_(null);try{if(t===`sync`){let a=await Z(`POST`,`auto-publish`,{scope:`global`,value:!0});if(!a.ok){C({intent:t,login:n,url:null,dashboardUrl:Pg(i),billingUrl:Ig(i),error:Cg(a.json,r(`common.requestFailed`,{status:a.status}))});return}Z(`POST`,`publish/${e}`),await o(),C({intent:t,login:n,url:null,dashboardUrl:Pg(i),billingUrl:Ig(i)});return}let a=await Z(`POST`,`publish/${e}`),s=await o();if(await Promise.all([j.refresh(),M.load()]),!a.ok){a.json.code===`plan_required`&&typeof a.json.upgradeUrl==`string`&&_(a.json.upgradeUrl);let e=Array.isArray(a.json.reasons)?a.json.reasons:[],o=Cg(a.json,r(`common.requestFailed`,{status:a.status}));h([o,...e]),C({intent:t,login:n,url:null,dashboardUrl:Pg(i),billingUrl:Ig(i),error:o});return}let c=eg(s?.artifacts?.[e]).url??(typeof a.json.url==`string`?a.json.url:null),l=c?gg(c,k):null,u=!1;if(t===`share`&&l)try{await navigator.clipboard.writeText(l),u=!0}catch{u=!1}C({intent:t,login:n,url:l,copied:u,dashboardUrl:Pg(i),billingUrl:Ig(i)})}finally{p(!1),w.current=!1}})()},[e,a?.signedIn,a?.login,a?.origin,k,o]);let se=Ng(a?.origin,i.language),ce=Pg(a?.origin),le=a?a.signedIn?(0,G.jsxs)(`div`,{...S($.panel),children:[(0,G.jsxs)(`div`,{...S($.row),children:[(0,G.jsx)(`span`,{...S($.muted),children:r(`publish.signedInAs`,{login:a.login})}),(0,G.jsx)(`button`,{type:`button`,...S($.textButton),onClick:()=>void P(()=>Z(`POST`,`logout`)),children:r(`publish.signOut`)})]}),(0,G.jsx)(r_,{foot:r(D_[E.visibility]),saving:f,url:A,visibility:E.visibility,beside:ie?{...ie.card,busy:f,onVisibility:e=>void P(()=>Z(`POST`,`visibility/${ie.key}`,{visibility:e})),onPublish:()=>void P(()=>Z(`POST`,`publish/${ie.key}`,{visibility:E.visibility}))}:null,cascade:{items:te,rootVisibility:E.visibility,busy:f,results:M.results,includeRoot:!E.published,onPublish:(e,t)=>void P(()=>M.publishRefs(E.published,E.visibility,e,t))},profile:E.published?{shown:E.onProfile,path:a.login?`/u/${a.login}`:null,onChange:t=>void P(()=>Z(`POST`,`profile/${e}`,{shown:t}))}:null,referrers:{items:N,exclude:ie?.key,rootVisibility:re,busy:f,cloudUnavailable:M.cloudUnavailable,results:M.referrerResults,onPublish:(e,t)=>void P(()=>M.publishReferrers(e,t))},shareKey:{active:E.access===`key`,value:v,onSelect:()=>void ae(),onExpiry:e=>void ae({expires:e}),onRegenerate:()=>void ae({regenerate:!0}),onRemove:()=>void P(()=>Z(`DELETE`,`share-key/${e}`))},status:(0,G.jsx)(Rg,{online:!0,busy:f,publication:D,published:E.published,publishedAt:T?.cloud?.publishedAt,onPublish:ne?void 0:()=>void P(()=>Z(`POST`,`publish/${e}`))}),onVisibility:e=>void F(e)}),ee?(0,G.jsx)(`span`,{...S(j.upToDate?$.muted:$.warning),children:r(`publish.${ee}`)}):null,E.synced?null:(0,G.jsxs)(`div`,{...S($.row,$.warning),children:[(0,G.jsx)(`span`,{children:r(`publish.visibilityNotSynced`)}),(0,G.jsx)(Ye,{disabled:f,size:`small`,onClick:()=>void F(E.visibility),children:r(`publish.sync`)})]}),m.length>0?(0,G.jsx)(`ul`,{...S($.error),children:m.map(e=>(0,G.jsx)(`li`,{children:e},e))}):null,g?(0,G.jsx)(`a`,{"data-upgrade":``,href:g,rel:`noreferrer`,target:`_blank`,...S($.textButton),children:r(`share.seePlans`)}):null,E.published&&(!D||D.phase===`published`)?(0,G.jsx)(Ye,{loading:f||!!O,type:`primary`,onClick:()=>void P(()=>Z(`POST`,`publish/${e}`)),children:r(`publish.update`)}):null,E.published?(0,G.jsx)(`button`,{disabled:f,type:`button`,...S($.textButton,$.danger),onClick:()=>void P(()=>Z(`DELETE`,`publish/${e}`)),children:r(`publish.unpublish`)}):null,E.published&&a.autoPublish?.enabled?(0,G.jsx)(`span`,{...S($.muted),children:r(`publish.autoPublishNote`)}):null,(0,G.jsxs)(`div`,{...S($.row,$.muted),children:[(0,G.jsx)(`span`,{children:r(`settings.menuStatus`,{state:a.autoPublish?.enabled?r(`settings.on`):r(`settings.off`)})}),(0,G.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:10},children:[ce?(0,G.jsxs)(`a`,{href:ce,rel:`noopener noreferrer`,target:`_blank`,...S($.textButton),children:[r(`cloudEntry.openShort`),` `,(0,G.jsx)(Co,{"aria-hidden":`true`,size:11})]}):null,(0,G.jsx)(`button`,{type:`button`,...S($.textButton),onClick:Dg,children:r(`publish.openSettings`)})]})]})]}):(0,G.jsx)(f_,{landingUrl:se,origin:a.origin,waitingForLogin:c,onStartIntent:oe}):(0,G.jsx)(`div`,{...S($.panel,$.muted),children:r(`publish.readingStatus`)});if(l.role===`beside`||rt())return null;let ue=n&&!!a&&!a.signedIn;return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Jt,{content:le,open:u,placement:`bottomRight`,popupProps:{"aria-label":r(`common.share`)},trigger:`click`,onOpenChange:e=>void I(e),children:(0,G.jsxs)(`button`,{"aria-label":`Share`,"data-cloud-shell-cta":ue?``:void 0,type:`button`,...S($.trigger,t&&$.floating,ue&&$.shellCta),children:[ue?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,...S($.brandDot)}),r(`cloudEntry.shellCta`)]}):(0,G.jsxs)(G.Fragment,{children:[E.published&&E.visibility===`public`?(0,G.jsx)(ct,{size:14}):(0,G.jsx)(To,{size:14}),E.published?r(`publish.published`):r(`common.share`)]}),D&&D.phase!==`published`?(0,G.jsx)(Rg,{compact:!0,publication:D,published:E.published}):null,j.upToDate===!1?(0,G.jsx)(`span`,{"aria-label":r(`publish.unpublishedChanges`),...S($.dot)}):null,ie?.hidden?(0,G.jsx)(`span`,{"aria-label":r(`beside.hidden`),"data-beside-dot":``,...S($.dot)}):null]})}),b?(0,G.jsx)(y_,{result:b,onDismiss:()=>C(null),onOpenSharePanel:()=>{C(null),I(!0)}}):null]})}function k_(e,t){let{band:n,front:r,echo:i}=t instanceof Element?{band:t,front:null,echo:null}:t,a=e.parentElement?.closest(`a, button`)??e,o=window.matchMedia(`(prefers-reduced-motion: reduce)`),s=[],c=()=>{if(o.matches||s.length>0)return;let{sweep:e,trace:t}=l,a=[];if(r){let e=typeof r.getTotalLength==`function`?r.getTotalLength():t.frontLength;r.style.strokeDasharray=`${e}`,a.push(r.animate([{strokeDashoffset:e},{strokeDashoffset:0}],{duration:t.frontDuration,easing:t.easing}))}if(i){let e=typeof i.getTotalLength==`function`?i.getTotalLength():t.echoLength;i.style.strokeDasharray=`${e}`,a.push(i.animate([{strokeDashoffset:e,opacity:.15},{strokeDashoffset:0,opacity:.38}],{duration:t.echoDuration,delay:t.echoDelay,easing:t.easing,fill:`backwards`}))}let c=n.animate([{transform:e.from},{transform:e.to}],{duration:e.duration,delay:r?e.delay:0,easing:e.easing});a.push(c),s=a;let u=a.length,d=()=>{--u,u<=0&&(s=[],r&&(r.style.strokeDasharray=``),i&&(i.style.strokeDasharray=``))};for(let e of a)e.onfinish=d,e.oncancel=d},u=()=>{a.matches(`:focus-visible`)&&c()};return a.addEventListener(`pointerenter`,c),a.addEventListener(`focus`,u),()=>{a.removeEventListener(`pointerenter`,c),a.removeEventListener(`focus`,u);for(let e of s)e.cancel();s=[]}}function A_({ink:e,seal:t,forMask:n=!1,frontRef:r,echoRef:i}){return(0,G.jsxs)(G.Fragment,{children:[!n&&(0,G.jsxs)(`g`,{opacity:.14,pointerEvents:`none`,transform:l.markTransform,children:[(0,G.jsx)(`path`,{d:`M14.5 22L22.8 6.8C23.4 5.7 24.6 5.7 25.2 6.8L33.5 22`,fill:`none`,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:3.2}),(0,G.jsx)(`path`,{d:`M9.5 40.5L22.2 14.8C23 13.2 25 13.2 25.8 14.8L38.5 40.5`,fill:`none`,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:4.4})]}),(0,G.jsxs)(`g`,{transform:l.markTransform,children:[(0,G.jsx)(`path`,{d:m,fill:`none`,opacity:n?1:.38,ref:i,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:3.2}),(0,G.jsx)(`path`,{d:_,fill:`none`,ref:r,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:4.4}),(0,G.jsx)(`circle`,{cx:p.cx,cy:p.cy,r:p.r,stroke:`none`,...t})]}),(0,G.jsxs)(`g`,{transform:l.wordTransform,children:[(0,G.jsx)(`path`,{d:l.path,fill:e,fillRule:`nonzero`}),(0,G.jsx)(`circle`,{cx:l.seal.cx,cy:l.seal.cy,r:l.seal.r,stroke:`none`,...t})]})]})}function j_({height:e=22,title:t,contextMenu:n=!0}){let{t:r}=x(),i=d((0,K.useId)()),a=(0,K.useRef)(null),o=(0,K.useRef)(null),s=(0,K.useRef)(null),c=(0,K.useRef)(null);(0,K.useEffect)(()=>k_(a.current,{band:o.current,front:s.current,echo:c.current}),[]);let u=async(e,t)=>{try{await navigator.clipboard.writeText(b(e)),rn.success(r(t))}catch{rn.error(r(`brand.copyFailed`))}},f=e=>{n&&(e.preventDefault(),e.stopPropagation(),Xt([{key:`copy-svg`,label:r(`brand.copySvg`),icon:wo,onClick:()=>void u(`lockup`,`brand.copiedSvg`)},{key:`copy-logo-svg`,label:r(`brand.copyLogoSvg`),icon:tt,onClick:()=>void u(`mark`,`brand.copiedLogoSvg`)},{key:`copy-text-svg`,label:r(`brand.copyTextSvg`),icon:Qe,onClick:()=>void u(`wordmark`,`brand.copiedTextSvg`)}]))},p=`${i}-mask`,m=`${i}-ember`;return(0,G.jsxs)(`svg`,{fill:`none`,ref:a,...t?{role:`img`,"aria-label":t}:{"aria-hidden":!0},height:e,viewBox:l.viewBox,width:Math.round(e*l.width/l.height*100)/100,onContextMenu:n?f:void 0,className:`x1lliihq x2lah0s`,children:[(0,G.jsxs)(`defs`,{children:[(0,G.jsx)(`linearGradient`,{id:m,children:l.bandStops.map(e=>(0,G.jsx)(`stop`,{offset:e.offset,stopColor:e.color,stopOpacity:e.opacity},e.offset))}),(0,G.jsx)(`mask`,{id:p,maskUnits:`userSpaceOnUse`,...l.mask,children:(0,G.jsx)(A_,{forMask:!0,ink:`#fff`,seal:{fill:`#fff`}})})]}),(0,G.jsx)(A_,{echoRef:c,frontRef:s,ink:`currentColor`,seal:{className:`xe8yr7n x1tl3b4t`}}),(0,G.jsx)(`g`,{mask:`url(#${p})`,pointerEvents:`none`,children:(0,G.jsx)(`rect`,{fill:`url(#${m})`,ref:o,...l.band})})]})}var M_=e=>`/api/avatar/github/${e}`,N_=e=>{e&&window.open(e,`_blank`,`noopener,noreferrer`)};function P_({compact:e=!1,status:t,waitingForLogin:n,onSignIn:r,onSignOut:i}){let{t:a,i18n:o}=x();if(!t)return null;if(!t.signedIn||!t.login){let e=Ng(t.origin,o.language),i=(0,G.jsxs)(`div`,{"data-cloud-connect-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x1m258z3 xqfszdh xfifm61 xo2rkog`,children:[(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,G.jsxs)(`span`,{className:`x3nfvp2 x6s0dn4 x1j9xkj6 x4z9k3i x1s688f`,children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`x17z2i9w x17rw0jw x1kogg8i x6z2zk2 x1cge3fn xrvj5dj x1ku5rj1 x2lah0s`,children:(0,G.jsx)(Go,{size:13})}),a(`cloudEntry.connectTitle`)]}),(0,G.jsx)(`span`,{className:`x1j6dyjg xddlp02`,children:a(`cloudEntry.freeStart`)})]}),(0,G.jsxs)(`div`,{className:`x78zum5 xdt5ytf x17d4w8g`,children:[(0,G.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,G.jsx)(ke,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,G.jsxs)(`div`,{children:[(0,G.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitShareTitle`)}),(0,G.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitShareBody`)})]})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,G.jsx)(ss,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,G.jsxs)(`div`,{children:[(0,G.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitPhoneTitle`)}),(0,G.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitPhoneBody`)})]})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,G.jsx)(Eo,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,G.jsxs)(`div`,{children:[(0,G.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitSyncTitle`)}),(0,G.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitSyncBody`)})]})]})]}),(0,G.jsx)(Ye,{className:{className:`xh8yej3 x90ne7k x3nfvp2 x6s0dn4 xl56j7k x1j9xkj6 xc342km xur7f20 x15az74h x12s0oaj xt9vybz xqfszdh x1ct8sxb xh88oxj x1ypdohk`}.className,icon:vo,loading:n,type:`primary`,onClick:r,children:a(n?`settings.waitingLogin`:`common.signInGithub`)}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1nejdyq x1j6dyjg xddlp02 xfrs9s4`,children:[(0,G.jsx)(To,{"aria-hidden":`true`,size:11}),(0,G.jsx)(`span`,{children:a(`cloudEntry.privateByDefault`)})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,G.jsx)(c_,{origin:t.origin}),e?(0,G.jsxs)(`a`,{href:e,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[a(`cloudEntry.learnShort`),(0,G.jsx)(Co,{"aria-hidden":`true`,size:11})]}):null]})]});return(0,G.jsx)(Jt,{content:i,placement:`bottomRight`,popupProps:{"aria-label":a(`cloudEntry.connectTitle`)},trigger:`click`,children:(0,G.jsxs)(`button`,{"data-cloud-connect-cta":``,type:`button`,className:`x3nfvp2 x6s0dn4 x1j9xkj6 x1gnnpzl xe2zdcy xpdmqnj xmkeg23 x1y0btm7 x1rqon0r x1e6avla x19ckca5 x1et1poy xs0jrwl xqfszdh xfifm61 xk50ysn xuxw1ft x1ypdohk xlee54d x784prv x9v5kkp xv8siiq x7s97pk`,children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct x1iug7pk x2lah0s`}),(0,G.jsx)(`span`,{children:a(`cloudEntry.connectCta`)}),(0,G.jsx)(`span`,{className:`x1pixwil xpilrb4 x1t7ytsu x13ft1s6 x1j6dyjg xo1l8bm xf9vgkq xy0uqqd`,children:a(`cloudEntry.connectHint`)})]})})}let s=t.login,c=Pg(t.origin);return(0,G.jsxs)(G.Fragment,{children:[!e&&c?(0,G.jsxs)(`a`,{"data-cloud-header-link":``,href:c,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1nejdyq x1fgtraw xdqyycr x1kogg8i xjbqb8w xj0l527 x1bo0w0s xytdrwj xfifm61 xk50ysn x1hl2dhg xuxw1ft x1gz44f`,children:[(0,G.jsx)(Go,{"aria-hidden":`true`,size:13}),(0,G.jsx)(`span`,{children:`Cloud`}),(0,G.jsx)(Co,{"aria-hidden":`true`,size:12})]}):null,(0,G.jsx)(Gt,{items:[{key:`status`,disabled:!0,label:`${s} · ${a(`settings.menuStatus`,{state:t.autoPublish?.enabled?a(`settings.on`):a(`settings.off`)})}`},{type:`divider`,key:`cloud-divider`},{key:`open-cloud`,icon:Go,label:a(`cloudEntry.openCloud`),extra:`↗`,onClick:()=>N_(c)},{key:`public-profile`,icon:ct,label:a(`cloudEntry.publicProfile`),extra:`/u/${s} ↗`,onClick:()=>N_(Fg(t.origin,s))},{key:`plans`,icon:Yo,label:a(`cloudEntry.plans`),extra:`↗`,onClick:()=>N_(Ig(t.origin))},{type:`divider`,key:`settings-divider`},{key:`settings`,icon:as,label:a(`settings.open`),onClick:Dg},{key:`sign-out`,icon:$o,label:a(`settings.signOut`),onClick:()=>void i?.()}],children:(0,G.jsx)(`button`,{"aria-label":a(`settings.accountMenu`,{login:s}),type:`button`,className:`x78zum5 x1717udv xc342km x16rqkct xjbqb8w x1ypdohk x1hl8ikr`,children:(0,G.jsx)(Vd,{alt:``,avatar:M_(s),shape:`circle`,size:28,className:`xs625wh`})})})]})}var F_=(0,K.createContext)(!1),I_=(0,K.createContext)(null),L_=F_.Provider,R_=I_.Provider,z_=()=>typeof window<`u`&&window.parent!==window&&we()&&!rt();function B_(){return(0,K.useContext)(F_)||z_()}function V_(){return(0,K.useContext)(I_)}function H_({type:e,id:t,docHeader:n,children:r}){let{t:i}=x(),a=fg(),[o,s]=(0,K.useState)(t),[c,l]=(0,K.useState)(null),d=`${e}/${t}`;(0,K.useEffect)(()=>{s(t);let e=()=>{let e=document.title?.trim();e&&e!==`Ryugi`&&e!==`Artifacts · Artideck`&&s(e)};e();let n=document.querySelector(`title`);if(!n||typeof MutationObserver>`u`)return;let r=new MutationObserver(e);return r.observe(n,{childList:!0,characterData:!0,subtree:!0}),()=>r.disconnect()},[t,e]);let f=!!a.status?.signedIn&&!!a.status.login;return(0,G.jsxs)(`div`,{"data-local-shell":``,className:`xixxii4 x10a8y8t x78zum5 xdt5ytf x184qs1t`,children:[(0,G.jsxs)(`header`,{"data-local-shell-bar":``,className:`x1okw0bk x78zum5 x6s0dn4 x1qughib xou54vl x1otypdl xn3w4p2 xqin4a2 xwbbzrz xso031l x1q0q8m5 xtrfj0v x1rozbrz xo2rkog xqfszdh x1ct8sxb x1n2onr6 x1355qak`,children:[(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x883omv xeuugli x98rzlu`,children:[(0,G.jsx)(`a`,{"aria-label":i(`localShell.backToList`),href:`/`,className:`x3nfvp2 x6s0dn4 x2lah0s xo2rkog x12rs2w1 x1hl2dhg x1sxf85j`,children:(0,G.jsx)(j_,{height:19})}),(0,G.jsxs)(`nav`,{"aria-label":i(`localShell.breadcrumb`),className:`x78zum5 x6s0dn4 x167g77z xeuugli x1ct8sxb xuxw1ft`,children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s`,children:`/`}),(0,G.jsx)(`span`,{className:`x1bo0w0s x2lah0s xt0psk2 xkaaz9w`,children:i(`type.${e}`)}),(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s xt0psk2 xkaaz9w`,children:`/`}),(0,G.jsx)(`span`,{title:o,className:`xeuugli xb3r6kr xlyipyv x1s688f xo2rkog`,children:o})]})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x167g77z x2lah0s`,children:[(0,G.jsx)(`div`,{ref:l,className:`xjp7ctv`}),u(e)&&n?.header?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Oe,{available:n.header.history,comments:n.header.comments,open:n.header.historyOpen,onComments:()=>n.history(`close`),onHistory:()=>n.history(`toggle`)}),(0,G.jsx)(So,{state:n.header.documentExport,onExport:n.exportPdf}),(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})]}):null,a.status&&!f?(0,G.jsxs)(`span`,{"data-local-only-badge":``,className:`x3nfvp2 xkaaz9w x6s0dn4 x1nejdyq x1qt5hsa xddlp02 xuxw1ft`,children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct xvndefy x1y0btm7 xhgr6co x9f619 x2lah0s`}),i(`server.localOnly`)]}):null,(0,G.jsx)(O_,{shell:!0,artifact:d}),f?(0,G.jsx)(P_,{compact:!0,status:a.status,waitingForLogin:a.waitingForLogin,onSignIn:()=>void a.login(),onSignOut:async()=>{await Z(`POST`,`logout`),await a.refresh()}}):(0,G.jsx)(`button`,{"aria-label":i(`settings.title`),title:i(`settings.title`),type:`button`,className:`xrvj5dj x1ku5rj1 xgd8bvy x1fgtraw x1717udv xc342km x1kogg8i xjbqb8w xj0l527 x1bo0w0s xytdrwj x1ypdohk x2lah0s`,onClick:Dg,children:(0,G.jsx)(as,{"aria-hidden":`true`,size:14})})]})]}),(0,G.jsx)(`div`,{className:`x1n2onr6 x98rzlu x2lwn1j x78zum5 xdt5ytf xb3r6kr`,children:(0,G.jsx)(L_,{value:!0,children:(0,G.jsx)(R_,{value:c,children:r})})})]})}var U_=1e3,W_=`ryugi:embed:hello`,G_=`ryugi:embed:heartbeat`,K_=`ryugi:embed:painted`,q_=`ryugi:embed:position`,J_=`ryugi:embed:positioned`;function Y_({parentOrigin:e,onPosition:t,win:n=window}){let r=(t,r)=>n.parent.postMessage({type:t,...r},e),i=i=>{if(i.origin!==e||i.source!==n.parent)return;let a=i.data;a?.type===q_&&a.anchor&&t&&t(a.anchor).then(()=>r(J_))};n.addEventListener(`message`,i),r(W_,t?{position:!0}:void 0);let a=setInterval(()=>r(G_),U_),o=!1;return{painted(){o||(o=!0,r(K_))},close(){clearInterval(a),n.removeEventListener(`message`,i)}}}function X_(e=document,t=window,n){let r=e.documentElement.dataset.ryugiEmbedParent;return r?Y_({parentOrigin:r,onPosition:n,win:t}):null}var Z_=()=>new Promise(e=>requestAnimationFrame(()=>requestAnimationFrame(()=>e()))),Q_=e=>(Ze(e),Z_()),$_=(0,K.createContext)(()=>{});function ev(){let e=(0,K.useRef)(null),t=(0,K.useRef)(!1);return(0,K.useEffect)(()=>{let n=X_(document,window,Q_);return e.current=n,t.current&&n?.painted(),()=>{n?.close(),e.current=null}},[]),(0,K.useCallback)(()=>{t.current=!0,e.current?.painted()},[])}function tv(e){let t=(0,K.useContext)($_);(0,K.useEffect)(()=>{if(!e)return;let n=0,r=requestAnimationFrame(()=>{n=requestAnimationFrame(()=>{t(),et()&&D({kind:`painted`})})});return()=>{cancelAnimationFrame(r),cancelAnimationFrame(n)}},[e,t])}function nv(e=window){try{let t=e.parent,n=new URLSearchParams(e.location.search).get(`at`);if(t!==e&&t.location.origin===e.location.origin&&/^\/whiteboard\/[^/]+\/?$/.test(t.location.pathname)&&t.location.pathname===n)return t}catch{}return e}var rv={artboard:{Layout:(0,K.lazy)(()=>r(async()=>{let{ArtboardLayout:e}=await import(`./ArtboardLayout-CWx1_DVU.js`);return{ArtboardLayout:e}},__vite__mapDeps([20,1,21,22,4,23,16,2,3,5,6,7,17,13,18,24,25,26,27,28,29,30,11,12,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,19,51,52,53,54,55,10,56,57,58,59,60,61,15,8,9,62,63,64,65]),import.meta.url).then(({ArtboardLayout:e})=>({default:e})))},document:{Layout:(0,K.lazy)(()=>r(async()=>{let{DocumentLayout:e}=await import(`./DocumentLayout-CJ59MGXp.js`);return{DocumentLayout:e}},__vite__mapDeps([66,1,4,5,2,3,6,7]),import.meta.url).then(({DocumentLayout:e})=>({default:e})))},html:{Layout:(0,K.lazy)(()=>r(async()=>{let{HtmlLayout:e}=await import(`./HtmlLayout-vlPq4J9Y.js`);return{HtmlLayout:e}},__vite__mapDeps([67,1,21,22,4,23,16,2,3,5,6,7,17,13,18,68,27,47,69,56,57]),import.meta.url).then(({HtmlLayout:e})=>({default:e})))},whiteboard:{Layout:(0,K.lazy)(()=>r(async()=>{let{WhiteboardLayout:e}=await import(`./WhiteboardLayout-Dd8Uh61C.js`);return{WhiteboardLayout:e}},__vite__mapDeps([70,1,22,4,23,16,2,3,5,6,7,17,13,18,71,72,73,27,19,42,74,37,75,76,52,32,53,38,77,46,78,10,31,11,12,49,50,39,40,47,58,79,63,80,44,45,81,82,83]),import.meta.url).then(({WhiteboardLayout:e})=>({default:e}))),embedIn:e=>(0,G.jsx)(mg,{pageWindow:nv(),children:e})},verify:{Layout:(0,K.lazy)(()=>r(async()=>{let{VerifyLayout:e}=await import(`./VerifyLayout-Usn3NkOU.js`);return{VerifyLayout:e}},__vite__mapDeps([84,1,16,2,3,4,5,6,7,17,13,18,22,23,85,86,73,27,19,42,74,37,75,76,52,32,53,38,77,46,78,40,87,88,89,90,81,91,49,50,39,12,47,92,28,93,94,11,80,25,10,8,9,79,95,69,96,59,60,30,97,98]),import.meta.url).then(({VerifyLayout:e})=>({default:e})))},slides:{Layout:(0,K.lazy)(()=>r(async()=>{let{SlidesLayout:e}=await import(`./SlidesLayout-8j14xYA-.js`);return{SlidesLayout:e}},__vite__mapDeps([99,1,21,22,4,23,16,2,3,5,6,7,17,13,18,100,95,72,69,56,57,30,68,27,47,10,49,50,39,40,12,35,36,37,38,41,42,43,76,81,88,45,46,55,77,32,63,9,15,19,101,53,54,91,28,102,8,58,94,103,104,26,105]),import.meta.url).then(({SlidesLayout:e})=>({default:e}))),bare:e=>new URLSearchParams(e).has(`live`)},report:{Layout:(0,K.lazy)(()=>r(async()=>{let{ReportLayout:e}=await import(`./ReportLayout-BD1bNPfi.js`);return{ReportLayout:e}},__vite__mapDeps([106,1,21,22,4,23,16,2,3,5,6,7,17,13,18,68,27,47,69,56,57,30,81,10,36,37,49,50,39,40,12,62,90,54,92]),import.meta.url).then(({ReportLayout:e})=>({default:e})))},storyboard:{Layout:(0,K.lazy)(()=>r(async()=>{let{StoryboardLayout:e}=await import(`./StoryboardLayout-zpUwF5xF.js`);return{StoryboardLayout:e}},__vite__mapDeps([107,1,4,21,22,23,16,2,3,5,6,7,17,13,18,108,30,69,68,27,47,56,57,39,40,109,54,94,26,49,50,12,81,93,103,15,28,41,42,45,46,36,37,75,77,32,33,34,43,53,61]),import.meta.url).then(({StoryboardLayout:e})=>({default:e})))}},iv=(0,K.lazy)(()=>r(async()=>{let{StoryboardRenderLayout:e}=await import(`./StoryboardRender--NOzkhyN.js`);return{StoryboardRenderLayout:e}},__vite__mapDeps([110,1,108,2,3,4,5,6,7,30,69,21,22,23,16,17,13,18]),import.meta.url).then(({StoryboardRenderLayout:e})=>({default:e}))),av=(0,K.lazy)(()=>r(async()=>{let{PreviewArtifactLayout:e}=await import(`./PreviewArtifactLayout-KGeS-A9y.js`);return{PreviewArtifactLayout:e}},__vite__mapDeps([111,1,4,16,2,3,5,6,7,17,13,18,23,103,15,39,40,27,10,68,47,48,55,49,50,12,101,45,46,11,43,53,112]),import.meta.url).then(({PreviewArtifactLayout:e})=>({default:e}))),ov=(0,K.lazy)(()=>r(async()=>{let{AutoPublishBar:e}=await import(`./auto-publish-GJrN3H-Y.js`);return{AutoPublishBar:e}},__vite__mapDeps([113,1,114,13,3,4,5,2,6,7]),import.meta.url).then(({AutoPublishBar:e})=>({default:e}))),sv=(0,K.lazy)(()=>r(async()=>{let{SettingsDialog:e}=await import(`./settings-Ccw15Eyz.js`);return{SettingsDialog:e}},__vite__mapDeps([115,1,16,2,3,4,5,6,7,17,13,18,32,55,14,79,116,47]),import.meta.url).then(({SettingsDialog:e})=>({default:e}))),cv=(0,K.lazy)(()=>r(async()=>{let{ArtifactList:e}=await import(`./ArtifactList-DtgRku6l.js`);return{ArtifactList:e}},__vite__mapDeps([117,1,36,2,3,4,5,6,7,16,17,13,18,37,27,43,39,40,55,26,92,77,112,68,47,14,51,57,60,45,46,63,19,23]),import.meta.url).then(({ArtifactList:e})=>({default:e}))),lv=(0,K.lazy)(()=>Promise.all([r(()=>import(`./split-DYwwKqIa.js`),__vite__mapDeps([118,1,95,16,2,3,4,5,6,7,17,13,18,57,15,89,102,45,46,47,119,87,109,74,91,10,9,104,97,120,50,82]),import.meta.url),r(()=>import(`./local-split-host-DOfRlsgx.js`).then(e=>e.n),__vite__mapDeps([100,1,95,16,2,3,4,5,6,7,17,13,18,23]),import.meta.url)]).then(([{SplitShell:e},{localSplitHost:t}])=>({default:n=>(0,G.jsx)(e,{...n,host:t})}))),uv=(0,K.lazy)(()=>r(async()=>{let{PreviewLayout:e}=await import(`./PreviewLayout-C5knCbv-.js`).then(e=>e.n);return{PreviewLayout:e}},__vite__mapDeps([121,1,4,2,3,5,6,7,24,80]),import.meta.url).then(({PreviewLayout:e})=>({default:e}))),dv=(e,t)=>(0,G.jsxs)(G.Fragment,{children:[e,(0,G.jsx)(ov,{}),(0,G.jsx)(sv,{}),t&&(0,G.jsx)(Jh,{artifact:t})]}),fv=(e,t,n)=>dv((0,G.jsx)(H_,{id:t,type:e,children:n}),`${e}/${t}`);function pv({type:e,id:t,split:n}){let[r,i]=(0,K.useState)({type:e,id:t}),[a,o]=(0,K.useState)(null);(0,K.useEffect)(()=>{i({type:e,id:t})},[e,t]);let s=(0,K.useCallback)(e=>{i(t=>t.type===e.primary.type&&t.id===e.primary.id?t:e.primary)},[]),c=(0,K.useCallback)(e=>{o(e)},[]);return dv((0,G.jsx)(H_,{docHeader:a,id:r.id,type:r.type,children:(0,G.jsx)(lv,{fill:!0,hostPrimaryDocument:!0,id:t,split:n,type:e,onDocumentHeader:c,onPanes:s})}),`${r.type}/${r.id}`)}function mv({id:e,type:t}){let n=ev(),{Layout:r,embedIn:i}=rv[t],a=(0,G.jsx)(r,{id:e});return(0,G.jsxs)($_,{value:n,children:[Gh(location.search)&&(0,G.jsx)(Jh,{artifact:`${t}/${e}`}),i?i(a):a]})}function hv(){let[e]=Sh(),t=h(e);if((0,K.useEffect)(()=>{if(!document.documentElement.dataset.ryugiArtifactId)return;let e=document.querySelector(`link[rel="canonical"]`);if(!e)return;let t=new URL(location.href);t.pathname=y(t.pathname,new URL(e.href).pathname),t.href!==location.href&&history.replaceState(history.state,``,t)},[]),(0,K.useEffect)(()=>{window.scrollTo(0,0)},[e]),t.kind===`list`)return dv((0,G.jsx)(cv,{}));if(t.kind===`unknown`)return(0,G.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:`No artifact lives at this address.`});let n=document.documentElement.dataset.ryugiArtifactId??t.id;if(t.kind===`preview`)return(0,G.jsx)(uv,{id:n,type:t.type});if(t.kind===`dev-preview`)return dv((0,G.jsx)(av,{id:n}),`preview/${n}`);if(t.kind===`embed`)return(0,G.jsx)(mv,{id:n,type:t.type});if(t.kind===`render`)return(0,G.jsx)(iv,{id:n});if(g(t.type).standalone){let{Layout:e,bare:r}=rv[t.type],i=(0,G.jsx)(e,{id:n});return r?.(location.search)?dv(i,`${t.type}/${n}`):fv(t.type,n,i)}return(0,G.jsx)(pv,{id:n,split:Ne(t,location.search)?.split??null,type:t.type})}function gv(){return(0,G.jsx)(K.Suspense,{fallback:(0,G.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:(0,G.jsx)(Oh,{label:n(`common.loading`)})}),children:(0,G.jsx)(hv,{})})}Fe(),a(),document.documentElement.lang=o[s.language];function _v(){return c(),(0,G.jsx)(Hd,{features:bf,children:(0,G.jsxs)(Le,{enableCustomFonts:!1,motion:Jm,children:[(0,G.jsx)(gv,{}),(0,G.jsx)(ae,{}),(0,G.jsx)(an,{}),(0,G.jsx)(Ep,{})]})})}(0,Ym.createRoot)(document.getElementById(`root`)).render((0,G.jsx)(K.StrictMode,{children:(0,G.jsx)(_v,{})}));export{Vp as A,qo as B,fg as C,Mh as D,Fh as E,Vd as F,ss as I,as as L,gp as M,pp as N,jh as O,wf as P,rs as R,Z as S,zh as T,Uo as V,Og as _,M_ as a,gg as b,m_ as c,h_ as d,c_ as f,Fg as g,Ng as h,P_ as i,Y as j,Oh as k,v_ as l,Pg as m,B_ as n,j_ as o,Ig as p,V_ as r,O_ as s,tv as t,g_ as u,Dg as v,eg as w,_g as x,jg as y,ts as z};
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./AgentDock-CH6Ykvym.js","./rolldown-runtime-XKyaHtl9.js","./route-C7yP-PEQ.js","./bem-vbke-3KC.js","./react-DlmbjZJV.js","./jsx-runtime-LKYXHABd.js","./types-BCsOeYI6.js","./index2.css","./BottomSheet-IPyTloz4.js","./motion-Cy65kd7X.js","./useMedia-CFebB4XU.js","./agentLook-B5foAwJ4.js","./icons-CaBMvHC2.js","./MotionConfigContext-HC2vqcJO.js","./arrow-up-right-0KreI6kY.js","./chevron-left-C5itNrp5.js","./url-CCmcoMys.js","./useLayerZIndex-xDNOdXYr.js","./is-html-element-DvgHo_1h.js","./chevron-right-xNdXLJg6.js","./ArtboardLayout-BoYjJscp.js","./useArtifactFeed-jfvAzTGY.js","./transport-DusCV1zV.js","./useArtifactSocket-BA04npYU.js","./view-BeeaUcIu.js","./rounds-BLj-tfMG.js","./imperative-BNlnuZ6l.js","./Popover-D8lFLEo-.js","./sliders-horizontal-CuS3-UwA.js","./Canvas-CCJt5GBL.js","./cssVar.stylex-CGbpAC1Y.js","./WritingCursor-DauvJIme.js","./maximize-2-Bc0lXBg6.js","./PlaybackIcon-D-vfZnSv.js","./elements-CmGVWYag.js","./snap-DD8dHw6I.js","./local-DGEGKhEk.js","./SelectScrollUpArrow-BbJtTBmP.js","./undo-2-B-JiyKIl.js","./stable-DU_-8Jo1.js","./Tooltip-Cd3a5ILg.js","./styles-CdPIply-.js","./stringifyLocale-D0juOOnH.js","./Input-CIa1R1G9.js","./PhoneArtboardBar-BQw7xexp.js","./DropdownMenu-NA_XxVZB.js","./MenuSubmenuTrigger-B1GRjbbe.js","./index5.css","./crop-encode-BOXz_WBQ.js","./ThreadView-ChVeZPH-.js","./comments-DUAz1Q9X.js","./folder-BViSPo7g.js","./ruler-CYb0HZGT.js","./mouse-pointer-2-B-OF_fcG.js","./play-6FAfeM1L.js","./Segmented-Bbax5uqk.js","./useTypeFavicon-yXOsFZBx.js","./type-icons-CxYXZlMj.js","./CommentPopover-BgaTBWoa.js","./GroupVerdict-itgmpXO9.js","./artifact-list-9ZLo_0qZ.js","./film-A6SU1RGC.js","./code-xml-c9QCqmhY.js","./store-D3ROW536.js","./selection-BWCQd_Fn.js","./ArtboardLayout-DLyi-yDq.css","./DocumentLayout-Cz3hhXPR.js","./HtmlLayout-DBJCJRWj.js","./WarningsBadge-6ZtNX9sd.js","./useSandboxFrame-CJmSnwgG.js","./WhiteboardLayout-C9oGhpGn.js","./shims-s-YVfIlz.js","./pages-DWkRbog-.js","./WhiteboardEditor-DrHOvXez-BewOBKRS.js","./code-DnmQyGiF.js","./zoom-out-DsmGFv1v.js","./text-align-start-CRhecbJR.js","./plus-DZJ2BVkK.js","./index3.css","./preference-oNdcNeml.js","./DotGrid-DKKr_PyM.js","./message-square-Yl8PoPy_.js","./backlinks-C_k8-LL2.js","./WhiteboardLayout-SRFXrlmW.css","./VerifyLayout-CaugP8cx.js","./useAssetBase-4Ut9QhBI.js","./editor-BA7mo2fo.js","./pen-tool-BfwjhXQW.js","./underline-CT_nGhA9.js","./external-link-D382oEvK.js","./table-2-D90vZ04E.js","./presentation-DXrcAbwM.js","./search-DTrfkTpJ.js","./upload-DffL3XsM.js","./video-DKoRqEZW.js","./ref-Cv0JhjU5.js","./index4.css","./fit-DF-RHcFl.js","./VerifyLayout-B9e4RHAZ.css","./SlidesLayout-vo3ppRgW.js","./local-split-host-BtzqQOET.js","./monitor-DRrnx_H5.js","./DocumentExportMenu-BRaYTbF_.js","./DraggablePanel-DpBrlowL.js","./embed-src-CmyqZplg.js","./SlidesLayout-Bjds2UXz.css","./ReportLayout-68jrSHuE.js","./StoryboardLayout-BqJngaoz.js","./useStoryboardData-CiapuT5g.js","./clapperboard-BfpJ7tpa.js","./StoryboardRender-0aFMSadj.js","./PreviewArtifactLayout-BIGmZXGw.js","./BrandingMark-BMinTxVM.js","./auto-publish-89R-LJph.js","./cloud-upload-D8TpApTr.js","./settings-BZwlhQsp.js","./read-marks-CVVWpIvf.js","./ArtifactList-uj-q3W1q.js","./split-Clr7jYGP.js","./SplitFrame-D6BLXuFm.js","./route-messages-Cd15UR6N.js","./PreviewLayout-BmJ39T9v.js"])))=>i.map(i=>d[i]);
2
+ import{n as e,r as t}from"./rolldown-runtime-XKyaHtl9.js";import{C as n,D as r,E as i,M as a,N as o,S as s,T as c,_ as l,a as u,b as d,f,h as p,m,n as h,o as g,p as _,s as v,t as y,v as b,w as x,x as S}from"./route-C7yP-PEQ.js";/* empty css */import{An as C,Ar as w,At as T,Bt as E,C as D,Cr as O,Ct as k,Dt as ee,Er as A,Et as te,Ft as j,Gt as ne,Ht as M,It as N,J as re,Kt as ie,Mr as ae,Mt as P,N as oe,Nt as F,On as se,Ot as ce,Pt as le,Qt as ue,Rt as de,Sr as fe,St as pe,Tr as me,Tt as he,Ut as ge,Vt as _e,Wt as ve,Xt as ye,Y as be,Yt as xe,Zt as Se,_ as Ce,_t as we,at as I,b as Te,bt as Ee,dt as De,ft as Oe,g as ke,gr as Ae,gt as je,hr as Me,ht as Ne,i as Pe,in as Fe,it as L,j as Ie,jn as Le,jr as Re,jt as ze,kr as Be,kt as Ve,lr as He,mr as Ue,mt as We,ot as Ge,pr as Ke,pt as qe,qt as Je,rt as Ye,sr as Xe,tn as Ze,u as Qe,ur as $e,ut as et,v as tt,vr as nt,vt as rt,w as it,wn as at,wr as ot,wt as st,xt as ct,yr as lt,yt as ut,zt as dt}from"./url-CCmcoMys.js";import{$r as ft,C as pt,Dn as mt,En as ht,Fn as gt,Ft as _t,Gr as vt,Hr as yt,It as bt,Kr as xt,Pn as St,Sn as Ct,Tn as wt,Vr as Tt,Xr as Et,Yr as Dt,Zr as Ot,ii as R,kr as kt,oi as At,or as jt,qn as Mt,ri as z,rr as Nt,t as Pt,zr as Ft}from"./useLayerZIndex-xDNOdXYr.js";import{n as It,r as B,t as Lt}from"./bem-vbke-3KC.js";import{t as Rt}from"./react-DlmbjZJV.js";import{a as zt,i as Bt,l as Vt,n as Ht,o as Ut,r as Wt,s as Gt,t as Kt}from"./DropdownMenu-NA_XxVZB.js";import{A as qt,f as Jt,t as Yt}from"./Popover-D8lFLEo-.js";import{t as Xt}from"./jsx-runtime-LKYXHABd.js";import{a as Zt,i as Qt,n as $t,o as en,r as tn,s as nn,t as rn}from"./store-D3ROW536.js";import{n as an,t as on}from"./imperative-BNlnuZ6l.js";import{$ as sn,B as cn,Ct as ln,Dt as un,Et as dn,G as fn,I as pn,J as mn,M as hn,N as gn,P as _n,St as vn,Tt as yn,U as bn,W as V,_t as xn,a as Sn,bt as Cn,c as wn,ct as Tn,d as En,dt as Dn,et as On,gt as kn,h as An,ht as jn,i as Mn,l as Nn,m as Pn,mt as Fn,o as In,p as Ln,r as Rn,s as zn,st as Bn,t as Vn,u as Hn,ut as Un,wt as Wn,xt as Gn}from"./MotionConfigContext-HC2vqcJO.js";import{$ as Kn,$n as qn,$t as Jn,A as Yn,An as Xn,At as Zn,B as Qn,Bn as $n,Bt as er,C as tr,Cn as nr,Cr as rr,Ct as ir,D as ar,Dn as or,Dt as sr,E as cr,En as lr,Et as ur,F as dr,Fn as fr,Ft as pr,G as mr,Gn as hr,Gt as gr,H as _r,Hn as vr,Ht as yr,I as br,In as xr,It as Sr,J as Cr,Jn as wr,Jt as Tr,K as Er,Kn as Dr,Kt as Or,L as kr,Ln as Ar,Lt as jr,M as Mr,Mn as Nr,Mt as Pr,N as Fr,Nn as Ir,Nt as Lr,O as Rr,On as zr,Ot as Br,P as Vr,Pn as Hr,Pt as Ur,Q as Wr,Qn as Gr,Qt as Kr,R as qr,Rn as Jr,Rt as Yr,S as Xr,Sn as Zr,Sr as Qr,St as $r,T as ei,Tn as ti,Tr as ni,Tt as ri,U as ii,Un as ai,Ut as oi,V as si,Vn as ci,Vt as li,W as ui,Wn as di,Wt as fi,X as pi,Xn as mi,Xt as hi,Y as gi,Yn as _i,Yt as vi,Z as yi,Zn as bi,Zt as xi,_ as Si,_n as Ci,_r as wi,_t as Ti,a as Ei,an as Di,ar as Oi,at as ki,b as Ai,bn as ji,br as H,bt as Mi,c as Ni,cn as Pi,cr as Fi,ct as Ii,d as Li,dn as Ri,dr as zi,dt as Bi,en as Vi,er as Hi,et as Ui,f as Wi,fn as Gi,fr as Ki,ft as qi,g as Ji,gn as Yi,gr as Xi,gt as Zi,h as Qi,hn as $i,hr as ea,ht as ta,i as na,in as ra,ir as ia,it as aa,j as oa,jn as sa,jt as ca,k as la,kn as ua,kt as da,l as fa,ln as pa,lr as ma,lt as ha,m as ga,mn as _a,mr as va,mt as ya,n as ba,nn as xa,nr as Sa,nt as Ca,o as wa,on as Ta,or as Ea,ot as Da,p as Oa,pn as ka,pr as Aa,pt as ja,q as Ma,qn as Na,qt as Pa,r as Fa,rn as Ia,rr as La,rt as Ra,s as za,sn as Ba,sr as Va,st as Ha,t as Ua,tn as Wa,tr as Ga,tt as Ka,u as qa,un as Ja,ur as Ya,ut as Xa,v as Za,vn as Qa,vr as $a,vt as eo,w as to,wn as no,wr as ro,wt as io,x as ao,xn as oo,xr as so,xt as co,y as lo,yn as uo,yr as fo,yt as po,z as mo,zn as ho,zt as go}from"./elements-CmGVWYag.js";import{t as _o}from"./is-html-element-DvgHo_1h.js";import{m as vo,p as yo,t as bo}from"./local-DGEGKhEk.js";import{r as xo,t as So}from"./useArtifactSocket-BA04npYU.js";import{F as Co,P as wo}from"./SelectScrollUpArrow-BbJtTBmP.js";import{t as To}from"./DocumentExportMenu-BRaYTbF_.js";import{t as Eo}from"./arrow-up-right-0KreI6kY.js";import{t as Do}from"./cloud-upload-D8TpApTr.js";import{t as Oo}from"./Tooltip-Cd3a5ILg.js";import{S as ko,a as Ao,c as jo,d as Mo,f as No,h as Po,i as Fo,l as Io,m as Lo,n as Ro,s as zo,t as Bo,u as Vo,x as Ho}from"./MenuSubmenuTrigger-B1GRjbbe.js";var Uo={name:`clock-3`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6h4`,key:`135r8i`}]]};Uo.node;var Wo=un(Uo),Go={name:`cloud`,size:24,node:[[`path`,{d:`M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z`,key:`p7xjir`}]]};Go.node;var Ko=un(Go),qo={name:`columns-2`,size:24,node:[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M12 3v18`,key:`108xh3`}]],aliases:[`columns`]};qo.node;var Jo=un(qo),Yo={name:`credit-card`,size:24,node:[[`rect`,{width:`20`,height:`14`,x:`2`,y:`5`,rx:`2`,key:`ynyp8z`}],[`line`,{x1:`2`,x2:`22`,y1:`10`,y2:`10`,key:`1b3vmo`}],[`path`,{d:`M6 14h2`,key:`mk7k0u`}]]};Yo.node;var Xo=un(Yo),Zo={name:`key-round`,size:24,node:[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]};Zo.node;var Qo=un(Zo),$o={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};$o.node;var es=un($o),ts={name:`refresh-cw`,size:24,node:[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]};ts.node;var ns=un(ts),rs={name:`rotate-cw`,size:24,node:[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]};rs.node;var is=un(rs),as={name:`settings`,size:24,node:[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]};as.node;var os=un(as),ss={name:`smartphone`,size:24,node:[[`rect`,{width:`14`,height:`20`,x:`5`,y:`2`,rx:`2`,ry:`2`,key:`1yt0o3`}],[`path`,{d:`M12 18h.01`,key:`mhygvu`}]]};ss.node;var cs=un(ss);function ls(e,t,n,r=0,i=1){let a=Array.from(e).sort((e,t)=>e.sortNodePosition(t)).indexOf(t),o=e.size,s=(o-1)*r;return typeof n==`function`?n(a,o):i===1?a*r:s-a*r}function us(e,t,n){return ni(e.getProps(),t,n,e)}var ds=(e,t)=>t===`exit`?e.presenceContext?.custom:void 0,fs=e=>Array.isArray(e);function ps(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Pn(n))}function ms(e){return fs(e)?e[e.length-1]||0:e}function hs(e,t){let{transitionEnd:n={},transition:r={},...i}=us(e,t)||{};i={...i,...n};for(let t in i)ps(e,t,ms(i[t]))}function gs(e){return!!(En(e)&&e.add)}function _s(e,t){let n=e.getValue(`willChange`);if(gs(n))return n.add(t);if(!n&&Cn.WillChange){let n=new Cn.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function vs(e){return e.props[ro]}var ys=typeof window<`u`;function bs({protectedKeys:e,needsAnimating:t},n){let r=n in e&&!t[n];return t[n]=!1,r}function xs(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a,transitionEnd:o,...s}=t,c=e.getDefaultTransition();a=a?N(a,c):c;let l=a?.reduceMotion,u=a?.skipAnimations;r&&(a=r);let d=[],f=i&&e.animationState?.getState()[i],p=a?.path;p&&(p.animateValues?p.animateValues(t=>e.getValue(t,e.latestValues[t]??0),s,a,n,d):p.animateVisualElement?.(e,s,a,n,d));for(let t in s){let r=e.getValue(t,e.latestValues[t]??null),i=s[t];if(i===void 0||f&&bs(f,t))continue;let o={delay:n,...j(f?.out[t]||a||{},t)};u&&(o.skipAnimations=!0);let c=r.get();if(c!==void 0&&!r.isAnimating()&&!Array.isArray(i)&&i===c&&!o.velocity){V.update(()=>r.set(i));continue}let p=!1;if(ys&&window.MotionHandoffAnimation){let n=vs(e);if(n){let e=window.MotionHandoffAnimation(n,t,V);e!==null&&(o.startTime=e,p=!0)}}_s(e,t);let m=l??e.shouldReduceMotion;r.run(le(t,r,i,m&&P.has(t)?{type:!1}:o,e,p));let h=r.animation;h&&d.push(h)}if(o){let t=()=>V.update(()=>{o&&hs(e,o)});d.length?Promise.all(d).then(t):t()}return d}function Ss(e,t,n={}){let r=us(e,t,ds(e,n.type)),i=n.transitionOverride||(r?.transition??(e.getDefaultTransition()||{})),a=()=>Promise.all(r?xs(e,r,n):[]),o=(r=0)=>{let{variantChildren:a}=e,{delayChildren:o=0,staggerChildren:s,staggerDirection:c}=i,l=[];return a?.forEach(e=>{e.notify(`AnimationStart`,t),l.push(Ss(e,t,{...n,delay:r+(typeof o==`function`?0:o)+ls(a,e,o,s,c)}).then(()=>e.notify(`AnimationComplete`,t)))}),Promise.all(l)},{when:s}=i;return s?s===`beforeChildren`?a().then(()=>o()):o().then(a):Promise.all([a(),o(n.delay)])}function Cs(e,t,n={}){return e.notify(`AnimationStart`,t),(Array.isArray(t)?Promise.all(t.map(t=>Ss(e,t,n))):typeof t==`string`?Ss(e,t,n):Promise.all(xs(e,us(e,t,n.custom),n))).then(()=>{e.notify(`AnimationComplete`,t)})}var ws=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomRightRadius`,`borderBottomLeftRadius`],Ts={value:null,addProjectionMetrics:null,countProjection:void 0};function Es(e,t){let n=Un.now();e=Ve(e);let r=({timestamp:i})=>{let a=i-n;a>=t&&(bn(r),e(a-t))};return V.setup(r,!0),ce(()=>bn(r))}function Ds(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function Os(e){return T(e)&&e.tagName===`svg`}var ks=e=>typeof e==`number`?e:parseFloat(e),As=ws.length,js=e=>typeof e==`number`||On.test(e);function Ms(e,t,n,r,i,a){i?(e.opacity=M(0,n.opacity??1,Ps(r)),e.opacityExit=M(t.opacity??1,0,Fs(r))):a&&(e.opacity=M(t.opacity??1,n.opacity??1,r));for(let i=0;i<As;i++){let a=ws[i],o=Ns(t,a),s=Ns(n,a);(o!==void 0||s!==void 0)&&(o||=0,s||=0,o===0||s===0||js(o)===js(s)?(e[a]=Math.max(M(ks(o),ks(s),r),0),(sn.test(s)||sn.test(o))&&(e[a]+=`%`)):e[a]=s)}for(let i=0;i<ut.length;i++){let a=ut[i];(t[a]||n[a])&&(e[a]=M(t[a]||0,n[a]||0,r))}}function Ns(e,t){return e[t]===void 0?e.borderRadius:e[t]}var Ps=Is(0,.5,ge),Fs=Is(.5,.95,xn);function Is(e,t,n){return r=>r<e?0:r>t?1:n(ve(e,t,r))}var Ls=(e,t,{x:n,y:r})=>{let i=e*e+t*t;return i<1?0:-1e3*(n*e+r*t)/i},Rs=(e,t=300)=>{let n=Gn(.25,2,t/300),{stiffness:r,damping:i}=dt({...e,duration:e.duration&&jn(e.duration)});return{...e,stiffness:r,damping:i*Math.sqrt(n),mass:n}};function zs(e,t){e.min=t.min,e.max=t.max}function Bs(e,t){zs(e.x,t.x),zs(e.y,t.y)}function Vs(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var Hs=.9999,Us=1.0001,Ws=-.01,Gs=.01;function U(e){return e.max-e.min}function Ks(e,t,n){return Math.abs(e-t)<=n}function qs(e,t,n,r=.5){e.origin=r,e.originPoint=M(t.min,t.max,e.origin),e.scale=U(n)/U(t),e.translate=M(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Hs&&e.scale<=Us||isNaN(e.scale))&&(e.scale=1),(e.translate>=Ws&&e.translate<=Gs||isNaN(e.translate))&&(e.translate=0)}function Js(e,t,n,r){qs(e.x,t.x,n.x,r?.originX),qs(e.y,t.y,n.y,r?.originY)}function Ys(e,t,n,r=0){e.min=(r?M(n.min,n.max,r):n.min)+t.min,e.max=e.min+U(t)}function Xs(e,t,n,r){Ys(e.x,t.x,n.x,r?.x),Ys(e.y,t.y,n.y,r?.y)}function Zs(e,t,n,r=0){let i=r?M(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+U(t)}function Qs(e,t,n,r){Zs(e.x,t.x,n.x,r?.x),Zs(e.y,t.y,n.y,r?.y)}function $s(e,t,n,r,i){return e-=t,e=je(e,1/n,r),i!==void 0&&(e=je(e,1/i,r)),e}function ec(e,t=0,n=1,r=.5,i,a=e,o=e){if(sn.test(t)&&(t=parseFloat(t),t=M(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=M(a.min,a.max,r);e===a&&(s-=t),e.min=$s(e.min,t,n,s,i),e.max=$s(e.max,t,n,s,i)}function tc(e,t,[n,r,i],a,o){ec(e,t[n],t[r],t[i],t.scale,a,o)}var nc=[`x`,`scaleX`,`originX`],rc=[`y`,`scaleY`,`originY`];function ic(e,t,n,r){tc(e.x,t,nc,n?.x,r?.x),tc(e.y,t,rc,n?.y,r?.y)}var ac=e=>typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),oc=ac(`applewebkit/`)&&!ac(`chrome/`)?Math.round:xn;function sc(e){e.min=oc(e.min),e.max=oc(e.max)}function cc(e){sc(e.x),sc(e.y)}function lc(e){return e.translate===0&&e.scale===1}function uc(e){return lc(e.x)&&lc(e.y)}function dc(e,t){return e.min===t.min&&e.max===t.max}function fc(e,t){return dc(e.x,t.x)&&dc(e.y,t.y)}function pc(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function mc(e,t){return pc(e.x,t.x)&&pc(e.y,t.y)}function hc(e){return U(e.x)/U(e.y)}function gc(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var _c=class{constructor(){this.members=[]}add(e){vn(this.members,e);for(let t=this.members.length-1;t>=0;t--){let n=this.members[t];if(n===e||n===this.lead||n===this.prevLead)continue;let r=n.instance;r&&r.isConnected!==!1||n.snapshot||(Wn(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(Wn(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){for(let t=this.members.indexOf(e)-1;t>=0;t--){let e=this.members[t];if(e.isPresent!==!1&&e.instance?.isConnected!==!1)return this.promote(e),!0}return!1}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.updateSnapshot(),e.scheduleRender();let{layoutDependency:r}=n.options,{layoutDependency:i}=e.options;(r===void 0||r!==i)&&(e.resumeFrom=n,t&&(n.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root?.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{e.options.onExitComplete?.(),e.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}};function vc(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var yc={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`){if(On.test(e))e=parseFloat(e);else return e}return`${vc(e,t.target.x)}% ${vc(e,t.target.y)}%`}},bc={borderRadius:Object.assign({},yc,{applyTo:ws.slice()}),borderTopLeftRadius:yc,borderTopRightRadius:yc,borderBottomLeftRadius:yc,borderBottomRightRadius:yc,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=mn.parse(e);if(i.length>5)return r;let a=mn.createTransformer(e),o=typeof i[0]==`number`?0:1,s=n.x.scale*t.x,c=n.y.scale*t.y;i[0+o]/=s,i[1+o]/=c;let l=M(s,c,.5);return typeof i[2+o]==`number`&&(i[2+o]/=l),typeof i[3+o]==`number`&&(i[3+o]/=l),a(i)}}};function xc(e,t,n){let r=``,i=e.x.translate/t.x,a=e.y.translate/t.y,o=n?.z||0;(i||a||o)&&(r=`translate3d(${i}px, ${a}px, ${o}px) `);let s=``;if(n){let{transformPerspective:e}=n;e&&(r=`perspective(${e}px) ${r}`);for(let e=0;e<ut.length;e++){let t=ut[e],r=n[t];r&&(s+=`${t}(${r}deg) `),!e&&n.pathRotation&&(s+=`rotate(${n.pathRotation}deg) `)}}if(s){(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),r+=s;let n=e.x.scale*t.x,i=e.y.scale*t.y;(n!==1||i!==1)&&(r+=`scale(${n}, ${i})`)}else e.x.scale!==1||e.y.scale!==1?r+=`scale(${e.x.scale}, ${e.y.scale})`:r||t.x===1&&t.y===1||(r=`scale(1, 1)`);return r||`none`}function Sc(e){return[e(`x`),e(`y`)]}var Cc=(e,t)=>e.depth-t.depth,wc=class{constructor(){this.children=[],this.isDirty=!1}add(e){vn(this.children,e),this.isDirty=!0}remove(e){Wn(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(Cc),this.isDirty=!1,this.children.forEach(e)}},Tc={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Ec=[`z`,`skew`,`skewZ`],Dc=1e3,Oc=0;function kc(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}var Ac=e=>e.instance&&An.get(e.instance)?.demote()&&e.resetSkewAndRotation();function jc(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=vs(t);if(window.MotionHasOptimisedAnimation(n,`transform`)){let{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,`transform`,V,!(t||r))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&jc(r)}function Mc(e){if(e)return e.options.allowProjection===!1?Mc(e.parent):e.projection}function Nc({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return Object.assign(rr,{...bc,...rr}),class{static create(e,t,n){let{layoutId:r,layout:i,drag:a,dragConstraints:o,layoutScroll:s,layoutRoot:c,layoutAnchor:l,layoutCrossfade:u}=t,d=e.projection=new this(e.latestValues,t[`data-framer-portal-id`]?void 0:Mc(e.parent));d.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!a||o&&Ds(o),visualElement:e,animationType:typeof i==`string`?i:`both`,initialPromotionConfig:n,crossfade:u,layoutScroll:s,layoutRoot:c,layoutAnchor:l});let f=d.getStack()?.lead;f&&!d.root.isUpdateBlocked()&&(f.willUpdate(),f.scheduleCheckAfterUnmount())}constructor(e={},n=t?.()){this.id=Oc++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Ic),this.nodes.forEach(qc),this.nodes.forEach(Jc),this.nodes.forEach(Lc),Ts.countProjection?.()},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new wc)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new kn),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){this.eventHandlers.get(e)?.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t){if(this.instance)return;this.isSVG=T(t)&&!Os(t),this.instance=t;let{layoutId:n,layout:r,visualElement:i}=this.options;if(i&&!i.current&&i.mount(t),this.root.nodes.add(this),this.parent?.children.add(this),this.root.hasTreeAnimated&&(r||n)&&(this.isLayoutDirty=!0),e){let n,r=0,i=()=>this.root.updateBlockedByResize=!1;V.read(()=>{r=window.innerWidth}),e(t,()=>{let e=window.innerWidth;e!==r&&(r=e,this.root.updateBlockedByResize=!0,n?.(),n=Es(i,250),Tc.hasAnimatedSinceResize&&(Tc.hasAnimatedSinceResize=!1,this.nodes.forEach(Kc)))})}n&&this.root.registerSharedNode(n,this),this.addLayoutListener()}addLayoutListener(){let{layoutId:e,layout:t,visualElement:n,animate:r}=this.options;this.instance&&!this.hasLayoutListener&&r!==!1&&n&&(e||t)&&(this.hasLayoutListener=!0,this.addEventListener(`didUpdate`,({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:r,layout:i})=>{if(this.isAnimationBlocked){this.target=void 0,this.relativeTarget=void 0;return}let a=this.options.transition||n.getDefaultTransition()||tl,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=n.getProps(),c=!this.targetLayout||!mc(this.targetLayout,i),l=!t&&r;if(this.options.layoutRoot||this.resumeFrom||l||t&&(c||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let t={...j(a,`layout`),onPlay:o,onComplete:s};(n.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t),this.setAnimationOrigin(e,l,t.path)}else t||Kc(this),this.isLead()&&this.options.onExitComplete?.();this.targetLayout=i}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this),this.getStack()?.remove(this),this.parent?.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),this.hasLayoutListener=!1,bn(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes?.forEach(Yc),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete?.();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&jc(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;Ac(this),this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,Ac(t),(typeof t.latestValues.x==`string`||typeof t.latestValues.y==`string`)&&(t.isLayoutDirty=!0),t.updateScroll(`snapshot`),t.options.layoutRoot&&t.willUpdate(!1),t.isAnimationBlocked&&(t.dragSnapshot||=t.measure(),this.dragAncestor=t)}let{layoutId:t,layout:n}=this.options;if(t===void 0&&!n)return;let r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,``):void 0,this.updateSnapshot(),e&&this.notifyListeners(`willUpdate`)}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){let e=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),e&&this.nodes.forEach(Bc),this.nodes.forEach(zc);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Vc);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Uc),this.nodes.forEach(Wc),this.nodes.forEach(Gc),this.nodes.forEach(Pc),this.nodes.forEach(Fc)):this.nodes.forEach(Vc),this.clearAllSnapshots();let e=Un.now();Dn.delta=Gn(0,1e3/60,e-Dn.timestamp),Dn.timestamp=e,Dn.isProcessing=!0,fn.update.process(Dn),fn.preRender.process(Dn),fn.render.process(Dn),Dn.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,zn.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Rc),this.sharedNodes.forEach((e,t)=>e.members.length?e.removeLeadSnapshot():this.sharedNodes.delete(t))}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,V.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){V.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){if(!this.snapshot&&this.instance&&(this.snapshot=this.measure(),this.snapshot&&!U(this.snapshot.measuredBox.x)&&!U(this.snapshot.measuredBox.y)&&(this.snapshot=void 0),this.snapshot)){let{visualElement:e}=this.options,t=this.currentAnimation?.state===`running`,n=t&&this.animationEdges;t&&this.relativeTarget&&(this.snapshot.relativeVelocity=this.relativeVelocity?.slice()||[]);let r=n&&this.motionValue?.getVelocity()||0,i=[0,1,2,3,4,5].map(t=>(t<4?n&&(this.edgeValues?this.edgeVelocity(t):-n[t]*r/1e3):e?.getValue(t<5?`x`:`y`)?.getVelocity())||0);i.some(Boolean)&&(this.snapshot.velocity=i)}}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutCorrected||=H(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners(`measure`,this.layout.layoutBox);let{visualElement:t}=this.options;t?.notify(`LayoutMeasure`,this.layout.layoutBox,e?.layoutBox)}updateScroll(e=`measure`){let{scroll:t,instance:i}=this,{animationId:a}=this.root;if(this.options.layoutScroll&&i&&!(t&&t.animationId===a&&t.phase===e)){let o=r(i);this.scroll={animationId:a,phase:e,isRoot:o,offset:n(i),wasRoot:t?t.isRoot:o}}}resetTransform(){if(!i)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout;e&&Ac(this);let t=this.projectionDelta&&!uc(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,``):void 0,a=r!==this.prevTransformTemplateValue;e&&this.instance&&(t||k(this.latestValues)||a)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){let t=this.measurePageBox(),n=this.removeElementScroll(t);return e&&(n=this.removeTransform(n)),cc(n),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:e}=this.options;if(!e)return H();let t=e.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(il))){let{scroll:e}=this.root;e&&(rt(t.x,e.offset.x),rt(t.y,e.offset.y))}return t}removeElementScroll(e){let t=H();if(Bs(t,e),this.scroll?.wasRoot)return t;for(let n=0;n<this.path.length;n++){let r=this.path[n],{scroll:i,options:a}=r;r!==this.root&&i&&a.layoutScroll&&(i.wasRoot&&Bs(t,e),rt(t.x,i.offset.x),rt(t.y,i.offset.y))}return t}applyTransform(e,t=!1,n,r,i=0){let a=n||H();Bs(a,e);for(let e=i;e<this.path.length;e++){let n=this.path[e];!t&&n.options.layoutScroll&&n.scroll&&n!==n.root&&(rt(a.x,-n.scroll.offset.x),rt(a.y,-n.scroll.offset.y)),k(n.latestValues)&&we(a,n.latestValues,n.layout?.layoutBox)}return!r&&k(this.latestValues)&&we(a,this.latestValues,this.layout?.layoutBox),a}removeTransform(e){let t=H();Bs(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!k(n.latestValues))continue;let r;n.instance&&(pe(n.latestValues)&&n.updateSnapshot(),r=H(),Bs(r,n.measurePageBox())),ic(t,n.latestValues,n.snapshot?.layoutBox,r)}return k(this.latestValues)&&ic(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:e.crossfade===void 0||e.crossfade},this.addLayoutListener()}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Dn.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){let t=this.getLead();this.isProjectionDirty||=t.isProjectionDirty,this.isTransformDirty||=t.isTransformDirty,this.isSharedProjectionDirty||=t.isSharedProjectionDirty;let n=!!this.resumingFrom||this!==t;if(!(e||n&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:r,layoutId:i}=this.options;if(!this.layout||!(r||i))return;this.resolvedRelativeTargetAt=Dn.timestamp;let a=this.getClosestProjectingParent();!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&a&&a.layout?this.createRelativeTarget(a,this.layout.layoutBox,a.layout.layoutBox):this.removeRelativeTarget()),(this.relativeTarget||this.targetDelta)&&(this.target||(this.target=H(),this.targetWithTransforms=H()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Xs(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target,!0):Bs(this.target,this.layout.layoutBox),We(this.target,this.targetDelta)):Bs(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&a&&(!a.resumingFrom==!this.resumingFrom||a.options.layoutRoot&&!a.resumingFrom)&&!a.options.layoutScroll&&a.target&&this.animationProgress!==1?this.createRelativeTarget(a,this.target,a.target):this.relativeParent=this.relativeTarget=void 0),Ts.countProjection?.(1))}getClosestProjectingParent(){if(!(!this.parent||pe(this.parent.latestValues)||Ee(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(e,t,n){this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=H(),this.relativeTargetOrigin=H(),Qs(this.relativeTargetOrigin,t,n,this.options.layoutAnchor||void 0),Bs(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let e=this.getLead(),t=!!this.resumingFrom||this!==e,n=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(n=!1),t&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(n=!1),this.resolvedRelativeTargetAt===Dn.timestamp&&(n=!1),n)return;let{layout:r,layoutId:i}=this.options;if(this.isTreeAnimating=!!(this.parent?.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(r||i))return;Bs(this.layoutCorrected,this.layout.layoutBox);let a=this.treeScale.x,o=this.treeScale.y;Ne(this.layoutCorrected,this.treeScale,this.path,t&&(e.relativeTarget&&!e.relativeParent.resumingFrom?e.relativeParent:!0)),e.layout&&!e.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(e.target=e.layout.layoutBox,e.targetWithTransforms=H());let{target:s}=e;s?(!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Vs(this.prevProjectionDelta.x,this.projectionDelta.x),Vs(this.prevProjectionDelta.y,this.projectionDelta.y)),Js(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.treeScale.x===a&&this.treeScale.y===o&&gc(this.projectionDelta.x,this.prevProjectionDelta.x)&&gc(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners(`projectionUpdate`,s)),Ts.countProjection?.(2)):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){this.options.visualElement?.scheduleRender(),e&&this.getStack()?.scheduleRender(),this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=so(),this.projectionDelta=so(),this.projectionDeltaWithTransform=so()}setAnimationOrigin(e,t=!1,n){let r=this.snapshot,i=r?r.latestValues:{},a={...this.latestValues},o=so();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let s=H(),c=r?.source!==this.layout?.source,l=this.getStack(),u=!l||l.members.length<=1,d=!(!c||u||this.options.crossfade!==!0||this.path.some(el));this.animationProgress=0;let f,p=n?.interpolateProjection(e),m=this.layout?.layoutBox,h=m&&[m.x.min,m.x.max,m.y.min,m.y.max].map((t,n)=>{let{translate:r,scale:i,originPoint:a}=e[n<2?`x`:`y`];return(t-a)*(i-1)+r});h?.every(isFinite)||(h=void 0),this.animationEdges=h,this.edgeValues=this.startVelocity=this.impulse=this.relativeVelocity=this.relativeStart=void 0;let g=r?.velocity,_=r?.relativeVelocity||g;if(_?.slice(0,4).some(Boolean)&&this.getClosestProjectingParent()&&(this.relativeStart=_),g&&h){let t=g.slice(0,4).map((e,t)=>e+(c?g[4+(t>>1)]:0));t.some(Boolean)&&(this.startVelocity=p?Ls(e.x.translate,e.y.translate,{x:(t[0]+t[1])/2,y:(t[2]+t[3])/2}):t)}this.mixTargetDelta=t=>{let n=t/1e3,r=p?.(n),l=this.edgeValues;for(let t=0;t<2;t++){let r=t?`y`:`x`;l?Xc(o[r],e[r],this.layout.layoutBox[r],l[t*2],l[t*2+1]):Zc(o[r],e[r],n)}if(r&&(o.x.translate=r.x,o.y.translate=r.y),this.setTargetDelta(o),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){Qs(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0);let e=this.relativeTargetOrigin,t=s;if($c(this.relativeTarget,e,t,n),this.isSpringLayout){let e=this.relativeTarget,t=this.impulse||0,n=this.relativeStart,r=Un.now(),i=(r-this.relativeTime)/1e3;this.relativeTime=r;let a=this.relativeVelocity||=[0,0,0,0];for(let r=0;r<4;r++){let o=r<2?`x`:`y`,s=r&1?`max`:`min`;n&&(e[o][s]+=n[r]*t),f&&i>0&&(a[r]=(e[o][s]-f[o][s])/i)}}f&&fc(this.relativeTarget,f)&&(this.isProjectionDirty=!1),f||=H(),Bs(f,this.relativeTarget)}c&&(this.animationValues=a,Ms(a,i,this.latestValues,n,d,u)),r?.rotate!==void 0&&(this.animationValues||=a,this.animationValues.pathRotation=r.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners(`animationStart`);let t=this.isSpringLayout=e.type===`spring`;this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.resumingFrom&&(this.resumingFrom.edgeValues=void 0),this.pendingAnimation&&=(bn(this.pendingAnimation),void 0),this.pendingAnimation=V.update(()=>{Tc.hasAnimatedSinceResize=!0,this.motionValue||=Pn(0),this.motionValue.jump(0,!1);let n=this.startVelocity;this.startVelocity=void 0;let r=e,i=0;if(t){if(e.mass===`auto`){let t=this.layout?.layoutBox;r=Rs(e,t&&Math.sqrt(U(t.x)*U(t.y)))}let t=this.relativeStart;if((n||t)&&!e.repeat){if(typeof n==`number`)i=n;else{let e=n&&this.animationEdges;r={...r,type:r=>{let i=[r.velocity,...n||[]].map((t,n)=>E({...r,keyframes:n?[e[n-1],0]:r.keyframes,velocity:t})),a=i.length;t&&i.push(E({...r,keyframes:[0,0],velocity:1e3,restDelta:.5,restSpeed:5}));let o=0,s=[],c={calculatedDuration:null,next:t=>{o=t;let n=i[0].next(t),r=n.done;for(let e=1;e<i.length;e++){let{value:n,done:o}=i[e].next(t);e<a?s[e-1]=n:this.impulse=n/1e3,r&&=o}return e&&(this.edgeValues=s),n.done=r,n}};return c.calculatedDuration=_e(c),c.next(0),this.edgeVelocity=e=>i[e+1].velocity(o),c}}}}}let a=et(this.motionValue,[0,1e3],{...r,velocity:i,isSync:!0,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}});this.currentAnimation=a,cn(this.currentAnimation,this),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=this.edgeValues=this.edgeVelocity=this.impulse=void 0,this.notifyListeners(`animationComplete`)}finishAnimation(){this.currentAnimation&&(this.edgeValues=this.impulse=void 0,this.mixTargetDelta?.(Dc),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,layout:n,latestValues:r}=e,{target:i}=e;if(t&&i&&n){if(this!==e&&this.layout&&n&&rl(this.options.animationType,this.layout.layoutBox,n.layoutBox)){let{layoutBox:e}=this.layout,t=i;i=this.target||H(),nl(i.x,t.x,e.x),nl(i.y,t.y,e.y)}Bs(t,i),we(t,r),Js(this.projectionDeltaWithTransform,this.layoutCorrected,t,r)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new _c),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?.transition,preserveFollowOpacity:n?.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){let{layoutId:e}=this.options;return e&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:e}=this.options;return e?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){this.getStack()?.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){return this.getStack()?.relegate(this)||!1}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let{latestValues:t}=e;if(!ct(t))return;let n={};for(let t=0;t<Ec.length;t++)kc(Ec[t],e,n,this.animationValues);for(let t=0;t<ut.length;t++)kc(ut[t],e,n,this.animationValues);e.render();for(let t in n)e.setStaticValue(t,n[t]),this.animationValues&&(this.animationValues[t]=n[t]);e.scheduleRender()}applyProjectionStyles(e,t){if(!this.instance||this.isSVG)return;let n=this.getLead();if(!this.isVisible&&n!==this){e.visibility=`hidden`;return}let r=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,e.visibility=``,e.opacity=``,e.pointerEvents=Qr(t?.pointerEvents)||``,e.transform=r?r(this.latestValues,``):`none`;return}if(!this.projectionDelta||!this.layout||!n.target){(this.options.layoutId||this.needsShow)&&(this.needsShow=!1,e.visibility=``,e.opacity=this.latestValues.opacity===void 0?1:this.latestValues.opacity,e.pointerEvents=Qr(t?.pointerEvents)||``),this.hasProjected&&!k(this.latestValues)&&(e.transform=r?r({},``):`none`,this.hasProjected=!1);return}e.visibility=``;let i=n.animationValues||n.latestValues;this.applyTransformsToTarget();let a=xc(this.projectionDeltaWithTransform,this.treeScale,i);r&&(a=r(i,a)),e.transform=a;let{x:o,y:s}=this.projectionDelta;e.transformOrigin=`${o.origin*100}% ${s.origin*100}% 0`,e.opacity=n.animationValues?n===this?i.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:i.opacityExit:n===this?i.opacity===void 0?``:i.opacity:i.opacityExit===void 0?0:i.opacityExit;for(let t in rr){if(i[t]===void 0)continue;let{correct:r,applyTo:o,isCSSVariable:s}=rr[t],c=a===`none`?i[t]:r(i[t],n);if(o){let t=o.length;for(let n=0;n<t;n++)e[o[n]]=c}else s?this.options.visualElement.renderState.vars[t]=c:e[t]=c}this.options.layoutId&&(e.pointerEvents=n===this?Qr(t?.pointerEvents)||``:`none`)}clearSnapshot(){this.resumeFrom=this.snapshot=this.dragSnapshot=this.dragAncestor=void 0}resetTree(){this.root.nodes.forEach(e=>e.currentAnimation?.stop()),this.root.nodes.forEach(zc),this.root.sharedNodes.clear()}}}function Pc(e){e.updateLayout(),Hc(e)}function Fc(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners(`didUpdate`)){let{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,a=t.source!==e.layout.source,o=(r,a)=>{if(i===`size`)Sc(e=>{let t=U(r[e]);r[e].min=a[e].min,r[e].max=r[e].min+t});else if(i===`x`||i===`y`){let e=i===`x`?`y`:`x`;zs(r[e],a[e])}else rl(i,t.layoutBox,n)&&Sc(t=>{let n=U(a[t]);r[t].max=r[t].min+n,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[t].max=e.relativeTarget[t].min+n)})},s=a?t.measuredBox:t.layoutBox;o(s,n);let c=so();Js(c,n,t.layoutBox);let l=so();Js(l,a?e.applyTransform(r,!0):n,s);let u=!uc(c),d=!1,f=e.getClosestProjectingParent();if((!a||f?.options.layoutRoot&&e.resumeFrom?.path.includes(f))&&f&&!f.resumeFrom){let{snapshot:r,layout:i}=f;if(r&&i){let s=e.options.layoutAnchor||void 0,c=H();Qs(c,a?e.resumeFrom.applyTransform(t.layoutBox,!0,void 0,!0,f.depth+1):t.layoutBox,r.layoutBox,s);let l=H();Qs(l,n,i.layoutBox,s),a&&o(c,l),mc(c,l)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=l,e.relativeTargetOrigin=c,e.relativeParent=f)}}e.notifyListeners(`didUpdate`,{layout:n,snapshot:t,delta:l,layoutDelta:c,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else e.isLead()&&e.options.onExitComplete?.();e.options.transition=void 0}function Ic(e){Ts.countProjection?.(0),e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty),e.isTransformDirty||=e.parent.isTransformDirty)}function Lc(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Rc(e){e.clearSnapshot()}function zc(e){e.clearMeasurements()}function Bc(e){e.isLayoutDirty=!0,e.updateLayout()}function Vc(e){e.isLayoutDirty=!1}function Hc(e){let{snapshot:t,dragAncestor:n}=e,r=n?.isAnimationBlocked&&n.layout;if(!t||!r||e.resumeFrom||e.isAnimationBlocked)return;let i=n.dragSnapshot;Sc(e=>rt(t.layoutBox[e],r.layoutBox[e].min-i.layoutBox[e].min))}function Uc(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.dragSnapshot||e.layout,e.isLayoutDirty=!0)}function Wc(e){e.relativeTarget&&e.relativeParent?.isLayoutDirty&&(e.currentAnimation?e.isLayoutDirty=!0:(e.targetDelta=void 0,e.removeRelativeTarget()))}function Gc(e){let{visualElement:t}=e.options;t?.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function Kc(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function qc(e){e.resolveTargetDelta()}function Jc(e){e.calcProjection()}function Yc(e){e.resetSkewAndRotation()}function Xc(e,t,n,r,i){let a=n.max-n.min,o=a?Math.max(0,(a+i-r)/a):1,s=e.originPoint=t.originPoint;e.origin=t.origin,e.scale=o,e.translate=n.min+r-(s+(n.min-s)*o)}function Zc(e,t,n){e.translate=M(t.translate,0,n),e.scale=M(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Qc(e,t,n,r){e.min=M(t.min,n.min,r),e.max=M(t.max,n.max,r)}function $c(e,t,n,r){Qc(e.x,t.x,n.x,r),Qc(e.y,t.y,n.y,r)}function el(e){return e.animationValues?.opacityExit!==void 0}var tl={duration:.45,ease:[.4,0,.1,1]};function nl(e,t,n){e.max=U(n)+(e.min=t.min)}function rl(e,t,n){return e===`position`||e===`preserve-aspect`&&!Ks(hc(t),hc(n),.2)}function il(e){return e!==e.root&&e.scroll?.wasRoot}function al(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}var ol=Nc({attachResizeListener:(e,t)=>al(e,`resize`,t),measureScroll:De,checkIsScrollRoot:()=>!0}),sl=Nc({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!fo.current){let e=new ol({});e.mount(window),e.setOptions({layoutScroll:!0}),fo.current=e}return fo.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>window.getComputedStyle(e).position===`fixed`}),cl=class extends Ki{constructor(){super(...arguments),this.KeyframeResolver=ze}sortInstanceNodePosition(e,t){return e.compareDocumentPosition(t)&2?1:-1}getBaseTargetFromProps(e,t){let n=e.style;return n?n[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;En(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}};function ll(e,{style:t,vars:n},r,i){let a=e.style,o;for(o in t)a[o]=t[o];for(o in i?.applyProjectionStyles(a,r),n)a.setProperty(o,n[o])}function ul(e){return window.getComputedStyle(e)}var dl=class extends cl{constructor(){super(...arguments),this.type=`html`,this.renderInstance=ll}mount(e){super.mount(e)}readValueFromInstance(e,t){if(hn.has(t))return this.projection?.isProjecting?gn(t):_n(e,t);{let n=ul(e),r=(Bn(t)?n.getPropertyValue(t):n[t])||0;return typeof r==`string`?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return qe(e,t)}build(e,t,n){Hn(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return zi(e,t,n)}},fl=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1;function pl(e){return{point:{x:e.pageX,y:e.pageY}}}var ml=e=>t=>fl(t)&&e(t,pl(t));function hl(e,t,n,r){return al(e,t,ml(n),r)}var gl=new WeakMap,_l,vl=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:T(r)&&`getBBox`in r?r.getBBox()[t]:r[n],yl=vl(`inline`,`width`,`offsetWidth`),bl=vl(`block`,`height`,`offsetHeight`);function xl({target:e,borderBoxSize:t}){gl.get(e)?.forEach(n=>{n(e,{get width(){return yl(e,t)},get height(){return bl(e,t)}})})}function Sl(e){e.forEach(xl)}function Cl(){typeof ResizeObserver<`u`&&(_l=new ResizeObserver(Sl))}function wl(e,t){_l||Cl();let n=ee(e);return n.forEach(e=>{let n=gl.get(e);n||(n=new Set,gl.set(e,n)),n.add(t),_l?.observe(e)}),()=>{n.forEach(e=>{let n=gl.get(e);n?.delete(t),n?.size||_l?.unobserve(e)})}}var Tl=new Set,El;function Dl(){El=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};Tl.forEach(t=>t(e))},window.addEventListener(`resize`,El)}function Ol(e){return Tl.add(e),El||Dl(),()=>{Tl.delete(e),!Tl.size&&typeof El==`function`&&(window.removeEventListener(`resize`,El),El=void 0)}}function kl(e,t){return ce(typeof e==`function`?Ol(e):wl(e,t))}var Al=(e,t)=>Math.abs(e-t);function jl(e,t){let n=Al(e.x,t.x),r=Al(e.y,t.y);return Math.sqrt(n**2+r**2)}var Ml=new Set([`auto`,`scroll`]),Nl=class{constructor(e,t,{transformPagePoint:n,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:a=3,element:o,immediate:s}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.onElementScroll=e=>{this.handleScroll(e.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.hasPendingMove=!1,this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Fl(this.lastRawMoveEventInfo,this.transformPagePoint));let e=Ll(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=jl(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e;this.history.push({...r,timestamp:Un.now()});let{onStart:i,onMove:a}=this.handlers;t||(i?.(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),a?.(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.handleScroll(window),this.lastMoveEvent=e,this.lastRawMoveEventInfo=t,this.lastMoveEventInfo=Fl(t,this.transformPagePoint),this.hasPendingMove=!0,V.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.hasPendingMove&&this.updatePoint(),this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&i?.(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let a=Ll(e.type===`pointercancel`?this.lastMoveEventInfo:Fl(t,this.transformPagePoint),this.history);this.startEvent&&n?.(e,a),r?.(e,a)},!fl(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=s?0:a,this.contextWindow=r||window;let c=pl(e),l=Fl(c,this.transformPagePoint),{point:u}=l;this.history=[{...u,timestamp:Un.now()}];let{onSessionStart:d}=t;d&&d(e,Ll(l,this.history));let f={passive:!0,capture:!0};this.removeListeners=ne(hl(this.contextWindow,`pointermove`,this.handlePointerMove,f),hl(this.contextWindow,`pointerup`,this.handlePointerUp,f),hl(this.contextWindow,`pointercancel`,this.handlePointerUp,f)),o&&this.startScrollTracking(o),s&&(this.handlePointerMove(e,c),this.updatePoint())}startScrollTracking(e){let t=e.parentElement;for(;t;){let e=getComputedStyle(t);(Ml.has(e.overflowX)||Ml.has(e.overflowY))&&this.scrollPositions.set(t,Pl(t)),t=t.parentElement}this.scrollPositions.set(window,Pl(window)),this.removeScrollListeners=ne(al(window,`scroll`,this.onElementScroll,{capture:!0}),al(window,`scroll`,this.onWindowScroll,{}))}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===window,r=Pl(e),i={x:r.x-t.x,y:r.y-t.y};(i.x!==0||i.y!==0)&&(n?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(e,r),V.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners?.(),this.removeScrollListeners?.(),this.scrollPositions.clear(),bn(this.updatePoint)}},Pl=e=>e===window?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop};function Fl(e,t){return t?{point:t(e.point)}:e}function Il(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Ll({point:e},t){return{point:e,delta:Il(e,zl(t)),offset:Il(e,Rl(t)),velocity:Bl(t,.1)}}function Rl(e){return e[0]}function zl(e){return e[e.length-1]}function Bl(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=zl(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>jn(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>jn(t)*2&&(r=e[1]);let a=Fn(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};let o={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}var Vl=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]);function Hl(e){return Vl.has(e.tagName)||e.isContentEditable===!0}var Ul=new Set([`INPUT`,`SELECT`,`TEXTAREA`]);function Wl(e){return Ul.has(e.tagName)||e.isContentEditable===!0}var Gl={x:!1,y:!1};function Kl(){return Gl.x||Gl.y}function ql(e){return e===`x`||e===`y`?Gl[e]?null:(Gl[e]=!0,()=>{Gl[e]=!1}):Gl.x||Gl.y?null:(Gl.x=Gl.y=!0,()=>{Gl.x=Gl.y=!1})}function Jl(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?M(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?M(n,e,r.max):Math.min(e,n)),e}function Yl(e,t,n){return{min:t===void 0?void 0:e.min+t,max:n===void 0?void 0:e.max+n-(e.max-e.min)}}function Xl(e,{top:t,left:n,bottom:r,right:i}){return{x:Yl(e.x,n,i),y:Yl(e.y,t,r)}}function Zl(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function Ql(e,t){return{x:Zl(e.x,t.x),y:Zl(e.y,t.y)}}function $l(e,t){let n=.5,r=U(e),i=U(t);return i>r?n=ve(t.min,t.max-r,e.min):r>i&&(n=ve(e.min,e.max-i,t.min)),Gn(0,1,n)}function eu(e,t){let n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}var tu=.35;function nu(e=tu){return e===!1?e=0:e===!0&&(e=tu),{x:ru(e,`left`,`right`),y:ru(e,`top`,`bottom`)}}function ru(e,t,n){return{min:iu(e,t),max:iu(e,n)}}function iu(e,t){return typeof e==`number`?e:e[t]||0}function au(e){let t=``;for(let n of e.path){n.scroll=void 0,n.updateScroll();let{scroll:r}=n;n!==e.root&&r&&(t+=r.offset.x+`,`+r.offset.y+`,`)}return t}var ou=new WeakMap,su=class{constructor(e,t=()=>e.getProps()){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=H(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e,this.readProps=t}start(e,t={}){if(this.visualElement.presenceContext?.isPresent===!1)return;let n=e=>{t.snapToCursor&&this.snapToCursor(e),this.stopAnimation()},r=(e,t)=>{let{drag:n,dragConstraints:r,dragPropagation:i,onDragStart:a}=this.getProps();if(n&&!i&&(this.openDragLock?.(),this.openDragLock=ql(n),!this.openDragLock))return;this.latestPointerEvent=e,this.latestPanInfo=t,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints();let{projection:o}=this.visualElement;o&&(o.isAnimationBlocked=!0,o.target=void 0),Sc(e=>{let t=this.getAxisMotionValue(e).get()||0;if(Tn(t)&&(t=F(t,this.visualElement.current)||0),On.test(t))t=parseFloat(t);else if(sn.test(t)){let n=o?.layout?.layoutBox[e];n&&(t=U(n)*(parseFloat(t)/100))}this.originPoint[e]=t}),this.point=typeof r==`function`&&r(this),a&&V.update(()=>a(e,t),!1,!0),_s(this.visualElement,`transform`),this.visualElement.animationState?.setActive(`whileDrag`,!0)},i=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t;let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:a}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:o}=t;if(r&&this.currentDirection===null){if(this.currentDirection=pu(o),this.currentDirection===null)return;i&&i(this.currentDirection)}this.updateAxis(`x`,o),this.updateAxis(`y`,o),this.point&&this.point.move(),this.visualElement.render(),a&&V.update(()=>a(e,t),!1,!0)},a=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t,this.stop(e,t),this.latestPointerEvent=null,this.latestPanInfo=null},o=()=>{let{dragSnapToOrigin:e}=this.getProps();(e||this.constraints||this.point)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:s}=this.getProps();this.panSession=new Nl(e,{onSessionStart:n,onStart:r,onMove:i,onSessionEnd:a,resumeAnimation:o},{...t,transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:s,contextWindow:this.visualElement.current?.ownerDocument.defaultView,element:this.visualElement.current})}stop(e,t,n){let r=e||this.latestPointerEvent,i=t||this.latestPanInfo,a=this.isDragging;if(this.cancel(),!a||!i||!r)return;let{velocity:o}=i;this.startAnimation(o,n);let{onDragEnd:s}=this.getProps();s&&V.postRender(()=>s(r,i))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession(),!this.getProps().dragPropagation&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t?.setActive(`whileDrag`,!1)}endPanSession(){this.panSession?.end(),this.panSession=void 0}updateAxis(e,t){let{drag:n}=this.readProps();if(!t||!fu(e,n,this.currentDirection))return;let r=this.getAxisMotionValue(e),i=this.originPoint[e]+t[e],a=this.constraints&&this.constraints[e];a&&(i=Jl(i,a,this.elastic[e])),this.point?this.point[e]=i:r.set(i)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),{projection:n}=this.visualElement,r=n&&(n.layout||n.measure(!1)),i=this.constraints;cu(e)?this.constraints&&this.scroll===au(n)||(this.constraints=this.resolveRefConstraints()):this.constraints=e&&r&&typeof e==`object`?Xl(r.layoutBox,e):!1,this.elastic=nu(t),i!==this.constraints&&!cu(e)&&r&&this.constraints&&!this.hasMutatedConstraints&&Sc(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=eu(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!cu(e))return!1;let n=lu(e),{projection:r}=this.visualElement;if(!r||!r.layout)return!1;this.scroll=au(r);let i=Oe(n,r.root,this.visualElement.getTransformPagePoint()),a=Ql(r.layout.layoutBox,r.removeElementScroll(i));if(t){let e=t(he(a));this.hasMutatedConstraints=!!e,e&&(a=st(e))}return a}startAnimation(e,t){let{drag:n,dragMomentum:r,dragElastic:i,dragTransition:a,dragSnapToOrigin:o,onDragTransitionEnd:s}=this.getProps(),c={bounceStiffness:i?200:1e6,bounceDamping:i?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...a},l=i=>r&&!(this.point&&o)&&fu(i,t||n,this.currentDirection)?e[i]:0;if(this.point&&!o)return this.point.release({x:l(`x`),y:l(`y`)},c).then(s);let u=this.constraints||{},d=Sc(e=>{if(!fu(e,t||n,this.currentDirection))return;let r=u[e]||{};(o===!0||o===e)&&(r={min:0,max:0});let i={type:`inertia`,velocity:l(e),...c,...r};return this.startAxisValueAnimation(e,i)});return Promise.all(d).then(s)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return _s(this.visualElement,e),n.start(le(e,n,0,t,this.visualElement,!1))}stopAnimation(){Sc(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`;return this.readProps()[t]||this.visualElement.getValue(e,this.visualElement.latestValues[e]??0)}snapToCursor({clientX:e,clientY:t}){let{drag:n}=this.getProps(),r={x:e,y:t},i=this.visualElement.getTransformPagePoint()?.(r)||r,a=this.visualElement.measureViewportBox();Sc(e=>{if(!fu(e,n,this.currentDirection))return;let t=this.getAxisMotionValue(e),{min:r,max:o}=a[e];t.set((t.get()||0)+i[e]-M(r,o,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!cu(t)||!n||!this.constraints)return;this.stopAnimation();let r=this.constraints,i={x:0,y:0};Sc(e=>{let t=this.getAxisMotionValue(e).get();i[e]=$l({min:t,max:t},r[e])});let{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},``):`none`,n.root?.updateScroll(),n.updateLayout(),this.constraints=!1,this.resolveConstraints(),Sc(t=>{let n=this.getAxisMotionValue(t);if(!fu(t,e,null)||!n.get())return;let{min:r,max:a}=this.constraints[t];n.set(M(r,a,i[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;ou.set(this.visualElement,this);let e=this.visualElement.current,t=hl(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&Wl(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps(),r=cu(t)&&lu(t);r&&(this.constraints=this.resolveRefConstraints(),n||=du(e,r,()=>this.scalePositionWithinConstraints()))},{projection:i}=this.visualElement,a=i.addEventListener(`measure`,r);i.layout||(i.root?.updateScroll(),i.updateLayout()),V.read(r);let o=al(window,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(Sc(t=>{if(!fu(t,this.getProps().drag,this.currentDirection))return;let n=this.getAxisMotionValue(t);this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate)}),this.visualElement.render())}));return()=>{o(),t(),a(),s(),n?.()}}getProps(){let e=this.readProps(),{dragElastic:t=tu,dragMomentum:n=!0}=e;return{...e,dragElastic:t,dragMomentum:n}}};function cu(e){return!!e&&typeof e==`object`&&(`current`in e||`nodeType`in e)}var lu=e=>`current`in e?e.current:e;function uu(e){let t=!0;return()=>{t?t=!1:e()}}function du(e,t,n){let r=kl(e,uu(n)),i=kl(t,uu(n));return()=>{r(),i()}}function fu(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function pu(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}function mu(e,t){let n=ee(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},ce(()=>r.abort())]}function hu(e){return!(e.pointerType===`touch`||Kl())}function gu(e,t,n={}){t=Ve(t);let[r,i,a]=mu(e,n);return r.forEach(e=>{let n=!1,r=!1,a,o=()=>{e.removeEventListener(`pointerleave`,u)},s=e=>{a&&=(a(e),void 0),o()},c=e=>{n=!1,window.removeEventListener(`pointerup`,c),window.removeEventListener(`pointercancel`,c),r&&(r=!1,s(e))},l=()=>{n=!0,window.addEventListener(`pointerup`,c,i),window.addEventListener(`pointercancel`,c,i)},u=e=>{e.pointerType!==`touch`&&(n?r=!0:s(e))};e.addEventListener(`pointerenter`,n=>{if(!hu(n))return;r=!1;let o=t(e,n);typeof o==`function`&&(a=o,e.addEventListener(`pointerleave`,u,i))},i),e.addEventListener(`pointerdown`,l,i)}),a}var _u=(e,t)=>t?e===t||_u(e,t.parentElement):!1,vu=new WeakSet;function yu(e){return t=>{t.key===`Enter`&&e(t)}}function bu(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}var xu=(e,t)=>{let n=!1,r=yu(()=>{n||vu.has(e)||(n=!0,bu(e,`down`))}),i=yu(()=>{n&&(n=!1,bu(e,`up`))});e.addEventListener(`keydown`,r,t),e.addEventListener(`keyup`,i,t),e.addEventListener(`blur`,()=>{e.removeEventListener(`keydown`,r),e.removeEventListener(`keyup`,i),n&&bu(e,`cancel`)},{...t,once:!0})};function Su(e){return fl(e)&&!Kl()}var Cu=new WeakSet,wu=100,Tu=8,Eu=(e,t,n)=>Math.hypot(e.clientX-t.clientX,e.clientY-t.clientY)>n,Du=e=>e.preventDefault();function Ou(e,t,n={}){t=Ve(t);let[r,i,a]=mu(e,n),o=new WeakMap,s=e=>{let r=e.currentTarget;if(!Su(e)||Cu.has(e))return;n.stopPropagation&&Cu.add(e);let{count:a=1,countTimeout:s=.3,hold:c=0,repeat:l}=n,u=Un.now(),d=jn(c),f=jn(s),p=o.get(r);p?.expire(Eu(p.event,e,wu))?p=void 0:p&&(bn(p.expire),o.delete(r));let m=p?p.count+1:1,h=m>=a,g=h&&(c||l),_=!c,v=0,y;if(vu.add(r),p)y=p.handlers;else{let n=t(r,e);y=typeof n==`function`?{onComplete:n}:n||{}}h&&_&&y.onActive?.();let b=jn(l),x=d||b,S=u+x,C=!0,w=()=>{if(i.signal.aborted)return bn(w);let e=Math.min(1-(S-Un.now())/x,1);C&&e<1&&(e=0),C=!1,y.onHold?.(e),e<1||(_?y.onRepeat?.(++v):(_=!0,y.onActive?.()),l?(C=!0,S+=x=b):bn(w))},T={...i,capture:!0},E=(t,n)=>{if(fl(t)){if(window.removeEventListener(`pointerup`,D,T),window.removeEventListener(`pointercancel`,O,T),window.removeEventListener(`pointermove`,k,T),r.removeEventListener(`contextmenu`,Du),bn(w),vu.delete(r),Kl()&&(n=!1),n&&!h){let n=Un.now(),a=e=>{let s=i.signal.aborted;if(s||e===!0||Un.now()-n>f)return bn(a),o.delete(r),s||y.onComplete?.(t,{success:!1}),!0};o.set(r,{count:m,event:e,handlers:y,expire:a}),V.update(a,!0)}else y.onComplete?.(t,{success:n&&_})}},D=e=>{E(e,r===window||r===document||n.useGlobalTarget||_u(r,e.target))},O=e=>{E(e,!1)},k=t=>{fl(t)&&((l||!_)&&Eu(e,t,Tu)||a>1&&Kl())&&O(t)};window.addEventListener(`pointerup`,D,T),window.addEventListener(`pointercancel`,O,T),(g||a>1)&&window.addEventListener(`pointermove`,k,T),g&&(V.update(w,!0),r.addEventListener(`contextmenu`,Du,{...i,passive:!1}))};return r.forEach(e=>{(n.useGlobalTarget?window:e).addEventListener(`pointerdown`,s,i),_o(e)&&(e.addEventListener(`focus`,()=>xu(e,i),i),!Hl(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function ku(...e){let t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],a=e[2+n],o=e[3+n],s=de(i,a,o);return t?s(r):s}var Au=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},ju=new Set([`baseFrequency`,`diffuseConstant`,`kernelMatrix`,`kernelUnitLength`,`keySplines`,`keyTimes`,`limitingConeAngle`,`markerHeight`,`markerWidth`,`numOctaves`,`targetX`,`targetY`,`surfaceScale`,`specularConstant`,`specularExponent`,`stdDeviation`,`tableValues`,`viewBox`,`gradientTransform`,`pathLength`,`startOffset`,`textLength`,`lengthAdjust`]);function Mu(e,t,n,r){ll(e,t,void 0,r);for(let n in t.attrs)e.setAttribute(ju.has(n)?n:te(n),t.attrs[n])}var Nu=class extends cl{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=H}getBaseTargetFromProps(e,t){return hn.has(t)?super.getBaseTargetFromProps(e,t)??gn(t):e[t]}getDefaultValue(e){return hn.has(e)?this.latestValues[e]??gn(e):void 0}readValueFromInstance(e,t){if(hn.has(t)){let e=pn(t);return e&&e.default||0}if(Nn.includes(t)){let n=getComputedStyle(e)[t];if(typeof n==`string`&&n)return n.trim()}return t=ju.has(t)?t:te(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return ma(e,t,n)}build(e,t,n){wn(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){Mu(e,t,n,r)}mount(e){this.isSVGTag=Ya(e.tagName),super.mount(e)}};function Pu(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}var Fu=[...Xi].reverse(),Iu=e=>e?.out===!0?e:e?.out;function Lu(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>Cs(e,t,n))),n=zu(),r=!0,i=!1;function a(a){let{props:o,parent:s,manuallyAnimateOnMount:c}=e,{initial:l}=o,u=r||i,d=[],f=(t=l)=>typeof t!=`boolean`&&us(e,Array.isArray(t)?t[0]:t,e.presenceContext?.custom)||void 0,p=new Map,m={},h=1/0,g=e;do g=g.props.inherit!==!1&&g.parent;while(g&&!g.isControllingVariants);let _=u&&Iu(f(l??(g&&g.props.initial))?.transition);if(Fu.forEach((t,r)=>{let i=n[t],l=o[t],f=g&&g.props[t],v=l===void 0?wi(f)||f===!1?f:void 0:l,y=wi(v),b=t===a?i.isActive:null,x=y&&l===void 0&&!(u&&c);if(i.protectedKeys={...m},!i.isActive&&b===null||!v&&!i.prevProp||$a(v)||typeof v==`boolean`)return;if(b===!1&&(h=r),t===`exit`&&i.isActive&&b!==!0){m={...m,...i.prevResolvedValues};return}let S=Ru(i.prevProp,v),C=S||y&&(b&&!x||r>h),w=!1,T=Array.isArray(v)?v:[v],E={},D;if(b!==!1)for(let n of T){let{transition:r,transitionEnd:i,...a}=us(e,n,ds(e,t))||{};E={...E,...a,...i},D=Iu(r)||D}let{prevResolvedValues:O}=i;for(let t in{...O,...E}){if(t in m)continue;let n=E[t],r=O[t],a=Array.isArray(n)&&Array.isArray(r)?!Pu(n,r)||S:n!==r,o;if(a&&n==null)p.has(t)||p.set(t,i.prevOut);else if(a||n!==void 0&&p.has(t)){C=!0,o=p.get(t)||_,p.delete(t)&&(w=!0),i.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)}else i.protectedKeys[t]=!0;i.out[t]=o}if(i.prevProp=v,i.prevResolvedValues=E,i.prevOut=D,i.isActive&&(m={...m,...E}),C&&(!(x&&S)||w))for(let n of T){let r={type:t};if(typeof n==`string`&&u&&c&&s?.enteringChildren){let t=us(s,n)?.transition?.delayChildren;r.delay=ls(s.enteringChildren,e,t)}d.push({animation:n,options:r})}}),p.size){let t={},n=f(),r=n?.transition;p.forEach((i,a)=>{i&&(r={...r||e.getDefaultTransition(),[a]:i});let s=e.getValue(a);s&&(s.liveStyle=!0);let c=n&&!Array.isArray(l)?n[a]:void 0,u=e.getBaseTargetFromProps(o,a);t[a]=(c===void 0?u!==void 0&&!En(u)?u:e.initialValues[a]===void 0?e.baseTarget[a]:void 0:c)??null}),r&&(t.transition=r),d.push({animation:t})}let v=u&&e.blockInitialAnimation||r&&!c&&(o.initial===!1||o.initial===o.animate);return r=i=!1,!v&&d.length?t(d):Promise.resolve()}function o(t,r){if(n[t].isActive===r)return Promise.resolve();e.variantChildren?.forEach(e=>e.animationState?.setActive(t,r)),n[t].isActive=r;let i=a(t);for(let e in n)n[e].protectedKeys={};return i}return{animateChanges:a,setActive:o,setAnimateFunction:n=>{t=n(e)},getState:()=>n,reset:()=>{n=zu(),i=!0}}}function Ru(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!Pu(t,e):!1}function zu(){let e={};for(let t of Xi)e[t]={isActive:t===`animate`,protectedKeys:{},needsAnimating:{},prevResolvedValues:{},out:{}};return e}var Bu=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g,Vu=e=>{let t=Bu();return e.match(t)?.[0]},W=Xt(),G=t(Rt(),1),Hu=e=>{let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t=(t<<5)-t+r,t&=t}return Math.abs(t)},Uu=(e,t)=>Math.floor(e/10**t%10),Wu=(e,t)=>!(Uu(e,t)%2),K=(e,t,n)=>{let r=e%t;return n&&Uu(e,n)%2==0?-r:r},Gu=(e,t,n)=>t[e%n],Ku=e=>{e.slice(0,1)===`#`&&(e=e.slice(1));let t=parseInt(e.substr(0,2),16),n=parseInt(e.substr(2,2),16),r=parseInt(e.substr(4,2),16);return(t*299+n*587+r*114)/1e3>=128?`#000000`:`#FFFFFF`},qu=4,q=80;function Ju(e,t){let n=Hu(e),r=t&&t.length;return Array.from({length:qu},(e,i)=>({color:Gu(n+i,t,r),translateX:K(n*(i+1),q/2-(i+17),1),translateY:K(n*(i+1),q/2-(i+17),2),rotate:K(n*(i+1),360),isSquare:Wu(n,2)}))}var Yu=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Ju(e,t),s=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:q,height:q,children:(0,W.jsx)(`rect`,{width:q,height:q,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,W.jsx)(`rect`,{width:q,height:q,fill:o[0].color}),(0,W.jsx)(`rect`,{x:10,y:30,width:q,height:o[1].isSquare?q:q/8,fill:o[1].color,transform:`translate(`+o[1].translateX+` `+o[1].translateY+`) rotate(`+o[1].rotate+` 40 40)`}),(0,W.jsx)(`circle`,{cx:q/2,cy:q/2,fill:o[2].color,r:q/5,transform:`translate(`+o[2].translateX+` `+o[2].translateY+`)`}),(0,W.jsx)(`line`,{x1:0,y1:q/2,x2:q,y2:q/2,strokeWidth:2,stroke:o[3].color,transform:`translate(`+o[3].translateX+` `+o[3].translateY+`) rotate(`+o[3].rotate+` 40 40)`})]})]})},Xu=90,Zu=5;function Qu(e,t){let n=Hu(e),r=t&&t.length,i=Array.from({length:Zu},(e,i)=>Gu(n+i,t,r)),a=[];return a[0]=i[0],a[1]=i[1],a[2]=i[1],a[3]=i[2],a[4]=i[2],a[5]=i[3],a[6]=i[3],a[7]=i[0],a[8]=i[4],a}var $u=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Qu(e,t),s=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 90 90`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:Xu,height:Xu,children:(0,W.jsx)(`rect`,{width:Xu,height:Xu,rx:r?void 0:180,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,W.jsx)(`path`,{d:`M0 0h90v45H0z`,fill:o[0]}),(0,W.jsx)(`path`,{d:`M0 45h90v45H0z`,fill:o[1]}),(0,W.jsx)(`path`,{d:`M83 45a38 38 0 00-76 0h76z`,fill:o[2]}),(0,W.jsx)(`path`,{d:`M83 45a38 38 0 01-76 0h76z`,fill:o[3]}),(0,W.jsx)(`path`,{d:`M77 45a32 32 0 10-64 0h64z`,fill:o[4]}),(0,W.jsx)(`path`,{d:`M77 45a32 32 0 11-64 0h64z`,fill:o[5]}),(0,W.jsx)(`path`,{d:`M71 45a26 26 0 00-52 0h52z`,fill:o[6]}),(0,W.jsx)(`path`,{d:`M71 45a26 26 0 01-52 0h52z`,fill:o[7]}),(0,W.jsx)(`circle`,{cx:45,cy:45,r:23,fill:o[8]})]})]})},ed=64,td=80;function nd(e,t){let n=Hu(e),r=t&&t.length;return Array.from({length:ed},(e,i)=>Gu(n%(i+1),t,r))}var rd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=nd(e,t),s=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:s,"mask-type":`alpha`,maskUnits:`userSpaceOnUse`,x:0,y:0,width:td,height:td,children:(0,W.jsx)(`rect`,{width:td,height:td,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,W.jsx)(`rect`,{width:10,height:10,fill:o[0]}),(0,W.jsx)(`rect`,{x:20,width:10,height:10,fill:o[1]}),(0,W.jsx)(`rect`,{x:40,width:10,height:10,fill:o[2]}),(0,W.jsx)(`rect`,{x:60,width:10,height:10,fill:o[3]}),(0,W.jsx)(`rect`,{x:10,width:10,height:10,fill:o[4]}),(0,W.jsx)(`rect`,{x:30,width:10,height:10,fill:o[5]}),(0,W.jsx)(`rect`,{x:50,width:10,height:10,fill:o[6]}),(0,W.jsx)(`rect`,{x:70,width:10,height:10,fill:o[7]}),(0,W.jsx)(`rect`,{y:10,width:10,height:10,fill:o[8]}),(0,W.jsx)(`rect`,{y:20,width:10,height:10,fill:o[9]}),(0,W.jsx)(`rect`,{y:30,width:10,height:10,fill:o[10]}),(0,W.jsx)(`rect`,{y:40,width:10,height:10,fill:o[11]}),(0,W.jsx)(`rect`,{y:50,width:10,height:10,fill:o[12]}),(0,W.jsx)(`rect`,{y:60,width:10,height:10,fill:o[13]}),(0,W.jsx)(`rect`,{y:70,width:10,height:10,fill:o[14]}),(0,W.jsx)(`rect`,{x:20,y:10,width:10,height:10,fill:o[15]}),(0,W.jsx)(`rect`,{x:20,y:20,width:10,height:10,fill:o[16]}),(0,W.jsx)(`rect`,{x:20,y:30,width:10,height:10,fill:o[17]}),(0,W.jsx)(`rect`,{x:20,y:40,width:10,height:10,fill:o[18]}),(0,W.jsx)(`rect`,{x:20,y:50,width:10,height:10,fill:o[19]}),(0,W.jsx)(`rect`,{x:20,y:60,width:10,height:10,fill:o[20]}),(0,W.jsx)(`rect`,{x:20,y:70,width:10,height:10,fill:o[21]}),(0,W.jsx)(`rect`,{x:40,y:10,width:10,height:10,fill:o[22]}),(0,W.jsx)(`rect`,{x:40,y:20,width:10,height:10,fill:o[23]}),(0,W.jsx)(`rect`,{x:40,y:30,width:10,height:10,fill:o[24]}),(0,W.jsx)(`rect`,{x:40,y:40,width:10,height:10,fill:o[25]}),(0,W.jsx)(`rect`,{x:40,y:50,width:10,height:10,fill:o[26]}),(0,W.jsx)(`rect`,{x:40,y:60,width:10,height:10,fill:o[27]}),(0,W.jsx)(`rect`,{x:40,y:70,width:10,height:10,fill:o[28]}),(0,W.jsx)(`rect`,{x:60,y:10,width:10,height:10,fill:o[29]}),(0,W.jsx)(`rect`,{x:60,y:20,width:10,height:10,fill:o[30]}),(0,W.jsx)(`rect`,{x:60,y:30,width:10,height:10,fill:o[31]}),(0,W.jsx)(`rect`,{x:60,y:40,width:10,height:10,fill:o[32]}),(0,W.jsx)(`rect`,{x:60,y:50,width:10,height:10,fill:o[33]}),(0,W.jsx)(`rect`,{x:60,y:60,width:10,height:10,fill:o[34]}),(0,W.jsx)(`rect`,{x:60,y:70,width:10,height:10,fill:o[35]}),(0,W.jsx)(`rect`,{x:10,y:10,width:10,height:10,fill:o[36]}),(0,W.jsx)(`rect`,{x:10,y:20,width:10,height:10,fill:o[37]}),(0,W.jsx)(`rect`,{x:10,y:30,width:10,height:10,fill:o[38]}),(0,W.jsx)(`rect`,{x:10,y:40,width:10,height:10,fill:o[39]}),(0,W.jsx)(`rect`,{x:10,y:50,width:10,height:10,fill:o[40]}),(0,W.jsx)(`rect`,{x:10,y:60,width:10,height:10,fill:o[41]}),(0,W.jsx)(`rect`,{x:10,y:70,width:10,height:10,fill:o[42]}),(0,W.jsx)(`rect`,{x:30,y:10,width:10,height:10,fill:o[43]}),(0,W.jsx)(`rect`,{x:30,y:20,width:10,height:10,fill:o[44]}),(0,W.jsx)(`rect`,{x:30,y:30,width:10,height:10,fill:o[45]}),(0,W.jsx)(`rect`,{x:30,y:40,width:10,height:10,fill:o[46]}),(0,W.jsx)(`rect`,{x:30,y:50,width:10,height:10,fill:o[47]}),(0,W.jsx)(`rect`,{x:30,y:60,width:10,height:10,fill:o[48]}),(0,W.jsx)(`rect`,{x:30,y:70,width:10,height:10,fill:o[49]}),(0,W.jsx)(`rect`,{x:50,y:10,width:10,height:10,fill:o[50]}),(0,W.jsx)(`rect`,{x:50,y:20,width:10,height:10,fill:o[51]}),(0,W.jsx)(`rect`,{x:50,y:30,width:10,height:10,fill:o[52]}),(0,W.jsx)(`rect`,{x:50,y:40,width:10,height:10,fill:o[53]}),(0,W.jsx)(`rect`,{x:50,y:50,width:10,height:10,fill:o[54]}),(0,W.jsx)(`rect`,{x:50,y:60,width:10,height:10,fill:o[55]}),(0,W.jsx)(`rect`,{x:50,y:70,width:10,height:10,fill:o[56]}),(0,W.jsx)(`rect`,{x:70,y:10,width:10,height:10,fill:o[57]}),(0,W.jsx)(`rect`,{x:70,y:20,width:10,height:10,fill:o[58]}),(0,W.jsx)(`rect`,{x:70,y:30,width:10,height:10,fill:o[59]}),(0,W.jsx)(`rect`,{x:70,y:40,width:10,height:10,fill:o[60]}),(0,W.jsx)(`rect`,{x:70,y:50,width:10,height:10,fill:o[61]}),(0,W.jsx)(`rect`,{x:70,y:60,width:10,height:10,fill:o[62]}),(0,W.jsx)(`rect`,{x:70,y:70,width:10,height:10,fill:o[63]})]})]})},J=36;function id(e,t){let n=Hu(e),r=t&&t.length,i=Gu(n,t,r),a=K(n,10,1),o=a<5?a+J/9:a,s=K(n,10,2),c=s<5?s+J/9:s;return{wrapperColor:i,faceColor:Ku(i),backgroundColor:Gu(n+13,t,r),wrapperTranslateX:o,wrapperTranslateY:c,wrapperRotate:K(n,360),wrapperScale:1+K(n,J/12)/10,isMouthOpen:Wu(n,2),isCircle:Wu(n,1),eyeSpread:K(n,5),mouthSpread:K(n,3),faceRotate:K(n,10,3),faceTranslateX:o>J/6?o/2:K(n,8,1),faceTranslateY:c>J/6?c/2:K(n,7,2)}}var ad=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=id(e,t),s=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 36 36`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:J,height:J,children:(0,W.jsx)(`rect`,{width:J,height:J,rx:r?void 0:72,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,W.jsx)(`rect`,{width:J,height:J,fill:o.backgroundColor}),(0,W.jsx)(`rect`,{x:`0`,y:`0`,width:J,height:J,transform:`translate(`+o.wrapperTranslateX+` `+o.wrapperTranslateY+`) rotate(`+o.wrapperRotate+` 18 18) scale(`+o.wrapperScale+`)`,fill:o.wrapperColor,rx:o.isCircle?J:J/6}),(0,W.jsxs)(`g`,{transform:`translate(`+o.faceTranslateX+` `+o.faceTranslateY+`) rotate(`+o.faceRotate+` 18 18)`,children:[o.isMouthOpen?(0,W.jsx)(`path`,{d:`M15 `+(19+o.mouthSpread)+`c2 1 4 1 6 0`,stroke:o.faceColor,fill:`none`,strokeLinecap:`round`}):(0,W.jsx)(`path`,{d:`M13,`+(19+o.mouthSpread)+` a1,0.75 0 0,0 10,0`,fill:o.faceColor}),(0,W.jsx)(`rect`,{x:14-o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor}),(0,W.jsx)(`rect`,{x:20+o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor})]})]})]})},od=4,sd=80;function cd(e,t){let n=Hu(e),r=t&&t.length;return Array.from({length:od},(e,i)=>Gu(n+i,t,r))}var ld=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=cd(e,t),s=e.replace(/\s/g,``),c=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:c,maskUnits:`userSpaceOnUse`,x:0,y:0,width:sd,height:sd,children:(0,W.jsx)(`rect`,{width:sd,height:sd,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${c})`,children:[(0,W.jsx)(`path`,{fill:`url(#gradient_paint0_linear_`+s+`)`,d:`M0 0h80v40H0z`}),(0,W.jsx)(`path`,{fill:`url(#gradient_paint1_linear_`+s+`)`,d:`M0 40h80v40H0z`})]}),(0,W.jsxs)(`defs`,{children:[(0,W.jsxs)(`linearGradient`,{id:`gradient_paint0_linear_`+s,x1:sd/2,y1:0,x2:sd/2,y2:sd/2,gradientUnits:`userSpaceOnUse`,children:[(0,W.jsx)(`stop`,{stopColor:o[0]}),(0,W.jsx)(`stop`,{offset:1,stopColor:o[1]})]}),(0,W.jsxs)(`linearGradient`,{id:`gradient_paint1_linear_`+s,x1:sd/2,y1:sd/2,x2:sd/2,y2:sd,gradientUnits:`userSpaceOnUse`,children:[(0,W.jsx)(`stop`,{stopColor:o[2]}),(0,W.jsx)(`stop`,{offset:1,stopColor:o[3]})]})]})]})},ud=3,dd=80;function fd(e,t){let n=Hu(e),r=t&&t.length;return Array.from({length:ud},(e,i)=>({color:Gu(n+i,t,r),translateX:K(n*(i+1),dd/10,1),translateY:K(n*(i+1),dd/10,2),scale:1.2+K(n*(i+1),dd/20)/10,rotate:K(n*(i+1),360,1)}))}var pd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=fd(e,t),s=G.useId();return(0,W.jsxs)(`svg`,{viewBox:`0 0 80 80`,fill:`none`,role:`img`,xmlns:`http://www.w3.org/2000/svg`,width:i,height:i,...a,children:[n&&(0,W.jsx)(`title`,{children:e}),(0,W.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:dd,height:dd,children:(0,W.jsx)(`rect`,{width:dd,height:dd,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,W.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,W.jsx)(`rect`,{width:dd,height:dd,fill:o[0].color}),(0,W.jsx)(`path`,{filter:`url(#filter_${s})`,d:`M32.414 59.35L50.376 70.5H72.5v-71H33.728L26.5 13.381l19.057 27.08L32.414 59.35z`,fill:o[1].color,transform:`translate(`+o[1].translateX+` `+o[1].translateY+`) rotate(`+o[1].rotate+` 40 40) scale(`+o[2].scale+`)`}),(0,W.jsx)(`path`,{filter:`url(#filter_${s})`,style:{mixBlendMode:`overlay`},d:`M22.216 24L0 46.75l14.108 38.129L78 86l-3.081-59.276-22.378 4.005 12.972 20.186-23.35 27.395L22.215 24z`,fill:o[2].color,transform:`translate(`+o[2].translateX+` `+o[2].translateY+`) rotate(`+o[2].rotate+` 40 40) scale(`+o[2].scale+`)`})]}),(0,W.jsx)(`defs`,{children:(0,W.jsxs)(`filter`,{id:`filter_${s}`,filterUnits:`userSpaceOnUse`,colorInterpolationFilters:`sRGB`,children:[(0,W.jsx)(`feFlood`,{floodOpacity:0,result:`BackgroundImageFix`}),(0,W.jsx)(`feBlend`,{in:`SourceGraphic`,in2:`BackgroundImageFix`,result:`shape`}),(0,W.jsx)(`feGaussianBlur`,{stdDeviation:7,result:`effect1_foregroundBlur`})]})})]})},md={pixel:rd,bauhaus:Yu,ring:$u,beam:ad,sunset:ld,marble:pd,geometric:ad,abstract:Yu},hd=({variant:e=`marble`,colors:t=[`#92A1C6`,`#146A7C`,`#F0AB3D`,`#C271B4`,`#C20D90`],name:n=`Clara Barton`,title:r=!1,size:i=`40px`,square:a=!1,...o})=>{let s=md[e]||pd;return(0,W.jsx)(s,{colors:t,name:n,title:r,size:i,square:a,...o})},gd=Lt({block:`img`,elements:[]}),_d=e=>(0,G.memo)(t=>(0,G.createElement)(e,t)),vd=({unoptimized:e,...t})=>{let n=(0,G.use)(w),r=n?.imgAs||`img`,i=(0,G.useMemo)(()=>_d(r),[r]);return(0,W.jsx)(i,{unoptimized:e===void 0?n?.imgUnoptimized:e,...t,className:B(gd(),t.className)})};vd.displayName=`Img`;var yd=Lt({block:`fluent-emoji`,elements:[]}),bd={container:{kLWn49:`lbo5v014`,kVAEAm:`lb1n2onr6`,k9WMMc:`lb2b8uid`,$$css:!0}};function xd(e){return[...e].map(e=>e?.codePointAt(0)?.toString(16)).join(`-`)}function Sd(e){let t=xd(e).split(`-`)[0];return t<`1f469`?`@lobehub/fluent-emoji-anim-1`:t>=`1f469`&&t<`1f620`?`@lobehub/fluent-emoji-anim-2`:t>=`1f620`&&t<`1f9a0`?`@lobehub/fluent-emoji-anim-3`:`@lobehub/fluent-emoji-anim-4`}var Cd=(e,t)=>{let n=[`anim`,`3d`].includes(t)?`webp`:`svg`;switch(t){case`raw`:return null;case`anim`:return{path:`assets/${xd(e)}.${n}`,pkg:Sd(e),version:`latest`};case`3d`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-3d`,version:`latest`};case`flat`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-flat`,version:`latest`};case`modern`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-modern`,version:`latest`};case`mono`:return{path:`assets/${xd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-mono`,version:`latest`}}},wd=({emoji:e,className:t,style:n,type:r=`3d`,size:i=40,unoptimized:a,ref:o,...s})=>{let[c,l]=(0,G.useState)(!1),u=ae(),d=(0,G.useMemo)(()=>Cd(e,r),[r,e]);return r===`raw`||!d||c?(0,W.jsx)(yn,{flex:`none`,height:i,ref:o,role:`img`,width:i,...s,...z(bd.container,B(yd(),t),{fontSize:i*.9,...n}),children:e}):(0,W.jsx)(vd,{alt:e,className:B(yd(),t),height:i,loading:`lazy`,ref:o,src:u(d),style:{flex:`none`,...n},unoptimized:a,width:i,onError:()=>l(!0),...s})};wd.displayName=`FluentEmoji`;var Td=e=>`oklch(from ${e} clamp(0, (l - 0.62) * -1000, 1) 0 h / 1)`,Ed=Lt({block:`avatar`,dataAttributes:[`shape`,`variant`,`shadow`],elements:[`loading`,`img`,`content`,`fallback`]}),Dd=Lt({block:`avatar-group`,elements:[`avatar`,`count`,`item`,`badge`]}),Od={circle:{kaIpWk:`lb16rqkct`,$$css:!0},clickable:{kkrTdU:`lb1ypdohk`,$$css:!0},defaultBackground:{kWkggS:`lb1yqcoyj`,$$css:!0},defaultColor:{kMwMTN:`lb6dwly7`,$$css:!0},defaultEmojiFont:{kGuDYH:`lbh7pmyk`,$$css:!0},defaultSize:{kGuDYH:`lb1pvqxga`,kZKoxP:`lbsdox4t`,kzqmXN:`lb1useyqa`,$$css:!0},defaultSquare:{kaIpWk:`lbur7f20`,$$css:!0},content:{kmVPX3:`lb1717udv`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kMwMTN:`lb1heor9g`,k1xSpc:`lb78zum5`,kGuDYH:`lb1qlqyl8`,k63SB2:`lbjs9k72`,kjj79g:`lbl56j7k`,kLWn49:`lbo5v014`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},fallback:{kUk6DE:`lb1okw0bk`,k1xSpc:`lb1lliihq`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},img:{kUk6DE:`lb1okw0bk`,kVIFPx:`lbl1xv1r`,kZKoxP:`lb5yr21d`,kzqmXN:`lbh8yej3`,$$css:!0},loading:{kpwlN0:`lb10a8y8t`,kWkggS:`lb1a3x57l`,kMwMTN:`lbfungia`,kVAEAm:`lb10l6tqk`,$$css:!0},root:{kUk6DE:`lb1okw0bk`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kWkggS:`lbjbqb8w`,k1xSpc:`lb78zum5`,kjj79g:`lbl56j7k`,kVAEAm:`lb1n2onr6`,kfSwDN:`lb87ps6o`,$$css:!0},shadow:{kGVxlE:`lbpjwdtl`,$$css:!0}},kd=e=>e?!!(typeof e==`string`&&[`/`,`http`,`data:`].some(t=>e.startsWith(t))||(0,G.isValidElement)(e)):!1,Ad=e=>!!(e&&e!==`transparent`&&e!==`rgba(0,0,0,0)`&&e!==null),jd=(e,t)=>{if(!e)return``;let n=e.toUpperCase();return t?n.slice(0,2):n},Md=(e,t,n)=>n?t?e*.85:e:e*.85,Nd=[`#383838`,`#7858f9`,`#f8f7bf`,`#ffdd1f`,`#f88c13`],Pd=(e,t,n)=>(t||n||typeof e==`string`&&e||void 0)?.trim().replaceAll(/[\s"'()#\\]+/g,`_`)||void 0,Fd={borderless:se.variantBorderlessWithoutHover,filled:se.variantFilledWithoutHover,outlined:se.variantOutlinedWithoutHover},Id=(0,G.memo)(({alt:e,animation:t,avatar:n,background:r,bordered:i,borderedColor:a,className:o,classNames:s,crossOrigin:c,draggable:l=!1,emojiScaleWithBackground:u=!0,fallbackColors:d,fallbackVariant:f=`marble`,loading:p,ref:m,shadow:h,shape:g=`square`,size:_,sliceText:v=!0,style:y,styles:b,title:x,tooltipProps:S,unoptimized:C,variant:w=`borderless`,xstyle:T,contentXstyle:E,nativeTitle:D,...O})=>{let k=_??48,ee=typeof n==`string`,[A,te]=(0,G.useState)(!1),j=(0,G.useMemo)(()=>kd(n),[n]),ne=(0,G.useMemo)(()=>n&&ee&&!j?Vu(n):void 0,[n,ee,j]),M=j?x:typeof n==`string`?n:void 0,N=e||x||`avatar`,re=Ad(r),ie=j&&ee&&!A,ae=j&&!ee&&!A,P=Pd(n,x,e),oe=f!==`text`&&!!P&&!ne&&!ie&&!ae,F=d?.length?d:Nd,se=(0,G.useMemo)(()=>ne?(0,W.jsx)(wd,{emoji:ne,size:Md(k,re,u),type:t?`anim`:`3d`,unoptimized:C}):jd(M||x,v),[t,ne,re,k,v,M,x,C,u]),ce=_!==void 0,le=!r&&!oe&&!(j&&!A||ne);return(0,W.jsxs)(`div`,{...It({shadow:h,shape:g,variant:w}),...O,ref:m,title:D,className:z([Od.root,Fd[w],h&&Od.shadow,!ce&&Od.defaultSize,!ce&&!!ne&&Od.defaultEmojiFont,g===`circle`?Od.circle:!ce&&Od.defaultSquare,le&&Od.defaultBackground,!r&&Od.defaultColor,!!O?.onClick&&Od.clickable,T],B(Ed(),o,s?.root)).className,style:{...r&&{backgroundColor:r,color:Td(r)},...ce&&{fontSize:k*(ne?.7:.5),height:k,width:k,...g!==`circle`&&{borderRadius:k<24?`33%`:Math.max(k/6,2)}},...i&&{boxShadow:`${He.colorBgLayout} 0 0 0 2px, ${a||He.colorTextTertiary} 0 0 0 4px`},...y,...b?.root},children:[p&&(0,W.jsx)(yn,{flex:`none`,height:`100%`,width:`100%`,...z(Od.loading,B(Ed(`loading`),s?.loading),b?.loading),children:(0,W.jsx)(Ct,{spin:!0,icon:Ue})}),typeof n==`string`&&ie&&(0,W.jsx)(`img`,{alt:N,crossOrigin:c,draggable:l,height:k,loading:`lazy`,src:n,width:k,...z(Od.img,B(Ed(`img`),s?.img),b?.img),onError:()=>te(!0)}),oe&&(0,W.jsx)(hd,{square:!0,"aria-label":N,colors:F,name:P,size:`100%`,variant:f,...z(Od.fallback,B(Ed(`fallback`),s?.fallback),b?.fallback)}),!ie&&!oe&&(0,W.jsx)(`span`,{...z([Od.content,E],B(Ed(`content`),s?.content),b?.content),children:ae?n:se})]})});Id.displayName=`Avatar`;var Ld=Id,Rd={avatar:{kVAM5u:`lbfbyuaw`,ksu8eU:`lb1y0btm7`,kMzoRj:`lbdh2fpr`,$$css:!0},root:{kVAEAm:`lb1n2onr6`,$$css:!0},count:{kMwMTN:`lb15g0kca`,kGuDYH:`lbsfzzmd`,$$css:!0},item:{kUk6DE:`lb1okw0bk`,k1xSpc:`lb3nfvp2`,kVAEAm:`lb1n2onr6`,$$css:!0},badge:{k1xSpc:`lb78zum5`,kt4wiu:`lbtijo5x`,kfzvcC:`lb47corl`,kVAEAm:`lb10l6tqk`,k3aq6I:`lbdu4413`,krVfgx:`lb1ey2m1c`,$$css:!0}},zd=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.currentTarget.click())},Bd=(0,G.memo)(({items:e,max:t,gap:n,variant:r=`borderless`,bordered:i,shadow:a,size:o,background:s,animation:c,draggable:l,fallbackColors:u,fallbackVariant:d,classNames:f,shape:p,styles:m,onClick:h,ref:g,zIndexReverse:_,className:v,...y})=>{let b=o??48,x=t?e.slice(0,t):e,S=e.slice(t,e.length),C=n??Math.floor(-b/4),w=S.map(e=>e.title??e.label??e.alt).filter(Boolean).join(`, `),T={animation:c,background:s,bordered:i,draggable:l,fallbackColors:u,fallbackVariant:d,shadow:a,shape:p,size:o,variant:r};return(0,W.jsxs)(dn,{horizontal:!0,gap:n,ref:g,...z(Rd.root,B(Dd(),v)),...y,children:[x.map((t,n)=>{let{key:r,style:i,className:a,ringColor:o,label:s,pressed:c,disabled:l,badge:u,onClick:d,...p}=t,g=!l&&(!!h||!!d),v={marginLeft:n===0?0:C,zIndex:u?e.length+1:_?e.length-n:n},y=(0,W.jsx)(Id,{"aria-disabled":l||void 0,"aria-label":s,"aria-pressed":g?!!c:void 0,className:B(Dd(`avatar`),f?.avatar,a),nativeTitle:s,role:g?`button`:void 0,tabIndex:g?0:void 0,xstyle:Rd.avatar,style:{...!u&&v,...o&&{boxShadow:`0 0 0 2px ${o}`},...m?.avatar,...i},onKeyDown:g?zd:void 0,onClick:g?d??(()=>h?.({item:t,key:r})):void 0,...T,...p},u?void 0:r);if(!u)return y;let b=z(Rd.item,Dd(`item`));return(0,W.jsxs)(`span`,{className:b.className,style:{...b.style,...v},children:[y,(0,W.jsx)(`span`,{...z(Rd.badge,Dd(`badge`)),children:u})]},r)}),t&&S.length>0&&(0,W.jsx)(Id,{...T,"aria-label":w||void 0,avatar:`+${S.length}`,background:He.colorText,className:B(Dd(`count`),f?.count),contentXstyle:Rd.count,fallbackVariant:`text`,nativeTitle:w||void 0,sliceText:!1,xstyle:Rd.avatar,style:{marginLeft:C,zIndex:_?0:x.length,...m?.count}})]})});Bd.displayName=`AvatarGroup`;var Vd=Ld;Vd.Group=Bd;function Hd({children:e,features:t,strict:n=!1}){let[,r]=(0,G.useState)(!Ud(t)),i=(0,G.useRef)(void 0);if(!Ud(t)){let{renderer:e,...n}=t;i.current=e,Va(n)}return(0,G.useEffect)(()=>{Ud(t)&&t().then(({renderer:e,...t})=>{Va(t),i.current=e,r(!0)})},[]),(0,W.jsx)(Fi.Provider,{value:{renderer:i.current,strict:n},children:e})}function Ud(e){return typeof e==`function`}function Wd(e,t){if(typeof Proxy>`u`)return ia;let n=new Map,r=(n,r)=>ia(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,ia(a,void 0,e,t)),n.get(a))})}var Gd=Wd(),Kd=(e,t)=>t.isSVG??Ea(e)?new Nu(t):new dl(t,{allowProjection:e!==G.Fragment}),qd=class extends Au{constructor(e){super(e),e.animationState||=Lu(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();$a(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){this.node.getProps().animate!==this.node.prevProps?.animate&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}},Jd=0,Yd={animation:{Feature:qd},exit:{Feature:class extends Au{constructor(){super(...arguments),this.id=Jd++}update(){let{presenceContext:e,animationState:t}=this.node;if(!e||!t)return;let{isPresent:n,onExitComplete:r}=e;if(n===!this.exit)return;if(n){if(this.exit===!0){let{initial:e}=this.node.getProps();if(e&&!Array.isArray(e)){let{transition:t,transitionEnd:n,...r}=us(this.node,e)||{};for(let e in r)this.node.getValue(e)?.jump(r[e])}this.node.blockInitialAnimation=!1,t.reset(),t.animateChanges()}else t.setActive(`exit`,!1);this.exit=void 0;return}let i=this.exit=t.setActive(`exit`,!0);r&&i.then(()=>{this.exit===i&&(this.exit=!0,r(this.id))})}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id,this.node)),this.update()}unmount(){}}}},Xd=class extends Au{constructor(e){super(e),this.removeGroupControls=xn,this.removeListeners=xn,this.controls=new su(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||xn}update(){let{dragControls:e,drag:t}=this.node.getProps(),{dragControls:n,drag:r}=this.node.prevProps||{};e!==n&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls))),r&&!t&&this.controls.stop(void 0,void 0,r)}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}},Zd=e=>(t,n)=>{e&&V.update(()=>e(t,n),!1,!0)},Qd=class extends Au{constructor(){super(...arguments),this.removePointerDownListener=xn}onPointerDown(e){this.session=new Nl(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:this.node.current?.ownerDocument.defaultView})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Zd(e),onStart:Zd(t),onMove:Zd(n),onEnd:(e,t)=>{delete this.session,r&&V.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=hl(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session?.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session?.end()}},$d=!1,ef=({layout:e,layoutDependency:t,layoutAnchor:n})=>({layout:e,layoutDependency:t,layoutAnchor:n,animationType:typeof e==`string`?e:`both`}),tf=(e,t)=>{let{snapshot:n}=e,r=e.getStack();r?.remove(e);let i=r?.lead;if(r?.prevLead===e&&i.resumeFrom===e&&(i.resumeFrom=i.currentAnimation=e.resumingFrom=void 0),e.options.layoutId=t,!t)e.needsShow=!0;else return e.root.registerSharedNode(t,e),()=>{let{resumeFrom:t}=e;t?.isPresent!==!1&&e.getStack().members.includes(t)&&(t.hide(),e.resumeFrom=void 0,e.snapshot=n)}},nf=class extends G.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;i&&(t.group?.add(i),r&&n?.register?.(i),$d&&i.root.didUpdate(),i.options.layoutId!==r&&tf(i,r)?.(),i.addEventListener(`animationComplete`,()=>this.safeToRemove()),i.setOptions({...i.options,...ef(this.props),onExitComplete:()=>this.safeToRemove()})),Tc.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,layoutId:n,visualElement:r,drag:i,isPresent:a}=this.props,{projection:o}=r;return o&&(o.isPresent=a,this.takeOver=e.layoutId===n?void 0:(o.willUpdate(),tf(o,n)),o.setOptions({...o.options,...ef(this.props)}),$d=!0,i||e.layoutDependency!==t||t===void 0||e.isPresent!==a?o.willUpdate():this.safeToRemove(),e.isPresent!==a&&(a?o.promote():o.relegate()||V.postRender(()=>{o.getStack()?.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(this.takeOver?.(),e.root.didUpdate(),zn.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;$d=!0,r&&(r.scheduleCheckAfterUnmount(),t.group?.remove(r),n?.deregister?.(r))}safeToRemove(){this.props.safeToRemove?.()}render(){return null}};function rf(e){let[t,n]=be(),r=(0,G.useContext)(Sn);return(0,W.jsx)(nf,{...e,layoutGroup:r,switchLayoutGroup:(0,G.useContext)(Oi),isPresent:t,safeToRemove:n})}var af={pan:{Feature:Qd},drag:{Feature:Xd,ProjectionNode:sl,MeasureLayout:rf}};function of(e,t,n,r,i){let{props:a}=e,o=`while`+n;!i&&e.animationState&&a[o]&&e.animationState.setActive(o,r===`Start`);let s=a[`on`+n+r];s&&V.postRender(()=>s(t,pl(t)))}var sf=class extends Au{mount(){let{current:e}=this.node;e&&(this.unmount=gu(e,(e,t)=>(of(this.node,t,`Hover`,`Start`),e=>of(this.node,e,`Hover`,`End`))))}unmount(){}},cf=class extends Au{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(`:focus-visible`)}catch{e=!0}e&&this.node.animationState&&(this.node.animationState.setActive(`whileFocus`,!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive(`whileFocus`,!1),this.isActive=!1)}mount(){this.unmount=ne(al(this.node.current,`focus`,()=>this.onFocus()),al(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}};function lf(e,t,n,r){e.current instanceof HTMLButtonElement&&e.current.disabled||of(e,t,`Tap`,n,r)}var uf=class extends Au{constructor(){super(...arguments),this.options={}}mount(){let{current:e}=this.node;e&&(this.update(),this.unmount=Ou(e,(e,t)=>(lf(this.node,t,`Start`),{onComplete:(e,{success:t})=>lf(this.node,e,t?``:`Cancel`),onRepeat:()=>lf(this.node,t,``,!0)}),this.options))}update(){let{options:e,node:t}=this,{globalTapTarget:n,propagate:r,tap:i}=t.props;for(let t in e)delete e[t];Object.assign(e,i,{useGlobalTarget:n,stopPropagation:r?.tap===!1})}unmount(){}},df=new WeakMap,ff=new WeakMap,pf=e=>{let t=df.get(e.target);t&&t(e)},mf=e=>{e.forEach(pf)};function hf({root:e,...t}){let n=e||document;ff.has(n)||ff.set(n,{});let r=ff.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(mf,{root:e,...t})),r[i]}function gf(e,t,n){let r=hf(t);return df.set(e,n),r.observe(e),()=>{df.delete(e),r.unobserve(e)}}var _f={some:0,all:1},vf=class extends Au{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r=`some`,once:i}=e,a={root:t?t.current:void 0,rootMargin:n,threshold:typeof r==`number`?r:_f[r]},o=e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive(`whileInView`,t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),a=t?n:r;a&&a(e)};this.stopObserver=gf(this.node.current,a,o)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>`u`)return;let{props:e,prevProps:t}=this.node;[`amount`,`margin`,`root`].some(yf(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function yf({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}var bf=Object.assign({},Object.assign({renderer:Kd},Yd,{inView:{Feature:vf},tap:{Feature:uf},focus:{Feature:cf},hover:{Feature:sf}}),af,{layout:{ProjectionNode:sl,MeasureLayout:rf}});function xf(e){let t=Mn(()=>Pn(e)),{isStatic:n}=(0,G.useContext)(Vn);if(n){let[,n]=(0,G.useState)(e);(0,G.useEffect)(()=>t.on(`change`,n),[])}return t}function Sf(e,t){let n=xf(t()),r=()=>n.set(t());return r(),Rn(()=>{let t=()=>V.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return r(),()=>{n.forEach(e=>e()),bn(r)}}),n}function Cf(e){Ln.current=[],e();let t=Sf(Ln.current,e);return Ln.current=void 0,t}function wf(e,t,n,r){if(typeof e==`function`)return Cf(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return Ef(e,t,n,r);let i=typeof t==`function`?t:ku(t,n,r),a=Array.isArray(e)?Tf(e,i):Tf([e],([e])=>i(e)),o=Array.isArray(e)?void 0:e.accelerate;if(o&&!o.isTransformed&&typeof t!=`function`&&Array.isArray(n)&&r?.clamp!==!1&&!r?.mixer){let e=r?.ease;a.accelerate={...o,times:[0,...t,1],keyframes:[n[0],...n,n[n.length-1]],isTransformed:!0,...e?{ease:Array.isArray(e)?[e[0],...e]:e}:{}}}return a}function Tf(e,t){let n=Mn(()=>[]);return Sf(e,()=>{n.length=0;let r=e.length;for(let t=0;t<r;t++)n[t]=e[t].get();return t(n)})}function Ef(e,t,n,r){let i=Mn(()=>Object.keys(n)),a=Mn(()=>({}));for(let o of i)a[o]=wf(e,t,n[o],r);return a}function Df(){!va.current&&Aa();let[e]=(0,G.useState)(ea.current);return e}var Of=(0,G.createContext)(null),kf=(0,G.createContext)(null);function Af(e,t,n,r,i,a=`ltr`){let o=e.findIndex(e=>e.value===t);if(o===-1)return e;if(i===`xy`){let{layout:t}=e[o],r={x:Mf(t.x)+n.x,y:Mf(t.y)+n.y},i=Nf(e),s=i.find(t=>t.items.includes(e[o])),c=i.reduce((e,t)=>Pf(r.y,t)<Pf(r.y,e)?t:e);if(c!==s)return Ff(e,o,r.x,c,a);let l=If(r,t),u=-1,d=l;return e.forEach((e,t)=>{if(t===o)return;let n=If(r,e.layout);n<d&&(u=t,d=n)}),u===-1?e:ln(e,o,o+Math.sign(u-o))}if(!r[i])return e;let s=r[i]>0?1:-1,c=e[o+s];if(!c)return e;let l=e[o].layout[i],u=c.layout[i],d=Mf(u);return s===1&&l.max+n[i]>d||s===-1&&l.min+n[i]<d?ln(e,o,o+s):e}function jf(e,t,n,r,i){let a=n>1==!!(n%2&&i)?-1:1,o=n>3?(n-4)*(e.length-1):t+a;if(r===`xy`&&n<4&&!(n%2)&&t>-1){let n=Nf(e).sort((e,t)=>e.min-t.min),r=n[n.findIndex(({items:n})=>n.includes(e[t]))+a],i=n=>Math.abs(Mf(n.layout.x)-Mf(e[t].layout.x));o=r?e.indexOf(r.items.reduce((e,t)=>i(t)<i(e)?t:e)):-1}return t>-1&&o!==t&&e[o]?o:-1}var Mf=({min:e,max:t})=>M(e,t,.5);function Nf(e){let t=[];return e.forEach(e=>{let{min:n,max:r}=e.layout.y,i=t[t.length-1];!i||n>=i.max||r<=i.min?t.push({items:[e],min:n,max:r}):(i.items.push(e),i.min=Math.min(i.min,n),i.max=Math.max(i.max,r))}),t}function Pf(e,t){return e<t.min?t.min-e:e>t.max?e-t.max:0}function Ff(e,t,n,r,i){let a=e.filter((e,n)=>n!==t),o=r.items.find(e=>{let t=Mf(e.layout.x);return i===`ltr`?n<t:n>t}),s=o?a.indexOf(o):a.indexOf(r.items[r.items.length-1])+1,c=[...a];return c.splice(s,0,e[t]),c.every((t,n)=>t===e[n])?e:c}function If(e,t){let n=Math.max(t.x.min-e.x,0,e.x-t.x.max),r=Math.max(t.y.min-e.y,0,e.y-t.y.max);return n*n+r*r}var Lf=(e,t)=>e.max<=t.min||t.max<=e.min;function Rf(e){let t=!1,n=!1;for(let r=0;r<e.length;r++)for(let i=r+1;i<e.length;i++)if(t||=Lf(e[r].x,e[i].x),n||=Lf(e[r].y,e[i].y),t&&n)return`xy`;return t?`x`:`y`}var zf=(e,t)=>n=>{e.current=n;let r=typeof t==`function`?t(n):t&&(t.current=n);if(typeof r==`function`)return()=>{e.current=null,r()}};function Bf({children:e,as:t=`ul`,axis:n,onReorder:r,values:i,onPointerDownCapture:a,onClickCapture:o,...s},c,l){let u=Mn(()=>l[t]),d=(0,G.useContext)(Of),f=(0,G.useRef)(new Map),p=(0,G.useRef)(new Map),[m,h]=(0,G.useState)(),[g,_]=(0,G.useState)(`y`),v=(0,G.useRef)(!1),y=(0,G.useRef)(!1),b=(0,G.useRef)(null),x=n||g,S=new Set(i);for(let e of[f.current,p.current])e.forEach((t,n)=>S.has(n)||e.delete(n));let C=S.has(m)?m:i[0],w=e=>p.current.get(e)?.current?.isConnected,T=e=>S.has(e)&&h(e),E=()=>{w(C)||T(i.find(w))};(0,G.useEffect)(E);let D=()=>i.flatMap(e=>f.current.get(e)||[]),O=()=>b.current?.ownerDocument.defaultView?.getComputedStyle(b.current).direction===`rtl`,k=(e,t)=>{let n=0,a=i.map(t=>f.current.has(t)?e[n++].value:t);a.some((e,t)=>e!==i[t])&&r(a,t)},ee={axis:x,proxy:l,groupRef:b,hasReordered:y,values:i,onReorder:r,getOrder:D,isTabStop:e=>e===C||!S.has(e),setActive:T,checkTabStop:E,elements:p.current,onKeyDown:(e,t,n,r)=>{let{key:a,currentTarget:o}=e;if(e.defaultPrevented||e.target!==o||e.altKey||e.ctrlKey||e.metaKey)return;let s=D(),c=[`ArrowUp`,`ArrowLeft`,`ArrowDown`,`ArrowRight`,`Home`,`End`].indexOf(a),l=c%2;if(a===` `)e.repeat||r(o,n?void 0:i);else if(c<0&&!(a===`Escape`&&n))return;else if(!d?.isMoving(o)){if(a===`Escape`&&n){if(r(o),!d?.restore(ee,t,o,n)){let e=n.flatMap(e=>s.filter(t=>t.value===e));k(s.map(t=>n.includes(t.value)?e.shift():t),t)}}else{let e=c>3||x===`xy`||x===(l?`x`:`y`),r=n?s:s.filter(({value:e})=>w(e)),i=r.findIndex(({value:e})=>e===t),a=e?jf(r,i,c,x,!!l&&O()):-1;if(a>-1)n?k(ln(s,i,a),t):p.current.get(r[a].value)?.current?.focus();else if(!(n&&c<4&&d?.key(ee,t,c,o,n))&&!e)return}}e.preventDefault()},registerItem:(e,t,r)=>{if(f.current.set(e,{value:e,layout:t,ref:r}),!n){let e=Rf(D().map(e=>e.layout));e!==g&&_(e)}},updateOrder:(e,t,n)=>{if(v.current)return;let r=D(),i=Af(r,e,t,n,x,O()?`rtl`:`ltr`);r!==i&&(v.current=!0,y.current=!0,k(i,e))}};(0,G.useEffect)(()=>{v.current=!1},[i]),Rn(()=>d?.add(ee));let A={overflowAnchor:`none`,...s.style};return(0,W.jsx)(u,{...s,style:A,ref:zf(b,c),onPointerDownCapture:e=>{y.current=!1,a?.(e)},onClickCapture:e=>{y.current&&e.detail&&(y.current=!1,e.stopPropagation(),e.preventDefault()),o?.(e)},ignoreStrict:!0,children:(0,W.jsx)(kf.Provider,{value:ee,children:e})})}var Vf=e=>(0,G.forwardRef)((t,n)=>Bf(t,n,e)),Hf=50,Uf=1.5,Wf=new Set([`auto`,`scroll`]),Gf={x:new Map,y:new Map};function Kf(){Gf.x.clear(),Gf.y.clear()}function qf(e,t){let n=getComputedStyle(e),r=t===`x`?n.overflowX:n.overflowY;return e===document.body||e===document.documentElement||Wf.has(r)&&(t===`x`?e.scrollWidth>e.clientWidth:e.scrollHeight>e.clientHeight)}function Jf(e,t){let n=e?.parentElement;for(;n;){if(qf(n,t))return n;n=n.parentElement}return null}function Yf(e){let t=Math.min(1,1-e/Hf);return Uf*t*t*Dn.delta}function Xf(e,t,n){let r=t.getBoundingClientRect(),i=n===`x`?Math.max(0,r.left):Math.max(0,r.top),a=n===`x`?Math.min(window.innerWidth,r.right):Math.min(window.innerHeight,r.bottom),o=e-i,s=a-e;return o<Hf?{amount:-Yf(o),edge:`start`}:s<Hf?{amount:Yf(s),edge:`end`}:{amount:0,edge:null}}function Zf(e,t,n,r){if(!e)return;let i=Jf(e,n);if(!i)return;let{amount:a,edge:o}=Xf(t-(n===`x`?window.scrollX:window.scrollY),i,n),s=Gf[n];if(o===null){s.delete(i);return}let c=s.get(i),l=i===document.body||i===document.documentElement;if(c?.edge!==o){if(!(o===`start`&&r<0||o===`end`&&r>0))return;c={edge:o,limit:n===`x`?i.scrollWidth-(l?window.innerWidth:i.clientWidth):i.scrollHeight-(l?window.innerHeight:i.clientHeight)},s.set(i,c)}a>0&&(n===`x`?l?window.scrollX:i.scrollLeft:l?window.scrollY:i.scrollTop)>=c.limit||(n===`x`?l?window.scrollBy({left:a}):i.scrollLeft+=a:l?window.scrollBy({top:a}):i.scrollTop+=a)}function Qf(e,t=0){return En(e)?e:xf(t)}function $f({children:e,style:t={},value:n,as:r=`li`,onDragStart:i,onDrag:a,onDragEnd:o,onKeyDown:s,onFocus:c,onBlur:l,layout:u=!0,...d},f){let p=(0,G.useContext)(kf),m=(0,G.useContext)(Of),h=(0,G.useRef)(null),g=Mn(()=>p.proxy[r]),_=(0,G.useRef)(),v={x:Qf(t.x),y:Qf(t.y)},y=wf([v.x,v.y],([e,t])=>e||t?1:`unset`),{axis:b,registerItem:x,updateOrder:S,groupRef:C,hasReordered:w,isTabStop:T,setActive:E,checkTabStop:D,elements:O,onKeyDown:k}=p,ee=b===`xy`||m?!0:b;O.set(n,h),(0,G.useEffect)(()=>D);let A=(e,t)=>{_.current=t,t||m?.end(n),In.get(e)?.animationState?.setActive(`whileDrag`,!!t)},te=(0,G.useRef)(!1);return Rn(()=>{m?.receive(p,n,h.current,A)&&(te.current=!0)},[]),(0,W.jsx)(g,{drag:ee,tabIndex:T(n)?0:-1,...d,dragSnapToOrigin:!0,style:{...t,x:v.x,y:v.y,zIndex:y},layout:u,onDragStart:(e,t)=>{te.current?te.current=!1:i?.(e,t)},onDrag:(e,t)=>{let{velocity:r,point:i}=t,o={x:v.x.get(),y:v.y.get()};m?.drag(p,n,h.current,e)||S(n,o,r);let s=m?[`x`,`y`]:[b===`xy`?Math.abs(r.x)>Math.abs(r.y)?`x`:`y`:b];for(let e of s)Zf(m&&!b.includes(e)?m.column(p):C.current,i[e],e,r[e]);a&&a(e,t)},onDragEnd:(e,t)=>{w.current=!1,Kf(),m?.end(n),o&&o(e,t)},onKeyDown:e=>{s?.(e),k(e,n,_.current,A)},onFocus:e=>{c?.(e),E(n)},onBlur:e=>{l?.(e),_.current&&A(e.currentTarget)},onLayoutMeasure:e=>{x(n,e,h)},ref:zf(h,f),ignoreStrict:!0,children:e})}var ep=(0,G.forwardRef)($f),tp=e=>{let{left:t,top:n,width:r,height:i}=e.getBoundingClientRect();return{x:t+r/2,y:n+i/2}},np=e=>{let{x:t,y:n}=tp(e),{scrollX:r,scrollY:i}=e.ownerDocument.defaultView;return{x:t+r,y:n+i}};function rp(e,t,n,r){let{left:i,right:a,top:o,bottom:s}=t.getBoundingClientRect(),c=r?e.x>(i+a)/2:e.x<=(i+a)/2,l=e.y<=(o+s)/2;return n===`x`?c:n===`y`?l:e.y<o||e.y<s&&c}var ip=(e,t)=>{let n=e.groupRef.current,r=t.groupRef.current;return n.contains(r)||r.contains(n)};function ap(e){let t=new Set,n,r=(t,n,r)=>!ip(t,n)&&e.current.canMove?.(r,t.values,n.values)!==!1,i,a=(e,t,r,i,a,o)=>{let s=tp(i),{values:c}=t;if(o===void 0){let e=t.getOrder().filter(e=>e.ref?.current?.isConnected),n=getComputedStyle(t.groupRef.current).direction===`rtl`,r=e.find(e=>rp(s,e.ref.current,t.axis,n)),i=e[e.length-1];o=r?c.indexOf(r.value):i?c.indexOf(i.value)+1:c.length}n={value:r,to:t.groupRef,element:i,centre:np(i),...a},t.hasReordered.current=!0,e.onReorder(e.values.filter(e=>e!==r),r),t.onReorder([...c.slice(0,o),r,...c.slice(o)],r)};return{add:e=>(t.add(e),()=>t.delete(e)),drag:(e,i,o,s)=>{if(!o?.isConnected)return!1;if(n?.controls?.isDragging)return n.value===i&&(n.centre=np(o),n.event=s),!0;let c=tp(o),l;for(let e of o.ownerDocument.elementsFromPoint(c.x,c.y))if(!o.contains(e)){for(let n of t)n.groupRef.current===e&&(l=n);if(l)break}if(!l||!r(e,l,i))return!1;let u=In.get(o);return a(e,l,i,o,{controls:u&&ou.get(u),event:s}),!0},key:(e,n,o,s,c)=>{let l=tp(s),u=o%2?`x`:`y`,d=o>1?1:-1,f,p=1/0;for(let i of t){let t=i.groupRef.current;if(!t)continue;let{left:a,right:s,top:c,bottom:m,width:h,height:g}=t.getBoundingClientRect();if(!h&&!g||([m,s,c,a][o]-l[u])*d<=0)continue;let _=Math.max(a-l.x,0,l.x-s),v=Math.max(c-l.y,0,l.y-m);_*_+v*v<p&&r(e,i,n)&&(p=_*_+v*v,f=i)}return f?(i?.from!==c&&(i={group:e.groupRef,from:c}),a(e,f,n,s,{keys:!0,from:c}),!0):!1},restore:(e,n,r,o)=>{let s=i?.from===o&&[...t].find(e=>e.groupRef===i.group);if(!s||s.groupRef===e.groupRef)return!1;let c=o.slice(o.indexOf(n)+1),l=s.values.findIndex(e=>c.includes(e));return i=void 0,a(e,s,n,r,{keys:!0},l<0?s.values.length:l),!0},end:e=>{n?.value===e&&(n=void 0)},isMoving:e=>n?.element===e,receive:(e,t,r,i)=>{let a=In.get(r),o=a&&ou.get(a);o?.isDragging&&a.animationState?.setActive(`whileDrag`,!0);let s=n;if(!s||s.value!==t||s.to!==e.groupRef)return!1;let{keys:c,from:l,controls:u}=s,d=!s.element.isConnected;if(c){n=void 0;let{activeElement:e,body:t}=r.ownerDocument;return d&&(!e||e===t)&&(r.focus(),i(r,l)),!1}return!o||!u?.isDragging?!1:(zn.read(()=>{if(n!==s)return;n=void 0,In.get(s.element)?.values.forEach((e,t)=>{let n=e.get();a.getValue(t,a.readValue(t,n))?.set(n)});let e=a.getTransformPagePoint()||(e=>e),t=e(s.centre),i=e(np(r));a.getValue(`x`).set(t.x-i.x),a.getValue(`y`).set(t.y-i.y),a.render(),d?u.cancel():u.stop(),o.start(s.event,{immediate:!0})}),d)},column:({groupRef:e})=>{let n=e.current,r=n=>[...t].some(t=>t.groupRef!==e&&n.contains(t.groupRef.current));for(;n?.parentElement?.parentElement&&!r(n.parentElement);)n=n.parentElement;return n}}}function op({children:e,...t}){let n=(0,G.useRef)(t);return Rn(()=>{n.current=t}),(0,W.jsx)(Of.Provider,{value:Mn(()=>ap(n)),children:e})}var sp=(e,t,n)=>{let[r,i]=(0,G.useState)(!1),a=typeof t==`object`&&t.tooltipWhenOverflow;return(0,G.useEffect)(()=>{if(!a)return;let n=()=>{let n=e.current;if(!n)return;let r=typeof t==`object`?t.rows:void 0;i(r&&r>1?n.scrollHeight>n.clientHeight:n.scrollWidth>n.clientWidth)};n();let r=new ResizeObserver(n);return e.current&&r.observe(e.current),()=>r.disconnect()},[a,t,n,e]),r},cp=Lt({block:`text`,dataAttributes:[`type`],elements:[]}),lp={code:{kMv6JI:`lb2xbw48`,$$css:!0},danger:{kMwMTN:`lb12ap7uz`,$$css:!0},delete:{kybGjl:`lbmqliwb`,$$css:!0},disabled:{kMwMTN:`lbv7q1j6`,kkrTdU:`lb1h6gzvc`,$$css:!0},ellipsis:{kVQacm:`lbb3r6kr`,kg5iWk:`lblyipyv`,khDVqt:`lbuxw1ft`,$$css:!0},ellipsisMulti:{kVQacm:`lbb3r6kr`,kgKLqz:`lb1ua5tub`,k1xSpc:`lb104kibb`,kg5iWk:`lblyipyv`,$$css:!0},h1:{kGuDYH:`lb1xiv2dn`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h2:{kGuDYH:`lb2ziyne`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h3:{kGuDYH:`lbowuowh`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h4:{kGuDYH:`lbkf6u7v`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},h5:{kGuDYH:`lb1pzwcx8`,k63SB2:`lb117nqv4`,kLWn49:`lb132q4wb`,$$css:!0},info:{kMwMTN:`lbapv1it`,$$css:!0},italic:{kKX8nH:`lb1k4tb9n`,$$css:!0},mark:{kWkggS:`lb10l2l1g`,kMwMTN:`lbod0wng`,$$css:!0},p:{kqGvvJ:`lb10im51j`,$$css:!0},secondary:{kMwMTN:`lb19ppog9`,$$css:!0},shiny:{"--shiny-color":`lb1yqjya6`,"--shiny-duration":`lb13qpc1j`,k44tkh:`lbpzn028`,ko0y90:`lba4qsjk`,kKVMdj:`lbj1bqtc`,kyAemX:`lb1esw782`,kHypHr:`lb1ta4xzc`,kKwaWg:`lb1k0woq6`,kgSjnq:`lbakli9p`,kMwMTN:`lb1g83pbf`,kfSwDN:`lb87ps6o`,$$css:!0},strong:{k63SB2:`lb117nqv4`,$$css:!0},success:{kMwMTN:`lbs9y9h1`,$$css:!0},text:{kMwMTN:`lb66ogz0`,$$css:!0},underline:{kybGjl:`lb1bvjpef`,$$css:!0},warning:{kMwMTN:`lbgyvj36`,$$css:!0}};({className:`lb2xbw48`}).className,{className:`lb12ap7uz`}.className,{className:`lbmqliwb`}.className,{className:`lbv7q1j6 lb1h6gzvc`}.className,{className:`lbb3r6kr lblyipyv lbuxw1ft`}.className,{className:`lbb3r6kr lb1ua5tub lb104kibb lblyipyv`}.className,{className:`lb1xiv2dn lb117nqv4 lb132q4wb`}.className,{className:`lb2ziyne lb117nqv4 lb132q4wb`}.className,{className:`lbowuowh lb117nqv4 lb132q4wb`}.className,{className:`lbkf6u7v lb117nqv4 lb132q4wb`}.className,{className:`lb1pzwcx8 lb117nqv4 lb132q4wb`}.className,{className:`lbapv1it`}.className,{className:`lb1k4tb9n`}.className,{className:`lb10l2l1g lbod0wng`}.className,{className:`lb10im51j`}.className,{className:`lb19ppog9`}.className,{className:`lb117nqv4`}.className,{className:`lbs9y9h1`}.className,{className:`lb66ogz0`}.className,{className:`lb1bvjpef`}.className,{className:`lbgyvj36`}.className,B((e=>z(e).className)(lp.shiny),`lobe-text-shiny`);var up=(e={})=>[lp.text,e.as&&lp[e.as],e.code&&lp.code,e.delete&&lp.delete,e.disabled&&lp.disabled,e.ellipsis===`multi`&&lp.ellipsisMulti,e.ellipsis===!0&&lp.ellipsis,e.italic&&lp.italic,e.mark&&lp.mark,e.shiny&&lp.shiny,e.strong&&lp.strong,e.type&&lp[e.type],e.underline&&lp.underline],dp=(0,G.memo)(({align:e,as:t=`div`,children:n,className:r,classNames:i,code:a,color:o,delete:s,disabled:c,ellipsis:l,fontSize:u,italic:d,lineClamp:f,lineHeight:p,mark:m,noWrap:h,ref:g,shiny:_,shinyDuration:v,strong:y,style:b,styles:x,textDecoration:S,textTransform:C,type:w,underline:T,weight:E,whiteSpace:D,wordBreak:O,...k})=>{let ee=(0,G.useRef)(null),A=sp(ee,l,n),te=typeof l==`object`&&!!l.rows&&l.rows>1,j=typeof l==`object`&&l.tooltipWhenOverflow,ne=e=>{ee.current=e,typeof g==`function`?g(e):g&&(g.current=e)},M={...o&&{color:o},...E&&{fontWeight:E},...p&&{lineHeight:p},...C&&{textTransform:C},...S&&{textDecoration:S},...O&&{wordBreak:O},...typeof l==`object`&&l.rows&&{WebkitLineClamp:l.rows},...!l&&!!f&&{WebkitBoxOrient:`vertical`,WebkitLineClamp:f,display:`-webkit-box`,overflow:`hidden`,textOverflow:`ellipsis`},..._&&v&&{"--shiny-duration":v},...u&&{fontSize:u},...e&&{textAlign:e},...!te&&h&&{whiteSpace:`nowrap`},...D&&{whiteSpace:D},...b,...x?.root},N=(0,W.jsx)(t,{...It({type:w}),...k,ref:ne,style:M,className:z(up({as:[`h1`,`h2`,`h3`,`h4`,`h5`,`p`].includes(t)?t:void 0,code:a,delete:s,disabled:c,ellipsis:l?typeof l==`object`&&l.rows?`multi`:!0:void 0,italic:d,mark:m,shiny:_,strong:y,type:w,underline:T}),B(cp(),_&&`lobe-text-shiny`,r,i?.root)).className,children:n});if(l&&typeof l==`object`&&(l.tooltip||l.tooltipWhenOverflow)){if(j&&!A)return N;let e=typeof l.tooltip==`string`?l.tooltip:n;return l.tooltip&&typeof l.tooltip==`object`?(0,W.jsx)(Oo,{...l.tooltip,title:l.tooltip?.title||e,children:N}):(0,W.jsx)(Oo,{title:e,children:N})}return N});dp.displayName=`Text`;var fp=dp,pp=e=>{e.stopPropagation()},mp=e=>{e.preventDefault(),e.stopPropagation(),e.preventBaseUIHandler?.()},hp=G.createContext({disabled:!1});function gp(){return G.useContext(hp)}function _p(e){let[t,n]=G.useState({getBoundingClientRect(){return DOMRect.fromRect({width:0,height:0,x:0,y:0})}}),r=G.useRef(null),i=G.useRef(null),a=G.useRef(null),o=G.useRef(null),s=G.useRef(!0),c=G.useRef(null),l=yt(),u=G.useMemo(()=>({anchor:t,setAnchor:n,actionsRef:a,backdropRef:r,internalBackdropRef:i,positionerRef:o,allowMouseUpTriggerRef:s,initialCursorPointRef:c,rootId:l}),[t,l]);return(0,W.jsx)(Ho.Provider,{value:u,children:(0,W.jsx)(ko.Provider,{value:void 0,children:(0,W.jsx)(Ao,{...e})})})}var vp=zo,Y=Lt({block:`context-menu`,elements:[`trigger`,`positioner`,`header`,`viewport`,`footer`,`item`,`item-content`,`icon`,`label-group`,`label`,`desc`,`extra`,`submenu-arrow`,`checkbox-indicator`,`switch`,`separator`,`group`,`group-label`]}),yp=(0,G.memo)(({collisionPadding:e,style:t,...n})=>{let r=typeof t!=`function`&&t?.zIndex!=null&&typeof t.zIndex==`number`?t.zIndex:void 0,{zIndex:i,ref:a}=Pt(`floating`,r),o=typeof t==`function`?e=>({zIndex:i,...t(e)}):{zIndex:i,...t};return(0,W.jsx)(vp,{...n,className:B(L.positioner,Y(`positioner`)),collisionPadding:e??C(),ref:a,style:o})});yp.displayName=`ContextMenuSubmenuPositioner`;var bp=(0,G.memo)(()=>{let{t:e}=Jt(re);return(0,W.jsx)(Vo,{disabled:!0,className:B(R(I.item,I.empty).className,Y(`item`)),children:(0,W.jsx)(`div`,{className:B(L.itemContent,Y(`item-content`)),children:(0,W.jsx)(`span`,{className:B(L.label,Y(`label`)),children:e(`common.empty`)})})})});bp.displayName=`EmptyMenuItem`;var xp=({checked:e,children:t,closeOnClick:n=!1,danger:r,defaultChecked:i,disabled:a,label:o,onCheckedChange:s})=>{let[c,l]=(0,G.useState)(i??!1),u=e!==void 0,d=u?e:c,f=(0,G.useCallback)(e=>{u||l(e),s?.(e)},[u,s]);return(0,W.jsxs)(Vo,{closeOnClick:n,disabled:a,label:o,className:B(R(I.item,r&&I.danger).className,Y(`item`)),onClick:e=>{e.preventDefault(),a||f(!d)},children:[t,(0,W.jsx)(`span`,{className:B(L.switchWrap,Y(`switch`)),onFocus:e=>e.stopPropagation(),children:(0,W.jsx)(Ge,{checked:d,disabled:a,size:`small`,tabIndex:-1,onChange:f,onClick:(e,t)=>t.stopPropagation()})})]})},Sp=(e,t,n)=>{let r=Bt(e),i=`desc`in e?e.desc:void 0,a=`extra`in e?e.extra:void 0,o=t?.indicatorOnRight,s=!!i&&t?.iconAlign===`start`,c=n!==void 0&&!o,l=c?!!n:!!e.icon,u=c?!!(t?.reserveIconSpace||n):!!(l||t?.reserveIconSpace),d=i?(0,W.jsxs)(`div`,{className:B(L.labelGroup,Y(`label-group`)),children:[(0,W.jsx)(`span`,{className:B(L.label,Y(`label`)),children:r}),(0,W.jsx)(`span`,{className:B(L.desc,Y(`desc`)),children:i})]}):(0,W.jsx)(`span`,{className:B(L.label,Y(`label`)),children:r});return(0,W.jsxs)(`div`,{className:B(R(I.itemContent,s&&I.itemContentAlignStart).className,Y(`item-content`)),children:[u?(0,W.jsx)(`span`,{"aria-hidden":!l,className:B(R(I.icon,s&&I.iconAlignStart).className,Ye.icon,Y(`icon`)),children:c?n:l?Gt(e.icon,`small`):null}):null,d,a?(0,W.jsx)(`span`,{className:B(L.extra,Y(`extra`)),children:a}):null,o&&n?n:null,t?.submenu?(0,W.jsx)(`span`,{className:B(L.submenuArrow,Y(`submenu-arrow`)),children:(0,W.jsx)(Ht,{})}):null]})},Cp=(e,t,n)=>{if(!e.onClick)return;let r=e.key??t.at(-1)??``,i={domEvent:n,item:n.currentTarget,key:String(r),keyPath:t};e.onClick(i)},wp=(e,t=[],n)=>{let r=n?.iconAlign,i=n?.iconSpaceMode??`global`,a=n?.reserveIconSpace??zt(e,i===`global`),o=n?.indicatorOnRight??Ut(e);return e.map((e,n)=>{if(!e)return null;let s=`${t.join(`-`)||`root`}-${n}`,c=Wt(e,s),l=[...t,String(c)];if(e.type===`checkbox`){let t=e,n=Bt(t),i=typeof n==`string`?n:void 0,s=!!t.danger,l=(0,W.jsx)(Lo,{className:Y(`checkbox-indicator`),children:(0,W.jsx)(Ct,{icon:A,size:`small`})});return(0,W.jsx)(Po,{checked:t.checked,closeOnClick:t.closeOnClick,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,className:B(R(I.item,s&&I.danger).className,Y(`item`)),onCheckedChange:e=>t.onCheckedChange?.(e),children:Sp(t,{iconAlign:r,indicatorOnRight:o,reserveIconSpace:a},l)},c)}if(e.type===`switch`){let t=e,n=Bt(t),i=typeof n==`string`?n:void 0,o=!!t.danger;return(0,W.jsx)(xp,{checked:t.checked,closeOnClick:t.closeOnClick,danger:o,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,onCheckedChange:t.onCheckedChange,children:Sp(t,{iconAlign:r,reserveIconSpace:a})},c)}if(e.type===`divider`)return(0,W.jsx)(Ro,{className:B(L.separator,Y(`separator`))},c);if(e.type===`group`){let t=e,n=i===`group`?t.children?zt(t.children):!1:a,o=t.children?Ut(t.children):!1;return(0,W.jsxs)(No,{className:Y(`group`),children:[t.label?(0,W.jsx)(Mo,{className:B(L.groupLabel,Y(`group-label`)),children:t.label}):null,t.children?wp(t.children,l,{iconAlign:r,iconSpaceMode:i,indicatorOnRight:o,reserveIconSpace:n}):null]},c)}if(e.type===`submenu`||`children`in e&&e.children){let t=e,n=Bt(t),o=typeof n==`string`?n:void 0,s=`danger`in t&&!!t.danger,u=t.header!=null||t.footer!=null,d=t.children&&t.children.length>0?wp(t.children,l,{iconAlign:r,iconSpaceMode:i}):(0,W.jsx)(bp,{});return(0,W.jsxs)(Fo,{defaultOpen:t.defaultOpen,open:t.open,onOpenChange:t.onOpenChange,children:[(0,W.jsx)(Bo,{...t.triggerProps,closeDelay:t.closeDelay,delay:t.delay,disabled:t.disabled,label:o,openOnHover:t.openOnHover,className:B(R(I.item,s&&I.danger).className,Y(`item`)),onClick:t.onClick,children:Sp(t,{iconAlign:r,reserveIconSpace:a,submenu:!0})}),(0,W.jsx)(jo,{children:(0,W.jsx)(yp,{alignOffset:-4,"data-submenu":``,sideOffset:-1,onContextMenu:mp,children:(0,W.jsxs)(Io,{className:B(R(I.popup,u&&I.popupWithSlots).className,Ye.popup,Y()),children:[t.header==null?null:(0,W.jsx)(`div`,{className:B(L.header,Y(`header`)),children:t.header}),u?(0,W.jsx)(`div`,{className:B(L.slotViewport,Y(`viewport`)),children:d}):d,t.footer==null?null:(0,W.jsx)(`div`,{className:B(L.footer,Y(`footer`)),children:t.footer})]})})})]},c)}let u=e,d=Bt(u),f=typeof d==`string`?d:void 0,p=`danger`in u&&!!u.danger;return(0,W.jsx)(Vo,{closeOnClick:u.closeOnClick,disabled:u.disabled,label:f,className:B(R(I.item,p&&I.danger).className,Y(`item`)),onClick:e=>Cp(u,l,e),children:Sp(u,{iconAlign:r,reserveIconSpace:a})},c)})},Tp={"--lobe-dropdown-animation-duration":`0ms`},Ep=(0,G.memo)(()=>{let e=Le(),t=At(),n=(0,G.useSyncExternalStore)(en,tn,$t);(0,G.useEffect)(()=>{},[e]),(0,G.useEffect)(()=>{let e=e=>nn(e);return window.addEventListener(`pointerdown`,e,!0),window.addEventListener(`contextmenu`,e,!0),()=>{window.removeEventListener(`pointerdown`,e,!0),window.removeEventListener(`contextmenu`,e,!0)}},[]);let r=(0,G.useMemo)(()=>wp(n.items,[],{iconAlign:n.iconAlign,iconSpaceMode:n.iconSpaceMode}),[n.items,n.iconAlign,n.iconSpaceMode]),{zIndex:i,ref:a}=Pt(`floating`),o=n.header!=null||n.footer!=null;return!e||!n.open&&n.items.length===0?null:(0,W.jsx)(_p,{open:n.open,onOpenChange:e=>{e?Qt({open:e}):rn()},children:(0,W.jsx)(jo,{container:t,children:(0,W.jsx)(vp,{anchor:n.anchor??void 0,className:B(L.positioner,Y(`positioner`)),collisionPadding:C(),ref:a,sideOffset:6,style:{...Tp,zIndex:i},children:(0,W.jsxs)(Io,{"data-has-footer":n.footer==null?void 0:``,"data-has-header":n.header==null?void 0:``,className:B(R(I.popup,o&&I.popupWithSlots).className,Ye.popup,Y()),onContextMenu:mp,children:[n.header==null?null:(0,W.jsx)(`div`,{className:B(L.header,Y(`header`)),children:n.header}),n.virtual?(0,W.jsx)(Vt,{className:Y(`viewport`),itemSize:n.listItemHeight,children:r}):o?(0,W.jsx)(`div`,{className:B(L.slotViewport,Y(`viewport`)),children:r}):r,n.footer==null?null:(0,W.jsx)(`div`,{className:B(L.footer,Y(`footer`)),children:n.footer})]})})})})});Ep.displayName=`ContextMenuHost`;var Dp={circle:{kaIpWk:`lb16rqkct`,$$css:!0},defaultSize:{kZKoxP:`lblup9mm`,kzqmXN:`lb1kky2od`,$$css:!0},defaultSquare:{kaIpWk:`lb12oqio5`,$$css:!0},group:{kOIVth:`lb1v2ro7d`,k1xSpc:`lb78zum5`,kXwgrk:`lb1q0g3np`,kwnvtZ:`lb1a02dak`,$$css:!0},groupVertical:{kXwgrk:`lbdt5ytf`,$$css:!0},iconCircle:{k3aq6I:`lb10078c2`,$$css:!0},iconSquare:{k3aq6I:`lb1nrvvgt`,$$css:!0},indicator:{kGNEyG:`lb6s0dn4`,k1xSpc:`lb78zum5`,kjj79g:`lbl56j7k`,$$css:!0},label:{kOIVth:`lb167g77z`,kGNEyG:`lb6s0dn4`,kkrTdU:`lb1ypdohk lb1r4mgf1`,k1xSpc:`lb3nfvp2`,kfSwDN:`lb87ps6o`,$$css:!0},root:{kogj98:`lb1ghz6dp`,kmVPX3:`lb1717udv`,kVAM5u:`lb1ri2ox9 lb10cypdb lb18hgaxl lb14dg99k`,ksu8eU:`lb1y0btm7`,kMzoRj:`lbmkeg23`,kUk6DE:`lb1okw0bk`,kI3sdo:`lb1a2a7pz`,kmkexE:`lb1mlet35`,kGNEyG:`lb6s0dn4`,kWkggS:`lbpbwnwz lb6yijhg lb1ppu4m2`,kMwMTN:`lb15g0kca lbcdmxi5`,kkrTdU:`lb1ypdohk lb5ezrf1`,k1xSpc:`lb3nfvp2`,kjj79g:`lbl56j7k`,kSiTet:`lb12zwbr1`,$$css:!0}};({className:`lb16rqkct`}).className,{className:`lblup9mm lb1kky2od`}.className,{className:`lb12oqio5`}.className,{className:`lb1v2ro7d lb78zum5 lb1q0g3np lb1a02dak`}.className,{className:`lbdt5ytf`}.className,{className:`lb10078c2`}.className,{className:`lb1nrvvgt`}.className,{className:`lb6s0dn4 lb78zum5 lbl56j7k`}.className,{className:`lb167g77z lb6s0dn4 lb1ypdohk lb1r4mgf1 lb3nfvp2 lb87ps6o`}.className,{className:`lb1ghz6dp lb1717udv lb1ri2ox9 lb10cypdb lb18hgaxl lb14dg99k lb1y0btm7 lbmkeg23 lb1okw0bk lb1a2a7pz lb1mlet35 lb6s0dn4 lbpbwnwz lb6yijhg lb1ppu4m2 lb15g0kca lbcdmxi5 lb1ypdohk lb5ezrf1 lb3nfvp2 lbl56j7k lb12zwbr1`}.className;function Op(e){if(!e)return null;for(let t of e.elements){let e=t.tagName;if(e===`BUTTON`||e===`INPUT`){let e=t;if(e.type===`submit`)return e}}return null}var kp=`data-checked`,Ap=`data-unchecked`;function jp(e){return{checked(t){return e.indeterminate?{}:t?{[kp]:``}:{[Ap]:``}},...Fe}}var Mp=G.createContext(void 0);function Np(){return G.useContext(Mp)}var Pp=G.createContext(void 0);function Fp(){let e=G.useContext(Pp);if(e===void 0)throw Error(Et(14));return e}var Ip=`data-parent`,Lp=G.forwardRef(function(e,t){let{checked:n,className:r,defaultChecked:i=!1,"aria-labelledby":a,disabled:o=!1,form:s,id:c,indeterminate:l=!1,inputRef:u,name:d,onCheckedChange:f,parent:p=!1,readOnly:m=!1,render:h,required:g=!1,uncheckedValue:_,value:v,nativeButton:y=!1,style:b,...x}=e,{clearErrors:S}=ye(),{disabled:C,name:w,setDirty:T,setFilled:E,setTouched:D,state:O,validationMode:k,validityData:ee,validation:A}=Ze(),te=gp(),{labelId:j,registerControlId:ne,getDescriptionProps:M}=xe(),N=Np(),re=N?.allValues===void 0?void 0:N.parent,ae=re!==void 0,P=C||te.disabled||N?.disabled||o,oe=w??d,F=v??oe,se=Tt(),ce=N?.registerControlId!==ne,le=ie({id:c||void 0,enabled:ce}),de=y?le:se,fe={};ae&&(p?fe=re.getParentProps():F!==void 0&&(fe=re.getChildProps(F)));let{checked:pe=n,indeterminate:me=l,onCheckedChange:he,...ge}=fe,_e=N?.value,ve=G.useRef(null),be=ue(P,ve),{getButtonProps:Ce,buttonRef:we}=St({disabled:P,native:y}),I=N?.validation??A,[Te,Ee]=Be({controlled:F!==void 0&&_e!==void 0&&!p?_e.includes(F):pe,default:i,name:`Checkbox`,state:`checked`}),De=ae?!!pe:Te,Oe=ae&&me||l;Se(ve,se,Te,void 0,!N&&!P,d);let ke=re?.registerChildId,Ae=G.useRef(null),je=I.registerInput,Me=N?F:void 0,Ne=G.useCallback(e=>je(e,{controlRef:ve,value:Me}),[je,Me]),Pe=Dt(u,Ae,p?void 0:Ne),Fe=Je(a,j,Ae,!y,le,x[`aria-label`]);Ot(()=>{Ae.current&&(Ae.current.indeterminate=Oe),N||E(Te)},[Te,Oe,N,E]),at(Te,()=>{N||(S(oe),T(Te!==ee.initialValue),I.change(Te))});let L=xt({checked:Te,disabled:P,form:s,name:p?void 0:oe,id:y?void 0:le,required:g,ref:Pe,style:oe?bt:_t,tabIndex:-1,type:`checkbox`,"aria-hidden":!0,onChange(e){if(e.nativeEvent.defaultPrevented)return;if(m){e.preventDefault();return}let t=e.currentTarget.checked,n=Ft(kt,e.nativeEvent);if(f?.(t,n),!n.isCanceled&&(he?.(t,n),!n.isCanceled&&(Ee(t),F!==void 0&&N!==void 0&&!p&&!ae))){let e=t?[...N.value,F]:N.value.filter(e=>e!==F);N.setValue(e,n)}},onClick(e){e.stopPropagation()},onFocus(){ve.current?.focus()}},v===void 0?ft:{value:(N?Te&&v:v)||``},M,e=>I.getValidationProps(P,e));G.useEffect(()=>{if(!re||F===void 0)return;let e=re.disabledStatesRef.current;return e.set(F,P),()=>{e.delete(F)}},[re,P,F]);let Ie=G.useMemo(()=>({...O,checked:De,disabled:P,readOnly:m,required:g,indeterminate:Oe}),[O,De,P,m,g,Oe]),Le=jp(Ie),Re=vt(`span`,e,{state:Ie,ref:[we,ve,t],props:[{id:de,role:`checkbox`,"aria-checked":Oe?`mixed`:De,"aria-readonly":m||void 0,"aria-required":g||void 0,"aria-labelledby":Fe,[Ip]:p?``:void 0,onFocus(){be(!0)},onBlur(){let e=Ae.current;e&&(D(!0),be(!1),k===`onBlur`&&I.commit(N?_e:e.checked))},onKeyDown(e){if(e.key!==`Enter`||(e.preventBaseUIHandler(),e.defaultPrevented))return;let t=Ae.current?.form??null,n=e.currentTarget,r=e.nativeEvent,i=e.preventDefault,a=r.preventDefault,o=!1;e.preventDefault=()=>{o=!0,i.call(e)},r.preventDefault=()=>{o=!0,a.call(r)},a.call(r),Mt(n).queueMicrotask(()=>{e.preventDefault=i,r.preventDefault=a,o||Op(t)?.click()})},onClick(e){if(m||P)return;e.preventDefault();let t=Ae.current;t&&gt(t,e)}},x,ge,Ce,M,e=>I.getValidationProps(P,e)],stateAttributesMapping:Le}),ze=Re.props.id;return Ot(()=>{if(ke&&!p&&F!==void 0&&ze!==void 0)return ke(F,ze)},[ke,p,F,ze]),(0,W.jsxs)(Pp.Provider,{value:Ie,children:[Re,!Te&&!N&&oe&&!p&&_!==void 0&&(0,W.jsx)(`input`,{type:`hidden`,form:s,name:oe,value:_,disabled:P}),(0,W.jsx)(`input`,{...L,suppressHydrationWarning:!0})]})}),Rp=G.forwardRef(function(e,t){let{render:n,className:r,style:i,keepMounted:a=!1,...o}=e,s=Fp(),c=s.checked||s.indeterminate,{mounted:l,transitionStatus:u,setMounted:d}=jt(c),f=G.useRef(null),p={...s,transitionStatus:u};mt({batch:!0,enabled:!c,open:c,ref:f,onComplete(){c||d(!1)}});let m={...jp(s),...Nt},h=a||l,g=vt(`span`,e,{ref:[t,f],state:p,stateAttributesMapping:m,props:o});return h?g:null}),zp=Lt({block:`checkbox`,dataAttributes:[`shape`],elements:[`checkbox`,`indicator`,`text`]});Lt({block:`checkbox-group`,dataAttributes:[`horizontal`],elements:[`item`]});var Bp=(0,G.memo)(({size:e,shape:t=`square`,backgroundColor:n,children:r,className:i,classNames:a,styles:o,style:s,textProps:c,onChange:l,disabled:u,indeterminate:d,...f})=>{let p=e??16,m=e!==void 0,h={...m&&{height:p,width:p},...m&&t===`square`&&{borderRadius:`max(4px, ${Math.round(p/4)}px)`},...n?{"--lobe-checkbox-bg":n}:{},...r?{}:s,...o?.checkbox},g=t===`square`?Dp.iconSquare:Dp.iconCircle,_=(0,W.jsx)(Lp,{disabled:u,indeterminate:d,onCheckedChange:l,...r?void 0:It({shape:t}),...f,...z([Dp.root,wt.info,!m&&Dp.defaultSize,t===`square`?!m&&Dp.defaultSquare:Dp.circle],B(!r&&zp(),zp(`checkbox`),r?a?.checkbox:i,a?.checkbox),h),children:(0,W.jsx)(Rp,{...z(Dp.indicator,zp(`indicator`)),children:d?(0,W.jsx)(Ke,{size:p,strokeWidth:3,...R(g)}):(0,W.jsx)(A,{size:p,strokeWidth:3,...R(g)})})});return r?(0,W.jsxs)(`label`,{...It({shape:t}),...z(Dp.label,B(zp(),i,a?.wrapper),{...m&&{gap:Math.floor(p/2)},...s,...o?.wrapper}),children:[_,(0,W.jsx)(fp,{as:`span`,className:B(zp(`text`),a?.text),style:o?.text,...c,type:u?`secondary`:c?.type,children:r})]}):_});Bp.displayName=`Checkbox`;var Vp=Object.assign(Bp,{formBinding:{valueProp:`checked`}}),X={glyph:{k1xSpc:`lb3nfvp2`,$$css:!0},glyphBox:{k1xSpc:`lb3nfvp2`,$$css:!0},network:{k1xSpc:`lb1rg5ohu`,kVAEAm:`lb1n2onr6`,$$css:!0},networkBox:{k87sOh:`lb13vifvy`,kLqNvP:`lb1o0tod`,kVAEAm:`lb10l6tqk`,k3nNDw:`lb1hj3fc7`,kZKoxP:`lbpyat2d`,kzqmXN:`lb1exxlbk`,$$css:!0},networkCore:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1ygz6qe lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kWkggS:`lb1h45990`,k87sOh:`lbyszfof`,kLqNvP:`lb4500kp`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbols6we`,kzqmXN:`lb1v4s8kt`,$$css:!0},networkLine:{kjVXCG:`lb68wf4t`,kfJifR:`lbpmuf5a`,kSiTet:`lbuzhngd`,$$css:!0},networkLines:{kpwlN0:`lb10a8y8t`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbpyat2d`,kzqmXN:`lb1exxlbk`,$$css:!0},networkNode:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1mw1q8i lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kogj98:`lbzvvh78`,kaIpWk:`lb16rqkct`,kWkggS:`lb1h45990`,kVAEAm:`lb10l6tqk`,kZKoxP:`lbxdy7cf`,kzqmXN:`lb165gwbr`,$$css:!0},networkParticle:{k44tkh:`lb1c74tu6 lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb15d5rfv lb1aquc0h`,kyAemX:`lb1debuo4 lb1uea3p4`,kogj98:`lb1rmkima`,kaIpWk:`lb16rqkct`,kWkggS:`lb1h45990`,k87sOh:`lbbssg55`,kLqNvP:`lbemjqv4`,kVAEAm:`lb10l6tqk`,kZKoxP:`lb11vverv`,kzqmXN:`lbsblaa2`,$$css:!0},networkRing:{k44tkh:`lb6q96wx lb1u6grsq`,ko0y90:`lba4qsjk lbg0664w`,kKVMdj:`lb1v0ides lb1aquc0h`,kyAemX:`lb1esw782 lb1uea3p4`,kpwlN0:`lb1vdmwfg`,kVAM5u:`lb181nr7w`,kaIpWk:`lb16rqkct`,ksu8eU:`lbbsl7fq`,kMzoRj:`lbmkeg23`,kSiTet:`lbti2d7y`,kVAEAm:`lb10l6tqk`,$$css:!0},overlay:{kpwlN0:`lb10a8y8t`,kOIVth:`lb167g77z`,kGNEyG:`lb6s0dn4`,kWkggS:`lb1c0b5dz`,kMwMTN:`lbc77et8`,k1xSpc:`lb78zum5`,kXwgrk:`lbdt5ytf`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,$$css:!0},ring:{k4XH5M:`lbwsa1kb`,$$css:!0},ringProgress:{kjVXCG:`lb1q6ff6i`,$$css:!0},ringTrack:{kjVXCG:`lb12pnydc`,$$css:!0},root:{kGNEyG:`lb6s0dn4`,kMwMTN:`lbc77et8`,k1xSpc:`lb3nfvp2`,$$css:!0},tip:{kMwMTN:`lbc77et8`,kGuDYH:`lbxobqjj`,$$css:!0},wrapper:{kVAEAm:`lb1n2onr6`,$$css:!0}},Hp=[0,1,2],Up=25,Wp=Hp.flatMap(e=>Hp.map(t=>({x:Up+e*Up,y:Up+t*Up}))),Gp=Hp.slice(0,-1).flatMap(e=>Hp.flatMap(t=>Hp.map(n=>({x1:Up+e*Up,x2:Up+(e+1)*Up,y1:Up+t*Up,y2:Up+n*Up})))),Kp=[0,1,2],qp=(e,t,n)=>Math.max(e,n*100/t),Jp=(0,G.memo)(({px:e})=>{let t={"--spin-node-size":`${qp(6,e,2)}px`,"--spin-particle-size":`${qp(3,e,1.5)}px`,transform:`scale(${e/100})`};return(0,W.jsx)(`span`,{...R(X.network),style:{height:e,width:e},children:(0,W.jsxs)(`span`,{...R(X.networkBox),style:t,children:[(0,W.jsx)(`svg`,{...R(X.networkLines),viewBox:`0 0 100 100`,children:Gp.map(e=>(0,W.jsx)(`line`,{...e,...R(X.networkLine)},`${e.x1}-${e.y1}-${e.y2}`))}),Wp.map(({x:e,y:t},n)=>(0,W.jsx)(`i`,{...R(X.networkNode),style:{animationDelay:`${n*.2}s`,left:e,top:t}},`${e}-${t}`)),Kp.map(e=>(0,W.jsx)(`i`,{...R(X.networkParticle),style:{animationDelay:`${e*.6}s`}},e)),(0,W.jsx)(`b`,{...R(X.networkCore)}),(0,W.jsx)(`u`,{...R(X.networkRing)})]})})});Jp.displayName=`NetworkGlyph`;var Yp=Lt({block:`spin`,dataAttributes:[`size`,`variant`],elements:[`indicator`,`overlay`,`tip`]}),Xp={large:32,middle:20,small:14},Zp=e=>typeof e==`number`?e:Xp[e],Qp=(0,G.memo)(({children:e,className:t,indicator:n,percent:r,ref:i,size:a=`middle`,spinning:o=!0,style:s,tip:c,variant:l=`default`,...u})=>{let d=(0,G.useMemo)(()=>Zp(a),[a]),f=(0,G.useMemo)(()=>{if(n)return n;if(l===`network`)return(0,W.jsx)(Jp,{px:d});if(typeof r==`number`){let e=Math.min(100,Math.max(0,r)),t=2*Math.PI*9,n=t*(1-e/100);return(0,W.jsxs)(`svg`,{...R(X.glyph,X.ring),height:d,viewBox:`0 0 24 24`,width:d,children:[(0,W.jsx)(`circle`,{...R(X.ringTrack),cx:12,cy:12,fill:`none`,r:9,strokeWidth:2.5}),(0,W.jsx)(`circle`,{...R(X.ringProgress),cx:12,cy:12,fill:`none`,r:9,strokeDasharray:t,strokeDashoffset:n,strokeLinecap:`round`,strokeWidth:2.5})]})}return(0,W.jsx)(Ct,{spin:!0,...R(X.glyph),icon:Ue,size:d})},[n,l,r,d]);if(!o)return e??null;let p=It({size:typeof a==`string`?a:void 0,variant:l});return e?(0,W.jsxs)(`div`,{ref:i,...z(X.wrapper,B(Yp(),t),s),...p,...u,children:[e,(0,W.jsxs)(`div`,{"aria-busy":!0,"aria-live":`polite`,...z(X.overlay,Yp(`overlay`)),role:`status`,children:[(0,W.jsx)(`span`,{"aria-hidden":!0,...z(X.glyphBox,Yp(`indicator`)),children:f}),c&&(0,W.jsx)(`span`,{...z(X.tip,Yp(`tip`)),children:c})]})]}):(0,W.jsx)(`div`,{"aria-busy":!0,"aria-live":`polite`,ref:i,role:`status`,...z(X.root,B(Yp(),t),s),...p,...u,children:(0,W.jsx)(`span`,{"aria-hidden":!0,...z(X.glyphBox,Yp(`indicator`)),children:f})})});Qp.displayName=`Spin`;var $p=(e=>(e[e.Border=-1]=`Border`,e[e.Data=0]=`Data`,e[e.Function=1]=`Function`,e[e.Position=2]=`Position`,e[e.Timing=3]=`Timing`,e[e.Alignment=4]=`Alignment`,e))($p||{}),em=[0,1],tm=[1,0],nm=[2,3],rm=[3,2],im={L:em,M:tm,Q:nm,H:rm},am=/^\d*$/,om=/^[A-Z0-9 $%*+./:-]*$/,sm=`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:`,cm=1,lm=40,um=3,dm=3,fm=40,pm=10,mm=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],hm=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],gm=class{constructor(e,t,n,r){if(this.version=e,this.ecc=t,e<cm||e>lm)throw RangeError(`Version value out of range`);if(r<-1||r>7)throw RangeError(`Mask value out of range`);this.size=e*4+17;let i=Array.from({length:this.size}).fill(!1);for(let e=0;e<this.size;e++)this.modules.push(i.slice()),this.types.push(i.map(()=>0));this.drawFunctionPatterns();let a=this.addEccAndInterleave(n);if(this.drawCodewords(a),r===-1){let e=1e9;for(let t=0;t<8;t++){this.applyMask(t),this.drawFormatBits(t);let n=this.getPenaltyScore();n<e&&(r=t,e=n),this.applyMask(t)}}this.mask=r,this.applyMask(r),this.drawFormatBits(r)}size;mask;modules=[];types=[];getModule(e,t){return e>=0&&e<this.size&&t>=0&&t<this.size&&this.modules[t][e]}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0,$p.Timing),this.setFunctionModule(e,6,e%2==0,$p.Timing);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);let e=this.getAlignmentPatternPositions(),t=e.length;for(let n=0;n<t;n++)for(let r=0;r<t;r++)n===0&&r===0||n===0&&r===t-1||n===t-1&&r===0||this.drawAlignmentPattern(e[n],e[r]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(e){let t=this.ecc[1]<<3|e,n=t;for(let e=0;e<10;e++)n=n<<1^(n>>>9)*1335;let r=(t<<10|n)^21522;for(let e=0;e<=5;e++)this.setFunctionModule(8,e,vm(r,e));this.setFunctionModule(8,7,vm(r,6)),this.setFunctionModule(8,8,vm(r,7)),this.setFunctionModule(7,8,vm(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,vm(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,vm(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,vm(r,e));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let e=this.version;for(let t=0;t<12;t++)e=e<<1^(e>>>11)*7973;let t=this.version<<12|e;for(let e=0;e<18;e++){let n=vm(t,e),r=this.size-11+e%3,i=Math.floor(e/3);this.setFunctionModule(r,i,n),this.setFunctionModule(i,r,n)}}drawFinderPattern(e,t){for(let n=-4;n<=4;n++)for(let r=-4;r<=4;r++){let i=Math.max(Math.abs(r),Math.abs(n)),a=e+r,o=t+n;a>=0&&a<this.size&&o>=0&&o<this.size&&this.setFunctionModule(a,o,i!==2&&i!==4,$p.Position)}}drawAlignmentPattern(e,t){for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)this.setFunctionModule(e+r,t+n,Math.max(Math.abs(r),Math.abs(n))!==1,$p.Alignment)}setFunctionModule(e,t,n,r=$p.Function){this.modules[t][e]=n,this.types[t][e]=r}addEccAndInterleave(e){let t=this.version,n=this.ecc;if(e.length!==Nm(t,n))throw RangeError(`Invalid argument`);let r=hm[n[0]][t],i=mm[n[0]][t],a=Math.floor(Mm(t)/8),o=r-a%r,s=Math.floor(a/r),c=[],l=Pm(i);for(let t=0,n=0;t<r;t++){let r=e.slice(n,n+s-i+(t<o?0:1));n+=r.length;let a=Fm(r,l);t<o&&r.push(0),c.push(r.concat(a))}let u=[];for(let e=0;e<c[0].length;e++)c.forEach((t,n)=>{(e!==s-i||n>=o)&&u.push(t[e])});return u}drawCodewords(e){if(e.length!==Math.floor(Mm(this.version)/8))throw RangeError(`Invalid argument`);let t=0;for(let n=this.size-1;n>=1;n-=2){n===6&&(n=5);for(let r=0;r<this.size;r++)for(let i=0;i<2;i++){let a=n-i,o=n+1&2?r:this.size-1-r;!this.types[o][a]&&t<e.length*8&&(this.modules[o][a]=vm(e[t>>>3],7-(t&7)),t++)}}}applyMask(e){if(e<0||e>7)throw RangeError(`Mask value out of range`);for(let t=0;t<this.size;t++)for(let n=0;n<this.size;n++){let r;switch(e){case 0:r=(n+t)%2==0;break;case 1:r=t%2==0;break;case 2:r=n%3==0;break;case 3:r=(n+t)%3==0;break;case 4:r=(Math.floor(n/3)+Math.floor(t/2))%2==0;break;case 5:r=n*t%2+n*t%3==0;break;case 6:r=(n*t%2+n*t%3)%2==0;break;case 7:r=((n+t)%2+n*t%3)%2==0;break;default:throw Error(`Unreachable`)}!this.types[t][n]&&r&&(this.modules[t][n]=!this.modules[t][n])}}getPenaltyScore(){let e=0;for(let t=0;t<this.size;t++){let n=!1,r=0,i=[0,0,0,0,0,0,0];for(let a=0;a<this.size;a++)this.modules[t][a]===n?(r++,r===5?e+=um:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*fm),n=this.modules[t][a],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*fm}for(let t=0;t<this.size;t++){let n=!1,r=0,i=[0,0,0,0,0,0,0];for(let a=0;a<this.size;a++)this.modules[a][t]===n?(r++,r===5?e+=um:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*fm),n=this.modules[a][t],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*fm}for(let t=0;t<this.size-1;t++)for(let n=0;n<this.size-1;n++){let r=this.modules[t][n];r===this.modules[t][n+1]&&r===this.modules[t+1][n]&&r===this.modules[t+1][n+1]&&(e+=dm)}let t=0;for(let e of this.modules)t=e.reduce((e,t)=>e+ +!!t,t);let n=this.size*this.size,r=Math.ceil(Math.abs(t*20-n*10)/n)-1;return e+=r*pm,e}getAlignmentPatternPositions(){if(this.version===1)return[];{let e=Math.floor(this.version/7)+2,t=this.version===32?26:Math.ceil((this.version*4+4)/(e*2-2))*2,n=[6];for(let r=this.size-7;n.length<e;r-=t)n.splice(1,0,r);return n}}finderPenaltyCountPatterns(e){let t=e[1],n=t>0&&e[2]===t&&e[3]===t*3&&e[4]===t&&e[5]===t;return(n&&e[0]>=t*4&&e[6]>=t?1:0)+(n&&e[6]>=t*4&&e[0]>=t?1:0)}finderPenaltyTerminateAndCount(e,t,n){return e&&(this.finderPenaltyAddHistory(t,n),t=0),t+=this.size,this.finderPenaltyAddHistory(t,n),this.finderPenaltyCountPatterns(n)}finderPenaltyAddHistory(e,t){t[0]===0&&(e+=this.size),t.pop(),t.unshift(e)}};function _m(e,t,n){if(t<0||t>31||e>>>t)throw RangeError(`Value out of range`);for(let r=t-1;r>=0;r--)n.push(e>>>r&1)}function vm(e,t){return!!(e>>>t&1)}var ym=class{constructor(e,t,n){if(this.mode=e,this.numChars=t,this.bitData=n,t<0)throw RangeError(`Invalid argument`);this.bitData=n.slice()}getData(){return this.bitData.slice()}},bm=[1,10,12,14],xm=[2,9,11,13],Sm=[4,8,16,16];function Cm(e,t){return e[Math.floor((t+7)/17)+1]}function wm(e){let t=[];for(let n of e)_m(n,8,t);return new ym(Sm,e.length,t)}function Tm(e){if(!Om(e))throw RangeError(`String contains non-numeric characters`);let t=[];for(let n=0;n<e.length;){let r=Math.min(e.length-n,3);_m(Number.parseInt(e.substring(n,n+r),10),r*3+1,t),n+=r}return new ym(bm,e.length,t)}function Em(e){if(!km(e))throw RangeError(`String contains unencodable characters in alphanumeric mode`);let t=[],n=0;for(;n+2<=e.length;n+=2){let r=sm.indexOf(e.charAt(n))*45;r+=sm.indexOf(e.charAt(n+1)),_m(r,11,t)}return n<e.length&&_m(sm.indexOf(e.charAt(n)),6,t),new ym(xm,e.length,t)}function Dm(e){return e===``?[]:Om(e)?[Tm(e)]:km(e)?[Em(e)]:[wm(jm(e))]}function Om(e){return am.test(e)}function km(e){return om.test(e)}function Am(e,t){let n=0;for(let r of e){let e=Cm(r.mode,t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}function jm(e){e=encodeURI(e);let t=[];for(let n=0;n<e.length;n++)e.charAt(n)===`%`?(t.push(Number.parseInt(e.substring(n+1,n+3),16)),n+=2):t.push(e.charCodeAt(n));return t}function Mm(e){if(e<cm||e>lm)throw RangeError(`Version number out of range`);let t=(16*e+128)*e+64;if(e>=2){let n=Math.floor(e/7)+2;t-=(25*n-10)*n-55,e>=7&&(t-=36)}return t}function Nm(e,t){return Math.floor(Mm(e)/8)-mm[t[0]][e]*hm[t[0]][e]}function Pm(e){if(e<1||e>255)throw RangeError(`Degree out of range`);let t=[];for(let n=0;n<e-1;n++)t.push(0);t.push(1);let n=1;for(let r=0;r<e;r++){for(let e=0;e<t.length;e++)t[e]=Im(t[e],n),e+1<t.length&&(t[e]^=t[e+1]);n=Im(n,2)}return t}function Fm(e,t){let n=t.map(e=>0);for(let r of e){let e=r^n.shift();n.push(0),t.forEach((t,r)=>n[r]^=Im(t,e))}return n}function Im(e,t){if(e>>>8||t>>>8)throw RangeError(`Byte out of range`);let n=0;for(let r=7;r>=0;r--)n=n<<1^(n>>>7)*285,n^=(t>>>r&1)*e;return n}function Lm(e,t,n=1,r=40,i=-1,a=!0){if(!(cm<=n&&n<=r&&r<=lm)||i<-1||i>7)throw RangeError(`Invalid value`);let o,s;for(o=n;;o++){let n=Nm(o,t)*8,i=Am(e,o);if(i<=n){s=i;break}if(o>=r)throw RangeError(`Data too long`)}for(let e of[tm,nm,rm])a&&s<=Nm(o,e)*8&&(t=e);let c=[];for(let t of e){_m(t.mode[0],4,c),_m(t.numChars,Cm(t.mode,o),c);for(let e of t.getData())c.push(e)}let l=Nm(o,t)*8;_m(0,Math.min(4,l-c.length),c),_m(0,(8-c.length%8)%8,c);for(let e=236;c.length<l;e^=253)_m(e,8,c);let u=Array.from({length:Math.ceil(c.length/8)},()=>0);return c.forEach((e,t)=>u[t>>>3]|=e<<7-(t&7)),new gm(o,t,u,i)}function Rm(e,t){let{ecc:n=`L`,boostEcc:r=!1,minVersion:i=1,maxVersion:a=40,maskPattern:o=-1,border:s=1}=t||{},c=typeof e==`string`?Dm(e):Array.isArray(e)?[wm(e)]:void 0;if(!c)throw Error(`uqr only supports encoding string and binary data, but got: ${typeof e}`);let l=Lm(c,im[n],i,a,o,r),u=zm({version:l.version,maskPattern:l.mask,size:l.size,data:l.modules,types:l.types},s);return t?.invert&&(u.data=u.data.map(e=>e.map(e=>!e))),t?.onEncoded?.(u),u}function zm(e,t=1){if(!t)return e;let{size:n}=e,r=n+t*2;e.size=r,e.data.forEach(e=>{for(let n=0;n<t;n++)e.unshift(!1),e.push(!1)});for(let n=0;n<t;n++)e.data.unshift(Array.from({length:r},e=>!1)),e.data.push(Array.from({length:r},e=>!1));let i=$p.Border;e.types.forEach(e=>{for(let n=0;n<t;n++)e.unshift(i),e.push(i)});for(let n=0;n<t;n++)e.types.unshift(Array.from({length:r},e=>i)),e.types.push(Array.from({length:r},e=>i));return e}var Bm={"qrCode.expired":`Expired`,"qrCode.loading":`Loading`,"qrCode.refresh":`Refresh`},Vm=(e,t)=>{let n=e.length,r=Math.floor((n-t)/2),i=r+t,a=``;for(let o=0;o<n;o++)for(let s=0;s<n;s++)t>0&&s>=r&&s<i&&o>=r&&o<i||e[o][s]&&(a+=`M${s} ${o}h1v1h-1z`);return a},Hm=Lt({block:`qr-code`,dataAttributes:[`status`,`bordered`],elements:[`code`,`icon`,`overlay`,`title`,`refresh`]}),Um={bordered:{kGVxlE:`lbnug1en`,$$css:!0},icon:{kaIpWk:`lb16rqkct`,kVQacm:`lbb3r6kr`,kGNEyG:`lb6s0dn4`,kGVxlE:`lbgffery`,k1xSpc:`lb78zum5`,k87sOh:`lbwa60dl`,kLqNvP:`lbbudbmw`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,k3aq6I:`lb11lhmoz`,$$css:!0},iconDefaultSize:{kZKoxP:`lb1iafx81`,kzqmXN:`lb1tzk97j`,$$css:!0},overlay:{kpwlN0:`lb10a8y8t`,kaIpWk:`lbgqmno8`,kOIVth:`lb1v2ro7d`,kGNEyG:`lb6s0dn4`,kWkggS:`lbsuhtdx`,kMwMTN:`lb1a94cpc`,k1xSpc:`lb78zum5`,kXwgrk:`lbdt5ytf`,kjj79g:`lbl56j7k`,kVAEAm:`lb10l6tqk`,$$css:!0},overlayTitle:{kGuDYH:`lb19d36u7`,k63SB2:`lb1s688f`,$$css:!0},refresh:{kaIpWk:`lb1e6avla`,ksu8eU:`lbng3xce`,kMzoRj:`lbc342km`,kjAs5C:`lb1aazh3f`,kOIVth:`lb17d4w8g`,kg3NbH:`lbqin4a2`,kGNEyG:`lb6s0dn4`,kWkggS:`lb1qtvmyh`,kMwMTN:`lbfungia`,kkrTdU:`lb1ypdohk`,k1xSpc:`lb3nfvp2`,kMv6JI:`lbjb2p0i`,kGuDYH:`lb4z9k3i`,kQqvRs:`lb1xh6y1q`,kKX8nH:`lb1t35e8`,k63SB2:`lbk50ysn`,kjj79g:`lbl56j7k`,kLWn49:`lb15bjb6t`,kZKoxP:`lb10w6t97`,$$css:!0},root:{kmVPX3:`lb1tamke2`,kaIpWk:`lbgqmno8`,kWkggS:`lb83z2og`,k1xSpc:`lb3nfvp2`,kVAEAm:`lb1n2onr6`,$$css:!0},spin:{kMwMTN:`lb33gn0b`,$$css:!0}},Wm=.22,Gm=(0,G.memo)(({bgColor:e,bordered:t=!0,className:n,color:r=`#000`,errorLevel:i=`M`,icon:a,onRefresh:o,ref:s,size:c,status:l=`active`,style:u,value:d,...f})=>{let{t:p}=Jt(Bm),m=c??160,{count:h,path:g}=(0,G.useMemo)(()=>{try{let{data:e}=Rm(d,{border:0,ecc:a?`H`:i}),t=a?Math.ceil(e.length*Wm)|1:0;return{count:e.length,path:Vm(e,t)}}catch{return{count:0,path:``}}},[d,a,i]);return(0,W.jsxs)(`div`,{ref:s,...z([Um.root,t&&Um.bordered],B(Hm(),n),e===void 0?u:{background:e,...u}),...It({bordered:t,status:l}),...f,children:[(0,W.jsxs)(`svg`,{"aria-label":d,className:Hm(`code`),height:m,role:`img`,shapeRendering:`crispEdges`,viewBox:`0 0 ${h} ${h}`,width:m,children:[(0,W.jsx)(`rect`,{fill:e??`#fff`,height:h,width:h}),(0,W.jsx)(`path`,{d:g,fill:r})]}),a&&(0,W.jsx)(`span`,{...z([Um.icon,c===void 0&&Um.iconDefaultSize],Hm(`icon`),c===void 0?void 0:{height:m*Wm,width:m*Wm}),children:a}),l===`loading`&&(0,W.jsx)(`span`,{"aria-label":p(`qrCode.loading`),...z(Um.overlay,Hm(`overlay`)),role:`status`,children:(0,W.jsx)(Qp,{className:z(Um.spin).className})}),l===`expired`&&(0,W.jsxs)(`span`,{...z(Um.overlay,Hm(`overlay`)),children:[(0,W.jsx)(`span`,{...z(Um.overlayTitle,Hm(`title`)),children:p(`qrCode.expired`)}),o&&(0,W.jsxs)(`button`,{...z([wt.info,Um.refresh],Hm(`refresh`)),type:`button`,onClick:o,children:[(0,W.jsx)(Ct,{icon:is,size:14}),p(`qrCode.refresh`)]})]})]})});Gm.displayName=`QRCode`;var Km=e({Board:()=>op,Group:()=>qm,Item:()=>ep}),qm=Vf(Gd),Jm=e({Reorder:()=>Km,a:()=>Ua,abbr:()=>ba,address:()=>Fa,animate:()=>na,area:()=>Ei,article:()=>wa,aside:()=>za,audio:()=>Ni,b:()=>fa,base:()=>qa,bdi:()=>Li,bdo:()=>Wi,big:()=>Oa,blockquote:()=>ga,body:()=>Qi,button:()=>Ji,canvas:()=>Si,caption:()=>Za,circle:()=>lo,cite:()=>Ai,clipPath:()=>ao,code:()=>Xr,col:()=>tr,colgroup:()=>to,create:()=>La,data:()=>ei,datalist:()=>cr,dd:()=>ar,defs:()=>Rr,del:()=>la,desc:()=>Yn,details:()=>oa,dfn:()=>Mr,dialog:()=>Fr,div:()=>Vr,dl:()=>dr,dt:()=>br,ellipse:()=>kr,em:()=>qr,embed:()=>mo,feBlend:()=>Qn,feColorMatrix:()=>si,feComponentTransfer:()=>_r,feComposite:()=>ii,feConvolveMatrix:()=>ui,feDiffuseLighting:()=>mr,feDisplacementMap:()=>Er,feDistantLight:()=>Ma,feDropShadow:()=>Cr,feFlood:()=>gi,feFuncA:()=>pi,feFuncB:()=>yi,feFuncG:()=>Wr,feFuncR:()=>Kn,feGaussianBlur:()=>Ui,feImage:()=>Ka,feMerge:()=>Ca,feMergeNode:()=>Ra,feMorphology:()=>aa,feOffset:()=>ki,fePointLight:()=>Da,feSpecularLighting:()=>Ha,feSpotLight:()=>Ii,feTile:()=>ha,feTurbulence:()=>Xa,fieldset:()=>Bi,figcaption:()=>qi,figure:()=>ja,filter:()=>ya,footer:()=>ta,foreignObject:()=>Zi,form:()=>Ti,g:()=>eo,h1:()=>po,h2:()=>Mi,h3:()=>co,h4:()=>$r,h5:()=>ir,h6:()=>io,head:()=>ri,header:()=>ur,hgroup:()=>sr,hr:()=>Br,html:()=>da,i:()=>Zn,iframe:()=>ca,image:()=>Pr,img:()=>Lr,input:()=>Ur,ins:()=>pr,kbd:()=>Sr,keygen:()=>jr,label:()=>Yr,legend:()=>go,li:()=>er,line:()=>li,linearGradient:()=>yr,link:()=>oi,main:()=>fi,map:()=>gr,mark:()=>Or,marker:()=>Pa,mask:()=>Tr,menu:()=>vi,menuitem:()=>hi,metadata:()=>xi,meter:()=>Kr,nav:()=>Jn,object:()=>Vi,ol:()=>Wa,optgroup:()=>xa,option:()=>Ia,output:()=>ra,p:()=>Di,param:()=>Ta,path:()=>Ba,pattern:()=>Pi,picture:()=>pa,polygon:()=>Ja,polyline:()=>Ri,pre:()=>Gi,progress:()=>ka,q:()=>_a,radialGradient:()=>$i,rect:()=>Yi,rp:()=>Ci,rt:()=>Qa,ruby:()=>uo,s:()=>ji,samp:()=>oo,script:()=>Zr,section:()=>nr,select:()=>no,small:()=>ti,source:()=>lr,span:()=>or,stop:()=>zr,strong:()=>ua,style:()=>Xn,sub:()=>sa,summary:()=>Nr,sup:()=>Ir,svg:()=>Hr,symbol:()=>fr,table:()=>xr,tbody:()=>Ar,td:()=>Jr,text:()=>ho,textPath:()=>$n,textarea:()=>ci,tfoot:()=>vr,th:()=>ai,thead:()=>di,time:()=>hr,title:()=>Dr,tr:()=>Na,track:()=>wr,tspan:()=>_i,u:()=>mi,ul:()=>bi,use:()=>Gr,video:()=>qn,view:()=>Hi,wbr:()=>Ga,webview:()=>Sa}),Ym=i();function Xm(e,t){if(e instanceof RegExp)return{keys:!1,pattern:e};var n,r,i,a,o=[],s=``,c=e.split(`/`);for(c[0]||c.shift();i=c.shift();)n=i[0],n===`*`?(o.push(n),s+=i[1]===`?`?`(?:/(.*))?`:`/(.*)`):n===`:`?(r=i.indexOf(`?`,1),a=i.indexOf(`.`,1),o.push(i.substring(1,~r?r:~a?a:i.length)),s+=~r&&!~a?`(?:/([^/]+?))?`:`/([^/]+?)`,~a&&(s+=(~r?`?`:``)+`\\`+i.substring(a))):s+=`/`+i;return{keys:o,pattern:RegExp(`^`+s+(t?`(?=$|/)`:`/?$`),`i`)}}var Zm=pt(),Qm=G.useInsertionEffect,$m=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0?G.useLayoutEffect:G.useEffect,eh=Qm||$m,th=e=>{let t=G.useRef([e,(...e)=>t[0](...e)]).current;return eh(()=>{t[0]=e}),t[1]},nh=[`popstate`,`pushState`,`replaceState`,`hashchange`],rh=[],ih=()=>rh.forEach(e=>e()),ah=e=>(rh.push(e)===1&&nh.forEach(e=>addEventListener(e,ih)),()=>{rh=rh.filter(t=>t!==e),rh.length||nh.forEach(e=>removeEventListener(e,ih))}),oh=(e,t)=>(0,Zm.useSyncExternalStore)(ah,e,t),sh=()=>location.search,ch=({ssrSearch:e}={})=>oh(sh,e==null?sh:()=>e),lh=()=>location.pathname,uh=({ssrPath:e}={})=>oh(lh,e==null?lh:()=>e),dh=(e,{replace:t=!1,state:n=null}={})=>history[t?`replaceState`:`pushState`](n,``,e),fh=e=>[uh(e),dh],ph=Symbol.for(`wouter_v3`);if(typeof history<`u`&&window[ph]===void 0){for(let e of[`pushState`,`replaceState`]){let t=history[e];history[e]=function(){let n=t.apply(this,arguments),r=new Event(e);return r.arguments=arguments,dispatchEvent(r),n}}Object.defineProperty(window,ph,{value:!0})}var mh=(e=``)=>e===`/`?``:e,hh=(e,t)=>e[0]===`~`?e.slice(1):mh(t)+e,gh=(e,t)=>(e=_h(mh(e)),t=_h(t),!e||(t.toLowerCase()+`/`).startsWith(e.toLowerCase()+`/`)?t.slice(e.length)||`/`:`~`+t),_h=e=>{try{return e.includes(`%`)?decodeURI(e):e}catch{return e}},vh={hook:fh,searchHook:ch,parser:Xm,base:``,ssrPath:void 0,ssrSearch:void 0,ssrContext:void 0,hrefs:e=>e,aroundNav:(e,t,n)=>e(t,n)},yh=(0,G.createContext)(vh),bh=()=>(0,G.useContext)(yh);(0,G.createContext)({});var xh=e=>{let[t,n]=e.hook(e);return[gh(e.base,t),th((t,r)=>e.aroundNav(n,hh(t,e.base),r))]},Sh=()=>xh(bh());(0,G.forwardRef)((e,t)=>{let n=bh(),[r,i]=xh(n),{to:a=``,href:o=a,onClick:s,asChild:c,children:l,className:u,replace:d,state:f,transition:p,...m}=e;return m.onClick=th(t=>{t.ctrlKey||t.metaKey||t.altKey||t.shiftKey||t.button!==0||(s?.(t),t.defaultPrevented||(t.preventDefault(),i(o,e)))}),m.href=n.hrefs(o[0]===`~`?o.slice(1):n.base+o,n),u!==void 0&&(m.className=u?.call?u(r===o):u),t&&(m.ref=t),c&&(0,G.isValidElement)(l)?(0,G.cloneElement)(l,m):(0,G.createElement)(`a`,m,l)});var Ch=0,wh=0,Th=new Set;function Eh(){wh||Ch>0||Th.size===0||(wh=requestAnimationFrame(()=>{if(wh=0,Ch>0)return;let e=[...Th];Th.clear();for(let t of e)t()}))}function Dh(){return Ch+=1,()=>{--Ch,Eh()}}function Oh({label:e}){return(0,G.useEffect)(Dh,[]),(0,W.jsx)(f,{stack:!0,label:e,size:32})}var kh={claude:`Claude Code`,codex:`Codex`,antigravity:`Antigravity`};function Ah(e,t){return e.harness===`claude`?t.find(t=>t.host===`claude`&&t.id===e.sessionId)?.id??null:t.filter(t=>t.host===e.harness).sort((e,t)=>t.since-e.since)[0]?.id??null}var jh=e=>e.kind!==`none`&&e.kind!==`login`,Mh=e=>e.kind===`quiet`||e.kind===`command`&&e.stuck===!0,Nh=e=>e.kind===`menu`||e.kind===`login`||e.kind===`error`?`amber`:e.kind===`quiet`||e.kind===`command`&&e.stuck?`grey`:null,Ph=(e,t)=>Math.max(1,Math.floor((t-e)/6e4));function Fh(e,t,n,r){let i=Ph(e.since,t);switch(e.kind){case`menu`:return n(`daemon.waiting`);case`login`:return n(`daemon.login`);case`error`:return n(`daemon.error`);case`quiet`:return n(`daemon.quiet`,{minutes:i});case`command`:return e.stuck?n(`daemon.commandStuck`,{minutes:i}):n(`daemon.command`,{command:e.line??``,minutes:i});default:return r}}var Ih=new Set([`thinking`,`running`,`your-turn`,`needs-approval`]),Lh=new Set([`starting`,`queued`]),Rh=e=>e.daemon!==null&&Nh(e.daemon.attention)===`amber`;function zh(e){return(e.daemon?Nh(e.daemon.attention)??(Lh.has(e.daemon.state)?`grey`:null):null)??(e.state===`needs-approval`?`amber`:null)}var Bh={"needs-approval":1,running:2,thinking:3,"your-turn":5};function Vh(e){if(Rh(e))return 0;let t=zh(e);return e.state?t===`grey`&&e.state!==`needs-approval`?4:Bh[e.state]:t===`grey`?4:e.daemon?.state===`running`?2:5}function Hh(e,t){let n=e.filter(e=>Ih.has(e.state)),r=t&&t.state!==`ended`?t:null,i=r?Ah(r,n):null,a=n.map((e,t)=>({key:e.host&&e.id?`${e.host}:${e.id}`:`hook:${t}`,agent:e.agent,state:e.state,since:e.since,turn:e.turn??null,daemon:r&&i!==null&&e.id===i?r:null}));return r&&i===null&&a.push({key:`daemon:${r.taskId}`,agent:kh[r.harness]??r.harness,state:null,since:r.attention.since,turn:null,daemon:r}),a.sort((e,t)=>Vh(e)-Vh(t))}async function Uh(e){let t=await fetch(`/api/agent/daemon`,{method:`POST`,credentials:`same-origin`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),n=await t.json().catch(()=>null);if(!t.ok||!n?.ok)throw Error(n?.error??`HTTP ${t.status}`);return n.data}function Wh(e){return{screen:async()=>{let t=await Uh({artifact:e,op:`agent-screen`});return Array.isArray(t?.lines)?t.lines.filter(e=>typeof e==`string`):[]},input:async t=>{await Uh({artifact:e,op:`agent-input`,...t})}}}var Gh=e=>new URLSearchParams(e).get(`agent`)===`1`;function Kh(){let[e,t]=(0,G.useState)([]),[n,r]=(0,G.useState)([]);return(0,G.useEffect)(()=>{let e=null,n,i=!1,a=()=>{e=new WebSocket(So(location)),e.onmessage=e=>{let n=JSON.parse(String(e.data));n.type===`agent-status`&&(t(n.sessions),r(n.daemon??[]))},e.onclose=()=>{t([]),r([]),i||(n=setTimeout(a,1e3))}};return a(),()=>{i=!0,clearTimeout(n),e?.close()}},[]),{sessions:e,daemon:n}}var qh=(0,G.lazy)(()=>r(async()=>{let{AgentDock:e}=await import(`./AgentDock-CH6Ykvym.js`);return{AgentDock:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19]),import.meta.url).then(({AgentDock:e})=>({default:e})));function Jh({artifact:e}){let{sessions:t,daemon:n}=Kh(),r=n.find(t=>t.artifact===e)??null,i=(0,G.useMemo)(()=>Wh(e),[e]),a=Hh(t.filter(t=>t.artifacts.includes(e)),r);return a.length===0?null:(0,W.jsx)(G.Suspense,{fallback:null,children:(0,W.jsx)(qh,{trusted:!0,rows:a,transport:r?i:null})})}function Yh(e,t){let{band:n,front:r,echo:i}=t instanceof Element?{band:t,front:null,echo:null}:t,a=e.parentElement?.closest(`a, button`)??e,o=window.matchMedia(`(prefers-reduced-motion: reduce)`),s=[],c=()=>{if(o.matches||s.length>0)return;let{sweep:e,trace:t}=l,a=[];if(r){let e=typeof r.getTotalLength==`function`?r.getTotalLength():t.frontLength;r.style.strokeDasharray=`${e}`,a.push(r.animate([{strokeDashoffset:e},{strokeDashoffset:0}],{duration:t.frontDuration,easing:t.easing}))}if(i){let e=typeof i.getTotalLength==`function`?i.getTotalLength():t.echoLength;i.style.strokeDasharray=`${e}`,a.push(i.animate([{strokeDashoffset:e,opacity:.15},{strokeDashoffset:0,opacity:.38}],{duration:t.echoDuration,delay:t.echoDelay,easing:t.easing,fill:`backwards`}))}let c=n.animate([{transform:e.from},{transform:e.to}],{duration:e.duration,delay:r?e.delay:0,easing:e.easing});a.push(c),s=a;let u=a.length,d=()=>{--u,u<=0&&(s=[],r&&(r.style.strokeDasharray=``),i&&(i.style.strokeDasharray=``))};for(let e of a)e.onfinish=d,e.oncancel=d},u=()=>{a.matches(`:focus-visible`)&&c()};return a.addEventListener(`pointerenter`,c),a.addEventListener(`focus`,u),()=>{a.removeEventListener(`pointerenter`,c),a.removeEventListener(`focus`,u);for(let e of s)e.cancel();s=[]}}function Xh({ink:e,seal:t,forMask:n=!1,frontRef:r,echoRef:i}){return(0,W.jsxs)(W.Fragment,{children:[!n&&(0,W.jsxs)(`g`,{opacity:.14,pointerEvents:`none`,transform:l.markTransform,children:[(0,W.jsx)(`path`,{d:`M14.5 22L22.8 6.8C23.4 5.7 24.6 5.7 25.2 6.8L33.5 22`,fill:`none`,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:3.2}),(0,W.jsx)(`path`,{d:`M9.5 40.5L22.2 14.8C23 13.2 25 13.2 25.8 14.8L38.5 40.5`,fill:`none`,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:4.4})]}),(0,W.jsxs)(`g`,{transform:l.markTransform,children:[(0,W.jsx)(`path`,{d:m,fill:`none`,opacity:n?1:.38,ref:i,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:3.2}),(0,W.jsx)(`path`,{d:_,fill:`none`,ref:r,stroke:e,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:4.4}),(0,W.jsx)(`circle`,{cx:p.cx,cy:p.cy,r:p.r,stroke:`none`,...t})]}),(0,W.jsxs)(`g`,{transform:l.wordTransform,children:[(0,W.jsx)(`path`,{d:l.path,fill:e,fillRule:`nonzero`}),(0,W.jsx)(`circle`,{cx:l.seal.cx,cy:l.seal.cy,r:l.seal.r,stroke:`none`,...t})]})]})}function Zh({height:e=22,title:t,contextMenu:n=!0}){let{t:r}=x(),i=d((0,G.useId)()),a=(0,G.useRef)(null),o=(0,G.useRef)(null),s=(0,G.useRef)(null),c=(0,G.useRef)(null);(0,G.useEffect)(()=>Yh(a.current,{band:o.current,front:s.current,echo:c.current}),[]);let u=async(e,t)=>{try{await navigator.clipboard.writeText(b(e)),an.success(r(t))}catch{an.error(r(`brand.copyFailed`))}},f=e=>{n&&(e.preventDefault(),e.stopPropagation(),Zt([{key:`copy-svg`,label:r(`brand.copySvg`),icon:Co,onClick:()=>void u(`lockup`,`brand.copiedSvg`)},{key:`copy-logo-svg`,label:r(`brand.copyLogoSvg`),icon:nt,onClick:()=>void u(`mark`,`brand.copiedLogoSvg`)},{key:`copy-text-svg`,label:r(`brand.copyTextSvg`),icon:$e,onClick:()=>void u(`wordmark`,`brand.copiedTextSvg`)}]))},p=`${i}-mask`,m=`${i}-ember`;return(0,W.jsxs)(`svg`,{fill:`none`,ref:a,...t?{role:`img`,"aria-label":t}:{"aria-hidden":!0},height:e,viewBox:l.viewBox,width:Math.round(e*l.width/l.height*100)/100,onContextMenu:n?f:void 0,className:`x1lliihq x2lah0s`,children:[(0,W.jsxs)(`defs`,{children:[(0,W.jsx)(`linearGradient`,{id:m,children:l.bandStops.map(e=>(0,W.jsx)(`stop`,{offset:e.offset,stopColor:e.color,stopOpacity:e.opacity},e.offset))}),(0,W.jsx)(`mask`,{id:p,maskUnits:`userSpaceOnUse`,...l.mask,children:(0,W.jsx)(Xh,{forMask:!0,ink:`#fff`,seal:{fill:`#fff`}})})]}),(0,W.jsx)(Xh,{echoRef:c,frontRef:s,ink:`currentColor`,seal:{className:`xe8yr7n x1tl3b4t`}}),(0,W.jsx)(`g`,{mask:`url(#${p})`,pointerEvents:`none`,children:(0,W.jsx)(`rect`,{fill:`url(#${m})`,ref:o,...l.band})})]})}var Qh=[`private`,`public`,`total`,`publishes`,`storage`,`objects`],$h=e=>e===`preparing`||e===`uploading`||e===`publishing`;function eg(e){if(!e||typeof e!=`object`)return null;let t=e;return typeof t.phase!=`string`||![`waiting`,`preparing`,`uploading`,`publishing`,`not-ready`,`failed`,`published`].includes(t.phase)||t.publishedAt!==null&&(typeof t.publishedAt!=`string`||!Number.isFinite(Date.parse(t.publishedAt)))||typeof t.autoPublish!=`boolean`||t.message!==void 0&&typeof t.message!=`string`||t.reasons!==void 0&&(!Array.isArray(t.reasons)||!t.reasons.every(e=>typeof e==`string`))?null:t}var tg=[`1d`,`7d`,`30d`,`never`],ng=(e,t)=>!!e?.expiresAt&&Date.parse(e.expiresAt)<=t;function rg(e){let t=e?.visibility??`private`,n=e?.cloud,r=!!n?.publishedAt;return{published:r,visibility:t,access:t===`private`&&n?.keyed?`key`:t,onProfile:n?.onProfile===!0,url:r?n.url:null,synced:!r||n.visibility===t}}function ig(e,t){return e===null?null:e?`upToDate`:t?`localChangesAuto`:`localChanges`}var ag=2e3,og=1e3,sg=3e5;async function Z(e,t,n){try{let r=await fetch(v(`/api/cloud/${t}`),{method:e,cache:`no-store`,headers:n===void 0?{}:{"Content-Type":`application/json`},body:n===void 0?void 0:JSON.stringify(n)}),i=await r.json().catch(()=>({}));return{ok:r.ok,status:r.status,json:i}}catch(e){return{ok:!1,status:0,json:{error:e.message}}}}var cg=null,lg=null,ug,dg=null,fg=new Set;function pg(){return lg??=Z(`GET`,`status`).then(e=>{if(lg=null,!e.ok)return null;cg=e.json;for(let e of fg)e(cg);return cg}),lg}function mg(e){return fg.add(e),dg??=xo(e=>{(e.type===`cloud-publication`||e.type===`cloud-published`)&&(clearTimeout(ug),ug=setTimeout(()=>void pg(),og))}),()=>{fg.delete(e),fg.size>0||(dg?.(),dg=null,clearTimeout(ug))}}function hg(){let[e,t]=(0,G.useState)(cg),[n,r]=(0,G.useState)(!1),i=(0,G.useRef)(null),a=(0,G.useCallback)(()=>pg(),[]),o=(0,G.useCallback)(()=>{i.current!==null&&window.clearInterval(i.current),i.current=null,r(!1)},[]),s=(0,G.useCallback)(async e=>{let t=e??(await Z(`POST`,`login`,{source:`viewer`})).json.url;if(!t)return;window.open(t,`_blank`,`noopener`),o(),r(!0);let n=Date.now();i.current=window.setInterval(async()=>{((await a())?.signedIn||Date.now()-n>sg)&&o()},ag)},[a,o]);return(0,G.useEffect)(()=>{let e=mg(t);return a(),()=>{e(),o()}},[a,o]),{status:e,refresh:a,login:s,waitingForLogin:n}}var gg=(0,G.createContext)(null);function _g({pageWindow:e,children:t}){return(0,W.jsx)(gg.Provider,{value:e??null,children:t})}var vg=()=>(0,G.useContext)(gg)??window;function yg(e,t){if(t===null)return e;let n=new URL(e);return n.searchParams.set(`page`,t),n.href}function bg(){let e=vg(),t=(0,G.useCallback)(t=>(e.addEventListener(`popstate`,t),e.addEventListener(`ryugi:pagechange`,t),()=>{e.removeEventListener(`popstate`,t),e.removeEventListener(`ryugi:pagechange`,t)}),[e]);return[(0,G.useSyncExternalStore)(t,()=>new URLSearchParams(e.location.search).get(`page`)),(0,G.useCallback)((t,n)=>{let r=new URL(e.location.href);r.searchParams.get(`page`)!==t&&(t===null?r.searchParams.delete(`page`):r.searchParams.set(`page`,t),e.history[n?`replaceState`:`pushState`](e.history.state,``,r),e.dispatchEvent(new Event(`ryugi:pagechange`)))},[e])]}var xg=[`B`,`KB`,`MB`,`GB`];function Sg(e){let t=e,n=0;for(;t>=1024&&n<xg.length-1;)t/=1024,n++;return`${n===0?t:Number(t.toFixed(1))} ${xg[n]}`}function Cg(e,t){return typeof e==`string`&&s.exists(`errors.${e}`)?s.t(`errors.${e}`):t}var wg=e=>typeof e==`object`&&!!e&&Qh.includes(e.kind)&&typeof e.max==`number`;function Tg({kind:e,max:t}){return s.t(`planLimit.${e}`,{max:e===`storage`?Sg(t):t})}function Eg(e,t){return e.code===`plan_limit`&&wg(e.limit)?Tg(e.limit):Cg(e.code,typeof e.error==`string`?e.error:t)}var Dg=!1,Og=new Set,kg=e=>{if(Dg!==e){Dg=e;for(let e of Og)e()}},Ag=()=>kg(!0),jg=()=>kg(!1),Mg=()=>Dg,Ng=e=>(Og.add(e),()=>Og.delete(e)),Pg=()=>(0,G.useSyncExternalStore)(Ng,Mg,Mg),Fg=e=>e?e.replace(/\/+$/,``):null,Ig=(e,t)=>{let n=Fg(e);return n?`${n}${t?.toLowerCase().startsWith(`zh`)?`/zh`:``}`:null},Lg=e=>{let t=Fg(e);return t?`${t}/`:null},Rg=(e,t)=>{let n=Fg(e);return n?`${n}/u/${encodeURIComponent(t)}`:null},zg=e=>{let t=Fg(e);return t?`${t}/billing`:null},Bg={summary:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kGuDYH:`xfifm61`,khDVqt:`xuxw1ft`,kMwMTN:`x7zghnd`,$$css:!0},card:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x167g77z`,kmVPX3:`xc7ga6q`,k1K539:`xod5an3`,kaIpWk:`xu4hgxq`,kWkggS:`xqdcvd7`,kMwMTN:`x7zghnd`,$$css:!0},success:{kWkggS:`xsf6uxt`,kMwMTN:`xh0clw4`,$$css:!0},failed:{kWkggS:`x8yy6z1`,kMwMTN:`xpt3syw`,$$css:!0}};function Vg({publication:e,published:t,publishedAt:n,online:r,onPublish:i,compact:a=!1,busy:o=!1}){let{t:s,i18n:c}=x(),l=Df(),u=e?.phase??(t?`published`:`waiting`),d=t&&u!==`published`,f=$h(u),p=s(`publication.${d?`update_${u}`:u}`),m=f?Ue:u===`failed`?fe:u===`published`?O:Wo,h=u===`failed`?Bg.failed:u===`published`?Bg.success:void 0,g=(0,W.jsx)(Ct,{"aria-hidden":`true`,icon:m,size:a?14:16,spin:f&&!l});if(a)return(0,W.jsxs)(`span`,{role:`status`,...S(Bg.summary,h),children:[g,p]});let _=e?.publishedAt??n,v=i&&!f&&u!==`published`&&u!==`not-ready`;return(0,W.jsxs)(`section`,{"aria-label":s(`publication.label`),...S(Bg.card,h),children:[(0,W.jsxs)(`div`,{role:`status`,className:`x78zum5 x6s0dn4 x167g77z xfifm61 x1s688f`,children:[g,p]}),(0,W.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:s(d&&u===`waiting`?`publication.updateWaitingDescription`:d&&u===`failed`?`publication.updateFailedDescription`:`publication.${u}Description`)}),e?.message?(0,W.jsx)(`p`,{role:`alert`,className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:e.message}):null,e?.reasons?.length?(0,W.jsx)(`ul`,{className:`x1ghz6dp xwn43p0 x1j6dyjg x4q1cud`,children:e.reasons.map((e,t)=>(0,W.jsx)(`li`,{children:e},t))}):null,v?(0,W.jsxs)(`button`,{disabled:o,type:`button`,onClick:i,className:`x78zum5 x6s0dn4 xl56j7k x17d4w8g x1rz828m x36usyh xc342km x1sxf85j x19ckca5 xs0jrwl xln7xf2 xfifm61 x1ypdohk`,children:[(0,W.jsx)(Do,{"aria-hidden":`true`,size:14}),s(u===`failed`?`publication.retry`:`publication.publishNow`)]}):null,!f&&u!==`published`?(0,W.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:s(r===!1?`publication.offline`:!i&&r===!0?`publication.updateLocal`:e?.autoPublish?u===`failed`?`publication.autoPublishRetry`:`publication.autoPublish`:`publication.manualPublish`)}):null,d?(0,W.jsxs)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud x1y1aw1k x178xt8z x13fuv20 xxu5053`,children:[s(`publication.previousVersion`),_?(0,W.jsxs)(W.Fragment,{children:[` `,(0,W.jsx)(`time`,{dateTime:_,children:new Date(_).toLocaleString(c.language)})]}):null]}):null]})}var Hg=(e,t)=>e===`public`&&(t===`private`||t===`unpublished`),Q={root:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x195vfkc`,keoZOQ:`x1xmf6yo`,kLKAdn:`x1y1aw1k`,kEafiO:`x178xt8z`,kPef9Z:`x13fuv20`,kLZC3w:`xxu5053`,$$css:!0},summary:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x167g77z`,kzqmXN:`xh8yej3`,kmVPX3:`x14zjhkh`,kMzoRj:`xc342km`,kaIpWk:`xu4hgxq`,kWkggS:`xjbqb8w x9jwiqo`,kMwMTN:`xo2rkog`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,k9WMMc:`x1yc453h`,kkrTdU:`x1ypdohk`,$$css:!0},icon:{k1xSpc:`xrvj5dj`,kgQiWS:`x1ku5rj1`,kUk6DE:`x1okw0bk`,kzqmXN:`xvy4d1p`,kZKoxP:`xxk0z11`,kaIpWk:`x1kogg8i`,kWkggS:`xahzvm9`,kMwMTN:`x1bo0w0s`,$$css:!0},text:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,kLWn49:`x1xfvgam`,$$css:!0},lead:{k1xSpc:`x1lliihq`,k63SB2:`x1s688f`,$$css:!0},sub:{k1xSpc:`x1lliihq`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,$$css:!0},chevron:{kMwMTN:`xddlp02`,$$css:!0},group:{k1xSpc:`x78zum5`,kjj79g:`x1qughib`,kogj98:`x12dmwbt`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,k63SB2:`xk50ysn`,$$css:!0},item:{k1xSpc:`x78zum5`,kGNEyG:`x1cy8zhl`,kOIVth:`x167g77z`,kmVPX3:`x14zjhkh`,$$css:!0},check:{kUk6DE:`x1okw0bk`,keoZOQ:`xvijh9v`,$$css:!0},body:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,$$css:!0},name:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,k63SB2:`xk50ysn`,kLWn49:`x1xfvgam`,$$css:!0},title:{k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,$$css:!0},type:{kUk6DE:`x1okw0bk`,kg3NbH:`xm9j1uf`,kaIpWk:`x12oqio5`,kWkggS:`xahzvm9`,kMwMTN:`x1bo0w0s`,kMv6JI:`x1fao0z8`,kGuDYH:`x1k6wstc`,$$css:!0},tag:{kUk6DE:`x1okw0bk`,kg3NbH:`xm9j1uf`,kaIpWk:`x12oqio5`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kMwMTN:`x1bo0w0s`,kGuDYH:`x1k6wstc`,$$css:!0},warnTag:{kVAM5u:`x9r1u3d`,kMwMTN:`x7zghnd`,$$css:!0},meta:{keoZOQ:`xvijh9v`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,kLWn49:`x37zpob`,$$css:!0},warn:{kMwMTN:`x7zghnd`,$$css:!0},error:{kMwMTN:`x12vcgws`,$$css:!0},action:{keoZOQ:`x1k70j0n`,$$css:!0}},Ug={pad:{kg3NbH:`x5k8d2m`,$$css:!0}},Wg=[{value:`private`,label:`share.onlyMe`,Icon:wo},{value:`public`,label:`share.anyone`,Icon:lt}];function Gg({busy:e,error:t,onCopyFailed:n,onPublish:r,onVisibility:i,readOnly:a,rootVisibility:o,state:s,title:c,type:l,url:u,uses:d}){let{t:f}=x(),p=Hg(o,s),m=f(s===`public`?`cascade.tag.public`:s===`private`?`cascade.tag.private`:s===`unpublished`?`beside.unpublished`:`beside.unsupported`),h=async()=>{if(u)try{await navigator.clipboard.writeText(u)}catch{n?.()}},g=!a&&s!==`unsupported`,_=Q;return(0,W.jsxs)(`div`,{"data-beside-card":``,className:`x78zum5 xdt5ytf x195vfkc x1xmf6yo xe8ttls xmkeg23 x1y0btm7 x12xov25 xhpnuu7`,children:[(0,W.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x1nejdyq xdd8z9q xddlp02 x1j6dyjg xk50ysn`,children:[(0,W.jsx)(Jo,{size:12}),f(`beside.title`)]}),(0,W.jsxs)(`span`,{...S(_.name,Ug.pad),children:[(0,W.jsx)(`span`,{...S(_.type),children:l}),(0,W.jsx)(`span`,{...S(_.title),children:c}),(0,W.jsx)(`span`,{...S(_.tag,p&&_.warnTag),children:m})]}),d||p?(0,W.jsxs)(`span`,{...S(_.meta,p&&_.warn,Ug.pad),children:[d?f(`referrers.uses`,{count:d}):null,d&&p?` · `:null,p?(0,W.jsx)(`span`,{"data-beside-hidden":``,children:f(`beside.hidden`)}):null]}):null,g||s!==`unsupported`?(0,W.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n x5k8d2m`,children:[g&&s===`unpublished`?(0,W.jsx)(Xe,{"data-beside-publish":``,disabled:e,size:`small`,onClick:()=>r?.(),children:f(`beside.publish`)}):null,g&&s!==`unpublished`?(0,W.jsx)(`span`,{role:`radiogroup`,className:`x3nfvp2 x1i3ajwb x1kogg8i xahzvm9`,children:Wg.map(({value:t,label:n,Icon:r})=>(0,W.jsxs)(`button`,{"aria-checked":t===s,"data-beside-visibility":t,disabled:e,role:`radio`,type:`button`,onClick:()=>t!==s&&i?.(t),...{0:{className:`x3nfvp2 x6s0dn4 x1jnr06f xf4egzd xdqyycr xc342km x1sxf85j xjbqb8w x1bo0w0s xqfszdh x1j6dyjg x1ypdohk`},1:{className:`x3nfvp2 x6s0dn4 x1jnr06f xf4egzd xdqyycr xc342km x1sxf85j xqfszdh x1j6dyjg x1ypdohk x1rozbrz xo2rkog`}}[t===s|0],children:[(0,W.jsx)(r,{size:11}),f(n)]},t))}):null,(0,W.jsx)(`span`,{className:`x98rzlu`}),(0,W.jsx)(Xe,{"aria-label":f(`beside.copyLink`),"data-beside-copy":``,disabled:!u,icon:Me,size:`small`,onClick:()=>void h()})]}):null,t?(0,W.jsx)(`span`,{"data-beside-error":``,...S(_.meta,_.error,Ug.pad),children:t}):null]})}var Kg=[`unpublished`,`stale`,`private`,`withdrawn`],qg=[`unpublished`,`stale`];function Jg(e,t,n){let r=new Map(e.map(e=>[e.artifact,e])),i=e=>Kg.includes(e.state)&&(t[e.artifact]??qg.includes(e.state)),a=e=>n?e===n:!r.has(e),o=new Set,s=e=>{if(a(e))return!0;let t=r.get(e);return!!t&&o.has(e)&&(t.open||i(t))};for(let t=!0;t;){t=!1;for(let n of e)!o.has(n.artifact)&&n.parents.some(s)&&(o.add(n.artifact),t=!0)}return e.map(e=>{let{reason:t,upstream:n,...r}=e,a=e.state===`blocked`?e.blocked:void 0;return o.has(e.artifact)?{...r,checked:i(e),selectable:Kg.includes(e.state),...a?{reason:a}:{}}:{...r,checked:!1,selectable:!1,reason:`upstream`,upstream:e.via??e.parents[0]}})}var Yg=e=>e.selectable?e.state===`private`?`private`:e.state===`withdrawn`?`skipped`:`publish`:e.state===`ready`?`ready`:`skipped`;function Xg({busy:e,error:t,includeRoot:n,items:r,offline:i,onPublish:a,results:o,rootVisibility:s}){let{t:c}=x(),[l,u]=(0,G.useState)(!1),[d,f]=(0,G.useState)({}),p=(0,G.useMemo)(()=>{let e=Jg(r,d);return i?e.map(e=>e.state===`private`?e:{...e,checked:!1,selectable:!1,reason:e.reason??`offline`}):e},[r,d,i]);if(!r.length)return null;let m=e=>r.find(t=>t.artifact===e)?.title??e,h=p.filter(e=>e.state!==`ready`&&e.state!==`private`).length,g=p.filter(e=>e.state===`private`&&!e.checked).length,_=p.filter(e=>e.checked),v=new Map((o??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),y=p.some(e=>e.state!==`ready`),b=()=>a(_.filter(e=>e.state!==`private`).map(e=>e.artifact),_.filter(e=>e.state===`private`).map(e=>e.artifact)),C=e=>{let t=v.get(e.artifact);return t?.error?{text:t.error.error,tone:Q.error}:e.reason===`offline`?{text:c(`cascade.offline`),tone:null}:e.reason===`upstream`?{text:c(`cascade.upstream`,{via:m(e.upstream??``)}),tone:null}:{text:[e.state===`blocked`?e.reason??``:e.state===`private`?c(`cascade.private`):e.state===`ready`?``:c(`cascade.${e.state}`),e.via?c(`cascade.via`,{via:m(e.via)}):``].filter(Boolean).join(` · `),tone:e.state===`private`?Q.warn:null}},w=[`publish`,`private`,`skipped`,`ready`],T=y?(0,W.jsx)(Xe,{block:!0,"data-cascade-publish":``,disabled:!_.length||e,loading:e,type:n?`primary`:`default`,onClick:b,...S(Q.action),children:c(n?`cascade.publishWithRoot`:`cascade.publish`,{count:_.length})}):null;return(0,W.jsxs)(`div`,{...S(Q.root),children:[(0,W.jsxs)(`button`,{"aria-expanded":l,"data-cascade-summary":``,type:`button`,onClick:()=>u(e=>!e),...S(Q.summary),children:[(0,W.jsx)(`span`,{...S(Q.icon),children:(0,W.jsx)(Ae,{size:13})}),(0,W.jsxs)(`span`,{...S(Q.text),children:[(0,W.jsx)(`span`,{...S(Q.lead),children:h?c(`cascade.summaryPending`,{total:r.length,pending:h}):c(`cascade.summaryReady`,{total:r.length})}),g?(0,W.jsx)(`span`,{...S(Q.sub),children:c(`cascade.summaryLocked`,{count:g})}):null,i?(0,W.jsx)(`span`,{...S(Q.sub),children:c(`cascade.offlineHint`)}):null]}),l?(0,W.jsx)(ot,{size:14,...S(Q.chevron)}):(0,W.jsx)(me,{size:14,...S(Q.chevron)})]}),l?w.map(t=>{let n=p.filter(e=>Yg(e)===t);if(!n.length)return null;let r=c(t===`publish`?`cascade.group.publish.${s}`:`cascade.group.${t}`);return(0,W.jsxs)(`div`,{"data-cascade-group":t,children:[(0,W.jsxs)(`div`,{...S(Q.group),children:[(0,W.jsx)(`span`,{children:r}),(0,W.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=C(t);return(0,W.jsxs)(`label`,{"data-cascade-item":t.artifact,...S(Q.item),children:[(0,W.jsx)(`span`,{...S(Q.check),children:(0,W.jsx)(Vp,{checked:t.checked,disabled:!t.selectable||e,onChange:e=>f(n=>({...n,[t.artifact]:e}))})}),(0,W.jsxs)(`span`,{...S(Q.body),children:[(0,W.jsxs)(`span`,{...S(Q.name),children:[(0,W.jsx)(`span`,{...S(Q.type),children:t.artifact.split(`/`)[0]}),(0,W.jsx)(`span`,{...S(Q.title),children:t.title}),t.state===`private`?(0,W.jsx)(`span`,{...S(Q.tag,Q.warnTag),children:c(`cascade.tag.private`)}):t.state===`ready`?(0,W.jsx)(`span`,{...S(Q.tag),children:c(`cascade.tag.${s}`)}):null]}),n.text?(0,W.jsx)(`span`,{...S(Q.meta,n.tone),children:n.text}):null]})]},t.artifact)})]},t)}):null,t?(0,W.jsx)(`span`,{...S(Q.meta,Q.error),children:t}):null,T]})}function Zg(e,t,n){let r=n?e.filter(e=>e.artifact!==n&&e.cloudId!==n):e,i=r.filter(e=>e.state!==`ready`);return{shown:r,hidden:i.length,allPrivate:i.length>0&&i.every(e=>e.state===`private`),visible:t===`public`&&i.length>0}}var Qg=[`private`,`unpublished`,`unlinked`,`ready`,`skipped`],$g=e=>e===`withdrawn`||e===`blocked`?`skipped`:e;function e_({busy:e,cloudUnavailable:t,error:n,exclude:r,items:i,onPublish:a,results:o,rootVisibility:s}){let{t:c}=x(),[l,u]=(0,G.useState)(!1),[d,f]=(0,G.useState)({}),{shown:p,hidden:m,allPrivate:h,visible:g}=Zg(i,s,r);if(!g)return null;let _=e=>e.selectable&&(d[e.artifact]??e.checked),v=p.filter(_),y=new Map((o??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),b=e=>{let t=y.get(e.artifact)?.error?.error;if(t)return{text:t,tone:Q.error};let n=e.state===`blocked`?e.reason:e.state===`withdrawn`?c(`referrers.withdrawn`):``;return{text:[c(`referrers.uses`,{count:e.uses}),n].filter(Boolean).join(` · `),tone:null}},C=()=>a(v.filter(e=>e.state!==`private`).map(e=>e.artifact),v.filter(e=>e.state===`private`).map(e=>e.artifact));return(0,W.jsxs)(`div`,{...S(Q.root),children:[(0,W.jsxs)(`button`,{"aria-expanded":l,"data-referrer-summary":``,type:`button`,onClick:()=>u(e=>!e),...S(Q.summary),children:[(0,W.jsx)(`span`,{...S(Q.icon),children:(0,W.jsx)(qt,{size:13})}),(0,W.jsxs)(`span`,{...S(Q.text),children:[(0,W.jsx)(`span`,{...S(Q.lead),children:c(`referrers.summary`,{total:p.length})}),(0,W.jsx)(`span`,{...S(Q.sub,Q.warn),children:c(h?`referrers.hiddenPrivate`:`referrers.hidden`,{count:m})}),t?(0,W.jsx)(`span`,{...S(Q.sub),children:c(`referrers.cloudUnavailable`)}):null]}),l?(0,W.jsx)(ot,{size:14,...S(Q.chevron)}):(0,W.jsx)(me,{size:14,...S(Q.chevron)})]}),l?Qg.map(t=>{let n=p.filter(e=>$g(e.state)===t);return n.length?(0,W.jsxs)(`div`,{"data-referrer-group":t,children:[(0,W.jsxs)(`div`,{...S(Q.group),children:[(0,W.jsx)(`span`,{children:c(`referrers.group.${t}`)}),(0,W.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=b(t);return(0,W.jsxs)(`label`,{"data-referrer-item":t.artifact,...S(Q.item),children:[(0,W.jsx)(`span`,{...S(Q.check),children:(0,W.jsx)(Vp,{checked:_(t),disabled:!t.selectable||e,onChange:e=>f(n=>({...n,[t.artifact]:e}))})}),(0,W.jsxs)(`span`,{...S(Q.body),children:[(0,W.jsxs)(`span`,{...S(Q.name),children:[(0,W.jsx)(`span`,{...S(Q.type),children:`document`}),(0,W.jsx)(`span`,{...S(Q.title),children:t.title}),t.state===`private`?(0,W.jsx)(`span`,{...S(Q.tag,Q.warnTag),children:c(`cascade.tag.private`)}):t.state===`ready`?(0,W.jsx)(`span`,{...S(Q.tag),children:c(`cascade.tag.public`)}):null]}),(0,W.jsx)(`span`,{...S(Q.meta,n.tone),children:n.text})]})]},t.artifact)})]},t):null}):null,n?(0,W.jsx)(`span`,{...S(Q.meta,Q.error),children:n}):null,l?(0,W.jsx)(Xe,{block:!0,"data-referrer-publish":``,disabled:!v.length||e,loading:e,onClick:C,...S(Q.action),children:c(`referrers.publish`,{count:v.length})}):null]})}var t_=864e5;function n_({text:e,action:t,onConfirm:n,onCancel:r}){let{t:i}=x();return(0,W.jsxs)(`div`,{"data-share-confirm":``,className:`x1k70j0n xe8ttls xmkeg23 x1y0btm7 x12xov25 xu4hgxq x2fo67v`,children:[(0,W.jsx)(`p`,{className:`x1q6ys4k x1j6dyjg x37zpob`,children:e}),(0,W.jsxs)(`div`,{className:`x78zum5 x13a6bvl x17d4w8g`,children:[(0,W.jsx)(Xe,{"data-confirm":`no`,size:`small`,onClick:r,children:i(`common.cancel`)}),(0,W.jsx)(Xe,{"data-confirm":`yes`,size:`small`,type:`primary`,onClick:n,children:t})]})]})}function r_({value:e,disabled:t,onExpiry:n,onRegenerate:r}){let{t:i,i18n:a}=x(),[o]=(0,G.useState)(()=>Date.now()),s=ng(e,o),c=e.expiresAt?new Date(e.expiresAt).toLocaleDateString(a.language,{month:`short`,day:`numeric`}):null,l=e.expiresAt?s?i(`share.expired`,{date:c}):i(`share.expiresIn`,{count:Math.max(1,Math.ceil((Date.parse(e.expiresAt)-o)/t_)),date:c}):i(`share.neverExpires`),u=tg.map(e=>({value:e,label:i(`share.expiry.${e}`)}));return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsxs)(`div`,{className:`x78zum5 x1a02dak x6s0dn4 x1qughib x167g77z xwkmoec x1bo0w0s xfifm61`,children:[(0,W.jsxs)(`label`,{"data-key-expired":s?``:void 0,"data-key-expiry":``,className:`x1n2onr6 x3nfvp2 xeuugli xss6m8b`,children:[(0,W.jsx)(`span`,{className:`x10l6tqk x1i1rx1s xjm9jq1 xb3r6kr xuxw1ft x1hyvwdk`,children:i(`share.expiryLabel`)}),(0,W.jsx)(bo,{disabled:t,options:u,placeholder:(0,W.jsx)(`span`,{...{0:{},1:{className:`x12vcgws`}}[!!s|0],children:l}),prefix:vo,size:`small`,style:{width:`auto`,minWidth:0,fontSize:11},value:null,onSelect:e=>n(e)})]}),(0,W.jsx)(Xe,{"data-key-regenerate":``,disabled:t,icon:ns,outdent:`end`,size:`small`,style:{fontSize:11},type:`text`,onClick:r,children:i(`share.regenerate`)})]}),s?(0,W.jsx)(`p`,{className:`x8k27cj x1bo0w0s x1j6dyjg x37zpob`,children:i(`share.expiredNote`)}):null]})}var i_=[{value:`private`,label:`share.onlyMe`,hint:`share.onlyMeHint`,Icon:wo},{value:`key`,label:`share.keyHolders`,hint:`share.keyHint`,Icon:Qo},{value:`public`,label:`share.anyone`,hint:`share.anyoneHint`,Icon:lt}],a_={private:{text:`share.removeKeyConfirm`,action:`share.removeKey`},public:{text:`share.makePublicConfirm`,action:`share.makePublic`},regenerate:{text:`share.regenerateConfirm`,action:`share.regenerate`}};function o_({beside:e,cascade:t,children:n,foot:r,onCopyFailed:i,onVisibility:a,profile:o,referrers:s,saving:c=!1,shareKey:l,status:u,url:d,visibility:f}){let{t:p}=x(),[m,h]=(0,G.useState)(!1),[g,_]=(0,G.useState)(null),[v]=(0,G.useState)(()=>Date.now());(0,G.useEffect)(()=>{if(!m)return;let e=setTimeout(()=>h(!1),2e3);return()=>clearTimeout(e)},[m]);let y=l?.active?`key`:f,b=y===`key`?l?.value?.url??null:d,S=async()=>{if(b)try{await navigator.clipboard.writeText(b),h(!0)}catch{i?.()}},C=e=>{e!==y&&(e===`key`?l?.onSelect():y===`key`?_(e):a(e))},w=()=>{g===`private`?l?.onRemove():g===`public`?a(`public`):g===`regenerate`&&l?.onRegenerate(),_(null)},T=y===`key`?l?.value??null:null,E=ng(T,v);return(0,W.jsxs)(`div`,{className:`x78zum5 xdt5ytf x195vfkc x58rd6w xqfszdh xfifm61`,children:[u,(0,W.jsx)(`p`,{className:`x1coi2bq xfifm61 x1s688f`,children:p(`share.whoCanSee`)}),(0,W.jsx)(`div`,{"aria-label":p(`share.whoCanSee`),role:`radiogroup`,className:`x78zum5 xdt5ytf x195vfkc`,children:i_.filter(({value:e})=>e!==`key`||l).map(({value:e,label:t,hint:n,Icon:r})=>(0,W.jsxs)(`button`,{"aria-checked":e===y,"data-visibility":e,disabled:c,role:`radio`,type:`button`,onClick:()=>C(e),...{0:{className:`x78zum5 xh8yej3 x6s0dn4 x167g77z x1ruevkc xmkeg23 x1y0btm7 x9r1u3d xu4hgxq xjbqb8w x9jwiqo xo2rkog xqfszdh x1yc453h x1ypdohk`},1:{className:`x78zum5 xh8yej3 x6s0dn4 x167g77z x1ruevkc xmkeg23 x1y0btm7 xu4hgxq xo2rkog xqfszdh x1yc453h x1ypdohk xgcsv5v x15dg6x3`}}[e===y|0],children:[(0,W.jsx)(`span`,{...{0:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i xahzvm9`},1:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i x19ckca5 xs0jrwl`}}[e===y|0],children:(0,W.jsx)(r,{size:12})}),(0,W.jsxs)(`span`,{children:[(0,W.jsxs)(`span`,{className:`x1lliihq xfifm61 x1s688f xwn7fz2`,children:[p(t),e===`key`&&l?.locked?(0,W.jsx)(`span`,{"data-pro-badge":``,className:`xdzw4kq xm9j1uf xmkeg23 x1y0btm7 xgcsv5v x12oqio5 x1bo0w0s x1k6wstc x1s688f x1xxsxie`,children:p(`share.proBadge`)}):null]}),(0,W.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:p(n)})]})]},e))}),y===`public`&&o?(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z x16ngw23 x12ulsxz x1icxu4v x1bo0w0s x1j6dyjg xwn7fz2`,children:[(0,W.jsxs)(`span`,{children:[p(`share.showOnProfile`),o.path?(0,W.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:o.path}):null]}),(0,W.jsx)(`button`,{"aria-checked":o.shown,"aria-label":p(`share.showOnProfile`),"data-profile-switch":``,disabled:c,role:`switch`,type:`button`,onClick:()=>o.onChange(!o.shown),...{0:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x15dg6x3 x1ypdohk`},1:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x1ypdohk x19ckca5`}}[!!o.shown|0],children:(0,W.jsx)(`span`,{...{0:{className:`x10l6tqk xs7f9wi xaoy8p5 x1fsd2vl x170jfvy x16rqkct x1rozbrz x2hifos xgdialr`},1:{className:`x10l6tqk xs7f9wi x1fsd2vl x170jfvy x16rqkct x1rozbrz x2hifos xgdialr x1r4y97`}}[!!o.shown|0]})})]}):null,(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n`,children:[(0,W.jsx)(`input`,{readOnly:!0,"aria-label":p(`share.linkLabel`),"data-share-url":``,"data-struck":E?``:void 0,placeholder:p(y===`key`?`share.keyPending`:`share.linkPending`),value:b??``,onFocus:e=>e.currentTarget.select(),...{0:{className:`x98rzlu xeuugli xc342km x1a2a7pz xifx94n xdqyycr x1sxf85j x2fo67v x1bo0w0s x1fao0z8 x1j6dyjg xb3r6kr xlyipyv xuxw1ft`},1:{className:`x98rzlu xeuugli xc342km x1a2a7pz xifx94n xdqyycr x1sxf85j x2fo67v x1fao0z8 x1j6dyjg xb3r6kr xlyipyv xuxw1ft xc7n51q x5lhwog`}}[!!E|0]}),(0,W.jsx)(Xe,{disabled:!b,icon:Co,size:`small`,type:`primary`,onClick:()=>void S(),children:p(m?`share.copied`:`share.copy`)})]}),g?(0,W.jsx)(n_,{action:p(a_[g].action),text:p(a_[g].text),onCancel:()=>_(null),onConfirm:w}):T&&l?(0,W.jsx)(r_,{disabled:c,value:T,onExpiry:l.onExpiry,onRegenerate:()=>_(`regenerate`)}):null,r&&y!==`key`?(0,W.jsx)(`div`,{className:`x8k27cj xddlp02 x1j6dyjg`,children:r}):null,e?(0,W.jsx)(Gg,{...e}):null,t?(0,W.jsx)(Xg,{...t}):null,s?(0,W.jsx)(e_,{...s}):null,n]})}var s_=`ryugi.pendingCloudIntent`,c_=6e5;function l_(e,t){try{let n={artifact:e,intent:t,at:Date.now()};window.sessionStorage.setItem(s_,JSON.stringify(n))}catch{}}function u_(e){try{let t=window.sessionStorage.getItem(s_);if(!t)return null;let n=JSON.parse(t);return n.artifact!==e||n.intent!==`share`&&n.intent!==`phone`&&n.intent!==`sync`||typeof n.at!=`number`||Date.now()-n.at>c_?(typeof n.at==`number`&&Date.now()-n.at>c_&&window.sessionStorage.removeItem(s_),null):(window.sessionStorage.removeItem(s_),n.intent)}catch{return null}}function d_({origin:e}){let{t,i18n:n}=x(),r=e.replace(/\/+$/,``),i=n.language?.toLowerCase().startsWith(`zh`)?`/zh`:``;return(0,W.jsxs)(`p`,{className:`x1ghz6dp x1j6dyjg x1evy7pa xddlp02`,children:[t(`common.authLegalPrefix`),(0,W.jsx)(`a`,{href:`${r}${i}/terms`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.terms`)}),t(`common.authLegalAnd`),(0,W.jsx)(`a`,{href:`${r}${i}/privacy`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.privacy`)}),t(`common.authLegalSuffix`)]})}var f_=[{id:`share`,icon:Ae,titleKey:`cloudIntent.shareTitle`,descKey:`cloudIntent.shareDesc`},{id:`phone`,icon:cs,titleKey:`cloudIntent.phoneTitle`,descKey:`cloudIntent.phoneDesc`},{id:`sync`,icon:Do,titleKey:`cloudIntent.syncTitle`,descKey:`cloudIntent.syncDesc`}],p_={share:`cloudIntent.shareCta`,phone:`cloudIntent.phoneCta`,sync:`cloudIntent.syncCta`},m_={share:`cloudIntent.sharePrivacy`,phone:`cloudIntent.phonePrivacy`,sync:`cloudIntent.syncPrivacy`};function h_({origin:e,landingUrl:t,waitingForLogin:n,onStartIntent:r}){let{t:i}=x(),[a,o]=(0,G.useState)(`share`);return(0,W.jsxs)(`div`,{"data-intent-login-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x168biu4 xw7nakj xqfszdh xfifm61 xo2rkog`,children:[(0,W.jsxs)(`div`,{className:`x78zum5 x1cy8zhl x1qughib x167g77z`,children:[(0,W.jsxs)(`div`,{children:[(0,W.jsx)(`span`,{className:`x1lliihq x2ouz8m x1s688f xo2rkog`,children:i(`cloudIntent.heading`)}),(0,W.jsx)(`span`,{className:`x1lliihq x1qt5hsa x1bo0w0s xr9ek0c`,children:i(`cloudIntent.subheading`)})]}),(0,W.jsx)(`span`,{className:`x1s31vzs x1s688f x1o8fvuk x6z2zk2 xj8oexa xlkn9b3 x1e6avla xuxw1ft x2lah0s`,children:i(`cloudIntent.badge`)})]}),(0,W.jsx)(`div`,{"aria-label":i(`cloudIntent.heading`),role:`radiogroup`,className:`x78zum5 xdt5ytf x1j9xkj6`,children:f_.map(({id:e,icon:t,titleKey:n,descKey:r})=>{let s=a===e;return(0,W.jsxs)(`button`,{"aria-checked":s,"data-cloud-intent":e,role:`radio`,type:`button`,...{0:{className:`xh8yej3 x1yc453h x78zum5 x1cy8zhl x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x12xov25 x1qj25k6 x1q4ynmn x1rozbrz x9jwiqo x1ypdohk xqfszdh x1mimgl9`},1:{className:`xh8yej3 x1yc453h x78zum5 x1cy8zhl x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x1q4ynmn x1ypdohk xqfszdh x1mimgl9 x1ektstd x1xrkum6`}}[!!s|0],onClick:()=>o(e),children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,...{0:{className:`x23j0i4 xd7y6wv xu4hgxq xahzvm9 xo2rkog xrvj5dj x1ku5rj1 x2lah0s xvijh9v`},1:{className:`x23j0i4 xd7y6wv xu4hgxq xrvj5dj x1ku5rj1 x2lah0s xvijh9v x1teopom x1cge3fn`}}[!!s|0],children:(0,W.jsx)(t,{size:14})}),(0,W.jsxs)(`span`,{className:`x98rzlu xeuugli`,children:[(0,W.jsx)(`span`,{className:`x1lliihq x1ct8sxb x1s688f xo2rkog`,children:i(n)}),(0,W.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4 xvijh9v`,children:i(r)})]}),(0,W.jsx)(`span`,{"aria-hidden":`true`,...{0:{className:`x1a00udw xx3o462 x16rqkct xvndefy x1y0btm7 xgcsv5v x2lah0s x1gslohp xrvj5dj x1ku5rj1 x9f619`},1:{className:`x1a00udw xx3o462 x16rqkct xvndefy x1y0btm7 x2lah0s x1gslohp xrvj5dj x1ku5rj1 x9f619 x1ektstd x15az74h`}}[!!s|0],children:s?(0,W.jsx)(`span`,{className:`x1ftt334 x1ycjhwn x16rqkct x1vi11w0`}):null})]},e)})}),(0,W.jsx)(Xe,{className:{className:`xh8yej3 x90ne7k x15az74h x12s0oaj x1ektstd x1w8fas2 xt9vybz xh88oxj`}.className,"data-cloud-intent-submit":``,icon:yo,loading:n,type:`primary`,onClick:()=>r(a),children:i(n?`publish.waitingLogin`:p_[a])}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g xknfcqp x1q4txso xur7f20 x2fo67v x1j6dyjg x1bo0w0s xfrs9s4`,children:[(0,W.jsx)(wo,{"aria-hidden":`true`,size:12,style:{flexShrink:0}}),(0,W.jsx)(`span`,{children:i(m_[a])})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,W.jsx)(d_,{origin:e}),t?(0,W.jsxs)(`a`,{href:t,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[i(`cloudEntry.learnShort`),(0,W.jsx)(Eo,{"aria-hidden":`true`,size:11})]}):null]})]})}var g_={bar:{kbCHJM:`x1nrll8i`,krVfgx:`xjnlgov`,k3aq6I:`xuuh30`,k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x1v2ro7d`,ks0D6T:`x4d2062`,kZKoxP:`xn3w4p2`,kB7OPa:`x9f619`,kZCmMZ:`x106a9eq`,kwRFfy:`x1icxu4v`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kaIpWk:`x1e6avla`,kWkggS:`x12ilycc`,kMwMTN:`xo2rkog`,kGVxlE:`x1gxogt1`,kGuDYH:`x4z9k3i`,kLWn49:`x37zpob`,khDVqt:`xuxw1ft`,$$css:!0},absolute:{kVAEAm:`x10l6tqk`,kY2c9j:`x1n327nk`,$$css:!0},fixed:{kVAEAm:`xixxii4`,kY2c9j:`x68pp3s`,$$css:!0},text:{k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,$$css:!0},muted:{kMwMTN:`x1bo0w0s`,$$css:!0},changed:{kMwMTN:`xr46axq`,$$css:!0},agent:{kMwMTN:`x1yz8712`,$$css:!0},success:{kMwMTN:`xcqng5w`,$$css:!0},rule:{kzqmXN:`x1i1rx1s`,kZKoxP:`xlup9mm`,kmuXW:`x2lah0s`,kWkggS:`xh6qj2i`,$$css:!0},button:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kmuXW:`x2lah0s`,kZKoxP:`x10w6t97`,kMzoRj:`xc342km`,kaIpWk:`x1e6avla`,kMv6JI:`xjb2p0i`,kGuDYH:`x4z9k3i`,kkrTdU:`x1ypdohk`,$$css:!0},anchor:{kMnn75:`xkrqix3`,$$css:!0},primary:{kg3NbH:`xqin4a2`,kWkggS:`x19ckca5`,kMwMTN:`xs0jrwl`,k63SB2:`xk50ysn`,kSiTet:`x1hc1fzr x1k29llp`,$$css:!0},quiet:{kg3NbH:`xaope02`,kWkggS:`xjbqb8w xj0l527`,kMwMTN:`x1bo0w0s`,$$css:!0},link:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kOIVth:`x1jnr06f`,kmuXW:`x2lah0s`,kmVPX3:`x1717udv`,kMzoRj:`xc342km`,kWkggS:`xjbqb8w`,kMwMTN:`x1bo0w0s xytdrwj`,kMv6JI:`xjb2p0i`,kGuDYH:`x4z9k3i`,kMnn75:`xujl8zx`,k1TLXF:`x1tdp7nx`,kcSHmL:`xda060z`,kkrTdU:`x1ypdohk`,$$css:!0}};function __({position:e,children:t,style:n,...r}){return(0,W.jsx)(`div`,{"data-action-bar":!0,...r,...S(g_.bar,g_[e]),style:n,children:t})}function v_({children:e,tone:t=`default`,limit:n}){return(0,W.jsx)(`span`,{...S(g_.text,t!=="default"&&g_[t]),style:n?{maxWidth:n}:void 0,children:e})}function y_(){return(0,W.jsx)(`span`,{className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})}function b_({variant:e,children:t,...n}){return(0,W.jsx)(`a`,{...n,...S(g_.button,g_.anchor,g_[e]),children:t})}function x_({variant:e,children:t,...n}){return(0,W.jsx)(`button`,{type:`button`,...n,...S(e===`link`?g_.link:[g_.button,g_[e]]),children:t})}function S_({result:e,onDismiss:t,onOpenSharePanel:n}){let{t:r}=x(),[i,a]=(0,G.useState)(!1),[o,s]=(0,G.useState)(!!e.copied),c=async()=>{if(e.url)try{await navigator.clipboard.writeText(e.url),s(!0)}catch{}};return e.error?(0,W.jsxs)(__,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[(0,W.jsx)(v_,{limit:380,tone:`muted`,children:e.error}),(0,W.jsx)(x_,{variant:`primary`,onClick:n,children:r(`cloudIntent.viewDetails`)}),(0,W.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xgd8bvy x1fgtraw x1717udv xc342km x1e6avla xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk x2lah0s`,onClick:t,children:(0,W.jsx)(ht,{size:13})})]}):(0,W.jsxs)(W.Fragment,{children:[i&&e.url?(0,W.jsxs)(`aside`,{"aria-label":r(`cloudIntent.qrTitle`),"data-intent-qr-popover":``,role:`dialog`,className:`xixxii4 x1nrll8i xhjxwu4 xuuh30 x12tvco5 x149cmgi xw7nakj x1tamke2 xmkeg23 x1y0btm7 x12xov25 xixl9f9 x12ilycc x1ytezby xo2rkog xqfszdh xfifm61 x78zum5 xdt5ytf x1v2ro7d`,children:[(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,W.jsx)(`span`,{className:`x4z9k3i x1s688f`,children:r(`cloudIntent.qrTitle`)}),(0,W.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xvy4d1p xxk0z11 x1717udv xc342km x1kogg8i xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk`,onClick:()=>a(!1),children:(0,W.jsx)(ht,{size:13})})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1af02g3`,children:[(0,W.jsx)(`div`,{className:`x1ruevkc xmkeg23 x1y0btm7 x12xov25 x1q4ynmn xqm9i1m x2lah0s xrvj5dj x1ku5rj1`,children:(0,W.jsx)(Gm,{bgColor:`#ffffff`,bordered:!1,color:`#141416`,size:108,value:e.url})}),(0,W.jsxs)(`div`,{className:`x78zum5 xdt5ytf x167g77z xeuugli x98rzlu`,children:[(0,W.jsx)(`p`,{className:`x1ghz6dp x1qt5hsa x1jjo3f5 x1bo0w0s`,children:r(`cloudIntent.qrDesc`)}),(0,W.jsx)(`div`,{children:(0,W.jsx)(Xe,{icon:(0,W.jsx)(Co,{size:12}),size:`small`,onClick:()=>void c(),children:r(o?`cloudIntent.copied`:`cloudIntent.copyPhoneLink`)})})]})]}),e.billingUrl?(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x1jw0pk6 xhpnuu7 x1xrkum6 x1qt5hsa`,children:[(0,W.jsx)(`span`,{className:`x1bo0w0s xfrs9s4`,children:r(`cloudIntent.proRelayHint`)}),(0,W.jsxs)(`a`,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 xd7y6wv x1awh872 x1kogg8i x15az74h x12s0oaj xt9vybz x1qt5hsa xh88oxj x1hl2dhg xuxw1ft x2lah0s`,children:[r(`cloudIntent.proRelayCta`),` ↗`]})]}):null]}):null,(0,W.jsxs)(__,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[e.intent===`share`?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(v_,{limit:380,tone:`success`,children:e.copied?r(`cloudIntent.toastShareCopied`,{login:e.login}):r(`cloudIntent.toastShare`,{login:e.login})}),(0,W.jsx)(x_,{variant:`quiet`,onClick:n,children:r(`cloudIntent.changeAccess`)}),e.url?(0,W.jsxs)(b_,{href:e.url,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudIntent.openLink`),` ↗`]}):null]}):e.intent===`phone`?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(v_,{limit:360,tone:`success`,children:r(`cloudIntent.toastPhone`)}),e.billingUrl?(0,W.jsx)(b_,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`quiet`,children:r(`cloudIntent.learnRelay`)}):null,e.url?(0,W.jsx)(x_,{variant:`primary`,onClick:()=>a(e=>!e),children:r(i?`cloudIntent.hideQr`:`cloudIntent.showQr`)}):null]}):(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(v_,{limit:380,tone:`success`,children:r(`cloudIntent.toastSync`,{login:e.login})}),(0,W.jsx)(x_,{variant:`quiet`,onClick:Ag,children:r(`cloudIntent.projectConfig`)}),e.dashboardUrl?(0,W.jsxs)(b_,{href:e.dashboardUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudEntry.openShort`),` ↗`]}):null]}),(0,W.jsx)(`button`,{"aria-label":r(`artboard.close`),type:`button`,className:`xgd8bvy x1fgtraw x1717udv xc342km x1e6avla xjbqb8w xj0l527 x1bo0w0s xrvj5dj x1ku5rj1 x1ypdohk x2lah0s`,onClick:()=>{a(!1),t()},children:(0,W.jsx)(ht,{size:13})})]})]})}var $={trigger:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x17d4w8g`,kZKoxP:`x1gnnpzl`,kg3NbH:`x1awh872`,kMzoRj:`xmkeg23`,ksu8eU:`x1y0btm7`,kVAM5u:`x12xov25`,kaIpWk:`xur7f20`,kWkggS:`x12ilycc xj0l527`,kMwMTN:`xo2rkog`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,kkrTdU:`x1ypdohk`,khDVqt:`xuxw1ft`,$$css:!0},shellCta:{kZKoxP:`x1fgtraw`,kZCmMZ:`xe2zdcy`,kwRFfy:`xpdmqnj`,kaIpWk:`x1e6avla`,kVAM5u:`x1rqon0r`,kWkggS:`x19ckca5 x1et1poy`,kMwMTN:`xs0jrwl`,k63SB2:`xk50ysn`,$$css:!0},brandDot:{kzqmXN:`x1v4s8kt`,kZKoxP:`xols6we`,kaIpWk:`x16rqkct`,kWkggS:`x1iug7pk`,kmuXW:`x2lah0s`,$$css:!0},floating:{kVAEAm:`xixxii4`,k87sOh:`x1tk7jg1`,kCIrl2:`xlftelb`,kY2c9j:`x1n327nk`,kGVxlE:`x1cqdj14`,$$css:!0},dot:{kzqmXN:`x1v4s8kt`,kZKoxP:`xols6we`,kaIpWk:`x16rqkct`,kWkggS:`xzkukvh`,$$css:!0},panel:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kOIVth:`x1v2ro7d`,kzqmXN:`x1m258z3`,kMv6JI:`xqfszdh`,kGuDYH:`xfifm61`,$$css:!0},row:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kjj79g:`x1qughib`,kOIVth:`x167g77z`,$$css:!0},muted:{kMwMTN:`x1bo0w0s`,kLWn49:`x1dbl2gt`,$$css:!0},link:{kUk6DE:`x98rzlu`,k7Eaqz:`xeuugli`,kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,kMv6JI:`x1fao0z8`,kGuDYH:`x1j6dyjg`,kMwMTN:`x9f21nr`,$$css:!0},textButton:{kmVPX3:`x1717udv`,kMzoRj:`xc342km`,kWkggS:`xjbqb8w`,kMwMTN:`xddlp02`,kGuDYH:`x1j6dyjg`,kkrTdU:`x1ypdohk`,$$css:!0},danger:{kMwMTN:`x12vcgws`,$$css:!0},error:{kogj98:`x1ghz6dp`,kZCmMZ:`xwn43p0`,kMwMTN:`x12vcgws`,kLWn49:`x1dbl2gt`,$$css:!0},warning:{kMwMTN:`x7zghnd`,$$css:!0}};async function C_(e,t){let n=await fetch(`/api/artifacts`,{cache:`no-store`}).catch(()=>null);return n?.ok?(await n.json().catch(()=>null))?.artifacts?.find(n=>n.type===e&&n.id===t)?.title??null:null}function w_(e,t,n,r){let i=e?.id?`${e.type}/${e.id}`:null,[a,o]=(0,G.useState)(null);if((0,G.useEffect)(()=>{if(!e?.id||!i)return;let t=!1;return C_(e.type,e.id).then(e=>{!t&&e&&o({key:i,text:e})}),()=>{t=!0}},[i]),!e||!i)return null;let s=rg(t?.artifacts[i]),c=s.published?s.visibility:`unpublished`;return{key:i,card:{type:e.type,title:a?.key===i?a.text:e.id,state:c,rootVisibility:n,url:s.published?s.url:null,uses:r.find(e=>e.artifact===i)?.uses??null},hidden:Hg(n,c)}}var T_=800;function E_(e,t){let[n,r]=(0,G.useState)(null),i=(0,G.useCallback)(async()=>{if(!t)return;let n=await Z(`GET`,`sync/${e}`);n.ok&&r(typeof n.json.upToDate==`boolean`?n.json.upToDate:null)},[e,t]);return(0,G.useEffect)(()=>{if(!t){r(null);return}i();let n,a=xo(t=>{t.artifact!==e||t.type!==`change`&&t.type!==`cloud-published`||(clearTimeout(n),n=setTimeout(()=>void i(),T_))});return()=>{clearTimeout(n),a()}},[e,t,i]),{upToDate:n,refresh:i}}function D_(e,t){let[n,r]=(0,G.useState)(null);return(0,G.useEffect)(()=>{if(!t){r(null);return}let n=!1,i=0,a=async()=>{let t=++i,a=await Z(`GET`,`publication/${e}`),o=a.ok&&eg(a.json);!n&&t===i&&o&&r(o)};a();let o=xo(t=>{t.artifact===e&&(t.type===`cloud-publication`&&(i++,r(t.publication)),(t.type===`change`||t.type===`cloud-published`)&&a())});return()=>{n=!0,o()}},[e,t]),n}var O_=e=>e.json.results??null;function k_(e){let[t,n]=(0,G.useState)([]),[r,i]=(0,G.useState)(null),[a,o]=(0,G.useState)([]),[s,c]=(0,G.useState)(null),[l,u]=(0,G.useState)(!1);return{refs:t,results:r,referrers:a,referrerResults:s,cloudUnavailable:l,load:(0,G.useCallback)(async()=>{let t=await Z(`GET`,`refs/${e}`);t.ok&&(Array.isArray(t.json.items)&&n(t.json.items),o(Array.isArray(t.json.referrers)?t.json.referrers:[]),u(t.json.cloudUnavailable===!0))},[e]),publishRefs:async(t,n,r,a)=>{if(!t){let t=await Z(`POST`,`publish/${e}`);if(!t.ok)return t}let o=await Z(`POST`,`publish-refs/${e}`,{visibility:n,refs:r,makePublic:a});return o.ok&&i(O_(o)),o},publishReferrers:async(t,n)=>{let r=await Z(`POST`,`publish-referrers/${e}`,{publish:t,makePublic:n});return r.ok&&c(O_(r)),r}}}var A_={private:`publish.hintPrivate`,public:`publish.hintPublic`};function j_({artifact:e,floating:t=!1,shell:n=!1}){let{t:r,i18n:i}=x(),{status:a,refresh:o,login:s,waitingForLogin:c}=hg(),l=Ce(),[u,d]=(0,G.useState)(!1),[f,p]=(0,G.useState)(!1),[m,h]=(0,G.useState)([]),[g,_]=(0,G.useState)(null),[v,y]=(0,G.useState)(null),[b,C]=(0,G.useState)(null),w=(0,G.useRef)(!1),T=a?.artifacts?.[e],E=rg(T),D=D_(e,!!a?.signedIn),O=D&&$h(D.phase),[k]=bg(),ee=E.url?yg(E.url,k):null,A=E_(e,!!a?.signedIn&&E.published),te=ig(A.upToDate,!!a?.autoPublish?.enabled&&T?.autoPublish!==!1),j=k_(e),{refs:ne,referrers:M}=j,N=async e=>{p(!0),h([]),_(null);let t=await e();if(`shareKey`in t.json&&y(t.ok?t.json.shareKey:null),t.status===401)s(t.json.loginUrl);else if(!t.ok){t.json.code===`plan_required`&&typeof t.json.upgradeUrl==`string`&&_(t.json.upgradeUrl);let e=Array.isArray(t.json.reasons)?t.json.reasons:[];h([Eg(t.json,r(`common.requestFailed`,{status:t.status})),...e])}await Promise.all([o(),A.refresh(),j.load()]),p(!1)},re=!E.published&&ne.some(e=>e.checked),ie=E.published?E.visibility:null,ae=w_(l.role===`primary`?l.other:null,a,ie,M),P=t=>N(()=>Z(`POST`,`visibility/${e}`,{visibility:t})),oe=(t={})=>N(()=>Z(`PUT`,`share-key/${e}`,t)),F=async t=>{if(d(t),t&&a?.signedIn&&j.load(),t&&a?.signedIn&&E.published){if(A.refresh(),E.access===`key`){let t=await Z(`GET`,`share-key/${e}`);t.ok&&y(t.json.shareKey)}(await Z(`GET`,`artifacts`)).ok&&await o()}},se=t=>{l_(e,t),s()};(0,G.useEffect)(()=>{if(!a?.signedIn||!a.login||w.current)return;let t=u_(e);if(!t)return;w.current=!0;let n=a.login,i=a.origin;(async()=>{d(!1),p(!0),h([]),_(null);try{if(t===`sync`){let a=await Z(`POST`,`auto-publish`,{scope:`global`,value:!0});if(!a.ok){C({intent:t,login:n,url:null,dashboardUrl:Lg(i),billingUrl:zg(i),error:Eg(a.json,r(`common.requestFailed`,{status:a.status}))});return}Z(`POST`,`publish/${e}`),await o(),C({intent:t,login:n,url:null,dashboardUrl:Lg(i),billingUrl:zg(i)});return}let a=await Z(`POST`,`publish/${e}`),s=await o();if(await Promise.all([A.refresh(),j.load()]),!a.ok){a.json.code===`plan_required`&&typeof a.json.upgradeUrl==`string`&&_(a.json.upgradeUrl);let e=Array.isArray(a.json.reasons)?a.json.reasons:[],o=Eg(a.json,r(`common.requestFailed`,{status:a.status}));h([o,...e]),C({intent:t,login:n,url:null,dashboardUrl:Lg(i),billingUrl:zg(i),error:o});return}let c=rg(s?.artifacts?.[e]).url??(typeof a.json.url==`string`?a.json.url:null),l=c?yg(c,k):null,u=!1;if(t===`share`&&l)try{await navigator.clipboard.writeText(l),u=!0}catch{u=!1}C({intent:t,login:n,url:l,copied:u,dashboardUrl:Lg(i),billingUrl:zg(i)})}finally{p(!1),w.current=!1}})()},[e,a?.signedIn,a?.login,a?.origin,k,o]);let ce=Ig(a?.origin,i.language),le=Lg(a?.origin),ue=a?a.signedIn?(0,W.jsxs)(`div`,{...S($.panel),children:[(0,W.jsxs)(`div`,{...S($.row),children:[(0,W.jsx)(`span`,{...S($.muted),children:r(`publish.signedInAs`,{login:a.login})}),(0,W.jsx)(`button`,{type:`button`,...S($.textButton),onClick:()=>void N(()=>Z(`POST`,`logout`)),children:r(`publish.signOut`)})]}),(0,W.jsx)(o_,{foot:r(A_[E.visibility]),saving:f,url:ee,visibility:E.visibility,beside:ae?{...ae.card,busy:f,onVisibility:e=>void N(()=>Z(`POST`,`visibility/${ae.key}`,{visibility:e})),onPublish:()=>void N(()=>Z(`POST`,`publish/${ae.key}`,{visibility:E.visibility}))}:null,cascade:{items:ne,rootVisibility:E.visibility,busy:f,results:j.results,includeRoot:!E.published,onPublish:(e,t)=>void N(()=>j.publishRefs(E.published,E.visibility,e,t))},profile:E.published?{shown:E.onProfile,path:a.login?`/u/${a.login}`:null,onChange:t=>void N(()=>Z(`POST`,`profile/${e}`,{shown:t}))}:null,referrers:{items:M,exclude:ae?.key,rootVisibility:ie,busy:f,cloudUnavailable:j.cloudUnavailable,results:j.referrerResults,onPublish:(e,t)=>void N(()=>j.publishReferrers(e,t))},shareKey:{active:E.access===`key`,value:v,onSelect:()=>void oe(),onExpiry:e=>void oe({expires:e}),onRegenerate:()=>void oe({regenerate:!0}),onRemove:()=>void N(()=>Z(`DELETE`,`share-key/${e}`))},status:(0,W.jsx)(Vg,{online:!0,busy:f,publication:D,published:E.published,publishedAt:T?.cloud?.publishedAt,onPublish:re?void 0:()=>void N(()=>Z(`POST`,`publish/${e}`))}),onVisibility:e=>void P(e)}),te?(0,W.jsx)(`span`,{...S(A.upToDate?$.muted:$.warning),children:r(`publish.${te}`)}):null,E.synced?null:(0,W.jsxs)(`div`,{...S($.row,$.warning),children:[(0,W.jsx)(`span`,{children:r(`publish.visibilityNotSynced`)}),(0,W.jsx)(Xe,{disabled:f,size:`small`,onClick:()=>void P(E.visibility),children:r(`publish.sync`)})]}),m.length>0?(0,W.jsx)(`ul`,{...S($.error),children:m.map(e=>(0,W.jsx)(`li`,{children:e},e))}):null,g?(0,W.jsx)(`a`,{"data-upgrade":``,href:g,rel:`noreferrer`,target:`_blank`,...S($.textButton),children:r(`share.seePlans`)}):null,E.published&&(!D||D.phase===`published`)?(0,W.jsx)(Xe,{loading:f||!!O,type:`primary`,onClick:()=>void N(()=>Z(`POST`,`publish/${e}`)),children:r(`publish.update`)}):null,E.published?(0,W.jsx)(`button`,{disabled:f,type:`button`,...S($.textButton,$.danger),onClick:()=>void N(()=>Z(`DELETE`,`publish/${e}`)),children:r(`publish.unpublish`)}):null,E.published&&a.autoPublish?.enabled?(0,W.jsx)(`span`,{...S($.muted),children:r(`publish.autoPublishNote`)}):null,(0,W.jsxs)(`div`,{...S($.row,$.muted),children:[(0,W.jsx)(`span`,{children:r(`settings.menuStatus`,{state:a.autoPublish?.enabled?r(`settings.on`):r(`settings.off`)})}),(0,W.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:10},children:[le?(0,W.jsxs)(`a`,{href:le,rel:`noopener noreferrer`,target:`_blank`,...S($.textButton),children:[r(`cloudEntry.openShort`),` `,(0,W.jsx)(Eo,{"aria-hidden":`true`,size:11})]}):null,(0,W.jsx)(`button`,{type:`button`,...S($.textButton),onClick:Ag,children:r(`publish.openSettings`)})]})]})]}):(0,W.jsx)(h_,{landingUrl:ce,origin:a.origin,waitingForLogin:c,onStartIntent:se}):(0,W.jsx)(`div`,{...S($.panel,$.muted),children:r(`publish.readingStatus`)});if(l.role===`beside`||it())return null;let de=n&&!!a&&!a.signedIn;return(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Yt,{content:ue,open:u,placement:`bottomRight`,popupProps:{"aria-label":r(`common.share`)},trigger:`click`,onOpenChange:e=>void F(e),children:(0,W.jsxs)(`button`,{"aria-label":`Share`,"data-cloud-shell-cta":de?``:void 0,type:`button`,...S($.trigger,t&&$.floating,de&&$.shellCta),children:[de?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,...S($.brandDot)}),r(`cloudEntry.shellCta`)]}):(0,W.jsxs)(W.Fragment,{children:[E.published&&E.visibility===`public`?(0,W.jsx)(lt,{size:14}):(0,W.jsx)(wo,{size:14}),E.published?r(`publish.published`):r(`common.share`)]}),D&&D.phase!==`published`?(0,W.jsx)(Vg,{compact:!0,publication:D,published:E.published}):null,A.upToDate===!1?(0,W.jsx)(`span`,{"aria-label":r(`publish.unpublishedChanges`),...S($.dot)}):null,ae?.hidden?(0,W.jsx)(`span`,{"aria-label":r(`beside.hidden`),"data-beside-dot":``,...S($.dot)}):null]})}),b?(0,W.jsx)(S_,{result:b,onDismiss:()=>C(null),onOpenSharePanel:()=>{C(null),F(!0)}}):null]})}var M_=e=>`/api/avatar/github/${e}`,N_=e=>{e&&window.open(e,`_blank`,`noopener,noreferrer`)};function P_({compact:e=!1,status:t,waitingForLogin:n,onSignIn:r,onSignOut:i}){let{t:a,i18n:o}=x();if(!t)return null;if(!t.signedIn||!t.login){let e=Ig(t.origin,o.language),i=(0,W.jsxs)(`div`,{"data-cloud-connect-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x1m258z3 xqfszdh xfifm61 xo2rkog`,children:[(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,W.jsxs)(`span`,{className:`x3nfvp2 x6s0dn4 x1j9xkj6 x4z9k3i x1s688f`,children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`x17z2i9w x17rw0jw x1kogg8i x6z2zk2 x1cge3fn xrvj5dj x1ku5rj1 x2lah0s`,children:(0,W.jsx)(Ko,{size:13})}),a(`cloudEntry.connectTitle`)]}),(0,W.jsx)(`span`,{className:`x1j6dyjg xddlp02`,children:a(`cloudEntry.freeStart`)})]}),(0,W.jsxs)(`div`,{className:`x78zum5 xdt5ytf x17d4w8g`,children:[(0,W.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,W.jsx)(Ae,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,W.jsxs)(`div`,{children:[(0,W.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitShareTitle`)}),(0,W.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitShareBody`)})]})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,W.jsx)(cs,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,W.jsxs)(`div`,{children:[(0,W.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitPhoneTitle`)}),(0,W.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitPhoneBody`)})]})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,W.jsx)(Do,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,W.jsxs)(`div`,{children:[(0,W.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitSyncTitle`)}),(0,W.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitSyncBody`)})]})]})]}),(0,W.jsx)(Xe,{className:{className:`xh8yej3 x90ne7k x3nfvp2 x6s0dn4 xl56j7k x1j9xkj6 xc342km xur7f20 x15az74h x12s0oaj xt9vybz xqfszdh x1ct8sxb xh88oxj x1ypdohk`}.className,icon:yo,loading:n,type:`primary`,onClick:r,children:a(n?`settings.waitingLogin`:`common.signInGithub`)}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1nejdyq x1j6dyjg xddlp02 xfrs9s4`,children:[(0,W.jsx)(wo,{"aria-hidden":`true`,size:11}),(0,W.jsx)(`span`,{children:a(`cloudEntry.privateByDefault`)})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,W.jsx)(d_,{origin:t.origin}),e?(0,W.jsxs)(`a`,{href:e,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[a(`cloudEntry.learnShort`),(0,W.jsx)(Eo,{"aria-hidden":`true`,size:11})]}):null]})]});return(0,W.jsx)(Yt,{content:i,placement:`bottomRight`,popupProps:{"aria-label":a(`cloudEntry.connectTitle`)},trigger:`click`,children:(0,W.jsxs)(`button`,{"data-cloud-connect-cta":``,type:`button`,className:`x3nfvp2 x6s0dn4 x1j9xkj6 x1gnnpzl xe2zdcy xpdmqnj xmkeg23 x1y0btm7 x1rqon0r x1e6avla x19ckca5 x1et1poy xs0jrwl xqfszdh xfifm61 xk50ysn xuxw1ft x1ypdohk xlee54d x784prv x9v5kkp xv8siiq x7s97pk`,children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct x1iug7pk x2lah0s`}),(0,W.jsx)(`span`,{children:a(`cloudEntry.connectCta`)}),(0,W.jsx)(`span`,{className:`x1pixwil xpilrb4 x1t7ytsu x13ft1s6 x1j6dyjg xo1l8bm xf9vgkq xy0uqqd`,children:a(`cloudEntry.connectHint`)})]})})}let s=t.login,c=Lg(t.origin);return(0,W.jsxs)(W.Fragment,{children:[!e&&c?(0,W.jsxs)(`a`,{"data-cloud-header-link":``,href:c,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1nejdyq x1fgtraw xdqyycr x1kogg8i xjbqb8w xj0l527 x1bo0w0s xytdrwj xfifm61 xk50ysn x1hl2dhg xuxw1ft x1gz44f`,children:[(0,W.jsx)(Ko,{"aria-hidden":`true`,size:13}),(0,W.jsx)(`span`,{children:`Cloud`}),(0,W.jsx)(Eo,{"aria-hidden":`true`,size:12})]}):null,(0,W.jsx)(Kt,{items:[{key:`status`,disabled:!0,label:`${s} · ${a(`settings.menuStatus`,{state:t.autoPublish?.enabled?a(`settings.on`):a(`settings.off`)})}`},{type:`divider`,key:`cloud-divider`},{key:`open-cloud`,icon:Ko,label:a(`cloudEntry.openCloud`),extra:`↗`,onClick:()=>N_(c)},{key:`public-profile`,icon:lt,label:a(`cloudEntry.publicProfile`),extra:`/u/${s} ↗`,onClick:()=>N_(Rg(t.origin,s))},{key:`plans`,icon:Xo,label:a(`cloudEntry.plans`),extra:`↗`,onClick:()=>N_(zg(t.origin))},{type:`divider`,key:`settings-divider`},{key:`settings`,icon:os,label:a(`settings.open`),onClick:Ag},{key:`sign-out`,icon:es,label:a(`settings.signOut`),onClick:()=>void i?.()}],children:(0,W.jsx)(`button`,{"aria-label":a(`settings.accountMenu`,{login:s}),type:`button`,className:`x78zum5 x1717udv xc342km x16rqkct xjbqb8w x1ypdohk x1hl8ikr`,children:(0,W.jsx)(Vd,{alt:``,avatar:M_(s),shape:`circle`,size:28,className:`xs625wh`})})})]})}var F_=(0,G.createContext)(!1),I_=(0,G.createContext)(null),L_=F_.Provider,R_=I_.Provider,z_=()=>typeof window<`u`&&window.parent!==window&&Te()&&!it();function B_(){return(0,G.useContext)(F_)||z_()}function V_(){return(0,G.useContext)(I_)}function H_({type:e,id:t,docHeader:n,children:r}){let{t:i}=x(),a=hg(),[o,s]=(0,G.useState)(t),[c,l]=(0,G.useState)(null),d=`${e}/${t}`;(0,G.useEffect)(()=>{s(t);let e=()=>{let e=document.title?.trim();e&&e!==`Ryugi`&&e!==`Artifacts · Artideck`&&s(e)};e();let n=document.querySelector(`title`);if(!n||typeof MutationObserver>`u`)return;let r=new MutationObserver(e);return r.observe(n,{childList:!0,characterData:!0,subtree:!0}),()=>r.disconnect()},[t,e]);let f=!!a.status?.signedIn&&!!a.status.login;return(0,W.jsxs)(`div`,{"data-local-shell":``,className:`xixxii4 x10a8y8t x78zum5 xdt5ytf x184qs1t`,children:[(0,W.jsxs)(`header`,{"data-local-shell-bar":``,className:`x1okw0bk x78zum5 x6s0dn4 x1qughib xou54vl x1otypdl xn3w4p2 xqin4a2 xwbbzrz xso031l x1q0q8m5 xtrfj0v x1rozbrz xo2rkog xqfszdh x1ct8sxb x1n2onr6 x1355qak`,children:[(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x883omv xeuugli x98rzlu`,children:[(0,W.jsx)(`a`,{"aria-label":i(`localShell.backToList`),href:`/`,className:`x3nfvp2 x6s0dn4 x2lah0s xo2rkog x12rs2w1 x1hl2dhg x1sxf85j`,children:(0,W.jsx)(Zh,{height:19})}),(0,W.jsxs)(`nav`,{"aria-label":i(`localShell.breadcrumb`),className:`x78zum5 x6s0dn4 x167g77z xeuugli x1ct8sxb xuxw1ft`,children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s`,children:`/`}),(0,W.jsx)(`span`,{className:`x1bo0w0s x2lah0s xt0psk2 xkaaz9w`,children:i(`type.${e}`)}),(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s xt0psk2 xkaaz9w`,children:`/`}),(0,W.jsx)(`span`,{title:o,className:`xeuugli xb3r6kr xlyipyv x1s688f xo2rkog`,children:o})]})]}),(0,W.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x167g77z x2lah0s`,children:[(0,W.jsx)(`div`,{ref:l,className:`xjp7ctv`}),u(e)&&n?.header?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(ke,{available:n.header.history,comments:n.header.comments,open:n.header.historyOpen,onComments:()=>n.history(`close`),onHistory:()=>n.history(`toggle`)}),(0,W.jsx)(To,{state:n.header.documentExport,onExport:n.exportPdf}),(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})]}):null,a.status&&!f?(0,W.jsxs)(`span`,{"data-local-only-badge":``,className:`x3nfvp2 xkaaz9w x6s0dn4 x1nejdyq x1qt5hsa xddlp02 xuxw1ft`,children:[(0,W.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct xvndefy x1y0btm7 xhgr6co x9f619 x2lah0s`}),i(`server.localOnly`)]}):null,(0,W.jsx)(j_,{shell:!0,artifact:d}),f?(0,W.jsx)(P_,{compact:!0,status:a.status,waitingForLogin:a.waitingForLogin,onSignIn:()=>void a.login(),onSignOut:async()=>{await Z(`POST`,`logout`),await a.refresh()}}):(0,W.jsx)(`button`,{"aria-label":i(`settings.title`),title:i(`settings.title`),type:`button`,className:`xrvj5dj x1ku5rj1 xgd8bvy x1fgtraw x1717udv xc342km x1kogg8i xjbqb8w xj0l527 x1bo0w0s xytdrwj x1ypdohk x2lah0s`,onClick:Ag,children:(0,W.jsx)(os,{"aria-hidden":`true`,size:14})})]})]}),(0,W.jsx)(`div`,{className:`x1n2onr6 x98rzlu x2lwn1j x78zum5 xdt5ytf xb3r6kr`,children:(0,W.jsx)(L_,{value:!0,children:(0,W.jsx)(R_,{value:c,children:r})})})]})}var U_=1e3,W_=`ryugi:embed:hello`,G_=`ryugi:embed:heartbeat`,K_=`ryugi:embed:painted`,q_=`ryugi:embed:position`,J_=`ryugi:embed:positioned`;function Y_({parentOrigin:e,onPosition:t,win:n=window}){let r=(t,r)=>n.parent.postMessage({type:t,...r},e),i=i=>{if(i.origin!==e||i.source!==n.parent)return;let a=i.data;a?.type===q_&&a.anchor&&t&&t(a.anchor).then(()=>r(J_))};n.addEventListener(`message`,i),r(W_,t?{position:!0}:void 0);let a=setInterval(()=>r(G_),U_),o=!1;return{painted(){o||(o=!0,r(K_))},close(){clearInterval(a),n.removeEventListener(`message`,i)}}}function X_(e=document,t=window,n){let r=e.documentElement.dataset.ryugiEmbedParent;return r?Y_({parentOrigin:r,onPosition:n,win:t}):null}var Z_=()=>new Promise(e=>requestAnimationFrame(()=>requestAnimationFrame(()=>e()))),Q_=e=>(Qe(e),Z_()),$_=(0,G.createContext)(()=>{});function ev(){let e=(0,G.useRef)(null),t=(0,G.useRef)(!1);return(0,G.useEffect)(()=>{let n=X_(document,window,Q_);return e.current=n,t.current&&n?.painted(),()=>{n?.close(),e.current=null}},[]),(0,G.useCallback)(()=>{t.current=!0,e.current?.painted()},[])}function tv(e){let t=(0,G.useContext)($_);(0,G.useEffect)(()=>{if(!e)return;let n=0,r=requestAnimationFrame(()=>{n=requestAnimationFrame(()=>{t(),tt()&&D({kind:`painted`})})});return()=>{cancelAnimationFrame(r),cancelAnimationFrame(n)}},[e,t])}function nv(e=window){try{let t=e.parent,n=new URLSearchParams(e.location.search).get(`at`);if(t!==e&&t.location.origin===e.location.origin&&/^\/whiteboard\/[^/]+\/?$/.test(t.location.pathname)&&t.location.pathname===n)return t}catch{}return e}var rv={artboard:{Layout:(0,G.lazy)(()=>r(async()=>{let{ArtboardLayout:e}=await import(`./ArtboardLayout-BoYjJscp.js`);return{ArtboardLayout:e}},__vite__mapDeps([20,1,21,22,4,23,16,2,3,5,6,7,17,13,18,24,25,26,27,28,29,30,11,12,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,19,51,52,53,54,55,10,56,57,58,59,60,61,15,8,9,62,63,64,65]),import.meta.url).then(({ArtboardLayout:e})=>({default:e})))},document:{Layout:(0,G.lazy)(()=>r(async()=>{let{DocumentLayout:e}=await import(`./DocumentLayout-Cz3hhXPR.js`);return{DocumentLayout:e}},__vite__mapDeps([66,1,4,5,2,3,6,7]),import.meta.url).then(({DocumentLayout:e})=>({default:e})))},html:{Layout:(0,G.lazy)(()=>r(async()=>{let{HtmlLayout:e}=await import(`./HtmlLayout-DBJCJRWj.js`);return{HtmlLayout:e}},__vite__mapDeps([67,1,21,22,4,23,16,2,3,5,6,7,17,13,18,68,27,47,69,56,57]),import.meta.url).then(({HtmlLayout:e})=>({default:e})))},whiteboard:{Layout:(0,G.lazy)(()=>r(async()=>{let{WhiteboardLayout:e}=await import(`./WhiteboardLayout-C9oGhpGn.js`);return{WhiteboardLayout:e}},__vite__mapDeps([70,1,22,4,23,16,2,3,5,6,7,17,13,18,71,72,73,27,19,42,74,37,75,76,52,32,53,38,77,46,78,10,31,11,12,49,50,39,40,47,58,79,63,80,44,45,81,82,83]),import.meta.url).then(({WhiteboardLayout:e})=>({default:e}))),embedIn:e=>(0,W.jsx)(_g,{pageWindow:nv(),children:e})},verify:{Layout:(0,G.lazy)(()=>r(async()=>{let{VerifyLayout:e}=await import(`./VerifyLayout-CaugP8cx.js`);return{VerifyLayout:e}},__vite__mapDeps([84,1,16,2,3,4,5,6,7,17,13,18,22,23,85,86,73,27,19,42,74,37,75,76,52,32,53,38,77,46,78,40,87,88,89,90,81,91,49,50,39,12,47,92,28,93,94,11,80,25,10,8,9,79,95,69,96,59,60,30,97,98]),import.meta.url).then(({VerifyLayout:e})=>({default:e})))},slides:{Layout:(0,G.lazy)(()=>r(async()=>{let{SlidesLayout:e}=await import(`./SlidesLayout-vo3ppRgW.js`);return{SlidesLayout:e}},__vite__mapDeps([99,1,21,22,4,23,16,2,3,5,6,7,17,13,18,100,95,72,69,56,57,30,68,27,47,10,49,50,39,40,12,35,36,37,38,41,42,43,76,81,88,45,46,55,77,32,63,9,15,19,101,53,54,91,28,102,8,58,94,103,104,26,105]),import.meta.url).then(({SlidesLayout:e})=>({default:e}))),bare:e=>new URLSearchParams(e).has(`live`)},report:{Layout:(0,G.lazy)(()=>r(async()=>{let{ReportLayout:e}=await import(`./ReportLayout-68jrSHuE.js`);return{ReportLayout:e}},__vite__mapDeps([106,1,21,22,4,23,16,2,3,5,6,7,17,13,18,68,27,47,69,56,57,30,81,10,36,37,49,50,39,40,12,62,90,54,92]),import.meta.url).then(({ReportLayout:e})=>({default:e})))},storyboard:{Layout:(0,G.lazy)(()=>r(async()=>{let{StoryboardLayout:e}=await import(`./StoryboardLayout-BqJngaoz.js`);return{StoryboardLayout:e}},__vite__mapDeps([107,1,4,21,22,23,16,2,3,5,6,7,17,13,18,108,30,69,68,27,47,56,57,39,40,109,54,94,26,49,50,12,81,93,103,15,28,41,42,45,46,36,37,75,77,32,33,34,43,53,61]),import.meta.url).then(({StoryboardLayout:e})=>({default:e})))}},iv=(0,G.lazy)(()=>r(async()=>{let{StoryboardRenderLayout:e}=await import(`./StoryboardRender-0aFMSadj.js`);return{StoryboardRenderLayout:e}},__vite__mapDeps([110,1,108,2,3,4,5,6,7,30,69,21,22,23,16,17,13,18]),import.meta.url).then(({StoryboardRenderLayout:e})=>({default:e}))),av=(0,G.lazy)(()=>r(async()=>{let{PreviewArtifactLayout:e}=await import(`./PreviewArtifactLayout-BIGmZXGw.js`);return{PreviewArtifactLayout:e}},__vite__mapDeps([111,1,4,16,2,3,5,6,7,17,13,18,23,103,15,39,40,27,10,68,47,48,55,49,50,12,101,45,46,11,43,53,112]),import.meta.url).then(({PreviewArtifactLayout:e})=>({default:e}))),ov=(0,G.lazy)(()=>r(async()=>{let{AutoPublishBar:e}=await import(`./auto-publish-89R-LJph.js`);return{AutoPublishBar:e}},__vite__mapDeps([113,1,114,13,3,4,5,2,6,7]),import.meta.url).then(({AutoPublishBar:e})=>({default:e}))),sv=(0,G.lazy)(()=>r(async()=>{let{SettingsDialog:e}=await import(`./settings-BZwlhQsp.js`);return{SettingsDialog:e}},__vite__mapDeps([115,1,16,2,3,4,5,6,7,17,13,18,32,55,14,79,116,47]),import.meta.url).then(({SettingsDialog:e})=>({default:e}))),cv=(0,G.lazy)(()=>r(async()=>{let{ArtifactList:e}=await import(`./ArtifactList-uj-q3W1q.js`);return{ArtifactList:e}},__vite__mapDeps([117,1,36,2,3,4,5,6,7,16,17,13,18,37,27,43,39,40,55,26,92,77,112,68,47,14,51,57,60,45,46,63,19,23]),import.meta.url).then(({ArtifactList:e})=>({default:e}))),lv=(0,G.lazy)(()=>Promise.all([r(()=>import(`./split-Clr7jYGP.js`),__vite__mapDeps([118,1,95,16,2,3,4,5,6,7,17,13,18,57,15,89,102,45,46,47,119,87,109,74,91,10,9,104,97,120,50,82]),import.meta.url),r(()=>import(`./local-split-host-BtzqQOET.js`).then(e=>e.n),__vite__mapDeps([100,1,95,16,2,3,4,5,6,7,17,13,18,23]),import.meta.url)]).then(([{SplitShell:e},{localSplitHost:t}])=>({default:n=>(0,W.jsx)(e,{...n,host:t})}))),uv=(0,G.lazy)(()=>r(async()=>{let{PreviewLayout:e}=await import(`./PreviewLayout-BmJ39T9v.js`).then(e=>e.n);return{PreviewLayout:e}},__vite__mapDeps([121,1,4,2,3,5,6,7,24,80]),import.meta.url).then(({PreviewLayout:e})=>({default:e}))),dv=(e,t)=>(0,W.jsxs)(W.Fragment,{children:[e,(0,W.jsx)(ov,{}),(0,W.jsx)(sv,{}),t&&(0,W.jsx)(Jh,{artifact:t})]}),fv=(e,t,n)=>dv((0,W.jsx)(H_,{id:t,type:e,children:n}),`${e}/${t}`);function pv({type:e,id:t,split:n}){let[r,i]=(0,G.useState)({type:e,id:t}),[a,o]=(0,G.useState)(null);(0,G.useEffect)(()=>{i({type:e,id:t})},[e,t]);let s=(0,G.useCallback)(e=>{i(t=>t.type===e.primary.type&&t.id===e.primary.id?t:e.primary)},[]),c=(0,G.useCallback)(e=>{o(e)},[]);return dv((0,W.jsx)(H_,{docHeader:a,id:r.id,type:r.type,children:(0,W.jsx)(lv,{fill:!0,hostPrimaryDocument:!0,id:t,split:n,type:e,onDocumentHeader:c,onPanes:s})}),`${r.type}/${r.id}`)}function mv({id:e,type:t}){let n=ev(),{Layout:r,embedIn:i}=rv[t],a=(0,W.jsx)(r,{id:e});return(0,W.jsxs)($_,{value:n,children:[Gh(location.search)&&(0,W.jsx)(Jh,{artifact:`${t}/${e}`}),i?i(a):a]})}function hv(){let[e]=Sh(),t=h(e);if((0,G.useEffect)(()=>{if(!document.documentElement.dataset.ryugiArtifactId)return;let e=document.querySelector(`link[rel="canonical"]`);if(!e)return;let t=new URL(location.href);t.pathname=y(t.pathname,new URL(e.href).pathname),t.href!==location.href&&history.replaceState(history.state,``,t)},[]),(0,G.useEffect)(()=>{window.scrollTo(0,0)},[e]),t.kind===`list`)return dv((0,W.jsx)(cv,{}));if(t.kind===`unknown`)return(0,W.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:`No artifact lives at this address.`});let n=document.documentElement.dataset.ryugiArtifactId??t.id;if(t.kind===`preview`)return(0,W.jsx)(uv,{id:n,type:t.type});if(t.kind===`dev-preview`)return dv((0,W.jsx)(av,{id:n}),`preview/${n}`);if(t.kind===`embed`)return(0,W.jsx)(mv,{id:n,type:t.type});if(t.kind===`render`)return(0,W.jsx)(iv,{id:n});if(g(t.type).standalone){let{Layout:e,bare:r}=rv[t.type],i=(0,W.jsx)(e,{id:n});return r?.(location.search)?dv(i,`${t.type}/${n}`):fv(t.type,n,i)}return(0,W.jsx)(pv,{id:n,split:Pe(t,location.search)?.split??null,type:t.type})}function gv(){return(0,W.jsx)(G.Suspense,{fallback:(0,W.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:(0,W.jsx)(Oh,{label:n(`common.loading`)})}),children:(0,W.jsx)(hv,{})})}Ie(),a(),document.documentElement.lang=o[s.language];function _v(){return c(),(0,W.jsx)(Hd,{features:bf,children:(0,W.jsxs)(Re,{enableCustomFonts:!1,motion:Jm,children:[(0,W.jsx)(gv,{}),(0,W.jsx)(oe,{}),(0,W.jsx)(on,{}),(0,W.jsx)(Ep,{})]})})}(0,Ym.createRoot)(document.getElementById(`root`)).render((0,W.jsx)(G.StrictMode,{children:(0,W.jsx)(_v,{})}));export{Vp as A,Jo as B,rg as C,Mh as D,Fh as E,Vd as F,cs as I,os as L,gp as M,pp as N,jh as O,wf as P,is as R,hg as S,zh as T,Wo as V,Ag as _,M_ as a,bg as b,x_ as c,d_ as d,zg as f,jg as g,Rg as h,P_ as i,Y as j,Oh as k,y_ as l,Ig as m,B_ as n,j_ as o,Lg as p,V_ as r,__ as s,tv as t,v_ as u,Pg as v,Zh as w,Z as x,yg as y,ns as z};