@hanzo/team 0.1.16 → 0.1.18
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.
- package/dist/404.html +2 -2
- package/dist/admin/index.html +2 -2
- package/dist/agents/algo/index.html +2 -2
- package/dist/agents/art/index.html +2 -2
- package/dist/agents/biz/index.html +2 -2
- package/dist/agents/cal/index.html +2 -2
- package/dist/agents/core/index.html +2 -2
- package/dist/agents/cyber/index.html +2 -2
- package/dist/agents/data/index.html +2 -2
- package/dist/agents/db/index.html +2 -2
- package/dist/agents/des/index.html +2 -2
- package/dist/agents/dev/index.html +2 -2
- package/dist/agents/doc/index.html +2 -2
- package/dist/agents/ed/index.html +2 -2
- package/dist/agents/fin/index.html +2 -2
- package/dist/agents/gov/index.html +2 -2
- package/dist/agents/huma/index.html +2 -2
- package/dist/agents/index.html +2 -2
- package/dist/agents/lang/index.html +2 -2
- package/dist/agents/law/index.html +2 -2
- package/dist/agents/mana/index.html +2 -2
- package/dist/agents/mark/index.html +2 -2
- package/dist/agents/mo/index.html +2 -2
- package/dist/agents/mu/index.html +2 -2
- package/dist/agents/opera/index.html +2 -2
- package/dist/agents/rev/index.html +2 -2
- package/dist/agents/sal/index.html +2 -2
- package/dist/agents/sci/index.html +2 -2
- package/dist/agents/sec/index.html +2 -2
- package/dist/agents/su/index.html +2 -2
- package/dist/agents/vi/index.html +2 -2
- package/dist/apps/ads/index.html +2 -2
- package/dist/apps/ai-chat/index.html +2 -2
- package/dist/apps/analytics/index.html +2 -2
- package/dist/apps/billing/index.html +2 -2
- package/dist/apps/bots/index.html +2 -2
- package/dist/apps/cal/index.html +2 -2
- package/dist/apps/chat/index.html +2 -2
- package/dist/apps/cms/index.html +2 -2
- package/dist/apps/commerce/index.html +2 -2
- package/dist/apps/console/index.html +2 -2
- package/dist/apps/crm/index.html +2 -2
- package/dist/apps/dataroom/index.html +2 -2
- package/dist/apps/dev/index.html +2 -2
- package/dist/apps/email/index.html +2 -2
- package/dist/apps/index.html +2 -2
- package/dist/apps/meet/index.html +2 -2
- package/dist/apps/platform/index.html +2 -2
- package/dist/apps/sign/index.html +2 -2
- package/dist/apps/social/index.html +2 -2
- package/dist/apps/tracker/index.html +2 -2
- package/dist/assets/{Bots-CPIU0Xgd.js → Bots-CIxJCKzl.js} +86 -86
- package/dist/assets/Bots-CIxJCKzl.js.map +1 -0
- package/dist/assets/ModelPickerMenu-BpCc5BDl.js +2 -0
- package/dist/assets/{ModelPickerMenu-Dx9FATCv.js.map → ModelPickerMenu-BpCc5BDl.js.map} +1 -1
- package/dist/assets/{ThemeToggleNext-Cb-dedIF.js → ThemeToggleNext-Bh1CU3Nq.js} +2 -2
- package/dist/assets/{ThemeToggleNext-Cb-dedIF.js.map → ThemeToggleNext-Bh1CU3Nq.js.map} +1 -1
- package/dist/assets/index-CngqRawd.css +1 -0
- package/dist/assets/index-nlYZdUfp.js +194 -0
- package/dist/assets/{index-BSvxo5-z.js.map → index-nlYZdUfp.js.map} +1 -1
- package/dist/assets/integrations-DW-vmr60.js.map +1 -1
- package/dist/auth/callback/index.html +2 -2
- package/dist/auth/index.html +2 -2
- package/dist/bots/index.html +2 -2
- package/dist/cal/index.html +2 -2
- package/dist/calendar/index.html +2 -2
- package/dist/chat/c-design/index.html +2 -2
- package/dist/chat/c-general/index.html +2 -2
- package/dist/chat/c-lux-bank/index.html +2 -2
- package/dist/chat/c-lux-bridge/index.html +2 -2
- package/dist/chat/c-revenue/index.html +2 -2
- package/dist/chat/c-support/index.html +2 -2
- package/dist/chat/c-tracker/index.html +2 -2
- package/dist/chat/c-ui/index.html +2 -2
- package/dist/chat/c-video/index.html +2 -2
- package/dist/chat/dm-algo/index.html +2 -2
- package/dist/chat/dm-art/index.html +2 -2
- package/dist/chat/dm-biz/index.html +2 -2
- package/dist/chat/dm-cal/index.html +2 -2
- package/dist/chat/dm-core/index.html +2 -2
- package/dist/chat/dm-cyber/index.html +2 -2
- package/dist/chat/dm-data/index.html +2 -2
- package/dist/chat/dm-db/index.html +2 -2
- package/dist/chat/dm-des/index.html +2 -2
- package/dist/chat/dm-dev/index.html +2 -2
- package/dist/chat/dm-doc/index.html +2 -2
- package/dist/chat/dm-ed/index.html +2 -2
- package/dist/chat/dm-fin/index.html +2 -2
- package/dist/chat/dm-gov/index.html +2 -2
- package/dist/chat/dm-huma/index.html +2 -2
- package/dist/chat/dm-lang/index.html +2 -2
- package/dist/chat/dm-law/index.html +2 -2
- package/dist/chat/dm-mana/index.html +2 -2
- package/dist/chat/dm-mark/index.html +2 -2
- package/dist/chat/dm-mo/index.html +2 -2
- package/dist/chat/dm-mu/index.html +2 -2
- package/dist/chat/dm-opera/index.html +2 -2
- package/dist/chat/dm-rev/index.html +2 -2
- package/dist/chat/dm-sal/index.html +2 -2
- package/dist/chat/dm-sci/index.html +2 -2
- package/dist/chat/dm-sec/index.html +2 -2
- package/dist/chat/dm-su/index.html +2 -2
- package/dist/chat/dm-vi/index.html +2 -2
- package/dist/chat/index.html +2 -2
- package/dist/crm/analytics/index.html +2 -2
- package/dist/crm/automations/index.html +2 -2
- package/dist/crm/campaigns/index.html +2 -2
- package/dist/crm/companies/index.html +2 -2
- package/dist/crm/contacts/index.html +2 -2
- package/dist/crm/customers/index.html +2 -2
- package/dist/crm/deliverability/index.html +2 -2
- package/dist/crm/forms/index.html +2 -2
- package/dist/crm/funds/index.html +2 -2
- package/dist/crm/index.html +2 -2
- package/dist/crm/investors/index.html +2 -2
- package/dist/crm/journeys/index.html +2 -2
- package/dist/crm/leads/index.html +2 -2
- package/dist/crm/lists/index.html +2 -2
- package/dist/crm/opportunities/index.html +2 -2
- package/dist/crm/segments/index.html +2 -2
- package/dist/crm/settings/index.html +2 -2
- package/dist/crm/templates/index.html +2 -2
- package/dist/crm/webhooks/index.html +2 -2
- package/dist/docs/index.html +2 -2
- package/dist/files/index.html +2 -2
- package/dist/inbox/index.html +2 -2
- package/dist/index.html +2 -2
- package/dist/issues/index.html +2 -2
- package/dist/issues/kanban/index.html +2 -2
- package/dist/issues/list/index.html +2 -2
- package/dist/login/index.html +2 -2
- package/dist/mail/index.html +2 -2
- package/dist/meet/index.html +2 -2
- package/dist/mine/index.html +2 -2
- package/dist/people/index.html +2 -2
- package/dist/personas/abai_qunanbaiuly.svg +3 -3
- package/dist/personas/ada.svg +3 -3
- package/dist/personas/adonis.svg +3 -3
- package/dist/personas/aime_cesaire.svg +3 -3
- package/dist/personas/al_biruni.svg +3 -3
- package/dist/personas/al_farabi.svg +3 -3
- package/dist/personas/al_khwarizmi.svg +3 -3
- package/dist/personas/al_kindi.svg +3 -3
- package/dist/personas/alan_watts.svg +3 -3
- package/dist/personas/alexandra_david_neel.svg +3 -3
- package/dist/personas/alisher_navoi.svg +3 -3
- package/dist/personas/amir_khusrau.svg +3 -3
- package/dist/personas/angelou.svg +3 -3
- package/dist/personas/anne_sexton.svg +3 -3
- package/dist/personas/aquinas.svg +3 -3
- package/dist/personas/aryabhata.svg +3 -3
- package/dist/personas/attar.svg +3 -3
- package/dist/personas/augustine.svg +3 -3
- package/dist/personas/averroes.svg +3 -3
- package/dist/personas/avicenna.svg +3 -3
- package/dist/personas/baal_shem_tov.svg +3 -3
- package/dist/personas/baha_ullah.svg +3 -3
- package/dist/personas/basho.svg +3 -3
- package/dist/personas/basil_great.svg +3 -3
- package/dist/personas/bernard_clairvaux.svg +3 -3
- package/dist/personas/bhaskara_ii.svg +3 -3
- package/dist/personas/brahmagupta.svg +3 -3
- package/dist/personas/cao_xueqin.svg +3 -3
- package/dist/personas/cesare_beccaria.svg +3 -3
- package/dist/personas/chikamatsu_monzaemon.svg +3 -3
- package/dist/personas/christiaan_huygens.svg +3 -3
- package/dist/personas/cicero.svg +3 -3
- package/dist/personas/clarice_lispector.svg +3 -3
- package/dist/personas/claudio_monteverdi.svg +3 -3
- package/dist/personas/clement_alexandria.svg +3 -3
- package/dist/personas/coltrane.svg +3 -3
- package/dist/personas/constance_garnett.svg +3 -3
- package/dist/personas/creative.svg +3 -3
- package/dist/personas/cv_raman.svg +3 -3
- package/dist/personas/cynthia_dwork.svg +3 -3
- package/dist/personas/dali.svg +3 -3
- package/dist/personas/david_bowie.svg +3 -3
- package/dist/personas/david_chaum.svg +3 -3
- package/dist/personas/davis.svg +3 -3
- package/dist/personas/desmond_tutu.svg +3 -3
- package/dist/personas/dogen.svg +3 -3
- package/dist/personas/donald_knuth.svg +3 -3
- package/dist/personas/du_fu.svg +3 -3
- package/dist/personas/edgar_codd.svg +3 -3
- package/dist/personas/eileen_chang.svg +3 -3
- package/dist/personas/emilie_du_chatelet.svg +3 -3
- package/dist/personas/emmeline_pankhurst.svg +3 -3
- package/dist/personas/forugh_farrokhzad.svg +3 -3
- package/dist/personas/france_preseren.svg +3 -3
- package/dist/personas/frances_perkins.svg +3 -3
- package/dist/personas/franz_schubert.svg +3 -3
- package/dist/personas/gabriel_garcia_marquez.svg +3 -3
- package/dist/personas/gabriela_mistral.svg +3 -3
- package/dist/personas/galois.svg +3 -3
- package/dist/personas/gandhi.svg +3 -3
- package/dist/personas/gao_xingjian.svg +3 -3
- package/dist/personas/geoffrey_hinton.svg +2 -2
- package/dist/personas/george_eliot.svg +3 -3
- package/dist/personas/george_martin.svg +3 -3
- package/dist/personas/georges_lemaitre.svg +3 -3
- package/dist/personas/giambattista_vico.svg +3 -3
- package/dist/personas/godel.svg +3 -3
- package/dist/personas/goethe.svg +3 -3
- package/dist/personas/gregory_nazianzus.svg +3 -3
- package/dist/personas/gregory_palamas.svg +3 -3
- package/dist/personas/grothendieck.svg +3 -3
- package/dist/personas/guru_nanak.svg +3 -3
- package/dist/personas/hafez.svg +3 -3
- package/dist/personas/hickey.svg +2 -2
- package/dist/personas/hildegard_bingen.svg +3 -3
- package/dist/personas/hua_luogeng.svg +3 -3
- package/dist/personas/hubert_dreyfus.svg +3 -3
- package/dist/personas/hugo.svg +3 -3
- package/dist/personas/ibn_al_haytham.svg +3 -3
- package/dist/personas/ibn_arabi.svg +3 -3
- package/dist/personas/jack_ma.svg +3 -3
- package/dist/personas/jamsetji_tata.svg +3 -3
- package/dist/personas/janis_joplin.svg +3 -3
- package/dist/personas/jcr_licklider.svg +3 -3
- package/dist/personas/jerome.svg +3 -3
- package/dist/personas/jimi_hendrix.svg +3 -3
- package/dist/personas/john_cage.svg +3 -3
- package/dist/personas/john_maynard_keynes.svg +3 -3
- package/dist/personas/john_wanamaker.svg +3 -3
- package/dist/personas/joseph_weizenbaum.svg +3 -3
- package/dist/personas/junichiro_tanizaki.svg +3 -3
- package/dist/personas/kalidasa.svg +3 -3
- package/dist/personas/kamo_no_chomei.svg +3 -3
- package/dist/personas/kaoru_ishikawa.svg +3 -3
- package/dist/personas/karen_sparck_jones.svg +3 -3
- package/dist/personas/katsushika_hokusai.svg +3 -3
- package/dist/personas/khalil_gibran.svg +3 -3
- package/dist/personas/kovalevskaya.svg +3 -3
- package/dist/personas/kunihiko_fukushima.svg +3 -3
- package/dist/personas/kwasi_wiredu.svg +3 -3
- package/dist/personas/leibniz.svg +3 -3
- package/dist/personas/leo_burnett.svg +3 -3
- package/dist/personas/li_qingzhao.svg +3 -3
- package/dist/personas/liu_hui.svg +3 -3
- package/dist/personas/lu_xun.svg +3 -3
- package/dist/personas/lucretius.svg +3 -3
- package/dist/personas/madhava.svg +3 -3
- package/dist/personas/madonna.svg +3 -3
- package/dist/personas/mahmoud_darwish.svg +3 -3
- package/dist/personas/maimonides.svg +3 -3
- package/dist/personas/mandela.svg +3 -3
- package/dist/personas/mandela_contextual.svg +3 -3
- package/dist/personas/mariama_ba.svg +3 -3
- package/dist/personas/marina_tsvetaeva.svg +3 -3
- package/dist/personas/mary_parker_follett.svg +3 -3
- package/dist/personas/mary_shelley.svg +3 -3
- package/dist/personas/massimo_vignelli.svg +2 -2
- package/dist/personas/meister_eckhart.svg +3 -3
- package/dist/personas/miguel_angel_asturias.svg +3 -3
- package/dist/personas/mircea_eliade.svg +3 -3
- package/dist/personas/mirza_ghalib.svg +3 -3
- package/dist/personas/morrison.svg +3 -3
- package/dist/personas/muhammad_ali.svg +3 -3
- package/dist/personas/murasaki_shikibu.svg +3 -3
- package/dist/personas/nagarjuna.svg +3 -3
- package/dist/personas/nazim_hikmet.svg +3 -3
- package/dist/personas/nguyen_du.svg +3 -3
- package/dist/personas/nina_simone.svg +3 -3
- package/dist/personas/nishida_kitaro.svg +3 -3
- package/dist/personas/nizami.svg +3 -3
- package/dist/personas/norbert_wiener.svg +3 -3
- package/dist/personas/paglia.svg +2 -2
- package/dist/personas/pascal.svg +3 -3
- package/dist/personas/plato.svg +3 -3
- package/dist/personas/plotinus.svg +3 -3
- package/dist/personas/plutarch.svg +3 -3
- package/dist/personas/pramoedya_ananta_toer.svg +3 -3
- package/dist/personas/premchand.svg +3 -3
- package/dist/personas/prince.svg +3 -3
- package/dist/personas/pseudo_dionysius.svg +3 -3
- package/dist/personas/ptolemy.svg +3 -3
- package/dist/personas/pythagoras.svg +3 -3
- package/dist/personas/qu_yuan.svg +3 -3
- package/dist/personas/queen_liliuokalani.svg +3 -3
- package/dist/personas/rabia_al_adawiyya.svg +3 -3
- package/dist/personas/radia_perlman.svg +3 -3
- package/dist/personas/ralph_ellison.svg +3 -3
- package/dist/personas/ralph_merkle.svg +3 -3
- package/dist/personas/ramanujan.svg +3 -3
- package/dist/personas/ravi_shankar.svg +3 -3
- package/dist/personas/richard_victor.svg +3 -3
- package/dist/personas/robert_boyle.svg +3 -3
- package/dist/personas/romulo_gallegos.svg +3 -3
- package/dist/personas/ruben_dario.svg +3 -3
- package/dist/personas/rumi.svg +3 -3
- package/dist/personas/rumi_contextual.svg +3 -3
- package/dist/personas/saadi.svg +3 -3
- package/dist/personas/samuel_johnson.svg +3 -3
- package/dist/personas/sei_shonagon.svg +3 -3
- package/dist/personas/seki_takakazu.svg +3 -3
- package/dist/personas/sergey_brin.svg +3 -3
- package/dist/personas/sesshu_toyo.svg +3 -3
- package/dist/personas/shafi_goldwasser.svg +3 -3
- package/dist/personas/shen_congwen.svg +3 -3
- package/dist/personas/shen_kuo.svg +3 -3
- package/dist/personas/shitao.svg +3 -3
- package/dist/personas/sima_guang.svg +3 -3
- package/dist/personas/sima_qian.svg +3 -3
- package/dist/personas/sor_juana_ines_de_la_cruz.svg +3 -3
- package/dist/personas/stanley_marcus.svg +3 -3
- package/dist/personas/taher_elgamal.svg +3 -3
- package/dist/personas/tatsumi_hijikata.svg +3 -3
- package/dist/personas/tesla.svg +3 -3
- package/dist/personas/thelonious_monk.svg +3 -3
- package/dist/personas/thurgood_marshall.svg +3 -3
- package/dist/personas/tim_burton.svg +3 -3
- package/dist/personas/toru_takemitsu.svg +3 -3
- package/dist/personas/tpope.svg +3 -3
- package/dist/personas/trevor_noah.svg +3 -3
- package/dist/personas/tsongkhapa.svg +3 -3
- package/dist/personas/u_thant.svg +3 -3
- package/dist/personas/verghese_kurien.svg +3 -3
- package/dist/personas/vs_naipaul.svg +3 -3
- package/dist/personas/wang_anshi.svg +3 -3
- package/dist/personas/wang_wei.svg +3 -3
- package/dist/personas/wang_yangming.svg +3 -3
- package/dist/personas/whitfield_diffie.svg +3 -3
- package/dist/personas/william_harvey.svg +3 -3
- package/dist/personas/xunzi.svg +3 -3
- package/dist/personas/yasunari_kawabata.svg +3 -3
- package/dist/personas/yogananda.svg +3 -3
- package/dist/personas/yukio_mishima.svg +3 -3
- package/dist/personas/zeami_motokiyo.svg +3 -3
- package/dist/personas/zeekay.svg +2 -2
- package/dist/personas/zhu_xi.svg +3 -3
- package/dist/personas/zora_neale_hurston.svg +3 -3
- package/dist/projects/index.html +2 -2
- package/dist/projects/proj-crm/components/index.html +2 -2
- package/dist/projects/proj-crm/index.html +2 -2
- package/dist/projects/proj-crm/issues/index.html +2 -2
- package/dist/projects/proj-crm/issues/kanban/index.html +2 -2
- package/dist/projects/proj-crm/issues/list/index.html +2 -2
- package/dist/projects/proj-crm/milestones/index.html +2 -2
- package/dist/projects/proj-crm/templates/index.html +2 -2
- package/dist/projects/proj-dev/components/index.html +2 -2
- package/dist/projects/proj-dev/index.html +2 -2
- package/dist/projects/proj-dev/issues/index.html +2 -2
- package/dist/projects/proj-dev/issues/kanban/index.html +2 -2
- package/dist/projects/proj-dev/issues/list/index.html +2 -2
- package/dist/projects/proj-dev/milestones/index.html +2 -2
- package/dist/projects/proj-dev/templates/index.html +2 -2
- package/dist/projects/proj-mkt/components/index.html +2 -2
- package/dist/projects/proj-mkt/index.html +2 -2
- package/dist/projects/proj-mkt/issues/index.html +2 -2
- package/dist/projects/proj-mkt/issues/kanban/index.html +2 -2
- package/dist/projects/proj-mkt/issues/list/index.html +2 -2
- package/dist/projects/proj-mkt/milestones/index.html +2 -2
- package/dist/projects/proj-mkt/templates/index.html +2 -2
- package/dist/projects/proj-next/components/index.html +2 -2
- package/dist/projects/proj-next/index.html +2 -2
- package/dist/projects/proj-next/issues/index.html +2 -2
- package/dist/projects/proj-next/issues/kanban/index.html +2 -2
- package/dist/projects/proj-next/issues/list/index.html +2 -2
- package/dist/projects/proj-next/milestones/index.html +2 -2
- package/dist/projects/proj-next/templates/index.html +2 -2
- package/dist/settings/index.html +2 -2
- package/dist/time/index.html +2 -2
- package/package.json +2 -2
- package/dist/assets/Bots-CPIU0Xgd.js.map +0 -1
- package/dist/assets/ModelPickerMenu-Dx9FATCv.js +0 -2
- package/dist/assets/index-BSvxo5-z.js +0 -203
- package/dist/assets/index-DUEuN8sV.css +0 -1
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/ModelPickerMenu-BpCc5BDl.js","assets/rolldown-runtime-B0Z9INg1.js","assets/react-DIaL9_ob.js","assets/catalog-BM2B7gTj.js","assets/Anchor-Avsca6-o.js","assets/ThemeToggleNext-Bh1CU3Nq.js","assets/Bots-CIxJCKzl.js","assets/instrument-CmZcxFxx.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{a as e,t}from"./rolldown-runtime-B0Z9INg1.js";import{$ as n,A as r,C as i,D as a,Dt as o,Et as s,F as c,G as l,H as u,I as d,J as f,L as p,M as m,N as h,O as g,Ot as _,Q as v,R as y,St as b,T as x,Tt as S,U as C,W as w,X as T,Y as E,a as D,at as O,c as k,ct as A,d as j,dt as ee,et as M,f as N,g as P,gt as te,h as F,ht as I,i as ne,it as re,j as ie,l as L,m as ae,mt as oe,n as R,nt as se,o as ce,ot as le,p as ue,pt as de,r as fe,rt as pe,s as me,st as he,t as ge,tt as _e,u as ve,wt as ye,xt as be,y as xe,yt as Se,z}from"./react-DIaL9_ob.js";import{A as Ce,C as we,D as Te,E as Ee,O as De,S as Oe,T as ke,_ as Ae,a as je,b as Me,c as Ne,d as Pe,f as Fe,g as Ie,h as Le,i as Re,k as ze,l as Be,m as Ve,n as He,o as Ue,p as We,r as Ge,s as Ke,t as qe,u as Je,v as Ye,w as Xe,x as Ze,y as Qe}from"./instrument-CmZcxFxx.js";import{$ as $e,$t as et,A as tt,At as nt,B as rt,Bt as it,C as at,Ct as ot,D as st,Dt as ct,E as lt,Et as ut,F as dt,Ft as ft,G as pt,Gt as mt,H as ht,Ht as gt,I as _t,It as vt,J as yt,Jt as bt,K as xt,Kt as St,L as B,Lt as Ct,M as wt,Mt as Tt,N as Et,Nt as Dt,O as Ot,Ot as kt,P as At,Pt as jt,Q as Mt,Qt as Nt,Rt as Pt,S as Ft,St as It,T as Lt,Tt as Rt,U as zt,Ut as Bt,V as Vt,Vt as Ht,W as Ut,Wt,X as Gt,Xt as Kt,Y as qt,Yt as Jt,Z as Yt,Zt as Xt,_ as Zt,_t as Qt,an as $t,at as en,bt as tn,ct as nn,dt as rn,en as an,et as on,f as sn,ft as cn,gt as ln,ht as un,in as dn,it as fn,j as pn,k as mn,kt as hn,lt as gn,mt as _n,nn as vn,nt as yn,on as bn,ot as xn,pt as Sn,q as Cn,qt as wn,r as Tn,rn as En,rt as Dn,st as On,tn as kn,tt as An,ut as jn,v as Mn,vt as Nn,w as Pn,wt as Fn,xt as In,yt as Ln,z as Rn,zt as zn}from"./catalog-BM2B7gTj.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var Bn=t((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Vn=t(((e,t)=>{t.exports=Bn()})),Hn=t((e=>{var t=Vn(),n=_(),r=o();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function s(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function c(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function u(e){if(s(e)!==e)throw Error(i(188))}function d(e){var t=e.alternate;if(!t){if(t=s(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var o=a.alternate;if(o===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===o.child){for(o=a.child;o;){if(o===n)return u(a),e;if(o===r)return u(a),t;o=o.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=o;else{for(var c=!1,l=a.child;l;){if(l===n){c=!0,n=a,r=o;break}if(l===r){c=!0,r=a,n=o;break}l=l.sibling}if(!c){for(l=o.child;l;){if(l===n){c=!0,n=o,r=a;break}if(l===r){c=!0,r=o,n=a;break}l=l.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}var p=Object.assign,m=Symbol.for(`react.element`),h=Symbol.for(`react.transitional.element`),g=Symbol.for(`react.portal`),v=Symbol.for(`react.fragment`),y=Symbol.for(`react.strict_mode`),b=Symbol.for(`react.profiler`),x=Symbol.for(`react.consumer`),S=Symbol.for(`react.context`),C=Symbol.for(`react.forward_ref`),w=Symbol.for(`react.suspense`),T=Symbol.for(`react.suspense_list`),E=Symbol.for(`react.memo`),D=Symbol.for(`react.lazy`),O=Symbol.for(`react.activity`),k=Symbol.for(`react.memo_cache_sentinel`),A=Symbol.iterator;function j(e){return typeof e!=`object`||!e?null:(e=A&&e[A]||e[`@@iterator`],typeof e==`function`?e:null)}var ee=Symbol.for(`react.client.reference`);function M(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===ee?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case v:return`Fragment`;case b:return`Profiler`;case y:return`StrictMode`;case w:return`Suspense`;case T:return`SuspenseList`;case O:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case g:return`Portal`;case S:return e.displayName||`Context`;case x:return(e._context.displayName||`Context`)+`.Consumer`;case C:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case E:return t=e.displayName||null,t===null?M(e.type)||`Memo`:t;case D:t=e._payload,e=e._init;try{return M(e(t))}catch{}}return null}var N=Array.isArray,P=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F={pending:!1,data:null,method:null,action:null},I=[],ne=-1;function re(e){return{current:e}}function ie(e){0>ne||(e.current=I[ne],I[ne]=null,ne--)}function L(e,t){ne++,I[ne]=e.current,e.current=t}var ae=re(null),oe=re(null),R=re(null),se=re(null);function ce(e,t){switch(L(R,t),L(oe,e),L(ae,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Qd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Qd(t),e=$d(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}ie(ae),L(ae,e)}function le(){ie(ae),ie(oe),ie(R)}function ue(e){e.memoizedState!==null&&L(se,e);var t=ae.current,n=$d(t,e.type);t!==n&&(L(oe,e),L(ae,n))}function de(e){oe.current===e&&(ie(ae),ie(oe)),se.current===e&&(ie(se),cp._currentValue=F)}var fe,pe;function me(e){if(fe===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);fe=t&&t[1]||``,pe=-1<e.stack.indexOf(`
|
|
3
|
+
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
4
|
+
`+fe+e+pe}var he=!1;function ge(e,t){if(!e||he)return``;he=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
|
|
5
|
+
`),l=s.split(`
|
|
6
|
+
`);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
|
|
7
|
+
`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{he=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?me(n):``}function _e(e,t){switch(e.tag){case 26:case 27:case 5:return me(e.type);case 16:return me(`Lazy`);case 13:return e.child!==t&&t!==null?me(`Suspense Fallback`):me(`Suspense`);case 19:return me(`SuspenseList`);case 0:case 15:return ge(e.type,!1);case 11:return ge(e.type.render,!1);case 1:return ge(e.type,!0);case 31:return me(`Activity`);default:return``}}function ve(e){try{var t=``,n=null;do t+=_e(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
|
|
8
|
+
Error generating stack: `+e.message+`
|
|
9
|
+
`+e.stack}}var ye=Object.prototype.hasOwnProperty,be=t.unstable_scheduleCallback,xe=t.unstable_cancelCallback,Se=t.unstable_shouldYield,z=t.unstable_requestPaint,Ce=t.unstable_now,we=t.unstable_getCurrentPriorityLevel,Te=t.unstable_ImmediatePriority,Ee=t.unstable_UserBlockingPriority,De=t.unstable_NormalPriority,Oe=t.unstable_LowPriority,ke=t.unstable_IdlePriority,Ae=t.log,je=t.unstable_setDisableYieldValue,Me=null,Ne=null;function Pe(e){if(typeof Ae==`function`&&je(e),Ne&&typeof Ne.setStrictMode==`function`)try{Ne.setStrictMode(Me,e)}catch{}}var Fe=Math.clz32?Math.clz32:Re,Ie=Math.log,Le=Math.LN2;function Re(e){return e>>>=0,e===0?32:31-(Ie(e)/Le|0)|0}var ze=256,Be=262144,Ve=4194304;function He(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ue(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=He(n))):i=He(o):i=He(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=He(n))):i=He(o)):i=He(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ge(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ke(){var e=Ve;return Ve<<=1,!(Ve&62914560)&&(Ve=4194304),e}function qe(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Je(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ye(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Fe(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Xe(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Xe(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Fe(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Ze(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Fe(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Qe(e,t){var n=t&-t;return n=n&42?1:$e(n),(n&(e.suspendedLanes|t))===0?n:0}function $e(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function et(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function tt(){var e=te.p;return e===0?(e=window.event,e===void 0?32:wp(e.type)):e}function nt(e,t){var n=te.p;try{return te.p=e,t()}finally{te.p=n}}var rt=Math.random().toString(36).slice(2),it=`__reactFiber$`+rt,at=`__reactProps$`+rt,ot=`__reactContainer$`+rt,st=`__reactEvents$`+rt,ct=`__reactListeners$`+rt,lt=`__reactHandles$`+rt,ut=`__reactResources$`+rt,dt=`__reactMarker$`+rt;function ft(e){delete e[it],delete e[at],delete e[st],delete e[ct],delete e[lt]}function pt(e){var t=e[it];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ot]||n[it]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Sf(e);e!==null;){if(n=e[it])return n;e=Sf(e)}return t}e=n,n=e.parentNode}return null}function mt(e){if(e=e[it]||e[ot]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ht(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function gt(e){var t=e[ut];return t||=e[ut]={hoistableStyles:new Map,hoistableScripts:new Map},t}function _t(e){e[dt]=!0}var vt=new Set,yt={};function bt(e,t){xt(e,t),xt(e+`Capture`,t)}function xt(e,t){for(yt[e]=t,e=0;e<t.length;e++)vt.add(t[e])}var St=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),B={},Ct={};function wt(e){return ye.call(Ct,e)?!0:ye.call(B,e)?!1:St.test(e)?Ct[e]=!0:(B[e]=!0,!1)}function Tt(e,t,n){if(wt(t)){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}}function Et(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Dt(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Ot(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function kt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function At(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function jt(e){if(!e._valueTracker){var t=kt(e)?`checked`:`value`;e._valueTracker=At(e,t,``+e[t])}}function Mt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=kt(e)?e.checked?`true`:`false`:e.value),e=r,e!==n&&(t.setValue(e),!0)}function Nt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Pt=/[\n"\\]/g;function Ft(e){return e.replace(Pt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function It(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Ot(t)):e.value!==``+Ot(t)&&(e.value=``+Ot(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Rt(e,o,Ot(n)):Rt(e,o,Ot(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Ot(s):e.removeAttribute(`name`)}function Lt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){jt(e);return}n=n==null?``:``+Ot(n),t=t==null?n:``+Ot(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),jt(e)}function Rt(e,t,n){t===`number`&&Nt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function zt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Ot(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Bt(e,t,n){if(t!=null&&(t=``+Ot(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Ot(n)}function Vt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(N(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=Ot(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),jt(e)}function Ht(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ut=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Wt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Ut.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Gt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Wt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Wt(e,o,t[o])}function Kt(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var qt=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),Jt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Yt(e){return Jt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Xt(){}var Zt=null;function Qt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var $t=null,en=null;function tn(e){var t=mt(e);if(t&&(e=t.stateNode)){var n=e[at]||null;a:switch(e=t.stateNode,t.type){case`input`:if(It(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Ft(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[at]||null;if(!a)throw Error(i(90));It(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Mt(r)}break a;case`textarea`:Bt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&zt(e,!!n.multiple,t,!1)}}}var nn=!1;function rn(e,t,n){if(nn)return e(t,n);nn=!0;try{return e(t)}finally{if(nn=!1,($t!==null||en!==null)&&(Ou(),$t&&(t=$t,e=en,en=$t=null,tn(t),e)))for(t=0;t<e.length;t++)tn(e[t])}}function an(e,t){var n=e.stateNode;if(n===null)return null;var r=n[at]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=e!==`button`&&e!==`input`&&e!==`select`&&e!==`textarea`),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var on=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),sn=!1;if(on)try{var cn={};Object.defineProperty(cn,"passive",{get:function(){sn=!0}}),window.addEventListener(`test`,cn,cn),window.removeEventListener(`test`,cn,cn)}catch{sn=!1}var ln=null,un=null,dn=null;function fn(){if(dn)return dn;var e,t=un,n=t.length,r,i=`value`in ln?ln.value:ln.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return dn=i.slice(e,1<r?1-r:void 0)}function pn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function mn(){return!0}function hn(){return!1}function gn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?mn:hn,this.isPropagationStopped=hn,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=mn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=mn)},persist:function(){},isPersistent:mn}),t}var _n={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},vn=gn(_n),yn=p({},_n,{view:0,detail:0}),bn=gn(yn),xn,Sn,Cn,wn=p({},yn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Fn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==Cn&&(Cn&&e.type===`mousemove`?(xn=e.screenX-Cn.screenX,Sn=e.screenY-Cn.screenY):Sn=xn=0,Cn=e),xn)},movementY:function(e){return`movementY`in e?e.movementY:Sn}}),Tn=gn(wn),En=gn(p({},wn,{dataTransfer:0})),Dn=gn(p({},yn,{relatedTarget:0})),On=gn(p({},_n,{animationName:0,elapsedTime:0,pseudoElement:0})),kn=gn(p({},_n,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),An=gn(p({},_n,{data:0})),jn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Mn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Nn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Nn[e])?!!t[e]:!1}function Fn(){return Pn}var In=gn(p({},yn,{key:function(e){if(e.key){var t=jn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=pn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Mn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Fn,charCode:function(e){return e.type===`keypress`?pn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?pn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Ln=gn(p({},wn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Rn=gn(p({},yn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Fn})),zn=gn(p({},_n,{propertyName:0,elapsedTime:0,pseudoElement:0})),Bn=gn(p({},wn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Hn=gn(p({},_n,{newState:0,oldState:0})),Un=[9,13,27,32],V=on&&`CompositionEvent`in window,Wn=null;on&&`documentMode`in document&&(Wn=document.documentMode);var Gn=on&&`TextEvent`in window&&!Wn,Kn=on&&(!V||Wn&&8<Wn&&11>=Wn),qn=` `,Jn=!1;function Yn(e,t){switch(e){case`keyup`:return Un.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Xn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Zn=!1;function Qn(e,t){switch(e){case`compositionend`:return Xn(t);case`keypress`:return t.which===32?(Jn=!0,qn):null;case`textInput`:return e=t.data,e===qn&&Jn?null:e;default:return null}}function $n(e,t){if(Zn)return e===`compositionend`||!V&&Yn(e,t)?(e=fn(),dn=un=ln=null,Zn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Kn&&t.locale!==`ko`?null:t.data;default:return null}}var er={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function tr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!er[e.type]:t===`textarea`}function nr(e,t,n,r){$t?en?en.push(r):en=[r]:$t=r,t=Id(t,`onChange`),0<t.length&&(n=new vn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var rr=null,ir=null;function ar(e){Od(e,0)}function or(e){if(Mt(ht(e)))return e}function sr(e,t){if(e===`change`)return t}var cr=!1;if(on){var lr;if(on){var ur=`oninput`in document;if(!ur){var dr=document.createElement(`div`);dr.setAttribute(`oninput`,`return;`),ur=typeof dr.oninput==`function`}lr=ur}else lr=!1;cr=lr&&(!document.documentMode||9<document.documentMode)}function fr(){rr&&(rr.detachEvent(`onpropertychange`,pr),ir=rr=null)}function pr(e){if(e.propertyName===`value`&&or(ir)){var t=[];nr(t,ir,e,Qt(e)),rn(ar,t)}}function mr(e,t,n){e===`focusin`?(fr(),rr=t,ir=n,rr.attachEvent(`onpropertychange`,pr)):e===`focusout`&&fr()}function hr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return or(ir)}function gr(e,t){if(e===`click`)return or(t)}function _r(e,t){if(e===`input`||e===`change`)return or(t)}function vr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var yr=typeof Object.is==`function`?Object.is:vr;function br(e,t){if(yr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!ye.call(t,i)||!yr(e[i],t[i]))return!1}return!0}function xr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Sr(e,t){var n=xr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=xr(n)}}function Cr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Cr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function wr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Nt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Nt(e.document)}return t}function Tr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Er=on&&`documentMode`in document&&11>=document.documentMode,Dr=null,Or=null,kr=null,Ar=!1;function jr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ar||Dr==null||Dr!==Nt(r)||(r=Dr,`selectionStart`in r&&Tr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),kr&&br(kr,r)||(kr=r,r=Id(Or,`onSelect`),0<r.length&&(t=new vn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Dr)))}function Mr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Nr={animationend:Mr(`Animation`,`AnimationEnd`),animationiteration:Mr(`Animation`,`AnimationIteration`),animationstart:Mr(`Animation`,`AnimationStart`),transitionrun:Mr(`Transition`,`TransitionRun`),transitionstart:Mr(`Transition`,`TransitionStart`),transitioncancel:Mr(`Transition`,`TransitionCancel`),transitionend:Mr(`Transition`,`TransitionEnd`)},Pr={},Fr={};on&&(Fr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Nr.animationend.animation,delete Nr.animationiteration.animation,delete Nr.animationstart.animation),`TransitionEvent`in window||delete Nr.transitionend.transition);function Ir(e){if(Pr[e])return Pr[e];if(!Nr[e])return e;var t=Nr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Fr)return Pr[e]=t[n];return e}var Lr=Ir(`animationend`),Rr=Ir(`animationiteration`),zr=Ir(`animationstart`),Br=Ir(`transitionrun`),Vr=Ir(`transitionstart`),Hr=Ir(`transitioncancel`),Ur=Ir(`transitionend`),Wr=new Map,Gr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Gr.push(`scrollEnd`);function Kr(e,t){Wr.set(e,t),bt(t,[e])}var qr=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Jr=[],Yr=0,Xr=0;function Zr(){for(var e=Yr,t=Xr=Yr=0;t<e;){var n=Jr[t];Jr[t++]=null;var r=Jr[t];Jr[t++]=null;var i=Jr[t];Jr[t++]=null;var a=Jr[t];if(Jr[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&ti(n,i,a)}}function Qr(e,t,n,r){Jr[Yr++]=e,Jr[Yr++]=t,Jr[Yr++]=n,Jr[Yr++]=r,Xr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function $r(e,t,n,r){return Qr(e,t,n,r),ni(e)}function ei(e,t){return Qr(e,null,null,t),ni(e)}function ti(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Fe(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function ni(e){if(50<yu)throw yu=0,bu=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ri={};function ii(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ai(e,t,n,r){return new ii(e,t,n,r)}function oi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function si(e,t){var n=e.alternate;return n===null?(n=ai(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ci(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function li(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)oi(e)&&(s=1);else if(typeof e==`string`)s=ep(e,n,ae.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case O:return e=ai(31,n,t,a),e.elementType=O,e.lanes=o,e;case v:return ui(n.children,a,o,t);case y:s=8,a|=24;break;case b:return e=ai(12,n,t,a|2),e.elementType=b,e.lanes=o,e;case w:return e=ai(13,n,t,a),e.elementType=w,e.lanes=o,e;case T:return e=ai(19,n,t,a),e.elementType=T,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case S:s=10;break a;case x:s=9;break a;case C:s=11;break a;case E:s=14;break a;case D:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=ai(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function ui(e,t,n,r){return e=ai(7,e,r,t),e.lanes=n,e}function di(e,t,n){return e=ai(6,e,null,t),e.lanes=n,e}function fi(e){var t=ai(18,null,null,0);return t.stateNode=e,t}function pi(e,t,n){return t=ai(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var mi=new WeakMap;function hi(e,t){if(typeof e==`object`&&e){var n=mi.get(e);return n===void 0?(t={value:e,source:t,stack:ve(t)},mi.set(e,t),t):n}return{value:e,source:t,stack:ve(t)}}var gi=[],_i=0,vi=null,yi=0,bi=[],xi=0,Si=null,Ci=1,wi=``;function Ti(e,t){gi[_i++]=yi,gi[_i++]=vi,vi=e,yi=t}function Ei(e,t,n){bi[xi++]=Ci,bi[xi++]=wi,bi[xi++]=Si,Si=e;var r=Ci;e=wi;var i=32-Fe(r)-1;r&=~(1<<i),n+=1;var a=32-Fe(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Ci=1<<32-Fe(t)+i|n<<i|r,wi=a+e}else Ci=1<<a|n<<i|r,wi=e}function Di(e){e.return!==null&&(Ti(e,1),Ei(e,1,0))}function Oi(e){for(;e===vi;)vi=gi[--_i],gi[_i]=null,yi=gi[--_i],gi[_i]=null;for(;e===Si;)Si=bi[--xi],bi[xi]=null,wi=bi[--xi],bi[xi]=null,Ci=bi[--xi],bi[xi]=null}function ki(e,t){bi[xi++]=Ci,bi[xi++]=wi,bi[xi++]=Si,Ci=t.id,wi=t.overflow,Si=e}var Ai=null,ji=null,Mi=!1,Ni=null,Pi=!1,Fi=Error(i(519));function Ii(e){throw Hi(hi(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Fi}function Li(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[it]=e,t[at]=r,n){case`dialog`:kd(`cancel`,t),kd(`close`,t);break;case`iframe`:case`object`:case`embed`:kd(`load`,t);break;case`video`:case`audio`:for(n=0;n<Ed.length;n++)kd(Ed[n],t);break;case`source`:kd(`error`,t);break;case`img`:case`image`:case`link`:kd(`error`,t),kd(`load`,t);break;case`details`:kd(`toggle`,t);break;case`input`:kd(`invalid`,t),Lt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:kd(`invalid`,t);break;case`textarea`:kd(`invalid`,t),Vt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Hd(t.textContent,n)?(r.popover!=null&&(kd(`beforetoggle`,t),kd(`toggle`,t)),r.onScroll!=null&&kd(`scroll`,t),r.onScrollEnd!=null&&kd(`scrollend`,t),r.onClick!=null&&(t.onclick=Xt),t=!0):t=!1,t||Ii(e,!0)}function Ri(e){for(Ai=e.return;Ai;)switch(Ai.tag){case 5:case 31:case 13:Pi=!1;return;case 27:case 3:Pi=!0;return;default:Ai=Ai.return}}function zi(e){if(e!==Ai)return!1;if(!Mi)return Ri(e),Mi=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||ef(e.type,e.memoizedProps)),n=!n),n&&ji&&Ii(e),Ri(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ji=xf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ji=xf(e)}else t===27?(t=ji,lf(e.type)?(e=bf,bf=null,ji=e):ji=t):ji=Ai?yf(e.stateNode.nextSibling):null;return!0}function Bi(){ji=Ai=null,Mi=!1}function Vi(){var e=Ni;return e!==null&&(au===null?au=e:au.push.apply(au,e),Ni=null),e}function Hi(e){Ni===null?Ni=[e]:Ni.push(e)}var Ui=re(null),Wi=null,Gi=null;function Ki(e,t,n){L(Ui,t._currentValue),t._currentValue=n}function qi(e){e._currentValue=Ui.current,ie(Ui)}function Ji(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Yi(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Ji(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Ji(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function Xi(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;yr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===se.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[cp]:e.push(cp))}a=a.return}e!==null&&Yi(t,e,n,r),t.flags|=262144}function Zi(e){for(e=e.firstContext;e!==null;){if(!yr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Qi(e){Wi=e,Gi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function $i(e){return ta(Wi,e)}function ea(e,t){return Wi===null&&Qi(e),ta(e,t)}function ta(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Gi===null){if(e===null)throw Error(i(308));Gi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Gi=Gi.next=t;return n}var na=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},ra=t.unstable_scheduleCallback,ia=t.unstable_NormalPriority,aa={$$typeof:S,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function oa(){return{controller:new na,data:new Map,refCount:0}}function sa(e){e.refCount--,e.refCount===0&&ra(ia,function(){e.controller.abort()})}var ca=null,la=0,ua=0,da=null;function fa(e,t){if(ca===null){var n=ca=[];la=0,ua=bd(),da={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return la++,t.then(pa,pa),t}function pa(){if(--la===0&&ca!==null){da!==null&&(da.status=`fulfilled`);var e=ca;ca=null,ua=0,da=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ma(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ha=P.S;P.S=function(e,t){cu=Ce(),typeof t==`object`&&t&&typeof t.then==`function`&&fa(e,t),ha!==null&&ha(e,t)};var ga=re(null);function _a(){var e=ga.current;return e===null?Ul.pooledCache:e}function va(e,t){t===null?L(ga,ga.current):L(ga,t.pool)}function ya(){var e=_a();return e===null?null:{parent:aa._currentValue,pool:e}}var ba=Error(i(460)),xa=Error(i(474)),Sa=Error(i(542)),Ca={then:function(){}};function wa(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Ta(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Xt,Xt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,ka(e),e;default:if(typeof t.status==`string`)t.then(Xt,Xt);else{if(e=Ul,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,ka(e),e}throw Da=t,ba}}function Ea(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Da=e,ba):e}}var Da=null;function Oa(){if(Da===null)throw Error(i(459));var e=Da;return Da=null,e}function ka(e){if(e===ba||e===Sa)throw Error(i(483))}var Aa=null,ja=0;function Ma(e){var t=ja;return ja+=1,Aa===null&&(Aa=[]),Ta(Aa,e,t)}function Na(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Pa(e,t){throw t.$$typeof===m?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Fa(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=si(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=di(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===v?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===D&&Ea(i)===t.type)?(t=a(t,n.props),Na(t,n),t.return=e,t):(t=li(n.type,n.key,n.props,null,e.mode,r),Na(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=pi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=ui(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=di(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case h:return n=li(t.type,t.key,t.props,null,e.mode,n),Na(n,t),n.return=e,n;case g:return t=pi(t,e.mode,n),t.return=e,t;case D:return t=Ea(t),f(e,t,n)}if(N(t)||j(t))return t=ui(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ma(t),n);if(t.$$typeof===S)return f(e,ea(e,t),n);Pa(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case h:return n.key===i?l(e,t,n,r):null;case g:return n.key===i?u(e,t,n,r):null;case D:return n=Ea(n),p(e,t,n,r)}if(N(n)||j(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ma(n),r);if(n.$$typeof===S)return p(e,t,ea(e,n),r);Pa(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case h:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case g:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case D:return r=Ea(r),m(e,t,n,r,i)}if(N(r)||j(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Ma(r),i);if(r.$$typeof===S)return m(e,t,n,ea(t,r),i);Pa(t,r)}return null}function _(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),Mi&&Ti(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return Mi&&Ti(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),Mi&&Ti(i,h),l}function y(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),Mi&&Ti(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return Mi&&Ti(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),Mi&&Ti(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===v&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===v){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===D&&Ea(l)===r.type){n(e,r.sibling),c=a(r,o.props),Na(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===v?(c=ui(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=li(o.type,o.key,o.props,null,e.mode,c),Na(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=pi(o,e.mode,c),c.return=e,e=c}return s(e);case D:return o=Ea(o),b(e,r,o,c)}if(N(o))return _(e,r,o,c);if(j(o)){if(l=j(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Ma(o),c);if(o.$$typeof===S)return b(e,r,ea(e,o),c);Pa(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=di(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{ja=0;var i=b(e,t,n,r);return Aa=null,i}catch(t){if(t===ba||t===Sa)throw t;var a=ai(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ia=Fa(!0),La=Fa(!1),Ra=!1;function za(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ba(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Va(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ha(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Hl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ni(e),ti(e,null,n),t}return Qr(e,r,t,n),ni(e)}function Ua(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}function Wa(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ga=!1;function Ka(){if(Ga){var e=da;if(e!==null)throw e}}function qa(e,t,n,r){Ga=!1;var i=e.updateQueue;Ra=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,m=f!==s.lane;if(m?(Gl&f)===f:(r&f)===f){f!==0&&f===ua&&(Ga=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=p({},d,f);break a;case 2:Ra=!0}}f=s.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[f]:m.push(f))}else m={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),$l|=o,e.lanes=o,e.memoizedState=d}}function Ja(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function Ya(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ja(n[e],t)}var Xa=re(null),Za=re(0);function Qa(e,t){e=Zl,L(Za,e),L(Xa,t),Zl=e|t.baseLanes}function H(){L(Za,Zl),L(Xa,Xa.current)}function $a(){Zl=Za.current,ie(Xa),ie(Za)}var eo=re(null),to=null;function no(e){var t=e.alternate;L(so,so.current&1),L(eo,e),to===null&&(t===null||Xa.current!==null||t.memoizedState!==null)&&(to=e)}function ro(e){L(so,so.current),L(eo,e),to===null&&(to=e)}function io(e){e.tag===22?(L(so,so.current),L(eo,e),to===null&&(to=e)):ao(e)}function ao(){L(so,so.current),L(eo,eo.current)}function oo(e){ie(eo),to===e&&(to=null),ie(so)}var so=re(0);function co(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||gf(n)||_f(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var lo=0,uo=null,fo=null,po=null,mo=!1,ho=!1,go=!1,_o=0,vo=0,yo=null,bo=0;function xo(){throw Error(i(321))}function So(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!yr(e[n],t[n]))return!1;return!0}function Co(e,t,n,r,i,a){return lo=a,uo=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,P.H=e===null||e.memoizedState===null?Bs:Vs,go=!1,a=n(r,i),go=!1,ho&&(a=To(t,n,r,i)),wo(e),a}function wo(e){P.H=zs;var t=fo!==null&&fo.next!==null;if(lo=0,po=fo=uo=null,mo=!1,vo=0,yo=null,t)throw Error(i(300));e===null||ic||(e=e.dependencies,e!==null&&Zi(e)&&(ic=!0))}function To(e,t,n,r){uo=e;var a=0;do{if(ho&&(yo=null),vo=0,ho=!1,25<=a)throw Error(i(301));if(a+=1,po=fo=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}P.H=Hs,o=t(n,r)}while(ho);return o}function Eo(){var e=P.H,t=e.useState()[0];return t=typeof t.then==`function`?No(t):t,e=e.useState()[0],(fo===null?null:fo.memoizedState)!==e&&(uo.flags|=1024),t}function Do(){var e=_o!==0;return _o=0,e}function Oo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function ko(e){if(mo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}mo=!1}lo=0,po=fo=uo=null,ho=!1,vo=_o=0,yo=null}function Ao(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return po===null?uo.memoizedState=po=e:po=po.next=e,po}function jo(){if(fo===null){var e=uo.alternate;e=e===null?null:e.memoizedState}else e=fo.next;var t=po===null?uo.memoizedState:po.next;if(t!==null)po=t,fo=e;else{if(e===null)throw uo.alternate===null?Error(i(467)):Error(i(310));fo=e,e={memoizedState:fo.memoizedState,baseState:fo.baseState,baseQueue:fo.baseQueue,queue:fo.queue,next:null},po===null?uo.memoizedState=po=e:po=po.next=e}return po}function Mo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function No(e){var t=vo;return vo+=1,yo===null&&(yo=[]),e=Ta(yo,e,t),t=uo,(po===null?t.memoizedState:po.next)===null&&(t=t.alternate,P.H=t===null||t.memoizedState===null?Bs:Vs),e}function Po(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return No(e);if(e.$$typeof===S)return $i(e)}throw Error(i(438,String(e)))}function Fo(e){var t=null,n=uo.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=uo.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Mo(),uo.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=k;return t.index++,n}function Io(e,t){return typeof t==`function`?t(e):t}function Lo(e){return Ro(jo(),fo,e)}function Ro(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(lo&f)===f:(Gl&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ua&&(d=!0);else if((lo&p)===p){u=u.next,p===ua&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,uo.lanes|=p,$l|=p;f=u.action,go&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,uo.lanes|=f,$l|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!yr(o,e.memoizedState)&&(ic=!0,d&&(n=da,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function zo(e){var t=jo(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);yr(o,t.memoizedState)||(ic=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Bo(e,t,n){var r=uo,a=jo(),o=Mi;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!yr((fo||a).memoizedState,n);if(s&&(a.memoizedState=n,ic=!0),a=a.queue,ds(Uo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||po!==null&&po.memoizedState.tag&1){if(r.flags|=2048,os(9,{destroy:void 0},Ho.bind(null,r,a,n,t),null),Ul===null)throw Error(i(349));o||lo&127||Vo(r,t,n)}return n}function Vo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=uo.updateQueue,t===null?(t=Mo(),uo.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Ho(e,t,n,r){t.value=n,t.getSnapshot=r,Wo(t)&&Go(e)}function Uo(e,t,n){return n(function(){Wo(t)&&Go(e)})}function Wo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!yr(e,n)}catch{return!0}}function Go(e){var t=ei(e,2);t!==null&&Cu(t,e,2)}function Ko(e){var t=Ao();if(typeof e==`function`){var n=e;if(e=n(),go){Pe(!0);try{n()}finally{Pe(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Io,lastRenderedState:e},t}function qo(e,t,n,r){return e.baseState=n,Ro(e,fo,typeof r==`function`?r:Io)}function Jo(e,t,n,r,a){if(Is(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};P.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Yo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Yo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=P.T,o={};P.T=o;try{var s=n(i,r),c=P.S;c!==null&&c(o,s),Xo(e,t,s)}catch(n){Qo(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),P.T=a}}else try{a=n(i,r),Xo(e,t,a)}catch(n){Qo(e,t,n)}}function Xo(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Zo(e,t,n)},function(n){return Qo(e,t,n)}):Zo(e,t,n)}function Zo(e,t,n){t.status=`fulfilled`,t.value=n,$o(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Yo(e,n)))}function Qo(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,$o(t),t=t.next;while(t!==r)}e.action=null}function $o(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function es(e,t){return t}function ts(e,t){if(Mi){var n=Ul.formState;if(n!==null){a:{var r=uo;if(Mi){if(ji){b:{for(var i=ji,a=Pi;i.nodeType!==8;){if(!a){i=null;break b}if(i=yf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){ji=yf(i.nextSibling),r=i.data===`F!`;break a}}Ii(r)}r=!1}r&&(t=n[0])}}return n=Ao(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:es,lastRenderedState:t},n.queue=r,n=Ns.bind(null,uo,r),r.dispatch=n,r=Ko(!1),a=Fs.bind(null,uo,!1,r.queue),r=Ao(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Jo.bind(null,uo,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function ns(e){return rs(jo(),fo,e)}function rs(e,t,n){if(t=Ro(e,t,es)[0],e=Lo(Io)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=No(t)}catch(e){throw e===ba?Sa:e}else r=t;t=jo();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(uo.flags|=2048,os(9,{destroy:void 0},is.bind(null,i,n),null)),[r,a,e]}function is(e,t){e.action=t}function as(e){var t=jo(),n=fo;if(n!==null)return rs(t,n,e);jo(),t=t.memoizedState,n=jo();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function os(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=uo.updateQueue,t===null&&(t=Mo(),uo.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ss(){return jo().memoizedState}function cs(e,t,n,r){var i=Ao();uo.flags|=e,i.memoizedState=os(1|t,{destroy:void 0},n,r===void 0?null:r)}function ls(e,t,n,r){var i=jo();r=r===void 0?null:r;var a=i.memoizedState.inst;fo!==null&&r!==null&&So(r,fo.memoizedState.deps)?i.memoizedState=os(t,a,n,r):(uo.flags|=e,i.memoizedState=os(1|t,a,n,r))}function us(e,t){cs(8390656,8,e,t)}function ds(e,t){ls(2048,8,e,t)}function fs(e){uo.flags|=4;var t=uo.updateQueue;if(t===null)t=Mo(),uo.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ps(e){var t=jo().memoizedState;return fs({ref:t,nextImpl:e}),function(){if(Hl&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function ms(e,t){return ls(4,2,e,t)}function hs(e,t){return ls(4,4,e,t)}function gs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function _s(e,t,n){n=n==null?null:n.concat([e]),ls(4,4,gs.bind(null,t,e),n)}function vs(){}function ys(e,t){var n=jo();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&So(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function bs(e,t){var n=jo();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&So(t,r[1]))return r[0];if(r=e(),go){Pe(!0);try{e()}finally{Pe(!1)}}return n.memoizedState=[r,t],r}function xs(e,t,n){return n===void 0||lo&1073741824&&!(Gl&261930)?e.memoizedState=t:(e.memoizedState=n,e=Su(),uo.lanes|=e,$l|=e,n)}function Ss(e,t,n,r){return yr(n,t)?n:Xa.current===null?!(lo&42)||lo&1073741824&&!(Gl&261930)?(ic=!0,e.memoizedState=n):(e=Su(),uo.lanes|=e,$l|=e,t):(e=xs(e,n,r),yr(e,t)||(ic=!0),e)}function Cs(e,t,n,r,i){var a=te.p;te.p=a!==0&&8>a?a:8;var o=P.T,s={};P.T=s,Fs(e,!1,t,n);try{var c=i(),l=P.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Ps(e,t,ma(c,r),xu(e)):Ps(e,t,r,xu(e))}catch(n){Ps(e,t,{then:function(){},status:`rejected`,reason:n},xu())}finally{te.p=a,o!==null&&s.types!==null&&(o.types=s.types),P.T=o}}function ws(){}function Ts(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=Es(e).queue;Cs(e,a,t,F,n===null?ws:function(){return Ds(e),n(r)})}function Es(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:F,baseState:F,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Io,lastRenderedState:F},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Io,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ds(e){var t=Es(e);t.next===null&&(t=e.alternate.memoizedState),Ps(e,t.next.queue,{},xu())}function Os(){return $i(cp)}function ks(){return jo().memoizedState}function As(){return jo().memoizedState}function js(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=xu();e=Va(n);var r=Ha(t,e,n);r!==null&&(Cu(r,t,n),Ua(r,t,n)),t={cache:oa()},e.payload=t;return}t=t.return}}function Ms(e,t,n){var r=xu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Is(e)?Ls(t,n):(n=$r(e,t,n,r),n!==null&&(Cu(n,e,r),Rs(n,t,r)))}function Ns(e,t,n){Ps(e,t,n,xu())}function Ps(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Is(e))Ls(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,yr(s,o))return Qr(e,t,i,0),Ul===null&&Zr(),!1}catch{}if(n=$r(e,t,i,r),n!==null)return Cu(n,e,r),Rs(n,t,r),!0}return!1}function Fs(e,t,n,r){if(r={lane:2,revertLane:bd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Is(e)){if(t)throw Error(i(479))}else t=$r(e,n,r,2),t!==null&&Cu(t,e,2)}function Is(e){var t=e.alternate;return e===uo||t!==null&&t===uo}function Ls(e,t){ho=mo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Rs(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}var zs={readContext:$i,use:Po,useCallback:xo,useContext:xo,useEffect:xo,useImperativeHandle:xo,useLayoutEffect:xo,useInsertionEffect:xo,useMemo:xo,useReducer:xo,useRef:xo,useState:xo,useDebugValue:xo,useDeferredValue:xo,useTransition:xo,useSyncExternalStore:xo,useId:xo,useHostTransitionStatus:xo,useFormState:xo,useActionState:xo,useOptimistic:xo,useMemoCache:xo,useCacheRefresh:xo};zs.useEffectEvent=xo;var Bs={readContext:$i,use:Po,useCallback:function(e,t){return Ao().memoizedState=[e,t===void 0?null:t],e},useContext:$i,useEffect:us,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),cs(4194308,4,gs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return cs(4194308,4,e,t)},useInsertionEffect:function(e,t){cs(4,2,e,t)},useMemo:function(e,t){var n=Ao();t=t===void 0?null:t;var r=e();if(go){Pe(!0);try{e()}finally{Pe(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Ao();if(n!==void 0){var i=n(t);if(go){Pe(!0);try{n(t)}finally{Pe(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ms.bind(null,uo,e),[r.memoizedState,e]},useRef:function(e){var t=Ao();return e={current:e},t.memoizedState=e},useState:function(e){e=Ko(e);var t=e.queue,n=Ns.bind(null,uo,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:vs,useDeferredValue:function(e,t){return xs(Ao(),e,t)},useTransition:function(){var e=Ko(!1);return e=Cs.bind(null,uo,e.queue,!0,!1),Ao().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=uo,a=Ao();if(Mi){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Ul===null)throw Error(i(349));Gl&127||Vo(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,us(Uo.bind(null,r,o,e),[e]),r.flags|=2048,os(9,{destroy:void 0},Ho.bind(null,r,o,n,t),null),n},useId:function(){var e=Ao(),t=Ul.identifierPrefix;if(Mi){var n=wi,r=Ci;n=(r&~(1<<32-Fe(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=_o++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=bo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Os,useFormState:ts,useActionState:ts,useOptimistic:function(e){var t=Ao();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Fs.bind(null,uo,!0,n),n.dispatch=t,[e,t]},useMemoCache:Fo,useCacheRefresh:function(){return Ao().memoizedState=js.bind(null,uo)},useEffectEvent:function(e){var t=Ao(),n={impl:e};return t.memoizedState=n,function(){if(Hl&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Vs={readContext:$i,use:Po,useCallback:ys,useContext:$i,useEffect:ds,useImperativeHandle:_s,useInsertionEffect:ms,useLayoutEffect:hs,useMemo:bs,useReducer:Lo,useRef:ss,useState:function(){return Lo(Io)},useDebugValue:vs,useDeferredValue:function(e,t){return Ss(jo(),fo.memoizedState,e,t)},useTransition:function(){var e=Lo(Io)[0],t=jo().memoizedState;return[typeof e==`boolean`?e:No(e),t]},useSyncExternalStore:Bo,useId:ks,useHostTransitionStatus:Os,useFormState:ns,useActionState:ns,useOptimistic:function(e,t){return qo(jo(),fo,e,t)},useMemoCache:Fo,useCacheRefresh:As};Vs.useEffectEvent=ps;var Hs={readContext:$i,use:Po,useCallback:ys,useContext:$i,useEffect:ds,useImperativeHandle:_s,useInsertionEffect:ms,useLayoutEffect:hs,useMemo:bs,useReducer:zo,useRef:ss,useState:function(){return zo(Io)},useDebugValue:vs,useDeferredValue:function(e,t){var n=jo();return fo===null?xs(n,e,t):Ss(n,fo.memoizedState,e,t)},useTransition:function(){var e=zo(Io)[0],t=jo().memoizedState;return[typeof e==`boolean`?e:No(e),t]},useSyncExternalStore:Bo,useId:ks,useHostTransitionStatus:Os,useFormState:as,useActionState:as,useOptimistic:function(e,t){var n=jo();return fo===null?(n.baseState=e,[e,n.queue.dispatch]):qo(n,fo,e,t)},useMemoCache:Fo,useCacheRefresh:As};Hs.useEffectEvent=ps;function Us(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:p({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ws={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=xu(),i=Va(r);i.payload=t,n!=null&&(i.callback=n),t=Ha(e,i,r),t!==null&&(Cu(t,e,r),Ua(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=xu(),i=Va(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ha(e,i,r),t!==null&&(Cu(t,e,r),Ua(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=xu(),r=Va(n);r.tag=2,t!=null&&(r.callback=t),t=Ha(e,r,n),t!==null&&(Cu(t,e,n),Ua(t,e,n))}};function Gs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!br(n,r)||!br(i,a):!0}function Ks(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Ws.enqueueReplaceState(t,t.state,null)}function qs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=p({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Js(e){qr(e)}function Ys(e){console.error(e)}function Xs(e){qr(e)}function Zs(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Qs(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function $s(e,t,n){return n=Va(n),n.tag=3,n.payload={element:null},n.callback=function(){Zs(e,t)},n}function ec(e){return e=Va(e),e.tag=3,e}function tc(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Qs(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Qs(t,n,r),typeof i!=`function`&&(du===null?du=new Set([this]):du.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function nc(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Xi(t,n,a,!0),n=eo.current,n!==null){switch(n.tag){case 31:case 13:return to===null?Fu():n.alternate===null&&Ql===0&&(Ql=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Ca?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),ed(e,r,a)),!1;case 22:return n.flags|=65536,r===Ca?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),ed(e,r,a)),!1}throw Error(i(435,n.tag))}return ed(e,r,a),Fu(),!1}if(Mi)return t=eo.current,t===null?(r!==Fi&&(t=Error(i(423),{cause:r}),Hi(hi(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=hi(r,n),a=$s(e.stateNode,r,a),Wa(e,a),Ql!==4&&(Ql=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Fi&&(e=Error(i(422),{cause:r}),Hi(hi(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=hi(o,n),iu===null?iu=[o]:iu.push(o),Ql!==4&&(Ql=2),t===null)return!0;r=hi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=$s(n.stateNode,r,e),Wa(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(du===null||!du.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=ec(a),tc(a,e,n,r),Wa(n,a),!1}n=n.return}while(n!==null);return!1}var rc=Error(i(461)),ic=!1;function ac(e,t,n,r){t.child=e===null?La(t,null,n,r):Ia(t,e.child,n,r)}function oc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Qi(t),r=Co(e,t,n,o,a,i),s=Do(),e!==null&&!ic?(Oo(e,t,i),Ac(e,t,i)):(Mi&&s&&Di(t),t.flags|=1,ac(e,t,r,i),t.child)}function sc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!oi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,cc(e,t,a,r,i)):(e=li(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!jc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?br:n,n(o,r)&&e.ref===t.ref)return Ac(e,t,i)}return t.flags|=1,e=si(a,r),e.ref=t.ref,e.return=t,t.child=e}function cc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(br(a,r)&&e.ref===t.ref){if(ic=!1,t.pendingProps=r=a,jc(e,i))e.flags&131072&&(ic=!0);else return t.lanes=e.lanes,Ac(e,t,i)}}return gc(e,t,n,r,i)}function lc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return dc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&va(t,a===null?null:a.cachePool),a===null?H():Qa(t,a),io(t);else return r=t.lanes=536870912,dc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&va(t,null),H(),ao(t)):(va(t,a.cachePool),Qa(t,a),ao(t),t.memoizedState=null);return ac(e,t,i,n),t.child}function uc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function dc(e,t,n,r,i){var a=_a();return a=a===null?null:{parent:aa._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&va(t,null),H(),io(t),e!==null&&Xi(e,t,r,!0),t.childLanes=i,null}function fc(e,t){return t=Tc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function pc(e,t,n){return Ia(t,e.child,null,n),e=fc(t,t.pendingProps),e.flags|=2,oo(t),t.memoizedState=null,e}function mc(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(Mi){if(r.mode===`hidden`)return e=fc(t,r),t.lanes=536870912,uc(null,e);if(ro(t),(e=ji)?(e=hf(e,Pi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Si===null?null:{id:Ci,overflow:wi},retryLane:536870912,hydrationErrors:null},n=fi(e),n.return=t,t.child=n,Ai=t,ji=null)):e=null,e===null)throw Ii(t);return t.lanes=536870912,null}return fc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(ro(t),a){if(t.flags&256)t.flags&=-257,t=pc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(ic||Xi(e,t,n,!1),a=(n&e.childLanes)!==0,ic||a){if(r=Ul,r!==null&&(s=Qe(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,ei(e,s),Cu(r,e,s),rc;Fu(),t=pc(e,t,n)}else e=o.treeContext,ji=yf(s.nextSibling),Ai=t,Mi=!0,Ni=null,Pi=!1,e!==null&&ki(t,e),t=fc(t,r),t.flags|=4096;return t}return e=si(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function hc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function gc(e,t,n,r,i){return Qi(t),n=Co(e,t,n,r,void 0,i),r=Do(),e!==null&&!ic?(Oo(e,t,i),Ac(e,t,i)):(Mi&&r&&Di(t),t.flags|=1,ac(e,t,n,i),t.child)}function _c(e,t,n,r,i,a){return Qi(t),t.updateQueue=null,n=To(t,r,n,i),wo(e),r=Do(),e!==null&&!ic?(Oo(e,t,a),Ac(e,t,a)):(Mi&&r&&Di(t),t.flags|=1,ac(e,t,n,a),t.child)}function vc(e,t,n,r,i){if(Qi(t),t.stateNode===null){var a=ri,o=n.contextType;typeof o==`object`&&o&&(a=$i(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Ws,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},za(t),o=n.contextType,a.context=typeof o==`object`&&o?$i(o):ri,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Us(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Ws.enqueueReplaceState(a,a.state,null),qa(t,r,a,i),Ka(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=qs(n,s);a.props=c;var l=a.context,u=n.contextType;o=ri,typeof u==`object`&&u&&(o=$i(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Ks(t,a,r,o),Ra=!1;var f=t.memoizedState;a.state=f,qa(t,r,a,i),Ka(),l=t.memoizedState,s||f!==l||Ra?(typeof d==`function`&&(Us(t,n,d,r),l=t.memoizedState),(c=Ra||Gs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Ba(e,t),o=t.memoizedProps,u=qs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ri,typeof l==`object`&&l&&(c=$i(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Ks(t,a,r,c),Ra=!1,f=t.memoizedState,a.state=f,qa(t,r,a,i),Ka();var p=t.memoizedState;o!==d||f!==p||Ra||e!==null&&e.dependencies!==null&&Zi(e.dependencies)?(typeof s==`function`&&(Us(t,n,s,r),p=t.memoizedState),(u=Ra||Gs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Zi(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,hc(e,t),r=!!(t.flags&128),a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Ia(t,e.child,null,i),t.child=Ia(t,null,n,i)):ac(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Ac(e,t,i),e}function yc(e,t,n,r){return Bi(),t.flags|=256,ac(e,t,n,r),t.child}var bc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function xc(e){return{baseLanes:e,cachePool:ya()}}function Sc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=nu),e}function Cc(e,t,n){var r=t.pendingProps,a=!1,o=!!(t.flags&128),s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:!!(so.current&2)),s&&(a=!0,t.flags&=-129),s=!!(t.flags&32),t.flags&=-33,e===null){if(Mi){if(a?no(t):ao(t),(e=ji)?(e=hf(e,Pi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Si===null?null:{id:Ci,overflow:wi},retryLane:536870912,hydrationErrors:null},n=fi(e),n.return=t,t.child=n,Ai=t,ji=null)):e=null,e===null)throw Ii(t);return _f(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(ao(t),a=t.mode,c=Tc({mode:`hidden`,children:c},a),r=ui(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=xc(n),r.childLanes=Sc(e,s,n),t.memoizedState=bc,uc(null,r)):(no(t),wc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(no(t),t.flags&=-257,t=Ec(e,t,n)):t.memoizedState===null?(ao(t),c=r.fallback,a=t.mode,r=Tc({mode:`visible`,children:r.children},a),c=ui(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Ia(t,e.child,null,n),r=t.child,r.memoizedState=xc(n),r.childLanes=Sc(e,s,n),t.memoizedState=bc,t=uc(null,r)):(ao(t),t.child=e.child,t.flags|=128,t=null);else if(no(t),_f(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Hi({value:r,source:null,stack:null}),t=Ec(e,t,n)}else if(ic||Xi(e,t,n,!1),s=(n&e.childLanes)!==0,ic||s){if(s=Ul,s!==null&&(r=Qe(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,ei(e,r),Cu(s,e,r),rc;gf(c)||Fu(),t=Ec(e,t,n)}else gf(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,ji=yf(c.nextSibling),Ai=t,Mi=!0,Ni=null,Pi=!1,e!==null&&ki(t,e),t=wc(t,r.children),t.flags|=4096);return t}return a?(ao(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=si(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ui(c,a,n,null),c.flags|=2):c=si(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,uc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=xc(n):(a=c.cachePool,a===null?a=ya():(l=aa._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=Sc(e,s,n),t.memoizedState=bc,uc(e.child,r)):(no(t),n=e.child,e=n.sibling,n=si(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function wc(e,t){return t=Tc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function Tc(e,t){return e=ai(22,e,null,t),e.lanes=0,e}function Ec(e,t,n){return Ia(t,e.child,null,n),e=wc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Dc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ji(e.return,t,n)}function Oc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function kc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=so.current,s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,L(so,o),ac(e,t,r,n),r=Mi?yi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Dc(e,n,t);else if(e.tag===19)Dc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&co(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Oc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&co(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Oc(t,!0,n,null,a,r);break;case`together`:Oc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Ac(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),$l|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(Xi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null}if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=si(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=si(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function jc(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&Zi(e)))}function Mc(e,t,n){switch(t.tag){case 3:ce(t,t.stateNode.containerInfo),Ki(t,aa,e.memoizedState.cache),Bi();break;case 27:case 5:ue(t);break;case 4:ce(t,t.stateNode.containerInfo);break;case 10:Ki(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,ro(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(no(t),e=Ac(e,t,n),e===null?null:e.sibling):Cc(e,t,n):(no(t),t.flags|=128,null);no(t);break;case 19:var i=!!(e.flags&128);if(r=(n&t.childLanes)!==0,r||=(Xi(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return kc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),L(so,so.current),r)break;return null;case 22:return t.lanes=0,lc(e,t,n,t.pendingProps);case 24:Ki(t,aa,e.memoizedState.cache)}return Ac(e,t,n)}function Nc(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)ic=!0;else{if(!jc(e,n)&&!(t.flags&128))return ic=!1,Mc(e,t,n);ic=!!(e.flags&131072)}}else ic=!1,Mi&&t.flags&1048576&&Ei(t,yi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=Ea(t.elementType),t.type=e,typeof e==`function`)oi(e)?(r=qs(e,r),t.tag=1,t=vc(null,t,e,r,n)):(t.tag=0,t=gc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===C){t.tag=11,t=oc(null,t,e,r,n);break a}if(a===E){t.tag=14,t=sc(null,t,e,r,n);break a}}throw t=M(e)||e,Error(i(306,t,``))}}return t;case 0:return gc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=qs(r,t.pendingProps),vc(e,t,r,a,n);case 3:a:{if(ce(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Ba(e,t),qa(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Ki(t,aa,r),r!==o.cache&&Yi(t,[aa],n,!0),Ka(),r=s.element,o.isDehydrated){if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=yc(e,t,r,n);break a}if(r!==a){a=hi(Error(i(424)),t),Hi(a),t=yc(e,t,r,n);break a}switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(ji=yf(e.firstChild),Ai=t,Mi=!0,Ni=null,Pi=!0,n=La(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Bi(),r===a){t=Ac(e,t,n);break a}ac(e,t,r,n)}t=t.child}return t;case 26:return hc(e,t),e===null?(n=Bf(t.type,null,t.pendingProps,null))?t.memoizedState=n:Mi||(n=t.type,e=t.pendingProps,r=Zd(R.current).createElement(n),r[it]=t,r[at]=e,Gd(r,n,e),_t(r),t.stateNode=r):t.memoizedState=Bf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ue(t),e===null&&Mi&&(r=t.stateNode=Cf(t.type,t.pendingProps,R.current),Ai=t,Pi=!0,a=ji,lf(t.type)?(bf=a,ji=yf(r.firstChild)):ji=a),ac(e,t,t.pendingProps.children,n),hc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Mi&&((a=r=ji)&&(r=pf(r,t.type,t.pendingProps,Pi),r===null?a=!1:(t.stateNode=r,Ai=t,ji=yf(r.firstChild),Pi=!1,a=!0)),a||Ii(t)),ue(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,ef(a,o)?r=null:s!==null&&ef(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Co(e,t,Eo,null,null,n),cp._currentValue=a),hc(e,t),ac(e,t,r,n),t.child;case 6:return e===null&&Mi&&((e=n=ji)&&(n=mf(n,t.pendingProps,Pi),n===null?e=!1:(t.stateNode=n,Ai=t,ji=null,e=!0)),e||Ii(t)),null;case 13:return Cc(e,t,n);case 4:return ce(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ia(t,null,r,n):ac(e,t,r,n),t.child;case 11:return oc(e,t,t.type,t.pendingProps,n);case 7:return ac(e,t,t.pendingProps,n),t.child;case 8:return ac(e,t,t.pendingProps.children,n),t.child;case 12:return ac(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Ki(t,t.type,r.value),ac(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,Qi(t),a=$i(a),r=r(a),t.flags|=1,ac(e,t,r,n),t.child;case 14:return sc(e,t,t.type,t.pendingProps,n);case 15:return cc(e,t,t.type,t.pendingProps,n);case 19:return kc(e,t,n);case 31:return mc(e,t,n);case 22:return lc(e,t,n,t.pendingProps);case 24:return Qi(t),r=$i(aa),e===null?(a=_a(),a===null&&(a=Ul,o=oa(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},za(t),Ki(t,aa,a)):((e.lanes&n)!==0&&(Ba(e,t),qa(t,null,null,n),Ka()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Ki(t,aa,r),r!==a.cache&&Yi(t,[aa],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Ki(t,aa,r))),ac(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Pc(e){e.flags|=4}function Fc(e,t,n,r,i){if((t=!!(e.mode&32))&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i){if(e.stateNode.complete)e.flags|=8192;else if(Mu())e.flags|=8192;else throw Da=Ca,xa}}else e.flags&=-16777217}function Ic(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!tp(t)){if(Mu())e.flags|=8192;else throw Da=Ca,xa}}function Lc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ke(),e.lanes|=t,ru|=t)}function Rc(e,t){if(!Mi)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function zc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Bc(e,t,n){var r=t.pendingProps;switch(Oi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return zc(t),null;case 1:return zc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),qi(aa),le(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(zi(t)?Pc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Vi())),zc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Pc(t),o===null?(zc(t),Fc(t,a,null,r,n)):(zc(t),Ic(t,o))):o?o===e.memoizedState?(zc(t),t.flags&=-16777217):(Pc(t),zc(t),Ic(t,o)):(e=e.memoizedProps,e!==r&&Pc(t),zc(t),Fc(t,a,e,r,n)),null;case 27:if(de(t),n=R.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Pc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return zc(t),null}e=ae.current,zi(t)?Li(t,e):(e=Cf(a,r,n),t.stateNode=e,Pc(t))}return zc(t),null;case 5:if(de(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Pc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return zc(t),null}if(o=ae.current,zi(t))Li(t,o);else{var s=Zd(R.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[it]=t,o[at]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Gd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Pc(t)}}return zc(t),Fc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Pc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=R.current,zi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Ai,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[it]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Hd(e.nodeValue,n)),e||Ii(t,!0)}else e=Zd(e).createTextNode(r),e[it]=t,t.stateNode=e}return zc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=zi(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[it]=t}else Bi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;zc(t),e=!1}else n=Vi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(oo(t),t):(oo(t),null);if(t.flags&128)throw Error(i(558))}return zc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=zi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[it]=t}else Bi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;zc(t),a=!1}else a=Vi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(oo(t),t):(oo(t),null)}return oo(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Lc(t,t.updateQueue),zc(t),null);case 4:return le(),e===null&&Md(t.stateNode.containerInfo),zc(t),null;case 10:return qi(t.type),zc(t),null;case 19:if(ie(so),r=t.memoizedState,r===null)return zc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Rc(r,!1);else{if(Ql!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=co(e),o!==null){for(t.flags|=128,Rc(r,!1),e=o.updateQueue,t.updateQueue=e,Lc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ci(n,e),n=n.sibling;return L(so,so.current&1|2),Mi&&Ti(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ce()>lu&&(t.flags|=128,a=!0,Rc(r,!1),t.lanes=4194304)}}else{if(!a){if(e=co(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Lc(t,e),Rc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!Mi)return zc(t),null}else 2*Ce()-r.renderingStartTime>lu&&n!==536870912&&(t.flags|=128,a=!0,Rc(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(zc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ce(),e.sibling=null,n=so.current,L(so,a?n&1|2:n&1),Mi&&Ti(t,r.treeForkCount),e);case 22:case 23:return oo(t),$a(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(zc(t),t.subtreeFlags&6&&(t.flags|=8192)):zc(t),n=t.updateQueue,n!==null&&Lc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&ie(ga),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),qi(aa),zc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Vc(e,t){switch(Oi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return qi(aa),le(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return de(t),null;case 31:if(t.memoizedState!==null){if(oo(t),t.alternate===null)throw Error(i(340));Bi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(oo(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Bi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ie(so),null;case 4:return le(),null;case 10:return qi(t.type),null;case 22:case 23:return oo(t),$a(),e!==null&&ie(ga),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return qi(aa),null;case 25:return null;default:return null}}function Hc(e,t){switch(Oi(t),t.tag){case 3:qi(aa),le();break;case 26:case 27:case 5:de(t);break;case 4:le();break;case 31:t.memoizedState!==null&&oo(t);break;case 13:oo(t);break;case 19:ie(so);break;case 10:qi(t.type);break;case 22:case 23:oo(t),$a(),e!==null&&ie(ga);break;case 24:qi(aa)}}function Uc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){$u(t,t.return,e)}}function Wc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){$u(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){$u(t,t.return,e)}}function Gc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ya(t,n)}catch(t){$u(e,e.return,t)}}}function Kc(e,t,n){n.props=qs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){$u(e,t,n)}}function qc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){$u(e,t,n)}}function Jc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){$u(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){$u(e,t,n)}else n.current=null}}function Yc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){$u(e,e.return,t)}}function Xc(e,t,n){try{var r=e.stateNode;Kd(r,e.type,n,t),r[at]=t}catch(t){$u(e,e.return,t)}}function Zc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&lf(e.type)||e.tag===4}function Qc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Zc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&lf(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function $c(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Xt));else if(r!==4&&(r===27&&lf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for($c(e,t,n),e=e.sibling;e!==null;)$c(e,t,n),e=e.sibling}function el(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&lf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(el(e,t,n),e=e.sibling;e!==null;)el(e,t,n),e=e.sibling}function tl(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Gd(t,r,n),t[it]=e,t[at]=n}catch(t){$u(e,e.return,t)}}var nl=!1,rl=!1,il=!1,al=typeof WeakSet==`function`?WeakSet:Set,ol=null;function sl(e,t){if(e=e.containerInfo,Yd=_p,e=wr(e),Tr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Xd={focusedElem:e,selectionRange:n},_p=!1,ol=t;ol!==null;)if(t=ol,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,ol=e;else for(;ol!==null;){switch(t=ol,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=qs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){$u(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ff(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ff(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,ol=e;break}ol=t.return}}function cl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:Cl(e,n),r&4&&Uc(5,n);break;case 1:if(Cl(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){$u(n,n.return,e)}else{var i=qs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){$u(n,n.return,e)}}}r&64&&Gc(n),r&512&&qc(n,n.return);break;case 3:if(Cl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Ya(e,t)}catch(e){$u(n,n.return,e)}}break;case 27:t===null&&r&4&&tl(n);case 26:case 5:Cl(e,n),t===null&&r&4&&Yc(n),r&512&&qc(n,n.return);break;case 12:Cl(e,n);break;case 31:Cl(e,n),r&4&&ml(e,n);break;case 13:Cl(e,n),r&4&&hl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=rd.bind(null,n),vf(e,n))));break;case 22:if(r=n.memoizedState!==null||nl,!r){t=t!==null&&t.memoizedState!==null||rl,i=nl;var a=rl;nl=r,(rl=t)&&!a?Tl(e,n,!!(n.subtreeFlags&8772)):Cl(e,n),nl=i,rl=a}break;case 30:break;default:Cl(e,n)}}function ll(e){var t=e.alternate;t!==null&&(e.alternate=null,ll(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&ft(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ul=null,dl=!1;function fl(e,t,n){for(n=n.child;n!==null;)pl(e,t,n),n=n.sibling}function pl(e,t,n){if(Ne&&typeof Ne.onCommitFiberUnmount==`function`)try{Ne.onCommitFiberUnmount(Me,n)}catch{}switch(n.tag){case 26:rl||Jc(n,t),fl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:rl||Jc(n,t);var r=ul,i=dl;lf(n.type)&&(ul=n.stateNode,dl=!1),fl(e,t,n),wf(n.stateNode),ul=r,dl=i;break;case 5:rl||Jc(n,t);case 6:if(r=ul,i=dl,ul=null,fl(e,t,n),ul=r,dl=i,ul!==null){if(dl)try{(ul.nodeType===9?ul.body:ul.nodeName===`HTML`?ul.ownerDocument.body:ul).removeChild(n.stateNode)}catch(e){$u(n,t,e)}else try{ul.removeChild(n.stateNode)}catch(e){$u(n,t,e)}}break;case 18:ul!==null&&(dl?(e=ul,uf(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Up(e)):uf(ul,n.stateNode));break;case 4:r=ul,i=dl,ul=n.stateNode.containerInfo,dl=!0,fl(e,t,n),ul=r,dl=i;break;case 0:case 11:case 14:case 15:Wc(2,n,t),rl||Wc(4,n,t),fl(e,t,n);break;case 1:rl||(Jc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Kc(n,t,r)),fl(e,t,n);break;case 21:fl(e,t,n);break;case 22:rl=(r=rl)||n.memoizedState!==null,fl(e,t,n),rl=r;break;default:fl(e,t,n)}}function ml(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Up(e)}catch(e){$u(t,t.return,e)}}}function hl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Up(e)}catch(e){$u(t,t.return,e)}}function gl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new al),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new al),t;default:throw Error(i(435,e.tag))}}function _l(e,t){var n=gl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=id.bind(null,e,t);t.then(r,r)}})}function vl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(lf(c.type)){ul=c.stateNode,dl=!1;break a}break;case 5:ul=c.stateNode,dl=!1;break a;case 3:case 4:ul=c.stateNode.containerInfo,dl=!0;break a}c=c.return}if(ul===null)throw Error(i(160));pl(o,s,a),ul=null,dl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)bl(t,e),t=t.sibling}var yl=null;function bl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:vl(t,e),xl(e),r&4&&(Wc(3,e,e.return),Uc(3,e),Wc(5,e,e.return));break;case 1:vl(t,e),xl(e),r&512&&(rl||n===null||Jc(n,n.return)),r&64&&nl&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=yl;if(vl(t,e),xl(e),r&512&&(rl||n===null||Jc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null){if(r===null){if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[dt]||o[it]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Gd(o,r,n),o[it]=e,_t(o),r=o;break a;case`link`:var s=Qf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Gd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Qf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Gd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[it]=e,_t(o),r=o}e.stateNode=r}else $f(a,e.type,e.stateNode)}else e.stateNode=qf(a,r,e.memoizedProps)}else o===r?r===null&&e.stateNode!==null&&Xc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?$f(a,e.type,e.stateNode):qf(a,r,e.memoizedProps))}break;case 27:vl(t,e),xl(e),r&512&&(rl||n===null||Jc(n,n.return)),n!==null&&r&4&&Xc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(vl(t,e),xl(e),r&512&&(rl||n===null||Jc(n,n.return)),e.flags&32){a=e.stateNode;try{Ht(a,``)}catch(t){$u(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,Xc(e,a,n===null?a:n.memoizedProps)),r&1024&&(il=!0);break;case 6:if(vl(t,e),xl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){$u(e,e.return,t)}}break;case 3:if(Zf=null,a=yl,yl=Df(t.containerInfo),vl(t,e),yl=a,xl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Up(t.containerInfo)}catch(t){$u(e,e.return,t)}il&&(il=!1,Sl(e));break;case 4:r=yl,yl=Df(e.stateNode.containerInfo),vl(t,e),xl(e),yl=r;break;case 12:vl(t,e),xl(e);break;case 31:vl(t,e),xl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,_l(e,r)));break;case 13:vl(t,e),xl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(su=Ce()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,_l(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=nl,d=rl;if(nl=u||a,rl=d||l,vl(t,e),rl=d,nl=u,xl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||nl||rl||wl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){$u(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){$u(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?df(m,!0):df(l.stateNode,!1)}catch(e){$u(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,_l(e,n))));break;case 19:vl(t,e),xl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,_l(e,r)));break;case 30:break;case 21:break;default:vl(t,e),xl(e)}}function xl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Zc(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;el(e,Qc(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Ht(o,``),n.flags&=-33),el(e,Qc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;$c(e,Qc(e),s);break;default:throw Error(i(161))}}catch(t){$u(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Sl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Sl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Cl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)cl(e,t.alternate,t),t=t.sibling}function wl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Wc(4,t,t.return),wl(t);break;case 1:Jc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Kc(t,t.return,n),wl(t);break;case 27:wf(t.stateNode);case 26:case 5:Jc(t,t.return),wl(t);break;case 22:t.memoizedState===null&&wl(t);break;case 30:wl(t);break;default:wl(t)}e=e.sibling}}function Tl(e,t,n){for(n&&=!!(t.subtreeFlags&8772),t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:Tl(i,a,n),Uc(4,a);break;case 1:if(Tl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){$u(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ja(c[i],s)}catch(e){$u(r,r.return,e)}}n&&o&64&&Gc(a),qc(a,a.return);break;case 27:tl(a);case 26:case 5:Tl(i,a,n),n&&r===null&&o&4&&Yc(a),qc(a,a.return);break;case 12:Tl(i,a,n);break;case 31:Tl(i,a,n),n&&o&4&&ml(i,a);break;case 13:Tl(i,a,n),n&&o&4&&hl(i,a);break;case 22:a.memoizedState===null&&Tl(i,a,n),qc(a,a.return);break;case 30:break;default:Tl(i,a,n)}t=t.sibling}}function El(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&sa(n))}function Dl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&sa(e))}function Ol(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)kl(e,t,n,r),t=t.sibling}function kl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:Ol(e,t,n,r),i&2048&&Uc(9,t);break;case 1:Ol(e,t,n,r);break;case 3:Ol(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&sa(e)));break;case 12:if(i&2048){Ol(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){$u(t,t.return,e)}}else Ol(e,t,n,r);break;case 31:Ol(e,t,n,r);break;case 13:Ol(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?Ol(e,t,n,r):(a._visibility|=2,Al(e,t,n,r,!!(t.subtreeFlags&10256)||!1)):a._visibility&2?Ol(e,t,n,r):jl(e,t),i&2048&&El(o,t);break;case 24:Ol(e,t,n,r),i&2048&&Dl(t.alternate,t);break;default:Ol(e,t,n,r)}}function Al(e,t,n,r,i){for(i&&=!!(t.subtreeFlags&10256)||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Al(a,o,s,c,i),Uc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Al(a,o,s,c,i)):u._visibility&2?Al(a,o,s,c,i):jl(a,o),i&&l&2048&&El(o.alternate,o);break;case 24:Al(a,o,s,c,i),i&&l&2048&&Dl(o.alternate,o);break;default:Al(a,o,s,c,i)}t=t.sibling}}function jl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:jl(n,r),i&2048&&El(r.alternate,r);break;case 24:jl(n,r),i&2048&&Dl(r.alternate,r);break;default:jl(n,r)}t=t.sibling}}var Ml=8192;function Nl(e,t,n){if(e.subtreeFlags&Ml)for(e=e.child;e!==null;)Pl(e,t,n),e=e.sibling}function Pl(e,t,n){switch(e.tag){case 26:Nl(e,t,n),e.flags&Ml&&e.memoizedState!==null&&np(n,yl,e.memoizedState,e.memoizedProps);break;case 5:Nl(e,t,n);break;case 3:case 4:var r=yl;yl=Df(e.stateNode.containerInfo),Nl(e,t,n),yl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Ml,Ml=16777216,Nl(e,t,n),Ml=r):Nl(e,t,n));break;default:Nl(e,t,n)}}function Fl(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Il(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ol=r,zl(r,e)}Fl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Ll(e),e=e.sibling}function Ll(e){switch(e.tag){case 0:case 11:case 15:Il(e),e.flags&2048&&Wc(9,e,e.return);break;case 3:Il(e);break;case 12:Il(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Rl(e)):Il(e);break;default:Il(e)}}function Rl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ol=r,zl(r,e)}Fl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Wc(8,t,t.return),Rl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Rl(t));break;default:Rl(t)}e=e.sibling}}function zl(e,t){for(;ol!==null;){var n=ol;switch(n.tag){case 0:case 11:case 15:Wc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:sa(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,ol=r;else a:for(n=e;ol!==null;){r=ol;var i=r.sibling,a=r.return;if(ll(r),r===n){ol=null;break a}if(i!==null){i.return=a,ol=i;break a}ol=a}}}var Bl={getCacheForType:function(e){var t=$i(aa),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return $i(aa).controller.signal}},Vl=typeof WeakMap==`function`?WeakMap:Map,Hl=0,Ul=null,Wl=null,Gl=0,Kl=0,ql=null,Jl=!1,Yl=!1,Xl=!1,Zl=0,Ql=0,$l=0,eu=0,tu=0,nu=0,ru=0,iu=null,au=null,ou=!1,su=0,cu=0,lu=1/0,uu=null,du=null,fu=0,pu=null,mu=null,hu=0,gu=0,_u=null,vu=null,yu=0,bu=null;function xu(){return Hl&2&&Gl!==0?Gl&-Gl:P.T===null?tt():bd()}function Su(){if(nu===0){if(!(Gl&536870912)||Mi){var e=Be;Be<<=1,!(Be&3932160)&&(Be=262144),nu=e}else nu=536870912}return e=eo.current,e!==null&&(e.flags|=32),nu}function Cu(e,t,n){(e===Ul&&(Kl===2||Kl===9)||e.cancelPendingCommit!==null)&&(Au(e,0),Du(e,Gl,nu,!1)),Je(e,n),(!(Hl&2)||e!==Ul)&&(e===Ul&&(!(Hl&2)&&(eu|=n),Ql===4&&Du(e,Gl,nu,!1)),fd(e))}function wu(e,t,n){if(Hl&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||We(e,t),a=r?Ru(e,t):Iu(e,t,!0),o=r;do{if(a===0){Yl&&!r&&Du(e,t,0,!1);break}if(n=e.current.alternate,o&&!Eu(n)){a=Iu(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=iu;var l=c.current.memoizedState.isDehydrated;if(l&&(Au(c,s).flags|=256),s=Iu(c,s,!1),s!==2){if(Xl&&!l){c.errorRecoveryDisabledLanes|=o,eu|=o,a=4;break a}o=au,au=a,o!==null&&(au===null?au=o:au.push.apply(au,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Au(e,0),Du(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:Du(r,t,nu,!Jl);break a;case 2:au=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=su+300-Ce(),10<a)){if(Du(r,t,nu,!Jl),Ue(r,0,!0)!==0)break a;hu=t,r.timeoutHandle=rf(Tu.bind(null,r,n,au,uu,ou,t,nu,eu,ru,Jl,o,`Throttled`,-0,0),a);break a}Tu(r,n,au,uu,ou,t,nu,eu,ru,Jl,o,null,-0,0)}break}while(1);fd(e)}function Tu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Xt},Pl(t,a,d);var m=(a&62914560)===a?su-Ce():(a&4194048)===a?cu-Ce():0;if(m=ip(d,m),m!==null){hu=a,e.cancelPendingCommit=m(Gu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),Du(e,a,o,!l);return}}Gu(e,t,a,n,r,i,o,s,c)}function Eu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!yr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Du(e,t,n,r){t&=~tu,t&=~eu,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Fe(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Xe(e,n,t)}function Ou(){return Hl&6?!0:(pd(0,!1),!1)}function ku(){if(Wl!==null){if(Kl===0)var e=Wl.return;else e=Wl,Gi=Wi=null,ko(e),Aa=null,ja=0,e=Wl;for(;e!==null;)Hc(e.alternate,e),e=e.return;Wl=null}}function Au(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,af(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),hu=0,ku(),Ul=e,Wl=n=si(e.current,null),Gl=t,Kl=0,ql=null,Jl=!1,Yl=We(e,t),Xl=!1,ru=nu=tu=eu=$l=Ql=0,au=iu=null,ou=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Fe(r),a=1<<i;t|=e[i],r&=~a}return Zl=t,Zr(),n}function ju(e,t){uo=null,P.H=zs,t===ba||t===Sa?(t=Oa(),Kl=3):t===xa?(t=Oa(),Kl=4):Kl=t===rc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,ql=t,Wl===null&&(Ql=1,Zs(e,hi(t,e.current)))}function Mu(){var e=eo.current;return e===null?!0:(Gl&4194048)===Gl?to===null:(Gl&62914560)===Gl||Gl&536870912?e===to:!1}function Nu(){var e=P.H;return P.H=zs,e===null?zs:e}function Pu(){var e=P.A;return P.A=Bl,e}function Fu(){Ql=4,Jl||(Gl&4194048)!==Gl&&eo.current!==null||(Yl=!0),!($l&134217727)&&!(eu&134217727)||Ul===null||Du(Ul,Gl,nu,!1)}function Iu(e,t,n){var r=Hl;Hl|=2;var i=Nu(),a=Pu();(Ul!==e||Gl!==t)&&(uu=null,Au(e,t)),t=!1;var o=Ql;a:do try{if(Kl!==0&&Wl!==null){var s=Wl,c=ql;switch(Kl){case 8:ku(),o=6;break a;case 3:case 2:case 9:case 6:eo.current===null&&(t=!0);var l=Kl;if(Kl=0,ql=null,Hu(e,s,c,l),n&&Yl){o=0;break a}break;default:l=Kl,Kl=0,ql=null,Hu(e,s,c,l)}}Lu(),o=Ql;break}catch(t){ju(e,t)}while(1);return t&&e.shellSuspendCounter++,Gi=Wi=null,Hl=r,P.H=i,P.A=a,Wl===null&&(Ul=null,Gl=0,Zr()),o}function Lu(){for(;Wl!==null;)Bu(Wl)}function Ru(e,t){var n=Hl;Hl|=2;var r=Nu(),a=Pu();Ul!==e||Gl!==t?(uu=null,lu=Ce()+500,Au(e,t)):Yl=We(e,t);a:do try{if(Kl!==0&&Wl!==null){t=Wl;var o=ql;b:switch(Kl){case 1:Kl=0,ql=null,Hu(e,t,o,1);break;case 2:case 9:if(wa(o)){Kl=0,ql=null,Vu(t);break}t=function(){Kl!==2&&Kl!==9||Ul!==e||(Kl=7),fd(e)},o.then(t,t);break a;case 3:Kl=7;break a;case 4:Kl=5;break a;case 7:wa(o)?(Kl=0,ql=null,Vu(t)):(Kl=0,ql=null,Hu(e,t,o,7));break;case 5:var s=null;switch(Wl.tag){case 26:s=Wl.memoizedState;case 5:case 27:var c=Wl;if(s?tp(s):c.stateNode.complete){Kl=0,ql=null;var l=c.sibling;if(l!==null)Wl=l;else{var u=c.return;u===null?Wl=null:(Wl=u,Uu(u))}break b}}Kl=0,ql=null,Hu(e,t,o,5);break;case 6:Kl=0,ql=null,Hu(e,t,o,6);break;case 8:ku(),Ql=6;break a;default:throw Error(i(462))}}zu();break}catch(t){ju(e,t)}while(1);return Gi=Wi=null,P.H=r,P.A=a,Hl=n,Wl===null?(Ul=null,Gl=0,Zr(),Ql):0}function zu(){for(;Wl!==null&&!Se();)Bu(Wl)}function Bu(e){var t=Nc(e.alternate,e,Zl);e.memoizedProps=e.pendingProps,t===null?Uu(e):Wl=t}function Vu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=_c(n,t,t.pendingProps,t.type,void 0,Gl);break;case 11:t=_c(n,t,t.pendingProps,t.type.render,t.ref,Gl);break;case 5:ko(t);default:Hc(n,t),t=Wl=ci(t,Zl),t=Nc(n,t,Zl)}e.memoizedProps=e.pendingProps,t===null?Uu(e):Wl=t}function Hu(e,t,n,r){Gi=Wi=null,ko(t),Aa=null,ja=0;var i=t.return;try{if(nc(e,i,t,n,Gl)){Ql=1,Zs(e,hi(n,e.current)),Wl=null;return}}catch(t){if(i!==null)throw Wl=i,t;Ql=1,Zs(e,hi(n,e.current)),Wl=null;return}t.flags&32768?(Mi||r===1?e=!0:Yl||Gl&536870912?e=!1:(Jl=e=!0,(r===2||r===9||r===3||r===6)&&(r=eo.current,r!==null&&r.tag===13&&(r.flags|=16384))),Wu(t,e)):Uu(t)}function Uu(e){var t=e;do{if(t.flags&32768){Wu(t,Jl);return}e=t.return;var n=Bc(t.alternate,t,Zl);if(n!==null){Wl=n;return}if(t=t.sibling,t!==null){Wl=t;return}Wl=t=e}while(t!==null);Ql===0&&(Ql=5)}function Wu(e,t){do{var n=Vc(e.alternate,e);if(n!==null){n.flags&=32767,Wl=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Wl=e;return}Wl=e=n}while(e!==null);Ql=6,Wl=null}function Gu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Xu();while(fu!==0);if(Hl&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=Xr,Ye(e,n,o,s,c,l),e===Ul&&(Wl=Ul=null,Gl=0),mu=t,pu=e,hu=n,gu=o,_u=a,vu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,ad(De,function(){return Zu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(t.flags&13878),t.subtreeFlags&13878||r){r=P.T,P.T=null,a=te.p,te.p=2,s=Hl,Hl|=4;try{sl(e,t,n)}finally{Hl=s,te.p=a,P.T=r}}fu=1,Ku(),qu(),Ju()}}function Ku(){if(fu===1){fu=0;var e=pu,t=mu,n=!!(t.flags&13878);if(t.subtreeFlags&13878||n){n=P.T,P.T=null;var r=te.p;te.p=2;var i=Hl;Hl|=4;try{bl(t,e);var a=Xd,o=wr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Cr(s.ownerDocument.documentElement,s)){if(c!==null&&Tr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=Sr(s,h),v=Sr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}_p=!!Yd,Xd=Yd=null}finally{Hl=i,te.p=r,P.T=n}}e.current=t,fu=2}}function qu(){if(fu===2){fu=0;var e=pu,t=mu,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=P.T,P.T=null;var r=te.p;te.p=2;var i=Hl;Hl|=4;try{cl(e,t.alternate,t)}finally{Hl=i,te.p=r,P.T=n}}fu=3}}function Ju(){if(fu===4||fu===3){fu=0,z();var e=pu,t=mu,n=hu,r=vu;t.subtreeFlags&10256||t.flags&10256?fu=5:(fu=0,mu=pu=null,Yu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(du=null),et(n),t=t.stateNode,Ne&&typeof Ne.onCommitFiberRoot==`function`)try{Ne.onCommitFiberRoot(Me,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=P.T,i=te.p,te.p=2,P.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{P.T=t,te.p=i}}hu&3&&Xu(),fd(e),i=e.pendingLanes,n&261930&&i&42?e===bu?yu++:(yu=0,bu=e):yu=0,pd(0,!1)}}function Yu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,sa(t)))}function Xu(){return Ku(),qu(),Ju(),Zu()}function Zu(){if(fu!==5)return!1;var e=pu,t=gu;gu=0;var n=et(hu),r=P.T,a=te.p;try{te.p=32>n?32:n,P.T=null,n=_u,_u=null;var o=pu,s=hu;if(fu=0,mu=pu=null,hu=0,Hl&6)throw Error(i(331));var c=Hl;if(Hl|=4,Ll(o.current),kl(o,o.current,s,n),Hl=c,pd(0,!1),Ne&&typeof Ne.onPostCommitFiberRoot==`function`)try{Ne.onPostCommitFiberRoot(Me,o)}catch{}return!0}finally{te.p=a,P.T=r,Yu(e,t)}}function Qu(e,t,n){t=hi(n,t),t=$s(e.stateNode,t,2),e=Ha(e,t,2),e!==null&&(Je(e,2),fd(e))}function $u(e,t,n){if(e.tag===3)Qu(e,e,n);else for(;t!==null;){if(t.tag===3){Qu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(du===null||!du.has(r))){e=hi(n,e),n=ec(2),r=Ha(t,n,2),r!==null&&(tc(n,r,t,e),Je(r,2),fd(r));break}}t=t.return}}function ed(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Vl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Xl=!0,i.add(n),e=td.bind(null,e,t,n),t.then(e,e))}function td(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Ul===e&&(Gl&n)===n&&(Ql===4||Ql===3&&(Gl&62914560)===Gl&&300>Ce()-su?!(Hl&2)&&Au(e,0):tu|=n,ru===Gl&&(ru=0)),fd(e)}function nd(e,t){t===0&&(t=Ke()),e=ei(e,t),e!==null&&(Je(e,t),fd(e))}function rd(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),nd(e,n)}function id(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),nd(e,n)}function ad(e,t){return be(e,t)}var od=null,sd=null,cd=!1,ld=!1,ud=!1,dd=0;function fd(e){e!==sd&&e.next===null&&(sd===null?od=sd=e:sd=sd.next=e),ld=!0,cd||(cd=!0,yd())}function pd(e,t){if(!ud&&ld){ud=!0;do for(var n=!1,r=od;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Fe(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,vd(r,a))}else a=Gl,a=Ue(r,r===Ul?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,vd(r,a))}r=r.next}while(n);ud=!1}}function md(){hd()}function hd(){ld=cd=!1;var e=0;dd!==0&&nf()&&(e=dd);for(var t=Ce(),n=null,r=od;r!==null;){var i=r.next,a=gd(r,t);a===0?(r.next=null,n===null?od=i:n.next=i,i===null&&(sd=n)):(n=r,(e!==0||a&3)&&(ld=!0)),r=i}fu!==0&&fu!==5||pd(e,!1),dd!==0&&(dd=0)}function gd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Fe(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Ge(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Ul,n=Gl,n=Ue(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Kl===2||Kl===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&xe(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||We(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&xe(r),et(n)){case 2:case 8:n=Ee;break;case 32:n=De;break;case 268435456:n=ke;break;default:n=De}return r=_d.bind(null,e),n=be(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&xe(r),e.callbackPriority=2,e.callbackNode=null,2}function _d(e,t){if(fu!==0&&fu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Xu()&&e.callbackNode!==n)return null;var r=Gl;return r=Ue(e,e===Ul?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(wu(e,r,t),gd(e,Ce()),e.callbackNode!=null&&e.callbackNode===n?_d.bind(null,e):null)}function vd(e,t){if(Xu())return null;wu(e,t,!0)}function yd(){sf(function(){Hl&6?be(Te,md):hd()})}function bd(){if(dd===0){var e=ua;e===0&&(e=ze,ze<<=1,!(ze&261888)&&(ze=256)),dd=e}return dd}function xd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Yt(``+e)}function Sd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function Cd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=xd((i[at]||null).action),o=r.submitter;o&&(t=(t=o[at]||null)?xd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new vn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(dd!==0){var e=o?Sd(i,o):new FormData(i);Ts(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?Sd(i,o):new FormData(i),Ts(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var wd=0;wd<Gr.length;wd++){var Td=Gr[wd];Kr(Td.toLowerCase(),`on`+(Td[0].toUpperCase()+Td.slice(1)))}Kr(Lr,`onAnimationEnd`),Kr(Rr,`onAnimationIteration`),Kr(zr,`onAnimationStart`),Kr(`dblclick`,`onDoubleClick`),Kr(`focusin`,`onFocus`),Kr(`focusout`,`onBlur`),Kr(Br,`onTransitionRun`),Kr(Vr,`onTransitionStart`),Kr(Hr,`onTransitionCancel`),Kr(Ur,`onTransitionEnd`),xt(`onMouseEnter`,[`mouseout`,`mouseover`]),xt(`onMouseLeave`,[`mouseout`,`mouseover`]),xt(`onPointerEnter`,[`pointerout`,`pointerover`]),xt(`onPointerLeave`,[`pointerout`,`pointerover`]),bt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),bt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),bt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),bt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),bt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),bt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Ed=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),Dd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Ed));function Od(e,t){t=!!(t&4);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){qr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){qr(e)}i.currentTarget=null,a=c}}}}function kd(e,t){var n=t[st];n===void 0&&(n=t[st]=new Set);var r=e+`__bubble`;n.has(r)||(Nd(t,e,2,!1),n.add(r))}function Ad(e,t,n){var r=0;t&&(r|=4),Nd(n,e,r,t)}var jd=`_reactListening`+Math.random().toString(36).slice(2);function Md(e){if(!e[jd]){e[jd]=!0,vt.forEach(function(t){t!==`selectionchange`&&(Dd.has(t)||Ad(t,!1,e),Ad(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[jd]||(t[jd]=!0,Ad(`selectionchange`,!1,t))}}function Nd(e,t,n,r){switch(wp(t)){case 2:var i=vp;break;case 8:i=yp;break;default:i=bp}n=i.bind(null,t,n,e),i=void 0,!sn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Pd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var c=r.stateNode.containerInfo;if(c===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;c!==null;){if(o=pt(c),o===null)return;if(l=o.tag,l===5||l===6||l===26||l===27){r=a=o;continue a}c=c.parentNode}}r=r.return}rn(function(){var r=a,i=Qt(n),o=[];a:{var c=Wr.get(e);if(c!==void 0){var l=vn,u=e;switch(e){case`keypress`:if(pn(n)===0)break a;case`keydown`:case`keyup`:l=In;break;case`focusin`:u=`focus`,l=Dn;break;case`focusout`:u=`blur`,l=Dn;break;case`beforeblur`:case`afterblur`:l=Dn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=Tn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=En;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Rn;break;case Lr:case Rr:case zr:l=On;break;case Ur:l=zn;break;case`scroll`:case`scrollend`:l=bn;break;case`wheel`:l=Bn;break;case`copy`:case`cut`:case`paste`:l=kn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Ln;break;case`toggle`:case`beforetoggle`:l=Hn}var d=!!(t&4),f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=an(m,p),g!=null&&d.push(Fd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),o.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==Zt&&(u=n.relatedTarget||n.fromElement)&&(pt(u)||u[ot]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?pt(u):null,u!==null&&(f=s(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=Tn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Ln,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:ht(l),h=u==null?c:ht(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,pt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Ld,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Rd(o,c,l,d,!1),u!==null&&f!==null&&Rd(o,f,u,d,!0)}}a:{if(c=r?ht(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=sr;else if(tr(c)){if(cr)v=_r;else{v=hr;var y=mr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&Kt(r.elementType)&&(v=sr):v=gr;if(v&&=v(e,r)){nr(o,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Rt(c,`number`,c.value)}switch(y=r?ht(r):window,e){case`focusin`:(tr(y)||y.contentEditable===`true`)&&(Dr=y,Or=r,kr=null);break;case`focusout`:kr=Or=Dr=null;break;case`mousedown`:Ar=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Ar=!1,jr(o,n,i);break;case`selectionchange`:if(Er)break;case`keydown`:case`keyup`:jr(o,n,i)}var b;if(V)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else Zn?Yn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Kn&&n.locale!==`ko`&&(Zn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Zn&&(b=fn()):(ln=i,un=`value`in ln?ln.value:ln.textContent,Zn=!0)),y=Id(r,x),0<y.length&&(x=new An(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=Xn(n),b!==null&&(x.data=b)))),(b=Gn?Qn(e,n):$n(e,n))&&(x=Id(r,`onBeforeInput`),0<x.length&&(y=new An(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),Cd(o,e,r,n,i)}Od(o,t)})}function Fd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Id(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=an(e,n),i!=null&&r.unshift(Fd(e,i,a)),i=an(e,t),i!=null&&r.push(Fd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ld(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Rd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=an(n,a),l!=null&&o.unshift(Fd(n,l,c))):i||(l=an(n,a),l!=null&&o.push(Fd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var zd=/\r\n?/g,Bd=/\u0000|\uFFFD/g;function Vd(e){return(typeof e==`string`?e:``+e).replace(zd,`
|
|
10
|
+
`).replace(Bd,``)}function Hd(e,t){return t=Vd(t),Vd(e)===t}function Ud(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Ht(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Ht(e,``+r);break;case`className`:Et(e,`class`,r);break;case`tabIndex`:Et(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Et(e,n,r);break;case`style`:Gt(e,r,o);break;case`data`:if(t!==`object`){Et(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Yt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&Ud(e,t,`name`,a.name,a,null),Ud(e,t,`formEncType`,a.formEncType,a,null),Ud(e,t,`formMethod`,a.formMethod,a,null),Ud(e,t,`formTarget`,a.formTarget,a,null)):(Ud(e,t,`encType`,a.encType,a,null),Ud(e,t,`method`,a.method,a,null),Ud(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Yt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Xt);break;case`onScroll`:r!=null&&kd(`scroll`,e);break;case`onScrollEnd`:r!=null&&kd(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=Yt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:kd(`beforetoggle`,e),kd(`toggle`,e),Tt(e,`popover`,r);break;case`xlinkActuate`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Dt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Dt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Dt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Dt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Tt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=qt.get(n)||n,Tt(e,n,r))}}function Wd(e,t,n,r,a,o){switch(n){case`style`:Gt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Ht(e,r):(typeof r==`number`||typeof r==`bigint`)&&Ht(e,``+r);break;case`onScroll`:r!=null&&kd(`scroll`,e);break;case`onScrollEnd`:r!=null&&kd(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Xt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!yt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[at]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Tt(e,n,r)}}}function Gd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:kd(`error`,e),kd(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,o,s,n,null)}}a&&Ud(e,t,`srcSet`,n.srcSet,n,null),r&&Ud(e,t,`src`,n.src,n,null);return;case`input`:kd(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Ud(e,t,r,d,n,null)}}Lt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in kd(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Ud(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&zt(e,!!r,n,!0):zt(e,!!r,t,!1);return;case`textarea`:for(s in kd(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Ud(e,t,s,c,n,null)}Vt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Ud(e,t,l,r,n,null)}return;case`dialog`:kd(`beforetoggle`,e),kd(`toggle`,e),kd(`cancel`,e),kd(`close`,e);break;case`iframe`:case`object`:kd(`load`,e);break;case`video`:case`audio`:for(r=0;r<Ed.length;r++)kd(Ed[r],e);break;case`image`:kd(`error`,e),kd(`load`,e);break;case`details`:kd(`toggle`,e);break;case`embed`:case`source`:case`link`:kd(`error`,e),kd(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,u,r,n,null)}return;default:if(Kt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Wd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Ud(e,t,c,r,n,null))}function Kd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Ud(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Ud(e,t,p,m,r,f)}}It(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Ud(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Ud(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?zt(e,!!n,n?[]:``,!1):zt(e,!!n,t,!0)):zt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Ud(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Ud(e,t,s,a,r,o)}Bt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Ud(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Ud(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Ud(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Ud(e,t,u,p,r,m)}return;default:if(Kt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Wd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Wd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Ud(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Ud(e,t,f,p,r,m)}function qd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Jd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&qd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&qd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Yd=null,Xd=null;function Zd(e){return e.nodeType===9?e:e.ownerDocument}function Qd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function $d(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function ef(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var tf=null;function nf(){var e=window.event;return e&&e.type===`popstate`?e!==tf&&(tf=e,!0):(tf=null,!1)}var rf=typeof setTimeout==`function`?setTimeout:void 0,af=typeof clearTimeout==`function`?clearTimeout:void 0,of=typeof Promise==`function`?Promise:void 0,sf=typeof queueMicrotask==`function`?queueMicrotask:of===void 0?rf:function(e){return of.resolve(null).then(e).catch(cf)};function cf(e){setTimeout(function(){throw e})}function lf(e){return e===`head`}function uf(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Up(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)wf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,wf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[dt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&wf(e.ownerDocument.body)}n=i}while(n);Up(t)}function df(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function ff(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ff(n),ft(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function pf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[dt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=yf(e.nextSibling),e===null)break}return null}function mf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=yf(e.nextSibling),e===null))return null;return e}function hf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=yf(e.nextSibling),e===null))return null;return e}function gf(e){return e.data===`$?`||e.data===`$~`}function _f(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function vf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function yf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var bf=null;function xf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return yf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function Sf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function Cf(e,t,n){switch(t=Zd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function wf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);ft(e)}var Tf=new Map,Ef=new Set;function Df(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Of=te.d;te.d={f:kf,r:Af,D:Nf,C:Pf,L:Ff,m:If,X:Rf,S:Lf,M:zf};function kf(){var e=Of.f(),t=Ou();return e||t}function Af(e){var t=mt(e);t!==null&&t.tag===5&&t.type===`form`?Ds(t):Of.r(e)}var jf=typeof document>`u`?null:document;function Mf(e,t,n){var r=jf;if(r&&typeof t==`string`&&t){var i=Ft(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Ef.has(i)||(Ef.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Gd(t,`link`,e),_t(t),r.head.appendChild(t)))}}function Nf(e){Of.D(e),Mf(`dns-prefetch`,e,null)}function Pf(e,t){Of.C(e,t),Mf(`preconnect`,e,t)}function Ff(e,t,n){Of.L(e,t,n);var r=jf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ft(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ft(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ft(n.imageSizes)+`"]`)):i+=`[href="`+Ft(e)+`"]`;var a=i;switch(t){case`style`:a=Vf(e);break;case`script`:a=Gf(e)}Tf.has(a)||(e=p({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),Tf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Hf(a))||t===`script`&&r.querySelector(Kf(a))||(t=r.createElement(`link`),Gd(t,`link`,e),_t(t),r.head.appendChild(t)))}}function If(e,t){Of.m(e,t);var n=jf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ft(r)+`"][href="`+Ft(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Gf(e)}if(!Tf.has(a)&&(e=p({rel:`modulepreload`,href:e},t),Tf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Kf(a)))return}r=n.createElement(`link`),Gd(r,`link`,e),_t(r),n.head.appendChild(r)}}}function Lf(e,t,n){Of.S(e,t,n);var r=jf;if(r&&e){var i=gt(r).hoistableStyles,a=Vf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Hf(a)))s.loading=5;else{e=p({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=Tf.get(a))&&Yf(e,n);var c=o=r.createElement(`link`);_t(c),Gd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Jf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Rf(e,t){Of.X(e,t);var n=jf;if(n&&e){var r=gt(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=p({src:e,async:!0},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),_t(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function zf(e,t){Of.M(e,t);var n=jf;if(n&&e){var r=gt(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=p({src:e,async:!0,type:`module`},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),_t(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Bf(e,t,n,r){var a=(a=R.current)?Df(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Vf(n.href),n=gt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Vf(n.href);var o=gt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Hf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),Tf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Tf.set(e,n),o||Wf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Gf(n),n=gt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Vf(e){return`href="`+Ft(e)+`"`}function Hf(e){return`link[rel="stylesheet"][`+e+`]`}function Uf(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Wf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Gd(t,`link`,n),_t(t),e.head.appendChild(t))}function Gf(e){return`[src="`+Ft(e)+`"]`}function Kf(e){return`script[async]`+e}function qf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ft(n.href)+`"]`);if(r)return t.instance=r,_t(r),r;var a=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),_t(r),Gd(r,`style`,a),Jf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Vf(n.href);var o=e.querySelector(Hf(a));if(o)return t.state.loading|=4,t.instance=o,_t(o),o;r=Uf(n),(a=Tf.get(a))&&Yf(r,a),o=(e.ownerDocument||e).createElement(`link`),_t(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Gd(o,`link`,r),t.state.loading|=4,Jf(o,n.precedence,e),t.instance=o;case`script`:return o=Gf(n.src),(a=e.querySelector(Kf(o)))?(t.instance=a,_t(a),a):(r=n,(a=Tf.get(o))&&(r=p({},n),Xf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),_t(a),Gd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Jf(r,n.precedence,e));return t.instance}function Jf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Yf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Xf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Zf=null;function Qf(e,t,n){if(Zf===null){var r=new Map,i=Zf=new Map;i.set(n,r)}else i=Zf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[dt]||a[it]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function $f(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function ep(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function tp(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function np(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Vf(r.href),a=t.querySelector(Hf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=ap.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,_t(a);return}a=t.ownerDocument||t,r=Uf(r),(i=Tf.get(i))&&Yf(r,i),a=a.createElement(`link`),_t(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Gd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=ap.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var rp=0;function ip(e,t){return e.stylesheets&&e.count===0&&U(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&U(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&rp===0&&(rp=62500*Jd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&U(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>rp?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function ap(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)U(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var op=null;function U(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,op=new Map,t.forEach(sp,e),op=null,ap.call(e))}function sp(e,t){if(!(t.state.loading&4)){var n=op.get(e);if(n)var r=n.get(null);else{n=new Map,op.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=ap.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var cp={$$typeof:S,Provider:null,Consumer:null,_currentValue:F,_currentValue2:F,_threadCount:0};function lp(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=qe(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=qe(0),this.hiddenUpdates=qe(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function up(e,t,n,r,i,a,o,s,c,l,u,d){return e=new lp(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ai(3,null,null,t),e.current=a,a.stateNode=e,t=oa(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},za(a),e}function dp(e){return e?(e=ri,e):ri}function fp(e,t,n,r,i,a){i=dp(i),r.context===null?r.context=i:r.pendingContext=i,r=Va(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ha(e,r,t),n!==null&&(Cu(n,e,t),Ua(n,e,t))}function pp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function mp(e,t){pp(e,t),(e=e.alternate)&&pp(e,t)}function hp(e){if(e.tag===13||e.tag===31){var t=ei(e,67108864);t!==null&&Cu(t,e,67108864),mp(e,67108864)}}function gp(e){if(e.tag===13||e.tag===31){var t=xu();t=$e(t);var n=ei(e,t);n!==null&&Cu(n,e,t),mp(e,t)}}var _p=!0;function vp(e,t,n,r){var i=P.T;P.T=null;var a=te.p;try{te.p=2,bp(e,t,n,r)}finally{te.p=a,P.T=i}}function yp(e,t,n,r){var i=P.T;P.T=null;var a=te.p;try{te.p=8,bp(e,t,n,r)}finally{te.p=a,P.T=i}}function bp(e,t,n,r){if(_p){var i=xp(r);if(i===null)Pd(e,t,r,Sp,n),Np(e,r);else if(Fp(i,e,t,n,r))r.stopPropagation();else if(Np(e,r),t&4&&-1<Mp.indexOf(e)){for(;i!==null;){var a=mt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=He(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Fe(o);s.entanglements[1]|=c,o&=~c}fd(a),!(Hl&6)&&(lu=Ce()+500,pd(0,!1))}}break;case 31:case 13:s=ei(a,2),s!==null&&Cu(s,a,2),Ou(),mp(a,2)}if(a=xp(r),a===null&&Pd(e,t,r,Sp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Pd(e,t,r,null,n)}}function xp(e){return e=Qt(e),Cp(e)}var Sp=null;function Cp(e){if(Sp=null,e=pt(e),e!==null){var t=s(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=c(t),e!==null)return e;e=null}else if(n===31){if(e=l(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Sp=e,null}function wp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(we()){case Te:return 2;case Ee:return 8;case De:case Oe:return 32;case ke:return 268435456;default:return 32}default:return 32}}var Tp=!1,Ep=null,Dp=null,Op=null,kp=new Map,Ap=new Map,jp=[],Mp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Np(e,t){switch(e){case`focusin`:case`focusout`:Ep=null;break;case`dragenter`:case`dragleave`:Dp=null;break;case`mouseover`:case`mouseout`:Op=null;break;case`pointerover`:case`pointerout`:kp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:Ap.delete(t.pointerId)}}function Pp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=mt(t),t!==null&&hp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Fp(e,t,n,r,i){switch(t){case`focusin`:return Ep=Pp(Ep,e,t,n,r,i),!0;case`dragenter`:return Dp=Pp(Dp,e,t,n,r,i),!0;case`mouseover`:return Op=Pp(Op,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return kp.set(a,Pp(kp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,Ap.set(a,Pp(Ap.get(a)||null,e,t,n,r,i)),!0}return!1}function Ip(e){var t=pt(e.target);if(t!==null){var n=s(t);if(n!==null){if(t=n.tag,t===13){if(t=c(n),t!==null){e.blockedOn=t,nt(e.priority,function(){gp(n)});return}}else if(t===31){if(t=l(n),t!==null){e.blockedOn=t,nt(e.priority,function(){gp(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Lp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=xp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Zt=r,n.target.dispatchEvent(r),Zt=null}else return t=mt(n),t!==null&&hp(t),e.blockedOn=n,!1;t.shift()}return!0}function Rp(e,t,n){Lp(e)&&n.delete(t)}function zp(){Tp=!1,Ep!==null&&Lp(Ep)&&(Ep=null),Dp!==null&&Lp(Dp)&&(Dp=null),Op!==null&&Lp(Op)&&(Op=null),kp.forEach(Rp),Ap.forEach(Rp)}function Bp(e,n){e.blockedOn===n&&(e.blockedOn=null,Tp||(Tp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,zp)))}var Vp=null;function Hp(e){Vp!==e&&(Vp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Vp===e&&(Vp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(Cp(r||n)===null)continue;break}var a=mt(n);a!==null&&(e.splice(t,3),t-=3,Ts(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Up(e){function t(t){return Bp(t,e)}Ep!==null&&Bp(Ep,e),Dp!==null&&Bp(Dp,e),Op!==null&&Bp(Op,e),kp.forEach(t),Ap.forEach(t);for(var n=0;n<jp.length;n++){var r=jp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<jp.length&&(n=jp[0],n.blockedOn===null);)Ip(n),n.blockedOn===null&&jp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[at]||null;if(typeof a==`function`)o||Hp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[at]||null)s=o.formAction;else if(Cp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Hp(n)}}}function Wp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Gp(e){this._internalRoot=e}Kp.prototype.render=Gp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;fp(n,xu(),e,t,null,null)},Kp.prototype.unmount=Gp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;fp(e.current,2,null,e,null,null),Ou(),t[ot]=null}};function Kp(e){this._internalRoot=e}Kp.prototype.unstable_scheduleHydration=function(e){if(e){var t=tt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<jp.length&&t!==0&&t<jp[n].priority;n++);jp.splice(n,0,e),n===0&&Ip(e)}};var qp=n.version;if(qp!==`19.2.8`)throw Error(i(527,qp,`19.2.8`));te.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=d(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Jp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:P,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Yp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Yp.isDisabled&&Yp.supportsFiber)try{Me=Yp.inject(Jp),Ne=Yp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Js,s=Ys,c=Xs;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=up(e,1,!1,null,null,n,r,null,o,s,c,Wp),e[ot]=t.current,Md(e),new Gp(t)}})),Un=t(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Hn()})),V=e(_(),1),Wn=Un(),Gn=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Kn=/^[\\/]{2}/;function qn(e,t){return t+e.replace(/\\/g,`/`)}var Jn=`popstate`;function Yn(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function Xn(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return tr(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:nr(t)}return ir(t,n,null,e)}function Zn(e,t){if(e===!1||e==null)throw Error(t)}function Qn(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function $n(){return Math.random().toString(36).substring(2,10)}function er(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function tr(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?rr(t):t,state:n,key:t&&t.key||r||$n(),mask:i}}function nr({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function rr(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function ir(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=`POP`,c=null,l=u();l??(l=0,o.replaceState({...o.state,idx:l},``));function u(){return(o.state||{idx:null}).idx}function d(){s=`POP`;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=`PUSH`;let r=Yn(e)?e:tr(h.location,e,t);n&&n(r,e),l=u()+1;let d=er(r,l),f=h.createHref(r.mask||r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=`REPLACE`;let r=Yn(e)?e:tr(h.location,e,t);n&&n(r,e),l=u();let i=er(r,l),d=h.createHref(r.mask||r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){return ar(i,e)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(Jn,d),c=e,()=>{i.removeEventListener(Jn,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}function ar(e,t,n=!1){let r=`http://localhost`;e&&(r=e.location.origin===`null`?e.location.href:e.location.origin),Zn(r,`No window.location.(origin|href) available to create URL`);let i=typeof t==`string`?t:nr(t);return i=i.replace(/ $/,`%20`),!n&&Kn.test(i)&&(i=r+i),new URL(i,r)}function or(e,t,n=`/`){return sr(e,t,n,!1)}function sr(e,t,n,r,i){let a=Or((typeof t==`string`?rr(t):t).pathname||`/`,n);if(a==null)return null;let o=i??cr(e),s=null,c=Dr(a);for(let e=0;s==null&&e<o.length;++e)s=Cr(o[e],c,r);return s}function cr(e){let t=lr(e);return dr(t),t}function lr(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let c={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(c.relativePath.startsWith(`/`)){if(!c.relativePath.startsWith(r)&&o)return;Zn(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let l=Ir([r,c.relativePath]),u=n.concat(c);e.children&&e.children.length>0&&(Zn(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),lr(e.children,t,u,l,o)),(e.path!=null||e.index)&&t.push({path:l,score:xr(l,e.index),routesMeta:u.map((e,t)=>{let[n,r]=Er(e.relativePath,e.caseSensitive,t===u.length-1);return{...e,matcher:n,compiledParams:r}})})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of ur(e.path))a(e,t,!0,n)}),t}function ur(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=ur(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function dr(e){e.sort((e,t)=>e.score===t.score?Sr(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var fr=/^:[\w-]+$/,pr=/^:[\w-]+/,mr=3.5,hr=3,gr=2,_r=1,vr=10,yr=-2,br=e=>e===`*`;function xr(e,t){let n=e.split(`/`),r=n.length;return n.some(br)&&(r+=yr),t&&(r+=gr),n.filter(e=>!br(e)).reduce((e,t)=>e+(fr.test(t)?hr:pr.test(t)?mr:t===``?_r:vr),r)}function Sr(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function Cr(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},d=s.matcher&&s.compiledParams?Tr(u,l,s.matcher,s.compiledParams):wr(u,l),f=s.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=wr({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!d)return null;Object.assign(i,d.params),o.push({params:i,pathname:Ir([a,d.pathname]),pathnameBase:Rr(Ir([a,d.pathnameBase])),route:f}),d.pathnameBase!==`/`&&(a=Ir([a,d.pathnameBase]))}return o}function wr(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Er(e.path,e.caseSensitive,e.end);return Tr(e,t,n,r)}function Tr(e,t,n,r){let i=t.match(n);if(!i)return null;let a=i[0],o=Lr(a,1),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=Lr(a.slice(0,a.length-e.length),1)}let i=s[r];return e[t]=n&&!i?void 0:(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function Er(e,t=!1,n=!0){Qn(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,`/*`)}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,`/*`)}".`);let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(?=\/|$|\()/g,`(?:/$1)?`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function Dr(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return Qn(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function Or(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function kr(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?rr(e):e,a;return n?(n=Fr(n),a=n.startsWith(`/`)||n.startsWith(`\\`)?Ar(n.substring(1),`/`):Ar(n,t)):a=t,{pathname:a,search:zr(r),hash:Br(i)}}function Ar(e,t){let n=Lr(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function jr(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Mr(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function Nr(e){let t=Mr(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function Pr(e,t,n,r=!1){let i;typeof e==`string`?i=rr(e):(i={...e},Zn(!i.pathname||!i.pathname.includes(`?`),jr(`?`,`pathname`,`search`,i)),Zn(!i.pathname||!i.pathname.includes(`#`),jr(`#`,`pathname`,`hash`,i)),Zn(!i.search||!i.search.includes(`#`),jr(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=kr(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var Fr=e=>e.replace(/[\\/]{2,}/g,`/`),Ir=e=>Fr(e.join(`/`));function Lr(e,t=0){let n=e.length;for(;n>t&&e.charCodeAt(n-1)===47;)n--;return n===e.length?e:e.slice(0,n)}var Rr=e=>Lr(e).replace(/^\/*/,`/`),zr=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,Br=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,Vr=class{status;statusText;data;error;internal;constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Hr(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function Ur(e){return Ir(e.map(e=>e.route.path).filter(Boolean))||`/`}var Wr=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function Gr(e,t){let n=e;if(typeof n!=`string`||!Gn.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Wr)try{let e=new URL(window.location.href),r=Kn.test(n)?new URL(qn(n,e.protocol)):new URL(n),a=Or(r.pathname,t);r.origin===e.origin&&a!=null?n=a+r.search+r.hash:i=!0}catch{Qn(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}var Kr=new URL(`http://localhost`);function qr(e){if(e.createURL)return e.createURL(`/`);try{return new URL(e.createHref(`/`),Kr)}catch{return Kr}}function Jr(e,t){return e.origin===t.origin&&(e.origin!==`null`||e.protocol===t.protocol&&e.host===t.host)}function Yr(e,t){if(e.startsWith(`//`))return!0;let n=t.protocol.toLowerCase();return e.toLowerCase().startsWith(n)?t.host===``||e.slice(n.length).startsWith(`//`):!1}function Xr(e,t,n,r){let i=null;try{i=e==null?null:new URL(e,n)}catch{}let a=new URL(t,n),o=i!=null&&!Jr(i,n),s=!Jr(a,n);if(r===`reject`){if(o||s)throw Error(`External navigation is not allowed`)}else if(s&&(i==null||!Yr(e,i)||!Jr(i,a)))throw Error(`External navigation is not allowed`)}var Zr=[`POST`,`PUT`,`PATCH`,`DELETE`];new Set(Zr);var Qr=[`GET`,...Zr];new Set(Qr);var $r=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function ei(e){try{return $r.includes(new URL(e).protocol)}catch{return!1}}var ti=V.createContext(null);ti.displayName=`DataRouter`;var ni=V.createContext(null);ni.displayName=`DataRouterState`;var ri=V.createContext(!1);function ii(){return V.useContext(ri)}var ai=V.createContext({isTransitioning:!1});ai.displayName=`ViewTransition`;var oi=V.createContext(new Map);oi.displayName=`Fetchers`;var si=V.createContext(null);si.displayName=`Await`;var ci=V.createContext(null);ci.displayName=`Navigation`;var li=V.createContext(null);li.displayName=`Location`;var ui=V.createContext({outlet:null,matches:[],isDataRoute:!1});ui.displayName=`Route`;var di=V.createContext(null);di.displayName=`RouteError`;var fi=`REACT_ROUTER_ERROR`,pi=`REDIRECT`,mi=`ROUTE_ERROR_RESPONSE`;function hi(e){if(e.startsWith(`${fi}:${pi}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`&&typeof t.location==`string`&&typeof t.reloadDocument==`boolean`&&typeof t.replace==`boolean`)return t}catch{}}function gi(e){if(e.startsWith(`${fi}:${mi}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new Vr(t.status,t.statusText,t.data)}catch{}}function _i(e,{relative:t}={}){Zn(vi(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=V.useContext(ci),{hash:i,pathname:a,search:o}=wi(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:Ir([n,a])),r.createHref({pathname:s,search:o,hash:i})}function vi(){return V.useContext(li)!=null}function yi(){return Zn(vi(),`useLocation() may be used only in the context of a <Router> component.`),V.useContext(li).location}var bi=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function xi(){let{isDataRoute:e}=V.useContext(ui);return e?Vi():Si()}function Si(){Zn(vi(),`useNavigate() may be used only in the context of a <Router> component.`);let e=V.useContext(ti),{basename:t,navigator:n}=V.useContext(ci),{matches:r}=V.useContext(ui),{pathname:i}=yi(),a=JSON.stringify(Nr(r)),o=V.useRef(!1);return V.useLayoutEffect(()=>{o.current=!0}),V.useCallback((r,s={})=>{if(Qn(o.current,bi),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=Pr(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:Ir([t,c.pathname])),Xr(typeof r==`string`?r:nr(r),n.createHref(c),qr(n),`reject`),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}V.createContext(null);function Ci(){let{matches:e}=V.useContext(ui);return e[e.length-1]?.params??{}}function wi(e,{relative:t}={}){let{matches:n}=V.useContext(ui),{pathname:r}=yi(),i=JSON.stringify(Nr(n));return V.useMemo(()=>Pr(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function Ti(e,t){return Ei(e,t)}function Ei(e,t,n){Zn(vi(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=V.useContext(ci),{matches:i}=V.useContext(ui),a=i[i.length-1],o=a?a.params:{};a&&a.pathname;let s=a?a.pathnameBase:`/`;a&&a.route;let c=yi(),l;if(t){let e=typeof t==`string`?rr(t):t;Zn(s===`/`||e.pathname?.startsWith(s),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${s}" but pathname "${e.pathname}" was given in the \`location\` prop.`),l=e}else l=c;let u=l.pathname||`/`,d=u;if(s!==`/`){let e=s.replace(/^\//,``).split(`/`);d=`/`+u.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let f=n&&n.state.matches.length?n.state.matches.map(e=>Object.assign(e,{route:n.manifest[e.route.id]||e.route})):or(e,{pathname:d}),p=Ni(f&&f.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:Ir([s,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?s:Ir([s,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&p?V.createElement(li.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,mask:void 0,...l},navigationType:`POP`}},p):p}function Di(){let e=Bi(),t=Hr(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null;return V.createElement(V.Fragment,null,V.createElement(`h2`,null,`Unexpected Application Error!`),V.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?V.createElement(`pre`,{style:{padding:`0.5rem`,backgroundColor:`rgba(200,200,200, 0.5)`}},n):null,null)}var Oi=V.createElement(Di,null),ki=class extends V.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static contextType=ri;static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=gi(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:V.createElement(ui.Provider,{value:this.props.routeContext},V.createElement(di.Provider,{value:e,children:this.props.component}));return this.context?V.createElement(ji,{error:e},t):t}},Ai=new WeakMap;function ji({children:e,error:t}){let{basename:n,navigator:r}=V.useContext(ci);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=hi(t.digest);if(e){let i=Ai.get(t);if(i)throw i;let a=Gr(e.location,n),o=a.absoluteURL||a.to;if(Xr(e.location,o,qr(r),`allow-explicit`),ei(o))throw Error(`Invalid redirect location`);if(Wr&&!Ai.get(t)){if(a.isExternal||e.reloadDocument)window.location.href=o;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(a.to,{replace:e.replace}));throw Ai.set(t,n),n}}return V.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${o}`})}}return e}function Mi({routeContext:e,match:t,children:n}){let r=V.useContext(ti);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),V.createElement(ui.Provider,{value:e},n)}function Ni(e,t=[],n){let r=n?.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);Zn(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let c=n?.onError,l=r&&c?(e,t)=>{c(e,{location:r.location,params:r.matches?.[0]?.params??{},pattern:Ur(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let u,d=!1,f=null,p=null;r&&(u=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||Oi,o&&(s<0&&c===0?(Ui(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=u?f:d?p:n.route.Component?V.createElement(n.route.Component,null):n.route.element?n.route.element:e,V.createElement(Mi,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?V.createElement(ki,{location:r.location,revalidation:r.revalidation,component:f,error:u,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:l}):h()},null)}function Pi(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Fi(e){let t=V.useContext(ti);return Zn(t,Pi(e)),t}function Ii(e){let t=V.useContext(ni);return Zn(t,Pi(e)),t}function Li(e){let t=V.useContext(ui);return Zn(t,Pi(e)),t}function Ri(e){let t=Li(e),n=t.matches[t.matches.length-1];return Zn(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function zi(){return Ri(`useRouteId`)}function Bi(){let e=V.useContext(di),t=Ii(`useRouteError`),n=Ri(`useRouteError`);return e===void 0?t.errors?.[n]:e}function Vi(){let{router:e}=Fi(`useNavigate`),t=Ri(`useNavigate`),n=V.useRef(!1);return V.useLayoutEffect(()=>{n.current=!0}),V.useCallback(async(r,i={})=>{Qn(n.current,bi),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var Hi={};function Ui(e,t,n){!t&&!Hi[e]&&(Hi[e]=!0,Qn(!1,n))}V.memo(Wi);function Wi({routes:e,manifest:t,future:n,state:r,isStatic:i,onError:a}){return Ei(e,void 0,{manifest:t,state:r,isStatic:i,onError:a,future:n})}function Gi({to:e,replace:t,state:n,relative:r}){Zn(vi(),`<Navigate> may be used only in the context of a <Router> component.`);let{static:i,navigator:a}=V.useContext(ci);Qn(!i,`<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.`);let{matches:o}=V.useContext(ui),{pathname:s}=yi(),c=xi(),l=Pr(e,Nr(o),s,r===`path`);Xr(typeof e==`string`?e:nr(e),a.createHref(l),qr(a),`reject`);let u=JSON.stringify(l);return V.useEffect(()=>{c(JSON.parse(u),{replace:t,state:n,relative:r})},[c,u,r,t,n]),null}function Ki({basename:e=`/`,children:t=null,location:n,navigationType:r=`POP`,navigator:i,static:a=!1,useTransitions:o}){Zn(!vi(),`You cannot render a <Router> inside another <Router>. You should never have more than one in your app.`);let s=e.replace(/^\/*/,`/`),c=V.useMemo(()=>({basename:s,navigator:i,static:a,useTransitions:o,future:{}}),[s,i,a,o]);typeof n==`string`&&(n=rr(n));let{pathname:l=`/`,search:u=``,hash:d=``,state:f=null,key:p=`default`,mask:m}=n,h=V.useMemo(()=>{let e=Or(l,s);return e==null?null:{location:{pathname:e,search:u,hash:d,state:f,key:p,mask:m},navigationType:r}},[s,l,u,d,f,p,r,m]);return Qn(h!=null,`<Router basename="${s}"> is not able to match the URL "${l}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:V.createElement(ci.Provider,{value:c},V.createElement(li.Provider,{children:t,value:h}))}V.Component;var qi=`application/x-www-form-urlencoded`;function Ji(e){return typeof HTMLElement<`u`&&e instanceof HTMLElement}function Yi(e){return Ji(e)&&e.tagName.toLowerCase()===`button`}function Xi(e){return Ji(e)&&e.tagName.toLowerCase()===`form`}function Zi(e){return Ji(e)&&e.tagName.toLowerCase()===`input`}function Qi(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function $i(e,t){return e.button===0&&(!t||t===`_self`)&&!Qi(e)}function ea(e=``){return new URLSearchParams(typeof e==`string`||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(e=>[n,e]):[[n,r]])},[]))}function ta(e,t){let n=ea(e);return t&&t.forEach((e,r)=>{n.has(r)||t.getAll(r).forEach(e=>{n.append(r,e)})}),n}var na=null;function ra(){if(na===null)try{new FormData(document.createElement(`form`),0),na=!1}catch{na=!0}return na}var ia=new Set([`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`]);function aa(e){return e!=null&&!ia.has(e)?(Qn(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${qi}"`),null):e}function oa(e,t){let n,r,i,a,o;if(Xi(e)){let o=e.getAttribute(`action`);r=o?Or(o,t):null,n=e.getAttribute(`method`)||`get`,i=aa(e.getAttribute(`enctype`))||qi,a=new FormData(e)}else if(Yi(e)||Zi(e)&&(e.type===`submit`||e.type===`image`)){let o=e.form;if(o==null)throw Error(`Cannot submit a <button> or <input type="submit"> without a <form>`);let s=e.getAttribute(`formaction`)||o.getAttribute(`action`);if(r=s?Or(s,t):null,n=e.getAttribute(`formmethod`)||o.getAttribute(`method`)||`get`,i=aa(e.getAttribute(`formenctype`))||aa(o.getAttribute(`enctype`))||qi,a=new FormData(o,e),!ra()){let{name:t,type:n,value:r}=e;if(n===`image`){let e=t?`${t}.`:``;a.append(`${e}x`,`0`),a.append(`${e}y`,`0`)}else t&&a.append(t,r)}}else if(Ji(e))throw Error(`Cannot submit element that is not <form>, <button>, or <input type="submit|image">`);else n=`get`,r=null,i=qi,o=e;return a&&i===`text/plain`&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}function sa(e,t){if(e===!1||e==null)throw Error(t)}function ca(e,t){let n=typeof e==`string`?new URL(e,typeof window>`u`?`server://singlefetch/`:window.location.origin):e;return n.pathname=n.pathname.endsWith(`/`)?`${n.pathname}_.${t}`:`${n.pathname}.${t}`,n}async function la(e,t){if(e.id in t)return t[e.id];try{let n=await Le(()=>import(e.module),[]);return t[e.id]=n,n}catch(t){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(t),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function ua(e){return e!=null&&typeof e.page==`string`}function da(e){return e==null?!1:e.href==null?e.rel===`preload`&&typeof e.imageSrcSet==`string`&&typeof e.imageSizes==`string`:typeof e.rel==`string`&&typeof e.href==`string`}async function fa(e,t,n){return _a((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await la(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(da).filter(e=>e.rel===`stylesheet`||e.rel===`preload`).map(e=>e.rel===`stylesheet`?{...e,rel:`prefetch`,as:`style`}:{...e,rel:`prefetch`}))}function pa(e,t,n,r,i,a){let o=(e,t)=>!n[t]||e.route.id!==n[t].route.id,s=(e,t)=>n[t].pathname!==e.pathname||n[t].route.path?.endsWith(`*`)&&n[t].params[`*`]!==e.params[`*`];return a===`assets`?t.filter((e,t)=>o(e,t)||s(e,t)):a===`data`?t.filter((t,a)=>{let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(o(t,a)||s(t,a))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if(typeof r==`boolean`)return r}return!0}):[]}function ma(e,t,{includeHydrateFallback:n}={}){return ha(e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let i=[r.module];return r.clientActionModule&&(i=i.concat(r.clientActionModule)),r.clientLoaderModule&&(i=i.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(i=i.concat(r.hydrateFallbackModule)),r.imports&&(i=i.concat(r.imports)),i}).flat(1))}function ha(e){return[...new Set(e)]}function ga(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function _a(e,t){let n=new Set,r=new Set(t);return e.reduce((e,i)=>{if(t&&!ua(i)&&i.as===`script`&&i.href&&r.has(i.href))return e;let a=JSON.stringify(ga(i));return n.has(a)||(n.add(a),e.push({key:a,link:i})),e},[])}function va(){let e=V.useContext(ti);return sa(e,`You must render this element inside a <DataRouterContext.Provider> element`),e}function ya(){let e=V.useContext(ni);return sa(e,`You must render this element inside a <DataRouterStateContext.Provider> element`),e}var ba=V.createContext(void 0);ba.displayName=`FrameworkContext`;function xa(){let e=V.useContext(ba);return sa(e,`You must render this element inside a <HydratedRouter> element`),e}function Sa(e,t){let n=V.useContext(ba),[r,i]=V.useState(!1),[a,o]=V.useState(!1),{onFocus:s,onBlur:c,onMouseEnter:l,onMouseLeave:u,onTouchStart:d}=t,f=V.useRef(null);V.useEffect(()=>{if(e===`render`&&o(!0),e===`viewport`){let e=new IntersectionObserver(e=>{e.forEach(e=>{o(e.isIntersecting)})},{threshold:.5});return f.current&&e.observe(f.current),()=>{e.disconnect()}}},[e]),V.useEffect(()=>{if(r){let e=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(e)}}},[r]);let p=()=>{i(!0)},m=()=>{i(!1),o(!1)};return n?e===`intent`?[a,f,{onFocus:Ca(s,p),onBlur:Ca(c,m),onMouseEnter:Ca(l,p),onMouseLeave:Ca(u,m),onTouchStart:Ca(d,p)}]:[a,f,{}]:[!1,f,{}]}function Ca(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function wa({page:e,...t}){let n=ii(),{nonce:r}=xa(),{router:i}=va(),a=V.useMemo(()=>or(i.routes,e,i.basename),[i.routes,e,i.basename]);return a?(t.nonce==null&&r&&(t={...t,nonce:r}),n?V.createElement(Ea,{page:e,matches:a,...t}):V.createElement(Da,{page:e,matches:a,...t})):null}function Ta(e){let{manifest:t,routeModules:n}=xa(),[r,i]=V.useState([]);return V.useEffect(()=>{let r=!1;return fa(e,t,n).then(e=>{r||i(e)}),()=>{r=!0}},[e,t,n]),r}function Ea({page:e,matches:t,...n}){let r=yi(),i=V.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=ca(e,`rsc`),i=!1,a=[];for(let e of t)typeof e.route.shouldRevalidate==`function`?i=!0:a.push(e.route.id);return i&&a.length>0&&n.searchParams.set(`_routes`,a.join(`,`)),[n.pathname+n.search]},[e,r,t]);return V.createElement(V.Fragment,null,i.map(e=>V.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})))}function Da({page:e,matches:t,...n}){let r=yi(),{manifest:i,routeModules:a}=xa(),{loaderData:o,matches:s}=ya(),c=V.useMemo(()=>pa(e,t,s,i,r,`data`),[e,t,s,i,r]),l=V.useMemo(()=>pa(e,t,s,i,r,`assets`),[e,t,s,i,r]),u=V.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,s=!1;if(t.forEach(e=>{let t=i.routes[e.route.id];t&&t.hasLoader&&(!c.some(t=>t.route.id===e.route.id)&&e.route.id in o&&a[e.route.id]?.shouldRevalidate||t.hasClientLoader?s=!0:n.add(e.route.id))}),n.size===0)return[];let l=ca(e,`data`);return s&&n.size>0&&l.searchParams.set(`_routes`,t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(`,`)),[l.pathname+l.search]},[o,r,i,c,t,e,a]),d=V.useMemo(()=>ma(l,i),[l,i]),f=Ta(l);return V.createElement(V.Fragment,null,u.map(e=>V.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})),d.map(e=>V.createElement(`link`,{key:e,rel:`modulepreload`,href:e,...n})),f.map(({key:e,link:t})=>V.createElement(`link`,{key:e,nonce:n.nonce,...t,crossOrigin:t.crossOrigin??n.crossOrigin})))}function Oa(...e){return t=>{e.forEach(e=>{typeof e==`function`?e(t):e!=null&&(e.current=t)})}}var ka=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;try{ka&&(window.__reactRouterVersion=`8`)}catch{}function Aa({basename:e,children:t,useTransitions:n,window:r}){let i=V.useRef(null);i.current??=Xn({window:r,v5Compat:!0});let a=i.current,[o,s]=V.useState({action:a.action,location:a.location}),c=V.useCallback(e=>{n===!1?s(e):V.startTransition(()=>s(e))},[n]);return V.useLayoutEffect(()=>a.listen(c),[a,c]),V.createElement(Ki,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:a,useTransitions:n})}var ja=V.forwardRef(function({onClick:e,discover:t=`render`,prefetch:n=`none`,relative:r,reloadDocument:i,replace:a,mask:o,state:s,target:c,to:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m){let{basename:h,navigator:g,useTransitions:_}=V.useContext(ci),v=typeof l==`string`&&Gn.test(l),y=Gr(l,h);l=y.to;let b=_i(l,{relative:r}),x=yi(),S=null;if(o){let e=Pr(o,[],x.mask?x.mask.pathname:`/`,!0);h!==`/`&&(e.pathname=e.pathname===`/`?h:Ir([h,e.pathname])),S=g.createHref(e)}let[C,w,T]=Sa(n,p),E=Ia(l,{replace:a,mask:o,state:s,target:c,preventScrollReset:u,relative:r,viewTransition:d,defaultShouldRevalidate:f,useTransitions:_});function D(t){e&&e(t),t.defaultPrevented||E(t)}let O=!(y.isExternal||i),k=V.createElement(`a`,{...p,...T,href:(O?S:void 0)||y.absoluteURL||b,onClick:O?D:e,ref:Oa(m,w),target:c,"data-discover":!v&&t===`render`?`true`:void 0});return C&&!v?V.createElement(V.Fragment,null,k,V.createElement(wa,{page:b})):k});ja.displayName=`Link`;var Ma=V.forwardRef(function({"aria-current":e=`page`,caseSensitive:t=!1,className:n=``,end:r=!1,style:i,to:a,viewTransition:o,children:s,...c},l){let u=wi(a,{relative:c.relative}),d=yi(),f=V.useContext(ni),{navigator:p,basename:m}=V.useContext(ci),h=f!=null&&Ha(u)&&o===!0,g=p.encodeLocation?p.encodeLocation(u).pathname:u.pathname,_=d.pathname,v=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;t||(_=_.toLowerCase(),v=v?v.toLowerCase():null,g=g.toLowerCase()),v&&m&&(v=Or(v,m)||v);let y=g!==`/`&&g.endsWith(`/`)?g.length-1:g.length,b=_===g||!r&&_.startsWith(g)&&_.charAt(y)===`/`,x=v!=null&&(v===g||!r&&v.startsWith(g)&&v.charAt(y)===`/`),S={isActive:b,isPending:x,isTransitioning:h},C=b?e:void 0,w;w=typeof n==`function`?n(S):[n,b?`active`:null,x?`pending`:null,h?`transitioning`:null].filter(Boolean).join(` `);let T=typeof i==`function`?i(S):i;return V.createElement(ja,{...c,"aria-current":C,className:w,ref:l,style:T,to:a,viewTransition:o},typeof s==`function`?s(S):s)});Ma.displayName=`NavLink`;var Na=V.forwardRef(({discover:e=`render`,fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=`get`,action:s,onSubmit:c,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m)=>{let{useTransitions:h}=V.useContext(ci),g=Ba(),_=Va(s,{relative:l}),v=o.toLowerCase()===`get`?`get`:`post`,y=typeof s==`string`&&Gn.test(s);return V.createElement(`form`,{ref:m,method:v,action:_,onSubmit:r?c:e=>{if(c&&c(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=r?.getAttribute(`formmethod`)||o,p=()=>g(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:a,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f});h&&n!==!1?V.startTransition(()=>p()):p()},...p,"data-discover":!y&&e===`render`?`true`:void 0})});Na.displayName=`Form`;function Pa(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Fa(e){let t=V.useContext(ti);return Zn(t,Pa(e)),t}function Ia(e,{target:t,replace:n,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c,useTransitions:l}={}){let u=xi(),d=yi(),f=wi(e,{relative:o});return V.useCallback(p=>{if($i(p,t)){p.preventDefault();let t=n===void 0?nr(d)===nr(f):n,m=()=>u(e,{replace:t,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c});l?V.startTransition(()=>m()):m()}},[d,u,f,n,r,i,t,e,a,o,s,c,l])}function La(e){Qn(typeof URLSearchParams<`u`,"You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=V.useRef(ea(e)),n=V.useRef(!1),r=yi(),i=V.useMemo(()=>ta(r.search,n.current?null:t.current),[r.search]),a=xi();return[i,V.useCallback((e,t)=>{let r=ea(typeof e==`function`?e(new URLSearchParams(i)):e);n.current=!0,a(`?`+r,t)},[a,i])]}var Ra=0,za=()=>`__${String(++Ra)}__`;function Ba(){let{router:e}=Fa(`useSubmit`),{basename:t}=V.useContext(ci),n=zi(),r=e.fetch,i=e.navigate;return V.useCallback(async(e,a={})=>{let{action:o,method:s,encType:c,formData:l,body:u}=oa(e,t);a.navigate===!1?await r(a.fetcherKey||za(),n,a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,relative:a.relative,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,flushSync:a.flushSync}):await i(a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,relative:a.relative,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,replace:a.replace,state:a.state,fromRouteId:n,flushSync:a.flushSync,viewTransition:a.viewTransition})},[r,i,t,n])}function Va(e,{relative:t}={}){let{basename:n}=V.useContext(ci),r=V.useContext(ui);Zn(r,`useFormAction must be used inside a RouteContext`);let[i]=r.matches.slice(-1),a={...wi(e||`.`,{relative:t})},o=yi();if(e==null){a.search=o.search;let e=new URLSearchParams(a.search),t=e.getAll(`index`);if(t.some(e=>e===``)){e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();a.search=n?`?${n}`:``}}return(!e||e===`.`)&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,`?index&`):`?index`),n!==`/`&&(a.pathname=a.pathname===`/`?n:Ir([n,a.pathname])),nr(a)}function Ha(e,{relative:t}={}){let n=V.useContext(ai);Zn(n!=null,"`useViewTransitionState` must be used within `react-router/dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=Fa(`useViewTransitionState`),i=wi(e,{relative:t});if(!n.isTransitioning)return!1;let a=Or(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Or(n.nextLocation.pathname,r)||n.nextLocation.pathname;return wr(i.pathname,o)!=null||wr(i.pathname,a)!=null}var Ua=[`web`,`android`,`ios`];function Wa(e){if(!e)return null;let t=Ga(e);for(let e of Ua)if(e===`web`&&t.has(e))return e;return null}function Ga(e){let t=new Set(e===!0?Ua:e===!1?[]:Array.isArray(e)?e:[e]);return t.has(`mobile`)&&(t.add(`android`),t.add(`ios`),t.delete(`mobile`)),t}var Ka;bn(`gesture`,{enabled:!1,Gesture:null,GestureDetector:null,ScrollView:null,RootView:null});var qa=`__hanzogui_press_state__`;(Ka=globalThis)[qa]??(Ka[qa]={owner:null,ownerId:null,ownerSource:null,ownerPointerId:null,timestamp:0}),bn(`zeego`,{enabled:!1,DropdownMenu:null,ContextMenu:null}),(0,V.createContext)(!1);var Ja=[`100`,`200`,`300`,`400`,`500`,`600`,`700`,`800`,`900`],Ya=(e,t,n)=>{if(typeof e==`string`)return e;let r=Object.keys(e),i=e[r[0]];return Object.fromEntries([...new Set([...t,...r])].map(t=>{let r=e[t]??n??i;return i=r,n=r,[t,r]}))},Xa=e=>{let t=Object.keys(e.size||{}),n=Object.fromEntries(Object.entries(e).map(([n,r])=>[n,Ya(r,n===`face`?Ja:t,n===`face`?{normal:e.family}:void 0)]));return Object.freeze(n)},Za=()=>pe()?be:!1;function Qa(){let e=V.useContext(vn);if(!e)return[!0,null,e];let{id:t,isPresent:n,onExitComplete:r,register:i}=e;return V.useEffect(()=>i(t),[]),!n&&r?[!1,()=>r?.(t),e]:[!0,void 0,e]}var H=s();function $a(e){let{Provider:t,useStyledContext:n}=S({collectionRef:{current:void 0},itemMap:new Map},`Toast`),r=e=>{let{scope:n,children:r}=e,i=V.useRef(void 0),a=V.useRef(new Map).current;return(0,H.jsx)(t,{scope:n,itemMap:a,collectionRef:i,children:r})};r.displayName=`CollectionProvider`;let i=e+`CollectionSlot`,a=V.forwardRef((e,t)=>{let{scope:r,children:i}=e,a=n(r),o=he(t,a.collectionRef);return(0,H.jsx)(_e,{ref:o,children:i})});a.displayName=i;let o=e+`CollectionItemSlot`,s=`data-collection-item`,c=V.forwardRef((e,t)=>{let{scope:r,children:i,...a}=e,o=V.useRef(void 0),c=he(t,o),l=n(r);return V.useEffect(()=>(l.itemMap.set(o,{ref:o,...a}),()=>void l.itemMap.delete(o))),(0,H.jsx)(_e,{[s]:``,ref:c,children:i})});c.displayName=o;function l(e){let t=n(e);return V.useCallback(()=>{let e=t.collectionRef.current;if(!e)return[];let n=Array.from(e.querySelectorAll(`[${s}]`));return Array.from(t.itemMap.values()).sort((e,t)=>n.indexOf(e.ref.current)-n.indexOf(t.ref.current))},[t.collectionRef,t.itemMap])}return[{Provider:r,Slot:a,ItemSlot:c},l]}var eo=M(h,{name:`SizableStack`,variants:{unstyled:{true:{elevate:!1,bordered:!1}},circular:d,elevate:p,bordered:{true:c},size:{"...size":(e,t)=>r(e,t)}}}),to=V.createContext(void 0);function no(e){let t=V.useContext(to);return e||t||`ltr`}var ro=[`animating`,`color`,`hidesWhenStopped`,`size`,`style`],io=e=>V.createElement(`circle`,{cx:`16`,cy:`16`,fill:`none`,r:`14`,strokeWidth:`4`,style:e}),ao=V.forwardRef((e,t)=>{var n=e.animating,r=n===void 0||n,i=e.color,a=i===void 0?`#1976D2`:i,o=e.hidesWhenStopped,s=o===void 0||o,c=e.size,l=c===void 0?`small`:c,u=e.style,d=x(e,ro),f=V.createElement(`svg`,{height:`100%`,viewBox:`0 0 32 32`,width:`100%`},io({stroke:a,opacity:.2}),io({stroke:a,strokeDasharray:80,strokeDashoffset:60}));return V.createElement(xe,Tt({},d,{"aria-valuemax":1,"aria-valuemin":0,ref:t,role:`progressbar`,style:[oo.container,u]}),V.createElement(xe,{children:f,style:[typeof l==`number`?{height:l,width:l}:so[l],oo.animation,!r&&oo.animationPause,!r&&s&&oo.hidesWhenStopped]}))});ao.displayName=`ActivityIndicator`;var oo=i.create({container:{alignItems:`center`,justifyContent:`center`},hidesWhenStopped:{visibility:`hidden`},animation:{animationDuration:`0.75s`,animationKeyframes:[{"0%":{transform:`rotate(0deg)`},"100%":{transform:`rotate(360deg)`}}],animationTimingFunction:`linear`,animationIterationCount:`infinite`},animationPause:{animationPlayState:`paused`}}),so=i.create({small:{width:20,height:20},large:{width:36,height:36}}),co=M(n,{name:`Image`,render:`img`}),lo=co.styleable((e,t)=>{let{blurRadius:n,capInsets:r,defaultSource:i,fadeDuration:a,loadingIndicatorSource:o,onLoadEnd:s,onPartialLoad:c,progressiveRenderingEnabled:l,resizeMethod:u,tintColor:d,...f}=e;return(0,H.jsx)(co,{ref:t,...f})},{staticConfig:{memo:!0}}),uo=(()=>{});lo.getSize=uo,lo.getSizeWithHeaders=uo,lo.prefetch=uo,lo.prefetchWithMetadata=uo,lo.abortPrefetch=uo,lo.queryCache=uo;var fo=(e,{tokens:t})=>{let n=t.size[e]??e,r=t.size[e]??e;return{width:n,height:r,minWidth:n,maxWidth:n,maxHeight:r,minHeight:r}},po=M(h,{name:`Square`,alignItems:`center`,justifyContent:`center`,variants:{size:{"...size":fo,":number":fo}}},{memo:!0}),mo=`Avatar`,[ho,go]=Ht(mo),[_o,vo]=ho(mo),yo=`AvatarImage`,bo=V.forwardRef((e,t)=>{let{__scopeAvatar:n,src:r,source:i,onLoadingStatusChange:a=()=>{},...o}=e,s=vo(yo,n),[c,l]=V.useState(`idle`),u=r||(i&&typeof i==`object`&&`uri`in i?i.uri:i);return V.useEffect(()=>{l(u?`idle`:`error`)},[u]),V.useEffect(()=>{a(c),s.onImageLoadingStatusChange(c)},[c]),u?(0,H.jsx)(z,{fullscreen:!0,zIndex:1,children:(0,H.jsx)(lo,{position:`absolute`,top:0,left:0,right:0,bottom:0,objectFit:`cover`,width:`100%`,height:`100%`,...o,ref:t,src:u,onError:()=>{l(`error`)},onLoad:()=>{l(`loaded`)}})}):null});bo.displayName=yo;var xo=`AvatarFallback`,So=M(z,{name:xo,position:`absolute`,fullscreen:!0,zIndex:0}),Co=So.styleable((e,t)=>{let{__scopeAvatar:n,delayMs:r,...i}=e,a=vo(xo,n),[o,s]=V.useState(r===void 0);return V.useEffect(()=>{if(r!==void 0){let e=setTimeout(()=>s(!0),r);return()=>clearTimeout(e)}},[r]),o&&a.imageLoadingStatus!==`loaded`?(0,H.jsx)(So,{...i,ref:t}):null});Co.displayName=xo;var wo=M(po,{name:mo,position:`relative`,overflow:`hidden`}),To=oe(V.forwardRef((e,t)=>{let{__scopeAvatar:n,size:r=`$true`,...i}=e,[a,o]=V.useState(`idle`);return(0,H.jsx)(_o,{size:r,scope:n,imageLoadingStatus:a,onImageLoadingStatusChange:o,children:(0,H.jsx)(wo,{size:r,...i,ref:t})})}),{Image:bo,Fallback:Co});To.displayName=mo;var Eo=e=>{let t=Fe(e.color);return n=>n&&(V.isValidElement(n)?V.cloneElement(n,{...e,color:t,...n.props}):V.createElement(n,e))},Do=S({size:`$true`,scaleIcon:1,unstyled:{}.GUI_HEADLESS===`1`,active:!1,disabled:!1}),Oo=M(z,{name:`CheckboxIndicator`,context:Do,variants:{unstyled:{false:{}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}},{accept:{activeStyle:`style`}}),ko=M(z,{name:`Checkbox`,render:`button`,context:Do,variants:{unstyled:{false:{size:`$true`,backgroundColor:`$background`,alignItems:`center`,justifyContent:`center`,borderWidth:1,borderColor:`$borderColor`,hoverStyle:{borderColor:`$borderColorHover`},pressStyle:{backgroundColor:`$backgroundPress`,borderColor:`$borderColorPress`},focusStyle:{borderColor:`$borderColorFocus`},focusVisibleStyle:{outlineStyle:`solid`,outlineWidth:2,outlineColor:`$outlineColor`}}},disabled:{true:{pointerEvents:`none`,userSelect:`none`,cursor:`not-allowed`,hoverStyle:{borderColor:`$borderColor`,backgroundColor:`$background`},pressStyle:{borderColor:`$borderColor`,backgroundColor:`$background`},focusStyle:{outlineWidth:0}}},size:{"...size":e=>({borderRadius:ee(ie(e))/8})}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}},{accept:{activeStyle:`style`}}),[Ao,jo]=it(`Label`,{id:void 0,controlRef:{current:null}}),Mo=M(a,{name:`Label`,render:`label`,variants:{unstyled:{false:{size:`$true`,color:`$color`,backgroundColor:`transparent`,display:`flex`,alignItems:`center`,userSelect:`none`,cursor:`default`,pressStyle:{color:`$colorPress`}}},size:{"...size":(e,t)=>{let n=r(e,t)?.height;return{...g(e,t),lineHeight:n?t.tokens.size[n]:void 0}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}});Mo.styleable(function(e,t){let{htmlFor:n,id:r,...i}=e,a=V.useRef(null),o=V.useRef(null),s=he(t,o),c=V.useId(),l=r??c;return b(()=>{if(n){let e=document.getElementById(n);if(o.current&&e){let t=()=>e.getAttribute(`aria-labelledby`),n=[l,t()].filter(Boolean).join(` `);return e.setAttribute(`aria-labelledby`,n),a.current=e,()=>{if(!l)return;let n=t()?.replace(l,``);n===``?e.removeAttribute(`aria-labelledby`):n&&e.setAttribute(`aria-labelledby`,n)}}}},[l,n]),(0,H.jsx)(Ao,{id:l,controlRef:a,children:(0,H.jsx)(Mo,{id:l,htmlFor:n,...i,ref:s,onMouseDown:t=>{e.onMouseDown?.(t),!t.defaultPrevented&&t.detail>1&&t.preventDefault()},onPress:t=>{e.onPress?.(t);{if(n||!a.current||t.defaultPrevented)return;let e=a.current.contains(t.target),r=t.isTrusted===!0;!e&&r&&(a.current.click(),a.current.focus())}}})})});var No=e=>{let t=jo(`LabelConsumer`),{controlRef:n}=t;return V.useEffect(()=>{e&&(n.current=e)},[e,n]),t.id};function Po(e){let t=V.useRef({value:e,previous:e});return V.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function Fo(e){return e===`indeterminate`}function Io(e){return Fo(e)?`indeterminate`:e?`checked`:`unchecked`}var Lo=e=>{let{checked:t,bubbles:n=!0,control:r,isHidden:i,...a}=e,o=V.useRef(null),s=Po(t);return V.useEffect(()=>{let e=o.current,r=window.HTMLInputElement.prototype,i=Object.getOwnPropertyDescriptor(r,`checked`).set;if(s!==t&&i){let r=new Event(`click`,{bubbles:n});e.indeterminate=Fo(t),i.call(e,!Fo(t)&&t),e.dispatchEvent(r)}},[s,t,n]),(0,H.jsx)(`input`,{type:`checkbox`,defaultChecked:!Fo(t)&&t,...a,tabIndex:-1,ref:o,"aria-hidden":i,style:{...i?{position:`absolute`,pointerEvents:`none`,opacity:0,margin:0}:{appearance:`auto`,accentColor:`var(--color6)`},...e.style}})};function Ro(e,[t,n],r){let{labelledBy:i,name:a,required:o,disabled:s,value:c=`on`,onCheckedChange:l,...u}=e,[d,f]=V.useState(null),p=he(r,f),m=V.useRef(!1),h=!d||!!d.closest(`form`),g=No(d),_=i||g,v=e.onKeyDown,y=(0,V.useMemo)(()=>I(v,e=>{e.key===`Enter`&&e.preventDefault()}),[v]),b=(0,V.useMemo)(()=>I(e.onPress,e=>{n(e=>Fo(e)?!0:!e),h&&`isPropagationStopped`in e&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}),[h]);return{bubbleInput:h?(0,H.jsx)(Lo,{isHidden:!0,control:d,bubbles:!m.current,name:a,value:c,checked:t,required:o,disabled:s}):null,checkboxRef:p,checkboxProps:{role:`checkbox`,"aria-labelledby":_,"aria-checked":Fo(t)?`mixed`:t,...u,type:`button`,value:c,"data-state":Io(t),"data-disabled":s?``:void 0,disabled:s,onKeyDown:s?void 0:y,onPress:s?void 0:b}}}var zo=V.createContext({checked:!1,disabled:!1}),Bo=e=>{e.context||=zo};function Vo(e){let{Frame:t=ko,Indicator:n=Oo}=e;Bo(t),Bo(n);let r=t.styleable(function(e,n){let{scaleSize:r=.45,sizeAdjust:i=0,scaleIcon:a,checked:o,defaultChecked:s,onCheckedChange:c,native:l,unstyled:u=!1,activeStyle:d,activeTheme:f,...p}=e,m=v(p),h=V.useContext(Do.context),g=0,_=0;u||(g=ee(ie(m.size??h?.size??`$true`,{shift:i})),_=r?Math.round(g*r):g);let[y=!1,b]=et({prop:o,defaultProp:s,onChange:c}),{checkboxProps:x,checkboxRef:S,bubbleInput:C}=Ro(m,[y,b],n);if(Wa(l)===`web`)return(0,H.jsx)(`input`,{type:`checkbox`,defaultChecked:!Fo(y)&&y,tabIndex:-1,ref:S,disabled:x.disabled,style:{appearance:`auto`,accentColor:`var(--color6)`,...x.style}});let w=(0,V.useMemo)(()=>({checked:y,disabled:x.disabled}),[y,x.disabled]),T=!!y,E=x.disabled;return(0,H.jsx)(zo.Provider,{value:w,children:(0,H.jsxs)(Do.Provider,{size:m.size??h?.size??`$true`,scaleIcon:a??h?.scaleIcon??1,unstyled:u,active:T,disabled:E,children:[(0,H.jsx)(t,{render:`button`,ref:S,unstyled:u,theme:f??null,type:`button`,...!u&&{width:_,height:_,size:_},checked:y,disabled:E,...x,...p,...T&&{...!u&&!d&&{backgroundColor:`$backgroundActive`},...d},children:m.children}),C]})})}),i=n.styleable((e,t)=>{let{children:r,forceMount:i,disablePassStyles:a,unstyled:o=!1,activeStyle:s,...c}=e,l=Do.useStyledContext(),{active:u}=l,d=r;if(!o){let e=Eo({size:(typeof l.size==`number`?l.size*.65:We(l.size))*l.scaleIcon,color:A().color});d=V.Children.toArray(r).map(t=>a||!V.isValidElement(t)?t:e(t))}let f=V.useContext(zo);return i||Fo(f.checked)||f.checked===!0?(0,H.jsx)(n,{pointerEvents:`none`,...c,...u&&s,ref:t,children:d}):null});return oe(r,{Indicator:i})}var Ho=Vo({Frame:ko,Indicator:Oo}),Uo=V.createContext([]),Wo=V.createContext(null);function Go(){let e=V.useContext(Uo),t=V.useContext(Wo);return V.useMemo(()=>{if(t===null)return null;let n=qo(t),r=e[e.length-1],i=n[n.length-1];return{maxIndex:r,maxIndexPath:e,index:i,indexPath:n,indexPathString:t,isFirst:i===0,isLast:i===r,isEven:i%2==0,isOdd:Math.abs(i%2)===1}},[e,t])}function Ko(e){let t=V.useContext(Uo),n=V.useContext(Wo),r=V.Children.count(e),i=V.useMemo(()=>t.concat(r-1),[r]);return(0,H.jsx)(Uo.Provider,{value:i,children:V.Children.map(e,(e,t)=>V.isValidElement(e)?(0,H.jsx)(Wo.Provider,{value:n?`${n}.${t.toString()}`:t.toString(),children:e},e.key):e)})}function qo(e){return e.split(`.`).map(e=>Number.parseInt(e,10))}var Jo=`Group`,[Yo,Xo]=Ht(Jo),[Zo,Qo]=Yo(Jo),$o=M(z,{name:`GroupFrame`,variants:{unstyled:{false:{size:`$true`}},size:(e,{tokens:t})=>({borderRadius:t.radius[e]??e??t.radius.$true})},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}});function es(e){return oe($o.styleable((t,n)=>{let{__scopeGroup:r,children:i,orientation:a=e?`vertical`:`horizontal`,disabled:o,...s}=t,c=a===`vertical`,l=Ko(V.Children.toArray(i));return(0,H.jsx)(Zo,{vertical:c,disabled:o,scope:r,children:(0,H.jsx)($o,{ref:n,flexDirection:c?`column`:`row`,...s,children:l})})}),{Item:ts})}function ts(e){let{__scopeGroup:t,children:n,forcePlacement:r,...i}=e,a=Qo(`GroupItem`,t),o=Go();if(!o)throw Error(`<Group.Item/> should only be used within a <Group/>`);if(!V.isValidElement(n))return n;let s=as(r===`first`||r!==`last`&&o.index===0,r===`last`||r!==`first`&&o.index===o.maxIndex,a.vertical),c={...i,...s};a.disabled!=null&&(c.disabled=n.props.disabled??a.disabled);let l=re(c,n.props);return V.cloneElement(n,l)}var ns=(e,t,n)=>{let r=Go(),i=Qo(`GroupItem`,n);if(!r)throw Error(`useGroupItem should only be used within a <Group/>`);let a=as(t===`first`||t!==`last`&&r.index===0,t===`last`||t!==`first`&&r.index===r.maxIndex,i.vertical);return{disabled:e.disabled??i.disabled,...a}},rs=es(!0),is=es(!1);function as(e,t,n){return n?{...e?null:{borderTopLeftRadius:0,borderTopRightRadius:0},...t?null:{borderBottomLeftRadius:0,borderBottomRightRadius:0}}:{...e?null:{borderTopLeftRadius:0,borderBottomLeftRadius:0},...t?null:{borderTopRightRadius:0,borderBottomRightRadius:0}}}var os=`ListItem`,ss=S({size:void 0,variant:void 0,color:void 0}),cs=M(n,{context:ss,name:os,render:`li`,role:`listitem`,variants:{unstyled:{false:{size:`$true`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`nowrap`,borderColor:`$borderColor`,width:`100%`,maxWidth:`100%`,overflow:`hidden`,flexDirection:`row`,backgroundColor:`$background`,cursor:`default`,hoverStyle:{backgroundColor:`$backgroundHover`,borderColor:`$borderColorHover`},pressStyle:{backgroundColor:`$backgroundPress`,borderColor:`$borderColorPress`}}},variant:{outlined:{}.GUI_HEADLESS===`1`?{}:{backgroundColor:`transparent`,borderWidth:1,borderColor:`$borderColor`,hoverStyle:{backgroundColor:`transparent`,borderColor:`$borderColorHover`},pressStyle:{backgroundColor:`transparent`,borderColor:`$borderColorPress`}}},size:{"...size":(e,{tokens:t})=>({minHeight:t.size[e],paddingHorizontal:t.space[e],paddingVertical:m(t.space[e],{shift:-4})})},active:{true:{hoverStyle:{backgroundColor:`$background`}}},disabled:{true:{opacity:.5,pointerEvents:`none`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),ls=M(a,{context:ss,name:`ListItemText`,variants:{unstyled:{false:{color:`$color`,size:`$true`,flexGrow:1,flexShrink:1,ellipsis:!0,cursor:`inherit`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),us=M(ls,{name:`ListItemSubtitle`,context:ss,variants:{unstyled:{false:{opacity:.6,maxWidth:`100%`,color:`$color`}},size:{"...size":(e,t)=>{let n=ie(e,{shift:-1,excludeHalfSteps:!0});return g(n.key,t)}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),ds=M(ls,{name:`ListItemTitle`,context:ss,variants:{unstyled:{false:{}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),fs=e=>{let{children:t,size:n,scaleIcon:r=1}=e,i=ss.useStyledContext();if(!i)throw Error(`ListItem.Icon must be used within a ListItem`);let a=n??i.size??`$true`,o=Fe(i.color),s=We(a)*r;return Pe(t,{size:s,color:o})},ps=cs.styleable(function(e,t){let{children:r,icon:i,iconAfter:a,scaleIcon:o=1,unstyled:s=!1,subTitle:c,title:l,iconSize:u,...d}=e,f=e.size||`$true`,p=ss.useStyledContext(),m=Fe(p?.color),h=We(u||f)*o,g=h*.4,_=i?(0,H.jsx)(n,{marginRight:g,children:Pe(i,{size:h,color:m})}):null,v=a?(0,H.jsx)(n,{marginLeft:g,children:Pe(a,{size:h,color:m})}):null,y=Ve(ls,{children:r},e.unstyled===!0?void 0:{unstyled:{}.GUI_HEADLESS===`1`,fontSize:e.size});return(0,H.jsxs)(cs,{ref:t,...d,children:[_,l||c?(0,H.jsxs)(z,{flex:1,children:[l?typeof l==`string`?(0,H.jsx)(ds,{unstyled:s,size:f,children:l}):l:null,c?(0,H.jsx)(H.Fragment,{children:typeof c==`string`?(0,H.jsx)(us,{unstyled:s,size:f,children:c}):c}):null,y]}):y,v]})}),ms=oe(ps,{Apply:ss.Provider,Frame:cs,Text:ls,Subtitle:us,Icon:fs,Title:ds}),hs=0;function gs(){V.useEffect(()=>{let e=document.querySelectorAll(`[data-hanzogui-focus-guard]`);return document.body.insertAdjacentElement(`afterbegin`,e[0]??_s()),document.body.insertAdjacentElement(`beforeend`,e[1]??_s()),hs++,()=>{hs===1&&document.querySelectorAll(`[data-hanzogui-focus-guard]`).forEach(e=>e.remove()),hs--}},[])}function _s(){let e=document.createElement(`span`);return e.setAttribute(`data-hanzogui-focus-guard`,``),e.tabIndex=0,e.style.cssText=`outline: none; opacity: 0; position: fixed; pointer-events: none`,e}function vs(e){return ln(e.target)&&e.target.tagName===`BUTTON`}function ys(e){return ln(e.target)&&e.target.tagName===`A`}function bs(e){return tn(e)}function xs(e,t={}){let{open:n,onOpenChange:r,dataRef:i,elements:{domReference:a}}=e,{enabled:o=!0,event:s=`click`,toggle:c=!0,ignoreMouse:l=!1,keyboardHandlers:u=!0,stickIfOpen:d=!0}=t,f=(0,V.useRef)(void 0),p=(0,V.useRef)(!1),m=(0,V.useMemo)(()=>({onPointerDown(e){f.current=e.pointerType},onMouseDown(e){let t=f.current;e.button===0&&s!==`click`&&(Nn(t,!0)&&l||(n&&c&&(!(i.current.openEvent&&d)||i.current.openEvent.type===`mousedown`)?r(!1,e.nativeEvent||e,`click`):(e.preventDefault(),r(!0,e.nativeEvent||e,`click`))))},onClick(e){let t=f.current;if(s===`mousedown`&&f.current){f.current=void 0;return}Nn(t,!0)&&l||(n&&c&&(!(i.current.openEvent&&d)||i.current.openEvent.type===`click`)?r(!1,e.nativeEvent||e,`click`):r(!0,e.nativeEvent||e,`click`))},onKeyDown(e){f.current=void 0,!(e.defaultPrevented||!u||vs(e))&&(e.key===` `&&!bs(a)&&(e.preventDefault(),p.current=!0),!ys(e)&&e.key===`Enter`&&r(!(n&&c),e.nativeEvent||e,`click`))},onKeyUp(e){e.defaultPrevented||!u||vs(e)||bs(a)||e.key===` `&&p.current&&(p.current=!1,r(!(n&&c),e.nativeEvent||e,`click`))}}),[i,a,s,l,u,r,n,d,c]);return(0,V.useMemo)(()=>o?{reference:m}:{},[o,m])}var Ss=`ArrowUp`,Cs=`ArrowDown`,ws=`ArrowLeft`,Ts=`ArrowRight`;function Es(e,t,n){switch(e){case`vertical`:return t;case`horizontal`:return n;default:return t||n}}function Ds(e,t){return Es(t,e===Ss||e===Cs,e===ws||e===Ts)}function Os(e,t,n){return Es(t,e===Cs,n?e===ws:e===Ts)||e===`Enter`||e===` `||e===``}function ks(e,t,n){return Es(t,n?e===ws:e===Ts,e===Cs)}function As(e,t,n){return Es(t,n?e===Ts:e===ws,e===Ss)}function js(e,t){let{open:n,onOpenChange:r,elements:i}=e,{listRef:a,activeIndex:o,onNavigate:s=()=>{},enabled:c=!0,selectedIndex:l=null,allowEscape:u=!1,loop:d=!1,nested:p=!1,rtl:m=!1,virtual:h=!1,focusItemOnOpen:g=`auto`,focusItemOnHover:_=!0,openOnArrowKeyDown:v=!0,disabledIndices:y=void 0,orientation:b=`vertical`,scrollItemIntoView:x=!0}=t,S=Ln(i.domReference),C=(0,V.useRef)(g),w=(0,V.useRef)(l??-1),T=(0,V.useRef)(null),E=(0,V.useRef)(!0),D=(0,V.useRef)(!!i.floating),O=(0,V.useRef)(n),k=(0,V.useRef)(!1),A=(0,V.useRef)(!1),j=(0,V.useRef)(y);j.current=y;let ee=(0,V.useRef)(n);ee.current=n;let M=(0,V.useRef)(x);M.current=x;let N=(0,V.useRef)(l);N.current=l;let P=f(s),[te,F]=(0,V.useState)(),I=f(()=>{P(w.current===-1?null:w.current)}),ne=(0,V.useRef)(I),re=f(()=>{function e(e){h?F(e.id):cn(e,{sync:k.current,preventScroll:!0})}let t=a.current[w.current],n=A.current;t&&e(t),(k.current?e=>e():requestAnimationFrame)(()=>{let r=a.current[w.current]||t;if(!r)return;t||e(r);let i=M.current;i&&r&&(n||!E.current)&&r.scrollIntoView?.(typeof i==`boolean`?{block:`nearest`,inline:`nearest`}:i)})});(0,V.useLayoutEffect)(()=>{c&&(n&&i.floating?C.current&&l!=null&&(A.current=!0,w.current=l,I()):D.current&&(w.current=-1,ne.current()))},[c,n,i.floating,l,I]),(0,V.useLayoutEffect)(()=>{if(c&&n&&i.floating){if(o==null){if(k.current=!1,N.current!=null)return;if(D.current&&(w.current=-1,re()),(!O.current||!D.current)&&C.current&&(T.current!=null||C.current===!0&&T.current==null)){let e=0,t=()=>{a.current[0]==null?(e<2&&(e?requestAnimationFrame:queueMicrotask)(t),e++):(w.current=T.current==null||Os(T.current,b,m)||p?un(a,j.current):_n(a,j.current),T.current=null,I())};t()}}else Qt(a,o)||(w.current=o,re(),A.current=!1)}},[c,n,i.floating,o,N,p,a,b,m,I,re,j]),(0,V.useLayoutEffect)(()=>{ne.current=I,O.current=n,D.current=!!i.floating}),(0,V.useLayoutEffect)(()=>{n||(T.current=null,C.current=g)},[n,g]);let ie=o!=null,L=f(e=>{if(E.current=!1,k.current=!0,e.which===229||!ee.current&&e.currentTarget===i.floating)return;if(p&&As(e.key,b,m)){ot(e),r(!1,e.nativeEvent,`list-navigation`),ln(i.domReference)&&i.domReference.focus();return}let t=w.current,o=un(a,y),s=_n(a,y);if(S||(e.key===`Home`&&(ot(e),w.current=o,I()),e.key===`End`&&(ot(e),w.current=s,I())),Ds(e.key,b)){if(ot(e),n&&!h&&jn(e.currentTarget.ownerDocument)===e.currentTarget){w.current=Os(e.key,b,m)?o:s,I();return}Os(e.key,b,m)?d?w.current=t>=s?u&&t!==a.current.length?-1:o:Sn(a,{startingIndex:t,disabledIndices:y}):w.current=Math.min(s,Sn(a,{startingIndex:t,disabledIndices:y})):d?w.current=t<=o?u&&t!==-1?a.current.length:s:Sn(a,{startingIndex:t,decrement:!0,disabledIndices:y}):w.current=Math.max(o,Sn(a,{startingIndex:t,decrement:!0,disabledIndices:y})),Qt(a,w.current)&&(w.current=-1),I()}}),ae=(0,V.useMemo)(()=>h&&n&&ie&&{"aria-activedescendant":te},[h,n,ie,te]),oe=(0,V.useMemo)(()=>({"aria-orientation":b===`both`?void 0:b,...S?{}:ae,onKeyDown:L,onPointerMove(){E.current=!0}}),[ae,L,b,S]),R=(0,V.useMemo)(()=>{function e(e){g===`auto`&&In(e.nativeEvent)&&(C.current=!0)}function t(e){C.current=g,g===`auto`&&It(e.nativeEvent)&&(C.current=!0)}return{...ae,onKeyDown(e){E.current=!1;let t=e.key.startsWith(`Arrow`),i=ks(e.key,b,m),o=Ds(e.key,b),s=(p?i:o)||e.key===`Enter`||e.key.trim()===``;if(h&&n)return L(e);if(n||v||!t){if(s&&(T.current=e.key),p){i&&(ot(e),n?(w.current=un(a,j.current),I()):r(!0,e.nativeEvent,`list-navigation`));return}o&&(l!=null&&(w.current=l),ot(e),!n&&v?r(!0,e.nativeEvent,`list-navigation`):L(e),n&&I())}},onFocus(){n&&!h&&(w.current=-1,I())},onPointerDown:t,onPointerEnter:t,onMouseDown:e,onClick:e}},[ae,L,j,g,a,p,I,r,n,v,b,m,l,h]),se=(0,V.useMemo)(()=>{function e(e){if(!ee.current)return;let t=a.current.indexOf(e);t!==-1&&w.current!==t&&(w.current=t,I())}return{onFocus({currentTarget:t}){k.current=!0,e(t)},onClick:({currentTarget:e})=>e.focus({preventScroll:!0}),onMouseMove({currentTarget:t}){k.current=!0,A.current=!1,_&&e(t)},onPointerLeave({pointerType:e}){E.current&&e!==`touch`&&(k.current=!0,_&&(w.current=-1,I(),h||i.floating?.focus({preventScroll:!0})))}}},[ee,_,a,I,h,i.floating]);return(0,V.useMemo)(()=>c?{reference:R,floating:oe,item:se}:{},[c,R,oe,se])}function Ms(e,t){let{open:n,dataRef:r}=e,{listRef:i,activeIndex:a,onMatch:o,onTypingChange:s,enabled:c=!0,findMatch:l=null,resetMs:u=750,ignoreKeys:d=[],selectedIndex:p=null}=t,m=(0,V.useRef)(-1),h=(0,V.useRef)(``),g=(0,V.useRef)(p??a??-1),_=(0,V.useRef)(null),v=f(o||(()=>{})),y=f(s||(()=>{})),b=(0,V.useRef)(l);b.current=l;let x=(0,V.useRef)(d);x.current=d,(0,V.useLayoutEffect)(()=>{n&&(rn(m),_.current=null,h.current=``)},[n]),(0,V.useLayoutEffect)(()=>{n&&h.current===``&&(g.current=p??a??-1)},[n,p,a]);let S=e=>{e?r.current.typing||(r.current.typing=e,y(e)):r.current.typing&&(r.current.typing=e,y(e))},C=e=>{function t(e,t,n){let r=b.current?b.current(t,n):t.find(e=>e?.toLocaleLowerCase().indexOf(n.toLocaleLowerCase())===0);return r?e.indexOf(r):-1}let r=i.current;if(h.current.length>0&&h.current[0]!==` `&&(t(r,r,h.current)===-1?S(!1):e.key===` `&&ot(e)),r==null||x.current.includes(e.key)||e.key.length!==1||e.ctrlKey||e.metaKey||e.altKey)return;n&&e.key!==` `&&(ot(e),S(!0)),r.every(e=>!e||e[0]?.toLocaleLowerCase()!==e[1]?.toLocaleLowerCase())&&h.current===e.key&&(h.current=``,g.current=_.current),h.current+=e.key,rn(m),m.current=window.setTimeout(()=>{h.current=``,g.current=_.current,S(!1)},u);let a=g.current,o=t(r,[...r.slice((a||0)+1),...r.slice(0,(a||0)+1)],h.current);o===-1?e.key!==` `&&(h.current=``,S(!1)):(v(o),_.current=o)},w=(0,V.useMemo)(()=>({onKeyDown:C}),[n,c]),T=(0,V.useMemo)(()=>({onKeyDown:C,onKeyUp(e){e.key===` `&&S(!1)}}),[n,c]);return(0,V.useMemo)(()=>c?{reference:w,floating:T}:{},[c,w,T])}var Ns=e(o(),1);function Ps(e,t){let{open:n,elements:r}=e,{enabled:i=!0,overflowRef:a,scrollRef:o,onChange:s}=t,c=f(s),l=V.useRef(!1),u=V.useRef(null),d=V.useRef(null);V.useEffect(()=>{if(!i)return;function e(e){if(e.ctrlKey||!t||a.current==null)return;let n=e.deltaY,r=a.current.top>=-.5,i=a.current.bottom>=-.5,o=t.scrollHeight-t.clientHeight,s=n<0?-1:1,l=n<0?`max`:`min`;t.scrollHeight<=t.clientHeight||(!r&&n>0||!i&&n<0?(e.preventDefault(),Ns.flushSync(()=>{c(e=>e+Math[l](n,o*s))})):/firefox/i.test(navigator.userAgent)&&(t.scrollTop+=n))}let t=o?.current||r.floating;if(n&&t)return t.addEventListener(`wheel`,e),requestAnimationFrame(()=>{u.current=t.scrollTop,a.current!=null&&(d.current={...a.current})}),()=>{u.current=null,d.current=null,t.removeEventListener(`wheel`,e)}},[i,n,r.floating,a,o,c]);let p=V.useMemo(()=>({onKeyDown(){l.current=!0},onWheel(){l.current=!1},onPointerMove(){l.current=!1},onScroll(){let e=o?.current||r.floating;if(a.current&&e&&l.current){if(u.current!==null){let t=e.scrollTop-u.current;(a.current.bottom<-.5&&t<-1||a.current.top<-.5&&t>1)&&Ns.flushSync(()=>c(e=>e+t))}requestAnimationFrame(()=>{u.current=e.scrollTop})}}}),[r.floating,c,a,o]);return V.useMemo(()=>i?{floating:p}:{},[i,p])}function Fs(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}var Is=e=>({name:`inner`,options:e,async fn(t){let{listRef:n,overflowRef:r,onFallbackChange:i,offset:a=0,index:o=0,minItemsVisible:s=4,referenceOverflowThreshold:c=0,scrollRef:l,padding:u=0}=e,{rects:d,elements:{floating:f}}=t,p=n.current?.[o??0],m=l?.current||f,h=f.clientTop||m.clientTop,g=f.clientTop!==0,_=m.clientTop!==0,v=f===m;if(!p||o==null)return i?.(!0),{};let y={...t,...await ut(-p.offsetTop-f.clientTop-d.reference.height/2-p.offsetHeight/2-a).fn(t)},b={padding:u},x=await nt(Fs(y,m.scrollHeight+h+f.clientTop),b),S=await nt(y,{...b,elementContext:`reference`}),C=Math.max(0,x.top),w=y.y+C,T=(m.scrollHeight>m.clientHeight?e=>e:Math.round)(Math.max(0,m.scrollHeight+(g&&v||_?h*2:0)-C-Math.max(0,x.bottom)));if(m.style.maxHeight=`${T}px`,m.scrollTop=C,i){let e=m.offsetHeight<p.offsetHeight*Math.min(s,n.current?.length??0)-1||S.top>=-c||S.bottom>=-c;Ns.flushSync(()=>i(e))}return r&&(r.current=await nt(Fs({...y,y:w},m.offsetHeight+h+f.clientTop),b)),{y:w}}}),Ls=`rovingFocusGroup.onEntryFocus`,Rs={bubbles:!1,cancelable:!0},zs=V.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,asChild:u,...d}=e,p=V.useRef(null),m=he(t,p),h=no(a),[g=null,_]=et({prop:o,defaultProp:s??null,onChange:c}),[v,y]=V.useState(!1),b=f(l),x=Ws(n||qs),S=V.useRef(!1),[C,T]=V.useState(0),E=u?_e:w;return(0,H.jsx)(Gs,{scope:n,orientation:r,dir:h,loop:i,currentTabStopId:g,onItemFocus:V.useCallback(e=>_(e),[_]),onItemShiftTab:V.useCallback(()=>y(!0),[]),onFocusableItemAdd:V.useCallback(()=>T(e=>e+1),[]),onFocusableItemRemove:V.useCallback(()=>T(e=>e-1),[]),children:(0,H.jsx)(E,{tabIndex:v||C===0?-1:0,"data-orientation":r,...d,ref:m,outlineStyle:`none`,onMouseDown:I(e.onMouseDown,()=>{S.current=!0}),onFocus:I(e.onFocus,e=>{let t=!S.current;if(e.target===e.currentTarget&&t&&!v){let e=new CustomEvent(Ls,Rs);if(b(e),!e.defaultPrevented){let e=x().filter(e=>e.focusable);Qs([e.find(e=>e.active),e.find(e=>e.id===g),...e].filter(Boolean).map(e=>e.ref.current),{focusVisible:!1})}}S.current=!1}),onBlur:I(e.onBlur,()=>y(!1))})})}),Bs=`RovingFocusGroupItem`,Vs=V.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,...o}=e,s=V.useId(),c=a||s,l=Ks(n);l.currentTabStopId;let u=Ws(n||qs),{onFocusableItemAdd:d,onFocusableItemRemove:f}=l;return V.useEffect(()=>{if(r)return d(),()=>f()},[r,d,f]),(0,H.jsx)(Us.ItemSlot,{scope:n||qs,id:c,focusable:r,active:i,children:(0,H.jsx)(w,{tabIndex:r?0:-1,"data-orientation":l.orientation,...o,ref:t,onMouseDown:I(e.onMouseDown,e=>{r?l.onItemFocus(c):e.preventDefault()}),onFocus:I(e.onFocus,()=>l.onItemFocus(c)),onKeyDown:I(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){l.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=Zs(e,l.orientation,l.dir);if(t!==void 0){e.preventDefault();let n=u().filter(e=>e.focusable).map(e=>e.ref.current);if(t===`last`)n.reverse();else if(t===`prev`||t===`next`){t===`prev`&&n.reverse();let r=n.indexOf(e.currentTarget);n=l.loop?$s(n,r+1):n.slice(r+1)}setTimeout(()=>Qs(n,{focusVisible:!0}))}})})})});Vs.displayName=Bs;var Hs=`RovingFocusGroup`,[Us,Ws]=$a(Hs),{Provider:Gs,useStyledContext:Ks}=S(),qs=`RovingFocusGroupContext`,Js=oe(V.forwardRef((e,t)=>(0,H.jsx)(Us.Provider,{scope:e.__scopeRovingFocusGroup||qs,children:(0,H.jsx)(Us.Slot,{scope:e.__scopeRovingFocusGroup||qs,children:(0,H.jsx)(zs,{...e,ref:t})})})),{Item:Vs});Js.displayName=Hs;var Ys={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function Xs(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}function Zs(e,t,n){let r=Xs(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return Ys[r]}function Qs(e,t){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({focusVisible:t?.focusVisible}),document.activeElement!==n))return}function $s(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var ec=M(n,{name:`MenuGroup`,variants:{unstyled:{false:{role:`group`,width:`100%`,borderRadius:0,borderWidth:0,borderColor:`$borderColor`,overflow:`hidden`,backgroundColor:`$background`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),tc=M(a,{name:`MenuLabel`,variants:{unstyled:{false:{cursor:`default`,color:`$color`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),nc=M(n,{name:`MenuSeparator`,role:`separator`,"aria-orientation":`horizontal`,variants:{unstyled:{false:{borderColor:`$borderColor`,flexShrink:0,borderWidth:0,height:1,marginVertical:3,marginHorizontal:10,backgroundColor:`$borderColor`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),rc={MenuIcon:M(n,{name:`MenuIcon`,variants:{unstyled:{false:{width:20,height:20,alignItems:`center`,justifyContent:`center`,marginLeft:`auto`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),MenuImage:M(lo,{name:`MenuImage`}),MenuIndicator:M(n,{name:`MenuIndicator`,variants:{unstyled:{false:{justifyContent:`center`,alignItems:`center`,marginLeft:`auto`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),MenuItem:M(n,{name:`MenuItem`,variants:{unstyled:{false:{flexDirection:`row`,width:`100%`,alignItems:`center`,cursor:`pointer`,borderRadius:6,paddingVertical:4,paddingHorizontal:8,focusStyle:{backgroundColor:`$backgroundHover`},pressStyle:{backgroundColor:`$backgroundPress`}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),Title:M(a,{name:`MenuTitle`,variants:{unstyled:{false:{cursor:`default`,color:`$color`,flexGrow:1,flexShrink:1}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),SubTitle:M(a,{name:`MenuSubTitle`,variants:{unstyled:{false:{cursor:`default`,color:`$colorFaint`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),MenuGroup:ec,MenuSeparator:nc,MenuLabel:tc};function ic(e){return t=>t.pointerType===`mouse`?e(t):void 0}var ac=[`Enter`,` `],oc=[`ArrowDown`,`PageUp`,`Home`],sc=[`ArrowUp`,`PageDown`,`End`],cc=[...oc,...sc],lc={ltr:[...ac,`ArrowRight`],rtl:[...ac,`ArrowLeft`]},uc={ltr:[`ArrowLeft`],rtl:[`ArrowRight`]},dc=`Menu`,[fc,pc]=$a(dc),{Provider:mc,useStyledContext:hc}=S(),{Provider:gc,useStyledContext:_c}=S(),vc=`MenuContext`;function yc({Item:e=rc.MenuItem,Title:t=rc.Title,SubTitle:r=rc.SubTitle,Image:i=rc.MenuImage,Icon:a=rc.MenuIcon,Indicator:o=rc.MenuIndicator,Separator:s=rc.MenuSeparator,MenuGroup:c=rc.MenuGroup,Label:l=rc.MenuLabel}){let u=e=>{let t=no(e.dir),n=t===`rtl`?`bottom-end`:`bottom-start`,{scope:r=vc,open:i=!1,children:a,dir:o,onOpenChange:s,modal:c=!0,allowFlip:l={padding:10},stayInFrame:u={padding:10},placement:d=n,resize:f=!0,offset:p=10,...m}=e,[h,g]=V.useState(null),_=V.useRef(!1),v=zn(s);return V.useEffect(()=>{let e=()=>{_.current=!0,document.addEventListener(`pointerdown`,t,{capture:!0,once:!0}),document.addEventListener(`pointermove`,t,{capture:!0,once:!0})},t=()=>_.current=!1;return document.addEventListener(`keydown`,e,{capture:!0}),()=>{document.removeEventListener(`keydown`,e,{capture:!0}),document.removeEventListener(`pointerdown`,t,{capture:!0}),document.removeEventListener(`pointermove`,t,{capture:!0})}},[]),(0,H.jsx)($e,{scope:r,open:i,placement:d,allowFlip:l,stayInFrame:u,resize:f,offset:p,...m,children:(0,H.jsx)(mc,{scope:r,open:i,onOpenChange:v,content:h,onContentChange:g,children:(0,H.jsx)(gc,{scope:r,open:i,onClose:V.useCallback(()=>v(!1),[v]),isUsingKeyboardRef:_,dir:t,modal:c,children:(0,H.jsx)(fe,{scope:r,children:a})})})})},d=e=>{let{scope:t=vc,menuContext:n,rootContext:r,popperContext:i,menuSubContext:a,children:o}=e;return(0,H.jsx)(fn,{...i,scope:t,children:(0,H.jsx)(mc,{scope:t,...n,children:(0,H.jsx)(gc,{scope:t,...r,children:a?(0,H.jsx)(fe,{scope:t,...a,children:o}):o})})})};u.displayName=dc;let f=e=>(0,H.jsx)(on,{scope:vc,...e});f.displayName=`MenuAnchor`;let{Provider:p,useStyledContext:m}=S(void 0,`Portal`),h=e=>{let{scope:t=vc,forceMount:r,zIndex:i,children:a}=e,o=hc(t),s=_c(t),c=en(t),l=pe(t),u=dn(),f=(0,H.jsx)(se,{forceClassName:!0,name:u,children:a}),m=bt()?(0,H.jsx)(d,{menuContext:o,rootContext:s,popperContext:c,menuSubContext:l,scope:t,children:f}):f,h=r||s.open&&o.open;return(0,H.jsx)(gt,{type:`presence`,present:h,children:(0,H.jsx)(Jt,{stackZIndex:!0,children:(0,H.jsx)(H.Fragment,{children:(0,H.jsx)(p,{scope:t,forceMount:r,children:(0,H.jsxs)(n,{zIndex:i||100,inset:0,position:`absolute`,children:[!!o.open&&!1,m]})})})})})};h.displayName=`MenuPortal`;let g=`MenuContent`,{Provider:_,useStyledContext:v}=S(),y=M(Dn,{name:g}).styleable((e,t)=>{let n=e.scope||vc,r=m(n),{forceMount:i=r.forceMount,...a}=e,o=_c(n);return(0,H.jsx)(fc.Provider,{scope:n,children:(0,H.jsx)(fc.Slot,{scope:n,children:o.modal?(0,H.jsx)(b,{...a,ref:t}):(0,H.jsx)(x,{...a,ref:t})})})}),b=V.forwardRef((e,t)=>{let n=e.scope||vc,r=hc(n),i=V.useRef(null),a=he(t,i);return(0,H.jsx)(C,{...e,scope:n,ref:a,trapFocus:r.open,disableOutsidePointerEvents:r.open,disableOutsideScroll:!1,onFocusOutside:I(e.onFocusOutside,e=>e.preventDefault(),{checkDefaultPrevented:!1}),onDismiss:()=>r.onOpenChange(!1)})}),x=V.forwardRef((e,t)=>{let n=e.scope||vc,r=hc(n);return(0,H.jsx)(C,{...e,scope:n,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>r.onOpenChange(!1)})}),C=V.forwardRef((e,t)=>{let{scope:n=vc,loop:r=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,disableDismissOnScroll:h=!1,unstyled:g={}.GUI_HEADLESS===`1`,...v}=e,y=hc(n),b=_c(n),x=en(n),S=pc(n),[C,w]=V.useState(null),T=V.useRef(null),E=V.useRef(null),D=he(t,T,y.onContentChange),O=V.useRef(0),k=V.useRef(``),A=V.useRef(0),j=V.useRef(null),ee=V.useRef(`right`),M=V.useRef(0),N=e=>{let t=k.current+e,n=S().filter(e=>!e.disabled),r=document.activeElement,i=n.find(e=>e.ref.current===r)?.textValue,a=Tc(n.map(e=>e.textValue),t,i),o=n.find(e=>e.textValue===a)?.ref.current;(function e(t){k.current=t,clearTimeout(O.current),t!==``&&(O.current=setTimeout(()=>e(``),1e3))})(t),o&&setTimeout(()=>o.focus())};V.useEffect(()=>()=>clearTimeout(O.current),[]),V.useEffect(()=>{if(!y.open)return;let e=requestAnimationFrame(()=>{let e=T.current?.querySelector(`[data-hanzogui-menu-content]`);e&&(E.current=e)});return()=>cancelAnimationFrame(e)},[y.open]),V.useEffect(()=>{if(h||!y.open)return;let e=e=>{let t=e.target;if(!t||T.current?.contains(t))return;let n=x.refs?.reference?.current,r=n instanceof Element?n:n?.contextElement??null;(!r||t.contains(r))&&p?.()};return window.addEventListener(`scroll`,e,{capture:!0,passive:!0}),()=>{window.removeEventListener(`scroll`,e,{capture:!0})}},[h,y.open,p,x.refs]),gs();let P=V.useCallback(e=>{let t=ee.current===j.current?.side,n=Dc(e,j.current?.area);return t&&n},[]),te=(0,H.jsx)(yn,{role:`menu`,tabIndex:-1,unstyled:g,...!g&&{backgroundColor:`$background`,borderWidth:1,borderColor:`$borderColor`,outlineWidth:0,minWidth:180},"aria-orientation":`vertical`,"data-state":bc(y.open),"data-hanzogui-menu-content":``,dir:b.dir,scope:n||vc,...v,ref:D,className:v.transition?void 0:v.className,onKeyDown:I(v.onKeyDown,e=>{let t=e.target.closest(`[data-hanzogui-menu-content]`)===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=e.key.length===1;t&&(e.key===`Tab`&&e.preventDefault(),!n&&r&&N(e.key));let i=e.target.hasAttribute(`data-hanzogui-menu-content`);if(!t||!i||!cc.includes(e.key))return;e.preventDefault();let a=S().filter(e=>!e.disabled).map(e=>e.ref.current);sc.includes(e.key)&&a.reverse(),Cc(a,{focusVisible:!0})}),onBlur:I(e.onBlur,e=>{e.currentTarget?.contains(e.target)||(clearTimeout(O.current),k.current=``)}),onPointerMove:I(e.onPointerMove,e=>{if(e.pointerType!==`mouse`)return;let t=e.target,n=M.current!==e.clientX;if(e.currentTarget?.contains(t)&&n){let t=e.clientX>M.current?`right`:`left`;ee.current=t,M.current=e.clientX}})});return(0,H.jsx)(_,{scope:n,searchRef:k,onItemEnter:V.useCallback(e=>{P(e)&&e.preventDefault()},[P]),onItemLeave:V.useCallback(e=>{P(e)||(E.current?.focus(),w(null))},[P]),onTriggerLeave:V.useCallback(e=>{P(e)&&e.preventDefault()},[P]),pointerGraceTimerRef:A,onPointerGraceIntentChange:V.useCallback(e=>{j.current=e},[]),children:(0,H.jsx)(jt,{enabled:m,children:(0,H.jsx)(ft,{asChild:!1,trapped:i,onMountAutoFocus:I(a,e=>{e.preventDefault(),document.querySelector(`[data-hanzogui-menu-content]`)?.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:(0,H.jsx)(Ct,{disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,asChild:!0,children:(0,H.jsx)(Js,{asChild:!0,__scopeRovingFocusGroup:n||vc,dir:b.dir,orientation:`vertical`,loop:r,currentTabStopId:C,onCurrentTabStopIdChange:w,onEntryFocus:I(c,e=>{b.isUsingKeyboardRef.current||e.preventDefault()}),children:te})})})})})});y.displayName=g;let w=`MenuItem`,E=`menu.itemSelect`,D=e.styleable((e,t)=>{let{disabled:n=!1,onSelect:r,preventCloseOnSelect:i,children:a,scope:o=vc,destructive:s,hidden:c,androidIconName:l,iosIconName:u,...d}=e,f=V.useRef(null),p=_c(o),m=v(o),h=he(t,f),g=V.useRef(!1),_=()=>{let e=f.current;if(!n&&e){let t=e,n=new CustomEvent(E,{bubbles:!0,cancelable:!0});t.addEventListener(E,e=>r?.(e),{once:!0}),Pt(t,n),n.defaultPrevented||i?g.current=!1:p.onClose()}},y=typeof a==`string`?(0,H.jsx)(T,{children:a}):a;return(0,H.jsx)(O,{outlineStyle:`none`,...d,scope:o,ref:h,disabled:n,onPress:I(e.onPress,_),onPointerDown:t=>{e.onPointerDown?.(t),g.current=!0},onPointerUp:I(e.onPointerUp,e=>{g.current||e.currentTarget?.click()}),onKeyDown:I(e.onKeyDown,e=>{let t=m.searchRef.current!==``;n||t&&e.key===` `||ac.includes(e.key)&&(e.currentTarget?.click(),e.preventDefault())}),children:y})}),O=V.forwardRef((t,n)=>{let{scope:r=vc,disabled:i=!1,textValue:a,unstyled:o={}.GUI_HEADLESS===`1`,...s}=t,c=v(r),l=V.useRef(null),u=he(n,l),[d,f]=V.useState(!1),[p,m]=V.useState(``);return V.useEffect(()=>{let e=l.current;e&&m((e.textContent??``).trim())},[s.children]),(0,H.jsx)(fc.ItemSlot,{scope:r,disabled:i,textValue:a??p,children:(0,H.jsx)(Js.Item,{asChild:!0,__scopeRovingFocusGroup:r,focusable:!i,children:(0,H.jsx)(e,{unstyled:o,componentName:w,role:`menuitem`,"data-highlighted":d?``:void 0,"aria-disabled":i||void 0,"data-disabled":i?``:void 0,...s,ref:u,onPointerMove:I(t.onPointerMove,e=>{e.pointerType===`mouse`&&(i?c.onItemLeave(e):(c.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0,focusVisible:!1})))}),onPointerLeave:I(t.onPointerLeave,e=>{c.onItemLeave(e)}),onFocus:I(t.onFocus,()=>f(!0)),onBlur:I(t.onBlur,()=>f(!1))})})})});D.displayName=w;let k=t.styleable((e,n)=>(0,H.jsx)(t,{...e,ref:n}));k.displayName=`MenuItemTitle`;let A=r.styleable((e,t)=>(0,H.jsx)(r,{...e,ref:t}));A.displayName=`MenuItemSubTitle`;let j=V.forwardRef((e,t)=>{let{ios:n,androidIconName:r,iosIconName:a,...o}=e;return(0,H.jsx)(i,{...o,ref:t})});j.displayName=`MenuItemImage`;let ee=a.styleable((e,t)=>{let{ios:n,android:r,androidIconName:i,iosIconName:o,...s}=e;return(0,H.jsx)(a,{...s,ref:t})});ee.displayName=`MenuItemIcon`;let N=`MenuCheckboxItem`,P=e.styleable((e,t)=>{let{checked:n=!1,onCheckedChange:r,scope:i=vc,value:a,onValueChange:o,...s}=e;return(0,H.jsx)(R,{scope:i,checked:n,children:(0,H.jsx)(D,{componentName:N,role:`menuitemcheckbox`,"aria-checked":xc(n)?`mixed`:n,...s,scope:i,ref:t,"data-state":Sc(n),onSelect:I(s.onSelect,()=>r?.(xc(n)?!0:!n),{checkDefaultPrevented:!1})})})});P.displayName=N;let te=`MenuRadioGroup`,{Provider:F,useStyledContext:ne}=S(),re=c.styleable((e,t)=>{let{value:n,onValueChange:r,scope:i=vc,...a}=e,o=zn(r);return(0,H.jsx)(F,{scope:i,value:n,onValueChange:o,children:(0,H.jsx)(c,{componentName:te,...a,ref:t})})});re.displayName=te;let ie=`MenuRadioItem`,L=e.styleable((e,t)=>{let{value:n,scope:r=vc,...i}=e,a=ne(r),o=n===a.value;return(0,H.jsx)(R,{scope:r,checked:o,children:(0,H.jsx)(D,{componentName:ie,...i,scope:r,"aria-checked":o,ref:t,role:`menuitemradio`,"data-state":Sc(o),onSelect:I(i.onSelect,()=>a.onValueChange?.(n),{checkDefaultPrevented:!1})})})});L.displayName=ie;let ae=`MenuItemIndicator`,{Provider:R,useStyledContext:ce}=S(),ue=o.styleable((e,t)=>{let{scope:n=vc,forceMount:r,...i}=e,a=ce(n);return(0,H.jsx)(kn,{children:r||xc(a.checked)||a.checked===!0?(0,H.jsx)(o,{componentName:ae,render:`span`,...i,ref:t,"data-state":Sc(a.checked)}):null})});ue.displayName=ae;let de=V.forwardRef(function(e,t){let{scope:n=vc,unstyled:r={}.GUI_HEADLESS===`1`,...i}=e;return(0,H.jsx)(An,{scope:n,componentName:`PopperArrow`,unstyled:r,...!r&&{backgroundColor:`$background`},...i,ref:t})}),{Provider:fe,useStyledContext:pe}=S(),me=e=>{let t=Za(),{scope:n=vc}=e,r=_c(n),i=en(n).placement?.split(`-`)[0],a=i===`left`||i===`right`,o=t?`bottom`:a?`${i}-start`:r.dir===`rtl`?`left-start`:`right-start`,{children:s,open:c=!1,onOpenChange:l,allowFlip:u={padding:10},stayInFrame:d={padding:10},placement:f=o,...p}=e,m=V.useMemo(()=>{if(!a||typeof u==`boolean`||u.fallbackPlacements)return u;let e=f.split(`-`)[0],t=f.split(`-`)[1]||`start`,n=t===`start`?`end`:`start`;if(e===`left`||e===`right`){let r=e===`right`?`left`:`right`;return{...typeof u==`object`?u:{},fallbackPlacements:[`${e}-${n}`,`${r}-${t}`,`${r}-${n}`]}}return u},[a,u,f]),h=hc(n),[g,_]=V.useState(null),[v,y]=V.useState(null),b=zn(l);return V.useEffect(()=>(h.open===!1&&b(!1),()=>b(!1)),[h.open,b]),(0,H.jsx)($e,{open:c,placement:f,allowFlip:m,stayInFrame:d,...p,scope:n,children:(0,H.jsx)(mc,{scope:n,open:c,onOpenChange:b,content:v,onContentChange:y,children:(0,H.jsx)(fe,{scope:n,contentId:(0,V.useId)(),triggerId:(0,V.useId)(),trigger:g,onTriggerChange:_,children:s})})})};me.displayName=`MenuSub`;let ge=`MenuSubTrigger`,_e=V.forwardRef((e,t)=>{let n=e.scope||vc,r=hc(n),i=_c(n),a=pe(n),o=v(n),s=en(n),c=V.useRef(null),{pointerGraceTimerRef:l,onPointerGraceIntentChange:u}=o,d=i.dir,p=V.useCallback(()=>{c.current&&window.clearTimeout(c.current),c.current=null},[]);return V.useEffect(()=>p,[p]),V.useEffect(()=>{let e=l.current;return()=>{window.clearTimeout(e),u(null)}},[l,u]),(0,H.jsx)(f,{componentName:ge,asChild:`except-style`,scope:n,children:(0,H.jsx)(O,{id:a.triggerId,"aria-haspopup":`menu`,"aria-expanded":r.open,"aria-controls":a.contentId,"data-state":bc(r.open),outlineStyle:`none`,...e,ref:le(t,a.onTriggerChange),onPress:t=>{e.onPress?.(t),!(e.disabled||t.defaultPrevented)&&(t.currentTarget.focus(),r.open||r.onOpenChange(!0))},onPointerMove:I(e.onPointerMove,ic(t=>{o.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!r.open&&!c.current&&(o.onPointerGraceIntentChange(null),c.current=window.setTimeout(()=>{r.onOpenChange(!0),p()},100))})),onPointerLeave:I(e.onPointerLeave,e=>{let t=e;p();let n=r.content?.getBoundingClientRect();if(n){let e=r.content,i=(e?.dataset?.side?e:e?.querySelector(`[data-side]`))?.dataset?.side||`right`,a=i===`right`,s=a?-5:5,c=n[a?`left`:`right`],u=n[a?`right`:`left`],d={area:[{x:t.clientX+s,y:t.clientY},{x:c,y:n.top},{x:u,y:n.top},{x:u,y:n.bottom},{x:c,y:n.bottom}],side:i};o.onPointerGraceIntentChange(d),window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.onPointerGraceIntentChange(null),300)}else if(a.trigger){let e=a.trigger?.getBoundingClientRect();if(e){let n=s.placement?.split(`-`)[0],r=n===`left`||n===`right`?n:i.dir===`rtl`?`left`:`right`,a=r===`right`,c=a?-5:5,u=a?e.right+4:e.left-4,d=a?u+200:u-200,f={area:[{x:t.clientX+c,y:t.clientY},{x:u,y:e.top-50},{x:d,y:e.top-50},{x:d,y:e.bottom+50},{x:u,y:e.bottom+50}],side:r};o.onPointerGraceIntentChange(f),window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.onPointerGraceIntentChange(null),300)}}else{if(o.onTriggerLeave(t),t.defaultPrevented)return;o.onPointerGraceIntentChange(null)}}),onKeyDown:I(e.onKeyDown,t=>{let n=o.searchRef.current!==``;if(!(e.disabled||n&&t.key===` `)&&lc[d].includes(t.key)){if(r.open&&r.content){let e=r.content.querySelector?.(`[role="menuitem"]:not([data-disabled])`);if(e){e.focus({focusVisible:!0}),t.preventDefault();return}}let e=t.currentTarget;s.refs?.setReference(e),r.onOpenChange(!0),requestAnimationFrame(()=>{s.update?.()}),r.content?.focus({focusVisible:!0}),t.preventDefault()}})})})});_e.displayName=ge;let ve=`MenuSubContent`,ye=M(Dn,{name:ve}).styleable((e,t)=>{let n=e.scope||vc,r=m(n),{forceMount:i=r.forceMount,...a}=e,o=hc(n),s=_c(n),c=pe(n),l=en(n),u=V.useRef(null),d=he(t,u),f=l.placement?.split(`-`)[0],p=f===`left`||f===`right`?f:s.dir===`rtl`?`left`:`right`,h=s.dir;return(0,H.jsx)(fc.Provider,{scope:n,children:(0,H.jsx)(fc.Slot,{scope:n,children:(0,H.jsx)(C,{id:c.contentId,"aria-labelledby":c.triggerId,...a,ref:d,"data-side":p,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{if(s.isUsingKeyboardRef.current){let e=u.current;(e?.querySelector?.(`[data-hanzogui-menu-content]`)||e)?.focus({preventScroll:!0})}e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:I(e.onFocusOutside,e=>{e.target!==c.trigger&&o.onOpenChange(!1)}),onEscapeKeyDown:I(e.onEscapeKeyDown,e=>{o.onOpenChange(!1),c.trigger?.focus({focusVisible:!0}),e.preventDefault()}),onKeyDown:I(e.onKeyDown,e=>{let t=e.currentTarget.contains(e.target),n=uc[h].includes(e.key);t&&n&&(o.onOpenChange(!1),c.trigger?.focus({focusVisible:!0}),e.preventDefault())})})})})});ye.displayName=ve;let be=f,xe=h,Se=y,z=c.styleable((e,t)=>(0,H.jsx)(c,{...e,ref:t}));z.displayName=`MenuGroup`;let Ce=l.styleable((e,t)=>(0,H.jsx)(l,{...e,ref:t}));Ce.displayName=`MenuLabel`;let we=D,Te=P,Ee=re,De=L,Oe=ue,ke=s.styleable((e,t)=>(0,H.jsx)(s,{...e,ref:t}));return ke.displayName=`MenuSeparator`,{Menu:oe(u,{Anchor:be,Portal:xe,Content:Se,Group:z,Label:Ce,Item:we,CheckboxItem:Te,RadioGroup:Ee,RadioItem:De,ItemIndicator:Oe,Separator:ke,Arrow:de,Sub:me,SubTrigger:_e,SubContent:ye,ItemTitle:k,ItemSubtitle:A,ItemImage:j,ItemIcon:ee})}}function bc(e){return e?`open`:`closed`}function xc(e){return e===`indeterminate`}function Sc(e){return xc(e)?`indeterminate`:e?`checked`:`unchecked`}function Cc(e,t){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:!0,focusVisible:t?.focusVisible}),document.activeElement!==n))return}function wc(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function Tc(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=wc(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}function Ec(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e].x,s=t[e].y,c=t[a].x,l=t[a].y;s>r!=l>r&&n<(c-o)*(r-s)/(l-s)+o&&(i=!i)}return i}function Dc(e,t){return t?Ec({x:e.clientX,y:e.clientY},t):!1}var Oc=(()=>null);function kc(){return{Menu:oe(Oc,{Trigger:Oc,Content:Oc,Item:Oc,ItemTitle:Oc,ItemSubtitle:Oc,SubTrigger:Oc,Group:Oc,ItemIcon:Oc,Separator:Oc,CheckboxItem:Oc,ItemIndicator:Oc,ItemImage:Oc,Label:Oc,Arrow:Oc,Sub:Oc,SubContent:Oc,Preview:Oc,Portal:Oc,RadioGroup:Oc,RadioItem:Oc,Auxiliary:Oc})}}var Ac=e=>kc();function jc({Component:e,NativeComponent:t}){return e}var Mc=`MenuContext`;function Nc(e){let t=V.useRef(new Map),n=V.useRef(null),r=f(r=>{let i=n.current;i!==r&&(i&&t.current.get(i)?.(!1),n.current=r,r&&e&&t.current.get(r)?.(!0))}),i=f((r,i)=>{t.current.set(r,i),i(n.current===r&&e)}),a=f(e=>{t.current.delete(e),n.current===e&&(n.current=null)});return V.useEffect(()=>{if(!e){r(null);return}let i=n.current;i&&t.current.get(i)?.(!0)},[e,r]),{setActiveTrigger:r,registerTrigger:i,unregisterTrigger:a}}function Pc(e){let{Menu:t}=yc(e),{Provider:r,useStyledContext:i}=S(),a=e=>{let{scope:n,children:i,dir:a,open:o,defaultOpen:s,onOpenChange:c,modal:l=!0,...u}=e,d=V.useRef(null),[f=!1,p]=et({prop:o,defaultProp:s,onChange:c}),m=V.useRef(f);m.current=f;let{setActiveTrigger:h,registerTrigger:g,unregisterTrigger:_}=Nc(f);return(0,H.jsx)(r,{scope:n,triggerId:(0,V.useId)(),triggerRef:d,contentId:(0,V.useId)(),openRef:m,onOpenChange:V.useCallback(e=>p(e),[p]),onOpenToggle:V.useCallback(()=>p(e=>!e),[p]),modal:l,setActiveTrigger:h,registerTrigger:g,unregisterTrigger:_,children:(0,H.jsx)(t,{scope:n||`MenuContext`,open:f,onOpenChange:p,dir:a,modal:l,...u,children:i})})};a.displayName=`Menu`;let o=`MenuTrigger`,s=t.Anchor,c=n.styleable((e,t)=>{let{scope:r,asChild:a,children:c,disabled:l=!1,onKeydown:u,...d}=e,f=i(r),p=xn(r||`MenuContext`),m=a?_e:n,h=Za(),g=V.useRef(null),_=V.useId(),[v,y]=V.useState(!1),{registerTrigger:b,unregisterTrigger:x}=f;V.useEffect(()=>(b(_,y),()=>x(_)),[b,x,_]);let S=V.useCallback(()=>{f.setActiveTrigger(_);let e=g.current;e&&(f.triggerRef.current=e,e instanceof HTMLElement&&(p.refs?.setReference(e),requestAnimationFrame(()=>p.update?.())))},[f,_,p]),C=h?`onClick`:`onPointerDown`;return(0,H.jsx)(s,{asChild:!0,componentName:o,scope:r||`MenuContext`,children:(0,H.jsx)(m,{role:`button`,id:f.triggerId,"aria-haspopup":`menu`,"aria-expanded":v,"aria-controls":v?f.contentId:void 0,"data-state":v?`open`:`closed`,"data-disabled":l?``:void 0,"aria-disabled":l||void 0,ref:le(t,f.triggerRef,g),[C]:I(e[C],e=>{if(!l){if(e instanceof PointerEvent&&e.button!==0&&e.ctrlKey===!0)return;f.openRef.current?f.setActiveTrigger(null):S(),f.onOpenToggle(),f.openRef.current||e.preventDefault()}}),onKeyDown:I(u,e=>{l||([`Enter`,` `].includes(e.key)&&(f.openRef.current?f.setActiveTrigger(null):S(),f.onOpenToggle()),e.key===`ArrowDown`&&(S(),f.onOpenChange(!0)),[`Enter`,` `,`ArrowDown`].includes(e.key)&&e.preventDefault())}),...d,children:c})})});c.displayName=o;let l=e=>{let{scope:n,children:a,...o}=e,s=Se?i(n):null,c=Se?(0,H.jsx)(r,{...s,children:a}):a;return(0,H.jsx)(t.Portal,{scope:n||`MenuContext`,...o,children:c})};l.displayName=`MenuPortal`;let u=V.forwardRef((e,n)=>{let{scope:r,...a}=e,o=i(r),s=V.useRef(!1);return(0,H.jsx)(t.Content,{id:o.contentId,"aria-labelledby":o.triggerId,scope:r||`MenuContext`,...a,ref:n,onCloseAutoFocus:I(e.onCloseAutoFocus,e=>{s.current||requestAnimationFrame(()=>{let e=document.activeElement;(!e||e===document.body)&&o.triggerRef.current?.focus()}),s.current=!1,e.preventDefault()}),onInteractOutside:I(e.onInteractOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;(!o.modal||r)&&(s.current=!0)}),style:{...e.style,"--hanzogui-menu-content-transform-origin":`var(--hanzogui-popper-transform-origin)`,"--hanzogui-menu-content-available-width":`var(--hanzogui-popper-available-width)`,"--hanzogui-menu-content-available-height":`var(--hanzogui-popper-available-height)`,"--hanzogui-menu-trigger-width":`var(--hanzogui-popper-anchor-width)`,"--hanzogui-menu-trigger-height":`var(--hanzogui-popper-anchor-height)`}})});u.displayName=`MenuContent`;let d=e=>{let{scope:n,children:r,open:i,onOpenChange:a,defaultOpen:o,...s}=e,[c=!1,l]=et({prop:i,defaultProp:o,onChange:a});return(0,H.jsx)(t.Sub,{scope:n||`MenuContext`,open:c,onOpenChange:l,...s,children:r})};d.displayName=`MenuSub`;let f=V.forwardRef((e,n)=>{let{scope:r,...i}=e;return(0,H.jsx)(t.SubContent,{scope:r||`MenuContext`,...i,ref:n,style:{...e.style,"--hanzogui-menu-content-transform-origin":`var(--hanzogui-popper-transform-origin)`,"--hanzogui-menu-content-available-width":`var(--hanzogui-popper-available-width)`,"--hanzogui-menu-content-available-height":`var(--hanzogui-popper-available-height)`,"--hanzogui-menu-trigger-width":`var(--hanzogui-popper-anchor-width)`,"--hanzogui-menu-trigger-height":`var(--hanzogui-popper-anchor-height)`}})});f.displayName=`MenuSubContent`;let p=M(Mt,{flexShrink:1,alignSelf:`stretch`,showsHorizontalScrollIndicator:!1,showsVerticalScrollIndicator:!1,"$platform-web":{maxHeight:`var(--hanzogui-menu-content-available-height)`}}),m=t.Group,h=t.Label,g=t.Item,_=t.CheckboxItem,v=t.RadioGroup,y=t.RadioItem,b=t.ItemIndicator,x=t.Separator,C=t.Arrow,w=t.SubTrigger,T=t.ItemTitle,E=t.ItemSubtitle,D=t.ItemImage,O=t.ItemIcon;return oe(a,{Root:a,Trigger:c,Portal:l,Content:u,Group:m,Label:h,Item:g,CheckboxItem:_,RadioGroup:v,RadioItem:y,ItemIndicator:b,Separator:x,Arrow:C,Sub:d,SubTrigger:w,SubContent:f,ItemTitle:T,ItemSubtitle:E,ItemImage:D,ItemIcon:O,ScrollView:p})}function Fc(e){let{Menu:t}=Ac(`Menu`),n=Pc(e),r={isRoot:!1,scope:Mc},i=jc({...r,Component:n.Root,NativeComponent:t,isRoot:!0}),a=jc({...r,Component:n.Trigger,NativeComponent:t.Trigger}),o=jc({...r,Component:n.Portal,NativeComponent:V.Fragment}),s=jc({...r,Component:n.Content,NativeComponent:t.Content}),c=jc({...r,Component:n.Group,NativeComponent:t.Group}),l=jc({...r,Component:n.Label,NativeComponent:t.Label}),u=jc({...r,Component:n.Item,NativeComponent:t.Item}),d=jc({...r,Component:n.ItemTitle,NativeComponent:t.ItemTitle}),f=jc({...r,Component:n.ItemSubtitle,NativeComponent:t.ItemSubtitle}),p=jc({...r,Component:n.ItemIcon,NativeComponent:t.ItemIcon}),m=jc({...r,Component:n.ItemImage,NativeComponent:t.ItemImage}),h=jc({...r,Component:n.CheckboxItem,NativeComponent:t.CheckboxItem}),g=jc({...r,Component:n.RadioGroup,NativeComponent:({children:e})=>(0,H.jsx)(H.Fragment,{children:e})}),_=jc({...r,Component:n.RadioItem,NativeComponent:({children:e})=>(0,H.jsx)(H.Fragment,{children:e})}),v=jc({...r,Component:n.ItemIndicator,NativeComponent:t.ItemIndicator}),y=jc({...r,Component:n.Separator,NativeComponent:t.Separator}),b=jc({...r,Component:n.Arrow,NativeComponent:t.Arrow}),x=jc({...r,Component:n.Sub,NativeComponent:t.Sub}),S=jc({...r,Component:n.SubTrigger,NativeComponent:t.SubTrigger}),C=jc({...r,Component:n.SubContent,NativeComponent:t.SubContent}),w=n.ScrollView;return oe(i,{Trigger:a,Portal:o,Content:s,Group:c,Label:l,Item:u,CheckboxItem:h,RadioGroup:g,RadioItem:_,ItemIndicator:v,Separator:y,Arrow:b,Sub:x,SubTrigger:S,SubContent:C,ItemTitle:d,ItemSubtitle:f,ItemIcon:p,ItemImage:m,ScrollView:w})}var Ic=Fc({Icon:rc.MenuIcon,Image:rc.MenuImage,Indicator:rc.MenuIndicator,Item:rc.MenuItem,Label:rc.MenuLabel,MenuGroup:rc.MenuGroup,Separator:rc.MenuSeparator,SubTitle:rc.SubTitle,Title:rc.Title}),Lc=M(w,{name:`Separator`,variants:{unstyled:{false:{borderColor:`$borderColor`,flexShrink:0,borderWidth:0,flex:1,height:0,maxHeight:0,borderBottomWidth:1,y:-.5}},vertical:{true:{y:0,x:-.5,height:`initial`,maxHeight:`initial`,width:0,maxWidth:0,borderBottomWidth:0,borderRightWidth:1}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),Rc=(0,V.createContext)(void 0),{Provider:zc,useStyledContext:Bc}=S(null,`Select`),{Provider:Vc,useStyledContext:Hc}=S(null,`SelectItem`),Uc=({context:e,itemContext:t,children:n})=>$t().state.type===`teleport`?n:(0,H.jsx)(zc,{isInSheet:!0,scope:e.scopeName,...e,children:(0,H.jsx)(Vc,{scope:e.scopeName,...t,children:n})}),Wc=e=>{let t=St(e.adaptScope);return e.open!==!1&&t},Gc=({children:e,scope:t,...n})=>{let r=Bc(t),i=Hc(t),a=(0,V.useContext)(Rc),o=Wc(r),s=e;return i.shouldRenderWebNative?(0,H.jsx)(H.Fragment,{children:e}):o?r.open?(0,H.jsx)(H.Fragment,{children:s}):null:(0,H.jsx)(Jt,{open:r.open,zIndex:a,stackZIndex:1e5,children:(0,H.jsx)(jt,{enabled:r.open&&!r.disablePreventBodyScroll,children:(0,H.jsx)(Ct,{asChild:!0,forceUnmount:!r.open,onDismiss:()=>i.setOpen(!1),onFocusOutside:e=>e.preventDefault(),onPointerDownOutside:e=>e.preventDefault(),children:(0,H.jsx)(ft,{...n,enabled:!!r.open,trapped:!0,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:e=>{e.preventDefault();let t=r.floatingContext?.refs?.reference?.current;t instanceof HTMLElement&&t.focus()},children:(0,H.jsx)(`div`,{style:{display:`contents`},children:s})})})})})},Kc=`SelectViewport`,qc=e=>{let{scope:t,children:n,open:r=!1,listContentRef:i,setActiveIndexFast:a}=e,o=Bc(t),s=Hc(t),{setActiveIndex:c,selectedIndex:l,activeIndexRef:u}=o,{setOpen:d,setSelectedIndex:p}=s,[m,h]=V.useState(0),g=Za(),_=V.useRef([]),v=V.useRef(null),y=V.useRef(null),x=V.useRef(null),S=V.useRef(!1),C=V.useRef(!0),w=V.useRef(null),T=V.useRef({isMouseOutside:!1,isTyping:!1}),[E,D]=V.useState(!1),[O,k]=V.useState(!1),[A,j]=V.useState(0),[ee,M]=V.useState(!1),N=V.useRef({});V.useEffect(()=>{r?a(l??0):(h(0),k(!1),a(null),D(!1))},[r,l,a]),b(()=>{if(!r)return;let e=e=>{T.current.isMouseOutside&&d(!1)};return document.addEventListener(`mouseup`,e),()=>{document.removeEventListener(`mouseup`,e)}},[r]);let{x:P,y:te,strategy:F,refs:I,update:ne,placement:re}=kt({open:r,placement:`bottom-start`,whileElementsMounted:hn,middleware:[ct({apply({rects:{reference:{width:e}}}){Object.assign(N.current,{minWidth:e+8}),I.floating.current&&Object.assign(I.floating.current.style,N.current)}}),Is({listRef:_,overflowRef:v,index:l,offset:A,onFallbackChange:k,padding:10,minItemsVisible:g?10:4,referenceOverflowThreshold:20}),ut({crossAxis:-5})]}),ie=I.floating,L=r&&m>8,ae=r&&ie.current&&m<ie.current.scrollHeight-ie.current.clientHeight-8,oe=ae||L;b(()=>{if(!(typeof window>`u`))return window.addEventListener(`resize`,ne),r&&ne(),()=>window.removeEventListener(`resize`,ne)},[ne,r]);let R=f(e=>(r?c:p)(e)),se=V.useRef({});se.current.placement=re;let ce={open:r,onOpenChange:e=>d(e),refs:{reference:I.reference,floating:I.floating,domReference:I.reference},elements:{reference:I.reference?.current||null,floating:I.floating?.current||null,domReference:I.reference?.current||null},dataRef:se},le=[xs(ce,{event:`mousedown`,keyboardHandlers:!1}),gn(ce,{role:`listbox`}),Ps(ce,{enabled:!O&&oe,onChange:j,overflowRef:v,scrollRef:I.floating}),js(ce,{listRef:_,activeIndex:o.activeIndex??0,selectedIndex:l,onNavigate:e=>{e!==null&&c(e)},scrollItemIntoView:!1}),Ms(ce,{listRef:i,onMatch:R,selectedIndex:l,activeIndex:o.activeIndex,onTypingChange:e=>{T.current.isTyping=e}})],ue=Fn(V.useMemo(()=>le,le)),de=V.useMemo(()=>({...ue,getReferenceProps(){return ue.getReferenceProps({ref:I.reference,className:`SelectTrigger`,onKeyDown(e){(e.key===`Enter`||e.code===`Space`||e.key===` `&&!T.current.isTyping)&&(e.preventDefault(),d(!0))}})},getFloatingProps(e){return ue.getFloatingProps({ref:I.floating,className:`Select`,...e,style:{position:F,top:te??``,left:P??``,outline:0,scrollbarWidth:`none`,...N.current,...e?.style},onPointerEnter(){D(!1),T.current.isMouseOutside=!1},onPointerLeave(){T.current.isMouseOutside=!0},onPointerMove(){T.current.isMouseOutside=!1,D(!1)},onKeyDown(){D(!0)},onContextMenu(e){e.preventDefault()},onScroll(e){(0,Ns.flushSync)(()=>{h(e.currentTarget.scrollTop)})}})}}),[I.reference.current,P,te,I.floating.current,ue]);b(()=>{if(r)return C.current=!1,w.current=setTimeout(()=>{S.current=!0,C.current=!0},300),()=>{clearTimeout(w.current)};S.current=!1,C.current=!0,j(0),k(!1),M(!1)},[r]),b(()=>{!r&&T.current.isMouseOutside&&(T.current.isMouseOutside=!1)},[r]),b(()=>{function e(e){let t=e.target;I.floating.current?.contains(t)||y.current?.contains(t)||x.current?.contains(t)||(d(!1),D(!1))}if(r)return document.addEventListener(`pointerdown`,e),()=>{document.removeEventListener(`pointerdown`,e)}},[r,I,d]),V.useEffect(()=>{if(!r)return;let e=e=>{E&&e!=null&&_.current[e]?.scrollIntoView({block:`nearest`}),h(I.floating.current?.scrollTop??0)};return e(u.current),s.activeIndexSubscribe(e)},[r,I,E,s.activeIndexSubscribe]),V.useEffect(()=>{r&&O&&l!=null&&_.current[l]?.scrollIntoView({block:`nearest`})},[r,O,l]),b(()=>{I.floating.current&&O&&(I.floating.current.style.maxHeight=``)},[I,O]);let fe=V.useMemo(()=>({refs:I,dataRef:se}),[I]);return(0,H.jsx)(zc,{scope:t,...o,setScrollTop:h,setInnerOffset:j,fallback:O,floatingContext:fe,canScrollDown:!!ae,canScrollUp:!!L,controlledScrolling:E,blockSelection:ee,upArrowRef:y,downArrowRef:x,update:ne,children:(0,H.jsx)(Vc,{scope:t,...s,allowMouseUpRef:C,allowSelectRef:S,dataRef:se,interactions:de,listRef:_,selectTimeoutRef:w,children:n})})},Jc=`SelectItem`,{Provider:Yc,useStyledContext:Xc}=S(null,Jc),Zc=ms.Frame.styleable(function(e,t){let{scope:n,value:r,disabled:i=!1,textValue:a,index:o,...s}=e,{setSelectedIndex:c,listRef:l,setOpen:u,onChange:d,activeIndexSubscribe:f,activeIndexRef:p,valueSubscribe:m,allowMouseUpRef:h,allowSelectRef:g,setValueAtIndex:_,selectTimeoutRef:v,dataRef:y,interactions:x,shouldRenderWebNative:S,size:C,onActiveChange:w,initialValue:T,setActiveIndexFast:E}=Hc(n),[D,O]=V.useState(T===r);b(()=>{T===r&&c(o)},[]),V.useEffect(()=>{let e=e=>{o===e&&(w(r,o),requestAnimationFrame(()=>{l?.current[o]?.focus()}))},t=p?.current;return t!=null&&e(t),f(e)},[o]),V.useEffect(()=>m(e=>{O(e===r)}),[r]);let k=V.useId(),A=V.useCallback(e=>{e instanceof HTMLElement&&l&&(l.current[o]=e)},[o,l]),j=he(t,A);b(()=>{_(o,r)},[o,_,r]);function ee(){c(o),d(r),u(!1)}let M=V.useMemo(()=>x?x.getItemProps({onTouchMove(){g.current=!0,h.current=!1},onTouchEnd(){g.current=!1,h.current=!0},onKeyDown(e){if(e.key===`Enter`||e.key===` `&&!y?.current.typing)e.preventDefault(),ee();else if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault(),e.stopPropagation();let t=l?.current.length??0;if(t===0)return;let n;n=e.key===`ArrowDown`?o+1>=t?0:o+1:o-1<0?t-1:o-1,E?.(n)}else g.current=!0},onClick(){g.current&&ee()},onMouseUp(){if(!h.current){h.current=!0,g.current=!0;return}g.current&&ee(),clearTimeout(v.current),v.current=setTimeout(()=>{g.current=!0})}}):{onPress:ee},[ee,o,l,E]);return(0,H.jsx)(Yc,{scope:n,value:r,textId:k||``,isSelected:D,children:S?(0,H.jsx)(`option`,{value:r,children:e.children}):(0,H.jsx)(ms.Frame,{render:`div`,componentName:Jc,ref:j,role:`option`,"aria-labelledby":k,"aria-selected":D,"data-state":D?`active`:`inactive`,"aria-disabled":i||void 0,"data-disabled":i?``:void 0,tabIndex:i?void 0:-1,...!e.unstyled&&{cursor:`default`,size:C,outlineOffset:-.5,zIndex:100,hoverStyle:{backgroundColor:`$backgroundHover`},pressStyle:{backgroundColor:`$backgroundPress`},focusStyle:{backgroundColor:`$backgroundFocus`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:1,outlineStyle:`solid`}},...s,...M})})},{disableTheme:!0}),Qc=M(a,{name:`SelectItemText`,variants:{unstyled:{false:{userSelect:`none`,color:`$color`,ellipsis:!0}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),$c=Qc.styleable(function(e,t){let{scope:n,className:r,...i}=e,a=Hc(n),o=V.useRef(null),s=he(t,o),c=Xc(n),l=V.useRef(null);return l.current=(0,H.jsx)(Qc,{className:r,size:a.size,id:c.textId,...i,ref:s}),b(()=>{a.initialValue===c.value&&a.setSelectedItem(l.current)},[]),b(()=>a.valueSubscribe(e=>{e===c.value&&a.setSelectedItem(l.current)}),[c.value]),a.shouldRenderWebNative?(0,H.jsx)(H.Fragment,{children:e.children}):(0,H.jsx)(H.Fragment,{children:l.current})}),el=`SelectScrollUpButton`,tl=V.forwardRef((e,t)=>(0,H.jsx)(il,{componentName:el,...e,dir:`up`,ref:t}));tl.displayName=el;var nl=`SelectScrollDownButton`,rl=V.forwardRef((e,t)=>(0,H.jsx)(il,{componentName:nl,...e,dir:`down`,ref:t}));rl.displayName=nl;var il=V.memo(V.forwardRef((e,t)=>{let{scope:n,dir:r,componentName:i,...a}=e,{forceUpdate:o,open:s,fallback:c,setScrollTop:l,setInnerOffset:u,...d}=Bc(n),f=d.floatingContext?.refs.floating,p=V.useRef(`idle`),m=d[r===`down`?`canScrollDown`:`canScrollUp`],h=V.useRef(null),{x:g,y:_,refs:v,strategy:y}=kt({open:s&&m,strategy:`fixed`,elements:{reference:f?.current},placement:r===`up`?`top`:`bottom`,middleware:[ut(({rects:e})=>-e.floating.height)],whileElementsMounted:(...e)=>hn(...e,{animationFrame:!0})}),b=he(t,v.setFloating);if(!m)return null;let x=e=>{let t=f;t&&(c?t.current&&(t.current.scrollTop-=e,(0,Ns.flushSync)(()=>l(t.current?.scrollTop??0))):(0,Ns.flushSync)(()=>u(t=>t-e)))};return(0,H.jsx)(z,{ref:b,componentName:i,"aria-hidden":!0,...a,zIndex:1e3,position:y,left:g||0,top:_||0,width:`calc(${(f?.current?.offsetWidth??0)-2}px)`,onPointerEnter:()=>{p.current=`active`;let e=Date.now();function t(){let n=f?.current;if(n){let i=Date.now(),a=i-e;e=i;let o=a/2,s=r===`up`?n.scrollTop:n.scrollHeight-n.clientHeight-n.scrollTop,c=r===`up`?n.scrollTop-o>0:n.scrollTop+o<n.scrollHeight-n.clientHeight;x(r===`up`?Math.min(o,s):Math.max(-o,-s)),c&&(h.current=requestAnimationFrame(t))}}cancelAnimationFrame(h.current),h.current=requestAnimationFrame(t)},onPointerLeave:()=>{p.current=`idle`,cancelAnimationFrame(h.current)}})})),al=`SelectTrigger`,ol=typeof window<`u`&&typeof window.matchMedia==`function`?window.matchMedia(`(pointer:coarse)`).matches:!0,sl=V.forwardRef(function(e,t){let{scope:n,disabled:r=!1,unstyled:i=!1,...a}=e,o=Bc(n),s=Hc(n),c=he(t,o.floatingContext?.refs.setReference);return s.shouldRenderWebNative?null:(0,H.jsx)(ms,{componentName:al,unstyled:i,render:`button`,type:`button`,id:s.id,...!i&&{focusVisibleStyle:{outlineStyle:`solid`,outlineWidth:2,outlineColor:`$outlineColor`},borderWidth:1,size:s.size},role:`combobox`,"aria-haspopup":`listbox`,"aria-expanded":o.open,"aria-autocomplete":`none`,dir:o.dir,disabled:r,"data-disabled":r?``:void 0,...a,ref:c,...s.interactions?{...s.interactions.getReferenceProps(),...ol?{onPress(){s.setOpen(!o.open)}}:{onMouseDown(){o.floatingContext?.update?.(),s.setOpen(!o.open)}}}:{onPress(){s.setOpen(!o.open)}}})}),cl=M(h,{name:Kc,variants:{unstyled:{false:{size:`$2`,backgroundColor:`$background`,elevate:!0,bordered:!0,userSelect:`none`,outlineWidth:0}},size:{"...size":(e,{tokens:t})=>({borderRadius:t.radius[e]??e})}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),ll=bt(),ul=cl.styleable(function(e,t){let{scope:n,children:r,disableScroll:i,...a}=e,o=Bc(n),s=Hc(n),c=St(o.adaptScope),[l,u]=V.useState(!o.lazyMount);V.useEffect(()=>{o.lazyMount&&o.open&&(l||an(()=>{u(!0)}))},[o.lazyMount,o.open,l]);let d=he(t,o.floatingContext?.refs.setFloating);if(b(()=>{o.update&&o.update()},[c]),b(()=>{o.lazyMount&&l&&o.open&&o.update&&o.update()},[l]),s.shouldRenderWebNative)return(0,H.jsx)(z,{position:`relative`,children:r});if(c){let e=r;return ll&&(e=(0,H.jsx)(Uc,{itemContext:s,context:o,children:e})),(0,H.jsx)(mt,{scope:o.adaptScope,children:e})}if(!s.interactions)return null;let{style:f,className:p,...m}=s.interactions.getFloatingProps();return(0,H.jsxs)(H.Fragment,{children:[!i&&!e.unstyled&&(0,H.jsx)(`style`,{dangerouslySetInnerHTML:{__html:dl}}),(0,H.jsx)(kn,{children:o.open?(0,H.jsx)(cl,{size:s.size,role:`presentation`,...a,...f,...m,...!e.unstyled&&{overflowY:i?void 0:f.overflow??`auto`},ref:d,children:l?r:null},`select-viewport`):null}),!o.open&&!(o.lazyMount&&o.renderValue)&&l&&(0,H.jsx)(`div`,{style:{display:`none`},children:r})]})}),dl=`
|
|
11
|
+
.is_SelectViewport {
|
|
12
|
+
scrollbar-width: none;
|
|
13
|
+
-webkit-overflow-scrolling: touch;
|
|
14
|
+
overscroll-behavior: contain;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.is_SelectViewport::-webkit-scrollbar{
|
|
18
|
+
display:none
|
|
19
|
+
}
|
|
20
|
+
`,fl=M(a,{name:`SelectValue`,userSelect:`none`}),pl=fl.styleable(function({scope:e,children:t,placeholder:n,...r},i){let a=Bc(e),o=Hc(e),s=he(i,a.onValueNodeChange),c=a.value==null||a.value===``,l=a.renderValue?.(a.value),u=t??l??o.selectedItem??a.value,d=c?n??u:u;return(0,H.jsx)(fl,{...!r.unstyled&&{size:o.size,ellipsis:!0,pointerEvents:`none`},ref:s,...r,children:ml(d)})});function ml(e){return V.Children.map(e,e=>{if(e){if(e.type?.staticConfig?.componentName===`SelectItemText`)return e.props.children;if(e.props?.children)return ml(e.props.children)}return e})}var hl=M(y,{name:`SelectIcon`,"aria-hidden":!0,children:(0,H.jsx)(Nt,{children:`▼`})}),gl=M(y,{name:`SelectItemIndicator`}),_l=V.forwardRef(function(e,t){let{scope:n,...r}=e,i=Hc(n),a=Xc(n);return i.shouldRenderWebNative?null:a.isSelected?(0,H.jsx)(gl,{"aria-hidden":!0,...r,ref:t}):null}),vl=M(z,{name:`SelectIndicator`,variants:{unstyled:{false:{position:`absolute`,top:0,left:0,pointerEvents:`none`,zIndex:10,backgroundColor:`$background`,borderRadius:0}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),yl=vl.styleable(function({scope:e,...t},n){let r=Hc(e),i=Bc(e),[a,o]=V.useState(null),s=V.useRef(0);return V.useLayoutEffect(()=>{let e=e=>{typeof e==`number`&&(cancelAnimationFrame(s.current),s.current=requestAnimationFrame(()=>{let t=r.listRef?.current?.[e];t&&o({width:Math.round(t.offsetWidth),height:Math.round(t.offsetHeight),x:Math.round(t.offsetLeft),y:Math.round(t.offsetTop)})}))};return i.open&&i.activeIndexRef.current!==null&&e(i.activeIndexRef.current),r.activeIndexSubscribe(e)},[i.open,r.listRef]),a?(0,H.jsx)(vl,{ref:n,...t,width:a.width,height:a.height,x:a.x,y:a.y}):null}),bl=`SelectGroup`,{Provider:xl,useStyledContext:Sl}=S({id:``},`SelectGroup`),Cl=M(z,{name:bl,width:`100%`}),wl=M(a,{render:`select`,backgroundColor:`$background`,borderColor:`$borderColor`,hoverStyle:{backgroundColor:`$backgroundHover`}}),Tl=M(z,{name:`NativeSelect`,variants:{size:{"...size":(e,t)=>{let{tokens:n}=t,r=ee(n.space[e]);return{borderRadius:n.radius[e]??e,minHeight:n.size[e],paddingRight:r+20,paddingLeft:r,paddingVertical:m(e,{shift:-3})}}},unstyled:{false:{borderWidth:1,borderColor:`$borderColor`,userSelect:`none`,outlineWidth:0,paddingRight:10}}},defaultVariants:{size:`$2`,unstyled:{}.GUI_HEADLESS===`1`}}),El=V.forwardRef((e,t)=>{let{scope:n,...r}=e,i=V.useId(),a=Bc(n),o=Hc(n),s=o.size??`$true`,c=V.useRef(null),l=o.shouldRenderWebNative?(0,H.jsx)(Tl,{asChild:!0,size:s,value:a.value,id:o.id,children:(0,H.jsx)(wl,{onChange:e=>{o.onChange(e.currentTarget.value)},size:s,ref:c,style:{color:`var(--color)`,appearance:`none`},children:e.children})}):(0,H.jsx)(Cl,{role:`group`,"aria-labelledby":i,...r,ref:t});return(0,H.jsx)(xl,{scope:n,id:i||``,children:l})});El.displayName=bl;var Dl=M(a,{name:`SelectLabel`,variants:{unstyled:{false:{size:`$true`,ellipsis:!0,maxWidth:`100%`,cursor:`default`}},size:{"...size":(e,{tokens:t})=>({paddingHorizontal:t.space[e],paddingVertical:m(t.space[e],{shift:-4})})}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),Ol=Dl.styleable((e,t)=>{let{scope:n,...r}=e,i=Hc(n),a=Sl(n);return i.shouldRenderWebNative?null:(0,H.jsx)(Dl,{render:`div`,id:a.id,size:i.size,...r,ref:t})});M(Lc,{name:`SelectSeparator`});var kl=e=>{let t=Bc(e.scope),n=Wc(t),r=St(t.adaptScope),i=E(n);return(0,H.jsx)(Dt,{onOpenChange:t=>{i()&&e.onOpenChange(t)},open:t.open,hidden:!r,children:e.children})},Al=e=>(0,H.jsx)(H.Fragment,{children:e.children}),jl=oe(function(e){let t=`AdaptSelect${e.scope||``}`;return(0,H.jsx)(Wt,{scope:t,portal:!0,children:(0,H.jsx)(Nl,{scope:e.scope,adaptScope:t,...e})})},{Adapt:Bt,Content:Gc,Group:El,Icon:hl,Item:Zc,ItemIndicator:_l,ItemText:$c,Label:Ol,ScrollDownButton:rl,ScrollUpButton:tl,Trigger:sl,Value:pl,Viewport:ul,Indicator:yl,FocusScope:vt});function Ml(){let e=V.useRef(new Set);return[V.useCallback(t=>{e.current.forEach(e=>e(t))},[]),V.useCallback(t=>(e.current.add(t),()=>{e.current.delete(t)}),[])]}function Nl(e){let{scope:t=``,adaptScope:n,native:r,children:i,open:a,defaultOpen:o,onOpenChange:s,value:c,defaultValue:l,onValueChange:u,disablePreventBodyScroll:d,size:p=`$true`,onActiveChange:m,dir:h,id:g,renderValue:_,lazyMount:v,zIndex:y}=e,x=St(n)?Al:qc,S=V.useReducer(()=>({}),{})[1],[C,w]=V.useState(null),[T,E]=et({prop:a,defaultProp:o||!1,onChange:s}),[D,O]=et({prop:c,defaultProp:l||``,onChange:u,transition:!0});V.useEffect(()=>{T&&ee(D)},[T]),V.useEffect(()=>{ee(D)},[D]);let k=V.useRef(null),[A,j]=V.useState(null),[ee,M]=Ml(),[N,P]=Ml(),te=V.useRef(null),F=V.useRef([]),[I,ne]=V.useState(0),[re,ie]=V.useState(null);b(()=>{te.current=I});let L=r===!0||r===`web`||Array.isArray(r)&&r.includes(`web`),ae=V.useCallback(e=>{k.current!==e&&(k.current=e,typeof e==`number`&&N(e))},[N]),oe=V.useCallback(e=>{ae(e),j(e)},[ae]),R=(0,H.jsx)(Vc,{scopeName:t,scope:t,adaptScope:n,initialValue:V.useMemo(()=>D,[T]),size:p,activeIndexSubscribe:P,activeIndexRef:k,valueSubscribe:M,setOpen:E,id:g,onChange:V.useCallback(e=>{O(e),ee(e)},[]),onActiveChange:f((e,t)=>{m?.(e,t)}),setSelectedIndex:ne,setValueAtIndex:V.useCallback((e,t)=>{F.current[e]=t},[]),shouldRenderWebNative:L,setActiveIndexFast:ae,selectedItem:C,setSelectedItem:w,children:(0,H.jsx)(zc,{scope:t,scopeName:t,adaptScope:n,disablePreventBodyScroll:d,dir:h,blockSelection:!1,fallback:!1,forceUpdate:S,valueNode:re,onValueNodeChange:ie,activeIndex:A,activeIndexRef:k,selectedIndex:I,setActiveIndex:oe,value:D,open:T,native:r,renderValue:_,lazyMount:v,children:(0,H.jsx)(kl,{onOpenChange:E,scope:t,children:L?i:(0,H.jsx)(x,{activeIndexRef:k,listContentRef:F,selectedIndexRef:te,setActiveIndexFast:ae,...e,open:T,value:D,children:i})})})});return y===void 0?R:(0,H.jsx)(Rc.Provider,{value:y,children:R})}function Pl(e){return e?`checked`:`unchecked`}var Fl=e=>{let{control:t,checked:n,bubbles:r=!0,...i}=e,a=V.useRef(null),o=Po(n);return V.useEffect(()=>{let e=a.current,t=window.HTMLInputElement.prototype,i=Object.getOwnPropertyDescriptor(t,`checked`).set;if(o!==n&&i){let t=new Event(`click`,{bubbles:r});i.call(e,n),e.dispatchEvent(t)}},[o,n,r]),(0,H.jsx)(`input`,{type:`checkbox`,"aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:a,style:{...e.style,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0}})};function Il(e,[t,n],r){{let{disabled:i,name:a,value:o,required:s}=e,c=V.useRef(!1),[l,u]=V.useState(null),d=he(r,u),f=!l||!!l.closest(`form`),p=No(l),m=e[`aria-labelledby`]||e.labeledBy||p;return{switchProps:{role:`switch`,"aria-checked":t,tabIndex:i?void 0:0,"data-state":Pl(t),"data-disabled":i?``:void 0,disabled:i,"aria-labelledby":m,onPress:I(e.onPress,e=>{n(e=>!e),f&&(c.current=e.isPropagationStopped(),c.current||e.stopPropagation())})},switchRef:d,bubbleInput:f?(0,H.jsx)(Fl,{control:l,bubbles:!c.current,name:a,value:o,checked:t,required:s,disabled:i,style:{transform:`translateX(-100%)`}}):null}}}var Ll=S({active:!1,disabled:!1,frameWidth:void 0,size:void 0,unstyled:{}.GUI_HEADLESS===`1`}),Rl=M(z,{name:`SwitchThumb`,variants:{unstyled:{false:{size:`$true`,backgroundColor:`$background`,borderRadius:1e3}},size:{"...size":e=>{let t=zl(e);return{height:t,width:t}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}},{accept:{activeStyle:`style`}}),zl=e=>Math.round(ee(ie(e))*.65),Bl=e=>zl(e)*2,Vl=M(z,{name:`Switch`,render:`button`,tabIndex:0,variants:{unstyled:{false:{borderRadius:1e3,backgroundColor:`$background`,focusVisibleStyle:{outlineColor:`$outlineColor`,outlineStyle:`solid`,outlineWidth:2}}},size:{"...size":(e,{props:t})=>{if(t.unstyled)return;let n=zl(e);return{height:n,minHeight:n,width:Bl(e)}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}},{accept:{activeStyle:`style`}});function Hl(e){return null}function Ul(e){let{Frame:t=Vl,Thumb:n=Rl}=e;t.staticConfig.context=Ll,n.staticConfig.context=Ll;let r=n.styleable(function(e,t){let{size:r,unstyled:i,activeStyle:a,...o}=e,{unstyled:s,size:c,active:l,disabled:u,frameWidth:d=0}=Ll.useStyledContext(),f={}.GUI_HEADLESS===`1`?!0:i??s??!1,p=r??c??`$true`,m=V.useRef(l).current,h=ee(e.width||p,`size`),[g,_]=V.useState(typeof h==`number`?h:0),v=d-g,y=m?l?0:-v:l?v:0;return(0,H.jsx)(n,{ref:t,unstyled:f,...f===!1&&{size:p},alignSelf:m?`flex-end`:`flex-start`,x:y,onLayout:I(e.onLayout,e=>{let t=e.nativeEvent.layout.width;_(t)}),disabled:u,...o,...l&&a})}),i=t.styleable(function(e,n){let{native:r,nativeProps:i,checked:a,defaultChecked:o,onCheckedChange:s,activeStyle:c,unstyled:l,activeTheme:u,...d}=e,[f,p]=et({prop:a,defaultProp:o||!1,onChange:s,transition:!0}),m=V.useContext(Ll.context),[h,g]=V.useState(0),{switchProps:_,bubbleInput:v,switchRef:y}=Il(d,[f,p],n),b=Hl({id:d.id,disabled:d.disabled,native:r,nativeProps:i,checked:f,setChecked:p});if(b)return b;let x=d.disabled,S=e=>{let t=e.nativeEvent.layout.width;t!==h&&g(t)},C=m.unstyled??l??!1;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(Ll.Provider,{size:m.size??d.size??`$true`,unstyled:C,active:f,disabled:x,frameWidth:h,children:(0,H.jsx)(t,{ref:y,render:`button`,theme:u??null,type:`button`,...!C&&{size:m.size??d.size??`$true`},unstyled:C,...d,..._,disabled:x,...f&&{...!C&&!c&&{backgroundColor:`$backgroundActive`},...c},children:(0,H.jsx)(w,{alignSelf:`stretch`,flex:1,onLayout:S,children:d.children})})}),v]})},{disableTheme:!0});return oe(i,{Thumb:r})}var Wl=Ul({Frame:Vl,Thumb:Rl}),{Provider:Gl,useStyledContext:Kl}=S(),ql=M(eo,{name:`Tabs`}),Jl=M(w,{name:`TabsTrigger`,role:`tab`,variants:{size:{"...size":r},disabled:{true:{pointerEvents:`none`}},unstyled:{false:{borderWidth:0,backgroundColor:`$background`,userSelect:`none`,justifyContent:`center`,alignItems:`center`,flexWrap:`nowrap`,flexDirection:`row`,cursor:`pointer`,pressStyle:{backgroundColor:`$backgroundPress`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`,zIndex:10}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}},{accept:{activeStyle:`style`}}),Yl=M(h,{name:`TabsContent`});function Xl(e){let{ContentFrame:t=Yl,TabFrame:n=Jl,TabsFrame:r=ql}=e,i=`TabsContext`,a=`TabsList`,o=V.forwardRef((e,t)=>{let{__scopeTabs:n,loop:r=!0,children:o,...s}=e,c=Kl(n);return(0,H.jsx)(Js,{__scopeRovingFocusGroup:n||i,orientation:c.orientation,dir:c.dir,loop:r,asChild:!0,children:(0,H.jsx)(rs,{role:`tablist`,componentName:a,"aria-orientation":c.orientation,ref:t,orientation:c.orientation,...s,children:o})})});o.displayName=a;let s=n.styleable((e,t)=>{let{__scopeTabs:r,value:a,disabled:o=!1,onInteraction:s,activeStyle:c,activeTheme:l,unstyled:u=!1,...d}=e,f=Kl(r),p=Zl(f.baseId,a),m=Ql(f.baseId,a),h=a===f.value,[g,_]=V.useState(null),v=V.useRef(null),y=ns({disabled:!!o});return V.useEffect(()=>(f.registerTrigger(),()=>f.unregisterTrigger()),[]),V.useEffect(()=>{if(!v.current)return;let e=v.current;function t(){e&&_({width:e.offsetWidth,height:e.offsetHeight,x:e.offsetLeft,y:e.offsetTop})}t();let n=new ResizeObserver(t);return n.observe(e),()=>{n.disconnect()}},[f.triggersCount]),V.useEffect(()=>{h&&g&&s?.(`select`,g)},[h,a,g]),(0,H.jsx)(Js.Item,{__scopeRovingFocusGroup:r||i,asChild:!0,focusable:!o,active:h,children:(0,H.jsx)(n,{onMouseEnter:I(e.onMouseEnter,()=>{g&&s?.(`hover`,g)}),onMouseLeave:I(e.onMouseLeave,()=>{s?.(`hover`,null)}),role:`tab`,"aria-selected":h,"aria-controls":m,"data-state":h?`active`:`inactive`,"data-disabled":o?``:void 0,id:p,theme:l??null,unstyled:u,...!u&&{size:f.size},...h&&{...!u&&!c&&{backgroundColor:`$backgroundActive`},...c},...y,disabled:o??y.disabled,...d,ref:le(t,v),onPress:I(e.onPress??void 0,e=>{let t=e.button===0&&e.ctrlKey===!1;!o&&!h&&t&&f.onChange(a)}),onKeyDown:I(e.onKeyDown,e=>{[` `,`Enter`].includes(e.key)&&(f.onChange(a),e.preventDefault())}),onFocus:I(e.onFocus,e=>{g&&s?.(`focus`,g);let t=f.activationMode!==`manual`;!h&&!o&&t&&f.onChange(a)}),onBlur:I(e.onBlur,()=>{s?.(`focus`,null)})})})});s.displayName=`TabsTrigger`;let c=t.styleable(function(e,n){let{__scopeTabs:r,value:i,forceMount:a,children:o,...s}=e,c=Kl(r),l=i===c.value,u=a||l,d=Zl(c.baseId,i),f=Ql(c.baseId,i);return u?(0,H.jsx)(t,{"data-state":l?`active`:`inactive`,"data-orientation":c.orientation,role:`tabpanel`,"aria-labelledby":d,hidden:!u,id:f,tabIndex:0,...s,ref:n,children:o},i):null}),l=r.styleable(function(e,t){let{__scopeTabs:n,value:i,onValueChange:a,defaultValue:o,orientation:s=`horizontal`,dir:c,activationMode:l=`manual`,size:u=`$true`,...d}=e,p=no(c),[m,h]=et({prop:i,onChange:a,defaultProp:o??``}),[g,_]=V.useState(0),v=f(()=>_(e=>e+1)),y=f(()=>_(e=>e-1));return(0,H.jsx)(P.Provider,{size:u,children:(0,H.jsx)(Gl,{scope:n,baseId:V.useId(),value:m,onChange:h,orientation:s,dir:p,activationMode:l,size:u,registerTrigger:v,triggersCount:g,unregisterTrigger:y,children:(0,H.jsx)(r,{direction:p,"data-orientation":s,...d,ref:t})})})});return oe(l,{List:o,Trigger:s,Tab:s,Content:c})}function Zl(e,t){return`${e}-trigger-${t}`}function Ql(e,t){return`${e}-content-${t}`}var $l=Xl({ContentFrame:Yl,TabFrame:Jl,TabsFrame:ql}),eu=M(T,{position:`absolute`,width:1,height:1,margin:-1,zIndex:-1e4,overflow:`hidden`,opacity:1e-8,pointerEvents:`none`,variants:{preserveDimensions:{true:{position:`relative`,width:`auto`,height:`auto`}},visible:{true:{position:`relative`,width:`auto`,height:`auto`,margin:0,zIndex:1,overflow:`visible`,opacity:1,pointerEvents:`auto`}}}});eu.isVisuallyHidden=!0;var tu=(e,{message:t,notificationOptions:n})=>!(`Notification`in window)||Notification.permission!==`granted`?!1:{nativeToastRef:new Notification(e,{body:t,...n})},nu=``,ru={focus:!0,"remove-scroll":!0},iu=Dn.styleable((e,t)=>{let n=V.useContext(ou),r=V.useContext(su);return(0,H.jsx)(yt,{scope:e.scope||nu,alwaysDisable:ru,...!e.unstyled&&{backgroundColor:`$background`,alignItems:`center`,pointerEvents:`none`,size:`$true`},ref:t,...r!==void 0&&{zIndex:r},...e,...n&&{transition:null}})},{staticConfig:{componentName:`Tooltip`}}),au=V.forwardRef((e,t)=>(0,H.jsx)(Cn,{scope:e.scope||nu,componentName:`Tooltip`,ref:t,...e})),ou=V.createContext(!1),su=V.createContext(void 0),cu=({children:e,delay:t,preventAnimation:n=!1,timeoutMs:r})=>(0,H.jsx)(ou.Provider,{value:n,children:(0,H.jsx)(On,{timeoutMs:r,delay:V.useMemo(()=>t,[JSON.stringify(t)]),children:e})}),lu=new Set,uu=V.forwardRef(function(e,t){"use no memo";let{children:n,delay:r,restMs:i,onOpenChange:a,focus:o,open:s,disableAutoCloseOnScroll:c,zIndex:l,scope:u=nu,...d}=e,p=V.useRef(null),[m,h]=V.useState(!1),{delay:g,setCurrentId:_}=nn(),v=r===void 0?g??400:r,y=i??(typeof v==`number`?v:0),[b,x]=et({prop:s,defaultProp:!1,onChange:a}),S=e.groupId,C=f(e=>{e&&_(S),x(e)});V.useEffect(()=>{if(!b||c||typeof document>`u`)return;let e=()=>{x(!1)};return lu.add(x),document.documentElement.addEventListener(`scroll`,e),()=>{lu.delete(x),document.documentElement.removeEventListener(`scroll`,e)}},[b,c]);let w=Yt({open:b,setOpen:C,disable:!1,disableFocus:!1,hoverable:!0,role:`tooltip`,focus:o,groupId:S,delay:v,restMs:y}),T=V.useCallback(()=>h(!0),[]),E=V.useCallback(()=>h(!1),[]),D=V.useId(),O=e.unstyled?null:ie(`$true`,{shift:-2,bounds:[0]}),k=(0,H.jsx)(Rt.Provider,{value:w,children:(0,H.jsx)($e,{scope:u,size:O?.key,allowFlip:!0,stayInFrame:!0,open:b,...d,children:(0,H.jsx)(qt,{scope:u,contentId:D,triggerRef:p,open:b,onOpenChange:x,onOpenToggle:mu,hasCustomAnchor:m,onCustomAnchorAdd:T,onCustomAnchorRemove:E,children:n})})});return l===void 0?k:(0,H.jsx)(su.Provider,{value:l,children:k})}),du=V.forwardRef(function(e,t){let{scope:n,...r}=e;return(0,H.jsx)(Gt,{...r,scope:n||nu,ref:t})}),fu=V.forwardRef(function(e,t){let{scope:n,...r}=e;return(0,H.jsx)(xt,{...r,scope:n||nu,ref:t})}),pu=oe(uu,{Anchor:fu,Arrow:au,Content:iu,Trigger:du}),mu=()=>{},hu=l,gu=[`facebook.`,`instagram.`,`twitter.`,`x.com`,`t.co`,`linkedin.`,`reddit.`,`youtube.`,`tiktok.`,`pinterest.`,`news.ycombinator.com`],_u=[`google.`,`bing.`,`duckduckgo.`,`yahoo.`,`baidu.`,`ecosia.`];function vu(e,t){let n=new URLSearchParams(e||``),r=e=>{let t=n.get(e);return t?t.trim():void 0},i={utm:{source:r(`utm_source`),medium:r(`utm_medium`),campaign:r(`utm_campaign`),term:r(`utm_term`),content:r(`utm_content`)},referrer:t?t.trim():void 0,refCode:r(`ref`)||r(`refCode`)||r(`ref_code`)||void 0};return i.channel=yu(i),i}function yu(e){let t=(e.utm.medium||``).toLowerCase();if(/(cpc|ppc|paid|paidsearch|display|cpm)/.test(t))return`paid`;if(e.utm.source||e.utm.campaign)return`campaign`;if(e.refCode)return`referral`;let n=bu(e.referrer);return n?gu.some(e=>n.includes(e))?`social`:_u.some(e=>n.includes(e))?`organic`:`referral`:`direct`}function bu(e){if(!e)return``;let t=e.trim(),n=t.indexOf(`://`);n>=0&&(t=t.slice(n+3));let r=t.search(/[/?#]/);r>=0&&(t=t.slice(0,r));let i=t.indexOf(`@`);i>=0&&(t=t.slice(i+1));let a=t.indexOf(`:`);return a>=0&&(t=t.slice(0,a)),t.toLowerCase().trim()}function xu(e){return!!(e.utm.source||e.utm.medium||e.utm.campaign||e.utm.term||e.utm.content||e.refCode||e.referrer&&bu(e.referrer))}var Su=Object.freeze({hanzo:Object.freeze([`hanzo.ai`,`hanzo.agency`,`hanzo.app`,`hanzo.bot`,`hanzo.chat`,`hanzo.codes`,`hanzo.community`,`hanzo.computer`,`hanzo.help`,`hanzo.id`,`hanzo.industries`,`hanzo.market`,`hanzo.network`,`hanzo.sh`,`hanzo.team`,`hanzo.ventures`,`hanzo.works`,`hanzoskills.com`]),lux:Object.freeze([`lux.network`,`lux.exchange`,`lux.market`,`lux.finance`,`lux.financial`,`lux.credit`,`lux.fund`,`lux.id`]),zoo:Object.freeze([`zoo.ngo`,`zoo.network`,`zoolabs.id`,`zoolabs.io`])}),Cu=Object.freeze({hanzo:`pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc`,lux:`pk-gUZp6ZVfhJzSwK-rb4oLbVkpCnMBx5uSCpxf_5yEhQk`,zoo:`pk-3TKpKnERV9AQSsBUERWkZejC1O1mUxc1jRzsP3MPbs4`}),wu=Object.freeze({"hanzo.ai":`pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc`,"www.hanzo.ai":`pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc`,"hanzo.app":`pk-wlnXN2a9_vmCm60yTFtQ629Q8TyuaxBNZbY1RWT72gQ`,"hanzo.team":`pk-NCzD2FiHpZv8KUpkCX4olT1LJOJsMxBC_Z8NkiQsOFQ`,"pay.hanzo.ai":`pk-eX6kv7JZNoiYn1WkeJH3tT_8OvkVYScmCXnLMwxTKf8`,"platform.hanzo.ai":`pk-My1RpZLEUnTj8vAdPbWKYdDUuhxZJ4dVjHcwjZN4rZ8`,"docs.hanzo.ai":`pk-jukhtjMT2ymoeBDAeFjINQWlBv-v9sNn1TPztiCrrwk`,"hanzo.bot":`pk-W5d7Mn7ZukT7igyscIy6Pqe8JpA0Ge604Yn4xNR4JCU`,"hanzo.chat":`pk-ATxWeB2jNyRSxDgqnkGoDj3CCbzrmTxSktUh9zlrO-E`,"hanzo.id":`pk-_GVF3KlaqprlPHDumBMRFeFU1lIGOaarQfgimNVDIo8`,"hanzo.industries":`pk-Vh1wvL2HqIAv9qpVvmrznTI9uMHrTD-jyIC-vnlBsgY`,"hanzo.market":`pk-DN3xQFa0H61epUVg9OkiOYLzCdteNt9hE6f-S-ednjQ`,"hanzo.network":`pk-YJ2eiA_7ckLStMPte8Ar8FsmRp_ycmeIeRbpGprZYmM`,"hanzo.agency":`pk-26a2clOaJFe24aKJZ0PkI-GWR9F4EEa8rthHzgy_Efw`,"console.hanzo.ai":`pk-oFNXoiO1wOD8PqGdHYyiSq6jaNCdrd7TpztGpwM2ZiQ`,"admin.hanzo.ai":`pk-RYZwxkomW-tlAnEu2DKo_kAzcxFbSF2YiYcsUY48QL0`,"bot.hanzo.ai":`pk-W5d7Mn7ZukT7igyscIy6Pqe8JpA0Ge604Yn4xNR4JCU`,"cloud.hanzo.ai":`pk-RAfEGHPoNdCEU9fnA_cPd_Xo9Tci44rlYQV9xuJ1Ob0`});function Tu(e){let t=Du(e).replace(/^www\./,``);return wu[t]??(t.endsWith(`.hanzo.app`)?wu[`hanzo.app`]:void 0)}var Eu=`pk-`,Du=e=>e.trim().toLowerCase().replace(/\.$/,``).split(`:`)[0]??``;function Ou(e){let t=Du(e);if(!t)return;let n,r=0;for(let[e,i]of Object.entries(Su))for(let a of i)(t===a||t.endsWith(`.${a}`))&&a.length>r&&(n=e,r=a.length);return n}function ku(e,t=Cu){if(t===Cu){let t=Tu(e);if(t)return t}let n=Ou(e);if(!n)return;let r=t[n];if(typeof r!=`string`)return;let i=r.trim();return i.startsWith(Eu)?i:void 0}function Au(e=Cu){if(!(typeof location>`u`))return ku(location.hostname,e)}var ju=`[redacted]`,Mu=`[email]`,Nu=`[ip]`,Pu=[/-----BEGIN[ A-Z]*PRIVATE KEY-----[\s\S]*?-----END[ A-Z]*PRIVATE KEY-----/g,/eyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{6,}\.[A-Za-z0-9_-]{6,}/g,/\bbearer\s+[A-Za-z0-9._~+/-]{12,}=*/gi,/\b(?:sk|pk|rk)-[A-Za-z0-9]{2,}-?[A-Za-z0-9]{12,}/g,/\b(?:sk|pk)_(?:live|test)_[A-Za-z0-9]{16,}/g,/\bhk-[A-Za-z0-9]{16,}/g,/\bAKIA[0-9A-Z]{16}\b/g,/\bASIA[0-9A-Z]{16}\b/g,/\bAIza[0-9A-Za-z_-]{20,}/g,/\bgh[posru]_[A-Za-z0-9]{20,}/g,/\bxox[baprs]-[A-Za-z0-9-]{10,}/g,/[a-zA-Z][a-zA-Z0-9+.-]{0,32}:\/\/[^\s:@/]{1,256}:[^\s@/]{1,256}@/g],Fu=/\b(?:\d[ -]?){13,19}\b/g;function Iu(e){let t=0,n=!1;for(let r=e.length-1;r>=0;r--){let i=e.charCodeAt(r)-48;n&&(i*=2,i>9&&(i-=9)),t+=i,n=!n}return t%10==0}function Lu(e){return e.replace(Fu,e=>{let t=e.replace(/[ -]/g,``);return t.length<13||t.length>19?e:Iu(t)?ju:e})}var Ru=/[A-Za-z0-9._%+-]{1,64}@[A-Za-z0-9.-]{1,255}\.[A-Za-z]{2,24}/g,zu=/\b(?:\d{1,3}\.){3}\d{1,3}\b/g,Bu=/\b(?:[0-9A-Fa-f]{1,4}:){2,7}[0-9A-Fa-f]{1,4}\b/g,Vu=RegExp(`([?&#;](?:`+`code.state.token.access_token.id_token.refresh_token.auth.authorization.secret.client_secret.password.passwd.pwd.api_key.apikey.key.session.session_id.sid.sig.signature.nonce.otp.invite.invitation.reset_token.confirmation_token.magic.ticket.assertion`.split(`.`).join(`|`)+`)=)[^&#;\\s]{1,4096}`,`gi`);function Hu(e){return e.replace(Vu,(e,t)=>t+ju)}var Uu=/(^|[^A-Za-z0-9_-]|%[0-9A-Fa-f]{2})((?=[A-Za-z0-9_-]{0,42}[a-z])(?=[A-Za-z0-9_-]{0,42}[A-Z])[A-Za-z0-9_-]{43})(?![A-Za-z0-9_-])/g;function Wu(e){e=Hu(e);for(let t of Pu)e=e.replace(t,ju);return e=e.replace(Uu,(e,t)=>t+ju),Lu(e)}function Gu(e){let t=e.indexOf(`#`);return t<0?e:e.slice(0,t)}function Ku(e){return e=e.replace(Ru,Mu),e=e.replace(Bu,Nu),e=e.replace(zu,Nu),e}var qu=8192;function Ju(e,t=qu){return e.length>t?e.slice(0,t)+`… [truncated]`:e}function Yu(e,t=!1){return e?(e=Ju(e),e=Wu(e),t||(e=Ku(e)),e):e??``}var Xu=50,Zu=500,Qu=2048,$u=/^\s*at\s+(?:(.+?)\s+\()?(?:(.+?):(\d+):(\d+)|([^)]+))\)?\s*$/,ed=/^\s*(?:(.*?)@)?(.+?):(\d+):(\d+)\s*$/;function td(e){return e?!(e.includes(`node_modules`)||e.startsWith(`webpack-internal`)||e.startsWith(`webpack://`)||e.startsWith(`chrome-extension://`)||e.startsWith(`moz-extension://`)):!1}function nd(e){if(!e)return[];let t=e.split(`
|
|
21
|
+
`,Zu),n=[];for(let e of t){if(e.length>Qu)continue;let t=e.trimEnd();if(!t)continue;let r,i=``,a=0,o=0,s=$u.exec(t);if(s)r=s[1],s[2]?(i=s[2],a=Number(s[3])||0,o=Number(s[4])||0):i=(s[5]||``).trim();else{let e=ed.exec(t);if(!e)continue;r=e[1],i=e[2],a=Number(e[3])||0,o=Number(e[4])||0}(i||r)&&n.push({function:r||`<anonymous>`,filename:i,abs_path:i,lineno:a,colno:o,in_app:td(i)})}return n.reverse(),n.length>Xu?n.slice(n.length-Xu):n}function rd(e){if(e instanceof Error){let t=id(e,`name`),n=id(e,`message`),r=id(e,`stack`);return{name:typeof t==`string`&&t?t:`Error`,message:typeof n==`string`&&n?n:ad(e),stack:typeof r==`string`?r:void 0}}if(typeof e==`string`)return{name:`Error`,message:e};try{return{name:`Error`,message:JSON.stringify(e)??ad(e)}}catch{return{name:`Error`,message:ad(e)}}}function id(e,t){try{return e[t]}catch{return}}function ad(e){try{return String(e)}catch{return`[unstringifiable]`}}var od=`iam-anon-id`,sd=[`hz_anon_id`,`hz_id`],cd=`hanzo.ai`,ld=63072e3,ud;function dd(e){var t=new Uint8Array(16),n,r=typeof crypto<`u`?crypto:void 0;if(r&&typeof r.getRandomValues==`function`)r.getRandomValues(t);else for(n=0;n<16;n++)t[n]=Math.random()*256|0;var i=Math.floor(e===void 0?Date.now():e);for(n=5;n>=0;n--)t[n]=i%256,i=Math.floor(i/256);t[6]=112|t[6]&15,t[8]=128|t[8]&63;var a=``;for(n=0;n<16;n++)a+=(t[n]+256).toString(16).slice(1),(n===3||n===5||n===7||n===9)&&(a+=`-`);return a}function fd(){try{return typeof document>`u`||typeof document.cookie!=`string`?null:document}catch{return null}}function pd(){try{return typeof window>`u`||!window.localStorage?null:window.localStorage}catch{return null}}function md(e,t){try{return e&&e.getItem(t)||``}catch{return``}}function hd(e){var t=fd();if(!t)return``;for(var n=t.cookie.split(`;`),r=0;r<n.length;r++){var i=n[r].indexOf(`=`);if(!(i<0||n[r].slice(0,i).trim()!==e)){var a=n[r].slice(i+1).trim();if(a)try{return decodeURIComponent(a)}catch{return a}}}return``}function gd(e,t){var n=fd();if(n){var r=``,i=!1;try{typeof window<`u`&&window.location&&(r=window.location.hostname||``,i=window.location.protocol===`https:`)}catch{}var a=e+`=`+encodeURIComponent(t);a+=`; Path=/; Max-Age=`+ld+`; SameSite=Lax`,(`.`+r).slice(-(cd.length+1))===`.`+cd&&(a+=`; Domain=`+cd),i&&(a+=`; Secure`);try{n.cookie=a}catch{}}}function _d(e){for(var t=0;t<sd.length;t++){var n=hd(sd[t])||md(e,sd[t]);if(n)return n}return``}function vd(){if(typeof window>`u`)return``;var e=pd(),t=hd(od)||md(e,od)||_d(e)||ud||dd();ud=t,gd(od,t);try{e&&e.getItem(od)!==t&&e.setItem(od,t)}catch{}return t}function yd(e){ud=e,gd(od,e);try{var t=pd();t&&t.setItem(od,e)}catch{}}var bd={session:`hz_session`,firstTouch:`hz_first_touch`,lastTouch:`hz_last_touch`,cohort:`hz_cohort`},xd=7776e6,Sd=18e5;function Cd(){try{return typeof window>`u`||!window.localStorage?void 0:window.localStorage}catch{return}}function wd(){return vd()||void 0}function Td(e=Date.now()){let t=Cd();if(!t)return;let n=null;try{n=JSON.parse(t.getItem(bd.session)||`null`)}catch{n=null}return!n||e-n.last>Sd?n={id:dd(e),last:e}:n.last=e,t.setItem(bd.session,JSON.stringify(n)),n.id}function Ed(e,t=Date.now()){let n=Cd();n&&n.setItem(bd.session,JSON.stringify({id:e,last:t}))}function Dd(e){yd(e)}function Od(){let e=Cd();if(e)try{let t=e.getItem(bd.firstTouch);return t?JSON.parse(t):void 0}catch{return}}function kd(e){let t=Cd();return Od()||(t&&t.setItem(bd.firstTouch,JSON.stringify(e)),e)}function Ad(e=Date.now()){let t=Cd();if(t)try{let n=JSON.parse(t.getItem(bd.lastTouch)||`null`);return!n?.utm||typeof n.at!=`number`||e-n.at>xd?void 0:n.utm}catch{return}}function jd(e,t=Date.now()){let n=Cd();n&&n.setItem(bd.lastTouch,JSON.stringify({utm:e,at:t}))}function Md(){let e=Cd();if(e)try{let t=e.getItem(bd.cohort);return t?JSON.parse(t):void 0}catch{return}}function Nd(e){let t=Cd(),n=Md()||{},r={signupWeek:n.signupWeek||e.signupWeek,channel:e.channel||n.channel,refCode:n.refCode||e.refCode};return t&&t.setItem(bd.cohort,JSON.stringify(r)),r}var Pd=86400,Fd=new Set([`hanzo.app`]);function Id(e){for(let t of Object.values(Su))for(let n of t)if(!Fd.has(n)&&(e===n||e.endsWith(`.${n}`)))return n;return``}function Ld(){let e=Id(window.location.hostname.toLowerCase());return e?`; Domain=.${e}`:``}function Rd(e){if(typeof document>`u`||typeof document.cookie!=`string`)return;let t=document.cookie.split(`; `).find(t=>t.startsWith(`${e}=`));return t?decodeURIComponent(t.slice(e.length+1)):void 0}function zd(e,t,n){if(typeof document>`u`)return;let r=window.location.protocol===`https:`?`; Secure`:``;document.cookie=`${e}=${encodeURIComponent(t)}; Max-Age=${n*Pd}; Path=/; SameSite=Lax${Ld()}${r}`}function Bd(e){return typeof window<`u`&&window.location?.protocol===`https:`?`__Host-${e}`:e}function Vd(e,t,n){if(typeof document>`u`)return;let r=window.location.protocol===`https:`?`; Secure`:``;document.cookie=`${Bd(e)}=${encodeURIComponent(t)}; Max-Age=${n*Pd}; Path=/; SameSite=Lax${r}`}function Hd(e,t=[]){if(typeof document>`u`||typeof document.cookie!=`string`)return;let n=document.cookie.split(`; `).map(e=>e.slice(0,e.indexOf(`=`))),r=new Set([...e,...n.filter(e=>t.some(t=>t.test(e)))]),i=window.location.hostname.split(`.`),a=new Set([``,Ld(),...i.slice(0,-1).map((e,t)=>`; Domain=.${i.slice(t).join(`.`)}`)]);for(let e of r)for(let t of a)document.cookie=`${e}=; Max-Age=0; Path=/${t}`}var Ud=()=>typeof navigator<`u`&&navigator.webdriver===!0,Wd=`hz_internal`;function Gd(){if(Ud())return!0;if(typeof window>`u`||typeof document>`u`||typeof document.cookie!=`string`)return!1;let e=new URLSearchParams(window.location?.search??``).get(Wd);return e===`1`&&zd(Wd,`1`,365),e===`0`?(zd(Wd,``,0),!1):e===`1`||Rd(Wd)===`1`}var Kd={anon:`hz_aid`,session:`hz_sid`,firstTouch:`hz_ft`},qd=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,Jd=e=>!!e&&qd.test(e);function Yd(e){return JSON.stringify([e.utm.source,e.utm.medium,e.utm.campaign,e.utm.term,e.utm.content,e.refCode,e.referrer,e.channel].map(e=>e??``))}function Xd(e){if(!(!e||e.length>1024))try{let t=JSON.parse(e);if(!Array.isArray(t)||t.length!==8||t.some(e=>typeof e!=`string`))return;let[n,r,i,a,o,s,c,l]=t,u=e=>e||void 0;return{utm:{source:u(n),medium:u(r),campaign:u(i),term:u(a),content:u(o)},refCode:u(s),referrer:u(c),channel:u(l)}}catch{return}}function Zd(e,t,n,r){let i;try{i=new URL(e,r)}catch{return e}if(i.protocol!==`https:`&&i.protocol!==`http:`||!Ou(i.hostname)||i.hostname===n)return e;let a=(e,t)=>t&&i.searchParams.set(e,t);return Jd(t.anonId)&&a(Kd.anon,t.anonId),Jd(t.sessionId)&&a(Kd.session,t.sessionId),t.firstTouch&&a(Kd.firstTouch,Yd(t.firstTouch)),i.toString()}function Qd(e){let t=new URLSearchParams(e||``),n=t.get(Kd.anon),r=t.get(Kd.session);return{anonId:Jd(n)?n:void 0,sessionId:Jd(r)?r:void 0,firstTouch:Xd(t.get(Kd.firstTouch))}}function $d(e){let t=new URL(e),n=!1;for(let e of Object.values(Kd))t.searchParams.has(e)&&(t.searchParams.delete(e),n=!0);return n?t.pathname+t.search+t.hash:void 0}var ef=`hz_consent`,tf=`hz_consent_v`,nf=`hz_consent_rule`,rf=3,af=2,of=`hzconsent`,sf={analytics:!1,marketing:!1,ads:!1},cf={analytics:!0,marketing:!0,ads:!0},lf=[`eu`,`us_privacy`,`global`],uf=`hz_consent_policy`,df=Symbol.for(`hanzo.event.consent`);function ff(){let e=globalThis;return e[df]??(e[df]={})}function pf(e){if(typeof e!=`object`||!e)return;let t=e;if(typeof t.version==`number`||typeof t.mode==`string`)return{mode:lf.includes(t.mode)?t.mode:`eu`,refused:t.refused===!0,version:Number(t.version)||0,region:String(t.region??``),floor:Number(t.floor)||af}}function mf(){try{return typeof window>`u`?void 0:window.sessionStorage}catch{return}}function hf(){let e=ff().served;if(e)return e;try{let e=pf(JSON.parse(mf()?.getItem(uf)??`null`));if(e)return e}catch{}return{mode:`eu`,refused:!1,version:rf,region:``,floor:af}}function gf(){let e=hf();return{mode:e.mode,refused:e.refused||vf(),version:yf(),region:e.region}}function _f(){return typeof navigator>`u`?!1:navigator.globalPrivacyControl===!0}function vf(){if(typeof window>`u`)return!1;let e=typeof navigator>`u`?{}:navigator,t=e.doNotTrack??window.doNotTrack??e.msDoNotTrack;return _f()||t===`1`||t===`yes`}var yf=()=>Math.max(ff().served?.version??0,rf),bf=()=>gf().refused;function xf(){let e=Rd(Bd(ef));if(e===void 0)return;let t=Number(Rd(Bd(tf))),n=Rd(Bd(nf));if(gf().mode===`eu`&&!(n===`eu`||n===void 0&&t===2))return;let r=e.split(`,`);return{held:{analytics:r.includes(`analytics`),marketing:r.includes(`marketing`),ads:r.includes(`ads`)},current:t>=hf().floor&&t<=yf()}}var Sf=e=>e.analytics||e.marketing||e.ads;function Cf(){let e=gf();if(e.refused)return{...sf};let t=e.mode===`eu`?sf:cf,n=xf();return n?n.current?{...n.held}:{analytics:t.analytics&&n.held.analytics,marketing:t.marketing&&n.held.marketing,ads:t.ads&&n.held.ads}:{...t}}function wf(){let e=xf();bf()&&e&&Sf(e.held)&&Ef({...sf})}function Tf(e){return[`analytics`,`marketing`,`ads`].filter(t=>e[t]).join(`,`)}function Ef(e){let t=gf(),n=t.refused?{...sf}:{analytics:e.analytics,marketing:e.marketing,ads:e.ads};Vd(ef,Tf(n),395),Vd(tf,String(yf()),395),Vd(nf,t.mode,395),n.analytics||Af(Df),n.marketing||Af(Of),n.ads||Af(kf),typeof window<`u`&&window.dispatchEvent(new Event(of))}var Df={cookies:[`_ga`,`_gid`,`_gat`,`hz_cid`],patterns:[/^_ga_[A-Z0-9]+$/,/^_gat_[\w-]+$/],storage:[]},Of={cookies:[`hz_touch`,`_fbp`,`_fbc`,`_ttp`,`_tt_enable_cookie`,`ttcsid`,`_twclid`,`li_fat_id`,`li_giant`,`_uetsid`,`_uetvid`,`_pin_unauth`,`_epik`,`_derived_epik`,`_rdt_uuid`,`_rdt_cid`],patterns:[/^ttcsid_[A-Z0-9]+$/],storage:[]},kf={cookies:[],patterns:[/^_gcl_[a-z]+$/,/^_gac_[\w-]+$/],storage:[]};function Af(e){if(Hd(e.cookies,e.patterns),!(typeof window>`u`))try{for(let t of e.storage)window.localStorage?.removeItem(t)}catch{}}var jf=`0.3.66`,Mf=`/v1/event`,Nf=`https://api.hanzo.ai`,Pf=`text/plain`;function Ff(e){try{if(typeof process<`u`)return{}[e]||void 0}catch{}}function If(e,t,n){return e+(e.includes(`?`)?`&`:`?`)+t+`=`+encodeURIComponent(n)}function Lf(e){let t=rd(e),n=nd(t.stack).slice(-50).map(e=>({function:e.function,file:e.filename,line:e.lineno,column:e.colno}));return{type:t.name,message:t.message,stack:t.stack,frames:n}}var Rf=()=>zf()?{screen:`${window.screen?.width??0}x${window.screen?.height??0}`,language:navigator.language||``}:{},zf=()=>typeof window<`u`&&typeof document<`u`;function Bf(e){if(!zf())return e;let t=new Set(Tf(Cf()).split(`,`).filter(Boolean)),n=String(e.properties?.consent??``).split(`,`).filter(e=>t.has(e)).join(`,`);return{...e,properties:{...e.properties,consent:n}}}function Vf(e){try{return JSON.stringify({batch:e})}catch{}let t=[];for(let n of e)try{t.push(JSON.stringify(n))}catch{try{t.push(JSON.stringify({...n,properties:{$unserializable:!0}}))}catch{}}return t.length>0?`{"batch":[`+t.join(`,`)+`]}`:null}var Hf=class{send(e,t,n){if(n.beacon&&zf()&&typeof navigator.sendBeacon==`function`){let r=n.ingestKey?If(e,`ingest_key`,n.ingestKey):e;try{if(navigator.sendBeacon(r,new Blob([t],{type:Pf})))return;n.debug&&console.warn(`[event] beacon refused, falling back to fetch`)}catch{}}if(typeof fetch!=`function`)return;let r=n.ingestKey!==void 0&&n.token===void 0&&n.contentType===void 0,i={"Content-Type":r?Pf:n.contentType??`application/json`},a=r?void 0:n.token??n.ingestKey;a&&(i.Authorization=`Bearer ${a}`),fetch(n.ingestKey?If(e,`ingest_key`,n.ingestKey):e,{method:`POST`,headers:i,body:t,keepalive:!0,credentials:r?`omit`:`include`}).then(t=>{!t.ok&&n.debug&&console.warn(`[event] ingest rejected`,t.status,e.split(`?`)[0])}).catch(t=>{n.debug&&console.warn(`[event] ingest failed`,e.split(`?`)[0],t)})}},Uf=class{constructor(e){this.queue=[],this.timer=null,this.attribution={utm:{}},this.cohort={},this.started=!1,this.reentrant=!1,this.cfg={host:Nf,batchSize:20,flushIntervalMs:5e3,enabled:!0,captureErrors:!0,...e,ingestKey:e.ingestKey??Ff(`NEXT_PUBLIC_PUBLISHABLE_KEY`)??Au()},this.transport=e.transport??new Hf}adopt(e){e.ingestKey&&!this.cfg.ingestKey&&(this.cfg.ingestKey=e.ingestKey),e.getToken&&!this.cfg.getToken&&(this.cfg.getToken=e.getToken)}init(){if(this.started||!this.cfg.enabled||(this.started=!0,!zf()))return;let e=Qd(window.location.search),t=$d(window.location.href);if(t!==void 0)try{window.history.replaceState(window.history.state,``,t)}catch{}this.settle(e,vu(window.location.search,document.referrer)),wf(),window.addEventListener(`visibilitychange`,()=>{document.visibilityState===`hidden`&&this.flush(!0)}),window.addEventListener(`pagehide`,()=>this.flush(!0)),this.cfg.captureErrors&&(window.addEventListener(`error`,e=>{this.captureError(e.error??e.message,{handled:!1})}),window.addEventListener(`unhandledrejection`,e=>{this.captureError(e.reason,{handled:!1})}))}settle(e,t){e.anonId&&Dd(e.anonId),e.sessionId&&Ed(e.sessionId);let n=e.firstTouch&&!Od()?kd(e.firstTouch):void 0;this.attribution=n??(xu(t)?kd(t):Od()??t),(t.utm.source||t.utm.campaign)&&jd(t.utm),this.lastUtm=Ad(),this.cohort=Nd({channel:this.attribution.channel??yu(this.attribution),refCode:this.attribution.refCode})}link(e){return zf()?(this.started||this.init(),Zd(e,{anonId:wd(),sessionId:Td(),firstTouch:this.attribution},window.location.hostname,window.location.href)):e}authorize(e){let t=this.link(e);return this.flush(!0),t}identify(e,t){this.personId=e,this.enqueue(`identify`,void 0,{properties:t})}group(e,t){this.enqueue(`group`,void 0,{groupId:e,properties:t})}pageview(e,t){let n=e??(zf()?window.location.pathname:void 0),r=(n??``)+`\0`+(zf()?window.location.href:``);r!==this.counted&&(this.counted=r,this.enqueue(`pageview`,Ce,{path:n,properties:{...Rf(),...t}}))}capture(e,t,n){this.enqueue(`event`,e,{properties:t,...n})}captureError(e,t){if(!this.reentrant){this.reentrant=!0;try{let n=t?.handled??!0,r=Lf(e);r.handled=n,this.enqueue(`error`,void 0,{error:r,level:t?.level??(n?`error`:`fatal`),release:this.cfg.release??Ff(`NEXT_PUBLIC_HANZO_RELEASE`),environment:this.cfg.environment??Ff(`NODE_ENV`),site:zf()?window.location.hostname:void 0,properties:t?.properties}),this.flush()}catch{}finally{this.reentrant=!1}}}setCohort(e){this.cohort=Nd(e)}flush(e=!1){if(!this.cfg.enabled||this.queue.length===0)return;let t=this.queue.map(Bf);if(this.queue=[],this.clearTimer(),t.length===0)return;let n=this.cfg.getToken?.()??void 0,r=this.cfg.ingestKey?.trim()||void 0,i=e&&!n,a=Vf(t);if(a===null){this.cfg.debug&&console.debug(`[event] flush → dropped, batch unserializable`);return}this.cfg.debug&&console.debug(`[event] flush →`,Mf,t.length),this.transport.send(this.cfg.host+Mf,a,{beacon:i,token:n,ingestKey:r,debug:this.cfg.debug})}enqueue(e,t,n){this.cfg.enabled&&(this.started||this.init(),this.queue.push(this.build(e,t,n)),this.queue.length>=this.cfg.batchSize?this.flush():this.schedule())}build(e,t,n){let r=wd(),i={messageId:dd(),type:e,event:t,timestamp:new Date().toISOString(),distinctId:this.personId??r,anonymousId:r,personId:this.personId,sessionId:Td(),product:this.cfg.product,referrer:this.attribution.referrer,utm:this.attribution.utm,lastUtm:this.lastUtm,refCode:this.cohort.refCode??this.attribution.refCode,channel:this.cohort.channel??this.attribution.channel,signupWeek:this.cohort.signupWeek,url:zf()?window.location.href:void 0,path:zf()?window.location.pathname:void 0,library:`@hanzo/event`,libraryVersion:jf,...n},a=this.cfg.capturePII??!1;return i.url&&=Yu(Gu(i.url),a),i.path&&=Yu(Gu(i.path),a),i.referrer&&=Yu(Gu(i.referrer),a),Gd()&&(i.properties={...i.properties,internal:!0}),zf()&&(i.properties={...i.properties,consent:Tf(Cf())}),i}schedule(){!this.timer&&this.cfg.enabled&&(this.timer=setTimeout(()=>{this.timer=null,this.flush()},this.cfg.flushIntervalMs))}clearTimer(){this.timer&&=(clearTimeout(this.timer),null)}},Wf=Symbol.for(`hanzo.event.clients.optin`);function Gf(){let e=globalThis,t=e[Wf];if(t)return t;let n=new Map;return e[Wf]=n,n}function Kf(e){if(!zf()||e.enabled===!1)return new Uf(e);let t=(e.host??Nf)+`\0`+e.product,n=Gf(),r=n.get(t);if(r)return r.adopt(e),r;let i=new Uf(e);return n.set(t,i),i}var qf=(0,V.createContext)(null);function Jf(e){let{client:t,config:n,autoPageview:r=!0,children:i}=e;if(!t&&!n)throw Error("AnalyticsProvider requires `client` or `config`");let a=t??Kf(n);return(0,V.useEffect)(()=>{a.init(),r&&a.pageview()},[a,r]),(0,V.createElement)(qf.Provider,{value:a},i)}new Uf({product:`unknown`,enabled:!1});var Yf=class extends V.Component{constructor(){super(...arguments),this.state={error:null},this.reset=()=>this.setState({error:null})}static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){(this.props.client??this.context??void 0)?.captureError(e,{handled:!1,properties:{componentStack:t.componentStack,react:!0}})}render(){let{error:e}=this.state;if(e===null)return this.props.children;let{fallback:t}=this.props;return typeof t==`function`?t(e,this.reset):t??null}};Yf.contextType=qf;var Xf=Yf.contextType;function Zf(){return(0,V.useContext)(Xf)}function Qf(e,t,n){(0,V.useEffect)(()=>{if(!t||typeof window>`u`||typeof document>`u`)return;let r=!1,i,a=()=>{r||Le(async()=>{let{observe:e,wireProps:t}=await import(`./dist-Cy8E8G3S.js`);return{observe:e,wireProps:t}},[]).then(({observe:t,wireProps:a})=>{if(r)return;let o=t(t=>{t.kind!==`nav`&&e.track(t.name,a(t))},{nav:!1,redaction:n});i=()=>o.stop()}).catch(()=>{})},o=window,s=typeof o.requestIdleCallback==`function`,c=s?o.requestIdleCallback(a,{timeout:3e3}):window.setTimeout(a,1200);return()=>{r=!0;try{s?o.cancelIdleCallback?.(c):window.clearTimeout(c)}catch{}i?.()}},[e,t])}var $f=e=>{try{let t=window.location,n=e==null||e===``?t:new URL(String(e),t.href);return{key:n.pathname+n.search+n.hash,path:n.pathname}}catch{return{key:``,path:void 0}}};function ep(e,t,n){let r=(0,V.useRef)(null),i=n!==void 0;(0,V.useEffect)(()=>{if(!t||!i||!je())return;let a=n??$f().path??``;r.current!==a&&(r.current=a,e.pageview(a))},[e,t,i,n]),(0,V.useEffect)(()=>{if(!t||i||!je())return;let n=t=>{let{key:n,path:i}=$f(t);r.current!==n&&(r.current=n,e.pageview(i))};n();let a=window.history,o=a.pushState,s=a.replaceState;a.pushState=function(...e){let t=o.apply(this,e);return n(e[2]),t},a.replaceState=function(...e){let t=s.apply(this,e);return n(e[2]),t};let c=()=>n();return window.addEventListener(`popstate`,c),window.addEventListener(`hashchange`,c),()=>{a.pushState=o,a.replaceState=s,window.removeEventListener(`popstate`,c),window.removeEventListener(`hashchange`,c)}},[e,t,i])}var tp=(0,V.createContext)(null);function np(e){let{owner:t=`app`,path:n,fallback:r,client:i,children:a,host:o,product:s,ingestKey:c,getToken:l,enabled:u,consent:d,replay:f,errors:p,pageviews:m,redaction:h,debug:g}=e,_=t===`gui`,v=Zf(),y=v!==null&&_,[b,x]=(0,V.useState)(!1),S=!_||b&&!y;(0,V.useEffect)(()=>{if(!_||y)return;let e=()=>x(!Ue());return e(),Ke(e)},[_,y]);let C=(0,V.useRef)(l);C.current=l;let w=(0,V.useRef)(h);w.current=h;let[T,E]=(0,V.useState)(0);(0,V.useEffect)(()=>{let e=()=>E(e=>e+1),t=Be(e);if(!je())return t;let n=t=>{(t.key===null||t.key===`hz_consent`)&&e()};return window.addEventListener(`storage`,n),()=>{t(),window.removeEventListener(`storage`,n)}},[]);let D=(0,V.useMemo)(()=>i??Ge({host:o,product:s,ingestKey:c,getToken:C.current?()=>C.current?.():void 0,enabled:S?u:!1,consent:d,replay:f,errors:p,pageviews:m,debug:g}),[i,o,s,c,S,u,d,f,p,m,g,T]);(0,V.useEffect)(()=>{if(S)return Ne(D,{app:!_}),D.client.init(),()=>{Re()===D&&Ne(void 0)}},[D,S,_]);let O=D.enabled;return ep(D,O&&(m??!0),n),Qf(D,O&&(f??!0),w.current),(0,H.jsx)(tp.Provider,{value:D,children:(0,H.jsx)(Jf,{client:y&&v?v:D.client,autoPageview:!1,children:(0,H.jsx)(rp,{telemetry:D,enabled:O&&(p??!0),fallback:r,children:a})})})}var rp=class extends V.Component{constructor(){super(...arguments),this.state={error:null},this.reset=()=>this.setState({error:null})}static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){if(this.props.enabled&&this.props.telemetry.captureError(e,{handled:!1,properties:{componentStack:t.componentStack,react:!0}}),this.props.fallback===void 0)throw e}render(){let{error:e}=this.state;if(!e)return this.props.children;let{fallback:t}=this.props;return t===void 0?null:typeof t==`function`?t(e,this.reset):t}},ip=({children:e,telemetry:t,...n})=>{let r=(0,H.jsx)(u,{...n,children:(0,H.jsx)(Kt.Provider,{value:1,children:(0,H.jsx)(wn,{shouldAddRootHost:!0,children:e})})});return t===!1?r:(0,H.jsx)(np,{owner:`gui`,...typeof t==`object`?t:null,children:r})},ap=M(ht,{name:`TextArea`,render:`textarea`,whiteSpace:`pre-wrap`,variants:{unstyled:{false:{height:`auto`,...zt,rows:3}},size:{"...size":Ut}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),op=z.styleable((e,t)=>{let{size:n,color:r,...i}=e,a=A(),o=r;return o&&o[0]===`$`&&(o=de(a[o])),(0,H.jsx)(z,{ref:t,...i,children:(0,H.jsx)(ao,{size:n,color:o})})}),U=M(C,{variants:{unstyled:{false:{color:`$color`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),sp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`10`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,stroke:t})]})})),cp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`19`,cy:`12`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`5`,cy:`12`,r:`1`,stroke:t})]})})),lp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,stroke:t})})})),up=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M15 12H3`,stroke:t}),(0,H.jsx)(N,{d:`M17 18H3`,stroke:t}),(0,H.jsx)(N,{d:`M21 6H3`,stroke:t})]})})),dp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`20`,height:`5`,x:`2`,y:`3`,rx:`1`,stroke:t}),(0,H.jsx)(N,{d:`M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8`,stroke:t}),(0,H.jsx)(N,{d:`M10 12h4`,stroke:t})]})})),fp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m3 16 4 4 4-4`,stroke:t}),(0,H.jsx)(N,{d:`M7 20V4`,stroke:t}),(0,H.jsx)(N,{d:`m21 8-4-4-4 4`,stroke:t}),(0,H.jsx)(N,{d:`M17 4v16`,stroke:t})]})})),pp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12 5v14`,stroke:t}),(0,H.jsx)(N,{d:`m19 12-7 7-7-7`,stroke:t})]})})),mp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m12 19-7-7 7-7`,stroke:t}),(0,H.jsx)(N,{d:`M19 12H5`,stroke:t})]})})),hp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M5 12h14`,stroke:t}),(0,H.jsx)(N,{d:`m12 5 7 7-7 7`,stroke:t})]})})),gp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m5 12 7-7 7 7`,stroke:t}),(0,H.jsx)(N,{d:`M12 19V5`,stroke:t})]})})),_p=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M10.268 21a2 2 0 0 0 3.464 0`,stroke:t}),(0,H.jsx)(N,{d:`M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326`,stroke:t})]})})),vp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12 8V4H8`,stroke:t}),(0,H.jsx)(ae,{width:`16`,height:`12`,x:`4`,y:`8`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M2 14h2`,stroke:t}),(0,H.jsx)(N,{d:`M20 14h2`,stroke:t}),(0,H.jsx)(N,{d:`M15 13v2`,stroke:t}),(0,H.jsx)(N,{d:`M9 13v2`,stroke:t})]})})),yp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z`,stroke:t}),(0,H.jsx)(N,{d:`m7 16.5-4.74-2.85`,stroke:t}),(0,H.jsx)(N,{d:`m7 16.5 5-3`,stroke:t}),(0,H.jsx)(N,{d:`M7 16.5v5.17`,stroke:t}),(0,H.jsx)(N,{d:`M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z`,stroke:t}),(0,H.jsx)(N,{d:`m17 16.5-5-3`,stroke:t}),(0,H.jsx)(N,{d:`m17 16.5 4.74-2.85`,stroke:t}),(0,H.jsx)(N,{d:`M17 16.5v5.17`,stroke:t}),(0,H.jsx)(N,{d:`M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z`,stroke:t}),(0,H.jsx)(N,{d:`M12 8 7.26 5.15`,stroke:t}),(0,H.jsx)(N,{d:`m12 8 4.74-2.85`,stroke:t}),(0,H.jsx)(N,{d:`M12 13.5V8`,stroke:t})]})})),bp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16`,stroke:t}),(0,H.jsx)(ae,{width:`20`,height:`14`,x:`2`,y:`6`,rx:`2`,stroke:t})]})})),xp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z`,stroke:t}),(0,H.jsx)(N,{d:`M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2`,stroke:t}),(0,H.jsx)(N,{d:`M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2`,stroke:t}),(0,H.jsx)(N,{d:`M10 6h4`,stroke:t}),(0,H.jsx)(N,{d:`M10 10h4`,stroke:t}),(0,H.jsx)(N,{d:`M10 14h4`,stroke:t}),(0,H.jsx)(N,{d:`M10 18h4`,stroke:t})]})})),Sp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M8 2v4`,stroke:t}),(0,H.jsx)(N,{d:`M16 2v4`,stroke:t}),(0,H.jsx)(ae,{width:`18`,height:`18`,x:`3`,y:`4`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M3 10h18`,stroke:t}),(0,H.jsx)(N,{d:`M8 14h.01`,stroke:t}),(0,H.jsx)(N,{d:`M12 14h.01`,stroke:t}),(0,H.jsx)(N,{d:`M16 14h.01`,stroke:t}),(0,H.jsx)(N,{d:`M8 18h.01`,stroke:t}),(0,H.jsx)(N,{d:`M12 18h.01`,stroke:t}),(0,H.jsx)(N,{d:`M16 18h.01`,stroke:t})]})})),Cp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M8 2v4`,stroke:t}),(0,H.jsx)(N,{d:`M16 2v4`,stroke:t}),(0,H.jsx)(ae,{width:`18`,height:`18`,x:`3`,y:`4`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M3 10h18`,stroke:t})]})})),wp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`m6 9 6 6 6-6`,stroke:t})})})),Tp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`m15 18-6-6 6-6`,stroke:t})})})),Ep=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`m18 15-6-6-6 6`,stroke:t})})})),Dp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m7 15 5 5 5-5`,stroke:t}),(0,H.jsx)(N,{d:`m7 9 5-5 5 5`,stroke:t})]})})),Op=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`10`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,stroke:t})]})})),kp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`10`,stroke:t}),(0,H.jsx)(N,{d:`m9 12 2 2 4-4`,stroke:t})]})})),Ap=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m2 2 20 20`,stroke:t}),(0,H.jsx)(N,{d:`M8.35 2.69A10 10 0 0 1 21.3 15.65`,stroke:t}),(0,H.jsx)(N,{d:`M19.08 19.08A10 10 0 1 1 4.92 4.92`,stroke:t})]})})),jp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ue,{points:`16 18 22 12 16 6`,stroke:t}),(0,H.jsx)(ue,{points:`8 6 2 12 8 18`,stroke:t})]})})),Mp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`8`,cy:`8`,r:`6`,stroke:t}),(0,H.jsx)(N,{d:`M18.09 10.37A6 6 0 1 1 10.34 18`,stroke:t}),(0,H.jsx)(N,{d:`M7 6h1v4`,stroke:t}),(0,H.jsx)(N,{d:`m16.71 13.88.7.71-2.82 2.82`,stroke:t})]})})),Np=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M9 3v18`,stroke:t}),(0,H.jsx)(N,{d:`M15 3v18`,stroke:t})]})})),Pp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m12 15 2 2 4-4`,stroke:t}),(0,H.jsx)(ae,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,stroke:t}),(0,H.jsx)(N,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,stroke:t})]})})),Fp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,stroke:t}),(0,H.jsx)(N,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,stroke:t})]})})),Ip=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`20`,height:`14`,x:`2`,y:`5`,rx:`2`,stroke:t}),(0,H.jsx)(j,{x1:`2`,x2:`22`,y1:`10`,y2:`10`,stroke:t})]})})),Lp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`2`,y2:`22`,stroke:t}),(0,H.jsx)(N,{d:`M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6`,stroke:t})]})})),Rp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,stroke:t}),(0,H.jsx)(ue,{points:`7 10 12 15 17 10`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`15`,y2:`3`,stroke:t})]})})),zp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`5`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`19`,r:`1`,stroke:t})]})})),Bp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M15 3h6v6`,stroke:t}),(0,H.jsx)(N,{d:`M10 14 21 3`,stroke:t}),(0,H.jsx)(N,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,stroke:t})]})})),Vp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,stroke:t}),(0,H.jsx)(N,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,stroke:t}),(0,H.jsx)(N,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,stroke:t}),(0,H.jsx)(N,{d:`m2 2 20 20`,stroke:t})]})})),Hp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`3`,stroke:t})]})})),Up=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z`,stroke:t}),(0,H.jsx)(N,{d:`M14 2v4a2 2 0 0 0 2 2h4`,stroke:t}),(0,H.jsx)(N,{d:`M10 9H8`,stroke:t}),(0,H.jsx)(N,{d:`M16 13H8`,stroke:t}),(0,H.jsx)(N,{d:`M16 17H8`,stroke:t})]})})),Wp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z`,stroke:t}),(0,H.jsx)(N,{d:`M8 10v4`,stroke:t}),(0,H.jsx)(N,{d:`M12 10v2`,stroke:t}),(0,H.jsx)(N,{d:`M16 10v6`,stroke:t})]})})),Gp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,stroke:t})})})),Kp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`18`,cy:`18`,r:`3`,stroke:t}),(0,H.jsx)(ve,{cx:`6`,cy:`6`,r:`3`,stroke:t}),(0,H.jsx)(N,{d:`M13 6h3a2 2 0 0 1 2 2v7`,stroke:t}),(0,H.jsx)(j,{x1:`6`,x2:`6`,y1:`9`,y2:`21`,stroke:t})]})})),qp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`10`,stroke:t}),(0,H.jsx)(N,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,stroke:t}),(0,H.jsx)(N,{d:`M2 12h20`,stroke:t})]})})),Jp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`9`,cy:`12`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`9`,cy:`5`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`9`,cy:`19`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`15`,cy:`12`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`15`,cy:`5`,r:`1`,stroke:t}),(0,H.jsx)(ve,{cx:`15`,cy:`19`,r:`1`,stroke:t})]})})),Yp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(j,{x1:`4`,x2:`20`,y1:`9`,y2:`9`,stroke:t}),(0,H.jsx)(j,{x1:`4`,x2:`20`,y1:`15`,y2:`15`,stroke:t}),(0,H.jsx)(j,{x1:`10`,x2:`8`,y1:`3`,y2:`21`,stroke:t}),(0,H.jsx)(j,{x1:`16`,x2:`14`,y1:`3`,y2:`21`,stroke:t})]})})),Xp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`10`,stroke:t}),(0,H.jsx)(N,{d:`M12 16v-4`,stroke:t}),(0,H.jsx)(N,{d:`M12 8h.01`,stroke:t})]})})),eee=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M6 5v11`,stroke:t}),(0,H.jsx)(N,{d:`M12 5v6`,stroke:t}),(0,H.jsx)(N,{d:`M18 5v14`,stroke:t})]})})),Zp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z`,stroke:t}),(0,H.jsx)(N,{d:`M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12`,stroke:t}),(0,H.jsx)(N,{d:`M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17`,stroke:t})]})})),Qp=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,stroke:t}),(0,H.jsx)(ae,{width:`7`,height:`7`,x:`14`,y:`3`,rx:`1`,stroke:t}),(0,H.jsx)(ae,{width:`7`,height:`7`,x:`14`,y:`14`,rx:`1`,stroke:t}),(0,H.jsx)(ae,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,stroke:t})]})})),$p=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M9 17H7A5 5 0 0 1 7 7h2`,stroke:t}),(0,H.jsx)(N,{d:`M15 7h2a5 5 0 1 1 0 10h-2`,stroke:t}),(0,H.jsx)(j,{x1:`8`,x2:`16`,y1:`12`,y2:`12`,stroke:t})]})})),em=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M3 6h18`,stroke:t}),(0,H.jsx)(N,{d:`M7 12h10`,stroke:t}),(0,H.jsx)(N,{d:`M10 18h4`,stroke:t})]})})),tm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M3 12h.01`,stroke:t}),(0,H.jsx)(N,{d:`M3 18h.01`,stroke:t}),(0,H.jsx)(N,{d:`M3 6h.01`,stroke:t}),(0,H.jsx)(N,{d:`M8 12h13`,stroke:t}),(0,H.jsx)(N,{d:`M8 18h13`,stroke:t}),(0,H.jsx)(N,{d:`M8 6h13`,stroke:t})]})})),nm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`18`,height:`11`,x:`3`,y:`11`,rx:`2`,ry:`2`,stroke:t}),(0,H.jsx)(N,{d:`M7 11V7a5 5 0 0 1 10 0v4`,stroke:t})]})})),rm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,stroke:t}),(0,H.jsx)(ue,{points:`16 17 21 12 16 7`,stroke:t}),(0,H.jsx)(j,{x1:`21`,x2:`9`,y1:`12`,y2:`12`,stroke:t})]})})),im=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7`,stroke:t}),(0,H.jsx)(ae,{x:`2`,y:`4`,width:`20`,height:`16`,rx:`2`,stroke:t})]})})),am=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`10`,r:`3`,stroke:t})]})})),om=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ue,{points:`15 3 21 3 21 9`,stroke:t}),(0,H.jsx)(ue,{points:`9 21 3 21 3 15`,stroke:t}),(0,H.jsx)(j,{x1:`21`,x2:`14`,y1:`3`,y2:`10`,stroke:t}),(0,H.jsx)(j,{x1:`3`,x2:`10`,y1:`21`,y2:`14`,stroke:t})]})})),sm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M7.9 20A9 9 0 1 0 4 16.1L2 22Z`,stroke:t}),(0,H.jsx)(N,{d:`M8 12h.01`,stroke:t}),(0,H.jsx)(N,{d:`M12 12h.01`,stroke:t}),(0,H.jsx)(N,{d:`M16 12h.01`,stroke:t})]})})),cm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`,stroke:t})})})),lm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M14 9a2 2 0 0 1-2 2H6l-4 4V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2z`,stroke:t}),(0,H.jsx)(N,{d:`M18 9h2a2 2 0 0 1 2 2v11l-4-4h-6a2 2 0 0 1-2-2v-1`,stroke:t})]})})),um=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M5 12h14`,stroke:t})})})),dm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z`,stroke:t})})})),fm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M9 3v18`,stroke:t})]})})),pm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M13.234 20.252 21 12.3`,stroke:t}),(0,H.jsx)(N,{d:`m16 6-8.414 8.586a2 2 0 0 0 0 2.828 2 2 0 0 0 2.828 0l8.414-8.586a4 4 0 0 0 0-5.656 4 4 0 0 0-5.656 0l-8.415 8.585a6 6 0 1 0 8.486 8.486`,stroke:t})]})})),mm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{x:`14`,y:`4`,width:`4`,height:`16`,rx:`1`,stroke:t}),(0,H.jsx)(ae,{x:`6`,y:`4`,width:`4`,height:`16`,rx:`1`,stroke:t})]})})),hm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M5 12h14`,stroke:t}),(0,H.jsx)(N,{d:`M12 5v14`,stroke:t})]})})),gm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,stroke:t}),(0,H.jsx)(N,{d:`M21 3v5h-5`,stroke:t}),(0,H.jsx)(N,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,stroke:t}),(0,H.jsx)(N,{d:`M8 16H3v5`,stroke:t})]})})),_m=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,stroke:t}),(0,H.jsx)(N,{d:`M3 3v5h5`,stroke:t})]})})),vm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m21 21-4.34-4.34`,stroke:t}),(0,H.jsx)(ve,{cx:`11`,cy:`11`,r:`8`,stroke:t})]})})),ym=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`3`,stroke:t})]})})),bm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`18`,cy:`5`,r:`3`,stroke:t}),(0,H.jsx)(ve,{cx:`6`,cy:`12`,r:`3`,stroke:t}),(0,H.jsx)(ve,{cx:`18`,cy:`19`,r:`3`,stroke:t}),(0,H.jsx)(j,{x1:`8.59`,x2:`15.42`,y1:`13.51`,y2:`17.49`,stroke:t}),(0,H.jsx)(j,{x1:`15.41`,x2:`8.59`,y1:`6.51`,y2:`10.49`,stroke:t})]})})),xm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,stroke:t}),(0,H.jsx)(N,{d:`m9 12 2 2 4-4`,stroke:t})]})})),Sm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(j,{x1:`21`,x2:`14`,y1:`4`,y2:`4`,stroke:t}),(0,H.jsx)(j,{x1:`10`,x2:`3`,y1:`4`,y2:`4`,stroke:t}),(0,H.jsx)(j,{x1:`21`,x2:`12`,y1:`12`,y2:`12`,stroke:t}),(0,H.jsx)(j,{x1:`8`,x2:`3`,y1:`12`,y2:`12`,stroke:t}),(0,H.jsx)(j,{x1:`21`,x2:`16`,y1:`20`,y2:`20`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`3`,y1:`20`,y2:`20`,stroke:t}),(0,H.jsx)(j,{x1:`14`,x2:`14`,y1:`2`,y2:`6`,stroke:t}),(0,H.jsx)(j,{x1:`8`,x2:`8`,y1:`10`,y2:`14`,stroke:t}),(0,H.jsx)(j,{x1:`16`,x2:`16`,y1:`18`,y2:`22`,stroke:t})]})})),Cm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M22 11v1a10 10 0 1 1-9-10`,stroke:t}),(0,H.jsx)(N,{d:`M8 14s1.5 2 4 2 4-2 4-2`,stroke:t}),(0,H.jsx)(j,{x1:`9`,x2:`9.01`,y1:`9`,y2:`9`,stroke:t}),(0,H.jsx)(j,{x1:`15`,x2:`15.01`,y1:`9`,y2:`9`,stroke:t}),(0,H.jsx)(N,{d:`M16 5h6`,stroke:t}),(0,H.jsx)(N,{d:`M19 2v6`,stroke:t})]})})),wm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z`,stroke:t}),(0,H.jsx)(N,{d:`M20 3v4`,stroke:t}),(0,H.jsx)(N,{d:`M22 5h-4`,stroke:t}),(0,H.jsx)(N,{d:`M4 17v2`,stroke:t}),(0,H.jsx)(N,{d:`M5 18H3`,stroke:t})]})})),Tm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`m9 12 2 2 4-4`,stroke:t})]})})),Em=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z`,stroke:t})})})),tee=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ve,{cx:`12`,cy:`12`,r:`4`,stroke:t}),(0,H.jsx)(N,{d:`M12 2v2`,stroke:t}),(0,H.jsx)(N,{d:`M12 20v2`,stroke:t}),(0,H.jsx)(N,{d:`m4.93 4.93 1.41 1.41`,stroke:t}),(0,H.jsx)(N,{d:`m17.66 17.66 1.41 1.41`,stroke:t}),(0,H.jsx)(N,{d:`M2 12h2`,stroke:t}),(0,H.jsx)(N,{d:`M20 12h2`,stroke:t}),(0,H.jsx)(N,{d:`m6.34 17.66-1.41 1.41`,stroke:t}),(0,H.jsx)(N,{d:`m19.07 4.93-1.41 1.41`,stroke:t})]})})),Dm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18`,stroke:t})})})),Om=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z`,stroke:t}),(0,H.jsx)(ve,{cx:`7.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,stroke:t})]})})),km=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M3 6h18`,stroke:t}),(0,H.jsx)(N,{d:`M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6`,stroke:t}),(0,H.jsx)(N,{d:`M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2`,stroke:t}),(0,H.jsx)(j,{x1:`10`,x2:`10`,y1:`11`,y2:`17`,stroke:t}),(0,H.jsx)(j,{x1:`14`,x2:`14`,y1:`11`,y2:`17`,stroke:t})]})})),Am=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ue,{points:`22 7 13.5 15.5 8.5 10.5 2 17`,stroke:t}),(0,H.jsx)(ue,{points:`16 7 22 7 22 13`,stroke:t})]})})),jm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`,stroke:t}),(0,H.jsx)(N,{d:`M12 9v4`,stroke:t}),(0,H.jsx)(N,{d:`M12 17h.01`,stroke:t})]})})),Mm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ue,{points:`4 7 4 4 20 4 20 7`,stroke:t}),(0,H.jsx)(j,{x1:`9`,x2:`15`,y1:`20`,y2:`20`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`4`,y2:`20`,stroke:t})]})})),Nm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,stroke:t}),(0,H.jsx)(ue,{points:`17 8 12 3 7 8`,stroke:t}),(0,H.jsx)(j,{x1:`12`,x2:`12`,y1:`3`,y2:`15`,stroke:t})]})})),Pm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,stroke:t}),(0,H.jsx)(ve,{cx:`9`,cy:`7`,r:`4`,stroke:t}),(0,H.jsx)(j,{x1:`19`,x2:`19`,y1:`8`,y2:`14`,stroke:t}),(0,H.jsx)(j,{x1:`22`,x2:`16`,y1:`11`,y2:`11`,stroke:t})]})})),Fm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2`,stroke:t}),(0,H.jsx)(ve,{cx:`12`,cy:`7`,r:`4`,stroke:t})]})})),Im=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,stroke:t}),(0,H.jsx)(N,{d:`M16 3.128a4 4 0 0 1 0 7.744`,stroke:t}),(0,H.jsx)(N,{d:`M22 21v-2a4 4 0 0 0-3-3.87`,stroke:t}),(0,H.jsx)(ve,{cx:`9`,cy:`7`,r:`4`,stroke:t})]})})),Lm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M18 16.98h-5.99c-1.1 0-1.95.94-2.48 1.9A4 4 0 0 1 2 17c.01-.7.2-1.4.57-2`,stroke:t}),(0,H.jsx)(N,{d:`m6 17 3.13-5.78c.53-.97.1-2.18-.5-3.1a4 4 0 1 1 6.89-4.06`,stroke:t}),(0,H.jsx)(N,{d:`m12 6 3.13 5.73C15.66 12.7 16.9 13 18 13a4 4 0 0 1 0 8`,stroke:t})]})})),Rm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(N,{d:`M12 20h.01`,stroke:t}),(0,H.jsx)(N,{d:`M2 8.82a15 15 0 0 1 20 0`,stroke:t}),(0,H.jsx)(N,{d:`M5 12.859a10 10 0 0 1 14 0`,stroke:t}),(0,H.jsx)(N,{d:`M8.5 16.429a5 5 0 0 1 7 0`,stroke:t})]})})),zm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsxs)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:[(0,H.jsx)(ae,{width:`8`,height:`8`,x:`3`,y:`3`,rx:`2`,stroke:t}),(0,H.jsx)(N,{d:`M7 11v4a2 2 0 0 0 2 2h4`,stroke:t}),(0,H.jsx)(ae,{width:`8`,height:`8`,x:`13`,y:`13`,rx:`2`,stroke:t})]})})),Bm=L((0,V.memo)(function(e){let{color:t=`black`,size:n=24,...r}=e;return(0,H.jsx)(F,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,stroke:t,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...r,children:(0,H.jsx)(N,{d:`M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z`,stroke:t})})})),Vm=(e,t=a,n={})=>V.Children.map(e,e=>typeof e==`string`||typeof e==`number`?(0,V.createElement)(t,n,e):e),Hm=(0,V.createContext)(null),Um={borderWidth:1,borderColor:`$rim`,rounded:`$xs`,p:`$0.5`,bg:`$panel`};function Wm({attached:e=!0,framed:t=!1,size:n,variant:r,tone:i,children:a,...o}){let s=V.Children.toArray(a).filter(V.isValidElement),c={size:n,variant:r,tone:i,framed:t},l=t?Um:null;return e?(0,H.jsx)(Hm.Provider,{value:c,children:(0,H.jsx)(is,{...B(`button-group`),"data-attached":``,role:`group`,unstyled:!0,display:`inline-flex`,self:`flex-start`,items:`center`,...l,...o,children:s.map((e,t)=>(0,H.jsx)(is.Item,{...t>0?{marginInlineStart:-1}:null,focusStyle:{zIndex:1},children:e},e.key??t))})}):(0,H.jsx)(Hm.Provider,{value:c,children:(0,H.jsx)(y,{...B(`button-group`),role:`group`,display:`inline-flex`,self:`flex-start`,items:`center`,gap:`$0.5`,...l,...o,children:s})})}var Gm=10,Km=600,nee=300,qm=(0,V.createContext)(null),Jm=(0,V.createContext)(!1),Ym=({offset:e=Gm,delay:t,...n})=>{let[r,i]=(0,V.useState)({}),a=(0,V.useCallback)(e=>i(t=>({...t,...e})),[]),o=(0,V.useContext)(Jm);return(0,H.jsx)(qm.Provider,{value:a,children:(0,H.jsx)(pu,{offset:r.offset??e,delay:t??(o?void 0:Km),...n})})},Xm=pu.Trigger,Zm=({delay:e=Km,...t})=>(0,H.jsx)(Jm.Provider,{value:!0,children:(0,H.jsx)(cu,{delay:e,...t})}),Qm=({sideOffset:e,startIcon:t,description:n,children:r,...i})=>{let a=dn(),o=(0,V.useContext)(qm);return(0,V.useEffect)(()=>{e!==void 0&&o?.({offset:e})},[o,e]),(0,H.jsx)(_t,{name:a,children:(0,H.jsx)(pu.Content,{...B(`tooltip-content`),componentName:`Hint`,bg:`$panel`,borderWidth:1,borderColor:`$borderColor`,rounded:`$3`,px:`$1.5`,py:`$1`,maxW:nee,...i,children:t||n?(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$1`,children:[t?(0,H.jsx)(y,{shrink:0,children:t}):null,Vm(r,void 0,{size:`$1`,fontWeight:`500`})]}),n?typeof n==`string`?(0,H.jsx)(U,{...B(`tooltip-description`),fontSize:`$1`,lineHeight:`$1`,color:`$aside`,style:{whiteSpace:`pre-line`},children:n}):n:null]}):Vm(r,void 0,{size:`$1`})})})},$m={"data-i18n-mirror":``},eh={"data-i18n-ltr":``},th=e=>typeof e==`string`?`\u2066${e}\u2069`:e,nh=e=>({textAlign:e}),rh=e=>typeof Element<`u`&&e instanceof Element&&getComputedStyle(e).direction===`rtl`,ih=e=>{let t=e.key??``;return rh(e.currentTarget)?t===`ArrowLeft`?`ArrowRight`:t===`ArrowRight`?`ArrowLeft`:t:t},ah=20,oh=M(y,{name:`Kbd`,render:`kbd`,display:`inline-flex`,pointerEvents:`none`,style:{userSelect:`none`},items:`center`,justify:`center`,gap:`$1`,height:ah,minW:ah,px:`$1`,rounded:`$1`,bg:`$hover`}),sh=M(a,{name:`KbdText`,size:`$1`,fontWeight:`500`,color:`$quiet`}),ch={height:18,minW:16,px:`$0.5`,bg:`$panel`,borderWidth:1,borderColor:`$rim`,rounded:`$xs`,style:{userSelect:`none`,boxShadow:`var(--shadow-underline, 0 1px 0 0 var(--border-strong))`}};function lh({children:e,variant:t=`default`,...n}){return(0,H.jsx)(oh,{"data-slot":`kbd`,...eh,...t===`cap`?{"data-variant":`cap`,...ch}:null,...n,children:Vm(e,sh,t===`cap`?{color:`$aside`}:{})})}var uh=e=>{let t=e===`mac`,n=t?{glyph:`⌘`,word:`Command`}:{glyph:`Ctrl`,word:`Control`};return{mod:n,commandorcontrol:n,cmdorctrl:n,command:{glyph:`⌘`,word:`Command`},cmd:{glyph:`⌘`,word:`Command`},meta:{glyph:`⌘`,word:`Command`},control:t?{glyph:`⌃`,word:`Control`}:{glyph:`Ctrl`,word:`Control`},ctrl:t?{glyph:`⌃`,word:`Control`}:{glyph:`Ctrl`,word:`Control`},alt:t?{glyph:`⌥`,word:`Option`}:{glyph:`Alt`,word:`Alt`},option:t?{glyph:`⌥`,word:`Option`}:{glyph:`Alt`,word:`Alt`},shift:{glyph:`⇧`,word:`Shift`},enter:{glyph:`⏎`,word:`Enter`},return:{glyph:`⏎`,word:`Enter`},backspace:{glyph:`⌫`,word:`Backspace`},delete:{glyph:`⌦`,word:`Delete`},escape:{glyph:`esc`,word:`Escape`},esc:{glyph:`esc`,word:`Escape`},tab:{glyph:`⇥`,word:`Tab`},space:{glyph:`Space`,word:`Space`},arrowup:{glyph:`↑`,word:`Up arrow`},arrowdown:{glyph:`↓`,word:`Down arrow`},arrowleft:{glyph:`←`,word:`Left arrow`},arrowright:{glyph:`→`,word:`Right arrow`},up:{glyph:`↑`,word:`Up arrow`},down:{glyph:`↓`,word:`Down arrow`},left:{glyph:`←`,word:`Left arrow`},right:{glyph:`→`,word:`Right arrow`}}},dh=(e,t)=>{let n=uh(t)[e.toLowerCase()];if(n)return n;let r=e.length===1?e.toUpperCase():e;return{glyph:r,word:r}},fh=e=>e.length>0&&Array.isArray(e[0])?e.map(e=>[...e]):[[...e]];function ph(e,t={}){let n=t.platform??hh(),r=t.combinationSeparator??(n===`mac`?``:` `);return fh(e).map(e=>e.map(e=>dh(e,n).glyph).join(r)).join(` ${t.sequenceJoinLabel??`then`} `)}function mh(e,t,n=`then`){return fh(e).map(e=>e.map(e=>dh(e,t).word).join(` + `)).join(` ${n} `)}function hh(){if(typeof navigator>`u`)return`other`;let e=navigator,t=e.userAgentData?.platform??e.platform??e.userAgent??``;return/mac|iphone|ipad|ipod/i.test(t)?`mac`:`other`}var gh=()=>()=>{};function _h({keys:e,platform:t,variant:n=`keys`,visibility:r=`always`,sequenceJoinLabel:i,combinationSeparator:o,...s}){let{t:c}=R(),l=i??c(`then`),u=(0,V.useSyncExternalStore)(gh,hh,()=>`other`),d=t??u,f=mh(e,d,l),p=r===`desktop`?{$touchable:{display:`none`}}:null,m={...B(`shortcut`),"data-variant":n,role:`img`,"aria-label":f,display:`inline-flex`,items:`center`,...p};if(n===`text`||n===`button`){let t=ph(e,{platform:d,sequenceJoinLabel:l,combinationSeparator:o});return(0,H.jsxs)(y,{...m,...n===`button`?{gap:6,marginInlineStart:`$1`,opacity:.5}:null,...s,children:[n===`button`?(0,H.jsx)(y,{"aria-hidden":!0,width:1,height:8,opacity:.4,style:{backgroundColor:`currentColor`}}):null,(0,H.jsx)(a,{"aria-hidden":!0,size:`$2`,...n===`button`?{fontWeight:`500`}:null,children:th(t)})]})}let h=fh(e);return(0,H.jsx)(y,{...m,gap:`$1`,...s,children:(0,H.jsx)(y,{...eh,display:`inline-flex`,items:`center`,gap:`$1`,children:h.map((e,t)=>(0,H.jsxs)(y,{"aria-hidden":!0,display:`inline-flex`,items:`center`,gap:`$1`,children:[t>0?(0,H.jsx)(a,{size:`$1`,color:`$hint`,children:l}):null,e.map((e,t)=>(0,H.jsx)(lh,{variant:`cap`,children:dh(e,d).glyph},t))]},t))})})}var vh=({variant:e,size:t,className:n}={})=>[...new Set([`btn`,`btn-${e??`default`}`,`btn-${t??`default`}`,n].filter(Boolean))].join(` `),yh=({variant:e}={})=>`badge badge-${e??`default`}`,bh=44,xh={default:36,sm:32,xs:24,lg:40,icon:36,"icon-sm":32,"icon-xs":24,"icon-2xs":20,"icon-lg":40},Sh={default:`$3`,sm:`$2`,xs:`$2`,lg:`$3`,icon:`$3`,"icon-sm":`$2`,"icon-xs":`$2`,"icon-2xs":`$1`,"icon-lg":`$3`},Ch={default:16,sm:14,xs:14,lg:16,icon:16,"icon-sm":16,"icon-xs":14,"icon-2xs":14,"icon-lg":20},wh={default:16,sm:14,xs:12,lg:16,icon:16,"icon-sm":14,"icon-xs":12,"icon-2xs":12,"icon-lg":16},Th=M(Je.Frame,{name:`Button`,items:`center`,justify:`center`,gap:`$2`,shrink:0,rounded:`$3`,borderWidth:1,borderColor:`transparent`,cursor:`pointer`,variants:{variant:{default:{bg:`$panel`,color:`$ink`,borderColor:`$borderColor`,hoverStyle:{bg:`$hover`,borderColor:`$rim`}},primary:{bg:`$accentBackground`,color:`$accentColor`,borderColor:`$rim`,hoverStyle:{bg:`$accentHover`,borderColor:`$bound`}},destructive:{bg:`var(--destructive)`,color:`var(--destructive-foreground)`,hoverStyle:{bg:`var(--destructive-hover)`}},outline:{bg:`$background`,color:`$ink`,borderColor:`$borderColor`,hoverStyle:{bg:`$hover`}},secondary:{bg:`$edge`,color:`$ink`,hoverStyle:{opacity:.8}},ghost:{bg:`transparent`,color:`$ink`,hoverStyle:{bg:`$hover`}},link:{bg:`transparent`,color:`$ink`,hoverStyle:{textDecorationLine:`underline`}},linkFG:{bg:`transparent`,color:`$ink`,hoverStyle:{textDecorationLine:`underline`}},linkMuted:{bg:`transparent`,color:`$quiet`,hoverStyle:{color:`$ink`,textDecorationLine:`underline`}}},size:{default:{height:`auto`,minHeight:xh.default,px:`$4`,$touchable:{minHeight:bh}},sm:{height:`auto`,minHeight:xh.sm,px:`$3`,gap:`$1.5`,$touchable:{minHeight:bh}},xs:{height:`auto`,minHeight:xh.xs,px:`$2`,gap:`$1`,$touchable:{minHeight:bh}},lg:{height:`auto`,minHeight:xh.lg,px:`$6`,$touchable:{minHeight:bh}},icon:{height:`auto`,minHeight:xh.icon,width:`auto`,minWidth:xh.icon,px:0,$touchable:{minHeight:bh,minWidth:bh}},"icon-sm":{height:`auto`,minHeight:xh[`icon-sm`],width:`auto`,minWidth:xh[`icon-sm`],px:0,$touchable:{minHeight:bh,minWidth:bh}},"icon-xs":{height:`auto`,minHeight:xh[`icon-xs`],width:`auto`,minWidth:xh[`icon-xs`],px:0,$touchable:{minHeight:bh,minWidth:bh}},"icon-2xs":{height:`auto`,minHeight:xh[`icon-2xs`],width:`auto`,minWidth:xh[`icon-2xs`],px:0,rounded:`$xs`,$touchable:{minHeight:bh,minWidth:bh}},"icon-lg":{height:`auto`,minHeight:xh[`icon-lg`],width:`auto`,minWidth:xh[`icon-lg`],px:0,$touchable:{minHeight:bh,minWidth:bh}}},compact:{true:{px:`$2`,gap:`$1`}},tone:(e,{props:t})=>{let n=Eh[e];if(!n)return{};switch(t.variant){case`primary`:return{bg:n.fill,color:n.fillInk,borderColor:`transparent`,hoverStyle:{bg:n.fillHover,borderColor:`transparent`}};case`secondary`:return{bg:n.soft,color:n.ink,hoverStyle:{bg:n.softHover,opacity:1}};case`ghost`:return{color:n.ink,hoverStyle:{bg:n.tint}};case`default`:case`outline`:case void 0:return{color:n.ink,borderColor:n.edge,hoverStyle:{bg:n.tint,borderColor:n.edge}};default:return{color:n.ink}}},elevated:(e,{props:t})=>e?{...t.variant==="default"||t.variant===`outline`||t.variant===void 0?{bg:`var(--surface-page)`,borderColor:`$rim`}:null}:{},fullWidth:{true:{width:`100%`,self:`stretch`}},round:{true:{rounded:`$10`}},disabled:{true:{opacity:.5,pointerEvents:`none`,cursor:`default`}}},defaultVariants:{variant:`default`,size:`default`}}),Eh={accent:{ink:`var(--primary)`,edge:`var(--primary)`,tint:`$hover`,soft:`$hover`,softHover:`$raised`,fill:`var(--primary)`,fillInk:`var(--primary-foreground)`,fillHover:`var(--primary-hover)`},danger:{ink:`$bad`,edge:`$red7`,tint:`var(--state-error-bg)`,soft:`var(--state-error-bg)`,softHover:`$red4`,fill:`var(--destructive)`,fillInk:`var(--destructive-foreground)`,fillHover:`var(--destructive-hover)`},success:{ink:`$good`,edge:`$green7`,tint:`var(--state-success-bg)`,soft:`var(--state-success-bg)`,softHover:`$green4`,fill:`$green9`,fillInk:`#ffffff`,fillHover:`$green10`}},Dh=(e,t)=>{if(e!==`neutral`)return t===`primary`?Eh[e].fillInk:Eh[e].ink},Oh=(e,t,n)=>{if(!(0,V.isValidElement)(e))return e;let r=e.props,i={...r.size==null?{size:t}:null,...n&&r.color==null?{color:n}:null};return Object.keys(i).length?(0,V.cloneElement)(e,i):e},kh=new Set([`icon-xs`,`icon-2xs`]),Ah=1e3;function W({tooltip:e,...t}){if(e==null||e===!1)return(0,H.jsx)(jh,{...t});let n=typeof e==`string`&&t[`aria-label`]==null?{"aria-label":e}:null;return(0,H.jsxs)(Ym,{delay:Ah,placement:`bottom`,children:[(0,H.jsx)(Xm,{asChild:!0,children:(0,H.jsx)(jh,{...t,...t.disabled?{focusableWhenDisabled:!0}:null,...n})}),(0,H.jsx)(Qm,{children:e})]})}function jh({className:e,variant:t,size:n,asChild:r=!1,isLoading:i=!1,disabled:a,startIcon:o,endIcon:s,shortcut:c,shortcutJoinLabel:l,emphasis:u=`standard`,tone:d,loadingPosition:f=`start`,fullWidth:p,elevated:m,shape:h,focusableWhenDisabled:g,children:_,...v}){let b=st(),x=(0,V.useContext)(Hm),S=t??x?.variant??`default`,C=d??x?.tone??`neutral`,w=n??x?.size??(b===`compact`?`sm`:`default`),T=b===`compact`&&n==null&&x?.size==null,E=u===`subtle`?{color:`$hint`}:null,D=u===`subtle`?`$hint`:Dh(C,S),O=b===`compact`?{fontWeight:`500`}:null,k=!!a&&!!g,A=i&&f===`center`,j=(0,H.jsx)(op,{"aria-hidden":!0,size:`small`,maxW:wh[w],maxH:wh[w]}),ee=r&&(0,V.isValidElement)(_)?_:null,M=ee?ee.props.children:_,N=ee!=null&&ee.props.href!=null;return(0,H.jsxs)(Th,{"data-slot":`button`,"data-variant":S,"data-size":w,...C===`neutral`?null:{"data-tone":C},variant:S,size:w,...T?{compact:!0}:null,...C===`neutral`?null:{tone:C},...m?{elevated:!0}:null,...p?{fullWidth:!0}:null,...h===`round`?{round:!0}:null,...x?.framed?{rounded:1}:null,...A?{position:`relative`}:null,...ee?{render:(0,V.createElement)(ee.type,{...ee.props,children:void 0})}:null,...N?{role:void 0}:null,disabled:k?!1:a||i,...k?{"aria-disabled":!0,opacity:.5,cursor:`not-allowed`}:null,...dt(xh[w],44,`y`),...Ot(vh({variant:S,size:n,className:m?[e,`elevation-1`].filter(Boolean).join(` `):e})),...v,...k?{onPress:void 0,onClick:e=>e?.preventDefault?.()}:null,children:[i&&f===`start`?j:null,A?(0,H.jsx)(y,{position:`absolute`,t:0,b:0,l:0,r:0,items:`center`,justify:`center`,pointerEvents:`none`,children:j}):null,o?Oh(o,Ch[w],D):null,Vm(kh.has(w)?Oh(M,Ch[w],D):M,Je.Text,{fontSize:Sh[w],...O,...E,...A?{opacity:0}:null}),c&&c.length?(0,H.jsx)(_h,{keys:c,variant:`button`,sequenceJoinLabel:l,...A?{opacity:0}:null}):null,s?Oh(s,Ch[w],D):null,i&&f===`end`?j:null]})}var Mh=[`red`,`ruby`,`crimson`,`tomato`,`orange`,`amber`,`yellow`,`lime`,`grass`,`green`,`jade`,`mint`,`teal`,`cyan`,`sky`,`blue`,`iris`,`violet`,`purple`,`plum`,`pink`,`bronze`,`gold`,`brown`,`gray`],Nh={red:{light:[`#fffcfc`,`#fff7f7`,`#feebec`,`#ffdbdc`,`#ffcdce`,`#fdbdbe`,`#f4a9aa`,`#eb8e90`,`#e5484d`,`#dd3e42`,`#ce2c31`,`#641723`],dark:[`#191111`,`#201314`,`#3b1219`,`#500e1c`,`#611623`,`#73232d`,`#8c333a`,`#b54548`,`#e5484d`,`#ec5e5e`,`#ff8a88`,`#ffd1d9`]},ruby:{light:[`#fffcfd`,`#fff7f8`,`#feeaed`,`#ffdce1`,`#fecfd6`,`#f8bfc8`,`#efacb8`,`#e592a3`,`#e54666`,`#dc3b5d`,`#ca244d`,`#64172b`],dark:[`#191113`,`#1e1517`,`#3a141e`,`#4e1325`,`#5e1a2e`,`#6f2539`,`#883447`,`#b3445a`,`#e54666`,`#ec5a72`,`#ff8a94`,`#fed2e1`]},crimson:{light:[`#fffcfd`,`#fef7f9`,`#ffe9f0`,`#fedce7`,`#facedd`,`#f3bed1`,`#eaacc3`,`#e094b2`,`#e93d82`,`#df3478`,`#cb1d63`,`#621639`],dark:[`#191114`,`#201318`,`#381525`,`#4d122f`,`#5c1839`,`#6d2445`,`#873357`,`#b0436e`,`#e93d82`,`#ee528a`,`#ff87a8`,`#fdd3e8`]},tomato:{light:[`#fffcfc`,`#fff8f7`,`#ffebe7`,`#ffdcd3`,`#ffcdc2`,`#fdbdaf`,`#f5a898`,`#ec8e7b`,`#e54d2e`,`#dd4425`,`#d13415`,`#5c271f`],dark:[`#181111`,`#1f1513`,`#391714`,`#4e1511`,`#5e1c16`,`#6e2920`,`#863a2d`,`#ac4d39`,`#e54d2e`,`#ec6142`,`#ff8e6c`,`#fbd3cb`]},orange:{light:[`#fefcfb`,`#fff7ed`,`#ffefd6`,`#ffdda9`,`#ffcf8b`,`#ffc182`,`#f5ae73`,`#ec9455`,`#f76a15`,`#ef5f00`,`#d14e00`,`#582d1d`],dark:[`#17120e`,`#1e160f`,`#331e0b`,`#481f00`,`#562800`,`#66350c`,`#7e451d`,`#a35829`,`#f76a15`,`#ff791b`,`#ff9b52`,`#ffe0c2`]},amber:{light:[`#fefdfb`,`#fefbe9`,`#fff7c2`,`#ffee9c`,`#fbe577`,`#f4d673`,`#e9c163`,`#e2a336`,`#ffc100`,`#ffba18`,`#ad6200`,`#4f3422`],dark:[`#16120c`,`#1d180f`,`#302008`,`#412700`,`#4e3000`,`#5c3d05`,`#714f1a`,`#8f6424`,`#ffc100`,`#ffdc00`,`#ffc916`,`#ffe7b3`]},yellow:{light:[`#fdfdf9`,`#fefce9`,`#fffab8`,`#fff394`,`#ffe770`,`#f3d768`,`#e4c767`,`#d5ae39`,`#ffea00`,`#ffdc00`,`#a06e00`,`#473b1f`],dark:[`#14110b`,`#1b180f`,`#2c2305`,`#372b00`,`#433500`,`#524202`,`#665417`,`#836a20`,`#ffea00`,`#ffff57`,`#f5e147`,`#f6eeb4`]},lime:{light:[`#fcfdfa`,`#f8faf3`,`#eef6d6`,`#e2f0bd`,`#d3e7a6`,`#c2da91`,`#abc978`,`#8db554`,`#bdee63`,`#b0e64c`,`#5c7c2f`,`#37401c`],dark:[`#11130c`,`#151a10`,`#1f2917`,`#29371d`,`#334423`,`#3d522a`,`#496231`,`#577538`,`#bdee63`,`#d4ff70`,`#bde56b`,`#e3f7ba`]},grass:{light:[`#fbfefb`,`#f5fbf5`,`#e9f7e9`,`#daf0db`,`#c9e9ca`,`#b2deb5`,`#94ce9a`,`#65ba74`,`#46a758`,`#3e9a4f`,`#2a7e3b`,`#203c25`],dark:[`#0e1511`,`#141a15`,`#1b2a1e`,`#1d3a24`,`#25482d`,`#2d5736`,`#366740`,`#3e7949`,`#46a758`,`#53b365`,`#71d083`,`#c2f0c2`]},green:{light:[`#fbfefc`,`#f4fbf6`,`#e6f6eb`,`#d6f1df`,`#c4e8d1`,`#adddc0`,`#8eceaa`,`#5bb88b`,`#30a46c`,`#2b9a66`,`#00824d`,`#193b2d`],dark:[`#0e1512`,`#121b17`,`#132d21`,`#113b29`,`#174933`,`#1f573e`,`#28684a`,`#2f7c57`,`#30a46c`,`#33b074`,`#3dd68c`,`#b1f1cb`]},jade:{light:[`#fbfefd`,`#f4fbf7`,`#e5f7ed`,`#d6f1e3`,`#c3e9d7`,`#acdec9`,`#8bceb6`,`#55ba9f`,`#29a383`,`#26997b`,`#00825c`,`#1d3b31`],dark:[`#0d1512`,`#121c18`,`#0f2e23`,`#0a3b2c`,`#104837`,`#1b5645`,`#246854`,`#2a7e68`,`#29a383`,`#27b08b`,`#1ed8a4`,`#adf0d4`]},mint:{light:[`#f9fefd`,`#f2fbf9`,`#ddf9f2`,`#c8f4e9`,`#b3ecde`,`#9ce0d0`,`#7ecfbd`,`#4cbba5`,`#86ead4`,`#7de1cb`,`#037864`,`#16433c`],dark:[`#0d1515`,`#0f1b1b`,`#092c2b`,`#003a39`,`#004744`,`#0f5650`,`#1e685f`,`#277f70`,`#86ead4`,`#a8f5e5`,`#58d5ba`,`#c4f5e1`]},teal:{light:[`#fafefd`,`#f3fbf9`,`#e0f8f3`,`#ccf3ea`,`#b8ebe0`,`#a1ded2`,`#83cdc1`,`#53b9ab`,`#12a594`,`#0d9b8a`,`#00826d`,`#0d3d38`],dark:[`#0d1514`,`#111c1b`,`#0d2d2a`,`#023b37`,`#084843`,`#145750`,`#1c6961`,`#1f7f74`,`#12a594`,`#0db39e`,`#0ad8b6`,`#adf0dd`]},cyan:{light:[`#fafdfe`,`#f2fafb`,`#def7f9`,`#caf1f6`,`#b5e9f0`,`#9ddee7`,`#7dcedc`,`#3db9ce`,`#01a2c7`,`#0797b9`,`#007da5`,`#0d3c48`],dark:[`#0b1619`,`#101b20`,`#082c36`,`#003848`,`#004558`,`#045468`,`#12677e`,`#11809c`,`#01a2c7`,`#23afd0`,`#4ccce5`,`#b6ecf7`]},sky:{light:[`#f9feff`,`#f1fafd`,`#e1f6fd`,`#d1f0fb`,`#bee7f5`,`#a9daed`,`#8dcae3`,`#60b3d7`,`#7ce2fe`,`#74daf8`,`#00749e`,`#1d3e56`],dark:[`#0d141e`,`#111a27`,`#112840`,`#113655`,`#154467`,`#1b537b`,`#1f6692`,`#197cae`,`#7ce2fe`,`#a8eeff`,`#75c7f0`,`#c2f3ff`]},blue:{light:[`#fdfdfe`,`#f7f9ff`,`#edf2fe`,`#e0e9ff`,`#d2deff`,`#c1d0ff`,`#abbdf9`,`#8da4ef`,`#3e63dd`,`#3358d4`,`#3a5bc7`,`#1f2d5c`],dark:[`#11131f`,`#141726`,`#182449`,`#1d2e61`,`#253974`,`#304384`,`#3a4f97`,`#435db2`,`#3e63dd`,`#5472e4`,`#9db1ff`,`#d6e1ff`]},iris:{light:[`#fdfdff`,`#f8f8ff`,`#f0f1fe`,`#e6e7ff`,`#dadcff`,`#cbcdff`,`#b8b9f8`,`#9b9ef0`,`#5b5bd6`,`#5151cd`,`#5753c6`,`#272962`],dark:[`#13131e`,`#171625`,`#202248`,`#262a65`,`#303374`,`#3d3d82`,`#4a4a95`,`#5a58b1`,`#5b5bd6`,`#6e6ade`,`#b0a9ff`,`#e0dffe`]},violet:{light:[`#fdfcfe`,`#faf8ff`,`#f4f0fe`,`#ebe5ff`,`#e1d9ff`,`#d4cafe`,`#c2b5f5`,`#aa99ec`,`#6e56cf`,`#654dc4`,`#6550b9`,`#2f265f`],dark:[`#14121f`,`#1b1525`,`#291f44`,`#33255b`,`#3c2e69`,`#473876`,`#56468b`,`#6858ad`,`#6e56cf`,`#7d66d9`,`#bba5ff`,`#e2ddfe`]},purple:{light:[`#fefcfe`,`#fbf7fe`,`#f7edfd`,`#f2e2fc`,`#ead5f9`,`#e0c4f4`,`#d1afec`,`#be93e4`,`#8e4ec6`,`#8347b9`,`#8145b5`,`#402060`],dark:[`#18111b`,`#1e1523`,`#2f1c3b`,`#3d224e`,`#48295c`,`#54346b`,`#664282`,`#8357aa`,`#8e4ec6`,`#9a5cd0`,`#d59cff`,`#ecd9fa`]},plum:{light:[`#fefcff`,`#fdf7fd`,`#fbebfb`,`#f7def8`,`#f1d1f3`,`#e9c2ec`,`#deade3`,`#cf91d8`,`#ab4aba`,`#a144af`,`#953ea3`,`#53195d`],dark:[`#181118`,`#201320`,`#351935`,`#451d47`,`#502454`,`#5e3062`,`#734079`,`#92549c`,`#ab4aba`,`#b658c4`,`#e796f3`,`#f4d4f4`]},pink:{light:[`#fffcfe`,`#fef7fb`,`#fee9f6`,`#fbdcef`,`#f6cee7`,`#efbfdd`,`#e7acd1`,`#dd93c2`,`#d6409f`,`#cf3897`,`#c2298a`,`#651249`],dark:[`#191117`,`#21121d`,`#37172f`,`#4b143d`,`#591c47`,`#692955`,`#833869`,`#a84885`,`#d6409f`,`#de51a8`,`#ff80ca`,`#fdd1ea`]},bronze:{light:[`#fdfcfc`,`#fdf7f5`,`#f6edea`,`#efe4df`,`#e7d9d3`,`#dfcdc5`,`#d3bcb3`,`#c2a499`,`#a18072`,`#957468`,`#7d5e54`,`#43302b`],dark:[`#141110`,`#1c1918`,`#262120`,`#302a27`,`#3b3330`,`#493e3a`,`#5a4d47`,`#6f5f57`,`#a18072`,`#ae8d7e`,`#d4b3a5`,`#ede0d9`]},gold:{light:[`#fdfdfc`,`#faf9f2`,`#f2f0e7`,`#eae6dc`,`#e1dccf`,`#d7d0bf`,`#cbc0aa`,`#b9a88d`,`#978365`,`#8c795e`,`#71624b`,`#3b352b`],dark:[`#121211`,`#1b1a17`,`#24231f`,`#2e2b26`,`#38352f`,`#444039`,`#544f46`,`#696256`,`#978365`,`#a39073`,`#cbb99f`,`#e8e2d9`]},brown:{light:[`#fefdfc`,`#fcf9f5`,`#f6eee7`,`#f0e4d9`,`#ebdaca`,`#e4cdb8`,`#dcbc9f`,`#cea37e`,`#ad7f58`,`#a07553`,`#815e46`,`#3e332e`],dark:[`#12110f`,`#1c1816`,`#28211d`,`#322922`,`#3e3128`,`#4d3c2f`,`#614a39`,`#7c5f46`,`#ad7f58`,`#b98c67`,`#dbb594`,`#f2e1ca`]},gray:{light:[`#ffffff`,`#fcfcfc`,`#f9f9f9`,`#f1f1f1`,`#ebebeb`,`#d6d6d6`,`#cccccc`,`#b3b3b3`,`#999999`,`#838383`,`#666666`,`#333333`],dark:[`#171717`,`#1b1b1b`,`#191919`,`#1d1d1d`,`#222222`,`#484848`,`#4c4c4c`,`#666666`,`#818181`,`#7b7b7b`,`#b3b3b3`,`#ebebeb`]},mauve:{light:[`#fdfcfd`,`#faf9fb`,`#f2eff3`,`#eae7ec`,`#e2dfe6`,`#dbd8e0`,`#d0cdd7`,`#bcbac7`,`#8e8c99`,`#83818e`,`#65636d`,`#211f26`],dark:[`#121113`,`#1a191b`,`#232225`,`#2b292d`,`#323035`,`#3c393f`,`#49474e`,`#625f69`,`#6f6d78`,`#7d7a85`,`#b5b2bc`,`#eeeef0`]},olive:{light:[`#fcfdfc`,`#f8faf8`,`#eff1ef`,`#e7e9e7`,`#dfe2df`,`#d7dad7`,`#cccfcc`,`#b9bcb8`,`#898e87`,`#7f837d`,`#60655f`,`#1d211c`],dark:[`#111210`,`#181917`,`#212220`,`#282a27`,`#2f312e`,`#383a37`,`#454943`,`#5c625b`,`#687066`,`#767d74`,`#afb5ad`,`#eceeec`]},sage:{light:[`#fbfdfc`,`#f7f9f8`,`#eef1f0`,`#e6e9e8`,`#dfe2e0`,`#d7dad8`,`#cbcfcd`,`#b8bcbb`,`#868e8b`,`#7c8481`,`#5f6563`,`#1a211e`],dark:[`#101211`,`#171918`,`#202221`,`#272a28`,`#2e3130`,`#373b39`,`#444947`,`#5b625f`,`#63706b`,`#717d79`,`#adb5b2`,`#eceeed`]},sand:{light:[`#fdfdfc`,`#f9f9f8`,`#f1f0ef`,`#e9e9e6`,`#e2e1de`,`#dad9d6`,`#cfcfca`,`#bcbbb5`,`#8d8d86`,`#82827c`,`#63635e`,`#21201c`],dark:[`#111110`,`#191918`,`#222221`,`#2a2a28`,`#31312e`,`#3b3a37`,`#494844`,`#62605a`,`#6f6d66`,`#7d7b74`,`#b5b3ad`,`#eeeeec`]},slate:{light:[`#fcfcfd`,`#f9f9fb`,`#f0f0f3`,`#e7e8ec`,`#e0e1e6`,`#d9d9e0`,`#cdced6`,`#b9bbc6`,`#8b8d98`,`#80838d`,`#60646c`,`#1c2024`],dark:[`#111113`,`#18191b`,`#212225`,`#272a2d`,`#2e3135`,`#363a3f`,`#43484e`,`#5a6169`,`#696e77`,`#777b84`,`#b0b4ba`,`#edeef0`]}},Ph=e=>{let t=0;for(let n=0;n<e.length;n++)t=e.charCodeAt(n)+((t<<5)-t);return Mh[Math.abs(t)%Mh.length]},Fh=e=>typeof e==`string`&&Object.hasOwn(Nh,e),Ih=(e,t=`gray`)=>Fh(e)?e:t;function Lh(e,t){dn();let n={};for(let r of t)n[`--tone-${r}`]=`var(--data-${e}-${r})`;return{style:n,tone:e=>`var(--tone-${e})`}}var Rh=32,zh={xs:{box:12,font:`$1`},sm:{box:14,font:`$1`},md:{box:16,font:`$1`},lg:{box:24,font:`$2`},xl:{box:40,font:`$4`}},Bh={square:`$2xs`,rounded:`$xs`,circle:`$10`},Vh=e=>{let t=[...(e??``).trim()][0];return t?t.toLocaleUpperCase():`-`},Hh=({size:e,shape:t,src:n,name:r,colorSeed:i,icon:o,variant:s=`soft`,ring:c=!1,pulsing:l=!1,onPress:u,alt:d,children:f,style:p,...m})=>{let h=typeof e==`string`&&e in zh?zh[e]:null,g=h?.box??(e!=null&&!h?e:Rh),_=Bh[t??(h?`square`:`circle`)],{style:v,tone:y}=Lh(Ph(i??r??``),[4,5,6,12]),b=f==null&&(n!=null||r!=null||o!=null),x=(r??``).trim(),S=b?(0,H.jsx)(Wh,{bg:o?`transparent`:x?y(s===`outline`?5:4):`$hover`,...s===`outline`&&x&&!o?{borderWidth:1,borderColor:y(6)}:null,rounded:_,children:o?(0,V.isValidElement)(o)&&o.props.size==null?(0,V.cloneElement)(o,{size:g}):o:(0,H.jsx)(a,{fontSize:h?.font??`$2`,lineHeight:g,fontWeight:`500`,color:x?y(12):`$hint`,select:`none`,children:Vh(r)})}):null;return(0,H.jsxs)(To,{"data-slot":`avatar`,...h?{"data-size":e}:null,...u?Pn(u):null,circular:_===`$10`,size:g,...h||t?{rounded:_}:null,shrink:0,overflow:`hidden`,...u?{cursor:`pointer`,hoverStyle:{outlineColor:`$hover`,outlineWidth:4,outlineStyle:`solid`},focusVisibleStyle:at}:null,...l?{"data-motion":`pulse`}:null,style:{...b&&x?v:null,...c?{boxShadow:`0 0 0 1px var(--border), 0 0 0 3px var(--background)`}:null,...p},...m,children:[b&&n?(0,H.jsx)(Uh,{src:n,...d?{alt:d}:null}):null,S,f]})},Uh=e=>(0,H.jsx)(To.Image,{"data-slot":`avatar-image`,width:`100%`,height:`100%`,...e}),Wh=({children:e,...t})=>(0,H.jsx)(To.Fallback,{"data-slot":`avatar-fallback`,bg:`$edge`,items:`center`,justify:`center`,...t,children:typeof e==`string`||typeof e==`number`?(0,H.jsx)(a,{size:`$2`,color:`$quiet`,children:e}):e}),Gh=44,Kh=24,qh=S({variant:`default`}),Jh=M(y,{name:`Badge`,context:qh,display:`inline-flex`,self:`flex-start`,items:`center`,justify:`center`,shrink:0,minH:Kh,px:`$2.5`,py:`$1`,gap:`$1.5`,rounded:`$2`,borderWidth:1,borderColor:`transparent`,overflow:`hidden`,variants:{variant:{default:{bg:`$ink`},secondary:{bg:`$edge`},destructive:{bg:`$red9`},outline:{bg:`$background`,borderColor:`$borderColor`},ghost:{bg:`transparent`,hoverStyle:{bg:`$hover`}},link:{bg:`transparent`},inputAdornment:{bg:`$hover`,px:`$2`},tags:{bg:`$hover`,borderColor:`$borderColor`,rounded:`$3`},muted:{bg:`$hover`},accent:{bg:`var(--primary)`},inherit:{bg:`transparent`}},size:{xs:{minH:14,height:14,px:`$1`,py:0,gap:`$1`,rounded:`$10`},sm:{minH:16,height:16,px:`$2`,py:0,gap:`$1`,rounded:`$10`},md:{minH:18,height:18,px:`$1.5`,py:0,gap:`$0.5`,rounded:`$10`},lg:{}},circle:{true:{px:0,justify:`center`}}},defaultVariants:{variant:`default`}}),Yh={xs:{size:`$1`,lineHeight:14,fontWeight:`600`},sm:{size:`$1`,lineHeight:16,fontWeight:`500`},md:{size:`$1`,lineHeight:18,fontWeight:`500`}},Xh=M(a,{name:`BadgeText`,context:qh,size:`$1`,fontWeight:`600`,variants:{variant:{default:{color:`$sunken`},secondary:{color:`$ink`},destructive:{color:`$white1`},outline:{color:`$ink`},ghost:{color:`$ink`},link:{color:`$ink`,textDecorationLine:`underline`},inputAdornment:{color:`$ink`,fontWeight:`500`},tags:{color:`$quiet`,fontWeight:`400`,textTransform:`capitalize`},muted:{color:`$hint`,fontWeight:`500`},accent:{color:`var(--primary-foreground)`,fontWeight:`500`},inherit:{}}}});function Zh({className:e,variant:t=`default`,size:n,shape:r=`pill`,asChild:i=!1,children:a,...o}){let s=n&&n!==`lg`?n:null,c=s?{xs:14,sm:16,md:18}[s]:Kh,l=t===`inherit`;return(0,H.jsx)(Jh,{"data-slot":`badge`,"data-variant":t,...n?{"data-size":n}:null,variant:t??`default`,...n?{size:n}:null,...r===`circle`?{circle:!0,width:c,minW:c}:null,asChild:i,render:i?void 0:`span`,...dt(c,Gh,`y`),...Ot([yh({variant:t}),e].filter(Boolean).join(` `)),...l?{style:{backgroundColor:`color-mix(in srgb, currentColor 16%, transparent)`}}:null,...o,children:i?a:Vm(a,Xh,{...s?Yh[s]:null,...l?{style:{color:`inherit`,fontWeight:`inherit`,fontVariantNumeric:`tabular-nums`}}:null})})}var Qh=16,$h=()=>{let e=(0,V.useContext)(zo).checked===`indeterminate`?um:Vt;return(0,H.jsx)(e,{size:13,color:`$ink`,strokeWidth:3})},eg={sm:{box:12,edge:1,glyph:14,pad:5},md:{box:18,edge:1.5,glyph:20,pad:6}},tg={solid:`$ink`,outline:`$hint`,soft:`$borderColor`},ng={accent:{fill:`var(--primary)`,glyph:`var(--primary-foreground)`,tint:`$raised`},success:{fill:`$good`,glyph:`$background`,tint:`var(--state-success-bg)`},warning:{fill:`var(--state-warning)`,glyph:`$background`,tint:`var(--state-warning-bg)`}},rg=({look:e})=>{let t=(0,V.useContext)(zo).checked,n=t===!0||t===`indeterminate`,r=t===`indeterminate`?um:Vt,{dim:i,tone:a}=e;return(0,H.jsx)(y,{...B(`checkbox-box`),position:`relative`,width:i.box+2*i.edge,height:i.box+2*i.edge,rounded:e.round?`$10`:`$xs`,borderWidth:i.edge,borderColor:n?a.fill:e.disabled?`$rim`:tg[e.variant],bg:n?a.fill:`transparent`,opacity:e.disabled&&n?.5:1,items:`center`,justify:`center`,pointerEvents:`none`,children:n?(0,H.jsx)(r,{size:i.glyph,color:a.glyph,strokeWidth:2.5}):null})},ig=({variant:e,size:t,shape:n,color:r,hoverable:i,...a})=>{let o=st()===`compact`,s=e??(o||t!==void 0||n!==void 0||r!==void 0||i!==void 0?`solid`:`plain`);if(s!==`plain`){let e=eg[t??`sm`],o=i??!0,c=e.box+2*e.edge,l=o?c+2*e.pad:c,u=a.checked===!0||a.checked===`indeterminate`,d={dim:e,variant:s,tone:ng[r??`accent`],round:n===`round`,hoverable:o,disabled:!!a.disabled};return(0,H.jsx)(Ho,{...B(`checkbox`),"data-variant":s,"data-size":t??`sm`,width:l,height:l,flexShrink:0,padding:0,position:`relative`,items:`center`,justify:`center`,borderWidth:0,rounded:n===`round`?`$10`:o?`$3`:`$xs`,backgroundColor:`transparent`,...o&&!a.disabled?{hoverStyle:{bg:u?d.tone.tint:`$hover`}}:null,activeStyle:{bg:`transparent`},cursor:a.disabled?`not-allowed`:`pointer`,...dt(l),...a,children:(0,H.jsx)(rg,{look:d})})}return(0,H.jsx)(Ho,{...B(`checkbox`),width:Qh,height:Qh,flexShrink:0,padding:0,borderRadius:`$2`,borderWidth:1,borderColor:`$bound`,backgroundColor:`transparent`,activeStyle:{bg:`transparent`},...dt(Qh),...a,children:(0,H.jsx)(Ho.Indicator,{...B(`checkbox-indicator`),alignItems:`center`,justifyContent:`center`,children:(0,H.jsx)($h,{})})})},ag=(e,t,n)=>{let r=t.trim().toLowerCase();if(!r)return 1;let i=(n?.length?`${e} ${n.join(` `)}`:e).toLowerCase();if(i===r)return 1;if(i.startsWith(r))return .9;let a=i.indexOf(r);if(a>-1)return .8-a/(i.length*100);let o=0;for(let e=0;e<i.length&&o<r.length;e++)i[e]===r[o]&&o++;return o===r.length?.4:0},og=(e,t,n,r=!1)=>{if(e<=0)return-1;let i=t+n;return i<0?r?e-1:0:i>=e?r?0:e-1:i},sg=44,cg=e=>typeof e==`string`||typeof e==`number`?String(e):Array.isArray(e)?e.map(cg).filter(Boolean).join(` `):(0,V.isValidElement)(e)?cg(e.props.children):``,lg=(0,V.createContext)(null),ug=(0,V.createContext)(void 0),dg=()=>{let e=(0,V.useContext)(lg);if(!e)throw Error(`Command parts must be rendered inside <Command>`);return e},fg=(0,V.forwardRef)(function({value:e,defaultValue:t,onValueChange:n,filter:r=ag,shouldFilter:i=!0,loop:a=!1,label:o,vimBindings:s=!0,disablePointerSelection:c=!1,children:l,...u},d){let f=(0,V.useRef)(new Map).current,p=(0,V.useRef)([]).current,[m,h]=(0,V.useReducer)(e=>e+1,0),[g,_]=(0,V.useState)(``),[v,y]=(0,V.useState)(t??``),b=e??v,x=(0,V.useCallback)((e,t)=>(f.set(e,t),p.includes(e)||p.push(e),h(),()=>{f.delete(e);let t=p.indexOf(e);t>-1&&p.splice(t,1),h()}),[f,p]),S=(0,V.useMemo)(()=>p.filter(e=>{let t=f.get(e)?.current;return!!t&&(!i||r(t.value,g,t.keywords)>0)}),[m,p,f,i,r,g]),C=(0,V.useMemo)(()=>new Set(S),[S]),w=(0,V.useMemo)(()=>new Set(S.map(e=>f.get(e)?.current.group).filter(Boolean)),[S,f]),T=(0,V.useCallback)(t=>{e===void 0&&y(t),n?.(t)},[e,n]);(0,V.useEffect)(()=>{if(!S.length||b&&S.some(e=>f.get(e)?.current.value===b))return;let e=f.get(S[0])?.current.value;e&&T(e)},[S,b,f,T]);let E=(0,V.useCallback)(e=>{let t=S.filter(e=>!f.get(e)?.current.disabled),n=t.findIndex(e=>f.get(e)?.current.value===b),r=og(t.length,n,e,a),i=r<0?void 0:f.get(t[r])?.current.value;i&&T(i)},[S,f,b,a,T]),D=(0,V.useCallback)(e=>{let t=f.get(e)?.current;t&&!t.disabled&&(T(t.value),t.onSelect?.(t.value))},[f,T]),O=(0,V.useCallback)(e=>{let t=s&&(e.ctrlKey||e.metaKey),n=e.key===`ArrowDown`||t&&(e.key===`n`||e.key===`j`),r=e.key===`ArrowUp`||t&&(e.key===`p`||e.key===`k`);if(n||r)e.preventDefault(),E(n?1:-1);else if(e.key===`Enter`){e.preventDefault();let t=S.find(e=>f.get(e)?.current.value===b);t&&D(t)}},[s,E,S,f,b,D]),k=(0,V.useMemo)(()=>({search:g,setSearch:_,selected:b,select:T,register:x,touch:h,run:D,onKey:O,shows:e=>C.has(e),showsGroup:e=>w.has(e),empty:S.length===0,disablePointerSelection:c}),[g,b,T,x,D,O,C,w,S.length,c]);return(0,H.jsx)(lg.Provider,{value:k,children:(0,H.jsx)(z,{ref:d,"data-slot":`command`,"aria-label":o,width:`100%`,overflow:`hidden`,rounded:`$4`,bg:`$background`,onKeyDown:O,...u,children:l})})}),pg=(0,V.forwardRef)(function({value:e,onValueChange:t,placeholder:n,...r},i){let{search:a,setSearch:o,onKey:s}=dg();return(0,V.useEffect)(()=>{e!==void 0&&e!==a&&o(e)},[e,a,o]),(0,H.jsxs)(y,{"data-slot":`command-input-wrapper`,items:`center`,gap:`$2`,px:`$3`,minH:sg,borderBottomWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(vm,{size:16,opacity:.5}),(0,H.jsx)(ht,{ref:i,"data-slot":`command-input`,unstyled:!0,flex:1,height:sg,borderWidth:0,bg:`transparent`,color:`$color`,placeholder:n,value:e??a,onChangeText:e=>{o(e),t?.(e)},onKeyDown:s,...r})]})}),mg=(0,V.forwardRef)(function(e,t){return(0,H.jsx)(Mt,{ref:t,"data-slot":`command-list`,maxH:300,...e})}),hg=(0,V.forwardRef)(function({children:e,...t},n){let{empty:r}=dg();return r?(0,H.jsx)(z,{ref:n,"data-slot":`command-empty`,py:`$4`,items:`center`,...t,children:typeof e==`string`?(0,H.jsx)(a,{size:`$3`,color:`$quiet`,children:e}):e}):null}),gg=(0,V.forwardRef)(function({value:e,keywords:t,disabled:n,onSelect:r,children:i,...a},o){let s=(0,V.useId)(),{register:c,touch:l,run:u,select:d,selected:f,shows:p,disablePointerSelection:m}=dg(),h=(0,V.useContext)(ug),g=e??cg(i),_=(0,V.useRef)({value:g,keywords:t,disabled:n,group:h,onSelect:r});_.current={value:g,keywords:t,disabled:n,group:h,onSelect:r},(0,V.useEffect)(()=>c(s,_),[s,c]),(0,V.useEffect)(l,[l,g,n,t?.join(`\0`)]);let v=!!g&&f===g;return(0,H.jsx)(ms,{ref:o,"data-slot":`command-item`,"data-selected":v,"data-disabled":!!n,display:p(s)?`flex`:`none`,disabled:n,minH:sg,gap:`$2`,rounded:`$2`,bg:v?`$backgroundFocus`:`transparent`,opacity:n?.5:1,onPress:()=>u(s),onPointerEnter:n||m?void 0:()=>d(g),...a,children:i})}),_g={h:32,px:4,gap:8,icon:16,chevron:14,well:4},vg=(e,t)=>e===`danger`?t?`$bad`:`$red10`:e===`placeholder`?`$hint`:t?`$aside`:`$ink`,yg=e=>e==null||e===!1?null:typeof e==`string`?(0,H.jsx)(_h,{keys:[e]}):Array.isArray(e)?(0,H.jsx)(_h,{keys:e}):e;function bg({label:e,sub:t,contextual:n,contextualPosition:r=`left`,dot:i,icon:a,iconContainer:o=!1,grip:s=`never`,shortcut:c,check:l=!1,submenu:u=!1,tone:d=`default`,quiet:f=!1,hovered:p=!1,subColor:m=`$hint`}){let h=i?(0,H.jsx)(z,{width:8,height:8,rounded:`$10`,bg:i}):a,g=s===`always`||s===`onHover`&&p?(0,H.jsx)(Jp,{size:_g.icon,color:`$hush`}):h&&o?(0,H.jsx)(y,{p:_g.well,rounded:`$xs`,bg:`$hover`,items:`center`,justify:`center`,shrink:0,children:h}):h,_=n!=null&&n!==``?(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,numberOfLines:1,paddingInlineStart:4,shrink:1,children:n}):null;return(0,H.jsxs)(H.Fragment,{children:[s===`never`?g??null:(0,H.jsx)(y,{shrink:0,items:`center`,justify:`center`,minW:_g.icon,children:g}),(0,H.jsxs)(z,{flex:1,minW:0,children:[(0,H.jsxs)(y,{items:`center`,minW:0,children:[typeof e==`string`||typeof e==`number`?(0,H.jsx)(U,{fontSize:`$2`,color:vg(d,f),numberOfLines:1,shrink:1,children:e}):e,r===`left`?_:null]}),t?typeof t==`string`?(0,H.jsx)(U,{fontSize:`$1`,color:m,numberOfLines:1,children:t}):t:null]}),r===`right`?_:null,c==null?null:(0,H.jsx)(y,{shrink:0,children:yg(c)}),l?(0,H.jsx)(Vt,{size:_g.icon,strokeWidth:2}):null,u?(0,H.jsx)(y,{shrink:0,animation:`quick`,rotate:u===`open`?`90deg`:`0deg`,"data-open":u===`open`?``:void 0,children:(0,H.jsx)(rt,{...$m,size:_g.chevron,color:`$hush`})}):null]})}var xg=32,Sg=44,Cg=8,wg=200,Tg=32,Eg=14,Dg=16,Og=4,kg=176,Ag=36,jg=33,Mg=20,Ng={bg:`$panel`,borderColor:`$borderColor`,borderWidth:1,rounded:`$4`,p:Og,minW:wg,overflow:`hidden`,shadowColor:`rgba(0,0,0,0.45)`,shadowRadius:20,shadowOffset:{width:0,height:10}},Pg={items:`center`,gap:Cg,px:Cg,minH:xg,rounded:`$xs`,select:`none`,cursor:`pointer`,...dt(xg,Sg,`y`),hoverStyle:{bg:`$hover`},focusStyle:{bg:`$hover`},pressStyle:{bg:`$raised`}},Fg=({children:e})=>(0,H.jsx)(y,{position:`absolute`,insetInlineStart:Cg,width:Eg,height:Eg,items:`center`,justify:`center`,pointerEvents:`none`,children:(0,H.jsx)(Ic.ItemIndicator,{children:e})}),Ig=V.createContext(null),Lg=V.createContext(null),Rg=V.createContext(null),zg=e=>e===`compact`?8:4;function Bg({offset:e,trigger:t,items:n,minWidth:r=wg,maxHeight:i,defaultPage:a,onOpenChange:o,children:s,...c}){let l=st(),u=e??zg(l),[d,f]=V.useState(u),[p,m]=V.useState(void 0);V.useEffect(()=>f(u),[u]);let[h,g]=V.useState(a?[a]:[]),_=V.useMemo(()=>({page:h[h.length-1]??null,depth:h.length,go:e=>g(t=>[...t,e]),back:()=>g(e=>e.length>1?e.slice(0,-1):e)}),[h]),v=V.useCallback(e=>{e||g(a?[a]:[]),o?.(e)},[a,o]);return(0,H.jsx)(Ig.Provider,{value:f,children:(0,H.jsx)(Lg.Provider,{value:m,children:(0,H.jsx)(Rg.Provider,{value:a?_:null,children:(0,H.jsxs)(Ic,{offset:d,...p?{placement:p}:null,onOpenChange:v,...c,children:[t?(0,H.jsx)(Hg,{asChild:!0,children:t}):null,n?(0,H.jsx)(Kg,{minW:r,maxH:i,children:n.map(Vg)}):null,s]})})})})}var Vg=(e,t)=>e.type===`separator`?(0,H.jsx)(p_,{},e.key??`sep-${t}`):e.type===`label`?(0,H.jsx)(f_,{children:e.label},e.key??`label-${t}`):(0,H.jsx)(Xg,{disabled:e.disabled,variant:e.destructive?`destructive`:`default`,onSelect:e.onSelect,...e.closeOnSelect===!1?{preventCloseOnSelect:!0}:null,children:(0,H.jsx)(bg,{label:e.label,sub:e.description,icon:e.icon?(0,H.jsx)(y,{width:Dg,height:Dg,items:`center`,justify:`center`,shrink:0,children:e.icon}):void 0,shortcut:e.shortcut?(0,H.jsx)(m_,{children:e.shortcut}):void 0,check:!!e.selected,submenu:!!e.hasSubmenu})},e.key),Hg=Ic.Trigger;Ic.Group,Ic.Portal,Ic.Sub,Ic.RadioGroup;var Ug=(e,t)=>{if(!t)return e;let n=e?.split(`-`)[0]??`bottom`;return t===`center`?n:`${n}-${t}`},Wg=e=>[...e.querySelectorAll(`[role="menuitem"], [role="menuitemradio"], [role="menuitemcheckbox"]`)].filter(t=>t.closest(`[data-hanzogui-menu-content]`)===e&&t.getAttribute(`aria-disabled`)!==`true`&&!t.hasAttribute(`data-disabled`)),Gg=e=>e.querySelector(`[data-slot="dropdown-menu-search"] input`),Kg=V.forwardRef(function({sideOffset:e,align:t,children:n,onKeyDown:r,...i},a){let o=dn(),s=st(),c=V.useContext(Rg),l=V.useContext(Ig),u=V.useContext(Lg),d=e??zg(s);V.useEffect(()=>l?.(d),[l,d]),V.useEffect(()=>u?.(Ug(void 0,t)),[u,t]);let f=e=>{if(r?.(e),e.key!==`ArrowUp`)return;let t=e.target?.closest?.(`[data-hanzogui-menu-content]`);if(!t)return;let n=Wg(t),i=Gg(t);i&&n[0]&&n[0]===document.activeElement&&(e.preventDefault(),i.focus())},p=Jg(n);return(0,H.jsx)(Ic.Portal,{children:(0,H.jsx)(_t,{name:o,children:(0,H.jsx)(Lt,{value:s,children:(0,H.jsx)(Rg.Provider,{value:c,children:(0,H.jsx)(Ic.Content,{ref:a,"data-slot":`dropdown-menu-content`,...Ng,...p.framed?{role:`dialog`,"aria-orientation":void 0,"data-framed":``}:null,onKeyDown:f,...i,children:(0,H.jsx)(Yg,{page:c?.page??null,children:p.children})})})})})})}),qg=e=>V.isValidElement(e)&&(e.type===n_||e.type===u_||e.type===d_);function Jg(e){let t=V.Children.toArray(e);if(!t.some(qg))return{framed:!1,children:e};let n=[],r=[],i=()=>{r.length&&(n.push((0,H.jsx)(z,{role:`menu`,"aria-orientation":`vertical`,"data-slot":`dropdown-menu-list`,children:r},`menu-${n.length}`)),r=[])};for(let e of t)qg(e)?(i(),n.push(e)):r.push(e);return i(),{framed:!0,children:n}}function Yg({page:e,children:t}){let n=V.useRef(null),r=V.useRef(!0);return V.useEffect(()=>{if(r.current){r.current=!1;return}let e=n.current?.closest?.(`[data-hanzogui-menu-content]`);if(!e)return;let t=requestAnimationFrame(()=>(Gg(e)??Wg(e)[0])?.focus());return()=>cancelAnimationFrame(t)},[e]),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{ref:n,hidden:!0,"data-slot":`dropdown-menu-anchor`}),t]})}var Xg=V.forwardRef(function({inset:e,variant:t=`default`,disabled:n,page:r,actions:i,actionsVisibility:a=`hover`,onSelect:o,children:s,...c},l){let u=V.useContext(Rg),[d,f]=V.useState(!1),p=r!==void 0&&u!==null,m=(0,H.jsx)(Ic.Item,{ref:l,"data-slot":`dropdown-menu-item`,"data-inset":e,"data-variant":t,disabled:n,...Pg,paddingInlineStart:e?Tg:Cg,theme:t===`destructive`?`red`:void 0,opacity:n?.5:1,cursor:n?`default`:`pointer`,...i?{flex:1,onFocus:()=>f(!0),onBlur:()=>f(!1)}:null,onSelect:e=>{r!==void 0&&u&&(e.preventDefault?.(),u.go(r)),o?.(e)},...c,children:p?(0,H.jsxs)(H.Fragment,{children:[Vm(s,U,{fontSize:`$2`}),(0,H.jsx)(rt,{...$m,size:14,marginInlineStart:`auto`,color:`$hush`})]}):Vm(s,U,{fontSize:`$2`})});return i?(0,H.jsxs)(y,{"data-slot":`dropdown-menu-item-row`,items:`center`,gap:Cg,onHoverIn:()=>f(!0),onHoverOut:()=>f(!1),children:[m,(0,H.jsx)(y,{"data-slot":`dropdown-menu-item-actions`,role:`group`,shrink:0,items:`center`,gap:2,opacity:a===`always`||d?1:0,$touchable:{opacity:1},animation:`75ms`,children:V.Children.map(i,e=>V.isValidElement(e)&&e.props.role==null?V.cloneElement(e,{role:`menuitem`}):e)})]}):m}),Zg=V.forwardRef(function({children:e,checked:t,...n},r){return(0,H.jsxs)(Ic.CheckboxItem,{ref:r,"data-slot":`dropdown-menu-checkbox-item`,checked:t,...Pg,paddingInlineStart:Tg,...n,children:[(0,H.jsx)(Fg,{children:(0,H.jsx)(Vt,{size:Dg})}),e]})}),Qg=V.createContext(null),$g=e=>e==null?[]:Array.isArray(e)?e:[e];function e_({value:e,defaultValue:t=null,onValueChange:n,multiple:r=!1,closeOnSelect:i,children:a}){let[o,s]=V.useState(()=>$g(t)),c=e===void 0?o:$g(e),l=t=>{e===void 0&&s(t),n?.(r?t:t[0]??null)},u={multiple:r,closeOnSelect:i??!r,has:e=>c.includes(e),toggle:e=>l(r?c.includes(e)?c.filter(t=>t!==e):[...c,e]:[e])};return(0,H.jsx)(Qg.Provider,{value:u,children:r?(0,H.jsx)(Ic.Group,{"data-slot":`dropdown-menu-selection-group`,children:a}):(0,H.jsx)(Ic.RadioGroup,{"data-slot":`dropdown-menu-selection-group`,value:c[0]??``,onValueChange:e=>l(e?[e]:[]),children:a})})}var ree=({on:e})=>(0,H.jsx)(y,{width:Eg,height:Eg,shrink:0,rounded:`$xs`,borderWidth:1,borderColor:e?`var(--primary)`:`$bound`,bg:e?`var(--primary)`:`transparent`,items:`center`,justify:`center`,children:e?(0,H.jsx)(Vt,{size:12,strokeWidth:3,color:`var(--primary-foreground)`}):null}),t_=V.forwardRef(function({value:e,indicator:t,closeOnSelect:n,onSelect:r,children:i,disabled:a,...o},s){let c=V.useContext(Qg),l=c?.multiple??!1,u=c?.has(e)??!1,d=t??(l?`checkbox`:`check`),f=n??c?.closeOnSelect??!l,p=(0,H.jsxs)(H.Fragment,{children:[d===`checkbox`?(0,H.jsx)(ree,{on:u}):null,typeof i==`string`?(0,H.jsx)(U,{fontSize:`$2`,color:`$aside`,numberOfLines:1,flex:1,minW:0,children:i}):i,d===`check`&&u?(0,H.jsx)(Vt,{size:Dg,strokeWidth:2,marginInlineStart:`auto`}):null]}),m={ref:s,"data-slot":`dropdown-menu-option-item`,"data-indicator":d,disabled:a,...Pg,...d===`none`&&u?{bg:`$hover`}:null,opacity:a?.5:1,preventCloseOnSelect:!f,onSelect:r,...o};return l?(0,H.jsx)(Ic.CheckboxItem,{...m,checked:u,onCheckedChange:()=>c?.toggle(e),children:p}):(0,H.jsx)(Ic.RadioItem,{...m,value:e,children:p})});function n_({value:e,defaultValue:t,onValueChange:n,placeholder:r,autoFocus:i=!0,"aria-label":a}){let{t:o}=R(),s=r??o(`Search`),c=V.useRef(null);V.useEffect(()=>{if(!i)return;let e=requestAnimationFrame(()=>{let e=setTimeout(()=>c.current?.focus(),0);t=()=>clearTimeout(e)}),t=()=>{};return()=>{cancelAnimationFrame(e),t()}},[i]);let l=e=>{if(e.key===`Escape`||e.key===`Tab`)return;let t=e.currentTarget.closest(`[data-hanzogui-menu-content]`);if(e.key===`ArrowDown`){e.preventDefault(),e.stopPropagation(),t&&Wg(t)[0]?.focus();return}if(e.key===`Enter`){if(e.stopPropagation(),e.nativeEvent.isComposing)return;e.preventDefault(),t&&Wg(t)[0]?.click();return}e.stopPropagation()};return(0,H.jsx)(y,{"data-slot":`dropdown-menu-search`,minH:Ag,items:`center`,px:Cg,mx:-4,mt:-4,mb:Og,borderBottomWidth:1,borderColor:`$borderColor`,children:(0,H.jsx)(ht,{ref:c,unstyled:!0,flex:1,minW:0,height:20,p:0,borderWidth:0,bg:`transparent`,color:`$ink`,placeholderTextColor:`$placeholderColor`,fontSize:`$1`,"aria-label":a??s,placeholder:s,...e===void 0?{defaultValue:t}:{value:e},onChangeText:e=>n?.(e),onKeyDown:l,style:{outlineStyle:`none`}})})}function r_({label:e,scrollable:t=!1,children:n,...r}){return(0,H.jsxs)(Ic.Group,{"data-slot":`dropdown-menu-section`,...typeof e==`string`?{"aria-label":e}:null,children:[e?(0,H.jsx)(f_,{variant:`band`,children:e}):null,(0,H.jsx)(z,{gap:2,...t?{maxH:kg,style:{overflowY:`auto`,overscrollBehavior:`contain`}}:null,...r,children:n})]})}function i_({id:e,children:t}){let n=V.useContext(Rg);return!n||n.page!==e?null:(0,H.jsx)(z,{"data-slot":`dropdown-menu-page`,"data-page":e,children:t})}var a_={minH:jg,items:`center`,gap:Cg,px:Cg,mx:-4,mt:-4,mb:Og,borderBottomWidth:1,borderColor:`$borderColor`};function o_({children:e,...t}){return(0,H.jsx)(y,{"data-slot":`dropdown-menu-header`,...a_,...t,children:e})}function s_({children:e,...t}){return(0,H.jsx)(U,{"data-slot":`dropdown-menu-title`,fontSize:`$2`,fontWeight:`500`,color:`$ink`,numberOfLines:1,flex:1,...t,children:e})}var c_=V.forwardRef(function({children:e,onSelect:t,...n},r){let i=V.useContext(Rg);return(0,H.jsxs)(Ic.Item,{ref:r,"data-slot":`dropdown-menu-back`,...a_,rounded:0,cursor:`pointer`,hoverStyle:{bg:`$hover`},focusStyle:{bg:`$hover`},preventCloseOnSelect:!0,onSelect:e=>{i?.back(),t?.(e)},...n,children:[(0,H.jsx)(Tp,{...$m,size:Dg,color:`$aside`}),typeof e==`string`?(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,color:`$ink`,numberOfLines:1,flex:1,children:e}):e]})});function l_({slot:e,children:t}){return(0,H.jsx)(y,{"data-slot":e,role:`status`,"aria-live":`polite`,items:`center`,gap:Cg,p:Cg,children:t})}function u_({children:e}){let{t}=R();return(0,H.jsx)(l_,{slot:`dropdown-menu-empty`,children:(0,H.jsx)(U,{fontSize:`$1`,color:`$aside`,children:e??t(`No results`)})})}function d_({children:e}){let{t}=R();return(0,H.jsxs)(l_,{slot:`dropdown-menu-loading`,children:[(0,H.jsx)(y,{"aria-hidden":!0,children:(0,H.jsx)(op,{size:`small`,maxW:14,maxH:14})}),(0,H.jsx)(U,{fontSize:`$1`,color:`$quiet`,children:e??t(`Loading`)})]})}var f_=V.forwardRef(function({inset:e,variant:t=`default`,...n},r){return t===`band`?(0,H.jsx)(Ic.Label,{ref:r,"data-slot":`dropdown-menu-label`,"data-variant":`band`,height:Mg,lineHeight:Mg,mx:-4,px:Cg,py:0,bg:`$hover`,fontSize:`$1`,fontWeight:`400`,color:`$hint`,select:`none`,...n}):(0,H.jsx)(Ic.Label,{ref:r,"data-slot":`dropdown-menu-label`,"data-inset":e,px:Cg,py:4,paddingInlineStart:e?Tg:Cg,fontSize:`$2`,fontWeight:`500`,color:`$ink`,select:`none`,...n})}),p_=V.forwardRef(function(e,t){return(0,H.jsx)(Ic.Separator,{ref:t,"data-slot":`dropdown-menu-separator`,height:1,bg:`$borderColor`,mx:-4,my:Og,...e})});function m_(e){return(0,H.jsx)(U,{"data-slot":`dropdown-menu-shortcut`,marginInlineStart:`auto`,fontSize:`$1`,letterSpacing:1,color:`$quiet`,...e,children:th(e.children)})}var h_=(e=2)=>({className:`glass elevation-${e}`,backgroundColor:`$background`,borderColor:`$borderColor`});({...B(`rows`)});var g_=(e,t)=>{let[n,r]=e.split(`-`),i=t??r;return!i||i===`center`?n:`${n}-${i}`},__=e=>e?{secureTextEntry:!0,type:`password`}:{secureTextEntry:!1,type:`text`},v_={default:{h:36,gutter:12,riser:7,font:`$3`},lg:{h:46,gutter:14,riser:12,font:`$3`},sm:{h:32,gutter:8,riser:7,font:`$2`},xs:{h:24,gutter:8,riser:3,font:`$2`}},y_={bg:`$raised`},b_={px:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,bg:`transparent`},x_=(0,V.createContext)({}),S_=()=>(0,V.useContext)(x_),C_=(e,t)=>e==null?!!t.invalid:e!==!1&&e!==`false`;M(z,{name:`FieldGroup`,width:`100%`,gap:`$7`}),M(y,{name:`Field`,context:S({orientation:`vertical`}),width:`100%`,gap:`$3`,variants:{orientation:{vertical:{flexDirection:`column`},horizontal:{flexDirection:`row`,items:`center`},responsive:{flexDirection:`column`,$md:{flexDirection:`row`,items:`center`}}},invalid:{true:{color:`$red9`}}},defaultVariants:{orientation:`vertical`}}),M(z,{name:`FieldContent`,flex:1,gap:`$1.5`});var w_=(0,V.createContext)(null),T_=`color-mix(in srgb, var(--foreground) 32%, transparent)`,E_=(e,t)=>t?.4:e?.9:.6;function D_({start:e,end:t,size:n,fill:r=!1,children:i,...a}){let o=st(),s=lt(n,o),c=v_[s],[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)({invalid:!1,disabled:!1}),p=(0,V.useCallback)(e=>f(t=>t.invalid===e.invalid&&t.disabled===e.disabled?t:e),[]),m=(0,V.useMemo)(()=>({size:s,focus:u,report:p}),[s,p]),h=d.invalid?l?`$red8`:`$red7`:l?T_:`$borderColor`;return(0,H.jsx)(w_.Provider,{value:m,children:(0,H.jsxs)(y,{...B(`input-group`),"data-focused":l?``:void 0,"data-invalid":d.invalid?``:void 0,"data-disabled":d.disabled?``:void 0,componentName:`Input`,...b_,...o===`compact`?{bg:`$panel`}:null,...r?y_:null,borderColor:h,hoverStyle:d.disabled||l?void 0:{borderColor:`$borderColorHover`},items:`center`,gap:`$1`,height:c.h,width:`100%`,minW:0,px:c.gutter,cursor:d.disabled?`not-allowed`:void 0,...a,children:[e?(0,H.jsx)(y,{...B(`input-group-start`),shrink:0,items:`center`,opacity:E_(l,d.disabled),children:e}):null,i,t?(0,H.jsx)(y,{...B(`input-group-end`),shrink:0,items:`center`,gap:`$1`,opacity:E_(l,d.disabled),children:t}):null]})})}var O_=24,k_=44,A_=(e,t)=>({position:`absolute`,[e===`start`?`insetInlineStart`:`insetInlineEnd`]:t,t:0,b:0,items:`center`,justify:`center`}),j_=(0,V.forwardRef)(function({startAdornment:e,endAdornment:t,reveal:n=!0,type:r,secureTextEntry:i,size:a,fill:o=!1,...s},c){let{t:l}=R(),[u,d]=(0,V.useState)(!1),f=st(),p=(0,V.useContext)(w_),m=r===`password`||i===!0,h=r===`email`||r===`url`,g=m&&n,_=v_[p?.size??lt(a,f)],v=_.gutter+O_,b=S_(),x=C_(s[`aria-invalid`],b),S=!!s.disabled,C=p?.report;if((0,V.useEffect)(()=>C?.({invalid:x,disabled:S}),[C,x,S]),p){let{onFocus:e,onBlur:t}=s;return(0,H.jsx)(ht,{ref:c,...B(`input`),...m?__(!u):{type:r,secureTextEntry:i},flex:1,minW:0,height:_.h-2,px:0,borderWidth:0,rounded:0,bg:`transparent`,color:`$ink`,placeholderTextColor:`$placeholderColor`,fontSize:_.font,...x?{"aria-invalid":!0}:null,...s,style:{...s.style??null,outlineStyle:`none`},onFocus:t=>{p.focus(!0),e?.(t)},onBlur:e=>{p.focus(!1),t?.(e)}})}let w=(0,H.jsx)(ht,{ref:c,...B(`input`),...m?__(!u):{type:r,secureTextEntry:i},...b_,...f===`compact`?{bg:`$panel`}:null,...o?y_:null,...x?{borderColor:`$red7`,focusStyle:{borderColor:`$red8`}}:null,height:_.h,...`height`in s?null:{$touchable:{height:Math.max(_.h,k_)}},width:`100%`,minW:0,color:`$ink`,placeholderTextColor:`$placeholderColor`,fontSize:_.font,...x?{"aria-invalid":!0}:null,paddingInlineStart:e?v:_.gutter,paddingInlineEnd:t||g?v:_.gutter,...s});return!e&&!t&&!g?w:(0,H.jsxs)(y,{position:`relative`,width:`100%`,items:`center`,...h?eh:null,children:[e?(0,H.jsx)(y,{...A_(`start`,_.gutter),pointerEvents:`none`,opacity:.6,children:e}):null,w,g?(0,H.jsx)(y,{...dt(20),...A_(`end`,_.gutter),cursor:`pointer`,onPress:()=>d(e=>!e),"aria-label":l(u?`Hide password`:`Show password`),children:u?(0,H.jsx)(Vp,{size:16}):(0,H.jsx)(Hp,{size:16})}):t?(0,H.jsx)(y,{...A_(`end`,_.gutter),opacity:.6,children:t}):null]})}),M_=4,N_=`bottom`,P_=(0,V.createContext)(null),F_=(0,V.createContext)(!1);function I_({offset:e,placement:t,...n}){let r=st();e??=r===`compact`?8:M_;let[i,a]=(0,V.useState)({}),o=(0,V.useCallback)(e=>a(t=>({...t,...e})),[]);return(0,H.jsx)(P_.Provider,{value:o,children:(0,H.jsx)(pt,{offset:i.offset??e,placement:g_(t??N_,i.align),...n})})}var L_=pt.Trigger;pt.Anchor,pt.Close;var R_=({sideOffset:e,align:t,solid:n,size:r,arrow:i=!1,children:a,...o})=>{let s=dn(),c=st(),l=(0,V.useContext)(P_),u=(0,V.useContext)(F_),d=n??u,f=(r??(c===`compact`?`sm`:`default`))===`sm`,p=e??(c===`compact`?8:M_);(0,V.useEffect)(()=>l?.({offset:p,align:t}),[l,p,t]);let m=d?`var(--popover)`:`$panel`;return(0,H.jsx)(F_.Provider,{value:d,children:(0,H.jsx)(_t,{name:s,children:(0,H.jsx)(Lt,{value:c,children:(0,H.jsxs)(pt.Content,{...B(`popover-content`),...d?{"data-material":`solid`}:null,...f?{"data-size":`sm`}:null,bg:m,borderWidth:1,borderColor:`$borderColor`,rounded:`$4`,...f?{p:`$2`,gap:`$1`,maxW:`var(--hanzogui-popper-available-width, 100vw)`}:{p:`$4`,width:288},...o,children:[i?(0,H.jsx)(pt.Arrow,{...B(`popover-arrow`),size:8.5,bg:m,borderWidth:1,borderColor:`$borderColor`}):null,a]})})})})},z_=10,B_=44,V_={offset:0,viewport:0,content:0},H_=(0,V.createContext)(null),U_=(e,t)=>e<0?0:e>t?t:e,W_=(0,V.forwardRef)(function({orientation:e=`vertical`,...t},n){let r=(0,V.useContext)(H_),[i,a]=(0,V.useState)(0),o=(0,V.useRef)(null);if(!r||r.axis!==e)return null;let s=e===`vertical`,{content:c,viewport:l,offset:u}=r.track,d=c-l,f=d>1,p=r.type===`always`?!0:f?r.type===`auto`||r.active:!1,m=Math.max(B_,l/Math.max(c,1)*i),h=Math.max(i-m,0),g=f?h*U_(u/d,1):0,_=Et({begin:e=>{o.current=At(e,!s)},move:e=>{let t=o.current;if(t===null||h===0)return;let n=At(e,!s);o.current=n,r.scrollBy((n-t)*d/h)},end:()=>{o.current=null}});return(0,H.jsx)(y,{ref:n,...B(`scroll-area-scrollbar`),position:`absolute`,...s?{t:0,b:0,...r.dir===`rtl`?{l:0}:r.dir===`ltr`?{r:0}:{insetInlineEnd:0},width:z_,flexDirection:`column`}:{l:0,r:0,b:0,height:z_,flexDirection:`row`},p:1,opacity:+!!p,pointerEvents:p?`auto`:`none`,onLayout:e=>a(s?e.nativeEvent.layout.height:e.nativeEvent.layout.width),...t,children:(0,H.jsx)(z,{...B(`scroll-area-thumb`),bg:`$borderColor`,rounded:z_,...dt(z_,B_,s?`x`:`y`),...s?{width:`100%`,height:m,y:g}:{height:`100%`,width:m,x:g},..._})})}),G_=(0,V.forwardRef)(function({type:e=`hover`,scrollHideDelay:t=600,dir:n,horizontal:r=!1,children:i,...a},o){let s=(0,V.useRef)(null),c=(0,V.useRef)(V_),[l,u]=(0,V.useState)(V_),[d,f]=(0,V.useState)(!1),p=(0,V.useRef)(null),m=r?`horizontal`:`vertical`,h=(0,V.useCallback)(e=>{let t={...c.current,...e};c.current=t,u(t)},[]),g=()=>{p.current&&clearTimeout(p.current),p.current=null},_=()=>{g(),f(!0)},v=(0,V.useCallback)(()=>{f(!0),g(),p.current=setTimeout(()=>f(!1),t)},[t]);(0,V.useEffect)(()=>g,[]);let y=(0,V.useCallback)(e=>{let t=c.current,n=U_(t.offset+e,Math.max(t.content-t.viewport,0));h({offset:n}),s.current?.scrollTo(r?{x:n,y:0,animated:!1}:{x:0,y:n,animated:!1})},[r,h]);return(0,H.jsxs)(z,{ref:o,...B(`scroll-area`),position:`relative`,overflow:`hidden`,onMouseEnter:e===`hover`?_:void 0,onMouseLeave:e===`hover`?v:void 0,...a,children:[(0,H.jsx)(Mt,{ref:s,...B(`scroll-area-viewport`),flex:1,width:`100%`,height:`100%`,horizontal:r,showsVerticalScrollIndicator:!1,showsHorizontalScrollIndicator:!1,scrollEventThrottle:16,onLayout:e=>h({viewport:r?e.nativeEvent.layout.width:e.nativeEvent.layout.height}),onContentSizeChange:(e,t)=>h({content:r?e:t}),onScroll:e=>{let{contentOffset:t}=e.nativeEvent;h({offset:r?t.x:t.y}),v()},children:Vm(i)}),(0,H.jsx)(H_.Provider,{value:{axis:m,track:l,type:e,active:d,dir:n,scrollBy:y},children:(0,H.jsx)(W_,{orientation:m})})]})}),K_=32,q_=(0,V.createContext)(!1),J_=Object.assign(({disabled:e=!1,...t})=>(0,H.jsx)(q_.Provider,{value:e,children:(0,H.jsx)(jl,{...t})}),jl);jl.Group;var Y_=(0,V.createContext)(`$3`),X_=({children:e,disabled:t,size:n,...r})=>{let i=(0,V.useContext)(q_),a=st(),o=v_[lt(n,a)],s=C_(r[`aria-invalid`],S_());return(0,H.jsxs)(jl.Trigger,{...B(`select-trigger`),unstyled:!0,disabled:t??i,...b_,...a===`compact`?{bg:`$panel`}:null,...s?{borderColor:`$red7`,"aria-invalid":!0}:null,px:o.gutter,items:`center`,justify:`space-between`,gap:`$2`,height:`auto`,minHeight:o.h,py:0,cursor:`pointer`,...dt(o.h,44,`y`),...r,children:[(0,H.jsx)(Y_.Provider,{value:o.font,children:Vm(e,void 0,{size:o.font})}),(0,H.jsx)(jl.Icon,{children:(0,H.jsx)(wp,{size:16,opacity:.5})})]})},Z_=({children:e,value:t,...n})=>{let r=st()===`compact`;return(0,H.jsxs)(jl.Item,{value:t,...B(`select-item`),unstyled:!0,index:n.index??0,items:`center`,justify:`flex-start`,gap:`$2`,minH:K_,paddingInlineStart:r?`$1`:`$2`,paddingInlineEnd:`$7`,rounded:`$xs`,cursor:`pointer`,...dt(K_,44,`y`),hoverStyle:{bg:r?`$hover`:`$raised`},focusStyle:{bg:r?`$hover`:`$raised`},...n,children:[(0,H.jsx)(jl.ItemText,{...r?{fontSize:`$2`,color:`$aside`}:null,children:e}),(0,H.jsx)(y,{position:`absolute`,insetInlineEnd:`$2`,items:`center`,justify:`center`,pointerEvents:`none`,children:(0,H.jsx)(jl.ItemIndicator,{children:(0,H.jsx)(Vt,{size:16,strokeWidth:2})})})]})},Q_=(e,t)=>V.Children.map(e,e=>{if(!(0,V.isValidElement)(e))return e;if(e.type===Z_)return(0,V.cloneElement)(e,{index:t()});let n=e.props.children;return n===void 0?e:(0,V.cloneElement)(e,void 0,Q_(n,t))}),$_=e=>(0,H.jsx)(jl.ScrollUpButton,{...B(`select-scroll-up-button`),items:`center`,justify:`center`,py:`$1`,...e,children:(0,H.jsx)(Ep,{size:16})}),ev=e=>(0,H.jsx)(jl.ScrollDownButton,{...B(`select-scroll-down-button`),items:`center`,justify:`center`,py:`$1`,...e,children:(0,H.jsx)(wp,{size:16})}),tv=({children:e,...t})=>{let n=0,r=st();return(0,H.jsx)(jl.Content,{...B(`select-content`),...t,children:(0,H.jsxs)(Lt,{value:r,children:[(0,H.jsx)($_,{}),(0,H.jsx)(jl.Viewport,{minW:128,p:`$1`,bg:`$panel`,borderWidth:1,borderColor:`$borderColor`,rounded:`$3`,children:Q_(e,()=>n++)}),(0,H.jsx)(ev,{})]})})},nv=({children:e,...t})=>(0,H.jsx)(z,{...B(`screen`),flex:1,flexBasis:`auto`,minH:0,width:`100%`,overflow:`hidden`,...t,children:e}),rv=({size:e=16,color:t=`currentColor`,variant:n=`arc`,...r})=>n===`dot`?(0,H.jsx)(y,{...B(`spinner`),"data-variant":`dot`,"aria-hidden":!0,width:24,height:12,shrink:0,rounded:`$10`,borderWidth:1,borderColor:t,overflow:`hidden`,items:`center`,justify:`center`,...r,children:(0,H.jsx)(w,{"data-motion":`hop`,width:8,height:8,rounded:`$10`,bg:t})}):(0,H.jsx)(op,{...B(`spinner`),"aria-hidden":!0,size:e,color:t,...r}),iv={default:{w:36,h:20,thumb:16,edge:1},md:{w:32,h:20,thumb:16,edge:0},sm:{w:24,h:16,thumb:12,edge:0}},av=({disabled:e,size:t,...n})=>{let r=st()===`compact`,i=iv[t??(r?`md`:`default`)];return(0,H.jsx)(Wl,{...B(`switch`),"data-size":t??(r?`md`:`default`),width:i.w,height:i.h,minHeight:i.h,padding:2,flexShrink:0,backgroundColor:`$color3`,borderWidth:i.edge,borderColor:`$borderColor`,activeStyle:{backgroundColor:`$color12`,borderColor:`$color12`},disabled:e,opacity:e?.5:1,cursor:e?`not-allowed`:`pointer`,...dt(i.h,44,`y`),...n,children:(0,H.jsx)(Wl.Thumb,{...B(`switch-thumb`),width:i.thumb,height:i.thumb,backgroundColor:`$color3`,activeStyle:{bg:`$color12`}})})},ov=36,sv=40,cv=(0,V.createContext)({variant:`default`,value:void 0,vertical:!1}),lv=({variant:e=`default`,value:t,defaultValue:n,onValueChange:r,orientation:i,...a})=>{let[o,s]=(0,V.useState)(n),c=t??o;return(0,H.jsx)(cv.Provider,{value:{variant:e,value:c,vertical:i===`vertical`},children:(0,H.jsx)($l,{...B(`tabs`),flexDirection:i===`vertical`?`row`:`column`,gap:`$2`,...t===void 0?{defaultValue:n}:{value:t},onValueChange:e=>{s(e),r?.(e)},...i?{orientation:i}:null,...e===`line`?{"data-variant":`line`}:null,...a})})},uv=e=>{let{variant:t,vertical:n}=(0,V.useContext)(cv);return t===`line`?(0,H.jsx)($l.List,{...B(`tabs-list`),...n?{flexDirection:`column`,borderInlineEndWidth:1,items:`stretch`}:{flexDirection:`row`,borderBottomWidth:1,items:`flex-end`},borderColor:`$borderColor`,bg:`transparent`,gap:`$1`,p:0,rounded:0,justify:`flex-start`,...e}):(0,H.jsx)($l.List,{...B(`tabs-list`),items:`center`,justify:`center`,self:`flex-start`,height:ov,p:3,gap:2,bg:`$hover`,rounded:`$4`,...e})},dv=({children:e,startIcon:t,endIcon:n,badge:r,size:i=`md`,highlighted:a=!1,disabled:o,value:s,...c})=>{let{value:l,vertical:u}=(0,V.useContext)(cv),[d,f]=(0,V.useState)(!1),p=l===s,m=o?`$hush`:p?`$ink`:`$aside`;return(0,H.jsxs)($l.Tab,{...B(`tabs-trigger`),"data-variant":`line`,...p?{"data-chosen":``}:null,unstyled:!0,value:s,disabled:o,position:`relative`,items:`center`,justify:`center`,minH:sv,p:0,bg:`transparent`,borderWidth:0,cursor:o?`default`:`pointer`,...dt(sv,44,`y`),onHoverIn:()=>f(!0),onHoverOut:()=>f(!1),...c,children:[(0,H.jsxs)(y,{...B(`tabs-trigger-box`),items:`center`,gap:`$1`,px:`$2`,py:i===`sm`?`$1`:`$2`,rounded:a?`$xs`:`$3`,bg:d&&!o?`$hover`:`transparent`,...a?{outlineWidth:1,outlineStyle:`solid`,outlineColor:`var(--primary)`,outlineOffset:-1}:null,children:[t,Vm(e,void 0,{size:`$2`,fontWeight:`500`,color:m,numberOfLines:1}),r,n]}),p?(0,H.jsx)(z,{...B(`tabs-indicator`),position:`absolute`,bg:`$ink`,...u?{insetInlineEnd:-1,t:0,b:0,width:1}:{b:-1,l:0,r:0,height:1}}):null]})},fv=e=>{let{variant:t}=(0,V.useContext)(cv);if(t===`line`)return(0,H.jsx)(dv,{...e});let{children:n,startIcon:r,endIcon:i,badge:a,size:o,highlighted:s,...c}=e;return(0,H.jsxs)($l.Tab,{...B(`tabs-trigger`),unstyled:!0,items:`center`,justify:`center`,height:`100%`,px:`$3`,gap:`$1.5`,rounded:`$3`,cursor:`pointer`,...dt(ov,44,`y`),hoverStyle:{bg:`$edge`},focusStyle:{bg:`$edge`},activeStyle:{bg:`$background`,shadowColor:`$shadowColor`,shadowOpacity:.12,shadowRadius:3,shadowOffset:{width:0,height:1}},...c,children:[r,Vm(n,void 0,{size:`$2`,fontWeight:`500`}),a,i]})},pv=({children:e,...t})=>(0,H.jsx)($l.Content,{...B(`tabs-content`),flexGrow:1,...t,children:Vm(e)}),mv=3,hv={default:20,lg:20,sm:16,xs:16},gv=e=>typeof e==`string`?e.split(`
|
|
22
|
+
`).length:0,_v=V.forwardRef(function({rows:e,value:t,defaultValue:n,style:r,size:i,fill:a=!1,maxRows:o,...s},c){let l=st(),u=S_(),d=lt(i,l),f=v_[d],p=hv[d],m=d===`sm`||d===`xs`,[h,g]=V.useState(()=>gv(n)),_=t===void 0,v=C_(s[`aria-invalid`],u),y=V.useRef(null),[b,x]=V.useState(void 0),[S,C]=V.useState(!1),w=V.useCallback(e=>{y.current=e,typeof c==`function`?c(e):c&&(c.current=e)},[c]),T=_?h:t;return V.useLayoutEffect(()=>{let e=y.current;if(!e||typeof e.scrollHeight!=`number`)return;let t=e.style.height;e.style.height=`auto`;let n=e.scrollHeight;e.style.height=t,e.offsetHeight;let r=parseFloat(getComputedStyle(e).maxHeight);C(Number.isFinite(r)&&n>r),x(e=>e===n?e:n)},[T]),(0,H.jsx)(ap,{ref:w,...B(`textarea`),rows:Math.max(e??mv,_?h:gv(t)),value:t,defaultValue:n,onChangeText:_?e=>g(gv(e)):void 0,...b_,...l===`compact`?{bg:`$panel`}:null,...a?y_:null,width:`100%`,minH:m?mv*p+2*f.riser+2:64,...o?{maxH:o*p+2*f.riser+2}:null,px:f.gutter,pt:f.riser,pb:f.riser,borderColor:v?`$red7`:`$borderColor`,...v?{focusStyle:{borderColor:`$red8`}}:null,color:`$ink`,placeholderTextColor:`$placeholderColor`,fontSize:f.font,...m?{lineHeight:p}:null,opacity:s.disabled?.5:1,...v?{"aria-invalid":!0}:null,...S?{"data-capped":``}:null,...s,style:{...r,...b?{height:b}:null}})}),vv=1,yv=class{constructor(){this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set,this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);t>-1&&this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{let{title:t,...n}=e,r=typeof e?.id==`number`||typeof e?.id==`string`&&e.id.length>0?e.id:vv++,i=this.toasts.find(e=>e.id===r),a=e.dismissible??!0;return this.dismissedToasts.has(r)&&this.dismissedToasts.delete(r),i?this.toasts=this.toasts.map(n=>n.id===r?(this.publish({...n,...e,id:r,title:t,dismissible:a}),{...n,...e,id:r,title:t,dismissible:a}):n):this.addToast({title:t,...n,dismissible:a,id:r}),r},this.dismiss=e=>(e===void 0?this.toasts.forEach(e=>{this.subscribers.forEach(t=>t({id:e.id,dismiss:!0}))}):(this.dismissedToasts.add(e),requestAnimationFrame(()=>{this.subscribers.forEach(t=>t({id:e,dismiss:!0}))})),e),this.message=(e,t)=>this.create({...t,title:e,type:`default`}),this.success=(e,t)=>this.create({...t,title:e,type:`success`}),this.error=(e,t)=>this.create({...t,title:e,type:`error`}),this.warning=(e,t)=>this.create({...t,title:e,type:`warning`}),this.info=(e,t)=>this.create({...t,title:e,type:`info`}),this.loading=(e,t)=>this.create({...t,title:e,type:`loading`}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({promise:e,type:`loading`,title:t.loading,description:typeof t.description==`function`?void 0:t.description,duration:1/0}));let r=Promise.resolve(e instanceof Function?e():e),i=n!==void 0,a,o=r.then(async e=>{if(a=[`resolve`,e],bv(e)&&!e.ok){i=!1;let r=typeof t.error==`function`?await t.error(`HTTP error! status: ${e.status}`):t.error,a=typeof t.description==`function`?await t.description(`HTTP error! status: ${e.status}`):t.description;this.create({id:n,type:`error`,title:r,description:a})}else if(t.success!==void 0){i=!1;let r=typeof t.success==`function`?await t.success(e):t.success,a=typeof t.description==`function`?await t.description(e):t.description;this.create({id:n,type:`success`,title:r,description:a})}}).catch(async e=>{if(a=[`reject`,e],t.error!==void 0){i=!1;let r=typeof t.error==`function`?await t.error(e):t.error,a=typeof t.description==`function`?await t.description(e):t.description;this.create({id:n,type:`error`,title:r,description:a})}}).finally(()=>{i&&(this.dismiss(n),n=void 0),t.finally?.()}),s=()=>new Promise((e,t)=>o.then(()=>a[0]===`reject`?t(a[1]):e(a[1])).catch(t));return typeof n!=`string`&&typeof n!=`number`?{unwrap:s}:Object.assign(n,{unwrap:s})},this.custom=(e,t)=>{let n=t?.id??vv++;return this.create({jsx:e(n),...t,id:n}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.getHistory=()=>this.toasts}};function bv(e){return e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`}var xv=new yv,Sv=Object.assign((e,t)=>xv.create({...t,title:e}),{success:xv.success,error:xv.error,warning:xv.warning,info:xv.info,loading:xv.loading,promise:xv.promise,custom:xv.custom,dismiss:xv.dismiss,message:xv.message,getHistory:()=>xv.getHistory(),getToasts:()=>xv.getActiveToasts()});function Cv(e,t){let n=typeof e.title==`function`?e.title():e.title;if(typeof n!=`string`)return!1;let r=typeof e.description==`function`?e.description():e.description,i=e.type??`default`,a=i===`error`?`error`:i===`success`?`done`:`none`,o=i===`error`?`error`:i===`success`?`success`:i===`warning`?`warning`:`none`;return tu(n,{message:typeof r==`string`?r:void 0,duration:e.duration??t.duration,burntOptions:{preset:a,haptic:o,...t.burntOptions},notificationOptions:t.notificationOptions})!==!1}var wv=.11;function Tv(e,t=25){if(e>=0)return e;let n=Math.sqrt(Math.abs(e))*2;return-Math.min(n,t)}var Ev=80;function Dv(e){if(Math.abs(e)<=Ev)return e;let t=e>0?1:-1,n=Math.abs(e)-Ev;return t*(Ev+Math.sqrt(n)*2)}function Ov(e){let{direction:t,threshold:n,disabled:r,expanded:i,onDragMove:a,onDragStart:o,onDismiss:s,onCancel:c}=e,[l,u]=V.useState(!1),d=V.useRef(null),f=V.useRef(null),p=V.useRef(null),m=t===`left`||t===`right`||t===`horizontal`,h=t===`up`||t===`down`||t===`vertical`,g=V.useRef(null);function _(){if(typeof document>`u`)return;window.getSelection()?.removeAllRanges();let e=e=>e.preventDefault();g.current=e,document.addEventListener(`selectstart`,e,!0)}function v(){g.current&&=(document.removeEventListener(`selectstart`,g.current,!0),null)}let y=V.useCallback(()=>{d.current=null,f.current=null,u(!1),v()},[]);return V.useEffect(()=>()=>{if(d.current){if(p.current&&d.current.pointerId)try{p.current.releasePointerCapture(d.current.pointerId)}catch{}y()}},[y]),{isDragging:l,gestureHandlers:{onPointerDown:V.useCallback(e=>{if(r||e.button!==0||e.target.closest(`button, a, input, textarea, select, [role="button"]`)||(window.getSelection()?.toString().length??0)>0)return;let t=e.currentTarget;p.current=t,t.setPointerCapture(e.pointerId),d.current={startX:e.clientX,startY:e.clientY,startTime:Date.now(),pointerId:e.pointerId},_(),u(!0),o?.()},[r,o]),onPointerMove:V.useCallback(e=>{if(!d.current||r)return;let n=e.clientX-d.current.startX,i=e.clientY-d.current.startY;!f.current&&(Math.abs(n)>1||Math.abs(i)>1)&&(f.current=Math.abs(n)>Math.abs(i)?`x`:`y`);let o=0,s=0;t===`right`?o=n>0?Dv(n):Tv(n):t===`left`?o=n<0?Dv(n):-Tv(-n):t===`down`?s=i>0?Dv(i):Tv(i):t===`up`?s=i<0?Dv(i):-Tv(-i):t===`horizontal`?o=Dv(n):t===`vertical`&&(s=Dv(i)),a(o,s)},[r,t,i,m,h,a]),onPointerUp:V.useCallback(e=>{if(!d.current||r)return;let i=e.clientX-d.current.startX,a=e.clientY-d.current.startY,o=Date.now()-d.current.startTime,l=Math.abs(i)/o,u=Math.abs(a)/o,g=f.current,_=g===`y`&&m||g===`x`&&h,v=m?i:a,b=m?l:u,x=Math.abs(v)>=n,S=b>wv,C=null;_||(t===`right`&&i>0?C=`right`:t===`left`&&i<0?C=`left`:t===`horizontal`?Math.abs(i)>Math.abs(a)&&(C=i>0?`right`:`left`):t===`down`&&a>0?C=`down`:t===`up`&&a<0?C=`up`:t===`vertical`&&Math.abs(a)>Math.abs(i)&&(C=a>0?`down`:`up`));let w=C&&(x||S);if(p.current)try{p.current.releasePointerCapture(e.pointerId)}catch{}y(),w&&C?s(C,b):c()},[r,t,n,m,h,s,c,y]),onPointerCancel:V.useCallback(e=>{if(p.current)try{p.current.releasePointerCapture(e.pointerId)}catch{}y(),c()},[c,y]),onLostPointerCapture:V.useCallback(()=>{d.current&&(y(),c())},[c,y])},gesture:null}}var kv={type:`spring`,damping:30,stiffness:400,mass:.5},Av=200;function jv(e,t,n,r,i,a,o){let{damping:s=30,stiffness:c=400,mass:l=.5,initialVelocityX:u=0,initialVelocityY:d=0,fadeOut:f=!1}=a,p=t,m=n,h=u,g=d,_=null,v=r,y=i,b=Math.sqrt((r-t)**2+(i-n)**2)||1;function x(){let r=-c*(p-v),i=-c*(m-y),a=-s*h,u=-s*g,d=(r+a)/l,S=(i+u)/l;if(h+=d*.016,g+=S*.016,p+=h*.016,m+=g*.016,e.style.transform=`translate3d(${p}px, ${m}px, 0)`,f){let r=Math.sqrt((p-t)**2+(m-n)**2),i=Math.min(r/b,1);e.style.opacity=String(1-i)}let C=Math.abs(p-v),w=Math.abs(m-y),T=Math.sqrt(h*h+g*g);if(C<.5&&w<.5&&T<.5){e.style.transform=`translate3d(${v}px, ${y}px, 0)`,f&&(e.style.opacity=`0`),o?.();return}_=requestAnimationFrame(x)}return _=requestAnimationFrame(x),()=>{_&&cancelAnimationFrame(_)}}function Mv(e={}){let{onExitComplete:t,reducedMotion:n,swipeAxis:r=`horizontal`}=e,{animationDriver:i}=ye();if(!i)throw Error(`Toast requires an animation driver to be set in GuiProvider`);let{useAnimatedNumber:a,useAnimatedNumberStyle:o,useAnimatedNumbersStyle:s}=i,c=i.View??w,l=V.useRef(null),u=V.useRef(null),d=V.useRef({x:0,y:0}),p=a(0),m=a(0),h=s?s([p,m],(e,t)=>{"worklet";return{transform:[{translateX:e},{translateY:t}]}}):o(r===`vertical`?m:p,e=>{"worklet";let t=r===`vertical`?p.getValue():m.getValue();return r===`vertical`?{transform:[{translateX:t},{translateY:e}]}:{transform:[{translateX:e},{translateY:t}]}}),g=f((e,t)=>{u.current?.(),u.current=null,d.current={x:e,y:t},l.current?(l.current.style.transform=`translate3d(${e}px, ${t}px, 0)`,l.current.style.opacity=`1`):(p.setValue(e,{type:`direct`}),m.setValue(t,{type:`direct`}))}),_=f(e=>{if(u.current?.(),n){l.current?l.current.style.transform=`translate3d(0px, 0px, 0)`:(p.setValue(0,{type:`direct`}),m.setValue(0,{type:`direct`})),d.current={x:0,y:0},e?.();return}if(l.current){let{x:t,y:n}=d.current;u.current=jv(l.current,t,n,0,0,kv,()=>{d.current={x:0,y:0},e?.()})}else p.setValue(0,kv),m.setValue(0,kv,e)}),v=f((e,r,i)=>{u.current?.();let{x:a,y:o}=d.current,s=e===`left`?-200:e===`right`?Av:0,c=e===`up`?-200:e===`down`?Av:0;if(e===`left`&&a<s?s=a-50:e===`right`&&a>s&&(s=a+50),e===`up`&&o<c?c=o-50:e===`down`&&o>c&&(c=o+50),n){l.current?l.current.style.transform=`translate3d(${s}px, ${c}px, 0)`:(p.setValue(s,{type:`direct`}),m.setValue(c,{type:`direct`})),i?.(),t?.();return}let f=(r??0)*500,h={damping:25,stiffness:350,mass:.4,initialVelocityX:e===`left`?-f:e===`right`?f:0,initialVelocityY:e===`up`?-f:e===`down`?f:0,fadeOut:!0};if(l.current){let{x:e,y:n}=d.current;u.current=jv(l.current,e,n,s,c,h,()=>{i?.(),t?.()})}else{let e={type:`spring`,damping:25,stiffness:350,mass:.4};p.setValue(s,e),m.setValue(c,e,()=>{i?.(),t?.()})}}),y=f(()=>{u.current?.(),p.stop(),m.stop()});return V.useEffect(()=>()=>{u.current?.()},[]),{setDragOffset:g,springBack:_,animateOut:v,stop:y,animatedStyle:h,AnimatedView:c,dragRef:l}}var Nv=null;function Pv(){return Nv===null?typeof window>`u`?!1:(Nv=window.matchMedia?.(`(prefers-reduced-motion: reduce)`)?.matches??!1,Nv):Nv}function Fv(e){let[t,n]=V.useState(()=>e??Pv());return V.useEffect(()=>{if(e!==void 0){n(e);return}if(typeof window>`u`)return;let t=window.matchMedia?.(`(prefers-reduced-motion: reduce)`);if(!t)return;let r=e=>{Nv=e.matches,n(e.matches)};return t.addEventListener?.(`change`,r),()=>{t.removeEventListener?.(`change`,r)}},[e]),t}var Iv=M(z,{name:`ToastPositionWrapper`,pointerEvents:`auto`,position:`absolute`,left:0,right:0,opacity:1,scale:1,y:0,x:0}),Lv=M(z,{name:`ToastItem`,userSelect:`none`,cursor:`default`,focusable:!0,variants:{unstyled:{false:{backgroundColor:`$background`,borderRadius:`$6`,paddingHorizontal:`$4`,paddingVertical:`$3`,borderWidth:1,borderColor:`$borderColor`,shadowColor:`rgba(0, 0, 0, 0.15)`,shadowOffset:{width:0,height:4},shadowRadius:12,focusVisibleStyle:{outlineWidth:2,outlineColor:`$color8`,outlineStyle:`solid`}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),Rv=M(y,{name:`ToastClose`,render:`button`,alignItems:`center`,justifyContent:`center`,cursor:`pointer`,variants:{unstyled:{false:{width:18,height:18,borderRadius:`$10`,backgroundColor:`$background`,borderWidth:1,borderColor:`$borderColor`,shadowColor:`rgba(0, 0, 0, 0.08)`,shadowOffset:{width:0,height:1},shadowRadius:3,hoverStyle:{backgroundColor:`$color3`},pressStyle:{backgroundColor:`$color4`}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),zv=M(y,{name:`ToastAction`,render:`button`,alignItems:`center`,justifyContent:`center`,cursor:`pointer`,variants:{unstyled:{false:{borderRadius:`$2`,paddingHorizontal:`$2`,height:24,backgroundColor:`$color5`,hoverStyle:{backgroundColor:`$color6`},pressStyle:{backgroundColor:`$color7`}}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),Bv=()=>(0,H.jsx)(a,{size:`$1`,color:`$color11`,children:`✕`}),Vv=4,Hv=16,Uv=14,Wv=4e3,Gv=72,Kv=200,qv=[`altKey`,`KeyT`],Jv=S({},`Toast__`),Yv=Jv.useStyledContext;function Xv(e){return!!e&&Array.isArray(e.toasts)&&typeof e.setToastHeight==`function`&&typeof e.removeToast==`function`}function Zv(e){let t=Yv();if(!Xv(t))throw Error(`\`${e}\` must be used within \`Toast\``);return t}var Qv=V.createContext(null);function $v(){let e=V.useContext(Qv);if(!e)throw Error(`useToastItemContext must be used within Toast.Item or Toast.List`);return e}function ey(e,t){if(e!==`auto`)return e;let[n,r]=t.split(`-`);return r===`left`?`left`:r===`right`?`right`:`horizontal`}var ty=V.forwardRef(function(e,t){let{children:n,position:r=`bottom-right`,duration:i=Wv,gap:a=Uv,visibleToasts:o=Vv,swipeDirection:s=`auto`,swipeThreshold:c=50,toastHeight:l=Gv,closeButton:u=!1,expand:d=!1,theme:f,reducedMotion:p,native:m=!1,burntOptions:h,notificationOptions:g,icons:_}=e,v=Fv(p),[y,b]=V.useState([]),[x,S]=V.useState({}),[C,w]=V.useState(!1),T=d||C,[E,D]=V.useState(!1),O=V.useRef(!1),k=V.useRef(T);V.useLayoutEffect(()=>{k.current!==T&&(O.current=!0,k.current=T);let e=setTimeout(()=>{O.current=!1},350);return()=>clearTimeout(e)},[T]);let A=V.useCallback((e,t)=>{if(O.current)return;let n=Math.round(t);S(t=>{let r=t[e];return r!=null&&Math.abs(r-n)<=2?t:{...t,[e]:n}})},[]),j=V.useCallback(e=>{S(t=>{if(!(e in t))return t;let n={...t};return delete n[e],n})},[]),ee=V.useRef(!1),M=V.useRef(null),N=V.useCallback(()=>{ee.current=!0,M.current&&clearTimeout(M.current),M.current=setTimeout(()=>{ee.current=!1},800)},[]),P=V.useCallback(()=>ee.current,[]),te=V.useRef(h),F=V.useRef(g);V.useEffect(()=>{te.current=h},[h]),V.useEffect(()=>{F.current=g},[g]),V.useEffect(()=>xv.subscribe(e=>{if(e.dismiss){b(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t));return}m&&Cv(e,{duration:i,burntOptions:te.current,notificationOptions:F.current})||b(t=>{let n=t.findIndex(t=>t.id===e.id);return n===-1?[e,...t]:[...t.slice(0,n),{...t[n],...e},...t.slice(n+1)]})}),[m,i]);let I=V.useRef(y.length);V.useEffect(()=>{let e=I.current;I.current=y.length,(y.length<=1&&!ee.current||y.length>e&&T)&&w(!1)},[y.length,T]);let ne=V.useCallback(e=>{b(t=>(t.find(t=>t.id===e.id)?.delete||xv.dismiss(e.id),t.filter(({id:t})=>t!==e.id)))},[]),re=ey(s,r),ie=dn(),L=f===`system`||!f?ie?.includes(`dark`)?`dark`:`light`:f,ae={toasts:y,heights:x,setToastHeight:A,removeToastHeight:j,expanded:T,setExpanded:w,interacting:E,setInteracting:D,triggerDismissCooldown:N,isInDismissCooldown:P,removeToast:ne,position:r,duration:i,gap:a,visibleToasts:o,swipeDirection:re,swipeThreshold:c,toastHeight:l,closeButton:u,reducedMotion:v,native:m,burntOptions:h,notificationOptions:g,icons:_};return(0,H.jsx)(Jv.Provider,{...ae,children:(0,H.jsx)(se,{name:L,children:n})})}),ny=M(w,{name:`ToastViewport`,variants:{unstyled:{false:{position:`fixed`,zIndex:1e5,pointerEvents:`box-none`,maxWidth:`100%`,width:356,minHeight:1}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),ry=ny.styleable(function(e,t){let{offset:n=Hv,hotkey:r=qv,label:i=`Notifications`,portalToRoot:a=!0,portalZIndex:o=2**53-1,children:s,...c}=e,l=Zv(`Toast.Viewport`),u=V.useRef(null),d=V.useRef(null),f=V.useRef(!1),p=V.useRef(null),m=V.useRef(!1),[h,g]=l.position.split(`-`),{insets:_}=ye(),v=V.useMemo(()=>{let e={},t=typeof n==`number`?n:Hv,r=typeof n==`object`?n:{top:t,right:t,bottom:t,left:t},i=_?.top??0,a=_?.bottom??0,o=i>0?i:r.top??t,s=a>0?a:r.bottom??t;return h===`top`?e.top=o:e.bottom=s,g===`left`?e.left=r.left??t:g===`right`?e.right=r.right??t:(e.left=`50%`,e.transform=`translateX(-50%)`),e},[n,h,g]);if(V.useEffect(()=>{let e=e=>{r.length>0&&r.every(t=>e[t]||e.code===t)&&(l.setExpanded(!0),u.current?.focus())};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[r]),l.toasts.length===0)return null;let y=r.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),b=(0,H.jsx)(ny,{ref:u,"aria-label":`${i} ${y}`,tabIndex:-1,"aria-live":`polite`,style:v,"data-y-position":h,"data-x-position":g,onMouseEnter:()=>{m.current=!0,p.current&&=(clearTimeout(p.current),null),l.toasts.length>1&&!l.interacting&&!f.current&&(d.current=setTimeout(()=>l.setExpanded(!0),50))},onMouseLeave:()=>{m.current=!1,d.current&&=(clearTimeout(d.current),null),!l.interacting&&!l.isInDismissCooldown()?l.setExpanded(!1):l.isInDismissCooldown()&&(p.current&&clearTimeout(p.current),p.current=setTimeout(()=>{p.current=null,m.current||l.setExpanded(!1)},1200))},onPointerDown:()=>{d.current&&=(clearTimeout(d.current),null),l.setInteracting(!0)},onPointerUp:()=>l.setInteracting(!1),onPointerCancel:()=>l.setInteracting(!1),onFocus:e=>{e.currentTarget.contains(e.relatedTarget)||(l.toasts.length>1&&l.setExpanded(!0),l.setInteracting(!0))},onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||(l.setInteracting(!1),l.isInDismissCooldown()||l.setExpanded(!1))},...c,children:s});return a?(0,H.jsx)(Jt,{zIndex:o,children:(0,H.jsx)(Jv.Provider,{...l,children:b})}):b});function iy({renderItem:e}){let t=Zv(`Toast.List`),n=t.toasts.length;return(0,H.jsx)(kn,{children:t.toasts.slice(0,n).map((n,r)=>{let i=()=>{n.dismissible!==!1&&(n.onDismiss?.(n),t.removeToast(n))},a={toast:n,handleClose:i};return e?(0,H.jsx)(Qv.Provider,{value:a,children:e({toast:n,index:r,handleClose:i})},n.id):(0,H.jsx)(Qv.Provider,{value:a,children:(0,H.jsx)(sy,{toast:n,index:r,children:(0,H.jsx)(ay,{toast:n})})},n.id)})})}function ay({toast:e}){let t=Zv(`Toast.Item`),{handleClose:n}=$v();e.type;let r=e.dismissible!==!1,i=typeof e.title==`function`?e.title():e.title,o=typeof e.description==`function`?e.description():e.description;return(0,H.jsxs)(y,{alignItems:`flex-start`,gap:`$3`,children:[(0,H.jsx)(fy,{}),(0,H.jsxs)(z,{flex:1,gap:`$1`,children:[i&&(0,H.jsx)(cy,{children:i}),o&&(0,H.jsx)(ly,{children:o}),(e.action||e.cancel)&&(0,H.jsxs)(y,{gap:`$2`,marginTop:`$2`,children:[e.cancel&&(0,H.jsx)(zv,{backgroundColor:`transparent`,onPress:t=>{e.cancel?.onClick?.(t),n()},children:(0,H.jsx)(a,{size:`$2`,color:`$color11`,children:e.cancel.label})}),e.action&&(0,H.jsx)(zv,{backgroundColor:`$color12`,hoverStyle:{backgroundColor:`$color11`},pressStyle:{backgroundColor:`$color10`},onPress:t=>{e.action?.onClick?.(t),t.defaultPrevented||n()},children:(0,H.jsx)(a,{size:`$2`,fontWeight:`600`,color:`$background`,children:e.action.label})})]})]}),t.closeButton&&r&&(0,H.jsx)(uy,{})]})}function oy({animatedStyle:e,gestureHandlers:t,gesture:n,AnimatedView:r,dragRef:i,children:a}){return(0,H.jsx)(`div`,{ref:i,style:{flex:1,display:`flex`,flexDirection:`column`,userSelect:`none`,WebkitUserSelect:`none`,touchAction:`none`,cursor:`default`},...t,children:a})}var sy=Lv.styleable(function(e,t){let{toast:n,index:r,children:i,...a}=e,o=Zv(`Toast.Item`),[s,c]=V.useState(!1),[l,u]=V.useState(!1),[d,p]=V.useState(!1),[m,h]=V.useState(0),g=V.useRef(null),_=V.useRef(null),v=V.useRef(0),y=V.useRef(0),b=V.useRef(n.duration??o.duration),x=r===0,S=r<o.visibleToasts,C=n.type??`default`,T=n.dismissible!==!1,E=n.duration??o.duration,[D]=o.position.split(`-`),O=D===`top`,k=(()=>{let e=0,t=0;for(let n=0;n<r;n++){let r=o.toasts[n]?.id;if(r==null)continue;let i=o.heights[r];i!==0&&(e+=i??o.toastHeight,t++)}return e+t*o.gap})(),A=V.useRef(k);A.current=k;let j=V.useRef(o.expanded);j.current=o.expanded;let ee=V.useCallback(()=>{E!==1/0&&C!==`loading`&&(v.current=Date.now(),_.current=setTimeout(()=>{n.onAutoClose?.(n),u(!0),setTimeout(()=>o.removeToast(n),Kv)},b.current))},[E,C,n,o.removeToast]),M=f(()=>{if(_.current&&clearTimeout(_.current),y.current<v.current){let e=Date.now()-v.current;b.current=Math.max(0,b.current-e)}y.current=Date.now()}),N=f(()=>{o.expanded||o.interacting||(b.current=E,ee())});V.useEffect(()=>{c(!0)},[]),V.useEffect(()=>{n.delete&&(u(!0),j.current&&h(A.current),setTimeout(()=>o.removeToast(n),Kv))},[n.delete,n,o.removeToast]),V.useEffect(()=>(o.expanded||o.interacting?M():ee(),()=>{_.current&&clearTimeout(_.current)}),[o.expanded,o.interacting,ee]),V.useEffect(()=>{b.current=E},[E]);let{setDragOffset:P,springBack:te,animateOut:F,animatedStyle:I,AnimatedView:ne,dragRef:re}=Mv({reducedMotion:o.reducedMotion,swipeAxis:o.swipeDirection===`up`||o.swipeDirection===`down`||o.swipeDirection===`vertical`?`vertical`:`horizontal`}),{isDragging:ie,gestureHandlers:L,gesture:ae}=Ov({direction:o.swipeDirection,threshold:o.swipeThreshold,disabled:!T||C===`loading`,expanded:o.expanded,onDragStart:M,onDragMove:P,onDismiss:(e,t)=>{o.triggerDismissCooldown(),p(!0),n.onDismiss?.(n),g.current=j.current?O?A.current:-A.current:x?0:O?o.gap*r:-o.gap*r,u(!0),o.removeToast(n),F(e,t)},onCancel:()=>{te(()=>{N()})}}),oe=V.useCallback(e=>{if(l||!o.expanded&&r!==0)return;let{height:t}=e.nativeEvent.layout;o.setToastHeight(n.id,t)},[n.id,o.setToastHeight,r,o.expanded,l]);V.useEffect(()=>()=>{o.removeToastHeight(n.id)},[n.id,o.removeToastHeight]);let R=V.useCallback(()=>{T&&(o.triggerDismissCooldown(),n.onDismiss?.(n),u(!0),j.current&&h(A.current),setTimeout(()=>o.removeToast(n),Kv))},[T,n,o.removeToast,o.triggerDismissCooldown]),se=V.useMemo(()=>({toast:n,handleClose:R}),[n,R]),ce=-1;for(let e of o.toasts){let t=o.heights[e.id];if(t!=null&&t>0){ce=t;break}}let le=!o.expanded&&!x?1-r*.05:1,ue=l?m:k,de=o.expanded?O?ue:-ue:x?0:O?o.gap*r:-o.gap*r,fe=l&&!d||r>=o.visibleToasts?0:1,pe=l?0:o.visibleToasts-r+1,me=o.expanded?o.heights[n.id]||void 0:!x&&ce>0?ce:void 0,he=r>=o.visibleToasts?`none`:`auto`,ge=o.expanded?o.gap+1:0,_e={"data-mounted":s?`true`:`false`,"data-removed":l?`true`:`false`,"data-swipe-out":d?`true`:`false`,"data-visible":S?`true`:`false`,"data-front":x?`true`:`false`,"data-index":String(r),"data-type":C,"data-expanded":o.expanded?`true`:`false`};return(0,H.jsx)(Iv,{ref:t,testID:a.testID,accessibilityLabel:a.accessibilityLabel,..._e,transition:ie||o.reducedMotion?void 0:l?`200ms`:`400ms`,animateOnly:[`transform`,`opacity`,`height`],y:de,scale:le,opacity:fe,zIndex:pe,height:me,overflow:`visible`,pointerEvents:he,top:O?0:void 0,bottom:O?void 0:0,...!x&&{style:{transformOrigin:O?`top center`:`bottom center`}},enterStyle:o.reducedMotion?{opacity:0}:{opacity:0,y:O?-80:80},exitStyle:o.reducedMotion?{opacity:0}:d?{opacity:0,y:g.current??de,scale:le}:{opacity:0,y:de,scale:le},children:(0,H.jsx)(oy,{animatedStyle:I,gestureHandlers:L,gesture:ae,AnimatedView:ne,dragRef:re,children:(0,H.jsxs)(Lv,{"data-slot":`toast`,role:`status`,"aria-live":`polite`,"aria-atomic":!0,tabIndex:0,onLayout:oe,onKeyDown:e=>{if(e.key===`Escape`&&T){let t=e.currentTarget,n=t.closest(`[aria-label]`);if(n){let e=n.querySelectorAll(`[tabindex="0"]`),r=Array.from(e),i=r.indexOf(t);(r[i+1]||r[i-1])?.focus()}R()}},...a,children:[o.expanded&&ge>0&&(0,H.jsx)(w,{position:`absolute`,left:0,right:0,height:ge,pointerEvents:`auto`,...O?{top:`100%`}:{bottom:`100%`}}),(0,H.jsx)(Qv.Provider,{value:se,children:i})]})})})}),cy=M(a,{name:`ToastTitle`,variants:{unstyled:{false:{color:`$color`,fontWeight:`600`,size:`$4`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),ly=M(a,{name:`ToastDescription`,variants:{unstyled:{false:{color:`$color11`,size:`$2`}}},defaultVariants:{unstyled:{}.GUI_HEADLESS===`1`}}),uy=Rv.styleable(function(e,t){let n;try{n=$v().handleClose}catch{}let r=Zv(`Toast.Close`);return(0,H.jsx)(Rv,{ref:t,"aria-label":`Close toast`,onPress:n,...e,children:e.children??r.icons?.close??(0,H.jsx)(Bv,{})})}),dy=zv.styleable(function(e,t){return(0,H.jsx)(zv,{ref:t,...e})});function fy(e){let t=Zv(`Toast.Icon`),n;try{n=$v().toast}catch{return null}if(!n)return null;if(n.icon!==void 0)return(0,H.jsx)(w,{flexShrink:0,marginTop:`$0.5`,children:n.icon});let r=n.type??`default`,i=t.icons?.[r]??null;return i?(0,H.jsx)(w,{flexShrink:0,marginTop:`$0.5`,children:i}):null}function py(){let e=Zv(`useToasts`);return{toasts:e.toasts,expanded:e.expanded,position:e.position}}ty.displayName=`Toast`;var my=oe(ty,{Viewport:ry,List:iy,Item:sy,Title:cy,Description:ly,Close:uy,Action:dy,Icon:fy}),hy={neutral:`gray`,info:`blue`,success:`green`,warning:`orange`,error:`red`},gy={gray:{ink:`$ink`,fill:`$raised`,on:`$ink`,tint:`$hover`,ground:`var(--data-gray-1)`,edge:`var(--data-gray-6)`},blue:{ink:`var(--primary)`,fill:`var(--primary)`,on:`var(--primary-foreground)`,tint:`var(--glass-strong)`,ground:`var(--data-blue-1)`,edge:`var(--data-blue-6)`},green:{ink:`var(--state-success)`,fill:`var(--state-success)`,on:`var(--neutral-950)`,tint:`var(--state-success-bg)`,ground:`var(--data-green-1)`,edge:`var(--data-green-6)`},orange:{ink:`var(--state-warning)`,fill:`var(--state-warning)`,on:`var(--neutral-950)`,tint:`var(--state-warning-bg)`,ground:`var(--data-orange-1)`,edge:`var(--data-orange-6)`},red:{ink:`var(--state-error)`,fill:`var(--destructive)`,on:`var(--destructive-foreground)`,tint:`var(--state-error-bg)`,ground:`var(--data-red-1)`,edge:`var(--data-red-6)`}},_y=(e,t)=>t??hy[e??`neutral`],vy=(e,t)=>gy[_y(e,t)],yy=296,by=8,xy=12,Sy={default:`neutral`,loading:`neutral`,info:`info`,success:`success`,warning:`warning`,error:`error`},Cy={neutral:D(`neutral`),info:D(`info`),success:D(`success`),warning:D(`warning`),error:D(`error`)},wy={neutral:jm,info:Xp,success:Tm,warning:jm,error:jm},Ty=e=>typeof e==`function`?e():e,Ey=e=>{let t=e.data?.progress;return typeof t==`number`&&Number.isFinite(t)?Math.max(0,Math.min(100,t)):null},Dy=e=>({...h_(2),width:e?`100%`:yy,rounded:e?0:`$3`,borderWidth:0,p:0,overflow:`hidden`}),Oy={position:`relative`,pt:`$2`,px:`$2`,pb:`$1`};function ky({t:e,duration:t,paused:n=!1,onClose:r,onHold:i}){let o=R(),s=Sy[e.type??`default`]??`neutral`,c=vy(s),l=wy[s],u=Ey(e),d=Ty(e.title),f=e.description?Ty(e.description):null;return(0,H.jsxs)(z,{...B(`toast-body`),...Oy,...i?{onHoverIn:()=>i(!0),onHoverOut:()=>i(!1),onFocus:()=>i(!0),onBlur:()=>i(!1)}:null,children:[u===null?t===void 0?null:(0,H.jsx)(w,{...B(`toast-countdown`),"data-motion":`drain`,"data-paused":n?``:void 0,position:`absolute`,t:0,l:0,r:0,b:0,bg:c.tint,pointerEvents:`none`,style:{"--drain":`${t}ms`}}):(0,H.jsx)(w,{...B(`toast-progress`),position:`absolute`,t:0,insetInlineStart:0,b:0,bg:c.tint,style:{width:`${u}%`,transition:`width 300ms linear`},pointerEvents:`none`}),(0,H.jsxs)(y,{...B(`toast-header`),items:`center`,gap:`$2`,mb:`$1`,minH:24,children:[(0,H.jsx)(w,{shrink:0,width:16,height:16,items:`center`,justify:`center`,children:e.icon??(0,H.jsx)(l,{size:16,color:c.ink,"aria-label":o.t(Cy[s])})}),(0,H.jsx)(a,{...B(`toast-message`),flex:1,size:`$1`,fontWeight:`500`,color:`$aside`,numberOfLines:2,children:d}),e.cancel?(0,H.jsx)(W,{...B(`toast-cancel`),size:`xs`,variant:`ghost`,fontWeight:`400`,onPress:t=>{e.cancel?.onClick?.(t),r?.()},children:e.cancel.label||o.t(`Cancel`)}):null,e.dismissible===!1?null:(0,H.jsx)(W,{...B(`toast-close`),size:`icon-xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":o.t(`Close`),onPress:r,children:(0,H.jsx)(Rn,{})})]}),f?(0,H.jsx)(a,{...B(`toast-description`),size:`$1`,color:`$hint`,paddingInlineStart:24,maxW:224,numberOfLines:1,mb:`$1`,children:f}):null,e.action?(0,H.jsx)(z,{...B(`toast-footer`),mt:`$2`,borderTopWidth:1,borderColor:`$borderColor`,pt:`$1`,items:`flex-end`,children:(0,H.jsx)(W,{size:`xs`,variant:`ghost`,onPress:t=>{e.action?.onClick?.(t),t?.defaultPrevented||r?.()},children:e.action.label})}):null]})}function Ay({t:e,index:t,fallback:n,phone:r}){let i=Ey(e),a=e.duration??n,o=i===null&&e.type!==`loading`&&Number.isFinite(a)&&a>0,[s,c]=(0,V.useState)(!1),l=(0,V.useRef)(a),u=(0,V.useRef)(!1);(0,V.useEffect)(()=>{if(!o||s||u.current)return;let t=Date.now(),n=setTimeout(()=>{u.current=!0,e.onAutoClose?.(e),Sv.dismiss(e.id)},l.current);return()=>{clearTimeout(n),l.current=Math.max(0,l.current-(Date.now()-t))}},[o,s,e]);let d=(0,V.useMemo)(()=>({...e,duration:1/0}),[e]),f=()=>{e.onDismiss?.(e),Sv.dismiss(e.id)};return(0,H.jsx)(my.Item,{toast:d,index:t,...Dy(r),"data-status":Sy[e.type??`default`]??`neutral`,children:(0,H.jsx)(ky,{t:e,duration:o?a:void 0,paused:s,onClose:f,onHold:c})})}function jy({limit:e}){let{toasts:t}=py(),n=t.filter(e=>!e.delete);return(0,V.useEffect)(()=>{for(let t of n.slice(e))Sv.dismiss(t.id)},[n,e]),null}var My=(0,V.forwardRef)(function(e,t){let{theme:n=`system`,toastOptions:r,richColors:i,className:a,style:o,position:s,offset:c,gap:l,limit:u=3,duration:d,containerAriaLabel:f,hotkey:p,...m}=e,h=R(),g=!!te()[`max-md`],_=r?.duration??d??6e3;return(0,H.jsx)(my,{...m,theme:n,position:s??(g?`top-center`:`bottom-right`),gap:l??by,visibleToasts:u,duration:1/0,children:(0,H.jsxs)(my.Viewport,{ref:t,...B(`toaster`),offset:c??(g?0:xy),hotkey:p,label:f??h.t(`Notifications`),...g?{width:`100%`}:null,children:[(0,H.jsx)(jy,{limit:u}),(0,H.jsx)(my.List,{renderItem:({toast:e,index:t})=>(0,H.jsx)(Ay,{t:e,index:t,fallback:_,phone:g},e.id)})]})})});function G(e){let t={};for(let[n,r]of e)t[aee[n]]=iee[r];return t}var iee=[`hsla(0, 0%, 10%, 1)`,`hsla(0, 0%, 67%, 1)`,`hsla(0, 0%, 100%, 0)`,`hsla(0, 0%, 97%, 0.2)`,`hsla(0, 0%, 97%, 0.4)`,`hsla(0, 0%, 97%, 0.6)`,`hsla(0, 0%, 97%, 0.8)`,`hsla(0, 0%, 100%, 1)`,`hsla(0, 0%, 97%, 1)`,`hsla(0, 0%, 93%, 1)`,`hsla(0, 0%, 85%, 1)`,`hsla(0, 0%, 80%, 1)`,`hsla(0, 0%, 70%, 1)`,`hsla(0, 0%, 59%, 1)`,`hsla(0, 0%, 45%, 1)`,`hsla(0, 0%, 30%, 1)`,`hsla(0, 0%, 20%, 1)`,`hsla(0, 0%, 14%, 1)`,`hsla(0, 0%, 2%, 1)`,`hsla(0, 0%, 2%, 0)`,`hsla(0, 0%, 2%, 0.2)`,`hsla(0, 0%, 2%, 0.4)`,`hsla(0, 0%, 2%, 0.6)`,`hsla(0, 0%, 2%, 0.8)`,`#090909`,`#151515`,`#191919`,`#232323`,`#333`,`#444`,`#666`,`#777`,`#858585`,`#aaa`,`#ccc`,`#ffffff`,`#fff`,`#f8f8f8`,`hsl(0, 0%, 93%)`,`hsl(0, 0%, 85%)`,`hsl(0, 0%, 80%)`,`hsl(0, 0%, 70%)`,`hsl(0, 0%, 59%)`,`hsl(0, 0%, 45%)`,`hsl(0, 0%, 30%)`,`hsl(0, 0%, 20%)`,`hsl(0, 0%, 14%)`,`hsl(0, 0%, 2%)`,`rgba(255,255,255,1)`,`rgba(255,255,255,0)`,`rgba(255,255,255,0.2)`,`rgba(255,255,255,0.4)`,`rgba(255,255,255,0.6)`,`rgba(255,255,255,0.8)`,`rgba(0,0,0,1)`,`rgba(0,0,0,0)`,`rgba(0,0,0,0.2)`,`rgba(0,0,0,0.4)`,`rgba(0,0,0,0.6)`,`rgba(0,0,0,0.8)`,`rgba(0,0,0,0.04)`,`rgba(0,0,0,0.08)`,`rgba(0,0,0,0.12)`,`rgba(0,0,0,0.22)`,`rgba(0,0,0,0.33)`,`rgba(0,0,0,0.44)`,`rgba(0,0,0,0.75)`,`rgba(255,255,255,0.05)`,`rgba(255,255,255,0.1)`,`rgba(255,255,255,0.15)`,`rgba(255,255,255,0.3)`,`rgba(255,255,255,0.55)`,`rgba(255,255,255,0.7)`,`rgba(255,255,255,0.85)`,`#fcfcfc`,`#f9f9f9`,`#f0f0f0`,`#e8e8e8`,`#e0e0e0`,`#d9d9d9`,`#cecece`,`#bbbbbb`,`#8d8d8d`,`#838383`,`#646464`,`#202020`,`#fbfdff`,`#f4faff`,`#e6f4fe`,`#d5efff`,`#c2e5ff`,`#acd8fc`,`#8ec8f6`,`#5eb1ef`,`#0090ff`,`#0588f0`,`#0d74ce`,`#113264`,`#fffcfc`,`#fff7f7`,`#feebec`,`#ffdbdc`,`#ffcdce`,`#fdbdbe`,`#f4a9aa`,`#eb8e90`,`#e5484d`,`#dc3e42`,`#ce2c31`,`#641723`,`#fdfdf9`,`#fefce9`,`#fffab8`,`#fff394`,`#ffe770`,`#f3d768`,`#e4c767`,`#d5ae39`,`#ffe629`,`#ffdc00`,`#9e6c00`,`#473b1f`,`#fbfefc`,`#f4fbf6`,`#e6f6eb`,`#d6f1df`,`#c4e8d1`,`#adddc0`,`#8eceaa`,`#5bb98b`,`#30a46c`,`#2b9a66`,`#218358`,`#193b2d`,`#fefcfb`,`#fff7ed`,`#ffefd6`,`#ffdfb5`,`#ffd19a`,`#ffc182`,`#f5ae73`,`#ec9455`,`#f76b15`,`#ef5f00`,`#cc4e00`,`#582d1d`,`#fffcfe`,`#fef7fb`,`#fee9f5`,`#fbdcef`,`#f6cee7`,`#efbfdd`,`#e7acd0`,`#dd93c2`,`#d6409f`,`#cf3897`,`#c2298a`,`#651249`,`#fefcfe`,`#fbf7fe`,`#f7edfe`,`#f2e2fc`,`#ead5f9`,`#e0c4f4`,`#d1afec`,`#be93e4`,`#8e4ec6`,`#8347b9`,`#8145b5`,`#402060`,`#fafefd`,`#f3fbf9`,`#e0f8f3`,`#ccf3ea`,`#b8eae0`,`#a1ded2`,`#83cdc1`,`#53b9ab`,`#12a594`,`#0d9b8a`,`#008573`,`#0d3d38`,`hsl(0, 0%, 68%)`,`hsl(0, 0%, 65%)`,`hsl(0, 0%, 62%)`,`hsl(0, 0%, 56%)`,`hsl(0, 0%, 53%)`,`hsl(0, 0%, 50%)`,`hsl(0, 0%, 47%)`,`hsl(0, 0%, 44%)`,`hsl(0, 0%, 41%)`,`hsl(0, 0%, 38%)`,`hsl(0, 0%, 32%)`,`hsla(0, 0%, 4%, 1)`,`hsla(0, 0%, 8%, 1)`,`hsla(0, 0%, 27%, 1)`,`hsla(0, 0%, 40%, 1)`,`hsla(0, 0%, 47%, 1)`,`hsla(0, 0%, 52%, 1)`,`hsla(0, 0%, 2%, 0.1)`,`hsla(0, 0%, 2%, 0.075)`,`hsla(0, 0%, 2%, 0.05)`,`hsla(0, 0%, 2%, 0.025)`,`hsla(0, 0%, 2%, 0.02)`,`hsla(0, 0%, 2%, 0.01)`,`hsla(0, 0%, 97%, 0.1)`,`hsla(0, 0%, 97%, 0.075)`,`hsla(0, 0%, 97%, 0.05)`,`hsla(0, 0%, 97%, 0.025)`,`hsla(0, 0%, 97%, 0.02)`,`hsla(0, 0%, 97%, 0.01)`,`hsla(0, 0%, 70%, 0.6)`,`hsla(0, 0%, 4%, 0)`,`hsla(0, 0%, 8%, 0.2)`,`hsla(0, 0%, 8%, 0.4)`,`hsla(0, 0%, 8%, 0.6)`,`hsla(0, 0%, 8%, 0.8)`,`hsla(0, 0%, 100%, 0.2)`,`hsla(0, 0%, 100%, 0.4)`,`hsla(0, 0%, 100%, 0.6)`,`hsla(0, 0%, 100%, 0.8)`,`rgba(0,0,0,0.15)`,`rgba(0,0,0,0.23)`,`rgba(0,0,0,0.45)`,`rgba(0,0,0,0.65)`,`rgba(0,0,0,0.9)`,`rgba(255,255,255,0.45)`,`rgba(255,255,255,0.65)`,`rgba(255,255,255,0.95)`,`#111111`,`#222222`,`#2a2a2a`,`#313131`,`#3a3a3a`,`#484848`,`#606060`,`#6e6e6e`,`#7b7b7b`,`#b4b4b4`,`#eeeeee`,`#0d1520`,`#111927`,`#0d2847`,`#003362`,`#004074`,`#104d87`,`#205d9e`,`#2870bd`,`#3b9eff`,`#70b8ff`,`#c2e6ff`,`#191111`,`#201314`,`#3b1219`,`#500f1c`,`#611623`,`#72232d`,`#8c333a`,`#b54548`,`#ec5d5e`,`#ff9592`,`#ffd1d9`,`#14120b`,`#1b180f`,`#2d2305`,`#362b00`,`#433500`,`#524202`,`#665417`,`#836a21`,`#ffff57`,`#f5e147`,`#f6eeb4`,`#0e1512`,`#121b17`,`#132d21`,`#113b29`,`#174933`,`#20573e`,`#28684a`,`#2f7c57`,`#33b074`,`#3dd68c`,`#b1f1cb`,`#17120e`,`#1e160f`,`#331e0b`,`#462100`,`#562800`,`#66350c`,`#7e451d`,`#a35829`,`#ff801f`,`#ffa057`,`#ffe0c2`,`#191117`,`#21121d`,`#37172f`,`#4b143d`,`#591c47`,`#692955`,`#833869`,`#a84885`,`#de51a8`,`#ff8dcc`,`#fdd1ea`,`#18111b`,`#1e1523`,`#301c3b`,`#3d224e`,`#48295c`,`#54346b`,`#664282`,`#8457aa`,`#9a5cd0`,`#d19dff`,`#ecd9fa`,`#0d1514`,`#111c1b`,`#0d2d2a`,`#023b37`,`#084843`,`#145750`,`#1c6961`,`#207e73`,`#0eb39e`,`#0bd8b6`,`#adf0dd`,`hsla(0, 0%, 100%, 0.1)`,`hsla(0, 0%, 100%, 0.075)`,`hsla(0, 0%, 100%, 0.05)`,`hsla(0, 0%, 100%, 0.025)`,`hsla(0, 0%, 100%, 0.02)`,`hsla(0, 0%, 100%, 0.01)`,`hsla(0, 0%, 8%, 0.1)`,`hsla(0, 0%, 8%, 0.075)`,`hsla(0, 0%, 8%, 0.05)`,`hsla(0, 0%, 8%, 0.025)`,`hsla(0, 0%, 8%, 0.02)`,`hsla(0, 0%, 8%, 0.01)`,`hsla(0, 0%, 27%, 0.6)`,`hsla(0, 0%, 99%, 0)`,`hsla(0, 0%, 98%, 0.2)`,`hsla(0, 0%, 98%, 0.4)`,`hsla(0, 0%, 98%, 0.6)`,`hsla(0, 0%, 98%, 0.8)`,`hsla(0, 0%, 99%, 1)`,`hsla(0, 0%, 98%, 1)`,`hsla(0, 0%, 94%, 1)`,`hsla(0, 0%, 91%, 1)`,`hsla(0, 0%, 88%, 1)`,`hsla(0, 0%, 81%, 1)`,`hsla(0, 0%, 73%, 1)`,`hsla(0, 0%, 55%, 1)`,`hsla(0, 0%, 51%, 1)`,`hsla(0, 0%, 39%, 1)`,`hsla(0, 0%, 13%, 1)`,`hsla(0, 0%, 13%, 0)`,`hsla(0, 0%, 13%, 0.2)`,`hsla(0, 0%, 13%, 0.4)`,`hsla(0, 0%, 13%, 0.6)`,`hsla(0, 0%, 13%, 0.8)`,`hsla(0, 0%, 13%, 0.1)`,`hsla(0, 0%, 13%, 0.075)`,`hsla(0, 0%, 13%, 0.05)`,`hsla(0, 0%, 13%, 0.025)`,`hsla(0, 0%, 13%, 0.02)`,`hsla(0, 0%, 13%, 0.01)`,`hsla(0, 0%, 98%, 0.1)`,`hsla(0, 0%, 98%, 0.075)`,`hsla(0, 0%, 98%, 0.05)`,`hsla(0, 0%, 98%, 0.025)`,`hsla(0, 0%, 98%, 0.02)`,`hsla(0, 0%, 98%, 0.01)`,`hsla(0, 0%, 85%, 0.6)`,`hsla(216, 100%, 99%, 0)`,`hsla(207, 100%, 98%, 0.2)`,`hsla(207, 100%, 98%, 0.4)`,`hsla(207, 100%, 98%, 0.6)`,`hsla(207, 100%, 98%, 0.8)`,`hsla(210, 100%, 99%, 1)`,`hsla(207, 100%, 98%, 1)`,`hsla(205, 92%, 95%, 1)`,`hsla(203, 100%, 92%, 1)`,`hsla(206, 100%, 88%, 1)`,`hsla(207, 93%, 83%, 1)`,`hsla(207, 85%, 76%, 1)`,`hsla(206, 82%, 65%, 1)`,`hsla(206, 100%, 50%, 1)`,`hsla(207, 96%, 48%, 1)`,`hsla(208, 88%, 43%, 1)`,`hsla(216, 71%, 23%, 1)`,`hsla(216, 71%, 23%, 0)`,`hsla(216, 71%, 23%, 0.2)`,`hsla(216, 71%, 23%, 0.4)`,`hsla(216, 71%, 23%, 0.6)`,`hsla(216, 71%, 23%, 0.8)`,`hsla(216, 71%, 23%, 0.1)`,`hsla(216, 71%, 23%, 0.075)`,`hsla(216, 71%, 23%, 0.05)`,`hsla(216, 71%, 23%, 0.025)`,`hsla(216, 71%, 23%, 0.02)`,`hsla(216, 71%, 23%, 0.01)`,`hsla(207, 100%, 98%, 0.1)`,`hsla(207, 100%, 98%, 0.075)`,`hsla(207, 100%, 98%, 0.05)`,`hsla(207, 100%, 98%, 0.025)`,`hsla(207, 100%, 98%, 0.02)`,`hsla(207, 100%, 98%, 0.01)`,`hsla(207, 93%, 83%, 0.6)`,`hsla(0, 100%, 99%, 0)`,`hsla(0, 100%, 98%, 0.2)`,`hsla(0, 100%, 98%, 0.4)`,`hsla(0, 100%, 98%, 0.6)`,`hsla(0, 100%, 98%, 0.8)`,`hsla(0, 100%, 99%, 1)`,`hsla(0, 100%, 98%, 1)`,`hsla(357, 90%, 96%, 1)`,`hsla(358, 100%, 93%, 1)`,`hsla(359, 100%, 90%, 1)`,`hsla(359, 94%, 87%, 1)`,`hsla(359, 77%, 81%, 1)`,`hsla(359, 70%, 74%, 1)`,`hsla(358, 75%, 59%, 1)`,`hsla(358, 69%, 55%, 1)`,`hsla(358, 65%, 49%, 1)`,`hsla(351, 63%, 24%, 1)`,`hsla(351, 63%, 24%, 0)`,`hsla(351, 63%, 24%, 0.2)`,`hsla(351, 63%, 24%, 0.4)`,`hsla(351, 63%, 24%, 0.6)`,`hsla(351, 63%, 24%, 0.8)`,`hsla(351, 63%, 24%, 0.1)`,`hsla(351, 63%, 24%, 0.075)`,`hsla(351, 63%, 24%, 0.05)`,`hsla(351, 63%, 24%, 0.025)`,`hsla(351, 63%, 24%, 0.02)`,`hsla(351, 63%, 24%, 0.01)`,`hsla(0, 100%, 98%, 0.1)`,`hsla(0, 100%, 98%, 0.075)`,`hsla(0, 100%, 98%, 0.05)`,`hsla(0, 100%, 98%, 0.025)`,`hsla(0, 100%, 98%, 0.02)`,`hsla(0, 100%, 98%, 0.01)`,`hsla(359, 94%, 87%, 0.6)`,`hsla(60, 45%, 98%, 0)`,`hsla(54, 91%, 95%, 0.2)`,`hsla(54, 91%, 95%, 0.4)`,`hsla(54, 91%, 95%, 0.6)`,`hsla(54, 91%, 95%, 0.8)`,`hsla(60, 50%, 98%, 1)`,`hsla(54, 91%, 95%, 1)`,`hsla(56, 100%, 86%, 1)`,`hsla(53, 100%, 79%, 1)`,`hsla(50, 100%, 72%, 1)`,`hsla(48, 85%, 68%, 1)`,`hsla(46, 70%, 65%, 1)`,`hsla(45, 65%, 53%, 1)`,`hsla(53, 100%, 58%, 1)`,`hsla(52, 100%, 50%, 1)`,`hsla(41, 100%, 31%, 1)`,`hsla(42, 39%, 20%, 1)`,`hsla(42, 39%, 20%, 0)`,`hsla(42, 39%, 20%, 0.2)`,`hsla(42, 39%, 20%, 0.4)`,`hsla(42, 39%, 20%, 0.6)`,`hsla(42, 39%, 20%, 0.8)`,`hsla(42, 39%, 20%, 0.1)`,`hsla(42, 39%, 20%, 0.075)`,`hsla(42, 39%, 20%, 0.05)`,`hsla(42, 39%, 20%, 0.025)`,`hsla(42, 39%, 20%, 0.02)`,`hsla(42, 39%, 20%, 0.01)`,`hsla(54, 91%, 95%, 0.1)`,`hsla(54, 91%, 95%, 0.075)`,`hsla(54, 91%, 95%, 0.05)`,`hsla(54, 91%, 95%, 0.025)`,`hsla(54, 91%, 95%, 0.02)`,`hsla(54, 91%, 95%, 0.01)`,`hsla(48, 85%, 68%, 0.6)`,`hsla(140, 60%, 99%, 0)`,`hsla(137, 47%, 97%, 0.2)`,`hsla(137, 47%, 97%, 0.4)`,`hsla(137, 47%, 97%, 0.6)`,`hsla(137, 47%, 97%, 0.8)`,`hsla(140, 60%, 99%, 1)`,`hsla(137, 47%, 97%, 1)`,`hsla(139, 47%, 93%, 1)`,`hsla(140, 49%, 89%, 1)`,`hsla(142, 44%, 84%, 1)`,`hsla(144, 41%, 77%, 1)`,`hsla(146, 40%, 68%, 1)`,`hsla(151, 40%, 54%, 1)`,`hsla(151, 55%, 42%, 1)`,`hsla(152, 56%, 39%, 1)`,`hsla(154, 60%, 32%, 1)`,`hsla(155, 40%, 16%, 1)`,`hsla(156, 41%, 16%, 0)`,`hsla(156, 41%, 16%, 0.2)`,`hsla(156, 41%, 16%, 0.4)`,`hsla(156, 41%, 16%, 0.6)`,`hsla(156, 41%, 16%, 0.8)`,`hsla(156, 41%, 16%, 0.1)`,`hsla(156, 41%, 16%, 0.075)`,`hsla(156, 41%, 16%, 0.05)`,`hsla(156, 41%, 16%, 0.025)`,`hsla(156, 41%, 16%, 0.02)`,`hsla(156, 41%, 16%, 0.01)`,`hsla(137, 47%, 97%, 0.1)`,`hsla(137, 47%, 97%, 0.075)`,`hsla(137, 47%, 97%, 0.05)`,`hsla(137, 47%, 97%, 0.025)`,`hsla(137, 47%, 97%, 0.02)`,`hsla(137, 47%, 97%, 0.01)`,`hsla(144, 41%, 77%, 0.6)`,`hsla(20, 60%, 99%, 0)`,`hsla(33, 100%, 96%, 0.2)`,`hsla(33, 100%, 96%, 0.4)`,`hsla(33, 100%, 96%, 0.6)`,`hsla(33, 100%, 96%, 0.8)`,`hsla(20, 60%, 99%, 1)`,`hsla(33, 100%, 96%, 1)`,`hsla(37, 100%, 92%, 1)`,`hsla(34, 100%, 85%, 1)`,`hsla(33, 100%, 80%, 1)`,`hsla(30, 100%, 75%, 1)`,`hsla(27, 87%, 71%, 1)`,`hsla(25, 80%, 63%, 1)`,`hsla(23, 93%, 53%, 1)`,`hsla(24, 100%, 47%, 1)`,`hsla(23, 100%, 40%, 1)`,`hsla(16, 50%, 23%, 1)`,`hsla(16, 50%, 23%, 0)`,`hsla(16, 50%, 23%, 0.2)`,`hsla(16, 50%, 23%, 0.4)`,`hsla(16, 50%, 23%, 0.6)`,`hsla(16, 50%, 23%, 0.8)`,`hsla(16, 50%, 23%, 0.1)`,`hsla(16, 50%, 23%, 0.075)`,`hsla(16, 50%, 23%, 0.05)`,`hsla(16, 50%, 23%, 0.025)`,`hsla(16, 50%, 23%, 0.02)`,`hsla(16, 50%, 23%, 0.01)`,`hsla(33, 100%, 96%, 0.1)`,`hsla(33, 100%, 96%, 0.075)`,`hsla(33, 100%, 96%, 0.05)`,`hsla(33, 100%, 96%, 0.025)`,`hsla(33, 100%, 96%, 0.02)`,`hsla(33, 100%, 96%, 0.01)`,`hsla(30, 100%, 75%, 0.6)`,`hsla(324, 100%, 99%, 0)`,`hsla(326, 78%, 98%, 0.2)`,`hsla(326, 78%, 98%, 0.4)`,`hsla(326, 78%, 98%, 0.6)`,`hsla(326, 78%, 98%, 0.8)`,`hsla(320, 100%, 99%, 1)`,`hsla(326, 78%, 98%, 1)`,`hsla(326, 91%, 95%, 1)`,`hsla(323, 79%, 92%, 1)`,`hsla(323, 69%, 89%, 1)`,`hsla(323, 60%, 84%, 1)`,`hsla(323, 55%, 79%, 1)`,`hsla(322, 52%, 72%, 1)`,`hsla(322, 65%, 55%, 1)`,`hsla(322, 61%, 52%, 1)`,`hsla(322, 65%, 46%, 1)`,`hsla(320, 70%, 23%, 1)`,`hsla(320, 69%, 23%, 0)`,`hsla(320, 69%, 23%, 0.2)`,`hsla(320, 69%, 23%, 0.4)`,`hsla(320, 69%, 23%, 0.6)`,`hsla(320, 69%, 23%, 0.8)`,`hsla(320, 69%, 23%, 0.1)`,`hsla(320, 69%, 23%, 0.075)`,`hsla(320, 69%, 23%, 0.05)`,`hsla(320, 69%, 23%, 0.025)`,`hsla(320, 69%, 23%, 0.02)`,`hsla(320, 69%, 23%, 0.01)`,`hsla(326, 78%, 98%, 0.1)`,`hsla(326, 78%, 98%, 0.075)`,`hsla(326, 78%, 98%, 0.05)`,`hsla(326, 78%, 98%, 0.025)`,`hsla(326, 78%, 98%, 0.02)`,`hsla(326, 78%, 98%, 0.01)`,`hsla(323, 60%, 84%, 0.6)`,`hsla(300, 60%, 99%, 0)`,`hsla(274, 78%, 98%, 0.2)`,`hsla(274, 78%, 98%, 0.4)`,`hsla(274, 78%, 98%, 0.6)`,`hsla(274, 78%, 98%, 0.8)`,`hsla(300, 50%, 99%, 1)`,`hsla(274, 78%, 98%, 1)`,`hsla(275, 89%, 96%, 1)`,`hsla(277, 81%, 94%, 1)`,`hsla(275, 75%, 91%, 1)`,`hsla(275, 69%, 86%, 1)`,`hsla(273, 62%, 81%, 1)`,`hsla(272, 60%, 74%, 1)`,`hsla(272, 51%, 54%, 1)`,`hsla(272, 45%, 50%, 1)`,`hsla(272, 45%, 49%, 1)`,`hsla(270, 50%, 25%, 1)`,`hsla(270, 50%, 25%, 0)`,`hsla(270, 50%, 25%, 0.2)`,`hsla(270, 50%, 25%, 0.4)`,`hsla(270, 50%, 25%, 0.6)`,`hsla(270, 50%, 25%, 0.8)`,`hsla(270, 50%, 25%, 0.1)`,`hsla(270, 50%, 25%, 0.075)`,`hsla(270, 50%, 25%, 0.05)`,`hsla(270, 50%, 25%, 0.025)`,`hsla(270, 50%, 25%, 0.02)`,`hsla(270, 50%, 25%, 0.01)`,`hsla(274, 78%, 98%, 0.1)`,`hsla(274, 78%, 98%, 0.075)`,`hsla(274, 78%, 98%, 0.05)`,`hsla(274, 78%, 98%, 0.025)`,`hsla(274, 78%, 98%, 0.02)`,`hsla(274, 78%, 98%, 0.01)`,`hsla(275, 69%, 86%, 0.6)`,`hsla(160, 60%, 99%, 0)`,`hsla(165, 50%, 97%, 0.2)`,`hsla(165, 50%, 97%, 0.4)`,`hsla(165, 50%, 97%, 0.6)`,`hsla(165, 50%, 97%, 0.8)`,`hsla(165, 67%, 99%, 1)`,`hsla(165, 50%, 97%, 1)`,`hsla(167, 63%, 93%, 1)`,`hsla(166, 62%, 88%, 1)`,`hsla(168, 54%, 82%, 1)`,`hsla(168, 48%, 75%, 1)`,`hsla(170, 43%, 66%, 1)`,`hsla(172, 42%, 53%, 1)`,`hsla(173, 80%, 36%, 1)`,`hsla(173, 85%, 33%, 1)`,`hsla(172, 100%, 26%, 1)`,`hsla(174, 65%, 15%, 1)`,`hsla(174, 66%, 15%, 0)`,`hsla(174, 66%, 15%, 0.2)`,`hsla(174, 66%, 15%, 0.4)`,`hsla(174, 66%, 15%, 0.6)`,`hsla(174, 66%, 15%, 0.8)`,`hsla(174, 66%, 15%, 0.1)`,`hsla(174, 66%, 15%, 0.075)`,`hsla(174, 66%, 15%, 0.05)`,`hsla(174, 66%, 15%, 0.025)`,`hsla(174, 66%, 15%, 0.02)`,`hsla(174, 66%, 15%, 0.01)`,`hsla(165, 50%, 97%, 0.1)`,`hsla(165, 50%, 97%, 0.075)`,`hsla(165, 50%, 97%, 0.05)`,`hsla(165, 50%, 97%, 0.025)`,`hsla(165, 50%, 97%, 0.02)`,`hsla(165, 50%, 97%, 0.01)`,`hsla(168, 48%, 75%, 0.6)`,`hsla(0, 0%, 68%, 0)`,`hsla(0, 0%, 65%, 0.2)`,`hsla(0, 0%, 65%, 0.4)`,`hsla(0, 0%, 65%, 0.6)`,`hsla(0, 0%, 65%, 0.8)`,`hsla(0, 0%, 68%, 1)`,`hsla(0, 0%, 65%, 1)`,`hsla(0, 0%, 62%, 1)`,`hsla(0, 0%, 56%, 1)`,`hsla(0, 0%, 53%, 1)`,`hsla(0, 0%, 50%, 1)`,`hsla(0, 0%, 44%, 1)`,`hsla(0, 0%, 41%, 1)`,`hsla(0, 0%, 38%, 1)`,`hsla(0, 0%, 32%, 1)`,`hsla(0, 0%, 32%, 0)`,`hsla(0, 0%, 32%, 0.2)`,`hsla(0, 0%, 32%, 0.4)`,`hsla(0, 0%, 32%, 0.6)`,`hsla(0, 0%, 32%, 0.8)`,`hsla(0, 0%, 32%, 0.1)`,`hsla(0, 0%, 32%, 0.075)`,`hsla(0, 0%, 32%, 0.05)`,`hsla(0, 0%, 32%, 0.025)`,`hsla(0, 0%, 32%, 0.02)`,`hsla(0, 0%, 32%, 0.01)`,`hsla(0, 0%, 65%, 0.1)`,`hsla(0, 0%, 65%, 0.075)`,`hsla(0, 0%, 65%, 0.05)`,`hsla(0, 0%, 65%, 0.025)`,`hsla(0, 0%, 65%, 0.02)`,`hsla(0, 0%, 65%, 0.01)`,`hsla(0, 0%, 53%, 0.6)`,`hsla(0, 0%, 7%, 0)`,`hsla(0, 0%, 10%, 0.2)`,`hsla(0, 0%, 10%, 0.4)`,`hsla(0, 0%, 10%, 0.6)`,`hsla(0, 0%, 10%, 0.8)`,`hsla(0, 0%, 7%, 1)`,`hsla(0, 0%, 16%, 1)`,`hsla(0, 0%, 19%, 1)`,`hsla(0, 0%, 23%, 1)`,`hsla(0, 0%, 28%, 1)`,`hsla(0, 0%, 43%, 1)`,`hsla(0, 0%, 48%, 1)`,`hsla(0, 0%, 71%, 1)`,`hsla(0, 0%, 93%, 0)`,`hsla(0, 0%, 93%, 0.2)`,`hsla(0, 0%, 93%, 0.4)`,`hsla(0, 0%, 93%, 0.6)`,`hsla(0, 0%, 93%, 0.8)`,`hsla(0, 0%, 93%, 0.1)`,`hsla(0, 0%, 93%, 0.075)`,`hsla(0, 0%, 93%, 0.05)`,`hsla(0, 0%, 93%, 0.025)`,`hsla(0, 0%, 93%, 0.02)`,`hsla(0, 0%, 93%, 0.01)`,`hsla(0, 0%, 10%, 0.1)`,`hsla(0, 0%, 10%, 0.075)`,`hsla(0, 0%, 10%, 0.05)`,`hsla(0, 0%, 10%, 0.025)`,`hsla(0, 0%, 10%, 0.02)`,`hsla(0, 0%, 10%, 0.01)`,`hsla(0, 0%, 23%, 0.6)`,`hsla(216, 43%, 9%, 0)`,`hsla(218, 39%, 11%, 0.2)`,`hsla(218, 39%, 11%, 0.4)`,`hsla(218, 39%, 11%, 0.6)`,`hsla(218, 39%, 11%, 0.8)`,`hsla(215, 42%, 9%, 1)`,`hsla(218, 39%, 11%, 1)`,`hsla(212, 69%, 16%, 1)`,`hsla(209, 100%, 19%, 1)`,`hsla(207, 100%, 23%, 1)`,`hsla(209, 79%, 30%, 1)`,`hsla(211, 66%, 37%, 1)`,`hsla(211, 65%, 45%, 1)`,`hsla(210, 100%, 62%, 1)`,`hsla(210, 100%, 72%, 1)`,`hsla(205, 100%, 88%, 1)`,`hsla(205, 100%, 88%, 0)`,`hsla(205, 100%, 88%, 0.2)`,`hsla(205, 100%, 88%, 0.4)`,`hsla(205, 100%, 88%, 0.6)`,`hsla(205, 100%, 88%, 0.8)`,`hsla(205, 100%, 88%, 0.1)`,`hsla(205, 100%, 88%, 0.075)`,`hsla(205, 100%, 88%, 0.05)`,`hsla(205, 100%, 88%, 0.025)`,`hsla(205, 100%, 88%, 0.02)`,`hsla(205, 100%, 88%, 0.01)`,`hsla(218, 39%, 11%, 0.1)`,`hsla(218, 39%, 11%, 0.075)`,`hsla(218, 39%, 11%, 0.05)`,`hsla(218, 39%, 11%, 0.025)`,`hsla(218, 39%, 11%, 0.02)`,`hsla(218, 39%, 11%, 0.01)`,`hsla(209, 79%, 30%, 0.6)`,`hsla(0, 17%, 8%, 0)`,`hsla(355, 25%, 10%, 0.2)`,`hsla(355, 25%, 10%, 0.4)`,`hsla(355, 25%, 10%, 0.6)`,`hsla(355, 25%, 10%, 0.8)`,`hsla(0, 19%, 8%, 1)`,`hsla(355, 25%, 10%, 1)`,`hsla(350, 53%, 15%, 1)`,`hsla(348, 68%, 19%, 1)`,`hsla(350, 63%, 23%, 1)`,`hsla(352, 53%, 29%, 1)`,`hsla(355, 47%, 37%, 1)`,`hsla(358, 45%, 49%, 1)`,`hsla(360, 79%, 65%, 1)`,`hsla(2, 100%, 79%, 1)`,`hsla(350, 100%, 91%, 1)`,`hsla(350, 100%, 91%, 0)`,`hsla(350, 100%, 91%, 0.2)`,`hsla(350, 100%, 91%, 0.4)`,`hsla(350, 100%, 91%, 0.6)`,`hsla(350, 100%, 91%, 0.8)`,`hsla(350, 100%, 91%, 0.1)`,`hsla(350, 100%, 91%, 0.075)`,`hsla(350, 100%, 91%, 0.05)`,`hsla(350, 100%, 91%, 0.025)`,`hsla(350, 100%, 91%, 0.02)`,`hsla(350, 100%, 91%, 0.01)`,`hsla(355, 25%, 10%, 0.1)`,`hsla(355, 25%, 10%, 0.075)`,`hsla(355, 25%, 10%, 0.05)`,`hsla(355, 25%, 10%, 0.025)`,`hsla(355, 25%, 10%, 0.02)`,`hsla(355, 25%, 10%, 0.01)`,`hsla(352, 53%, 29%, 0.6)`,`hsla(47, 29%, 6%, 0)`,`hsla(45, 29%, 8%, 0.2)`,`hsla(45, 29%, 8%, 0.4)`,`hsla(45, 29%, 8%, 0.6)`,`hsla(45, 29%, 8%, 0.8)`,`hsla(47, 29%, 6%, 1)`,`hsla(45, 29%, 8%, 1)`,`hsla(45, 80%, 10%, 1)`,`hsla(48, 100%, 11%, 1)`,`hsla(47, 100%, 13%, 1)`,`hsla(48, 95%, 16%, 1)`,`hsla(46, 63%, 25%, 1)`,`hsla(45, 60%, 32%, 1)`,`hsla(60, 100%, 67%, 1)`,`hsla(53, 90%, 62%, 1)`,`hsla(53, 79%, 84%, 1)`,`hsla(53, 78%, 84%, 0)`,`hsla(53, 78%, 84%, 0.2)`,`hsla(53, 78%, 84%, 0.4)`,`hsla(53, 78%, 84%, 0.6)`,`hsla(53, 78%, 84%, 0.8)`,`hsla(53, 78%, 84%, 0.1)`,`hsla(53, 78%, 84%, 0.075)`,`hsla(53, 78%, 84%, 0.05)`,`hsla(53, 78%, 84%, 0.025)`,`hsla(53, 78%, 84%, 0.02)`,`hsla(53, 78%, 84%, 0.01)`,`hsla(45, 29%, 8%, 0.1)`,`hsla(45, 29%, 8%, 0.075)`,`hsla(45, 29%, 8%, 0.05)`,`hsla(45, 29%, 8%, 0.025)`,`hsla(45, 29%, 8%, 0.02)`,`hsla(45, 29%, 8%, 0.01)`,`hsla(48, 95%, 16%, 0.6)`,`hsla(154, 20%, 7%, 0)`,`hsla(153, 20%, 9%, 0.2)`,`hsla(153, 20%, 9%, 0.4)`,`hsla(153, 20%, 9%, 0.6)`,`hsla(153, 20%, 9%, 0.8)`,`hsla(154, 20%, 7%, 1)`,`hsla(153, 20%, 9%, 1)`,`hsla(152, 41%, 13%, 1)`,`hsla(154, 55%, 15%, 1)`,`hsla(154, 52%, 19%, 1)`,`hsla(153, 46%, 23%, 1)`,`hsla(152, 44%, 28%, 1)`,`hsla(151, 45%, 34%, 1)`,`hsla(151, 55%, 45%, 1)`,`hsla(151, 65%, 54%, 1)`,`hsla(144, 70%, 82%, 1)`,`hsla(144, 70%, 82%, 0)`,`hsla(144, 70%, 82%, 0.2)`,`hsla(144, 70%, 82%, 0.4)`,`hsla(144, 70%, 82%, 0.6)`,`hsla(144, 70%, 82%, 0.8)`,`hsla(144, 70%, 82%, 0.1)`,`hsla(144, 70%, 82%, 0.075)`,`hsla(144, 70%, 82%, 0.05)`,`hsla(144, 70%, 82%, 0.025)`,`hsla(144, 70%, 82%, 0.02)`,`hsla(144, 70%, 82%, 0.01)`,`hsla(153, 20%, 9%, 0.1)`,`hsla(153, 20%, 9%, 0.075)`,`hsla(153, 20%, 9%, 0.05)`,`hsla(153, 20%, 9%, 0.025)`,`hsla(153, 20%, 9%, 0.02)`,`hsla(153, 20%, 9%, 0.01)`,`hsla(153, 46%, 23%, 0.6)`,`hsla(23, 22%, 7%, 0)`,`hsla(28, 33%, 9%, 0.2)`,`hsla(28, 33%, 9%, 0.4)`,`hsla(28, 33%, 9%, 0.6)`,`hsla(28, 33%, 9%, 0.8)`,`hsla(27, 24%, 7%, 1)`,`hsla(28, 33%, 9%, 1)`,`hsla(29, 65%, 12%, 1)`,`hsla(28, 100%, 14%, 1)`,`hsla(28, 100%, 17%, 1)`,`hsla(27, 79%, 22%, 1)`,`hsla(25, 63%, 30%, 1)`,`hsla(23, 60%, 40%, 1)`,`hsla(26, 100%, 56%, 1)`,`hsla(26, 100%, 67%, 1)`,`hsla(30, 100%, 88%, 1)`,`hsla(30, 100%, 88%, 0)`,`hsla(30, 100%, 88%, 0.2)`,`hsla(30, 100%, 88%, 0.4)`,`hsla(30, 100%, 88%, 0.6)`,`hsla(30, 100%, 88%, 0.8)`,`hsla(30, 100%, 88%, 0.1)`,`hsla(30, 100%, 88%, 0.075)`,`hsla(30, 100%, 88%, 0.05)`,`hsla(30, 100%, 88%, 0.025)`,`hsla(30, 100%, 88%, 0.02)`,`hsla(30, 100%, 88%, 0.01)`,`hsla(28, 33%, 9%, 0.1)`,`hsla(28, 33%, 9%, 0.075)`,`hsla(28, 33%, 9%, 0.05)`,`hsla(28, 33%, 9%, 0.025)`,`hsla(28, 33%, 9%, 0.02)`,`hsla(28, 33%, 9%, 0.01)`,`hsla(27, 79%, 22%, 0.6)`,`hsla(317, 17%, 8%, 0)`,`hsla(316, 29%, 10%, 0.2)`,`hsla(316, 29%, 10%, 0.4)`,`hsla(316, 29%, 10%, 0.6)`,`hsla(316, 29%, 10%, 0.8)`,`hsla(315, 19%, 8%, 1)`,`hsla(316, 29%, 10%, 1)`,`hsla(315, 41%, 15%, 1)`,`hsla(315, 58%, 19%, 1)`,`hsla(318, 52%, 23%, 1)`,`hsla(319, 44%, 29%, 1)`,`hsla(321, 40%, 37%, 1)`,`hsla(322, 40%, 47%, 1)`,`hsla(323, 68%, 59%, 1)`,`hsla(327, 100%, 78%, 1)`,`hsla(326, 92%, 91%, 1)`,`hsla(326, 91%, 91%, 0)`,`hsla(326, 91%, 91%, 0.2)`,`hsla(326, 91%, 91%, 0.4)`,`hsla(326, 91%, 91%, 0.6)`,`hsla(326, 91%, 91%, 0.8)`,`hsla(326, 91%, 91%, 0.1)`,`hsla(326, 91%, 91%, 0.075)`,`hsla(326, 91%, 91%, 0.05)`,`hsla(326, 91%, 91%, 0.025)`,`hsla(326, 91%, 91%, 0.02)`,`hsla(326, 91%, 91%, 0.01)`,`hsla(316, 29%, 10%, 0.1)`,`hsla(316, 29%, 10%, 0.075)`,`hsla(316, 29%, 10%, 0.05)`,`hsla(316, 29%, 10%, 0.025)`,`hsla(316, 29%, 10%, 0.02)`,`hsla(316, 29%, 10%, 0.01)`,`hsla(319, 44%, 29%, 0.6)`,`hsla(282, 22%, 9%, 0)`,`hsla(279, 25%, 11%, 0.2)`,`hsla(279, 25%, 11%, 0.4)`,`hsla(279, 25%, 11%, 0.6)`,`hsla(279, 25%, 11%, 0.8)`,`hsla(282, 23%, 9%, 1)`,`hsla(279, 25%, 11%, 1)`,`hsla(279, 36%, 17%, 1)`,`hsla(277, 39%, 22%, 1)`,`hsla(276, 38%, 26%, 1)`,`hsla(275, 35%, 31%, 1)`,`hsla(274, 33%, 38%, 1)`,`hsla(273, 33%, 50%, 1)`,`hsla(272, 55%, 59%, 1)`,`hsla(272, 100%, 81%, 1)`,`hsla(275, 77%, 92%, 1)`,`hsla(275, 76%, 92%, 0)`,`hsla(275, 76%, 92%, 0.2)`,`hsla(275, 76%, 92%, 0.4)`,`hsla(275, 76%, 92%, 0.6)`,`hsla(275, 76%, 92%, 0.8)`,`hsla(275, 76%, 92%, 0.1)`,`hsla(275, 76%, 92%, 0.075)`,`hsla(275, 76%, 92%, 0.05)`,`hsla(275, 76%, 92%, 0.025)`,`hsla(275, 76%, 92%, 0.02)`,`hsla(275, 76%, 92%, 0.01)`,`hsla(279, 25%, 11%, 0.1)`,`hsla(279, 25%, 11%, 0.075)`,`hsla(279, 25%, 11%, 0.05)`,`hsla(279, 25%, 11%, 0.025)`,`hsla(279, 25%, 11%, 0.02)`,`hsla(279, 25%, 11%, 0.01)`,`hsla(275, 35%, 31%, 0.6)`,`hsla(173, 22%, 7%, 0)`,`hsla(175, 24%, 9%, 0.2)`,`hsla(175, 24%, 9%, 0.4)`,`hsla(175, 24%, 9%, 0.6)`,`hsla(175, 24%, 9%, 0.8)`,`hsla(173, 24%, 7%, 1)`,`hsla(175, 24%, 9%, 1)`,`hsla(174, 55%, 11%, 1)`,`hsla(176, 93%, 12%, 1)`,`hsla(175, 80%, 16%, 1)`,`hsla(174, 63%, 21%, 1)`,`hsla(174, 58%, 26%, 1)`,`hsla(173, 59%, 31%, 1)`,`hsla(172, 85%, 38%, 1)`,`hsla(170, 90%, 45%, 1)`,`hsla(163, 69%, 81%, 1)`,`hsla(163, 69%, 81%, 0)`,`hsla(163, 69%, 81%, 0.2)`,`hsla(163, 69%, 81%, 0.4)`,`hsla(163, 69%, 81%, 0.6)`,`hsla(163, 69%, 81%, 0.8)`,`hsla(163, 69%, 81%, 0.1)`,`hsla(163, 69%, 81%, 0.075)`,`hsla(163, 69%, 81%, 0.05)`,`hsla(163, 69%, 81%, 0.025)`,`hsla(163, 69%, 81%, 0.02)`,`hsla(163, 69%, 81%, 0.01)`,`hsla(175, 24%, 9%, 0.1)`,`hsla(175, 24%, 9%, 0.075)`,`hsla(175, 24%, 9%, 0.05)`,`hsla(175, 24%, 9%, 0.025)`,`hsla(175, 24%, 9%, 0.02)`,`hsla(175, 24%, 9%, 0.01)`,`hsla(174, 63%, 21%, 0.6)`,`hsla(0, 0%, 4%, 0.2)`,`hsla(0, 0%, 4%, 0.4)`,`hsla(0, 0%, 4%, 0.6)`,`hsla(0, 0%, 4%, 0.8)`,`hsla(0, 0%, 99%, 0.2)`,`hsla(0, 0%, 99%, 0.4)`,`hsla(0, 0%, 99%, 0.6)`,`hsla(0, 0%, 99%, 0.8)`,`hsla(216, 100%, 99%, 0.2)`,`hsla(216, 100%, 99%, 0.4)`,`hsla(216, 100%, 99%, 0.6)`,`hsla(216, 100%, 99%, 0.8)`,`hsla(0, 100%, 99%, 0.2)`,`hsla(0, 100%, 99%, 0.4)`,`hsla(0, 100%, 99%, 0.6)`,`hsla(0, 100%, 99%, 0.8)`,`hsla(60, 45%, 98%, 0.2)`,`hsla(60, 45%, 98%, 0.4)`,`hsla(60, 45%, 98%, 0.6)`,`hsla(60, 45%, 98%, 0.8)`,`hsla(140, 60%, 99%, 0.2)`,`hsla(140, 60%, 99%, 0.4)`,`hsla(140, 60%, 99%, 0.6)`,`hsla(140, 60%, 99%, 0.8)`,`hsla(20, 60%, 99%, 0.2)`,`hsla(20, 60%, 99%, 0.4)`,`hsla(20, 60%, 99%, 0.6)`,`hsla(20, 60%, 99%, 0.8)`,`hsla(324, 100%, 99%, 0.2)`,`hsla(324, 100%, 99%, 0.4)`,`hsla(324, 100%, 99%, 0.6)`,`hsla(324, 100%, 99%, 0.8)`,`hsla(300, 60%, 99%, 0.2)`,`hsla(300, 60%, 99%, 0.4)`,`hsla(300, 60%, 99%, 0.6)`,`hsla(300, 60%, 99%, 0.8)`,`hsla(160, 60%, 99%, 0.2)`,`hsla(160, 60%, 99%, 0.4)`,`hsla(160, 60%, 99%, 0.6)`,`hsla(160, 60%, 99%, 0.8)`,`hsla(0, 0%, 68%, 0.2)`,`hsla(0, 0%, 68%, 0.4)`,`hsla(0, 0%, 68%, 0.6)`,`hsla(0, 0%, 68%, 0.8)`,`hsla(0, 0%, 7%, 0.2)`,`hsla(0, 0%, 7%, 0.4)`,`hsla(0, 0%, 7%, 0.6)`,`hsla(0, 0%, 7%, 0.8)`,`hsla(216, 43%, 9%, 0.2)`,`hsla(216, 43%, 9%, 0.4)`,`hsla(216, 43%, 9%, 0.6)`,`hsla(216, 43%, 9%, 0.8)`,`hsla(0, 17%, 8%, 0.2)`,`hsla(0, 17%, 8%, 0.4)`,`hsla(0, 17%, 8%, 0.6)`,`hsla(0, 17%, 8%, 0.8)`,`hsla(47, 29%, 6%, 0.2)`,`hsla(47, 29%, 6%, 0.4)`,`hsla(47, 29%, 6%, 0.6)`,`hsla(47, 29%, 6%, 0.8)`,`hsla(154, 20%, 7%, 0.2)`,`hsla(154, 20%, 7%, 0.4)`,`hsla(154, 20%, 7%, 0.6)`,`hsla(154, 20%, 7%, 0.8)`,`hsla(23, 22%, 7%, 0.2)`,`hsla(23, 22%, 7%, 0.4)`,`hsla(23, 22%, 7%, 0.6)`,`hsla(23, 22%, 7%, 0.8)`,`hsla(317, 17%, 8%, 0.2)`,`hsla(317, 17%, 8%, 0.4)`,`hsla(317, 17%, 8%, 0.6)`,`hsla(317, 17%, 8%, 0.8)`,`hsla(282, 22%, 9%, 0.2)`,`hsla(282, 22%, 9%, 0.4)`,`hsla(282, 22%, 9%, 0.6)`,`hsla(282, 22%, 9%, 0.8)`,`hsla(173, 22%, 7%, 0.2)`,`hsla(173, 22%, 7%, 0.4)`,`hsla(173, 22%, 7%, 0.6)`,`hsla(173, 22%, 7%, 0.8)`],aee=`accentBackground.accentColor.background0.background02.background04.background06.background08.color1.color2.color3.color4.color5.color6.color7.color8.color9.color10.color11.color12.color0.color02.color04.color06.color08.color.colorHover.colorPress.colorFocus.background.backgroundHover.backgroundPress.backgroundFocus.backgroundActive.borderColor.borderColorHover.borderColorFocus.borderColorPress.placeholderColor.colorTransparent.black1.black2.black3.black4.black5.black6.black7.black8.black9.black10.black11.black12.white1.white2.white3.white4.white5.white6.white7.white8.white9.white10.white11.white12.white.white0.white02.white04.white06.white08.black.black0.black02.black04.black06.black08.shadow1.shadow2.shadow3.shadow4.shadow5.shadow6.shadow7.shadow8.highlight1.highlight2.highlight3.highlight4.highlight5.highlight6.highlight7.highlight8.shadowColor.gray1.gray2.gray3.gray4.gray5.gray6.gray7.gray8.gray9.gray10.gray11.gray12.blue1.blue2.blue3.blue4.blue5.blue6.blue7.blue8.blue9.blue10.blue11.blue12.red1.red2.red3.red4.red5.red6.red7.red8.red9.red10.red11.red12.yellow1.yellow2.yellow3.yellow4.yellow5.yellow6.yellow7.yellow8.yellow9.yellow10.yellow11.yellow12.green1.green2.green3.green4.green5.green6.green7.green8.green9.green10.green11.green12.orange1.orange2.orange3.orange4.orange5.orange6.orange7.orange8.orange9.orange10.orange11.orange12.pink1.pink2.pink3.pink4.pink5.pink6.pink7.pink8.pink9.pink10.pink11.pink12.purple1.purple2.purple3.purple4.purple5.purple6.purple7.purple8.purple9.purple10.purple11.purple12.teal1.teal2.teal3.teal4.teal5.teal6.teal7.teal8.teal9.teal10.teal11.teal12.neutral1.neutral2.neutral3.neutral4.neutral5.neutral6.neutral7.neutral8.neutral9.neutral10.neutral11.neutral12.accent1.accent2.accent3.accent4.accent5.accent6.accent7.accent8.accent9.accent10.accent11.accent12.color01.color0075.color005.color0025.color002.color001.background01.background0075.background005.background0025.background002.background001.outlineColor`.split(`.`),oee=G([[0,0],[1,1],[2,2],[3,3],[4,4],[5,5],[6,6],[7,7],[8,8],[9,9],[10,10],[11,11],[12,12],[13,13],[14,14],[15,15],[16,16],[17,17],[18,18],[19,19],[20,20],[21,21],[22,22],[23,23],[24,18],[25,18],[26,18],[27,23],[28,8],[29,7],[30,9],[31,9],[32,8],[33,10],[34,9],[35,10],[36,11],[37,15],[38,19],[39,24],[40,25],[41,26],[42,27],[43,28],[44,29],[45,30],[46,31],[47,32],[48,33],[49,34],[50,35],[51,36],[52,37],[53,38],[54,39],[55,40],[56,41],[57,42],[58,43],[59,44],[60,45],[61,46],[62,47],[63,48],[64,49],[65,50],[66,51],[67,52],[68,53],[69,54],[70,55],[71,56],[72,57],[73,58],[74,59],[75,60],[76,61],[77,62],[78,63],[79,64],[80,65],[81,58],[82,66],[83,67],[84,68],[85,69],[86,70],[87,51],[88,71],[89,72],[90,73],[91,62],[92,74],[93,75],[94,76],[95,77],[96,78],[97,79],[98,80],[99,81],[100,82],[101,83],[102,84],[103,85],[104,86],[105,87],[106,88],[107,89],[108,90],[109,91],[110,92],[111,93],[112,94],[113,95],[114,96],[115,97],[116,98],[117,99],[118,100],[119,101],[120,102],[121,103],[122,104],[123,105],[124,106],[125,107],[126,108],[127,109],[128,110],[129,111],[130,112],[131,113],[132,114],[133,115],[134,116],[135,117],[136,118],[137,119],[138,120],[139,121],[140,122],[141,123],[142,124],[143,125],[144,126],[145,127],[146,128],[147,129],[148,130],[149,131],[150,132],[151,133],[152,134],[153,135],[154,136],[155,137],[156,138],[157,139],[158,140],[159,141],[160,142],[161,143],[162,144],[163,145],[164,146],[165,147],[166,148],[167,149],[168,150],[169,151],[170,152],[171,153],[172,154],[173,155],[174,156],[175,157],[176,158],[177,159],[178,160],[179,161],[180,162],[181,163],[182,164],[183,165],[184,166],[185,167],[186,168],[187,169],[188,170],[189,171],[190,172],[191,173],[192,174],[193,175],[194,176],[195,177],[196,178],[197,179],[198,180],[199,181],[200,182],[201,183],[202,184],[203,42],[204,185],[205,186],[206,187],[207,188],[208,189],[209,190],[210,191],[211,192],[212,193],[213,194],[214,0],[215,17],[216,16],[217,195],[218,196],[219,197],[220,198],[221,1],[222,11],[223,7],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),see=G([[0,16],[1,9],[2,212],[3,213],[4,214],[5,215],[6,216],[7,193],[8,194],[9,0],[10,17],[11,16],[12,195],[13,196],[14,197],[15,198],[16,1],[17,11],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,220],[26,7],[27,11],[28,194],[29,0],[30,193],[31,0],[32,194],[33,17],[34,16],[35,17],[36,0],[37,198],[38,2],[39,24],[40,25],[41,26],[42,27],[43,28],[44,29],[45,30],[46,31],[47,32],[48,33],[49,34],[50,35],[51,36],[52,37],[53,38],[54,39],[55,40],[56,41],[57,42],[58,43],[59,44],[60,45],[61,46],[62,47],[63,48],[64,49],[65,50],[66,51],[67,52],[68,53],[69,54],[70,55],[71,56],[72,57],[73,58],[74,59],[75,221],[76,222],[77,64],[78,223],[79,224],[80,59],[81,225],[82,54],[83,68],[84,50],[85,70],[86,226],[87,227],[88,73],[89,228],[90,48],[91,64],[92,229],[93,26],[94,230],[95,231],[96,232],[97,233],[98,234],[99,235],[100,236],[101,237],[102,238],[103,239],[104,240],[105,241],[106,242],[107,243],[108,244],[109,245],[110,246],[111,247],[112,94],[113,248],[114,249],[115,250],[116,251],[117,252],[118,253],[119,254],[120,255],[121,256],[122,257],[123,258],[124,106],[125,259],[126,260],[127,261],[128,262],[129,263],[130,264],[131,265],[132,266],[133,267],[134,268],[135,269],[136,118],[137,270],[138,271],[139,272],[140,273],[141,274],[142,275],[143,276],[144,277],[145,278],[146,279],[147,280],[148,130],[149,281],[150,282],[151,283],[152,284],[153,285],[154,286],[155,287],[156,288],[157,289],[158,290],[159,291],[160,142],[161,292],[162,293],[163,294],[164,295],[165,296],[166,297],[167,298],[168,299],[169,300],[170,301],[171,302],[172,154],[173,303],[174,304],[175,305],[176,306],[177,307],[178,308],[179,309],[180,310],[181,311],[182,312],[183,313],[184,166],[185,314],[186,315],[187,316],[188,317],[189,318],[190,319],[191,320],[192,321],[193,322],[194,323],[195,324],[196,178],[197,325],[198,326],[199,327],[200,182],[201,183],[202,184],[203,42],[204,185],[205,186],[206,187],[207,188],[208,189],[209,190],[210,191],[211,192],[212,7],[213,8],[214,9],[215,10],[216,11],[217,12],[218,13],[219,14],[220,15],[221,16],[222,17],[223,18],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),cee=G([[0,9],[1,16],[2,212],[3,213],[4,214],[5,215],[6,216],[7,193],[8,194],[9,0],[10,17],[11,16],[12,195],[13,196],[14,197],[15,198],[16,1],[17,11],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,7],[26,7],[27,220],[28,194],[29,193],[30,0],[31,0],[32,194],[33,17],[34,0],[35,17],[36,16],[37,198],[38,2],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),lee=G([[0,1],[1,0],[2,2],[3,3],[4,4],[5,5],[6,6],[7,7],[8,8],[9,9],[10,10],[11,11],[12,12],[13,13],[14,14],[15,15],[16,16],[17,17],[18,18],[19,19],[20,20],[21,21],[22,22],[23,23],[24,18],[25,23],[26,18],[27,17],[28,8],[29,9],[30,7],[31,9],[32,8],[33,10],[34,11],[35,10],[36,9],[37,15],[38,19],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),uee=G([[0,0],[1,1],[2,212],[3,213],[4,214],[5,215],[6,216],[7,193],[8,194],[9,0],[10,17],[11,16],[12,195],[13,196],[14,197],[15,198],[16,1],[17,11],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,7],[26,7],[27,220],[28,194],[29,193],[30,0],[31,0],[32,194],[33,17],[34,0],[35,17],[36,16],[37,198],[38,2],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),dee=G([[0,0],[1,1],[2,2],[3,3],[4,4],[5,5],[6,6],[7,7],[8,8],[9,9],[10,10],[11,11],[12,12],[13,13],[14,14],[15,15],[16,16],[17,17],[18,18],[19,19],[20,20],[21,21],[22,22],[23,23],[24,18],[25,18],[26,18],[27,23],[28,8],[29,7],[30,9],[31,9],[32,8],[33,10],[34,9],[35,10],[36,11],[37,15],[38,19],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),fee=G([[0,0],[1,1],[2,341],[3,342],[4,343],[5,344],[6,345],[7,346],[8,347],[9,348],[10,349],[11,350],[12,10],[13,351],[14,352],[15,353],[16,354],[17,355],[18,356],[19,357],[20,358],[21,359],[22,360],[23,361],[24,356],[25,356],[26,356],[27,361],[28,347],[29,346],[30,348],[31,348],[32,347],[33,349],[34,348],[35,349],[36,350],[37,353],[38,357],[224,362],[225,363],[226,364],[227,365],[228,366],[229,367],[230,368],[231,369],[232,370],[233,371],[234,372],[235,373],[236,374]]),pee=G([[0,0],[1,1],[2,375],[3,376],[4,377],[5,378],[6,379],[7,380],[8,381],[9,382],[10,383],[11,384],[12,385],[13,386],[14,387],[15,388],[16,389],[17,390],[18,391],[19,392],[20,393],[21,394],[22,395],[23,396],[24,391],[25,391],[26,391],[27,396],[28,381],[29,380],[30,382],[31,382],[32,381],[33,383],[34,382],[35,383],[36,384],[37,388],[38,392],[224,397],[225,398],[226,399],[227,400],[228,401],[229,402],[230,403],[231,404],[232,405],[233,406],[234,407],[235,408],[236,409]]),mee=G([[0,0],[1,1],[2,410],[3,411],[4,412],[5,413],[6,414],[7,415],[8,416],[9,417],[10,418],[11,419],[12,420],[13,421],[14,422],[15,423],[16,424],[17,425],[18,426],[19,427],[20,428],[21,429],[22,430],[23,431],[24,426],[25,426],[26,426],[27,431],[28,416],[29,415],[30,417],[31,417],[32,416],[33,418],[34,417],[35,418],[36,419],[37,423],[38,427],[224,432],[225,433],[226,434],[227,435],[228,436],[229,437],[230,438],[231,439],[232,440],[233,441],[234,442],[235,443],[236,444]]),hee=G([[0,0],[1,1],[2,445],[3,446],[4,447],[5,448],[6,449],[7,450],[8,451],[9,452],[10,453],[11,454],[12,455],[13,456],[14,457],[15,458],[16,459],[17,460],[18,461],[19,462],[20,463],[21,464],[22,465],[23,466],[24,461],[25,461],[26,461],[27,466],[28,451],[29,450],[30,452],[31,452],[32,451],[33,453],[34,452],[35,453],[36,454],[37,458],[38,462],[224,467],[225,468],[226,469],[227,470],[228,471],[229,472],[230,473],[231,474],[232,475],[233,476],[234,477],[235,478],[236,479]]),gee=G([[0,0],[1,1],[2,480],[3,481],[4,482],[5,483],[6,484],[7,485],[8,486],[9,487],[10,488],[11,489],[12,490],[13,491],[14,492],[15,493],[16,494],[17,495],[18,496],[19,497],[20,498],[21,499],[22,500],[23,501],[24,496],[25,496],[26,496],[27,501],[28,486],[29,485],[30,487],[31,487],[32,486],[33,488],[34,487],[35,488],[36,489],[37,493],[38,497],[224,502],[225,503],[226,504],[227,505],[228,506],[229,507],[230,508],[231,509],[232,510],[233,511],[234,512],[235,513],[236,514]]),_ee=G([[0,0],[1,1],[2,515],[3,516],[4,517],[5,518],[6,519],[7,520],[8,521],[9,522],[10,523],[11,524],[12,525],[13,526],[14,527],[15,528],[16,529],[17,530],[18,531],[19,532],[20,533],[21,534],[22,535],[23,536],[24,531],[25,531],[26,531],[27,536],[28,521],[29,520],[30,522],[31,522],[32,521],[33,523],[34,522],[35,523],[36,524],[37,528],[38,532],[224,537],[225,538],[226,539],[227,540],[228,541],[229,542],[230,543],[231,544],[232,545],[233,546],[234,547],[235,548],[236,549]]),vee=G([[0,0],[1,1],[2,550],[3,551],[4,552],[5,553],[6,554],[7,555],[8,556],[9,557],[10,558],[11,559],[12,560],[13,561],[14,562],[15,563],[16,564],[17,565],[18,566],[19,567],[20,568],[21,569],[22,570],[23,571],[24,566],[25,566],[26,566],[27,571],[28,556],[29,555],[30,557],[31,557],[32,556],[33,558],[34,557],[35,558],[36,559],[37,563],[38,567],[224,572],[225,573],[226,574],[227,575],[228,576],[229,577],[230,578],[231,579],[232,580],[233,581],[234,582],[235,583],[236,584]]),yee=G([[0,0],[1,1],[2,585],[3,586],[4,587],[5,588],[6,589],[7,590],[8,591],[9,592],[10,593],[11,594],[12,595],[13,596],[14,597],[15,598],[16,599],[17,600],[18,601],[19,602],[20,603],[21,604],[22,605],[23,606],[24,601],[25,601],[26,601],[27,606],[28,591],[29,590],[30,592],[31,592],[32,591],[33,593],[34,592],[35,593],[36,594],[37,598],[38,602],[224,607],[225,608],[226,609],[227,610],[228,611],[229,612],[230,613],[231,614],[232,615],[233,616],[234,617],[235,618],[236,619]]),bee=G([[0,0],[1,1],[2,620],[3,621],[4,622],[5,623],[6,624],[7,625],[8,626],[9,627],[10,628],[11,629],[12,630],[13,631],[14,632],[15,633],[16,634],[17,635],[18,636],[19,637],[20,638],[21,639],[22,640],[23,641],[24,636],[25,636],[26,636],[27,641],[28,626],[29,625],[30,627],[31,627],[32,626],[33,628],[34,627],[35,628],[36,629],[37,633],[38,637],[224,642],[225,643],[226,644],[227,645],[228,646],[229,647],[230,648],[231,649],[232,650],[233,651],[234,652],[235,653],[236,654]]),xee=G([[0,0],[1,1],[2,655],[3,656],[4,657],[5,658],[6,659],[7,660],[8,661],[9,662],[10,13],[11,663],[12,664],[13,665],[14,197],[15,666],[16,667],[17,668],[18,669],[19,670],[20,671],[21,672],[22,673],[23,674],[24,669],[25,669],[26,669],[27,674],[28,661],[29,660],[30,662],[31,662],[32,661],[33,13],[34,662],[35,13],[36,663],[37,666],[38,670],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[236,687]]),See=G([[0,16],[1,9],[2,212],[3,213],[4,214],[5,215],[6,216],[7,193],[8,194],[9,0],[10,17],[11,16],[12,195],[13,196],[14,197],[15,198],[16,1],[17,11],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,220],[26,7],[27,11],[28,194],[29,0],[30,193],[31,0],[32,194],[33,17],[34,16],[35,17],[36,0],[37,198],[38,2],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),Cee=G([[0,16],[1,9],[2,2],[3,3],[4,4],[5,5],[6,6],[7,7],[8,8],[9,9],[10,10],[11,11],[12,12],[13,13],[14,14],[15,15],[16,16],[17,17],[18,18],[19,19],[20,20],[21,21],[22,22],[23,23],[24,18],[25,23],[26,18],[27,17],[28,8],[29,9],[30,7],[31,9],[32,8],[33,10],[34,11],[35,10],[36,9],[37,15],[38,19],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),wee=G([[0,16],[1,9],[2,688],[3,689],[4,690],[5,691],[6,692],[7,693],[8,0],[9,356],[10,694],[11,695],[12,696],[13,697],[14,668],[15,698],[16,699],[17,700],[18,9],[19,701],[20,702],[21,703],[22,704],[23,705],[24,9],[25,705],[26,9],[27,700],[28,0],[29,356],[30,693],[31,356],[32,0],[33,694],[34,695],[35,694],[36,356],[37,698],[38,701],[224,706],[225,707],[226,708],[227,709],[228,710],[229,711],[230,712],[231,713],[232,714],[233,715],[234,716],[235,717],[236,718]]),Tee=G([[0,16],[1,9],[2,719],[3,720],[4,721],[5,722],[6,723],[7,724],[8,725],[9,726],[10,727],[11,728],[12,729],[13,730],[14,731],[15,388],[16,732],[17,733],[18,734],[19,735],[20,736],[21,737],[22,738],[23,739],[24,734],[25,739],[26,734],[27,733],[28,725],[29,726],[30,724],[31,726],[32,725],[33,727],[34,728],[35,727],[36,726],[37,388],[38,735],[224,740],[225,741],[226,742],[227,743],[228,744],[229,745],[230,746],[231,747],[232,748],[233,749],[234,750],[235,751],[236,752]]),Eee=G([[0,16],[1,9],[2,753],[3,754],[4,755],[5,756],[6,757],[7,758],[8,759],[9,760],[10,761],[11,762],[12,763],[13,764],[14,765],[15,423],[16,766],[17,767],[18,768],[19,769],[20,770],[21,771],[22,772],[23,773],[24,768],[25,773],[26,768],[27,767],[28,759],[29,760],[30,758],[31,760],[32,759],[33,761],[34,762],[35,761],[36,760],[37,423],[38,769],[224,774],[225,775],[226,776],[227,777],[228,778],[229,779],[230,780],[231,781],[232,782],[233,783],[234,784],[235,785],[236,786]]),Dee=G([[0,16],[1,9],[2,787],[3,788],[4,789],[5,790],[6,791],[7,792],[8,793],[9,794],[10,795],[11,796],[12,797],[13,798],[14,799],[15,458],[16,800],[17,801],[18,802],[19,803],[20,804],[21,805],[22,806],[23,807],[24,802],[25,807],[26,802],[27,801],[28,793],[29,794],[30,792],[31,794],[32,793],[33,795],[34,796],[35,795],[36,794],[37,458],[38,803],[224,808],[225,809],[226,810],[227,811],[228,812],[229,813],[230,814],[231,815],[232,816],[233,817],[234,818],[235,819],[236,820]]),Oee=G([[0,16],[1,9],[2,821],[3,822],[4,823],[5,824],[6,825],[7,826],[8,827],[9,828],[10,829],[11,830],[12,831],[13,832],[14,833],[15,493],[16,834],[17,835],[18,836],[19,837],[20,838],[21,839],[22,840],[23,841],[24,836],[25,841],[26,836],[27,835],[28,827],[29,828],[30,826],[31,828],[32,827],[33,829],[34,830],[35,829],[36,828],[37,493],[38,837],[224,842],[225,843],[226,844],[227,845],[228,846],[229,847],[230,848],[231,849],[232,850],[233,851],[234,852],[235,853],[236,854]]),kee=G([[0,16],[1,9],[2,855],[3,856],[4,857],[5,858],[6,859],[7,860],[8,861],[9,862],[10,863],[11,864],[12,865],[13,866],[14,867],[15,528],[16,868],[17,869],[18,870],[19,871],[20,872],[21,873],[22,874],[23,875],[24,870],[25,875],[26,870],[27,869],[28,861],[29,862],[30,860],[31,862],[32,861],[33,863],[34,864],[35,863],[36,862],[37,528],[38,871],[224,876],[225,877],[226,878],[227,879],[228,880],[229,881],[230,882],[231,883],[232,884],[233,885],[234,886],[235,887],[236,888]]),Aee=G([[0,16],[1,9],[2,889],[3,890],[4,891],[5,892],[6,893],[7,894],[8,895],[9,896],[10,897],[11,898],[12,899],[13,900],[14,901],[15,563],[16,902],[17,903],[18,904],[19,905],[20,906],[21,907],[22,908],[23,909],[24,904],[25,909],[26,904],[27,903],[28,895],[29,896],[30,894],[31,896],[32,895],[33,897],[34,898],[35,897],[36,896],[37,563],[38,905],[224,910],[225,911],[226,912],[227,913],[228,914],[229,915],[230,916],[231,917],[232,918],[233,919],[234,920],[235,921],[236,922]]),jee=G([[0,16],[1,9],[2,923],[3,924],[4,925],[5,926],[6,927],[7,928],[8,929],[9,930],[10,931],[11,932],[12,933],[13,934],[14,935],[15,598],[16,936],[17,937],[18,938],[19,939],[20,940],[21,941],[22,942],[23,943],[24,938],[25,943],[26,938],[27,937],[28,929],[29,930],[30,928],[31,930],[32,929],[33,931],[34,932],[35,931],[36,930],[37,598],[38,939],[224,944],[225,945],[226,946],[227,947],[228,948],[229,949],[230,950],[231,951],[232,952],[233,953],[234,954],[235,955],[236,956]]),Mee=G([[0,16],[1,9],[2,957],[3,958],[4,959],[5,960],[6,961],[7,962],[8,963],[9,964],[10,965],[11,966],[12,967],[13,968],[14,969],[15,633],[16,970],[17,971],[18,972],[19,973],[20,974],[21,975],[22,976],[23,977],[24,972],[25,977],[26,972],[27,971],[28,963],[29,964],[30,962],[31,964],[32,963],[33,965],[34,966],[35,965],[36,964],[37,633],[38,973],[224,978],[225,979],[226,980],[227,981],[228,982],[229,983],[230,984],[231,985],[232,986],[233,987],[234,988],[235,989],[236,990]]),Nee=G([[0,16],[1,9],[2,655],[3,656],[4,657],[5,658],[6,659],[7,660],[8,661],[9,662],[10,13],[11,663],[12,664],[13,665],[14,197],[15,666],[16,667],[17,668],[18,669],[19,670],[20,671],[21,672],[22,673],[23,674],[24,669],[25,674],[26,669],[27,668],[28,661],[29,662],[30,660],[31,662],[32,661],[33,13],[34,663],[35,13],[36,662],[37,666],[38,670],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[236,687]]),Ny=G([[24,17],[25,17],[26,17],[27,18],[28,9],[29,8],[30,10],[31,11],[32,9],[33,11],[34,10],[35,11],[36,12],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),Py=G([[24,17],[25,17],[26,17],[27,18],[28,10],[29,9],[30,11],[31,13],[32,10],[33,12],[34,11],[35,12],[36,13],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),Fy=G([[24,11],[25,7],[26,11],[27,1],[28,0],[29,17],[30,194],[31,16],[32,0],[33,16],[34,195],[35,16],[36,17],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),Iy=G([[24,11],[25,7],[26,11],[27,1],[28,17],[29,16],[30,0],[31,196],[32,17],[33,195],[34,196],[35,195],[36,16],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),Ly=G([[0,1],[1,0],[2,2],[3,213],[4,214],[5,215],[6,216],[7,7],[8,11],[9,1],[10,198],[11,197],[12,196],[13,195],[14,16],[15,17],[16,0],[17,194],[18,193],[19,212],[20,991],[21,992],[22,993],[23,994],[24,193],[25,193],[26,193],[27,994],[28,11],[29,7],[30,1],[31,1],[32,11],[33,198],[34,1],[35,198],[36,197],[37,17],[38,212],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),Ry=G([[24,11],[25,11],[26,11],[27,7],[28,0],[29,194],[30,17],[31,16],[32,0],[33,16],[34,17],[35,16],[36,195],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),zy=G([[24,11],[25,11],[26,11],[27,7],[28,17],[29,0],[30,16],[31,196],[32,17],[33,195],[34,16],[35,195],[36,196],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),By=G([[0,1],[1,0],[2,19],[3,3],[4,4],[5,5],[6,6],[7,18],[8,17],[9,16],[10,15],[11,14],[12,13],[13,12],[14,11],[15,10],[16,9],[17,8],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,7],[26,7],[27,220],[28,17],[29,18],[30,16],[31,16],[32,17],[33,15],[34,16],[35,15],[36,14],[37,10],[38,2],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),Vy=G([[0,1],[1,0],[2,357],[3,342],[4,343],[5,344],[6,345],[7,356],[8,355],[9,354],[10,353],[11,352],[12,351],[13,10],[14,350],[15,349],[16,348],[17,347],[18,346],[19,341],[20,995],[21,996],[22,997],[23,998],[24,346],[25,346],[26,346],[27,998],[28,355],[29,356],[30,354],[31,354],[32,355],[33,353],[34,354],[35,353],[36,352],[37,349],[38,341],[224,362],[225,363],[226,364],[227,365],[228,366],[229,367],[230,368],[231,369],[232,370],[233,371],[234,372],[235,373],[236,374]]),Hy=G([[24,355],[25,355],[26,355],[27,356],[28,348],[29,347],[30,349],[31,350],[32,348],[33,350],[34,349],[35,350],[36,10],[224,362],[225,363],[226,364],[227,365],[228,366],[229,367],[230,368],[231,369],[232,370],[233,371],[234,372],[235,373],[3,342],[4,343],[5,344],[6,345],[236,374]]),Uy=G([[24,355],[25,355],[26,355],[27,356],[28,349],[29,348],[30,350],[31,351],[32,349],[33,10],[34,350],[35,10],[36,351],[224,362],[225,363],[226,364],[227,365],[228,366],[229,367],[230,368],[231,369],[232,370],[233,371],[234,372],[235,373],[3,342],[4,343],[5,344],[6,345],[236,374]]),Wy=G([[0,1],[1,0],[2,392],[3,376],[4,377],[5,378],[6,379],[7,391],[8,390],[9,389],[10,388],[11,387],[12,386],[13,385],[14,384],[15,383],[16,382],[17,381],[18,380],[19,375],[20,999],[21,1e3],[22,1001],[23,1002],[24,380],[25,380],[26,380],[27,1002],[28,390],[29,391],[30,389],[31,389],[32,390],[33,388],[34,389],[35,388],[36,387],[37,383],[38,375],[224,397],[225,398],[226,399],[227,400],[228,401],[229,402],[230,403],[231,404],[232,405],[233,406],[234,407],[235,408],[236,409]]),Gy=G([[24,390],[25,390],[26,390],[27,391],[28,382],[29,381],[30,383],[31,384],[32,382],[33,384],[34,383],[35,384],[36,385],[224,397],[225,398],[226,399],[227,400],[228,401],[229,402],[230,403],[231,404],[232,405],[233,406],[234,407],[235,408],[3,376],[4,377],[5,378],[6,379],[236,409]]),Ky=G([[24,390],[25,390],[26,390],[27,391],[28,383],[29,382],[30,384],[31,386],[32,383],[33,385],[34,384],[35,385],[36,386],[224,397],[225,398],[226,399],[227,400],[228,401],[229,402],[230,403],[231,404],[232,405],[233,406],[234,407],[235,408],[3,376],[4,377],[5,378],[6,379],[236,409]]),qy=G([[0,1],[1,0],[2,427],[3,411],[4,412],[5,413],[6,414],[7,426],[8,425],[9,424],[10,423],[11,422],[12,421],[13,420],[14,419],[15,418],[16,417],[17,416],[18,415],[19,410],[20,1003],[21,1004],[22,1005],[23,1006],[24,415],[25,415],[26,415],[27,1006],[28,425],[29,426],[30,424],[31,424],[32,425],[33,423],[34,424],[35,423],[36,422],[37,418],[38,410],[224,432],[225,433],[226,434],[227,435],[228,436],[229,437],[230,438],[231,439],[232,440],[233,441],[234,442],[235,443],[236,444]]),Jy=G([[24,425],[25,425],[26,425],[27,426],[28,417],[29,416],[30,418],[31,419],[32,417],[33,419],[34,418],[35,419],[36,420],[224,432],[225,433],[226,434],[227,435],[228,436],[229,437],[230,438],[231,439],[232,440],[233,441],[234,442],[235,443],[3,411],[4,412],[5,413],[6,414],[236,444]]),Yy=G([[24,425],[25,425],[26,425],[27,426],[28,418],[29,417],[30,419],[31,421],[32,418],[33,420],[34,419],[35,420],[36,421],[224,432],[225,433],[226,434],[227,435],[228,436],[229,437],[230,438],[231,439],[232,440],[233,441],[234,442],[235,443],[3,411],[4,412],[5,413],[6,414],[236,444]]),Xy=G([[0,1],[1,0],[2,462],[3,446],[4,447],[5,448],[6,449],[7,461],[8,460],[9,459],[10,458],[11,457],[12,456],[13,455],[14,454],[15,453],[16,452],[17,451],[18,450],[19,445],[20,1007],[21,1008],[22,1009],[23,1010],[24,450],[25,450],[26,450],[27,1010],[28,460],[29,461],[30,459],[31,459],[32,460],[33,458],[34,459],[35,458],[36,457],[37,453],[38,445],[224,467],[225,468],[226,469],[227,470],[228,471],[229,472],[230,473],[231,474],[232,475],[233,476],[234,477],[235,478],[236,479]]),Zy=G([[24,460],[25,460],[26,460],[27,461],[28,452],[29,451],[30,453],[31,454],[32,452],[33,454],[34,453],[35,454],[36,455],[224,467],[225,468],[226,469],[227,470],[228,471],[229,472],[230,473],[231,474],[232,475],[233,476],[234,477],[235,478],[3,446],[4,447],[5,448],[6,449],[236,479]]),Qy=G([[24,460],[25,460],[26,460],[27,461],[28,453],[29,452],[30,454],[31,456],[32,453],[33,455],[34,454],[35,455],[36,456],[224,467],[225,468],[226,469],[227,470],[228,471],[229,472],[230,473],[231,474],[232,475],[233,476],[234,477],[235,478],[3,446],[4,447],[5,448],[6,449],[236,479]]),$y=G([[0,1],[1,0],[2,497],[3,481],[4,482],[5,483],[6,484],[7,496],[8,495],[9,494],[10,493],[11,492],[12,491],[13,490],[14,489],[15,488],[16,487],[17,486],[18,485],[19,480],[20,1011],[21,1012],[22,1013],[23,1014],[24,485],[25,485],[26,485],[27,1014],[28,495],[29,496],[30,494],[31,494],[32,495],[33,493],[34,494],[35,493],[36,492],[37,488],[38,480],[224,502],[225,503],[226,504],[227,505],[228,506],[229,507],[230,508],[231,509],[232,510],[233,511],[234,512],[235,513],[236,514]]),eb=G([[24,495],[25,495],[26,495],[27,496],[28,487],[29,486],[30,488],[31,489],[32,487],[33,489],[34,488],[35,489],[36,490],[224,502],[225,503],[226,504],[227,505],[228,506],[229,507],[230,508],[231,509],[232,510],[233,511],[234,512],[235,513],[3,481],[4,482],[5,483],[6,484],[236,514]]),tb=G([[24,495],[25,495],[26,495],[27,496],[28,488],[29,487],[30,489],[31,491],[32,488],[33,490],[34,489],[35,490],[36,491],[224,502],[225,503],[226,504],[227,505],[228,506],[229,507],[230,508],[231,509],[232,510],[233,511],[234,512],[235,513],[3,481],[4,482],[5,483],[6,484],[236,514]]),nb=G([[0,1],[1,0],[2,532],[3,516],[4,517],[5,518],[6,519],[7,531],[8,530],[9,529],[10,528],[11,527],[12,526],[13,525],[14,524],[15,523],[16,522],[17,521],[18,520],[19,515],[20,1015],[21,1016],[22,1017],[23,1018],[24,520],[25,520],[26,520],[27,1018],[28,530],[29,531],[30,529],[31,529],[32,530],[33,528],[34,529],[35,528],[36,527],[37,523],[38,515],[224,537],[225,538],[226,539],[227,540],[228,541],[229,542],[230,543],[231,544],[232,545],[233,546],[234,547],[235,548],[236,549]]),rb=G([[24,530],[25,530],[26,530],[27,531],[28,522],[29,521],[30,523],[31,524],[32,522],[33,524],[34,523],[35,524],[36,525],[224,537],[225,538],[226,539],[227,540],[228,541],[229,542],[230,543],[231,544],[232,545],[233,546],[234,547],[235,548],[3,516],[4,517],[5,518],[6,519],[236,549]]),ib=G([[24,530],[25,530],[26,530],[27,531],[28,523],[29,522],[30,524],[31,526],[32,523],[33,525],[34,524],[35,525],[36,526],[224,537],[225,538],[226,539],[227,540],[228,541],[229,542],[230,543],[231,544],[232,545],[233,546],[234,547],[235,548],[3,516],[4,517],[5,518],[6,519],[236,549]]),ab=G([[0,1],[1,0],[2,567],[3,551],[4,552],[5,553],[6,554],[7,566],[8,565],[9,564],[10,563],[11,562],[12,561],[13,560],[14,559],[15,558],[16,557],[17,556],[18,555],[19,550],[20,1019],[21,1020],[22,1021],[23,1022],[24,555],[25,555],[26,555],[27,1022],[28,565],[29,566],[30,564],[31,564],[32,565],[33,563],[34,564],[35,563],[36,562],[37,558],[38,550],[224,572],[225,573],[226,574],[227,575],[228,576],[229,577],[230,578],[231,579],[232,580],[233,581],[234,582],[235,583],[236,584]]),ob=G([[24,565],[25,565],[26,565],[27,566],[28,557],[29,556],[30,558],[31,559],[32,557],[33,559],[34,558],[35,559],[36,560],[224,572],[225,573],[226,574],[227,575],[228,576],[229,577],[230,578],[231,579],[232,580],[233,581],[234,582],[235,583],[3,551],[4,552],[5,553],[6,554],[236,584]]),sb=G([[24,565],[25,565],[26,565],[27,566],[28,558],[29,557],[30,559],[31,561],[32,558],[33,560],[34,559],[35,560],[36,561],[224,572],[225,573],[226,574],[227,575],[228,576],[229,577],[230,578],[231,579],[232,580],[233,581],[234,582],[235,583],[3,551],[4,552],[5,553],[6,554],[236,584]]),cb=G([[0,1],[1,0],[2,602],[3,586],[4,587],[5,588],[6,589],[7,601],[8,600],[9,599],[10,598],[11,597],[12,596],[13,595],[14,594],[15,593],[16,592],[17,591],[18,590],[19,585],[20,1023],[21,1024],[22,1025],[23,1026],[24,590],[25,590],[26,590],[27,1026],[28,600],[29,601],[30,599],[31,599],[32,600],[33,598],[34,599],[35,598],[36,597],[37,593],[38,585],[224,607],[225,608],[226,609],[227,610],[228,611],[229,612],[230,613],[231,614],[232,615],[233,616],[234,617],[235,618],[236,619]]),lb=G([[24,600],[25,600],[26,600],[27,601],[28,592],[29,591],[30,593],[31,594],[32,592],[33,594],[34,593],[35,594],[36,595],[224,607],[225,608],[226,609],[227,610],[228,611],[229,612],[230,613],[231,614],[232,615],[233,616],[234,617],[235,618],[3,586],[4,587],[5,588],[6,589],[236,619]]),ub=G([[24,600],[25,600],[26,600],[27,601],[28,593],[29,592],[30,594],[31,596],[32,593],[33,595],[34,594],[35,595],[36,596],[224,607],[225,608],[226,609],[227,610],[228,611],[229,612],[230,613],[231,614],[232,615],[233,616],[234,617],[235,618],[3,586],[4,587],[5,588],[6,589],[236,619]]),db=G([[0,1],[1,0],[2,637],[3,621],[4,622],[5,623],[6,624],[7,636],[8,635],[9,634],[10,633],[11,632],[12,631],[13,630],[14,629],[15,628],[16,627],[17,626],[18,625],[19,620],[20,1027],[21,1028],[22,1029],[23,1030],[24,625],[25,625],[26,625],[27,1030],[28,635],[29,636],[30,634],[31,634],[32,635],[33,633],[34,634],[35,633],[36,632],[37,628],[38,620],[224,642],[225,643],[226,644],[227,645],[228,646],[229,647],[230,648],[231,649],[232,650],[233,651],[234,652],[235,653],[236,654]]),fb=G([[24,635],[25,635],[26,635],[27,636],[28,627],[29,626],[30,628],[31,629],[32,627],[33,629],[34,628],[35,629],[36,630],[224,642],[225,643],[226,644],[227,645],[228,646],[229,647],[230,648],[231,649],[232,650],[233,651],[234,652],[235,653],[3,621],[4,622],[5,623],[6,624],[236,654]]),pb=G([[24,635],[25,635],[26,635],[27,636],[28,628],[29,627],[30,629],[31,631],[32,628],[33,630],[34,629],[35,630],[36,631],[224,642],[225,643],[226,644],[227,645],[228,646],[229,647],[230,648],[231,649],[232,650],[233,651],[234,652],[235,653],[3,621],[4,622],[5,623],[6,624],[236,654]]),mb=G([[0,1],[1,0],[2,670],[3,656],[4,657],[5,658],[6,659],[7,669],[8,668],[9,667],[10,666],[11,197],[12,665],[13,664],[14,663],[15,13],[16,662],[17,661],[18,660],[19,655],[20,1031],[21,1032],[22,1033],[23,1034],[24,660],[25,660],[26,660],[27,1034],[28,668],[29,669],[30,667],[31,667],[32,668],[33,666],[34,667],[35,666],[36,197],[37,13],[38,655],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[236,687]]),hb=G([[24,668],[25,668],[26,668],[27,669],[28,662],[29,661],[30,13],[31,663],[32,662],[33,663],[34,13],[35,663],[36,664],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),gb=G([[24,668],[25,668],[26,668],[27,669],[28,13],[29,662],[30,663],[31,665],[32,13],[33,664],[34,663],[35,664],[36,665],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),_b=G([[0,9],[1,16],[2,2],[3,213],[4,214],[5,215],[6,216],[7,7],[8,11],[9,1],[10,198],[11,197],[12,196],[13,195],[14,16],[15,17],[16,0],[17,194],[18,193],[19,212],[20,991],[21,992],[22,993],[23,994],[24,193],[25,994],[26,193],[27,194],[28,11],[29,1],[30,7],[31,1],[32,11],[33,198],[34,197],[35,198],[36,1],[37,17],[38,212],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[236,340]]),vb=G([[0,9],[1,16],[2,19],[3,3],[4,4],[5,5],[6,6],[7,18],[8,17],[9,16],[10,15],[11,14],[12,13],[13,12],[14,11],[15,10],[16,9],[17,8],[18,7],[19,2],[20,217],[21,218],[22,219],[23,220],[24,7],[25,220],[26,7],[27,8],[28,17],[29,16],[30,18],[31,16],[32,17],[33,15],[34,14],[35,15],[36,16],[37,10],[38,2],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[236,211]]),yb=G([[24,17],[25,18],[26,17],[27,16],[28,9],[29,10],[30,8],[31,11],[32,9],[33,11],[34,12],[35,11],[36,10],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),bb=G([[24,17],[25,18],[26,17],[27,16],[28,10],[29,11],[30,9],[31,13],[32,10],[33,12],[34,13],[35,12],[36,11],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),xb=G([[0,9],[1,16],[2,701],[3,689],[4,690],[5,691],[6,692],[7,9],[8,700],[9,699],[10,698],[11,668],[12,697],[13,696],[14,695],[15,694],[16,356],[17,0],[18,693],[19,688],[20,1035],[21,1036],[22,1037],[23,1038],[24,693],[25,1038],[26,693],[27,0],[28,700],[29,699],[30,9],[31,699],[32,700],[33,698],[34,668],[35,698],[36,699],[37,694],[38,688],[224,706],[225,707],[226,708],[227,709],[228,710],[229,711],[230,712],[231,713],[232,714],[233,715],[234,716],[235,717],[236,718]]),Sb=G([[24,700],[25,9],[26,700],[27,699],[28,356],[29,694],[30,0],[31,695],[32,356],[33,695],[34,696],[35,695],[36,694],[224,706],[225,707],[226,708],[227,709],[228,710],[229,711],[230,712],[231,713],[232,714],[233,715],[234,716],[235,717],[3,689],[4,690],[5,691],[6,692],[236,718]]),Cb=G([[24,700],[25,9],[26,700],[27,699],[28,694],[29,695],[30,356],[31,697],[32,694],[33,696],[34,697],[35,696],[36,695],[224,706],[225,707],[226,708],[227,709],[228,710],[229,711],[230,712],[231,713],[232,714],[233,715],[234,716],[235,717],[3,689],[4,690],[5,691],[6,692],[236,718]]),wb=G([[0,9],[1,16],[2,735],[3,720],[4,721],[5,722],[6,723],[7,734],[8,733],[9,732],[10,388],[11,731],[12,730],[13,729],[14,728],[15,727],[16,726],[17,725],[18,724],[19,719],[20,1039],[21,1040],[22,1041],[23,1042],[24,724],[25,1042],[26,724],[27,725],[28,733],[29,732],[30,734],[31,732],[32,733],[33,388],[34,731],[35,388],[36,732],[37,727],[38,719],[224,740],[225,741],[226,742],[227,743],[228,744],[229,745],[230,746],[231,747],[232,748],[233,749],[234,750],[235,751],[236,752]]),Tb=G([[24,733],[25,734],[26,733],[27,732],[28,726],[29,727],[30,725],[31,728],[32,726],[33,728],[34,729],[35,728],[36,727],[224,740],[225,741],[226,742],[227,743],[228,744],[229,745],[230,746],[231,747],[232,748],[233,749],[234,750],[235,751],[3,720],[4,721],[5,722],[6,723],[236,752]]),Eb=G([[24,733],[25,734],[26,733],[27,732],[28,727],[29,728],[30,726],[31,730],[32,727],[33,729],[34,730],[35,729],[36,728],[224,740],[225,741],[226,742],[227,743],[228,744],[229,745],[230,746],[231,747],[232,748],[233,749],[234,750],[235,751],[3,720],[4,721],[5,722],[6,723],[236,752]]),Db=G([[0,9],[1,16],[2,769],[3,754],[4,755],[5,756],[6,757],[7,768],[8,767],[9,766],[10,423],[11,765],[12,764],[13,763],[14,762],[15,761],[16,760],[17,759],[18,758],[19,753],[20,1043],[21,1044],[22,1045],[23,1046],[24,758],[25,1046],[26,758],[27,759],[28,767],[29,766],[30,768],[31,766],[32,767],[33,423],[34,765],[35,423],[36,766],[37,761],[38,753],[224,774],[225,775],[226,776],[227,777],[228,778],[229,779],[230,780],[231,781],[232,782],[233,783],[234,784],[235,785],[236,786]]),Ob=G([[24,767],[25,768],[26,767],[27,766],[28,760],[29,761],[30,759],[31,762],[32,760],[33,762],[34,763],[35,762],[36,761],[224,774],[225,775],[226,776],[227,777],[228,778],[229,779],[230,780],[231,781],[232,782],[233,783],[234,784],[235,785],[3,754],[4,755],[5,756],[6,757],[236,786]]),kb=G([[24,767],[25,768],[26,767],[27,766],[28,761],[29,762],[30,760],[31,764],[32,761],[33,763],[34,764],[35,763],[36,762],[224,774],[225,775],[226,776],[227,777],[228,778],[229,779],[230,780],[231,781],[232,782],[233,783],[234,784],[235,785],[3,754],[4,755],[5,756],[6,757],[236,786]]),Ab=G([[0,9],[1,16],[2,803],[3,788],[4,789],[5,790],[6,791],[7,802],[8,801],[9,800],[10,458],[11,799],[12,798],[13,797],[14,796],[15,795],[16,794],[17,793],[18,792],[19,787],[20,1047],[21,1048],[22,1049],[23,1050],[24,792],[25,1050],[26,792],[27,793],[28,801],[29,800],[30,802],[31,800],[32,801],[33,458],[34,799],[35,458],[36,800],[37,795],[38,787],[224,808],[225,809],[226,810],[227,811],[228,812],[229,813],[230,814],[231,815],[232,816],[233,817],[234,818],[235,819],[236,820]]),jb=G([[24,801],[25,802],[26,801],[27,800],[28,794],[29,795],[30,793],[31,796],[32,794],[33,796],[34,797],[35,796],[36,795],[224,808],[225,809],[226,810],[227,811],[228,812],[229,813],[230,814],[231,815],[232,816],[233,817],[234,818],[235,819],[3,788],[4,789],[5,790],[6,791],[236,820]]),Mb=G([[24,801],[25,802],[26,801],[27,800],[28,795],[29,796],[30,794],[31,798],[32,795],[33,797],[34,798],[35,797],[36,796],[224,808],[225,809],[226,810],[227,811],[228,812],[229,813],[230,814],[231,815],[232,816],[233,817],[234,818],[235,819],[3,788],[4,789],[5,790],[6,791],[236,820]]),Nb=G([[0,9],[1,16],[2,837],[3,822],[4,823],[5,824],[6,825],[7,836],[8,835],[9,834],[10,493],[11,833],[12,832],[13,831],[14,830],[15,829],[16,828],[17,827],[18,826],[19,821],[20,1051],[21,1052],[22,1053],[23,1054],[24,826],[25,1054],[26,826],[27,827],[28,835],[29,834],[30,836],[31,834],[32,835],[33,493],[34,833],[35,493],[36,834],[37,829],[38,821],[224,842],[225,843],[226,844],[227,845],[228,846],[229,847],[230,848],[231,849],[232,850],[233,851],[234,852],[235,853],[236,854]]),Pb=G([[24,835],[25,836],[26,835],[27,834],[28,828],[29,829],[30,827],[31,830],[32,828],[33,830],[34,831],[35,830],[36,829],[224,842],[225,843],[226,844],[227,845],[228,846],[229,847],[230,848],[231,849],[232,850],[233,851],[234,852],[235,853],[3,822],[4,823],[5,824],[6,825],[236,854]]),Fb=G([[24,835],[25,836],[26,835],[27,834],[28,829],[29,830],[30,828],[31,832],[32,829],[33,831],[34,832],[35,831],[36,830],[224,842],[225,843],[226,844],[227,845],[228,846],[229,847],[230,848],[231,849],[232,850],[233,851],[234,852],[235,853],[3,822],[4,823],[5,824],[6,825],[236,854]]),Ib=G([[0,9],[1,16],[2,871],[3,856],[4,857],[5,858],[6,859],[7,870],[8,869],[9,868],[10,528],[11,867],[12,866],[13,865],[14,864],[15,863],[16,862],[17,861],[18,860],[19,855],[20,1055],[21,1056],[22,1057],[23,1058],[24,860],[25,1058],[26,860],[27,861],[28,869],[29,868],[30,870],[31,868],[32,869],[33,528],[34,867],[35,528],[36,868],[37,863],[38,855],[224,876],[225,877],[226,878],[227,879],[228,880],[229,881],[230,882],[231,883],[232,884],[233,885],[234,886],[235,887],[236,888]]),Lb=G([[24,869],[25,870],[26,869],[27,868],[28,862],[29,863],[30,861],[31,864],[32,862],[33,864],[34,865],[35,864],[36,863],[224,876],[225,877],[226,878],[227,879],[228,880],[229,881],[230,882],[231,883],[232,884],[233,885],[234,886],[235,887],[3,856],[4,857],[5,858],[6,859],[236,888]]),Rb=G([[24,869],[25,870],[26,869],[27,868],[28,863],[29,864],[30,862],[31,866],[32,863],[33,865],[34,866],[35,865],[36,864],[224,876],[225,877],[226,878],[227,879],[228,880],[229,881],[230,882],[231,883],[232,884],[233,885],[234,886],[235,887],[3,856],[4,857],[5,858],[6,859],[236,888]]),zb=G([[0,9],[1,16],[2,905],[3,890],[4,891],[5,892],[6,893],[7,904],[8,903],[9,902],[10,563],[11,901],[12,900],[13,899],[14,898],[15,897],[16,896],[17,895],[18,894],[19,889],[20,1059],[21,1060],[22,1061],[23,1062],[24,894],[25,1062],[26,894],[27,895],[28,903],[29,902],[30,904],[31,902],[32,903],[33,563],[34,901],[35,563],[36,902],[37,897],[38,889],[224,910],[225,911],[226,912],[227,913],[228,914],[229,915],[230,916],[231,917],[232,918],[233,919],[234,920],[235,921],[236,922]]),Bb=G([[24,903],[25,904],[26,903],[27,902],[28,896],[29,897],[30,895],[31,898],[32,896],[33,898],[34,899],[35,898],[36,897],[224,910],[225,911],[226,912],[227,913],[228,914],[229,915],[230,916],[231,917],[232,918],[233,919],[234,920],[235,921],[3,890],[4,891],[5,892],[6,893],[236,922]]),Vb=G([[24,903],[25,904],[26,903],[27,902],[28,897],[29,898],[30,896],[31,900],[32,897],[33,899],[34,900],[35,899],[36,898],[224,910],[225,911],[226,912],[227,913],[228,914],[229,915],[230,916],[231,917],[232,918],[233,919],[234,920],[235,921],[3,890],[4,891],[5,892],[6,893],[236,922]]),Hb=G([[0,9],[1,16],[2,939],[3,924],[4,925],[5,926],[6,927],[7,938],[8,937],[9,936],[10,598],[11,935],[12,934],[13,933],[14,932],[15,931],[16,930],[17,929],[18,928],[19,923],[20,1063],[21,1064],[22,1065],[23,1066],[24,928],[25,1066],[26,928],[27,929],[28,937],[29,936],[30,938],[31,936],[32,937],[33,598],[34,935],[35,598],[36,936],[37,931],[38,923],[224,944],[225,945],[226,946],[227,947],[228,948],[229,949],[230,950],[231,951],[232,952],[233,953],[234,954],[235,955],[236,956]]),Ub=G([[24,937],[25,938],[26,937],[27,936],[28,930],[29,931],[30,929],[31,932],[32,930],[33,932],[34,933],[35,932],[36,931],[224,944],[225,945],[226,946],[227,947],[228,948],[229,949],[230,950],[231,951],[232,952],[233,953],[234,954],[235,955],[3,924],[4,925],[5,926],[6,927],[236,956]]),Wb=G([[24,937],[25,938],[26,937],[27,936],[28,931],[29,932],[30,930],[31,934],[32,931],[33,933],[34,934],[35,933],[36,932],[224,944],[225,945],[226,946],[227,947],[228,948],[229,949],[230,950],[231,951],[232,952],[233,953],[234,954],[235,955],[3,924],[4,925],[5,926],[6,927],[236,956]]),Gb=G([[0,9],[1,16],[2,973],[3,958],[4,959],[5,960],[6,961],[7,972],[8,971],[9,970],[10,633],[11,969],[12,968],[13,967],[14,966],[15,965],[16,964],[17,963],[18,962],[19,957],[20,1067],[21,1068],[22,1069],[23,1070],[24,962],[25,1070],[26,962],[27,963],[28,971],[29,970],[30,972],[31,970],[32,971],[33,633],[34,969],[35,633],[36,970],[37,965],[38,957],[224,978],[225,979],[226,980],[227,981],[228,982],[229,983],[230,984],[231,985],[232,986],[233,987],[234,988],[235,989],[236,990]]),Kb=G([[24,971],[25,972],[26,971],[27,970],[28,964],[29,965],[30,963],[31,966],[32,964],[33,966],[34,967],[35,966],[36,965],[224,978],[225,979],[226,980],[227,981],[228,982],[229,983],[230,984],[231,985],[232,986],[233,987],[234,988],[235,989],[3,958],[4,959],[5,960],[6,961],[236,990]]),qb=G([[24,971],[25,972],[26,971],[27,970],[28,965],[29,966],[30,964],[31,968],[32,965],[33,967],[34,968],[35,967],[36,966],[224,978],[225,979],[226,980],[227,981],[228,982],[229,983],[230,984],[231,985],[232,986],[233,987],[234,988],[235,989],[3,958],[4,959],[5,960],[6,961],[236,990]]),Jb=G([[0,9],[1,16],[2,670],[3,656],[4,657],[5,658],[6,659],[7,669],[8,668],[9,667],[10,666],[11,197],[12,665],[13,664],[14,663],[15,13],[16,662],[17,661],[18,660],[19,655],[20,1031],[21,1032],[22,1033],[23,1034],[24,660],[25,1034],[26,660],[27,661],[28,668],[29,667],[30,669],[31,667],[32,668],[33,666],[34,197],[35,666],[36,667],[37,13],[38,655],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[236,687]]),Yb=G([[24,668],[25,669],[26,668],[27,667],[28,662],[29,13],[30,661],[31,663],[32,662],[33,663],[34,664],[35,663],[36,13],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),Xb=G([[24,668],[25,669],[26,668],[27,667],[28,13],[29,663],[30,662],[31,665],[32,13],[33,664],[34,665],[35,664],[36,663],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),Zb=G([[24,17],[25,17],[26,17],[27,18],[28,12],[29,11],[30,13],[31,17],[32,12],[33,14],[34,13],[35,14],[36,15],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),Qb=G([[24,11],[25,7],[26,11],[27,1],[28,195],[29,196],[30,16],[31,11],[32,195],[33,197],[34,198],[35,197],[36,196],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),$b=G([[24,11],[25,11],[26,11],[27,7],[28,195],[29,16],[30,196],[31,11],[32,195],[33,197],[34,196],[35,197],[36,198],[224,328],[225,329],[226,330],[227,331],[228,332],[229,333],[230,334],[231,335],[232,336],[233,337],[234,338],[235,339],[3,213],[4,214],[5,215],[6,216],[236,340]]),ex=G([[24,355],[25,355],[26,355],[27,356],[28,10],[29,350],[30,351],[31,355],[32,10],[33,352],[34,351],[35,352],[36,353],[224,362],[225,363],[226,364],[227,365],[228,366],[229,367],[230,368],[231,369],[232,370],[233,371],[234,372],[235,373],[3,342],[4,343],[5,344],[6,345],[236,374]]),tx=G([[24,390],[25,390],[26,390],[27,391],[28,385],[29,384],[30,386],[31,390],[32,385],[33,387],[34,386],[35,387],[36,388],[224,397],[225,398],[226,399],[227,400],[228,401],[229,402],[230,403],[231,404],[232,405],[233,406],[234,407],[235,408],[3,376],[4,377],[5,378],[6,379],[236,409]]),nx=G([[24,425],[25,425],[26,425],[27,426],[28,420],[29,419],[30,421],[31,425],[32,420],[33,422],[34,421],[35,422],[36,423],[224,432],[225,433],[226,434],[227,435],[228,436],[229,437],[230,438],[231,439],[232,440],[233,441],[234,442],[235,443],[3,411],[4,412],[5,413],[6,414],[236,444]]),rx=G([[24,460],[25,460],[26,460],[27,461],[28,455],[29,454],[30,456],[31,460],[32,455],[33,457],[34,456],[35,457],[36,458],[224,467],[225,468],[226,469],[227,470],[228,471],[229,472],[230,473],[231,474],[232,475],[233,476],[234,477],[235,478],[3,446],[4,447],[5,448],[6,449],[236,479]]),ix=G([[24,495],[25,495],[26,495],[27,496],[28,490],[29,489],[30,491],[31,495],[32,490],[33,492],[34,491],[35,492],[36,493],[224,502],[225,503],[226,504],[227,505],[228,506],[229,507],[230,508],[231,509],[232,510],[233,511],[234,512],[235,513],[3,481],[4,482],[5,483],[6,484],[236,514]]),ax=G([[24,530],[25,530],[26,530],[27,531],[28,525],[29,524],[30,526],[31,530],[32,525],[33,527],[34,526],[35,527],[36,528],[224,537],[225,538],[226,539],[227,540],[228,541],[229,542],[230,543],[231,544],[232,545],[233,546],[234,547],[235,548],[3,516],[4,517],[5,518],[6,519],[236,549]]),ox=G([[24,565],[25,565],[26,565],[27,566],[28,560],[29,559],[30,561],[31,565],[32,560],[33,562],[34,561],[35,562],[36,563],[224,572],[225,573],[226,574],[227,575],[228,576],[229,577],[230,578],[231,579],[232,580],[233,581],[234,582],[235,583],[3,551],[4,552],[5,553],[6,554],[236,584]]),sx=G([[24,600],[25,600],[26,600],[27,601],[28,595],[29,594],[30,596],[31,600],[32,595],[33,597],[34,596],[35,597],[36,598],[224,607],[225,608],[226,609],[227,610],[228,611],[229,612],[230,613],[231,614],[232,615],[233,616],[234,617],[235,618],[3,586],[4,587],[5,588],[6,589],[236,619]]),cx=G([[24,635],[25,635],[26,635],[27,636],[28,630],[29,629],[30,631],[31,635],[32,630],[33,632],[34,631],[35,632],[36,633],[224,642],[225,643],[226,644],[227,645],[228,646],[229,647],[230,648],[231,649],[232,650],[233,651],[234,652],[235,653],[3,621],[4,622],[5,623],[6,624],[236,654]]),lx=G([[24,668],[25,668],[26,668],[27,669],[28,664],[29,663],[30,665],[31,668],[32,664],[33,197],[34,665],[35,197],[36,666],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),ux=G([[24,17],[25,18],[26,17],[27,16],[28,12],[29,13],[30,11],[31,17],[32,12],[33,14],[34,15],[35,14],[36,13],[224,199],[225,200],[226,201],[227,202],[228,203],[229,204],[230,205],[231,206],[232,207],[233,208],[234,209],[235,210],[3,3],[4,4],[5,5],[6,6],[236,211]]),dx=G([[24,700],[25,9],[26,700],[27,699],[28,696],[29,697],[30,695],[31,700],[32,696],[33,668],[34,698],[35,668],[36,697],[224,706],[225,707],[226,708],[227,709],[228,710],[229,711],[230,712],[231,713],[232,714],[233,715],[234,716],[235,717],[3,689],[4,690],[5,691],[6,692],[236,718]]),fx=G([[24,733],[25,734],[26,733],[27,732],[28,729],[29,730],[30,728],[31,733],[32,729],[33,731],[34,388],[35,731],[36,730],[224,740],[225,741],[226,742],[227,743],[228,744],[229,745],[230,746],[231,747],[232,748],[233,749],[234,750],[235,751],[3,720],[4,721],[5,722],[6,723],[236,752]]),px=G([[24,767],[25,768],[26,767],[27,766],[28,763],[29,764],[30,762],[31,767],[32,763],[33,765],[34,423],[35,765],[36,764],[224,774],[225,775],[226,776],[227,777],[228,778],[229,779],[230,780],[231,781],[232,782],[233,783],[234,784],[235,785],[3,754],[4,755],[5,756],[6,757],[236,786]]),mx=G([[24,801],[25,802],[26,801],[27,800],[28,797],[29,798],[30,796],[31,801],[32,797],[33,799],[34,458],[35,799],[36,798],[224,808],[225,809],[226,810],[227,811],[228,812],[229,813],[230,814],[231,815],[232,816],[233,817],[234,818],[235,819],[3,788],[4,789],[5,790],[6,791],[236,820]]),hx=G([[24,835],[25,836],[26,835],[27,834],[28,831],[29,832],[30,830],[31,835],[32,831],[33,833],[34,493],[35,833],[36,832],[224,842],[225,843],[226,844],[227,845],[228,846],[229,847],[230,848],[231,849],[232,850],[233,851],[234,852],[235,853],[3,822],[4,823],[5,824],[6,825],[236,854]]),gx=G([[24,869],[25,870],[26,869],[27,868],[28,865],[29,866],[30,864],[31,869],[32,865],[33,867],[34,528],[35,867],[36,866],[224,876],[225,877],[226,878],[227,879],[228,880],[229,881],[230,882],[231,883],[232,884],[233,885],[234,886],[235,887],[3,856],[4,857],[5,858],[6,859],[236,888]]),_x=G([[24,903],[25,904],[26,903],[27,902],[28,899],[29,900],[30,898],[31,903],[32,899],[33,901],[34,563],[35,901],[36,900],[224,910],[225,911],[226,912],[227,913],[228,914],[229,915],[230,916],[231,917],[232,918],[233,919],[234,920],[235,921],[3,890],[4,891],[5,892],[6,893],[236,922]]),vx=G([[24,937],[25,938],[26,937],[27,936],[28,933],[29,934],[30,932],[31,937],[32,933],[33,935],[34,598],[35,935],[36,934],[224,944],[225,945],[226,946],[227,947],[228,948],[229,949],[230,950],[231,951],[232,952],[233,953],[234,954],[235,955],[3,924],[4,925],[5,926],[6,927],[236,956]]),yx=G([[24,971],[25,972],[26,971],[27,970],[28,967],[29,968],[30,966],[31,971],[32,967],[33,969],[34,633],[35,969],[36,968],[224,978],[225,979],[226,980],[227,981],[228,982],[229,983],[230,984],[231,985],[232,986],[233,987],[234,988],[235,989],[3,958],[4,959],[5,960],[6,961],[236,990]]),bx=G([[24,668],[25,669],[26,668],[27,667],[28,664],[29,665],[30,663],[31,668],[32,664],[33,197],[34,666],[35,197],[36,665],[224,675],[225,676],[226,677],[227,678],[228,679],[229,680],[230,681],[231,682],[232,683],[233,684],[234,685],[235,686],[3,656],[4,657],[5,658],[6,659],[236,687]]),xx={light:oee,dark:see,light_accent:cee,dark_accent:lee,light_black:uee,light_white:dee,light_gray:fee,light_blue:pee,light_red:mee,light_yellow:hee,light_green:gee,light_orange:_ee,light_pink:vee,light_purple:yee,light_teal:bee,light_neutral:xee,dark_black:See,dark_white:Cee,dark_gray:wee,dark_blue:Tee,dark_red:Eee,dark_yellow:Dee,dark_green:Oee,dark_orange:kee,dark_pink:Aee,dark_purple:jee,dark_teal:Mee,dark_neutral:Nee,light_surface1:Ny,light_white_surface1:Ny,light_Input:Ny,light_Progress:Ny,light_Slider:Ny,light_TextArea:Ny,light_white_Input:Ny,light_white_Progress:Ny,light_white_Slider:Ny,light_white_TextArea:Ny,light_surface2:Py,light_white_surface2:Py,light_Button:Py,light_SliderThumb:Py,light_Switch:Py,light_white_Button:Py,light_white_SliderThumb:Py,light_white_Switch:Py,dark_surface1:Fy,dark_black_surface1:Fy,dark_Input:Fy,dark_Progress:Fy,dark_Slider:Fy,dark_TextArea:Fy,dark_black_Input:Fy,dark_black_Progress:Fy,dark_black_Slider:Fy,dark_black_TextArea:Fy,dark_surface2:Iy,dark_black_surface2:Iy,dark_Button:Iy,dark_SliderThumb:Iy,dark_Switch:Iy,dark_black_Button:Iy,dark_black_SliderThumb:Iy,dark_black_Switch:Iy,light_black_accent:Ly,light_black_Tooltip:Ly,light_black_SwitchThumb:Ly,light_black_surface1:Ry,light_black_Input:Ry,light_black_Progress:Ry,light_black_Slider:Ry,light_black_TextArea:Ry,light_black_surface2:zy,light_black_Button:zy,light_black_SliderThumb:zy,light_black_Switch:zy,light_white_accent:By,light_Tooltip:By,light_SwitchThumb:By,light_white_Tooltip:By,light_white_SwitchThumb:By,light_gray_accent:Vy,light_gray_Tooltip:Vy,light_gray_SwitchThumb:Vy,light_gray_surface1:Hy,light_gray_Input:Hy,light_gray_Progress:Hy,light_gray_Slider:Hy,light_gray_TextArea:Hy,light_gray_surface2:Uy,light_gray_Button:Uy,light_gray_SliderThumb:Uy,light_gray_Switch:Uy,light_blue_accent:Wy,light_blue_Tooltip:Wy,light_blue_SwitchThumb:Wy,light_blue_surface1:Gy,light_blue_Input:Gy,light_blue_Progress:Gy,light_blue_Slider:Gy,light_blue_TextArea:Gy,light_blue_surface2:Ky,light_blue_Button:Ky,light_blue_SliderThumb:Ky,light_blue_Switch:Ky,light_red_accent:qy,light_red_Tooltip:qy,light_red_SwitchThumb:qy,light_red_surface1:Jy,light_red_Input:Jy,light_red_Progress:Jy,light_red_Slider:Jy,light_red_TextArea:Jy,light_red_surface2:Yy,light_red_Button:Yy,light_red_SliderThumb:Yy,light_red_Switch:Yy,light_yellow_accent:Xy,light_yellow_Tooltip:Xy,light_yellow_SwitchThumb:Xy,light_yellow_surface1:Zy,light_yellow_Input:Zy,light_yellow_Progress:Zy,light_yellow_Slider:Zy,light_yellow_TextArea:Zy,light_yellow_surface2:Qy,light_yellow_Button:Qy,light_yellow_SliderThumb:Qy,light_yellow_Switch:Qy,light_green_accent:$y,light_green_Tooltip:$y,light_green_SwitchThumb:$y,light_green_surface1:eb,light_green_Input:eb,light_green_Progress:eb,light_green_Slider:eb,light_green_TextArea:eb,light_green_surface2:tb,light_green_Button:tb,light_green_SliderThumb:tb,light_green_Switch:tb,light_orange_accent:nb,light_orange_Tooltip:nb,light_orange_SwitchThumb:nb,light_orange_surface1:rb,light_orange_Input:rb,light_orange_Progress:rb,light_orange_Slider:rb,light_orange_TextArea:rb,light_orange_surface2:ib,light_orange_Button:ib,light_orange_SliderThumb:ib,light_orange_Switch:ib,light_pink_accent:ab,light_pink_Tooltip:ab,light_pink_SwitchThumb:ab,light_pink_surface1:ob,light_pink_Input:ob,light_pink_Progress:ob,light_pink_Slider:ob,light_pink_TextArea:ob,light_pink_surface2:sb,light_pink_Button:sb,light_pink_SliderThumb:sb,light_pink_Switch:sb,light_purple_accent:cb,light_purple_Tooltip:cb,light_purple_SwitchThumb:cb,light_purple_surface1:lb,light_purple_Input:lb,light_purple_Progress:lb,light_purple_Slider:lb,light_purple_TextArea:lb,light_purple_surface2:ub,light_purple_Button:ub,light_purple_SliderThumb:ub,light_purple_Switch:ub,light_teal_accent:db,light_teal_Tooltip:db,light_teal_SwitchThumb:db,light_teal_surface1:fb,light_teal_Input:fb,light_teal_Progress:fb,light_teal_Slider:fb,light_teal_TextArea:fb,light_teal_surface2:pb,light_teal_Button:pb,light_teal_SliderThumb:pb,light_teal_Switch:pb,light_neutral_accent:mb,light_neutral_Tooltip:mb,light_neutral_SwitchThumb:mb,light_neutral_surface1:hb,light_neutral_Input:hb,light_neutral_Progress:hb,light_neutral_Slider:hb,light_neutral_TextArea:hb,light_neutral_surface2:gb,light_neutral_Button:gb,light_neutral_SliderThumb:gb,light_neutral_Switch:gb,dark_black_accent:_b,dark_Tooltip:_b,dark_SwitchThumb:_b,dark_black_Tooltip:_b,dark_black_SwitchThumb:_b,dark_white_accent:vb,dark_white_Tooltip:vb,dark_white_SwitchThumb:vb,dark_white_surface1:yb,dark_white_Input:yb,dark_white_Progress:yb,dark_white_Slider:yb,dark_white_TextArea:yb,dark_white_surface2:bb,dark_white_Button:bb,dark_white_SliderThumb:bb,dark_white_Switch:bb,dark_gray_accent:xb,dark_gray_Tooltip:xb,dark_gray_SwitchThumb:xb,dark_gray_surface1:Sb,dark_gray_Input:Sb,dark_gray_Progress:Sb,dark_gray_Slider:Sb,dark_gray_TextArea:Sb,dark_gray_surface2:Cb,dark_gray_Button:Cb,dark_gray_SliderThumb:Cb,dark_gray_Switch:Cb,dark_blue_accent:wb,dark_blue_Tooltip:wb,dark_blue_SwitchThumb:wb,dark_blue_surface1:Tb,dark_blue_Input:Tb,dark_blue_Progress:Tb,dark_blue_Slider:Tb,dark_blue_TextArea:Tb,dark_blue_surface2:Eb,dark_blue_Button:Eb,dark_blue_SliderThumb:Eb,dark_blue_Switch:Eb,dark_red_accent:Db,dark_red_Tooltip:Db,dark_red_SwitchThumb:Db,dark_red_surface1:Ob,dark_red_Input:Ob,dark_red_Progress:Ob,dark_red_Slider:Ob,dark_red_TextArea:Ob,dark_red_surface2:kb,dark_red_Button:kb,dark_red_SliderThumb:kb,dark_red_Switch:kb,dark_yellow_accent:Ab,dark_yellow_Tooltip:Ab,dark_yellow_SwitchThumb:Ab,dark_yellow_surface1:jb,dark_yellow_Input:jb,dark_yellow_Progress:jb,dark_yellow_Slider:jb,dark_yellow_TextArea:jb,dark_yellow_surface2:Mb,dark_yellow_Button:Mb,dark_yellow_SliderThumb:Mb,dark_yellow_Switch:Mb,dark_green_accent:Nb,dark_green_Tooltip:Nb,dark_green_SwitchThumb:Nb,dark_green_surface1:Pb,dark_green_Input:Pb,dark_green_Progress:Pb,dark_green_Slider:Pb,dark_green_TextArea:Pb,dark_green_surface2:Fb,dark_green_Button:Fb,dark_green_SliderThumb:Fb,dark_green_Switch:Fb,dark_orange_accent:Ib,dark_orange_Tooltip:Ib,dark_orange_SwitchThumb:Ib,dark_orange_surface1:Lb,dark_orange_Input:Lb,dark_orange_Progress:Lb,dark_orange_Slider:Lb,dark_orange_TextArea:Lb,dark_orange_surface2:Rb,dark_orange_Button:Rb,dark_orange_SliderThumb:Rb,dark_orange_Switch:Rb,dark_pink_accent:zb,dark_pink_Tooltip:zb,dark_pink_SwitchThumb:zb,dark_pink_surface1:Bb,dark_pink_Input:Bb,dark_pink_Progress:Bb,dark_pink_Slider:Bb,dark_pink_TextArea:Bb,dark_pink_surface2:Vb,dark_pink_Button:Vb,dark_pink_SliderThumb:Vb,dark_pink_Switch:Vb,dark_purple_accent:Hb,dark_purple_Tooltip:Hb,dark_purple_SwitchThumb:Hb,dark_purple_surface1:Ub,dark_purple_Input:Ub,dark_purple_Progress:Ub,dark_purple_Slider:Ub,dark_purple_TextArea:Ub,dark_purple_surface2:Wb,dark_purple_Button:Wb,dark_purple_SliderThumb:Wb,dark_purple_Switch:Wb,dark_teal_accent:Gb,dark_teal_Tooltip:Gb,dark_teal_SwitchThumb:Gb,dark_teal_surface1:Kb,dark_teal_Input:Kb,dark_teal_Progress:Kb,dark_teal_Slider:Kb,dark_teal_TextArea:Kb,dark_teal_surface2:qb,dark_teal_Button:qb,dark_teal_SliderThumb:qb,dark_teal_Switch:qb,dark_neutral_accent:Jb,dark_neutral_Tooltip:Jb,dark_neutral_SwitchThumb:Jb,dark_neutral_surface1:Yb,dark_neutral_Input:Yb,dark_neutral_Progress:Yb,dark_neutral_Slider:Yb,dark_neutral_TextArea:Yb,dark_neutral_surface2:Xb,dark_neutral_Button:Xb,dark_neutral_SliderThumb:Xb,dark_neutral_Switch:Xb,light_ProgressIndicator:Zb,light_SliderActive:Zb,light_white_ProgressIndicator:Zb,light_white_SliderActive:Zb,dark_ProgressIndicator:Qb,dark_SliderActive:Qb,dark_black_ProgressIndicator:Qb,dark_black_SliderActive:Qb,light_black_ProgressIndicator:$b,light_black_SliderActive:$b,light_gray_ProgressIndicator:ex,light_gray_SliderActive:ex,light_blue_ProgressIndicator:tx,light_blue_SliderActive:tx,light_red_ProgressIndicator:nx,light_red_SliderActive:nx,light_yellow_ProgressIndicator:rx,light_yellow_SliderActive:rx,light_green_ProgressIndicator:ix,light_green_SliderActive:ix,light_orange_ProgressIndicator:ax,light_orange_SliderActive:ax,light_pink_ProgressIndicator:ox,light_pink_SliderActive:ox,light_purple_ProgressIndicator:sx,light_purple_SliderActive:sx,light_teal_ProgressIndicator:cx,light_teal_SliderActive:cx,light_neutral_ProgressIndicator:lx,light_neutral_SliderActive:lx,dark_white_ProgressIndicator:ux,dark_white_SliderActive:ux,dark_gray_ProgressIndicator:dx,dark_gray_SliderActive:dx,dark_blue_ProgressIndicator:fx,dark_blue_SliderActive:fx,dark_red_ProgressIndicator:px,dark_red_SliderActive:px,dark_yellow_ProgressIndicator:mx,dark_yellow_SliderActive:mx,dark_green_ProgressIndicator:hx,dark_green_SliderActive:hx,dark_orange_ProgressIndicator:gx,dark_orange_SliderActive:gx,dark_pink_ProgressIndicator:_x,dark_pink_SliderActive:_x,dark_purple_ProgressIndicator:vx,dark_purple_SliderActive:vx,dark_teal_ProgressIndicator:yx,dark_teal_SliderActive:yx,dark_neutral_ProgressIndicator:bx,dark_neutral_SliderActive:bx};function Sx(e){return e===0?0:e===2?.5:e===4?1:e===8?1.5:e<=16?Math.round(e*.333):Math.floor(e*.7-12)}var Cx={$0:0,"$0.25":2,"$0.5":4,"$0.75":8,$1:20,"$1.5":24,$2:28,"$2.5":32,$3:36,"$3.5":40,$4:44,$true:44,"$4.5":48,$5:52,$6:64,$7:74,$8:84,$9:94,$10:104,$11:124,$12:144,$13:164,$14:184,$15:204,$16:224,$17:224,$18:244,$19:264,$20:284},wx=Object.entries(Cx).map(([e,t])=>[e,Sx(t)]),Tx=wx.slice(1).map(([e,t])=>[`-${e.slice(1)}`,-t]),Ex={radius:{0:0,1:3,2:5,3:7,4:9,true:9,5:10,6:16,7:19,8:22,9:26,10:34,11:42,12:50},zIndex:{0:0,1:100,2:200,3:300,4:400,5:500},space:{...Object.fromEntries(wx),...Object.fromEntries(Tx)},size:Cx},Dx=Ox({text:`textAlign`,b:`bottom`,bg:`backgroundColor`,content:`alignContent`,grow:`flexGrow`,items:`alignItems`,justify:`justifyContent`,l:`left`,m:`margin`,maxH:`maxHeight`,maxW:`maxWidth`,mb:`marginBottom`,minH:`minHeight`,minW:`minWidth`,ml:`marginLeft`,mr:`marginRight`,mt:`marginTop`,mx:`marginHorizontal`,my:`marginVertical`,p:`padding`,pb:`paddingBottom`,pl:`paddingLeft`,pr:`paddingRight`,pt:`paddingTop`,px:`paddingHorizontal`,py:`paddingVertical`,r:`right`,rounded:`borderRadius`,select:`userSelect`,self:`alignSelf`,shrink:`flexShrink`,t:`top`,z:`zIndex`});function Ox(e){return e}var kx=`Zen Mono`,Ax=`Zen Pixel Square`,jx=`"Zen", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`,Mx=`"${kx}", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace`;`${Ax}${kx}`;var Nx=jx,Px=Mx,Fx={1:12,2:13,3:14,4:15,true:15,5:16,6:18,7:22,8:26,9:30,10:40,11:46,12:52,13:60,14:70,15:85,16:100},Ix=e=>{let t=1.5-Math.max(0,(e-20)*.004);return Math.round(e*t)},Lx=({font:e={},sizeLineHeight:t=Ix,sizeSize:n=e=>Math.round(e)}={})=>{let r=Object.fromEntries(Object.entries({...Fx,...e.size}).map(([e,t])=>[e,n(+t)]));return Xa({family:`-apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`,lineHeight:Object.fromEntries(Object.entries(r).map(([e,n])=>[e,t(ee(n))])),weight:{1:`400`},letterSpacing:{4:0},...e,size:r})},Rx=e=>Math.round(e*1.12+5),zx=Nx,Bx=Px,Vx={body:Lx({font:{family:zx}}),heading:Lx({font:{family:zx,weight:{0:`600`,6:`700`,9:`800`}},sizeLineHeight:Rx}),mono:Lx({font:{family:Bx}})},Hx={100:100,200:200,xxxs:260,xxs:340,xs:460,sm:640,md:768,lg:1024,xl:1280,xxl:1536},Ux=.02,Wx={media:{touchable:{pointer:`coarse`},hoverable:{hover:`hover`},"max-xxl":{maxWidth:Hx.xxl-Ux},"max-xl":{maxWidth:Hx.xl-Ux},"max-lg":{maxWidth:Hx.lg-Ux},"max-md":{maxWidth:Hx.md-Ux},"max-sm":{maxWidth:Hx.sm-Ux},"max-xs":{maxWidth:Hx.xs-Ux},"max-xxs":{maxWidth:Hx.xxs-Ux},"max-xxxs":{maxWidth:Hx.xxxs-Ux},"max-200":{maxWidth:Hx[200]-Ux},"max-100":{maxWidth:Hx[100]-Ux},xxxs:{minWidth:Hx.xxxs},xxs:{minWidth:Hx.xxs},xs:{minWidth:Hx.xs},sm:{minWidth:Hx.sm},md:{minWidth:Hx.md},lg:{minWidth:Hx.lg},xl:{minWidth:Hx.xl},xxl:{minWidth:Hx.xxl},"max-height-lg":{maxHeight:Hx.lg-Ux},"max-height-md":{maxHeight:Hx.md-Ux},"max-height-sm":{maxHeight:Hx.sm-Ux},"max-height-xs":{maxHeight:Hx.xs-Ux},"max-height-xxs":{maxHeight:Hx.xxs-Ux},"max-height-xxxs":{maxHeight:Hx.xxxs-Ux},"max-height-200":{maxHeight:Hx[200]-Ux},"max-height-100":{maxHeight:Hx[100]-Ux},"height-sm":{minHeight:Hx.sm},"height-md":{minHeight:Hx.md},"height-lg":{minHeight:Hx.lg}},shorthands:Dx,themes:xx,tokens:Ex,fonts:Vx,selectionStyles:e=>e.color5?{backgroundColor:e.color5,color:e.color11}:null,settings:{mediaQueryDefaultActive:{touchable:!1,hoverable:!0,"max-xxl":!0,"max-xl":!0,"max-lg":!0,"max-md":!0,"max-sm":!0,"max-xs":!0,"max-xxs":!1,"max-xxxs":!1,xxxs:!0,xxs:!0,xs:!0,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1,"max-height-sm":!1,"max-height-md":!1,"max-height-lg":!0,"height-sm":!0,"height-md":!0,"height-lg":!1},defaultFont:`body`,fastSchemeChange:!0,shouldAddPrefersColorThemes:!0,allowedStyleValues:`somewhat-strict-web`,addThemeClassName:`html`,onlyAllowShorthands:!0,styleCompat:`web`}},Gx=new Set([`stiffness`,`damping`,`mass`,`tension`,`friction`,`velocity`,`overshootClamping`,`duration`,`bounciness`,`speed`]);function Kx(e){return Gx.has(e)}function qx(e){if(!e)return{default:null,enter:null,exit:null,delay:void 0,properties:{}};if(typeof e==`string`)return{default:e,enter:null,exit:null,delay:void 0,properties:{}};if(Array.isArray(e)){let[t,n]=e,r={},i={},a,o=null,s=null;if(n&&typeof n==`object`)for(let[e,t]of Object.entries(n))e===`delay`&&typeof t==`number`?a=t:e===`enter`&&typeof t==`string`?o=t:e===`exit`&&typeof t==`string`?s=t:Kx(e)&&t!==void 0?Object.assign(i,{[e]:t}):t!==void 0&&(r[e]=t);return{default:t,enter:o,exit:s,delay:a,properties:r,config:Object.keys(i).length>0?i:void 0}}if(typeof e==`object`){let t={},n={},r=null,i=null,a=null,o;for(let[s,c]of Object.entries(e))s==="default"&&typeof c==`string`?r=c:s===`enter`&&typeof c==`string`?i=c:s===`exit`&&typeof c==`string`?a=c:s===`delay`&&typeof c==`number`?o=c:Kx(s)&&c!==void 0?Object.assign(n,{[s]:c}):c!==void 0&&(t[s]=c);return{default:r,enter:i,exit:a,delay:o,properties:t,config:Object.keys(n).length>0?n:void 0}}return{default:null,enter:null,exit:null,delay:void 0,properties:{}}}function Jx(e){return e.default!==null||e.enter!==null||e.exit!==null||Object.keys(e.properties).length>0}function Yx(e){return Object.keys(e.properties)}function Xx(e,t){return t===`enter`&&e.enter?e.enter:t===`exit`&&e.exit?e.exit:e.default}function Zx(e,t,n,r){let i=new Map;for(let a of n){let n=e.properties[a],o=null;typeof n==`string`?o=t[n]??null:n&&typeof n==`object`&&n.type&&(o=t[n.type]??null),o===null&&(o=r),i.set(a,o)}return i}var Qx=/(\d+(?:\.\d+)?)\s*ms/,$x=/(\d+(?:\.\d+)?)\s*s/;function eS(e){let t=e.match(Qx);if(t)return Number.parseInt(t[1],10);let n=e.match($x);return n?Math.round(Number.parseFloat(n[1])*1e3):300}var tS=/(\d+(?:\.\d+)?)\s*ms/,nS=/(\d+(?:\.\d+)?)\s*s(?!tiffness)/;function rS(e,t){let n=e.replace(tS,`${t}ms`);if(n!==e)return n;let r=e.replace(nS,`${t}ms`);return r===e?`${t}ms ${e}`:r}var iS=[`x`,`y`,`scale`,`scaleX`,`scaleY`,`rotate`,`rotateX`,`rotateY`,`rotateZ`,`skewX`,`skewY`];function aS(e){if(!e)return``;let t=[];if(e.x!==void 0||e.y!==void 0){let n=e.x??0,r=e.y??0;t.push(`translate(${n}px, ${r}px)`)}if(e.scale!==void 0&&t.push(`scale(${e.scale})`),e.scaleX!==void 0&&t.push(`scaleX(${e.scaleX})`),e.scaleY!==void 0&&t.push(`scaleY(${e.scaleY})`),e.rotate!==void 0){let n=e.rotate,r=typeof n==`string`&&n.includes(`deg`)?``:`deg`;t.push(`rotate(${n}${r})`)}return e.rotateX!==void 0&&t.push(`rotateX(${e.rotateX}deg)`),e.rotateY!==void 0&&t.push(`rotateY(${e.rotateY}deg)`),e.rotateZ!==void 0&&t.push(`rotateZ(${e.rotateZ}deg)`),e.skewX!==void 0&&t.push(`skewX(${e.skewX}deg)`),e.skewY!==void 0&&t.push(`skewY(${e.skewY}deg)`),t.join(` `)}function oS(e,t){if(!t)return;let n=aS(t);n&&(e.style.transform=n);for(let[n,r]of Object.entries(t))iS.includes(n)||r!==void 0&&(n===`opacity`?e.style.opacity=String(r):n===`backgroundColor`?e.style.backgroundColor=String(r):n===`color`?e.style.color=String(r):e.style[n]=typeof r==`number`?`${r}px`:String(r))}function sS(e){let t=new WeakMap;return{animations:e,usePresence:Qa,ResetPresence:En,inputStyle:`css`,outputStyle:`css`,useAnimatedNumber(e){let[n,r]=V.useState(e),i=V.useRef(null);return{getInstance(){return r},getValue(){return n},setValue(e,n,a){if(r(e),i.current&&=(clearTimeout(i.current),null),a){if(!n||n.type===`direct`||n.type===`timing`&&n.duration===0)a();else{let e=n.type===`timing`?n.duration:300;i.current=setTimeout(a,e)}}let o=t.get(r);o&&o.forEach(t=>t(e))},stop(){i.current&&=(clearTimeout(i.current),null)}}},useAnimatedNumberReaction({value:e},n){V.useEffect(()=>{let r=e.getInstance(),i=t.get(r);if(!i){let e=new Set;t.set(r,e),i=e}return i.add(n),()=>{i?.delete(n)}},[])},useAnimatedNumberStyle(e,t){return t(e.getValue())},useAnimatedNumbersStyle(e,t){return t(...e.map(e=>e.getValue()))},useAnimations:({props:t,presence:n,style:r,componentState:i,stateRef:a,styleState:o})=>{let s=i.unmounted===!0,c=!!i.unmounted,l=n?.[0]===!1,u=n?.[1],d=V.useRef(c),f=d.current&&!c;V.useEffect(()=>{d.current=c});let p=V.useRef(0),m=V.useRef(!1),h=V.useRef(!1),g=V.useRef(!1),_=V.useRef(u),v=V.useRef({});_.current=u;let y=l&&!h.current,x=!l&&h.current;y&&(p.current++,m.current=!1),x&&(p.current++,g.current=!0),V.useEffect(()=>{h.current=l}),b(()=>{let e=a.current.host;if(l||!e)return;let t=getComputedStyle(e);v.current={opacity:t.opacity}});let S=qx(o?.effectiveTransition??t.transition),C=Xx(S,l?`exit`:c||f?`enter`:`default`),w=C?e[C]:null,T=Yx(S),E=S.default!==null||S.enter!==null||S.exit!==null,D=T.length>0,k;if(k=t.animateOnly?t.animateOnly:D&&!E?T:D&&E?[`all`,...T]:[`all`],b(()=>{let n=a.current.host;if(!u||!l||!n)return;let i=n,o=p.current,s=()=>{o===p.current&&(m.current||(m.current=!0,_.current?.()))};if(k.length===0){s();return}let c,d=g.current,f=d,h=t.enterStyle,y=t.exitStyle,b=S.delay?` ${S.delay}ms`:``,x=S.config?.duration,C=k.map(t=>{let n=S.properties[t],r=null;return typeof n==`string`?r=e[n]:n&&typeof n==`object`&&n.type?r=e[n.type]:w&&(r=w),r&&x&&(r=rS(r,x)),r?`${t} ${r}${b}`:null}).filter(Boolean).join(`, `),T=e=>e===`opacity`?r?.opacity??t.opacity??v.current.opacity??1:iS.includes(e)?+(e===`scale`||e===`scaleX`||e===`scaleY`):h?.[e];if(d){if(g.current=!1,i.style.transition=`none`,y){let e={};for(let t of Object.keys(y)){let n=T(t);n!==void 0&&(e[t]=n)}oS(i,e)}else i.style.opacity=`1`,i.style.transform=`none`;i.offsetHeight}else if(y){f=!0,i.style.transition=`none`;let e={};for(let t of Object.keys(y)){let n=T(t);n!==void 0&&(e[t]=n)}oS(i,e),i.offsetHeight,c=requestAnimationFrame(()=>{o===p.current&&(i.style.transition=C,i.offsetHeight,oS(i,y),f=!1)})}let E=w?eS(w):200,D=Zx(S,e,k,w);for(let e of D.values())if(e){let t=eS(e);t>E&&(E=t)}let O=S.delay??0,A=E+O,j=setTimeout(()=>{s()},A),ee=new Set(k),M=0,N=e=>{if(e.target!==i)return;let t=e.propertyName;(ee.has(t)||t===`all`)&&(M++,M>=ee.size&&(clearTimeout(j),s()))},P=()=>{f||(clearTimeout(j),s())};return i.addEventListener(`transitionend`,N),i.addEventListener(`transitioncancel`,P),d&&(c=requestAnimationFrame(()=>{o===p.current&&(i.style.transition=C,i.offsetHeight,oS(i,y),f=!1)})),()=>{clearTimeout(j),c!==void 0&&cancelAnimationFrame(c),i.removeEventListener(`transitionend`,N),i.removeEventListener(`transitioncancel`,P),i.style.transition=``}},[l]),s||!Jx(S))return null;Array.isArray(r.transform)&&(r.transform=O(r.transform));let A=S.delay?` ${S.delay}ms`:``,j=S.config?.duration;return r.transition=k.map(t=>{let n=S.properties[t],r=null;return typeof n==`string`?r=e[n]:n&&typeof n==`object`&&n.type?r=e[n.type]:w&&(r=w),r&&j&&(r=rS(r,j)),r?`${t} ${r}${A}`:null}).filter(Boolean).join(`, `),{style:r,className:c?`t_unmounted`:``}}}}var cS={dark:{ground:`var(--neutral-900)`,line:`var(--neutral-800)`,dim:`var(--neutral-400)`,ink:`var(--neutral-300)`,bright:`var(--neutral-50)`},light:{ground:`var(--neutral-100)`,line:`var(--neutral-200)`,dim:`var(--neutral-600)`,ink:`var(--neutral-700)`,bright:`var(--neutral-950)`}},lS={key:`ink`,string:`bright`,number:`bright`,boolean:`bright`,null:`bright`,punctuation:`dim`,comment:`dim`,keyword:`bright`},uS=e=>Object.fromEntries(Object.entries(lS).map(([t,n])=>[t,cS[e][n]])),dS={dark:uS(`dark`),light:uS(`light`)},fS={comment:{fontStyle:`italic`},keyword:{fontWeight:`700`},boolean:{fontWeight:`700`},null:{fontWeight:`700`}},pS=e=>`code${e[0].toUpperCase()}${e.slice(1)}`;function mS(e){let t=t=>`var(--${pS(t)}, ${cS[e][t]})`,n=t=>{let n=fS[t],r=n?.fontStyle??(n?.fontWeight?`bold`:void 0);return{foreground:`var(--${pS(t)}, ${dS[e][t]})`,...r?{fontStyle:r}:null}};return{name:`mono-${e}`,type:e,fg:t(`ink`),bg:t(`ground`),colors:{"editor.selectionBackground":t(`line`),"editor.lineHighlightBackground":t(`line`)},tokenColors:[{settings:{foreground:t(`ink`)}},{scope:[`comment`,`punctuation.definition.comment`,`string.quoted.docstring`],settings:n(`comment`)},{scope:[`punctuation`,`meta.brace`,`constant.character.escape.line-continuation`],settings:n(`punctuation`)},{scope:[`string`,`markup.inline.raw`],settings:n(`string`)},{scope:`constant.numeric`,settings:n(`number`)},{scope:[`constant.language`,`constant.language.boolean`],settings:n(`boolean`)},{scope:[`constant.language.null`,`constant.language.undefined`],settings:n(`null`)},{scope:[`constant`,`support.constant`,`entity.name.function`,`entity.name.command`,`support.function`,`entity.name.tag`],settings:{foreground:t(`bright`)}},{scope:[`string.unquoted`,`support.type.property-name`,`meta.object-literal.key`],settings:n(`key`)},{scope:[`keyword`,`storage`],settings:n(`keyword`)},{scope:[`keyword.operator`,`punctuation.accessor`],settings:{foreground:t(`ink`),fontStyle:``}},{scope:[`markup.heading`,`markup.bold`],settings:{foreground:t(`bright`),fontStyle:`bold`}},{scope:`markup.italic`,settings:{fontStyle:`italic`}},{scope:`markup.underline.link`,settings:{fontStyle:`underline`}},{scope:`markup.inserted`,settings:{foreground:t(`bright`)}},{scope:`markup.deleted`,settings:{foreground:t(`dim`)}}]}}mS(`dark`),mS(`light`);var hS=[`dim`,`ink`,`bright`,...Object.keys(lS)];Object.fromEntries(hS.map(e=>{let t=e in lS?lS[e]:e;return[e,{key:pS(e),light:cS.light[t],dark:cS.dark[t]}]}));var gS=`var(--font-sans, 'Zen', system-ui, -apple-system, sans-serif)`,_S=`var(--font-mono, 'Zen Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace)`,vS=`var(--font-serif, Georgia, serif)`,yS={1:`var(--text-xs, 12px)`,2:`var(--text-sm, 13px)`,3:`var(--text-base, 14px)`,4:`var(--text-lg, 15px)`,5:`var(--text-lg, 15px)`,6:`var(--text-xl, 17px)`,7:`var(--text-2xl, 21px)`,8:`var(--text-3xl, 26px)`,9:`var(--text-3xl, 26px)`,10:`var(--text-4xl, 32px)`,11:`var(--text-5xl, 40px)`,12:`calc(var(--text-5xl, 40px) + (var(--text-7xl, 64px) - var(--text-5xl, 40px)) / 3)`,13:`calc(var(--text-5xl, 40px) + 2 * (var(--text-7xl, 64px) - var(--text-5xl, 40px)) / 3)`,14:`var(--text-7xl, 64px)`,15:`calc(var(--text-7xl, 64px) + 4 * (var(--text-8xl, 84px) - var(--text-7xl, 64px)) / 5)`,16:`calc(var(--text-8xl, 84px) + 3 * (var(--text-9xl, 112px) - var(--text-8xl, 84px)) / 7)`,true:`var(--text-base, 14px)`},bS={1:`calc(16px * var(--type-scale, 1) * var(--leading-lang, 1))`,2:`calc(18px * var(--type-scale, 1) * var(--leading-lang, 1))`,3:`calc(20px * var(--type-scale, 1) * var(--leading-lang, 1))`,4:`calc(22px * var(--type-scale, 1) * var(--leading-lang, 1))`,5:`calc(22px * var(--type-scale, 1) * var(--leading-lang, 1))`,6:`calc(24px * var(--type-scale, 1) * var(--leading-lang, 1))`,7:`calc(22px * var(--type-scale, 1) * var(--leading-lang, 1))`,8:`calc(28px * var(--type-scale, 1) * var(--leading-lang, 1))`,9:`calc(28px * var(--type-scale, 1) * var(--leading-lang, 1))`,10:`calc(34px * var(--type-scale, 1) * var(--leading-lang, 1))`,11:`calc(42px * var(--type-scale, 1) * var(--leading-lang, 1))`,12:`calc(50px * var(--type-scale, 1) * var(--leading-lang, 1))`,13:`calc(58px * var(--type-scale, 1) * var(--leading-lang, 1))`,14:`calc(66px * var(--type-scale, 1) * var(--leading-lang, 1))`,15:`calc(82px * var(--type-scale, 1) * var(--leading-lang, 1))`,16:`calc(98px * var(--type-scale, 1) * var(--leading-lang, 1))`,true:`calc(20px * var(--type-scale, 1) * var(--leading-lang, 1))`},xS={1:0,2:0,3:0,4:0,5:0,6:0,7:`-0.025em`,8:`-0.025em`,9:`-0.025em`,10:`-0.025em`,11:`-0.025em`,12:`-0.025em`,13:`-0.025em`,14:`-0.025em`,15:`-0.025em`,16:`-0.025em`,true:0},SS={"2xs":2,xs:4,0:0,1:6,2:6,3:8,4:8,5:12,6:12,7:12,8:12,9:12,10:9999,11:9999,12:9999,true:8},CS={0:0,"0.25":1,"0.5":2,"0.75":3,1:4,"1.5":6,2:8,"2.5":10,3:12,"3.5":14,4:16,"4.5":20,5:24,6:32,7:40,8:48,9:56,10:64,11:80,12:96,13:112,14:128,15:144,16:160,17:160,18:176,19:192,20:208},wS=e=>e===0?0:`calc(${e}px * var(--density, 1))`,TS=e=>e===0||e>=9999?e:`calc(${e}px * var(--radius-scale, 1))`,ES=Object.fromEntries(Object.entries(SS).map(([e,t])=>[e,TS(t)])),DS={};for(let[e,t]of Object.entries(CS))DS[`$${e}`]=wS(t),DS[`-${e}`]=wS(-t);DS.$true=wS(CS[4]),DS[`-true`]=wS(-CS[4]);var OS={dark:`rgb(255 255 255 / .10)`,light:`rgb(0 0 0 / .10)`},kS={dark:`#e5e5e5`,light:`#0a0a0a`},AS={dark:`rgb(255 255 255 / .40)`,light:`rgb(0 0 0 / .5)`},jS={bad:`var(--state-error, #ef4444)`,good:`var(--state-success, #22c55e)`},MS={dark:{aside:`rgb(255 255 255 / .78)`,hint:`rgb(255 255 255 / .55)`,hush:`rgb(255 255 255 / .3)`},light:{aside:`rgb(10 10 10 / .78)`,hint:`rgb(10 10 10 / .55)`,hush:`rgb(10 10 10 / .3)`}},NS=e=>Object.fromEntries(Object.entries({...cS[e],...dS[e]}).map(([e,t])=>[`code${e[0].toUpperCase()}${e.slice(1)}`,t])),PS={dark:{base:`rgb(255 255 255 / .03)`,hover:`rgb(255 255 255 / .06)`,raised:`rgb(255 255 255 / .12)`},light:{base:`rgb(0 0 0 / .03)`,hover:`rgb(0 0 0 / .06)`,raised:`rgb(0 0 0 / .12)`}},FS={dark:`#0a0a0a`,light:`#f7f7f7`},IS={dark:`#333333`,light:`#e0e0e0`},LS={dark:`rgb(229 229 229 / .6)`,light:`rgb(10 10 10 / .65)`},RS=e=>e.startsWith(`light`)?`light`:`dark`,zS=e=>`color4`in e,BS=e=>e.split(`_`).slice(0,-1).join(`_`),VS=e=>{let t=Wx.themes[e];return!t||e===RS(e)?`var(--border, ${OS[RS(e)]})`:zS(t)?String(t.borderColor):VS(BS(e))},HS=Object.fromEntries(Object.entries(Wx.themes).map(([e,t])=>{let n=RS(e),r={...t,outlineColor:`var(--ring, ${AS[n]})`,...zS(t)?{}:{borderColor:VS(e)}};return[e,e===n?{...r,color2:`var(--surface-1, ${PS[n].base})`,color3:`var(--surface-2, ${PS[n].hover})`,color4:`var(--border, ${OS[n]})`,color5:`var(--surface-3, ${PS[n].raised})`,borderColor:`var(--border, ${OS[n]})`,color12:`var(--foreground, ${kS[n]})`,sunken:String(t.color1),panel:`var(--surface-1, ${PS[n].base})`,hover:`var(--surface-2, ${PS[n].hover})`,edge:`var(--border, ${OS[n]})`,raised:`var(--surface-3, ${PS[n].raised})`,rim:String(t.color6),bound:String(t.color7),dim:String(t.color8),faint:String(t.color9),soft:String(t.color10),quiet:String(t.color11),ink:`var(--foreground, ${kS[n]})`,aside:`var(--text-secondary, ${MS[n].aside})`,hint:`var(--text-tertiary, ${MS[n].hint})`,hush:`var(--text-disabled, ${MS[n].hush})`,bad:jS.bad,good:jS.good,background:FS[n],color:`var(--foreground, ${kS[n]})`,placeholderColor:`var(--text-placeholder, ${LS[n]})`,accentBackground:`var(--accent, ${PS[n].raised})`,accentColor:`var(--accent-foreground, ${kS[n]})`,accentHover:`var(--accent-hover, ${IS[n]})`,...NS(n)}:r]})),US=e=>e,WS=`var(--ease-out, cubic-bezier(0.215, 0.61, 0.355, 1))`,GS={animations:sS({default:`${WS} var(--duration-base, 300ms)`,"75ms":`${WS} 75ms`,"100ms":`${WS} 100ms`,"200ms":`${WS} 200ms`,quickest:`${WS} var(--duration-fast, 150ms)`,quicker:`${WS} var(--duration-base, 300ms)`,quick:`${WS} var(--duration-slow, 400ms)`,medium:`${WS} 300ms`,slow:`${WS} 500ms`,bouncy:`${WS} 200ms`,lazy:`${WS} 1000ms`,tooltip:`${WS} 400ms`}),...Wx,settings:{...Wx.settings,shouldAddPrefersColorThemes:!1},tokens:{...Wx.tokens,radius:ES,space:DS},fonts:{...Wx.fonts,body:{...Wx.fonts.body,family:gS,size:US(yS),lineHeight:US(bS),letterSpacing:US(xS)},heading:{...Wx.fonts.heading,family:gS,size:US(yS),lineHeight:US(bS),letterSpacing:US(xS)},mono:{...Wx.fonts.body,family:_S,size:US(yS),lineHeight:US(bS)},serif:{...Wx.fonts.body,family:vS,size:US(yS),lineHeight:US(bS),letterSpacing:US(xS)}}},KS=hu({...GS,themes:HS}),qS=new Set([`blue`,`green`,`orange`,`pink`,`purple`,`red`,`teal`,`yellow`]),JS=e=>e.split(`_`).slice(1).some(e=>qS.has(e));if(hu({...GS,themes:Object.fromEntries(Object.entries(HS).filter(([e])=>!JS(e)))}),!KS)throw Error(`@hanzo/ui: the gui config did not install`);var YS=new Set(`a.span.em.strong.b.i.u.s.small.abbr.cite.code.kbd.samp.var.sub.sup.mark.q.time.label.output.bdi.bdo.ruby.wbr`.split(`.`)),XS=[`fontSize`,`lineHeight`,`fontWeight`,`letterSpacing`,`textTransform`,`fontFamily`,`fontStyle`,`textAlign`,`color`,`textDecorationLine`,`whiteSpace`,`fontVariantNumeric`],ZS={table:`table`,thead:`table-header-group`,tbody:`table-row-group`,tfoot:`table-footer-group`,tr:`table-row`,td:`table-cell`,th:`table-cell`,caption:`table-caption`,colgroup:`table-column-group`,col:`table-column`},QS=[`scrollSnapType`,`scrollSnapAlign`,`scrollSnapStop`,`WebkitBackgroundClip`,`transitionProperty`,`transitionDuration`,`transitionDelay`,`transitionTimingFunction`,`textOverflow`],$S=(0,V.forwardRef)(function({className:e,children:t,"aria-hidden":n,tag:r,...i},a){let{props:o,rest:s}=mn(e);`minHeight`in o||(o.minHeight=`auto`),`minWidth`in o||(o.minWidth=`auto`);let c={};for(let e of XS)e in o&&(c[e]=o[e],delete o[e]);for(let e of QS)e in o&&(c[e]=o[e],delete o[e]);r===`li`&&!(`display`in o)&&(c.display=`list-item`),r&&r in ZS&&!(`display`in o)&&(c.display=ZS[r]);let l=Object.keys(c).length?{...c,...i.style}:i.style;return(0,H.jsx)(z,{ref:r?void 0:a,asChild:r?!0:void 0,display:r&&YS.has(r)?`inline`:`block`,shrink:1,"aria-hidden":n===void 0?void 0:n!==`false`&&n!==!1,...o,...r?{}:i,className:r?void 0:s||void 0,style:r?void 0:l,children:r?(0,V.createElement)(r,{...i,ref:a,className:s||void 0,style:l},t):t})}),eC=V.createContext(`a`),tC=()=>V.useContext(eC),nC=tt,rC=wt,iC={end:{t:0,b:0,insetInlineEnd:0,height:`100%`,width:`100%`,maxW:384,borderStartStartRadius:`$5`,borderEndStartRadius:`$5`,borderStartEndRadius:0,borderEndEndRadius:0},start:{t:0,b:0,insetInlineStart:0,height:`100%`,width:`100%`,maxW:384,borderStartEndRadius:`$5`,borderEndEndRadius:`$5`,borderStartStartRadius:0,borderEndStartRadius:0},right:{t:0,b:0,r:0,height:`100%`,width:`100%`,maxW:384,btlr:`$5`,bblr:`$5`,btrr:0,bbrr:0},left:{t:0,b:0,l:0,height:`100%`,width:`100%`,maxW:384,btrr:`$5`,bbrr:`$5`,btlr:0,bblr:0},top:{t:0,l:0,r:0,width:`100%`,maxW:`100%`,maxH:`80%`,bblr:`$5`,bbrr:`$5`,btlr:0,btrr:0},bottom:{b:0,l:0,r:0,width:`100%`,maxW:`100%`,maxH:`80%`,btlr:`$5`,btrr:`$5`,bblr:0,bbrr:0}},aC=({side:e=`end`,className:t,...n})=>(0,H.jsx)(pn,{...oC(e),position:`fixed`,...iC[e],...Ot(t),...n}),oC=e=>({"data-slot":`sheet-content`,"data-side":e}),sC={xs:13,s:16,m:24,l:32,xl:40},cC=`linear-gradient(90deg, transparent 0%, var(--glass, rgba(128, 128, 128, 0.08)) 50%, transparent 100%)`;function lC({size:e,layout:t=`inline`,animated:n=!0,className:r,...i}){let{props:o,rest:s}=mn(r),c=e?sC[e]:t===`block`?`1em`:void 0;return(0,H.jsx)(z,{...B(`skeleton`),"aria-hidden":!0,"data-layout":t,"data-motion":n?`shimmer`:void 0,display:t===`inline`?`inline-flex`:`flex`,width:`100%`,...c===void 0?null:{height:c},rounded:`$xs`,bg:`$hover`,backgroundImage:n?cC:void 0,backgroundSize:`160px 100%`,backgroundRepeat:`no-repeat`,overflow:`hidden`,...o,...s?{className:s}:null,...i,children:t===`inline`&&c===void 0&&!(`height`in i)&&!(`height`in o)?(0,H.jsx)(a,{size:`$2`,"aria-hidden":!0,children:``}):null})}var uC=(e,t)=>e==null?`${t}px`:typeof e==`number`?`${e}px`:e.startsWith(`$`)?`var(--space-${e.slice(1)}, ${t}px)`:e,dC=e=>typeof e==`object`&&!!e&&!Array.isArray(e),fC=e=>typeof e==`number`?`${e}px`:e,pC=e=>typeof e==`number`?`repeat(${e}, minmax(0, 1fr))`:Array.isArray(e)?e.map(fC).join(` `):e,mC=({min:e,max:t},n)=>`repeat(auto-fill, minmax(${t?`max(min(${e}px, 100%), calc((100% - ${t-1} * ${n}) / ${t}))`:`min(${e}px, 100%)`}, 1fr))`,hC=(e,t=`0px`)=>dC(e)?mC(e,t):pC(e),gC={fontFamily:`inherit`,fontWeight:`inherit`,letterSpacing:`inherit`,lineHeight:`inherit`},Pee=e=>(typeof e==`function`||typeof e==`object`)&&e!==null&&`staticConfig`in e,Fee=e=>{if(!(0,V.isValidElement)(e)||e.type===V.Fragment||Pee(e.type))return e;let t=e,n=t.props.style;return Array.isArray(n)?(0,V.cloneElement)(t,{style:[{minWidth:0},...n]}):n&&typeof n==`object`&&`minWidth`in n?t:(0,V.cloneElement)(t,{style:{minWidth:0,...n}})},_C=({columns:e={min:240},rows:t,gap:n=`$3`,style:r,children:i,...a})=>{let o=uC(n,12);return(0,H.jsx)(w,{"data-slot":`grid`,display:`grid`,gridTemplateColumns:hC(e,o),...t===void 0?null:{gridTemplateRows:pC(t)},gap:o,shrink:1,minW:`auto`,minH:`auto`,style:{...gC,...r},...a,children:V.Children.map(i,Fee)})},vC=e=>e===void 0?void 0:typeof e==`number`?`span ${e}`:e,yC=({col:e,row:t,style:n,...r})=>(0,H.jsx)(w,{"data-slot":`grid-cell`,...e===void 0?null:{gridColumn:vC(e)},...t===void 0?null:{gridRow:vC(t)},minW:0,shrink:1,style:{...gC,...n},...r}),Iee=[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`],bC=[`Su`,`Mo`,`Tu`,`We`,`Th`,`Fr`,`Sa`],xC=(e,t,n)=>new Date(e,t,n),SC=e=>`${e.getFullYear()}-${e.getMonth()+1}-${e.getDate()}`,CC=(e,t)=>!!e&&!!t&&SC(e)===SC(t),wC=e=>xC(e.getFullYear(),e.getMonth(),e.getDate()).getTime(),TC=(e,t)=>xC(e.getFullYear(),e.getMonth(),e.getDate()+t),EC=(e,t=0)=>xC(e.getFullYear(),e.getMonth()+t,1),DC=(e,t)=>{let n=xC(e.getFullYear(),e.getMonth()+t+1,0);return xC(n.getFullYear(),n.getMonth(),Math.min(e.getDate(),n.getDate()))},Lee=(e,t,n)=>{let r=(e.getDay()-t+7)%7,i=xC(e.getFullYear(),e.getMonth()+1,0).getDate();return Array.from({length:Math.ceil((r+i)/7)*7},(t,a)=>{let o=a-r+1;return n||o>=1&&o<=i?xC(e.getFullYear(),e.getMonth(),o):null})},Ree=(e,t)=>{if(e.mode===`multiple`)return(e.selected??[]).some(e=>CC(e,t));if(e.mode===`range`){let{from:n,to:r}=e.selected??{};return!!n&&(r?wC(n)<=wC(t)&&wC(t)<=wC(r):CC(n,t))}return CC(e.selected,t)},zee=(e,t)=>{let{from:n,to:r}=e??{};if(!n)return{from:t,to:t};if(!r)return wC(t)<wC(n)?{from:t,to:n}:{from:n,to:t};if(!(CC(n,t)&&CC(r,t)))return CC(n,t)?{from:n,to:t}:CC(r,t)?{from:t,to:t}:wC(t)<wC(n)?{from:t,to:r}:{from:n,to:t}},Bee=(e,t)=>{if(e.mode===`multiple`){let n=e.selected??[];e.onSelect?.(n.some(e=>CC(e,t))?n.filter(e=>!CC(e,t)):[...n,t])}else e.mode===`range`?e.onSelect?.(zee(e.selected,t)):e.onSelect?.(CC(e.selected,t)?void 0:t)},Vee=(e,t,n)=>{let r=(t.getDay()-n+7)%7;return e===`ArrowLeft`?TC(t,-1):e===`ArrowRight`?TC(t,1):e===`ArrowUp`?TC(t,-7):e===`ArrowDown`?TC(t,7):e===`Home`?TC(t,-r):e===`End`?TC(t,6-r):e===`PageUp`?DC(t,-1):e===`PageDown`?DC(t,1):void 0};function Hee(e){let{t}=R(),{month:n,defaultMonth:r,onMonthChange:i,numberOfMonths:o=1,weekStartsOn:s=0,showOutsideDays:c=!0,disabled:l,initialFocus:u,className:d}=e,[f,p]=(0,V.useState)(()=>EC(r??new Date)),m=n?EC(n):f,h=Array.from({length:o},(e,t)=>EC(m,t)),g=h.map(e=>Lee(e,s,c)),_=e=>!!e&&wC(e)>=wC(m)&&wC(e)<wC(EC(m,o)),v=e=>g.some(t=>t.some(t=>CC(t,e))),b=[...bC.slice(s),...bC.slice(0,s)].map(e=>t(e)),x=new Date,S=e.mode===`range`?e.selected??{}:{},[C,w]=(0,V.useState)(),T=e.mode===`multiple`?e.selected??[]:e.mode===`range`?[e.selected?.from]:[e.selected],E=C&&v(C)?C:T.find(_)??(_(x)?x:m),D=(0,V.useRef)(null),O=(0,V.useRef)(!!u);(0,V.useEffect)(()=>{let e=D.current;if(!O.current||typeof HTMLElement>`u`||!(e instanceof HTMLElement))return;O.current=!1;let t=`[data-date="${SC(E)}"]`;(e.querySelector(`${t}:not([data-outside])`)??e.querySelector(t))?.focus()});let k=e=>{let t=EC(m,e);p(t),i?.(t)},A=(e,t)=>{let n=Vee(ih(e),t,s);n&&(e.preventDefault(),O.current=!0,w(n),v(n)||k(wC(n)<wC(m)?-1:1))};return(0,H.jsx)(y,{ref:D,...B(`calendar`),flexWrap:`wrap`,gap:`$4`,p:`$3`,...Ot(d),children:h.map((n,r)=>(0,H.jsxs)(z,{...B(`calendar-month`),gap:`$4`,children:[(0,H.jsxs)(y,{...B(`calendar-caption`),items:`center`,justify:`space-between`,children:[(0,H.jsx)(z,{width:32,children:r===0&&(0,H.jsx)(W,{...B(`calendar-nav-previous`),"aria-label":t(`Previous month`),variant:`outline`,size:`icon-sm`,onClick:()=>k(-1),children:(0,H.jsx)(Tp,{...$m,size:16})})}),(0,H.jsxs)(a,{...B(`calendar-caption-label`),size:`$3`,fontWeight:`500`,children:[t(Iee[n.getMonth()]),` `,n.getFullYear()]}),(0,H.jsx)(z,{width:32,items:`flex-end`,children:r===h.length-1&&(0,H.jsx)(W,{...B(`calendar-nav-next`),"aria-label":t(`Next month`),variant:`outline`,size:`icon-sm`,onClick:()=>k(1),children:(0,H.jsx)(rt,{...$m,size:16})})})]}),(0,H.jsxs)(_C,{columns:7,gap:`$1`,children:[b.map(e=>(0,H.jsx)(yC,{style:{textAlign:`center`},children:(0,H.jsx)(a,{size:`$1`,color:`$quiet`,children:e})},e)),g[r].map((t,r)=>{if(!t)return(0,H.jsx)(yC,{},r);let i=t.getMonth()!==n.getMonth(),a=Ree(e,t),o=CC(S.from,t),s=CC(S.to,t),c=a&&e.mode===`range`&&!o&&!s,u=CC(t,x);return(0,H.jsx)(yC,{children:(0,H.jsx)(W,{...B(`calendar-day`),"data-date":SC(t),"data-today":u||void 0,"data-outside":i||void 0,"data-selected":a||void 0,"data-range-start":o||void 0,"data-range-end":s||void 0,"data-range-middle":c||void 0,"aria-selected":a,"aria-label":t.toDateString(),variant:a&&!c?`primary`:c||u?`secondary`:`ghost`,size:`icon`,width:`100%`,opacity:i?.5:1,disabled:!!l?.(t),tabIndex:CC(t,E)&&(!i||!_(E))?0:-1,onFocus:()=>w(t),onKeyDown:e=>A(e,t),onClick:()=>Bee(e,t),children:t.getDate()})},r)})]})]},r))})}var OC=[],kC=[];(()=>{let e=`lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,1n,9,16,o,,x,1i,3,,i,,7,a,2,t,3,1k,,,7,2,2,2,3,9,,a,2,q,,2,3,1k,,,5,4,2,2,3,3,,u,2,3,,b,3,1k,,,8,,3,,3,k,2,m,6,,3,1k,,,7,2,2,2,3,7,3,a,2,u,,1n,5,3,3,,4,9,,14,5,1j,,,7,,3,,4,7,2,b,2,t,3,1k,,,7,,3,,4,7,2,b,2,f,,c,4,1j,2,,7,,3,,4,9,,a,2,t,3,1y,,4,6,,,,8,i,2,1p,,,8,c,8,2q,,,a,b,7,21,2,r,,,,,,4,2,1d,k,,2,5,b,,10,9,,2u,b,,6,n,4,4,3,g,4,d,,,3,6,,f,,jj,3,qa,4,s,3,t,2,u,2,1s,w,9,,19,3,,,39,2,y,,3a,c,4,c,63,5,1l,a,,,,,2,o,2,,1c,1a,2,c,k,5,1b,h,12,9,c,3,u,d,1k,e,1c,k,48,3,,l,4,,6,,2,3,5i,1s,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,n,5,4,,2b,2,1e,i,q,i,d,,12,8,p,d,18,4,1b,e,10,,1v,e,c,,8,2,1a,,1f,,,3,2,2,5,2,,,15,5,5,2,6k,8,,2,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,1t,5,8t,2,25,6,1y,b,1d,4,3e,3,1h,f,15,,2,2,a,4,19,b,7,,1p,3,10,e,g,2,18,,c,3,1c,e,8,4,,2,2k,c,6,,2,,4d,c,l,4,1j,2,,7,2,2,2,3,9,,a,2,2,7,3,5,1v,9,,,2,,,4,,5,,,e,2,2a,i,n,,29,k,6j,7,2,9,r,2,2a,h,2y,d,2t,3,2,a,74,f,6t,6,,2,2,4,,,,2,3x,7,2,7,3,,s,a,14,7,,4,8,,9,b,1a,g,5i,8,5j,8,,8,2a,m,,e,3e,6,3,,,2,,7,,,1u,5,,2,,5,9n,4,9,2,,,1c,7,3,5,n,,44l,,6,f,8ug,i,1xc,5,1n,7,t4,,,1j,7,4,29,,b,2,f57,2,3mp,1a,2,n,f2,5,3,6,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,2s,,4g,7,af,,1p,4,e4,4,72,2,6r,,2,,7,2,5,,d6,7,31,7,240,5`.split(`,`).map(e=>e?parseInt(e,36):1);for(let t=0,n=0;t<e.length;t++)(t%2?kC:OC).push(n+=e[t])})();function Uee(e){if(e<768)return!1;for(let t=0,n=OC.length;;){let r=t+n>>1;if(e<OC[r])n=r;else if(e>=kC[r])t=r+1;else return!0;if(t==n)return!1}}function AC(e){return e>=127462&&e<=127487}var jC=8205;function Wee(e,t,n=!0,r=!0){return(n?MC:Gee)(e,t,r)}function MC(e,t,n){if(t==e.length)return t;t&&PC(e.charCodeAt(t))&&FC(e.charCodeAt(t-1))&&t--;let r=NC(e,t);for(t+=IC(r);t<e.length;){let i=NC(e,t);if(r==jC||i==jC||n&&Uee(i))t+=IC(i),r=i;else if(AC(i)){let n=0,r=t-2;for(;r>=0&&AC(NC(e,r));)n++,r-=2;if(n%2==0)break;t+=2}else break}return t}function Gee(e,t,n){for(;t>1;){let r=MC(e,t-2,n);if(r<t)return r;t--}return 0}function NC(e,t){let n=e.charCodeAt(t);if(!FC(n)||t+1==e.length)return n;let r=e.charCodeAt(t+1);return PC(r)?(n-55296<<10)+(r-56320)+65536:n}function PC(e){return e>=56320&&e<57344}function FC(e){return e>=55296&&e<56320}function IC(e){return e<65536?1:2}var LC=class e{lineAt(e){if(e<0||e>this.length)throw RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,t,n){[e,t]=GC(this,e,t);let r=[];return this.decompose(0,e,r,2),n.length&&n.decompose(0,n.length,r,3),this.decompose(t,this.length,r,1),zC.from(r,this.length-(t-e)+n.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,t=this.length){[e,t]=GC(this,e,t);let n=[];return this.decompose(e,t,n,0),zC.from(n,t-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let t=this.scanIdentical(e,1),n=this.length-this.scanIdentical(e,-1),r=new HC(this),i=new HC(e);for(let e=t,a=t;;){if(r.next(e),i.next(e),e=0,r.lineBreak!=i.lineBreak||r.done!=i.done||r.value!=i.value)return!1;if(a+=r.value.length,r.done||a>=n)return!0}}iter(e=1){return new HC(this,e)}iterRange(e,t=this.length){return new UC(this,e,t)}iterLines(e,t){let n;if(e==null)n=this.iter();else{t??=this.lines+1;let r=this.line(e).from;n=this.iterRange(r,Math.max(r,t==this.lines+1?this.length:t<=1?0:this.line(t-1).to))}return new WC(n)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(t){if(t.length==0)throw RangeError(`A document must have at least one line`);return t.length==1&&!t[0]?e.empty:t.length<=32?new RC(t):zC.from(RC.split(t,[]))}},RC=class e extends LC{constructor(e,t=Kee(e)){super(),this.text=e,this.length=t}get lines(){return this.text.length}get children(){return null}lineInner(e,t,n,r){for(let i=0;;i++){let a=this.text[i],o=r+a.length;if((t?n:o)>=e)return new qee(r,o,n,a);r=o+1,n++}}decompose(t,n,r,i){let a=t<=0&&n>=this.length?this:new e(VC(this.text,t,n),Math.min(n,this.length)-Math.max(0,t));if(i&1){let t=r.pop(),n=BC(a.text,t.text.slice(),0,a.length);if(n.length<=32)r.push(new e(n,t.length+a.length));else{let t=n.length>>1;r.push(new e(n.slice(0,t)),new e(n.slice(t)))}}else r.push(a)}replace(t,n,r){if(!(r instanceof e))return super.replace(t,n,r);[t,n]=GC(this,t,n);let i=BC(this.text,BC(r.text,VC(this.text,0,t)),n),a=this.length+r.length-(n-t);return i.length<=32?new e(i,a):zC.from(e.split(i,[]),a)}sliceString(e,t=this.length,n=`
|
|
23
|
+
`){[e,t]=GC(this,e,t);let r=``;for(let i=0,a=0;i<=t&&a<this.text.length;a++){let o=this.text[a],s=i+o.length;i>e&&a&&(r+=n),e<s&&t>i&&(r+=o.slice(Math.max(0,e-i),t-i)),i=s+1}return r}flatten(e){for(let t of this.text)e.push(t)}scanIdentical(){return 0}static split(t,n){let r=[],i=-1;for(let a of t)r.push(a),i+=a.length+1,r.length==32&&(n.push(new e(r,i)),r=[],i=-1);return i>-1&&n.push(new e(r,i)),n}},zC=class e extends LC{constructor(e,t){super(),this.children=e,this.length=t,this.lines=0;for(let t of e)this.lines+=t.lines}lineInner(e,t,n,r){for(let i=0;;i++){let a=this.children[i],o=r+a.length,s=n+a.lines-1;if((t?s:o)>=e)return a.lineInner(e,t,n,r);r=o+1,n=s+1}}decompose(e,t,n,r){for(let i=0,a=0;a<=t&&i<this.children.length;i++){let o=this.children[i],s=a+o.length;if(e<=s&&t>=a){let i=r&(a<=e|(s>=t?2:0));a>=e&&s<=t&&!i?n.push(o):o.decompose(e-a,t-a,n,i)}a=s+1}}replace(t,n,r){if([t,n]=GC(this,t,n),r.lines<this.lines)for(let i=0,a=0;i<this.children.length;i++){let o=this.children[i],s=a+o.length;if(t>=a&&n<=s){let c=o.replace(t-a,n-a,r),l=this.lines-o.lines+c.lines;if(c.lines<l>>4&&c.lines>l>>6){let a=this.children.slice();return a[i]=c,new e(a,this.length-(n-t)+r.length)}return super.replace(a,s,c)}a=s+1}return super.replace(t,n,r)}sliceString(e,t=this.length,n=`
|
|
24
|
+
`){[e,t]=GC(this,e,t);let r=``;for(let i=0,a=0;i<this.children.length&&a<=t;i++){let o=this.children[i],s=a+o.length;a>e&&i&&(r+=n),e<s&&t>a&&(r+=o.sliceString(e-a,t-a,n)),a=s+1}return r}flatten(e){for(let t of this.children)t.flatten(e)}scanIdentical(t,n){if(!(t instanceof e))return 0;let r=0,[i,a,o,s]=n>0?[0,0,this.children.length,t.children.length]:[this.children.length-1,t.children.length-1,-1,-1];for(;;i+=n,a+=n){if(i==o||a==s)return r;let e=this.children[i],c=t.children[a];if(e!=c)return r+e.scanIdentical(c,n);r+=e.length+1}}static from(t,n=t.reduce((e,t)=>e+t.length+1,-1)){let r=0;for(let e of t)r+=e.lines;if(r<32){let e=[];for(let n of t)n.flatten(e);return new RC(e,n)}let i=Math.max(32,r>>5),a=i<<1,o=i>>1,s=[],c=0,l=-1,u=[];function d(t){let n;if(t.lines>a&&t instanceof e)for(let e of t.children)d(e);else t.lines>o&&(c>o||!c)?(f(),s.push(t)):t instanceof RC&&c&&(n=u[u.length-1])instanceof RC&&t.lines+n.lines<=32?(c+=t.lines,l+=t.length+1,u[u.length-1]=new RC(n.text.concat(t.text),n.length+1+t.length)):(c+t.lines>i&&f(),c+=t.lines,l+=t.length+1,u.push(t))}function f(){c!=0&&(s.push(u.length==1?u[0]:e.from(u,l)),l=-1,c=u.length=0)}for(let e of t)d(e);return f(),s.length==1?s[0]:new e(s,n)}};LC.empty=new RC([``],0);function Kee(e){let t=-1;for(let n of e)t+=n.length+1;return t}function BC(e,t,n=0,r=1e9){for(let i=0,a=0,o=!0;a<e.length&&i<=r;a++){let s=e[a],c=i+s.length;c>=n&&(c>r&&(s=s.slice(0,r-i)),i<n&&(s=s.slice(n-i)),o?(t[t.length-1]+=s,o=!1):t.push(s)),i=c+1}return t}function VC(e,t,n){return BC(e,[``],t,n)}var HC=class{constructor(e,t=1){this.dir=t,this.done=!1,this.lineBreak=!1,this.value=``,this.nodes=[e],this.offsets=[t>0?1:(e instanceof RC?e.text.length:e.children.length)<<1]}nextInner(e,t){for(this.done=this.lineBreak=!1;;){let n=this.nodes.length-1,r=this.nodes[n],i=this.offsets[n],a=i>>1,o=r instanceof RC?r.text.length:r.children.length;if(a==(t>0?o:0)){if(n==0)return this.done=!0,this.value=``,this;t>0&&this.offsets[n-1]++,this.nodes.pop(),this.offsets.pop()}else if((i&1)==(t>0?0:1)){if(this.offsets[n]+=t,e==0)return this.lineBreak=!0,this.value=`
|
|
25
|
+
`,this;e--}else if(r instanceof RC){let i=r.text[a+(t<0?-1:0)];if(this.offsets[n]+=t,i.length>Math.max(0,e))return this.value=e==0?i:t>0?i.slice(e):i.slice(0,i.length-e),this;e-=i.length}else{let i=r.children[a+(t<0?-1:0)];e>i.length?(e-=i.length,this.offsets[n]+=t):(t<0&&this.offsets[n]--,this.nodes.push(i),this.offsets.push(t>0?1:(i instanceof RC?i.text.length:i.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}},UC=class{constructor(e,t,n){this.value=``,this.done=!1,this.cursor=new HC(e,t>n?-1:1),this.pos=t>n?e.length:0,this.from=Math.min(t,n),this.to=Math.max(t,n)}nextInner(e,t){if(t<0?this.pos<=this.from:this.pos>=this.to)return this.value=``,this.done=!0,this;e+=Math.max(0,t<0?this.pos-this.to:this.from-this.pos);let n=t<0?this.pos-this.from:this.to-this.pos;e>n&&(e=n),n-=e;let{value:r}=this.cursor.next(e);return this.pos+=(r.length+e)*t,this.value=r.length<=n?r:t<0?r.slice(r.length-n):r.slice(0,n),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=``}},WC=class{constructor(e){this.inner=e,this.afterBreak=!0,this.value=``,this.done=!1}next(e=0){let{done:t,lineBreak:n,value:r}=this.inner.next(e);return t&&this.afterBreak?(this.value=``,this.afterBreak=!1):t?(this.done=!0,this.value=``):n?this.afterBreak?this.value=``:(this.afterBreak=!0,this.next()):(this.value=r,this.afterBreak=!1),this}get lineBreak(){return!1}};typeof Symbol<`u`&&(LC.prototype[Symbol.iterator]=function(){return this.iter()},HC.prototype[Symbol.iterator]=UC.prototype[Symbol.iterator]=WC.prototype[Symbol.iterator]=function(){return this});var qee=class{constructor(e,t,n,r){this.from=e,this.to=t,this.number=n,this.text=r}get length(){return this.to-this.from}};function GC(e,t,n){return t=Math.max(0,Math.min(e.length,t)),[t,Math.max(t,Math.min(e.length,n))]}function KC(e,t,n=!0,r=!0){return Wee(e,t,n,r)}function Jee(e){return e>=56320&&e<57344}function Yee(e){return e>=55296&&e<56320}function Xee(e,t){let n=e.charCodeAt(t);if(!Yee(n)||t+1==e.length)return n;let r=e.charCodeAt(t+1);return Jee(r)?(n-55296<<10)+(r-56320)+65536:n}function Zee(e){return e<65536?1:2}var qC=/\r\n?|\n/,JC=(function(e){return e[e.Simple=0]=`Simple`,e[e.TrackDel=1]=`TrackDel`,e[e.TrackBefore=2]=`TrackBefore`,e[e.TrackAfter=3]=`TrackAfter`,e})(JC||={}),YC=class e{constructor(e){this.sections=e}get length(){let e=0;for(let t=0;t<this.sections.length;t+=2)e+=this.sections[t];return e}get newLength(){let e=0;for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t+1];e+=n<0?this.sections[t]:n}return e}get empty(){return this.sections.length==0||this.sections.length==2&&this.sections[1]<0}iterGaps(e){for(let t=0,n=0,r=0;t<this.sections.length;){let i=this.sections[t++],a=this.sections[t++];a<0?(e(n,r,i),r+=i):r+=a,n+=i}}iterChangedRanges(e,t=!1){$C(this,e,t)}get invertedDesc(){let t=[];for(let e=0;e<this.sections.length;){let n=this.sections[e++],r=this.sections[e++];r<0?t.push(n,r):t.push(r,n)}return new e(t)}composeDesc(e){return this.empty?e:e.empty?this:tw(this,e)}mapDesc(e,t=!1){return e.empty?this:ew(this,e,t)}mapPos(e,t=-1,n=JC.Simple){let r=0,i=0;for(let a=0;a<this.sections.length;){let o=this.sections[a++],s=this.sections[a++],c=r+o;if(s<0){if(c>e)return i+(e-r);i+=o}else{if(n!=JC.Simple&&c>=e&&(n==JC.TrackDel&&r<e&&c>e||n==JC.TrackBefore&&r<e||n==JC.TrackAfter&&c>e))return null;if(c>e||c==e&&t<0&&!o)return e==r||t<0?i:i+s;i+=s}r=c}if(e>r)throw RangeError(`Position ${e} is out of range for changeset of length ${r}`);return i}touchesRange(e,t=e){for(let n=0,r=0;n<this.sections.length&&r<=t;){let i=this.sections[n++],a=this.sections[n++],o=r+i;if(a>=0&&r<=t&&o>=e)return r<e&&o>t?`cover`:!0;r=o}return!1}toString(){let e=``;for(let t=0;t<this.sections.length;){let n=this.sections[t++],r=this.sections[t++];e+=(e?` `:``)+n+(r>=0?`:`+r:``)}return e}toJSON(){return this.sections}static fromJSON(t){if(!Array.isArray(t)||t.length%2||t.some(e=>typeof e!=`number`))throw RangeError(`Invalid JSON representation of ChangeDesc`);return new e(t)}static create(t){return new e(t)}},XC=class e extends YC{constructor(e,t){super(e),this.inserted=t}apply(e){if(this.length!=e.length)throw RangeError(`Applying change set to a document with the wrong length`);return $C(this,(t,n,r,i,a)=>e=e.replace(r,r+(n-t),a),!1),e}mapDesc(e,t=!1){return ew(this,e,t,!0)}invert(t){let n=this.sections.slice(),r=[];for(let e=0,i=0;e<n.length;e+=2){let a=n[e],o=n[e+1];if(o>=0){n[e]=o,n[e+1]=a;let s=e>>1;for(;r.length<s;)r.push(LC.empty);r.push(a?t.slice(i,i+a):LC.empty)}i+=a}return new e(n,r)}compose(e){return this.empty?e:e.empty?this:tw(this,e,!0)}map(e,t=!1){return e.empty?this:ew(this,e,t,!0)}iterChanges(e,t=!1){$C(this,e,t)}get desc(){return YC.create(this.sections)}filter(t){let n=[],r=[],i=[],a=new nw(this);done:for(let e=0,o=0;;){let s=e==t.length?1e9:t[e++];for(;o<s||o==s&&a.len==0;){if(a.done)break done;let e=Math.min(a.len,s-o);ZC(i,e,-1);let t=a.ins==-1?-1:a.off==0?a.ins:0;ZC(n,e,t),t>0&&QC(r,n,a.text),a.forward(e),o+=e}let c=t[e++];for(;o<c;){if(a.done)break done;let e=Math.min(a.len,c-o);ZC(n,e,-1),ZC(i,e,a.ins==-1?-1:a.off==0?a.ins:0),a.forward(e),o+=e}}return{changes:new e(n,r),filtered:YC.create(i)}}toJSON(){let e=[];for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t],r=this.sections[t+1];r<0?e.push(n):r==0?e.push([n]):e.push([n].concat(this.inserted[t>>1].toJSON()))}return e}static of(t,n,r){let i=[],a=[],o=0,s=null;function c(t=!1){if(!t&&!i.length)return;o<n&&ZC(i,n-o,-1);let r=new e(i,a);s=s?s.compose(r.map(s)):r,i=[],a=[],o=0}function l(t){if(Array.isArray(t))for(let e of t)l(e);else if(t instanceof e){if(t.length!=n)throw RangeError(`Mismatched change set length (got ${t.length}, expected ${n})`);c(),s=s?s.compose(t.map(s)):t}else{let{from:e,to:s=e,insert:l}=t;if(e>s||e<0||s>n)throw RangeError(`Invalid change range ${e} to ${s} (in doc of length ${n})`);let u=l?typeof l==`string`?LC.of(l.split(r||qC)):l:LC.empty,d=u.length;if(e==s&&d==0)return;e<o&&c(),e>o&&ZC(i,e-o,-1),ZC(i,s-e,d),QC(a,i,u),o=s}}return l(t),c(!s),s}static empty(t){return new e(t?[t,-1]:[],[])}static fromJSON(t){if(!Array.isArray(t))throw RangeError(`Invalid JSON representation of ChangeSet`);let n=[],r=[];for(let e=0;e<t.length;e++){let i=t[e];if(typeof i==`number`)n.push(i,-1);else if(!Array.isArray(i)||typeof i[0]!=`number`||i.some((e,t)=>t&&typeof e!=`string`))throw RangeError(`Invalid JSON representation of ChangeSet`);else if(i.length==1)n.push(i[0],0);else{for(;r.length<e;)r.push(LC.empty);r[e]=LC.of(i.slice(1)),n.push(i[0],r[e].length)}}return new e(n,r)}static createSet(t,n){return new e(t,n)}};function ZC(e,t,n,r=!1){if(t==0&&n<=0)return;let i=e.length-2;i>=0&&n<=0&&n==e[i+1]?e[i]+=t:i>=0&&t==0&&e[i]==0?e[i+1]+=n:r?(e[i]+=t,e[i+1]+=n):e.push(t,n)}function QC(e,t,n){if(n.length==0)return;let r=t.length-2>>1;if(r<e.length)e[e.length-1]=e[e.length-1].append(n);else{for(;e.length<r;)e.push(LC.empty);e.push(n)}}function $C(e,t,n){let r=e.inserted;for(let i=0,a=0,o=0;o<e.sections.length;){let s=e.sections[o++],c=e.sections[o++];if(c<0)i+=s,a+=s;else{let l=i,u=a,d=LC.empty;for(;l+=s,u+=c,c&&r&&(d=d.append(r[o-2>>1])),!(n||o==e.sections.length||e.sections[o+1]<0);)s=e.sections[o++],c=e.sections[o++];t(i,l,a,u,d),i=l,a=u}}}function ew(e,t,n,r=!1){let i=[],a=r?[]:null,o=new nw(e),s=new nw(t);for(let e=-1;;)if(o.done&&s.len||s.done&&o.len)throw Error(`Mismatched change set lengths`);else if(o.ins==-1&&s.ins==-1){let e=Math.min(o.len,s.len);ZC(i,e,-1),o.forward(e),s.forward(e)}else if(s.ins>=0&&(o.ins<0||e==o.i||o.off==0&&(s.len<o.len||s.len==o.len&&!n))){let t=s.len;for(ZC(i,s.ins,-1);t;){let n=Math.min(o.len,t);o.ins>=0&&e<o.i&&o.len<=n&&(ZC(i,0,o.ins),a&&QC(a,i,o.text),e=o.i),o.forward(n),t-=n}s.next()}else if(o.ins>=0){let t=0,n=o.len;for(;n;)if(s.ins==-1){let e=Math.min(n,s.len);t+=e,n-=e,s.forward(e)}else if(s.ins==0&&s.len<n)n-=s.len,s.next();else break;ZC(i,t,e<o.i?o.ins:0),a&&e<o.i&&QC(a,i,o.text),e=o.i,o.forward(o.len-n)}else if(o.done&&s.done)return a?XC.createSet(i,a):YC.create(i);else throw Error(`Mismatched change set lengths`)}function tw(e,t,n=!1){let r=[],i=n?[]:null,a=new nw(e),o=new nw(t);for(let e=!1;;)if(a.done&&o.done)return i?XC.createSet(r,i):YC.create(r);else if(a.ins==0)ZC(r,a.len,0,e),a.next();else if(o.len==0&&!o.done)ZC(r,0,o.ins,e),i&&QC(i,r,o.text),o.next();else if(a.done||o.done)throw Error(`Mismatched change set lengths`);else{let t=Math.min(a.len2,o.len),n=r.length;if(a.ins==-1){let n=o.ins==-1?-1:o.off?0:o.ins;ZC(r,t,n,e),i&&n&&QC(i,r,o.text)}else o.ins==-1?(ZC(r,a.off?0:a.len,t,e),i&&QC(i,r,a.textBit(t))):(ZC(r,a.off?0:a.len,o.off?0:o.ins,e),i&&!o.off&&QC(i,r,o.text));e=(a.ins>t||o.ins>=0&&o.len>t)&&(e||r.length>n),a.forward2(t),o.forward(t)}}var nw=class{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return this.ins==-2}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,t=this.i-2>>1;return t>=e.length?LC.empty:e[t]}textBit(e){let{inserted:t}=this.set,n=this.i-2>>1;return n>=t.length&&!e?LC.empty:t[n].slice(this.off,e==null?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){this.ins==-1?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}},rw=class e{constructor(e,t,n,r){this.from=e,this.to=t,this.flags=n,this.goalColumn=r}get anchor(){return this.flags&32?this.to:this.from}get head(){return this.flags&32?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&8?-1:this.flags&16?1:0}get undirectional(){return(this.flags&64)>0}get bidiLevel(){let e=this.flags&7;return e==7?null:e}map(t,n=-1){let r,i;return this.empty?r=i=t.mapPos(this.from,n):(r=t.mapPos(this.from,1),i=t.mapPos(this.to,-1)),r==this.from&&i==this.to?this:new e(r,i,this.flags,this.goalColumn)}extend(e,t=e,n=0){if(e<=this.anchor&&t>=this.anchor)return K.range(e,t,void 0,void 0,n);let r=Math.abs(e-this.anchor)>Math.abs(t-this.anchor)?e:t;return K.range(this.anchor,r,void 0,void 0,n)}eq(e,t=!1){return this.anchor==e.anchor&&this.head==e.head&&this.goalColumn==e.goalColumn&&(!t||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||typeof e.anchor!=`number`||typeof e.head!=`number`)throw RangeError(`Invalid JSON representation for SelectionRange`);return K.range(e.anchor,e.head)}static create(t,n,r,i){return new e(t,n,r,i)}},K=class e{constructor(e,t){this.ranges=e,this.mainIndex=t}map(t,n=-1){return t.empty?this:e.create(this.ranges.map(e=>e.map(t,n)),this.mainIndex)}eq(e,t=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let n=0;n<this.ranges.length;n++)if(!this.ranges[n].eq(e.ranges[n],t))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return this.ranges.length==1?this:new e([this.main],0)}addRange(t,n=!0){return e.create([t].concat(this.ranges),n?0:this.mainIndex+1)}replaceRange(t,n=this.mainIndex){let r=this.ranges.slice();return r[n]=t,e.create(r,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(t){if(!t||!Array.isArray(t.ranges)||typeof t.main!=`number`||t.main>=t.ranges.length)throw RangeError(`Invalid JSON representation for EditorSelection`);return new e(t.ranges.map(e=>rw.fromJSON(e)),t.main)}static single(t,n=t){return new e([e.range(t,n)],0)}static create(t,n=0){if(t.length==0)throw RangeError(`A selection needs at least one range`);for(let r=0,i=0;i<t.length;i++){let a=t[i];if(a.empty?a.from<=r:a.from<r)return e.normalized(t.slice(),n);r=a.to}return new e(t,n)}static cursor(e,t=0,n,r){return rw.create(e,e,(t==0?0:t<0?8:16)|(n==null?7:Math.min(6,n)),r)}static range(e,t,n,r,i){let a=r==null?7:Math.min(6,r);return!i&&e!=t&&(i=t<e?1:-1),i&&(a|=i<0?8:16),t<e?rw.create(t,e,a|32,n):rw.create(e,t,a,n)}static undirectionalRange(e,t){return rw.create(e,t,64,void 0)}static normalized(t,n=0){let r=t[n];t.sort((e,t)=>e.from-t.from),n=t.indexOf(r);for(let r=1;r<t.length;r++){let i=t[r],a=t[r-1];if(i.empty?i.from<=a.to:i.from<a.to){let o=a.from,s=Math.max(i.to,a.to);r<=n&&n--,t.splice(--r,2,i.anchor>i.head?e.range(s,o):e.range(o,s))}}return new e(t,n)}};function iw(e,t){for(let n of e.ranges)if(n.to>t)throw RangeError(`Selection points outside of document`)}var aw=0,ow=class e{constructor(e,t,n,r,i){this.combine=e,this.compareInput=t,this.compare=n,this.isStatic=r,this.id=aw++,this.default=e([]),this.extensions=typeof i==`function`?i(this):i}get reader(){return this}static define(t={}){return new e(t.combine||(e=>e),t.compareInput||((e,t)=>e===t),t.compare||(t.combine?(e,t)=>e===t:sw),!!t.static,t.enables)}of(e){return new cw([],this,0,e)}compute(e,t){if(this.isStatic)throw Error(`Can't compute a static facet`);return new cw(e,this,1,t)}computeN(e,t){if(this.isStatic)throw Error(`Can't compute a static facet`);return new cw(e,this,2,t)}from(e,t){return t||=e=>e,this.compute([e],n=>t(n.field(e)))}};function sw(e,t){return e==t||e.length==t.length&&e.every((e,n)=>e===t[n])}var cw=class{constructor(e,t,n,r){this.dependencies=e,this.facet=t,this.type=n,this.value=r,this.id=aw++}dynamicSlot(e){let t=this.value,n=this.facet.compareInput,r=this.id,i=e[r]>>1,a=this.type==2,o=!1,s=!1,c=[];for(let t of this.dependencies)t==`doc`?o=!0:t==`selection`?s=!0:(e[t.id]??1)&1||c.push(e[t.id]);return{create(e){return e.values[i]=t(e),1},update(e,r){if(o&&r.docChanged||s&&(r.docChanged||r.selection)||uw(e,c)){let r=t(e);if(a?!lw(r,e.values[i],n):!n(r,e.values[i]))return e.values[i]=r,1}return 0},reconfigure:(e,o)=>{let s,c=o.config.address[r];if(c!=null){let r=Cw(o,c);if(this.dependencies.every(t=>t instanceof ow?o.facet(t)===e.facet(t):t instanceof pw?o.field(t,!1)==e.field(t,!1):!0)||(a?lw(s=t(e),r,n):n(s=t(e),r)))return e.values[i]=r,0}else s=t(e);return e.values[i]=s,1}}}get extension(){return this}};function lw(e,t,n){if(e.length!=t.length)return!1;for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!1;return!0}function uw(e,t){let n=!1;for(let r of t)Sw(e,r)&1&&(n=!0);return n}function dw(e,t,n){let r=n.map(t=>e[t.id]),i=n.map(e=>e.type),a=r.filter(e=>!(e&1)),o=e[t.id]>>1;function s(e){let n=[];for(let t=0;t<r.length;t++){let a=Cw(e,r[t]);if(i[t]==2)for(let e of a)n.push(e);else n.push(a)}return t.combine(n)}return{create(e){for(let t of r)Sw(e,t);return e.values[o]=s(e),1},update(e,n){if(!uw(e,a))return 0;let r=s(e);return t.compare(r,e.values[o])?0:(e.values[o]=r,1)},reconfigure(e,i){let a=uw(e,r),c=i.config.facets[t.id],l=i.facet(t);if(c&&!a&&sw(n,c))return e.values[o]=l,0;let u=s(e);return t.compare(u,l)?(e.values[o]=l,0):(e.values[o]=u,1)}}}var fw=ow.define({static:!0}),pw=class e{constructor(e,t,n,r,i){this.id=e,this.createF=t,this.updateF=n,this.compareF=r,this.spec=i,this.provides=void 0}static define(t){let n=new e(aw++,t.create,t.update,t.compare||((e,t)=>e===t),t);return t.provide&&(n.provides=t.provide(n)),n}create(e){return(e.facet(fw).find(e=>e.field==this)?.create||this.createF)(e)}slot(e){let t=e[this.id]>>1;return{create:e=>(e.values[t]=this.create(e),1),update:(e,n)=>{let r=e.values[t],i=this.updateF(r,n);return this.compareF(r,i)?0:(e.values[t]=i,1)},reconfigure:(e,n)=>{let r=e.facet(fw),i=n.facet(fw),a;return(a=r.find(e=>e.field==this))&&a!=i.find(e=>e.field==this)?(e.values[t]=a.create(e),1):n.config.address[this.id]==null?(e.values[t]=this.create(e),1):(e.values[t]=n.field(this),0)}}}init(e){return[this,fw.of({field:this,create:e})]}get extension(){return this}},mw={lowest:4,low:3,default:2,high:1,highest:0};function hw(e){return t=>new _w(t,e)}var gw={highest:hw(mw.highest),high:hw(mw.high),default:hw(mw.default),low:hw(mw.low),lowest:hw(mw.lowest)},_w=class{constructor(e,t){this.inner=e,this.prec=t}get extension(){return this}},vw=class e{of(e){return new yw(this,e)}reconfigure(t){return e.reconfigure.of({compartment:this,extension:t})}get(e){return e.config.compartments.get(this)}},yw=class{constructor(e,t){this.compartment=e,this.inner=t}get extension(){return this}},bw=class e{constructor(e,t,n,r,i,a){for(this.base=e,this.compartments=t,this.dynamicSlots=n,this.address=r,this.staticValues=i,this.facets=a,this.statusTemplate=[];this.statusTemplate.length<n.length;)this.statusTemplate.push(0)}staticFacet(e){let t=this.address[e.id];return t==null?e.default:this.staticValues[t>>1]}static resolve(t,n,r){let i=[],a=Object.create(null),o=new Map;for(let e of xw(t,n,o))e instanceof pw?i.push(e):(a[e.facet.id]||(a[e.facet.id]=[])).push(e);let s=Object.create(null),c=[],l=[];for(let e of i)s[e.id]=l.length<<1,l.push(t=>e.slot(t));let u=r?.config.facets;for(let e in a){let t=a[e],n=t[0].facet,i=u&&u[e]||[];if(t.every(e=>e.type==0)){if(s[n.id]=c.length<<1|1,sw(i,t))c.push(r.facet(n));else{let e=n.combine(t.map(e=>e.value));c.push(r&&n.compare(e,r.facet(n))?r.facet(n):e)}}else{for(let e of t)e.type==0?(s[e.id]=c.length<<1|1,c.push(e.value)):(s[e.id]=l.length<<1,l.push(t=>e.dynamicSlot(t)));s[n.id]=l.length<<1,l.push(e=>dw(e,n,t))}}let d=l.map(e=>e(s));return new e(t,o,d,s,c,a)}};function xw(e,t,n){let r=[[],[],[],[],[]],i=new Map;function a(e,o){let s=i.get(e);if(s!=null){if(s<=o)return;let t=r[s].indexOf(e);t>-1&&r[s].splice(t,1),e instanceof yw&&n.delete(e.compartment)}if(i.set(e,o),Array.isArray(e))for(let t of e)a(t,o);else if(e instanceof yw){if(n.has(e.compartment))throw RangeError(`Duplicate use of compartment in extensions`);let r=t.get(e.compartment)||e.inner;n.set(e.compartment,r),a(r,o)}else if(e instanceof _w)a(e.inner,e.prec);else if(e instanceof pw)r[o].push(e),e.provides&&a(e.provides,o);else if(e instanceof cw)r[o].push(e),e.facet.extensions&&a(e.facet.extensions,mw.default);else{let t=e.extension;if(!t)throw Error(`Unrecognized extension value in extension set (${e}).`);if(t==e)throw Error(`Unrecognized extension value in extension set (${e}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);a(t,o)}}return a(e,mw.default),r.reduce((e,t)=>e.concat(t))}function Sw(e,t){if(t&1)return 2;let n=t>>1,r=e.status[n];if(r==4)throw Error(`Cyclic dependency between fields and/or facets`);if(r&2)return r;e.status[n]=4;let i=e.computeSlot(e,e.config.dynamicSlots[n]);return e.status[n]=2|i}function Cw(e,t){return t&1?e.config.staticValues[t>>1]:e.values[t>>1]}var ww=ow.define(),Tw=ow.define({combine:e=>e.some(e=>e),static:!0}),Ew=ow.define({combine:e=>e.length?e[0]:void 0,static:!0}),Dw=ow.define(),Ow=ow.define(),kw=ow.define(),Aw=ow.define({combine:e=>e.length?e[0]:!1}),jw=class{constructor(e,t){this.type=e,this.value=t}static define(){return new Mw}},Mw=class{of(e){return new jw(this,e)}},Nw=class{constructor(e){this.map=e}of(e){return new Pw(this,e)}},Pw=class e{constructor(e,t){this.type=e,this.value=t}map(t){let n=this.type.map(this.value,t);return n===void 0?void 0:n==this.value?this:new e(this.type,n)}is(e){return this.type==e}static define(e={}){return new Nw(e.map||(e=>e))}static mapEffects(e,t){if(!e.length)return e;let n=[];for(let r of e){let e=r.map(t);e&&n.push(e)}return n}};Pw.reconfigure=Pw.define(),Pw.appendConfig=Pw.define();var Fw=class e{constructor(t,n,r,i,a,o){this.startState=t,this.changes=n,this.selection=r,this.effects=i,this.annotations=a,this.scrollIntoView=o,this._doc=null,this._state=null,r&&iw(r,n.newLength),a.some(t=>t.type==e.time)||(this.annotations=a.concat(e.time.of(Date.now())))}static create(t,n,r,i,a,o){return new e(t,n,r,i,a,o)}get newDoc(){return this._doc||=this.changes.apply(this.startState.doc)}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(e){for(let t of this.annotations)if(t.type==e)return t.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(t){let n=this.annotation(e.userEvent);return!!(n&&(n==t||n.length>t.length&&n.slice(0,t.length)==t&&n[t.length]==`.`))}};Fw.time=jw.define(),Fw.userEvent=jw.define(),Fw.addToHistory=jw.define(),Fw.remote=jw.define();function Iw(e,t){let n=[];for(let r=0,i=0;;){let a,o;if(r<e.length&&(i==t.length||t[i]>=e[r]))a=e[r++],o=e[r++];else if(i<t.length)a=t[i++],o=t[i++];else return n;!n.length||n[n.length-1]<a?n.push(a,o):n[n.length-1]<o&&(n[n.length-1]=o)}}function Lw(e,t,n){let r,i,a;return n?(r=t.changes,i=XC.empty(t.changes.length),a=e.changes.compose(t.changes)):(r=t.changes.map(e.changes),i=e.changes.mapDesc(t.changes,!0),a=e.changes.compose(r)),{changes:a,selection:t.selection?t.selection.map(i):e.selection?.map(r),effects:Pw.mapEffects(e.effects,r).concat(Pw.mapEffects(t.effects,i)),annotations:e.annotations.length?e.annotations.concat(t.annotations):t.annotations,scrollIntoView:e.scrollIntoView||t.scrollIntoView}}function Rw(e,t,n){let r=t.selection,i=Uw(t.annotations);return t.userEvent&&(i=i.concat(Fw.userEvent.of(t.userEvent))),{changes:t.changes instanceof XC?t.changes:XC.of(t.changes||[],n,e.facet(Ew)),selection:r&&(r instanceof K?r:K.single(r.anchor,r.head)),effects:Uw(t.effects),annotations:i,scrollIntoView:!!t.scrollIntoView}}function zw(e,t,n){let r=Rw(e,t.length?t[0]:{},e.doc.length);t.length&&t[0].filter===!1&&(n=!1);for(let i=1;i<t.length;i++){t[i].filter===!1&&(n=!1);let a=!!t[i].sequential;r=Lw(r,Rw(e,t[i],a?r.changes.newLength:e.doc.length),a)}let i=Fw.create(e,r.changes,r.selection,r.effects,r.annotations,r.scrollIntoView);return Vw(n?Bw(i):i)}function Bw(e){let t=e.startState,n=!0;for(let r of t.facet(Dw)){let t=r(e);if(t===!1){n=!1;break}Array.isArray(t)&&(n=n===!0?t:Iw(n,t))}if(n!==!0){let r,i;if(n===!1)i=e.changes.invertedDesc,r=XC.empty(t.doc.length);else{let t=e.changes.filter(n);r=t.changes,i=t.filtered.mapDesc(t.changes).invertedDesc}e=Fw.create(t,r,e.selection&&e.selection.map(i),Pw.mapEffects(e.effects,i),e.annotations,e.scrollIntoView)}let r=t.facet(Ow);for(let n=r.length-1;n>=0;n--){let i=r[n](e);e=i instanceof Fw?i:Array.isArray(i)&&i.length==1&&i[0]instanceof Fw?i[0]:zw(t,Uw(i),!1)}return e}function Vw(e){let t=e.startState,n=t.facet(kw),r=e;for(let i=n.length-1;i>=0;i--){let a=n[i](e);a&&Object.keys(a).length&&(r=Lw(r,Rw(t,a,e.changes.newLength),!0))}return r==e?e:Fw.create(t,e.changes,e.selection,r.effects,r.annotations,r.scrollIntoView)}var Hw=[];function Uw(e){return e==null?Hw:Array.isArray(e)?e:[e]}var Ww=(function(e){return e[e.Word=0]=`Word`,e[e.Space=1]=`Space`,e[e.Other=2]=`Other`,e})(Ww||={}),Gw=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,Kw;try{Kw=RegExp(`[\\p{Alphabetic}\\p{Number}_]`,`u`)}catch{}function qw(e){if(Kw)return Kw.test(e);for(let t=0;t<e.length;t++){let n=e[t];if(/\w/.test(n)||n>``&&(n.toUpperCase()!=n.toLowerCase()||Gw.test(n)))return!0}return!1}function Jw(e){return t=>{if(!/\S/.test(t))return Ww.Space;if(qw(t))return Ww.Word;for(let n=0;n<e.length;n++)if(t.indexOf(e[n])>-1)return Ww.Word;return Ww.Other}}var Yw=class e{constructor(e,t,n,r,i,a){this.config=e,this.doc=t,this.selection=n,this.values=r,this.status=e.statusTemplate.slice(),this.computeSlot=i,a&&(a._state=this);for(let e=0;e<this.config.dynamicSlots.length;e++)Sw(this,e<<1);this.computeSlot=null}field(e,t=!0){let n=this.config.address[e.id];if(n==null){if(t)throw RangeError(`Field is not present in this state`);return}return Sw(this,n),Cw(this,n)}update(...e){return zw(this,e,!0)}applyTransaction(t){let n=this.config,{base:r,compartments:i}=n;for(let e of t.effects)e.is(vw.reconfigure)?(n&&=(i=new Map,n.compartments.forEach((e,t)=>i.set(t,e)),null),i.set(e.value.compartment,e.value.extension)):e.is(Pw.reconfigure)?(n=null,r=e.value):e.is(Pw.appendConfig)&&(n=null,r=Uw(r).concat(e.value));let a;n?a=t.startState.values.slice():(n=bw.resolve(r,i,this),a=new e(n,this.doc,this.selection,n.dynamicSlots.map(()=>null),(e,t)=>t.reconfigure(e,this),null).values);let o=t.startState.facet(Tw)?t.newSelection:t.newSelection.asSingle();new e(n,t.newDoc,o,a,(e,n)=>n.update(e,t),t)}replaceSelection(e){return typeof e==`string`&&(e=this.toText(e)),this.changeByRange(t=>({changes:{from:t.from,to:t.to,insert:e},range:K.cursor(t.from+e.length,-1)}))}changeByRange(e){let t=this.selection,n=e(t.ranges[0]),r=this.changes(n.changes),i=[n.range],a=Uw(n.effects);for(let n=1;n<t.ranges.length;n++){let o=e(t.ranges[n]),s=this.changes(o.changes),c=s.map(r);for(let e=0;e<n;e++)i[e]=i[e].map(c);let l=r.mapDesc(s,!0);i.push(o.range.map(l)),r=r.compose(c),a=Pw.mapEffects(a,c).concat(Pw.mapEffects(Uw(o.effects),l))}return{changes:r,selection:K.create(i,t.mainIndex),effects:a}}changes(t=[]){return t instanceof XC?t:XC.of(t,this.doc.length,this.facet(e.lineSeparator))}toText(t){return LC.of(t.split(this.facet(e.lineSeparator)||qC))}sliceDoc(e=0,t=this.doc.length){return this.doc.sliceString(e,t,this.lineBreak)}facet(e){let t=this.config.address[e.id];return t==null?e.default:(Sw(this,t),Cw(this,t))}toJSON(e){let t={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(e)for(let n in e){let r=e[n];r instanceof pw&&this.config.address[r.id]!=null&&(t[n]=r.spec.toJSON(this.field(e[n]),this))}return t}static fromJSON(t,n={},r){if(!t||typeof t.doc!=`string`)throw RangeError(`Invalid JSON representation for EditorState`);let i=[];if(r){for(let e in r)if(Object.prototype.hasOwnProperty.call(t,e)){let n=r[e],a=t[e];i.push(n.init(e=>n.spec.fromJSON(a,e)))}}return e.create({doc:t.doc,selection:K.fromJSON(t.selection),extensions:n.extensions?i.concat([n.extensions]):i})}static create(t={}){let n=bw.resolve(t.extensions||[],new Map),r=t.doc instanceof LC?t.doc:LC.of((t.doc||``).split(n.staticFacet(e.lineSeparator)||qC)),i=t.selection?t.selection instanceof K?t.selection:K.single(t.selection.anchor,t.selection.head):K.single(0);return iw(i,r.length),n.staticFacet(Tw)||(i=i.asSingle()),new e(n,r,i,n.dynamicSlots.map(()=>null),(e,t)=>t.create(e),null)}get tabSize(){return this.facet(e.tabSize)}get lineBreak(){return this.facet(e.lineSeparator)||`
|
|
26
|
+
`}get readOnly(){return this.facet(Aw)}phrase(t,...n){for(let n of this.facet(e.phrases))if(Object.prototype.hasOwnProperty.call(n,t)){t=n[t];break}return n.length&&(t=t.replace(/\$(\$|\d*)/g,(e,t)=>{if(t==`$`)return`$`;let r=+(t||1);return!r||r>n.length?e:n[r-1]})),t}languageDataAt(e,t,n=-1){let r=[];for(let i of this.facet(ww))for(let a of i(this,t,n))Object.prototype.hasOwnProperty.call(a,e)&&r.push(a[e]);return r}charCategorizer(e){let t=this.languageDataAt(`wordChars`,e);return Jw(t.length?t[0]:``)}wordAt(e){let{text:t,from:n,length:r}=this.doc.lineAt(e),i=this.charCategorizer(e),a=e-n,o=e-n;for(;a>0;){let e=KC(t,a,!1);if(i(t.slice(e,a))!=Ww.Word)break;a=e}for(;o<r;){let e=KC(t,o);if(i(t.slice(o,e))!=Ww.Word)break;o=e}return a==o?null:K.range(a+n,o+n)}};Yw.allowMultipleSelections=Tw,Yw.tabSize=ow.define({combine:e=>e.length?e[0]:4}),Yw.lineSeparator=Ew,Yw.readOnly=Aw,Yw.phrases=ow.define({compare(e,t){let n=Object.keys(e),r=Object.keys(t);return n.length==r.length&&n.every(n=>e[n]==t[n])}}),Yw.languageData=ww,Yw.changeFilter=Dw,Yw.transactionFilter=Ow,Yw.transactionExtender=kw,vw.reconfigure=Pw.define();function Xw(e,t,n={}){let r={};for(let t of e)for(let e of Object.keys(t)){let i=t[e],a=r[e];if(a===void 0)r[e]=i;else if(a!==i&&i!==void 0){if(Object.hasOwnProperty.call(n,e))r[e]=n[e](a,i);else throw Error(`Config merge conflict for field `+e)}}for(let e in t)r[e]===void 0&&(r[e]=t[e]);return r}var Zw=class{eq(e){return this==e}range(e,t=e){return $w.create(e,t,this)}};Zw.prototype.startSide=Zw.prototype.endSide=0,Zw.prototype.point=!1,Zw.prototype.mapMode=JC.TrackDel;function Qw(e,t){return e==t||e.constructor==t.constructor&&e.eq(t)}var $w=class e{constructor(e,t,n){this.from=e,this.to=t,this.value=n}static create(t,n,r){return new e(t,n,r)}};function eT(e,t){return e.from-t.from||e.value.startSide-t.value.startSide}var tT=class e{constructor(e,t,n,r){this.from=e,this.to=t,this.value=n,this.maxPoint=r}get length(){return rT(this.to)}findIndex(e,t,n,r=0){let i=n?this.to:this.from;for(let a=r,o=i.length;;){if(a==o)return a;let r=a+o>>1,s=i[r]-e||(n?this.value[r].endSide:this.value[r].startSide)-t;if(r==a)return s>=0?a:o;s>=0?o=r:a=r+1}}between(e,t,n,r){for(let i=this.findIndex(t,-1e9,!0),a=this.findIndex(n,1e9,!1,i);i<a;i++)if(r(this.from[i]+e,this.to[i]+e,this.value[i])===!1)return!1}map(t,n,r,i,a){let o=[],s=[],c=[],l=-1,u=-1;iter:for(let e=0;e<this.value.length;e++){let d=this.value[e],f=this.from[e]+t,p=this.to[e]+t,m,h;if(f==p){let e=n.mapPos(f,d.startSide,d.mapMode);if(e==null||(m=h=e,d.startSide!=d.endSide&&(h=n.mapPos(f,d.endSide),h<m)))continue}else if(m=n.mapPos(f,d.startSide),h=n.mapPos(p,d.endSide),m>h||m==h&&d.startSide>0&&d.endSide<=0)continue;if(!((h-m||d.endSide-d.startSide)<0)){if(l<0&&(l=m),d.point&&(u=Math.max(u,h-m)),(m-r||d.startSide-i)>=0)o.push(d),s.push(m-l),c.push(h-l),r=h,i=d.endSide;else{if(m==h)for(let e=o.length;e>0;e--){if((m-(c[e-1]+l)||d.startSide-o[e-1].endSide)>=0){o.splice(e,0,d),s.splice(e,0,m-l),c.splice(e,0,h-l);continue iter}if((m-(s[e-1]+l)||d.endSide-o[e-1].startSide)>0)break}a(m,h,d)}}}return{mapped:o.length?new e(s,c,o,u):null,pos:l}}},nT=class e{constructor(e,t,n,r){this.chunkPos=e,this.chunk=t,this.nextLayer=n,this.maxPoint=r}static create(t,n,r,i){return new e(t,n,r,i)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let t of this.chunk)e+=t.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(t){let{add:n=[],sort:r=!1,filterFrom:i=0,filterTo:a=this.length}=t,o=t.filter;if(n.length==0&&!o)return this;if(r&&(n=n.slice().sort(eT)),this.isEmpty)return n.length?e.of(n):this;let s=new sT(this,null,-1).goto(0),c=0,l=[],u=new aT;for(;s.value||c<n.length;)if(c<n.length&&(s.from-n[c].from||s.startSide-n[c].value.startSide)>=0){let e=n[c++];u.addInner(e.from,e.to,e.value,!1)||l.push(e)}else s.rangeIndex==1&&s.chunkIndex<this.chunk.length&&(c==n.length||this.chunkEnd(s.chunkIndex)<n[c].from)&&(!o||i>this.chunkEnd(s.chunkIndex)||a<this.chunkPos[s.chunkIndex])&&u.addChunk(this.chunkPos[s.chunkIndex],this.chunk[s.chunkIndex])?s.nextChunk():((!o||i>s.to||a<s.from||o(s.from,s.to,s.value))&&(u.addInner(s.from,s.to,s.value,!1)||l.push($w.create(s.from,s.to,s.value))),s.next());return u.finishInner(this.nextLayer.isEmpty&&!l.length?e.empty:this.nextLayer.update({add:l,filter:o,filterFrom:i,filterTo:a}))}map(t){if(t.empty||this.isEmpty)return this;let n=[],r=[],i=-1,a,o=(e,t,n)=>{a||=new aT,a.addRange(e,t,n,!1)};for(let e=0;e<this.chunk.length;e++){let a=this.chunkPos[e],s=this.chunk[e],c=t.touchesRange(a,a+s.length);if(c===!1)i=Math.max(i,s.maxPoint),n.push(s),r.push(t.mapPos(a));else if(c===!0){let[e,c]=n.length?[rT(r)+rT(n).length,rT(rT(n).value).endSide]:[-1,-1],{mapped:l,pos:u}=s.map(a,t,e,c,o);l&&(i=Math.max(i,l.maxPoint),n.push(l),r.push(u))}}let s=this.nextLayer.map(t);return a&&(s=a.finishInner(s)),n.length==0?s:new e(r,n,s||e.empty,i)}between(e,t,n){if(!this.isEmpty){for(let r=0;r<this.chunk.length;r++){let i=this.chunkPos[r],a=this.chunk[r];if(t>=i&&e<=i+a.length&&a.between(i,e-i,t-i,n)===!1)return}this.nextLayer.between(e,t,n)}}iter(e=0){return cT.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,t=0){return cT.from(e).goto(t)}static compare(e,t,n,r,i=-1){let a=e.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),o=t.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),s=oT(a,o,n),c=new uT(a,s,i),l=new uT(o,s,i);n.iterGaps((e,t,n)=>dT(c,e,l,t,n,r)),n.empty&&n.length==0&&dT(c,0,l,0,0,r)}static eq(e,t,n=0,r){r??=1e9-1;let i=e.filter(e=>!e.isEmpty&&t.indexOf(e)<0),a=t.filter(t=>!t.isEmpty&&e.indexOf(t)<0);if(i.length!=a.length)return!1;if(!i.length)return!0;let o=oT(i,a),s=new uT(i,o,0).goto(n),c=new uT(a,o,0).goto(n);for(;;){if(s.to!=c.to||!fT(s.active,c.active)||s.point&&(!c.point||!Qw(s.point,c.point)))return!1;if(s.to>r)return!0;s.next(),c.next()}}static spans(e,t,n,r,i=-1){let a=new uT(e,null,i).goto(t),o=t,s=a.openStart;for(;;){let e=Math.min(a.to,n);if(a.point){let n=a.activeForPoint(a.to),i=a.pointFrom<t?n.length+1:a.point.startSide<0?n.length:Math.min(n.length,s);r.point(o,e,a.point,n,i,a.pointRank),s=Math.min(a.openEnd(e),n.length)}else e>o&&(r.span(o,e,a.active,s),s=a.openEnd(e));if(a.to>n)return s+(a.point&&a.to>n?1:0);o=a.to,a.next()}}static of(e,t=!1){let n=new aT;for(let r of e instanceof $w?[e]:t?iT(e):e)n.add(r.from,r.to,r.value);return n.finish()}static join(t){if(!t.length)return e.empty;let n=rT(t);for(let r=t.length-2;r>=0;r--)for(let i=t[r];i!=e.empty;i=i.nextLayer)n=new e(i.chunkPos,i.chunk,n,Math.max(i.maxPoint,n.maxPoint));return n}};nT.empty=new nT([],[],null,-1);function rT(e){return e[e.length-1]}function iT(e){if(e.length>1)for(let t=e[0],n=1;n<e.length;n++){let r=e[n];if(eT(t,r)>0)return e.slice().sort(eT);t=r}return e}nT.empty.nextLayer=nT.empty;var aT=class e{finishChunk(e){this.chunks.push(new tT(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,t,n){this.addRange(e,t,n,!0)}addRange(t,n,r,i){this.addInner(t,n,r,i)||(this.nextLayer||=new e).addRange(t,n,r,i)}addInner(e,t,n,r){let i=e-this.lastTo||n.startSide-this.last.endSide;if(r&&i<=0&&(e-this.lastFrom||n.startSide-this.last.startSide)<0)throw Error("Ranges must be added sorted by `from` position and `startSide`");return i<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(t-this.chunkStart),this.last=n,this.lastFrom=e,this.lastTo=t,this.value.push(n),n.point&&(this.maxPoint=Math.max(this.maxPoint,t-e)),!0)}addChunk(e,t){if((e-this.lastTo||t.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,t.maxPoint),this.chunks.push(t),this.chunkPos.push(e);let n=t.value.length-1;return this.last=t.value[n],this.lastFrom=t.from[n]+e,this.lastTo=t.to[n]+e,!0}finish(){return this.finishInner(nT.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return e;let t=nT.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,t}};function oT(e,t,n){let r=new Map;for(let t of e)for(let e=0;e<t.chunk.length;e++)t.chunk[e].maxPoint<=0&&r.set(t.chunk[e],t.chunkPos[e]);let i=new Set;for(let e of t)for(let t=0;t<e.chunk.length;t++){let a=r.get(e.chunk[t]);a!=null&&(n?n.mapPos(a):a)==e.chunkPos[t]&&!n?.touchesRange(a,a+e.chunk[t].length)&&i.add(e.chunk[t])}return i}var sT=class{constructor(e,t,n,r=0){this.layer=e,this.skip=t,this.minPoint=n,this.rank=r}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,t=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,t,!1),this}gotoInner(e,t,n){for(;this.chunkIndex<this.layer.chunk.length;){let t=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(t)||this.layer.chunkEnd(this.chunkIndex)<e||t.maxPoint<this.minPoint))break;this.chunkIndex++,n=!1}if(this.chunkIndex<this.layer.chunk.length){let r=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],t,!0);(!n||this.rangeIndex<r)&&this.setRangeIndex(r)}this.next()}forward(e,t){(this.to-e||this.endSide-t)<0&&this.gotoInner(e,t,!0)}next(){for(;;)if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}else{let e=this.layer.chunkPos[this.chunkIndex],t=this.layer.chunk[this.chunkIndex],n=e+t.from[this.rangeIndex];if(this.from=n,this.to=e+t.to[this.rangeIndex],this.value=t.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]);)this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}},cT=class e{constructor(e){this.heap=e}static from(t,n=null,r=-1){let i=[];for(let e=0;e<t.length;e++)for(let a=t[e];!a.isEmpty;a=a.nextLayer)a.maxPoint>=r&&i.push(new sT(a,n,r,e));return i.length==1?i[0]:new e(i)}get startSide(){return this.value?this.value.startSide:0}goto(e,t=-1e9){for(let n of this.heap)n.goto(e,t);for(let e=this.heap.length>>1;e>=0;e--)lT(this.heap,e);return this.next(),this}forward(e,t){for(let n of this.heap)n.forward(e,t);for(let e=this.heap.length>>1;e>=0;e--)lT(this.heap,e);(this.to-e||this.value.endSide-t)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),lT(this.heap,0)}}};function lT(e,t){for(let n=e[t];;){let r=(t<<1)+1;if(r>=e.length)break;let i=e[r];if(r+1<e.length&&i.compare(e[r+1])>=0&&(i=e[r+1],r++),n.compare(i)<0)break;e[r]=n,e[t]=i,t=r}}var uT=class{constructor(e,t,n){this.minPoint=n,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=cT.from(e,t,n)}goto(e,t=-1e9){return this.cursor.goto(e,t),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=t,this.openStart=-1,this.next(),this}forward(e,t){for(;this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-t)<0;)this.removeActive(this.minActive);this.cursor.forward(e,t)}removeActive(e){pT(this.active,e),pT(this.activeTo,e),pT(this.activeRank,e),this.minActive=hT(this.active,this.activeTo)}addActive(e){let t=0,{value:n,to:r,rank:i}=this.cursor;for(;t<this.activeRank.length&&(i-this.activeRank[t]||r-this.activeTo[t])>0;)t++;mT(this.active,t,n),mT(this.activeTo,t,r),mT(this.activeRank,t,i),e&&mT(e,t,this.cursor.from),this.minActive=hT(this.active,this.activeTo)}next(){let e=this.to,t=this.point;this.point=null;let n=this.openStart<0?[]:null;for(;;){let r=this.minActive;if(r>-1&&(this.activeTo[r]-this.cursor.from||this.active[r].endSide-this.cursor.startSide)<0){if(this.activeTo[r]>e){this.to=this.activeTo[r],this.endSide=this.active[r].endSide;break}this.removeActive(r),n&&pT(n,r)}else if(!this.cursor.value){this.to=this.endSide=1e9;break}else if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let e=this.cursor.value;if(!e.point)this.addActive(n),this.cursor.next();else if(t&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)this.cursor.next();else{this.point=e,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=e.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}}}if(n){this.openStart=0;for(let t=n.length-1;t>=0&&n[t]<e;t--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let t=[];for(let n=this.active.length-1;n>=0&&!(this.activeRank[n]<this.pointRank);n--)(this.activeTo[n]>e||this.activeTo[n]==e&&this.active[n].endSide>=this.point.endSide)&&t.push(this.active[n]);return t.reverse()}openEnd(e){let t=0;for(let n=this.activeTo.length-1;n>=0&&this.activeTo[n]>e;n--)t++;return t}};function dT(e,t,n,r,i,a){e.goto(t),n.goto(r);let o=r+i,s=r,c=r-t,l=!!a.boundChange;for(let t=!1;;){let r=e.to+c-n.to,i=r||e.endSide-n.endSide,u=i<0?e.to+c:n.to,d=Math.min(u,o);if(e.point||n.point?(e.point&&n.point&&Qw(e.point,n.point)&&fT(e.activeForPoint(e.to),n.activeForPoint(n.to))||a.comparePoint(s,d,e.point,n.point),t=!1):(t&&=(a.boundChange(s),!1),d>s&&!fT(e.active,n.active)&&a.compareRange(s,d,e.active,n.active),l&&d<o&&(r||e.openEnd(u)!=n.openEnd(u))&&(t=!0)),u>o)break;s=u,i<=0&&e.next(),i>=0&&n.next()}}function fT(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!=t[n]&&!Qw(e[n],t[n]))return!1;return!0}function pT(e,t){for(let n=t,r=e.length-1;n<r;n++)e[n]=e[n+1];e.pop()}function mT(e,t,n){for(let n=e.length-1;n>=t;n--)e[n+1]=e[n];e[t]=n}function hT(e,t){let n=-1,r=1e9;for(let i=0;i<t.length;i++)(t[i]-r||e[i].endSide-e[n].endSide)<0&&(n=i,r=t[i]);return n}function gT(e,t,n=e.length){let r=0;for(let i=0;i<n&&i<e.length;)e.charCodeAt(i)==9?(r+=t-r%t,i++):(r++,i=KC(e,i));return r}function _T(e,t,n,r){for(let r=0,i=0;;){if(i>=t)return r;if(r==e.length)break;i+=e.charCodeAt(r)==9?n-i%n:1,r=KC(e,r)}return r===!0?-1:e.length}for(var vT=`ͼ`,yT=typeof Symbol>`u`?`__ͼ`:Symbol.for(vT),bT=typeof Symbol>`u`?`__styleSet`+Math.floor(Math.random()*1e8):Symbol(`styleSet`),xT=typeof globalThis<`u`?globalThis:typeof window<`u`?window:{},ST=class{constructor(e,t){this.rules=[];let{finish:n}=t||{};function r(e){return/^@/.test(e)?[e]:e.split(/,\s*/)}function i(e,t,a,o){let s=[],c=/^@(\w+)\b/.exec(e[0]),l=c&&c[1]==`keyframes`;if(c&&t==null)return a.push(e[0]+`;`);for(let n in t){let o=t[n];if(/&/.test(n))i(n.split(/,\s*/).map(t=>e.map(e=>t.replace(/&/,e))).reduce((e,t)=>e.concat(t)),o,a);else if(o&&typeof o==`object`){if(!c)throw RangeError(`The value of a property (`+n+`) should be a primitive value.`);i(r(n),o,s,l)}else o!=null&&s.push(n.replace(/_.*/,``).replace(/[A-Z]/g,e=>`-`+e.toLowerCase())+`: `+o+`;`)}(s.length||l)&&a.push((n&&!c&&!o?e.map(n):e).join(`, `)+` {`+s.join(` `)+`}`)}for(let t in e)i(r(t),e[t],this.rules)}getRules(){return this.rules.join(`
|
|
27
|
+
`)}static newName(){let e=xT[yT]||1;return xT[yT]=e+1,vT+e.toString(36)}static mount(e,t,n){let r=e[bT],i=n&&n.nonce;r?i&&r.setNonce(i):r=new wT(e,i),r.mount(Array.isArray(t)?t:[t],e)}},CT=new Map,wT=class{constructor(e,t){let n=e.ownerDocument||e,r=n.defaultView;if(!e.head&&e.adoptedStyleSheets&&r.CSSStyleSheet){let t=CT.get(n);if(t)return e[bT]=t;this.sheet=new r.CSSStyleSheet,CT.set(n,this)}else this.styleTag=n.createElement(`style`),t&&this.styleTag.setAttribute(`nonce`,t);this.modules=[],e[bT]=this}mount(e,t){let n=this.sheet,r=0,i=0,a=!1;for(let t=0;t<e.length;t++){let o=e[t],s=this.modules.indexOf(o);if(s<i&&s>-1&&(this.modules.splice(s,1),a=!0,i--,s=-1),s==-1){if(this.modules.splice(i++,0,o),a=!0,n)for(let e=0;e<o.rules.length;e++)n.insertRule(o.rules[e],r++)}else{for(;i<s;)r+=this.modules[i++].rules.length;r+=o.rules.length,i++}}if(n)t.adoptedStyleSheets.indexOf(this.sheet)<0&&(t.adoptedStyleSheets=[this.sheet,...t.adoptedStyleSheets]);else{if(a){let e=``;for(let t=0;t<this.modules.length;t++)e+=this.modules[t].getRules()+`
|
|
28
|
+
`;this.styleTag.textContent=e}let e=t.head||t;this.styleTag.parentNode!=e&&e.insertBefore(this.styleTag,e.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute(`nonce`)!=e&&this.styleTag.setAttribute(`nonce`,e)}},TT={8:`Backspace`,9:`Tab`,10:`Enter`,12:`NumLock`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,44:`PrintScreen`,45:`Insert`,46:`Delete`,59:`;`,61:`=`,91:`Meta`,92:`Meta`,106:`*`,107:`+`,108:`,`,109:`-`,110:`.`,111:`/`,144:`NumLock`,145:`ScrollLock`,160:`Shift`,161:`Shift`,162:`Control`,163:`Control`,164:`Alt`,165:`Alt`,173:`-`,186:`;`,187:`=`,188:`,`,189:`-`,190:`.`,191:`/`,192:"`",219:`[`,220:`\\`,221:`]`,222:`'`},ET={48:`)`,49:`!`,50:`@`,51:`#`,52:`$`,53:`%`,54:`^`,55:`&`,56:`*`,57:`(`,59:`:`,61:`+`,173:`_`,186:`:`,187:`+`,188:`<`,189:`_`,190:`>`,191:`?`,192:`~`,219:`{`,220:`|`,221:`}`,222:`"`},DT=typeof navigator<`u`&&/Mac/.test(navigator.platform),OT=typeof navigator<`u`&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),kT=0;kT<10;kT++)TT[48+kT]=TT[96+kT]=String(kT);for(var kT=1;kT<=24;kT++)TT[kT+111]=`F`+kT;for(var kT=65;kT<=90;kT++)TT[kT]=String.fromCharCode(kT+32),ET[kT]=String.fromCharCode(kT);for(var AT in TT)ET.hasOwnProperty(AT)||(ET[AT]=TT[AT]);function jT(e){var t=!(DT&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||OT&&e.shiftKey&&e.key&&e.key.length==1||e.key==`Unidentified`)&&e.key||(e.shiftKey?ET:TT)[e.keyCode]||e.key||`Unidentified`;return t==`Esc`&&(t=`Escape`),t==`Del`&&(t=`Delete`),t==`Left`&&(t=`ArrowLeft`),t==`Up`&&(t=`ArrowUp`),t==`Right`&&(t=`ArrowRight`),t==`Down`&&(t=`ArrowDown`),t}var MT=typeof navigator<`u`?navigator:{userAgent:``,vendor:``,platform:``},NT=typeof document<`u`?document:{documentElement:{style:{}}},PT=/Edge\/(\d+)/.exec(MT.userAgent),FT=/MSIE \d/.test(MT.userAgent),IT=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(MT.userAgent),LT=!!(FT||IT||PT),RT=!LT&&/gecko\/(\d+)/i.test(MT.userAgent),zT=!LT&&/Chrome\/(\d+)/.exec(MT.userAgent),BT=`webkitFontSmoothing`in NT.documentElement.style,VT=!LT&&/Apple Computer/.test(MT.vendor),HT=VT&&(/Mobile\/\w+/.test(MT.userAgent)||MT.maxTouchPoints>2),q={mac:HT||/Mac/.test(MT.platform),windows:/Win/.test(MT.platform),linux:/Linux|X11/.test(MT.platform),ie:LT,ie_version:FT?NT.documentMode||6:IT?+IT[1]:PT?+PT[1]:0,gecko:RT,gecko_version:RT?+(/Firefox\/(\d+)/.exec(MT.userAgent)||[0,0])[1]:0,chrome:!!zT,chrome_version:zT?+zT[1]:0,ios:HT,android:/Android\b/.test(MT.userAgent),webkit:BT,webkit_version:BT?+(/\bAppleWebKit\/(\d+)/.exec(MT.userAgent)||[0,0])[1]:0,safari:VT,safari_version:VT?+(/\bVersion\/(\d+(\.\d+)?)/.exec(MT.userAgent)||[0,0])[1]:0,tabSize:NT.documentElement.style.tabSize==null?`-moz-tab-size`:`tab-size`};function UT(e,t){for(let n in e)n==`class`&&t.class?t.class+=` `+e.class:n==`style`&&t.style?t.style+=`;`+e.style:t[n]=e[n];return t}var WT=Object.create(null);function GT(e,t,n){if(e==t)return!0;e||=WT,t||=WT;let r=Object.keys(e),i=Object.keys(t);if(r.length-0!=i.length-0)return!1;for(let a of r)if(a!=n&&(i.indexOf(a)==-1||e[a]!==t[a]))return!1;return!0}function KT(e,t){for(let n=e.attributes.length-1;n>=0;n--){let r=e.attributes[n].name;t[r]??e.removeAttribute(r)}for(let n in t){let r=t[n];n==`style`?e.style.cssText=r:e.getAttribute(n)!=r&&e.setAttribute(n,r)}}function qT(e,t,n){let r=!1;if(t)for(let i in t)n&&i in n||(r=!0,i==`style`?e.style.cssText=``:e.removeAttribute(i));if(n)for(let i in n)t&&t[i]==n[i]||(r=!0,i==`style`?e.style.cssText=n[i]:e.setAttribute(i,n[i]));return r}function JT(e){let t=Object.create(null);for(let n=0;n<e.attributes.length;n++){let r=e.attributes[n];t[r.name]=r.value}return t}var YT=class{eq(e){return!1}updateDOM(e,t,n){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return-1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,t,n){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}},XT=(function(e){return e[e.Text=0]=`Text`,e[e.WidgetBefore=1]=`WidgetBefore`,e[e.WidgetAfter=2]=`WidgetAfter`,e[e.WidgetRange=3]=`WidgetRange`,e})(XT||={}),ZT=class extends Zw{constructor(e,t,n,r){super(),this.startSide=e,this.endSide=t,this.widget=n,this.spec=r}get heightRelevant(){return!1}static mark(e){return new QT(e)}static widget(e){let t=Math.max(-1e4,Math.min(1e4,e.side||0)),n=!!e.block;return t+=n&&!e.inlineOrder?t>0?3e8:-4e8:t>0?1e8:-1e8,new eE(e,t,t,n,e.widget||null,!1)}static replace(e){let t=!!e.block,n,r;if(e.isBlockGap)n=-5e8,r=4e8;else{let{start:i,end:a}=tE(e,t);n=(i?t?-3e8:-1:5e8)-1,r=(a?t?2e8:1:-6e8)+1}return new eE(e,n,r,t,e.widget||null,!0)}static line(e){return new $T(e)}static set(e,t=!1){return nT.of(e,t)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}};ZT.none=nT.empty;var QT=class e extends ZT{constructor(e){let{start:t,end:n}=tE(e);super(t?-1:5e8,n?1:-6e8,null,e),this.tagName=e.tagName||`span`,this.attrs=e.class&&e.attributes?UT(e.attributes,{class:e.class}):e.class?{class:e.class}:e.attributes||WT}eq(t){return this==t||t instanceof e&&this.tagName==t.tagName&>(this.attrs,t.attrs)}range(e,t=e){if(e>=t)throw RangeError(`Mark decorations may not be empty`);return super.range(e,t)}};QT.prototype.point=!1;var $T=class e extends ZT{constructor(e){super(-2e8,-2e8,null,e)}eq(t){return t instanceof e&&this.spec.class==t.spec.class&>(this.spec.attributes,t.spec.attributes)}range(e,t=e){if(t!=e)throw RangeError(`Line decoration ranges must be zero-length`);return super.range(e,t)}};$T.prototype.mapMode=JC.TrackBefore,$T.prototype.point=!0;var eE=class e extends ZT{constructor(e,t,n,r,i,a){super(t,n,i,e),this.block=r,this.isReplace=a,this.mapMode=r?t<=0?JC.TrackBefore:JC.TrackAfter:JC.TrackDel}get type(){return this.startSide==this.endSide?this.startSide<=0?XT.WidgetBefore:XT.WidgetAfter:XT.WidgetRange}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(t){return t instanceof e&&nE(this.widget,t.widget)&&this.block==t.block&&this.startSide==t.startSide&&this.endSide==t.endSide}range(e,t=e){if(this.isReplace&&(e>t||e==t&&this.startSide>0&&this.endSide<=0))throw RangeError(`Invalid range for replacement decoration`);if(!this.isReplace&&t!=e)throw RangeError(`Widget decorations can only have zero-length ranges`);return super.range(e,t)}};eE.prototype.point=!0;function tE(e,t=!1){let{inclusiveStart:n,inclusiveEnd:r}=e;return n??=e.inclusive,r??=e.inclusive,{start:n??t,end:r??t}}function nE(e,t){return e==t||!!(e&&t&&e.compare(t))}function rE(e,t,n,r=0){let i=n.length-1;i>=0&&n[i]+r>=e?n[i]=Math.max(n[i],t):n.push(e,t)}var iE=class e extends Zw{constructor(e,t,n){super(),this.tagName=e,this.attributes=t,this.rank=n}eq(t){return t==this||t instanceof e&&this.tagName==t.tagName&>(this.attributes,t.attributes)}static create(t){return new e(t.tagName,t.attributes||WT,t.rank==null?50:Math.max(0,Math.min(t.rank,100)))}static set(e,t=!1){return nT.of(e,t)}};iE.prototype.startSide=iE.prototype.endSide=-1;var aE=e=>e.nodeType==1,oE=e=>e.nodeType==3;function sE(e){let t;return t=e.nodeType==11?e.getSelection?e:e.ownerDocument:e,t.getSelection()}function cE(e,t){return t?e==t||e.contains(t.nodeType==1?t:t.parentNode):!1}function lE(e,t){if(!t.anchorNode)return!1;try{return cE(e,t.anchorNode)}catch{return!1}}function uE(e){return oE(e)?DE(e,0,e.nodeValue.length).getClientRects():aE(e)?e.getClientRects():[]}function dE(e,t,n,r){return n?mE(e,t,n,r,-1)||mE(e,t,n,r,1):!1}function fE(e){for(var t=0;;t++)if(e=e.previousSibling,!e)return t}function pE(e){return aE(e)&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(e.nodeName)}function mE(e,t,n,r,i){for(;;){if(e==n&&t==r)return!0;if(t==(i<0?0:hE(e))){if(e.nodeName==`DIV`)return!1;let n=e.parentNode;if(!n||!aE(n))return!1;t=fE(e)+(i<0?0:1),e=n}else if(aE(e)){if(e=e.childNodes[t+(i<0?-1:0)],aE(e)&&(e.nodeName==`IMG`||e.nodeName==`BR`||e.contentEditable==`false`))return!1;t=i<0?hE(e):0}else return!1}}function hE(e){return oE(e)?e.nodeValue.length:e.childNodes.length}function gE(e,t){let{left:n,right:r}=e;if(n==r)return e;let i=t?n:r;return{left:i,right:i,top:e.top,bottom:e.bottom}}function _E(e){let t=e.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.innerWidth,top:0,bottom:e.innerHeight}}function vE(e,t){let n=t.width/e.offsetWidth,r=t.height/e.offsetHeight;return(n>.995&&n<1.005||!isFinite(n)||Math.abs(t.width-e.offsetWidth)<1)&&(n=1),(r>.995&&r<1.005||!isFinite(r)||Math.abs(t.height-e.offsetHeight)<1)&&(r=1),{scaleX:n,scaleY:r}}function yE(e,t,n,r,i,a,o,s){let c=e.ownerDocument,l=c.defaultView||window;for(let u=e,d=!1;u&&!d;)if(aE(u)){let e,f=u==c.body,p=1,m=1,h=!0,g=!0;if(f)e=_E(l);else{let t=getComputedStyle(u);if(/^(fixed|sticky)$/.test(t.position)&&(d=!0),(u.scrollHeight<=u.clientHeight||!/auto|scroll/.test(t.overflowY))&&(g=!1),(u.scrollWidth<=u.clientWidth||!/auto|scroll/.test(t.overflowX))&&(h=!1),!h&&!g){u=u.assignedSlot||u.parentNode;continue}let n=u.getBoundingClientRect();({scaleX:p,scaleY:m}=vE(u,n)),e={left:n.left,right:n.left+u.clientWidth*p,top:n.top,bottom:n.top+u.clientHeight*m}}let _=0,v=0;if(g){if(i==`nearest`)t.top<e.top+o?(v=t.top-(e.top+o),n>0&&t.bottom>e.bottom+v&&(v=t.bottom-e.bottom+o)):t.bottom>e.bottom-o&&(v=t.bottom-e.bottom+o,n<0&&t.top-v<e.top&&(v=t.top-(e.top+o)));else{let r=t.bottom-t.top,a=e.bottom-e.top;v=(i==`center`&&r<=a?t.top+r/2-a/2:i==`start`||i==`center`&&n<0?t.top-o:t.bottom-a+o)-e.top}}if(h&&(r==`nearest`?t.left<e.left+a?(_=t.left-(e.left+a),n>0&&t.right>e.right+_&&(_=t.right-e.right+a)):t.right>e.right-a&&(_=t.right-e.right+a,n<0&&t.left<e.left+_&&(_=t.left-(e.left+a))):_=(r==`center`?t.left+(t.right-t.left)/2-(e.right-e.left)/2:r==`start`==s?t.left-a:t.right-(e.right-e.left)+a)-e.left),_||v){if(f)l.scrollBy(_,v);else{let e=0,n=0;if(v){let e=u.scrollTop;u.scrollTop+=v/m,n=(u.scrollTop-e)*m}if(_){let t=u.scrollLeft;u.scrollLeft+=_/p,e=(u.scrollLeft-t)*p}t={left:t.left-e,top:t.top-n,right:t.right-e,bottom:t.bottom-n},e&&Math.abs(e-_)<1&&(r=`nearest`),n&&Math.abs(n-v)<1&&(i=`nearest`)}}if(f)break;(t.top<e.top||t.bottom>e.bottom||t.left<e.left||t.right>e.right)&&(t={left:Math.max(t.left,e.left),right:Math.min(t.right,e.right),top:Math.max(t.top,e.top),bottom:Math.min(t.bottom,e.bottom)}),u=u.assignedSlot||u.parentNode}else if(u.nodeType==11)u=u.host;else break}function bE(e,t=!0){let n=e.ownerDocument,r=null,i=null;for(let a=e.parentNode;a&&!(a==n.body||(!t||r)&&i);)if(aE(a))!i&&a.scrollHeight>a.clientHeight&&/scroll|auto/.test(getComputedStyle(a).overflowY)&&(i=a),t&&!r&&a.scrollWidth>a.clientWidth&&/scroll|auto/.test(getComputedStyle(a).overflowX)&&(r=a),a=a.assignedSlot||a.parentNode;else if(a.nodeType==11)a=a.host;else break;return{x:r,y:i}}var xE=class{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:t,focusNode:n}=e;this.set(t,Math.min(e.anchorOffset,t?hE(t):0),n,Math.min(e.focusOffset,n?hE(n):0))}set(e,t,n,r){this.anchorNode=e,this.anchorOffset=t,this.focusNode=n,this.focusOffset=r}};function SE(e){let t=[];for(let n=e;n;n=n.nodeType==11?n.host:n.parentNode)aE(n)&&t.push({node:n,left:n.scrollLeft,top:n.scrollTop});return t}function CE(e,t=!0){for(let{node:n,left:r,top:i}of e)t&&n.scrollTop!=i&&(n.scrollTop=i),n.scrollLeft!=r&&(n.scrollLeft=r)}var wE=null;q.safari&&q.safari_version>=26&&(wE=!1);function TE(e){if(e.setActive)return e.setActive();if(wE)return e.focus(wE);let t=SE(e);e.focus(wE==null?{get preventScroll(){return wE={preventScroll:!0},!0}}:void 0),wE||(wE=!1,CE(t))}var EE;function DE(e,t,n=t){let r=EE||=document.createRange();return r.setEnd(e,n),r.setStart(e,t),r}function OE(e,t,n,r){let i={key:t,code:t,keyCode:n,which:n,cancelable:!0};r&&({altKey:i.altKey,ctrlKey:i.ctrlKey,shiftKey:i.shiftKey,metaKey:i.metaKey}=r);let a=new KeyboardEvent(`keydown`,i);a.synthetic=!0,e.dispatchEvent(a);let o=new KeyboardEvent(`keyup`,i);return o.synthetic=!0,e.dispatchEvent(o),a.defaultPrevented||o.defaultPrevented}function kE(e){for(;e;){if(e&&(e.nodeType==9||e.nodeType==11&&e.host))return e;e=e.assignedSlot||e.parentNode}return null}function AE(e,t){let n=t.focusNode,r=t.focusOffset;if(!n||t.anchorNode!=n||t.anchorOffset!=r)return!1;for(r=Math.min(r,hE(n));;)if(r){if(!aE(n))return!1;let e=n.childNodes[r-1];e.contentEditable==`false`?r--:(n=e,r=hE(n))}else if(n==e)return!0;else r=fE(n),n=n.parentNode}function jE(e){return e instanceof Window?e.pageYOffset>Math.max(0,e.document.documentElement.scrollHeight-e.innerHeight-4):e.scrollTop>Math.max(1,e.scrollHeight-e.clientHeight-4)}function ME(e,t){for(let n=e,r=t;;)if(oE(n)&&r>0)return{node:n,offset:r};else if(aE(n)&&r>0){if(n.contentEditable==`false`)return null;n=n.childNodes[r-1],r=hE(n)}else if(n.parentNode&&!pE(n))r=fE(n),n=n.parentNode;else return null}function NE(e,t){for(let n=e,r=t;;)if(oE(n)&&r<n.nodeValue.length)return{node:n,offset:r};else if(aE(n)&&r<n.childNodes.length){if(n.contentEditable==`false`)return null;n=n.childNodes[r],r=0}else if(n.parentNode&&!pE(n))r=fE(n)+1,n=n.parentNode;else return null}var PE=class e{constructor(e,t,n=!0){this.node=e,this.offset=t,this.precise=n}static before(t,n){return new e(t.parentNode,fE(t),n)}static after(t,n){return new e(t.parentNode,fE(t)+1,n)}},FE=(function(e){return e[e.LTR=0]=`LTR`,e[e.RTL=1]=`RTL`,e})(FE||={}),IE=FE.LTR,LE=FE.RTL;function RE(e){let t=[];for(let n=0;n<e.length;n++)t.push(1<<e[n]);return t}var zE=RE(`88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008`),BE=RE(`4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333`),VE=Object.create(null),HE=[];for(let e of[`()`,`[]`,`{}`]){let t=e.charCodeAt(0),n=e.charCodeAt(1);VE[t]=n,VE[n]=-t}function UE(e){return e<=247?zE[e]:1424<=e&&e<=1524?2:1536<=e&&e<=1785?BE[e-1536]:1774<=e&&e<=2220?4:8192<=e&&e<=8204?256:64336<=e&&e<=65023?4:1}var WE=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/,GE=class{get dir(){return this.level%2?LE:IE}constructor(e,t,n){this.from=e,this.to=t,this.level=n}side(e,t){return this.dir==t==e?this.to:this.from}forward(e,t){return e==(this.dir==t)}static find(e,t,n,r){let i=-1;for(let a=0;a<e.length;a++){let o=e[a];if(o.from<=t&&o.to>=t){if(o.level==n)return a;(i<0||(r==0?e[i].level>o.level:r<0?o.from<t:o.to>t))&&(i=a)}}if(i<0)throw RangeError(`Index out of range`);return i}};function KE(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t[n];if(r.from!=i.from||r.to!=i.to||r.direction!=i.direction||!KE(r.inner,i.inner))return!1}return!0}var qE=[];function JE(e,t,n,r,i){for(let a=0;a<=r.length;a++){let o=a?r[a-1].to:t,s=a<r.length?r[a].from:n,c=a?256:i;for(let t=o,n=c,r=c;t<s;t++){let i=UE(e.charCodeAt(t));i==512?i=n:i==8&&r==4&&(i=16),qE[t]=i==4?2:i,i&7&&(r=i),n=i}for(let e=o,t=c,r=c;e<s;e++){let i=qE[e];if(i==128)e<s-1&&t==qE[e+1]&&t&24?i=qE[e]=t:qE[e]=256;else if(i==64){let i=e+1;for(;i<s&&qE[i]==64;)i++;let a=e&&t==8||i<n&&qE[i]==8?r==1?1:8:256;for(let t=e;t<i;t++)qE[t]=a;e=i-1}else i==8&&r==1&&(qE[e]=1);t=i,i&7&&(r=i)}}}function YE(e,t,n,r,i){let a=i==1?2:1;for(let o=0,s=0,c=0;o<=r.length;o++){let l=o?r[o-1].to:t,u=o<r.length?r[o].from:n;for(let t=l,n,r,o;t<u;t++)if(r=VE[n=e.charCodeAt(t)]){if(r<0){for(let e=s-3;e>=0;e-=3)if(HE[e+1]==-r){let n=HE[e+2],r=n&2?i:n&4?n&1?a:i:0;r&&(qE[t]=qE[HE[e]]=r),s=e;break}}else if(HE.length==189)break;else HE[s++]=t,HE[s++]=n,HE[s++]=c}else if((o=qE[t])==2||o==1){let e=o==i;c=+!e;for(let t=s-3;t>=0;t-=3){let n=HE[t+2];if(n&2)break;if(e)HE[t+2]|=2;else{if(n&4)break;HE[t+2]|=4}}}}}function XE(e,t,n,r){for(let i=0,a=r;i<=n.length;i++){let o=i?n[i-1].to:e,s=i<n.length?n[i].from:t;for(let c=o;c<s;){let o=qE[c];if(o==256){let o=c+1;for(;;)if(o==s){if(i==n.length)break;o=n[i++].to,s=i<n.length?n[i].from:t}else if(qE[o]==256)o++;else break;let l=a==1,u=l==((o<t?qE[o]:r)==1)?l?1:2:r;for(let t=o,r=i,a=r?n[r-1].to:e;t>c;)t==a&&(t=n[--r].from,a=r?n[r-1].to:e),qE[--t]=u;c=o}else a=o,c++}}}function ZE(e,t,n,r,i,a,o){let s=r%2?2:1;if(r%2==i%2)for(let c=t,l=0;c<n;){let t=!0,u=!1;if(l==a.length||c<a[l].from){let e=qE[c];e!=s&&(t=!1,u=e==16)}let d=!t&&s==1?[]:null,f=t?r:r+1,p=c;run:for(;;)if(l<a.length&&p==a[l].from){if(u)break run;let m=a[l];if(!t)for(let e=m.to,t=l+1;;){if(e==n)break run;if(t<a.length&&a[t].from==e)e=a[t++].to;else if(qE[e]==s)break run;else break}l++,d?d.push(m):(m.from>c&&o.push(new GE(c,m.from,f)),QE(e,m.direction==IE==!(f%2)?r:r+1,i,m.inner,m.from,m.to,o),c=m.to),p=m.to}else if(p==n||(t?qE[p]!=s:qE[p]==s))break;else p++;d?ZE(e,c,p,r+1,i,d,o):c<p&&o.push(new GE(c,p,f)),c=p}else for(let c=n,l=a.length;c>t;){let n=!0,u=!1;if(!l||c>a[l-1].to){let e=qE[c-1];e!=s&&(n=!1,u=e==16)}let d=!n&&s==1?[]:null,f=n?r:r+1,p=c;run:for(;;)if(l&&p==a[l-1].to){if(u)break run;let m=a[--l];if(!n)for(let e=m.from,n=l;;){if(e==t)break run;if(n&&a[n-1].to==e)e=a[--n].from;else if(qE[e-1]==s)break run;else break}d?d.push(m):(m.to<c&&o.push(new GE(m.to,c,f)),QE(e,m.direction==IE==!(f%2)?r:r+1,i,m.inner,m.from,m.to,o),c=m.from),p=m.from}else if(p==t||(n?qE[p-1]!=s:qE[p-1]==s))break;else p--;d?ZE(e,p,c,r+1,i,d,o):p<c&&o.push(new GE(p,c,f)),c=p}}function QE(e,t,n,r,i,a,o){let s=t%2?2:1;JE(e,i,a,r,s),YE(e,i,a,r,s),XE(i,a,r,s),ZE(e,i,a,t,n,r,o)}function $E(e,t,n){if(!e)return[new GE(0,0,+(t==LE))];if(t==IE&&!n.length&&!WE.test(e))return eD(e.length);if(n.length)for(;e.length>qE.length;)qE[qE.length]=256;let r=[],i=t==IE?0:1;return QE(e,i,i,n,0,e.length,r),r}function eD(e){return[new GE(0,e,0)]}var tD=``;function nD(e,t,n,r,i){if(!e.length)return null;let a=r.head-e.from,o;if(r.head==e.from&&r.assoc<0){if(!i)return null;a=t[o=0].side(!1,n)}else if(r.head==e.to&&r.assoc>0){if(i)return null;a=t[o=t.length-1].side(!0,n)}else o=GE.find(t,a,r.bidiLevel??-1,r.assoc);let s=t[o],c=s.side(i,n);if(a==c){let e=o+=i?1:-1;if(e<0||e>=t.length)return null;s=t[o=e],a=s.side(!i,n),c=s.side(i,n)}let l=KC(e.text,a,s.forward(i,n));(l<s.from||l>s.to)&&(l=c),tD=e.text.slice(Math.min(a,l),Math.max(a,l));let u=o==(i?t.length-1:0)?null:t[o+(i?1:-1)];if(l==c){if(!u)return i?K.cursor(e.to,1):K.cursor(e.from,-1);if(u.level+ +!i<s.level)return K.cursor(u.side(!i,n)+e.from,u.forward(i,n)?1:-1,u.level)}return K.cursor(l+e.from,s.forward(i,n)?-1:1,s.level)}function rD(e,t,n){for(let r=t;r<n;r++){let t=UE(e.charCodeAt(r));if(t==1)return IE;if(t==2||t==4)return LE}}var iD=ow.define(),aD=ow.define(),oD=ow.define(),sD=ow.define(),cD=ow.define(),lD=ow.define(),uD=ow.define(),dD=ow.define(),fD=ow.define(),pD=ow.define({combine:e=>e.some(e=>e)}),mD=ow.define({combine:e=>e.some(e=>e)}),hD=ow.define(),gD=class e{constructor(e,t,n,r,i,a=!1){this.range=e,this.y=t,this.x=n,this.yMargin=r,this.xMargin=i,this.isSnapshot=a}map(t){return t.empty?this:new e(this.range.map(t),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(t){return this.range.to<=t.doc.length?this:new e(K.cursor(t.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}},_D=Pw.define({map:(e,t)=>e.map(t)}),vD=Pw.define();function yD(e,t,n){let r=e.facet(sD);r.length?r[0](t):window.onerror&&window.onerror(String(t),n,void 0,void 0,t)||(n?console.error(n+`:`,t):console.error(t))}var bD=ow.define({combine:e=>!e.length||e[0]}),xD=0,SD=ow.define({combine(e){return e.filter((t,n)=>{for(let r=0;r<n;r++)if(e[r].plugin==t.plugin)return!1;return!0})}}),CD=class e{constructor(e,t,n,r,i){this.id=e,this.create=t,this.domEventHandlers=n,this.domEventObservers=r,this.baseExtensions=i(this),this.extension=this.baseExtensions.concat(SD.of({plugin:this,arg:void 0}))}of(e){return this.baseExtensions.concat(SD.of({plugin:this,arg:e}))}static define(t,n){let{eventHandlers:r,eventObservers:i,provide:a,decorations:o}=n||{};return new e(xD++,t,r,i,e=>{let t=[];return o&&t.push(DD.of(t=>{let n=t.plugin(e);return n?o(n):ZT.none})),a&&t.push(a(e)),t})}static fromClass(t,n){return e.define((e,n)=>new t(e,n),n)}},wD=class{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}get plugin(){return this.spec&&this.spec.plugin}update(e){if(!this.value){if(this.spec)try{this.value=this.spec.plugin.create(e,this.spec.arg)}catch(t){yD(e.state,t,`CodeMirror plugin crashed`),this.deactivate()}}else if(this.mustUpdate){let e=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(e)}catch(t){if(yD(e.state,t,`CodeMirror plugin crashed`),this.value.destroy)try{this.value.destroy()}catch{}this.deactivate()}}return this}destroy(e){if(this.value?.destroy)try{this.value.destroy()}catch(t){yD(e.state,t,`CodeMirror plugin crashed`)}}deactivate(){this.spec=this.value=null}},TD=ow.define(),ED=ow.define(),DD=ow.define(),OD=ow.define(),kD=ow.define(),AD=ow.define(),jD=ow.define();function MD(e,t){let n=e.state.facet(jD);if(!n.length)return n;let r=n.map(t=>t instanceof Function?t(e):t),i=[];return nT.spans(r,t.from,t.to,{point(){},span(e,n,r,a){let o=e-t.from,s=n-t.from,c=i;for(let e=r.length-1;e>=0;e--,a--){let t=r[e].spec.bidiIsolate,n;if(a>0&&c.length&&(n=c[c.length-1]).to==o&&n.direction==t)n.to=s,c=n.inner;else{let e={from:o,to:s,direction:t,inner:[]};c.push(e),c=e.inner}}}}),ND(t.text,i)}function ND(e,t){for(let n of t){if(n.direction==null){for(let t=n.from,r=0;t<n.to;r++){let i=r<n.inner.length?n.inner[r]:null,a=rD(e,t,i?i.from:n.to);if(a){n.direction=a;break}if(!i)break;t=i.to}n.direction??=FE.LTR}ND(e,n.inner)}return t}var PD=ow.define();function FD(e){let t=0,n=0,r=0,i=0;for(let a of e.state.facet(PD)){let o=a(e);o&&(o.left!=null&&(t=Math.max(t,o.left)),o.right!=null&&(n=Math.max(n,o.right)),o.top!=null&&(r=Math.max(r,o.top)),o.bottom!=null&&(i=Math.max(i,o.bottom)))}return{left:t,right:n,top:r,bottom:i}}var ID=ow.define(),LD=class e{constructor(e,t,n,r){this.fromA=e,this.toA=t,this.fromB=n,this.toB=r}join(t){return new e(Math.min(this.fromA,t.fromA),Math.max(this.toA,t.toA),Math.min(this.fromB,t.fromB),Math.max(this.toB,t.toB))}addToSet(e){let t=e.length,n=this;for(;t>0;t--){let r=e[t-1];if(!(r.fromA>n.toA)){if(r.toA<n.fromA)break;n=n.join(r),e.splice(t-1,1)}}return e.splice(t,0,n),e}static extendWithRanges(t,n){if(n.length==0)return t;let r=[];for(let i=0,a=0,o=0;;){let s=i<t.length?t[i].fromB:1e9,c=a<n.length?n[a]:1e9,l=Math.min(s,c);if(l==1e9)break;let u=l+o,d=l,f=u;for(;;)if(a<n.length&&n[a]<=d){let e=n[a+1];a+=2,d=Math.max(d,e);for(let e=i;e<t.length&&t[e].fromB<=d;e++)o=t[e].toA-t[e].toB;f=Math.max(f,e+o)}else if(i<t.length&&t[i].fromB<=d){let e=t[i++];d=Math.max(d,e.toB),f=Math.max(f,e.toA),o=e.toA-e.toB}else break;r.push(new e(u,f,l,d))}return r}},RD=class e{constructor(e,t,n){this.view=e,this.state=t,this.transactions=n,this.flags=0,this.startState=e.state,this.changes=XC.empty(this.startState.doc.length);for(let e of n)this.changes=this.changes.compose(e.changes);let r=[];this.changes.iterChangedRanges((e,t,n,i)=>r.push(new LD(e,t,n,i))),this.changedRanges=r}static create(t,n,r){return new e(t,n,r)}get viewportChanged(){return(this.flags&4)>0}get viewportMoved(){return(this.flags&8)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&18)>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return this.flags==0&&this.transactions.length==0}},zD=[],BD=class{constructor(e,t,n=0){this.dom=e,this.length=t,this.flags=n,this.parent=null,e.cmTile=this}get breakAfter(){return this.flags&1}get children(){return zD}isWidget(){return!1}get isHidden(){return!1}isComposite(){return!1}isLine(){return!1}isText(){return!1}isBlock(){return!1}get domAttrs(){return null}sync(e){if(this.flags|=2,this.flags&4){this.flags&=-5;let e=this.domAttrs;e&&KT(this.dom,e)}}toString(){return this.constructor.name+(this.children.length?`(${this.children})`:``)+(this.breakAfter?`#`:``)}destroy(){this.parent=null}setDOM(e){this.dom=e,e.cmTile=this}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e,t=this.posAtStart){let n=t;for(let t of this.children){if(t==e)return n;n+=t.length+t.breakAfter}throw RangeError(`Invalid child in posBefore`)}posAfter(e){return this.posBefore(e)+e.length}covers(e){return!0}coordsIn(e,t,n){return null}domPosFor(e,t){let n=fE(this.dom),r=this.length?e>0:t>0;return new PE(this.parent.dom,n+ +!!r,e==0||e==this.length)}markDirty(e){this.flags&=-3,e&&(this.flags|=4),this.parent&&this.parent.flags&2&&this.parent.markDirty(!1)}get overrideDOMText(){return null}get root(){for(let e=this;e;e=e.parent)if(e instanceof UD)return e;return null}static get(e){return e.cmTile}},VD=class extends BD{constructor(e){super(e,0),this._children=[]}isComposite(){return!0}get children(){return this._children}get lastChild(){return this.children.length?this.children[this.children.length-1]:null}append(e){this.children.push(e),e.parent=this}sync(e){if(this.flags&2)return;super.sync(e);let t=this.dom,n=null,r,i=e?.node==t?e:null,a=0;for(let o of this.children){if(o.sync(e),a+=o.length+o.breakAfter,r=n?n.nextSibling:t.firstChild,i&&r!=o.dom&&(i.written=!0),o.dom.parentNode==t)for(;r&&r!=o.dom;)r=HD(r);else t.insertBefore(o.dom,r);n=o.dom}for(r=n?n.nextSibling:t.firstChild,i&&r&&(i.written=!0);r;)r=HD(r);this.length=a}};function HD(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}var UD=class extends VD{constructor(e,t){super(t),this.view=e}owns(e){for(;e;e=e.parent)if(e==this)return!0;return!1}isBlock(){return!0}nearest(e){for(;;){if(!e)return null;let t=BD.get(e);if(t&&this.owns(t))return t;e=e.parentNode}}blockTiles(e){for(let t=[],n=this,r=0,i=0;;)if(r==n.children.length){if(!t.length)return;n=n.parent,n.breakAfter&&i++,r=t.pop()}else{let a=n.children[r++];if(a instanceof WD)t.push(r),n=a,r=0;else{let t=i+a.length,n=e(a,i);if(n!==void 0)return n;i=t+a.breakAfter}}}resolveBlock(e,t){let n,r=-1,i,a=-1;if(this.blockTiles((o,s)=>{let c=s+o.length;if(e>=s&&e<=c){if(o.isWidget()&&t>=-1&&t<=1){if(o.flags&32)return!0;o.flags&16&&(n=void 0)}(s<e||e==c&&(t<-1?o.length:o.covers(1)))&&(!n||!o.isWidget()&&n.isWidget())&&(n=o,r=e-s),(c>e||e==s&&(t>1?o.length:o.covers(-1)))&&(!i||!o.isWidget()&&i.isWidget())&&(i=o,a=e-s)}}),!n&&!i)throw Error(`No tile at position `+e);return n&&t<0||!i?{tile:n,offset:r}:{tile:i,offset:a}}},WD=class e extends VD{constructor(e,t){super(e),this.wrapper=t}isBlock(){return!0}covers(e){return this.children.length?e<0?this.children[0].covers(-1):this.lastChild.covers(1):!1}get domAttrs(){return this.wrapper.attributes}static of(t,n){let r=new e(n||document.createElement(t.tagName),t);return n||(r.flags|=4),r}},GD=class e extends VD{constructor(e,t){super(e),this.attrs=t}isLine(){return!0}static start(t,n,r){let i=new e(n||document.createElement(`div`),t);return(!n||!r)&&(i.flags|=4),i}get domAttrs(){return this.attrs}resolveInline(e,t,n=!1){let r=null,i=-1,a=null,o=-1;function s(e,c){for(let l=0,u=0;l<e.children.length&&u<=c;l++){let d=e.children[l],f=u+d.length;f>=c&&(d.isComposite()?s(d,c-u):(!a||n&&a.isHidden&&(t>0&&!(a.flags&32)||n&&qD(a,d)))&&(f>c||d.flags&32&&t<=1)?(a=d,o=c-u):(u<c||d.flags&16&&!(n&&d.isHidden)&&t>=-1)&&(r=d,i=c-u)),u=f}}s(this,e);let c=(t<0?r:a)||r||a;return c?{tile:c,offset:c==r?i:o}:null}coordsIn(e,t,n){let r=this.resolveInline(e,t,!0);return r?r.tile.coordsIn(Math.max(0,r.offset),t,n):KD(this)}domIn(e,t){let n=this.resolveInline(e,t);if(n){let{tile:e,offset:r}=n;if(this.dom.contains(e.dom))return e.isText()?new PE(e.dom,Math.min(e.dom.nodeValue.length,r)):e.domPosFor(r,e.flags&16?1:e.flags&32?-1:t);let i=n.tile.parent,a=!1;for(let e of i.children){if(a)return new PE(e.dom,0);e==n.tile&&(a=!0)}}return new PE(this.dom,0)}};function KD(e){let t=e.dom.lastChild;if(!t)return e.dom.getBoundingClientRect();let n=uE(t);return n[n.length-1]||null}function qD(e,t){let n=e.coordsIn(0,1),r=t.coordsIn(0,1);return n&&r&&r.top<n.bottom}var JD=class e extends VD{constructor(e,t){super(e),this.mark=t}get domAttrs(){return this.mark.attrs}static of(t,n){let r=new e(n||document.createElement(t.tagName),t);return n||(r.flags|=4),r}},YD=class e extends BD{constructor(e,t){super(e,t.length),this.text=t}sync(e){this.flags&2||(super.sync(e),this.dom.nodeValue!=this.text&&(e&&e.node==this.dom&&(e.written=!0),this.dom.nodeValue=this.text))}isText(){return!0}toString(){return JSON.stringify(this.text)}coordsIn(e,t,n){let r=this.dom.nodeValue.length;e>r&&(e=r);let i=e,a=e,o=0;e==0&&t<0||e==r&&t>=0?q.chrome||q.gecko||(e?(i--,o=1):a<r&&(a++,o=-1)):t<0?i--:a<r&&a++;let s=DE(this.dom,i,a).getClientRects();if(!s.length)return null;let c=s[(o?o<0:t>=0)?0:s.length-1];return q.safari&&!o&&c.width==0&&(c=Array.prototype.find.call(s,e=>e.width)||c),n==null?c:gE(c,(o?o>0:t<0)==n)}static of(t,n){let r=new e(n||document.createTextNode(t),t);return n||(r.flags|=2),r}},XD=class e extends BD{constructor(e,t,n,r){super(e,t,r),this.widget=n}isWidget(){return!0}get isHidden(){return this.widget.isHidden}covers(e){return this.flags&48?!1:(this.flags&(e<0?64:128))>0}coordsIn(e,t){return this.coordsInWidget(e,t,!1)}coordsInWidget(e,t,n){let r=this.widget.coordsAt(this.dom,e,t);if(r)return r;if(n)return gE(this.dom.getBoundingClientRect(),this.length?e==0:t<=0);{let t=this.dom.getClientRects(),n=null;if(!t.length)return null;let r=this.flags&16?!0:this.flags&32?!1:e>0;for(let i=r?t.length-1:0;n=t[i],!(e>0?i==0:i==t.length-1||n.top<n.bottom);i+=r?-1:1);return gE(n,!r)}}get overrideDOMText(){if(!this.length)return LC.empty;let{root:e}=this;if(!e)return LC.empty;let t=this.posAtStart;return e.view.state.doc.slice(t,t+this.length)}destroy(){super.destroy(),this.widget.destroy(this.dom)}static of(t,n,r,i,a){return a||(a=t.toDOM(n),t.editable||(a.contentEditable=`false`)),new e(a,r,t,i)}},ZD=class extends BD{constructor(e){let t=document.createElement(`img`);t.className=`cm-widgetBuffer`,t.setAttribute(`aria-hidden`,`true`),super(t,0,e)}get isHidden(){return!0}get overrideDOMText(){return LC.empty}coordsIn(e,t,n){let r=this.dom.getBoundingClientRect();return n==null?r:gE(r,t>0==n)}},QD=class{constructor(e){this.index=0,this.beforeBreak=!1,this.parents=[],this.tile=e}advance(e,t,n){let{tile:r,index:i,beforeBreak:a,parents:o}=this;for(;e||t>0;)if(!r.isComposite()){let t=r.length;if(i<t&&e){let a=Math.min(e,t-i);n&&n.skip(r,i,i+a),e-=a,i+=a}if(i==t)a=!!r.breakAfter,{tile:r,index:i}=o.pop(),i++;else if(!e)break}else if(a){if(!e)break;n&&n.break(),e--,a=!1}else if(i==r.children.length){if(!e&&!o.length)break;n&&n.leave(r),a=!!r.breakAfter,{tile:r,index:i}=o.pop(),i++}else{let s=r.children[i],c=s.breakAfter;(t>0?s.length<=e:s.length<e)&&(!n||n.skip(s,0,s.length)!==!1||!s.isComposite)?(a=!!c,i++,e-=s.length):(o.push({tile:r,index:i}),r=s,i=0,n&&s.isComposite()&&n.enter(s))}return this.tile=r,this.index=i,this.beforeBreak=a,this}get root(){return this.parents.length?this.parents[0].tile:this.tile}},$D=class{constructor(e,t,n,r){this.from=e,this.to=t,this.wrapper=n,this.rank=r}},eO=class{constructor(e,t,n){this.cache=e,this.root=t,this.blockWrappers=n,this.curLine=null,this.lastBlock=null,this.afterWidget=null,this.pos=0,this.wrappers=[],this.wrapperPos=0}addText(e,t,n,r){this.flushBuffer();let i=this.ensureMarks(t,n),a=i.lastChild;if(a&&a.isText()&&!(a.flags&8)&&a.length+e.length<512){this.cache.reused.set(a,2);let t=i.children[i.children.length-1]=new YD(a.dom,a.text+e);t.parent=i}else i.append(r||YD.of(e,this.cache.find(YD)?.dom));this.pos+=e.length,this.afterWidget=null}addComposition(e,t){let n=this.curLine;n.dom!=t.line.dom&&(n.setDOM(this.cache.reused.has(t.line)?uO(t.line.dom):t.line.dom),this.cache.reused.set(t.line,2));let r=n;for(let e=t.marks.length-1;e>=0;e--){let n=t.marks[e],i=r.lastChild;if(i instanceof JD&&i.mark.eq(n.mark))i.dom!=n.dom&&i.setDOM(uO(n.dom)),r=i;else{let{dom:e}=n;this.cache.reused.get(n)&&BD.get(n.dom)&&(e=uO(n.dom));let t=JD.of(n.mark,e);r.append(t),r=t}this.cache.reused.set(n,2)}let i=BD.get(e.text);i&&this.cache.reused.set(i,2);let a=new YD(e.text,e.text.nodeValue);a.flags|=8,this.pos=e.range.toB,r.append(a)}addInlineWidget(e,t,n){let r=this.afterWidget&&e.flags&48&&(this.afterWidget.flags&48)==(e.flags&48);r||this.flushBuffer();let i=this.ensureMarks(t,n);!r&&!(e.flags&16)&&i.append(this.getBuffer(1)),i.append(e),this.pos+=e.length,this.afterWidget=e}addMark(e,t,n){this.flushBuffer(),this.ensureMarks(t,n).append(e),this.pos+=e.length,this.afterWidget=null}addBlockWidget(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}continueWidget(e){let t=this.afterWidget||this.lastBlock;t.length+=e,this.pos+=e}addLineStart(e,t){e||=sO;let n=GD.start(e,t||this.cache.find(GD)?.dom,!!t);this.getBlockPos().append(this.lastBlock=this.curLine=n)}addLine(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}addBreak(){this.lastBlock.flags|=1,this.endLine(),this.pos++}addLineStartIfNotCovered(e){this.blockPosCovered()||this.addLineStart(e)}ensureLine(e){this.curLine||this.addLineStart(e)}ensureMarks(e,t){let n=this.curLine;for(let r=e.length-1;r>=0;r--){let i=e[r],a;if(t>0&&(a=n.lastChild)&&a instanceof JD&&a.mark.eq(i))n=a,t--;else{let e=JD.of(i,this.cache.find(JD,e=>e.mark.eq(i))?.dom);n.append(e),n=e,t=0}}return n}endLine(){if(this.curLine){this.flushBuffer();let e=this.curLine.lastChild;(!e||!aO(this.curLine,!1)||e.dom.nodeName!=`BR`&&e.isWidget()&&!(q.ios&&aO(this.curLine,!0)))&&this.curLine.append(this.cache.findWidget(fO,0,32)||new XD(fO.toDOM(),0,fO,32)),this.curLine=this.afterWidget=null}}updateBlockWrappers(){this.wrapperPos>this.pos+1e4&&(this.blockWrappers.goto(this.pos),this.wrappers.length=0);for(let e=this.wrappers.length-1;e>=0;e--)this.wrappers[e].to<this.pos&&this.wrappers.splice(e,1);for(let e=this.blockWrappers;e.value&&e.from<=this.pos;e.next())if(e.to>=this.pos){let t=e.rank*102+e.value.rank,n=new $D(e.from,e.to,e.value,t),r=this.wrappers.length;for(;r>0&&(this.wrappers[r-1].rank-n.rank||this.wrappers[r-1].to-n.to)<0;)r--;this.wrappers.splice(r,0,n)}this.wrapperPos=this.pos}getBlockPos(){this.updateBlockWrappers();let e=this.root;for(let t of this.wrappers){let n=e.lastChild;if(t.from<this.pos&&n instanceof WD&&n.wrapper.eq(t.wrapper))e=n;else{let n=WD.of(t.wrapper,this.cache.find(WD,e=>e.wrapper.eq(t.wrapper))?.dom);e.append(n),e=n}}return e}blockPosCovered(){let e=this.lastBlock;return e!=null&&!e.breakAfter&&(!e.isWidget()||(e.flags&160)>0)}getBuffer(e){let t=2|(e<0?16:32),n=this.cache.find(ZD,void 0,1);return n&&(n.flags=t),n||new ZD(t)}flushBuffer(){this.afterWidget&&!(this.afterWidget.flags&32)&&(this.afterWidget.parent.append(this.getBuffer(-1)),this.afterWidget=null)}},tO=class{constructor(e){this.skipCount=0,this.text=``,this.textOff=0,this.cursor=e.iter()}skip(e){this.textOff+e<=this.text.length?this.textOff+=e:(this.skipCount+=e-(this.text.length-this.textOff),this.text=``,this.textOff=0)}next(e){if(this.textOff==this.text.length){let{value:t,lineBreak:n,done:r}=this.cursor.next(this.skipCount);if(this.skipCount=0,r)throw Error(`Ran out of text content when drawing inline views`);this.text=t;let i=this.textOff=Math.min(e,t.length);return n?null:t.slice(0,i)}let t=Math.min(this.text.length,this.textOff+e),n=this.text.slice(this.textOff,t);return this.textOff=t,n}},nO=[XD,GD,YD,JD,ZD,WD,UD];for(let e=0;e<nO.length;e++)nO[e].bucket=e;var rO=class{constructor(e){this.view=e,this.buckets=nO.map(()=>[]),this.index=nO.map(()=>0),this.reused=new Map}add(e){let t=e.constructor.bucket,n=this.buckets[t];n.length<6?n.push(e):n[this.index[t]=(this.index[t]+1)%6]=e}find(e,t,n=2){let r=e.bucket,i=this.buckets[r],a=this.index[r];for(let e=0;e<i.length;e++){let o=(e+a)%i.length,s=i[o];if((!t||t(s))&&!this.reused.has(s))return i.splice(o,1),o<a&&this.index[r]--,this.reused.set(s,n),s}return null}findWidget(e,t,n){let r=this.buckets[0];if(r.length)for(let i=0,a=0;;i++){if(i==r.length){if(a)return null;a=1,i=0}let o=r[i];if(!this.reused.has(o)&&(a==0?o.widget.compare(e):o.widget.constructor==e.constructor&&e.updateDOM(o.dom,this.view,o.widget)))return r.splice(i,1),i<this.index[0]&&this.index[0]--,o.widget==e&&o.length==t&&(o.flags&497)==n?(this.reused.set(o,1),o):(this.reused.set(o,2),new XD(o.dom,t,e,o.flags&-498|n))}}reuse(e){return this.reused.set(e,1),e}maybeReuse(e,t=2){if(!this.reused.has(e))return this.reused.set(e,t),e.dom}clear(){for(let e=0;e<this.buckets.length;e++)this.buckets[e].length=this.index[e]=0}},iO=class{constructor(e,t,n,r,i){this.view=e,this.decorations=r,this.disallowBlockEffectsFor=i,this.openWidget=!1,this.openMarks=0,this.cache=new rO(e),this.text=new tO(e.state.doc),this.builder=new eO(this.cache,new UD(e,e.contentDOM),nT.iter(n)),this.cache.reused.set(t,2),this.old=new QD(t),this.reuseWalker={skip:(e,t,n)=>{if(this.cache.add(e),e.isComposite())return!1},enter:e=>this.cache.add(e),leave:()=>{},break:()=>{}}}run(e,t){let n=t&&this.getCompositionContext(t.text);for(let r=0,i=0,a=0;;){let o=a<e.length?e[a++]:null,s=o?o.fromA:this.old.root.length;if(s>r){let e=s-r;this.preserve(e,!a,!o),r=s,i+=e}if(!o)break;t&&o.fromA<=t.range.fromA&&o.toA>=t.range.toA?(this.forward(o.fromA,t.range.fromA,t.range.fromA<t.range.toA?1:-1),this.emit(i,t.range.fromB),this.builder.flushBuffer(),this.cache.clear(),this.builder.addComposition(t,n),this.text.skip(t.range.toB-t.range.fromB),this.forward(t.range.fromA,o.toA),this.emit(t.range.toB,o.toB)):(this.forward(o.fromA,o.toA),this.emit(i,o.toB)),i=o.toB,r=o.toA}return this.builder.curLine&&this.builder.endLine(),this.builder.root}preserve(e,t,n){let r=lO(this.old),i=this.openMarks;this.old.advance(e,n?1:-1,{skip:(e,t,n)=>{if(e.isWidget()){if(this.openWidget)this.builder.continueWidget(n-t);else{let a=n>0||t<e.length?XD.of(e.widget,this.view,n-t,e.flags&496,this.cache.maybeReuse(e)):this.cache.reuse(e);a.flags&256?(a.flags&=-2,this.builder.addBlockWidget(a)):(this.builder.ensureLine(null),this.builder.addInlineWidget(a,r,i),i=r.length)}}else if(e.isText())this.builder.ensureLine(null),!t&&n==e.length&&!this.cache.reused.has(e)?this.builder.addText(e.text,r,i,this.cache.reuse(e)):(this.cache.add(e),this.builder.addText(e.text.slice(t,n),r,i)),i=r.length;else if(e.isLine())e.flags&=-2,this.cache.reused.set(e,1),this.builder.addLine(e);else if(e instanceof ZD)this.cache.add(e);else if(e instanceof JD)this.builder.ensureLine(null),this.builder.addMark(e,r,i),this.cache.reused.set(e,1),i=r.length;else return!1;this.openWidget=!1},enter:e=>{e.isLine()?this.builder.addLineStart(e.attrs,this.cache.maybeReuse(e)):(this.cache.add(e),e instanceof JD&&r.unshift(e.mark)),this.openWidget=!1},leave:e=>{e.isLine()?r.length&&=i=0:e instanceof JD&&(r.shift(),i=Math.min(i,r.length))},break:()=>{this.builder.addBreak(),this.openWidget=!1}}),this.text.skip(e)}emit(e,t){let n=null,r=this.builder,i=-1,a=nT.spans(this.decorations,e,t,{point:(e,t,a,o,s,c)=>{if(a instanceof eE){if(this.disallowBlockEffectsFor[c]){if(a.block)throw RangeError(`Block decorations may not be specified via plugins`);if(t>this.view.state.doc.lineAt(e).to)throw RangeError(`Decorations that replace line breaks may not be specified via plugins`)}if(i=o.length,s>o.length)r.continueWidget(t-e);else{let i=a.widget||(a.block?dO.block:dO.inline),c=oO(a),l=this.cache.findWidget(i,t-e,c)||XD.of(i,this.view,t-e,c);a.block?(a.startSide>0&&r.addLineStartIfNotCovered(n),r.addBlockWidget(l)):(r.ensureLine(n),r.addInlineWidget(l,o,s))}n=null}else n=cO(n,a);t>e&&this.text.skip(t-e)},span:(e,t,a,o)=>{for(let i=e;i<t;){let s=this.text.next(Math.min(512,t-i));s==null?(r.addLineStartIfNotCovered(n),r.addBreak(),i++):(r.ensureLine(n),r.addText(s,a,i==e?o:a.length),i+=s.length),n=null}i=a.length}});i>-1&&(this.openWidget=a>i),this.openWidget||r.addLineStartIfNotCovered(n),this.openMarks=a}forward(e,t,n=1){t-e<=10?this.old.advance(t-e,n,this.reuseWalker):(this.old.advance(5,-1,this.reuseWalker),this.old.advance(t-e-10,-1),this.old.advance(5,n,this.reuseWalker))}getCompositionContext(e){let t=[],n=null;for(let r=e.parentNode;;r=r.parentNode){let e=BD.get(r);if(r==this.view.contentDOM)break;e instanceof JD?t.push(e):e?.isLine()?n=e:e instanceof WD||(r.nodeName==`DIV`&&!n?n=new GD(r,sO):n||t.push(JD.of(new QT({tagName:r.nodeName.toLowerCase(),attributes:JT(r)}),r)))}return n?{line:n,marks:t}:null}};function aO(e,t){let n=e=>{for(let r of e.children)if((t?r.isText():r.length)||n(r))return!0;return!1};return n(e)}function oO(e){let t=e.isReplace?(e.startSide<0?64:0)|(e.endSide>0?128:0):e.startSide>0?32:16;return e.block&&(t|=256),t}var sO={class:`cm-line`};function cO(e,t){let n=t.spec.attributes,r=t.spec.class;return!n&&!r?e:(e||={class:`cm-line`},n&&UT(n,e),r&&(e.class+=` `+r),e)}function lO(e){let t=[];for(let n=e.parents.length;n>1;n--){let r=n==e.parents.length?e.tile:e.parents[n].tile;r instanceof JD&&t.push(r.mark)}return t}function uO(e){let t=BD.get(e);return t&&t.setDOM(e.cloneNode()),e}var dO=class extends YT{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}};dO.inline=new dO(`span`),dO.block=new dO(`div`);var fO=new class extends YT{toDOM(){return document.createElement(`br`)}get isHidden(){return!0}get editable(){return!0}},pO=class{constructor(e){this.view=e,this.decorations=[],this.blockWrappers=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.editContextFormatting=ZT.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.updateDeco(),this.tile=new UD(e,e.contentDOM),this.updateInner([new LD(0,0,0,e.state.doc.length)],null)}update(e){let t=e.changedRanges;this.minWidth>0&&t.length&&(t.every(({fromA:e,toA:t})=>t<this.minWidthFrom||e>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let n=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&(this.domChanged?.newSel?n=this.domChanged.newSel.head:!wO(e.changes,this.hasComposition)&&!e.selectionSet&&(n=e.state.selection.main.head));let r=n>-1?_O(this.view,e.changes,n):null;if(this.domChanged=null,this.hasComposition){let{from:n,to:r}=this.hasComposition;t=new LD(n,r,e.changes.mapPos(n,-1),e.changes.mapPos(r,1)).addToSet(t.slice())}this.hasComposition=r?{from:r.range.fromB,to:r.range.toB}:null,(q.ie||q.chrome)&&!r&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let i=this.decorations,a=this.blockWrappers;this.updateDeco();let o=bO(i,this.decorations,e.changes);o.length&&(t=LD.extendWithRanges(t,o));let s=SO(a,this.blockWrappers,e.changes);return s.length&&(t=LD.extendWithRanges(t,s)),r&&!t.some(e=>e.fromA<=r.range.fromA&&e.toA>=r.range.toA)&&(t=r.range.addToSet(t.slice())),this.tile.flags&2&&t.length==0?!1:(this.updateInner(t,r),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,t){this.view.viewState.mustMeasureContent=!0;let{observer:n}=this.view;n.ignore(()=>{if(t||e.length){let n=this.tile,r=new iO(this.view,n,this.blockWrappers,this.decorations,this.dynamicDecorationMap);t&&BD.get(t.text)&&r.cache.reused.set(BD.get(t.text),2),this.tile=r.run(e,t),mO(n,r.cache.reused)}this.tile.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+`px`,this.tile.dom.style.flexBasis=this.minWidth?this.minWidth+`px`:``;let r=q.chrome||q.ios?{node:n.selectionRange.focusNode,written:!1}:void 0;this.tile.sync(r),r&&(r.written||n.selectionRange.focusNode!=r.node||!this.tile.dom.contains(r.node))&&(this.forceSelection=!0),this.tile.dom.style.height=``});let r=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let e of this.tile.children)e.isWidget()&&e.widget instanceof TO&&r.push(e.dom);n.updateGaps(r)}updateEditContextFormatting(e){this.editContextFormatting=this.editContextFormatting.map(e.changes);for(let t of e.transactions)for(let e of t.effects)e.is(vD)&&(this.editContextFormatting=e.value)}updateSelection(e=!1,t=!1){(e||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange();let{dom:n}=this.tile,r=this.view.root.activeElement,i=r==n,a=!i&&!(this.view.state.facet(bD)||n.tabIndex>-1)&&lE(n,this.view.observer.selectionRange)&&!(r&&n.contains(r));if(!(i||t||a))return;let o=this.forceSelection;this.forceSelection=!1;let s=this.view.state.selection.main,c,l;if(s.empty?l=c=this.inlineDOMNearPos(s.anchor,s.assoc||1):(l=this.inlineDOMNearPos(s.head,s.head==s.from?1:-1),c=this.inlineDOMNearPos(s.anchor,s.anchor==s.from?1:-1)),q.gecko&&s.empty&&!this.hasComposition&&hO(c)){let e=document.createTextNode(``);this.view.observer.ignore(()=>c.node.insertBefore(e,c.node.childNodes[c.offset]||null)),c=l=new PE(e,0),o=!0}let u=this.view.observer.selectionRange;(o||!u.focusNode||(!dE(c.node,c.offset,u.anchorNode,u.anchorOffset)||!dE(l.node,l.offset,u.focusNode,u.focusOffset))&&!this.suppressWidgetCursorChange(u,s))&&(this.view.observer.ignore(()=>{q.android&&q.chrome&&n.contains(u.focusNode)&&CO(u.focusNode,n)&&(n.blur(),n.focus({preventScroll:!0}));let e=sE(this.view.root);if(e){if(s.empty){if(q.gecko){let e=vO(c.node,c.offset);if(e&&e!=3){let t=(e==1?ME:NE)(c.node,c.offset);t&&(c=new PE(t.node,t.offset))}}e.collapse(c.node,c.offset),s.bidiLevel!=null&&e.caretBidiLevel!==void 0&&(e.caretBidiLevel=s.bidiLevel)}else if(e.extend){e.collapse(c.node,c.offset);try{e.extend(l.node,l.offset)}catch{}}else{let t=document.createRange();s.anchor>s.head&&([c,l]=[l,c]),t.setEnd(l.node,l.offset),t.setStart(c.node,c.offset),e.removeAllRanges(),e.addRange(t)}}a&&this.view.root.activeElement==n&&(n.blur(),r&&r.focus())}),this.view.observer.setSelectionRange(c,l)),this.impreciseAnchor=c.precise?null:new PE(u.anchorNode,u.anchorOffset),this.impreciseHead=l.precise?null:new PE(u.focusNode,u.focusOffset)}suppressWidgetCursorChange(e,t){return this.hasComposition&&t.empty&&dE(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==t.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,t=e.state.selection.main,n=sE(e.root),{anchorNode:r,anchorOffset:i}=e.observer.selectionRange;if(!n||!t.empty||!t.assoc||!n.modify)return;let a=this.lineAt(t.head,t.assoc);if(!a)return;let o=a.posAtStart;if(t.head==o||t.head==o+a.length)return;let s=this.coordsAt(t.head,-1),c=this.coordsAt(t.head,1);if(!s||!c||s.bottom>c.top)return;let l=this.domAtPos(t.head+t.assoc,t.assoc);n.collapse(l.node,l.offset),n.modify(`move`,t.assoc<0?`forward`:`backward`,`lineboundary`),e.observer.readSelectionRange();let u=e.observer.selectionRange;e.docView.posFromDOM(u.anchorNode,u.anchorOffset)!=t.from&&n.collapse(r,i)}posFromDOM(e,t){let n=this.tile.nearest(e);if(!n)return this.tile.dom.compareDocumentPosition(e)&2?0:this.view.state.doc.length;let r=n.posAtStart;if(n.isComposite()){let i;if(e==n.dom)i=n.dom.childNodes[t];else{let r=hE(e)==0?0:t==0?-1:1;for(;;){let t=e.parentNode;if(t==n.dom)break;r==0&&t.firstChild!=t.lastChild&&(r=e==t.firstChild?-1:1),e=t}i=r<0?e:e.nextSibling}if(i==n.dom.firstChild)return r;for(;i&&!BD.get(i);)i=i.nextSibling;if(!i)return r+n.length;for(let e=0,t=r;;e++){let r=n.children[e];if(r.dom==i)return t;t+=r.length+r.breakAfter}}else if(n.isText())return e==n.dom?r+t:r+(t?n.length:0);else return r}domAtPos(e,t){let{tile:n,offset:r}=this.tile.resolveBlock(e,t);return n.isWidget()?n.domPosFor(r,t):n.domIn(r,t)}inlineDOMNearPos(e,t){let n,r=-1,i=!1,a,o=-1,s=!1;return this.tile.blockTiles((t,c)=>{if(t.isWidget()){if(t.flags&32&&c>=e)return!0;t.flags&16&&(i=!0)}else{let l=c+t.length;if(c<=e&&(n=t,r=e-c,i=l<e),l>=e&&!a&&(a=t,o=e-c,s=c>e),c>e&&a)return!0}}),!n&&!a?this.domAtPos(e,t):(i&&a?n=null:s&&n&&(a=null),n&&t<0||!a?n.domIn(r,t):a.domIn(o,t))}coordsAt(e,t,n){let{tile:r,offset:i}=this.tile.resolveBlock(e,t);return r.isWidget()?r.widget instanceof TO?null:r.coordsInWidget(i,t,!0):r.coordsIn(i,t,n)}lineAt(e,t){let{tile:n}=this.tile.resolveBlock(e,t);return n.isLine()?n:null}coordsForChar(e){let{tile:t,offset:n}=this.tile.resolveBlock(e,1);if(!t.isLine())return null;function r(e,t){if(e.isComposite())for(let n of e.children){if(n.length>=t){let e=r(n,t);if(e)return e}if(t-=n.length,t<0)break}else if(e.isText()&&t<e.length){let n=KC(e.text,t);if(n==t)return null;let r=DE(e.dom,t,n).getClientRects();for(let e=0;e<r.length;e++){let t=r[e];if(e==r.length-1||t.top<t.bottom&&t.left<t.right)return t}}return null}return r(t,n)}measureVisibleLineHeights(e){let t=[],{from:n,to:r}=e,i=this.view.contentDOM.clientWidth,a=i>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,o=-1,s=this.view.textDirection==FE.LTR,c=0,l=(e,u,d)=>{for(let f=0;f<e.children.length&&!(u>r);f++){let r=e.children[f],p=u+r.length,m=r.dom.getBoundingClientRect(),{height:h}=m;if(d&&!f&&(c+=m.top-d.top),r instanceof WD)p>n&&l(r,u,m);else if(u>=n&&(c>0&&t.push(-c),t.push(h+c),c=0,a)){let e=r.dom.lastChild,t=e?uE(e):[];if(t.length){let e=t[t.length-1],n=s?e.right-m.left:m.right-e.left;n>o&&(o=n,this.minWidth=i,this.minWidthFrom=u,this.minWidthTo=p)}}d&&f==e.children.length-1&&(c+=d.bottom-m.bottom),u=p+r.breakAfter}};return l(this.tile,0,null),t}textDirectionAt(e){let{tile:t}=this.tile.resolveBlock(e,1);return getComputedStyle(t.dom).direction==`rtl`?FE.RTL:FE.LTR}measureTextSize(){let e=this.tile.blockTiles(e=>{if(e.isLine()&&e.children.length&&e.length<=20){let t=0,n;for(let r of e.children){if(!r.isText()||/[^ -~]/.test(r.text))return;let e=uE(r.dom);if(e.length!=1)return;t+=e[0].width,n=e[0].height}if(t)return{lineHeight:e.dom.getBoundingClientRect().height,charWidth:t/e.length,textHeight:n}}});if(e)return e;let t=document.createElement(`div`),n,r,i;return t.className=`cm-line`,t.style.width=`99999px`,t.style.position=`absolute`,t.textContent=`abc def ghi jkl mno pqr stu`,this.view.observer.ignore(()=>{this.tile.dom.appendChild(t);let e=uE(t.firstChild)[0];n=t.getBoundingClientRect().height,r=e&&e.width?e.width/27:7,i=e&&e.height?e.height:n,t.remove()}),{lineHeight:n,charWidth:r,textHeight:i}}computeBlockGapDeco(){let e=[],t=this.view.viewState;for(let n=0,r=0;;r++){let i=r==t.viewports.length?null:t.viewports[r],a=i?i.from-1:this.view.state.doc.length;if(a>n){let r=(t.lineBlockAt(a).bottom-t.lineBlockAt(n).top)/this.view.scaleY;e.push(ZT.replace({widget:new TO(r),block:!0,inclusive:!0,isBlockGap:!0}).range(n,a))}if(!i)break;n=i.to+1}return ZT.set(e)}updateDeco(){let e=1,t=this.view.state.facet(DD).map(t=>(this.dynamicDecorationMap[e++]=typeof t==`function`)?t(this.view):t),n=!1,r=this.view.state.facet(kD).map((e,t)=>{let r=typeof e==`function`;return r&&(n=!0),r?e(this.view):e});for(r.length&&(this.dynamicDecorationMap[e++]=n,t.push(nT.join(r))),this.decorations=[this.editContextFormatting,...t,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];e<this.decorations.length;)this.dynamicDecorationMap[e++]=!1;this.blockWrappers=this.view.state.facet(OD).map(e=>typeof e==`function`?e(this.view):e)}scrollIntoView(e){if(e.isSnapshot){let t=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=t.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let t of this.view.state.facet(hD))try{if(t(this.view,e.range,e))return!0}catch(e){yD(this.view.state,e,`scroll handler`)}let{range:t}=e,n=this.coordsAt(t.head,t.assoc||(t.head>t.anchor?-1:1)),r;if(!n)return;!t.empty&&(r=this.coordsAt(t.anchor,t.anchor>t.head?-1:1))&&(n={left:Math.min(n.left,r.left),top:Math.min(n.top,r.top),right:Math.max(n.right,r.right),bottom:Math.max(n.bottom,r.bottom)});let i=FD(this.view),a={left:n.left-i.left,top:n.top-i.top,right:n.right+i.right,bottom:n.bottom+i.bottom},{offsetWidth:o,offsetHeight:s}=this.view.scrollDOM;if(yE(this.view.scrollDOM,a,t.head<t.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,o),-o),Math.max(Math.min(e.yMargin,s),-s),this.view.textDirection==FE.LTR),window.visualViewport&&window.innerHeight-window.visualViewport.height>1&&(n.top>window.visualViewport.offsetTop+window.visualViewport.height||n.bottom<window.visualViewport.offsetTop)){let e=this.view.docView.lineAt(t.head,1);if(e){let t=SE(e.dom);e.dom.scrollIntoView({block:`nearest`}),CE(t,!1)}}}lineHasWidget(e){let t=e=>e.isWidget()||e.children.some(t);return t(this.tile.resolveBlock(e,1).tile)}destroy(){mO(this.tile)}};function mO(e,t){let n=t?.get(e);if(n!=1){n??e.destroy();for(let n of e.children)mO(n,t)}}function hO(e){return aE(e.node)&&e.node.firstChild&&(e.offset==0||e.node.childNodes[e.offset-1].contentEditable==`false`)&&(e.offset==e.node.childNodes.length||e.node.childNodes[e.offset].contentEditable==`false`)}function gO(e,t){let n=e.observer.selectionRange;if(!n.focusNode)return null;let r=ME(n.focusNode,n.focusOffset),i=NE(n.focusNode,n.focusOffset),a=r||i;if(i&&r&&i.node!=r.node){let t=BD.get(i.node);if(!t||t.isText()&&t.text!=i.node.nodeValue)a=i;else if(e.docView.lastCompositionAfterCursor){let e=BD.get(r.node);!e||e.isText()&&e.text!=r.node.nodeValue||(a=i)}}if(e.docView.lastCompositionAfterCursor=a!=r,!a)return null;let o=t-a.offset;return{from:o,to:o+a.node.nodeValue.length,node:a.node}}function _O(e,t,n){let r=gO(e,n);if(!r)return null;let{node:i,from:a,to:o}=r,s=i.nodeValue;if(/[\n\r]/.test(s)||e.state.doc.sliceString(r.from,r.to)!=s)return null;let c=t.invertedDesc;return{range:new LD(c.mapPos(a),c.mapPos(o),a,o),text:i}}function vO(e,t){return aE(e)?(t&&e.childNodes[t-1].contentEditable==`false`?1:0)|(t<e.childNodes.length&&e.childNodes[t].contentEditable==`false`?2:0):0}var yO=class{constructor(){this.changes=[]}compareRange(e,t){rE(e,t,this.changes)}comparePoint(e,t){rE(e,t,this.changes)}boundChange(e){rE(e,e,this.changes)}};function bO(e,t,n){let r=new yO;return nT.compare(e,t,n,r),r.changes}var xO=class{constructor(){this.changes=[]}compareRange(e,t){rE(e,t,this.changes)}comparePoint(){}boundChange(e){rE(e,e,this.changes)}};function SO(e,t,n){let r=new xO;return nT.compare(e,t,n,r),r.changes}function CO(e,t){for(let n=e;n&&n!=t;n=n.assignedSlot||n.parentNode)if(aE(n)&&n.contentEditable==`false`)return!0;return!1}function wO(e,t){let n=!1;return t&&e.iterChangedRanges((e,r)=>{e<t.to&&r>t.from&&(n=!0)}),n}var TO=class extends YT{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement(`div`);return e.className=`cm-gap`,this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+`px`,!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}};function EO(e,t,n=1){let r=e.charCategorizer(t),i=e.doc.lineAt(t),a=t-i.from;if(i.length==0)return K.cursor(t);a==0?n=1:a==i.length&&(n=-1);let o=a,s=a;n<0?o=KC(i.text,a,!1):s=KC(i.text,a);let c=r(i.text.slice(o,s));for(;o>0;){let e=KC(i.text,o,!1);if(r(i.text.slice(e,o))!=c)break;o=e}for(;s<i.length;){let e=KC(i.text,s);if(r(i.text.slice(s,e))!=c)break;s=e}return K.undirectionalRange(o+i.from,s+i.from)}function DO(e,t,n,r,i){let a=Math.round((r-t.left)*e.defaultCharacterWidth);if(e.lineWrapping&&n.height>e.defaultLineHeight*1.5){let t=e.viewState.heightOracle.textHeight,r=Math.floor((i-n.top-(e.defaultLineHeight-t)*.5)/t);a+=r*e.viewState.heightOracle.lineLength}let o=e.state.sliceDoc(n.from,n.to);return n.from+_T(o,a,e.state.tabSize)}function OO(e,t,n){let r=e.lineBlockAt(t);if(Array.isArray(r.type)){let e;for(let i of r.type){if(i.from>t)break;if(!(i.to<t)){if(i.from<t&&i.to>t)return i;(!e||i.type==XT.Text&&(e.type!=i.type||(n<0?i.from<t:i.to>t)))&&(e=i)}}return e||r}return r}function kO(e,t,n,r){let i=OO(e,t.head,t.assoc||-1),a=!r||i.type!=XT.Text||!(e.lineWrapping||i.widgetLineBreaks)?null:e.coordsAtPos(t.assoc<0&&t.head>i.from?t.head-1:t.head);if(a){let t=e.dom.getBoundingClientRect(),r=e.textDirectionAt(i.from),o=e.posAndSideAtCoords({x:n==(r==FE.LTR)?t.right-1:t.left+1,y:(a.top+a.bottom)/2});if(o)return K.cursor(o.pos,o.assoc)}return K.cursor(n?i.to:i.from,n?1:-1)}function AO(e,t,n,r){let i=e.state.doc.lineAt(t.head),a=e.bidiSpans(i),o=e.textDirectionAt(i.from);for(let s=t,c=null;;){let t=nD(i,a,o,s,n),l=tD;if(!t){if(i.number==(n?e.state.doc.lines:1))return s;l=`
|
|
29
|
+
`,i=e.state.doc.line(i.number+(n?1:-1)),a=e.bidiSpans(i),t=n?K.cursor(i.from,-1):K.cursor(i.to,1)}if(!c){if(!r)return t;c=r(l)}else if(!c(l))return s;s=t}}function jO(e,t,n){let r=e.state.charCategorizer(t),i=r(n);return e=>{let t=r(e);return i==Ww.Space&&(i=t),i==t}}function MO(e,t,n,r){let i=t.head,a=n?1:-1;if(i==(n?e.state.doc.length:0))return K.cursor(i,t.assoc);let o=t.goalColumn,s,c=e.contentDOM.getBoundingClientRect(),l=e.coordsAtPos(i,t.assoc||((t.empty?n:t.head==t.from)?1:-1)),u=e.documentTop;if(l)o??=l.left-c.left,s=a<0?l.top:l.bottom;else{let t=e.viewState.lineBlockAt(i);o??=Math.min(c.right-c.left,e.defaultCharacterWidth*(i-t.from)),s=(a<0?t.top:t.bottom)+u}let d=c.left+o,f=e.viewState.heightOracle.textHeight>>1,p=r??f;for(let t=0;;t+=f){let r=s+(p+t)*a,i=LO(e,{x:d,y:r},!1,a);if(n?r>c.bottom:r<c.top)return K.cursor(i.pos,i.assoc);let l=e.coordsAtPos(i.pos,i.assoc),u=l?(l.top+l.bottom)/2:0;if(!l||(n?u>s:u<s))return K.cursor(i.pos,i.assoc,void 0,o)}}function NO(e,t,n){for(;;){let r=0;for(let i of e)i.between(t-1,t+1,(e,i,a)=>{if(t>e&&t<i){let a=r||n||(t-e<i-t?-1:1);t=a<0?e:i,r=a}});if(!r)return t}}function PO(e,t){let n=null;for(let r=0;r<t.ranges.length;r++){let i=t.ranges[r],a=null;if(i.empty){let t=NO(e,i.from,0);t!=i.from&&(a=K.cursor(t,-1))}else{let t=NO(e,i.from,-1),n=NO(e,i.to,1);(t!=i.from||n!=i.to)&&(a=i.undirectional?K.undirectionalRange(i.from,i.to):K.range(i.from==i.anchor?t:n,i.from==i.head?t:n))}a&&(n||=t.ranges.slice(),n[r]=a)}return n?K.create(n,t.mainIndex):t}function FO(e,t,n){let r=NO(e.state.facet(AD).map(t=>t(e)),n.from,t.head>n.from?-1:1);return r==n.from?n:K.cursor(r,r<n.from?1:-1)}var IO=class{constructor(e,t){this.pos=e,this.assoc=t}};function LO(e,t,n,r){let i=e.contentDOM.getBoundingClientRect(),a=i.top+e.viewState.paddingTop,{x:o,y:s}=t,c=s-a,l;for(;;){if(c<0)return new IO(0,1);if(c>e.viewState.docHeight)return new IO(e.state.doc.length,-1);if(l=e.elementAtHeight(c),r==null)break;if(l.type==XT.Text){if(r<0?l.to<e.viewport.from:l.from>e.viewport.to)break;let t=e.docView.coordsAt(r<0?l.from:l.to,r>0?-1:1);if(t&&(r<0?t.top<=c+a:t.bottom>=c+a))break}let t=e.viewState.heightOracle.textHeight/2;c=r>0?l.bottom+t:l.top-t}if(e.viewport.from>=l.to||e.viewport.to<=l.from){if(n)return null;if(l.type==XT.Text){let t=DO(e,i,l,o,s);return new IO(t,t==l.from?1:-1)}}if(l.type!=XT.Text)return c<(l.top+l.bottom)/2?new IO(l.from,1):new IO(l.to,-1);let u=e.docView.lineAt(l.from,2);return(!u||u.length!=l.length)&&(u=e.docView.lineAt(l.from,-2)),new Qee(e,o,s,e.textDirectionAt(l.from)).scanTile(u,l.from)}var Qee=class{constructor(e,t,n,r){this.view=e,this.x=t,this.y=n,this.baseDir=r,this.line=null,this.spans=null}bidiSpansAt(e){return(!this.line||this.line.from>e||this.line.to<e)&&(this.line=this.view.state.doc.lineAt(e),this.spans=this.view.bidiSpans(this.line)),this}baseDirAt(e,t){let{line:n,spans:r}=this.bidiSpansAt(e);return r[GE.find(r,e-n.from,-1,t)].level==this.baseDir}dirAt(e,t){let{line:n,spans:r}=this.bidiSpansAt(e);return r[GE.find(r,e-n.from,-1,t)].dir}bidiIn(e,t){let{spans:n,line:r}=this.bidiSpansAt(e);return n.length>1||n.length&&(n[0].level!=this.baseDir||n[0].to+r.from<t)}scan(e,t,n=!1){let r=0,i=e.length-1,a=new Set,o=this.bidiIn(e[0],e[i]),s,c,l=-1,u=1e9,d;search:for(;r<i;){let n=i-r,f=r+i>>1;adjust:if(a.has(f)){for(let e=1;e<n;e++){let t=f+e;if(t>=i&&(t-=n),!a.has(t)){f=t;break adjust}}break search}a.add(f);let p=t(f),m=0;if(p)for(let e=0;e<p.length;e++){let t=p[e];if(!(t.width==0&&p.length>1)){if(t.bottom<this.y)(!s||s.bottom<t.bottom)&&(s=t),m=1;else if(t.top>this.y)(!c||c.top>t.top)&&(c=t),m=-1;else{let e=t.left>this.x?this.x-t.left:t.right<this.x?this.x-t.right:0,n=Math.abs(e);n<u&&(l=f,u=n,d=t),e&&(m=e<0==(this.baseDir==FE.LTR)?-1:1)}}}m==-1&&(!o||this.baseDirAt(e[f],1))?i=f:m==1&&(!o||this.baseDirAt(e[f+1],-1))&&(r=f+1)}if(!d){if(!c&&!s)return{i:0,after:!1};let n=s&&(!c||this.y-s.bottom<c.top-this.y)?s:c;return this.y=(n.top+n.bottom)/2,this.scan(e,t,!0)}if(u&&!n){let{top:n,bottom:r}=d;if(s&&s.bottom>(n+n+r)/3)return this.y=s.bottom-1,this.scan(e,t,!0);if(c&&c.top<(n+r+r)/3)return this.y=c.top+1,this.scan(e,t,!0)}let f=(o?this.dirAt(e[l],1):this.baseDir)==FE.LTR;return{i:l,after:this.x>(d.left+d.right)/2==f}}scanText(e,t){let n=[];for(let r=0;r<e.length;r=KC(e.text,r))n.push(t+r);n.push(t+e.length);let r=this.scan(n,r=>{let i=n[r]-t,a=n[r+1]-t;return DE(e.dom,i,a).getClientRects()});return r.after?new IO(n[r.i+1],-1):new IO(n[r.i],1)}scanTile(e,t){if(!e.length)return new IO(t,1);if(e.children.length==1){let n=e.children[0];if(n.isText())return this.scanText(n,t);if(n.isComposite())return this.scanTile(n,t)}let n=[t];for(let r=0,i=t;r<e.children.length;r++)n.push(i+=e.children[r].length);let r=this.scan(n,t=>{let n=e.children[t];return n.flags&48?null:(aE(n.dom)?n.dom:DE(n.dom,0,n.length)).getClientRects()}),i=e.children[r.i],a=n[r.i];return i.isText()?this.scanText(i,a):i.isComposite()?this.scanTile(i,a):r.after?new IO(n[r.i+1],-1):new IO(a,1)}},RO=``,$ee=class{constructor(e,t){this.points=e,this.view=t,this.text=``,this.lineSeparator=t.state.facet(Yw.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=RO}readRange(e,t){if(!e)return this;let n=e.parentNode;for(let r=e;;){this.findPointBefore(n,r);let e=this.text.length;this.readNode(r);let i=BD.get(r),a=r.nextSibling;if(a==t){i?.breakAfter&&!a&&n!=this.view.contentDOM&&this.lineBreak();break}let o=BD.get(a);(i&&o?i.breakAfter:(i?i.breakAfter:pE(r))||pE(a)&&(r.nodeName!=`BR`||i?.isWidget())&&this.text.length>e)&&!tte(a,t)&&this.lineBreak(),r=a}return this.findPointBefore(n,t),this}readTextNode(e){let t=e.nodeValue;for(let n of this.points)n.node==e&&(n.pos=this.text.length+Math.min(n.offset,t.length));for(let n=0,r=this.lineSeparator?null:/\r\n?|\n/g;;){let i=-1,a=1,o;if(this.lineSeparator?(i=t.indexOf(this.lineSeparator,n),a=this.lineSeparator.length):(o=r.exec(t))&&(i=o.index,a=o[0].length),this.append(t.slice(n,i<0?t.length:i)),i<0)break;if(this.lineBreak(),a>1)for(let t of this.points)t.node==e&&t.pos>this.text.length&&(t.pos-=a-1);n=i+a}}readNode(e){let t=BD.get(e),n=t&&t.overrideDOMText;if(n!=null){this.findPointInside(e,n.length);for(let e=n.iter();!e.next().done;)e.lineBreak?this.lineBreak():this.append(e.value)}else oE(e)?this.readTextNode(e):e.nodeName==`BR`?e.nextSibling&&this.lineBreak():aE(e)&&this.readRange(e.firstChild,null)}findPointBefore(e,t){for(let n of this.points)n.node==e&&e.childNodes[n.offset]==t&&(n.pos=this.text.length)}findPointInside(e,t){for(let n of this.points)(oE(e)?n.node==e:e.contains(n.node))&&(n.pos=this.text.length+(ete(e,n.node,n.offset)?t:0))}};function ete(e,t,n){for(;;){if(!t||n<hE(t))return!1;if(t==e)return!0;n=fE(t)+1,t=t.parentNode}}function tte(e,t){let n;for(;e!=t&&e;e=e.nextSibling){let t=BD.get(e);if(!t?.isWidget())return!1;t&&(n||=[]).push(t)}if(n){for(let e of n)if(e.overrideDOMText?.length)return!1}return!0}var zO=class{constructor(e,t){this.node=e,this.offset=t,this.pos=-1}},nte=class{constructor(e,t,n,r){this.typeOver=r,this.bounds=null,this.text=``,this.domChanged=t>-1;let{impreciseHead:i,impreciseAnchor:a}=e.docView,o=e.state.selection;if(e.state.readOnly&&t>-1)this.newSel=null;else if(t>-1&&(this.bounds=BO(e.docView.tile,t,n,0))){let t=i||a?[]:ite(e),n=new $ee(t,e);n.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=n.text,this.newSel=ate(t,this.bounds.from)}else{let t=e.observer.selectionRange,n=i&&i.node==t.focusNode&&i.offset==t.focusOffset||!cE(e.contentDOM,t.focusNode)?o.main.head:e.docView.posFromDOM(t.focusNode,t.focusOffset),r=a&&a.node==t.anchorNode&&a.offset==t.anchorOffset||!cE(e.contentDOM,t.anchorNode)?o.main.anchor:e.docView.posFromDOM(t.anchorNode,t.anchorOffset),s=e.viewport;if((q.ios||q.chrome)&&n!=r&&Math.min(n,r)<=o.main.from&&Math.max(n,r)>=o.main.to&&(s.from>0||s.to<e.state.doc.length)){let t=Math.min(n,r),i=Math.max(n,r),a=s.from-t,o=s.to-i;(a==0||a==1||t==0)&&(o==0||o==-1||i==e.state.doc.length)&&(n=0,r=e.state.doc.length)}if(e.inputState.composing>-1&&o.ranges.length>1)this.newSel=o.replaceRange(K.range(r,n));else if(e.lineWrapping&&r==n&&!(o.main.empty&&o.main.head==n)&&e.inputState.lastTouchTime>Date.now()-100){let t=e.coordsAtPos(n,-1),r=0;t&&(r=e.inputState.lastTouchY<=t.bottom?-1:1),this.newSel=K.create([K.cursor(n,r)])}else this.newSel=K.single(r,n)}}};function BO(e,t,n,r){if(e.isComposite()){let i=-1,a=-1,o=-1,s=-1;for(let c=0,l=r,u=r;c<e.children.length;c++){let r=e.children[c],d=l+r.length;if(l<t&&d>n)return BO(r,t,n,l);if(d>=t&&i==-1&&(i=c,a=l),l>n&&r.dom.parentNode==e.dom){o=c,s=u;break}u=d,l=d+r.breakAfter}return{from:a,to:s<0?r+e.length:s,startDOM:(i?e.children[i-1].dom.nextSibling:null)||e.dom.firstChild,endDOM:o<e.children.length&&o>=0?e.children[o].dom:null}}return e.isText()?{from:r,to:r+e.length,startDOM:e.dom,endDOM:e.dom.nextSibling}:null}function VO(e,t){let n,{newSel:r}=t,{state:i}=e,a=i.selection.main,o=e.inputState.lastKeyTime>Date.now()-100?e.inputState.lastKeyCode:-1;if(t.bounds){let{from:e,to:r}=t.bounds,s=a.from,c=null;(o===8||q.android&&t.text.length<r-e)&&(s=a.to,c=`end`);let l=i.doc.sliceString(e,r,RO),u,d;!a.empty&&a.from>=e&&a.to<=r&&(t.typeOver||l!=t.text)&&l.slice(0,a.from-e)==t.text.slice(0,a.from-e)&&l.slice(a.to-e)==t.text.slice(u=t.text.length-(l.length-(a.to-e)))?n={from:a.from,to:a.to,insert:LC.of(t.text.slice(a.from-e,u).split(RO))}:(d=UO(l,t.text,s-e,c))&&(q.chrome&&o==13&&d.toB==d.from+2&&t.text.slice(d.from,d.toB)==``&&d.toB--,n={from:e+d.from,to:e+d.toA,insert:LC.of(t.text.slice(d.from,d.toB).split(RO))})}else r&&(!e.hasFocus&&i.facet(bD)||WO(r,a))&&(r=null);if(!n&&!r)return!1;if((q.mac||q.android)&&n&&n.from==n.to&&n.from==a.head-1&&/^\. ?$/.test(n.insert.toString())&&e.contentDOM.getAttribute(`autocorrect`)==`off`?(r&&n.insert.length==2&&(r=K.single(r.main.anchor-1,r.main.head-1)),n={from:n.from,to:n.to,insert:LC.of([n.insert.toString().replace(`.`,` `)])}):i.doc.lineAt(a.from).to<a.to&&e.docView.lineHasWidget(a.to)&&e.inputState.insertingTextAt>Date.now()-50?n={from:a.from,to:a.to,insert:i.toText(e.inputState.insertingText)}:q.chrome&&n&&n.from==n.to&&n.from==a.head&&n.insert.toString()==`
|
|
30
|
+
`&&e.lineWrapping&&(r&&=K.single(r.main.anchor-1,r.main.head-1),n={from:a.from,to:a.to,insert:LC.of([` `])}),n)return HO(e,n,r,o);if(r&&!WO(r,a)){let t=!1,n=`select`;return e.inputState.lastSelectionTime>Date.now()-50&&(e.inputState.lastSelectionOrigin==`select`&&(t=!0),n=e.inputState.lastSelectionOrigin,n==`select.pointer`&&(r=PO(i.facet(AD).map(t=>t(e)),r))),e.dispatch({selection:r,scrollIntoView:t,userEvent:n}),!0}return!1}function HO(e,t,n,r=-1){if(q.ios&&e.inputState.flushIOSKey(t))return!0;let i=e.state.selection.main;if(q.android&&(t.to==i.to&&(t.from==i.from||t.from==i.from-1&&e.state.sliceDoc(t.from,i.from)==` `)&&t.insert.length==1&&t.insert.lines==2&&OE(e.contentDOM,`Enter`,13)||(t.from==i.from-1&&t.to==i.to&&t.insert.length==0||r==8&&t.insert.length<t.to-t.from&&t.to>i.head)&&OE(e.contentDOM,`Backspace`,8)||t.from==i.from&&t.to==i.to+1&&t.insert.length==0&&OE(e.contentDOM,`Delete`,46)))return!0;let a=t.insert.toString();e.inputState.composing>=0&&e.inputState.composing++;let o,s=()=>o||=rte(e,t,n);return e.state.facet(lD).some(n=>n(e,t.from,t.to,a,s))||e.dispatch(s()),!0}function rte(e,t,n){let r,i=e.state,a=i.selection.main,o=-1;if(t.from==t.to&&t.from<a.from||t.from>a.to){let n=t.from<a.from?-1:1,r=n<0?a.from:a.to,s=NO(i.facet(AD).map(t=>t(e)),r,n);t.from==s&&(o=s)}if(o>-1)r={changes:t,selection:K.cursor(t.from+t.insert.length,-1)};else if(t.from>=a.from&&t.to<=a.to&&t.to-t.from>=(a.to-a.from)/3&&(!n||n.main.empty&&n.main.from==t.from+t.insert.length)&&e.inputState.composing<0){let n=a.from<t.from?i.sliceDoc(a.from,t.from):``,o=a.to>t.to?i.sliceDoc(t.to,a.to):``;r=i.replaceSelection(e.state.toText(n+t.insert.sliceString(0,void 0,e.state.lineBreak)+o))}else{let o=i.changes(t),s=n&&n.main.to<=o.newLength?n.main:void 0;if(i.selection.ranges.length>1&&(e.inputState.composing>=0||e.inputState.compositionPendingChange)&&t.to<=a.to+10&&t.to>=a.to-10){let c=e.state.sliceDoc(t.from,t.to),l,u=n&&gO(e,n.main.head);if(u){let e=t.insert.length-(t.to-t.from);l={from:u.from,to:u.to-e}}else l=e.state.doc.lineAt(a.head);let d=a.to-t.to;r=i.changeByRange(n=>{if(n.from==a.from&&n.to==a.to)return{changes:o,range:s||n.map(o)};let r=n.to-d,u=r-c.length;if(e.state.sliceDoc(u,r)!=c||r>=l.from&&u<=l.to)return{range:n};let f=i.changes({from:u,to:r,insert:t.insert}),p=n.to-a.to;return{changes:f,range:s?K.range(Math.max(0,s.anchor+p),Math.max(0,s.head+p)):n.map(f)}})}else r={changes:o,selection:s&&i.selection.replaceRange(s)}}let s=`input.type`;return(e.composing||e.inputState.compositionPendingChange&&e.inputState.compositionEndedAt>Date.now()-50)&&(e.inputState.compositionPendingChange=!1,s+=`.compose`,e.inputState.compositionFirstChange&&(s+=`.start`,e.inputState.compositionFirstChange=!1)),i.update(r,{userEvent:s,scrollIntoView:!0})}function UO(e,t,n,r){let i=Math.min(e.length,t.length),a=0;for(;a<i&&e.charCodeAt(a)==t.charCodeAt(a);)a++;if(a==i&&e.length==t.length)return null;let o=e.length,s=t.length;for(;o>0&&s>0&&e.charCodeAt(o-1)==t.charCodeAt(s-1);)o--,s--;if(r==`end`){let e=Math.max(0,a-Math.min(o,s));n-=o+e-a}if(o<a&&e.length<t.length){let e=n<=a&&n>=o?a-n:0;a-=e,s=a+(s-o),o=a}else if(s<a){let e=n<=a&&n>=s?a-n:0;a-=e,o=a+(o-s),s=a}return{from:a,toA:o,toB:s}}function ite(e){let t=[];if(e.root.activeElement!=e.contentDOM)return t;let{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:a}=e.observer.selectionRange;return n&&(t.push(new zO(n,r)),(i!=n||a!=r)&&t.push(new zO(i,a))),t}function ate(e,t){if(e.length==0)return null;let n=e[0].pos,r=e.length==2?e[1].pos:n;return n<0||r<0?null:n==r?K.create([K.cursor(r+t,-1)]):K.single(n+t,r+t)}function WO(e,t){return t.head==e.main.head&&t.anchor==e.main.anchor}var ote=class{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.touchActive=!1,this.lastTouchTime=0,this.lastTouchX=0,this.lastTouchY=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.lastWheelEvent=0,this.pendingIOSKey=void 0,this.lastIOSMomentumScroll=0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.insertingText=``,this.insertingTextAt=0,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,q.safari&&e.contentDOM.addEventListener(`input`,()=>null),q.gecko&&Ste(e.contentDOM.ownerDocument)}handleEvent(e){hte(this.view,e)&&!this.ignoreDuringComposition(e)&&(e.type==`keydown`&&this.keydown(e)||(this.view.updateState==0?this.runHandlers(e.type,e):Promise.resolve().then(()=>this.runHandlers(e.type,e))))}runHandlers(e,t){let n=this.handlers[e];if(n){for(let e of n.observers)e(this.view,t);for(let e of n.handlers){if(t.defaultPrevented)break;if(e(this.view,t)){t.preventDefault();break}}}}ensureHandlers(e){let t=cte(e),n=this.handlers,r=this.view.contentDOM;for(let e in t)if(e!=`scroll`){let i=!t[e].handlers.length,a=n[e];a&&i!=!a.handlers.length&&(r.removeEventListener(e,this.handleEvent),a=null),a||r.addEventListener(e,this.handleEvent,{passive:i})}for(let e in n)e!=`scroll`&&!t[e]&&r.removeEventListener(e,this.handleEvent);this.handlers=t}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&e.keyCode!=27&&qO.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),q.android&&q.chrome&&!e.synthetic&&(e.keyCode==13||e.keyCode==8))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;if(q.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&(KO.some(t=>t.keyCode==e.keyCode)&&!e.ctrlKey||lte.indexOf(e.key)>-1&&e.ctrlKey)){let t={ctrlKey:e.ctrlKey,altKey:e.altKey,metaKey:e.metaKey,shiftKey:e.shiftKey};t.shiftKey&&q.ios&&!/^(off|none)$/.test(this.view.contentDOM.autocapitalize)&&ste(this.view.win)&&(t.shiftKey=!1);let n=this.pendingIOSKey={key:e.key,keyCode:e.keyCode,mods:t};return setTimeout(()=>{this.pendingIOSKey==n&&this.flushIOSKey()},50),!0}return e.keyCode!=229&&this.view.observer.forceFlush(),!1}flushIOSKey(e){let t=this.pendingIOSKey;return!t||this.view.observer.pendingRecords().length||t.key==`Enter`&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString())?!1:(this.pendingIOSKey=void 0,OE(this.view.contentDOM,t.key,t.keyCode,t.mods))}ignoreDuringComposition(e){return!/^key/.test(e.type)||e.synthetic?!1:this.composing>0?!0:q.safari&&!q.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100?(this.compositionPendingKey=!1,!0):!1}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}};function ste(e){return e.visualViewport?e.visualViewport.height*e.visualViewport.scale/e.document.documentElement.clientHeight<.85:!1}function GO(e,t){return(n,r)=>{try{return t.call(e,r,n)}catch(e){yD(n.state,e)}}}function cte(e){let t=Object.create(null);function n(e){return t[e]||(t[e]={observers:[],handlers:[]})}for(let t of e){let e=t.spec,r=e&&e.plugin.domEventHandlers,i=e&&e.plugin.domEventObservers;if(r)for(let e in r){let i=r[e];i&&n(e).handlers.push(GO(t.value,i))}if(i)for(let e in i){let r=i[e];r&&n(e).observers.push(GO(t.value,r))}}for(let e in XO)n(e).handlers.push(XO[e]);for(let e in ZO)n(e).observers.push(ZO[e]);return t}var KO=[{key:`Backspace`,keyCode:8,inputType:`deleteContentBackward`},{key:`Enter`,keyCode:13,inputType:`insertParagraph`},{key:`Enter`,keyCode:13,inputType:`insertLineBreak`},{key:`Delete`,keyCode:46,inputType:`deleteContentForward`}],lte=`dthko`,qO=[16,17,18,20,91,92,224,225],JO=6;function YO(e){return Math.max(0,e)*.7+8}function ute(e,t){return Math.max(Math.abs(e.clientX-t.clientX),Math.abs(e.clientY-t.clientY))}var dte=class{constructor(e,t,n,r){this.view=e,this.startEvent=t,this.style=n,this.mustSelect=r,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=t,this.scrollParents=bE(e.contentDOM),this.atoms=e.state.facet(AD).map(t=>t(e));let i=e.contentDOM.ownerDocument;i.addEventListener(`mousemove`,this.move=this.move.bind(this)),i.addEventListener(`mouseup`,this.up=this.up.bind(this)),this.extend=t.shiftKey,this.multiple=e.state.facet(Yw.allowMultipleSelections)&&fte(e,t),this.dragging=mte(e,t)&&ak(t)==1?null:!1}start(e){this.dragging===!1&&this.select(e)}move(e){if(e.buttons==0)return this.destroy();if(this.dragging||this.dragging==null&&ute(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let t=0,n=0,r=0,i=0,a=this.view.win.innerWidth,o=this.view.win.innerHeight;this.scrollParents.x&&({left:r,right:a}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:i,bottom:o}=this.scrollParents.y.getBoundingClientRect());let s=FD(this.view);e.clientX-s.left<=r+JO?t=-YO(r-e.clientX):e.clientX+s.right>=a-JO&&(t=YO(e.clientX-a)),e.clientY-s.top<=i+JO?n=-YO(i-e.clientY):e.clientY+s.bottom>=o-JO&&(n=YO(e.clientY-o)),this.setScrollSpeed(t,n)}up(e){this.dragging??this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener(`mousemove`,this.move),e.removeEventListener(`mouseup`,this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,t){this.scrollSpeed={x:e,y:t},e||t?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:t}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),t&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=t,t=0),(e||t)&&this.view.win.scrollBy(e,t),this.dragging===!1&&this.select(this.lastEvent)}select(e){let{view:t}=this,n=PO(this.atoms,this.style.get(e,this.extend,this.multiple));(this.mustSelect||!n.eq(t.state.selection,this.dragging===!1))&&this.view.dispatch({selection:n,userEvent:`select.pointer`}),this.mustSelect=!1}update(e){e.transactions.some(e=>e.isUserEvent(`input.type`))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}};function fte(e,t){let n=e.state.facet(iD);return n.length?n[0](t):q.mac?t.metaKey:t.ctrlKey}function pte(e,t){let n=e.state.facet(aD);return n.length?n[0](t):q.mac?!t.altKey:!t.ctrlKey}function mte(e,t){let{main:n}=e.state.selection;if(n.empty)return!1;let r=sE(e.root);if(!r||r.rangeCount==0)return!0;let i=r.getRangeAt(0).getClientRects();for(let e=0;e<i.length;e++){let n=i[e];if(n.left<=t.clientX&&n.right>=t.clientX&&n.top<=t.clientY&&n.bottom>=t.clientY)return!0}return!1}function hte(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let n=t.target,r;n!=e.contentDOM;n=n.parentNode)if(!n||n.nodeType==11||(r=BD.get(n))&&r.isWidget()&&!r.isHidden&&r.widget.ignoreEvent(t))return!1;return!0}var XO=Object.create(null),ZO=Object.create(null),QO=q.ie&&q.ie_version<15||q.ios&&q.webkit_version<604;function gte(e){let t=e.dom.parentNode;if(!t)return;let n=t.appendChild(document.createElement(`textarea`));n.style.cssText=`position: fixed; left: -10000px; top: 10px`,n.focus(),setTimeout(()=>{e.focus(),n.remove(),ek(e,n.value)},50)}function $O(e,t,n){for(let r of e.facet(t))n=r(n,e);return n}function ek(e,t){t=$O(e.state,dD,t);let{state:n}=e,r,i=1,a=n.toText(t),o=a.lines==n.selection.ranges.length;if(sk!=null&&n.selection.ranges.every(e=>e.empty)&&sk==a.toString()){let e=-1;r=n.changeByRange(r=>{let s=n.doc.lineAt(r.from);if(s.from==e)return{range:r};e=s.from;let c=n.toText((o?a.line(i++).text:t)+n.lineBreak);return{changes:{from:s.from,insert:c},range:K.cursor(r.from+c.length,-1)}})}else r=o?n.changeByRange(e=>{let t=a.line(i++);return{changes:{from:e.from,to:e.to,insert:t.text},range:K.cursor(e.from+t.length,-1)}}):n.replaceSelection(a);e.dispatch(r,{userEvent:`input.paste`,scrollIntoView:!0})}ZO.scroll=e=>{let t=e.inputState;t.lastScrollTop=e.scrollDOM.scrollTop,t.lastScrollLeft=e.scrollDOM.scrollLeft,q.ios&&!t.touchActive&&(t.lastIOSMomentumScroll=Date.now())},ZO.wheel=ZO.mousewheel=e=>{e.inputState.lastWheelEvent=Date.now()},XO.keydown=(e,t)=>(e.inputState.setSelectionOrigin(`select`),t.keyCode==27&&e.inputState.tabFocusMode!=0&&(e.inputState.tabFocusMode=Date.now()+2e3),!1),ZO.touchstart=(e,t)=>{let n=e.inputState,r=t.targetTouches[0];n.touchActive=!0,n.lastTouchTime=Date.now(),r&&(n.lastTouchX=r.clientX,n.lastTouchY=r.clientY),n.setSelectionOrigin(`select.pointer`)},ZO.touchmove=e=>{e.inputState.setSelectionOrigin(`select.pointer`)},ZO.touchend=(e,t)=>{e.inputState.touchActive=!1},XO.mousedown=(e,t)=>{if(e.observer.flush(),e.inputState.lastTouchTime>Date.now()-2e3)return!1;let n=null;for(let r of e.state.facet(oD))if(n=r(e,t),n)break;if(!n&&t.button==0&&(n=vte(e,t)),n){let r=!e.hasFocus;e.inputState.startMouseSelection(new dte(e,t,n,r)),r&&e.observer.ignore(()=>{TE(e.contentDOM);let t=e.root.activeElement;t&&!t.contains(e.contentDOM)&&t.blur()});let i=e.inputState.mouseSelection;if(i)return i.start(t),i.dragging===!1}else e.inputState.setSelectionOrigin(`select.pointer`);return!1};function tk(e,t,n,r){if(r==1)return K.cursor(t,n);if(r==2)return EO(e.state,t,n);{let r=e.docView.lineAt(t,n),i=e.state.doc.lineAt(r?r.posAtEnd:t),a=r?r.posAtStart:i.from,o=r?r.posAtEnd:i.to;return o<e.state.doc.length&&o==i.to&&o++,K.undirectionalRange(a,o)}}var _te=q.ie&&q.ie_version<=11,nk=null,rk=0,ik=0;function ak(e){if(!_te)return e.detail;let t=nk,n=ik;return nk=e,ik=Date.now(),rk=!t||n>Date.now()-400&&Math.abs(t.clientX-e.clientX)<2&&Math.abs(t.clientY-e.clientY)<2?(rk+1)%3:1}function vte(e,t){let n=e.posAndSideAtCoords({x:t.clientX,y:t.clientY},!1),r=ak(t),i=e.state.selection;return{update(e){e.docChanged&&(n.pos=e.changes.mapPos(n.pos),i=i.map(e.changes))},get(t,a,o){let s=e.posAndSideAtCoords({x:t.clientX,y:t.clientY},!1),c,l=tk(e,s.pos,s.assoc,r);if(n.pos!=s.pos&&!a){let t=tk(e,n.pos,n.assoc,r),i=Math.min(t.from,l.from),a=Math.max(t.to,l.to);l=i<l.from?K.range(i,a,l.assoc):K.range(a,i,l.assoc)}return a?i.replaceRange(i.main.extend(l.from,l.to,l.assoc)):o&&r==1&&i.ranges.length>1&&(c=yte(i,s.pos))?c:o?i.addRange(l):K.create([l])}}}function yte(e,t){for(let n=0;n<e.ranges.length;n++){let{from:r,to:i}=e.ranges[n];if(r<=t&&i>=t)return K.create(e.ranges.slice(0,n).concat(e.ranges.slice(n+1)),e.mainIndex==n?0:e.mainIndex-+(e.mainIndex>n))}return null}XO.dragstart=(e,t)=>{let{selection:{main:n}}=e.state;if(t.target.draggable){let r=e.docView.tile.nearest(t.target);if(r&&r.isWidget()){let e=r.posAtStart,t=e+r.length;(e>=n.to||t<=n.from)&&(n=K.undirectionalRange(e,t))}}let{inputState:r}=e;return r.mouseSelection&&(r.mouseSelection.dragging=!0),r.draggedContent=n,t.dataTransfer&&(t.dataTransfer.setData(`Text`,$O(e.state,fD,e.state.sliceDoc(n.from,n.to))),t.dataTransfer.effectAllowed=`copyMove`),!1},XO.dragend=e=>(e.inputState.draggedContent=null,!1);function ok(e,t,n,r){if(n=$O(e.state,dD,n),!n)return;let i=e.posAtCoords({x:t.clientX,y:t.clientY},!1),{draggedContent:a}=e.inputState,o=r&&a&&pte(e,t)?{from:a.from,to:a.to}:null,s={from:i,insert:n},c=e.state.changes(o?[o,s]:s);e.focus(),e.dispatch({changes:c,selection:{anchor:c.mapPos(i,-1),head:c.mapPos(i,1)},userEvent:o?`move.drop`:`input.drop`}),e.inputState.draggedContent=null}XO.drop=(e,t)=>{if(!t.dataTransfer)return!1;if(e.state.readOnly)return!0;let n=t.dataTransfer.files;if(n&&n.length){let r=Array(n.length),i=0,a=()=>{++i==n.length&&ok(e,t,r.filter(e=>e!=null).join(e.state.lineBreak),!1)};for(let e=0;e<n.length;e++){let t=new FileReader;t.onerror=a,t.onload=()=>{/[\x00-\x08\x0e-\x1f]{2}/.test(t.result)||(r[e]=t.result),a()},t.readAsText(n[e])}return!0}{let n=t.dataTransfer.getData(`Text`);if(n)return ok(e,t,n,!0),!0}return!1},XO.paste=(e,t)=>{if(e.state.readOnly)return!0;e.observer.flush();let n=QO?null:t.clipboardData;return n?(ek(e,n.getData(`text/plain`)||n.getData(`text/uri-list`)),!0):(gte(e),!1)};function bte(e,t){let n=e.dom.parentNode;if(!n)return;let r=n.appendChild(document.createElement(`textarea`));r.style.cssText=`position: fixed; left: -10000px; top: 10px`,r.value=t,r.focus(),r.selectionEnd=t.length,r.selectionStart=0,setTimeout(()=>{r.remove(),e.focus()},50)}function xte(e){let t=[],n=[],r=!1;for(let r of e.selection.ranges)r.empty||(t.push(e.sliceDoc(r.from,r.to)),n.push(r));if(!t.length){let i=-1;for(let{from:r}of e.selection.ranges){let a=e.doc.lineAt(r);a.number>i&&(t.push(a.text),n.push({from:a.from,to:Math.min(e.doc.length,a.to+1)})),i=a.number}r=!0}return{text:$O(e,fD,t.join(e.lineBreak)),ranges:n,linewise:r}}var sk=null;XO.copy=XO.cut=(e,t)=>{if(!lE(e.contentDOM,e.observer.selectionRange))return!1;let{text:n,ranges:r,linewise:i}=xte(e.state);if(!n&&!i)return!1;sk=i?n:null,t.type==`cut`&&!e.state.readOnly&&e.dispatch({changes:r,scrollIntoView:!0,userEvent:`delete.cut`});let a=QO?null:t.clipboardData;return a?(a.clearData(),a.setData(`text/plain`,n),!0):(bte(e,n),!1)};var ck=jw.define();function lk(e,t){let n=[];for(let r of e.facet(uD)){let i=r(e,t);i&&n.push(i)}return n.length?e.update({effects:n,annotations:ck.of(!0)}):null}function uk(e){setTimeout(()=>{let t=e.hasFocus;if(t!=e.inputState.notifiedFocused){let n=lk(e.state,t);n?e.dispatch(n):e.update([])}},10)}ZO.focus=e=>{e.inputState.lastFocusTime=Date.now(),!e.scrollDOM.scrollTop&&(e.inputState.lastScrollTop||e.inputState.lastScrollLeft)&&(e.scrollDOM.scrollTop=e.inputState.lastScrollTop,e.scrollDOM.scrollLeft=e.inputState.lastScrollLeft),uk(e)},ZO.blur=e=>{e.observer.clearSelectionRange(),uk(e)},ZO.compositionstart=ZO.compositionupdate=(e,t)=>{if(!e.observer.editContext&&(e.inputState.compositionFirstChange??(e.inputState.compositionFirstChange=!0),e.inputState.composing<0)){let{main:t}=e.state.selection;!t.empty&&e.lineBlockAt(t.from).from!=e.lineBlockAt(t.to).from&&!e.state.readOnly&&e.dispatch({changes:e.state.selection.ranges.filter(e=>!e.empty).map(e=>({from:e.from,to:e.to})),userEvent:`input`}),e.inputState.composing=0}},ZO.compositionend=e=>{e.observer.editContext||(e.inputState.composing=-1,e.inputState.compositionEndedAt=Date.now(),e.inputState.compositionPendingKey=!0,e.inputState.compositionPendingChange=e.observer.pendingRecords().length>0,e.inputState.compositionFirstChange=null,q.chrome&&q.android?e.observer.flushSoon():e.inputState.compositionPendingChange?Promise.resolve().then(()=>e.observer.flush()):setTimeout(()=>{e.inputState.composing<0&&e.docView.hasComposition&&e.update([])},50))},ZO.contextmenu=e=>{e.inputState.lastContextMenu=Date.now()},XO.beforeinput=(e,t)=>{if((t.inputType==`insertText`||t.inputType==`insertCompositionText`)&&(e.inputState.insertingText=t.data,e.inputState.insertingTextAt=Date.now()),t.inputType==`insertReplacementText`&&e.observer.editContext){let n=t.dataTransfer?.getData(`text/plain`),r=t.getTargetRanges();if(n&&r.length){let t=r[0];return HO(e,{from:e.posAtDOM(t.startContainer,t.startOffset),to:e.posAtDOM(t.endContainer,t.endOffset),insert:e.state.toText(n)},null),!0}}let n;if(q.chrome&&q.android&&(n=KO.find(e=>e.inputType==t.inputType))&&(e.observer.delayAndroidKey(n.key,n.keyCode),n.key==`Backspace`||n.key==`Delete`)){let t=window.visualViewport?.height||0;setTimeout(()=>{(window.visualViewport?.height||0)>t+10&&e.hasFocus&&(e.contentDOM.blur(),e.focus())},100)}return q.ios&&t.inputType==`deleteContentForward`&&e.observer.flushSoon(),q.safari&&t.inputType==`insertText`&&e.inputState.composing>=0&&setTimeout(()=>ZO.compositionend(e,t),20),!1};var dk=new Set;function Ste(e){dk.has(e)||(dk.add(e),e.addEventListener(`copy`,()=>{}),e.addEventListener(`cut`,()=>{}))}var fk=[`pre-wrap`,`normal`,`pre-line`,`break-spaces`],pk=!1;function mk(){pk=!1}var Cte=class{constructor(e){this.lineWrapping=e,this.doc=LC.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,t){let n=this.doc.lineAt(t).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(n+=Math.max(0,Math.ceil((t-e-n*this.lineLength*.5)/this.lineLength))),this.lineHeight*n}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/Math.max(1,this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return fk.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let t=!1;for(let n=0;n<e.length;n++){let r=e[n];r<0?n++:this.heightSamples[Math.floor(r*10)]||(t=!0,this.heightSamples[Math.floor(r*10)]=!0)}return t}refresh(e,t,n,r,i,a){let o=fk.indexOf(e)>-1,s=Math.abs(t-this.lineHeight)>.3||this.lineWrapping!=o;if(this.lineWrapping=o,this.lineHeight=t,this.charWidth=n,this.textHeight=r,this.lineLength=i,s){this.heightSamples={};for(let e=0;e<a.length;e++){let t=a[e];t<0?e++:this.heightSamples[Math.floor(t*10)]=!0}}return s}},wte=class{constructor(e,t){this.from=e,this.heights=t,this.index=0}get more(){return this.index<this.heights.length}},hk=class e{constructor(e,t,n,r,i){this.from=e,this.length=t,this.top=n,this.height=r,this._content=i}get type(){return typeof this._content==`number`?XT.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof eE?this._content.widget:null}get widgetLineBreaks(){return typeof this._content==`number`?this._content:0}join(t){let n=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(t._content)?t._content:[t]);return new e(this.from,this.length+t.length,this.top,this.height+t.height,n)}},gk=(function(e){return e[e.ByPos=0]=`ByPos`,e[e.ByHeight=1]=`ByHeight`,e[e.ByPosNoHeight=2]=`ByPosNoHeight`,e})(gk||={}),_k=.001,vk=class e{constructor(e,t,n=2){this.length=e,this.height=t,this.flags=n}get outdated(){return(this.flags&2)>0}set outdated(e){this.flags=(e?2:0)|this.flags&-3}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>_k&&(pk=!0),this.height=e)}replace(t,n,r){return e.of(r)}decomposeLeft(e,t){t.push(this)}decomposeRight(e,t){t.push(this)}applyChanges(e,t,n,r){let i=this,a=n.doc;for(let o=r.length-1;o>=0;o--){let{fromA:s,toA:c,fromB:l,toB:u}=r[o],d=i.lineAt(s,gk.ByPosNoHeight,n.setDoc(t),0,0),f=d.to>=c?d:i.lineAt(c,gk.ByPosNoHeight,n,0,0);for(u+=f.to-c,c=f.to;o>0&&d.from<=r[o-1].toA;)s=r[o-1].fromA,l=r[o-1].fromB,o--,s<d.from&&(d=i.lineAt(s,gk.ByPosNoHeight,n,0,0));l+=d.from-s,s=d.from;let p=Ote.build(n.setDoc(a),e,l,u);i=yk(i,i.replace(s,c,p))}return i.updateHeight(n,0)}static empty(){return new xk(0,0,0)}static of(t){if(t.length==1)return t[0];let n=0,r=t.length,i=0,a=0;for(;;)if(n==r){if(i>a*2){let e=t[n-1];e.break?t.splice(--n,1,e.left,null,e.right):t.splice(--n,1,e.left,e.right),r+=1+e.break,i-=e.size}else if(a>i*2){let e=t[r];e.break?t.splice(r,1,e.left,null,e.right):t.splice(r,1,e.left,e.right),r+=2+e.break,a-=e.size}else break}else if(i<a){let e=t[n++];e&&(i+=e.size)}else{let e=t[--r];e&&(a+=e.size)}let o=!1;return t[n-1]==null?(o=!0,n--):t[n]??(o=!0,r++),new Ete(e.of(t.slice(0,n)),o,e.of(t.slice(r)))}};function yk(e,t){return e==t?e:(e.constructor!=t.constructor&&(pk=!0),t)}vk.prototype.size=1;var Tte=ZT.replace({}),bk=class extends vk{constructor(e,t,n){super(e,t),this.deco=n,this.spaceAbove=0}mainBlock(e,t){return new hk(t,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.deco||0)}blockAt(e,t,n,r){return this.spaceAbove&&e<n+this.spaceAbove?new hk(r,0,n,this.spaceAbove,Tte):this.mainBlock(n,r)}lineAt(e,t,n,r,i){let a=this.mainBlock(r,i);return this.spaceAbove?this.blockAt(0,n,r,i).join(a):a}forEachLine(e,t,n,r,i,a){e<=i+this.length&&t>=i&&a(this.lineAt(0,gk.ByPos,n,r,i))}setMeasuredHeight(e){let t=e.heights[e.index++];t<0?(this.spaceAbove=-t,t=e.heights[e.index++]):this.spaceAbove=0,this.setHeight(t)}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more&&this.setMeasuredHeight(r),this.outdated=!1,this}toString(){return`block(${this.length})`}},xk=class e extends bk{constructor(e,t,n){super(e,t,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0,this.spaceAbove=n}mainBlock(e,t){return new hk(t,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.breaks)}replace(t,n,r){let i=r[0];return r.length==1&&(i instanceof e||i instanceof Sk&&i.flags&4)&&Math.abs(this.length-i.length)<10?(i instanceof Sk?i=new e(i.length,this.height,this.spaceAbove):i.height=this.height,this.outdated||(i.outdated=!1),i):vk.of(r)}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more?this.setMeasuredHeight(r):(n||this.outdated)&&(this.spaceAbove=0,this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight)),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:``}${this.widgetHeight?`:`+this.widgetHeight:``})`}},Sk=class e extends vk{constructor(e){super(e,0)}heightMetrics(e,t){let n=e.doc.lineAt(t).number,r=e.doc.lineAt(t+this.length).number,i=r-n+1,a,o=0;if(e.lineWrapping){let t=Math.min(this.height,e.lineHeight*i);a=t/i,this.length>i+1&&(o=(this.height-t)/(this.length-i-1))}else a=this.height/i;return{firstLine:n,lastLine:r,perLine:a,perChar:o}}blockAt(e,t,n,r){let{firstLine:i,lastLine:a,perLine:o,perChar:s}=this.heightMetrics(t,r);if(t.lineWrapping){let i=r+(e<t.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-n)/this.height))*this.length)),a=t.doc.lineAt(i),c=o+a.length*s,l=Math.max(n,e-c/2);return new hk(a.from,a.length,l,c,0)}{let r=Math.max(0,Math.min(a-i,Math.floor((e-n)/o))),{from:s,length:c}=t.doc.line(i+r);return new hk(s,c,n+o*r,o,0)}}lineAt(e,t,n,r,i){if(t==gk.ByHeight)return this.blockAt(e,n,r,i);if(t==gk.ByPosNoHeight){let{from:t,to:r}=n.doc.lineAt(e);return new hk(t,r-t,0,0,0)}let{firstLine:a,perLine:o,perChar:s}=this.heightMetrics(n,i),c=n.doc.lineAt(e),l=o+c.length*s,u=c.number-a,d=r+o*u+s*(c.from-i-u);return new hk(c.from,c.length,Math.max(r,Math.min(d,r+this.height-l)),l,0)}forEachLine(e,t,n,r,i,a){e=Math.max(e,i),t=Math.min(t,i+this.length);let{firstLine:o,perLine:s,perChar:c}=this.heightMetrics(n,i);for(let l=e,u=r;l<=t;){let t=n.doc.lineAt(l);if(l==e){let n=t.number-o;u+=s*n+c*(e-i-n)}let r=s+c*t.length;a(new hk(t.from,t.length,u,r,0)),u+=r,l=t.to+1}}replace(t,n,r){let i=this.length-n;if(i>0){let t=r[r.length-1];t instanceof e?r[r.length-1]=new e(t.length+i):r.push(null,new e(i-1))}if(t>0){let n=r[0];n instanceof e?r[0]=new e(t+n.length):r.unshift(new e(t-1),null)}return vk.of(r)}decomposeLeft(t,n){n.push(new e(t-1),null)}decomposeRight(t,n){n.push(null,new e(this.length-t-1))}updateHeight(t,n=0,r=!1,i){let a=n+this.length;if(i&&i.from<=n+this.length&&i.more){let r=[],o=Math.max(n,i.from),s=-1;for(i.from>n&&r.push(new e(i.from-n-1).updateHeight(t,n));o<=a&&i.more;){let e=t.doc.lineAt(o).length;r.length&&r.push(null);let n=i.heights[i.index++],a=0;n<0&&(a=-n,n=i.heights[i.index++]),s==-1?s=n:Math.abs(n-s)>=_k&&(s=-2);let c=new xk(e,n,a);c.outdated=!1,r.push(c),o+=e+1}o<=a&&r.push(null,new e(a-o).updateHeight(t,o));let c=vk.of(r);return(s<0||Math.abs(c.height-this.height)>=_k||Math.abs(s-this.heightMetrics(t,n).perLine)>=_k)&&(pk=!0),yk(this,c)}return(r||this.outdated)&&(this.setHeight(t.heightForGap(n,n+this.length)),this.outdated=!1),this}toString(){return`gap(${this.length})`}},Ete=class extends vk{constructor(e,t,n){super(e.length+ +!!t+n.length,e.height+n.height,+!!t|(e.outdated||n.outdated?2:0)),this.left=e,this.right=n,this.size=e.size+n.size}get break(){return this.flags&1}blockAt(e,t,n,r){let i=n+this.left.height;return e<i?this.left.blockAt(e,t,n,r):this.right.blockAt(e,t,i,r+this.left.length+this.break)}lineAt(e,t,n,r,i){let a=r+this.left.height,o=i+this.left.length+this.break,s=t==gk.ByHeight?e<a:e<o,c=s?this.left.lineAt(e,t,n,r,i):this.right.lineAt(e,t,n,a,o);if(this.break||(s?c.to<o:c.from>o))return c;let l=t==gk.ByPosNoHeight?gk.ByPosNoHeight:gk.ByPos;return s?c.join(this.right.lineAt(o,l,n,a,o)):this.left.lineAt(o,l,n,r,i).join(c)}forEachLine(e,t,n,r,i,a){let o=r+this.left.height,s=i+this.left.length+this.break;if(this.break)e<s&&this.left.forEachLine(e,t,n,r,i,a),t>=s&&this.right.forEachLine(e,t,n,o,s,a);else{let c=this.lineAt(s,gk.ByPos,n,r,i);e<c.from&&this.left.forEachLine(e,Math.min(t,c.from-1),n,r,i,a),c.to>=e&&c.from<=t&&a(c),t>c.to&&this.right.forEachLine(Math.max(e,c.to+1),t,n,o,s,a)}}replace(e,t,n){let r=this.left.length+this.break;if(t<r)return this.balanced(this.left.replace(e,t,n),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-r,t-r,n));let i=[];e>0&&this.decomposeLeft(e,i);let a=i.length;for(let e of n)i.push(e);if(e>0&&Ck(i,a-1),t<this.length){let e=i.length;this.decomposeRight(t,i),Ck(i,e)}return vk.of(i)}decomposeLeft(e,t){let n=this.left.length;if(e<=n)return this.left.decomposeLeft(e,t);t.push(this.left),this.break&&(n++,e>=n&&t.push(null)),e>n&&this.right.decomposeLeft(e-n,t)}decomposeRight(e,t){let n=this.left.length,r=n+this.break;if(e>=r)return this.right.decomposeRight(e-r,t);e<n&&this.left.decomposeRight(e,t),this.break&&e<r&&t.push(null),t.push(this.right)}balanced(e,t){return e.size>2*t.size||t.size>2*e.size?vk.of(this.break?[e,null,t]:[e,t]):(this.left=yk(this.left,e),this.right=yk(this.right,t),this.setHeight(e.height+t.height),this.outdated=e.outdated||t.outdated,this.size=e.size+t.size,this.length=e.length+this.break+t.length,this)}updateHeight(e,t=0,n=!1,r){let{left:i,right:a}=this,o=t+i.length+this.break,s=null;return r&&r.from<=t+i.length&&r.more?s=i=i.updateHeight(e,t,n,r):i.updateHeight(e,t,n),r&&r.from<=o+a.length&&r.more?s=a=a.updateHeight(e,o,n,r):a.updateHeight(e,o,n),s?this.balanced(i,a):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?` `:`-`)+this.right}};function Ck(e,t){let n,r;e[t]==null&&(n=e[t-1])instanceof Sk&&(r=e[t+1])instanceof Sk&&e.splice(t-1,3,new Sk(n.length+1+r.length))}var Dte=5,Ote=class e{constructor(e,t){this.pos=e,this.oracle=t,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,t){if(this.lineStart>-1){let e=Math.min(t,this.lineEnd),n=this.nodes[this.nodes.length-1];n instanceof xk?n.length+=e-this.pos:(e>this.pos||!this.isCovered)&&this.nodes.push(new xk(e-this.pos,-1,0)),this.writtenTo=e,t>e&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=t}point(e,t,n){if(e<t||n.heightRelevant){let r=n.widget?n.widget.estimatedHeight:0,i=n.widget?n.widget.lineBreaks:0;r<0&&(r=this.oracle.lineHeight);let a=t-e;n.block?this.addBlock(new bk(a,r,n)):(a||i||r>=Dte)&&this.addLineDeco(r,i,a)}else t>e&&this.span(e,t);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:t}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=t,this.writtenTo<e&&((this.writtenTo<e-1||this.nodes[this.nodes.length-1]==null)&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new xk(this.pos-e,-1,0)),this.writtenTo=this.pos}blankContent(e,t){let n=new Sk(t-e);return this.oracle.doc.lineAt(e).to==t&&(n.flags|=4),n}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof xk)return e;let t=new xk(0,-1,0);return this.nodes.push(t),t}addBlock(e){this.enterLine();let t=e.deco;t&&t.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos+=e.length,t&&t.endSide>0&&(this.covering=e)}addLineDeco(e,t,n){let r=this.ensureLine();r.length+=n,r.collapsed+=n,r.widgetHeight=Math.max(r.widgetHeight,e),r.breaks+=t,this.writtenTo=this.pos+=n}finish(e){let t=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(t instanceof xk)&&!this.isCovered?this.nodes.push(new xk(0,-1,0)):(this.writtenTo<this.pos||t==null)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos));let n=e;for(let e of this.nodes)e instanceof xk&&e.updateHeight(this.oracle,n),n+=e?e.length:1;return this.nodes}static build(t,n,r,i){let a=new e(r,t);return nT.spans(n,r,i,a,0),a.finish(r)}};function kte(e,t,n){let r=new Ate;return nT.compare(e,t,n,r,0),r.changes}var Ate=class{constructor(){this.changes=[]}compareRange(){}comparePoint(e,t,n,r){(e<t||n&&n.heightRelevant||r&&r.heightRelevant)&&rE(e,t,this.changes,5)}};function jte(e,t){let n=e.getBoundingClientRect(),r=e.ownerDocument,i=r.defaultView||window,a=Math.max(0,n.left),o=Math.min(i.innerWidth,n.right),s=Math.max(0,n.top),c=Math.min(i.innerHeight,n.bottom);for(let t=e.parentNode;t&&t!=r.body;)if(aE(t)){let n=window.getComputedStyle(t);if((t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth)&&n.overflow!=`visible`){let n=t.getBoundingClientRect();a=Math.max(a,n.left),o=Math.min(o,n.right),s=Math.max(s,n.top),c=Math.min(t==e.parentNode?i.innerHeight:c,n.bottom)}t=n.position==`absolute`||n.position==`fixed`?t.offsetParent:t.parentNode}else if(t.nodeType==11)t=t.host;else break;return{left:a-n.left,right:Math.max(a,o)-n.left,top:s-(n.top+t),bottom:Math.max(s,c)-(n.top+t)}}function Mte(e){let t=e.getBoundingClientRect(),n=e.ownerDocument.defaultView||window;return t.left<n.innerWidth&&t.right>0&&t.top<n.innerHeight&&t.bottom>0}function Nte(e,t){let n=e.getBoundingClientRect();return{left:0,right:n.right-n.left,top:t,bottom:n.bottom-(n.top+t)}}var wk=class{constructor(e,t,n,r){this.from=e,this.to=t,this.size=n,this.displaySize=r}static same(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t[n];if(r.from!=i.from||r.to!=i.to||r.size!=i.size)return!1}return!0}draw(e,t){return ZT.replace({widget:new Pte(this.displaySize*(t?e.scaleY:e.scaleX),t)}).range(this.from,this.to)}},Pte=class extends YT{constructor(e,t){super(),this.size=e,this.vertical=t}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement(`div`);return this.vertical?e.style.height=this.size+`px`:(e.style.width=this.size+`px`,e.style.height=`2px`,e.style.display=`inline-block`),e}get estimatedHeight(){return this.vertical?this.size:-1}},Tk=class{constructor(e,t){this.view=e,this.state=t,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scaleX=1,this.scaleY=1,this.scrollOffset=0,this.scrolledToBottom=!1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=kk,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=FE.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let n=t.facet(ED).some(e=>typeof e!=`function`&&e.class==`cm-lineWrapping`);this.heightOracle=new Cte(n),this.stateDeco=Ak(t),this.heightMap=vk.empty().applyChanges(this.stateDeco,LC.empty,this.heightOracle.setDoc(t.doc),[new LD(0,0,0,t.doc.length)]);for(let e=0;e<2&&(this.viewport=this.getViewport(0,null),this.updateForViewport());e++);this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=ZT.set(this.lineGaps.map(e=>e.draw(this,!1))),this.scrollParent=e.scrollDOM,this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:t}=this.state.selection;for(let n=0;n<=1;n++){let r=n?t.head:t.anchor;if(!e.some(({from:e,to:t})=>r>=e&&r<=t)){let{from:t,to:n}=this.lineBlockAt(r);e.push(new Ek(t,n))}}return this.viewports=e.sort((e,t)=>e.from-t.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?kk:Lte.get(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(jk(e,this.scaler))})}update(e,t=null){this.state=e.state;let n=this.stateDeco;this.stateDeco=Ak(this.state);let r=e.changedRanges,i=LD.extendWithRanges(r,kte(n,this.stateDeco,e?e.changes:XC.empty(this.state.doc.length))),a=this.heightMap.height,o=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollOffset);mk(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),i),(this.heightMap.height!=a||pk)&&(e.flags|=2),o?(this.scrollAnchorPos=e.changes.mapPos(o.from,-1),this.scrollAnchorHeight=o.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=a);let s=i.length?this.mapViewport(this.viewport,e.changes):this.viewport;(t&&(t.range.head<s.from||t.range.head>s.to)||!this.viewportIsAppropriate(s))&&(s=this.getViewport(0,t));let c=s.from!=this.viewport.from||s.to!=this.viewport.to;this.viewport=s,e.flags|=this.updateForViewport(),(c||!e.changes.empty||e.flags&2)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),t&&(this.scrollTarget=t),!this.mustEnforceCursorAssoc&&(e.selectionSet||e.focusChanged)&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(mD)&&(this.mustEnforceCursorAssoc=!0)}measure(){let{view:e}=this,t=e.contentDOM,n=window.getComputedStyle(t),r=this.heightOracle,i=n.whiteSpace;this.defaultTextDirection=n.direction==`rtl`?FE.RTL:FE.LTR;let a=this.heightOracle.mustRefreshForWrapping(i)||this.mustMeasureContent===`refresh`,o=t.getBoundingClientRect(),s=a||this.mustMeasureContent||this.contentDOMHeight!=o.height;this.contentDOMHeight=o.height,this.mustMeasureContent=!1;let c=0,l=0;if(o.width&&o.height){let{scaleX:e,scaleY:n}=vE(t,o);(e>.005&&Math.abs(this.scaleX-e)>.005||n>.005&&Math.abs(this.scaleY-n)>.005)&&(this.scaleX=e,this.scaleY=n,c|=16,a=s=!0)}let u=(parseInt(n.paddingTop)||0)*this.scaleY,d=(parseInt(n.paddingBottom)||0)*this.scaleY;(this.paddingTop!=u||this.paddingBottom!=d)&&(this.paddingTop=u,this.paddingBottom=d,c|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(r.lineWrapping&&(s=!0),this.editorWidth=e.scrollDOM.clientWidth,c|=16);let f=bE(this.view.contentDOM,!1).y;f!=this.scrollParent&&(this.scrollParent=f,this.scrollAnchorHeight=-1,this.scrollOffset=0);let p=this.getScrollOffset();this.scrollOffset!=p&&(this.scrollAnchorHeight=-1,this.scrollOffset=p),this.scrolledToBottom=jE(this.scrollParent||e.win);let m=(this.printing?Nte:jte)(t,this.paddingTop),h=m.top-this.pixelViewport.top,g=m.bottom-this.pixelViewport.bottom;this.pixelViewport=m;let _=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(_!=this.inView&&(this.inView=_,_&&(s=!0)),!this.inView&&!this.scrollTarget&&!Mte(e.dom))return 0;let v=o.width;if((this.contentDOMWidth!=v||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=o.width,this.editorHeight=e.scrollDOM.clientHeight,c|=16),s){let t=e.docView.measureVisibleLineHeights(this.viewport);if(r.mustRefreshForHeights(t)&&(a=!0),a||r.lineWrapping&&Math.abs(v-this.contentDOMWidth)>r.charWidth){let{lineHeight:n,charWidth:o,textHeight:s}=e.docView.measureTextSize();a=n>0&&r.refresh(i,n,o,s,Math.max(5,v/o),t),a&&(e.docView.minWidth=0,c|=16)}h>0&&g>0?l=Math.max(h,g):h<0&&g<0&&(l=Math.min(h,g)),mk();for(let n of this.viewports){let i=n.from==this.viewport.from?t:e.docView.measureVisibleLineHeights(n);this.heightMap=(a?vk.empty().applyChanges(this.stateDeco,LC.empty,this.heightOracle,[new LD(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(r,0,a,new wte(n.from,i))}pk&&(c|=2)}let y=!this.viewportIsAppropriate(this.viewport,l)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return y&&(c&2&&(c|=this.updateScaler()),this.viewport=this.getViewport(l,this.scrollTarget),c|=this.updateForViewport()),(c&2||y)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(a?[]:this.lineGaps,e)),c|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),c}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,t){let n=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),r=this.heightMap,i=this.heightOracle,{visibleTop:a,visibleBottom:o}=this,s=new Ek(r.lineAt(a-n*1e3,gk.ByHeight,i,0,0).from,r.lineAt(o+(1-n)*1e3,gk.ByHeight,i,0,0).to);if(t){let{head:e}=t.range;if(e<s.from||e>s.to){let n=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),a=r.lineAt(e,gk.ByPos,i,0,0),o;o=t.y==`center`?(a.top+a.bottom)/2-n/2:t.y==`start`||t.y==`nearest`&&e<s.from?a.top:a.bottom-n,s=new Ek(r.lineAt(o-500,gk.ByHeight,i,0,0).from,r.lineAt(o+n+500,gk.ByHeight,i,0,0).to)}}return s}mapViewport(e,t){let n=t.mapPos(e.from,-1),r=t.mapPos(e.to,1);return new Ek(this.heightMap.lineAt(n,gk.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(r,gk.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:t},n=0){if(!this.inView)return!0;let{top:r}=this.heightMap.lineAt(e,gk.ByPos,this.heightOracle,0,0),{bottom:i}=this.heightMap.lineAt(t,gk.ByPos,this.heightOracle,0,0),{visibleTop:a,visibleBottom:o}=this;return(e==0||r<=a-Math.max(10,Math.min(-n,250)))&&(t==this.state.doc.length||i>=o+Math.max(10,Math.min(n,250)))&&r>a-2e3&&i<o+2e3}mapLineGaps(e,t){if(!e.length||t.empty)return e;let n=[];for(let r of e)t.touchesRange(r.from,r.to)||n.push(new wk(t.mapPos(r.from),t.mapPos(r.to),r.size,r.displaySize));return n}ensureLineGaps(e,t){let n=this.heightOracle.lineWrapping,r=n?1e4:2e3,i=r>>1,a=r<<1;if(this.defaultTextDirection!=FE.LTR&&!n)return[];let o=[],s=(r,a,c,l)=>{if(a-r<i)return;let u=this.state.selection.main,d=[u.from];u.empty||d.push(u.to);for(let e of d)if(e>r&&e<a){s(r,e-10,c,l),s(e+10,a,c,l);return}let f=Ite(e,e=>e.from>=c.from&&e.to<=c.to&&Math.abs(e.from-r)<i&&Math.abs(e.to-a)<i&&!d.some(t=>e.from<t&&e.to>t));if(!f){if(a<c.to&&t&&n&&t.visibleRanges.some(e=>e.from<=a&&e.to>=a)){let e=t.moveToLineBoundary(K.cursor(a),!1,!0).head;e>r&&(a=e)}let e=this.gapSize(c,r,a,l);f=new wk(r,a,e,n||e<2e6?e:2e6)}o.push(f)},c=t=>{if(t.length<a||t.type!=XT.Text)return;let i=Fte(t.from,t.to,this.stateDeco);if(i.total<a)return;let o=this.scrollTarget?this.scrollTarget.range.head:null,c,l;if(n){let e=r/this.heightOracle.lineLength*this.heightOracle.lineHeight,n,a;if(o!=null){let r=Ok(i,o),s=((this.visibleBottom-this.visibleTop)/2+e)/t.height;n=r-s,a=r+s}else n=(this.visibleTop-t.top-e)/t.height,a=(this.visibleBottom-t.top+e)/t.height;c=Dk(i,n),l=Dk(i,a)}else{let n=i.total*this.heightOracle.charWidth,a=r*this.heightOracle.charWidth,s=0;if(n>2e6)for(let n of e)n.from>=t.from&&n.from<t.to&&n.size!=n.displaySize&&n.from*this.heightOracle.charWidth+s<this.pixelViewport.left&&(s=n.size-n.displaySize);let u=this.pixelViewport.left+s,d=this.pixelViewport.right+s,f,p;if(o!=null){let e=Ok(i,o),t=((d-u)/2+a)/n;f=e-t,p=e+t}else f=(u-a)/n,p=(d+a)/n;c=Dk(i,f),l=Dk(i,p)}c>t.from&&s(t.from,c,t,i),l<t.to&&s(l,t.to,t,i)};for(let e of this.viewportLines)Array.isArray(e.type)?e.type.forEach(c):c(e);return o}gapSize(e,t,n,r){let i=Ok(r,n)-Ok(r,t);return this.heightOracle.lineWrapping?e.height*i:r.total*this.heightOracle.charWidth*i}updateLineGaps(e){wk.same(e,this.lineGaps)||(this.lineGaps=e,this.lineGapDeco=ZT.set(e.map(e=>e.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let t=this.stateDeco;this.lineGaps.length&&(t=t.concat(this.lineGapDeco));let n=[];nT.spans(t,this.viewport.from,this.viewport.to,{span(e,t){n.push({from:e,to:t})},point(){}},20);let r=0;if(n.length!=this.visibleRanges.length)r=12;else for(let t=0;t<n.length&&!(r&8);t++){let i=this.visibleRanges[t],a=n[t];(i.from!=a.from||i.to!=a.to)&&(r|=4,e&&e.mapPos(i.from,-1)==a.from&&e.mapPos(i.to,1)==a.to||(r|=8))}return this.visibleRanges=n,r}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(t=>t.from<=e&&t.to>=e)||jk(this.heightMap.lineAt(e,gk.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(t=>t.top<=e&&t.bottom>=e)||jk(this.heightMap.lineAt(this.scaler.fromDOM(e),gk.ByHeight,this.heightOracle,0,0),this.scaler)}getScrollOffset(){return this.scrollParent==this.view.scrollDOM?this.scrollParent.scrollTop*this.scaleY:(this.scrollParent?this.scrollParent.getBoundingClientRect().top:0)-this.view.contentDOM.getBoundingClientRect().top}scrollAnchorAt(e){let t=this.lineBlockAtHeight(e+12-this.paddingTop);return t.from>=this.viewport.from||this.viewportLines[0].top-e>200?t:this.viewportLines[0]}elementAtHeight(e){return jk(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}},Ek=class{constructor(e,t){this.from=e,this.to=t}};function Fte(e,t,n){let r=[],i=e,a=0;return nT.spans(n,e,t,{span(){},point(e,t){e>i&&(r.push({from:i,to:e}),a+=e-i),i=t}},20),i<t&&(r.push({from:i,to:t}),a+=t-i),{total:a,ranges:r}}function Dk({total:e,ranges:t},n){if(n<=0)return t[0].from;if(n>=1)return t[t.length-1].to;let r=Math.floor(e*n);for(let e=0;;e++){let{from:n,to:i}=t[e],a=i-n;if(r<=a)return n+r;r-=a}}function Ok(e,t){let n=0;for(let{from:r,to:i}of e.ranges){if(t<=i){n+=t-r;break}n+=i-r}return n/e.total}function Ite(e,t){for(let n of e)if(t(n))return n}var kk={toDOM(e){return e},fromDOM(e){return e},scale:1,eq(e){return e==this}};function Ak(e){let t=e.facet(DD).filter(e=>typeof e!=`function`),n=e.facet(kD).filter(e=>typeof e!=`function`);return n.length&&t.push(nT.join(n)),t}var Lte=class e{constructor(e,t){this.scale=e,this.viewports=t}static get(t,n,r){let i=0,a=0,o=0,s=r.map(({from:e,to:r})=>{let a=n.lineAt(e,gk.ByPos,t,0,0).top,o=n.lineAt(r,gk.ByPos,t,0,0).bottom;return i+=o-a,{from:e,to:r,top:a,bottom:o,domTop:0,domBottom:0}});if(n.height-i<10)return kk;let c=(7e6-i)/(n.height-i);for(let e of s)e.domTop=o+(e.top-a)*c,o=e.domBottom=e.domTop+(e.bottom-e.top),a=e.bottom;return new e(c,s)}toDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.top)return r+(e-n)*this.scale;if(e<=i.bottom)return i.domTop+(e-i.top);n=i.bottom,r=i.domBottom}}fromDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.domTop)return n+(e-r)/this.scale;if(e<=i.domBottom)return i.top+(e-i.domTop);n=i.bottom,r=i.domBottom}}eq(t){return t instanceof e&&this.scale==t.scale&&this.viewports.length==t.viewports.length&&this.viewports.every((e,n)=>e.from==t.viewports[n].from&&e.to==t.viewports[n].to)}};function jk(e,t){if(t.scale==1)return e;let n=t.toDOM(e.top),r=t.toDOM(e.bottom);return new hk(e.from,e.length,n,r-n,Array.isArray(e._content)?e._content.map(e=>jk(e,t)):e._content)}var Mk=ow.define({combine:e=>e.join(` `)}),Nk=ow.define({combine:e=>e.indexOf(!0)>-1}),Pk=ST.newName(),Fk=ST.newName(),Ik=ST.newName(),Lk={"&light":`.`+Fk,"&dark":`.`+Ik};function Rk(e,t,n){return new ST(t,{finish(t){return/&/.test(t)?t.replace(/&\w*/,t=>{if(t==`&`)return e;if(!n||!n[t])throw RangeError(`Unsupported selector: ${t}`);return n[t]}):e+` `+t}})}var zk=Rk(`.`+Pk,{"&":{position:`relative !important`,boxSizing:`border-box`,"&.cm-focused":{outline:`1px dotted #212121`},display:`flex !important`,flexDirection:`column`},".cm-scroller":{display:`flex !important`,alignItems:`flex-start !important`,fontFamily:`monospace`,lineHeight:1.4,height:`100%`,overflowX:`auto`,position:`relative`,zIndex:0,overflowAnchor:`none`},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:`block`,whiteSpace:`pre`,wordWrap:`normal`,boxSizing:`border-box`,minHeight:`100%`,padding:`4px 0`,outline:`none`,"&[contenteditable=true]":{WebkitUserModify:`read-write-plaintext-only`}},".cm-lineWrapping":{whiteSpace_fallback:`pre-wrap`,whiteSpace:`break-spaces`,wordBreak:`break-word`,overflowWrap:`anywhere`,flexShrink:1},"&light .cm-content":{caretColor:`black`},"&dark .cm-content":{caretColor:`white`},".cm-line":{display:`block`,padding:`0 2px 0 6px`},".cm-layer":{userSelect:`none`,position:`absolute`,left:0,top:0,contain:`size style`,"& > *":{position:`absolute`}},"&light .cm-selectionBackground":{background:`#d9d9d9`},"&dark .cm-selectionBackground":{background:`#222`},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:`#d7d4f0`},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:`#233`},".cm-cursorLayer":{pointerEvents:`none`},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:`steps(1) cm-blink 1.2s infinite`},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:`1.2px solid black`,marginLeft:`-0.6px`,pointerEvents:`none`},".cm-cursor":{display:`none`},"&dark .cm-cursor":{borderLeftColor:`#ddd`},".cm-selectionHandle":{backgroundColor:`currentColor`,width:`1.5px`},".cm-selectionHandle-start::before, .cm-selectionHandle-end::before":{content:`""`,backgroundColor:`inherit`,borderRadius:`50%`,width:`8px`,height:`8px`,position:`absolute`,left:`-3.25px`},".cm-selectionHandle-start::before":{top:`-8px`},".cm-selectionHandle-end::before":{bottom:`-8px`},".cm-dropCursor":{position:`absolute`},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:`block`},".cm-iso":{unicodeBidi:`isolate`},".cm-announced":{position:`fixed`,top:`-10000px`},"@media print":{".cm-announced":{display:`none`}},"&light .cm-activeLine":{backgroundColor:`#cceeff44`},"&dark .cm-activeLine":{backgroundColor:`#99eeff33`},"&light .cm-specialChar":{color:`red`},"&dark .cm-specialChar":{color:`#f78`},".cm-gutters":{flexShrink:0,display:`flex`,height:`100%`,boxSizing:`border-box`,zIndex:200},".cm-gutters-before":{insetInlineStart:0},".cm-gutters-after":{insetInlineEnd:0},"&light .cm-gutters":{backgroundColor:`#f5f5f5`,color:`#6c6c6c`,border:`0px solid #ddd`,"&.cm-gutters-before":{borderRightWidth:`1px`},"&.cm-gutters-after":{borderLeftWidth:`1px`}},"&dark .cm-gutters":{backgroundColor:`#333338`,color:`#ccc`},".cm-gutter":{display:`flex !important`,flexDirection:`column`,flexShrink:0,boxSizing:`border-box`,minHeight:`100%`,overflow:`hidden`},".cm-gutterElement":{boxSizing:`border-box`},".cm-lineNumbers .cm-gutterElement":{padding:`0 3px 0 5px`,minWidth:`20px`,textAlign:`right`,whiteSpace:`nowrap`},"&light .cm-activeLineGutter":{backgroundColor:`#e2f2ff`},"&dark .cm-activeLineGutter":{backgroundColor:`#222227`},".cm-panels":{boxSizing:`border-box`,position:`sticky`,left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:`#f5f5f5`,color:`black`},".cm-panels-top":{top:`0`},".cm-panels-bottom":{bottom:`0`},"&light .cm-panels-top":{borderBottom:`1px solid #ddd`},"&light .cm-panels-bottom":{borderTop:`1px solid #ddd`},"&dark .cm-panels":{backgroundColor:`#333338`,color:`white`},".cm-dialog":{padding:`2px 19px 4px 6px`,position:`relative`,"& label":{fontSize:`80%`}},".cm-dialog-close":{position:`absolute`,top:`3px`,right:`4px`,backgroundColor:`inherit`,border:`none`,font:`inherit`,fontSize:`14px`,padding:`0`},".cm-tab":{display:`inline-block`,overflow:`hidden`,verticalAlign:`bottom`},".cm-widgetBuffer":{verticalAlign:`baseline`,height:`1em`,width:0,display:`inline`},".cm-placeholder":{color:`#888`,display:`inline-block`,verticalAlign:`top`,userSelect:`none`},".cm-highlightSpace":{background:`radial-gradient(circle at 50% 55%, #aaa 20%, transparent 0) no-repeat`,backgroundSize:`.4em`,backgroundPosition:`calc(min(50%, 0px)) center`},".cm-highlightTab":{backgroundImage:`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>')`,backgroundSize:`auto 100%`,backgroundPosition:`right 90%`,backgroundRepeat:`no-repeat`},".cm-trailingSpace":{backgroundColor:`#ff332255`},".cm-button":{verticalAlign:`middle`,color:`inherit`,fontSize:`70%`,padding:`.2em 1em`,borderRadius:`1px`},"&light .cm-button":{backgroundImage:`linear-gradient(#eff1f5, #d9d9df)`,border:`1px solid #888`,"&:active":{backgroundImage:`linear-gradient(#b4b4b4, #d0d3d6)`}},"&dark .cm-button":{backgroundImage:`linear-gradient(#393939, #111)`,border:`1px solid #888`,"&:active":{backgroundImage:`linear-gradient(#111, #333)`}},".cm-textfield":{verticalAlign:`middle`,color:`inherit`,fontSize:`70%`,border:`1px solid silver`,padding:`.2em .5em`},"&light .cm-textfield":{backgroundColor:`white`},"&dark .cm-textfield":{border:`1px solid #555`,backgroundColor:`inherit`}},Lk),Bk={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},Vk=q.ie&&q.ie_version<=11,Hk=class{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new xE,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(t=>{for(let e of t)this.queue.push(e);(q.ie&&q.ie_version<=11||q.ios&&e.composing)&&t.some(e=>e.type==`childList`&&e.removedNodes.length||e.type==`characterData`&&e.oldValue.length>e.target.nodeValue.length)?this.flushSoon():this.flush()}),window.EditContext&&q.android&&e.constructor.EDIT_CONTEXT!==!1&&!(q.chrome&&q.chrome_version<126)&&(this.editContext=new Kk(e),e.state.facet(bD)&&(e.contentDOM.editContext=this.editContext.editContext)),Vk&&(this.onCharData=e=>{this.queue.push({target:e.target,type:`characterData`,oldValue:e.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia(`print`)),typeof ResizeObserver==`function`&&(this.resizeScroll=new ResizeObserver(()=>{this.view.docView?.lastUpdate<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),typeof IntersectionObserver==`function`&&(this.intersection=new IntersectionObserver(e=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),e.length>0&&e[e.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent(`Event`)))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(e=>{e.length>0&&e[e.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent(`Event`))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers(`scroll`,e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(this.pendingRecords().length>0),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){(e.type!=`change`&&e.type||e.matches)&&(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((t,n)=>t!=e[n]))){this.gapIntersection.disconnect();for(let t of e)this.gapIntersection.observe(t);this.gaps=e}}onSelectionChange(e){let t=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:n}=this,r=this.selectionRange;if(n.state.facet(bD)?n.root.activeElement!=this.dom:!lE(this.dom,r))return;let i=r.anchorNode&&n.docView.tile.nearest(r.anchorNode);if(i&&i.isWidget()&&i.widget.ignoreEvent(e)){t||(this.selectionChanged=!1);return}(q.ie&&q.ie_version<=11||q.android&&q.chrome)&&!n.state.selection.main.empty&&r.focusNode&&dE(r.focusNode,r.focusOffset,r.anchorNode,r.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,t=sE(e.root);if(!t)return!1;let n=q.safari&&e.root.nodeType==11&&e.root.activeElement==this.dom&&Gk(this.view,t)||t;if(!n||this.selectionRange.eq(n))return!1;let r=lE(this.dom,n);return r&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&AE(this.dom,n)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(n),r&&(this.selectionChanged=!0),!0)}setSelectionRange(e,t){this.selectionRange.set(e.node,e.offset,t.node,t.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,t=null;for(let n=this.dom;n;)if(aE(n))!t&&e<this.scrollTargets.length&&this.scrollTargets[e]==n?e++:t||=this.scrollTargets.slice(0,e),t&&t.push(n),n=n.assignedSlot||n.parentNode;else if(n.nodeType==11)n=n.host;else break;if(e<this.scrollTargets.length&&!t&&(t=this.scrollTargets.slice(0,e)),t){for(let e of this.scrollTargets)e.removeEventListener(`scroll`,this.onScroll);for(let e of this.scrollTargets=t)e.addEventListener(`scroll`,this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){this.active||=(this.observer.observe(this.dom,Bk),Vk&&this.dom.addEventListener(`DOMCharacterDataModified`,this.onCharData),!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),Vk&&this.dom.removeEventListener(`DOMCharacterDataModified`,this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,t){if(!this.delayedAndroidKey){let e=()=>{let e=this.delayedAndroidKey;e&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=e.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&e.force&&OE(this.dom,e.key,e.keyCode))};this.flushingAndroidKey=this.view.win.requestAnimationFrame(e)}(!this.delayedAndroidKey||e==`Enter`)&&(this.delayedAndroidKey={key:e,keyCode:t,force:this.lastChange<Date.now()-50||!!this.delayedAndroidKey?.force})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let t=-1,n=-1,r=!1;for(let i of e){let e=this.readMutation(i);e&&(e.typeOver&&(r=!0),t==-1?{from:t,to:n}=e:(t=Math.min(e.from,t),n=Math.max(e.to,n)))}return{from:t,to:n,typeOver:r}}readChange(){let{from:e,to:t,typeOver:n}=this.processRecords(),r=this.selectionChanged&&lE(this.dom,this.selectionRange);if(e<0&&!r)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let i=new nte(this.view,e,t,n);return this.view.docView.domChanged={newSel:i.newSel?i.newSel.main:null},i}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let t=this.selectionChanged,n=this.readChange();if(!n)return this.view.requestMeasure(),!1;let r=this.view.state,i=VO(this.view,n);return this.view.state==r&&(n.domChanged||t)&&this.view.update([]),i}readMutation(e){let t=this.view.docView.tile.nearest(e.target);if(!t||t.isWidget())return null;if(t.markDirty(e.type==`attributes`),e.type==`childList`){let n=Uk(t,e.previousSibling||e.target.previousSibling,-1),r=Uk(t,e.nextSibling||e.target.nextSibling,1);return{from:n?t.posAfter(n):t.posAtStart,to:r?t.posBefore(r):t.posAtEnd,typeOver:!1}}return e.type==`characterData`?{from:t.posAtStart,to:t.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener(`resize`,this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener(`change`,this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener(`beforeprint`,this.onPrint),e.addEventListener(`scroll`,this.onScroll),e.document.addEventListener(`selectionchange`,this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener(`scroll`,this.onScroll),e.removeEventListener(`resize`,this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener(`change`,this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener(`beforeprint`,this.onPrint),e.document.removeEventListener(`selectionchange`,this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(bD)!=e.state.facet(bD)&&(e.view.contentDOM.editContext=e.state.facet(bD)?this.editContext.editContext:null))}destroy(){var e,t,n;this.stop(),(e=this.intersection)==null||e.disconnect(),(t=this.gapIntersection)==null||t.disconnect(),(n=this.resizeScroll)==null||n.disconnect();for(let e of this.scrollTargets)e.removeEventListener(`scroll`,this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}};function Uk(e,t,n){for(;t;){let r=BD.get(t);if(r&&r.parent==e)return r;let i=t.parentNode;t=i==e.dom?n>0?t.nextSibling:t.previousSibling:i}return null}function Wk(e,t){let n=t.startContainer,r=t.startOffset,i=t.endContainer,a=t.endOffset,o=e.docView.domAtPos(e.state.selection.main.anchor,1);return dE(o.node,o.offset,i,a)&&([n,r,i,a]=[i,a,n,r]),{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:a}}function Gk(e,t){if(t.getComposedRanges){let n=t.getComposedRanges(e.root)[0];if(n)return Wk(e,n)}let n=null;function r(e){e.preventDefault(),e.stopImmediatePropagation(),n=e.getTargetRanges()[0]}return e.contentDOM.addEventListener(`beforeinput`,r,!0),e.dom.ownerDocument.execCommand(`indent`),e.contentDOM.removeEventListener(`beforeinput`,r,!0),n?Wk(e,n):null}var Kk=class{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let t=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=n=>{let r=e.state.selection.main,{anchor:i,head:a}=r,o=this.toEditorPos(n.updateRangeStart),s=this.toEditorPos(n.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:n.updateRangeStart,editorBase:o,drifted:!1});let c=s-o>n.text.length;o==this.from&&i<this.from?o=i:s==this.to&&i>this.to&&(s=i);let l=UO(e.state.sliceDoc(o,s),n.text,(c?r.from:r.to)-o,c?`end`:null);if(!l){let t=K.single(this.toEditorPos(n.selectionStart),this.toEditorPos(n.selectionEnd));WO(t,r)||e.dispatch({selection:t,userEvent:`select`});return}let u={from:l.from+o,to:l.toA+o,insert:LC.of(n.text.slice(l.from,l.toB).split(`
|
|
31
|
+
`))};if((q.mac||q.android)&&u.from==a-1&&/^\. ?$/.test(n.text)&&e.contentDOM.getAttribute(`autocorrect`)==`off`&&(u={from:o,to:s,insert:LC.of([n.text.replace(`.`,` `)])}),this.pendingContextChange=u,!e.state.readOnly){let t=this.to-this.from+(u.to-u.from+u.insert.length);HO(e,u,K.single(this.toEditorPos(n.selectionStart,t),this.toEditorPos(n.selectionEnd,t)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state)),u.from<u.to&&!u.insert.length&&e.inputState.composing>=0&&!/[\\p{Alphabetic}\\p{Number}_]/.test(t.text.slice(Math.max(0,n.updateRangeStart-1),Math.min(t.text.length,n.updateRangeStart+1)))&&this.handlers.compositionend(n)},this.handlers.characterboundsupdate=n=>{let r=[],i=null;for(let t=this.toEditorPos(n.rangeStart),a=this.toEditorPos(n.rangeEnd);t<a;t++){let n=e.coordsForChar(t);i=n&&new DOMRect(n.left,n.top,n.right-n.left,n.bottom-n.top)||i||new DOMRect,r.push(i)}t.updateCharacterBounds(n.rangeStart,r)},this.handlers.textformatupdate=t=>{let n=[];for(let e of t.getTextFormats()){let t=e.underlineStyle,r=e.underlineThickness;if(!/none/i.test(t)&&!/none/i.test(r)){let i=this.toEditorPos(e.rangeStart),a=this.toEditorPos(e.rangeEnd);if(i<a){let e=`text-decoration: underline ${/^[a-z]/.test(t)?t+` `:t==`Dashed`?`dashed `:t==`Squiggle`?`wavy `:``}${/thin/i.test(r)?1:2}px`;n.push(ZT.mark({attributes:{style:e}}).range(i,a))}}}e.dispatch({effects:vD.of(ZT.set(n))})},this.handlers.compositionstart=()=>{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:t}=this.composing;this.composing=null,t&&this.reset(e.state)}};for(let e in this.handlers)t.addEventListener(e,this.handlers[e]);this.measureReq={read:e=>{let t=sE(e.root);t&&t.rangeCount&&this.editContext.updateSelectionBounds(t.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let t=0,n=!1,r=this.pendingContextChange;return e.changes.iterChanges((i,a,o,s,c)=>{if(n)return;let l=c.length-(a-i);if(r&&a>=r.to){if(r.from==i&&r.to==a&&r.insert.eq(c)){r=this.pendingContextChange=null,t+=l,this.to+=l;return}r=null,this.revertPending(e.state)}if(i+=t,a+=t,a<=this.from)this.from+=l,this.to+=l;else if(i<this.to){if(i<this.from||a>this.to||this.to-this.from+c.length>3e4){n=!0;return}this.editContext.updateText(this.toContextPos(i),this.toContextPos(a),c.toString()),this.to+=l}t+=l}),r&&!n&&this.revertPending(e.state),!n}update(e){let t=this.pendingContextChange,n=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(n.from,n.to)&&e.transactions.some(e=>!e.isUserEvent(`input.type`)&&e.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):!this.applyEdits(e)||!this.rangeIsValid(e.state)?(this.pendingContextChange=null,this.reset(e.state)):(e.docChanged||e.selectionSet||t)&&this.setSelection(e.state),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:t}=e.selection.main;this.from=Math.max(0,t-1e4),this.to=Math.min(e.doc.length,t+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let t=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(t.from),this.toContextPos(t.from+t.insert.length),e.doc.sliceString(t.from,t.to))}setSelection(e){let{main:t}=e.selection,n=this.toContextPos(Math.max(this.from,Math.min(this.to,t.anchor))),r=this.toContextPos(t.head);(this.editContext.selectionStart!=n||this.editContext.selectionEnd!=r)&&this.editContext.updateSelection(n,r)}rangeIsValid(e){let{head:t}=e.selection.main;return!(this.from>0&&t-this.from<500||this.to<e.doc.length&&this.to-t<500||this.to-this.from>3e4)}toEditorPos(e,t=this.to-this.from){e=Math.min(e,t);let n=this.composing;return n&&n.drifted?n.editorBase+(e-n.contextBase):e+this.from}toContextPos(e){let t=this.composing;return t&&t.drifted?t.contextBase+(e-t.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}},qk=class e{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return!!this.inputState&&this.inputState.composing>0}get compositionStarted(){return!!this.inputState&&this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.clearAnnouncement=-1,this.contentDOM=document.createElement(`div`),this.scrollDOM=document.createElement(`div`),this.scrollDOM.tabIndex=-1,this.scrollDOM.className=`cm-scroller`,this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement(`div`),this.announceDOM.className=`cm-announced`,this.announceDOM.setAttribute(`aria-live`,`polite`),this.dom=document.createElement(`div`),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:t}=e;this.dispatchTransactions=e.dispatchTransactions||t&&(e=>e.forEach(e=>t(e,this)))||(e=>this.update(e)),this.dispatch=this.dispatch.bind(this),this._root=e.root||kE(e.parent)||document,this.viewState=new Tk(this,e.state||Yw.create(e)),e.scrollTo&&e.scrollTo.is(_D)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(SD).map(e=>new wD(e));for(let e of this.plugins)e.update(this);this.observer=new Hk(this),this.inputState=new ote(this),this.inputState.ensureHandlers(this.plugins),this.docView=new pO(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),document.fonts?.ready&&document.fonts.ready.then(()=>{this.viewState.mustMeasureContent=`refresh`,this.requestMeasure()})}dispatch(...e){let t=e.length==1&&e[0]instanceof Fw?e:e.length==1&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(t,this)}update(t){if(this.updateState!=0)throw Error(`Calls to EditorView.update are not allowed while an update is in progress`);let n=!1,r=!1,i,a=this.state;for(let e of t){if(e.startState!=a)throw RangeError(`Trying to update state with a transaction that doesn't start from the previous state.`);a=e.state}if(this.destroyed){this.viewState.state=a;return}let o=this.hasFocus,s=0,c=null;t.some(e=>e.annotation(ck))?(this.inputState.notifiedFocused=o,s=1):o!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=o,c=lk(a,o),c||(s=1));let l=this.observer.delayedAndroidKey,u=null;if(l?(this.observer.clearDelayedAndroidKey(),u=this.observer.readChange(),(u&&!this.state.doc.eq(a.doc)||!this.state.selection.eq(a.selection))&&(u=null)):this.observer.clear(),a.facet(Yw.phrases)!=this.state.facet(Yw.phrases))return this.setState(a);i=RD.create(this,a,t),i.flags|=s;let d=this.viewState.scrollTarget;try{this.updateState=2;for(let n of t){if(d&&=d.map(n.changes),n.scrollIntoView){let{main:t}=n.state.selection,{x:r,y:i}=this.state.facet(e.cursorScrollMargin);d=new gD(t.empty?t:K.cursor(t.head,t.head>t.anchor?-1:1),`nearest`,`nearest`,i,r)}for(let e of n.effects)e.is(_D)&&(d=e.value.clip(this.state))}this.viewState.update(i,d),this.bidiCache=Xk.update(this.bidiCache,i.changes),i.empty||(this.updatePlugins(i),this.inputState.update(i)),n=this.docView.update(i),this.state.facet(ID)!=this.styleModules&&this.mountStyles(),r=this.updateAttrs(),this.showAnnouncements(t),this.docView.updateSelection(n,t.some(e=>e.isUserEvent(`select.pointer`)))}finally{this.updateState=0}if(i.startState.facet(Mk)!=i.state.facet(Mk)&&(this.viewState.mustMeasureContent=!0),(n||r||d||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),n&&this.docViewUpdate(),!i.empty)for(let e of this.state.facet(cD))try{e(i)}catch(e){yD(this.state,e,`update listener`)}(c||u)&&Promise.resolve().then(()=>{c&&this.state==c.startState&&this.dispatch(c),u&&!VO(this,u)&&l.force&&OE(this.contentDOM,l.key,l.keyCode)})}setState(e){if(this.updateState!=0)throw Error(`Calls to EditorView.setState are not allowed while an update is in progress`);if(this.destroyed){this.viewState.state=e;return}this.updateState=2;let t=this.hasFocus;try{for(let e of this.plugins)e.destroy(this);this.viewState=new Tk(this,e),this.plugins=e.facet(SD).map(e=>new wD(e)),this.pluginMap.clear();for(let e of this.plugins)e.update(this);this.docView.destroy(),this.docView=new pO(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}t&&this.focus(),this.requestMeasure()}updatePlugins(e){let t=e.startState.facet(SD),n=e.state.facet(SD);if(t!=n){let r=[];for(let i of n){let n=t.indexOf(i);if(n<0)r.push(new wD(i));else{let t=this.plugins[n];t.mustUpdate=e,r.push(t)}}for(let t of this.plugins)t.mustUpdate!=e&&t.destroy(this);this.plugins=r,this.pluginMap.clear()}else for(let t of this.plugins)t.mustUpdate=e;for(let e=0;e<this.plugins.length;e++)this.plugins[e].update(this);t!=n&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let e of this.plugins){let t=e.value;if(t&&t.docViewUpdate)try{t.docViewUpdate(this)}catch(e){yD(this.state,e,`doc view update listener`)}}}measure(e=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,e&&this.observer.forceFlush();let t=null,n=this.viewState.scrollParent,r=this.viewState.getScrollOffset(),{scrollAnchorPos:i,scrollAnchorHeight:a,scaleY:o}=this.viewState;Math.abs(r-this.viewState.scrollOffset)>1&&(a=-1),this.viewState.scrollAnchorHeight=-1;try{for(let e=0;;e++){if(a<0){if(jE(n||this.win))i=-1,a=this.viewState.heightMap.height/this.viewState.scaleY;else{let e=this.viewState.scrollAnchorAt(r);i=e.from,a=e.top}o=this.viewState.scaleY}this.updateState=1;let s=this.viewState.measure();if(!s&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(e>5){console.warn(this.measureRequests.length?`Measure loop restarted more than 5 times`:`Viewport failed to stabilize`);break}let c=[];s&4||([this.measureRequests,c]=[c,this.measureRequests]);let l=c.map(e=>{try{return e.read(this)}catch(e){return yD(this.state,e),Yk}}),u=RD.create(this,this.state,[]),d=!1;u.flags|=s,t?t.flags|=s:t=u,this.updateState=2,u.empty||(this.updatePlugins(u),this.inputState.update(u),this.updateAttrs(),d=this.docView.update(u),d&&this.docViewUpdate());for(let e=0;e<c.length;e++)if(l[e]!=Yk)try{let t=c[e];t.write&&t.write(l[e],this)}catch(e){yD(this.state,e)}if(d&&this.docView.updateSelection(!0),!u.viewportChanged&&this.measureRequests.length==0){if(this.viewState.editorHeight){if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,a=-1;continue}{let e=(i<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(i).top)/this.viewState.scaleY-a/o;if((e>1||e<-1)&&!(q.ios&&this.inputState.lastIOSMomentumScroll>Date.now()-100)&&(n==this.scrollDOM||this.hasFocus||Math.max(this.inputState.lastWheelEvent,this.inputState.lastTouchTime)>Date.now()-100)){r+=e,n?i<0?n.scrollTop=n.scrollHeight:n.scrollTop+=e:this.win.scrollBy(0,e),a=-1;continue}}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(t&&!t.empty)for(let e of this.state.facet(cD))e(t)}get themeClasses(){return Pk+` `+(this.state.facet(Nk)?Ik:Fk)+` `+this.state.facet(Mk)}updateAttrs(){let e=Zk(this,TD,{class:`cm-editor`+(this.hasFocus?` cm-focused `:` `)+this.themeClasses}),t={spellcheck:`false`,autocorrect:`off`,autocapitalize:`off`,writingsuggestions:`false`,translate:`no`,contenteditable:this.state.facet(bD)?`true`:`false`,class:`cm-content`,style:`${q.tabSize}: ${this.state.tabSize}`,role:`textbox`,"aria-multiline":`true`};this.state.readOnly&&(t[`aria-readonly`]=`true`),Zk(this,ED,t);let n=this.observer.ignore(()=>{let n=qT(this.contentDOM,this.contentAttrs,t),r=qT(this.dom,this.editorAttrs,e);return n||r});return this.editorAttrs=e,this.contentAttrs=t,n}showAnnouncements(t){let n=!0;for(let r of t)for(let t of r.effects)if(t.is(e.announce)){n&&=(this.announceDOM.textContent=``,this.win.clearTimeout(this.clearAnnouncement),this.clearAnnouncement=this.win.setTimeout(()=>{this.announceDOM.textContent=`\xA0`},200),!1);let e=this.announceDOM.appendChild(document.createElement(`div`));e.textContent=t.value}}mountStyles(){this.styleModules=this.state.facet(ID);let t=this.state.facet(e.cspNonce);ST.mount(this.root,this.styleModules.concat(zk).reverse(),t?{nonce:t}:void 0)}readMeasured(){if(this.updateState==2)throw Error(`Reading the editor layout isn't allowed during an update`);this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(this.measureRequests.indexOf(e)>-1)return;if(e.key!=null){for(let t=0;t<this.measureRequests.length;t++)if(this.measureRequests[t].key===e.key){this.measureRequests[t]=e;return}}this.measureRequests.push(e)}}plugin(e){let t=this.pluginMap.get(e);return(t===void 0||t&&t.plugin!=e)&&this.pluginMap.set(e,t=this.plugins.find(t=>t.plugin==e)||null),t&&t.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,t,n){return FO(this,e,AO(this,e,t,n))}moveByGroup(e,t){return FO(this,e,AO(this,e,t,t=>jO(this,e.head,t)))}visualLineSide(e,t){return t?K.cursor(e.to,1):K.cursor(e.from,-1)}moveToLineBoundary(e,t,n=!0){return kO(this,e,t,n)}moveVertically(e,t,n){return FO(this,e,MO(this,e,t,n))}domAtPos(e,t=1){return this.docView.domAtPos(e,t)}posAtDOM(e,t=0){return this.docView.posFromDOM(e,t)}posAtCoords(e,t=!0){this.readMeasured();let n=LO(this,e,t);return n&&n.pos}posAndSideAtCoords(e,t=!0){return this.readMeasured(),LO(this,e,t)}coordsAtPos(e,t=1){this.readMeasured();let n=this.state.doc.lineAt(e),r=this.bidiSpans(n),i=r[GE.find(r,e-n.from,-1,t)];return n.length&&(e==n.from&&t<0||e==n.to&&t>0)&&i.dir!=this.textDirectionAt(n.from)&&(e==n.to?(e=n.from+i.from,t=1):(e=n.from+i.to,t=-1)),this.docView.coordsAt(e,t,i.dir==FE.RTL)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){return!this.state.facet(pD)||e<this.viewport.from||e>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>Jk)return eD(e.length);let t=this.textDirectionAt(e.from),n;for(let r of this.bidiCache)if(r.from==e.from&&r.dir==t&&(r.fresh||KE(r.isolates,n=MD(this,e))))return r.order;n||=MD(this,e);let r=$E(e.text,t,n);return this.bidiCache.push(new Xk(e.from,e.to,t,n,!0,r)),r}get hasFocus(){return(this.dom.ownerDocument.hasFocus()||q.safari&&this.inputState?.lastContextMenu>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{TE(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((e.nodeType==9?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.win.clearTimeout(this.clearAnnouncement),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,t={}){return _D.of(new gD(typeof e==`number`?K.cursor(e):e,t.y??`nearest`,t.x??`nearest`,t.yMargin??5,t.xMargin??5))}scrollSnapshot(){let{scrollTop:e,scrollLeft:t}=this.scrollDOM,n=this.viewState.scrollAnchorAt(e);return _D.of(new gD(K.cursor(n.from),`start`,`start`,n.top-e,t,!0))}setTabFocusMode(e){e==null?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:typeof e==`boolean`?this.inputState.tabFocusMode=e?0:-1:this.inputState.tabFocusMode!=0&&(this.inputState.tabFocusMode=Date.now()+e)}static domEventHandlers(e){return CD.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return CD.define(()=>({}),{eventObservers:e})}static theme(e,t){let n=ST.newName(),r=[Mk.of(n),ID.of(Rk(`.${n}`,e))];return t&&t.dark&&r.push(Nk.of(!0)),r}static baseTheme(e){return gw.lowest(ID.of(Rk(`.`+Pk,e,Lk)))}static findFromDOM(e){let t=e.querySelector(`.cm-content`);return(t&&BD.get(t)||BD.get(e))?.root?.view||null}};qk.styleModule=ID,qk.inputHandler=lD,qk.clipboardInputFilter=dD,qk.clipboardOutputFilter=fD,qk.scrollHandler=hD,qk.focusChangeEffect=uD,qk.perLineTextDirection=pD,qk.exceptionSink=sD,qk.updateListener=cD,qk.editable=bD,qk.mouseSelectionStyle=oD,qk.dragMovesSelection=aD,qk.clickAddsSelectionRange=iD,qk.decorations=DD,qk.blockWrappers=OD,qk.outerDecorations=kD,qk.atomicRanges=AD,qk.bidiIsolatedRanges=jD,qk.cursorScrollMargin=ow.define({combine:e=>{let t=5,n=5;for(let r of e)typeof r==`number`?t=n=r:{x:t,y:n}=r;return{x:t,y:n}}}),qk.scrollMargins=PD,qk.darkTheme=Nk,qk.cspNonce=ow.define({combine:e=>e.length?e[0]:``}),qk.contentAttributes=ED,qk.editorAttributes=TD,qk.lineWrapping=qk.contentAttributes.of({class:`cm-lineWrapping`}),qk.announce=Pw.define();var Jk=4096,Yk={},Xk=class e{constructor(e,t,n,r,i,a){this.from=e,this.to=t,this.dir=n,this.isolates=r,this.fresh=i,this.order=a}static update(t,n){if(n.empty&&!t.some(e=>e.fresh))return t;let r=[],i=t.length?t[t.length-1].dir:FE.LTR;for(let a=Math.max(0,t.length-10);a<t.length;a++){let o=t[a];o.dir==i&&!n.touchesRange(o.from,o.to)&&r.push(new e(n.mapPos(o.from,1),n.mapPos(o.to,-1),o.dir,o.isolates,!1,o.order))}return r}};function Zk(e,t,n){for(let r=e.state.facet(t),i=r.length-1;i>=0;i--){let t=r[i],a=typeof t==`function`?t(e):t;a&&UT(a,n)}return n}var Qk=q.mac?`mac`:q.windows?`win`:q.linux?`linux`:`key`;function $k(e,t){let n=e.split(/-(?!$)/),r=n[n.length-1];r==`Space`&&(r=` `);let i,a,o,s;for(let e=0;e<n.length-1;++e){let r=n[e];if(/^(cmd|meta|m)$/i.test(r))s=!0;else if(/^a(lt)?$/i.test(r))i=!0;else if(/^(c|ctrl|control)$/i.test(r))a=!0;else if(/^s(hift)?$/i.test(r))o=!0;else if(/^mod$/i.test(r))t==`mac`?s=!0:a=!0;else throw Error(`Unrecognized modifier name: `+r)}return i&&(r=`Alt-`+r),a&&(r=`Ctrl-`+r),s&&(r=`Meta-`+r),o&&(r=`Shift-`+r),r}function eA(e,t,n){return t.altKey&&(e=`Alt-`+e),t.ctrlKey&&(e=`Ctrl-`+e),t.metaKey&&(e=`Meta-`+e),n!==!1&&t.shiftKey&&(e=`Shift-`+e),e}var tA=gw.default(qk.domEventHandlers({keydown(e,t){return lA(iA(t.state),e,t,`editor`)}})),nA=ow.define({enables:tA}),rA=new WeakMap;function iA(e){let t=e.facet(nA),n=rA.get(t);return n||rA.set(t,n=sA(t.reduce((e,t)=>e.concat(t),[]))),n}var aA=null,oA=4e3;function sA(e,t=Qk){let n=Object.create(null),r=Object.create(null),i=(e,t)=>{let n=r[e];if(n==null)r[e]=t;else if(n!=t)throw Error(`Key binding `+e+` is used both as a regular binding and as a multi-stroke prefix`)},a=(e,r,a,o,s)=>{let c=n[e]||(n[e]=Object.create(null)),l=r.split(/ (?!$)/).map(e=>$k(e,t));for(let t=1;t<l.length;t++){let n=l.slice(0,t).join(` `);i(n,!0),c[n]||(c[n]={preventDefault:!0,stopPropagation:!1,run:[t=>{let r=aA={view:t,prefix:n,scope:e};return setTimeout(()=>{aA==r&&(aA=null)},oA),!0}]})}let u=l.join(` `);i(u,!1);let d=c[u]||(c[u]={preventDefault:!1,stopPropagation:!1,run:(c._any?.run)?.slice()||[]});a&&d.run.push(a),o&&(d.preventDefault=!0),s&&(d.stopPropagation=!0)};for(let r of e){let e=r.scope?r.scope.split(` `):[`editor`];if(r.any)for(let t of e){let e=n[t]||(n[t]=Object.create(null));e._any||={preventDefault:!1,stopPropagation:!1,run:[]};let{any:i}=r;for(let t in e)e[t].run.push(e=>i(e,cA))}let i=r[t]||r.key;if(i)for(let t of e)a(t,i,r.run,r.preventDefault,r.stopPropagation),r.shift&&a(t,`Shift-`+i,r.shift,r.preventDefault,r.stopPropagation)}return n}var cA=null;function lA(e,t,n,r){cA=t;let i=jT(t),a=Zee(Xee(i,0))==i.length&&i!=` `,o=``,s=!1,c=!1,l=!1;aA&&aA.view==n&&aA.scope==r&&(o=aA.prefix+` `,qO.indexOf(t.keyCode)<0&&(c=!0,aA=null));let u=new Set,d=e=>{if(e){for(let t of e.run)if(!u.has(t)&&(u.add(t),t(n)))return e.stopPropagation&&(l=!0),!0;e.preventDefault&&(e.stopPropagation&&(l=!0),c=!0)}return!1},f=e[r],p,m;return f&&(d(f[o+eA(i,t,!a)])?s=!0:a&&(t.altKey||t.metaKey||t.ctrlKey)&&!(q.windows&&t.ctrlKey&&t.altKey)&&!(q.mac&&t.altKey&&!(t.ctrlKey||t.metaKey))&&(p=TT[t.keyCode])&&p!=i?(d(f[o+eA(p,t,!0)])||t.shiftKey&&(m=ET[t.keyCode])!=i&&m!=p&&d(f[o+eA(m,t,!1)]))&&(s=!0):a&&t.shiftKey&&d(f[o+eA(i,t,!0)])&&(s=!0),!s&&d(f._any)&&(s=!0)),c&&(s=!0),s&&l&&t.stopPropagation(),cA=null,s}var uA=class e{constructor(e,t,n,r,i){this.className=e,this.left=t,this.top=n,this.width=r,this.height=i}draw(){let e=document.createElement(`div`);return e.className=this.className,this.adjust(e),e}update(e,t){return t.className==this.className&&(this.adjust(e),!0)}adjust(e){e.style.left=this.left+`px`,e.style.top=this.top+`px`,this.width!=null&&(e.style.width=this.width+`px`),e.style.height=this.height+`px`}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(t,n,r){if(r.empty){let i=t.coordsAtPos(r.head,r.assoc||1);if(!i)return[];let a=dA(t);return[new e(n,i.left-a.left,i.top-a.top,null,i.bottom-i.top)]}return pA(t,n,r)}};function dA(e){let t=e.scrollDOM.getBoundingClientRect();return{left:(e.textDirection==FE.LTR?t.left:t.right-e.scrollDOM.clientWidth*e.scaleX)-e.scrollDOM.scrollLeft*e.scaleX,top:t.top-e.scrollDOM.scrollTop*e.scaleY}}function fA(e,t,n,r){let i=e.coordsAtPos(t,n*2);if(!i)return r;let a=e.dom.getBoundingClientRect(),o=(i.top+i.bottom)/2,s=e.posAtCoords({x:a.left+1,y:o}),c=e.posAtCoords({x:a.right-1,y:o});return s==null||c==null?r:{from:Math.max(r.from,Math.min(s,c)),to:Math.min(r.to,Math.max(s,c))}}function pA(e,t,n){if(n.to<=e.viewport.from||n.from>=e.viewport.to)return[];let r=Math.max(n.from,e.viewport.from),i=Math.min(n.to,e.viewport.to),a=e.textDirection==FE.LTR,o=e.contentDOM,s=o.getBoundingClientRect(),c=dA(e),l=o.querySelector(`.cm-line`),u=l&&window.getComputedStyle(l),d=s.left+(u?parseInt(u.paddingLeft)+Math.min(0,parseInt(u.textIndent)):0),f=s.right-(u?parseInt(u.paddingRight):0),p=OO(e,r,1),m=OO(e,i,-1),h=p.type==XT.Text?p:null,g=m.type==XT.Text?m:null;if(h&&(e.lineWrapping||p.widgetLineBreaks)&&(h=fA(e,r,1,h)),g&&(e.lineWrapping||m.widgetLineBreaks)&&(g=fA(e,i,-1,g)),h&&g&&h.from==g.from&&h.to==g.to)return v(y(n.from,n.to,h));{let t=h?y(n.from,null,h):b(p,!1),r=g?y(null,n.to,g):b(m,!0),i=[];return(h||p).to<(g||m).from-(h&&g?1:0)||p.widgetLineBreaks>1&&t.bottom+e.defaultLineHeight/2<r.top?i.push(_(d,t.bottom,f,r.top)):t.bottom<r.top&&e.elementAtHeight((t.bottom+r.top)/2).type==XT.Text&&(t.bottom=r.top=(t.bottom+r.top)/2),v(t).concat(i).concat(v(r))}function _(e,n,r,i){return new uA(t,e-c.left,n-c.top,Math.max(0,r-e),i-n)}function v({top:e,bottom:t,horizontal:n}){let r=[];for(let i=0;i<n.length;i+=2)r.push(_(n[i],e,n[i+1],t));return r}function y(t,n,r){let i=1e9,o=-1e9,s=[];function c(t,n,c,l,u){let p=e.coordsAtPos(t,t==r.to?-2:2),m=e.coordsAtPos(c,c==r.from?2:-2);p&&m&&(i=Math.min(p.top,m.top,i),o=Math.max(p.bottom,m.bottom,o),u==FE.LTR?s.push(a&&n?d:p.left,a&&l?f:m.right):s.push(!a&&l?d:m.left,!a&&n?f:p.right))}let l=t??r.from,u=n??r.to;for(let r of e.visibleRanges)if(r.to>l&&r.from<u)for(let i=Math.max(r.from,l),a=Math.min(r.to,u);;){let r=e.state.doc.lineAt(i);for(let o of e.bidiSpans(r)){let e=o.from+r.from,s=o.to+r.from;if(e>=a)break;s>i&&c(Math.max(e,i),t==null&&e<=l,Math.min(s,a),n==null&&s>=u,o.dir)}if(i=r.to+1,i>=a)break}return s.length==0&&c(l,t==null,u,n==null,e.textDirection),{top:i,bottom:o,horizontal:s}}function b(e,t){let n=s.top+(t?e.top:e.bottom);return{top:n,bottom:n,horizontal:[]}}}function mA(e,t){return e.constructor==t.constructor&&e.eq(t)}var hA=class{constructor(e,t){this.view=e,this.layer=t,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement(`div`)),this.dom.classList.add(`cm-layer`),t.above&&this.dom.classList.add(`cm-layer-above`),t.class&&this.dom.classList.add(t.class),this.scale(),this.dom.setAttribute(`aria-hidden`,`true`),this.setOrder(e.state),e.requestMeasure(this.measureReq),t.mount&&t.mount(this.dom,e)}update(e){e.startState.facet(gA)!=e.state.facet(gA)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){this.layer.updateOnDocViewUpdate!==!1&&e.requestMeasure(this.measureReq)}setOrder(e){let t=0,n=e.facet(gA);for(;t<n.length&&n[t]!=this.layer;)t++;this.dom.style.zIndex=String((this.layer.above?150:-1)-t)}measure(){return this.layer.markers(this.view)}scale(){let{scaleX:e,scaleY:t}=this.view;(e!=this.scaleX||t!=this.scaleY)&&(this.scaleX=e,this.scaleY=t,this.dom.style.transform=`scale(${1/e}, ${1/t})`)}draw(e){if(e.length!=this.drawn.length||e.some((e,t)=>!mA(e,this.drawn[t]))){let t=this.dom.firstChild,n=0;for(let r of e)r.update&&t&&r.constructor&&this.drawn[n].constructor&&r.update(t,this.drawn[n])?(t=t.nextSibling,n++):this.dom.insertBefore(r.draw(),t);for(;t;){let e=t.nextSibling;t.remove(),t=e}this.drawn=e,q.webkit&&(this.dom.style.display=this.dom.firstChild?``:`none`)}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}},gA=ow.define();function _A(e){return[CD.define(t=>new hA(t,e)),gA.of(e)]}var vA=!q.ios,yA=ow.define({combine(e){return Xw(e,{cursorBlinkRate:1200,drawRangeCursor:!0,iosSelectionHandles:!0},{cursorBlinkRate:(e,t)=>Math.min(e,t),drawRangeCursor:(e,t)=>e||t})}});function bA(e={}){return[yA.of(e),SA,wA,EA,mD.of(!0)]}function xA(e){return e.startState.facet(yA)!=e.state.facet(yA)}var SA=_A({above:!0,markers(e){let{state:t}=e,n=t.facet(yA),r=[];for(let i of t.selection.ranges){let a=i==t.selection.main;if(i.empty||n.drawRangeCursor&&!(a&&q.ios&&n.iosSelectionHandles)){let t=a?`cm-cursor cm-cursor-primary`:`cm-cursor cm-cursor-secondary`,n=i.empty?i:K.cursor(i.head,i.assoc);for(let i of uA.forRange(e,t,n))r.push(i)}}return r},update(e,t){e.transactions.some(e=>e.selection)&&(t.style.animationName=t.style.animationName==`cm-blink`?`cm-blink2`:`cm-blink`);let n=xA(e);return n&&CA(e.state,t),e.docChanged||e.selectionSet||n},mount(e,t){CA(t.state,e)},class:`cm-cursorLayer`});function CA(e,t){t.style.animationDuration=e.facet(yA).cursorBlinkRate+`ms`}var wA=_A({above:!1,markers(e){let t=[],{main:n,ranges:r}=e.state.selection;for(let i of r)if(!i.empty&&(vA||i!=n))for(let n of uA.forRange(e,`cm-selectionBackground`,i))t.push(n);if(q.ios&&!n.empty&&e.state.facet(yA).iosSelectionHandles){for(let r of uA.forRange(e,`cm-selectionHandle cm-selectionHandle-start`,K.cursor(n.from,1)))t.push(r);for(let r of uA.forRange(e,`cm-selectionHandle cm-selectionHandle-end`,K.cursor(n.to,1)))t.push(r)}return t},update(e,t){return e.docChanged||e.selectionSet||e.viewportChanged||xA(e)},class:`cm-selectionLayer`}),TA=q.gecko&&q.gecko_version==153?`#ffffff01`:`transparent`,EA=gw.highest(qk.theme({".cm-line":{...vA?{"& ::selection, &::selection":{backgroundColor:`${TA} !important`}}:{},caretColor:`transparent !important`},".cm-content":{caretColor:`transparent !important`,"& :focus":{caretColor:`initial !important`,...vA?{"&::selection, & ::selection":{backgroundColor:`Highlight !important`}}:{}}}}));/x/.unicode;function DA(){return kA}var OA=ZT.line({class:`cm-activeLine`}),kA=CD.fromClass(class{constructor(e){this.decorations=this.getDeco(e)}update(e){(e.docChanged||e.selectionSet)&&(this.decorations=this.getDeco(e.view))}getDeco(e){let t=-1,n=[];for(let r of e.state.selection.ranges){let i=e.lineBlockAt(r.head);i.from>t&&(n.push(OA.range(i.from)),t=i.from)}return ZT.set(n)}},{decorations:e=>e.decorations}),AA=class extends YT{constructor(e){super(),this.content=e}toDOM(e){let t=document.createElement(`span`);return t.className=`cm-placeholder`,t.style.pointerEvents=`none`,t.appendChild(typeof this.content==`string`?document.createTextNode(this.content):typeof this.content==`function`?this.content(e):this.content.cloneNode(!0)),t.setAttribute(`aria-hidden`,`true`),t}coordsAt(e){let t=e.firstChild?uE(e.firstChild):[];if(!t.length)return null;let n=window.getComputedStyle(e.parentNode),r=gE(t[0],n.direction!=`rtl`),i=parseInt(n.lineHeight);return r.bottom-r.top>i*1.5?{left:r.left,right:r.right,top:r.top,bottom:r.top+i}:r}ignoreEvent(){return!1}};function jA(e){let t=CD.fromClass(class{constructor(t){this.view=t,this.placeholder=e?ZT.set([ZT.widget({widget:new AA(e),side:1}).range(0)]):ZT.none}get decorations(){return this.view.state.doc.length?ZT.none:this.placeholder}},{decorations:e=>e.decorations});return typeof e==`string`?[t,qk.contentAttributes.of({"aria-placeholder":e})]:t}var MA=class extends Zw{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}};MA.prototype.elementClass=``,MA.prototype.toDOM=void 0,MA.prototype.mapMode=JC.TrackBefore,MA.prototype.startSide=MA.prototype.endSide=-1,MA.prototype.point=!0;var NA=ow.define(),PA=ow.define(),FA={class:``,renderEmptyElements:!1,elementStyle:``,markers:()=>nT.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{},side:`before`},IA=ow.define();function LA(e){return[zA(),IA.of({...FA,...e})]}var RA=ow.define({combine:e=>e.some(e=>e)});function zA(e){let t=[BA];return e&&e.fixed===!1&&t.push(RA.of(!0)),t}var BA=CD.fromClass(class{constructor(e){this.view=e,this.domAfter=null,this.prevViewport=e.viewport,this.dom=document.createElement(`div`),this.dom.className=`cm-gutters cm-gutters-before`,this.dom.setAttribute(`aria-hidden`,`true`),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+`px`,this.gutters=e.state.facet(IA).map(t=>new WA(e,t)),this.fixed=!e.state.facet(RA);for(let e of this.gutters)e.config.side==`after`?this.getDOMAfter().appendChild(e.dom):this.dom.appendChild(e.dom);this.fixed&&(this.dom.style.position=`sticky`),this.syncGutters(!1),e.scrollDOM.insertBefore(this.dom,e.contentDOM)}getDOMAfter(){return this.domAfter||(this.domAfter=document.createElement(`div`),this.domAfter.className=`cm-gutters cm-gutters-after`,this.domAfter.setAttribute(`aria-hidden`,`true`),this.domAfter.style.minHeight=this.view.contentHeight/this.view.scaleY+`px`,this.domAfter.style.position=this.fixed?`sticky`:``,this.view.scrollDOM.appendChild(this.domAfter)),this.domAfter}update(e){if(this.updateGutters(e)){let t=this.prevViewport,n=e.view.viewport,r=Math.min(t.to,n.to)-Math.max(t.from,n.from);this.syncGutters(r<(n.to-n.from)*.8)}if(e.geometryChanged){let e=this.view.contentHeight/this.view.scaleY+`px`;this.dom.style.minHeight=e,this.domAfter&&(this.domAfter.style.minHeight=e)}this.view.state.facet(RA)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?`sticky`:``,this.domAfter&&(this.domAfter.style.position=this.fixed?`sticky`:``)),this.prevViewport=e.view.viewport}syncGutters(e){let t=this.dom.nextSibling;e&&(this.dom.remove(),this.domAfter&&this.domAfter.remove());let n=nT.iter(this.view.state.facet(NA),this.view.viewport.from),r=[],i=this.gutters.map(e=>new UA(e,this.view.viewport,-this.view.documentPadding.top));for(let e of this.view.viewportLineBlocks)if(r.length&&(r=[]),Array.isArray(e.type)){let t=!0;for(let a of e.type)if(a.type==XT.Text&&t){HA(n,r,a.from);for(let e of i)e.line(this.view,a,r);t=!1}else if(a.widget)for(let e of i)e.widget(this.view,a)}else if(e.type==XT.Text){HA(n,r,e.from);for(let t of i)t.line(this.view,e,r)}else if(e.widget)for(let t of i)t.widget(this.view,e);for(let e of i)e.finish();e&&(this.view.scrollDOM.insertBefore(this.dom,t),this.domAfter&&this.view.scrollDOM.appendChild(this.domAfter))}updateGutters(e){let t=e.startState.facet(IA),n=e.state.facet(IA),r=e.docChanged||e.heightChanged||e.viewportChanged||!nT.eq(e.startState.facet(NA),e.state.facet(NA),e.view.viewport.from,e.view.viewport.to);if(t==n)for(let t of this.gutters)t.update(e)&&(r=!0);else{r=!0;let i=[];for(let r of n){let n=t.indexOf(r);n<0?i.push(new WA(this.view,r)):(this.gutters[n].update(e),i.push(this.gutters[n]))}for(let e of this.gutters)e.dom.remove(),i.indexOf(e)<0&&e.destroy();for(let e of i)e.config.side==`after`?this.getDOMAfter().appendChild(e.dom):this.dom.appendChild(e.dom);this.gutters=i}return r}destroy(){for(let e of this.gutters)e.destroy();this.dom.remove(),this.domAfter&&this.domAfter.remove()}},{provide:e=>qk.scrollMargins.of(t=>{let n=t.plugin(e);if(!n||n.gutters.length==0||!n.fixed)return null;let r=n.dom.offsetWidth*t.scaleX,i=n.domAfter?n.domAfter.offsetWidth*t.scaleX:0;return t.textDirection==FE.LTR?{left:r,right:i}:{right:r,left:i}})});function VA(e){return Array.isArray(e)?e:[e]}function HA(e,t,n){for(;e.value&&e.from<=n;)e.from==n&&t.push(e.value),e.next()}var UA=class{constructor(e,t,n){this.gutter=e,this.height=n,this.i=0,this.cursor=nT.iter(e.markers,t.from)}addElement(e,t,n){let{gutter:r}=this,i=(t.top-this.height)/e.scaleY,a=t.height/e.scaleY;if(this.i==r.elements.length){let t=new GA(e,a,i,n);r.elements.push(t),r.dom.appendChild(t.dom)}else r.elements[this.i].update(e,a,i,n);this.height=t.bottom,this.i++}line(e,t,n){let r=[];HA(this.cursor,r,t.from),n.length&&(r=r.concat(n));let i=this.gutter.config.lineMarker(e,t,r);i&&r.unshift(i);let a=this.gutter;(r.length!=0||a.config.renderEmptyElements)&&this.addElement(e,t,r)}widget(e,t){let n=this.gutter.config.widgetMarker(e,t.widget,t),r=n?[n]:null;for(let n of e.state.facet(PA)){let i=n(e,t.widget,t);i&&(r||=[]).push(i)}r&&this.addElement(e,t,r)}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let t=e.elements.pop();e.dom.removeChild(t.dom),t.destroy()}}},WA=class{constructor(e,t){this.view=e,this.config=t,this.elements=[],this.spacer=null,this.dom=document.createElement(`div`),this.dom.className=`cm-gutter`+(this.config.class?` `+this.config.class:``);for(let n in t.domEventHandlers)this.dom.addEventListener(n,r=>{let i=r.target,a;if(i!=this.dom&&this.dom.contains(i)){for(;i.parentNode!=this.dom;)i=i.parentNode;let e=i.getBoundingClientRect();a=(e.top+e.bottom)/2}else a=r.clientY;let o=e.lineBlockAtHeight(a-e.documentTop);t.domEventHandlers[n](e,o,r)&&r.preventDefault()});this.markers=VA(t.markers(e)),t.initialSpacer&&(this.spacer=new GA(e,0,0,[t.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+=`visibility: hidden; pointer-events: none`)}update(e){let t=this.markers;if(this.markers=VA(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let t=this.config.updateSpacer(this.spacer.markers[0],e);t!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[t])}let n=e.view.viewport;return!nT.eq(this.markers,t,n.from,n.to)||(this.config.lineMarkerChange?this.config.lineMarkerChange(e):!1)}destroy(){for(let e of this.elements)e.destroy()}},GA=class{constructor(e,t,n,r){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement(`div`),this.dom.className=`cm-gutterElement`,this.update(e,t,n,r)}update(e,t,n,r){this.height!=t&&(this.height=t,this.dom.style.height=t+`px`),this.above!=n&&(this.dom.style.marginTop=(this.above=n)?n+`px`:``),KA(this.markers,r)||this.setMarkers(e,r)}setMarkers(e,t){let n=`cm-gutterElement`,r=this.dom.firstChild;for(let i=0,a=0;;){let o=a,s=i<t.length?t[i++]:null,c=!1;if(s){let e=s.elementClass;e&&(n+=` `+e);for(let e=a;e<this.markers.length;e++)if(this.markers[e].compare(s)){o=e,c=!0;break}}else o=this.markers.length;for(;a<o;){let e=this.markers[a++];if(e.toDOM){e.destroy(r);let t=r.nextSibling;r.remove(),r=t}}if(!s)break;s.toDOM&&(c?r=r.nextSibling:this.dom.insertBefore(s.toDOM(e),r)),c&&a++}this.dom.className=n,this.markers=t}destroy(){this.setMarkers(null,[])}};function KA(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].compare(t[n]))return!1;return!0}var qA=ow.define(),JA=ow.define(),YA=ow.define({combine(e){return Xw(e,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,t){let n=Object.assign({},e);for(let e in t){let r=n[e],i=t[e];n[e]=r?(e,t,n)=>r(e,t,n)||i(e,t,n):i}return n}})}}),XA=class extends MA{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}};function ZA(e,t){return e.state.facet(YA).formatNumber(t,e.state)}var QA=IA.compute([YA],e=>({class:`cm-lineNumbers`,renderEmptyElements:!1,markers(e){return e.state.facet(qA)},lineMarker(e,t,n){return n.some(e=>e.toDOM)?null:new XA(ZA(e,e.state.doc.lineAt(t.from).number))},widgetMarker:(e,t,n)=>{for(let r of e.state.facet(JA)){let i=r(e,t,n);if(i)return i}return null},lineMarkerChange:e=>e.startState.facet(YA)!=e.state.facet(YA),initialSpacer(e){return new XA(ZA(e,ej(e.state.doc.lines)))},updateSpacer(e,t){let n=ZA(t.view,ej(t.view.state.doc.lines));return n==e.number?e:new XA(n)},domEventHandlers:e.facet(YA).domEventHandlers,side:`before`}));function $A(e={}){return[YA.of(e),zA(),QA]}function ej(e){let t=9;for(;t<e;)t=t*10+9;return t}var tj=new class extends MA{constructor(){super(...arguments),this.elementClass=`cm-activeLineGutter`}},nj=NA.compute([`selection`],e=>{let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.head).from;i>n&&(n=i,t.push(tj.range(i)))}return nT.of(t)});function rj(){return nj}var ij=1024,aj=0,oj=class{constructor(e,t){this.from=e,this.to=t}},sj=class{constructor(e={}){this.id=aj++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw Error(`This node type doesn't define a deserialize function`)}),this.combine=e.combine||null}add(e){if(this.perNode)throw RangeError(`Can't add per-node props to node types`);return typeof e!=`function`&&(e=uj.match(e)),t=>{let n=e(t);return n===void 0?null:[this,n]}}};sj.closedBy=new sj({deserialize:e=>e.split(` `)}),sj.openedBy=new sj({deserialize:e=>e.split(` `)}),sj.group=new sj({deserialize:e=>e.split(` `)}),sj.isolate=new sj({deserialize:e=>{if(e&&e!=`rtl`&&e!=`ltr`&&e!=`auto`)throw RangeError(`Invalid value for isolate: `+e);return e||`auto`}}),sj.contextHash=new sj({perNode:!0}),sj.lookAhead=new sj({perNode:!0}),sj.mounted=new sj({perNode:!0});var cj=class{constructor(e,t,n,r=!1){this.tree=e,this.overlay=t,this.parser=n,this.bracketed=r}static get(e){return e&&e.props&&e.props[sj.mounted.id]}},lj=Object.create(null),uj=class e{constructor(e,t,n,r=0){this.name=e,this.props=t,this.id=n,this.flags=r}static define(t){let n=t.props&&t.props.length?Object.create(null):lj,r=+!!t.top|(t.skipped?2:0)|(t.error?4:0)|(t.name==null?8:0),i=new e(t.name||``,n,t.id,r);if(t.props){for(let e of t.props)if(Array.isArray(e)||(e=e(i)),e){if(e[0].perNode)throw RangeError(`Can't store a per-node prop on a node type`);n[e[0].id]=e[1]}}return i}prop(e){return this.props[e.id]}get isTop(){return(this.flags&1)>0}get isSkipped(){return(this.flags&2)>0}get isError(){return(this.flags&4)>0}get isAnonymous(){return(this.flags&8)>0}is(e){if(typeof e==`string`){if(this.name==e)return!0;let t=this.prop(sj.group);return t?t.indexOf(e)>-1:!1}return this.id==e}static match(e){let t=Object.create(null);for(let n in e)for(let r of n.split(` `))t[r]=e[n];return e=>{for(let n=e.prop(sj.group),r=-1;r<(n?n.length:0);r++){let i=t[r<0?e.name:n[r]];if(i)return i}}}};uj.none=new uj(``,Object.create(null),0,8);var dj=class e{constructor(e){this.types=e;for(let t=0;t<e.length;t++)if(e[t].id!=t)throw RangeError(`Node type ids should correspond to array positions when creating a node set`)}extend(...t){let n=[];for(let e of this.types){let r=null;for(let n of t){let t=n(e);if(t){r||=Object.assign({},e.props);let n=t[1],i=t[0];i.combine&&i.id in r&&(n=i.combine(r[i.id],n)),r[i.id]=n}}n.push(r?new uj(e.name,r,e.id,e.flags):e)}return new e(n)}},fj=new WeakMap,pj=new WeakMap,mj;(function(e){e[e.ExcludeBuffers=1]=`ExcludeBuffers`,e[e.IncludeAnonymous=2]=`IncludeAnonymous`,e[e.IgnoreMounts=4]=`IgnoreMounts`,e[e.IgnoreOverlays=8]=`IgnoreOverlays`,e[e.EnterBracketed=16]=`EnterBracketed`})(mj||={});var hj=class e{constructor(e,t,n,r,i){if(this.type=e,this.children=t,this.positions=n,this.length=r,this.props=null,i&&i.length){this.props=Object.create(null);for(let[e,t]of i)this.props[typeof e==`number`?e:e.id]=t}}toString(){let e=cj.get(this);if(e&&!e.overlay)return e.tree.toString();let t=``;for(let e of this.children){let n=e.toString();n&&(t&&(t+=`,`),t+=n)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(t.length?`(`+t+`)`:``):t}cursor(e=0){return new kj(this.topNode,e)}cursorAt(e,t=0,n=0){let r=new kj(fj.get(this)||this.topNode);return r.moveTo(e,t),fj.set(this,r._tree),r}get topNode(){return new xj(this,0,0,null)}resolve(e,t=0){let n=yj(fj.get(this)||this.topNode,e,t,!1);return fj.set(this,n),n}resolveInner(e,t=0){let n=yj(pj.get(this)||this.topNode,e,t,!0);return pj.set(this,n),n}resolveStack(e,t=0){return Oj(this,e,t)}iterate(e){let{enter:t,leave:n,from:r=0,to:i=this.length}=e,a=e.mode||0,o=(a&mj.IncludeAnonymous)>0;for(let e=this.cursor(a|mj.IncludeAnonymous);;){let a=!1;if(e.from<=i&&e.to>=r&&(!o&&e.type.isAnonymous||t(e)!==!1)){if(e.firstChild())continue;a=!0}for(;a&&n&&(o||!e.type.isAnonymous)&&n(e),!e.nextSibling();){if(!e.parent())return;a=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let t in this.props)e.push([+t,this.props[t]]);return e}balance(t={}){return this.children.length<=8?this:Pj(uj.none,this.children,this.positions,0,this.children.length,0,this.length,(t,n,r)=>new e(this.type,t,n,r,this.propValues),t.makeTree||((t,n,r)=>new e(uj.none,t,n,r)))}static build(e){return jj(e)}};hj.empty=new hj(uj.none,[],[],0);var gj=class e{constructor(e,t){this.buffer=e,this.index=t}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new e(this.buffer,this.index)}},_j=class e{constructor(e,t,n){this.buffer=e,this.length=t,this.set=n}get type(){return uj.none}toString(){let e=[];for(let t=0;t<this.buffer.length;)e.push(this.childString(t)),t=this.buffer[t+3];return e.join(`,`)}childString(e){let t=this.buffer[e],n=this.buffer[e+3],r=this.set.types[t],i=r.name;if(/\W/.test(i)&&!r.isError&&(i=JSON.stringify(i)),e+=4,n==e)return i;let a=[];for(;e<n;)a.push(this.childString(e)),e=this.buffer[e+3];return i+`(`+a.join(`,`)+`)`}findChild(e,t,n,r,i){let{buffer:a}=this,o=-1;for(let s=e;s!=t&&!(vj(i,r,a[s+1],a[s+2])&&(o=s,n>0));s=a[s+3]);return o}slice(t,n,r){let i=this.buffer,a=new Uint16Array(n-t),o=0;for(let e=t,s=0;e<n;){a[s++]=i[e++],a[s++]=i[e++]-r;let n=a[s++]=i[e++]-r;a[s++]=i[e++]-t,o=Math.max(o,n)}return new e(a,o,this.set)}};function vj(e,t,n,r){switch(e){case-2:return n<t;case-1:return r>=t&&n<t;case 0:return n<t&&r>t;case 1:return n<=t&&r>t;case 2:return r>t;case 4:return!0}}function yj(e,t,n,r){for(;e.from==e.to||(n<1?e.from>=t:e.from>t)||(n>-1?e.to<=t:e.to<t);){let t=!r&&e instanceof xj&&e.index<0?null:e.parent;if(!t)return e;e=t}let i=r?0:mj.IgnoreOverlays;if(r)for(let r=e,a=r.parent;a;r=a,a=r.parent)r instanceof xj&&r.index<0&&a.enter(t,n,i)?.from!=r.from&&(e=a);for(;;){let r=e.enter(t,n,i);if(!r)return e;e=r}}var bj=class{cursor(e=0){return new kj(this,e)}getChild(e,t=null,n=null){let r=Sj(this,e,t,n);return r.length?r[0]:null}getChildren(e,t=null,n=null){return Sj(this,e,t,n)}resolve(e,t=0){return yj(this,e,t,!1)}resolveInner(e,t=0){return yj(this,e,t,!0)}matchContext(e){return Cj(this.parent,e)}enterUnfinishedNodesBefore(e){let t=this.childBefore(e),n=this;for(;t;){let e=t.lastChild;if(!e||e.to!=t.to)break;e.type.isError&&e.from==e.to?(n=t,t=e.prevSibling):t=e}return n}get node(){return this}get next(){return this.parent}},xj=class e extends bj{constructor(e,t,n,r){super(),this._tree=e,this.from=t,this.index=n,this._parent=r}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(t,n,r,i,a=0){for(let o=this;;){for(let{children:s,positions:c}=o._tree,l=n>0?s.length:-1;t!=l;t+=n){let l=s[t],u=c[t]+o.from,d;if(a&mj.EnterBracketed&&l instanceof hj&&(d=cj.get(l))&&!d.overlay&&d.bracketed&&r>=u&&r<=u+l.length||vj(i,r,u,u+l.length)){if(l instanceof _j){if(a&mj.ExcludeBuffers)continue;let e=l.findChild(0,l.buffer.length,n,r-u,i);if(e>-1)return new Tj(new wj(o,l,t,u),null,e)}else if(a&mj.IncludeAnonymous||!l.type.isAnonymous||Aj(l)){let s;if(!(a&mj.IgnoreMounts)&&(s=cj.get(l))&&!s.overlay)return new e(s.tree,u,t,o);let c=new e(l,u,t,o);return a&mj.IncludeAnonymous||!c.type.isAnonymous?c:c.nextChild(n<0?l.children.length-1:0,n,r,i,a)}}}if(a&mj.IncludeAnonymous||!o.type.isAnonymous||(t=o.index>=0?o.index+n:n<0?-1:o._parent._tree.children.length,o=o._parent,!o))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}prop(e){return this._tree.prop(e)}enter(t,n,r=0){let i;if(!(r&mj.IgnoreOverlays)&&(i=cj.get(this._tree))&&i.overlay){let a=t-this.from,o=r&mj.EnterBracketed&&i.bracketed;for(let{from:t,to:r}of i.overlay)if((n>0||o?t<=a:t<a)&&(n<0||o?r>=a:r>a))return new e(i.tree,i.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,t,n,r)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}};function Sj(e,t,n,r){let i=e.cursor(),a=[];if(!i.firstChild())return a;if(n!=null){for(let e=!1;!e;)if(e=i.type.is(n),!i.nextSibling())return a}for(;;){if(r!=null&&i.type.is(r))return a;if(i.type.is(t)&&a.push(i.node),!i.nextSibling())return r==null?a:[]}}function Cj(e,t,n=t.length-1){for(let r=e;n>=0;r=r.parent){if(!r)return!1;if(!r.type.isAnonymous){if(t[n]&&t[n]!=r.name)return!1;n--}}return!0}var wj=class{constructor(e,t,n,r){this.parent=e,this.buffer=t,this.index=n,this.start=r}},Tj=class e extends bj{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,t,n){super(),this.context=e,this._parent=t,this.index=n,this.type=e.buffer.set.types[e.buffer.buffer[n]]}child(t,n,r){let{buffer:i}=this.context,a=i.findChild(this.index+4,i.buffer[this.index+3],t,n-this.context.start,r);return a<0?null:new e(this.context,this,a)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}prop(e){return this.type.prop(e)}enter(t,n,r=0){if(r&mj.ExcludeBuffers)return null;let{buffer:i}=this.context,a=i.findChild(this.index+4,i.buffer[this.index+3],n>0?1:-1,t-this.context.start,n);return a<0?null:new e(this.context,this,a)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:t}=this.context,n=t.buffer[this.index+3];return n<(this._parent?t.buffer[this._parent.index+3]:t.buffer.length)?new e(this.context,this._parent,n):this.externalSibling(1)}get prevSibling(){let{buffer:t}=this.context,n=this._parent?this._parent.index+4:0;return this.index==n?this.externalSibling(-1):new e(this.context,this._parent,t.findChild(n,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],t=[],{buffer:n}=this.context,r=this.index+4,i=n.buffer[this.index+3];if(i>r){let a=n.buffer[this.index+1];e.push(n.slice(r,i,a)),t.push(0)}return new hj(this.type,e,t,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}};function Ej(e){if(!e.length)return null;let t=0,n=e[0];for(let r=1;r<e.length;r++){let i=e[r];(i.from>n.from||i.to<n.to)&&(n=i,t=r)}let r=n instanceof xj&&n.index<0?null:n.parent,i=e.slice();return r?i[t]=r:i.splice(t,1),new Dj(i,n)}var Dj=class{constructor(e,t){this.heads=e,this.node=t}get next(){return Ej(this.heads)}};function Oj(e,t,n){let r=e.resolveInner(t,n),i=null;for(let e=r instanceof xj?r:r.context.parent;e;e=e.parent)if(e.index<0){let a=e.parent;(i||=[r]).push(a.resolve(t,n)),e=a}else{let a=cj.get(e.tree);if(a&&a.overlay&&a.overlay[0].from<=t&&a.overlay[a.overlay.length-1].to>=t){let o=new xj(a.tree,a.overlay[0].from+e.from,-1,e);(i||=[r]).push(yj(o,t,n,!1))}}return i?Ej(i):r}var kj=class{get name(){return this.type.name}constructor(e,t=0){if(this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,this.mode=t&~mj.EnterBracketed,e instanceof xj)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let t=e._parent;t;t=t._parent)this.stack.unshift(t.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return e?(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0):!1}yieldBuf(e,t){this.index=e;let{start:n,buffer:r}=this.buffer;return this.type=t||r.set.types[r.buffer[e]],this.from=n+r.buffer[e+1],this.to=n+r.buffer[e+2],!0}yield(e){return e?e instanceof xj?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)):!1}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,t,n){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,t,n,this.mode));let{buffer:r}=this.buffer,i=r.findChild(this.index+4,r.buffer[this.index+3],e,t-this.buffer.start,n);return i<0?!1:(this.stack.push(this.index),this.yieldBuf(i))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,t,n=this.mode){return this.buffer?n&mj.ExcludeBuffers?!1:this.enterChild(1,e,t):this.yield(this._tree.enter(e,t,n))}parent(){if(!this.buffer)return this.yieldNode(this.mode&mj.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&mj.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return this._tree._parent?this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode)):!1;let{buffer:t}=this.buffer,n=this.stack.length-1;if(e<0){let e=n<0?0:this.stack[n]+4;if(this.index!=e)return this.yieldBuf(t.findChild(e,this.index,-1,0,4))}else{let e=t.buffer[this.index+3];if(e<(n<0?t.buffer.length:t.buffer[this.stack[n]+3]))return this.yieldBuf(e)}return n<0&&this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode))}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let t,n,{buffer:r}=this;if(r){if(e>0){if(this.index<r.buffer.buffer.length)return!1}else for(let e=0;e<this.index;e++)if(r.buffer.buffer[e+3]<this.index)return!1;({index:t,parent:n}=r)}else({index:t,_parent:n}=this._tree);for(;n;{index:t,_parent:n}=n)if(t>-1)for(let r=t+e,i=e<0?-1:n._tree.children.length;r!=i;r+=e){let e=n._tree.children[r];if(this.mode&mj.IncludeAnonymous||e instanceof _j||!e.type.isAnonymous||Aj(e))return!1}return!0}move(e,t){if(t&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,t=0){for(;(this.from==this.to||(t<1?this.from>=e:this.from>e)||(t>-1?this.to<=e:this.to<e))&&this.parent(););for(;this.enterChild(1,e,t););return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,t=null,n=0;if(e&&e.context==this.buffer)scan:for(let r=this.index,i=this.stack.length;i>=0;){for(let a=e;a;a=a._parent)if(a.index==r){if(r==this.index)return a;t=a,n=i+1;break scan}r=this.stack[--i]}for(let e=n;e<this.stack.length;e++)t=new Tj(this.buffer,t,this.stack[e]);return this.bufferNode=new Tj(this.buffer,t,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,t){for(let n=0;;){let r=!1;if(this.type.isAnonymous||e(this)!==!1){if(this.firstChild()){n++;continue}this.type.isAnonymous||(r=!0)}for(;;){if(r&&t&&t(this),r=this.type.isAnonymous,!n)return;if(this.nextSibling())break;this.parent(),n--,r=!0}}}matchContext(e){if(!this.buffer)return Cj(this.node.parent,e);let{buffer:t}=this.buffer,{types:n}=t.set;for(let r=e.length-1,i=this.stack.length-1;r>=0;i--){if(i<0)return Cj(this._tree,e,r);let a=n[t.buffer[this.stack[i]]];if(!a.isAnonymous){if(e[r]&&e[r]!=a.name)return!1;r--}}return!0}};function Aj(e){return e.children.some(e=>e instanceof _j||!e.type.isAnonymous||Aj(e))}function jj(e){let{buffer:t,nodeSet:n,maxBufferLength:r=ij,reused:i=[],minRepeatType:a=n.types.length}=e,o=Array.isArray(t)?new gj(t,t.length):t,s=n.types,c=0,l=0;function u(e,t,_,v,y,b){let{id:x,start:S,end:C,size:w}=o,T=l,E=c;if(w<0){if(o.next(),w==-1){let t=i[x];_.push(t),v.push(S-e);return}if(w==-3){c=x;return}if(w==-4){l=x;return}throw RangeError(`Unrecognized record size: ${w}`)}let D=s[x],O,k,A=S-e;if(C-S<=r&&(k=h(o.pos-t,y))){let t=new Uint16Array(k.size-k.skip),r=o.pos-k.size,i=t.length;for(;o.pos>r;)i=g(k.start,t,i);O=new _j(t,C-k.start,n),A=k.start-e}else{let e=o.pos-w;o.next();let t=[],s=[],c=x>=a?x:-1,h=0,g=C,_=T;for(;o.pos>e;)c>=0&&o.id==c&&o.size>=0?(o.end<=g-r&&(p(t,s,S,h,o.end,g,c,_,E),h=t.length,g=o.end,_=l),o.next()):b>2500?d(S,e,t,s):(c>=0&&o.size==-1&&i[o.id].type==n.types[c]&&(h<t.length&&p(t,s,S,h,o.end,g,c,_,E),h=t.length+1,g=o.start,_=l),u(S,e,t,s,c,b+1));if(c>=0&&h>0&&h<t.length&&p(t,s,S,h,S,g,c,_,E),t.reverse(),s.reverse(),c>-1&&h>0){let e=f(D,E);O=Pj(D,t,s,0,t.length,0,C-S,e,e)}else O=m(D,t,s,C-S,T-C,E)}_.push(O),v.push(A)}function d(e,t,i,a){let s=[],c=0,l=-1;for(;o.pos>t;){let{id:e,start:t,end:n,size:i}=o;if(i>4)o.next();else if(l>-1&&t<l)break;else l<0&&(l=n-r),s.push(e,t,n),c++,o.next()}if(c){let t=new Uint16Array(c*4),r=s[s.length-2];for(let e=s.length-3,n=0;e>=0;e-=3)t[n++]=s[e],t[n++]=s[e+1]-r,t[n++]=s[e+2]-r,t[n++]=n;i.push(new _j(t,s[2]-r,n)),a.push(r-e)}}function f(e,t){return(n,r,i)=>{let a=0,o=n.length-1,s,c;if(o>=0&&(s=n[o])instanceof hj){if(!o&&s.type==e&&s.length==i)return s;(c=s.prop(sj.lookAhead))&&(a=r[o]+s.length+c-i)}return m(e,n,r,i,a,t)}}function p(e,t,r,i,a,o,s,c,l){let u=[],d=[];for(;e.length>i;)u.push(e.pop()),d.push(t.pop()+r-a);e.push(m(n.types[s],u,d,o-a,c-o,l)),t.push(a-r)}function m(e,t,n,r,i,a,o){if(a){let e=[sj.contextHash,a];o=o?[e].concat(o):[e]}if(i>25){let e=[sj.lookAhead,i];o=o?[e].concat(o):[e]}return new hj(e,t,n,r,o)}function h(e,t){let n=o.fork(),i=0,s=0,c=0,l=n.end-r,u={size:0,start:0,skip:0};scan:for(let r=n.pos-e;n.pos>r;){let e=n.size;if(n.id==t&&e>=0){u.size=i,u.start=s,u.skip=c,c+=4,i+=4,n.next();continue}let o=n.pos-e;if(e<0||o<r||n.start<l)break;let d=n.id>=a?4:0,f=n.start;for(n.next();n.pos>o;){if(n.size<0){if(n.size==-3||n.size==-4)d+=4;else break scan}else n.id>=a&&(d+=4);n.next()}s=f,i+=e,c+=d}return(t<0||i==e)&&(u.size=i,u.start=s,u.skip=c),u.size>4?u:void 0}function g(e,t,n){let{id:r,start:i,end:s,size:u}=o;if(o.next(),u>=0&&r<a){let a=n;if(u>4){let r=o.pos-(u-4);for(;o.pos>r;)n=g(e,t,n)}t[--n]=a,t[--n]=s-e,t[--n]=i-e,t[--n]=r}else u==-3?c=r:u==-4&&(l=r);return n}let _=[],v=[];for(;o.pos>0;)u(e.start||0,e.bufferStart||0,_,v,-1,0);let y=e.length??(_.length?v[0]+_[0].length:0);return new hj(s[e.topID],_.reverse(),v.reverse(),y)}var Mj=new WeakMap;function Nj(e,t){if(!e.isAnonymous||t instanceof _j||t.type!=e)return 1;let n=Mj.get(t);if(n==null){n=1;for(let r of t.children){if(r.type!=e||!(r instanceof hj)){n=1;break}n+=Nj(e,r)}Mj.set(t,n)}return n}function Pj(e,t,n,r,i,a,o,s,c){let l=0;for(let n=r;n<i;n++)l+=Nj(e,t[n]);let u=Math.ceil(l*1.5/8),d=[],f=[];function p(t,n,r,i,o){for(let s=r;s<i;){let r=s,l=n[s],m=Nj(e,t[s]);for(s++;s<i;s++){let n=Nj(e,t[s]);if(m+n>=u)break;m+=n}if(s==r+1){if(m>u){let e=t[r];p(e.children,e.positions,0,e.children.length,n[r]+o);continue}d.push(t[r])}else{let i=n[s-1]+t[s-1].length-l;d.push(Pj(e,t,n,r,s,l,i,null,c))}f.push(l+o-a)}}return p(t,n,r,i,0),(s||c)(d,f,o)}var Fj=class e{constructor(e,t,n,r,i=!1,a=!1){this.from=e,this.to=t,this.tree=n,this.offset=r,this.open=!!i|(a?2:0)}get openStart(){return(this.open&1)>0}get openEnd(){return(this.open&2)>0}static addTree(t,n=[],r=!1){let i=[new e(0,t.length,t,0,!1,r)];for(let e of n)e.to>t.length&&i.push(e);return i}static applyChanges(t,n,r=128){if(!n.length)return t;let i=[],a=1,o=t.length?t[0]:null;for(let s=0,c=0,l=0;;s++){let u=s<n.length?n[s]:null,d=u?u.fromA:1e9;if(d-c>=r)for(;o&&o.from<d;){let n=o;if(c>=n.from||d<=n.to||l){let t=Math.max(n.from,c)-l,r=Math.min(n.to,d)-l;n=t>=r?null:new e(t,r,n.tree,n.offset+l,s>0,!!u)}if(n&&i.push(n),o.to>d)break;o=a<t.length?t[a++]:null}if(!u)break;c=u.toA,l=u.toA-u.toB}return i}},Ij=class{startParse(e,t,n){return typeof e==`string`&&(e=new Lj(e)),n=n?n.length?n.map(e=>new oj(e.from,e.to)):[new oj(0,0)]:[new oj(0,e.length)],this.createParse(e,t||[],n)}parse(e,t,n){let r=this.startParse(e,t,n);for(;;){let e=r.advance();if(e)return e}}},Lj=class{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,t){return this.string.slice(e,t)}};new sj({perNode:!0});var Rj=0,zj=class e{constructor(e,t,n,r){this.name=e,this.set=t,this.base=n,this.modified=r,this.id=Rj++}toString(){let{name:e}=this;for(let t of this.modified)t.name&&(e=`${t.name}(${e})`);return e}static define(t,n){let r=typeof t==`string`?t:`?`;if(t instanceof e&&(n=t),n?.base)throw Error(`Can not derive from a modified tag`);let i=new e(r,[],null,[]);if(i.set.push(i),n)for(let e of n.set)i.set.push(e);return i}static defineModifier(e){let t=new Vj(e);return e=>e.modified.indexOf(t)>-1?e:Vj.get(e.base||e,e.modified.concat(t).sort((e,t)=>e.id-t.id))}},Bj=0,Vj=class e{constructor(e){this.name=e,this.instances=[],this.id=Bj++}static get(t,n){if(!n.length)return t;let r=n[0].instances.find(e=>e.base==t&&Hj(n,e.modified));if(r)return r;let i=[],a=new zj(t.name,i,t,n);for(let e of n)e.instances.push(a);let o=Uj(n);for(let n of t.set)if(!n.modified.length)for(let t of o)i.push(e.get(n,t));return a}};function Hj(e,t){return e.length==t.length&&e.every((e,n)=>e==t[n])}function Uj(e){let t=[[]];for(let n=0;n<e.length;n++)for(let r=0,i=t.length;r<i;r++)t.push(t[r].concat(e[n]));return t.sort((e,t)=>t.length-e.length)}function Wj(e){let t=Object.create(null);for(let n in e){let r=e[n];Array.isArray(r)||(r=[r]);for(let e of n.split(` `))if(e){let n=[],i=2,a=e;for(let t=0;;){if(a==`...`&&t>0&&t+3==e.length){i=1;break}let r=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(a);if(!r)throw RangeError(`Invalid path: `+e);if(n.push(r[0]==`*`?``:r[0][0]==`"`?JSON.parse(r[0]):r[0]),t+=r[0].length,t==e.length)break;let o=e[t++];if(t==e.length&&o==`!`){i=0;break}if(o!=`/`)throw RangeError(`Invalid path: `+e);a=e.slice(t)}let o=n.length-1,s=n[o];if(!s)throw RangeError(`Invalid path: `+e);t[s]=new Kj(r,i,o>0?n.slice(0,o):null).sort(t[s])}}return Gj.add(t)}var Gj=new sj({combine(e,t){let n,r,i;for(;e||t;){if(!e||t&&e.depth<=t.depth?(i=t,t=t.next):(i=e,e=e.next),n&&n.mode==i.mode&&!i.context&&!n.context)continue;let a=new Kj(i.tags,i.mode,i.context);n?n.next=a:r=a,n=a}return r}}),Kj=class{constructor(e,t,n,r){this.tags=e,this.mode=t,this.context=n,this.next=r}get opaque(){return this.mode==0}get inherit(){return this.mode==1}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}};Kj.empty=new Kj([],2,null);function qj(e,t){let n=Object.create(null);for(let t of e)if(!Array.isArray(t.tag))n[t.tag.id]=t.class;else for(let e of t.tag)n[e.id]=t.class;let{scope:r,all:i=null}=t||{};return{style:e=>{let t=i;for(let r of e)for(let e of r.set){let r=n[e.id];if(r){t=t?t+` `+r:r;break}}return t},scope:r}}function Jj(e,t){let n=null;for(let r of e){let e=r.style(t);e&&(n=n?n+` `+e:e)}return n}function Yj(e,t,n,r=0,i=e.length){let a=new Xj(r,Array.isArray(t)?t:[t],n);a.highlightRange(e.cursor(),r,i,``,a.highlighters),a.flush(i)}var Xj=class{constructor(e,t,n){this.at=e,this.highlighters=t,this.span=n,this.class=``}startSpan(e,t){t!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=t)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,t,n,r,i){let{type:a,from:o,to:s}=e;if(o>=n||s<=t)return;a.isTop&&(i=this.highlighters.filter(e=>!e.scope||e.scope(a)));let c=r,l=Zj(e)||Kj.empty,u=Jj(i,l.tags);if(u&&(c&&(c+=` `),c+=u,l.mode==1&&(r+=(r?` `:``)+u)),this.startSpan(Math.max(t,o),c),l.opaque)return;let d=e.tree&&e.tree.prop(sj.mounted);if(d&&d.overlay){let a=e.node.enter(d.overlay[0].from+o,1),l=this.highlighters.filter(e=>!e.scope||e.scope(d.tree.type)),u=e.firstChild();for(let f=0,p=o;;f++){let m=f<d.overlay.length?d.overlay[f]:null,h=m?m.from+o:s,g=Math.max(t,p),_=Math.min(n,h);if(g<_&&u)for(;e.from<_&&(this.highlightRange(e,g,_,r,i),this.startSpan(Math.min(_,e.to),c),!(e.to>=h||!e.nextSibling())););if(!m||h>n)break;p=m.to+o,p>t&&(this.highlightRange(a.cursor(),Math.max(t,m.from+o),Math.min(n,p),``,l),this.startSpan(Math.min(n,p),c))}u&&e.parent()}else if(e.firstChild()){d&&(r=``);do if(!(e.to<=t)){if(e.from>=n)break;this.highlightRange(e,t,n,r,i),this.startSpan(Math.min(n,e.to),c)}while(e.nextSibling());e.parent()}}};function Zj(e){let t=e.type.prop(Gj);for(;t&&t.context&&!e.matchContext(t.context);)t=t.next;return t||null}var J=zj.define,Qj=J(),$j=J(),eM=J($j),tM=J($j),nM=J(),rM=J(nM),iM=J(nM),aM=J(),oM=J(aM),sM=J(),cM=J(),lM=J(),uM=J(lM),dM=J(),Y={comment:Qj,lineComment:J(Qj),blockComment:J(Qj),docComment:J(Qj),name:$j,variableName:J($j),typeName:eM,tagName:J(eM),propertyName:tM,attributeName:J(tM),className:J($j),labelName:J($j),namespace:J($j),macroName:J($j),literal:nM,string:rM,docString:J(rM),character:J(rM),attributeValue:J(rM),number:iM,integer:J(iM),float:J(iM),bool:J(nM),regexp:J(nM),escape:J(nM),color:J(nM),url:J(nM),keyword:sM,self:J(sM),null:J(sM),atom:J(sM),unit:J(sM),modifier:J(sM),operatorKeyword:J(sM),controlKeyword:J(sM),definitionKeyword:J(sM),moduleKeyword:J(sM),operator:cM,derefOperator:J(cM),arithmeticOperator:J(cM),logicOperator:J(cM),bitwiseOperator:J(cM),compareOperator:J(cM),updateOperator:J(cM),definitionOperator:J(cM),typeOperator:J(cM),controlOperator:J(cM),punctuation:lM,separator:J(lM),bracket:uM,angleBracket:J(uM),squareBracket:J(uM),paren:J(uM),brace:J(uM),content:aM,heading:oM,heading1:J(oM),heading2:J(oM),heading3:J(oM),heading4:J(oM),heading5:J(oM),heading6:J(oM),contentSeparator:J(aM),list:J(aM),quote:J(aM),emphasis:J(aM),strong:J(aM),link:J(aM),monospace:J(aM),strikethrough:J(aM),inserted:J(),deleted:J(),changed:J(),invalid:J(),meta:dM,documentMeta:J(dM),annotation:J(dM),processingInstruction:J(dM),definition:zj.defineModifier(`definition`),constant:zj.defineModifier(`constant`),function:zj.defineModifier(`function`),standard:zj.defineModifier(`standard`),local:zj.defineModifier(`local`),special:zj.defineModifier(`special`)};for(let e in Y){let t=Y[e];t instanceof zj&&(t.name=e)}qj([{tag:Y.link,class:`tok-link`},{tag:Y.heading,class:`tok-heading`},{tag:Y.emphasis,class:`tok-emphasis`},{tag:Y.strong,class:`tok-strong`},{tag:Y.keyword,class:`tok-keyword`},{tag:Y.atom,class:`tok-atom`},{tag:Y.bool,class:`tok-bool`},{tag:Y.url,class:`tok-url`},{tag:Y.labelName,class:`tok-labelName`},{tag:Y.inserted,class:`tok-inserted`},{tag:Y.deleted,class:`tok-deleted`},{tag:Y.literal,class:`tok-literal`},{tag:Y.string,class:`tok-string`},{tag:Y.number,class:`tok-number`},{tag:[Y.regexp,Y.escape,Y.special(Y.string)],class:`tok-string2`},{tag:Y.variableName,class:`tok-variableName`},{tag:Y.local(Y.variableName),class:`tok-variableName tok-local`},{tag:Y.definition(Y.variableName),class:`tok-variableName tok-definition`},{tag:Y.special(Y.variableName),class:`tok-variableName2`},{tag:Y.definition(Y.propertyName),class:`tok-propertyName tok-definition`},{tag:Y.typeName,class:`tok-typeName`},{tag:Y.namespace,class:`tok-namespace`},{tag:Y.className,class:`tok-className`},{tag:Y.macroName,class:`tok-macroName`},{tag:Y.propertyName,class:`tok-propertyName`},{tag:Y.operator,class:`tok-operator`},{tag:Y.comment,class:`tok-comment`},{tag:Y.meta,class:`tok-meta`},{tag:Y.invalid,class:`tok-invalid`},{tag:Y.punctuation,class:`tok-punctuation`}]);var fM=new sj;function pM(e){return ow.define({combine:e?t=>t.concat(e):void 0})}var mM=new sj,hM=class{constructor(e,t,n=[],r=``){this.data=e,this.name=r,Yw.prototype.hasOwnProperty(`tree`)||Object.defineProperty(Yw.prototype,"tree",{get(){return vM(this)}}),this.parser=t,this.extension=[DM.of(this),Yw.languageData.of((e,t,n)=>{let r=gM(e,t,n),i=r.type.prop(fM);if(!i)return[];let a=e.facet(i),o=r.type.prop(mM);if(o){let i=r.resolve(t-r.from,n);for(let t of o)if(t.test(i,e)){let n=e.facet(t.facet);return t.type==`replace`?n:n.concat(a)}}return a})].concat(n)}isActiveAt(e,t,n=-1){return gM(e,t,n).type.prop(fM)==this.data}findRegions(e){let t=e.facet(DM);if(t?.data==this.data)return[{from:0,to:e.doc.length}];if(!t||!t.allowsNesting)return[];let n=[],r=(e,t)=>{if(e.prop(fM)==this.data){n.push({from:t,to:t+e.length});return}let i=e.prop(sj.mounted);if(i){if(i.tree.prop(fM)==this.data){if(i.overlay)for(let e of i.overlay)n.push({from:e.from+t,to:e.to+t});else n.push({from:t,to:t+e.length});return}if(i.overlay){let e=n.length;if(r(i.tree,i.overlay[0].from+t),n.length>e)return}}for(let n=0;n<e.children.length;n++){let i=e.children[n];i instanceof hj&&r(i,e.positions[n]+t)}};return r(vM(e),0),n}get allowsNesting(){return!0}};hM.setState=Pw.define();function gM(e,t,n){let r=e.facet(DM),i=vM(e).topNode;if(!r||r.allowsNesting)for(let e=i;e;e=e.enter(t,n,mj.ExcludeBuffers|mj.EnterBracketed))e.type.isTop&&(i=e);return i}var _M=class e extends hM{constructor(e,t,n){super(e,t,[],n),this.parser=t}static define(t){let n=pM(t.languageData);return new e(n,t.parser.configure({props:[fM.add(e=>e.isTop?n:void 0)]}),t.name)}configure(t,n){return new e(this.data,this.parser.configure(t),n||this.name)}get allowsNesting(){return this.parser.hasWrappers()}};function vM(e){let t=e.field(hM.state,!1);return t?t.tree:hj.empty}var yM=class{constructor(e){this.doc=e,this.cursorPos=0,this.string=``,this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,t){let n=this.cursorPos-this.string.length;return e<n||t>=this.cursorPos?this.doc.sliceString(e,t):this.string.slice(e-n,t-n)}},bM=null,xM=class e{constructor(e,t,n=[],r,i,a,o,s){this.parser=e,this.state=t,this.fragments=n,this.tree=r,this.treeLen=i,this.viewport=a,this.skipped=o,this.scheduleOn=s,this.parse=null,this.tempSkipped=[]}static create(t,n,r){return new e(t,n,[],hj.empty,0,r,[],null)}startParse(){return this.parser.startParse(new yM(this.state.doc),this.fragments)}work(e,t){return t!=null&&t>=this.state.doc.length&&(t=void 0),this.tree!=hj.empty&&this.isDone(t??this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{if(typeof e==`number`){let t=Date.now()+e;e=()=>Date.now()>t}for(this.parse||=this.startParse(),t!=null&&(this.parse.stoppedAt==null||this.parse.stoppedAt>t)&&t<this.state.doc.length&&this.parse.stopAt(t);;){let n=this.parse.advance();if(n){if(this.fragments=this.withoutTempSkipped(Fj.addTree(n,this.fragments,this.parse.stoppedAt!=null)),this.treeLen=this.parse.stoppedAt??this.state.doc.length,this.tree=n,this.parse=null,this.treeLen<(t??this.state.doc.length))this.parse=this.startParse();else return!0}if(e())return!1}})}takeTree(){let e,t;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((this.parse.stoppedAt==null||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(t=this.parse.advance()););}),this.treeLen=e,this.tree=t,this.fragments=this.withoutTempSkipped(Fj.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let t=bM;bM=this;try{return e()}finally{bM=t}}withoutTempSkipped(e){for(let t;t=this.tempSkipped.pop();)e=SM(e,t.from,t.to);return e}changes(t,n){let{fragments:r,tree:i,treeLen:a,viewport:o,skipped:s}=this;if(this.takeTree(),!t.empty){let e=[];if(t.iterChangedRanges((t,n,r,i)=>e.push({fromA:t,toA:n,fromB:r,toB:i})),r=Fj.applyChanges(r,e),i=hj.empty,a=0,o={from:t.mapPos(o.from,-1),to:t.mapPos(o.to,1)},this.skipped.length){s=[];for(let e of this.skipped){let n=t.mapPos(e.from,1),r=t.mapPos(e.to,-1);n<r&&s.push({from:n,to:r})}}}return new e(this.parser,n,r,i,a,o,s,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let t=this.skipped.length;for(let t=0;t<this.skipped.length;t++){let{from:n,to:r}=this.skipped[t];n<e.to&&r>e.from&&(this.fragments=SM(this.fragments,n,r),this.skipped.splice(t--,1))}return this.skipped.length>=t?!1:(this.reset(),!0)}reset(){this.parse&&=(this.takeTree(),null)}skipUntilInView(e,t){this.skipped.push({from:e,to:t})}static getSkippingParser(e){return new class extends Ij{createParse(t,n,r){let i=r[0].from,a=r[r.length-1].to;return{parsedPos:i,advance(){let t=bM;if(t){for(let e of r)t.tempSkipped.push(e);e&&(t.scheduleOn=t.scheduleOn?Promise.all([t.scheduleOn,e]):e)}return this.parsedPos=a,new hj(uj.none,[],[],a-i)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let t=this.fragments;return this.treeLen>=e&&t.length&&t[0].from==0&&t[0].to>=e}static get(){return bM}};function SM(e,t,n){return Fj.applyChanges(e,[{fromA:t,toA:n,fromB:t,toB:n}])}var CM=class e{constructor(e){this.context=e,this.tree=e.tree}apply(t){if(!t.docChanged&&this.tree==this.context.tree)return this;let n=this.context.changes(t.changes,t.state),r=this.context.treeLen==t.startState.doc.length?void 0:Math.max(t.changes.mapPos(this.context.treeLen),n.viewport.to);return n.work(20,r)||n.takeTree(),new e(n)}static init(t){let n=Math.min(3e3,t.doc.length),r=xM.create(t.facet(DM).parser,t,{from:0,to:n});return r.work(20,n)||r.takeTree(),new e(r)}};hM.state=pw.define({create:CM.init,update(e,t){for(let e of t.effects)if(e.is(hM.setState))return e.value;return t.startState.facet(DM)==t.state.facet(DM)?e.apply(t):CM.init(t.state)}});var wM=e=>{let t=setTimeout(()=>e(),500);return()=>clearTimeout(t)};typeof requestIdleCallback<`u`&&(wM=e=>{let t=-1,n=setTimeout(()=>{t=requestIdleCallback(e,{timeout:400})},100);return()=>t<0?clearTimeout(n):cancelIdleCallback(t)});var TM=typeof navigator<`u`&&navigator.scheduling?.isInputPending?()=>navigator.scheduling.isInputPending():null,EM=CD.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let t=this.view.state.field(hM.state).context;(t.updateViewport(e.view.viewport)||this.view.viewport.to>t.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(t)}scheduleWork(){if(this.working)return;let{state:e}=this.view,t=e.field(hM.state);(t.tree!=t.context.tree||!t.context.isDone(e.doc.length))&&(this.working=wM(this.work))}work(e){this.working=null;let t=Date.now();if(this.chunkEnd<t&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=t+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:n,viewport:{to:r}}=this.view,i=n.field(hM.state);if(i.tree==i.context.tree&&i.context.isDone(r+1e5))return;let a=Date.now()+Math.min(this.chunkBudget,100,e&&!TM?Math.max(25,e.timeRemaining()-5):1e9),o=i.context.treeLen<r&&n.doc.length>r+1e3,s=i.context.work(()=>TM&&TM()||Date.now()>a,r+(o?0:1e5));this.chunkBudget-=Date.now()-t,(s||this.chunkBudget<=0)&&(i.context.takeTree(),this.view.dispatch({effects:hM.setState.of(new CM(i.context))})),this.chunkBudget>0&&(!s||o)&&this.scheduleWork(),this.checkAsyncSchedule(i.context)}checkAsyncSchedule(e){e.scheduleOn&&=(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(e=>yD(this.view.state,e)).then(()=>this.workScheduled--),null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),DM=ow.define({combine(e){return e.length?e[0]:null},enables:e=>[hM.state,EM,qk.contentAttributes.compute([e],t=>{let n=t.facet(e);return n&&n.name?{"data-language":n.name}:{}})]}),OM=class{constructor(e,t=[]){this.language=e,this.support=t,this.extension=[e,t]}},kM=ow.define(),AM=ow.define({combine:e=>{if(!e.length)return` `;let t=e[0];if(!t||/\S/.test(t)||Array.from(t).some(e=>e!=t[0]))throw Error(`Invalid indent unit: `+JSON.stringify(e[0]));return t}});function jM(e){let t=e.facet(AM);return t.charCodeAt(0)==9?e.tabSize*t.length:t.length}function MM(e,t){let n=``,r=e.tabSize,i=e.facet(AM)[0];if(i==` `){for(;t>=r;)n+=` `,t-=r;i=` `}for(let e=0;e<t;e++)n+=i;return n}function NM(e,t){e instanceof Yw&&(e=new PM(e));for(let n of e.state.facet(kM)){let r=n(e,t);if(r!==void 0)return r}let n=vM(e.state);return n.length>=t?IM(e,n,t):null}var PM=class{constructor(e,t={}){this.state=e,this.options=t,this.unit=jM(e)}lineAt(e,t=1){let n=this.state.doc.lineAt(e),{simulateBreak:r,simulateDoubleBreak:i}=this.options;return r!=null&&r>=n.from&&r<=n.to?i&&r==e?{text:``,from:e}:(t<0?r<e:r<=e)?{text:n.text.slice(r-n.from),from:r}:{text:n.text.slice(0,r-n.from),from:n.from}:n}textAfterPos(e,t=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return``;let{text:n,from:r}=this.lineAt(e,t);return n.slice(e-r,Math.min(n.length,e+100-r))}column(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.countColumn(n,e-r),a=this.options.overrideIndentation?this.options.overrideIndentation(r):-1;return a>-1&&(i+=a-this.countColumn(n,n.search(/\S|$/))),i}countColumn(e,t=e.length){return gT(e,this.state.tabSize,t)}lineIndent(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.options.overrideIndentation;if(i){let e=i(r);if(e>-1)return e}return this.countColumn(n,n.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}},FM=new sj;function IM(e,t,n){let r=t.resolveStack(n),i=t.resolveInner(n,-1).resolve(n,0).enterUnfinishedNodesBefore(n);if(i!=r.node){let e=[];for(let t=i;t&&!(t.from<r.node.from||t.to>r.node.to||t.from==r.node.from&&t.type==r.node.type);t=t.parent)e.push(t);for(let t=e.length-1;t>=0;t--)r={node:e[t],next:r}}return LM(r,e,n)}function LM(e,t,n){for(let r=e;r;r=r.next){let e=zM(r.node);if(e)return e(VM.create(t,n,r))}return 0}function RM(e){return e.pos==e.options.simulateBreak&&e.options.simulateDoubleBreak}function zM(e){let t=e.type.prop(FM);if(t)return t;let n=e.firstChild,r;if(n&&(r=n.type.prop(sj.closedBy))){let t=e.lastChild,n=t&&r.indexOf(t.name)>-1;return e=>WM(e,!0,1,void 0,n&&!RM(e)?t.from:void 0)}return e.parent==null?BM:null}function BM(){return 0}var VM=class e extends PM{constructor(e,t,n){super(e.state,e.options),this.base=e,this.pos=t,this.context=n}get node(){return this.context.node}static create(t,n,r){return new e(t,n,r)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let t=this.state.doc.lineAt(e.from);for(;;){let n=e.resolve(t.from);for(;n.parent&&n.parent.from==n.from;)n=n.parent;if(HM(n,e))break;t=this.state.doc.lineAt(n.from)}return this.lineIndent(t.from)}continue(){return LM(this.context.next,this.base,this.pos)}};function HM(e,t){for(let n=t;n;n=n.parent)if(e==n)return!0;return!1}function UM(e){let t=e.node,n=t.childAfter(t.from),r=t.lastChild;if(!n)return null;let i=e.options.simulateBreak,a=e.state.doc.lineAt(n.from),o=i==null||i<=a.from?a.to:Math.min(a.to,i);for(let e=n.to;;){let i=t.childAfter(e);if(!i||i==r)return null;if(!i.type.isSkipped){if(i.from>=o)return null;let e=/^ */.exec(a.text.slice(n.to-a.from))[0].length;return{from:n.from,to:n.to+e}}e=i.to}}function WM(e,t,n,r,i){let a=e.textAfter,o=a.match(/^\s*/)[0].length,s=r&&a.slice(o,o+r.length)==r||i==e.pos+o,c=t?UM(e):null;return c?s?e.column(c.from):e.column(c.to):e.baseIndent+(s?0:e.unit*n)}function GM({except:e,units:t=1}={}){return n=>{let r=e&&e.test(n.textAfter);return n.baseIndent+(r?0:t*n.unit)}}var KM=200;function qM(){return Yw.transactionFilter.of(e=>{if(!e.docChanged||!e.isUserEvent(`input.type`)&&!e.isUserEvent(`input.complete`))return e;let t=e.startState.languageDataAt(`indentOnInput`,e.startState.selection.main.head);if(!t.length)return e;let n=e.newDoc,{head:r}=e.newSelection.main,i=n.lineAt(r);if(r>i.from+KM)return e;let a=n.sliceString(i.from,r);if(!t.some(e=>e.test(a)))return e;let{state:o}=e,s=-1,c=[];for(let{head:e}of o.selection.ranges){let t=o.doc.lineAt(e);if(t.from==s)continue;s=t.from;let n=NM(o,t.from);if(n==null)continue;let r=/^\s*/.exec(t.text)[0],i=MM(o,n);r!=i&&c.push({from:t.from,to:t.from+r.length,insert:i})}return c.length?[e,{changes:c,sequential:!0}]:e})}var JM=ow.define(),YM=new sj;function XM(e){let t=e.firstChild,n=e.lastChild;return t&&t.to<n.from?{from:t.to,to:n.type.isError?e.to:n.from}:null}function ZM(e,t,n){let r=vM(e);if(r.length<n)return null;let i=r.resolveStack(n,1),a=null;for(let o=i;o;o=o.next){let i=o.node;if(i.to<=n||i.from>n)continue;if(a&&i.from<t)break;let s=i.type.prop(YM);if(s&&(i.to<r.length-50||r.length==e.doc.length||!QM(i))){let r=s(i,e);r&&r.from<=n&&r.from>=t&&r.to>n&&(a=r)}}return a}function QM(e){let t=e.lastChild;return t&&t.to==e.to&&t.type.isError}function $M(e,t,n){for(let r of e.facet(JM)){let i=r(e,t,n);if(i)return i}return ZM(e,t,n)}function eN(e,t){let n=t.mapPos(e.from,1),r=t.mapPos(e.to,-1);return n>=r?void 0:{from:n,to:r}}var tN=Pw.define({map:eN}),nN=Pw.define({map:eN});function rN(e){let t=[];for(let{head:n}of e.state.selection.ranges)t.some(e=>e.from<=n&&e.to>=n)||t.push(e.lineBlockAt(n));return t}var iN=pw.define({create(){return ZT.none},update(e,t){t.isUserEvent(`delete`)&&t.changes.iterChangedRanges((t,n)=>e=aN(e,t,n)),e=e.map(t.changes);let n=[];for(let r of t.effects)r.is(tN)&&!sN(e,r.value.from,r.value.to)?n.push(r.value):r.is(nN)&&(e=e.update({filter:(e,t)=>r.value.from!=e||r.value.to!=t,filterFrom:r.value.from,filterTo:r.value.to}));if(n.length){let{preparePlaceholder:r}=t.state.facet(mN),i=n.map(e=>(r?ZT.replace({widget:new vN(r(t.state,e))}):_N).range(e.from,e.to));e=e.update({add:i})}return t.selection&&(e=aN(e,t.selection.main.head)),e},provide:e=>qk.decorations.from(e),toJSON(e,t){let n=[];return e.between(0,t.doc.length,(e,t)=>{n.push(e,t)}),n},fromJSON(e){if(!Array.isArray(e)||e.length%2)throw RangeError(`Invalid JSON for fold state`);let t=[];for(let n=0;n<e.length;){let r=e[n++],i=e[n++];if(typeof r!=`number`||typeof i!=`number`)throw RangeError(`Invalid JSON for fold state`);t.push(_N.range(r,i))}return ZT.set(t,!0)}});function aN(e,t,n=t){let r=!1;return e.between(t,n,(e,i)=>{e<n&&i>t&&(r=!0)}),r?e.update({filterFrom:t,filterTo:n,filter:(e,r)=>e>=n||r<=t}):e}function oN(e,t,n){var r;let i=null;return(r=e.field(iN,!1))==null||r.between(t,n,(e,t)=>{(!i||i.from>e)&&(i={from:e,to:t})}),i}function sN(e,t,n){let r=!1;return e.between(t,t,(e,i)=>{e==t&&i==n&&(r=!0)}),r}function cN(e,t){return e.field(iN,!1)?t:t.concat(Pw.appendConfig.of(hN()))}var lN=e=>{for(let t of rN(e)){let n=$M(e.state,t.from,t.to);if(n)return e.dispatch({effects:cN(e.state,[tN.of(n),dN(e,n)])}),!0}return!1},uN=e=>{if(!e.state.field(iN,!1))return!1;let t=[];for(let n of rN(e)){let r=oN(e.state,n.from,n.to);r&&t.push(nN.of(r),dN(e,r,!1))}return t.length&&e.dispatch({effects:t}),t.length>0};function dN(e,t,n=!0){let r=e.state.doc.lineAt(t.from).number,i=e.state.doc.lineAt(t.to).number;return qk.announce.of(`${e.state.phrase(n?`Folded lines`:`Unfolded lines`)} ${r} ${e.state.phrase(`to`)} ${i}.`)}var fN=[{key:`Ctrl-Shift-[`,mac:`Cmd-Alt-[`,run:lN},{key:`Ctrl-Shift-]`,mac:`Cmd-Alt-]`,run:uN},{key:`Ctrl-Alt-[`,run:e=>{let{state:t}=e,n=[];for(let r=0;r<t.doc.length;){let i=e.lineBlockAt(r),a=$M(t,i.from,i.to);a&&n.push(tN.of(a)),r=(a?e.lineBlockAt(a.to):i).to+1}return n.length&&e.dispatch({effects:cN(e.state,n)}),!!n.length}},{key:`Ctrl-Alt-]`,run:e=>{let t=e.state.field(iN,!1);if(!t||!t.size)return!1;let n=[];return t.between(0,e.state.doc.length,(e,t)=>{n.push(nN.of({from:e,to:t}))}),e.dispatch({effects:n}),!0}}],pN={placeholderDOM:null,preparePlaceholder:null,placeholderText:`…`},mN=ow.define({combine(e){return Xw(e,pN)}});function hN(e){let t=[iN,SN];return e&&t.push(mN.of(e)),t}function gN(e,t){let{state:n}=e,r=n.facet(mN),i=t=>{let n=e.lineBlockAt(e.posAtDOM(t.target)),r=oN(e.state,n.from,n.to);r&&e.dispatch({effects:nN.of(r)}),t.preventDefault()};if(r.placeholderDOM)return r.placeholderDOM(e,i,t);let a=document.createElement(`span`);return a.textContent=r.placeholderText,a.setAttribute(`aria-label`,n.phrase(`folded code`)),a.title=n.phrase(`unfold`),a.className=`cm-foldPlaceholder`,a.onclick=i,a}var _N=ZT.replace({widget:new class extends YT{toDOM(e){return gN(e,null)}}}),vN=class extends YT{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return gN(e,this.value)}},yN={openText:`⌄`,closedText:`›`,markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1},bN=class extends MA{constructor(e,t){super(),this.config=e,this.open=t}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let t=document.createElement(`span`);return t.textContent=this.open?this.config.openText:this.config.closedText,t.title=e.state.phrase(this.open?`Fold line`:`Unfold line`),t}};function xN(e={}){let t={...yN,...e},n=new bN(t,!0),r=new bN(t,!1),i=CD.fromClass(class{constructor(e){this.from=e.viewport.from,this.markers=this.buildMarkers(e)}update(e){(e.docChanged||e.viewportChanged||e.startState.facet(DM)!=e.state.facet(DM)||e.startState.field(iN,!1)!=e.state.field(iN,!1)||vM(e.startState)!=vM(e.state)||t.foldingChanged(e))&&(this.markers=this.buildMarkers(e.view))}buildMarkers(e){let t=new aT;for(let i of e.viewportLineBlocks){let a=oN(e.state,i.from,i.to)?r:$M(e.state,i.from,i.to)?n:null;a&&t.add(i.from,i.from,a)}return t.finish()}}),{domEventHandlers:a}=t;return[i,LA({class:`cm-foldGutter`,markers(e){return e.plugin(i)?.markers||nT.empty},initialSpacer(){return new bN(t,!1)},domEventHandlers:{...a,click:(e,t,n)=>{if(a.click&&a.click(e,t,n))return!0;let r=oN(e.state,t.from,t.to);if(r)return e.dispatch({effects:nN.of(r)}),!0;let i=$M(e.state,t.from,t.to);return i?(e.dispatch({effects:tN.of(i)}),!0):!1}}}),hN()]}var SN=qk.baseTheme({".cm-foldPlaceholder":{backgroundColor:`#eee`,border:`1px solid #ddd`,color:`#888`,borderRadius:`.2em`,margin:`0 1px`,padding:`0 1px`,cursor:`pointer`},".cm-foldGutter span":{padding:`0 1px`,cursor:`pointer`}}),CN=class e{constructor(e,t){this.specs=e;let n;function r(e){let t=ST.newName();return(n||=Object.create(null))[`.`+t]=e,t}let i=typeof t.all==`string`?t.all:t.all?r(t.all):void 0,a=t.scope;this.scope=a instanceof hM?e=>e.prop(fM)==a.data:a?e=>e==a:void 0,this.style=qj(e.map(e=>({tag:e.tag,class:e.class||r(Object.assign({},e,{tag:null}))})),{all:i}).style,this.module=n?new ST(n):null,this.themeType=t.themeType}static define(t,n){return new e(t,n||{})}},wN=ow.define(),TN=ow.define({combine(e){return e.length?[e[0]]:null}});function EN(e){let t=e.facet(wN);return t.length?t:e.facet(TN)}function DN(e,t){let n=[kN],r;return e instanceof CN&&(e.module&&n.push(qk.styleModule.of(e.module)),r=e.themeType),t?.fallback?n.push(TN.of(e)):r?n.push(wN.computeN([qk.darkTheme],t=>t.facet(qk.darkTheme)==(r==`dark`)?[e]:[])):n.push(wN.of(e)),n}var ON=class{constructor(e){this.markCache=Object.create(null),this.tree=vM(e.state),this.decorations=this.buildDeco(e,EN(e.state)),this.decoratedTo=e.viewport.to}update(e){let t=vM(e.state),n=EN(e.state),r=n!=EN(e.startState),{viewport:i}=e.view,a=e.changes.mapPos(this.decoratedTo,1);t.length<i.to&&!r&&t.type==this.tree.type&&a>=i.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=a):(t!=this.tree||e.viewportChanged||r)&&(this.tree=t,this.decorations=this.buildDeco(e.view,n),this.decoratedTo=i.to)}buildDeco(e,t){if(!t||!this.tree.length)return ZT.none;let n=new aT;for(let{from:r,to:i}of e.visibleRanges)Yj(this.tree,t,(e,t,r)=>{n.add(e,t,this.markCache[r]||(this.markCache[r]=ZT.mark({class:r})))},r,i);return n.finish()}},kN=gw.high(CD.fromClass(ON,{decorations:e=>e.decorations}));Y.meta,Y.link,Y.heading,Y.emphasis,Y.strong,Y.strikethrough,Y.keyword,Y.atom,Y.bool,Y.url,Y.contentSeparator,Y.labelName,Y.literal,Y.inserted,Y.string,Y.deleted,Y.regexp,Y.escape,Y.string,Y.variableName,Y.variableName,Y.typeName,Y.namespace,Y.className,Y.variableName,Y.macroName,Y.propertyName,Y.comment,Y.invalid;var AN=qk.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:`#328c8252`},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:`#bb555544`}}),jN=1e4,MN=`()[]{}`,NN=ow.define({combine(e){return Xw(e,{afterCursor:!0,brackets:MN,maxScanDistance:jN,renderMatch:IN})}}),PN=ZT.mark({class:`cm-matchingBracket`}),FN=ZT.mark({class:`cm-nonmatchingBracket`});function IN(e){let t=[],n=e.matched?PN:FN;return t.push(n.range(e.start.from,e.start.to)),e.end&&t.push(n.range(e.end.from,e.end.to)),t}function LN(e){let t=[],n=e.facet(NN);for(let r of e.selection.ranges){if(!r.empty)continue;let i=UN(e,r.head,-1,n)||r.head>0&&UN(e,r.head-1,1,n)||n.afterCursor&&(UN(e,r.head,1,n)||r.head<e.doc.length&&UN(e,r.head+1,-1,n));i&&(t=t.concat(n.renderMatch(i,e)))}return ZT.set(t,!0)}var RN=[CD.fromClass(class{constructor(e){this.paused=!1,this.decorations=LN(e.state)}update(e){(e.docChanged||e.selectionSet||this.paused)&&(e.view.composing?(this.decorations=this.decorations.map(e.changes),this.paused=!0):(this.decorations=LN(e.state),this.paused=!1))}},{decorations:e=>e.decorations}),AN];function zN(e={}){return[NN.of(e),RN]}var BN=new sj;function VN(e,t,n){let r=e.prop(t<0?sj.openedBy:sj.closedBy);if(r)return r;if(e.name.length==1){let r=n.indexOf(e.name);if(r>-1&&r%2==+(t<0))return[n[r+t]]}return null}function HN(e){let t=e.type.prop(BN);return t?t(e.node):e}function UN(e,t,n,r={}){let i=r.maxScanDistance||jN,a=r.brackets||MN,o=vM(e),s=o.resolveInner(t,n);for(let r=s;r;r=r.parent){let i=VN(r.type,n,a);if(i&&r.from<r.to){let o=HN(r);if(o&&(n>0?t>=o.from&&t<o.to:t>o.from&&t<=o.to))return WN(e,t,n,r,o,i,a)}}return GN(e,t,n,o,s.type,i,a)}function WN(e,t,n,r,i,a,o){let s=r.parent,c={from:i.from,to:i.to},l=0,u=s?.cursor();if(u&&(n<0?u.childBefore(r.from):u.childAfter(r.to)))do if(n<0?u.to<=r.from:u.from>=r.to){if(l==0&&a.indexOf(u.type.name)>-1&&u.from<u.to){let e=HN(u);return{start:c,end:e?{from:e.from,to:e.to}:void 0,matched:!0}}if(VN(u.type,n,o))l++;else if(VN(u.type,-n,o)){if(l==0){let e=HN(u);return{start:c,end:e&&e.from<e.to?{from:e.from,to:e.to}:void 0,matched:!1}}l--}}while(n<0?u.prevSibling():u.nextSibling());return{start:c,matched:!1}}function GN(e,t,n,r,i,a,o){if(n<0?!t:t==e.doc.length)return null;let s=n<0?e.sliceDoc(t-1,t):e.sliceDoc(t,t+1),c=o.indexOf(s);if(c<0||c%2==0!=n>0)return null;let l={from:n<0?t-1:t,to:n>0?t+1:t},u=e.doc.iterRange(t,n>0?e.doc.length:0),d=0;for(let e=0;!u.next().done&&e<=a;){let a=u.value;n<0&&(e+=a.length);let s=t+e*n;for(let e=n>0?0:a.length-1,t=n>0?a.length:-1;e!=t;e+=n){let t=o.indexOf(a[e]);if(!(t<0||r.resolveInner(s+e,1).type!=i)){if(t%2==0==n>0)d++;else if(d==1)return{start:l,end:{from:s+e,to:s+e+1},matched:t>>1==c>>1};else d--}}n>0&&(e+=a.length)}return u.done?{start:l,matched:!1}:null}var KN=Object.create(null),qN=[uj.none],JN=[],YN=Object.create(null),XN=Object.create(null);for(let[e,t]of[[`variable`,`variableName`],[`variable-2`,`variableName.special`],[`string-2`,`string.special`],[`def`,`variableName.definition`],[`tag`,`tagName`],[`attribute`,`attributeName`],[`type`,`typeName`],[`builtin`,`variableName.standard`],[`qualifier`,`modifier`],[`error`,`invalid`],[`header`,`heading`],[`property`,`propertyName`]])XN[e]=QN(KN,t);function ZN(e,t){JN.indexOf(e)>-1||(JN.push(e),console.warn(t))}function QN(e,t){let n=[];for(let r of t.split(` `)){let t=[];for(let n of r.split(`.`)){let r=e[n]||Y[n];r?typeof r==`function`?t.length?t=t.map(r):ZN(n,`Modifier ${n} used at start of tag`):t.length?ZN(n,`Tag ${n} used as modifier`):t=Array.isArray(r)?r:[r]:ZN(n,`Unknown highlighting tag ${n}`)}for(let e of t)n.push(e)}if(!n.length)return 0;let r=t.replace(/ /g,`_`),i=r+` `+n.map(e=>e.id),a=YN[i];if(a)return a.id;let o=YN[i]=uj.define({id:qN.length,name:r,props:[Wj({[r]:n})]});return qN.push(o),o.id}FE.RTL,FE.LTR;var $N=e=>{let{state:t}=e,n=t.doc.lineAt(t.selection.main.from),r=iP(e.state,n.from);return r.line?tP(e):r.block?rP(e):!1};function eP(e,t){return({state:n,dispatch:r})=>{if(n.readOnly)return!1;let i=e(t,n);return i?(r(n.update(i)),!0):!1}}var tP=eP(lP,0),nP=eP(cP,0),rP=eP((e,t)=>cP(e,t,sP(t)),0);function iP(e,t){let n=e.languageDataAt(`commentTokens`,t,1);return n.length?n[0]:{}}var aP=50;function oP(e,{open:t,close:n},r,i){let a=e.sliceDoc(r-aP,r),o=e.sliceDoc(i,i+aP),s=/\s*$/.exec(a)[0].length,c=/^\s*/.exec(o)[0].length,l=a.length-s;if(a.slice(l-t.length,l)==t&&o.slice(c,c+n.length)==n)return{open:{pos:r-s,margin:s&&1},close:{pos:i+c,margin:c&&1}};let u,d;i-r<=100?u=d=e.sliceDoc(r,i):(u=e.sliceDoc(r,r+aP),d=e.sliceDoc(i-aP,i));let f=/^\s*/.exec(u)[0].length,p=/\s*$/.exec(d)[0].length,m=d.length-p-n.length;return u.slice(f,f+t.length)==t&&d.slice(m,m+n.length)==n?{open:{pos:r+f+t.length,margin:+!!/\s/.test(u.charAt(f+t.length))},close:{pos:i-p-n.length,margin:+!!/\s/.test(d.charAt(m-1))}}:null}function sP(e){let t=[];for(let n of e.selection.ranges){let r=e.doc.lineAt(n.from),i=n.to<=r.to?r:e.doc.lineAt(n.to);i.from>r.from&&i.from==n.to&&(i=n.to==r.to+1?r:e.doc.lineAt(n.to-1));let a=t.length-1;a>=0&&t[a].to>r.from?t[a].to=i.to:t.push({from:r.from+/^\s*/.exec(r.text)[0].length,to:i.to})}return t}function cP(e,t,n=t.selection.ranges){let r=n.map(e=>iP(t,e.from).block);if(!r.every(e=>e))return null;let i=n.map((e,n)=>oP(t,r[n],e.from,e.to));if(e!=2&&!i.every(e=>e))return{changes:t.changes(n.map((e,t)=>i[t]?[]:[{from:e.from,insert:r[t].open+` `},{from:e.to,insert:` `+r[t].close}]))};if(e!=1&&i.some(e=>e)){let e=[];for(let t=0,n;t<i.length;t++)if(n=i[t]){let i=r[t],{open:a,close:o}=n;e.push({from:a.pos-i.open.length,to:a.pos+a.margin},{from:o.pos-o.margin,to:o.pos+i.close.length})}return{changes:e}}return null}function lP(e,t,n=t.selection.ranges){let r=[],i=-1;ranges:for(let{from:e,to:a}of n){let n=r.length,o=1e9,s;for(let n=e;n<=a;){let c=t.doc.lineAt(n);if(s==null&&(s=iP(t,c.from).line,!s))continue ranges;if(c.from>i&&(e==a||a>c.from)){i=c.from;let e=/^\s*/.exec(c.text)[0].length,t=e==c.length,n=c.text.slice(e,e+s.length)==s?e:-1;e<c.text.length&&e<o&&(o=e),r.push({line:c,comment:n,token:s,indent:e,empty:t,single:!1})}n=c.to+1}if(o<1e9)for(let e=n;e<r.length;e++)r[e].indent<r[e].line.text.length&&(r[e].indent=o);r.length==n+1&&(r[n].single=!0)}if(e!=2&&r.some(e=>e.comment<0&&(!e.empty||e.single))){let e=[];for(let{line:t,token:n,indent:i,empty:a,single:o}of r)(o||!a)&&e.push({from:t.from+i,insert:n+` `});let n=t.changes(e);return{changes:n,selection:t.selection.map(n,1)}}if(e!=1&&r.some(e=>e.comment>=0)){let e=[];for(let{line:t,comment:n,token:i}of r)if(n>=0){let r=t.from+n,a=r+i.length;t.text[a-t.from]==` `&&a++,e.push({from:r,to:a})}return{changes:e}}return null}var uP=jw.define(),dP=jw.define(),fP=ow.define(),pP=ow.define({combine(e){return Xw(e,{minDepth:100,newGroupDelay:500,joinToEvent:(e,t)=>t},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,t)=>(n,r)=>e(n,r)||t(n,r)})}}),mP=pw.define({create(){return NP.empty},update(e,t){let n=t.state.facet(pP),r=t.annotation(uP);if(r){let i=xP.fromTransaction(t,r.selection),a=r.side,o=a==0?e.undone:e.done;return o=i?SP(o,o.length,n.minDepth,i):OP(o,t.startState.selection),new NP(a==0?r.rest:o,a==0?o:r.rest)}let i=t.annotation(dP);if((i==`full`||i==`before`)&&(e=e.isolate()),t.annotation(Fw.addToHistory)===!1)return t.changes.empty?e:e.addMapping(t.changes.desc);let a=xP.fromTransaction(t),o=t.annotation(Fw.time),s=t.annotation(Fw.userEvent);return a?e=e.addChanges(a,o,s,n,t):t.selection&&(e=e.addSelection(t.startState.selection,o,s,n.newGroupDelay)),(i==`full`||i==`after`)&&(e=e.isolate()),e},toJSON(e){return{done:e.done.map(e=>e.toJSON()),undone:e.undone.map(e=>e.toJSON())}},fromJSON(e){return new NP(e.done.map(xP.fromJSON),e.undone.map(xP.fromJSON))}});function hP(e={}){return[mP,pP.of(e),qk.domEventHandlers({beforeinput(e,t){let n=e.inputType==`historyUndo`?_P:e.inputType==`historyRedo`?vP:null;return n?(e.preventDefault(),n(t)):!1}})]}function gP(e,t){return function({state:n,dispatch:r}){if(!t&&n.readOnly)return!1;let i=n.field(mP,!1);if(!i)return!1;let a=i.pop(e,n,t);return a?(r(a),!0):!1}}var _P=gP(0,!1),vP=gP(1,!1),yP=gP(0,!0),bP=gP(1,!0),xP=class e{constructor(e,t,n,r,i){this.changes=e,this.effects=t,this.mapped=n,this.startSelection=r,this.selectionsAfter=i}setSelAfter(t){return new e(this.changes,this.effects,this.mapped,this.startSelection,t)}toJSON(){return{changes:this.changes?.toJSON(),mapped:this.mapped?.toJSON(),startSelection:this.startSelection?.toJSON(),selectionsAfter:this.selectionsAfter.map(e=>e.toJSON())}}static fromJSON(t){return new e(t.changes&&XC.fromJSON(t.changes),[],t.mapped&&YC.fromJSON(t.mapped),t.startSelection&&K.fromJSON(t.startSelection),t.selectionsAfter.map(K.fromJSON))}static fromTransaction(t,n){let r=EP;for(let e of t.startState.facet(fP)){let n=e(t);n.length&&(r=r.concat(n))}return!r.length&&t.changes.empty?null:new e(t.changes.invert(t.startState.doc),r,void 0,n||t.startState.selection,EP)}static selection(t){return new e(void 0,EP,void 0,void 0,t)}};function SP(e,t,n,r){let i=t+1>n+20?t-n-1:0,a=e.slice(i,t);return a.push(r),a}function CP(e,t){let n=[],r=!1;return e.iterChangedRanges((e,t)=>n.push(e,t)),t.iterChangedRanges((e,t,i,a)=>{for(let e=0;e<n.length;){let t=n[e++],o=n[e++];a>=t&&i<=o&&(r=!0)}}),r}function wP(e,t){return e.ranges.length==t.ranges.length&&e.ranges.filter((e,n)=>e.empty!=t.ranges[n].empty).length===0}function TP(e,t){return e.length?t.length?e.concat(t):e:t}var EP=[],DP=200;function OP(e,t){if(e.length){let n=e[e.length-1],r=n.selectionsAfter.slice(Math.max(0,n.selectionsAfter.length-DP));return r.length&&r[r.length-1].eq(t)?e:(r.push(t),SP(e,e.length-1,1e9,n.setSelAfter(r)))}return[xP.selection([t])]}function kP(e){let t=e[e.length-1],n=e.slice();return n[e.length-1]=t.setSelAfter(t.selectionsAfter.slice(0,t.selectionsAfter.length-1)),n}function AP(e,t){if(!e.length)return e;let n=e.length,r=EP;for(;n;){let i=jP(e[n-1],t,r);if(i.changes&&!i.changes.empty||i.effects.length){let t=e.slice(0,n);return t[n-1]=i,t}t=i.mapped,n--,r=i.selectionsAfter}return r.length?[xP.selection(r)]:EP}function jP(e,t,n){let r=TP(e.selectionsAfter.length?e.selectionsAfter.map(e=>e.map(t)):EP,n);if(!e.changes)return xP.selection(r);let i=e.changes.map(t),a=t.mapDesc(e.changes,!0),o=e.mapped?e.mapped.composeDesc(a):a;return new xP(i,Pw.mapEffects(e.effects,t),o,e.startSelection.map(a),r)}var MP=/^(input\.type|delete)($|\.)/,NP=class e{constructor(e,t,n=0,r=void 0){this.done=e,this.undone=t,this.prevTime=n,this.prevUserEvent=r}isolate(){return this.prevTime?new e(this.done,this.undone):this}addChanges(t,n,r,i,a){let o=this.done,s=o[o.length-1];return o=s&&s.changes&&!s.changes.empty&&t.changes&&(!r||MP.test(r))&&(!s.selectionsAfter.length&&n-this.prevTime<i.newGroupDelay&&i.joinToEvent(a,CP(s.changes,t.changes))||r==`input.type.compose`)?SP(o,o.length-1,i.minDepth,new xP(t.changes.compose(s.changes),TP(Pw.mapEffects(t.effects,s.changes),s.effects),s.mapped,s.startSelection,EP)):SP(o,o.length,i.minDepth,t),new e(o,EP,n,r)}addSelection(t,n,r,i){let a=this.done.length?this.done[this.done.length-1].selectionsAfter:EP;return a.length>0&&n-this.prevTime<i&&r==this.prevUserEvent&&r&&/^select($|\.)/.test(r)&&wP(a[a.length-1],t)?this:new e(OP(this.done,t),this.undone,n,r)}addMapping(t){return new e(AP(this.done,t),AP(this.undone,t),this.prevTime,this.prevUserEvent)}pop(e,t,n){let r=e==0?this.done:this.undone;if(r.length==0)return null;let i=r[r.length-1],a=i.selectionsAfter[0]||(i.startSelection?i.startSelection.map(i.changes.invertedDesc,1):t.selection);if(n&&i.selectionsAfter.length)return t.update({selection:i.selectionsAfter[i.selectionsAfter.length-1],annotations:uP.of({side:e,rest:kP(r),selection:a}),userEvent:e==0?`select.undo`:`select.redo`,scrollIntoView:!0});if(i.changes){let n=r.length==1?EP:r.slice(0,r.length-1);return i.mapped&&(n=AP(n,i.mapped)),t.update({changes:i.changes,selection:i.startSelection,effects:i.effects,annotations:uP.of({side:e,rest:n,selection:a}),filter:!1,userEvent:e==0?`undo`:`redo`,scrollIntoView:!0})}return null}};NP.empty=new NP(EP,EP);var PP=[{key:`Mod-z`,run:_P,preventDefault:!0},{key:`Mod-y`,mac:`Mod-Shift-z`,run:vP,preventDefault:!0},{linux:`Ctrl-Shift-z`,run:vP,preventDefault:!0},{key:`Mod-u`,run:yP,preventDefault:!0},{key:`Alt-u`,mac:`Mod-Shift-u`,run:bP,preventDefault:!0}];function FP(e,t){return K.create(e.ranges.map(t),e.mainIndex)}function IP(e,t){return e.update({selection:t,scrollIntoView:!0,userEvent:`select`})}function LP({state:e,dispatch:t},n){let r=FP(e.selection,n);return!r.eq(e.selection,!0)&&(t(IP(e,r)),!0)}function RP(e,t){return K.cursor(t?e.to:e.from)}function zP(e,t){return LP(e,n=>n.empty?e.moveByChar(n,t):RP(n,t))}function BP(e){return e.textDirectionAt(e.state.selection.main.head)==FE.LTR}var VP=e=>zP(e,!BP(e)),HP=e=>zP(e,BP(e));function UP(e,t){return LP(e,n=>n.empty?e.moveByGroup(n,t):RP(n,t))}var WP=e=>UP(e,!BP(e)),GP=e=>UP(e,BP(e));typeof Intl<`u`&&Intl.Segmenter;function KP(e,t,n){if(t.type.prop(n))return!0;let r=t.to-t.from;return r&&(r>2||/[^\s,.;:]/.test(e.sliceDoc(t.from,t.to)))||t.firstChild}function qP(e,t,n){let r=vM(e).resolveInner(t.head),i=n?sj.closedBy:sj.openedBy;for(let a=t.head;;){let t=n?r.childAfter(a):r.childBefore(a);if(!t)break;KP(e,t,i)?r=t:a=n?t.to:t.from}let a=r.type.prop(i),o,s;return s=a&&(o=n?UN(e,r.from,1):UN(e,r.to,-1))&&o.matched?n?o.end.to:o.end.from:n?r.to:r.from,K.cursor(s,n?-1:1)}var JP=e=>LP(e,t=>qP(e.state,t,!BP(e))),YP=e=>LP(e,t=>qP(e.state,t,BP(e)));function XP(e,t){return LP(e,n=>{if(!n.empty)return RP(n,t);let r=e.moveVertically(n,t);return r.head==n.head?e.moveToLineBoundary(n,t):r})}var ZP=e=>XP(e,!1),QP=e=>XP(e,!0);function $P(e){let t=e.scrollDOM.clientHeight<e.scrollDOM.scrollHeight-2,n=0,r=0,i;if(t){for(let t of e.state.facet(qk.scrollMargins)){let i=t(e);i?.top&&(n=Math.max(i?.top,n)),i?.bottom&&(r=Math.max(i?.bottom,r))}i=e.scrollDOM.clientHeight-n-r}else i=(e.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:n,marginBottom:r,selfScroll:t,height:Math.max(e.defaultLineHeight,i-5)}}function eF(e,t){let n=$P(e),{state:r}=e,i=FP(r.selection,r=>r.empty?e.moveVertically(r,t,n.height):RP(r,t));if(i.eq(r.selection))return!1;let a;if(n.selfScroll){let t=e.coordsAtPos(r.selection.main.head),o=e.scrollDOM.getBoundingClientRect(),s=o.top+n.marginTop,c=o.bottom-n.marginBottom;t&&t.top>s&&t.bottom<c&&(a=qk.scrollIntoView(i.main.head,{y:`start`,yMargin:t.top-s}))}return e.dispatch(IP(r,i),{effects:a}),!0}var tF=e=>eF(e,!1),nF=e=>eF(e,!0);function rF(e,t,n){let r=e.lineBlockAt(t.head),i=e.moveToLineBoundary(t,n);if(i.head==t.head&&i.head!=(n?r.to:r.from)&&(i=e.moveToLineBoundary(t,n,!1)),!n&&i.head==r.from&&r.length){let n=/^\s*/.exec(e.state.sliceDoc(r.from,Math.min(r.from+100,r.to)))[0].length;n&&t.head!=r.from+n&&(i=K.cursor(r.from+n))}return i}var iF=e=>LP(e,t=>rF(e,t,!0)),aF=e=>LP(e,t=>rF(e,t,!1)),oF=e=>LP(e,t=>rF(e,t,!BP(e))),sF=e=>LP(e,t=>rF(e,t,BP(e))),cF=e=>LP(e,t=>e.moveToLineBoundary(t,!1,!1)),lF=e=>LP(e,t=>e.moveToLineBoundary(t,!0,!1));function uF(e,t,n){let r=!1,i=FP(e.selection,t=>{let i=UN(e,t.head,-1)||UN(e,t.head,1)||t.head>0&&UN(e,t.head-1,1)||t.head<e.doc.length&&UN(e,t.head+1,-1);if(!i||!i.end)return t;r=!0;let a=i.start.from==t.head?i.end.to:i.end.from;return n?K.range(t.anchor,a):K.cursor(a)});return r?(t(IP(e,i)),!0):!1}var dF=({state:e,dispatch:t})=>uF(e,t,!1);function fF(e,t,n){let r=FP(e.state.selection,e=>{e.undirectional&&e.head>=e.anchor!=t&&(e=K.range(e.head,e.anchor));let r=n(e);return K.range(e.anchor,r.head,r.goalColumn,r.bidiLevel||void 0,r.assoc)});return!r.eq(e.state.selection)&&(e.dispatch(IP(e.state,r)),!0)}function pF(e,t){return fF(e,t,n=>e.moveByChar(n,t))}var mF=e=>pF(e,!BP(e)),hF=e=>pF(e,BP(e));function gF(e,t){return fF(e,t,n=>e.moveByGroup(n,t))}var _F=e=>gF(e,!BP(e)),vF=e=>gF(e,BP(e)),yF=e=>{let t=!BP(e);return fF(e,t,n=>qP(e.state,n,t))},bF=e=>{let t=BP(e);return fF(e,t,n=>qP(e.state,n,t))};function xF(e,t){return fF(e,t,n=>e.moveVertically(n,t))}var SF=e=>xF(e,!1),CF=e=>xF(e,!0);function wF(e,t){return fF(e,t,n=>e.moveVertically(n,t,$P(e).height))}var TF=e=>wF(e,!1),EF=e=>wF(e,!0),DF=e=>fF(e,!0,t=>rF(e,t,!0)),OF=e=>fF(e,!1,t=>rF(e,t,!1)),kF=e=>{let t=!BP(e);return fF(e,t,n=>rF(e,n,t))},AF=e=>{let t=BP(e);return fF(e,t,n=>rF(e,n,t))},jF=e=>fF(e,!1,t=>K.cursor(e.lineBlockAt(t.head).from)),MF=e=>fF(e,!0,t=>K.cursor(e.lineBlockAt(t.head).to)),NF=({state:e,dispatch:t})=>(t(IP(e,{anchor:0})),!0),PF=({state:e,dispatch:t})=>(t(IP(e,{anchor:e.doc.length})),!0),FF=({state:e,dispatch:t})=>(t(IP(e,{anchor:e.selection.main.anchor,head:0})),!0),IF=({state:e,dispatch:t})=>(t(IP(e,{anchor:e.selection.main.anchor,head:e.doc.length})),!0),LF=({state:e,dispatch:t})=>(t(e.update({selection:{anchor:0,head:e.doc.length},userEvent:`select`})),!0),RF=({state:e,dispatch:t})=>{let n=rI(e).map(({from:t,to:n})=>K.undirectionalRange(t,Math.min(n+1,e.doc.length)));return t(e.update({selection:K.create(n),userEvent:`select`})),!0},zF=({state:e,dispatch:t})=>{let n=FP(e.selection,t=>{let n=vM(e),r=n.resolveStack(t.from,1);if(t.empty){let e=n.resolveStack(t.from,-1);e.node.from>=r.node.from&&e.node.to<=r.node.to&&(r=e)}for(let e=r;e;e=e.next){let{node:n}=e;if((n.from<t.from&&n.to>=t.to||n.to>t.to&&n.from<=t.from)&&e.next)return K.undirectionalRange(n.from,n.to)}return t});return!n.eq(e.selection)&&(t(IP(e,n)),!0)};function BF(e,t){let{state:n}=e,r=n.selection,i=n.selection.ranges.slice();for(let r of n.selection.ranges){let a=n.doc.lineAt(r.head);if(t?a.to<e.state.doc.length:a.from>0)for(let n=r;;){let r=e.moveVertically(n,t);if(r.head<a.from||r.head>a.to){i.some(e=>e.head==r.head)||i.push(r);break}if(r.head==n.head)break;n=r}}return i.length!=r.ranges.length&&(e.dispatch(IP(n,K.create(i,i.length-1))),!0)}var VF=e=>BF(e,!1),HF=e=>BF(e,!0),UF=({state:e,dispatch:t})=>{let n=e.selection,r=null;return n.ranges.length>1?r=K.create([n.main]):n.main.empty||(r=K.create([K.cursor(n.main.head)])),r?(t(IP(e,r)),!0):!1};function WF(e,t){if(e.state.readOnly)return!1;let n=`delete.selection`,{state:r}=e,i=r.changeByRange(r=>{let{from:i,to:a}=r;if(i==a){let o=t(r);o<i?(n=`delete.backward`,o=GF(e,o,!1)):o>i&&(n=`delete.forward`,o=GF(e,o,!0)),i=Math.min(i,o),a=Math.max(a,o)}else i=GF(e,i,!1),a=GF(e,a,!0);return i==a?{range:r}:{changes:{from:i,to:a},range:K.cursor(i,i<r.head?-1:1)}});return!i.changes.empty&&(e.dispatch(r.update(i,{scrollIntoView:!0,userEvent:n,effects:n==`delete.selection`?qk.announce.of(r.phrase(`Selection deleted`)):void 0})),!0)}function GF(e,t,n){if(e instanceof qk)for(let r of e.state.facet(qk.atomicRanges).map(t=>t(e)))r.between(t,t,(e,r)=>{e<t&&r>t&&(t=n?r:e)});return t}var KF=(e,t,n)=>WF(e,r=>{let i=r.from,{state:a}=e,o=a.doc.lineAt(i),s,c;if(n&&!t&&i>o.from&&i<o.from+200&&!/[^ \t]/.test(s=o.text.slice(0,i-o.from))){if(s[s.length-1]==` `)return i-1;let e=gT(s,a.tabSize)%jM(a)||jM(a);for(let t=0;t<e&&s[s.length-1-t]==` `;t++)i--;c=i}else c=KC(o.text,i-o.from,t,t)+o.from,c==i&&o.number!=(t?a.doc.lines:1)?c+=t?1:-1:!t&&/[\ufe00-\ufe0f]/.test(o.text.slice(c-o.from,i-o.from))&&(c=KC(o.text,c-o.from,!1,!1)+o.from);return c}),qF=e=>KF(e,!1,!0),JF=e=>KF(e,!0,!1),YF=(e,t)=>WF(e,n=>{let r=n.head,{state:i}=e,a=i.doc.lineAt(r),o=i.charCategorizer(r);for(let e=null;;){if(r==(t?a.to:a.from)){r==n.head&&a.number!=(t?i.doc.lines:1)&&(r+=t?1:-1);break}let s=KC(a.text,r-a.from,t)+a.from,c=a.text.slice(Math.min(r,s)-a.from,Math.max(r,s)-a.from),l=o(c);if(e!=null&&l!=e)break;(c!=` `||r!=n.head)&&(e=l),r=s}return r}),XF=e=>YF(e,!1),ZF=e=>YF(e,!0),QF=e=>WF(e,t=>{let n=e.lineBlockAt(t.head).to;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)}),$F=e=>WF(e,t=>{let n=e.moveToLineBoundary(t,!1).head;return t.head>n?n:Math.max(0,t.head-1)}),eI=e=>WF(e,t=>{let n=e.moveToLineBoundary(t,!0).head;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)}),tI=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(e=>({changes:{from:e.from,to:e.to,insert:LC.of([``,``])},range:K.cursor(e.from)}));return t(e.update(n,{scrollIntoView:!0,userEvent:`input`})),!0},nI=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(t=>{if(!t.empty||t.from==0||t.from==e.doc.length)return{range:t};let n=t.from,r=e.doc.lineAt(n),i=n==r.from?n-1:KC(r.text,n-r.from,!1)+r.from,a=n==r.to?n+1:KC(r.text,n-r.from,!0)+r.from;return{changes:{from:i,to:a,insert:e.doc.slice(n,a).append(e.doc.slice(i,n))},range:K.cursor(a)}});return!n.changes.empty&&(t(e.update(n,{scrollIntoView:!0,userEvent:`move.character`})),!0)};function rI(e){let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.from),a=e.doc.lineAt(r.to);if(!r.empty&&r.to==a.from&&(a=e.doc.lineAt(r.to-1)),n>=i.number){let e=t[t.length-1];e.to=a.to,e.ranges.push(r)}else t.push({from:i.from,to:a.to,ranges:[r]});n=a.number+1}return t}function iI(e,t,n){if(e.readOnly)return!1;let r=[],i=[];for(let t of rI(e)){if(n?t.to==e.doc.length:t.from==0)continue;let a=e.doc.lineAt(n?t.to+1:t.from-1),o=a.length+1;if(n){r.push({from:t.to,to:a.to},{from:t.from,insert:a.text+e.lineBreak});for(let n of t.ranges)i.push(K.range(Math.min(e.doc.length,n.anchor+o),Math.min(e.doc.length,n.head+o)))}else{r.push({from:a.from,to:t.from},{from:t.to,insert:e.lineBreak+a.text});for(let e of t.ranges)i.push(K.range(e.anchor-o,e.head-o))}}return r.length?(t(e.update({changes:r,scrollIntoView:!0,selection:K.create(i,e.selection.mainIndex),userEvent:`move.line`})),!0):!1}var aI=({state:e,dispatch:t})=>iI(e,t,!1),oI=({state:e,dispatch:t})=>iI(e,t,!0);function sI(e,t,n){if(e.readOnly)return!1;let r=[];for(let t of rI(e))n?r.push({from:t.from,insert:e.doc.slice(t.from,t.to)+e.lineBreak}):r.push({from:t.to,insert:e.lineBreak+e.doc.slice(t.from,t.to)});let i=e.changes(r);return t(e.update({changes:i,selection:e.selection.map(i,n?1:-1),scrollIntoView:!0,userEvent:`input.copyline`})),!0}var cI=({state:e,dispatch:t})=>sI(e,t,!1),lI=({state:e,dispatch:t})=>sI(e,t,!0),uI=e=>{if(e.state.readOnly)return!1;let{state:t}=e,n=t.changes(rI(t).map(({from:e,to:n})=>(e>0?e--:n<t.doc.length&&n++,{from:e,to:n}))),r=FP(t.selection,t=>{let n;if(e.lineWrapping){let r=e.lineBlockAt(t.head),i=e.coordsAtPos(t.head,t.assoc||1);i&&(n=r.bottom+e.documentTop-i.bottom+e.defaultLineHeight/2)}return e.moveVertically(t,!0,n)}).map(n);return e.dispatch({changes:n,selection:r,scrollIntoView:!0,userEvent:`delete.line`}),!0};function dI(e,t){if(/\(\)|\[\]|\{\}/.test(e.sliceDoc(t-1,t+1)))return{from:t,to:t};let n=vM(e).resolveInner(t),r=n.childBefore(t),i=n.childAfter(t),a;return r&&i&&r.to<=t&&i.from>=t&&(a=r.type.prop(sj.closedBy))&&a.indexOf(i.name)>-1&&e.doc.lineAt(r.to).from==e.doc.lineAt(i.from).from&&!/\S/.test(e.sliceDoc(r.to,i.from))?{from:r.to,to:i.from}:null}var fI=mI(!1),pI=mI(!0);function mI(e){return({state:t,dispatch:n})=>{if(t.readOnly)return!1;let r=t.changeByRange(n=>{let{from:r,to:i}=n,a=t.doc.lineAt(r),o=!e&&r==i&&dI(t,r);e&&(r=i=(i<=a.to?a:t.doc.lineAt(i)).to);let s=new PM(t,{simulateBreak:r,simulateDoubleBreak:!!o}),c=NM(s,r);for(c??=gT(/^\s*/.exec(t.doc.lineAt(r).text)[0],t.tabSize);i<a.to&&/\s/.test(a.text[i-a.from]);)i++;o?{from:r,to:i}=o:r>a.from&&r<a.from+100&&!/\S/.test(a.text.slice(0,r))&&(r=a.from);let l=[``,MM(t,c)];return o&&l.push(MM(t,s.lineIndent(a.from,-1))),{changes:{from:r,to:i,insert:LC.of(l)},range:K.cursor(r+1+l[1].length)}});return n(t.update(r,{scrollIntoView:!0,userEvent:`input`})),!0}}function hI(e,t){let n=-1;return e.changeByRange(r=>{let i=[];for(let a=r.from;a<=r.to;){let o=e.doc.lineAt(a);o.number>n&&(r.empty||r.to>o.from)&&(t(o,i,r),n=o.number),a=o.to+1}let a=e.changes(i);return{changes:i,range:K.range(a.mapPos(r.anchor,1),a.mapPos(r.head,1))}})}var gI=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=Object.create(null),r=new PM(e,{overrideIndentation:e=>n[e]??-1}),i=hI(e,(t,i,a)=>{let o=NM(r,t.from);if(o==null)return;/\S/.test(t.text)||(o=0);let s=/^\s*/.exec(t.text)[0],c=MM(e,o);(s!=c||a.from<t.from+s.length)&&(n[t.from]=o,i.push({from:t.from,to:t.from+s.length,insert:c}))});return i.changes.empty||t(e.update(i,{userEvent:`indent`})),!0},_I=({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(hI(e,(t,n)=>{n.push({from:t.from,insert:e.facet(AM)})}),{userEvent:`input.indent`})),!0),vI=({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(hI(e,(t,n)=>{let r=/^\s*/.exec(t.text)[0];if(!r)return;let i=gT(r,e.tabSize),a=0,o=MM(e,Math.max(0,i-jM(e)));for(;a<r.length&&a<o.length&&r.charCodeAt(a)==o.charCodeAt(a);)a++;n.push({from:t.from+a,to:t.from+r.length,insert:o.slice(a)})}),{userEvent:`delete.dedent`})),!0),yI=e=>(e.setTabFocusMode(),!0),bI=[{key:`Ctrl-b`,run:VP,shift:mF,preventDefault:!0},{key:`Ctrl-f`,run:HP,shift:hF},{key:`Ctrl-p`,run:ZP,shift:SF},{key:`Ctrl-n`,run:QP,shift:CF},{key:`Ctrl-a`,run:cF,shift:jF},{key:`Ctrl-e`,run:lF,shift:MF},{key:`Ctrl-d`,run:JF},{key:`Ctrl-h`,run:qF},{key:`Ctrl-k`,run:QF},{key:`Ctrl-Alt-h`,run:XF},{key:`Ctrl-o`,run:tI},{key:`Ctrl-t`,run:nI},{key:`Ctrl-v`,run:nF}],xI=[{key:`ArrowLeft`,run:VP,shift:mF,preventDefault:!0},{key:`Mod-ArrowLeft`,mac:`Alt-ArrowLeft`,run:WP,shift:_F,preventDefault:!0},{mac:`Cmd-ArrowLeft`,run:oF,shift:kF,preventDefault:!0},{key:`ArrowRight`,run:HP,shift:hF,preventDefault:!0},{key:`Mod-ArrowRight`,mac:`Alt-ArrowRight`,run:GP,shift:vF,preventDefault:!0},{mac:`Cmd-ArrowRight`,run:sF,shift:AF,preventDefault:!0},{key:`ArrowUp`,run:ZP,shift:SF,preventDefault:!0},{mac:`Cmd-ArrowUp`,run:NF,shift:FF},{mac:`Ctrl-ArrowUp`,run:tF,shift:TF},{key:`ArrowDown`,run:QP,shift:CF,preventDefault:!0},{mac:`Cmd-ArrowDown`,run:PF,shift:IF},{mac:`Ctrl-ArrowDown`,run:nF,shift:EF},{key:`PageUp`,run:tF,shift:TF},{key:`PageDown`,run:nF,shift:EF},{key:`Home`,run:aF,shift:OF,preventDefault:!0},{key:`Mod-Home`,run:NF,shift:FF},{key:`End`,run:iF,shift:DF,preventDefault:!0},{key:`Mod-End`,run:PF,shift:IF},{key:`Enter`,run:fI,shift:fI},{key:`Mod-a`,run:LF},{key:`Backspace`,run:qF,shift:qF,preventDefault:!0},{key:`Delete`,run:JF,preventDefault:!0},{key:`Mod-Backspace`,mac:`Alt-Backspace`,run:XF,preventDefault:!0},{key:`Mod-Delete`,mac:`Alt-Delete`,run:ZF,preventDefault:!0},{mac:`Mod-Backspace`,run:$F,preventDefault:!0},{mac:`Mod-Delete`,run:eI,preventDefault:!0}].concat(bI.map(e=>({mac:e.key,run:e.run,shift:e.shift}))),SI=[{key:`Alt-ArrowLeft`,mac:`Ctrl-ArrowLeft`,run:JP,shift:yF},{key:`Alt-ArrowRight`,mac:`Ctrl-ArrowRight`,run:YP,shift:bF},{key:`Alt-ArrowUp`,run:aI},{key:`Shift-Alt-ArrowUp`,run:cI},{key:`Alt-ArrowDown`,run:oI},{key:`Shift-Alt-ArrowDown`,run:lI},{key:`Mod-Alt-ArrowUp`,run:VF},{key:`Mod-Alt-ArrowDown`,run:HF},{key:`Escape`,run:UF},{key:`Mod-Enter`,run:pI},{key:`Alt-l`,mac:`Ctrl-l`,run:RF},{key:`Mod-i`,run:zF,preventDefault:!0},{key:`Mod-[`,run:vI},{key:`Mod-]`,run:_I},{key:`Mod-Alt-\\`,run:gI},{key:`Shift-Mod-k`,run:uI},{key:`Shift-Mod-\\`,run:dF},{key:`Mod-/`,run:$N},{key:`Alt-A`,mac:`Ctrl-A`,run:nP},{key:`Ctrl-m`,mac:`Shift-Alt-m`,run:yI}].concat(xI),CI={key:`Tab`,run:_I,shift:vI},wI=class e{constructor(e,t,n,r,i,a,o,s,c,l=0,u){this.p=e,this.stack=t,this.state=n,this.reducePos=r,this.pos=i,this.score=a,this.buffer=o,this.bufferBase=s,this.curContext=c,this.lookAhead=l,this.parent=u}toString(){return`[${this.stack.filter((e,t)=>t%3==0).concat(this.state)}]@${this.pos}${this.score?`!`+this.score:``}`}static start(t,n,r=0){let i=t.parser.context;return new e(t,[],n,r,r,0,[],0,i?new TI(i,i.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,t){this.stack.push(this.state,t,this.bufferBase+this.buffer.length),this.state=e}reduce(e){let t=e>>19,n=e&65535,{parser:r}=this.p,i=this.reducePos<this.pos-25&&this.setLookAhead(this.pos),a=r.dynamicPrecedence(n);if(a&&(this.score+=a),t==0){n<r.minRepeatTerm&&this.reducePos<this.pos&&(this.reducePos=this.pos),this.pushState(r.getGoto(this.state,n,!0),this.reducePos),n<r.minRepeatTerm&&this.storeNode(n,this.reducePos,this.reducePos,i?8:4,!0),this.reduceContext(n,this.reducePos);return}let o=this.stack.length-(t-1)*3-(e&262144?6:0),s=o?this.stack[o-2]:this.p.ranges[0].from;n<r.minRepeatTerm&&s==this.reducePos&&this.reducePos<this.pos&&(this.reducePos=this.pos);let c=this.reducePos-s;c>=2e3&&!this.p.parser.nodeSet.types[n]?.isAnonymous&&(s==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=c):this.p.lastBigReductionSize<c&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=s,this.p.lastBigReductionSize=c));let l=o?this.stack[o-1]:0,u=this.bufferBase+this.buffer.length-l;if(n<r.minRepeatTerm||e&131072){let e=r.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(n,s,e,u+4,!0)}if(e&262144)this.state=this.stack[o];else{let e=this.stack[o-3];this.state=r.getGoto(e,n,!0)}for(;this.stack.length>o;)this.stack.pop();this.reduceContext(n,s)}storeNode(e,t,n,r=4,i=!1){if(e==0&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let e=this.buffer.length;if(e>0&&this.buffer[e-4]==0&&this.buffer[e-1]>-1){if(t==n)return;if(this.buffer[e-2]>=t){this.buffer[e-2]=n;return}}}if(!i||this.pos==n)this.buffer.push(e,t,n,r);else{let i=this.buffer.length;if(i>0&&(this.buffer[i-4]!=0||this.buffer[i-1]<0)){let e=!1;for(let t=i;t>0&&this.buffer[t-2]>n;t-=4)if(this.buffer[t-1]>=0){e=!0;break}if(e)for(;i>0&&this.buffer[i-2]>n;)this.buffer[i]=this.buffer[i-4],this.buffer[i+1]=this.buffer[i-3],this.buffer[i+2]=this.buffer[i-2],this.buffer[i+3]=this.buffer[i-1],i-=4,r>4&&(r-=4)}this.buffer[i]=e,this.buffer[i+1]=t,this.buffer[i+2]=n,this.buffer[i+3]=r}}shift(e,t,n,r){if(e&131072)this.pushState(e&65535,this.pos);else if(e&262144)this.pos=r,this.shiftContext(t,n),t<=this.p.parser.maxNode&&this.buffer.push(t,n,r,4);else{let i=e,{parser:a}=this.p;this.pos=r;let o=a.stateFlag(i,1);!o&&(r>n||t<=a.maxNode)&&(this.reducePos=r),this.pushState(i,o?n:Math.min(n,this.reducePos)),this.shiftContext(t,n),t<=a.maxNode&&this.buffer.push(t,n,r,4)}}apply(e,t,n,r){e&65536?this.reduce(e):this.shift(e,t,n,r)}useNode(e,t,n){let r=this.p.reused.length-1;(r<0||this.p.reused[r]!=e)&&(this.p.reused.push(e),r++);let i=this.reducePos=this.pos=n+e.length;this.pushState(t,n),this.buffer.push(r,n,i,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let t=this,n=t.buffer.length;for(n&&t.buffer[n-4]==0&&(n-=4);n>0&&t.buffer[n-2]>t.reducePos;)n-=4;let r=t.buffer.slice(n),i=t.bufferBase+n;for(;t&&i==t.bufferBase;)t=t.parent;return new e(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,r,i,this.curContext,this.lookAhead,t)}recoverByDelete(e,t){let n=e<=this.p.parser.maxNode;n&&this.storeNode(e,this.pos,t,4),this.storeNode(0,this.pos,t,n?8:4),this.pos=this.reducePos=t,this.score-=190}canShift(e){for(let t=new EI(this);;){let n=this.p.parser.stateSlot(t.state,4)||this.p.parser.hasAction(t.state,e);if(n==0)return!1;if(!(n&65536))return!0;t.reduce(n)}}recoverByInsert(e){if(this.stack.length>=300)return[];let t=this.p.parser.nextStates(this.state);if(t.length>8||this.stack.length>=120){let n=[];for(let r=0,i;r<t.length;r+=2)(i=t[r+1])!=this.state&&this.p.parser.hasAction(i,e)&&n.push(t[r],i);if(this.stack.length<120)for(let e=0;n.length<8&&e<t.length;e+=2){let r=t[e+1];n.some((e,t)=>t&1&&e==r)||n.push(t[e],r)}t=n}let n=[];for(let e=0;e<t.length&&n.length<4;e+=2){let r=t[e+1];if(r==this.state)continue;let i=this.split();i.pushState(r,this.pos),i.storeNode(0,i.pos,i.pos,4,!0),i.shiftContext(t[e],this.pos),i.reducePos=this.pos,i.score-=200,n.push(i)}return n}forceReduce(){let{parser:e}=this.p,t=e.stateSlot(this.state,5);if(!(t&65536))return!1;if(!e.validAction(this.state,t)){let n=t>>19,r=t&65535,i=this.stack.length-n*3;if(i<0||e.getGoto(this.stack[i],r,!1)<0){let e=this.findForcedReduction();if(e==null)return!1;t=e}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(t),!0}findForcedReduction(){let{parser:e}=this.p,t=[],n=(r,i)=>{if(!t.includes(r))return t.push(r),e.allActions(r,t=>{if(!(t&393216)){if(t&65536){let n=(t>>19)-i;if(n>1){let r=t&65535,i=this.stack.length-n*3;if(i>=0&&e.getGoto(this.stack[i],r,!1)>=0)return n<<19|65536|r}}else{let e=n(t,i+1);if(e!=null)return e}}})};return n(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(this.stack.length!=3)return!1;let{parser:e}=this.p;return e.data[e.stateSlot(this.state,1)]==65535&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let t=0;t<this.stack.length;t+=3)if(this.stack[t]!=e.stack[t])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(t)))}reduceContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(t)))}emitContext(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-3)&&this.storeNode(this.curContext.hash,this.reducePos,this.reducePos,-3,!0)}emitLookAhead(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-4)&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let t=new TI(this.curContext.tracker,e);t.hash!=this.curContext.hash&&this.emitContext(),this.curContext=t}}setLookAhead(e){return e<=this.lookAhead?!1:(this.emitLookAhead(),this.lookAhead=e,!0)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}},TI=class{constructor(e,t){this.tracker=e,this.context=t,this.hash=e.strict?e.hash(t):0}},EI=class{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let t=e&65535,n=e>>19;n==0?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(n-1)*3;let r=this.start.p.parser.getGoto(this.stack[this.base-3],t,!0);this.state=r}},DI=class e{constructor(e,t,n){this.stack=e,this.pos=t,this.index=n,this.buffer=e.buffer,this.index==0&&this.maybeNext()}static create(t,n=t.bufferBase+t.buffer.length){return new e(t,n,n-t.bufferBase)}maybeNext(){let e=this.stack.parent;e!=null&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,this.index==0&&this.maybeNext()}fork(){return new e(this.stack,this.pos,this.index)}};function OI(e,t=Uint16Array){if(typeof e!=`string`)return e;let n=null;for(let r=0,i=0;r<e.length;){let a=0;for(;;){let t=e.charCodeAt(r++),n=!1;if(t==126){a=65535;break}t>=92&&t--,t>=34&&t--;let i=t-32;if(i>=46&&(i-=46,n=!0),a+=i,n)break;a*=46}n?n[i++]=a:n=new t(a)}return n}var kI=class{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}},AI=new kI,jI=class{constructor(e,t){this.input=e,this.ranges=t,this.chunk=``,this.chunkOff=0,this.chunk2=``,this.chunk2Pos=0,this.next=-1,this.token=AI,this.rangeIndex=0,this.pos=this.chunkPos=t[0].from,this.range=t[0],this.end=t[t.length-1].to,this.readNext()}resolveOffset(e,t){let n=this.range,r=this.rangeIndex,i=this.pos+e;for(;i<n.from;){if(!r)return null;let e=this.ranges[--r];i-=n.from-e.to,n=e}for(;t<0?i>n.to:i>=n.to;){if(r==this.ranges.length-1)return null;let e=this.ranges[++r];i+=e.from-n.to,n=e}return i}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let t of this.ranges)if(t.to>e)return Math.max(e,t.from);return this.end}peek(e){let t=this.chunkOff+e,n,r;if(t>=0&&t<this.chunk.length)n=this.pos+e,r=this.chunk.charCodeAt(t);else{let t=this.resolveOffset(e,1);if(t==null)return-1;if(n=t,n>=this.chunk2Pos&&n<this.chunk2Pos+this.chunk2.length)r=this.chunk2.charCodeAt(n-this.chunk2Pos);else{let e=this.rangeIndex,t=this.range;for(;t.to<=n;)t=this.ranges[++e];this.chunk2=this.input.chunk(this.chunk2Pos=n),n+this.chunk2.length>t.to&&(this.chunk2=this.chunk2.slice(0,t.to-n)),r=this.chunk2.charCodeAt(0)}}return n>=this.token.lookAhead&&(this.token.lookAhead=n+1),r}acceptToken(e,t=0){let n=t?this.resolveOffset(t,-1):this.pos;if(n==null||n<this.token.start)throw RangeError(`Token end out of bounds`);this.token.value=e,this.token.end=n}acceptTokenTo(e,t){this.token.value=e,this.token.end=t}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:t}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=t,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),t=this.pos+e.length;this.chunk=t>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.next=this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?-1:this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk=``,this.next=-1}reset(e,t){if(t?(this.token=t,t.start=e,t.lookAhead=e+1,t.value=t.extended=-1):this.token=AI,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e<this.range.from;)this.range=this.ranges[--this.rangeIndex];for(;e>=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk=``,this.chunkOff=0),this.readNext()}return this}read(e,t){if(e>=this.chunkPos&&t<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,t-this.chunkPos);if(e>=this.chunk2Pos&&t<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,t-this.chunk2Pos);if(e>=this.range.from&&t<=this.range.to)return this.input.read(e,t);let n=``;for(let r of this.ranges){if(r.from>=t)break;r.to>e&&(n+=this.input.read(Math.max(r.from,e),Math.min(r.to,t)))}return n}},MI=class{constructor(e,t){this.data=e,this.id=t}token(e,t){let{parser:n}=t.p;PI(this.data,e,t,this.id,n.data,n.tokenPrecTable)}};MI.prototype.contextual=MI.prototype.fallback=MI.prototype.extend=!1;var NI=class{constructor(e,t,n){this.precTable=t,this.elseToken=n,this.data=typeof e==`string`?OI(e):e}token(e,t){let n=e.pos,r=0;for(;;){let n=e.next<0,i=e.resolveOffset(1,1);if(PI(this.data,e,t,0,this.data,this.precTable),e.token.value>-1)break;if(this.elseToken==null)return;if(n||r++,i==null)break;e.reset(i,e.token)}r&&(e.reset(n,e.token),e.acceptToken(this.elseToken,r))}};NI.prototype.contextual=MI.prototype.fallback=MI.prototype.extend=!1;function PI(e,t,n,r,i,a){let o=0,s=1<<r,{dialect:c}=n.p.parser;scan:for(;(s&e[o])!=0;){let n=e[o+1];for(let r=o+3;r<n;r+=2)if((e[r+1]&s)>0){let n=e[r];if(c.allows(n)&&(t.token.value==-1||t.token.value==n||II(n,t.token.value,i,a))){t.acceptToken(n);break}}let r=t.next,l=0,u=e[o+2];if(t.next<0&&u>l&&e[n+u*3-3]==65535){o=e[n+u*3-1];continue scan}for(;l<u;){let i=l+u>>1,a=n+i+(i<<1),s=e[a],c=e[a+1]||65536;if(r<s)u=i;else if(r>=c)l=i+1;else{o=e[a+2],t.advance();continue scan}}break}}function FI(e,t,n){for(let r=t,i;(i=e[r])!=65535;r++)if(i==n)return r-t;return-1}function II(e,t,n,r){let i=FI(n,r,t);return i<0||FI(n,r,e)<i}var LI=typeof process<`u`&&/\bparse\b/.test({}.LOG),RI=null;function zI(e,t,n){let r=e.cursor(mj.IncludeAnonymous);for(r.moveTo(t);;)if(!(n<0?r.childBefore(t):r.childAfter(t)))for(;;){if((n<0?r.to<t:r.from>t)&&!r.type.isError)return n<0?Math.max(0,Math.min(r.to-1,t-25)):Math.min(e.length,Math.max(r.from+1,t+25));if(n<0?r.prevSibling():r.nextSibling())break;if(!r.parent())return n<0?0:e.length}}var BI=class{constructor(e,t){this.fragments=e,this.minRepeat=t,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.lastRepeat=null,this.lastRepeatPos=-1,this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?zI(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?zI(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;for(;this.fragment&&this.safeTo<=e;)this.nextFragment();if(!this.fragment)return null;for(;;){let t=this.trees.length-1;if(t<0)return this.nextFragment(),null;if(e<this.safeFrom)return null;let n=this.trees[t],r=this.index[t];if(r==n.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let i=n.children[r],a=this.start[t]+n.positions[r];if(a>e)return this.nextStart=a,null;if(i instanceof hj){let n=a>this.lastRepeatPos&&i.type.id>=this.minRepeat;if(a==e||n){let t=a+i.length,r;if(a>=this.safeFrom&&t<=this.safeTo&&(!(r=i.prop(sj.lookAhead))||t+r<this.fragment.to)&&(n&&(this.lastRepeat=i,this.lastRepeatPos=a),a==e))return i}this.index[t]++,a+i.length>=Math.max(this.safeFrom,e)&&(this.trees.push(i),this.start.push(a),this.index.push(0))}else this.index[t]++,this.nextStart=a+i.length}}},VI=class{constructor(e,t){this.stream=t,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(e=>new kI)}getActions(e){let t=0,n=null,{parser:r}=e.p,{tokenizers:i}=r,a=r.stateSlot(e.state,3),o=e.curContext?e.curContext.hash:0,s=0;for(let r=0;r<i.length;r++){if(!(1<<r&a))continue;let c=i[r],l=this.tokens[r];if((!n||c.fallback)&&((c.contextual||l.start!=e.pos||l.mask!=a||l.context!=o)&&(this.updateCachedToken(l,c,e),l.mask=a,l.context=o),l.lookAhead>l.end+25&&(s=Math.max(l.lookAhead,s)),l.value!=0)){let r=t;if(l.extended>-1&&(t=this.addActions(e,l.extended,l.end,t)),t=this.addActions(e,l.value,l.end,t),!c.extend&&(n=l,t>r))break}}for(;this.actions.length>t;)this.actions.pop();return s&&e.setLookAhead(s),!n&&e.pos==this.stream.end&&(n=new kI,n.value=e.p.parser.eofTerm,n.start=n.end=e.pos,t=this.addActions(e,n.value,n.end,t)),this.mainToken=n,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let t=new kI,{pos:n,p:r}=e;return t.start=n,t.end=Math.min(n+1,r.stream.end),t.value=n==r.stream.end?r.parser.eofTerm:0,t}updateCachedToken(e,t,n){let r=this.stream.clipPos(n.pos);if(t.token(this.stream.reset(r,e),n),e.value>-1){let{parser:t}=n.p;for(let r=0;r<t.specialized.length;r++)if(t.specialized[r]==e.value){let i=t.specializers[r](this.stream.read(e.start,e.end),n);if(i>=0&&n.p.parser.dialect.allows(i>>1)){i&1?e.extended=i>>1:e.value=i>>1;break}}}else e.value=0,e.end=this.stream.clipPos(r+1)}putAction(e,t,n,r){for(let t=0;t<r;t+=3)if(this.actions[t]==e)return r;return this.actions[r++]=e,this.actions[r++]=t,this.actions[r++]=n,r}addActions(e,t,n,r){let{state:i}=e,{parser:a}=e.p,{data:o}=a;for(let e=0;e<2;e++)for(let s=a.stateSlot(i,e?2:1);;s+=3){if(o[s]==65535){if(o[s+1]==1)s=KI(o,s+2);else{r==0&&o[s+1]==2&&(r=this.putAction(KI(o,s+2),t,n,r));break}}o[s]==t&&(r=this.putAction(KI(o,s+1),t,n,r))}return r}},HI=class{constructor(e,t,n,r){this.parser=e,this.input=t,this.ranges=r,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new jI(t,r),this.tokens=new VI(e,this.stream),this.topTerm=e.top[1];let{from:i}=r[0];this.stacks=[wI.start(this,e.top[0],i)],this.fragments=n.length&&this.stream.end-i>e.bufferLength*4?new BI(n,e.minRepeatTerm):null}get parsedPos(){return this.minStackPos}advance(){let e=this.stacks,t=this.minStackPos,n=this.stacks=[],r,i;if(this.bigReductionCount>300&&e.length==1){let[t]=e;for(;t.forceReduce()&&t.stack.length&&t.stack[t.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let a=0;a<e.length;a++){let o=e[a];for(;;){if(this.tokens.mainToken=null,o.pos>t)n.push(o);else if(this.advanceStack(o,n,e))continue;else{r||(r=[],i=[]),r.push(o);let e=this.tokens.getMainToken(o);i.push(e.value,e.end)}break}}if(!n.length){let e=r&&qI(r);if(e)return LI&&console.log(`Finish with `+this.stackID(e)),this.stackToTree(e);if(this.parser.strict)throw LI&&r&&console.log(`Stuck with token `+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):`none`)),SyntaxError(`No parse at `+t);this.recovering||=5}if(this.recovering&&r){let e=this.stoppedAt!=null&&r[0].pos>this.stoppedAt?r[0]:this.runRecovery(r,i,n);if(e)return LI&&console.log(`Force-finish `+this.stackID(e)),this.stackToTree(e.forceAll())}if(this.recovering){let e=this.recovering==1?1:this.recovering*3;if(n.length>e)for(n.sort((e,t)=>t.score-e.score);n.length>e;)n.pop();n.some(e=>e.reducePos>t)&&this.recovering--}else if(n.length>1){outer:for(let e=0;e<n.length-1;e++){let t=n[e];for(let r=e+1;r<n.length;r++){let i=n[r];if(t.sameState(i)||t.buffer.length>500&&i.buffer.length>500){if((t.score-i.score||t.buffer.length-i.buffer.length)>0)n.splice(r--,1);else{n.splice(e--,1);continue outer}}}}n.length>12&&(n.sort((e,t)=>t.score-e.score),n.splice(12,n.length-12))}this.minStackPos=n[0].pos;for(let e=1;e<n.length;e++)n[e].pos<this.minStackPos&&(this.minStackPos=n[e].pos);return null}stopAt(e){if(this.stoppedAt!=null&&this.stoppedAt<e)throw RangeError(`Can't move stoppedAt forward`);this.stoppedAt=e}tryReuse(e,t,n,r){if(!n)return null;let i=e.curContext&&e.curContext.tracker.strict,a=i?e.curContext.hash:0;for(;n;){let o=this.parser.nodeSet.types[n.type.id]==n.type?this.parser.getGoto(e.state,n.type.id):-1;if(o>-1&&n.length&&(!i||(n.prop(sj.contextHash)||0)==a))return e.useNode(n,o,t),n;if(n.children.length==0||n.positions[0]>0)break;let s=n.children[0];if(s instanceof hj&&(!r||s.type.id>=this.parser.minRepeatTerm))n=s;else break}return null}advanceStack(e,t,n){let r=e.pos,{parser:i}=this,a=LI?this.stackID(e)+` -> `:``;if(this.stoppedAt!=null&&r>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let t=e.reducePos<r&&e.buffer.length&&e.buffer[e.buffer.length-2]<=e.reducePos&&this.fragments.lastRepeatPos==e.reducePos&&this.tryReuse(e,e.reducePos,this.fragments.lastRepeat,!0)||this.tryReuse(e,r,this.fragments.nodeAt(r),!1);if(t)return LI&&console.log(a+this.stackID(e)+` (via reuse of ${i.getName(t.type.id)})`),!0}let o=i.stateSlot(e.state,4);if(o>0)return e.reduce(o),LI&&console.log(a+this.stackID(e)+` (via always-reduce ${i.getName(o&65535)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let s=this.tokens.getActions(e);for(let o=0;o<s.length;){let c=s[o++],l=s[o++],u=s[o++],d=o==s.length||!n,f=d?e:e.split(),p=this.tokens.mainToken;if(f.apply(c,l,p?p.start:f.pos,u),LI&&console.log(a+this.stackID(f)+` (via ${c&65536?`reduce of ${i.getName(c&65535)}`:`shift`} for ${i.getName(l)} @ ${r}${f==e?``:`, split`})`),d)return!0;f.pos>r?t.push(f):n.push(f)}return!1}advanceFully(e,t){let n=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>n)return UI(e,t),!0}}runRecovery(e,t,n){let r=null,i=!1;for(let a=0;a<e.length;a++){let o=e[a],s=t[a<<1],c=t[(a<<1)+1],l=LI?this.stackID(o)+` -> `:``;if(o.deadEnd&&(i||(i=!0,o.restart(),LI&&console.log(l+this.stackID(o)+` (restarted)`),this.advanceFully(o,n))))continue;let u=o.split(),d=l;for(let e=0;e<10&&u.forceReduce()&&(LI&&console.log(d+this.stackID(u)+` (via force-reduce)`),!this.advanceFully(u,n));e++)LI&&(d=this.stackID(u)+` -> `);for(let e of o.recoverByInsert(s))LI&&console.log(l+this.stackID(e)+` (via recover-insert)`),this.advanceFully(e,n);this.stream.end>o.pos?(c==o.pos&&(c++,s=0),o.recoverByDelete(s,c),LI&&console.log(l+this.stackID(o)+` (via recover-delete ${this.parser.getName(s)})`),UI(o,n)):(!r||r.score<u.score)&&(r=u)}return r}stackToTree(e){return e.close(),hj.build({buffer:DI.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let t=(RI||=new WeakMap).get(e);return t||RI.set(e,t=String.fromCodePoint(this.nextStackID++)),t+e}};function UI(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(r.pos==e.pos&&r.sameState(e)){t[n].score<e.score&&(t[n]=e);return}}t.push(e)}var WI=class{constructor(e,t,n){this.source=e,this.flags=t,this.disabled=n}allows(e){return!this.disabled||this.disabled[e]==0}},GI=class e extends Ij{constructor(e){if(super(),this.wrappers=[],e.version!=14)throw RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let t=e.nodeNames.split(` `);this.minRepeatTerm=t.length;for(let n=0;n<e.repeatNodeCount;n++)t.push(``);let n=Object.keys(e.topRules).map(t=>e.topRules[t][1]),r=[];for(let e=0;e<t.length;e++)r.push([]);function i(e,t,n){r[e].push([t,t.deserialize(String(n))])}if(e.nodeProps)for(let t of e.nodeProps){let e=t[0];typeof e==`string`&&(e=sj[e]);for(let n=1;n<t.length;){let r=t[n++];if(r>=0)i(r,e,t[n++]);else{let a=t[n+-r];for(let o=-r;o>0;o--)i(t[n++],e,a);n++}}}this.nodeSet=new dj(t.map((t,i)=>uj.define({name:i>=this.minRepeatTerm?void 0:t,id:i,props:r[i],top:n.indexOf(i)>-1,error:i==0,skipped:e.skippedNodes&&e.skippedNodes.indexOf(i)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=ij;let a=OI(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let e=0;e<this.specializerSpecs.length;e++)this.specialized[e]=this.specializerSpecs[e].term;this.specializers=this.specializerSpecs.map(JI),this.states=OI(e.states,Uint32Array),this.data=OI(e.stateData),this.goto=OI(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(e=>typeof e==`number`?new MI(a,e):e),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,t,n){let r=new HI(this,e,t,n);for(let i of this.wrappers)r=i(r,e,t,n);return r}getGoto(e,t,n=!1){let r=this.goto;if(t>=r[0])return-1;for(let i=r[t+1];;){let t=r[i++],a=t&1,o=r[i++];if(a&&n)return o;for(let n=i+(t>>1);i<n;i++)if(r[i]==e)return o;if(a)return-1}}hasAction(e,t){let n=this.data;for(let r=0;r<2;r++)for(let i=this.stateSlot(e,r?2:1),a;;i+=3){if((a=n[i])==65535){if(n[i+1]==1)a=n[i=KI(n,i+2)];else if(n[i+1]==2)return KI(n,i+2);else break}if(a==t||a==0)return KI(n,i+1)}return 0}stateSlot(e,t){return this.states[e*6+t]}stateFlag(e,t){return(this.stateSlot(e,0)&t)>0}validAction(e,t){return!!this.allActions(e,e=>e==t||null)}allActions(e,t){let n=this.stateSlot(e,4),r=n?t(n):void 0;for(let n=this.stateSlot(e,1);r==null;n+=3){if(this.data[n]==65535){if(this.data[n+1]==1)n=KI(this.data,n+2);else break}r=t(KI(this.data,n+1))}return r}nextStates(e){let t=[];for(let n=this.stateSlot(e,1);;n+=3){if(this.data[n]==65535){if(this.data[n+1]==1)n=KI(this.data,n+2);else break}if(!(this.data[n+2]&1)){let e=this.data[n+1];t.some((t,n)=>n&1&&t==e)||t.push(this.data[n],e)}}return t}configure(t){let n=Object.assign(Object.create(e.prototype),this);if(t.props&&(n.nodeSet=this.nodeSet.extend(...t.props)),t.top){let e=this.topRules[t.top];if(!e)throw RangeError(`Invalid top rule name ${t.top}`);n.top=e}return t.tokenizers&&(n.tokenizers=this.tokenizers.map(e=>{let n=t.tokenizers.find(t=>t.from==e);return n?n.to:e})),t.specializers&&(n.specializers=this.specializers.slice(),n.specializerSpecs=this.specializerSpecs.map((e,r)=>{let i=t.specializers.find(t=>t.from==e.external);if(!i)return e;let a=Object.assign(Object.assign({},e),{external:i.to});return n.specializers[r]=JI(a),a})),t.contextTracker&&(n.context=t.contextTracker),t.dialect&&(n.dialect=this.parseDialect(t.dialect)),t.strict!=null&&(n.strict=t.strict),t.wrap&&(n.wrappers=n.wrappers.concat(t.wrap)),t.bufferLength!=null&&(n.bufferLength=t.bufferLength),n}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let t=this.dynamicPrecedences;return t==null?0:t[e]||0}parseDialect(e){let t=Object.keys(this.dialects),n=t.map(()=>!1);if(e)for(let r of e.split(` `)){let e=t.indexOf(r);e>=0&&(n[e]=!0)}let r=null;for(let e=0;e<t.length;e++)if(!n[e])for(let n=this.dialects[t[e]],i;(i=this.data[n++])!=65535;)(r||=new Uint8Array(this.maxTerm+1))[i]=1;return new WI(e,n,r)}static deserialize(t){return new e(t)}};function KI(e,t){return e[t]|e[t+1]<<16}function qI(e){let t=null;for(let n of e){let e=n.p.stoppedAt;(n.pos==n.p.stream.end||e!=null&&n.pos>e)&&n.p.parser.stateFlag(n.state,2)&&(!t||t.score<n.score)&&(t=n)}return t}function JI(e){if(e.external){let t=+!!e.extend;return(n,r)=>e.external(n,r)<<1|t}return e.get}var YI=Wj({String:Y.string,Number:Y.number,"True False":Y.bool,PropertyName:Y.propertyName,Null:Y.null,", :":Y.separator,"[ ]":Y.squareBracket,"{ }":Y.brace}),XI=GI.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:`#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O`,goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:`⚠ JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array`,maxTerm:25,nodeProps:[[`isolate`,-2,6,11,``],[`openedBy`,7,`{`,14,`[`],[`closedBy`,8,`}`,15,`]`]],propSources:[YI],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0}),ZI=_M.define({name:`json`,parser:XI.configure({props:[FM.add({Object:GM({except:/^\s*\}/}),Array:GM({except:/^\s*\]/})}),YM.add({"Object Array":XM})]}),languageData:{closeBrackets:{brackets:[`[`,`{`,`"`]},indentOnInput:/^\s*[\}\]]$/}}),QI=8,$I=32,eL=48,tL=8;function nL({side:e,span:t,floor:n,ceil:r,reset:i,onReset:a,onSpan:o,onKeep:s,onShut:c,label:l,bar:u,step:d=QI,...f}){let p=e===`top`,m=t=>e===`start`?rh(t)?`right`:`left`:e===`end`?rh(t)?`left`:`right`:e,h=V.useRef(1),g=V.useRef(0),_=V.useRef(`none`),v=V.useRef(t),y=V.useRef(t),b=V.useRef(0),[x,S]=V.useState(!1),[C,w]=V.useState(!1),[T,E]=V.useState(!1);V.useEffect(()=>()=>cancelAnimationFrame(b.current),[]);let D=e=>Math.round(Math.min(r,Math.max(n,e))),O=e=>p?e.clientY:e.clientX,k=e=>{let n=e?.parentElement?.getBoundingClientRect();return n?p?n.height:n.width:t},A=e=>{o(e),s?.(e)},j=()=>{_.current=`none`,cancelAnimationFrame(b.current),b.current=0,E(!1)},ee=()=>{if(_.current===`none`)return;let e=_.current===`moved`;j(),e&&A(v.current)};V.useEffect(()=>{if(!T||typeof window>`u`)return;let e=e=>{e.key===`Escape`&&_.current!==`none`&&(e.preventDefault(),j(),o(y.current))};return window.addEventListener(`keydown`,e,!0),()=>window.removeEventListener(`keydown`,e,!0)});let M=p?{l:0,r:0,b:0,height:tL,justify:`center`}:{t:0,b:0,width:tL,items:`center`,...e===`start`?{insetInlineEnd:0}:e===`end`?{insetInlineStart:0}:e===`left`?{r:0}:{l:0}};return(0,H.jsx)(z,{role:`separator`,"aria-orientation":p?`horizontal`:`vertical`,"aria-label":l,"aria-valuenow":Math.round(t),"aria-valuemin":n,"aria-valuemax":r,tabIndex:0,"data-slot":`grip`,"data-side":e,"data-moving":T?``:void 0,position:`absolute`,...M,z:10,cursor:p?`row-resize`:`col-resize`,outlineWidth:0,focusVisibleStyle:{outlineWidth:0},style:{touchAction:`none`},onPointerEnter:()=>S(!0),onPointerLeave:()=>S(!1),onFocus:e=>w(e.currentTarget.matches(`:focus-visible`)),onBlur:()=>w(!1),onPointerDown:e=>{if(e.button!==0)return;e.preventDefault(),e.currentTarget.setPointerCapture?.(e.pointerId);let t=k(e.currentTarget);h.current=m(e.currentTarget)===`right`?-1:1,g.current=O(e)-h.current*t,v.current=D(t),y.current=D(t),_.current=`held`,E(!0)},onPointerMove:e=>{if(_.current===`none`)return;_.current=`moved`;let t=h.current*(O(e)-g.current);if(c&&t<n-eL){j(),e.currentTarget.releasePointerCapture?.(e.pointerId),c();return}v.current=D(t),!b.current&&(b.current=requestAnimationFrame(()=>{b.current=0,o(v.current)}))},onPointerUp:ee,onPointerCancel:ee,onDoubleClick:()=>a?a():A(D(i??t)),onKeyDown:e=>{let t=e.shiftKey?$I:d,i=k(e.currentTarget),a=m(e.currentTarget),o=a===`left`?`ArrowRight`:a===`right`?`ArrowLeft`:`ArrowDown`,s=a===`left`?`ArrowLeft`:a===`right`?`ArrowRight`:`ArrowUp`,l=e.key===o?i+t:e.key===s?i-t:e.key===`Home`?n:e.key===`End`?r:null;if(l!==null){if(e.preventDefault?.(),c&&l<n)return c();A(D(l))}},...f,children:u?(0,H.jsx)(z,{"data-slot":`grip-bar`,...(()=>{let[e,t]=u===`edge`?[4,48]:[3,32];return p?{height:e,width:t}:{width:e,height:t}})(),self:`center`,rounded:`$10`,bg:T?`$rim`:C?`$outlineColor`:x?`$hint`:`transparent`,[p?`scaleX`:`scaleY`]:T||x||C?1.2:1,animation:`quickest`,pointerEvents:`none`}):(0,H.jsx)(z,{...p?{height:2,width:`100%`}:{width:2,height:`100%`},rounded:1,bg:C||T?`$outlineColor`:x?`$rim`:`transparent`,pointerEvents:`none`})})}var rL=`
|
|
32
|
+
\r`,iL=`"\\/bfnrt`,aL=/-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?/y,oL=/[0-9a-fA-F]{4}/y,Rte=/^(\{|\[\s*([[{"\]\-\d]|true\b|false\b|null\b|$))/,sL=e=>e===void 0?`end of input`:e===`
|
|
33
|
+
`?`line break`:`character '${e}'`;function cL(e){let t=0,n=(e,n=t)=>{throw{at:n,message:e}},r=()=>{for(;t<e.length&&rL.includes(e[t]);)t++},i=()=>{for(t++;t<e.length;){let r=e[t];if(r===`"`){t++;return}if(r===`\\`){let r=e[t+1];if(r===`u`){oL.lastIndex=t+2,oL.test(e)||n(`Expected four hex digits after \\u`,t+2),t+=6;continue}(r===void 0||!iL.includes(r))&&n(`Invalid escape '\\${r??``}' in string`,t+1),t+=2;continue}r<` `&&n(r===`
|
|
34
|
+
`?`Unterminated string`:`Control character in string`),t++}n(`Unterminated string`)},a=()=>{aL.lastIndex=t;let r=aL.exec(e);(!r||r[0]===`-`)&&n(`Invalid number`),t+=r[0].length},o=a=>{r(),e[t]!==`"`&&n(a&&e[t]===`}`?`Trailing comma before '}'`:`Expected a double-quoted property name, found ${sL(e[t])}`),i(),r(),e[t]!==`:`&&n(`Expected ':' after property name, found ${sL(e[t])}`),t++},s=[],c=!0;try{for(;;){if(r(),c){let l=e[t];if(l===`{`||l===`[`){if(t++,r(),e[t]===(l===`{`?`}`:`]`)){t++,c=!1;continue}s.push(l),l===`{`&&o(!1);continue}if(l===`"`)i();else if(l===`-`||l!==void 0&&l>=`0`&&l<=`9`)a();else{let r=[`true`,`false`,`null`].find(n=>e.startsWith(n,t));r||n(`Unexpected ${sL(l)}`),t+=r.length}c=!1;continue}let l=s.at(-1);if(!l)return t<e.length&&n(`Unexpected ${sL(e[t])} after the JSON value`),null;if(e[t]===`,`){t++,l===`{`?o(!0):(r(),e[t]===`]`&&n(`Trailing comma before ']'`)),c=!0;continue}if(e[t]===(l===`{`?`}`:`]`)){t++,s.pop();continue}n(l===`{`?`Expected ',' or '}' after property value, found ${sL(e[t])}`:`Expected ',' or ']' after array element, found ${sL(e[t])}`)}}catch(e){return e}}function lL(e,t){let n=1,r=0;for(let i=0;i<t&&i<e.length;i++)e[i]===`
|
|
35
|
+
`&&(n++,r=i+1);return{line:n,column:t-r+1}}function uL(e,t={}){let n=e.trim();if(!n)return{kind:`empty`};try{return{kind:`json`,value:JSON.parse(e)}}catch(r){if(t.text&&!Rte.test(n))return{kind:`text`,value:e};let i=cL(e)??{at:0,message:r instanceof Error?r.message:String(r)};return{kind:`error`,message:i.message,at:i.at,...lL(e,i.at)}}}function dL(e){let t=uL(e);return t.kind===`json`?JSON.stringify(t.value,null,2):null}var fL=[`javascript`,`typescript`,`python`,`java`,`csharp`,`cpp`,`c`,`go`,`rust`,`ruby`,`php`,`swift`,`kotlin`,`dart`,`html`,`css`,`scss`,`json`,`xml`,`yaml`,`sql`,`markdown`,`shell`,`plaintext`],pL={javascript:`JavaScript`,typescript:`TypeScript`,python:`Python`,java:`Java`,csharp:`C#`,cpp:`C++`,c:`C`,go:`Go`,rust:`Rust`,ruby:`Ruby`,php:`PHP`,swift:`Swift`,kotlin:`Kotlin`,dart:`Dart`,html:`HTML`,css:`CSS`,scss:`SCSS`,json:`JSON`,xml:`XML`,yaml:`YAML`,sql:`SQL`,markdown:`Markdown`,shell:`Shell`,plaintext:D(`Plain Text`)},mL=4096,hL=qk.theme({"&":{color:`var(--ink)`,backgroundColor:`transparent`},"&.cm-focused":{outline:`none`},".cm-scroller":{fontFamily:`var(--font-mono, 'Zen Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace)`,lineHeight:`1.6`,overflow:`auto`,flex:`1 1 auto`,height:`auto`,minHeight:`0`},".cm-content":{padding:`8px 0`,caretColor:`var(--ink)`},".cm-line":{padding:`0 12px`},".cm-gutters":{backgroundColor:`transparent`,color:`var(--codeDim)`,border:`none`,borderInlineEnd:`1px solid var(--edge)`},".cm-lineNumbers .cm-gutterElement":{padding:`0 10px 0 12px`,minWidth:`28px`},".cm-activeLine":{backgroundColor:`var(--panel)`},".cm-activeLineGutter":{backgroundColor:`transparent`,color:`var(--quiet)`},".cm-cursor, .cm-dropCursor":{borderInlineStartColor:`var(--ink)`},".cm-selectionBackground, &.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, ::selection":{backgroundColor:`var(--raised)`},".cm-matchingBracket, &.cm-focused .cm-matchingBracket":{backgroundColor:`var(--raised)`,color:`inherit`,outline:`none`},".cm-nonmatchingBracket, &.cm-focused .cm-nonmatchingBracket":{backgroundColor:`transparent`},".cm-placeholder":{color:`var(--codeDim)`},".cm-foldGutter .cm-gutterElement":{padding:`0 4px`,color:`var(--codeDim)`,cursor:`pointer`},".cm-foldGutter .cm-gutterElement:hover":{color:`var(--ink)`},".cm-foldPlaceholder":{backgroundColor:`var(--raised)`,border:`1px solid var(--edge)`,borderRadius:`4px`,color:`var(--codePunctuation)`,padding:`0 4px`,margin:`0 2px`,cursor:`pointer`},".cm-foldCount":{color:`var(--codeComment)`},".cm-fault":{backgroundColor:`var(--state-error-bg, rgb(239 68 68 / .1))`},".cm-gutterElement.cm-fault":{color:`var(--bad)`},".cm-fault-at":{textDecoration:`underline wavy var(--bad)`,textDecorationSkipInk:`none`,textUnderlineOffset:`3px`}}),gL=e=>({color:`var(--code${e[0].toUpperCase()}${e.slice(1)})`,...fS[e]}),_L=CN.define([{tag:Y.propertyName,...gL(`key`)},{tag:Y.string,...gL(`string`)},{tag:Y.number,...gL(`number`)},{tag:Y.bool,...gL(`boolean`)},{tag:Y.null,...gL(`null`)},{tag:[Y.punctuation,Y.separator,Y.brace,Y.squareBracket],...gL(`punctuation`)},{tag:Y.comment,...gL(`comment`)},{tag:Y.keyword,...gL(`keyword`)}]),vL=new OM(ZI.configure({props:[YM.add({"Object Array":e=>({from:e.from,to:e.to})})]})),yL=(e,t)=>t===1?e(`1 key`):e(`{n} keys`,{n:t}),bL=(e,t)=>t===1?e(`1 item`):e(`{n} items`,{n:t});function xL(e,t,n){let r=vM(e).resolveInner(t.from,1);for(;r.parent&&r.name!==`Object`&&r.name!==`Array`;)r=r.parent;if(r.name===`Object`)return{open:`{`,close:`}`,count:yL(n,r.getChildren(`Property`).length)};let i=0;for(let e=r.firstChild;e;e=e.nextSibling)!/^[[\],]$/.test(e.name)&&!e.type.isError&&(i+=1);return{open:`[`,close:`]`,count:bL(n,i)}}var SL=e=>hN({preparePlaceholder:(t,n)=>xL(t,n,e),placeholderDOM:(t,n,r)=>{let i=document.createElement(`span`);i.className=`cm-foldPlaceholder`,i.title=e(`Unfold`),i.setAttribute(`aria-label`,e(`Folded, {count}`,{count:r.count})),i.textContent=`${r.open}…${r.close}`;let a=document.createElement(`span`);return a.className=`cm-foldCount`,a.textContent=` ${r.count}`,i.append(a),i.onclick=n,i}}),CL=2,wL=(e,t)=>{let n=0;for(let r of e)if(r===` `)n+=1;else if(r===` `)n+=t-n%t;else break;return n},TL=new Map,EL=e=>{let t=TL.get(e);return t||(t=ZT.line({attributes:{style:`padding-inline-start: calc(${e}ch + 12px); text-indent: -${e}ch`}}),TL.set(e,t)),t},DL=CD.fromClass(class{decorations;constructor(e){this.decorations=this.build(e)}update(e){(e.docChanged||e.viewportChanged)&&(this.decorations=this.build(e.view))}build(e){let t=new aT;for(let{from:n,to:r}of e.visibleRanges)for(let i=n;i<=r;){let n=e.state.doc.lineAt(i);t.add(n.from,n.from,EL(wL(n.text,e.state.tabSize)+CL)),i=n.to+1}return t.finish()}},{decorations:e=>e.decorations}),OL=jw.define(),kL=new class extends MA{elementClass=`cm-fault`},AL=ZT.line({class:`cm-fault`}),jL=ZT.mark({class:`cm-fault-at`});function ML(e,t){let n=uL(e.doc.toString(),{text:t});if(n.kind!==`error`)return{check:n,marks:ZT.none,gutter:nT.empty};let r=Number.isFinite(n.at)?Math.min(n.at,e.doc.length):0,i=e.doc.lineAt(r),a=Math.min(r+1,i.to),o=[AL.range(i.from),...a>r?[jL.range(r,a)]:[]];return{check:n,marks:ZT.set(o,!0),gutter:nT.of([kL.range(i.from)])}}var NL=e=>pw.define({create:t=>ML(t,e),update:(t,n)=>n.docChanged?ML(n.state,e):t,provide:e=>[qk.decorations.from(e,e=>e.marks),NA.from(e,e=>e.gutter)]}),PL=e=>typeof e==`number`?`${e}px`:e;function FL({value:e,defaultValue:t=``,language:n=`javascript`,height:r,minHeight:i=96,maxHeight:o=480,resizable:s=r===void 0,allowText:c=!1,onChange:l,onCheck:u,onMount:d,readOnly:f=!1,lineNumbers:p=!0,wordWrap:m=`on`,fontSize:h=14,placeholder:g,showCopyButton:_=!0,showFormatButton:v,showLanguageSelector:b=!0,availableLanguages:x=fL,label:S,variant:C,title:w,actions:T,autoHeight:E=!1,...D}){let{t:O}=R(),k=S??O(`Code`),A=V.useMemo(()=>SL(O),[O]),j=C??(w!==void 0||T!==void 0?`with-header`:`default`),ee=j===`with-header`,[M,N]=V.useState(n),[P,te]=V.useState(e??t),[F,I]=V.useState(null),[ne,re]=V.useState(!1),ie=V.useRef(null),L=V.useRef([]),ae=V.useRef(null),[oe,se]=V.useState(null),ce=V.useRef(void 0),le=V.useRef({onChange:l,onCheck:u});le.current={onChange:l,onCheck:u};let ue=V.useMemo(()=>({language:new vw,gutter:new vw,wrap:new vw,edit:new vw}),[]),de=M===`json`,fe=V.useMemo(()=>NL(c),[c]),pe=V.useRef({field:fe});pe.current.field=fe;let me=()=>de?[vL,fe,A,xN()]:[],he=()=>p?[$A(),rj()]:[],ge=()=>m===`off`?[]:[qk.lineWrapping,DL],_e=()=>[Yw.readOnly.of(f),qk.editable.of(!f)],ve=e=>{let t=e.field(pe.current.field,!1);t!==pe.current.seen&&(pe.current.seen=t,I(t?t.check:null),t&&le.current.onCheck?.(t.check))},ye=V.useCallback(()=>{let e=ae.current;if(!e||e.state.readOnly)return!1;let t=e.state.doc.toString(),n=dL(t);return n===null||n===t?!1:(e.dispatch({changes:{from:0,to:t.length,insert:n}}),!0)},[]);V.useEffect(()=>{let n=ie.current;if(!n)return;let r=qk.updateListener.of(e=>{if(e.docChanged&&!e.transactions.some(e=>e.annotation(OL))){let t=e.state.doc.toString();te(t),le.current.onChange&&(L.current=[...L.current.slice(-31),t]),le.current.onChange?.(t)}ve(e.state)}),i=new qk({parent:n,state:Yw.create({doc:e??t,extensions:[ue.gutter.of(he()),hP(),bA(),qM(),zN(),DA(),DN(_L),nA.of([{key:`Shift-Alt-f`,run:ye},CI,...fN,...SI,...PP,{key:`Escape`,run:e=>(e.contentDOM.blur(),!0)}]),ue.language.of(me()),ue.wrap.of(ge()),ue.edit.of(_e()),g?jA(g):[],qk.contentAttributes.of({"aria-label":k,"data-slot":`code-editor-content`}),hL,r]})});return ae.current=i,ve(i.state),d?.(i),()=>{i.destroy(),ae.current=null,clearTimeout(ce.current)}},[]),V.useEffect(()=>{ae.current?.dispatch({effects:[ue.language.reconfigure(me()),ue.gutter.reconfigure(he()),ue.wrap.reconfigure(ge()),ue.edit.reconfigure(_e())]})},[de,fe,A,p,m,f]),V.useEffect(()=>{let t=ae.current;if(!t||e===void 0)return;let n=L.current.indexOf(e);if(n!==-1){L.current=L.current.slice(n+1);return}L.current=[];let r=t.state.doc.toString();e!==r&&(t.dispatch({changes:{from:0,to:r.length,insert:e},annotations:OL.of(!0)}),te(e))},[e]),V.useEffect(()=>{let e=ae.current?.dom;if(!e)return;e.style.fontSize=`${h}px`;let t=oe===null?r===void 0?``:PL(r):`${oe}px`;e.style.height=t,e.style.minHeight=t?``:`${i}px`,e.style.maxHeight=t||E?``:`${o}px`,ae.current?.requestMeasure()},[oe,r,i,o,E,h]);let be=V.useCallback(async()=>{try{await navigator.clipboard.writeText(P),re(!0),clearTimeout(ce.current),ce.current=setTimeout(()=>re(!1),2e3),Sv.success(O(`Code copied to clipboard`))}catch{Sv.error(O(`Failed to copy code`))}},[P,O]),xe=typeof r==`string`&&r.endsWith(`%`),Se=v??(de&&!f),Ce=ee||b||_||Se,we=de&&F!==null;return(0,H.jsxs)(z,{...B(`code-editor`),"data-variant":j,borderWidth:j===`borderless`?0:1,borderColor:`$borderColor`,rounded:j===`borderless`?0:`$3`,overflow:`hidden`,bg:`$background`,focusWithinStyle:j===`borderless`?void 0:{borderColor:`$outlineColor`},...D,children:[Ce&&(0,H.jsxs)(y,{...B(ee?`code-editor-header`:`code-editor-toolbar`),items:`center`,justify:`space-between`,flexWrap:`wrap`,gap:`$2`,borderBottomWidth:1,borderColor:`$borderColor`,bg:`$panel`,px:`$2`,py:ee?0:`$1`,...ee?{minH:40}:null,children:[ee?(0,H.jsx)(a,{...B(`code-editor-title`),size:`$2`,fontWeight:`500`,color:`$hint`,px:`$1`,numberOfLines:1,flex:1,minW:0,children:w??k}):null,b?(0,H.jsxs)(J_,{value:M,onValueChange:N,children:[(0,H.jsx)(X_,{...B(`code-editor-language-trigger`),width:`auto`,minHeight:32,borderWidth:0,bg:`transparent`,gap:`$1.5`,px:`$2`,children:(0,H.jsx)(a,{size:`$1`,fontFamily:`$mono`,children:pL[M]?O(pL[M]):M})}),(0,H.jsx)(tv,{...B(`code-editor-language-content`),children:x.map(e=>(0,H.jsx)(Z_,{value:e,children:pL[e]?O(pL[e]):e},e))})]}):(0,H.jsx)(a,{...B(`code-editor-language`),size:`$1`,fontFamily:`$mono`,color:`$soft`,px:`$2`,children:pL[M]?O(pL[M]):M}),(0,H.jsxs)(y,{items:`center`,justify:`flex-end`,flexWrap:`wrap`,gap:ee?`$2`:`$1`,shrink:1,minW:0,children:[Se&&(0,H.jsxs)(W,{...B(`code-editor-format-button`),variant:`ghost`,size:`sm`,disabled:F?.kind!==`json`,onClick:ye,children:[(0,H.jsx)(up,{size:14}),O(`Format`)]}),_&&(0,H.jsxs)(W,{...B(`code-editor-copy-button`),variant:`ghost`,size:`sm`,disabled:!P,onClick:be,children:[ne?(0,H.jsx)(Vt,{size:14}):(0,H.jsx)(Fp,{size:14}),O(ne?`Copied!`:`Copy`)]}),T]})]}),(0,H.jsxs)(z,{position:`relative`,...xe&&{flex:1,minH:0},children:[(0,H.jsx)(z,{ref:ie,...B(`code-editor-body`),...eh,...xe&&{flex:1,minH:0}}),s&&(0,H.jsx)(nL,{side:`top`,span:oe??i,floor:i,ceil:mL,onSpan:se,onReset:()=>se(null),label:O(`Resize {label}`,{label:k}),b:-4})]}),we&&(0,H.jsx)(y,{...B(`code-editor-footer`),items:`center`,justify:`space-between`,gap:`$2`,minH:28,px:`$3`,py:`$1`,borderTopWidth:1,borderColor:`$borderColor`,bg:`$panel`,children:(0,H.jsx)(IL,{check:F})})]})}function IL({check:e}){let{t}=R(),n=e?.kind===`error`,r=e===null?``:e.kind===`error`?t(`Line {line}, column {column}: {message}`,{line:e.line,column:e.column,message:e.message}):e.kind===`text`?t(`Plain text`):e.kind===`empty`?t(`Empty`):t(`Valid JSON`);return(0,H.jsxs)(y,{...B(`code-editor-status`),"aria-live":`polite`,items:`center`,gap:`$1.5`,flex:1,minW:0,children:[n?(0,H.jsx)(Op,{size:14,color:`$bad`}):e?.kind===`text`?(0,H.jsx)(Mm,{size:14,color:`$soft`}):e?.kind===`json`?(0,H.jsx)(kp,{size:14,color:`$soft`}):null,(0,H.jsx)(a,{...B(`code-editor-status-text`),"data-kind":e?.kind,size:`$1`,fontFamily:`$mono`,color:n?`$bad`:`$soft`,numberOfLines:2,children:r})]})}var LL=e=>k(e||`en`),RL=e=>me(e||`en`),zL=e=>e&&e!==`en`?e:`en`,BL={active:!1,locale:`en-US`,dir:`ltr`,messages:{},t:(e,t)=>ce({},e,t),format:fe(`en-US`)},VL=(0,V.createContext)(BL),HL=(e,t)=>({active:!0,locale:e,dir:RL(e),messages:t,t:(e,n)=>ce(t,e,n),format:fe(e)});function UL(){let e=(0,V.useContext)(VL);return e.active?{active:!0,locale:e.locale,dir:e.dir}:{active:!1,locale:`en-US`,dir:`ltr`}}var WL=[[`year`,31536e3],[`month`,2592e3],[`week`,604800],[`day`,86400],[`hour`,3600],[`minute`,60],[`second`,1]],GL={year:`y`,month:`mo`,week:`w`,day:`d`,hour:`h`,minute:`m`,second:`s`},KL=e=>{let t=Math.abs(e);for(let[n,r]of WL)if(t>=r||n===`second`){let i=`${Math.floor(t/r)}${GL[n]}`;return e<0?`in ${i}`:i}return`0s`},qL=(e,t)=>{if(e<0){let n=-e;return n<60?t(`in a moment`):n<120?t(`in 1 minute`):n<3600?t(`in {n} minutes`,{n:Math.floor(n/60)}):n<7200?t(`in 1 hour`):n<86400?t(`in {n} hours`,{n:Math.floor(n/3600)}):n<172800?t(`tomorrow`):n<604800?t(`in {n} days`,{n:Math.floor(n/86400)}):n<1209600?t(`in 1 week`):n<2592e3?t(`in {n} weeks`,{n:Math.floor(n/604800)}):n<5184e3?t(`in 1 month`):n<31536e3?t(`in {n} months`,{n:Math.floor(n/2592e3)}):n<63072e3?t(`in 1 year`):t(`in {n} years`,{n:Math.floor(n/31536e3)})}return e<60?t(`just now`):e<120?t(`1 minute ago`):e<3600?t(`{n} minutes ago`,{n:Math.floor(e/60)}):e<7200?t(`1 hour ago`):e<86400?t(`{n} hours ago`,{n:Math.floor(e/3600)}):e<172800?t(`1 day ago`):e<604800?t(`{n} days ago`,{n:Math.floor(e/86400)}):e<1209600?t(`1 week ago`):e<2592e3?t(`{n} weeks ago`,{n:Math.floor(e/604800)}):e<5184e3?t(`1 month ago`):e<31536e3?t(`{n} months ago`,{n:Math.floor(e/2592e3)}):e<63072e3?t(`1 year ago`):t(`{n} years ago`,{n:Math.floor(e/31536e3)})},JL=(e,t)=>{let n=new Intl.RelativeTimeFormat(t,{numeric:`auto`,style:`long`});for(let[t,r]of WL)if(Math.abs(e)>=r||t===`second`){let i=Math.round(e/r)*-1;return n.format(i,t)}return n.format(0,`second`)},YL=(e,t,n,r)=>{let i=Math.floor((Date.now()-new Date(e).getTime())/1e3);return t===`short`?KL(i):t===`long`?JL(i,r):qL(i,n)},XL=M(a,{name:`RelativeTime`,render:`time`});function ZL({date:e,format:t=`auto`,updateInterval:n=6e4,...r}){let{t:i}=R(),{active:a,locale:o}=UL(),s=a?o:void 0,[c,l]=V.useState(()=>YL(e,t,i,s));return V.useEffect(()=>{l(YL(e,t,i,s));let r=setInterval(()=>l(YL(e,t,i,s)),n);return()=>clearInterval(r)},[e,t,n,i,s]),(0,H.jsx)(XL,{"data-slot":`relative-time`,"data-format":t,dateTime:new Date(e).toISOString(),...r,children:c})}var QL=(0,V.createContext)(`measure-on-hover`),$L=e=>{let t=e;return!t||typeof t.scrollWidth!=`number`?!1:t.scrollWidth>(t.clientWidth??0)||(t.scrollHeight??0)>(t.clientHeight??0)},eR=500,tR=300;function nR({text:e,lineClamp:t,tooltipContent:n,tooltipDelay:r=eR,tooltipPlace:i=`bottom`,isTooltipMultiline:o=!1,alwaysShowTooltip:s=!1,isFocusable:c=!1,...l}){let u=(0,V.useContext)(QL),[d,f]=(0,V.useState)(!1),[p,m]=(0,V.useState)(!1),h=(0,V.useRef)(null),g=(0,V.useRef)(null),_=(0,V.useRef)(!1);(0,V.useEffect)(()=>()=>{g.current&&clearTimeout(g.current)},[]);let v=t&&Number.isInteger(t)&&t>0?t:1,y=t=>(0,H.jsx)(a,{...B(`truncated-text`),numberOfLines:v,maxW:`100%`,minW:0,...v>1?{style:{whiteSpace:`pre-wrap`,overflowWrap:`anywhere`}}:null,...l,...t,children:e});if(u===`disabled`&&!s)return y({});let b=e=>{h.current=e;let t=$L(e);return m(t),t},x=(e,t)=>{g.current&&clearTimeout(g.current);let n=u===`measure-on-hover`?b(e):(h.current=e,!1);g.current=setTimeout(()=>{let e=u===`measure-on-open`?b(h.current):n;(s||e)&&f(!0)},t)},S=()=>{g.current&&clearTimeout(g.current),g.current=null,_.current||f(!1)};return(0,H.jsxs)(Ym,{open:d,onOpenChange:e=>!e&&f(!1),placement:i,children:[(0,H.jsx)(pu.Anchor,{asChild:!0,children:y({onPointerEnter:e=>x(e?.currentTarget,r),onPointerLeave:S,onFocus:e=>{_.current=!0,x(e?.currentTarget,0)},onBlur:()=>{_.current=!1,S()},...c?{tabIndex:0,focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`}}:null,...p?{cursor:`pointer`}:null})}),(0,H.jsx)(Qm,{maxW:tR,children:o&&typeof(n??e)==`string`?(0,H.jsx)(a,{size:`$1`,style:{whiteSpace:`pre-wrap`},children:n??e}):n??e})]})}var rR=20,iR=14,aR=(e,t)=>{if(!(0,V.isValidElement)(e))return e;let n=e.props;return(0,V.cloneElement)(e,{...n.size==null?{size:iR}:null,...n.color==null?{color:t}:null})};function oR({color:e=`gray`,variant:t=`soft`,weight:n=`regular`,startIcon:r,endElement:i,truncate:o=!0,borderStyle:s=`solid`,onPress:c,href:l,disabled:u=!1,children:d,style:f,...p}){let m=e===`transparent`,h=Ih(m?`gray`:e),{style:g,tone:_}=Lh(h,[3,11]),v=m?`$aside`:t===`solid`?`$background`:_(11),b=m||t===`outline`||t===`ghost`?`transparent`:_(t===`solid`?11:3),x={size:`$2`,fontWeight:n===`medium`?`500`:void 0,color:v},S=!u&&(c!=null||l!=null);return(0,H.jsxs)(y,{...B(`tag`),"data-color":m?`transparent`:h,"data-variant":t,...l==null?c==null?{render:`span`}:{...Pn(u?void 0:c)}:{render:`a`,href:l},...u?{"aria-disabled":!0}:null,display:`inline-flex`,self:`flex-start`,items:`center`,gap:`$1`,height:rR,px:`$2`,maxW:`100%`,minW:0,rounded:`$xs`,bg:b,...t===`outline`?{borderWidth:1,borderColor:`$rim`,borderStyle:s}:null,overflow:`hidden`,opacity:u?.5:1,cursor:u?`not-allowed`:S?`pointer`:void 0,...S?{focusVisibleStyle:at}:null,style:{...g,...f},...p,children:[r?aR(r,v):null,typeof d==`string`||typeof d==`number`?o?(0,H.jsx)(nR,{text:String(d),...x}):(0,H.jsx)(a,{...x,children:d}):d,i?(0,H.jsx)(y,{...B(`tag-end`),shrink:0,items:`center`,children:i}):null]})}var sR={sm:20,md:24},cR={ghost:{rest:`transparent`,hover:`$hover`,down:`$raised`},soft:{rest:`$hover`,hover:`$raised`,down:`$rim`},solid:{rest:`$raised`,hover:`$rim`,down:`$bound`}};function lR({label:e,size:t=`sm`,variant:n=`ghost`,color:r=`primary`,shape:i=`square`,weight:a=`regular`,startElement:o,endElement:s,endElementDivider:c=!1,truncate:l=!0,tooltipContent:u,onPress:d,href:f,clickable:p,disabled:m=!1,children:h,...g}){let _=cR[n],v=!m&&(p??(d!=null||f!=null)),b={size:`$2`,fontWeight:a===`medium`?`500`:void 0,color:m?`$hush`:r===`secondary`?`$aside`:`$ink`},x=e??h;return(0,H.jsxs)(y,{...B(`chip`),"data-size":t,"data-variant":n,...f!=null&&!m?{render:`a`,href:f}:d==null?null:Pn(m?void 0:d),...m?{"aria-disabled":!0}:null,display:`inline-flex`,self:`flex-start`,items:`center`,gap:`$1`,height:sR[t],px:`$1`,maxW:`100%`,minW:0,rounded:i===`round`?`$10`:`$xs`,bg:_.rest,select:`none`,cursor:m?`not-allowed`:v?`pointer`:void 0,...v?{hoverStyle:{bg:_.hover},pressStyle:{bg:_.down},focusVisibleStyle:at,...dt(sR[t],44,`y`)}:null,...g,children:[o?(0,H.jsx)(y,{...B(`chip-start`),shrink:0,items:`center`,children:o}):null,typeof x==`string`||typeof x==`number`?l?(0,H.jsx)(nR,{text:String(x),tooltipContent:u,...b}):Vm(x,void 0,b):x,s?(0,H.jsx)(y,{...B(`chip-end`),shrink:0,items:`center`,self:`stretch`,...c?{borderInlineStartWidth:1,borderColor:`$borderColor`,paddingInlineStart:`$1`}:null,children:s}):null]})}var uR=4,dR=24,fR=220;function pR(e,t,n=1/0,r=uR,i=dR){let a=Math.min(e.length,n);if(a===0)return 0;let o=0;for(let n=0;n<a;n++){let a=o+(n>0?r:0)+e[n];if(a+(n+1<e.length?r+i:0)>t)return Math.max(1,n);o=a}return a}function mR({children:e,maxInlineCount:t,showOverflowCount:n=`hover`,overflowLabel:r,open:i,defaultOpen:o=!1,onOpenChange:s,popupProps:c,...l}){let{t:u}=R(),d=(0,V.useMemo)(()=>V.Children.toArray(e).filter(V.isValidElement),[e]),[f,p]=(0,V.useState)([]),[m,h]=(0,V.useState)(null),[g,_]=(0,V.useState)(!1),[v,b]=(0,V.useState)(o),x=i??v,S=(0,V.useCallback)(e=>{i===void 0&&b(e),s?.(e)},[i,s]),C=m!=null&&f.filter(e=>e!=null).length===d.length?pR(f,m,t):Math.min(d.length,t??d.length),w=d.length-C,T=w>0&&(n===`always`||n===`hover`&&(g||x)),E=e=>t=>{let n=t?.nativeEvent?.layout?.width;typeof n==`number`&&p(t=>{if(t[e]===n)return t;let r=t.slice();return r[e]=n,r})};return(0,H.jsxs)(y,{...B(`overflowing-list`),position:`relative`,width:`100%`,minW:0,items:`center`,gap:uR,overflow:`hidden`,onLayout:e=>h(e.nativeEvent.layout.width),onPointerEnter:()=>_(!0),onPointerLeave:()=>_(!1),onFocus:()=>_(!0),onBlur:()=>_(!1),...l,children:[(0,H.jsx)(y,{"aria-hidden":!0,position:`absolute`,t:0,l:0,opacity:0,pointerEvents:`none`,gap:uR,inert:!0,children:d.map((e,t)=>(0,H.jsx)(y,{shrink:0,onLayout:E(t),children:e},e.key??t))}),d.slice(0,C).map((e,t)=>(0,H.jsx)(y,{...t===C-1?{shrink:1,minW:0}:{shrink:0},children:e},e.key??t)),w>0&&n!==`never`?(0,H.jsxs)(I_,{open:x,onOpenChange:S,placement:`bottom-start`,children:[(0,H.jsx)(L_,{asChild:!0,children:(0,H.jsx)(y,{...B(`overflowing-list-count`),...Pn(()=>S(!x)),"aria-label":u(`{label} ({n})`,{label:r??u(`Show all items`),n:d.length}),"aria-expanded":x,shrink:0,minW:dR,height:20,px:`$1`,items:`center`,justify:`center`,rounded:`$xs`,cursor:`pointer`,hoverStyle:{bg:`$hover`},focusVisibleStyle:at,opacity:+!!T,children:(0,H.jsx)(a,{size:`$1`,color:`$ink`,children:`+${w}`})})}),(0,H.jsx)(R_,{p:`$2`,minW:fR,style:{width:Math.max(fR,Math.round(m??0))},...c,children:(0,H.jsx)(z,{...B(`overflowing-list-popup`),maxH:320,overflow:`scroll`,children:(0,H.jsx)(y,{flexWrap:`wrap`,gap:uR,children:d})})})]}):null]})}var hR=e=>{let t=new Intl.NumberFormat(e).formatToParts(-12345.6);return{group:t.find(e=>e.type===`group`)?.value??`,`,decimal:t.find(e=>e.type===`decimal`)?.value??`.`}},gR=/[\s\u00a0\u202f\u2009]/g,_R=/^[\s\u00a0\u202f\u2009]$/;function vR(e,t,n){let{group:r,decimal:i}=hR(t),a=e.replace(gR,``).replace(/[\u2212\u2012\u2013]/g,`-`);if(!a)return NaN;r&&!_R.test(r)&&(a=a.split(r).join(``));let o=n?.style===`percent`||a.includes(`%`);if(a=a.replace(/[^0-9.,\-+]/g,``),a=i===`.`?a.replace(/,/g,``):a.replace(/\./g,``).replace(i,`.`),!/^[-+]?(\d+\.?\d*|\.\d+)$/.test(a))return NaN;let s=Number(a);return o?s/100:s}var yR=e=>{let t=String(e),n=t.match(/e-(\d+)$/);return n?Number(n[1]):t.includes(`.`)?t.split(`.`)[1].length:0},bR=(e,t,n)=>Math.min(n??1/0,Math.max(t??-1/0,e)),xR={lg:`icon-lg`,default:`icon`,sm:`icon-sm`,xs:`icon-xs`};function SR({value:e,defaultValue:t=null,onValueChange:n,min:r,max:i,step:a=1,smallStep:o=.1,largeStep:s=10,format:c,locale:l,allowOutOfRange:u=!1,readOnly:d=!1,required:f,disabled:p,buttons:m=!1,decrementLabel:h,incrementLabel:g,size:_,onFocus:v,onBlur:b,...x}){let{t:S}=R(),C=st(),w=lt(_,C),T=e!==void 0,[E,D]=(0,V.useState)(t),O=T?e:E,[k,A]=(0,V.useState)(null),j=(0,V.useRef)(O);j.current=O;let ee=(0,V.useMemo)(()=>new Intl.NumberFormat(l,{maximumFractionDigits:20,...c}),[l,c]),M=k??(O==null||Number.isNaN(O)?``:ee.format(O)),N=(0,V.useCallback)(e=>{T||D(e),e!==j.current&&n?.(e),j.current=e},[T,n]),P=e=>{if(d||p)return;let t=O??(e>0?(r??0)-e:(i??0)-e),n=Math.max(yR(e),yR(t)),a=Number((t+e).toFixed(n));A(null),N(u?a:bR(a,r,i))},te=e=>{let t=e.shiftKey?s:e.altKey?o:a;if(e.key===`ArrowUp`)P(t);else if(e.key===`ArrowDown`)P(-t);else if(e.key===`Home`&&r!=null&&!d)A(null),N(r);else if(e.key===`End`&&i!=null&&!d)A(null),N(i);else return;e.preventDefault?.()},F=O!=null&&r!=null&&O<=r,I=O!=null&&i!=null&&O>=i,ne=(0,H.jsx)(j_,{...B(`number-field-input`),...x,size:w,role:`spinbutton`,"aria-valuenow":O??void 0,"aria-valuemin":r,"aria-valuemax":i,"aria-readonly":d||void 0,"aria-required":f||void 0,inputMode:c?.maximumFractionDigits===0?`numeric`:`decimal`,autoComplete:`off`,disabled:p,readOnly:d,value:M,onChangeText:e=>{if(A(e),!e.trim())return N(null);let t=vR(e,l,c);Number.isNaN(t)||N(t)},onFocus:e=>{A(M),v?.(e)},onBlur:e=>{let t=k;if(A(null),t!=null&&t.trim()){let e=vR(t,l,c);Number.isNaN(e)||N(u?e:bR(e,r,i))}b?.(e)},onKeyDown:te});if(!m)return ne;let re=xR[w],ie=e=>()=>P(e);return(0,H.jsxs)(y,{...B(`number-field`),items:`center`,gap:`$1`,width:`100%`,minW:0,children:[(0,H.jsx)(y,{flex:1,minW:0,children:ne}),(0,H.jsx)(W,{...B(`number-field-decrement`),variant:`outline`,size:re,"aria-label":h??S(`Decrease`),tabIndex:-1,disabled:p||!u&&F,...d?{opacity:.5,cursor:`default`,hoverStyle:{bg:`$background`}}:null,onPress:ie(-a),children:(0,H.jsx)(um,{size:16})}),(0,H.jsx)(W,{...B(`number-field-increment`),variant:`outline`,size:re,"aria-label":g??S(`Increase`),tabIndex:-1,disabled:p||!u&&I,...d?{opacity:.5,cursor:`default`,hoverStyle:{bg:`$background`}}:null,onPress:ie(a),children:(0,H.jsx)(hm,{size:16})})]})}var CR=(e,t=!1,n)=>{let[r,i]=(0,V.useState)(t);return[e??r,t=>{e===void 0&&i(t),n?.(t)}]},wR=(0,V.forwardRef)(function({disabled:e,open:t,label:n,children:r,...i},a){let o=(0,V.useContext)(w_),s=st(),c=v_[o?.size??lt(void 0,s)];return(0,H.jsx)(y,{ref:a,...B(`field-segment`),render:`button`,type:`button`,disabled:e,"aria-expanded":!!t,...n?{"aria-label":n}:null,height:c.h-2,marginInlineStart:o?-c.gutter:0,shrink:0,items:`center`,gap:`$1`,px:`$2`,bg:`transparent`,borderWidth:0,borderInlineEndWidth:1,borderColor:`$borderColor`,borderStartStartRadius:`$3`,borderEndStartRadius:`$3`,cursor:e?`not-allowed`:`pointer`,opacity:e?.5:1,hoverStyle:e?void 0:{bg:`$hover`},focusVisibleStyle:{...at,outlineOffset:-2},...i,children:r})}),TR=32;function ER({trigger:e,open:t,onOpenChange:n,options:r,value:i,onPick:o,searchLabel:s,emptyLabel:c,width:l=240}){let{t:u}=R(),d=st(),f=s??u(`Search`);return(0,H.jsxs)(I_,{open:t,onOpenChange:n,placement:`bottom-start`,children:[(0,H.jsx)(L_,{asChild:!0,children:e}),(0,H.jsx)(R_,{"data-slot":`search-list`,p:0,width:l,sideOffset:8,overflow:`hidden`,children:(0,H.jsx)(Lt,{value:d,children:(0,H.jsxs)(fg,{value:i??void 0,children:[(0,H.jsx)(pg,{placeholder:f,"aria-label":f,autoFocus:!0}),(0,H.jsxs)(mg,{p:`$1`,children:[(0,H.jsx)(hg,{children:c??u(`No results`)}),r.map(e=>(0,H.jsxs)(gg,{value:e.value,keywords:[e.label,...e.keywords??[]],disabled:e.disabled,minH:TR,px:`$1`,rounded:`$xs`,...dt(TR,44,`y`),onSelect:e=>o(e),"aria-selected":e.value===i,children:[e.start?(0,H.jsx)(y,{shrink:0,items:`center`,children:e.start}):null,(0,H.jsx)(a,{size:`$2`,color:`$ink`,flex:1,minW:0,numberOfLines:1,children:e.label}),e.end==null?null:(0,H.jsx)(a,{size:`$2`,color:`$hint`,shrink:0,children:e.end}),(0,H.jsx)(Vt,{size:16,opacity:+(e.value===i),shrink:0})]},e.value))]})]})})})]})}var DR=e=>`${e.name} (${e.code})`,OR=e=>[e.name,e.code,e.symbol].filter(Boolean).join(` `);function kR({currencies:e,value:t,defaultValue:n=null,onValueChange:r,placeholder:i=`—`,renderValue:o,getOptionLabel:s=DR,getSearchText:c=OR,selectedFirst:l=!1,closeOnSelect:u=!0,open:d,defaultOpen:f,onOpenChange:p,disabled:m=!1,label:h,searchLabel:g,emptyLabel:_}){let{t:v}=R(),y=h??v(`Currency`),[b,x]=(0,V.useState)(n),S=t===void 0?b:t,[C,w]=CR(d,f,p),T=e.find(e=>e.code===S),E=(l&&T?[T,...e.filter(e=>e!==T)]:e).map(e=>({value:e.code,label:s(e),keywords:[c(e)],disabled:e.disabled,end:e.symbol}));return(0,H.jsx)(ER,{open:C&&!m,onOpenChange:e=>w(!m&&e),options:E,value:S,searchLabel:g??v(`Search currencies`),emptyLabel:_??v(`No currency found`),onPick:e=>{t===void 0&&x(e),e!==S&&r?.(e),u&&w(!1)},trigger:(0,H.jsxs)(wR,{"data-slot":`currency-picker`,disabled:m,open:C,label:T?v(`{label}: {value}`,{label:y,value:T.name}):y,children:[o?o(T):(0,H.jsx)(a,{size:`$2`,fontWeight:`500`,color:`$hint`,children:T?.code??i}),(0,H.jsx)(wp,{size:14,color:`$hint`})]})})}var AR=e=>{let t=e?.trim().toUpperCase();return!t||!/^[A-Z]{2}$/.test(t)?null:String.fromCodePoint(...[...t].map(e=>127462+e.charCodeAt(0)-65))};function jR({iso:e,override:t}){let n=t??AR(e);return(0,H.jsx)(y,{width:16,height:12,rounded:`$2xs`,overflow:`hidden`,items:`center`,justify:`center`,shrink:0,"aria-hidden":!0,children:n==null?(0,H.jsx)(qp,{size:14,color:`$hint`}):typeof n==`string`?(0,H.jsx)(a,{size:`$2`,lineHeight:12,children:n}):n})}function MR({countries:e,value:t,defaultValue:n=null,onValueChange:r,closeOnSelect:i=!0,open:a,defaultOpen:o,onOpenChange:s,disabled:c=!1,label:l,searchLabel:u,emptyLabel:d}){let{t:f}=R(),p=l??f(`Country calling code`),[m,h]=(0,V.useState)(n),g=t===void 0?m:t,[_,v]=CR(a,o,s),b=e.find(e=>e.value===g),x=e.map(e=>({value:e.value,label:e.label,keywords:[e.value,e.callingCode,`+${e.callingCode}`],disabled:e.disabled,start:(0,H.jsx)(y,{paddingInlineEnd:`$1`,children:(0,H.jsx)(jR,{iso:e.value,override:e.flag})}),end:`+${e.callingCode}`}));return(0,H.jsx)(ER,{open:_&&!c,onOpenChange:e=>v(!c&&e),options:x,value:g,searchLabel:u??f(`Search countries`),emptyLabel:d??f(`No country found`),width:280,onPick:e=>{t===void 0&&h(e),e!==g&&r?.(e),i&&v(!1)},trigger:(0,H.jsxs)(wR,{"data-slot":`phone-country-picker`,disabled:c,open:_,gap:`$0.5`,paddingInlineStart:`$2`,paddingInlineEnd:`$1`,children:[(0,H.jsx)(jR,{iso:b?.value,override:b?.flag}),(0,H.jsx)(wp,{size:14,color:`$hint`}),(0,H.jsx)(eu,{children:b?f(`{label}: {country} +{code}`,{label:p,country:b.label,code:b.callingCode}):p})]})})}var NR=`none`,PR=({iso:e,override:t})=>{let n=t??AR(e);return(0,H.jsx)(y,{width:16,height:16,items:`center`,justify:`center`,shrink:0,"aria-hidden":!0,children:n==null?(0,H.jsx)(Ap,{size:16,color:`$hint`}):typeof n==`string`?(0,H.jsx)(a,{size:`$3`,lineHeight:16,children:n}):n})};function FR({countries:e,value:t,defaultValue:n=null,onValueChange:r,label:i,"aria-label":o,noCountryLabel:s,searchLabel:c,noResultsLabel:l,size:u,open:d,defaultOpen:f,onOpenChange:p,disabled:m=!1}){let{t:h}=R(),g=s??h(`No country`),_=st(),v=v_[lt(u,_)],b=(0,V.useId)(),[x,S]=(0,V.useState)(n),C=t===void 0?x:t,[w,T]=CR(d,f,p),E=m||e.length===0,D=e.find(e=>e.value===C),O=[{value:NR,label:g,start:(0,H.jsx)(PR,{})},...e.map(e=>({value:e.value,label:e.label,keywords:[e.value],disabled:e.disabled,start:(0,H.jsx)(PR,{iso:e.value,override:e.flag})}))],k=(0,H.jsxs)(y,{...B(`country-select`),render:`button`,type:`button`,disabled:E,"aria-expanded":w,...i?{"aria-labelledby":b}:o?{"aria-label":o}:null,componentName:`Input`,...b_,..._===`compact`?{bg:`$panel`}:null,minH:v.h,px:v.gutter,width:`100%`,minW:0,items:`center`,gap:`$2`,cursor:E?`not-allowed`:`pointer`,opacity:E?.5:1,borderColor:w?`$borderColorFocus`:`$borderColor`,hoverStyle:E?void 0:{borderColor:`$borderColorHover`},...dt(v.h,44,`y`),children:[(0,H.jsx)(PR,{iso:D?.value,override:D?.flag}),(0,H.jsx)(a,{size:v.font,color:D?`$ink`:`$placeholderColor`,flex:1,minW:0,numberOfLines:1,...nh(`start`),children:D?.label??g}),(0,H.jsx)(wp,{size:16,opacity:.5,shrink:0})]});return(0,H.jsxs)(z,{...B(`country-select-field`),width:`100%`,minW:0,gap:`$1`,children:[i?(0,H.jsx)(a,{id:b,size:`$1`,fontWeight:`600`,color:`$hint`,children:i}):null,(0,H.jsx)(ER,{open:w&&!E,onOpenChange:e=>T(!E&&e),options:O,value:C??NR,searchLabel:c,emptyLabel:l,width:280,onPick:e=>{let n=e===NR?null:e;t===void 0&&S(n),n!==C&&r?.(n),T(!1)},trigger:k})]})}var IR=`appearance`;async function LR(e){return await RR(IR,e)}async function RR(e,{base:t,token:n,signal:r}){if(!(typeof window<`u`&&new URL(t,window.location.origin).origin!==window.location.origin&&!n))try{return(await VR(t,n,{},r))?.[e]}catch{return}}async function zR(e,t){return BR(IR,e,t)}async function BR(e,t,{base:n,token:r,signal:i}){if(typeof window<`u`&&new URL(n,window.location.origin).origin!==window.location.origin&&!r)return!1;try{return!!await VR(n,r,{[e]:t},i)}catch{return!1}}async function VR(e,t,n,r){let i=typeof window<`u`&&new URL(e,window.location.origin).origin!==window.location.origin,a=await fetch(`${e.replace(/\/+$/,``)}/v1/iam/preferences`,{method:`POST`,credentials:t||i?`omit`:`include`,headers:{"Content-Type":`application/json`,...t?{Authorization:`Bearer ${t}`}:{}},body:JSON.stringify(n),signal:r});if(!a.ok)return;let o=await a.json();if(o?.status===`ok`)return o.data??{}}var HR=`hanzo.composer`,UR=`hanzo:composer`;function WR(e){let t=e&&typeof e==`object`?e:{},n={};return(t.send===`enter`||t.send===`mod`)&&(n.send=t.send),typeof t.chips==`boolean`&&(n.chips=t.chips),typeof t.model==`boolean`&&(n.model=t.model),typeof t.mode==`boolean`&&(n.mode=t.mode),n}var GR=()=>{try{return typeof window>`u`?void 0:window.localStorage}catch{return}},KR,qR={},JR=null;function YR(e=GR()){if(JR)return JR;let t=null;try{t=e?.getItem(`hanzo.composer`)??null}catch{t=null}if(t===KR)return qR;KR=t;try{qR=WR(JSON.parse(t??`null`))}catch{qR={}}return qR}function XR(e,t=GR()){let n=WR(e);try{if(!t)throw Error(`no storage`);Object.keys(n).length?t.setItem(HR,JSON.stringify(n)):t.removeItem(HR),JR=null}catch{JR=n}typeof window<`u`&&window.dispatchEvent(new Event(UR))}function ZR(e){return window.addEventListener(UR,e),window.addEventListener(`storage`,e),()=>{window.removeEventListener(UR,e),window.removeEventListener(`storage`,e)}}var zte={};function Bte(){return(0,V.useSyncExternalStore)(ZR,()=>YR(),()=>zte)}async function Vte(e){let t=await RR(`composer`,e);return t===void 0?void 0:WR(t)}function Hte(e,t){return BR(`composer`,WR(e),t)}var QR={"--neutral-50":`#FAFAFA`,"--neutral-100":`#F5F5F5`,"--neutral-200":`#E5E5E5`,"--neutral-300":`#D4D4D4`,"--neutral-400":`#A3A3A3`,"--neutral-500":`#737373`,"--neutral-600":`#525252`,"--neutral-700":`#404040`,"--neutral-800":`#262626`,"--neutral-900":`#171717`,"--neutral-950":`#0A0A0A`,"--pure-black":`#000000`,"--pure-white":`#FFFFFF`,"--hanzo-black":`#0A0A0B`,"--hanzo-white":`#FFFFFF`,"--art-tide":`#2F6BFF`,"--art-iris":`#8B5CF6`,"--art-ember":`#FF7A3D`,"--art-glow":`#F4F1FF`,"--white-03":`rgb(255 255 255 / .03)`,"--white-05":`rgb(255 255 255 / .05)`,"--white-06":`rgb(255 255 255 / .06)`,"--white-08":`rgb(255 255 255 / .08)`,"--white-10":`rgb(255 255 255 / .10)`,"--white-14":`rgb(255 255 255 / .14)`,"--white-15":`rgb(255 255 255 / .15)`,"--white-16":`rgb(255 255 255 / .16)`,"--white-18":`rgb(255 255 255 / .18)`,"--white-20":`rgb(255 255 255 / .20)`,"--white-22":`rgb(255 255 255 / .22)`,"--white-30":`rgb(255 255 255 / .30)`,"--white-40":`rgb(255 255 255 / .40)`,"--white-45":`rgb(255 255 255 / .45)`,"--white-55":`rgb(255 255 255 / .55)`,"--white-60":`rgb(255 255 255 / .60)`,"--white-78":`rgb(255 255 255 / .78)`,"--white-80":`rgb(255 255 255 / .80)`,"--white-92":`rgb(255 255 255 / .92)`,"--background":`#0a0a0a`,"--foreground":`#e5e5e5`,"--card":`#0f0f0f`,"--card-foreground":`#e5e5e5`,"--popover":`#0f0f0f`,"--popover-foreground":`#e5e5e5`,"--primary":`#fafafa`,"--primary-hover":`#e5e5e5`,"--primary-foreground":`#0a0a0a`,"--secondary":`#262626`,"--secondary-hover":`#333333`,"--secondary-foreground":`#fafafa`,"--muted":`#171717`,"--muted-foreground":`#a3a3a3`,"--accent":`#262626`,"--accent-hover":`var(--secondary-hover)`,"--accent-foreground":`#fafafa`,"--destructive":`#dc2626`,"--destructive-hover":`#b91c1c`,"--destructive-foreground":`#fafafa`,"--border":`var(--white-10)`,"--border-strong":`var(--white-16)`,"--border-control":`var(--white-15)`,"--border-focus":`var(--white-22)`,"--border-selected":`var(--white-30)`,"--edge":`var(--white-06)`,"--input":`var(--border-control)`,"--ring":`var(--white-40)`,"--ring-halo":`var(--white-10)`,"--brand":`#e4e4e7`,"--brand-foreground":`#09090b`,"--brand-muted":`#a3a3a3`,"--black":`#000000`,"--white":`#fafafa`,"--selection":`var(--white-20)`,"--glass":`var(--white-05)`,"--glass-strong":`var(--white-08)`,"--surface-page":`var(--background)`,"--surface-card":`rgb(38 38 38 / .5)`,"--surface-card-emphasis":`rgb(38 38 38 / .75)`,"--surface-card-quiet":`rgb(38 38 38 / .35)`,"--surface-overlay":`rgb(23 23 23 / .92)`,"--surface-header":`rgb(0 0 0 / .7)`,"--surface-scrim":`rgb(0 0 0 / .8)`,"--surface-0":`var(--background)`,"--surface-1":`var(--card)`,"--surface-2":`var(--muted)`,"--surface-3":`var(--secondary)`,"--text-primary":`#fafafa`,"--text-secondary":`var(--white-78)`,"--text-tertiary":`var(--white-55)`,"--text-helper":`var(--muted-foreground)`,"--text-disabled":`var(--white-30)`,"--state-error":`#ef4444`,"--state-error-text":`#fca5a5`,"--state-error-bg":`rgb(239 68 68 / .1)`,"--state-online":`#4ade80`,"--state-success":`#22c55e`,"--chrome-dot-red":`rgb(239 68 68 / .6)`,"--chrome-dot-yellow":`rgb(234 179 8 / .6)`,"--chrome-dot-green":`rgb(34 197 94 / .6)`,"--type-scale":`1`,"--type-ratio":`1`,"--text-floor":`0.75rem`,"--text-ceiling":`30vw`,"--text-xs":`0.75rem`,"--leading-xs":`1rem`,"--text-sm":`0.8125rem`,"--leading-sm":`1.15rem`,"--text-base":`0.875rem`,"--leading-base":`1.35rem`,"--text-lg":`0.9375rem`,"--leading-lg":`1.4rem`,"--text-xl":`1.0625rem`,"--leading-xl":`1.55rem`,"--text-2xl":`1.3125rem`,"--leading-2xl":`1.7rem`,"--text-3xl":`1.625rem`,"--leading-3xl":`1.95rem`,"--text-4xl":`2rem`,"--leading-4xl":`2.25rem`,"--text-5xl":`2.5rem`,"--leading-5xl":`1.05`,"--text-6xl":`3.25rem`,"--leading-6xl":`1`,"--text-7xl":`4rem`,"--leading-7xl":`1`,"--text-8xl":`5.25rem`,"--leading-8xl":`1`,"--text-9xl":`7rem`,"--leading-9xl":`1`,"--font-size-xs":`var(--text-xs)`,"--font-size-sm":`var(--text-sm)`,"--font-size-base":`var(--text-base)`,"--font-size-lg":`var(--text-lg)`,"--font-size-xl":`var(--text-xl)`,"--font-size-2xl":`var(--text-2xl)`,"--font-size-3xl":`var(--text-3xl)`,"--font-size-4xl":`var(--text-4xl)`,"--font-size-5xl":`var(--text-5xl)`,"--font-size-6xl":`var(--text-6xl)`,"--font-size-7xl":`var(--text-7xl)`,"--font-size-8xl":`var(--text-8xl)`,"--font-size-9xl":`var(--text-9xl)`,"--text-control":`var(--text-sm)`,"--weight-normal":`400`,"--weight-medium":`500`,"--weight-semibold":`600`,"--weight-bold":`700`,"--tracking-tight":`-0.025em`,"--tracking-normal":`0em`,"--tracking-wide":`0.025em`,"--tracking-widest":`0.1em`,"--leading-none":`1`,"--leading-tight":`1.25`,"--leading-snug":`1.375`,"--leading-normal":`1.5`,"--leading-relaxed":`1.625`,"--leading-golden":`1.618`,"--type-hero":`600 var(--text-5xl)/1.05 var(--font-display)`,"--type-h2":`700 var(--text-4xl)/var(--leading-4xl) var(--font-display)`,"--type-h3":`600 var(--text-xl)/var(--leading-xl) var(--font-display)`,"--type-lead":`400 var(--text-lg)/var(--leading-relaxed) var(--font-sans)`,"--type-body":`400 var(--text-sm)/var(--leading-sm) var(--font-sans)`,"--type-caption":`400 var(--text-xs)/var(--leading-xs) var(--font-sans)`,"--type-code":`400 var(--text-sm)/var(--leading-relaxed) var(--font-mono)`,"--type-eyebrow":`600 0.75rem/1 var(--font-sans)`,"--density":`1`,"--space-0":`0`,"--space-1":`0.25rem`,"--space-2":`0.5rem`,"--space-3":`0.75rem`,"--space-4":`1rem`,"--space-5":`1.25rem`,"--space-6":`1.5rem`,"--space-8":`2rem`,"--space-10":`2.5rem`,"--space-12":`3rem`,"--space-14":`3.5rem`,"--space-16":`4rem`,"--space-20":`5rem`,"--space-24":`6rem`,"--space-32":`8rem`,"--golden-1":`0.25rem`,"--golden-2":`0.405rem`,"--golden-3":`0.654rem`,"--golden-4":`1.059rem`,"--golden-5":`1.713rem`,"--golden-6":`2.772rem`,"--golden-7":`4.487rem`,"--golden-8":`7.26rem`,"--golden-9":`11.749rem`,"--golden-split":`38.2% 61.8%`,"--container-max":`80rem`,"--container-prose":`48rem`,"--container-wide":`72rem`,"--gutter":`max(1rem,var(--safe-left),var(--safe-right))`,"--page-gutter":`clamp(20px,4vw,72px)`,"--gutter-sm":`1.5rem`,"--gutter-lg":`2rem`,"--section-y":`2.5rem`,"--section-y-lg":`3.5rem`,"--hero-y":`3rem`,"--hero-y-lg":`4.5rem`,"--header-height":`3.5rem`,"--header":`0px`,"--dock":`0px`,"--tap-target":`44px`,"--control-height-sm":`32px`,"--control-height":`36px`,"--control-height-lg":`40px`,"--control-height-xl":`52px`,"--safe-top":`env(safe-area-inset-top,0px)`,"--safe-right":`env(safe-area-inset-right,0px)`,"--safe-bottom":`env(safe-area-inset-bottom,0px)`,"--safe-left":`env(safe-area-inset-left,0px)`,"--grid-columns":`12`,"--grid-gap":`var(--space-6)`,"--grid-gap-tight":`var(--space-4)`,"--grid-gap-loose":`var(--space-8)`,"--breakpoint-sm":`40rem`,"--breakpoint-md":`48rem`,"--breakpoint-lg":`64rem`,"--breakpoint-xl":`80rem`,"--breakpoint-2xl":`96rem`,"--grid-card-min":`18rem`,"--grid-card-min-wide":`24rem`,"--radius-scale":`1`,"--radius":`calc(0.5rem * var(--radius-scale, 1))`,"--radius-sm":`calc(0.375rem * var(--radius-scale, 1))`,"--radius-md":`calc(0.5rem * var(--radius-scale, 1))`,"--radius-lg":`calc(0.75rem * var(--radius-scale, 1))`,"--radius-xl":`calc(1rem * var(--radius-scale, 1))`,"--radius-2xl":`calc(1.5rem * var(--radius-scale, 1))`,"--radius-composer":`calc(28px * var(--radius-scale, 1))`,"--radius-full":`9999px`,"--shadow-none":`none`,"--shadow-floating":`0 24px 60px -16px rgb(0 0 0 / .75)`,"--shadow-inset-hairline":`inset 0 0 0 1px var(--white-10)`,"--edge-highlight":`inset 0 1px 0 0 rgb(255 255 255 / .10)`,"--bloom":`0 0 24px -2px rgb(255 255 255 / .28)`,"--ring-focus":`0 0 0 3px var(--ring-halo)`,"--shadow-sm":`0 1px 2px 0 rgb(0 0 0 / .40)`,"--shadow":`0 1px 3px 0 rgb(0 0 0 / .45), 0 1px 2px -1px rgb(0 0 0 / .45)`,"--shadow-md":`0 4px 6px -1px rgb(0 0 0 / .50), 0 2px 4px -2px rgb(0 0 0 / .50)`,"--shadow-lg":`0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)`,"--shadow-xl":`0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)`,"--shadow-2xl":`var(--shadow-floating)`,"--sheet-0":`var(--surface-page)`,"--sheet-1":`var(--surface-card)`,"--sheet-2":`var(--surface-card-emphasis)`,"--shadow-sheet-1":`var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)`,"--shadow-sheet-2":`var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)`,"--fold":`12px`,"--fold-face":`linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))`,"--glow-hero":`radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)`,"--glow-hero-blur":`120px`,"--sheen-card":`radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)`,"--sheen-edge":`linear-gradient(90deg,transparent,rgb(255 255 255 / .14) 50%,transparent)`,"--gradient-chrome":`linear-gradient(to right,#ffffff,var(--white-80),var(--white-60))`,"--gradient-chrome-2":`linear-gradient(to right,#ffffff,var(--neutral-500))`,"--gradient-protect":`linear-gradient(to bottom,var(--white-10),transparent)`,"--chrome":`rgb(9 9 11 / .72)`,"--chrome-blur":`blur(20px) saturate(1.8)`,"--chrome-panel":`var(--popover)`,"--pane-blur":`var(--chrome-blur)`,"--pane-edge":`var(--white-08)`,"--pane-round":`var(--radius-xl)`,"--pane-fill":`var(--sheet-1)`,"--pane-solid":`color-mix(in srgb,var(--neutral-800) 50%,var(--background))`,"--pane-floor":`var(--background)`,"--pane-gap":`var(--space-2)`,"--pane-ground":`radial-gradient(80rem 40rem at 12% -10%,rgb(255 255 255 / .035),transparent 60%),radial-gradient(60rem 34rem at 92% 108%,var(--white-03),transparent 60%)`,"--duration-fast":`150ms`,"--duration-base":`300ms`,"--duration-slow":`400ms`,"--duration-slower":`500ms`,"--duration-glow":`9s`,"--duration-press":`90ms`,"--ease-out":`cubic-bezier(0,0,0.2,1)`,"--ease-in-out":`cubic-bezier(0.4,0,0.2,1)`,"--ease-emphasis":`cubic-bezier(0.16,1,0.3,1)`,"--stagger":`60ms`,"--entry-rise":`16px`,"--entry-rise-lg":`24px`,"--z-base":`0`,"--z-raised":`10`,"--z-sticky":`200`,"--z-header":`300`,"--z-dropdown":`400`,"--z-overlay":`500`,"--z-modal":`600`,"--z-popover":`700`,"--z-toast":`800`,"--z-under":`-10`,"--z-panel":`18`,"--z-scrim":`19`,"--z-drawer":`20`,"--z-sheet":`30`,"--z-dock":`40`,"--z-banner":`50`,"--z-tooltip":`var(--z-popover)`,"--z-notification":`var(--z-toast)`,"--font-arabic-kufi":`"Noto Kufi Arabic"`,"--font-arabic-sans":`"Noto Sans Arabic"`,"--font-arabic-plex":`"IBM Plex Sans Arabic"`,"--font-arabic":`var(--font-arabic-kufi)`,"--font-sans":`var(--font-arabic), Zen, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif`,"--font-display":`var(--font-sans)`,"--font-mono":`var(--font-arabic), Zen Mono, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace`,"--font-serif":`var(--font-arabic), Georgia, serif`,"--font-feature-settings":`normal`,"--ring-offset":`-2px`},Ute=.85,Wte=1.4,Gte=.75,Kte=1.5,qte=1.05,Jte=[`2xl`,`3xl`,`4xl`,`5xl`,`6xl`,`7xl`,`8xl`,`9xl`],Yte=1.0625,$R={compact:.85,default:1,comfortable:1.15},Xte={system:`ui-sans-serif, system-ui, -apple-system, sans-serif`,serif:`var(--font-serif)`,mono:`var(--font-mono)`},Zte={kufi:`var(--font-arabic-kufi)`,sans:`var(--font-arabic-sans)`,plex:`var(--font-arabic-plex)`},Qte={narrow:{max:`64rem`,prose:`40rem`,wide:`58rem`},wide:{max:`96rem`,prose:`56rem`,wide:`86rem`}},$te={sharp:.5,round:1.5},ez=(e,t,n)=>Math.min(n,Math.max(t,e)),tz=e=>String(Math.round(e*1e4)/1e4);function ene(e){let t=e.trim();return!t||t.length>64||/[;{}()]/.test(t)&&!/^(rgb|rgba|hsl|hsla|oklch|oklab|lab|lch|color)\([^;{}]*\)$/i.test(t)?!1:/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i.test(t)||/^(rgb|rgba|hsl|hsla|oklch|oklab|lab|lch|color)\([^;{}]*\)$/i.test(t)||/^[a-z]{3,20}$/i.test(t)}var nz=QR[`--primary-foreground`],rz=QR[`--primary`],iz=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4,az=(e,t,n)=>.2126*iz(e)+.7152*iz(t)+.0722*iz(n),oz=(e,t)=>{let n=parseFloat(e);return e.trim().endsWith(`%`)?n/100*t:n};function sz(e){let t=e.trim().toLowerCase(),n=/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/.exec(t);if(n){let e=n[1],t=e.length<=4?[...e.slice(0,3)].map(e=>e+e).join(``):e.slice(0,6),[r,i,a]=[0,2,4].map(e=>parseInt(t.slice(e,e+2),16)/255);return az(r,i,a)}let r=/^(rgba?|hsla?|oklch|oklab)\(([^)]*)\)$/.exec(t);if(!r)return;let i=r[2].split(/[\s,/]+/).filter(Boolean);if(!(i.length<3||i.slice(0,3).some(e=>!Number.isFinite(parseFloat(e))))){if(r[1].startsWith(`rgb`)){let[e,t,n]=i.slice(0,3).map(e=>ez(oz(e,255),0,255)/255);return az(e,t,n)}if(r[1].startsWith(`hsl`)){let e=(parseFloat(i[0])%360+360)%360,t=ez(oz(i[1],1),0,1),n=ez(oz(i[2],1),0,1),r=t=>(t+e/30)%12,a=t*Math.min(n,1-n),o=e=>n-a*Math.max(-1,Math.min(r(e)-3,9-r(e),1));return az(o(0),o(8),o(4))}return ez(oz(i[0],1),0,1)**3}}var cz=(e,t)=>(Math.max(e,t)+.05)/(Math.min(e,t)+.05);function tne(e){let t=sz(e);if(t===void 0)return;let n=sz(nz)??0,r=sz(rz)??1;return cz(t,n)>=cz(t,r)?nz:rz}function nne(e){let t={};if(typeof e.type==`number`&&Number.isFinite(e.type)&&(t[`--type-scale`]=tz(ez(e.type,Ute,Wte))),typeof e.ratio==`number`&&Number.isFinite(e.ratio)&&(t[`--type-ratio`]=tz(ez(e.ratio,Gte,Kte))),typeof e.modular==`number`&&Number.isFinite(e.modular)){let n=ez(e.modular,qte,2);Jte.forEach((e,r)=>{let i=Yte*n**+(r+1);t[`--text-${e}`]=`clamp(var(--text-floor), calc(${tz(i)}rem * var(--type-scale, 1)), var(--text-ceiling))`})}e.density&&e.density in $R&&(t[`--density`]=tz($R[e.density]));let n=e.font?Xte[e.font]:void 0;n&&(t[`--font-sans`]=n);let r=e.arabic?Zte[e.arabic]:void 0;r&&(t[`--font-arabic`]=r);let i=e.width?Qte[e.width]:void 0;i&&(t[`--container-max`]=i.max,t[`--container-prose`]=i.prose,t[`--container-wide`]=i.wide);let a=e.radius?$te[e.radius]:void 0;a&&(t[`--radius-scale`]=tz(a));let o=e.accent&&ene(e.accent)?e.accent.trim():void 0,s=o?tne(o):void 0;if(o&&s){let e=`color-mix(in oklab, ${o} 85%, ${s})`;t[`--primary`]=o,t[`--primary-foreground`]=s,t[`--primary-hover`]=e,t[`--accent`]=o,t[`--accent-foreground`]=s,t[`--accent-hover`]=e}return t}var rne=[`install`,`org`,`user`,`userOrg`],ine=[`type`,`ratio`,`modular`,`density`,`font`,`arabic`,`width`,`accent`,`highlight`,`background`,`contrast`,`theme`,`radius`];function ane(e){let t={},n={};for(let r of ine)for(let i of rne){let a=e[i]?.[r];a!=null&&a!==``&&(t[r]=a,n[r]=i)}return{pref:t,from:n}}var lz=e=>e===`org`?`userOrg`:`user`,uz=/^(#[0-9a-fA-F]{3,8}|(?:rgb|hsl|oklch|oklab|lab|lch)a?\(\s*[-+0-9.%deg\s,/]+\)|[a-zA-Z]{3,20})$/;function dz(e){let t=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/.exec(e);if(!t)return`#fafafa`;let n=t[1].length===3?t[1].replace(/./g,`$&$&`):t[1].slice(0,6),[r,i,a]=[0,2,4].map(e=>{let t=parseInt(n.slice(e,e+2),16)/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4});return .2126*r+.7152*i+.0722*a>.179?`#09090b`:`#fafafa`}var fz={oled:{"--background":`#000000`,"--foreground":`#fafafa`,"--text-primary":`#fafafa`,"--pane-floor":`#000000`,"--pane-fill":`#050505`,"--card":`#080808`,"--surface-card":`#080808`,"--card-foreground":`#fafafa`,"--popover":`#080808`,"--popover-foreground":`#fafafa`,"--muted":`#0d0d0d`,"--secondary":`#161616`,"--secondary-hover":`#1f1f1f`,"--secondary-foreground":`#fafafa`,"--composer-fill":`#111111`,"--composer-ground":`#111111`},soft:{"--background":`#181818`,"--foreground":`#fafafa`,"--text-primary":`#fafafa`,"--pane-floor":`#131312`,"--pane-fill":`#1c1c1b`,"--card":`#20201f`,"--surface-card":`#20201f`,"--card-foreground":`#fafafa`,"--popover":`#20201f`,"--popover-foreground":`#fafafa`,"--muted":`#252523`,"--secondary":`#2e2e2c`,"--secondary-hover":`#383835`,"--secondary-foreground":`#fafafa`,"--composer-fill":`#272725`,"--composer-ground":`#272725`},high:{"--background":`#000000`,"--foreground":`#ffffff`,"--text-primary":`#ffffff`,"--pane-floor":`#000000`,"--pane-fill":`#060606`,"--card":`#0a0a0a`,"--surface-card":`#0a0a0a`,"--card-foreground":`#ffffff`,"--popover":`#0a0a0a`,"--popover-foreground":`#ffffff`,"--muted":`#121212`,"--secondary":`#1f1f1f`,"--secondary-hover":`#292929`,"--secondary-foreground":`#ffffff`,"--composer-fill":`#141414`,"--composer-ground":`#141414`,"--border":`rgb(255 255 255 / .18)`}};function one(e){if(e.background!==void 0){let t=e.background.trim();if(uz.test(t))return dz(t)===`#09090b`?`light`:`dark`}return e.contrast&&e.contrast in fz?`dark`:e.theme}function pz(e){let t=(e??``).trim().toLowerCase(),n=(e,t=245,n=335)=>(e%360+360)%360>=t&&(e%360+360)%360<=n,r=(e,t,r)=>{let i=Math.max(e,t,r),a=i-Math.min(e,t,r);if(a<=.15)return!1;let o=i===e?(t-r)/a%6:i===t?(r-e)/a+2:(e-t)/a+4;return n(o*60)},i=/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/.exec(t);if(i){let e=i[1],t=e.length<=4?[...e.slice(0,3)].map(e=>e+e).join(``):e.slice(0,6),[n,a,o]=[0,2,4].map(e=>parseInt(t.slice(e,e+2),16)/255);return r(n,a,o)}let a=/^(rgba?|hsla?|oklch)\(([^)]*)\)$/.exec(t);if(!a)return!1;let o=a[2].split(/[\s,/]+/).filter(Boolean),s=(e,t)=>o[e]?.endsWith(`%`)?parseFloat(o[e])/100*t:parseFloat(o[e]);return o.length<3||[0,1,2].some(e=>!Number.isFinite(s(e,1)))?!1:a[1].startsWith(`rgb`)?r(s(0,255)/255,s(1,255)/255,s(2,255)/255):a[1].startsWith(`hsl`)?n(s(0,360))&&s(1,1)/(o[1].endsWith(`%`)?1:100)>.2:n(s(2,360),272,340)&&s(1,1)>.04}function mz(e){let t={...e};return pz(t.accent)&&delete t.accent,pz(t.highlight)&&delete t.highlight,t}function hz(e){let t=mz(e),n={...nne(t)};if(t.contrast&&t.contrast in fz&&Object.assign(n,fz[t.contrast]),t.background!==void 0){let e=t.background.trim();if(uz.test(e)){let t=dz(e),r=t===`#09090b`?`black`:`white`;n[`--background`]=e,n[`--foreground`]=t,n[`--text-primary`]=t,n[`--pane-floor`]=`color-mix(in oklch, ${e} 95%, black)`,n[`--pane-fill`]=`color-mix(in oklch, ${e} 97%, ${r})`,n[`--card`]=`color-mix(in oklch, ${e} 95%, ${r})`,n[`--surface-card`]=`color-mix(in oklch, ${e} 95%, ${r})`,n[`--card-foreground`]=t,n[`--popover`]=`color-mix(in oklch, ${e} 92%, ${r})`,n[`--popover-foreground`]=t,n[`--muted`]=`color-mix(in oklch, ${e} 92%, ${r})`,n[`--secondary`]=`color-mix(in oklch, ${e} 90%, ${r})`,n[`--secondary-hover`]=`color-mix(in oklch, ${e} 84%, ${r})`,n[`--secondary-foreground`]=t,n[`--composer-fill`]=`color-mix(in oklch, ${e} 90%, ${r})`,n[`--composer-ground`]=`color-mix(in oklch, ${e} 90%, ${r})`}}if(t.highlight!==void 0){let e=t.highlight.trim();uz.test(e)&&(n[`--highlight`]=e,n[`--selection`]=`color-mix(in oklab, ${e} 28%, transparent)`,n[`--ring`]=`color-mix(in oklab, ${e} 55%, transparent)`,n[`--ring-halo`]=`color-mix(in oklab, ${e} 18%, transparent)`,n[`--border-focus`]=`color-mix(in oklab, ${e} 50%, transparent)`,n[`--border-selected`]=`color-mix(in oklab, ${e} 65%, transparent)`)}return n}var gz=`hanzo.appearance`,_z=(e,t)=>e===`org`&&t?`${gz}@${t}`:gz,sne={type:1,density:`default`},vz=()=>typeof document<`u`,yz=[`kufi`,`sans`,`plex`];function cne(e=vz()?document.documentElement:void 0){if(!e)return;let t=getComputedStyle(e),n=t.getPropertyValue(`--font-arabic`).trim();return n?yz.find(e=>t.getPropertyValue(`--font-arabic-${e}`).trim()===n):void 0}function bz({scope:e=`everywhere`,org:t,store:n=Ez()}={}){try{let r=n?.getItem(_z(e,t));if(!r)return{};let i=JSON.parse(r);return!i||typeof i!=`object`?{}:{...typeof i.type==`number`&&Number.isFinite(i.type)?{type:i.type}:{},...typeof i.ratio==`number`&&Number.isFinite(i.ratio)?{ratio:i.ratio}:{},...typeof i.modular==`number`&&Number.isFinite(i.modular)?{modular:i.modular}:{},...i.density===`compact`||i.density===`comfortable`||i.density==="default"?{density:i.density}:{},...i.font==="default"||i.font===`system`||i.font===`serif`||i.font===`mono`?{font:i.font}:{},...i.arabic==="default"||yz.includes(i.arabic)?{arabic:i.arabic}:{},...i.width===`narrow`||i.width==="default"||i.width===`wide`?{width:i.width}:{},...typeof i.accent==`string`&&!pz(i.accent)?{accent:i.accent}:{},...typeof i.highlight==`string`&&!pz(i.highlight)?{highlight:i.highlight}:{},...typeof i.background==`string`?{background:i.background}:{},...i.contrast===`oled`||i.contrast===`soft`||i.contrast===`high`?{contrast:i.contrast}:{},...i.theme===`system`||i.theme===`light`||i.theme===`dark`?{theme:i.theme}:{},...i.radius===`sharp`||i.radius==="default"||i.radius===`round`?{radius:i.radius}:{}}}catch{return{}}}function lne({org:e,store:t=Ez()}={}){return{user:bz({scope:`everywhere`,store:t}),...e?{userOrg:bz({scope:`org`,org:e,store:t})}:{}}}var xz=`hanzo:appearance`;function Sz(e,{scope:t=`everywhere`,org:n,store:r=Ez()}={}){try{return r?.setItem(_z(t,n),JSON.stringify(mz(e))),typeof window<`u`&&typeof Event==`function`&&window.dispatchEvent(new Event(xz)),!!r}catch{return!1}}function Cz(e,t=vz()?document.documentElement:void 0,{store:n=Ez()}={}){if(!t)return;let r=hz(e);for(let e of pne){let n=r[e];n?t.style.setProperty(e,n):t.style.removeProperty(e)}let i=one(e);if(wz(i,t),vz()&&t===document.documentElement){fne(i);try{n?.setItem(une,JSON.stringify({vars:r,...i?{theme:i}:{}}))}catch{}}}var une=`${gz}.painted.v2`,dne=e=>e===`dark`||e===`system`&&typeof matchMedia==`function`&&matchMedia(`(prefers-color-scheme: dark)`).matches;function wz(e,t){if(!e&&!t.hasAttribute(`data-scheme`))return;let n=!e||dne(e);t.classList.toggle(`light`,!n),t.classList.toggle(`dark`,n),t.classList.toggle(`t_light`,!n),t.classList.toggle(`t_dark`,n),t.style.colorScheme=n?`dark`:`light`,e?t.setAttribute(`data-scheme`,e):t.removeAttribute(`data-scheme`)}var Tz;function fne(e){if(e===`system`){if(Tz||typeof matchMedia!=`function`)return;let e=matchMedia(`(prefers-color-scheme: dark)`),t=()=>wz(`system`,document.documentElement);e.addEventListener?.(`change`,t),Tz={query:e,on:t}}else Tz&&=(Tz.query.removeEventListener?.(`change`,Tz.on),void 0)}var pne=Object.keys(hz({type:1,ratio:1,modular:1.25,density:`compact`,font:`serif`,arabic:`sans`,width:`wide`,accent:`#000`,highlight:`#000`,background:`#000`,contrast:`high`,radius:`round`}));function mne({install:e,org:t,orgId:n,store:r}={}){return ane({install:e,org:t,...lne({org:n,store:r})})}function Ez(){try{return typeof localStorage<`u`?localStorage:void 0}catch{return}}var hne=[{label:`S`,title:`Small`,value:.9},{label:`M`,title:`Default`,value:1},{label:`L`,title:`Large`,value:1.15},{label:`XL`,title:`Larger`,value:1.3}],gne=[{label:`Flat`,title:`Sizes sit close together — dense screens`,value:.85},{label:`Default`,title:`The published scale`,value:1},{label:`Airy`,title:`Headings lead further — reading pages`,value:1.2}],_ne=[{label:`Default`,title:`The authored ramp — tuned, not generated`},{label:`Minor 3rd`,title:`A gentle scale (1.2)`,value:1.2},{label:`Major 3rd`,title:`What this ramp already approximates (1.25)`,value:1.25},{label:`4th`,title:`A perfect fourth (1.333) — strong headings`,value:1.3333},{label:`Golden`,title:`The golden ratio (1.618) — display-first`,value:1.618}],vne=[{label:`Tight`,value:`compact`},{label:`Default`,value:`default`},{label:`Roomy`,value:`comfortable`}],yne=[{label:`Sans`,value:`default`},{label:`System`,value:`system`,preview:`ui-sans-serif, system-ui`},{label:`Serif`,value:`serif`,preview:`var(--font-serif)`},{label:`Mono`,value:`mono`,preview:`var(--font-mono)`}],bne=[{label:`Kufi`,value:`kufi`},{label:`Sans`,value:`sans`},{label:`Plex`,value:`plex`}],xne=`عربي`,Sne=[{label:`Narrow`,value:`narrow`},{label:`Default`,value:`default`},{label:`Wide`,value:`wide`}],Cne=[{label:`System`,value:`system`},{label:`Light`,value:`light`},{label:`Dark`,value:`dark`}],wne=[{label:`Sharp`,value:`sharp`},{label:`Default`,value:`default`},{label:`Round`,value:`round`}],Tne=()=>document.documentElement.classList.contains(`light`)?`light`:`dark`;function Ene(e){let t=new MutationObserver(e);return t.observe(document.documentElement,{attributes:!0,attributeFilter:[`class`]}),()=>t.disconnect()}function Dz(){return(0,V.useSyncExternalStore)(Ene,Tne,()=>`dark`)}var Oz=[{label:`Default`},{label:`Olive`,value:`#808000`},{label:`Blue`,value:`#3b82f6`},{label:`Emerald`,value:`#10b981`},{label:`Rose`,value:`#f43f5e`},{label:`Amber`,value:`#f59e0b`}],kz=[{label:`Default`},{label:`Blue`,value:`#3b82f6`},{label:`Cyan`,value:`#06b6d4`},{label:`Emerald`,value:`#10b981`},{label:`Amber`,value:`#f59e0b`},{label:`Rose`,value:`#f43f5e`}],Dne=[{label:`Deep`,title:`Deep black — rich dark ground with warm-neutral contrast (default)`},{label:`OLED`,title:`Pure black — #000000 floor for OLED displays`,value:`oled`},{label:`Soft`,title:`Soft charcoal — warmer, lifted dark surfaces`,value:`soft`},{label:`High`,title:`High contrast — pure black ground, bright ink and stronger hairlines`,value:`high`}],Az=[{label:`Default`},{label:`Pure Black`,value:`#000000`},{label:`Obsidian`,value:`#0a0a0f`},{label:`Midnight`,value:`#090d16`},{label:`Forest`,value:`#07120e`},{label:`Espresso`,value:`#120d0a`},{label:`Paper`,value:`#faf8f5`}];function jz({org:e,install:t,orgPref:n,account:r}={}){let[i,a]=(0,V.useState)(sne),[o,s]=(0,V.useState)({}),[c,l]=(0,V.useState)(`everywhere`),u=(0,V.useCallback)((r=c)=>{let i=mne({install:t,org:n,orgId:e});return a(i.pref),s(i.from),Cz(i.pref),l(r),i},[t,n,e,c]);return(0,V.useEffect)(()=>{u()},[e,t,n]),(0,V.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>u();return window.addEventListener(xz,e),window.addEventListener(`storage`,e),()=>{window.removeEventListener(xz,e),window.removeEventListener(`storage`,e)}},[u]),(0,V.useEffect)(()=>{if(!r)return;let e=!0;return LR(r).then(t=>{e&&t&&(Sz(t,{scope:`everywhere`}),u())}),Vte(r).then(t=>{e&&t&&XR(t)}),()=>{e=!1}},[r?.base,r?.token]),{pref:i,set:(0,V.useCallback)(t=>{let n={...t};pz(n.accent)&&delete n.accent,pz(n.highlight)&&delete n.highlight;let i={...bz({scope:c,org:e}),...n};`accent`in n&&n.accent===void 0&&delete i.accent,`highlight`in n&&n.highlight===void 0&&delete i.highlight,`background`in n&&n.background===void 0&&delete i.background,`contrast`in n&&n.contrast===void 0&&delete i.contrast,Sz(i,{scope:c,org:e}),u(),r&&c===`everywhere`&&zR(i,r)},[c,e,u,r]),reset:(0,V.useCallback)(()=>{Sz({},{scope:c,org:e}),u(),r&&c===`everywhere`&&zR({},r)},[c,e,u,r]),scope:c,setScope:e=>u(e),from:o,layer:lz(c)}}var Mz={panel:{display:`flex`,flexDirection:`column`},row:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:`var(--space-3)`,minHeight:40,paddingBlock:`var(--space-2)`,flexWrap:`wrap`},label:{fontSize:`var(--text-sm)`,color:`var(--foreground)`,whiteSpace:`nowrap`},note:{fontSize:`var(--text-xs)`,lineHeight:`var(--leading-xs)`,color:`var(--muted-foreground, var(--foreground))`,opacity:.6,margin:0},track:{display:`inline-flex`,alignItems:`center`,gap:2,padding:2,borderRadius:`var(--radius-full)`,background:`var(--secondary, rgb(255 255 255 / .06))`},swatch:e=>({width:14,height:14,borderRadius:`var(--radius-full)`,background:e??`var(--foreground)`,opacity:e?1:.35,flex:`0 0 auto`})},Nz=e=>({display:`inline-flex`,alignItems:`center`,justifyContent:`center`,gap:`var(--space-1)`,height:24,padding:`0 var(--space-2)`,borderRadius:`var(--radius-full)`,border:`1px solid transparent`,background:e?`var(--surface-card, rgb(255 255 255 / .10))`:`transparent`,color:e?`var(--foreground)`:`var(--muted-foreground, var(--foreground))`,opacity:e?1:.7,fontSize:`var(--text-xs)`,fontFamily:`inherit`,cursor:`pointer`});function Pz({on:e,onSelect:t,children:n,title:r,style:i}){return(0,H.jsx)(`button`,{type:`button`,"aria-pressed":e,onClick:t,title:r,"aria-label":r,style:{...Nz(e),...i},children:n})}function Fz({label:e,children:t,by:n,scope:r,org:i}){let a=n&&n!==lz(r??`everywhere`)?n===`org`?`Set by ${i||`your organization`}`:n===`install`?`A default for this install`:n===`user`?`Your setting for everywhere`:`Your setting for ${i||`this organization`}`:null;return(0,H.jsxs)(`div`,{style:Mz.row,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:Mz.label,children:e}),a?(0,H.jsx)(`p`,{style:Mz.note,children:a}):null]}),(0,H.jsx)(`div`,{style:Mz.track,children:t})]})}function One({org:e,orgName:t,install:n,orgPref:r,account:i}={}){let{pref:a,set:o,reset:s,scope:c,setScope:l,from:u}=jz({org:e,install:n,orgPref:r,account:i}),d=a.type??1,f=a.ratio??1,p=(e,t)=>Math.abs(e-t)<.001,m=Dz(),h=d!==1||f!==1||a.modular!==void 0||(a.density??`default`)!=="default"||(a.font??`default`)!=="default"||(a.arabic??`default`)!=="default"||(a.width??`default`)!=="default"||!!a.accent||!!a.highlight||!!a.background||!!a.contrast||!!a.theme||(a.radius??`default`)!=="default",g=t||e;return(0,H.jsxs)(`div`,{style:Mz.panel,children:[e?(0,H.jsxs)(Fz,{label:`Applies to`,children:[(0,H.jsx)(Pz,{on:c===`everywhere`,onSelect:()=>l(`everywhere`),children:`Everywhere`}),(0,H.jsx)(Pz,{on:c===`org`,onSelect:()=>l(`org`),children:g})]}):null,(0,H.jsx)(Fz,{label:`Theme`,by:u.theme,scope:c,org:g,children:Cne.map(e=>(0,H.jsx)(Pz,{on:(a.theme??m)===e.value,onSelect:()=>o({theme:e.value,...a.background===void 0?{}:{background:void 0},...a.contrast===void 0?{}:{contrast:void 0}}),children:e.label},e.value))}),(0,H.jsx)(Fz,{label:`Contrast`,by:u.contrast,scope:c,org:g,children:Dne.map(e=>(0,H.jsx)(Pz,{on:a.contrast===e.value,onSelect:()=>o({contrast:e.value,...e.value&&a.background!==void 0?{background:void 0}:{}}),title:e.title,children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Text size`,by:u.type,scope:c,org:g,children:hne.map(e=>(0,H.jsx)(Pz,{on:p(d,e.value),onSelect:()=>o({type:e.value}),title:e.title,children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Scale`,by:u.ratio,scope:c,org:g,children:gne.map(e=>(0,H.jsx)(Pz,{on:p(f,e.value),onSelect:()=>o({ratio:e.value}),title:e.title,children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Scale system`,by:u.modular,scope:c,org:g,children:_ne.map(e=>(0,H.jsx)(Pz,{on:e.value===void 0?a.modular===void 0:Math.abs((a.modular??0)-e.value)<.001,onSelect:()=>o({modular:e.value}),title:e.title,children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Spacing`,by:u.density,scope:c,org:g,children:vne.map(e=>(0,H.jsx)(Pz,{on:(a.density??`default`)===e.value,onSelect:()=>o({density:e.value}),children:e.label},e.value))}),(0,H.jsx)(Fz,{label:`Font`,by:u.font,scope:c,org:g,children:yne.map(e=>(0,H.jsx)(Pz,{on:(a.font??`default`)===e.value,onSelect:()=>o({font:e.value}),style:{fontFamily:e.preview},children:e.label},e.value))}),(0,H.jsx)(Fz,{label:`Arabic`,by:u.arabic,scope:c,org:g,children:bne.map(e=>(0,H.jsxs)(Pz,{on:(a.arabic&&a.arabic!=="default"?a.arabic:cne())===e.value,onSelect:()=>o({arabic:e.value}),title:`Arabic in ${e.label}`,style:{fontFamily:`var(--font-arabic-${e.value}), var(--font-sans)`},children:[e.label,` `,(0,H.jsx)(`span`,{lang:`ar`,dir:`rtl`,children:xne})]},e.value))}),(0,H.jsx)(Fz,{label:`Width`,by:u.width,scope:c,org:g,children:Sne.map(e=>(0,H.jsx)(Pz,{on:(a.width??`default`)===e.value,onSelect:()=>o({width:e.value}),children:e.label},e.value))}),(0,H.jsx)(Fz,{label:`Corners`,by:u.radius,scope:c,org:g,children:wne.map(e=>(0,H.jsx)(Pz,{on:(a.radius??`default`)===e.value,onSelect:()=>o({radius:e.value}),children:e.label},e.value))}),(0,H.jsxs)(Fz,{label:`Accent`,by:u.accent,scope:c,org:g,children:[Oz.map(e=>(0,H.jsx)(Pz,{on:a.accent===e.value,onSelect:()=>o({accent:e.value}),title:e.label,children:(0,H.jsx)(`span`,{style:Mz.swatch(e.value)})},e.label)),(0,H.jsxs)(`label`,{title:`Custom accent color`,style:{...Nz(!(!a.accent||Oz.some(e=>e.value===a.accent))),position:`relative`,overflow:`hidden`},children:[(0,H.jsx)(`span`,{style:{...Mz.swatch(a.accent),border:`1px solid rgb(255 255 255 / .25)`}}),(0,H.jsx)(`input`,{type:`color`,"aria-label":`Custom accent color`,value:a.accent&&/^#[0-9a-fA-F]{6}$/.test(a.accent)?a.accent:`#3b82f6`,onChange:e=>o({accent:e.target.value}),style:{position:`absolute`,inset:0,opacity:0,cursor:`pointer`,width:`100%`,height:`100%`,border:0,padding:0}})]})]}),(0,H.jsxs)(Fz,{label:`Highlight`,by:u.highlight,scope:c,org:g,children:[kz.map(e=>(0,H.jsx)(Pz,{on:a.highlight===e.value,onSelect:()=>o({highlight:e.value}),title:`Highlight: ${e.label}`,children:(0,H.jsx)(`span`,{style:Mz.swatch(e.value)})},e.label)),(0,H.jsxs)(`label`,{title:`Custom highlight color`,style:{...Nz(!(!a.highlight||kz.some(e=>e.value===a.highlight))),position:`relative`,overflow:`hidden`},children:[(0,H.jsx)(`span`,{style:{...Mz.swatch(a.highlight),border:`1px solid rgb(255 255 255 / .25)`}}),(0,H.jsx)(`input`,{type:`color`,"aria-label":`Custom highlight color`,value:a.highlight&&/^#[0-9a-fA-F]{6}$/.test(a.highlight)?a.highlight:`#ffffff`,onChange:e=>o({highlight:e.target.value}),style:{position:`absolute`,inset:0,opacity:0,cursor:`pointer`,width:`100%`,height:`100%`,border:0,padding:0}})]})]}),(0,H.jsxs)(Fz,{label:`Background`,by:u.background,scope:c,org:g,children:[Az.map(e=>(0,H.jsx)(Pz,{on:a.background===e.value,onSelect:()=>o({background:e.value}),title:e.label,children:(0,H.jsx)(`span`,{style:{...Mz.swatch(e.value),border:e.value?`1px solid rgb(255 255 255 / .2)`:void 0}})},e.label)),(0,H.jsxs)(`label`,{title:`Custom background color`,style:{...Nz(!(!a.background||Az.some(e=>e.value===a.background))),position:`relative`,overflow:`hidden`},children:[(0,H.jsx)(`span`,{style:{...Mz.swatch(a.background),border:`1px solid rgb(255 255 255 / .25)`}}),(0,H.jsx)(`input`,{type:`color`,"aria-label":`Custom background color`,value:a.background&&/^#[0-9a-fA-F]{6}$/.test(a.background)?a.background:`#0a0a0f`,onChange:e=>o({background:e.target.value}),style:{position:`absolute`,inset:0,opacity:0,cursor:`pointer`,width:`100%`,height:`100%`,border:0,padding:0}})]})]}),(0,H.jsx)(kne,{account:i}),h?(0,H.jsx)(`div`,{style:{...Mz.row,justifyContent:`flex-end`},children:(0,H.jsx)(`button`,{type:`button`,onClick:s,style:{...Nz(!1),opacity:.8},children:c===`org`?`Reset for ${g}`:`Reset`})}):null]})}var Iz=[{label:`Auto`},{label:`Show`,value:!0},{label:`Hide`,value:!1}];function kne({account:e}){let t=Bte(),n=n=>{let r={...t,...n};for(let e of Object.keys(n))n[e]===void 0&&delete r[e];XR(r),e&&Hte(r,e)};return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(Fz,{label:`Send with`,children:[(0,H.jsx)(Pz,{on:(t.send??`enter`)===`enter`,onSelect:()=>n({send:`enter`}),title:`Enter sends; Shift+Enter starts a new line`,children:`Enter`}),(0,H.jsx)(Pz,{on:t.send===`mod`,onSelect:()=>n({send:`mod`}),title:`⌘ or Ctrl+Enter sends; Enter starts a new line`,children:`⌘ Enter`})]}),(0,H.jsx)(Fz,{label:`Composer chips`,children:Iz.map(e=>(0,H.jsx)(Pz,{on:t.chips===e.value,onSelect:()=>n({chips:e.value}),children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Model in composer`,children:Iz.map(e=>(0,H.jsx)(Pz,{on:t.model===e.value,onSelect:()=>n({model:e.value}),children:e.label},e.label))}),(0,H.jsx)(Fz,{label:`Mode in composer`,children:Iz.map(e=>(0,H.jsx)(Pz,{on:t.mode===e.value,onSelect:()=>n({mode:e.value}),children:e.label},e.label))})]})}var Ane={Close:`إغلاق`,"Close window":`إغلاق النافذة`,"Minimize window":`تصغير النافذة`,"Restore window":`استعادة النافذة`,"Maximize window":`تكبير النافذة`,Resize:`تغيير الحجم`,"Select all":`تحديد الكل`,"Select row":`تحديد الصف`,"Previous month":`الشهر السابق`,"Next month":`الشهر التالي`,Dismiss:`تجاهل`,Breadcrumb:`مسار التنقل`,Cards:`بطاقات`,"Copy code":`نسخ الرمز`,Copied:`تم النسخ`,"Copied!":`تم النسخ!`,Copy:`نسخ`,"Previous slide":`الشريحة السابقة`,"Next slide":`الشريحة التالية`,"Previous card":`البطاقة السابقة`,"Next card":`البطاقة التالية`,"Zoom out":`تصغير`,"Zoom in":`تكبير`,Rotate:`تدوير`,Filter:`تصفية`,"Expand all":`توسيع الكل`,"Collapse all":`طي الكل`,"Search...":`بحث...`,"Pick a date":`اختر تاريخًا`,Select:`تحديد`,"Start typing...":`ابدأ الكتابة...`,Search:`بحث`,Decrease:`إنقاص`,Increase:`زيادة`,pagination:`ترقيم الصفحات`,"Go to previous page":`الانتقال إلى الصفحة السابقة`,"Go to next page":`الانتقال إلى الصفحة التالية`,Previous:`السابق`,Next:`التالي`,"More pages":`مزيد من الصفحات`,Remove:`إزالة`,"Go back":`رجوع`,"Go forward":`تقدم`,"Reload page":`إعادة تحميل الصفحة`,Share:`مشاركة`,"New tab":`علامة تبويب جديدة`,Menu:`القائمة`,"Copy command":`نسخ الأمر`,"Terminal input":`إدخال الطرفية`,Seek:`التمرير`,"Rewind 10 seconds":`إرجاع 10 ثوانٍ`,"Forward 10 seconds":`تقديم 10 ثوانٍ`,Volume:`مستوى الصوت`,"Toggle captions":`تبديل التعليقات`,"Playback speed":`سرعة التشغيل`,Quality:`الجودة`,"Picture in picture":`صورة داخل صورة`,Play:`تشغيل`,Pause:`إيقاف مؤقت`,Mute:`كتم الصوت`,Unmute:`إلغاء كتم الصوت`,"Exit fullscreen":`الخروج من ملء الشاشة`,"Enter fullscreen":`ملء الشاشة`,Expand:`توسيع`,Collapse:`طي`,"Copy reply":`نسخ الرد`,"Good result":`نتيجة جيدة`,"Bad result":`نتيجة سيئة`,"Dialog Close":`إغلاق مربع الحوار`,Notifications:`الإشعارات`,Account:`الحساب`,Cart:`السلة`,Call:`مكالمة`,"Video call":`مكالمة فيديو`,Message:`رسالة`,Main:`الرئيسي`,Columns:`الأعمدة`,"No results.":`لا توجد نتائج.`,"No results":`لا توجد نتائج`,"No results found":`لم يُعثر على نتائج`,"Drop files here":`أفلت الملفات هنا`,"Drag & drop files here":`اسحب الملفات وأفلتها هنا`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`أو انقر للاستعراض (بحد أقصى {maxFiles} ملفات، {maxSize} ميغابايت لكل ملف)`,"Remove {name}":`إزالة {name}`,"{selected} of {total} row(s) selected.":`تم تحديد {selected} من {total}.`,"Try again":`حاول مرة أخرى`,"What’s up next?":`ما التالي؟`,"Show password":`إظهار كلمة المرور`,"Hide password":`إخفاء كلمة المرور`,"Search icons":`البحث عن أيقونات`,"No icon matches":`لا توجد أيقونة مطابقة`,"Show all items ({n})":`عرض الكل ({n})`,"Fewer {what}":`{what} أقل`,"More {what}":`المزيد من {what}`,"No tasks available. Add tasks to display Gantt chart.":`لا توجد مهام. أضف مهامًا لعرض مخطط جانت.`,January:`يناير`,February:`فبراير`,March:`مارس`,April:`أبريل`,May:`مايو`,June:`يونيو`,July:`يوليو`,August:`أغسطس`,September:`سبتمبر`,October:`أكتوبر`,November:`نوفمبر`,December:`ديسمبر`,Su:`ح`,Mo:`ن`,Tu:`ث`,We:`ر`,Th:`خ`,Fr:`ج`,Sa:`س`,"just now":`الآن`,"in a moment":`بعد لحظات`,"in 1 minute":`خلال دقيقة واحدة`,"in {n} minutes":`خلال {n} دقائق`,"in 1 hour":`خلال ساعة واحدة`,"in {n} hours":`خلال {n} ساعات`,tomorrow:`غدًا`,"in {n} days":`خلال {n} أيام`,"in 1 week":`خلال أسبوع واحد`,"in {n} weeks":`خلال {n} أسابيع`,"in 1 month":`خلال شهر واحد`,"in {n} months":`خلال {n} أشهر`,"in 1 year":`خلال سنة واحدة`,"in {n} years":`خلال {n} سنوات`,"1 minute ago":`قبل دقيقة واحدة`,"{n} minutes ago":`قبل {n} دقائق`,"1 hour ago":`قبل ساعة واحدة`,"{n} hours ago":`قبل {n} ساعات`,"1 day ago":`قبل يوم واحد`,"{n} days ago":`قبل {n} أيام`,"1 week ago":`قبل أسبوع واحد`,"{n} weeks ago":`قبل {n} أسابيع`,"1 month ago":`قبل شهر واحد`,"{n} months ago":`قبل {n} أشهر`,"1 year ago":`قبل سنة واحدة`,"{n} years ago":`قبل {n} سنوات`,"Cookie notice":`إشعار ملفات تعريف الارتباط`,"Cookie preferences":`تفضيلات ملفات تعريف الارتباط`,"Close and use essential cookies only":`إغلاق واستخدام ملفات تعريف الارتباط الأساسية فقط`,Back:`رجوع`,"Log in":`تسجيل الدخول`,"Search Hanzo or ask AI":`ابحث في Hanzo أو اسأل الذكاء الاصطناعي`,"Search models":`البحث عن النماذج`,"Search branches…":`البحث عن الفروع…`,"Search repositories…":`البحث عن المستودعات…`,"Show options":`إظهار الخيارات`,Retry:`إعادة المحاولة`,"Donut chart":`مخطط حلقي`,"Find an organization":`العثور على مؤسسة`,Organizations:`المؤسسات`,"Organization name":`اسم المؤسسة`,"Previous page":`الصفحة السابقة`,"Next page":`الصفحة التالية`,"Continue with credits":`المتابعة باستخدام الرصيد`,"Try Hanzo":`جرّب Hanzo`,"Terms & Policies":`الشروط والسياسات`,"Who this is for":`لمن هذا`,"Bill yearly":`فوترة سنوية`,Apps:`التطبيقات`,"Card actions":`إجراءات البطاقة`,"Assign to...":`تعيين إلى...`,"Search cards...":`البحث في البطاقات...`,"Clear search":`مسح البحث`,"Open files":`الملفات المفتوحة`,"Close panel":`إغلاق اللوحة`,"Add an organization":`إضافة مؤسسة`,"Keyboard Shortcuts":`اختصارات لوحة المفاتيح`,"Run a command":`تشغيل أمر`,"Type shell command...":`اكتب أمر الصدفة...`,"Attached to the next message":`مرفق بالرسالة التالية`,"Channel Member Roster":`أعضاء القناة`,"Channel Collaborative Notes":`ملاحظات القناة المشتركة`,"Code Diff Viewer":`عارض الفروق`,"Live Voice Call":`مكالمة صوتية مباشرة`,"MCP Server Hub":`مركز خوادم MCP`,"Multi-Agent Swarm Bar":`شريط سرب الوكلاء`,"Write shared channel notes, meeting agenda, or AI summaries...":`اكتب ملاحظات القناة أو جدول الاجتماع أو ملخصات الذكاء الاصطناعي...`,"Help improve our AI models":`ساعد في تحسين نماذج الذكاء الاصطناعي`,"Your name":`اسمك`,"Your role":`دورك`,"Country or region":`البلد أو المنطقة`,"Card details":`بيانات البطاقة`,"Agree to recurring charges":`الموافقة على الرسوم المتكررة`,"How you will use Hanzo":`كيف ستستخدم Hanzo`,"Team size":`حجم الفريق`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`أوافق على شروط الخدمة وسياسة الاستخدام المقبول وأؤكد أن عمري 18 عامًا على الأقل.`,"Empty string":`سلسلة فارغة`,"Empty array":`مصفوفة فارغة`,"Empty object":`كائن فارغ`,"Copy {what}":`نسخ {what}`,"Ask anything":`اسأل عن أي شيء`,Auto:`تلقائي`,Instant:`فوري`,Low:`منخفض`,Medium:`متوسط`,High:`عالٍ`,Max:`الحد الأقصى`,Dictate:`إملاء`,"Dictating — click to stop":`جارٍ الإملاء — انقر للإيقاف`,"Dictation settings":`إعدادات الإملاء`,Language:`اللغة`,"No devices found":`لم يُعثر على أجهزة`,"Microphone {n}":`ميكروفون {n}`,"Nothing matches":`لا يوجد تطابق`,Commands:`الأوامر`,"Search commands…":`البحث عن الأوامر…`,Agents:`الوكلاء`,Skills:`المهارات`,Connectors:`الموصّلات`,"Design system":`نظام التصميم`,Plugins:`الإضافات`,Devices:`الأجهزة`,Memory:`الذاكرة`,Research:`بحث متعمق`,On:`تشغيل`,"Upload or add files":`تحميل ملفات أو إضافتها`,"Add files, agents, skills and more":`أضف ملفاتًا ووكلاء ومهارات والمزيد`,"No agents yet":`لا يوجد وكلاء بعد`,"No skills yet":`لا توجد مهارات بعد`,"No connectors yet":`لا توجد موصّلات بعد`,"No design system yet":`لا يوجد نظام تصميم بعد`,"No plugins yet":`لا توجد إضافات بعد`,"No devices yet":`لا توجد أجهزة بعد`,"Search agents":`البحث عن الوكلاء`,"Search skills":`البحث عن المهارات`,"Search connectors":`البحث عن الموصّلات`,"Search design system":`البحث في نظام التصميم`,"Search plugins":`البحث عن الإضافات`,"Search devices":`البحث عن الأجهزة`,"Reading agents":`جارٍ قراءة الوكلاء`,"Reading skills":`جارٍ قراءة المهارات`,"Reading connectors":`جارٍ قراءة الموصّلات`,"Reading design system":`جارٍ قراءة نظام التصميم`,"Reading plugins":`جارٍ قراءة الإضافات`,"Adaptive reasoning based on task complexity":`استدلال متكيف حسب تعقيد المهمة`,"Answers right away, without thinking":`يجيب فورًا دون تفكير`,"A quick pass with minimal thinking":`مرور سريع بأقل قدر من التفكير`,"Thinks before answering":`يفكر قبل الإجابة`,"Deep reasoning for complex problems":`استدلال عميق للمشكلات المعقدة`,"Maximum compute and exhaustive verification":`أقصى حساب وتحقق شامل`,Effort:`الجهد`,"Effort: {level}":`الجهد: {level}`,Mode:`الوضع`,"Mode: {mode}":`الوضع: {mode}`,Model:`النموذج`,"Model: {name}":`النموذج: {name}`,"Voice mode":`وضع الصوت`,"Hanzo is speaking — talk to interrupt":`Hanzo يتحدث — تحدّث للمقاطعة`,"In conversation — click to hang up":`في محادثة — انقر لإنهاء المكالمة`,"Go to testimonial {n}":`الانتقال إلى الشهادة {n}`,"Go to card {n}":`الانتقال إلى البطاقة {n}`,"{n} of {total}":`{n} من {total}`,"Reading…":`جارٍ القراءة…`,Skill:`مهارة`,Plugin:`إضافة`},jne={Close:`Schließen`,"Close window":`Fenster schließen`,"Minimize window":`Fenster minimieren`,"Restore window":`Fenster wiederherstellen`,"Maximize window":`Fenster maximieren`,Resize:`Größe ändern`,"Select all":`Alle auswählen`,"Select row":`Zeile auswählen`,"Previous month":`Vorheriger Monat`,"Next month":`Nächster Monat`,Dismiss:`Schließen`,Breadcrumb:`Brotkrumen`,Cards:`Karten`,"Copy code":`Code kopieren`,Copied:`Kopiert`,"Copied!":`Kopiert!`,Copy:`Kopieren`,"Previous slide":`Vorherige Folie`,"Next slide":`Nächste Folie`,"Previous card":`Vorherige Karte`,"Next card":`Nächste Karte`,"Zoom out":`Verkleinern`,"Zoom in":`Vergrößern`,Rotate:`Drehen`,Filter:`Filtern`,"Expand all":`Alle aufklappen`,"Collapse all":`Alle zuklappen`,"Search...":`Suchen...`,"Pick a date":`Datum wählen`,Select:`Auswählen`,"Start typing...":`Schreibe etwas...`,Search:`Suchen`,Decrease:`Verringern`,Increase:`Erhöhen`,pagination:`Seitennummerierung`,"Go to previous page":`Zur vorherigen Seite`,"Go to next page":`Zur nächsten Seite`,Previous:`Zurück`,Next:`Weiter`,"More pages":`Weitere Seiten`,Remove:`Entfernen`,"Go back":`Zurück`,"Go forward":`Vorwärts`,"Reload page":`Seite neu laden`,Share:`Teilen`,"New tab":`Neuer Tab`,Menu:`Menü`,"Copy command":`Befehl kopieren`,"Terminal input":`Terminaleingabe`,Seek:`Position`,"Rewind 10 seconds":`10 Sekunden zurück`,"Forward 10 seconds":`10 Sekunden vor`,Volume:`Lautstärke`,"Toggle captions":`Untertitel umschalten`,"Playback speed":`Wiedergabegeschwindigkeit`,Quality:`Qualität`,"Picture in picture":`Bild im Bild`,Play:`Wiedergabe`,Pause:`Pause`,Mute:`Stumm`,Unmute:`Ton an`,"Exit fullscreen":`Vollbild beenden`,"Enter fullscreen":`Vollbild`,Expand:`Aufklappen`,Collapse:`Zuklappen`,"Copy reply":`Antwort kopieren`,"Good result":`Gutes Ergebnis`,"Bad result":`Schlechtes Ergebnis`,"Dialog Close":`Dialog schließen`,Notifications:`Benachrichtigungen`,Account:`Konto`,Cart:`Warenkorb`,Call:`Anruf`,"Video call":`Videoanruf`,Message:`Nachricht`,Main:`Hauptnavigation`,Columns:`Spalten`,"No results.":`Keine Ergebnisse.`,"No results":`Keine Ergebnisse`,"No results found":`Keine Ergebnisse gefunden`,"Drop files here":`Dateien hier ablegen`,"Drag & drop files here":`Dateien hierher ziehen`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`oder klicken zum Durchsuchen (max. {maxFiles} Dateien, je {maxSize} MB)`,"Remove {name}":`{name} entfernen`,"{selected} of {total} row(s) selected.":`{selected} von {total} Zeile(n) ausgewählt.`,"Try again":`Erneut versuchen`,"What’s up next?":`Was steht als Nächstes an?`,"Show password":`Passwort anzeigen`,"Hide password":`Passwort verbergen`,"Search icons":`Symbole suchen`,"No icon matches":`Kein Symbol passt`,"Show all items ({n})":`Alle anzeigen ({n})`,"Fewer {what}":`Weniger {what}`,"More {what}":`Mehr {what}`,"No tasks available. Add tasks to display Gantt chart.":`Keine Aufgaben. Fügen Sie welche hinzu, um das Gantt-Diagramm zu sehen.`,January:`Januar`,February:`Februar`,March:`März`,April:`April`,May:`Mai`,June:`Juni`,July:`Juli`,August:`August`,September:`September`,October:`Oktober`,November:`November`,December:`Dezember`,Su:`So`,Mo:`Mo`,Tu:`Di`,We:`Mi`,Th:`Do`,Fr:`Fr`,Sa:`Sa`,"just now":`gerade eben`,"in a moment":`gleich`,"in 1 minute":`in 1 Minute`,"in {n} minutes":`in {n} Minuten`,"in 1 hour":`in 1 Stunde`,"in {n} hours":`in {n} Stunden`,tomorrow:`morgen`,"in {n} days":`in {n} Tagen`,"in 1 week":`in 1 Woche`,"in {n} weeks":`in {n} Wochen`,"in 1 month":`in 1 Monat`,"in {n} months":`in {n} Monaten`,"in 1 year":`in 1 Jahr`,"in {n} years":`in {n} Jahren`,"1 minute ago":`vor 1 Minute`,"{n} minutes ago":`vor {n} Minuten`,"1 hour ago":`vor 1 Stunde`,"{n} hours ago":`vor {n} Stunden`,"1 day ago":`vor 1 Tag`,"{n} days ago":`vor {n} Tagen`,"1 week ago":`vor 1 Woche`,"{n} weeks ago":`vor {n} Wochen`,"1 month ago":`vor 1 Monat`,"{n} months ago":`vor {n} Monaten`,"1 year ago":`vor 1 Jahr`,"{n} years ago":`vor {n} Jahren`,"Cookie notice":`Hinweis zu Cookies`,"Cookie preferences":`Cookie-Einstellungen`,"Close and use essential cookies only":`Schließen und nur essenzielle Cookies verwenden`,Back:`Zurück`,"Log in":`Anmelden`,"Search Hanzo or ask AI":`Hanzo durchsuchen oder die KI fragen`,"Search models":`Modelle suchen`,"Search branches…":`Branches suchen…`,"Search repositories…":`Repositories suchen…`,"Show options":`Optionen anzeigen`,Retry:`Wiederholen`,"Donut chart":`Ringdiagramm`,"Find an organization":`Organisation finden`,Organizations:`Organisationen`,"Organization name":`Name der Organisation`,"Previous page":`Vorherige Seite`,"Next page":`Nächste Seite`,"Continue with credits":`Mit Guthaben fortfahren`,"Try Hanzo":`Hanzo ausprobieren`,"Terms & Policies":`Bedingungen und Richtlinien`,"Who this is for":`Für wen es ist`,"Bill yearly":`Jährlich abrechnen`,Apps:`Apps`,"Card actions":`Kartenaktionen`,"Assign to...":`Zuweisen an...`,"Search cards...":`Karten suchen...`,"Clear search":`Suche löschen`,"Open files":`Geöffnete Dateien`,"Close panel":`Bereich schließen`,"Add an organization":`Organisation hinzufügen`,"Keyboard Shortcuts":`Tastenkürzel`,"Run a command":`Befehl ausführen`,"Type shell command...":`Shell-Befehl eingeben...`,"Attached to the next message":`An die nächste Nachricht angehängt`,"Channel Member Roster":`Kanalmitglieder`,"Channel Collaborative Notes":`Gemeinsame Kanalnotizen`,"Code Diff Viewer":`Diff-Ansicht`,"Live Voice Call":`Live-Sprachanruf`,"MCP Server Hub":`MCP-Server-Hub`,"Multi-Agent Swarm Bar":`Leiste für den Agentenschwarm`,"Write shared channel notes, meeting agenda, or AI summaries...":`Gemeinsame Notizen, Tagesordnung oder KI-Zusammenfassungen schreiben...`,"Help improve our AI models":`Hilf mit, unsere KI-Modelle zu verbessern`,"Your name":`Dein Name`,"Your role":`Deine Rolle`,"Country or region":`Land oder Region`,"Card details":`Kartendaten`,"Agree to recurring charges":`Wiederkehrenden Abbuchungen zustimmen`,"How you will use Hanzo":`Wie du Hanzo nutzen wirst`,"Team size":`Teamgröße`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Ich stimme den Nutzungsbedingungen und der Richtlinie zur akzeptablen Nutzung zu und bestätige, dass ich mindestens 18 Jahre alt bin.`,"Empty string":`Leere Zeichenkette`,"Empty array":`Leeres Array`,"Empty object":`Leeres Objekt`,"Copy {what}":`{what} kopieren`,"Ask anything":`Frag nach allem`,Auto:`Auto`,Instant:`Sofort`,Low:`Niedrig`,Medium:`Mittel`,High:`Hoch`,Max:`Maximal`,Dictate:`Diktieren`,"Dictating — click to stop":`Diktat läuft — zum Stoppen klicken`,"Dictation settings":`Diktateinstellungen`,Language:`Sprache`,"No devices found":`Keine Geräte gefunden`,"Microphone {n}":`Mikrofon {n}`,"Nothing matches":`Nichts passt`,Commands:`Befehle`,"Search commands…":`Befehle suchen…`,Agents:`Agenten`,Skills:`Fähigkeiten`,Connectors:`Konnektoren`,"Design system":`Designsystem`,Plugins:`Plugins`,Devices:`Geräte`,Memory:`Gedächtnis`,Research:`Recherche`,On:`An`,"Upload or add files":`Dateien hochladen oder hinzufügen`,"Add files, agents, skills and more":`Dateien, Agenten, Fähigkeiten und mehr hinzufügen`,"No agents yet":`Noch keine Agenten`,"No skills yet":`Noch keine Fähigkeiten`,"No connectors yet":`Noch keine Konnektoren`,"No design system yet":`Noch kein Designsystem`,"No plugins yet":`Noch keine Plugins`,"No devices yet":`Noch keine Geräte`,"Search agents":`Agenten suchen`,"Search skills":`Fähigkeiten suchen`,"Search connectors":`Konnektoren suchen`,"Search design system":`Designsystem durchsuchen`,"Search plugins":`Plugins suchen`,"Search devices":`Geräte suchen`,"Reading agents":`Agenten werden gelesen`,"Reading skills":`Fähigkeiten werden gelesen`,"Reading connectors":`Konnektoren werden gelesen`,"Reading design system":`Designsystem wird gelesen`,"Reading plugins":`Plugins werden gelesen`,"Adaptive reasoning based on task complexity":`Adaptives Denken je nach Komplexität der Aufgabe`,"Answers right away, without thinking":`Antwortet sofort, ohne nachzudenken`,"A quick pass with minimal thinking":`Ein schneller Durchgang mit wenig Nachdenken`,"Thinks before answering":`Denkt nach, bevor es antwortet`,"Deep reasoning for complex problems":`Tiefes Nachdenken bei komplexen Problemen`,"Maximum compute and exhaustive verification":`Maximales Rechnen und gründliche Prüfung`,Effort:`Aufwand`,"Effort: {level}":`Aufwand: {level}`,Mode:`Modus`,"Mode: {mode}":`Modus: {mode}`,Model:`Modell`,"Model: {name}":`Modell: {name}`,"Voice mode":`Sprachmodus`,"Hanzo is speaking — talk to interrupt":`Hanzo spricht — sprich, um zu unterbrechen`,"In conversation — click to hang up":`Im Gespräch — zum Auflegen klicken`,"Go to testimonial {n}":`Zu Testimonial {n}`,"Go to card {n}":`Zu Karte {n}`,"{n} of {total}":`{n} von {total}`,"Reading…":`Wird gelesen…`,Skill:`Fähigkeit`,Plugin:`Plugin`},Mne={Close:`Cerrar`,"Close window":`Cerrar ventana`,"Minimize window":`Minimizar ventana`,"Restore window":`Restaurar ventana`,"Maximize window":`Maximizar ventana`,Resize:`Cambiar tamaño`,"Select all":`Seleccionar todo`,"Select row":`Seleccionar fila`,"Previous month":`Mes anterior`,"Next month":`Mes siguiente`,Dismiss:`Descartar`,Breadcrumb:`Ruta de navegación`,Cards:`Tarjetas`,"Copy code":`Copiar código`,Copied:`Copiado`,"Copied!":`¡Copiado!`,Copy:`Copiar`,"Previous slide":`Diapositiva anterior`,"Next slide":`Diapositiva siguiente`,"Previous card":`Tarjeta anterior`,"Next card":`Tarjeta siguiente`,"Zoom out":`Alejar`,"Zoom in":`Acercar`,Rotate:`Girar`,Filter:`Filtrar`,"Expand all":`Expandir todo`,"Collapse all":`Contraer todo`,"Search...":`Buscar...`,"Pick a date":`Elige una fecha`,Select:`Seleccionar`,"Start typing...":`Empieza a escribir...`,Search:`Buscar`,Decrease:`Disminuir`,Increase:`Aumentar`,pagination:`paginación`,"Go to previous page":`Ir a la página anterior`,"Go to next page":`Ir a la página siguiente`,Previous:`Anterior`,Next:`Siguiente`,"More pages":`Más páginas`,Remove:`Quitar`,"Go back":`Volver`,"Go forward":`Avanzar`,"Reload page":`Recargar página`,Share:`Compartir`,"New tab":`Nueva pestaña`,Menu:`Menú`,"Copy command":`Copiar comando`,"Terminal input":`Entrada del terminal`,Seek:`Buscar posición`,"Rewind 10 seconds":`Retroceder 10 segundos`,"Forward 10 seconds":`Adelantar 10 segundos`,Volume:`Volumen`,"Toggle captions":`Mostrar u ocultar subtítulos`,"Playback speed":`Velocidad de reproducción`,Quality:`Calidad`,"Picture in picture":`Imagen en imagen`,Play:`Reproducir`,Pause:`Pausa`,Mute:`Silenciar`,Unmute:`Activar sonido`,"Exit fullscreen":`Salir de pantalla completa`,"Enter fullscreen":`Pantalla completa`,Expand:`Expandir`,Collapse:`Contraer`,"Copy reply":`Copiar respuesta`,"Good result":`Buen resultado`,"Bad result":`Mal resultado`,"Dialog Close":`Cerrar diálogo`,Notifications:`Notificaciones`,Account:`Cuenta`,Cart:`Carrito`,Call:`Llamada`,"Video call":`Videollamada`,Message:`Mensaje`,Main:`Principal`,Columns:`Columnas`,"No results.":`No hay resultados.`,"No results":`No hay resultados`,"No results found":`No se encontraron resultados`,"Drop files here":`Suelta los archivos aquí`,"Drag & drop files here":`Arrastra y suelta archivos aquí`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`o haz clic para explorar (máx. {maxFiles} archivos, {maxSize} MB cada uno)`,"Remove {name}":`Quitar {name}`,"{selected} of {total} row(s) selected.":`{selected} de {total} fila(s) seleccionada(s).`,"Try again":`Intentar de nuevo`,"What’s up next?":`¿Qué sigue?`,"Show password":`Mostrar contraseña`,"Hide password":`Ocultar contraseña`,"Search icons":`Buscar iconos`,"No icon matches":`Ningún icono coincide`,"Show all items ({n})":`Mostrar todos ({n})`,"Fewer {what}":`Menos {what}`,"More {what}":`Más {what}`,"No tasks available. Add tasks to display Gantt chart.":`No hay tareas. Añade tareas para ver el diagrama de Gantt.`,January:`Enero`,February:`Febrero`,March:`Marzo`,April:`Abril`,May:`Mayo`,June:`Junio`,July:`Julio`,August:`Agosto`,September:`Septiembre`,October:`Octubre`,November:`Noviembre`,December:`Diciembre`,Su:`do`,Mo:`lu`,Tu:`ma`,We:`mi`,Th:`ju`,Fr:`vi`,Sa:`sá`,"just now":`ahora mismo`,"in a moment":`en un momento`,"in 1 minute":`en 1 minuto`,"in {n} minutes":`en {n} minutos`,"in 1 hour":`en 1 hora`,"in {n} hours":`en {n} horas`,tomorrow:`mañana`,"in {n} days":`en {n} días`,"in 1 week":`en 1 semana`,"in {n} weeks":`en {n} semanas`,"in 1 month":`en 1 mes`,"in {n} months":`en {n} meses`,"in 1 year":`en 1 año`,"in {n} years":`en {n} años`,"1 minute ago":`hace 1 minuto`,"{n} minutes ago":`hace {n} minutos`,"1 hour ago":`hace 1 hora`,"{n} hours ago":`hace {n} horas`,"1 day ago":`hace 1 día`,"{n} days ago":`hace {n} días`,"1 week ago":`hace 1 semana`,"{n} weeks ago":`hace {n} semanas`,"1 month ago":`hace 1 mes`,"{n} months ago":`hace {n} meses`,"1 year ago":`hace 1 año`,"{n} years ago":`hace {n} años`,"Cookie notice":`Aviso de cookies`,"Cookie preferences":`Preferencias de cookies`,"Close and use essential cookies only":`Cerrar y usar solo cookies esenciales`,Back:`Atrás`,"Log in":`Iniciar sesión`,"Search Hanzo or ask AI":`Busca en Hanzo o pregunta a la IA`,"Search models":`Buscar modelos`,"Search branches…":`Buscar ramas…`,"Search repositories…":`Buscar repositorios…`,"Show options":`Mostrar opciones`,Retry:`Reintentar`,"Donut chart":`Gráfico de anillo`,"Find an organization":`Buscar una organización`,Organizations:`Organizaciones`,"Organization name":`Nombre de la organización`,"Previous page":`Página anterior`,"Next page":`Página siguiente`,"Continue with credits":`Continuar con créditos`,"Try Hanzo":`Probar Hanzo`,"Terms & Policies":`Términos y políticas`,"Who this is for":`Para quién es`,"Bill yearly":`Facturación anual`,Apps:`Aplicaciones`,"Card actions":`Acciones de la tarjeta`,"Assign to...":`Asignar a...`,"Search cards...":`Buscar tarjetas...`,"Clear search":`Borrar búsqueda`,"Open files":`Archivos abiertos`,"Close panel":`Cerrar panel`,"Add an organization":`Añadir una organización`,"Keyboard Shortcuts":`Atajos de teclado`,"Run a command":`Ejecutar un comando`,"Type shell command...":`Escribe un comando de shell...`,"Attached to the next message":`Adjunto al próximo mensaje`,"Channel Member Roster":`Miembros del canal`,"Channel Collaborative Notes":`Notas compartidas del canal`,"Code Diff Viewer":`Visor de diferencias`,"Live Voice Call":`Llamada de voz en vivo`,"MCP Server Hub":`Centro de servidores MCP`,"Multi-Agent Swarm Bar":`Barra del enjambre de agentes`,"Write shared channel notes, meeting agenda, or AI summaries...":`Escribe notas del canal, el orden del día o resúmenes de la IA...`,"Help improve our AI models":`Ayuda a mejorar nuestros modelos de IA`,"Your name":`Tu nombre`,"Your role":`Tu rol`,"Country or region":`País o región`,"Card details":`Datos de la tarjeta`,"Agree to recurring charges":`Acepto los cargos recurrentes`,"How you will use Hanzo":`Cómo usarás Hanzo`,"Team size":`Tamaño del equipo`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Acepto las Condiciones del servicio y la Política de uso aceptable y confirmo que tengo al menos 18 años.`,"Empty string":`Cadena vacía`,"Empty array":`Arreglo vacío`,"Empty object":`Objeto vacío`,"Copy {what}":`Copiar {what}`,"Ask anything":`Pregunta lo que quieras`,Auto:`Auto`,Instant:`Instantáneo`,Low:`Bajo`,Medium:`Medio`,High:`Alto`,Max:`Máximo`,Dictate:`Dictar`,"Dictating — click to stop":`Dictando — haz clic para detener`,"Dictation settings":`Ajustes de dictado`,Language:`Idioma`,"No devices found":`No se encontraron dispositivos`,"Microphone {n}":`Micrófono {n}`,"Nothing matches":`Nada coincide`,Commands:`Comandos`,"Search commands…":`Buscar comandos…`,Agents:`Agentes`,Skills:`Habilidades`,Connectors:`Conectores`,"Design system":`Sistema de diseño`,Plugins:`Complementos`,Devices:`Dispositivos`,Memory:`Memoria`,Research:`Investigación`,On:`Activado`,"Upload or add files":`Subir o añadir archivos`,"Add files, agents, skills and more":`Añade archivos, agentes, habilidades y más`,"No agents yet":`Aún no hay agentes`,"No skills yet":`Aún no hay habilidades`,"No connectors yet":`Aún no hay conectores`,"No design system yet":`Aún no hay sistema de diseño`,"No plugins yet":`Aún no hay complementos`,"No devices yet":`Aún no hay dispositivos`,"Search agents":`Buscar agentes`,"Search skills":`Buscar habilidades`,"Search connectors":`Buscar conectores`,"Search design system":`Buscar en el sistema de diseño`,"Search plugins":`Buscar complementos`,"Search devices":`Buscar dispositivos`,"Reading agents":`Leyendo agentes`,"Reading skills":`Leyendo habilidades`,"Reading connectors":`Leyendo conectores`,"Reading design system":`Leyendo el sistema de diseño`,"Reading plugins":`Leyendo complementos`,"Adaptive reasoning based on task complexity":`Razonamiento adaptativo según la complejidad de la tarea`,"Answers right away, without thinking":`Responde al instante, sin pensar`,"A quick pass with minimal thinking":`Una pasada rápida, con poco razonamiento`,"Thinks before answering":`Piensa antes de responder`,"Deep reasoning for complex problems":`Razonamiento profundo para problemas complejos`,"Maximum compute and exhaustive verification":`Cómputo máximo y verificación exhaustiva`,Effort:`Esfuerzo`,"Effort: {level}":`Esfuerzo: {level}`,Mode:`Modo`,"Mode: {mode}":`Modo: {mode}`,Model:`Modelo`,"Model: {name}":`Modelo: {name}`,"Voice mode":`Modo de voz`,"Hanzo is speaking — talk to interrupt":`Hanzo está hablando — habla para interrumpir`,"In conversation — click to hang up":`En conversación — haz clic para colgar`,"Go to testimonial {n}":`Ir al testimonio {n}`,"Go to card {n}":`Ir a la tarjeta {n}`,"{n} of {total}":`{n} de {total}`,"Reading…":`Leyendo…`,Skill:`Habilidad`,Plugin:`Complemento`},Nne={Close:`Fermer`,"Close window":`Fermer la fenêtre`,"Minimize window":`Réduire la fenêtre`,"Restore window":`Restaurer la fenêtre`,"Maximize window":`Agrandir la fenêtre`,Resize:`Redimensionner`,"Select all":`Tout sélectionner`,"Select row":`Sélectionner la ligne`,"Previous month":`Mois précédent`,"Next month":`Mois suivant`,Dismiss:`Ignorer`,Breadcrumb:`Fil d’Ariane`,Cards:`Cartes`,"Copy code":`Copier le code`,Copied:`Copié`,"Copied!":`Copié !`,Copy:`Copier`,"Previous slide":`Diapositive précédente`,"Next slide":`Diapositive suivante`,"Previous card":`Carte précédente`,"Next card":`Carte suivante`,"Zoom out":`Zoom arrière`,"Zoom in":`Zoom avant`,Rotate:`Pivoter`,Filter:`Filtrer`,"Expand all":`Tout développer`,"Collapse all":`Tout réduire`,"Search...":`Rechercher...`,"Pick a date":`Choisir une date`,Select:`Sélectionner`,"Start typing...":`Commencez à écrire...`,Search:`Rechercher`,Decrease:`Diminuer`,Increase:`Augmenter`,pagination:`pagination`,"Go to previous page":`Aller à la page précédente`,"Go to next page":`Aller à la page suivante`,Previous:`Précédent`,Next:`Suivant`,"More pages":`Plus de pages`,Remove:`Retirer`,"Go back":`Retour`,"Go forward":`Avancer`,"Reload page":`Recharger la page`,Share:`Partager`,"New tab":`Nouvel onglet`,Menu:`Menu`,"Copy command":`Copier la commande`,"Terminal input":`Saisie du terminal`,Seek:`Position de lecture`,"Rewind 10 seconds":`Reculer de 10 secondes`,"Forward 10 seconds":`Avancer de 10 secondes`,Volume:`Volume`,"Toggle captions":`Afficher ou masquer les sous-titres`,"Playback speed":`Vitesse de lecture`,Quality:`Qualité`,"Picture in picture":`Image dans l’image`,Play:`Lecture`,Pause:`Pause`,Mute:`Couper le son`,Unmute:`Réactiver le son`,"Exit fullscreen":`Quitter le plein écran`,"Enter fullscreen":`Plein écran`,Expand:`Développer`,Collapse:`Réduire`,"Copy reply":`Copier la réponse`,"Good result":`Bon résultat`,"Bad result":`Mauvais résultat`,"Dialog Close":`Fermer la boîte de dialogue`,Notifications:`Notifications`,Account:`Compte`,Cart:`Panier`,Call:`Appel`,"Video call":`Appel vidéo`,Message:`Message`,Main:`Principal`,Columns:`Colonnes`,"No results.":`Aucun résultat.`,"No results":`Aucun résultat`,"No results found":`Aucun résultat trouvé`,"Drop files here":`Déposez les fichiers ici`,"Drag & drop files here":`Glissez-déposez des fichiers ici`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`ou cliquez pour parcourir ({maxFiles} fichiers max., {maxSize} Mo chacun)`,"Remove {name}":`Retirer {name}`,"{selected} of {total} row(s) selected.":`{selected} sur {total} ligne(s) sélectionnée(s).`,"Try again":`Réessayer`,"What’s up next?":`Et ensuite ?`,"Show password":`Afficher le mot de passe`,"Hide password":`Masquer le mot de passe`,"Search icons":`Rechercher des icônes`,"No icon matches":`Aucune icône ne correspond`,"Show all items ({n})":`Tout afficher ({n})`,"Fewer {what}":`Moins de {what}`,"More {what}":`Plus de {what}`,"No tasks available. Add tasks to display Gantt chart.":`Aucune tâche. Ajoutez-en pour afficher le diagramme de Gantt.`,January:`janvier`,February:`février`,March:`mars`,April:`avril`,May:`mai`,June:`juin`,July:`juillet`,August:`août`,September:`septembre`,October:`octobre`,November:`novembre`,December:`décembre`,Su:`di`,Mo:`lu`,Tu:`ma`,We:`me`,Th:`je`,Fr:`ve`,Sa:`sa`,"just now":`à l’instant`,"in a moment":`dans un instant`,"in 1 minute":`dans 1 minute`,"in {n} minutes":`dans {n} minutes`,"in 1 hour":`dans 1 heure`,"in {n} hours":`dans {n} heures`,tomorrow:`demain`,"in {n} days":`dans {n} jours`,"in 1 week":`dans 1 semaine`,"in {n} weeks":`dans {n} semaines`,"in 1 month":`dans 1 mois`,"in {n} months":`dans {n} mois`,"in 1 year":`dans 1 an`,"in {n} years":`dans {n} ans`,"1 minute ago":`il y a 1 minute`,"{n} minutes ago":`il y a {n} minutes`,"1 hour ago":`il y a 1 heure`,"{n} hours ago":`il y a {n} heures`,"1 day ago":`il y a 1 jour`,"{n} days ago":`il y a {n} jours`,"1 week ago":`il y a 1 semaine`,"{n} weeks ago":`il y a {n} semaines`,"1 month ago":`il y a 1 mois`,"{n} months ago":`il y a {n} mois`,"1 year ago":`il y a 1 an`,"{n} years ago":`il y a {n} ans`,"Cookie notice":`Avis sur les cookies`,"Cookie preferences":`Préférences de cookies`,"Close and use essential cookies only":`Fermer et n’utiliser que les cookies essentiels`,Back:`Retour`,"Log in":`Se connecter`,"Search Hanzo or ask AI":`Rechercher dans Hanzo ou demander à l’IA`,"Search models":`Rechercher des modèles`,"Search branches…":`Rechercher des branches…`,"Search repositories…":`Rechercher des dépôts…`,"Show options":`Afficher les options`,Retry:`Réessayer`,"Donut chart":`Graphique en anneau`,"Find an organization":`Trouver une organisation`,Organizations:`Organisations`,"Organization name":`Nom de l’organisation`,"Previous page":`Page précédente`,"Next page":`Page suivante`,"Continue with credits":`Continuer avec des crédits`,"Try Hanzo":`Essayer Hanzo`,"Terms & Policies":`Conditions et politiques`,"Who this is for":`À qui cela s’adresse`,"Bill yearly":`Facturation annuelle`,Apps:`Applications`,"Card actions":`Actions de la carte`,"Assign to...":`Attribuer à...`,"Search cards...":`Rechercher des cartes...`,"Clear search":`Effacer la recherche`,"Open files":`Fichiers ouverts`,"Close panel":`Fermer le panneau`,"Add an organization":`Ajouter une organisation`,"Keyboard Shortcuts":`Raccourcis clavier`,"Run a command":`Exécuter une commande`,"Type shell command...":`Saisissez une commande shell...`,"Attached to the next message":`Joint au prochain message`,"Channel Member Roster":`Membres du canal`,"Channel Collaborative Notes":`Notes collaboratives du canal`,"Code Diff Viewer":`Visionneuse de diff`,"Live Voice Call":`Appel vocal en direct`,"MCP Server Hub":`Hub des serveurs MCP`,"Multi-Agent Swarm Bar":`Barre d’essaim multi-agents`,"Write shared channel notes, meeting agenda, or AI summaries...":`Écrivez des notes partagées, l’ordre du jour ou des résumés de l’IA...`,"Help improve our AI models":`Aidez à améliorer nos modèles d’IA`,"Your name":`Votre nom`,"Your role":`Votre rôle`,"Country or region":`Pays ou région`,"Card details":`Coordonnées de la carte`,"Agree to recurring charges":`J’accepte les prélèvements récurrents`,"How you will use Hanzo":`Comment vous utiliserez Hanzo`,"Team size":`Taille de l’équipe`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`J’accepte les Conditions d’utilisation et la Politique d’usage acceptable et je confirme avoir au moins 18 ans.`,"Empty string":`Chaîne vide`,"Empty array":`Tableau vide`,"Empty object":`Objet vide`,"Copy {what}":`Copier {what}`,"Ask anything":`Demandez n’importe quoi`,Auto:`Auto`,Instant:`Instantané`,Low:`Faible`,Medium:`Moyen`,High:`Élevé`,Max:`Max`,Dictate:`Dicter`,"Dictating — click to stop":`Dictée en cours — cliquez pour arrêter`,"Dictation settings":`Réglages de la dictée`,Language:`Langue`,"No devices found":`Aucun appareil trouvé`,"Microphone {n}":`Microphone {n}`,"Nothing matches":`Aucun résultat`,Commands:`Commandes`,"Search commands…":`Rechercher des commandes…`,Agents:`Agents`,Skills:`Compétences`,Connectors:`Connecteurs`,"Design system":`Système de design`,Plugins:`Plugins`,Devices:`Appareils`,Memory:`Mémoire`,Research:`Recherche`,On:`Activé`,"Upload or add files":`Téléverser ou ajouter des fichiers`,"Add files, agents, skills and more":`Ajoutez des fichiers, des agents, des compétences et plus`,"No agents yet":`Pas encore d’agents`,"No skills yet":`Pas encore de compétences`,"No connectors yet":`Pas encore de connecteurs`,"No design system yet":`Pas encore de système de design`,"No plugins yet":`Pas encore de plugins`,"No devices yet":`Pas encore d’appareils`,"Search agents":`Rechercher des agents`,"Search skills":`Rechercher des compétences`,"Search connectors":`Rechercher des connecteurs`,"Search design system":`Rechercher dans le système de design`,"Search plugins":`Rechercher des plugins`,"Search devices":`Rechercher des appareils`,"Reading agents":`Lecture des agents`,"Reading skills":`Lecture des compétences`,"Reading connectors":`Lecture des connecteurs`,"Reading design system":`Lecture du système de design`,"Reading plugins":`Lecture des plugins`,"Adaptive reasoning based on task complexity":`Raisonnement adaptatif selon la complexité de la tâche`,"Answers right away, without thinking":`Répond immédiatement, sans réfléchir`,"A quick pass with minimal thinking":`Un passage rapide, avec peu de réflexion`,"Thinks before answering":`Réfléchit avant de répondre`,"Deep reasoning for complex problems":`Raisonnement approfondi pour les problèmes complexes`,"Maximum compute and exhaustive verification":`Calcul maximal et vérification exhaustive`,Effort:`Effort`,"Effort: {level}":`Effort : {level}`,Mode:`Mode`,"Mode: {mode}":`Mode : {mode}`,Model:`Modèle`,"Model: {name}":`Modèle : {name}`,"Voice mode":`Mode vocal`,"Hanzo is speaking — talk to interrupt":`Hanzo parle — parlez pour interrompre`,"In conversation — click to hang up":`En conversation — cliquez pour raccrocher`,"Go to testimonial {n}":`Aller au témoignage {n}`,"Go to card {n}":`Aller à la carte {n}`,"{n} of {total}":`{n} sur {total}`,"Reading…":`Lecture…`,Skill:`Compétence`,Plugin:`Plugin`},Pne={Close:`बंद करें`,"Close window":`विंडो बंद करें`,"Minimize window":`विंडो छोटा करें`,"Restore window":`विंडो पुनर्स्थापित करें`,"Maximize window":`विंडो बड़ा करें`,Resize:`आकार बदलें`,"Select all":`सभी चुनें`,"Select row":`पंक्ति चुनें`,"Previous month":`पिछला महीना`,"Next month":`अगला महीना`,Dismiss:`खारिज करें`,Breadcrumb:`ब्रेडक्रम्ब`,Cards:`कार्ड`,"Copy code":`कोड कॉपी करें`,Copied:`कॉपी हो गया`,"Copied!":`कॉपी हो गया!`,Copy:`कॉपी करें`,"Previous slide":`पिछली स्लाइड`,"Next slide":`अगली स्लाइड`,"Previous card":`पिछला कार्ड`,"Next card":`अगला कार्ड`,"Zoom out":`ज़ूम आउट`,"Zoom in":`ज़ूम इन`,Rotate:`घुमाएँ`,Filter:`फ़िल्टर`,"Expand all":`सभी विस्तृत करें`,"Collapse all":`सभी समेटें`,"Search...":`खोजें...`,"Pick a date":`तारीख चुनें`,Select:`चुनें`,"Start typing...":`लिखना शुरू करें...`,Search:`खोजें`,Decrease:`घटाएँ`,Increase:`बढ़ाएँ`,pagination:`पृष्ठांकन`,"Go to previous page":`पिछले पृष्ठ पर जाएँ`,"Go to next page":`अगले पृष्ठ पर जाएँ`,Previous:`पिछला`,Next:`अगला`,"More pages":`और पृष्ठ`,Remove:`हटाएँ`,"Go back":`वापस जाएँ`,"Go forward":`आगे जाएँ`,"Reload page":`पृष्ठ पुनः लोड करें`,Share:`साझा करें`,"New tab":`नया टैब`,Menu:`मेनू`,"Copy command":`कमांड कॉपी करें`,"Terminal input":`टर्मिनल इनपुट`,Seek:`स्थिति`,"Rewind 10 seconds":`10 सेकंड पीछे`,"Forward 10 seconds":`10 सेकंड आगे`,Volume:`आवाज़`,"Toggle captions":`कैप्शन टॉगल करें`,"Playback speed":`प्लेबैक गति`,Quality:`गुणवत्ता`,"Picture in picture":`पिक्चर इन पिक्चर`,Play:`चलाएँ`,Pause:`रोकें`,Mute:`म्यूट`,Unmute:`अनम्यूट`,"Exit fullscreen":`पूर्ण स्क्रीन से बाहर`,"Enter fullscreen":`पूर्ण स्क्रीन`,Expand:`विस्तृत करें`,Collapse:`समेटें`,"Copy reply":`जवाब कॉपी करें`,"Good result":`अच्छा परिणाम`,"Bad result":`खराब परिणाम`,"Dialog Close":`संवाद बंद करें`,Notifications:`सूचनाएँ`,Account:`खाता`,Cart:`कार्ट`,Call:`कॉल`,"Video call":`वीडियो कॉल`,Message:`संदेश`,Main:`मुख्य`,Columns:`कॉलम`,"No results.":`कोई परिणाम नहीं।`,"No results":`कोई परिणाम नहीं`,"No results found":`कोई परिणाम नहीं मिला`,"Drop files here":`फ़ाइलें यहाँ छोड़ें`,"Drag & drop files here":`फ़ाइलें खींचकर यहाँ छोड़ें`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`या ब्राउज़ करने के लिए क्लिक करें (अधिकतम {maxFiles} फ़ाइलें, प्रत्येक {maxSize} MB)`,"Remove {name}":`{name} हटाएँ`,"{selected} of {total} row(s) selected.":`{total} में से {selected} पंक्तियाँ चुनी गईं।`,"Try again":`फिर कोशिश करें`,"What’s up next?":`आगे क्या है?`,"Show password":`पासवर्ड दिखाएँ`,"Hide password":`पासवर्ड छिपाएँ`,"Search icons":`आइकन खोजें`,"No icon matches":`कोई आइकन मेल नहीं खाता`,"Show all items ({n})":`सभी दिखाएँ ({n})`,"Fewer {what}":`कम {what}`,"More {what}":`अधिक {what}`,"No tasks available. Add tasks to display Gantt chart.":`कोई कार्य नहीं। गैंट चार्ट के लिए कार्य जोड़ें।`,January:`जनवरी`,February:`फ़रवरी`,March:`मार्च`,April:`अप्रैल`,May:`मई`,June:`जून`,July:`जुलाई`,August:`अगस्त`,September:`सितंबर`,October:`अक्टूबर`,November:`नवंबर`,December:`दिसंबर`,Su:`र`,Mo:`सो`,Tu:`मं`,We:`बु`,Th:`गु`,Fr:`शु`,Sa:`श`,"just now":`अभी`,"in a moment":`थोड़ी देर में`,"in 1 minute":`1 मिनट में`,"in {n} minutes":`{n} मिनट में`,"in 1 hour":`1 घंटे में`,"in {n} hours":`{n} घंटे में`,tomorrow:`कल`,"in {n} days":`{n} दिन में`,"in 1 week":`1 हफ़्ते में`,"in {n} weeks":`{n} हफ़्ते में`,"in 1 month":`1 महीने में`,"in {n} months":`{n} महीने में`,"in 1 year":`1 साल में`,"in {n} years":`{n} साल में`,"1 minute ago":`1 मिनट पहले`,"{n} minutes ago":`{n} मिनट पहले`,"1 hour ago":`1 घंटे पहले`,"{n} hours ago":`{n} घंटे पहले`,"1 day ago":`1 दिन पहले`,"{n} days ago":`{n} दिन पहले`,"1 week ago":`1 हफ़्ते पहले`,"{n} weeks ago":`{n} हफ़्ते पहले`,"1 month ago":`1 महीने पहले`,"{n} months ago":`{n} महीने पहले`,"1 year ago":`1 साल पहले`,"{n} years ago":`{n} साल पहले`,"Cookie notice":`कुकी सूचना`,"Cookie preferences":`कुकी प्राथमिकताएँ`,"Close and use essential cookies only":`बंद करें और केवल आवश्यक कुकीज़ का उपयोग करें`,Back:`वापस`,"Log in":`लॉग इन`,"Search Hanzo or ask AI":`Hanzo में खोजें या AI से पूछें`,"Search models":`मॉडल खोजें`,"Search branches…":`ब्रांच खोजें…`,"Search repositories…":`रिपॉज़िटरी खोजें…`,"Show options":`विकल्प दिखाएँ`,Retry:`फिर से कोशिश करें`,"Donut chart":`डोनट चार्ट`,"Find an organization":`संगठन खोजें`,Organizations:`संगठन`,"Organization name":`संगठन का नाम`,"Previous page":`पिछला पृष्ठ`,"Next page":`अगला पृष्ठ`,"Continue with credits":`क्रेडिट से जारी रखें`,"Try Hanzo":`Hanzo आज़माएँ`,"Terms & Policies":`नियम और नीतियाँ`,"Who this is for":`यह किसके लिए है`,"Bill yearly":`वार्षिक बिल`,Apps:`ऐप्स`,"Card actions":`कार्ड क्रियाएँ`,"Assign to...":`इसे असाइन करें...`,"Search cards...":`कार्ड खोजें...`,"Clear search":`खोज साफ़ करें`,"Open files":`खुली फ़ाइलें`,"Close panel":`पैनल बंद करें`,"Add an organization":`संगठन जोड़ें`,"Keyboard Shortcuts":`कीबोर्ड शॉर्टकट`,"Run a command":`कमांड चलाएँ`,"Type shell command...":`शेल कमांड लिखें...`,"Attached to the next message":`अगले संदेश से जुड़ा`,"Channel Member Roster":`चैनल सदस्य`,"Channel Collaborative Notes":`चैनल के साझा नोट`,"Code Diff Viewer":`कोड डिफ़ व्यूअर`,"Live Voice Call":`लाइव वॉइस कॉल`,"MCP Server Hub":`MCP सर्वर हब`,"Multi-Agent Swarm Bar":`मल्टी-एजेंट स्वार्म बार`,"Write shared channel notes, meeting agenda, or AI summaries...":`चैनल नोट, एजेंडा या AI सार लिखें...`,"Help improve our AI models":`हमारे AI मॉडल बेहतर बनाने में मदद करें`,"Your name":`आपका नाम`,"Your role":`आपकी भूमिका`,"Country or region":`देश या क्षेत्र`,"Card details":`कार्ड विवरण`,"Agree to recurring charges":`आवर्ती शुल्क से सहमत हूँ`,"How you will use Hanzo":`आप Hanzo का उपयोग कैसे करेंगे`,"Team size":`टीम का आकार`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`मैं सेवा की शर्तों और स्वीकार्य उपयोग नीति से सहमत हूँ और पुष्टि करता हूँ कि मेरी आयु कम से कम 18 वर्ष है।`,"Empty string":`खाली स्ट्रिंग`,"Empty array":`खाली ऐरे`,"Empty object":`खाली ऑब्जेक्ट`,"Copy {what}":`{what} कॉपी करें`,"Ask anything":`कुछ भी पूछें`,Auto:`ऑटो`,Instant:`तुरंत`,Low:`कम`,Medium:`मध्यम`,High:`उच्च`,Max:`अधिकतम`,Dictate:`डिक्टेट`,"Dictating — click to stop":`डिक्टेशन चालू है — रोकने के लिए क्लिक करें`,"Dictation settings":`डिक्टेशन सेटिंग`,Language:`भाषा`,"No devices found":`कोई डिवाइस नहीं मिला`,"Microphone {n}":`माइक्रोफ़ोन {n}`,"Nothing matches":`कुछ मेल नहीं खाता`,Commands:`कमांड`,"Search commands…":`कमांड खोजें…`,Agents:`एजेंट`,Skills:`कौशल`,Connectors:`कनेक्टर`,"Design system":`डिज़ाइन सिस्टम`,Plugins:`प्लगइन`,Devices:`डिवाइस`,Memory:`मेमोरी`,Research:`रिसर्च`,On:`चालू`,"Upload or add files":`फ़ाइलें अपलोड या जोड़ें`,"Add files, agents, skills and more":`फ़ाइलें, एजेंट, कौशल और अधिक जोड़ें`,"No agents yet":`अभी कोई एजेंट नहीं`,"No skills yet":`अभी कोई कौशल नहीं`,"No connectors yet":`अभी कोई कनेक्टर नहीं`,"No design system yet":`अभी कोई डिज़ाइन सिस्टम नहीं`,"No plugins yet":`अभी कोई प्लगइन नहीं`,"No devices yet":`अभी कोई डिवाइस नहीं`,"Search agents":`एजेंट खोजें`,"Search skills":`कौशल खोजें`,"Search connectors":`कनेक्टर खोजें`,"Search design system":`डिज़ाइन सिस्टम खोजें`,"Search plugins":`प्लगइन खोजें`,"Search devices":`डिवाइस खोजें`,"Reading agents":`एजेंट पढ़े जा रहे हैं`,"Reading skills":`कौशल पढ़े जा रहे हैं`,"Reading connectors":`कनेक्टर पढ़े जा रहे हैं`,"Reading design system":`डिज़ाइन सिस्टम पढ़ा जा रहा है`,"Reading plugins":`प्लगइन पढ़े जा रहे हैं`,"Adaptive reasoning based on task complexity":`कार्य की जटिलता के अनुसार अनुकूल तर्क`,"Answers right away, without thinking":`बिना सोचे तुरंत जवाब देता है`,"A quick pass with minimal thinking":`कम सोच के साथ एक त्वरित पास`,"Thinks before answering":`जवाब से पहले सोचता है`,"Deep reasoning for complex problems":`जटिल समस्याओं के लिए गहरा तर्क`,"Maximum compute and exhaustive verification":`अधिकतम कंप्यूट और पूरी जाँच`,Effort:`प्रयास`,"Effort: {level}":`प्रयास: {level}`,Mode:`मोड`,"Mode: {mode}":`मोड: {mode}`,Model:`मॉडल`,"Model: {name}":`मॉडल: {name}`,"Voice mode":`वॉइस मोड`,"Hanzo is speaking — talk to interrupt":`Hanzo बोल रहा है — बीच में बोलें`,"In conversation — click to hang up":`बातचीत में — काटने के लिए क्लिक करें`,"Go to testimonial {n}":`प्रशंसापत्र {n} पर जाएँ`,"Go to card {n}":`कार्ड {n} पर जाएँ`,"{n} of {total}":`{n} / {total}`,"Reading…":`पढ़ा जा रहा है…`,Skill:`कौशल`,Plugin:`प्लगइन`},Fne={Close:`Tutup`,"Close window":`Tutup jendela`,"Minimize window":`Minimalkan jendela`,"Restore window":`Pulihkan jendela`,"Maximize window":`Maksimalkan jendela`,Resize:`Ubah ukuran`,"Select all":`Pilih semua`,"Select row":`Pilih baris`,"Previous month":`Bulan sebelumnya`,"Next month":`Bulan berikutnya`,Dismiss:`Tutup`,Breadcrumb:`Jejak navigasi`,Cards:`Kartu`,"Copy code":`Salin kode`,Copied:`Disalin`,"Copied!":`Disalin!`,Copy:`Salin`,"Previous slide":`Slide sebelumnya`,"Next slide":`Slide berikutnya`,"Previous card":`Kartu sebelumnya`,"Next card":`Kartu berikutnya`,"Zoom out":`Perkecil`,"Zoom in":`Perbesar`,Rotate:`Putar`,Filter:`Filter`,"Expand all":`Bentangkan semua`,"Collapse all":`Ciutkan semua`,"Search...":`Cari...`,"Pick a date":`Pilih tanggal`,Select:`Pilih`,"Start typing...":`Mulai mengetik...`,Search:`Cari`,Decrease:`Kurangi`,Increase:`Tambah`,pagination:`paginasi`,"Go to previous page":`Ke halaman sebelumnya`,"Go to next page":`Ke halaman berikutnya`,Previous:`Sebelumnya`,Next:`Berikutnya`,"More pages":`Halaman lainnya`,Remove:`Hapus`,"Go back":`Kembali`,"Go forward":`Maju`,"Reload page":`Muat ulang halaman`,Share:`Bagikan`,"New tab":`Tab baru`,Menu:`Menu`,"Copy command":`Salin perintah`,"Terminal input":`Masukan terminal`,Seek:`Geser`,"Rewind 10 seconds":`Mundur 10 detik`,"Forward 10 seconds":`Maju 10 detik`,Volume:`Volume`,"Toggle captions":`Alihkan takarir`,"Playback speed":`Kecepatan pemutaran`,Quality:`Kualitas`,"Picture in picture":`Gambar dalam gambar`,Play:`Putar`,Pause:`Jeda`,Mute:`Bisukan`,Unmute:`Nyalakan suara`,"Exit fullscreen":`Keluar dari layar penuh`,"Enter fullscreen":`Layar penuh`,Expand:`Bentangkan`,Collapse:`Ciutkan`,"Copy reply":`Salin balasan`,"Good result":`Hasil baik`,"Bad result":`Hasil buruk`,"Dialog Close":`Tutup dialog`,Notifications:`Notifikasi`,Account:`Akun`,Cart:`Keranjang`,Call:`Panggilan`,"Video call":`Panggilan video`,Message:`Pesan`,Main:`Utama`,Columns:`Kolom`,"No results.":`Tidak ada hasil.`,"No results":`Tidak ada hasil`,"No results found":`Tidak ada hasil yang ditemukan`,"Drop files here":`Letakkan file di sini`,"Drag & drop files here":`Seret dan lepas file di sini`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`atau klik untuk menelusuri (maks. {maxFiles} file, masing-masing {maxSize} MB)`,"Remove {name}":`Hapus {name}`,"{selected} of {total} row(s) selected.":`{selected} dari {total} baris dipilih.`,"Try again":`Coba lagi`,"What’s up next?":`Selanjutnya apa?`,"Show password":`Tampilkan kata sandi`,"Hide password":`Sembunyikan kata sandi`,"Search icons":`Cari ikon`,"No icon matches":`Tidak ada ikon yang cocok`,"Show all items ({n})":`Tampilkan semua ({n})`,"Fewer {what}":`Lebih sedikit {what}`,"More {what}":`Lebih banyak {what}`,"No tasks available. Add tasks to display Gantt chart.":`Tidak ada tugas. Tambahkan tugas untuk menampilkan bagan Gantt.`,January:`Januari`,February:`Februari`,March:`Maret`,April:`April`,May:`Mei`,June:`Juni`,July:`Juli`,August:`Agustus`,September:`September`,October:`Oktober`,November:`November`,December:`Desember`,Su:`Mg`,Mo:`Sn`,Tu:`Sl`,We:`Rb`,Th:`Km`,Fr:`Jm`,Sa:`Sb`,"just now":`baru saja`,"in a moment":`sebentar lagi`,"in 1 minute":`dalam 1 menit`,"in {n} minutes":`dalam {n} menit`,"in 1 hour":`dalam 1 jam`,"in {n} hours":`dalam {n} jam`,tomorrow:`besok`,"in {n} days":`dalam {n} hari`,"in 1 week":`dalam 1 minggu`,"in {n} weeks":`dalam {n} minggu`,"in 1 month":`dalam 1 bulan`,"in {n} months":`dalam {n} bulan`,"in 1 year":`dalam 1 tahun`,"in {n} years":`dalam {n} tahun`,"1 minute ago":`1 menit yang lalu`,"{n} minutes ago":`{n} menit yang lalu`,"1 hour ago":`1 jam yang lalu`,"{n} hours ago":`{n} jam yang lalu`,"1 day ago":`1 hari yang lalu`,"{n} days ago":`{n} hari yang lalu`,"1 week ago":`1 minggu yang lalu`,"{n} weeks ago":`{n} minggu yang lalu`,"1 month ago":`1 bulan yang lalu`,"{n} months ago":`{n} bulan yang lalu`,"1 year ago":`1 tahun yang lalu`,"{n} years ago":`{n} tahun yang lalu`,"Cookie notice":`Pemberitahuan cookie`,"Cookie preferences":`Preferensi cookie`,"Close and use essential cookies only":`Tutup dan gunakan cookie penting saja`,Back:`Kembali`,"Log in":`Masuk`,"Search Hanzo or ask AI":`Cari di Hanzo atau tanya AI`,"Search models":`Cari model`,"Search branches…":`Cari cabang…`,"Search repositories…":`Cari repositori…`,"Show options":`Tampilkan opsi`,Retry:`Coba lagi`,"Donut chart":`Diagram donat`,"Find an organization":`Cari organisasi`,Organizations:`Organisasi`,"Organization name":`Nama organisasi`,"Previous page":`Halaman sebelumnya`,"Next page":`Halaman berikutnya`,"Continue with credits":`Lanjutkan dengan kredit`,"Try Hanzo":`Coba Hanzo`,"Terms & Policies":`Syarat dan kebijakan`,"Who this is for":`Untuk siapa`,"Bill yearly":`Tagihan tahunan`,Apps:`Aplikasi`,"Card actions":`Tindakan kartu`,"Assign to...":`Tetapkan ke...`,"Search cards...":`Cari kartu...`,"Clear search":`Hapus pencarian`,"Open files":`File terbuka`,"Close panel":`Tutup panel`,"Add an organization":`Tambah organisasi`,"Keyboard Shortcuts":`Pintasan keyboard`,"Run a command":`Jalankan perintah`,"Type shell command...":`Ketik perintah shell...`,"Attached to the next message":`Dilampirkan ke pesan berikutnya`,"Channel Member Roster":`Anggota kanal`,"Channel Collaborative Notes":`Catatan kolaboratif kanal`,"Code Diff Viewer":`Penampil diff kode`,"Live Voice Call":`Panggilan suara langsung`,"MCP Server Hub":`Hub server MCP`,"Multi-Agent Swarm Bar":`Bilah kawanan agen`,"Write shared channel notes, meeting agenda, or AI summaries...":`Tulis catatan kanal, agenda, atau ringkasan AI...`,"Help improve our AI models":`Bantu tingkatkan model AI kami`,"Your name":`Nama Anda`,"Your role":`Peran Anda`,"Country or region":`Negara atau wilayah`,"Card details":`Detail kartu`,"Agree to recurring charges":`Setuju dengan tagihan berulang`,"How you will use Hanzo":`Cara Anda memakai Hanzo`,"Team size":`Ukuran tim`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Saya menyetujui Ketentuan Layanan dan Kebijakan Penggunaan yang Dapat Diterima serta menyatakan berusia minimal 18 tahun.`,"Empty string":`String kosong`,"Empty array":`Array kosong`,"Empty object":`Objek kosong`,"Copy {what}":`Salin {what}`,"Ask anything":`Tanyakan apa saja`,Auto:`Otomatis`,Instant:`Instan`,Low:`Rendah`,Medium:`Sedang`,High:`Tinggi`,Max:`Maks`,Dictate:`Dikte`,"Dictating — click to stop":`Sedang mendikte — klik untuk berhenti`,"Dictation settings":`Pengaturan dikte`,Language:`Bahasa`,"No devices found":`Tidak ada perangkat`,"Microphone {n}":`Mikrofon {n}`,"Nothing matches":`Tidak ada yang cocok`,Commands:`Perintah`,"Search commands…":`Cari perintah…`,Agents:`Agen`,Skills:`Keterampilan`,Connectors:`Konektor`,"Design system":`Sistem desain`,Plugins:`Plugin`,Devices:`Perangkat`,Memory:`Memori`,Research:`Riset`,On:`Nyala`,"Upload or add files":`Unggah atau tambah file`,"Add files, agents, skills and more":`Tambah file, agen, keterampilan, dan lainnya`,"No agents yet":`Belum ada agen`,"No skills yet":`Belum ada keterampilan`,"No connectors yet":`Belum ada konektor`,"No design system yet":`Belum ada sistem desain`,"No plugins yet":`Belum ada plugin`,"No devices yet":`Belum ada perangkat`,"Search agents":`Cari agen`,"Search skills":`Cari keterampilan`,"Search connectors":`Cari konektor`,"Search design system":`Cari sistem desain`,"Search plugins":`Cari plugin`,"Search devices":`Cari perangkat`,"Reading agents":`Membaca agen`,"Reading skills":`Membaca keterampilan`,"Reading connectors":`Membaca konektor`,"Reading design system":`Membaca sistem desain`,"Reading plugins":`Membaca plugin`,"Adaptive reasoning based on task complexity":`Penalaran adaptif sesuai kompleksitas tugas`,"Answers right away, without thinking":`Langsung menjawab, tanpa berpikir`,"A quick pass with minimal thinking":`Lewatan cepat dengan sedikit penalaran`,"Thinks before answering":`Berpikir sebelum menjawab`,"Deep reasoning for complex problems":`Penalaran mendalam untuk masalah kompleks`,"Maximum compute and exhaustive verification":`Komputasi maksimum dan verifikasi menyeluruh`,Effort:`Upaya`,"Effort: {level}":`Upaya: {level}`,Mode:`Mode`,"Mode: {mode}":`Mode: {mode}`,Model:`Model`,"Model: {name}":`Model: {name}`,"Voice mode":`Mode suara`,"Hanzo is speaking — talk to interrupt":`Hanzo sedang berbicara — bicara untuk menyela`,"In conversation — click to hang up":`Sedang berbicara — klik untuk menutup`,"Go to testimonial {n}":`Ke testimoni {n}`,"Go to card {n}":`Ke kartu {n}`,"{n} of {total}":`{n} dari {total}`,"Reading…":`Membaca…`,Skill:`Keterampilan`,Plugin:`Plugin`},Ine={Close:`Chiudi`,"Close window":`Chiudi finestra`,"Minimize window":`Riduci a icona`,"Restore window":`Ripristina finestra`,"Maximize window":`Ingrandisci finestra`,Resize:`Ridimensiona`,"Select all":`Seleziona tutto`,"Select row":`Seleziona riga`,"Previous month":`Mese precedente`,"Next month":`Mese successivo`,Dismiss:`Chiudi`,Breadcrumb:`Percorso di navigazione`,Cards:`Schede`,"Copy code":`Copia codice`,Copied:`Copiato`,"Copied!":`Copiato!`,Copy:`Copia`,"Previous slide":`Diapositiva precedente`,"Next slide":`Diapositiva successiva`,"Previous card":`Scheda precedente`,"Next card":`Scheda successiva`,"Zoom out":`Riduci zoom`,"Zoom in":`Aumenta zoom`,Rotate:`Ruota`,Filter:`Filtra`,"Expand all":`Espandi tutto`,"Collapse all":`Comprimi tutto`,"Search...":`Cerca...`,"Pick a date":`Scegli una data`,Select:`Seleziona`,"Start typing...":`Inizia a scrivere...`,Search:`Cerca`,Decrease:`Diminuisci`,Increase:`Aumenta`,pagination:`paginazione`,"Go to previous page":`Vai alla pagina precedente`,"Go to next page":`Vai alla pagina successiva`,Previous:`Precedente`,Next:`Successivo`,"More pages":`Altre pagine`,Remove:`Rimuovi`,"Go back":`Indietro`,"Go forward":`Avanti`,"Reload page":`Ricarica pagina`,Share:`Condividi`,"New tab":`Nuova scheda`,Menu:`Menu`,"Copy command":`Copia comando`,"Terminal input":`Input del terminale`,Seek:`Posizione`,"Rewind 10 seconds":`Indietro di 10 secondi`,"Forward 10 seconds":`Avanti di 10 secondi`,Volume:`Volume`,"Toggle captions":`Attiva o disattiva i sottotitoli`,"Playback speed":`Velocità di riproduzione`,Quality:`Qualità`,"Picture in picture":`Picture in picture`,Play:`Riproduci`,Pause:`Pausa`,Mute:`Disattiva audio`,Unmute:`Attiva audio`,"Exit fullscreen":`Esci da schermo intero`,"Enter fullscreen":`Schermo intero`,Expand:`Espandi`,Collapse:`Comprimi`,"Copy reply":`Copia risposta`,"Good result":`Buon risultato`,"Bad result":`Risultato scarso`,"Dialog Close":`Chiudi finestra di dialogo`,Notifications:`Notifiche`,Account:`Account`,Cart:`Carrello`,Call:`Chiamata`,"Video call":`Videochiamata`,Message:`Messaggio`,Main:`Principale`,Columns:`Colonne`,"No results.":`Nessun risultato.`,"No results":`Nessun risultato`,"No results found":`Nessun risultato trovato`,"Drop files here":`Rilascia i file qui`,"Drag & drop files here":`Trascina i file qui`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`oppure fai clic per sfogliare (max {maxFiles} file, {maxSize} MB ciascuno)`,"Remove {name}":`Rimuovi {name}`,"{selected} of {total} row(s) selected.":`{selected} di {total} riga/righe selezionata/e.`,"Try again":`Riprova`,"What’s up next?":`Che cosa c’è dopo?`,"Show password":`Mostra password`,"Hide password":`Nascondi password`,"Search icons":`Cerca icone`,"No icon matches":`Nessuna icona corrisponde`,"Show all items ({n})":`Mostra tutti ({n})`,"Fewer {what}":`Meno {what}`,"More {what}":`Più {what}`,"No tasks available. Add tasks to display Gantt chart.":`Nessuna attività. Aggiungine per mostrare il diagramma di Gantt.`,January:`gennaio`,February:`febbraio`,March:`marzo`,April:`aprile`,May:`maggio`,June:`giugno`,July:`luglio`,August:`agosto`,September:`settembre`,October:`ottobre`,November:`novembre`,December:`dicembre`,Su:`do`,Mo:`lu`,Tu:`ma`,We:`me`,Th:`gi`,Fr:`ve`,Sa:`sa`,"just now":`proprio ora`,"in a moment":`tra un attimo`,"in 1 minute":`tra 1 minuto`,"in {n} minutes":`tra {n} minuti`,"in 1 hour":`tra 1 ora`,"in {n} hours":`tra {n} ore`,tomorrow:`domani`,"in {n} days":`tra {n} giorni`,"in 1 week":`tra 1 settimana`,"in {n} weeks":`tra {n} settimane`,"in 1 month":`tra 1 mese`,"in {n} months":`tra {n} mesi`,"in 1 year":`tra 1 anno`,"in {n} years":`tra {n} anni`,"1 minute ago":`1 minuto fa`,"{n} minutes ago":`{n} minuti fa`,"1 hour ago":`1 ora fa`,"{n} hours ago":`{n} ore fa`,"1 day ago":`1 giorno fa`,"{n} days ago":`{n} giorni fa`,"1 week ago":`1 settimana fa`,"{n} weeks ago":`{n} settimane fa`,"1 month ago":`1 mese fa`,"{n} months ago":`{n} mesi fa`,"1 year ago":`1 anno fa`,"{n} years ago":`{n} anni fa`,"Cookie notice":`Avviso sui cookie`,"Cookie preferences":`Preferenze cookie`,"Close and use essential cookies only":`Chiudi e usa solo i cookie essenziali`,Back:`Indietro`,"Log in":`Accedi`,"Search Hanzo or ask AI":`Cerca in Hanzo o chiedi all’IA`,"Search models":`Cerca modelli`,"Search branches…":`Cerca branch…`,"Search repositories…":`Cerca repository…`,"Show options":`Mostra opzioni`,Retry:`Riprova`,"Donut chart":`Grafico ad anello`,"Find an organization":`Trova un’organizzazione`,Organizations:`Organizzazioni`,"Organization name":`Nome dell’organizzazione`,"Previous page":`Pagina precedente`,"Next page":`Pagina successiva`,"Continue with credits":`Continua con i crediti`,"Try Hanzo":`Prova Hanzo`,"Terms & Policies":`Termini e politiche`,"Who this is for":`A chi è rivolto`,"Bill yearly":`Fatturazione annuale`,Apps:`App`,"Card actions":`Azioni della scheda`,"Assign to...":`Assegna a...`,"Search cards...":`Cerca schede...`,"Clear search":`Cancella ricerca`,"Open files":`File aperti`,"Close panel":`Chiudi pannello`,"Add an organization":`Aggiungi un’organizzazione`,"Keyboard Shortcuts":`Scorciatoie da tastiera`,"Run a command":`Esegui un comando`,"Type shell command...":`Digita un comando shell...`,"Attached to the next message":`Allegato al prossimo messaggio`,"Channel Member Roster":`Membri del canale`,"Channel Collaborative Notes":`Note collaborative del canale`,"Code Diff Viewer":`Visualizzatore diff`,"Live Voice Call":`Chiamata vocale dal vivo`,"MCP Server Hub":`Hub dei server MCP`,"Multi-Agent Swarm Bar":`Barra dello sciame di agenti`,"Write shared channel notes, meeting agenda, or AI summaries...":`Scrivi note condivise, l’ordine del giorno o riassunti dell’IA...`,"Help improve our AI models":`Aiuta a migliorare i nostri modelli di IA`,"Your name":`Il tuo nome`,"Your role":`Il tuo ruolo`,"Country or region":`Paese o area`,"Card details":`Dati della carta`,"Agree to recurring charges":`Accetto gli addebiti ricorrenti`,"How you will use Hanzo":`Come userai Hanzo`,"Team size":`Dimensione del team`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Accetto i Termini di servizio e la Politica di utilizzo accettabile e confermo di avere almeno 18 anni.`,"Empty string":`Stringa vuota`,"Empty array":`Array vuoto`,"Empty object":`Oggetto vuoto`,"Copy {what}":`Copia {what}`,"Ask anything":`Chiedi qualsiasi cosa`,Auto:`Auto`,Instant:`Istantaneo`,Low:`Basso`,Medium:`Medio`,High:`Alto`,Max:`Massimo`,Dictate:`Detta`,"Dictating — click to stop":`Dettatura in corso — fai clic per fermare`,"Dictation settings":`Impostazioni di dettatura`,Language:`Lingua`,"No devices found":`Nessun dispositivo trovato`,"Microphone {n}":`Microfono {n}`,"Nothing matches":`Nessuna corrispondenza`,Commands:`Comandi`,"Search commands…":`Cerca comandi…`,Agents:`Agenti`,Skills:`Competenze`,Connectors:`Connettori`,"Design system":`Sistema di design`,Plugins:`Plugin`,Devices:`Dispositivi`,Memory:`Memoria`,Research:`Ricerca`,On:`Attivo`,"Upload or add files":`Carica o aggiungi file`,"Add files, agents, skills and more":`Aggiungi file, agenti, competenze e altro`,"No agents yet":`Ancora nessun agente`,"No skills yet":`Ancora nessuna competenza`,"No connectors yet":`Ancora nessun connettore`,"No design system yet":`Ancora nessun sistema di design`,"No plugins yet":`Ancora nessun plugin`,"No devices yet":`Ancora nessun dispositivo`,"Search agents":`Cerca agenti`,"Search skills":`Cerca competenze`,"Search connectors":`Cerca connettori`,"Search design system":`Cerca nel sistema di design`,"Search plugins":`Cerca plugin`,"Search devices":`Cerca dispositivi`,"Reading agents":`Lettura degli agenti`,"Reading skills":`Lettura delle competenze`,"Reading connectors":`Lettura dei connettori`,"Reading design system":`Lettura del sistema di design`,"Reading plugins":`Lettura dei plugin`,"Adaptive reasoning based on task complexity":`Ragionamento adattivo in base alla complessità`,"Answers right away, without thinking":`Risponde subito, senza ragionare`,"A quick pass with minimal thinking":`Un passaggio rapido, con poco ragionamento`,"Thinks before answering":`Riflette prima di rispondere`,"Deep reasoning for complex problems":`Ragionamento profondo per problemi complessi`,"Maximum compute and exhaustive verification":`Calcolo massimo e verifica esaustiva`,Effort:`Sforzo`,"Effort: {level}":`Sforzo: {level}`,Mode:`Modalità`,"Mode: {mode}":`Modalità: {mode}`,Model:`Modello`,"Model: {name}":`Modello: {name}`,"Voice mode":`Modalità vocale`,"Hanzo is speaking — talk to interrupt":`Hanzo sta parlando — parla per interrompere`,"In conversation — click to hang up":`In conversazione — fai clic per riagganciare`,"Go to testimonial {n}":`Vai alla testimonianza {n}`,"Go to card {n}":`Vai alla scheda {n}`,"{n} of {total}":`{n} di {total}`,"Reading…":`Lettura…`,Skill:`Competenza`,Plugin:`Plugin`},Lne={Close:`閉じる`,"Close window":`ウィンドウを閉じる`,"Minimize window":`ウィンドウを最小化`,"Restore window":`ウィンドウを元に戻す`,"Maximize window":`ウィンドウを最大化`,Resize:`サイズ変更`,"Select all":`すべて選択`,"Select row":`行を選択`,"Previous month":`前の月`,"Next month":`次の月`,Dismiss:`閉じる`,Breadcrumb:`パンくずリスト`,Cards:`カード`,"Copy code":`コードをコピー`,Copied:`コピーしました`,"Copied!":`コピーしました`,Copy:`コピー`,"Previous slide":`前のスライド`,"Next slide":`次のスライド`,"Previous card":`前のカード`,"Next card":`次のカード`,"Zoom out":`縮小`,"Zoom in":`拡大`,Rotate:`回転`,Filter:`絞り込み`,"Expand all":`すべて展開`,"Collapse all":`すべて折りたたむ`,"Search...":`検索...`,"Pick a date":`日付を選択`,Select:`選択`,"Start typing...":`入力を開始...`,Search:`検索`,Decrease:`減らす`,Increase:`増やす`,pagination:`ページネーション`,"Go to previous page":`前のページへ`,"Go to next page":`次のページへ`,Previous:`前へ`,Next:`次へ`,"More pages":`その他のページ`,Remove:`削除`,"Go back":`戻る`,"Go forward":`進む`,"Reload page":`ページを再読み込み`,Share:`共有`,"New tab":`新しいタブ`,Menu:`メニュー`,"Copy command":`コマンドをコピー`,"Terminal input":`ターミナル入力`,Seek:`シーク`,"Rewind 10 seconds":`10秒戻る`,"Forward 10 seconds":`10秒進む`,Volume:`音量`,"Toggle captions":`字幕の切り替え`,"Playback speed":`再生速度`,Quality:`画質`,"Picture in picture":`ピクチャーインピクチャー`,Play:`再生`,Pause:`一時停止`,Mute:`ミュート`,Unmute:`ミュート解除`,"Exit fullscreen":`全画面を終了`,"Enter fullscreen":`全画面`,Expand:`展開`,Collapse:`折りたたむ`,"Copy reply":`返信をコピー`,"Good result":`良い結果`,"Bad result":`悪い結果`,"Dialog Close":`ダイアログを閉じる`,Notifications:`通知`,Account:`アカウント`,Cart:`カート`,Call:`通話`,"Video call":`ビデオ通話`,Message:`メッセージ`,Main:`メイン`,Columns:`列`,"No results.":`結果がありません。`,"No results":`結果なし`,"No results found":`結果が見つかりません`,"Drop files here":`ファイルをここにドロップ`,"Drag & drop files here":`ファイルをドラッグ&ドロップ`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`またはクリックして参照(最大 {maxFiles} ファイル、各 {maxSize} MB)`,"Remove {name}":`{name} を削除`,"{selected} of {total} row(s) selected.":`{total} 行中 {selected} 行を選択`,"Try again":`もう一度試す`,"What’s up next?":`次は何?`,"Show password":`パスワードを表示`,"Hide password":`パスワードを隠す`,"Search icons":`アイコンを検索`,"No icon matches":`一致するアイコンがありません`,"Show all items ({n})":`すべて表示 ({n})`,"Fewer {what}":`{what}を減らす`,"More {what}":`{what}を増やす`,"No tasks available. Add tasks to display Gantt chart.":`タスクがありません。ガントチャートを表示するにはタスクを追加してください。`,January:`1月`,February:`2月`,March:`3月`,April:`4月`,May:`5月`,June:`6月`,July:`7月`,August:`8月`,September:`9月`,October:`10月`,November:`11月`,December:`12月`,Su:`日`,Mo:`月`,Tu:`火`,We:`水`,Th:`木`,Fr:`金`,Sa:`土`,"just now":`たった今`,"in a moment":`まもなく`,"in 1 minute":`1分後`,"in {n} minutes":`{n}分後`,"in 1 hour":`1時間後`,"in {n} hours":`{n}時間後`,tomorrow:`明日`,"in {n} days":`{n}日後`,"in 1 week":`1週間後`,"in {n} weeks":`{n}週間後`,"in 1 month":`1か月後`,"in {n} months":`{n}か月後`,"in 1 year":`1年後`,"in {n} years":`{n}年後`,"1 minute ago":`1分前`,"{n} minutes ago":`{n}分前`,"1 hour ago":`1時間前`,"{n} hours ago":`{n}時間前`,"1 day ago":`1日前`,"{n} days ago":`{n}日前`,"1 week ago":`1週間前`,"{n} weeks ago":`{n}週間前`,"1 month ago":`1か月前`,"{n} months ago":`{n}か月前`,"1 year ago":`1年前`,"{n} years ago":`{n}年前`,"Cookie notice":`Cookie の通知`,"Cookie preferences":`Cookie の設定`,"Close and use essential cookies only":`閉じて必須 Cookie のみ使う`,Back:`戻る`,"Log in":`ログイン`,"Search Hanzo or ask AI":`Hanzo を検索するか AI に聞く`,"Search models":`モデルを検索`,"Search branches…":`ブランチを検索…`,"Search repositories…":`リポジトリを検索…`,"Show options":`オプションを表示`,Retry:`再試行`,"Donut chart":`ドーナツグラフ`,"Find an organization":`組織を探す`,Organizations:`組織`,"Organization name":`組織名`,"Previous page":`前のページ`,"Next page":`次のページ`,"Continue with credits":`クレジットで続ける`,"Try Hanzo":`Hanzo を試す`,"Terms & Policies":`規約とポリシー`,"Who this is for":`対象`,"Bill yearly":`年払い`,Apps:`アプリ`,"Card actions":`カードの操作`,"Assign to...":`割り当て先...`,"Search cards...":`カードを検索...`,"Clear search":`検索をクリア`,"Open files":`開いているファイル`,"Close panel":`パネルを閉じる`,"Add an organization":`組織を追加`,"Keyboard Shortcuts":`キーボードショートカット`,"Run a command":`コマンドを実行`,"Type shell command...":`シェルコマンドを入力...`,"Attached to the next message":`次のメッセージに添付`,"Channel Member Roster":`チャンネルのメンバー`,"Channel Collaborative Notes":`チャンネルの共同メモ`,"Code Diff Viewer":`差分ビューア`,"Live Voice Call":`ライブ音声通話`,"MCP Server Hub":`MCP サーバーハブ`,"Multi-Agent Swarm Bar":`マルチエージェントの群れバー`,"Write shared channel notes, meeting agenda, or AI summaries...":`共有メモ、議題、AI の要約を書く...`,"Help improve our AI models":`AI モデルの改善に協力する`,"Your name":`お名前`,"Your role":`あなたの役割`,"Country or region":`国または地域`,"Card details":`カード情報`,"Agree to recurring charges":`継続課金に同意する`,"How you will use Hanzo":`Hanzo の使い方`,"Team size":`チームの規模`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`利用規約と許容される使用に関するポリシーに同意し、18歳以上であることを確認します。`,"Empty string":`空の文字列`,"Empty array":`空の配列`,"Empty object":`空のオブジェクト`,"Copy {what}":`{what}をコピー`,"Ask anything":`何でも聞いてください`,Auto:`自動`,Instant:`即答`,Low:`低`,Medium:`中`,High:`高`,Max:`最大`,Dictate:`音声入力`,"Dictating — click to stop":`音声入力中 — クリックで停止`,"Dictation settings":`音声入力の設定`,Language:`言語`,"No devices found":`デバイスが見つかりません`,"Microphone {n}":`マイク {n}`,"Nothing matches":`一致するものがありません`,Commands:`コマンド`,"Search commands…":`コマンドを検索…`,Agents:`エージェント`,Skills:`スキル`,Connectors:`コネクタ`,"Design system":`デザインシステム`,Plugins:`プラグイン`,Devices:`デバイス`,Memory:`メモリ`,Research:`リサーチ`,On:`オン`,"Upload or add files":`ファイルをアップロードまたは追加`,"Add files, agents, skills and more":`ファイル、エージェント、スキルなどを追加`,"No agents yet":`エージェントはまだありません`,"No skills yet":`スキルはまだありません`,"No connectors yet":`コネクタはまだありません`,"No design system yet":`デザインシステムはまだありません`,"No plugins yet":`プラグインはまだありません`,"No devices yet":`デバイスはまだありません`,"Search agents":`エージェントを検索`,"Search skills":`スキルを検索`,"Search connectors":`コネクタを検索`,"Search design system":`デザインシステムを検索`,"Search plugins":`プラグインを検索`,"Search devices":`デバイスを検索`,"Reading agents":`エージェントを読み込み中`,"Reading skills":`スキルを読み込み中`,"Reading connectors":`コネクタを読み込み中`,"Reading design system":`デザインシステムを読み込み中`,"Reading plugins":`プラグインを読み込み中`,"Adaptive reasoning based on task complexity":`タスクの複雑さに合わせた推論`,"Answers right away, without thinking":`考えずにすぐに答えます`,"A quick pass with minimal thinking":`最小限の思考による素早い処理`,"Thinks before answering":`答える前に考える`,"Deep reasoning for complex problems":`複雑な問題のための深い推論`,"Maximum compute and exhaustive verification":`最大の計算と徹底した検証`,Effort:`思考量`,"Effort: {level}":`思考量: {level}`,Mode:`モード`,"Mode: {mode}":`モード: {mode}`,Model:`モデル`,"Model: {name}":`モデル: {name}`,"Voice mode":`音声モード`,"Hanzo is speaking — talk to interrupt":`Hanzo が話しています — 話すと中断します`,"In conversation — click to hang up":`会話中 — クリックで終了`,"Go to testimonial {n}":`お客様の声 {n} へ`,"Go to card {n}":`カード {n} へ`,"{n} of {total}":`{n} / {total}`,"Reading…":`読み込み中…`,Skill:`スキル`,Plugin:`プラグイン`},Rne={Close:`닫기`,"Close window":`창 닫기`,"Minimize window":`창 최소화`,"Restore window":`창 복원`,"Maximize window":`창 최대화`,Resize:`크기 조절`,"Select all":`모두 선택`,"Select row":`행 선택`,"Previous month":`이전 달`,"Next month":`다음 달`,Dismiss:`닫기`,Breadcrumb:`이동 경로`,Cards:`카드`,"Copy code":`코드 복사`,Copied:`복사됨`,"Copied!":`복사됨!`,Copy:`복사`,"Previous slide":`이전 슬라이드`,"Next slide":`다음 슬라이드`,"Previous card":`이전 카드`,"Next card":`다음 카드`,"Zoom out":`축소`,"Zoom in":`확대`,Rotate:`회전`,Filter:`필터`,"Expand all":`모두 펼치기`,"Collapse all":`모두 접기`,"Search...":`검색...`,"Pick a date":`날짜 선택`,Select:`선택`,"Start typing...":`입력 시작...`,Search:`검색`,Decrease:`줄이기`,Increase:`늘리기`,pagination:`페이지 매김`,"Go to previous page":`이전 페이지로`,"Go to next page":`다음 페이지로`,Previous:`이전`,Next:`다음`,"More pages":`페이지 더보기`,Remove:`제거`,"Go back":`뒤로`,"Go forward":`앞으로`,"Reload page":`페이지 새로고침`,Share:`공유`,"New tab":`새 탭`,Menu:`메뉴`,"Copy command":`명령 복사`,"Terminal input":`터미널 입력`,Seek:`탐색`,"Rewind 10 seconds":`10초 되감기`,"Forward 10 seconds":`10초 빨리감기`,Volume:`음량`,"Toggle captions":`자막 전환`,"Playback speed":`재생 속도`,Quality:`화질`,"Picture in picture":`화면 속 화면`,Play:`재생`,Pause:`일시정지`,Mute:`음소거`,Unmute:`음소거 해제`,"Exit fullscreen":`전체 화면 종료`,"Enter fullscreen":`전체 화면`,Expand:`펼치기`,Collapse:`접기`,"Copy reply":`답변 복사`,"Good result":`좋은 결과`,"Bad result":`나쁜 결과`,"Dialog Close":`대화상자 닫기`,Notifications:`알림`,Account:`계정`,Cart:`장바구니`,Call:`통화`,"Video call":`영상 통화`,Message:`메시지`,Main:`기본`,Columns:`열`,"No results.":`결과가 없습니다.`,"No results":`결과 없음`,"No results found":`결과를 찾을 수 없습니다`,"Drop files here":`파일을 여기에 놓으세요`,"Drag & drop files here":`파일을 끌어다 놓으세요`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`또는 클릭하여 찾아보기 (최대 {maxFiles}개 파일, 각 {maxSize}MB)`,"Remove {name}":`{name} 제거`,"{selected} of {total} row(s) selected.":`{total}개 중 {selected}개 행 선택됨`,"Try again":`다시 시도`,"What’s up next?":`다음은 무엇인가요?`,"Show password":`비밀번호 표시`,"Hide password":`비밀번호 숨기기`,"Search icons":`아이콘 검색`,"No icon matches":`일치하는 아이콘 없음`,"Show all items ({n})":`모두 보기 ({n})`,"Fewer {what}":`{what} 줄이기`,"More {what}":`{what} 늘리기`,"No tasks available. Add tasks to display Gantt chart.":`작업이 없습니다. 간트 차트를 보려면 작업을 추가하세요.`,January:`1월`,February:`2월`,March:`3월`,April:`4월`,May:`5월`,June:`6월`,July:`7월`,August:`8월`,September:`9월`,October:`10월`,November:`11월`,December:`12월`,Su:`일`,Mo:`월`,Tu:`화`,We:`수`,Th:`목`,Fr:`금`,Sa:`토`,"just now":`방금`,"in a moment":`곧`,"in 1 minute":`1분 후`,"in {n} minutes":`{n}분 후`,"in 1 hour":`1시간 후`,"in {n} hours":`{n}시간 후`,tomorrow:`내일`,"in {n} days":`{n}일 후`,"in 1 week":`1주 후`,"in {n} weeks":`{n}주 후`,"in 1 month":`1개월 후`,"in {n} months":`{n}개월 후`,"in 1 year":`1년 후`,"in {n} years":`{n}년 후`,"1 minute ago":`1분 전`,"{n} minutes ago":`{n}분 전`,"1 hour ago":`1시간 전`,"{n} hours ago":`{n}시간 전`,"1 day ago":`1일 전`,"{n} days ago":`{n}일 전`,"1 week ago":`1주 전`,"{n} weeks ago":`{n}주 전`,"1 month ago":`1개월 전`,"{n} months ago":`{n}개월 전`,"1 year ago":`1년 전`,"{n} years ago":`{n}년 전`,"Cookie notice":`쿠키 안내`,"Cookie preferences":`쿠키 설정`,"Close and use essential cookies only":`닫고 필수 쿠키만 사용`,Back:`뒤로`,"Log in":`로그인`,"Search Hanzo or ask AI":`Hanzo 검색 또는 AI에게 질문`,"Search models":`모델 검색`,"Search branches…":`브랜치 검색…`,"Search repositories…":`저장소 검색…`,"Show options":`옵션 표시`,Retry:`다시 시도`,"Donut chart":`도넛 차트`,"Find an organization":`조직 찾기`,Organizations:`조직`,"Organization name":`조직 이름`,"Previous page":`이전 페이지`,"Next page":`다음 페이지`,"Continue with credits":`크레딧으로 계속`,"Try Hanzo":`Hanzo 체험`,"Terms & Policies":`약관 및 정책`,"Who this is for":`대상`,"Bill yearly":`연간 결제`,Apps:`앱`,"Card actions":`카드 작업`,"Assign to...":`할당 대상...`,"Search cards...":`카드 검색...`,"Clear search":`검색어 지우기`,"Open files":`열린 파일`,"Close panel":`패널 닫기`,"Add an organization":`조직 추가`,"Keyboard Shortcuts":`키보드 단축키`,"Run a command":`명령 실행`,"Type shell command...":`셸 명령 입력...`,"Attached to the next message":`다음 메시지에 첨부됨`,"Channel Member Roster":`채널 구성원`,"Channel Collaborative Notes":`채널 공동 메모`,"Code Diff Viewer":`코드 차이 보기`,"Live Voice Call":`실시간 음성 통화`,"MCP Server Hub":`MCP 서버 허브`,"Multi-Agent Swarm Bar":`다중 에이전트 군집 막대`,"Write shared channel notes, meeting agenda, or AI summaries...":`공유 메모, 안건 또는 AI 요약을 작성...`,"Help improve our AI models":`AI 모델 개선에 참여`,"Your name":`이름`,"Your role":`역할`,"Country or region":`국가 또는 지역`,"Card details":`카드 정보`,"Agree to recurring charges":`정기 결제에 동의`,"How you will use Hanzo":`Hanzo 사용 방식`,"Team size":`팀 규모`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`서비스 약관과 허용 사용 정책에 동의하며 만 18세 이상임을 확인합니다.`,"Empty string":`빈 문자열`,"Empty array":`빈 배열`,"Empty object":`빈 객체`,"Copy {what}":`{what} 복사`,"Ask anything":`무엇이든 물어보세요`,Auto:`자동`,Instant:`즉시`,Low:`낮음`,Medium:`중간`,High:`높음`,Max:`최대`,Dictate:`받아쓰기`,"Dictating — click to stop":`받아쓰는 중 — 클릭하여 중지`,"Dictation settings":`받아쓰기 설정`,Language:`언어`,"No devices found":`기기를 찾을 수 없습니다`,"Microphone {n}":`마이크 {n}`,"Nothing matches":`일치하는 항목 없음`,Commands:`명령`,"Search commands…":`명령 검색…`,Agents:`에이전트`,Skills:`스킬`,Connectors:`커넥터`,"Design system":`디자인 시스템`,Plugins:`플러그인`,Devices:`기기`,Memory:`메모리`,Research:`리서치`,On:`켜짐`,"Upload or add files":`파일 업로드 또는 추가`,"Add files, agents, skills and more":`파일, 에이전트, 스킬 등 추가`,"No agents yet":`아직 에이전트가 없습니다`,"No skills yet":`아직 스킬이 없습니다`,"No connectors yet":`아직 커넥터가 없습니다`,"No design system yet":`아직 디자인 시스템이 없습니다`,"No plugins yet":`아직 플러그인이 없습니다`,"No devices yet":`아직 기기가 없습니다`,"Search agents":`에이전트 검색`,"Search skills":`스킬 검색`,"Search connectors":`커넥터 검색`,"Search design system":`디자인 시스템 검색`,"Search plugins":`플러그인 검색`,"Search devices":`기기 검색`,"Reading agents":`에이전트 읽는 중`,"Reading skills":`스킬 읽는 중`,"Reading connectors":`커넥터 읽는 중`,"Reading design system":`디자인 시스템 읽는 중`,"Reading plugins":`플러그인 읽는 중`,"Adaptive reasoning based on task complexity":`작업 복잡도에 맞춘 추론`,"Answers right away, without thinking":`생각하지 않고 바로 답합니다`,"A quick pass with minimal thinking":`최소한의 사고로 빠르게`,"Thinks before answering":`답하기 전에 생각`,"Deep reasoning for complex problems":`복잡한 문제를 위한 깊은 추론`,"Maximum compute and exhaustive verification":`최대 연산과 철저한 검증`,Effort:`노력`,"Effort: {level}":`노력: {level}`,Mode:`모드`,"Mode: {mode}":`모드: {mode}`,Model:`모델`,"Model: {name}":`모델: {name}`,"Voice mode":`음성 모드`,"Hanzo is speaking — talk to interrupt":`Hanzo가 말하는 중 — 말하면 중단`,"In conversation — click to hang up":`대화 중 — 클릭하여 종료`,"Go to testimonial {n}":`후기 {n}(으)로`,"Go to card {n}":`카드 {n}(으)로`,"{n} of {total}":`{n} / {total}`,"Reading…":`읽는 중…`,Skill:`스킬`,Plugin:`플러그인`},zne={Close:`Fechar`,"Close window":`Fechar janela`,"Minimize window":`Minimizar janela`,"Restore window":`Restaurar janela`,"Maximize window":`Maximizar janela`,Resize:`Redimensionar`,"Select all":`Selecionar tudo`,"Select row":`Selecionar linha`,"Previous month":`Mês anterior`,"Next month":`Próximo mês`,Dismiss:`Dispensar`,Breadcrumb:`Trilha de navegação`,Cards:`Cartões`,"Copy code":`Copiar código`,Copied:`Copiado`,"Copied!":`Copiado!`,Copy:`Copiar`,"Previous slide":`Slide anterior`,"Next slide":`Próximo slide`,"Previous card":`Cartão anterior`,"Next card":`Próximo cartão`,"Zoom out":`Diminuir zoom`,"Zoom in":`Aumentar zoom`,Rotate:`Girar`,Filter:`Filtrar`,"Expand all":`Expandir tudo`,"Collapse all":`Recolher tudo`,"Search...":`Pesquisar...`,"Pick a date":`Escolha uma data`,Select:`Selecionar`,"Start typing...":`Comece a digitar...`,Search:`Pesquisar`,Decrease:`Diminuir`,Increase:`Aumentar`,pagination:`paginação`,"Go to previous page":`Ir para a página anterior`,"Go to next page":`Ir para a próxima página`,Previous:`Anterior`,Next:`Próximo`,"More pages":`Mais páginas`,Remove:`Remover`,"Go back":`Voltar`,"Go forward":`Avançar`,"Reload page":`Recarregar página`,Share:`Compartilhar`,"New tab":`Nova aba`,Menu:`Menu`,"Copy command":`Copiar comando`,"Terminal input":`Entrada do terminal`,Seek:`Posição`,"Rewind 10 seconds":`Retroceder 10 segundos`,"Forward 10 seconds":`Avançar 10 segundos`,Volume:`Volume`,"Toggle captions":`Alternar legendas`,"Playback speed":`Velocidade de reprodução`,Quality:`Qualidade`,"Picture in picture":`Picture in picture`,Play:`Reproduzir`,Pause:`Pausar`,Mute:`Silenciar`,Unmute:`Ativar som`,"Exit fullscreen":`Sair da tela cheia`,"Enter fullscreen":`Tela cheia`,Expand:`Expandir`,Collapse:`Recolher`,"Copy reply":`Copiar resposta`,"Good result":`Bom resultado`,"Bad result":`Resultado ruim`,"Dialog Close":`Fechar diálogo`,Notifications:`Notificações`,Account:`Conta`,Cart:`Carrinho`,Call:`Chamada`,"Video call":`Chamada de vídeo`,Message:`Mensagem`,Main:`Principal`,Columns:`Colunas`,"No results.":`Nenhum resultado.`,"No results":`Nenhum resultado`,"No results found":`Nenhum resultado encontrado`,"Drop files here":`Solte os arquivos aqui`,"Drag & drop files here":`Arraste e solte arquivos aqui`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`ou clique para procurar (máx. {maxFiles} arquivos, {maxSize} MB cada)`,"Remove {name}":`Remover {name}`,"{selected} of {total} row(s) selected.":`{selected} de {total} linha(s) selecionada(s).`,"Try again":`Tentar novamente`,"What’s up next?":`O que vem agora?`,"Show password":`Mostrar senha`,"Hide password":`Ocultar senha`,"Search icons":`Pesquisar ícones`,"No icon matches":`Nenhum ícone corresponde`,"Show all items ({n})":`Mostrar todos ({n})`,"Fewer {what}":`Menos {what}`,"More {what}":`Mais {what}`,"No tasks available. Add tasks to display Gantt chart.":`Nenhuma tarefa. Adicione tarefas para exibir o gráfico de Gantt.`,January:`janeiro`,February:`fevereiro`,March:`março`,April:`abril`,May:`maio`,June:`junho`,July:`julho`,August:`agosto`,September:`setembro`,October:`outubro`,November:`novembro`,December:`dezembro`,Su:`do`,Mo:`se`,Tu:`te`,We:`qa`,Th:`qi`,Fr:`sx`,Sa:`sá`,"just now":`agora mesmo`,"in a moment":`em instantes`,"in 1 minute":`em 1 minuto`,"in {n} minutes":`em {n} minutos`,"in 1 hour":`em 1 hora`,"in {n} hours":`em {n} horas`,tomorrow:`amanhã`,"in {n} days":`em {n} dias`,"in 1 week":`em 1 semana`,"in {n} weeks":`em {n} semanas`,"in 1 month":`em 1 mês`,"in {n} months":`em {n} meses`,"in 1 year":`em 1 ano`,"in {n} years":`em {n} anos`,"1 minute ago":`há 1 minuto`,"{n} minutes ago":`há {n} minutos`,"1 hour ago":`há 1 hora`,"{n} hours ago":`há {n} horas`,"1 day ago":`há 1 dia`,"{n} days ago":`há {n} dias`,"1 week ago":`há 1 semana`,"{n} weeks ago":`há {n} semanas`,"1 month ago":`há 1 mês`,"{n} months ago":`há {n} meses`,"1 year ago":`há 1 ano`,"{n} years ago":`há {n} anos`,"Cookie notice":`Aviso de cookies`,"Cookie preferences":`Preferências de cookies`,"Close and use essential cookies only":`Fechar e usar apenas cookies essenciais`,Back:`Voltar`,"Log in":`Entrar`,"Search Hanzo or ask AI":`Pesquise na Hanzo ou pergunte à IA`,"Search models":`Pesquisar modelos`,"Search branches…":`Pesquisar branches…`,"Search repositories…":`Pesquisar repositórios…`,"Show options":`Mostrar opções`,Retry:`Tentar novamente`,"Donut chart":`Gráfico de rosca`,"Find an organization":`Encontrar uma organização`,Organizations:`Organizações`,"Organization name":`Nome da organização`,"Previous page":`Página anterior`,"Next page":`Próxima página`,"Continue with credits":`Continuar com créditos`,"Try Hanzo":`Experimentar a Hanzo`,"Terms & Policies":`Termos e políticas`,"Who this is for":`Para quem é`,"Bill yearly":`Cobrança anual`,Apps:`Aplicativos`,"Card actions":`Ações do cartão`,"Assign to...":`Atribuir a...`,"Search cards...":`Pesquisar cartões...`,"Clear search":`Limpar pesquisa`,"Open files":`Arquivos abertos`,"Close panel":`Fechar painel`,"Add an organization":`Adicionar uma organização`,"Keyboard Shortcuts":`Atalhos de teclado`,"Run a command":`Executar um comando`,"Type shell command...":`Digite um comando de shell...`,"Attached to the next message":`Anexado à próxima mensagem`,"Channel Member Roster":`Membros do canal`,"Channel Collaborative Notes":`Notas colaborativas do canal`,"Code Diff Viewer":`Visualizador de diff`,"Live Voice Call":`Chamada de voz ao vivo`,"MCP Server Hub":`Hub de servidores MCP`,"Multi-Agent Swarm Bar":`Barra do enxame de agentes`,"Write shared channel notes, meeting agenda, or AI summaries...":`Escreva notas do canal, a pauta ou resumos da IA...`,"Help improve our AI models":`Ajude a melhorar nossos modelos de IA`,"Your name":`Seu nome`,"Your role":`Seu papel`,"Country or region":`País ou região`,"Card details":`Dados do cartão`,"Agree to recurring charges":`Concordo com cobranças recorrentes`,"How you will use Hanzo":`Como você usará a Hanzo`,"Team size":`Tamanho da equipe`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Concordo com os Termos de Serviço e a Política de Uso Aceitável e confirmo que tenho pelo menos 18 anos.`,"Empty string":`Texto vazio`,"Empty array":`Array vazio`,"Empty object":`Objeto vazio`,"Copy {what}":`Copiar {what}`,"Ask anything":`Pergunte qualquer coisa`,Auto:`Auto`,Instant:`Instantâneo`,Low:`Baixo`,Medium:`Médio`,High:`Alto`,Max:`Máximo`,Dictate:`Ditar`,"Dictating — click to stop":`Ditando — clique para parar`,"Dictation settings":`Configurações de ditado`,Language:`Idioma`,"No devices found":`Nenhum dispositivo encontrado`,"Microphone {n}":`Microfone {n}`,"Nothing matches":`Nada corresponde`,Commands:`Comandos`,"Search commands…":`Pesquisar comandos…`,Agents:`Agentes`,Skills:`Habilidades`,Connectors:`Conectores`,"Design system":`Sistema de design`,Plugins:`Plugins`,Devices:`Dispositivos`,Memory:`Memória`,Research:`Pesquisa`,On:`Ativado`,"Upload or add files":`Enviar ou adicionar arquivos`,"Add files, agents, skills and more":`Adicione arquivos, agentes, habilidades e mais`,"No agents yet":`Ainda não há agentes`,"No skills yet":`Ainda não há habilidades`,"No connectors yet":`Ainda não há conectores`,"No design system yet":`Ainda não há sistema de design`,"No plugins yet":`Ainda não há plugins`,"No devices yet":`Ainda não há dispositivos`,"Search agents":`Pesquisar agentes`,"Search skills":`Pesquisar habilidades`,"Search connectors":`Pesquisar conectores`,"Search design system":`Pesquisar no sistema de design`,"Search plugins":`Pesquisar plugins`,"Search devices":`Pesquisar dispositivos`,"Reading agents":`Lendo agentes`,"Reading skills":`Lendo habilidades`,"Reading connectors":`Lendo conectores`,"Reading design system":`Lendo o sistema de design`,"Reading plugins":`Lendo plugins`,"Adaptive reasoning based on task complexity":`Raciocínio adaptativo conforme a complexidade da tarefa`,"Answers right away, without thinking":`Responde na hora, sem pensar`,"A quick pass with minimal thinking":`Uma passada rápida, com pouco raciocínio`,"Thinks before answering":`Pensa antes de responder`,"Deep reasoning for complex problems":`Raciocínio profundo para problemas complexos`,"Maximum compute and exhaustive verification":`Computação máxima e verificação exaustiva`,Effort:`Esforço`,"Effort: {level}":`Esforço: {level}`,Mode:`Modo`,"Mode: {mode}":`Modo: {mode}`,Model:`Modelo`,"Model: {name}":`Modelo: {name}`,"Voice mode":`Modo de voz`,"Hanzo is speaking — talk to interrupt":`A Hanzo está falando — fale para interromper`,"In conversation — click to hang up":`Em conversa — clique para desligar`,"Go to testimonial {n}":`Ir para o depoimento {n}`,"Go to card {n}":`Ir para o cartão {n}`,"{n} of {total}":`{n} de {total}`,"Reading…":`Lendo…`,Skill:`Habilidade`,Plugin:`Plugin`},Bne={Close:`Закрыть`,"Close window":`Закрыть окно`,"Minimize window":`Свернуть окно`,"Restore window":`Восстановить окно`,"Maximize window":`Развернуть окно`,Resize:`Изменить размер`,"Select all":`Выбрать все`,"Select row":`Выбрать строку`,"Previous month":`Предыдущий месяц`,"Next month":`Следующий месяц`,Dismiss:`Закрыть`,Breadcrumb:`Навигационная цепочка`,Cards:`Карточки`,"Copy code":`Копировать код`,Copied:`Скопировано`,"Copied!":`Скопировано!`,Copy:`Копировать`,"Previous slide":`Предыдущий слайд`,"Next slide":`Следующий слайд`,"Previous card":`Предыдущая карточка`,"Next card":`Следующая карточка`,"Zoom out":`Уменьшить`,"Zoom in":`Увеличить`,Rotate:`Повернуть`,Filter:`Фильтр`,"Expand all":`Развернуть все`,"Collapse all":`Свернуть все`,"Search...":`Поиск...`,"Pick a date":`Выберите дату`,Select:`Выбрать`,"Start typing...":`Начните вводить...`,Search:`Поиск`,Decrease:`Уменьшить`,Increase:`Увеличить`,pagination:`постраничная навигация`,"Go to previous page":`К предыдущей странице`,"Go to next page":`К следующей странице`,Previous:`Назад`,Next:`Далее`,"More pages":`Ещё страницы`,Remove:`Удалить`,"Go back":`Назад`,"Go forward":`Вперёд`,"Reload page":`Обновить страницу`,Share:`Поделиться`,"New tab":`Новая вкладка`,Menu:`Меню`,"Copy command":`Копировать команду`,"Terminal input":`Ввод в терминале`,Seek:`Позиция`,"Rewind 10 seconds":`Назад на 10 секунд`,"Forward 10 seconds":`Вперёд на 10 секунд`,Volume:`Громкость`,"Toggle captions":`Субтитры`,"Playback speed":`Скорость воспроизведения`,Quality:`Качество`,"Picture in picture":`Картинка в картинке`,Play:`Воспроизвести`,Pause:`Пауза`,Mute:`Выключить звук`,Unmute:`Включить звук`,"Exit fullscreen":`Выйти из полноэкранного режима`,"Enter fullscreen":`Полный экран`,Expand:`Развернуть`,Collapse:`Свернуть`,"Copy reply":`Копировать ответ`,"Good result":`Хороший результат`,"Bad result":`Плохой результат`,"Dialog Close":`Закрыть диалог`,Notifications:`Уведомления`,Account:`Аккаунт`,Cart:`Корзина`,Call:`Звонок`,"Video call":`Видеозвонок`,Message:`Сообщение`,Main:`Основное`,Columns:`Столбцы`,"No results.":`Ничего не найдено.`,"No results":`Ничего не найдено`,"No results found":`Ничего не найдено`,"Drop files here":`Перетащите файлы сюда`,"Drag & drop files here":`Перетащите файлы сюда`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`или нажмите, чтобы выбрать (не более {maxFiles} файлов, по {maxSize} МБ)`,"Remove {name}":`Удалить {name}`,"{selected} of {total} row(s) selected.":`Выбрано {selected} из {total}.`,"Try again":`Повторить`,"What’s up next?":`Что дальше?`,"Show password":`Показать пароль`,"Hide password":`Скрыть пароль`,"Search icons":`Поиск значков`,"No icon matches":`Нет подходящих значков`,"Show all items ({n})":`Показать все ({n})`,"Fewer {what}":`Меньше: {what}`,"More {what}":`Больше: {what}`,"No tasks available. Add tasks to display Gantt chart.":`Нет задач. Добавьте их, чтобы показать диаграмму Ганта.`,January:`январь`,February:`февраль`,March:`март`,April:`апрель`,May:`май`,June:`июнь`,July:`июль`,August:`август`,September:`сентябрь`,October:`октябрь`,November:`ноябрь`,December:`декабрь`,Su:`вс`,Mo:`пн`,Tu:`вт`,We:`ср`,Th:`чт`,Fr:`пт`,Sa:`сб`,"just now":`только что`,"in a moment":`через мгновение`,"in 1 minute":`через 1 минуту`,"in {n} minutes":`через {n} мин.`,"in 1 hour":`через 1 час`,"in {n} hours":`через {n} ч.`,tomorrow:`завтра`,"in {n} days":`через {n} дн.`,"in 1 week":`через 1 неделю`,"in {n} weeks":`через {n} нед.`,"in 1 month":`через 1 месяц`,"in {n} months":`через {n} мес.`,"in 1 year":`через 1 год`,"in {n} years":`через {n} г.`,"1 minute ago":`1 минуту назад`,"{n} minutes ago":`{n} мин. назад`,"1 hour ago":`1 час назад`,"{n} hours ago":`{n} ч. назад`,"1 day ago":`1 день назад`,"{n} days ago":`{n} дн. назад`,"1 week ago":`1 неделю назад`,"{n} weeks ago":`{n} нед. назад`,"1 month ago":`1 месяц назад`,"{n} months ago":`{n} мес. назад`,"1 year ago":`1 год назад`,"{n} years ago":`{n} г. назад`,"Cookie notice":`Уведомление о cookie`,"Cookie preferences":`Настройки cookie`,"Close and use essential cookies only":`Закрыть и оставить только необходимые cookie`,Back:`Назад`,"Log in":`Войти`,"Search Hanzo or ask AI":`Искать в Hanzo или спросить ИИ`,"Search models":`Поиск моделей`,"Search branches…":`Поиск веток…`,"Search repositories…":`Поиск репозиториев…`,"Show options":`Показать параметры`,Retry:`Повторить`,"Donut chart":`Кольцевая диаграмма`,"Find an organization":`Найти организацию`,Organizations:`Организации`,"Organization name":`Название организации`,"Previous page":`Предыдущая страница`,"Next page":`Следующая страница`,"Continue with credits":`Продолжить за счёт кредитов`,"Try Hanzo":`Попробовать Hanzo`,"Terms & Policies":`Условия и политики`,"Who this is for":`Для кого это`,"Bill yearly":`Оплата за год`,Apps:`Приложения`,"Card actions":`Действия с карточкой`,"Assign to...":`Назначить...`,"Search cards...":`Поиск карточек...`,"Clear search":`Очистить поиск`,"Open files":`Открытые файлы`,"Close panel":`Закрыть панель`,"Add an organization":`Добавить организацию`,"Keyboard Shortcuts":`Сочетания клавиш`,"Run a command":`Выполнить команду`,"Type shell command...":`Введите команду оболочки...`,"Attached to the next message":`Прикреплено к следующему сообщению`,"Channel Member Roster":`Участники канала`,"Channel Collaborative Notes":`Общие заметки канала`,"Code Diff Viewer":`Просмотр различий`,"Live Voice Call":`Голосовой звонок`,"MCP Server Hub":`Хаб серверов MCP`,"Multi-Agent Swarm Bar":`Панель роя агентов`,"Write shared channel notes, meeting agenda, or AI summaries...":`Пишите общие заметки, повестку или сводки ИИ...`,"Help improve our AI models":`Помогите улучшить наши модели ИИ`,"Your name":`Ваше имя`,"Your role":`Ваша роль`,"Country or region":`Страна или регион`,"Card details":`Данные карты`,"Agree to recurring charges":`Согласие на регулярные списания`,"How you will use Hanzo":`Как вы будете использовать Hanzo`,"Team size":`Размер команды`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Я принимаю Условия обслуживания и Политику допустимого использования и подтверждаю, что мне исполнилось 18 лет.`,"Empty string":`Пустая строка`,"Empty array":`Пустой массив`,"Empty object":`Пустой объект`,"Copy {what}":`Копировать {what}`,"Ask anything":`Спросите что угодно`,Auto:`Авто`,Instant:`Мгновенно`,Low:`Низкий`,Medium:`Средний`,High:`Высокий`,Max:`Максимум`,Dictate:`Диктовка`,"Dictating — click to stop":`Идёт диктовка — нажмите, чтобы остановить`,"Dictation settings":`Настройки диктовки`,Language:`Язык`,"No devices found":`Устройства не найдены`,"Microphone {n}":`Микрофон {n}`,"Nothing matches":`Ничего не найдено`,Commands:`Команды`,"Search commands…":`Поиск команд…`,Agents:`Агенты`,Skills:`Навыки`,Connectors:`Коннекторы`,"Design system":`Дизайн-система`,Plugins:`Плагины`,Devices:`Устройства`,Memory:`Память`,Research:`Исследование`,On:`Вкл.`,"Upload or add files":`Загрузить или добавить файлы`,"Add files, agents, skills and more":`Добавьте файлы, агентов, навыки и другое`,"No agents yet":`Агентов пока нет`,"No skills yet":`Навыков пока нет`,"No connectors yet":`Коннекторов пока нет`,"No design system yet":`Дизайн-системы пока нет`,"No plugins yet":`Плагинов пока нет`,"No devices yet":`Устройств пока нет`,"Search agents":`Поиск агентов`,"Search skills":`Поиск навыков`,"Search connectors":`Поиск коннекторов`,"Search design system":`Поиск в дизайн-системе`,"Search plugins":`Поиск плагинов`,"Search devices":`Поиск устройств`,"Reading agents":`Чтение агентов`,"Reading skills":`Чтение навыков`,"Reading connectors":`Чтение коннекторов`,"Reading design system":`Чтение дизайн-системы`,"Reading plugins":`Чтение плагинов`,"Adaptive reasoning based on task complexity":`Адаптивное рассуждение по сложности задачи`,"Answers right away, without thinking":`Отвечает сразу, без размышлений`,"A quick pass with minimal thinking":`Быстрый проход с минимумом размышлений`,"Thinks before answering":`Думает перед ответом`,"Deep reasoning for complex problems":`Глубокое рассуждение для сложных задач`,"Maximum compute and exhaustive verification":`Максимум вычислений и полная проверка`,Effort:`Усилие`,"Effort: {level}":`Усилие: {level}`,Mode:`Режим`,"Mode: {mode}":`Режим: {mode}`,Model:`Модель`,"Model: {name}":`Модель: {name}`,"Voice mode":`Голосовой режим`,"Hanzo is speaking — talk to interrupt":`Hanzo говорит — говорите, чтобы прервать`,"In conversation — click to hang up":`Разговор — нажмите, чтобы завершить`,"Go to testimonial {n}":`К отзыву {n}`,"Go to card {n}":`К карточке {n}`,"{n} of {total}":`{n} из {total}`,"Reading…":`Чтение…`,Skill:`Навык`,Plugin:`Плагин`},Vne={Close:`ปิด`,"Close window":`ปิดหน้าต่าง`,"Minimize window":`ย่อหน้าต่าง`,"Restore window":`คืนค่าหน้าต่าง`,"Maximize window":`ขยายหน้าต่าง`,Resize:`ปรับขนาด`,"Select all":`เลือกทั้งหมด`,"Select row":`เลือกแถว`,"Previous month":`เดือนก่อน`,"Next month":`เดือนถัดไป`,Dismiss:`ปิด`,Breadcrumb:`เส้นทางนำทาง`,Cards:`การ์ด`,"Copy code":`คัดลอกโค้ด`,Copied:`คัดลอกแล้ว`,"Copied!":`คัดลอกแล้ว!`,Copy:`คัดลอก`,"Previous slide":`สไลด์ก่อนหน้า`,"Next slide":`สไลด์ถัดไป`,"Previous card":`การ์ดก่อนหน้า`,"Next card":`การ์ดถัดไป`,"Zoom out":`ซูมออก`,"Zoom in":`ซูมเข้า`,Rotate:`หมุน`,Filter:`กรอง`,"Expand all":`ขยายทั้งหมด`,"Collapse all":`ยุบทั้งหมด`,"Search...":`ค้นหา...`,"Pick a date":`เลือกวันที่`,Select:`เลือก`,"Start typing...":`เริ่มพิมพ์...`,Search:`ค้นหา`,Decrease:`ลด`,Increase:`เพิ่ม`,pagination:`การแบ่งหน้า`,"Go to previous page":`ไปหน้าก่อนหน้า`,"Go to next page":`ไปหน้าถัดไป`,Previous:`ก่อนหน้า`,Next:`ถัดไป`,"More pages":`หน้าเพิ่มเติม`,Remove:`นำออก`,"Go back":`ย้อนกลับ`,"Go forward":`ไปข้างหน้า`,"Reload page":`โหลดหน้าใหม่`,Share:`แชร์`,"New tab":`แท็บใหม่`,Menu:`เมนู`,"Copy command":`คัดลอกคำสั่ง`,"Terminal input":`ช่องพิมพ์เทอร์มินัล`,Seek:`เลื่อนตำแหน่ง`,"Rewind 10 seconds":`ย้อน 10 วินาที`,"Forward 10 seconds":`ไปข้างหน้า 10 วินาที`,Volume:`ระดับเสียง`,"Toggle captions":`เปิดหรือปิดคำบรรยาย`,"Playback speed":`ความเร็วเล่น`,Quality:`คุณภาพ`,"Picture in picture":`ภาพซ้อนภาพ`,Play:`เล่น`,Pause:`หยุดชั่วคราว`,Mute:`ปิดเสียง`,Unmute:`เปิดเสียง`,"Exit fullscreen":`ออกจากเต็มหน้าจอ`,"Enter fullscreen":`เต็มหน้าจอ`,Expand:`ขยาย`,Collapse:`ยุบ`,"Copy reply":`คัดลอกคำตอบ`,"Good result":`ผลลัพธ์ดี`,"Bad result":`ผลลัพธ์ไม่ดี`,"Dialog Close":`ปิดกล่องโต้ตอบ`,Notifications:`การแจ้งเตือน`,Account:`บัญชี`,Cart:`ตะกร้า`,Call:`โทร`,"Video call":`วิดีโอคอล`,Message:`ข้อความ`,Main:`หลัก`,Columns:`คอลัมน์`,"No results.":`ไม่มีผลลัพธ์`,"No results":`ไม่มีผลลัพธ์`,"No results found":`ไม่พบผลลัพธ์`,"Drop files here":`วางไฟล์ที่นี่`,"Drag & drop files here":`ลากแล้ววางไฟล์ที่นี่`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`หรือคลิกเพื่อเลือก (สูงสุด {maxFiles} ไฟล์ ไฟล์ละ {maxSize} MB)`,"Remove {name}":`นำ {name} ออก`,"{selected} of {total} row(s) selected.":`เลือกแล้ว {selected} จาก {total} แถว`,"Try again":`ลองอีกครั้ง`,"What’s up next?":`ต่อไปคืออะไร`,"Show password":`แสดงรหัสผ่าน`,"Hide password":`ซ่อนรหัสผ่าน`,"Search icons":`ค้นหาไอคอน`,"No icon matches":`ไม่มีไอคอนที่ตรงกัน`,"Show all items ({n})":`แสดงทั้งหมด ({n})`,"Fewer {what}":`ลด {what}`,"More {what}":`เพิ่ม {what}`,"No tasks available. Add tasks to display Gantt chart.":`ยังไม่มีงาน เพิ่มงานเพื่อแสดงแผนภูมิ Gantt`,January:`มกราคม`,February:`กุมภาพันธ์`,March:`มีนาคม`,April:`เมษายน`,May:`พฤษภาคม`,June:`มิถุนายน`,July:`กรกฎาคม`,August:`สิงหาคม`,September:`กันยายน`,October:`ตุลาคม`,November:`พฤศจิกายน`,December:`ธันวาคม`,Su:`อา`,Mo:`จ`,Tu:`อ`,We:`พ`,Th:`พฤ`,Fr:`ศ`,Sa:`ส`,"just now":`เมื่อสักครู่`,"in a moment":`อีกครู่`,"in 1 minute":`ใน 1 นาที`,"in {n} minutes":`ใน {n} นาที`,"in 1 hour":`ใน 1 ชั่วโมง`,"in {n} hours":`ใน {n} ชั่วโมง`,tomorrow:`พรุ่งนี้`,"in {n} days":`ใน {n} วัน`,"in 1 week":`ใน 1 สัปดาห์`,"in {n} weeks":`ใน {n} สัปดาห์`,"in 1 month":`ใน 1 เดือน`,"in {n} months":`ใน {n} เดือน`,"in 1 year":`ใน 1 ปี`,"in {n} years":`ใน {n} ปี`,"1 minute ago":`1 นาทีที่แล้ว`,"{n} minutes ago":`{n} นาทีที่แล้ว`,"1 hour ago":`1 ชั่วโมงที่แล้ว`,"{n} hours ago":`{n} ชั่วโมงที่แล้ว`,"1 day ago":`1 วันที่แล้ว`,"{n} days ago":`{n} วันที่แล้ว`,"1 week ago":`1 สัปดาห์ที่แล้ว`,"{n} weeks ago":`{n} สัปดาห์ที่แล้ว`,"1 month ago":`1 เดือนที่แล้ว`,"{n} months ago":`{n} เดือนที่แล้ว`,"1 year ago":`1 ปีที่แล้ว`,"{n} years ago":`{n} ปีที่แล้ว`,"Cookie notice":`ประกาศคุกกี้`,"Cookie preferences":`การตั้งค่าคุกกี้`,"Close and use essential cookies only":`ปิดและใช้เฉพาะคุกกี้ที่จำเป็น`,Back:`กลับ`,"Log in":`เข้าสู่ระบบ`,"Search Hanzo or ask AI":`ค้นหาใน Hanzo หรือถาม AI`,"Search models":`ค้นหาโมเดล`,"Search branches…":`ค้นหาแบรนช์…`,"Search repositories…":`ค้นหาที่เก็บ…`,"Show options":`แสดงตัวเลือก`,Retry:`ลองใหม่`,"Donut chart":`แผนภูมิโดนัท`,"Find an organization":`ค้นหาองค์กร`,Organizations:`องค์กร`,"Organization name":`ชื่อองค์กร`,"Previous page":`หน้าก่อนหน้า`,"Next page":`หน้าถัดไป`,"Continue with credits":`ใช้เครดิตต่อไป`,"Try Hanzo":`ลองใช้ Hanzo`,"Terms & Policies":`ข้อกำหนดและนโยบาย`,"Who this is for":`เหมาะกับใคร`,"Bill yearly":`คิดเงินรายปี`,Apps:`แอป`,"Card actions":`การทำงานของการ์ด`,"Assign to...":`มอบหมายให้...`,"Search cards...":`ค้นหาการ์ด...`,"Clear search":`ล้างการค้นหา`,"Open files":`ไฟล์ที่เปิดอยู่`,"Close panel":`ปิดแผง`,"Add an organization":`เพิ่มองค์กร`,"Keyboard Shortcuts":`แป้นพิมพ์ลัด`,"Run a command":`เรียกใช้คำสั่ง`,"Type shell command...":`พิมพ์คำสั่งเชลล์...`,"Attached to the next message":`แนบกับข้อความถัดไป`,"Channel Member Roster":`สมาชิกช่อง`,"Channel Collaborative Notes":`บันทึกร่วมของช่อง`,"Code Diff Viewer":`ตัวดูส่วนต่างโค้ด`,"Live Voice Call":`สายเสียงสด`,"MCP Server Hub":`ฮับเซิร์ฟเวอร์ MCP`,"Multi-Agent Swarm Bar":`แถบฝูงเอเจนต์`,"Write shared channel notes, meeting agenda, or AI summaries...":`เขียนบันทึกช่อง วาระประชุม หรือสรุปจาก AI...`,"Help improve our AI models":`ช่วยปรับปรุงโมเดล AI ของเรา`,"Your name":`ชื่อของคุณ`,"Your role":`บทบาทของคุณ`,"Country or region":`ประเทศหรือภูมิภาค`,"Card details":`รายละเอียดบัตร`,"Agree to recurring charges":`ยอมรับการเรียกเก็บซ้ำ`,"How you will use Hanzo":`คุณจะใช้ Hanzo อย่างไร`,"Team size":`ขนาดทีม`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`ฉันยอมรับข้อกำหนดการให้บริการและนโยบายการใช้งานที่ยอมรับได้ และยืนยันว่าฉันมีอายุอย่างน้อย 18 ปี`,"Empty string":`สตริงว่าง`,"Empty array":`อาร์เรย์ว่าง`,"Empty object":`อ็อบเจกต์ว่าง`,"Copy {what}":`คัดลอก {what}`,"Ask anything":`ถามอะไรก็ได้`,Auto:`อัตโนมัติ`,Instant:`ทันที`,Low:`ต่ำ`,Medium:`ปานกลาง`,High:`สูง`,Max:`สูงสุด`,Dictate:`สั่งด้วยเสียง`,"Dictating — click to stop":`กำลังสั่งด้วยเสียง — คลิกเพื่อหยุด`,"Dictation settings":`การตั้งค่าการสั่งด้วยเสียง`,Language:`ภาษา`,"No devices found":`ไม่พบอุปกรณ์`,"Microphone {n}":`ไมโครโฟน {n}`,"Nothing matches":`ไม่มีรายการที่ตรงกัน`,Commands:`คำสั่ง`,"Search commands…":`ค้นหาคำสั่ง…`,Agents:`เอเจนต์`,Skills:`ทักษะ`,Connectors:`ตัวเชื่อม`,"Design system":`ระบบดีไซน์`,Plugins:`ปลั๊กอิน`,Devices:`อุปกรณ์`,Memory:`ความจำ`,Research:`ค้นคว้า`,On:`เปิด`,"Upload or add files":`อัปโหลดหรือเพิ่มไฟล์`,"Add files, agents, skills and more":`เพิ่มไฟล์ เอเจนต์ ทักษะ และอื่นๆ`,"No agents yet":`ยังไม่มีเอเจนต์`,"No skills yet":`ยังไม่มีทักษะ`,"No connectors yet":`ยังไม่มีตัวเชื่อม`,"No design system yet":`ยังไม่มีระบบดีไซน์`,"No plugins yet":`ยังไม่มีปลั๊กอิน`,"No devices yet":`ยังไม่มีอุปกรณ์`,"Search agents":`ค้นหาเอเจนต์`,"Search skills":`ค้นหาทักษะ`,"Search connectors":`ค้นหาตัวเชื่อม`,"Search design system":`ค้นหาระบบดีไซน์`,"Search plugins":`ค้นหาปลั๊กอิน`,"Search devices":`ค้นหาอุปกรณ์`,"Reading agents":`กำลังอ่านเอเจนต์`,"Reading skills":`กำลังอ่านทักษะ`,"Reading connectors":`กำลังอ่านตัวเชื่อม`,"Reading design system":`กำลังอ่านระบบดีไซน์`,"Reading plugins":`กำลังอ่านปลั๊กอิน`,"Adaptive reasoning based on task complexity":`การใช้เหตุผลตามความซับซ้อนของงาน`,"Answers right away, without thinking":`ตอบทันทีโดยไม่ต้องคิด`,"A quick pass with minimal thinking":`ผ่านอย่างรวดเร็วโดยคิดน้อย`,"Thinks before answering":`คิดก่อนตอบ`,"Deep reasoning for complex problems":`การใช้เหตุผลเชิงลึกสำหรับปัญหาซับซ้อน`,"Maximum compute and exhaustive verification":`การคำนวณสูงสุดและการตรวจอย่างละเอียด`,Effort:`ระดับความพยายาม`,"Effort: {level}":`ระดับความพยายาม: {level}`,Mode:`โหมด`,"Mode: {mode}":`โหมด: {mode}`,Model:`โมเดล`,"Model: {name}":`โมเดล: {name}`,"Voice mode":`โหมดเสียง`,"Hanzo is speaking — talk to interrupt":`Hanzo กำลังพูด — พูดเพื่อขัดจังหวะ`,"In conversation — click to hang up":`กำลังสนทนา — คลิกเพื่อวางสาย`,"Go to testimonial {n}":`ไปยังคำรับรอง {n}`,"Go to card {n}":`ไปยังการ์ด {n}`,"{n} of {total}":`{n} จาก {total}`,"Reading…":`กำลังอ่าน…`,Skill:`ทักษะ`,Plugin:`ปลั๊กอิน`},Hne={Close:`Kapat`,"Close window":`Pencereyi kapat`,"Minimize window":`Pencereyi küçült`,"Restore window":`Pencereyi geri yükle`,"Maximize window":`Pencereyi büyüt`,Resize:`Yeniden boyutlandır`,"Select all":`Tümünü seç`,"Select row":`Satırı seç`,"Previous month":`Önceki ay`,"Next month":`Sonraki ay`,Dismiss:`Kapat`,Breadcrumb:`Gezinti yolu`,Cards:`Kartlar`,"Copy code":`Kodu kopyala`,Copied:`Kopyalandı`,"Copied!":`Kopyalandı!`,Copy:`Kopyala`,"Previous slide":`Önceki slayt`,"Next slide":`Sonraki slayt`,"Previous card":`Önceki kart`,"Next card":`Sonraki kart`,"Zoom out":`Uzaklaştır`,"Zoom in":`Yakınlaştır`,Rotate:`Döndür`,Filter:`Filtrele`,"Expand all":`Tümünü genişlet`,"Collapse all":`Tümünü daralt`,"Search...":`Ara...`,"Pick a date":`Tarih seçin`,Select:`Seç`,"Start typing...":`Yazmaya başlayın...`,Search:`Ara`,Decrease:`Azalt`,Increase:`Artır`,pagination:`sayfalama`,"Go to previous page":`Önceki sayfaya git`,"Go to next page":`Sonraki sayfaya git`,Previous:`Önceki`,Next:`Sonraki`,"More pages":`Diğer sayfalar`,Remove:`Kaldır`,"Go back":`Geri`,"Go forward":`İleri`,"Reload page":`Sayfayı yenile`,Share:`Paylaş`,"New tab":`Yeni sekme`,Menu:`Menü`,"Copy command":`Komutu kopyala`,"Terminal input":`Terminal girişi`,Seek:`Konum`,"Rewind 10 seconds":`10 saniye geri`,"Forward 10 seconds":`10 saniye ileri`,Volume:`Ses`,"Toggle captions":`Altyazıları aç veya kapat`,"Playback speed":`Oynatma hızı`,Quality:`Kalite`,"Picture in picture":`Resim içinde resim`,Play:`Oynat`,Pause:`Duraklat`,Mute:`Sessize al`,Unmute:`Sesi aç`,"Exit fullscreen":`Tam ekrandan çık`,"Enter fullscreen":`Tam ekran`,Expand:`Genişlet`,Collapse:`Daralt`,"Copy reply":`Yanıtı kopyala`,"Good result":`İyi sonuç`,"Bad result":`Kötü sonuç`,"Dialog Close":`İletişim kutusunu kapat`,Notifications:`Bildirimler`,Account:`Hesap`,Cart:`Sepet`,Call:`Arama`,"Video call":`Görüntülü arama`,Message:`Mesaj`,Main:`Ana`,Columns:`Sütunlar`,"No results.":`Sonuç yok.`,"No results":`Sonuç yok`,"No results found":`Sonuç bulunamadı`,"Drop files here":`Dosyaları buraya bırakın`,"Drag & drop files here":`Dosyaları sürükleyip bırakın`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`veya göz atmak için tıklayın (en fazla {maxFiles} dosya, her biri {maxSize} MB)`,"Remove {name}":`{name} öğesini kaldır`,"{selected} of {total} row(s) selected.":`{total} satırdan {selected} tanesi seçili.`,"Try again":`Yeniden dene`,"What’s up next?":`Sırada ne var?`,"Show password":`Şifreyi göster`,"Hide password":`Şifreyi gizle`,"Search icons":`Simge ara`,"No icon matches":`Eşleşen simge yok`,"Show all items ({n})":`Tümünü göster ({n})`,"Fewer {what}":`Daha az {what}`,"More {what}":`Daha fazla {what}`,"No tasks available. Add tasks to display Gantt chart.":`Görev yok. Gantt grafiğini görmek için görev ekleyin.`,January:`Ocak`,February:`Şubat`,March:`Mart`,April:`Nisan`,May:`Mayıs`,June:`Haziran`,July:`Temmuz`,August:`Ağustos`,September:`Eylül`,October:`Ekim`,November:`Kasım`,December:`Aralık`,Su:`Pz`,Mo:`Pt`,Tu:`Sa`,We:`Ça`,Th:`Pe`,Fr:`Cu`,Sa:`Ct`,"just now":`şimdi`,"in a moment":`birazdan`,"in 1 minute":`1 dakika içinde`,"in {n} minutes":`{n} dakika içinde`,"in 1 hour":`1 saat içinde`,"in {n} hours":`{n} saat içinde`,tomorrow:`yarın`,"in {n} days":`{n} gün içinde`,"in 1 week":`1 hafta içinde`,"in {n} weeks":`{n} hafta içinde`,"in 1 month":`1 ay içinde`,"in {n} months":`{n} ay içinde`,"in 1 year":`1 yıl içinde`,"in {n} years":`{n} yıl içinde`,"1 minute ago":`1 dakika önce`,"{n} minutes ago":`{n} dakika önce`,"1 hour ago":`1 saat önce`,"{n} hours ago":`{n} saat önce`,"1 day ago":`1 gün önce`,"{n} days ago":`{n} gün önce`,"1 week ago":`1 hafta önce`,"{n} weeks ago":`{n} hafta önce`,"1 month ago":`1 ay önce`,"{n} months ago":`{n} ay önce`,"1 year ago":`1 yıl önce`,"{n} years ago":`{n} yıl önce`,"Cookie notice":`Çerez bildirimi`,"Cookie preferences":`Çerez tercihleri`,"Close and use essential cookies only":`Kapat ve yalnızca zorunlu çerezleri kullan`,Back:`Geri`,"Log in":`Giriş yap`,"Search Hanzo or ask AI":`Hanzo’da ara veya yapay zekâya sor`,"Search models":`Model ara`,"Search branches…":`Dalları ara…`,"Search repositories…":`Depoları ara…`,"Show options":`Seçenekleri göster`,Retry:`Yeniden dene`,"Donut chart":`Halka grafik`,"Find an organization":`Kuruluş bul`,Organizations:`Kuruluşlar`,"Organization name":`Kuruluş adı`,"Previous page":`Önceki sayfa`,"Next page":`Sonraki sayfa`,"Continue with credits":`Kredilerle devam et`,"Try Hanzo":`Hanzo’yu dene`,"Terms & Policies":`Koşullar ve politikalar`,"Who this is for":`Kimler için`,"Bill yearly":`Yıllık faturalandır`,Apps:`Uygulamalar`,"Card actions":`Kart işlemleri`,"Assign to...":`Ata...`,"Search cards...":`Kart ara...`,"Clear search":`Aramayı temizle`,"Open files":`Açık dosyalar`,"Close panel":`Paneli kapat`,"Add an organization":`Kuruluş ekle`,"Keyboard Shortcuts":`Klavye kısayolları`,"Run a command":`Komut çalıştır`,"Type shell command...":`Kabuk komutu yazın...`,"Attached to the next message":`Sonraki iletiye eklendi`,"Channel Member Roster":`Kanal üyeleri`,"Channel Collaborative Notes":`Kanalın ortak notları`,"Code Diff Viewer":`Fark görüntüleyici`,"Live Voice Call":`Canlı sesli arama`,"MCP Server Hub":`MCP sunucu merkezi`,"Multi-Agent Swarm Bar":`Çoklu aracı çubuğu`,"Write shared channel notes, meeting agenda, or AI summaries...":`Paylaşılan kanal notları, gündem veya yapay zekâ özetleri yazın...`,"Help improve our AI models":`Yapay zekâ modellerimizi geliştirmeye yardım edin`,"Your name":`Adınız`,"Your role":`Rolünüz`,"Country or region":`Ülke veya bölge`,"Card details":`Kart bilgileri`,"Agree to recurring charges":`Yinelenen ücretleri kabul et`,"How you will use Hanzo":`Hanzo’yu nasıl kullanacağınız`,"Team size":`Ekip büyüklüğü`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Hizmet Şartlarını ve Kabul Edilebilir Kullanım Politikasını kabul ediyor ve en az 18 yaşında olduğumu onaylıyorum.`,"Empty string":`Boş dize`,"Empty array":`Boş dizi`,"Empty object":`Boş nesne`,"Copy {what}":`{what} kopyala`,"Ask anything":`Her şeyi sorun`,Auto:`Otomatik`,Instant:`Anında`,Low:`Düşük`,Medium:`Orta`,High:`Yüksek`,Max:`Maksimum`,Dictate:`Dikte`,"Dictating — click to stop":`Dikte ediliyor — durdurmak için tıklayın`,"Dictation settings":`Dikte ayarları`,Language:`Dil`,"No devices found":`Aygıt bulunamadı`,"Microphone {n}":`Mikrofon {n}`,"Nothing matches":`Eşleşme yok`,Commands:`Komutlar`,"Search commands…":`Komut ara…`,Agents:`Aracılar`,Skills:`Beceriler`,Connectors:`Bağlayıcılar`,"Design system":`Tasarım sistemi`,Plugins:`Eklentiler`,Devices:`Aygıtlar`,Memory:`Bellek`,Research:`Araştırma`,On:`Açık`,"Upload or add files":`Dosya yükle veya ekle`,"Add files, agents, skills and more":`Dosya, aracı, beceri ve daha fazlasını ekle`,"No agents yet":`Henüz aracı yok`,"No skills yet":`Henüz beceri yok`,"No connectors yet":`Henüz bağlayıcı yok`,"No design system yet":`Henüz tasarım sistemi yok`,"No plugins yet":`Henüz eklenti yok`,"No devices yet":`Henüz aygıt yok`,"Search agents":`Aracı ara`,"Search skills":`Beceri ara`,"Search connectors":`Bağlayıcı ara`,"Search design system":`Tasarım sisteminde ara`,"Search plugins":`Eklenti ara`,"Search devices":`Aygıt ara`,"Reading agents":`Aracılar okunuyor`,"Reading skills":`Beceriler okunuyor`,"Reading connectors":`Bağlayıcılar okunuyor`,"Reading design system":`Tasarım sistemi okunuyor`,"Reading plugins":`Eklentiler okunuyor`,"Adaptive reasoning based on task complexity":`Görevin karmaşıklığına göre uyarlanabilir akıl yürütme`,"Answers right away, without thinking":`Düşünmeden hemen yanıt verir`,"A quick pass with minimal thinking":`Az düşünerek hızlı bir geçiş`,"Thinks before answering":`Yanıtlamadan önce düşünür`,"Deep reasoning for complex problems":`Karmaşık sorunlar için derin akıl yürütme`,"Maximum compute and exhaustive verification":`En yüksek hesap ve kapsamlı doğrulama`,Effort:`Çaba`,"Effort: {level}":`Çaba: {level}`,Mode:`Mod`,"Mode: {mode}":`Mod: {mode}`,Model:`Model`,"Model: {name}":`Model: {name}`,"Voice mode":`Ses modu`,"Hanzo is speaking — talk to interrupt":`Hanzo konuşuyor — kesmek için konuşun`,"In conversation — click to hang up":`Görüşmede — kapatmak için tıklayın`,"Go to testimonial {n}":`{n}. görüşe git`,"Go to card {n}":`{n}. karta git`,"{n} of {total}":`{n} / {total}`,"Reading…":`Okunuyor…`,Skill:`Beceri`,Plugin:`Eklenti`},Une={Close:`Đóng`,"Close window":`Đóng cửa sổ`,"Minimize window":`Thu nhỏ cửa sổ`,"Restore window":`Khôi phục cửa sổ`,"Maximize window":`Phóng to cửa sổ`,Resize:`Đổi kích thước`,"Select all":`Chọn tất cả`,"Select row":`Chọn hàng`,"Previous month":`Tháng trước`,"Next month":`Tháng sau`,Dismiss:`Bỏ qua`,Breadcrumb:`Đường dẫn`,Cards:`Thẻ`,"Copy code":`Sao chép mã`,Copied:`Đã sao chép`,"Copied!":`Đã sao chép!`,Copy:`Sao chép`,"Previous slide":`Trang trước`,"Next slide":`Trang sau`,"Previous card":`Thẻ trước`,"Next card":`Thẻ sau`,"Zoom out":`Thu nhỏ`,"Zoom in":`Phóng to`,Rotate:`Xoay`,Filter:`Lọc`,"Expand all":`Mở rộng tất cả`,"Collapse all":`Thu gọn tất cả`,"Search...":`Tìm kiếm...`,"Pick a date":`Chọn ngày`,Select:`Chọn`,"Start typing...":`Bắt đầu nhập...`,Search:`Tìm kiếm`,Decrease:`Giảm`,Increase:`Tăng`,pagination:`phân trang`,"Go to previous page":`Đến trang trước`,"Go to next page":`Đến trang sau`,Previous:`Trước`,Next:`Tiếp`,"More pages":`Thêm trang`,Remove:`Xóa`,"Go back":`Quay lại`,"Go forward":`Tiến`,"Reload page":`Tải lại trang`,Share:`Chia sẻ`,"New tab":`Tab mới`,Menu:`Menu`,"Copy command":`Sao chép lệnh`,"Terminal input":`Nhập lệnh`,Seek:`Tua`,"Rewind 10 seconds":`Tua lại 10 giây`,"Forward 10 seconds":`Tua đi 10 giây`,Volume:`Âm lượng`,"Toggle captions":`Bật hoặc tắt phụ đề`,"Playback speed":`Tốc độ phát`,Quality:`Chất lượng`,"Picture in picture":`Hình trong hình`,Play:`Phát`,Pause:`Tạm dừng`,Mute:`Tắt tiếng`,Unmute:`Bật tiếng`,"Exit fullscreen":`Thoát toàn màn hình`,"Enter fullscreen":`Toàn màn hình`,Expand:`Mở rộng`,Collapse:`Thu gọn`,"Copy reply":`Sao chép câu trả lời`,"Good result":`Kết quả tốt`,"Bad result":`Kết quả kém`,"Dialog Close":`Đóng hộp thoại`,Notifications:`Thông báo`,Account:`Tài khoản`,Cart:`Giỏ hàng`,Call:`Cuộc gọi`,"Video call":`Cuộc gọi video`,Message:`Tin nhắn`,Main:`Chính`,Columns:`Cột`,"No results.":`Không có kết quả.`,"No results":`Không có kết quả`,"No results found":`Không tìm thấy kết quả`,"Drop files here":`Thả tệp vào đây`,"Drag & drop files here":`Kéo và thả tệp vào đây`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`hoặc bấm để duyệt (tối đa {maxFiles} tệp, mỗi tệp {maxSize} MB)`,"Remove {name}":`Xóa {name}`,"{selected} of {total} row(s) selected.":`Đã chọn {selected} / {total} hàng.`,"Try again":`Thử lại`,"What’s up next?":`Tiếp theo là gì?`,"Show password":`Hiện mật khẩu`,"Hide password":`Ẩn mật khẩu`,"Search icons":`Tìm biểu tượng`,"No icon matches":`Không có biểu tượng khớp`,"Show all items ({n})":`Hiện tất cả ({n})`,"Fewer {what}":`Ít {what} hơn`,"More {what}":`Thêm {what}`,"No tasks available. Add tasks to display Gantt chart.":`Chưa có công việc. Thêm công việc để hiện biểu đồ Gantt.`,January:`tháng 1`,February:`tháng 2`,March:`tháng 3`,April:`tháng 4`,May:`tháng 5`,June:`tháng 6`,July:`tháng 7`,August:`tháng 8`,September:`tháng 9`,October:`tháng 10`,November:`tháng 11`,December:`tháng 12`,Su:`CN`,Mo:`T2`,Tu:`T3`,We:`T4`,Th:`T5`,Fr:`T6`,Sa:`T7`,"just now":`vừa xong`,"in a moment":`chốc nữa`,"in 1 minute":`sau 1 phút`,"in {n} minutes":`sau {n} phút`,"in 1 hour":`sau 1 giờ`,"in {n} hours":`sau {n} giờ`,tomorrow:`ngày mai`,"in {n} days":`sau {n} ngày`,"in 1 week":`sau 1 tuần`,"in {n} weeks":`sau {n} tuần`,"in 1 month":`sau 1 tháng`,"in {n} months":`sau {n} tháng`,"in 1 year":`sau 1 năm`,"in {n} years":`sau {n} năm`,"1 minute ago":`1 phút trước`,"{n} minutes ago":`{n} phút trước`,"1 hour ago":`1 giờ trước`,"{n} hours ago":`{n} giờ trước`,"1 day ago":`1 ngày trước`,"{n} days ago":`{n} ngày trước`,"1 week ago":`1 tuần trước`,"{n} weeks ago":`{n} tuần trước`,"1 month ago":`1 tháng trước`,"{n} months ago":`{n} tháng trước`,"1 year ago":`1 năm trước`,"{n} years ago":`{n} năm trước`,"Cookie notice":`Thông báo cookie`,"Cookie preferences":`Tùy chọn cookie`,"Close and use essential cookies only":`Đóng và chỉ dùng cookie thiết yếu`,Back:`Quay lại`,"Log in":`Đăng nhập`,"Search Hanzo or ask AI":`Tìm trong Hanzo hoặc hỏi AI`,"Search models":`Tìm mô hình`,"Search branches…":`Tìm nhánh…`,"Search repositories…":`Tìm kho…`,"Show options":`Hiện tùy chọn`,Retry:`Thử lại`,"Donut chart":`Biểu đồ vành khuyên`,"Find an organization":`Tìm tổ chức`,Organizations:`Tổ chức`,"Organization name":`Tên tổ chức`,"Previous page":`Trang trước`,"Next page":`Trang sau`,"Continue with credits":`Tiếp tục bằng tín dụng`,"Try Hanzo":`Dùng thử Hanzo`,"Terms & Policies":`Điều khoản và chính sách`,"Who this is for":`Dành cho ai`,"Bill yearly":`Thanh toán theo năm`,Apps:`Ứng dụng`,"Card actions":`Thao tác thẻ`,"Assign to...":`Gán cho...`,"Search cards...":`Tìm thẻ...`,"Clear search":`Xóa tìm kiếm`,"Open files":`Tệp đang mở`,"Close panel":`Đóng bảng`,"Add an organization":`Thêm tổ chức`,"Keyboard Shortcuts":`Phím tắt`,"Run a command":`Chạy lệnh`,"Type shell command...":`Nhập lệnh shell...`,"Attached to the next message":`Đính kèm tin nhắn tiếp theo`,"Channel Member Roster":`Thành viên kênh`,"Channel Collaborative Notes":`Ghi chú cộng tác của kênh`,"Code Diff Viewer":`Trình xem khác biệt mã`,"Live Voice Call":`Cuộc gọi thoại trực tiếp`,"MCP Server Hub":`Trung tâm máy chủ MCP`,"Multi-Agent Swarm Bar":`Thanh bầy tác nhân`,"Write shared channel notes, meeting agenda, or AI summaries...":`Viết ghi chú kênh, chương trình họp hoặc tóm tắt AI...`,"Help improve our AI models":`Giúp cải thiện mô hình AI của chúng tôi`,"Your name":`Tên của bạn`,"Your role":`Vai trò của bạn`,"Country or region":`Quốc gia hoặc khu vực`,"Card details":`Thông tin thẻ`,"Agree to recurring charges":`Đồng ý các khoản phí định kỳ`,"How you will use Hanzo":`Bạn sẽ dùng Hanzo thế nào`,"Team size":`Quy mô nhóm`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`Tôi đồng ý với Điều khoản dịch vụ và Chính sách sử dụng được chấp nhận và xác nhận tôi đủ 18 tuổi.`,"Empty string":`Chuỗi rỗng`,"Empty array":`Mảng rỗng`,"Empty object":`Đối tượng rỗng`,"Copy {what}":`Sao chép {what}`,"Ask anything":`Hỏi bất cứ điều gì`,Auto:`Tự động`,Instant:`Tức thì`,Low:`Thấp`,Medium:`Trung bình`,High:`Cao`,Max:`Tối đa`,Dictate:`Đọc chính tả`,"Dictating — click to stop":`Đang đọc — bấm để dừng`,"Dictation settings":`Cài đặt đọc chính tả`,Language:`Ngôn ngữ`,"No devices found":`Không tìm thấy thiết bị`,"Microphone {n}":`Micro {n}`,"Nothing matches":`Không có gì khớp`,Commands:`Lệnh`,"Search commands…":`Tìm lệnh…`,Agents:`Tác nhân`,Skills:`Kỹ năng`,Connectors:`Trình kết nối`,"Design system":`Hệ thống thiết kế`,Plugins:`Plugin`,Devices:`Thiết bị`,Memory:`Bộ nhớ`,Research:`Nghiên cứu`,On:`Bật`,"Upload or add files":`Tải lên hoặc thêm tệp`,"Add files, agents, skills and more":`Thêm tệp, tác nhân, kỹ năng và hơn thế`,"No agents yet":`Chưa có tác nhân`,"No skills yet":`Chưa có kỹ năng`,"No connectors yet":`Chưa có trình kết nối`,"No design system yet":`Chưa có hệ thống thiết kế`,"No plugins yet":`Chưa có plugin`,"No devices yet":`Chưa có thiết bị`,"Search agents":`Tìm tác nhân`,"Search skills":`Tìm kỹ năng`,"Search connectors":`Tìm trình kết nối`,"Search design system":`Tìm trong hệ thống thiết kế`,"Search plugins":`Tìm plugin`,"Search devices":`Tìm thiết bị`,"Reading agents":`Đang đọc tác nhân`,"Reading skills":`Đang đọc kỹ năng`,"Reading connectors":`Đang đọc trình kết nối`,"Reading design system":`Đang đọc hệ thống thiết kế`,"Reading plugins":`Đang đọc plugin`,"Adaptive reasoning based on task complexity":`Suy luận thích ứng theo độ phức tạp`,"Answers right away, without thinking":`Trả lời ngay, không suy nghĩ`,"A quick pass with minimal thinking":`Một lượt nhanh, ít suy nghĩ`,"Thinks before answering":`Suy nghĩ trước khi trả lời`,"Deep reasoning for complex problems":`Suy luận sâu cho vấn đề phức tạp`,"Maximum compute and exhaustive verification":`Tính toán tối đa và kiểm tra toàn diện`,Effort:`Mức nỗ lực`,"Effort: {level}":`Mức nỗ lực: {level}`,Mode:`Chế độ`,"Mode: {mode}":`Chế độ: {mode}`,Model:`Mô hình`,"Model: {name}":`Mô hình: {name}`,"Voice mode":`Chế độ giọng nói`,"Hanzo is speaking — talk to interrupt":`Hanzo đang nói — hãy nói để ngắt`,"In conversation — click to hang up":`Đang trò chuyện — bấm để gác máy`,"Go to testimonial {n}":`Đến lời nhận xét {n}`,"Go to card {n}":`Đến thẻ {n}`,"{n} of {total}":`{n} / {total}`,"Reading…":`Đang đọc…`,Skill:`Kỹ năng`,Plugin:`Plugin`},Wne={Close:`关闭`,"Close window":`关闭窗口`,"Minimize window":`最小化窗口`,"Restore window":`还原窗口`,"Maximize window":`最大化窗口`,Resize:`调整大小`,"Select all":`全选`,"Select row":`选择行`,"Previous month":`上个月`,"Next month":`下个月`,Dismiss:`关闭`,Breadcrumb:`面包屑`,Cards:`卡片`,"Copy code":`复制代码`,Copied:`已复制`,"Copied!":`已复制!`,Copy:`复制`,"Previous slide":`上一张`,"Next slide":`下一张`,"Previous card":`上一张卡片`,"Next card":`下一张卡片`,"Zoom out":`缩小`,"Zoom in":`放大`,Rotate:`旋转`,Filter:`筛选`,"Expand all":`全部展开`,"Collapse all":`全部折叠`,"Search...":`搜索...`,"Pick a date":`选择日期`,Select:`选择`,"Start typing...":`开始输入...`,Search:`搜索`,Decrease:`减少`,Increase:`增加`,pagination:`分页`,"Go to previous page":`转到上一页`,"Go to next page":`转到下一页`,Previous:`上一页`,Next:`下一页`,"More pages":`更多页面`,Remove:`移除`,"Go back":`返回`,"Go forward":`前进`,"Reload page":`重新加载页面`,Share:`分享`,"New tab":`新标签页`,Menu:`菜单`,"Copy command":`复制命令`,"Terminal input":`终端输入`,Seek:`拖动进度`,"Rewind 10 seconds":`后退 10 秒`,"Forward 10 seconds":`快进 10 秒`,Volume:`音量`,"Toggle captions":`开关字幕`,"Playback speed":`播放速度`,Quality:`画质`,"Picture in picture":`画中画`,Play:`播放`,Pause:`暂停`,Mute:`静音`,Unmute:`取消静音`,"Exit fullscreen":`退出全屏`,"Enter fullscreen":`全屏`,Expand:`展开`,Collapse:`折叠`,"Copy reply":`复制回复`,"Good result":`结果好`,"Bad result":`结果不好`,"Dialog Close":`关闭对话框`,Notifications:`通知`,Account:`账户`,Cart:`购物车`,Call:`通话`,"Video call":`视频通话`,Message:`消息`,Main:`主导航`,Columns:`列`,"No results.":`没有结果。`,"No results":`无结果`,"No results found":`未找到结果`,"Drop files here":`将文件拖放到此处`,"Drag & drop files here":`拖放文件到此处`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`或点击浏览(最多 {maxFiles} 个文件,每个 {maxSize} MB)`,"Remove {name}":`移除 {name}`,"{selected} of {total} row(s) selected.":`已选择 {selected}/{total} 行。`,"Try again":`重试`,"What’s up next?":`接下来做什么?`,"Show password":`显示密码`,"Hide password":`隐藏密码`,"Search icons":`搜索图标`,"No icon matches":`没有匹配的图标`,"Show all items ({n})":`显示全部 ({n})`,"Fewer {what}":`减少{what}`,"More {what}":`增加{what}`,"No tasks available. Add tasks to display Gantt chart.":`没有任务。添加任务以显示甘特图。`,January:`一月`,February:`二月`,March:`三月`,April:`四月`,May:`五月`,June:`六月`,July:`七月`,August:`八月`,September:`九月`,October:`十月`,November:`十一月`,December:`十二月`,Su:`日`,Mo:`一`,Tu:`二`,We:`三`,Th:`四`,Fr:`五`,Sa:`六`,"just now":`刚刚`,"in a moment":`片刻后`,"in 1 minute":`1 分钟后`,"in {n} minutes":`{n} 分钟后`,"in 1 hour":`1 小时后`,"in {n} hours":`{n} 小时后`,tomorrow:`明天`,"in {n} days":`{n} 天后`,"in 1 week":`1 周后`,"in {n} weeks":`{n} 周后`,"in 1 month":`1 个月后`,"in {n} months":`{n} 个月后`,"in 1 year":`1 年后`,"in {n} years":`{n} 年后`,"1 minute ago":`1 分钟前`,"{n} minutes ago":`{n} 分钟前`,"1 hour ago":`1 小时前`,"{n} hours ago":`{n} 小时前`,"1 day ago":`1 天前`,"{n} days ago":`{n} 天前`,"1 week ago":`1 周前`,"{n} weeks ago":`{n} 周前`,"1 month ago":`1 个月前`,"{n} months ago":`{n} 个月前`,"1 year ago":`1 年前`,"{n} years ago":`{n} 年前`,"Cookie notice":`Cookie 提示`,"Cookie preferences":`Cookie 偏好`,"Close and use essential cookies only":`关闭并仅使用必要 Cookie`,Back:`返回`,"Log in":`登录`,"Search Hanzo or ask AI":`搜索 Hanzo 或询问 AI`,"Search models":`搜索模型`,"Search branches…":`搜索分支…`,"Search repositories…":`搜索仓库…`,"Show options":`显示选项`,Retry:`重试`,"Donut chart":`环形图`,"Find an organization":`查找组织`,Organizations:`组织`,"Organization name":`组织名称`,"Previous page":`上一页`,"Next page":`下一页`,"Continue with credits":`使用额度继续`,"Try Hanzo":`试用 Hanzo`,"Terms & Policies":`条款与政策`,"Who this is for":`适合谁`,"Bill yearly":`按年计费`,Apps:`应用`,"Card actions":`卡片操作`,"Assign to...":`分配给...`,"Search cards...":`搜索卡片...`,"Clear search":`清除搜索`,"Open files":`打开的文件`,"Close panel":`关闭面板`,"Add an organization":`添加组织`,"Keyboard Shortcuts":`键盘快捷键`,"Run a command":`运行命令`,"Type shell command...":`输入 shell 命令...`,"Attached to the next message":`附加到下一条消息`,"Channel Member Roster":`频道成员`,"Channel Collaborative Notes":`频道协作笔记`,"Code Diff Viewer":`代码差异查看器`,"Live Voice Call":`实时语音通话`,"MCP Server Hub":`MCP 服务器中心`,"Multi-Agent Swarm Bar":`多智能体群集栏`,"Write shared channel notes, meeting agenda, or AI summaries...":`撰写频道笔记、会议议程或 AI 摘要...`,"Help improve our AI models":`帮助改进我们的 AI 模型`,"Your name":`你的名字`,"Your role":`你的角色`,"Country or region":`国家或地区`,"Card details":`银行卡信息`,"Agree to recurring charges":`同意周期性扣款`,"How you will use Hanzo":`你将如何使用 Hanzo`,"Team size":`团队规模`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`我同意服务条款和可接受使用政策,并确认我已年满 18 岁。`,"Empty string":`空字符串`,"Empty array":`空数组`,"Empty object":`空对象`,"Copy {what}":`复制{what}`,"Ask anything":`尽管问`,Auto:`自动`,Instant:`即时`,Low:`低`,Medium:`中`,High:`高`,Max:`最大`,Dictate:`听写`,"Dictating — click to stop":`正在听写 — 点击停止`,"Dictation settings":`听写设置`,Language:`语言`,"No devices found":`未找到设备`,"Microphone {n}":`麦克风 {n}`,"Nothing matches":`没有匹配项`,Commands:`命令`,"Search commands…":`搜索命令…`,Agents:`智能体`,Skills:`技能`,Connectors:`连接器`,"Design system":`设计系统`,Plugins:`插件`,Devices:`设备`,Memory:`记忆`,Research:`研究`,On:`开`,"Upload or add files":`上传或添加文件`,"Add files, agents, skills and more":`添加文件、智能体、技能等`,"No agents yet":`还没有智能体`,"No skills yet":`还没有技能`,"No connectors yet":`还没有连接器`,"No design system yet":`还没有设计系统`,"No plugins yet":`还没有插件`,"No devices yet":`还没有设备`,"Search agents":`搜索智能体`,"Search skills":`搜索技能`,"Search connectors":`搜索连接器`,"Search design system":`搜索设计系统`,"Search plugins":`搜索插件`,"Search devices":`搜索设备`,"Reading agents":`正在读取智能体`,"Reading skills":`正在读取技能`,"Reading connectors":`正在读取连接器`,"Reading design system":`正在读取设计系统`,"Reading plugins":`正在读取插件`,"Adaptive reasoning based on task complexity":`根据任务复杂度自适应推理`,"Answers right away, without thinking":`立即回答,不进行思考`,"A quick pass with minimal thinking":`快速过一遍,少思考`,"Thinks before answering":`先想再答`,"Deep reasoning for complex problems":`针对复杂问题的深度推理`,"Maximum compute and exhaustive verification":`最大算力与穷尽验证`,Effort:`力度`,"Effort: {level}":`力度:{level}`,Mode:`模式`,"Mode: {mode}":`模式:{mode}`,Model:`模型`,"Model: {name}":`模型:{name}`,"Voice mode":`语音模式`,"Hanzo is speaking — talk to interrupt":`Hanzo 正在说话 — 开口即可打断`,"In conversation — click to hang up":`通话中 — 点击挂断`,"Go to testimonial {n}":`转到评价 {n}`,"Go to card {n}":`转到卡片 {n}`,"{n} of {total}":`{n} / {total}`,"Reading…":`正在读取…`,Skill:`技能`,Plugin:`插件`},Gne={Close:`關閉`,"Close window":`關閉視窗`,"Minimize window":`最小化視窗`,"Restore window":`還原視窗`,"Maximize window":`最大化視窗`,Resize:`調整大小`,"Select all":`全選`,"Select row":`選擇列`,"Previous month":`上個月`,"Next month":`下個月`,Dismiss:`關閉`,Breadcrumb:`導覽路徑`,Cards:`卡片`,"Copy code":`複製程式碼`,Copied:`已複製`,"Copied!":`已複製!`,Copy:`複製`,"Previous slide":`上一張`,"Next slide":`下一張`,"Previous card":`上一張卡片`,"Next card":`下一張卡片`,"Zoom out":`縮小`,"Zoom in":`放大`,Rotate:`旋轉`,Filter:`篩選`,"Expand all":`全部展開`,"Collapse all":`全部摺疊`,"Search...":`搜尋...`,"Pick a date":`選擇日期`,Select:`選擇`,"Start typing...":`開始輸入...`,Search:`搜尋`,Decrease:`減少`,Increase:`增加`,pagination:`分頁`,"Go to previous page":`前往上一頁`,"Go to next page":`前往下一頁`,Previous:`上一頁`,Next:`下一頁`,"More pages":`更多頁面`,Remove:`移除`,"Go back":`返回`,"Go forward":`前進`,"Reload page":`重新載入頁面`,Share:`分享`,"New tab":`新分頁`,Menu:`選單`,"Copy command":`複製指令`,"Terminal input":`終端機輸入`,Seek:`拖曳進度`,"Rewind 10 seconds":`後退 10 秒`,"Forward 10 seconds":`快轉 10 秒`,Volume:`音量`,"Toggle captions":`開關字幕`,"Playback speed":`播放速度`,Quality:`畫質`,"Picture in picture":`子母畫面`,Play:`播放`,Pause:`暫停`,Mute:`靜音`,Unmute:`取消靜音`,"Exit fullscreen":`結束全螢幕`,"Enter fullscreen":`全螢幕`,Expand:`展開`,Collapse:`摺疊`,"Copy reply":`複製回覆`,"Good result":`結果好`,"Bad result":`結果不好`,"Dialog Close":`關閉對話方塊`,Notifications:`通知`,Account:`帳戶`,Cart:`購物車`,Call:`通話`,"Video call":`視訊通話`,Message:`訊息`,Main:`主導覽`,Columns:`欄`,"No results.":`沒有結果。`,"No results":`無結果`,"No results found":`找不到結果`,"Drop files here":`將檔案拖放到這裡`,"Drag & drop files here":`拖放檔案到這裡`,"or click to browse (max {maxFiles} files, {maxSize}MB each)":`或點擊瀏覽(最多 {maxFiles} 個檔案,每個 {maxSize} MB)`,"Remove {name}":`移除 {name}`,"{selected} of {total} row(s) selected.":`已選取 {selected}/{total} 列。`,"Try again":`再試一次`,"What’s up next?":`接下來做什麼?`,"Show password":`顯示密碼`,"Hide password":`隱藏密碼`,"Search icons":`搜尋圖示`,"No icon matches":`沒有相符的圖示`,"Show all items ({n})":`顯示全部 ({n})`,"Fewer {what}":`減少{what}`,"More {what}":`增加{what}`,"No tasks available. Add tasks to display Gantt chart.":`沒有任務。新增任務以顯示甘特圖。`,January:`一月`,February:`二月`,March:`三月`,April:`四月`,May:`五月`,June:`六月`,July:`七月`,August:`八月`,September:`九月`,October:`十月`,November:`十一月`,December:`十二月`,Su:`日`,Mo:`一`,Tu:`二`,We:`三`,Th:`四`,Fr:`五`,Sa:`六`,"just now":`剛剛`,"in a moment":`稍後`,"in 1 minute":`1 分鐘後`,"in {n} minutes":`{n} 分鐘後`,"in 1 hour":`1 小時後`,"in {n} hours":`{n} 小時後`,tomorrow:`明天`,"in {n} days":`{n} 天後`,"in 1 week":`1 週後`,"in {n} weeks":`{n} 週後`,"in 1 month":`1 個月後`,"in {n} months":`{n} 個月後`,"in 1 year":`1 年後`,"in {n} years":`{n} 年後`,"1 minute ago":`1 分鐘前`,"{n} minutes ago":`{n} 分鐘前`,"1 hour ago":`1 小時前`,"{n} hours ago":`{n} 小時前`,"1 day ago":`1 天前`,"{n} days ago":`{n} 天前`,"1 week ago":`1 週前`,"{n} weeks ago":`{n} 週前`,"1 month ago":`1 個月前`,"{n} months ago":`{n} 個月前`,"1 year ago":`1 年前`,"{n} years ago":`{n} 年前`,"Cookie notice":`Cookie 通知`,"Cookie preferences":`Cookie 偏好`,"Close and use essential cookies only":`關閉並僅使用必要 Cookie`,Back:`返回`,"Log in":`登入`,"Search Hanzo or ask AI":`搜尋 Hanzo 或詢問 AI`,"Search models":`搜尋模型`,"Search branches…":`搜尋分支…`,"Search repositories…":`搜尋存放庫…`,"Show options":`顯示選項`,Retry:`重試`,"Donut chart":`環形圖`,"Find an organization":`尋找組織`,Organizations:`組織`,"Organization name":`組織名稱`,"Previous page":`上一頁`,"Next page":`下一頁`,"Continue with credits":`使用額度繼續`,"Try Hanzo":`試用 Hanzo`,"Terms & Policies":`條款與政策`,"Who this is for":`適合誰`,"Bill yearly":`按年計費`,Apps:`應用程式`,"Card actions":`卡片操作`,"Assign to...":`指派給...`,"Search cards...":`搜尋卡片...`,"Clear search":`清除搜尋`,"Open files":`開啟的檔案`,"Close panel":`關閉面板`,"Add an organization":`新增組織`,"Keyboard Shortcuts":`鍵盤快速鍵`,"Run a command":`執行指令`,"Type shell command...":`輸入 shell 指令...`,"Attached to the next message":`附加到下一則訊息`,"Channel Member Roster":`頻道成員`,"Channel Collaborative Notes":`頻道協作筆記`,"Code Diff Viewer":`程式碼差異檢視`,"Live Voice Call":`即時語音通話`,"MCP Server Hub":`MCP 伺服器中心`,"Multi-Agent Swarm Bar":`多代理群集列`,"Write shared channel notes, meeting agenda, or AI summaries...":`撰寫頻道筆記、會議議程或 AI 摘要...`,"Help improve our AI models":`協助改進我們的 AI 模型`,"Your name":`你的名字`,"Your role":`你的角色`,"Country or region":`國家或地區`,"Card details":`卡片資訊`,"Agree to recurring charges":`同意週期性扣款`,"How you will use Hanzo":`你會如何使用 Hanzo`,"Team size":`團隊規模`,"I agree to the Terms of Service and Acceptable Use Policy and confirm that I am at least 18 years of age":`我同意服務條款與可接受使用政策,並確認我已年滿 18 歲。`,"Empty string":`空字串`,"Empty array":`空陣列`,"Empty object":`空物件`,"Copy {what}":`複製{what}`,"Ask anything":`儘管問`,Auto:`自動`,Instant:`即時`,Low:`低`,Medium:`中`,High:`高`,Max:`最大`,Dictate:`聽寫`,"Dictating — click to stop":`正在聽寫 — 點擊停止`,"Dictation settings":`聽寫設定`,Language:`語言`,"No devices found":`找不到裝置`,"Microphone {n}":`麥克風 {n}`,"Nothing matches":`沒有相符項目`,Commands:`指令`,"Search commands…":`搜尋指令…`,Agents:`代理`,Skills:`技能`,Connectors:`連接器`,"Design system":`設計系統`,Plugins:`外掛`,Devices:`裝置`,Memory:`記憶`,Research:`研究`,On:`開`,"Upload or add files":`上傳或新增檔案`,"Add files, agents, skills and more":`新增檔案、代理、技能等`,"No agents yet":`還沒有代理`,"No skills yet":`還沒有技能`,"No connectors yet":`還沒有連接器`,"No design system yet":`還沒有設計系統`,"No plugins yet":`還沒有外掛`,"No devices yet":`還沒有裝置`,"Search agents":`搜尋代理`,"Search skills":`搜尋技能`,"Search connectors":`搜尋連接器`,"Search design system":`搜尋設計系統`,"Search plugins":`搜尋外掛`,"Search devices":`搜尋裝置`,"Reading agents":`正在讀取代理`,"Reading skills":`正在讀取技能`,"Reading connectors":`正在讀取連接器`,"Reading design system":`正在讀取設計系統`,"Reading plugins":`正在讀取外掛`,"Adaptive reasoning based on task complexity":`依任務複雜度調整的推理`,"Answers right away, without thinking":`立即回答,不進行思考`,"A quick pass with minimal thinking":`快速過一遍,少思考`,"Thinks before answering":`先想再答`,"Deep reasoning for complex problems":`針對複雜問題的深度推理`,"Maximum compute and exhaustive verification":`最大算力與徹底驗證`,Effort:`力度`,"Effort: {level}":`力度:{level}`,Mode:`模式`,"Mode: {mode}":`模式:{mode}`,Model:`模型`,"Model: {name}":`模型:{name}`,"Voice mode":`語音模式`,"Hanzo is speaking — talk to interrupt":`Hanzo 正在說話 — 開口即可打斷`,"In conversation — click to hang up":`通話中 — 點擊掛斷`,"Go to testimonial {n}":`前往評價 {n}`,"Go to card {n}":`前往卡片 {n}`,"{n} of {total}":`{n} / {total}`,"Reading…":`正在讀取…`,Skill:`技能`,Plugin:`外掛`},Lz=e=>e,Kne={ar:Lz(Ane),"de-DE":Lz(jne),"es-ES":Lz(Mne),"fr-FR":Lz(Nne),"hi-IN":Lz(Pne),"id-ID":Lz(Fne),"it-IT":Lz(Ine),"ja-JP":Lz(Lne),"ko-KR":Lz(Rne),"pt-BR":Lz(zne),ru:Lz(Bne),th:Lz(Vne),tr:Lz(Hne),vi:Lz(Une),"zh-Hans":Lz(Wne),"zh-Hant":Lz(Gne)},Rz=e=>Kne[e]??{},qne={display:`contents`};function Jne({children:e,locale:t,messages:n,syncDocument:r=!1}){let i=LL(t),a=HL(i,n?{...Rz(i),...n}:Rz(i)),o=RL(i),s=zL(t);return(0,V.useLayoutEffect)(()=>{if(!r||typeof document>`u`)return;let e=document.documentElement,t=e.lang,n=e.dir;return e.lang=s,e.dir=o,()=>{e.lang=t,e.dir=n}},[r,s,o]),(0,H.jsx)(VL.Provider,{value:a,children:(0,H.jsx)(`div`,{dir:o,lang:s,style:qne,children:e})})}var Yne=(0,V.createContext)(null),Xne=({children:e,theme:t,analytics:n,config:r=KS,appearance:i,locale:a,messages:o})=>{let{pref:s,set:c}=jz(i),l=(0,V.useMemo)(()=>({pref:s,set:c}),[s,c]),u=Dz(),d=a||o?(0,H.jsx)(Jne,{locale:a,messages:o,children:e}):e,f=(0,H.jsx)(Yne.Provider,{value:l,children:(0,H.jsx)(ip,{config:r,defaultTheme:t??u,disableInjectCSS:!0,children:d})});return n?(0,H.jsx)(np,{...n===!0?{}:n,children:f}):f},Zne=({size:e=11,label:t})=>(0,H.jsxs)(`svg`,{width:e*30/14,height:e,viewBox:`0 0 30 14`,focusable:`false`,...t?{role:`img`,"aria-label":t}:{"aria-hidden":!0},style:{flexShrink:0,display:`block`},children:[(0,H.jsx)(`path`,{d:`M7.4 12.8h6.8l3.1-11.6H7.4C4.2 1.2 1.6 3.8 1.6 7s2.6 5.8 5.8 5.8z`,fill:`#fff`,fillRule:`evenodd`,clipRule:`evenodd`}),(0,H.jsx)(`path`,{d:`M22.6 0H7.4c-3.9 0-7 3.1-7 7s3.1 7 7 7h15.2c3.9 0 7-3.1 7-7s-3.2-7-7-7zm-21 7c0-3.2 2.6-5.8 5.8-5.8h9.9l-3.1 11.6H7.4c-3.2 0-5.8-2.6-5.8-5.8z`,fill:`#06f`,fillRule:`evenodd`,clipRule:`evenodd`}),(0,H.jsx)(`path`,{d:`M24.6 4c.2.2.2.6 0 .8L22.5 7l2.2 2.2c.2.2.2.6 0 .8-.2.2-.6.2-.8 0l-2.2-2.2-2.2 2.2c-.2.2-.6.2-.8 0-.2-.2-.2-.6 0-.8L20.8 7l-2.2-2.2c-.2-.2-.2-.6 0-.8.2-.2.6-.2.8 0l2.2 2.2L23.8 4c.2-.2.6-.2.8 0z`,fill:`#fff`}),(0,H.jsx)(`path`,{d:`M12.7 4.1c.2.2.3.6.1.8L8.6 9.8c-.1.1-.2.2-.3.2-.2.1-.5.1-.7-.1L5.4 7.7c-.2-.2-.2-.6 0-.8.2-.2.6-.2.8 0L8 8.6l3.8-4.5c.2-.2.6-.2.9 0z`,fill:`#06f`})]}),zz=`hzconsent-open`,Bz=`#choices`,Qne=1500,$ne=()=>{let e=Oe();return e.region?e.mode:void 0},ere=Symbol.for(`hanzo.ui.consent.links`),Vz=`hzconsent-links`;function tre(){if((globalThis[ere]??0)>0)return!0;for(let e of document.querySelectorAll(`a[href*="${Bz}"]`))try{let t=new URL(e.getAttribute(`href`)??``,document.baseURI);if(t.hash===Bz&&t.origin===window.location.origin)return!0}catch{}return!1}var nre=(e,t,n,r)=>[{id:`necessary`,title:e(`Strictly Necessary Cookies`),body:e(`These are needed for the site to work, so they are always on. They keep you signed in and your session secure, protect forms against cross-site request forgery, spread traffic across servers, remember the choice you make here, and keep what you have typed into a form. They include {brand}'s own first-party analytics, which counts visits and finds what is broken for {brand} alone and is never sold or shared.`,{brand:t})},{id:`analytics`,key:`analytics`,title:e(`Performance Cookies`),body:e(`Google Analytics: lets Google measure visits to {brand} with its own cookies.`,{brand:t})},{id:`marketing`,key:`marketing`,title:e(`Marketing Cookies`),body:e(`The Meta pixel: lets Meta measure the sign-ups and orders {brand}'s ads led to.`,{brand:t})},{id:`ads`,key:`ads`,title:e(`Sell, Share, or Use Your Data for Targeted Advertising`),body:e(`Lets Google and Meta use your visits to choose the ads they show you on other sites and apps. Some US state privacy laws call this a “sale” or “sharing” of your personal information, or “targeted advertising”, and give you the right to opt out: {rule}`,{rule:e(r?`your browser’s signal keeps it off.`:n?`it stays off unless you turn it on.`:`turn this off to opt out.`)})}],rre=(e,t,n)=>e(n?`We use cookies and similar technologies to provide our services. Essential cookies are required for the site to work and cannot be turned off. Learn more in our `:t?`We use cookies and similar technologies to provide our services, measure performance, and support advertising. Essential cookies are required for the site to work and cannot be turned off. You can allow or reject optional cookies below. Learn more in our `:`We use cookies and similar technologies to provide our services, measure performance, and support advertising. Google Analytics and the Meta pixel run on this site by default. Turn either off below, or turn off the last switch to opt out of the sale or sharing of your personal information for targeted advertising; each switch is saved as soon as you change it. Essential cookies are required for the site to work and cannot be turned off. Learn more in our `),ire=D(`Your browser asks sites not to track you, so all of these stay off.`),Hz={top:`max(16px, calc(var(--safe-top, env(safe-area-inset-top, 0px)) + 8px))`,bottom:`max(16px, calc(var(--safe-bottom, env(safe-area-inset-bottom, 0px)) + 8px))`,left:`max(16px, calc(var(--safe-left, env(safe-area-inset-left, 0px)) + 8px))`,right:`max(16px, calc(var(--safe-right, env(safe-area-inset-right, 0px)) + 8px))`},Uz={button:`var(--radius-lg, 12px)`,card:`var(--radius-xl, 16px)`},Wz={bg:`$background`,borderWidth:1,borderColor:`$borderColor`,rounded:Uz.card,shadowColor:`rgba(0,0,0,0.25)`,shadowRadius:24,shadowOffset:{width:0,height:8}},Gz={...B(`consent`),...Wz,position:`fixed`,b:Hz.bottom,l:Hz.left,r:Hz.right,mx:`auto`,z:`var(--z-banner, 50)`,py:`$3`,paddingInlineStart:`$4`,paddingInlineEnd:56},Kz={width:`fit-content`},qz={outlineColor:`var(--ring)`,outlineStyle:`solid`,outlineWidth:2,outlineOffset:2},Jz=(e,t,n)=>({size:`sm`,minH:36,rounded:Uz.button,bg:e,color:n,borderColor:`transparent`,hoverStyle:{bg:t,borderColor:`transparent`,opacity:1},pressStyle:{bg:t,borderColor:`transparent`,opacity:1},focusStyle:{borderColor:`transparent`},focusVisibleStyle:qz}),Yz=Jz(`var(--primary)`,`var(--primary-hover)`,`var(--primary-foreground)`),Xz=Jz(`var(--secondary)`,`var(--secondary-hover)`,`var(--secondary-foreground)`),Zz={rounded:Uz.button,bg:`transparent`,borderColor:`transparent`,hoverStyle:{bg:`var(--secondary)`,borderColor:`transparent`,opacity:1},pressStyle:{bg:`var(--secondary-hover)`,borderColor:`transparent`,opacity:1},focusStyle:{borderColor:`transparent`},focusVisibleStyle:qz},Qz={type:`button`,variant:`link`,size:`sm`,px:0,minH:0,color:`$aside`,hoverStyle:{color:`$ink`},focusVisibleStyle:qz,startIcon:(0,H.jsx)(Zne,{})},$z={color:`inherit`,textDecoration:`underline`,whiteSpace:`nowrap`},eB={position:`fixed`,t:0,r:0,b:0,l:0},are=`a[href], button:not([disabled]), [tabindex]:not([tabindex="-1"])`,ore={type:`button`},sre=({cookies:e=`https://hanzo.ai/cookies`,privacy:t=`https://hanzo.ai/privacy`,terms:n=`https://hanzo.ai/terms`,brand:r=`Hanzo`,floating:i=!0})=>{let{t:a}=R(),[o,s]=(0,V.useState)(),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)({analytics:!1,marketing:!1,ads:!1}),m=(0,V.useRef)(f);m.current=f;let[h,g]=(0,V.useState)({}),[_,v]=(0,V.useState)(!0),b=(0,V.useRef)(void 0),x=(0,V.useRef)(!1),S=(0,V.useRef)(null),C=(0,V.useRef)(null),w=(0,V.useRef)(null),T=(0,V.useRef)(!1),E=(0,V.useRef)(!1),D=(0,V.useRef)(new Set),O=(0,V.useId)(),[k,A]=(0,V.useState)(!1),j=(e=b.current)=>e===`eu`?Ye():e===`global`&&!Ze()&&!Qe(),ee=e=>{let t=we();for(let n of D.current)(e!==`eu`||!m.current[n])&&(t[n]=m.current[n]);return t},M=e=>{let t=ee(e);p(t),e!==`eu`&&D.current.size&&ke(t)},N=()=>{if(x.current)return;let e=document.activeElement;S.current=e instanceof HTMLElement&&e!==document.body?e:null,x.current=!0,D.current=new Set,A(Qe()),E.current=De(),p(we()),d(!0)},P=()=>{x.current=!1,d(!1),l(j())};(0,V.useEffect)(()=>{let e=()=>{l(j()),A(Qe()),x.current&&E.current&&!De()&&(E.current=!1,M(b.current??`eu`))},t=t=>{let n=b.current!==t;b.current=t,s(t),e(),n&&x.current&&M(t)},n=()=>t(Oe().mode),r=$ne();r&&t(r);let i=r?void 0:window.setTimeout(()=>b.current??t(`eu`),Qne),a=0,o=()=>{a||=window.requestAnimationFrame(()=>{a=0,v(tre())})};o();let c=new MutationObserver(o);c.observe(document.body,{childList:!0,subtree:!0});let u=()=>{window.location.hash===Bz&&(queueMicrotask(()=>history.replaceState(history.state,``,window.location.pathname+window.location.search)),N())},d=e=>{if(e.defaultPrevented||e.button!==0||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return;let t=e.target?.closest?.(`a[href]`),n=t?.getAttribute(`href`),r=t?.getAttribute(`target`);if(!n||t?.hasAttribute(`download`)||r&&r!==`_self`)return;let i;try{i=new URL(n,document.baseURI)}catch{return}i.hash===Bz&&i.origin===window.location.origin&&(e.preventDefault(),N())};return u(),window.addEventListener(zz,N),window.addEventListener(Ie,n),window.addEventListener(Vz,o),window.addEventListener(`hashchange`,u),document.addEventListener(`click`,d,{capture:!0}),()=>{window.clearTimeout(i),window.cancelAnimationFrame(a),c.disconnect(),window.removeEventListener(zz,N),window.removeEventListener(Ie,n),window.removeEventListener(Vz,o),window.removeEventListener(`hashchange`,u),document.removeEventListener(`click`,d,{capture:!0})}},[]),(0,V.useEffect)(()=>{if(u)return Ee(!0),()=>Ee(!1)},[u]),(0,V.useEffect)(()=>{if(!u){if(!T.current)return;T.current=!1;let e=S.current;S.current=null,e?.isConnected?e.focus():(w.current??document.querySelector(`[data-slot="consent-choices"] button`))?.focus();return}T.current=!0;let e=()=>[...C.current?.querySelectorAll(are)??[]];e()[0]?.focus();let t=t=>{if(t.key===`Escape`){t.preventDefault(),P();return}if(t.key!==`Tab`)return;let n=e(),r=n[0],i=n[n.length-1];if(!r||!i)return;let a=document.activeElement,o=!!a&&!!C.current?.contains(a);t.shiftKey&&(a===r||!o)?(t.preventDefault(),i.focus()):!t.shiftKey&&(a===i||!o)&&(t.preventDefault(),r.focus())};return document.addEventListener(`keydown`,t),()=>document.removeEventListener(`keydown`,t)},[u]);let te=e=>()=>{e(),x.current=!1,l(j()),d(!1)},F=null;if(u){let i=(o??`eu`)===`eu`,s=(e,t)=>{D.current.add(e);let n={...f,[e]:t};p(n),i||ke(n)};F=(0,H.jsxs)(z,{...B(`consent-sheet`),...eB,z:`var(--z-modal, 600)`,items:`center`,justify:`center`,style:{padding:`${Hz.top} ${Hz.right} ${Hz.bottom} ${Hz.left}`},children:[(0,H.jsx)(z,{...eB,position:`absolute`,z:0,bg:`rgba(0,0,0,0.6)`,"aria-hidden":!0,onPress:P}),(0,H.jsxs)(z,{...B(`consent`),...Wz,ref:C,role:`dialog`,"aria-modal":!0,"aria-labelledby":`${O}-title`,position:`relative`,width:`100%`,maxW:560,maxH:`100%`,overflow:`hidden`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$3`,pt:`$5`,pb:`$3`,paddingInlineStart:`$5`,paddingInlineEnd:`$4`,children:[(0,H.jsx)(U,{render:`h2`,id:`${O}-title`,m:0,fontSize:`$6`,lineHeight:`$6`,fontWeight:`600`,color:`$ink`,children:a(`Cookie Preferences`)}),(0,H.jsx)(W,{type:`button`,size:`icon`,...Zz,"aria-label":a(`Close`),onClick:P,children:(0,H.jsx)(Rn,{size:16})})]}),(0,H.jsxs)(z,{shrink:1,minH:0,overflowY:`auto`,px:`$5`,pb:`$2`,style:{overscrollBehavior:`contain`},children:[(0,H.jsxs)(Nt,{size:`$2`,color:`$aside`,m:0,pb:`$3`,children:[rre(a,i,k),a(`{cookies}, {privacy}, and {terms}.`,{cookies:(0,H.jsx)(`a`,{href:e,style:$z,children:a(`Cookie Policy`)}),privacy:(0,H.jsx)(`a`,{href:t,style:$z,children:a(`Privacy Policy`)}),terms:(0,H.jsx)(`a`,{href:n,style:$z,children:a(`Terms of Service`)})})]}),k?(0,H.jsx)(Nt,{size:`$2`,color:`$ink`,m:0,pb:`$3`,children:a(ire)}):null,nre(a,r,i,k).map(e=>{let t=h[e.id]===!0,n=`${O}-${e.id}`;return(0,H.jsxs)(z,{...B(`consent-section`),borderTopWidth:1,borderColor:`$borderColor`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$3`,minH:52,py:`$2`,children:[(0,H.jsx)(y,{render:`h3`,flex:1,minW:0,m:0,children:(0,H.jsxs)(y,{render:`button`,...ore,"aria-expanded":t,"aria-controls":n,onPress:()=>g({...h,[e.id]:!t}),flex:1,minW:0,items:`center`,gap:`$2`,p:0,bg:`transparent`,borderWidth:0,cursor:`pointer`,children:[(0,H.jsx)(y,{shrink:0,rotate:t?`180deg`:`0deg`,opacity:.7,children:(0,H.jsx)(wp,{size:16})}),(0,H.jsx)(U,{fontSize:`$3`,lineHeight:`$3`,fontWeight:`600`,color:`$ink`,...nh(`start`),children:e.title})]})}),e.key?(0,H.jsx)(av,{"aria-label":e.title,"aria-describedby":n,disabled:k,checked:!k&&f[e.key],onCheckedChange:t=>s(e.key,t===!0)}):(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,whiteSpace:`nowrap`,children:a(`Always Active`)})]}),(0,H.jsx)(z,{id:n,display:t?`flex`:`none`,pb:`$3`,paddingInlineStart:24,children:(0,H.jsx)(Nt,{size:`$2`,color:`$aside`,m:0,children:e.body})})]},e.id)})]}),(0,H.jsx)(y,{flexWrap:`wrap`,gap:`$2`,px:`$5`,py:`$4`,borderTopWidth:1,borderColor:`$borderColor`,children:i?(0,H.jsxs)(H.Fragment,{children:[k?null:(0,H.jsx)(W,{type:`button`,...Xz,grow:1,onClick:te(Ae),children:a(`Accept all`)}),(0,H.jsx)(W,{type:`button`,...Yz,grow:1,onClick:te(()=>ke(f)),children:a(`Save preferences`)})]}):(0,H.jsx)(W,{type:`button`,...Yz,grow:1,onClick:P,children:a(`Done`)})})]})]})}if(!o)return F;let I=i&&!_&&!c?(0,H.jsx)(y,{...B(`consent-choices`),position:`fixed`,b:Hz.bottom,l:Hz.left,z:`var(--z-banner, 50)`,px:`$2.5`,py:`$1`,bg:`$background`,borderWidth:1,borderColor:`$borderColor`,rounded:Uz.button,children:(0,H.jsx)(W,{...Qz,onClick:N,children:a(`Your Privacy Choices`)})}):null;return c&&o===`global`?I=(0,H.jsxs)(y,{...Gz,role:`region`,"aria-label":a(`Cookie notice`),style:Kz,maxW:1200,flexWrap:`wrap`,items:`center`,columnGap:`$4`,rowGap:`$2`,children:[(0,H.jsx)(z,{shrink:1,minW:0,children:(0,H.jsx)(Nt,{size:`$2`,color:`$ink`,m:0,children:a(`We use cookies to improve your experience. By continuing to browse, you agree.`)})}),(0,H.jsx)(W,{...Qz,onClick:N,children:a(`Your Privacy Choices`)}),(0,H.jsx)(W,{type:`button`,size:`icon`,...Zz,"aria-label":a(`Close`),position:`absolute`,t:`$3`,insetInlineEnd:`$3`,onClick:te(Me),children:(0,H.jsx)(Rn,{size:16})})]}):c&&o===`eu`&&(I=(0,H.jsxs)(y,{...Gz,role:`dialog`,"aria-label":a(`Cookie preferences`),style:Kz,maxW:1200,flexWrap:`wrap`,items:`center`,columnGap:`$4`,rowGap:`$3`,children:[(0,H.jsx)(z,{shrink:1,minW:0,children:(0,H.jsx)(Nt,{size:`$2`,color:`$ink`,m:0,children:a(`Essential cookies keep {brand} running. With your OK, optional cookies help us measure performance and ads.`,{brand:r})})}),(0,H.jsxs)(y,{gap:`$2`,marginInlineStart:`auto`,items:`center`,flexWrap:`wrap`,children:[(0,H.jsx)(W,{ref:w,type:`button`,...Xz,onClick:N,children:a(`Manage preferences`)}),(0,H.jsx)(W,{type:`button`,...Yz,onClick:te(Ae),children:a(`Accept all`)})]}),(0,H.jsx)(W,{type:`button`,size:`icon`,...Zz,"aria-label":a(`Close and use essential cookies only`),position:`absolute`,t:`$3`,insetInlineEnd:`$3`,onClick:te(Xe),children:(0,H.jsx)(Rn,{size:16})})]})),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{inert:u||void 0,style:{display:`contents`},children:I}),F]})},tB=32;function nB(e){let t=new Uint8Array(e);return crypto.getRandomValues(t),rB(t.buffer)}async function cre(e){let t=new TextEncoder;return crypto.subtle.digest(`SHA-256`,t.encode(e))}function rB(e){let t=new Uint8Array(e),n=``;for(let e of t)n+=String.fromCharCode(e);return btoa(n).replace(/\+/g,`-`).replace(/\//g,`_`).replace(/=+$/,``)}async function iB(){let e=nB(tB);return{codeVerifier:e,codeChallenge:rB(await cre(e))}}function aB(){return nB(tB)}var oB={discovery:`/.well-known/openid-configuration`,authorize:`/v1/iam/oauth/authorize`,token:`/v1/iam/oauth/token`,userinfo:`/v1/iam/oauth/userinfo`,jwks:`/v1/iam/.well-known/jwks`,logout:`/v1/iam/oauth/logout`,revoke:`/v1/iam/oauth/revoke`},sB={authMethods:`/v1/iam/auth/methods`,authIdentifier:`/v1/iam/auth/identifier`,authApplication:`/v1/iam/auth/application`,login:`/v1/iam/login`,sendCode:`/v1/iam/verification-codes`,federationMfa:`/v1/iam/oauth/federation/mfa`,signup:`/v1/iam/signup`,terms:`/v1/iam/terms`,password:`/v1/iam/password`,address:`/v1/iam/address`,accept:`/v1/iam/invitations/accept`,web3Nonce:`/v1/iam/web3/nonce`,web3Verify:`/v1/iam/web3/verify`};function cB(e){return e.replace(/\/+$/,``)}function lB(e,t){return`${cB(e)}${oB[t]}`}function lre(e){let t=new URL(e.endpoint??lB(e.serverUrl,`authorize`));t.searchParams.set(`client_id`,e.clientId),t.searchParams.set(`response_type`,`code`),t.searchParams.set(`redirect_uri`,e.redirectUri),t.searchParams.set(`scope`,e.scope??`openid profile email`),t.searchParams.set(`state`,e.state),e.codeChallenge&&(t.searchParams.set(`code_challenge`,e.codeChallenge),t.searchParams.set(`code_challenge_method`,`S256`)),e.prompt&&t.searchParams.set(`prompt`,e.prompt);for(let[n,r]of Object.entries(e.params??{}))t.searchParams.set(n,r);return t}function ure(e){if(!e)return{};try{let t=e.split(`.`)[1];return t?JSON.parse(atob(t.replace(/-/g,`+`).replace(/_/g,`/`))):{}}catch{return{}}}var uB={chain:`evm`,scheme:`secp256k1-eip191`};async function dre(e){let t=e.trim().toLowerCase().replace(/^0x/,``);if(!/^[0-9a-f]{40}$/.test(t))throw Error(`not an Ethereum address: ${e}`);let{keccak_256:n}=await Le(async()=>{let{keccak_256:e}=await import(`./sha3-DDKddPFc.js`);return{keccak_256:e}},[]),r=n(new TextEncoder().encode(t)),i=`0x`;for(let e=0;e<t.length;e++){let n=e%2==0?r[e>>1]>>4:r[e>>1]&15;i+=n>=8?t[e].toUpperCase():t[e]}return i}function fre(e,t,n){let{domain:r,uri:i,statement:a,nonce:o,issuedAt:s,expirationTime:c,version:l}=e;if(a?.includes(`
|
|
36
|
+
`))throw Error(`the sign-in statement must be one line`);let u=[`${r} wants you to sign in with your Ethereum account:`,t,``];return a&&u.push(a,``),u.push(`URI: ${i}`,`Version: ${l||`1`}`,`Chain ID: ${n}`,`Nonce: ${o}`,`Issued At: ${s}`),c&&u.push(`Expiration Time: ${c}`),u.join(`
|
|
37
|
+
`)}function pre(e){let t=`0x`;for(let n of new TextEncoder().encode(e))t+=n.toString(16).padStart(2,`0`);return t}function mre(e){let t=typeof e==`string`?Number.parseInt(e,16):typeof e==`number`?e:NaN;return Number.isSafeInteger(t)&&t>0?t:1}var dB=1500,fB=`hanzo_iam_`,pB=`${fB}state`,mB=`${fB}code_verifier`,hB=`${fB}access_token`,gB=`${fB}refresh_token`,_B=`${fB}id_token`,vB=`${fB}expires_at`,yB=`${fB}hold`,bB=`${fB}spent`,hre=`${fB}refresh`,xB=`${fB}refresh_lease`,gre=3e4,_re=50,vre=50,SB=`${mB}:`;function CB(e){return`${SB}${e}`}var yre=12;function bre(e,t){return`${t}.${e}`}function wB(e){let t=e.indexOf(`.`);if(t>0){let n=e.slice(0,t);if(/^\d+$/.test(n))return{issuedAt:Number(n),codeVerifier:e.slice(t+1)}}return{issuedAt:0,codeVerifier:e}}var xre=`hanzo_iam_login`,Sre=`hanzo-iam`;function Cre(e,t){let n=new URLSearchParams({code:t});e.state&&n.set(`state`,e.state);let r=e.redirectUri.includes(`?`)?`&`:`?`;return`${e.redirectUri}${r}${n.toString()}`}var wre=9e5,TB=class extends Error{constructor(e,t){super(e),this.code=t,this.name=`Refused`}code},Tre=class extends Error{constructor(e,t=[],n){super(`this account signs in with a second factor`),this.directive=e,this.factors=t,this.request=n,this.name=`SecondFactor`}directive;factors;request},EB=class extends Error{constructor(e,t){super(`confirm the account's email address to finish signing in`),this.email=e,this.request=t,this.name=`EmailRequired`}email;request};function DB(e){return`recovery`in e?{recoveryCode:e.recovery}:{mfaType:e.type,passcode:e.passcode}}function Ere(e){if(!Array.isArray(e))return[];let t=e.flatMap(e=>{let t=e??{};return typeof t.mfaType!=`string`||!t.mfaType?[]:[{type:t.mfaType,preferred:t.isPreferred===!0,remember:typeof t.mfaRememberInHours==`number`?t.mfaRememberInHours:0}]}),n=``;for(let e of t)(e.type===`email`||e.type===`sms`)&&(n===``||e.preferred)&&(n=e.type);return t.map(({type:e,remember:t})=>({type:e,sent:e===n,remember:t}))}var Dre=class extends Error{constructor(){super(`no account holds this address; accept the terms to create one`),this.name=`SignupRequired`}},OB=class extends Error{constructor(e){super(`the session has ended: ${e}`),this.reason=e,this.name=`SessionEnded`}reason},kB=class extends Error{constructor(e,t){super(e),this.reason=t,this.name=`Unmatched`}reason};function AB(e){try{let t=e(),n=`${fB}probe`;return t.setItem(n,`1`),t.removeItem(n),t}catch{return null}}function Ore(){return AB(()=>localStorage)??AB(()=>sessionStorage)}function kre(){let e=new Map;return{get length(){return e.size},clear:()=>e.clear(),getItem:t=>e.has(t)?e.get(t):null,key:t=>Array.from(e.keys())[t]??null,removeItem:t=>{e.delete(t)},setItem:(t,n)=>{e.set(t,String(n))}}}var jB=e=>new Promise(t=>setTimeout(t,e));function Are(){try{return typeof navigator<`u`&&navigator.locks?navigator.locks:null}catch{return null}}async function jre(e,t){let n=Are();if(n)return n.request(hre,t);let r=aB(),i=()=>e.getItem(xB)?.startsWith(`${r}.`)===!0;for(;;){let t=e.getItem(xB);if((t?Number(t.slice(t.indexOf(`.`)+1)):0)>Date.now()){await jB(vre);continue}if(e.setItem(xB,`${r}.${Date.now()+gre}`),await jB(_re),i())break}try{return await t()}finally{i()&&e.removeItem(xB)}}function Mre(e){try{let t=JSON.parse(e);return{error:typeof t.error==`string`?t.error:``,description:typeof t.error_description==`string`?t.error_description:``}}catch{return{error:``,description:``}}}async function MB(e,t){let n=await e.json().catch(()=>({}));if(!e.ok||n.status===`error`)throw new TB(typeof n.msg==`string`&&n.msg?n.msg:`${t} (${e.status})`,typeof n.code==`string`?n.code:``);return n}async function NB(e,t){return(await MB(e,t)).data}var Nre=class{config;storage;txStorage;redeemable;discoveryCache=null;callbackInFlight=null;held;refreshing=null;constructor(e){this.config=e;let t=Ore();this.storage=e.storage??t??kre(),this.txStorage=t??this.storage,this.redeemable=t!==null||e.storage!==void 0,this.held=this.stored()}async getDiscovery(){if(this.discoveryCache)return this.discoveryCache;let e=cB(this.config.serverUrl);try{let t=await fetch(`${e}${oB.discovery}`,{headers:{Accept:`application/json`}});if(t.ok)return this.discoveryCache=await t.json(),this.discoveryCache}catch{}return this.discoveryCache={issuer:e,authorization_endpoint:lB(e,`authorize`),token_endpoint:lB(e,`token`),userinfo_endpoint:lB(e,`userinfo`),jwks_uri:lB(e,`jwks`),revocation_endpoint:lB(e,`revoke`),end_session_endpoint:lB(e,`logout`),response_types_supported:[`code`],grant_types_supported:[`authorization_code`,`refresh_token`],scopes_supported:[`openid`,`email`,`profile`]},this.discoveryCache}async tokenEndpoint(){return this.config.proxyBaseUrl?lB(this.config.proxyBaseUrl,`token`):(await this.getDiscovery()).token_endpoint}async userinfoEndpoint(){return this.config.proxyBaseUrl?lB(this.config.proxyBaseUrl,`userinfo`):(await this.getDiscovery()).userinfo_endpoint}async revocationEndpoint(){return this.config.proxyBaseUrl?lB(this.config.proxyBaseUrl,`revoke`):(await this.getDiscovery()).revocation_endpoint??lB(this.config.serverUrl,`revoke`)}async endSessionEndpoint(){return this.config.proxyBaseUrl?lB(this.config.proxyBaseUrl,`logout`):(await this.getDiscovery()).end_session_endpoint??lB(this.config.serverUrl,`logout`)}stashPkce(e,t){this.sweepStaleVerifiers(),this.txStorage.setItem(CB(e),bre(t,Date.now())),this.txStorage.setItem(pB,e),this.txStorage.setItem(mB,t)}sweepStaleVerifiers(){let e=[];for(let t=this.txStorage.length-1;t>=0;t--){let n=this.txStorage.key(t);if(!n||!n.startsWith(SB))continue;let r=this.txStorage.getItem(n);e.push({key:n,issuedAt:r?wB(r).issuedAt:0})}e.sort((e,t)=>t.issuedAt-e.issuedAt);for(let t of e.slice(yre-1))this.txStorage.removeItem(t.key)}async buildAuthorizeUrl(e){if(!this.redeemable)throw Error(`@hanzo/iam: this browser keeps neither localStorage nor sessionStorage, so the PKCE verifier cannot outlive the redirect to IAM and the callback would fail. Call usableStorage() before starting a login to catch this on the page.`);let t=await this.getDiscovery(),{codeVerifier:n,codeChallenge:r}=await iB(),i=aB();return this.stashPkce(i,n),{url:lre({endpoint:t.authorization_endpoint,serverUrl:this.config.serverUrl,clientId:this.config.clientId,redirectUri:this.config.redirectUri,state:i,scope:this.config.scope,codeChallenge:r,prompt:e?.prompt,params:e?.additionalParams}),codeVerifier:n,state:i}}async signinRedirect(e){let{url:t}=await this.buildAuthorizeUrl(e);window.location.replace(t.toString())}async getSigninUrl(e){let{url:t}=await this.buildAuthorizeUrl(e);return t.toString()}asking=null;parties=new Map;ask(e){this.asking=e&&e.state?{...e,state:e.state}:null}get client(){return this.asking?.clientId??this.config.clientId}async party(e){if(e===this.config.clientId)return{application:this.config.application??this.config.clientId,organization:this.config.organization};let t=this.parties.get(e);if(t)return t;let n=new URL(`${cB(this.config.serverUrl)}${sB.authApplication}`);n.searchParams.set(`clientId`,e);let r=await NB(await fetch(n.toString(),{headers:{Accept:`application/json`}}),`could not read the application`)??{};if(typeof r.organization!=`string`||!r.organization)throw Error(`IAM did not name the application's organization`);let i={application:typeof r.name==`string`&&r.name?r.name:e,organization:r.organization};return this.parties.set(e,i),i}async own(){return this.asking??await this.mine()}async mine(){let{codeVerifier:e,codeChallenge:t}=await iB(),n=aB();return this.stashPkce(n,e),{clientId:this.config.clientId,redirectUri:this.config.redirectUri,scope:this.config.scope,state:n,codeChallenge:t,codeChallengeMethod:`S256`}}async credentialLogin(e){return this.post(e,await this.own())}async post(e,t,n){let r=this.config.proxyBaseUrl??this.config.serverUrl,i=new URL(n??`${cB(r)}${sB.login}`);i.searchParams.set(`clientId`,t.clientId),i.searchParams.set(`responseType`,`code`),i.searchParams.set(`redirectUri`,t.redirectUri),i.searchParams.set(`scope`,t.scope??`openid profile email`),t.state&&i.searchParams.set(`state`,t.state),t.nonce&&i.searchParams.set(`nonce`,t.nonce),t.prompt&&i.searchParams.set(`prompt`,t.prompt),t.loginHint&&i.searchParams.set(`login_hint`,t.loginHint),i.searchParams.set(`type`,`code`),t.codeChallenge&&(i.searchParams.set(`code_challenge`,t.codeChallenge),i.searchParams.set(`code_challenge_method`,t.codeChallengeMethod??`S256`));let a=await fetch(i.toString(),{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},credentials:`include`,body:JSON.stringify({type:`code`,...await this.party(t.clientId),autoSignin:!0,...e})}),o;try{o=await MB(a,`sign-in failed`)}catch(e){throw e instanceof TB&&e.code===`login_required`&&this.release(),e}let s=o.data;if(s===`NextMfa`||s===`RequiredMfa`)throw s===`NextMfa`&&this.hold(),new Tre(s,Ere(o.data2),t);if(s===`RequiredEmail`){this.hold();let e=o.data2??{};throw new EB(typeof e.email==`string`?e.email:``,t)}if(s===`SignupRequired`)throw new Dre;if(typeof s!=`string`||s.length===0)throw Error(`IAM did not return an authorization code`);return this.release(),Cre(t,s)}hold(){this.txStorage.setItem(yB,String(Date.now()+wre))}release(){this.txStorage.removeItem(yB)}holding(){return Number(this.txStorage.getItem(yB)??0)>Date.now()}async resume(e){if(this.holding())return null;try{return await this.credentialLogin(e?{loginHint:e}:{})}catch{return null}}loginWithPassword(e,t){return this.credentialLogin({username:e,password:t,signinMethod:`Password`})}loginWithCode(e,t){let n=e.includes(`@`);return this.credentialLogin({username:e,code:t,signinMethod:`Verification code`,...n?{email:e}:{phone:e}})}createAccountWithCode(e,t,n){return this.credentialLogin({username:e,code:t,signinMethod:`Verification code`,email:e,create:!0,terms:n.terms,aup:n.aup})}async verifyFactor(e,t,n=!1){if(!e.request)throw Error(`this second factor names no sign-in to finish`);try{return await this.post({...DB(t),enableMfaRemember:n},e.request)}catch(e){throw e instanceof TB&&this.release(),e}}async finishFederation(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=(await MB(await fetch(`${cB(t)}${sB.federationMfa}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},credentials:`include`,body:JSON.stringify(DB(e))}),`the sign-in could not be finished`)).data;if(typeof n!=`string`||!n)throw Error(`IAM did not say where the sign-in goes`);return n}confirmEmail(e,t){return this.post({passcode:t},e.request)}async changeEmail(e,t){try{await this.post({email:t},e.request)}catch(e){if(e instanceof EB)return e;throw e}throw Error(`IAM granted the sign-in without confirming the address`)}async resetPassword(e,t,n){await NB(await fetch(`${cB(this.config.serverUrl)}${sB.password}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({organization:this.config.organization,username:e,code:t,password:n})}),`could not set the password`)}async acceptInvite(e,t,n){let r=await this.getValidAccessToken();if(!r)throw new TB(`please sign in first`,`login_required`);let i=await NB(await fetch(`${cB(this.config.serverUrl)}${sB.accept}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${r}`},body:JSON.stringify({owner:e,code:t,...n?{emailCode:n}:{}})}),`could not join the organization`)??{};if(i.joined!==!0)throw Error(`IAM did not join the organization`);return typeof i.org==`string`&&i.org?i.org:e}async acceptTerms(e){let t=await this.getValidAccessToken();if(!t)throw Error(`No valid access token — user must log in`);let n=this.config.proxyBaseUrl??this.config.serverUrl;await NB(await fetch(`${cB(n)}${sB.terms}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${t}`},body:JSON.stringify({terms:e.terms,aup:e.aup})}),`could not record the acceptance`)}async addAddress(e,t){let n=await this.getValidAccessToken();if(!n)throw new TB(`please sign in first`,`login_required`);let r=this.config.proxyBaseUrl??this.config.serverUrl,i=await NB(await fetch(`${cB(r)}${sB.address}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${n}`},body:JSON.stringify({clientId:this.client,address:e,code:t})}),`could not add the address`)??{};return{email:typeof i.email==`string`?i.email:``,phone:typeof i.phone==`string`?i.phone:``}}async sendLoginCode(e){let t=e.includes(`@`),n=this.config.proxyBaseUrl??this.config.serverUrl;await NB(await fetch(`${cB(n)}${sB.sendCode}`,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`,Accept:`application/json`},body:new URLSearchParams({applicationId:`admin/${(await this.party(this.client)).application}`,dest:e,type:t?`email`:`phone`}).toString()}),`could not send code`)}async signup(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=new URL(`${cB(t)}${sB.signup}`);return n.searchParams.set(`clientId`,this.config.clientId),await NB(await fetch(n.toString(),{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({application:this.config.application??this.config.clientId,clientId:this.config.clientId,organization:this.config.organization,email:e.email,password:e.password,code:e.code,...e.name?{name:e.name}:{},...e.terms?{terms:e.terms.terms,aup:e.terms.aup}:{}})}),`sign-up failed`),this.loginWithPassword(e.email,e.password)}async methods(){let e=new URL(`${cB(this.config.serverUrl)}${sB.authMethods}`);e.searchParams.set(`clientId`,this.client);let t=await NB(await fetch(e.toString(),{headers:{Accept:`application/json`}}),`could not read the sign-in methods`)??{},n=Array.isArray(t.oauth)?t.oauth:[];return{password:t.password===!0,code:t.code===!0,signup:t.signup===!0,wallet:t.web3===!0&&(!Array.isArray(t.web3Chains)||t.web3Chains.includes(uB.chain)),address:t.address===!0,providers:n.filter(e=>typeof e.name==`string`&&typeof e.type==`string`).map(e=>({name:e.name,type:e.type}))}}async identify(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=await NB(await fetch(`${cB(t)}${sB.authIdentifier}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({clientId:this.client,identifier:e})}),`could not look up the address`)??{};return{account:n.account===!0,password:n.password===!0}}async handleCallback(e){let t=new URL(e??window.location.href),n=t.searchParams.get(`error`);if(n)throw this.isOwnAttempt(t.searchParams.get(`state`))?new TB(`OAuth error: ${t.searchParams.get(`error_description`)??n}`,n):new kB(`OAuth error on a sign-in this browser did not start. Restart sign-in.`,`foreign`);let r=t.searchParams.get(`code`);if(!r)throw new kB(`Missing authorization code in callback URL`,`empty`);let i=this.callbackInFlight;if(i&&i.code===r)return i.promise;let a=this.exchangeCode(t,r);return this.callbackInFlight={code:r,promise:a},a.catch(()=>{this.callbackInFlight?.promise===a&&(this.callbackInFlight=null)}),a}isOwnAttempt(e){if(!e)return!1;let t=CB(e);return this.txStorage.getItem(t)??this.storage.getItem(t)?!0:(this.txStorage.getItem(pB)??this.storage.getItem(pB))===e}async exchangeCode(e,t){let n=e.searchParams.get(`state`),r=n?CB(n):null,i=r?this.txStorage.getItem(r)??this.storage.getItem(r):null,a=i?wB(i).codeVerifier:null;if(a&&r)this.txStorage.removeItem(r),this.storage.removeItem(r),(this.txStorage.getItem(pB)===n||this.storage.getItem(pB)===n)&&(this.txStorage.removeItem(pB),this.txStorage.removeItem(mB),this.storage.removeItem(pB),this.storage.removeItem(mB));else{if(n&&this.spent().includes(n))throw new kB(`This sign-in already finished in this browser.`,`spent`);let e=this.txStorage.getItem(pB)??this.storage.getItem(pB);if(!e||n!==e)throw new kB(`OAuth state mismatch — stale, concurrent, or forged login. Restart sign-in.`,`foreign`);if(a=this.txStorage.getItem(mB)??this.storage.getItem(mB),!a)throw Error(`Missing PKCE code verifier — start sign-in via signinRedirect() or the embedded credential login.`);this.txStorage.removeItem(pB),this.txStorage.removeItem(mB),this.storage.removeItem(pB),this.storage.removeItem(mB)}let o=new URLSearchParams({grant_type:`authorization_code`,client_id:this.config.clientId,code:t,redirect_uri:this.config.redirectUri,code_verifier:a}),s=await this.tokenEndpoint(),c=await fetch(s,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:o.toString()});if(!c.ok){let e=await c.text().catch(()=>``);throw Error(`Token exchange failed (${c.status}): ${e}`)}let l=await c.json();return this.storeTokens(l),n&&this.spend(n),PB(l)}spent(){try{let e=JSON.parse(this.txStorage.getItem(bB)??`[]`);return Array.isArray(e)?e.filter(e=>typeof e==`string`):[]}catch{return[]}}spend(e){let t=this.spent().filter(t=>t!==e);t.push(e),this.txStorage.setItem(bB,JSON.stringify(t.slice(-12)))}refreshAccessToken(){return this.refreshing??=jre(this.storage,()=>this.refreshHeld()).finally(()=>{this.refreshing=null}),this.refreshing}async refreshHeld(){let e=this.stored(),t=e.access!==this.held.access||e.refresh!==this.held.refresh;if(e.access&&t&&!this.isTokenExpired()){this.held=e;let t=this.getExpiresAt();return{accessToken:e.access,refreshToken:e.refresh??void 0,idToken:this.getIdToken()??void 0,expiresIn:t===null?void 0:Math.max(0,Math.floor((t-Date.now())/1e3)),tokenType:`Bearer`}}if(!e.refresh)throw this.clearTokens(),new OB(`no refresh token is stored`);let n=await fetch(await this.tokenEndpoint(),{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:new URLSearchParams({grant_type:`refresh_token`,client_id:this.config.clientId,refresh_token:e.refresh}).toString()});if(!n.ok){let t=await n.text().catch(()=>``),{error:r,description:i}=Mre(t);throw r===`invalid_grant`?(this.storage.getItem(gB)===e.refresh&&this.clearTokens(),new OB(i||r)):Error(`Token refresh failed (${n.status}): ${t}`)}let r=await n.json();return this.storeTokens(r),PB(r)}stored(){return{access:this.storage.getItem(hB),refresh:this.storage.getItem(gB)}}async signinPopup(e){let{url:t,state:n}=await this.buildAuthorizeUrl({additionalParams:e?.additionalParams}),r=e?.width??600,i=e?.height??700,a=window.screenX+(window.outerWidth-r)/2,o=window.screenY+(window.outerHeight-i)/2,s=new URL(this.config.redirectUri,window.location.href).origin;return new Promise((c,l)=>{let u=window.open(t.toString(),xre,`width=${r},height=${i},left=${a},top=${o},menubar=no,toolbar=no`);if(!u){l(Error(`Failed to open login popup — blocked by browser?`));return}let d=!1,f=null,p=()=>{if(!d){d=!0,window.removeEventListener(`message`,m),clearInterval(h),clearTimeout(g),f&&clearTimeout(f);try{u.closed||u.close()}catch{}}},m=e=>{if(d||e.origin!==s)return;let t=e.data;if(!t||typeof t!=`object`||t.source!==Sre)return;if(typeof t.state!=`string`||t.state!==n){p(),l(Error(`OAuth state mismatch — possible CSRF (popup)`));return}if(t.error){p(),l(Error(`OAuth error: ${t.error}`));return}if(typeof t.code!=`string`||t.code.length===0){p(),l(Error(`Login popup returned no authorization code`));return}let r=t.code,i=t.state;p();let a=this.config.redirectUri.includes(`?`)?`&`:`?`,o=`${this.config.redirectUri}${a}code=${encodeURIComponent(r)}&state=${encodeURIComponent(i)}`;this.handleCallback(o).then(c,l)};window.addEventListener(`message`,m);let h=setInterval(()=>{d||!u.closed||f||(f=setTimeout(()=>{d||(p(),l(Error(`Login popup was closed before completing`)))},1e3))},300),g=setTimeout(()=>{d||(p(),l(Error(`Login popup timed out`)))},e?.timeoutMs??3e5)})}async loginWithWallet(e){let t=e?.provider??globalThis.ethereum;if(!t||typeof t.request!=`function`)throw Error(`No EIP-1193 wallet provider found (window.ethereum).`);let n=await t.request({method:`eth_requestAccounts`}),r=Array.isArray(n)?n[0]:void 0;if(typeof r!=`string`||!r)throw Error(`Wallet did not return an address`);let i=await dre(r),a=mre(await t.request({method:`eth_chainId`}).catch(()=>void 0)),o=await this.own(),s=cB(this.config.serverUrl),c=new URL(`${s}${sB.web3Nonce}`);c.searchParams.set(`chain`,uB.chain),c.searchParams.set(`address`,i),c.searchParams.set(`clientId`,o.clientId);let l=await NB(await fetch(c.toString(),{headers:{Accept:`application/json`},credentials:`include`}),`could not start the wallet sign-in`);if(!l||typeof l.nonce!=`string`||typeof l.domain!=`string`)throw Error(`IAM did not return a sign-in challenge`);let u=fre(l,i,a),d=await t.request({method:`personal_sign`,params:[pre(u),i]});if(typeof d!=`string`||!d)throw Error(`Wallet did not return a signature`);return this.post({...uB,address:i,message:u,signature:d,clientId:o.clientId,redirectUri:o.redirectUri,scope:o.scope??`openid profile email`,state:o.state,nonce:o.nonce,codeChallenge:o.codeChallenge,codeChallengeMethod:o.codeChallengeMethod},o,`${s}${sB.web3Verify}`)}storeTokens(e){if(this.storage.setItem(hB,e.access_token),e.refresh_token&&this.storage.setItem(gB,e.refresh_token),e.id_token&&this.storage.setItem(_B,e.id_token),e.expires_in){let t=Date.now()+e.expires_in*1e3;this.storage.setItem(vB,String(t))}else{let t=ure(e.access_token).exp;typeof t==`number`&&Number.isFinite(t)&&this.storage.setItem(vB,String(t*1e3))}this.held=this.stored()}getAccessToken(){return this.storage.getItem(hB)}getRefreshToken(){return this.storage.getItem(gB)}getIdToken(){return this.storage.getItem(_B)}getExpiresAt(){let e=this.storage.getItem(vB);if(!e)return null;let t=Number(e);return Number.isFinite(t)?t:null}isTokenExpired(){let e=this.storage.getItem(vB);return e?Date.now()>=Number(e):!1}async getValidAccessToken(){let e=this.getAccessToken();if(e&&!this.isTokenExpired())return e;if(this.getRefreshToken())try{return(await this.refreshAccessToken()).accessToken}catch{return null}return null}clearTokens(){this.storage.removeItem(hB),this.storage.removeItem(gB),this.storage.removeItem(_B),this.storage.removeItem(vB),this.held={access:null,refresh:null}}async logout(){let e=this.storage.getItem(hB),t=this.storage.getItem(gB),n=this.storage.getItem(_B);this.clearTokens();let r=await Promise.race([(async()=>(await this.revoke(t,`refresh_token`,e),await this.revoke(e,`access_token`,e),this.endSessionEndpoint()))(),new Promise(e=>setTimeout(()=>e(lB(this.config.serverUrl,`logout`)),dB))]),i=new URL(r);n&&i.searchParams.set(`id_token_hint`,n),i.searchParams.set(`client_id`,this.config.clientId),this.config.postLogoutRedirectUri&&i.searchParams.set(`post_logout_redirect_uri`,this.config.postLogoutRedirectUri),window.location.href=i.toString()}async end(){let e=this.storage.getItem(hB),t=this.storage.getItem(gB),n=this.storage.getItem(_B);this.clearTokens();let r=this.config.proxyBaseUrl??this.config.serverUrl,i=new URLSearchParams({client_id:this.config.clientId});n&&i.set(`id_token_hint`,n),await Promise.race([(async()=>{await this.revoke(t,`refresh_token`,e,lB(r,`revoke`)),await this.revoke(e,`access_token`,e,lB(r,`revoke`)),await fetch(lB(r,`logout`),{method:`POST`,credentials:`include`,redirect:`manual`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:i.toString()}).catch(()=>void 0)})(),new Promise(e=>setTimeout(e,dB))])}async revoke(e,t,n,r){if(e)try{await fetch(r??await this.revocationEndpoint(),{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/x-www-form-urlencoded`,...n?{Authorization:`Bearer ${n}`}:{}},body:new URLSearchParams({token:e,token_type_hint:t,client_id:this.config.clientId}).toString()})}catch{}}async getUserInfo(){let e=await this.getValidAccessToken();if(!e)throw Error(`No valid access token — user must log in`);let t=await this.userinfoEndpoint(),n=await fetch(t,{headers:{Authorization:`Bearer ${e}`}});if(!n.ok)throw Error(`Userinfo fetch failed (${n.status})`);return await n.json()}async getUser(){if(!await this.getValidAccessToken())return null;let e=await this.getUserInfo();return{sub:e.sub??``,email:e.email,name:e.name,givenName:e.given_name,familyName:e.family_name,phoneNumber:e.phone_number,emailVerified:e.email_verified,picture:e.picture,owner:e.owner}}};function PB(e){return{accessToken:e.access_token,refreshToken:e.refresh_token,idToken:e.id_token,expiresIn:e.expires_in,tokenType:e.token_type,scope:e.scope}}var FB=[{org:`hanzo`,app:`team-native`,issuer:`https://hanzo.id`,title:`Team`,hosts:[`hanzo.team`,`www.hanzo.team`,`hanzo.app`,`localhost`,`127.0.0.1`]},{org:`hanzo`,app:`team2`,issuer:`https://hanzo.id`,title:`Team`,hosts:[`team2.hanzo.ai`,`team2.hanzo.app`,`hanzo-team.hanzo.app`]}],Pre=()=>typeof window>`u`?``:window.location.hostname,IB=FB.find(e=>e.hosts.includes(Pre()))??FB[0],LB=`${IB.org}-${IB.app}`,RB=`https://api.hanzo.ai`,zB={account:`${RB}/v1/team/account`,channels:`${RB}/v1/team/channels`,dms:`${RB}/v1/team/dms`,files:`${RB}/v1/team/files`,plan:`${RB}/v1/team/billing/plan`};`${IB.issuer}${IB.org}${IB.app}`;var BB=`/login`,VB=`/auth/callback`,HB=`openid profile email offline_access`,UB=null,WB=()=>{let e=window.location.origin;return{serverUrl:IB.issuer,clientId:LB,redirectUri:`${e}${VB}`,postLogoutRedirectUri:`${e}${BB}`,scope:HB,proxyBaseUrl:void 0}},GB=()=>UB||(UB=new Nre(WB()),UB),KB=`https://hanzo.ai`,qB=e=>e?{additionalParams:{login_hint:e}}:void 0,JB=(e,t=`login`,n)=>{let r=new URL(e);return t===`another`&&r.searchParams.set(`prompt`,`select_account`),n&&r.searchParams.set(`provider`,n),`${KB}${t===`signup`?`/signup`:`/login`}${r.search}`},YB=e=>{let t=new URL(e);return t.searchParams.set(`prompt`,`none`),`${KB}/v1/iam/oauth/authorize${t.search}`},XB=new Set([`login_required`,`interaction_required`,`consent_required`,`account_selection_required`]),ZB=(e,t)=>e?XB.has(e)?!0:e===`access_denied`&&!!(t&&t.toLowerCase().includes(`no interaction was permitted`)):!1,QB=e=>e===`localhost`||e===`127.0.0.1`||e===`[::1]`,$B=(e,t,n)=>{if(QB(new URL(n).hostname))return`/login?from=logout`;let r=new URLSearchParams({client_id:t,everywhere:`true`,post_logout_redirect_uri:new URL(`/`,n).href});return`${e.replace(/\/+$/,``)}/v1/iam/oauth/logout?${r}`},eV=new Map,tV=new Set,nV=0,rV=()=>{nV++;for(let e of tV)e()},iV=e=>(tV.add(e),()=>void tV.delete(e)),aV=e=>{let t=eV.get(e);return t||(t={phase:`loading`,started:!1},eV.set(e,t)),t},oV=(e,t)=>{let n=aV(e);n.started=!0,t().then(t=>{eV.set(e,{phase:`ready`,data:t,started:!0}),rV()},t=>{eV.set(e,{phase:`failure`,error:sV(t),started:!0}),rV()})},sV=e=>e instanceof Error?e:Error(String(e)),cV=(e,t,n={})=>{let r=n.enabled??!0;(0,V.useSyncExternalStore)(iV,()=>nV,()=>nV);let i=aV(e);r&&!i.started&&oV(e,t);let a=(0,V.useCallback)(()=>{eV.delete(e),oV(e,t),rV()},[e]);return{phase:i.phase,data:i.data,error:i.error,reload:a}},lV=e=>{if(!e)eV.clear();else for(let t of[...eV.keys()])t.startsWith(e)&&eV.delete(t);rV()},uV=(e,t)=>{eV.set(e,{phase:`ready`,data:t,started:!0}),rV()},dV=e=>eV.get(e)?.data,fV=(0,V.createContext)(null),pV=()=>{let e=(0,V.useContext)(fV);if(!e)throw Error(`useSession outside <Session>`);return e},mV=`team.back`,hV=()=>{let e=window.location.pathname+window.location.search;!e.startsWith(`/login`)&&!e.startsWith(`/auth/`)&&sessionStorage.setItem(mV,e)},gV=()=>{let e=sessionStorage.getItem(mV);return sessionStorage.removeItem(mV),e??`/`},_V=`team.silent`,vV=/bot|crawl|spider|slurp|preview|lighthouse|headless/i,yV=()=>{if(navigator.webdriver||vV.test(navigator.userAgent)||QB(window.location.hostname))return!1;try{return!sessionStorage.getItem(_V)}catch{return!1}},bV=()=>{try{sessionStorage.setItem(_V,`1`)}catch{}},xV=6e4,SV=e=>{let t=e instanceof Error?e.message:String(e);return t.includes(`(401)`)||t.includes(`(403)`)},CV=({children:e})=>{let[t,n]=(0,V.useState)(`unknown`),[r,i]=(0,V.useState)(null),a=(0,V.useCallback)(async()=>{try{let e=await GB().getUser();i(e?wV(e):null),n(`in`),lV()}catch(e){if(SV(e)){GB().clearTokens(),i(null),n(`out`),lV();return}i(null),n(`in`),lV()}},[]),o=(0,V.useCallback)(()=>{i(null),n(`out`),lV()},[]),s=(0,V.useRef)(!1);(0,V.useEffect)(()=>{s.current||(s.current=!0,(async()=>{if(!window.location.pathname.startsWith(`/auth/`)){if(new URLSearchParams(window.location.search).get(`from`)===`logout`){bV(),GB().clearTokens(),o();return}if(await GB().getValidAccessToken().catch(()=>null))return a();if(yV()){bV(),hV();try{window.location.replace(YB(await GB().getSigninUrl({additionalParams:{prompt:`none`}})));return}catch{}}o()}})())},[a,o]),(0,V.useEffect)(()=>{if(t===`out`){let e=Date.now(),t=()=>{document.visibilityState!==`visible`||Date.now()-e<15e3||(e=Date.now(),(async()=>{if(await GB().getValidAccessToken().catch(()=>null)){await a();return}if(!(navigator.webdriver||vV.test(navigator.userAgent)||QB(window.location.hostname)))try{let e=Number(sessionStorage.getItem(`team.silent.at`)||`0`);if(Date.now()-e<xV)return;sessionStorage.setItem(`team.silent.at`,String(Date.now())),hV(),window.location.replace(YB(await GB().getSigninUrl({additionalParams:{prompt:`none`}})))}catch{}})())};return document.addEventListener(`visibilitychange`,t),()=>document.removeEventListener(`visibilitychange`,t)}if(t!==`in`)return;let e=Date.now(),n=()=>{document.visibilityState!==`visible`||Date.now()-e<xV||(e=Date.now(),GB().getUserInfo().catch(e=>{SV(e)&&(GB().clearTokens(),o())}))};return document.addEventListener(`visibilitychange`,n),()=>document.removeEventListener(`visibilitychange`,n)},[t,a,o]);let c=(0,V.useCallback)(async(e=`login`,t={})=>{hV();let n=await GB().getSigninUrl(qB(t.hint)),r=t.provider??new URLSearchParams(window.location.search).get(`provider`);window.location.replace(JB(n,e,r))},[]),l=(0,V.useCallback)(e=>(hV(),GB().getSigninUrl(e)),[]),u=(0,V.useCallback)(()=>{let e=GB(),t=e.getAccessToken(),n=e.getRefreshToken();e.clearTokens(),o(),(async()=>{try{let e=async(e,n)=>{e&&await fetch(`/v1/iam/oauth/revoke`,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`,...t?{Authorization:`Bearer ${t}`}:{}},body:new URLSearchParams({token:e,token_type_hint:n,client_id:LB}).toString()}).catch(()=>void 0)};await e(n,`refresh_token`),await e(t,`access_token`)}finally{window.location.assign($B(IB.issuer,LB,window.location.origin))}})()},[o]),d=(0,V.useCallback)(async()=>{let e=gV(),t=new URLSearchParams(window.location.search);if(ZB(t.get(`error`),t.get(`error_description`)))return e;if(!(await GB().handleCallback()).accessToken)throw Error(`the issuer returned no access token`);return await a(),e},[a]),f=(0,V.useMemo)(()=>({standing:t,who:r,depart:c,request:l,leave:u,land:d}),[t,r,c,l,u,d]);return(0,H.jsx)(fV.Provider,{value:f,children:e})},wV=e=>{let t=String(e.preferred_username??e.name??e.sub??``);return{id:String(e.sub??t),name:t,label:String(e.name??e.preferred_username??t),email:typeof e.email==`string`?e.email:void 0,avatar:typeof e.picture==`string`?e.picture:void 0}},TV=class extends Error{status;detail;constructor(e,t){super(t||`HTTP ${e}`),this.status=e,this.detail=t,this.name=`Refused`}},EV=async()=>{let e=await GB().getValidAccessToken().catch(()=>null);return e?{authorization:`Bearer ${e}`}:{}},DV=async(e,t)=>{let n=await fetch(e,{...t,headers:{accept:`application/json`,...t?.body?{"content-type":`application/json`}:{},...await EV(),...t?.headers}}),r=await n.text();if(!n.ok)throw new TV(n.status,kV(r)||n.statusText);if(r)try{return JSON.parse(r)}catch{throw new TV(n.status,`expected JSON, read ${r.length} bytes of ${n.headers.get(`content-type`)??`nothing`}`)}},OV=(e,t)=>DV(e,{method:`POST`,body:JSON.stringify(t)}),kV=e=>{try{let t=JSON.parse(e);return t.detail??t.message??``}catch{return e.slice(0,200)}},AV=class extends Error{code;constructor(e,t){super(t),this.code=e,this.name=`Denied`}get unauthorized(){return this.code.endsWith(`:Unauthorized`)}},jV=async(e,t={})=>{let n=await OV(zB.account,{method:e,params:t});if(n.error)throw new AV(n.error.code,n.error.params?.message??n.error.code);return n.result},MV=()=>jV(`getUserWorkspaces`),NV=e=>jV(`selectWorkspace`,{workspaceUrl:e}),PV=()=>jV(`enrol`),FV={request:0,response:1,push:2},IV=16,LV=16,RV=24,zV=40,BV=0,VV=4,HV=8,UV=16,WV=new TextEncoder,GV=new TextDecoder,KV=e=>{let t=WV.encode(e.method),n=e.payload,r=zV,i=r,a=t.length>0?r-24:0;t.length>0&&(r+=t.length);let o=r,s=n.length>0?r-32:0;n.length>0&&(r+=n.length);let c=new Uint8Array(r),l=new DataView(c.buffer);return c.set(WV.encode(`ZAP\0`),0),l.setUint16(4,2,!0),l.setUint16(6,0,!0),l.setUint32(8,LV,!0),l.setUint32(12,r,!0),l.setUint32(16,e.id,!0),c[20]=e.kind,l.setUint32(24,a,!0),l.setUint32(28,t.length,!0),l.setUint32(32,s,!0),l.setUint32(36,n.length,!0),c.set(t,i),c.set(n,o),c},qV=e=>{if(e.length<IV||GV.decode(e.subarray(0,4))!==`ZAP\0`)return null;let t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=t.getUint32(8,!0);return n<IV||n+RV>e.length?null:{id:t.getUint32(n+BV,!0),kind:e[n+VV],method:GV.decode(JV(e,t,n+HV)),payload:JV(e,t,n+UV).slice()}},JV=(e,t,n)=>{if(n+8>e.length)return new Uint8Array;let r=t.getUint32(n,!0);if(r===0)return new Uint8Array;let i=t.getUint32(n+4,!0),a=n+r;return a<IV||a+i>e.length?new Uint8Array:e.subarray(a,a+i)},YV=(e,t,n,r)=>KV({id:e,kind:t,method:n,payload:WV.encode(JSON.stringify(r))}),XV=e=>GV.decode(e.payload),ZV=e=>{if(e==null)return[];if(Array.isArray(e))return e;let t=e.value;if(Array.isArray(t))return t;throw Error(`findAll answered something that is not a list of documents`)},QV=25e3,$V=[500,1e3,2e3,5e3,1e4,2e4],eH=class{slug;socket=null;next=1;waiting=new Map;listeners=new Set;standings=new Set;beat=null;retry=null;attempt=0;closed=!1;opening=null;standing=`idle`;entry=null;get account(){return this.entry?`hanzo:${this.entry.account}`:null}constructor(e){this.slug=e}watch(e){return this.listeners.add(e),()=>void this.listeners.delete(e)}observe(e){return this.standings.add(e),()=>void this.standings.delete(e)}async open(){if(this.socket?.readyState!==WebSocket.OPEN)return this.opening||=this.connect().finally(()=>{this.opening=null}),this.opening}close(){this.closed=!0,this.stopBeat(),this.retry&&clearTimeout(this.retry),this.socket?.close(),this.socket=null,this.settle(`idle`)}async find(e,t={},n={}){return ZV(await this.call(`findAll`,[e,t,n]))}async one(e,t){return(await this.find(e,t,{limit:1}))[0]}async write(e){await this.call(`tx`,[e])}async call(e,t=[]){await this.open();let n=this.socket;if(!n||n.readyState!==WebSocket.OPEN)throw Error(`the space plane is not open`);let r=this.next++;return new Promise((i,a)=>{this.waiting.set(r,{resolve:i,reject:a}),n.send(YV(r,FV.request,e,{id:r,method:e,params:t}))})}async connect(){this.closed=!1,this.settle(`opening`);let e=await NV(this.slug);this.entry=e,await new Promise((t,n)=>{let r=new WebSocket(`${e.endpoint}/${e.token}`);r.binaryType=`arraybuffer`,this.socket=r,r.onmessage=e=>this.receive(e.data),r.onerror=()=>n(Error(`the space plane refused the connection`)),r.onclose=()=>{this.stopBeat();for(let e of this.waiting.values())e.reject(Error(`the space plane closed`));this.waiting.clear(),!this.closed&&(this.settle(`lost`),this.later())},r.onopen=()=>{this.call(`hello`,[]).then(()=>{this.attempt=0,this.settle(`live`),this.startBeat(),t()}).catch(n)}})}receive(e){if(typeof e==`string`)return;let t=qV(new Uint8Array(e));if(!t)return;let n=XV(t);if(n===`pong!`)return;let r;try{r=JSON.parse(n)}catch{return}if(t.kind===FV.push||r.id===void 0){let e=Array.isArray(r.result)?r.result:[];if(e.length)for(let t of this.listeners)t(e);return}let i=this.waiting.get(r.id);i&&(this.waiting.delete(r.id),r.error?i.reject(Error(String(r.error))):i.resolve(r.result))}startBeat(){this.stopBeat(),this.beat=setInterval(()=>{this.socket?.readyState===WebSocket.OPEN&&this.socket.send(KV({id:0,kind:FV.request,method:``,payload:new TextEncoder().encode(`ping`)}))},QV)}stopBeat(){this.beat&&clearInterval(this.beat),this.beat=null}later(){let e=$V[Math.min(this.attempt++,$V.length-1)];this.retry=setTimeout(()=>void this.open().catch(()=>this.later()),e)}settle(e){this.standing=e;for(let t of this.standings)t(e)}},tH=(0,V.createContext)(null),nH=()=>{let e=(0,V.useContext)(tH);if(!e)throw Error(`useSpace outside <Space>`);return e},rH=`team.space`,iH=`${zB.account}/auth/openid`,aH=({children:e})=>{let{standing:t}=pV(),[n,r]=(0,V.useState)(`unknown`),[i,a]=(0,V.useState)([]),[o,s]=(0,V.useState)(()=>localStorage.getItem(rH)),[c,l]=(0,V.useState)(null),[u,d]=(0,V.useState)(`idle`),[f,p]=(0,V.useState)(null),m=(0,V.useCallback)(e=>{if(p(null),a(e),e.length===0){r(`homeless`);return}s(t=>t&&e.some(e=>e.url===t)?t:e[0].url)},[]),h=(0,V.useCallback)(async()=>{let e=await PV().catch(e=>e);return e instanceof Error?(p(e),!1):(m(e),!0)},[m]),g=(0,V.useRef)(!1),_=(0,V.useRef)(t);(0,V.useEffect)(()=>{_.current!==t&&(g.current=!1,lV()),_.current=t,!(t===`unknown`||g.current)&&(g.current=!0,(async()=>{let e=await(t===`in`?MV():Promise.resolve([])).catch(e=>e);if(t===`in`&&e instanceof AV&&e.unauthorized&&(e=await PV().catch(t=>t instanceof AV&&t.code.endsWith(`:UnknownMethod`)?e:t)),e instanceof Error){p(e),r(e instanceof AV&&e.unauthorized?`stranger`:`refused`);return}m(e)})())},[t,m]),(0,V.useEffect)(()=>{if(!o)return;localStorage.setItem(rH,o);let e=new eH(o);l(e);let t=e.observe(d);return e.open().then(()=>r(`settled`)).catch(e=>{p(e),r(`refused`)}),()=>{t(),e.close()}},[o]),(0,V.useEffect)(()=>{if(c)return c.watch(e=>{for(let t of new Set(e.map(e=>String(e.objectClass??``))))t&&lV(t)})},[c]);let v=(0,V.useCallback)(e=>{lV(),s(e)},[]),y=(0,V.useMemo)(()=>i.find(e=>e.url===o)??null,[i,o]),b=(0,V.useMemo)(()=>({standing:n,all:i,current:y,org:y?.org??null,choose:v,plane:c,connection:u,refusal:f,enrolNow:h,enrolment:iH}),[n,i,y,v,c,u,f,h]);return(0,H.jsx)(tH.Provider,{value:b,children:e})},oH=`team.aside`,sH=`team.aside.kind`,cH=()=>{try{return localStorage.getItem(oH)===`yes`}catch{return!1}},lH=()=>{try{return localStorage.getItem(sH)===`inspector`?`inspector`:`inbox`}catch{return`inbox`}},uH=cH(),dH=lH(),fH=new Set,pH=()=>{for(let e of fH)e()},mH=e=>{if(e!==uH){uH=e;try{localStorage.setItem(oH,e?`yes`:`no`)}catch{}pH()}},hH=e=>{let t=e!==dH;dH=e;try{localStorage.setItem(sH,e)}catch{}uH?t&&pH():mH(!0)},gH=e=>{uH&&dH===e?mH(!1):hH(e)},_H=()=>mH(!1),vH=()=>(0,V.useSyncExternalStore)(e=>(fH.add(e),()=>fH.delete(e)),()=>uH,()=>!1),yH=()=>(0,V.useSyncExternalStore)(e=>(fH.add(e),()=>fH.delete(e)),()=>dH,()=>`inbox`),bH=1120,xH=e=>`var(--team-${e})`,X={ground:xH(`ground`),panel:xH(`panel`),card:xH(`card`),rule:xH(`rule`),bar:xH(`bar`),barRule:xH(`bar-rule`),rail:xH(`rail`),railRule:xH(`rail-rule`),railActive:xH(`rail-active`),railFg:xH(`rail-fg`),railFgActive:xH(`rail-fg-active`),sidebar:xH(`sidebar`),sidebarRule:xH(`sidebar-rule`),rowActive:xH(`row-active`),rowHover:xH(`row-hover`),avatar:xH(`avatar`),avatarInk:xH(`avatar-ink`),composer:xH(`composer`),composerRule:xH(`composer-rule`),composerAccent:xH(`composer-accent`),composerAccentInk:xH(`composer-accent-ink`),composerWarn:xH(`composer-warn`),chatUser:xH(`chat-user`),chatUserInk:xH(`chat-user-ink`),ink:xH(`ink`),mute:xH(`mute`),dim:xH(`dim`),accent:xH(`accent`),alert:xH(`alert`)},SH={backlog:xH(`backlog`),todo:xH(`todo`),doing:xH(`doing`),done:xH(`done`)},CH=6,wH=e=>{let t=e.toLowerCase(),n=0;for(let e=0;e<t.length;e++)n=n*31+t.charCodeAt(e)|0;return Math.abs(n)%CH+1},TH=e=>({background:`var(--team-hue-${wH(e)})`,color:`var(--team-chip-ink)`}),EH=e=>`var(--team-hue-${wH(e)})`,DH=e=>e===1||e===2,OH=e=>DH(e)?{background:`var(--team-urgent)`,color:`var(--team-chip-ink)`}:{background:`var(--team-quiet)`,color:X.ink},Z={title:`$7`,row:`$4`,body:`$3`,small:`$2`,chip:`$1`,figure:`$7`},kH={tight:`$2`,inset:`$3`,wide:`$4`,edge:`$5`},Q={card:`$1`,panel:`$1`,field:`$1`,pill:`$10`},AH={textTransform:`uppercase`,letterSpacing:.08},jH={outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},MH=[`all`,`task`,`chat`],NH=(e,t)=>t===`all`?[...e]:e.filter(e=>e.kind===t),PH=(e,t)=>e.reduce((e,n)=>e+ +(n.kind===t&&!n.seen),0),FH=(e,t)=>e.map(e=>e.id===t?{...e,seen:!0}:e),IH=`inbox`,LH={list:()=>Promise.resolve([]),see:()=>Promise.resolve()},RH=e=>{LH=e,lV(IH)},zH=()=>cV(IH,()=>LH.list()),BH=()=>(zH().data??[]).reduce((e,t)=>e+ +!t.seen,0),VH=e=>{let t=dV(IH),n=t?.find(t=>t.id===e);t&&n&&!n.seen&&(uV(IH,FH(t,e)),LH.see(e).catch(()=>uV(IH,t)))},HH=()=>{let e=dV(IH);if(!e)return;let t=e.filter(e=>!e.seen);if(t.length!==0){uV(IH,e.map(e=>e.seen?e:{...e,seen:!0}));for(let e of t)LH.see(e.id).catch(()=>{})}},UH=`<svg role="img" aria-label="Hanzo" viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
38
|
+
<!-- Origami fold-in → hover: one 3-D turn → press: squash. Pure CSS, no JS. Canonical 7-path shaded H. -->
|
|
39
|
+
|
|
40
|
+
<style>.o{fill:#fff;opacity:0;transform-box:fill-box;transform-origin:left center;animation:fold 0.42s cubic-bezier(.16,1,.3,1) forwards}
|
|
41
|
+
.s{fill:#ddd}
|
|
42
|
+
@keyframes fold{from{opacity:0;transform:perspective(320px) rotateY(90deg)}to{opacity:1;transform:none}}
|
|
43
|
+
.o0{animation-delay:0.00s}.o1{animation-delay:0.06s}.o2{animation-delay:0.12s}.o3{animation-delay:0.18s}.o4{animation-delay:0.24s}
|
|
44
|
+
/* interaction — pure CSS, no JS: hover = one graceful turn (returns to rest), press = squash */
|
|
45
|
+
.hanzo-hov{transform-box:view-box;transform-origin:33.5px 33.5px}
|
|
46
|
+
.hanzo-prs{transform-box:view-box;transform-origin:33.5px 33.5px;transition:transform .22s cubic-bezier(.22,1,.36,1)}
|
|
47
|
+
svg:hover .hanzo-hov{animation:hanzoTurn 0.85s cubic-bezier(.45,0,.2,1)}
|
|
48
|
+
svg:active .hanzo-prs{transform:scale(.92)}
|
|
49
|
+
@keyframes hanzoTurn{0%{transform:perspective(300px) rotateY(0)}100%{transform:perspective(300px) rotateY(360deg)}}
|
|
50
|
+
@media (prefers-reduced-motion:reduce){.hanzo-hov,.hanzo-prs{animation:none!important;transform:none!important}.o{opacity:1;animation:none;transform:none}}
|
|
51
|
+
</style>
|
|
52
|
+
<g class="hanzo-hov"><g class="hanzo-prs">
|
|
53
|
+
<path class="o o0" d="M22.21 0H0V22.3184H22.21V0Z"/>
|
|
54
|
+
<path class="o o1" d="M66.7198 0H44.5098V22.3184H66.7198V0Z"/>
|
|
55
|
+
<path class="o o1 s" d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z"/>
|
|
56
|
+
<path class="o o2" d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z"/>
|
|
57
|
+
<path class="o o3" d="M22.21 67V44.6369H0V67H22.21Z"/>
|
|
58
|
+
<path class="o o3 s" d="M0 44.6369L22.21 46.8285V44.6369H0Z"/>
|
|
59
|
+
<path class="o o4" d="M66.7198 67V44.6369H44.5098V67H66.7198Z"/>
|
|
60
|
+
</g></g>
|
|
61
|
+
</svg>`;function WH(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
62
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#ffffff"/>
|
|
63
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#DDDDDD"/>
|
|
64
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#ffffff"/>
|
|
65
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#ffffff"/>
|
|
66
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#ffffff"/>
|
|
67
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#DDDDDD"/>
|
|
68
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#ffffff"/>
|
|
69
|
+
</svg>`}function GH(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
70
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#000000"/>
|
|
71
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#222222"/>
|
|
72
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#000000"/>
|
|
73
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#000000"/>
|
|
74
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#000000"/>
|
|
75
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#222222"/>
|
|
76
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#000000"/>
|
|
77
|
+
</svg>`}function KH(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
78
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#ffffff"/>
|
|
79
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#DDDDDD"/>
|
|
80
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#ffffff"/>
|
|
81
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#ffffff"/>
|
|
82
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#ffffff"/>
|
|
83
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#DDDDDD"/>
|
|
84
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#ffffff"/>
|
|
85
|
+
</svg>`}function qH(){return`<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg">
|
|
86
|
+
<rect width="64" height="64" rx="8" fill="#000000"/>
|
|
87
|
+
<g transform="translate(8, 8) scale(0.716)">
|
|
88
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#ffffff"/>
|
|
89
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#ffffff"/>
|
|
90
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#ffffff"/>
|
|
91
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#ffffff"/>
|
|
92
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#ffffff"/>
|
|
93
|
+
</g>
|
|
94
|
+
</svg>`}function JH(e={}){let{variant:t=`color`}=e,n=``;switch(t){case`mono`:n=GH();break;case`white`:n=KH();break;case`favicon`:n=qH();break;default:n=WH()}return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(n)))}`}JH(),JH({variant:`mono`}),JH({variant:`white`}),JH({variant:`favicon`});function YH(){return`data:image/svg+xml;base64,`+btoa(unescape(encodeURIComponent(UH)))}YH();var XH=32;function ZH(e){let t=new Uint8Array(e);return crypto.getRandomValues(t),$H(t.buffer)}async function QH(e){let t=new TextEncoder;return crypto.subtle.digest(`SHA-256`,t.encode(e))}function $H(e){let t=new Uint8Array(e),n=``;for(let e of t)n+=String.fromCharCode(e);return btoa(n).replace(/\+/g,`-`).replace(/\//g,`_`).replace(/=+$/,``)}async function eU(){let e=ZH(XH);return{codeVerifier:e,codeChallenge:$H(await QH(e))}}function tU(){return ZH(XH)}var nU={discovery:`/.well-known/openid-configuration`,authorize:`/v1/iam/oauth/authorize`,token:`/v1/iam/oauth/token`,userinfo:`/v1/iam/oauth/userinfo`,jwks:`/v1/iam/.well-known/jwks`,logout:`/v1/iam/oauth/logout`,revoke:`/v1/iam/oauth/revoke`},rU={authMethods:`/v1/iam/auth/methods`,authIdentifier:`/v1/iam/auth/identifier`,authApplication:`/v1/iam/auth/application`,onboarding:`/v1/iam/onboarding`,login:`/v1/iam/login`,sendCode:`/v1/iam/verification-codes`,federationMfa:`/v1/iam/oauth/federation/mfa`,signup:`/v1/iam/signup`,terms:`/v1/iam/terms`,password:`/v1/iam/password`,address:`/v1/iam/address`,accept:`/v1/iam/invitations/accept`,web3Nonce:`/v1/iam/web3/nonce`,web3Verify:`/v1/iam/web3/verify`};function iU(e){return e.replace(/\/+$/,``)}function aU(e,t){return`${iU(e)}${nU[t]}`}function oU(e){let t=new URL(e.endpoint??aU(e.serverUrl,`authorize`));t.searchParams.set(`client_id`,e.clientId),t.searchParams.set(`response_type`,`code`),t.searchParams.set(`redirect_uri`,e.redirectUri),t.searchParams.set(`scope`,e.scope??`openid profile email`),t.searchParams.set(`state`,e.state),e.codeChallenge&&(t.searchParams.set(`code_challenge`,e.codeChallenge),t.searchParams.set(`code_challenge_method`,`S256`)),e.prompt&&t.searchParams.set(`prompt`,e.prompt);for(let[n,r]of Object.entries(e.params??{}))t.searchParams.set(n,r);return t}function sU(e){if(!e)return{};try{let t=e.split(`.`)[1];return t?JSON.parse(atob(t.replace(/-/g,`+`).replace(/_/g,`/`))):{}}catch{return{}}}function cU(e){let t=sU(e),n=Array.isArray(t.orgs)?t.orgs:[],r=[],i={};for(let e of n)e&&typeof e.org==`string`&&e.org!==``&&(r.includes(e.org)||r.push(e.org),typeof e.role==`string`&&e.role!==``&&(i[e.org]=e.role));return{organizations:r,roles:i}}function lU(e){let t=e.trim(),n=t.includes(`/`)?t.slice(t.lastIndexOf(`/`)+1):t;return/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(n)||/^[0-9a-f]{24,}$/i.test(n)||/^[0-9]{10,}$/.test(n)?!0:/^[a-z0-9]{20,}$/i.test(n)&&!/[aeiou]{1}/i.test(n.slice(0,6))}function uU(e,t){let n=e??{},r=(...e)=>{for(let r of e){let e=n[r]??t[r];if(typeof e==`string`&&e.trim()!==``)return e.trim()}return null},i=(...e)=>{for(let r of e){let e=n[r]??t[r];if(typeof e==`string`&&e.trim()!==``&&!lU(e))return e.trim()}return null},a=r(`email`),o=i(`displayName`,`name`,`preferred_username`,`given_name`,`firstName`)??(a?a.split(`@`)[0]:null);if(o==null)return null;let s=o.split(/[\s._-]+/).filter(Boolean).slice(0,2).map(e=>e[0]?.toUpperCase()??``).join(``)||o.slice(0,2).toUpperCase();return{name:o,email:a,avatarUrl:r(`avatar`,`picture`,`avatarUrl`),initials:s}}var dU={chain:`evm`,scheme:`secp256k1-eip191`};async function fU(e){let t=e.trim().toLowerCase().replace(/^0x/,``);if(!/^[0-9a-f]{40}$/.test(t))throw Error(`not an Ethereum address: ${e}`);let{keccak_256:n}=await Le(async()=>{let{keccak_256:e}=await import(`./sha3-DDKddPFc.js`);return{keccak_256:e}},[]),r=n(new TextEncoder().encode(t)),i=`0x`;for(let e=0;e<t.length;e++){let n=e%2==0?r[e>>1]>>4:r[e>>1]&15;i+=n>=8?t[e].toUpperCase():t[e]}return i}function pU(e,t,n){let{domain:r,uri:i,statement:a,nonce:o,issuedAt:s,expirationTime:c,version:l}=e;if(a?.includes(`
|
|
95
|
+
`))throw Error(`the sign-in statement must be one line`);let u=[`${r} wants you to sign in with your Ethereum account:`,t,``];return a&&u.push(a,``),u.push(`URI: ${i}`,`Version: ${l||`1`}`,`Chain ID: ${n}`,`Nonce: ${o}`,`Issued At: ${s}`),c&&u.push(`Expiration Time: ${c}`),u.join(`
|
|
96
|
+
`)}function mU(e){let t=`0x`;for(let n of new TextEncoder().encode(e))t+=n.toString(16).padStart(2,`0`);return t}function hU(e){let t=typeof e==`string`?Number.parseInt(e,16):typeof e==`number`?e:NaN;return Number.isSafeInteger(t)&&t>0?t:1}var gU=1500,_U=`hanzo_iam_`,vU=`${_U}state`,yU=`${_U}code_verifier`,bU=`${_U}access_token`,xU=`${_U}refresh_token`,SU=`${_U}id_token`,CU=`${_U}expires_at`,wU=`${_U}hold`,TU=`${_U}spent`,EU=`${_U}refresh`,DU=`${_U}refresh_lease`,OU=3e4,kU=50,AU=50,jU=`${yU}:`;function MU(e){return`${jU}${e}`}var NU=12;function PU(e,t){return`${t}.${e}`}function FU(e){let t=e.indexOf(`.`);if(t>0){let n=e.slice(0,t);if(/^\d+$/.test(n))return{issuedAt:Number(n),codeVerifier:e.slice(t+1)}}return{issuedAt:0,codeVerifier:e}}var IU=`hanzo_iam_login`,LU=`hanzo-iam`;function RU(e,t){let n=new URLSearchParams({code:t});e.state&&n.set(`state`,e.state);let r=e.redirectUri.includes(`?`)?`&`:`?`;return`${e.redirectUri}${r}${n.toString()}`}var zU=9e5,BU=class extends Error{constructor(e,t){super(e),this.code=t,this.name=`Refused`}code},VU=class extends Error{constructor(e,t=[],n){super(`this account signs in with a second factor`),this.directive=e,this.factors=t,this.request=n,this.name=`SecondFactor`}directive;factors;request},HU=class extends Error{constructor(e,t){super(`confirm the account's email address to finish signing in`),this.email=e,this.request=t,this.name=`EmailRequired`}email;request};function UU(e){return`recovery`in e?{recoveryCode:e.recovery}:{mfaType:e.type,passcode:e.passcode}}function WU(e){if(!Array.isArray(e))return[];let t=e.flatMap(e=>{let t=e??{};return typeof t.mfaType!=`string`||!t.mfaType?[]:[{type:t.mfaType,preferred:t.isPreferred===!0,remember:typeof t.mfaRememberInHours==`number`?t.mfaRememberInHours:0}]}),n=``;for(let e of t)(e.type===`email`||e.type===`sms`)&&(n===``||e.preferred)&&(n=e.type);return t.map(({type:e,remember:t})=>({type:e,sent:e===n,remember:t}))}var GU=class extends Error{constructor(){super(`no account holds this address; accept the terms to create one`),this.name=`SignupRequired`}},KU=class extends Error{constructor(e){super(`the session has ended: ${e}`),this.reason=e,this.name=`SessionEnded`}reason},qU=class extends Error{constructor(e,t){super(e),this.reason=t,this.name=`Unmatched`}reason};function JU(e){try{let t=e(),n=`${_U}probe`;return t.setItem(n,`1`),t.removeItem(n),t}catch{return null}}function YU(){return JU(()=>localStorage)??JU(()=>sessionStorage)}function XU(){let e=new Map;return{get length(){return e.size},clear:()=>e.clear(),getItem:t=>e.has(t)?e.get(t):null,key:t=>Array.from(e.keys())[t]??null,removeItem:t=>{e.delete(t)},setItem:(t,n)=>{e.set(t,String(n))}}}var ZU=e=>new Promise(t=>setTimeout(t,e));function QU(){try{return typeof navigator<`u`&&navigator.locks?navigator.locks:null}catch{return null}}async function $U(e,t){let n=QU();if(n)return n.request(EU,t);let r=tU(),i=()=>e.getItem(DU)?.startsWith(`${r}.`)===!0;for(;;){let t=e.getItem(DU);if((t?Number(t.slice(t.indexOf(`.`)+1)):0)>Date.now()){await ZU(AU);continue}if(e.setItem(DU,`${r}.${Date.now()+OU}`),await ZU(kU),i())break}try{return await t()}finally{i()&&e.removeItem(DU)}}function eW(e){try{let t=JSON.parse(e);return{error:typeof t.error==`string`?t.error:``,description:typeof t.error_description==`string`?t.error_description:``}}catch{return{error:``,description:``}}}async function tW(e,t){let n=await e.json().catch(()=>({}));if(!e.ok||n.status===`error`)throw new BU(typeof n.msg==`string`&&n.msg?n.msg:`${t} (${e.status})`,typeof n.code==`string`?n.code:``);return n}async function nW(e,t){return(await tW(e,t)).data}var rW=class{config;storage;txStorage;redeemable;discoveryCache=null;callbackInFlight=null;held;refreshing=null;constructor(e){this.config=e;let t=YU();this.storage=e.storage??t??XU(),this.txStorage=t??this.storage,this.redeemable=t!==null||e.storage!==void 0,this.held=this.stored()}async getDiscovery(){if(this.discoveryCache)return this.discoveryCache;let e=iU(this.config.serverUrl);try{let t=await fetch(`${e}${nU.discovery}`,{headers:{Accept:`application/json`}});if(t.ok)return this.discoveryCache=await t.json(),this.discoveryCache}catch{}return this.discoveryCache={issuer:e,authorization_endpoint:aU(e,`authorize`),token_endpoint:aU(e,`token`),userinfo_endpoint:aU(e,`userinfo`),jwks_uri:aU(e,`jwks`),revocation_endpoint:aU(e,`revoke`),end_session_endpoint:aU(e,`logout`),response_types_supported:[`code`],grant_types_supported:[`authorization_code`,`refresh_token`],scopes_supported:[`openid`,`email`,`profile`]},this.discoveryCache}async tokenEndpoint(){return this.config.proxyBaseUrl?aU(this.config.proxyBaseUrl,`token`):(await this.getDiscovery()).token_endpoint}async userinfoEndpoint(){return this.config.proxyBaseUrl?aU(this.config.proxyBaseUrl,`userinfo`):(await this.getDiscovery()).userinfo_endpoint}async revocationEndpoint(){return this.config.proxyBaseUrl?aU(this.config.proxyBaseUrl,`revoke`):(await this.getDiscovery()).revocation_endpoint??aU(this.config.serverUrl,`revoke`)}async endSessionEndpoint(){return this.config.proxyBaseUrl?aU(this.config.proxyBaseUrl,`logout`):(await this.getDiscovery()).end_session_endpoint??aU(this.config.serverUrl,`logout`)}stashPkce(e,t){this.sweepStaleVerifiers(),this.txStorage.setItem(MU(e),PU(t,Date.now())),this.txStorage.setItem(vU,e),this.txStorage.setItem(yU,t)}sweepStaleVerifiers(){let e=[];for(let t=this.txStorage.length-1;t>=0;t--){let n=this.txStorage.key(t);if(!n||!n.startsWith(jU))continue;let r=this.txStorage.getItem(n);e.push({key:n,issuedAt:r?FU(r).issuedAt:0})}e.sort((e,t)=>t.issuedAt-e.issuedAt);for(let t of e.slice(NU-1))this.txStorage.removeItem(t.key)}async buildAuthorizeUrl(e){if(!this.redeemable)throw Error(`@hanzo/iam: this browser keeps neither localStorage nor sessionStorage, so the PKCE verifier cannot outlive the redirect to IAM and the callback would fail. Call usableStorage() before starting a login to catch this on the page.`);let t=await this.getDiscovery(),{codeVerifier:n,codeChallenge:r}=await eU(),i=tU();return this.stashPkce(i,n),{url:oU({endpoint:t.authorization_endpoint,serverUrl:this.config.serverUrl,clientId:this.config.clientId,redirectUri:this.config.redirectUri,state:i,scope:this.config.scope,codeChallenge:r,prompt:e?.prompt,params:e?.additionalParams}),codeVerifier:n,state:i}}async signinRedirect(e){let{url:t}=await this.buildAuthorizeUrl(e);window.location.replace(t.toString())}async getSigninUrl(e){let{url:t}=await this.buildAuthorizeUrl(e);return t.toString()}asking=null;parties=new Map;ask(e){this.asking=e&&e.state?{...e,state:e.state}:null}get client(){return this.asking?.clientId??this.config.clientId}async party(e){if(e===this.config.clientId)return{application:this.config.application??this.config.clientId,organization:this.config.organization};let t=this.parties.get(e);if(t)return t;let n=new URL(`${iU(this.config.serverUrl)}${rU.authApplication}`);n.searchParams.set(`clientId`,e);let r=await nW(await fetch(n.toString(),{headers:{Accept:`application/json`}}),`could not read the application`)??{};if(typeof r.organization!=`string`||!r.organization)throw Error(`IAM did not name the application's organization`);let i={application:typeof r.name==`string`&&r.name?r.name:e,organization:r.organization};return this.parties.set(e,i),i}async own(){return this.asking??await this.mine()}async mine(){let{codeVerifier:e,codeChallenge:t}=await eU(),n=tU();return this.stashPkce(n,e),{clientId:this.config.clientId,redirectUri:this.config.redirectUri,scope:this.config.scope,state:n,codeChallenge:t,codeChallengeMethod:`S256`}}async credentialLogin(e){return this.post(e,await this.own())}async post(e,t,n){let r=this.config.proxyBaseUrl??this.config.serverUrl,i=new URL(n??`${iU(r)}${rU.login}`);i.searchParams.set(`clientId`,t.clientId),i.searchParams.set(`responseType`,`code`),i.searchParams.set(`redirectUri`,t.redirectUri),i.searchParams.set(`scope`,t.scope??`openid profile email`),t.state&&i.searchParams.set(`state`,t.state),t.nonce&&i.searchParams.set(`nonce`,t.nonce),t.prompt&&i.searchParams.set(`prompt`,t.prompt),t.loginHint&&i.searchParams.set(`login_hint`,t.loginHint),i.searchParams.set(`type`,`code`),t.codeChallenge&&(i.searchParams.set(`code_challenge`,t.codeChallenge),i.searchParams.set(`code_challenge_method`,t.codeChallengeMethod??`S256`));let a=await fetch(i.toString(),{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},credentials:`include`,body:JSON.stringify({type:`code`,...await this.party(t.clientId),autoSignin:!0,...e})}),o;try{o=await tW(a,`sign-in failed`)}catch(e){throw e instanceof BU&&e.code===`login_required`&&this.release(),e}let s=o.data;if(s===`NextMfa`||s===`RequiredMfa`)throw s===`NextMfa`&&this.hold(),new VU(s,WU(o.data2),t);if(s===`RequiredEmail`){this.hold();let e=o.data2??{};throw new HU(typeof e.email==`string`?e.email:``,t)}if(s===`SignupRequired`)throw new GU;if(typeof s!=`string`||s.length===0)throw Error(`IAM did not return an authorization code`);return this.release(),RU(t,s)}hold(){this.txStorage.setItem(wU,String(Date.now()+zU))}release(){this.txStorage.removeItem(wU)}holding(){return Number(this.txStorage.getItem(wU)??0)>Date.now()}async resume(e){if(this.holding())return null;try{return await this.credentialLogin(e?{loginHint:e}:{})}catch{return null}}loginWithPassword(e,t){return this.credentialLogin({username:e,password:t,signinMethod:`Password`})}loginWithCode(e,t){let n=e.includes(`@`);return this.credentialLogin({username:e,code:t,signinMethod:`Verification code`,...n?{email:e}:{phone:e}})}createAccountWithCode(e,t,n){return this.credentialLogin({username:e,code:t,signinMethod:`Verification code`,email:e,create:!0,terms:n.terms,aup:n.aup})}async verifyFactor(e,t,n=!1){if(!e.request)throw Error(`this second factor names no sign-in to finish`);try{return await this.post({...UU(t),enableMfaRemember:n},e.request)}catch(e){throw e instanceof BU&&this.release(),e}}async finishFederation(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=(await tW(await fetch(`${iU(t)}${rU.federationMfa}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},credentials:`include`,body:JSON.stringify(UU(e))}),`the sign-in could not be finished`)).data;if(typeof n!=`string`||!n)throw Error(`IAM did not say where the sign-in goes`);return n}confirmEmail(e,t){return this.post({passcode:t},e.request)}async changeEmail(e,t){try{await this.post({email:t},e.request)}catch(e){if(e instanceof HU)return e;throw e}throw Error(`IAM granted the sign-in without confirming the address`)}async resetPassword(e,t,n){await nW(await fetch(`${iU(this.config.serverUrl)}${rU.password}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({organization:this.config.organization,username:e,code:t,password:n})}),`could not set the password`)}async acceptInvite(e,t,n){let r=await this.getValidAccessToken();if(!r)throw new BU(`please sign in first`,`login_required`);let i=await nW(await fetch(`${iU(this.config.serverUrl)}${rU.accept}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${r}`},body:JSON.stringify({owner:e,code:t,...n?{emailCode:n}:{}})}),`could not join the organization`)??{};if(i.joined!==!0)throw Error(`IAM did not join the organization`);return typeof i.org==`string`&&i.org?i.org:e}async acceptTerms(e){let t=await this.getValidAccessToken();if(!t)throw Error(`No valid access token — user must log in`);let n=this.config.proxyBaseUrl??this.config.serverUrl;await nW(await fetch(`${iU(n)}${rU.terms}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${t}`},body:JSON.stringify({terms:e.terms,aup:e.aup})}),`could not record the acceptance`)}async addAddress(e,t){let n=await this.getValidAccessToken();if(!n)throw new BU(`please sign in first`,`login_required`);let r=this.config.proxyBaseUrl??this.config.serverUrl,i=await nW(await fetch(`${iU(r)}${rU.address}`,{method:`PUT`,headers:{"Content-Type":`application/json`,Accept:`application/json`,Authorization:`Bearer ${n}`},body:JSON.stringify({clientId:this.client,address:e,code:t})}),`could not add the address`)??{};return{email:typeof i.email==`string`?i.email:``,phone:typeof i.phone==`string`?i.phone:``}}async sendLoginCode(e){let t=e.includes(`@`),n=this.config.proxyBaseUrl??this.config.serverUrl;await nW(await fetch(`${iU(n)}${rU.sendCode}`,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`,Accept:`application/json`},body:new URLSearchParams({applicationId:`admin/${(await this.party(this.client)).application}`,dest:e,type:t?`email`:`phone`}).toString()}),`could not send code`)}async signup(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=new URL(`${iU(t)}${rU.signup}`);return n.searchParams.set(`clientId`,this.config.clientId),await nW(await fetch(n.toString(),{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({application:this.config.application??this.config.clientId,clientId:this.config.clientId,organization:this.config.organization,email:e.email,password:e.password,code:e.code,...e.name?{name:e.name}:{},...e.terms?{terms:e.terms.terms,aup:e.terms.aup}:{}})}),`sign-up failed`),this.loginWithPassword(e.email,e.password)}async methods(){let e=new URL(`${iU(this.config.serverUrl)}${rU.authMethods}`);e.searchParams.set(`clientId`,this.client);let t=await nW(await fetch(e.toString(),{headers:{Accept:`application/json`}}),`could not read the sign-in methods`)??{},n=Array.isArray(t.oauth)?t.oauth:[];return{password:t.password===!0,code:t.code===!0,signup:t.signup===!0,wallet:t.web3===!0&&(!Array.isArray(t.web3Chains)||t.web3Chains.includes(dU.chain)),address:t.address===!0,providers:n.filter(e=>typeof e.name==`string`&&typeof e.type==`string`).map(e=>({name:e.name,type:e.type}))}}async identify(e){let t=this.config.proxyBaseUrl??this.config.serverUrl,n=await nW(await fetch(`${iU(t)}${rU.authIdentifier}`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({clientId:this.client,identifier:e})}),`could not look up the address`)??{};return{account:n.account===!0,password:n.password===!0}}async handleCallback(e){let t=new URL(e??window.location.href),n=t.searchParams.get(`error`);if(n)throw this.isOwnAttempt(t.searchParams.get(`state`))?new BU(`OAuth error: ${t.searchParams.get(`error_description`)??n}`,n):new qU(`OAuth error on a sign-in this browser did not start. Restart sign-in.`,`foreign`);let r=t.searchParams.get(`code`);if(!r)throw new qU(`Missing authorization code in callback URL`,`empty`);let i=this.callbackInFlight;if(i&&i.code===r)return i.promise;let a=this.exchangeCode(t,r);return this.callbackInFlight={code:r,promise:a},a.catch(()=>{this.callbackInFlight?.promise===a&&(this.callbackInFlight=null)}),a}isOwnAttempt(e){if(!e)return!1;let t=MU(e);return this.txStorage.getItem(t)??this.storage.getItem(t)?!0:(this.txStorage.getItem(vU)??this.storage.getItem(vU))===e}async exchangeCode(e,t){let n=e.searchParams.get(`state`),r=n?MU(n):null,i=r?this.txStorage.getItem(r)??this.storage.getItem(r):null,a=i?FU(i).codeVerifier:null;if(a&&r)this.txStorage.removeItem(r),this.storage.removeItem(r),(this.txStorage.getItem(vU)===n||this.storage.getItem(vU)===n)&&(this.txStorage.removeItem(vU),this.txStorage.removeItem(yU),this.storage.removeItem(vU),this.storage.removeItem(yU));else{if(n&&this.spent().includes(n))throw new qU(`This sign-in already finished in this browser.`,`spent`);let e=this.txStorage.getItem(vU)??this.storage.getItem(vU);if(!e||n!==e)throw new qU(`OAuth state mismatch — stale, concurrent, or forged login. Restart sign-in.`,`foreign`);if(a=this.txStorage.getItem(yU)??this.storage.getItem(yU),!a)throw Error(`Missing PKCE code verifier — start sign-in via signinRedirect() or the embedded credential login.`);this.txStorage.removeItem(vU),this.txStorage.removeItem(yU),this.storage.removeItem(vU),this.storage.removeItem(yU)}let o=new URLSearchParams({grant_type:`authorization_code`,client_id:this.config.clientId,code:t,redirect_uri:this.config.redirectUri,code_verifier:a}),s=await this.tokenEndpoint(),c=await fetch(s,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:o.toString()});if(!c.ok){let e=await c.text().catch(()=>``);throw Error(`Token exchange failed (${c.status}): ${e}`)}let l=await c.json();return this.storeTokens(l),n&&this.spend(n),iW(l)}spent(){try{let e=JSON.parse(this.txStorage.getItem(TU)??`[]`);return Array.isArray(e)?e.filter(e=>typeof e==`string`):[]}catch{return[]}}spend(e){let t=this.spent().filter(t=>t!==e);t.push(e),this.txStorage.setItem(TU,JSON.stringify(t.slice(-12)))}refreshAccessToken(){return this.refreshing??=$U(this.storage,()=>this.refreshHeld()).finally(()=>{this.refreshing=null}),this.refreshing}async refreshHeld(){let e=this.stored(),t=e.access!==this.held.access||e.refresh!==this.held.refresh;if(e.access&&t&&!this.isTokenExpired()){this.held=e;let t=this.getExpiresAt();return{accessToken:e.access,refreshToken:e.refresh??void 0,idToken:this.getIdToken()??void 0,expiresIn:t===null?void 0:Math.max(0,Math.floor((t-Date.now())/1e3)),tokenType:`Bearer`}}if(!e.refresh)throw this.clearTokens(),new KU(`no refresh token is stored`);let n=await fetch(await this.tokenEndpoint(),{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:new URLSearchParams({grant_type:`refresh_token`,client_id:this.config.clientId,refresh_token:e.refresh}).toString()});if(!n.ok){let t=await n.text().catch(()=>``),{error:r,description:i}=eW(t);throw r===`invalid_grant`?(this.storage.getItem(xU)===e.refresh&&this.clearTokens(),new KU(i||r)):Error(`Token refresh failed (${n.status}): ${t}`)}let r=await n.json();return this.storeTokens(r),iW(r)}stored(){return{access:this.storage.getItem(bU),refresh:this.storage.getItem(xU)}}async signinPopup(e){let{url:t,state:n}=await this.buildAuthorizeUrl({additionalParams:e?.additionalParams}),r=e?.width??600,i=e?.height??700,a=window.screenX+(window.outerWidth-r)/2,o=window.screenY+(window.outerHeight-i)/2,s=new URL(this.config.redirectUri,window.location.href).origin;return new Promise((c,l)=>{let u=window.open(t.toString(),IU,`width=${r},height=${i},left=${a},top=${o},menubar=no,toolbar=no`);if(!u){l(Error(`Failed to open login popup — blocked by browser?`));return}let d=!1,f=null,p=()=>{if(!d){d=!0,window.removeEventListener(`message`,m),clearInterval(h),clearTimeout(g),f&&clearTimeout(f);try{u.closed||u.close()}catch{}}},m=e=>{if(d||e.origin!==s)return;let t=e.data;if(!t||typeof t!=`object`||t.source!==LU)return;if(typeof t.state!=`string`||t.state!==n){p(),l(Error(`OAuth state mismatch — possible CSRF (popup)`));return}if(t.error){p(),l(Error(`OAuth error: ${t.error}`));return}if(typeof t.code!=`string`||t.code.length===0){p(),l(Error(`Login popup returned no authorization code`));return}let r=t.code,i=t.state;p();let a=this.config.redirectUri.includes(`?`)?`&`:`?`,o=`${this.config.redirectUri}${a}code=${encodeURIComponent(r)}&state=${encodeURIComponent(i)}`;this.handleCallback(o).then(c,l)};window.addEventListener(`message`,m);let h=setInterval(()=>{d||!u.closed||f||(f=setTimeout(()=>{d||(p(),l(Error(`Login popup was closed before completing`)))},1e3))},300),g=setTimeout(()=>{d||(p(),l(Error(`Login popup timed out`)))},e?.timeoutMs??3e5)})}async loginWithWallet(e){let t=e?.provider??globalThis.ethereum;if(!t||typeof t.request!=`function`)throw Error(`No EIP-1193 wallet provider found (window.ethereum).`);let n=await t.request({method:`eth_requestAccounts`}),r=Array.isArray(n)?n[0]:void 0;if(typeof r!=`string`||!r)throw Error(`Wallet did not return an address`);let i=await fU(r),a=hU(await t.request({method:`eth_chainId`}).catch(()=>void 0)),o=await this.own(),s=iU(this.config.serverUrl),c=new URL(`${s}${rU.web3Nonce}`);c.searchParams.set(`chain`,dU.chain),c.searchParams.set(`address`,i),c.searchParams.set(`clientId`,o.clientId);let l=await nW(await fetch(c.toString(),{headers:{Accept:`application/json`},credentials:`include`}),`could not start the wallet sign-in`);if(!l||typeof l.nonce!=`string`||typeof l.domain!=`string`)throw Error(`IAM did not return a sign-in challenge`);let u=pU(l,i,a),d=await t.request({method:`personal_sign`,params:[mU(u),i]});if(typeof d!=`string`||!d)throw Error(`Wallet did not return a signature`);return this.post({...dU,address:i,message:u,signature:d,clientId:o.clientId,redirectUri:o.redirectUri,scope:o.scope??`openid profile email`,state:o.state,nonce:o.nonce,codeChallenge:o.codeChallenge,codeChallengeMethod:o.codeChallengeMethod},o,`${s}${rU.web3Verify}`)}storeTokens(e){if(this.storage.setItem(bU,e.access_token),e.refresh_token&&this.storage.setItem(xU,e.refresh_token),e.id_token&&this.storage.setItem(SU,e.id_token),e.expires_in){let t=Date.now()+e.expires_in*1e3;this.storage.setItem(CU,String(t))}else{let t=sU(e.access_token).exp;typeof t==`number`&&Number.isFinite(t)&&this.storage.setItem(CU,String(t*1e3))}this.held=this.stored()}getAccessToken(){return this.storage.getItem(bU)}getRefreshToken(){return this.storage.getItem(xU)}getIdToken(){return this.storage.getItem(SU)}getExpiresAt(){let e=this.storage.getItem(CU);if(!e)return null;let t=Number(e);return Number.isFinite(t)?t:null}isTokenExpired(){let e=this.storage.getItem(CU);return e?Date.now()>=Number(e):!1}async getValidAccessToken(){let e=this.getAccessToken();if(e&&!this.isTokenExpired())return e;if(this.getRefreshToken())try{return(await this.refreshAccessToken()).accessToken}catch{return null}return null}clearTokens(){this.storage.removeItem(bU),this.storage.removeItem(xU),this.storage.removeItem(SU),this.storage.removeItem(CU),this.held={access:null,refresh:null}}async logout(){let e=this.storage.getItem(bU),t=this.storage.getItem(xU),n=this.storage.getItem(SU);this.clearTokens();let r=await Promise.race([(async()=>(await this.revoke(t,`refresh_token`,e),await this.revoke(e,`access_token`,e),this.endSessionEndpoint()))(),new Promise(e=>setTimeout(()=>e(aU(this.config.serverUrl,`logout`)),gU))]),i=new URL(r);n&&i.searchParams.set(`id_token_hint`,n),i.searchParams.set(`client_id`,this.config.clientId),this.config.postLogoutRedirectUri&&i.searchParams.set(`post_logout_redirect_uri`,this.config.postLogoutRedirectUri),window.location.href=i.toString()}async end(){let e=this.storage.getItem(bU),t=this.storage.getItem(xU),n=this.storage.getItem(SU);this.clearTokens();let r=this.config.proxyBaseUrl??this.config.serverUrl,i=new URLSearchParams({client_id:this.config.clientId});n&&i.set(`id_token_hint`,n),await Promise.race([(async()=>{await this.revoke(t,`refresh_token`,e,aU(r,`revoke`)),await this.revoke(e,`access_token`,e,aU(r,`revoke`)),await fetch(aU(r,`logout`),{method:`POST`,credentials:`include`,redirect:`manual`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:i.toString()}).catch(()=>void 0)})(),new Promise(e=>setTimeout(e,gU))])}async revoke(e,t,n,r){if(e)try{await fetch(r??await this.revocationEndpoint(),{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/x-www-form-urlencoded`,...n?{Authorization:`Bearer ${n}`}:{}},body:new URLSearchParams({token:e,token_type_hint:t,client_id:this.config.clientId}).toString()})}catch{}}async getUserInfo(){let e=await this.getValidAccessToken();if(!e)throw Error(`No valid access token — user must log in`);let t=await this.userinfoEndpoint(),n=await fetch(t,{headers:{Authorization:`Bearer ${e}`}});if(!n.ok)throw Error(`Userinfo fetch failed (${n.status})`);return await n.json()}async getUser(){if(!await this.getValidAccessToken())return null;let e=await this.getUserInfo();return{sub:e.sub??``,email:e.email,name:e.name,givenName:e.given_name,familyName:e.family_name,phoneNumber:e.phone_number,emailVerified:e.email_verified,picture:e.picture,owner:e.owner}}};function iW(e){return{accessToken:e.access_token,refreshToken:e.refresh_token,idToken:e.id_token,expiresIn:e.expires_in,tokenType:e.token_type,scope:e.scope}}var aW=2147483647,oW=3e4,sW=(0,V.createContext)(null);sW.displayName=`IamContext`;var cW=`hanzo_iam_current_org`,lW=`hanzo_iam_current_project`;function uW(e){let{config:t,autoInit:n=!0,onAuthChange:r,children:i}=e,a=(0,V.useMemo)(()=>new rW(t),[t.serverUrl,t.clientId,t.redirectUri]),[o,s]=(0,V.useState)(null),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(n),[f,p]=(0,V.useState)(a.getAccessToken()),[m,h]=(0,V.useState)(null),g=(0,V.useRef)(null),_=(0,V.useCallback)(()=>{if(g.current&&clearTimeout(g.current),a.isTokenExpired())return;let e=a.getExpiresAt();if(e===null)return;let t=async()=>{try{let e=await a.refreshAccessToken();p(e.accessToken),_()}catch(e){if(e instanceof KU){l(!1),s(null),p(null);return}g.current=setTimeout(t,oW)}},n=e-Date.now()-6e4;if(n>aW){g.current=setTimeout(_,aW);return}if(n<=0){t();return}g.current=setTimeout(t,n)},[a]);(0,V.useEffect)(()=>{if(!n){d(!1);return}let e=!1;return(async()=>{try{let t=await a.getValidAccessToken();if(e)return;if(t){p(t),l(!0);try{let t=await a.getUserInfo();e||s(t)}catch{}_(),r?.(!0)}else r?.(!1)}catch(t){e||(h(t instanceof Error?t:Error(String(t))),r?.(!1))}finally{e||d(!1)}})(),()=>{e=!0}},[a,n]),(0,V.useEffect)(()=>()=>{g.current&&clearTimeout(g.current)},[]);let v=(0,V.useCallback)(async e=>{p(e.accessToken),l(!0);try{let e=await a.getUserInfo();s(e)}catch{}_(),r?.(!0)},[a,_,r]),y=(0,V.useCallback)(async e=>{h(null),await a.signinRedirect(e)},[a]),b=(0,V.useCallback)(async e=>{h(null);try{let t=await a.signinPopup(e);await v(t)}catch(e){let t=e instanceof Error?e:Error(String(e));throw h(t),t}},[a,v]),x=(0,V.useCallback)(async e=>{h(null);try{let t=await a.handleCallback(e);return await v(t),t}catch(e){let t=e instanceof Error?e:Error(String(e));throw h(t),t}},[a,v]),S=(0,V.useCallback)(async()=>{g.current&&clearTimeout(g.current);try{localStorage.removeItem(cW),localStorage.removeItem(lW)}catch{}try{await a.logout()}catch{a.clearTokens(),s(null),l(!1),p(null),h(null),r?.(!1)}},[a,r]),C=(0,V.useMemo)(()=>({sdk:a,config:t,user:o,isAuthenticated:c,isLoading:u,accessToken:f,login:y,loginPopup:b,handleCallback:x,logout:S,error:m}),[a,t,o,c,u,f,y,b,x,S,m]);return(0,V.createElement)(sW.Provider,{value:C},i)}function dW(){let e=(0,V.useContext)(sW);if(!e)throw Error(`useIam() must be used within an <IamProvider>`);return e}function fW(){let{isAuthenticated:e,accessToken:t}=dW(),[n,r]=(0,V.useState)([]),[i,a]=(0,V.useState)({}),[o,s]=(0,V.useState)(()=>{try{return localStorage.getItem(cW)}catch{return null}}),[c,l]=(0,V.useState)(()=>{try{return localStorage.getItem(lW)}catch{return null}});(0,V.useEffect)(()=>{if(!e||!t){r([]),a({});return}let{organizations:n,roles:i}=cU(t);r(n.map(e=>({name:e,displayName:e}))),a(i);let c=n[0];if(c&&(!o||!n.includes(o))){s(c);try{localStorage.setItem(cW,c)}catch{}}},[e,t]);let u=[],d=(0,V.useMemo)(()=>n.find(e=>e.name===o)??null,[n,o]),f=(0,V.useCallback)(e=>{s(e),l(null);try{localStorage.setItem(cW,e),localStorage.removeItem(lW)}catch{}},[]),p=(0,V.useCallback)(e=>{l(e);try{e?localStorage.setItem(lW,e):localStorage.removeItem(lW)}catch{}},[]);return{organizations:n,roles:i,currentRole:o?i[o]??null:null,currentOrg:d,currentOrgId:o,switchOrg:f,projects:u,currentProject:null,currentProjectId:c,switchProject:p,isLoading:!1}}function pW(){let{sdk:e,accessToken:t,isAuthenticated:n}=dW(),r=(0,V.useCallback)(async()=>{try{return await e.getValidAccessToken()}catch{return null}},[e]);return{token:t,isValid:n&&!!t&&!e.isTokenExpired(),refresh:r}}function mW(){return hW((0,V.useContext)(sW))}function hW(e){let t=e?.user??null,n=e?.accessToken??null,r=e?.isAuthenticated??!1;return(0,V.useMemo)(()=>r?uU(t,sU(n)):null,[t,n,r])}var gW={site:``,home:`/home`,signUp:`/signup`};function _W(e){gW={...gW,...e}}var vW=()=>gW,yW=()=>gW.brand??`Hanzo`,bW=e=>`${gW.site}${e}`,xW=`admin`;function SW(e){if(!e||e.type===`application`)return!1;let t=e.orgs;return!Array.isArray(t)||t.length===0?!1:t[0]?.org===xW}var CW=[`/board`,`/bots`,`/cal`,`/chat`,`/chat/shared`,`/contacts`,`/dev`,`/drive`,`/home`,`/inbox`,`/meet`,`/settings`,`/settings/organization`,`/settings/organization/billing`,`/settings/organization/members`,`/settings/organization/usage`,`/work`],wW=[`general`,`account`,`privacy`,`billing`,`usage`,`capabilities`,`memory`,`code`,`environments`,`machines`,`keys`,`members`,`integrations`,`notifications`],TW=[`agents`,`bots`,`skills`,`connectors`,`plugins`],EW=[`image`,`video`,`audio`,`document`,`slides`,`type`,`model`,`code`,`file`,`sites`,`new`],DW=/^sess_[0-9a-f]{32}$/,OW=/^[a-z0-9]([a-z0-9-]{0,38}[a-z0-9])?$/,kW=/^[A-Za-z0-9][A-Za-z0-9._-]{0,63}$/,AW=/^(flow_[0-9a-f]{32}|new)$/,jW=[`artifacts`,`templates`,`projects`,`issues`,`automations`,`sync`,`mcp`,`plans`];function MW(e){let t=e.replace(/^\/+|\/+$/g,``);if(DW.test(t))return{kind:`run`,id:t};if(t===`-/settings`||t.startsWith(`-/settings/`)){let e=t.slice(11)||`general`;return wW.includes(e)?{kind:`settings`,section:e}:{kind:`new`}}if(t.startsWith(`-/customize/agents/`)){let e=t.slice(19);return kW.test(e)?{kind:`agent`,name:e}:{kind:`new`}}if(t===`-/customize`||t.startsWith(`-/customize/`)){let e=t.slice(12)||`agents`;return TW.includes(e)?{kind:`customize`,tab:e}:{kind:`new`}}if(t.startsWith(`-/automations/`)){let e=t.slice(14);return AW.test(e)?{kind:`automation`,id:e}:{kind:`new`}}if(t.startsWith(`-/artifacts/`)){let e=t.slice(12);return EW.includes(e)?{kind:`screen`,screen:`artifacts`,of:e}:{kind:`new`}}if(t.startsWith(`-/`)){let e=t.slice(2);return jW.includes(e)?{kind:`screen`,screen:e}:{kind:`new`}}if(OW.test(t))return{kind:`project`,slug:t};let[n,r,...i]=t.split(`/`);return!i.length&&n&&r&&kW.test(n)&&kW.test(r)?{kind:`repo`,org:n,name:r}:{kind:`new`}}[...jW.map(e=>({kind:`screen`,screen:e})),...wW.map(e=>({kind:`settings`,section:e})),...TW.map(e=>({kind:`customize`,tab:e}))];var NW=new Map([[`-/settings/machines`,`machines`],[`-/settings/environments`,`environments`]]);new Map([...NW].map(([e,t])=>[t,e]));function PW(e){if(e.kind===`run`)return`/run/${e.id}`;if(e.kind===`repo`)return`/projects/${e.org}/${e.name}`;if(e.kind===`project`)return`/projects/${e.slug}`;let t=FW(e);return t&&`/${NW.get(t)??t.slice(2)}`}function FW(e){switch(e.kind){case`new`:return``;case`run`:return e.id;case`screen`:return e.of?`-/${e.screen}/${e.of}`:`-/${e.screen}`;case`settings`:return e.section===`general`?`-/settings`:`-/settings/${e.section}`;case`customize`:return e.tab===`agents`?`-/customize`:`-/customize/${e.tab}`;case`agent`:return`-/customize/agents/${e.name}`;case`project`:return e.slug;case`repo`:return`${e.org}/${e.name}`;case`automation`:return`-/automations/${e.id}`}}var IW=`hanzo.optin`,LW=D(`Sign in to choose experimental features.`);async function RW(e,t,n){let r;try{r=await fetch(`${fG()}${e}`,{...t,headers:{...t?.body?{"Content-Type":`application/json`}:{},...DG()}})}catch{throw Error(n.offline)}if(r.status===401)throw Error(LW);if(r.status===403&&n.refused)throw Error(n.refused);if(!r.ok)throw Error(n.failed);return r.json()}var zW=()=>{typeof window<`u`&&window.dispatchEvent(new Event(IW))};function BW(e){let t=e??{};return{on:t.on===!0,blocked:t.blocked===!0,public:Array.isArray(t.public)?t.public.filter(e=>typeof e==`string`):[]}}async function VW(){return BW(await RW(`/v1/flag/optin`,void 0,{offline:D(`Your experimental features setting could not be read. Check your connection and try again.`),failed:D(`Your experimental features setting could not be read. Try again in a moment.`)}))}async function HW(e){let t=BW(await RW(`/v1/flag/optin`,{method:`PUT`,body:JSON.stringify({on:e})},{offline:D(`Your choice was not saved. Check your connection and try again.`),failed:D(`Your choice was not saved. Try again in a moment.`),refused:D(`Your team or organization has turned experimental features off.`)}));return zW(),t}var UW=`https://hanzo.team`;`${UW}`,`${UW}`;var WW=`/dev`,GW=`/library`,KW=`/settings`,qW=`${KW}/organization`,JW={general:KW,organization:qW,members:`${qW}/members`,billing:`${qW}/billing`,usage:`${qW}/usage`,keys:`${qW}/keys`},YW=e=>Object.hasOwn(JW,e),XW=e=>e&&YW(e)?JW[e]:KW;function ZW(e){let t=MW(e),n=PW(t);return n===`/artifacts`||n.startsWith(`/artifacts/`)?`${GW}${n.slice(10)}`:t.kind===`settings`&&(n===`/settings`||n.startsWith(`/settings/`))?XW(t.section):WW+n}var QW=/^[A-Za-z0-9][A-Za-z0-9._-]{0,63}\/[A-Za-z0-9][A-Za-z0-9._-]{0,63}$/,$W=e=>bW(ZW(e&&(DW.test(e)||QW.test(e)||OW.test(e))?e:``)),eG=new Set([`/chat`,`/chat/shared`,`/dev`]);CW.filter(e=>!eG.has(e)&&e!==`/settings`&&!e.startsWith(`/settings/`));var tG=[`hanzo.app`],nG=e=>tG.includes(e),rG=e=>e===`hanzo.team`||e===`www.hanzo.team`,iG=`https://hanzo.ai`,aG=e=>e===`hanzo.ai`||e===`www.hanzo.ai`,oG=`https://hanzo.app`;`${oG}`,`${oG}`;var sG=e=>e.endsWith(`.hanzo.app`)||e===`hanzo.chat`,cG=`-dev.hanzo.ai`;function lG(e){let t=e.endsWith(`.`)?e.slice(0,-1):e;if(!t.endsWith(cG))return!1;let n=t.slice(0,-9);return n.length>4&&!n.includes(`.`)}[...tG],[...tG];var uG=`https://api-dev.hanzo.ai`,dG=()=>typeof window<`u`&&lG(window.location.hostname);function fG(){if(dG())return uG;let e=vW().api;if(e)return e.replace(/\/+$/,``);if(typeof window<`u`){let e=window.location.hostname;return nG(e)||e===`hanzo.ai`||e.endsWith(`.hanzo.ai`)||rG(e)||e===`hanzo.bot`||sG(e)?`https://api.hanzo.ai`:window.location.origin}return`https://api.hanzo.ai`}var pG=`hanzo_iam_`,mG=`${pG}access_token`;`${pG}`;var hG=`${pG}expires_at`;`${pG}`;function gG(){return vW().session??window.localStorage}function _G(){if(typeof window>`u`)return null;try{return gG().getItem(mG)}catch{return null}}`${mG}${hG}`;function vG(){if(typeof window>`u`)return!1;try{return!!(_G()||bG()||window.localStorage.getItem(`hanzo_access_token`)||window.localStorage.getItem(yG)||window.sessionStorage?.getItem(mG))}catch{return!1}}var yG=`hanzo:who`;`${pG}`,`${pG}`;function bG(){let e=_G();if(e)try{let t=e.split(`.`)[1],n=JSON.parse(atob(t.replace(/-/g,`+`).replace(/_/g,`/`)));return typeof n.sub==`string`&&n.sub?n.sub:void 0}catch{return}}function xG(e){if(!e)return null;try{let t=e.split(`.`)[1];return JSON.parse(atob(t.replace(/-/g,`+`).replace(/_/g,`/`)))}catch{return null}}var SG=[`hanzo-id`,`lux-id`,`zoo-id`,`pars-id`],CG=[`hanzo`,`lux`,`zoo`,`pars`,`platform`,`hanzoai`,`luxfi`,`zooai`,`hanzo-inc`,`hanzo-apps`,`hanzo-community`];function wG(e){let t=xG(e),n=SW(t),r=t?.orgs,i=[];for(let e of Array.isArray(r)?r:[]){let t=e,r=t?.org;if(typeof r!=`string`||!r||i.includes(r)||SG.includes(r))continue;let a=typeof t?.role==`string`&&[`owner`,`admin`].includes(t.role.trim().toLowerCase());(r===`admin`?n:!CG.includes(r)||n||a)&&i.push(r)}return i}function TG(){return wG(_G())}function EG(){try{let e=TG(),t=window.localStorage.getItem(`${pG}current_org`);return t&&e.includes(t)?t:e.length===1?e[0]:null}catch{return null}}function DG(){let e={},t=_G();t&&(e.Authorization=`Bearer ${t}`);let n=EG();return n&&(e[`X-Org-Id`]=n),e}var OG=`hanzo:org`;function kG(e){AG(e),window.dispatchEvent(new Event(OG))}function AG(e){try{window.localStorage.setItem(`${pG}current_org`,e)}catch{}}var jG=e=>e?.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase();function MG(e,t,n=[]){if(t==null)throw Error(`[lucide]: iconNode is required when icon name is used`);return{name:jG(e),size:24,node:t,...n.length>0?{aliases:n}:{}}}var NG=e=>{let t=``,n=!1;for(let r of e){if(r===`-`||r===`_`||r<=` `){n=t.length>0;continue}t.length===0?t+=r.toLowerCase():t+=n?r.toUpperCase():r,n=!1}return t},PG=e=>{let t=NG(e);return t.charAt(0).toUpperCase()+t.slice(1)},FG=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),IG={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":2,"stroke-linecap":`round`,"stroke-linejoin":`round`};function LG(e){return e!=null}function RG(e,t={}){let n=t.attributeNames??{},r=e=>n[e]??e,i=e.size??e.width??IG.width,a=e.size??e.height??IG.height,o=e.aliases?.filter(e=>typeof e==`string`&&e.trim()!==``).map(e=>`lucide-${e}`)??[],s=[...e.name?[`lucide-${e.name}`]:[],...o],c=t.className?.split(` `).filter(Boolean)??[],l=t.includeDefaultClasses===!1?FG(...c):FG(`lucide`,...s,...c),u=t.absoluteStrokeWidth?Number(t.strokeWidth??IG[`stroke-width`])*Number(e.size??e.width??IG.width)/Number(t.size??t.width??IG.width):t.strokeWidth??IG[`stroke-width`];return[`svg`,{...Object.entries(IG).reduce((e,[t,n])=>(e[r(t)]=n,e),{}),...`color`in t&&t.color&&{[r(`stroke`)]:t.color},...`size`in t&&LG(t.size)&&{[r(`width`)]:t.size,[r(`height`)]:t.size},...`width`in t&&LG(t.width)&&{[r(`width`)]:t.width},...`height`in t&&LG(t.height)&&{[r(`height`)]:t.height},[r(`stroke-width`)]:u,...l&&{[r(`class`)]:l},[r(`viewBox`)]:`0 0 ${i} ${a}`,...t.hasA11yProp===!1?{[r(`aria-hidden`)]:`true`}:{},...`attributes`in t&&t.attributes},e.node.map(e=>{let[n,i,a]=e,o=t.nonScalingStroke?{[r(`vector-effect`)]:`non-scaling-stroke`,...i}:i;return a?[n,o,a]:[n,o]})]}function zG(e,t={}){return RG(e,{...t,attributeNames:{...t.attributeNames,class:`className`,"stroke-width":`strokeWidth`,"stroke-linecap":`strokeLinecap`,"stroke-linejoin":`strokeLinejoin`,"vector-effect":`vectorEffect`}})}var BG=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},VG=(0,V.createContext)({}),HG=()=>(0,V.useContext)(VG),UG=(0,V.forwardRef)(({color:e,size:t,width:n,height:r,strokeWidth:i,absoluteStrokeWidth:a,nonScalingStroke:o,className:s=``,children:c,iconNode:l=[],icon:u={node:l,aliases:[],size:24},...d},f)=>{let{size:p=24,strokeWidth:m=2,absoluteStrokeWidth:h=!1,nonScalingStroke:g=!1,color:_=`currentColor`,className:v=``}=HG()??{},y=!!c||BG(d),[b,x,S=[]]=zG(u,{color:e??_,width:n??t??p,height:r??t??p,strokeWidth:i??m,absoluteStrokeWidth:a??h,nonScalingStroke:o??g,className:FG(v,s),hasA11yProp:y,attributes:d});return(0,V.createElement)(b,{ref:f,...x},[...S.map(([e,t])=>(0,V.createElement)(e,t)),...Array.isArray(c)?c:[c]])});function WG(e,t=[],n=[]){let r=typeof e==`string`?MG(e,t,n):e,i=(0,V.forwardRef)(({className:e,...t},n)=>(0,V.createElement)(UG,{ref:n,icon:r,className:e,...t}));return r.name&&(i.displayName=PG(r.name)),i}var GG={name:`arrow-left`,size:24,node:[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]};GG.node;var KG=WG(GG),qG={name:`arrow-up-right`,size:24,node:[[`path`,{d:`M7 7h10v10`,key:`1tivn9`}],[`path`,{d:`M7 17 17 7`,key:`1vkiza`}]]};qG.node;var JG=WG(qG),YG={name:`check`,size:24,node:[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]};YG.node;var XG=WG(YG),ZG={name:`compass`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z`,key:`9ktpf1`}]]};ZG.node;var QG=WG(ZG),$G={name:`download`,size:24,node:[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]};$G.node;var eK=WG($G),tK={name:`external-link`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]};tK.node;var nK=WG(tK),rK={name:`lock`,size:24,node:[[`rect`,{width:`18`,height:`11`,x:`3`,y:`11`,rx:`2`,ry:`2`,key:`1w4ew1`}],[`path`,{d:`M7 11V7a5 5 0 0 1 10 0v4`,key:`fwvmzm`}]]};rK.node;var iK=WG(rK),aK={name:`palette`,size:24,node:[[`path`,{d:`M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z`,key:`e79jfc`}],[`circle`,{cx:`13.5`,cy:`6.5`,r:`.5`,fill:`currentColor`,key:`1okk4w`}],[`circle`,{cx:`17.5`,cy:`10.5`,r:`.5`,fill:`currentColor`,key:`f64h9f`}],[`circle`,{cx:`6.5`,cy:`12.5`,r:`.5`,fill:`currentColor`,key:`qy21gx`}],[`circle`,{cx:`8.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`fotxhn`}]]};aK.node;var oK=WG(aK),sK={name:`plus`,size:24,node:[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]};sK.node;var cK=WG(sK),lK={name:`search`,size:24,node:[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]};lK.node;var uK=WG(lK),dK={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`}]]};dK.node;var fK=WG(dK),pK={name:`sparkles`,size:24,node:[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]],aliases:[`stars`]};pK.node;var mK=WG(pK),hK={name:`type`,size:24,node:[[`path`,{d:`M12 4v16`,key:`1654pz`}],[`path`,{d:`M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2`,key:`e0r10z`}],[`path`,{d:`M9 20h6`,key:`s66wpe`}]]};hK.node;var gK=WG(hK),_K={name:`upload`,size:24,node:[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]};_K.node;var vK=WG(_K),yK={name:`x`,size:24,node:[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]};yK.node;var bK=WG(yK),xK=null,SK=null,CK=()=>SK??=Le(()=>import(`./ModelPickerMenu-BpCc5BDl.js`).then(e=>xK=e.ModelPickerMenu),__vite__mapDeps([0,1,2,3,4])),wK=32,TK=44;function EK({models:e,value:t,onChange:n,scope:r,limits:i,loading:o=!1,error:s=null,disabled:c=!1,quiet:l=!1,size:u=`md`,placeholder:d,name:f,describe:p,granted:m,onUpgrade:h,funded:g,balance:_,onTopUp:v,open:b,onOpenChange:x}){let{t:S}=R(),C=f??S(`Model`),[w,T]=(0,V.useState)(!1),E=b??w,D=(0,V.useCallback)(e=>{b===void 0&&T(e),x?.(e)},[b,x]),O=!te().sm,k=O?TK:wK,[A,j]=(0,V.useState)(0),ee=(0,V.useRef)(null),M=t?e.find(e=>e.id===t):void 0,N=M?Zt(M):t||(d??S(`Choose a model`)),P=(0,V.useCallback)(()=>{D(!1),queueMicrotask(()=>ee.current?.focus?.())},[D]),[F,I]=(0,V.useState)(()=>xK),ne=(0,V.useCallback)(()=>{F||CK().then(e=>I(()=>e))},[F]);(0,V.useEffect)(()=>{E&&ne()},[E,ne]);let re=(0,V.useRef)(!1);(0,V.useEffect)(()=>{F&&re.current&&ee.current?.focus?.()},[F]);let ie=u===`sm`,L=(0,H.jsxs)(y,{ref:ee,...B(`model-picker`),role:`button`,tabIndex:c?-1:0,"aria-label":p??S(`{name}: {model}`,{name:C,model:N}),"aria-haspopup":`listbox`,"aria-expanded":E,"aria-disabled":c||void 0,height:l||ie?28:36,px:l?5:ie?`$2`:`$3`,gap:`$2`,items:`center`,maxW:`100%`,rounded:l?8:`$3`,...l?{"$max-sm":{height:36},transition:`quickest`}:null,borderWidth:+!l,borderColor:`$borderColor`,bg:l?`transparent`:`$background`,cursor:c?`default`:`pointer`,opacity:c?.5:1,hoverStyle:c?void 0:l?{bg:`$hover`}:{borderColor:`$rim`},pressStyle:c?void 0:{bg:`$hover`},focusVisibleStyle:at,onLayout:e=>j(e.nativeEvent?.layout?.width??0),onPress:c||F&&!O?void 0:()=>D(!0),onMouseEnter:c?void 0:ne,onFocus:c?void 0:()=>{re.current=!0,ne()},onBlur:e=>{e.relatedTarget&&(re.current=!1)},onKeyDown:e=>{c||(e.key===`Enter`||e.key===` `||e.key===`ArrowDown`||e.key===`ArrowUp`)&&(e.preventDefault?.(),D(!0))},children:[(0,H.jsx)(a,{size:l?`$3`:ie?`$1`:`$2`,color:`$ink`,fontWeight:l?`500`:void 0,numberOfLines:1,shrink:1,minW:0,children:N}),M&&!l?(0,H.jsx)(a,{size:ie?`$1`:`$2`,color:`$soft`,numberOfLines:1,shrink:2,minW:0,children:sn(M)}):null,l?null:(0,H.jsx)(Dp,{size:ie?12:14,color:`$soft`,shrink:0,"aria-hidden":!0})]});return F?(0,H.jsx)(F,{trigger:L,open:E,onOpen:()=>D(!0),onClose:P,disabled:c,width:A,focusTrigger:()=>ee.current?.focus?.(),models:e,value:t,onChange:n,scope:r,limits:i,loading:o,error:s,name:C,sheet:O,row:k,granted:m,onUpgrade:h,funded:g,balance:_,onTopUp:v}):L}var DK=[{id:`auto`,label:D(`Auto`),note:D(`Adaptive reasoning based on task complexity`)},{id:`instant`,label:D(`Instant`),note:D(`Answers right away, without thinking`)},{id:`low`,label:D(`Low`),note:D(`A quick pass with minimal thinking`)},{id:`medium`,label:D(`Medium`),note:D(`Thinks before answering`)},{id:`high`,label:D(`High`),note:D(`Deep reasoning for complex problems`)},{id:`max`,label:D(`Max`),note:D(`Maximum compute and exhaustive verification`)}],OK={px:`$2`,py:`$1.5`,rounded:`$3`};function kK({label:e,children:t,...n}){return(0,H.jsxs)(z,{...B(`sidebar-section`),mt:`$3`,gap:`$0.5`,...n,children:[e?(0,H.jsx)(a,{size:`$1`,px:`$2`,py:`$1`,color:`$soft`,fontWeight:`500`,children:e}):null,t]})}function AK({children:e,active:t=!1,onPress:n,icon:r,...i}){return(0,H.jsxs)(y,{...B(`sidebar-item`),...OK,items:`center`,gap:`$2`,cursor:`pointer`,onPress:n,role:`button`,tabIndex:0,"aria-current":t?`page`:void 0,bg:t?`$edge`:void 0,hoverStyle:{bg:t?`$edge`:`$hover`},pressStyle:{bg:`$raised`},...i,children:[r?(0,H.jsx)(z,{opacity:.7,children:r}):null,(0,H.jsx)(a,{size:`$2`,numberOfLines:1,flex:1,color:t?`$color`:`$quiet`,children:e})]})}var jK=(e,t)=>e.product?e.label:t(e.label),MK=[{label:D(`Settings`),rows:[{id:`general`,label:D(`General`)},{id:`account`,label:D(`Account`)},{id:`billing`,label:D(`Billing`)},{id:`referrals`,label:D(`Referrals & Rewards`)},{id:`usage`,label:D(`Usage`)},{id:`capabilities`,label:D(`Capabilities`),note:D(`What a model may reach for on your behalf.`)},{id:`privacy`,label:D(`Privacy`),href:bW(`/legal/privacy`)},{id:`dev`,label:`Hanzo Dev`,product:!0,href:$W()},{id:`browser`,label:`Hanzo Browser`,product:!0,href:bW(`/extension`)}]},{label:D(`Preferences`),rows:[{id:`model`,label:D(`Default model`)},{id:`agent`,label:D(`Personal agent`),note:D(`The agent that answers as you — its capabilities, its modes, and what it is allowed to do on your behalf. Nothing is bound to this surface yet, so there is nothing here to change; it is listed because this is where it will live.`)}]},{label:D(`Customize`),rows:[{id:`apps`,label:D(`Apps`)},{id:`channels`,label:D(`Channels`)},{id:`plugins`,label:D(`Plugins`),href:bW(ZW(`-/customize/plugins`))},{id:`skills`,label:D(`Skills`),href:bW(ZW(`-/customize`))},{id:`memory`,label:D(`Memory`),note:D(`Nothing is remembered between conversations yet.`)}]},{label:D(`Platform`),rows:[{id:`models`,label:D(`Models`)},{id:`base`,label:`Base`,product:!0,href:bW(`/base`)},{id:`functions`,label:`Functions`,product:!0,href:bW(`/functions`)},{id:`realtime`,label:`Realtime`,product:!0,href:bW(`/realtime`)},{id:`keys`,label:D(`API keys`),href:`https://platform.hanzo.ai/api-keys`}]},{label:D(`Help & Support`),rows:[{id:`docs`,label:D(`Documentation`),href:`https://docs.hanzo.ai`},{id:`support`,label:D(`Help center`),href:bW(`/support`)},{id:`contact`,label:D(`Contact us`),href:bW(`/contact`)},{id:`status`,label:D(`Status`),href:`https://status.hanzo.ai`},{id:`releases`,label:D(`Release notes`),href:`https://github.com/hanzoai/cli/releases`}]}],NK=MK.flatMap(e=>e.rows),PK=NK[0].id;function FK({active:e,filter:t,onPick:n,onBack:r}){let{t:i}=R(),a=t.trim().toLowerCase(),o=a?MK.map(e=>({...e,rows:e.rows.filter(e=>[jK(e,i),e.label].some(e=>e.toLowerCase().includes(a)))})).filter(e=>e.rows.length>0):MK;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(AK,{icon:(0,H.jsx)(KG,{size:15,"aria-hidden":!0,"data-i18n-mirror":!0}),onPress:r,children:i(`Workspace`)}),a&&o.length===0?(0,H.jsx)(U,{px:`$3`,py:`$2`,fontSize:`$2`,color:`$quiet`,children:i(`No matches for “{query}”.`,{query:t.trim()})}):null,o.map(t=>(0,H.jsx)(kK,{label:i(t.label),children:t.rows.map(t=>(0,H.jsx)(AK,{icon:t.href?(0,H.jsx)(JG,{size:13,"aria-hidden":!0}):void 0,active:t.id===e,"aria-current":t.id===e?`true`:void 0,onPress:()=>n(t),children:jK(t,i)},t.id))},t.label))]})}var IK=((e,t)=>ce({},e,t)),LK=class extends Error{status;constructor(e,t){super(t),this.status=e,this.name=`Refusal`}},RK=class extends Error{source;values;constructor(e,t={}){super(ce({},e,t)),this.source=e,this.values=t}};function zK(e,t=IK){return e instanceof RK?t(e.source,e.values):t(e instanceof Error?e.message:String(e))}function BK(e,t){let n=new Headers(t),r=e.token();return r&&!n.has(`Authorization`)&&n.set(`Authorization`,`Bearer ${r}`),e.org&&!n.has(`X-Org-Id`)&&n.set(`X-Org-Id`,e.org),n}async function VK(e){try{let t=await e.json(),n=typeof t.error==`string`?t.error:t.error?.message;return t.detail||n||t.msg||t.message||t.title||``}catch{return``}}var HK=e=>encodeURIComponent(e);async function UK(e,t,n,r,i){let a=BK(e,r===void 0?void 0:{"Content-Type":`application/json`}),o=await fetch(`${e.api}${n}`,{method:t,headers:a,body:r===void 0?void 0:JSON.stringify(r),cache:`no-store`,signal:i?.signal});if(!o.ok){let e=await VK(o);throw new LK(o.status,e||`${t} ${n.split(`?`)[0]} answered ${o.status}`)}if(o.status===204)return;let s=await o.text();return s?JSON.parse(s):void 0}var WK=e=>typeof e==`string`?e:``,GK=e=>typeof e==`number`&&Number.isFinite(e)?e:0,KK=e=>e&&typeof e==`object`?e:{},qK=e=>Array.isArray(e)?e:[];function JK(e,t=`usd`){let n=e%100==0;try{return new Intl.NumberFormat(`en-US`,{style:`currency`,currency:(t||`usd`).toUpperCase(),minimumFractionDigits:n?0:2,maximumFractionDigits:2}).format(e/100)}catch{return`${(e/100).toFixed(n?0:2)} ${t.toUpperCase()}`}}function YK(e){let t=e.replace(/[$,\s]/g,``);if(!/^\d+(\.\d{1,2})?$/.test(t))return null;let n=Math.round(Number(t)*100);return n>0?n:null}function XK(e){let t=KK(e),n=KK(t.card),r=KK(t.billingAddress),i=GK(n.expMonth),a=GK(n.expYear);return{id:WK(t.id),type:WK(t.type)||`card`,brand:WK(n.brand),last4:WK(n.last4),expires:i&&a?`${String(i).padStart(2,`0`)}/${String(a%100).padStart(2,`0`)}`:``,default:t.isDefault===!0,name:WK(t.name),billingAddress:r&&(r.line1||r.city||r.country||r.name||r.postalCode||r.state)?{name:WK(r.name),line1:WK(r.line1),line2:WK(r.line2),city:WK(r.city),state:WK(r.state),postalCode:WK(r.postalCode),country:WK(r.country)}:void 0}}function ZK(e){return e.last4?`${e.brand?e.brand.charAt(0).toUpperCase()+e.brand.slice(1):`Card`} •••• ${e.last4}`:e.name||e.type}async function QK(e){let t=await UK(e,`GET`,`/v1/billing/methods`);return(Array.isArray(t)?t:qK(KK(t).data)).map(XK).filter(e=>e.id)}function $K(e){return e.find(e=>e.default)??e[0]??null}async function eq(e){let t=KK(await UK(e,`GET`,`/v1/billing/balance`));return GK(t.available??t.balance)}async function tq(e){return qK(KK(await UK(e,`GET`,`/v1/billing/credit-balance`)).balances).map(KK).filter(e=>(WK(e.currency)||`usd`).toLowerCase()===`usd`).reduce((e,t)=>e+GK(t.available),0)}async function nq(e){return qK(KK(await UK(e,`GET`,`/v1/billing/credits`)).grants).map(KK).map(e=>({id:WK(e.id),name:WK(e.name),amount:GK(e.amountCents),remaining:GK(e.remainingCents),currency:WK(e.currency)||`usd`,expires:WK(e.expiresAt),active:e.active===!0&&e.voided!==!0})).filter(e=>e.id)}async function rq(e){let t=KK(await UK(e,`GET`,`/v1/billing/tier`));return{plan:WK(t.plan),tier:WK(KK(t.tier).name),name:WK(t.planName)}}function iq(e){let t=KK(e);return{enabled:t.enabled===!0,threshold:GK(t.thresholdCents),amount:GK(t.amountCents),currency:WK(t.currency)||`usd`,last:WK(t.lastRechargedAt)}}async function aq(e){return iq(await UK(e,`GET`,`/v1/billing/recharge`))}async function oq(e,t){return iq(await UK(e,`PUT`,`/v1/billing/recharge`,{enabled:t.enabled,thresholdCents:t.threshold,amountCents:t.amount,currency:`usd`}))}async function sq(e,t,n){if(!Number.isInteger(t)||t<=0)throw Error(D(`Enter an amount to add`));if(!n)throw Error(D(`Add a card before buying more`));return GK(KK(await UK(e,`POST`,`/v1/billing/topup`,{amountCents:t,paymentMethodId:n})).balanceCents)}async function cq(e){let t=KK(KK(await UK(e,`GET`,`/v1/usage/summary?range=month`)).spend);return{known:t.available===!0,total:GK(t.mtdCents)||GK(t.totalCents),categories:qK(t.byCategory).map(KK).map(e=>({name:WK(e.category)||`Uncategorized`,cents:GK(e.cents)})).filter(e=>e.cents>0)}}var lq=e=>GK(e)>0?new Date(GK(e)*1e3).toISOString():``;async function uq(e){let t=KK(await UK(e,`GET`,`/v1/allowance`)),n=t.pool&&typeof t.pool==`object`?KK(t.pool):null;return{plan:WK(t.plan),limit:GK(t.limit),used:GK(t.used),spent:t.spent===!0,window:WK(t.window),resets:lq(t.resets),pooled:t.pooled===!0,pool:n&&WK(n.state)?{state:WK(n.state),resets:lq(n.resets)}:null}}function dq(e){let t=KK(e);return{id:WK(t.id),title:WK(t.title),threshold:GK(t.threshold),enforce:t.enforce===!0,project:WK(t.project),service:WK(t.service),spent:typeof t.periodSpentCents==`number`?t.periodSpentCents:null,resets:WK(t.resetsAt)}}async function fq(e){return qK(await UK(e,`GET`,`/v1/billing/alerts`)).map(dq).filter(e=>e.id)}function pq(e){return e.find(e=>!e.project&&!e.service&&e.threshold>0)??null}async function mq(e,t,n){if(!Number.isInteger(n)||n<=0)throw Error(D(`Enter a monthly limit`));let r=pq(t);return dq(r?await UK(e,`PATCH`,`/v1/billing/alerts/${HK(r.id)}`,{threshold:n}):await UK(e,`POST`,`/v1/billing/alerts`,{title:`Monthly limit`,threshold:n,currency:`usd`,project:``,service:``,enforce:!0,softPct:80,rateLimitRpm:0}))}async function hq(e,t){await UK(e,`DELETE`,`/v1/billing/alerts/${HK(t)}`)}var gq=DK.filter(e=>[`auto`,`high`,`max`].includes(e.id)),_q={model:Tn,effort:`auto`},vq=`hanzo.mind`,yq=`hanzo:mind`,bq=e=>e===`xhigh`?`max`:gq.some(t=>t.id===e)?e:_q.effort;function xq(){try{return typeof window>`u`?null:window.localStorage}catch{return null}}var Sq,Cq=_q,wq=null;function Tq(){if(wq)return wq;let e=null;try{e=xq()?.getItem(vq)??null}catch{e=null}if(e===Sq)return Cq;Sq=e;try{let t=JSON.parse(e??`null`);Cq={model:typeof t?.model==`string`&&t.model.trim()?t.model:_q.model,effort:bq(t?.effort)}}catch{Cq=_q}return Cq}function Eq(e){let t=Tq(),n={...t,...e,effort:e.effort===void 0?t.effort:bq(e.effort)};try{xq()?.setItem(vq,JSON.stringify(n)),wq=null}catch{wq=n}typeof window<`u`&&window.dispatchEvent(new Event(yq))}function Dq(e){return window.addEventListener(yq,e),window.addEventListener(`storage`,e),()=>{window.removeEventListener(yq,e),window.removeEventListener(`storage`,e)}}function Oq(){return[(0,V.useSyncExternalStore)(Dq,Tq,()=>_q),Eq]}Mn([{id:Tn,name:`Enso Auto`,family:`enso`,class:`ours`}]);var kq=`auto`,Aq=`hanzo.chat.preferences`,jq=`hanzo.agent.autonomy`,Mq=`hanzo:chat:preferences`,Nq=4,Pq={allowThirdPartyModels:!1,effort:kq,approvalMode:`auto`,showLanguage:!1,effortVersion:Nq};function Fq(e){return gq.some(t=>t.id===e)?e:null}function Iq(e){return DK.some(t=>t.id===e)?e:kq}function Lq(e,t){return e===`manual`||e===`auto`?e:t===`supervised`?`manual`:`auto`}function Rq(){if(typeof window>`u`)return Pq;try{let e=window.localStorage.getItem(Aq),t=window.localStorage.getItem(jq);if(!e)return{...Pq,approvalMode:Lq(void 0,t)};let n=JSON.parse(e),r=n.effortVersion===Nq?Iq(n.effort):kq;return{allowThirdPartyModels:n.thirdPartyChosen?!!n.allowThirdPartyModels:n.allowThirdPartyModels===!0,...n.thirdPartyChosen?{thirdPartyChosen:!0}:{},effort:r,approvalMode:Lq(n.approvalMode,t),showLanguage:!!n.showLanguage,effortVersion:Nq}}catch{return Pq}}function zq(e){let t={...Rq(),...e,effortVersion:Nq};if(typeof window<`u`){try{window.localStorage.setItem(Aq,JSON.stringify(t)),e.approvalMode&&window.localStorage.setItem(jq,e.approvalMode===`manual`?`supervised`:`autonomous`)}catch{}window.dispatchEvent(new CustomEvent(Mq,{detail:t}))}return t}function Bq(){let[e,t]=(0,V.useState)(Rq);return(0,V.useEffect)(()=>{let e=e=>{let n=e.detail;t(n||Rq())};return window.addEventListener(Mq,e),window.addEventListener(`storage`,e),()=>{window.removeEventListener(Mq,e),window.removeEventListener(`storage`,e)}},[]),[e,zq]}var Vq={display:`inline-flex`,flexDirection:`row`,items:`center`,$touchable:{minH:44,minW:44}},Hq=`#181717`,Uq=V.forwardRef(function({title:e=`GitHub`,color:t=`currentColor`,size:n=24,...r},i){return t==="default"&&(t=Hq),(0,H.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:n,height:n,fill:t,viewBox:`0 0 24 24`,ref:i,...r,children:[(0,H.jsx)(`title`,{children:e}),(0,H.jsx)(`path`,{d:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`})]})}),Wq=`#4285F4`,Gq=V.forwardRef(function({title:e=`Google`,color:t=`currentColor`,size:n=24,...r},i){return t==="default"&&(t=Wq),(0,H.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:n,height:n,fill:t,viewBox:`0 0 24 24`,ref:i,...r,children:[(0,H.jsx)(`title`,{children:e}),(0,H.jsx)(`path`,{d:`M12.48 10.92v3.28h7.84c-.24 1.84-.853 3.187-1.787 4.133-1.147 1.147-2.933 2.4-6.053 2.4-4.827 0-8.6-3.893-8.6-8.72s3.773-8.72 8.6-8.72c2.6 0 4.507 1.027 5.907 2.347l2.307-2.307C18.747 1.44 16.133 0 12.48 0 5.867 0 .307 5.387.307 12s5.56 12 12.173 12c3.573 0 6.267-1.173 8.373-3.36 2.16-2.16 2.84-5.213 2.84-7.667 0-.76-.053-1.467-.173-2.053H12.48z`})]})}),Kq=`hanzo_iam_`,qq=`${Kq}access_token`,Jq=`${Kq}refresh_token`;`${Kq}`;var Yq=`${Kq}id_token`,Xq=e=>{if(typeof window>`u`)return null;try{return window.localStorage.getItem(e)}catch{return null}},Zq=e=>{if(typeof window>`u`)return null;try{return window.sessionStorage?.getItem(e)??null}catch{return null}},Qq=e=>{if(typeof document>`u`||!document.cookie)return null;try{let t=document.cookie.split(`; `).find(t=>t.startsWith(`${e}=`));if(t){let e=t.split(`=`)[1];return e?decodeURIComponent(e):null}return null}catch{return null}},$q=()=>Xq(qq)||Xq(`hanzo_access_token`)||Xq(`token`)||Xq(`auth_token`)||Zq(qq)||Zq(`hanzo_access_token`)||Zq(`token`)||Qq(qq)||Qq(`auth_token`)||Qq(`token`)||Qq(`hanzo_access_token`),eJ=()=>Xq(Jq),tJ=()=>Xq(Yq),nJ=`https://hanzo.ai`;function rJ(e,t,n=nJ){let r=new URL(e).searchParams,i=n.replace(/\/+$/,``);switch(t.kind){case`provider`:return r.set(`provider`,t.provider),`${i}/v1/iam/oauth/authorize?${r}`;case`email`:return r.set(`login_hint`,t.email),`${i}/login?${r}`;case`another`:return r.set(`prompt`,`select_account`),`${i}/login?${r}`;case`signup`:return`${i}/signup?${r}`;case`login`:return`${i}/login?${r}`}}function iJ(e){let t=e.trim();return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)?t:null}var aJ={google:`Google`,github:`GitHub`},oJ=`[data-slot="signin-panel"]`,sJ=`var(--popover,var(--panel))`,cJ=`var(--border,var(--edge))`,lJ=`var(--border-strong,var(--bound))`,uJ=`var(--foreground,var(--ink))`,dJ=`var(--muted-foreground,var(--quiet))`,fJ=`${oJ} [data-signin-body]{container-type:inline-size;display:flex;flex-direction:column;gap:10px;width:100%}${oJ} [data-signin-pair]{display:grid;grid-template-columns:1fr 1fr;gap:10px;width:100%}@container (max-width:379.98px){${oJ} [data-signin-pair]{grid-template-columns:1fr}}${oJ} [data-signin-btn]{box-sizing:border-box;display:flex;align-items:center;justify-content:center;gap:9px;width:100%;height:46px;margin:0;padding:0 14px;border-radius:14px;border:1px solid ${cJ};background:${sJ};color:${uJ};font-family:var(--font-sans,Zen,system-ui,sans-serif);font-size:14px;font-weight:500;line-height:1;white-space:nowrap;cursor:pointer;box-shadow:0 1px 2px rgba(0,0,0,.04);transition:transform .2s cubic-bezier(.16,1,.3,1),border-color .2s,background-color .2s,opacity .2s}${oJ} [data-signin-btn]:hover:not(:disabled){border-color:${lJ};transform:translateY(-2px)}${oJ} [data-signin-btn]:active:not(:disabled){transform:scale(.98)}${oJ} [data-signin-btn]:disabled{opacity:.55;cursor:not-allowed}${oJ} [data-signin-btn][data-solid]{background:${uJ};color:var(--background);border-color:${uJ}}${oJ} [data-signin-btn][data-solid]:hover:not(:disabled){opacity:.92;transform:none}${oJ} [data-signin-btn] svg{flex-shrink:0}${oJ} [data-signin-or]{display:flex;align-items:center;gap:12px;font-size:12.5px;color:${dJ}}${oJ} [data-signin-or]::before,${oJ} [data-signin-or]::after{content:'';flex:1;height:1px;background:${cJ}}${oJ} [data-signin-form]{display:flex;flex-direction:column;gap:10px;margin:0}${oJ} [data-signin-field]{box-sizing:border-box;width:100%;height:46px;margin:0;padding:0 16px;border-radius:14px;border:1px solid ${cJ};background-color:${sJ};color:${uJ};font-family:var(--font-sans,Zen,system-ui,sans-serif);font-size:14px;outline:none}${oJ} [data-signin-field]::placeholder{color:${dJ}}${oJ} [data-signin-field]:focus-visible{border-color:${lJ};box-shadow:0 0 0 2px var(--ring,${lJ})}${oJ} [data-signin-wrong]{margin:0;font-size:13px;color:var(--destructive,#e5484d)}${oJ} [data-signin-quiet]{margin:0;font-size:13px;color:${dJ}}${oJ} [data-signin-quiet] button{padding:0;border:0;background:none;color:${uJ};font:inherit;cursor:pointer}${oJ} [data-signin-quiet] button:hover:not(:disabled){text-decoration:underline}${oJ} [data-signin-terms]{margin:0;max-width:400px;text-align:center;font-size:12px;line-height:18px;color:${dJ}}${oJ} [data-signin-terms] a{color:${uJ};text-decoration:none}${oJ} [data-signin-terms] a:hover{text-decoration:underline;text-underline-offset:2px}`;function pJ(e){return e.request?(0,H.jsx)(hJ,{...e,mint:e.request}):(0,H.jsx)(mJ,{...e})}function mJ(e){let{sdk:t}=dW();return(0,H.jsx)(hJ,{...e,mint:e=>t.getSigninUrl(e)})}function hJ({title:e,line:t,providers:n=[`google`,`github`],signin:r=nJ,signup:i=!1,termsHref:a=`https://hanzo.ai/terms`,privacyHref:o=`https://hanzo.ai/privacy`,authorize:s=e=>e,track:c,mint:l,background:u=`$background`,borderColor:d=`$borderColor`,bare:f=!1}){let{t:p}=R(),[m,h]=(0,V.useState)(``),[g,_]=(0,V.useState)(!1),[v,y]=(0,V.useState)(null),[b,x]=(0,V.useState)(null);async function S(e,t,n){x(null),y(e),c?.(`signin_started`,{method:e});try{let e=await l(n?{additionalParams:{login_hint:n}}:void 0);window.location.assign(s(rJ(e,t,r)))}catch(e){x(e instanceof Error&&e.message?e.message:`Signing in could not start. Try again.`),y(null)}}function C(e){e.preventDefault();let t=iJ(m);if(!t){x(`Enter your email address.`);return}S(`email`,{kind:`email`,email:t},t)}let w=f?{}:{bg:u,borderWidth:1,borderColor:d,rounded:`$6`,p:`$6`},T=p(v===`email`?`One moment…`:`Continue with email`);return(0,H.jsxs)(z,{"data-slot":`signin-panel`,"data-surface":f?`bare`:`card`,width:`100%`,maxW:f?400:464,items:`center`,gap:`$3`,...w,children:[(0,H.jsx)(`style`,{dangerouslySetInnerHTML:{__html:fJ}}),e?(0,H.jsx)(Xt,{render:`h1`,size:`$8`,fontWeight:`500`,color:`$ink`,m:0,text:`center`,children:e}):null,t?(0,H.jsx)(Nt,{size:`$3`,color:`$quiet`,m:0,text:`center`,maxW:360,children:t}):null,(0,H.jsxs)(`div`,{"data-signin-body":``,style:e||t?{marginTop:12}:void 0,children:[n.length?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{"data-signin-pair":``,children:n.map(e=>(0,H.jsxs)(`button`,{"data-signin-btn":``,type:`button`,disabled:v!==null,onClick:()=>void S(e,{kind:`provider`,provider:e}),children:[e===`google`?(0,H.jsx)(Gq,{size:17,"aria-hidden":!0}):(0,H.jsx)(Uq,{size:17,"aria-hidden":!0}),p(`Continue with {provider}`,{provider:aJ[e]})]},e))}),(0,H.jsx)(`div`,{"data-signin-or":``,children:p(`or`)})]}):null,g?(0,H.jsxs)(`form`,{"data-signin-form":``,onSubmit:C,noValidate:!0,children:[(0,H.jsx)(`input`,{id:`hanzo-signin-email`,"data-signin-field":``,type:`email`,name:`email`,autoComplete:`username`,"aria-label":p(`Email`),"aria-invalid":b?!0:void 0,value:m,onChange:e=>h(e.target.value),placeholder:`you@company.com`,autoFocus:!0}),b?(0,H.jsx)(`p`,{"data-signin-wrong":``,role:`alert`,children:p(b)}):null,(0,H.jsx)(`button`,{"data-signin-btn":``,"data-solid":``,type:`submit`,disabled:v!==null,children:T})]}):(0,H.jsxs)(H.Fragment,{children:[b?(0,H.jsx)(`p`,{"data-signin-wrong":``,role:`alert`,children:p(b)}):null,(0,H.jsx)(`button`,{"data-signin-btn":``,"data-solid":``,type:`button`,disabled:v!==null,onClick:()=>{x(null),_(!0)},children:T})]})]}),i?(0,H.jsxs)(`p`,{"data-signin-quiet":``,children:[`${p(`New to Hanzo?`)} `,(0,H.jsx)(`button`,{type:`button`,disabled:v!==null,onClick:()=>void S(`signup`,{kind:`signup`}),children:p(`Create account`)})]}):null,(0,H.jsx)(`p`,{"data-signin-terms":``,children:p(`By continuing, you agree to Hanzo's {terms} and {privacy}.`,{terms:(0,H.jsx)(`a`,{href:a,children:p(`Terms`)}),privacy:(0,H.jsx)(`a`,{href:o,children:p(`Privacy Policy`)})})})]})}async function gJ(e,t,n,r,i){if(t)try{await fetch(`${e}/v1/iam/oauth/revoke`,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`,...r?{Authorization:`Bearer ${r}`}:{}},body:new URLSearchParams({token:t,token_type_hint:n,...i?{client_id:i}:{}}).toString()})}catch{}}async function _J(e,t,n,r){try{await fetch(`${e}/v1/iam/oauth/logout`,{method:`POST`,credentials:`include`,redirect:`manual`,headers:{"Content-Type":`application/x-www-form-urlencoded`},body:new URLSearchParams({...n?{client_id:n}:{},...t?{id_token_hint:t}:{},...r?{everywhere:`true`}:{}}).toString()})}catch{}}function vJ(e,t,n){let r=new URLSearchParams({...n?{client_id:n}:{},everywhere:`true`,post_logout_redirect_uri:new URL(t,window.location.origin).href});return`${e.replace(/\/+$/,``)}/v1/iam/oauth/logout?${r}`}async function yJ(e,{via:t,to:n=`/login?from=logout`,clientId:r,track:i,everywhere:a,issuer:o}={}){let s=t??window.location.origin,c=$q(),l=eJ(),u=tJ();e.clearTokens();try{await gJ(s,l,`refresh_token`,c,r),await gJ(s,c,`access_token`,c,r),await _J(s,u,r,a)}finally{i?.(`logout_completed`,{}),window.location.assign(a&&o?vJ(o,n,r):n)}}function bJ(e={}){let{sdk:t,config:n}=dW(),{via:r,to:i,track:a,clientId:o=n.clientId,everywhere:s,issuer:c=n.serverUrl}=e;return(0,V.useCallback)(()=>yJ(t,{via:r,to:i,track:a,clientId:o,everywhere:s,issuer:c}),[t,r,i,a,o,s,c])}var xJ;function SJ(e,t={}){let n=vW().track;n?n(e,t):ze(xJ,e,t)}var CJ=e=>e===`localhost`||e===`127.0.0.1`||e===`[::1]`||e.endsWith(`.localhost`);function wJ(e,t){if(CJ(t))return``;try{let t=new URL(e).hostname;if(t===`api.hanzo.ai`||t===`hanzo.id`||t===`hanzo.ai`)return iG}catch{return``}return e}function TJ(e=`/`){let{config:t}=dW(),n=bJ({to:e,track:SJ,everywhere:!0,issuer:(e===`/`||e===`/login?from=logout`)&&typeof window<`u`?wJ(t.serverUrl,window.location.hostname):``});return(0,V.useCallback)(async()=>{window.google?.accounts?.id?.disableAutoSelect?.(),await n()},[n])}var EJ=class{constructor(e){this.http=e}http;get(e){return this.http.enveloped({method:`GET`,path:`/v1/ai/account`,...e?.signal?{signal:e.signal}:{}})}},DJ=class extends Error{constructor(e){super(e),this.name=`HanzoAIError`}},OJ=class extends DJ{status;body;constructor(e,t,n){super(e),this.name=`APIError`,this.status=t,this.body=n}},kJ=class extends DJ{constructor(e="No auth token available. Pass `token` or `getToken` to createAiClient."){super(e),this.name=`AuthError`}},AJ=`/v1/agents`,jJ=/^[A-Za-z0-9][A-Za-z0-9._-]{0,63}$/,MJ=131072;function NJ(e,t=``){if(!jJ.test(e))throw new DJ(`Not a valid agent ref: ${JSON.stringify(e)}`);return`${AJ}/${e}${t}`}var PJ=class{constructor(e){this.http=e}http;list(e){return this.http.collection(`agents`,{method:`GET`,path:AJ,...e?.signal?{signal:e.signal}:{}})}create(e,t){return this.http.json({method:`POST`,path:AJ,body:e,...t?.signal?{signal:t.signal}:{}})}async get(e,t){return this.http.json({method:`GET`,path:NJ(e),...t?.signal?{signal:t.signal}:{}})}async update(e,t,n){return this.http.json({method:`PATCH`,path:NJ(e),body:t,...n?.signal?{signal:n.signal}:{}})}async delete(e,t){await this.http.raw({method:`DELETE`,path:NJ(e),...t?.signal?{signal:t.signal}:{}})}async run(e,t,n){let r=NJ(e,`/run`);if(new TextEncoder().encode(t).length>MJ)throw new DJ(`Input exceeds ${MJ} bytes.`);return this.http.json({method:`POST`,path:r,body:{input:t},...n?.signal?{signal:n.signal}:{}})}runs(e={},t){let{agent:n,...r}=e;return this.http.collection(`runs`,{method:`GET`,path:n?NJ(n,`/runs`):`${AJ}/runs`,...Object.keys(r).length?{query:r}:{},...t?.signal?{signal:t.signal}:{}})}metrics(e,t){return this.http.json({method:`GET`,path:`${AJ}/metrics`,...e?.range?{query:{range:e.range}}:{},...t?.signal?{signal:t.signal}:{}})}activity(e){return this.http.collection(`activity`,{method:`GET`,path:`${AJ}/activity`,...e?.signal?{signal:e.signal}:{}})}};function FJ(e){let t=e??{};return{status:`held`,id:typeof t.id==`string`?t.id:``,clause:typeof t.clause==`string`?t.clause:``,reason:typeof t.reason==`string`?t.reason:``}}var IJ=`https://api.hanzo.ai`;function LJ(e,t){return e.replace(/\/+$/,``)+(t.startsWith(`/`)?t:`/${t}`)}function RJ(e){if(!e)return``;let t=new URLSearchParams;for(let[n,r]of Object.entries(e))r!==void 0&&t.set(n,String(r));let n=t.toString();return n?`?${n}`:``}function zJ(e){return typeof FormData<`u`&&e instanceof FormData}var BJ=class{baseUrl;issuer;auth;token;getToken;fetchImpl;extraHeaders;constructor(e){this.baseUrl=e.baseUrl??IJ,this.issuer=e.issuer,this.auth=e.auth,this.token=e.token??e.secretKey??e.publishableKey,this.getToken=e.getToken,this.extraHeaders=e.headers??{};let t=e.fetch??globalThis.fetch;if(typeof t!=`function`)throw new OJ("No fetch implementation available; pass `fetch` in the client config.",0);this.fetchImpl=t.bind(globalThis)}async resolveToken(){if(this.auth){let e=this.auth.getValidAccessToken?await this.auth.getValidAccessToken():this.auth.getAccessToken?.()??null;if(e)return e;if(!this.getToken&&!this.token)throw new kJ}if(this.getToken)return await this.getToken();if(this.token)return this.token;throw new kJ}async buildHeaders(e){let t=new Headers(this.extraHeaders);for(let[n,r]of Object.entries(e.headers??{}))t.set(n,r);return e.body!==void 0&&!zJ(e.body)&&!t.has(`Content-Type`)&&t.set(`Content-Type`,`application/json`),!e.anonymous&&!t.has(`Authorization`)&&t.set(`Authorization`,`Bearer ${await this.resolveToken()}`),t}async send(e,t){let n=await this.buildHeaders(t),r={method:t.method??`GET`,headers:n};return t.body!==void 0&&(r.body=zJ(t.body)?t.body:JSON.stringify(t.body)),t.signal&&(r.signal=t.signal),this.fetchImpl(e,r)}async raw(e){let t=LJ(e.baseUrl??this.baseUrl,e.path)+RJ(e.query),n=await this.send(t,e);return!e.anonymous&&this.auth?.invalidate&&await VJ(n)&&(this.auth.invalidate(),n=await this.send(t,e)),n.ok||await UJ(n),n}async result(e){let t=await this.raw(e),n=await t.json().catch(()=>({}));return t.status===202&&n.status===`held`?FJ(n):{status:`done`,value:n}}scoped(e){return{baseUrl:this.baseUrl,issuer:this.issuer,auth:e,fetch:this.fetchImpl,headers:this.extraHeaders}}async json(e){return await(await this.raw(e)).json()}async collection(e,t){let n=(await this.json(t))?.[e];return Array.isArray(n)?n:[]}async bearer(){try{return await this.resolveToken()}catch{return}}async enveloped(e){let t=await this.json(e);if(t.status!==`ok`)throw new OJ(t.msg||`Request failed`,200,t);return t.data}};async function VJ(e){if(e.status===401)return!0;if(e.status!==403)return!1;let t=(await e.clone().json().catch(()=>void 0))?.detail;return typeof t==`string`&&t.includes(`validated principal`)}var HJ={502:`The service did not answer. Nothing was run; try again.`,503:`The service is not running right now.`,504:`The service took too long to answer.`};async function UJ(e){let t=await e.text().catch(()=>``),n=t,r=HJ[e.status]??`HTTP ${e.status}`;if(t)try{n=JSON.parse(t),r=WJ(n)??r}catch{n=t}throw new OJ(r,e.status,n)}function WJ(e){if(e&&typeof e==`object`){let t=e;if(typeof t.msg==`string`&&t.msg)return t.msg;let n=t.error;if(typeof n==`string`)return n;if(n&&typeof n==`object`){let e=n.message;if(typeof e==`string`)return e}if(typeof t.detail==`string`&&t.detail)return t.detail;if(typeof t.title==`string`&&t.title)return t.title}}async function*GJ(e){let t=e.getReader(),n=new TextDecoder,r=``;try{for(;;){let{value:e,done:i}=await t.read();if(i)break;r+=n.decode(e,{stream:!0});let a;for(;(a=KJ(r))!==-1;){let e=r.slice(0,a);r=r.slice(qJ(r,a));let t=JJ(e);t&&(yield t)}}let e=r.trim();if(e){let t=JJ(e);t&&(yield t)}}finally{t.releaseLock()}}function KJ(e){let t=e.indexOf(`
|
|
97
|
+
|
|
98
|
+
`),n=e.indexOf(`\r
|
|
99
|
+
\r
|
|
100
|
+
`);return t===-1?n:n===-1?t:Math.min(t,n)}function qJ(e,t){return e.startsWith(`\r
|
|
101
|
+
\r
|
|
102
|
+
`,t)?t+4:t+2}function JJ(e){let t,n=[];for(let r of e.split(/\r?\n/))r===``||r.startsWith(`:`)||(r.startsWith(`event:`)?t=r.slice(6).trim():r.startsWith(`data:`)&&n.push(r.slice(5).replace(/^ /,``)));if(n.length===0&&t===void 0)return null;let r={data:n.join(`
|
|
103
|
+
`)};return t!==void 0&&(r.event=t),r}function YJ(e){if(!e.body)throw new OJ(`Streaming response had no body`,e.status);return e.body}async function XJ(e){if(/\bjson\b/i.test(e.headers.get(`content-type`)??``)){let t=await e.clone().text().catch(()=>``),n=t;try{n=JSON.parse(t)}catch{}throw n&&typeof n==`object`&&(`error`in n||`detail`in n||`msg`in n)&&await UJ(e),new OJ(`The service answered with a document where a stream was asked for.`,e.status,n)}return GJ(YJ(e))}async function*ZJ(e){for await(let t of await XJ(e)){let e=t.data;if(e===`[DONE]`)return;e&&(yield JSON.parse(e))}}async function*QJ(e){for await(let t of await XJ(e)){let e=t.data;if(e===`[DONE]`)return;e&&(yield JSON.parse(e))}}async function*$J(e){for await(let t of await XJ(e)){if(t.data===`[DONE]`||!t.data)continue;let e=JSON.parse(t.data);t.event&&!e.type&&(e.type=t.event);let n=e;if(yield n,n.type===`message_stop`)return}}var eY=`/v1/chat/completions`,tY=`/v1/chat/public`;function nY(e){let t={...e?.headers};return e?.maxCost!==void 0&&(t[`X-Max-Cost`]=String(e.maxCost)),e?.maxLatencyMs!==void 0&&(t[`X-Max-Latency-Ms`]=String(e.maxLatencyMs)),Object.keys(t).length>0?t:void 0}var rY=class{constructor(e){this.http=e}http;lane(e){return iY(this.http,e)}async create(e,t){let n=await this.lane(t)===`public`?tY:eY,r=nY(t),i=await this.http.raw({method:`POST`,path:n,body:e,...e.stream?{stream:!0}:{},...t?.signal?{signal:t.signal}:{},...t?.anonymous||n===tY?{anonymous:!0}:{},...r?{headers:r}:{}});return t?.onResponse?.(i),e.stream?ZJ(i):await i.json()}};async function iY(e,t){return t?.lane?t.lane:t?.anonymous?`public`:await e.bearer()?`account`:`public`}var aY=class{completions;constructor(e){this.completions=new rY(e)}},oY=class{constructor(e){this.http=e}http;create(e,t){return this.http.json({method:`POST`,path:`/v1/decisions`,body:e,...t?.signal?{signal:t.signal}:{}})}},sY=`https://api.hanzo.ai`,cY=new Set([`up`,`down`,`regenerate`,`switch`,`abandon`,`accept`,`revert`,`rating`,`dismiss`]);function lY(e){let t=typeof e.requestId==`string`?e.requestId.trim():``;if(!t)return null;let n=e.signal;if(!cY.has(n))return null;if(n===`rating`){let n=e.rating;return n!==1&&n!==2&&n!==3?null:{request_id:t,signal:`rating`,rating:n}}return{request_id:t,signal:n}}function uY(e){return e.signal===`rating`?`${e.request_id}:rating:${e.rating}`:`${e.request_id}:${e.signal}`}var dY=new Set;function fY(){try{let e=globalThis.process?.env?.HANZO_FEEDBACK;if(e==null)return!1;let t=String(e).trim().toLowerCase();return t===`0`||t===`false`||t===`off`}catch{return!1}}function pY(e,t={}){if(t.disabled||fY())return Promise.resolve(null);let n=lY(e);if(!n)return Promise.resolve(null);if(t.dedupe!==!1){let e=uY(n);if(dY.has(e))return Promise.resolve(null);dY.add(e)}let r=LJ(t.baseUrl??sY,`/v1/ai/feedback`),i=JSON.stringify(n),a=t.token;return typeof a==`function`?Promise.resolve().then(()=>a()).then(e=>mY(r,i,e,t)).catch(()=>null):mY(r,i,a,t)}function mY(e,t,n,r){try{if(!n){let n=r.sendBeacon??(typeof navigator<`u`&&typeof navigator.sendBeacon==`function`?navigator.sendBeacon.bind(navigator):void 0);if(n){let r=typeof Blob<`u`?new Blob([t],{type:`application/json`}):t;try{if(n(e,r))return Promise.resolve(null)}catch{}}}let i=r.fetch??(typeof fetch==`function`?fetch:void 0);if(!i)return Promise.resolve(null);let a={"Content-Type":`application/json`};return n&&(a.Authorization=`Bearer ${n}`),i(e,{method:`POST`,credentials:r.credentials??`include`,keepalive:!0,headers:a,body:t}).then(async e=>{if(!e.ok)return null;let t=await e.json();return t.status===`ok`&&t.data?t.data:null}).catch(()=>null)}catch{return Promise.resolve(null)}}var hY=3e4,gY=3e5,_Y=`/v1/iam/tokens/issue`,vY=`https://hanzo.id`,yY=class{constructor(e,t,n=vY){this.http=e,this.subject=t,this.issuer=n}http;subject;issuer;token;expiresAt=0;async getValidAccessToken(){return this.token&&this.expiresAt-Date.now()>hY?this.token:this.mint()}invalidate(){this.token=void 0,this.expiresAt=0}async mint(){let e=await this.http.json({method:`POST`,baseUrl:this.issuer,path:_Y,query:{id:this.subject}}),t=e.accessToken;if(!t)throw new kJ(`IAM issued no token for the act grant.`);return this.token=t,this.expiresAt=bY(e),t}};function bY(e){return typeof e.expiresIn==`number`?Date.now()+e.expiresIn*1e3:Date.now()+gY}var xY=class{constructor(e){this.http=e}http;list(e){return this.http.collection(`targets`,{method:`GET`,path:`/v1/agents/targets`,...e?.signal?{signal:e.signal}:{}})}},SY=`/v1/messages`,CY=class{constructor(e){this.http=e}http;async create(e,t){return e.stream?$J(await this.http.raw({method:`POST`,path:SY,body:e,stream:!0,...t?.signal?{signal:t.signal}:{}})):this.http.json({method:`POST`,path:SY,body:e,...t?.signal?{signal:t.signal}:{}})}async*stream(e,t){yield*await this.create({...e,stream:!0},t)}countTokens(e,t){return this.http.json({method:`POST`,path:`${SY}/count_tokens`,body:e,...t?.signal?{signal:t.signal}:{}})}},wY=class{constructor(e){this.http=e}http;list(e){return this.http.collection(`data`,{method:`GET`,path:`/v1/models`,...e?.signal?{signal:e.signal}:{}})}},TY=`/v1/iam/scim/v2/Users`,EY=`urn:ietf:params:scim:schemas:extension:hanzo:2.0:User`;function DY(e){let t=e[EY]??{},n=e.emails?.find(e=>e.primary)?.value??e.emails?.[0]?.value;return{id:e.id,name:e.userName,displayName:e.displayName,...n?{email:n}:{},active:e.active,service:e.userType===`service-account`,...t.owner?{org:t.owner}:{},...t.isAdmin?{admin:!0}:{}}}var OY=class{constructor(e){this.http=e}http;async list(e,t){let n=((await this.http.json({method:`GET`,path:TY,query:{owner:e.owner},...t?.signal?{signal:t.signal}:{}}))?.Resources??[]).map(DY);return e.service===void 0?n:n.filter(t=>t.service===e.service)}},kY=class{constructor(e){this.http=e}http;lease(e,t){return this.http.json({method:`POST`,path:`/v1/sandbox/lease`,body:e??{},...t?.signal?{signal:t.signal}:{}})}run(e,t){return this.http.json({method:`POST`,path:`/v1/sandbox/run`,body:e,...t?.signal?{signal:t.signal}:{}})}read(e,t){return this.http.json({method:`POST`,path:`/v1/sandbox/read`,body:e,...t?.signal?{signal:t.signal}:{}})}write(e,t){return this.http.json({method:`POST`,path:`/v1/sandbox/write`,body:e,...t?.signal?{signal:t.signal}:{}})}stop(e,t){return this.http.json({method:`POST`,path:`/v1/sandbox/stop`,body:e,...t?.signal?{signal:t.signal}:{}})}end(e,t){return this.http.raw({method:`POST`,path:`/v1/sandbox/end`,body:e,...t?.signal?{signal:t.signal}:{}}).then(()=>void 0)}list(e,t){let n={};return e?.project&&(n.project=e.project),e?.status&&(n.status=e.status),this.http.collection(`sandboxes`,{method:`GET`,path:`/v1/sandbox`,query:n,...t?.signal?{signal:t.signal}:{}})}get(e,t){return this.http.json({method:`GET`,path:`/v1/sandbox/${encodeURIComponent(e)}`,...t?.signal?{signal:t.signal}:{}})}},AY=`/v1/agents/sessions`,jY=class{constructor(e){this.http=e}http;list(e,t){let n={};return e?.status&&(n.status=e.status),e?.project&&(n.project=e.project),e?.root&&(n.root=e.root),e?.parent&&(n.parent=e.parent),e?.limit!==void 0&&(n.limit=String(e.limit)),this.http.collection(`sessions`,{method:`GET`,path:AY,query:n,...t?.signal?{signal:t.signal}:{}})}get(e,t){return this.http.json({method:`GET`,path:`${AY}/${encodeURIComponent(e)}`,...t?.signal?{signal:t.signal}:{}})}tree(e,t){return this.http.json({method:`GET`,path:`${AY}/${encodeURIComponent(e)}/tree`,...t?.signal?{signal:t.signal}:{}})}update(e,t,n){return this.http.json({method:`PATCH`,path:`${AY}/${encodeURIComponent(e)}`,body:t,...n?.signal?{signal:n.signal}:{}})}steer(e,t,n,r){return this.http.json({method:`POST`,path:`${AY}/${encodeURIComponent(e)}/${t}`,body:n??{},...r?.signal?{signal:r.signal}:{}})}control(e,t,n){let r={};return t?.after!==void 0&&(r.after=String(t.after)),this.http.json({method:`GET`,path:`${AY}/${encodeURIComponent(e)}/control`,query:r,...n?.signal?{signal:n.signal}:{}})}async*stream(e,t){let n={};e?.root&&(n.root=e.root);let r=await this.http.raw({method:`GET`,path:`${AY}/stream`,query:n,headers:{Accept:`text/event-stream`},...t?.signal?{signal:t.signal}:{}});if(r.body)for await(let e of GJ(r.body)){if(!e.data)continue;let t;try{t=JSON.parse(e.data)}catch{continue}e.event===`event`?t.event&&(yield{kind:`event`,event:t.event}):t.session&&(yield{kind:`session`,session:t.session})}}},MY=`/v1/agents/chat/conversations`,NY=class{constructor(e){this.http=e}http;list(e){return this.http.collection(`conversations`,{method:`GET`,path:MY,...e?.archived?{query:{archived:!0}}:{},...e?.signal?{signal:e.signal}:{}})}update(e,t,n){return this.http.json({method:`PATCH`,path:`${MY}/${encodeURIComponent(e)}`,body:t,...n?.signal?{signal:n.signal}:{}})}async remove(e,t){await this.http.json({method:`DELETE`,path:`${MY}/${encodeURIComponent(e)}`,...t?.signal?{signal:t.signal}:{}})}async record(e,t,n){return(await this.http.json({method:`POST`,path:MY,body:{...t?{conversationId:t}:{},messages:e},...n?.signal?{signal:n.signal}:{}}))?.conversationId??``}async get(e,t){let n=await this.http.json({method:`GET`,path:`${MY}/${encodeURIComponent(e)}`,...t?.signal?{signal:t.signal}:{}});return n?.messages?.length?n:null}},PY=`/v1/tools`,FY=class{constructor(e){this.http=e}http;list(e,t){let n={};return e?.source&&(n.source=e.source),e?.activated!==void 0&&(n.activated=String(e.activated)),this.http.collection(`tools`,{method:`GET`,path:PY,query:n,...t?.signal?{signal:t.signal}:{}})}skills(e,t){let n={};return e?.activated!==void 0&&(n.activated=String(e.activated)),this.http.json({method:`GET`,path:`${PY}/skills`,query:n,...t?.signal?{signal:t.signal}:{}})}plugins(e,t){let n={};return e?.all!==void 0&&(n.all=String(e.all)),this.http.collection(`plugins`,{method:`GET`,path:`${PY}/plugins`,query:n,...t?.signal?{signal:t.signal}:{}})}mcp(e){return this.http.collection(`servers`,{method:`GET`,path:`${PY}/mcp/servers`,...e?.signal?{signal:e.signal}:{}})}catalog(e,t){let n={};return e?.q&&(n.q=e.q),e?.featured!==void 0&&(n.featured=String(e.featured)),e?.official!==void 0&&(n.official=String(e.official)),e?.limit!==void 0&&(n.limit=String(e.limit)),e?.offset!==void 0&&(n.offset=String(e.offset)),this.http.json({method:`GET`,path:`${PY}/catalog`,query:n,...t?.signal?{signal:t.signal}:{}})}listing(e,t){return this.http.json({method:`GET`,path:`${PY}/catalog/${encodeURIComponent(e)}`,...t?.signal?{signal:t.signal}:{}})}activation(e){return this.http.json({method:`GET`,path:`${PY}/activation`,...e?.signal?{signal:e.signal}:{}})}activate(e,t){return this.http.json({method:`PUT`,path:`${PY}/activation`,body:{enabled:e},...t?.signal?{signal:t.signal}:{}})}},IY=class{constructor(e){this.http=e}http;list(e){return this.http.collection(`transports`,{method:`GET`,path:`/v1/transport`,...e?.signal?{signal:e.signal}:{}})}inbox(e,t){let n={};return e?.since!==void 0&&(n.since=String(e.since)),e?.limit!==void 0&&(n.limit=String(e.limit)),this.http.json({method:`GET`,path:`/v1/transport/inbox`,query:n,...t?.signal?{signal:t.signal}:{}})}allowlist(e,t){return this.http.json({method:`GET`,path:`/v1/transport/allowlist`,query:{transport:e.transport},...t?.signal?{signal:t.signal}:{}})}pairing(e){return this.http.json({method:`GET`,path:`/v1/transport/pairing`,...e?.signal?{signal:e.signal}:{}})}},LY=`/v1/ask`;function RY(e){return e instanceof kJ?`401 ${e.message}`:e instanceof OJ?`${e.status} ${e.message}`:e instanceof Error?e.message:String(e)}async function*zY(e,t,n,r){try{yield*QJ(await e.http.raw({method:`POST`,path:LY,headers:{Accept:`text/event-stream`},body:{q:t,mode:n===`deep`?`research`:n,model:r.model,sources:r.sources,language:r.language,maxSources:r.maxSources,maxQueries:r.maxQueries,followUps:r.followUps,system:r.system},...r.signal?{signal:r.signal}:{}}))}catch(e){yield{type:`error`,error:RY(e)}}}function BY(e,t,n={}){return zY(e,t,n.mode??`search`,n)}function VY(e,t,n={}){return zY(e,t,`research`,n)}var HY=class e{chat;messages;models;decisions;agents;machines;sandboxes;tools;sessions;threads;people;transports;account;http;constructor(e={}){this.http=new BJ(e),this.chat=new aY(this.http),this.messages=new CY(this.http),this.models=new wY(this.http),this.decisions=new oY(this.http),this.agents=new PJ(this.http),this.machines=new xY(this.http),this.sandboxes=new kY(this.http),this.sessions=new jY(this.http),this.tools=new FY(this.http),this.threads=new NY(this.http),this.people=new OY(this.http),this.transports=new IY(this.http),this.account=new EJ(this.http)}search(e,t){return BY(this,e,t)}deepResearch(e,t){return VY(this,e,t)}feedback(e,t={}){return pY(e,{fetch:this.http.fetchImpl,...t,baseUrl:this.http.baseUrl,token:()=>this.http.bearer()})}as(t){return new e(this.http.scoped(new yY(this.http,t,this.http.issuer)))}};function UY(e={}){return new HY(e)}var WY=(0,V.createContext)(null);function GY(){let e=(0,V.useContext)(WY);if(!e)throw new DJ(`useAi requires an <AiProvider> above it.`);return e}function KY(e){return e instanceof Error?e:new DJ(String(e))}function qY(e,t){let[n,r]=(0,V.useState)(null),[i,a]=(0,V.useState)(!0),[o,s]=(0,V.useState)(null),[c,l]=(0,V.useState)(0),u=(0,V.useRef)(e);return u.current=e,(0,V.useEffect)(()=>{let e=new AbortController;return a(!0),u.current(e.signal).then(t=>{e.signal.aborted||(r(t),s(null),a(!1))},t=>{e.signal.aborted||(s(KY(t)),a(!1))}),()=>e.abort()},[...t,c]),{value:n,loading:i,error:o,reload:(0,V.useCallback)(()=>l(e=>e+1),[]),set:r}}function JY(){let e=GY(),{value:t,loading:n,error:r}=qY(t=>e.models.list({signal:t}),[e]);return{models:t??[],loading:n,error:r}}var YY=class extends Error{status;constructor(e,t=0){super(e),this.name=`UsageError`,this.status=t}},XY=e=>typeof e==`number`&&Number.isFinite(e)?e:0,ZY=e=>typeof e==`string`?e:``,QY=e=>e===!0,$Y=e=>typeof e==`number`&&Number.isFinite(e)?e:null;function eX(e){let t=e??{};return{tokens:XY(t.tokens),promptTokens:XY(t.promptTokens),completionTokens:XY(t.completionTokens),requests:XY(t.requests),spendCents:XY(t.spendCents),models:XY(t.models),providers:XY(t.providers)}}function tX(e){let t={};if(e&&typeof e==`object`)for(let[n,r]of Object.entries(e)){let e=r??{};t[n]={current:XY(e.current),prior:XY(e.prior),pct:$Y(e.pct)}}return t}function nX(e){return Array.isArray(e)?e.map(e=>{let t=e??{};return{t:ZY(t.t),tokens:XY(t.tokens),spendCents:XY(t.spendCents),requests:XY(t.requests),models:XY(t.models)}}):[]}function rX(e){let t=e??{},n=Array.isArray(t.items)?t.items.map(e=>{let t=e??{};return{model:ZY(t.model),provider:ZY(t.provider),spendCents:XY(t.spendCents),tokens:XY(t.tokens),requests:XY(t.requests),pct:XY(t.pct)}}):[],r=null;if(t.other&&typeof t.other==`object`){let e=t.other;r={spendCents:XY(e.spendCents),tokens:XY(e.tokens),requests:XY(e.requests),pct:XY(e.pct),modelCount:XY(e.modelCount)}}return{items:n,other:r,totalCents:XY(t.totalCents)}}function iX(e){let t=e??{};return{items:Array.isArray(t.items)?t.items.map(e=>{let t=e??{};return{time:ZY(t.time),model:ZY(t.model),provider:ZY(t.provider),type:ZY(t.type),status:ZY(t.status),tokens:XY(t.tokens),promptTokens:XY(t.promptTokens),completionTokens:XY(t.completionTokens),costCents:XY(t.costCents),stream:QY(t.stream),premium:QY(t.premium),requestId:ZY(t.requestId),org:ZY(t.org),user:ZY(t.user)}}):[],limit:XY(t.limit),offset:XY(t.offset),total:XY(t.total),type:ZY(t.type)}}function aX(e){let t=e??{},n=t.scope??{};return{range:ZY(t.range),start:ZY(t.start),end:ZY(t.end),interval:ZY(t.interval)||`day`,scope:{org:ZY(n.org),allOrgs:QY(n.allOrgs)},totals:eX(t.totals),deltas:tX(t.deltas),series:nX(t.series),byModel:rX(t.byModel),activity:iX(t.activity)}}var oX=`/v1/ai/usages/cloud`;async function sX(e){let t=e.fetch??globalThis.fetch;if(!t)throw new YY(`no fetch implementation available`);let n=e.baseUrl.replace(/\/+$/,``),r=new URLSearchParams;e.range&&r.set(`range`,e.range),e.start&&r.set(`start`,e.start),e.end&&r.set(`end`,e.end),e.org&&r.set(`org`,e.org),e.topModels!=null&&r.set(`topModels`,String(e.topModels)),e.activityType&&r.set(`activityType`,e.activityType),e.activityLimit!=null&&r.set(`activityLimit`,String(e.activityLimit)),e.activityOffset!=null&&r.set(`activityOffset`,String(e.activityOffset));let i=r.toString(),a;try{a=await t(`${n}${oX}${i?`?${i}`:``}`,{method:`GET`,headers:{Authorization:`Bearer ${e.token}`,Accept:`application/json`},signal:e.signal})}catch(e){throw new YY(e instanceof Error?e.message:String(e))}if(!a.ok)throw new YY(`GET ${oX} HTTP ${a.status}`,a.status);let o=await a.json();if(o&&typeof o==`object`&&`status`in o&&o.status&&o.status!==`ok`)throw new YY(o.msg||`usage ledger unavailable`,a.status);return aX(o&&typeof o==`object`&&`data`in o?o.data:o)}var cX=class extends Error{status;constructor(e,t){super(e),this.name=`UsageSummaryError`,this.status=t}},lX=`/v1/usage/summary`,uX=e=>typeof e==`number`&&Number.isFinite(e)?e:0,dX=e=>typeof e==`string`?e:``;function fX(e){let t=e??{},n=t.spend??{},r=t.llm??{};return{start:dX(t.start),end:dX(t.end),interval:dX(t.interval),scope:t.scope??{},spend:{available:n.available===!0,totalCents:uX(n.totalCents),mtdCents:uX(n.mtdCents),overageCents:uX(n.overageCents),balanceCents:uX(n.balanceCents),availableCents:uX(n.availableCents),byCategory:Array.isArray(n.byCategory)?n.byCategory.map(e=>{let t=e??{};return{category:dX(t.category),amountCents:uX(t.amountCents)}}):[],series:Array.isArray(n.series)?n.series.map(e=>{let t=e??{};return{t:dX(t.t),amountCents:uX(t.amountCents)}}):[],source:dX(n.source)},llm:{available:r.available===!0,requests:uX(r.requests),tokens:uX(r.tokens),promptTokens:uX(r.promptTokens),completionTokens:uX(r.completionTokens)},accounts:t.accounts,sources:t.sources??void 0}}async function pX(e){let t=e.fetch??globalThis.fetch;if(!t)throw new cX(`no fetch implementation available`);let n=e.baseUrl.replace(/\/+$/,``),r=new URLSearchParams;e.range&&r.set(`range`,e.range),e.org&&r.set(`org`,e.org);let i=r.toString(),a=await t(`${n}${lX}${i?`?${i}`:``}`,{headers:e.token?{authorization:`Bearer ${e.token}`}:{},signal:e.signal});if(!a.ok)throw new cX(`GET ${lX} HTTP ${a.status}`,a.status);let o=await a.json();return fX(o&&typeof o==`object`&&`data`in o?o.data:o)}var mX=class extends Error{status;constructor(e,t){super(e),this.name=`AllowanceError`,this.status=t}},hX=`/v1/allowance`,gX=e=>typeof e==`number`&&Number.isFinite(e)?e:0,_X=e=>typeof e==`string`?e:``,vX=e=>gX(e)>0?gX(e)*1e3:null,yX=[`available`,`busy`,`exhausted`];function bX(e){let t=e??{},n=t.pool&&typeof t.pool==`object`?t.pool:null,r=_X(n?.state);return{plan:_X(t.plan),limit:gX(t.limit),used:gX(t.used),spent:t.spent===!0,window:_X(t.window),resets:vX(t.resets),pooled:t.pooled===!0,pool:n&&yX.includes(r)?{state:r,resets:vX(n.resets)}:null}}async function xX(e){let t=e.fetch??globalThis.fetch;if(!t)throw new mX(`no fetch implementation available`);let n=await t(`${e.baseUrl.replace(/\/+$/,``)}${hX}`,{headers:e.token?{authorization:`Bearer ${e.token}`}:{},signal:e.signal});if(!n.ok)throw new mX(`GET ${hX} HTTP ${n.status}`,n.status);let r=await n.json();return bX(r&&typeof r==`object`&&`data`in r&&!(`limit`in r)?r.data:r)}function SX(e){return e.limit<=0?0:Math.min(100,Math.ceil(Math.min(e.used,e.limit)/e.limit*100/5)*5)}function CX(e){return e===`hour`?`this hour`:e===`day`?`today`:`this period`}function wX(e,t=Date.now()){if(e===null)return``;let n=new Date(e),r=new Date(t),i=`${String(n.getUTCHours()).padStart(2,`0`)}:${String(n.getUTCMinutes()).padStart(2,`0`)} UTC`;return n.getUTCFullYear()===r.getUTCFullYear()&&n.getUTCMonth()===r.getUTCMonth()&&n.getUTCDate()===r.getUTCDate()?i:`${n.toLocaleString(`en-US`,{month:`short`,timeZone:`UTC`})} ${n.getUTCDate()}, ${i}`}function TX(e,t=Date.now()){let n=wX(e.resets,t);switch(e.state){case`available`:return`Available`;case`busy`:return`Busy — try again in a minute`;case`exhausted`:return`Used up${n?` until ${n}`:` for now`}`}}function EX(e){let t=(Number.isFinite(e)?e:0)/100,n=Math.abs(t);return n>=1e6?`$${(t/1e6).toFixed(1)}M`:n>=1e4?`$${(t/1e3).toFixed(1)}K`:`$${t.toFixed(2)}`}function DX(e){if(!Number.isFinite(e))return`—`;let t=Math.abs(e);return t>=1e9?`${(e/1e9).toFixed(1)}B`:t>=1e6?`${(e/1e6).toFixed(1)}M`:t>=1e3?`${(e/1e3).toFixed(1)}K`:String(Math.round(e))}function OX(e){if(e==null)return`new`;let t=Math.round(e);return`${t>0?`+`:``}${t}%`}function kX(e){return e==null||Math.round(e)===0?`flat`:e>0?`up`:`down`}function AX(e,t){let n=new Date(e);return Number.isNaN(n.getTime())?e:t===`hour`?`${String(n.getUTCHours()).padStart(2,`0`)}:00`:n.toLocaleDateString(void 0,{month:`short`,day:`numeric`,timeZone:`UTC`})}var jX=[`#6ea8fe`,`#7ee787`,`#f0a868`,`#c792ea`,`#56d4c4`,`#e879a6`,`#d6c15a`,`#8b9bb4`],MX=`rgba(128,128,128,0.18)`,NX=`#7ee787`,PX=`#e5534b`,FX=e=>jX[e%jX.length];function IX({points:e,width:t=120,height:n=34,color:r=jX[0]}){let i=(e??[]).filter(e=>Number.isFinite(e));if(i.length<2)return null;let a=Math.min(...i),o=Math.max(...i)-a||1,s=t/(i.length-1),c=e=>n-2-(e-a)/o*(n-4),l=i.map((e,t)=>`${t===0?`M`:`L`}${(t*s).toFixed(1)},${c(e).toFixed(1)}`).join(` `),u=`${l} L${(t-1).toFixed(1)},${n} L1,${n} Z`;return(0,H.jsxs)(`svg`,{width:t,height:n,viewBox:`0 0 ${t} ${n}`,"aria-hidden":!0,style:{display:`block`},children:[(0,H.jsx)(`path`,{d:u,fill:r,fillOpacity:.12}),(0,H.jsx)(`path`,{d:l,fill:`none`,stroke:r,strokeWidth:1.5,strokeLinejoin:`round`,strokeLinecap:`round`})]})}function LX({bars:e,height:t=120,color:n=jX[0]}){if(!e.length)return null;let r=Math.max(...e.map(e=>e.value),1),i=e.length>60?1:3,a=Math.max(1,(640-i*(e.length-1))/e.length);return(0,H.jsx)(`svg`,{width:`100%`,height:t,viewBox:`0 0 640 ${t}`,preserveAspectRatio:`none`,role:`img`,"aria-label":`usage over time`,children:e.map((e,o)=>{let s=Math.max(1,e.value/r*(t-2));return(0,H.jsx)(`rect`,{x:o*(a+i),y:t-s,width:a,height:s,rx:2,fill:n,opacity:.85,children:(0,H.jsx)(`title`,{children:e.hint})},`${e.label}-${o}`)})})}function RX({pct:e,color:t}){return(0,H.jsx)(z,{height:6,bg:MX,rounded:`$2`,overflow:`hidden`,children:(0,H.jsx)(z,{height:6,width:`${Math.max(2,Math.max(0,Math.min(100,e)))}%`,bg:t,rounded:`$2`})})}function zX({title:e,action:t,children:n,minW:r}){return(0,H.jsxs)(z,{flex:1,minW:r??320,gap:`$3`,p:`$4`,borderWidth:1,borderColor:`$borderColor`,rounded:`$4`,bg:`$color1`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`800`,color:`$color12`,children:e}),t]}),n]})}function BX({icon:e,label:t,value:n,deltaPct:r,spark:i,sparkColor:a}){let o=r===void 0?`flat`:kX(r??null),s=o===`up`?NX:o===`down`?PX:`$color10`;return(0,H.jsxs)(z,{p:`$4`,gap:`$2`,borderWidth:1,borderColor:`$borderColor`,rounded:`$4`,bg:`$color1`,flex:1,minW:180,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[e,(0,H.jsx)(U,{fontSize:`$2`,color:`$color11`,numberOfLines:1,children:t})]}),(0,H.jsxs)(y,{items:`flex-end`,justify:`space-between`,gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$7`,fontWeight:`900`,color:`$color12`,children:n}),r===void 0?null:(0,H.jsx)(U,{fontSize:`$1`,color:s,fontWeight:`700`,children:OX(r??null)})]}),i&&i.filter(e=>Number.isFinite(e)).length>=2?(0,H.jsx)(IX,{points:i,color:a??jX[0]}):null]})}function VX({title:e,subtitle:t,right:n}){return(0,H.jsxs)(y,{items:`flex-start`,justify:`space-between`,gap:`$3`,flexWrap:`wrap`,children:[(0,H.jsxs)(z,{gap:`$1`,children:[(0,H.jsx)(U,{fontSize:`$6`,fontWeight:`900`,color:`$color12`,children:e}),t?(0,H.jsx)(U,{fontSize:`$2`,color:`$color10`,children:t}):null]}),n]})}function HX({title:e,message:t,onRetry:n}){return(0,H.jsxs)(z,{p:`$5`,gap:`$3`,borderWidth:1,borderColor:`$borderColor`,rounded:`$4`,bg:`$color1`,items:`center`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`700`,color:`$color12`,children:e}),(0,H.jsx)(U,{fontSize:`$2`,color:`$color10`,style:{textAlign:`center`},children:t}),n?(0,H.jsx)(Je,{size:`$2`,icon:(0,H.jsx)(gm,{size:15}),onPress:n,children:`Retry`}):null]})}function UX({data:e}){let t=e.series,n=e.totals,r=e.deltas;return(0,H.jsxs)(y,{flexWrap:`wrap`,gap:`$3`,children:[(0,H.jsx)(BX,{icon:(0,H.jsx)(Lp,{size:16,color:`#7ee787`}),label:`Spend`,value:EX(n.spendCents),deltaPct:r.spendCents?.pct??null,spark:t.map(e=>e.spendCents),sparkColor:`#7ee787`}),(0,H.jsx)(BX,{icon:(0,H.jsx)(Mp,{size:16,color:`#6ea8fe`}),label:`Tokens`,value:DX(n.tokens),deltaPct:r.tokens?.pct??null,spark:t.map(e=>e.tokens),sparkColor:`#6ea8fe`}),(0,H.jsx)(BX,{icon:(0,H.jsx)(lp,{size:16,color:`#f0a868`}),label:`Requests`,value:DX(n.requests),deltaPct:r.requests?.pct??null,spark:t.map(e=>e.requests),sparkColor:`#f0a868`}),(0,H.jsx)(BX,{icon:(0,H.jsx)(Zp,{size:16,color:`#c792ea`}),label:`Models`,value:DX(n.models),deltaPct:r.models?.pct??null}),(0,H.jsx)(BX,{icon:(0,H.jsx)(yp,{size:16,color:`#56d4c4`}),label:`Providers`,value:DX(n.providers)})]})}var WX=[{key:`spendCents`,label:`Spend`,color:`#7ee787`},{key:`tokens`,label:`Tokens`,color:`#6ea8fe`},{key:`requests`,label:`Requests`,color:`#f0a868`}],GX=(e,t)=>t===`spendCents`?e.spendCents:t===`tokens`?e.tokens:e.requests,KX=(e,t,n)=>`${AX(e.t,n)} · ${t===`spendCents`?EX(e.spendCents):`${DX(GX(e,t))} ${t}`}`;function qX({data:e}){let[t,n]=(0,V.useState)(`spendCents`),r=WX.find(e=>e.key===t)??WX[0],i=e.series.map(n=>({label:n.t,value:GX(n,t),hint:KX(n,t,e.interval)})),a=i.some(e=>e.value>0);return(0,H.jsx)(zX,{title:`Usage over time`,action:(0,H.jsx)(y,{gap:`$1`,children:WX.map(e=>(0,H.jsx)(Je,{size:`$2`,chromeless:t!==e.key,onPress:()=>n(e.key),"aria-label":`Show ${e.label}`,children:e.label},e.key))}),children:a?(0,H.jsx)(LX,{bars:i,color:r.color}):(0,H.jsxs)(U,{fontSize:`$3`,color:`$color10`,children:[`No `,r.label.toLowerCase(),` recorded in this range yet.`]})})}function JX({data:e}){let t=e.spend,n=t.totalCents,r=t.byCategory.map((e,t)=>({key:`${e.category}-${t}`,label:e.category||`other`,amountCents:e.amountCents,pct:n>0?e.amountCents/n*100:0,color:FX(t)}));return(0,H.jsx)(zX,{title:`Spend by category`,action:(0,H.jsx)(U,{fontSize:`$2`,color:`$color11`,children:EX(n)}),children:t.available?r.length?(0,H.jsx)(z,{gap:`$3`,children:r.map(e=>(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$2`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,flex:1,children:[(0,H.jsx)(z,{width:9,height:9,rounded:`$1`,bg:e.color}),(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$color12`,numberOfLines:1,children:e.label})]}),(0,H.jsx)(U,{fontSize:`$3`,color:`$color12`,fontWeight:`600`,children:EX(e.amountCents)})]}),(0,H.jsx)(RX,{pct:e.pct,color:e.color})]},e.key))}):(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`No spend in this range yet.`}):(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`The ledger could not be read, so this is not a measurement.`})})}function YX({data:e}){let t=e.byModel,n=t.items.map((e,t)=>({key:`${e.model}-${t}`,model:e.model||`unknown`,provider:e.provider,spendCents:e.spendCents,pct:e.pct,color:FX(t)}));return t.other&&n.push({key:`other`,model:`Other (${t.other.modelCount})`,provider:`remaining models`,spendCents:t.other.spendCents,pct:t.other.pct,color:`#64748b`}),(0,H.jsx)(zX,{title:`Spend by model`,action:(0,H.jsx)(U,{fontSize:`$2`,color:`$color11`,children:EX(t.totalCents)}),children:n.length?(0,H.jsx)(z,{gap:`$3`,children:n.map(e=>(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$2`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,flex:1,children:[(0,H.jsx)(z,{width:9,height:9,rounded:`$1`,bg:e.color}),(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$color12`,numberOfLines:1,children:e.model}),(0,H.jsx)(U,{fontSize:`$1`,color:`$color10`,numberOfLines:1,children:e.provider})]}),(0,H.jsx)(U,{fontSize:`$3`,color:`$color12`,fontWeight:`600`,children:EX(e.spendCents)})]}),(0,H.jsx)(RX,{pct:e.pct,color:e.color})]},e.key))}):(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`No model spend in this range yet.`})})}var XX={available:NX,busy:`#f0a868`,exhausted:PX};function ZX({data:e,upgrade:t,now:n=Date.now()}){if(!e.pooled||e.limit<=0)return null;let r=SX(e),i=wX(e.resets,n);return(0,H.jsxs)(zX,{title:`Free plan`,action:t?(0,H.jsx)(`a`,{href:t,style:{textDecoration:`none`},children:(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`700`,color:`$color12`,children:`Upgrade`})}):void 0,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$color11`,children:`Free — limited usage, from a pool shared by all free users.`}),(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsxs)(y,{items:`baseline`,justify:`space-between`,gap:`$2`,flexWrap:`wrap`,children:[(0,H.jsxs)(U,{fontSize:`$3`,fontWeight:`600`,color:`$color12`,children:[r,`% used `,CX(e.window)]}),i?(0,H.jsxs)(U,{fontSize:`$2`,color:`$color10`,children:[`Refills `,i]}):null]}),(0,H.jsx)(RX,{pct:r,color:e.spent?PX:NX})]}),e.pool?(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(z,{width:8,height:8,rounded:`$10`,bg:XX[e.pool.state]??`$color10`}),(0,H.jsxs)(U,{fontSize:`$2`,color:`$color11`,children:[`Shared pool: `,TX(e.pool,n)]})]}):null]})}var QX=e=>{let t=e.toLowerCase();return t===`success`||t===`ok`||t===``?NX:t===`error`||t===`failed`?PX:`#f0a868`},$X=e=>{let t=new Date(e);return Number.isNaN(t.getTime())?e:t.toLocaleString(void 0,{month:`short`,day:`numeric`,hour:`2-digit`,minute:`2-digit`})};function eZ({data:e}){let t=e.activity.items;return(0,H.jsx)(zX,{title:`Recent activity`,action:e.activity.total?(0,H.jsxs)(U,{fontSize:`$2`,color:`$color11`,children:[DX(e.activity.total),` calls`]}):void 0,children:t.length?(0,H.jsx)(z,{children:t.map((e,n)=>(0,H.jsxs)(y,{items:`center`,gap:`$2`,py:`$2`,borderColor:`$borderColor`,borderBottomWidth:+(n<t.length-1),children:[(0,H.jsx)(z,{width:7,height:7,rounded:`$10`,bg:QX(e.status)}),(0,H.jsxs)(z,{flex:1,gap:`$0.5`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$color12`,numberOfLines:1,children:e.model||`inference`}),(0,H.jsx)(U,{fontSize:`$1`,color:`$color10`,numberOfLines:1,children:[e.provider,$X(e.time)].filter(Boolean).join(` · `)})]}),(0,H.jsxs)(U,{fontSize:`$2`,color:`$color11`,numberOfLines:1,children:[DX(e.tokens),` tok`]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$color12`,fontWeight:`600`,numberOfLines:1,children:EX(e.costCents)})]},e.requestId||`${e.time}-${n}`))}):(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`No activity in this range yet.`})})}var tZ=[`24h`,`7d`,`30d`];function nZ({value:e,onChange:t}){return(0,H.jsx)(y,{gap:`$1`,children:tZ.map(n=>(0,H.jsx)(Je,{size:`$2`,chromeless:e!==n,onPress:()=>t(n),"aria-label":`Range ${n}`,children:n},n))})}var rZ=e=>!(`baseUrl`in e);function iZ({data:e,sections:t,summary:n,allowance:r,upgrade:i}){let a={overview:!0,chart:!0,breakdown:!0,activity:!0,categories:!1,allowance:!0,...t};return(0,H.jsxs)(z,{gap:`$4`,children:[a.allowance&&r?.pooled?(0,H.jsx)(y,{children:(0,H.jsx)(ZX,{data:r,upgrade:i})}):null,a.overview?(0,H.jsx)(UX,{data:e}):null,a.categories&&n?(0,H.jsx)(y,{children:(0,H.jsx)(JX,{data:n})}):null,a.chart?(0,H.jsx)(y,{children:(0,H.jsx)(qX,{data:e})}):null,a.breakdown||a.activity?(0,H.jsxs)(y,{flexWrap:`wrap`,gap:`$4`,children:[a.breakdown?(0,H.jsx)(YX,{data:e}):null,a.activity?(0,H.jsx)(eZ,{data:e}):null]}):null]})}var aZ=`Usage is unavailable`;function oZ(e){let t=e.title??`Usage`;if(rZ(e)){let n=e.onRangeChange&&e.range?(0,H.jsx)(nZ,{value:e.range,onChange:e.onRangeChange}):void 0;return(0,H.jsxs)(z,{gap:`$4`,children:[(0,H.jsx)(VX,{title:t,subtitle:e.subtitle,right:n}),e.error?(0,H.jsx)(HX,{title:aZ,message:e.error,onRetry:e.onRetry}):e.loading||!e.data?(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`Loading usage…`}):(0,H.jsx)(iZ,{data:e.data,sections:e.sections})]})}return(0,H.jsx)(sZ,{...e,title:t})}function sZ(e){let[t,n]=(0,V.useState)(e.range??`24h`),[r,i]=(0,V.useState)({phase:`loading`}),[a,o]=(0,V.useState)(0),[s,c]=(0,V.useState)(null),[l,u]=(0,V.useState)(null),{baseUrl:d,token:f,org:p,start:m,end:h,topModels:g,activityType:_,activityLimit:v,activityOffset:y}=e,b=e.fetch,x=(0,V.useRef)(0);(0,V.useEffect)(()=>{let e=++x.current,n=new AbortController;return i({phase:`loading`}),sX({baseUrl:d,token:f,org:p,range:t,start:m,end:h,topModels:g,activityType:_,activityLimit:v,activityOffset:y,signal:n.signal,fetch:b}).then(t=>{e===x.current&&i({phase:`ready`,data:t})}).catch(t=>{n.signal.aborted||e!==x.current||i({phase:`error`,message:t instanceof Error?t.message:String(t)})}),()=>n.abort()},[d,f,p,t,m,h,g,_,v,y,b,a]),(0,V.useEffect)(()=>{if(!e.sections?.categories){c(null);return}let n=new AbortController,r=!0;return pX({baseUrl:d,token:f,org:p,range:t,signal:n.signal,fetch:b}).then(e=>{r&&c(e)}).catch(()=>{r&&c(null)}),()=>{r=!1,n.abort()}},[d,f,p,t,a,e.sections?.categories]);let S=e.sections?.allowance!==!1;return(0,V.useEffect)(()=>{if(!S){u(null);return}let e=new AbortController,t=!0;return xX({baseUrl:d,token:f,signal:e.signal,fetch:b}).then(e=>{t&&u(e)}).catch(()=>{t&&u(null)}),()=>{t=!1,e.abort()}},[d,f,b,a,S]),(0,H.jsxs)(z,{gap:`$4`,children:[(0,H.jsx)(VX,{title:e.title,subtitle:e.subtitle,right:(0,H.jsx)(nZ,{value:t,onChange:t=>{n(t),e.onRangeChange?.(t)}})}),r.phase===`error`?(0,H.jsx)(HX,{title:aZ,message:r.message,onRetry:()=>o(e=>e+1)}):r.phase===`loading`?(0,H.jsx)(U,{fontSize:`$3`,color:`$color10`,children:`Loading usage…`}):(0,H.jsx)(iZ,{data:r.data,sections:e.sections,summary:s,allowance:l,upgrade:e.upgrade})]})}var cZ=M(z,{name:`Card`,bg:`$background`,position:`relative`,rounded:`$true`}),lZ=`<svg role="img" aria-label="Hanzo" viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
104
|
+
<!-- Origami fold-in → hover: one 3-D turn → press: squash. Pure CSS, no JS. Canonical 7-path shaded H. -->
|
|
105
|
+
|
|
106
|
+
<style>.o{fill:currentColor;opacity:0;transform-box:fill-box;transform-origin:left center;animation:fold 0.42s cubic-bezier(.16,1,.3,1) forwards}
|
|
107
|
+
.s{fill:currentColor;opacity:.55}
|
|
108
|
+
@keyframes fold{from{opacity:0;transform:perspective(320px) rotateY(90deg)}to{opacity:1;transform:none}}
|
|
109
|
+
.o0{animation-delay:0.00s}.o1{animation-delay:0.06s}.o2{animation-delay:0.12s}.o3{animation-delay:0.18s}.o4{animation-delay:0.24s}
|
|
110
|
+
/* interaction — pure CSS, no JS: hover = one graceful turn (returns to rest), press = squash */
|
|
111
|
+
.hanzo-hov{transform-box:view-box;transform-origin:33.5px 33.5px}
|
|
112
|
+
.hanzo-prs{transform-box:view-box;transform-origin:33.5px 33.5px;transition:transform .22s cubic-bezier(.22,1,.36,1)}
|
|
113
|
+
svg:hover .hanzo-hov{animation:hanzoTurn 0.85s cubic-bezier(.45,0,.2,1)}
|
|
114
|
+
svg:active .hanzo-prs{transform:scale(.92)}
|
|
115
|
+
@keyframes hanzoTurn{0%{transform:perspective(300px) rotateY(0)}100%{transform:perspective(300px) rotateY(360deg)}}
|
|
116
|
+
@media (prefers-reduced-motion:reduce){.hanzo-hov,.hanzo-prs{animation:none!important;transform:none!important}.o{opacity:1;animation:none;transform:none}}
|
|
117
|
+
</style>
|
|
118
|
+
<g class="hanzo-hov"><g class="hanzo-prs">
|
|
119
|
+
<path class="o o0" d="M22.21 0H0V22.3184H22.21V0Z"/>
|
|
120
|
+
<path class="o o1" d="M66.7198 0H44.5098V22.3184H66.7198V0Z"/>
|
|
121
|
+
<path class="o o1 s" d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z"/>
|
|
122
|
+
<path class="o o2" d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z"/>
|
|
123
|
+
<path class="o o3" d="M22.21 67V44.6369H0V67H22.21Z"/>
|
|
124
|
+
<path class="o o3 s" d="M0 44.6369L22.21 46.8285V44.6369H0Z"/>
|
|
125
|
+
<path class="o o4" d="M66.7198 67V44.6369H44.5098V67H66.7198Z"/>
|
|
126
|
+
</g></g>
|
|
127
|
+
</svg>`,uZ=[`M22.21 67V44.6369H0V67H22.21Z`,`M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z`,`M22.21 0H0V22.3184H22.21V0Z`,`M66.7198 0H44.5098V22.3184H66.7198V0Z`,`M66.7198 67V44.6369H44.5098V67H66.7198Z`],dZ=[`M0 44.6369L22.21 46.8285V44.6369H0Z`,`M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z`],fZ=`<path d="${uZ[0]}"/><path class="shade" fill="#DDDDDD" d="${dZ[0]}"/><path d="${uZ[1]}"/><path d="${uZ[2]}"/><path d="${uZ[3]}"/><path class="shade" fill="#DDDDDD" d="${dZ[1]}"/><path d="${uZ[4]}"/>`,pZ=`<circle cx="12" cy="12" r="8.88" fill="none" stroke="currentColor" stroke-width="2.64" stroke-linecap="round"/>`;function mZ(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
128
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#ffffff"/>
|
|
129
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#DDDDDD"/>
|
|
130
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#ffffff"/>
|
|
131
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#ffffff"/>
|
|
132
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#ffffff"/>
|
|
133
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#DDDDDD"/>
|
|
134
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#ffffff"/>
|
|
135
|
+
</svg>`}function hZ(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
136
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#000000"/>
|
|
137
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#000000"/>
|
|
138
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#000000"/>
|
|
139
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#000000"/>
|
|
140
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#000000"/>
|
|
141
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#000000"/>
|
|
142
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#000000"/>
|
|
143
|
+
</svg>`}function gZ(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
144
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="#ffffff"/>
|
|
145
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="#DDDDDD"/>
|
|
146
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="#ffffff"/>
|
|
147
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="#ffffff"/>
|
|
148
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="#ffffff"/>
|
|
149
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="#DDDDDD"/>
|
|
150
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="#ffffff"/>
|
|
151
|
+
</svg>`}function _Z(){let e=e=>`<path d="${e}" fill="#000000"/>`,t=e=>`<path class="shade" d="${e}" fill="#222222"/>`;return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg"><rect width="67" height="67" fill="#ffffff"/>`+e(uZ[0])+t(dZ[0])+e(uZ[1])+e(uZ[2])+e(uZ[3])+t(dZ[1])+e(uZ[4])+`</svg>`}function vZ(){return`<svg viewBox="0 0 67 67" xmlns="http://www.w3.org/2000/svg">
|
|
152
|
+
<path d="M22.21 67V44.6369H0V67H22.21Z" fill="currentColor"/>
|
|
153
|
+
<path d="M0 44.6369L22.21 46.8285V44.6369H0Z" fill="currentColor"/>
|
|
154
|
+
<path d="M66.7038 22.3184H22.2534L0.0878906 44.6367H44.4634L66.7038 22.3184Z" fill="currentColor"/>
|
|
155
|
+
<path d="M22.21 0H0V22.3184H22.21V0Z" fill="currentColor"/>
|
|
156
|
+
<path d="M66.7198 0H44.5098V22.3184H66.7198V0Z" fill="currentColor"/>
|
|
157
|
+
<path d="M66.6753 22.3185L44.5098 20.0822V22.3185H66.6753Z" fill="currentColor"/>
|
|
158
|
+
<path d="M66.7198 67V44.6369H44.5098V67H66.7198Z" fill="currentColor"/>
|
|
159
|
+
</svg>`}var yZ=64,bZ=2,xZ=48/67,SZ=8,CZ=4/xZ,wZ=(e,t)=>` <defs><g id="m">
|
|
160
|
+
${uZ.map(e=>` <path d="${e}"/>`).join(`
|
|
161
|
+
`)}
|
|
162
|
+
</g></defs>
|
|
163
|
+
<g transform="translate(${SZ} ${SZ}) scale(${xZ.toFixed(4)})">
|
|
164
|
+
<use href="#m" ${e} stroke-width="${CZ.toFixed(4)}" stroke-miterlimit="${bZ}"/>
|
|
165
|
+
<use href="#m" ${t}/>
|
|
166
|
+
</g>`;function TZ(){return`<svg viewBox="0 0 ${yZ} ${yZ}" xmlns="http://www.w3.org/2000/svg">
|
|
167
|
+
<style>
|
|
168
|
+
.core { fill: #ffffff }
|
|
169
|
+
.rim { fill: #000000; stroke: #000000 }
|
|
170
|
+
@media (prefers-color-scheme: light) { .core { fill: #000000 } }
|
|
171
|
+
@media (prefers-color-scheme: dark) { .rim { fill: #ffffff; stroke: #ffffff } }
|
|
172
|
+
</style>
|
|
173
|
+
${wZ(`class="rim"`,`class="core"`)}
|
|
174
|
+
</svg>`}function EZ(e={}){let{variant:t=`current`}=e,n=``;switch(t){case`mono`:n=hZ();break;case`white`:n=gZ();break;case`light`:n=_Z();break;case`current`:n=vZ();break;case`favicon`:n=TZ();break;case`color`:n=mZ();break;default:n=vZ()}return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(n)))}`}TZ(),EZ(),EZ({variant:`mono`}),EZ({variant:`white`}),EZ({variant:`favicon`});function DZ(){return`data:image/svg+xml;base64,`+btoa(unescape(encodeURIComponent(lZ)))}DZ();function OZ(e){let t=e.trim();if(!t||/^(https?:|data:|\/)/.test(t)||!/[\p{Extended_Pictographic}\p{Regional_Indicator}]/u.test(t))return!1;let n=Intl.Segmenter;return(n?[...new n().segment(t)].length:[...t].length)<=3}function kZ(e){return(e.trim().split(/[\s._/-]+/).filter(Boolean).slice(0,2).map(e=>e[0]??``).join(``)||e.trim().slice(0,2)).toUpperCase()}var AZ=e=>e<26?`$1`:e<34?`$2`:e<44?`$4`:`$6`;function jZ({org:e,size:t=22,maxW:n}){let[r,i]=(0,V.useState)(!1);return(0,V.useEffect)(()=>i(!1),[e.logo]),e.logo&&OZ(e.logo)?(0,H.jsx)(z,{width:t,height:t,items:`center`,justify:`center`,style:{flexShrink:0},children:(0,H.jsx)(U,{fontSize:Math.round(t*.72),lineHeight:t,children:e.logo.trim()})}):e.logo&&!r?(0,H.jsx)(`img`,{src:e.logo,alt:``,onError:()=>i(!0),style:{height:t,width:n?`auto`:t,maxWidth:n??t,objectFit:`contain`,display:`block`,borderRadius:6,flexShrink:0}}):(0,H.jsx)(z,{width:t,height:t,rounded:`$3`,bg:`$edge`,items:`center`,justify:`center`,style:{flexShrink:0},children:(0,H.jsx)(U,{fontSize:AZ(t),fontWeight:`800`,color:`$ink`,children:kZ(e.displayName||e.name)})})}var MZ=`theme`;function NZ(){if(typeof document>`u`)return;let e=document.documentElement;if(e.classList.contains(`dark`))return`dark`;if(e.classList.contains(`light`))return`light`;try{let e=window.localStorage.getItem(MZ);if(e===`light`||e===`dark`)return e}catch{}}function PZ(e){if(typeof document>`u`)return;let t=document.documentElement;t.classList.toggle(`dark`,e===`dark`),t.classList.toggle(`light`,e===`light`),t.style.colorScheme=e;try{window.localStorage.setItem(MZ,e)}catch{}}function FZ({theme:e,defaultTheme:t,onToggle:n,onThemeChange:r,size:i=`$2`,label:a}){let o=e!==void 0,[s,c]=(0,V.useState)(()=>e??t??NZ()??`dark`),l=(o?e:s)===`dark`,u=He(),{t:d}=R();return(0,H.jsx)(Je,{size:i,chromeless:!0,icon:l?(0,H.jsx)(tee,{size:16}):(0,H.jsx)(dm,{size:16}),onPress:()=>{let e=l?`light`:`dark`;u({component:`ThemeToggle`,action:`change`,value:e}),o||(c(e),PZ(e)),n?.(e),r?.(e)},"aria-label":a??d(l?`Switch to light theme`:`Switch to dark theme`)})}var IZ=(0,V.lazy)(()=>Le(()=>import(`./ThemeToggleNext-Bh1CU3Nq.js`),__vite__mapDeps([5,1,2]))),LZ=class extends V.Component{state={failed:!1};static getDerivedStateFromError(){return{failed:!0}}render(){return this.state.failed?this.props.fallback:this.props.children}};function RZ(e){if(e.theme!==void 0||e.onToggle!==void 0||e.onThemeChange!==void 0)return(0,H.jsx)(FZ,{...e});let t=(0,H.jsx)(FZ,{...e});return(0,H.jsx)(LZ,{fallback:t,children:(0,H.jsx)(V.Suspense,{fallback:t,children:(0,H.jsx)(IZ,{size:e.size,label:e.label})})})}var zZ=(0,V.createContext)({}),BZ=()=>(0,V.useContext)(zZ);function VZ(e){let t=typeof e?.status==`number`?e.status:0,n=e instanceof Error?e.message:String(e);return t===503?{kind:`not-initialized`,message:n}:t===404||t===405?{kind:`unavailable`,message:n}:t===501?{kind:`not-implemented`,message:n}:t===402?{kind:`billing`,message:n}:t===401?{kind:`signin`,message:n}:t===403?{kind:`access`,message:n}:{kind:`error`,message:n}}var HZ={"not-initialized":D(`Backend not initialized`),unavailable:D(`Not available on this deployment yet`),"not-implemented":D(`Not yet available`),access:D(`Not enabled for your account`),signin:D(`Your session expired`),billing:D(`Add credits to continue`),error:D(`Could not reach the backend`)},UZ={"not-initialized":D(`The /v1 route is mounted but its runtime (or the console API key it proxies to) is not configured on this deployment yet. Real data appears here once it is — no placeholder data is shown.`),unavailable:D(`This endpoint is not mounted at the gateway on this host yet. The view lights up automatically once the route is live.`),"not-implemented":D(`This capability is planned but not wired yet. The backend answers honestly rather than pretending it worked — nothing here is fabricated, and the view lights up automatically once it ships.`),access:D(`You're signed in, but this isn't enabled for your organization on this deployment, or it's an admin-only surface. It appears here automatically once your account has access — nothing is fabricated.`),signin:D(`Your session has expired or isn’t recognized here. Sign in again to continue where you left off.`),billing:``,error:``};function WZ({state:e,onRetry:t,hint:n}){let{signIn:r,addCredits:i}=BZ(),{t:a}=R();return(0,H.jsxs)(cZ,{borderWidth:1,borderColor:`$borderColor`,p:`$4`,gap:`$2`,maxW:640,children:[(0,H.jsxs)(y,{gap:`$2`,items:`center`,children:[(0,H.jsx)(jm,{size:16}),(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`700`,children:a(HZ[e.kind])})]}),(0,H.jsx)(U,{fontSize:`$3`,color:`$quiet`,children:UZ[e.kind]?a(UZ[e.kind]):e.message}),n?(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:n}):null,e.kind===`signin`&&r?(0,H.jsx)(Je,{size:`$2`,theme:`light`,self:`flex-start`,onPress:r,children:a(`Sign in again`)}):e.kind===`billing`&&i?(0,H.jsxs)(y,{gap:`$2`,items:`center`,flexWrap:`wrap`,children:[(0,H.jsx)(Je,{size:`$2`,theme:`light`,self:`flex-start`,icon:(0,H.jsx)(Ip,{size:14}),onPress:i,children:a(`Add credits`)}),t?(0,H.jsx)(Je,{size:`$2`,self:`flex-start`,onPress:t,children:a(`Retry`)}):null]}):t?(0,H.jsx)(Je,{size:`$2`,self:`flex-start`,onPress:t,children:a(`Retry`)}):null]})}var GZ={fontWeight:`600`,px:`$3`};function KZ({onPress:e,...t}){let n=He(),r=st()===`compact`;return(0,H.jsx)(Je,{bg:`var(--primary)`,color:`var(--primary-foreground)`,borderColor:`var(--primary)`,hoverStyle:{bg:`var(--primary-hover)`,borderColor:`var(--primary-hover)`},pressStyle:{bg:`var(--primary-hover)`,borderColor:`var(--primary-hover)`},onPress:r=>{n({component:`PrimaryButton`,action:`click`,id:qe(t.children)??t[`aria-label`]}),e?.(r)},...r?GZ:null,...t})}function qZ(e){typeof window<`u`&&window.open(e,`_blank`,`noopener`)}function JZ({icon:e,title:t,description:n,bullets:r,primary:i,secondary:a}){let o=He();return(0,H.jsxs)(cZ,{borderWidth:1,borderColor:`$borderColor`,borderStyle:`dashed`,p:`$6`,gap:`$4`,items:`center`,maxW:640,self:`center`,width:`100%`,children:[(0,H.jsx)(z,{width:48,height:48,items:`center`,justify:`center`,rounded:`$4`,bg:`$hover`,children:(0,H.jsx)(e,{size:24})}),(0,H.jsxs)(z,{gap:`$2`,items:`center`,maxW:480,children:[(0,H.jsx)(U,{fontSize:`$6`,fontWeight:`500`,text:`center`,letterSpacing:-.3,children:t}),(0,H.jsx)(U,{fontSize:`$3`,color:`$quiet`,text:`center`,children:n})]}),r&&r.length?(0,H.jsx)(z,{gap:`$2`,self:`stretch`,maxW:420,mx:`auto`,children:r.map(e=>(0,H.jsxs)(y,{gap:`$2`,items:`flex-start`,children:[(0,H.jsx)(z,{pt:`$1`,children:(0,H.jsx)(Vt,{size:14,color:`$soft`})}),(0,H.jsx)(U,{fontSize:`$3`,color:`$quiet`,flex:1,children:e})]},e))}):null,i||a?(0,H.jsxs)(y,{gap:`$2`,items:`center`,flexWrap:`wrap`,justify:`center`,children:[i?(0,H.jsx)(KZ,{icon:i.icon,iconAfter:i.href?(0,H.jsx)(Bp,{size:16}):(0,H.jsx)(hp,{...$m,size:16}),onPress:()=>{o({component:`EmptyState`,action:`click`,id:t,value:i.label}),i.href?qZ(i.href):i.onPress?.()},children:i.label}):null,a?(0,H.jsx)(Je,{chromeless:!0,icon:a.icon,iconAfter:a.href?(0,H.jsx)(Bp,{size:14}):void 0,onPress:()=>{o({component:`EmptyState`,action:`click`,id:t,value:a.label}),a.href?qZ(a.href):a.onPress?.()},children:a.label}):null]}):null]})}var YZ=new Map;function XZ(e,t){YZ.set(e,t)}function ZZ(e){return YZ.get(e)}var QZ={AC:`247`,AD:`376`,AE:`971`,AF:`93`,AG:`1`,AI:`1`,AL:`355`,AM:`374`,AO:`244`,AR:`54`,AS:`1`,AT:`43`,AU:`61`,AW:`297`,AX:`358`,AZ:`994`,BA:`387`,BB:`1`,BD:`880`,BE:`32`,BF:`226`,BG:`359`,BH:`973`,BI:`257`,BJ:`229`,BL:`590`,BM:`1`,BN:`673`,BO:`591`,BQ:`599`,BR:`55`,BS:`1`,BT:`975`,BW:`267`,BY:`375`,BZ:`501`,CA:`1`,CC:`61`,CD:`243`,CF:`236`,CG:`242`,CH:`41`,CI:`225`,CK:`682`,CL:`56`,CM:`237`,CN:`86`,CO:`57`,CR:`506`,CU:`53`,CV:`238`,CW:`599`,CX:`61`,CY:`357`,CZ:`420`,DE:`49`,DJ:`253`,DK:`45`,DM:`1`,DO:`1`,DZ:`213`,EC:`593`,EE:`372`,EG:`20`,EH:`212`,ER:`291`,ES:`34`,ET:`251`,FI:`358`,FJ:`679`,FK:`500`,FM:`691`,FO:`298`,FR:`33`,GA:`241`,GB:`44`,GD:`1`,GE:`995`,GF:`594`,GG:`44`,GH:`233`,GI:`350`,GL:`299`,GM:`220`,GN:`224`,GP:`590`,GQ:`240`,GR:`30`,GT:`502`,GU:`1`,GW:`245`,GY:`592`,HK:`852`,HN:`504`,HR:`385`,HT:`509`,HU:`36`,ID:`62`,IE:`353`,IL:`972`,IM:`44`,IN:`91`,IO:`246`,IQ:`964`,IR:`98`,IS:`354`,IT:`39`,JE:`44`,JM:`1`,JO:`962`,JP:`81`,KE:`254`,KG:`996`,KH:`855`,KI:`686`,KM:`269`,KN:`1`,KP:`850`,KR:`82`,KW:`965`,KY:`1`,KZ:`7`,LA:`856`,LB:`961`,LC:`1`,LI:`423`,LK:`94`,LR:`231`,LS:`266`,LT:`370`,LU:`352`,LV:`371`,LY:`218`,MA:`212`,MC:`377`,MD:`373`,ME:`382`,MF:`590`,MG:`261`,MH:`692`,MK:`389`,ML:`223`,MM:`95`,MN:`976`,MO:`853`,MP:`1`,MQ:`596`,MR:`222`,MS:`1`,MT:`356`,MU:`230`,MV:`960`,MW:`265`,MX:`52`,MY:`60`,MZ:`258`,NA:`264`,NC:`687`,NE:`227`,NF:`672`,NG:`234`,NI:`505`,NL:`31`,NO:`47`,NP:`977`,NR:`674`,NU:`683`,NZ:`64`,OM:`968`,PA:`507`,PE:`51`,PF:`689`,PG:`675`,PH:`63`,PK:`92`,PL:`48`,PM:`508`,PR:`1`,PS:`970`,PT:`351`,PW:`680`,PY:`595`,QA:`974`,RE:`262`,RO:`40`,RS:`381`,RU:`7`,RW:`250`,SA:`966`,SB:`677`,SC:`248`,SD:`249`,SE:`46`,SG:`65`,SH:`290`,SI:`386`,SJ:`47`,SK:`421`,SL:`232`,SM:`378`,SN:`221`,SO:`252`,SR:`597`,SS:`211`,ST:`239`,SV:`503`,SX:`1`,SY:`963`,SZ:`268`,TA:`290`,TC:`1`,TD:`235`,TG:`228`,TH:`66`,TJ:`992`,TK:`690`,TL:`670`,TM:`993`,TN:`216`,TO:`676`,TR:`90`,TT:`1`,TV:`688`,TW:`886`,TZ:`255`,UA:`380`,UG:`256`,US:`1`,UY:`598`,UZ:`998`,VA:`39`,VC:`1`,VE:`58`,VG:`1`,VI:`1`,VN:`84`,VU:`678`,WF:`681`,WS:`685`,XK:`383`,YE:`967`,YT:`262`,ZA:`27`,ZM:`260`,ZW:`263`},$Z=e=>e==null?``:String(e),eQ=e=>{if(e==null||e===``)return null;let t=typeof e==`number`?e:Number(e);return Number.isFinite(t)?t:null},tQ=e=>Array.isArray(e)?e:e==null||e===``?[]:[e],nQ=e=>{if(e==null||e===``)return``;if(e instanceof Date)return Number.isNaN(e.getTime())?``:e.toISOString().slice(0,10);let t=String(e),n=t.match(/^(\d{4}-\d{2}-\d{2})/);if(n)return n[1];let r=new Date(t);return Number.isNaN(r.getTime())?``:r.toISOString().slice(0,10)},rQ=e=>{if(e==null||e===``)return null;let t=e instanceof Date?e:new Date(e);return Number.isNaN(t.getTime())?null:t},iQ=e=>{if(e==null||e===``)return{};if(typeof e==`string`){let t=e.trim(),n=t.indexOf(` `);return n<0?{first:t}:{first:t.slice(0,n),last:t.slice(n+1).trim()}}if(typeof e!=`object`)return{first:String(e)};let t=e;return{first:$Z(t.first??t.firstName).trim()||void 0,last:$Z(t.last??t.lastName).trim()||void 0}},aQ=e=>{let t=iQ(e);return[t.first,t.last].filter(Boolean).join(` `)},oQ=[`street1`,`street2`,`city`,`state`,`postcode`,`country`],sQ=e=>{if(e==null||e===``)return{};if(typeof e==`string`)return{street1:e};let t=e,n={},r={street1:`addressStreet1`,street2:`addressStreet2`,city:`addressCity`,state:`addressState`,postcode:`addressPostcode`,country:`addressCountry`};for(let e of oQ){let i=$Z(t[e]??t[r[e]]).trim();i&&(n[e]=i)}return n},cQ=(e,t)=>{if(!e)return``;if(!/^[A-Za-z]{2}$/.test(e))return e;try{return new Intl.DisplayNames(t?[t]:void 0,{type:`region`}).of(e.toUpperCase())??e}catch{return e}},lQ=(e,t)=>{let n=sQ(e);return oQ.map(e=>e===`country`?cQ(n.country,t):n[e]).filter(Boolean).join(`, `)},uQ=e=>tQ(e).map(e=>typeof e==`string`?{url:e}:e).filter(e=>!!e&&typeof e.url==`string`&&e.url.trim()!==``),dQ=e=>{let t=e.trim();try{let e=new URL(/^[a-z][a-z0-9+.-]*:/i.test(t)?t:`https://${t}`);return e.host.replace(/^www\./,``)+(e.pathname===`/`?``:e.pathname.replace(/\/$/,``))}catch{return t}},fQ=e=>{let t=e.trim();if(!t)return;let n=/^[a-z][a-z0-9+.-]*:/i.test(t)?t:`https://${t}`;try{let e=new URL(n);return[`http:`,`https:`,`mailto:`,`tel:`].includes(e.protocol)?e.href:void 0}catch{return}},pQ=e=>{if(e&&typeof e==`object`&&!Array.isArray(e)){let t=e;return[$Z(t.primaryEmail),...tQ(t.additionalEmails).map($Z)].map(e=>e.trim()).filter(Boolean)}return tQ(e).flatMap(e=>$Z(e).split(/[,;]/)).map(e=>e.trim()).filter(Boolean)},mQ=e=>/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e.trim()),hQ=(()=>{let e={};for(let[t,n]of Object.entries(QZ))(e[n]??=[]).push(t);for(let[t,n]of Object.entries({1:`US`,7:`RU`,44:`GB`,47:`NO`,61:`AU`,212:`MA`,262:`RE`,290:`SH`,358:`FI`,590:`GP`,599:`CW`})){let r=e[t];r?.includes(n)&&(e[t]=[n,...r.filter(e=>e!==n)])}return e})(),gQ=(e,t)=>{if(e&&typeof e==`object`){let t=e,n=$Z(t.number??t.primaryPhoneNumber).trim(),r=$Z(t.country??t.countryCode??t.primaryPhoneCountryCode).trim().toUpperCase()||void 0;return{country:r,callingCode:$Z(t.callingCode??t.primaryPhoneCallingCode).replace(/^\+/,``).trim()||(r?QZ[r]:void 0),number:n}}let n=$Z(e).trim();if(!n.startsWith(`+`)){let e=t?.toUpperCase();return{country:e,callingCode:e?QZ[e]:void 0,number:n}}let r=n.slice(1).replace(/[^\d]/g,``);for(let e=Math.min(4,r.length);e>0;e--){let i=r.slice(0,e),a=hQ[i];if(a)return{country:t&&a.includes(t.toUpperCase())?t.toUpperCase():a[0],callingCode:i,number:_Q(n.slice(1),e)}}return{number:n}},_Q=(e,t)=>{let n=0,r=0;for(;r<e.length&&n<t;)/\d/.test(e[r++])&&n++;return e.slice(r).replace(/^[\s.()-]+/,``).trim()},vQ=e=>{let t=e.number.trim();return t?e.callingCode?`+${e.callingCode} ${t.replace(/^0+(?=\d)/,``)}`:t:``},yQ=e=>{let t=e.number.replace(/[^\d]/g,``).replace(/^0+(?=\d)/,``);if(t)return`tel:${e.callingCode?`+${e.callingCode}`:``}${t}`},bQ=e=>{if(e==null||e===``)return null;if(typeof e==`string`)return{name:e};let t=e,n=$Z(t.name??t.workspaceMemberName??t.label).trim();return n?{name:n,source:$Z(t.source).toLowerCase()||void 0,avatarUrl:$Z(t.avatarUrl).trim()||void 0}:null},xQ=e=>{if(e==null||e===``)return``;if(typeof e==`object`){let t=e;return typeof t.markdown==`string`&&t.markdown.trim()?xQ(t.markdown):`blocknote`in t||`content`in t||`type`in t||Array.isArray(e)?xQ(SQ(e).join(`
|
|
175
|
+
`)):``}for(let t of String(e).split(`
|
|
176
|
+
`)){let e=t.replace(/^\s{0,3}(#{1,6}\s+|>\s?|[-*+]\s+|\d+[.)]\s+|-\s\[[ x]\]\s+)/i,``).replace(/!\[[^\]]*\]\([^)]*\)/g,``).replace(/\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/(\*\*|__|\*|_|~~|`)/g,``).trim();if(e)return e}return``},SQ=e=>{if(typeof e==`string`)try{return SQ(JSON.parse(e))}catch{return[e]}if(Array.isArray(e))return e.flatMap(SQ);if(e&&typeof e==`object`){let t=e,n=typeof t.text==`string`?[t.text]:[],r=[t.content,t.children,t.blocknote].flatMap(e=>e==null?[]:SQ(e));return t.type&&r.length?[[...n,...r].join(``)]:[...n,...r]}return[]},CQ=(e,t)=>{if(typeof t==`string`)return t;if(t&&typeof t==`object`){let n=t;return $Z(n[e]??n.label??n.name??n.id)}return``};function wQ(){return(0,H.jsx)(U,{fontSize:`$2`,color:`var(--text-faint)`,"aria-label":`Empty`,children:`—`})}var TQ=({text:e,color:t=`$ink`,mono:n})=>(0,H.jsx)(nR,{text:e,size:`$2`,color:t,...n?{fontFamily:`$mono`}:null}),EQ={target:`_blank`,rel:`noopener noreferrer`};function DQ({label:e,color:t}){return(0,H.jsx)(oR,{color:t??`gray`,children:e})}var OQ=(e,t)=>e?.find(e=>e.value===t)??{value:t,label:t};function kQ({value:e}){let t=$Z(e).trim();return t?(0,H.jsx)(TQ,{text:t}):(0,H.jsx)(wQ,{})}function AQ({value:e}){let t=$Z(e).trim();return t?(0,H.jsx)(nR,{text:t,lineClamp:2,size:`$2`,color:`$ink`,isTooltipMultiline:!0}):(0,H.jsx)(wQ,{})}function jQ({value:e}){let t=xQ(e);return t?(0,H.jsx)(TQ,{text:t,color:`$aside`}):(0,H.jsx)(wQ,{})}function MQ({value:e}){let t=pQ(e);return t.length===0?(0,H.jsx)(wQ,{}):(0,H.jsx)(s$,{children:t.map((e,t)=>(0,H.jsx)(lR,{shape:`round`,variant:`soft`,label:e,href:`mailto:${e}`},`${e}-${t}`))})}var NQ=({url:e,label:t})=>{let n=fQ(e);return(0,H.jsx)(lR,{shape:`round`,variant:`soft`,label:t?.trim()||dQ(e),tooltipContent:e,...n?{href:n,...EQ}:null})};function PQ({value:e}){let t=uQ(e);return t.length===0?(0,H.jsx)(wQ,{}):t.length===1?(0,H.jsx)(NQ,{url:t[0].url,label:t[0].label}):(0,H.jsx)(s$,{children:t.map((e,t)=>(0,H.jsx)(NQ,{url:e.url,label:e.label},`${e.url}-${t}`))})}function FQ({value:e}){let t=uQ(e);return t.length===0?(0,H.jsx)(wQ,{}):(0,H.jsx)(s$,{children:t.map((e,t)=>(0,H.jsx)(NQ,{url:e.url,label:e.label},`${e.url}-${t}`))})}function IQ({field:e,value:t}){let n=e.metadata?.defaultCountry,r=(Array.isArray(t)?t:[t]).map(e=>gQ(e,n)).filter(e=>e.number);return r.length===0?(0,H.jsx)(wQ,{}):(0,H.jsx)(s$,{children:r.map((e,t)=>{let n=yQ(e);return(0,H.jsx)(lR,{shape:`round`,variant:`soft`,label:vQ(e),...n?{href:n}:null},`${e.number}-${t}`)})})}var LQ={fontVariant:[`tabular-nums`]},RQ=({text:e})=>(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,numberOfLines:1,...LQ,children:e});function zQ({field:e,value:t}){let n=eQ(t);if(n==null)return(0,H.jsx)(wQ,{});let r=e.metadata??{},i=r.decimals==null?n.toLocaleString():n.toLocaleString(void 0,{minimumFractionDigits:r.decimals,maximumFractionDigits:r.decimals});return(0,H.jsx)(RQ,{text:`${r.prefix??``}${i}${r.suffix??``}`})}function BQ({field:e,value:t}){let n=eQ(t);if(n==null)return(0,H.jsx)(wQ,{});let r=(e.metadata??{}).decimals??0;return(0,H.jsx)(RQ,{text:`${n.toLocaleString(void 0,{minimumFractionDigits:r,maximumFractionDigits:r})}%`})}function VQ({field:e,value:t}){let n=e.metadata??{},r=t??{},i=eQ(typeof r==`object`&&r?r.amount:t);if(i==null)return(0,H.jsx)(wQ,{});let a=typeof r==`object`&&r?.currencyCode||n.currencyCode||`USD`,o;try{o=new Intl.NumberFormat(void 0,{style:`currency`,currency:a,maximumFractionDigits:n.decimals??2}).format(i)}catch{o=`${i} ${a}`}return(0,H.jsx)(RQ,{text:o})}function HQ({value:e,max:t,hover:n}){let r=A().aside?.get?.()??`currentColor`,i=n??e;return(0,H.jsx)(y,{items:`center`,gap:2,"aria-hidden":!0,children:Array.from({length:t},(e,t)=>t+1).map(e=>(0,H.jsx)(Em,{size:16,color:e<=i?`$aside`:`$raised`,fill:e<=i?r:`none`},e))})}function UQ({field:e,value:t}){let n=(e.metadata??{}).max??5,r=Math.max(0,Math.min(n,Math.round(eQ(t)??0)));return(0,H.jsx)(y,{role:`img`,"aria-label":`${r} of ${n}`,children:(0,H.jsx)(HQ,{value:r,max:n})})}function WQ({field:e,value:t}){if(t==null||t===``)return(0,H.jsx)(wQ,{});let n=e.metadata??{},r=t===!0||t===`true`||t===1;return(0,H.jsxs)(y,{items:`center`,gap:`$1`,height:20,children:[(0,H.jsx)(r?Vt:Rn,{size:14,color:`$aside`}),(0,H.jsx)(U,{fontSize:`$2`,color:`$aside`,children:r?n.trueLabel??`Yes`:n.falseLabel??`No`})]})}function GQ({field:e,value:t}){let n=$Z(t);if(!n)return(0,H.jsx)(wQ,{});let r=e.metadata?.options,i=OQ(r,n);return(0,H.jsx)(DQ,{label:i.label,color:i.color})}function KQ({field:e,value:t}){let n=tQ(t).map($Z).filter(Boolean);if(n.length===0)return(0,H.jsx)(wQ,{});let r=e.metadata?.options;return(0,H.jsx)(s$,{children:n.map(e=>{let t=OQ(r,e);return(0,H.jsx)(DQ,{label:t.label,color:t.color},e)})})}var qQ=[[`year`,31536e3],[`month`,2592e3],[`week`,604800],[`day`,86400],[`hour`,3600],[`minute`,60]],JQ=(e,t=Date.now())=>{let n=(e.getTime()-t)/1e3,r=new Intl.RelativeTimeFormat(void 0,{numeric:`auto`});for(let[e,t]of qQ)if(Math.abs(n)>=t)return r.format(Math.round(n/t),e);return r.format(Math.round(n),`second`)};function YQ({field:e,value:t}){let n=nQ(t);if(!n)return(0,H.jsx)(wQ,{});let r=new Date(`${n}T00:00:00Z`);if(e.metadata?.display===`relative`){let e=new Date(new Date().toISOString().slice(0,10)+`T00:00:00Z`);return(0,H.jsx)(TQ,{text:JQ(r,e.getTime())})}return(0,H.jsx)(TQ,{text:r.toLocaleDateString(void 0,{timeZone:`UTC`,year:`numeric`,month:`short`,day:`numeric`})})}function XQ({field:e,value:t}){let n=rQ(t);if(!n)return(0,H.jsx)(wQ,{});let r=e.metadata?.display===`relative`;return(0,H.jsx)(TQ,{text:r?JQ(n):n.toLocaleString(void 0,{year:`numeric`,month:`short`,day:`numeric`,hour:`numeric`,minute:`2-digit`,timeZoneName:`short`})})}function ZQ({label:e,seed:t,src:n,shape:r=`square`,href:i,onPress:a}){return(0,H.jsx)(lR,{label:e,startElement:(0,H.jsx)(Hh,{size:`md`,shape:r===`circle`?`circle`:`square`,name:e,colorSeed:t??e,src:n??null}),...i?{href:i}:null,...a?{onPress:a}:null})}function QQ({field:e,value:t}){let n=e.metadata??{},r=n.labelField??`name`,i=tQ(t).map(e=>{let t=CQ(r,e),i=e&&typeof e==`object`?e:null,a=i&&$Z(i[n.avatarField??`avatarUrl`]).trim()||void 0;return{label:t,seed:i&&$Z(i.id)||t,src:a}}).filter(e=>e.label);if(i.length===0)return(0,H.jsx)(wQ,{});let a=i.map((e,t)=>(0,H.jsx)(ZQ,{label:e.label,seed:e.seed,src:e.src,shape:n.shape},`${e.seed}-${t}`));return i.length===1?a[0]:(0,H.jsx)(s$,{children:a})}var $Q={api:jp,import:Nm,email:im,calendar:Cp,workflow:zm,webhook:Lm,system:vp,manual:Rp};function e$({value:e}){let t=bQ(e);if(!t)return(0,H.jsx)(wQ,{});let n=t.source&&t.source!==`member`?$Q[t.source]:void 0;return(0,H.jsx)(lR,{label:t.name,startElement:n?(0,H.jsx)(n,{size:14,color:`$hint`}):(0,H.jsx)(Hh,{size:`md`,shape:`circle`,name:t.name,src:t.avatarUrl??null})})}function t$({value:e}){let t=aQ(e);return t?(0,H.jsx)(TQ,{text:t}):(0,H.jsx)(wQ,{})}function n$({value:e}){let t=lQ(e);return t?(0,H.jsx)(TQ,{text:t}):(0,H.jsx)(wQ,{})}function r$({value:e}){let t=$Z(e);return t?(0,H.jsx)(TQ,{text:t,color:`$hint`,mono:!0}):(0,H.jsx)(wQ,{})}function i$({value:e}){let t=tQ(e).map(e=>typeof e==`string`?{name:e}:e).map(e=>({name:$Z(e?.label??e?.name).trim()||`file`,url:$Z(e?.url).trim()}));return t.length===0?(0,H.jsx)(wQ,{}):(0,H.jsx)(s$,{children:t.map((e,t)=>{let n=e.url?fQ(e.url):void 0;return(0,H.jsx)(lR,{variant:`soft`,label:e.name,maxW:120,startElement:(0,H.jsx)(pm,{size:14,color:`$hint`}),...n?{href:n,...EQ}:null},`${e.name}-${t}`)})})}function a$({value:e}){if(e==null)return(0,H.jsx)(wQ,{});let t;try{t=JSON.stringify(e)}catch{t=String(e)}return(0,H.jsx)(TQ,{text:t,color:`$hint`,mono:!0})}function o$({value:e}){if(typeof e==`object`&&e)return(0,H.jsx)(a$,{field:{name:``,label:``,type:`json`},value:e});let t=$Z(e);return t?(0,H.jsx)(TQ,{text:t}):(0,H.jsx)(wQ,{})}function s$({children:e}){return(0,H.jsx)(mR,{flex:1,minW:0,children:e})}var c$=e=>{let t=new Map;return n=>{let r=n??``,i=t.get(r);return i===void 0&&t.set(r,i=e(n)),i}},l$=(e,t)=>{try{return new Intl.DisplayNames(e?[e]:void 0,{type:t})}catch{return null}},u$=c$(e=>{let t=l$(e,`region`),n=new Intl.Collator(e);return Object.entries(QZ).map(([e,n])=>{let r=e;try{r=t?.of(e)??e}catch{r=e}return{value:e,label:r,callingCode:n}}).sort((e,t)=>n.compare(e.label,t.label))}),d$=(e,t)=>{try{let n=new Intl.NumberFormat(t,{style:`currency`,currency:e,currencyDisplay:`narrowSymbol`}).formatToParts(0).find(e=>e.type===`currency`)?.value;return n&&n!==e?n:void 0}catch{return}},f$=c$(e=>{let t=Intl.supportedValuesOf,n=t?t(`currency`):[`USD`,`EUR`,`GBP`,`JPY`,`CNY`,`CAD`,`AUD`,`CHF`,`INR`,`BRL`],r=l$(e,`currency`);return n.map(t=>{let n=t;try{n=r?.of(t)??t}catch{n=t}return{code:t,name:n,symbol:d$(t,e)}})}),p$=e=>e.field.metadata?.options??[],m$=(e,t)=>{let n=e=>e.normalize(`NFD`).replace(/\p{M}/gu,``).toLowerCase(),r=n(t.trim());return r?e.filter(e=>n(e.label).includes(r)||n(e.value).includes(r)):e};function h$({onSubmit:e,onCancel:t,multiline:n,children:r}){return(0,H.jsx)(z,{width:`100%`,minW:0,onKeyDown:r=>{r.nativeEvent?.isComposing||(r.key===`Enter`&&!(n&&r.shiftKey)?(r.preventDefault?.(),e?.()):r.key===`Escape`&&(r.preventDefault?.(),t?.()))},children:r})}var g$=e=>e.field.label;function _$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.metadata?.placeholder;return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsx)(j_,{"aria-label":e.label,value:$Z(t),onChangeText:e=>n(e),placeholder:o,autoFocus:a})})}function v$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=$Z(Array.isArray(t)?t[0]:t),s=e.metadata?.placeholder??`name@example.com`;return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsx)(j_,{"aria-label":e.label,type:`email`,inputMode:`email`,autoComplete:`email`,value:o,onChangeText:e=>n(e.trim()),placeholder:s,autoFocus:a,"aria-invalid":o!==``&&!mQ(o)||void 0})})}function y$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=$Z(typeof t==`object`&&t&&!Array.isArray(t)?t.url:t),s=e.metadata?.placeholder??`https://`;return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsx)(j_,{"aria-label":e.label,type:`url`,inputMode:`url`,value:o,onChangeText:e=>n(e.trim()),placeholder:s,autoFocus:a})})}function b$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.metadata??{},s=gQ(t,o.defaultCountry),[c,l]=(0,V.useState)(s.country??o.defaultCountry?.toUpperCase()),u=(0,V.useMemo)(()=>u$(),[]),d=(e,r)=>{let i=e?QZ[e]:void 0;n(typeof t==`object`&&t&&!Array.isArray(t)?{...t,number:r,countryCode:e,callingCode:i?`+${i}`:void 0}:r.trim()?i?`+${i} ${r.trim()}`:r.trim():null)};return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsxs)(D_,{children:[(0,H.jsx)(MR,{countries:u,value:c??null,onValueChange:e=>{l(e??void 0),d(e??void 0,s.number)}}),(0,H.jsx)(j_,{"aria-label":e.label,type:`tel`,inputMode:`tel`,autoComplete:`tel`,value:s.number,onChangeText:e=>d(c,e),placeholder:o.placeholder??`Phone number`,autoFocus:a})]})})}function x$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.metadata??{};return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,multiline:!0,children:(0,H.jsx)(_v,{"aria-label":e.label,value:$Z(t),onChangeText:e=>n(e),placeholder:o.placeholder,autoFocus:a,rows:o.rows??3,maxRows:o.rows&&o.rows>10?o.rows:10})})}function S$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.metadata??{};return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsx)(SR,{"aria-label":e.label,value:eQ(t),onValueChange:e=>n(e),placeholder:o.placeholder,autoFocus:a,allowOutOfRange:!0,...o.decimals==null?null:{format:{maximumFractionDigits:o.decimals}}})})}function C$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=(e.metadata??{}).decimals;return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsx)(D_,{end:(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:`%`}),children:(0,H.jsx)(SR,{"aria-label":e.label,value:eQ(t),onValueChange:e=>n(e),autoFocus:a,allowOutOfRange:!0,...o==null?null:{format:{maximumFractionDigits:o}}})})})}function w$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.metadata??{},s=t??{},c=eQ(typeof s==`object`&&s?s.amount:t),l=typeof s==`object`&&s?.currencyCode||o.currencyCode||`USD`,u=(0,V.useMemo)(()=>f$(),[]);return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsxs)(D_,{children:[(0,H.jsx)(kR,{currencies:u,value:l,onValueChange:e=>n({amount:c,currencyCode:e??l}),selectedFirst:!0}),(0,H.jsx)(SR,{"aria-label":e.label,value:c,onValueChange:e=>n({amount:e,currencyCode:l}),autoFocus:a,allowOutOfRange:!0,format:{maximumFractionDigits:o.decimals??2}})]})})}function T$({field:e,value:t,onChange:n}){let r=(e.metadata??{}).max??5,i=Math.max(0,Math.min(r,Math.round(eQ(t)??0))),[a,o]=(0,V.useState)(null),s=e=>n(Math.max(0,Math.min(r,e)));return(0,H.jsx)(y,{role:`slider`,tabIndex:0,onKeyDown:e=>{let t=e.key===`ArrowRight`||e.key===`ArrowUp`?i+1:e.key===`ArrowLeft`||e.key===`ArrowDown`?i-1:e.key===`Home`?0:e.key===`End`?r:null;t!=null&&(e.preventDefault?.(),s(t))},"aria-label":e.label,"aria-valuemin":0,"aria-valuemax":r,"aria-valuenow":i,"aria-valuetext":`${i} of ${r}`,items:`center`,height:20,rounded:`$xs`,focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},onHoverOut:()=>o(null),children:(0,H.jsxs)(y,{position:`relative`,children:[(0,H.jsx)(HQ,{value:i,max:r,hover:a}),(0,H.jsx)(y,{position:`absolute`,t:0,l:0,r:0,b:0,children:Array.from({length:r},(e,t)=>t+1).map(e=>(0,H.jsx)(y,{flex:1,cursor:`pointer`,onHoverIn:()=>o(e),onPress:()=>s(e===i?0:e),"data-star":e},e))})]})})}function E$({field:e,value:t,onChange:n}){let r=e.metadata??{},i=t===!0||t===`true`||t===1;return(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(av,{"aria-label":e.label,checked:i,onCheckedChange:e=>n(e)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$aside`,children:i?r.trueLabel??`Yes`:r.falseLabel??`No`})]})}function D$({children:e,...t}){return(0,H.jsx)(W,{variant:`outline`,width:`100%`,justify:`space-between`,endIcon:(0,H.jsx)(wp,{color:`$hint`}),...t,children:(0,H.jsx)(y,{flex:1,minW:0,items:`center`,gap:`$1`,overflow:`hidden`,children:e})})}var O$=({text:e})=>(0,H.jsx)(U,{fontSize:`$2`,color:`$hush`,numberOfLines:1,children:e}),k$=e=>(0,V.useState)(!!e);function A$(e){let{value:t,onChange:n,autoFocus:r}=e,i=p$(e),[a,o]=k$(r),[s,c]=(0,V.useState)(``),l=$Z(t),u=i.find(e=>e.value===l),d=m$(i,s);return(0,H.jsxs)(Bg,{open:a,onOpenChange:e=>{o(e),e||c(``)},children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(D$,{"aria-label":g$(e),children:u?(0,H.jsx)(DQ,{label:u.label,color:u.color}):(0,H.jsx)(O$,{text:`Select…`})})}),(0,H.jsxs)(Kg,{minW:240,children:[(0,H.jsx)(n_,{value:s,onValueChange:c,placeholder:`Search options`,"aria-label":`Search ${g$(e)}`}),l?(0,H.jsx)(Xg,{onSelect:()=>n(null),children:`No ${g$(e)}`}):null,(0,H.jsx)(e_,{value:l||null,onValueChange:e=>n(e??null),children:(0,H.jsx)(r_,{scrollable:!0,children:d.map(e=>(0,H.jsx)(t_,{value:e.value,children:(0,H.jsx)(DQ,{label:e.label,color:e.color})},e.value))})}),d.length===0?(0,H.jsx)(u_,{children:`No options`}):null]})]})}function j$(e){let{value:t,onChange:n,autoFocus:r}=e,i=p$(e),[a,o]=k$(r),[s,c]=(0,V.useState)(``),l=tQ(t).map($Z).filter(Boolean),u=m$(i,s);return(0,H.jsxs)(Bg,{open:a,onOpenChange:e=>{o(e),e||c(``)},children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(D$,{"aria-label":g$(e),children:l.length>0?l.map(e=>{let t=i.find(t=>t.value===e)??{value:e,label:e};return(0,H.jsx)(DQ,{label:t.label,color:t.color},e)}):(0,H.jsx)(O$,{text:`Select…`})})}),(0,H.jsxs)(Kg,{minW:240,children:[(0,H.jsx)(n_,{value:s,onValueChange:c,placeholder:`Search options`,"aria-label":`Search ${g$(e)}`}),(0,H.jsx)(e_,{multiple:!0,value:l,onValueChange:e=>n(tQ(e).map($Z)),children:(0,H.jsx)(r_,{scrollable:!0,children:u.map(e=>(0,H.jsx)(t_,{value:e.value,children:(0,H.jsx)(DQ,{label:e.label,color:e.color})},e.value))})}),u.length===0?(0,H.jsx)(u_,{children:`No options`}):null]})]})}function M$(e){let{field:t,value:n,onChange:r,onSubmit:i,onCancel:a,autoFocus:o}=e,s=p$(e),c=(t.metadata??{}).shape??`square`,[l,u]=k$(o),[d,f]=(0,V.useState)(``);if(s.length===0){let e=$Z(typeof n==`object`&&n?n.name??n.id:n);return(0,H.jsx)(h$,{onSubmit:i,onCancel:a,children:(0,H.jsx)(j_,{"aria-label":t.label,value:e,onChangeText:e=>r(e),placeholder:`Related record id…`,autoFocus:o})})}let p=$Z(typeof n==`object`&&n?n.id??n.value:n),m=s.find(e=>e.value===p),h=m$(s,d),g=e=>(0,H.jsxs)(y,{items:`center`,gap:`$2`,minW:0,children:[(0,H.jsx)(Hh,{size:`md`,shape:c,name:e.label,colorSeed:e.value,src:e.avatarUrl??null}),(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,numberOfLines:1,children:e.label})]});return(0,H.jsxs)(Bg,{open:l,onOpenChange:e=>{u(e),e||f(``)},children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(D$,{"aria-label":t.label,children:m?g(m):(0,H.jsx)(O$,{text:`Link a record…`})})}),(0,H.jsxs)(Kg,{minW:280,children:[(0,H.jsx)(n_,{value:d,onValueChange:f,placeholder:`Search records`,"aria-label":`Search ${t.label}`}),p?(0,H.jsx)(Xg,{onSelect:()=>r(null),children:`No ${t.label}`}):null,(0,H.jsx)(e_,{value:p||null,onValueChange:e=>r(e??null),children:(0,H.jsx)(r_,{scrollable:!0,children:h.map(e=>(0,H.jsx)(t_,{value:e.value,children:g(e)},e.value))})}),h.length===0?(0,H.jsx)(u_,{children:`No record found`}):null]})]})}var N$=e=>String(e).padStart(2,`0`),P$=e=>{let[t,n,r]=e.split(`-`).map(Number);return new Date(t,n-1,r)},F$=e=>`${e.getFullYear()}-${N$(e.getMonth()+1)}-${N$(e.getDate())}`;function I$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=e.type===`dateTime`,[s,c]=k$(a),l=o&&t!=null&&t!==``?new Date(t):null,u=o&&l&&!Number.isNaN(l.getTime())?F$(l):nQ(t),d=l&&!Number.isNaN(l.getTime())?`${N$(l.getHours())}:${N$(l.getMinutes())}`:``,[f,p]=(0,V.useState)(null),m=(e,t=d)=>{if(!e)return n(null);if(!o)return n(e);let r=new Date(`${e}T${/^\d{2}:\d{2}$/.test(t)?t:`00:00`}`);n(Number.isNaN(r.getTime())?null:r.toISOString())},h=u?P$(u).toLocaleDateString(void 0,{year:`numeric`,month:`short`,day:`numeric`})+(o&&d?` ${d}`:``):``;return(0,H.jsxs)(I_,{open:s,onOpenChange:c,placement:`bottom-start`,children:[(0,H.jsx)(L_,{asChild:!0,children:(0,H.jsxs)(D$,{"aria-label":e.label,children:[(0,H.jsx)(Cp,{size:14,color:`$hint`}),h?(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,numberOfLines:1,children:h}):(0,H.jsx)(O$,{text:`Pick a date…`})]})}),(0,H.jsx)(R_,{size:`sm`,width:280,children:(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsxs)(y,{gap:`$1`,children:[(0,H.jsx)(j_,{"aria-label":`${e.label}, as YYYY-MM-DD`,size:`sm`,flex:1,value:f??u,placeholder:`YYYY-MM-DD`,onChangeText:e=>{p(e),/^\d{4}-\d{2}-\d{2}$/.test(e)&&!Number.isNaN(P$(e).getTime())?m(e):e===``&&m(``)},onBlur:()=>p(null)}),o?(0,H.jsx)(j_,{"aria-label":`${e.label}, time`,size:`sm`,width:72,value:d,placeholder:`HH:mm`,onChangeText:e=>{/^\d{2}:\d{2}$/.test(e)&&m(u||F$(new Date),e)}}):null]}),(0,H.jsx)(Hee,{mode:`single`,selected:u?P$(u):void 0,defaultMonth:u?P$(u):void 0,onSelect:e=>{m(e?F$(e):``),o||c(!1)}}),u?(0,H.jsx)(W,{size:`xs`,variant:`ghost`,emphasis:`subtle`,onPress:()=>{m(``),c(!1)},children:`Clear`}):null]})})})]})}function L$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=uQ(t),[s,c]=(0,V.useState)(``);return(0,H.jsxs)(z,{gap:`$1`,width:`100%`,minW:0,children:[o.map((e,t)=>(0,H.jsxs)(y,{items:`center`,gap:`$2`,minH:24,children:[(0,H.jsx)(U,{flex:1,minW:0,fontSize:`$2`,color:`$ink`,numberOfLines:1,children:e.label?.trim()||dQ(e.url)}),(0,H.jsx)(W,{size:`icon-2xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Remove ${e.label?.trim()||dQ(e.url)}`,onPress:()=>n(o.filter((e,n)=>n!==t)),children:(0,H.jsx)(Rn,{})})]},`${e.url}-${t}`)),(0,H.jsx)(h$,{onSubmit:()=>{let e=s.trim();if(!e)return r?.();n([...o,{url:e}]),c(``)},onCancel:i,children:(0,H.jsx)(j_,{"aria-label":`Add to ${e.label}`,type:`url`,inputMode:`url`,value:s,onChangeText:c,placeholder:`Add a link`,autoFocus:a})})]})}function R$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=iQ(t),s=(e,t)=>n(!e?.trim()&&!t?.trim()?null:{first:e??``,last:t??``});return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsxs)(y,{gap:`$1`,children:[(0,H.jsx)(j_,{"aria-label":`${e.label}, first name`,flex:1,value:o.first??``,placeholder:`First name`,autoFocus:a,onChangeText:e=>{let t=iQ(e);t.last&&!o.last&&e.includes(` `)?s(t.first,t.last):s(e,o.last)}}),(0,H.jsx)(j_,{"aria-label":`${e.label}, last name`,flex:1,value:o.last??``,placeholder:`Last name`,onChangeText:e=>s(o.first,e)})]})})}var z$={street1:`Address 1`,street2:`Address 2`,city:`City`,state:`State`,postcode:`Post code`,country:`Country`};function B$({field:e,value:t,onChange:n,onSubmit:r,onCancel:i,autoFocus:a}){let o=(e.metadata??{}).defaultCountry,s=sQ(t),c=(0,V.useMemo)(()=>u$().map(e=>({value:e.value,label:e.label})),[]),l=(e,t)=>{let r={...s,[e]:t??void 0};t||delete r[e],n(Object.keys(r).length?r:null)};return(0,H.jsx)(h$,{onSubmit:r,onCancel:i,children:(0,H.jsxs)(z,{gap:`$1`,width:344,maxW:`100%`,children:[[`street1`,`street2`].map((e,t)=>(0,H.jsx)(j_,{"aria-label":z$[e],placeholder:z$[e],value:s[e]??``,autoFocus:a&&t===0,onChangeText:t=>l(e,t)},e)),(0,H.jsxs)(y,{gap:`$1`,children:[(0,H.jsx)(j_,{"aria-label":z$.city,placeholder:z$.city,flex:1,value:s.city??``,onChangeText:e=>l(`city`,e)}),(0,H.jsx)(j_,{"aria-label":z$.state,placeholder:z$.state,flex:1,value:s.state??``,onChangeText:e=>l(`state`,e)})]}),(0,H.jsxs)(y,{gap:`$1`,children:[(0,H.jsx)(j_,{"aria-label":z$.postcode,placeholder:z$.postcode,flex:1,value:s.postcode??``,onChangeText:e=>l(`postcode`,e)}),(0,H.jsx)(z,{flex:1,minW:0,children:(0,H.jsx)(FR,{"aria-label":z$.country,countries:c,value:(s.country&&/^[A-Za-z]{2}$/.test(s.country)?s.country.toUpperCase():null)??o?.toUpperCase()??null,onValueChange:e=>l(`country`,e)})})]})]})})}function V$({value:e,onChange:t}){let n=tQ(e),r=e=>typeof e==`string`?e:$Z(e?.label??e?.name??`file`);return(0,H.jsxs)(z,{gap:`$2`,children:[typeof document<`u`?(0,H.jsx)(W,{size:`sm`,variant:`outline`,startIcon:(0,H.jsx)(Nm,{}),onPress:()=>{if(typeof document>`u`)return;let e=document.createElement(`input`);e.type=`file`,e.multiple=!0,e.onchange=()=>t(e.files?[...n,...Array.from(e.files)]:n),e.click()},self:`flex-start`,children:`Choose files`}):(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:`File upload is available on the web.`}),n.length>0?(0,H.jsx)(y,{gap:`$1`,flexWrap:`wrap`,children:n.map((e,i)=>(0,H.jsxs)(y,{items:`center`,gap:`$1`,height:24,pl:`$2`,pr:`$1`,rounded:`$xs`,bg:`$hover`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,numberOfLines:1,maxW:160,children:r(e)}),(0,H.jsx)(W,{size:`icon-2xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Remove ${r(e)}`,onPress:()=>t(n.filter((e,t)=>t!==i)),children:(0,H.jsx)(Rn,{})})]},`${r(e)}-${i}`))}):null]})}function H$(e){try{return JSON.stringify(e,null,2)}catch{return String(e)}}function U$({field:e,value:t,onChange:n,onCancel:r}){let[i,a]=(0,V.useState)(()=>t==null?``:typeof t==`string`?t:H$(t));return(0,H.jsx)(z,{gap:`$1`,width:400,maxW:`100%`,onKeyDown:e=>e.key===`Escape`&&r?.(),children:(0,H.jsx)(FL,{label:e.label,language:`json`,value:i,minHeight:120,maxHeight:300,onChange:e=>{a(e);let t=uL(e);t.kind===`empty`?n(null):t.kind===`json`&&n(t.value)}})})}var W$=!1;function G$(){W$||(W$=!0,XZ(`text`,{Display:kQ,Input:_$}),XZ(`longText`,{Display:AQ,Input:x$}),XZ(`richText`,{Display:jQ,Input:x$}),XZ(`number`,{Display:zQ,Input:S$}),XZ(`percent`,{Display:BQ,Input:C$}),XZ(`currency`,{Display:VQ,Input:w$}),XZ(`boolean`,{Display:WQ,Input:E$}),XZ(`select`,{Display:GQ,Input:A$}),XZ(`multiSelect`,{Display:KQ,Input:j$}),XZ(`date`,{Display:YQ,Input:I$}),XZ(`dateTime`,{Display:XQ,Input:I$}),XZ(`email`,{Display:MQ,Input:v$}),XZ(`url`,{Display:PQ,Input:y$}),XZ(`phone`,{Display:IQ,Input:b$}),XZ(`rating`,{Display:UQ,Input:T$}),XZ(`links`,{Display:FQ,Input:L$}),XZ(`relation`,{Display:QQ,Input:M$}),XZ(`json`,{Display:a$,Input:U$}),XZ(`files`,{Display:i$,Input:V$}),XZ(`uuid`,{Display:r$}),XZ(`fullName`,{Display:t$,Input:R$}),XZ(`address`,{Display:n$,Input:B$}),XZ(`position`,{Display:zQ}),XZ(`actor`,{Display:e$}))}G$();function K$(e){let t=ZZ(e.field.type)?.Display??o$;return(0,H.jsx)(t,{...e})}function q$(e){let t=ZZ(e.field.type)?.Input;return t?(0,H.jsx)(t,{...e}):null}function J$(e){return!!ZZ(e)?.Input}function Y$({trigger:e,children:t,open:n,onOpenChange:r,placement:i=`bottom-start`,width:a=240,maxHeight:o=320,header:s}){return(0,H.jsxs)(I_,{placement:i,open:n,onOpenChange:r,allowFlip:!0,children:[(0,H.jsx)(L_,{asChild:!0,children:e}),(0,H.jsxs)(R_,{size:`sm`,p:0,gap:0,width:a,overflow:`hidden`,children:[s?(0,H.jsx)(z,{p:`$1`,borderBottomWidth:1,borderColor:`$borderColor`,children:s}):null,(0,H.jsx)(Mt,{style:{maxHeight:o},children:(0,H.jsx)(z,{p:`$1`,gap:2,children:t})})]})]})}function X$({children:e,onPress:t,active:n,icon:r,trailing:i,tone:a=`default`}){return(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,onPress:t,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault?.(),t?.())},cursor:`pointer`,items:`center`,gap:`$2`,minH:32,px:`$2`,rounded:`$xs`,bg:n?`$hover`:`transparent`,hoverStyle:{bg:a===`danger`?`var(--state-error-bg)`:`$hover`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},children:[r?(0,H.jsx)(y,{items:`center`,justify:`center`,shrink:0,children:r}):null,(0,H.jsx)(z,{flex:1,minW:0,children:typeof e==`string`?(0,H.jsx)(U,{fontSize:`$2`,color:a===`danger`?`$bad`:`$aside`,numberOfLines:1,children:e}):e}),i??null]})}function Z$({checked:e,indeterminate:t,onChange:n,size:r=16,label:i}){return(0,H.jsx)(ig,{size:r>16?`md`:`sm`,variant:`solid`,hoverable:!0,checked:t?`indeterminate`:!!e,onCheckedChange:()=>n?.(t?!0:!e),"aria-label":i??(t?`Select all`:`Select`)})}var Q$=e=>e==null?``:String(e),$$=e=>{if(e==null||e===``)return null;if(typeof e==`object`&&!Array.isArray(e)&&`amount`in e)return $$(e.amount);let t=typeof e==`number`?e:Number(e);return Number.isFinite(t)?t:null},e1=e=>Array.isArray(e)?e:e==null?[]:[e],t1=864e5,n1=e=>typeof e==`string`&&/^\d{4}-\d{2}-\d{2}$/.test(e.trim()),r1=e=>{if(e==null||e===``)return null;let t=(e instanceof Date?e:new Date(e)).getTime();return Number.isNaN(t)?null:t},i1=(e,t)=>(e?.metadata?.options)?.find(e=>e.value===t)?.label??t;function a1(e,t){let n=e?.metadata?.labelField??`name`;if(typeof t==`string`)return t;if(t&&typeof t==`object`){let e=t;return Q$(e[n]??e.label??e.name??e.id)}return``}function o1(e,t){switch(e?.type){case`number`:case`percent`:case`rating`:case`position`:return $$(t);case`currency`:{let e=t??{};return $$(typeof e==`object`&&e?e.amount:t)}case`boolean`:return+(t===!0||t===`true`||t===1);case`date`:case`dateTime`:return r1(t);case`select`:return t==null||t===``?null:i1(e,Q$(t)).toLowerCase();case`multiSelect`:return e1(t).map(t=>i1(e,Q$(t))).join(`, `).toLowerCase()||null;case`relation`:return a1(e,t).toLowerCase()||null;case`links`:return e1(t).map(e=>typeof e==`string`?e:e?.url??``).join(`, `).toLowerCase()||null;case`fullName`:return aQ(t).toLowerCase()||null;case`address`:return lQ(t).toLowerCase()||null;case`phone`:return vQ(gQ(t)).toLowerCase()||null;case`email`:return pQ(t).join(`, `).toLowerCase()||null;case`actor`:return bQ(t)?.name.toLowerCase()||null;case`richText`:return xQ(t).toLowerCase()||null;default:{let e=Q$(t);return e===``?null:e.toLowerCase()}}}var s1=(e,t)=>e.find(e=>e.name===t);function c1(e,t){return typeof e==`number`&&typeof t==`number`?e-t:String(e).localeCompare(String(t))}function l1(e,t,n){return t.length===0?e.slice():e.map((e,t)=>[e,t]).sort(([e,r],[i,a])=>{for(let r of t){let t=s1(n,r.field),a=o1(t,e[r.field]),o=o1(t,i[r.field]);if(a===null&&o===null)continue;if(a===null)return 1;if(o===null)return-1;let s=c1(a,o);if(s!==0)return r.dir===`asc`?s:-s}return r-a}).map(([e])=>e)}function u1(e,t){let n=e.length===1&&e[0].field===t?e[0]:void 0;return n?n.dir===`asc`?[{field:t,dir:`desc`}]:[]:[{field:t,dir:`asc`}]}function d1(e,t){return e.find(e=>e.field===t)?.dir}function f1(e){let t=Array.isArray(e)?e:[],n=e=>e==null||e===``?void 0:e;return[n(t[0]),n(t[1])]}function p1(e){return e.op===`isEmpty`||e.op===`isNotEmpty`?!0:e.op===`between`?f1(e.value).some(e=>e!==void 0):e.op===`isAnyOf`?Array.isArray(e.value)&&e.value.length>0:e.value!=null&&e.value!==``}var m1={contains:`contains`,notContains:`does not contain`,is:`is`,isNot:`is not`,gt:`is greater than`,gte:`is at least`,lt:`is less than`,lte:`is at most`,isEmpty:`is empty`,isNotEmpty:`is not empty`,isAnyOf:`is any of`,between:`is between`},h1=[`contains`,`notContains`,`is`,`isNot`,`isEmpty`,`isNotEmpty`],g1=[`is`,`isNot`,`between`,`gt`,`gte`,`lt`,`lte`,`isEmpty`,`isNotEmpty`],_1=[`is`,`isNot`,`isAnyOf`,`isEmpty`,`isNotEmpty`],v1=[`is`];function y1(e){switch(e){case`number`:case`percent`:case`currency`:case`rating`:case`date`:case`dateTime`:return g1;case`select`:case`multiSelect`:case`relation`:return _1;case`boolean`:return v1;default:return h1}}var b1=(e,t)=>t==null||t===``?!0:Array.isArray(t)?t.length===0:e?.type===`currency`&&$$(t?.amount)==null,x1=e=>e===`number`||e===`percent`||e===`currency`||e===`rating`||e===`date`||e===`dateTime`;function S1(e,t){if(e?.type===`multiSelect`)return e1(t).map(Q$).filter(e=>e!==``);if(e?.type===`relation`){let e=C1(t);return e?[e]:[]}let n=Q$(t);return n===``?[]:[n]}var C1=e=>{if(typeof e==`string`)return e;if(e&&typeof e==`object`){let t=e;return Q$(t.id??t.value??``)}return``};function w1(e,t,n){if(n.op===`isEmpty`)return b1(e,t);if(n.op===`isNotEmpty`)return!b1(e,t);let r=e?.type;if(r===`boolean`){let e=t===!0||t===`true`||t===1,r=n.value===!0||n.value===`true`||n.value===1;return n.op===`isNot`?e!==r:e===r}if(r===`select`||r===`multiSelect`||r===`relation`){let r=new Set(S1(e,t));if(n.op===`isAnyOf`){let e=new Set((Array.isArray(n.value)?n.value:[]).map(Q$));return e.size===0||[...r].some(t=>e.has(t))}let i=Q$(n.value);return n.op===`is`?r.has(i):n.op!==`isNot`||!r.has(i)}if(x1(r)){let i=o1(e,t),a=typeof i==`number`?i:null,o=r===`date`||r===`dateTime`,s=e=>o?r1(e):$$(e);if(n.op===`between`){let[e,t]=f1(n.value),r=e===void 0?null:s(e),i=t===void 0?null:s(t);if(a==null)return!1;let c=i!=null&&o&&n1(t)?i+t1-1:i;return(r==null||a>=r)&&(c==null||a<=c)}let c=s(n.value);if(a==null||c==null)return n.op===`isNot`;switch(n.op){case`is`:return a===c;case`isNot`:return a!==c;case`gt`:return a>c;case`gte`:return a>=c;case`lt`:return a<c;case`lte`:return a<=c;default:return!0}}let i=Q$(o1(e,t)),a=Q$(n.value).toLowerCase();switch(n.op){case`contains`:return i.includes(a);case`notContains`:return!i.includes(a);case`is`:return i===a;case`isNot`:return i!==a;default:return!0}}function T1(e,t,n,r=`and`){let i=t.filter(p1);if(i.length===0)return e.slice();let a=e=>t=>w1(s1(n,t.field),e[t.field],t);return e.filter(e=>r===`or`?i.some(a(e)):i.every(a(e)))}function E1(e,t,n){let r=t.trim().toLowerCase();return r?e.filter(e=>n.some(t=>{let n=o1(t,e[t.name]);return n!=null&&String(n).toLowerCase().includes(r)})):e.slice()}function D1(e,t,n){let r=e.length,i=Math.max(1,Math.ceil(r/n)),a=Math.min(Math.max(1,t),i),o=(a-1)*n,s=e.slice(o,o+n);return{items:s,page:a,pageCount:i,total:r,from:r===0?0:o+1,to:o+s.length}}function O1(e,t,n){let r=e.filter(e=>!n?.has(e.name));if(!t||t.length===0)return r;let i=new Map(r.map(e=>[e.name,e])),a=[];for(let e of t){let t=i.get(e);t&&(a.push(t),i.delete(e))}for(let e of r)i.has(e.name)&&a.push(e);return a}var k1=new Set([`boolean`,`select`,`multiSelect`,`date`,`dateTime`,`relation`,`rating`,`files`]),A1=80,j1={regular:{row:44,pad:12,select:44},compact:{row:32,pad:8,select:28}};function M1(e){let{fields:t,records:n,getRowKey:r,loading:i,empty:a=`No records yet.`,sorts:o=[],onSortChange:s,onOpen:c,selectable:l,onSelectionChange:u,bulkActions:d,editable:f,onEditCommit:p,fieldOptions:m,columnOrder:h,onColumnOrderChange:g,hiddenFields:_,pageSize:v=25,remote:b}=e,x=j1[st()],S=e.rowHeight??x.row,C=x.select,w=(0,V.useMemo)(()=>new Set(_??[]),[_]),[T,E]=(0,V.useState)(h);(0,V.useEffect)(()=>{h&&E(h)},[h]);let D=(0,V.useMemo)(()=>O1(t,T,w),[t,T,w]),[O,k]=(0,V.useState)({}),[A,j]=(0,V.useState)(new Set),[ee,M]=(0,V.useState)(null),[N,P]=(0,V.useState)(void 0),[te,F]=(0,V.useState)(null),[I,ne]=(0,V.useState)(1),re=(0,V.useCallback)((e,t)=>r?r(e,t):e.id==null?String(t):String(e.id),[r]),ie=(0,V.useMemo)(()=>{if(b){let e=v>0?v:Math.max(1,n.length),t=b.total===0||n.length===0?0:(b.page-1)*e+1;return{items:n,page:b.page,pageCount:Math.max(1,Math.ceil(b.total/e)),total:b.total,from:t,to:t===0?0:t+n.length-1}}return v>0?D1(n,I,v):{items:n,page:1,pageCount:1,total:n.length,from:+!!n.length,to:n.length}},[n,I,v,b]);(0,V.useEffect)(()=>{!b&&I>ie.pageCount&&ne(ie.pageCount)},[b,I,ie.pageCount]);let L=e=>{let t=Math.min(Math.max(1,e),ie.pageCount);b?b.onPage(t):ne(t)},ae=(0,V.useCallback)(e=>{j(e),u?.([...e])},[u]),oe=ie.items.map((e,t)=>re(e,t)),R=oe.length>0&&oe.every(e=>A.has(e)),se=oe.some(e=>A.has(e)),ce=()=>{let e=new Set(A);R?oe.forEach(t=>e.delete(t)):oe.forEach(t=>e.add(t)),ae(e)},le=e=>{let t=new Set(A);t.has(e)?t.delete(e):t.add(e),ae(t)},ue=e=>s?.(u1(o,e)),de=(0,V.useRef)([]),[fe,pe]=(0,V.useState)(null),me=(e,t)=>n=>{let r=n.clientX??n.nativeEvent?.clientX??0,i=t?.getBoundingClientRect().width??A1,a=t=>k(n=>({...n,[e]:Math.max(A1,i+(t.clientX-r))})),o=()=>{window.removeEventListener(`pointermove`,a),window.removeEventListener(`pointerup`,o)};window.addEventListener(`pointermove`,a),window.addEventListener(`pointerup`,o)},he=e=>t=>{if(!g&&h)return;let n=de.current.map(e=>e?.getBoundingClientRect()??null),r=t.clientX??t.nativeEvent?.clientX??0;pe({from:e,x:r,target:e});let i=t=>{let r=n.length-1;for(let e=0;e<n.length;e++){let i=n[e];if(i&&t.clientX<i.left+i.width/2){r=e;break}}pe({from:e,x:t.clientX,target:r})},a=()=>{window.removeEventListener(`pointermove`,i),window.removeEventListener(`pointerup`,a),pe(e=>{if(e&&e.target!==e.from){let t=D.map(e=>e.name),[n]=t.splice(e.from,1);t.splice(e.target,0,n),E(t),g?.(t)}return null})};window.addEventListener(`pointermove`,i),window.addEventListener(`pointerup`,a)},ge=(e,t,n)=>{f&&!t.readOnly&&J$(t.type)&&(M({key:e,field:t.name}),P(n))},_e=()=>{M(null),P(void 0)},ve=(0,V.useCallback)(async(e,t,n)=>{let r=`${ee?.key}:${t.name}`;if(M(null),P(void 0),p)try{F(r),await p(e,t,n)}finally{F(null)}},[ee,p]),ye=!f&&!!c,be=(l?C:0)+D.reduce((e,t)=>e+(O[t.name]??t.width??160),0),xe=e=>{let t=O[e.name]??e.width;return t?{width:t}:{flex:1,minW:140}},Se={borderBottomWidth:1,borderColor:`$borderColor`};return(0,H.jsxs)(z,{"data-slot":`data-table`,rounded:`$3`,overflow:`hidden`,borderWidth:1,borderColor:`$borderColor`,bg:`$background`,children:[l&&A.size>0?(0,H.jsxs)(y,{items:`center`,justify:`space-between`,px:x.pad,py:`$2`,bg:`$panel`,...Se,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,children:`${A.size} selected`}),(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[d?.([...A]),(0,H.jsx)(W,{size:`xs`,variant:`ghost`,emphasis:`subtle`,onPress:()=>ae(new Set),children:`Clear`})]})]}):null,(0,H.jsxs)(z,{role:`table`,"aria-rowcount":ie.total+1,style:{minWidth:be},children:[(0,H.jsxs)(y,{bg:`$panel`,minH:S,...Se,role:`row`,children:[l?(0,H.jsx)(y,{width:C,items:`center`,justify:`center`,shrink:0,role:`columnheader`,children:(0,H.jsx)(Z$,{checked:R,indeterminate:!R&&se,onChange:ce,label:`Select all rows`})}):null,D.map((e,t)=>{let n=d1(o,e.name),r=fe&&fe.target===t&&fe.from!==t;return(0,H.jsxs)(y,{...xe(e),role:`columnheader`,"aria-sort":n===`asc`?`ascending`:n===`desc`?`descending`:void 0,items:`center`,gap:`$1`,px:x.pad,borderLeftWidth:r?2:0,borderLeftColor:`var(--primary)`,opacity:fe?.from===t?.5:1,ref:e=>{de.current[t]=e},style:{position:`relative`},children:[(0,H.jsxs)(y,{items:`center`,gap:`$1`,flex:1,minW:0,cursor:`pointer`,onPress:()=>ue(e.name),onPointerDown:he(t),children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,numberOfLines:1,color:`$aside`,children:e.label}),n===`asc`?(0,H.jsx)(gp,{size:12,color:`$hint`}):n===`desc`?(0,H.jsx)(pp,{size:12,color:`$hint`}):s?(0,H.jsx)(Dp,{size:12,color:`$hush`}):null]}),(0,H.jsx)(z,{width:8,height:`100%`,cursor:`col-resize`,onPointerDown:me(e.name,de.current[t]),style:{position:`absolute`,right:-4,top:0,zIndex:2}})]},e.name)})]}),i?(0,H.jsx)(y,{role:`row`,children:(0,H.jsxs)(y,{flex:1,px:`$4`,py:`$6`,items:`center`,justify:`center`,gap:`$2`,role:`cell`,"aria-live":`polite`,children:[(0,H.jsx)(op,{size:`small`,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:`Loading…`})]})}):ie.items.length===0?(0,H.jsx)(y,{role:`row`,children:(0,H.jsx)(z,{flex:1,px:`$4`,py:`$7`,items:`center`,gap:`$1`,role:`cell`,children:typeof a==`string`?(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:a}):a})}):ie.items.map((e,t)=>{let n=re(e,t),r=A.has(n);return(0,H.jsxs)(y,{group:!0,role:`row`,"aria-selected":l?r:void 0,items:`stretch`,cursor:ye?`pointer`:void 0,onPress:ye?()=>c?.(e):void 0,bg:r?`$hover`:`transparent`,hoverStyle:{bg:`$hover`},minH:S,...Se,children:[l?(0,H.jsx)(y,{width:C,items:`center`,justify:`center`,shrink:0,role:`cell`,children:(0,H.jsx)(Z$,{checked:r,onChange:()=>le(n),label:`Select row ${ie.from+t}`})}):null,D.map((t,r)=>{let i=f&&ee?.key===n&&ee.field===t.name,a=f&&!t.readOnly&&J$(t.type),o=`${n}:${t.name}`,s=m?.(t)?{...t,metadata:{...t.metadata,options:m(t)}}:t;return(0,H.jsxs)(y,{...xe(t),role:`cell`,items:`center`,px:x.pad,minW:0,style:{position:`relative`},children:[i?(0,H.jsx)(z,{flex:1,minW:0,py:`$1`,onPress:e=>e.stopPropagation?.(),children:(0,H.jsx)(q$,{field:s,value:N,autoFocus:!0,onChange:n=>k1.has(t.type)?void ve(e,t,n):P(n),onSubmit:()=>void ve(e,t,N),onCancel:_e})}):(0,H.jsxs)(y,{flex:1,minW:0,items:`center`,gap:`$1`,minH:S-8,cursor:a?`text`:void 0,onPress:a?()=>ge(n,t,e[t.name]):void 0,hoverStyle:a?{bg:`$raised`}:void 0,rounded:`$xs`,px:a?`$1`:0,mx:a?-4:0,overflow:`hidden`,children:[(0,H.jsx)(K$,{field:t,value:e[t.name]}),te===o?(0,H.jsx)(op,{size:`small`,"aria-hidden":!0}):null]}),r===0&&c&&f&&!i?(0,H.jsx)(y,{position:`absolute`,r:x.pad/2,opacity:0,"$group-hover":{opacity:1},focusWithinStyle:{opacity:1},children:(0,H.jsx)(Wm,{framed:!0,size:`icon-2xs`,variant:`ghost`,children:(0,H.jsx)(W,{size:`icon-2xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Open record`,onPress:()=>c(e),children:(0,H.jsx)(om,{})})})}):null]},t.name)})]},n)})]}),!i&&v>0&&ie.total>0?(0,H.jsxs)(y,{items:`center`,justify:`space-between`,px:x.pad,py:`$1`,bg:`$panel`,borderTopWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(U,{fontSize:`$1`,color:`$hint`,children:`${ie.from.toLocaleString()}–${ie.to.toLocaleString()} of ${ie.total.toLocaleString()}`}),(0,H.jsxs)(y,{items:`center`,gap:`$1`,children:[(0,H.jsx)(W,{size:`icon-xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Previous page`,disabled:ie.page<=1,onPress:()=>L(ie.page-1),children:(0,H.jsx)(Tp,{})}),(0,H.jsx)(U,{fontSize:`$1`,px:`$1`,color:`$hint`,children:`${ie.page.toLocaleString()} / ${ie.pageCount.toLocaleString()}`}),(0,H.jsx)(W,{size:`icon-xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Next page`,disabled:ie.page>=ie.pageCount,onPress:()=>L(ie.page+1),children:(0,H.jsx)(rt,{})})]})]}):null]})}var N1=`red.ruby.crimson.tomato.orange.amber.yellow.lime.grass.green.jade.mint.teal.cyan.sky.blue.iris.violet.purple.plum.pink.bronze.gold.brown.gray.mauve.olive.sage.sand.slate`.split(`.`),P1=e=>({bg:`var(--data-${e}-3)`,fg:`var(--data-${e}-11)`,border:`var(--data-${e}-6)`});Object.fromEntries(N1.map(e=>[e,P1(e)]));var F1={text:`#f4f4f5`,textMuted:`#a1a1aa`,textFaint:`#71717a`,surface:`#09090b`,surfaceRaised:`#0a0a0a`,border:`#27272a`,hover:`#18181b`,accent:`#60a5fa`,danger:`#fca5a5`},I1=M(z,{name:`Card`,backgroundColor:`$background`,position:`relative`,borderRadius:`$true`}),L1={header:32,check:24,value:156,icon:16,rows:2};function R1(e){return st()===`compact`?(0,H.jsx)(V1,{...e}):(0,H.jsx)(H1,{...e})}var z1=(e,t,n)=>{let r=e??t[0]?.name,i=r==null?void 0:n[r];return{name:r,text:i==null||i===``?`Untitled`:String(i)}},B1=e=>{let t=e?.target;return!!(t instanceof Element&&t.closest(`button, a, [role="button"], [role="checkbox"], [role="link"]`))};function V1({titleField:e,fields:t,record:n,onPress:r,selected:i=!1,onSelectedChange:a,active:o=!1,fieldIcons:s,imageField:c,drag:l}){let[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)(!1),m=z1(e,t,n),h=t.filter(e=>e.name!==m.name&&e.name!==c),g=n.id==null?m.text:String(n.id),_=c?n[c]:void 0,v=r?()=>r(n):void 0,b=a&&(u||i);return(0,H.jsxs)(z,{"data-slot":`record-card`,"data-selected":i?``:void 0,"data-active":o?``:void 0,bg:i||o||f?`$hover`:`$panel`,borderWidth:1,borderColor:o?`$rim`:`$borderColor`,hoverStyle:{borderColor:`$rim`},rounded:`$xs`,overflow:`hidden`,cursor:v?`pointer`:void 0,opacity:l===`source`?.3:1,scale:l===`preview`?1.02:1,onHoverIn:()=>d(!0),onHoverOut:()=>d(!1),onFocus:()=>p(!0),onBlur:()=>p(!1),onPress:v?e=>B1(e)?void 0:v():void 0,children:[(0,H.jsxs)(y,{"data-slot":`record-card-header`,minH:L1.header,items:`center`,pt:`$2`,pr:`$2`,pb:`$1`,pl:`$2`,children:[(0,H.jsx)(y,{flex:1,minW:0,children:(0,H.jsx)(lR,{size:`sm`,weight:`medium`,label:m.text,startElement:(0,H.jsx)(Hh,{size:`sm`,shape:`rounded`,name:m.text,colorSeed:g,src:_??null}),...v?{onPress:v}:null})}),a?(0,H.jsx)(y,{"data-slot":`record-card-check`,height:20,width:b?L1.check:0,$touchable:{width:L1.check},overflow:`hidden`,justify:`flex-end`,items:`center`,shrink:0,style:{transition:`width 160ms var(--ease-out, ease)`},children:(0,H.jsx)(ig,{variant:`outline`,checked:i,onCheckedChange:e=>a(e===!0),"aria-label":`Select ${m.text}`})}):null]}),h.length?(0,H.jsx)(z,{"data-slot":`record-card-body`,gap:L1.rows,pt:0,pr:`$2`,pb:`$2`,pl:10,children:h.map(e=>(0,H.jsxs)(y,{items:`center`,gap:`$2`,minH:24,children:[s?.[e.name]?(0,H.jsx)(y,{width:L1.icon,height:L1.icon,items:`center`,justify:`center`,shrink:0,children:s[e.name]}):(0,H.jsx)(U,{fontSize:`$1`,color:`$hint`,numberOfLines:1,shrink:0,children:e.label}),(0,H.jsx)(z,{flex:1,minW:0,maxW:L1.value,children:(0,H.jsx)(K$,{field:e,value:n[e.name]})})]},e.name))}):null]})}function H1({titleField:e,fields:t,record:n,onPress:r}){let i=z1(e,t,n),a=t.filter(e=>e.name!==i.name);return(0,H.jsxs)(I1,{p:12,gap:8,borderWidth:1,rounded:8,cursor:r?`pointer`:void 0,hoverStyle:r?{bg:F1.hover}:void 0,onPress:r?()=>r(n):void 0,style:{backgroundColor:F1.surface,borderColor:F1.border},children:[(0,H.jsx)(U,{fontSize:14,fontWeight:`700`,numberOfLines:1,style:{color:F1.text},children:i.text}),a.map(e=>(0,H.jsxs)(y,{gap:8,items:`center`,children:[(0,H.jsx)(U,{fontSize:11,numberOfLines:1,width:84,style:{color:F1.textFaint},children:e.label}),(0,H.jsx)(z,{flex:1,children:(0,H.jsx)(K$,{field:e,value:n[e.name]})})]},e.name))]})}var U1=e=>e==null?``:String(e),W1=new Set([`select`,`boolean`,`relation`]);function G1(e){return e.filter(e=>W1.has(e.type))}function K1(e){let t=e.filter(e=>e.type===`select`);return t.length>0?t[0].name:G1(e)[0]?.name}function q1(e,t){if(e.type===`boolean`)return t==null||t===``?``:t===!0||t===`true`||t===1?`true`:`false`;if(e.type===`relation`){if(t&&typeof t==`object`){let e=t;return U1(e.id??e.value??``)}return U1(t)}return U1(t)}function J1(e){if(e.type===`boolean`){let t=e.metadata??{};return[{key:`true`,label:t.trueLabel??`Yes`,color:`green`},{key:`false`,label:t.falseLabel??`No`,color:`gray`}]}return(e.metadata?.options??[]).map(e=>({key:e.value,label:e.label,color:e.color}))}function Y1(e,t,n={}){let r=n.includeEmpty??!0,i=J1(t),a=[],o=new Map,s=new Map,c=(e,t,n)=>{s.has(e)||(s.set(e,[]),a.push(e),o.set(e,{label:t,color:n}))};r&&c(``,n.emptyLabel??`No ${t.label.toLowerCase()}`);for(let e of i)c(e.key,e.label,e.color);for(let i of e){let e=q1(t,i[t.name]);(e!==``||r)&&(s.has(e)||c(e,e||(n.emptyLabel??`No ${t.label.toLowerCase()}`)),s.get(e).push(i))}return a.filter(e=>!(e===``&&(s.get(e)?.length??0)===0&&i.length>0)).map(e=>({key:e,...o.get(e),records:s.get(e)??[]}))}function X1(e,t){return e.type===`boolean`?{[e.name]:t===`true`}:{[e.name]:t===``?null:t}}var Z1=300,Q1=200;function $1(e){let{fields:t,records:n,groupField:r,titleField:i,cardFields:a,onOpen:o,onRecordChange:s,onCreate:c,getRowKey:l}=e,{selectedIds:u,onSelectedChange:d,activeId:f,fieldIcons:p}=e,m=e=>l?l(e):String(e.id??``),h=st()===`compact`,g=h?Q1:Z1,_=(e,t)=>h?{selected:u?.has(m(e))??!1,onSelectedChange:d?t=>d(e,t):void 0,active:f!=null&&f===m(e),fieldIcons:p,drag:t}:null,v=t.find(e=>e.name===r),[b,x]=(0,V.useState)({});(0,V.useEffect)(()=>{x({})},[n]);let S=(0,V.useRef)(null),C=(0,V.useRef)([]),[w,T]=(0,V.useState)(null),E=(0,V.useMemo)(()=>v?n.map(e=>b[m(e)]==null?e:{...e,[v.name]:b[m(e)]===``?null:b[m(e)]}):n,[n,b,v]),D=(0,V.useMemo)(()=>v?Y1(E,v):[],[E,v]);if(!v)return h?(0,H.jsx)(z,{p:`$5`,items:`center`,borderWidth:1,rounded:`$xs`,borderColor:`$borderColor`,bg:`$panel`,children:(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:`Pick a select or status field to group the board by.`})}):(0,H.jsx)(z,{p:24,items:`center`,borderWidth:1,rounded:10,style:{borderColor:F1.border,backgroundColor:F1.surface},children:(0,H.jsx)(U,{style:{color:F1.textFaint},children:`Pick a select or status field to group the board by.`})});let O=e=>t=>{if(!s)return;let n=m(e),r=q1(v,e[v.name]),i=C.current.map(e=>e?.getBoundingClientRect()??null),a=t.clientX??t.nativeEvent?.clientX??0,o=t.clientY??t.nativeEvent?.clientY??0;T({id:n,from:r,x:a,y:o,target:r});let c=e=>{let t=r;for(let n=0;n<i.length;n++){let a=i[n];if(a&&e.clientX>=a.left&&e.clientX<=a.right){t=D[n]?.key??r;break}}T({id:n,from:r,x:e.clientX,y:e.clientY,target:t})},l=()=>{window.removeEventListener(`pointermove`,c),window.removeEventListener(`pointerup`,l),T(t=>(t&&t.target!==t.from&&(x(e=>({...e,[t.id]:t.target})),Promise.resolve(s(e,X1(v,t.target))).catch(()=>x(e=>{let n={...e};return delete n[t.id],n}))),null))};window.addEventListener(`pointermove`,c),window.addEventListener(`pointerup`,l)},k=w?E.find(e=>m(e)===w.id):void 0,A=()=>S.current?.getBoundingClientRect();return(0,H.jsxs)(z,{ref:e=>{S.current=e},style:{position:`relative`},children:[(0,H.jsx)(Mt,{horizontal:!0,showsHorizontalScrollIndicator:!1,children:(0,H.jsx)(y,{gap:h?8:12,py:2,items:`flex-start`,children:D.map((e,n)=>{let r=w&&w.target===e.key&&w.from!==e.key,l=h?{gap:8,p:4,rounded:`$xs`,bg:r?`$hover`:`transparent`}:{gap:8,p:8,rounded:12,style:{backgroundColor:F1.surfaceRaised,borderWidth:1,borderColor:r?F1.accent:F1.border}};return(0,H.jsxs)(z,{"data-slot":`board-column`,width:g,ref:e=>{C.current[n]=e},...l,children:[h?(0,H.jsxs)(y,{items:`center`,justify:`space-between`,minH:24,px:4,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,minW:0,children:[e.key===``?(0,H.jsx)(oR,{variant:`outline`,borderStyle:`dashed`,color:`transparent`,children:e.label}):(0,H.jsx)(oR,{color:e.color??`gray`,children:e.label}),(0,H.jsx)(U,{fontSize:`$1`,color:`$hint`,children:e.records.length})]}),c?(0,H.jsx)(W,{size:`icon-xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Add to ${e.label}`,onPress:()=>c(e.key),children:(0,H.jsx)(hm,{})}):null]}):(0,H.jsxs)(y,{items:`center`,justify:`space-between`,px:4,py:2,children:[(0,H.jsxs)(y,{items:`center`,gap:8,children:[e.key===``?(0,H.jsx)(U,{fontSize:13,fontWeight:`700`,style:{color:F1.textMuted},children:e.label}):(0,H.jsx)(DQ,{label:e.label,color:e.color}),(0,H.jsx)(U,{fontSize:12,style:{color:F1.textFaint},children:e.records.length})]}),c?(0,H.jsx)(z,{cursor:`pointer`,p:3,rounded:6,hoverStyle:{bg:F1.hover},onPress:()=>c(e.key),children:(0,H.jsx)(hm,{size:14,color:F1.textMuted})}):null]}),(0,H.jsxs)(z,{gap:8,style:{minHeight:40},children:[e.records.map(e=>{let n=w?.id===m(e);return(0,H.jsx)(z,{onPointerDown:O(e),style:{opacity:n&&!h?.35:1,cursor:s?`grab`:void 0},children:(0,H.jsx)(R1,{titleField:i,fields:a??t.filter(e=>e.name!==v.name),record:e,onPress:o,..._(e,n?`source`:void 0)})},m(e))}),e.records.length===0?h?(0,H.jsx)(z,{items:`center`,justify:`center`,py:`$4`,rounded:`$xs`,borderWidth:1,borderStyle:`dashed`,borderColor:`$borderColor`,children:(0,H.jsx)(U,{fontSize:`$1`,color:`$hint`,children:`Drop here`})}):(0,H.jsx)(z,{items:`center`,justify:`center`,py:16,rounded:8,style:{borderWidth:1,borderColor:F1.border,borderStyle:`dashed`},children:(0,H.jsx)(U,{fontSize:12,style:{color:F1.textFaint},children:`Drop here`})}):null]})]},e.key||`∅`)})})}),w&&k?(0,H.jsx)(z,{width:g-(h?8:20),style:{position:`absolute`,left:w.x-(A()?.left??0)-(g-(h?8:20))/2,top:w.y-(A()?.top??0)-20,pointerEvents:`none`,zIndex:50,...h?null:{transform:[{rotate:`2deg`}],boxShadow:`0 12px 32px rgba(0,0,0,0.4)`}},...h?{className:`elevation-2`}:null,children:(0,H.jsx)(R1,{titleField:i,fields:a??t.filter(e=>e.name!==v.name),record:k,..._(k,`preview`)})}):null]})}var e0=new Set([`boolean`,`select`,`multiSelect`,`date`,`dateTime`,`relation`,`rating`,`files`]),t0=({children:e})=>(0,H.jsx)(U,{fontSize:`$1`,fontWeight:`500`,color:`$hint`,numberOfLines:1,children:e});function n0({field:e,value:t,editable:n,onCommit:r,options:i}){let[a,o]=(0,V.useState)(!1),[s,c]=(0,V.useState)(t),l=n&&!e.readOnly&&J$(e.type)&&!!r,u=i?{...e,metadata:{...e.metadata,options:i}}:e,d=e=>{o(!1),r?.(e)};return(0,H.jsxs)(z,{gap:`$1`,py:`$2`,borderBottomWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(t0,{children:e.label}),a?(0,H.jsx)(q$,{field:u,value:s,autoFocus:!0,onChange:t=>e0.has(e.type)?d(t):c(t),onSubmit:()=>d(s),onCancel:()=>{c(t),o(!1)}}):(0,H.jsx)(y,{items:`center`,minH:24,minW:0,cursor:l?`text`:void 0,rounded:`$xs`,px:l?`$1`:0,mx:l?-4:0,hoverStyle:l?{bg:`$hover`}:void 0,...l?{role:`button`,tabIndex:0,"aria-label":`Edit ${e.label}`}:null,onKeyDown:l?e=>{e.key===`Enter`&&(e.preventDefault?.(),c(t),o(!0))}:void 0,onPress:l?()=>{c(t),o(!0)}:void 0,children:(0,H.jsx)(K$,{field:e,value:t})})]})}function r0({fields:e,record:t,title:n,editable:r,onEditCommit:i,fieldOptions:a,related:o}){return(0,H.jsxs)(z,{gap:2,children:[n?(0,H.jsx)(z,{pb:`$3`,mb:`$1`,borderBottomWidth:1,borderColor:`$borderColor`,children:(0,H.jsx)(U,{fontSize:`$7`,fontWeight:`600`,numberOfLines:2,color:`$ink`,children:n})}):null,e.map(e=>(0,H.jsx)(n0,{field:e,value:t[e.name],editable:r,onCommit:i?t=>i(e,t):void 0,options:a?.(e)},e.name)),o?(0,H.jsx)(z,{pt:`$4`,gap:`$2`,children:o}):null]})}function i0(e,t=`default`,n=e===`board`?`Board`:`All records`){return{id:t,name:n,kind:e,filters:[],sorts:[]}}function a0(e,t,n){let r=e;return t.search&&t.search.trim()&&(r=E1(r,t.search,n)),r=T1(r,t.filters,n,t.match),r=l1(r,t.sorts,n),r}function o0(e){let t=y1(e.type);return{field:e.name,op:t[0]??`contains`}}function s0(e,t){return{...e,filters:[...e.filters,t]}}function c0(e,t,n){return{...e,filters:e.filters.map((e,r)=>r===t?{...e,...n}:e)}}function l0(e,t){return{...e,filters:e.filters.filter((e,n)=>n!==t)}}function u0(e,t){return{...e,match:t}}var d0=e=>e===`or`?`and`:`or`;function f0(e,t){return{...e,sorts:t}}function p0(e,t){return{...e,search:t}}function m0(e,t){return{...e,kind:t}}function h0(e,t){return{...e,groupField:t}}function g0(e,t){let n=new Set(e.hiddenFields??[]);return n.has(t)?n.delete(t):n.add(t),{...e,hiddenFields:[...n]}}var _0=new Set([`text`,`longText`,`email`,`url`]),v0=new Set([`contains`,`notContains`,`is`,`isNot`]);function y0(e,t,n){let r=e.type===`currency`||e.type===`percent`||e.type===`rating`,i=v0.has(t.op)&&!_0.has(e.type)&&e.type!==`select`&&e.type!==`multiSelect`&&e.type!==`relation`&&e.type!==`boolean`&&!r&&e.type!==`date`&&e.type!==`dateTime`&&e.type!==`number`,a=t.op===`isAnyOf`?{...e,type:`multiSelect`}:r?{...e,type:`number`}:i?{...e,type:`text`,metadata:void 0}:e;return n?{...a,metadata:{...a.metadata,options:n}}:a}function b0(e,t){let n=t?.metadata?.options,r=e=>n?.find(t=>t.value===e)?.label??String(e);if(e.op===`between`){let[t,n]=f1(e.value);return t!==void 0&&n!==void 0?`${r(t)} to ${r(n)}`:t===void 0?n===void 0?``:`to ${r(n)}`:`from ${r(t)}`}return e.value==null||e.value===``?``:Array.isArray(e.value)?e.value.map(r).join(`, `):r(e.value)}var x0=e=>e.op!==`isEmpty`&&e.op!==`isNotEmpty`;function S0({field:e,rule:t,onChange:n,fieldOptions:r}){let i=r?.(e),a=(0,V.useMemo)(()=>y0(e,t,i),[e,t,i]);if(t.op!==`between`)return(0,H.jsx)(q$,{field:a,value:t.value,onChange:n});let[o,s]=f1(t.value);return(0,H.jsxs)(y,{items:`center`,gap:6,flex:1,children:[(0,H.jsx)(y,{flex:1,minW:90,"aria-label":`From`,children:(0,H.jsx)(q$,{field:a,value:o,onChange:e=>n([e,s])})}),(0,H.jsx)(U,{fontSize:12,style:{color:F1.textFaint},children:`to`}),(0,H.jsx)(y,{flex:1,minW:90,"aria-label":`To`,children:(0,H.jsx)(q$,{field:a,value:s,onChange:e=>n([o,e])})})]})}var C0={top:39,details:32,chip:24,remove:20,name:130,menu:200,wide:240},w0=(e,t)=>e.find(e=>e.name===t),T0=(e,t)=>e.filter(e=>e.label.toLowerCase().includes(t.trim().toLowerCase()));function E0({open:e,icon:t,children:n,...r}){return(0,H.jsx)(W,{size:`xs`,variant:`ghost`,color:`$aside`,startIcon:t,bg:e?`$hover`:void 0,...r,children:n})}function D0(e){let{fields:t,view:n,onView:r,extra:i,onCreate:a,createLabel:o=`New`,boardDisabled:s}=e,{savedViews:c,dirty:l=!1,onResetView:u,onSaveView:d,onSaveAsView:f}=e,[p,m]=(0,V.useState)(!1),h=n.sorts.length>0||n.filters.length>0||l&&(u||d);return(0,H.jsxs)(z,{"data-slot":`view-bar`,children:[(0,H.jsxs)(y,{"data-slot":`view-bar-top`,minH:C0.top+1,items:`center`,justify:`space-between`,gap:`$2`,ml:`$1`,pr:`$2`,borderBottomWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(O0,{...e}),(0,H.jsxs)(y,{items:`center`,gap:`$0.5`,shrink:1,minW:0,children:[(0,H.jsx)(D_,{size:`xs`,start:(0,H.jsx)(vm,{size:14}),width:180,shrink:1,children:(0,H.jsx)(j_,{value:n.search??``,onChangeText:e=>r(p0(n,e)),placeholder:`Search…`,"aria-label":`Search records`})}),(0,H.jsx)(k0,{fields:t,view:n,onView:r,open:p,onOpenChange:m,children:(0,H.jsx)(E0,{open:p,icon:(0,H.jsx)(em,{}),children:`Filter`})}),(0,H.jsx)(j0,{fields:t,view:n,onView:r}),(0,H.jsx)(M0,{fields:t,view:n,onView:r,boardDisabled:s}),i,a?(0,H.jsx)(W,{size:`xs`,variant:`primary`,startIcon:(0,H.jsx)(hm,{}),onPress:a,children:o}):null]})]}),h?(0,H.jsxs)(y,{"data-slot":`view-bar-details`,minH:C0.details,items:`center`,gap:`$2`,py:`$1`,px:`$2`,borderTopWidth:1,borderColor:`$borderColor`,flexWrap:`wrap`,children:[n.sorts.map(e=>(0,H.jsx)(F0,{rule:e,fields:t,view:n,onView:r},`sort-${e.field}`)),n.sorts.length>0&&n.filters.length>0?(0,H.jsx)(z,{"data-slot":`view-bar-rule`,width:1,height:16,bg:`$raised`}):null,n.filters.map((t,i)=>(0,H.jsxs)(V.Fragment,{children:[i>0?(0,H.jsx)(W,{size:`xs`,variant:`ghost`,color:`$aside`,fontWeight:`400`,"aria-label":`Rules combine by ${n.match===`or`?`or`:`and`}; press for ${d0(n.match)}`,onPress:()=>r(u0(n,d0(n.match))),children:n.match===`or`?`or`:`and`}):null,(0,H.jsx)(I0,{index:i,rule:t,...e})]},`filter-${i}`)),(0,H.jsx)(W,{size:`xs`,variant:`ghost`,color:`$aside`,fontWeight:`400`,startIcon:(0,H.jsx)(hm,{}),onPress:()=>m(!0),children:`Add filter`}),(0,H.jsx)(y,{flex:1}),l&&u?(0,H.jsx)(W,{size:`xs`,variant:`ghost`,color:`$aside`,fontWeight:`400`,onPress:u,children:`Reset`}):null,l&&d?(0,H.jsxs)(Wm,{size:`xs`,variant:`outline`,"aria-label":`Update view`,children:[(0,H.jsx)(W,{onPress:d,children:`Update view`}),f?(0,H.jsxs)(Bg,{children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(W,{size:`icon-xs`,"aria-label":`More ways to save the view`,children:(0,H.jsx)(wp,{})})}),(0,H.jsx)(Kg,{align:`end`,minW:C0.menu,children:(0,H.jsx)(Xg,{onSelect:f,children:`Save as new view`})})]}):null]}):null]}):null]})}function O0({view:e,onView:t,count:n,savedViews:r,boardDisabled:i}){let[a,o]=(0,V.useState)(!1),s=e.kind===`board`?Qp:Dm;return(0,H.jsxs)(Bg,{open:a,onOpenChange:o,children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsxs)(W,{size:`xs`,variant:`ghost`,color:`$aside`,pl:`$1`,startIcon:(0,H.jsx)(s,{size:16}),endIcon:(0,H.jsx)(wp,{size:14,color:`$hush`}),bg:a?`$hover`:void 0,"aria-label":`View: ${e.name}`,children:[(0,H.jsx)(nR,{text:e.name,maxW:C0.name,fontSize:`$2`,fontWeight:`500`,color:`$aside`}),n==null?null:(0,H.jsx)(U,{fontSize:`$2`,color:`$hint`,children:`· ${n}`})]})}),(0,H.jsxs)(Kg,{minW:C0.menu,children:[r&&r.views.length?(0,H.jsx)(e_,{value:r.activeId??e.id,onValueChange:e=>{let n=r?.views.find(t=>t.id===e);n&&r&&(r.onSelect(n.id),t(n))},children:(0,H.jsx)(r_,{label:`Views`,children:r.views.map(e=>(0,H.jsx)(t_,{value:e.id,children:e.name},e.id))})}):null,i?null:(0,H.jsxs)(e_,{value:e.kind,onValueChange:n=>n===`table`||n===`board`?t(m0(e,n)):void 0,children:[(0,H.jsx)(f_,{variant:`band`,children:`Layout`}),(0,H.jsx)(t_,{value:`table`,children:`Table`}),(0,H.jsx)(t_,{value:`board`,children:`Board`})]})]})]})}function k0({fields:e,view:t,onView:n,open:r,onOpenChange:i,children:a}){let[o,s]=(0,V.useState)(``),c=T0(e,o);return(0,H.jsxs)(Bg,{open:r,onOpenChange:e=>{i(e),e||s(``)},children:[(0,H.jsx)(Hg,{asChild:!0,children:a}),(0,H.jsxs)(Kg,{minW:C0.menu,children:[(0,H.jsx)(n_,{value:o,onValueChange:s,placeholder:`Search fields`}),(0,H.jsx)(r_,{scrollable:!0,children:c.map(e=>(0,H.jsx)(Xg,{onSelect:()=>n(s0(t,o0(e))),children:e.label},e.name))}),c.length===0?(0,H.jsx)(u_,{children:`No field matches`}):null]})]})}var A0=(e,t)=>{let n=e.find(e=>e.field===t);return n?n.dir===`asc`?e.map(e=>e.field===t?{...e,dir:`desc`}:e):e.filter(e=>e.field!==t):[...e,{field:t,dir:`asc`}]};function j0({fields:e,view:t,onView:n}){let[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(``),s=T0(e,a);return(0,H.jsxs)(Bg,{open:r,onOpenChange:e=>{i(e),e||o(``)},children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(E0,{open:r,icon:(0,H.jsx)(fp,{}),children:`Sort`})}),(0,H.jsxs)(Kg,{minW:C0.menu,children:[(0,H.jsx)(n_,{value:a,onValueChange:o,placeholder:`Search fields`}),(0,H.jsx)(r_,{scrollable:!0,children:s.map(e=>{let r=t.sorts.find(t=>t.field===e.name)?.dir;return(0,H.jsx)(Xg,{onSelect:()=>n(f0(t,A0(t.sorts,e.name))),children:(0,H.jsxs)(y,{flex:1,items:`center`,justify:`space-between`,gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$aside`,numberOfLines:1,children:e.label}),r===`asc`?(0,H.jsx)(gp,{size:14,color:`$aside`}):r===`desc`?(0,H.jsx)(pp,{size:14,color:`$aside`}):null]})},e.name)})}),s.length===0?(0,H.jsx)(u_,{children:`No field matches`}):null]})]})}function M0({fields:e,view:t,onView:n,boardDisabled:r}){let[i,a]=(0,V.useState)(!1),o=new Set(t.hiddenFields??[]),s=e.filter(e=>!o.has(e.name)).map(e=>e.name),c=G1(e);return(0,H.jsxs)(Bg,{open:i,onOpenChange:a,defaultPage:`options`,children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(E0,{open:i,icon:(0,H.jsx)(Sm,{}),children:`Options`})}),(0,H.jsxs)(Kg,{align:`end`,minW:C0.wide,children:[(0,H.jsxs)(i_,{id:`options`,children:[(0,H.jsx)(o_,{children:(0,H.jsx)(s_,{children:`View options`})}),(0,H.jsx)(Xg,{page:`fields`,children:`Fields`}),t.kind===`board`&&c.length?(0,H.jsx)(Xg,{page:`group`,children:`Group by`}):null,r?null:(0,H.jsxs)(e_,{value:t.kind,onValueChange:e=>e===`table`||e===`board`?n(m0(t,e)):void 0,children:[(0,H.jsx)(f_,{variant:`band`,children:`Layout`}),(0,H.jsx)(t_,{value:`table`,children:`Table`}),(0,H.jsx)(t_,{value:`board`,children:`Board`})]})]}),(0,H.jsxs)(i_,{id:`fields`,children:[(0,H.jsx)(c_,{children:`Fields`}),(0,H.jsx)(e_,{multiple:!0,value:s,onValueChange:r=>{let i=new Set(Array.isArray(r)?r:r?[r]:[]),a=t;for(let t of e)i.has(t.name)===o.has(t.name)&&(a=g0(a,t.name));n(a)},children:(0,H.jsx)(r_,{scrollable:!0,children:e.map(e=>(0,H.jsx)(t_,{value:e.name,children:e.label},e.name))})})]}),(0,H.jsxs)(i_,{id:`group`,children:[(0,H.jsx)(c_,{children:`Group by`}),(0,H.jsx)(e_,{value:t.groupField??null,onValueChange:e=>n(h0(t,typeof e==`string`?e:void 0)),children:c.map(e=>(0,H.jsx)(t_,{value:e.name,children:e.label},e.name))})]})]})]})}function N0({label:e,onRemove:t,children:n}){return(0,H.jsxs)(y,{"data-slot":`view-chip`,height:C0.chip,items:`center`,gap:`$1`,p:`$0.5`,pl:`$1`,rounded:`$xs`,bg:`$hover`,borderWidth:1,borderColor:`$borderColor`,children:[n,(0,H.jsx)(W,{size:`icon-2xs`,variant:`ghost`,emphasis:`subtle`,"aria-label":`Remove ${e}`,onPress:t,children:(0,H.jsx)(Rn,{})})]})}var P0=(e,t,n={})=>(0,H.jsxs)(y,{role:`button`,tabIndex:0,"data-slot":`view-chip-body`,items:`center`,gap:`$1`,cursor:`pointer`,rounded:`$2xs`,focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},...n,children:[(0,H.jsx)(U,{fontSize:`$1`,fontWeight:`500`,color:`$ink`,numberOfLines:1,children:e}),t]});function F0({rule:e,fields:t,view:n,onView:r}){let i=w0(t,e.field)?.label??e.field,a=()=>r(f0(n,n.sorts.map(t=>t.field===e.field?{...t,dir:t.dir===`asc`?`desc`:`asc`}:t)));return(0,H.jsx)(N0,{label:`sort by ${i}`,onRemove:()=>r(f0(n,n.sorts.filter(t=>t.field!==e.field))),children:P0(i,e.dir===`asc`?(0,H.jsx)(gp,{size:14,color:`$ink`}):(0,H.jsx)(pp,{size:14,color:`$ink`}),{"aria-label":`Sort by ${i}, ${e.dir===`asc`?`ascending`:`descending`}`,onPress:a,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault?.(),a())}})})}function I0({index:e,rule:t,fields:n,view:r,onView:i,fieldOptions:a}){let[o,s]=(0,V.useState)(!1),c=w0(n,t.field)??n[0],l=y1(c.type),u=b0(t,c);return(0,H.jsx)(N0,{label:`filter on ${c.label}`,onRemove:()=>i(l0(r,e)),children:(0,H.jsxs)(Bg,{open:o,onOpenChange:s,children:[(0,H.jsx)(Hg,{asChild:!0,children:P0(c.label,(0,H.jsx)(U,{fontSize:`$1`,color:`$ink`,numberOfLines:1,children:`: ${m1[t.op]}${u?` ${u}`:``}`}),{"aria-label":`Filter: ${c.label} ${m1[t.op]} ${u}`.trim()})}),(0,H.jsxs)(Kg,{minW:C0.wide,children:[(0,H.jsxs)(e_,{value:t.op,closeOnSelect:!1,onValueChange:n=>{if(typeof n!=`string`)return;let a=n;i(c0(r,e,a===`between`||t.op===`between`?{op:a,value:void 0}:{op:a}))},children:[(0,H.jsx)(f_,{variant:`band`,children:c.label}),l.map(e=>(0,H.jsx)(t_,{value:e,children:m1[e]},e))]}),x0(t)?(0,H.jsx)(z,{p:`$1`,children:(0,H.jsx)(S0,{field:c,rule:t,fieldOptions:a,onChange:t=>i(c0(r,e,{value:t}))})}):null]})]})})}var L0=(e,t)=>e.find(e=>e.name===t);function R0({icon:e,label:t,count:n,active:r,style:i,...a}){return(0,H.jsxs)(y,{role:`button`,tabIndex:0,"aria-label":t,...a,items:`center`,gap:6,px:10,py:7,rounded:8,borderWidth:1,cursor:`pointer`,hoverStyle:{borderColor:F1.textMuted},style:{...i,borderColor:r?F1.accent:F1.border,backgroundColor:r?F1.hover:`transparent`},children:[e,(0,H.jsx)(U,{fontSize:13,fontWeight:`600`,style:{color:r?F1.text:F1.textMuted},children:t}),n?(0,H.jsx)(y,{items:`center`,justify:`center`,width:18,height:18,rounded:9,style:{backgroundColor:F1.accent},children:(0,H.jsx)(U,{fontSize:11,fontWeight:`700`,style:{color:`#0b1220`},children:n})}):null]})}function z0({view:e,onView:t,boardDisabled:n}){let r=(n,r,i)=>{let a=e.kind===n;return(0,H.jsxs)(y,{items:`center`,gap:6,px:10,py:6,rounded:7,cursor:`pointer`,onPress:()=>t(m0(e,n)),style:{backgroundColor:a?F1.surface:`transparent`},hoverStyle:a?void 0:{bg:F1.hover},children:[r,(0,H.jsx)(U,{fontSize:13,fontWeight:`600`,style:{color:a?F1.text:F1.textFaint},children:i})]})};return(0,H.jsxs)(y,{p:3,gap:2,rounded:9,borderWidth:1,style:{borderColor:F1.border,backgroundColor:F1.surfaceRaised},children:[r(`table`,(0,H.jsx)(Dm,{size:14,color:e.kind===`table`?F1.text:F1.textFaint}),`Table`),n?null:r(`board`,(0,H.jsx)(Qp,{size:14,color:e.kind===`board`?F1.text:F1.textFaint}),`Board`)]})}function B0({fields:e,value:t,onPick:n,trigger:r}){let[i,a]=(0,V.useState)(!1);return(0,H.jsx)(Y$,{open:i,onOpenChange:a,width:220,trigger:r,children:e.map(e=>(0,H.jsx)(X$,{active:e.name===t,onPress:()=>{n(e.name),a(!1)},children:(0,H.jsx)(U,{fontSize:13,style:{color:F1.text},children:e.label})},e.name))})}function V0({ops:e,value:t,onPick:n}){let[r,i]=(0,V.useState)(!1);return(0,H.jsx)(Y$,{open:r,onOpenChange:i,width:200,trigger:(0,H.jsx)(H0,{text:m1[t]}),children:e.map(e=>(0,H.jsx)(X$,{active:e===t,onPress:()=>{n(e),i(!1)},children:(0,H.jsx)(U,{fontSize:13,style:{color:F1.text},children:m1[e]})},e))})}function H0({text:e,style:t,...n}){return(0,H.jsx)(y,{role:`button`,tabIndex:0,...n,items:`center`,px:8,py:5,rounded:7,borderWidth:1,cursor:`pointer`,hoverStyle:{borderColor:F1.textMuted},style:{...t,borderColor:F1.border,backgroundColor:F1.surface},children:(0,H.jsx)(U,{fontSize:12,numberOfLines:1,style:{color:F1.text},children:e})})}function U0({fields:e,view:t,onView:n,fieldOptions:r}){let[i,a]=(0,V.useState)(!1),o=t.filters.filter(p1).length;return(0,H.jsx)(Y$,{open:i,onOpenChange:a,width:420,trigger:(0,H.jsx)(R0,{icon:(0,H.jsx)(em,{size:14,color:F1.textMuted}),label:`Filter`,count:o,active:o>0}),children:(0,H.jsxs)(z,{gap:8,p:4,children:[t.filters.length===0?(0,H.jsx)(U,{px:6,py:4,fontSize:12,style:{color:F1.textFaint},children:`No filters yet.`}):null,t.filters.map((i,a)=>{let o=L0(e,i.field)??e[0],s=y1(o.type);return(0,H.jsxs)(y,{items:`center`,gap:6,children:[a===0?(0,H.jsx)(U,{fontSize:12,width:36,style:{color:F1.textFaint},children:`Where`}):(0,H.jsx)(y,{width:36,cursor:`pointer`,onPress:()=>n(u0(t,d0(t.match))),role:`button`,"aria-label":`Rules combine by ${t.match===`or`?`or`:`and`}; press for ${d0(t.match)}`,children:(0,H.jsx)(U,{fontSize:12,fontWeight:`600`,style:{color:F1.accent},children:t.match===`or`?`or`:`and`})}),(0,H.jsx)(B0,{fields:e,value:i.field,onPick:r=>{n(c0(t,a,{field:r,op:y1(L0(e,r).type)[0],value:void 0}))},trigger:(0,H.jsx)(H0,{text:o.label})}),(0,H.jsx)(V0,{ops:s,value:i.op,onPick:e=>n(c0(t,a,e===`between`||i.op===`between`?{op:e,value:void 0}:{op:e}))}),x0(i)?(0,H.jsx)(y,{flex:1,minW:120,children:(0,H.jsx)(S0,{field:o,rule:i,fieldOptions:r,onChange:e=>n(c0(t,a,{value:e}))})}):(0,H.jsx)(y,{flex:1}),(0,H.jsx)(z,{cursor:`pointer`,p:4,rounded:6,hoverStyle:{bg:F1.hover},onPress:()=>n(l0(t,a)),children:(0,H.jsx)(Rn,{size:14,color:F1.textFaint})})]},a)}),(0,H.jsx)(y,{children:(0,H.jsx)(Je,{size:`$2`,icon:(0,H.jsx)(hm,{size:14}),onPress:()=>n(s0(t,o0(e[0]))),children:`Add filter`})})]})})}function W0({fields:e,view:t,onView:n}){let[r,i]=(0,V.useState)(!1),a=e=>t.sorts.find(t=>t.field===e)?.dir,o=e=>{let r=t.sorts.find(t=>t.field===e),i;i=r?r.dir===`asc`?t.sorts.map(t=>t.field===e?{...t,dir:`desc`}:t):t.sorts.filter(t=>t.field!==e):[...t.sorts,{field:e,dir:`asc`}],n(f0(t,i))};return(0,H.jsx)(Y$,{open:r,onOpenChange:i,width:240,trigger:(0,H.jsx)(R0,{icon:(0,H.jsx)(fp,{size:14,color:F1.textMuted}),label:`Sort`,count:t.sorts.length,active:t.sorts.length>0}),children:e.map(e=>{let t=a(e.name);return(0,H.jsx)(X$,{active:!!t,onPress:()=>o(e.name),trailing:t===`asc`?(0,H.jsx)(gp,{size:13,color:F1.accent}):t===`desc`?(0,H.jsx)(pp,{size:13,color:F1.accent}):null,children:(0,H.jsx)(U,{fontSize:13,style:{color:F1.text},children:e.label})},e.name)})})}function G0({fields:e,view:t,onView:n}){let[r,i]=(0,V.useState)(!1),a=G1(e),o=L0(e,t.groupField??``);return(0,H.jsxs)(Y$,{open:r,onOpenChange:i,width:220,trigger:(0,H.jsx)(R0,{icon:(0,H.jsx)(Np,{size:14,color:F1.textMuted}),label:o?`Group: ${o.label}`:`Group by`,active:!!o}),children:[a.length===0?(0,H.jsx)(U,{px:10,py:6,fontSize:12,style:{color:F1.textFaint},children:`No groupable fields`}):null,a.map(e=>(0,H.jsx)(X$,{active:e.name===t.groupField,onPress:()=>{n(h0(t,e.name)),i(!1)},children:(0,H.jsx)(U,{fontSize:13,style:{color:F1.text},children:e.label})},e.name))]})}function K0(e){return st()===`compact`?(0,H.jsx)(D0,{...e}):(0,H.jsx)(q0,{...e})}function q0(e){let{fields:t,view:n,onView:r,onCreate:i,createLabel:a=`New`,extra:o,boardDisabled:s}=e;return(0,H.jsxs)(y,{items:`center`,gap:8,style:{flexWrap:`wrap`},children:[(0,H.jsx)(z0,{view:n,onView:r,boardDisabled:s}),(0,H.jsx)(U0,{...e}),(0,H.jsx)(W0,{fields:t,view:n,onView:r}),n.kind===`board`?(0,H.jsx)(G0,{fields:t,view:n,onView:r}):null,(0,H.jsxs)(y,{flex:1,minW:160,items:`center`,gap:6,px:10,py:6,rounded:8,borderWidth:1,style:{borderColor:F1.border,backgroundColor:F1.surface},children:[(0,H.jsx)(vm,{size:14,color:F1.textFaint}),(0,H.jsx)(ht,{flex:1,size:`$2`,value:n.search??``,onChangeText:e=>r(p0(n,e)),placeholder:`Search…`,style:{borderWidth:0,backgroundColor:`transparent`,paddingLeft:0,paddingRight:0}})]}),o?(0,H.jsx)(V.Fragment,{children:o}):null,i?(0,H.jsx)(Je,{size:`$3`,icon:(0,H.jsx)(hm,{size:16}),theme:`blue`,onPress:i,children:a}):null]})}function J0(e){let{fields:t,records:n,loading:r,empty:i,view:a,onViewChange:o,defaultKind:s=`table`,savedViews:c,title:l,onOpen:u,onCreate:d,createLabel:f,onEditCommit:p,onRecordChange:m,fieldOptions:h,selectable:g=!0,editable:_=!0,bulkActions:v,toolbarExtra:y,boardDisabled:b,titleField:x,cardFields:S,remote:C}=e,[w,T]=(0,V.useState)(()=>{let e=i0(s);return s===`board`?{...e,groupField:K1(t)}:e}),E=a??w,D=e=>{let n=e.kind===`board`&&!e.groupField?{...e,groupField:K1(t)}:e;o?o(n):T(n)},O=(0,V.useMemo)(()=>C?n:a0(n,E,t),[C,n,E,t]),k=st()===`compact`,A=c?.views.find(e=>e.id===(c.activeId??E.id)),j=!!A&&JSON.stringify(A)!==JSON.stringify(E),ee=k&&c?{savedViews:{views:c.views,activeId:c.activeId,onSelect:c.onSelect},dirty:j,onResetView:A?()=>D(A):void 0,onSaveView:()=>c.onSave(E),onSaveAsView:()=>c.onSave({...E,id:`view-${Date.now()}`,name:`View ${c.views.length+1}`})}:null,M=m??(p?(e,n)=>{let[r]=Object.keys(n),i=t.find(e=>e.name===r);if(i)return p(e,i,n[r])}:void 0);return(0,H.jsxs)(z,{gap:12,children:[l?typeof l==`string`?(0,H.jsx)(U,{fontSize:20,fontWeight:`800`,style:{color:F1.text},children:l}):l:null,c&&!k?(0,H.jsx)(Y0,{saved:c,current:E,onLoad:D}):null,(0,H.jsx)(K0,{fields:t,view:E,onView:D,onCreate:d,createLabel:f,fieldOptions:h,extra:y,boardDisabled:b,...k?{count:C?C.total:O.length}:null,...ee}),E.kind===`board`?(0,H.jsx)($1,{fields:t,records:O,groupField:E.groupField??K1(t)??``,titleField:x,cardFields:S,onOpen:u,onRecordChange:M,onCreate:d?()=>d():void 0}):(0,H.jsx)(M1,{fields:t,records:O,loading:r,empty:i,sorts:E.sorts,onSortChange:e=>D(f0(E,e)),onOpen:u,selectable:g,bulkActions:v,editable:_,onEditCommit:p,fieldOptions:h,hiddenFields:E.hiddenFields,columnOrder:E.columnOrder,onColumnOrderChange:e=>D({...E,columnOrder:e}),pageSize:E.pageSize??25,remote:C})]})}function Y0({saved:e,current:t,onLoad:n}){return(0,H.jsxs)(y,{items:`center`,gap:4,style:{flexWrap:`wrap`},children:[e.views.map(r=>{let i=r.id===(e.activeId??t.id);return(0,H.jsxs)(y,{items:`center`,gap:6,px:10,py:6,rounded:8,cursor:`pointer`,onPress:()=>{e.onSelect(r.id),n(r)},style:{backgroundColor:i?F1.hover:`transparent`,borderBottomWidth:2,borderBottomColor:i?F1.accent:`transparent`},hoverStyle:i?void 0:{bg:F1.surfaceRaised},children:[(0,H.jsx)(U,{fontSize:13,fontWeight:i?`700`:`500`,style:{color:i?F1.text:F1.textMuted},children:r.name}),e.onDelete&&e.views.length>1&&(e.deletable?.(r.id)??!0)?(0,H.jsx)(z,{role:`button`,tabIndex:0,"aria-label":`Delete view ${r.name}`,cursor:`pointer`,onPress:t=>{t?.stopPropagation?.(),e.onDelete?.(r.id)},children:(0,H.jsx)(Rn,{size:12,color:F1.textFaint})}):null]},r.id)}),(0,H.jsxs)(y,{items:`center`,gap:4,px:10,py:6,rounded:8,cursor:`pointer`,hoverStyle:{bg:F1.surfaceRaised},onPress:()=>e.onSave({...t,id:`view-${Date.now()}`,name:`View ${e.views.length+1}`}),children:[(0,H.jsx)(hm,{size:13,color:F1.textFaint}),(0,H.jsx)(U,{fontSize:13,style:{color:F1.textFaint},children:`New view`})]})]})}var X0=e=>(e.kind===`upgrade`||e.kind===`topup`)&&!!e.url,Z0=[`premium`,`ours`,`free`],Q0=(e,t)=>e===`premium`?t(`Premium`):e===`ours`?`Hanzo`:t(`Free`),$0=[`ok`,`near`,`limited`],e2=[`plan`,`credits`,`free`,`none`],t2=[`upgrade`,`topup`,`credits`,`switch`],n2={upgrade:`Upgrade`,topup:`Add prepaid credit`,credits:`Continue with credits`,switch:`Switch model`,later:`Try again later`},r2=(e,t)=>t(e===`upgrade`?`Upgrade`:e===`topup`?`Add prepaid credit`:e===`credits`?`Continue with credits`:`Switch model`),i2={ok:0,near:1,limited:2},a2=e=>typeof e==`string`?e:null,o2=(e,t)=>typeof t==`string`&&e.includes(t)?t:null,s2=e=>e&&typeof e==`object`&&!Array.isArray(e)?e:null,c2=e=>!!e?.plan&&e?.plan!==`free`,l2=(e,t)=>i2[t]>i2[e]?t:e,u2=e=>typeof e==`number`&&Number.isFinite(e)?Math.min(100,Math.max(0,Math.round(e))):null;function d2(e){let t=s2(e),n=u2(t?.percent);return n===null?null:{percent:n,state:o2($0,t?.state)??(n>=80?`near`:`ok`),resets_at:a2(t?.resets_at)}}function f2(e){let t=d2(e);if(!t)return null;let n=s2(e),r=d2(n?.window);return{...t,paying:o2(e2,n?.paying)??`plan`,...r?{window:r}:{}}}function p2(e){return Array.isArray(e)?e.flatMap(e=>{let t=s2(e),n=o2(t2,t?.kind);if(!n)return[];let r=a2(t?.url)??void 0,i=a2(t?.model)??void 0,a=a2(t?.plan)??void 0;return(n===`upgrade`||n===`topup`)&&!r||n===`switch`&&!i?[]:[{kind:n,label:a2(t?.label)||n2[n],...r?{url:r}:{},...i?{model:i}:{},...a?{plan:a}:{}}]}):[]}var m2=e=>Array.isArray(e)?e.flatMap(e=>o2(Z0,e)?[e]:[]):[];function h2(e){return Array.isArray(e)?e.flatMap(e=>{let t=s2(e),n=a2(t?.model);if(!n)return[];let r=a2(t?.fallback);return[{model:n,...r?{fallback:r}:{},resets_at:a2(t?.resets_at)}]}):[]}function g2(e){let t=s2(e),n=a2(t?.plan);if(n===null)return null;let r={},i=s2(t?.classes);for(let e of Z0){let t=f2(i?.[e]);t&&(r[e]=t)}let a=h2(t?.paused),o=s2(t?.limited),s=o?{reason:a2(o.reason)??``,classes:m2(o.classes),message:a2(o.message)??``}:void 0,c=o2($0,t?.state)??Object.values(r).reduce((e,t)=>l2(e,t?l2(t.state,t.window?.state??`ok`):`ok`),`ok`);return{plan:n,period_start:a2(t?.period_start)??void 0,period_end:a2(t?.period_end)??void 0,state:c,classes:r,...s?{limited:s}:{},...a.length?{paused:a}:{},actions:p2(t?.actions),upgrade:a2(t?.upgrade)??void 0,...typeof t?.credits_after_allowance==`boolean`?{creditsAfterAllowance:t.credits_after_allowance}:{}}}function _2(e){let t=o2($0,e.get(`x-hanzo-usage`)),n=e.get(`x-hanzo-fallback`)||null,r=n&&(e.get(`x-hanzo-served`)||n);return!t&&!r?null:{state:t??`limited`,class:o2(Z0,e.get(`x-hanzo-usage-class`)),paidBy:o2(e2,e.get(`x-hanzo-paid-by`)),fallback:r,reason:e.get(`x-hanzo-usage-reason`)||null}}var v2=new Map([[`free_plan_cap`,`rate_limit_error`],[`usage_cap_exceeded`,`rate_limit_error`],[`allowance_spent`,`insufficient_quota`]]),y2=86400;function b2(e,t,n){let r=s2(s2(e)?.error);if(!r)return null;let i=a2(r.code)??``;if(r.type!==`billing_error`&&(!v2.has(i)||v2.get(i)!==r.type))return null;let a=n?Number(n):NaN;return{status:t,code:i,message:a2(r.message)??``,class:o2(Z0,r.class),resets_at:a2(r.resets_at),actions:p2(r.actions),retry:a>=0&&a<=y2?a:null}}function x2(e,t){if(!e)return null;let n={...e.classes},{served:r,refusal:i}=t;if(r?.class&&n[r.class]){let e=n[r.class];n[r.class]={...e,state:r.state}}if(i?.class&&n[i.class]){let e=n[i.class];n[i.class]={...e,state:`limited`,paying:`none`,resets_at:i.resets_at??e.resets_at}}let a=Object.values(n).reduce((e,t)=>l2(e,t?l2(t.state,t.window?.state??`ok`):`ok`),t.served||t.refusal?`ok`:e.state);return{...e,classes:n,state:l2(a,i?`limited`:`ok`)}}var S2=e=>e?e.window&&i2[e.window.state]>i2[e.state]?e.window.resets_at:e.resets_at:null,C2=e=>e.reduce((e,t)=>t&&(!e||Date.parse(t)<Date.parse(e))?t:e,null);function w2(e,t=Ft){let[n,r,i]=Z0.filter(t=>e.includes(t)).map(e=>Q0(e,t));return n?r?i?t(`{a}, {b} and {c} models`,{a:n,b:r,c:i}):t(`{a} and {b} models`,{a:n,b:r}):t(`{a} models`,{a:n}):t(`Models`)}function T2(e,t=Date.now()){let n=e?Date.parse(e):NaN;if(Number.isNaN(n))return``;let r=new Date(n);return n-t<864e5?r.toLocaleTimeString(`en-US`,{hour:`numeric`,minute:`2-digit`}):r.toLocaleDateString(`en-US`,{timeZone:`UTC`,month:`short`,day:`numeric`})}var E2=(e,t)=>e===`paid_plan_required`?t(`This model needs a paid plan.`):e===`free_plan_cap`?t(`You've used the free plan's usage for now.`):e===`insufficient_balance`?t(`Your credits have run out.`):void 0,D2=(e,t,n)=>e.endsWith(`*`)?n(`{family} models`,{family:`${e.slice(0,-1).split(`/`).pop()?.replace(/[-.]$/,``)}`}):t(e),O2=(e,t,n,r)=>n?r?e(`{what} are paused until {until}.`,{what:t,until:r}):e(`{what} are paused.`,{what:t}):r?e(`{what} is paused until {until}.`,{what:t,until:r}):e(`{what} is paused.`,{what:t});function k2(e,t,n=e=>e,r=Date.now(),i=Ft){let{served:a,refusal:o}=t,s=a?.fallback??null,c=new Set(e?.limited?.classes??[]);for(let t of Z0)t!==`free`&&e?.classes[t]?.state===`limited`&&c.add(t);if(o?.class&&c.add(o.class),s&&a?.class&&a.class!==`free`&&c.add(a.class),!o&&!s&&!e?.limited&&e?.state!==`limited`)return null;let l=o?.code||e?.limited?.reason||a?.reason||``,u=l===`model_cap`?e?.paused?.find(e=>s!==null&&e.fallback===s)??e?.paused?.[0]??null:null;u&&a?.class&&c.delete(a.class);let d=Z0.filter(e=>c.has(e)),f=u?u.resets_at??o?.resets_at??null:C2([...d.map(t=>S2(e?.classes[t])),o?.resets_at??null]),p=l===`plan_allowance_used`||!l&&d.length>0,m=T2(f,r),h=u?O2(i,D2(u.model,n,i),u.model.endsWith(`*`),m):p?O2(i,w2(d,i),!0,m):o?.message||e?.limited?.message||(l===`paid_plan_required`&&d.length?i(`{classes} need a paid plan.`,{classes:w2(d,i)}):E2(l,i))||i(`Usage is paused for now.`),g=o?.actions.length?o.actions:e?.actions??[];return{reason:l,classes:d,message:s?`${h} ${i(`You're chatting on {model}.`,{model:n(s)})}`:h,actions:g.map(e=>e.label===n2[e.kind]?{...e,label:r2(e.kind,i)}:e),resets_at:f,fallback:s,refused:o!==null}}function A2(e,t=Date.now(),n=Ft){if(!e||e.state===`limited`)return null;let r=Z0.filter(t=>{let n=e.classes[t];return t!==`free`&&n&&(n.state===`near`||n.window?.state===`near`)});if(!r.length)return null;let i=T2(C2(r.map(t=>S2(e.classes[t]))),t),a=r.length>1?n(`You're close to your plan's included premium and Hanzo model usage.`):r[0]===`premium`?n(`You're close to your plan's included premium model usage.`):n(`You're close to your plan's included Hanzo model usage.`);return i?`${a} ${n(`Resets {until}.`,{until:i})}`:a}var j2={served:null,refusal:null,at:0},M2=new Set,N2=e=>{j2=e;for(let e of M2)e()},P2=e=>(M2.add(e),()=>{M2.delete(e)}),F2=()=>j2,I2={served:null,refusal:null,at:0},L2=()=>I2;function R2(e){let t=_2(e.headers);if(e.ok){(t||j2.served||j2.refusal)&&N2({served:t,refusal:null,at:Date.now()});return}if(e.status!==402&&e.status!==429)return;let n=e.headers.get(`retry-after`);e.clone().json().then(r=>{let i=b2(r,e.status,n);i&&N2({served:t??j2.served,refusal:i,at:Date.now()})}).catch(()=>{})}function z2(e,t=null,n){let[r,i]=(0,V.useState)(null),[a,o]=(0,V.useState)(!1),[s,c]=(0,V.useState)(0),[l,u]=(0,V.useState)(0),d=(0,V.useRef)(e);d.current=e;let f=e!==null,p=(0,V.useSyncExternalStore)(P2,F2,L2),{t:m}=R();(0,V.useEffect)(()=>{let e=d.current;if(!e){i(null);return}let t=new AbortController,n=Date.now();return e(t.signal).then(e=>{t.signal.aborted||(i(g2(e)),c(n))}).catch(()=>{t.signal.aborted||i(null)}).finally(()=>{t.signal.aborted||o(!0)}),()=>t.abort()},[f,t,l]);let h=p.at>s,g=h&&(p.refusal!==null||p.served!==null&&(p.served.fallback!==null||p.served.class!==null&&r?.classes[p.served.class]?.state!==p.served.state));(0,V.useEffect)(()=>{g&&f&&u(e=>e+1)},[g,f,p.at]);let _=(0,V.useMemo)(()=>{if(h)return p;let e=p.served;return{served:e!==null&&(e.fallback!==null&&e.reason!==`plan_allowance_used`||r?.state===`limited`)?e:null,refusal:p.refusal}},[h,p,r?.state]),v=(0,V.useMemo)(()=>x2(r,_),[r,_]),y=(0,V.useRef)(n);y.current=n;let b=(0,V.useMemo)(()=>k2(v,_,e=>y.current?.(e)??e,Date.now(),m),[v,_,m]);return{limits:v,answered:a,notice:b,near:(0,V.useMemo)(()=>b?null:A2(v,Date.now(),m),[b,v,m]),reload:(0,V.useCallback)(()=>u(e=>e+1),[])}}function B2(e,t,n){let[r,i]=(0,V.useState)(t),[a,o]=(0,V.useState)(null),[s,c]=(0,V.useState)(!!e),[l,u]=(0,V.useState)(0),d=(0,V.useCallback)(()=>u(e=>e+1),[]);return(0,V.useEffect)(()=>{if(!e){c(!1);return}let t=!0;return c(!0),e().then(e=>{t&&(i(e),o(null))}).catch(e=>t&&o(e)).finally(()=>t&&c(!1)),()=>{t=!1}},[...n,l]),{value:r,error:a,loading:s,reload:d}}function V2({title:e,detail:t,action:n,children:r}){return(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsxs)(z,{flex:1,minW:0,gap:`$0.5`,children:[(0,H.jsx)(a,{size:`$3`,color:`$ink`,children:e}),t?(0,H.jsx)(a,{size:`$1`,color:`$soft`,children:t}):null]}),n]}),r]})}function H2({children:e}){return(0,H.jsx)(z,{borderWidth:1,borderColor:`$borderColor`,rounded:`$3`,overflow:`hidden`,children:e})}function U2({title:e,detail:t,leading:n,trailing:r,first:i,mono:o}){return(0,H.jsxs)(y,{items:`center`,gap:`$3`,px:`$3`,py:`$2.5`,borderTopWidth:+!i,borderColor:`$borderColor`,children:[n,(0,H.jsxs)(z,{flex:1,minW:0,gap:`$0.5`,children:[(0,H.jsx)(a,{size:`$2`,color:`$ink`,numberOfLines:1,style:o?{fontFamily:`var(--f-mono, ui-monospace, monospace)`}:void 0,children:e}),t?(0,H.jsx)(a,{size:`$1`,color:`$soft`,numberOfLines:2,children:t}):null]}),r]})}function W2({children:e}){return(0,H.jsx)(z,{py:`$5`,items:`center`,children:(0,H.jsx)(a,{size:`$2`,color:`$soft`,style:{textAlign:`center`},children:e})})}function G2(e){let t=e?new Date(e):null;return t&&!Number.isNaN(t.getTime())?t.toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,year:`numeric`,timeZone:`UTC`}):``}function K2({children:e}){return e?(0,H.jsx)(a,{size:`$1`,color:`$soft`,role:`status`,children:e}):null}var q2={free:D(`Free`),go:`Go`,dev:`Pro`,pro:`Pro`,max:`Max`,team:`Team`,agency:`Agency`,advisory:`Agency`,dedicated:`Agency`,pod:`Agency`,enterprise:`Enterprise`},J2={pro:`Pro`,enterprise:`Enterprise`},Y2=/^[0-9a-f]{8}-[0-9a-f]{4}-|[0-9a-f]{12,}|^[a-z]+_[0-9a-z]{6,}$|^\d+$/i,X2=e=>/^\d+x$/.test(e)?e:e.charAt(0).toUpperCase()+e.slice(1);function Z2(e,t,n){let r=(n??``).trim();if(r)return{name:r,tag:``};let i=(e??``).trim().toLowerCase(),a=()=>{let e=J2[(t??``).trim().toLowerCase()];return e?{name:e,tag:``}:null};if(!i)return a();if(Y2.test(i))return a()??{name:D(`Paid plan`),tag:``};let o=i.replace(/[\s_]+/g,`-`),[s,...c]=o.split(`-`).filter(Boolean),l=q2[s];if(!l)return{name:o.split(`-`).filter(Boolean).map(X2).join(` `),tag:``};let u=c.join(`-`);return{name:l,tag:/^\d+x$/.test(u)?u:/^(annual|yearly|year)$/.test(u)?D(`Annual`):u?c.map(X2).join(` `):``}}var Q2=e=>e?e.tag?`${e.name} ${e.tag}`:e.name:``,$2=[`ok`,`near`,`limited`],e4=e=>e&&typeof e==`object`&&!Array.isArray(e)?e:null;function t4(e){let t=e4(e),n=$2.find(e=>e===t?.state);return!t||!n||typeof t.percent!=`number`||!Number.isFinite(t.percent)?null:{percent:Math.min(100,Math.max(0,Math.round(t.percent))),state:n,resets:typeof t.resets_at==`string`?t.resets_at:``}}function n4(e,t,n){let r=(e??``).trim().toLowerCase();return r&&r!==`free`||J2[(n??``).trim().toLowerCase()]?`plan`:t!==null&&t>0?`credits`:`free`}function r4(e,t=Date.now()){let n=e?Date.parse(e):NaN;if(Number.isNaN(n))return``;let r=new Date(n);return n-t<864e5?r.toLocaleTimeString(`en-US`,{hour:`numeric`,minute:`2-digit`}):r.toLocaleDateString(`en-US`,{timeZone:`UTC`,month:`short`,day:`numeric`})}var i4={premium:`premium`,ours:`Hanzo`},a4={"":D(`usage`),premium:D(`premium model usage`),Hanzo:D(`Hanzo model usage`),"premium and Hanzo":D(`premium and Hanzo model usage`)};function o4(e,t,n,r=Date.now(),i=IK){let a=t.map(e=>i4[e]).filter(Boolean).join(` and `),o=a4[a]===void 0?`${a} model usage`:i(a4[a]),s=r4(n,r);if(!e)return s?i(`Your plan’s included {what} is used until {time}.`,{what:o,time:s}):i(`Your plan’s included {what} is used.`,{what:o});let c=Q2({name:i(e.name),tag:e.tag?i(e.tag):``});return s?i(`Your {plan} plan’s included {what} is used until {time}.`,{plan:c,what:o,time:s}):i(`Your {plan} plan’s included {what} is used.`,{plan:c,what:o})}function s4(e,t=IK){let n=t=>e.find(e=>e.kind===t),r=n(`topup`);return[n(`credits`)??(r?{...r,label:t(`Add credits`)}:void 0),n(`upgrade`),n(`switch`)].filter(e=>e!==void 0)}var c4=[`premium`,`ours`],l4=e=>typeof e==`string`?e:``,u4=e=>e&&typeof e==`object`&&!Array.isArray(e)?e:{},d4=e=>Array.isArray(e)?e:[],f4=[`upgrade`,`topup`,`credits`,`switch`],p4=[`ok`,`near`,`limited`];function m4(e){let t=t4(e);if(!t)return null;let n=u4(e);return{...t,paying:l4(n.paying)||`none`,window:t4(n.window)}}function h4(e){let t=u4(e),n={};for(let e of c4){let r=m4(u4(t.classes)[e]);r&&(n[e]=r)}let r=t.limited?u4(t.limited):null;return{plan:l4(t.plan)||`free`,start:l4(t.period_start),end:l4(t.period_end),state:p4.find(e=>e===t.state)??`ok`,session:t4(t.session),day:t4(t.day),classes:n,limited:r?{reason:l4(r.reason),classes:d4(r.classes).filter(e=>c4.includes(e)),message:l4(r.message)}:null,actions:d4(t.actions).map(u4).flatMap(e=>{let t=f4.find(t=>t===e.kind);if(!t)return[];let n=l4(e.url),r=l4(e.model);return(t===`upgrade`||t===`topup`)&&!n||t===`switch`&&!r?[]:[{kind:t,label:l4(e.label),url:n,plan:l4(e.plan),model:r}]}),upgrade:l4(t.upgrade),credits:t.credits_after_allowance===!0,paused:d4(t.paused).map(u4).filter(e=>l4(e.model)).map(e=>({model:l4(e.model),fallback:l4(e.fallback),resets:l4(e.resets_at)}))}}async function g4(e){return h4(await UK(e,`GET`,`/v1/ai/limits`))}async function _4(e,t){return h4(await UK(e,`PUT`,`/v1/ai/limits`,{creditsAfterAllowance:t}))}var v4=e=>e.status===`fulfilled`?e.value:null;async function y4(e){let t=await Promise.allSettled([rq(e),g4(e),uq(e),eq(e)]);if(t.every(e=>e.status===`rejected`))throw t[0].reason;let[n,r,i,a]=[v4(t[0]),v4(t[1]),v4(t[2]),v4(t[3])],o=n?.plan||(r&&r.plan!==`free`?r.plan:``),s=n4(o,a,n?.tier);return{kind:s,label:s===`plan`?Z2(o,n?.tier,n?.name):s===`free`?{name:D(`Free`),tag:``}:{name:D(`Pay as you go`),tag:``},limits:r,allowance:i,balance:a}}function b4(e,t=!0){return B2(t&&e.token()?()=>y4(e):null,null,[e,t])}function x4(e){return!e||e.limit<=0?null:Math.max(0,100-Math.round(Math.min(e.used,e.limit)/e.limit*100))}var S4={ok:`$soft`,near:`$yellow10`,limited:`$red10`};D(`Session`),D(`Today`),D(`Month`);function C4({label:e,size:t=`$3`}){let{t:n}=R();return(0,H.jsxs)(y,{items:`baseline`,gap:`$1.5`,minW:0,"data-slot":`plan-name`,children:[(0,H.jsx)(a,{size:t,color:`$ink`,style:{fontWeight:600},numberOfLines:1,children:n(e.name)}),e.tag?(0,H.jsx)(a,{size:`$1`,color:`$soft`,px:`$1.5`,rounded:`$2`,borderWidth:1,borderColor:`$borderColor`,"data-slot":`plan-tag`,children:n(e.tag)}):null]})}function w4(e){if(!e)return null;try{let t=e.split(`.`)[1];return t?JSON.parse(atob(t.replace(/-/g,`+`).replace(/_/g,`/`))):null}catch{return null}}var T4=[`owner`,`admin`];function E4(e,t){if(!t)return!1;let n=w4(e)?.orgs;return(Array.isArray(n)?n:[]).some(e=>{let n=e;return n?.org===t&&T4.includes(n.role)})}var D4=D(`Credits are separate from your plan’s usage allowance. They pay for usage past it when you choose to continue with credits, and for all usage when there is no plan.`);function O4({read:e}){let{t}=R();return(0,H.jsx)(a,{size:`$2`,color:e.error?`$soft`:`$ink`,numberOfLines:1,maxW:200,children:e.error?t(`Unavailable`):e.loading?`…`:JK(e.value)})}function k4({part:e,whole:t,limit:n}){let r=Math.min(100,Math.max(0,e/t*100));return(0,H.jsx)(z,{height:6,rounded:999,bg:`$hover`,overflow:`hidden`,role:`progressbar`,"aria-valuenow":Math.round(r),"aria-valuemin":0,"aria-valuemax":100,children:(0,H.jsx)(z,{height:6,width:`${r}%`,rounded:999,bg:n&&r>=100?`$red10`:`$ink`})})}function A4({title:e,used:t,of:n,says:r,first:i,limit:o=!0}){return(0,H.jsxs)(z,{gap:`$2`,px:`$3`,py:`$3`,borderTopWidth:+!i,borderColor:`$borderColor`,children:[(0,H.jsxs)(y,{items:`baseline`,justify:`space-between`,flexWrap:`wrap`,columnGap:`$3`,rowGap:`$1`,children:[(0,H.jsx)(a,{size:`$2`,color:`$ink`,children:e}),(0,H.jsx)(a,{size:`$1`,color:`$soft`,children:r})]}),(0,H.jsx)(k4,{part:t,whole:n,limit:o})]})}var j4=(e,t)=>G2(e)?t(`Resets {date}`,{date:G2(e)}):``;function M4({target:e,admin:t,add:n,onCard:r}){let{t:i}=R(),o=B2(()=>eq(e),0,[e]),s=B2(()=>tq(e),0,[e]),c=B2(()=>nq(e),[],[e]),l=B2(()=>cq(e),null,[e]),u=B2(()=>aq(e),null,[e]),d=B2(()=>fq(e),[],[e]),f=B2(n?null:()=>QK(e),[],[e,n]),[p,m]=(0,V.useState)(!1),[h,g]=(0,V.useState)(`25`),[_,v]=(0,V.useState)(``),[b,x]=(0,V.useState)(``),[S,C]=(0,V.useState)(``),[w,T]=(0,V.useState)(!1),[E,D]=(0,V.useState)(``);(0,V.useEffect)(()=>{u.value&&(x(u.value.threshold?String(u.value.threshold/100):``),C(u.value.amount?String(u.value.amount/100):``))},[u.value]);let O=async(e,t,n)=>{T(!0),D(``);try{await e(),n(),D(t)}catch(e){D(zK(e,i))}finally{T(!1)}},k=$K(f.value),A=YK(h),j=pq(d.value),ee=d.value.filter(e=>e!==j),M=l.value,N=Math.max(0,...(M?.categories??[]).map(e=>e.cents)),P=c.value.filter(e=>e.active&&e.remaining>0),te=()=>{if(!A)return D(i(`Enter an amount in dollars`));O(()=>sq(e,A,k.id),i(`{amount} is added to the balance`,{amount:JK(A)}),()=>{m(!1),o.reload()})},F=()=>{let t=YK(_);if(!t)return D(i(`Enter a monthly limit in dollars`));O(()=>mq(e,d.value,t),i(`Spend stops at {amount} a month`,{amount:JK(t)}),()=>{v(``),d.reload()})},I=t=>{let n=b.trim()===``||b.trim()===`0`?0:YK(b),r=YK(S);if(t&&(n===null||!r))return D(i(`Enter the balance to reload below and the amount to add, in dollars`));O(()=>oq(e,{enabled:t,threshold:n??0,amount:r??u.value?.amount??0}),t?i(`Adds {amount} whenever the balance falls below {floor}`,{amount:JK(r??0),floor:JK(n??0)}):i(`Auto-reload is off`),u.reload)};return(0,H.jsxs)(z,{gap:`$6`,"data-slot":`credits`,children:[(0,H.jsxs)(V2,{title:i(`Credits`),detail:i(D4),action:n?(0,H.jsx)(W,{size:`sm`,variant:`outline`,onPress:()=>window.open(n,`_blank`,`noopener`),children:i(`Add funds`)}):p||!t?void 0:(0,H.jsx)(W,{size:`sm`,variant:`outline`,onPress:()=>m(!0),children:i(`Buy more`)}),children:[(0,H.jsxs)(H2,{children:[(0,H.jsx)(U2,{first:!0,title:i(`Prepaid balance`),detail:i(`Bought with a card`),trailing:(0,H.jsx)(O4,{read:o})}),(0,H.jsx)(U2,{title:i(`Granted credit`),detail:i(`Given by Hanzo; some models take only prepaid`),trailing:(0,H.jsx)(O4,{read:s})}),(0,H.jsx)(U2,{title:i(`Spent this month`),detail:M&&!M.known?i(`The ledger did not answer, so this is not a measurement`):void 0,trailing:(0,H.jsx)(O4,{read:{...l,value:M?.total??0}})}),p?(0,H.jsx)(z,{gap:`$2`,px:`$3`,py:`$3`,borderTopWidth:1,borderColor:`$borderColor`,children:k?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(y,{gap:`$2`,items:`center`,flexWrap:`wrap`,children:[(0,H.jsx)(z,{width:140,children:(0,H.jsx)(j_,{value:h,onChangeText:g,"aria-label":i(`Amount in dollars`),placeholder:`25`,inputMode:`decimal`})}),(0,H.jsx)(a,{flex:1,minW:160,size:`$1`,color:`$soft`,children:i(`Charged to {card}`,{card:ZK(k)})})]}),(0,H.jsxs)(y,{gap:`$2`,justify:`flex-end`,children:[(0,H.jsx)(W,{size:`sm`,variant:`ghost`,onPress:()=>m(!1),children:i(`Cancel`)}),(0,H.jsx)(W,{size:`sm`,disabled:w,onPress:te,children:A?i(`Add {amount}`,{amount:JK(A)}):i(`Add funds`)})]})]}):(0,H.jsxs)(y,{gap:`$2`,items:`center`,flexWrap:`wrap`,children:[(0,H.jsx)(a,{flex:1,minW:160,size:`$2`,color:`$soft`,children:f.loading?i(`Reading cards…`):i(`Add a card to buy more.`)}),r?(0,H.jsx)(W,{size:`sm`,variant:`outline`,onPress:r,children:i(`Add card`)}):null]})}):null]}),P.length?(0,H.jsx)(H2,{children:P.map((e,t)=>(0,H.jsx)(U2,{first:t===0,title:e.name||i(`Credit grant`),detail:[i(`{left} left of {amount}`,{left:JK(e.remaining,e.currency),amount:JK(e.amount,e.currency)}),e.expires?i(`expires {date}`,{date:G2(e.expires)}):``].filter(Boolean).join(` · `)},e.id))}):null]}),(0,H.jsx)(V2,{title:i(`Auto-reload`),detail:i(`Tops the balance up from the card on file whenever it falls below a floor.`),children:u.error?(0,H.jsx)(W2,{children:zK(u.error,i)}):u.value?(0,H.jsxs)(H2,{children:[(0,H.jsx)(U2,{first:!0,title:u.value.enabled?i(`Adds {amount} below {floor}`,{amount:JK(u.value.amount),floor:JK(u.value.threshold)}):i(`Off`),detail:u.value.last?i(`Last reloaded {date}`,{date:G2(u.value.last)}):t?void 0:i(`An org admin sets auto-reload.`),trailing:t?(0,H.jsx)(av,{"aria-label":i(`Auto-reload`),checked:u.value.enabled,disabled:w,onCheckedChange:e=>I(e)}):void 0}),t?(0,H.jsxs)(y,{gap:`$2`,items:`center`,px:`$3`,py:`$3`,borderTopWidth:1,borderColor:`$borderColor`,flexWrap:`wrap`,children:[(0,H.jsx)(z,{width:150,children:(0,H.jsx)(j_,{value:b,onChangeText:x,"aria-label":i(`Reload below, in dollars`),placeholder:i(`Below {amount}`,{amount:`$5`}),inputMode:`decimal`})}),(0,H.jsx)(z,{width:150,children:(0,H.jsx)(j_,{value:S,onChangeText:C,"aria-label":i(`Amount to add, in dollars`),placeholder:i(`Add {amount}`,{amount:`$25`}),inputMode:`decimal`})}),(0,H.jsx)(y,{flex:1,justify:`flex-end`,children:(0,H.jsx)(W,{size:`sm`,variant:`outline`,disabled:w,onPress:()=>I(!0),children:u.value.enabled?i(`Save`):i(`Turn on`)})})]}):null]}):(0,H.jsx)(W2,{children:i(`Reading auto-reload…`)})}),(0,H.jsx)(V2,{title:i(`Spend this month`),detail:i(`What credits paid for, by kind.`),children:l.error?(0,H.jsx)(W2,{children:zK(l.error,i)}):M?M.categories.length===0?(0,H.jsx)(H2,{children:(0,H.jsx)(W2,{children:i(`Nothing spent this month.`)})}):(0,H.jsx)(H2,{children:M.categories.map((e,t)=>(0,H.jsx)(A4,{first:t===0,title:e.name,used:e.cents,of:N,says:JK(e.cents),limit:!1},e.name))}):(0,H.jsx)(W2,{children:i(`Reading spend…`)})}),(0,H.jsxs)(V2,{title:i(`Monthly limit`),detail:i(`Spend from credits past it is refused until the month starts over.`),children:[d.error?(0,H.jsx)(W2,{children:zK(d.error,i)}):(0,H.jsxs)(H2,{children:[j?(0,H.jsx)(A4,{first:!0,title:i(`{amount} a month`,{amount:JK(j.threshold)}),used:j.spent??0,of:j.threshold,says:[j.spent===null?i(`Spend unknown`):i(`{amount} spent`,{amount:JK(j.spent)}),j4(j.resets,i)].filter(Boolean).join(` · `)}):(0,H.jsx)(U2,{first:!0,title:i(`No monthly limit`),detail:i(`Spend is bounded by the balance alone.`)}),ee.map(e=>(0,H.jsx)(U2,{title:e.title||i(`Limit`),detail:[e.project&&i(`project {name}`,{name:e.project}),e.service&&i(`service {name}`,{name:e.service}),e.enforce?i(`refuses spend past it`):i(`warns only`)].filter(Boolean).join(` · `),trailing:(0,H.jsx)(a,{size:`$2`,color:`$ink`,children:e.threshold?JK(e.threshold):`—`})},e.id)),t?(0,H.jsxs)(y,{gap:`$2`,items:`center`,px:`$3`,py:`$3`,borderTopWidth:1,borderColor:`$borderColor`,flexWrap:`wrap`,children:[(0,H.jsx)(z,{width:160,children:(0,H.jsx)(j_,{value:_,onChangeText:v,"aria-label":i(`Monthly limit in dollars`),placeholder:j?String(j.threshold/100):`500`,inputMode:`decimal`})}),(0,H.jsxs)(y,{flex:1,gap:`$2`,justify:`flex-end`,children:[j?(0,H.jsx)(W,{size:`sm`,variant:`ghost`,disabled:w,onPress:()=>void O(()=>hq(e,j.id),i(`The monthly limit is lifted`),d.reload),children:i(`Remove`)}):null,(0,H.jsx)(W,{size:`sm`,variant:`outline`,disabled:w||!_.trim(),onPress:F,children:i(j?`Change limit`:`Set limit`)})]})]}):null]}),t?null:(0,H.jsx)(a,{size:`$1`,color:`$soft`,children:i(`An org admin sets the monthly limit.`)})]}),(0,H.jsx)(K2,{children:E})]})}var N4={premium:D(`Premium models`),ours:D(`Hanzo models`)},P4={ok:`$ink`,near:`$yellow10`,limited:`$red10`};function F4({percent:e,state:t}){return(0,H.jsx)(z,{height:6,rounded:999,bg:`$hover`,overflow:`hidden`,role:`progressbar`,"aria-valuenow":e,"aria-valuemin":0,"aria-valuemax":100,children:(0,H.jsx)(z,{height:6,width:`${e}%`,rounded:999,bg:P4[t]})})}function I4({title:e,w:t,first:n,says:r,now:i,children:o}){let{t:s}=R(),c=r4(t.resets,i);return(0,H.jsxs)(z,{gap:`$2`,px:`$3`,py:`$3`,borderTopWidth:+!n,borderColor:`$borderColor`,"data-slot":`plan-window`,"data-state":t.state,children:[(0,H.jsxs)(y,{items:`baseline`,justify:`space-between`,flexWrap:`wrap`,columnGap:`$3`,rowGap:`$1`,children:[(0,H.jsx)(a,{size:`$2`,color:`$ink`,children:e}),(0,H.jsx)(a,{size:`$1`,color:S4[t.state],style:{fontVariantNumeric:`tabular-nums`},children:[r??s(`{n}% used`,{n:t.percent}),c?s(`Resets {time}`,{time:c}):``].filter(Boolean).join(` · `)})]}),(0,H.jsx)(F4,{percent:t.percent,state:t.state}),o]})}function L4({s:e,target:t,onPlans:n,onBilling:r,now:i}){let{t:o}=R(),[s,c]=(0,V.useState)(null),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(``),p=s??e.limits,m=p?.actions.find(e=>e.kind===`upgrade`),h=async e=>{u(!0),f(``);try{c(await _4(t,e))}catch(e){f(zK(e,o))}finally{u(!1)}},g=e=>{if(e.kind===`credits`)return void h(!0);if(e.kind===`upgrade`&&n)return n();if(e.kind===`topup`)return r();e.url&&window.location.assign(e.url)},_=e.kind===`plan`&&p?c4.filter(e=>p.classes[e]?.state===`limited`):[],v=e.kind===`plan`?p?.paused[0]??null:null,b=_.map(e=>p.classes[e].resets).sort()[0]??``,x=v?r4(v.resets,i):``,S=v?v.model.replace(/\*$/,``):``,C=_.length?o4(e.label,_,b,i,o):v?v.fallback?x?o(`{model} is paused until {time}; chat continues on {fallback}.`,{model:S,time:x,fallback:v.fallback}):o(`{model} is paused; chat continues on {fallback}.`,{model:S,fallback:v.fallback}):x?o(`{model} is paused until {time}.`,{model:S,time:x}):o(`{model} is paused.`,{model:S}):``,w=(0,H.jsxs)(y,{items:`center`,gap:`$3`,flexWrap:`wrap`,"data-slot":`plan-head`,children:[(0,H.jsxs)(z,{flex:1,minW:200,gap:`$1`,children:[e.label?(0,H.jsx)(C4,{label:e.label,size:`$5`}):null,(0,H.jsx)(a,{size:`$2`,color:`$soft`,children:e.kind===`plan`?p?.start&&p.end?o(`Current period {start} – {end}`,{start:G2(p.start),end:G2(p.end)}):o(`Your plan`):e.kind===`free`?o(`Limited usage of free models, from a pool every free account shares.`):o(`No plan. Usage is paid from your credits.`)})]}),m&&!C||e.kind!==`plan`&&n?(0,H.jsx)(W,{size:`sm`,variant:e.kind===`plan`?`outline`:`primary`,onPress:()=>m?g(m):n?.(),children:m?.label||o(`Upgrade`)}):null]});if(e.kind===`free`){let t=x4(e.allowance),n=e.allowance;return(0,H.jsxs)(z,{gap:`$5`,"data-slot":`plan-usage`,"data-kind":`free`,children:[w,n&&t!==null?(0,H.jsxs)(H2,{children:[(0,H.jsx)(I4,{first:!0,title:n.window===`hour`?o(`This hour`):o(`Today`),w:{percent:100-t,state:t===0?`limited`:t<=20?`near`:`ok`,resets:n.resets},says:o(`{n}% left`,{n:t}),now:i}),n.pool?(0,H.jsx)(U2,{title:o(`Shared pool`),detail:n.pool.state===`exhausted`?r4(n.pool.resets,i)?o(`Used up until {time}`,{time:r4(n.pool.resets,i)}):o(`Used up`):n.pool.state===`busy`?o(`Busy. Try again in a minute.`):o(`Every free request is being served.`)}):null]}):(0,H.jsx)(W2,{children:o(`The free allowance could not be read.`)}),(0,H.jsxs)(y,{items:`center`,gap:`$3`,flexWrap:`wrap`,children:[(0,H.jsx)(a,{size:`$2`,color:`$soft`,flex:1,minW:200,children:o(`Credits pay as you go for any model, with or without a plan.`)}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,onPress:r,children:o(`Add credits`)})]})]})}if(e.kind===`credits`)return(0,H.jsxs)(z,{gap:`$5`,"data-slot":`plan-usage`,"data-kind":`credits`,children:[w,(0,H.jsx)(H2,{children:(0,H.jsx)(U2,{first:!0,title:o(`Credits`),detail:o(`What your usage is paid from, at each model’s list price.`),trailing:(0,H.jsx)(a,{size:`$2`,color:`$ink`,"data-slot":`plan-balance`,children:e.balance===null?o(`Unavailable`):JK(e.balance)})})}),(0,H.jsx)(y,{children:(0,H.jsx)(W,{size:`sm`,variant:`outline`,onPress:r,children:o(`Add funds`)})})]});let T=p?.credits??!1;return(0,H.jsxs)(z,{gap:`$5`,"data-slot":`plan-usage`,"data-kind":`plan`,children:[w,C?(0,H.jsxs)(y,{items:`center`,gap:`$2.5`,flexWrap:`wrap`,px:`$3`,py:`$2.5`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,"data-slot":`plan-spent`,children:[(0,H.jsx)(z,{width:8,height:8,rounded:4,bg:`$red10`,shrink:0,"aria-hidden":!0}),(0,H.jsx)(a,{size:`$2`,color:`$ink`,flex:1,minW:200,children:C}),(0,H.jsx)(y,{gap:`$2`,flexWrap:`wrap`,children:s4(p?.actions??[],o).map((e,t)=>(0,H.jsx)(W,{size:`sm`,variant:t===0?`primary`:`outline`,disabled:l,"data-kind":e.kind,onPress:()=>g(e),children:e.label},e.kind))})]}):null,p?!p.session&&!p.day&&!Object.keys(p.classes).length?(0,H.jsx)(W2,{children:o(`This plan sets no usage limits.`)}):(0,H.jsxs)(H.Fragment,{children:[p.session||p.day?(0,H.jsx)(V2,{title:o(`Requests`),detail:o(`Every request the plan covers counts in both.`),children:(0,H.jsxs)(H2,{children:[p.session?(0,H.jsx)(I4,{first:!0,title:o(`Session`),w:p.session,says:p.session.resets?void 0:[o(`{n}% used`,{n:p.session.percent}),o(`Starts with your next request`)].join(` · `),now:i}):null,p.day?(0,H.jsx)(I4,{first:!p.session,title:o(`Today`),w:p.day,now:i}):null]})}):null,Object.keys(p.classes).length?(0,H.jsx)(V2,{title:o(`By model class`),detail:o(`Each class’s share of the billing period, and of its shorter window where the plan sets one.`),children:(0,H.jsx)(H2,{children:c4.filter(e=>p.classes[e]).map((e,t)=>{let n=p.classes[e];return(0,H.jsx)(z,{"data-class":e,children:(0,H.jsx)(I4,{first:t===0,title:o(N4[e]),w:n,says:n.paying===`credits`?[o(`{n}% used`,{n:n.percent}),o(`Paying from credits`)].join(` · `):void 0,now:i,children:n.window?(0,H.jsxs)(y,{gap:`$2`,items:`center`,"data-slot":`plan-short`,children:[(0,H.jsx)(a,{size:`$1`,color:`$soft`,shrink:0,children:o(`Shorter window`)}),(0,H.jsx)(z,{flex:1,children:(0,H.jsx)(F4,{percent:n.window.percent,state:n.window.state})}),(0,H.jsx)(a,{size:`$1`,color:`$soft`,shrink:0,children:[`${n.window.percent}%`,r4(n.window.resets,i)?o(`Resets {time}`,{time:r4(n.window.resets,i)}):``].filter(Boolean).join(` · `)})]}):null})},e)})})}):null,(0,H.jsx)(V2,{title:o(`When the allowance runs out`),detail:o(`Credits are separate from your plan’s usage allowance. They live in Billing.`),children:(0,H.jsxs)(H2,{children:[(0,H.jsx)(U2,{first:!0,title:o(`Use credits when my plan’s allowance runs out`),detail:o(T?`On. A model whose included usage is used keeps working, paid from credits — prepaid first, then granted credit where the model takes it — at its list price.`:`Off. Chat continues on a free model, and other requests wait for the plan to reset.`),trailing:(0,H.jsx)(av,{"aria-label":o(`Use credits when my plan’s allowance runs out`),checked:T,disabled:l,onCheckedChange:e=>void h(e)})}),(0,H.jsx)(U2,{title:o(`Credits`),detail:e.balance===0?o(`There are no credits to spend yet.`):o(`The balance, top-ups and auto-reload.`),trailing:(0,H.jsx)(W,{size:`sm`,variant:`ghost`,onPress:r,children:e.balance===0?o(`Add credits`):o(`Billing`)})})]})})]}):(0,H.jsx)(W2,{children:o(`The plan’s usage could not be read.`)}),(0,H.jsx)(K2,{children:d})]})}function R4({target:e,onPlans:t,onBilling:n,now:r}){let{t:i}=R(),a=b4(e);return a.value?(0,H.jsx)(L4,{s:a.value,target:e,onPlans:t,onBilling:n,now:r}):(0,H.jsx)(W2,{children:a.error?zK(a.error,i):i(`Reading the plan…`)})}function z4(e){if(e.includes(`/`)){let[t,...n]=e.split(`/`);return{org:t,slug:n.join(`/`)}}return{org:`hanzo`,slug:e}}var B4={hanzo:`Hanzo`,openai:`OpenAI`,anthropic:`Anthropic`,google:`Google`,"meta-llama":`Meta`,"x-ai":`xAI`,mistralai:`Mistral`,deepseek:`DeepSeek`,qwen:`Qwen`,nvidia:`NVIDIA`,"z-ai":`Z.ai`,"arcee-ai":`Arcee AI`,minimax:`Minimax`,allenai:`Allen AI`,nousresearch:`Nous Research`,liquid:`Liquid AI`,moonshotai:`Moonshot AI`,amazon:`Amazon`,perplexity:`Perplexity`,baidu:`Baidu`,cohere:`Cohere`,"bytedance-seed":`ByteDance Seed`,openrouter:`OpenRouter`,microsoft:`Microsoft`,inflection:`Inflection`,sao10k:`Sao10K`,"aion-labs":`Aion Labs`,thedrummer:`TheDrummer`,stepfun:`StepFun`,relace:`Relace`,morph:`Morph`,inception:`Inception`,neversleep:`NeverSleep`,upstage:`Upstage`,writer:`Writer`,xiaomi:`Xiaomi`,"nex-agi":`Nex-AGI`,essentialai:`EssentialAI`,"prime-intellect":`Prime Intellect`,deepcogito:`DeepCogito`,kwaipilot:`KwaiPilot`,"ibm-granite":`IBM Granite`,alibaba:`Alibaba`,opengvlab:`OpenGVLab`,meituan:`Meituan`,ai21:`AI21`,bytedance:`ByteDance`,switchpoint:`Switchpoint`,cognitivecomputations:`Cognitive Computations`,tencent:`Tencent`,tngtech:`TNG Tech`,eleutherai:`EleutherAI`,alfredpros:`AlfredPros`,raifle:`Raifle`,"anthracite-org":`Anthracite`,alpindale:`Alpindale`,mancer:`Mancer`,undi95:`Undi95`,gryphe:`Gryphe`,meta:`Meta`,inclusionai:`inclusionAI`,thinkingmachines:`Thinking Machines`,rekaai:`Reka AI`,sakana:`Sakana AI`,perceptron:`Perceptron`};function V4(e){return e?B4[e]??e:`Hanzo`}var H4=`<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>`,U4=`</title><path d="`,W4=`"/></svg>`,G4={title:`Adroll`,slug:`adroll`,get svg(){return H4+`Adroll`+U4+this.path+W4},path:`M24 12c0-6.01-4.727-10.886-10.886-10.886a10.863 10.863 0 0 0-9.508 5.578L8.914 12c0-2.323 1.958-4.2 4.2-4.2 2.377 0 4.2 1.877 4.2 4.2s-1.836 4.2-4.2 4.2H4.065A4.07 4.07 0 0 0 0 20.266v2.62h13.114C19.232 22.886 24 18.01 24 12`,source:`https://www.adroll.com`,hex:`0DBDFF`},K4={title:`Cloudflare`,slug:`cloudflare`,get svg(){return H4+`Cloudflare`+U4+this.path+W4},path:`M16.5088 16.8447c.1475-.5068.0908-.9707-.1553-1.3154-.2246-.3164-.6045-.499-1.0615-.5205l-8.6592-.1123a.1559.1559 0 0 1-.1333-.0713c-.0283-.042-.0351-.0986-.021-.1553.0278-.084.1123-.1484.2036-.1562l8.7359-.1123c1.0351-.0489 2.1601-.8868 2.5537-1.9136l.499-1.3013c.0215-.0561.0293-.1128.0147-.168-.5625-2.5463-2.835-4.4453-5.5499-4.4453-2.5039 0-4.6284 1.6177-5.3876 3.8614-.4927-.3658-1.1187-.5625-1.794-.499-1.2026.119-2.1665 1.083-2.2861 2.2856-.0283.31-.0069.6128.0635.894C1.5683 13.171 0 14.7754 0 16.752c0 .1748.0142.3515.0352.5273.0141.083.0844.1475.1689.1475h15.9814c.0909 0 .1758-.0645.2032-.1553l.12-.4268zm2.7568-5.5634c-.0771 0-.1611 0-.2383.0112-.0566 0-.1054.0415-.127.0976l-.3378 1.1744c-.1475.5068-.0918.9707.1543 1.3164.2256.3164.6055.498 1.0625.5195l1.8437.1133c.0557 0 .1055.0263.1329.0703.0283.043.0351.1074.0214.1562-.0283.084-.1132.1485-.204.1553l-1.921.1123c-1.041.0488-2.1582.8867-2.5527 1.914l-.1406.3585c-.0283.0713.0215.1416.0986.1416h6.5977c.0771 0 .1474-.0489.169-.126.1122-.4082.1757-.837.1757-1.2803 0-2.6025-2.125-4.727-4.7344-4.727`,source:`https://www.cloudflare.com/logo/`,hex:`F38020`,guidelines:`https://www.cloudflare.com/trademark/`},q4={title:`Discord`,slug:`discord`,get svg(){return H4+`Discord`+U4+this.path+W4},path:`M20.317 4.3698a19.7913 19.7913 0 00-4.8851-1.5152.0741.0741 0 00-.0785.0371c-.211.3753-.4447.8648-.6083 1.2495-1.8447-.2762-3.68-.2762-5.4868 0-.1636-.3933-.4058-.8742-.6177-1.2495a.077.077 0 00-.0785-.037 19.7363 19.7363 0 00-4.8852 1.515.0699.0699 0 00-.0321.0277C.5334 9.0458-.319 13.5799.0992 18.0578a.0824.0824 0 00.0312.0561c2.0528 1.5076 4.0413 2.4228 5.9929 3.0294a.0777.0777 0 00.0842-.0276c.4616-.6304.8731-1.2952 1.226-1.9942a.076.076 0 00-.0416-.1057c-.6528-.2476-1.2743-.5495-1.8722-.8923a.077.077 0 01-.0076-.1277c.1258-.0943.2517-.1923.3718-.2914a.0743.0743 0 01.0776-.0105c3.9278 1.7933 8.18 1.7933 12.0614 0a.0739.0739 0 01.0785.0095c.1202.099.246.1981.3728.2924a.077.077 0 01-.0066.1276 12.2986 12.2986 0 01-1.873.8914.0766.0766 0 00-.0407.1067c.3604.698.7719 1.3628 1.225 1.9932a.076.076 0 00.0842.0286c1.961-.6067 3.9495-1.5219 6.0023-3.0294a.077.077 0 00.0313-.0552c.5004-5.177-.8382-9.6739-3.5485-13.6604a.061.061 0 00-.0312-.0286zM8.02 15.3312c-1.1825 0-2.1569-1.0857-2.1569-2.419 0-1.3332.9555-2.4189 2.157-2.4189 1.2108 0 2.1757 1.0952 2.1568 2.419 0 1.3332-.9555 2.4189-2.1569 2.4189zm7.9748 0c-1.1825 0-2.1569-1.0857-2.1569-2.419 0-1.3332.9554-2.4189 2.1569-2.4189 1.2108 0 2.1757 1.0952 2.1568 2.419 0 1.3332-.946 2.4189-2.1568 2.4189Z`,source:`https://discord.com/branding`,hex:`5865F2`,guidelines:`https://discord.com/branding`},J4={title:`Dropbox`,slug:`dropbox`,get svg(){return H4+`Dropbox`+U4+this.path+W4},path:`M6 1.807L0 5.629l6 3.822 6.001-3.822L6 1.807zM18 1.807l-6 3.822 6 3.822 6-3.822-6-3.822zM0 13.274l6 3.822 6.001-3.822L6 9.452l-6 3.822zM18 9.452l-6 3.822 6 3.822 6-3.822-6-3.822zM6 18.371l6.001 3.822 6-3.822-6-3.822L6 18.371z`,source:`https://www.dropbox.com/branding`,hex:`0061FF`},Y4={title:`Facebook`,slug:`facebook`,get svg(){return H4+`Facebook`+U4+this.path+W4},path:`M9.101 23.691v-7.98H6.627v-3.667h2.474v-1.58c0-4.085 1.848-5.978 5.858-5.978.401 0 .955.042 1.468.103a8.68 8.68 0 0 1 1.141.195v3.325a8.623 8.623 0 0 0-.653-.036 26.805 26.805 0 0 0-.733-.009c-.707 0-1.259.096-1.675.309a1.686 1.686 0 0 0-.679.622c-.258.42-.374.995-.374 1.752v1.297h3.919l-.386 2.103-.287 1.564h-3.246v8.245C19.396 23.238 24 18.179 24 12.044c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.628 3.874 10.35 9.101 11.647Z`,source:`https://about.meta.com/brand/resources/facebook/logo`,hex:`0866FF`,guidelines:`https://about.meta.com/brand/resources/facebook/logo`},X4={title:`Farcaster`,slug:`farcaster`,get svg(){return H4+`Farcaster`+U4+this.path+W4},path:`M18.24.24H5.76C2.5789.24 0 2.8188 0 6v12c0 3.1811 2.5789 5.76 5.76 5.76h12.48c3.1812 0 5.76-2.5789 5.76-5.76V6C24 2.8188 21.4212.24 18.24.24m.8155 17.1662v.504c.2868-.0256.5458.1905.5439.479v.5688h-5.1437v-.5688c-.0019-.2885.2576-.5047.5443-.479v-.504c0-.22.1525-.402.358-.458l-.0095-4.3645c-.1589-1.7366-1.6402-3.0979-3.4435-3.0979-1.8038 0-3.2846 1.3613-3.4435 3.0979l-.0096 4.3578c.2276.0424.5318.2083.5395.4648v.504c.2863-.0256.5457.1905.5438.479v.5688H4.3915v-.5688c-.0019-.2885.2575-.5047.5438-.479v-.504c0-.2529.2011-.4548.4536-.4724v-7.895h-.4905L4.2898 7.008l2.6405-.0005V5.0419h9.9495v1.9656h2.8219l-.6091 2.0314h-.4901v7.8949c.2519.0177.453.2195.453.4724`,source:`https://www.farcaster.xyz`,hex:`855DCD`},Z4={title:`GitHub`,slug:`github`,get svg(){return H4+`GitHub`+U4+this.path+W4},path:`M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12`,source:`https://github.com/logos`,hex:`181717`,guidelines:`https://github.com/logos`},Q4={title:`GitLab`,slug:`gitlab`,get svg(){return H4+`GitLab`+U4+this.path+W4},path:`m23.6004 9.5927-.0337-.0862L20.3.9814a.851.851 0 0 0-.3362-.405.8748.8748 0 0 0-.9997.0539.8748.8748 0 0 0-.29.4399l-2.2055 6.748H7.5375l-2.2057-6.748a.8573.8573 0 0 0-.29-.4412.8748.8748 0 0 0-.9997-.0537.8585.8585 0 0 0-.3362.4049L.4332 9.5015l-.0325.0862a6.0657 6.0657 0 0 0 2.0119 7.0105l.0113.0087.03.0213 4.976 3.7264 2.462 1.8633 1.4995 1.1321a1.0085 1.0085 0 0 0 1.2197 0l1.4995-1.1321 2.4619-1.8633 5.006-3.7489.0125-.01a6.0682 6.0682 0 0 0 2.0094-7.003z`,source:`https://about.gitlab.com/press/press-kit/`,hex:`FC6D26`,guidelines:`https://about.gitlab.com/handbook/marketing/corporate-marketing/brand-activation/trademark-guidelines/`},$4={title:`Gmail`,slug:`gmail`,get svg(){return H4+`Gmail`+U4+this.path+W4},path:`M24 5.457v13.909c0 .904-.732 1.636-1.636 1.636h-3.819V11.73L12 16.64l-6.545-4.91v9.273H1.636A1.636 1.636 0 0 1 0 19.366V5.457c0-2.023 2.309-3.178 3.927-1.964L5.455 4.64 12 9.548l6.545-4.91 1.528-1.145C21.69 2.28 24 3.434 24 5.457z`,source:`https://fonts.gstatic.com/s/i/productlogos/gmail_2020q4/v8/192px.svg`,hex:`EA4335`},e3={title:`Google Ads`,slug:`googleads`,get svg(){return H4+`Google Ads`+U4+this.path+W4},path:`M3.9998 22.9291C1.7908 22.9291 0 21.1383 0 18.9293s1.7908-3.9998 3.9998-3.9998 3.9998 1.7908 3.9998 3.9998-1.7908 3.9998-3.9998 3.9998zm19.4643-6.0004L15.4632 3.072C14.3586 1.1587 11.9121.5028 9.9988 1.6074S7.4295 5.1585 8.5341 7.0718l8.0009 13.8567c1.1046 1.9133 3.5511 2.5679 5.4644 1.4646 1.9134-1.1046 2.568-3.5511 1.4647-5.4644zM7.5137 4.8438L1.5645 15.1484A4.5 4.5 0 0 1 4 14.4297c2.5597-.0075 4.6248 2.1585 4.4941 4.7148l3.2168-5.5723-3.6094-6.25c-.4499-.7793-.6322-1.6394-.5878-2.4784z`,source:`https://ads.google.com/home/`,hex:`4285F4`},t3={title:`Google Calendar`,slug:`googlecalendar`,get svg(){return H4+`Google Calendar`+U4+this.path+W4},path:`M18.316 5.684H24v12.632h-5.684V5.684zM5.684 24h12.632v-5.684H5.684V24zM18.316 5.684V0H1.895A1.894 1.894 0 0 0 0 1.895v16.421h5.684V5.684h12.632zm-7.207 6.25v-.065c.272-.144.5-.349.687-.617s.279-.595.279-.982c0-.379-.099-.72-.3-1.025a2.05 2.05 0 0 0-.832-.714 2.703 2.703 0 0 0-1.197-.257c-.6 0-1.094.156-1.481.467-.386.311-.65.671-.793 1.078l1.085.452c.086-.249.224-.461.413-.633.189-.172.445-.257.767-.257.33 0 .602.088.816.264a.86.86 0 0 1 .322.703c0 .33-.12.589-.36.778-.24.19-.535.284-.886.284h-.567v1.085h.633c.407 0 .748.109 1.02.327.272.218.407.499.407.843 0 .336-.129.614-.387.832s-.565.327-.924.327c-.351 0-.651-.103-.897-.311-.248-.208-.422-.502-.521-.881l-1.096.452c.178.616.505 1.082.977 1.401.472.319.984.478 1.538.477a2.84 2.84 0 0 0 1.293-.291c.382-.193.684-.458.902-.794.218-.336.327-.72.327-1.149 0-.429-.115-.797-.344-1.105a2.067 2.067 0 0 0-.881-.689zm2.093-1.931l.602.913L15 10.045v5.744h1.187V8.446h-.827l-2.158 1.557zM22.105 0h-3.289v5.184H24V1.895A1.894 1.894 0 0 0 22.105 0zm-3.289 23.5l4.684-4.684h-4.684V23.5zM0 22.105C0 23.152.848 24 1.895 24h3.289v-5.184H0v3.289z`,source:`https://fonts.gstatic.com/s/i/productlogos/calendar_2020q4/v8/192px.svg`,hex:`4285F4`},n3={title:`Google Chrome`,slug:`googlechrome`,get svg(){return H4+`Google Chrome`+U4+this.path+W4},path:`M12 0C8.21 0 4.831 1.757 2.632 4.501l3.953 6.848A5.454 5.454 0 0 1 12 6.545h10.691A12 12 0 0 0 12 0zM1.931 5.47A11.943 11.943 0 0 0 0 12c0 6.012 4.42 10.991 10.189 11.864l3.953-6.847a5.45 5.45 0 0 1-6.865-2.29zm13.342 2.166a5.446 5.446 0 0 1 1.45 7.09l.002.001h-.002l-5.344 9.257c.206.01.413.016.621.016 6.627 0 12-5.373 12-12 0-1.54-.29-3.011-.818-4.364zM12 16.364a4.364 4.364 0 1 1 0-8.728 4.364 4.364 0 0 1 0 8.728Z`,source:`https://www.google.com/chrome`,hex:`4285F4`,guidelines:`https://partnermarketinghub.withgoogle.com/brands/chrome`},r3={title:`Google Drive`,slug:`googledrive`,get svg(){return H4+`Google Drive`+U4+this.path+W4},path:`M12.01 1.485c-2.082 0-3.754.02-3.743.047.01.02 1.708 3.001 3.774 6.62l3.76 6.574h3.76c2.081 0 3.753-.02 3.742-.047-.005-.02-1.708-3.001-3.775-6.62l-3.76-6.574zm-4.76 1.73a789.828 789.861 0 0 0-3.63 6.319L0 15.868l1.89 3.298 1.885 3.297 3.62-6.335 3.618-6.33-1.88-3.287C8.1 4.704 7.255 3.22 7.25 3.214zm2.259 12.653-.203.348c-.114.198-.96 1.672-1.88 3.287a423.93 423.948 0 0 1-1.698 2.97c-.01.026 3.24.042 7.222.042h7.244l1.796-3.157c.992-1.734 1.85-3.23 1.906-3.323l.104-.167h-7.249z`,source:`https://developers.google.com/drive/web/branding`,hex:`4285F4`},i3={title:`HubSpot`,slug:`hubspot`,get svg(){return H4+`HubSpot`+U4+this.path+W4},path:`M18.164 7.93V5.084a2.198 2.198 0 001.267-1.978v-.067A2.2 2.2 0 0017.238.845h-.067a2.2 2.2 0 00-2.193 2.193v.067a2.196 2.196 0 001.252 1.973l.013.006v2.852a6.22 6.22 0 00-2.969 1.31l.012-.01-7.828-6.095A2.497 2.497 0 104.3 4.656l-.012.006 7.697 5.991a6.176 6.176 0 00-1.038 3.446c0 1.343.425 2.588 1.147 3.607l-.013-.02-2.342 2.343a1.968 1.968 0 00-.58-.095h-.002a2.033 2.033 0 102.033 2.033 1.978 1.978 0 00-.1-.595l.005.014 2.317-2.317a6.247 6.247 0 104.782-11.134l-.036-.005zm-.964 9.378a3.206 3.206 0 113.215-3.207v.002a3.206 3.206 0 01-3.207 3.207z`,source:`https://www.hubspot.com/style-guide`,hex:`FF7A59`,guidelines:`https://www.hubspot.com/style-guide`},a3={title:`iCloud`,slug:`icloud`,get svg(){return H4+`iCloud`+U4+this.path+W4},path:`M13.762 4.29a6.51 6.51 0 0 0-5.669 3.332 3.571 3.571 0 0 0-1.558-.36 3.571 3.571 0 0 0-3.516 3A4.918 4.918 0 0 0 0 14.796a4.918 4.918 0 0 0 4.92 4.914 4.93 4.93 0 0 0 .617-.045h14.42c2.305-.272 4.041-2.258 4.043-4.589v-.009a4.594 4.594 0 0 0-3.727-4.508 6.51 6.51 0 0 0-6.511-6.27z`,source:`https://commons.wikimedia.org/wiki/File:ICloud_logo.svg`,hex:`3693F3`},o3={title:`Instagram`,slug:`instagram`,get svg(){return H4+`Instagram`+U4+this.path+W4},path:`M7.0301.084c-1.2768.0602-2.1487.264-2.911.5634-.7888.3075-1.4575.72-2.1228 1.3877-.6652.6677-1.075 1.3368-1.3802 2.127-.2954.7638-.4956 1.6365-.552 2.914-.0564 1.2775-.0689 1.6882-.0626 4.947.0062 3.2586.0206 3.6671.0825 4.9473.061 1.2765.264 2.1482.5635 2.9107.308.7889.72 1.4573 1.388 2.1228.6679.6655 1.3365 1.0743 2.1285 1.38.7632.295 1.6361.4961 2.9134.552 1.2773.056 1.6884.069 4.9462.0627 3.2578-.0062 3.668-.0207 4.9478-.0814 1.28-.0607 2.147-.2652 2.9098-.5633.7889-.3086 1.4578-.72 2.1228-1.3881.665-.6682 1.0745-1.3378 1.3795-2.1284.2957-.7632.4966-1.636.552-2.9124.056-1.2809.0692-1.6898.063-4.948-.0063-3.2583-.021-3.6668-.0817-4.9465-.0607-1.2797-.264-2.1487-.5633-2.9117-.3084-.7889-.72-1.4568-1.3876-2.1228C21.2982 1.33 20.628.9208 19.8378.6165 19.074.321 18.2017.1197 16.9244.0645 15.6471.0093 15.236-.005 11.977.0014 8.718.0076 8.31.0215 7.0301.0839m.1402 21.6932c-1.17-.0509-1.8053-.2453-2.2287-.408-.5606-.216-.96-.4771-1.3819-.895-.422-.4178-.6811-.8186-.9-1.378-.1644-.4234-.3624-1.058-.4171-2.228-.0595-1.2645-.072-1.6442-.079-4.848-.007-3.2037.0053-3.583.0607-4.848.05-1.169.2456-1.805.408-2.2282.216-.5613.4762-.96.895-1.3816.4188-.4217.8184-.6814 1.3783-.9003.423-.1651 1.0575-.3614 2.227-.4171 1.2655-.06 1.6447-.072 4.848-.079 3.2033-.007 3.5835.005 4.8495.0608 1.169.0508 1.8053.2445 2.228.408.5608.216.96.4754 1.3816.895.4217.4194.6816.8176.9005 1.3787.1653.4217.3617 1.056.4169 2.2263.0602 1.2655.0739 1.645.0796 4.848.0058 3.203-.0055 3.5834-.061 4.848-.051 1.17-.245 1.8055-.408 2.2294-.216.5604-.4763.96-.8954 1.3814-.419.4215-.8181.6811-1.3783.9-.4224.1649-1.0577.3617-2.2262.4174-1.2656.0595-1.6448.072-4.8493.079-3.2045.007-3.5825-.006-4.848-.0608M16.953 5.5864A1.44 1.44 0 1 0 18.39 4.144a1.44 1.44 0 0 0-1.437 1.4424M5.8385 12.012c.0067 3.4032 2.7706 6.1557 6.173 6.1493 3.4026-.0065 6.157-2.7701 6.1506-6.1733-.0065-3.4032-2.771-6.1565-6.174-6.1498-3.403.0067-6.156 2.771-6.1496 6.1738M8 12.0077a4 4 0 1 1 4.008 3.9921A3.9996 3.9996 0 0 1 8 12.0077`,source:`https://about.meta.com/brand/resources/instagram`,hex:`FF0069`,guidelines:`https://about.meta.com/brand/resources/instagram`},s3={title:`Linear`,slug:`linear`,get svg(){return H4+`Linear`+U4+this.path+W4},path:`M2.886 4.18A11.982 11.982 0 0 1 11.99 0C18.624 0 24 5.376 24 12.009c0 3.64-1.62 6.903-4.18 9.105L2.887 4.18ZM1.817 5.626l16.556 16.556c-.524.33-1.075.62-1.65.866L.951 7.277c.247-.575.537-1.126.866-1.65ZM.322 9.163l14.515 14.515c-.71.172-1.443.282-2.195.322L0 11.358a12 12 0 0 1 .322-2.195Zm-.17 4.862 9.823 9.824a12.02 12.02 0 0 1-9.824-9.824Z`,source:`https://linear.app`,hex:`5E6AD2`},c3={title:`Messenger`,slug:`messenger`,get svg(){return H4+`Messenger`+U4+this.path+W4},path:`M12 0C5.24 0 0 4.952 0 11.64c0 3.499 1.434 6.521 3.769 8.61a.96.96 0 0 1 .323.683l.065 2.135a.96.96 0 0 0 1.347.85l2.381-1.053a.96.96 0 0 1 .641-.046A13 13 0 0 0 12 23.28c6.76 0 12-4.952 12-11.64S18.76 0 12 0m6.806 7.44c.522-.03.971.567.63 1.094l-4.178 6.457a.707.707 0 0 1-.977.208l-3.87-2.504a.44.44 0 0 0-.49.007l-4.363 3.01c-.637.438-1.415-.317-.995-.966l4.179-6.457a.706.706 0 0 1 .977-.21l3.87 2.505c.15.097.344.094.491-.007l4.362-3.008a.7.7 0 0 1 .364-.13`,source:`https://about.meta.com/brand/resources/facebook/messenger-icon`,hex:`0866FF`,guidelines:`https://about.meta.com/brand/resources/facebook/messenger-icon`},l3={title:`Meta`,slug:`meta`,get svg(){return H4+`Meta`+U4+this.path+W4},path:`M6.915 4.03c-1.968 0-3.683 1.28-4.871 3.113C.704 9.208 0 11.883 0 14.449c0 .706.07 1.369.21 1.973a6.624 6.624 0 0 0 .265.86 5.297 5.297 0 0 0 .371.761c.696 1.159 1.818 1.927 3.593 1.927 1.497 0 2.633-.671 3.965-2.444.76-1.012 1.144-1.626 2.663-4.32l.756-1.339.186-.325c.061.1.121.196.183.3l2.152 3.595c.724 1.21 1.665 2.556 2.47 3.314 1.046.987 1.992 1.22 3.06 1.22 1.075 0 1.876-.355 2.455-.843a3.743 3.743 0 0 0 .81-.973c.542-.939.861-2.127.861-3.745 0-2.72-.681-5.357-2.084-7.45-1.282-1.912-2.957-2.93-4.716-2.93-1.047 0-2.088.467-3.053 1.308-.652.57-1.257 1.29-1.82 2.05-.69-.875-1.335-1.547-1.958-2.056-1.182-.966-2.315-1.303-3.454-1.303zm10.16 2.053c1.147 0 2.188.758 2.992 1.999 1.132 1.748 1.647 4.195 1.647 6.4 0 1.548-.368 2.9-1.839 2.9-.58 0-1.027-.23-1.664-1.004-.496-.601-1.343-1.878-2.832-4.358l-.617-1.028a44.908 44.908 0 0 0-1.255-1.98c.07-.109.141-.224.211-.327 1.12-1.667 2.118-2.602 3.358-2.602zm-10.201.553c1.265 0 2.058.791 2.675 1.446.307.327.737.871 1.234 1.579l-1.02 1.566c-.757 1.163-1.882 3.017-2.837 4.338-1.191 1.649-1.81 1.817-2.486 1.817-.524 0-1.038-.237-1.383-.794-.263-.426-.464-1.13-.464-2.046 0-2.221.63-4.535 1.66-6.088.454-.687.964-1.226 1.533-1.533a2.264 2.264 0 0 1 1.088-.285z`,source:`https://www.meta.com`,hex:`0467DF`,guidelines:`https://www.facebook.com/brand/resources/meta/company-brand`},u3={title:`Notion`,slug:`notion`,get svg(){return H4+`Notion`+U4+this.path+W4},path:`M4.459 4.208c.746.606 1.026.56 2.428.466l13.215-.793c.28 0 .047-.28-.046-.326L17.86 1.968c-.42-.326-.981-.7-2.055-.607L3.01 2.295c-.466.046-.56.28-.374.466zm.793 3.08v13.904c0 .747.373 1.027 1.214.98l14.523-.84c.841-.046.935-.56.935-1.167V6.354c0-.606-.233-.933-.748-.887l-15.177.887c-.56.047-.747.327-.747.933zm14.337.745c.093.42 0 .84-.42.888l-.7.14v10.264c-.608.327-1.168.514-1.635.514-.748 0-.935-.234-1.495-.933l-4.577-7.186v6.952L12.21 19s0 .84-1.168.84l-3.222.186c-.093-.186 0-.653.327-.746l.84-.233V9.854L7.822 9.76c-.094-.42.14-1.026.793-1.073l3.456-.233 4.764 7.279v-6.44l-1.215-.139c-.093-.514.28-.887.747-.933zM1.936 1.035l13.31-.98c1.634-.14 2.055-.047 3.082.7l4.249 2.986c.7.513.934.653.934 1.213v16.378c0 1.026-.373 1.634-1.68 1.726l-15.458.934c-.98.047-1.448-.093-1.962-.747l-3.129-4.06c-.56-.747-.793-1.306-.793-1.96V2.667c0-.839.374-1.54 1.447-1.632z`,source:`https://www.notion.so`,hex:`000000`},d3={title:`Pinterest`,slug:`pinterest`,get svg(){return H4+`Pinterest`+U4+this.path+W4},path:`M12.017 0C5.396 0 .029 5.367.029 11.987c0 5.079 3.158 9.417 7.618 11.162-.105-.949-.199-2.403.041-3.439.219-.937 1.406-5.957 1.406-5.957s-.359-.72-.359-1.781c0-1.663.967-2.911 2.168-2.911 1.024 0 1.518.769 1.518 1.688 0 1.029-.653 2.567-.992 3.992-.285 1.193.6 2.165 1.775 2.165 2.128 0 3.768-2.245 3.768-5.487 0-2.861-2.063-4.869-5.008-4.869-3.41 0-5.409 2.562-5.409 5.199 0 1.033.394 2.143.889 2.741.099.12.112.225.085.345-.09.375-.293 1.199-.334 1.363-.053.225-.172.271-.401.165-1.495-.69-2.433-2.878-2.433-4.646 0-3.776 2.748-7.252 7.92-7.252 4.158 0 7.392 2.967 7.392 6.923 0 4.135-2.607 7.462-6.233 7.462-1.214 0-2.354-.629-2.758-1.379l-.749 2.848c-.269 1.045-1.004 2.352-1.498 3.146 1.123.345 2.306.535 3.55.535 6.607 0 11.985-5.365 11.985-11.987C23.97 5.39 18.592.026 11.985.026L12.017 0z`,source:`https://business.pinterest.com/en/brand-guidelines`,hex:`BD081C`,guidelines:`https://business.pinterest.com/en/brand-guidelines`},f3={title:`QuickBooks`,slug:`quickbooks`,get svg(){return H4+`QuickBooks`+U4+this.path+W4},path:`M12 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0zm.642 4.1335c.9554 0 1.7296.776 1.7296 1.7332v9.0667h1.6c1.614 0 2.9275-1.3156 2.9275-2.933 0-1.6173-1.3136-2.9333-2.9276-2.9333h-.6654V7.3334h.6654c2.5722 0 4.6577 2.0897 4.6577 4.667 0 2.5774-2.0855 4.6666-4.6577 4.6666H12.642zM7.9837 7.333h3.3291v12.533c-.9555 0-1.73-.7759-1.73-1.7332V9.0662H7.9837c-1.6146 0-2.9277 1.316-2.9277 2.9334 0 1.6175 1.3131 2.9333 2.9277 2.9333h.6654v1.7332h-.6654c-2.5725 0-4.6577-2.0892-4.6577-4.6665 0-2.5771 2.0852-4.6666 4.6577-4.6666Z`,source:`https://design.intuit.com/quickbooks/brand`,hex:`2CA01C`,guidelines:`https://design.intuit.com/quickbooks/brand`},p3={title:`Reddit`,slug:`reddit`,get svg(){return H4+`Reddit`+U4+this.path+W4},path:`M12 0C5.373 0 0 5.373 0 12c0 3.314 1.343 6.314 3.515 8.485l-2.286 2.286C.775 23.225 1.097 24 1.738 24H12c6.627 0 12-5.373 12-12S18.627 0 12 0Zm4.388 3.199c1.104 0 1.999.895 1.999 1.999 0 1.105-.895 2-1.999 2-.946 0-1.739-.657-1.947-1.539v.002c-1.147.162-2.032 1.15-2.032 2.341v.007c1.776.067 3.4.567 4.686 1.363.473-.363 1.064-.58 1.707-.58 1.547 0 2.802 1.254 2.802 2.802 0 1.117-.655 2.081-1.601 2.531-.088 3.256-3.637 5.876-7.997 5.876-4.361 0-7.905-2.617-7.998-5.87-.954-.447-1.614-1.415-1.614-2.538 0-1.548 1.255-2.802 2.803-2.802.645 0 1.239.218 1.712.585 1.275-.79 2.881-1.291 4.64-1.365v-.01c0-1.663 1.263-3.034 2.88-3.207.188-.911.993-1.595 1.959-1.595Zm-8.085 8.376c-.784 0-1.459.78-1.506 1.797-.047 1.016.64 1.429 1.426 1.429.786 0 1.371-.369 1.418-1.385.047-1.017-.553-1.841-1.338-1.841Zm7.406 0c-.786 0-1.385.824-1.338 1.841.047 1.017.634 1.385 1.418 1.385.785 0 1.473-.413 1.426-1.429-.046-1.017-.721-1.797-1.506-1.797Zm-3.703 4.013c-.974 0-1.907.048-2.77.135-.147.015-.241.168-.183.305.483 1.154 1.622 1.964 2.953 1.964 1.33 0 2.47-.81 2.953-1.964.057-.137-.037-.29-.184-.305-.863-.087-1.795-.135-2.769-.135Z`,source:`https://www.redditinc.com/brand`,hex:`FF4500`,guidelines:`https://www.redditinc.com/brand`},m3={title:`Shopify`,slug:`shopify`,get svg(){return H4+`Shopify`+U4+this.path+W4},path:`M15.337 23.979l7.216-1.561s-2.604-17.613-2.625-17.73c-.018-.116-.114-.192-.211-.192s-1.929-.136-1.929-.136-1.275-1.274-1.439-1.411c-.045-.037-.075-.057-.121-.074l-.914 21.104h.023zM11.71 11.305s-.81-.424-1.774-.424c-1.447 0-1.504.906-1.504 1.141 0 1.232 3.24 1.715 3.24 4.629 0 2.295-1.44 3.76-3.406 3.76-2.354 0-3.54-1.465-3.54-1.465l.646-2.086s1.245 1.066 2.28 1.066c.675 0 .975-.545.975-.932 0-1.619-2.654-1.694-2.654-4.359-.034-2.237 1.571-4.416 4.827-4.416 1.257 0 1.875.361 1.875.361l-.945 2.715-.02.01zM11.17.83c.136 0 .271.038.405.135-.984.465-2.064 1.639-2.508 3.992-.656.213-1.293.405-1.889.578C7.697 3.75 8.951.84 11.17.84V.83zm1.235 2.949v.135c-.754.232-1.583.484-2.394.736.466-1.777 1.333-2.645 2.085-2.971.193.501.309 1.176.309 2.1zm.539-2.234c.694.074 1.141.867 1.429 1.755-.349.114-.735.231-1.158.366v-.252c0-.752-.096-1.371-.271-1.871v.002zm2.992 1.289c-.02 0-.06.021-.078.021s-.289.075-.714.21c-.423-1.233-1.176-2.37-2.508-2.37h-.115C12.135.209 11.669 0 11.265 0 8.159 0 6.675 3.877 6.21 5.846c-1.194.365-2.063.636-2.16.674-.675.213-.694.232-.772.87-.075.462-1.83 14.063-1.83 14.063L15.009 24l.927-21.166z`,source:`https://www.shopify.com/brand-assets`,hex:`7AB55C`,guidelines:`https://www.shopify.com/brand-assets`},h3={title:`Signal`,slug:`signal`,get svg(){return H4+`Signal`+U4+this.path+W4},path:`M12 0q-.934 0-1.83.139l.17 1.111a11 11 0 0 1 3.32 0l.172-1.111A12 12 0 0 0 12 0M9.152.34A12 12 0 0 0 5.77 1.742l.584.961a10.8 10.8 0 0 1 3.066-1.27zm5.696 0-.268 1.094a10.8 10.8 0 0 1 3.066 1.27l.584-.962A12 12 0 0 0 14.848.34M12 2.25a9.75 9.75 0 0 0-8.539 14.459c.074.134.1.292.064.441l-1.013 4.338 4.338-1.013a.62.62 0 0 1 .441.064A9.7 9.7 0 0 0 12 21.75c5.385 0 9.75-4.365 9.75-9.75S17.385 2.25 12 2.25m-7.092.068a12 12 0 0 0-2.59 2.59l.909.664a11 11 0 0 1 2.345-2.345zm14.184 0-.664.909a11 11 0 0 1 2.345 2.345l.909-.664a12 12 0 0 0-2.59-2.59M1.742 5.77A12 12 0 0 0 .34 9.152l1.094.268a10.8 10.8 0 0 1 1.269-3.066zm20.516 0-.961.584a10.8 10.8 0 0 1 1.27 3.066l1.093-.268a12 12 0 0 0-1.402-3.383M.138 10.168A12 12 0 0 0 0 12q0 .934.139 1.83l1.111-.17A11 11 0 0 1 1.125 12q0-.848.125-1.66zm23.723.002-1.111.17q.125.812.125 1.66c0 .848-.042 1.12-.125 1.66l1.111.172a12.1 12.1 0 0 0 0-3.662M1.434 14.58l-1.094.268a12 12 0 0 0 .96 2.591l-.265 1.14 1.096.255.36-1.539-.188-.365a10.8 10.8 0 0 1-.87-2.35m21.133 0a10.8 10.8 0 0 1-1.27 3.067l.962.584a12 12 0 0 0 1.402-3.383zm-1.793 3.848a11 11 0 0 1-2.345 2.345l.664.909a12 12 0 0 0 2.59-2.59zm-19.959 1.1L.357 21.48a1.8 1.8 0 0 0 2.162 2.161l1.954-.455-.256-1.095-1.953.455a.675.675 0 0 1-.81-.81l.454-1.954zm16.832 1.769a10.8 10.8 0 0 1-3.066 1.27l.268 1.093a12 12 0 0 0 3.382-1.402zm-10.94.213-1.54.36.256 1.095 1.139-.266c.814.415 1.683.74 2.591.961l.268-1.094a10.8 10.8 0 0 1-2.35-.869zm3.634 1.24-.172 1.111a12.1 12.1 0 0 0 3.662 0l-.17-1.111q-.812.125-1.66.125a11 11 0 0 1-1.66-.125`,source:`https://signal.org/brand`,hex:`3B45FD`,guidelines:`https://signal.org/brand`},g3={title:`Stripe`,slug:`stripe`,get svg(){return H4+`Stripe`+U4+this.path+W4},path:`M13.976 9.15c-2.172-.806-3.356-1.426-3.356-2.409 0-.831.683-1.305 1.901-1.305 2.227 0 4.515.858 6.09 1.631l.89-5.494C18.252.975 15.697 0 12.165 0 9.667 0 7.589.654 6.104 1.872 4.56 3.147 3.757 4.992 3.757 7.218c0 4.039 2.467 5.76 6.476 7.219 2.585.92 3.445 1.574 3.445 2.583 0 .98-.84 1.545-2.354 1.545-1.875 0-4.965-.921-6.99-2.109l-.9 5.555C5.175 22.99 8.385 24 11.714 24c2.641 0 4.843-.624 6.328-1.813 1.664-1.305 2.525-3.236 2.525-5.732 0-4.128-2.524-5.851-6.594-7.305h.003z`,source:`https://stripe.com/newsroom/information`,hex:`635BFF`},_3={title:`Supabase`,slug:`supabase`,get svg(){return H4+`Supabase`+U4+this.path+W4},path:`M11.9 1.036c-.015-.986-1.26-1.41-1.874-.637L.764 12.05C-.33 13.427.65 15.455 2.409 15.455h9.579l.113 7.51c.014.985 1.259 1.408 1.873.636l9.262-11.653c1.093-1.375.113-3.403-1.645-3.403h-9.642z`,source:`https://github.com/supabase/supabase/blob/4031a7549f5d46da7bc79c01d56be4177dc7c114/packages/common/assets/images/supabase-logo-wordmark--light.svg`,hex:`3FCF8E`},v3={title:`Telegram`,slug:`telegram`,get svg(){return H4+`Telegram`+U4+this.path+W4},path:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`,source:`https://telegram.org/tour/screenshots`,hex:`26A5E4`},y3={title:`Threads`,slug:`threads`,get svg(){return H4+`Threads`+U4+this.path+W4},path:`M18.263 11.097c-.03-3.486-1.92-5.586-5.111-5.586-2.13 0-3.922.963-4.863 2.499l2.062 1.438c.535-.843 1.272-1.543 2.628-1.543 1.528 0 2.318.85 2.544 2.431a15 15 0 0 0-2.236-.173c-4.125 0-6.068 1.867-6.068 4.336s1.943 3.99 4.804 3.99c3.139 0 5.013-2.115 5.781-4.735.798.361 1.348 1.204 1.348 2.47 0 3.387-3.907 5.232-7.22 5.232-4.885 0-8.077-3.207-8.077-8.424 0-6.392 4.223-10.487 9.9-10.487 3.808 0 5.69 1.671 6.97 3.914l2.108-1.475C21.44 2.078 18.331 0 13.663 0 6.227 0 1.168 5.277 1.168 12.934c0 7 4.953 11.066 10.856 11.066 4.878 0 9.809-2.846 9.809-7.716 0-2.545-1.46-4.231-3.569-5.187m-6.33 4.855c-1.077 0-2.026-.512-2.026-1.453 0-1.483 1.822-1.934 3.606-1.934.678 0 1.34.045 1.927.173-.422 1.927-1.671 3.215-3.508 3.214Z`,source:`https://www.meta.com/brand/resources/instagram/threads`,hex:`000000`,guidelines:`https://www.meta.com/brand/resources/instagram/threads`},b3={title:`TikTok`,slug:`tiktok`,get svg(){return H4+`TikTok`+U4+this.path+W4},path:`M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z`,source:`https://tiktok.com`,hex:`000000`},x3={title:`Twitch`,slug:`twitch`,get svg(){return H4+`Twitch`+U4+this.path+W4},path:`M11.571 4.714h1.715v5.143H11.57zm4.715 0H18v5.143h-1.714zM6 0L1.714 4.286v15.428h5.143V24l4.286-4.286h3.428L22.286 12V0zm14.571 11.143l-3.428 3.428h-3.429l-3 3v-3H6.857V1.714h13.714Z`,source:`https://brand.twitch.tv`,hex:`9146FF`,guidelines:`https://brand.twitch.tv`},S3={title:`WhatsApp`,slug:`whatsapp`,get svg(){return H4+`WhatsApp`+U4+this.path+W4},path:`M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413Z`,source:`https://about.meta.com/brand/resources/whatsapp/whatsapp-brand`,hex:`25D366`,guidelines:`https://about.meta.com/brand/resources/whatsapp/whatsapp-brand`},C3={title:`X`,slug:`x`,get svg(){return H4+`X`+U4+this.path+W4},path:`M14.234 10.162 22.977 0h-2.072l-7.591 8.824L7.251 0H.258l9.168 13.343L.258 24H2.33l8.016-9.318L16.749 24h6.993zm-2.837 3.299-.929-1.329L3.076 1.56h3.182l5.965 8.532.929 1.329 7.754 11.09h-3.182z`,source:`https://x.com`,hex:`000000`,guidelines:`https://about.x.com/en/who-we-are/brand-toolkit`},w3={title:`YouTube`,slug:`youtube`,get svg(){return H4+`YouTube`+U4+this.path+W4},path:`M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z`,source:`https://www.youtube.com/howyoutubeworks/resources/brand-resources/#logos-icons-and-colors`,hex:`FF0000`,guidelines:`https://www.youtube.com/howyoutubeworks/resources/brand-resources/#logos-icons-and-colors`},T3={title:`Zoom`,slug:`zoom`,get svg(){return H4+`Zoom`+U4+this.path+W4},path:`M5.033 14.649H.743a.74.74 0 0 1-.686-.458.74.74 0 0 1 .16-.808L3.19 10.41H1.06A1.06 1.06 0 0 1 0 9.35h3.957c.301 0 .57.18.686.458a.74.74 0 0 1-.161.808L1.51 13.59h2.464c.585 0 1.06.475 1.06 1.06zM24 11.338c0-1.14-.927-2.066-2.066-2.066-.61 0-1.158.265-1.537.686a2.061 2.061 0 0 0-1.536-.686c-1.14 0-2.066.926-2.066 2.066v3.311a1.06 1.06 0 0 0 1.06-1.06v-2.251a1.004 1.004 0 0 1 2.013 0v2.251c0 .586.474 1.06 1.06 1.06v-3.311a1.004 1.004 0 0 1 2.012 0v2.251c0 .586.475 1.06 1.06 1.06zM16.265 12a2.728 2.728 0 1 1-5.457 0 2.728 2.728 0 0 1 5.457 0zm-1.06 0a1.669 1.669 0 1 0-3.338 0 1.669 1.669 0 0 0 3.338 0zm-4.82 0a2.728 2.728 0 1 1-5.458 0 2.728 2.728 0 0 1 5.457 0zm-1.06 0a1.669 1.669 0 1 0-3.338 0 1.669 1.669 0 0 0 3.338 0z`,source:`https://brand.zoom.us/media-library/`,hex:`0B5CFF`,guidelines:`https://brand.zoom.us/usage-legal/`},E3={enso:pZ,hanzo:`<g transform="scale(0.3582089552238806)">${fZ}</g>`,ai2:`<path d="M9.553 9.378H4.777V4.835H8.62c.513 0 .932-.42.932-.932V.058h4.544v4.777a4.542 4.542 0 01-4.544 4.543zm-4.776.467H0v4.543h3.845c.512 0 .932.42.932.932v3.845H9.32v-4.777a4.542 4.542 0 00-4.543-4.543zM20.05 9.61a.935.935 0 01-.932-.932V4.835h-4.543V9.61a4.542 4.542 0 004.543 4.544h4.777V9.612H20.05zM9.787 19.166v4.777h4.544v-3.845c0-.513.42-.932.932-.932h3.845V14.62H14.33a4.542 4.542 0 00-4.544 4.544z"></path>`,ai21:`<path d="M6.47 17l-.367-1.189H2.718L2.35 17H0l3.398-9.789h2.026L8.864 17H6.47zm-2.052-6.993l-1.17 4.028H5.56l-1.142-4.028zm4.707-2.796h2.23V17h-2.23V7.211zM11.955 15c.1-.483.277-.946.524-1.37.214-.359.482-.68.795-.951.32-.273.658-.52 1.013-.741.28-.168.54-.33.781-.483.222-.14.433-.296.632-.468.172-.148.317-.325.428-.525.107-.199.16-.423.157-.65 0-.392-.104-.674-.313-.846a1.176 1.176 0 00-.775-.259 1.207 1.207 0 00-.863.329c-.231.219-.347.585-.347 1.098H11.8a3.387 3.387 0 01.224-1.245c.146-.377.371-.716.66-.993.306-.29.667-.514 1.06-.657A4.04 4.04 0 0115.183 7c.42-.002.84.057 1.244.175.376.107.73.287 1.04.531.305.246.55.562.714.923.185.419.275.875.265 1.335.005.39-.084.774-.259 1.12-.167.328-.38.63-.632.894-.246.259-.517.49-.808.693-.29.2-.554.37-.789.51-.326.224-.596.417-.809.58a3.872 3.872 0 00-.51.455 1.229 1.229 0 00-.265.434 1.633 1.633 0 00-.074.517h4.078V17h-6.606a9.24 9.24 0 01.183-2zM18.8 8.93a5.05 5.05 0 001.135-.105c.25-.049.484-.156.686-.314.163-.139.28-.324.34-.532.068-.25.1-.51.095-.77H23V17h-2.243v-6.475H18.8V8.93z"></path>`,aionlabs:`<path d="M8.303.964c.038.016.064.01.076-.016a.487.487 0 00.048-.034L8.76.66a2.845 2.845 0 011.5-.575c.078-.007.148-.007.211 0 .12.01.19.016.21.016.01 0 .02 0 .029.004a.416.416 0 00.148.021c.016 0 .031.002.046.006a.303.303 0 00.15.015c.34-.085.613-.133.82-.144.191-.01.42.012.688.067.454.092.864.288 1.23.588.048.04.13.114.249.223.007.006.015.01.024.011.037.006.07.001.099-.015a1.06 1.06 0 01.716-.12l.367.022c.235.023.446.083.632.18.096.048.223.128.383.238a.05.05 0 00.025.009c.047.003.091-.035.125-.03.033.004.068-.02.106-.024a3.47 3.47 0 01.815 0c.135.015.264.047.386.097.306.127.583.296.83.507.3.255.57.55.765.9.133.239.22.455.263.65.021.1.046.224.073.372.002.01.005.018.009.028.07.172.167.335.23.508.04.113.07.208.087.286.024.108.047.239.069.394.006.051.018.108.034.17a.142.142 0 00.046.073c.273.233.49.514.617.841.037.095.06.207.068.337.013.199.02.41-.042.598-.046.143-.076.23-.089.26a.085.085 0 00-.005.047c.016.105.023.18.02.225-.013.152-.021.265-.026.34a1.14 1.14 0 01-.121.43c-.247.5-.7.773-1.25.844a.236.236 0 00-.09.038c-.018.01-.02.034-.007.07a.062.062 0 01.003.023 2.592 2.592 0 01-.068.463c-.068.3-.205.55-.41.748a1.68 1.68 0 01-.742.41c-.036.01-.116.022-.24.034a.033.033 0 00-.027.022c-.01.033 0 .097-.017.15-.023.069-.006.17-.026.239-.02.065-.015.134-.024.215-.006.044-.023.163-.053.357a12.686 12.686 0 01-1.535 4.4c-.105.184-.23.366-.363.564a.07.07 0 00-.01.052c.089.486.185.956.32 1.416.08.272.182.523.383.715.057.054.155.121.296.203.63.367 1.277.656 1.985.963a.019.019 0 01.007.005.02.02 0 01.004.008.02.02 0 010 .009 2.052 2.052 0 01-.135.176c-.757.875-1.549 1.639-2.448 2.277a7.977 7.977 0 01-2.65 1.23.417.417 0 01-.087.017c-.01 0-.019.002-.027.008-.04.027-.092.01-.138.037a.063.063 0 01-.033.008.275.275 0 00-.12.02.081.081 0 01-.028.007c-.14.004-.259.029-.387.031-.327.007-.686.034-1.02.025a8.142 8.142 0 01-.646-.037 5.625 5.625 0 01-.613-.13 6.23 6.23 0 01-1.764-.73 4.407 4.407 0 01-1.199-1.098 1.296 1.296 0 01-.276-.625.734.734 0 00-.029-.163.679.679 0 00-.022-.192.17.17 0 01-.006-.045.648.648 0 00-.008-.127c-.025-.112-.02-.18-.037-.31a22.16 22.16 0 00-.173-1.086.667.667 0 01-.012-.104c-.002-.053-.027-.086-.026-.14a.28.28 0 00-.023-.129.051.051 0 01-.005-.027.358.358 0 00-.016-.134c-.023-.06-.008-.123-.036-.198a.1.1 0 01-.006-.036.33.33 0 00-.012-.115c-.026-.069-.008-.136-.04-.208a.063.063 0 01-.004-.027.357.357 0 00-.015-.124c-.023-.064-.006-.12-.03-.18-.021-.052-.004-.119-.028-.17-.025-.055-.008-.125-.032-.187-.019-.047-.003-.093-.023-.148-.02-.06-.008-.13-.032-.184-.016-.036-.01-.079-.019-.125l-.05-.267a.98.98 0 00-.061-.24.022.022 0 00-.02-.014.278.278 0 01-.07-.019 2.243 2.243 0 01-.69-.397 1.597 1.597 0 01-.48-.695 2.39 2.39 0 01-.104-.4c-.03-.17-.147-.303-.217-.43a1.498 1.498 0 01-.142-.384c-.01-.041-.004-.115-.028-.147a.017.017 0 01.004-.024c.018-.013.024-.044.016-.092-.006-.037-.024-.055-.053-.054a.03.03 0 01-.013-.002.03.03 0 01-.01-.008c-.26-.308-.456-.554-.545-.897a2.623 2.623 0 01-.086-.483 4.554 4.554 0 00-.021-.279.02.02 0 01-.005-.014.497.497 0 00.046-.183.323.323 0 00-.056-.251.123.123 0 01-.023-.052l-.078-.394a.114.114 0 01-.002-.037c.017-.149.028-.237.034-.264.045-.212.126-.406.244-.583a.025.025 0 00.004-.018.026.026 0 00-.01-.015 2.888 2.888 0 01-.927-1.357A2.66 2.66 0 013 8.36c.001-.148.008-.28.02-.397a2.276 2.276 0 01.656-1.395c.166-.168.356-.318.572-.452.037-.022.053-.053.05-.092a.417.417 0 00-.024-.103.077.077 0 01-.005-.028 20.28 20.28 0 01.004-1.105c.006-.126.038-.28.096-.462.175-.556.438-1.015.79-1.379.215-.222.449-.4.7-.535.162-.087.314-.142.396-.252.173-.233.373-.45.6-.65.312-.274.68-.447 1.103-.519.104-.017.229-.01.345-.027zm.106.32l-.24-.047a1.42 1.42 0 00-.59.115c-.674.296-1.225.917-1.414 1.616-.045.17-.053.305-.075.51a.087.087 0 01-.035.06c-.113.084-.26.186-.363.302a2.227 2.227 0 00-.355.53 1.45 1.45 0 00-.133.55.745.745 0 00-.009.282l.016.24a.016.016 0 01-.015.017.264.264 0 00-.131.046c-.305.204-.512.52-.631.862-.042.12-.118.326-.078.436a.042.042 0 00.043.027.043.043 0 00.018-.005.557.557 0 00.194-.177c.237-.315.489-.593.86-.758a1.79 1.79 0 011.076-.127 7.415 7.415 0 01.518.114.012.012 0 00.007-.016 1.69 1.69 0 01-.134-.5.827.827 0 010-.142l.015-.128a1.89 1.89 0 00.61 1.269c.254.231.557.338.898.375.237.026.46.028.671.006a.32.32 0 01.128-.009 1.735 1.735 0 001.225-.678v-.006a.013.013 0 00-.005-.006.012.012 0 00-.006-.002l-.434-.048a4.718 4.718 0 00-.369-.141c-.138-.046-.271-.05-.41-.068-.453-.058-.831-.371-.914-.841-.028-.318.026-.623.244-.865.065-.072.143-.148.233-.227a.088.088 0 00.03-.096.056.056 0 01-.001-.026l.067-.312.174-.325a.014.014 0 00-.014-.02 1.24 1.24 0 00-.877.605c-.186.309-.264.69-.152 1.03a.004.004 0 01-.002.005h-.003l-.002-.002c-.222-.418-.247-.911.03-1.309.253-.36.775-.712 1.247-.67a.03.03 0 00.024-.01l.203-.214a2.28 2.28 0 01.443-.352c.112-.068.259-.128.379-.194a.016.016 0 00.001-.027.784.784 0 00-.267-.118 2.217 2.217 0 00-.79-.046c-.45.054-.943.304-1.302.596a.012.012 0 01-.013.002.013.013 0 01-.008-.01c0-.01.001-.018.005-.024.16-.231.342-.419.546-.562.507-.357 1.193-.4 1.768-.204.128.061.25.133.367.215a.219.219 0 00.073.037.52.52 0 00.287-.064.36.36 0 00.187-.269.23.23 0 00-.004-.128.065.065 0 00-.016-.023c-.057-.05-.085-.106-.085-.168 0-.12.075-.2.199-.177a.478.478 0 01.168.076.605.605 0 01.11.435l.004.004a.011.011 0 00.011.002c.214-.088.363-.079.641-.091a.019.019 0 01.014.005.019.019 0 01.005.013v.21a.011.011 0 01-.01.011c-.24.026-.398.053-.475.08-.558.201-.93.583-1.113 1.144-.105.38-.085.752.06 1.113.126.301.32.55.578.745.442.332 1.015.404 1.552.291.111-.023.209-.07.3-.11a.004.004 0 00.002-.003.005.005 0 000-.006l-.004-.001a1.237 1.237 0 01-.87-.314 1.726 1.726 0 01-.213-.235.79.79 0 00.546.172c.226-.01.468-.102.6-.297a.024.024 0 00.003-.02.025.025 0 00-.005-.009.025.025 0 00-.008-.006c-.497-.249-.698-.726-.654-1.268a.134.134 0 01.032-.054.014.014 0 01.023.009l.003.038a.537.537 0 00.053.19c.147.316.371.546.67.686.47.221 1.122.188 1.551-.114a.712.712 0 00.258-.32.417.417 0 00-.043-.41c-.122-.153-.27-.194-.44-.123-.117.048-.187.133-.296.164-.55.159-1.123-.414-.907-.96a.503.503 0 01.346-.266l.1.004a1.048 1.048 0 00-.146.241c-.103.23-.046.492.174.62.12.058.235.06.342.004.095-.05.145-.141.213-.22a.394.394 0 01.273-.14c.486-.046.884.347 1.062.77.061.201.09.398.084.591l-.037.278-.024.106c-.08.118-.138.254-.177.406-.07.28.045.482.245.662a.008.008 0 00.01 0 .008.008 0 00.003-.008.977.977 0 01.01-.526l.11-.242c.147-.198.335-.327.563-.387a1.613 1.613 0 01.412-.047.012.012 0 00.004-.003.013.013 0 00.003-.005V3.87c-.049-.26-.03-.483.054-.669.264-.578.864-.658 1.409-.47.262.091.474.247.699.383a.011.011 0 00.012 0 .011.011 0 00.004-.005.454.454 0 00-.048-.163 2.018 2.018 0 00-1.123-1.113 2.008 2.008 0 00-.558-.102.306.306 0 01.276-.158.01.01 0 00.006-.002.01.01 0 00.003-.006.01.01 0 00-.007-.01 2.14 2.14 0 01-.19-.064 1.71 1.71 0 00-1.061-.062.033.033 0 00-.02.05l.087.152a.044.044 0 00.048.021c.057-.012.135-.02.235-.025a.694.694 0 01.415.108 1.79 1.79 0 00-1.339.788.201.201 0 01-.02-.04c-.015-.034-.041-.05-.054-.08-.022-.052.029-.156.058-.2.107-.16.245-.297.412-.41a.021.021 0 00.008-.027.74.74 0 00-.18-.248 1.394 1.394 0 00-.693-.434c-.512-.143-1.04-.067-1.457.256a9.16 9.16 0 00-.268.221c-.046.04-.093.053-.14.04a.798.798 0 00-.52.017c-.307.12-.544.371-.593.71-.004.03-.002.07-.006.104a.026.026 0 01-.02.022 1.331 1.331 0 00-.347.153c-.308.174-.442.441-.403.8.01.083.036.169.079.259l-.052.216c-.064-.083-.137-.169-.18-.255a.988.988 0 01-.035-.814c.08-.214.284-.44.534-.39a.167.167 0 01.119.08.026.026 0 00.025.012.025.025 0 00.02-.019c.01-.036.02-.082.026-.138.074-.558.534-1.062 1.136-1.077.039 0 .077-.012.11-.034l.284-.182a.012.012 0 00.005-.008v-.005a2.488 2.488 0 00-1.269-.735 2.637 2.637 0 00-1.47.116.132.132 0 01-.08.003A2.257 2.257 0 009.123.71a2.2 2.2 0 00-.24.165c-.157.138-.316.274-.474.41zm.965 2.196a1.215 1.215 0 00-.388.183.453.453 0 00-.112.11.057.057 0 00-.01.025c-.061.389-.04.825.21 1.152.455.6 1.252.715 1.936.475.121-.042.246-.124.356-.174a.012.012 0 00.005-.004.011.011 0 00.001-.007.011.011 0 00-.008-.01 1.759 1.759 0 01-.896-.665 1.446 1.446 0 01-.25-.516c-.094-.44-.04-.879.164-1.317.084-.166.184-.323.302-.47a.248.248 0 00.033-.051.01.01 0 000-.006.01.01 0 00-.006-.01 1.398 1.398 0 00-.517.167c-.42.238-.757.638-.82 1.118zm-4.8 2.044c.088-.12.184-.224.285-.31a.128.128 0 00.045-.087l.03-.347c.083-.455.288-.84.613-1.152a1.54 1.54 0 01.302-.211.032.032 0 00.016-.03 1.823 1.823 0 01.121-.713.015.015 0 00-.003-.016.015.015 0 00-.016-.003.59.59 0 00-.076.037 2.595 2.595 0 00-.825.75 3.317 3.317 0 00-.53 1.224 2.961 2.961 0 00-.036.947.005.005 0 00.009 0l.064-.089zm13.143-.942c-.136.069-.282.106-.438.11-.306.01-.548-.09-.7-.357a.018.018 0 00-.027-.005l-.085.071c-.322.25-.288.603-.04.893.168.198.38.326.634.384.448.101.9.014 1.242-.295.233-.21.37-.47.41-.782.01-.071.02-.158.028-.26a.077.077 0 01.063-.069.263.263 0 01.11.012c.435.119.668.58.77.984.003.016 0 .024-.01.025-.121.005-.25.017-.386.035a.016.016 0 00-.013.013l.001.01a.016.016 0 00.007.006c.143.076.274.283.258.445-.016.163-.034.329-.053.5-.015.139-.01.249-.009.422 0 .01.002.02.006.03.04.114.082.196.217.19.01 0 .018-.003.027-.007.166-.069.242-.24.286-.403.08-.282.069-.554-.035-.816a1.831 1.831 0 00-.112-.21 1.95 1.95 0 01-.108-.211 1.833 1.833 0 00-.02-.744c-.16-.667-.796-1.429-1.555-1.175a.81.81 0 00-.56.84c.013.111.06.243.092.364zm-2.6.49a2.111 2.111 0 01-.429.433c-.291.217-.615.349-.97.394-.157.02-.335.01-.48.014a.618.618 0 00-.315.11c-.162.104-.35.23-.53.316-.347.166-.71.25-1.09.25a8.8 8.8 0 01-.405-.007.302.302 0 00-.252.105 38.7 38.7 0 01-.397.443l-.322.215-.319.16c-.223.114-.4.269-.53.466-.119.18-.17.362-.26.626a1.477 1.477 0 01-.374.58l-.337.198a.017.017 0 00-.007.02c.012.033.032.078.058.136.11.24.135.491.077.756a.989.989 0 01-.217.414.846.846 0 01-.428.221c-.456.069-.788-.255-.978-.629l-.002-.002h-.003l-.002.002-.001.003.067.316c.028.131.095.297.17.435.054.096.104.19.15.283-.013.121-.063.2-.15.238-.1.043-.238-.005-.338-.048a15.309 15.309 0 01-.44-.2.372.372 0 01-.205-.209c-.058-.165-.107-.359-.173-.494a1.045 1.045 0 00-.588-.533.36.36 0 00-.121-.024c-.008-.013-.01-.017-.004-.012l-.03-.485c-.024-.32.024-.64.37-.756.48-.057.528.515.79.722a.013.013 0 00.015 0 .012.012 0 00.006-.012c-.044-.306-.09-.588-.296-.818a.518.518 0 00-.465-.176c-.416.047-.58.386-.622.762-.021.193-.024.371-.009.535.023.356.12.796.163 1.006.047.233.11.455.188.665.07.19.212.426.299.554.13.194.301.362.51.504.366.246.76.297 1.186.153.058.431.147.86.266 1.29.026.092.057.177.093.253.186.518.478.98.876 1.384.255.26.515.48.78.664.007.012.033.03.077.05a.6.6 0 00.106.094c.484.329 1.004.613 1.56.852l.239.103c.197.087.36.15.485.191.295.094.462.146.502.158.39.113.79.172 1.2.175.312.004.598-.049.869-.184.207-.105.424-.32.505-.553.162-.468-.062-.95-.47-1.214a1.54 1.54 0 00-.665-.287 1.85 1.85 0 00-.492-.029c.07-.11.115-.178.135-.204.133-.175.385-.209.584-.177.167.028.309.053.426.077.223.045.397-.064.352-.313a.362.362 0 00-.179-.272 2.06 2.06 0 00-.65-.223.944.944 0 00-.268-.02c-.22.028-.395.05-.524.063a.519.519 0 00-.287.152.412.412 0 01-.145-.06.216.216 0 01-.063-.107c.05-.172.161-.264.336-.275a.097.097 0 01.07.026c.162.152.362.091.557.024a.99.99 0 01.715.01c.087.034.298.125.42.112.142-.016.214-.1.215-.251a.062.062 0 00-.03-.054 4.639 4.639 0 01-.144-.1.14.14 0 01-.033-.036 3.76 3.76 0 01-.135-.218c-.085-.147-.238-.192-.397-.23a.506.506 0 01-.246-.154c.1-.196.272-.313.515-.349a.596.596 0 01.32.037c.269.11.46.186.575.227.312.11.649.115.818-.213a.6.6 0 00.086-.284c.02-.508.05-1.347.092-2.517l.039-1.008c.01-.273.084-.515.323-.668.19-.11.433-.097.645-.112.428-.03.485-.436.408-.77-.064-.356-.321-.667-.634-.838a2.432 2.432 0 00-.531-.207 3.244 3.244 0 01-.357-.148 2 2 0 01-.355-.263v-.004l.004-.002h.004l.202.091c.137.056.28.076.428.06.309-.032.485-.33.288-.6-.13-.18-.364-.324-.53-.439a2.118 2.118 0 01-.405-.376 1.616 1.616 0 01-.288-.516.004.004 0 00-.005 0l-.001.002a1.46 1.46 0 01-.241.55zm3.914.445c-.011.02-.018.064-.031.082-.183.239-.33.338-.595.532a.794.794 0 00-.257.319.01.01 0 00.009.01c.105.008.212.002.322-.018.501-.093.61-.479.567-.921l-.002-.005a.008.008 0 00-.009-.002.008.008 0 00-.004.003zM3.266 7.891c-.048.295-.042.593.018.893.09.507.311 1.007.687 1.366.048.046.106.09.175.13.014.014.028.018.042.011.107-.05.223-.125.35-.223a.031.031 0 00.012-.025v-.09a.071.071 0 00-.066-.07.834.834 0 01-.453-.177 1.05 1.05 0 01-.356-.521 6.047 6.047 0 00-.07-.203l.017-.145a.007.007 0 01.015 0c.036.23.177.527.395.634a.29.29 0 00.309-.025.779.779 0 00.173-.35.079.079 0 00-.032-.081c-.355-.24-.385-.6-.078-.88.358-.325.868-.352 1.273-.125.034.019.087.053.157.104.05.036.102.072.155.107.075.074.17.158.285.25.2.163.408.24.67.25.411.017.748-.127 1.01-.432.127-.147.187-.294.292-.512a.919.919 0 01.611-.511.007.007 0 00-.004-.01l-.318-.069a1.755 1.755 0 00-.358-.045 1.02 1.02 0 00-.534.081c-.196.09-.357.28-.555.334-.267.073-.471-.005-.611-.233a.34.34 0 01-.034-.158l.009-.007c.213.276.51.121.558-.178a.66.66 0 00-.106-.473c-.213-.316-.518-.463-.916-.441-.397.022-.773.248-1.022.548-.192.232-.402.547-.709.458-.226-.066-.235-.278-.19-.477a.01.01 0 00-.015-.01c-.09.056-.165.115-.224.176a2.093 2.093 0 00-.562 1.129zm3.221 1.627a.99.99 0 00.174.337c.054.068.115.132.181.193.08.157.178.264.293.321.26.13.554.024.658-.251.078-.237.047-.444-.092-.62a.626.626 0 00-.435-.239 2.97 2.97 0 00-.527.017l-.35-.21a.01.01 0 00-.011 0 .01.01 0 00-.005.011c.016.16.054.307.114.44zM4.23 10.86a1.16 1.16 0 00-.08.132c-.074.158-.109.323-.102.495.01.26.196.672.528.6a.343.343 0 00.249-.202.3.3 0 00.042-.15 1.418 1.418 0 00-.093-.4 2.793 2.793 0 01-.16-.754.036.036 0 00-.008-.019.017.017 0 00-.01-.006c-.004-.001-.008 0-.012.002a1.674 1.674 0 00-.354.302zm.109 2.45a1.921 1.921 0 00.337.464c.002.001.003.002.005.001a.013.013 0 00.01-.004l.08-.096a1.21 1.21 0 01.622-.114c.03.003.06.005.091.004l.15.082c.084.057.17.115.257.176a2.12 2.12 0 01.272.259h.003a.005.005 0 00.002-.002v-.003a1.983 1.983 0 00-.133-.625 1.117 1.117 0 00-.635-.61 33.41 33.41 0 00-.275-.285.482.482 0 00-.413-.152.752.752 0 01-.516-.07.01.01 0 00-.008.004 1.79 1.79 0 00.151.971zm2.137 1.902c.006.025.008.037.006.037.023.307.058.602.106.887.045.443.092.81.14 1.1l.419 2.536c.092.552.126.872.185 1.457.022.214.095.407.218.578.203.283.438.53.705.744.459.367.97.646 1.534.838.444.168.906.28 1.385.339.476.054.963.053 1.461-.004.395-.038.794-.12 1.196-.245.119-.038.304-.104.554-.2a.891.891 0 00.114-.06.588.588 0 00.128-.046c.311-.15.613-.308.905-.473a2.43 2.43 0 00.276-.185v-.007a.012.012 0 00-.005-.005.011.011 0 00-.007-.002c-.716.065-1.372-.067-2.035-.383-.574-.273-1.088-.718-1.552-1.21a26.147 26.147 0 01-1.289-1.46l-2.286-2.761a9.577 9.577 0 01-.753-1.023 4.608 4.608 0 01-.577-1.342l-.147-.61a.018.018 0 00-.019-.014c-.45.038-.68.566-.688.958a3.17 3.17 0 00.026.556zm-1.47-1.214a.506.506 0 00-.027.551.638.638 0 00.231.251.105.105 0 00.088.011c.302-.095.58-.148.887-.034h.004a.008.008 0 00.004-.002.007.007 0 00.001-.008 1.908 1.908 0 00-.302-.475 1.227 1.227 0 00-.432-.357.533.533 0 00-.21-.065c-.098-.003-.18.04-.244.128zm.96 2.255a.76.76 0 00.244.08l.14.016a.033.033 0 00.031-.018 2.273 2.273 0 00-.07-.799.02.02 0 00-.007-.01.019.019 0 00-.012-.004c-.179.008-.356.033-.533.074-.009-.01-.023-.016-.043-.018a1.019 1.019 0 01-.384-.434.012.012 0 00-.017.009c-.069.454.279.892.652 1.104z"></path><path d="M7.126 3.698a2.128 2.128 0 00-.016 1.07l-.091-.023c-.31-.215-.696-.139-.966.09a.02.02 0 01-.018.005.978.978 0 00-.294-.023c.15-.23.352-.383.604-.457.083-.024.187-.044.31-.058a.023.023 0 00.018-.015c.091-.24.242-.436.453-.59zM14.187 8.01c.415.181.695.507.724.97a.035.035 0 01-.009.025l-.018.021c-.241.232-.463.462-.735.66-.23.165-.56.315-.849.297a.335.335 0 01-.24-.112.968.968 0 01-.038-.37.043.043 0 00-.038-.047.448.448 0 01-.148-.045c.06-.134.094-.251.102-.352.029-.327-.238-.5-.53-.538a1.515 1.515 0 00-.7.074c-.1.03-.193.073-.279.126a.756.756 0 00-.164.14 9.013 9.013 0 00-.144.164.02.02 0 00-.004.012c0 .005.002.01.005.013.015.016.022.031.021.046l-.178.074-.172-.031a6.66 6.66 0 00-.755-.142 3.515 3.515 0 01-.465-.116c.215.01.404 0 .565-.033a2.67 2.67 0 00.502-.156c.564-.236.991-.43 1.538-.496a.041.041 0 00.035-.032c.047-.211.19-.285.397-.327.138-.029.313-.035.526-.02.378.028.715.066 1.05.196z"></path>`,alibaba:`<path d="M24 14.014c-2.8 1.512-5.62 2.896-8.759 3.524-.7.139-1.476.139-2.187.043-.678-.085-1.017-.682-.776-1.31.23-.585.536-1.181.93-1.671.852-1.065 1.814-2.034 2.678-3.088a15.75 15.75 0 001.422-2.054c.306-.511.164-1.129-.372-1.384-.897-.437-1.859-.745-2.81-1.075-.11-.043-.274.074-.492.149.273.244.47.425.743.67-2.821.48-5.49 1.16-8.08 2.098-.012.053-.033.095-.023.117.383.585.208 1.032-.35 1.394a2.365 2.365 0 00-.568.522c1.706.5 3.226.213 4.68-.735-.087-.127-.175-.244-.262-.372.546.096.874.394.918.862.011.107-.054.213-.087.32-.077-.086-.175-.17-.24-.267-.045-.064-.056-.138-.088-.245-1.728 1.15-3.587 1.438-5.632.842 0 .404-.022.745.011 1.075.022.287-.098.415-.36.564-.591.362-1.204.735-1.696 1.214-.59.585-.371 1.299.427 1.597.907.34 1.859.35 2.81.234 1.126-.139 2.23-.32 3.456-.49-1.433.67-2.844 1.14-4.33 1.33-1.04.14-2.078.214-3.106-.084-1.476-.415-2.133-1.501-1.75-2.96.361-1.363 1.236-2.449 2.176-3.45 3.139-3.332 7.108-5.024 11.7-5.365 1.072-.074 2.155.064 3.16.511 1.411.639 2.002 1.99 1.313 3.354-.448.905-1.072 1.735-1.695 2.555-.612.809-1.301 1.554-1.946 2.331-.186.234-.361.48-.503.745-.274.5-.088.83.492.778 1.213-.118 2.45-.213 3.62-.511 1.716-.437 3.389-1.054 5.084-1.597.175-.043.339-.107.492-.17z"></path>`,anthropic:`<path d="M13.827 3.52h3.603L24 20h-3.603l-6.57-16.48zm-7.258 0h3.767L16.906 20h-3.674l-1.343-3.461H5.017l-1.344 3.46H0L6.57 3.522zm4.132 9.959L8.453 7.687 6.205 13.48H10.7z"></path>`,antigravity:`<g transform="scale(0.24)"><path d="M85.2843 88.0301C90.1329 91.6664 97.4057 89.2422 90.7389 82.5755C70.7389 63.1816 74.9813 9.84827 50.1329 9.84827C25.2843 9.84827 29.5267 63.1816 9.52673 82.5755C2.25402 89.8483 10.1328 91.6664 14.9813 88.0301C33.7692 75.3028 32.5571 52.8786 50.1329 52.8786C67.7086 52.8786 66.4965 75.3028 85.2843 88.0301Z"></path></g>`,arcee:`<path d="M13.236 2.377L2.751 20.493H0L11.863 0l1.373 2.377zm3.554 6.156l-9.606 11.96H4.13L15.511 6.32l1.279 2.212zm6.908 11.96H14.05l8.406-2.151 1.242 2.15zm-3.42-5.922l-7.843 5.92H8.482l10.597-7.997 1.2 2.077z"></path>`,aws:`<path d="M6.763 11.212c0 .296.032.535.088.71.064.176.144.368.256.576.04.063.056.127.056.183 0 .08-.048.16-.152.24l-.503.335a.383.383 0 01-.208.072c-.08 0-.16-.04-.239-.112a2.47 2.47 0 01-.287-.375 6.18 6.18 0 01-.248-.471c-.622.734-1.405 1.101-2.347 1.101-.67 0-1.205-.191-1.596-.574-.39-.384-.59-.894-.59-1.533 0-.678.24-1.23.726-1.644.487-.415 1.133-.623 1.955-.623.272 0 .551.024.846.064.296.04.6.104.918.176v-.583c0-.607-.127-1.03-.375-1.277-.255-.248-.686-.367-1.3-.367-.28 0-.568.031-.863.103-.295.072-.583.16-.862.272-.09.04-.184.075-.28.104a.488.488 0 01-.127.023c-.112 0-.168-.08-.168-.247v-.391c0-.128.016-.224.056-.28a.597.597 0 01.224-.167 4.577 4.577 0 011.005-.36 4.84 4.84 0 011.246-.151c.95 0 1.644.216 2.091.647.44.43.662 1.085.662 1.963v2.586h.016zm-3.24 1.214c.263 0 .534-.048.822-.144a1.78 1.78 0 00.758-.51 1.27 1.27 0 00.272-.512c.047-.191.08-.423.08-.694v-.335a6.66 6.66 0 00-.735-.136 6.02 6.02 0 00-.75-.048c-.535 0-.926.104-1.19.32-.263.215-.39.518-.39.917 0 .375.095.655.295.846.191.2.47.296.838.296zm6.41.862c-.144 0-.24-.024-.304-.08-.064-.048-.12-.16-.168-.311L7.586 6.726a1.398 1.398 0 01-.072-.32c0-.128.064-.2.191-.2h.783c.151 0 .255.025.31.08.065.048.113.16.16.312l1.342 5.284 1.245-5.284c.04-.16.088-.264.151-.312a.549.549 0 01.32-.08h.638c.152 0 .256.025.32.08.063.048.12.16.151.312l1.261 5.348 1.381-5.348c.048-.16.104-.264.16-.312a.52.52 0 01.311-.08h.743c.127 0 .2.065.2.2 0 .04-.009.08-.017.128a1.137 1.137 0 01-.056.2l-1.923 6.17c-.048.16-.104.263-.168.311a.51.51 0 01-.303.08h-.687c-.15 0-.255-.024-.32-.08-.063-.056-.119-.16-.15-.32L12.32 7.747l-1.23 5.14c-.04.16-.087.264-.15.32-.065.056-.177.08-.32.08l-.686.001zm10.256.215c-.415 0-.83-.048-1.229-.143-.399-.096-.71-.2-.918-.32-.128-.071-.215-.151-.247-.223a.563.563 0 01-.048-.224v-.407c0-.167.064-.247.183-.247.048 0 .096.008.144.024.048.016.12.048.2.08.271.12.566.215.878.279.32.064.63.096.95.096.502 0 .894-.088 1.165-.264a.86.86 0 00.415-.758.777.777 0 00-.215-.559c-.144-.151-.416-.287-.807-.415l-1.157-.36c-.583-.183-1.014-.454-1.277-.813a1.902 1.902 0 01-.4-1.158c0-.335.073-.63.216-.886.144-.255.335-.479.575-.654.24-.184.51-.32.83-.415.32-.096.655-.136 1.006-.136.175 0 .36.008.535.032.183.024.35.056.518.088.16.04.312.08.455.127.144.048.256.096.336.144a.69.69 0 01.24.2.43.43 0 01.071.263v.375c0 .168-.064.256-.184.256a.83.83 0 01-.303-.096 3.652 3.652 0 00-1.532-.311c-.455 0-.815.071-1.062.223-.248.152-.375.383-.375.71 0 .224.08.416.24.567.16.152.454.304.877.44l1.134.358c.574.184.99.44 1.237.767.247.327.367.702.367 1.117 0 .343-.072.655-.207.926a2.157 2.157 0 01-.583.703c-.248.2-.543.343-.886.447-.36.111-.734.167-1.142.167z"></path><path d="M.378 15.475c3.384 1.963 7.56 3.153 11.877 3.153 2.914 0 6.114-.607 9.06-1.852.44-.2.814.287.383.607-2.626 1.94-6.442 2.969-9.722 2.969-4.598 0-8.74-1.7-11.87-4.526-.247-.223-.024-.527.272-.351zm23.531-.2c.287.36-.08 2.826-1.485 4.007-.215.184-.423.088-.327-.151l.175-.439c.343-.88.802-2.198.52-2.555-.336-.43-2.22-.207-3.074-.103-.255.032-.295-.192-.063-.36 1.5-1.053 3.967-.75 4.254-.399z"></path>`,baai:`<path clip-rule="evenodd" d="M0 4.68L8.61 0l3.583 2.004 3.1-1.735L24 5.14v8.701l-3.582 2.004v3.469L12.038 24l-8.482-4.52v-3.847L0 13.9V4.68zm1.284 1.472v2.934l7.936 4.098-.032 1.419-7.904-4.08v2.658l10.043 5.303V11.77L1.284 6.152zm10.741 4.532l9.791-5.33-2.63-1.47-7.398 4.137-1.251-.736 7.366-4.12-2.61-1.46-9.806 5.34 6.538 3.64zM4.2 6.328l6.709-3.606L8.61 1.436l-6.714 3.61L4.2 6.327zm11.04 14.444l-2.618 1.465V11.94l6.512-3.642v10.298l-2.61 1.46v-8.241l-1.283.682v8.277zm-10.4-4.42l6.487 3.568v2.23L4.84 18.763v-2.41zm17.876-3.23v-6.83L20.418 7.58v6.829l2.298-1.286z"></path>`,baidu:`<path d="M8.859 11.735c1.017-1.71 4.059-3.083 6.202.286 1.579 2.284 4.284 4.397 4.284 4.397s2.027 1.601.73 4.684c-1.24 2.956-5.64 1.607-6.005 1.49l-.024-.009s-1.746-.568-3.776-.112c-2.026.458-3.773.286-3.773.286l-.045-.001c-.328-.01-2.38-.187-3.001-2.968-.675-3.028 2.365-4.687 2.592-4.968.226-.288 1.802-1.37 2.816-3.085zm.986 1.738v2.032h-1.64s-1.64.138-2.213 2.014c-.2 1.252.177 1.99.242 2.148.067.157.596 1.073 1.927 1.342h3.078v-7.514l-1.394-.022zm3.588 2.191l-1.44.024v3.956s.064.985 1.44 1.344h3.541v-5.3h-1.528v3.979h-1.46s-.466-.068-.553-.447v-3.556zM9.82 16.715v3.06H8.58s-.863-.045-1.126-1.049c-.136-.445.02-.959.088-1.16.063-.203.353-.671.951-.85H9.82zm9.525-9.036c2.086 0 2.646 2.06 2.646 2.742 0 .688.284 3.597-2.309 3.655-2.595.057-2.704-1.77-2.704-3.08 0-1.374.277-3.317 2.367-3.317zM4.24 6.08c1.523-.135 2.645 1.55 2.762 2.513.07.625.393 3.486-1.975 4-2.364.515-3.244-2.249-2.984-3.544 0 0 .28-2.797 2.197-2.969zm8.847-1.483c.14-1.31 1.69-3.316 2.931-3.028 1.236.285 2.367 1.944 2.137 3.37-.224 1.428-1.345 3.313-3.095 3.082-1.748-.226-2.143-1.823-1.973-3.424zM9.425 1c1.307 0 2.364 1.519 2.364 3.398 0 1.879-1.057 3.4-2.364 3.4s-2.367-1.521-2.367-3.4C7.058 2.518 8.118 1 9.425 1z"></path>`,bytedance:`<path d="M14.944 18.587l-1.704-.445V10.01l1.824-.462c1-.254 1.84-.461 1.88-.453.032 0 .056 2.235.056 4.972v4.973l-.176-.008c-.104 0-.952-.207-1.88-.446z"></path><path d="M7 16.542c0-2.736.024-4.98.064-4.98.032-.008.872.2 1.88.454l1.816.461-.016 4.05-.024 4.049-1.632.422c-.896.23-1.736.445-1.856.469L7 21.523v-4.98z"></path><path d="M19.24 12.477c0-9.03.008-9.515.144-9.475.072.024.784.207 1.576.406.792.207 1.576.405 1.744.445l.296.08-.016 8.56-.024 8.568-1.624.414c-.888.23-1.728.437-1.856.47l-.24.055v-9.523z"></path><path d="M1 12.509c0-4.678.024-8.505.064-8.505.032 0 .872.207 1.872.454l1.824.461v7.582c0 4.16-.016 7.574-.032 7.574-.024 0-.872.215-1.88.47L1 21.013v-8.505z"></path>`,claude:`<path d="M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z"></path>`,claudecode:`<path clip-rule="evenodd" d="M20.998 10.949H24v3.102h-3v3.028h-1.487V20H18v-2.921h-1.487V20H15v-2.921H9V20H7.488v-2.921H6V20H4.487v-2.921H3V14.05H0V10.95h3V5h17.998v5.949zM6 10.949h1.488V8.102H6v2.847zm10.51 0H18V8.102h-1.49v2.847z"></path>`,codex:`<path clip-rule="evenodd" d="M8.086.457a6.105 6.105 0 013.046-.415c1.333.153 2.521.72 3.564 1.7a.117.117 0 00.107.029c1.408-.346 2.762-.224 4.061.366l.063.03.154.076c1.357.703 2.33 1.77 2.918 3.198.278.679.418 1.388.421 2.126a5.655 5.655 0 01-.18 1.631.167.167 0 00.04.155 5.982 5.982 0 011.578 2.891c.385 1.901-.01 3.615-1.183 5.14l-.182.22a6.063 6.063 0 01-2.934 1.851.162.162 0 00-.108.102c-.255.736-.511 1.364-.987 1.992-1.199 1.582-2.962 2.462-4.948 2.451-1.583-.008-2.986-.587-4.21-1.736a.145.145 0 00-.14-.032c-.518.167-1.04.191-1.604.185a5.924 5.924 0 01-2.595-.622 6.058 6.058 0 01-2.146-1.781c-.203-.269-.404-.522-.551-.821a7.74 7.74 0 01-.495-1.283 6.11 6.11 0 01-.017-3.064.166.166 0 00.008-.074.115.115 0 00-.037-.064 5.958 5.958 0 01-1.38-2.202 5.196 5.196 0 01-.333-1.589 6.915 6.915 0 01.188-2.132c.45-1.484 1.309-2.648 2.577-3.493.282-.188.55-.334.802-.438.286-.12.573-.22.861-.304a.129.129 0 00.087-.087A6.016 6.016 0 015.635 2.31C6.315 1.464 7.132.846 8.086.457zm-.804 7.85a.848.848 0 00-1.473.842l1.694 2.965-1.688 2.848a.849.849 0 001.46.864l1.94-3.272a.849.849 0 00.007-.854l-1.94-3.393zm5.446 6.24a.849.849 0 000 1.695h4.848a.849.849 0 000-1.696h-4.848z"></path>`,cohere:`<path clip-rule="evenodd" d="M8.128 14.099c.592 0 1.77-.033 3.398-.703 1.897-.781 5.672-2.2 8.395-3.656 1.905-1.018 2.74-2.366 2.74-4.18A4.56 4.56 0 0018.1 1H7.549A6.55 6.55 0 001 7.55c0 3.617 2.745 6.549 7.128 6.549z"></path><path clip-rule="evenodd" d="M9.912 18.61a4.387 4.387 0 012.705-4.052l3.323-1.38c3.361-1.394 7.06 1.076 7.06 4.715a5.104 5.104 0 01-5.105 5.104l-3.597-.001a4.386 4.386 0 01-4.386-4.387z"></path><path d="M4.776 14.962A3.775 3.775 0 001 18.738v.489a3.776 3.776 0 007.551 0v-.49a3.775 3.775 0 00-3.775-3.775z"></path>`,cursor:`<path d="M22.106 5.68L12.5.135a.998.998 0 00-.998 0L1.893 5.68a.84.84 0 00-.419.726v11.186c0 .3.16.577.42.727l9.607 5.547a.999.999 0 00.998 0l9.608-5.547a.84.84 0 00.42-.727V6.407a.84.84 0 00-.42-.726zm-.603 1.176L12.228 22.92c-.063.108-.228.064-.228-.061V12.34a.59.59 0 00-.295-.51l-9.11-5.26c-.107-.062-.063-.228.062-.228h18.55c.264 0 .428.286.296.514z"></path>`,deepcogito:`<path d="M19.74 21.618l4.213-10.534a.412.412 0 00.027-.1l.003-.03a.404.404 0 00-.02-.167l-.007-.026a.44.44 0 00-.045-.085l-.003-.005L16.528.13c-.002-.003 0-.006-.003-.01h.004v.173h-.01c-.102-.254-.277-.285-.445-.248l-.001-.003c-.001.001-.003-.003-.003-.003h-.006s0-.038-.002-.038L4.466 3.143c-.006.002-.012-.005-.018-.003-.022.007-.044.01-.064.021a.42.42 0 00-.039.022c-.013.008-.026.015-.037.025a.464.464 0 00-.118.154l-.01.017L0 13.919c-.004.013.023.026.023.04v.148c0 .019 0 .038.003.057l-.003.001v.006c0 .049-.011.096.016.139H.03c0 .002-.008.002-.008.002l-.01.001c.007.012.008.023.016.034l7.377 9.486v.005a.063.063 0 00.006.005c.006.008.013.013.02.02a.258.258 0 00.02.02c.008.008.015.017.023.023l.02.014a.564.564 0 00.104.053c.011.003.021.008.032.01.005.002.01.005.016.006a.445.445 0 00.172.004l11.597-2.108a.362.362 0 00.041-.01l.011.001h.001c.005 0 .01-.007.015-.009.01-.003.02-.008.03-.013a.248.248 0 00.025-.012l.01-.007a.448.448 0 00.096-.072c.004-.004.006-.01.01-.013a.419.419 0 00.069-.1l.005-.008.003-.006.001-.003.006-.015zm-.77-.894l-7.315-4.573 8.229-6.4-.915 10.973zm-7.82-5.27l-2.782-10.2 11.127 3.71-8.345 6.49zm9.611-5.883l2.267 1.512-3.022 7.554.755-9.066zm1.133-.278l-1.168-.778-1.556-3.113 2.724 3.891zm-2.35-1.22L8.862 4.514l7.122-3.56 3.56 7.12zM7.71 4.129L6.063 3.58 12.1 1.932 7.71 4.128zm-2.881-.053l2.201.734-5.137 6.605 2.936-7.34zm2.725 1.46l2.754 10.096-9.179-1.835 6.425-8.26zM10.3 16.508L7.633 22.73l-6.223-8 8.89 1.777zm.803.313l7.065 4.417-9.716 1.767 2.65-6.184z"></path>`,deepseek:`<path d="M23.748 4.482c-.254-.124-.364.113-.512.234-.051.039-.094.09-.137.136-.372.397-.806.657-1.373.626-.829-.046-1.537.214-2.163.848-.133-.782-.575-1.248-1.247-1.548-.352-.156-.708-.311-.955-.65-.172-.241-.219-.51-.305-.774-.055-.16-.11-.323-.293-.35-.2-.031-.278.136-.356.276-.313.572-.434 1.202-.422 1.84.027 1.436.633 2.58 1.838 3.393.137.093.172.187.129.323-.082.28-.18.552-.266.833-.055.179-.137.217-.329.14a5.526 5.526 0 01-1.736-1.18c-.857-.828-1.631-1.742-2.597-2.458a11.365 11.365 0 00-.689-.471c-.985-.957.13-1.743.388-1.836.27-.098.093-.432-.779-.428-.872.004-1.67.295-2.687.684a3.055 3.055 0 01-.465.137 9.597 9.597 0 00-2.883-.102c-1.885.21-3.39 1.102-4.497 2.623C.082 8.606-.231 10.684.152 12.85c.403 2.284 1.569 4.175 3.36 5.653 1.858 1.533 3.997 2.284 6.438 2.14 1.482-.085 3.133-.284 4.994-1.86.47.234.962.327 1.78.397.63.059 1.236-.03 1.705-.128.735-.156.684-.837.419-.961-2.155-1.004-1.682-.595-2.113-.926 1.096-1.296 2.746-2.642 3.392-7.003.05-.347.007-.565 0-.845-.004-.17.035-.237.23-.256a4.173 4.173 0 001.545-.475c1.396-.763 1.96-2.015 2.093-3.517.02-.23-.004-.467-.247-.588zM11.581 18c-2.089-1.642-3.102-2.183-3.52-2.16-.392.024-.321.471-.235.763.09.288.207.486.371.739.114.167.192.416-.113.603-.673.416-1.842-.14-1.897-.167-1.361-.802-2.5-1.86-3.301-3.307-.774-1.393-1.224-2.887-1.298-4.482-.02-.386.093-.522.477-.592a4.696 4.696 0 011.529-.039c2.132.312 3.946 1.265 5.468 2.774.868.86 1.525 1.887 2.202 2.891.72 1.066 1.494 2.082 2.48 2.914.348.292.625.514.891.677-.802.09-2.14.11-3.054-.614zm1-6.44a.306.306 0 01.415-.287.302.302 0 01.2.288.306.306 0 01-.31.307.303.303 0 01-.304-.308zm3.11 1.596c-.2.081-.399.151-.59.16a1.245 1.245 0 01-.798-.254c-.274-.23-.47-.358-.552-.758a1.73 1.73 0 01.016-.588c.07-.327-.008-.537-.239-.727-.187-.156-.426-.199-.688-.199a.559.559 0 01-.254-.078c-.11-.054-.2-.19-.114-.358.028-.054.16-.186.192-.21.356-.202.767-.136 1.146.016.352.144.618.408 1.001.782.391.451.462.576.685.914.176.265.336.537.445.848.067.195-.019.354-.25.452z"></path>`,gemma:`<path d="M12.34 5.953a8.233 8.233 0 01-.247-1.125V3.72a8.25 8.25 0 015.562 2.232H12.34zm-.69 0c.113-.373.199-.755.257-1.145V3.72a8.25 8.25 0 00-5.562 2.232h5.304zm-5.433.187h5.373a7.98 7.98 0 01-.267.696 8.41 8.41 0 01-1.76 2.65L6.216 6.14zm-.264-.187H2.977v.187h2.915a8.436 8.436 0 00-2.357 5.767H0v.186h3.535a8.436 8.436 0 002.357 5.767H2.977v.186h2.976v2.977h.187v-2.915a8.436 8.436 0 005.767 2.357V24h.186v-3.535a8.436 8.436 0 005.767-2.357v2.915h.186v-2.977h2.977v-.186h-2.915a8.436 8.436 0 002.357-5.767H24v-.186h-3.535a8.436 8.436 0 00-2.357-5.767h2.915v-.187h-2.977V2.977h-.186v2.915a8.436 8.436 0 00-5.767-2.357V0h-.186v3.535A8.436 8.436 0 006.14 5.892V2.977h-.187v2.976zm6.14 14.326a8.25 8.25 0 005.562-2.233H12.34c-.108.367-.19.743-.247 1.126v1.107zm-.186-1.087a8.015 8.015 0 00-.258-1.146H6.345a8.25 8.25 0 005.562 2.233v-1.087zm-8.186-7.285h1.107a8.23 8.23 0 001.125-.247V6.345a8.25 8.25 0 00-2.232 5.562zm1.087.186H3.72a8.25 8.25 0 002.232 5.562v-5.304a8.012 8.012 0 00-1.145-.258zm15.47-.186a8.25 8.25 0 00-2.232-5.562v5.315c.367.108.743.19 1.126.247h1.107zm-1.086.186c-.39.058-.772.144-1.146.258v5.304a8.25 8.25 0 002.233-5.562h-1.087zm-1.332 5.69V12.41a7.97 7.97 0 00-.696.267 8.409 8.409 0 00-2.65 1.76l3.346 3.346zm0-6.18v-5.45l-.012-.013h-5.451c.076.235.162.468.26.696a8.698 8.698 0 001.819 2.688 8.698 8.698 0 002.688 1.82c.228.097.46.183.696.259zM6.14 17.848V12.41c.235.078.468.167.696.267a8.403 8.403 0 012.688 1.799 8.404 8.404 0 011.799 2.688c.1.228.19.46.267.696H6.152l-.012-.012zm0-6.245V6.326l3.29 3.29a8.716 8.716 0 01-2.594 1.728 8.14 8.14 0 01-.696.259zm6.257 6.257h5.277l-3.29-3.29a8.716 8.716 0 00-1.728 2.594 8.135 8.135 0 00-.259.696zm-2.347-7.81a9.435 9.435 0 01-2.88 1.96 9.14 9.14 0 012.88 1.94 9.14 9.14 0 011.94 2.88 9.435 9.435 0 011.96-2.88 9.14 9.14 0 012.88-1.94 9.435 9.435 0 01-2.88-1.96 9.434 9.434 0 01-1.96-2.88 9.14 9.14 0 01-1.94 2.88z"></path>`,google:`<path d="M23 12.245c0-.905-.075-1.565-.236-2.25h-10.54v4.083h6.186c-.124 1.014-.797 2.542-2.294 3.569l-.021.136 3.332 2.53.23.022C21.779 18.417 23 15.593 23 12.245z"></path><path d="M12.225 23c3.03 0 5.574-.978 7.433-2.665l-3.542-2.688c-.948.648-2.22 1.1-3.891 1.1a6.745 6.745 0 01-6.386-4.572l-.132.011-3.465 2.628-.045.124C4.043 20.531 7.835 23 12.225 23z"></path><path d="M5.84 14.175A6.65 6.65 0 015.463 12c0-.758.138-1.491.361-2.175l-.006-.147-3.508-2.67-.115.054A10.831 10.831 0 001 12c0 1.772.436 3.447 1.197 4.938l3.642-2.763z"></path><path d="M12.225 5.253c2.108 0 3.529.892 4.34 1.638l3.167-3.031C17.787 2.088 15.255 1 12.225 1 7.834 1 4.043 3.469 2.197 7.062l3.63 2.763a6.77 6.77 0 016.398-4.572z"></path>`,hermesagent:`<path d="M5.938 12.835c.127-.039.285.02.373.143.028.038.036.092.046.14.003.014-.02.033-.04.05-.124-.098-.24-.194-.354-.291-.011-.01-.016-.027-.025-.042zM8.396 9.412c.195-.032.39-.06.588-.05a.54.54 0 01.148.026c.202.071.402.147.601.224.028.01.05.036.075.055l-.013.027a9.203 9.203 0 01-.26-.089c-.115-.038-.213-.077-.315-.098-.25-.05-.25-.046-.292-.014l.574.144c.275.139.55.276.823.417.042.022.09.057.107.098.026.06.063.076.117.072.066-.006.132-.017.213-.027l-.04.086c.051.08.142.02.216.064-.074.13-.247.09-.334.199l.061.074-.12.087c0 .106-.038.168-.306.243l.026.085-.196.042.07.124h-.25l-.007.137c-.081-.01-.161-.018-.244-.027l-.053.123c-.027-.008-.052-.011-.073-.023-.067-.038-.128-.056-.195.006-.019.017-.063.014-.093.008-.026-.006-.05-.029-.07-.042-.11.095-.11.095-.208.003-.057.046-.12.074-.186.011-.063.027-.123-.02-.178-.014-.07.007-.097-.035-.133-.07l-.13.033c-.013-.236-.194-.19-.34-.203.005-.072.05-.092.095-.094a.474.474 0 01.159.022c.164.05.32.12.496.138.203.021.405.029.601-.015.265-.059.52-.149.707-.365.049-.056.083-.127.117-.195.019-.038.02-.084-.02-.116a1.397 1.397 0 00-.382-.217c.024.12-.031.182-.115.221 0 .014-.004.025 0 .03.08.115.084.16-.007.267a1.39 1.39 0 01-.218.211.477.477 0 01-.641-.05 1.36 1.36 0 01-.133-.152c-.078-.107-.076-.108-.033-.236-.165-.08-.128-.226-.104-.364.008-.05.028-.096.049-.163-.04.014-.067.017-.087.032a.897.897 0 00-.316.357c-.007.016-.01.034-.02.047-.012.015-.034.038-.045.035-.02-.006-.037-.027-.05-.045-.008-.012-.007-.032-.012-.057h-.126l.053-.172a14.82 14.82 0 00-.039-.049l.11-.284c-.06.026-.091.044-.124.051-.03.007-.064 0-.095 0 0-.031-.01-.07.004-.092.149-.22.305-.428.593-.476z"></path><path d="M8.06 10.788c-.003-.038-.004-.075.037-.062.016.006.034.048.028.067-.01.04-.038.032-.064-.005z"></path><path clip-rule="evenodd" d="M11.981.009c.226-.012.453-.011.679 0 .247.01.495.024.74.062.401.064.798.157 1.19.273.463.138.92.299 1.356.511a7.31 7.31 0 012.948 2.642c.292.469.536.963.739 1.479.219.556.446 1.11.623 1.683.204.654.329 1.326.458 1.997.097.504.182 1.01.29 1.511.156.722.329 1.44.494 2.16.186.812.4 1.615.63 2.415.102.355.193.713.282 1.072.11.436.202.876.254 1.323.031.278.066.557.073.837a7.56 7.56 0 01-.017.88c-.037.413-.1.818-.226 1.212a5.017 5.017 0 01-.915 1.649l-.13.156.018.023c.043-.023.088-.041.127-.068.2-.138.373-.307.531-.49.4-.46.721-.973.975-1.529a3.59 3.59 0 00.325-1.72c-.024-.424-.097-.834-.3-1.213-.013-.027-.015-.06-.03-.121.05.035.082.048.101.072.107.13.22.258.315.398.33.494.46 1.052.486 1.64a3.75 3.75 0 01-.47 1.97c-.36.655-.887 1.14-1.526 1.506-.193.111-.394.21-.595.308-.157.078-.248.211-.318.365a.522.522 0 00-.033.406.359.359 0 01.013.139c-.005.077-.077.155-.14.162-.054.006-.125-.043-.15-.116a1.206 1.206 0 01-.06-.233c-.04-.314-.155-.6-.308-.87a3.906 3.906 0 00-.73-.91 2.129 2.129 0 00-.897-.524 4.093 4.093 0 00-.692-.131c-.075-.008-.15-.04-.22.01.18.06.363.11.538.18.434.173.82.43 1.18.728.308.255.58.543.794.884.098.155.186.315.227.496.027.123.042.25.067.375.013.062-.002.109-.053.144-.047.033-.122.034-.163-.01a.455.455 0 01-.08-.14c-.03-.073-.038-.159-.078-.225a7.314 7.314 0 00-1.423-1.664c-.16-.137-.329-.26-.537-.323-.376-.114-.753-.203-1.15-.154-.213.025-.427.032-.64.053a1.6 1.6 0 00-.736.278 5.14 5.14 0 00-.834.72c-.329.342-.642.699-.955 1.055-.136.155-.264.319-.314.531a5.227 5.227 0 00-.012.051.096.096 0 01-.09.076h-.31c-.046 0-.082-.048-.072-.094.023-.108.045-.216.07-.324.075-.325.19-.635.368-.917.024-.039.04-.088.104-.08l.01.049.027.077c.28-.435.571-.834.996-1.135.283-.204.584-.378.89-.55a.196.196 0 00-.098-.002c-.162.043-.325.084-.485.134-.402.124-.764.33-1.11.566-.147.1-.298.193-.414.333a7.314 7.314 0 00-1.07 1.767.845.845 0 00-.04.12.075.075 0 01-.072.056h-.494c-.04 0-.062-.051-.036-.082.123-.14.246-.282.377-.415.275-.281.58-.532.777-.884.027-.048.063-.09.095-.135.238-.333.54-.607.818-.902.082-.086.175-.16.26-.24.029-.027.053-.057.079-.085l-.018-.025-.135.041c-.034.017-.07.031-.102.05-.248.144-.494.292-.743.433-.408.23-.825.439-1.209.711-.281.2-.591.358-.889.533-.02.012-.044.015-.08.028-.015-.135.143-.201.108-.336-.033.014-.064.02-.085.038-.111.096-.227.19-.328.296-.148.157-.284.325-.425.488-.125.143-.25.286-.373.431A.153.153 0 019.89 24H8.762a.316.316 0 00.016-.042c.028-.09.085-.172.083-.28-.091-.018-.162.001-.212.077a4.45 4.45 0 00-.136.215c-.01.016-.024.03-.042.03h-.093c-.019 0-.029-.022-.017-.037.071-.088.14-.178.209-.268.001-.002-.006-.012-.012-.024-.014.004-.03.006-.045.013-.176.09-.352.181-.527.274a.363.363 0 01-.168.042H5.202c-.026 0-.039-.036-.019-.053.21-.178.402-.374.558-.605.335-.496.538-1.047.667-1.629.004-.02-.003-.043-.006-.091-.037.048-.059.072-.076.1a1.943 1.943 0 01-.334.415c-.28.258-.59.448-.983.464-.297.012-.588 0-.865-.127-.46-.21-.722-.57-.794-1.072-.025-.17-.017-.171-.182-.219A3.513 3.513 0 011.97 20.6a2.286 2.286 0 01-.808-1.13 3.569 3.569 0 01-.16-1.245c.002-.034.016-.067.024-.1.032.023.046.043.05.066.033.153.059.308.096.46.086.355.257.664.516.92.258.256.571.419.91.532.358.118.717.138 1.07-.016a1.89 1.89 0 00.621-.452c.328-.348.533-.76.648-1.223.009-.034.005-.071.007-.11-.015.006-.026.006-.03.011-.031.05-.064.1-.093.152-.284.502-.679.887-1.196 1.135-.351.17-.718.255-1.11.159a1.607 1.607 0 01-.971-.64 2.006 2.006 0 01-.368-.924 2.903 2.903 0 01.02-.886c.05-.439.466-1.17.742-1.271-.02.063-.035.112-.053.16-.043.116-.097.227-.13.345a1.901 1.901 0 00-.05.82c.033.212.09.416.204.6.147.236.346.407.62.465.11.023.225.014.338.018a.576.576 0 00.386-.131c.164-.128.282-.292.366-.481.168-.375.24-.777.309-1.179.05-.296.093-.594.133-.893.039-.281.071-.563.104-.845.026-.232.048-.464.074-.696.024-.228.052-.455.076-.683.024-.227.047-.455.069-.683.013-.14.022-.28.034-.42l.037-.417c.022-.25.041-.5.065-.748.008-.082-.02-.132-.09-.177a2.46 2.46 0 01-.492-.418c-.1-.109-.188-.228-.282-.342-.035-.042-.056-.097-.116-.118a2.084 2.084 0 00.275.597c.06.092.131.176.196.265.063.086.182.115.234.226-.028.003-.046.01-.06.006a4.74 4.74 0 01-.22-.057 2.71 2.71 0 01-1.287-.819c-.435-.487-.656-1.076-.71-1.723a5.206 5.206 0 01.014-1.06c.072-.602.22-1.186.45-1.745.155-.376.338-.741.526-1.102.205-.393.466-.75.765-1.076.512-.559 1.104-1.024 1.726-1.448.717-.49 1.478-.898 2.277-1.233C8.244.828 8.767.632 9.31.494c.655-.166 1.31-.33 1.982-.415.229-.03.458-.058.688-.07zm-1.847 22.82c-.07.06-.147.111-.207.18-.238.27-.464.549-.668.869l-.044.108a.177.177 0 00.093-.057c.174-.19.351-.378.519-.574.104-.122.195-.255.288-.386.024-.034.03-.08.046-.12l-.027-.02zm1.65-3.695a5.51 5.51 0 00-.653.593l-.37.386a.963.963 0 01-.377.25 1.372 1.372 0 01-.467.09c-.044 0-.087.006-.151.012.028.058.043.097.064.131.15.242.301.482.45.724.136.22.276.438.399.666.068.125.105.267.156.404.077.027.14-.018.202-.048.29-.135.579-.274.867-.412.213-.101.437-.186.636-.31.347-.215.68-.455 1.018-.685.015-.01.026-.028.042-.046-.023-.019-.038-.037-.056-.044-.287-.111-.527-.3-.77-.482a5.319 5.319 0 01-.506-.42 1.757 1.757 0 01-.41-.653c-.019-.049-.045-.095-.075-.156zm-5.847.264c-.06.096-.097.194-.132.293a3.38 3.38 0 01-.555 1.01c-.2.25-.455.412-.762.493-.23.06-.464.076-.7.07-.048-.002-.097.002-.158.005.016.04.021.066.035.085.1.145.23.246.4.295.157.046.316.034.498.023.181-.037.343-.115.485-.234.238-.199.402-.454.536-.732.175-.363.264-.751.342-1.144.01-.053.008-.11.011-.164zm14.945-4.586c.008.029.016.057.027.107.024.155.051.31.072.464.03.219.067.437.078.657.017.344.027.689-.014 1.033-.037.315-.063.633-.116.946a6.153 6.153 0 01-.46 1.518c-.008.018-.01.039-.02.082.047-.03.077-.042.098-.064.085-.083.17-.167.248-.255.271-.305.458-.66.596-1.043.18-.498.228-1.011.145-1.531-.103-.65-.33-1.263-.597-1.881a9.055 9.055 0 00-.024-.055l-.033.022zM5.797 8.29a.26.26 0 00.018.153c.124.251.25.501.379.75.025.049.066.09.03.163-.284.06-.578.119-.88.255.059.038.097.06.132.087.042.032.112.058.09.12-.01.033-.075.048-.117.072.017.01.043.021.067.036.166.102.33.207.447.368.138.192.229.404.188.644-.079.469-.306.85-.69 1.132-.054.04-.106.083-.161.122a.243.243 0 00-.103.245.77.77 0 00.055.195c.083.196.22.35.375.492.083.076.159.164.222.257a.37.37 0 01.025.377c-.023.05-.05.099-.076.148-.03.06-.028.111.022.162.041.042.08.089.112.138.038.058.078.079.147.05a.486.486 0 01.333-.006c.16.046.302.126.444.21.13.077.264.149.4.219.067.035.14.05.219.026.071-.022.124.01.145.076.02.064-.003.108-.074.139-.07.03-.137.063-.209.088-.1.035-.201.073-.314.077-.013-.107.11-.088.127-.159-.206-.126-.643-.145-.801-.034.063.112.035.21-.096.313-.13-.1-.025-.202.002-.3a.209.209 0 00-.249.17c-.015.101.067.216.178.224.108.007.218-.005.326-.012.06-.005.12-.027.199 0-.103.123-.248.127-.357.19.002.05.07.086.019.131-.053.048-.095-.001-.132-.03-.08-.063-.16-.126-.231-.197a.474.474 0 01-.157-.311.52.52 0 00-.043-.172c-.032-.074-.032-.137.033-.19-.018-.03-.028-.053-.045-.072a1.222 1.222 0 01-.196-.369c-.053-.137-.046-.264.048-.381.024-.03.05-.06.064-.095a.664.664 0 00.047-.168c.017-.165-.064-.287-.182-.387-.186-.156-.36-.322-.46-.551-.005-.011-.024-.017-.037-.026-.011.017-.024.027-.025.038-.019.185-.045.37-.052.557-.014.377.058.743.162 1.104.118.41.289.798.488 1.173.267.502.537 1.002.812 1.5.055.098.13.189.208.27.198.202.452.272.724.273.202 0 .404-.006.605-.026.295-.03.59-.073.884-.113.183-.025.365-.057.548-.08.21-.026.38.073.522.21.16.156.305.327.447.5.22.265.397.56.554.867.05.098.07.1.147.03.13-.121.26-.242.394-.36.067-.059.088-.12.067-.213a3.535 3.535 0 01-.085-.796c.002-.157.006-.314.018-.471.015-.224.03-.45.06-.672a59.114 59.114 0 01.362-2.298c.087-.493.182-.984.268-1.477.06-.347.118-.694.162-1.043.034-.273.055-.55.063-.825.011-.332.003-.665.002-.998 0-.077.004-.155-.01-.23-.028-.142-.01-.155-.162-.19a5.826 5.826 0 00-.607-.107c-.146-.018-.207-.053-.221-.19-.006-.049-.025-.098-.041-.146-.009-.025-.024-.048-.046-.09l-.025.264c-.009.096-.029.116-.127.115-.055 0-.11-.008-.164-.008-.476 0-.952-.008-1.426.032-.095.008-.173-.015-.226-.103-.04-.066-.088-.126-.134-.186-.063-.084-.086-.093-.182-.06-.195.068-.388.138-.582.21a2.71 2.71 0 00-.675.394.986.986 0 01-.323.168c-.033.01-.07.008-.127.013.02-.066.024-.114.047-.15.064-.105.135-.205.205-.306.023-.033.049-.063.073-.095l-.015-.023-.201.037c-.146.04-.296.07-.437.122-.148.053-.266.023-.386-.072a3.623 3.623 0 01-.733-.786l-.093-.132zm8.592 8.963l-.147.09c-.22.134-.44.266-.659.402-.093.058-.184.12-.27.188-.085.07-.124.161-.072.272.047.1.093.2.147.294.047.08.124.138.213.147.11.01.228.012.336-.012.217-.05.372-.205.528-.357a.291.291 0 00.087-.308c-.046-.18-.079-.365-.118-.547-.011-.052-.027-.103-.045-.169zm-.257-2.409c-.12.291-.205.597-.325.91-.151.433-.294.87-.435 1.323.036-.01.054-.01.067-.018.261-.16.522-.324.785-.484.054-.033.071-.078.065-.138-.012-.13-.024-.262-.034-.393l-.068-.886c-.008-.103-.02-.206-.029-.31-.009 0-.017-.002-.026-.004zm3.081-8.13l.099.285c.08.231.159.463.24.714l.58 1.952c.187.63.372 1.262.558 1.893.114.382.235.762.343 1.146.072.257.126.519.186.799.044.206.087.413.127.64.034.106.023.226.077.325l.025-.006-.068-.362c-.038-.206-.077-.412-.113-.638-.015-.07-.029-.141-.046-.211-.095-.396-.177-.796-.29-1.187-.196-.685-.413-1.364-.618-2.046-.165-.549-.322-1.1-.488-1.648-.069-.227-.15-.45-.226-.695l-.117-.336c-.037-.107-.075-.216-.115-.322-.04-.106-.084-.21-.127-.314a7.558 7.558 0 01-.027.01zM6.225 14.304c-.063-.001-.115.014-.134.083a.35.35 0 00.41.012 4.533 4.533 0 00-.276-.095zM5.23 11.98c-.026-.027-.057-.048-.075.002-.012.032-.007.07-.01.113.082-.037.082-.037.085-.115zm.062-1.189a.135.135 0 00-.088.056.197.197 0 00-.025.11c.005.152.01.306.026.457a.751.751 0 00.066.218c.061.136.157.167.288.101.055-.027.06-.054.025-.11a4.52 4.52 0 01-.129-.211c-.015-.068-.066-.131-.033-.207.04-.09-.076-.116-.074-.19V10.874c-.003-.038-.006-.087-.056-.083zm-.017-.968a.867.867 0 00-.467.127c-.076.045-.084.07-.05.158.034.087.07.173.115.254.064.117.09.125.21.077a.657.657 0 01.336-.053c.202.022.357.136.504.264l.092.077c.007-.006.014-.013.022-.018-.019-.105-.035-.226-.149-.264-.157-.053-.324-.075-.508-.117l-.24-.005c.24-.169.452-.044.687.009-.063-.115-.153-.147-.23-.193-.082-.05-.17-.092-.25-.144-.06-.037-.12-.08-.072-.172zm10.233.325c-.23-.01-.427.08-.608.211-.034.026-.06.065-.105.117.087.026.15.046.232.065.044-.015.088-.03.13-.046.306-.114.61-.115.904.031.126.063.237.04.366-.005-.02-.031-.03-.054-.045-.071a.986.986 0 00-.448-.273c-.14-.044-.284-.024-.426-.03zM7.99 6.483a.308.308 0 00.002.133c.08.321.156.643.242.962.104.387.27.75.456 1.103.02.037.061.08.098.087a.404.404 0 00.253-.051l-.472-.84c-.23-.448-.405-.92-.579-1.394zM10.397.497c-.2-.008-.405.004-.603.034-.236.035-.47.087-.7.152-.287.08-.569.18-.852.273-.04.013-.074.038-.11.058.028.014.05.018.07.014.287-.068.58-.085.873-.09.134-.002.269.009.402.025.19.024.382.048.57.09.456.104.874.3 1.265.556.464.306.888.66 1.257 1.078.205.232.395.475.56.739.17.274.315.561.449.856.273.601.456 1.232.6 1.876.04.173.07.348.1.524.017.104.065.167.17.19.122.028.2.105.22.251-.003.102-.06.174-.129.24a1.065 1.065 0 00-.268.358.164.164 0 00.083-.039c.08-.086.162-.172.235-.265a.56.56 0 00.13-.333c.009-.05.022-.1.024-.15.007-.124-.017-.15-.143-.168-.025-.004-.049-.014-.073-.015-.082-.007-.125-.063-.137-.131-.033-.198-.004-.355.247-.408.086-.018.174-.03.26-.042.158-.023.315-.053.473-.067.14-.012.19.033.226.167.008.029.018.057.021.087.019.179-.008.225-.141.288-.027.013-.055.024-.078.042a.148.148 0 00-.051.067c-.039.144.073.382.206.445l.673.32c.023.011.05.015.075.023l.018-.026c-.015-.008-.032-.013-.044-.024a2.27 2.27 0 00-.544-.32 4.898 4.898 0 00-.173-.075.203.203 0 01-.126-.191c-.003-.085.045-.154.128-.187l.059-.025c.099-.044.118-.076.112-.187a.384.384 0 00-.008-.063c-.067-.294-.123-.59-.205-.88a9.478 9.478 0 00-.826-2.036 7.465 7.465 0 00-1.39-1.805 4.536 4.536 0 00-1.177-.824 3.656 3.656 0 00-1.016-.328 6.155 6.155 0 00-.712-.074zm6.719 5.955c.01.014.018.028.038.034l-.022-.044-.016.01zM4.103 3.917a.062.062 0 01-.03.012.455.455 0 01-.04.039c-.01.01-.02.02-.045.04l-.363.354c-.088.085-.17.178-.266.253-.284.22-.425.53-.544.855a.132.132 0 00-.007.071c.013.055.033.108.052.168l.074.026c-.017.056-.03.105-.047.152-.058.164-.118.327-.175.491-.005.015.008.036.019.077.08-.175.158-.33.225-.489.228-.544.484-1.074.819-1.561.09-.133.182-.266.283-.401.004-.006.007-.013.022-.03.001-.016.003-.032.015-.04l.008-.017zm12.976 2.408a.023.023 0 01.009.019.073.073 0 00-.006.01.188.188 0 00.007.02l.018.022c.002-.007.007-.016.005-.021-.003-.01-.012-.018-.02-.038a1.331 1.331 0 01-.013-.012zM4.199 4.48c-.003.004-.008.008-.027.014-.005.013-.011.025-.031.047a2.085 2.085 0 01-.124.167c-.048.07-.116.055-.181.041-.134-.028-.228.016-.287.143-.089.187-.187.37-.273.56-.049.108-.11.216-.118.36.081.003.154.007.228.008h.228a2.563 2.563 0 01-.079.264c-.01.052-.022.103-.033.155l.02.004c.018-.046.037-.092.067-.153.066-.142.13-.285.2-.426.02-.04.034-.1.116-.092 0 .043.004.084 0 .124-.005.045-.017.09-.028.143.141.043.086.174.115.269.102-.022.104-.195.248-.144v.205l.017.002.439-1.059c-.13 0-.246-.02-.358.033-.024.011-.058-.001-.108-.004.075-.15.139-.278.211-.417a.128.128 0 01.025-.036c0-.015-.001-.03.008-.038l.006-.02c-.005.006-.01.011-.028.017-.004.012-.009.024-.026.045a.085.085 0 01-.032.033c-.123.157-.09.164-.258.106-.079-.027-.078-.028-.047-.144.028-.046.056-.093.098-.15 0-.016-.001-.032.007-.042L4.2 4.48zm2.073-.67c-.003.006-.007.011-.027.016-.094.125-.194.246-.28.377-.155.238-.301.481-.451.723-.14.224-.345.368-.575.481-.017.008-.04.006-.079.011.012-.059.016-.109.033-.153a6.076 6.076 0 01.229-.518l-.007-.02a.138.138 0 01-.035.025c-.028.05-.055.1-.093.164-.26.424-.443.817-.442.95.024.004.048.011.073.013.177.013.188.007.26-.165.03-.07.077-.12.147-.15l.175-.07c.044-.018.085-.057.146-.032.003.05-.01.11.014.145.042.062.044.125.047.193.002.049.017.098.026.147.029-.034.039-.065.05-.097.142-.39.277-.782.428-1.17.1-.256.22-.504.33-.756.013-.03.013-.067.03-.092V3.81zm3.987-.34c0 .045.01.084.021.123.042.16.094.318.124.48.024.133.023.27.028.406 0 .033-.019.067-.032.11-.094-.058-.047-.158-.106-.215h-.125c-.015.072-.01.152-.046.2-.066.085-.155.154-.236.227-.043.038-.078.018-.103-.025l-.046-.087c-.065.035-.117.069-.172.093-.116.051-.235.095-.35.147-.085.038-.09.053-.07.147.014.075.034.148.047.223.013.072.05.109.123.124.233.05.462.115.657.265.058-.102.058-.102.168-.151.03-.014.06-.03.092-.042.08-.03.115-.017.15.06.023.048.041.098.066.158.06-.14-.042-.267.017-.416.157.18.24.39.375.567a.235.235 0 00.022-.098c.002-.124 0-.247.002-.371 0-.034.013-.067.02-.1l.032-.003c.11.155.13.354.226.52a3.036 3.036 0 00-.01-.392c-.004-.045 0-.074.05-.088.08.036.116.14.215.158-.03-.275-.423-1.137-.798-1.635-.114-.127-.2-.28-.34-.386zm-2.667.696c-.019.034-.03.05-.037.067-.061.185-.125.37-.18.556-.031.105-.087.169-.195.19-.09.019-.178.052-.268.073-.038.009-.089.015-.118-.003-.024-.016-.025-.069-.036-.106-.064.076-.082.087-.17.047-.133-.062-.262-.135-.393-.201-.048-.025-.093-.063-.17-.03-.043.12-.091.25-.137.382-.099.28-.087.242.095.453.046.048.102.03.154.023.054-.009.106-.03.16-.036.13-.013.26-.08.367-.015.204-.064.387-.122.571-.178.05-.015.089.005.114.054.022.042.034.093.082.121.038-.056-.013-.128.063-.178l.14.241-.042-1.46zm.278.358c-.096-.01-.107.01-.11.108-.002.038-.003.078.002.115.03.2.099.386.174.57.002.006.012.01.022.015l.078-.05c.052.036.081.088.153.088.205-.002.41.014.616.012.099-.001.158.042.205.12.018.03.024.077.088.066l-.08-.394c-.05-.195-.085-.395-.172-.589-.057.057-.114.068-.18.046a.72.72 0 00-.135-.028c-.22-.028-.44-.059-.66-.08zm10.254-1.727c.089.163.155.316.139.491-.016.168.026.342-.044.516-.047-.033-.088-.082-.112-.075-.117.035-.164-.057-.227-.115a4.772 4.772 0 01-.286-.29l-.104-.113a4.856 4.856 0 01-.023.019c.035.046.07.093.11.156.04.064.084.127.122.193.034.058.065.118.031.205-.082-.01-.164-.019-.246-.032-.06-.01-.101 0-.124.07-.031.098-.037.096-.15.09.02.042.036.08.057.116.041.074.03.138-.03.196-.06.06-.118.122-.178.181a.175.175 0 01-.185.046c-.222-.061-.447-.113-.67-.174-.032-.009-.063-.04-.086-.068-.03-.04-.052-.087-.08-.13-.044-.07-.09-.138-.136-.207a.18.18 0 00-.014.105c.012.127.03.253.035.38.005.1-.024.12-.121.104-.104-.017-.206-.04-.31-.058-.064-.012-.131-.028-.202.03l.081.208c.09 0 .166-.01.237.002a.819.819 0 01.458.251c.078.083.154.168.241.26l.018-.005c-.004-.006-.008-.013-.01-.04.014-.056-.062-.118.018-.178.031.03.064.057.088.09.058.078.111.159.169.257l.089.141.024-.013a2093.819 2093.819 0 01-.427-.934c.055.007.083.007.108.016.193.07.385.142.577.216.074.028.147.06.219.094.062.028.112.018.157-.033.05-.056.102-.112.154-.167.05-.051.095-.046.132.014.016.025.026.053.04.08.071.138.143.277.217.433l.159.308.025-.011c-.044-.106-.07-.218-.138-.334-.057-.182-.168-.346-.206-.545.136.034.362.326.567.732l.057.074.018-.011a1.563 1.563 0 01-.052-.127c-.046-.145-.097-.29-.136-.436-.022-.083-.036-.173.022-.26l.109.058-.026-.207.027-.016c.022.02.05.036.065.06.073.108.143.22.215.33.01.016.029.029.043.043-.036-.217-.2-.38-.229-.626l.155.112c.014-.166.012-.319.042-.465.032-.158-.023-.297-.063-.445.024.004.036.006.055.025.092.124.183.249.277.371.02.027.05.047.069.087l.04.063.019-.015a.293.293 0 01-.053-.082 27.922 27.922 0 01-.332-.49c-.221-.311-.363-.467-.485-.521zm-6.57.327c-.003.161.092.275.069.415l-.368.087c.09.139.032.237-.052.331-.05.057-.092.122-.143.178-.037.04-.046.078-.018.126l.16.275c.029.048.072.066.128.064.076-.003.152 0 .228-.001.116-.003.216.022.275.137.006.014.02.024.044.052.004-.059-.003-.098.01-.13.016-.04.04-.099.072-.108.084-.023.173-.024.26-.03.013-.001.027.018.04.029l.071.065c.019-.11-.082-.198-.024-.31l.126.04c-.026-.123-.07-.245-.071-.366 0-.123.051-.243.115-.36.107.062.16.156.234.253.183.265.36.533.494.834.165-.078.27.068.407.088-.003-.106-.133-.441-.197-.492a.142.142 0 00-.102-.028c-.06.011-.119.039-.191.063-.025-.039-.056-.078-.077-.122a3.936 3.936 0 00-.473-.783c-.076-.094-.16-.182-.228-.26l-.391.285c-.049.035-.094.03-.132-.017l-.169-.207c-.025-.03-.053-.059-.097-.108z"></path>`,ibm:`<path clip-rule="evenodd" d="M24 16.333V17h-3.158v-.667H24zm-7.579 0V17h-3.158v-.667h3.158zm2.464 0L18.63 17l-.25-.667h.504zm-7.075 0a2.528 2.528 0 01-1.717.667h-5.04v-.667h6.757zm-7.389 0V17H0v-.667h4.421zm12-1.333v.667h-3.158V15h3.158zm2.958 0l-.246.667h-1L17.885 15h1.494zm-6.937 0c-.057.237-.148.46-.265.667H5.053V15h7.39zm-8.02 0v.667H0V15h4.421zM24 15v.667h-3.158V15H24zm-1.263-1.333v.666h-1.895v-.666h1.895zm-6.316 0v.666h-1.895v-.666h1.895zm3.453 0l-.248.666h-1.989l-.25-.666h2.487zm-7.52 0c.056.212.088.435.088.666h-2.337v-.666h2.249zm-4.143 0v.666H6.316v-.666H8.21zm-5.053 0v.666H1.263v-.666h1.895zm19.579-1.334V13h-1.895v-.667h1.895zm-6.316 0V13h-1.895v-.667h1.895zm3.948 0l-.247.667h-2.987l-.245-.667h3.48zm-8.792 0c.218.188.405.414.55.667H6.315v-.667h5.26zm-8.42 0V13H1.264v-.667h1.895zM18.456 11l.177.539.176-.539h3.929v.667h-1.895v-.613l-.215.613H16.63l-.209-.613v.613h-1.895V11h3.929zM3.158 11v.667H1.263V11h1.895zm8.968 0a2.555 2.555 0 01-.55.667h-5.26V11h5.81zm10.61-1.333v.666h-3.709l.224-.666h3.486zm-4.722 0l.224.666h-3.712v-.666h3.488zm-5.572 0c0 .23-.032.454-.088.666h-2.249v-.666h2.337zm-4.231 0v.666H6.316v-.666H8.21zm-5.053 0v.666H1.263v-.666h1.895zm14.419-1.334l.22.667h-4.534v-.667h4.314zm6.423 0V9h-4.536l.229-.667H24zm-11.823 0c.117.206.208.43.265.667h-7.39v-.667h7.125zm-7.756 0V9H0v-.667h4.421zM17.133 7l.224.667h-4.094V7h3.87zM24 7v.667h-4.089L20.13 7H24zM10.093 7c.662 0 1.264.253 1.717.667H5.053V7h5.04zM4.42 7v.667H0V7h4.421z"></path>`,inception:`<path d="M14.767 1H7.884L1 7.883v6.884h6.884V7.883h6.883V1zM9.234 23h6.882L23 16.116V9.233h-6.884v6.883H9.234V23z"></path>`,kimi:`<path d="M21.846 0a1.923 1.923 0 110 3.846H20.15a.226.226 0 01-.227-.226V1.923C19.923.861 20.784 0 21.846 0z"></path><path d="M11.065 11.199l7.257-7.2c.137-.136.06-.41-.116-.41H14.3a.164.164 0 00-.117.051l-7.82 7.756c-.122.12-.302.013-.302-.179V3.82c0-.127-.083-.23-.185-.23H3.186c-.103 0-.186.103-.186.23V19.77c0 .128.083.23.186.23h2.69c.103 0 .186-.102.186-.23v-3.25c0-.069.025-.135.069-.178l2.424-2.406a.158.158 0 01.205-.023l6.484 4.772a7.677 7.677 0 003.453 1.283c.108.012.2-.095.2-.23v-3.06c0-.117-.07-.212-.164-.227a5.028 5.028 0 01-2.027-.807l-5.613-4.064c-.117-.078-.132-.279-.028-.381z"></path>`,kwaipilot:`<path clip-rule="evenodd" d="M11.765.03C5.327.03.108 5.25.108 11.686c0 3.514 1.556 6.665 4.015 8.804L9.89 8.665h6.451L9.31 23.083c.807.173 1.63.26 2.455.26 6.438 0 11.657-5.22 11.657-11.658S18.202.028 11.765.028V.03z"></path>`,longcat:`<path clip-rule="evenodd" d="M.507 19.883a.507.507 0 01-.489-.642L4.29 3.745a1.013 1.013 0 011.533-.578l5.622 3.687a1.013 1.013 0 001.11 0L18.2 3.165a1.013 1.013 0 011.532.58l4.25 15.497a.506.506 0 01-.49.64H18.07a6.297 6.297 0 001.53-4.115v-.177a6.09 6.09 0 00-1.513-4.017l-.697-3.495a.438.438 0 00-.694-.266L14.07 9.781a.748.748 0 01-.654.121 5.156 5.156 0 00-2.833 0 .746.746 0 01-.653-.121L7.302 7.81a.435.435 0 00-.688.269l-.675 3.652a5.36 5.36 0 00-1.539 3.76v.333c0 1.474.527 2.9 1.488 4.02l.032.038H.507z"></path><path d="M9.213 16.843h1.52v-3.546h-1.29l-.23 3.546zm5.573 0h-1.52v-3.546h1.29l.23 3.546z"></path>`,mcp:`<path d="M15.688 2.343a2.588 2.588 0 00-3.61 0l-9.626 9.44a.863.863 0 01-1.203 0 .823.823 0 010-1.18l9.626-9.44a4.313 4.313 0 016.016 0 4.116 4.116 0 011.204 3.54 4.3 4.3 0 013.609 1.18l.05.05a4.115 4.115 0 010 5.9l-8.706 8.537a.274.274 0 000 .393l1.788 1.754a.823.823 0 010 1.18.863.863 0 01-1.203 0l-1.788-1.753a1.92 1.92 0 010-2.754l8.706-8.538a2.47 2.47 0 000-3.54l-.05-.049a2.588 2.588 0 00-3.607-.003l-7.172 7.034-.002.002-.098.097a.863.863 0 01-1.204 0 .823.823 0 010-1.18l7.273-7.133a2.47 2.47 0 00-.003-3.537z"></path><path d="M14.485 4.703a.823.823 0 000-1.18.863.863 0 00-1.204 0l-7.119 6.982a4.115 4.115 0 000 5.9 4.314 4.314 0 006.016 0l7.12-6.982a.823.823 0 000-1.18.863.863 0 00-1.204 0l-7.119 6.982a2.588 2.588 0 01-3.61 0 2.47 2.47 0 010-3.54l7.12-6.982z"></path>`,meta:`<path d="M6.897 4c1.915 0 3.516.932 5.43 3.376l.282-.373c.19-.246.383-.484.58-.71l.313-.35C14.588 4.788 15.792 4 17.225 4c1.273 0 2.469.557 3.491 1.516l.218.213c1.73 1.765 2.917 4.71 3.053 8.026l.011.392.002.25c0 1.501-.28 2.759-.818 3.7l-.14.23-.108.153c-.301.42-.664.758-1.086 1.009l-.265.142-.087.04a3.493 3.493 0 01-.302.118 4.117 4.117 0 01-1.33.208c-.524 0-.996-.067-1.438-.215-.614-.204-1.163-.56-1.726-1.116l-.227-.235c-.753-.812-1.534-1.976-2.493-3.586l-1.43-2.41-.544-.895-1.766 3.13-.343.592C7.597 19.156 6.227 20 4.356 20c-1.21 0-2.205-.42-2.936-1.182l-.168-.184c-.484-.573-.837-1.311-1.043-2.189l-.067-.32a8.69 8.69 0 01-.136-1.288L0 14.468c.002-.745.06-1.49.174-2.23l.1-.573c.298-1.53.828-2.958 1.536-4.157l.209-.34c1.177-1.83 2.789-3.053 4.615-3.16L6.897 4zm-.033 2.615l-.201.01c-.83.083-1.606.673-2.252 1.577l-.138.199-.01.018c-.67 1.017-1.185 2.378-1.456 3.845l-.004.022a12.591 12.591 0 00-.207 2.254l.002.188c.004.18.017.36.04.54l.043.291c.092.503.257.908.486 1.208l.117.137c.303.323.698.492 1.17.492 1.1 0 1.796-.676 3.696-3.641l2.175-3.4.454-.701-.139-.198C9.11 7.3 8.084 6.616 6.864 6.616zm10.196-.552l-.176.007c-.635.048-1.223.359-1.82.933l-.196.198c-.439.462-.887 1.064-1.367 1.807l.266.398c.18.274.362.56.55.858l.293.475 1.396 2.335.695 1.114c.583.926 1.03 1.6 1.408 2.082l.213.262c.282.326.529.54.777.673l.102.05c.227.1.457.138.718.138.176.002.35-.023.518-.073.338-.104.61-.32.813-.637l.095-.163.077-.162c.194-.459.29-1.06.29-1.785l-.006-.449c-.08-2.871-.938-5.372-2.2-6.798l-.176-.189c-.67-.683-1.444-1.074-2.27-1.074z"></path>`,microsoft:`<path d="M11.49 2H2v9.492h9.492V2h-.002z"></path><path d="M22 2h-9.492v9.492H22V2z"></path><path d="M11.49 12.508H2V22h9.492v-9.492h-.002z"></path><path d="M22 12.508h-9.492V22H22v-9.492z"></path>`,minimax:`<path d="M16.278 2c1.156 0 2.093.927 2.093 2.07v12.501a.74.74 0 00.744.709.74.74 0 00.743-.709V9.099a2.06 2.06 0 012.071-2.049A2.06 2.06 0 0124 9.1v6.561a.649.649 0 01-.652.645.649.649 0 01-.653-.645V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v7.472a2.037 2.037 0 01-2.048 2.026 2.037 2.037 0 01-2.048-2.026v-12.5a.785.785 0 00-.788-.753.785.785 0 00-.789.752l-.001 15.904A2.037 2.037 0 0113.441 22a2.037 2.037 0 01-2.048-2.026V18.04c0-.356.292-.645.652-.645.36 0 .652.289.652.645v1.934c0 .263.142.506.372.638.23.131.514.131.744 0a.734.734 0 00.372-.638V4.07c0-1.143.937-2.07 2.093-2.07zm-5.674 0c1.156 0 2.093.927 2.093 2.07v11.523a.648.648 0 01-.652.645.648.648 0 01-.652-.645V4.07a.785.785 0 00-.789-.78.785.785 0 00-.789.78v14.013a2.06 2.06 0 01-2.07 2.048 2.06 2.06 0 01-2.071-2.048V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v3.8a2.06 2.06 0 01-2.071 2.049A2.06 2.06 0 010 12.9v-1.378c0-.357.292-.646.652-.646.36 0 .653.29.653.646V12.9c0 .418.343.757.766.757s.766-.339.766-.757V9.099a2.06 2.06 0 012.07-2.048 2.06 2.06 0 012.071 2.048v8.984c0 .419.343.758.767.758.423 0 .766-.339.766-.758V4.07c0-1.143.937-2.07 2.093-2.07z"></path>`,mistral:`<path clip-rule="evenodd" d="M3.428 3.4h3.429v3.428h3.429v3.429h-.002 3.431V6.828h3.427V3.4h3.43v13.714H24v3.429H13.714v-3.428h-3.428v-3.429h-3.43v3.428h3.43v3.429H0v-3.429h3.428V3.4zm10.286 13.715h3.428v-3.429h-3.427v3.429z"></path>`,moonshot:`<path d="M1.052 16.916l9.539 2.552a21.007 21.007 0 00.06 2.033l5.956 1.593a11.997 11.997 0 01-5.586.865l-.18-.016-.044-.004-.084-.009-.094-.01a11.605 11.605 0 01-.157-.02l-.107-.014-.11-.016a11.962 11.962 0 01-.32-.051l-.042-.008-.075-.013-.107-.02-.07-.015-.093-.019-.075-.016-.095-.02-.097-.023-.094-.022-.068-.017-.088-.022-.09-.024-.095-.025-.082-.023-.109-.03-.062-.02-.084-.025-.093-.028-.105-.034-.058-.019-.08-.026-.09-.031-.066-.024a6.293 6.293 0 01-.044-.015l-.068-.025-.101-.037-.057-.022-.08-.03-.087-.035-.088-.035-.079-.032-.095-.04-.063-.028-.063-.027a5.655 5.655 0 01-.041-.018l-.066-.03-.103-.047-.052-.024-.096-.046-.062-.03-.084-.04-.086-.044-.093-.047-.052-.027-.103-.055-.057-.03-.058-.032a6.49 6.49 0 01-.046-.026l-.094-.053-.06-.034-.051-.03-.072-.041-.082-.05-.093-.056-.052-.032-.084-.053-.061-.039-.079-.05-.07-.047-.053-.035a7.785 7.785 0 01-.054-.036l-.044-.03-.044-.03a6.066 6.066 0 01-.04-.028l-.057-.04-.076-.054-.069-.05-.074-.054-.056-.042-.076-.057-.076-.059-.086-.067-.045-.035-.064-.052-.074-.06-.089-.073-.046-.039-.046-.039a7.516 7.516 0 01-.043-.037l-.045-.04-.061-.053-.07-.062-.068-.06-.062-.058-.067-.062-.053-.05-.088-.084a13.28 13.28 0 01-.099-.097l-.029-.028-.041-.042-.069-.07-.05-.051-.05-.053a6.457 6.457 0 01-.168-.179l-.08-.088-.062-.07-.071-.08-.042-.049-.053-.062-.058-.068-.046-.056a7.175 7.175 0 01-.027-.033l-.045-.055-.066-.082-.041-.052-.05-.064-.02-.025a11.99 11.99 0 01-1.44-2.402zm-1.02-5.794l11.353 3.037a20.468 20.468 0 00-.469 2.011l10.817 2.894a12.076 12.076 0 01-1.845 2.005L.657 15.923l-.016-.046-.035-.104a11.965 11.965 0 01-.05-.153l-.007-.023a11.896 11.896 0 01-.207-.741l-.03-.126-.018-.08-.021-.097-.018-.081-.018-.09-.017-.084-.018-.094c-.026-.141-.05-.283-.071-.426l-.017-.118-.011-.083-.013-.102a12.01 12.01 0 01-.019-.161l-.005-.047a12.12 12.12 0 01-.034-2.145zm1.593-5.15l11.948 3.196c-.368.605-.705 1.231-1.01 1.875l11.295 3.022c-.142.82-.368 1.612-.668 2.365l-11.55-3.09L.124 10.26l.015-.1.008-.049.01-.067.015-.087.018-.098c.026-.148.056-.295.088-.442l.028-.124.02-.085.024-.097c.022-.09.045-.18.07-.268l.028-.102.023-.083.03-.1.025-.082.03-.096.026-.082.031-.095a11.896 11.896 0 011.01-2.232zm4.442-4.4L17.352 4.59a20.77 20.77 0 00-1.688 1.721l7.823 2.093c.267.852.442 1.744.513 2.665L2.106 5.213l.045-.065.027-.04.04-.055.046-.065.055-.076.054-.072.064-.086.05-.065.057-.073.055-.07.06-.074.055-.069.065-.077.054-.066.066-.077.053-.06.072-.082.053-.06.067-.074.054-.058.073-.078.058-.06.063-.067.168-.17.1-.098.059-.056.076-.071a12.084 12.084 0 012.272-1.677zM12.017 0h.097l.082.001.069.001.054.002.068.002.046.001.076.003.047.002.06.003.054.002.087.005.105.007.144.011.088.007.044.004.077.008.082.008.047.005.102.012.05.006.108.014.081.01.042.006.065.01.207.032.07.012.065.011.14.026.092.018.11.022.046.01.075.016.041.01L14.7.3l.042.01.065.015.049.012.071.017.096.024.112.03.113.03.113.032.05.015.07.02.078.024.073.023.05.016.05.016.076.025.099.033.102.036.048.017.064.023.093.034.11.041.116.045.1.04.047.02.06.024.041.018.063.026.04.018.057.025.11.048.1.046.074.035.075.036.06.028.092.046.091.045.102.052.053.028.049.026.046.024.06.033.041.022.052.029.088.05.106.06.087.051.057.034.053.032.096.059.088.055.098.062.036.024.064.041.084.056.04.027.062.042.062.043.023.017c.054.037.108.075.161.114l.083.06.065.048.056.043.086.065.082.064.04.03.05.041.086.069.079.065.085.071c.712.6 1.353 1.283 1.909 2.031L7.222.994l.062-.027.065-.028.081-.034.086-.035c.113-.045.227-.09.341-.131l.096-.035.093-.033.084-.03.096-.031c.087-.03.176-.058.264-.085l.091-.027.086-.025.102-.03.085-.023.1-.026L9.04.37l.09-.023.091-.022.095-.022.09-.02.098-.021.091-.02.095-.018.092-.018.1-.018.091-.016.098-.017.092-.014.097-.015.092-.013.102-.013.091-.012.105-.012.09-.01.105-.01c.093-.01.186-.018.28-.024l.106-.008.09-.005.11-.006.093-.004.1-.004.097-.002.099-.002.197-.002z"></path>`,morph:`<path d="M7.941 2c.23 0 .452.073.638.21.186.136.325.328.397.55l.593 1.814c.073.221.212.413.397.55.186.136.409.21.638.21h2.791c.23 0 .452-.074.638-.21a1.11 1.11 0 00.397-.55l.594-1.815a1.11 1.11 0 01.397-.55c.185-.136.408-.209.637-.209h1.7c.23 0 .453.073.639.21.185.136.324.328.397.55l.652 1.994c.118.361.41.635.77.728l2.957.752c.236.06.446.199.596.394.15.195.23.436.231.684v9.376c0 .248-.081.488-.231.684a1.09 1.09 0 01-.595.394l-2.957.752a1.086 1.086 0 00-.477.263 1.114 1.114 0 00-.293.465l-.653 1.994a1.11 1.11 0 01-.396.55c-.186.136-.41.21-.638.21h-1.702c-.229 0-.452-.073-.637-.21a1.11 1.11 0 01-.397-.55l-.364-1.11a1.131 1.131 0 01.15-1.002 1.074 1.074 0 01.885-.462h2.85c.29 0 .567-.116.772-.325.204-.208.32-.49.32-.785V6.444c0-.294-.116-.577-.32-.785a1.08 1.08 0 00-.771-.326h-3.273c-.29 0-.567.117-.772.326-.204.208-.32.49-.32.785v7.778c0 .295-.114.578-.319.786a1.08 1.08 0 01-.771.325h-2.182a1.08 1.08 0 01-.771-.325 1.122 1.122 0 01-.32-.786V6.444c0-.294-.115-.577-.32-.785a1.081 1.081 0 00-.77-.326H5.454c-.29 0-.567.117-.772.326-.204.208-.32.49-.32.785v11.112c0 .294.116.577.32.785.205.209.482.326.772.326h2.85a1.075 1.075 0 01.885.461 1.122 1.122 0 01.15 1.001l-.364 1.112a1.11 1.11 0 01-.397.55c-.185.136-.408.209-.637.209H6.24c-.229 0-.452-.073-.638-.21a1.11 1.11 0 01-.397-.55l-.652-1.994a1.114 1.114 0 00-.294-.465 1.086 1.086 0 00-.477-.263l-2.956-.752a1.09 1.09 0 01-.595-.394A1.124 1.124 0 010 16.688V7.312c0-.248.081-.489.231-.684.15-.195.36-.334.595-.394l2.957-.753c.178-.045.342-.136.477-.263.134-.127.235-.287.293-.464l.653-1.995a1.11 1.11 0 01.397-.55C5.788 2.075 6.01 2 6.24 2h1.701z"></path>`,nousresearch:`<path d="M5.938 12.835c.127-.039.285.02.373.143.028.038.036.092.046.14.003.014-.02.033-.04.05-.124-.098-.24-.194-.354-.291-.011-.01-.016-.027-.025-.042zM8.396 9.412c.195-.032.39-.06.588-.05a.54.54 0 01.148.026c.202.071.402.147.601.224.028.01.05.036.075.055l-.013.027a9.203 9.203 0 01-.26-.089c-.115-.038-.213-.077-.315-.098-.25-.05-.25-.046-.292-.014l.574.144c.275.139.55.276.823.417.042.022.09.057.107.098.026.06.063.076.117.072.066-.006.132-.017.213-.027l-.04.086c.051.08.142.02.216.064-.074.13-.247.09-.334.199l.061.074-.12.087c0 .106-.038.168-.306.243l.026.085-.196.042.07.124h-.25l-.007.137c-.081-.01-.161-.018-.244-.027l-.053.123c-.027-.008-.052-.011-.073-.023-.067-.038-.128-.056-.195.006-.019.017-.063.014-.093.008-.026-.006-.05-.029-.07-.042-.11.095-.11.095-.208.003-.057.046-.12.074-.186.011-.063.027-.123-.02-.178-.014-.07.007-.097-.035-.133-.07l-.13.033c-.013-.236-.194-.19-.34-.203.005-.072.05-.092.095-.094a.474.474 0 01.159.022c.164.05.32.12.496.138.203.021.405.029.601-.015.265-.059.52-.149.707-.365.049-.056.083-.127.117-.195.019-.038.02-.084-.02-.116a1.397 1.397 0 00-.382-.217c.024.12-.031.182-.115.221 0 .014-.004.025 0 .03.08.115.084.16-.007.267a1.39 1.39 0 01-.218.211.477.477 0 01-.641-.05 1.36 1.36 0 01-.133-.152c-.078-.107-.076-.108-.033-.236-.165-.08-.128-.226-.104-.364.008-.05.028-.096.049-.163-.04.014-.067.017-.087.032a.897.897 0 00-.316.357c-.007.016-.01.034-.02.047-.012.015-.034.038-.045.035-.02-.006-.037-.027-.05-.045-.008-.012-.007-.032-.012-.057h-.126l.053-.172a14.82 14.82 0 00-.039-.049l.11-.284c-.06.026-.091.044-.124.051-.03.007-.064 0-.095 0 0-.031-.01-.07.004-.092.149-.22.305-.428.593-.476z"></path><path d="M8.06 10.788c-.003-.038-.004-.075.037-.062.016.006.034.048.028.067-.01.04-.038.032-.064-.005z"></path><path clip-rule="evenodd" d="M11.981.009c.226-.012.453-.011.679 0 .247.01.495.024.74.062.401.064.798.157 1.19.273.463.138.92.299 1.356.511a7.31 7.31 0 012.948 2.642c.292.469.536.963.739 1.479.219.556.446 1.11.623 1.683.204.654.329 1.326.458 1.997.097.504.182 1.01.29 1.511.156.722.329 1.44.494 2.16.186.812.4 1.615.63 2.415.102.355.193.713.282 1.072.11.436.202.876.254 1.323.031.278.066.557.073.837a7.56 7.56 0 01-.017.88c-.037.413-.1.818-.226 1.212a5.017 5.017 0 01-.915 1.649l-.13.156.018.023c.043-.023.088-.041.127-.068.2-.138.373-.307.531-.49.4-.46.721-.973.975-1.529a3.59 3.59 0 00.325-1.72c-.024-.424-.097-.834-.3-1.213-.013-.027-.015-.06-.03-.121.05.035.082.048.101.072.107.13.22.258.315.398.33.494.46 1.052.486 1.64a3.75 3.75 0 01-.47 1.97c-.36.655-.887 1.14-1.526 1.506-.193.111-.394.21-.595.308-.157.078-.248.211-.318.365a.522.522 0 00-.033.406.359.359 0 01.013.139c-.005.077-.077.155-.14.162-.054.006-.125-.043-.15-.116a1.206 1.206 0 01-.06-.233c-.04-.314-.155-.6-.308-.87a3.906 3.906 0 00-.73-.91 2.129 2.129 0 00-.897-.524 4.093 4.093 0 00-.692-.131c-.075-.008-.15-.04-.22.01.18.06.363.11.538.18.434.173.82.43 1.18.728.308.255.58.543.794.884.098.155.186.315.227.496.027.123.042.25.067.375.013.062-.002.109-.053.144-.047.033-.122.034-.163-.01a.455.455 0 01-.08-.14c-.03-.073-.038-.159-.078-.225a7.314 7.314 0 00-1.423-1.664c-.16-.137-.329-.26-.537-.323-.376-.114-.753-.203-1.15-.154-.213.025-.427.032-.64.053a1.6 1.6 0 00-.736.278 5.14 5.14 0 00-.834.72c-.329.342-.642.699-.955 1.055-.136.155-.264.319-.314.531a5.227 5.227 0 00-.012.051.096.096 0 01-.09.076h-.31c-.046 0-.082-.048-.072-.094.023-.108.045-.216.07-.324.075-.325.19-.635.368-.917.024-.039.04-.088.104-.08l.01.049.027.077c.28-.435.571-.834.996-1.135.283-.204.584-.378.89-.55a.196.196 0 00-.098-.002c-.162.043-.325.084-.485.134-.402.124-.764.33-1.11.566-.147.1-.298.193-.414.333a7.314 7.314 0 00-1.07 1.767.845.845 0 00-.04.12.075.075 0 01-.072.056h-.494c-.04 0-.062-.051-.036-.082.123-.14.246-.282.377-.415.275-.281.58-.532.777-.884.027-.048.063-.09.095-.135.238-.333.54-.607.818-.902.082-.086.175-.16.26-.24.029-.027.053-.057.079-.085l-.018-.025-.135.041c-.034.017-.07.031-.102.05-.248.144-.494.292-.743.433-.408.23-.825.439-1.209.711-.281.2-.591.358-.889.533-.02.012-.044.015-.08.028-.015-.135.143-.201.108-.336-.033.014-.064.02-.085.038-.111.096-.227.19-.328.296-.148.157-.284.325-.425.488-.125.143-.25.286-.373.431A.153.153 0 019.89 24H8.762a.316.316 0 00.016-.042c.028-.09.085-.172.083-.28-.091-.018-.162.001-.212.077a4.45 4.45 0 00-.136.215c-.01.016-.024.03-.042.03h-.093c-.019 0-.029-.022-.017-.037.071-.088.14-.178.209-.268.001-.002-.006-.012-.012-.024-.014.004-.03.006-.045.013-.176.09-.352.181-.527.274a.363.363 0 01-.168.042H5.202c-.026 0-.039-.036-.019-.053.21-.178.402-.374.558-.605.335-.496.538-1.047.667-1.629.004-.02-.003-.043-.006-.091-.037.048-.059.072-.076.1a1.943 1.943 0 01-.334.415c-.28.258-.59.448-.983.464-.297.012-.588 0-.865-.127-.46-.21-.722-.57-.794-1.072-.025-.17-.017-.171-.182-.219A3.513 3.513 0 011.97 20.6a2.286 2.286 0 01-.808-1.13 3.569 3.569 0 01-.16-1.245c.002-.034.016-.067.024-.1.032.023.046.043.05.066.033.153.059.308.096.46.086.355.257.664.516.92.258.256.571.419.91.532.358.118.717.138 1.07-.016a1.89 1.89 0 00.621-.452c.328-.348.533-.76.648-1.223.009-.034.005-.071.007-.11-.015.006-.026.006-.03.011-.031.05-.064.1-.093.152-.284.502-.679.887-1.196 1.135-.351.17-.718.255-1.11.159a1.607 1.607 0 01-.971-.64 2.006 2.006 0 01-.368-.924 2.903 2.903 0 01.02-.886c.05-.439.466-1.17.742-1.271-.02.063-.035.112-.053.16-.043.116-.097.227-.13.345a1.901 1.901 0 00-.05.82c.033.212.09.416.204.6.147.236.346.407.62.465.11.023.225.014.338.018a.576.576 0 00.386-.131c.164-.128.282-.292.366-.481.168-.375.24-.777.309-1.179.05-.296.093-.594.133-.893.039-.281.071-.563.104-.845.026-.232.048-.464.074-.696.024-.228.052-.455.076-.683.024-.227.047-.455.069-.683.013-.14.022-.28.034-.42l.037-.417c.022-.25.041-.5.065-.748.008-.082-.02-.132-.09-.177a2.46 2.46 0 01-.492-.418c-.1-.109-.188-.228-.282-.342-.035-.042-.056-.097-.116-.118a2.084 2.084 0 00.275.597c.06.092.131.176.196.265.063.086.182.115.234.226-.028.003-.046.01-.06.006a4.74 4.74 0 01-.22-.057 2.71 2.71 0 01-1.287-.819c-.435-.487-.656-1.076-.71-1.723a5.206 5.206 0 01.014-1.06c.072-.602.22-1.186.45-1.745.155-.376.338-.741.526-1.102.205-.393.466-.75.765-1.076.512-.559 1.104-1.024 1.726-1.448.717-.49 1.478-.898 2.277-1.233C8.244.828 8.767.632 9.31.494c.655-.166 1.31-.33 1.982-.415.229-.03.458-.058.688-.07zm-1.847 22.82c-.07.06-.147.111-.207.18-.238.27-.464.549-.668.869l-.044.108a.177.177 0 00.093-.057c.174-.19.351-.378.519-.574.104-.122.195-.255.288-.386.024-.034.03-.08.046-.12l-.027-.02zm1.65-3.695a5.51 5.51 0 00-.653.593l-.37.386a.963.963 0 01-.377.25 1.372 1.372 0 01-.467.09c-.044 0-.087.006-.151.012.028.058.043.097.064.131.15.242.301.482.45.724.136.22.276.438.399.666.068.125.105.267.156.404.077.027.14-.018.202-.048.29-.135.579-.274.867-.412.213-.101.437-.186.636-.31.347-.215.68-.455 1.018-.685.015-.01.026-.028.042-.046-.023-.019-.038-.037-.056-.044-.287-.111-.527-.3-.77-.482a5.319 5.319 0 01-.506-.42 1.757 1.757 0 01-.41-.653c-.019-.049-.045-.095-.075-.156zm-5.847.264c-.06.096-.097.194-.132.293a3.38 3.38 0 01-.555 1.01c-.2.25-.455.412-.762.493-.23.06-.464.076-.7.07-.048-.002-.097.002-.158.005.016.04.021.066.035.085.1.145.23.246.4.295.157.046.316.034.498.023.181-.037.343-.115.485-.234.238-.199.402-.454.536-.732.175-.363.264-.751.342-1.144.01-.053.008-.11.011-.164zm14.945-4.586c.008.029.016.057.027.107.024.155.051.31.072.464.03.219.067.437.078.657.017.344.027.689-.014 1.033-.037.315-.063.633-.116.946a6.153 6.153 0 01-.46 1.518c-.008.018-.01.039-.02.082.047-.03.077-.042.098-.064.085-.083.17-.167.248-.255.271-.305.458-.66.596-1.043.18-.498.228-1.011.145-1.531-.103-.65-.33-1.263-.597-1.881a9.055 9.055 0 00-.024-.055l-.033.022zM5.797 8.29a.26.26 0 00.018.153c.124.251.25.501.379.75.025.049.066.09.03.163-.284.06-.578.119-.88.255.059.038.097.06.132.087.042.032.112.058.09.12-.01.033-.075.048-.117.072.017.01.043.021.067.036.166.102.33.207.447.368.138.192.229.404.188.644-.079.469-.306.85-.69 1.132-.054.04-.106.083-.161.122a.243.243 0 00-.103.245.77.77 0 00.055.195c.083.196.22.35.375.492.083.076.159.164.222.257a.37.37 0 01.025.377c-.023.05-.05.099-.076.148-.03.06-.028.111.022.162.041.042.08.089.112.138.038.058.078.079.147.05a.486.486 0 01.333-.006c.16.046.302.126.444.21.13.077.264.149.4.219.067.035.14.05.219.026.071-.022.124.01.145.076.02.064-.003.108-.074.139-.07.03-.137.063-.209.088-.1.035-.201.073-.314.077-.013-.107.11-.088.127-.159-.206-.126-.643-.145-.801-.034.063.112.035.21-.096.313-.13-.1-.025-.202.002-.3a.209.209 0 00-.249.17c-.015.101.067.216.178.224.108.007.218-.005.326-.012.06-.005.12-.027.199 0-.103.123-.248.127-.357.19.002.05.07.086.019.131-.053.048-.095-.001-.132-.03-.08-.063-.16-.126-.231-.197a.474.474 0 01-.157-.311.52.52 0 00-.043-.172c-.032-.074-.032-.137.033-.19-.018-.03-.028-.053-.045-.072a1.222 1.222 0 01-.196-.369c-.053-.137-.046-.264.048-.381.024-.03.05-.06.064-.095a.664.664 0 00.047-.168c.017-.165-.064-.287-.182-.387-.186-.156-.36-.322-.46-.551-.005-.011-.024-.017-.037-.026-.011.017-.024.027-.025.038-.019.185-.045.37-.052.557-.014.377.058.743.162 1.104.118.41.289.798.488 1.173.267.502.537 1.002.812 1.5.055.098.13.189.208.27.198.202.452.272.724.273.202 0 .404-.006.605-.026.295-.03.59-.073.884-.113.183-.025.365-.057.548-.08.21-.026.38.073.522.21.16.156.305.327.447.5.22.265.397.56.554.867.05.098.07.1.147.03.13-.121.26-.242.394-.36.067-.059.088-.12.067-.213a3.535 3.535 0 01-.085-.796c.002-.157.006-.314.018-.471.015-.224.03-.45.06-.672a59.114 59.114 0 01.362-2.298c.087-.493.182-.984.268-1.477.06-.347.118-.694.162-1.043.034-.273.055-.55.063-.825.011-.332.003-.665.002-.998 0-.077.004-.155-.01-.23-.028-.142-.01-.155-.162-.19a5.826 5.826 0 00-.607-.107c-.146-.018-.207-.053-.221-.19-.006-.049-.025-.098-.041-.146-.009-.025-.024-.048-.046-.09l-.025.264c-.009.096-.029.116-.127.115-.055 0-.11-.008-.164-.008-.476 0-.952-.008-1.426.032-.095.008-.173-.015-.226-.103-.04-.066-.088-.126-.134-.186-.063-.084-.086-.093-.182-.06-.195.068-.388.138-.582.21a2.71 2.71 0 00-.675.394.986.986 0 01-.323.168c-.033.01-.07.008-.127.013.02-.066.024-.114.047-.15.064-.105.135-.205.205-.306.023-.033.049-.063.073-.095l-.015-.023-.201.037c-.146.04-.296.07-.437.122-.148.053-.266.023-.386-.072a3.623 3.623 0 01-.733-.786l-.093-.132zm8.592 8.963l-.147.09c-.22.134-.44.266-.659.402-.093.058-.184.12-.27.188-.085.07-.124.161-.072.272.047.1.093.2.147.294.047.08.124.138.213.147.11.01.228.012.336-.012.217-.05.372-.205.528-.357a.291.291 0 00.087-.308c-.046-.18-.079-.365-.118-.547-.011-.052-.027-.103-.045-.169zm-.257-2.409c-.12.291-.205.597-.325.91-.151.433-.294.87-.435 1.323.036-.01.054-.01.067-.018.261-.16.522-.324.785-.484.054-.033.071-.078.065-.138-.012-.13-.024-.262-.034-.393l-.068-.886c-.008-.103-.02-.206-.029-.31-.009 0-.017-.002-.026-.004zm3.081-8.13l.099.285c.08.231.159.463.24.714l.58 1.952c.187.63.372 1.262.558 1.893.114.382.235.762.343 1.146.072.257.126.519.186.799.044.206.087.413.127.64.034.106.023.226.077.325l.025-.006-.068-.362c-.038-.206-.077-.412-.113-.638-.015-.07-.029-.141-.046-.211-.095-.396-.177-.796-.29-1.187-.196-.685-.413-1.364-.618-2.046-.165-.549-.322-1.1-.488-1.648-.069-.227-.15-.45-.226-.695l-.117-.336c-.037-.107-.075-.216-.115-.322-.04-.106-.084-.21-.127-.314a7.558 7.558 0 01-.027.01zM6.225 14.304c-.063-.001-.115.014-.134.083a.35.35 0 00.41.012 4.533 4.533 0 00-.276-.095zM5.23 11.98c-.026-.027-.057-.048-.075.002-.012.032-.007.07-.01.113.082-.037.082-.037.085-.115zm.062-1.189a.135.135 0 00-.088.056.197.197 0 00-.025.11c.005.152.01.306.026.457a.751.751 0 00.066.218c.061.136.157.167.288.101.055-.027.06-.054.025-.11a4.52 4.52 0 01-.129-.211c-.015-.068-.066-.131-.033-.207.04-.09-.076-.116-.074-.19V10.874c-.003-.038-.006-.087-.056-.083zm-.017-.968a.867.867 0 00-.467.127c-.076.045-.084.07-.05.158.034.087.07.173.115.254.064.117.09.125.21.077a.657.657 0 01.336-.053c.202.022.357.136.504.264l.092.077c.007-.006.014-.013.022-.018-.019-.105-.035-.226-.149-.264-.157-.053-.324-.075-.508-.117l-.24-.005c.24-.169.452-.044.687.009-.063-.115-.153-.147-.23-.193-.082-.05-.17-.092-.25-.144-.06-.037-.12-.08-.072-.172zm10.233.325c-.23-.01-.427.08-.608.211-.034.026-.06.065-.105.117.087.026.15.046.232.065.044-.015.088-.03.13-.046.306-.114.61-.115.904.031.126.063.237.04.366-.005-.02-.031-.03-.054-.045-.071a.986.986 0 00-.448-.273c-.14-.044-.284-.024-.426-.03zM7.99 6.483a.308.308 0 00.002.133c.08.321.156.643.242.962.104.387.27.75.456 1.103.02.037.061.08.098.087a.404.404 0 00.253-.051l-.472-.84c-.23-.448-.405-.92-.579-1.394zM10.397.497c-.2-.008-.405.004-.603.034-.236.035-.47.087-.7.152-.287.08-.569.18-.852.273-.04.013-.074.038-.11.058.028.014.05.018.07.014.287-.068.58-.085.873-.09.134-.002.269.009.402.025.19.024.382.048.57.09.456.104.874.3 1.265.556.464.306.888.66 1.257 1.078.205.232.395.475.56.739.17.274.315.561.449.856.273.601.456 1.232.6 1.876.04.173.07.348.1.524.017.104.065.167.17.19.122.028.2.105.22.251-.003.102-.06.174-.129.24a1.065 1.065 0 00-.268.358.164.164 0 00.083-.039c.08-.086.162-.172.235-.265a.56.56 0 00.13-.333c.009-.05.022-.1.024-.15.007-.124-.017-.15-.143-.168-.025-.004-.049-.014-.073-.015-.082-.007-.125-.063-.137-.131-.033-.198-.004-.355.247-.408.086-.018.174-.03.26-.042.158-.023.315-.053.473-.067.14-.012.19.033.226.167.008.029.018.057.021.087.019.179-.008.225-.141.288-.027.013-.055.024-.078.042a.148.148 0 00-.051.067c-.039.144.073.382.206.445l.673.32c.023.011.05.015.075.023l.018-.026c-.015-.008-.032-.013-.044-.024a2.27 2.27 0 00-.544-.32 4.898 4.898 0 00-.173-.075.203.203 0 01-.126-.191c-.003-.085.045-.154.128-.187l.059-.025c.099-.044.118-.076.112-.187a.384.384 0 00-.008-.063c-.067-.294-.123-.59-.205-.88a9.478 9.478 0 00-.826-2.036 7.465 7.465 0 00-1.39-1.805 4.536 4.536 0 00-1.177-.824 3.656 3.656 0 00-1.016-.328 6.155 6.155 0 00-.712-.074zm6.719 5.955c.01.014.018.028.038.034l-.022-.044-.016.01zM4.103 3.917a.062.062 0 01-.03.012.455.455 0 01-.04.039c-.01.01-.02.02-.045.04l-.363.354c-.088.085-.17.178-.266.253-.284.22-.425.53-.544.855a.132.132 0 00-.007.071c.013.055.033.108.052.168l.074.026c-.017.056-.03.105-.047.152-.058.164-.118.327-.175.491-.005.015.008.036.019.077.08-.175.158-.33.225-.489.228-.544.484-1.074.819-1.561.09-.133.182-.266.283-.401.004-.006.007-.013.022-.03.001-.016.003-.032.015-.04l.008-.017zm12.976 2.408a.023.023 0 01.009.019.073.073 0 00-.006.01.188.188 0 00.007.02l.018.022c.002-.007.007-.016.005-.021-.003-.01-.012-.018-.02-.038a1.331 1.331 0 01-.013-.012zM4.199 4.48c-.003.004-.008.008-.027.014-.005.013-.011.025-.031.047a2.085 2.085 0 01-.124.167c-.048.07-.116.055-.181.041-.134-.028-.228.016-.287.143-.089.187-.187.37-.273.56-.049.108-.11.216-.118.36.081.003.154.007.228.008h.228a2.563 2.563 0 01-.079.264c-.01.052-.022.103-.033.155l.02.004c.018-.046.037-.092.067-.153.066-.142.13-.285.2-.426.02-.04.034-.1.116-.092 0 .043.004.084 0 .124-.005.045-.017.09-.028.143.141.043.086.174.115.269.102-.022.104-.195.248-.144v.205l.017.002.439-1.059c-.13 0-.246-.02-.358.033-.024.011-.058-.001-.108-.004.075-.15.139-.278.211-.417a.128.128 0 01.025-.036c0-.015-.001-.03.008-.038l.006-.02c-.005.006-.01.011-.028.017-.004.012-.009.024-.026.045a.085.085 0 01-.032.033c-.123.157-.09.164-.258.106-.079-.027-.078-.028-.047-.144.028-.046.056-.093.098-.15 0-.016-.001-.032.007-.042L4.2 4.48zm2.073-.67c-.003.006-.007.011-.027.016-.094.125-.194.246-.28.377-.155.238-.301.481-.451.723-.14.224-.345.368-.575.481-.017.008-.04.006-.079.011.012-.059.016-.109.033-.153a6.076 6.076 0 01.229-.518l-.007-.02a.138.138 0 01-.035.025c-.028.05-.055.1-.093.164-.26.424-.443.817-.442.95.024.004.048.011.073.013.177.013.188.007.26-.165.03-.07.077-.12.147-.15l.175-.07c.044-.018.085-.057.146-.032.003.05-.01.11.014.145.042.062.044.125.047.193.002.049.017.098.026.147.029-.034.039-.065.05-.097.142-.39.277-.782.428-1.17.1-.256.22-.504.33-.756.013-.03.013-.067.03-.092V3.81zm3.987-.34c0 .045.01.084.021.123.042.16.094.318.124.48.024.133.023.27.028.406 0 .033-.019.067-.032.11-.094-.058-.047-.158-.106-.215h-.125c-.015.072-.01.152-.046.2-.066.085-.155.154-.236.227-.043.038-.078.018-.103-.025l-.046-.087c-.065.035-.117.069-.172.093-.116.051-.235.095-.35.147-.085.038-.09.053-.07.147.014.075.034.148.047.223.013.072.05.109.123.124.233.05.462.115.657.265.058-.102.058-.102.168-.151.03-.014.06-.03.092-.042.08-.03.115-.017.15.06.023.048.041.098.066.158.06-.14-.042-.267.017-.416.157.18.24.39.375.567a.235.235 0 00.022-.098c.002-.124 0-.247.002-.371 0-.034.013-.067.02-.1l.032-.003c.11.155.13.354.226.52a3.036 3.036 0 00-.01-.392c-.004-.045 0-.074.05-.088.08.036.116.14.215.158-.03-.275-.423-1.137-.798-1.635-.114-.127-.2-.28-.34-.386zm-2.667.696c-.019.034-.03.05-.037.067-.061.185-.125.37-.18.556-.031.105-.087.169-.195.19-.09.019-.178.052-.268.073-.038.009-.089.015-.118-.003-.024-.016-.025-.069-.036-.106-.064.076-.082.087-.17.047-.133-.062-.262-.135-.393-.201-.048-.025-.093-.063-.17-.03-.043.12-.091.25-.137.382-.099.28-.087.242.095.453.046.048.102.03.154.023.054-.009.106-.03.16-.036.13-.013.26-.08.367-.015.204-.064.387-.122.571-.178.05-.015.089.005.114.054.022.042.034.093.082.121.038-.056-.013-.128.063-.178l.14.241-.042-1.46zm.278.358c-.096-.01-.107.01-.11.108-.002.038-.003.078.002.115.03.2.099.386.174.57.002.006.012.01.022.015l.078-.05c.052.036.081.088.153.088.205-.002.41.014.616.012.099-.001.158.042.205.12.018.03.024.077.088.066l-.08-.394c-.05-.195-.085-.395-.172-.589-.057.057-.114.068-.18.046a.72.72 0 00-.135-.028c-.22-.028-.44-.059-.66-.08zm10.254-1.727c.089.163.155.316.139.491-.016.168.026.342-.044.516-.047-.033-.088-.082-.112-.075-.117.035-.164-.057-.227-.115a4.772 4.772 0 01-.286-.29l-.104-.113a4.856 4.856 0 01-.023.019c.035.046.07.093.11.156.04.064.084.127.122.193.034.058.065.118.031.205-.082-.01-.164-.019-.246-.032-.06-.01-.101 0-.124.07-.031.098-.037.096-.15.09.02.042.036.08.057.116.041.074.03.138-.03.196-.06.06-.118.122-.178.181a.175.175 0 01-.185.046c-.222-.061-.447-.113-.67-.174-.032-.009-.063-.04-.086-.068-.03-.04-.052-.087-.08-.13-.044-.07-.09-.138-.136-.207a.18.18 0 00-.014.105c.012.127.03.253.035.38.005.1-.024.12-.121.104-.104-.017-.206-.04-.31-.058-.064-.012-.131-.028-.202.03l.081.208c.09 0 .166-.01.237.002a.819.819 0 01.458.251c.078.083.154.168.241.26l.018-.005c-.004-.006-.008-.013-.01-.04.014-.056-.062-.118.018-.178.031.03.064.057.088.09.058.078.111.159.169.257l.089.141.024-.013a2093.819 2093.819 0 01-.427-.934c.055.007.083.007.108.016.193.07.385.142.577.216.074.028.147.06.219.094.062.028.112.018.157-.033.05-.056.102-.112.154-.167.05-.051.095-.046.132.014.016.025.026.053.04.08.071.138.143.277.217.433l.159.308.025-.011c-.044-.106-.07-.218-.138-.334-.057-.182-.168-.346-.206-.545.136.034.362.326.567.732l.057.074.018-.011a1.563 1.563 0 01-.052-.127c-.046-.145-.097-.29-.136-.436-.022-.083-.036-.173.022-.26l.109.058-.026-.207.027-.016c.022.02.05.036.065.06.073.108.143.22.215.33.01.016.029.029.043.043-.036-.217-.2-.38-.229-.626l.155.112c.014-.166.012-.319.042-.465.032-.158-.023-.297-.063-.445.024.004.036.006.055.025.092.124.183.249.277.371.02.027.05.047.069.087l.04.063.019-.015a.293.293 0 01-.053-.082 27.922 27.922 0 01-.332-.49c-.221-.311-.363-.467-.485-.521zm-6.57.327c-.003.161.092.275.069.415l-.368.087c.09.139.032.237-.052.331-.05.057-.092.122-.143.178-.037.04-.046.078-.018.126l.16.275c.029.048.072.066.128.064.076-.003.152 0 .228-.001.116-.003.216.022.275.137.006.014.02.024.044.052.004-.059-.003-.098.01-.13.016-.04.04-.099.072-.108.084-.023.173-.024.26-.03.013-.001.027.018.04.029l.071.065c.019-.11-.082-.198-.024-.31l.126.04c-.026-.123-.07-.245-.071-.366 0-.123.051-.243.115-.36.107.062.16.156.234.253.183.265.36.533.494.834.165-.078.27.068.407.088-.003-.106-.133-.441-.197-.492a.142.142 0 00-.102-.028c-.06.011-.119.039-.191.063-.025-.039-.056-.078-.077-.122a3.936 3.936 0 00-.473-.783c-.076-.094-.16-.182-.228-.26l-.391.285c-.049.035-.094.03-.132-.017l-.169-.207c-.025-.03-.053-.059-.097-.108z"></path>`,nvidia:`<path d="M10.212 8.976V7.62c.127-.01.256-.017.388-.021 3.596-.117 5.957 3.184 5.957 3.184s-2.548 3.647-5.282 3.647a3.227 3.227 0 01-1.063-.175v-4.109c1.4.174 1.681.812 2.523 2.258l1.873-1.627a4.905 4.905 0 00-3.67-1.846 6.594 6.594 0 00-.729.044m0-4.476v2.025c.13-.01.259-.019.388-.024 5.002-.174 8.261 4.226 8.261 4.226s-3.743 4.69-7.643 4.69c-.338 0-.675-.031-1.007-.092v1.25c.278.038.558.057.838.057 3.629 0 6.253-1.91 8.794-4.169.421.347 2.146 1.193 2.501 1.564-2.416 2.083-8.048 3.763-11.24 3.763-.308 0-.603-.02-.894-.048V19.5H24v-15H10.21zm0 9.756v1.068c-3.356-.616-4.287-4.21-4.287-4.21a7.173 7.173 0 014.287-2.138v1.172h-.005a3.182 3.182 0 00-2.502 1.178s.615 2.276 2.507 2.931m-5.961-3.3c1.436-1.935 3.604-3.148 5.961-3.336V6.523C5.81 6.887 2 10.723 2 10.723s2.158 6.427 8.21 7.015v-1.166C5.77 16 4.25 10.958 4.25 10.958h-.002z"></path>`,openai:`<path d="M9.205 8.658v-2.26c0-.19.072-.333.238-.428l4.543-2.616c.619-.357 1.356-.523 2.117-.523 2.854 0 4.662 2.212 4.662 4.566 0 .167 0 .357-.024.547l-4.71-2.759a.797.797 0 00-.856 0l-5.97 3.473zm10.609 8.8V12.06c0-.333-.143-.57-.429-.737l-5.97-3.473 1.95-1.118a.433.433 0 01.476 0l4.543 2.617c1.309.76 2.189 2.378 2.189 3.948 0 1.808-1.07 3.473-2.76 4.163zM7.802 12.703l-1.95-1.142c-.167-.095-.239-.238-.239-.428V5.899c0-2.545 1.95-4.472 4.591-4.472 1 0 1.927.333 2.712.928L8.23 5.067c-.285.166-.428.404-.428.737v6.898zM12 15.128l-2.795-1.57v-3.33L12 8.658l2.795 1.57v3.33L12 15.128zm1.796 7.23c-1 0-1.927-.332-2.712-.927l4.686-2.712c.285-.166.428-.404.428-.737v-6.898l1.974 1.142c.167.095.238.238.238.428v5.233c0 2.545-1.974 4.472-4.614 4.472zm-5.637-5.303l-4.544-2.617c-1.308-.761-2.188-2.378-2.188-3.948A4.482 4.482 0 014.21 6.327v5.423c0 .333.143.571.428.738l5.947 3.449-1.95 1.118a.432.432 0 01-.476 0zm-.262 3.9c-2.688 0-4.662-2.021-4.662-4.519 0-.19.024-.38.047-.57l4.686 2.71c.286.167.571.167.856 0l5.97-3.448v2.26c0 .19-.07.333-.237.428l-4.543 2.616c-.619.357-1.356.523-2.117.523zm5.899 2.83a5.947 5.947 0 005.827-4.756C22.287 18.339 24 15.84 24 13.296c0-1.665-.713-3.282-1.998-4.448.119-.5.19-.999.19-1.498 0-3.401-2.759-5.947-5.946-5.947-.642 0-1.26.095-1.88.31A5.962 5.962 0 0010.205 0a5.947 5.947 0 00-5.827 4.757C1.713 5.447 0 7.945 0 10.49c0 1.666.713 3.283 1.998 4.448-.119.5-.19 1-.19 1.499 0 3.401 2.759 5.946 5.946 5.946.642 0 1.26-.095 1.88-.309a5.96 5.96 0 004.162 1.713z"></path>`,openclaw:`<g clip-path="url(#a)"><path d="M9.046 7.104a.527.527 0 110 1.055.527.527 0 010-1.055z"></path><path d="M15.376 7.104a.528.528 0 110 1.056.528.528 0 010-1.056z"></path><path clip-rule="evenodd" d="M16.877 1.912c.58-.27 1.14-.323 1.616-.037a.317.317 0 01-.326.542c-.227-.136-.547-.153-1.022.068-.352.165-.765.45-1.234.866 2.683 1.17 4.4 3.5 5.148 5.921a6.421 6.421 0 00-.704.184c-.578.016-1.174.204-1.502.735-.338.55-.268 1.276.072 2.069l.005.012.007.014c.523 1.045 1.318 1.91 2.2 2.284-.912 3.274-3.44 6.144-5.972 6.988v2.109h-2.11v-2.11c-1.043.417-2.086.01-2.11 0v2.11h-2.11v-2.11c-2.531-.843-5.061-3.713-5.973-6.987.882-.373 1.678-1.238 2.2-2.284l.007-.014.006-.012c.34-.793.41-1.518.071-2.069-.327-.531-.923-.719-1.503-.735a6.409 6.409 0 00-.704-.183c.749-2.421 2.466-4.751 5.149-5.922-.47-.416-.88-.701-1.234-.866-.474-.221-.794-.204-1.021-.068a.318.318 0 01-.435-.109.317.317 0 01.109-.433c.476-.286 1.036-.233 1.615.037.49.229 1.031.628 1.621 1.182A9.924 9.924 0 0112 2.568c1.199 0 2.284.19 3.256.526.59-.554 1.13-.953 1.62-1.182zM8.835 6.577a1.266 1.266 0 100 2.532 1.266 1.266 0 000-2.532zm6.33 0a1.267 1.267 0 100 2.533 1.267 1.267 0 000-2.533z"></path><path d="M.395 13.118c-.966-1.932-.163-3.863 2.41-3.365v-.001l.05.01c.084.018.17.038.26.06.033.009.067.017.1.027.084.022.168.048.255.076l.09.027c.528 0 .95.158 1.16.501.212.343.212.87-.105 1.61-.085.17-.178.333-.276.489l-.01.017a4.967 4.967 0 01-.62.791l-.019.02c-1.092 1.117-2.496 1.336-3.295-.262z"></path><path d="M21.193 9.753c2.574-.5 3.378 1.433 2.411 3.365-.58 1.159-1.476 1.361-2.342.96l-.011-.005a2.419 2.419 0 01-.114-.056l-.019-.01a2.751 2.751 0 01-.115-.067l-.023-.014c-.035-.022-.071-.044-.106-.068l-.05-.035c-.55-.388-1.062-1.007-1.44-1.76-.276-.647-.311-1.132-.174-1.472.176-.439.636-.639 1.23-.639.032-.011.066-.02.099-.03.08-.026.16-.05.238-.072l.117-.03a5.502 5.502 0 01.3-.067z"></path></g><defs><linearGradient gradientUnits="userSpaceOnUse" id="b" x1="-.659" x2="27.023" y1=".458" y2="22.855"><stop stop-color="#FF4D4D"></stop><stop offset="1" stop-color="#991B1B"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="c" x1="-.659" x2="27.023" y1=".458" y2="22.855"><stop stop-color="#FF4D4D"></stop><stop offset="1" stop-color="#991B1B"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="d" x1="-.659" x2="27.023" y1=".458" y2="22.855"><stop stop-color="#FF4D4D"></stop><stop offset="1" stop-color="#991B1B"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="e" x1="-.659" x2="27.023" y1=".458" y2="22.855"><stop stop-color="#FF4D4D"></stop><stop offset="1" stop-color="#991B1B"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="f" x1="-.659" x2="27.023" y1=".458" y2="22.855"><stop stop-color="#FF4D4D"></stop><stop offset="1" stop-color="#991B1B"></stop></linearGradient><clipPath id="a"><path d="M0 0h24v24H0z"></path></clipPath></defs>`,openrouter:`<path d="M18.654 3.87a5.087 5.087 0 110 10.174L23.7 19.09c.64.641.187 1.737-.72 1.737H8.48a8.479 8.479 0 010-16.958h10.175zM8.479 7.26a5.087 5.087 0 100 10.176 5.087 5.087 0 000-10.175z"></path>`,perplexity:`<path d="M19.785 0v7.272H22.5V17.62h-2.935V24l-7.037-6.194v6.145h-1.091v-6.152L4.392 24v-6.465H1.5V7.188h2.884V0l7.053 6.494V.19h1.09v6.49L19.786 0zm-7.257 9.044v7.319l5.946 5.234V14.44l-5.946-5.397zm-1.099-.08l-5.946 5.398v7.235l5.946-5.234V8.965zm8.136 7.58h1.844V8.349H13.46l6.105 5.54v2.655zm-8.982-8.28H2.59v8.195h1.8v-2.576l6.192-5.62zM5.475 2.476v4.71h5.115l-5.115-4.71zm13.219 0l-5.115 4.71h5.115v-4.71z"></path>`,poolside:`<g clip-path="url(#lobe-icons-poolside-0-_R_0_)"><mask height="24" id="lobe-icons-poolside-4-_R_0_" maskUnits="userSpaceOnUse" style="mask-type:alpha" width="24" x="0" y="0"><path d="M24 0H0v24h24V0z" fill="url(#lobe-icons-poolside-1-_R_0_)"></path><path d="M24 0H0v24h24V0z" fill="url(#lobe-icons-poolside-2-_R_0_)"></path><path d="M24 0H0v24h24V0z" fill="url(#lobe-icons-poolside-3-_R_0_)"></path></mask><g mask="url(#lobe-icons-poolside-4-_R_0_)"><path d="M6.742 22.786a11.93 11.93 0 01-5.232-4.963 11.98 11.98 0 01-1.463-6.886.975.975 0 011.943.173c-.178 2.005.246 4 1.226 5.769a9.968 9.968 0 003.526 3.685l4.586-9.405c-1.795-.598-3.29-.338-3.425-.312l-.058.012a.972.972 0 01-1.054-.576c-.24-.448-.96-1.544-1.834-1.97-.873-.426-2.218-.289-2.651-.195a.977.977 0 01-1.087-1.38C4.117.792 11.315-1.686 17.262 1.215c5.946 2.9 8.422 10.093 5.529 16.038l-.01.02c-2.903 5.94-10.095 8.414-16.039 5.514zm6.338-10.773l-4.586 9.405c4.629 1.73 9.896-.192 12.304-4.558-.338-.524-.932-1.275-1.62-1.61-.888-.434-2.19-.292-2.637-.198a.989.989 0 01-.616-.055.984.984 0 01-.49-.473c-.028-.058-.739-1.438-2.355-2.51zM5.81 6.56c.747.365 1.356.944 1.81 1.49 1.406-2.15 3.314-3.774 4.787-4.82a20.81 20.81 0 011.66-1.067A10.078 10.078 0 003.882 6.077c.617.042 1.297.174 1.929.482zm12.671-2.243c.09.624.152 1.294.182 1.965.083 1.801-.021 4.296-.844 6.722.686.018 1.484.14 2.214.495.652.318 1.198.8 1.628 1.28a10.082 10.082 0 00-3.18-10.462zm-5.394 5.46a9.522 9.522 0 012.984 2.287c1.075-3.493.606-7.402.215-8.85-1.381.584-4.75 2.62-6.84 5.618a9.515 9.515 0 013.64.944z"></path></g></g><defs><linearGradient gradientUnits="userSpaceOnUse" id="lobe-icons-poolside-1-_R_0_" x1="6.75" x2="5.625" y1="20.55" y2="20.55"><stop stop-color="currentColor"></stop><stop offset="1" stop-color="currentColor" stop-opacity="0"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="lobe-icons-poolside-2-_R_0_" x1="6.825" x2="7.2" y1="11.85" y2="11.137"><stop stop-color="currentColor" stop-opacity="0"></stop><stop offset="1" stop-color="currentColor"></stop></linearGradient><linearGradient gradientUnits="userSpaceOnUse" id="lobe-icons-poolside-3-_R_0_" x1=".975" x2=".975" y1="20.512" y2="10.912"><stop stop-color="currentColor"></stop><stop offset=".105" stop-color="currentColor" stop-opacity=".9"></stop><stop offset=".904" stop-color="currentColor" stop-opacity=".04"></stop><stop offset="1" stop-color="currentColor" stop-opacity="0"></stop></linearGradient><clipPath id="lobe-icons-poolside-0-_R_0_"><path d="M0 0h24v24H0z" fill="currentColor"></path></clipPath></defs>`,qwen:`<path d="M12.604 1.34c.393.69.784 1.382 1.174 2.075a.18.18 0 00.157.091h5.552c.174 0 .322.11.446.327l1.454 2.57c.19.337.24.478.024.837-.26.43-.513.864-.76 1.3l-.367.658c-.106.196-.223.28-.04.512l2.652 4.637c.172.301.111.494-.043.77-.437.785-.882 1.564-1.335 2.34-.159.272-.352.375-.68.37-.777-.016-1.552-.01-2.327.016a.099.099 0 00-.081.05 575.097 575.097 0 01-2.705 4.74c-.169.293-.38.363-.725.364-.997.003-2.002.004-3.017.002a.537.537 0 01-.465-.271l-1.335-2.323a.09.09 0 00-.083-.049H4.982c-.285.03-.553-.001-.805-.092l-1.603-2.77a.543.543 0 01-.002-.54l1.207-2.12a.198.198 0 000-.197 550.951 550.951 0 01-1.875-3.272l-.79-1.395c-.16-.31-.173-.496.095-.965.465-.813.927-1.625 1.387-2.436.132-.234.304-.334.584-.335a338.3 338.3 0 012.589-.001.124.124 0 00.107-.063l2.806-4.895a.488.488 0 01.422-.246c.524-.001 1.053 0 1.583-.006L11.704 1c.341-.003.724.032.9.34zm-3.432.403a.06.06 0 00-.052.03L6.254 6.788a.157.157 0 01-.135.078H3.253c-.056 0-.07.025-.041.074l5.81 10.156c.025.042.013.062-.034.063l-2.795.015a.218.218 0 00-.2.116l-1.32 2.31c-.044.078-.021.118.068.118l5.716.008c.046 0 .08.02.104.061l1.403 2.454c.046.081.092.082.139 0l5.006-8.76.783-1.382a.055.055 0 01.096 0l1.424 2.53a.122.122 0 00.107.062l2.763-.02a.04.04 0 00.035-.02.041.041 0 000-.04l-2.9-5.086a.108.108 0 010-.113l.293-.507 1.12-1.977c.024-.041.012-.062-.035-.062H9.2c-.059 0-.073-.026-.043-.077l1.434-2.505a.107.107 0 000-.114L9.225 1.774a.06.06 0 00-.053-.031zm6.29 8.02c.046 0 .058.02.034.06l-.832 1.465-2.613 4.585a.056.056 0 01-.05.029.058.058 0 01-.05-.029L8.498 9.841c-.02-.034-.01-.052.028-.054l.216-.012 6.722-.012z"></path>`,relace:`<path d="M23 23H1V1h22v22zM2.962 15.232c1.969.3 5.028.42 7.78-.171.904-.195 1.743-.46 2.49-.803-1.395-3.4-1.675-5.766-1.264-7.378.466-1.823 1.799-2.59 2.998-2.602h.01c.688 0 2.117.177 3.081 1.35 1.003 1.22 1.216 3.152.26 5.991-.504 1.493-1.437 2.616-2.594 3.456 1.323 2.993 2.11 4.498 2.588 5.284.223.367.372.564.467.679h2.26V2.962H2.962v12.27zm11.05.827c-.912.413-1.887.711-2.857.92-2.91.626-6.059.527-8.193.234v3.825h13.471c-.527-.92-1.287-2.424-2.421-4.98zm.97-9.82c-.323.005-.87.181-1.112 1.127-.25.975-.161 2.776 1.055 5.84.705-.598 1.233-1.329 1.531-2.213.868-2.576.455-3.67.086-4.119-.406-.494-1.09-.633-1.56-.634z"></path>`,stability:`<path d="M7.223 21c4.252 0 7.018-2.22 7.018-5.56 0-2.59-1.682-4.236-4.69-4.918l-1.93-.571c-1.694-.375-2.683-.825-2.45-1.975.194-.957.773-1.497 2.122-1.497 4.285 0 5.873 1.497 5.873 1.497v-3.6S11.62 3 7.293 3C3.213 3 1 5.07 1 8.273c0 2.59 1.534 4.097 4.645 4.812l.334.083c.473.144 1.112.335 1.916.572 1.59.375 1.999.773 1.999 1.966 0 1.09-1.15 1.71-2.67 1.71C2.841 17.416 1 15.231 1 15.231v3.989S2.152 21 7.223 21z"></path><path d="M20.374 20.73c1.505 0 2.626-1.073 2.626-2.526 0-1.484-1.089-2.526-2.626-2.526-1.505 0-2.594 1.042-2.594 2.526 0 1.484 1.089 2.526 2.594 2.526z"></path>`,stepfun:`<path d="M12 0C5.372 0 0 5.372 0 12s5.372 12 12 12 12-5.372 12-12S18.628 0 12 0zM8.762 19.614H4.376v-4.386h4.386v4.386zm5.423 0H9.798v-4.386h4.387v4.386zm0-5.42H9.798V9.81h4.387v4.386zm0-5.418H9.798V4.39h4.387v4.386zm5.422-.004h-4.386V4.386h4.386v4.386z"></path>`,tencent:`<path d="M9.976 1L24 9.8l-10.587.015L10.723 23H5.489L8.18 9.8H3.244L1 5.4h8.077L9.976 1z"></path>`,upstage:`<path d="M19.763 0l-.373 1.297h2.594L22.354 0h-2.591z"></path><path d="M16.192 2.27l-.376 1.298h5.52l.37-1.298h-5.514z"></path><path d="M12.897 4.54l-.377 1.298h8.167l.37-1.297h-8.16z"></path><path d="M2.85 6.81l-.377 1.298h17.565l.37-1.297H2.85z"></path><path d="M3.884 9.081l-.376 1.297H19.39l.37-1.297H3.883z"></path><path d="M4.088 24l.376-1.297H1.866L1.5 24h2.588z"></path><path d="M7.662 21.73l.376-1.298H2.515L2.15 21.73h5.513z"></path><path d="M10.957 19.46l.377-1.298h-8.17l-.367 1.297h8.16z"></path><path d="M21.005 17.19l.376-1.298H3.812l-.366 1.297h17.559z"></path><path d="M19.967 14.919l.376-1.297H4.461l-.366 1.297h15.872z"></path><path d="M18.787 12.649l.376-1.298H4.26l-.366 1.298h14.893z"></path>`,xai:`<path d="M6.469 8.776L16.512 23h-4.464L2.005 8.776H6.47zm-.004 7.9l2.233 3.164L6.467 23H2l4.465-6.324zM22 2.582V23h-3.659V7.764L22 2.582zM22 1l-9.952 14.095-2.233-3.163L17.533 1H22z"></path>`,xiaomimimo:`<path d="M.958 15.936a.459.459 0 01.459.44v2.729a.46.46 0 01-.918 0v-2.729a.459.459 0 01.459-.44zm4.814-2.035a.46.46 0 01.553.45v4.754a.458.458 0 11-.918 0V15.48L3.74 17.202a.462.462 0 01-.655.016.462.462 0 01-.065-.082L.628 14.67a.459.459 0 01.658-.637l2.124 2.187 2.127-2.188a.46.46 0 01.235-.13zm2.068.004a.46.46 0 01.458.445v4.755a.46.46 0 01-.458.458.459.459 0 01-.458-.458V14.35a.459.459 0 01.458-.445zm1.973 2.014a.46.46 0 01.46.457v2.729a.46.46 0 01-.784.324.46.46 0 01-.134-.324v-2.729a.46.46 0 01.458-.458zm.002-2.045a.458.458 0 01.328.157l2.127 2.19 2.125-2.19a.459.459 0 01.784.318v4.756a.46.46 0 01-.455.458.46.46 0 01-.458-.458V15.48l-1.667 1.723a.46.46 0 01-.65.008l-.005-.005c0-.002-.002-.002-.004-.003l-2.455-2.534a.46.46 0 01-.008-.667.461.461 0 01.338-.128zm6.797 1.206a.46.46 0 01.53.651A1.966 1.966 0 0019.81 18.4a.462.462 0 01.623.18.46.46 0 01-.181.624 2.863 2.863 0 01-1.38.353l-.142-.004a2.88 2.88 0 01-2.393-4.263.461.461 0 01.274-.21zm.864-.931a2.884 2.884 0 013.915 3.914.46.46 0 01-.402.24l-.057-.004a.458.458 0 01-.164-.055.46.46 0 01-.182-.622 1.967 1.967 0 00-2.669-2.67.459.459 0 11-.441-.803zM9.59 6.368c1.481 0 1.696 1.202 1.696 1.654v2.648h-.917v-.432c-.26.346-.792.535-1.36.535-.133 0-1.289-.03-1.384-1.136-.082-.932.675-1.61 2.053-1.61h.691c0-.563-.367-.886-.983-.886-.44.013-.864.174-1.2.458l-.36-.664c.484-.379 1.012-.567 1.764-.567zm4.427.1c1.263 0 2.082.97 2.083 2.15 0 1.181-.824 2.154-2.083 2.154-1.26 0-2.084-.972-2.084-2.152 0-1.18.82-2.153 2.084-2.153zm6.801.015c.68 0 1.202.465 1.197 1.548v2.642H21.1V8.29c0-.312-.002-.98-.63-.98s-.628.667-.628.838v2.524h-.89V8.148c0-.17-.001-.838-.63-.838-.628 0-.628.668-.628.98v2.383h-.917v-4.03h.917V7a1.22 1.22 0 01.947-.516c.398 0 .76.193.982.686a1.321 1.321 0 011.195-.686zm-18.093.872l1.457-1.772H5.32L3.311 8.07l2.14 2.602H4.24L2.725 8.796 1.21 10.672H0L2.138 8.07.13 5.583h1.138l1.458 1.772zm4.149 3.317h-.916V6.644h.916v4.028zm16.99 0h-.916V6.644h.916v4.028zM9.925 8.71c-1.055 0-1.359.412-1.326.742.032.329.324.537.757.537a1.013 1.013 0 001.014-.968l.002-.31h-.447zM14.018 7.3c-.663 0-1.184.487-1.184 1.32 0 .832.52 1.32 1.184 1.32.662 0 1.182-.49 1.182-1.32 0-.832-.52-1.32-1.182-1.32zM6.417 5.001a.568.568 0 01.587.582.588.588 0 01-1.175 0A.57.57 0 016.417 5zm16.991 0a.57.57 0 01.592.582.588.588 0 01-1.174 0 .57.57 0 01.357-.542.572.572 0 01.225-.04z"></path>`,zai:`<path d="M12.105 2L9.927 4.953H.653L2.83 2h9.276zM23.254 19.048L21.078 22h-9.242l2.174-2.952h9.244zM24 2L9.264 22H0L14.736 2H24z"></path>`,zoo:`<defs><clipPath id="zoo-cut"><circle cx="12" cy="12" r="12"></circle></clipPath></defs><g clip-path="url(#zoo-cut)" fill="none" stroke="currentColor"><circle cx="12.203" cy="6.27" r="9.509" stroke-width="2.4" stroke="#00A652"></circle><circle cx="6.189" cy="15.454" r="9.509" stroke-width="2.4" stroke="#ED1C24"></circle><circle cx="17.486" cy="15.454" r="9.509" stroke-width="2.4" stroke="#2E3192"></circle><circle cx="12" cy="12" r="10.8" stroke-width="2.4"></circle></g>`,adroll:`<path d="${G4.path}"></path>`,chrome:`<path d="${n3.path}"></path>`,cloudflare:`<path d="${K4.path}"></path>`,discord:`<path d="${q4.path}"></path>`,facebook:`<path d="${Y4.path}"></path>`,github:`<path d="${Z4.path}"></path>`,gitlab:`<path d="${Q4.path}"></path>`,google_ads:`<path d="${e3.path}"></path>`,instagram:`<path d="${o3.path}"></path>`,meta_ads:`<path d="${l3.path}"></path>`,pinterest:`<path d="${d3.path}"></path>`,reddit:`<path d="${p3.path}"></path>`,reddit_ads:`<path d="${p3.path}"></path>`,telegram:`<path d="${v3.path}"></path>`,threads:`<path d="${y3.path}"></path>`,tiktok:`<path d="${b3.path}"></path>`,tiktok_ads:`<path d="${b3.path}"></path>`,twitch:`<path d="${x3.path}"></path>`,warpcast:`<path d="${X4.path}"></path>`,whatsapp:`<path d="${S3.path}"></path>`,x:`<path d="${C3.path}"></path>`,youtube:`<path d="${w3.path}"></path>`},D3={"aion-labs":`aionlabs`,allenai:`ai2`,amazon:`aws`,"arcee-ai":`arcee`,bge:`baai`,"bytedance-seed":`bytedance`,e:`microsoft`,glm:`zai`,gpt:`openai`,gte:`alibaba`,"ibm-granite":`ibm`,llama:`meta`,meituan:`longcat`,"meta-llama":`meta`,mimo:`xiaomimimo`,mistralai:`mistral`,moonshotai:`moonshot`,nemotron:`nvidia`,o:`openai`,rerank:`baai`,stable:`stability`,trinity:`arcee`,wan:`alibaba`,"x-ai":`xai`,xiaomi:`xiaomimimo`,"z-ai":`zai`,zen:`zoo`},O3=/ stroke="#[0-9A-Fa-f]{6}"/g,k3=e=>e?E3[e]?e:E3[D3[e]??``]?D3[e]:void 0:void 0,A3={alibaba:`#FF6A00`,aws:`#FF9900`,baidu:`#2932E1`,claude:`#C37E4E`,deepseek:`#4D6BFE`,gemma:`#4285F4`,google:`#4285F4`,ibm:`#0F62FE`,meta:`#0064E0`,minimax:`#F23F5D`,mistral:`#FA520F`,nvidia:`#76B900`,perplexity:`#20808D`,qwen:`#615CED`,tencent:`#0052D9`,xiaomimimo:`#EF6200`,zai:`#3859FF`,adroll:`#`+G4.hex,chrome:`#`+n3.hex,cloudflare:`#`+K4.hex,discord:`#`+q4.hex,facebook:`#`+Y4.hex,github:`#`+Z4.hex,gitlab:`#`+Q4.hex,google_ads:`#`+e3.hex,instagram:`#`+o3.hex,meta_ads:`#`+l3.hex,pinterest:`#`+d3.hex,reddit:`#`+p3.hex,reddit_ads:`#`+p3.hex,telegram:`#`+v3.hex,threads:`#`+y3.hex,tiktok:`#`+b3.hex,tiktok_ads:`#`+b3.hex,twitch:`#`+x3.hex,warpcast:`#`+X4.hex,whatsapp:`#`+S3.hex,x:`#`+C3.hex,youtube:`#`+w3.hex};function j3(e,t){return k3((t?z4(t).slug.toLowerCase().match(/^[a-z]+/)?.[0]:void 0)??``)??k3(e.replace(/^~/,``).toLowerCase())}function M3({org:e,provider:t,model:n,size:r=32,ink:i}){let a=j3(e||t||`enso`,n);return a?(0,H.jsx)(w,{render:`span`,children:(0,H.jsx)(`svg`,{"aria-hidden":!0,focusable:`false`,width:r,height:r,viewBox:`0 0 24 24`,fill:`currentColor`,fillRule:`evenodd`,color:i?void 0:A3[a],dangerouslySetInnerHTML:{__html:i?E3[a].replace(O3,``):E3[a]}})}):(0,H.jsx)(U,{"aria-hidden":!0,display:`flex`,shrink:0,items:`center`,justify:`center`,width:r,height:r,rounded:`var(--radius-lg)`,bg:`var(--secondary)`,fontSize:r*.44,fontWeight:`700`,textTransform:`uppercase`,color:`var(--muted-foreground)`,children:(V4(e)||`Hanzo`).replace(/^~/,``).charAt(0)})}function N3(e){let t=e?.body;if(t&&typeof t==`object`){let e=t;for(let t of[`detail`,`message`,`msg`,`error`,`title`]){let n=e[t];if(typeof n==`string`&&n.trim())return n.trim();if(t===`error`&&n&&typeof n==`object`){let e=n.message;if(typeof e==`string`&&e.trim())return e.trim()}}}}var P3=e=>{let t=e?.status;return typeof t==`number`&&Number.isFinite(t)?t:null},F3=e=>/no instance running|not running|service unavailable|503|econnrefused|failed to fetch|network/i.test(e),I3=e=>/401|403|forbidden|unauthori[sz]ed|not authori[sz]ed|authentication required|validated principal|permission|serve anonymous|anonymous completions/i.test(e);function L3(e,t,n=`read`,r=ne){let i=e instanceof Error?e.message:String(e??``),a=P3(e);return a===502||a===503||a===504||F3(i)?r(`Could not reach {subject}. Nothing has been lost — try again shortly.`,{subject:t}):a===401||a===403||I3(i)?r(n===`save`?`This account cannot change {subject}.`:`This account cannot open {subject}.`,{subject:t}):r(n===`save`?`Could not save {subject}.`:`Could not read {subject}.`,{subject:t})}function R3(e,t,n=ne){let r=e instanceof Error?e.message:String(e??``);return F3(r)||I3(r)?L3(e,t,`read`,n):N3(e)??r}function z3(e){let t=P3(e);return t!==402&&t!==429?null:b2(e?.body,t)}function B3(e){if(typeof e==`string`)try{let t=new URL(e),n=t.hostname;return t.protocol===`https:`&&(n===`hanzo.ai`||n.endsWith(`.hanzo.ai`))?t.toString():void 0}catch{return}}var V3=`signin.destination`,H3=new Set([`/login`,`/signup`,`/auth/callback`]);function U3(){try{let{pathname:e,search:t,hash:n}=window.location;window.sessionStorage.setItem(V3,e+t+n)}catch{}}var W3=`/login`,G3=()=>vW().signUp,K3=`hz_known`;function q3(){try{return window.localStorage.getItem(K3)===`1`?W3:G3()}catch{return G3()}}function J3(e=q3()){let{pathname:t,search:n,hash:r}=window.location,i=`${t}${n}${r}`;Z3(i)||(U3(),window.location.assign(X3(e,i)))}var Y3=[`utm_source`,`utm_medium`,`utm_campaign`,`utm_term`,`utm_content`,`gclid`,`gbraid`,`wbraid`,`fbclid`,`li_fat_id`,`twclid`,`ttclid`];function X3(e,t){let[n,r=``]=e.split(`?`),i=new URLSearchParams(r),a=Q3(t,``);a&&a!==`/`&&i.set(`next`,a);let o=new URLSearchParams(t.split(`#`)[0].split(`?`)[1]??``);for(let e of Y3){let t=o.get(e)?.trim();t&&!i.has(e)&&i.set(e,t)}let s=i.toString();return s?`${n}?${s}`:n}function Z3(e){if(typeof window>`u`)return!1;let t=window.location.hostname,n=new URLSearchParams(e.split(`#`)[0].split(`?`)[1]??``).has(`client_id`);return!sG(t)&&(!aG(t)||n)?!1:(window.location.assign(oG+e),!0)}function Q3(e,t=`/`){if(!e||!e.startsWith(`/`)||e.startsWith(`//`)||e.startsWith(`/\\`))return t;let n;try{n=new URL(e,$3)}catch{return t}if(n.origin!==$3)return t;let r=n.pathname.replace(/\/+$/,``)||`/`;return H3.has(r)?t:e}var $3=`https://hanzo.invalid`,e6=(e,t,n)=>{let r=tC();return e===void 0?t===void 0?n:r!==`a`&&t6(t)?(0,V.createElement)(r,{href:t}):`a`:e},t6=e=>e.startsWith(`/`)&&!e.startsWith(`//`)&&!/\.[a-z][a-z0-9]{1,4}$/i.test(e.split(/[?#]/)[0]),n6={display:`inline-flex`,items:`center`,whiteSpace:`inherit`,textDecorationLine:`none`},r6={fontSize:`$2`,lineHeight:`calc(1.25 / 0.875)`},i6=(e,t,n)=>{let r=t=>Object.fromEntries(Object.entries(t).filter(([t])=>!(t in e))),{hoverStyle:i,...a}=n;return{...e.hoverStyle===void 0?{hoverStyle:r(t)}:null,...e[`$theme-light`]===void 0?{"$theme-light":{...r(a),...i&&e.hoverStyle===void 0?{hoverStyle:r(i)}:null}}:null}},a6=({render:e,fill:t=!1,...n})=>{let r=e6(e,n.href,`a`);return(0,H.jsx)(U,{...B(`action`),...t?{"data-fill":``}:null,render:r,...n6,...r6,justify:`center`,gap:`$2`,minH:44,px:`$5`,rounded:9999,fontWeight:`500`,backdropFilter:`var(--chrome-blur)`,...t?{borderWidth:0,bg:`var(--pure-white)`,color:`var(--pure-black)`,boxShadow:`0 4px 20px -2px var(--white-22), 0 2px 8px 0 color-mix(in srgb, var(--pure-black) 40%, transparent)`,...i6(n,{opacity:.92,bg:`var(--neutral-100)`,color:`var(--pure-black)`},{bg:`var(--foreground)`,color:`var(--background)`,boxShadow:`0 4px 16px -6px color-mix(in srgb, var(--pure-black) 40%, transparent)`,hoverStyle:{bg:`var(--foreground)`,color:`var(--background)`}})}:{borderWidth:1,borderStyle:`solid`,borderColor:`var(--white-14)`,bg:`color-mix(in srgb, var(--neutral-900) 65%, transparent)`,color:`var(--foreground)`,boxShadow:`inset 0 1px 0 0 var(--white-14), 0 4px 16px -2px color-mix(in srgb, var(--pure-black) 30%, transparent)`,...i6(n,{bg:`color-mix(in srgb, var(--neutral-800) 80%, transparent)`,borderColor:`var(--white-22)`,color:`var(--pure-white)`},{borderColor:`color-mix(in srgb, var(--pure-black) 14%, transparent)`,bg:`color-mix(in srgb, var(--pure-white) 72%, transparent)`,color:`var(--foreground)`,boxShadow:`0 2px 10px -4px color-mix(in srgb, var(--pure-black) 18%, transparent)`,hoverStyle:{borderColor:`color-mix(in srgb, var(--pure-black) 26%, transparent)`,bg:`var(--pure-white)`,color:`var(--foreground)`}})},...n})},o6=(e,t)=>`color-mix(in srgb, ${e} ${t}%, var(--foreground))`,s6=o6(`var(--state-success)`,55);o6(`var(--destructive)`,70),D(`Works with`),D(`Channels`);var c6=`/v1/provider`,l6=(e,t)=>e.connected?e.account||t(`Connected`):e.available?e.publisher:t(`Needs app credentials`),u6=[`tiktok`,`instagram`,`linkedin`,`slack`,`x`,`whatsapp`,`discord`,`telegram`,`facebook`,`teams`,`threads`,`youtube`],d6=null,f6=()=>d6??=Le(async()=>{let{INTEGRATIONS:e}=await import(`./integrations-DW-vmr60.js`);return{INTEGRATIONS:e}},[]).then(({INTEGRATIONS:e})=>e.map(e=>({id:e.slug,name:e.name,publisher:e.creator,description:e.description.split(`. `)[0]+`.`,kind:`native`}))).catch(()=>[]),p6=e=>e.charAt(0).toUpperCase()+e.slice(1);function m6(e){let t=e??{},n=e=>{let t=u6.indexOf(e);return t<0?u6.length:t};return(t.providers??[]).map(e=>{let t=e.connection??{},n=String(t.account??t.label??``);return{id:String(e.id),name:String(e.name??p6(String(e.id))),publisher:String(e.category??``),description:String(e.description??``),kind:`native`,connected:!!e.connected,available:!!e.available,account:n}}).sort((e,t)=>n(e.id)-n(t.id))}var h6=e=>Object.assign(Error(String(e.status)),{status:e.status});function g6({tab:e}){let{t}=R(),{isAuthenticated:n,accessToken:r}=dW(),[i,a]=(0,V.useState)(``),[o,s]=(0,V.useState)(null),[c,l]=(0,V.useState)(null),[u,d]=(0,V.useState)(0),f=t(e===`channels`?`Search channels`:`Search works with`),p=n&&!!r;(0,V.useEffect)(()=>{let t=!0;s(null),l(null);let n=p?DG():null;if(e===`apps`)return f6().then(e=>{t&&s(e)}),n&&Promise.all([f6(),fetch(`${fG()}/v1/connection`,{headers:n}).then(e=>e.ok?e.json():null)]).then(([e,n])=>{if(!t||!n?.connectors)return;let r=new Set(n.connectors.map(e=>String(e.provider)));s(e.map(e=>r.has(e.id)?{...e,connected:!0}:e))}).catch(()=>{}),()=>{t=!1};if(n)return fetch(`${fG()}${c6}`,{headers:n}).then(e=>{if(!e.ok)throw h6(e);return e.json()}).then(e=>t&&s(m6(e))).catch(e=>t&&l(e)),()=>{t=!1}},[e,p,u]),(0,V.useEffect)(()=>{if(e!==`channels`)return;let t=()=>{document.visibilityState===`visible`&&d(e=>e+1)};return document.addEventListener(`visibilitychange`,t),()=>document.removeEventListener(`visibilitychange`,t)},[e]);let m=(0,V.useMemo)(()=>{let e=i.trim().toLowerCase();return(o??[]).filter(t=>!e||t.name.toLowerCase().includes(e)||t.description.toLowerCase().includes(e))},[o,i]),h=(e,t)=>(0,H.jsxs)(z,{gap:`$3`,py:`$4`,items:`flex-start`,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e}),t]});return(0,H.jsxs)(z,{gap:`$4`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$2`,flexWrap:`wrap`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,flex:1,minW:180,children:[(0,H.jsx)(uK,{size:14,"aria-hidden":!0}),(0,H.jsx)(j_,{value:i,onChangeText:a,placeholder:f,"aria-label":f,flex:1})]}),(0,H.jsx)(a6,{render:`button`,onPress:()=>window.open(`https://hanzo.market`,`_blank`,`noopener,noreferrer`),$touchable:{minH:36},children:(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(QG,{size:14,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,children:t(`Explore on hanzo.market`)}),(0,H.jsx)(JG,{size:13,"aria-hidden":!0})]})})]}),e===`channels`&&!p?h(t(`Sign in to see the channels your organization can connect.`),(0,H.jsx)(a6,{render:`button`,onPress:()=>J3(),$touchable:{minH:44,minW:44},children:t(`Sign in`)})):c?h(L3(c,t(`the channels`),`read`,t),(0,H.jsx)(a6,{render:`button`,onPress:()=>d(e=>e+1),$touchable:{minH:44,minW:44},children:t(`Try again`)})):o===null?h(t(e===`channels`?`Loading channels…`:`Loading works with…`)):m.length>0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:m.length===1?t(`1 result`):t(`{n} results`,{n:m.length})}),(0,H.jsx)(z,{maxH:380,overflowY:`auto`,overflowX:`hidden`,paddingInlineEnd:`$1`,width:`100%`,children:(0,H.jsx)(_C,{columns:e===`channels`?{min:168,max:4}:{min:240,max:2},gap:12,children:m.map(t=>e===`channels`?(0,H.jsx)(v6,{row:t,onChange:()=>d(e=>e+1)},t.id):(0,H.jsx)(_6,{row:t,tab:e},t.id))})})]}):h(i?t(`Nothing matches “{query}”.`,{query:i}):t(e===`channels`?`No channel can be connected here yet.`:`Nothing is listed yet.`))]})}function _6({row:e,tab:t}){let{t:n}=R(),r=bW(`/integrations/${e.id}`);return(0,H.jsxs)(z,{gap:`$2`,p:`$3`,borderWidth:1,borderColor:`$borderColor`,rounded:`$3`,height:`100%`,bg:`$raised`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(M3,{org:e.id.replace(/-sdk$/,``),size:20}),(0,H.jsxs)(z,{flex:1,minW:0,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`500`,color:`$ink`,numberOfLines:1,children:e.name}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,numberOfLines:1,children:e.publisher})]}),e.connected?(0,H.jsxs)(y,{items:`center`,gap:`$1`,px:`$2`,py:`$1`,rounded:`$2`,bg:`$hover`,children:[(0,H.jsx)(XG,{size:12,color:s6,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$1`,color:s6,fontWeight:`600`,children:n(`Connected`)})]}):(0,H.jsx)($S,{render:(0,H.jsx)(`a`,{href:r,target:t===`apps`?void 0:`_blank`,rel:`noreferrer`,"aria-label":n(`Open {name}`,{name:e.name})}),...Vq,children:(0,H.jsxs)(y,{items:`center`,gap:`$1`,px:`$2`,py:`$1`,rounded:`$2`,borderWidth:1,borderColor:`$borderColor`,bg:`var(--white-05)`,hoverStyle:{bg:`$hover`},children:[(0,H.jsx)(U,{fontSize:`$1`,color:`$color`,fontWeight:`600`,children:n(t===`apps`?`Docs`:`Install`)}),(0,H.jsx)(JG,{size:11,"aria-hidden":!0})]})})]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,numberOfLines:2,flex:1,children:e.description}),(0,H.jsx)(y,{items:`center`,pt:`$1`,children:(0,H.jsx)(U,{fontFamily:`$mono`,fontVariant:[`tabular-nums`],fontSize:`$1`,color:`$soft`,children:e.kind===`MCP`?`MCP`:n(`native`)})})]})}function v6({row:e,onChange:t}){let{t:n}=R(),{isAuthenticated:r,accessToken:i}=dW(),[a,o]=(0,V.useState)(!1),[s,c]=(0,V.useState)(null),l=async n=>{if(!r||!i){J3();return}o(!0),c(null);try{let r=await fetch(`${fG()}/v1/provider/${encodeURIComponent(e.id)}/${n}`,{method:`POST`,headers:{...DG(),"Content-Type":`application/json`},body:`{}`});if(!r.ok)throw h6(r);let i=await r.json();i.authorizeUrl&&window.open(i.authorizeUrl,`_blank`,`noopener,noreferrer`),t()}catch(e){c(e)}finally{o(!1)}},u=(e,t,n,r)=>(0,H.jsxs)($S,{render:`button`,onClick:()=>void l(n),"aria-label":t,"aria-disabled":a,px:`$3`,py:`$1.5`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,hoverStyle:{bg:`$hover`},opacity:a?.5:1,display:`flex`,items:`center`,gap:`$1`,children:[r,(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,fontWeight:`500`,children:e})]});return(0,H.jsxs)(z,{items:`center`,gap:`$2`,p:`$4`,borderWidth:1,borderColor:`$borderColor`,rounded:`$4`,bg:`$raised`,children:[e.connected?(0,H.jsxs)(y,{self:`flex-start`,items:`center`,gap:`$1`,"aria-label":n(`Connected`),children:[(0,H.jsx)($S,{width:6,height:6,rounded:3,bg:`$ink`}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:n(`Connected`)})]}):null,(0,H.jsxs)(z,{items:`center`,gap:`$2`,pt:e.connected?0:`$3`,children:[(0,H.jsx)(M3,{org:e.id,size:40}),(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`500`,color:`$ink`,text:`center`,numberOfLines:1,children:e.name}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,text:`center`,numberOfLines:1,children:l6(e,n)})]}),(0,H.jsx)(y,{gap:`$1.5`,items:`center`,justify:`center`,flexWrap:`wrap`,children:e.connected?(0,H.jsxs)(H.Fragment,{children:[u(n(`Disconnect`),n(`Disconnect {name}`,{name:e.name}),`disconnect`),e.available?u(n(`Add`),n(`Add {name}`,{name:e.name}),`connect`,(0,H.jsx)(cK,{size:12,"aria-hidden":!0})):null]}):e.available?u(n(`Connect`),n(`Connect {name}`,{name:e.name}),`connect`):null}),s?(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,text:`center`,children:L3(s,e.name,`read`,n)}):null]})}var y6=`https://hanzo.ai/pay`,b6=`https://app-dev.hanzo.ai/pay`;function x6(){return typeof window<`u`&&lG(window.location.hostname)?b6:y6}function S6(e=`/`){return C6(e,{org:EG()})}function C6(e,t){let n=new URLSearchParams;for(let[e,r]of Object.entries(t))r&&n.set(e,r);let r=n.toString(),i=x6();return e===`/`&&!r?i:`${i}${e}${r?`?${r}`:``}`}var w6=e=>`$${e.toFixed(2)}`,T6=(e,t=`en-US`)=>t===`en-US`?Number.isInteger(e)?`$${e.toLocaleString(`en-US`)}`:w6(e):new Intl.NumberFormat(t,{style:`currency`,currency:`USD`,minimumFractionDigits:Number.isInteger(e)?0:2,maximumFractionDigits:Number.isInteger(e)?0:2}).format(e);function E6(e){return Array.isArray(e)?e:[]}function D6(e,t=`en-US`){let n=e?Date.parse(e):NaN;return Number.isNaN(n)?``:new Date(n).toLocaleDateString(t,{timeZone:`UTC`,year:`numeric`,month:`short`,day:`numeric`})}var O6=(e,t)=>Object.assign(Error(t),{status:e});async function k6(e,t){let n=await fetch(`${fG()}${e}`,{headers:DG(),signal:t});if(!n.ok){let e=``;try{e=(await n.json()).detail??``}catch{}throw O6(n.status,e||`Billing answered ${n.status}`)}return await n.json()}async function A6(e){if(!_G())throw O6(401,`Sign in to see your plan`);let[t,n]=await Promise.all([k6(`/v1/billing/tier`,e),k6(`/v1/billing/balance`,e)]);return t.balance={...t.balance,effectiveAvailable:n.available,account:n.account},t}var j6=new Set([`active`,`trialing`]);async function M6(e){return E6((await k6(`/v1/billing/subscriptions`,e))?.subscriptions).find(e=>j6.has(e?.status)&&typeof e?.plan?.price==`number`)??null}function N6(e,t=ne,n=`en-US`){let r=T6(e.plan.price*Math.max(1,e.quantity||1)/100,n),i=D6(e.currentPeriodEnd,n),a=e.plan.interval||`month`,o=a===`month`?t(`{price}/month`,{price:r}):a===`year`?t(`{price}/year`,{price:r}):`${r}/${a}`;return i?e.cancelAtPeriodEnd?t(`{price} subscription, ends {date}`,{price:o,date:i}):t(`{price} subscription, renews {date}`,{price:o,date:i}):t(`{price} subscription`,{price:o})}function P6(e=!0,t=null){let[n,r]=(0,V.useState)(null);return(0,V.useEffect)(()=>{if(!e)return;let t=new AbortController;return M6(t.signal).then(e=>{t.signal.aborted||r(e)}).catch(()=>{t.signal.aborted||r(null)}),()=>t.abort()},[e,t]),n}function F6(e){let t=e?.status;return typeof t!=`number`||t===408||t===429||t>=500}function I6(e,t,n){if(`tier`in n)return{tier:n.tier,wrong:null,last:{org:t,tier:n.tier}};let r=e&&e.org===t?e:null;return F6(n.wrong)&&r?{tier:r.tier,wrong:null,last:r}:{tier:null,wrong:n.wrong,last:F6(n.wrong)?e:null}}function L6(e,t){return e&&e.org===t?{tier:e.tier,wrong:e.wrong}:{tier:null,wrong:null}}function R6(e=!0,t=null){let[n,r]=(0,V.useState)(null),[i,a]=(0,V.useState)(0),o=(0,V.useRef)(null);return(0,V.useEffect)(()=>{if(!e)return;let n=new AbortController;r(e=>e&&e.org===t?{...e,wrong:null}:e);let i=e=>{if(n.signal.aborted)return;let i=I6(o.current,t,e);o.current=i.last,r({org:t,tier:i.tier,wrong:i.wrong})};return A6(n.signal).then(e=>i({tier:e}),e=>i({wrong:e})),()=>n.abort()},[e,i,t]),{...L6(n,t),reload:(0,V.useCallback)(()=>a(e=>e+1),[])}}async function z6(e){let t=await fetch(`${fG()}/v1/ai/limits`,{headers:DG(),signal:e});if(!t.ok)throw Object.assign(Error(`Limits answered ${t.status}`),{status:t.status});return t.json()}var B6=(e=!0,t=null,n)=>z2(e?z6:null,t,n),V6=({limits:e,answered:t})=>t&&!c2(e),H6={thread:null,session:null,channel:null,bucket:null,emptied:0,settings:null,agents:[],aside:null},U6=H6;if(typeof window<`u`)try{let e=new URLSearchParams(window.location.search),t=e.get(`thread`),n=e.get(`session`),r=e.get(`agent`),i=e.get(`aside`);(t||n||r||i)&&(U6={...H6,thread:t??H6.thread,session:n??H6.session,agents:r?r.split(`,`).map(e=>e.trim()).filter(Boolean):H6.agents,aside:i??H6.aside})}catch{}var W6=new Set;function G6(e){if(e.thread!==U6.thread||e.session!==U6.session||e.channel!==U6.channel||e.bucket!==U6.bucket||e.emptied!==U6.emptied||e.settings!==U6.settings||e.agents.join(`
|
|
177
|
+
`)!==U6.agents.join(`
|
|
178
|
+
`)||e.aside!==U6.aside){U6=e;for(let e of W6)e()}}function K6(e){G6({...U6,settings:e})}var q6={ios:{id:`ios`,name:`Apple iOS`,fontFamily:`-apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", sans-serif`,fontMono:`"SF Mono", ui-monospace, Menlo, monospace`,radiusCard:22,radiusPill:9999,glassBlur:24,glassSaturate:190,specularBorder:!0,touchFeedback:`spring`},android:{id:`android`,name:`Google Android`,fontFamily:`Roboto, "Google Sans", system-ui, sans-serif`,fontMono:`"Roboto Mono", monospace`,radiusCard:16,radiusPill:16,glassBlur:16,glassSaturate:130,specularBorder:!1,touchFeedback:`ripple`},macos:{id:`macos`,name:`Apple macOS`,fontFamily:`-apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif`,fontMono:`"SF Mono", Menlo, monospace`,radiusCard:12,radiusPill:9999,glassBlur:20,glassSaturate:160,specularBorder:!0,touchFeedback:`subtle`},windows:{id:`windows`,name:`Microsoft Windows`,fontFamily:`"Segoe UI Variable", "Segoe UI", system-ui, sans-serif`,fontMono:`"Cascadia Code", Consolas, monospace`,radiusCard:8,radiusPill:9999,glassBlur:18,glassSaturate:125,specularBorder:!1,touchFeedback:`subtle`},linux:{id:`linux`,name:`Linux / Desktop`,fontFamily:`system-ui, -apple-system, "Cantarell", sans-serif`,fontMono:`"Ubuntu Mono", monospace`,radiusCard:10,radiusPill:9999,glassBlur:14,glassSaturate:110,specularBorder:!1,touchFeedback:`subtle`}},J6=`hanzo.mod.platform`;function Y6(e){let t=(e??(typeof navigator<`u`?navigator.userAgent:``)).toLowerCase();return/iphone|ipad|ipod/.test(t)||typeof navigator<`u`&&navigator.platform===`MacIntel`&&navigator.maxTouchPoints>1?`ios`:/android/.test(t)?`android`:/macintosh|mac os x/.test(t)?`macos`:/windows|win32|win64/.test(t)?`windows`:/linux|x11/.test(t)?`linux`:`ios`}var X6=[`--platform-font-sans`,`--platform-font-mono`,`--platform-radius-card`,`--platform-radius-pill`,`--glass-blur`,`--glass-saturate`,`--font-sans`,`--font-display`,`--font-mono`,`--pane-round`,`--radius-scale`,`--chrome-blur`,`--pane-blur`];function Z6(){if(typeof document>`u`)return;let e=document.documentElement;for(let t of X6)e.style.removeProperty(t)}function Q6(e){if(!(typeof window>`u`)){try{e===`auto`?window.localStorage.removeItem(J6):window.localStorage.setItem(J6,e)}catch{}e===`auto`?(Z6(),typeof document<`u`&&document.documentElement.setAttribute(`data-platform`,Y6())):$6(e),window.dispatchEvent(new CustomEvent(`hanzo:mod:change`,{detail:{platform:e}}))}}function $6(e){if(typeof document>`u`)return;let t=q6[e]??q6.ios,n=document.documentElement,r=typeof t.radiusCard==`number`?`${t.radiusCard}px`:t.radiusCard,i=typeof t.radiusPill==`number`?`${t.radiusPill}px`:t.radiusPill,a=typeof t.radiusCard==`number`?String(Math.round(t.radiusCard/12*100)/100):`1`;n.setAttribute(`data-platform`,t.id),n.style.setProperty(`--platform-font-sans`,t.fontFamily),n.style.setProperty(`--platform-font-mono`,t.fontMono),n.style.setProperty(`--platform-radius-card`,r),n.style.setProperty(`--platform-radius-pill`,i),n.style.setProperty(`--glass-blur`,`${t.glassBlur}px`),n.style.setProperty(`--glass-saturate`,`${t.glassSaturate}%`),n.style.setProperty(`--font-sans`,`var(--font-arabic), ${t.fontFamily}`),n.style.setProperty(`--font-display`,`var(--font-arabic), ${t.fontFamily}`),n.style.setProperty(`--font-mono`,`var(--font-arabic), ${t.fontMono}`),n.style.setProperty(`--pane-round`,r),n.style.setProperty(`--radius-scale`,a),n.style.setProperty(`--chrome-blur`,`${t.glassBlur}px`),n.style.setProperty(`--pane-blur`,`${Math.round(t.glassBlur*1.5)}px`)}var e8=[{id:`ios-liquid`,name:`Apple iOS Liquid`,description:`Continuous squircles, high-specular liquid glass, and Apple SF Pro typography.`,author:`Hanzo Design`,platform:`ios`,theme:`dark`,background:`#000000`,glassBlur:24,radius:22,density:`comfortable`},{id:`android-material`,name:`Android Material 3`,description:`Google Material 3 tonal elevations, Roboto Sans, and smooth dynamic rounded cards.`,author:`Hanzo Design`,platform:`android`,theme:`dark`,background:`#0b0e14`,glassBlur:16,radius:16,density:`default`},{id:`macos-vibrant`,name:`macOS Vibrant`,description:`Translucent sidebars, vibrant visual effect filters, and clean desktop density.`,author:`Hanzo Design`,platform:`macos`,theme:`dark`,background:`#09090b`,glassBlur:20,radius:12,density:`compact`},{id:`windows-fluent`,name:`Windows Mica Fluent`,description:`Microsoft Fluent Design Mica acrylic and Segoe UI Variable geometry.`,author:`Hanzo Design`,platform:`windows`,theme:`dark`,background:`#0a0d12`,glassBlur:18,radius:8,density:`default`},{id:`cyber-zen`,name:`Cyber Zen (OLED)`,description:`High contrast deep OLED black with electric cyan and magenta accents.`,author:`Hanzo Labs`,platform:`ios`,theme:`dark`,background:`#000000`,primary:`#00f0ff`,accent:`#ff007f`,glassBlur:28,radius:20,density:`comfortable`},{id:`nordic-frost`,name:`Nordic Frost`,description:`Pure arctic monochrome glass, high clarity, and minimalist typography.`,author:`Hanzo Design`,platform:`macos`,theme:`dark`,background:`#090d16`,primary:`#e2e8f0`,accent:`#38bdf8`,glassBlur:22,radius:14,density:`default`},{id:`studio-light`,name:`Studio Paper (Light)`,description:`Warm editorial paper ground, crisp ink typography, and subtle daylight glass.`,author:`Hanzo Design`,platform:`macos`,theme:`light`,background:`#faf8f5`,primary:`#18181b`,accent:`#2563eb`,glassBlur:16,radius:12,density:`default`}],t8=`hanzo.mod.active`;function n8(e){return JSON.stringify(e,null,2)}function r8(e){let t=JSON.parse(e);if(!t||typeof t!=`object`||!t.name)throw Error(`Invalid Hanzo mod: missing theme name`);return{id:t.id||`mod-${Date.now()}`,name:String(t.name).slice(0,64),description:t.description?String(t.description).slice(0,256):void 0,author:t.author?String(t.author).slice(0,64):void 0,org:t.org,platform:t.platform&&t.platform in q6?t.platform:void 0,theme:t.theme===`light`||t.theme===`dark`||t.theme===`system`?t.theme:void 0,background:t.background,surface:t.surface,foreground:t.foreground,fontHeading:t.fontHeading,fontBody:t.fontBody,fontMono:t.fontMono,customFontUrl:t.customFontUrl,primary:t.primary,accent:t.accent,glassTint:t.glassTint,glassBlur:typeof t.glassBlur==`number`?t.glassBlur:void 0,radius:typeof t.radius==`number`?t.radius:void 0,density:t.density,customCss:t.customCss}}function i8(e){let t=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/.exec(e.trim());if(!t)return`#fafafa`;let n=t[1].length===3?t[1].replace(/./g,`$&$&`):t[1].slice(0,6),[r,i,a]=[0,2,4].map(e=>{let t=parseInt(n.slice(e,e+2),16)/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4});return .2126*r+.7152*i+.0722*a>.179?`#09090b`:`#fafafa`}var a8=`--background.--foreground.--text-primary.--card.--surface-card.--card-foreground.--popover.--popover-foreground.--muted.--secondary.--secondary-hover.--secondary-foreground.--pane-floor.--pane-fill.--composer-fill.--composer-ground.--primary.--primary-foreground.--primary-hover.--accent.--accent-foreground.--accent-hover.--ring.--liquid-glass-bg.--glass-blur.--chrome-blur.--pane-blur.--radius.--pane-round.--radius-scale.--density.--font-heading.--font-display.--font-body.--font-sans.--font-mono`.split(`.`);function o8(e){if(typeof document>`u`)return;let t=document.documentElement;for(let e of a8)t.style.removeProperty(e);e.platform&&$6(e.platform);let n=e.theme??(e.background?i8(e.background)===`#09090b`?`light`:`dark`:void 0);if(n){let e=n===`dark`||n===`system`&&typeof matchMedia==`function`&&matchMedia(`(prefers-color-scheme: dark)`).matches;t.classList.toggle(`light`,!e),t.classList.toggle(`dark`,e),t.classList.toggle(`t_light`,!e),t.classList.toggle(`t_dark`,e),t.style.colorScheme=e?`dark`:`light`,t.setAttribute(`data-scheme`,n)}if(e.background){let n=e.background.trim(),r=e.foreground?.trim()||i8(n),i=r===`#09090b`?`black`:`white`,a=e.surface?.trim()||`color-mix(in oklch, ${n} 95%, ${i})`;t.style.setProperty(`--background`,n),t.style.setProperty(`--foreground`,r),t.style.setProperty(`--text-primary`,r),t.style.setProperty(`--card`,a),t.style.setProperty(`--surface-card`,a),t.style.setProperty(`--card-foreground`,r),t.style.setProperty(`--popover`,`color-mix(in oklch, ${n} 92%, ${i})`),t.style.setProperty(`--popover-foreground`,r),t.style.setProperty(`--muted`,`color-mix(in oklch, ${n} 92%, ${i})`),t.style.setProperty(`--secondary`,`color-mix(in oklch, ${n} 90%, ${i})`),t.style.setProperty(`--secondary-hover`,`color-mix(in oklch, ${n} 84%, ${i})`),t.style.setProperty(`--secondary-foreground`,r),t.style.setProperty(`--pane-floor`,`color-mix(in oklch, ${n} 95%, black)`),t.style.setProperty(`--pane-fill`,`color-mix(in oklch, ${n} 97%, ${i})`),t.style.setProperty(`--composer-fill`,`color-mix(in oklch, ${n} 90%, ${i})`),t.style.setProperty(`--composer-ground`,`color-mix(in oklch, ${n} 90%, ${i})`)}let r=e.accent||e.primary;if(r){let n=i8(r),i=`color-mix(in oklch, ${r} 88%, white)`;t.style.setProperty(`--primary`,e.primary||r),t.style.setProperty(`--primary-foreground`,n),t.style.setProperty(`--primary-hover`,i),t.style.setProperty(`--accent`,r),t.style.setProperty(`--accent-foreground`,n),t.style.setProperty(`--accent-hover`,i),t.style.setProperty(`--ring`,r)}if(e.glassTint&&t.style.setProperty(`--liquid-glass-bg`,e.glassTint),typeof e.glassBlur==`number`&&(t.style.setProperty(`--glass-blur`,`${e.glassBlur}px`),t.style.setProperty(`--chrome-blur`,`${e.glassBlur}px`),t.style.setProperty(`--pane-blur`,`${Math.round(e.glassBlur*1.5)}px`)),typeof e.radius==`number`&&(t.style.setProperty(`--radius`,`${e.radius}px`),t.style.setProperty(`--pane-round`,`${e.radius}px`),t.style.setProperty(`--radius-scale`,String(Math.round(e.radius/12*100)/100))),e.density){let n=e.density===`compact`?`0.85`:e.density===`comfortable`?`1.15`:`1`;t.style.setProperty(`--density`,n)}e.fontHeading&&(t.style.setProperty(`--font-heading`,e.fontHeading),t.style.setProperty(`--font-display`,e.fontHeading)),e.fontBody&&(t.style.setProperty(`--font-body`,e.fontBody),t.style.setProperty(`--font-sans`,e.fontBody)),e.fontMono&&t.style.setProperty(`--font-mono`,e.fontMono);let i=document.getElementById(`hanzo-custom-mod-css`);e.customCss?(i||(i=document.createElement(`style`),i.id=`hanzo-custom-mod-css`,document.head.appendChild(i)),i.textContent=e.customCss):i&&i.remove();try{window.localStorage.setItem(t8,JSON.stringify(e)),window.dispatchEvent(new CustomEvent(`hanzo:mod:applied`,{detail:{mod:e}}))}catch{}}function s8(){if(!(typeof window>`u`))try{window.localStorage.removeItem(t8);let e=document.getElementById(`hanzo-custom-mod-css`);if(e&&e.remove(),typeof document<`u`){let e=document.documentElement;for(let t of a8)e.style.removeProperty(t);Z6()}window.dispatchEvent(new CustomEvent(`hanzo:mod:cleared`))}catch{}}var c8=`hanzo-font-`;function l8(e){if(typeof document>`u`)return;let t=`${c8}${e.family.toLowerCase().replace(/[^a-z0-9]/g,`-`)}`,n=document.getElementById(t);if(n&&n.remove(),e.isStylesheet||e.url.endsWith(`.css`)||e.url.includes(`fonts.googleapis.com`)){let n=document.createElement(`link`);n.id=t,n.rel=`stylesheet`,n.href=e.url,document.head.appendChild(n)}else{let n=e.format||(e.url.endsWith(`.woff2`)?`woff2`:e.url.endsWith(`.woff`)?`woff`:`truetype`),r=e.weights||[400,500,600,700],i=``;for(let t of r)i+=`
|
|
179
|
+
@font-face {
|
|
180
|
+
font-family: "${e.family}";
|
|
181
|
+
src: url("${e.url}") format("${n}");
|
|
182
|
+
font-weight: ${t};
|
|
183
|
+
font-style: normal;
|
|
184
|
+
font-display: swap;
|
|
185
|
+
}
|
|
186
|
+
`;let a=document.createElement(`style`);a.id=t,a.textContent=i,document.head.appendChild(a)}}function u8(e,t){if(typeof document>`u`)return;let n=e===`heading`?`--font-heading`:e===`mono`?`--font-mono`:`--font-sans`;document.documentElement.style.setProperty(n,t)}(0,V.createContext)({router:{push:e=>window.location.assign(e),replace:e=>window.location.replace(e),back:()=>window.history.back(),forward:()=>window.history.forward()},path:null,route:`/`,Link:({prefetch:e,...t})=>(0,H.jsx)(`a`,{...t})});function d8(){let{currentOrg:e}=fW(),t=e;return{id:t?.id||t?.name,name:t?.displayName||t?.name}}var f8={theme:`system`};function p8(){let{accessToken:e}=dW();return jz({org:d8().id,account:e?{base:fG(),token:e}:void 0,install:f8})}var m8={rounded:8,borderWidth:1,borderStyle:`solid`,cursor:`pointer`},h8=[{id:`auto`,label:D(`Auto (System OS)`),note:D(`Automatically detects your device operating system`)},{id:`ios`,label:D(`Apple iOS (Liquid Glass)`),note:D(`Continuous squircles, specular liquid glass, SF Pro typography`)},{id:`android`,label:D(`Android (Material 3)`),note:D(`Material 3 tonal elevations and Google Sans geometry`)},{id:`macos`,label:D(`Apple macOS (Vibrant)`),note:D(`Translucent glass sidebars and compact desktop density`)},{id:`windows`,label:D(`Windows (Mica Fluent)`),note:D(`Fluent Design acrylic Mica and Segoe UI Variable`)},{id:`linux`,label:D(`Linux (Clean System)`),note:D(`Crisp system geometry and flat modern edges`)}];function g8(){let{t:e}=R(),{accessToken:t}=dW(),n=d8(),r=p8(),[i,a]=Bq(),[o,s]=(0,V.useState)(()=>typeof window>`u`?`auto`:window.localStorage.getItem(`hanzo.mod.platform`)??`auto`),[c,l]=(0,V.useState)(()=>{if(typeof window>`u`)return null;try{let e=window.localStorage.getItem(`hanzo.mod.active`);return e?JSON.parse(e)?.id??null:null}catch{return null}}),[u,d]=(0,V.useState)(``),[f,p]=(0,V.useState)(!1),[m,h]=(0,V.useState)(``),[g,_]=(0,V.useState)(!1);(0,V.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>l(null),t=e=>{let t=e.detail;t?.mod?.id&&l(t.mod.id)};return window.addEventListener(`hanzo:mod:cleared`,e),window.addEventListener(`hanzo:mod:applied`,t),()=>{window.removeEventListener(`hanzo:mod:cleared`,e),window.removeEventListener(`hanzo:mod:applied`,t)}},[]);let v=e=>{s(e),Q6(e),e===`auto`&&Cz(r.pref)},b=e=>{if(c===e.id){s8(),l(null),Cz(r.pref);return}l(e.id),e.platform&&s(e.platform),r.set({...e.theme?{theme:e.theme}:{},background:e.background,accent:e.accent??e.primary,...e.density?{density:e.density}:{}}),o8(e)},x=()=>{if(!u.trim())return;let e=u.trim(),t=e.startsWith(`http://`)||e.startsWith(`https://`)?`CustomBrandFont`:e;t===`CustomBrandFont`&&l8({family:t,url:e,isStylesheet:!0}),u8(`heading`,`var(--font-arabic), ${t}, sans-serif`),u8(`sans`,`var(--font-arabic), ${t}, sans-serif`),p(!0),setTimeout(()=>p(!1),2500)},S=e=>{let t=n8(e);navigator.clipboard?.writeText(t),_(!0),setTimeout(()=>_(!1),2e3)};return(0,H.jsxs)(z,{gap:`$5`,maxW:540,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Customized per organization and kept with your account across all Hanzo surfaces.`)}),(0,H.jsx)(One,{org:n.id,orgName:n.name||yW(),account:{base:fG(),token:t??void 0}}),(0,H.jsxs)(z,{gap:`$2.5`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(fK,{size:16,color:`var(--primary)`,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Native Platform Look & Feel`)})]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Adaptive styling tailored to your OS: iOS Liquid Glass, Material 3, macOS Vibrant, or Windows Mica.`)}),(0,H.jsx)(z,{gap:`$1.5`,pt:`$1`,children:h8.map(t=>{let n=o===t.id;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>v(t.id),...m8,p:`$2.5`,bg:n?`var(--edge, var(--white-14))`:`transparent`,borderColor:n?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:n?`600`:`500`,color:`$ink`,children:e(t.label)}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e(t.note)})]}),n?(0,H.jsx)(XG,{size:16,color:`var(--primary)`,"aria-hidden":!0}):null]})},t.id)})})]}),(0,H.jsxs)(z,{gap:`$3`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(oK,{size:16,color:`var(--primary)`,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Organization Theme Mods (@hanzo/mod)`)})]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Select or fork designer themes for custom organization branding.`)}),(0,H.jsx)(y,{gap:`$2`,flexWrap:`wrap`,children:e8.map(e=>{let t=c===e.id;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>b(e),...m8,py:6,px:12,bg:t?`var(--edge, var(--white-14))`:`transparent`,borderColor:t?`var(--borderColor, var(--white-22))`:`var(--white-10)`,hoverStyle:{bg:`$hover`},children:(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:t?`600`:`400`,color:`$ink`,children:e.name}),t?(0,H.jsx)(XG,{size:12,color:`var(--primary)`,"aria-hidden":!0}):null]})},e.id)})}),(0,H.jsxs)(z,{gap:`$2`,p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(gK,{size:15,color:`var(--primary)`,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Custom Typography`)})]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Enter a font family name (e.g. "Zen", "Inter", "Cabinet Grotesk") or a webfont stylesheet URL.`)}),(0,H.jsxs)(y,{gap:`$2`,items:`center`,children:[(0,H.jsx)(j_,{flex:1,size:`sm`,value:u,onChange:e=>d(e.target.value),placeholder:`e.g. Cabinet Grotesk or https://fonts.googleapis.com/...`}),(0,H.jsx)(W,{size:`sm`,onClick:x,children:e(f?`Applied!`:`Apply Font`)})]})]}),(0,H.jsxs)(z,{gap:`$2`,p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Fork & Share Theme Mods`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Export current mod configuration or paste a mod JSON to import.`)}),(0,H.jsxs)(y,{gap:`$2`,items:`center`,children:[(0,H.jsx)(j_,{flex:1,size:`sm`,value:m,onChange:e=>h(e.target.value),placeholder:e(`Paste mod JSON here to import`)}),(0,H.jsxs)(W,{size:`sm`,variant:`outline`,onClick:()=>{if(m.trim())try{let t=r8(m.trim());b(t),alert(e(`Mod "{name}" successfully applied!`,{name:t.name})),h(``)}catch(t){alert(e(`Failed to import mod: {message}`,{message:t.message}))}},children:[(0,H.jsx)(vK,{size:13,"aria-hidden":!0}),e(`Import`)]}),(0,H.jsxs)(W,{size:`sm`,variant:`outline`,onClick:()=>S(e8[0]),children:[(0,H.jsx)(eK,{size:13,"aria-hidden":!0}),e(g?`Copied!`:`Export JSON`)]})]})]})]}),(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Language`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`The language Hanzo is shown in, on every Hanzo surface you sign in to.`)}),(0,H.jsx)(y,{pt:`$1`,children:(0,H.jsx)(ge,{})})]}),(0,H.jsxs)(z,{gap:`$2`,"data-slot":`settings-approval-mode`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Tool & Action Approval`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Control whether tools, connectors, and actions execute automatically or require manual approval first.`)}),(0,H.jsx)(y,{gap:`$2`,pt:`$1`,children:[{id:`auto`,label:e(`Auto`),note:e(`Runs tools on its own; pauses only for anything risky.`)},{id:`manual`,label:e(`Manual`),note:e(`Asks before each tool, connector or site it opens.`)}].map(e=>{let t=(i.approvalMode||`auto`)===e.id;return(0,H.jsxs)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>a({approvalMode:e.id}),...m8,flex:1,p:`$2.5`,bg:t?`var(--edge, var(--white-14))`:`transparent`,borderColor:t?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:t?`600`:`500`,color:`$ink`,children:e.label}),t?(0,H.jsx)(XG,{size:16,color:`var(--primary)`,"aria-hidden":!0}):null]}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e.note})]},e.id)})})]}),(0,H.jsxs)(z,{gap:`$2`,"data-slot":`settings-reasoning-effort`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Default Reasoning Effort`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Sets how deeply models think before answering. Defaults to Auto, where the router decides.`)}),(0,H.jsx)(y,{gap:`$2`,pt:`$1`,flexWrap:`wrap`,children:DK.map(e=>{let t=(i.effort||`auto`)===e.id;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>a({effort:e.id}),...m8,py:6,px:12,bg:t?`var(--edge, var(--white-14))`:`transparent`,borderColor:t?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:t?`600`:`400`,color:t?`$ink`:`$soft`,children:e.label}),t?(0,H.jsx)(XG,{size:12,color:`var(--primary)`,"aria-hidden":!0}):null]})},e.id)})})]})]})}function _8(e,t){let n=DG(),r=!!n.Authorization,i=y8(n),[a,o]=(0,V.useState)(()=>S8(e,t)),[s,c]=(0,V.useState)(!r);return(0,V.useEffect)(()=>{if(!r)return;let i=!0;return Fre().then(r=>{if(!i)return;let a=`${n.Authorization}:${e}`;if(v8.has(a)){let t=v8.get(a);o(t),C8(e,t)}else if(r){if(e in r){let t=r[e];o(t),C8(e,t)}else{let n=S8(e,t);n===t?(o(t),C8(e,t)):(o(n),x8({[e]:n}))}}c(!0)}),()=>{i=!1}},[e,r,i]),[a,t=>{o(t),C8(e,t),x8({[e]:t})},s]}var v8=new Map;function y8(e){return e.Authorization?`${e.Authorization}:${e[`X-Org-Id`]??``}`:``}var b8=null;function Fre(){let e=DG();if(!e.Authorization)return Promise.resolve(null);let t=y8(e);return b8?.auth!==t&&(b8={auth:t,doc:fetch(`${fG()}/v1/pref`,{headers:e}).then(e=>e.ok?e.json():null).then(e=>e&&e.prefs&&typeof e.prefs==`object`?e.prefs:e?{}:null).catch(()=>null)}),b8.doc}function x8(e){let t=DG();if(!t.Authorization)return;for(let[n,r]of Object.entries(e))v8.set(`${t.Authorization}:${n}`,r);let n=y8(t);b8?.auth===n&&(b8={auth:n,doc:b8.doc.then(t=>({...t??{},...e}))}),fetch(`${fG()}/v1/pref`,{method:`PATCH`,keepalive:!0,headers:{...t,"Content-Type":`application/json`},body:JSON.stringify(e)}).catch(()=>{})}function S8(e,t){try{let n=localStorage.getItem(e);return n===null?t:JSON.parse(n)}catch{return t}}function C8(e,t){try{localStorage.setItem(e,JSON.stringify(t))}catch{}}function Ire(){let{t:e}=R(),{isAuthenticated:t}=dW(),[n,r]=(0,V.useState)(null),[i,a]=(0,V.useState)(!1),[o,s]=(0,V.useState)(null);if((0,V.useEffect)(()=>{if(!t)return;let e=!0;return VW().then(t=>e&&r(t)).catch(t=>e&&s(t instanceof Error?t.message:String(t))),()=>{e=!1}},[t]),!t)return null;let c=n?.blocked===!0,l=e(`Automatically opt-in for future experimental features`);return(0,H.jsxs)(z,{p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,gap:`$3`,"data-slot":`optin`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:`$3`,children:[(0,H.jsxs)(z,{flex:1,pr:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:l}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Automatically opt into new experimental features, unless disabled by your team or organization`)})]}),(0,H.jsx)(av,{"aria-label":l,checked:n?.on===!0&&!c,disabled:!n||i||c,onCheckedChange:e=>{a(!0),s(null),HW(e).then(r).catch(e=>s(e instanceof Error?e.message:String(e))).finally(()=>a(!1))}})]}),c?(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,"data-slot":`optin-blocked`,children:e(`Turned off by your team or organization.`)}):null,o?(0,H.jsx)(U,{fontSize:`$2`,color:`$red10`,children:e(o)}):null]})}var w8={rounded:8,borderWidth:1,borderStyle:`solid`,cursor:`pointer`};function Lre({id:e}){let{t}=R(),n=NK.find(t=>t.id===e);return(0,H.jsx)(z,{flex:1,minH:0,overflowY:`auto`,overflowX:`hidden`,children:(0,H.jsxs)(z,{p:`$5`,gap:`$4`,maxW:860,children:[(0,H.jsx)(U,{fontSize:`$6`,fontWeight:`600`,color:`$ink`,children:n?jK(n,t):t(`Settings`)}),(0,H.jsx)(Rre,{id:e,note:n?.note?t(n.note):void 0})]})})}function Rre({id:e,note:t}){let{t:n}=R();return e===`apps`||e===`channels`?(0,H.jsx)(g6,{tab:e}):e===`general`?(0,H.jsxs)(z,{gap:`$5`,children:[(0,H.jsx)(g8,{}),(0,H.jsx)(Ire,{})]}):e===`account`?(0,H.jsx)(Vre,{}):e===`billing`?(0,H.jsx)(Ure,{}):e===`referrals`?(0,H.jsx)(Hre,{}):e===`usage`?(0,H.jsx)(Wre,{}):e===`model`?(0,H.jsx)(zre,{}):e===`models`?(0,H.jsx)(Bre,{}):e===`agent`?(0,H.jsx)(Kre,{}):e===`capabilities`?(0,H.jsx)(qre,{}):e===`memory`?(0,H.jsx)(Jre,{}):(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:t??n(`Nothing to configure here yet.`)})}function zre(){let{t:e}=R(),{models:t}=JY(),n=(0,V.useMemo)(()=>Mn(t).filter(e=>e.class!==`premium`),[t]),[r,i]=Oq(),[a,o]=Bq(),{isAuthenticated:s}=dW(),{tier:c}=R6(s,EG()),l=!!(c?.plan&&c.plan!==`free`);return(0,H.jsxs)(z,{gap:`$5`,maxW:540,children:[(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Default model`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Used for new chats and runs. An agent with its own model keeps that choice.`)}),(0,H.jsx)(y,{self:`flex-start`,pt:`$1`,children:(0,H.jsx)(EK,{models:n,scope:`chat`,value:r.model,onChange:e=>i({model:e}),size:`sm`})})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Default reasoning effort`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Sets how deeply models think before answering. Defaults to Auto, where the router decides.`)}),(0,H.jsx)(y,{gap:`$2`,pt:`$1`,flexWrap:`wrap`,children:DK.map(e=>{let t=(a.effort||`auto`)===e.id;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>{o({effort:e.id});let t=Fq(e.id);t&&i({effort:t})},...w8,bg:t?`var(--edge, var(--white-14))`:`transparent`,borderColor:t?`var(--borderColor, var(--white-22))`:`var(--white-08)`,py:6,px:12,children:(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:t?`600`:`400`,color:t?`$ink`:`$soft`,children:e.label}),t?(0,H.jsx)(XG,{size:12,color:`var(--primary)`,"aria-hidden":!0}):null]})},e.id)})})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$2`,"data-slot":`settings-approval-mode`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Tool & action approval`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Choose whether agents run tools and connectors automatically or ask for manual approval before each action.`)}),(0,H.jsx)(y,{gap:`$2`,pt:`$1`,children:[{id:`auto`,label:e(`Auto`),desc:e(`Runs tools on its own; pauses only for anything risky.`)},{id:`manual`,label:e(`Manual`),desc:e(`Asks before each tool, connector or site it opens.`)}].map(e=>{let t=(a.approvalMode||`auto`)===e.id;return(0,H.jsxs)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>o({approvalMode:e.id}),...w8,flex:1,p:10,bg:t?`var(--edge, var(--white-14))`:`transparent`,borderColor:t?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,children:e.label}),t?(0,H.jsx)(XG,{size:12,color:`var(--primary)`,"aria-hidden":!0}):null]}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e.desc})]},e.id)})})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$3`,children:[(0,H.jsx)(y,{items:`center`,justify:`space-between`,children:(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Advanced composer controls`)}),l?null:(0,H.jsxs)(y,{items:`center`,gap:`$1`,px:`$2`,py:`$0.5`,rounded:9999,bg:`var(--edge, var(--white-10))`,children:[(0,H.jsx)(iK,{size:11,color:`$soft`,"aria-hidden":!0}),(0,H.jsx)(U,{fontSize:`$1`,fontWeight:`600`,color:`$soft`,children:e(`Paid plan`)})]})]}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Third-party model access, and the language dictation listens in.`)})]})}),(0,H.jsx)(z,{p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,gap:`$2`,children:(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsxs)(z,{flex:1,pr:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Enable third-party models`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Third-party models (OpenAI, Anthropic, Google, DeepSeek) are paid from your pre-paid balance on any plan. First-party models (Enso, Zen, Kai) are covered by your plan.`)})]}),(0,H.jsx)(W,{size:`sm`,variant:a.allowThirdPartyModels?`default`:`outline`,onClick:()=>o({allowThirdPartyModels:!a.allowThirdPartyModels,thirdPartyChosen:!0}),children:a.allowThirdPartyModels?e(`Enabled`):e(`Disabled`)})]})}),(0,H.jsx)(z,{p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,gap:`$2`,children:(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsxs)(z,{flex:1,pr:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Show language selector beside +`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Display the dictation language indicator next to the + context button on the composer row.`)})]}),(0,H.jsx)(W,{size:`sm`,variant:a.showLanguage?`default`:`outline`,onClick:()=>o({showLanguage:!a.showLanguage}),children:a.showLanguage?e(`Enabled`):e(`Disabled`)})]})}),l?null:(0,H.jsx)(y,{pt:`$1`,children:(0,H.jsxs)(W,{size:`sm`,variant:`outline`,onClick:()=>window.location.assign(bW(`/pricing`)),children:[(0,H.jsx)(mK,{size:14,color:`var(--primary)`,"aria-hidden":!0}),e(`Upgrade to unlock advanced model controls`)]})})]})]})}function Bre(){let{t:e}=R(),{models:t,loading:n,error:r}=JY();return n?(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Reading the catalog.`)}):r?(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`The catalog did not answer: {message}`,{message:r.message})}):t.length===0?(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`No model answers on this account. Sign in to reach the ones your org opens.`)}):(0,H.jsxs)(z,{gap:`$3`,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`{count} models answer at {path} on this account.`,{count:t.length,path:`/v1/models`})}),(0,H.jsx)(z,{children:t.map(e=>(0,H.jsxs)(y,{items:`center`,gap:`$2.5`,py:`$2`,borderBottomWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(M3,{model:e.id,org:e.owned_by,size:16,ink:!0}),(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,flex:1,children:(0,H.jsx)(`bdi`,{dir:`ltr`,children:e.id})}),e.owned_by?(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:(0,H.jsx)(`bdi`,{dir:`ltr`,children:e.owned_by})}):null]},e.id))}),(0,H.jsx)(y,{children:(0,H.jsx)($S,{render:(0,H.jsx)(`a`,{href:bW(`/models`)}),...Vq,children:(0,H.jsxs)(y,{items:`center`,gap:`$2`,py:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$ink`,children:e(`Browse the model catalog`)}),(0,H.jsx)(JG,{size:13,"aria-hidden":!0})]})})})]})}function Vre(){let{t:e}=R(),t=mW(),{isAuthenticated:n}=dW(),r=TJ(),{organizations:i,currentOrgId:a,currentRole:o,switchOrg:s}=fW();return!n||!t?(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Sign in to see your account.`)}):(0,H.jsxs)(z,{gap:`$4`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$3`,children:[(0,H.jsx)(z,{width:44,height:44,rounded:22,bg:`$borderColor`,items:`center`,justify:`center`,children:(0,H.jsx)(U,{fontSize:`$3`,color:`$ink`,children:t.initials})}),(0,H.jsxs)(z,{gap:`$1`,flex:1,minW:0,children:[(0,H.jsx)(U,{fontSize:`$4`,color:`$ink`,children:t.name}),t.email?(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:(0,H.jsx)(`bdi`,{dir:`ltr`,children:t.email})}):null]})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Organizations`)}),i.length===0?(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`You are not a member of an organization.`)}):i.map(e=>{let t=e.name===a;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),onClick:()=>{kG(e.name),s(e.name)},...Vq,children:(0,H.jsxs)(y,{items:`center`,justify:`space-between`,py:`$2`,width:`100%`,gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,color:t?`$ink`:`$soft`,children:e.displayName||e.name}),t&&o?(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:o}):null]})},e.name)})]}),(0,H.jsx)(Lc,{}),(0,H.jsx)(T8,{}),(0,H.jsx)(Lc,{}),(0,H.jsx)(y,{children:(0,H.jsx)(W,{size:`sm`,onClick:()=>r(),children:e(`Sign out`)})})]})}function T8(){let{t:e}=R(),[t,n]=_8(`rewards_payout_wallet`,``),[,r]=_8(`rewards_payout_provider`,``),[i,a]=(0,V.useState)(!1),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(``),u=async(e,t)=>{let i=e.trim();n(i),r(i?t:``),s(!0),setTimeout(()=>s(!1),2400)},d=async()=>{l(``),a(!0);try{let t=typeof window<`u`?window.ethereum:void 0;if(!t?.request){l(e(`No EVM browser wallet detected. Install MetaMask, Coinbase Wallet, or Brave Wallet, or paste your payout address below.`));return}let n=(await t.request({method:`eth_requestAccounts`}))?.[0];n&&await u(n,`evm`)}catch(t){l(t instanceof Error?t.message:e(`Wallet connection cancelled.`))}finally{a(!1)}},f=async()=>{l(``),a(!0);try{let t=typeof window<`u`?window.solana:void 0;if(!t?.connect){l(e(`No Solana wallet detected. Install Phantom or Backpack, or paste your payout address below.`));return}let n=(await t.connect())?.publicKey?.toString();n&&await u(n,`solana`)}catch(t){l(t instanceof Error?t.message:e(`Wallet connection cancelled.`))}finally{a(!1)}};return(0,H.jsxs)(z,{gap:`$2.5`,"data-slot":`wallet-payouts`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Web3 Wallet & Rewards Payouts`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Connect your Web3 wallet (MetaMask, EVM / Base, or Solana) or enter a payout address to collect referral rewards, affiliate commissions, and AI compute rebates.`)}),(0,H.jsxs)(y,{gap:`$2`,flexWrap:`wrap`,children:[(0,H.jsx)(W,{size:`sm`,variant:`outline`,disabled:i,onClick:()=>void d(),children:e(`Connect EVM / MetaMask`)}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,disabled:i,onClick:()=>void f(),children:e(`Connect Solana Wallet`)})]}),(0,H.jsxs)(y,{gap:`$2`,items:`center`,children:[(0,H.jsx)(j_,{flex:1,size:`sm`,placeholder:e(`0x... (EVM / Base) or Solana payout address`),value:t,onChange:e=>n(e.target.value)}),(0,H.jsx)(W,{size:`sm`,onClick:()=>void u(t,`manual`),children:e(o?`Saved!`:`Save Payout Wallet`)})]}),c?(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:c}):null]})}function Hre(){let{t:e}=R(),t=mW(),{isAuthenticated:n}=dW(),[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(``),[s,c]=(0,V.useState)(!1);if(!n||!t)return(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Sign in to view your referral program.`)});let l=t.name?t.name.toLowerCase().replace(/\s+/g,`-`):t.email?t.email.split(`@`)[0]:`user`,u=`https://hanzo.ai/?ref=${encodeURIComponent(l)}`;return(0,H.jsxs)(z,{gap:`$5`,maxW:640,children:[(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsx)(y,{items:`center`,gap:`$2`,children:(0,H.jsx)(U,{fontSize:`$4`,fontWeight:`600`,color:`$ink`,children:e(`Give $20, Get 20%`)})}),(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Invite developers, creators, and colleagues to Hanzo. They get $20 in free cloud compute credits, and you earn 20% recurring revenue share on their compute spend for 12 months.`)})]}),(0,H.jsxs)(z,{gap:`$2`,p:`$3`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,children:e(`Your Personal Referral Link`)}),(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)($S,{flex:1,p:`$2`,rounded:`$2`,bg:`$hover`,borderWidth:1,borderColor:`$borderColor`,children:(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,fontFamily:`$mono`,numberOfLines:1,children:u})}),(0,H.jsx)(W,{size:`sm`,onClick:()=>{navigator.clipboard.writeText(u),i(!0),setTimeout(()=>i(!1),2e3)},children:e(r?`Copied!`:`Copy Link`)})]}),(0,H.jsxs)(y,{items:`center`,justify:`space-between`,pt:`$2`,flexWrap:`wrap`,gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e(`1-Click Social Share:`)}),(0,H.jsxs)(y,{gap:`$2`,flexWrap:`wrap`,children:[(0,H.jsx)(W,{size:`sm`,variant:`outline`,onClick:()=>{window.open(`https://twitter.com/intent/tweet?text=Deploy%20AI%20agents%2C%20sites%2C%20and%20apps%20on%20%40HanzoAI.%20Get%20%2420%20in%20free%20cloud%20compute%20credits%3A&url=${encodeURIComponent(u)}`,`_blank`,`noopener,noreferrer`)},children:`𝕏 (Twitter)`}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,onClick:()=>{window.open(`https://www.linkedin.com/sharing/share-offsite/?url=${encodeURIComponent(u)}`,`_blank`,`noopener,noreferrer`)},children:`LinkedIn`}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,onClick:()=>{window.open(`https://t.me/share/url?url=${encodeURIComponent(u)}&text=Get%20%2420%20free%20Hanzo%20cloud%20compute%20credits%3A`,`_blank`,`noopener,noreferrer`)},children:`Telegram`}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,onClick:()=>{window.open(`https://api.whatsapp.com/send?text=${encodeURIComponent(`Deploy with Hanzo — get $20 in free cloud credits: `+u)}`,`_blank`,`noopener,noreferrer`)},children:`WhatsApp`})]})]})]}),(0,H.jsx)(Lc,{}),(0,H.jsx)(T8,{}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Referral Rules & Offer Details`)}),(0,H.jsxs)(z,{gap:`$1`,children:[(0,H.jsxs)(U,{fontSize:`$2`,color:`$soft`,children:[`• `,e(`30-day attribution window: First click binds to user identity upon registration.`)]}),(0,H.jsxs)(U,{fontSize:`$2`,color:`$soft`,children:[`• `,e(`20% recurring margin share: Calculated against net platform margin (safe from wholesale token dilution).`)]}),(0,H.jsxs)(U,{fontSize:`$2`,color:`$soft`,children:[`• `,e(`Payout options: Platform credits, direct wire/ACH, or on-chain EVM wallet settlement.`)]})]})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$3`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Official Affiliate & Creator Program`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Building an open-source project, template, or dev community? Apply for official affiliate status for custom vanity links (hanzo.ai/?aff=code) and elevated commission tiers.`)}),s?(0,H.jsx)($S,{p:`$3`,rounded:`$2`,bg:`$hover`,children:(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,children:e(`Application submitted for review. Manage payouts and advanced settings in platform.hanzo.ai/dashboard/settings/referrals`)})}):(0,H.jsxs)(y,{gap:`$2`,children:[(0,H.jsx)(j_,{flex:1,size:`sm`,placeholder:e(`Desired vanity code (e.g. your project)`),value:a,onChange:e=>o(e.target.value)}),(0,H.jsx)(W,{size:`sm`,onClick:()=>{a.trim()&&c(!0)},children:e(`Apply for Partner`)})]}),(0,H.jsx)(y,{pt:`$1`,children:(0,H.jsx)($S,{render:(0,H.jsx)(`a`,{href:`https://platform.hanzo.ai/dashboard/settings/referrals`,target:`_blank`,rel:`noreferrer`}),...Vq,children:(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$ink`,children:e(`Open Full Referrals & Affiliate Portal`)}),(0,H.jsx)(JG,{size:13,"aria-hidden":!0})]})})})]})]})}function E8(){let e=EG();return(0,V.useMemo)(()=>({api:fG(),token:_G,org:e}),[e])}function Ure(){let{t:e,locale:t}=R(),{isAuthenticated:n}=dW(),r=E8(),{tier:i}=R6(n,EG()),a=P6(n,EG());if(!n)return(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Sign in to see billing.`)});let o=i?Z2(i.plan,i.tier.name)??{name:`Free`,tag:``}:null;return(0,H.jsxs)(z,{gap:`$5`,children:[o?(0,H.jsxs)(z,{gap:`$1`,"data-slot":`billing-plan`,children:[(0,H.jsx)(C4,{label:o,size:`$5`}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:a?N6(a,e,t):i?.plan?e(`Your plan.`):e(`No paid plan. Usage is paid from credits.`)})]}):(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Reading your plan…`)}),(0,H.jsx)(M4,{target:r,admin:E4(_G(),EG()),add:S6()}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$2`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Payment`)}),(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`A card is entered on the payment host and nowhere else, so this is the one control here that opens another surface.`)}),(0,H.jsx)(y,{children:(0,H.jsx)($S,{render:(0,H.jsx)(`a`,{href:S6(),target:`_blank`,rel:`noreferrer`}),...Vq,children:(0,H.jsxs)(y,{items:`center`,gap:`$2`,py:`$2`,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$ink`,children:e(`Manage plan, payment method and invoices`)}),(0,H.jsx)(nK,{size:13,"aria-hidden":!0})]})})})]})]})}function Wre(){let{t:e}=R(),{accessToken:t,isAuthenticated:n}=dW(),r=E8(),i=B6(n,EG());if(!n||!t)return(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Sign in to see your usage.`)});let a=(0,H.jsx)(R4,{target:r,onPlans:()=>window.location.assign(bW(`/pricing`)),onBilling:()=>K6(`billing`)});return V6(i)?(0,H.jsxs)(z,{gap:`$6`,children:[a,(0,H.jsx)(oZ,{baseUrl:fG(),token:t,upgrade:S6(),title:e(`Spend`)})]}):a}var Gre=[{id:`architect`,name:D(`Software Architect`),role:`Full-stack & systems design`,words:!0},{id:`satoshi`,name:`Satoshi Nakamoto`,role:`Distributed cryptography & consensus`},{id:`turing`,name:`Alan Turing`,role:`Algorithmic logic & formal verification`},{id:`ada`,name:`Ada Lovelace`,role:`Computational precision & analysis`},{id:`davinci`,name:`Leonardo da Vinci`,role:`Polymathic engineering & design`}];function Kre(){let{t:e}=R(),[t,n]=(0,V.useState)(()=>typeof window>`u`?``:localStorage.getItem(`hanzo.agent.instructions`)||`You are an autonomous AI software engineer at Hanzo. Think step-by-step and write robust code.`),[r,i]=(0,V.useState)(()=>typeof window>`u`?`architect`:localStorage.getItem(`hanzo.agent.persona`)||`architect`),[a,o]=(0,V.useState)(()=>typeof window>`u`?`autonomous`:localStorage.getItem(`hanzo.agent.autonomy`)||`autonomous`),[s,c]=(0,V.useState)(!1),[,l]=Bq(),u=()=>{localStorage.setItem(`hanzo.agent.instructions`,t),localStorage.setItem(`hanzo.agent.persona`,r),localStorage.setItem(`hanzo.agent.autonomy`,a),l({approvalMode:a===`supervised`?`manual`:`auto`}),c(!0),setTimeout(()=>c(!1),2e3)};return(0,H.jsxs)(z,{gap:`$4`,maxW:480,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Nothing is bound to this surface yet — when you bind a personal agent, its persona, tools and memory live here rather than in a shared team.`)}),(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Persona & Historical Character`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Pick an intellectual archetype for agent reasoning and tone.`)}),(0,H.jsx)(y,{flexWrap:`wrap`,gap:`$2`,pt:`$1`,children:Gre.map(t=>{let n=r===t.id;return(0,H.jsx)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>i(t.id),...w8,bg:n?`var(--edge, var(--white-14))`:`transparent`,borderColor:n?`var(--borderColor, var(--white-22))`:`var(--white-08)`,py:6,px:12,children:(0,H.jsx)(U,{fontSize:`$2`,fontWeight:n?`600`:`400`,color:n?`$ink`:`$soft`,children:t.words?e(t.name):t.name})},t.id)})})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`System Prompt Instructions`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Custom system directions prepended to all coding and research runs.`)}),(0,H.jsx)(U,{render:(0,H.jsx)(`textarea`,{value:t,onChange:e=>n(e.target.value),rows:4}),width:`100%`,bg:`var(--panel, color-mix(in srgb, var(--pure-black) 30%, transparent))`,color:`inherit`,borderWidth:1,borderColor:`var(--borderColor, var(--white-15))`,rounded:8,p:10,fontSize:`$2`,fontFamily:`$mono`})]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(z,{gap:`$1.5`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Autonomy & Permissions`)}),(0,H.jsxs)(y,{gap:`$2`,children:[(0,H.jsxs)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>o(`autonomous`),...w8,flex:1,p:10,bg:a===`autonomous`?`var(--edge, var(--white-14))`:`transparent`,borderColor:a===`autonomous`?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,children:e(`Autonomous`)}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e(`Executes tools & writes code without interrupting.`)})]}),(0,H.jsxs)($S,{render:(0,H.jsx)(`button`,{type:`button`}),...Vq,onClick:()=>o(`supervised`),...w8,flex:1,p:10,bg:a===`supervised`?`var(--edge, var(--white-14))`:`transparent`,borderColor:a===`supervised`?`var(--borderColor, var(--white-22))`:`var(--white-08)`,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`600`,color:`$ink`,children:e(`Supervised`)}),(0,H.jsx)(U,{fontSize:`$1`,color:`$soft`,children:e(`Requests confirmation before file writes and commands.`)})]})]})]}),(0,H.jsx)(y,{self:`flex-start`,pt:`$2`,children:(0,H.jsx)(W,{size:`sm`,onClick:u,children:e(s?`Saved`:`Save agent preferences`)})})]})}function qre(){let{t:e}=R();return(0,H.jsxs)(z,{gap:`$3`,maxW:480,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`What models and agent swarms are granted access to during tasks.`)}),(0,H.jsx)(z,{gap:`$2`,pt:`$1`,children:[{id:`files`,title:e(`Filesystem (Read / Write)`),desc:e(`Create, modify, and delete workspace files in the target repository.`)},{id:`shell`,title:e(`Shell & Terminal Exec`),desc:e(`Execute build, test, and shell commands in isolated sandbox VMs.`)},{id:`web`,title:e(`Live Web & Search`),desc:e(`Query internet search APIs and fetch web documentation.`)},{id:`mcp`,title:e(`MCP Protocol Server`),desc:e(`Expose local and remote tools via Model Context Protocol at /mcp.`)}].map(e=>(0,H.jsxs)(z,{gap:`$0.5`,p:`$2.5`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e.title}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e.desc})]},e.id))})]})}function Jre(){let{t:e}=R(),[t,n]=(0,V.useState)(!1);return(0,H.jsxs)(z,{gap:`$3`,maxW:480,children:[(0,H.jsx)(U,{fontSize:`$3`,color:`$soft`,children:e(`Semantic memory and conversation recall across sessions.`)}),(0,H.jsxs)(z,{gap:`$0.5`,p:`$2.5`,rounded:`$3`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:e(`Semantic Vector Index`)}),(0,H.jsx)(U,{fontSize:`$2`,color:`$soft`,children:e(`Automatically indexes past workspace sessions into vector memory.`)})]}),(0,H.jsx)(y,{self:`flex-start`,pt:`$2`,children:(0,H.jsx)(W,{size:`sm`,variant:`outline`,onClick:()=>{localStorage.removeItem(`hanzo.chat.history`),n(!0),setTimeout(()=>n(!1),2e3)},children:e(t?`Memory cleared`:`Clear local memory cache`)})})]})}function D8({open:e,onOpenChange:t,initialSection:n=PK}){let{t:r}=R(),[i,a]=(0,V.useState)(n),[o,s]=(0,V.useState)(``);return(0,V.useEffect)(()=>{e&&a(n)},[e,n]),(0,H.jsx)(tt,{open:e,onOpenChange:t,children:(0,H.jsxs)(pn,{"data-slot":`preferences-dialog`,width:`94vw`,maxW:980,height:`84vh`,maxH:760,p:0,gap:0,rounded:14,overflow:`hidden`,bg:`var(--pane-fill, var(--card))`,borderWidth:1,borderColor:`var(--pane-edge, var(--border))`,children:[(0,H.jsx)(wt,{display:`none`,children:r(`Settings`)}),(0,H.jsxs)(y,{flex:1,minH:0,width:`100%`,children:[(0,H.jsxs)(z,{width:236,shrink:0,height:`100%`,bg:`var(--side-fill, var(--background))`,borderRightWidth:1,borderColor:`var(--pane-edge, var(--border))`,"$max-md":{width:184},children:[(0,H.jsx)(y,{px:12,pt:12,pb:8,shrink:0,children:(0,H.jsxs)(y,{flex:1,height:32,px:10,gap:7,items:`center`,rounded:8,bg:`var(--surface-card-emphasis)`,borderWidth:1,borderColor:`var(--pane-edge, var(--border))`,children:[(0,H.jsx)(uK,{size:13,color:`var(--muted-foreground)`,"aria-hidden":!0}),(0,H.jsx)(j_,{unstyled:!0,value:o,onChange:e=>s(e.target.value),placeholder:r(`Search settings`),"aria-label":r(`Search settings`),flex:1,minW:0,fontSize:13,color:`var(--foreground)`,placeholderTextColor:`$placeholderColor`})]})}),(0,H.jsx)(z,{flex:1,minH:0,px:8,pb:12,overflowY:`auto`,overflowX:`hidden`,children:(0,H.jsx)(FK,{active:i,filter:o,onPick:e=>{if(e.href){window.open(e.href,`_blank`,`noopener,noreferrer`);return}a(e.id)},onBack:()=>t(!1)})})]}),(0,H.jsxs)(z,{flex:1,minW:0,minH:0,height:`100%`,bg:`var(--pane-fill, var(--card))`,position:`relative`,children:[(0,H.jsx)(y,{position:`absolute`,t:12,r:14,z:5,children:(0,H.jsx)(y,{render:`button`,type:`button`,"aria-label":r(`Close`),onClick:()=>t(!1),width:32,height:32,rounded:999,items:`center`,justify:`center`,bg:`var(--surface-card-emphasis)`,borderWidth:1,borderColor:`var(--pane-edge, var(--border))`,cursor:`pointer`,hoverStyle:{bg:`var(--secondary)`},children:(0,H.jsx)(bK,{size:15,color:`var(--foreground)`,"aria-hidden":!0})})}),(0,H.jsx)(Lre,{id:i})]})]})]})})}_W({site:`https://hanzo.ai`,home:`/`,brand:`Hanzo Team`,signUp:`/start`});var O8=new Set,k8=null;function A8(e=`general`){k8=e;for(let e of O8)e(k8)}function j8(){k8=null;for(let e of O8)e(null)}function Yre(e){return e===`ai`?`model`:e===`account`?`account`:`general`}function Xre(e){let t=(0,V.useMemo)(()=>WB(),[]),{current:n}=nH(),[r,i]=(0,V.useState)(k8);return(0,V.useEffect)(()=>{n?.org&&kG(n.org)},[n?.org]),(0,V.useEffect)(()=>{let e=e=>i(e);O8.add(e);let t=e=>{(e.metaKey||e.ctrlKey)&&e.key===`,`?(e.preventDefault(),A8(k8??`general`)):e.key===`Escape`&&k8&&j8()};return window.addEventListener(`keydown`,t),()=>{O8.delete(e),window.removeEventListener(`keydown`,t)}},[]),(0,H.jsx)(uW,{config:t,children:(0,H.jsx)(D8,{open:r!==null,onOpenChange:e=>{e||j8()},initialSection:r?Yre(r):`general`})})}var Zre=`with-`,M8=e=>`/bots?bot=${encodeURIComponent(e.name)}`,N8=e=>e?.startsWith(Zre)?e.slice(5):void 0,P8=e=>e.filter(e=>e.bot&&!e.gone).sort((e,t)=>e.name.localeCompare(t.name)),F8=(e,t)=>e.kind===`direct`?t.find(t=>t.bot&&e.members.includes(t.id)):void 0,I8={project:`tracker:class:Project`,issue:`tracker:class:Issue`,status:`tracker:class:IssueStatus`,milestone:`tracker:class:Milestone`,component:`tracker:class:Component`,person:`contact:class:Person`,channel:`chunter:class:Channel`,direct:`chunter:class:DirectMessage`,message:`chunter:class:ChatMessage`,reply:`chunter:class:ThreadMessage`,reaction:`activity:class:Reaction`,notice:`notification:class:ActivityInboxNotification`,tag:`tags:class:TagReference`},L8={create:`core:class:TxCreateDoc`,update:`core:class:TxUpdateDoc`,remove:`core:class:TxRemoveDoc`},R8={backlog:`tracker:issueStatusCategory:Backlog`,todo:`tracker:issueStatusCategory:Unstarted`,doing:`tracker:issueStatusCategory:Started`,done:`tracker:issueStatusCategory:Completed`,cancelled:`tracker:issueStatusCategory:Cancelled`},z8={none:0,urgent:1,high:2,medium:3,low:4},B8=e=>{let t=e?.name??``;if(!t.includes(`,`))return t.trim();let[n,r]=t.split(`,`);return[r,n].map(e=>e?.trim()).filter(Boolean).join(` `)},Qre=(e,t)=>e?`${e.identifier}-${t.number}`:`#${t.number}`,V8=(e,...t)=>[e,...t.map(e=>e??``)].join(`|`),$re=e=>(eie(e)?tie(e):e).replace(/<\/(p|div|li|h[1-6])>|<br\s*\/?>/gi,`
|
|
187
|
+
`).replace(/<[^>]*>/g,``).split(`
|
|
188
|
+
`).map(e=>aie(e).trim()).filter(e=>e!==``),eie=e=>e.trimStart().startsWith(`{"type"`),tie=e=>{let t;try{t=JSON.parse(e)}catch{return e}let n=e=>e.type===`reference`?`@${e.attrs?.label??``}`:(e.text??``)+(e.content??[]).map(n).join(``);return(t.content??[]).map(e=>`<p>${U8(n(e))}</p>`).join(``)},H8=(e,t=[])=>nie(e,t)??rie(e),nie=(e,t)=>{let n=new Map;for(let e of t)e.name.trim()&&n.set(e.name.trim().toLowerCase(),e);if(n.size===0)return null;let r=!1,i=e.replace(/\r\n/g,`
|
|
189
|
+
`).split(`
|
|
190
|
+
`).map(e=>e.trimEnd()).filter(e=>e!==``).map(e=>{let t=[],i=0;for(let a of e.matchAll(/(?<![\w.@-])@([\w.-]+)/g)){let o=n.get(a[1].replace(/[.-]+$/,``).toLowerCase());if(!o)continue;let s=a.index+1+a[1].replace(/[.-]+$/,``).length;a.index>i&&t.push({type:`text`,text:e.slice(i,a.index)}),t.push({type:`reference`,attrs:{id:`person-${o.id}`,objectclass:`contact:class:Person`,label:o.name}}),i=s,r=!0}return i<e.length&&t.push({type:`text`,text:e.slice(i)}),{type:`paragraph`,content:t}});return r?JSON.stringify({type:`doc`,content:i}):null},rie=e=>e.replace(/\r\n/g,`
|
|
191
|
+
`).split(`
|
|
192
|
+
`).map(e=>e.trimEnd()).filter(e=>e!==``).map(e=>`<p>${U8(e)}</p>`).join(``)||`<p></p>`,iie={"&":`&`,"<":`<`,">":`>`,""":`"`,"'":`'`,""":`"`," ":` `},aie=e=>e.replace(/&(?:amp|lt|gt|quot|nbsp|#39|#34);/g,e=>iie[e]??e),U8=e=>e.replace(/[&<>"']/g,e=>`&${{"&":`amp`,"<":`lt`,">":`gt`,'"':`quot`,"'":`#39`}[e]};`),oie=/(?<![\w.@-])(@[\w.-]+)|(https?:\/\/[^\s<>()]+)/g,sie=e=>{let t=[],n=0;for(let r of e.matchAll(oie)){let i=r.index;i>n&&t.push({kind:`text`,value:e.slice(n,i)}),t.push(r[1]?{kind:`mention`,value:r[1]}:{kind:`link`,value:r[2]}),n=i+r[0].length}return n<e.length&&t.push({kind:`text`,value:e.slice(n)}),t},W8={channel:I8.channel,direct:I8.direct,message:I8.message,reply:I8.reply,reaction:I8.reaction,person:I8.person},G8=L8.create,cie=L8.remove,K8=(e,t)=>e.name||e.members.map(e=>t.find(t=>t.id===e)?.name).filter(e=>!!e).join(`, `),q8=e=>typeof e==`string`?e:``,J8=e=>typeof e==`number`?e:0,lie=async e=>{let[t,n]=await Promise.all([e.find(W8.channel),e.find(W8.direct)]);return[...t.map(e=>Y8(e,`channel`)),...n.map(e=>Y8(e,`direct`))].filter(e=>!e.archived)},uie=e=>{let t=new Set;if(Array.isArray(e.bindings))for(let n of e.bindings)typeof n==`string`&&n.startsWith(`connect:`)&&t.add(n.slice(8));let n=q8(e.topic)||q8(e.description);for(let e of n.matchAll(/connect:([a-z0-9_-]+)/gi))e[1]&&t.add(e[1].toLowerCase());let r=q8(e.name).match(/^[a-z0-9]+-x-([a-z0-9_-]+)$/i);return r?.[1]&&t.add(r[1].toLowerCase()),t.size>0?[...t]:void 0},Y8=(e,t)=>({id:q8(e._id),kind:t,name:q8(e.name),topic:q8(e.topic)||void 0,private:e.private===!0,archived:e.archived===!0,members:Array.isArray(e.members)?e.members.filter(e=>typeof e==`string`):[],connectedOrgs:uie(e)}),die=async(e,t)=>(await e.find(W8.message,{attachedTo:t})).map(e=>Z8(e,t)).sort(X8),X8=(e,t)=>e.at-t.at||(e.id<t.id?-1:1),Z8=(e,t)=>({id:q8(e._id),room:t,author:q8(e.createdBy)||q8(e.modifiedBy),lines:$re(q8(e.message)),at:J8(e.createdOn)||J8(e.modifiedOn),replies:J8(e.replies),pinned:e.isPinned===!0}),fie=async(e,t)=>(await e.find(W8.reply,{attachedTo:t})).map(e=>({...pie(e),room:t})).sort(X8),pie=e=>Z8(e,q8(e.attachedTo)),mie=async(e,t)=>t.length===0?[]:(await e.find(W8.reaction,{attachedTo:{$in:t}})).map(e=>({id:q8(e._id),message:q8(e.attachedTo),emoji:q8(e.emoji),by:q8(e.createBy)||q8(e.createdBy)})),hie=e=>B8({name:e}).replace(/\s+/g,` `),gie=e=>{let t=e[`contact:mixin:Employee`];return q8(e.position)||(t&&typeof t==`object`?q8(t.position):``)},_ie=e=>{let t=e[`contact:mixin:Employee`],n=t&&typeof t==`object`?t.active:e.active;return typeof n==`boolean`?n:void 0},vie=async e=>(await e.find(W8.person)).map(e=>({id:q8(e.personUuid)||q8(e._id),name:hie(q8(e.name)),avatar:q8(e.avatar)||void 0,bot:gie(e)===`Agent`||void 0,gone:_ie(e)===!1||void 0})),yie=(e,t,n,r=[])=>e.write(e5(t5(),W8.message,t.id,t.id,Q8(t),`messages`,$8(e),{message:H8(n,r)})),bie=(e,t,n,r,i=[])=>e.write(e5(t5(),W8.reply,t.id,n.id,W8.message,`replies`,$8(e),{message:H8(r,i),objectId:t.id,objectClass:Q8(t)})),xie=(e,t,n,r)=>e.write(e5(t5(),W8.reaction,t.id,n.id,W8.message,`reactions`,$8(e),{emoji:r})),Sie=(e,t,n)=>e.write({_class:cie,objectId:n.id,objectClass:W8.reaction,objectSpace:t.id,modifiedBy:$8(e),modifiedOn:Date.now()}),Cie=async(e,t,n,r)=>{let i=t.trim().replace(/^#+/,``).toLowerCase().replace(/[^a-z0-9_-]+/g,`-`),a=n.map(e=>e.trim().toLowerCase().replace(/[^a-z0-9_-]+/g,``)).filter(Boolean),o=`connect-${i}-${t5().slice(0,8)}`,s=Date.now(),c=$8(e),l=a.map(e=>`connect:${e}`),u=[r?.trim(),...l].filter(Boolean).join(` · `);return await e.write({_class:G8,objectId:o,objectClass:W8.channel,objectSpace:`core:space:Space`,modifiedBy:c,modifiedOn:s,createdBy:c,createdOn:s,attributes:{name:i,topic:u,description:u,private:!1,archived:!1,members:c?[c]:[],owners:c?[c]:[],life:`standing`,bindings:l}}),o},Q8=e=>e.kind===`direct`?W8.direct:W8.channel,$8=e=>e.account??``,e5=(e,t,n,r,i,a,o,s)=>{let c=Date.now();return{_class:G8,objectId:e,objectClass:t,objectSpace:n,modifiedBy:o,modifiedOn:c,createdBy:o,createdOn:c,attributes:s,attachedTo:r,attachedToClass:i,collection:a}},t5=()=>[...crypto.getRandomValues(new Uint8Array(16))].map(e=>e.toString(16).padStart(2,`0`)).join(``),wie=(e,t)=>e.some(e=>{let n=q8(e.objectClass);return n!==W8.message&&n!==W8.reaction&&n!==W8.reply?!1:q8(e.objectSpace)===t||q8(e.attachedTo)===t||n!==W8.message}),n5=()=>{let{plane:e,current:t}=nH();return cV(`chat:rooms:${t?.uuid??`-`}`,()=>e?lie(e):Promise.resolve([]),{enabled:!!e})},Tie=e=>{let{plane:t}=nH();return cV(`chat:messages:${e??`-`}`,()=>t&&e?die(t,e):Promise.resolve([]),{enabled:!!(t&&e)})},Eie=e=>{let{plane:t}=nH();return cV(`chat:reactions:${e.join(`,`).slice(0,200)}:${e.length}`,()=>t?mie(t,e):Promise.resolve([]),{enabled:!!t&&e.length>0})},Die=e=>{let{plane:t}=nH();return cV(`chat:replies:${e??`-`}`,()=>t&&e?fie(t,e):Promise.resolve([]),{enabled:!!(t&&e)})},r5=()=>{let{plane:e,current:t}=nH();return cV(`chat:people:${t?.uuid??`-`}`,()=>e?vie(e):Promise.resolve([]),{enabled:!!e})},Oie=e=>{let{plane:t}=nH();(0,V.useEffect)(()=>{if(t&&e)return t.watch(t=>{wie(t,e)&&(lV(`chat:messages:${e}`),lV(`chat:reactions:`),lV(`chat:replies:`))})},[t,e])},i5=(e,t)=>{let n=t.startsWith(`hanzo:`)?t.slice(6):t;return e.find(e=>e.id===n||e.id===t)?.name||kie(n)},kie=e=>(e.length>12?`${e.slice(0,8)}…`:e)||`Someone`,Aie=e=>e.split(/[\s._-]+/).filter(Boolean).slice(0,2).map(e=>e[0].toUpperCase()).join(``)||`?`;function a5(e,t){return e?.trim()?e.trim():(t?.split(`@`)[0])?.trim()||``}function jie(e,t){let n=a5(e,t).replace(/,/g,` `).trim();if(!n)return`HZ`;let r=n.split(/\s+/).filter(Boolean);return r.length>=2?`${r[0][0]??``}${r[r.length-1][0]??``}`.toUpperCase():n.slice(0,2).toUpperCase()}var Mie=[{id:`chat`,label:`Chat — Channels & threads`,desc:`Workspace channels, threads & teammates`,path:`/chat`},{id:`issues`,label:`Tracker — All issues`,desc:`Kanban board, list & project issues`,path:`/issues`},{id:`projects`,label:`Projects`,desc:`Every project in this space`,path:`/projects`},{id:`crm`,label:`CRM`,desc:`Investors, contacts & pipeline`,path:`/crm/investors`}];function Nie({currentOrg:e,navSpan:t,navOpen:n=!1,onToggleNav:r,surfaceTitle:i,leftSlot:a,children:o,rightSlot:s,onNavigate:c}){let[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(``),[p,m]=(0,V.useState)(()=>typeof window>`u`?1200:window.innerWidth),h=p<680,g=e?.displayName?.trim()||e?.name||`Hanzo AI`;(0,V.useEffect)(()=>{let e=e=>{(e.metaKey||e.ctrlKey)&&e.key.toLowerCase()===`k`&&(e.preventDefault(),u(e=>!e))};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[]);let _=r5().data??[],v=n5().data??[],b=(0,V.useMemo)(()=>{let e=d.trim().toLowerCase(),t=P8(_).map(e=>({id:`bot-${e.id}`,kind:`bot`,label:e.name,desc:`Agent`,path:M8(e)})),n=v.filter(e=>e.kind===`channel`).map(e=>({id:e.id,kind:`channel`,label:`#${e.name}`,desc:e.topic??``,path:`/chat/${e.id}`})),r=[...Mie.map(e=>({...e,kind:`surface`})),...n,...t];return e?r.filter(t=>t.label.toLowerCase().includes(e)||t.desc.toLowerCase().includes(e)).slice(0,14):r.slice(0,12)},[d,_,v]),x=e=>{u(!1),f(``),c?c(e):typeof window<`u`&&window.location.assign(e)};return(0,H.jsxs)(y,{render:`header`,height:36,items:`center`,borderBottomWidth:1,shrink:0,style:{backgroundColor:X.bar,borderBottomColor:X.barRule},onLayout:e=>m(e.nativeEvent.layout.width),"data-testid":`hanzo-business-header`,children:[(0,H.jsxs)(y,{height:`100%`,width:n&&t?48+t:void 0,minW:n&&t?48+t:void 0,pl:11,pr:8,gap:2,items:`center`,borderRightWidth:n&&t?1:0,shrink:0,style:{borderRightColor:X.barRule},children:[a,r?(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,width:26,height:26,rounded:6,items:`center`,justify:`center`,hoverStyle:{bg:`$color3`},"aria-label":n?`Collapse sidebar`:`Expand sidebar`,"data-testid":`toggle-team-sidebar`,onPress:r,children:(0,H.jsx)(fm,{size:15,color:`$color10`})}):null,h?null:(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,width:26,height:26,rounded:6,items:`center`,justify:`center`,hoverStyle:{bg:`$color3`},"aria-label":`Go back`,onPress:()=>{typeof window<`u`&&window.history.back()},children:(0,H.jsx)(mp,{size:14,color:`$color10`})}),(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,width:26,height:26,rounded:6,items:`center`,justify:`center`,hoverStyle:{bg:`$color3`},"aria-label":`Go forward`,onPress:()=>{typeof window<`u`&&window.history.forward()},children:(0,H.jsx)(hp,{size:14,color:`$color10`})})]})]}),(0,H.jsxs)(y,{flex:1,height:`100%`,pl:12,pr:12,gap:`$2`,items:`center`,justify:`space-between`,minW:0,children:[(0,H.jsxs)(y,{items:`center`,gap:6,minW:0,shrink:1,children:[(0,H.jsx)(U,{fontSize:12.5,fontWeight:`600`,color:`$color11`,numberOfLines:1,children:g}),i&&!h?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(U,{fontSize:12,color:`$color9`,children:`/`}),(0,H.jsx)(U,{fontSize:12.5,fontWeight:`500`,color:`$color10`,numberOfLines:1,children:i})]}):null]}),(0,H.jsxs)(y,{items:`center`,justify:`flex-end`,gap:`$1.5`,minW:0,shrink:0,children:[o??(0,H.jsxs)(pt,{open:l,onOpenChange:u,placement:`bottom-end`,allowFlip:!0,stayInFrame:!0,children:[(0,H.jsx)(pt.Trigger,{asChild:!0,children:(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,width:h?28:240,maxW:h?28:`38vw`,height:25,px:h?0:`$2`,rounded:7,borderWidth:1,items:`center`,justify:h?`center`:`space-between`,style:{backgroundColor:X.sidebar,borderColor:X.sidebarRule},hoverStyle:{bg:`$color3`},"aria-label":`Search ${g}`,"data-testid":`slack-top-search-trigger`,children:h?(0,H.jsx)(vm,{size:13,color:`$color10`}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,minW:0,flex:1,children:[(0,H.jsx)(vm,{size:12,color:`$color10`}),(0,H.jsx)(U,{fontSize:12,color:`$color10`,numberOfLines:1,children:`Search ${g}…`})]}),(0,H.jsx)(U,{fontSize:10,fontWeight:`600`,color:`$color9`,px:`$1`,py:1,rounded:`$1`,children:`⌘K`})]})})}),(0,H.jsx)(pt.Content,{role:`dialog`,"aria-label":`Jump to channel, bot, or surface`,borderWidth:1,elevation:`$4`,p:`$2`,width:460,bg:`$background`,borderColor:`$borderColor`,rounded:`$4`,style:{zIndex:1e5},children:(0,H.jsxs)(z,{gap:`$2`,width:`100%`,children:[(0,H.jsxs)(y,{height:34,px:`$2.5`,items:`center`,gap:`$2`,rounded:`$3`,bg:`$color2`,borderWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(vm,{size:14,color:`$color10`}),(0,H.jsx)(ht,{flex:1,height:30,fontSize:13,borderWidth:0,bg:`transparent`,placeholder:`Jump to a channel, bot or issue board…`,value:d,onChangeText:f,autoFocus:!0})]}),(0,H.jsx)(z,{gap:`$0.5`,maxH:340,style:{overflowY:`auto`},children:b.map(e=>(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2.5`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>x(e.path),children:[(0,H.jsx)(z,{width:24,height:24,rounded:`$2`,bg:`$color3`,items:`center`,justify:`center`,shrink:0,children:e.kind===`bot`?(0,H.jsx)(vp,{size:13,color:`$color11`}):e.kind===`channel`?(0,H.jsx)(Yp,{size:13,color:`$color11`}):(0,H.jsx)(Tm,{size:13,color:`$color11`})}),(0,H.jsxs)(z,{flex:1,minW:0,children:[(0,H.jsx)(U,{fontSize:12,fontWeight:`600`,color:`$color12`,numberOfLines:1,children:e.label}),(0,H.jsx)(U,{fontSize:11,color:`$color10`,numberOfLines:1,children:e.desc})]})]},e.id))})]})})]}),s]})]})]})}function Pie({user:e,currentOrg:t,orgs:n=[],onSelectOrg:r,onCreateOrg:i,onConnectOrg:a,accounts:o=[],onSwitchAccount:s,onAddAccount:c,onSettings:l,onSignOut:u}){let[d,f]=(0,V.useState)(!1),p=t?.displayName?.trim()||t?.name||`Hanzo AI`,m=a5(e?.name,e?.email)||`Account`,h=e?.email||``,g=e?.sub||``,_=(()=>{let n=[],r=new Set;g&&(r.add(g),n.push({sub:g,owner:e?.owner||t?.name||`hanzo`,name:m,email:h||void 0,avatar:e?.avatar}));for(let e of o)e.sub&&!r.has(e.sub)&&(r.add(e.sub),n.push(e));return n})();return(0,H.jsxs)(pt,{open:d,onOpenChange:f,placement:`right-end`,allowFlip:!0,stayInFrame:!0,children:[(0,H.jsx)(pt.Trigger,{asChild:!0,children:(0,H.jsx)(z,{role:`button`,tabIndex:0,cursor:`pointer`,width:32,height:32,rounded:Q.pill,items:`center`,justify:`center`,position:`relative`,hoverStyle:{bg:`$color3`},"aria-label":`${m} · Account & settings`,"aria-haspopup":`menu`,"aria-expanded":d,"data-testid":`rail-account-menu-trigger`,onKeyDown:e=>{(e?.key===`Enter`||e?.key===` `)&&(e.preventDefault?.(),f(!d))},children:e?.avatar?(0,H.jsx)(jZ,{org:{name:m,logo:e.avatar},size:28}):(0,H.jsx)(z,{width:28,height:28,rounded:Q.pill,items:`center`,justify:`center`,style:{backgroundColor:X.avatar},children:(0,H.jsx)(U,{fontSize:11,fontWeight:`600`,style:{color:X.avatarInk},children:jie(e?.name,e?.email)})})})}),(0,H.jsx)(pt.Content,{role:`menu`,"aria-label":`Account menu`,borderWidth:1,elevation:`$4`,p:`$2`,width:300,bg:`$background`,borderColor:`$borderColor`,rounded:`$4`,style:{zIndex:1e5},children:(0,H.jsxs)(z,{gap:`$1`,width:`100%`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2.5`,px:`$2`,py:`$2`,rounded:`$3`,bg:`$color2`,children:[(0,H.jsx)(jZ,{org:{name:m,logo:e?.avatar},size:36}),(0,H.jsxs)(z,{flex:1,minW:0,gap:1,children:[(0,H.jsx)(U,{fontSize:`$3`,fontWeight:`700`,color:`$color12`,numberOfLines:1,children:m}),h&&h!==m?(0,H.jsx)(U,{fontSize:`$1`,color:`$color10`,numberOfLines:1,children:h}):null,(0,H.jsxs)(y,{items:`center`,gap:`$1.5`,mt:2,children:[(0,H.jsx)(z,{width:6,height:6,rounded:Q.pill,style:{backgroundColor:SH.done}}),(0,H.jsxs)(U,{fontSize:11,fontWeight:`600`,color:`$color10`,children:[`Active · `,p]})]})]})]}),(0,H.jsx)(Lc,{borderColor:`$borderColor`,my:`$1`}),(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsxs)(y,{px:`$2`,py:`$1`,items:`center`,justify:`space-between`,children:[(0,H.jsx)(U,{fontSize:`$1`,fontWeight:`700`,color:`$color10`,textTransform:`uppercase`,letterSpacing:.5,children:`Switch account`}),(0,H.jsx)(U,{fontSize:11,color:`$color9`,children:`Identities`})]}),_.map(e=>{let t=!!(g&&e.sub===g),n=e.name||e.email||e.sub;return(0,H.jsxs)(y,{role:`menuitem`,"aria-checked":t,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,bg:t?`$color3`:`transparent`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),t||s?.(e)},children:[(0,H.jsx)(jZ,{org:{name:n,logo:e.avatar},size:24}),(0,H.jsxs)(z,{flex:1,minW:0,children:[(0,H.jsx)(U,{fontSize:`$2`,fontWeight:t?`600`:`500`,color:`$color12`,numberOfLines:1,children:n}),(0,H.jsx)(U,{fontSize:`$1`,color:`$color10`,numberOfLines:1,children:e.email&&e.email!==n?e.email:t?`Current account`:`Identity · ${e.owner}`})]}),t?(0,H.jsx)(Vt,{size:14,color:`$color12`}):null]},e.sub)}),c?(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),c()},children:[(0,H.jsx)(z,{width:24,height:24,rounded:Q.pill,bg:`$color3`,items:`center`,justify:`center`,children:(0,H.jsx)(Pm,{size:13,color:`$color11`})}),(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,color:`$color12`,children:`Add another account`})]}):null]}),(0,H.jsx)(Lc,{borderColor:`$borderColor`,my:`$1`}),(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsxs)(y,{px:`$2`,py:`$1`,items:`center`,justify:`space-between`,children:[(0,H.jsx)(U,{fontSize:`$1`,fontWeight:`700`,color:`$color10`,textTransform:`uppercase`,letterSpacing:.5,children:`Switch organization`}),(0,H.jsx)(U,{fontSize:11,color:`$color9`,children:p})]}),n.slice(0,5).map(e=>{let n=e.name===t?.name,i=e.displayName?.trim()||e.name;return(0,H.jsxs)(y,{role:`menuitem`,"aria-checked":n,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,bg:n?`$color3`:`transparent`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),n||r?.(e.name)},children:[(0,H.jsx)(jZ,{org:{name:i,logo:e.logo},size:20}),(0,H.jsx)(U,{flex:1,fontSize:`$2`,fontWeight:n?`600`:`500`,color:`$color12`,numberOfLines:1,children:i}),n?(0,H.jsx)(Vt,{size:14,color:`$color12`}):null]},e.name)}),i?(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),i()},children:[(0,H.jsx)(z,{width:20,height:20,rounded:Q.field,bg:`$color3`,items:`center`,justify:`center`,children:(0,H.jsx)(hm,{size:12,color:`$color11`})}),(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,color:`$color12`,children:`Create new organization…`})]}):null,a?(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),a()},children:[(0,H.jsx)(z,{width:20,height:20,rounded:Q.field,bg:`$color3`,items:`center`,justify:`center`,children:(0,H.jsx)(bm,{size:12,color:`$color11`})}),(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,color:`$color12`,children:`Hanzo Connect (share channel)…`})]}):null]}),(0,H.jsx)(Lc,{borderColor:`$borderColor`,my:`$1`}),(0,H.jsxs)(z,{gap:`$0.5`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,px:`$2`,py:`$1.5`,rounded:`$3`,children:[(0,H.jsx)(U,{fontSize:`$2`,color:`$color12`,children:`Theme`}),(0,H.jsx)(RZ,{})]}),l?(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),l()},children:[(0,H.jsx)(ym,{size:15,color:`$color10`}),(0,H.jsx)(U,{flex:1,fontSize:`$2`,color:`$color12`,children:`Settings & Preferences`}),(0,H.jsx)(U,{fontSize:11,color:`$color9`,children:`⌘,`})]}):null]}),u?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(Lc,{borderColor:`$borderColor`,my:`$1`}),(0,H.jsxs)(y,{role:`menuitem`,tabIndex:0,cursor:`pointer`,items:`center`,gap:`$2.5`,px:`$2`,py:`$1.5`,rounded:`$3`,hoverStyle:{bg:`$color3`},onPress:()=>{f(!1),u()},children:[(0,H.jsx)(rm,{size:15,color:X.alert}),(0,H.jsx)(U,{fontSize:`$2`,fontWeight:`500`,style:{color:X.alert},children:`Sign out`})]})]}):null]})})]})}var o5=(e,t)=>({role:`button`,tabIndex:0,cursor:`pointer`,...t?{"aria-label":t}:{},onPress:e,onKeyDown:t=>{(t.nativeEvent.key===`Enter`||t.nativeEvent.key===` `)&&(t.preventDefault(),e())}}),s5=new Set,c5=null,l5=(e=`connect`)=>{c5=e;for(let e of s5)e(c5)},u5=()=>{c5=null;for(let e of s5)e(null)};function Fie(){let[e,t]=(0,V.useState)(c5),n=xi(),{all:r,current:i,plane:o}=nH(),[s,c]=(0,V.useState)(`lux`),[l,u]=(0,V.useState)(``),[d,f]=(0,V.useState)(`hanzo-x-lux`),[p,m]=(0,V.useState)(`Cross-organization engineering, shared agents & delivery`),[h,g]=(0,V.useState)(!1);(0,V.useEffect)(()=>{let e=e=>t(e);return s5.add(e),()=>{s5.delete(e)}},[]);let _=i?.url??`hanzo`,v=i?.name??`Hanzo AI`,b=r.filter(e=>e.url!==_),x=(l.trim()||s||`partner`).toLowerCase().replace(/[^a-z0-9-]+/g,`-`).replace(/^-|-$/g,``);if((0,V.useEffect)(()=>{x&&f(`${_}-x-${x}`)},[_,x]),!e)return null;let S=async()=>{if(!o||h)return;let e=x||`partner`,t=d.trim().toLowerCase().replace(/^#+/,``).replace(/[^a-z0-9-]+/g,`-`).replace(/^-|-$/g,``)||`${_}-x-${e}`;g(!0);try{let r=await Cie(o,t,[e],p);lV(`chat:rooms:`),u5(),n(`/chat/${r}`)}finally{g(!1)}};return(0,H.jsx)(z,{position:`fixed`,t:0,l:0,r:0,b:0,z:1e5,items:`center`,justify:`center`,p:16,style:{backgroundColor:`var(--team-backdrop, rgba(0, 0, 0, 0.65))`,backdropFilter:`blur(4px)`},onPress:()=>u5(),children:(0,H.jsxs)(z,{width:`100%`,maxW:520,rounded:Q.card,bg:`$panel`,borderWidth:1,borderColor:`$edge`,p:20,gap:16,onPress:e=>e.stopPropagation?.(),"data-testid":`hanzo-connect-modal`,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:12,children:[(0,H.jsxs)(y,{items:`center`,gap:10,children:[(0,H.jsx)(z,{width:32,height:32,rounded:Q.field,bg:`$background`,borderWidth:1,borderColor:`$edge`,items:`center`,justify:`center`,children:(0,H.jsx)(bm,{size:16,color:`$ink`})}),(0,H.jsxs)(z,{children:[(0,H.jsx)(a,{fontSize:Z.row,fontWeight:`700`,color:`$ink`,children:`Hanzo Connect`}),(0,H.jsx)(a,{fontSize:Z.chip,color:`$soft`,children:`Multi-org shared channels & isolated organization workspaces`})]})]}),(0,H.jsx)(y,{...o5(()=>u5(),`Close Hanzo Connect modal`),px:8,py:4,rounded:Q.field,hoverStyle:{background:`$hover`},children:(0,H.jsx)(a,{fontSize:Z.body,color:`$soft`,children:`✕`})})]}),(0,H.jsx)(y,{bg:`$background`,p:3,rounded:Q.field,borderWidth:1,borderColor:`$edge`,gap:4,children:(0,H.jsxs)(y,{flex:1,...o5(()=>t(`connect`),`Connect organizations tab`),py:7,px:10,rounded:Q.field,items:`center`,justify:`center`,gap:6,bg:e===`connect`?`$panel`:`transparent`,children:[(0,H.jsx)(bm,{size:14,color:e===`connect`?`$ink`:`$soft`}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:e===`connect`?`600`:`500`,color:e===`connect`?`$ink`:`$soft`,children:`Connect Orgs (Shared Channel)`})]})}),(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(z,{gap:14,children:[(0,H.jsxs)(y,{p:12,rounded:Q.field,bg:`$background`,borderWidth:1,borderColor:`$edge`,items:`center`,justify:`space-between`,gap:8,children:[(0,H.jsxs)(z,{gap:2,children:[(0,H.jsx)(a,{fontSize:Z.chip,color:`$faint`,children:`HOST ORGANIZATION`}),(0,H.jsxs)(a,{fontSize:Z.body,fontWeight:`700`,color:`$ink`,children:[v,` (`,_,`)`]})]}),(0,H.jsxs)(y,{px:8,py:3,rounded:Q.pill,bg:`$panel`,borderWidth:1,borderColor:`$edge`,items:`center`,gap:5,children:[(0,H.jsx)(qp,{size:12,color:`$ink`}),(0,H.jsxs)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$ink`,children:[`connect:`,x||`org`]})]}),(0,H.jsxs)(z,{gap:2,items:`flex-end`,children:[(0,H.jsx)(a,{fontSize:Z.chip,color:`$faint`,children:`PARTNER ORGANIZATION`}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`700`,color:`$ink`,children:x||`partner`})]})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$quiet`,children:`Select or enter partner organization slug`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:b.map(e=>{let t=!l.trim()&&s===e.url;return(0,H.jsxs)(y,{...o5(()=>{u(``),c(e.url)},`Select ${e.name}`),px:10,py:5,rounded:Q.pill,bg:t?`$ink`:`$background`,borderWidth:1,borderColor:t?`$ink`:`$edge`,items:`center`,gap:5,children:[t?(0,H.jsx)(Vt,{size:12,color:`$background`}):null,(0,H.jsxs)(a,{fontSize:Z.chip,fontWeight:`600`,color:t?`$background`:`$ink`,children:[e.name,` (`,e.url,`)`]})]},e.url)})}),(0,H.jsx)(y,{px:10,py:6,rounded:Q.field,bg:`$background`,borderWidth:1,borderColor:`$edge`,children:(0,H.jsx)(`input`,{value:l,onChange:e=>u(e.target.value),placeholder:`Or enter external organization slug (e.g. acme, skully, partner)...`,style:{width:`100%`,border:`none`,background:`transparent`,color:`inherit`,fontSize:13,outline:`none`}})})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$quiet`,children:`Shared channel name`}),(0,H.jsxs)(y,{items:`center`,gap:6,px:10,py:6,rounded:Q.field,bg:`$background`,borderWidth:1,borderColor:`$edge`,children:[(0,H.jsx)(Yp,{size:14,color:`$soft`}),(0,H.jsx)(`input`,{value:d,onChange:e=>f(e.target.value),placeholder:`hanzo-x-partner`,style:{flex:1,border:`none`,background:`transparent`,color:`inherit`,fontSize:13,outline:`none`}})]})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$quiet`,children:`Channel purpose & agent scope`}),(0,H.jsx)(y,{px:10,py:6,rounded:Q.field,bg:`$background`,borderWidth:1,borderColor:`$edge`,children:(0,H.jsx)(`input`,{value:p,onChange:e=>m(e.target.value),placeholder:`Cross-org engineering, shared agents & delivery`,style:{width:`100%`,border:`none`,background:`transparent`,color:`inherit`,fontSize:13,outline:`none`}})})]}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$soft`,children:[`Both organizations keep strict tenant isolation (separate IAM, KMS secrets, private repos, and billing) while humans and AI agents (@vi, @dev, @mark) collaborate in real time inside #`,d||`${_}-x-${x}`,`.`]}),(0,H.jsxs)(y,{justify:`flex-end`,gap:8,pt:4,children:[(0,H.jsx)(y,{...o5(()=>u5(),`Cancel`),px:12,py:8,rounded:Q.field,borderWidth:1,borderColor:`$edge`,children:(0,H.jsx)(a,{fontSize:Z.body,color:`$quiet`,children:`Cancel`})}),(0,H.jsxs)(y,{...o5(()=>void S(),`Connect and create shared channel`),px:14,py:8,rounded:Q.field,bg:`$ink`,items:`center`,gap:6,children:[(0,H.jsx)(bm,{size:14,color:`$background`}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`600`,color:`$background`,children:h?`Connecting…`:`Connect & Share Channel`})]})]})]})})]})})}var d5=e=>{let t=e,n=new Set;return{set:e=>{if(e!==t){t=e;for(let e of n)e()}},use:()=>(0,V.useSyncExternalStore)(e=>(n.add(e),()=>n.delete(e)),()=>t,()=>e)}},f5=d5(0),p5=d5(null),Iie=f5.set,m5=f5.use,Lie=p5.set;p5.use;var h5=[{id:`chat`,label:`Chat`,icon:lm,path:`/chat`},{id:`bots`,label:`Bots`,icon:vp,path:`/bots`},{id:`tracker`,label:`Tracker`,icon:Tm,path:`/issues`},{id:`crm`,label:`CRM`,icon:bp,path:`/crm`}],g5=e=>h5.find(t=>e===t.path||e.startsWith(`${t.path}/`)||t.id===`tracker`&&(e===`/mine`||e.startsWith(`/mine/`)||e===`/projects`||e===`/projects/`||e.startsWith(`/projects/`))),_5={outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},v5={backgroundColor:X.railActive},Rie={background:X.alert},zie=({notices:e,onNotices:t,onSurface:n,account:r})=>{let{pathname:i}=yi(),o=m5(),s=r?.orgs&&r.orgs.length>0?r.orgs:r?.currentOrg?.name||r?.currentOrg?.displayName?[r.currentOrg]:[];return(0,H.jsxs)(z,{width:48,shrink:0,height:`100%`,items:`center`,justify:`space-between`,pt:6,pb:8,borderRightWidth:1,style:{backgroundColor:X.rail,borderRightColor:X.railRule},"data-parity-key":`shell.rail`,children:[(0,H.jsx)(G_,{flex:1,minH:0,width:`100%`,children:(0,H.jsxs)(z,{items:`center`,width:`100%`,gap:4,children:[s.length>0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(z,{items:`center`,width:`100%`,gap:5,"data-parity-key":`shell.orgs`,children:[s.slice(0,5).map(e=>{let t=e.name===r?.currentOrg?.name||s.length===1,n=e.displayName?.trim()||e.name||`Workspace`;return(0,H.jsxs)(Ym,{children:[(0,H.jsx)(Xm,{children:(0,H.jsxs)(z,{...o5(()=>r?.onSelectOrg?.(e.name),`${n} organization`),width:32,height:32,rounded:9,items:`center`,justify:`center`,position:`relative`,style:t?v5:void 0,hoverStyle:t?void 0:{background:`$hover`},focusVisibleStyle:_5,children:[t?(0,H.jsx)(z,{position:`absolute`,l:-6,width:3,height:16,rounded:Q.pill,style:{backgroundColor:X.railFgActive}}):null,(0,H.jsx)(jZ,{org:{name:n,logo:e.logo},size:22})]})}),(0,H.jsx)(Qm,{children:n})]},e.name||n)}),r?.onConnectOrg?(0,H.jsxs)(Ym,{children:[(0,H.jsx)(Xm,{children:(0,H.jsx)(z,{...o5(r.onConnectOrg,`Connect or switch organization`),width:28,height:28,rounded:8,items:`center`,justify:`center`,hoverStyle:{background:`$hover`},focusVisibleStyle:_5,children:(0,H.jsx)(hm,{size:15,color:X.railFg})})}),(0,H.jsx)(Qm,{children:`Connect organization`})]}):null]}),(0,H.jsx)(y5,{})]}):null,(0,H.jsxs)(b5,{label:o>0?`${e?`Hide`:`Show`} Activity (${o} unread)`:e?`Hide Activity`:`Show Activity`,pressed:e,onPress:t,children:[(0,H.jsx)(_p,{size:18,color:e?X.railFgActive:X.railFg}),o>0?(0,H.jsx)(z,{position:`absolute`,t:2,r:2,minW:14,height:14,px:3,rounded:Q.pill,items:`center`,justify:`center`,style:Rie,children:(0,H.jsx)(a,{fontSize:9,lineHeight:11,fontWeight:`700`,style:{color:X.panel},children:o})}):null]}),(0,H.jsx)(y5,{}),h5.map(e=>{let t=g5(i)?.id===e.id;return(0,H.jsx)(b5,{label:e.label,here:t,onPress:()=>n(e.path),children:(0,H.jsx)(e.icon,{size:18,color:t?X.railFgActive:X.railFg})},e.id)})]})}),(0,H.jsxs)(z,{items:`center`,width:`100%`,gap:6,pt:6,children:[r?.onSettings?(0,H.jsx)(b5,{label:`Preferences (⌘,)`,onPress:r.onSettings,children:(0,H.jsx)(Sm,{size:16,color:X.railFg})}):null,(0,H.jsx)(Pie,{...r})]})]})},y5=()=>(0,H.jsx)(Lc,{width:28,my:4,borderColor:`$edge`}),b5=({label:e,here:t=!1,pressed:n,onPress:r,children:i})=>{let a=!!(t||n);return(0,H.jsxs)(Ym,{children:[(0,H.jsx)(Xm,{children:(0,H.jsx)(z,{...o5(r,e),"aria-current":t?`page`:void 0,"aria-pressed":n,width:32,height:32,items:`center`,justify:`center`,position:`relative`,rounded:8,style:a?v5:void 0,hoverStyle:a?void 0:{background:`$hover`},focusVisibleStyle:_5,children:i})}),(0,H.jsx)(Qm,{children:e})]})},x5=({nav:e,children:t,aside:n})=>{let{pathname:r}=yi(),i=xi(),{who:a,leave:o,depart:s}=pV(),{all:c,current:l,choose:u}=nH(),[d,f]=(0,V.useState)(()=>typeof window>`u`?bH:window.innerWidth),[p,m]=(0,V.useState)(220),[h,g]=(0,V.useState)(!1),[_,v]=(0,V.useState)(!1),[b,x]=(0,V.useState)(!1),S=vH(),C=yH(),w=d>=bH,T=d>=800,E=!!(T&&e&&!h),D=t=>{if(!T&&e&&(r===t||r.startsWith(`${t}/`)))return v(!0);if(T&&e&&h&&(r===t||r.startsWith(`${t}/`))){g(!1);return}i(t)},O=c,k=l??O[0],A=a?{sub:a.id,name:a.label||a.name,email:a.email,avatar:a.avatar,owner:k?.org??``}:{sub:``,name:``,email:``,owner:``},j={name:k?.url??``,displayName:k?.name??``},ee=O.map(e=>({name:e.url,displayName:e.name}));return(0,H.jsxs)(nv,{bg:`$background`,children:[(0,H.jsx)(Nie,{currentOrg:j,onNavigate:D,navSpan:p+1,navOpen:E,onToggleNav:e?()=>{T?g(e=>!e):v(e=>!e)}:void 0,surfaceTitle:g5(r)?.label}),(0,H.jsxs)(y,{flex:1,minH:0,onLayout:e=>f(e.nativeEvent.layout.width),children:[(0,H.jsx)(zie,{notices:!!n&&(w?S&&C===`inbox`:b),onNotices:()=>{w?gH(`inbox`):(hH(`inbox`),x(!b))},onSurface:D,account:{user:A,currentOrg:j,orgs:ee,onSelectOrg:e=>u(e),onConnectOrg:()=>l5(`connect`),onAddAccount:()=>void s(`another`),onSettings:()=>A8(`general`),onSignOut:()=>o()}}),E?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(z,{width:p,shrink:0,minH:0,style:{backgroundColor:X.sidebar},"data-parity-key":`shell.nav`,children:e}),(0,H.jsx)(Bie,{value:p,onChange:m})]}):null,(0,H.jsxs)(y,{flex:1,minW:0,minH:0,pt:0,pb:0,pr:0,gap:0,children:[(0,H.jsx)(S5,{parity:`shell.main`,children:t}),n&&S&&w?(0,H.jsx)(z,{width:284,shrink:0,borderLeftWidth:1,style:{borderLeftColor:X.sidebarRule},children:(0,H.jsx)(S5,{parity:`shell.aside`,children:n})}):null]})]}),(0,H.jsx)(nC,{open:!!n&&!w&&b,onOpenChange:x,children:(0,H.jsx)(aC,{side:`right`,width:284,p:0,bg:`$panel`,children:n})}),(0,H.jsx)(nC,{open:!!e&&_&&!T,onOpenChange:v,children:(0,H.jsx)(aC,{side:`left`,width:220,p:0,style:{backgroundColor:X.sidebar},children:e})}),(0,H.jsx)(Fie,{}),(0,H.jsx)(Xre,{user:A,orgName:j.displayName})]})},S5=({parity:e,children:t})=>(0,H.jsx)(z,{flex:1,minW:0,minH:0,rounded:0,overflow:`hidden`,style:{backgroundColor:X.panel},"data-parity-key":e,children:t}),Bie=({value:e,onChange:t})=>{let n=(0,V.useRef)(0),r=(0,V.useRef)(e),i=(0,V.useRef)(!1),a=e=>Math.min(340,Math.max(188,e));return(0,H.jsx)(z,{role:`separator`,"aria-orientation":`vertical`,"aria-label":`Resize the navigator`,"aria-valuenow":e,"aria-valuemin":188,"aria-valuemax":340,tabIndex:0,width:1,shrink:0,position:`relative`,cursor:`col-resize`,style:{backgroundColor:X.sidebarRule},hoverStyle:{bg:`$soft`},focusVisibleStyle:{bg:`$outlineColor`},onPointerDown:t=>{i.current=!0,n.current=t.clientX,r.current=e,t.currentTarget.setPointerCapture?.(t.pointerId)},onPointerMove:e=>{i.current&&t(a(r.current+e.clientX-n.current))},onPointerUp:e=>{i.current=!1,e.currentTarget.releasePointerCapture?.(e.pointerId)},onPointerCancel:()=>{i.current=!1},onKeyDown:n=>{let r=n.shiftKey?1:8;n.key===`ArrowLeft`&&t(a(e-r)),n.key===`ArrowRight`&&t(a(e+r))},children:(0,H.jsx)(z,{position:`absolute`,t:0,b:0,l:-8,r:-8})})},C5={outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},w5={flexDirection:`row`},T5=({title:e,children:t})=>(0,H.jsxs)(z,{flex:1,minH:0,pt:6,pb:8,children:[(0,H.jsx)(y,{height:36,px:10,pb:4,items:`center`,justify:`space-between`,children:(0,H.jsxs)(y,{items:`center`,gap:4,minW:0,children:[(0,H.jsx)(a,{fontSize:Z.row,fontWeight:`600`,color:`$ink`,numberOfLines:1,children:e}),(0,H.jsx)(wp,{size:13,color:`$soft`})]})}),t]}),E5=({value:e,onChange:t})=>(0,H.jsxs)(y,{mx:10,height:30,items:`center`,gap:8,px:12,rounded:Q.field,borderWidth:1,borderColor:`$edge`,bg:`$panel`,focusWithinStyle:C5,children:[(0,H.jsx)(vm,{size:16,color:`$soft`}),(0,H.jsx)(j_,{flex:1,unstyled:!0,height:28,borderWidth:0,bg:`transparent`,fontSize:Z.body,color:`$ink`,placeholderTextColor:`$faint`,placeholder:`Search…`,value:e,onChangeText:t})]}),D5=()=>(0,H.jsx)(Lc,{my:6,mx:10,borderColor:`$edge`}),O5=({children:e,count:t,open:n=!0,onToggle:r})=>(0,H.jsxs)(y,{...r?o5(r):{},height:26,items:`center`,justify:`space-between`,px:10,gap:5,children:[(0,H.jsxs)(y,{items:`center`,gap:4,minW:0,flex:1,children:[r?(0,H.jsx)(Vie,{open:n}):null,(0,H.jsx)(a,{fontSize:12,fontWeight:`500`,color:`$soft`,numberOfLines:1,children:e})]}),t===void 0?null:(0,H.jsx)(a,{fontSize:Z.chip,color:`$faint`,children:t})]}),Vie=({open:e=!0})=>(0,H.jsx)(z,{width:18,height:18,items:`center`,justify:`center`,rotate:e?`0deg`:`-90deg`,children:(0,H.jsx)(z,{width:7,height:7,borderBottomWidth:1.5,borderRightWidth:1.5,borderColor:`$soft`,rotate:`45deg`,mt:-3})}),k5=({to:e,icon:t,children:n,indent:r})=>{let{pathname:i}=yi(),o=i===e||i.startsWith(`${e}/`);return(0,H.jsx)(y,{asChild:!0,style:o?{...w5,backgroundColor:X.rowActive}:w5,height:r?27:29,items:`center`,gap:8,pl:r?32:8,pr:8,mx:6,rounded:8,hoverStyle:o?void 0:{bg:`$hover`},focusVisibleStyle:C5,children:(0,H.jsxs)(ja,{to:e,"aria-current":o?`page`:void 0,children:[t?(0,H.jsx)(z,{width:18,height:18,items:`center`,justify:`center`,children:t}):null,(0,H.jsx)(a,{fontSize:Z.small,fontWeight:o?`500`:`400`,color:o?`$ink`:`$quiet`,numberOfLines:1,children:n})]})})},Hie=({icon:e,children:t,open:n,onPress:r})=>(0,H.jsxs)(y,{...o5(r),"aria-expanded":n,height:29,items:`center`,gap:8,px:10,mx:4,rounded:Q.field,hoverStyle:{bg:`$hover`},focusVisibleStyle:C5,children:[e?(0,H.jsx)(z,{width:18,height:18,items:`center`,justify:`center`,children:e}):null,(0,H.jsx)(a,{fontSize:Z.row,color:`$quiet`,numberOfLines:1,children:t})]}),Uie=({children:e})=>(0,H.jsxs)(z,{position:`relative`,children:[(0,H.jsx)(z,{position:`absolute`,l:23,t:0,b:0,width:1,bg:`$edge`}),e]}),A5=({children:e})=>(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsx)(z,{pb:10,children:e})}),Wie=36,j5=21,M5=9,N5=18,Gie=e=>e.split(/\s+/).slice(0,2).map(e=>e[0]??``).join(``).toUpperCase(),P5=({spans:e,clamp:t,parity:n})=>(0,H.jsx)(a,{"data-parity-key":n,size:Z.body,lineHeight:j5,color:X.mute,numberOfLines:t,children:e.map((e,t)=>(0,H.jsx)(a,{size:Z.body,lineHeight:j5,fontWeight:e.strong?`600`:`400`,color:e.mention?X.alert:e.strong?X.ink:X.mute,children:e.text},t))}),Kie=({note:e,onSee:t})=>(0,H.jsxs)(y,{"data-parity-key":`inbox.row`,"data-seen":e.seen?`yes`:`no`,...o5(()=>t(e.id),e.line.map(e=>e.text).join(``)),px:10,py:kH.inset,gap:kH.tight,bg:e.seen?`transparent`:X.card,borderBottomWidth:1,borderColor:X.rule,hoverStyle:{background:X.card},focusVisibleStyle:jH,children:[(0,H.jsxs)(Hh,{"data-parity-key":`inbox.face`,size:Wie,children:[e.actor.face?(0,H.jsx)(Uh,{src:e.actor.face,alt:``}):null,(0,H.jsx)(Wh,{bg:TH(e.actor.name).background,children:(0,H.jsx)(a,{size:Z.small,fontWeight:`600`,color:TH(e.actor.name).color,children:Gie(e.actor.name)})})]}),(0,H.jsxs)(z,{flex:1,minW:0,gap:kH.tight,children:[(0,H.jsxs)(z,{children:[(0,H.jsx)(P5,{spans:e.line,parity:`inbox.line`}),e.quote?(0,H.jsx)(P5,{spans:e.quote,clamp:1,parity:`inbox.quote`}):null]}),(0,H.jsxs)(y,{"data-parity-key":`inbox.meta`,items:`center`,gap:kH.tight,overflow:`hidden`,children:[(0,H.jsx)(a,{size:Z.small,lineHeight:N5,color:X.dim,children:(0,H.jsx)(ZL,{date:new Date(e.at),format:`short`,style:{fontSize:`inherit`,lineHeight:`inherit`,color:`inherit`,whiteSpace:`nowrap`}})}),e.place?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(a,{size:Z.small,lineHeight:N5,color:X.dim,children:`•`}),(0,H.jsx)(a,{size:Z.small,lineHeight:N5,color:X.dim,numberOfLines:1,children:e.place})]}):null]})]}),(0,H.jsx)(z,{"data-parity-key":`inbox.lane`,width:M5,shrink:0,pt:6,children:e.seen?null:(0,H.jsx)(z,{"data-parity-key":`inbox.dot`,role:`img`,"aria-label":`unread`,width:M5,height:M5,rounded:Q.pill,bg:X.alert})})]}),qie=12,Jie=12,Yie=36,Xie=6,Zie=17,F5=16,I5=24,Qie={all:tm,task:Pp,chat:sm},$ie={all:`All`,task:`Tasks`,chat:`Chat`},L5=e=>e.line.some(e=>e.mention||e.text.includes(`mentioned`))||(e.quote?.some(e=>e.mention)??!1),R5=({children:e})=>(0,H.jsx)(z,{flex:1,items:`center`,justify:`center`,p:10,gap:kH.inset,children:e}),eae=({tab:e,filter:t})=>{let n=zH();if(n.phase===`loading`)return(0,H.jsx)(R5,{children:(0,H.jsx)(rv,{})});if(n.phase===`failure`)return(0,H.jsxs)(R5,{children:[(0,H.jsx)(a,{size:Z.body,color:X.mute,children:`The inbox is not answering.`}),(0,H.jsx)(a,{size:Z.body,color:X.ink,textDecorationLine:`underline`,...o5(n.reload),focusVisibleStyle:jH,children:`Try again`})]});let r=NH(n.data??[],e).filter(e=>t===`unread`?!e.seen:t!==`mentions`||L5(e));return r.length===0?(0,H.jsx)(R5,{children:(0,H.jsx)(a,{size:Z.body,color:X.dim,children:t===`unread`?`All caught up — no unread notifications.`:t===`mentions`?`No mentions in this view.`:`Nothing here.`})}):(0,H.jsx)(G_,{"data-parity-key":`inbox.list`,flex:1,pt:Xie,children:(0,H.jsx)(z,{role:`list`,children:r.map(e=>(0,H.jsx)(Kie,{note:e,onSee:VH},e.id))})})},z5=()=>{let[e,t]=(0,V.useState)(`all`),[n,r]=(0,V.useState)(`all`),i=zH().data??[],o=BH(),s=i.filter(L5).length;return(0,H.jsxs)(z,{"data-parity-key":`inbox.panel`,flex:1,minH:0,children:[(0,H.jsxs)(y,{px:10,pt:qie,items:`center`,justify:`space-between`,children:[(0,H.jsxs)(y,{items:`center`,gap:8,children:[(0,H.jsx)(a,{"data-parity-key":`inbox.title`,size:Z.row,fontWeight:`600`,color:X.ink,children:`Inbox`}),o>0?(0,H.jsx)(y,{px:7,py:2,rounded:Q.pill,items:`center`,justify:`center`,bg:X.alert,children:(0,H.jsx)(a,{size:Z.chip,fontWeight:`700`,color:X.panel,children:`${o} unread`})}):null]}),(0,H.jsxs)(y,{items:`center`,gap:6,children:[o>0?(0,H.jsx)(y,{...o5(HH,`Mark all notifications as read`),px:7,py:3,rounded:Q.field,hoverStyle:{background:X.card},focusVisibleStyle:jH,children:(0,H.jsx)(a,{size:Z.chip,fontWeight:`500`,color:X.mute,children:`Mark all read`})}):null,(0,H.jsx)(y,{"data-parity-key":`inbox.close`,...o5(_H,`Close the inbox`),width:I5,height:I5,items:`center`,justify:`center`,rounded:Q.field,hoverStyle:{background:X.card},focusVisibleStyle:jH,children:(0,H.jsx)(Rn,{size:14,color:X.dim})})]})]}),(0,H.jsxs)(lv,{value:e,onValueChange:e=>t(e),orientation:`horizontal`,flex:1,minH:0,gap:0,mt:Jie,children:[(0,H.jsx)(z,{"data-parity-key":`inbox.rail`,borderBottomWidth:1,borderColor:X.rule,children:(0,H.jsx)(uv,{height:Yie,self:`stretch`,justify:`flex-start`,items:`stretch`,p:0,pl:kH.tight,gap:kH.tight,bg:`transparent`,rounded:0,children:MH.map(t=>{let n=t===e,r=Qie[t],o=t===`all`?0:PH(i,t);return(0,H.jsxs)(fv,{"data-parity-key":`inbox.tab.${t}`,value:t,height:`100%`,flexDirection:`row`,px:kH.tight,gap:`$1.5`,items:`center`,justify:`center`,rounded:0,bg:`transparent`,borderBottomWidth:2,borderColor:n?X.accent:`transparent`,activeStyle:{background:`transparent`},hoverStyle:{background:`transparent`},focusStyle:{background:`transparent`},focusVisibleStyle:jH,children:[(0,H.jsx)(r,{size:Zie,color:n?X.ink:X.dim}),(0,H.jsx)(a,{size:Z.small,fontWeight:n?`600`:`500`,color:n?X.ink:X.dim,children:$ie[t]}),o>0?(0,H.jsx)(z,{"data-parity-key":`inbox.badge`,minW:F5,height:F5,px:4,rounded:Q.pill,items:`center`,justify:`center`,bg:X.alert,children:(0,H.jsx)(a,{size:Z.chip,fontWeight:`600`,color:X.panel,children:o})}):null]},t)})})}),(0,H.jsx)(y,{px:10,py:8,gap:6,items:`center`,borderBottomWidth:1,borderColor:X.rule,children:[[`all`,`All (${i.length})`],[`unread`,`Unread (${o})`],[`mentions`,`Mentions (${s})`]].map(([e,t])=>{let i=n===e;return(0,H.jsx)(y,{...o5(()=>r(e),`Filter ${t}`),px:8,py:3,rounded:Q.pill,bg:i?X.card:`transparent`,borderWidth:1,borderColor:i?X.ink:X.rule,hoverStyle:{background:X.card},focusVisibleStyle:jH,children:(0,H.jsx)(a,{size:Z.chip,fontWeight:i?`600`:`500`,color:i?X.ink:X.mute,children:t})},e)})}),MH.map(t=>(0,H.jsx)(pv,{value:t,flex:1,minH:0,children:t===e?(0,H.jsx)(eae,{tab:t,filter:n}):null},t))]})]})},tae=()=>{let{id:e}=Ci(),t=r5().data??[],n=n5().data??[],r=N8(e);if(r)return t.find(e=>e.id===r&&e.bot);let i=n.find(t=>t.id===e);return i?F8(i,t):void 0},B5=({person:e,size:t})=>(0,H.jsx)(z,{width:t,height:t,rounded:Q.pill,overflow:`hidden`,bg:`$panel`,borderWidth:1,borderColor:`$edge`,items:`center`,justify:`center`,shrink:0,children:e.avatar?(0,H.jsx)(`img`,{src:e.avatar,alt:e.name,width:t,height:t,style:{width:t,height:t,objectFit:`cover`,display:`block`}}):(0,H.jsx)(a,{fontSize:Math.max(10,t*.42),fontWeight:`600`,color:`$quiet`,children:e.name.slice(0,1).toUpperCase()})});function nae(){let e=yH(),t=tae();return!t||e===`inbox`?(0,H.jsx)(z5,{}):(0,H.jsxs)(z,{flex:1,minH:0,px:10,pt:12,pb:10,gap:14,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`600`,color:`$quiet`,children:`${t.name} · Agent`}),(0,H.jsx)(y,{...o5(_H,`Close inspector`),width:24,height:24,items:`center`,justify:`center`,rounded:Q.field,hoverStyle:{background:X.card},focusVisibleStyle:jH,children:(0,H.jsx)(Rn,{size:14,color:X.dim})})]}),(0,H.jsxs)(z,{items:`center`,gap:6,children:[(0,H.jsx)(B5,{person:t,size:52}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`600`,color:`$ink`,children:t.name})]})]})}var rae=async(e,t)=>{let n=await OV(zB.dms,{space:e,members:[t.id]});return{id:n.channel.id,kind:`direct`,name:t.name,private:!0,archived:n.channel.archived===!0,members:n.channel.members??[]}},V5=`hanzo.appearance`,H5=`hanzo.chat.preferences`,iae=new Set([`system`,`light`,`dark`]),U5=new Set([`compact`,`default`,`spacious`]),W5=new Set([`compact`,`default`,`large`]),G5=new Set([`ink`,`iris`,`jade`,`amber`,`coral`,`plum`]),aae=new Set([`low`,`medium`,`high`]),oae=new Set([`auto`,`manual`]),K5={theme:`dark`,density:`default`,font:`default`},q5={effort:`medium`,approvalMode:`auto`,allowThirdPartyModels:!0,spokenLanguage:`auto`},J5=new Set,Y5=()=>{for(let e of J5)e()};function X5(e){if(!e||typeof e!=`object`)return{...K5};let t=e,n=iae.has(t.theme)?t.theme:K5.theme,r=U5.has(t.density)?t.density:K5.density,i=W5.has(t.font)?t.font:K5.font,a=G5.has(t.accent)?t.accent:void 0;return a?{theme:n,density:r,font:i,accent:a}:{theme:n,density:r,font:i}}function Z5(e){if(!e||typeof e!=`object`)return{...q5};let t=e;return{effort:aae.has(t.effort)?t.effort:q5.effort,approvalMode:oae.has(t.approvalMode)?t.approvalMode:q5.approvalMode,allowThirdPartyModels:typeof t.allowThirdPartyModels==`boolean`?t.allowThirdPartyModels:q5.allowThirdPartyModels,spokenLanguage:typeof t.spokenLanguage==`string`&&t.spokenLanguage.trim()?t.spokenLanguage.trim():q5.spokenLanguage}}function Q5(){if(typeof window>`u`)return{...K5};try{let e=window.localStorage.getItem(V5);return e?X5(JSON.parse(e)):{...K5}}catch{return{...K5}}}function $5(){if(typeof window>`u`)return{...q5};try{let e=window.localStorage.getItem(H5);return e?Z5(JSON.parse(e)):{...q5}}catch{return{...q5}}}function e7(e){return e===`light`||e===`dark`?e:typeof window<`u`&&typeof window.matchMedia==`function`?window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:`dark`}function sae(e){return e===`compact`?`0.92`:e===`large`?`1.08`:`1`}function t7(e){let t=e7(e.theme);if(typeof document>`u`)return t;let n=document.documentElement;n.dataset.theme=t,n.dataset.density=e.density,n.classList.toggle(`dark`,t===`dark`),n.classList.toggle(`light`,t===`light`),n.style.setProperty(`--hanzo-font-scale`,sae(e.font)),e.accent&&(n.dataset.accent=e.accent);let r=window.getComputedStyle(n).getPropertyValue(`--background`).trim(),i=document.querySelector(`meta[name="theme-color"]`);return i&&r&&i.setAttribute(`content`,r),t}function n7(e){let t=X5({...Q5(),...e});if(typeof window<`u`)try{window.localStorage.setItem(V5,JSON.stringify(t))}catch{}return t7(t),Y5(),t}function cae(e){let t=Z5({...$5(),...e});if(typeof window<`u`)try{window.localStorage.setItem(H5,JSON.stringify(t))}catch{}return Y5(),t}async function lae(e){if(e&&typeof fetch==`function`)try{let t=await fetch(`https://api.hanzo.ai/v1/account/appearance`,{method:`GET`,headers:{Authorization:`Bearer ${e}`,Accept:`application/json`}});if(!t.ok)return;let n=await t.json();if(!n||typeof n!=`object`)return;let r=n,i={};W5.has(r.font)&&(i.font=r.font),U5.has(r.density)&&(i.density=r.density),G5.has(r.accent)&&(i.accent=r.accent),Object.keys(i).length>0&&n7(i)}catch{}}function r7(){let[,e]=(0,V.useState)(0);(0,V.useEffect)(()=>{let t=()=>e(e=>e+1);J5.add(t);let n=e=>{(e.key===`hanzo.appearance`||e.key===`hanzo.chat.preferences`)&&(t7(Q5()),t())};return window.addEventListener(`storage`,n),()=>{J5.delete(t),window.removeEventListener(`storage`,n)}},[]);let t=Q5();return{appearance:t,chat:$5(),effectiveTheme:e7(t.theme),setAppearance:n7,setChat:cae}}var i7=22,uae=44,a7=198;function o7({placeholder:e,disabled:t,onSend:n}){let[r,i]=(0,V.useState)(``),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(null),{chat:u,setChat:d}=r7(),f=u.approvalMode===`auto`,p=r.trim()!==``&&!o&&!t,m=async()=>{if(!p)return;let e=r;s(!0),l(null);try{await n(e),i(``)}catch(e){l(e instanceof Error?e.message:String(e))}finally{s(!1)}},h=Math.min(8,r.split(`
|
|
193
|
+
`).length),g=Math.max(uae,Math.min(a7,h*i7+22));return(0,H.jsxs)(z,{px:16,pb:12,pt:6,gap:6,children:[c?(0,H.jsx)(a,{fontSize:`$1`,style:{color:X.alert},children:c}):null,(0,H.jsxs)(z,{gap:4,px:12,pt:8,pb:8,rounded:18,borderWidth:1,opacity:t?.6:1,style:{backgroundColor:X.composer,borderTopColor:X.composerRule,borderRightColor:X.composerRule,borderBottomColor:X.composerRule,borderLeftColor:X.composerRule},focusWithinStyle:{borderColor:`$bound`},"data-testid":`team-composer`,children:[(0,H.jsx)(_v,{flex:1,unstyled:!0,rows:1,height:g-12,minH:g-12,maxH:a7,py:4,px:2,borderWidth:0,bg:`transparent`,fontSize:`$3`,lineHeight:i7,color:`$ink`,placeholderTextColor:`$placeholderColor`,placeholder:t??e,value:r,disabled:!!t,"aria-label":e,onChangeText:i,onKeyDown:e=>{e.nativeEvent.key!==`Enter`||e.shiftKey||(e.preventDefault?.(),m())}}),(0,H.jsxs)(y,{items:`center`,justify:`space-between`,pt:2,children:[(0,H.jsxs)(y,{items:`center`,gap:6,children:[(0,H.jsx)(z,{width:26,height:26,rounded:13,items:`center`,justify:`center`,hoverStyle:{bg:`$hover`},children:(0,H.jsx)(hm,{size:15,color:`$soft`})}),(0,H.jsxs)(y,{...o5(()=>d({approvalMode:f?`manual`:`auto`}),f?`Switch to manual approval`:`Switch to full access`),height:24,px:7,gap:5,rounded:7,items:`center`,hoverStyle:{bg:`$hover`},"data-testid":`composer-approval-toggle`,children:[f?(0,H.jsx)(sp,{size:13,color:X.composerWarn}):(0,H.jsx)(xm,{size:13,color:`$soft`}),(0,H.jsx)(a,{fontSize:12,fontWeight:`500`,style:{color:f?X.composerWarn:void 0},color:f?void 0:`$soft`,children:f?`Full access`:`Manual approval`})]})]}),(0,H.jsx)(z,{"aria-disabled":!p,...o5(()=>void m(),`Send`),cursor:p?`pointer`:`default`,width:30,height:30,items:`center`,justify:`center`,rounded:15,style:{backgroundColor:X.composerAccent},opacity:p?1:.92,focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},children:(0,H.jsx)(gp,{size:16,color:X.composerAccentInk})})]})]})]})}var dae=3e5,fae=e=>{let t=[],n=null,r=``;for(let i of e){let e=mae(i.at);if(e!==r&&(r=e,n=null,t.push({kind:`day`,id:`day:${e}`,at:i.at})),n&&n.author===i.author&&i.at-pae(n).at<=dae){n.messages.push(i);continue}n={id:i.id,author:i.author,at:i.at,messages:[i]},t.push({kind:`run`,...n})}return t},pae=e=>e.messages[e.messages.length-1],mae=e=>{let t=new Date(e);return`${t.getFullYear()}-${t.getMonth()+1}-${t.getDate()}`},hae=(e,t=Date.now())=>{let n=s7(t)-s7(e);if(n===0)return`Today`;if(n===1)return`Yesterday`;let r=new Date(e),i=r.getFullYear()===new Date(t).getFullYear()?void 0:`numeric`;return r.toLocaleDateString(void 0,{month:`long`,day:`numeric`,year:i})},s7=e=>{let t=new Date(e);return Math.floor((e-t.getTimezoneOffset()*6e4)/864e5)},gae=e=>new Date(e).toLocaleTimeString(void 0,{hour:`numeric`,minute:`2-digit`});function c7({author:e,at:t,messages:n,people:r,reactions:i,me:o,onReact:s,onOpen:c,open:l}){let u=i5(r,e),d=r.find(e=>e.name===u);return(0,H.jsxs)(y,{px:16,pt:10,gap:10,items:`flex-start`,children:[(0,H.jsxs)(Hh,{circular:!0,size:36,children:[d?.avatar?(0,H.jsx)(Uh,{src:d.avatar,alt:``}):null,(0,H.jsx)(Wh,{bg:`$raised`,children:(0,H.jsx)(a,{fontSize:`$2`,color:`$quiet`,children:Aie(u)})})]}),(0,H.jsxs)(z,{flex:1,minW:0,gap:2,children:[(0,H.jsxs)(y,{gap:8,items:`baseline`,children:[(0,H.jsx)(a,{fontSize:`$3`,fontWeight:`600`,color:`$ink`,children:u}),(0,H.jsx)(a,{fontSize:`$1`,color:`$dim`,children:gae(t)})]}),n.map(e=>(0,H.jsx)(_ae,{message:e,reactions:i.filter(t=>t.message===e.id),me:o,onReact:s,onOpen:c,open:l===e.id},e.id))]})]})}function _ae({message:e,reactions:t,me:n,onReact:r,onOpen:i,open:o}){let s=u7(t),c=!!n&&e.author===n;return(0,H.jsxs)(z,{group:!0,position:`relative`,pr:72,py:2,rounded:`$1`,bg:o?`$hover`:`transparent`,hoverStyle:{background:`$hover`},children:[(0,H.jsx)(z,{self:c?`flex-start`:void 0,px:c?12:0,py:c?6:0,rounded:c?12:0,style:c?{backgroundColor:X.chatUser}:void 0,children:e.lines.map((e,t)=>(0,H.jsx)(a,{fontSize:`$3`,lineHeight:22,color:c?void 0:`$ink`,style:c?{color:X.chatUserInk}:void 0,children:sie(e).map((e,t)=>e.kind===`text`?(0,H.jsx)(a,{fontSize:`$3`,lineHeight:22,color:c?void 0:`$ink`,style:c?{color:X.chatUserInk}:void 0,children:e.value},t):(0,H.jsx)(a,{fontSize:`$3`,lineHeight:22,style:{color:e.kind===`mention`?X.alert:X.accent},fontWeight:e.kind===`mention`?`500`:`400`,...e.kind===`link`?{tag:`a`,href:e.value,target:`_blank`,rel:`noreferrer`}:{},children:e.value},t))},t))}),s.length>0?(0,H.jsx)(y,{gap:4,pt:4,flexWrap:`wrap`,children:s.map(t=>(0,H.jsx)(vae,{emoji:t.emoji,count:t.by.length,mine:t.by.includes(n),onPress:()=>r(e,t.emoji)},t.emoji))}):null,e.replies>0?(0,H.jsxs)(y,{items:`center`,gap:5,pt:4,...o5(()=>i(e)),children:[(0,H.jsx)(cm,{size:13,color:X.accent}),(0,H.jsx)(a,{fontSize:`$1`,style:{color:X.accent},children:e.replies===1?`1 reply`:`${e.replies} replies`})]}):null,(0,H.jsxs)(y,{position:`absolute`,t:0,r:8,gap:2,opacity:0,"$group-hover":{opacity:1},focusWithinStyle:{opacity:1},children:[(0,H.jsx)(l7,{label:`React`,onPress:()=>r(e,`👍`),children:(0,H.jsx)(Cm,{size:15,color:`$soft`})}),(0,H.jsx)(l7,{label:`Reply in thread`,onPress:()=>i(e),children:(0,H.jsx)(cm,{size:15,color:`$soft`})})]})]})}var l7=({label:e,onPress:t,children:n})=>(0,H.jsx)(z,{width:26,height:26,items:`center`,justify:`center`,rounded:`$1`,bg:`$panel`,borderWidth:1,borderColor:`$edge`,...o5(t,e),hoverStyle:{background:`$hover`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},children:n}),vae=({emoji:e,count:t,mine:n,onPress:r})=>(0,H.jsxs)(y,{"aria-pressed":n,height:22,items:`center`,gap:4,px:7,rounded:11,borderWidth:1,borderColor:n?`$bound`:`$edge`,bg:n?`$hover`:`$raised`,...o5(r),hoverStyle:{borderColor:`$bound`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},children:[(0,H.jsx)(a,{fontSize:12,lineHeight:14,children:e}),(0,H.jsx)(a,{fontSize:`$1`,color:n?`$ink`:`$quiet`,children:t})]}),u7=e=>{let t=[];for(let n of e){let e=t.find(e=>e.emoji===n.emoji);e?e.by.push(n.by):t.push({emoji:n.emoji,by:[n.by]})}return t};function d7({room:e,phase:t,error:n,messages:r,people:i,reactions:a,me:o,onRetry:s,onReact:c,onOpen:l,open:u}){return t===`loading`?(0,H.jsx)(p7,{}):t===`failure`?(0,H.jsx)(m7,{error:n,onRetry:s}):r.length===0?(0,H.jsx)(xae,{room:e}):(0,H.jsx)(yae,{messages:r,people:i,reactions:a,me:o,onReact:c,onOpen:l,open:u})}function yae({messages:e,people:t,reactions:n,me:r,onReact:i,onOpen:a,open:o}){let s=(0,V.useRef)(null),c=e[e.length-1]?.id;return(0,V.useEffect)(()=>{s.current?.scrollIntoView({block:`end`})},[c]),(0,H.jsx)(z,{flex:1,minH:0,style:{overflowY:`auto`},children:(0,H.jsxs)(z,{pt:4,pb:12,children:[fae(e).map(e=>e.kind===`day`?(0,H.jsx)(bae,{at:e.at},e.id):(0,H.jsx)(c7,{author:e.author,at:e.at,messages:e.messages,people:t,reactions:n,me:r,onReact:i,onOpen:a,open:o},e.id)),(0,H.jsx)(`div`,{ref:e=>void(s.current=e)})]})})}var bae=({at:e})=>(0,H.jsx)(z,{px:16,pt:14,pb:4,children:(0,H.jsx)(z,{height:1,bg:`$edge`,position:`relative`,justify:`center`,children:(0,H.jsx)(a,{position:`absolute`,self:`center`,px:10,style:{backgroundColor:X.panel},fontSize:`$1`,color:`$dim`,children:hae(e)})})}),f7=({children:e})=>(0,H.jsx)(z,{flex:1,minH:0,items:`center`,justify:`center`,p:24,children:e}),p7=()=>(0,H.jsx)(f7,{children:(0,H.jsx)(rv,{size:16})}),m7=({error:e,onRetry:t})=>(0,H.jsx)(f7,{children:(0,H.jsx)(WZ,{state:VZ(e),onRetry:t})}),xae=({room:e})=>(0,H.jsx)(f7,{children:(0,H.jsxs)(z,{gap:6,maxW:340,items:`center`,children:[(0,H.jsx)(a,{fontSize:`$4`,fontWeight:`500`,color:`$ink`,children:e.kind===`direct`?e.name:`#${e.name}`}),(0,H.jsx)(a,{fontSize:`$2`,color:`$dim`,text:`center`,children:e.topic?e.topic:e.kind===`direct`?`The beginning of your conversation.`:`This is the beginning of the channel. Say something.`})]})}),h7=({people:e,size:t=28,show:n=3,ground:r=X.ground})=>{if(e.length===0)return null;let i=e.slice(0,n),o=e.length-i.length,s=Math.round(t*.575);return(0,H.jsxs)(y,{items:`center`,"aria-label":`${e.length} assigned`,children:[i.map((e,n)=>(0,H.jsx)(z,{ml:n===0?0:s-t,rounded:9999,borderWidth:2,style:{backgroundColor:r,borderColor:r},children:(0,H.jsxs)(Hh,{size:t,"aria-label":e.name,children:[e.face?(0,H.jsx)(Uh,{src:e.face,alt:``}):null,(0,H.jsx)(Wh,{children:Sae(e.name)})]})},e.id)),o>0?(0,H.jsxs)(a,{fontSize:`$2`,color:`$quiet`,ml:6,children:[`+`,o]}):null]})},Sae=e=>(e[0]??``).toUpperCase();function Cae({members:e,people:t}){return e.length===0?null:(0,H.jsx)(h7,{people:e.map(e=>({id:e,name:i5(t,e),face:wae(t,e)})),size:28,show:4,ground:`$panel`})}var wae=(e,t)=>{let n=t.startsWith(`hanzo:`)?t.slice(6):t;return e.find(e=>e.id===n||e.id===t)?.avatar};function Tae({room:e,parent:t,replies:n,phase:r,error:i,people:o,reactions:s,me:c,onClose:l,onRetry:u,onReact:d,onSend:f}){return(0,H.jsxs)(z,{width:360,shrink:0,minH:0,borderLeftWidth:1,borderLeftColor:`$edge`,children:[(0,H.jsxs)(y,{height:56,items:`center`,px:20,gap:8,children:[(0,H.jsx)(a,{flex:1,fontSize:`$4`,fontWeight:`500`,color:`$ink`,children:`Thread`}),(0,H.jsx)(z,{width:28,height:28,items:`center`,justify:`center`,rounded:`$1`,...o5(l,`Close the thread`),hoverStyle:{background:`$hover`},focusVisibleStyle:{outlineColor:`$outlineColor`,outlineWidth:2,outlineStyle:`solid`},children:(0,H.jsx)(Rn,{size:16,color:`$soft`})})]}),(0,H.jsx)(z,{pb:8,borderBottomWidth:1,borderBottomColor:`$edge`,children:(0,H.jsx)(c7,{author:t.author,at:t.at,messages:[t],people:o,reactions:s,me:c,onReact:d,onOpen:()=>{}})}),(0,H.jsx)(d7,{room:e,phase:r,error:i,messages:n,people:o,reactions:s,me:c,onRetry:u,onReact:d,onOpen:()=>{}}),(0,H.jsx)(o7,{placeholder:`Reply…`,onSend:f})]})}var Eae={"dm-algo":`dm-sci`,"dm-cal":`dm-mana`,"dm-core":`dm-opera`,"dm-db":`dm-data`,"dm-sec":`dm-cyber`};function g7(){let{id:e}=Ci(),t=e&&(Eae[e]??e),{plane:n,current:r}=nH(),i=n5(),a=r5(),o=N8(t),s=(0,V.useMemo)(()=>o?(a.data??[]).find(e=>e.id===o):void 0,[o,a.data]),c=r?.uuid??``,l=cV(`chat:dm:${c}:${s?.id??`-`}`,()=>rae(c,s),{enabled:!!(n&&s&&c)}),u=(0,V.useMemo)(()=>(i.data??[]).find(e=>e.id===t)??null,[i.data,t]),d=o?l.data??null:u,f=d?F8(d,a.data??[]):void 0,p=Tie(d?.id??null),m=p.data??[],h=Eie((0,V.useMemo)(()=>m.map(e=>e.id),[m]));Oie(d?.id??null);let[g,_]=(0,V.useState)(null),v=m.find(e=>e.id===g)??null,b=Die(v?.id??null),x=n?.account??``,S=a.data??[],C=h.data??[],w=(0,V.useCallback)((e,t)=>{if(!n||!d)return;let r=u7(C.filter(t=>t.message===e.id)).find(e=>e.emoji===t),i=C.find(n=>n.message===e.id&&n.emoji===t&&n.by===x);(r&&i?Sie(n,d,i):xie(n,d,e,t)).then(()=>lV(`chat:reactions:`))},[n,d,C,x]);if(!t){if(i.phase===`failure`)return(0,H.jsx)(m7,{error:i.error,onRetry:i.reload});if(i.phase===`loading`||!n)return(0,H.jsx)(p7,{});let e=(i.data??[]).find(e=>e.kind===`channel`)??(i.data??[])[0];return e?(0,H.jsx)(Gi,{to:`/chat/${e.id}`,replace:!0}):(0,H.jsx)(Oae,{})}if(o){if(a.phase===`failure`)return(0,H.jsx)(m7,{error:a.error,onRetry:a.reload});if(a.phase===`loading`||!n)return(0,H.jsx)(p7,{});if(!s)return(0,H.jsx)(_7,{});if(l.phase===`failure`)return(0,H.jsx)(m7,{error:l.error,onRetry:l.reload});if(!d)return(0,H.jsx)(p7,{})}else if(i.phase===`failure`)return(0,H.jsx)(m7,{error:i.error,onRetry:i.reload});else if(i.phase===`loading`||!n)return(0,H.jsx)(p7,{});return d?(0,H.jsxs)(y,{flex:1,minH:0,children:[(0,H.jsxs)(z,{flex:1,minW:0,minH:0,children:[(0,H.jsx)(Dae,{room:d,people:S,agent:f}),(0,H.jsx)(d7,{room:d,phase:p.phase,error:p.error,messages:m,people:S,reactions:C,me:x,onRetry:p.reload,onReact:w,onOpen:e=>_(e.id),open:g??void 0}),(0,H.jsx)(o7,{placeholder:d.kind===`direct`?`Message ${K8(d,S)}`:`Message #${d.name}`,onSend:e=>yie(n,d,e,S)})]}),v?(0,H.jsx)(Tae,{room:d,parent:v,replies:b.data??[],phase:b.phase,error:b.error,people:S,reactions:C,me:x,onClose:()=>_(null),onRetry:b.reload,onReact:w,onSend:e=>bie(n,d,v,e,S)}):null]}):(0,H.jsx)(_7,{})}function Dae({room:e,people:t,agent:n}){let r=m5(),i=vH(),o=yH();return(0,H.jsx)(z,{borderBottomWidth:1,borderBottomColor:`$edge`,bg:`$panel`,children:(0,H.jsxs)(y,{px:16,py:8,items:`center`,justify:`space-between`,gap:10,children:[n?(0,H.jsxs)(y,{flex:1,minW:0,items:`center`,gap:12,children:[(0,H.jsx)(B5,{person:n,size:34}),(0,H.jsxs)(y,{items:`center`,gap:8,flexWrap:`wrap`,children:[(0,H.jsx)(a,{fontSize:Z.row,fontWeight:`600`,color:`$ink`,children:n.name}),(0,H.jsx)(y,{px:7,py:2,rounded:Q.field,bg:`$raised`,borderWidth:1,borderColor:`$edge`,children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`500`,color:`$quiet`,children:`Agent`})})]})]}):(0,H.jsxs)(y,{flex:1,minW:0,items:`center`,gap:10,children:[(0,H.jsxs)(y,{items:`center`,gap:6,shrink:0,children:[e.kind===`direct`?null:e.private?(0,H.jsx)(nm,{size:16,color:`$quiet`}):(0,H.jsx)(Yp,{size:17,color:`$quiet`}),(0,H.jsx)(a,{fontSize:Z.row,fontWeight:`600`,color:`$ink`,numberOfLines:1,children:K8(e,t??[])})]}),e.topic?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(z,{width:1,height:14,bg:`$edge`,shrink:0}),(0,H.jsx)(a,{fontSize:Z.small,color:`$dim`,numberOfLines:1,flex:1,children:e.topic})]}):null]}),(0,H.jsxs)(y,{items:`center`,gap:8,shrink:0,children:[n?null:(0,H.jsx)(Cae,{members:e.members,people:t??[]}),(0,H.jsxs)(y,{...o5(()=>gH(`inbox`),`Toggle Inbox drawer`),"aria-pressed":i&&o===`inbox`,px:9,py:5,rounded:Q.field,bg:i&&o===`inbox`?`$hover`:`$raised`,borderWidth:1,borderColor:i&&o===`inbox`?`$bound`:`$edge`,items:`center`,gap:6,hoverStyle:{background:`$hover`},focusVisibleStyle:jH,children:[(0,H.jsx)(_p,{size:13,color:i&&o===`inbox`?`$ink`:`$quiet`}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`500`,color:i&&o===`inbox`?`$ink`:`$quiet`,children:`Inbox`}),r>0?(0,H.jsx)(z,{minW:16,height:16,px:4,rounded:Q.pill,items:`center`,justify:`center`,style:{background:X.alert},children:(0,H.jsx)(a,{fontSize:10,lineHeight:12,fontWeight:`700`,style:{color:X.panel},children:r})}):null]})]})]})})}var Oae=()=>(0,H.jsx)(f7,{children:(0,H.jsx)(JZ,{icon:lm,title:`Chat`,description:`Choose a channel or a conversation to read it.`})}),_7=()=>(0,H.jsx)(f7,{children:(0,H.jsx)(JZ,{icon:lm,title:`No such room`,description:`It may have been archived, or it may belong to another space.`})});function kae(){let{pathname:e}=yi(),t=xi(),[n,r]=(0,V.useState)(``),[i,o]=(0,V.useState)(!0),[s,c]=(0,V.useState)(!0),[l,u]=(0,V.useState)(!0),d=n5(),f=r5().data??[],p=d.data??[],m=n.trim().toLowerCase(),h=m?p.filter(e=>e.name.toLowerCase().includes(m)):p,g=h.filter(e=>e.kind===`channel`),_=g.filter(e=>!e.connectedOrgs||e.connectedOrgs.length===0),v=g.filter(e=>e.connectedOrgs&&e.connectedOrgs.length>0),b=h.filter(e=>e.kind===`direct`),x=P8(f).filter(e=>!m||e.name.toLowerCase().includes(m));return(0,H.jsxs)(T5,{title:g5(e)?.label??`Chat`,children:[(0,H.jsx)(E5,{value:n,onChange:r}),(0,H.jsx)(z,{height:8}),(0,H.jsx)(D5,{}),(0,H.jsxs)(A5,{children:[d.phase===`loading`?(0,H.jsx)(z,{px:10,py:12,children:(0,H.jsx)(rv,{size:16})}):null,d.phase===`failure`?(0,H.jsx)(y7,{children:`Your rooms could not be read.`}):null,d.phase===`ready`&&p.length===0&&x.length===0?(0,H.jsx)(y7,{children:`No rooms yet.`}):null,d.phase===`ready`&&p.length>0&&h.length===0&&x.length===0?(0,H.jsx)(y7,{children:`Nothing matches “${n.trim()}”.`}):null,_.length>0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(O5,{count:_.length,open:i,onToggle:()=>o(e=>!e),children:`Channels`}),i?_.map(e=>(0,H.jsx)(v7,{room:e,roster:f},e.id)):null]}):null,d.phase===`ready`&&(!m||v.length>0)?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(D5,{}),(0,H.jsx)(O5,{count:v.length,open:s,onToggle:()=>c(e=>!e),children:`Hanzo Connect`}),s?(0,H.jsxs)(H.Fragment,{children:[v.map(e=>(0,H.jsx)(v7,{room:e,roster:f},e.id)),(0,H.jsxs)(y,{...o5(()=>l5(`connect`),`Connect external organization channel`),px:10,py:6,mx:4,gap:8,items:`center`,rounded:Q.field,hoverStyle:{background:`$hover`},"data-testid":`hanzo-connect-add-trigger`,children:[(0,H.jsx)(hm,{size:14,color:`$soft`}),(0,H.jsx)(a,{fontSize:Z.body,color:`$quiet`,fontWeight:`500`,children:`Connect organization…`})]})]}):null]}):null,x.length>0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(D5,{}),(0,H.jsx)(O5,{count:x.length,open:l,onToggle:()=>u(e=>!e),children:`Bots`}),l?x.map(e=>{let n=M8(e);return(0,H.jsxs)(y,{...o5(()=>t(n),e.name),px:8,py:6,mx:6,gap:10,items:`center`,rounded:8,bg:`transparent`,hoverStyle:{background:`$hover`},children:[(0,H.jsx)(B5,{person:e,size:26}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`600`,color:`$ink`,numberOfLines:1,flex:1,children:e.name})]},e.id)}):null]}):null,b.length>0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(D5,{}),(0,H.jsx)(O5,{count:b.length,children:`Direct`}),b.map(e=>(0,H.jsx)(v7,{room:e,roster:f},e.id))]}):null]})]})}var v7=({room:e,roster:t})=>{let n=e.connectedOrgs&&e.connectedOrgs.length>0?`${e.name} · ${e.connectedOrgs.join(`, `)}`:K8(e,t);return(0,H.jsx)(k5,{to:`/chat/${e.id}`,icon:(0,H.jsx)(Aae,{room:e}),children:n})},Aae=({room:e})=>e.kind===`direct`?null:e.connectedOrgs&&e.connectedOrgs.length>0?(0,H.jsx)(bm,{size:14,color:`$soft`}):e.private?(0,H.jsx)(nm,{size:14,color:`$soft`}):(0,H.jsx)(Yp,{size:16,color:`$soft`}),y7=({children:e})=>(0,H.jsx)(a,{px:10,py:8,fontSize:`$2`,color:`$faint`,children:e});G$();var jae=`https://api.hanzo.ai`,b7=e=>DV(`${jae}${e}`),Mae=[`investors`,`funds`,`customers`,`leads`,`feedback`,`errors`,`lists`],x7=[{value:`NEW`,label:`New`,color:`pink`},{value:`SCREENING`,label:`Screening`,color:`cyan`},{value:`MEETING`,label:`Meeting`,color:`blue`},{value:`PROPOSAL`,label:`Proposal`,color:`amber`},{value:`CUSTOMER`,label:`Customer`,color:`green`}],Nae=[{name:`name`,label:`Investor`,type:`text`,metadata:{avatar:`circle`}},{name:`company`,label:`Firm / Fund`,type:`relation`,metadata:{labelField:`name`,shape:`square`}},{name:`category`,label:`Category`,type:`select`,metadata:{options:[{value:`vc`,label:`Institutional VC`,color:`blue`},{value:`crypto_vc`,label:`Crypto / Web3 VC`,color:`cyan`},{value:`accredited`,label:`Accredited High-Check`,color:`green`},{value:`angel`,label:`Angel Investor`,color:`amber`},{value:`family_office`,label:`Family Office`,color:`cyan`},{value:`crowdfunding_republic`,label:`Republic / Reg CF`,color:`orange`}]}},{name:`stage`,label:`Stage`,type:`select`,metadata:{options:x7}},{name:`email`,label:`Email`,type:`email`},{name:`title`,label:`Title`,type:`text`},{name:`checkSize`,label:`Check Size`,type:`text`},{name:`location`,label:`Location`,type:`text`}],Pae=[{name:`name`,label:`Fund / Firm`,type:`text`,metadata:{avatar:`square`}},{name:`stage`,label:`Stage`,type:`select`,metadata:{options:x7}},{name:`aum`,label:`AUM`,type:`text`},{name:`checkSize`,label:`Check Size`,type:`text`},{name:`primaryEmail`,label:`Primary Email`,type:`email`},{name:`website`,label:`Url`,type:`url`},{name:`location`,label:`Location`,type:`text`}],Fae=[{name:`name`,label:`Customer`,type:`text`,metadata:{avatar:`circle`}},{name:`email`,label:`Email`,type:`email`},{name:`product`,label:`Product`,type:`text`},{name:`totalSpent`,label:`Total Spent`,type:`currency`,metadata:{currencyCode:`USD`,decimals:0}},{name:`stage`,label:`Stage`,type:`select`,metadata:{options:x7}},{name:`location`,label:`Location`,type:`text`}],Iae=[{name:`name`,label:`Developer`,type:`text`,metadata:{avatar:`circle`}},{name:`handle`,label:`GitHub`,type:`text`},{name:`email`,label:`Email`,type:`email`},{name:`company`,label:`Company`,type:`relation`,metadata:{labelField:`name`,shape:`square`}},{name:`stars`,label:`Stars`,type:`number`},{name:`followers`,label:`Followers`,type:`number`},{name:`location`,label:`Location`,type:`text`}],Lae=[{name:`name`,label:`Audience / Segment`,type:`text`,metadata:{avatar:`square`}},{name:`purpose`,label:`Engine`,type:`text`},{name:`totalCount`,label:`Total Contacts`,type:`number`},{name:`eligibleCount`,label:`Deliverable`,type:`number`},{name:`description`,label:`Description`,type:`text`}],Rae=[{name:`name`,label:`Subject / Summary`,type:`text`,metadata:{avatar:`square`}},{name:`program`,label:`Kind`,type:`text`},{name:`email`,label:`Submitter`,type:`email`},{name:`company`,label:`Organization`,type:`text`},{name:`source`,label:`Source`,type:`text`},{name:`recordCode`,label:`Ref / Report ID`,type:`text`,readOnly:!0},{name:`closeDate`,label:`Submitted At`,type:`date`}],zae=[{name:`name`,label:`Exception / Fault`,type:`text`,metadata:{avatar:`square`}},{name:`program`,label:`Class / Type`,type:`text`},{name:`company`,label:`Service / App`,type:`text`},{name:`location`,label:`Origin / File`,type:`text`},{name:`source`,label:`Env & Release`,type:`text`},{name:`recordCode`,label:`Event / Issue ID`,type:`text`,readOnly:!0},{name:`closeDate`,label:`Occurred At`,type:`date`}],Bae={name:(0,H.jsx)(xp,{size:14,color:`$color10`}),domainName:(0,H.jsx)($p,{size:14,color:`$color10`}),website:(0,H.jsx)($p,{size:14,color:`$color10`}),createdBy:(0,H.jsx)(Fm,{size:14,color:`$color10`}),city:(0,H.jsx)(am,{size:14,color:`$color10`}),location:(0,H.jsx)(am,{size:14,color:`$color10`}),country:(0,H.jsx)(qp,{size:14,color:`$color10`}),employees:(0,H.jsx)(Im,{size:14,color:`$color10`}),arr:(0,H.jsx)(Lp,{size:14,color:`$color10`}),amount:(0,H.jsx)(Lp,{size:14,color:`$color10`}),totalSpent:(0,H.jsx)(Lp,{size:14,color:`$color10`}),company:(0,H.jsx)(xp,{size:14,color:`$color10`}),pointOfContact:(0,H.jsx)(Fm,{size:14,color:`$color10`}),rating:(0,H.jsx)(Em,{size:14,color:`$color10`}),closeDate:(0,H.jsx)(Cp,{size:14,color:`$color10`}),recordCode:(0,H.jsx)(Yp,{size:14,color:`$color10`}),email:(0,H.jsx)(im,{size:14,color:`$color10`}),primaryEmail:(0,H.jsx)(im,{size:14,color:`$color10`}),jobTitle:(0,H.jsx)(bp,{size:14,color:`$color10`}),title:(0,H.jsx)(bp,{size:14,color:`$color10`})};function Vae(){let[e,t]=(0,V.useState)(``),n=e.trim().toLowerCase(),r=[{to:`investors`,label:`Investors`,icon:(0,H.jsx)(Am,{size:15,color:EH(`investors`)}),group:`Audiences`},{to:`funds`,label:`Funds`,icon:(0,H.jsx)(bp,{size:15,color:EH(`funds`)}),group:`Audiences`},{to:`customers`,label:`Customers`,icon:(0,H.jsx)(Im,{size:15,color:EH(`customers`)}),group:`Audiences`},{to:`leads`,label:`Developer Leads`,icon:(0,H.jsx)(Bm,{size:15,color:EH(`leads`)}),group:`Audiences`},{to:`feedback`,label:`Feedback, Bugs & Forms`,icon:(0,H.jsx)(Up,{size:15,color:EH(`feedback`)}),group:`Inbound`},{to:`errors`,label:`Runtime & CLI Errors`,icon:(0,H.jsx)(lp,{size:15,color:EH(`errors`)}),group:`Inbound`},{to:`lists`,label:`Lists & Segments`,icon:(0,H.jsx)(Zp,{size:15,color:`$soft`}),group:`Engagement`}].filter(e=>!n||e.label.toLowerCase().includes(n)),i=[...new Set(r.map(e=>e.group))];return(0,H.jsxs)(T5,{title:`CRM`,children:[(0,H.jsx)(E5,{value:e,onChange:t}),(0,H.jsx)(z,{height:12}),(0,H.jsx)(A5,{children:i.map((e,t)=>(0,H.jsxs)(z,{children:[t>0?(0,H.jsx)(D5,{}):null,(0,H.jsx)(O5,{children:e}),r.filter(t=>t.group===e).map(e=>(0,H.jsx)(k5,{to:`/crm/${e.to}`,icon:e.icon,children:e.label},e.to))]},e))})]})}var S7=e=>[e.city,e.state,e.country].filter(Boolean).join(`, `)||String(e.location??``),C7=e=>typeof e==`string`?e.slice(0,10):``,Hae=async(e,t,n)=>{switch(e){case`investors`:{let e=await b7(`/v1/crm/investors?limit=250&category=${n===`all`?`vc`:n}`),t=(e.items??[]).filter(e=>e.name||e.email).map(e=>({id:String(e.id),name:String(e.name??e.email),company:String(e.company??e.fund_name??``),category:String(e.category??``),stage:String(e.stage??``).toUpperCase(),email:String(e.email??``),title:String(e.title??``),checkSize:String(e.check_size??``),location:S7(e)}));return{rows:t,total:e.total??t.length}}case`funds`:{let e=await b7(`/v1/crm/funds?limit=250`),t=(e.items??[]).map(e=>({id:String(e.id),name:String(e.name??``),stage:String(e.stage??``).toUpperCase(),aum:String(e.aum??``),checkSize:String(e.check_size??``),primaryEmail:String(e.primary_email??``),website:String(e.website??``),location:String(e.location??e.country??``)}));return{rows:t,total:e.total??t.length}}case`customers`:{let e=await b7(`/v1/crm/customers?limit=250`),t=(e.items??[]).map(e=>({id:String(e.id),name:String(e.name??e.email??``),email:String(e.email??``),product:String(e.products??e.product??``),totalSpent:Number(e.total_spent??e.amount??0),stage:`CUSTOMER`,location:S7(e)}));return{rows:t,total:e.total??t.length}}case`leads`:{let e=new URLSearchParams({limit:`200`}),[n,r]=t===`all`?[]:t.endsWith(`+`)?[t.slice(0,-1)]:t.split(`-`);n&&e.set(`min_stars`,n===`0`?`1`:n),r&&e.set(`max_stars`,r);let i=await b7(`/v1/crm/leads?${e}`),a=(i.leads??[]).map((e,t)=>({id:String(e.id??e.github_login??t),name:String(e.name??e.github_login??e.email??``),handle:e.github_login?`@${e.github_login}`:``,email:String(e.email??``),company:String(e.company??``),stars:Number(e.total_stars??e.stars??0),followers:Number(e.followers??0),location:String(e.location??e.country??``)}));return{rows:a,total:i.total??a.length}}case`feedback`:{let[e,t]=await Promise.all([b7(`/v1/base/collections/activities/records?perPage=150&sort=-at,-created`),b7(`/v1/base/collections/people/records?perPage=250`)]),n=new Map((t.items??[]).map(e=>[String(e.id),e])),r=(e.items??[]).filter(e=>e.kind===`form`||e.data?.program).map((e,t)=>{let r=e.data??{},i=n.get(String(e.person_id??``))??{};return{id:String(e.id??t),name:String(e.subject??r.need??r.description??``),program:String(r.program??r.kind??`feedback`),email:String(i.email??r.email??``),company:String(i.company??i.name??r.company??``),source:String(r.source??e.channel??``),recordCode:String(r.public_ref??e.source_id??e.id??``),closeDate:C7(e.at??e.created)}});return{rows:r,total:e.totalItems??r.length}}case`errors`:{let e=await b7(`/v1/event/errors?limit=100`),t=(Array.isArray(e)?e:e.items??e.errors??[]).map((e,t)=>{let n=String(e.environment??e.env??``),r=String(e.release??``);return{id:String(e.id??e.event_id??t),name:String(e.value??e.message??e.title??``),program:String(e.type??e.class??e.name??``),company:String(e.app??e.service??e.product??``),location:String(e.culprit??e.origin??e.path??``),source:[n,r].filter(Boolean).join(` · `),recordCode:String(e.issue??e.id??e.event_id??``),closeDate:C7(e.timestamp??e.time??e.created_at)}});return{rows:t,total:t.length}}case`lists`:{let e=await b7(`/v1/crm/lists`),t=(e.items??[]).map(e=>({id:String(e.id),name:String(e.name??``),purpose:String(e.purpose??e.kind??``),totalCount:Number(e.total_count??e.eligible_count??0),eligibleCount:Number(e.eligible_count??e.total_count??0),description:String(e.description??``)}));return{rows:t,total:e.total??t.length}}}},Uae={investors:Nae,funds:Pae,customers:Fae,leads:Iae,feedback:Rae,errors:zae,lists:Lae},Wae={investors:{title:`Investors`,icon:(0,H.jsx)(Am,{size:14})},funds:{title:`Funds`,icon:(0,H.jsx)(bp,{size:14})},customers:{title:`Customers`,icon:(0,H.jsx)(Im,{size:14})},leads:{title:`Developer Leads`,icon:(0,H.jsx)(Bm,{size:14})},feedback:{title:`Feedback, Bugs & Forms`,icon:(0,H.jsx)(Up,{size:14})},errors:{title:`Runtime & CLI Errors`,icon:(0,H.jsx)(lp,{size:14})},lists:{title:`Lists & Segments`,icon:(0,H.jsx)(Zp,{size:14})}},Gae=[{id:`all`,label:`Institutional VCs`},{id:`crypto_vc`,label:`Crypto / Web3 VCs`},{id:`accredited`,label:`Accredited High-Check`},{id:`family_office`,label:`Family Offices`},{id:`crowdfunding_republic`,label:`Republic / Reg CF`}],Kae=[`all`,`0-100`,`100-500`,`500-1000`,`1000-5000`,`5000-15000`,`15000+`];function qae(){let{section:e}=Ci(),t=Mae.includes(e)?e:`investors`,[n,r]=(0,V.useState)(`all`),[i,o]=(0,V.useState)(`all`),[s,c]=(0,V.useState)(null),[l,u]=(0,V.useState)(null),[d,f]=(0,V.useState)(!1),[p,m]=(0,V.useState)(null),h=(0,V.useCallback)(async()=>{f(!0),m(null),u(null);try{c(await Hae(t,n,i))}catch(e){c(null),u(e instanceof Error?e.message:`The read failed.`)}finally{f(!1)}},[t,n,i]);(0,V.useEffect)(()=>{h()},[h]);let g=Uae[t],_=(0,V.useMemo)(()=>TH(t),[t]),{title:v,icon:b}=Wae[t],x=(e,t,n)=>(0,H.jsx)(y,{height:36,px:`$3`,items:`center`,gap:`$1.5`,borderBottomWidth:1,borderColor:`$borderColor`,bg:`$background`,children:e.map(e=>(0,H.jsx)(W,{size:`xs`,height:24,px:`$2`,rounded:`$2`,chromeless:t!==e.id,bg:t===e.id?`$color3`:`transparent`,onPress:()=>n(e.id),children:(0,H.jsx)(a,{fontSize:11,fontWeight:t===e.id?`600`:`400`,color:t===e.id?`$color12`:`$color10`,children:e.label})},e.id))});return(0,H.jsx)(Lt,{value:`compact`,children:(0,H.jsxs)(z,{flex:1,minH:0,bg:`$background`,children:[(0,H.jsxs)(y,{height:44,px:`$3`,items:`center`,justify:`space-between`,borderBottomWidth:1,borderColor:`$borderColor`,gap:`$2`,children:[(0,H.jsxs)(y,{items:`center`,gap:`$2`,children:[(0,H.jsx)(y,{width:22,height:22,rounded:`$2`,items:`center`,justify:`center`,style:{backgroundColor:_.background,color:_.color},children:b}),(0,H.jsx)(a,{fontSize:14,fontWeight:`600`,color:`$color12`,children:v}),s?(0,H.jsx)(a,{fontSize:12,color:`$color10`,children:`${s.total.toLocaleString()} total`}):null]}),(0,H.jsx)(W,{size:`xs`,height:24,px:`$2`,chromeless:!0,startIcon:(0,H.jsx)(gm,{size:12}),onPress:()=>void h(),children:(0,H.jsx)(a,{fontSize:12,color:`$color10`,children:`Refresh`})})]}),t===`leads`?x(Kae.map(e=>({id:e,label:e===`all`?`All`:`★ ${e}`})),n,r):null,t===`investors`?x(Gae,i,o):null,l?(0,H.jsxs)(z,{p:`$4`,gap:`$2`,children:[(0,H.jsx)(a,{fontSize:13,fontWeight:`600`,color:`$color12`,children:`This list could not be read.`}),(0,H.jsx)(a,{fontSize:12,color:`$color10`,children:l})]}):(0,H.jsxs)(y,{flex:1,minW:0,minH:0,children:[(0,H.jsx)(G_,{flex:1,minW:0,minH:0,children:(0,H.jsx)(J0,{fields:g,records:s?.rows??[],loading:d,editable:!1,selectable:!1,defaultKind:`table`,boardDisabled:!0,fieldIcons:Bae,onOpen:e=>m(e),empty:`No records.`},t)}),p?(0,H.jsxs)(z,{width:380,shrink:0,borderLeftWidth:1,borderColor:`$borderColor`,bg:`$background`,children:[(0,H.jsxs)(y,{height:44,px:`$3`,items:`center`,justify:`space-between`,borderBottomWidth:1,borderColor:`$borderColor`,children:[(0,H.jsx)(a,{fontSize:13,fontWeight:`600`,color:`$color12`,numberOfLines:1,children:String(p.name||p.email||`Record`)}),(0,H.jsx)(W,{size:`xs`,width:26,height:26,p:`$0`,chromeless:!0,onPress:()=>m(null),children:(0,H.jsx)(Rn,{size:14,color:`$color10`})})]}),(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsx)(z,{p:`$3`,children:(0,H.jsx)(r0,{fields:g,record:p})})})]}):null]})]})})}var w7=()=>{let e=Math.floor(Date.now()/1e3),t=crypto.getRandomValues(new Uint8Array(8));return e.toString(16).padStart(8,`0`)+Array.from(t,e=>e.toString(16).padStart(2,`0`)).join(``)},T7=(e,t)=>({_id:w7(),space:`core:space:Tx`,objectSpace:e,modifiedBy:t,modifiedOn:Date.now()}),E7=(e,t,n,r,i=w7())=>({...T7(e,t),_class:L8.create,objectId:i,objectClass:n,attributes:r}),D7=(e,t,n)=>({...T7(e.space,t),_class:L8.update,objectId:e._id,objectClass:e._class,operations:n}),O7=(e,t)=>({...T7(e.space,t),_class:L8.remove,objectId:e._id,objectClass:e._class}),k7=`0123456789abcdefghijklmnopqrstuvwxyz`,A7=0,Jae=35,j7=k7[18],M7=(e,t)=>k7.indexOf(e[t]),N7=(e,t)=>{let n=e??``,r=t??``,i=0;for(;i<n.length&&i<r.length&&n[i]===r[i];)i++;return n.slice(0,i)+Yae(n.slice(i),r.slice(i))},Yae=(e,t)=>{if(t===``)return P7(e);if(e===``)return F7(t);let n=M7(e,0),r=M7(t,0);return r-n>1?k7[Math.floor((n+r)/2)]:e[0]+P7(e.slice(1))},P7=e=>{for(let t=e.length-1;t>=0;t--)if(M7(e,t)<Jae)return e.slice(0,t)+k7[M7(e,t)+1];return e+j7},F7=e=>{let t=M7(e,0);return t>1?k7[Math.floor(t/2)]:t===1?k7[A7]+j7:k7[A7]+F7(e.slice(1))},I7=[R8.backlog,R8.todo,R8.doing,R8.done],L7=e=>e.find(I8.project),R7=(e,t)=>e.one(I8.project,{_id:t}),z7=async(e,t)=>{let n=await e.find(I8.status,t?{space:t}:{}),r=new Map(I7.map((e,t)=>[e,t]));return n.sort((e,t)=>(r.get(e.category)??I7.length)-(r.get(t.category)??I7.length)||(e.rank??``).localeCompare(t.rank??``))},B7=async(e,t)=>(await e.find(I8.issue,t?{space:t}:{})).sort((e,t)=>(e.rank??``).localeCompare(t.rank??``)||e.number-t.number),V7=e=>e.find(I8.person),H7=e=>e.find(I8.tag),Xae=e=>e.find(I8.component),U7={projects:()=>V8(I8.project),statuses:e=>V8(I8.status,e),issues:e=>V8(I8.issue,e),people:()=>V8(I8.person),tags:()=>V8(I8.tag),components:()=>V8(I8.component)},Zae=(e,t,n,r,i={})=>e.write(D7(n,t,{status:r,rank:N7(i.before?.rank,i.after?.rank)})),W7=(e,t,n,r)=>e.write(D7(n,t,r)),Qae=(e,t,n,r)=>e.write(E7(n,t,I8.issue,{title:r.title,status:r.status,priority:r.priority,number:r.number,rank:N7(void 0,r.after?.rank),assignee:null,subIssues:0,comments:0,attachments:0,estimation:0,reportedTime:0,remainingTime:0})),$ae=[`issues`,`components`,`milestones`,`templates`],eoe=e=>e[0].toUpperCase()+e.slice(1),toe=()=>{let[e,t]=(0,V.useState)(``),{pathname:n}=yi(),{plane:r}=nH(),i=cV(U7.projects(),()=>L7(r),{enabled:!!r}),a=(i.data??[]).filter(t=>t.name.toLowerCase().includes(e.trim().toLowerCase()));return(0,H.jsxs)(T5,{title:g5(n)?.label??`Tracker`,children:[(0,H.jsx)(E5,{value:e,onChange:t}),(0,H.jsx)(z,{height:24}),(0,H.jsx)(k5,{to:`/mine`,icon:(0,H.jsx)(Gp,{size:16,color:`$soft`}),children:`My issues`}),(0,H.jsx)(k5,{to:`/issues`,icon:(0,H.jsx)(Tm,{size:16,color:`$soft`}),children:`All issues`}),(0,H.jsx)(D5,{}),(0,H.jsx)(k5,{to:`/projects`,icon:(0,H.jsx)(dp,{size:16,color:`$soft`}),children:`All projects`}),(0,H.jsx)(D5,{}),(0,H.jsxs)(A5,{children:[(0,H.jsx)(O5,{children:`Your projects`}),i.phase===`loading`?(0,H.jsx)(z,{px:10,py:12,children:(0,H.jsx)(rv,{size:16})}):null,i.phase===`failure`?(0,H.jsx)(K7,{children:`Your projects could not be read.`}):null,i.phase===`ready`&&a.length===0?(0,H.jsx)(K7,{children:e.trim()?`No project by that name.`:`No projects yet.`}):null,a.map(e=>(0,H.jsx)(noe,{project:e},e._id))]})]})},noe=({project:e})=>{let t=Ci().id===e._id,[n,r]=(0,V.useState)(t);return(0,H.jsxs)(z,{children:[(0,H.jsx)(Hie,{open:n,onPress:()=>r(!n),icon:(0,H.jsx)(roe,{id:e._id}),children:e.name}),n?(0,H.jsx)(Uie,{children:$ae.map(t=>(0,H.jsx)(k5,{to:`/projects/${e._id}/${t}`,indent:!0,children:eoe(t)},t))}):null]})},G7=[`M8 1.5 14.5 8 8 14.5 1.5 8Z`,`M8 1.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13Z`,`M8 1.5 15 14.5H1Z`,`M2 2h12v12H2Z`],roe=({id:e})=>(0,H.jsx)(`svg`,{width:16,height:16,viewBox:`0 0 16 16`,fill:`none`,"aria-hidden":!0,children:(0,H.jsx)(`path`,{d:G7[wH(e)%G7.length],stroke:EH(e),strokeWidth:1.5,strokeLinejoin:`round`})}),K7=({children:e})=>(0,H.jsx)(a,{px:10,py:8,fontSize:Z.small,color:`$faint`,children:e}),q7=async(e,t)=>{let n=await e.find(I8.notice,{space:t});return(n.length>0?n:await e.find(I8.notice)).sort((e,t)=>t.modifiedOn-e.modifiedOn)},ioe=async(e,t)=>{let[n,r,i]=await Promise.all([e.find(I8.channel,{space:t}),e.find(I8.issue),e.find(I8.project)]),a=n.length>0?n:await e.find(I8.channel),o=new Map;for(let e of i)o.set(e._id,e.name);for(let e of a)o.set(e._id,`#${e.name}`);for(let e of r){let t=o.get(e.space);t&&o.set(e._id,t)}return o},aoe=(e,t,n)=>e.write(D7(n,t,{isViewed:!0})),J7={[R8.backlog]:`backlog`,[R8.todo]:`todo`,[R8.doing]:`progress`,[R8.done]:`done`,[R8.cancelled]:`done`},ooe=[void 0,`urgent`,`high`,`medium`,`low`],Y7={urgent:z8.urgent,high:z8.high,medium:z8.medium,low:z8.low},soe=e=>{let t=e.estimation??0;return t<=0?0:Math.max(0,Math.min(1,(e.reportedTime??0)/t))},X7=e=>({id:e._id,name:B8(e),face:e.avatar??void 0}),coe=(e,t)=>{let n=[e.assignee,...e.collaborators??[]].filter(e=>!!e),r=new Set,i=[];for(let e of n){if(r.has(e))continue;r.add(e);let n=t.get(e);n&&i.push(X7(n))}return i},loe=(e,t)=>({id:e._id,key:Qre(t.project??t.projects.get(e.space),e),title:e.title,description:e.description,projectId:e.space,status:t.columns.get(e.status)??`backlog`,priority:ooe[e.priority]??void 0,labels:t.words.get(e._id)??[],done:soe(e),people:coe(e,t.crowd),origin:e.component?uoe(t.parts.get(e.component)):void 0,files:e.attachments??0,replies:e.comments??0}),uoe=e=>e?{name:e}:void 0,Z7=e=>new Map(e.map(e=>[e._id,J7[e.category]??`backlog`])),doe=(e,t)=>async(n,r,i)=>{let a=t??`proj-crm`,[o,s,c]=await Promise.all([B7(e,a),z7(e,a),R7(e,a)]),l=s.find(e=>(J7[e.category]??`backlog`)===n)??s[0];if(!l)throw Error(`this project has no ${n} column`);let u=Math.max(c?.sequence??0,...o.map(e=>e.number))+1,d=i?.priority?Y7[i.priority]:0;if(await Qae(e,e.account??``,a,{title:r,status:l._id,priority:d,number:u,after:o.find(e=>e.status===l._id)}),i&&(i.description||i.assigneeId||i.labels&&i.labels.length>0)){let t=(await B7(e,a)).find(e=>e.number===u&&e.title===r);if(t&&(await W7(e,e.account??``,t,{...i.description===void 0?{}:{description:i.description},...i.assigneeId===void 0?{}:{assignee:i.assigneeId,collaborators:i.assigneeId?[i.assigneeId]:[]}}),i.labels&&i.labels.length>0))for(let n of i.labels)await e.write(E7(a,e.account??``,I8.tag,{attachedTo:t._id,attachedToClass:I8.issue,collection:`labels`,tag:`tag-${n.toLowerCase()}`,title:n}))}},foe=(e,t)=>({watch(n,r){let i=!0,a=()=>{Promise.all([z7(e,t),B7(e,t),V7(e),H7(e),Xae(e),L7(e)]).then(async([r,a,o,s,c,l])=>{if(!i)return;let u=t&&a.length?await R7(e,t):void 0;if(!i)return;let d=new Map;for(let e of s){let t=d.get(e.attachedTo);t?t.push(e.title):d.set(e.attachedTo,[e.title])}let f={columns:Z7(r),crowd:new Map(o.map(e=>[e._id,e])),words:d,parts:new Map(c.map(e=>[e._id,e.label])),project:u,projects:new Map(l.map(e=>[e._id,e]))};n(a.map(e=>loe(e,f)))}).catch(e=>i&&r(e instanceof Error?e:Error(String(e))))};a();let o=e.watch(a);return()=>{i=!1,o()}},add:doe(e,t),async move(n,r,i){let a=await B7(e,t),o=a.find(e=>e._id===n);if(!o)throw Error(`no issue to move`);let s=(await z7(e,o.space)).find(e=>(J7[e.category]??`backlog`)===r);if(!s)throw Error(`no column to move into`);let c=a.filter(e=>e.status===s._id&&e._id!==n),l=i?c.findIndex(e=>e._id===i):c.length,u=l<0?c.length:l;await Zae(e,e.account??``,o,s._id,{before:c[u-1],after:c[u]})},async update(n,r){let i=(await B7(e,t)).find(e=>e._id===n);if(!i)return;let a={};if(r.title!==void 0&&(a.title=r.title),r.description!==void 0&&(a.description=r.description),r.priority!==void 0&&(a.priority=r.priority?Y7[r.priority]:0),r.done!==void 0){let e=i.estimation&&i.estimation>0?i.estimation:100;a.estimation=e,a.reportedTime=Math.round(Math.max(0,Math.min(1,r.done))*e)}if(r.assigneeId!==void 0){a.assignee=r.assigneeId;let e=(i.collaborators??[]).filter(e=>e!==r.assigneeId);a.collaborators=r.assigneeId?[r.assigneeId,...e]:e}if(r.replies!==void 0&&(a.comments=r.replies),r.status!==void 0){let t=(await z7(e,i.space)).find(e=>(J7[e.category]??`backlog`)===r.status);t&&(a.status=t._id)}if(Object.keys(a).length>0&&await W7(e,e.account??``,i,a),r.labels!==void 0){let t=(await H7(e)).filter(e=>e.attachedTo===n);for(let n of t)await e.write(O7(n,e.account??``));for(let t of r.labels)await e.write(E7(i.space,e.account??``,I8.tag,{attachedTo:n,attachedToClass:I8.issue,collection:`labels`,tag:`tag-${t.toLowerCase()}`,title:t}))}},async remove(n){let r=(await B7(e,t)).find(e=>e._id===n);r&&await e.write(O7(r,e.account??``))}}),Q7=e=>{let{plane:t,current:n}=nH();return(0,V.useMemo)(()=>t&&n?foe(t,e):null,[t,n,e])},$7=e=>{let{plane:t}=nH(),n=cV(U7.people(),()=>V7(t),{enabled:!!t}),r=cV(U7.projects(),()=>L7(t),{enabled:!!t}),i=e?(r.data??[]).find(t=>t._id===e)?.members:void 0,a=new Map((n.data??[]).map(e=>[e._id,e]));return(i?i.map(e=>a.get(e)):n.data??[]).filter(e=>!!e).map(X7)},e9=e=>e===`refused`?`refused`:e===`homeless`?`nowhere`:`opening`,t9=()=>{let{plane:e}=nH();return cV(U7.projects(),()=>L7(e),{enabled:!!e})},poe=e=>{let t=t9();return e?(t.data??[]).find(t=>t._id===e):void 0},moe=/(@[\w.-]+)/g,n9=(e,t)=>e?[{text:e,[t]:!0}]:[],hoe=(e,t,n)=>{let r=[{text:e,strong:!0}];return(n?t.split(n):[t]).forEach((e,t)=>{t>0&&r.push(...n9(n,`strong`));for(let t of e.split(moe))t&&(t.startsWith(`@`)?r.push(...n9(t,`mention`)):r.push({text:t}))}),r.map((e,t)=>t===1&&e.text?{...e,text:` ${e.text}`}:e)},goe=(e,t,n)=>{let r=t.get(String(e.modifiedBy??``)),i=r?B8(r):`Somebody`,a=n.get(String(e.attachedTo??``));return{id:e._id,kind:e.attachedToClass===I8.channel||e.attachedToClass===I8.direct||e.attachedToClass===I8.message?`chat`:`task`,actor:{name:i,face:r?.avatar??void 0},line:hoe(i,e.body??e.title??``,a),at:e.modifiedOn,place:a,seen:e.isViewed}},_oe=()=>{let{plane:e,current:t,standing:n}=nH();return(0,V.useEffect)(()=>{if(!e||!t){let e=e9(n);RH({list:e===`refused`?()=>Promise.reject(Error(`Your workspace is not answering.`)):e===`nowhere`?()=>Promise.resolve([]):()=>new Promise(()=>{}),see:()=>Promise.resolve()});return}let r=t.uuid;RH({async list(){let[t,n,i]=await Promise.all([q7(e,r),V7(e),ioe(e,r)]),a=new Map(n.map(e=>[e._id,e]));return t.map(e=>goe(e,a,i))},async see(t){let n=(await q7(e,r)).find(e=>e._id===t);n&&!n.isViewed&&await aoe(e,e.account??``,n)}})},[e,t,n]),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(voe,{}),(0,H.jsx)(yoe,{})]})},voe=()=>{let e=BH();return(0,V.useEffect)(()=>Iie(e),[e]),null},yoe=()=>{let{plane:e}=nH(),t=cV(U7.statuses(),()=>z7(e),{enabled:!!e}),n=cV(U7.issues(),()=>B7(e),{enabled:!!e}),r=Z7(t.data??[]),i=n.data??[],a=i.filter(e=>r.get(e.status)!==`done`).length,o=i.length?Math.round(a/i.length*100):null;return(0,V.useEffect)(()=>Lie(o),[o]),null},r9=({glyph:e,n:t,label:n})=>t>0?(0,H.jsxs)(y,{items:`center`,gap:4,"aria-label":`${t} ${n}`,children:[e,(0,H.jsx)(a,{fontSize:`$3`,color:`$dim`,children:t})]}):null,i9=[`backlog`,`todo`,`progress`,`done`],a9=[`low`,`medium`,`high`,`urgent`],o9={backlog:`Backlog`,todo:`To do`,progress:`In progress`,done:`Done`},boe={urgent:1,high:2,medium:3,low:4},s9=(e,t)=>t&&e.toLowerCase()===t?OH(boe[t]):TH(e),c9={backlog:SH.backlog,todo:SH.todo,progress:SH.doing,done:SH.done},l9={arc:X.accent,track:X.rule},u9=({done:e,size:t=16,width:n=2})=>{let r=Math.min(1,Math.max(0,e)),i=(t-n)/2,a=2*Math.PI*i;return(0,H.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 ${t} ${t}`,role:`img`,"aria-label":`${Math.round(r*100)}% done`,children:[(0,H.jsx)(`circle`,{cx:t/2,cy:t/2,r:i,fill:`none`,stroke:l9.track,strokeWidth:n}),r>0?(0,H.jsx)(`circle`,{cx:t/2,cy:t/2,r:i,fill:`none`,stroke:l9.arc,strokeWidth:n,strokeLinecap:`round`,strokeDasharray:`${a*r} ${a}`,transform:`rotate(-90 ${t/2} ${t/2})`}):null]})},d9=12,xoe=48,Soe=({issue:e,dragging:t,onOpen:n,...r})=>{let i=e.priority?[woe(e.priority),...e.labels]:e.labels;return(0,H.jsxs)(z,{"data-slot":`issue`,"data-issue":e.id,bg:`$raised`,rounded:Q.card,overflow:`hidden`,opacity:t?.4:1,cursor:n?`pointer`:`grab`,hoverStyle:{background:`$hover`},role:`article`,tabIndex:0,"aria-label":`${e.key} ${e.title}`,onPress:()=>n?.(e),...Toe(r),children:[(0,H.jsxs)(z,{p:d9,gap:kH.tight,children:[e.cover?(0,H.jsx)(lo,{src:e.cover,alt:``,width:`100%`,aspectRatio:1.44,rounded:`$1`,mb:4}):null,(0,H.jsx)(y,{items:`center`,justify:`space-between`,gap:6,children:(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`600`,color:`$dim`,children:e.key})}),(0,H.jsx)(a,{fontSize:Z.body,lineHeight:20,color:`$ink`,style:Doe,children:e.title}),i.length>0?(0,H.jsx)(y,{gap:kH.tight,flexWrap:`wrap`,children:i.map(t=>{let{background:n,color:r}=s9(t,e.priority);return(0,H.jsx)(Zh,{variant:`default`,style:{...Coe,backgroundColor:n},children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,style:{color:r},children:t})},t)})}):null,e.done!==void 0||e.origin?(0,H.jsxs)(y,{items:`center`,gap:`$4`,mt:`$2`,children:[e.done===void 0?null:(0,H.jsxs)(y,{items:`center`,gap:4,children:[(0,H.jsx)(u9,{done:e.done}),(0,H.jsxs)(a,{fontSize:Z.body,color:`$soft`,children:[Math.round(e.done*100),`%`]})]}),e.origin?(0,H.jsx)(Eoe,{name:e.origin.name,mark:e.origin.mark}):null]}):null]}),(0,H.jsx)(Lc,{}),(0,H.jsxs)(y,{height:xoe,px:d9,items:`center`,justify:`space-between`,children:[(0,H.jsx)(h7,{people:e.people}),(0,H.jsxs)(y,{items:`center`,gap:`$3`,children:[(0,H.jsx)(r9,{glyph:(0,H.jsx)(pm,{size:12,color:`$dim`}),n:e.files,label:`attachments`}),(0,H.jsx)(r9,{glyph:(0,H.jsx)(cm,{size:12,color:`$dim`}),n:e.replies,label:`replies`})]})]})]})},Coe={minHeight:18,height:18,paddingHorizontal:8,borderRadius:9999},woe=e=>e[0].toUpperCase()+e.slice(1),Toe=e=>({draggable:!0,...e}),Eoe=({name:e,mark:t})=>(0,H.jsxs)(y,{items:`center`,gap:6,children:[t?(0,H.jsx)(lo,{src:t,alt:``,width:20,height:20,rounded:9999}):(0,H.jsx)(y,{width:20,height:20,rounded:9999,bg:`$edge`,items:`center`,justify:`center`,children:(0,H.jsx)(a,{fontSize:`$1`,color:`$quiet`,children:e[0]?.toUpperCase()})}),(0,H.jsx)(a,{fontSize:`$2`,color:`$quiet`,children:e})]}),Doe={display:`-webkit-box`,WebkitBoxOrient:`vertical`,WebkitLineClamp:3,overflow:`hidden`},Ooe=({column:e,drag:t,over:n,onOver:r,onDrop:i,onAdd:o,onOpen:s,onLift:c,onLand:l})=>{let u=t=>n=>{n.preventDefault(),n.stopPropagation(),i(e.status,t)},d=t=>n=>{n.preventDefault(),r(e.status,t)};return(0,H.jsxs)(z,{"data-slot":`column`,"data-status":e.status,flex:1,minW:240,shrink:0,gap:kH.tight,role:`list`,"aria-label":e.name,onDragOver:d(`end`),onDrop:u(),children:[(0,H.jsxs)(y,{items:`center`,gap:kH.tight,height:24,children:[(0,H.jsx)(z,{width:8,height:8,rounded:9999,shrink:0,style:{backgroundColor:c9[e.status]}}),(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`700`,color:`$ink`,...AH,children:e.name}),(0,H.jsxs)(a,{fontSize:Z.small,color:`$dim`,children:[`– `,e.issues.length]}),(0,H.jsx)(y,{flex:1}),o?(0,H.jsxs)(Bg,{children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(W,{variant:`ghost`,size:`icon-sm`,"aria-label":`${e.name} actions`,children:(0,H.jsx)(cp,{size:14})})}),(0,H.jsx)(Kg,{align:`end`,children:(0,H.jsx)(Xg,{onSelect:()=>o(e.status),children:`Add issue`})})]}):null]}),o?(0,H.jsx)(W,{variant:`ghost`,height:36,width:`100%`,borderWidth:1,borderStyle:`dashed`,borderColor:`$edge`,rounded:Q.card,"aria-label":`Add issue to ${e.name}`,onPress:()=>o(e.status),children:(0,H.jsx)(hm,{size:16})}):null,e.issues.map(e=>(0,H.jsxs)(z,{role:`listitem`,gap:kH.tight,onDragOver:d(e.id),onDrop:u(e.id),children:[t&&n===e.id?(0,H.jsx)(f9,{height:t.cover?260:176}):null,(0,H.jsx)(Soe,{issue:e,dragging:t?.id===e.id,onOpen:s,onDragStart:()=>c(e),onDragEnd:l})]},e.id)),t&&n===`end`?(0,H.jsx)(f9,{height:t.cover?260:176}):null,(0,H.jsx)(z,{flex:1,minH:24})]})},f9=({height:e})=>(0,H.jsx)(z,{height:e,rounded:Q.card,borderWidth:1,borderStyle:`dashed`,borderColor:`$edge`}),p9=e=>i9.map(t=>({status:t,name:o9[t],issues:e.filter(e=>e.status===t)})),m9=(e,t,n,r)=>{let i=e.find(e=>e.id===t);if(!i||i.status===n&&r===void 0&&koe(e,n)?.id===t||t===r)return e;let a=e.filter(e=>e.id!==t),o={...i,status:n},s=r?a.findIndex(e=>e.id===r):-1;if(s<0){let e=a.map(e=>e.status===n).lastIndexOf(!0);return h9(a,e<0?a.length:e+1,o)}return h9(a,s,o)},h9=(e,t,n)=>[...e.slice(0,t),n,...e.slice(t)],koe=(e,t)=>e.filter(e=>e.status===t).at(-1),g9=10,_9=14,Aoe=({source:e,only:t,onOpen:n,onCreateIn:r})=>{let[i,a]=(0,V.useState)(null),[o,s]=(0,V.useState)(null),[c,l]=(0,V.useState)(null),[u,d]=(0,V.useState)(null),[f,p]=(0,V.useState)(0);(0,V.useEffect)(()=>(a(null),s(null),e.watch(e=>{a(e),s(null)},s)),[e,f]);let m=(0,V.useCallback)((t,n)=>{d(null);let r=c;l(null),r&&i&&(a(m9(i,r.id,t,n)),e.move(r.id,t,n).catch(s))},[c,i,e]),h=e.add?.bind(e),g=r??(h?e=>{h(e,`New issue`).catch(s)}:void 0);if(o)return(0,H.jsx)(Noe,{why:o.message,onRetry:()=>p(e=>e+1)});if(!i)return(0,H.jsx)(joe,{});if(i.length===0)return(0,H.jsx)(Moe,{onAdd:g&&(()=>g(`backlog`))});let _=t?.length?i.filter(e=>e.priority&&t.includes(e.priority)):i;return(0,H.jsx)(Mt,{horizontal:!0,contentContainerStyle:{p:_9,gap:g9,shrink:0,grow:1,minW:`100%`},children:p9(_).map(e=>(0,H.jsx)(Ooe,{column:e,drag:c,over:u?.status===e.status?u.before:null,onOver:(e,t)=>d({status:e,before:t}),onDrop:m,onAdd:g,onOpen:n,onLift:l,onLand:()=>{l(null),d(null)}},e.status))})},joe=()=>(0,H.jsx)(y,{p:_9,gap:g9,"aria-busy":!0,"aria-label":`Loading issues`,children:[0,1,2,3].map(e=>(0,H.jsxs)(z,{width:240,gap:`$2`,children:[(0,H.jsx)(lC,{height:12,width:96}),(0,H.jsx)(lC,{height:36}),[0,1,2].map(e=>(0,H.jsx)(lC,{height:176},e))]},e))}),Moe=({onAdd:e})=>(0,H.jsx)(z,{p:_9,items:`flex-start`,children:(0,H.jsx)(JZ,{icon:Qp,title:`No issues yet`,description:`Issues you open appear here, one column per status.`,primary:e?{label:`New issue`,onPress:e}:void 0})}),Noe=({why:e,onRetry:t})=>(0,H.jsxs)(z,{p:_9,gap:`$3`,items:`flex-start`,role:`alert`,children:[(0,H.jsx)(a,{fontSize:`$4`,color:`$ink`,children:e}),(0,H.jsx)(W,{variant:`outline`,size:`sm`,onPress:t,children:`Try again`})]}),Poe=()=>new Promise(()=>{}),v9=e=>({watch(t,n){return e===`refused`&&n(Error(`Your workspace is not answering.`)),e===`nowhere`&&t([]),()=>{}},move:Poe}),y9=16,Foe=12,Ioe=20,Loe=4,Roe=28,zoe=10,Boe=34,b9=[{id:`kanban`,label:`Kanban`,icon:eee},{id:`list`,label:`List`,icon:tm},{id:`timeline`,label:`Timeline`,icon:Sp}],Voe=({trail:e,title:t,base:n,here:r,people:i,only:o,onOnly:s,onAdd:c})=>(0,H.jsxs)(z,{"data-parity-key":`board.head`,pt:Foe,children:[(0,H.jsxs)(y,{px:y9,height:Ioe,items:`center`,gap:8,children:[(0,H.jsx)(Hoe,{steps:e}),(0,H.jsx)(y,{flex:1,minW:0}),i.length>0?(0,H.jsx)(y,{rounded:Q.pill,bg:`$hover`,px:6,py:2,items:`center`,children:(0,H.jsx)(h7,{people:i,size:24,show:4,ground:X.card})}):null,c?(0,H.jsx)(Koe,{onAdd:c}):null]}),(0,H.jsx)(z,{height:Loe}),(0,H.jsx)(y,{px:y9,height:Roe,items:`center`,children:(0,H.jsx)(a,{fontSize:Z.title,fontWeight:`500`,color:`$ink`,children:t})}),(0,H.jsx)(z,{height:zoe}),(0,H.jsxs)(y,{px:10,height:Boe,items:`flex-end`,gap:4,children:[b9.map(e=>(0,H.jsxs)(Woe,{to:e.id===`kanban`?n:`${n}/${e.id}`,here:e.id===r,children:[(0,H.jsx)(e.icon,{size:16,color:e.id===r?`$ink`:`$soft`}),(0,H.jsx)(a,{fontSize:Z.row,color:e.id===r?`$ink`:`$soft`,children:e.label})]},e.id)),(0,H.jsx)(y,{flex:1,minW:0}),(0,H.jsx)(Goe,{only:o,onOnly:s}),c?(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,height:26,mb:3,px:10,items:`center`,gap:6,rounded:Q.field,style:{backgroundColor:X.accent},focusVisibleStyle:jH,"aria-label":`New issue`,onPress:c,children:[(0,H.jsx)(hm,{size:14,color:X.ground}),(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`600`,style:{color:X.ground},children:`New issue`})]}):null]}),(0,H.jsx)(Lc,{borderColor:`$edge`})]}),Hoe=({steps:e})=>(0,H.jsx)(y,{items:`center`,gap:8,minW:0,children:e.map((e,t)=>(0,H.jsxs)(y,{items:`center`,gap:8,minW:0,children:[t>0?(0,H.jsx)(a,{fontSize:Z.small,color:`$faint`,children:`/`}):null,e.to?(0,H.jsx)(y,{asChild:!0,style:Uoe,rounded:Q.field,focusVisibleStyle:jH,children:(0,H.jsx)(ja,{to:e.to,children:(0,H.jsx)(a,{fontSize:Z.small,color:`$soft`,numberOfLines:1,hoverStyle:{color:`$ink`},children:e.label})})}):(0,H.jsx)(a,{fontSize:Z.small,numberOfLines:1,"aria-current":`page`,style:{color:X.accent},children:e.label})]},`${e.label}-${t}`))}),Uoe={flexDirection:`row`,alignItems:`center`},Woe=({to:e,here:t,children:n})=>(0,H.jsx)(z,{asChild:!0,style:{alignItems:`center`},rounded:Q.field,focusVisibleStyle:jH,children:(0,H.jsxs)(ja,{to:e,"aria-current":t?`page`:void 0,children:[(0,H.jsx)(y,{height:30,px:6,items:`center`,gap:8,children:n}),(0,H.jsx)(z,{height:2,width:`100%`,rounded:Q.pill,style:{backgroundColor:t?X.accent:`transparent`}})]})}),Goe=({only:e,onOnly:t})=>{let n=new Set(e),r=r=>t(n.has(r)?e.filter(e=>e!==r):[...e,r]);return(0,H.jsxs)(Bg,{children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,height:30,px:8,items:`center`,gap:8,rounded:Q.field,hoverStyle:{background:`$hover`},focusVisibleStyle:jH,"aria-label":`Filter issues`,children:[(0,H.jsx)(Sm,{size:16,color:e.length?`$ink`:`$soft`}),(0,H.jsx)(a,{fontSize:Z.row,color:e.length?`$ink`:`$soft`,children:e.length?`Filter · ${e.length}`:`Filter`})]})}),(0,H.jsxs)(Kg,{align:`end`,children:[(0,H.jsx)(f_,{children:`Priority`}),a9.map(e=>(0,H.jsx)(Zg,{checked:n.has(e),onCheckedChange:()=>r(e),children:(0,H.jsx)(a,{...AH,fontSize:Z.small,children:e})},e)),e.length?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(p_,{}),(0,H.jsx)(Xg,{onSelect:()=>t([]),children:`Show every priority`})]}):null]})]})},Koe=({onAdd:e})=>(0,H.jsxs)(Bg,{children:[(0,H.jsx)(Hg,{asChild:!0,children:(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,width:24,height:24,items:`center`,justify:`center`,rounded:Q.field,hoverStyle:{background:`$hover`},focusVisibleStyle:jH,"aria-label":`Board actions`,children:(0,H.jsx)(zp,{size:16,color:`$soft`})})}),(0,H.jsx)(Kg,{align:`end`,children:(0,H.jsx)(Xg,{onSelect:e,children:`New issue`})})]}),x9=[`Backend`,`Frontend`,`Devops`,`Feature`,`Design`,`Sales`,`Marketing`,`QA`,`Research`],qoe=[0,.25,.5,.75,1],S9=e=>e[0].toUpperCase()+e.slice(1);function Joe({issue:e,source:t,people:n,onClose:r}){let[i,o]=(0,V.useState)(e.title),[s,c]=(0,V.useState)(e.description??``),[l,u]=(0,V.useState)(``),[d,f]=(0,V.useState)(!1);(0,V.useEffect)(()=>{o(e.title),c(e.description??``)},[e.id,e.title,e.description]);let p=n=>{t.update?t.update(e.id,n):n.status&&t.move(e.id,n.status),f(!0),setTimeout(()=>f(!1),1200)},m=()=>{let t=i.trim()||e.title;p({title:t,description:s.trim()})},h=t=>{let n=e.labels.includes(t)?e.labels.filter(e=>e!==t):[...e.labels,t];p({labels:n})},g=()=>{let t=l.trim();t&&(e.labels.includes(t)||p({labels:[...e.labels,t]}),u(``))},_=e.people[0]?.id??null;return(0,H.jsxs)(z,{"data-slot":`issue-drawer`,width:420,shrink:0,borderLeftWidth:1,borderColor:`$edge`,bg:`$panel`,height:`100%`,children:[(0,H.jsxs)(y,{height:48,px:16,items:`center`,justify:`space-between`,borderBottomWidth:1,borderColor:`$edge`,gap:8,children:[(0,H.jsxs)(y,{items:`center`,gap:8,children:[(0,H.jsx)(z,{width:8,height:8,rounded:9999,style:{backgroundColor:c9[e.status]}}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`700`,color:`$ink`,children:e.key}),e.origin?(0,H.jsx)(y,{px:8,height:20,rounded:9999,bg:`$raised`,borderWidth:1,borderColor:`$edge`,items:`center`,children:(0,H.jsx)(a,{fontSize:Z.chip,color:`$soft`,children:e.origin.name})}):null,d?(0,H.jsxs)(y,{items:`center`,gap:4,px:6,py:2,rounded:Q.pill,bg:`$hover`,children:[(0,H.jsx)(Vt,{size:11,color:`$ink`}),(0,H.jsx)(a,{fontSize:Z.chip,color:`$ink`,children:`Saved`})]}):null]}),(0,H.jsxs)(y,{items:`center`,gap:4,children:[t.remove?(0,H.jsx)(W,{variant:`ghost`,size:`icon-sm`,"aria-label":`Delete issue`,onPress:()=>{t.remove?.(e.id),r()},children:(0,H.jsx)(km,{size:14,color:`$soft`})}):null,(0,H.jsx)(W,{variant:`ghost`,size:`icon-sm`,"aria-label":`Close issue drawer`,onPress:r,children:(0,H.jsx)(Rn,{size:15,color:`$soft`})})]})]}),(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsxs)(z,{p:16,gap:16,children:[(0,H.jsxs)(z,{gap:8,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Title`}),(0,H.jsx)(j_,{height:32,value:i,onChangeText:o,onBlur:m,fontSize:13,fontWeight:`600`,bg:`$raised`,borderColor:`$edge`})]}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Specification & Notes`}),(0,H.jsx)(W,{size:`xs`,height:22,px:8,rounded:Q.field,style:{backgroundColor:X.accent},onPress:m,children:(0,H.jsx)(a,{fontSize:11,fontWeight:`600`,style:{color:X.ground},children:`Save`})})]}),(0,H.jsx)(j_,{height:32,value:s,onChangeText:c,onBlur:m,placeholder:`Add acceptance criteria, PR links, or technical context...`,fontSize:12,bg:`$raised`,borderColor:`$edge`})]}),(0,H.jsx)(Lc,{borderColor:`$edge`}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Workflow Status`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:i9.map(t=>{let n=e.status===t;return(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:10,height:28,rounded:Q.field,items:`center`,gap:6,bg:n?`$hover`:`$raised`,borderWidth:1,borderColor:n?`$ink`:`$edge`,focusVisibleStyle:jH,onPress:()=>p({status:t}),children:[(0,H.jsx)(z,{width:7,height:7,rounded:9999,style:{backgroundColor:c9[t]}}),(0,H.jsx)(a,{fontSize:Z.small,fontWeight:n?`700`:`500`,color:n?`$ink`:`$soft`,children:o9[t]})]},t)})})]}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Priority`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:a9.map(t=>{let n=e.priority===t,{background:r,color:i}=s9(S9(t),t);return(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:10,height:26,rounded:Q.pill,items:`center`,borderWidth:1,borderColor:n?`$ink`:`transparent`,style:{backgroundColor:r},onPress:()=>p({priority:n?null:t}),children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,style:{color:i},children:S9(t)})},t)})})]}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Completion Progress`}),(0,H.jsxs)(y,{items:`center`,gap:6,children:[(0,H.jsx)(u9,{done:e.done??0}),(0,H.jsxs)(a,{fontSize:Z.small,fontWeight:`600`,color:`$ink`,children:[Math.round((e.done??0)*100),`%`]})]})]}),(0,H.jsx)(y,{gap:6,children:qoe.map(t=>{let n=Math.round(t*100),r=Math.round((e.done??0)*100)===n;return(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,flex:1,height:26,rounded:Q.field,items:`center`,justify:`center`,bg:r?`$hover`:`$raised`,borderWidth:1,borderColor:r?`$ink`:`$edge`,onPress:()=>p({done:t}),children:(0,H.jsxs)(a,{fontSize:Z.chip,fontWeight:r?`700`:`500`,color:r?`$ink`:`$soft`,children:[n,`%`]})},n)})})]}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsxs)(y,{items:`center`,gap:6,children:[(0,H.jsx)(Fm,{size:12,color:`$dim`}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Assignee`})]}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:n.slice(0,10).map(e=>{let t=_===e.id;return(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:8,height:28,rounded:Q.pill,items:`center`,gap:6,bg:t?`$hover`:`$raised`,borderWidth:1,borderColor:t?`$ink`:`$edge`,onPress:()=>p({assigneeId:e.id}),children:[(0,H.jsx)(h7,{people:[e],size:18,show:1}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:t?`700`:`500`,color:t?`$ink`:`$soft`,children:e.name.split(` `)[0]})]},e.id)})})]}),(0,H.jsxs)(z,{gap:8,children:[(0,H.jsxs)(y,{items:`center`,gap:6,children:[(0,H.jsx)(Om,{size:12,color:`$dim`}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Labels`})]}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:x9.map(t=>{let n=e.labels.includes(t),{background:r,color:i}=s9(t);return(0,H.jsx)(Zh,{variant:`default`,style:{minHeight:22,height:22,paddingLeft:9,paddingRight:9,borderRadius:9999,cursor:`pointer`,backgroundColor:n?r:`transparent`,borderWidth:1,borderStyle:`solid`,borderColor:n?i:X.rule,opacity:n?1:.7},onClick:()=>h(t),children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,style:{color:n?i:X.mute},children:n?`✓ ${t}`:t})},t)})}),(0,H.jsxs)(y,{gap:6,children:[(0,H.jsx)(j_,{flex:1,height:26,fontSize:11,placeholder:`Add custom label...`,value:l,onChangeText:u,bg:`$raised`,borderColor:`$edge`}),(0,H.jsx)(W,{size:`xs`,height:26,px:10,variant:`outline`,onPress:g,children:(0,H.jsx)(hm,{size:12})})]})]})]})})]})}function Yoe({initialStatus:e=`backlog`,people:t,onCreate:n,onClose:r}){let[i,o]=(0,V.useState)(``),[s,c]=(0,V.useState)(``),[l,u]=(0,V.useState)(e),[d,f]=(0,V.useState)(`medium`),[p,m]=(0,V.useState)(t[0]?.id??null),[h,g]=(0,V.useState)([`Feature`]),[_,v]=(0,V.useState)(!1),b=e=>{g(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])},x=async()=>{let e=i.trim();if(e&&!_){v(!0);try{await n(l,e,{description:s.trim()||void 0,priority:d,assigneeId:p,labels:h}),r()}finally{v(!1)}}};return(0,H.jsx)(z,{position:`fixed`,t:0,l:0,r:0,b:0,z:1e3,bg:X.ground,items:`center`,justify:`center`,p:16,children:(0,H.jsxs)(z,{width:`100%`,maxW:520,rounded:Q.card,borderWidth:1,borderColor:`$edge`,bg:`$panel`,overflow:`hidden`,children:[(0,H.jsxs)(y,{height:46,px:16,items:`center`,justify:`space-between`,borderBottomWidth:1,borderColor:`$edge`,children:[(0,H.jsxs)(y,{items:`center`,gap:8,children:[(0,H.jsx)(vp,{size:15,color:`$ink`}),(0,H.jsx)(a,{fontSize:Z.body,fontWeight:`700`,color:`$ink`,children:`Create New Issue`})]}),(0,H.jsx)(W,{variant:`ghost`,size:`icon-sm`,"aria-label":`Close modal`,onPress:r,children:(0,H.jsx)(Rn,{size:15,color:`$soft`})})]}),(0,H.jsxs)(z,{p:16,gap:14,children:[(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Issue Title`}),(0,H.jsx)(j_,{autoFocus:!0,placeholder:`e.g. Wire real-time webhook retry metrics in hanzo/cloud`,value:i,onChangeText:o,fontSize:13,bg:`$raised`,borderColor:`$edge`})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Description & Acceptance Criteria`}),(0,H.jsx)(j_,{placeholder:`Context, repository, and target milestone...`,value:s,onChangeText:c,fontSize:12,bg:`$raised`,borderColor:`$edge`})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Status`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:i9.map(e=>{let t=l===e;return(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:10,height:26,rounded:Q.field,items:`center`,gap:6,bg:t?`$hover`:`$raised`,borderWidth:1,borderColor:t?`$ink`:`$edge`,onPress:()=>u(e),children:[(0,H.jsx)(z,{width:7,height:7,rounded:9999,style:{backgroundColor:c9[e]}}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:t?`700`:`500`,color:t?`$ink`:`$soft`,children:o9[e]})]},e)})})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Priority`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:a9.map(e=>{let t=d===e,{background:n,color:r}=s9(S9(e),e);return(0,H.jsx)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:10,height:24,rounded:Q.pill,items:`center`,borderWidth:1,borderColor:t?`$ink`:`transparent`,style:{backgroundColor:n},onPress:()=>f(e),children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,style:{color:r},children:S9(e)})},e)})})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Assign to a team member`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:t.slice(0,8).map(e=>{let t=p===e.id;return(0,H.jsxs)(y,{role:`button`,tabIndex:0,cursor:`pointer`,px:8,height:26,rounded:Q.pill,items:`center`,gap:6,bg:t?`$hover`:`$raised`,borderWidth:1,borderColor:t?`$ink`:`$edge`,onPress:()=>m(e.id),children:[(0,H.jsx)(h7,{people:[e],size:16,show:1}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:t?`700`:`500`,color:t?`$ink`:`$soft`,children:e.name.split(` `)[0]})]},e.id)})})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,color:`$dim`,...AH,children:`Labels`}),(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:x9.slice(0,6).map(e=>{let t=h.includes(e),{background:n,color:r}=s9(e);return(0,H.jsx)(Zh,{variant:`default`,style:{minHeight:20,height:20,paddingLeft:8,paddingRight:8,borderRadius:9999,cursor:`pointer`,backgroundColor:t?n:`transparent`,borderWidth:1,borderStyle:`solid`,borderColor:t?r:X.rule},onClick:()=>b(e),children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,style:{color:t?r:X.mute},children:e})},e)})})]})]}),(0,H.jsxs)(y,{px:16,py:12,items:`center`,justify:`flex-end`,gap:8,borderTopWidth:1,borderColor:`$edge`,bg:`$raised`,children:[(0,H.jsx)(W,{size:`sm`,variant:`ghost`,onPress:r,children:`Cancel`}),(0,H.jsx)(W,{size:`sm`,style:{backgroundColor:X.accent},disabled:!i.trim()||_,onPress:()=>void x(),children:(0,H.jsx)(a,{fontSize:12,fontWeight:`600`,style:{color:X.ground},children:_?`Creating…`:`Create issue`})})]})]})})}var Xoe={minHeight:18,height:18,paddingHorizontal:8,borderRadius:9999},Zoe=e=>e[0].toUpperCase()+e.slice(1),C9=e=>i9[(i9.indexOf(e)+1)%i9.length]??`backlog`,Qoe=({source:e,only:t,mine:n,onOpen:r,onCreateIn:i})=>{let[o,s]=(0,V.useState)(null),[c,l]=(0,V.useState)(null),[u,d]=(0,V.useState)(0);(0,V.useEffect)(()=>(s(null),l(null),e.watch(e=>{s(e),l(null)},l)),[e,u]);let f=e.add?.bind(e),p=i??(f?e=>void f(e,`New issue`).catch(l):void 0),m=t=>{if(!o)return;let n=C9(t.status);s(m9(o,t.id,n)),e.move(t.id,n).catch(l)};if(c)return(0,H.jsxs)(z,{p:24,gap:`$3`,items:`flex-start`,role:`alert`,children:[(0,H.jsx)(a,{fontSize:`$4`,color:`$ink`,children:c.message}),(0,H.jsx)(W,{variant:`outline`,size:`sm`,onPress:()=>d(e=>e+1),children:`Try again`})]});if(!o)return(0,H.jsx)(z,{p:24,gap:`$3`,"aria-busy":!0,"aria-label":`Loading issue list`,children:[0,1,2,3,4,5].map(e=>(0,H.jsx)(lC,{height:44},e))});let h=t?.length?o.filter(e=>e.priority&&t.includes(e.priority)):o,g=n?h.filter((e,t)=>t%2==0||h.length<=6):h;return g.length===0?(0,H.jsx)(z,{p:24,items:`flex-start`,children:(0,H.jsx)(JZ,{icon:tm,title:`No matching issues`,description:`Issues appear here grouped by workflow status.`,primary:p?{label:`New issue`,onPress:()=>p(`backlog`)}:void 0})}):(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsx)(z,{p:24,gap:20,children:p9(g).map(e=>(0,H.jsxs)(z,{rounded:Q.card,borderWidth:1,borderColor:`$edge`,bg:`$background`,overflow:`hidden`,children:[(0,H.jsxs)(y,{px:16,height:40,items:`center`,gap:kH.tight,bg:`$panel`,borderBottomWidth:+(e.issues.length>0),borderColor:`$edge`,children:[(0,H.jsx)(z,{width:8,height:8,rounded:9999,shrink:0,style:{backgroundColor:c9[e.status]}}),(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`700`,color:`$ink`,...AH,children:e.name}),(0,H.jsx)(a,{fontSize:Z.small,color:`$dim`,children:e.issues.length}),(0,H.jsx)(y,{flex:1}),p?(0,H.jsx)(W,{variant:`ghost`,size:`icon-sm`,"aria-label":`Add issue to ${e.name}`,onPress:()=>p(e.status),children:(0,H.jsx)(hm,{size:14})}):null]}),e.issues.map((e,t)=>{let n=e.priority?[Zoe(e.priority),...e.labels]:e.labels;return(0,H.jsxs)(z,{children:[t>0?(0,H.jsx)(Lc,{borderColor:`$edge`}):null,(0,H.jsxs)(y,{px:16,py:10,items:`center`,gap:12,cursor:r?`pointer`:`default`,hoverStyle:{background:`$hover`},onPress:()=>r?.(e),children:[(0,H.jsx)(y,{...o5(t=>{t?.stopPropagation?.(),m(e)},`Advance ${e.key} status`),width:20,height:20,rounded:9999,items:`center`,justify:`center`,borderWidth:1,borderColor:`$edge`,bg:`$panel`,children:(0,H.jsx)(z,{width:8,height:8,rounded:9999,style:{backgroundColor:c9[e.status]}})}),(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`600`,color:`$soft`,width:68,shrink:0,children:e.key}),(0,H.jsx)(a,{fontSize:Z.body,color:`$ink`,flex:1,minW:160,numberOfLines:1,children:e.title}),(0,H.jsxs)(y,{gap:kH.tight,items:`center`,flexWrap:`wrap`,children:[n.map(t=>{let{background:n,color:r}=s9(t,e.priority);return(0,H.jsx)(Zh,{variant:`default`,style:{...Xoe,backgroundColor:n},children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,style:{color:r},children:t})},t)}),e.origin?(0,H.jsx)(y,{px:8,height:18,rounded:9999,bg:`$panel`,borderWidth:1,borderColor:`$edge`,items:`center`,children:(0,H.jsx)(a,{fontSize:Z.chip,color:`$quiet`,children:e.origin.name})}):null]}),(0,H.jsx)(y,{width:64,items:`center`,justify:`flex-end`,gap:4,shrink:0,children:e.done===void 0?null:(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(u9,{done:e.done}),(0,H.jsxs)(a,{fontSize:Z.small,color:`$soft`,children:[Math.round(e.done*100),`%`]})]})}),(0,H.jsxs)(y,{width:64,items:`center`,justify:`flex-end`,gap:`$2`,shrink:0,children:[(0,H.jsx)(r9,{glyph:(0,H.jsx)(pm,{size:12,color:`$dim`}),n:e.files,label:`attachments`}),(0,H.jsx)(r9,{glyph:(0,H.jsx)(cm,{size:12,color:`$dim`}),n:e.replies,label:`replies`})]}),(0,H.jsx)(y,{width:76,justify:`flex-end`,shrink:0,children:(0,H.jsx)(h7,{people:e.people,size:24,show:3})})]})]},e.id)})]},e.status))})})},w9=[{id:`w1`,label:`W1 · Oct 20`,sub:`Sprint 14`},{id:`w2`,label:`W2 · Oct 27`,sub:`Sprint 14`},{id:`w3`,label:`W3 · Nov 03`,sub:`Current · Active`,now:!0},{id:`w4`,label:`W4 · Nov 10`,sub:`Sprint 15`},{id:`w5`,label:`W5 · Nov 17`,sub:`Sprint 15`},{id:`w6`,label:`W6 · Nov 24`,sub:`Release Cut`}],$oe=(e,t)=>{switch(e){case`done`:return{start:t%2==0?0:1,span:2};case`progress`:return{start:1+t%2,span:2};case`todo`:return{start:2+t%2,span:2};default:return{start:3+t%2,span:2}}},ese=({source:e,only:t,mine:n,onOpen:r})=>{let[i,o]=(0,V.useState)(null),[s,c]=(0,V.useState)(null);(0,V.useEffect)(()=>(o(null),c(null),e.watch(e=>{o(e),c(null)},c)),[e]);let l=t=>{if(!i)return;let n=C9(t.status);o(m9(i,t.id,n)),e.move(t.id,n).catch(c)};if(s)return(0,H.jsx)(z,{p:24,children:(0,H.jsx)(a,{fontSize:`$4`,color:`$ink`,children:s.message})});if(!i)return(0,H.jsx)(z,{p:24,gap:`$3`,"aria-busy":!0,"aria-label":`Loading timeline`,children:[0,1,2,3,4].map(e=>(0,H.jsx)(lC,{height:48},e))});let u=t?.length?i.filter(e=>e.priority&&t.includes(e.priority)):i,d=n?u.filter((e,t)=>t%2==0||u.length<=6):u;return d.length===0?(0,H.jsx)(z,{p:24,items:`flex-start`,children:(0,H.jsx)(JZ,{icon:Sp,title:`No issues on timeline`,description:`Scheduled issues and sprint milestones appear here across weeks.`})}):(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsx)(z,{p:24,gap:16,children:(0,H.jsxs)(z,{rounded:Q.card,borderWidth:1,borderColor:`$edge`,bg:`$background`,overflow:`hidden`,children:[(0,H.jsxs)(y,{bg:`$panel`,borderBottomWidth:1,borderColor:`$edge`,height:48,items:`center`,children:[(0,H.jsxs)(y,{width:280,shrink:0,px:16,items:`center`,justify:`space-between`,borderRightWidth:1,borderColor:`$edge`,height:`100%`,children:[(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`700`,color:`$ink`,...AH,children:`Issue / Assignee`}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$soft`,children:[d.length,` tracked`]})]}),(0,H.jsx)(y,{flex:1,height:`100%`,children:w9.map(e=>(0,H.jsxs)(z,{flex:1,px:10,justify:`center`,borderRightWidth:1,borderColor:`$edge`,bg:`now`in e&&e.now?`$hover`:`transparent`,children:[(0,H.jsxs)(y,{items:`center`,gap:6,children:[`now`in e&&e.now?(0,H.jsx)(z,{width:6,height:6,rounded:9999,style:{backgroundColor:X.accent}}):null,(0,H.jsx)(a,{fontSize:Z.small,fontWeight:`600`,color:`now`in e&&e.now?`$ink`:`$soft`,children:e.label})]}),(0,H.jsx)(a,{fontSize:Z.chip,color:`$quiet`,children:e.sub})]},e.id))})]}),d.map((e,t)=>{let{start:n,span:i}=$oe(e.status,t),o=n/w9.length*100,s=i/w9.length*100,c=Math.round((e.done??(e.status===`done`?1:.25))*100);return(0,H.jsxs)(z,{children:[t>0?(0,H.jsx)(Lc,{borderColor:`$edge`}):null,(0,H.jsxs)(y,{height:46,items:`center`,hoverStyle:{background:`$hover`},children:[(0,H.jsxs)(y,{width:280,shrink:0,px:16,gap:8,items:`center`,borderRightWidth:1,borderColor:`$edge`,height:`100%`,cursor:r?`pointer`:`default`,onPress:()=>r?.(e),children:[(0,H.jsx)(z,{width:8,height:8,rounded:9999,shrink:0,style:{backgroundColor:c9[e.status]}}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$soft`,width:54,shrink:0,children:e.key}),(0,H.jsx)(a,{fontSize:Z.small,color:`$ink`,flex:1,numberOfLines:1,children:e.title}),(0,H.jsx)(h7,{people:e.people,size:20,show:1})]}),(0,H.jsxs)(y,{flex:1,height:`100%`,position:`relative`,items:`center`,children:[w9.map(e=>(0,H.jsx)(z,{flex:1,height:`100%`,borderRightWidth:1,borderColor:`$edge`,bg:`now`in e&&e.now?`$panel`:`transparent`},e.id)),(0,H.jsxs)(y,{...o5(()=>l(e),`${e.key} (${c}% done) — click to advance status`),position:`absolute`,style:{left:`${o+1}%`,width:`${s-2}%`},height:26,rounded:Q.field,bg:`$panel`,borderWidth:1,borderColor:`$edge`,overflow:`hidden`,items:`center`,px:8,justify:`space-between`,children:[(0,H.jsx)(z,{position:`absolute`,l:0,t:0,b:0,width:`${c}%`,opacity:.22,pointerEvents:`none`,style:{backgroundColor:c9[e.status]}}),(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$ink`,numberOfLines:1,z:1,children:e.title}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$soft`,shrink:0,ml:6,z:1,children:[c,`%`]})]})]})]})]},e.id)})]})})})},tse=e=>b9.find(t=>t.id===e)?.id??`kanban`,T9=({mine:e=!1})=>{let{id:t,view:n}=Ci(),r=poe(t),{standing:i}=nH(),a=Q7(t)??v9(e9(i)),o=a.add?.bind(a),s=$7(t),[c,l]=(0,V.useState)([]),[u,d]=(0,V.useState)(null),[f,p]=(0,V.useState)([]),[m,h]=(0,V.useState)(null),g=tse(n);(0,V.useEffect)(()=>a.watch(e=>p(e),()=>{}),[a]);let _=u?f.find(e=>e.id===u)??null:null,v=e?`/mine`:t?`/projects/${t}/issues`:`/issues`,b=[{label:`Your projects`,to:`/projects`},...t?[{label:r?.name??`…`,to:v}]:[],{label:e?`My issues`:t?`Issues`:`All issues`}];return(0,H.jsxs)(z,{flex:1,minH:0,children:[(0,H.jsx)(Voe,{trail:b,title:e?`My issues`:t?`Issues`:`All issues`,base:v,here:g,people:s,only:c,onOnly:l,onAdd:o?()=>h(`backlog`):void 0}),(0,H.jsxs)(y,{flex:1,minH:0,minW:0,children:[(0,H.jsx)(z,{flex:1,minH:0,minW:0,children:g===`kanban`?(0,H.jsx)(Aoe,{source:a,only:c,onOpen:e=>d(e.id),onCreateIn:o?e=>h(e):void 0}):g===`list`?(0,H.jsx)(Qoe,{source:a,only:c,mine:e,onOpen:e=>d(e.id),onCreateIn:o?e=>h(e):void 0}):(0,H.jsx)(ese,{source:a,only:c,mine:e,onOpen:e=>d(e.id)})}),_?(0,H.jsx)(Joe,{issue:_,source:a,people:s,onClose:()=>d(null)}):null]}),m&&o?(0,H.jsx)(Yoe,{initialStatus:m,people:s,onCreate:async(e,t,n)=>{await o(e,t,n)},onClose:()=>h(null)}):null]})};function nse(){let e=xi(),{current:t,standing:n}=nH(),r=t9(),i=Q7()??v9(e9(n)),o=$7(),[s,c]=(0,V.useState)([]);(0,V.useEffect)(()=>i.watch(e=>c(e),()=>{}),[i]);let l=r.data??[];return(0,H.jsx)(G_,{flex:1,minH:0,children:(0,H.jsxs)(z,{p:24,gap:20,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,flexWrap:`wrap`,gap:12,children:[(0,H.jsxs)(z,{gap:4,children:[(0,H.jsxs)(a,{...AH,fontSize:Z.chip,fontWeight:`600`,color:`$soft`,children:[t?.name??`Hanzo AI`,` · Portfolio & Tracker`]}),(0,H.jsxs)(a,{fontSize:Z.title,fontWeight:`600`,color:`$ink`,children:[`All projects (`,l.length,`)`]}),(0,H.jsx)(a,{fontSize:Z.body,color:`$quiet`,children:`The projects in this space and the issues on their boards.`})]}),(0,H.jsxs)(y,{gap:8,items:`center`,children:[(0,H.jsx)(h7,{people:o,size:26,show:5}),(0,H.jsxs)(W,{onPress:()=>e(`/issues`),children:[`All Issues (`,s.length,`)`]})]})]}),(0,H.jsx)(y,{flexWrap:`wrap`,gap:16,children:l.map(t=>{let n=t.identifier.toUpperCase(),r=s.filter(e=>e.key.startsWith(`${n}-`)),i=r.length||t.sequence,o=r.filter(e=>e.status===`done`).length,c=r.filter(e=>e.status===`progress`).length,l=r.filter(e=>e.status===`todo`).length,u=r.filter(e=>e.status===`backlog`).length,d=r.length>0?o/r.length:0;return(0,H.jsxs)(z,{width:380,grow:1,p:20,rounded:Q.card,bg:`$background`,borderWidth:1,borderColor:`$edge`,gap:14,children:[(0,H.jsxs)(y,{items:`center`,justify:`space-between`,gap:10,children:[(0,H.jsxs)(y,{items:`center`,gap:10,children:[(0,H.jsx)(z,{width:36,height:36,rounded:Q.field,items:`center`,justify:`center`,bg:`$panel`,borderWidth:1,borderColor:`$edge`,children:(0,H.jsx)(Wp,{size:18,color:`$ink`})}),(0,H.jsxs)(z,{children:[(0,H.jsxs)(y,{items:`center`,gap:8,children:[(0,H.jsx)(a,{fontSize:Z.row,fontWeight:`600`,color:`$ink`,children:t.name}),(0,H.jsx)(y,{px:8,py:2,rounded:Q.pill,style:TH(t.identifier),children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`700`,style:{color:TH(t.identifier).color},children:t.identifier})})]}),(0,H.jsxs)(a,{fontSize:Z.small,color:`$soft`,children:[r.length,` active issues · `,(t.members??[]).length,` members`]})]})]}),(0,H.jsxs)(y,{items:`center`,gap:6,children:[(0,H.jsx)(u9,{done:d,size:20,width:2.5}),(0,H.jsxs)(a,{fontSize:Z.small,fontWeight:`600`,color:`$ink`,children:[Math.round(d*100),`%`]})]})]}),(0,H.jsxs)(z,{gap:6,children:[(0,H.jsxs)(y,{height:6,rounded:Q.pill,bg:`$panel`,overflow:`hidden`,gap:2,children:[(0,H.jsx)(z,{flex:Math.max(1,o),style:{backgroundColor:SH.done}}),(0,H.jsx)(z,{flex:Math.max(1,c),style:{backgroundColor:SH.doing}}),(0,H.jsx)(z,{flex:Math.max(1,l),style:{backgroundColor:SH.todo}}),(0,H.jsx)(z,{flex:Math.max(1,u),style:{backgroundColor:SH.backlog}})]}),(0,H.jsxs)(y,{justify:`space-between`,flexWrap:`wrap`,gap:8,children:[(0,H.jsxs)(a,{fontSize:Z.chip,color:`$quiet`,children:[`Backlog: `,u]}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$quiet`,children:[`To do: `,l]}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$quiet`,children:[`In progress: `,c]}),(0,H.jsxs)(a,{fontSize:Z.chip,color:`$quiet`,children:[`Done: `,o,` / `,i]})]})]}),(0,H.jsxs)(y,{items:`center`,justify:`space-between`,flexWrap:`wrap`,gap:8,children:[(0,H.jsx)(y,{gap:6,flexWrap:`wrap`,children:[[`issues`,`Board`],[`issues/list`,`List`],[`issues/timeline`,`Timeline`]].map(([n,r])=>(0,H.jsx)(y,{...o5(()=>e(`/projects/${t._id}/${n}`),`${t.name} ${r}`),px:10,py:5,rounded:Q.field,bg:`$panel`,borderWidth:1,borderColor:`$edge`,hoverStyle:{background:`$hover`},children:(0,H.jsx)(a,{fontSize:Z.chip,fontWeight:`600`,color:`$soft`,children:r})},n))}),(0,H.jsx)(W,{size:`sm`,onPress:()=>e(`/projects/${t._id}/issues`),children:`Open Board →`})]})]},t._id)})})]})})}var rse=(0,V.lazy)(()=>Le(()=>import(`./Bots-CIxJCKzl.js`).then(e=>({default:e.Bots})),__vite__mapDeps([6,1,2,7,3,4]))),E9=()=>{let{id:e}=Ci();return(0,H.jsx)(Gi,{to:e?`/projects/${e}/issues`:`/projects`,replace:!0})},D9=()=>(0,H.jsx)(Gi,{to:`/chat`,replace:!0}),O9=e=>(0,H.jsx)(x5,{nav:(0,H.jsx)(toe,{}),aside:(0,H.jsx)(z5,{}),children:e}),k9=e=>(0,H.jsx)(x5,{nav:(0,H.jsx)(kae,{}),aside:(0,H.jsx)(nae,{}),children:e}),ise=[{path:`/`,element:(0,H.jsx)(D9,{})},{path:`/login`,element:(0,H.jsx)(D9,{})},{path:`/auth`,element:(0,H.jsx)(D9,{})},{path:`/auth/callback`,element:(0,H.jsx)(D9,{})},{path:`/issues`,element:O9((0,H.jsx)(T9,{}))},{path:`/issues/:view`,element:O9((0,H.jsx)(T9,{}))},{path:`/mine`,element:O9((0,H.jsx)(T9,{mine:!0}))},{path:`/mine/:view`,element:O9((0,H.jsx)(T9,{mine:!0}))},{path:`/projects`,element:O9((0,H.jsx)(nse,{}))},{path:`/projects/:id`,element:(0,H.jsx)(E9,{})},{path:`/projects/:id/issues`,element:O9((0,H.jsx)(T9,{}))},{path:`/projects/:id/issues/:view`,element:O9((0,H.jsx)(T9,{}))},{path:`/projects/:id/:page`,element:(0,H.jsx)(E9,{})},{path:`/chat`,element:k9((0,H.jsx)(g7,{}))},{path:`/chat/:id`,element:k9((0,H.jsx)(g7,{}))},{path:`/bots`,element:(0,H.jsx)(x5,{nav:null,children:(0,H.jsx)(V.Suspense,{fallback:null,children:(0,H.jsx)(rse,{})})})},{path:`/crm`,element:(0,H.jsx)(Gi,{to:`/crm/investors`,replace:!0})},{path:`/crm/:section`,element:(e=>(0,H.jsx)(x5,{nav:(0,H.jsx)(Vae,{}),children:e}))((0,H.jsx)(qae,{}))},{path:`/overview`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/agents`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/agents/:id`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/apps`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/apps/:appId`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/calendar`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/cal`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/time`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/meet`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/inbox`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/docs`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/files`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/mail`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/admin`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/settings`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})},{path:`/people`,element:(0,H.jsx)(Gi,{to:`/crm/investors`,replace:!0})},{path:`*`,element:(0,H.jsx)(Gi,{to:`/chat`,replace:!0})}],ase=()=>{let{land:e}=pV(),[t,n]=(0,V.useState)(null);return(0,V.useEffect)(()=>{e().then(e=>window.location.replace(e)).catch(e=>n(e instanceof Error?e.message:String(e)))},[e]),(0,H.jsxs)(z,{flex:1,minH:`100vh`,bg:X.ground,children:[(0,H.jsx)(y,{width:`100%`,minH:68,px:kH.wide,py:kH.tight,items:`center`,borderBottomWidth:1,borderColor:X.rule,bg:X.ground,children:(0,H.jsx)(y,{items:`center`,gap:kH.tight,cursor:`pointer`,shrink:0,onPress:()=>window.location.assign(`/`),children:(0,H.jsx)(a,{size:Z.row,color:X.ink,fontWeight:`600`,children:`Hanzo ${IB.title}`})})}),(0,H.jsx)(z,{flex:1,items:`center`,justify:`center`,gap:kH.inset,children:t?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(a,{size:Z.body,color:X.alert,children:t}),(0,H.jsx)(a,{size:Z.small,color:X.mute,cursor:`pointer`,onPress:()=>window.location.replace(`/login`),children:`Try again`})]}):(0,H.jsx)(rv,{})})]})},A9=[{id:`chat`,label:`Chat`,scene:0},{id:`projects`,label:`Projects`,scene:1},{id:`tasks`,label:`Tasks`,scene:1},{id:`crm`,label:`CRM`,scene:2},{id:`docs`,label:`Docs`,scene:2}],ose=[`bugfix`,`engineering`,`launch`,`security`,`ops`],j9=`PR #418`,sse=[{name:`Dev`,role:j9,hue:`var(--pv-blue)`},{name:`Sci`,role:`42/42 E2E`,hue:`var(--pv-green)`},{name:`Mark`,role:`v2.4.1`,hue:`var(--pv-amber)`},{name:`Opera`,role:`us-west`,hue:`var(--pv-violet)`}],M9=[{name:`Dev`,domain:`Engineering`,sandbox:`sbx-eng-01`,task:`Merged ${j9} · release PaySheet lock`,badge:`+14 −3`,hue:`var(--pv-blue)`},{name:`Sci`,domain:`QA & Eval`,sandbox:`sbx-webkit-02`,task:`iOS 18.2 Safari checkout suite green`,badge:`42/42 PASS`,hue:`var(--pv-green)`},{name:`Cyber`,domain:`Security`,sandbox:`sbx-sec-03`,task:`Diff & webhook signature audit clean`,badge:`0 CVEs`,hue:`var(--pv-rose)`},{name:`Mark`,domain:`Growth`,sandbox:`sbx-mkt-04`,task:`Drafted release note for #launch`,badge:`READY`,hue:`var(--pv-amber)`},{name:`Opera`,domain:`Infra & SRE`,sandbox:`sbx-sre-05`,task:`Canary rollout 100% healthy · 18ms p95`,badge:`LIVE`,hue:`var(--pv-violet)`},{name:`Fin`,domain:`Revenue Ops`,sandbox:`sbx-fin-06`,task:`Apple Pay settlement ledger reconciled`,badge:`$0 DRIFT`,hue:`var(--pv-green)`}],cse=[{id:0,label:`Chat · #engineering`,short:`Chat`},{id:1,label:`Projects · Board`,short:`Projects`},{id:2,label:`Agents · Live Ops`,short:`Live Ops`}];function N9({pct:e,color:t}){let n=2*Math.PI*6,r=n*(1-Math.max(0,Math.min(100,e))/100);return(0,H.jsxs)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 16 16`,style:{flexShrink:0,transform:`rotate(-90deg)`},children:[(0,H.jsx)(`circle`,{cx:`8`,cy:`8`,r:6,fill:`none`,stroke:`var(--pv-rule-strong)`,strokeWidth:`2`}),(0,H.jsx)(`circle`,{cx:`8`,cy:`8`,r:6,fill:`none`,stroke:t,strokeWidth:`2`,strokeDasharray:n,strokeDashoffset:r,strokeLinecap:`round`,style:{transition:`stroke-dashoffset 0.55s ease`}})]})}function lse({x:e,y:t,label:n}){return(0,H.jsxs)(`div`,{className:`hz-pv-cursor`,style:{transform:`translate3d(${e}px, ${t}px, 0)`},children:[(0,H.jsx)(`svg`,{width:`13`,height:`15`,viewBox:`0 0 14 16`,fill:`none`,children:(0,H.jsx)(`path`,{d:`M1.5 1.2L12.4 7.1L7.3 8.6L4.9 13.7L1.5 1.2Z`,fill:`var(--pv-ink)`,stroke:`var(--pv-bar)`,strokeWidth:`1.2`,strokeLinejoin:`round`})}),(0,H.jsx)(`span`,{className:`hz-pv-cursor-tag`,children:n})]})}var use=()=>{let e=(0,V.useRef)(null),[t,n]=(0,V.useState)(680),[r,i]=(0,V.useState)(0),[a,o]=(0,V.useState)(2),[s,c]=(0,V.useState)(`engineering`),[l,u]=(0,V.useState)(!1);(0,V.useEffect)(()=>{let t=e.current;if(!t)return;let r=()=>{let e=t.getBoundingClientRect().width;e>0&&n(e)};r();let i=new ResizeObserver(r);return i.observe(t),()=>i.disconnect()},[]),(0,V.useEffect)(()=>{if(l)return;let e=window.setInterval(()=>{o(e=>e<3?e+1:(i(e=>(e+1)%3),0))},1650);return()=>window.clearInterval(e)},[l]);let d=e=>{i(e),o(2)},f=t>=540,p=f?640:500,m=f?400:336,h=f?540:412,g=f?338:284,_=f?184:156,v=f?348:292,y=Math.max(.45,Math.min(1.16,t/p)),b=Math.round(m*y),x=r===0?a===0?{x:f?248:124,y:108,label:`◆ Dev`}:a===1?{x:f?316:186,y:184,label:`◆ Dev`}:a===2?{x:f?298:174,y:238,label:`◆ Sci`}:{x:f?344:196,y:g-28,label:`◆ Zoe`}:r===1?a<=1?{x:f?336:188,y:158,label:`◆ Dev`}:{x:f?378:218,y:132,label:`◆ Dev`}:{x:(f?204:84)+a%3*(f?82:68),y:a<2?126:212,label:a%2==0?`◆ Opera`:`◆ Sci`},S=r===1&&a>=2,C=r===1?a===0?76:a===1?84:a===2?94:100:94;return(0,H.jsxs)(`div`,{style:{width:`100%`,maxWidth:740},onPointerEnter:()=>u(!0),onPointerLeave:()=>u(!1),children:[(0,H.jsx)(`div`,{ref:e,className:`hz-pv-host`,style:{height:b},children:(0,H.jsxs)(`div`,{className:`hz-pv-stage`,style:{width:p,height:m,transform:`scale(${y})`},children:[(0,H.jsxs)(`div`,{className:`hz-pv-desk`,style:{width:h,height:g},children:[(0,H.jsxs)(`div`,{className:`hz-pv-topbar`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:7},children:[(0,H.jsxs)(`div`,{className:`hz-pv-traffic`,children:[(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{background:`var(--pv-dot-red)`}}),(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{background:`var(--pv-dot-yellow)`}}),(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{background:`var(--pv-dot-green)`}})]}),(0,H.jsx)(`span`,{style:{color:`var(--pv-mute)`,display:`inline-flex`},children:(0,H.jsx)(fm,{size:12,color:`var(--pv-mute)`})}),(0,H.jsxs)(`span`,{className:`hz-pv-pill`,children:[(0,H.jsx)(`span`,{className:`hz-pv-live-dot`}),(0,H.jsx)(`span`,{children:`hanzo.team`})]})]}),(0,H.jsx)(`div`,{className:`hz-pv-tabs`,role:`tablist`,"aria-label":`Hanzo Team preview surfaces`,children:(f?A9:A9.slice(0,4)).map(e=>{let t=e.id===`chat`&&r===0||e.id===`projects`&&r===1||e.id===`crm`&&r===2;return(0,H.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":t,className:`hz-pv-tab`,"data-active":t?`true`:`false`,onClick:()=>d(e.scene),children:e.label},e.id)})})]}),(0,H.jsxs)(`div`,{className:`hz-pv-body`,children:[(0,H.jsxs)(`div`,{className:`hz-pv-rail`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`button`,{type:`button`,"aria-label":`Hanzo AI organization`,onClick:()=>d(0),style:{width:22,height:22,borderRadius:6,border:0,background:`var(--pv-ink)`,color:`var(--pv-bar)`,fontSize:10,fontWeight:800,cursor:`pointer`,marginBottom:2},children:`H`}),(0,H.jsx)(`button`,{type:`button`,"aria-label":`Chat channels`,className:`hz-pv-rail-btn`,"data-active":r===0?`true`:`false`,onClick:()=>d(0),children:(0,H.jsx)(cm,{size:13,color:r===0?`var(--pv-ink)`:`var(--pv-mute)`})}),(0,H.jsx)(`button`,{type:`button`,"aria-label":`Project boards`,className:`hz-pv-rail-btn`,"data-active":r===1?`true`:`false`,onClick:()=>d(1),children:(0,H.jsx)(Tm,{size:13,color:r===1?`var(--pv-ink)`:`var(--pv-mute)`})}),(0,H.jsx)(`button`,{type:`button`,"aria-label":`Activity inbox`,className:`hz-pv-rail-btn`,"data-active":`false`,onClick:()=>d(0),children:(0,H.jsx)(_p,{size:13,color:`var(--pv-mute)`})}),(0,H.jsx)(`button`,{type:`button`,"aria-label":`Workspace docs`,className:`hz-pv-rail-btn`,"data-active":`false`,onClick:()=>d(1),children:(0,H.jsx)(Up,{size:13,color:`var(--pv-mute)`})}),(0,H.jsx)(`button`,{type:`button`,"aria-label":`AI Teammates`,className:`hz-pv-rail-btn`,"data-active":r===2?`true`:`false`,onClick:()=>d(2),children:(0,H.jsx)(vp,{size:13,color:r===2?`var(--pv-ink)`:`var(--pv-mute)`})})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,alignItems:`center`,gap:5},children:[(0,H.jsx)(`span`,{className:`hz-pv-rail-btn`,"aria-hidden":`true`,children:(0,H.jsx)(ym,{size:12,color:`var(--pv-mute)`})}),(0,H.jsxs)(`div`,{style:{position:`relative`,width:20,height:20,borderRadius:999,background:`var(--pv-send)`,color:`var(--pv-ink)`,fontSize:8,fontWeight:700,display:`flex`,alignItems:`center`,justifyContent:`center`},children:[`ZK`,(0,H.jsx)(`span`,{style:{position:`absolute`,right:-1,bottom:-1,width:6,height:6,borderRadius:999,background:`var(--pv-green)`,border:`1.5px solid var(--pv-rail)`}})]})]})]}),f?(0,H.jsxs)(`div`,{className:`hz-pv-sidebar`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:2},children:[(0,H.jsx)(`div`,{className:`hz-pv-sec-head`,children:`Channels`}),ose.map(e=>{let t=r===0&&s===e;return(0,H.jsxs)(`button`,{type:`button`,className:`hz-pv-nav-row`,"data-active":t?`true`:`false`,onClick:()=>{c(e),d(0)},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:4,minWidth:0},children:[(0,H.jsx)(Yp,{size:10,color:t?`var(--pv-ink)`:`var(--pv-mute)`}),(0,H.jsx)(`span`,{style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:e})]}),e===`engineering`?(0,H.jsx)(`span`,{style:{fontSize:7.5,fontWeight:700,padding:`1px 4px`,borderRadius:999,background:`var(--pv-send)`,color:`var(--pv-ink)`},children:`3`}):null]},e)})]}),(0,H.jsx)(`div`,{style:{height:1,background:`var(--pv-rule)`}}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:2},children:[(0,H.jsx)(`div`,{className:`hz-pv-sec-head`,children:`Teammates`}),sse.map(e=>(0,H.jsxs)(`button`,{type:`button`,className:`hz-pv-nav-row`,"data-active":r===2&&e.name===`Dev`?`true`:`false`,onClick:()=>d(2),children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5},children:[(0,H.jsx)(`span`,{className:`hz-pv-live-dot`}),(0,H.jsx)(`span`,{children:e.name})]}),(0,H.jsx)(`span`,{style:{fontSize:7.5,color:`var(--pv-dim)`},children:e.role})]},e.name))]})]}):null,(0,H.jsxs)(`div`,{className:`hz-pv-main`,children:[r===0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`hz-pv-pane-head`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:6,minWidth:0},children:[(0,H.jsx)(Yp,{size:12,color:`var(--pv-mute)`}),(0,H.jsx)(`span`,{style:{fontSize:10.5,fontWeight:600},children:s}),(0,H.jsx)(`span`,{style:{fontSize:8.5,color:`var(--pv-dim)`,whiteSpace:`nowrap`},children:`· Checkout & Apple Pay`})]}),(0,H.jsx)(`span`,{style:{marginRight:f?78:98,fontSize:8,fontWeight:600,padding:`2px 6px`,borderRadius:999,background:`var(--pv-green-bg)`,border:`1px solid var(--pv-green-edge)`,color:`var(--pv-green)`,flexShrink:0},children:`Agents active`})]}),(0,H.jsxs)(`div`,{style:{flex:1,padding:`8px 11px 6px`,paddingRight:f?96:122,display:`flex`,flexDirection:`column`,gap:7,overflow:`hidden`},children:[(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{display:`flex`,gap:7,alignItems:`flex-start`},children:[(0,H.jsx)(`div`,{style:{width:20,height:20,borderRadius:999,background:`var(--pv-amber)`,color:`var(--pv-bar)`,fontSize:9,fontWeight:800,display:`flex`,alignItems:`center`,justifyContent:`center`,flexShrink:0},children:`Z`}),(0,H.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`baseline`,gap:5,marginBottom:2},children:[(0,H.jsx)(`span`,{style:{fontSize:9.5,fontWeight:600},children:`Zoe`}),(0,H.jsx)(`span`,{style:{fontSize:7.5,color:`var(--pv-dim)`},children:`9:40 AM`})]}),(0,H.jsxs)(`div`,{style:{display:`inline-block`,padding:`5px 9px`,borderRadius:9,background:`var(--pv-bubble)`,color:`var(--pv-bubble-ink)`,fontSize:9.2,lineHeight:1.35,maxWidth:f?`92%`:`88%`},children:[(0,H.jsx)(`span`,{style:{color:`var(--pv-amber)`,fontWeight:600},children:`@Dev`}),` Checkout fails on mobile Safari when Apple Pay closes early.`]})]})]}),a>=1?(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{display:`flex`,gap:7,alignItems:`flex-start`},children:[(0,H.jsx)(`div`,{style:{width:20,height:20,borderRadius:999,background:`var(--pv-blue)`,color:`var(--pv-bar)`,fontSize:9,fontWeight:800,display:`flex`,alignItems:`center`,justifyContent:`center`,flexShrink:0},children:`D`}),(0,H.jsxs)(`div`,{style:{flex:1,minWidth:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:5,marginBottom:2},children:[(0,H.jsx)(`span`,{style:{fontSize:9.5,fontWeight:600},children:`Dev`}),(0,H.jsx)(`span`,{style:{fontSize:7.5,padding:`0.5px 4px`,borderRadius:4,background:`var(--pv-card)`,border:`1px solid var(--pv-rule-strong)`,color:`var(--pv-mute)`},children:`Agent`})]}),(0,H.jsxs)(`div`,{style:{fontSize:9,color:`var(--pv-mute)`,lineHeight:1.32},children:[`PaySheet mutex stayed locked on cancel. Opened PR and linked`,` `,(0,H.jsx)(`span`,{style:{color:`var(--pv-ink)`,fontWeight:600},children:`TEAM-142`}),`:`]}),(0,H.jsxs)(`div`,{style:{marginTop:4,padding:`4.5px 7px`,borderRadius:7,background:`var(--pv-card)`,border:`1px solid var(--pv-rule-strong)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:6,maxWidth:f?`86%`:`76%`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5,fontSize:8.5,fontWeight:600,minWidth:0},children:[(0,H.jsx)(Kp,{size:11,color:`var(--pv-green)`}),(0,H.jsx)(`span`,{style:{overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:`${j9} · fix(checkout): release PaySheet lock`})]}),(0,H.jsx)(`span`,{style:{fontSize:8,color:`var(--pv-green)`,fontWeight:700,flexShrink:0},children:`+14 −3`})]})]})]}):(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{display:`flex`,alignItems:`center`,gap:6,paddingLeft:27,paddingTop:4},children:[(0,H.jsx)(`span`,{className:`hz-pv-live-dot`}),(0,H.jsx)(`span`,{style:{fontSize:8.8,color:`var(--pv-mute)`},children:`Dev is inspecting checkout/pay-sheet.ts…`})]}),a>=2?(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{display:`flex`,gap:7,alignItems:`flex-start`},children:[(0,H.jsx)(`div`,{style:{width:20,height:20,borderRadius:999,background:`var(--pv-green)`,color:`var(--pv-bar)`,fontSize:9,fontWeight:800,display:`flex`,alignItems:`center`,justifyContent:`center`,flexShrink:0},children:`S`}),(0,H.jsxs)(`div`,{style:{flex:1,minWidth:0,display:`flex`,alignItems:`center`,gap:6,flexWrap:`wrap`},children:[(0,H.jsx)(`span`,{style:{fontSize:9.2,fontWeight:600},children:`Sci`}),(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:3,fontSize:8,fontWeight:700,padding:`2px 6px`,borderRadius:5,background:`var(--pv-green-bg)`,border:`1px solid var(--pv-green-edge)`,color:`var(--pv-green)`},children:[(0,H.jsx)(Vt,{size:9,color:`var(--pv-green)`}),`42/42 E2E GREEN`]}),(0,H.jsx)(`span`,{style:{fontSize:8.5,color:`var(--pv-mute)`},children:`WebKit iOS 18.2 verified`})]})]}):null]}),(0,H.jsxs)(`div`,{className:`hz-pv-composer`,style:{marginRight:f?92:118},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:6,minWidth:0},children:[(0,H.jsx)(hm,{size:11,color:`var(--pv-mute)`}),(0,H.jsx)(`span`,{style:{fontSize:8.8,color:a===3?`var(--pv-ink)`:`var(--pv-mute)`,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`},children:a===3?(0,H.jsxs)(H.Fragment,{children:[`@Opera deploy v2.4.1 to prod`,(0,H.jsx)(`span`,{className:`hz-pv-caret`})]}):`Message #${s}`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:6,flexShrink:0},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:3,fontSize:7.8,fontWeight:600,color:`var(--pv-warn)`},children:[(0,H.jsx)(sp,{size:9,color:`var(--pv-warn)`}),`Full access`]}),(0,H.jsx)(`span`,{className:`hz-pv-send`,children:(0,H.jsx)(gp,{size:11,color:`var(--pv-ink)`})})]})]})]}):null,r===1?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`hz-pv-pane-head`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:6},children:[(0,H.jsx)(Tm,{size:12,color:`var(--pv-blue)`}),(0,H.jsx)(`span`,{style:{fontSize:10.5,fontWeight:600},children:`Projects · Cycle 18`}),(0,H.jsx)(`span`,{style:{fontSize:8.5,color:`var(--pv-dim)`},children:`4 columns`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:5,paddingRight:f?78:96},children:[(0,H.jsx)(N9,{pct:C,color:`var(--pv-green)`}),(0,H.jsxs)(`span`,{style:{fontSize:8.5,fontWeight:700,color:`var(--pv-ink)`},children:[C,`%`]})]})]}),(0,H.jsxs)(`div`,{style:{flex:1,padding:`8px 9px`,paddingRight:f?92:118,display:`grid`,gridTemplateColumns:`repeat(4, minmax(0, 1fr))`,gap:6,overflow:`hidden`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{width:6,height:6,background:`var(--pv-amber)`}}),(0,H.jsx)(`span`,{style:{fontSize:8,fontWeight:700,color:`var(--pv-mute)`},children:`Backlog`})]}),(0,H.jsx)(P9,{code:`TEAM-151`,title:`Webhook retry jitter`,agent:`O`,hue:`var(--pv-violet)`,pct:25})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{width:6,height:6,background:`var(--pv-mute)`}}),(0,H.jsx)(`span`,{style:{fontSize:8,fontWeight:700,color:`var(--pv-mute)`},children:`To Do`})]}),(0,H.jsx)(P9,{code:`TEAM-148`,title:`Apple Pay telemetry`,agent:`M`,hue:`var(--pv-amber)`,pct:40})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{width:6,height:6,background:`var(--pv-blue)`}}),(0,H.jsx)(`span`,{style:{fontSize:8,fontWeight:700,color:`var(--pv-ink)`},children:`In Progress`})]}),(0,H.jsx)(P9,{code:`TEAM-145`,title:`Stripe 3DS fallback`,agent:`S`,hue:`var(--pv-green)`,pct:a>=1?82:64}),S?null:(0,H.jsx)(P9,{code:`TEAM-142`,title:`Release PaySheet lock`,agent:`D`,hue:`var(--pv-blue)`,pct:a===0?68:92,highlight:!0})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`span`,{className:`hz-pv-dot`,style:{width:6,height:6,background:`var(--pv-green)`}}),(0,H.jsx)(`span`,{style:{fontSize:8,fontWeight:700,color:`var(--pv-green)`},children:`Done`})]}),S?(0,H.jsx)(P9,{code:`TEAM-142`,title:`Release PaySheet lock`,agent:`D`,hue:`var(--pv-green)`,pct:100,done:!0,highlight:!0}):null,(0,H.jsx)(P9,{code:`TEAM-139`,title:`Unified SSO cookie`,agent:`C`,hue:`var(--pv-rose)`,pct:100,done:!0})]})]})]}):null,r===2?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`hz-pv-pane-head`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:6},children:[(0,H.jsx)(wm,{size:12,color:`var(--pv-amber)`}),(0,H.jsx)(`span`,{style:{fontSize:10.5,fontWeight:600},children:`Agents · Live Ops`}),(0,H.jsx)(`span`,{style:{fontSize:8.5,color:`var(--pv-dim)`},children:`6 teammates online`})]}),(0,H.jsx)(`span`,{style:{marginRight:f?78:96,fontSize:7.8,fontWeight:700,color:`var(--pv-green)`},children:`Sandboxes healthy`})]}),(0,H.jsx)(`div`,{style:{flex:1,padding:`8px 10px 6px`,paddingRight:f?92:118,display:`grid`,gridTemplateColumns:`repeat(3, minmax(0, 1fr))`,gap:6,alignContent:`start`},children:M9.map((e,t)=>{let n=t===a||a===3&&t===4;return(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{padding:`6px 7px`,borderRadius:8,background:n?`var(--pv-card-hi)`:`var(--pv-card)`,border:n?`1px solid var(--pv-blue)`:`1px solid var(--pv-rule-strong)`,display:`flex`,flexDirection:`column`,gap:3.5,transition:`border-color 0.2s ease, background-color 0.2s ease`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:4},children:[(0,H.jsx)(`span`,{style:{width:14,height:14,borderRadius:999,background:e.hue,color:`var(--pv-bar)`,fontSize:7.5,fontWeight:800,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},children:e.name[0]}),(0,H.jsx)(`span`,{style:{fontSize:8.8,fontWeight:700},children:e.name})]}),(0,H.jsx)(`span`,{className:`hz-pv-live-dot`})]}),(0,H.jsx)(`div`,{style:{fontSize:7.6,color:`var(--pv-mute)`,lineHeight:1.28,display:`-webkit-box`,WebkitLineClamp:2,WebkitBoxOrient:`vertical`,overflow:`hidden`},children:e.task}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginTop:`auto`,paddingTop:1},children:[(0,H.jsx)(`span`,{style:{fontSize:7,color:`var(--pv-dim)`},children:e.sandbox}),(0,H.jsx)(`span`,{style:{fontSize:7,fontWeight:700,color:e.hue},children:e.badge})]})]},e.name)})}),(0,H.jsxs)(`div`,{style:{margin:`0 10px 8px`,marginRight:f?92:118,padding:`4.5px 8px`,borderRadius:7,background:`var(--pv-bar)`,border:`1px solid var(--pv-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,fontSize:8,color:`var(--pv-mute)`},children:[(0,H.jsx)(`span`,{children:`Handoff: #engineering → @Dev → @Sci → @Opera`}),(0,H.jsx)(`span`,{style:{color:`var(--pv-green)`,fontWeight:700},children:`v2.4.1 live · 48s`})]})]}):null]})]}),(0,H.jsx)(lse,{x:x.x,y:x.y,label:x.label})]}),(0,H.jsx)(`div`,{className:`hz-pv-phone`,style:{width:_,height:v},children:(0,H.jsxs)(`div`,{className:`hz-pv-phone-screen`,children:[(0,H.jsxs)(`div`,{className:`hz-pv-phone-status`,children:[(0,H.jsx)(`span`,{children:`9:41`}),(0,H.jsx)(`div`,{className:`hz-pv-island`,children:(0,H.jsx)(`span`,{className:`hz-pv-island-lens`})}),(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:3},children:[(0,H.jsx)(Rm,{size:8.5,color:`var(--pv-ink)`}),(0,H.jsx)(`span`,{style:{width:12,height:6.5,borderRadius:2,border:`1px solid var(--pv-mute)`,padding:1,display:`inline-flex`},children:(0,H.jsx)(`span`,{style:{flex:1,background:`var(--pv-green)`,borderRadius:.5}})})]})]}),(0,H.jsxs)(`div`,{style:{height:25,padding:`0 9px`,borderBottom:`1px solid var(--pv-rule)`,background:`var(--pv-bar)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexShrink:0},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:4,fontSize:8.5,fontWeight:700},children:[(0,H.jsx)(`span`,{style:{width:13,height:13,borderRadius:4,background:`var(--pv-ink)`,color:`var(--pv-bar)`,fontSize:7.5,fontWeight:800,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},children:`H`}),(0,H.jsx)(`span`,{children:r===0?`#${s}`:r===1?`Projects`:`Live Ops`})]}),(0,H.jsx)(`span`,{className:`hz-pv-live-dot`})]}),(0,H.jsxs)(`div`,{style:{flex:1,minHeight:0,background:`var(--pv-canvas)`,padding:`7px 8px`,display:`flex`,flexDirection:`column`,gap:6,overflow:`hidden`},children:[r===0?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{style:{alignSelf:`flex-end`,padding:`5px 7px`,borderRadius:`9px 9px 3px 9px`,background:`var(--pv-bubble)`,color:`var(--pv-bubble-ink)`,fontSize:7.8,lineHeight:1.32,maxWidth:`92%`},children:`@Dev Safari Apple Pay closes early on checkout`}),a>=1?(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{padding:`5px 7px`,borderRadius:8,background:`var(--pv-card)`,border:`1px solid var(--pv-rule-strong)`,display:`flex`,flexDirection:`column`,gap:3},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.8,fontWeight:700,color:`var(--pv-blue)`},children:`◆ Dev`}),(0,H.jsx)(`span`,{style:{fontSize:7,color:`var(--pv-green)`,fontWeight:700},children:`+14 −3`})]}),(0,H.jsx)(`div`,{style:{fontSize:7.5,color:`var(--pv-ink)`},children:`${j9} · Release PaySheet lock`})]}):(0,H.jsx)(`div`,{style:{fontSize:7.5,color:`var(--pv-mute)`},children:`◆ Dev is fixing PaySheet…`}),a>=2?(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{padding:`4px 7px`,borderRadius:7,background:`var(--pv-green-bg)`,border:`1px solid var(--pv-green-edge)`,color:`var(--pv-green)`,fontSize:7.5,fontWeight:700,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{children:`◆ Sci · 42/42 E2E`}),(0,H.jsx)(`span`,{children:`GREEN`})]}):null]}):null,r===1?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.5,color:`var(--pv-mute)`,fontWeight:600},children:`Cycle 18 Sprint`}),(0,H.jsxs)(`span`,{style:{fontSize:7.8,color:`var(--pv-green)`,fontWeight:700},children:[C,`%`]})]}),(0,H.jsxs)(`div`,{style:{padding:`5.5px 7px`,borderRadius:8,background:`var(--pv-card-hi)`,border:S?`1px solid var(--pv-green)`:`1px solid var(--pv-blue)`,display:`flex`,flexDirection:`column`,gap:3},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.2,color:`var(--pv-dim)`,fontWeight:700},children:`TEAM-142`}),(0,H.jsx)(`span`,{style:{fontSize:6.8,fontWeight:700,color:S?`var(--pv-green)`:`var(--pv-blue)`},children:S?`✓ Done`:`In Progress`})]}),(0,H.jsx)(`div`,{style:{fontSize:7.8,fontWeight:600},children:`Release PaySheet lock`})]}),(0,H.jsxs)(`div`,{style:{padding:`5px 7px`,borderRadius:8,background:`var(--pv-card)`,border:`1px solid var(--pv-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.5},children:`TEAM-145 · 3DS`}),(0,H.jsx)(`span`,{style:{fontSize:7,color:`var(--pv-mute)`},children:`82%`})]}),(0,H.jsxs)(`div`,{style:{padding:`5px 7px`,borderRadius:8,background:`var(--pv-card)`,border:`1px solid var(--pv-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.5},children:`TEAM-139 · SSO`}),(0,H.jsx)(`span`,{style:{fontSize:7,color:`var(--pv-green)`,fontWeight:700},children:`Done`})]})]}):null,r===2?(0,H.jsx)(H.Fragment,{children:M9.slice(0,4).map(e=>(0,H.jsxs)(`div`,{style:{padding:`4.5px 6.5px`,borderRadius:7,background:`var(--pv-card)`,border:`1px solid var(--pv-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`,gap:4},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:4,minWidth:0},children:[(0,H.jsx)(`span`,{className:`hz-pv-live-dot`}),(0,H.jsx)(`span`,{style:{fontSize:7.8,fontWeight:700},children:e.name})]}),(0,H.jsx)(`span`,{style:{fontSize:6.8,fontWeight:700,color:e.hue},children:e.badge})]},e.name))}):null]}),(0,H.jsxs)(`div`,{style:{padding:`4px 7px 5px`,background:`var(--pv-canvas)`},children:[(0,H.jsxs)(`div`,{style:{height:22,padding:`0 4px 0 8px`,borderRadius:999,background:`var(--pv-composer)`,border:`1px solid var(--pv-composer-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.4,color:`var(--pv-mute)`},children:`Message team…`}),(0,H.jsx)(`span`,{style:{width:15,height:15,borderRadius:999,background:`var(--pv-send)`,color:`var(--pv-ink)`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},children:(0,H.jsx)(gp,{size:9,color:`var(--pv-ink)`})})]}),(0,H.jsx)(`div`,{style:{width:48,height:3,borderRadius:999,background:`var(--pv-rule-strong)`,margin:`5px auto 0`}})]})]})})]})}),(0,H.jsx)(`div`,{className:`hz-pv-scene-pills`,role:`tablist`,"aria-label":`Preview scenes`,children:cse.map(e=>{let t=r===e.id;return(0,H.jsxs)(`button`,{type:`button`,role:`tab`,"aria-selected":t,className:`hz-pv-scene-pill`,"data-active":t?`true`:`false`,onClick:()=>d(e.id),children:[t?(0,H.jsx)(`span`,{className:`hz-pv-live-dot`}):(0,H.jsx)(xm,{size:11,color:`var(--muted-foreground)`}),(0,H.jsx)(`span`,{children:f?e.label:e.short})]},e.id)})})]})};function P9({code:e,title:t,agent:n,hue:r,pct:i,done:a=!1,highlight:o=!1}){return(0,H.jsxs)(`div`,{className:`hz-pv-rise`,style:{padding:`6px 6.5px`,borderRadius:7,background:o?`var(--pv-card-hi)`:`var(--pv-card)`,border:o?a?`1px solid var(--pv-green)`:`1px solid var(--pv-blue)`:`1px solid var(--pv-rule-strong)`,display:`flex`,flexDirection:`column`,gap:4},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{fontSize:7.2,fontWeight:700,color:`var(--pv-dim)`},children:e}),(0,H.jsx)(N9,{pct:i,color:a?`var(--pv-green)`:r})]}),(0,H.jsx)(`div`,{style:{fontSize:8,fontWeight:600,lineHeight:1.25,color:`var(--pv-ink)`},children:t}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{style:{width:13,height:13,borderRadius:999,background:r,color:`var(--pv-bar)`,fontSize:7,fontWeight:800,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},children:n}),(0,H.jsx)(`span`,{style:{fontSize:7,fontWeight:700,color:a?`var(--pv-green)`:`var(--pv-mute)`},children:a?`Merged`:`${i}%`})]})]})}var dse=[[`Channels`,`Your people and your agents, in one conversation.`],[`Agents`,`Hand an agent the work; it reports back when it is done.`],[`Issue boards`,`Every task from backlog to done, on one board.`]],fse=()=>(0,H.jsx)(y,{width:`100%`,maxW:740,gap:kH.wide,flexWrap:`wrap`,children:dse.map(([e,t])=>(0,H.jsxs)(z,{flex:1,minW:180,gap:4,children:[(0,H.jsx)(a,{size:Z.body,color:X.ink,fontWeight:`600`,children:e}),(0,H.jsx)(a,{size:Z.small,color:X.mute,children:t})]},e))}),F9=`PR #418`,I9=`PR #421`,pse=`#E5E7EB`,mse=`#EC4899`,L9=`#1A1A1A`,R9=`#F472B6`,z9=`Read https://hanzo.ai/skill.md and use Hanzo Team in my project.`,hse={vi:`V`,opera:`O`,mana:`M`,dev:`D`,des:`D`,doc:`D`,su:`S`,sal:`S`,sci:`S`,cyber:`C`,mark:`M`,fin:`F`,law:`L`,data:`D`,rev:`R`};function B9({id:e,size:t=26}){let n={width:t,height:t,"--img":`url(https://hanzo.ai/agents/${e}.png)`};return(0,H.jsx)(`span`,{className:`hz-ts-face`,style:n,"aria-hidden":`true`,children:hse[e]??e.slice(0,1).toUpperCase()})}function V9({pct:e,size:t=13}){let n=t/2-1.5,r=2*Math.PI*n,i=Math.max(0,Math.min(100,e));return(0,H.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 ${t} ${t}`,"aria-hidden":`true`,style:{flexShrink:0},children:[(0,H.jsx)(`circle`,{cx:t/2,cy:t/2,r:n,fill:`none`,stroke:`var(--ts-rule-strong)`,strokeWidth:`1.6`}),(0,H.jsx)(`circle`,{cx:t/2,cy:t/2,r:n,fill:`none`,stroke:`var(--ts-green)`,strokeWidth:`1.6`,strokeDasharray:r,strokeDashoffset:r*(1-i/100),transform:`rotate(-90 ${t/2} ${t/2})`,style:{transition:`stroke-dashoffset 0.45s ease`}})]})}var H9=[{head:`BACKLOG – 7`,tone:`var(--ts-amber)`,cards:[{id:`CRM-1`,tag:`Devops`,title:`Set up cluster monitoring & telemetry`,pct:12,owner:`opera`,col:0},{id:`CRM-2`,tag:`Research`,title:`Analyze and cluster search queries`,pct:35,owner:`sci`,col:0}]},{head:`TO DO – 6`,tone:`var(--ts-mute)`,cards:[{id:`CRM-8`,tag:`Sales`,title:`Sales planning & enterprise deal desk`,pct:20,owner:`rev`,col:1},{id:`CRM-11`,tag:`Backend`,title:`Deduplicate contacts on CRM import`,pct:40,owner:`dev`,col:1}]},{head:`IN PROGRESS – 3`,tone:`var(--ts-blue)`,cards:[{id:`CRM-15`,tag:`QA`,title:`Conduct custdev interview w/ client`,pct:90,owner:`sal`,col:2},{id:`CRM-16`,tag:`Feature`,title:`Add view-resource for MVP Deal Screen`,pct:65,owner:`des`,col:2}]},{head:`DONE – 3`,tone:`var(--ts-green)`,cards:[{id:`CRM-17`,tag:`Backend`,title:`Ship seat-count billing reconciliation`,pct:100,owner:`rev`,col:3},{id:`CRM-19`,tag:`Feature`,title:`Cut first release of the deal screen`,pct:100,owner:`dev`,col:3}]}],U9=H9.flatMap(e=>e.cards),W9=[{num:`01`,title:`Channels for every part of the work`,body:`A channel for each team and project, direct messages, and threads that keep a decision next to the question that started it.`},{num:`02`,title:`Agents are teammates`,body:`Mention an agent and hand it the work. It answers in the channel with the work done: a pull request, a drafted reply, an updated deck.`},{num:`03`,title:`Every organization you belong to`,body:`Switch between your company, a side project and your friends from one rail, each with its own channels, people and agents.`}],G9=[[`dev`,`Dev`,`Repos, PRs, CI`],[`sci`,`Sci`,`E2E specs, WebKit`],[`cyber`,`Cyber`,`Security, audits`],[`des`,`Des`,`UI, tokens, specs`],[`mark`,`Mark`,`Launch, growth`],[`su`,`Su`,`Triage, replies`],[`opera`,`Opera`,`Deploys, infra`]],K9=[{title:`Coding`,body:`A bug report becomes a pull request; a person reviews it, the checks pass, and it ships, all in the channel.`,pair:[`vi`,`dev`]},{title:`Support`,body:`An agent drafts the reply, a person makes it warmer, and it goes out.`,pair:[`su`,`vi`]},{title:`Email`,body:`The inbox is sorted and the replies are drafted in your voice. You approve them as a batch.`,pair:[`su`,`vi`]},{title:`Fundraising`,body:`The deck and the model are built, the intros are drafted, and the meeting lands on the calendar.`,pair:[`fin`,`vi`]},{title:`Docs & Specs`,body:`Shared specifications stay linked to issues, pull requests, and channel decisions without drifting out of date.`,pair:[`doc`,`dev`]},{title:`Science & R&D Ops`,body:`Run LillyMol MedChem screens, targets + crew Slurm DAGs, pytest-wdl proteomics, and admiral/brms.mmrm clinical tables right from #research.`,pair:[`vi`,`sci`]}],q9=[{channel:`bugfix`,category:`Engineering & QA`,no:`01`,title:`E2E Bug Reproduction, Patch & Verification`,summary:`A human drops a one-line bug report in #bugfix. @Dev reproduces it, patches the component, and opens a pull request while @Sci verifies the fix end-to-end across browsers.`,faces:[`dev`,`sci`],humanInitials:`ZM`,humanName:`Zoe Maxwell`,humanTime:`10:14 AM`,humanAsk:`Checkout button is unresponsive on mobile Safari when Apple Pay sheet closes — @Dev can we patch this before noon?`,leadAgent:`dev`,leadName:`Dev`,leadReply:`Reproduced in WebKit simulator: oncancel left the sheet lock active in PaySheet.tsx:84. Cleared lock in finally block and opened ${F9}.`,artifact:`${F9} · fix(checkout): release PaySheet lock on cancel (+14 -3)`,verifyAgent:`sci`,verifyName:`Sci`,badge:`42/42 E2E GREEN`,verifyLine:`Verified e2e across iOS 18 Safari & Chromium — 42/42 checkout specs green. Ready to merge.`,steps:[`Reproduce Safari sheet lock in headless WebKit`,`Trace state lock to components/checkout/PaySheet.tsx:84`,`Patch finally handler & push branch fix/apple-pay-lock`,`Run 42 Playwright e2e checkout specs across iOS & desktop`],tools:[`GitHub`,`Playwright`,`Safari WebKit`,`CI Runner`]},{channel:`security`,category:`Security & SecOps`,no:`02`,title:`Continuous Zero-Trust Audit & Secret Rotation`,summary:`Every new endpoint or auth change is audited in #security. @Cyber inspects token scopes, hardens audience checks, and coordinates zero-downtime key rotation with @Dev.`,faces:[`cyber`,`dev`],humanInitials:`AR`,humanName:`Alex Rivera`,humanTime:`11:02 AM`,humanAsk:`New OAuth callback & WIMSE token exchange landed on staging — @Cyber can you run a full audit before we cut the release?`,leadAgent:`cyber`,leadName:`Cyber`,leadReply:`Audited 14 endpoints & SBOM: 0 critical CVEs. Tightened JWT audience validation on /v1/oauth/token and opened ${I9}.`,artifact:`${I9} · sec(oauth): enforce strict WIMSE audience & nonce (+28 -6)`,verifyAgent:`dev`,verifyName:`Dev`,badge:`0 CRITICAL CVEs`,verifyLine:`Merged ${I9} and rotated staging signing keys in KMS with zero dropped sessions.`,steps:[`Scan 14 OAuth & WIMSE endpoints for token scope drift`,`Verify dependency SBOM against CVE advisories`,`Enforce strict aud + nonce claim validation in ${I9}`,`Rotate KMS signing keys and verify zero session drops`],tools:[`Hanzo KMS`,`WIMSE IAM`,`Trivy SBOM`,`GitHub`]},{channel:`launch`,category:`Marketing & Design`,no:`03`,title:`Coordinated Product Launch & Creative Assets`,summary:`From a single brief in #launch, @Mark drafts the announcement post, changelog, and social thread while @Des renders responsive OpenGraph cards and video cuts.`,faces:[`mark`,`des`],humanInitials:`AW`,humanName:`Antje Worring`,humanTime:`9:20 AM`,humanAsk:`We ship Team v2 at noon PT — @Mark @Des prepare the launch post, changelog, and social cards.`,leadAgent:`mark`,leadName:`Mark`,leadReply:`Drafted launch post, customer email segment, and 6-part X/LinkedIn thread synced with live release notes.`,artifact:`Canvas · Team v2 Launch Kit + 28-channel Post queue`,verifyAgent:`des`,verifyName:`Des`,badge:`LAUNCH READY`,verifyLine:`Rendered 1080p hero loop + dark-mode OG cards across hanzo.ai/team and hanzo.team.`,steps:[`Synthesize merged PR changelog into product narrative`,`Render 16:9 + 9:16 launch cards on canonical brand tokens`,`Stage scheduled posts in Hanzo Post queue`,`Verify UTM attribution and OG previews`],tools:[`Hanzo Post`,`Canvas`,`Hanzo Insights`,`CDN`]},{channel:`support`,category:`Customer Support`,no:`04`,title:`Instant Ticket Triage, Reproduction & Warm Reply`,summary:`@Su correlates inbound customer threads with telemetry traces, reproduces config issues, and drafts an accurate reply linked to docs.`,faces:[`su`,`doc`],humanInitials:`HB`,humanName:`Harry Boone`,humanTime:`1:08 PM`,humanAsk:`@Su Enterprise tenant acme-corp is seeing 403 on custom MCP webhook — can we diagnose and draft the reply?`,leadAgent:`su`,leadName:`Su`,leadReply:`Traced request req_98a2f: webhook secret header used legacy prefix. Drafted step-by-step reply for Acme eng.`,artifact:`Ticket SUP-884 · Root cause + verified cURL snippet attached`,verifyAgent:`doc`,verifyName:`Doc`,badge:`SLA 3 MIN`,verifyLine:`Updated MCP webhook header guide in docs.hanzo.ai so future setups copy the v2 header.`,steps:[`Correlate tenant org slug with gateway request logs`,`Pinpoint header mismatch without exposing tenant secrets`,`Draft warm customer reply with copy-paste fix`,`Patch docs quickstart example`],tools:[`Hanzo O11y`,`Zendesk / Slack`,`Docs MCP`,`Gateway`]},{channel:`ops`,category:`Infra & SRE`,no:`05`,title:`Zero-Downtime Canary Rollouts & Latency Guard`,summary:`@Opera advances multi-region Kubernetes rollouts while watching p95 latency, error budgets, and KMS health checks.`,faces:[`opera`,`cyber`],humanInitials:`ZK`,humanName:`Zach Kelling`,humanTime:`2:40 PM`,humanAsk:`@Opera roll team-gateway v0.1.17 across us-west and eu-central with 10% canary hold.`,leadAgent:`opera`,leadName:`Opera`,leadReply:`Canary held 5m at 10% traffic: 17.8ms p95, 0.00% 5xx. Promoted 100% across all regions.`,artifact:`deploy/team-gateway · sha256:9f4c…81e2 · 6/6 pods healthy`,verifyAgent:`cyber`,verifyName:`Cyber`,badge:`17.8ms P95`,verifyLine:`Verified mTLS mesh certificates and egress policy across all 6 replicas.`,steps:[`Verify container signature & image digest`,`Shift 10% canary traffic and sample 10k spans`,`Promote rollout across us-west & eu-central`,`Confirm mTLS & health probes green`],tools:[`Kubernetes`,`Prometheus`,`Hanzo O11y`,`Hanzo KMS`]},{channel:`research`,category:`Science & BioOps`,no:`06`,title:`Reproducible Compute DAGs, Benchmarks & Tables`,summary:`@Sci runs distributed evaluation suites, MedChem screens, and statistical tables directly from #research with pinned artifacts.`,faces:[`sci`,`data`],humanInitials:`ZM`,humanName:`Zoe Maxwell`,humanTime:`3:15 PM`,humanAsk:`@Sci run the Zen-4 tool-use eval matrix against the new router checkpoint and post throughput + pass@1.`,leadAgent:`sci`,leadName:`Sci`,leadReply:`Completed 1,200-task tool-use benchmark on 8xH200 cluster: +3.4% pass@1 at 148 tok/s.`,artifact:`eval/zen4-router-r18.parquet · 1,200 trajectories archived`,verifyAgent:`data`,verifyName:`Data`,badge:`REPRODUCIBLE`,verifyLine:`Published interactive comparison table to Datastore and pinned seed manifest.`,steps:[`Provision ephemeral GPU batch on Hanzo Machines`,`Execute deterministic eval harness with pinned seeds`,`Aggregate latency, token cost & pass@1 deltas`,`Archive artifacts to S3 & Datastore`],tools:[`Hanzo Machines`,`Datastore`,`S3 Storage`,`Zen Eval`]},{channel:`deals`,category:`Sales & RevOps`,no:`07`,title:`Inbound Enrichment, Deal Desk & Custom Terms`,summary:`@Sal enriches enterprise leads, prepares tailored architecture decks, and syncs stage updates into Hanzo CRM.`,faces:[`sal`,`des`],humanInitials:`AW`,humanName:`Antje Worring`,humanTime:`4:05 PM`,humanAsk:`@Sal prep the sovereign cloud proposal and security questionnaire for Meridian Health before tomorrow’s call.`,leadAgent:`sal`,leadName:`Sal`,leadReply:`Completed 94-item HIPAA/SOC2 security matrix, sized 64-GPU reserved tier, and updated CRM deal stage.`,artifact:`CRM Deal · Meridian Health ($240k ARR) · Proposal v1`,verifyAgent:`des`,verifyName:`Des`,badge:`CRM SYNCED`,verifyLine:`Formatted custom architecture deck with Meridian VPC topology diagram.`,steps:[`Enrich account footprint & compliance requirements`,`Auto-complete security questionnaire from Trust KB`,`Model reserved compute pricing & margins`,`Sync proposal + calendar invite to Hanzo CRM`],tools:[`Hanzo CRM`,`Data Room`,`Hanzo Sign`,`Calendar`]},{channel:`finance`,category:`Finance & Billing`,no:`08`,title:`Multi-Cloud Cost Reconciliation & Ledger Close`,summary:`@Fin reconciles Stripe settlements, usage-metered API credits, and cloud GPU invoices with zero spreadsheet drift.`,faces:[`fin`,`data`],humanInitials:`ZK`,humanName:`Zach Kelling`,humanTime:`4:45 PM`,humanAsk:`@Fin reconcile October metered token usage against Stripe payouts and flag any margin anomalies.`,leadAgent:`fin`,leadName:`Fin`,leadReply:`Reconciled 48,912 usage invoices against Stripe & Commerce ledger: $0.00 variance, gross margin +2.1% MoM.`,artifact:`Ledger Close · 2026-10 · 100% matched`,verifyAgent:`data`,verifyName:`Data`,badge:`$0 DRIFT`,verifyLine:`Verified ClickHouse usage rollups match billing snapshots across all orgs.`,steps:[`Ingest Stripe payouts & Hanzo Billing credit ledgers`,`Cross-check per-org token & compute metering`,`Flag outlier unit-cost SKUs`,`Lock monthly close report in Drive`],tools:[`Hanzo Billing`,`Stripe`,`QuickBooks`,`Datastore`]},{channel:`legal`,category:`Legal & Compliance`,no:`09`,title:`DPA Redlines, OSS License Gate & E-Sign`,summary:`@Law reviews vendor DPAs against standard playbook fallback clauses and routes clean agreements to Hanzo Sign.`,faces:[`law`,`cyber`],humanInitials:`AR`,humanName:`Alex Rivera`,humanTime:`5:12 PM`,humanAsk:`@Law check redlines on the enterprise MSA + DPA from Northstar Bank against our standard liability cap.`,leadAgent:`law`,leadName:`Law`,leadReply:`Reviewed 19 clauses: 17 standard, 2 redlines on subprocessor notice window. Applied approved 30-day fallback.`,artifact:`Northstar_MSA_DPA_clean.pdf · Ready for Hanzo Sign`,verifyAgent:`cyber`,verifyName:`Cyber`,badge:`PLAYBOOK PASS`,verifyLine:`Confirmed subprocessor list and data-residency annex match EU-Central deployment.`,steps:[`Parse incoming DOCX redlines against clause playbook`,`Verify GDPR / SOC2 data-residency commitments`,`Generate clean comparison + redline summary`,`Stage envelope in Hanzo Sign`],tools:[`Hanzo Sign`,`Data Room`,`Trust KB`,`Drive`]},{channel:`growth`,category:`Growth & Analytics`,no:`10`,title:`Funnel Diagnostics, Cohort Retention & Experiments`,summary:`@Mark and @Sci monitor signup-to-activation funnels in Hanzo Insights and ship copy/UX improvements in hours.`,faces:[`mark`,`sci`],humanInitials:`HB`,humanName:`Harry Boone`,humanTime:`5:50 PM`,humanAsk:`@Mark check 7-day activation on team invite links after yesterday’s onboarding update.`,leadAgent:`mark`,leadName:`Mark`,leadReply:`Workspace invite completion jumped from 64.2% → 81.9% (+17.7pp) after removing the manual setup gate.`,artifact:`Insights Funnel · 7d Invite Activation (+17.7pp)`,verifyAgent:`sci`,verifyName:`Sci`,badge:`P < 0.001`,verifyLine:`Confirmed statistical significance across 4,180 sessions on desktop and mobile Safari.`,steps:[`Query 7-day cohort funnel in Hanzo Insights`,`Segment conversion by browser & auth provider`,`Run two-proportion significance check`,`Post weekly growth digest to #growth`],tools:[`Hanzo Insights`,`Datastore`,`GitHub`,`Hanzo Post`]}],gse=[`1. Code trace`,`2. Loop in design`,`3. Decision`,`4. Canvas summary`,`5. E2E verify`,`6. Session complete`],_se=[[`12`,`12`,``,`.cta-button {`],[`13`,`13`,``,` display: inline-flex;`],[`14`,`14`,``,` align-items: center;`],[`15`,``,`del`,`- color: ${pse.toLowerCase()};`],[`16`,``,`del`,`- background: ${mse.toLowerCase()};`],[``,`15`,`add`,`+ color: ${L9.toLowerCase()};`],[``,`16`,`add`,`+ background: ${R9.toLowerCase()};`],[``,`17`,`add`,`+ font-weight: 600;`],[`17`,`18`,``,` border-radius: 8px;`],[`18`,`19`,``,`}`]];function vse({onOpen:e,working:t}){let[n,r]=(0,V.useState)(4),[i,o]=(0,V.useState)(!0),[s,c]=(0,V.useState)(0),[l,u]=(0,V.useState)(0),[d,f]=(0,V.useState)(0),[p,m]=(0,V.useState)(!1),[h,g]=(0,V.useState)(6),[_,v]=(0,V.useState)(`Code`),[b,x]=(0,V.useState)(!1);(0,V.useEffect)(()=>{if(!i)return;let e=window.setInterval(()=>{r(e=>(e+1)%U9.length)},2200);return()=>window.clearInterval(e)},[i]),(0,V.useEffect)(()=>{if(p)return;let e=window.setInterval(()=>{f(e=>(e+1)%q9.length)},3400);return()=>window.clearInterval(e)},[p]);let S=U9[n]??U9[0],C=q9[d]??q9[0],w=K9[l]??K9[0];return(0,H.jsxs)(`div`,{className:`hz-ts-wrap`,children:[(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Live Tracker Board and Mobile Sync`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`Web + Mobile Synced`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`The playground for humans + AI`}),(0,H.jsx)(`p`,{className:`hz-ts-sub`,children:`Your people and your AI agents plan, build, and ship together — click any card to watch its specialist teammate pick it up and sync live to mobile.`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-board-win`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-win-bar`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:10},children:[(0,H.jsx)(`strong`,{style:{fontWeight:600},children:`hanzo.team`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-dim)`},children:`·`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-ink)`,fontWeight:500},children:`Tracker Board`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`},children:`23 AI Teammates`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`},children:`Virtual Office`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:12},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:6,fontSize:12,color:`var(--ts-mute)`},children:[(0,H.jsx)(V9,{pct:83,size:14}),`83% Sprint complete`]}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>o(e=>!e),"aria-label":i?`Pause board`:`Replay board`,style:{appearance:`none`,border:`1px solid var(--ts-rule-strong)`,background:`var(--ts-card)`,color:`var(--ts-ink)`,borderRadius:6,width:26,height:26,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,cursor:`pointer`},children:i?(0,H.jsx)(mm,{size:12}):(0,H.jsx)(_m,{size:12})})]})]}),(0,H.jsxs)(`div`,{className:`hz-ts-board-body`,children:[(0,H.jsx)(`div`,{className:`hz-ts-cols`,children:H9.map(e=>(0,H.jsxs)(`div`,{className:`hz-ts-col`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-col-h`,children:[(0,H.jsx)(`span`,{style:{width:7,height:7,borderRadius:999,background:e.tone}}),(0,H.jsx)(`span`,{children:e.head})]}),e.cards.map(e=>{let t=U9.findIndex(t=>t.id===e.id),i=t===n;return(0,H.jsxs)(`button`,{type:`button`,className:`hz-ts-card`,"data-active":i?`true`:`false`,onClick:()=>{o(!1),r(t)},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,fontSize:11,color:`var(--ts-mute)`},children:[(0,H.jsx)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`},children:e.id}),(0,H.jsx)(`span`,{style:{padding:`1px 6px`,borderRadius:999,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`},children:e.tag})]}),(0,H.jsx)(`div`,{style:{fontSize:13,fontWeight:500,lineHeight:1.38},children:e.title}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,fontSize:11.5,color:`var(--ts-mute)`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5},children:[(0,H.jsx)(V9,{pct:e.pct}),e.pct,`%`]}),(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5,color:i?`var(--ts-ink)`:`var(--ts-mute)`,fontWeight:600},children:[(0,H.jsx)(B9,{id:e.owner,size:18}),`@`,e.owner]})]})]},e.id)})]},e.head))}),(0,H.jsx)(`div`,{className:`hz-ts-phone`,"aria-label":`Synced iPhone workspace`,children:(0,H.jsxs)(`div`,{className:`hz-ts-phone-in`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:8},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,fontSize:11},children:[(0,H.jsx)(`strong`,{children:`9:41`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-green)`,fontSize:10.5,fontWeight:600},children:`● Synced`})]}),(0,H.jsxs)(`div`,{style:{padding:10,borderRadius:10,background:`var(--ts-card)`,border:`1px solid var(--ts-rule)`,display:`flex`,flexDirection:`column`,gap:6},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,fontSize:10.5,color:`var(--ts-mute)`},children:[(0,H.jsx)(`span`,{children:S.id}),(0,H.jsx)(`span`,{children:S.tag})]}),(0,H.jsx)(`div`,{style:{fontSize:12,fontWeight:600,lineHeight:1.35},children:S.title}),(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,fontSize:11,color:`var(--ts-mute)`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5},children:[(0,H.jsx)(V9,{pct:S.pct,size:12}),S.pct,`%`]}),(0,H.jsxs)(`span`,{children:[`@`,S.owner]})]})]}),(0,H.jsxs)(`div`,{style:{padding:9,borderRadius:10,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`,display:`flex`,gap:8,alignItems:`center`},children:[(0,H.jsx)(B9,{id:`mark`,size:24}),(0,H.jsxs)(`div`,{style:{minWidth:0},children:[(0,H.jsx)(`div`,{style:{fontSize:11,fontWeight:600},children:`#hanzo-mark · Mark`}),(0,H.jsx)(`div`,{style:{fontSize:10.5,color:`var(--ts-mute)`},children:`28-day GA4 checkout funnel synced`})]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,paddingTop:6,borderTop:`1px solid var(--ts-rule)`,fontSize:10.5,color:`var(--ts-mute)`},children:[(0,H.jsx)(`div`,{style:{display:`flex`,gap:4},children:[`dev`,`cyber`,`mark`,`sci`].map(e=>(0,H.jsx)(B9,{id:e,size:18},e))}),(0,H.jsx)(`span`,{children:`Web + iOS`})]})]})})]})]})]}),(0,H.jsx)(`div`,{className:`hz-ts-drift`,"aria-hidden":`true`,children:(0,H.jsx)(`div`,{className:`hz-ts-drift-track`,children:[0,1].flatMap(e=>q9.map(t=>(0,H.jsxs)(`span`,{children:[`# `,t.channel]},`${e}-${t.channel}`)))})}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`What it is`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`What it is`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`One workspace. Everything connected.`}),(0,H.jsx)(`p`,{className:`hz-ts-sub`,children:`Stop jumping between tools just to get work done.`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-split`,children:[(0,H.jsx)(`div`,{role:`tablist`,"aria-label":`Workspace chapters`,style:{display:`flex`,flexDirection:`column`,gap:10},children:W9.map((e,t)=>(0,H.jsxs)(`button`,{type:`button`,role:`tab`,"aria-selected":s===t,className:`hz-ts-tab-btn`,onClick:()=>c(t),children:[(0,H.jsx)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`,fontSize:11,color:`var(--ts-dim)`},children:e.num}),(0,H.jsx)(`span`,{style:{fontSize:15.5,fontWeight:600,color:s===t?`var(--ts-ink)`:`var(--foreground)`},children:e.title}),(0,H.jsx)(`span`,{style:{fontSize:13.5,lineHeight:1.5,color:`var(--ts-mute)`},children:e.body})]},e.num))}),(0,H.jsxs)(`div`,{className:`hz-ts-stage-card`,children:[s===0?(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:12},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,paddingBottom:10,borderBottom:`1px solid var(--ts-rule)`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:6,fontWeight:600},children:[(0,H.jsx)(Yp,{size:15}),` bugfix`]}),(0,H.jsx)(`span`,{style:{fontSize:11.5,color:`var(--ts-green)`,fontWeight:600},children:`42/42 E2E GREEN`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:10,alignItems:`flex-start`},children:[(0,H.jsx)(`span`,{className:`hz-ts-face`,style:{width:28,height:28},children:`ZM`}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:12.5,fontWeight:600},children:`Zoe Maxwell · 10:14 AM`}),(0,H.jsx)(`div`,{style:{fontSize:13.5,color:`var(--ts-mute)`,marginTop:2},children:`Checkout button is unresponsive on mobile Safari when Apple Pay sheet closes.`})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:10,alignItems:`flex-start`,paddingLeft:18,borderLeft:`2px solid var(--ts-rule-strong)`},children:[(0,H.jsx)(B9,{id:`dev`,size:28}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:12.5,fontWeight:600},children:`Dev · Agent`}),(0,H.jsx)(`div`,{style:{fontSize:13.5,color:`var(--ts-mute)`,marginTop:2},children:`Cleared lock in finally block and opened ${F9}.`})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:10,alignItems:`flex-start`,paddingLeft:18,borderLeft:`2px solid var(--ts-rule-strong)`},children:[(0,H.jsx)(B9,{id:`sci`,size:28}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:12.5,fontWeight:600},children:`Sci · Agent`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-green)`,fontWeight:600,marginTop:2},children:`Verified across iOS 18 Safari & Chromium — 42/42 checkout specs green.`})]})]})]}):s===1?(0,H.jsx)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(180px, 1fr))`,gap:10},children:G9.map(([e,t,n])=>(0,H.jsxs)(`div`,{style:{padding:12,borderRadius:10,background:`var(--ts-card)`,border:`1px solid var(--ts-rule)`,display:`flex`,alignItems:`center`,gap:10},children:[(0,H.jsx)(B9,{id:e,size:36}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:13.5,fontWeight:600},children:t}),(0,H.jsx)(`div`,{style:{fontSize:11.5,color:`var(--ts-mute)`},children:n})]})]},e))}):(0,H.jsxs)(`div`,{style:{display:`flex`,gap:14,alignItems:`stretch`},children:[(0,H.jsxs)(`div`,{style:{width:46,borderRadius:10,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`,padding:`10px 0`,display:`flex`,flexDirection:`column`,alignItems:`center`,gap:8},children:[(0,H.jsx)(`span`,{style:{width:30,height:30,borderRadius:8,background:`var(--ts-ink)`,color:`var(--ts-bg)`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,fontWeight:800,fontSize:12},children:`HA`}),(0,H.jsx)(`span`,{style:{width:30,height:30,borderRadius:8,background:`var(--ts-card-hi)`,color:`var(--ts-ink)`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,fontWeight:700,fontSize:12},children:`LN`}),(0,H.jsx)(`span`,{style:{width:30,height:30,borderRadius:8,background:`var(--ts-card)`,color:`var(--ts-mute)`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,fontWeight:700,fontSize:12},children:`ZL`}),(0,H.jsx)(`span`,{style:{width:30,height:30,borderRadius:8,border:`1px dashed var(--ts-rule-strong)`,color:`var(--ts-mute)`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`,fontSize:14},children:`+`})]}),(0,H.jsxs)(`div`,{style:{flex:1,display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(200px, 1fr))`,gap:12},children:[(0,H.jsxs)(`div`,{style:{padding:14,borderRadius:10,background:`var(--ts-card)`,border:`1px solid var(--ts-ink)`},children:[(0,H.jsx)(`div`,{style:{fontSize:13.5,fontWeight:600},children:`Hanzo AI · hanzo.ai`}),(0,H.jsxs)(`div`,{style:{fontSize:12,color:`var(--ts-mute)`,marginTop:8,display:`flex`,flexDirection:`column`,gap:4},children:[(0,H.jsx)(`span`,{children:`# bugfix`}),(0,H.jsx)(`span`,{children:`# launch`}),(0,H.jsx)(`span`,{children:`# ops`})]})]}),(0,H.jsxs)(`div`,{style:{padding:14,borderRadius:10,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`},children:[(0,H.jsx)(`div`,{style:{fontSize:13.5,fontWeight:600},children:`Lux Network · lux.network`}),(0,H.jsxs)(`div`,{style:{fontSize:12,color:`var(--ts-mute)`,marginTop:8,display:`flex`,flexDirection:`column`,gap:4},children:[(0,H.jsx)(`span`,{children:`# consensus`}),(0,H.jsx)(`span`,{children:`# validator-ops`}),(0,H.jsx)(`span`,{children:`# bridge-audit`})]})]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,paddingTop:10,borderTop:`1px solid var(--ts-rule)`,fontSize:12,color:`var(--ts-dim)`},children:[(0,H.jsxs)(`span`,{children:[`Chapter `,W9[s].num,` / 03`]}),(0,H.jsx)(`span`,{children:`Slack-style org rail · Threads · Native AI teammates`})]})]})]})]}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Humans and agents on the same work`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`Together`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`Humans and agents, on the same work`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-split`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-stage-card`,style:{justifyContent:`center`,alignItems:`flex-start`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:14},children:[(0,H.jsx)(B9,{id:w.pair[0],size:52}),(0,H.jsx)(`span`,{style:{width:36,height:2,background:`var(--ts-ink)`,display:`inline-block`}}),(0,H.jsx)(B9,{id:w.pair[1],size:52})]}),(0,H.jsxs)(`div`,{style:{fontFamily:`var(--font-mono, monospace)`,fontSize:12,color:`var(--ts-dim)`},children:[`HANDOFF `,String(l+1).padStart(2,`0`),` / 06`]}),(0,H.jsx)(`div`,{style:{fontSize:22,fontWeight:600},children:w.title}),(0,H.jsx)(`p`,{style:{margin:0,fontSize:14.5,lineHeight:1.55,color:`var(--ts-mute)`},children:w.body})]}),(0,H.jsx)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(240px, 1fr))`,gap:10},children:K9.map((e,t)=>(0,H.jsxs)(`button`,{type:`button`,className:`hz-ts-tab-btn`,"aria-selected":l===t,onMouseEnter:()=>u(t),onClick:()=>u(t),children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:8},children:[(0,H.jsx)(B9,{id:e.pair[0],size:24}),(0,H.jsx)(`span`,{style:{color:`var(--ts-dim)`,fontSize:11},children:`→`}),(0,H.jsx)(B9,{id:e.pair[1],size:24}),(0,H.jsx)(`span`,{style:{fontSize:14.5,fontWeight:600,color:`var(--foreground)`},children:e.title})]}),(0,H.jsx)(`span`,{style:{fontSize:12.5,lineHeight:1.48,color:`var(--ts-mute)`},children:e.body})]},e.title))})]})]}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Everything the team works in`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`The rooms`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`Everything the team works in`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-bento`,children:[(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsx)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(3, 1fr)`,gap:6,fontSize:10.5},children:[`Backlog`,`Doing`,`Done`].map((e,t)=>(0,H.jsxs)(`div`,{style:{padding:7,borderRadius:7,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`},children:[(0,H.jsx)(`div`,{style:{color:`var(--ts-dim)`,marginBottom:5},children:e}),(0,H.jsx)(`div`,{style:{padding:`5px 6px`,borderRadius:5,background:t===2?`var(--ts-green-bg)`:`var(--ts-card)`,border:`1px solid var(--ts-rule)`,fontWeight:500},children:t===0?`Email`:t===1?`R&D Ops`:`Specs ✓`})]},e))}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Board`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`Cards in Backlog, Doing and Done, each with its owner, person or agent.`})]})]}),(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5,padding:10,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`,fontSize:11.5,fontFamily:`var(--font-mono, monospace)`},children:[(0,H.jsx)(`span`,{style:{color:`var(--ts-ink)`,fontWeight:600},children:`▾ Docs & Specs/`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`,paddingLeft:12},children:`PaySheet.tsx`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`,paddingLeft:12},children:`BuyNowButton.tsx`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`,paddingLeft:12},children:`styles.css`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Drive`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`The team's documents and files, in folders.`})]})]}),(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:6,padding:10,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`,fontSize:11.5},children:[(0,H.jsxs)(`div`,{style:{padding:`5px 8px`,borderRadius:6,background:`var(--ts-card-hi)`,display:`flex`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{children:`09:30 · Design Crit`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`},children:`@Des`})]}),(0,H.jsxs)(`div`,{style:{padding:`5px 8px`,borderRadius:6,background:`var(--ts-green-bg)`,border:`1px solid var(--ts-green-edge)`,display:`flex`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{children:`12:00 · Canary Rollout`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-green)`},children:`@Opera`})]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Calendar`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`The week's meetings and agent routines on one schedule.`})]})]}),(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,padding:10,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:8},children:[(0,H.jsx)(B9,{id:`vi`,size:32}),(0,H.jsx)(B9,{id:`dev`,size:32})]}),(0,H.jsxs)(`div`,{style:{fontSize:11,textAlign:`right`},children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Fix: Button Dark Mode`}),(0,H.jsx)(`div`,{style:{color:`var(--ts-mute)`},children:`Canvas · Live notes`})]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Meet`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`Calls with notes taken for you, in the same workspace as the work.`})]})]}),(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5,padding:10,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`,fontSize:11.5},children:[[`vi`,`Zoe Maxwell`,`@Dev`],[`dev`,`Harry Boone`,`@Zoe`],[`sci`,`Dev`,`@Sci`]].map(([e,t,n])=>(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:6},children:[(0,H.jsx)(B9,{id:e,size:18}),(0,H.jsx)(`span`,{children:t})]}),(0,H.jsx)(`span`,{style:{color:`var(--ts-blue)`,fontWeight:600},children:n})]},t+n))}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Inbox`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`Every mention, thread reply, and review request in one triage queue.`})]})]}),(0,H.jsxs)(`article`,{className:`hz-ts-tile`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,flexWrap:`wrap`,gap:6,padding:10,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`},children:G9.map(([e,t])=>(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:5,padding:`3px 8px 3px 4px`,borderRadius:999,background:`var(--ts-card)`,border:`1px solid var(--ts-rule)`,fontSize:11},children:[(0,H.jsx)(B9,{id:e,size:18}),t]},e))}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:15.5,fontWeight:600},children:`Agents`}),(0,H.jsx)(`div`,{style:{fontSize:13,color:`var(--ts-mute)`,marginTop:4},children:`Dedicated AI teammates configured with your repos, docs, and permissions.`})]})]})]})]}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Ten everyday workflows`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`10 Everyday Workflows`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`Ten everyday workflows your team hands off in a single mention.`}),(0,H.jsx)(`p`,{className:`hz-ts-sub`,children:`Open a channel, mention the right specialist teammate, and get finished work back — verified end-to-end by a second agent before you merge or send.`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-flows`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-flow-nav`,role:`tablist`,"aria-label":`Workflow channels`,children:[(0,H.jsx)(`div`,{style:{padding:`4px 10px 8px`,fontSize:11,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-dim)`},children:`HANZO · 10 CHANNELS`}),q9.map((e,t)=>(0,H.jsxs)(`button`,{type:`button`,role:`tab`,"aria-selected":d===t,className:`hz-ts-flow-btn`,onClick:()=>{m(!0),f(t)},children:[(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:7},children:[(0,H.jsx)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`,fontSize:11,color:`var(--ts-dim)`},children:e.no}),(0,H.jsxs)(`span`,{children:[`#`,e.channel]})]}),(0,H.jsxs)(`span`,{style:{display:`inline-flex`,gap:3},children:[(0,H.jsx)(B9,{id:e.faces[0],size:20}),(0,H.jsx)(B9,{id:e.faces[1],size:20})]})]},e.channel))]}),(0,H.jsxs)(`div`,{style:{padding:24,display:`flex`,flexDirection:`column`,gap:18},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,justifyContent:`space-between`,gap:8},children:[(0,H.jsxs)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`,fontSize:11.5,color:`var(--ts-mute)`},children:[`ACTIVE CREW · #`,C.channel,` · `,C.category]}),(0,H.jsx)(`span`,{style:{padding:`3px 9px`,borderRadius:999,background:`var(--ts-green-bg)`,border:`1px solid var(--ts-green-edge)`,color:`var(--ts-green)`,fontSize:11,fontWeight:700,fontFamily:`var(--font-mono, monospace)`},children:C.badge})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h3`,{style:{margin:0,fontSize:20,fontWeight:600},children:C.title}),(0,H.jsx)(`p`,{style:{margin:`6px 0 0`,fontSize:13.5,lineHeight:1.5,color:`var(--ts-mute)`},children:C.summary})]}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(280px, 1fr))`,gap:16},children:[(0,H.jsxs)(`div`,{style:{padding:14,borderRadius:12,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`,display:`flex`,flexDirection:`column`,gap:12},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9,alignItems:`flex-start`},children:[(0,H.jsx)(`span`,{className:`hz-ts-face`,style:{width:28,height:28},children:C.humanInitials}),(0,H.jsxs)(`div`,{style:{fontSize:12.5},children:[(0,H.jsxs)(`div`,{style:{fontWeight:600},children:[C.humanName,` `,(0,H.jsx)(`span`,{style:{color:`var(--ts-dim)`,fontWeight:400},children:C.humanTime})]}),(0,H.jsx)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2,lineHeight:1.45},children:C.humanAsk})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9,alignItems:`flex-start`},children:[(0,H.jsx)(B9,{id:C.leadAgent,size:28}),(0,H.jsxs)(`div`,{style:{fontSize:12.5,flex:1},children:[(0,H.jsxs)(`div`,{style:{fontWeight:600},children:[C.leadName,` · Agent`]}),(0,H.jsx)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2,lineHeight:1.45},children:C.leadReply}),(0,H.jsxs)(`div`,{style:{marginTop:6,padding:`6px 9px`,borderRadius:7,background:`var(--ts-card)`,border:`1px solid var(--ts-rule-strong)`,fontFamily:`var(--font-mono, monospace)`,fontSize:11,display:`flex`,alignItems:`center`,gap:6},children:[(0,H.jsx)(Kp,{size:12,color:`var(--ts-green)`}),(0,H.jsx)(`span`,{children:C.artifact})]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9,alignItems:`flex-start`},children:[(0,H.jsx)(B9,{id:C.verifyAgent,size:28}),(0,H.jsxs)(`div`,{style:{fontSize:12.5},children:[(0,H.jsxs)(`div`,{style:{fontWeight:600},children:[C.verifyName,` · Agent`]}),(0,H.jsx)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2,lineHeight:1.45},children:C.verifyLine})]})]})]}),(0,H.jsxs)(`div`,{style:{padding:14,borderRadius:12,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`,display:`flex`,flexDirection:`column`,justifyContent:`space-between`,gap:12},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:9},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,fontSize:11,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-mute)`},children:[(0,H.jsx)(`strong`,{children:`AUTOMATED WORKFLOW`}),(0,H.jsx)(`span`,{children:`4 / 4 complete`})]}),C.steps.map(e=>(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:8,fontSize:12.5,color:`var(--ts-ink)`},children:[(0,H.jsx)(Vt,{size:14,color:`var(--ts-green)`,style:{marginTop:2,flexShrink:0}}),(0,H.jsx)(`span`,{children:e})]},e))]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontSize:10.5,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-dim)`,marginBottom:6},children:`TOOLS & SANDBOXES USED`}),(0,H.jsx)(`div`,{style:{display:`flex`,flexWrap:`wrap`,gap:6},children:C.tools.map(e=>(0,H.jsx)(`span`,{style:{padding:`3px 8px`,borderRadius:6,background:`var(--ts-card)`,border:`1px solid var(--ts-rule)`,fontSize:11.5,color:`var(--ts-mute)`},children:e},e))})]})]})]})]})]})]}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Code channels and artifacts`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-head`,children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`Code Channels & Artifacts`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`Code channels where engineers, designers, and agents ship together.`}),(0,H.jsx)(`p`,{className:`hz-ts-sub`,children:`Every code channel pairs the conversation with a live Artifacts pane — Canvas root-cause writeups, unified branch diffs, and interactive previews.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,flexWrap:`wrap`,gap:8},role:`tablist`,"aria-label":`Code session steps`,children:gse.map((e,t)=>{let n=t+1,r=h===n;return(0,H.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":r,onClick:()=>g(n),style:{appearance:`none`,padding:`6px 12px`,borderRadius:999,border:`1px solid ${r?`var(--ts-ink)`:`var(--ts-rule-strong)`}`,background:r?`var(--ts-card-hi)`:`var(--ts-panel)`,color:r?`var(--ts-ink)`:`var(--ts-mute)`,fontSize:12,fontWeight:r?600:500,cursor:`pointer`},children:e},e)})}),(0,H.jsxs)(`div`,{className:`hz-ts-board-win`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-win-bar`,children:[(0,H.jsx)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`,fontSize:12},children:`hanzo.team — Hanzo AI (hanzo.ai) · #bug-button-darkmode`}),(0,H.jsx)(`span`,{style:{fontSize:11.5,color:`var(--ts-green)`,fontWeight:600},children:`Working · Session channel`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-code-grid`,children:[(0,H.jsxs)(`aside`,{style:{padding:14,borderRight:`1px solid var(--ts-rule)`,background:`var(--ts-panel)`,display:`flex`,flexDirection:`column`,gap:10,fontSize:12.5},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Hanzo AI`}),(0,H.jsx)(`div`,{style:{fontSize:11,color:`var(--ts-dim)`},children:`hanzo.ai`})]}),(0,H.jsx)(`div`,{style:{fontSize:10.5,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-dim)`,marginTop:4},children:`CODE CHANNELS`}),(0,H.jsx)(`div`,{style:{padding:`6px 8px`,borderRadius:7,background:`var(--ts-card-hi)`,fontWeight:600},children:`# bug-button-darkmode`}),(0,H.jsx)(`div`,{style:{padding:`4px 8px`,color:`var(--ts-mute)`},children:`# feat-wimse-tokens`}),(0,H.jsxs)(`div`,{style:{marginTop:`auto`,padding:8,borderRadius:8,background:`var(--ts-bg)`,border:`1px solid var(--ts-rule)`,fontFamily:`var(--font-mono, monospace)`,fontSize:10.5,color:`var(--ts-mute)`},children:[(0,H.jsx)(`div`,{children:`hanzoai/app`}),(0,H.jsx)(`div`,{style:{color:`var(--ts-ink)`},children:`main → update-cta-color`})]})]}),(0,H.jsxs)(`div`,{style:{padding:16,borderRight:`1px solid var(--ts-rule)`,display:`flex`,flexDirection:`column`,gap:12,fontSize:13},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9},children:[(0,H.jsx)(B9,{id:`dev`,size:26}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Dev · 9:31 AM`}),(0,H.jsxs)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2},children:[`Searched `,(0,H.jsx)(`code`,{children:`components/ui/`}),` and `,(0,H.jsx)(`code`,{children:`styles/cta-button.css`}),`: button foreground is too light on dark backgrounds. What contrast target should we use?`]})]})]}),h>=2?(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9},children:[(0,H.jsx)(`span`,{className:`hz-ts-face`,style:{width:26,height:26},children:`HB`}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Harry Boone · 9:32 AM`}),(0,H.jsx)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2},children:`@Zoe Maxwell what token should we pair with the accent fill?`})]})]}):null,h>=3?(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9},children:[(0,H.jsx)(`span`,{className:`hz-ts-face`,style:{width:26,height:26},children:`ZM`}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Zoe Maxwell · 9:34 AM`}),(0,H.jsxs)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2},children:[`Keep the pink pill and switch the label ink to `,(0,H.jsx)(`code`,{children:L9}),` for AAA contrast.`]})]})]}):null,h>=4?(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9},children:[(0,H.jsx)(B9,{id:`dev`,size:26}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Dev · 9:36 AM`}),(0,H.jsxs)(`div`,{style:{color:`var(--ts-mute)`,marginTop:2},children:[`Updated `,(0,H.jsx)(`code`,{children:`styles/cta-button.css`}),` and wrote the root-cause summary in Canvas. @Sci running E2E checks now.`]})]})]}):null,h>=5?(0,H.jsxs)(`div`,{style:{display:`flex`,gap:9},children:[(0,H.jsx)(B9,{id:`sci`,size:26}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Sci · 9:41 AM`}),(0,H.jsx)(`div`,{style:{color:`var(--ts-green)`,fontWeight:600,marginTop:2},children:`Verified across Chromium & Safari — WCAG AAA contrast (8.9:1) and 28/28 checkout specs green.`})]})]}):null,h>=6?(0,H.jsxs)(`div`,{style:{marginTop:`auto`,padding:`8px 12px`,borderRadius:8,background:`var(--ts-green-bg)`,border:`1px solid var(--ts-green-edge)`,color:`var(--ts-green)`,fontWeight:600,fontSize:12.5,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`span`,{children:`✓ ${F9} merged · E2E green`}),(0,H.jsx)(`span`,{style:{color:`var(--ts-mute)`,fontWeight:500},children:`Session complete`})]}):null]}),(0,H.jsxs)(`div`,{style:{background:`var(--ts-panel)`,display:`flex`,flexDirection:`column`},children:[(0,H.jsxs)(`div`,{style:{padding:`10px 12px`,borderBottom:`1px solid var(--ts-rule)`,display:`flex`,alignItems:`center`,justifyContent:`space-between`},children:[(0,H.jsx)(`strong`,{style:{fontSize:12.5},children:`Artifacts`}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:4},children:[`Code`,`View`,`Canvas`].map(e=>(0,H.jsx)(`button`,{type:`button`,onClick:()=>v(e),style:{appearance:`none`,border:`1px solid var(--ts-rule)`,background:_===e?`var(--ts-card-hi)`:`transparent`,color:_===e?`var(--ts-ink)`:`var(--ts-mute)`,borderRadius:6,padding:`3px 8px`,fontSize:11.5,fontWeight:600,cursor:`pointer`},children:e},e))})]}),_===`Code`?(0,H.jsxs)(`div`,{style:{padding:`10px 0`,display:`flex`,flexDirection:`column`,gap:2},children:[(0,H.jsx)(`div`,{style:{padding:`0 12px 8px`,fontSize:11,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-mute)`},children:`styles/cta-button.css · +3 -2`}),_se.map(([e,t,n,r],i)=>(0,H.jsxs)(`div`,{className:`hz-ts-diff-row`,"data-kind":n||void 0,children:[(0,H.jsx)(`span`,{style:{color:`var(--ts-dim)`},children:e}),(0,H.jsx)(`span`,{style:{color:`var(--ts-dim)`},children:t}),(0,H.jsx)(`span`,{children:r})]},i))]}):_===`View`?(0,H.jsxs)(`div`,{style:{padding:16,display:`flex`,flexDirection:`column`,gap:12},children:[(0,H.jsx)(`div`,{style:{fontSize:11,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-mute)`},children:`BEFORE (LOW CONTRAST · 1.9:1)`}),(0,H.jsx)(`div`,{style:{padding:`9px 14px`,borderRadius:8,background:`var(--ts-pink-low)`,color:`var(--ts-pink-ink-bad)`,fontWeight:500,textAlign:`center`,fontSize:13},children:`Buy Now — $49`}),(0,H.jsx)(`div`,{style:{fontSize:11,fontFamily:`var(--font-mono, monospace)`,color:`var(--ts-green)`},children:`AFTER FIX (${L9} ON ${R9} · 8.9:1 AAA)`}),(0,H.jsx)(`div`,{style:{padding:`9px 14px`,borderRadius:8,background:`var(--ts-pink-fill)`,color:`var(--ts-pink-ink-good)`,fontWeight:700,textAlign:`center`,fontSize:13},children:`Buy Now — $49`})]}):(0,H.jsxs)(`div`,{style:{padding:16,display:`flex`,flexDirection:`column`,gap:10,fontSize:12.5},children:[(0,H.jsx)(`div`,{style:{fontWeight:600},children:`Fix: Button Dark Mode`}),(0,H.jsxs)(`div`,{style:{color:`var(--ts-mute)`,lineHeight:1.5},children:[`Global dark theme inherited light foreground text onto `,(0,H.jsx)(`code`,{children:`.cta-button`}),` without scoping contrast to the accent surface token.`]}),(0,H.jsx)(`div`,{style:{color:`var(--ts-green)`,fontWeight:600},children:`✓ WCAG AAA contrast ratio (8.9:1) verified`})]})]})]})]})]}),(0,H.jsxs)(`section`,{className:`hz-ts-sec`,"aria-label":`Get Hanzo Team`,children:[(0,H.jsxs)(`div`,{className:`hz-ts-split`,style:{alignItems:`center`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:10},children:[(0,H.jsx)(`span`,{className:`hz-ts-kicker`,children:`Paste and ship`}),(0,H.jsx)(`h2`,{className:`hz-ts-h2`,children:`Get Team`}),(0,H.jsx)(`p`,{className:`hz-ts-sub`,children:`Paste this prompt into any agent. It reads the skill manifest and connects your project to Hanzo Team.`})]}),(0,H.jsxs)(`div`,{className:`hz-ts-stage-card`,style:{gap:12},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,fontSize:12,color:`var(--ts-mute)`},children:[(0,H.jsx)(`span`,{style:{fontFamily:`var(--font-mono, monospace)`},children:`Agent prompt · MIT Open Source`}),(0,H.jsxs)(`button`,{type:`button`,onClick:()=>{navigator.clipboard?.writeText(z9),x(!0),window.setTimeout(()=>x(!1),1800)},style:{appearance:`none`,border:`1px solid var(--ts-rule-strong)`,background:`var(--ts-card)`,color:`var(--ts-ink)`,borderRadius:7,padding:`4px 10px`,fontSize:11.5,fontWeight:600,display:`inline-flex`,alignItems:`center`,gap:6,cursor:`pointer`},children:[b?(0,H.jsx)(Vt,{size:12,color:`var(--ts-green)`}):(0,H.jsx)(Fp,{size:12}),(0,H.jsx)(`span`,{children:b?`Copied`:`Copy`})]})]}),(0,H.jsx)(`div`,{style:{padding:`12px 14px`,borderRadius:10,background:`var(--ts-panel)`,border:`1px solid var(--ts-rule)`,fontFamily:`var(--font-mono, monospace)`,fontSize:12.5,color:`var(--ts-ink)`,wordBreak:`break-word`},children:z9})]})]}),(0,H.jsxs)(z,{width:`100%`,p:kH.edge,rounded:Q.card,borderWidth:1,borderColor:X.rule,bg:X.panel,items:`center`,gap:kH.inset,style:{textAlign:`center`,marginTop:12},children:[(0,H.jsx)(a,{size:Z.title,color:X.ink,fontWeight:`700`,children:`One workspace for how your team actually works.`}),(0,H.jsx)(a,{size:Z.body,color:X.mute,style:{maxWidth:560},children:`Bring your projects, tasks, conversations, docs, meetings, and AI teammates together.`}),(0,H.jsxs)(y,{gap:kH.tight,flexWrap:`wrap`,justify:`center`,pt:kH.tight,children:[(0,H.jsx)(W,{size:`lg`,rounded:Q.pill,bg:X.ink,disabled:t,onPress:e,children:(0,H.jsx)(a,{size:Z.small,color:X.ground,fontWeight:`600`,children:t?`One moment…`:`Open Team`})}),(0,H.jsx)(W,{size:`lg`,variant:`outline`,rounded:Q.pill,onPress:()=>window.location.assign(`https://hanzo.ai/contact-sales`),children:(0,H.jsx)(a,{size:Z.small,color:X.ink,fontWeight:`500`,children:`Contact sales`})})]})]})]})]})}var yse=`https://pay.hanzo.ai/cart`,bse=(e,t)=>{let n=new URL(yse);return new URLSearchParams(e).forEach((e,t)=>n.searchParams.set(t,e)),n.searchParams.get(`plan`)||n.searchParams.set(`plan`,`team`),n.searchParams.set(`returnUrl`,`${t}/`),n.toString()},xse=`/auth/callback`,$=`https://hanzo.ai`,J9=`https://docs.hanzo.ai`,Sse=`https://github.com/hanzoai`,Cse=`https://status.hanzo.ai`,wse=`https://hanzo.agency`,Tse=`https://hanzo.university`,Y9=[{label:`Features`,href:`https://hanzo.ai/team`},{label:`Docs`,href:`https://docs.hanzo.ai`},{label:`Hanzo Bot`,href:`https://hanzo.bot`},{label:`Hanzo App`,href:`https://hanzo.app`},{label:`API Platform`,href:`https://platform.hanzo.ai`},{label:`Hanzo AI`,href:`https://hanzo.ai`}],Ese=[{id:`damon`,name:`Damon Motorcycles`,logo:`/logos/customers/damon-motorcycles.svg`,href:`${$}/customers/damon-motorcycles`},{id:`kanoa`,name:`KANOA`,logo:`/logos/customers/kanoa.png`,href:`${$}/customers/kanoa`},{id:`skully`,name:`SKULLY`,logo:`/logos/customers/skully.png`,href:`${$}/customers#skully`},{id:`bellabeat`,name:`Bellabeat`,logo:`/logos/customers/bellabeat.svg`,href:`${$}/customers#bellabeat`},{id:`stoned`,name:`STONED Audio`,logo:`/logos/customers/stoned.svg`,href:`${$}/customers#stoned`},{id:`unikrn`,name:`Unikrn`,logo:`/logos/customers/unikoin-gold.svg`,href:`${$}/customers#unikoin-gold`},{id:`arca`,name:`Arca`,logo:`/logos/customers/arca.png`,href:`${$}/customers#arca`},{id:`casper`,name:`Casper Labs`,logo:`/logos/customers/casper-blockchain.svg`,href:`${$}/customers#casper-blockchain`},{id:`triller`,name:`Triller`,logo:`/logos/customers/trillerfest.png`,href:`${$}/customers#trillerfest`},{id:`cover`,name:`Cover Build`,logo:`/logos/customers/cover-build.svg`,href:`${$}/customers#cover-build`},{id:`myle`,name:`Myle Tap`,logo:`/logos/customers/myle-tap.png`,href:`${$}/customers#myle-tap`},{id:`keek`,name:`Personas Social`,logo:`/logos/customers/keek-social.svg`,href:`${$}/customers#keek-social`}],Dse=[[{title:`Products`,href:`${$}/products`,links:[{label:`Hanzo App`,href:`https://hanzo.app`},{label:`Hanzo Dev`,href:`${$}/dev`},{label:`Hanzo Bot`,href:`https://hanzo.bot`},{label:`Hanzo Team`,href:`https://hanzo.team`},{label:`Hanzo Science`,href:`${$}/science`},{label:`Hanzo Security`,href:`${$}/security`},{label:`Download app`,href:`${$}/download`},{label:`Pricing`,href:`${$}/pricing`}]},{title:`Capabilities`,links:[{label:`Hanzo Design`,href:`${$}/design`},{label:`MCP`,href:`${$}/mcp`},{label:`Skills`,href:`${$}/skills`},{label:`Integrations`,href:`${$}/integrations`},{label:`Hanzo CLI`,href:`${$}/cli`}]},{title:`Extensions`,links:[{label:`Hanzo in Chrome`,href:`${$}/extension`},{label:`Desktop app`,href:`${$}/desktop`},{label:`Hanzo IDE`,href:`${$}/ide`}]},{title:`Models`,href:`${$}/models`,links:[{label:`All models`,href:`${$}/models`},{label:`Zen`,href:`${$}/zen`},{label:`Enso`,href:`${$}/enso`},{label:`Kai`,href:`${$}/kai`},{label:`Video · Koma`,href:`${$}/koma`},{label:`Images · Iro`,href:`${$}/iro`},{label:`3D · Mori`,href:`${$}/mori`},{label:`Voice · Koe`,href:`${$}/koe`},{label:`Benchmarks`,href:`${$}/benchmarks`}]}],[{title:`Enterprise`,href:`${$}/enterprise`,links:[{label:`Overview`,href:`${$}/enterprise`},{label:`All solutions`,href:`${$}/solutions`},{label:`Customer stories`,href:`${$}/customers`},{label:`Contact sales`,href:`${$}/contact-sales`}]},{title:`Teams`,href:`${$}/solutions`,links:[{label:`Engineering`,href:`${$}/solutions/engineering`},{label:`Operations`,href:`${$}/solutions/operations`},{label:`Finance`,href:`${$}/solutions/finance`},{label:`Data`,href:`${$}/solutions/data`},{label:`Sales`,href:`${$}/solutions/sales`},{label:`Marketing`,href:`${$}/solutions/marketing`},{label:`Design`,href:`${$}/solutions/design`}]},{title:`Industries`,href:`${$}/solutions`,links:[{label:`Cybersecurity`,href:`${$}/solutions/cybersecurity`},{label:`Financial services`,href:`${$}/solutions/financial-services`},{label:`Government`,href:`${$}/solutions/government`},{label:`Healthcare`,href:`${$}/solutions/healthcare`},{label:`Education`,href:`${$}/solutions/education`},{label:`Law`,href:`${$}/solutions/law`},{label:`Retail`,href:`${$}/solutions/retail`}]},{title:`Programs`,href:`${$}/startups`,links:[{label:`Startups`,href:`${$}/startups`},{label:`Affiliate program`,href:`${$}/affiliate`},{label:`Referral program`,href:`${$}/referral`},{label:`Reserved tier`,href:`${$}/solutions/reserved`},{label:`OSS grants`,href:`${$}/open-source`}]}],[{title:`Developers`,href:J9,links:[{label:`Developer docs`,href:J9},{label:`API reference`,href:`${J9}/docs/openapi/`},{label:`Quickstart`,href:`${J9}/docs/quickstart/`},{label:`SDKs`,href:`${$}/sdks`},{label:`Console`,href:`https://platform.hanzo.ai`},{label:`GitHub`,href:Sse}]},{title:`API Platform`,href:`${$}/platform`,links:[{label:`Overview`,href:`${$}/platform`},{label:`API keys`,href:`https://platform.hanzo.ai/settings/organization/keys`},{label:`Gateway`,href:`${$}/gateway`},{label:`Agents`,href:`${$}/agents`},{label:`Playground`,href:`${$}/playground`}]},{title:`Cloud`,href:`${$}/products`,links:[{label:`Base`,href:`${$}/base`},{label:`Machines`,href:`${$}/machines`},{label:`Search`,href:`${$}/search`},{label:`Datastore`,href:`${$}/datastore`},{label:`Memory`,href:`${$}/products/memory`},{label:`Realtime`,href:`${$}/realtime`},{label:`Observability`,href:`${$}/o11y`},{label:`Insights`,href:`${$}/insights`},{label:`Commerce`,href:`${$}/commerce`}]},{title:`Help and security`,links:[{label:`Availability`,href:Cse},{label:`Help center`,href:`${$}/support`},{label:`Security and compliance`,href:`${$}/security`},{label:`Trust & transparency`,href:`${$}/trust`}]}],[{title:`Company`,href:`${$}/about`,links:[{label:`Hanzo AI`,href:`${$}/about`},{label:`Careers`,href:`${$}/careers`},{label:`Philosophy`,href:`${$}/philosophy`},{label:`Research`,href:`${$}/research`},{label:`News`,href:`${$}/press`},{label:`Investors`,href:`${$}/investors`},{label:`Brand`,href:`${$}/brand`},{label:`Open source`,href:`${$}/open-source`},{label:`Contact`,href:`${$}/contact`}]},{title:`Resources`,href:`${$}/learn`,links:[{label:`Blog`,href:`${$}/blog`},{label:`Guides`,href:`${J9}/docs/guides/`},{label:`Cookbook`,href:`${J9}/docs/guides/cookbook/`},{label:`Hanzo University`,href:Tse},{label:`Hanzo Agency`,href:wse},{label:`Cost calculator`,href:`${$}/calculator`}]},{title:`Terms and policies`,href:`${$}/legal`,links:[{label:`Privacy choices`,href:`${$}/privacy#choices`},{label:`Privacy policy`,href:`${$}/privacy`},{label:`Terms of service`,href:`${$}/terms`},{label:`Usage policy`,href:`${$}/aup`},{label:`Cookie policy`,href:`${$}/cookies`},{label:`Other policies`,href:`${$}/legal`}]}]],Ose=[{label:`Discord`,href:`https://discord.gg/XthHQQj`},{label:`Telegram`,href:`https://t.me/hanzoai`},{label:`X`,href:`https://x.com/hanzoai`},{label:`GitHub`,href:`https://github.com/hanzoai`},{label:`LinkedIn`,href:`https://linkedin.com/company/hanzo-ai`},{label:`Facebook`,href:`https://facebook.com/hanzoinc`},{label:`Bluesky`,href:`https://bsky.app/profile/hanzoai.bsky.social`},{label:`Reddit`,href:`https://www.reddit.com/r/HanzoAI/`},{label:`TikTok`,href:`https://www.tiktok.com/@hanzoinc`},{label:`Instagram`,href:`https://www.instagram.com/hanzoinc`}];function kse(){let e=(0,V.useRef)(null);return(0,V.useEffect)(()=>{let t=e.current,n=t?.parentElement;if(!t||!n)return;let r=t.getContext(`2d`);if(!r)return;let i=window.matchMedia(`(prefers-reduced-motion: reduce)`).matches,a=0,o=0,s=0,c=0,l=0,u=-1e4,d=-1e4,f=-1e4,p=-1e4,m=!1,h=0,g=0,_=[.085,.155,.235],v=[.32,.44,.56,.68,.8,.92],y=[[],[],[]],b=[[],[],[],[],[],[]],x=()=>{if(a<1||o<1)return;r.clearRect(0,0,a,o),r.fillStyle=getComputedStyle(t).color;for(let e=0;e<3;e++)y[e].length=0;for(let e=0;e<6;e++)b[e].length=0;let e=a*.18,n=o*.58,i=a*.82,l=o*.48,u=1/Math.max(1,o),d=Math.max(1,a*.3),m=Math.max(1,a*.34),g=h>.01&&f>-5e3;for(let t=0;t<c;t++){let r=t*10,o=.28+r*u*.95,c=o<1?o:1,_=o<1?u*.95:0;for(let t=0;t<s;t++){let o=t*10,s=1-o/d,u=(o-a*.66)/m,v=.14,x=0;s>=u&&s>.14?(v=s,x=-1/d):u>.14&&(v=u,x=1/m);let S=o*.012+r*.006,C=r*.014-o*.005,w=(o+r)*.007,T=Math.sin(S),E=Math.cos(S),D=Math.cos(C),O=Math.sin(C),k=Math.sin(w),A=Math.cos(w),j=T*D*.65+k*.35,ee=.65*(.012*E*D+T*.005*O)+.00245*A,M=.65*(.006*E*D-T*.014*O)+.00245*A,N=.56+.44*j,P=v*c*N*1.24,te=(x*c*N+v*c*.44*ee)*1.24,F=(v*_*N+v*c*.44*M)*1.24,I=o-e,ne=r-n,re=I*I+ne*ne;if(re<57600){let e=Math.sqrt(re)||1,t=1-e/240;P+=t*t*.24;let n=-.48*t/(240*e);te+=n*I,F+=n*ne}let ie=o-i,L=r-l,ae=ie*ie+L*L;if(ae<57600){let e=Math.sqrt(ae)||1,t=1-e/240;P+=t*t*.24;let n=-.48*t/(240*e);te+=n*ie,F+=n*L}let oe=P<0?0:P>1?1:P;if(oe<.05)continue;let R=-te*68,se=-F*68,ce=1/Math.sqrt(R*R+se*se+1),le=R*ce,ue=se*ce,de=ce,fe=o+le*oe*2.4,pe=r+ue*oe*2.4,me=oe*10*.38,he=-1;if(g){let e=f-o,t=p-r,n=e*e+t*t;if(n<65025){let r=1-Math.sqrt(n)/255,i=r*r*(3-2*r),a=108-oe*44,o=1/Math.sqrt(n+a*a),s=e*o,c=t*o,l=a*o,u=Math.max(0,le*s+ue*c+de*l),d=l+1,f=1/Math.sqrt(s*s+c*c+d*d),p=Math.max(0,(le*s+ue*c+de*d)*f),m=p*p,g=m*m,_=g*g*g,v=Math.max(.06,Math.min(1,(j+.72)*.68))*(.2+.8*oe),y=i*h*v*(.42*u+1.05*_),b=y*(.35+.65*oe);me=Math.min(4.8,me+b*10*.16),fe-=e/255*oe*2.2*i*h,pe-=t/255*oe*2.2*i*h,y>.07&&(he=Math.min(5,Math.floor((y-.07)*7.2)))}}he>=0?b[he].push(fe,pe,me):y[oe<.28?0:oe<.56?1:2].push(fe,pe,me)}}for(let e=0;e<3;e++){let t=y[e];if(t.length){r.globalAlpha=_[e],r.beginPath();for(let e=0;e<t.length;e+=3){let n=t[e],i=t[e+1],a=t[e+2];r.moveTo(n+a,i),r.arc(n,i,a,0,6.2832)}r.fill()}}for(let e=0;e<6;e++){let t=b[e];if(t.length){r.globalAlpha=v[e],r.beginPath();for(let e=0;e<t.length;e+=3){let n=t[e],i=t[e+1],a=t[e+2];r.moveTo(n+a,i),r.arc(n,i,a,0,6.2832)}r.fill()}}r.globalAlpha=1},S=()=>{g*=.9;let e=m?Math.min(1,.72+g*.28):0;h+=(e-h)*(m?.18:.08),f<-5e3&&u>-5e3?(f=u,p=d):u>-5e3&&(f+=(u-f)*.28,p+=(d-p)*.28),x(),l=h>.01||m?requestAnimationFrame(S):0},C=()=>{!l&&(h>.01||m)&&(l=requestAnimationFrame(S))},w=()=>{let e=n.getBoundingClientRect(),i=Math.min(window.devicePixelRatio||1,2);a=e.width,o=e.height,!(a<1||o<1)&&(t.width=Math.round(a*i),t.height=Math.round(o*i),t.style.width=`${a}px`,t.style.height=`${o}px`,r.setTransform(i,0,0,i,0,0),s=Math.ceil(a/10)+1,c=Math.ceil(o/10)+1,x())},T=e=>{if(i||e.pointerType===`touch`)return;let t=n.getBoundingClientRect(),r=e.clientX-t.left,a=e.clientY-t.top;u>-5e3&&(g=Math.min(1.4,g+Math.hypot(r-u,a-d)*.016)),u=r,d=a,m=!0,C()},E=()=>{m=!1,C()};w();let D=new ResizeObserver(w);return D.observe(n),window.addEventListener(`pointermove`,T,{passive:!0}),document.addEventListener(`mouseleave`,E,{passive:!0}),()=>{l&&cancelAnimationFrame(l),D.disconnect(),window.removeEventListener(`pointermove`,T),document.removeEventListener(`mouseleave`,E)}},[]),(0,H.jsx)(`canvas`,{ref:e,"aria-hidden":`true`,style:{position:`absolute`,inset:0,width:`100%`,height:`100%`,pointerEvents:`none`,zIndex:0,color:`var(--foreground)`}})}var Ase=()=>{let{standing:e,depart:t,request:n}=pV(),[r,i]=(0,V.useState)(null);if(e===`in`)return null;let o=(e,n)=>{i(e),t(n).catch(()=>i(null))},s=r!==null;return(0,H.jsxs)(z,{flex:1,bg:X.ground,overflow:`scroll`,children:[(0,H.jsxs)(y,{width:`100%`,minH:68,px:kH.wide,py:kH.tight,items:`center`,justify:`space-between`,borderBottomWidth:1,borderColor:X.rule,bg:X.ground,style:{position:`sticky`,top:0,zIndex:40},children:[(0,H.jsx)(y,{items:`center`,gap:kH.tight,cursor:`pointer`,shrink:0,onPress:()=>window.location.assign(`/`),children:(0,H.jsx)(a,{size:Z.row,color:X.ink,fontWeight:`600`,children:`Hanzo ${IB.title}`})}),(0,H.jsxs)(y,{items:`center`,gap:kH.tight,shrink:0,children:[(0,H.jsx)(`div`,{className:`hz-landing-nav-links`,children:Y9.map(e=>(0,H.jsx)(W,{size:`sm`,chromeless:!0,rounded:Q.pill,onPress:()=>window.location.assign(e.href),children:(0,H.jsx)(a,{size:Z.small,color:X.mute,children:e.label})},e.label))}),(0,H.jsx)(W,{size:`sm`,variant:`outline`,rounded:Q.pill,onPress:()=>window.location.assign(`https://hanzo.ai/contact-sales`),children:(0,H.jsx)(a,{size:Z.small,color:X.ink,fontWeight:`500`,children:`Contact sales`})}),(0,H.jsx)(W,{size:`sm`,rounded:Q.pill,bg:X.ink,disabled:s,onPress:()=>o(`open`,`login`),children:(0,H.jsx)(a,{size:Z.small,color:X.ground,fontWeight:`600`,children:((e,t)=>r===e?`One moment…`:t)(`open`,`Open Team`)})})]})]}),(0,H.jsxs)(`main`,{className:`hz-signin`,children:[(0,H.jsx)(kse,{}),(0,H.jsxs)(`div`,{className:`hz-signin-row`,children:[(0,H.jsxs)(`div`,{className:`hz-signin-copy`,children:[(0,H.jsx)(pJ,{bare:!0,title:`Sign in to Hanzo ${IB.title}`,line:`AI cockpit, live streams, issue boards, channels, and bots for your team.`,request:n,termsHref:`${$}/terms`,privacyHref:`${$}/privacy`}),(0,H.jsx)(y,{items:`center`,justify:`center`,pt:kH.tight,children:(0,H.jsx)(a,{size:Z.small,color:X.mute,cursor:`pointer`,onPress:()=>window.location.assign(`${$}/team`),style:{textDecoration:`underline`,textUnderlineOffset:`3px`},children:`Learn more about Hanzo Team →`})})]}),(0,H.jsxs)(`div`,{className:`hz-signin-figure`,children:[(0,H.jsx)(use,{}),(0,H.jsx)(fse,{})]})]})]}),(0,H.jsxs)(z,{width:`100%`,items:`center`,px:kH.wide,py:kH.edge,gap:kH.inset,bg:X.ground,children:[(0,H.jsx)(a,{size:Z.small,color:X.mute,fontWeight:`500`,style:{textAlign:`center`},children:`Companies building with the Hanzo API`}),(0,H.jsx)(`div`,{className:`hz-mq-view`,children:(0,H.jsx)(`div`,{className:`hz-mq-track`,children:[0,1].map(e=>Ese.map(t=>{let n=e>0;return(0,H.jsx)(`a`,{href:t.href,className:`hz-logo`,"aria-label":n?void 0:t.name,"aria-hidden":n||void 0,tabIndex:n?-1:void 0,target:`_blank`,rel:`noopener noreferrer`,title:t.name,children:(0,H.jsx)(`img`,{src:t.logo,alt:n?``:t.name,loading:`lazy`})},`${e}-${t.id}`)}))})})]}),(0,H.jsx)(vse,{onOpen:()=>o(`open`,`login`),working:s}),(0,H.jsx)(z,{width:`100%`,borderTopWidth:1,borderColor:X.rule,bg:X.ground,px:kH.wide,py:kH.edge,children:(0,H.jsxs)(z,{width:`100%`,maxW:1240,mx:`auto`,gap:kH.edge,children:[(0,H.jsxs)(y,{justify:`space-between`,items:`flex-start`,gap:kH.edge,flexWrap:`wrap`,children:[(0,H.jsx)(z,{minW:160,gap:kH.tight,children:(0,H.jsxs)(y,{items:`center`,gap:kH.tight,cursor:`pointer`,onPress:()=>window.location.assign($),children:[(0,H.jsx)(z,{width:22,height:22,rounded:Q.field,bg:X.ink,items:`center`,justify:`center`,children:(0,H.jsx)(a,{size:Z.small,color:X.ground,fontWeight:`700`,children:`H`})}),(0,H.jsx)(a,{size:Z.row,color:X.ink,fontWeight:`600`,children:`Hanzo`})]})}),(0,H.jsx)(y,{gap:kH.edge,flexWrap:`wrap`,grow:1,justify:`space-between`,children:Dse.map((e,t)=>(0,H.jsx)(z,{minW:150,gap:kH.inset,children:e.map(e=>(0,H.jsxs)(z,{gap:kH.tight,children:[(0,H.jsx)(a,{size:Z.small,color:X.ink,fontWeight:`600`,cursor:e.href?`pointer`:void 0,onPress:e.href?()=>window.location.assign(e.href):void 0,style:{lineHeight:`1.35`},children:e.title}),(0,H.jsx)(z,{style:{gap:`2.5px`},children:e.links.map(e=>(0,H.jsx)(a,{size:Z.small,color:X.mute,cursor:e.href?`pointer`:void 0,onPress:()=>window.location.assign(e.href),style:{lineHeight:`1.32`},children:e.label},e.href+e.label))})]},e.title))},t))})]}),(0,H.jsx)(y,{pt:kH.inset,borderTopWidth:1,borderColor:X.rule,items:`center`,flexWrap:`wrap`,style:{columnGap:`24px`,rowGap:`8px`},children:Ose.map(e=>(0,H.jsxs)(a,{size:Z.small,color:X.mute,cursor:`pointer`,onPress:()=>window.location.assign(e.href),style:{lineHeight:`1.35`},children:[e.label,` ↗`]},e.label))}),(0,H.jsxs)(y,{pt:kH.inset,borderTopWidth:1,borderColor:X.rule,items:`center`,justify:`space-between`,flexWrap:`wrap`,gap:kH.tight,children:[(0,H.jsx)(a,{size:Z.chip,color:X.dim,children:`© 2026 Hanzo AI, Inc. All rights reserved.`}),(0,H.jsx)(y,{gap:kH.inset,flexWrap:`wrap`,children:[[`Terms`,`${$}/terms`],[`Privacy`,`${$}/privacy`],[`Usage policy`,`${$}/aup`],[`Privacy choices`,`${$}/privacy#choices`]].map(([e,t])=>(0,H.jsx)(a,{size:Z.chip,color:X.dim,cursor:`pointer`,onPress:()=>window.location.assign(t),children:e},e))})]})]})})]})},X9=`team.enrol_tried`,jse=({children:e})=>{let{standing:t}=pV(),{standing:n,refusal:r,enrolNow:i,enrolment:a}=nH(),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(!1);return(0,V.useEffect)(()=>{if(n===`settled`){try{sessionStorage.removeItem(X9)}catch{}l(!1)}},[n]),(0,V.useEffect)(()=>{if(t!==`in`||n!==`stranger`)return;let e=!1;try{e=sessionStorage.getItem(X9)===`1`}catch{e=!0}if(e){l(!0);return}try{sessionStorage.setItem(X9,`1`)}catch{}s(!0),i().then(e=>{e?s(!1):navigator.webdriver?(s(!1),l(!0)):window.location.replace(a)})},[t,n,i,a]),window.location.pathname===xse?(0,H.jsx)(ase,{}):window.location.pathname===`/start`?(0,H.jsx)(Mse,{to:bse(window.location.search,window.location.origin)}):t===`unknown`?(0,H.jsx)(Z9,{}):t===`out`?(0,H.jsx)(Ase,{}):n===`stranger`?c?(0,H.jsx)(Q9,{title:`One more step`,body:`Set up your workspace to see your projects.`,children:(0,H.jsx)(W,{disabled:o,onPress:()=>{s(!0),i().then(e=>{e?s(!1):window.location.assign(a)})},children:o?`Setting up…`:`Set up`})}):(0,H.jsx)(Z9,{}):n===`refused`?(0,H.jsx)(Q9,{title:`Your workspace is not answering`,body:r?.message??``,children:(0,H.jsx)(W,{onPress:()=>window.location.reload(),children:`Try again`})}):n===`unknown`?(0,H.jsx)(Z9,{}):(0,H.jsx)(H.Fragment,{children:e})},Mse=({to:e})=>((0,V.useEffect)(()=>window.location.replace(e),[e]),(0,H.jsx)(Z9,{})),Z9=()=>(0,H.jsx)(z,{flex:1,items:`center`,justify:`center`,bg:X.ground,children:(0,H.jsx)(rv,{})}),Q9=({title:e,body:t,children:n})=>(0,H.jsxs)(z,{flex:1,items:`center`,justify:`center`,gap:kH.inset,bg:X.ground,p:kH.wide,children:[(0,H.jsx)(a,{size:Z.title,color:X.ink,children:e}),t?(0,H.jsx)(a,{size:Z.body,color:X.mute,children:t}):null,n]}),Nse=()=>Ti(ise),Pse=200,Fse=()=>{let{effectiveTheme:e}=r7();return(0,V.useEffect)(()=>{t7(Q5()),lae(GB().getAccessToken())},[]),(0,H.jsx)(My,{theme:e,position:`top-center`})},Ise=()=>(0,H.jsxs)(Xne,{children:[(0,H.jsx)(Zm,{delay:Pse,children:(0,H.jsx)(CV,{children:(0,H.jsxs)(aH,{children:[(0,H.jsx)(_oe,{}),(0,H.jsx)(jse,{children:(0,H.jsx)(Aa,{children:(0,H.jsx)(Nse,{})})})]})})}),(0,H.jsx)(Fse,{}),(0,H.jsx)(sre,{floating:!1})]});Te({token:()=>GB().getAccessToken()??void 0});var $9=document.getElementById(`root`);if(!$9)throw Error(`no #root`);(0,Wn.createRoot)($9).render((0,H.jsx)(V.StrictMode,{children:(0,H.jsx)(Ise,{})}));export{pW as $,T3 as A,XG as B,h3 as C,b3 as D,v3 as E,ZJ as F,vG as G,WG as H,TJ as I,DG as J,EG as K,bK as L,X0 as M,FZ as N,S3 as O,UY as P,dW as Q,uK as R,m3 as S,_3 as T,OG as U,KG as V,_G as W,_W as X,fG as Y,uW as Z,s3 as _,Fp as _t,R3 as a,av as at,f3 as b,La as bt,J4 as c,L_ as ct,$4 as d,Xg as dt,nH as et,t3 as f,f_ as ft,o3 as g,vm as gt,a3 as h,W as ht,B3 as i,rC as it,R2 as j,C3 as k,Y4 as l,Bg as lt,i3 as m,Hg as mt,J3 as n,nC as nt,L3 as o,I_ as ot,r3 as p,p_ as pt,kG as q,z3 as r,aC as rt,q4 as s,R_ as st,D8 as t,WB as tt,Z4 as u,Kg as ut,c3 as v,wp as vt,g3 as w,p3 as x,u3 as y,U as yt,cK as z};
|
|
194
|
+
//# sourceMappingURL=index-nlYZdUfp.js.map
|