ryugi-artifacts 1.108.6 → 1.108.7

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 (115) hide show
  1. package/dist/cli.cjs +8 -8
  2. package/dist/document-engine.cjs +1 -1
  3. package/dist/runtime/Figtree-OFL.txt +93 -0
  4. package/dist/runtime/ryugi-mockup.js +270 -2
  5. package/dist/runtime/ryugi-preview-bridge.js +2 -2
  6. package/dist/runtime/ryugi-ui.js +1 -1
  7. package/dist/server.cjs +93 -93
  8. package/dist/viewer/{AgentDock-BMyCZfOA.js → AgentDock-fdzdI0YU.js} +1 -1
  9. package/dist/viewer/{ArtboardLayout-Ca63S-ht.js → ArtboardLayout-CyP7z5iV.js} +1 -1
  10. package/dist/viewer/{ArtifactList-CyHqaLMU.js → ArtifactList-D1Cv2wcz.js} +1 -1
  11. package/dist/viewer/{ArtifactModal-CNcJ9SwG.js → ArtifactModal-BRPuHjh3.js} +1 -1
  12. package/dist/viewer/{BottomSheet-CPpAPNxv.js → BottomSheet-DksTxPPS.js} +1 -1
  13. package/dist/viewer/{Canvas-CZAIguUl.js → Canvas-DA9wKktu.js} +1 -1
  14. package/dist/viewer/{CommentPopover-SiWZ0XbH.js → CommentPopover-Bz3qXsBS.js} +1 -1
  15. package/dist/viewer/{DocumentExportMenu-D3KMkrvj.js → DocumentExportMenu-Cb03PJdE.js} +1 -1
  16. package/dist/viewer/DocumentLayout-16zcY3cg.js +2 -0
  17. package/dist/viewer/DocumentPage-B__O7sY3.js +3 -0
  18. package/dist/viewer/{DraggablePanel-GsMby8P2.js → DraggablePanel-BlNQ_JOj.js} +1 -1
  19. package/dist/viewer/{DropdownMenu-BXvqn_bX.js → DropdownMenu-DhVZ3e22.js} +1 -1
  20. package/dist/viewer/Figtree-OFL.txt +93 -0
  21. package/dist/viewer/{GroupVerdict-DWVpUZS_.js → GroupVerdict-DkOR7Neo.js} +1 -1
  22. package/dist/viewer/{HtmlLayout-DlU3MyPC.js → HtmlLayout-BQS68lEe.js} +1 -1
  23. package/dist/viewer/{Input-vV0jo5B6.js → Input-YumXWTse.js} +1 -1
  24. package/dist/viewer/{MenuSubmenuTrigger-BaYw4HuY.js → MenuSubmenuTrigger-DZ2Nb6Hm.js} +1 -1
  25. package/dist/viewer/{PhoneArtboardBar-DWHrTBZF.js → PhoneArtboardBar-CZKL18gK.js} +1 -1
  26. package/dist/viewer/{Popover-BRvZS1gZ.js → Popover-i0m3nwq7.js} +1 -1
  27. package/dist/viewer/{PreviewArtifactLayout-neL_d_3n.js → PreviewArtifactLayout-B4SZfLvw.js} +1 -1
  28. package/dist/viewer/PreviewLayout-DiIQthoy.js +2 -0
  29. package/dist/viewer/{ReportLayout-BLVLfLGU.js → ReportLayout-DPnqWYPZ.js} +1 -1
  30. package/dist/viewer/{RyugiMark-d0ZfdfP2.js → RyugiMark-Ch2tF00h.js} +1 -1
  31. package/dist/viewer/{Segmented-BIBgIkNi.js → Segmented-BV_iofkK.js} +1 -1
  32. package/dist/viewer/{SelectScrollUpArrow-DNQWHWMc.js → SelectScrollUpArrow-BNSyHMPX.js} +1 -1
  33. package/dist/viewer/{SlidesLayout-MGWpipwc.js → SlidesLayout-CSeSindR.js} +3 -3
  34. package/dist/viewer/{SnapshotDocument-DX9wLXWv.js → SnapshotDocument-TIzAsI0l.js} +1 -1
  35. package/dist/viewer/{SplitFrame-CiqjUPs6.js → SplitFrame-C3Mr0Ehv.js} +1 -1
  36. package/dist/viewer/{StoryboardLayout-BkntJIHV.js → StoryboardLayout-DZVJbnzc.js} +1 -1
  37. package/dist/viewer/{StoryboardRender-BniWnBGv.js → StoryboardRender-DORxY44d.js} +1 -1
  38. package/dist/viewer/{ThreadView-WZruOpTE.js → ThreadView-CbKzFwUf.js} +1 -1
  39. package/dist/viewer/{Tooltip-DKnMl1yQ.js → Tooltip-81DgA1Zr.js} +1 -1
  40. package/dist/viewer/{VerifyLayout-Bjh7Ddzn.js → VerifyLayout--deiRi4o.js} +1 -1
  41. package/dist/viewer/{VirtualizedEditor-uWe43zaI-DIyWJhFX.js → VirtualizedEditor-uWe43zaI-1EQ0fdB8.js} +1 -1
  42. package/dist/viewer/{VirtualizedRenderer-C_d95FXi-BkojOMeR.js → VirtualizedRenderer-C_d95FXi-CixG8E4F.js} +1 -1
  43. package/dist/viewer/{WarningsBadge-B0H-6XNv.js → WarningsBadge-fEXkyk3t.js} +1 -1
  44. package/dist/viewer/{WhiteboardEditor-cZ32fLqJ-DfASNG0e.js → WhiteboardEditor-cZ32fLqJ-BRt-wSEn.js} +2 -2
  45. package/dist/viewer/WhiteboardLayout-qGm-CExy.js +4 -0
  46. package/dist/viewer/{WritingCursor-B1KstzsM.js → WritingCursor-OdCSWg_M.js} +1 -1
  47. package/dist/viewer/{agentLook-DAbDap_r.js → agentLook-EhrjbD1n.js} +1 -1
  48. package/dist/viewer/{artifact-list-Dk7B04aS.js → artifact-list-D22lTyyh.js} +1 -1
  49. package/dist/viewer/{auto-publish-D0gnAgNH.js → auto-publish-BXmqx8BX.js} +1 -1
  50. package/dist/viewer/{channel-W8z1JRUp.js → channel-CaUFZV2H.js} +3 -3
  51. package/dist/viewer/{crop-encode-jcaJuFwz.js → crop-encode-Udgh8S7r.js} +1 -1
  52. package/dist/viewer/{dist-8GuhHKSd.js → dist-0JlH-iFk.js} +1 -1
  53. package/dist/viewer/{dist-DKWGY7vW.js → dist-B-RrlmaY.js} +1 -1
  54. package/dist/viewer/{dist-e32bsEFO.js → dist-BMJWStKC.js} +1 -1
  55. package/dist/viewer/{dist-hskNTNrk.js → dist-BNiHzkc8.js} +1 -1
  56. package/dist/viewer/{dist-D5w5f0nx.js → dist-C0Fbwkds.js} +1 -1
  57. package/dist/viewer/{dist-DdWP5O5Z.js → dist-C4fPBi1f.js} +1 -1
  58. package/dist/viewer/{dist-BLDdWa7l.js → dist-C81vCo2L.js} +1 -1
  59. package/dist/viewer/dist-CY11yEtD.js +1 -0
  60. package/dist/viewer/{dist-DzgE9d65.js → dist-CjVeWopx.js} +1 -1
  61. package/dist/viewer/{dist-BKKpgaMc.js → dist-CuWYFfBf.js} +1 -1
  62. package/dist/viewer/{dist-CilrySXL.js → dist-DBnvEq5g.js} +1 -1
  63. package/dist/viewer/{dist-IX2iT14j.js → dist-DD00JDtU.js} +1 -1
  64. package/dist/viewer/{dist-B6IVYls_.js → dist-DKWARfq1.js} +1 -1
  65. package/dist/viewer/{dist-BTzyPMeC.js → dist-DRUJxMS6.js} +1 -1
  66. package/dist/viewer/{dist-C6DCB_Rj.js → dist-DRmbQ1f0.js} +1 -1
  67. package/dist/viewer/{dist-EFdcYRKe.js → dist-DurHsNXj.js} +1 -1
  68. package/dist/viewer/{dist-DE-DH2i7.js → dist-DzmIJXNR.js} +1 -1
  69. package/dist/viewer/{dist-CqeeTfim.js → dist-G4Vj4mFX.js} +1 -1
  70. package/dist/viewer/{dist-DNO7AZoy.js → dist-R6N8uqUg.js} +1 -1
  71. package/dist/viewer/{dist-BC8nvFq2.js → dist-i-_vhfnL.js} +1 -1
  72. package/dist/viewer/{dist-Bpgppm6o.js → dist-kzNj8Wks.js} +1 -1
  73. package/dist/viewer/{dist-B2aqeAk-.js → dist-o-mpdm3Q.js} +1 -1
  74. package/dist/viewer/{dist-w08ese3i.js → dist-rs8SY6NP.js} +1 -1
  75. package/dist/viewer/{dist-BhE_JiAo.js → dist-vjczWTJX.js} +1 -1
  76. package/dist/viewer/{editor-IGV7cqIf.js → editor-BabkJ7hH.js} +6 -6
  77. package/dist/viewer/figtree-latin-ext-wght-normal-DCwSJGxG.woff2 +0 -0
  78. package/dist/viewer/figtree-latin-wght-normal-D_ZTVpCC.woff2 +0 -0
  79. package/dist/viewer/{fit-CwTJJcvD.js → fit-BJ0VxRML.js} +1 -1
  80. package/dist/viewer/{icons-Dwk8RW6i.js → icons-8mizjIXE.js} +1 -1
  81. package/dist/viewer/{imperative-9zI7cd1I.js → imperative-iclc26pT.js} +1 -1
  82. package/dist/viewer/index.css +1 -1
  83. package/dist/viewer/index.html +12 -12
  84. package/dist/viewer/index.js +2 -2
  85. package/dist/viewer/index2.css +1 -1
  86. package/dist/viewer/{local-BIV9Bn_B.js → local-DzHVL3fo.js} +1 -1
  87. package/dist/viewer/{local-split-host-DJJKo1Vj.js → local-split-host-DaeACaX5.js} +1 -1
  88. package/dist/viewer/plugin-_bGVeqI0-BkU-g6bb.js +2 -0
  89. package/dist/viewer/preview.html +3 -3
  90. package/dist/viewer/preview.js +1 -1
  91. package/dist/viewer/{printDocument-BbvYpCaV.js → printDocument-Bh1qUAf9.js} +1 -1
  92. package/dist/viewer/{ref-DcFpXWwa.js → ref-JbqCEGXp.js} +1 -1
  93. package/dist/viewer/{route-CAQRGuux.js → route-DdpUUY_w.js} +5 -5
  94. package/dist/viewer/{route-messages-AShIvXR0.js → route-messages-BMv2jmvl.js} +1 -1
  95. package/dist/viewer/{settings-CxJUVRn8.js → settings-wKTRexHi.js} +1 -1
  96. package/dist/viewer/{snap-Bp7A7-zR.js → snap-1DJNMR4r.js} +1 -1
  97. package/dist/viewer/{split-CeIplvJa.js → split-BJA_5Rtf.js} +2 -2
  98. package/dist/viewer/{stable-DVc3NRmV.js → stable-CZy_447C.js} +1 -1
  99. package/dist/viewer/{styles-BBTLo6nS.js → styles-BHI9FTnz.js} +1 -1
  100. package/dist/viewer/{transport-CazJfalj.js → transport-Djlo7-HU.js} +1 -1
  101. package/dist/viewer/{url-BS6kqcve.js → url-B_fuREEU.js} +1 -1
  102. package/dist/viewer/{useArtifactFeed-CymUjnz1.js → useArtifactFeed-B9RfhN8_.js} +1 -1
  103. package/dist/viewer/{useArtifactSocket-BOU81P_2.js → useArtifactSocket-ns9zjgVa.js} +1 -1
  104. package/dist/viewer/{useLayerZIndex-D5QVXpVc.js → useLayerZIndex-VAxAVO-V.js} +1 -1
  105. package/dist/viewer/{useStoryboardData-BbPOAS-Z.js → useStoryboardData-DCPDhUMO.js} +1 -1
  106. package/dist/viewer/{view-BatCe1Ci.js → view-DLrABahQ.js} +1 -1
  107. package/dist/viewer/{viewport-CFJHn_Y6-DuJwG-4n.js → viewport-CFJHn_Y6-B0Ka3uWP.js} +1 -1
  108. package/package.json +1 -1
  109. package/dist/viewer/DocumentLayout-Vo9s9zeJ.js +0 -2
  110. package/dist/viewer/DocumentPage-CIvaYNgp.js +0 -3
  111. package/dist/viewer/Goeist-DFcbbrZE.woff2 +0 -0
  112. package/dist/viewer/PreviewLayout-BuviWNGi.js +0 -2
  113. package/dist/viewer/WhiteboardLayout-CwmEBIBu.js +0 -4
  114. package/dist/viewer/dist-Cg7E0M7K.js +0 -1
  115. package/dist/viewer/plugin-_bGVeqI0-_v5JtKHd.js +0 -2
@@ -1,2 +1,2 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./AgentDock-BMyCZfOA.js","./rolldown-runtime-XKyaHtl9.js","./route-CAQRGuux.js","./bem-vbke-3KC.js","./react-DlmbjZJV.js","./jsx-runtime-LKYXHABd.js","./types-DAs-xbqr.js","./index2.css","./BottomSheet-CPpAPNxv.js","./motion-Cy65kd7X.js","./useMedia-CFebB4XU.js","./agentLook-DAbDap_r.js","./icons-Dwk8RW6i.js","./MotionConfigContext-HC2vqcJO.js","./arrow-up-right-0KreI6kY.js","./chevron-left-C5itNrp5.js","./url-BS6kqcve.js","./useLayerZIndex-D5QVXpVc.js","./chevron-right-xNdXLJg6.js","./ArtboardLayout-Ca63S-ht.js","./useArtifactFeed-CymUjnz1.js","./transport-CazJfalj.js","./useArtifactSocket-BOU81P_2.js","./imperative-9zI7cd1I.js","./Popover-BRvZS1gZ.js","./view-BatCe1Ci.js","./rounds-BLj-tfMG.js","./sliders-horizontal-CuS3-UwA.js","./Canvas-CZAIguUl.js","./cssVar.stylex-CGbpAC1Y.js","./WritingCursor-B1KstzsM.js","./maximize-2-Bc0lXBg6.js","./PlaybackIcon-D-vfZnSv.js","./elements-CmGVWYag.js","./snap-Bp7A7-zR.js","./local-BIV9Bn_B.js","./SelectScrollUpArrow-DNQWHWMc.js","./undo-2-B-JiyKIl.js","./stable-DVc3NRmV.js","./Tooltip-DKnMl1yQ.js","./styles-BBTLo6nS.js","./stringifyLocale-D0juOOnH.js","./Input-vV0jo5B6.js","./PhoneArtboardBar-DWHrTBZF.js","./DropdownMenu-BXvqn_bX.js","./MenuSubmenuTrigger-BaYw4HuY.js","./index5.css","./crop-encode-jcaJuFwz.js","./ThreadView-WZruOpTE.js","./comments-DUAz1Q9X.js","./folder-BViSPo7g.js","./ruler-CYb0HZGT.js","./mouse-pointer-2-B-OF_fcG.js","./play-6FAfeM1L.js","./Segmented-BIBgIkNi.js","./useTypeFavicon-yXOsFZBx.js","./type-icons-CxYXZlMj.js","./CommentPopover-SiWZ0XbH.js","./GroupVerdict-DWVpUZS_.js","./artifact-list-Dk7B04aS.js","./film-A6SU1RGC.js","./code-xml-c9QCqmhY.js","./store-D3ROW536.js","./selection-BWCQd_Fn.js","./ArtboardLayout-DLyi-yDq.css","./DocumentLayout-Vo9s9zeJ.js","./HtmlLayout-DlU3MyPC.js","./WarningsBadge-B0H-6XNv.js","./useSandboxFrame-CJmSnwgG.js","./WhiteboardLayout-CwmEBIBu.js","./shims-s-YVfIlz.js","./WhiteboardEditor-cZ32fLqJ-DfASNG0e.js","./code-DnmQyGiF.js","./zoom-out-DsmGFv1v.js","./text-align-start-CRhecbJR.js","./plus-DZJ2BVkK.js","./index3.css","./pages-DWkRbog-.js","./preference-oNdcNeml.js","./DotGrid-DKKr_PyM.js","./message-square-Yl8PoPy_.js","./backlinks-C_k8-LL2.js","./WhiteboardLayout-SRFXrlmW.css","./VerifyLayout-Bjh7Ddzn.js","./useAssetBase-4Ut9QhBI.js","./editor-IGV7cqIf.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-DcFpXWwa.js","./index4.css","./fit-CwTJJcvD.js","./VerifyLayout-B9e4RHAZ.css","./SlidesLayout-MGWpipwc.js","./local-split-host-DJJKo1Vj.js","./monitor-DRrnx_H5.js","./DocumentExportMenu-D3KMkrvj.js","./DraggablePanel-GsMby8P2.js","./embed-src-CmyqZplg.js","./SlidesLayout-Bjds2UXz.css","./ReportLayout-BLVLfLGU.js","./StoryboardLayout-BkntJIHV.js","./useStoryboardData-BbPOAS-Z.js","./clapperboard-BfpJ7tpa.js","./StoryboardRender-BniWnBGv.js","./PreviewArtifactLayout-neL_d_3n.js","./RyugiMark-d0ZfdfP2.js","./auto-publish-D0gnAgNH.js","./cloud-upload-D8TpApTr.js","./settings-CxJUVRn8.js","./ArtifactList-CyHqaLMU.js","./split-CeIplvJa.js","./SplitFrame-CiqjUPs6.js","./route-messages-AShIvXR0.js","./split-C1umM5Fz.css","./PreviewLayout-BuviWNGi.js"])))=>i.map(i=>d[i]);
2
- import{n as e,r as t}from"./rolldown-runtime-XKyaHtl9.js";import{C as n,S as r,_ as i,a,b as o,d as s,f as c,g as l,h as u,m as d,n as f,o as p,s as m,t as h,v as g,w as _,x as v,y}from"./route-CAQRGuux.js";/* empty css */import{$t as b,Ar as x,At as S,Bt as C,C as w,Cr as T,Ct as E,Dr as D,Dt as O,Er as k,Et as ee,Ft as A,Gt as te,Ht as j,It as ne,J as re,Jt as M,Kt as ie,Lt as ae,Mn as N,Mr as oe,Mt as se,N as ce,Nr as le,Nt as P,Ot as ue,Pt as de,Qt as fe,St as pe,Tn as me,Tr as he,Tt as ge,Ut as F,Vt as _e,Wt as ve,Xt as ye,Y as be,Zt as xe,_ as Se,_r as Ce,_t as we,an as Te,at as I,b as Ee,br as De,bt as Oe,cr as L,dr as ke,dt as Ae,ft as je,g as Me,gr as Ne,gt as Pe,hr as Fe,ht as Ie,i as Le,it as R,j as Re,jn as ze,jr as Be,jt as Ve,kn as He,kt as Ue,mr as We,mt as Ge,nn as Ke,ot as qe,pt as Je,qt as Ye,rt as Xe,u as Ze,ur as Qe,ut as $e,v as et,vt as tt,w as nt,wr as rt,wt as it,xt as at,yr as ot,yt as st,zt as ct}from"./url-BS6kqcve.js";import{$r as lt,C as ut,Dn as dt,En as ft,Fn as pt,Ft as mt,Gr as ht,Hr as gt,It as _t,Kr as vt,Pn as yt,Sn as bt,Tn as xt,Vr as St,Xr as Ct,Yr as wt,Zr as Tt,ii as z,kr as Et,oi as Dt,or as Ot,qn as kt,ri as B,rr as At,t as jt,zr as Mt}from"./useLayerZIndex-D5QVXpVc.js";import{n as Nt,r as V,t as Pt}from"./bem-vbke-3KC.js";import{t as Ft}from"./react-DlmbjZJV.js";import{a as It,i as Lt,l as Rt,n as zt,o as Bt,r as Vt,s as Ht,t as Ut}from"./DropdownMenu-BXvqn_bX.js";import{A as Wt,f as Gt,t as Kt}from"./Popover-BRvZS1gZ.js";import{t as qt}from"./jsx-runtime-LKYXHABd.js";import{a as Jt,i as Yt,n as Xt,o as Zt,r as Qt,s as $t,t as en}from"./store-D3ROW536.js";import{n as tn,t as nn}from"./imperative-9zI7cd1I.js";import{$ as rn,B as an,Ct as on,Dt as sn,Et as cn,G as ln,I as un,J as dn,M as fn,N as pn,P as mn,St as hn,Tt as gn,U as _n,W as H,_t as vn,a as yn,bt as bn,c as xn,ct as Sn,d as Cn,dt as wn,et as Tn,gt as En,h as Dn,ht as On,i as kn,l as An,m as jn,mt as Mn,o as Nn,p as Pn,r as Fn,s as In,st as Ln,t as Rn,u as zn,ut as Bn,wt as Vn,xt as Hn}from"./MotionConfigContext-HC2vqcJO.js";import{$ as Un,$n as Wn,$t as Gn,A as Kn,An as qn,At as Jn,B as Yn,Bn as Xn,Bt as Zn,C as Qn,Cn as $n,Cr as er,Ct as tr,D as nr,Dn as rr,Dt as ir,E as ar,En as or,Et as sr,F as cr,Fn as lr,Ft as ur,G as dr,Gn as fr,Gt as pr,H as mr,Hn as hr,Ht as gr,I as _r,In as vr,It as yr,J as br,Jn as xr,Jt as Sr,K as Cr,Kn as wr,Kt as Tr,L as Er,Ln as Dr,Lt as Or,M as kr,Mn as Ar,Mt as jr,N as Mr,Nn as Nr,Nt as Pr,O as Fr,On as Ir,Ot as Lr,P as Rr,Pn as zr,Pt as Br,Q as Vr,Qn as Hr,Qt as Ur,R as Wr,Rn as Gr,Rt as Kr,S as qr,Sn as Jr,Sr as Yr,St as Xr,T as Zr,Tn as Qr,Tr as $r,Tt as ei,U as ti,Un as ni,Ut as ri,V as ii,Vn as ai,Vt as oi,W as si,Wn as ci,Wt as li,X as ui,Xn as di,Xt as fi,Y as pi,Yn as mi,Yt as hi,Z as gi,Zn as _i,Zt as vi,_ as yi,_n as bi,_r as xi,_t as Si,a as Ci,an as wi,ar as Ti,at as Ei,b as Di,bn as Oi,br as U,bt as ki,c as Ai,cn as ji,cr as Mi,ct as Ni,d as Pi,dn as Fi,dr as Ii,dt as Li,en as Ri,er as zi,et as Bi,f as Vi,fn as Hi,fr as Ui,ft as Wi,g as Gi,gn as Ki,gr as qi,gt as Ji,h as Yi,hn as Xi,hr as Zi,ht as Qi,i as $i,in as ea,ir as ta,it as na,j as ra,jn as ia,jt as aa,k as oa,kn as sa,kt as ca,l as la,ln as ua,lr as da,lt as fa,m as pa,mn as ma,mr as ha,mt as ga,n as _a,nn as va,nr as ya,nt as ba,o as xa,on as Sa,or as Ca,ot as wa,p as Ta,pn as Ea,pr as Da,pt as Oa,q as ka,qn as Aa,qt as ja,r as Ma,rn as Na,rr as Pa,rt as Fa,s as Ia,sn as La,sr as Ra,st as za,t as Ba,tn as Va,tr as Ha,tt as Ua,u as Wa,un as Ga,ur as Ka,ut as qa,v as Ja,vn as Ya,vr as Xa,vt as Za,w as Qa,wn as $a,wr as eo,wt as to,x as no,xn as ro,xr as io,xt as ao,y as oo,yn as so,yr as co,yt as lo,z as uo,zn as fo,zt as po}from"./elements-CmGVWYag.js";import{m as mo,p as ho,t as go}from"./local-BIV9Bn_B.js";import{r as _o,t as vo}from"./useArtifactSocket-BOU81P_2.js";import{t as yo}from"./DocumentExportMenu-D3KMkrvj.js";import{t as bo}from"./arrow-up-right-0KreI6kY.js";import{F as xo,P as So}from"./SelectScrollUpArrow-DNQWHWMc.js";import{t as Co}from"./cloud-upload-D8TpApTr.js";import{t as wo}from"./Tooltip-DKnMl1yQ.js";import{S as To,a as Eo,c as Do,d as Oo,f as ko,h as Ao,i as jo,l as Mo,m as No,n as Po,s as Fo,t as Io,u as Lo,x as Ro}from"./MenuSubmenuTrigger-BaYw4HuY.js";var zo={name:`clock-3`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6h4`,key:`135r8i`}]]};zo.node;var Bo=sn(zo),Vo={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`}]]};Vo.node;var Ho=sn(Vo),Uo={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`]};Uo.node;var Wo=sn(Uo),Go={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`}]]};Go.node;var Ko=sn(Go),qo={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`}]]};qo.node;var Jo=sn(qo),Yo={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`}]]};Yo.node;var Xo=sn(Yo),Zo={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`}]]};Zo.node;var Qo=sn(Zo),$o={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`}]]};$o.node;var es=sn($o),ts={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`}]]};ts.node;var ns=sn(ts),rs={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`}]]};rs.node;var is=sn(rs);function as(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 os(e,t,n){return $r(e.getProps(),t,n,e)}var ss=(e,t)=>t===`exit`?e.presenceContext?.custom:void 0,cs=e=>Array.isArray(e);function ls(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,jn(n))}function us(e){return cs(e)?e[e.length-1]||0:e}function ds(e,t){let{transitionEnd:n={},transition:r={},...i}=os(e,t)||{};i={...i,...n};for(let t in i)ls(e,t,us(i[t]))}function fs(e){return!!(Cn(e)&&e.add)}function ps(e,t){let n=e.getValue(`willChange`);if(fs(n))return n.add(t);if(!n&&bn.WillChange){let n=new bn.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function ms(e){return e.props[eo]}var hs=typeof window<`u`;function gs({protectedKeys:e,needsAnimating:t},n){let r=n in e&&!t[n];return t[n]=!1,r}function _s(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a,transitionEnd:o,...s}=t,c=e.getDefaultTransition();a=a?ae(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&&gs(f,t))continue;let o={delay:n,...ne(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(hs&&window.MotionHandoffAnimation){let n=ms(e);if(n){let e=window.MotionHandoffAnimation(n,t,H);e!==null&&(o.startTime=e,p=!0)}}ps(e,t);let m=l??e.shouldReduceMotion;r.run(A(t,r,i,m&&P.has(t)?{type:!1}:o,e,p));let h=r.animation;h&&d.push(h)}if(o){let t=()=>H.update(()=>{o&&ds(e,o)});d.length?Promise.all(d).then(t):t()}return d}function vs(e,t,n={}){let r=os(e,t,ss(e,n.type)),i=n.transitionOverride||(r?.transition??(e.getDefaultTransition()||{})),a=()=>Promise.all(r?_s(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(vs(e,t,{...n,delay:r+(typeof o==`function`?0:o)+as(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 ys(e,t,n={}){return e.notify(`AnimationStart`,t),(Array.isArray(t)?Promise.all(t.map(t=>vs(e,t,n))):typeof t==`string`?vs(e,t,n):Promise.all(_s(e,os(e,t,n.custom),n))).then(()=>{e.notify(`AnimationComplete`,t)})}var bs=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomRightRadius`,`borderBottomLeftRadius`],xs={value:null,addProjectionMetrics:null,countProjection:void 0};function Ss(e,t){let n=Bn.now();e=Ue(e);let r=({timestamp:i})=>{let a=i-n;a>=t&&(_n(r),e(a-t))};return H.setup(r,!0),ue(()=>_n(r))}function Cs(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function ws(e){return S(e)&&e.tagName===`svg`}var Ts=e=>typeof e==`number`?e:parseFloat(e),Es=bs.length,Ds=e=>typeof e==`number`||Tn.test(e);function Os(e,t,n,r,i,a){i?(e.opacity=F(0,n.opacity??1,As(r)),e.opacityExit=F(t.opacity??1,0,js(r))):a&&(e.opacity=F(t.opacity??1,n.opacity??1,r));for(let i=0;i<Es;i++){let a=bs[i],o=ks(t,a),s=ks(n,a);(o!==void 0||s!==void 0)&&(o||=0,s||=0,o===0||s===0||Ds(o)===Ds(s)?(e[a]=Math.max(F(Ts(o),Ts(s),r),0),(rn.test(s)||rn.test(o))&&(e[a]+=`%`)):e[a]=s)}for(let i=0;i<st.length;i++){let a=st[i];(t[a]||n[a])&&(e[a]=F(t[a]||0,n[a]||0,r))}}function ks(e,t){return e[t]===void 0?e.borderRadius:e[t]}var As=Ms(0,.5,ve),js=Ms(.5,.95,vn);function Ms(e,t,n){return r=>r<e?0:r>t?1:n(te(e,t,r))}var Ns=(e,t,{x:n,y:r})=>{let i=e*e+t*t;return i<1?0:-1e3*(n*e+r*t)/i},Ps=(e,t=300)=>{let n=Hn(.25,2,t/300),{stiffness:r,damping:i}=C({...e,duration:e.duration&&On(e.duration)});return{...e,stiffness:r,damping:i*Math.sqrt(n),mass:n}};function Fs(e,t){e.min=t.min,e.max=t.max}function Is(e,t){Fs(e.x,t.x),Fs(e.y,t.y)}function Ls(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var Rs=.9999,zs=1.0001,Bs=-.01,Vs=.01;function W(e){return e.max-e.min}function Hs(e,t,n){return Math.abs(e-t)<=n}function Us(e,t,n,r=.5){e.origin=r,e.originPoint=F(t.min,t.max,e.origin),e.scale=W(n)/W(t),e.translate=F(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Rs&&e.scale<=zs||isNaN(e.scale))&&(e.scale=1),(e.translate>=Bs&&e.translate<=Vs||isNaN(e.translate))&&(e.translate=0)}function Ws(e,t,n,r){Us(e.x,t.x,n.x,r?.originX),Us(e.y,t.y,n.y,r?.originY)}function Gs(e,t,n,r=0){e.min=(r?F(n.min,n.max,r):n.min)+t.min,e.max=e.min+W(t)}function Ks(e,t,n,r){Gs(e.x,t.x,n.x,r?.x),Gs(e.y,t.y,n.y,r?.y)}function qs(e,t,n,r=0){let i=r?F(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+W(t)}function Js(e,t,n,r){qs(e.x,t.x,n.x,r?.x),qs(e.y,t.y,n.y,r?.y)}function Ys(e,t,n,r,i){return e-=t,e=Pe(e,1/n,r),i!==void 0&&(e=Pe(e,1/i,r)),e}function Xs(e,t=0,n=1,r=.5,i,a=e,o=e){if(rn.test(t)&&(t=parseFloat(t),t=F(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=F(a.min,a.max,r);e===a&&(s-=t),e.min=Ys(e.min,t,n,s,i),e.max=Ys(e.max,t,n,s,i)}function Zs(e,t,[n,r,i],a,o){Xs(e,t[n],t[r],t[i],t.scale,a,o)}var Qs=[`x`,`scaleX`,`originX`],$s=[`y`,`scaleY`,`originY`];function ec(e,t,n,r){Zs(e.x,t,Qs,n?.x,r?.x),Zs(e.y,t,$s,n?.y,r?.y)}var tc=e=>typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),nc=tc(`applewebkit/`)&&!tc(`chrome/`)?Math.round:vn;function rc(e){e.min=nc(e.min),e.max=nc(e.max)}function ic(e){rc(e.x),rc(e.y)}function ac(e){return e.translate===0&&e.scale===1}function oc(e){return ac(e.x)&&ac(e.y)}function sc(e,t){return e.min===t.min&&e.max===t.max}function cc(e,t){return sc(e.x,t.x)&&sc(e.y,t.y)}function lc(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function uc(e,t){return lc(e.x,t.x)&&lc(e.y,t.y)}function dc(e){return W(e.x)/W(e.y)}function fc(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var pc=class{constructor(){this.members=[]}add(e){hn(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||(Vn(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(Vn(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 mc(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var hc={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`){if(Tn.test(e))e=parseFloat(e);else return e}return`${mc(e,t.target.x)}% ${mc(e,t.target.y)}%`}},gc={borderRadius:Object.assign({},hc,{applyTo:bs.slice()}),borderTopLeftRadius:hc,borderTopRightRadius:hc,borderBottomLeftRadius:hc,borderBottomRightRadius:hc,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=dn.parse(e);if(i.length>5)return r;let a=dn.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=F(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 _c(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<st.length;e++){let t=st[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 vc(e){return[e(`x`),e(`y`)]}var yc=(e,t)=>e.depth-t.depth,bc=class{constructor(){this.children=[],this.isDirty=!1}add(e){hn(this.children,e),this.isDirty=!0}remove(e){Vn(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(yc),this.isDirty=!1,this.children.forEach(e)}},xc={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Sc=[`z`,`skew`,`skewZ`],Cc=1e3,wc=0;function Tc(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}var Ec=e=>e.instance&&Dn.get(e.instance)?.demote()&&e.resetSkewAndRotation();function Dc(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=ms(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&&Dc(r)}function Oc(e){if(e)return e.options.allowProjection===!1?Oc(e.parent):e.projection}function kc({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return Object.assign(er,{...gc,...er}),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:Oc(e.parent));d.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!a||o&&Cs(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=wc++,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(Mc),this.nodes.forEach(Uc),this.nodes.forEach(Wc),this.nodes.forEach(Nc),xs.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 bc)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new En),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=S(t)&&!ws(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=Ss(i,250),xc.hasAnimatedSinceResize&&(xc.hasAnimatedSinceResize=!1,this.nodes.forEach(Hc)))})}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()||Zc,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=n.getProps(),c=!this.targetLayout||!uc(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={...ne(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||Hc(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,_n(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(Gc),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&&Dc(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;Ec(this),this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,Ec(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(Ic),this.nodes.forEach(Fc);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Lc);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(zc),this.nodes.forEach(Bc),this.nodes.forEach(Vc),this.nodes.forEach(Ac),this.nodes.forEach(jc)):this.nodes.forEach(Lc),this.clearAllSnapshots();let e=Bn.now();wn.delta=Hn(0,1e3/60,e-wn.timestamp),wn.timestamp=e,wn.isProcessing=!0,ln.update.process(wn),ln.preRender.process(wn),ln.render.process(wn),wn.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,In.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Pc),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&&Ec(this);let t=this.projectionDelta&&!oc(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,``):void 0,a=r!==this.prevTransformTemplateValue;e&&this.instance&&(t||E(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)),ic(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(el))){let{scroll:e}=this.root;e&&(tt(t.x,e.offset.x),tt(t.y,e.offset.y))}return t}removeElementScroll(e){let t=U();if(Is(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&&Is(t,e),tt(t.x,i.offset.x),tt(t.y,i.offset.y))}return t}applyTransform(e,t=!1,n,r,i=0){let a=n||U();Is(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&&(tt(a.x,-n.scroll.offset.x),tt(a.y,-n.scroll.offset.y)),E(n.latestValues)&&we(a,n.latestValues,n.layout?.layoutBox)}return!r&&E(this.latestValues)&&we(a,this.latestValues,this.layout?.layoutBox),a}removeTransform(e){let t=U();Is(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!E(n.latestValues))continue;let r;n.instance&&(pe(n.latestValues)&&n.updateSnapshot(),r=U(),Is(r,n.measurePageBox())),ec(t,n.latestValues,n.snapshot?.layoutBox,r)}return E(this.latestValues)&&ec(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!==wn.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=wn.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(),Ks(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):Is(this.target,this.layout.layoutBox),Ge(this.target,this.targetDelta)):Is(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),xs.countProjection?.(1))}getClosestProjectingParent(){if(!(!this.parent||pe(this.parent.latestValues)||Oe(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(),Js(this.relativeTargetOrigin,t,n,this.options.layoutAnchor||void 0),Is(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===wn.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;Is(this.layoutCorrected,this.layout.layoutBox);let a=this.treeScale.x,o=this.treeScale.y;Ie(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():(Ls(this.prevProjectionDelta.x,this.projectionDelta.x),Ls(this.prevProjectionDelta.y,this.projectionDelta.y)),Ws(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.treeScale.x===a&&this.treeScale.y===o&&fc(this.projectionDelta.x,this.prevProjectionDelta.x)&&fc(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners(`projectionUpdate`,s)),xs.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=io(),this.projectionDelta=io(),this.projectionDeltaWithTransform=io()}setAnimationOrigin(e,t=!1,n){let r=this.snapshot,i=r?r.latestValues:{},a={...this.latestValues},o=io();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(Xc));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?Ns(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?Kc(o[r],e[r],this.layout.layoutBox[r],l[t*2],l[t*2+1]):qc(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){Js(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0);let e=this.relativeTargetOrigin,t=s;if(Yc(this.relativeTarget,e,t,n),this.isSpringLayout){let e=this.relativeTarget,t=this.impulse||0,n=this.relativeStart,r=Bn.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&&cc(this.relativeTarget,f)&&(this.isProjectionDirty=!1),f||=U(),Is(f,this.relativeTarget)}c&&(this.animationValues=a,Os(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&&=(_n(this.pendingAnimation),void 0),this.pendingAnimation=H.update(()=>{xc.hasAnimatedSinceResize=!0,this.motionValue||=jn(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=Ps(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=j(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,an(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?.(Cc),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&&$c(this.options.animationType,this.layout.layoutBox,n.layoutBox)){let{layoutBox:e}=this.layout,t=i;i=this.target||U(),Qc(i.x,t.x,e.x),Qc(i.y,t.y,e.y)}Is(t,i),we(t,r),Ws(this.projectionDeltaWithTransform,this.layoutCorrected,t,r)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new pc),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(!at(t))return;let n={};for(let t=0;t<Sc.length;t++)Tc(Sc[t],e,n,this.animationValues);for(let t=0;t<st.length;t++)Tc(st[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=Yr(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=Yr(t?.pointerEvents)||``),this.hasProjected&&!E(this.latestValues)&&(e.transform=r?r({},``):`none`,this.hasProjected=!1);return}e.visibility=``;let i=n.animationValues||n.latestValues;this.applyTransformsToTarget();let a=_c(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 er){if(i[t]===void 0)continue;let{correct:r,applyTo:o,isCSSVariable:s}=er[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?Yr(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(Fc),this.root.sharedNodes.clear()}}}function Ac(e){e.updateLayout(),Rc(e)}function jc(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`)vc(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`;Fs(r[e],a[e])}else $c(i,t.layoutBox,n)&&vc(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=io();Ws(c,n,t.layoutBox);let l=io();Ws(l,a?e.applyTransform(r,!0):n,s);let u=!oc(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();Js(c,a?e.resumeFrom.applyTransform(t.layoutBox,!0,void 0,!0,f.depth+1):t.layoutBox,r.layoutBox,s);let l=U();Js(l,n,i.layoutBox,s),a&&o(c,l),uc(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 Mc(e){xs.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 Nc(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Pc(e){e.clearSnapshot()}function Fc(e){e.clearMeasurements()}function Ic(e){e.isLayoutDirty=!0,e.updateLayout()}function Lc(e){e.isLayoutDirty=!1}function Rc(e){let{snapshot:t,dragAncestor:n}=e,r=n?.isAnimationBlocked&&n.layout;if(!t||!r||e.resumeFrom||e.isAnimationBlocked)return;let i=n.dragSnapshot;vc(e=>tt(t.layoutBox[e],r.layoutBox[e].min-i.layoutBox[e].min))}function zc(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.dragSnapshot||e.layout,e.isLayoutDirty=!0)}function Bc(e){e.relativeTarget&&e.relativeParent?.isLayoutDirty&&(e.currentAnimation?e.isLayoutDirty=!0:(e.targetDelta=void 0,e.removeRelativeTarget()))}function Vc(e){let{visualElement:t}=e.options;t?.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function Hc(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Uc(e){e.resolveTargetDelta()}function Wc(e){e.calcProjection()}function Gc(e){e.resetSkewAndRotation()}function Kc(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 qc(e,t,n){e.translate=F(t.translate,0,n),e.scale=F(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Jc(e,t,n,r){e.min=F(t.min,n.min,r),e.max=F(t.max,n.max,r)}function Yc(e,t,n,r){Jc(e.x,t.x,n.x,r),Jc(e.y,t.y,n.y,r)}function Xc(e){return e.animationValues?.opacityExit!==void 0}var Zc={duration:.45,ease:[.4,0,.1,1]};function Qc(e,t,n){e.max=W(n)+(e.min=t.min)}function $c(e,t,n){return e===`position`||e===`preserve-aspect`&&!Hs(dc(t),dc(n),.2)}function el(e){return e!==e.root&&e.scroll?.wasRoot}function tl(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}var nl=kc({attachResizeListener:(e,t)=>tl(e,`resize`,t),measureScroll:Ae,checkIsScrollRoot:()=>!0}),rl=kc({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!co.current){let e=new nl({});e.mount(window),e.setOptions({layoutScroll:!0}),co.current=e}return co.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>window.getComputedStyle(e).position===`fixed`}),il=class extends Ui{constructor(){super(...arguments),this.KeyframeResolver=se}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;Cn(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}};function al(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 ol(e){return window.getComputedStyle(e)}var sl=class extends il{constructor(){super(...arguments),this.type=`html`,this.renderInstance=al}mount(e){super.mount(e)}readValueFromInstance(e,t){if(fn.has(t))return this.projection?.isProjecting?pn(t):mn(e,t);{let n=ol(e),r=(Ln(t)?n.getPropertyValue(t):n[t])||0;return typeof r==`string`?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return Je(e,t)}build(e,t,n){zn(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return Ii(e,t,n)}},cl=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1;function ll(e){return{point:{x:e.pageX,y:e.pageY}}}var ul=e=>t=>cl(t)&&e(t,ll(t));function dl(e,t,n,r){return tl(e,t,ul(n),r)}var fl=new WeakMap,pl,ml=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:S(r)&&`getBBox`in r?r.getBBox()[t]:r[n],hl=ml(`inline`,`width`,`offsetWidth`),gl=ml(`block`,`height`,`offsetHeight`);function _l({target:e,borderBoxSize:t}){fl.get(e)?.forEach(n=>{n(e,{get width(){return hl(e,t)},get height(){return gl(e,t)}})})}function vl(e){e.forEach(_l)}function yl(){typeof ResizeObserver<`u`&&(pl=new ResizeObserver(vl))}function bl(e,t){pl||yl();let n=O(e);return n.forEach(e=>{let n=fl.get(e);n||(n=new Set,fl.set(e,n)),n.add(t),pl?.observe(e)}),()=>{n.forEach(e=>{let n=fl.get(e);n?.delete(t),n?.size||pl?.unobserve(e)})}}var xl=new Set,Sl;function Cl(){Sl=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};xl.forEach(t=>t(e))},window.addEventListener(`resize`,Sl)}function wl(e){return xl.add(e),Sl||Cl(),()=>{xl.delete(e),!xl.size&&typeof Sl==`function`&&(window.removeEventListener(`resize`,Sl),Sl=void 0)}}function Tl(e,t){return ue(typeof e==`function`?wl(e):bl(e,t))}var El=(e,t)=>Math.abs(e-t);function Dl(e,t){let n=El(e.x,t.x),r=El(e.y,t.y);return Math.sqrt(n**2+r**2)}var Ol=new Set([`auto`,`scroll`]),kl=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=jl(this.lastRawMoveEventInfo,this.transformPagePoint));let e=Nl(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=Dl(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e;this.history.push({...r,timestamp:Bn.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=jl(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=Nl(e.type===`pointercancel`?this.lastMoveEventInfo:jl(t,this.transformPagePoint),this.history);this.startEvent&&n?.(e,a),r?.(e,a)},!cl(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=s?0:a,this.contextWindow=r||window;let c=ll(e),l=jl(c,this.transformPagePoint),{point:u}=l;this.history=[{...u,timestamp:Bn.now()}];let{onSessionStart:d}=t;d&&d(e,Nl(l,this.history));let f={passive:!0,capture:!0};this.removeListeners=ie(dl(this.contextWindow,`pointermove`,this.handlePointerMove,f),dl(this.contextWindow,`pointerup`,this.handlePointerUp,f),dl(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);(Ol.has(e.overflowX)||Ol.has(e.overflowY))&&this.scrollPositions.set(t,Al(t)),t=t.parentElement}this.scrollPositions.set(window,Al(window)),this.removeScrollListeners=ie(tl(window,`scroll`,this.onElementScroll,{capture:!0}),tl(window,`scroll`,this.onWindowScroll,{}))}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===window,r=Al(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(),_n(this.updatePoint)}},Al=e=>e===window?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop};function jl(e,t){return t?{point:t(e.point)}:e}function Ml(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Nl({point:e},t){return{point:e,delta:Ml(e,Fl(t)),offset:Ml(e,Pl(t)),velocity:Il(t,.1)}}function Pl(e){return e[0]}function Fl(e){return e[e.length-1]}function Il(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=Fl(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>On(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>On(t)*2&&(r=e[1]);let a=Mn(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 Ll=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]);function Rl(e){return Ll.has(e.tagName)||e.isContentEditable===!0}var zl=new Set([`INPUT`,`SELECT`,`TEXTAREA`]);function Bl(e){return zl.has(e.tagName)||e.isContentEditable===!0}var Vl={x:!1,y:!1};function Hl(){return Vl.x||Vl.y}function Ul(e){return e===`x`||e===`y`?Vl[e]?null:(Vl[e]=!0,()=>{Vl[e]=!1}):Vl.x||Vl.y?null:(Vl.x=Vl.y=!0,()=>{Vl.x=Vl.y=!1})}function Wl(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?F(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?F(n,e,r.max):Math.min(e,n)),e}function Gl(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 Kl(e,{top:t,left:n,bottom:r,right:i}){return{x:Gl(e.x,n,i),y:Gl(e.y,t,r)}}function ql(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 Jl(e,t){return{x:ql(e.x,t.x),y:ql(e.y,t.y)}}function Yl(e,t){let n=.5,r=W(e),i=W(t);return i>r?n=te(t.min,t.max-r,e.min):r>i&&(n=te(e.min,e.max-i,t.min)),Hn(0,1,n)}function Xl(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 Zl=.35;function Ql(e=Zl){return e===!1?e=0:e===!0&&(e=Zl),{x:$l(e,`left`,`right`),y:$l(e,`top`,`bottom`)}}function $l(e,t,n){return{min:eu(e,t),max:eu(e,n)}}function eu(e,t){return typeof e==`number`?e:e[t]||0}function tu(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 nu=new WeakMap,ru=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=Ul(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),vc(e=>{let t=this.getAxisMotionValue(e).get()||0;if(Sn(t)&&(t=de(t,this.visualElement.current)||0),Tn.test(t))t=parseFloat(t);else if(rn.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),ps(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=lu(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 kl(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||!cu(e,n,this.currentDirection))return;let r=this.getAxisMotionValue(e),i=this.originPoint[e]+t[e],a=this.constraints&&this.constraints[e];a&&(i=Wl(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;iu(e)?this.constraints&&this.scroll===tu(n)||(this.constraints=this.resolveRefConstraints()):this.constraints=e&&r&&typeof e==`object`?Kl(r.layoutBox,e):!1,this.elastic=Ql(t),i!==this.constraints&&!iu(e)&&r&&this.constraints&&!this.hasMutatedConstraints&&vc(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=Xl(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!iu(e))return!1;let n=au(e),{projection:r}=this.visualElement;if(!r||!r.layout)return!1;this.scroll=tu(r);let i=je(n,r.root,this.visualElement.getTransformPagePoint()),a=Jl(r.layout.layoutBox,r.removeElementScroll(i));if(t){let e=t(ge(a));this.hasMutatedConstraints=!!e,e&&(a=it(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)&&cu(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=vc(e=>{if(!cu(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 ps(this.visualElement,e),n.start(A(e,n,0,t,this.visualElement,!1))}stopAnimation(){vc(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();vc(e=>{if(!cu(e,n,this.currentDirection))return;let t=this.getAxisMotionValue(e),{min:r,max:o}=a[e];t.set((t.get()||0)+i[e]-F(r,o,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!iu(t)||!n||!this.constraints)return;this.stopAnimation();let r=this.constraints,i={x:0,y:0};vc(e=>{let t=this.getAxisMotionValue(e).get();i[e]=Yl({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(),vc(t=>{let n=this.getAxisMotionValue(t);if(!cu(t,e,null)||!n.get())return;let{min:r,max:a}=this.constraints[t];n.set(F(r,a,i[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;nu.set(this.visualElement,this);let e=this.visualElement.current,t=dl(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&Bl(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps(),r=iu(t)&&au(t);r&&(this.constraints=this.resolveRefConstraints(),n||=su(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=tl(window,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(vc(t=>{if(!cu(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=Zl,dragMomentum:n=!0}=e;return{...e,dragElastic:t,dragMomentum:n}}};function iu(e){return!!e&&typeof e==`object`&&(`current`in e||`nodeType`in e)}var au=e=>`current`in e?e.current:e;function ou(e){let t=!0;return()=>{t?t=!1:e()}}function su(e,t,n){let r=Tl(e,ou(n)),i=Tl(t,ou(n));return()=>{r(),i()}}function cu(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function lu(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}function uu(e,t){let n=O(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},ue(()=>r.abort())]}function du(e){return!(e.pointerType===`touch`||Hl())}function fu(e,t,n={}){t=Ue(t);let[r,i,a]=uu(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(!du(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 pu=(e,t)=>t?e===t||pu(e,t.parentElement):!1,mu=new WeakSet;function hu(e){return t=>{t.key===`Enter`&&e(t)}}function gu(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}var _u=(e,t)=>{let n=!1,r=hu(()=>{n||mu.has(e)||(n=!0,gu(e,`down`))}),i=hu(()=>{n&&(n=!1,gu(e,`up`))});e.addEventListener(`keydown`,r,t),e.addEventListener(`keyup`,i,t),e.addEventListener(`blur`,()=>{e.removeEventListener(`keydown`,r),e.removeEventListener(`keyup`,i),n&&gu(e,`cancel`)},{...t,once:!0})};function vu(e){return cl(e)&&!Hl()}var yu=new WeakSet,bu=100,xu=8,Su=(e,t,n)=>Math.hypot(e.clientX-t.clientX,e.clientY-t.clientY)>n,Cu=e=>e.preventDefault();function wu(e,t,n={}){t=Ue(t);let[r,i,a]=uu(e,n),o=new WeakMap,s=e=>{let r=e.currentTarget;if(!vu(e)||yu.has(e))return;n.stopPropagation&&yu.add(e);let{count:a=1,countTimeout:s=.3,hold:c=0,repeat:l}=n,u=Bn.now(),d=On(c),f=On(s),p=o.get(r);p?.expire(Su(p.event,e,bu))?p=void 0:p&&(_n(p.expire),o.delete(r));let m=p?p.count+1:1,h=m>=a,g=h&&(c||l),_=!c,v=0,y;if(mu.add(r),p)y=p.handlers;else{let n=t(r,e);y=typeof n==`function`?{onComplete:n}:n||{}}h&&_&&y.onActive?.();let b=On(l),x=d||b,S=u+x,C=!0,w=()=>{if(i.signal.aborted)return _n(w);let e=Math.min(1-(S-Bn.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):_n(w))},T={...i,capture:!0},E=(t,n)=>{if(cl(t)){if(window.removeEventListener(`pointerup`,D,T),window.removeEventListener(`pointercancel`,O,T),window.removeEventListener(`pointermove`,k,T),r.removeEventListener(`contextmenu`,Cu),_n(w),mu.delete(r),Hl()&&(n=!1),n&&!h){let n=Bn.now(),a=e=>{let s=i.signal.aborted;if(s||e===!0||Bn.now()-n>f)return _n(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||pu(r,e.target))},O=e=>{E(e,!1)},k=t=>{cl(t)&&((l||!_)&&Su(e,t,xu)||a>1&&Hl())&&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`,Cu,{...i,passive:!1}))};return r.forEach(e=>{(n.useGlobalTarget?window:e).addEventListener(`pointerdown`,s,i),Ve(e)&&(e.addEventListener(`focus`,()=>_u(e,i),i),!Rl(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function Tu(...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=ct(i,a,o);return t?s(r):s}var Eu=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},Du=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 Ou(e,t,n,r){al(e,t,void 0,r);for(let n in t.attrs)e.setAttribute(Du.has(n)?n:ee(n),t.attrs[n])}var ku=class extends il{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=U}getBaseTargetFromProps(e,t){return fn.has(t)?super.getBaseTargetFromProps(e,t)??pn(t):e[t]}getDefaultValue(e){return fn.has(e)?this.latestValues[e]??pn(e):void 0}readValueFromInstance(e,t){if(fn.has(t)){let e=un(t);return e&&e.default||0}if(An.includes(t)){let n=getComputedStyle(e)[t];if(typeof n==`string`&&n)return n.trim()}return t=Du.has(t)?t:ee(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return da(e,t,n)}build(e,t,n){xn(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){Ou(e,t,n,r)}mount(e){this.isSVGTag=Ka(e.tagName),super.mount(e)}};function Au(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 ju=[...qi].reverse(),Mu=e=>e?.out===!0?e:e?.out;function Nu(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>ys(e,t,n))),n=Fu(),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`&&os(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&&Mu(f(l??(g&&g.props.initial))?.transition);if(ju.forEach((t,r)=>{let i=n[t],l=o[t],f=g&&g.props[t],v=l===void 0?xi(f)||f===!1?f:void 0:l,y=xi(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||Xa(v)||typeof v==`boolean`)return;if(b===!1&&(h=r),t===`exit`&&i.isActive&&b!==!0){m={...m,...i.prevResolvedValues};return}let S=Pu(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}=os(e,n,ss(e,t))||{};E={...E,...a,...i},D=Mu(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)?!Au(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=os(s,n)?.transition?.delayChildren;r.delay=as(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&&!Cn(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=Fu(),i=!0}}}function Pu(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!Au(t,e):!1}function Fu(){let e={};for(let t of qi)e[t]={isActive:t===`animate`,protectedKeys:{},needsAnimating:{},prevResolvedValues:{},out:{}};return e}var Iu=()=>/[#*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,Lu=e=>{let t=Iu();return e.match(t)?.[0]},G=qt(),K=t(Ft(),1),Ru=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)},zu=(e,t)=>Math.floor(e/10**t%10),Bu=(e,t)=>!(zu(e,t)%2),q=(e,t,n)=>{let r=e%t;return n&&zu(e,n)%2==0?-r:r},Vu=(e,t,n)=>t[e%n],Hu=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`},Uu=4,J=80;function Wu(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:Uu},(e,i)=>({color:Vu(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:Bu(n,2)}))}var Gu=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Wu(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)`})]})]})},Ku=90,qu=5;function Ju(e,t){let n=Ru(e),r=t&&t.length,i=Array.from({length:qu},(e,i)=>Vu(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 Yu=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Ju(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:Ku,height:Ku,children:(0,G.jsx)(`rect`,{width:Ku,height:Ku,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]})]})]})},Xu=64,Zu=80;function Qu(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:Xu},(e,i)=>Vu(n%(i+1),t,r))}var $u=({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,"mask-type":`alpha`,maskUnits:`userSpaceOnUse`,x:0,y:0,width:Zu,height:Zu,children:(0,G.jsx)(`rect`,{width:Zu,height:Zu,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]})]})]})},ed=36;function td(e,t){let n=Ru(e),r=t&&t.length,i=Vu(n,t,r),a=q(n,10,1),o=a<5?a+ed/9:a,s=q(n,10,2),c=s<5?s+ed/9:s;return{wrapperColor:i,faceColor:Hu(i),backgroundColor:Vu(n+13,t,r),wrapperTranslateX:o,wrapperTranslateY:c,wrapperRotate:q(n,360),wrapperScale:1+q(n,ed/12)/10,isMouthOpen:Bu(n,2),isCircle:Bu(n,1),eyeSpread:q(n,5),mouthSpread:q(n,3),faceRotate:q(n,10,3),faceTranslateX:o>ed/6?o/2:q(n,8,1),faceTranslateY:c>ed/6?c/2:q(n,7,2)}}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 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:ed,height:ed,children:(0,G.jsx)(`rect`,{width:ed,height:ed,rx:r?void 0:72,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:ed,height:ed,fill:o.backgroundColor}),(0,G.jsx)(`rect`,{x:`0`,y:`0`,width:ed,height:ed,transform:`translate(`+o.wrapperTranslateX+` `+o.wrapperTranslateY+`) rotate(`+o.wrapperRotate+` 18 18) scale(`+o.wrapperScale+`)`,fill:o.wrapperColor,rx:o.isCircle?ed:ed/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})]})]})]})},rd=4,id=80;function ad(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:rd},(e,i)=>Vu(n+i,t,r))}var od=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=ad(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:id,height:id,children:(0,G.jsx)(`rect`,{width:id,height:id,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:id/2,y1:0,x2:id/2,y2:id/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:id/2,y1:id/2,x2:id/2,y2:id,gradientUnits:`userSpaceOnUse`,children:[(0,G.jsx)(`stop`,{stopColor:o[2]}),(0,G.jsx)(`stop`,{offset:1,stopColor:o[3]})]})]})]})},sd=3,cd=80;function ld(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:sd},(e,i)=>({color:Vu(n+i,t,r),translateX:q(n*(i+1),cd/10,1),translateY:q(n*(i+1),cd/10,2),scale:1.2+q(n*(i+1),cd/20)/10,rotate:q(n*(i+1),360,1)}))}var ud=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=ld(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:cd,height:cd,children:(0,G.jsx)(`rect`,{width:cd,height:cd,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,G.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,G.jsx)(`rect`,{width:cd,height:cd,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`})]})})]})},dd={pixel:$u,bauhaus:Gu,ring:Yu,beam:nd,sunset:od,marble:ud,geometric:nd,abstract:Gu},fd=({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=dd[e]||ud;return(0,G.jsx)(s,{colors:t,name:n,title:r,size:i,square:a,...o})},pd=Pt({block:`img`,elements:[]}),md=e=>(0,K.memo)(t=>(0,K.createElement)(e,t)),hd=({unoptimized:e,...t})=>{let n=(0,K.use)(Be),r=n?.imgAs||`img`,i=(0,K.useMemo)(()=>md(r),[r]);return(0,G.jsx)(i,{unoptimized:e===void 0?n?.imgUnoptimized:e,...t,className:V(pd(),t.className)})};hd.displayName=`Img`;var gd=Pt({block:`fluent-emoji`,elements:[]}),_d={container:{kLWn49:`lbo5v014`,kVAEAm:`lb1n2onr6`,k9WMMc:`lb2b8uid`,$$css:!0}};function vd(e){return[...e].map(e=>e?.codePointAt(0)?.toString(16)).join(`-`)}function yd(e){let t=vd(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 bd=(e,t)=>{let n=[`anim`,`3d`].includes(t)?`webp`:`svg`;switch(t){case`raw`:return null;case`anim`:return{path:`assets/${vd(e)}.${n}`,pkg:yd(e),version:`latest`};case`3d`:return{path:`assets/${vd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-3d`,version:`latest`};case`flat`:return{path:`assets/${vd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-flat`,version:`latest`};case`modern`:return{path:`assets/${vd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-modern`,version:`latest`};case`mono`:return{path:`assets/${vd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-mono`,version:`latest`}}},xd=({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=le(),d=(0,K.useMemo)(()=>bd(e,r),[r,e]);return r===`raw`||!d||c?(0,G.jsx)(gn,{flex:`none`,height:i,ref:o,role:`img`,width:i,...s,...B(_d.container,V(gd(),t),{fontSize:i*.9,...n}),children:e}):(0,G.jsx)(hd,{alt:e,className:V(gd(),t),height:i,loading:`lazy`,ref:o,src:u(d),style:{flex:`none`,...n},unoptimized:a,width:i,onError:()=>l(!0),...s})};xd.displayName=`FluentEmoji`;var Sd=e=>`oklch(from ${e} clamp(0, (l - 0.62) * -1000, 1) 0 h / 1)`,Cd=Pt({block:`avatar`,dataAttributes:[`shape`,`variant`,`shadow`],elements:[`loading`,`img`,`content`,`fallback`]}),wd=Pt({block:`avatar-group`,elements:[`avatar`,`count`,`item`,`badge`]}),Td={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}},Ed=e=>e?!!(typeof e==`string`&&[`/`,`http`,`data:`].some(t=>e.startsWith(t))||(0,K.isValidElement)(e)):!1,Dd=e=>!!(e&&e!==`transparent`&&e!==`rgba(0,0,0,0)`&&e!==null),Od=(e,t)=>{if(!e)return``;let n=e.toUpperCase();return t?n.slice(0,2):n},kd=(e,t,n)=>n?t?e*.85:e:e*.85,Ad=[`#383838`,`#7858f9`,`#f8f7bf`,`#ffdd1f`,`#f88c13`],jd=(e,t,n)=>(t||n||typeof e==`string`&&e||void 0)?.trim().replaceAll(/[\s"'()#\\]+/g,`_`)||void 0,Md={borderless:He.variantBorderlessWithoutHover,filled:He.variantFilledWithoutHover,outlined:He.variantOutlinedWithoutHover},Nd=(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,ee=typeof n==`string`,[A,te]=(0,K.useState)(!1),j=(0,K.useMemo)(()=>Ed(n),[n]),ne=(0,K.useMemo)(()=>n&&ee&&!j?Lu(n):void 0,[n,ee,j]),re=j?x:typeof n==`string`?n:void 0,M=e||x||`avatar`,ie=Dd(r),ae=j&&ee&&!A,N=j&&!ee&&!A,oe=jd(n,x,e),se=f!==`text`&&!!oe&&!ne&&!ae&&!N,ce=d?.length?d:Ad,le=(0,K.useMemo)(()=>ne?(0,G.jsx)(xd,{emoji:ne,size:kd(k,ie,u),type:t?`anim`:`3d`,unoptimized:C}):Od(re||x,v),[t,ne,ie,k,v,re,x,C,u]),P=_!==void 0,ue=!r&&!se&&!(j&&!A||ne);return(0,G.jsxs)(`div`,{...Nt({shadow:h,shape:g,variant:w}),...O,ref:m,title:D,className:B([Td.root,Md[w],h&&Td.shadow,!P&&Td.defaultSize,!P&&!!ne&&Td.defaultEmojiFont,g===`circle`?Td.circle:!P&&Td.defaultSquare,ue&&Td.defaultBackground,!r&&Td.defaultColor,!!O?.onClick&&Td.clickable,T],V(Cd(),o,s?.root)).className,style:{...r&&{backgroundColor:r,color:Sd(r)},...P&&{fontSize:k*(ne?.7:.5),height:k,width:k,...g!==`circle`&&{borderRadius:k<24?`33%`:Math.max(k/6,2)}},...i&&{boxShadow:`${Qe.colorBgLayout} 0 0 0 2px, ${a||Qe.colorTextTertiary} 0 0 0 4px`},...y,...b?.root},children:[p&&(0,G.jsx)(gn,{flex:`none`,height:`100%`,width:`100%`,...B(Td.loading,V(Cd(`loading`),s?.loading),b?.loading),children:(0,G.jsx)(bt,{spin:!0,icon:Fe})}),typeof n==`string`&&ae&&(0,G.jsx)(`img`,{alt:M,crossOrigin:c,draggable:l,height:k,loading:`lazy`,src:n,width:k,...B(Td.img,V(Cd(`img`),s?.img),b?.img),onError:()=>te(!0)}),se&&(0,G.jsx)(fd,{square:!0,"aria-label":M,colors:ce,name:oe,size:`100%`,variant:f,...B(Td.fallback,V(Cd(`fallback`),s?.fallback),b?.fallback)}),!ae&&!se&&(0,G.jsx)(`span`,{...B([Td.content,E],V(Cd(`content`),s?.content),b?.content),children:N?n:le})]})});Nd.displayName=`Avatar`;var Pd=Nd,Fd={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}},Id=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.currentTarget.click())},Ld=(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)(cn,{horizontal:!0,gap:n,ref:g,...B(Fd.root,V(wd(),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)(Nd,{"aria-disabled":l||void 0,"aria-label":s,"aria-pressed":g?!!c:void 0,className:V(wd(`avatar`),f?.avatar,a),nativeTitle:s,role:g?`button`:void 0,tabIndex:g?0:void 0,xstyle:Fd.avatar,style:{...!u&&v,...o&&{boxShadow:`0 0 0 2px ${o}`},...m?.avatar,...i},onKeyDown:g?Id: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(Fd.item,wd(`item`));return(0,G.jsxs)(`span`,{className:b.className,style:{...b.style,...v},children:[y,(0,G.jsx)(`span`,{...B(Fd.badge,wd(`badge`)),children:u})]},r)}),t&&S.length>0&&(0,G.jsx)(Nd,{...T,"aria-label":w||void 0,avatar:`+${S.length}`,background:Qe.colorText,className:V(wd(`count`),f?.count),contentXstyle:Fd.count,fallbackVariant:`text`,nativeTitle:w||void 0,sliceText:!1,xstyle:Fd.avatar,style:{marginLeft:C,zIndex:_?0:x.length,...m?.count}})]})});Ld.displayName=`AvatarGroup`;var Rd=Pd;Rd.Group=Ld;function zd({children:e,features:t,strict:n=!1}){let[,r]=(0,K.useState)(!Bd(t)),i=(0,K.useRef)(void 0);if(!Bd(t)){let{renderer:e,...n}=t;i.current=e,Ra(n)}return(0,K.useEffect)(()=>{Bd(t)&&t().then(({renderer:e,...t})=>{Ra(t),i.current=e,r(!0)})},[]),(0,G.jsx)(Mi.Provider,{value:{renderer:i.current,strict:n},children:e})}function Bd(e){return typeof e==`function`}function Vd(e,t){if(typeof Proxy>`u`)return ta;let n=new Map,r=(n,r)=>ta(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,ta(a,void 0,e,t)),n.get(a))})}var Hd=Vd(),Ud=(e,t)=>t.isSVG??Ca(e)?new ku(t):new sl(t,{allowProjection:e!==K.Fragment}),Wd=class extends Eu{constructor(e){super(e),e.animationState||=Nu(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();Xa(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?.()}},Gd=0,Kd={animation:{Feature:Wd},exit:{Feature:class extends Eu{constructor(){super(...arguments),this.id=Gd++}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}=os(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(){}}}},qd=class extends Eu{constructor(e){super(e),this.removeGroupControls=vn,this.removeListeners=vn,this.controls=new ru(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||vn}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()}},Jd=e=>(t,n)=>{e&&H.update(()=>e(t,n),!1,!0)},Yd=class extends Eu{constructor(){super(...arguments),this.removePointerDownListener=vn}onPointerDown(e){this.session=new kl(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:Jd(e),onStart:Jd(t),onMove:Jd(n),onEnd:(e,t)=>{delete this.session,r&&H.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=dl(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session?.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session?.end()}},Xd=!1,Zd=({layout:e,layoutDependency:t,layoutAnchor:n})=>({layout:e,layoutDependency:t,layoutAnchor:n,animationType:typeof e==`string`?e:`both`}),Qd=(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)}},$d=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),Xd&&i.root.didUpdate(),i.options.layoutId!==r&&Qd(i,r)?.(),i.addEventListener(`animationComplete`,()=>this.safeToRemove()),i.setOptions({...i.options,...Zd(this.props),onExitComplete:()=>this.safeToRemove()})),xc.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(),Qd(o,n)),o.setOptions({...o.options,...Zd(this.props)}),Xd=!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(),In.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;Xd=!0,r&&(r.scheduleCheckAfterUnmount(),t.group?.remove(r),n?.deregister?.(r))}safeToRemove(){this.props.safeToRemove?.()}render(){return null}};function ef(e){let[t,n]=be(),r=(0,K.useContext)(yn);return(0,G.jsx)($d,{...e,layoutGroup:r,switchLayoutGroup:(0,K.useContext)(Ti),isPresent:t,safeToRemove:n})}var tf={pan:{Feature:Yd},drag:{Feature:qd,ProjectionNode:rl,MeasureLayout:ef}};function nf(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,ll(t)))}var rf=class extends Eu{mount(){let{current:e}=this.node;e&&(this.unmount=fu(e,(e,t)=>(nf(this.node,t,`Hover`,`Start`),e=>nf(this.node,e,`Hover`,`End`))))}unmount(){}},af=class extends Eu{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=ie(tl(this.node.current,`focus`,()=>this.onFocus()),tl(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}};function of(e,t,n,r){e.current instanceof HTMLButtonElement&&e.current.disabled||nf(e,t,`Tap`,n,r)}var sf=class extends Eu{constructor(){super(...arguments),this.options={}}mount(){let{current:e}=this.node;e&&(this.update(),this.unmount=wu(e,(e,t)=>(of(this.node,t,`Start`),{onComplete:(e,{success:t})=>of(this.node,e,t?``:`Cancel`),onRepeat:()=>of(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(){}},cf=new WeakMap,lf=new WeakMap,uf=e=>{let t=cf.get(e.target);t&&t(e)},df=e=>{e.forEach(uf)};function ff({root:e,...t}){let n=e||document;lf.has(n)||lf.set(n,{});let r=lf.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(df,{root:e,...t})),r[i]}function pf(e,t,n){let r=ff(t);return cf.set(e,n),r.observe(e),()=>{cf.delete(e),r.unobserve(e)}}var mf={some:0,all:1},hf=class extends Eu{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:mf[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=pf(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(gf(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function gf({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}var _f=Object.assign({},Object.assign({renderer:Ud},Kd,{inView:{Feature:hf},tap:{Feature:sf},focus:{Feature:af},hover:{Feature:rf}}),tf,{layout:{ProjectionNode:rl,MeasureLayout:ef}});function vf(e){let t=kn(()=>jn(e)),{isStatic:n}=(0,K.useContext)(Rn);if(n){let[,n]=(0,K.useState)(e);(0,K.useEffect)(()=>t.on(`change`,n),[])}return t}function yf(e,t){let n=vf(t()),r=()=>n.set(t());return r(),Fn(()=>{let t=()=>H.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return r(),()=>{n.forEach(e=>e()),_n(r)}}),n}function bf(e){Pn.current=[],e();let t=yf(Pn.current,e);return Pn.current=void 0,t}function xf(e,t,n,r){if(typeof e==`function`)return bf(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return Cf(e,t,n,r);let i=typeof t==`function`?t:Tu(t,n,r),a=Array.isArray(e)?Sf(e,i):Sf([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 Sf(e,t){let n=kn(()=>[]);return yf(e,()=>{n.length=0;let r=e.length;for(let t=0;t<r;t++)n[t]=e[t].get();return t(n)})}function Cf(e,t,n,r){let i=kn(()=>Object.keys(n)),a=kn(()=>({}));for(let o of i)a[o]=xf(e,t,n[o],r);return a}function wf(){!ha.current&&Da();let[e]=(0,K.useState)(Zi.current);return e}var Tf=(0,K.createContext)(null),Ef=(0,K.createContext)(null);function Df(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:kf(t.x)+n.x,y:kf(t.y)+n.y},i=Af(e),s=i.find(t=>t.items.includes(e[o])),c=i.reduce((e,t)=>jf(r.y,t)<jf(r.y,e)?t:e);if(c!==s)return Mf(e,o,r.x,c,a);let l=Nf(r,t),u=-1,d=l;return e.forEach((e,t)=>{if(t===o)return;let n=Nf(r,e.layout);n<d&&(u=t,d=n)}),u===-1?e:on(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=kf(u);return s===1&&l.max+n[i]>d||s===-1&&l.min+n[i]<d?on(e,o,o+s):e}function Of(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=Af(e).sort((e,t)=>e.min-t.min),r=n[n.findIndex(({items:n})=>n.includes(e[t]))+a],i=n=>Math.abs(kf(n.layout.x)-kf(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 kf=({min:e,max:t})=>F(e,t,.5);function Af(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 jf(e,t){return e<t.min?t.min-e:e>t.max?e-t.max:0}function Mf(e,t,n,r,i){let a=e.filter((e,n)=>n!==t),o=r.items.find(e=>{let t=kf(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 Nf(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 Pf=(e,t)=>e.max<=t.min||t.max<=e.min;function Ff(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||=Pf(e[r].x,e[i].x),n||=Pf(e[r].y,e[i].y),t&&n)return`xy`;return t?`x`:`y`}var If=(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 Lf({children:e,as:t=`ul`,axis:n,onReorder:r,values:i,onPointerDownCapture:a,onClickCapture:o,...s},c,l){let u=kn(()=>l[t]),d=(0,K.useContext)(Tf),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)},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?Of(r,i,c,x,!!l&&O()):-1;if(a>-1)n?k(on(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=Ff(D().map(e=>e.layout));e!==g&&_(e)}},updateOrder:(e,t,n)=>{if(v.current)return;let r=D(),i=Df(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]),Fn(()=>d?.add(ee));let A={overflowAnchor:`none`,...s.style};return(0,G.jsx)(u,{...s,style:A,ref:If(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)(Ef.Provider,{value:ee,children:e})})}var Rf=e=>(0,K.forwardRef)((t,n)=>Lf(t,n,e)),zf=50,Bf=1.5,Vf=new Set([`auto`,`scroll`]),Hf={x:new Map,y:new Map};function Uf(){Hf.x.clear(),Hf.y.clear()}function Wf(e,t){let n=getComputedStyle(e),r=t===`x`?n.overflowX:n.overflowY;return e===document.body||e===document.documentElement||Vf.has(r)&&(t===`x`?e.scrollWidth>e.clientWidth:e.scrollHeight>e.clientHeight)}function Gf(e,t){let n=e?.parentElement;for(;n;){if(Wf(n,t))return n;n=n.parentElement}return null}function Kf(e){let t=Math.min(1,1-e/zf);return Bf*t*t*wn.delta}function qf(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<zf?{amount:-Kf(o),edge:`start`}:s<zf?{amount:Kf(s),edge:`end`}:{amount:0,edge:null}}function Jf(e,t,n,r){if(!e)return;let i=Gf(e,n);if(!i)return;let{amount:a,edge:o}=qf(t-(n===`x`?window.scrollX:window.scrollY),i,n),s=Hf[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 Yf(e,t=0){return Cn(e)?e:vf(t)}function Xf({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)(Ef),m=(0,K.useContext)(Tf),h=(0,K.useRef)(null),g=kn(()=>p.proxy[r]),_=(0,K.useRef)(),v={x:Yf(t.x),y:Yf(t.y)},y=xf([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,K.useEffect)(()=>D);let A=(e,t)=>{_.current=t,t||m?.end(n),Nn.get(e)?.animationState?.setActive(`whileDrag`,!!t)},te=(0,K.useRef)(!1);return Fn(()=>{m?.receive(p,n,h.current,A)&&(te.current=!0)},[]),(0,G.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)Jf(m&&!b.includes(e)?m.column(p):C.current,i[e],e,r[e]);a&&a(e,t)},onDragEnd:(e,t)=>{w.current=!1,Uf(),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:If(h,f),ignoreStrict:!0,children:e})}var Zf=(0,K.forwardRef)(Xf),Qf=e=>{let{left:t,top:n,width:r,height:i}=e.getBoundingClientRect();return{x:t+r/2,y:n+i/2}},$f=e=>{let{x:t,y:n}=Qf(e),{scrollX:r,scrollY:i}=e.ownerDocument.defaultView;return{x:t+r,y:n+i}};function ep(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 tp=(e,t)=>{let n=e.groupRef.current,r=t.groupRef.current;return n.contains(r)||r.contains(n)};function np(e){let t=new Set,n,r=(t,n,r)=>!tp(t,n)&&e.current.canMove?.(r,t.values,n.values)!==!1,i,a=(e,t,r,i,a,o)=>{let s=Qf(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=>ep(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:$f(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=$f(o),n.event=s),!0;let c=Qf(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=Nn.get(o);return a(e,l,i,o,{controls:u&&nu.get(u),event:s}),!0},key:(e,n,o,s,c)=>{let l=Qf(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=Nn.get(r),o=a&&nu.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:(In.read(()=>{if(n!==s)return;n=void 0,Nn.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($f(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 rp({children:e,...t}){let n=(0,K.useRef)(t);return Fn(()=>{n.current=t}),(0,G.jsx)(Tf.Provider,{value:kn(()=>np(n)),children:e})}var ip=(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},ap=Pt({block:`text`,dataAttributes:[`type`],elements:[]}),op={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)(op.shiny),`lobe-text-shiny`);var sp=(e={})=>[op.text,e.as&&op[e.as],e.code&&op.code,e.delete&&op.delete,e.disabled&&op.disabled,e.ellipsis===`multi`&&op.ellipsisMulti,e.ellipsis===!0&&op.ellipsis,e.italic&&op.italic,e.mark&&op.mark,e.shiny&&op.shiny,e.strong&&op.strong,e.type&&op[e.type],e.underline&&op.underline],cp=(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 ee=(0,K.useRef)(null),A=ip(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)},re={...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},M=(0,G.jsx)(t,{...Nt({type:w}),...k,ref:ne,style:re,className:B(sp({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(ap(),_&&`lobe-text-shiny`,r,i?.root)).className,children:n});if(l&&typeof l==`object`&&(l.tooltip||l.tooltipWhenOverflow)){if(j&&!A)return M;let e=typeof l.tooltip==`string`?l.tooltip:n;return l.tooltip&&typeof l.tooltip==`object`?(0,G.jsx)(wo,{...l.tooltip,title:l.tooltip?.title||e,children:M}):(0,G.jsx)(wo,{title:e,children:M})}return M});cp.displayName=`Text`;var lp=cp,up=e=>{e.stopPropagation()},dp=e=>{e.preventDefault(),e.stopPropagation(),e.preventBaseUIHandler?.()},fp=K.createContext({disabled:!1});function pp(){return K.useContext(fp)}function mp(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=gt(),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)(Ro.Provider,{value:u,children:(0,G.jsx)(To.Provider,{value:void 0,children:(0,G.jsx)(Eo,{...e})})})}var hp=Fo,Y=Pt({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`]}),gp=(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}=jt(`floating`,r),o=typeof t==`function`?e=>({zIndex:i,...t(e)}):{zIndex:i,...t};return(0,G.jsx)(hp,{...n,className:V(R.positioner,Y(`positioner`)),collisionPadding:e??ze(),ref:a,style:o})});gp.displayName=`ContextMenuSubmenuPositioner`;var _p=(0,K.memo)(()=>{let{t:e}=Gt(re);return(0,G.jsx)(Lo,{disabled:!0,className:V(z(I.item,I.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`)})})})});_p.displayName=`EmptyMenuItem`;var vp=({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)(Lo,{closeOnClick:n,disabled:a,label:o,className:V(z(I.item,r&&I.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)(qe,{checked:d,disabled:a,size:`small`,tabIndex:-1,onChange:f,onClick:(e,t)=>t.stopPropagation()})})]})},yp=(e,t,n)=>{let r=Lt(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(I.itemContent,s&&I.itemContentAlignStart).className,Y(`item-content`)),children:[u?(0,G.jsx)(`span`,{"aria-hidden":!l,className:V(z(I.icon,s&&I.iconAlignStart).className,Xe.icon,Y(`icon`)),children:c?n:l?Ht(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)(zt,{})}):null]})},bp=(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)},xp=(e,t=[],n)=>{let r=n?.iconAlign,i=n?.iconSpaceMode??`global`,a=n?.reserveIconSpace??It(e,i===`global`),o=n?.indicatorOnRight??Bt(e);return e.map((e,n)=>{if(!e)return null;let s=`${t.join(`-`)||`root`}-${n}`,c=Vt(e,s),l=[...t,String(c)];if(e.type===`checkbox`){let t=e,n=Lt(t),i=typeof n==`string`?n:void 0,s=!!t.danger,l=(0,G.jsx)(No,{className:Y(`checkbox-indicator`),children:(0,G.jsx)(bt,{icon:D,size:`small`})});return(0,G.jsx)(Ao,{checked:t.checked,closeOnClick:t.closeOnClick,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,className:V(z(I.item,s&&I.danger).className,Y(`item`)),onCheckedChange:e=>t.onCheckedChange?.(e),children:yp(t,{iconAlign:r,indicatorOnRight:o,reserveIconSpace:a},l)},c)}if(e.type===`switch`){let t=e,n=Lt(t),i=typeof n==`string`?n:void 0,o=!!t.danger;return(0,G.jsx)(vp,{checked:t.checked,closeOnClick:t.closeOnClick,danger:o,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,onCheckedChange:t.onCheckedChange,children:yp(t,{iconAlign:r,reserveIconSpace:a})},c)}if(e.type===`divider`)return(0,G.jsx)(Po,{className:V(R.separator,Y(`separator`))},c);if(e.type===`group`){let t=e,n=i===`group`?t.children?It(t.children):!1:a,o=t.children?Bt(t.children):!1;return(0,G.jsxs)(ko,{className:Y(`group`),children:[t.label?(0,G.jsx)(Oo,{className:V(R.groupLabel,Y(`group-label`)),children:t.label}):null,t.children?xp(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=Lt(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?xp(t.children,l,{iconAlign:r,iconSpaceMode:i}):(0,G.jsx)(_p,{});return(0,G.jsxs)(jo,{defaultOpen:t.defaultOpen,open:t.open,onOpenChange:t.onOpenChange,children:[(0,G.jsx)(Io,{...t.triggerProps,closeDelay:t.closeDelay,delay:t.delay,disabled:t.disabled,label:o,openOnHover:t.openOnHover,className:V(z(I.item,s&&I.danger).className,Y(`item`)),onClick:t.onClick,children:yp(t,{iconAlign:r,reserveIconSpace:a,submenu:!0})}),(0,G.jsx)(Do,{children:(0,G.jsx)(gp,{alignOffset:-4,"data-submenu":``,sideOffset:-1,onContextMenu:dp,children:(0,G.jsxs)(Mo,{className:V(z(I.popup,u&&I.popupWithSlots).className,Xe.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=Lt(u),f=typeof d==`string`?d:void 0,p=`danger`in u&&!!u.danger;return(0,G.jsx)(Lo,{closeOnClick:u.closeOnClick,disabled:u.disabled,label:f,className:V(z(I.item,p&&I.danger).className,Y(`item`)),onClick:e=>bp(u,l,e),children:yp(u,{iconAlign:r,reserveIconSpace:a})},c)})},Sp={"--lobe-dropdown-animation-duration":`0ms`},Cp=(0,K.memo)(()=>{let e=N(),t=Dt(),n=(0,K.useSyncExternalStore)(Zt,Qt,Xt);(0,K.useEffect)(()=>{},[e]),(0,K.useEffect)(()=>{let e=e=>$t(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)(()=>xp(n.items,[],{iconAlign:n.iconAlign,iconSpaceMode:n.iconSpaceMode}),[n.items,n.iconAlign,n.iconSpaceMode]),{zIndex:i,ref:a}=jt(`floating`),o=n.header!=null||n.footer!=null;return!e||!n.open&&n.items.length===0?null:(0,G.jsx)(mp,{open:n.open,onOpenChange:e=>{e?Yt({open:e}):en()},children:(0,G.jsx)(Do,{container:t,children:(0,G.jsx)(hp,{anchor:n.anchor??void 0,className:V(R.positioner,Y(`positioner`)),collisionPadding:ze(),ref:a,sideOffset:6,style:{...Sp,zIndex:i},children:(0,G.jsxs)(Mo,{"data-has-footer":n.footer==null?void 0:``,"data-has-header":n.header==null?void 0:``,className:V(z(I.popup,o&&I.popupWithSlots).className,Xe.popup,Y()),onContextMenu:dp,children:[n.header==null?null:(0,G.jsx)(`div`,{className:V(R.header,Y(`header`)),children:n.header}),n.virtual?(0,G.jsx)(Rt,{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})]})})})})});Cp.displayName=`ContextMenuHost`;var wp={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 Tp(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 Ep=`data-checked`,Dp=`data-unchecked`;function Op(e){return{checked(t){return e.indeterminate?{}:t?{[Ep]:``}:{[Dp]:``}},...Te}}var kp=K.createContext(void 0);function Ap(){return K.useContext(kp)}var jp=K.createContext(void 0);function Mp(){let e=K.useContext(jp);if(e===void 0)throw Error(Ct(14));return e}var Np=`data-parent`,Pp=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:S,...C}=e,{clearErrors:w}=xe(),{disabled:T,name:E,setDirty:D,setFilled:O,setTouched:k,state:ee,validationMode:A,validityData:te,validation:j}=Ke(),ne=pp(),{labelId:re,registerControlId:ie,getDescriptionProps:ae}=ye(),N=Ap(),oe=N?.allValues===void 0?void 0:N.parent,se=oe!==void 0,ce=T||ne.disabled||N?.disabled||o,le=E??d,P=v??le,ue=St(),de=N?.registerControlId!==ie,pe=Ye({id:c||void 0,enabled:de}),he=y?pe:ue,ge={};se&&(p?ge=oe.getParentProps():P!==void 0&&(ge=oe.getChildProps(P)));let{checked:F=n,indeterminate:_e=l,onCheckedChange:ve,...be}=ge,Se=N?.value,Ce=K.useRef(null),we=b(ce,Ce),{getButtonProps:Te,buttonRef:I}=yt({disabled:ce,native:y}),Ee=N?.validation??j,[De,Oe]=x({controlled:P!==void 0&&Se!==void 0&&!p?Se.includes(P):F,default:i,name:`Checkbox`,state:`checked`}),L=se?!!F:De,ke=se&&_e||l;fe(Ce,ue,De,void 0,!N&&!ce,d);let Ae=oe?.registerChildId,je=K.useRef(null),Me=Ee.registerInput,Ne=N?P:void 0,Pe=K.useCallback(e=>Me(e,{controlRef:Ce,value:Ne}),[Me,Ne]),Fe=wt(u,je,p?void 0:Pe),Ie=M(a,re,je,!y,pe,C[`aria-label`]);Tt(()=>{je.current&&(je.current.indeterminate=ke),N||O(De)},[De,ke,N,O]),me(De,()=>{N||(w(le),D(De!==te.initialValue),Ee.change(De))});let Le=vt({checked:De,disabled:ce,form:s,name:p?void 0:le,id:y?void 0:pe,required:g,ref:Fe,style:le?_t:mt,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=Mt(Et,e.nativeEvent);if(f?.(t,n),!n.isCanceled&&(ve?.(t,n),!n.isCanceled&&(Oe(t),P!==void 0&&N!==void 0&&!p&&!se))){let e=t?[...N.value,P]:N.value.filter(e=>e!==P);N.setValue(e,n)}},onClick(e){e.stopPropagation()},onFocus(){Ce.current?.focus()}},v===void 0?lt:{value:(N?De&&v:v)||``},ae,e=>Ee.getValidationProps(ce,e));K.useEffect(()=>{if(!oe||P===void 0)return;let e=oe.disabledStatesRef.current;return e.set(P,ce),()=>{e.delete(P)}},[oe,ce,P]);let R=K.useMemo(()=>({...ee,checked:L,disabled:ce,readOnly:m,required:g,indeterminate:ke}),[ee,L,ce,m,g,ke]),Re=Op(R),ze=ht(`span`,e,{state:R,ref:[I,Ce,t],props:[{id:he,role:`checkbox`,"aria-checked":ke?`mixed`:L,"aria-readonly":m||void 0,"aria-required":g||void 0,"aria-labelledby":Ie,[Np]:p?``:void 0,onFocus(){we(!0)},onBlur(){let e=je.current;e&&(k(!0),we(!1),A===`onBlur`&&Ee.commit(N?Se:e.checked))},onKeyDown(e){if(e.key!==`Enter`||(e.preventBaseUIHandler(),e.defaultPrevented))return;let t=je.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),kt(n).queueMicrotask(()=>{e.preventDefault=i,r.preventDefault=a,o||Tp(t)?.click()})},onClick(e){if(m||ce)return;e.preventDefault();let t=je.current;t&&pt(t,e)}},C,be,Te,ae,e=>Ee.getValidationProps(ce,e)],stateAttributesMapping:Re}),Be=ze.props.id;return Tt(()=>{if(Ae&&!p&&P!==void 0&&Be!==void 0)return Ae(P,Be)},[Ae,p,P,Be]),(0,G.jsxs)(jp.Provider,{value:R,children:[ze,!De&&!N&&le&&!p&&_!==void 0&&(0,G.jsx)(`input`,{type:`hidden`,form:s,name:le,value:_,disabled:ce}),(0,G.jsx)(`input`,{...Le,suppressHydrationWarning:!0})]})}),Fp=K.forwardRef(function(e,t){let{render:n,className:r,style:i,keepMounted:a=!1,...o}=e,s=Mp(),c=s.checked||s.indeterminate,{mounted:l,transitionStatus:u,setMounted:d}=Ot(c),f=K.useRef(null),p={...s,transitionStatus:u};dt({batch:!0,enabled:!c,open:c,ref:f,onComplete(){c||d(!1)}});let m={...Op(s),...At},h=a||l,g=ht(`span`,e,{ref:[t,f],state:p,stateAttributesMapping:m,props:o});return h?g:null}),Ip=Pt({block:`checkbox`,dataAttributes:[`shape`],elements:[`checkbox`,`indicator`,`text`]});Pt({block:`checkbox-group`,dataAttributes:[`horizontal`],elements:[`item`]});var Lp=(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`?wp.iconSquare:wp.iconCircle,_=(0,G.jsx)(Pp,{disabled:u,indeterminate:d,onCheckedChange:l,...r?void 0:Nt({shape:t}),...f,...B([wp.root,xt.info,!m&&wp.defaultSize,t===`square`?!m&&wp.defaultSquare:wp.circle],V(!r&&Ip(),Ip(`checkbox`),r?a?.checkbox:i,a?.checkbox),h),children:(0,G.jsx)(Fp,{...B(wp.indicator,Ip(`indicator`)),children:d?(0,G.jsx)(We,{size:p,strokeWidth:3,...z(g)}):(0,G.jsx)(D,{size:p,strokeWidth:3,...z(g)})})});return r?(0,G.jsxs)(`label`,{...Nt({shape:t}),...B(wp.label,V(Ip(),i,a?.wrapper),{...m&&{gap:Math.floor(p/2)},...s,...o?.wrapper}),children:[_,(0,G.jsx)(lp,{as:`span`,className:V(Ip(`text`),a?.text),style:o?.text,...c,type:u?`secondary`:c?.type,children:r})]}):_});Lp.displayName=`Checkbox`;var Rp=Object.assign(Lp,{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}},zp=[0,1,2],Bp=25,Vp=zp.flatMap(e=>zp.map(t=>({x:Bp+e*Bp,y:Bp+t*Bp}))),Hp=zp.slice(0,-1).flatMap(e=>zp.flatMap(t=>zp.map(n=>({x1:Bp+e*Bp,x2:Bp+(e+1)*Bp,y1:Bp+t*Bp,y2:Bp+n*Bp})))),Up=[0,1,2],Wp=(e,t,n)=>Math.max(e,n*100/t),Gp=(0,K.memo)(({px:e})=>{let t={"--spin-node-size":`${Wp(6,e,2)}px`,"--spin-particle-size":`${Wp(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:Hp.map(e=>(0,G.jsx)(`line`,{...e,...z(X.networkLine)},`${e.x1}-${e.y1}-${e.y2}`))}),Vp.map(({x:e,y:t},n)=>(0,G.jsx)(`i`,{...z(X.networkNode),style:{animationDelay:`${n*.2}s`,left:e,top:t}},`${e}-${t}`)),Up.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)})]})})});Gp.displayName=`NetworkGlyph`;var Kp=Pt({block:`spin`,dataAttributes:[`size`,`variant`],elements:[`indicator`,`overlay`,`tip`]}),qp={large:32,middle:20,small:14},Jp=e=>typeof e==`number`?e:qp[e],Yp=(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)(()=>Jp(a),[a]),f=(0,K.useMemo)(()=>{if(n)return n;if(l===`network`)return(0,G.jsx)(Gp,{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)(bt,{spin:!0,...z(X.glyph),icon:Fe,size:d})},[n,l,r,d]);if(!o)return e??null;let p=Nt({size:typeof a==`string`?a:void 0,variant:l});return e?(0,G.jsxs)(`div`,{ref:i,...B(X.wrapper,V(Kp(),t),s),...p,...u,children:[e,(0,G.jsxs)(`div`,{"aria-busy":!0,"aria-live":`polite`,...B(X.overlay,Kp(`overlay`)),role:`status`,children:[(0,G.jsx)(`span`,{"aria-hidden":!0,...B(X.glyphBox,Kp(`indicator`)),children:f}),c&&(0,G.jsx)(`span`,{...B(X.tip,Kp(`tip`)),children:c})]})]}):(0,G.jsx)(`div`,{"aria-busy":!0,"aria-live":`polite`,ref:i,role:`status`,...B(X.root,V(Kp(),t),s),...p,...u,children:(0,G.jsx)(`span`,{"aria-hidden":!0,...B(X.glyphBox,Kp(`indicator`)),children:f})})});Yp.displayName=`Spin`;var Xp=(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))(Xp||{}),Zp=[0,1],Qp=[1,0],$p=[2,3],em=[3,2],tm={L:Zp,M:Qp,Q:$p,H:em},nm=/^\d*$/,rm=/^[A-Z0-9 $%*+./:-]*$/,im=`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:`,am=1,om=40,sm=3,cm=3,lm=40,um=10,dm=[[-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]],fm=[[-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]],pm=class{constructor(e,t,n,r){if(this.version=e,this.ecc=t,e<am||e>om)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,Xp.Timing),this.setFunctionModule(e,6,e%2==0,Xp.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,hm(r,e));this.setFunctionModule(8,7,hm(r,6)),this.setFunctionModule(8,8,hm(r,7)),this.setFunctionModule(7,8,hm(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,hm(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,hm(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,hm(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=hm(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,Xp.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,Xp.Alignment)}setFunctionModule(e,t,n,r=Xp.Function){this.modules[t][e]=n,this.types[t][e]=r}addEccAndInterleave(e){let t=this.version,n=this.ecc;if(e.length!==Am(t,n))throw RangeError(`Invalid argument`);let r=fm[n[0]][t],i=dm[n[0]][t],a=Math.floor(km(t)/8),o=r-a%r,s=Math.floor(a/r),c=[],l=jm(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=Mm(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(km(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]=hm(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+=sm:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*lm),n=this.modules[t][a],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*lm}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+=sm:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*lm),n=this.modules[a][t],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*lm}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+=cm)}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*um,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 mm(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 hm(e,t){return!!(e>>>t&1)}var gm=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()}},_m=[1,10,12,14],vm=[2,9,11,13],ym=[4,8,16,16];function bm(e,t){return e[Math.floor((t+7)/17)+1]}function xm(e){let t=[];for(let n of e)mm(n,8,t);return new gm(ym,e.length,t)}function Sm(e){if(!Tm(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);mm(Number.parseInt(e.substring(n,n+r),10),r*3+1,t),n+=r}return new gm(_m,e.length,t)}function Cm(e){if(!Em(e))throw RangeError(`String contains unencodable characters in alphanumeric mode`);let t=[],n=0;for(;n+2<=e.length;n+=2){let r=im.indexOf(e.charAt(n))*45;r+=im.indexOf(e.charAt(n+1)),mm(r,11,t)}return n<e.length&&mm(im.indexOf(e.charAt(n)),6,t),new gm(vm,e.length,t)}function wm(e){return e===``?[]:Tm(e)?[Sm(e)]:Em(e)?[Cm(e)]:[xm(Om(e))]}function Tm(e){return nm.test(e)}function Em(e){return rm.test(e)}function Dm(e,t){let n=0;for(let r of e){let e=bm(r.mode,t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}function Om(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 km(e){if(e<am||e>om)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 Am(e,t){return Math.floor(km(e)/8)-dm[t[0]][e]*fm[t[0]][e]}function jm(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]=Nm(t[e],n),e+1<t.length&&(t[e]^=t[e+1]);n=Nm(n,2)}return t}function Mm(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]^=Nm(t,e))}return n}function Nm(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 Pm(e,t,n=1,r=40,i=-1,a=!0){if(!(am<=n&&n<=r&&r<=om)||i<-1||i>7)throw RangeError(`Invalid value`);let o,s;for(o=n;;o++){let n=Am(o,t)*8,i=Dm(e,o);if(i<=n){s=i;break}if(o>=r)throw RangeError(`Data too long`)}for(let e of[Qp,$p,em])a&&s<=Am(o,e)*8&&(t=e);let c=[];for(let t of e){mm(t.mode[0],4,c),mm(t.numChars,bm(t.mode,o),c);for(let e of t.getData())c.push(e)}let l=Am(o,t)*8;mm(0,Math.min(4,l-c.length),c),mm(0,(8-c.length%8)%8,c);for(let e=236;c.length<l;e^=253)mm(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 pm(o,t,u,i)}function Fm(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`?wm(e):Array.isArray(e)?[xm(e)]:void 0;if(!c)throw Error(`uqr only supports encoding string and binary data, but got: ${typeof e}`);let l=Pm(c,tm[n],i,a,o,r),u=Im({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 Im(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=Xp.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 Lm={"qrCode.expired":`Expired`,"qrCode.loading":`Loading`,"qrCode.refresh":`Refresh`},Rm=(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},zm=Pt({block:`qr-code`,dataAttributes:[`status`,`bordered`],elements:[`code`,`icon`,`overlay`,`title`,`refresh`]}),Bm={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}},Vm=.22,Hm=(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}=Gt(Lm),m=c??160,{count:h,path:g}=(0,K.useMemo)(()=>{try{let{data:e}=Fm(d,{border:0,ecc:a?`H`:i}),t=a?Math.ceil(e.length*Vm)|1:0;return{count:e.length,path:Rm(e,t)}}catch{return{count:0,path:``}}},[d,a,i]);return(0,G.jsxs)(`div`,{ref:s,...B([Bm.root,t&&Bm.bordered],V(zm(),n),e===void 0?u:{background:e,...u}),...Nt({bordered:t,status:l}),...f,children:[(0,G.jsxs)(`svg`,{"aria-label":d,className:zm(`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([Bm.icon,c===void 0&&Bm.iconDefaultSize],zm(`icon`),c===void 0?void 0:{height:m*Vm,width:m*Vm}),children:a}),l===`loading`&&(0,G.jsx)(`span`,{"aria-label":p(`qrCode.loading`),...B(Bm.overlay,zm(`overlay`)),role:`status`,children:(0,G.jsx)(Yp,{className:B(Bm.spin).className})}),l===`expired`&&(0,G.jsxs)(`span`,{...B(Bm.overlay,zm(`overlay`)),children:[(0,G.jsx)(`span`,{...B(Bm.overlayTitle,zm(`title`)),children:p(`qrCode.expired`)}),o&&(0,G.jsxs)(`button`,{...B([xt.info,Bm.refresh],zm(`refresh`)),type:`button`,onClick:o,children:[(0,G.jsx)(bt,{icon:es,size:14}),p(`qrCode.refresh`)]})]})]})});Hm.displayName=`QRCode`;var Um=e({Board:()=>rp,Group:()=>Wm,Item:()=>Zf}),Wm=Rf(Hd),Gm=e({Reorder:()=>Um,a:()=>Ba,abbr:()=>_a,address:()=>Ma,animate:()=>$i,area:()=>Ci,article:()=>xa,aside:()=>Ia,audio:()=>Ai,b:()=>la,base:()=>Wa,bdi:()=>Pi,bdo:()=>Vi,big:()=>Ta,blockquote:()=>pa,body:()=>Yi,button:()=>Gi,canvas:()=>yi,caption:()=>Ja,circle:()=>oo,cite:()=>Di,clipPath:()=>no,code:()=>qr,col:()=>Qn,colgroup:()=>Qa,create:()=>Pa,data:()=>Zr,datalist:()=>ar,dd:()=>nr,defs:()=>Fr,del:()=>oa,desc:()=>Kn,details:()=>ra,dfn:()=>kr,dialog:()=>Mr,div:()=>Rr,dl:()=>cr,dt:()=>_r,ellipse:()=>Er,em:()=>Wr,embed:()=>uo,feBlend:()=>Yn,feColorMatrix:()=>ii,feComponentTransfer:()=>mr,feComposite:()=>ti,feConvolveMatrix:()=>si,feDiffuseLighting:()=>dr,feDisplacementMap:()=>Cr,feDistantLight:()=>ka,feDropShadow:()=>br,feFlood:()=>pi,feFuncA:()=>ui,feFuncB:()=>gi,feFuncG:()=>Vr,feFuncR:()=>Un,feGaussianBlur:()=>Bi,feImage:()=>Ua,feMerge:()=>ba,feMergeNode:()=>Fa,feMorphology:()=>na,feOffset:()=>Ei,fePointLight:()=>wa,feSpecularLighting:()=>za,feSpotLight:()=>Ni,feTile:()=>fa,feTurbulence:()=>qa,fieldset:()=>Li,figcaption:()=>Wi,figure:()=>Oa,filter:()=>ga,footer:()=>Qi,foreignObject:()=>Ji,form:()=>Si,g:()=>Za,h1:()=>lo,h2:()=>ki,h3:()=>ao,h4:()=>Xr,h5:()=>tr,h6:()=>to,head:()=>ei,header:()=>sr,hgroup:()=>ir,hr:()=>Lr,html:()=>ca,i:()=>Jn,iframe:()=>aa,image:()=>jr,img:()=>Pr,input:()=>Br,ins:()=>ur,kbd:()=>yr,keygen:()=>Or,label:()=>Kr,legend:()=>po,li:()=>Zn,line:()=>oi,linearGradient:()=>gr,link:()=>ri,main:()=>li,map:()=>pr,mark:()=>Tr,marker:()=>ja,mask:()=>Sr,menu:()=>hi,menuitem:()=>fi,metadata:()=>vi,meter:()=>Ur,nav:()=>Gn,object:()=>Ri,ol:()=>Va,optgroup:()=>va,option:()=>Na,output:()=>ea,p:()=>wi,param:()=>Sa,path:()=>La,pattern:()=>ji,picture:()=>ua,polygon:()=>Ga,polyline:()=>Fi,pre:()=>Hi,progress:()=>Ea,q:()=>ma,radialGradient:()=>Xi,rect:()=>Ki,rp:()=>bi,rt:()=>Ya,ruby:()=>so,s:()=>Oi,samp:()=>ro,script:()=>Jr,section:()=>$n,select:()=>$a,small:()=>Qr,source:()=>or,span:()=>rr,stop:()=>Ir,strong:()=>sa,style:()=>qn,sub:()=>ia,summary:()=>Ar,sup:()=>Nr,svg:()=>zr,symbol:()=>lr,table:()=>vr,tbody:()=>Dr,td:()=>Gr,text:()=>fo,textPath:()=>Xn,textarea:()=>ai,tfoot:()=>hr,th:()=>ni,thead:()=>ci,time:()=>fr,title:()=>wr,tr:()=>Aa,track:()=>xr,tspan:()=>mi,u:()=>di,ul:()=>_i,use:()=>Hr,video:()=>Wn,view:()=>zi,wbr:()=>Ha,webview:()=>ya}),Km=r();function qm(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 Jm=ut(),Ym=K.useInsertionEffect,Xm=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0?K.useLayoutEffect:K.useEffect,Zm=Ym||Xm,Qm=e=>{let t=K.useRef([e,(...e)=>t[0](...e)]).current;return Zm(()=>{t[0]=e}),t[1]},$m=[`popstate`,`pushState`,`replaceState`,`hashchange`],eh=[],th=()=>eh.forEach(e=>e()),nh=e=>(eh.push(e)===1&&$m.forEach(e=>addEventListener(e,th)),()=>{eh=eh.filter(t=>t!==e),eh.length||$m.forEach(e=>removeEventListener(e,th))}),rh=(e,t)=>(0,Jm.useSyncExternalStore)(nh,e,t),ih=()=>location.search,ah=({ssrSearch:e}={})=>rh(ih,e==null?ih:()=>e),oh=()=>location.pathname,sh=({ssrPath:e}={})=>rh(oh,e==null?oh:()=>e),ch=(e,{replace:t=!1,state:n=null}={})=>history[t?`replaceState`:`pushState`](n,``,e),lh=e=>[sh(e),ch],uh=Symbol.for(`wouter_v3`);if(typeof history<`u`&&window[uh]===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,uh,{value:!0})}var dh=(e=``)=>e===`/`?``:e,fh=(e,t)=>e[0]===`~`?e.slice(1):dh(t)+e,ph=(e,t)=>(e=mh(dh(e)),t=mh(t),!e||(t.toLowerCase()+`/`).startsWith(e.toLowerCase()+`/`)?t.slice(e.length)||`/`:`~`+t),mh=e=>{try{return e.includes(`%`)?decodeURI(e):e}catch{return e}},hh={hook:lh,searchHook:ah,parser:qm,base:``,ssrPath:void 0,ssrSearch:void 0,ssrContext:void 0,hrefs:e=>e,aroundNav:(e,t,n)=>e(t,n)},gh=(0,K.createContext)(hh),_h=()=>(0,K.useContext)(gh);(0,K.createContext)({});var vh=e=>{let[t,n]=e.hook(e);return[ph(e.base,t),Qm((t,r)=>e.aroundNav(n,fh(t,e.base),r))]},yh=()=>vh(_h());(0,K.forwardRef)((e,t)=>{let n=_h(),[r,i]=vh(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=Qm(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 bh=0,xh=0,Sh=new Set;function Ch(){xh||bh>0||Sh.size===0||(xh=requestAnimationFrame(()=>{if(xh=0,bh>0)return;let e=[...Sh];Sh.clear();for(let t of e)t()}))}function wh(){return bh+=1,()=>{--bh,Ch()}}function Th({label:e}){return(0,K.useEffect)(wh,[]),(0,G.jsx)(s,{stack:!0,label:e,size:32})}var Eh={claude:`Claude Code`,codex:`Codex`,antigravity:`Antigravity`};function Dh(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 Oh=e=>e.kind!==`none`&&e.kind!==`login`,kh=e=>e.kind===`quiet`||e.kind===`command`&&e.stuck===!0,Ah=e=>e.kind===`menu`||e.kind===`login`||e.kind===`error`?`amber`:e.kind===`quiet`||e.kind===`command`&&e.stuck?`grey`:null,jh=(e,t)=>Math.max(1,Math.floor((t-e)/6e4));function Mh(e,t,n,r){let i=jh(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 Nh=new Set([`thinking`,`running`,`your-turn`,`needs-approval`]),Ph=new Set([`starting`,`queued`]),Fh=e=>e.daemon!==null&&Ah(e.daemon.attention)===`amber`;function Ih(e){return(e.daemon?Ah(e.daemon.attention)??(Ph.has(e.daemon.state)?`grey`:null):null)??(e.state===`needs-approval`?`amber`:null)}var Lh={"needs-approval":1,running:2,thinking:3,"your-turn":5};function Rh(e){if(Fh(e))return 0;let t=Ih(e);return e.state?t===`grey`&&e.state!==`needs-approval`?4:Lh[e.state]:t===`grey`?4:e.daemon?.state===`running`?2:5}function zh(e,t){let n=e.filter(e=>Nh.has(e.state)),r=t&&t.state!==`ended`?t:null,i=r?Dh(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:Eh[r.harness]??r.harness,state:null,since:r.attention.since,turn:null,daemon:r}),a.sort((e,t)=>Rh(e)-Rh(t))}async function Bh(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 Vh(e){return{screen:async()=>{let t=await Bh({artifact:e,op:`agent-screen`});return Array.isArray(t?.lines)?t.lines.filter(e=>typeof e==`string`):[]},input:async t=>{await Bh({artifact:e,op:`agent-input`,...t})}}}var Hh=e=>new URLSearchParams(e).get(`agent`)===`1`;function Uh(){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(vo(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 Wh=(0,K.lazy)(()=>_(async()=>{let{AgentDock:e}=await import(`./AgentDock-BMyCZfOA.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]),import.meta.url).then(({AgentDock:e})=>({default:e})));function Gh({artifact:e}){let{sessions:t,daemon:n}=Uh(),r=n.find(t=>t.artifact===e)??null,i=(0,K.useMemo)(()=>Vh(e),[e]),a=zh(t.filter(t=>t.artifacts.includes(e)),r);return a.length===0?null:(0,G.jsx)(K.Suspense,{fallback:null,children:(0,G.jsx)(Wh,{trusted:!0,rows:a,transport:r?i:null})})}var Kh=[`private`,`public`,`total`,`publishes`,`storage`,`objects`],qh=e=>e===`preparing`||e===`uploading`||e===`publishing`;function Jh(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 Yh=[`1d`,`7d`,`30d`,`never`],Xh=(e,t)=>!!e?.expiresAt&&Date.parse(e.expiresAt)<=t;function Zh(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 Qh(e,t){return e===null?null:e?`upToDate`:t?`localChangesAuto`:`localChanges`}var $h=2e3,eg=1e3,tg=3e5;async function Z(e,t,n){try{let r=await fetch(m(`/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 ng=null,rg=null,ig,ag=null,og=new Set;function sg(){return rg??=Z(`GET`,`status`).then(e=>{if(rg=null,!e.ok)return null;ng=e.json;for(let e of og)e(ng);return ng}),rg}function cg(e){return og.add(e),ag??=_o(e=>{(e.type===`cloud-publication`||e.type===`cloud-published`)&&(clearTimeout(ig),ig=setTimeout(()=>void sg(),eg))}),()=>{og.delete(e),og.size>0||(ag?.(),ag=null,clearTimeout(ig))}}function lg(){let[e,t]=(0,K.useState)(ng),[n,r]=(0,K.useState)(!1),i=(0,K.useRef)(null),a=(0,K.useCallback)(()=>sg(),[]),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>tg)&&o()},$h)},[a,o]);return(0,K.useEffect)(()=>{let e=cg(t);return a(),()=>{e(),o()}},[a,o]),{status:e,refresh:a,login:s,waitingForLogin:n}}var ug=(0,K.createContext)(null);function dg({pageWindow:e,children:t}){return(0,G.jsx)(ug.Provider,{value:e??null,children:t})}var fg=()=>(0,K.useContext)(ug)??window;function pg(e,t){if(t===null)return e;let n=new URL(e);return n.searchParams.set(`page`,t),n.href}function mg(){let e=fg(),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 hg=[`B`,`KB`,`MB`,`GB`];function gg(e){let t=e,n=0;for(;t>=1024&&n<hg.length-1;)t/=1024,n++;return`${n===0?t:Number(t.toFixed(1))} ${hg[n]}`}function _g(e,t){return typeof e==`string`&&g.exists(`errors.${e}`)?g.t(`errors.${e}`):t}var vg=e=>typeof e==`object`&&!!e&&Kh.includes(e.kind)&&typeof e.max==`number`;function yg({kind:e,max:t}){return g.t(`planLimit.${e}`,{max:e===`storage`?gg(t):t})}function bg(e,t){return e.code===`plan_limit`&&vg(e.limit)?yg(e.limit):_g(e.code,typeof e.error==`string`?e.error:t)}var xg=!1,Sg=new Set,Cg=e=>{if(xg!==e){xg=e;for(let e of Sg)e()}},wg=()=>Cg(!0),Tg=()=>Cg(!1),Eg=()=>xg,Dg=e=>(Sg.add(e),()=>Sg.delete(e)),Og=()=>(0,K.useSyncExternalStore)(Dg,Eg,Eg),kg=e=>e?e.replace(/\/+$/,``):null,Ag=(e,t)=>{let n=kg(e);return n?`${n}${t?.toLowerCase().startsWith(`zh`)?`/zh`:``}`:null},jg=e=>{let t=kg(e);return t?`${t}/`:null},Mg=(e,t)=>{let n=kg(e);return n?`${n}/u/${encodeURIComponent(t)}`:null},Ng=e=>{let t=kg(e);return t?`${t}/billing`:null},Pg={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 Fg({publication:e,published:t,publishedAt:n,online:r,onPublish:a,compact:s=!1,busy:c=!1}){let{t:l,i18n:u}=o(),d=wf(),f=e?.phase??(t?`published`:`waiting`),p=t&&f!==`published`,m=qh(f),h=l(`publication.${p?`update_${f}`:f}`),g=m?Fe:f===`failed`?T:f===`published`?rt:Bo,_=f===`failed`?Pg.failed:f===`published`?Pg.success:void 0,v=(0,G.jsx)(bt,{"aria-hidden":`true`,icon:g,size:s?14:16,spin:m&&!d});if(s)return(0,G.jsxs)(`span`,{role:`status`,...i(Pg.summary,_),children:[v,h]});let y=e?.publishedAt??n,b=a&&!m&&f!==`published`&&f!==`not-ready`;return(0,G.jsxs)(`section`,{"aria-label":l(`publication.label`),...i(Pg.card,_),children:[(0,G.jsxs)(`div`,{role:`status`,className:`x78zum5 x6s0dn4 x167g77z xfifm61 x1s688f`,children:[v,h]}),(0,G.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:l(p&&f===`waiting`?`publication.updateWaitingDescription`:p&&f===`failed`?`publication.updateFailedDescription`:`publication.${f}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,b?(0,G.jsxs)(`button`,{disabled:c,type:`button`,onClick:a,className:`x78zum5 x6s0dn4 xl56j7k x17d4w8g x1rz828m x36usyh xc342km x1sxf85j x19ckca5 xs0jrwl xln7xf2 xfifm61 x1ypdohk`,children:[(0,G.jsx)(Co,{"aria-hidden":`true`,size:14}),l(f===`failed`?`publication.retry`:`publication.publishNow`)]}):null,!m&&f!==`published`?(0,G.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:l(r===!1?`publication.offline`:!a&&r===!0?`publication.updateLocal`:e?.autoPublish?`publication.autoPublish`:`publication.manualPublish`)}):null,p?(0,G.jsxs)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud x1y1aw1k x178xt8z x13fuv20 xxu5053`,children:[l(`publication.previousVersion`),y?(0,G.jsxs)(G.Fragment,{children:[` `,(0,G.jsx)(`time`,{dateTime:y,children:new Date(y).toLocaleString(u.language)})]}):null]}):null]})}var Ig=(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}},Lg={pad:{kg3NbH:`x5k8d2m`,$$css:!0}},Rg=[{value:`private`,label:`share.onlyMe`,Icon:So},{value:`public`,label:`share.anyone`,Icon:De}];function zg({busy:e,error:t,onCopyFailed:n,onPublish:r,onVisibility:a,readOnly:s,rootVisibility:c,state:l,title:u,type:d,url:f,uses:p}){let{t:m}=o(),h=Ig(c,l),g=m(l===`public`?`cascade.tag.public`:l===`private`?`cascade.tag.private`:l===`unpublished`?`beside.unpublished`:`beside.unsupported`),_=async()=>{if(f)try{await navigator.clipboard.writeText(f)}catch{n?.()}},v=!s&&l!==`unsupported`,y=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)(Wo,{size:12}),m(`beside.title`)]}),(0,G.jsxs)(`span`,{...i(y.name,Lg.pad),children:[(0,G.jsx)(`span`,{...i(y.type),children:d}),(0,G.jsx)(`span`,{...i(y.title),children:u}),(0,G.jsx)(`span`,{...i(y.tag,h&&y.warnTag),children:g})]}),p||h?(0,G.jsxs)(`span`,{...i(y.meta,h&&y.warn,Lg.pad),children:[p?m(`referrers.uses`,{count:p}):null,p&&h?` · `:null,h?(0,G.jsx)(`span`,{"data-beside-hidden":``,children:m(`beside.hidden`)}):null]}):null,v||l!==`unsupported`?(0,G.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n x5k8d2m`,children:[v&&l===`unpublished`?(0,G.jsx)(L,{"data-beside-publish":``,disabled:e,size:`small`,onClick:()=>r?.(),children:m(`beside.publish`)}):null,v&&l!==`unpublished`?(0,G.jsx)(`span`,{role:`radiogroup`,className:`x3nfvp2 x1i3ajwb x1kogg8i xahzvm9`,children:Rg.map(({value:t,label:n,Icon:r})=>(0,G.jsxs)(`button`,{"aria-checked":t===l,"data-beside-visibility":t,disabled:e,role:`radio`,type:`button`,onClick:()=>t!==l&&a?.(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===l|0],children:[(0,G.jsx)(r,{size:11}),m(n)]},t))}):null,(0,G.jsx)(`span`,{className:`x98rzlu`}),(0,G.jsx)(L,{"aria-label":m(`beside.copyLink`),"data-beside-copy":``,disabled:!f,icon:Ne,size:`small`,onClick:()=>void _()})]}):null,t?(0,G.jsx)(`span`,{"data-beside-error":``,...i(y.meta,y.error,Lg.pad),children:t}):null]})}var Bg=[`unpublished`,`stale`,`private`,`withdrawn`],Vg=[`unpublished`,`stale`];function Hg(e,t,n){let r=new Map(e.map(e=>[e.artifact,e])),i=e=>Bg.includes(e.state)&&(t[e.artifact]??Vg.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:Bg.includes(e.state),...a?{reason:a}:{}}:{...r,checked:!1,selectable:!1,reason:`upstream`,upstream:e.via??e.parents[0]}})}var Ug=e=>e.selectable?e.state===`private`?`private`:e.state===`withdrawn`?`skipped`:`publish`:e.state===`ready`?`ready`:`skipped`;function Wg({busy:e,error:t,includeRoot:n,items:r,offline:a,onPublish:s,results:c,rootVisibility:l}){let{t:u}=o(),[d,f]=(0,K.useState)(!1),[p,m]=(0,K.useState)({}),h=(0,K.useMemo)(()=>{let e=Hg(r,p);return a?e.map(e=>e.state===`private`?e:{...e,checked:!1,selectable:!1,reason:e.reason??`offline`}):e},[r,p,a]);if(!r.length)return null;let g=e=>r.find(t=>t.artifact===e)?.title??e,_=h.filter(e=>e.state!==`ready`&&e.state!==`private`).length,v=h.filter(e=>e.state===`private`&&!e.checked).length,y=h.filter(e=>e.checked),b=new Map((c??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),x=h.some(e=>e.state!==`ready`),S=()=>s(y.filter(e=>e.state!==`private`).map(e=>e.artifact),y.filter(e=>e.state===`private`).map(e=>e.artifact)),C=e=>{let t=b.get(e.artifact);return t?.error?{text:t.error.error,tone:Q.error}:e.reason===`offline`?{text:u(`cascade.offline`),tone:null}:e.reason===`upstream`?{text:u(`cascade.upstream`,{via:g(e.upstream??``)}),tone:null}:{text:[e.state===`blocked`?e.reason??``:e.state===`private`?u(`cascade.private`):e.state===`ready`?``:u(`cascade.${e.state}`),e.via?u(`cascade.via`,{via:g(e.via)}):``].filter(Boolean).join(` · `),tone:e.state===`private`?Q.warn:null}},w=[`publish`,`private`,`skipped`,`ready`],T=x?(0,G.jsx)(L,{block:!0,"data-cascade-publish":``,disabled:!y.length||e,loading:e,type:n?`primary`:`default`,onClick:S,...i(Q.action),children:u(n?`cascade.publishWithRoot`:`cascade.publish`,{count:y.length})}):null;return(0,G.jsxs)(`div`,{...i(Q.root),children:[(0,G.jsxs)(`button`,{"aria-expanded":d,"data-cascade-summary":``,type:`button`,onClick:()=>f(e=>!e),...i(Q.summary),children:[(0,G.jsx)(`span`,{...i(Q.icon),children:(0,G.jsx)(Ce,{size:13})}),(0,G.jsxs)(`span`,{...i(Q.text),children:[(0,G.jsx)(`span`,{...i(Q.lead),children:_?u(`cascade.summaryPending`,{total:r.length,pending:_}):u(`cascade.summaryReady`,{total:r.length})}),v?(0,G.jsx)(`span`,{...i(Q.sub),children:u(`cascade.summaryLocked`,{count:v})}):null,a?(0,G.jsx)(`span`,{...i(Q.sub),children:u(`cascade.offlineHint`)}):null]}),d?(0,G.jsx)(he,{size:14,...i(Q.chevron)}):(0,G.jsx)(k,{size:14,...i(Q.chevron)})]}),d?w.map(t=>{let n=h.filter(e=>Ug(e)===t);if(!n.length)return null;let r=u(t===`publish`?`cascade.group.publish.${l}`:`cascade.group.${t}`);return(0,G.jsxs)(`div`,{"data-cascade-group":t,children:[(0,G.jsxs)(`div`,{...i(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,...i(Q.item),children:[(0,G.jsx)(`span`,{...i(Q.check),children:(0,G.jsx)(Rp,{checked:t.checked,disabled:!t.selectable||e,onChange:e=>m(n=>({...n,[t.artifact]:e}))})}),(0,G.jsxs)(`span`,{...i(Q.body),children:[(0,G.jsxs)(`span`,{...i(Q.name),children:[(0,G.jsx)(`span`,{...i(Q.type),children:t.artifact.split(`/`)[0]}),(0,G.jsx)(`span`,{...i(Q.title),children:t.title}),t.state===`private`?(0,G.jsx)(`span`,{...i(Q.tag,Q.warnTag),children:u(`cascade.tag.private`)}):t.state===`ready`?(0,G.jsx)(`span`,{...i(Q.tag),children:u(`cascade.tag.${l}`)}):null]}),n.text?(0,G.jsx)(`span`,{...i(Q.meta,n.tone),children:n.text}):null]})]},t.artifact)})]},t)}):null,t?(0,G.jsx)(`span`,{...i(Q.meta,Q.error),children:t}):null,T]})}function Gg(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 Kg=[`private`,`unpublished`,`unlinked`,`ready`,`skipped`],qg=e=>e===`withdrawn`||e===`blocked`?`skipped`:e;function Jg({busy:e,cloudUnavailable:t,error:n,exclude:r,items:a,onPublish:s,results:c,rootVisibility:l}){let{t:u}=o(),[d,f]=(0,K.useState)(!1),[p,m]=(0,K.useState)({}),{shown:h,hidden:g,allPrivate:_,visible:v}=Gg(a,l,r);if(!v)return null;let y=e=>e.selectable&&(p[e.artifact]??e.checked),b=h.filter(y),x=new Map((c??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),S=e=>{let t=x.get(e.artifact)?.error?.error;if(t)return{text:t,tone:Q.error};let n=e.state===`blocked`?e.reason:e.state===`withdrawn`?u(`referrers.withdrawn`):``;return{text:[u(`referrers.uses`,{count:e.uses}),n].filter(Boolean).join(` · `),tone:null}},C=()=>s(b.filter(e=>e.state!==`private`).map(e=>e.artifact),b.filter(e=>e.state===`private`).map(e=>e.artifact));return(0,G.jsxs)(`div`,{...i(Q.root),children:[(0,G.jsxs)(`button`,{"aria-expanded":d,"data-referrer-summary":``,type:`button`,onClick:()=>f(e=>!e),...i(Q.summary),children:[(0,G.jsx)(`span`,{...i(Q.icon),children:(0,G.jsx)(Wt,{size:13})}),(0,G.jsxs)(`span`,{...i(Q.text),children:[(0,G.jsx)(`span`,{...i(Q.lead),children:u(`referrers.summary`,{total:h.length})}),(0,G.jsx)(`span`,{...i(Q.sub,Q.warn),children:u(_?`referrers.hiddenPrivate`:`referrers.hidden`,{count:g})}),t?(0,G.jsx)(`span`,{...i(Q.sub),children:u(`referrers.cloudUnavailable`)}):null]}),d?(0,G.jsx)(he,{size:14,...i(Q.chevron)}):(0,G.jsx)(k,{size:14,...i(Q.chevron)})]}),d?Kg.map(t=>{let n=h.filter(e=>qg(e.state)===t);return n.length?(0,G.jsxs)(`div`,{"data-referrer-group":t,children:[(0,G.jsxs)(`div`,{...i(Q.group),children:[(0,G.jsx)(`span`,{children:u(`referrers.group.${t}`)}),(0,G.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=S(t);return(0,G.jsxs)(`label`,{"data-referrer-item":t.artifact,...i(Q.item),children:[(0,G.jsx)(`span`,{...i(Q.check),children:(0,G.jsx)(Rp,{checked:y(t),disabled:!t.selectable||e,onChange:e=>m(n=>({...n,[t.artifact]:e}))})}),(0,G.jsxs)(`span`,{...i(Q.body),children:[(0,G.jsxs)(`span`,{...i(Q.name),children:[(0,G.jsx)(`span`,{...i(Q.type),children:`document`}),(0,G.jsx)(`span`,{...i(Q.title),children:t.title}),t.state===`private`?(0,G.jsx)(`span`,{...i(Q.tag,Q.warnTag),children:u(`cascade.tag.private`)}):t.state===`ready`?(0,G.jsx)(`span`,{...i(Q.tag),children:u(`cascade.tag.public`)}):null]}),(0,G.jsx)(`span`,{...i(Q.meta,n.tone),children:n.text})]})]},t.artifact)})]},t):null}):null,n?(0,G.jsx)(`span`,{...i(Q.meta,Q.error),children:n}):null,d?(0,G.jsx)(L,{block:!0,"data-referrer-publish":``,disabled:!b.length||e,loading:e,onClick:C,...i(Q.action),children:u(`referrers.publish`,{count:b.length})}):null]})}var Yg=864e5;function Xg({text:e,action:t,onConfirm:n,onCancel:r}){let{t:i}=o();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)(L,{"data-confirm":`no`,size:`small`,onClick:r,children:i(`common.cancel`)}),(0,G.jsx)(L,{"data-confirm":`yes`,size:`small`,type:`primary`,onClick:n,children:t})]})]})}function Zg({value:e,disabled:t,onExpiry:n,onRegenerate:r}){let{t:i,i18n:a}=o(),[s]=(0,K.useState)(()=>Date.now()),c=Xh(e,s),l=e.expiresAt?new Date(e.expiresAt).toLocaleDateString(a.language,{month:`short`,day:`numeric`}):null,u=e.expiresAt?c?i(`share.expired`,{date:l}):i(`share.expiresIn`,{count:Math.max(1,Math.ceil((Date.parse(e.expiresAt)-s)/Yg)),date:l}):i(`share.neverExpires`),d=Yh.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":c?``: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)(go,{disabled:t,options:d,placeholder:(0,G.jsx)(`span`,{...{0:{},1:{className:`x12vcgws`}}[!!c|0],children:u}),prefix:mo,size:`small`,style:{width:`auto`,minWidth:0,fontSize:11},value:null,onSelect:e=>n(e)})]}),(0,G.jsx)(L,{"data-key-regenerate":``,disabled:t,icon:Qo,outdent:`end`,size:`small`,style:{fontSize:11},type:`text`,onClick:r,children:i(`share.regenerate`)})]}),c?(0,G.jsx)(`p`,{className:`x8k27cj x1bo0w0s x1j6dyjg x37zpob`,children:i(`share.expiredNote`)}):null]})}var Qg=[{value:`private`,label:`share.onlyMe`,hint:`share.onlyMeHint`,Icon:So},{value:`key`,label:`share.keyHolders`,hint:`share.keyHint`,Icon:Jo},{value:`public`,label:`share.anyone`,hint:`share.anyoneHint`,Icon:De}],$g={private:{text:`share.removeKeyConfirm`,action:`share.removeKey`},public:{text:`share.makePublicConfirm`,action:`share.makePublic`},regenerate:{text:`share.regenerateConfirm`,action:`share.regenerate`}};function e_({beside:e,cascade:t,children:n,foot:r,onCopyFailed:i,onVisibility:a,profile:s,referrers:c,saving:l=!1,shareKey:u,status:d,url:f,visibility:p}){let{t:m}=o(),[h,g]=(0,K.useState)(!1),[_,v]=(0,K.useState)(null),[y]=(0,K.useState)(()=>Date.now());(0,K.useEffect)(()=>{if(!h)return;let e=setTimeout(()=>g(!1),2e3);return()=>clearTimeout(e)},[h]);let b=u?.active?`key`:p,x=b===`key`?u?.value?.url??null:f,S=async()=>{if(x)try{await navigator.clipboard.writeText(x),g(!0)}catch{i?.()}},C=e=>{e!==b&&(e===`key`?u?.onSelect():b===`key`?v(e):a(e))},w=()=>{_===`private`?u?.onRemove():_===`public`?a(`public`):_===`regenerate`&&u?.onRegenerate(),v(null)},T=b===`key`?u?.value??null:null,E=Xh(T,y);return(0,G.jsxs)(`div`,{className:`x78zum5 xdt5ytf x195vfkc x58rd6w xqfszdh xfifm61`,children:[d,(0,G.jsx)(`p`,{className:`x1coi2bq xfifm61 x1s688f`,children:m(`share.whoCanSee`)}),(0,G.jsx)(`div`,{"aria-label":m(`share.whoCanSee`),role:`radiogroup`,className:`x78zum5 xdt5ytf x195vfkc`,children:Qg.filter(({value:e})=>e!==`key`||u).map(({value:e,label:t,hint:n,Icon:r})=>(0,G.jsxs)(`button`,{"aria-checked":e===b,"data-visibility":e,disabled:l,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===b|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===b|0],children:(0,G.jsx)(r,{size:12})}),(0,G.jsxs)(`span`,{children:[(0,G.jsxs)(`span`,{className:`x1lliihq xfifm61 x1s688f xwn7fz2`,children:[m(t),e===`key`&&u?.locked?(0,G.jsx)(`span`,{"data-pro-badge":``,className:`xdzw4kq xm9j1uf xmkeg23 x1y0btm7 xgcsv5v x12oqio5 x1bo0w0s x1k6wstc x1s688f x1xxsxie`,children:m(`share.proBadge`)}):null]}),(0,G.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:m(n)})]})]},e))}),b===`public`&&s?(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z x16ngw23 x12ulsxz x1icxu4v x1bo0w0s x1j6dyjg xwn7fz2`,children:[(0,G.jsxs)(`span`,{children:[m(`share.showOnProfile`),s.path?(0,G.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:s.path}):null]}),(0,G.jsx)(`button`,{"aria-checked":s.shown,"aria-label":m(`share.showOnProfile`),"data-profile-switch":``,disabled:l,role:`switch`,type:`button`,onClick:()=>s.onChange(!s.shown),...{0:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x15dg6x3 x1ypdohk`},1:{className:`x1n2onr6 x1okw0bk xvy4d1p x1v9usgg x1717udv xc342km x1e6avla x1ypdohk x19ckca5`}}[!!s.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`}}[!!s.shown|0]})})]}):null,(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n`,children:[(0,G.jsx)(`input`,{readOnly:!0,"aria-label":m(`share.linkLabel`),"data-share-url":``,"data-struck":E?``:void 0,placeholder:m(b===`key`?`share.keyPending`:`share.linkPending`),value:x??``,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)(L,{disabled:!x,icon:xo,size:`small`,type:`primary`,onClick:()=>void S(),children:m(h?`share.copied`:`share.copy`)})]}),_?(0,G.jsx)(Xg,{action:m($g[_].action),text:m($g[_].text),onCancel:()=>v(null),onConfirm:w}):T&&u?(0,G.jsx)(Zg,{disabled:l,value:T,onExpiry:u.onExpiry,onRegenerate:()=>v(`regenerate`)}):null,r&&b!==`key`?(0,G.jsx)(`div`,{className:`x8k27cj xddlp02 x1j6dyjg`,children:r}):null,e?(0,G.jsx)(zg,{...e}):null,t?(0,G.jsx)(Wg,{...t}):null,c?(0,G.jsx)(Jg,{...c}):null,n]})}var t_=`ryugi.pendingCloudIntent`,n_=6e5;function r_(e,t){try{let n={artifact:e,intent:t,at:Date.now()};window.sessionStorage.setItem(t_,JSON.stringify(n))}catch{}}function i_(e){try{let t=window.sessionStorage.getItem(t_);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>n_?(typeof n.at==`number`&&Date.now()-n.at>n_&&window.sessionStorage.removeItem(t_),null):(window.sessionStorage.removeItem(t_),n.intent)}catch{return null}}function a_({origin:e}){let{t,i18n:n}=o(),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 o_=[{id:`share`,icon:Ce,titleKey:`cloudIntent.shareTitle`,descKey:`cloudIntent.shareDesc`},{id:`phone`,icon:is,titleKey:`cloudIntent.phoneTitle`,descKey:`cloudIntent.phoneDesc`},{id:`sync`,icon:Co,titleKey:`cloudIntent.syncTitle`,descKey:`cloudIntent.syncDesc`}],s_={share:`cloudIntent.shareCta`,phone:`cloudIntent.phoneCta`,sync:`cloudIntent.syncCta`},c_={share:`cloudIntent.sharePrivacy`,phone:`cloudIntent.phonePrivacy`,sync:`cloudIntent.syncPrivacy`};function l_({origin:e,landingUrl:t,waitingForLogin:n,onStartIntent:r}){let{t:i}=o(),[a,s]=(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:o_.map(({id:e,icon:t,titleKey:n,descKey:r})=>{let o=a===e;return(0,G.jsxs)(`button`,{"aria-checked":o,"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`}}[!!o|0],onClick:()=>s(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`}}[!!o|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`}}[!!o|0],children:o?(0,G.jsx)(`span`,{className:`x1ftt334 x1ycjhwn x16rqkct x1vi11w0`}):null})]},e)})}),(0,G.jsx)(L,{className:{className:`xh8yej3 x90ne7k x15az74h x12s0oaj x1ektstd x1w8fas2 xt9vybz xh88oxj`}.className,"data-cloud-intent-submit":``,icon:ho,loading:n,type:`primary`,onClick:()=>r(a),children:i(n?`publish.waitingLogin`:s_[a])}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g xknfcqp x1q4txso xur7f20 x2fo67v x1j6dyjg x1bo0w0s xfrs9s4`,children:[(0,G.jsx)(So,{"aria-hidden":`true`,size:12,style:{flexShrink:0}}),(0,G.jsx)(`span`,{children:i(c_[a])})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,G.jsx)(a_,{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)(bo,{"aria-hidden":`true`,size:11})]}):null]})]})}var u_={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:`xo5v014`,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 d_({position:e,children:t,style:n,...r}){return(0,G.jsx)(`div`,{"data-action-bar":!0,...r,...i(u_.bar,u_[e]),style:n,children:t})}function f_({children:e,tone:t=`default`,limit:n}){return(0,G.jsx)(`span`,{...i(u_.text,t!=="default"&&u_[t]),style:n?{maxWidth:n}:void 0,children:e})}function p_(){return(0,G.jsx)(`span`,{className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})}function m_({variant:e,children:t,...n}){return(0,G.jsx)(`a`,{...n,...i(u_.button,u_.anchor,u_[e]),children:t})}function h_({variant:e,children:t,...n}){return(0,G.jsx)(`button`,{type:`button`,...n,...i(e===`link`?u_.link:[u_.button,u_[e]]),children:t})}function g_({result:e,onDismiss:t,onOpenSharePanel:n}){let{t:r}=o(),[i,a]=(0,K.useState)(!1),[s,c]=(0,K.useState)(!!e.copied),l=async()=>{if(e.url)try{await navigator.clipboard.writeText(e.url),c(!0)}catch{}};return e.error?(0,G.jsxs)(d_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[(0,G.jsx)(f_,{limit:380,tone:`muted`,children:e.error}),(0,G.jsx)(h_,{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)(ft,{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)(ft,{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)(Hm,{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)(L,{icon:(0,G.jsx)(xo,{size:12}),size:`small`,onClick:()=>void l(),children:r(s?`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)(d_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[e.intent===`share`?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(f_,{limit:380,tone:`success`,children:e.copied?r(`cloudIntent.toastShareCopied`,{login:e.login}):r(`cloudIntent.toastShare`,{login:e.login})}),(0,G.jsx)(h_,{variant:`quiet`,onClick:n,children:r(`cloudIntent.changeAccess`)}),e.url?(0,G.jsxs)(m_,{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)(f_,{limit:360,tone:`success`,children:r(`cloudIntent.toastPhone`)}),e.billingUrl?(0,G.jsx)(m_,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`quiet`,children:r(`cloudIntent.learnRelay`)}):null,e.url?(0,G.jsx)(h_,{variant:`primary`,onClick:()=>a(e=>!e),children:r(i?`cloudIntent.hideQr`:`cloudIntent.showQr`)}):null]}):(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(f_,{limit:380,tone:`success`,children:r(`cloudIntent.toastSync`,{login:e.login})}),(0,G.jsx)(h_,{variant:`quiet`,onClick:wg,children:r(`cloudIntent.projectConfig`)}),e.dashboardUrl?(0,G.jsxs)(m_,{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)(ft,{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 __(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 v_(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 __(e.type,e.id).then(e=>{!t&&e&&o({key:i,text:e})}),()=>{t=!0}},[i]),!e||!i)return null;let s=Zh(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:Ig(n,c)}}var y_=800;function b_(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=_o(t=>{t.artifact!==e||t.type!==`change`&&t.type!==`cloud-published`||(clearTimeout(n),n=setTimeout(()=>void i(),y_))});return()=>{clearTimeout(n),a()}},[e,t,i]),{upToDate:n,refresh:i}}function x_(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&&Jh(a.json);!n&&t===i&&o&&r(o)};a();let o=_o(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 S_=e=>e.json.results??null;function C_(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(S_(o)),o},publishReferrers:async(t,n)=>{let r=await Z(`POST`,`publish-referrers/${e}`,{publish:t,makePublic:n});return r.ok&&c(S_(r)),r}}}var w_={private:`publish.hintPrivate`,public:`publish.hintPublic`};function T_({artifact:e,floating:t=!1,shell:n=!1}){let{t:r,i18n:a}=o(),{status:s,refresh:c,login:l,waitingForLogin:u}=lg(),d=Se(),[f,p]=(0,K.useState)(!1),[m,h]=(0,K.useState)(!1),[g,_]=(0,K.useState)([]),[v,y]=(0,K.useState)(null),[b,x]=(0,K.useState)(null),[S,C]=(0,K.useState)(null),w=(0,K.useRef)(!1),T=s?.artifacts?.[e],E=Zh(T),D=x_(e,!!s?.signedIn),O=D&&qh(D.phase),[k]=mg(),ee=E.url?pg(E.url,k):null,A=b_(e,!!s?.signedIn&&E.published),te=Qh(A.upToDate,!!s?.autoPublish?.enabled&&T?.autoPublish!==!1),j=C_(e),{refs:ne,referrers:re}=j,M=async e=>{h(!0),_([]),y(null);let t=await e();if(`shareKey`in t.json&&x(t.ok?t.json.shareKey:null),t.status===401)l(t.json.loginUrl);else if(!t.ok){t.json.code===`plan_required`&&typeof t.json.upgradeUrl==`string`&&y(t.json.upgradeUrl);let e=Array.isArray(t.json.reasons)?t.json.reasons:[];_([bg(t.json,r(`common.requestFailed`,{status:t.status})),...e])}await Promise.all([c(),A.refresh(),j.load()]),h(!1)},ie=!E.published&&ne.some(e=>e.checked),ae=E.published?E.visibility:null,N=v_(d.role===`primary`?d.other:null,s,ae,re),oe=t=>M(()=>Z(`POST`,`visibility/${e}`,{visibility:t})),se=(t={})=>M(()=>Z(`PUT`,`share-key/${e}`,t)),ce=async t=>{if(p(t),t&&s?.signedIn&&j.load(),t&&s?.signedIn&&E.published){if(A.refresh(),E.access===`key`){let t=await Z(`GET`,`share-key/${e}`);t.ok&&x(t.json.shareKey)}(await Z(`GET`,`artifacts`)).ok&&await c()}},le=t=>{r_(e,t),l()};(0,K.useEffect)(()=>{if(!s?.signedIn||!s.login||w.current)return;let t=i_(e);if(!t)return;w.current=!0;let n=s.login,i=s.origin;(async()=>{p(!1),h(!0),_([]),y(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:jg(i),billingUrl:Ng(i),error:bg(a.json,r(`common.requestFailed`,{status:a.status}))});return}Z(`POST`,`publish/${e}`),await c(),C({intent:t,login:n,url:null,dashboardUrl:jg(i),billingUrl:Ng(i)});return}let a=await Z(`POST`,`publish/${e}`),o=await c();if(await Promise.all([A.refresh(),j.load()]),!a.ok){a.json.code===`plan_required`&&typeof a.json.upgradeUrl==`string`&&y(a.json.upgradeUrl);let e=Array.isArray(a.json.reasons)?a.json.reasons:[],o=bg(a.json,r(`common.requestFailed`,{status:a.status}));_([o,...e]),C({intent:t,login:n,url:null,dashboardUrl:jg(i),billingUrl:Ng(i),error:o});return}let s=Zh(o?.artifacts?.[e]).url??(typeof a.json.url==`string`?a.json.url:null),l=s?pg(s,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:jg(i),billingUrl:Ng(i)})}finally{h(!1),w.current=!1}})()},[e,s?.signedIn,s?.login,s?.origin,k,c]);let P=Ag(s?.origin,a.language),ue=jg(s?.origin),de=s?s.signedIn?(0,G.jsxs)(`div`,{...i($.panel),children:[(0,G.jsxs)(`div`,{...i($.row),children:[(0,G.jsx)(`span`,{...i($.muted),children:r(`publish.signedInAs`,{login:s.login})}),(0,G.jsx)(`button`,{type:`button`,...i($.textButton),onClick:()=>void M(()=>Z(`POST`,`logout`)),children:r(`publish.signOut`)})]}),(0,G.jsx)(e_,{foot:r(w_[E.visibility]),saving:m,url:ee,visibility:E.visibility,beside:N?{...N.card,busy:m,onVisibility:e=>void M(()=>Z(`POST`,`visibility/${N.key}`,{visibility:e})),onPublish:()=>void M(()=>Z(`POST`,`publish/${N.key}`,{visibility:E.visibility}))}:null,cascade:{items:ne,rootVisibility:E.visibility,busy:m,results:j.results,includeRoot:!E.published,onPublish:(e,t)=>void M(()=>j.publishRefs(E.published,E.visibility,e,t))},profile:E.published?{shown:E.onProfile,path:s.login?`/u/${s.login}`:null,onChange:t=>void M(()=>Z(`POST`,`profile/${e}`,{shown:t}))}:null,referrers:{items:re,exclude:N?.key,rootVisibility:ae,busy:m,cloudUnavailable:j.cloudUnavailable,results:j.referrerResults,onPublish:(e,t)=>void M(()=>j.publishReferrers(e,t))},shareKey:{active:E.access===`key`,value:b,onSelect:()=>void se(),onExpiry:e=>void se({expires:e}),onRegenerate:()=>void se({regenerate:!0}),onRemove:()=>void M(()=>Z(`DELETE`,`share-key/${e}`))},status:(0,G.jsx)(Fg,{online:!0,busy:m,publication:D,published:E.published,publishedAt:T?.cloud?.publishedAt,onPublish:ie?void 0:()=>void M(()=>Z(`POST`,`publish/${e}`))}),onVisibility:e=>void oe(e)}),te?(0,G.jsx)(`span`,{...i(A.upToDate?$.muted:$.warning),children:r(`publish.${te}`)}):null,E.synced?null:(0,G.jsxs)(`div`,{...i($.row,$.warning),children:[(0,G.jsx)(`span`,{children:r(`publish.visibilityNotSynced`)}),(0,G.jsx)(L,{disabled:m,size:`small`,onClick:()=>void oe(E.visibility),children:r(`publish.sync`)})]}),g.length>0?(0,G.jsx)(`ul`,{...i($.error),children:g.map(e=>(0,G.jsx)(`li`,{children:e},e))}):null,v?(0,G.jsx)(`a`,{"data-upgrade":``,href:v,rel:`noreferrer`,target:`_blank`,...i($.textButton),children:r(`share.seePlans`)}):null,E.published&&(!D||D.phase===`published`)?(0,G.jsx)(L,{loading:m||!!O,type:`primary`,onClick:()=>void M(()=>Z(`POST`,`publish/${e}`)),children:r(`publish.update`)}):null,E.published?(0,G.jsx)(`button`,{disabled:m,type:`button`,...i($.textButton,$.danger),onClick:()=>void M(()=>Z(`DELETE`,`publish/${e}`)),children:r(`publish.unpublish`)}):null,E.published&&s.autoPublish?.enabled?(0,G.jsx)(`span`,{...i($.muted),children:r(`publish.autoPublishNote`)}):null,(0,G.jsxs)(`div`,{...i($.row,$.muted),children:[(0,G.jsx)(`span`,{children:r(`settings.menuStatus`,{state:s.autoPublish?.enabled?r(`settings.on`):r(`settings.off`)})}),(0,G.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:10},children:[ue?(0,G.jsxs)(`a`,{href:ue,rel:`noopener noreferrer`,target:`_blank`,...i($.textButton),children:[r(`cloudEntry.openShort`),` `,(0,G.jsx)(bo,{"aria-hidden":`true`,size:11})]}):null,(0,G.jsx)(`button`,{type:`button`,...i($.textButton),onClick:wg,children:r(`publish.openSettings`)})]})]})]}):(0,G.jsx)(l_,{landingUrl:P,origin:s.origin,waitingForLogin:u,onStartIntent:le}):(0,G.jsx)(`div`,{...i($.panel,$.muted),children:r(`publish.readingStatus`)});if(d.role===`beside`||nt())return null;let fe=n&&!!s&&!s.signedIn;return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Kt,{content:de,open:f,placement:`bottomRight`,popupProps:{"aria-label":r(`common.share`)},trigger:`click`,onOpenChange:e=>void ce(e),children:(0,G.jsxs)(`button`,{"aria-label":`Share`,"data-cloud-shell-cta":fe?``:void 0,type:`button`,...i($.trigger,t&&$.floating,fe&&$.shellCta),children:[fe?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`span`,{"aria-hidden":`true`,...i($.brandDot)}),r(`cloudEntry.shellCta`)]}):(0,G.jsxs)(G.Fragment,{children:[E.published&&E.visibility===`public`?(0,G.jsx)(De,{size:14}):(0,G.jsx)(So,{size:14}),E.published?r(`publish.published`):r(`common.share`)]}),D&&D.phase!==`published`?(0,G.jsx)(Fg,{compact:!0,publication:D,published:E.published}):null,A.upToDate===!1?(0,G.jsx)(`span`,{"aria-label":r(`publish.unpublishedChanges`),...i($.dot)}):null,N?.hidden?(0,G.jsx)(`span`,{"aria-label":r(`beside.hidden`),"data-beside-dot":``,...i($.dot)}):null]})}),S?(0,G.jsx)(g_,{result:S,onDismiss:()=>C(null),onOpenSharePanel:()=>{C(null),ce(!0)}}):null]})}function E_(e,t){let n=e.parentElement?.closest(`a, button`)??e,r=window.matchMedia(`(prefers-reduced-motion: reduce)`),i=null,a=()=>{if(r.matches||i)return;let{from:e,to:n,duration:a,easing:o}=d.sweep,s=t.animate([{transform:e},{transform:n}],{duration:a,easing:o});i=s,s.onfinish=s.oncancel=()=>{i=null}},o=()=>{n.matches(`:focus-visible`)&&a()};return n.addEventListener(`pointerenter`,a),n.addEventListener(`focus`,o),()=>{n.removeEventListener(`pointerenter`,a),n.removeEventListener(`focus`,o),i?.cancel()}}function D_({ink:e,clip:t,seal:n}){return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(`g`,{dangerouslySetInnerHTML:{__html:c},fill:e,transform:d.markTransform}),(0,G.jsxs)(`g`,{fill:`none`,stroke:e,strokeLinejoin:`round`,strokeWidth:d.strokeWidth,transform:d.wordTransform,children:[d.butt.map(e=>(0,G.jsx)(`path`,{d:e,strokeLinecap:`butt`},e)),d.round.map(e=>(0,G.jsx)(`path`,{d:e,strokeLinecap:`round`},e)),(0,G.jsx)(`g`,{clipPath:`url(#${t})`,children:d.clipped.map(e=>(0,G.jsx)(`path`,{d:e,strokeLinecap:`butt`},e))}),(0,G.jsx)(`rect`,{height:d.seal.size,rx:d.seal.rx,stroke:`none`,width:d.seal.size,x:d.seal.x,y:d.seal.y,...n})]})]})}function O_({height:e=22,title:t,contextMenu:n=!0}){let{t:r}=o(),i=l((0,K.useId)()),a=(0,K.useRef)(null),s=(0,K.useRef)(null);(0,K.useEffect)(()=>E_(a.current,s.current),[]);let c=async(e,t)=>{try{await navigator.clipboard.writeText(u(e)),tn.success(r(t))}catch{tn.error(r(`brand.copyFailed`))}},f=e=>{n&&(e.preventDefault(),e.stopPropagation(),Jt([{key:`copy-svg`,label:r(`brand.copySvg`),icon:xo,onClick:()=>void c(`lockup`,`brand.copiedSvg`)},{key:`copy-logo-svg`,label:r(`brand.copyLogoSvg`),icon:ot,onClick:()=>void c(`mark`,`brand.copiedLogoSvg`)},{key:`copy-text-svg`,label:r(`brand.copyTextSvg`),icon:ke,onClick:()=>void c(`wordmark`,`brand.copiedTextSvg`)}]))},p=`${i}-clip`,m=`${i}-mask`,h=`${i}-ember`;return(0,G.jsxs)(`svg`,{ref:a,...t?{role:`img`,"aria-label":t}:{"aria-hidden":!0},height:e,viewBox:d.viewBox,width:Math.round(e*d.width/d.height*100)/100,onContextMenu:n?f:void 0,className:`x1lliihq x2lah0s`,children:[(0,G.jsxs)(`defs`,{children:[(0,G.jsx)(`clipPath`,{id:p,children:(0,G.jsx)(`rect`,{...d.clipRect})}),(0,G.jsx)(`linearGradient`,{id:h,children:d.bandStops.map(e=>(0,G.jsx)(`stop`,{offset:e.offset,stopColor:e.color,stopOpacity:e.opacity},e.offset))}),(0,G.jsx)(`mask`,{id:m,maskUnits:`userSpaceOnUse`,...d.mask,children:(0,G.jsx)(D_,{clip:p,ink:`#fff`,seal:{fill:`#fff`}})})]}),(0,G.jsx)(D_,{clip:p,ink:`currentColor`,seal:{className:`xe8yr7n x1tl3b4t`}}),(0,G.jsx)(`g`,{mask:`url(#${m})`,children:(0,G.jsx)(`rect`,{fill:`url(#${h})`,ref:s,...d.band})})]})}var k_=e=>{e&&window.open(e,`_blank`,`noopener,noreferrer`)};function A_({compact:e=!1,status:t,waitingForLogin:n,onSignIn:r,onSignOut:i}){let{t:a,i18n:s}=o();if(!t)return null;if(!t.signedIn||!t.login){let e=Ag(t.origin,s.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)(Ho,{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)(Ce,{"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)(is,{"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)(Co,{"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)(L,{className:{className:`xh8yej3 x90ne7k x3nfvp2 x6s0dn4 xl56j7k x1j9xkj6 xc342km xur7f20 x15az74h x12s0oaj xt9vybz xqfszdh x1ct8sxb xh88oxj x1ypdohk`}.className,icon:ho,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)(So,{"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)(a_,{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)(bo,{"aria-hidden":`true`,size:11})]}):null]})]});return(0,G.jsx)(Kt,{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 c=t.login,l=jg(t.origin);return(0,G.jsxs)(G.Fragment,{children:[!e&&l?(0,G.jsxs)(`a`,{"data-cloud-header-link":``,href:l,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)(Ho,{"aria-hidden":`true`,size:13}),(0,G.jsx)(`span`,{children:`Cloud`}),(0,G.jsx)(bo,{"aria-hidden":`true`,size:12})]}):null,(0,G.jsx)(Ut,{items:[{key:`status`,disabled:!0,label:`${c} · ${a(`settings.menuStatus`,{state:t.autoPublish?.enabled?a(`settings.on`):a(`settings.off`)})}`},{type:`divider`,key:`cloud-divider`},{key:`open-cloud`,icon:Ho,label:a(`cloudEntry.openCloud`),extra:`↗`,onClick:()=>k_(l)},{key:`public-profile`,icon:De,label:a(`cloudEntry.publicProfile`),extra:`/u/${c} ↗`,onClick:()=>k_(Mg(t.origin,c))},{key:`plans`,icon:Ko,label:a(`cloudEntry.plans`),extra:`↗`,onClick:()=>k_(Ng(t.origin))},{type:`divider`,key:`settings-divider`},{key:`settings`,icon:ns,label:a(`settings.open`),onClick:wg},{key:`sign-out`,icon:Xo,label:a(`settings.signOut`),onClick:()=>void i?.()}],children:(0,G.jsx)(`button`,{"aria-label":a(`settings.accountMenu`,{login:c}),type:`button`,className:`x78zum5 x1717udv xc342km x16rqkct xjbqb8w x1ypdohk x1hl8ikr`,children:(0,G.jsx)(Rd,{alt:``,avatar:`/api/avatar/github/${c}`,shape:`circle`,size:28,className:`xs625wh`})})})]})}var j_=(0,K.createContext)(!1),M_=(0,K.createContext)(null),N_=j_.Provider,P_=M_.Provider,F_=()=>typeof window<`u`&&window.parent!==window&&Ee()&&!nt();function I_(){return(0,K.useContext)(j_)||F_()}function L_(){return(0,K.useContext)(M_)}function R_({type:e,id:t,docHeader:n,children:r}){let{t:i}=o(),s=lg(),[c,l]=(0,K.useState)(t),[u,d]=(0,K.useState)(null),f=`${e}/${t}`;(0,K.useEffect)(()=>{l(t);let e=()=>{let e=document.title?.trim();e&&e!==`Ryugi`&&e!==`Artifacts · Ryugi`&&l(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 p=!!s.status?.signedIn&&!!s.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)(O_,{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:c,className:`xeuugli xb3r6kr xlyipyv x1s688f xo2rkog`,children:c})]})]}),(0,G.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x167g77z x2lah0s`,children:[(0,G.jsx)(`div`,{ref:d,className:`xjp7ctv`}),a(e)&&n?.header?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Me,{available:n.header.history,comments:n.header.comments,open:n.header.historyOpen,onComments:()=>n.history(`close`),onHistory:()=>n.history(`toggle`)}),(0,G.jsx)(yo,{state:n.header.documentExport,onExport:n.exportPdf}),(0,G.jsx)(`span`,{"aria-hidden":`true`,className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})]}):null,s.status&&!p?(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)(T_,{shell:!0,artifact:f}),p?(0,G.jsx)(A_,{compact:!0,status:s.status,waitingForLogin:s.waitingForLogin,onSignIn:()=>void s.login(),onSignOut:async()=>{await Z(`POST`,`logout`),await s.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:wg,children:(0,G.jsx)(ns,{"aria-hidden":`true`,size:14})})]})]}),(0,G.jsx)(`div`,{className:`x1n2onr6 x98rzlu x2lwn1j x78zum5 xdt5ytf xb3r6kr`,children:(0,G.jsx)(N_,{value:!0,children:(0,G.jsx)(P_,{value:u,children:r})})})]})}var z_=1e3,B_=`ryugi:embed:hello`,V_=`ryugi:embed:heartbeat`,H_=`ryugi:embed:painted`,U_=`ryugi:embed:position`,W_=`ryugi:embed:positioned`;function G_({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===U_&&a.anchor&&t&&t(a.anchor).then(()=>r(W_))};n.addEventListener(`message`,i),r(B_,t?{position:!0}:void 0);let a=setInterval(()=>r(V_),z_),o=!1;return{painted(){o||(o=!0,r(H_))},close(){clearInterval(a),n.removeEventListener(`message`,i)}}}function K_(e=document,t=window,n){let r=e.documentElement.dataset.ryugiEmbedParent;return r?G_({parentOrigin:r,onPosition:n,win:t}):null}var q_=()=>new Promise(e=>requestAnimationFrame(()=>requestAnimationFrame(()=>e()))),J_=e=>(Ze(e),q_()),Y_=(0,K.createContext)(()=>{});function X_(){let e=(0,K.useRef)(null),t=(0,K.useRef)(!1);return(0,K.useEffect)(()=>{let n=K_(document,window,J_);return e.current=n,t.current&&n?.painted(),()=>{n?.close(),e.current=null}},[]),(0,K.useCallback)(()=>{t.current=!0,e.current?.painted()},[])}function Z_(e){let t=(0,K.useContext)(Y_);(0,K.useEffect)(()=>{if(!e)return;let n=0,r=requestAnimationFrame(()=>{n=requestAnimationFrame(()=>{t(),et()&&w({kind:`painted`})})});return()=>{cancelAnimationFrame(r),cancelAnimationFrame(n)}},[e,t])}function Q_(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 $_={artboard:{Layout:(0,K.lazy)(()=>_(async()=>{let{ArtboardLayout:e}=await import(`./ArtboardLayout-Ca63S-ht.js`);return{ArtboardLayout:e}},__vite__mapDeps([19,1,20,21,4,22,16,2,3,5,6,7,17,13,23,24,25,26,27,28,29,11,12,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,18,50,51,52,53,54,10,55,56,57,58,59,60,15,8,9,61,62,63,64]),import.meta.url).then(({ArtboardLayout:e})=>({default:e})))},document:{Layout:(0,K.lazy)(()=>_(async()=>{let{DocumentLayout:e}=await import(`./DocumentLayout-Vo9s9zeJ.js`);return{DocumentLayout:e}},__vite__mapDeps([65,1,4,5,2,3,6,7]),import.meta.url).then(({DocumentLayout:e})=>({default:e})))},html:{Layout:(0,K.lazy)(()=>_(async()=>{let{HtmlLayout:e}=await import(`./HtmlLayout-DlU3MyPC.js`);return{HtmlLayout:e}},__vite__mapDeps([66,1,20,21,4,22,16,2,3,5,6,7,17,13,67,24,46,68,55,56]),import.meta.url).then(({HtmlLayout:e})=>({default:e})))},whiteboard:{Layout:(0,K.lazy)(()=>_(async()=>{let{WhiteboardLayout:e}=await import(`./WhiteboardLayout-CwmEBIBu.js`);return{WhiteboardLayout:e}},__vite__mapDeps([69,1,21,4,22,16,2,3,5,6,7,17,13,70,71,24,18,41,72,36,73,74,51,31,52,37,75,45,76,77,10,30,11,12,48,38,39,49,46,57,78,62,79,43,44,80,81,82]),import.meta.url).then(({WhiteboardLayout:e})=>({default:e}))),embedIn:e=>(0,G.jsx)(dg,{pageWindow:Q_(),children:e})},verify:{Layout:(0,K.lazy)(()=>_(async()=>{let{VerifyLayout:e}=await import(`./VerifyLayout-Bjh7Ddzn.js`);return{VerifyLayout:e}},__vite__mapDeps([83,1,16,2,3,4,5,6,7,17,13,21,22,84,85,71,24,18,41,72,36,73,74,51,31,52,37,75,45,76,39,86,87,88,89,80,90,48,38,49,12,46,91,27,92,93,11,79,26,10,8,9,78,94,68,95,58,59,29,96,97]),import.meta.url).then(({VerifyLayout:e})=>({default:e})))},slides:{Layout:(0,K.lazy)(()=>_(async()=>{let{SlidesLayout:e}=await import(`./SlidesLayout-MGWpipwc.js`);return{SlidesLayout:e}},__vite__mapDeps([98,1,20,21,4,22,16,2,3,5,6,7,17,13,99,94,77,68,55,56,29,67,24,46,10,48,38,39,49,12,34,35,36,37,40,41,42,74,80,87,44,45,54,75,31,62,9,15,18,100,52,53,90,27,101,8,57,93,102,103,23,104]),import.meta.url).then(({SlidesLayout:e})=>({default:e}))),bare:e=>new URLSearchParams(e).has(`live`)},report:{Layout:(0,K.lazy)(()=>_(async()=>{let{ReportLayout:e}=await import(`./ReportLayout-BLVLfLGU.js`);return{ReportLayout:e}},__vite__mapDeps([105,1,20,21,4,22,16,2,3,5,6,7,17,13,67,24,46,68,55,56,29,80,10,35,36,48,38,39,49,12,61,89,53,91]),import.meta.url).then(({ReportLayout:e})=>({default:e})))},storyboard:{Layout:(0,K.lazy)(()=>_(async()=>{let{StoryboardLayout:e}=await import(`./StoryboardLayout-BkntJIHV.js`);return{StoryboardLayout:e}},__vite__mapDeps([106,1,4,20,21,22,16,2,3,5,6,7,17,13,107,29,68,67,24,46,55,56,38,39,54,108,53,93,23,48,49,12,80,92,102,15,27,40,41,44,45,35,36,73,75,31,32,33,42,52,60]),import.meta.url).then(({StoryboardLayout:e})=>({default:e})))}},ev=(0,K.lazy)(()=>_(async()=>{let{StoryboardRenderLayout:e}=await import(`./StoryboardRender-BniWnBGv.js`);return{StoryboardRenderLayout:e}},__vite__mapDeps([109,1,107,2,3,4,5,6,7,29,68,20,21,22,16,17,13]),import.meta.url).then(({StoryboardRenderLayout:e})=>({default:e}))),tv=(0,K.lazy)(()=>_(async()=>{let{PreviewArtifactLayout:e}=await import(`./PreviewArtifactLayout-neL_d_3n.js`);return{PreviewArtifactLayout:e}},__vite__mapDeps([110,1,4,16,2,3,5,6,7,17,13,22,102,15,38,39,24,10,67,46,47,54,48,49,12,100,44,45,11,42,52,111]),import.meta.url).then(({PreviewArtifactLayout:e})=>({default:e}))),nv=(0,K.lazy)(()=>_(async()=>{let{AutoPublishBar:e}=await import(`./auto-publish-D0gnAgNH.js`);return{AutoPublishBar:e}},__vite__mapDeps([112,1,113,13,3,4,5,2,6,7]),import.meta.url).then(({AutoPublishBar:e})=>({default:e}))),rv=(0,K.lazy)(()=>_(async()=>{let{SettingsDialog:e}=await import(`./settings-CxJUVRn8.js`);return{SettingsDialog:e}},__vite__mapDeps([114,1,16,2,3,4,5,6,7,17,13,31,54,14,78,46]),import.meta.url).then(({SettingsDialog:e})=>({default:e}))),iv=(0,K.lazy)(()=>_(async()=>{let{ArtifactList:e}=await import(`./ArtifactList-CyHqaLMU.js`);return{ArtifactList:e}},__vite__mapDeps([115,1,35,2,3,4,5,6,7,16,17,13,36,24,42,38,39,54,23,91,75,111,67,46,14,50,56,59,44,45,62,18,22]),import.meta.url).then(({ArtifactList:e})=>({default:e}))),av=(0,K.lazy)(()=>Promise.all([_(()=>import(`./split-CeIplvJa.js`),__vite__mapDeps([116,1,94,16,2,3,4,5,6,7,17,13,56,15,88,101,44,45,46,117,86,108,72,90,10,9,103,96,118,49,81,119]),import.meta.url),_(()=>import(`./local-split-host-DJJKo1Vj.js`).then(e=>e.n),__vite__mapDeps([99,1,94,16,2,3,4,5,6,7,17,13,22]),import.meta.url)]).then(([{SplitShell:e},{localSplitHost:t}])=>({default:n=>(0,G.jsx)(e,{...n,host:t})}))),ov=(0,K.lazy)(()=>_(async()=>{let{PreviewLayout:e}=await import(`./PreviewLayout-BuviWNGi.js`).then(e=>e.n);return{PreviewLayout:e}},__vite__mapDeps([120,1,4,2,3,5,6,7,25,79]),import.meta.url).then(({PreviewLayout:e})=>({default:e}))),sv=(e,t)=>(0,G.jsxs)(G.Fragment,{children:[e,(0,G.jsx)(nv,{}),(0,G.jsx)(rv,{}),t&&(0,G.jsx)(Gh,{artifact:t})]}),cv=(e,t,n)=>sv((0,G.jsx)(R_,{id:t,type:e,children:n}),`${e}/${t}`);function lv({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 sv((0,G.jsx)(R_,{docHeader:a,id:r.id,type:r.type,children:(0,G.jsx)(av,{fill:!0,hostPrimaryDocument:!0,id:t,split:n,type:e,onDocumentHeader:c,onPanes:s})}),`${r.type}/${r.id}`)}function uv({id:e,type:t}){let n=X_(),{Layout:r,embedIn:i}=$_[t],a=(0,G.jsx)(r,{id:e});return(0,G.jsxs)(Y_,{value:n,children:[Hh(location.search)&&(0,G.jsx)(Gh,{artifact:`${t}/${e}`}),i?i(a):a]})}function dv(){let[e]=yh(),t=f(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=h(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 sv((0,G.jsx)(iv,{}));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)(ov,{id:n,type:t.type});if(t.kind===`dev-preview`)return sv((0,G.jsx)(tv,{id:n}),`preview/${n}`);if(t.kind===`embed`)return(0,G.jsx)(uv,{id:n,type:t.type});if(t.kind===`render`)return(0,G.jsx)(ev,{id:n});if(p(t.type).standalone){let{Layout:e,bare:r}=$_[t.type],i=(0,G.jsx)(e,{id:n});return r?.(location.search)?sv(i,`${t.type}/${n}`):cv(t.type,n,i)}return(0,G.jsx)(lv,{id:n,split:Le(t,location.search)?.split??null,type:t.type})}function fv(){return(0,G.jsx)(K.Suspense,{fallback:(0,G.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:(0,G.jsx)(Th,{label:y(`common.loading`)})}),children:(0,G.jsx)(dv,{})})}Re(),document.documentElement.lang=n[g.language];function pv(){return v(),(0,G.jsx)(zd,{features:_f,children:(0,G.jsxs)(oe,{enableCustomFonts:!1,motion:Gm,children:[(0,G.jsx)(fv,{}),(0,G.jsx)(ce,{}),(0,G.jsx)(nn,{}),(0,G.jsx)(Cp,{})]})})}(0,Km.createRoot)(document.getElementById(`root`)).render((0,G.jsx)(K.StrictMode,{children:(0,G.jsx)(pv,{})}));export{Y as A,Bo as B,Zh as C,Oh as D,kh as E,is as F,ns as I,es as L,up as M,xf as N,Th as O,Rd as P,Qo as R,lg as S,Mh as T,wg as _,O_ as a,mg as b,h_ as c,a_ as d,Ng as f,Tg as g,Mg as h,A_ as i,pp as j,Rp as k,p_ as l,Ag as m,I_ as n,T_ as o,jg as p,L_ as r,d_ as s,Z_ as t,f_ as u,Og as v,Ih as w,Z as x,pg as y,Wo as z};
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./AgentDock-fdzdI0YU.js","./rolldown-runtime-XKyaHtl9.js","./route-DdpUUY_w.js","./bem-vbke-3KC.js","./react-DlmbjZJV.js","./jsx-runtime-LKYXHABd.js","./types-DAs-xbqr.js","./index2.css","./BottomSheet-DksTxPPS.js","./motion-Cy65kd7X.js","./useMedia-CFebB4XU.js","./agentLook-EhrjbD1n.js","./icons-8mizjIXE.js","./MotionConfigContext-HC2vqcJO.js","./arrow-up-right-0KreI6kY.js","./chevron-left-C5itNrp5.js","./url-B_fuREEU.js","./useLayerZIndex-VAxAVO-V.js","./chevron-right-xNdXLJg6.js","./ArtboardLayout-CyP7z5iV.js","./useArtifactFeed-B9RfhN8_.js","./transport-Djlo7-HU.js","./useArtifactSocket-ns9zjgVa.js","./imperative-iclc26pT.js","./Popover-i0m3nwq7.js","./view-DLrABahQ.js","./rounds-BLj-tfMG.js","./sliders-horizontal-CuS3-UwA.js","./Canvas-DA9wKktu.js","./cssVar.stylex-CGbpAC1Y.js","./WritingCursor-OdCSWg_M.js","./maximize-2-Bc0lXBg6.js","./PlaybackIcon-D-vfZnSv.js","./elements-CmGVWYag.js","./snap-1DJNMR4r.js","./local-DzHVL3fo.js","./SelectScrollUpArrow-BNSyHMPX.js","./undo-2-B-JiyKIl.js","./stable-CZy_447C.js","./Tooltip-81DgA1Zr.js","./styles-BHI9FTnz.js","./stringifyLocale-D0juOOnH.js","./Input-YumXWTse.js","./PhoneArtboardBar-CZKL18gK.js","./DropdownMenu-DhVZ3e22.js","./MenuSubmenuTrigger-DZ2Nb6Hm.js","./index5.css","./crop-encode-Udgh8S7r.js","./ThreadView-CbKzFwUf.js","./comments-DUAz1Q9X.js","./folder-BViSPo7g.js","./ruler-CYb0HZGT.js","./mouse-pointer-2-B-OF_fcG.js","./play-6FAfeM1L.js","./Segmented-BV_iofkK.js","./useTypeFavicon-yXOsFZBx.js","./type-icons-CxYXZlMj.js","./CommentPopover-Bz3qXsBS.js","./GroupVerdict-DkOR7Neo.js","./artifact-list-D22lTyyh.js","./film-A6SU1RGC.js","./code-xml-c9QCqmhY.js","./store-D3ROW536.js","./selection-BWCQd_Fn.js","./ArtboardLayout-DLyi-yDq.css","./DocumentLayout-16zcY3cg.js","./HtmlLayout-BQS68lEe.js","./WarningsBadge-fEXkyk3t.js","./useSandboxFrame-CJmSnwgG.js","./WhiteboardLayout-qGm-CExy.js","./shims-s-YVfIlz.js","./WhiteboardEditor-cZ32fLqJ-BRt-wSEn.js","./code-DnmQyGiF.js","./zoom-out-DsmGFv1v.js","./text-align-start-CRhecbJR.js","./plus-DZJ2BVkK.js","./index3.css","./pages-DWkRbog-.js","./preference-oNdcNeml.js","./DotGrid-DKKr_PyM.js","./message-square-Yl8PoPy_.js","./backlinks-C_k8-LL2.js","./WhiteboardLayout-SRFXrlmW.css","./VerifyLayout--deiRi4o.js","./useAssetBase-4Ut9QhBI.js","./editor-BabkJ7hH.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-JbqCEGXp.js","./index4.css","./fit-BJ0VxRML.js","./VerifyLayout-B9e4RHAZ.css","./SlidesLayout-CSeSindR.js","./local-split-host-DaeACaX5.js","./monitor-DRrnx_H5.js","./DocumentExportMenu-Cb03PJdE.js","./DraggablePanel-BlNQ_JOj.js","./embed-src-CmyqZplg.js","./SlidesLayout-Bjds2UXz.css","./ReportLayout-DPnqWYPZ.js","./StoryboardLayout-DZVJbnzc.js","./useStoryboardData-DCPDhUMO.js","./clapperboard-BfpJ7tpa.js","./StoryboardRender-DORxY44d.js","./PreviewArtifactLayout-B4SZfLvw.js","./RyugiMark-Ch2tF00h.js","./auto-publish-BXmqx8BX.js","./cloud-upload-D8TpApTr.js","./settings-wKTRexHi.js","./ArtifactList-D1Cv2wcz.js","./split-BJA_5Rtf.js","./SplitFrame-C3Mr0Ehv.js","./route-messages-BMv2jmvl.js","./split-C1umM5Fz.css","./PreviewLayout-DiIQthoy.js"])))=>i.map(i=>d[i]);
2
+ import{n as e,r as t}from"./rolldown-runtime-XKyaHtl9.js";import{C as n,S as r,T as i,_ as a,a as o,b as s,d as c,f as l,g as u,h as d,m as f,n as p,o as m,s as h,t as g,v as _,w as v,x as y,y as b}from"./route-DdpUUY_w.js";/* empty css */import{$t as x,Ar as S,At as C,Bt as w,C as T,Cr as E,Ct as D,Dr as O,Dt as k,Er as A,Et as j,Ft as ee,Gt as M,Ht as te,It as ne,J as N,Jt as re,Kt as ie,Lt as P,Mn as ae,Mr as oe,Mt as F,N as se,Nr as I,Nt as ce,Ot as le,Pt as ue,Qt as de,St as fe,Tn as pe,Tr as me,Tt as he,Ut as L,Vt as ge,Wt as _e,Xt as ve,Y as ye,Zt as be,_ as xe,_r as Se,_t as Ce,an as we,at as R,b as Te,br as Ee,bt as De,cr as z,dr as Oe,dt as ke,ft as Ae,g as je,gr as Me,gt as Ne,hr as Pe,ht as Fe,i as Ie,it as B,j as Le,jn as Re,jr as ze,jt as Be,kn as Ve,kt as He,mr as Ue,mt as We,nn as Ge,ot as Ke,pt as qe,qt as Je,rt as Ye,u as Xe,ur as Ze,ut as Qe,v as $e,vt as et,w as tt,wr as nt,wt as rt,xt as it,yr as at,yt as ot,zt as st}from"./url-B_fuREEU.js";import{$r as ct,C as lt,Dn as ut,En as dt,Fn as ft,Ft as pt,Gr as mt,Hr as ht,It as gt,Kr as _t,Pn as vt,Sn as yt,Tn as bt,Vr as xt,Xr as St,Yr as Ct,Zr as wt,ii as V,kr as Tt,oi as Et,or as Dt,qn as Ot,ri as H,rr as kt,t as At,zr as jt}from"./useLayerZIndex-VAxAVO-V.js";import{n as Mt,r as U,t as Nt}from"./bem-vbke-3KC.js";import{t as Pt}from"./react-DlmbjZJV.js";import{a as Ft,i as It,l as Lt,n as Rt,o as zt,r as Bt,s as Vt,t as Ht}from"./DropdownMenu-DhVZ3e22.js";import{A as Ut,f as Wt,t as Gt}from"./Popover-i0m3nwq7.js";import{t as Kt}from"./jsx-runtime-LKYXHABd.js";import{a as qt,i as Jt,n as Yt,o as Xt,r as Zt,s as Qt,t as $t}from"./store-D3ROW536.js";import{n as en,t as tn}from"./imperative-iclc26pT.js";import{$ as nn,B as rn,Ct as an,Dt as on,Et as sn,G as cn,I as ln,J as un,M as dn,N as fn,P as pn,St as mn,Tt as hn,U as gn,W,_t as _n,a as vn,bt as yn,c as bn,ct as xn,d as Sn,dt as Cn,et as wn,gt as Tn,h as En,ht as Dn,i as On,l as kn,m as An,mt as jn,o as Mn,p as Nn,r as Pn,s as Fn,st as In,t as Ln,u as Rn,ut as zn,wt as Bn,xt as Vn}from"./MotionConfigContext-HC2vqcJO.js";import{$ as Hn,$n as Un,$t as Wn,A as Gn,An as Kn,At as qn,B as Jn,Bn as Yn,Bt as Xn,C as Zn,Cn as Qn,Cr as $n,Ct as er,D as tr,Dn as nr,Dt as rr,E as ir,En as ar,Et as or,F as sr,Fn as cr,Ft as lr,G as ur,Gn as dr,Gt as fr,H as pr,Hn as mr,Ht as hr,I as gr,In as _r,It as vr,J as yr,Jn as br,Jt as xr,K as Sr,Kn as Cr,Kt as wr,L as Tr,Ln as Er,Lt as Dr,M as Or,Mn as kr,Mt as Ar,N as jr,Nn as Mr,Nt as Nr,O as Pr,On as Fr,Ot as Ir,P as Lr,Pn as Rr,Pt as zr,Q as Br,Qn as Vr,Qt as Hr,R as Ur,Rn as Wr,Rt as Gr,S as Kr,Sn as qr,Sr as Jr,St as Yr,T as Xr,Tn as Zr,Tr as Qr,Tt as $r,U as ei,Un as ti,Ut as ni,V as ri,Vn as ii,Vt as ai,W as oi,Wn as si,Wt as ci,X as li,Xn as ui,Xt as di,Y as fi,Yn as pi,Yt as mi,Z as hi,Zn as gi,Zt as _i,_ as vi,_n as yi,_r as bi,_t as xi,a as Si,an as Ci,ar as wi,at as Ti,b as Ei,bn as Di,br as G,bt as Oi,c as ki,cn as Ai,cr as ji,ct as Mi,d as Ni,dn as Pi,dr as Fi,dt as Ii,en as Li,er as Ri,et as zi,f as Bi,fn as Vi,fr as Hi,ft as Ui,g as Wi,gn as Gi,gr as Ki,gt as qi,h as Ji,hn as Yi,hr as Xi,ht as Zi,i as Qi,in as $i,ir as ea,it as ta,j as na,jn as ra,jt as ia,k as aa,kn as oa,kt as sa,l as ca,ln as la,lr as ua,lt as da,m as fa,mn as pa,mr as ma,mt as ha,n as ga,nn as _a,nr as va,nt as ya,o as ba,on as xa,or as Sa,ot as Ca,p as wa,pn as Ta,pr as Ea,pt as Da,q as Oa,qn as ka,qt as Aa,r as ja,rn as Ma,rr as Na,rt as Pa,s as Fa,sn as Ia,sr as La,st as Ra,t as za,tn as Ba,tr as Va,tt as Ha,u as Ua,un as Wa,ur as Ga,ut as Ka,v as qa,vn as Ja,vr as Ya,vt as Xa,w as Za,wn as Qa,wr as $a,wt as eo,x as to,xn as no,xr as ro,xt as io,y as ao,yn as oo,yr as so,yt as co,z as lo,zn as uo,zt as fo}from"./elements-CmGVWYag.js";import{m as po,p as mo,t as ho}from"./local-DzHVL3fo.js";import{r as go,t as _o}from"./useArtifactSocket-ns9zjgVa.js";import{t as vo}from"./DocumentExportMenu-Cb03PJdE.js";import{t as yo}from"./arrow-up-right-0KreI6kY.js";import{F as bo,P as xo}from"./SelectScrollUpArrow-BNSyHMPX.js";import{t as So}from"./cloud-upload-D8TpApTr.js";import{t as Co}from"./Tooltip-81DgA1Zr.js";import{S as wo,a as To,c as Eo,d as Do,f as Oo,h as ko,i as Ao,l as jo,m as Mo,n as No,s as Po,t as Fo,u as Io,x as Lo}from"./MenuSubmenuTrigger-DZ2Nb6Hm.js";var Ro={name:`clock-3`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6h4`,key:`135r8i`}]]};Ro.node;var zo=on(Ro),Bo={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`}]]};Bo.node;var Vo=on(Bo),Ho={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`]};Ho.node;var Uo=on(Ho),Wo={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`}]]};Wo.node;var Go=on(Wo),Ko={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`}]]};Ko.node;var qo=on(Ko),Jo={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`}]]};Jo.node;var Yo=on(Jo),Xo={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`}]]};Xo.node;var Zo=on(Xo),Qo={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`}]]};Qo.node;var $o=on(Qo),es={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`}]]};es.node;var ts=on(es),ns={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`}]]};ns.node;var rs=on(ns);function is(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 as(e,t,n){return Qr(e.getProps(),t,n,e)}var os=(e,t)=>t===`exit`?e.presenceContext?.custom:void 0,ss=e=>Array.isArray(e);function cs(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,An(n))}function ls(e){return ss(e)?e[e.length-1]||0:e}function us(e,t){let{transitionEnd:n={},transition:r={},...i}=as(e,t)||{};i={...i,...n};for(let t in i)cs(e,t,ls(i[t]))}function ds(e){return!!(Sn(e)&&e.add)}function fs(e,t){let n=e.getValue(`willChange`);if(ds(n))return n.add(t);if(!n&&yn.WillChange){let n=new yn.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function ps(e){return e.props[$a]}var ms=typeof window<`u`;function hs({protectedKeys:e,needsAnimating:t},n){let r=n in e&&!t[n];return t[n]=!1,r}function gs(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&&hs(f,t))continue;let o={delay:n,...ne(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){W.update(()=>r.set(i));continue}let p=!1;if(ms&&window.MotionHandoffAnimation){let n=ps(e);if(n){let e=window.MotionHandoffAnimation(n,t,W);e!==null&&(o.startTime=e,p=!0)}}fs(e,t);let m=l??e.shouldReduceMotion;r.run(ee(t,r,i,m&&ce.has(t)?{type:!1}:o,e,p));let h=r.animation;h&&d.push(h)}if(o){let t=()=>W.update(()=>{o&&us(e,o)});d.length?Promise.all(d).then(t):t()}return d}function _s(e,t,n={}){let r=as(e,t,os(e,n.type)),i=n.transitionOverride||(r?.transition??(e.getDefaultTransition()||{})),a=()=>Promise.all(r?gs(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(_s(e,t,{...n,delay:r+(typeof o==`function`?0:o)+is(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 vs(e,t,n={}){return e.notify(`AnimationStart`,t),(Array.isArray(t)?Promise.all(t.map(t=>_s(e,t,n))):typeof t==`string`?_s(e,t,n):Promise.all(gs(e,as(e,t,n.custom),n))).then(()=>{e.notify(`AnimationComplete`,t)})}var ys=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomRightRadius`,`borderBottomLeftRadius`],bs={value:null,addProjectionMetrics:null,countProjection:void 0};function xs(e,t){let n=zn.now();e=He(e);let r=({timestamp:i})=>{let a=i-n;a>=t&&(gn(r),e(a-t))};return W.setup(r,!0),le(()=>gn(r))}function Ss(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function Cs(e){return C(e)&&e.tagName===`svg`}var ws=e=>typeof e==`number`?e:parseFloat(e),Ts=ys.length,Es=e=>typeof e==`number`||wn.test(e);function Ds(e,t,n,r,i,a){i?(e.opacity=L(0,n.opacity??1,ks(r)),e.opacityExit=L(t.opacity??1,0,As(r))):a&&(e.opacity=L(t.opacity??1,n.opacity??1,r));for(let i=0;i<Ts;i++){let a=ys[i],o=Os(t,a),s=Os(n,a);(o!==void 0||s!==void 0)&&(o||=0,s||=0,o===0||s===0||Es(o)===Es(s)?(e[a]=Math.max(L(ws(o),ws(s),r),0),(nn.test(s)||nn.test(o))&&(e[a]+=`%`)):e[a]=s)}for(let i=0;i<ot.length;i++){let a=ot[i];(t[a]||n[a])&&(e[a]=L(t[a]||0,n[a]||0,r))}}function Os(e,t){return e[t]===void 0?e.borderRadius:e[t]}var ks=js(0,.5,_e),As=js(.5,.95,_n);function js(e,t,n){return r=>r<e?0:r>t?1:n(M(e,t,r))}var Ms=(e,t,{x:n,y:r})=>{let i=e*e+t*t;return i<1?0:-1e3*(n*e+r*t)/i},Ns=(e,t=300)=>{let n=Vn(.25,2,t/300),{stiffness:r,damping:i}=w({...e,duration:e.duration&&Dn(e.duration)});return{...e,stiffness:r,damping:i*Math.sqrt(n),mass:n}};function Ps(e,t){e.min=t.min,e.max=t.max}function Fs(e,t){Ps(e.x,t.x),Ps(e.y,t.y)}function Is(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var Ls=.9999,Rs=1.0001,zs=-.01,Bs=.01;function Vs(e){return e.max-e.min}function Hs(e,t,n){return Math.abs(e-t)<=n}function Us(e,t,n,r=.5){e.origin=r,e.originPoint=L(t.min,t.max,e.origin),e.scale=Vs(n)/Vs(t),e.translate=L(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Ls&&e.scale<=Rs||isNaN(e.scale))&&(e.scale=1),(e.translate>=zs&&e.translate<=Bs||isNaN(e.translate))&&(e.translate=0)}function Ws(e,t,n,r){Us(e.x,t.x,n.x,r?.originX),Us(e.y,t.y,n.y,r?.originY)}function Gs(e,t,n,r=0){e.min=(r?L(n.min,n.max,r):n.min)+t.min,e.max=e.min+Vs(t)}function Ks(e,t,n,r){Gs(e.x,t.x,n.x,r?.x),Gs(e.y,t.y,n.y,r?.y)}function qs(e,t,n,r=0){let i=r?L(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+Vs(t)}function Js(e,t,n,r){qs(e.x,t.x,n.x,r?.x),qs(e.y,t.y,n.y,r?.y)}function Ys(e,t,n,r,i){return e-=t,e=Ne(e,1/n,r),i!==void 0&&(e=Ne(e,1/i,r)),e}function Xs(e,t=0,n=1,r=.5,i,a=e,o=e){if(nn.test(t)&&(t=parseFloat(t),t=L(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=L(a.min,a.max,r);e===a&&(s-=t),e.min=Ys(e.min,t,n,s,i),e.max=Ys(e.max,t,n,s,i)}function Zs(e,t,[n,r,i],a,o){Xs(e,t[n],t[r],t[i],t.scale,a,o)}var Qs=[`x`,`scaleX`,`originX`],$s=[`y`,`scaleY`,`originY`];function ec(e,t,n,r){Zs(e.x,t,Qs,n?.x,r?.x),Zs(e.y,t,$s,n?.y,r?.y)}var tc=e=>typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),nc=tc(`applewebkit/`)&&!tc(`chrome/`)?Math.round:_n;function rc(e){e.min=nc(e.min),e.max=nc(e.max)}function ic(e){rc(e.x),rc(e.y)}function ac(e){return e.translate===0&&e.scale===1}function oc(e){return ac(e.x)&&ac(e.y)}function sc(e,t){return e.min===t.min&&e.max===t.max}function cc(e,t){return sc(e.x,t.x)&&sc(e.y,t.y)}function lc(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function uc(e,t){return lc(e.x,t.x)&&lc(e.y,t.y)}function dc(e){return Vs(e.x)/Vs(e.y)}function fc(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var pc=class{constructor(){this.members=[]}add(e){mn(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||(Bn(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(Bn(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 mc(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var hc={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`){if(wn.test(e))e=parseFloat(e);else return e}return`${mc(e,t.target.x)}% ${mc(e,t.target.y)}%`}},gc={borderRadius:Object.assign({},hc,{applyTo:ys.slice()}),borderTopLeftRadius:hc,borderTopRightRadius:hc,borderBottomLeftRadius:hc,borderBottomRightRadius:hc,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=un.parse(e);if(i.length>5)return r;let a=un.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=L(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 _c(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<ot.length;e++){let t=ot[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 vc(e){return[e(`x`),e(`y`)]}var yc=(e,t)=>e.depth-t.depth,bc=class{constructor(){this.children=[],this.isDirty=!1}add(e){mn(this.children,e),this.isDirty=!0}remove(e){Bn(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(yc),this.isDirty=!1,this.children.forEach(e)}},xc={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Sc=[`z`,`skew`,`skewZ`],Cc=1e3,wc=0;function Tc(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}var Ec=e=>e.instance&&En.get(e.instance)?.demote()&&e.resetSkewAndRotation();function Dc(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=ps(t);if(window.MotionHasOptimisedAnimation(n,`transform`)){let{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,`transform`,W,!(t||r))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Dc(r)}function Oc(e){if(e)return e.options.allowProjection===!1?Oc(e.parent):e.projection}function kc({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return Object.assign($n,{...gc,...$n}),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:Oc(e.parent));d.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!a||o&&Ss(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=wc++,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(Mc),this.nodes.forEach(Uc),this.nodes.forEach(Wc),this.nodes.forEach(Nc),bs.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 bc)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new Tn),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=C(t)&&!Cs(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;W.read(()=>{r=window.innerWidth}),e(t,()=>{let e=window.innerWidth;e!==r&&(r=e,this.root.updateBlockedByResize=!0,n?.(),n=xs(i,250),xc.hasAnimatedSinceResize&&(xc.hasAnimatedSinceResize=!1,this.nodes.forEach(Hc)))})}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()||Zc,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=n.getProps(),c=!this.targetLayout||!uc(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={...ne(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||Hc(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,gn(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(Gc),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&&Dc(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;Ec(this),this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,Ec(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(Ic),this.nodes.forEach(Fc);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Lc);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(zc),this.nodes.forEach(Bc),this.nodes.forEach(Vc),this.nodes.forEach(Ac),this.nodes.forEach(jc)):this.nodes.forEach(Lc),this.clearAllSnapshots();let e=zn.now();Cn.delta=Vn(0,1e3/60,e-Cn.timestamp),Cn.timestamp=e,Cn.isProcessing=!0,cn.update.process(Cn),cn.preRender.process(Cn),cn.render.process(Cn),Cn.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Fn.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Pc),this.sharedNodes.forEach((e,t)=>e.members.length?e.removeLeadSnapshot():this.sharedNodes.delete(t))}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,W.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){W.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){if(!this.snapshot&&this.instance&&(this.snapshot=this.measure(),this.snapshot&&!Vs(this.snapshot.measuredBox.x)&&!Vs(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||=G(),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&&Ec(this);let t=this.projectionDelta&&!oc(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,``):void 0,a=r!==this.prevTransformTemplateValue;e&&this.instance&&(t||D(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)),ic(n),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:e}=this.options;if(!e)return G();let t=e.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(el))){let{scroll:e}=this.root;e&&(et(t.x,e.offset.x),et(t.y,e.offset.y))}return t}removeElementScroll(e){let t=G();if(Fs(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&&Fs(t,e),et(t.x,i.offset.x),et(t.y,i.offset.y))}return t}applyTransform(e,t=!1,n,r,i=0){let a=n||G();Fs(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&&(et(a.x,-n.scroll.offset.x),et(a.y,-n.scroll.offset.y)),D(n.latestValues)&&Ce(a,n.latestValues,n.layout?.layoutBox)}return!r&&D(this.latestValues)&&Ce(a,this.latestValues,this.layout?.layoutBox),a}removeTransform(e){let t=G();Fs(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!D(n.latestValues))continue;let r;n.instance&&(fe(n.latestValues)&&n.updateSnapshot(),r=G(),Fs(r,n.measurePageBox())),ec(t,n.latestValues,n.snapshot?.layoutBox,r)}return D(this.latestValues)&&ec(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!==Cn.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=Cn.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=G(),this.targetWithTransforms=G()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Ks(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):Fs(this.target,this.layout.layoutBox),We(this.target,this.targetDelta)):Fs(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),bs.countProjection?.(1))}getClosestProjectingParent(){if(!(!this.parent||fe(this.parent.latestValues)||De(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=G(),this.relativeTargetOrigin=G(),Js(this.relativeTargetOrigin,t,n,this.options.layoutAnchor||void 0),Fs(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===Cn.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;Fs(this.layoutCorrected,this.layout.layoutBox);let a=this.treeScale.x,o=this.treeScale.y;Fe(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=G());let{target:s}=e;s?(!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Is(this.prevProjectionDelta.x,this.projectionDelta.x),Is(this.prevProjectionDelta.y,this.projectionDelta.y)),Ws(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.treeScale.x===a&&this.treeScale.y===o&&fc(this.projectionDelta.x,this.prevProjectionDelta.x)&&fc(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners(`projectionUpdate`,s)),bs.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=ro(),this.projectionDelta=ro(),this.projectionDeltaWithTransform=ro()}setAnimationOrigin(e,t=!1,n){let r=this.snapshot,i=r?r.latestValues:{},a={...this.latestValues},o=ro();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let s=G(),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(Xc));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?Ms(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?Kc(o[r],e[r],this.layout.layoutBox[r],l[t*2],l[t*2+1]):qc(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){Js(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0);let e=this.relativeTargetOrigin,t=s;if(Yc(this.relativeTarget,e,t,n),this.isSpringLayout){let e=this.relativeTarget,t=this.impulse||0,n=this.relativeStart,r=zn.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&&cc(this.relativeTarget,f)&&(this.isProjectionDirty=!1),f||=G(),Fs(f,this.relativeTarget)}c&&(this.animationValues=a,Ds(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&&=(gn(this.pendingAnimation),void 0),this.pendingAnimation=W.update(()=>{xc.hasAnimatedSinceResize=!0,this.motionValue||=An(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=Ns(e,t&&Math.sqrt(Vs(t.x)*Vs(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)=>ge({...r,keyframes:n?[e[n-1],0]:r.keyframes,velocity:t})),a=i.length;t&&i.push(ge({...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=te(c),c.next(0),this.edgeVelocity=e=>i[e+1].velocity(o),c}}}}}let a=Qe(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,rn(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?.(Cc),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&&$c(this.options.animationType,this.layout.layoutBox,n.layoutBox)){let{layoutBox:e}=this.layout,t=i;i=this.target||G(),Qc(i.x,t.x,e.x),Qc(i.y,t.y,e.y)}Fs(t,i),Ce(t,r),Ws(this.projectionDeltaWithTransform,this.layoutCorrected,t,r)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new pc),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(!it(t))return;let n={};for(let t=0;t<Sc.length;t++)Tc(Sc[t],e,n,this.animationValues);for(let t=0;t<ot.length;t++)Tc(ot[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=Jr(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=Jr(t?.pointerEvents)||``),this.hasProjected&&!D(this.latestValues)&&(e.transform=r?r({},``):`none`,this.hasProjected=!1);return}e.visibility=``;let i=n.animationValues||n.latestValues;this.applyTransformsToTarget();let a=_c(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 $n){if(i[t]===void 0)continue;let{correct:r,applyTo:o,isCSSVariable:s}=$n[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?Jr(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(Fc),this.root.sharedNodes.clear()}}}function Ac(e){e.updateLayout(),Rc(e)}function jc(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`)vc(e=>{let t=Vs(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`;Ps(r[e],a[e])}else $c(i,t.layoutBox,n)&&vc(t=>{let n=Vs(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=ro();Ws(c,n,t.layoutBox);let l=ro();Ws(l,a?e.applyTransform(r,!0):n,s);let u=!oc(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=G();Js(c,a?e.resumeFrom.applyTransform(t.layoutBox,!0,void 0,!0,f.depth+1):t.layoutBox,r.layoutBox,s);let l=G();Js(l,n,i.layoutBox,s),a&&o(c,l),uc(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 Mc(e){bs.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 Nc(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Pc(e){e.clearSnapshot()}function Fc(e){e.clearMeasurements()}function Ic(e){e.isLayoutDirty=!0,e.updateLayout()}function Lc(e){e.isLayoutDirty=!1}function Rc(e){let{snapshot:t,dragAncestor:n}=e,r=n?.isAnimationBlocked&&n.layout;if(!t||!r||e.resumeFrom||e.isAnimationBlocked)return;let i=n.dragSnapshot;vc(e=>et(t.layoutBox[e],r.layoutBox[e].min-i.layoutBox[e].min))}function zc(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.dragSnapshot||e.layout,e.isLayoutDirty=!0)}function Bc(e){e.relativeTarget&&e.relativeParent?.isLayoutDirty&&(e.currentAnimation?e.isLayoutDirty=!0:(e.targetDelta=void 0,e.removeRelativeTarget()))}function Vc(e){let{visualElement:t}=e.options;t?.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function Hc(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Uc(e){e.resolveTargetDelta()}function Wc(e){e.calcProjection()}function Gc(e){e.resetSkewAndRotation()}function Kc(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 qc(e,t,n){e.translate=L(t.translate,0,n),e.scale=L(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Jc(e,t,n,r){e.min=L(t.min,n.min,r),e.max=L(t.max,n.max,r)}function Yc(e,t,n,r){Jc(e.x,t.x,n.x,r),Jc(e.y,t.y,n.y,r)}function Xc(e){return e.animationValues?.opacityExit!==void 0}var Zc={duration:.45,ease:[.4,0,.1,1]};function Qc(e,t,n){e.max=Vs(n)+(e.min=t.min)}function $c(e,t,n){return e===`position`||e===`preserve-aspect`&&!Hs(dc(t),dc(n),.2)}function el(e){return e!==e.root&&e.scroll?.wasRoot}function tl(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}var nl=kc({attachResizeListener:(e,t)=>tl(e,`resize`,t),measureScroll:ke,checkIsScrollRoot:()=>!0}),rl=kc({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!so.current){let e=new nl({});e.mount(window),e.setOptions({layoutScroll:!0}),so.current=e}return so.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>window.getComputedStyle(e).position===`fixed`}),il=class extends Hi{constructor(){super(...arguments),this.KeyframeResolver=F}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;Sn(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}};function al(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 ol(e){return window.getComputedStyle(e)}var sl=class extends il{constructor(){super(...arguments),this.type=`html`,this.renderInstance=al}mount(e){super.mount(e)}readValueFromInstance(e,t){if(dn.has(t))return this.projection?.isProjecting?fn(t):pn(e,t);{let n=ol(e),r=(In(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){Rn(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return Fi(e,t,n)}},cl=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1;function ll(e){return{point:{x:e.pageX,y:e.pageY}}}var ul=e=>t=>cl(t)&&e(t,ll(t));function dl(e,t,n,r){return tl(e,t,ul(n),r)}var fl=new WeakMap,pl,ml=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:C(r)&&`getBBox`in r?r.getBBox()[t]:r[n],hl=ml(`inline`,`width`,`offsetWidth`),gl=ml(`block`,`height`,`offsetHeight`);function _l({target:e,borderBoxSize:t}){fl.get(e)?.forEach(n=>{n(e,{get width(){return hl(e,t)},get height(){return gl(e,t)}})})}function vl(e){e.forEach(_l)}function yl(){typeof ResizeObserver<`u`&&(pl=new ResizeObserver(vl))}function bl(e,t){pl||yl();let n=k(e);return n.forEach(e=>{let n=fl.get(e);n||(n=new Set,fl.set(e,n)),n.add(t),pl?.observe(e)}),()=>{n.forEach(e=>{let n=fl.get(e);n?.delete(t),n?.size||pl?.unobserve(e)})}}var xl=new Set,Sl;function Cl(){Sl=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};xl.forEach(t=>t(e))},window.addEventListener(`resize`,Sl)}function wl(e){return xl.add(e),Sl||Cl(),()=>{xl.delete(e),!xl.size&&typeof Sl==`function`&&(window.removeEventListener(`resize`,Sl),Sl=void 0)}}function Tl(e,t){return le(typeof e==`function`?wl(e):bl(e,t))}var El=(e,t)=>Math.abs(e-t);function Dl(e,t){let n=El(e.x,t.x),r=El(e.y,t.y);return Math.sqrt(n**2+r**2)}var Ol=new Set([`auto`,`scroll`]),kl=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=jl(this.lastRawMoveEventInfo,this.transformPagePoint));let e=Nl(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=Dl(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e;this.history.push({...r,timestamp:zn.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=jl(t,this.transformPagePoint),this.hasPendingMove=!0,W.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=Nl(e.type===`pointercancel`?this.lastMoveEventInfo:jl(t,this.transformPagePoint),this.history);this.startEvent&&n?.(e,a),r?.(e,a)},!cl(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=s?0:a,this.contextWindow=r||window;let c=ll(e),l=jl(c,this.transformPagePoint),{point:u}=l;this.history=[{...u,timestamp:zn.now()}];let{onSessionStart:d}=t;d&&d(e,Nl(l,this.history));let f={passive:!0,capture:!0};this.removeListeners=ie(dl(this.contextWindow,`pointermove`,this.handlePointerMove,f),dl(this.contextWindow,`pointerup`,this.handlePointerUp,f),dl(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);(Ol.has(e.overflowX)||Ol.has(e.overflowY))&&this.scrollPositions.set(t,Al(t)),t=t.parentElement}this.scrollPositions.set(window,Al(window)),this.removeScrollListeners=ie(tl(window,`scroll`,this.onElementScroll,{capture:!0}),tl(window,`scroll`,this.onWindowScroll,{}))}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===window,r=Al(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),W.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners?.(),this.removeScrollListeners?.(),this.scrollPositions.clear(),gn(this.updatePoint)}},Al=e=>e===window?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop};function jl(e,t){return t?{point:t(e.point)}:e}function Ml(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Nl({point:e},t){return{point:e,delta:Ml(e,Fl(t)),offset:Ml(e,Pl(t)),velocity:Il(t,.1)}}function Pl(e){return e[0]}function Fl(e){return e[e.length-1]}function Il(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=Fl(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Dn(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>Dn(t)*2&&(r=e[1]);let a=jn(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 Ll=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]);function Rl(e){return Ll.has(e.tagName)||e.isContentEditable===!0}var zl=new Set([`INPUT`,`SELECT`,`TEXTAREA`]);function Bl(e){return zl.has(e.tagName)||e.isContentEditable===!0}var Vl={x:!1,y:!1};function Hl(){return Vl.x||Vl.y}function Ul(e){return e===`x`||e===`y`?Vl[e]?null:(Vl[e]=!0,()=>{Vl[e]=!1}):Vl.x||Vl.y?null:(Vl.x=Vl.y=!0,()=>{Vl.x=Vl.y=!1})}function Wl(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?L(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?L(n,e,r.max):Math.min(e,n)),e}function Gl(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 Kl(e,{top:t,left:n,bottom:r,right:i}){return{x:Gl(e.x,n,i),y:Gl(e.y,t,r)}}function ql(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 Jl(e,t){return{x:ql(e.x,t.x),y:ql(e.y,t.y)}}function Yl(e,t){let n=.5,r=Vs(e),i=Vs(t);return i>r?n=M(t.min,t.max-r,e.min):r>i&&(n=M(e.min,e.max-i,t.min)),Vn(0,1,n)}function Xl(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 Zl=.35;function Ql(e=Zl){return e===!1?e=0:e===!0&&(e=Zl),{x:$l(e,`left`,`right`),y:$l(e,`top`,`bottom`)}}function $l(e,t,n){return{min:eu(e,t),max:eu(e,n)}}function eu(e,t){return typeof e==`number`?e:e[t]||0}function tu(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 nu=new WeakMap,ru=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=G(),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=Ul(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),vc(e=>{let t=this.getAxisMotionValue(e).get()||0;if(xn(t)&&(t=ue(t,this.visualElement.current)||0),wn.test(t))t=parseFloat(t);else if(nn.test(t)){let n=o?.layout?.layoutBox[e];n&&(t=Vs(n)*(parseFloat(t)/100))}this.originPoint[e]=t}),this.point=typeof r==`function`&&r(this),a&&W.update(()=>a(e,t),!1,!0),fs(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=lu(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&&W.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 kl(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&&W.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||!cu(e,n,this.currentDirection))return;let r=this.getAxisMotionValue(e),i=this.originPoint[e]+t[e],a=this.constraints&&this.constraints[e];a&&(i=Wl(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;iu(e)?this.constraints&&this.scroll===tu(n)||(this.constraints=this.resolveRefConstraints()):this.constraints=e&&r&&typeof e==`object`?Kl(r.layoutBox,e):!1,this.elastic=Ql(t),i!==this.constraints&&!iu(e)&&r&&this.constraints&&!this.hasMutatedConstraints&&vc(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=Xl(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!iu(e))return!1;let n=au(e),{projection:r}=this.visualElement;if(!r||!r.layout)return!1;this.scroll=tu(r);let i=Ae(n,r.root,this.visualElement.getTransformPagePoint()),a=Jl(r.layout.layoutBox,r.removeElementScroll(i));if(t){let e=t(he(a));this.hasMutatedConstraints=!!e,e&&(a=rt(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)&&cu(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=vc(e=>{if(!cu(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 fs(this.visualElement,e),n.start(ee(e,n,0,t,this.visualElement,!1))}stopAnimation(){vc(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();vc(e=>{if(!cu(e,n,this.currentDirection))return;let t=this.getAxisMotionValue(e),{min:r,max:o}=a[e];t.set((t.get()||0)+i[e]-L(r,o,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!iu(t)||!n||!this.constraints)return;this.stopAnimation();let r=this.constraints,i={x:0,y:0};vc(e=>{let t=this.getAxisMotionValue(e).get();i[e]=Yl({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(),vc(t=>{let n=this.getAxisMotionValue(t);if(!cu(t,e,null)||!n.get())return;let{min:r,max:a}=this.constraints[t];n.set(L(r,a,i[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;nu.set(this.visualElement,this);let e=this.visualElement.current,t=dl(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&Bl(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps(),r=iu(t)&&au(t);r&&(this.constraints=this.resolveRefConstraints(),n||=su(e,r,()=>this.scalePositionWithinConstraints()))},{projection:i}=this.visualElement,a=i.addEventListener(`measure`,r);i.layout||(i.root?.updateScroll(),i.updateLayout()),W.read(r);let o=tl(window,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(vc(t=>{if(!cu(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=Zl,dragMomentum:n=!0}=e;return{...e,dragElastic:t,dragMomentum:n}}};function iu(e){return!!e&&typeof e==`object`&&(`current`in e||`nodeType`in e)}var au=e=>`current`in e?e.current:e;function ou(e){let t=!0;return()=>{t?t=!1:e()}}function su(e,t,n){let r=Tl(e,ou(n)),i=Tl(t,ou(n));return()=>{r(),i()}}function cu(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function lu(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}function uu(e,t){let n=k(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},le(()=>r.abort())]}function du(e){return!(e.pointerType===`touch`||Hl())}function fu(e,t,n={}){t=He(t);let[r,i,a]=uu(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(!du(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 pu=(e,t)=>t?e===t||pu(e,t.parentElement):!1,mu=new WeakSet;function hu(e){return t=>{t.key===`Enter`&&e(t)}}function gu(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}var _u=(e,t)=>{let n=!1,r=hu(()=>{n||mu.has(e)||(n=!0,gu(e,`down`))}),i=hu(()=>{n&&(n=!1,gu(e,`up`))});e.addEventListener(`keydown`,r,t),e.addEventListener(`keyup`,i,t),e.addEventListener(`blur`,()=>{e.removeEventListener(`keydown`,r),e.removeEventListener(`keyup`,i),n&&gu(e,`cancel`)},{...t,once:!0})};function vu(e){return cl(e)&&!Hl()}var yu=new WeakSet,bu=100,xu=8,Su=(e,t,n)=>Math.hypot(e.clientX-t.clientX,e.clientY-t.clientY)>n,Cu=e=>e.preventDefault();function wu(e,t,n={}){t=He(t);let[r,i,a]=uu(e,n),o=new WeakMap,s=e=>{let r=e.currentTarget;if(!vu(e)||yu.has(e))return;n.stopPropagation&&yu.add(e);let{count:a=1,countTimeout:s=.3,hold:c=0,repeat:l}=n,u=zn.now(),d=Dn(c),f=Dn(s),p=o.get(r);p?.expire(Su(p.event,e,bu))?p=void 0:p&&(gn(p.expire),o.delete(r));let m=p?p.count+1:1,h=m>=a,g=h&&(c||l),_=!c,v=0,y;if(mu.add(r),p)y=p.handlers;else{let n=t(r,e);y=typeof n==`function`?{onComplete:n}:n||{}}h&&_&&y.onActive?.();let b=Dn(l),x=d||b,S=u+x,C=!0,w=()=>{if(i.signal.aborted)return gn(w);let e=Math.min(1-(S-zn.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):gn(w))},T={...i,capture:!0},E=(t,n)=>{if(cl(t)){if(window.removeEventListener(`pointerup`,D,T),window.removeEventListener(`pointercancel`,O,T),window.removeEventListener(`pointermove`,k,T),r.removeEventListener(`contextmenu`,Cu),gn(w),mu.delete(r),Hl()&&(n=!1),n&&!h){let n=zn.now(),a=e=>{let s=i.signal.aborted;if(s||e===!0||zn.now()-n>f)return gn(a),o.delete(r),s||y.onComplete?.(t,{success:!1}),!0};o.set(r,{count:m,event:e,handlers:y,expire:a}),W.update(a,!0)}else y.onComplete?.(t,{success:n&&_})}},D=e=>{E(e,r===window||r===document||n.useGlobalTarget||pu(r,e.target))},O=e=>{E(e,!1)},k=t=>{cl(t)&&((l||!_)&&Su(e,t,xu)||a>1&&Hl())&&O(t)};window.addEventListener(`pointerup`,D,T),window.addEventListener(`pointercancel`,O,T),(g||a>1)&&window.addEventListener(`pointermove`,k,T),g&&(W.update(w,!0),r.addEventListener(`contextmenu`,Cu,{...i,passive:!1}))};return r.forEach(e=>{(n.useGlobalTarget?window:e).addEventListener(`pointerdown`,s,i),Be(e)&&(e.addEventListener(`focus`,()=>_u(e,i),i),!Rl(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function Tu(...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=st(i,a,o);return t?s(r):s}var Eu=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},Du=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 Ou(e,t,n,r){al(e,t,void 0,r);for(let n in t.attrs)e.setAttribute(Du.has(n)?n:j(n),t.attrs[n])}var ku=class extends il{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=G}getBaseTargetFromProps(e,t){return dn.has(t)?super.getBaseTargetFromProps(e,t)??fn(t):e[t]}getDefaultValue(e){return dn.has(e)?this.latestValues[e]??fn(e):void 0}readValueFromInstance(e,t){if(dn.has(t)){let e=ln(t);return e&&e.default||0}if(kn.includes(t)){let n=getComputedStyle(e)[t];if(typeof n==`string`&&n)return n.trim()}return t=Du.has(t)?t:j(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return ua(e,t,n)}build(e,t,n){bn(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){Ou(e,t,n,r)}mount(e){this.isSVGTag=Ga(e.tagName),super.mount(e)}};function Au(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 ju=[...Ki].reverse(),Mu=e=>e?.out===!0?e:e?.out;function Nu(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>vs(e,t,n))),n=Fu(),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`&&as(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&&Mu(f(l??(g&&g.props.initial))?.transition);if(ju.forEach((t,r)=>{let i=n[t],l=o[t],f=g&&g.props[t],v=l===void 0?bi(f)||f===!1?f:void 0:l,y=bi(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||Ya(v)||typeof v==`boolean`)return;if(b===!1&&(h=r),t===`exit`&&i.isActive&&b!==!0){m={...m,...i.prevResolvedValues};return}let S=Pu(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}=as(e,n,os(e,t))||{};E={...E,...a,...i},D=Mu(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)?!Au(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=as(s,n)?.transition?.delayChildren;r.delay=is(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&&!Sn(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=Fu(),i=!0}}}function Pu(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!Au(t,e):!1}function Fu(){let e={};for(let t of Ki)e[t]={isActive:t===`animate`,protectedKeys:{},needsAnimating:{},prevResolvedValues:{},out:{}};return e}var Iu=()=>/[#*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,Lu=e=>{let t=Iu();return e.match(t)?.[0]},K=Kt(),q=t(Pt(),1),Ru=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)},zu=(e,t)=>Math.floor(e/10**t%10),Bu=(e,t)=>!(zu(e,t)%2),Vu=(e,t,n)=>{let r=e%t;return n&&zu(e,n)%2==0?-r:r},Hu=(e,t,n)=>t[e%n],Uu=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`},Wu=4,J=80;function Gu(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:Wu},(e,i)=>({color:Hu(n+i,t,r),translateX:Vu(n*(i+1),J/2-(i+17),1),translateY:Vu(n*(i+1),J/2-(i+17),2),rotate:Vu(n*(i+1),360),isSquare:Bu(n,2)}))}var Ku=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Gu(e,t),s=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:J,height:J,children:(0,K.jsx)(`rect`,{width:J,height:J,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,K.jsx)(`rect`,{width:J,height:J,fill:o[0].color}),(0,K.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,K.jsx)(`circle`,{cx:J/2,cy:J/2,fill:o[2].color,r:J/5,transform:`translate(`+o[2].translateX+` `+o[2].translateY+`)`}),(0,K.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)`})]})]})},qu=90,Ju=5;function Yu(e,t){let n=Ru(e),r=t&&t.length,i=Array.from({length:Ju},(e,i)=>Hu(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 Xu=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=Yu(e,t),s=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:qu,height:qu,children:(0,K.jsx)(`rect`,{width:qu,height:qu,rx:r?void 0:180,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,K.jsx)(`path`,{d:`M0 0h90v45H0z`,fill:o[0]}),(0,K.jsx)(`path`,{d:`M0 45h90v45H0z`,fill:o[1]}),(0,K.jsx)(`path`,{d:`M83 45a38 38 0 00-76 0h76z`,fill:o[2]}),(0,K.jsx)(`path`,{d:`M83 45a38 38 0 01-76 0h76z`,fill:o[3]}),(0,K.jsx)(`path`,{d:`M77 45a32 32 0 10-64 0h64z`,fill:o[4]}),(0,K.jsx)(`path`,{d:`M77 45a32 32 0 11-64 0h64z`,fill:o[5]}),(0,K.jsx)(`path`,{d:`M71 45a26 26 0 00-52 0h52z`,fill:o[6]}),(0,K.jsx)(`path`,{d:`M71 45a26 26 0 01-52 0h52z`,fill:o[7]}),(0,K.jsx)(`circle`,{cx:45,cy:45,r:23,fill:o[8]})]})]})},Zu=64,Qu=80;function $u(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:Zu},(e,i)=>Hu(n%(i+1),t,r))}var ed=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=$u(e,t),s=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:s,"mask-type":`alpha`,maskUnits:`userSpaceOnUse`,x:0,y:0,width:Qu,height:Qu,children:(0,K.jsx)(`rect`,{width:Qu,height:Qu,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,K.jsx)(`rect`,{width:10,height:10,fill:o[0]}),(0,K.jsx)(`rect`,{x:20,width:10,height:10,fill:o[1]}),(0,K.jsx)(`rect`,{x:40,width:10,height:10,fill:o[2]}),(0,K.jsx)(`rect`,{x:60,width:10,height:10,fill:o[3]}),(0,K.jsx)(`rect`,{x:10,width:10,height:10,fill:o[4]}),(0,K.jsx)(`rect`,{x:30,width:10,height:10,fill:o[5]}),(0,K.jsx)(`rect`,{x:50,width:10,height:10,fill:o[6]}),(0,K.jsx)(`rect`,{x:70,width:10,height:10,fill:o[7]}),(0,K.jsx)(`rect`,{y:10,width:10,height:10,fill:o[8]}),(0,K.jsx)(`rect`,{y:20,width:10,height:10,fill:o[9]}),(0,K.jsx)(`rect`,{y:30,width:10,height:10,fill:o[10]}),(0,K.jsx)(`rect`,{y:40,width:10,height:10,fill:o[11]}),(0,K.jsx)(`rect`,{y:50,width:10,height:10,fill:o[12]}),(0,K.jsx)(`rect`,{y:60,width:10,height:10,fill:o[13]}),(0,K.jsx)(`rect`,{y:70,width:10,height:10,fill:o[14]}),(0,K.jsx)(`rect`,{x:20,y:10,width:10,height:10,fill:o[15]}),(0,K.jsx)(`rect`,{x:20,y:20,width:10,height:10,fill:o[16]}),(0,K.jsx)(`rect`,{x:20,y:30,width:10,height:10,fill:o[17]}),(0,K.jsx)(`rect`,{x:20,y:40,width:10,height:10,fill:o[18]}),(0,K.jsx)(`rect`,{x:20,y:50,width:10,height:10,fill:o[19]}),(0,K.jsx)(`rect`,{x:20,y:60,width:10,height:10,fill:o[20]}),(0,K.jsx)(`rect`,{x:20,y:70,width:10,height:10,fill:o[21]}),(0,K.jsx)(`rect`,{x:40,y:10,width:10,height:10,fill:o[22]}),(0,K.jsx)(`rect`,{x:40,y:20,width:10,height:10,fill:o[23]}),(0,K.jsx)(`rect`,{x:40,y:30,width:10,height:10,fill:o[24]}),(0,K.jsx)(`rect`,{x:40,y:40,width:10,height:10,fill:o[25]}),(0,K.jsx)(`rect`,{x:40,y:50,width:10,height:10,fill:o[26]}),(0,K.jsx)(`rect`,{x:40,y:60,width:10,height:10,fill:o[27]}),(0,K.jsx)(`rect`,{x:40,y:70,width:10,height:10,fill:o[28]}),(0,K.jsx)(`rect`,{x:60,y:10,width:10,height:10,fill:o[29]}),(0,K.jsx)(`rect`,{x:60,y:20,width:10,height:10,fill:o[30]}),(0,K.jsx)(`rect`,{x:60,y:30,width:10,height:10,fill:o[31]}),(0,K.jsx)(`rect`,{x:60,y:40,width:10,height:10,fill:o[32]}),(0,K.jsx)(`rect`,{x:60,y:50,width:10,height:10,fill:o[33]}),(0,K.jsx)(`rect`,{x:60,y:60,width:10,height:10,fill:o[34]}),(0,K.jsx)(`rect`,{x:60,y:70,width:10,height:10,fill:o[35]}),(0,K.jsx)(`rect`,{x:10,y:10,width:10,height:10,fill:o[36]}),(0,K.jsx)(`rect`,{x:10,y:20,width:10,height:10,fill:o[37]}),(0,K.jsx)(`rect`,{x:10,y:30,width:10,height:10,fill:o[38]}),(0,K.jsx)(`rect`,{x:10,y:40,width:10,height:10,fill:o[39]}),(0,K.jsx)(`rect`,{x:10,y:50,width:10,height:10,fill:o[40]}),(0,K.jsx)(`rect`,{x:10,y:60,width:10,height:10,fill:o[41]}),(0,K.jsx)(`rect`,{x:10,y:70,width:10,height:10,fill:o[42]}),(0,K.jsx)(`rect`,{x:30,y:10,width:10,height:10,fill:o[43]}),(0,K.jsx)(`rect`,{x:30,y:20,width:10,height:10,fill:o[44]}),(0,K.jsx)(`rect`,{x:30,y:30,width:10,height:10,fill:o[45]}),(0,K.jsx)(`rect`,{x:30,y:40,width:10,height:10,fill:o[46]}),(0,K.jsx)(`rect`,{x:30,y:50,width:10,height:10,fill:o[47]}),(0,K.jsx)(`rect`,{x:30,y:60,width:10,height:10,fill:o[48]}),(0,K.jsx)(`rect`,{x:30,y:70,width:10,height:10,fill:o[49]}),(0,K.jsx)(`rect`,{x:50,y:10,width:10,height:10,fill:o[50]}),(0,K.jsx)(`rect`,{x:50,y:20,width:10,height:10,fill:o[51]}),(0,K.jsx)(`rect`,{x:50,y:30,width:10,height:10,fill:o[52]}),(0,K.jsx)(`rect`,{x:50,y:40,width:10,height:10,fill:o[53]}),(0,K.jsx)(`rect`,{x:50,y:50,width:10,height:10,fill:o[54]}),(0,K.jsx)(`rect`,{x:50,y:60,width:10,height:10,fill:o[55]}),(0,K.jsx)(`rect`,{x:50,y:70,width:10,height:10,fill:o[56]}),(0,K.jsx)(`rect`,{x:70,y:10,width:10,height:10,fill:o[57]}),(0,K.jsx)(`rect`,{x:70,y:20,width:10,height:10,fill:o[58]}),(0,K.jsx)(`rect`,{x:70,y:30,width:10,height:10,fill:o[59]}),(0,K.jsx)(`rect`,{x:70,y:40,width:10,height:10,fill:o[60]}),(0,K.jsx)(`rect`,{x:70,y:50,width:10,height:10,fill:o[61]}),(0,K.jsx)(`rect`,{x:70,y:60,width:10,height:10,fill:o[62]}),(0,K.jsx)(`rect`,{x:70,y:70,width:10,height:10,fill:o[63]})]})]})},td=36;function nd(e,t){let n=Ru(e),r=t&&t.length,i=Hu(n,t,r),a=Vu(n,10,1),o=a<5?a+td/9:a,s=Vu(n,10,2),c=s<5?s+td/9:s;return{wrapperColor:i,faceColor:Uu(i),backgroundColor:Hu(n+13,t,r),wrapperTranslateX:o,wrapperTranslateY:c,wrapperRotate:Vu(n,360),wrapperScale:1+Vu(n,td/12)/10,isMouthOpen:Bu(n,2),isCircle:Bu(n,1),eyeSpread:Vu(n,5),mouthSpread:Vu(n,3),faceRotate:Vu(n,10,3),faceTranslateX:o>td/6?o/2:Vu(n,8,1),faceTranslateY:c>td/6?c/2:Vu(n,7,2)}}var rd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=nd(e,t),s=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:td,height:td,children:(0,K.jsx)(`rect`,{width:td,height:td,rx:r?void 0:72,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,K.jsx)(`rect`,{width:td,height:td,fill:o.backgroundColor}),(0,K.jsx)(`rect`,{x:`0`,y:`0`,width:td,height:td,transform:`translate(`+o.wrapperTranslateX+` `+o.wrapperTranslateY+`) rotate(`+o.wrapperRotate+` 18 18) scale(`+o.wrapperScale+`)`,fill:o.wrapperColor,rx:o.isCircle?td:td/6}),(0,K.jsxs)(`g`,{transform:`translate(`+o.faceTranslateX+` `+o.faceTranslateY+`) rotate(`+o.faceRotate+` 18 18)`,children:[o.isMouthOpen?(0,K.jsx)(`path`,{d:`M15 `+(19+o.mouthSpread)+`c2 1 4 1 6 0`,stroke:o.faceColor,fill:`none`,strokeLinecap:`round`}):(0,K.jsx)(`path`,{d:`M13,`+(19+o.mouthSpread)+` a1,0.75 0 0,0 10,0`,fill:o.faceColor}),(0,K.jsx)(`rect`,{x:14-o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor}),(0,K.jsx)(`rect`,{x:20+o.eyeSpread,y:14,width:1.5,height:2,rx:1,stroke:`none`,fill:o.faceColor})]})]})]})},id=4,ad=80;function od(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:id},(e,i)=>Hu(n+i,t,r))}var sd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=od(e,t),s=e.replace(/\s/g,``),c=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:c,maskUnits:`userSpaceOnUse`,x:0,y:0,width:ad,height:ad,children:(0,K.jsx)(`rect`,{width:ad,height:ad,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${c})`,children:[(0,K.jsx)(`path`,{fill:`url(#gradient_paint0_linear_`+s+`)`,d:`M0 0h80v40H0z`}),(0,K.jsx)(`path`,{fill:`url(#gradient_paint1_linear_`+s+`)`,d:`M0 40h80v40H0z`})]}),(0,K.jsxs)(`defs`,{children:[(0,K.jsxs)(`linearGradient`,{id:`gradient_paint0_linear_`+s,x1:ad/2,y1:0,x2:ad/2,y2:ad/2,gradientUnits:`userSpaceOnUse`,children:[(0,K.jsx)(`stop`,{stopColor:o[0]}),(0,K.jsx)(`stop`,{offset:1,stopColor:o[1]})]}),(0,K.jsxs)(`linearGradient`,{id:`gradient_paint1_linear_`+s,x1:ad/2,y1:ad/2,x2:ad/2,y2:ad,gradientUnits:`userSpaceOnUse`,children:[(0,K.jsx)(`stop`,{stopColor:o[2]}),(0,K.jsx)(`stop`,{offset:1,stopColor:o[3]})]})]})]})},cd=3,ld=80;function ud(e,t){let n=Ru(e),r=t&&t.length;return Array.from({length:cd},(e,i)=>({color:Hu(n+i,t,r),translateX:Vu(n*(i+1),ld/10,1),translateY:Vu(n*(i+1),ld/10,2),scale:1.2+Vu(n*(i+1),ld/20)/10,rotate:Vu(n*(i+1),360,1)}))}var dd=({name:e,colors:t,title:n,square:r,size:i,...a})=>{let o=ud(e,t),s=q.useId();return(0,K.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,K.jsx)(`title`,{children:e}),(0,K.jsx)(`mask`,{id:s,maskUnits:`userSpaceOnUse`,x:0,y:0,width:ld,height:ld,children:(0,K.jsx)(`rect`,{width:ld,height:ld,rx:r?void 0:160,fill:`#FFFFFF`})}),(0,K.jsxs)(`g`,{mask:`url(#${s})`,children:[(0,K.jsx)(`rect`,{width:ld,height:ld,fill:o[0].color}),(0,K.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,K.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,K.jsx)(`defs`,{children:(0,K.jsxs)(`filter`,{id:`filter_${s}`,filterUnits:`userSpaceOnUse`,colorInterpolationFilters:`sRGB`,children:[(0,K.jsx)(`feFlood`,{floodOpacity:0,result:`BackgroundImageFix`}),(0,K.jsx)(`feBlend`,{in:`SourceGraphic`,in2:`BackgroundImageFix`,result:`shape`}),(0,K.jsx)(`feGaussianBlur`,{stdDeviation:7,result:`effect1_foregroundBlur`})]})})]})},fd={pixel:ed,bauhaus:Ku,ring:Xu,beam:rd,sunset:sd,marble:dd,geometric:rd,abstract:Ku},pd=({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=fd[e]||dd;return(0,K.jsx)(s,{colors:t,name:n,title:r,size:i,square:a,...o})},md=Nt({block:`img`,elements:[]}),hd=e=>(0,q.memo)(t=>(0,q.createElement)(e,t)),gd=({unoptimized:e,...t})=>{let n=(0,q.use)(ze),r=n?.imgAs||`img`,i=(0,q.useMemo)(()=>hd(r),[r]);return(0,K.jsx)(i,{unoptimized:e===void 0?n?.imgUnoptimized:e,...t,className:U(md(),t.className)})};gd.displayName=`Img`;var _d=Nt({block:`fluent-emoji`,elements:[]}),vd={container:{kLWn49:`lbo5v014`,kVAEAm:`lb1n2onr6`,k9WMMc:`lb2b8uid`,$$css:!0}};function yd(e){return[...e].map(e=>e?.codePointAt(0)?.toString(16)).join(`-`)}function bd(e){let t=yd(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 xd=(e,t)=>{let n=[`anim`,`3d`].includes(t)?`webp`:`svg`;switch(t){case`raw`:return null;case`anim`:return{path:`assets/${yd(e)}.${n}`,pkg:bd(e),version:`latest`};case`3d`:return{path:`assets/${yd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-3d`,version:`latest`};case`flat`:return{path:`assets/${yd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-flat`,version:`latest`};case`modern`:return{path:`assets/${yd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-modern`,version:`latest`};case`mono`:return{path:`assets/${yd(e)}.${n}`,pkg:`@lobehub/fluent-emoji-mono`,version:`latest`}}},Sd=({emoji:e,className:t,style:n,type:r=`3d`,size:i=40,unoptimized:a,ref:o,...s})=>{let[c,l]=(0,q.useState)(!1),u=I(),d=(0,q.useMemo)(()=>xd(e,r),[r,e]);return r===`raw`||!d||c?(0,K.jsx)(hn,{flex:`none`,height:i,ref:o,role:`img`,width:i,...s,...H(vd.container,U(_d(),t),{fontSize:i*.9,...n}),children:e}):(0,K.jsx)(gd,{alt:e,className:U(_d(),t),height:i,loading:`lazy`,ref:o,src:u(d),style:{flex:`none`,...n},unoptimized:a,width:i,onError:()=>l(!0),...s})};Sd.displayName=`FluentEmoji`;var Cd=e=>`oklch(from ${e} clamp(0, (l - 0.62) * -1000, 1) 0 h / 1)`,wd=Nt({block:`avatar`,dataAttributes:[`shape`,`variant`,`shadow`],elements:[`loading`,`img`,`content`,`fallback`]}),Td=Nt({block:`avatar-group`,elements:[`avatar`,`count`,`item`,`badge`]}),Ed={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}},Dd=e=>e?!!(typeof e==`string`&&[`/`,`http`,`data:`].some(t=>e.startsWith(t))||(0,q.isValidElement)(e)):!1,Od=e=>!!(e&&e!==`transparent`&&e!==`rgba(0,0,0,0)`&&e!==null),kd=(e,t)=>{if(!e)return``;let n=e.toUpperCase();return t?n.slice(0,2):n},Ad=(e,t,n)=>n?t?e*.85:e:e*.85,jd=[`#383838`,`#7858f9`,`#f8f7bf`,`#ffdd1f`,`#f88c13`],Md=(e,t,n)=>(t||n||typeof e==`string`&&e||void 0)?.trim().replaceAll(/[\s"'()#\\]+/g,`_`)||void 0,Nd={borderless:Ve.variantBorderlessWithoutHover,filled:Ve.variantFilledWithoutHover,outlined:Ve.variantOutlinedWithoutHover},Pd=(0,q.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,q.useState)(!1),M=(0,q.useMemo)(()=>Dd(n),[n]),te=(0,q.useMemo)(()=>n&&A&&!M?Lu(n):void 0,[n,A,M]),ne=M?x:typeof n==`string`?n:void 0,N=e||x||`avatar`,re=Od(r),ie=M&&A&&!j,P=M&&!A&&!j,ae=Md(n,x,e),oe=f!==`text`&&!!ae&&!te&&!ie&&!P,F=d?.length?d:jd,se=(0,q.useMemo)(()=>te?(0,K.jsx)(Sd,{emoji:te,size:Ad(k,re,u),type:t?`anim`:`3d`,unoptimized:C}):kd(ne||x,v),[t,te,re,k,v,ne,x,C,u]),I=_!==void 0,ce=!r&&!oe&&!(M&&!j||te);return(0,K.jsxs)(`div`,{...Mt({shadow:h,shape:g,variant:w}),...O,ref:m,title:D,className:H([Ed.root,Nd[w],h&&Ed.shadow,!I&&Ed.defaultSize,!I&&!!te&&Ed.defaultEmojiFont,g===`circle`?Ed.circle:!I&&Ed.defaultSquare,ce&&Ed.defaultBackground,!r&&Ed.defaultColor,!!O?.onClick&&Ed.clickable,T],U(wd(),o,s?.root)).className,style:{...r&&{backgroundColor:r,color:Cd(r)},...I&&{fontSize:k*(te?.7:.5),height:k,width:k,...g!==`circle`&&{borderRadius:k<24?`33%`:Math.max(k/6,2)}},...i&&{boxShadow:`${Ze.colorBgLayout} 0 0 0 2px, ${a||Ze.colorTextTertiary} 0 0 0 4px`},...y,...b?.root},children:[p&&(0,K.jsx)(hn,{flex:`none`,height:`100%`,width:`100%`,...H(Ed.loading,U(wd(`loading`),s?.loading),b?.loading),children:(0,K.jsx)(yt,{spin:!0,icon:Pe})}),typeof n==`string`&&ie&&(0,K.jsx)(`img`,{alt:N,crossOrigin:c,draggable:l,height:k,loading:`lazy`,src:n,width:k,...H(Ed.img,U(wd(`img`),s?.img),b?.img),onError:()=>ee(!0)}),oe&&(0,K.jsx)(pd,{square:!0,"aria-label":N,colors:F,name:ae,size:`100%`,variant:f,...H(Ed.fallback,U(wd(`fallback`),s?.fallback),b?.fallback)}),!ie&&!oe&&(0,K.jsx)(`span`,{...H([Ed.content,E],U(wd(`content`),s?.content),b?.content),children:P?n:se})]})});Pd.displayName=`Avatar`;var Fd=Pd,Id={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}},Ld=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.currentTarget.click())},Rd=(0,q.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,K.jsxs)(sn,{horizontal:!0,gap:n,ref:g,...H(Id.root,U(Td(),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,K.jsx)(Pd,{"aria-disabled":l||void 0,"aria-label":s,"aria-pressed":g?!!c:void 0,className:U(Td(`avatar`),f?.avatar,a),nativeTitle:s,role:g?`button`:void 0,tabIndex:g?0:void 0,xstyle:Id.avatar,style:{...!u&&v,...o&&{boxShadow:`0 0 0 2px ${o}`},...m?.avatar,...i},onKeyDown:g?Ld:void 0,onClick:g?d??(()=>h?.({item:t,key:r})):void 0,...T,...p},u?void 0:r);if(!u)return y;let b=H(Id.item,Td(`item`));return(0,K.jsxs)(`span`,{className:b.className,style:{...b.style,...v},children:[y,(0,K.jsx)(`span`,{...H(Id.badge,Td(`badge`)),children:u})]},r)}),t&&S.length>0&&(0,K.jsx)(Pd,{...T,"aria-label":w||void 0,avatar:`+${S.length}`,background:Ze.colorText,className:U(Td(`count`),f?.count),contentXstyle:Id.count,fallbackVariant:`text`,nativeTitle:w||void 0,sliceText:!1,xstyle:Id.avatar,style:{marginLeft:C,zIndex:_?0:x.length,...m?.count}})]})});Rd.displayName=`AvatarGroup`;var zd=Fd;zd.Group=Rd;function Bd({children:e,features:t,strict:n=!1}){let[,r]=(0,q.useState)(!Vd(t)),i=(0,q.useRef)(void 0);if(!Vd(t)){let{renderer:e,...n}=t;i.current=e,La(n)}return(0,q.useEffect)(()=>{Vd(t)&&t().then(({renderer:e,...t})=>{La(t),i.current=e,r(!0)})},[]),(0,K.jsx)(ji.Provider,{value:{renderer:i.current,strict:n},children:e})}function Vd(e){return typeof e==`function`}function Hd(e,t){if(typeof Proxy>`u`)return ea;let n=new Map,r=(n,r)=>ea(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,ea(a,void 0,e,t)),n.get(a))})}var Ud=Hd(),Wd=(e,t)=>t.isSVG??Sa(e)?new ku(t):new sl(t,{allowProjection:e!==q.Fragment}),Gd=class extends Eu{constructor(e){super(e),e.animationState||=Nu(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();Ya(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?.()}},Kd=0,qd={animation:{Feature:Gd},exit:{Feature:class extends Eu{constructor(){super(...arguments),this.id=Kd++}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}=as(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(){}}}},Jd=class extends Eu{constructor(e){super(e),this.removeGroupControls=_n,this.removeListeners=_n,this.controls=new ru(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||_n}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()}},Yd=e=>(t,n)=>{e&&W.update(()=>e(t,n),!1,!0)},Xd=class extends Eu{constructor(){super(...arguments),this.removePointerDownListener=_n}onPointerDown(e){this.session=new kl(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:Yd(e),onStart:Yd(t),onMove:Yd(n),onEnd:(e,t)=>{delete this.session,r&&W.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=dl(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session?.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session?.end()}},Zd=!1,Qd=({layout:e,layoutDependency:t,layoutAnchor:n})=>({layout:e,layoutDependency:t,layoutAnchor:n,animationType:typeof e==`string`?e:`both`}),$d=(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)}},ef=class extends q.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),Zd&&i.root.didUpdate(),i.options.layoutId!==r&&$d(i,r)?.(),i.addEventListener(`animationComplete`,()=>this.safeToRemove()),i.setOptions({...i.options,...Qd(this.props),onExitComplete:()=>this.safeToRemove()})),xc.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(),$d(o,n)),o.setOptions({...o.options,...Qd(this.props)}),Zd=!0,i||e.layoutDependency!==t||t===void 0||e.isPresent!==a?o.willUpdate():this.safeToRemove(),e.isPresent!==a&&(a?o.promote():o.relegate()||W.postRender(()=>{o.getStack()?.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(this.takeOver?.(),e.root.didUpdate(),Fn.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;Zd=!0,r&&(r.scheduleCheckAfterUnmount(),t.group?.remove(r),n?.deregister?.(r))}safeToRemove(){this.props.safeToRemove?.()}render(){return null}};function tf(e){let[t,n]=ye(),r=(0,q.useContext)(vn);return(0,K.jsx)(ef,{...e,layoutGroup:r,switchLayoutGroup:(0,q.useContext)(wi),isPresent:t,safeToRemove:n})}var nf={pan:{Feature:Xd},drag:{Feature:Jd,ProjectionNode:rl,MeasureLayout:tf}};function rf(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&&W.postRender(()=>s(t,ll(t)))}var af=class extends Eu{mount(){let{current:e}=this.node;e&&(this.unmount=fu(e,(e,t)=>(rf(this.node,t,`Hover`,`Start`),e=>rf(this.node,e,`Hover`,`End`))))}unmount(){}},of=class extends Eu{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=ie(tl(this.node.current,`focus`,()=>this.onFocus()),tl(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}};function sf(e,t,n,r){e.current instanceof HTMLButtonElement&&e.current.disabled||rf(e,t,`Tap`,n,r)}var cf=class extends Eu{constructor(){super(...arguments),this.options={}}mount(){let{current:e}=this.node;e&&(this.update(),this.unmount=wu(e,(e,t)=>(sf(this.node,t,`Start`),{onComplete:(e,{success:t})=>sf(this.node,e,t?``:`Cancel`),onRepeat:()=>sf(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(){}},lf=new WeakMap,uf=new WeakMap,df=e=>{let t=lf.get(e.target);t&&t(e)},ff=e=>{e.forEach(df)};function pf({root:e,...t}){let n=e||document;uf.has(n)||uf.set(n,{});let r=uf.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(ff,{root:e,...t})),r[i]}function mf(e,t,n){let r=pf(t);return lf.set(e,n),r.observe(e),()=>{lf.delete(e),r.unobserve(e)}}var hf={some:0,all:1},gf=class extends Eu{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:hf[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=mf(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(_f(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function _f({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}var vf=Object.assign({},Object.assign({renderer:Wd},qd,{inView:{Feature:gf},tap:{Feature:cf},focus:{Feature:of},hover:{Feature:af}}),nf,{layout:{ProjectionNode:rl,MeasureLayout:tf}});function yf(e){let t=On(()=>An(e)),{isStatic:n}=(0,q.useContext)(Ln);if(n){let[,n]=(0,q.useState)(e);(0,q.useEffect)(()=>t.on(`change`,n),[])}return t}function bf(e,t){let n=yf(t()),r=()=>n.set(t());return r(),Pn(()=>{let t=()=>W.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return r(),()=>{n.forEach(e=>e()),gn(r)}}),n}function xf(e){Nn.current=[],e();let t=bf(Nn.current,e);return Nn.current=void 0,t}function Sf(e,t,n,r){if(typeof e==`function`)return xf(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return wf(e,t,n,r);let i=typeof t==`function`?t:Tu(t,n,r),a=Array.isArray(e)?Cf(e,i):Cf([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 Cf(e,t){let n=On(()=>[]);return bf(e,()=>{n.length=0;let r=e.length;for(let t=0;t<r;t++)n[t]=e[t].get();return t(n)})}function wf(e,t,n,r){let i=On(()=>Object.keys(n)),a=On(()=>({}));for(let o of i)a[o]=Sf(e,t,n[o],r);return a}function Tf(){!ma.current&&Ea();let[e]=(0,q.useState)(Xi.current);return e}var Ef=(0,q.createContext)(null),Df=(0,q.createContext)(null);function Of(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:Af(t.x)+n.x,y:Af(t.y)+n.y},i=jf(e),s=i.find(t=>t.items.includes(e[o])),c=i.reduce((e,t)=>Mf(r.y,t)<Mf(r.y,e)?t:e);if(c!==s)return Nf(e,o,r.x,c,a);let l=Pf(r,t),u=-1,d=l;return e.forEach((e,t)=>{if(t===o)return;let n=Pf(r,e.layout);n<d&&(u=t,d=n)}),u===-1?e:an(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=Af(u);return s===1&&l.max+n[i]>d||s===-1&&l.min+n[i]<d?an(e,o,o+s):e}function kf(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=jf(e).sort((e,t)=>e.min-t.min),r=n[n.findIndex(({items:n})=>n.includes(e[t]))+a],i=n=>Math.abs(Af(n.layout.x)-Af(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 Af=({min:e,max:t})=>L(e,t,.5);function jf(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 Mf(e,t){return e<t.min?t.min-e:e>t.max?e-t.max:0}function Nf(e,t,n,r,i){let a=e.filter((e,n)=>n!==t),o=r.items.find(e=>{let t=Af(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 Pf(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 Ff=(e,t)=>e.max<=t.min||t.max<=e.min;function If(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||=Ff(e[r].x,e[i].x),n||=Ff(e[r].y,e[i].y),t&&n)return`xy`;return t?`x`:`y`}var Lf=(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 Rf({children:e,as:t=`ul`,axis:n,onReorder:r,values:i,onPointerDownCapture:a,onClickCapture:o,...s},c,l){let u=On(()=>l[t]),d=(0,q.useContext)(Ef),f=(0,q.useRef)(new Map),p=(0,q.useRef)(new Map),[m,h]=(0,q.useState)(),[g,_]=(0,q.useState)(`y`),v=(0,q.useRef)(!1),y=(0,q.useRef)(!1),b=(0,q.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,q.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?kf(r,i,c,x,!!l&&O()):-1;if(a>-1)n?k(an(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=If(D().map(e=>e.layout));e!==g&&_(e)}},updateOrder:(e,t,n)=>{if(v.current)return;let r=D(),i=Of(r,e,t,n,x,O()?`rtl`:`ltr`);r!==i&&(v.current=!0,y.current=!0,k(i,e))}};(0,q.useEffect)(()=>{v.current=!1},[i]),Pn(()=>d?.add(A));let j={overflowAnchor:`none`,...s.style};return(0,K.jsx)(u,{...s,style:j,ref:Lf(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,K.jsx)(Df.Provider,{value:A,children:e})})}var zf=e=>(0,q.forwardRef)((t,n)=>Rf(t,n,e)),Bf=50,Vf=1.5,Hf=new Set([`auto`,`scroll`]),Uf={x:new Map,y:new Map};function Wf(){Uf.x.clear(),Uf.y.clear()}function Gf(e,t){let n=getComputedStyle(e),r=t===`x`?n.overflowX:n.overflowY;return e===document.body||e===document.documentElement||Hf.has(r)&&(t===`x`?e.scrollWidth>e.clientWidth:e.scrollHeight>e.clientHeight)}function Kf(e,t){let n=e?.parentElement;for(;n;){if(Gf(n,t))return n;n=n.parentElement}return null}function qf(e){let t=Math.min(1,1-e/Bf);return Vf*t*t*Cn.delta}function Jf(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<Bf?{amount:-qf(o),edge:`start`}:s<Bf?{amount:qf(s),edge:`end`}:{amount:0,edge:null}}function Yf(e,t,n,r){if(!e)return;let i=Kf(e,n);if(!i)return;let{amount:a,edge:o}=Jf(t-(n===`x`?window.scrollX:window.scrollY),i,n),s=Uf[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 Xf(e,t=0){return Sn(e)?e:yf(t)}function Zf({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,q.useContext)(Df),m=(0,q.useContext)(Ef),h=(0,q.useRef)(null),g=On(()=>p.proxy[r]),_=(0,q.useRef)(),v={x:Xf(t.x),y:Xf(t.y)},y=Sf([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,q.useEffect)(()=>D);let j=(e,t)=>{_.current=t,t||m?.end(n),Mn.get(e)?.animationState?.setActive(`whileDrag`,!!t)},ee=(0,q.useRef)(!1);return Pn(()=>{m?.receive(p,n,h.current,j)&&(ee.current=!0)},[]),(0,K.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)Yf(m&&!b.includes(e)?m.column(p):C.current,i[e],e,r[e]);a&&a(e,t)},onDragEnd:(e,t)=>{w.current=!1,Wf(),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:Lf(h,f),ignoreStrict:!0,children:e})}var Qf=(0,q.forwardRef)(Zf),$f=e=>{let{left:t,top:n,width:r,height:i}=e.getBoundingClientRect();return{x:t+r/2,y:n+i/2}},ep=e=>{let{x:t,y:n}=$f(e),{scrollX:r,scrollY:i}=e.ownerDocument.defaultView;return{x:t+r,y:n+i}};function tp(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 np=(e,t)=>{let n=e.groupRef.current,r=t.groupRef.current;return n.contains(r)||r.contains(n)};function rp(e){let t=new Set,n,r=(t,n,r)=>!np(t,n)&&e.current.canMove?.(r,t.values,n.values)!==!1,i,a=(e,t,r,i,a,o)=>{let s=$f(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=>tp(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:ep(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=ep(o),n.event=s),!0;let c=$f(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=Mn.get(o);return a(e,l,i,o,{controls:u&&nu.get(u),event:s}),!0},key:(e,n,o,s,c)=>{let l=$f(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=Mn.get(r),o=a&&nu.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:(Fn.read(()=>{if(n!==s)return;n=void 0,Mn.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(ep(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 ip({children:e,...t}){let n=(0,q.useRef)(t);return Pn(()=>{n.current=t}),(0,K.jsx)(Ef.Provider,{value:On(()=>rp(n)),children:e})}var ap=(e,t,n)=>{let[r,i]=(0,q.useState)(!1),a=typeof t==`object`&&t.tooltipWhenOverflow;return(0,q.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},op=Nt({block:`text`,dataAttributes:[`type`],elements:[]}),sp={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,U((e=>H(e).className)(sp.shiny),`lobe-text-shiny`);var cp=(e={})=>[sp.text,e.as&&sp[e.as],e.code&&sp.code,e.delete&&sp.delete,e.disabled&&sp.disabled,e.ellipsis===`multi`&&sp.ellipsisMulti,e.ellipsis===!0&&sp.ellipsis,e.italic&&sp.italic,e.mark&&sp.mark,e.shiny&&sp.shiny,e.strong&&sp.strong,e.type&&sp[e.type],e.underline&&sp.underline],lp=(0,q.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,q.useRef)(null),j=ap(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)},ne={...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},N=(0,K.jsx)(t,{...Mt({type:w}),...k,ref:te,style:ne,className:H(cp({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}),U(op(),_&&`lobe-text-shiny`,r,i?.root)).className,children:n});if(l&&typeof l==`object`&&(l.tooltip||l.tooltipWhenOverflow)){if(M&&!j)return N;let e=typeof l.tooltip==`string`?l.tooltip:n;return l.tooltip&&typeof l.tooltip==`object`?(0,K.jsx)(Co,{...l.tooltip,title:l.tooltip?.title||e,children:N}):(0,K.jsx)(Co,{title:e,children:N})}return N});lp.displayName=`Text`;var up=lp,dp=e=>{e.stopPropagation()},fp=e=>{e.preventDefault(),e.stopPropagation(),e.preventBaseUIHandler?.()},pp=q.createContext({disabled:!1});function mp(){return q.useContext(pp)}function hp(e){let[t,n]=q.useState({getBoundingClientRect(){return DOMRect.fromRect({width:0,height:0,x:0,y:0})}}),r=q.useRef(null),i=q.useRef(null),a=q.useRef(null),o=q.useRef(null),s=q.useRef(!0),c=q.useRef(null),l=ht(),u=q.useMemo(()=>({anchor:t,setAnchor:n,actionsRef:a,backdropRef:r,internalBackdropRef:i,positionerRef:o,allowMouseUpTriggerRef:s,initialCursorPointRef:c,rootId:l}),[t,l]);return(0,K.jsx)(Lo.Provider,{value:u,children:(0,K.jsx)(wo.Provider,{value:void 0,children:(0,K.jsx)(To,{...e})})})}var gp=Po,Y=Nt({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`]}),_p=(0,q.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}=At(`floating`,r),o=typeof t==`function`?e=>({zIndex:i,...t(e)}):{zIndex:i,...t};return(0,K.jsx)(gp,{...n,className:U(B.positioner,Y(`positioner`)),collisionPadding:e??Re(),ref:a,style:o})});_p.displayName=`ContextMenuSubmenuPositioner`;var vp=(0,q.memo)(()=>{let{t:e}=Wt(N);return(0,K.jsx)(Io,{disabled:!0,className:U(V(R.item,R.empty).className,Y(`item`)),children:(0,K.jsx)(`div`,{className:U(B.itemContent,Y(`item-content`)),children:(0,K.jsx)(`span`,{className:U(B.label,Y(`label`)),children:e(`common.empty`)})})})});vp.displayName=`EmptyMenuItem`;var yp=({checked:e,children:t,closeOnClick:n=!1,danger:r,defaultChecked:i,disabled:a,label:o,onCheckedChange:s})=>{let[c,l]=(0,q.useState)(i??!1),u=e!==void 0,d=u?e:c,f=(0,q.useCallback)(e=>{u||l(e),s?.(e)},[u,s]);return(0,K.jsxs)(Io,{closeOnClick:n,disabled:a,label:o,className:U(V(R.item,r&&R.danger).className,Y(`item`)),onClick:e=>{e.preventDefault(),a||f(!d)},children:[t,(0,K.jsx)(`span`,{className:U(B.switchWrap,Y(`switch`)),onFocus:e=>e.stopPropagation(),children:(0,K.jsx)(Ke,{checked:d,disabled:a,size:`small`,tabIndex:-1,onChange:f,onClick:(e,t)=>t.stopPropagation()})})]})},bp=(e,t,n)=>{let r=It(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,K.jsxs)(`div`,{className:U(B.labelGroup,Y(`label-group`)),children:[(0,K.jsx)(`span`,{className:U(B.label,Y(`label`)),children:r}),(0,K.jsx)(`span`,{className:U(B.desc,Y(`desc`)),children:i})]}):(0,K.jsx)(`span`,{className:U(B.label,Y(`label`)),children:r});return(0,K.jsxs)(`div`,{className:U(V(R.itemContent,s&&R.itemContentAlignStart).className,Y(`item-content`)),children:[u?(0,K.jsx)(`span`,{"aria-hidden":!l,className:U(V(R.icon,s&&R.iconAlignStart).className,Ye.icon,Y(`icon`)),children:c?n:l?Vt(e.icon,`small`):null}):null,d,a?(0,K.jsx)(`span`,{className:U(B.extra,Y(`extra`)),children:a}):null,o&&n?n:null,t?.submenu?(0,K.jsx)(`span`,{className:U(B.submenuArrow,Y(`submenu-arrow`)),children:(0,K.jsx)(Rt,{})}):null]})},xp=(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)},Sp=(e,t=[],n)=>{let r=n?.iconAlign,i=n?.iconSpaceMode??`global`,a=n?.reserveIconSpace??Ft(e,i===`global`),o=n?.indicatorOnRight??zt(e);return e.map((e,n)=>{if(!e)return null;let s=`${t.join(`-`)||`root`}-${n}`,c=Bt(e,s),l=[...t,String(c)];if(e.type===`checkbox`){let t=e,n=It(t),i=typeof n==`string`?n:void 0,s=!!t.danger,l=(0,K.jsx)(Mo,{className:Y(`checkbox-indicator`),children:(0,K.jsx)(yt,{icon:O,size:`small`})});return(0,K.jsx)(ko,{checked:t.checked,closeOnClick:t.closeOnClick,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,className:U(V(R.item,s&&R.danger).className,Y(`item`)),onCheckedChange:e=>t.onCheckedChange?.(e),children:bp(t,{iconAlign:r,indicatorOnRight:o,reserveIconSpace:a},l)},c)}if(e.type===`switch`){let t=e,n=It(t),i=typeof n==`string`?n:void 0,o=!!t.danger;return(0,K.jsx)(yp,{checked:t.checked,closeOnClick:t.closeOnClick,danger:o,defaultChecked:t.defaultChecked,disabled:t.disabled,label:i,onCheckedChange:t.onCheckedChange,children:bp(t,{iconAlign:r,reserveIconSpace:a})},c)}if(e.type===`divider`)return(0,K.jsx)(No,{className:U(B.separator,Y(`separator`))},c);if(e.type===`group`){let t=e,n=i===`group`?t.children?Ft(t.children):!1:a,o=t.children?zt(t.children):!1;return(0,K.jsxs)(Oo,{className:Y(`group`),children:[t.label?(0,K.jsx)(Do,{className:U(B.groupLabel,Y(`group-label`)),children:t.label}):null,t.children?Sp(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=It(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?Sp(t.children,l,{iconAlign:r,iconSpaceMode:i}):(0,K.jsx)(vp,{});return(0,K.jsxs)(Ao,{defaultOpen:t.defaultOpen,open:t.open,onOpenChange:t.onOpenChange,children:[(0,K.jsx)(Fo,{...t.triggerProps,closeDelay:t.closeDelay,delay:t.delay,disabled:t.disabled,label:o,openOnHover:t.openOnHover,className:U(V(R.item,s&&R.danger).className,Y(`item`)),onClick:t.onClick,children:bp(t,{iconAlign:r,reserveIconSpace:a,submenu:!0})}),(0,K.jsx)(Eo,{children:(0,K.jsx)(_p,{alignOffset:-4,"data-submenu":``,sideOffset:-1,onContextMenu:fp,children:(0,K.jsxs)(jo,{className:U(V(R.popup,u&&R.popupWithSlots).className,Ye.popup,Y()),children:[t.header==null?null:(0,K.jsx)(`div`,{className:U(B.header,Y(`header`)),children:t.header}),u?(0,K.jsx)(`div`,{className:U(B.slotViewport,Y(`viewport`)),children:d}):d,t.footer==null?null:(0,K.jsx)(`div`,{className:U(B.footer,Y(`footer`)),children:t.footer})]})})})]},c)}let u=e,d=It(u),f=typeof d==`string`?d:void 0,p=`danger`in u&&!!u.danger;return(0,K.jsx)(Io,{closeOnClick:u.closeOnClick,disabled:u.disabled,label:f,className:U(V(R.item,p&&R.danger).className,Y(`item`)),onClick:e=>xp(u,l,e),children:bp(u,{iconAlign:r,reserveIconSpace:a})},c)})},Cp={"--lobe-dropdown-animation-duration":`0ms`},wp=(0,q.memo)(()=>{let e=ae(),t=Et(),n=(0,q.useSyncExternalStore)(Xt,Zt,Yt);(0,q.useEffect)(()=>{},[e]),(0,q.useEffect)(()=>{let e=e=>Qt(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,q.useMemo)(()=>Sp(n.items,[],{iconAlign:n.iconAlign,iconSpaceMode:n.iconSpaceMode}),[n.items,n.iconAlign,n.iconSpaceMode]),{zIndex:i,ref:a}=At(`floating`),o=n.header!=null||n.footer!=null;return!e||!n.open&&n.items.length===0?null:(0,K.jsx)(hp,{open:n.open,onOpenChange:e=>{e?Jt({open:e}):$t()},children:(0,K.jsx)(Eo,{container:t,children:(0,K.jsx)(gp,{anchor:n.anchor??void 0,className:U(B.positioner,Y(`positioner`)),collisionPadding:Re(),ref:a,sideOffset:6,style:{...Cp,zIndex:i},children:(0,K.jsxs)(jo,{"data-has-footer":n.footer==null?void 0:``,"data-has-header":n.header==null?void 0:``,className:U(V(R.popup,o&&R.popupWithSlots).className,Ye.popup,Y()),onContextMenu:fp,children:[n.header==null?null:(0,K.jsx)(`div`,{className:U(B.header,Y(`header`)),children:n.header}),n.virtual?(0,K.jsx)(Lt,{className:Y(`viewport`),itemSize:n.listItemHeight,children:r}):o?(0,K.jsx)(`div`,{className:U(B.slotViewport,Y(`viewport`)),children:r}):r,n.footer==null?null:(0,K.jsx)(`div`,{className:U(B.footer,Y(`footer`)),children:n.footer})]})})})})});wp.displayName=`ContextMenuHost`;var Tp={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 Ep(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 Dp=`data-checked`,Op=`data-unchecked`;function kp(e){return{checked(t){return e.indeterminate?{}:t?{[Dp]:``}:{[Op]:``}},...we}}var Ap=q.createContext(void 0);function jp(){return q.useContext(Ap)}var Mp=q.createContext(void 0);function Np(){let e=q.useContext(Mp);if(e===void 0)throw Error(St(14));return e}var Pp=`data-parent`,Fp=q.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,...C}=e,{clearErrors:w}=be(),{disabled:T,name:E,setDirty:D,setFilled:O,setTouched:k,state:A,validationMode:j,validityData:ee,validation:M}=Ge(),te=mp(),{labelId:ne,registerControlId:N,getDescriptionProps:ie}=ve(),P=jp(),ae=P?.allValues===void 0?void 0:P.parent,oe=ae!==void 0,F=T||te.disabled||P?.disabled||o,se=E??d,I=v??se,ce=xt(),le=P?.registerControlId!==N,ue=Je({id:c||void 0,enabled:le}),fe=y?ue:ce,me={};oe&&(p?me=ae.getParentProps():I!==void 0&&(me=ae.getChildProps(I)));let{checked:he=n,indeterminate:L=l,onCheckedChange:ge,..._e}=me,ye=P?.value,xe=q.useRef(null),Se=x(F,xe),{getButtonProps:Ce,buttonRef:we}=vt({disabled:F,native:y}),R=P?.validation??M,[Te,Ee]=S({controlled:I!==void 0&&ye!==void 0&&!p?ye.includes(I):he,default:i,name:`Checkbox`,state:`checked`}),De=oe?!!he:Te,z=oe&&L||l;de(xe,ce,Te,void 0,!P&&!F,d);let Oe=ae?.registerChildId,ke=q.useRef(null),Ae=R.registerInput,je=P?I:void 0,Me=q.useCallback(e=>Ae(e,{controlRef:xe,value:je}),[Ae,je]),Ne=Ct(u,ke,p?void 0:Me),Pe=re(a,ne,ke,!y,ue,C[`aria-label`]);wt(()=>{ke.current&&(ke.current.indeterminate=z),P||O(Te)},[Te,z,P,O]),pe(Te,()=>{P||(w(se),D(Te!==ee.initialValue),R.change(Te))});let Fe=_t({checked:Te,disabled:F,form:s,name:p?void 0:se,id:y?void 0:ue,required:g,ref:Ne,style:se?gt:pt,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=jt(Tt,e.nativeEvent);if(f?.(t,n),!n.isCanceled&&(ge?.(t,n),!n.isCanceled&&(Ee(t),I!==void 0&&P!==void 0&&!p&&!oe))){let e=t?[...P.value,I]:P.value.filter(e=>e!==I);P.setValue(e,n)}},onClick(e){e.stopPropagation()},onFocus(){xe.current?.focus()}},v===void 0?ct:{value:(P?Te&&v:v)||``},ie,e=>R.getValidationProps(F,e));q.useEffect(()=>{if(!ae||I===void 0)return;let e=ae.disabledStatesRef.current;return e.set(I,F),()=>{e.delete(I)}},[ae,F,I]);let Ie=q.useMemo(()=>({...A,checked:De,disabled:F,readOnly:m,required:g,indeterminate:z}),[A,De,F,m,g,z]),B=kp(Ie),Le=mt(`span`,e,{state:Ie,ref:[we,xe,t],props:[{id:fe,role:`checkbox`,"aria-checked":z?`mixed`:De,"aria-readonly":m||void 0,"aria-required":g||void 0,"aria-labelledby":Pe,[Pp]:p?``:void 0,onFocus(){Se(!0)},onBlur(){let e=ke.current;e&&(k(!0),Se(!1),j===`onBlur`&&R.commit(P?ye: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),Ot(n).queueMicrotask(()=>{e.preventDefault=i,r.preventDefault=a,o||Ep(t)?.click()})},onClick(e){if(m||F)return;e.preventDefault();let t=ke.current;t&&ft(t,e)}},C,_e,Ce,ie,e=>R.getValidationProps(F,e)],stateAttributesMapping:B}),Re=Le.props.id;return wt(()=>{if(Oe&&!p&&I!==void 0&&Re!==void 0)return Oe(I,Re)},[Oe,p,I,Re]),(0,K.jsxs)(Mp.Provider,{value:Ie,children:[Le,!Te&&!P&&se&&!p&&_!==void 0&&(0,K.jsx)(`input`,{type:`hidden`,form:s,name:se,value:_,disabled:F}),(0,K.jsx)(`input`,{...Fe,suppressHydrationWarning:!0})]})}),Ip=q.forwardRef(function(e,t){let{render:n,className:r,style:i,keepMounted:a=!1,...o}=e,s=Np(),c=s.checked||s.indeterminate,{mounted:l,transitionStatus:u,setMounted:d}=Dt(c),f=q.useRef(null),p={...s,transitionStatus:u};ut({batch:!0,enabled:!c,open:c,ref:f,onComplete(){c||d(!1)}});let m={...kp(s),...kt},h=a||l,g=mt(`span`,e,{ref:[t,f],state:p,stateAttributesMapping:m,props:o});return h?g:null}),Lp=Nt({block:`checkbox`,dataAttributes:[`shape`],elements:[`checkbox`,`indicator`,`text`]});Nt({block:`checkbox-group`,dataAttributes:[`horizontal`],elements:[`item`]});var Rp=(0,q.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`?Tp.iconSquare:Tp.iconCircle,_=(0,K.jsx)(Fp,{disabled:u,indeterminate:d,onCheckedChange:l,...r?void 0:Mt({shape:t}),...f,...H([Tp.root,bt.info,!m&&Tp.defaultSize,t===`square`?!m&&Tp.defaultSquare:Tp.circle],U(!r&&Lp(),Lp(`checkbox`),r?a?.checkbox:i,a?.checkbox),h),children:(0,K.jsx)(Ip,{...H(Tp.indicator,Lp(`indicator`)),children:d?(0,K.jsx)(Ue,{size:p,strokeWidth:3,...V(g)}):(0,K.jsx)(O,{size:p,strokeWidth:3,...V(g)})})});return r?(0,K.jsxs)(`label`,{...Mt({shape:t}),...H(Tp.label,U(Lp(),i,a?.wrapper),{...m&&{gap:Math.floor(p/2)},...s,...o?.wrapper}),children:[_,(0,K.jsx)(up,{as:`span`,className:U(Lp(`text`),a?.text),style:o?.text,...c,type:u?`secondary`:c?.type,children:r})]}):_});Rp.displayName=`Checkbox`;var zp=Object.assign(Rp,{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}},Bp=[0,1,2],Vp=25,Hp=Bp.flatMap(e=>Bp.map(t=>({x:Vp+e*Vp,y:Vp+t*Vp}))),Up=Bp.slice(0,-1).flatMap(e=>Bp.flatMap(t=>Bp.map(n=>({x1:Vp+e*Vp,x2:Vp+(e+1)*Vp,y1:Vp+t*Vp,y2:Vp+n*Vp})))),Wp=[0,1,2],Gp=(e,t,n)=>Math.max(e,n*100/t),Kp=(0,q.memo)(({px:e})=>{let t={"--spin-node-size":`${Gp(6,e,2)}px`,"--spin-particle-size":`${Gp(3,e,1.5)}px`,transform:`scale(${e/100})`};return(0,K.jsx)(`span`,{...V(X.network),style:{height:e,width:e},children:(0,K.jsxs)(`span`,{...V(X.networkBox),style:t,children:[(0,K.jsx)(`svg`,{...V(X.networkLines),viewBox:`0 0 100 100`,children:Up.map(e=>(0,K.jsx)(`line`,{...e,...V(X.networkLine)},`${e.x1}-${e.y1}-${e.y2}`))}),Hp.map(({x:e,y:t},n)=>(0,K.jsx)(`i`,{...V(X.networkNode),style:{animationDelay:`${n*.2}s`,left:e,top:t}},`${e}-${t}`)),Wp.map(e=>(0,K.jsx)(`i`,{...V(X.networkParticle),style:{animationDelay:`${e*.6}s`}},e)),(0,K.jsx)(`b`,{...V(X.networkCore)}),(0,K.jsx)(`u`,{...V(X.networkRing)})]})})});Kp.displayName=`NetworkGlyph`;var qp=Nt({block:`spin`,dataAttributes:[`size`,`variant`],elements:[`indicator`,`overlay`,`tip`]}),Jp={large:32,middle:20,small:14},Yp=e=>typeof e==`number`?e:Jp[e],Xp=(0,q.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,q.useMemo)(()=>Yp(a),[a]),f=(0,q.useMemo)(()=>{if(n)return n;if(l===`network`)return(0,K.jsx)(Kp,{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,K.jsxs)(`svg`,{...V(X.glyph,X.ring),height:d,viewBox:`0 0 24 24`,width:d,children:[(0,K.jsx)(`circle`,{...V(X.ringTrack),cx:12,cy:12,fill:`none`,r:9,strokeWidth:2.5}),(0,K.jsx)(`circle`,{...V(X.ringProgress),cx:12,cy:12,fill:`none`,r:9,strokeDasharray:t,strokeDashoffset:n,strokeLinecap:`round`,strokeWidth:2.5})]})}return(0,K.jsx)(yt,{spin:!0,...V(X.glyph),icon:Pe,size:d})},[n,l,r,d]);if(!o)return e??null;let p=Mt({size:typeof a==`string`?a:void 0,variant:l});return e?(0,K.jsxs)(`div`,{ref:i,...H(X.wrapper,U(qp(),t),s),...p,...u,children:[e,(0,K.jsxs)(`div`,{"aria-busy":!0,"aria-live":`polite`,...H(X.overlay,qp(`overlay`)),role:`status`,children:[(0,K.jsx)(`span`,{"aria-hidden":!0,...H(X.glyphBox,qp(`indicator`)),children:f}),c&&(0,K.jsx)(`span`,{...H(X.tip,qp(`tip`)),children:c})]})]}):(0,K.jsx)(`div`,{"aria-busy":!0,"aria-live":`polite`,ref:i,role:`status`,...H(X.root,U(qp(),t),s),...p,...u,children:(0,K.jsx)(`span`,{"aria-hidden":!0,...H(X.glyphBox,qp(`indicator`)),children:f})})});Xp.displayName=`Spin`;var Zp=(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))(Zp||{}),Qp=[0,1],$p=[1,0],em=[2,3],tm=[3,2],nm={L:Qp,M:$p,Q:em,H:tm},rm=/^\d*$/,im=/^[A-Z0-9 $%*+./:-]*$/,am=`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:`,om=1,sm=40,cm=3,lm=3,um=40,dm=10,fm=[[-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]],pm=[[-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]],mm=class{constructor(e,t,n,r){if(this.version=e,this.ecc=t,e<om||e>sm)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,Zp.Timing),this.setFunctionModule(e,6,e%2==0,Zp.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,gm(r,e));this.setFunctionModule(8,7,gm(r,6)),this.setFunctionModule(8,8,gm(r,7)),this.setFunctionModule(7,8,gm(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,gm(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,gm(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,gm(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=gm(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,Zp.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,Zp.Alignment)}setFunctionModule(e,t,n,r=Zp.Function){this.modules[t][e]=n,this.types[t][e]=r}addEccAndInterleave(e){let t=this.version,n=this.ecc;if(e.length!==jm(t,n))throw RangeError(`Invalid argument`);let r=pm[n[0]][t],i=fm[n[0]][t],a=Math.floor(Am(t)/8),o=r-a%r,s=Math.floor(a/r),c=[],l=Mm(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=Nm(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(Am(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]=gm(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+=cm:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*um),n=this.modules[t][a],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*um}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+=cm:r>5&&e++):(this.finderPenaltyAddHistory(r,i),n||(e+=this.finderPenaltyCountPatterns(i)*um),n=this.modules[a][t],r=1);e+=this.finderPenaltyTerminateAndCount(n,r,i)*um}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+=lm)}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*dm,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 hm(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 gm(e,t){return!!(e>>>t&1)}var _m=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()}},vm=[1,10,12,14],ym=[2,9,11,13],bm=[4,8,16,16];function xm(e,t){return e[Math.floor((t+7)/17)+1]}function Sm(e){let t=[];for(let n of e)hm(n,8,t);return new _m(bm,e.length,t)}function Cm(e){if(!Em(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);hm(Number.parseInt(e.substring(n,n+r),10),r*3+1,t),n+=r}return new _m(vm,e.length,t)}function wm(e){if(!Dm(e))throw RangeError(`String contains unencodable characters in alphanumeric mode`);let t=[],n=0;for(;n+2<=e.length;n+=2){let r=am.indexOf(e.charAt(n))*45;r+=am.indexOf(e.charAt(n+1)),hm(r,11,t)}return n<e.length&&hm(am.indexOf(e.charAt(n)),6,t),new _m(ym,e.length,t)}function Tm(e){return e===``?[]:Em(e)?[Cm(e)]:Dm(e)?[wm(e)]:[Sm(km(e))]}function Em(e){return rm.test(e)}function Dm(e){return im.test(e)}function Om(e,t){let n=0;for(let r of e){let e=xm(r.mode,t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}function km(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 Am(e){if(e<om||e>sm)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 jm(e,t){return Math.floor(Am(e)/8)-fm[t[0]][e]*pm[t[0]][e]}function Mm(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]=Pm(t[e],n),e+1<t.length&&(t[e]^=t[e+1]);n=Pm(n,2)}return t}function Nm(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]^=Pm(t,e))}return n}function Pm(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 Fm(e,t,n=1,r=40,i=-1,a=!0){if(!(om<=n&&n<=r&&r<=sm)||i<-1||i>7)throw RangeError(`Invalid value`);let o,s;for(o=n;;o++){let n=jm(o,t)*8,i=Om(e,o);if(i<=n){s=i;break}if(o>=r)throw RangeError(`Data too long`)}for(let e of[$p,em,tm])a&&s<=jm(o,e)*8&&(t=e);let c=[];for(let t of e){hm(t.mode[0],4,c),hm(t.numChars,xm(t.mode,o),c);for(let e of t.getData())c.push(e)}let l=jm(o,t)*8;hm(0,Math.min(4,l-c.length),c),hm(0,(8-c.length%8)%8,c);for(let e=236;c.length<l;e^=253)hm(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 mm(o,t,u,i)}function Im(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`?Tm(e):Array.isArray(e)?[Sm(e)]:void 0;if(!c)throw Error(`uqr only supports encoding string and binary data, but got: ${typeof e}`);let l=Fm(c,nm[n],i,a,o,r),u=Lm({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 Lm(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=Zp.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 Rm={"qrCode.expired":`Expired`,"qrCode.loading":`Loading`,"qrCode.refresh":`Refresh`},zm=(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},Bm=Nt({block:`qr-code`,dataAttributes:[`status`,`bordered`],elements:[`code`,`icon`,`overlay`,`title`,`refresh`]}),Vm={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}},Hm=.22,Um=(0,q.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}=Wt(Rm),m=c??160,{count:h,path:g}=(0,q.useMemo)(()=>{try{let{data:e}=Im(d,{border:0,ecc:a?`H`:i}),t=a?Math.ceil(e.length*Hm)|1:0;return{count:e.length,path:zm(e,t)}}catch{return{count:0,path:``}}},[d,a,i]);return(0,K.jsxs)(`div`,{ref:s,...H([Vm.root,t&&Vm.bordered],U(Bm(),n),e===void 0?u:{background:e,...u}),...Mt({bordered:t,status:l}),...f,children:[(0,K.jsxs)(`svg`,{"aria-label":d,className:Bm(`code`),height:m,role:`img`,shapeRendering:`crispEdges`,viewBox:`0 0 ${h} ${h}`,width:m,children:[(0,K.jsx)(`rect`,{fill:e??`#fff`,height:h,width:h}),(0,K.jsx)(`path`,{d:g,fill:r})]}),a&&(0,K.jsx)(`span`,{...H([Vm.icon,c===void 0&&Vm.iconDefaultSize],Bm(`icon`),c===void 0?void 0:{height:m*Hm,width:m*Hm}),children:a}),l===`loading`&&(0,K.jsx)(`span`,{"aria-label":p(`qrCode.loading`),...H(Vm.overlay,Bm(`overlay`)),role:`status`,children:(0,K.jsx)(Xp,{className:H(Vm.spin).className})}),l===`expired`&&(0,K.jsxs)(`span`,{...H(Vm.overlay,Bm(`overlay`)),children:[(0,K.jsx)(`span`,{...H(Vm.overlayTitle,Bm(`title`)),children:p(`qrCode.expired`)}),o&&(0,K.jsxs)(`button`,{...H([bt.info,Vm.refresh],Bm(`refresh`)),type:`button`,onClick:o,children:[(0,K.jsx)(yt,{icon:$o,size:14}),p(`qrCode.refresh`)]})]})]})});Um.displayName=`QRCode`;var Wm=e({Board:()=>ip,Group:()=>Gm,Item:()=>Qf}),Gm=zf(Ud),Km=e({Reorder:()=>Wm,a:()=>za,abbr:()=>ga,address:()=>ja,animate:()=>Qi,area:()=>Si,article:()=>ba,aside:()=>Fa,audio:()=>ki,b:()=>ca,base:()=>Ua,bdi:()=>Ni,bdo:()=>Bi,big:()=>wa,blockquote:()=>fa,body:()=>Ji,button:()=>Wi,canvas:()=>vi,caption:()=>qa,circle:()=>ao,cite:()=>Ei,clipPath:()=>to,code:()=>Kr,col:()=>Zn,colgroup:()=>Za,create:()=>Na,data:()=>Xr,datalist:()=>ir,dd:()=>tr,defs:()=>Pr,del:()=>aa,desc:()=>Gn,details:()=>na,dfn:()=>Or,dialog:()=>jr,div:()=>Lr,dl:()=>sr,dt:()=>gr,ellipse:()=>Tr,em:()=>Ur,embed:()=>lo,feBlend:()=>Jn,feColorMatrix:()=>ri,feComponentTransfer:()=>pr,feComposite:()=>ei,feConvolveMatrix:()=>oi,feDiffuseLighting:()=>ur,feDisplacementMap:()=>Sr,feDistantLight:()=>Oa,feDropShadow:()=>yr,feFlood:()=>fi,feFuncA:()=>li,feFuncB:()=>hi,feFuncG:()=>Br,feFuncR:()=>Hn,feGaussianBlur:()=>zi,feImage:()=>Ha,feMerge:()=>ya,feMergeNode:()=>Pa,feMorphology:()=>ta,feOffset:()=>Ti,fePointLight:()=>Ca,feSpecularLighting:()=>Ra,feSpotLight:()=>Mi,feTile:()=>da,feTurbulence:()=>Ka,fieldset:()=>Ii,figcaption:()=>Ui,figure:()=>Da,filter:()=>ha,footer:()=>Zi,foreignObject:()=>qi,form:()=>xi,g:()=>Xa,h1:()=>co,h2:()=>Oi,h3:()=>io,h4:()=>Yr,h5:()=>er,h6:()=>eo,head:()=>$r,header:()=>or,hgroup:()=>rr,hr:()=>Ir,html:()=>sa,i:()=>qn,iframe:()=>ia,image:()=>Ar,img:()=>Nr,input:()=>zr,ins:()=>lr,kbd:()=>vr,keygen:()=>Dr,label:()=>Gr,legend:()=>fo,li:()=>Xn,line:()=>ai,linearGradient:()=>hr,link:()=>ni,main:()=>ci,map:()=>fr,mark:()=>wr,marker:()=>Aa,mask:()=>xr,menu:()=>mi,menuitem:()=>di,metadata:()=>_i,meter:()=>Hr,nav:()=>Wn,object:()=>Li,ol:()=>Ba,optgroup:()=>_a,option:()=>Ma,output:()=>$i,p:()=>Ci,param:()=>xa,path:()=>Ia,pattern:()=>Ai,picture:()=>la,polygon:()=>Wa,polyline:()=>Pi,pre:()=>Vi,progress:()=>Ta,q:()=>pa,radialGradient:()=>Yi,rect:()=>Gi,rp:()=>yi,rt:()=>Ja,ruby:()=>oo,s:()=>Di,samp:()=>no,script:()=>qr,section:()=>Qn,select:()=>Qa,small:()=>Zr,source:()=>ar,span:()=>nr,stop:()=>Fr,strong:()=>oa,style:()=>Kn,sub:()=>ra,summary:()=>kr,sup:()=>Mr,svg:()=>Rr,symbol:()=>cr,table:()=>_r,tbody:()=>Er,td:()=>Wr,text:()=>uo,textPath:()=>Yn,textarea:()=>ii,tfoot:()=>mr,th:()=>ti,thead:()=>si,time:()=>dr,title:()=>Cr,tr:()=>ka,track:()=>br,tspan:()=>pi,u:()=>ui,ul:()=>gi,use:()=>Vr,video:()=>Un,view:()=>Ri,wbr:()=>Va,webview:()=>va}),qm=r();function Jm(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 Ym=lt(),Xm=q.useInsertionEffect,Zm=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0?q.useLayoutEffect:q.useEffect,Qm=Xm||Zm,$m=e=>{let t=q.useRef([e,(...e)=>t[0](...e)]).current;return Qm(()=>{t[0]=e}),t[1]},eh=[`popstate`,`pushState`,`replaceState`,`hashchange`],th=[],nh=()=>th.forEach(e=>e()),rh=e=>(th.push(e)===1&&eh.forEach(e=>addEventListener(e,nh)),()=>{th=th.filter(t=>t!==e),th.length||eh.forEach(e=>removeEventListener(e,nh))}),ih=(e,t)=>(0,Ym.useSyncExternalStore)(rh,e,t),ah=()=>location.search,oh=({ssrSearch:e}={})=>ih(ah,e==null?ah:()=>e),sh=()=>location.pathname,ch=({ssrPath:e}={})=>ih(sh,e==null?sh:()=>e),lh=(e,{replace:t=!1,state:n=null}={})=>history[t?`replaceState`:`pushState`](n,``,e),uh=e=>[ch(e),lh],dh=Symbol.for(`wouter_v3`);if(typeof history<`u`&&window[dh]===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,dh,{value:!0})}var fh=(e=``)=>e===`/`?``:e,ph=(e,t)=>e[0]===`~`?e.slice(1):fh(t)+e,mh=(e,t)=>(e=hh(fh(e)),t=hh(t),!e||(t.toLowerCase()+`/`).startsWith(e.toLowerCase()+`/`)?t.slice(e.length)||`/`:`~`+t),hh=e=>{try{return e.includes(`%`)?decodeURI(e):e}catch{return e}},gh={hook:uh,searchHook:oh,parser:Jm,base:``,ssrPath:void 0,ssrSearch:void 0,ssrContext:void 0,hrefs:e=>e,aroundNav:(e,t,n)=>e(t,n)},_h=(0,q.createContext)(gh),vh=()=>(0,q.useContext)(_h);(0,q.createContext)({});var yh=e=>{let[t,n]=e.hook(e);return[mh(e.base,t),$m((t,r)=>e.aroundNav(n,ph(t,e.base),r))]},bh=()=>yh(vh());(0,q.forwardRef)((e,t)=>{let n=vh(),[r,i]=yh(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=$m(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,q.isValidElement)(l)?(0,q.cloneElement)(l,m):(0,q.createElement)(`a`,m,l)});var xh=0,Sh=0,Ch=new Set;function wh(){Sh||xh>0||Ch.size===0||(Sh=requestAnimationFrame(()=>{if(Sh=0,xh>0)return;let e=[...Ch];Ch.clear();for(let t of e)t()}))}function Th(){return xh+=1,()=>{--xh,wh()}}function Eh({label:e}){return(0,q.useEffect)(Th,[]),(0,K.jsx)(c,{stack:!0,label:e,size:32})}var Dh={claude:`Claude Code`,codex:`Codex`,antigravity:`Antigravity`};function Oh(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 kh=e=>e.kind!==`none`&&e.kind!==`login`,Ah=e=>e.kind===`quiet`||e.kind===`command`&&e.stuck===!0,jh=e=>e.kind===`menu`||e.kind===`login`||e.kind===`error`?`amber`:e.kind===`quiet`||e.kind===`command`&&e.stuck?`grey`:null,Mh=(e,t)=>Math.max(1,Math.floor((t-e)/6e4));function Nh(e,t,n,r){let i=Mh(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 Ph=new Set([`thinking`,`running`,`your-turn`,`needs-approval`]),Fh=new Set([`starting`,`queued`]),Ih=e=>e.daemon!==null&&jh(e.daemon.attention)===`amber`;function Lh(e){return(e.daemon?jh(e.daemon.attention)??(Fh.has(e.daemon.state)?`grey`:null):null)??(e.state===`needs-approval`?`amber`:null)}var Rh={"needs-approval":1,running:2,thinking:3,"your-turn":5};function zh(e){if(Ih(e))return 0;let t=Lh(e);return e.state?t===`grey`&&e.state!==`needs-approval`?4:Rh[e.state]:t===`grey`?4:e.daemon?.state===`running`?2:5}function Bh(e,t){let n=e.filter(e=>Ph.has(e.state)),r=t&&t.state!==`ended`?t:null,i=r?Oh(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:Dh[r.harness]??r.harness,state:null,since:r.attention.since,turn:null,daemon:r}),a.sort((e,t)=>zh(e)-zh(t))}async function Vh(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 Hh(e){return{screen:async()=>{let t=await Vh({artifact:e,op:`agent-screen`});return Array.isArray(t?.lines)?t.lines.filter(e=>typeof e==`string`):[]},input:async t=>{await Vh({artifact:e,op:`agent-input`,...t})}}}var Uh=e=>new URLSearchParams(e).get(`agent`)===`1`;function Wh(){let[e,t]=(0,q.useState)([]),[n,r]=(0,q.useState)([]);return(0,q.useEffect)(()=>{let e=null,n,i=!1,a=()=>{e=new WebSocket(_o(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 Gh=(0,q.lazy)(()=>i(async()=>{let{AgentDock:e}=await import(`./AgentDock-fdzdI0YU.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]),import.meta.url).then(({AgentDock:e})=>({default:e})));function Kh({artifact:e}){let{sessions:t,daemon:n}=Wh(),r=n.find(t=>t.artifact===e)??null,i=(0,q.useMemo)(()=>Hh(e),[e]),a=Bh(t.filter(t=>t.artifacts.includes(e)),r);return a.length===0?null:(0,K.jsx)(q.Suspense,{fallback:null,children:(0,K.jsx)(Gh,{trusted:!0,rows:a,transport:r?i:null})})}var qh=[`private`,`public`,`total`,`publishes`,`storage`,`objects`],Jh=e=>e===`preparing`||e===`uploading`||e===`publishing`;function Yh(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 Xh=[`1d`,`7d`,`30d`,`never`],Zh=(e,t)=>!!e?.expiresAt&&Date.parse(e.expiresAt)<=t;function Qh(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 $h(e,t){return e===null?null:e?`upToDate`:t?`localChangesAuto`:`localChanges`}var eg=2e3,tg=1e3,ng=3e5;async function Z(e,t,n){try{let r=await fetch(h(`/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 rg=null,ig=null,ag,og=null,sg=new Set;function cg(){return ig??=Z(`GET`,`status`).then(e=>{if(ig=null,!e.ok)return null;rg=e.json;for(let e of sg)e(rg);return rg}),ig}function lg(e){return sg.add(e),og??=go(e=>{(e.type===`cloud-publication`||e.type===`cloud-published`)&&(clearTimeout(ag),ag=setTimeout(()=>void cg(),tg))}),()=>{sg.delete(e),sg.size>0||(og?.(),og=null,clearTimeout(ag))}}function ug(){let[e,t]=(0,q.useState)(rg),[n,r]=(0,q.useState)(!1),i=(0,q.useRef)(null),a=(0,q.useCallback)(()=>cg(),[]),o=(0,q.useCallback)(()=>{i.current!==null&&window.clearInterval(i.current),i.current=null,r(!1)},[]),s=(0,q.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>ng)&&o()},eg)},[a,o]);return(0,q.useEffect)(()=>{let e=lg(t);return a(),()=>{e(),o()}},[a,o]),{status:e,refresh:a,login:s,waitingForLogin:n}}var dg=(0,q.createContext)(null);function fg({pageWindow:e,children:t}){return(0,K.jsx)(dg.Provider,{value:e??null,children:t})}var pg=()=>(0,q.useContext)(dg)??window;function mg(e,t){if(t===null)return e;let n=new URL(e);return n.searchParams.set(`page`,t),n.href}function hg(){let e=pg(),t=(0,q.useCallback)(t=>(e.addEventListener(`popstate`,t),e.addEventListener(`ryugi:pagechange`,t),()=>{e.removeEventListener(`popstate`,t),e.removeEventListener(`ryugi:pagechange`,t)}),[e]);return[(0,q.useSyncExternalStore)(t,()=>new URLSearchParams(e.location.search).get(`page`)),(0,q.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 gg=[`B`,`KB`,`MB`,`GB`];function _g(e){let t=e,n=0;for(;t>=1024&&n<gg.length-1;)t/=1024,n++;return`${n===0?t:Number(t.toFixed(1))} ${gg[n]}`}function vg(e,t){return typeof e==`string`&&_.exists(`errors.${e}`)?_.t(`errors.${e}`):t}var yg=e=>typeof e==`object`&&!!e&&qh.includes(e.kind)&&typeof e.max==`number`;function bg({kind:e,max:t}){return _.t(`planLimit.${e}`,{max:e===`storage`?_g(t):t})}function xg(e,t){return e.code===`plan_limit`&&yg(e.limit)?bg(e.limit):vg(e.code,typeof e.error==`string`?e.error:t)}var Sg=!1,Cg=new Set,wg=e=>{if(Sg!==e){Sg=e;for(let e of Cg)e()}},Tg=()=>wg(!0),Eg=()=>wg(!1),Dg=()=>Sg,Og=e=>(Cg.add(e),()=>Cg.delete(e)),kg=()=>(0,q.useSyncExternalStore)(Og,Dg,Dg),Ag=e=>e?e.replace(/\/+$/,``):null,jg=(e,t)=>{let n=Ag(e);return n?`${n}${t?.toLowerCase().startsWith(`zh`)?`/zh`:``}`:null},Mg=e=>{let t=Ag(e);return t?`${t}/`:null},Ng=(e,t)=>{let n=Ag(e);return n?`${n}/u/${encodeURIComponent(t)}`:null},Pg=e=>{let t=Ag(e);return t?`${t}/billing`:null},Fg={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 Ig({publication:e,published:t,publishedAt:n,online:r,onPublish:i,compact:o=!1,busy:c=!1}){let{t:l,i18n:u}=s(),d=Tf(),f=e?.phase??(t?`published`:`waiting`),p=t&&f!==`published`,m=Jh(f),h=l(`publication.${p?`update_${f}`:f}`),g=m?Pe:f===`failed`?E:f===`published`?nt:zo,_=f===`failed`?Fg.failed:f===`published`?Fg.success:void 0,v=(0,K.jsx)(yt,{"aria-hidden":`true`,icon:g,size:o?14:16,spin:m&&!d});if(o)return(0,K.jsxs)(`span`,{role:`status`,...a(Fg.summary,_),children:[v,h]});let y=e?.publishedAt??n,b=i&&!m&&f!==`published`&&f!==`not-ready`;return(0,K.jsxs)(`section`,{"aria-label":l(`publication.label`),...a(Fg.card,_),children:[(0,K.jsxs)(`div`,{role:`status`,className:`x78zum5 x6s0dn4 x167g77z xfifm61 x1s688f`,children:[v,h]}),(0,K.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:l(p&&f===`waiting`?`publication.updateWaitingDescription`:p&&f===`failed`?`publication.updateFailedDescription`:`publication.${f}Description`)}),e?.message?(0,K.jsx)(`p`,{role:`alert`,className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:e.message}):null,e?.reasons?.length?(0,K.jsx)(`ul`,{className:`x1ghz6dp xwn43p0 x1j6dyjg x4q1cud`,children:e.reasons.map((e,t)=>(0,K.jsx)(`li`,{children:e},t))}):null,b?(0,K.jsxs)(`button`,{disabled:c,type:`button`,onClick:i,className:`x78zum5 x6s0dn4 xl56j7k x17d4w8g x1rz828m x36usyh xc342km x1sxf85j x19ckca5 xs0jrwl xln7xf2 xfifm61 x1ypdohk`,children:[(0,K.jsx)(So,{"aria-hidden":`true`,size:14}),l(f===`failed`?`publication.retry`:`publication.publishNow`)]}):null,!m&&f!==`published`?(0,K.jsx)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud`,children:l(r===!1?`publication.offline`:!i&&r===!0?`publication.updateLocal`:e?.autoPublish?`publication.autoPublish`:`publication.manualPublish`)}):null,p?(0,K.jsxs)(`p`,{className:`x1ghz6dp x1bo0w0s x1qt5hsa x4q1cud x1y1aw1k x178xt8z x13fuv20 xxu5053`,children:[l(`publication.previousVersion`),y?(0,K.jsxs)(K.Fragment,{children:[` `,(0,K.jsx)(`time`,{dateTime:y,children:new Date(y).toLocaleString(u.language)})]}):null]}):null]})}var Lg=(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}},Rg={pad:{kg3NbH:`x5k8d2m`,$$css:!0}},zg=[{value:`private`,label:`share.onlyMe`,Icon:xo},{value:`public`,label:`share.anyone`,Icon:Ee}];function Bg({busy:e,error:t,onCopyFailed:n,onPublish:r,onVisibility:i,readOnly:o,rootVisibility:c,state:l,title:u,type:d,url:f,uses:p}){let{t:m}=s(),h=Lg(c,l),g=m(l===`public`?`cascade.tag.public`:l===`private`?`cascade.tag.private`:l===`unpublished`?`beside.unpublished`:`beside.unsupported`),_=async()=>{if(f)try{await navigator.clipboard.writeText(f)}catch{n?.()}},v=!o&&l!==`unsupported`,y=Q;return(0,K.jsxs)(`div`,{"data-beside-card":``,className:`x78zum5 xdt5ytf x195vfkc x1xmf6yo xe8ttls xmkeg23 x1y0btm7 x12xov25 xhpnuu7`,children:[(0,K.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x1nejdyq xdd8z9q xddlp02 x1j6dyjg xk50ysn`,children:[(0,K.jsx)(Uo,{size:12}),m(`beside.title`)]}),(0,K.jsxs)(`span`,{...a(y.name,Rg.pad),children:[(0,K.jsx)(`span`,{...a(y.type),children:d}),(0,K.jsx)(`span`,{...a(y.title),children:u}),(0,K.jsx)(`span`,{...a(y.tag,h&&y.warnTag),children:g})]}),p||h?(0,K.jsxs)(`span`,{...a(y.meta,h&&y.warn,Rg.pad),children:[p?m(`referrers.uses`,{count:p}):null,p&&h?` · `:null,h?(0,K.jsx)(`span`,{"data-beside-hidden":``,children:m(`beside.hidden`)}):null]}):null,v||l!==`unsupported`?(0,K.jsxs)(`span`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n x5k8d2m`,children:[v&&l===`unpublished`?(0,K.jsx)(z,{"data-beside-publish":``,disabled:e,size:`small`,onClick:()=>r?.(),children:m(`beside.publish`)}):null,v&&l!==`unpublished`?(0,K.jsx)(`span`,{role:`radiogroup`,className:`x3nfvp2 x1i3ajwb x1kogg8i xahzvm9`,children:zg.map(({value:t,label:n,Icon:r})=>(0,K.jsxs)(`button`,{"aria-checked":t===l,"data-beside-visibility":t,disabled:e,role:`radio`,type:`button`,onClick:()=>t!==l&&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===l|0],children:[(0,K.jsx)(r,{size:11}),m(n)]},t))}):null,(0,K.jsx)(`span`,{className:`x98rzlu`}),(0,K.jsx)(z,{"aria-label":m(`beside.copyLink`),"data-beside-copy":``,disabled:!f,icon:Me,size:`small`,onClick:()=>void _()})]}):null,t?(0,K.jsx)(`span`,{"data-beside-error":``,...a(y.meta,y.error,Rg.pad),children:t}):null]})}var Vg=[`unpublished`,`stale`,`private`,`withdrawn`],Hg=[`unpublished`,`stale`];function Ug(e,t,n){let r=new Map(e.map(e=>[e.artifact,e])),i=e=>Vg.includes(e.state)&&(t[e.artifact]??Hg.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:Vg.includes(e.state),...a?{reason:a}:{}}:{...r,checked:!1,selectable:!1,reason:`upstream`,upstream:e.via??e.parents[0]}})}var Wg=e=>e.selectable?e.state===`private`?`private`:e.state===`withdrawn`?`skipped`:`publish`:e.state===`ready`?`ready`:`skipped`;function Gg({busy:e,error:t,includeRoot:n,items:r,offline:i,onPublish:o,results:c,rootVisibility:l}){let{t:u}=s(),[d,f]=(0,q.useState)(!1),[p,m]=(0,q.useState)({}),h=(0,q.useMemo)(()=>{let e=Ug(r,p);return i?e.map(e=>e.state===`private`?e:{...e,checked:!1,selectable:!1,reason:e.reason??`offline`}):e},[r,p,i]);if(!r.length)return null;let g=e=>r.find(t=>t.artifact===e)?.title??e,_=h.filter(e=>e.state!==`ready`&&e.state!==`private`).length,v=h.filter(e=>e.state===`private`&&!e.checked).length,y=h.filter(e=>e.checked),b=new Map((c??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),x=h.some(e=>e.state!==`ready`),S=()=>o(y.filter(e=>e.state!==`private`).map(e=>e.artifact),y.filter(e=>e.state===`private`).map(e=>e.artifact)),C=e=>{let t=b.get(e.artifact);return t?.error?{text:t.error.error,tone:Q.error}:e.reason===`offline`?{text:u(`cascade.offline`),tone:null}:e.reason===`upstream`?{text:u(`cascade.upstream`,{via:g(e.upstream??``)}),tone:null}:{text:[e.state===`blocked`?e.reason??``:e.state===`private`?u(`cascade.private`):e.state===`ready`?``:u(`cascade.${e.state}`),e.via?u(`cascade.via`,{via:g(e.via)}):``].filter(Boolean).join(` · `),tone:e.state===`private`?Q.warn:null}},w=[`publish`,`private`,`skipped`,`ready`],T=x?(0,K.jsx)(z,{block:!0,"data-cascade-publish":``,disabled:!y.length||e,loading:e,type:n?`primary`:`default`,onClick:S,...a(Q.action),children:u(n?`cascade.publishWithRoot`:`cascade.publish`,{count:y.length})}):null;return(0,K.jsxs)(`div`,{...a(Q.root),children:[(0,K.jsxs)(`button`,{"aria-expanded":d,"data-cascade-summary":``,type:`button`,onClick:()=>f(e=>!e),...a(Q.summary),children:[(0,K.jsx)(`span`,{...a(Q.icon),children:(0,K.jsx)(Se,{size:13})}),(0,K.jsxs)(`span`,{...a(Q.text),children:[(0,K.jsx)(`span`,{...a(Q.lead),children:_?u(`cascade.summaryPending`,{total:r.length,pending:_}):u(`cascade.summaryReady`,{total:r.length})}),v?(0,K.jsx)(`span`,{...a(Q.sub),children:u(`cascade.summaryLocked`,{count:v})}):null,i?(0,K.jsx)(`span`,{...a(Q.sub),children:u(`cascade.offlineHint`)}):null]}),d?(0,K.jsx)(me,{size:14,...a(Q.chevron)}):(0,K.jsx)(A,{size:14,...a(Q.chevron)})]}),d?w.map(t=>{let n=h.filter(e=>Wg(e)===t);if(!n.length)return null;let r=u(t===`publish`?`cascade.group.publish.${l}`:`cascade.group.${t}`);return(0,K.jsxs)(`div`,{"data-cascade-group":t,children:[(0,K.jsxs)(`div`,{...a(Q.group),children:[(0,K.jsx)(`span`,{children:r}),(0,K.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=C(t);return(0,K.jsxs)(`label`,{"data-cascade-item":t.artifact,...a(Q.item),children:[(0,K.jsx)(`span`,{...a(Q.check),children:(0,K.jsx)(zp,{checked:t.checked,disabled:!t.selectable||e,onChange:e=>m(n=>({...n,[t.artifact]:e}))})}),(0,K.jsxs)(`span`,{...a(Q.body),children:[(0,K.jsxs)(`span`,{...a(Q.name),children:[(0,K.jsx)(`span`,{...a(Q.type),children:t.artifact.split(`/`)[0]}),(0,K.jsx)(`span`,{...a(Q.title),children:t.title}),t.state===`private`?(0,K.jsx)(`span`,{...a(Q.tag,Q.warnTag),children:u(`cascade.tag.private`)}):t.state===`ready`?(0,K.jsx)(`span`,{...a(Q.tag),children:u(`cascade.tag.${l}`)}):null]}),n.text?(0,K.jsx)(`span`,{...a(Q.meta,n.tone),children:n.text}):null]})]},t.artifact)})]},t)}):null,t?(0,K.jsx)(`span`,{...a(Q.meta,Q.error),children:t}):null,T]})}function Kg(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`],Jg=e=>e===`withdrawn`||e===`blocked`?`skipped`:e;function Yg({busy:e,cloudUnavailable:t,error:n,exclude:r,items:i,onPublish:o,results:c,rootVisibility:l}){let{t:u}=s(),[d,f]=(0,q.useState)(!1),[p,m]=(0,q.useState)({}),{shown:h,hidden:g,allPrivate:_,visible:v}=Kg(i,l,r);if(!v)return null;let y=e=>e.selectable&&(p[e.artifact]??e.checked),b=h.filter(y),x=new Map((c??[]).filter(e=>e.status!==`published`).map(e=>[e.artifact,e])),S=e=>{let t=x.get(e.artifact)?.error?.error;if(t)return{text:t,tone:Q.error};let n=e.state===`blocked`?e.reason:e.state===`withdrawn`?u(`referrers.withdrawn`):``;return{text:[u(`referrers.uses`,{count:e.uses}),n].filter(Boolean).join(` · `),tone:null}},C=()=>o(b.filter(e=>e.state!==`private`).map(e=>e.artifact),b.filter(e=>e.state===`private`).map(e=>e.artifact));return(0,K.jsxs)(`div`,{...a(Q.root),children:[(0,K.jsxs)(`button`,{"aria-expanded":d,"data-referrer-summary":``,type:`button`,onClick:()=>f(e=>!e),...a(Q.summary),children:[(0,K.jsx)(`span`,{...a(Q.icon),children:(0,K.jsx)(Ut,{size:13})}),(0,K.jsxs)(`span`,{...a(Q.text),children:[(0,K.jsx)(`span`,{...a(Q.lead),children:u(`referrers.summary`,{total:h.length})}),(0,K.jsx)(`span`,{...a(Q.sub,Q.warn),children:u(_?`referrers.hiddenPrivate`:`referrers.hidden`,{count:g})}),t?(0,K.jsx)(`span`,{...a(Q.sub),children:u(`referrers.cloudUnavailable`)}):null]}),d?(0,K.jsx)(me,{size:14,...a(Q.chevron)}):(0,K.jsx)(A,{size:14,...a(Q.chevron)})]}),d?qg.map(t=>{let n=h.filter(e=>Jg(e.state)===t);return n.length?(0,K.jsxs)(`div`,{"data-referrer-group":t,children:[(0,K.jsxs)(`div`,{...a(Q.group),children:[(0,K.jsx)(`span`,{children:u(`referrers.group.${t}`)}),(0,K.jsx)(`span`,{children:n.length})]}),n.map(t=>{let n=S(t);return(0,K.jsxs)(`label`,{"data-referrer-item":t.artifact,...a(Q.item),children:[(0,K.jsx)(`span`,{...a(Q.check),children:(0,K.jsx)(zp,{checked:y(t),disabled:!t.selectable||e,onChange:e=>m(n=>({...n,[t.artifact]:e}))})}),(0,K.jsxs)(`span`,{...a(Q.body),children:[(0,K.jsxs)(`span`,{...a(Q.name),children:[(0,K.jsx)(`span`,{...a(Q.type),children:`document`}),(0,K.jsx)(`span`,{...a(Q.title),children:t.title}),t.state===`private`?(0,K.jsx)(`span`,{...a(Q.tag,Q.warnTag),children:u(`cascade.tag.private`)}):t.state===`ready`?(0,K.jsx)(`span`,{...a(Q.tag),children:u(`cascade.tag.public`)}):null]}),(0,K.jsx)(`span`,{...a(Q.meta,n.tone),children:n.text})]})]},t.artifact)})]},t):null}):null,n?(0,K.jsx)(`span`,{...a(Q.meta,Q.error),children:n}):null,d?(0,K.jsx)(z,{block:!0,"data-referrer-publish":``,disabled:!b.length||e,loading:e,onClick:C,...a(Q.action),children:u(`referrers.publish`,{count:b.length})}):null]})}var Xg=864e5;function Zg({text:e,action:t,onConfirm:n,onCancel:r}){let{t:i}=s();return(0,K.jsxs)(`div`,{"data-share-confirm":``,className:`x1k70j0n xe8ttls xmkeg23 x1y0btm7 x12xov25 xu4hgxq x2fo67v`,children:[(0,K.jsx)(`p`,{className:`x1q6ys4k x1j6dyjg x37zpob`,children:e}),(0,K.jsxs)(`div`,{className:`x78zum5 x13a6bvl x17d4w8g`,children:[(0,K.jsx)(z,{"data-confirm":`no`,size:`small`,onClick:r,children:i(`common.cancel`)}),(0,K.jsx)(z,{"data-confirm":`yes`,size:`small`,type:`primary`,onClick:n,children:t})]})]})}function Qg({value:e,disabled:t,onExpiry:n,onRegenerate:r}){let{t:i,i18n:a}=s(),[o]=(0,q.useState)(()=>Date.now()),c=Zh(e,o),l=e.expiresAt?new Date(e.expiresAt).toLocaleDateString(a.language,{month:`short`,day:`numeric`}):null,u=e.expiresAt?c?i(`share.expired`,{date:l}):i(`share.expiresIn`,{count:Math.max(1,Math.ceil((Date.parse(e.expiresAt)-o)/Xg)),date:l}):i(`share.neverExpires`),d=Xh.map(e=>({value:e,label:i(`share.expiry.${e}`)}));return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsxs)(`div`,{className:`x78zum5 x1a02dak x6s0dn4 x1qughib x167g77z xwkmoec x1bo0w0s xfifm61`,children:[(0,K.jsxs)(`label`,{"data-key-expired":c?``:void 0,"data-key-expiry":``,className:`x1n2onr6 x3nfvp2 xeuugli xss6m8b`,children:[(0,K.jsx)(`span`,{className:`x10l6tqk x1i1rx1s xjm9jq1 xb3r6kr xuxw1ft x1hyvwdk`,children:i(`share.expiryLabel`)}),(0,K.jsx)(ho,{disabled:t,options:d,placeholder:(0,K.jsx)(`span`,{...{0:{},1:{className:`x12vcgws`}}[!!c|0],children:u}),prefix:po,size:`small`,style:{width:`auto`,minWidth:0,fontSize:11},value:null,onSelect:e=>n(e)})]}),(0,K.jsx)(z,{"data-key-regenerate":``,disabled:t,icon:Zo,outdent:`end`,size:`small`,style:{fontSize:11},type:`text`,onClick:r,children:i(`share.regenerate`)})]}),c?(0,K.jsx)(`p`,{className:`x8k27cj x1bo0w0s x1j6dyjg x37zpob`,children:i(`share.expiredNote`)}):null]})}var $g=[{value:`private`,label:`share.onlyMe`,hint:`share.onlyMeHint`,Icon:xo},{value:`key`,label:`share.keyHolders`,hint:`share.keyHint`,Icon:qo},{value:`public`,label:`share.anyone`,hint:`share.anyoneHint`,Icon:Ee}],e_={private:{text:`share.removeKeyConfirm`,action:`share.removeKey`},public:{text:`share.makePublicConfirm`,action:`share.makePublic`},regenerate:{text:`share.regenerateConfirm`,action:`share.regenerate`}};function t_({beside:e,cascade:t,children:n,foot:r,onCopyFailed:i,onVisibility:a,profile:o,referrers:c,saving:l=!1,shareKey:u,status:d,url:f,visibility:p}){let{t:m}=s(),[h,g]=(0,q.useState)(!1),[_,v]=(0,q.useState)(null),[y]=(0,q.useState)(()=>Date.now());(0,q.useEffect)(()=>{if(!h)return;let e=setTimeout(()=>g(!1),2e3);return()=>clearTimeout(e)},[h]);let b=u?.active?`key`:p,x=b===`key`?u?.value?.url??null:f,S=async()=>{if(x)try{await navigator.clipboard.writeText(x),g(!0)}catch{i?.()}},C=e=>{e!==b&&(e===`key`?u?.onSelect():b===`key`?v(e):a(e))},w=()=>{_===`private`?u?.onRemove():_===`public`?a(`public`):_===`regenerate`&&u?.onRegenerate(),v(null)},T=b===`key`?u?.value??null:null,E=Zh(T,y);return(0,K.jsxs)(`div`,{className:`x78zum5 xdt5ytf x195vfkc x58rd6w xqfszdh xfifm61`,children:[d,(0,K.jsx)(`p`,{className:`x1coi2bq xfifm61 x1s688f`,children:m(`share.whoCanSee`)}),(0,K.jsx)(`div`,{"aria-label":m(`share.whoCanSee`),role:`radiogroup`,className:`x78zum5 xdt5ytf x195vfkc`,children:$g.filter(({value:e})=>e!==`key`||u).map(({value:e,label:t,hint:n,Icon:r})=>(0,K.jsxs)(`button`,{"aria-checked":e===b,"data-visibility":e,disabled:l,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===b|0],children:[(0,K.jsx)(`span`,{...{0:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i xahzvm9`},1:{className:`xrvj5dj x1ku5rj1 x1okw0bk xvy4d1p xxk0z11 x1kogg8i x19ckca5 xs0jrwl`}}[e===b|0],children:(0,K.jsx)(r,{size:12})}),(0,K.jsxs)(`span`,{children:[(0,K.jsxs)(`span`,{className:`x1lliihq xfifm61 x1s688f xwn7fz2`,children:[m(t),e===`key`&&u?.locked?(0,K.jsx)(`span`,{"data-pro-badge":``,className:`xdzw4kq xm9j1uf xmkeg23 x1y0btm7 xgcsv5v x12oqio5 x1bo0w0s x1k6wstc x1s688f x1xxsxie`,children:m(`share.proBadge`)}):null]}),(0,K.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:m(n)})]})]},e))}),b===`public`&&o?(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z x16ngw23 x12ulsxz x1icxu4v x1bo0w0s x1j6dyjg xwn7fz2`,children:[(0,K.jsxs)(`span`,{children:[m(`share.showOnProfile`),o.path?(0,K.jsx)(`span`,{className:`x1lliihq xddlp02 x1j6dyjg xwn7fz2`,children:o.path}):null]}),(0,K.jsx)(`button`,{"aria-checked":o.shown,"aria-label":m(`share.showOnProfile`),"data-profile-switch":``,disabled:l,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,K.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,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g x1k70j0n`,children:[(0,K.jsx)(`input`,{readOnly:!0,"aria-label":m(`share.linkLabel`),"data-share-url":``,"data-struck":E?``:void 0,placeholder:m(b===`key`?`share.keyPending`:`share.linkPending`),value:x??``,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,K.jsx)(z,{disabled:!x,icon:bo,size:`small`,type:`primary`,onClick:()=>void S(),children:m(h?`share.copied`:`share.copy`)})]}),_?(0,K.jsx)(Zg,{action:m(e_[_].action),text:m(e_[_].text),onCancel:()=>v(null),onConfirm:w}):T&&u?(0,K.jsx)(Qg,{disabled:l,value:T,onExpiry:u.onExpiry,onRegenerate:()=>v(`regenerate`)}):null,r&&b!==`key`?(0,K.jsx)(`div`,{className:`x8k27cj xddlp02 x1j6dyjg`,children:r}):null,e?(0,K.jsx)(Bg,{...e}):null,t?(0,K.jsx)(Gg,{...t}):null,c?(0,K.jsx)(Yg,{...c}):null,n]})}var n_=`ryugi.pendingCloudIntent`,r_=6e5;function i_(e,t){try{let n={artifact:e,intent:t,at:Date.now()};window.sessionStorage.setItem(n_,JSON.stringify(n))}catch{}}function a_(e){try{let t=window.sessionStorage.getItem(n_);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>r_?(typeof n.at==`number`&&Date.now()-n.at>r_&&window.sessionStorage.removeItem(n_),null):(window.sessionStorage.removeItem(n_),n.intent)}catch{return null}}function o_({origin:e}){let{t,i18n:n}=s(),r=e.replace(/\/+$/,``),i=n.language?.toLowerCase().startsWith(`zh`)?`/zh`:``;return(0,K.jsxs)(`p`,{className:`x1ghz6dp x1j6dyjg x1evy7pa xddlp02`,children:[t(`common.authLegalPrefix`),(0,K.jsx)(`a`,{href:`${r}${i}/terms`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.terms`)}),t(`common.authLegalAnd`),(0,K.jsx)(`a`,{href:`${r}${i}/privacy`,rel:`noopener noreferrer`,target:`_blank`,className:`x1bo0w0s x1bvjpef xrys4gj`,children:t(`common.privacy`)}),t(`common.authLegalSuffix`)]})}var s_=[{id:`share`,icon:Se,titleKey:`cloudIntent.shareTitle`,descKey:`cloudIntent.shareDesc`},{id:`phone`,icon:rs,titleKey:`cloudIntent.phoneTitle`,descKey:`cloudIntent.phoneDesc`},{id:`sync`,icon:So,titleKey:`cloudIntent.syncTitle`,descKey:`cloudIntent.syncDesc`}],c_={share:`cloudIntent.shareCta`,phone:`cloudIntent.phoneCta`,sync:`cloudIntent.syncCta`},l_={share:`cloudIntent.sharePrivacy`,phone:`cloudIntent.phonePrivacy`,sync:`cloudIntent.syncPrivacy`};function u_({origin:e,landingUrl:t,waitingForLogin:n,onStartIntent:r}){let{t:i}=s(),[a,o]=(0,q.useState)(`share`);return(0,K.jsxs)(`div`,{"data-intent-login-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x168biu4 xw7nakj xqfszdh xfifm61 xo2rkog`,children:[(0,K.jsxs)(`div`,{className:`x78zum5 x1cy8zhl x1qughib x167g77z`,children:[(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`span`,{className:`x1lliihq x2ouz8m x1s688f xo2rkog`,children:i(`cloudIntent.heading`)}),(0,K.jsx)(`span`,{className:`x1lliihq x1qt5hsa x1bo0w0s xr9ek0c`,children:i(`cloudIntent.subheading`)})]}),(0,K.jsx)(`span`,{className:`x1s31vzs x1s688f x1o8fvuk x6z2zk2 xj8oexa xlkn9b3 x1e6avla xuxw1ft x2lah0s`,children:i(`cloudIntent.badge`)})]}),(0,K.jsx)(`div`,{"aria-label":i(`cloudIntent.heading`),role:`radiogroup`,className:`x78zum5 xdt5ytf x1j9xkj6`,children:s_.map(({id:e,icon:t,titleKey:n,descKey:r})=>{let s=a===e;return(0,K.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,K.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,K.jsx)(t,{size:14})}),(0,K.jsxs)(`span`,{className:`x98rzlu xeuugli`,children:[(0,K.jsx)(`span`,{className:`x1lliihq x1ct8sxb x1s688f xo2rkog`,children:i(n)}),(0,K.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4 xvijh9v`,children:i(r)})]}),(0,K.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,K.jsx)(`span`,{className:`x1ftt334 x1ycjhwn x16rqkct x1vi11w0`}):null})]},e)})}),(0,K.jsx)(z,{className:{className:`xh8yej3 x90ne7k x15az74h x12s0oaj x1ektstd x1w8fas2 xt9vybz xh88oxj`}.className,"data-cloud-intent-submit":``,icon:mo,loading:n,type:`primary`,onClick:()=>r(a),children:i(n?`publish.waitingLogin`:c_[a])}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x17d4w8g xknfcqp x1q4txso xur7f20 x2fo67v x1j6dyjg x1bo0w0s xfrs9s4`,children:[(0,K.jsx)(xo,{"aria-hidden":`true`,size:12,style:{flexShrink:0}}),(0,K.jsx)(`span`,{children:i(l_[a])})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,K.jsx)(o_,{origin:e}),t?(0,K.jsxs)(`a`,{href:t,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[i(`cloudEntry.learnShort`),(0,K.jsx)(yo,{"aria-hidden":`true`,size:11})]}):null]})]})}var d_={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:`xo5v014`,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 f_({position:e,children:t,style:n,...r}){return(0,K.jsx)(`div`,{"data-action-bar":!0,...r,...a(d_.bar,d_[e]),style:n,children:t})}function p_({children:e,tone:t=`default`,limit:n}){return(0,K.jsx)(`span`,{...a(d_.text,t!=="default"&&d_[t]),style:n?{maxWidth:n}:void 0,children:e})}function m_(){return(0,K.jsx)(`span`,{className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})}function h_({variant:e,children:t,...n}){return(0,K.jsx)(`a`,{...n,...a(d_.button,d_.anchor,d_[e]),children:t})}function g_({variant:e,children:t,...n}){return(0,K.jsx)(`button`,{type:`button`,...n,...a(e===`link`?d_.link:[d_.button,d_[e]]),children:t})}function __({result:e,onDismiss:t,onOpenSharePanel:n}){let{t:r}=s(),[i,a]=(0,q.useState)(!1),[o,c]=(0,q.useState)(!!e.copied),l=async()=>{if(e.url)try{await navigator.clipboard.writeText(e.url),c(!0)}catch{}};return e.error?(0,K.jsxs)(f_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[(0,K.jsx)(p_,{limit:380,tone:`muted`,children:e.error}),(0,K.jsx)(g_,{variant:`primary`,onClick:n,children:r(`cloudIntent.viewDetails`)}),(0,K.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,K.jsx)(dt,{size:13})})]}):(0,K.jsxs)(K.Fragment,{children:[i&&e.url?(0,K.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,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,K.jsx)(`span`,{className:`x4z9k3i x1s688f`,children:r(`cloudIntent.qrTitle`)}),(0,K.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,K.jsx)(dt,{size:13})})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1af02g3`,children:[(0,K.jsx)(`div`,{className:`x1ruevkc xmkeg23 x1y0btm7 x12xov25 x1q4ynmn xqm9i1m x2lah0s xrvj5dj x1ku5rj1`,children:(0,K.jsx)(Um,{bgColor:`#ffffff`,bordered:!1,color:`#141416`,size:108,value:e.url})}),(0,K.jsxs)(`div`,{className:`x78zum5 xdt5ytf x167g77z xeuugli x98rzlu`,children:[(0,K.jsx)(`p`,{className:`x1ghz6dp x1qt5hsa x1jjo3f5 x1bo0w0s`,children:r(`cloudIntent.qrDesc`)}),(0,K.jsx)(`div`,{children:(0,K.jsx)(z,{icon:(0,K.jsx)(bo,{size:12}),size:`small`,onClick:()=>void l(),children:r(o?`cloudIntent.copied`:`cloudIntent.copyPhoneLink`)})})]})]}),e.billingUrl?(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x883omv x1m7iz9m xfoe8qy xmkeg23 x1y0btm7 x1jw0pk6 xhpnuu7 x1xrkum6 x1qt5hsa`,children:[(0,K.jsx)(`span`,{className:`x1bo0w0s xfrs9s4`,children:r(`cloudIntent.proRelayHint`)}),(0,K.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,K.jsxs)(f_,{"data-intent-toast":``,position:`fixed`,role:`status`,children:[e.intent===`share`?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(p_,{limit:380,tone:`success`,children:e.copied?r(`cloudIntent.toastShareCopied`,{login:e.login}):r(`cloudIntent.toastShare`,{login:e.login})}),(0,K.jsx)(g_,{variant:`quiet`,onClick:n,children:r(`cloudIntent.changeAccess`)}),e.url?(0,K.jsxs)(h_,{href:e.url,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudIntent.openLink`),` ↗`]}):null]}):e.intent===`phone`?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(p_,{limit:360,tone:`success`,children:r(`cloudIntent.toastPhone`)}),e.billingUrl?(0,K.jsx)(h_,{href:e.billingUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`quiet`,children:r(`cloudIntent.learnRelay`)}):null,e.url?(0,K.jsx)(g_,{variant:`primary`,onClick:()=>a(e=>!e),children:r(i?`cloudIntent.hideQr`:`cloudIntent.showQr`)}):null]}):(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(p_,{limit:380,tone:`success`,children:r(`cloudIntent.toastSync`,{login:e.login})}),(0,K.jsx)(g_,{variant:`quiet`,onClick:Tg,children:r(`cloudIntent.projectConfig`)}),e.dashboardUrl?(0,K.jsxs)(h_,{href:e.dashboardUrl,rel:`noopener noreferrer`,target:`_blank`,variant:`primary`,children:[r(`cloudEntry.openShort`),` ↗`]}):null]}),(0,K.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,K.jsx)(dt,{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 v_(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 y_(e,t,n,r){let i=e?.id?`${e.type}/${e.id}`:null,[a,o]=(0,q.useState)(null);if((0,q.useEffect)(()=>{if(!e?.id||!i)return;let t=!1;return v_(e.type,e.id).then(e=>{!t&&e&&o({key:i,text:e})}),()=>{t=!0}},[i]),!e||!i)return null;let s=Qh(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:Lg(n,c)}}var b_=800;function x_(e,t){let[n,r]=(0,q.useState)(null),i=(0,q.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,q.useEffect)(()=>{if(!t){r(null);return}i();let n,a=go(t=>{t.artifact!==e||t.type!==`change`&&t.type!==`cloud-published`||(clearTimeout(n),n=setTimeout(()=>void i(),b_))});return()=>{clearTimeout(n),a()}},[e,t,i]),{upToDate:n,refresh:i}}function S_(e,t){let[n,r]=(0,q.useState)(null);return(0,q.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&&Yh(a.json);!n&&t===i&&o&&r(o)};a();let o=go(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 C_=e=>e.json.results??null;function w_(e){let[t,n]=(0,q.useState)([]),[r,i]=(0,q.useState)(null),[a,o]=(0,q.useState)([]),[s,c]=(0,q.useState)(null),[l,u]=(0,q.useState)(!1);return{refs:t,results:r,referrers:a,referrerResults:s,cloudUnavailable:l,load:(0,q.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(C_(o)),o},publishReferrers:async(t,n)=>{let r=await Z(`POST`,`publish-referrers/${e}`,{publish:t,makePublic:n});return r.ok&&c(C_(r)),r}}}var T_={private:`publish.hintPrivate`,public:`publish.hintPublic`};function E_({artifact:e,floating:t=!1,shell:n=!1}){let{t:r,i18n:i}=s(),{status:o,refresh:c,login:l,waitingForLogin:u}=ug(),d=xe(),[f,p]=(0,q.useState)(!1),[m,h]=(0,q.useState)(!1),[g,_]=(0,q.useState)([]),[v,y]=(0,q.useState)(null),[b,x]=(0,q.useState)(null),[S,C]=(0,q.useState)(null),w=(0,q.useRef)(!1),T=o?.artifacts?.[e],E=Qh(T),D=S_(e,!!o?.signedIn),O=D&&Jh(D.phase),[k]=hg(),A=E.url?mg(E.url,k):null,j=x_(e,!!o?.signedIn&&E.published),ee=$h(j.upToDate,!!o?.autoPublish?.enabled&&T?.autoPublish!==!1),M=w_(e),{refs:te,referrers:ne}=M,N=async e=>{h(!0),_([]),y(null);let t=await e();if(`shareKey`in t.json&&x(t.ok?t.json.shareKey:null),t.status===401)l(t.json.loginUrl);else if(!t.ok){t.json.code===`plan_required`&&typeof t.json.upgradeUrl==`string`&&y(t.json.upgradeUrl);let e=Array.isArray(t.json.reasons)?t.json.reasons:[];_([xg(t.json,r(`common.requestFailed`,{status:t.status})),...e])}await Promise.all([c(),j.refresh(),M.load()]),h(!1)},re=!E.published&&te.some(e=>e.checked),ie=E.published?E.visibility:null,P=y_(d.role===`primary`?d.other:null,o,ie,ne),ae=t=>N(()=>Z(`POST`,`visibility/${e}`,{visibility:t})),oe=(t={})=>N(()=>Z(`PUT`,`share-key/${e}`,t)),F=async t=>{if(p(t),t&&o?.signedIn&&M.load(),t&&o?.signedIn&&E.published){if(j.refresh(),E.access===`key`){let t=await Z(`GET`,`share-key/${e}`);t.ok&&x(t.json.shareKey)}(await Z(`GET`,`artifacts`)).ok&&await c()}},se=t=>{i_(e,t),l()};(0,q.useEffect)(()=>{if(!o?.signedIn||!o.login||w.current)return;let t=a_(e);if(!t)return;w.current=!0;let n=o.login,i=o.origin;(async()=>{p(!1),h(!0),_([]),y(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:Mg(i),billingUrl:Pg(i),error:xg(a.json,r(`common.requestFailed`,{status:a.status}))});return}Z(`POST`,`publish/${e}`),await c(),C({intent:t,login:n,url:null,dashboardUrl:Mg(i),billingUrl:Pg(i)});return}let a=await Z(`POST`,`publish/${e}`),o=await c();if(await Promise.all([j.refresh(),M.load()]),!a.ok){a.json.code===`plan_required`&&typeof a.json.upgradeUrl==`string`&&y(a.json.upgradeUrl);let e=Array.isArray(a.json.reasons)?a.json.reasons:[],o=xg(a.json,r(`common.requestFailed`,{status:a.status}));_([o,...e]),C({intent:t,login:n,url:null,dashboardUrl:Mg(i),billingUrl:Pg(i),error:o});return}let s=Qh(o?.artifacts?.[e]).url??(typeof a.json.url==`string`?a.json.url:null),l=s?mg(s,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:Mg(i),billingUrl:Pg(i)})}finally{h(!1),w.current=!1}})()},[e,o?.signedIn,o?.login,o?.origin,k,c]);let I=jg(o?.origin,i.language),ce=Mg(o?.origin),le=o?o.signedIn?(0,K.jsxs)(`div`,{...a($.panel),children:[(0,K.jsxs)(`div`,{...a($.row),children:[(0,K.jsx)(`span`,{...a($.muted),children:r(`publish.signedInAs`,{login:o.login})}),(0,K.jsx)(`button`,{type:`button`,...a($.textButton),onClick:()=>void N(()=>Z(`POST`,`logout`)),children:r(`publish.signOut`)})]}),(0,K.jsx)(t_,{foot:r(T_[E.visibility]),saving:m,url:A,visibility:E.visibility,beside:P?{...P.card,busy:m,onVisibility:e=>void N(()=>Z(`POST`,`visibility/${P.key}`,{visibility:e})),onPublish:()=>void N(()=>Z(`POST`,`publish/${P.key}`,{visibility:E.visibility}))}:null,cascade:{items:te,rootVisibility:E.visibility,busy:m,results:M.results,includeRoot:!E.published,onPublish:(e,t)=>void N(()=>M.publishRefs(E.published,E.visibility,e,t))},profile:E.published?{shown:E.onProfile,path:o.login?`/u/${o.login}`:null,onChange:t=>void N(()=>Z(`POST`,`profile/${e}`,{shown:t}))}:null,referrers:{items:ne,exclude:P?.key,rootVisibility:ie,busy:m,cloudUnavailable:M.cloudUnavailable,results:M.referrerResults,onPublish:(e,t)=>void N(()=>M.publishReferrers(e,t))},shareKey:{active:E.access===`key`,value:b,onSelect:()=>void oe(),onExpiry:e=>void oe({expires:e}),onRegenerate:()=>void oe({regenerate:!0}),onRemove:()=>void N(()=>Z(`DELETE`,`share-key/${e}`))},status:(0,K.jsx)(Ig,{online:!0,busy:m,publication:D,published:E.published,publishedAt:T?.cloud?.publishedAt,onPublish:re?void 0:()=>void N(()=>Z(`POST`,`publish/${e}`))}),onVisibility:e=>void ae(e)}),ee?(0,K.jsx)(`span`,{...a(j.upToDate?$.muted:$.warning),children:r(`publish.${ee}`)}):null,E.synced?null:(0,K.jsxs)(`div`,{...a($.row,$.warning),children:[(0,K.jsx)(`span`,{children:r(`publish.visibilityNotSynced`)}),(0,K.jsx)(z,{disabled:m,size:`small`,onClick:()=>void ae(E.visibility),children:r(`publish.sync`)})]}),g.length>0?(0,K.jsx)(`ul`,{...a($.error),children:g.map(e=>(0,K.jsx)(`li`,{children:e},e))}):null,v?(0,K.jsx)(`a`,{"data-upgrade":``,href:v,rel:`noreferrer`,target:`_blank`,...a($.textButton),children:r(`share.seePlans`)}):null,E.published&&(!D||D.phase===`published`)?(0,K.jsx)(z,{loading:m||!!O,type:`primary`,onClick:()=>void N(()=>Z(`POST`,`publish/${e}`)),children:r(`publish.update`)}):null,E.published?(0,K.jsx)(`button`,{disabled:m,type:`button`,...a($.textButton,$.danger),onClick:()=>void N(()=>Z(`DELETE`,`publish/${e}`)),children:r(`publish.unpublish`)}):null,E.published&&o.autoPublish?.enabled?(0,K.jsx)(`span`,{...a($.muted),children:r(`publish.autoPublishNote`)}):null,(0,K.jsxs)(`div`,{...a($.row,$.muted),children:[(0,K.jsx)(`span`,{children:r(`settings.menuStatus`,{state:o.autoPublish?.enabled?r(`settings.on`):r(`settings.off`)})}),(0,K.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:10},children:[ce?(0,K.jsxs)(`a`,{href:ce,rel:`noopener noreferrer`,target:`_blank`,...a($.textButton),children:[r(`cloudEntry.openShort`),` `,(0,K.jsx)(yo,{"aria-hidden":`true`,size:11})]}):null,(0,K.jsx)(`button`,{type:`button`,...a($.textButton),onClick:Tg,children:r(`publish.openSettings`)})]})]})]}):(0,K.jsx)(u_,{landingUrl:I,origin:o.origin,waitingForLogin:u,onStartIntent:se}):(0,K.jsx)(`div`,{...a($.panel,$.muted),children:r(`publish.readingStatus`)});if(d.role===`beside`||tt())return null;let ue=n&&!!o&&!o.signedIn;return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(Gt,{content:le,open:f,placement:`bottomRight`,popupProps:{"aria-label":r(`common.share`)},trigger:`click`,onOpenChange:e=>void F(e),children:(0,K.jsxs)(`button`,{"aria-label":`Share`,"data-cloud-shell-cta":ue?``:void 0,type:`button`,...a($.trigger,t&&$.floating,ue&&$.shellCta),children:[ue?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(`span`,{"aria-hidden":`true`,...a($.brandDot)}),r(`cloudEntry.shellCta`)]}):(0,K.jsxs)(K.Fragment,{children:[E.published&&E.visibility===`public`?(0,K.jsx)(Ee,{size:14}):(0,K.jsx)(xo,{size:14}),E.published?r(`publish.published`):r(`common.share`)]}),D&&D.phase!==`published`?(0,K.jsx)(Ig,{compact:!0,publication:D,published:E.published}):null,j.upToDate===!1?(0,K.jsx)(`span`,{"aria-label":r(`publish.unpublishedChanges`),...a($.dot)}):null,P?.hidden?(0,K.jsx)(`span`,{"aria-label":r(`beside.hidden`),"data-beside-dot":``,...a($.dot)}):null]})}),S?(0,K.jsx)(__,{result:S,onDismiss:()=>C(null),onOpenSharePanel:()=>{C(null),F(!0)}}):null]})}function D_(e,t){let n=e.parentElement?.closest(`a, button`)??e,r=window.matchMedia(`(prefers-reduced-motion: reduce)`),i=null,a=()=>{if(r.matches||i)return;let{from:e,to:n,duration:a,easing:o}=f.sweep,s=t.animate([{transform:e},{transform:n}],{duration:a,easing:o});i=s,s.onfinish=s.oncancel=()=>{i=null}},o=()=>{n.matches(`:focus-visible`)&&a()};return n.addEventListener(`pointerenter`,a),n.addEventListener(`focus`,o),()=>{n.removeEventListener(`pointerenter`,a),n.removeEventListener(`focus`,o),i?.cancel()}}function O_({ink:e,clip:t,seal:n}){return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(`g`,{dangerouslySetInnerHTML:{__html:l},fill:e,transform:f.markTransform}),(0,K.jsxs)(`g`,{fill:`none`,stroke:e,strokeLinejoin:`round`,strokeWidth:f.strokeWidth,transform:f.wordTransform,children:[f.butt.map(e=>(0,K.jsx)(`path`,{d:e,strokeLinecap:`butt`},e)),f.round.map(e=>(0,K.jsx)(`path`,{d:e,strokeLinecap:`round`},e)),(0,K.jsx)(`g`,{clipPath:`url(#${t})`,children:f.clipped.map(e=>(0,K.jsx)(`path`,{d:e,strokeLinecap:`butt`},e))}),(0,K.jsx)(`rect`,{height:f.seal.size,rx:f.seal.rx,stroke:`none`,width:f.seal.size,x:f.seal.x,y:f.seal.y,...n})]})]})}function k_({height:e=22,title:t,contextMenu:n=!0}){let{t:r}=s(),i=u((0,q.useId)()),a=(0,q.useRef)(null),o=(0,q.useRef)(null);(0,q.useEffect)(()=>D_(a.current,o.current),[]);let c=async(e,t)=>{try{await navigator.clipboard.writeText(d(e)),en.success(r(t))}catch{en.error(r(`brand.copyFailed`))}},l=e=>{n&&(e.preventDefault(),e.stopPropagation(),qt([{key:`copy-svg`,label:r(`brand.copySvg`),icon:bo,onClick:()=>void c(`lockup`,`brand.copiedSvg`)},{key:`copy-logo-svg`,label:r(`brand.copyLogoSvg`),icon:at,onClick:()=>void c(`mark`,`brand.copiedLogoSvg`)},{key:`copy-text-svg`,label:r(`brand.copyTextSvg`),icon:Oe,onClick:()=>void c(`wordmark`,`brand.copiedTextSvg`)}]))},p=`${i}-clip`,m=`${i}-mask`,h=`${i}-ember`;return(0,K.jsxs)(`svg`,{ref:a,...t?{role:`img`,"aria-label":t}:{"aria-hidden":!0},height:e,viewBox:f.viewBox,width:Math.round(e*f.width/f.height*100)/100,onContextMenu:n?l:void 0,className:`x1lliihq x2lah0s`,children:[(0,K.jsxs)(`defs`,{children:[(0,K.jsx)(`clipPath`,{id:p,children:(0,K.jsx)(`rect`,{...f.clipRect})}),(0,K.jsx)(`linearGradient`,{id:h,children:f.bandStops.map(e=>(0,K.jsx)(`stop`,{offset:e.offset,stopColor:e.color,stopOpacity:e.opacity},e.offset))}),(0,K.jsx)(`mask`,{id:m,maskUnits:`userSpaceOnUse`,...f.mask,children:(0,K.jsx)(O_,{clip:p,ink:`#fff`,seal:{fill:`#fff`}})})]}),(0,K.jsx)(O_,{clip:p,ink:`currentColor`,seal:{className:`xe8yr7n x1tl3b4t`}}),(0,K.jsx)(`g`,{mask:`url(#${m})`,children:(0,K.jsx)(`rect`,{fill:`url(#${h})`,ref:o,...f.band})})]})}var A_=e=>{e&&window.open(e,`_blank`,`noopener,noreferrer`)};function j_({compact:e=!1,status:t,waitingForLogin:n,onSignIn:r,onSignOut:i}){let{t:a,i18n:o}=s();if(!t)return null;if(!t.signedIn||!t.login){let e=jg(t.origin,o.language),i=(0,K.jsxs)(`div`,{"data-cloud-connect-panel":``,className:`x78zum5 xdt5ytf x1v2ro7d x1m258z3 xqfszdh xfifm61 xo2rkog`,children:[(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,K.jsxs)(`span`,{className:`x3nfvp2 x6s0dn4 x1j9xkj6 x4z9k3i x1s688f`,children:[(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`x17z2i9w x17rw0jw x1kogg8i x6z2zk2 x1cge3fn xrvj5dj x1ku5rj1 x2lah0s`,children:(0,K.jsx)(Vo,{size:13})}),a(`cloudEntry.connectTitle`)]}),(0,K.jsx)(`span`,{className:`x1j6dyjg xddlp02`,children:a(`cloudEntry.freeStart`)})]}),(0,K.jsxs)(`div`,{className:`x78zum5 xdt5ytf x17d4w8g`,children:[(0,K.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,K.jsx)(Se,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitShareTitle`)}),(0,K.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitShareBody`)})]})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,K.jsx)(rs,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitPhoneTitle`)}),(0,K.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitPhoneBody`)})]})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x1cy8zhl xmmi0ta x1vvogim x1awh872 xur7f20 xmkeg23 x1y0btm7 x12xov25 x2fo67v`,children:[(0,K.jsx)(So,{"aria-hidden":`true`,size:14,className:`x1cge3fn x2lah0s xr9ek0c`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`span`,{className:`x1lliihq xfifm61 xh88oxj xo2rkog`,children:a(`cloudEntry.benefitSyncTitle`)}),(0,K.jsx)(`span`,{className:`x1lliihq x1j6dyjg x1bo0w0s xfrs9s4`,children:a(`cloudEntry.benefitSyncBody`)})]})]})]}),(0,K.jsx)(z,{className:{className:`xh8yej3 x90ne7k x3nfvp2 x6s0dn4 xl56j7k x1j9xkj6 xc342km xur7f20 x15az74h x12s0oaj xt9vybz xqfszdh x1ct8sxb xh88oxj x1ypdohk`}.className,icon:mo,loading:n,type:`primary`,onClick:r,children:a(n?`settings.waitingLogin`:`common.signInGithub`)}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1nejdyq x1j6dyjg xddlp02 xfrs9s4`,children:[(0,K.jsx)(xo,{"aria-hidden":`true`,size:11}),(0,K.jsx)(`span`,{children:a(`cloudEntry.privateByDefault`)})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x1qughib x167g77z`,children:[(0,K.jsx)(o_,{origin:t.origin}),e?(0,K.jsxs)(`a`,{href:e,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1ed6fcf x1j6dyjg xddlp02 xytdrwj x1hl2dhg xuxw1ft`,children:[a(`cloudEntry.learnShort`),(0,K.jsx)(yo,{"aria-hidden":`true`,size:11})]}):null]})]});return(0,K.jsx)(Gt,{content:i,placement:`bottomRight`,popupProps:{"aria-label":a(`cloudEntry.connectTitle`)},trigger:`click`,children:(0,K.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,K.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct x1iug7pk x2lah0s`}),(0,K.jsx)(`span`,{children:a(`cloudEntry.connectCta`)}),(0,K.jsx)(`span`,{className:`x1pixwil xpilrb4 x1t7ytsu x13ft1s6 x1j6dyjg xo1l8bm xf9vgkq xy0uqqd`,children:a(`cloudEntry.connectHint`)})]})})}let c=t.login,l=Mg(t.origin);return(0,K.jsxs)(K.Fragment,{children:[!e&&l?(0,K.jsxs)(`a`,{"data-cloud-header-link":``,href:l,rel:`noopener noreferrer`,target:`_blank`,className:`x3nfvp2 x6s0dn4 x1nejdyq x1fgtraw xdqyycr x1kogg8i xjbqb8w xj0l527 x1bo0w0s xytdrwj xfifm61 xk50ysn x1hl2dhg xuxw1ft x1gz44f`,children:[(0,K.jsx)(Vo,{"aria-hidden":`true`,size:13}),(0,K.jsx)(`span`,{children:`Cloud`}),(0,K.jsx)(yo,{"aria-hidden":`true`,size:12})]}):null,(0,K.jsx)(Ht,{items:[{key:`status`,disabled:!0,label:`${c} · ${a(`settings.menuStatus`,{state:t.autoPublish?.enabled?a(`settings.on`):a(`settings.off`)})}`},{type:`divider`,key:`cloud-divider`},{key:`open-cloud`,icon:Vo,label:a(`cloudEntry.openCloud`),extra:`↗`,onClick:()=>A_(l)},{key:`public-profile`,icon:Ee,label:a(`cloudEntry.publicProfile`),extra:`/u/${c} ↗`,onClick:()=>A_(Ng(t.origin,c))},{key:`plans`,icon:Go,label:a(`cloudEntry.plans`),extra:`↗`,onClick:()=>A_(Pg(t.origin))},{type:`divider`,key:`settings-divider`},{key:`settings`,icon:ts,label:a(`settings.open`),onClick:Tg},{key:`sign-out`,icon:Yo,label:a(`settings.signOut`),onClick:()=>void i?.()}],children:(0,K.jsx)(`button`,{"aria-label":a(`settings.accountMenu`,{login:c}),type:`button`,className:`x78zum5 x1717udv xc342km x16rqkct xjbqb8w x1ypdohk x1hl8ikr`,children:(0,K.jsx)(zd,{alt:``,avatar:`/api/avatar/github/${c}`,shape:`circle`,size:28,className:`xs625wh`})})})]})}var M_=(0,q.createContext)(!1),N_=(0,q.createContext)(null),P_=M_.Provider,F_=N_.Provider,I_=()=>typeof window<`u`&&window.parent!==window&&Te()&&!tt();function L_(){return(0,q.useContext)(M_)||I_()}function R_(){return(0,q.useContext)(N_)}function z_({type:e,id:t,docHeader:n,children:r}){let{t:i}=s(),a=ug(),[c,l]=(0,q.useState)(t),[u,d]=(0,q.useState)(null),f=`${e}/${t}`;(0,q.useEffect)(()=>{l(t);let e=()=>{let e=document.title?.trim();e&&e!==`Ryugi`&&e!==`Artifacts · Ryugi`&&l(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 p=!!a.status?.signedIn&&!!a.status.login;return(0,K.jsxs)(`div`,{"data-local-shell":``,className:`xixxii4 x10a8y8t x78zum5 xdt5ytf x184qs1t`,children:[(0,K.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,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x883omv xeuugli x98rzlu`,children:[(0,K.jsx)(`a`,{"aria-label":i(`localShell.backToList`),href:`/`,className:`x3nfvp2 x6s0dn4 x2lah0s xo2rkog x12rs2w1 x1hl2dhg x1sxf85j`,children:(0,K.jsx)(k_,{height:19})}),(0,K.jsxs)(`nav`,{"aria-label":i(`localShell.breadcrumb`),className:`x78zum5 x6s0dn4 x167g77z xeuugli x1ct8sxb xuxw1ft`,children:[(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s`,children:`/`}),(0,K.jsx)(`span`,{className:`x1bo0w0s x2lah0s xt0psk2 xkaaz9w`,children:i(`type.${e}`)}),(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`xddlp02 x2lah0s xt0psk2 xkaaz9w`,children:`/`}),(0,K.jsx)(`span`,{title:c,className:`xeuugli xb3r6kr xlyipyv x1s688f xo2rkog`,children:c})]})]}),(0,K.jsxs)(`div`,{className:`x78zum5 x6s0dn4 x167g77z x2lah0s`,children:[(0,K.jsx)(`div`,{ref:d,className:`xjp7ctv`}),o(e)&&n?.header?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(je,{available:n.header.history,comments:n.header.comments,open:n.header.historyOpen,onComments:()=>n.history(`close`),onHistory:()=>n.history(`toggle`)}),(0,K.jsx)(vo,{state:n.header.documentExport,onExport:n.exportPdf}),(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`x1i1rx1s xlup9mm x2lah0s xh6qj2i`})]}):null,a.status&&!p?(0,K.jsxs)(`span`,{"data-local-only-badge":``,className:`x3nfvp2 xkaaz9w x6s0dn4 x1nejdyq x1qt5hsa xddlp02 xuxw1ft`,children:[(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`x1v4s8kt xols6we x16rqkct xvndefy x1y0btm7 xhgr6co x9f619 x2lah0s`}),i(`server.localOnly`)]}):null,(0,K.jsx)(E_,{shell:!0,artifact:f}),p?(0,K.jsx)(j_,{compact:!0,status:a.status,waitingForLogin:a.waitingForLogin,onSignIn:()=>void a.login(),onSignOut:async()=>{await Z(`POST`,`logout`),await a.refresh()}}):(0,K.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:Tg,children:(0,K.jsx)(ts,{"aria-hidden":`true`,size:14})})]})]}),(0,K.jsx)(`div`,{className:`x1n2onr6 x98rzlu x2lwn1j x78zum5 xdt5ytf xb3r6kr`,children:(0,K.jsx)(P_,{value:!0,children:(0,K.jsx)(F_,{value:u,children:r})})})]})}var B_=1e3,V_=`ryugi:embed:hello`,H_=`ryugi:embed:heartbeat`,U_=`ryugi:embed:painted`,W_=`ryugi:embed:position`,G_=`ryugi:embed:positioned`;function K_({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===W_&&a.anchor&&t&&t(a.anchor).then(()=>r(G_))};n.addEventListener(`message`,i),r(V_,t?{position:!0}:void 0);let a=setInterval(()=>r(H_),B_),o=!1;return{painted(){o||(o=!0,r(U_))},close(){clearInterval(a),n.removeEventListener(`message`,i)}}}function q_(e=document,t=window,n){let r=e.documentElement.dataset.ryugiEmbedParent;return r?K_({parentOrigin:r,onPosition:n,win:t}):null}var J_=()=>new Promise(e=>requestAnimationFrame(()=>requestAnimationFrame(()=>e()))),Y_=e=>(Xe(e),J_()),X_=(0,q.createContext)(()=>{});function Z_(){let e=(0,q.useRef)(null),t=(0,q.useRef)(!1);return(0,q.useEffect)(()=>{let n=q_(document,window,Y_);return e.current=n,t.current&&n?.painted(),()=>{n?.close(),e.current=null}},[]),(0,q.useCallback)(()=>{t.current=!0,e.current?.painted()},[])}function Q_(e){let t=(0,q.useContext)(X_);(0,q.useEffect)(()=>{if(!e)return;let n=0,r=requestAnimationFrame(()=>{n=requestAnimationFrame(()=>{t(),$e()&&T({kind:`painted`})})});return()=>{cancelAnimationFrame(r),cancelAnimationFrame(n)}},[e,t])}function $_(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 ev={artboard:{Layout:(0,q.lazy)(()=>i(async()=>{let{ArtboardLayout:e}=await import(`./ArtboardLayout-CyP7z5iV.js`);return{ArtboardLayout:e}},__vite__mapDeps([19,1,20,21,4,22,16,2,3,5,6,7,17,13,23,24,25,26,27,28,29,11,12,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,18,50,51,52,53,54,10,55,56,57,58,59,60,15,8,9,61,62,63,64]),import.meta.url).then(({ArtboardLayout:e})=>({default:e})))},document:{Layout:(0,q.lazy)(()=>i(async()=>{let{DocumentLayout:e}=await import(`./DocumentLayout-16zcY3cg.js`);return{DocumentLayout:e}},__vite__mapDeps([65,1,4,5,2,3,6,7]),import.meta.url).then(({DocumentLayout:e})=>({default:e})))},html:{Layout:(0,q.lazy)(()=>i(async()=>{let{HtmlLayout:e}=await import(`./HtmlLayout-BQS68lEe.js`);return{HtmlLayout:e}},__vite__mapDeps([66,1,20,21,4,22,16,2,3,5,6,7,17,13,67,24,46,68,55,56]),import.meta.url).then(({HtmlLayout:e})=>({default:e})))},whiteboard:{Layout:(0,q.lazy)(()=>i(async()=>{let{WhiteboardLayout:e}=await import(`./WhiteboardLayout-qGm-CExy.js`);return{WhiteboardLayout:e}},__vite__mapDeps([69,1,21,4,22,16,2,3,5,6,7,17,13,70,71,24,18,41,72,36,73,74,51,31,52,37,75,45,76,77,10,30,11,12,48,38,39,49,46,57,78,62,79,43,44,80,81,82]),import.meta.url).then(({WhiteboardLayout:e})=>({default:e}))),embedIn:e=>(0,K.jsx)(fg,{pageWindow:$_(),children:e})},verify:{Layout:(0,q.lazy)(()=>i(async()=>{let{VerifyLayout:e}=await import(`./VerifyLayout--deiRi4o.js`);return{VerifyLayout:e}},__vite__mapDeps([83,1,16,2,3,4,5,6,7,17,13,21,22,84,85,71,24,18,41,72,36,73,74,51,31,52,37,75,45,76,39,86,87,88,89,80,90,48,38,49,12,46,91,27,92,93,11,79,26,10,8,9,78,94,68,95,58,59,29,96,97]),import.meta.url).then(({VerifyLayout:e})=>({default:e})))},slides:{Layout:(0,q.lazy)(()=>i(async()=>{let{SlidesLayout:e}=await import(`./SlidesLayout-CSeSindR.js`);return{SlidesLayout:e}},__vite__mapDeps([98,1,20,21,4,22,16,2,3,5,6,7,17,13,99,94,77,68,55,56,29,67,24,46,10,48,38,39,49,12,34,35,36,37,40,41,42,74,80,87,44,45,54,75,31,62,9,15,18,100,52,53,90,27,101,8,57,93,102,103,23,104]),import.meta.url).then(({SlidesLayout:e})=>({default:e}))),bare:e=>new URLSearchParams(e).has(`live`)},report:{Layout:(0,q.lazy)(()=>i(async()=>{let{ReportLayout:e}=await import(`./ReportLayout-DPnqWYPZ.js`);return{ReportLayout:e}},__vite__mapDeps([105,1,20,21,4,22,16,2,3,5,6,7,17,13,67,24,46,68,55,56,29,80,10,35,36,48,38,39,49,12,61,89,53,91]),import.meta.url).then(({ReportLayout:e})=>({default:e})))},storyboard:{Layout:(0,q.lazy)(()=>i(async()=>{let{StoryboardLayout:e}=await import(`./StoryboardLayout-DZVJbnzc.js`);return{StoryboardLayout:e}},__vite__mapDeps([106,1,4,20,21,22,16,2,3,5,6,7,17,13,107,29,68,67,24,46,55,56,38,39,54,108,53,93,23,48,49,12,80,92,102,15,27,40,41,44,45,35,36,73,75,31,32,33,42,52,60]),import.meta.url).then(({StoryboardLayout:e})=>({default:e})))}},tv=(0,q.lazy)(()=>i(async()=>{let{StoryboardRenderLayout:e}=await import(`./StoryboardRender-DORxY44d.js`);return{StoryboardRenderLayout:e}},__vite__mapDeps([109,1,107,2,3,4,5,6,7,29,68,20,21,22,16,17,13]),import.meta.url).then(({StoryboardRenderLayout:e})=>({default:e}))),nv=(0,q.lazy)(()=>i(async()=>{let{PreviewArtifactLayout:e}=await import(`./PreviewArtifactLayout-B4SZfLvw.js`);return{PreviewArtifactLayout:e}},__vite__mapDeps([110,1,4,16,2,3,5,6,7,17,13,22,102,15,38,39,24,10,67,46,47,54,48,49,12,100,44,45,11,42,52,111]),import.meta.url).then(({PreviewArtifactLayout:e})=>({default:e}))),rv=(0,q.lazy)(()=>i(async()=>{let{AutoPublishBar:e}=await import(`./auto-publish-BXmqx8BX.js`);return{AutoPublishBar:e}},__vite__mapDeps([112,1,113,13,3,4,5,2,6,7]),import.meta.url).then(({AutoPublishBar:e})=>({default:e}))),iv=(0,q.lazy)(()=>i(async()=>{let{SettingsDialog:e}=await import(`./settings-wKTRexHi.js`);return{SettingsDialog:e}},__vite__mapDeps([114,1,16,2,3,4,5,6,7,17,13,31,54,14,78,46]),import.meta.url).then(({SettingsDialog:e})=>({default:e}))),av=(0,q.lazy)(()=>i(async()=>{let{ArtifactList:e}=await import(`./ArtifactList-D1Cv2wcz.js`);return{ArtifactList:e}},__vite__mapDeps([115,1,35,2,3,4,5,6,7,16,17,13,36,24,42,38,39,54,23,91,75,111,67,46,14,50,56,59,44,45,62,18,22]),import.meta.url).then(({ArtifactList:e})=>({default:e}))),ov=(0,q.lazy)(()=>Promise.all([i(()=>import(`./split-BJA_5Rtf.js`),__vite__mapDeps([116,1,94,16,2,3,4,5,6,7,17,13,56,15,88,101,44,45,46,117,86,108,72,90,10,9,103,96,118,49,81,119]),import.meta.url),i(()=>import(`./local-split-host-DaeACaX5.js`).then(e=>e.n),__vite__mapDeps([99,1,94,16,2,3,4,5,6,7,17,13,22]),import.meta.url)]).then(([{SplitShell:e},{localSplitHost:t}])=>({default:n=>(0,K.jsx)(e,{...n,host:t})}))),sv=(0,q.lazy)(()=>i(async()=>{let{PreviewLayout:e}=await import(`./PreviewLayout-DiIQthoy.js`).then(e=>e.n);return{PreviewLayout:e}},__vite__mapDeps([120,1,4,2,3,5,6,7,25,79]),import.meta.url).then(({PreviewLayout:e})=>({default:e}))),cv=(e,t)=>(0,K.jsxs)(K.Fragment,{children:[e,(0,K.jsx)(rv,{}),(0,K.jsx)(iv,{}),t&&(0,K.jsx)(Kh,{artifact:t})]}),lv=(e,t,n)=>cv((0,K.jsx)(z_,{id:t,type:e,children:n}),`${e}/${t}`);function uv({type:e,id:t,split:n}){let[r,i]=(0,q.useState)({type:e,id:t}),[a,o]=(0,q.useState)(null);(0,q.useEffect)(()=>{i({type:e,id:t})},[e,t]);let s=(0,q.useCallback)(e=>{i(t=>t.type===e.primary.type&&t.id===e.primary.id?t:e.primary)},[]),c=(0,q.useCallback)(e=>{o(e)},[]);return cv((0,K.jsx)(z_,{docHeader:a,id:r.id,type:r.type,children:(0,K.jsx)(ov,{fill:!0,hostPrimaryDocument:!0,id:t,split:n,type:e,onDocumentHeader:c,onPanes:s})}),`${r.type}/${r.id}`)}function dv({id:e,type:t}){let n=Z_(),{Layout:r,embedIn:i}=ev[t],a=(0,K.jsx)(r,{id:e});return(0,K.jsxs)(X_,{value:n,children:[Uh(location.search)&&(0,K.jsx)(Kh,{artifact:`${t}/${e}`}),i?i(a):a]})}function fv(){let[e]=bh(),t=p(e);if((0,q.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=g(t.pathname,new URL(e.href).pathname),t.href!==location.href&&history.replaceState(history.state,``,t)},[]),(0,q.useEffect)(()=>{window.scrollTo(0,0)},[e]),t.kind===`list`)return cv((0,K.jsx)(av,{}));if(t.kind===`unknown`)return(0,K.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,K.jsx)(sv,{id:n,type:t.type});if(t.kind===`dev-preview`)return cv((0,K.jsx)(nv,{id:n}),`preview/${n}`);if(t.kind===`embed`)return(0,K.jsx)(dv,{id:n,type:t.type});if(t.kind===`render`)return(0,K.jsx)(tv,{id:n});if(m(t.type).standalone){let{Layout:e,bare:r}=ev[t.type],i=(0,K.jsx)(e,{id:n});return r?.(location.search)?cv(i,`${t.type}/${n}`):lv(t.type,n,i)}return(0,K.jsx)(uv,{id:n,split:Ie(t,location.search)?.split??null,type:t.type})}function pv(){return(0,K.jsx)(q.Suspense,{fallback:(0,K.jsx)(`div`,{className:`x78zum5 x6s0dn4 xl56j7k x5yr21d xggk2y7 x1bo0w0s xqfszdh xif65rj`,children:(0,K.jsx)(Eh,{label:b(`common.loading`)})}),children:(0,K.jsx)(fv,{})})}Le(),n(),document.documentElement.lang=v[_.language];function mv(){return y(),(0,K.jsx)(Bd,{features:vf,children:(0,K.jsxs)(oe,{enableCustomFonts:!1,motion:Km,children:[(0,K.jsx)(pv,{}),(0,K.jsx)(se,{}),(0,K.jsx)(tn,{}),(0,K.jsx)(wp,{})]})})}(0,qm.createRoot)(document.getElementById(`root`)).render((0,K.jsx)(q.StrictMode,{children:(0,K.jsx)(mv,{})}));export{Y as A,zo as B,Qh as C,kh as D,Ah as E,rs as F,ts as I,$o as L,dp as M,Sf as N,Eh as O,zd as P,Zo as R,ug as S,Nh as T,Tg as _,k_ as a,hg as b,g_ as c,o_ as d,Pg as f,Eg as g,Ng as h,j_ as i,mp as j,zp as k,m_ as l,jg as m,L_ as n,E_ as o,Mg as p,R_ as r,f_ as s,Q_ as t,p_ as u,kg as v,Lh as w,Z as x,mg as y,Uo as z};