@abtnode/webapp 1.16.48 → 1.16.49-beta-20250813-141500-f02b41b4
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/blocklet.js +1 -1
- package/blocklet.yml +1 -1
- package/dist/assets/{AdapterDayjs-CMmkTpH7.js → AdapterDayjs-BjO18toV.js} +1 -1
- package/dist/assets/{Add-S-3I84b8.js → Add-D7FBmxz9.js} +1 -1
- package/dist/assets/ArrowDropDown-CGRxh8gD.js +1 -0
- package/dist/assets/{Autocomplete-BaEPlYLx.js → Autocomplete-Bj2hcqGf.js} +1 -1
- package/dist/assets/{Breadcrumbs-BiRfhuZp.js → Breadcrumbs-DwE835ah.js} +1 -1
- package/dist/assets/{ButtonGroup-Bb6jDsD1.js → ButtonGroup-CToFieon.js} +1 -1
- package/dist/assets/{CSSTransition-wxeeFOKf.js → CSSTransition-DG0p2bDc.js} +1 -1
- package/dist/assets/{CallMerge-D7rsNNxc.js → CallMerge-DDDKPRmO.js} +1 -1
- package/dist/assets/{CardContent-F-Sbai2s.js → CardContent-DXBw-i1o.js} +1 -1
- package/dist/assets/{ChevronLeft-DADCIS34.js → ChevronLeft-ClJUpIrX.js} +1 -1
- package/dist/assets/{ChevronRight-B_f9hb86.js → ChevronRight-pNcrG18Z.js} +1 -1
- package/dist/assets/{Clear-v5WhrN0k.js → Clear-wN_lM9i_.js} +1 -1
- package/dist/assets/{DeleteOutline-DkhKATuN.js → DeleteOutline-0Pjk0X04.js} +1 -1
- package/dist/assets/{Done-BrXgYrm-.js → Done-Bvnq95wW.js} +1 -1
- package/dist/assets/{Edit-b0bQueoc.js → Edit-CVMHb0TK.js} +1 -1
- package/dist/assets/{ErrorOutline-cbP6hbrl.js → ErrorOutline-B2Mw_vUr.js} +1 -1
- package/dist/assets/{FilterList-CETwaOot.js → FilterList-agXhdRax.js} +1 -1
- package/dist/assets/{Google-G2hBKskK.js → Google-CnSXuxho.js} +1 -1
- package/dist/assets/{HelpOutline-DaPSpbPH.js → HelpOutline-CNZGWmTU.js} +1 -1
- package/dist/assets/{Launch-CxDOgvl0.js → Launch-CmazaRGZ.js} +1 -1
- package/dist/assets/{Link-CCQ4Xrxg.js → Link-DxObZpZX.js} +1 -1
- package/dist/assets/{ListItemButton-f6NCT9iY.js → ListItemButton-Bk_S-24I.js} +1 -1
- package/dist/assets/{ListSubheader-YCstldBv.js → ListSubheader-CjL9mMf3.js} +1 -1
- package/dist/assets/{LoadingButton-DY_lGC3z.js → LoadingButton-BTTKyDvk.js} +1 -1
- package/dist/assets/{MoreVert-C716pe1M.js → MoreVert-CpVaEDbL.js} +1 -1
- package/dist/assets/{OpenInNew-8_57FieH.js → OpenInNew-zVEoRj2W.js} +1 -1
- package/dist/assets/{Refresh-lnreJErX.js → Refresh-BZtduSQA.js} +1 -1
- package/dist/assets/{Search-hhDB6YL9.js → Search-C1hYBh2z.js} +1 -1
- package/dist/assets/{Slider-DMeR2md5.js → Slider-D41Gc6DM.js} +1 -1
- package/dist/assets/{Stepper-CKg6__EK.js → Stepper-Bax0qACN.js} +1 -1
- package/dist/assets/{Switch-CEsPeHy7.js → Switch-BA5PH6p0.js} +1 -1
- package/dist/assets/{TableSearch-Lg4M-8KA.js → TableSearch-BzANvfKC.js} +1 -1
- package/dist/assets/{ToggleButtonGroup-prN9b22p.js → ToggleButtonGroup-BzxI_4Ka.js} +1 -1
- package/dist/assets/{Verified-YDT1ukv5.js → Verified-B9q95gmQ.js} +1 -1
- package/dist/assets/{VerifiedUser-DjH4G4q1.js → VerifiedUser-CPgjTUes.js} +1 -1
- package/dist/assets/{ViewList-Bwe4mYRB.js → ViewList-CEZqTkZN.js} +1 -1
- package/dist/assets/{_createAggregator-ctoSszuV.js → _createAggregator-6qCBlT2m.js} +1 -1
- package/dist/assets/{actions-BIszN-OK.js → actions-CwHV7VOi.js} +1 -1
- package/dist/assets/{actions-D4Kz7IAL.js → actions-Lc_gpmy_.js} +1 -1
- package/dist/assets/{agreement-B39z5WNn.js → agreement-nMH2PwNa.js} +1 -1
- package/dist/assets/api-C4QD0LkR.js +1 -0
- package/dist/assets/{appearance-BRueUKRZ.js → appearance-wME-EwFf.js} +1 -1
- package/dist/assets/{ar-qovKpPcU.js → ar-RVOyZ73G.js} +1 -1
- package/dist/assets/{audit-logs-ZvNCA3Zx.js → audit-logs-DQNniPIc.js} +1 -1
- package/dist/assets/{base-chart-DZ65G0Up.js → base-chart-DfzeqYgM.js} +1 -1
- package/dist/assets/{blocklet-vLRH388n.js → blocklet-CXBJcwmD.js} +1 -1
- package/dist/assets/chain-0epXNZTv.js +6 -0
- package/dist/assets/{click-to-copy-D5YohLRv.js → click-to-copy-CCt7i81W.js} +1 -1
- package/dist/assets/client-BriPpb0D.js +1 -0
- package/dist/assets/cloneDeep-DZJaLQYA.js +1 -0
- package/dist/assets/{collapse-D_6eVE_q.js → collapse-UWItJur2.js} +1 -2
- package/dist/assets/{config-navigation-DXRA92Ph.js → config-navigation-D7hjrTsx.js} +5 -5
- package/dist/assets/connect-to-DUMdqErZ.js +30 -0
- package/dist/assets/{cssMode-IX2WeX_E.js → cssMode-OQuv2wel.js} +1 -1
- package/dist/assets/{de-BrVlvg8I.js → de-BXIXPwxt.js} +1 -1
- package/dist/assets/{delete-confirm-CKWr12s3.js → delete-confirm-i_RblorR.js} +1 -1
- package/dist/assets/{depsEqual-CfdoQRpO.js → depsEqual-CLLXOjvx.js} +1 -1
- package/dist/assets/{detail-BnDNU4xS.js → detail-SmxG2E5W.js} +3 -3
- package/dist/assets/{domains-DbIh7fxa.js → domains-Bxk0d7jT.js} +2 -2
- package/dist/assets/{download-CX5ROtbY.js → download-DtuXp01T.js} +12 -12
- package/dist/assets/{edit.svg-1dKJigcF.js → edit.svg-BhSUheUT.js} +1 -1
- package/dist/assets/emotion-cache.browser.esm-BE8-ertk.js +1 -0
- package/dist/assets/engine-ByaR-FMJ.js +1 -0
- package/dist/assets/{es-CWdREjkO.js → es-DJvu101w.js} +1 -1
- package/dist/assets/{fr-CfM2gAY_.js → fr-D9eGKSnG.js} +1 -1
- package/dist/assets/{freemarker2-Ci6NhYtQ.js → freemarker2-CSRF4Izm.js} +1 -1
- package/dist/assets/{get-safe-url-CVrrblG0.js → get-safe-url-CO9heLC_.js} +1 -1
- package/dist/assets/getValidReactChildren-yMK1JaZz.js +1 -0
- package/dist/assets/{graphqlMode-CUUxEJv4.js → graphqlMode-Y3Syqq4-.js} +2 -2
- package/dist/assets/{handlebars-SXl07VWN.js → handlebars-C5wgXGwl.js} +1 -1
- package/dist/assets/hi-CSHwUi_Z.js +5 -0
- package/dist/assets/{html-f82gCVQF.js → html-_LQ37iNF.js} +1 -1
- package/dist/assets/{html-title-s4xKUvYC.js → html-title-D7IA5_Dw.js} +1 -1
- package/dist/assets/{htmlMode-BQkLubkF.js → htmlMode-CYNIx1xO.js} +1 -1
- package/dist/assets/{id-BfAVuWhm.js → id-Dc-m_i57.js} +1 -1
- package/dist/assets/{iframe-D0ox4iMz.js → iframe-Cmb-t7Zd.js} +1 -1
- package/dist/assets/{index-CDjkuvXP.js → index-50D2VUJd.js} +1 -1
- package/dist/assets/index-5CUDmo0b.js +11 -0
- package/dist/assets/{index-oIdyH1SE.js → index-7iaj_w93.js} +1 -1
- package/dist/assets/{index-BK-A1qdT.js → index-B4Clf5Is.js} +1 -1
- package/dist/assets/{index-Cv8VUnaq.js → index-B4M5fNtl.js} +1 -1
- package/dist/assets/{index-CN0dYmBa.js → index-BEosxyQ-.js} +1 -1
- package/dist/assets/{index-CU3QIJsR.js → index-BOJNvmUd.js} +2 -2
- package/dist/assets/index-BQOJioXe.js +153 -0
- package/dist/assets/{index-DRNAAkse.js → index-BTLRRIeH.js} +9 -9
- package/dist/assets/{index-Dh2uOJnr.js → index-BUYTK_02.js} +1 -1
- package/dist/assets/{index-itvjoWYA.js → index-BZaAN-VG.js} +1 -1
- package/dist/assets/{index-BwEL7b_y.js → index-BmtqDcN9.js} +1 -1
- package/dist/assets/{index-CLdrrNyQ.js → index-Bs51pyjo.js} +1 -1
- package/dist/assets/{index-BiGMKi60.js → index-BxSe45Us.js} +3 -3
- package/dist/assets/{index-CL-6WnAm.js → index-C3GHA9Mq.js} +1 -1
- package/dist/assets/{index-0y0GUu_H.js → index-C7AV4hRT.js} +1 -1
- package/dist/assets/{index-RUTgtMpc.js → index-CAA85gOc.js} +1 -1
- package/dist/assets/{index-B_AzVDZL.js → index-CGgu2xDj.js} +3 -3
- package/dist/assets/index-CMuL6EA4.js +602 -0
- package/dist/assets/{index-vwlVGFIa.js → index-CPZEAvjw.js} +1 -1
- package/dist/assets/index-CR9frGrE.js +1 -0
- package/dist/assets/{index-DSTJqWf2.js → index-CaxSNZzZ.js} +1 -1
- package/dist/assets/{index-DQAon04N.js → index-CqD2fBUt.js} +283 -280
- package/dist/assets/{index-CP6Hc8EC.js → index-CxHR01Rd.js} +3 -3
- package/dist/assets/{index-Dm9VJXIH.js → index-D0H3PjUo.js} +1 -1
- package/dist/assets/{index-BLKRAGfo.js → index-DBwi0mrP.js} +1 -1
- package/dist/assets/{index-DmyIzBGi.js → index-DDWxd2Ux.js} +1 -1
- package/dist/assets/{index-DaeBi0tJ.js → index-DM9qDnRm.js} +1 -1
- package/dist/assets/{index-danRXFlY.js → index-DU2ssP7d.js} +4 -4
- package/dist/assets/{index-jNX_J6BB.js → index-DaPV0E1i.js} +1 -1
- package/dist/assets/{index-BRHUKEe0.js → index-DhjgCBSh.js} +1 -1
- package/dist/assets/{index-C5EipBB6.js → index-DpQcmMsP.js} +1 -1
- package/dist/assets/{index-rTbI0lkb.js → index-DuvpHuQS.js} +1 -1
- package/dist/assets/{index-DdGrP93n.js → index-DxXsj_BT.js} +1 -1
- package/dist/assets/{index-DjP4YyEm.js → index-DyXybTnU.js} +1 -1
- package/dist/assets/{index-BHmKNTQs.js → index-KVQaYJ5Y.js} +1 -1
- package/dist/assets/{index-DxaoKSdL.js → index-OepyDXYU.js} +1 -1
- package/dist/assets/{index-CqjImXJn.js → index-S1_KC8Yl.js} +1 -1
- package/dist/assets/{index-D3La8IYq.js → index-TFXeoKpv.js} +1 -1
- package/dist/assets/{index-DuC1UwU8.js → index-ZZeybSqq.js} +1 -1
- package/dist/assets/{index-C7WxFtB9.js → index-aZuZZsqe.js} +1 -1
- package/dist/assets/{index-DmfWG7ck.js → index-hHL_v0H9.js} +2 -2
- package/dist/assets/{index-1LmYeNoL.js → index-kAJasXw_.js} +1 -1
- package/dist/assets/{index-CPEKV9ZW.js → index-pskT-PqN.js} +2 -2
- package/dist/assets/{index-Dz-lyfj_.js → index-qOevQjkj.js} +1 -1
- package/dist/assets/{index.esm-BIUDl4l6.js → index.esm-0YKGK8i_.js} +1 -1
- package/dist/assets/{install-from-url-DeNQZMpF.js → install-from-url-xkTAZofh.js} +1 -1
- package/dist/assets/{invitation-COCb5On_.js → invitation-COGTm43o.js} +1 -1
- package/dist/assets/{is-path-prefix-equal-N7tEpQVO.js → is-path-prefix-equal-8gdmSIzT.js} +1 -1
- package/dist/assets/{item-BeOwNcih.js → item-DVoxQKtM.js} +1 -1
- package/dist/assets/{ja-616mK6Bu.js → ja-DuWRl1OM.js} +1 -1
- package/dist/assets/{javascript-Db-35yxg.js → javascript-9DHIuu8w.js} +1 -1
- package/dist/assets/{jsonMode-CrQKwuqp.js → jsonMode-DrQT0Rrg.js} +1 -1
- package/dist/assets/{ko-CoUjs_Gj.js → ko-YalU3HfD.js} +1 -1
- package/dist/assets/{liquid-DJMO6cZA.js → liquid-1g4gJZY5.js} +1 -1
- package/dist/assets/{list-header-CYEe-lQ7.js → list-header-CNhWtGQP.js} +1 -1
- package/dist/assets/{log-DWlTkDeY.js → log-Cv5rHloz.js} +1 -1
- package/dist/assets/{lottie-react.esm-BcFfDY7I.js → lottie-react.esm-C6YuAEWV.js} +1 -1
- package/dist/assets/{mdx-D6XejU-T.js → mdx-B-cv_j71.js} +1 -1
- package/dist/assets/{memory-Di9F3qs2.js → memory-DPkaeOl7.js} +1 -1
- package/dist/assets/{metric-Rsw_68TX.js → metric-CiNgShR5.js} +1 -1
- package/dist/assets/omit-C5UyCO0S.js +1 -0
- package/dist/assets/{overview-D38nD9i7.js → overview-BA5biw-O.js} +1 -1
- package/dist/assets/{permission-BIUOpX2u.js → permission-DZQgH-wh.js} +1 -1
- package/dist/assets/{preference-DSmHq1w5.js → preference-auzdU7Dy.js} +3 -3
- package/dist/assets/pt-B3IRBzK6.js +5 -0
- package/dist/assets/{python-Dqyd2Hsi.js → python-tC148uh2.js} +1 -1
- package/dist/assets/{raf-schd.esm-BGXncqYB.js → raf-schd.esm-2IIbMYWO.js} +1 -1
- package/dist/assets/{razor-CdzgmOZv.js → razor-DOE4a2El.js} +1 -1
- package/dist/assets/{rotate-session-key-95XBCkHR.js → rotate-session-key-Bdv8tRY6.js} +1 -1
- package/dist/assets/ru-BEEcST35.js +5 -0
- package/dist/assets/{runtime-D7lqaXvd.js → runtime-CQbc5vgt.js} +1 -1
- package/dist/assets/schema-ObohfjTu.js +1 -0
- package/dist/assets/sdk-Yo848YWX.js +1 -0
- package/dist/assets/{service-DBfnpgzT.js → service-mTfNIC7m.js} +1 -1
- package/dist/assets/{shorten-label-BwqBgwTL.js → shorten-label-B8e0Bk0t.js} +1 -1
- package/dist/assets/{simple-select-DQnMwaJg.js → simple-select-IWkCsCtv.js} +1 -1
- package/dist/assets/{spaces-DpCJGUwf.js → spaces-DrkRFkPj.js} +1 -1
- package/dist/assets/{status-DGosxj_C.js → status-BaKGKdEv.js} +1 -1
- package/dist/assets/{status-C0x1F2hB.js → status-L8y4a0he.js} +1 -1
- package/dist/assets/{switch-control-DJmzxMX-.js → switch-control-DzVAWrsU.js} +1 -1
- package/dist/assets/{table-icons-CjbBCbkG.js → table-icons-CzZoaBLP.js} +1 -1
- package/dist/assets/{team-CapU231S.js → team-upwNpr8j.js} +1 -1
- package/dist/assets/th-DYSyn_pj.js +5 -0
- package/dist/assets/{toLower-YESHqG1W.js → toLower-By3wiYQ5.js} +1 -1
- package/dist/assets/toUpper-WFb-_EjO.js +1 -0
- package/dist/assets/{traffic-DS6Iezpg.js → traffic-oApG71Gy.js} +1 -1
- package/dist/assets/{tsMode-QBKsv_MH.js → tsMode-3JYy3Rny.js} +1 -1
- package/dist/assets/{typescript-2FQtO0Jn.js → typescript-BpFSqCb2.js} +1 -1
- package/dist/assets/{url-evaluation-LJajQhtP.js → url-evaluation-CboxDo9a.js} +1 -1
- package/dist/assets/{url-join-D0FvPMVn.js → url-join-4f83ALpx.js} +1 -1
- package/dist/assets/{use-mobile-BuUEnGf6.js → use-mobile-ByGodlLU.js} +1 -1
- package/dist/assets/{use-mobile-B5hY0d0u.js → use-mobile-DHBy85Ov.js} +1 -1
- package/dist/assets/{useAsync-BRnzfjB4.js → useAsync-DAJnGdBq.js} +1 -1
- package/dist/assets/{useAsyncRetry-B5zkihuo.js → useAsyncRetry-BFx8IbqU.js} +1 -1
- package/dist/assets/{useLocalStorage-DAbLYpB1.js → useLocalStorage-4sgI3E92.js} +1 -1
- package/dist/assets/{useThemeProps-iUKmymVW.js → useThemeProps-ATydoH1u.js} +1 -1
- package/dist/assets/{util-BSKUyUc4.js → util-DH4frn9i.js} +1 -1
- package/dist/assets/vi-BvKqvojn.js +5 -0
- package/dist/assets/{wait-container-DAVQIB8x.js → wait-container-CJvrIzPn.js} +1 -1
- package/dist/assets/{without-wallet-BlI613tw.js → without-wallet-BxHS9HA2.js} +1 -1
- package/dist/assets/wrap-locale-C7k7RLj9.js +1 -0
- package/dist/assets/{xml--DZQiP49.js → xml-9s8DQRAB.js} +1 -1
- package/dist/assets/{yaml-DF8yZtH2.js → yaml-D0a0z0M-.js} +1 -1
- package/dist/assets/zh-BaEjqGHy.js +10 -0
- package/dist/assets/{zh-tw-DK_EuRfN.js → zh-tw-xcyHbP3V.js} +2 -2
- package/dist/index.html +1 -1
- package/dist/service-worker.js +1 -1
- package/package.json +1 -1
- package/dist/assets/ArrowDropDown-IcntJnxN.js +0 -1
- package/dist/assets/api-BPsZ_jNB.js +0 -1
- package/dist/assets/chain-DS4Hjfmr.js +0 -6
- package/dist/assets/client-bjR3BWE3.js +0 -1
- package/dist/assets/cloneDeep-CNxnXGqe.js +0 -1
- package/dist/assets/connect-to-lgGqqqWV.js +0 -29
- package/dist/assets/download-1sZ_L4eJ.css +0 -32
- package/dist/assets/emotion-cache.browser.esm-BkCEErJn.js +0 -1
- package/dist/assets/engine-O4HpK5Dx.js +0 -1
- package/dist/assets/getValidReactChildren-DJQKILMh.js +0 -1
- package/dist/assets/hi-B6hnXdBn.js +0 -5
- package/dist/assets/index-BhRNr1Mm.js +0 -602
- package/dist/assets/index-ByZBUOEV.js +0 -11
- package/dist/assets/index-DOh613-F.js +0 -153
- package/dist/assets/index-Mwj3mzuq.js +0 -1
- package/dist/assets/omit-DAMRcdLY.js +0 -1
- package/dist/assets/pt-BjllWaWg.js +0 -5
- package/dist/assets/ru-XKA9Zu_7.js +0 -5
- package/dist/assets/schema-CJDApxAh.js +0 -1
- package/dist/assets/sdk-DXw8dY2Q.js +0 -1
- package/dist/assets/th-C_39WNhc.js +0 -5
- package/dist/assets/toUpper-DxP9R-Bl.js +0 -1
- package/dist/assets/vi-B8pz6rul.js +0 -5
- package/dist/assets/wrap-locale-DcxOTLb-.js +0 -1
- package/dist/assets/zh-Dr_3RhGJ.js +0 -10
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
import{aG as de,j as e,hd as Ps,he as Ts,bL as Is,r as L,s as ve,N as A,f4 as wt,t as U,eN as ht,a4 as ne,C as Ie,bi as zt,dK as Es,o as T,hf as Ds,b2 as Ht,cw as Ls,cP as qs,dn as Ms,T as J,dF as at,bn as re,bz as ft,g as ue,hg as zs,bA as mt,b as se,bg as ee,dH as Y,H as Z,aV as ie,m as ae,n as Bt,q as Hs,w as Ft,ad as Bs,J as Nt,g7 as Fs,hh as Ns,au as Zs,aU as K,V as Te,$ as ke,D as Vs,X as Us,v as te,Y as it,hi as Ws,hj as Js,ez as Ks,eB as Gs,I as je,E as W,hk as Ys,cX as kt,W as Xs,fp as Zt,az as X,aR as St,hl as Qs,fc as Re,cr as E,by as ge,aE as Q,Q as G,aP as ye,hm as qe,a2 as er,hn as Je,c2 as Ce,eC as tr,ho as sr,dG as ce,f as $e,y as Vt,bv as ot,O as rr,cD as Ut,g6 as nr,fL as Ze,hp as ar,b9 as ir,L as or,cq as ze,aK as Be,hq as lr,U as cr,ag as Ct,a3 as Wt,bj as Fe,hr as Jt,b6 as dr,gw as we,fd as Kt,cV as Gt,B as ur,b5 as Rt,fe as hr,fj as fr,G as Ke,M as mr,bt as pr}from"./index-DQAon04N.js";import{F as gr,a as yr,s as vr,L as _e,S as xr,B as br}from"./preference-DSmHq1w5.js";import{N as $t}from"./ChevronRight-B_f9hb86.js";import{T as Ne}from"./html-title-s4xKUvYC.js";import{w as Ee,P as jr}from"./permission-BIUOpX2u.js";import{u as pt}from"./index-Mwj3mzuq.js";import{D as _r}from"./Done-BrXgYrm-.js";import{R as wr,S as M}from"./collapse-D_6eVE_q.js";import{A as kr,a as At}from"./Autocomplete-BaEPlYLx.js";import{C as Sr,R as Cr,P as Rr}from"./rotate-session-key-95XBCkHR.js";import{u as oe}from"./blocklet-vLRH388n.js";import{C as $r}from"./click-to-copy-D5YohLRv.js";import{u as Ve}from"./team-CapU231S.js";import{v as Yt}from"./index-CDjkuvXP.js";import{g as Ar}from"./chain-DS4Hjfmr.js";import{V as Or,d as Pr}from"./status-DGosxj_C.js";import{S as pe}from"./Switch-CEsPeHy7.js";import{B as Tr}from"./index-0y0GUu_H.js";import{y as Ir}from"./index-DmfWG7ck.js";import{I as Er,J as Dr,K as Lr,L as qr}from"./index-CN0dYmBa.js";import{u as xe,C as H,b as Ot}from"./index.esm-BIUDl4l6.js";import{S as He,u as Mr}from"./switch-control-DJmzxMX-.js";import{D as Pt,R as Xt,a as Qt}from"./url-evaluation-LJajQhtP.js";import{A as Tt}from"./Add-S-3I84b8.js";import{S as zr}from"./Slider-DMeR2md5.js";import{H as Ue}from"./index-1LmYeNoL.js";import{l as Hr}from"./index-CL-6WnAm.js";import{u as es}from"./use-mobile-BuUEnGf6.js";import{S as Ge}from"./simple-select-DQnMwaJg.js";import{G as Br}from"./actions-D4Kz7IAL.js";import{C as Fr}from"./CardContent-F-Sbai2s.js";import"./omit-DAMRcdLY.js";import"./index-C7WxFtB9.js";import"./edit.svg-1dKJigcF.js";import"./ArrowDropDown-IcntJnxN.js";import"./ButtonGroup-Bb6jDsD1.js";import"./getValidReactChildren-DJQKILMh.js";import"./index-D3La8IYq.js";import"./iframe-D0ox4iMz.js";import"./ListSubheader-YCstldBv.js";import"./ErrorOutline-cbP6hbrl.js";import"./redux-DfszZyTl.js";import"./typeof-QjJsDpFa.js";import"./visuallyHidden-Dan1xhjv.js";import"./FilterList-CETwaOot.js";import"./CSSTransition-wxeeFOKf.js";import"./emotion-cache.browser.esm-BkCEErJn.js";import"./depsEqual-CfdoQRpO.js";import"./TableSearch-Lg4M-8KA.js";import"./Search-hhDB6YL9.js";import"./Clear-v5WhrN0k.js";import"./MoreVert-C716pe1M.js";import"./useLocalStorage-DAbLYpB1.js";import"./get-safe-url-CVrrblG0.js";const ts=de([e.jsx("path",{d:"M21 7.28V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-2.28c.59-.35 1-.98 1-1.72V9c0-.74-.41-1.37-1-1.72M20 9v6h-7V9zM5 19V5h14v2h-6c-1.1 0-2 .9-2 2v6c0 1.1.9 2 2 2h6v2z"},"0"),e.jsx("circle",{cx:"16",cy:"12",r:"1.5"},"1")]),Nr=de([e.jsx("path",{d:"M19 5v14H5V5zm0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2"},"0"),e.jsx("path",{d:"M14 17H7v-2h7zm3-4H7v-2h10zm0-4H7V7h10z"},"1")]),Zr=de(e.jsx("path",{d:"M21 8V7l-3 2-3-2v1l3 2zm1-5H2C.9 3 0 3.9 0 5v14c0 1.1.9 2 2 2h20c1.1 0 1.99-.9 1.99-2L24 5c0-1.1-.9-2-2-2M8 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3m6 12H2v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1zm8-6h-8V6h8z"})),Vr=de(e.jsx("path",{d:"M24 9v2h-6V9zM8 4C5.79 4 4 5.79 4 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4m0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4m4.51-8.95C13.43 5.11 14 6.49 14 8s-.57 2.89-1.49 3.95C14.47 11.7 16 10.04 16 8s-1.53-3.7-3.49-3.95m4.02 9.78C17.42 14.66 18 15.7 18 17v3h2v-3c0-1.45-1.59-2.51-3.47-3.17"})),Ur=de(e.jsx("path",{d:"M21 10h-8.35C11.83 7.67 9.61 6 7 6c-3.31 0-6 2.69-6 6s2.69 6 6 6c2.61 0 4.83-1.67 5.65-4H13l2 2 2-2 2 2 4-4.04zM7 15c-1.65 0-3-1.35-3-3s1.35-3 3-3 3 1.35 3 3-1.35 3-3 3"})),Wr=de(e.jsx("path",{d:"M21 10h-8.35C11.83 7.67 9.61 6 7 6c-3.31 0-6 2.69-6 6s2.69 6 6 6c2.61 0 4.83-1.67 5.65-4H13l2 2 2-2 2 2 4-4.04zM7 15c-1.65 0-3-1.35-3-3s1.35-3 3-3 3 1.35 3 3-1.35 3-3 3"})),lt=de(e.jsx("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2m-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2m3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1s3.1 1.39 3.1 3.1z"})),Jr=de([e.jsx("path",{d:"M18 11c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.79-1.13-1.26-2.51-1.26-4 0-3.87 3.13-7 7-7M8.9 6c0-1.71 1.39-3.1 3.1-3.1s3.1 1.39 3.1 3.1v2H8.9z"},"0"),e.jsx("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5m0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5m0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32"},"1")]),Kr=de(e.jsx("path",{d:"M11 7 9.6 8.4l2.6 2.6H2v2h10.2l-2.6 2.6L11 17l5-5zm9 12h-8v2h8c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-8v2h8z"})),Gr=de(e.jsx("path",{d:"M12 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2m6-6v-5c0-3.07-1.63-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.64 5.36 6 7.92 6 11v5l-2 2v1h16v-1zm-2 1H8v-6c0-2.48 1.51-4.5 4-4.5s4 2.02 4 4.5z"})),ss=de(e.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2m4.24 16L12 15.45 7.77 18l1.12-4.81-3.73-3.23 4.92-.42L12 5l1.92 4.53 4.92.42-3.73 3.23z"})),Yr=de(e.jsx("path",{d:"M3 18c0 .55.45 1 1 1h5v-2H4c-.55 0-1 .45-1 1M3 6c0 .55.45 1 1 1h9V5H4c-.55 0-1 .45-1 1m10 14v-1h7c.55 0 1-.45 1-1s-.45-1-1-1h-7v-1c0-.55-.45-1-1-1s-1 .45-1 1v4c0 .55.45 1 1 1s1-.45 1-1M7 10v1H4c-.55 0-1 .45-1 1s.45 1 1 1h3v1c0 .55.45 1 1 1s1-.45 1-1v-4c0-.55-.45-1-1-1s-1 .45-1 1m14 2c0-.55-.45-1-1-1h-9v2h9c.55 0 1-.45 1-1m-5-3c.55 0 1-.45 1-1V7h3c.55 0 1-.45 1-1s-.45-1-1-1h-3V4c0-.55-.45-1-1-1s-1 .45-1 1v4c0 .55.45 1 1 1"})),Xr=de(e.jsx("path",{d:"M16 13c3.09-2.81 6-5.44 6-7.7C22 3.45 20.55 2 18.7 2c-1.04 0-2.05.49-2.7 1.25C15.34 2.49 14.34 2 13.3 2 11.45 2 10 3.45 10 5.3c0 2.26 2.91 4.89 6 7.7m-2.7-9c.44 0 .89.21 1.18.55L16 6.34l1.52-1.79c.29-.34.74-.55 1.18-.55.74 0 1.3.56 1.3 1.3 0 1.12-2.04 3.17-4 4.99-1.96-1.82-4-3.88-4-4.99 0-.74.56-1.3 1.3-1.3M19 16h-2c0-1.2-.75-2.28-1.87-2.7L8.97 11H1v11h6v-1.44l7 1.94 8-2.5v-1c0-1.66-1.34-3-3-3M3 20v-7h2v7zm10.97.41L7 18.48V13h1.61l5.82 2.17c.34.13.57.46.57.83 0 0-1.99-.05-2.3-.15l-2.38-.79-.63 1.9 2.38.79c.51.17 1.04.26 1.58.26H19c.39 0 .74.23.9.56z"}));var Qr=Array.prototype,It=Qr.splice;function en(x,C,$,R){var _=Ts,b=-1,m=C.length,r=x;for(x===C&&(C=Ps(C));++b<m;)for(var p=0,f=C[b],h=f;(p=_(r,h,p))>-1;)r!==x&&It.call(r,p,1),It.call(x,p,1);return x}function tn(x,C){return x&&x.length&&C&&C.length?en(x,C):x}var sn=Is(tn);const rn={width:24,height:24,body:'<path fill="currentColor" d="M4.975 15q-.425 0-.7-.288T4 14q0-.425.288-.713T5 13h14.025q.425 0 .7.288T20 14q0 .425-.288.713T19 15H4.975Zm0 4q-.425 0-.7-.288T4 18q0-.425.288-.713T5 17h14.025q.425 0 .7.288T20 18q0 .425-.288.713T19 19H4.975Zm0-8q-.425 0-.7-.288T4 10q0-.425.288-.713T5 9h14.025q.425 0 .7.288T20 10q0 .425-.288.713T19 11H4.975Zm0-4q-.425 0-.7-.288T4 6q0-.425.288-.713T5 5h14.025q.425 0 .7.288T20 6q0 .425-.288.713T19 7H4.975Z"/>'};function rs({label:x="",disabled:C=!1,required:$=!1,initialValue:R="",onChange:_=()=>{},style:b={},onSubmit:m=()=>{},triggers:r=[],options:p=[],formatterBeforeSubmit:f=a=>a.join(","),helperText:h="",placeholder:t="",renderImage:l=()=>null,renderLabel:o=()=>"",filterKeys:n=["name"],noEmpty:s=!1,...c}){const[a,i]=L.useState(!1),[u,g]=L.useState(!1),[y,k]=L.useState(""),w=L.useRef(null),[d,v]=L.useState(R),[j,S]=L.useState(d),O=L.useMemo(()=>{if(!p)return{};const q={};return p.forEach(z=>{q[z.code]=z}),q},[p]),P=()=>{if(!p)return[];if(!y)return p.map(z=>z.code);const q=new RegExp(y.toLowerCase());return p.filter(z=>{for(let F=0;F<n.length;F++){const V=n[F];if(q.test(z[V]?.toLowerCase()))return!0}return!1}).map(z=>z.code)},D=async()=>{g(!0);try{await m(typeof f=="function"?f(j):j)===!1?S(d):s&&!j.length?(S(R),v(R)):(S(j),v(j))}catch{S(d)}finally{g(!1),i(!1)}},I=(q,z)=>{if(!Array.isArray(z)){S([]),_([]);return}const F=z.filter(V=>O[V]);if(!F.length){S([]),_([]);return}S(F),_(F)},B=q=>{q.stopPropagation(),i(!0),setTimeout(()=>{if(w.current){const z=w.current.querySelector("input");z&&z.focus()}},500)},N=a?e.jsx(kr,{ref:w,options:p,value:j,onChange:I,inputValue:y,onInputChange:(q,z)=>{k(z)},fullWidth:!0,multiple:!0,variant:"outlined",margin:"dense",filterOptions:P,getOptionLabel:q=>O[q]?.name,renderInput:q=>e.jsx(U,{...q,label:"",placeholder:t}),renderOption:(q,z)=>{const F=j.indexOf(z)!==-1;return L.createElement(nn,{component:"li",...q,key:z},l(O[z]||{}),e.jsx(A,{sx:{"& > img":{mr:2,flexShrink:0}},style:{flex:1,fontWeight:F?"700":"normal"},children:o(z,O[z])||O[z]?.name}),e.jsx(A,{component:wt,sx:{opacity:.5,width:18,height:18},style:{visibility:F?"visible":"hidden"}}))},...c,slots:{popper:an}}):e.jsx(A,{className:"form-item-input slot",onClick:B,style:{whiteSpace:"pre-wrap",cursor:"text"},sx:{px:1},children:j.filter(q=>p.some(z=>z.code===q)).map(q=>e.jsx(ht,{label:p.find(z=>z.code===q).name,style:{marginRight:8},size:"small"},q))});return e.jsx(gr,{className:"form",style:b,children:e.jsxs(A,{className:"form-item",children:[e.jsxs(A,{className:"form-item-label",children:[x,$&&e.jsx(wr,{})]}),e.jsxs(A,{className:"form-item-body",children:[e.jsx(A,{className:"form-item-input",children:N}),a?e.jsx(A,{className:"form-item-action",children:e.jsxs(e.Fragment,{children:[e.jsx(ne,{"data-cy":"schema-form-item-confirm",onClick:D,disabled:C||u,size:"large",children:u?e.jsx(Ie,{size:24}):e.jsx(_r,{})}),e.jsx(ne,{"data-cy":"schema-form-item-cancel",onClick:()=>{S(d),i(!1)},disabled:C||u,size:"large",children:e.jsx(wt,{})})]})}):null]}),a&&h&&e.jsx(zt,{children:h})]})})}rs.propTypes={style:T.object,onSubmit:T.func,onChange:T.func,label:T.string,initialValue:T.string,required:T.bool,disabled:T.bool,triggers:T.array,options:T.array,helperText:T.string,formatterBeforeSubmit:T.func,placeholder:T.string,renderImage:T.func,filterKeys:T.arrayOf(T.string),noEmpty:T.bool,renderLabel:T.func};const nn=ve.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
justify-content: space-between;
|
|
4
|
-
align-items: center;
|
|
5
|
-
height: 48px;
|
|
6
|
-
border-bottom: 1px solid rgba(0, 0, 0, 0.08);
|
|
7
|
-
font-size: 1.1em;
|
|
8
|
-
`,an=ve(Es)(()=>({[`& .${At.paper}`]:{boxShadow:"0px 8px 12px rgba(92, 92, 92, 0.04), 0px -10px 12px rgba(92, 92, 92, 0.04)",borderRadius:"6px",width:"100%",border:"1px solid rgba(0, 0, 0, 0.12)",color:"inherit",fontSize:13,position:"absolute",left:0,top:0},[`& .${At.listbox}`]:{padding:0}}));function ct({name:x,icon:C,did:$,dark:R=!1}){return e.jsx(Ds,{prefer:R?"dark":"light",children:e.jsx(A,{sx:{display:"flex",justifyContent:"center",alignItems:"center",bgcolor:R?"common.black":"info.main",pl:4,borderRadius:1,overflow:"hidden",height:1},children:e.jsxs(Ht,{sx:{display:"flex",alignItems:"center",p:1.5,width:1,borderRadius:"8px 0 0 8px"},children:[e.jsx(Ls,{sx:{bgcolor:"transparent",width:48,height:48,borderRadius:1},children:C?e.jsx(qs,{src:C,alt:"icon",style:{width:48,height:48,borderRadius:"8px"}}):e.jsx(Ms,{variant:"rectangular",width:48,height:48,sx:{borderRadius:1}})}),e.jsxs(A,{sx:{ml:1,flex:1,width:0,overflow:"hidden"},children:[e.jsx(J,{sx:{fontSize:20,fontWeight:500,color:"text.primary",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:x}),e.jsx(at,{did:$,inline:!0,size:13})]})]})})})}ct.propTypes={name:T.string.isRequired,icon:T.string.isRequired,did:T.string.isRequired,dark:T.bool};var ns=function(C){return e.jsxs("svg",{...C,children:[e.jsxs("g",{clipPath:"url(#a)",children:[e.jsx("path",{fill:"color(display-p3 .1255 .3333 .898)",d:"M0 0h384v216H0z"}),e.jsxs("g",{filter:"url(#b)",children:[e.jsx("rect",{width:"1600",height:"887.778",x:"32",y:"32",fill:"#fff",rx:"12",shapeRendering:"crispEdges"}),e.jsxs("g",{clipPath:"url(#c)",children:[e.jsx("path",{fill:"color(display-p3 .8745 .8824 .898)",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"55.333",y:"49.778",fill:"color(display-p3 .9255 .4196 .3686)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"77.556",y:"49.778",fill:"color(display-p3 .9569 .749 .3098)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"99.778",y:"49.778",fill:"color(display-p3 .3804 .7686 .3255)",rx:"6.667"}),e.jsxs("g",{clipPath:"url(#d)",children:[e.jsx("path",{fill:"#fff",d:"M128.667 49.778a8.888 8.888 0 0 1 8.889-8.89h248.888c4.91 0 8.889 3.98 8.889 8.89v28.889H128.667v-28.89Z"}),e.jsx("path",{stroke:"color(display-p3 .2392 .251 .2627)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"m374.222 56.444 3.334 3.334m0 0 3.333-3.334m-3.333 3.334-3.334 3.333m3.334-3.333 3.333 3.333"}),e.jsx("rect",{width:"180",height:"18",x:"140",y:"51",fill:"color(display-p3 .8745 .8824 .898)",rx:"4"})]})]}),e.jsx("path",{fill:"#fff",d:"M32 78.667h1600v40H32z"}),e.jsx("path",{stroke:"color(display-p3 .3765 .3882 .4039)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"M63.111 98.667H49.778m0 0L56.444 92m-6.666 6.667 6.666 6.666m28.889-6.666h13.334m0 0L92 92m6.667 6.667L92 105.333"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",fillRule:"evenodd",d:"M122.278 98.667a5.278 5.278 0 0 1 9.524-3.136l-2.024 2.024h5.555V92l-2.343 2.343a6.944 6.944 0 1 0 .752 7.48.834.834 0 0 0-1.484-.758 5.278 5.278 0 0 1-9.98-2.398Z",clipRule:"evenodd"}),e.jsx("rect",{width:"1360",height:"31.111",x:"152",y:"83.111",fill:"color(display-p3 .9451 .9529 .9569)",rx:"15.556"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",fillRule:"evenodd",d:"M172 93.111a2.778 2.778 0 0 0-2.778 2.778V97h-.555a1.11 1.11 0 0 0-1.111 1.111v5.556c0 .613.497 1.111 1.111 1.111h6.666c.614 0 1.111-.498 1.111-1.111v-5.556A1.11 1.11 0 0 0 175.333 97h-.555v-1.111A2.778 2.778 0 0 0 172 93.11ZM173.667 97v-1.111a1.667 1.667 0 0 0-3.334 0V97h3.334Z",clipRule:"evenodd"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",d:"M195.695 102.373v-4.231c0-.324-.066-.605-.198-.843a1.29 1.29 0 0 0-.577-.562c-.258-.132-.577-.198-.957-.198-.355 0-.666.061-.934.183a1.624 1.624 0 0 0-.623.478 1.05 1.05 0 0 0-.221.638h-1.405c0-.293.076-.585.228-.873.152-.289.37-.55.653-.783a3.271 3.271 0 0 1 1.033-.562 4.072 4.072 0 0 1 1.352-.212c.598 0 1.125.1 1.58.303.461.203.821.51 1.079.92.263.405.395.913.395 1.526v3.828c0 .274.023.565.068.874.051.309.124.575.22.797v.122h-1.466a2.684 2.684 0 0 1-.167-.646 5.26 5.26 0 0 1-.06-.759Zm.243-3.578.015.988h-1.421c-.4 0-.757.032-1.07.098a2.463 2.463 0 0 0-.79.281 1.34 1.34 0 0 0-.487.479 1.273 1.273 0 0 0-.167.661c0 .258.059.493.175.706.117.213.291.382.524.509.238.122.529.182.874.182a2.357 2.357 0 0 0 1.921-.942c.198-.263.304-.519.319-.767l.6.676a2.034 2.034 0 0 1-.288.707 3.402 3.402 0 0 1-1.557 1.329 3.02 3.02 0 0 1-1.2.228c-.557 0-1.046-.109-1.466-.327a2.51 2.51 0 0 1-.973-.873 2.322 2.322 0 0 1-.341-1.238c0-.441.086-.828.258-1.163.172-.339.42-.62.744-.843.324-.228.714-.4 1.17-.516a6.173 6.173 0 0 1 1.527-.175h1.633Zm4.777-1.944v6.927h-1.405v-8.219h1.367l.038 1.292Zm2.567-1.337-.007 1.306a2.035 2.035 0 0 0-.334-.045 3.579 3.579 0 0 0-.35-.015c-.324 0-.61.05-.858.151a1.777 1.777 0 0 0-.63.426c-.173.182-.309.4-.411.653a3.132 3.132 0 0 0-.189.82l-.395.228c0-.496.048-.962.144-1.397.101-.436.256-.82.463-1.155.208-.34.471-.602.79-.79.324-.192.709-.288 1.155-.288.101 0 .217.012.349.038.132.02.223.043.273.068Zm4.436 7.261c.334 0 .643-.068.927-.205.283-.137.516-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.372 3.372 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.618 0-1.157-.109-1.618-.327a3.213 3.213 0 0 1-1.139-.896 3.998 3.998 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564a3.99 3.99 0 0 1 .676-1.314c.304-.38.684-.679 1.139-.897.461-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395.481.258.859.612 1.132 1.063.279.445.431.952.456 1.519h-1.337a2.01 2.01 0 0 0-.289-.919 1.794 1.794 0 0 0-.668-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.898 1.898 0 0 0-.691.684c-.167.283-.289.6-.365.95a5.214 5.214 0 0 0-.106 1.055v.32c0 .359.035.713.106 1.063.071.349.19.665.357.949.172.284.403.511.691.684.294.167.659.25 1.094.25Zm4.846-10.664h1.413v10.072l-.122 1.595h-1.291V92.111Zm6.965 7.49v.159c0 .597-.071 1.152-.212 1.663-.142.507-.35.947-.623 1.322a2.897 2.897 0 0 1-1.003.873c-.395.208-.848.312-1.359.312-.522 0-.98-.089-1.375-.266a2.707 2.707 0 0 1-.988-.782 4.064 4.064 0 0 1-.645-1.231 7.769 7.769 0 0 1-.327-1.625v-.7c.061-.607.17-1.151.327-1.632a4.05 4.05 0 0 1 .645-1.23 2.6 2.6 0 0 1 .988-.783c.39-.182.843-.273 1.359-.273.517 0 .975.1 1.375.303.4.198.734.481 1.003.851a4 4 0 0 1 .623 1.33c.141.51.212 1.08.212 1.708Zm-1.413.159v-.16c0-.41-.038-.795-.113-1.154a2.993 2.993 0 0 0-.365-.957 1.81 1.81 0 0 0-.661-.653c-.273-.162-.61-.243-1.01-.243-.355 0-.663.06-.927.182a2.014 2.014 0 0 0-.661.493 2.64 2.64 0 0 0-.448.7 3.993 3.993 0 0 0-.25.804v1.831c.081.354.212.696.395 1.025.187.324.435.59.744.798.314.207.701.311 1.162.311.38 0 .704-.076.972-.228.274-.157.494-.372.661-.645.172-.274.299-.59.38-.95.081-.359.121-.744.121-1.154Zm4.717-7.649v11.667h-1.412V92.111h1.412Zm1.884 7.649v-.175c0-.592.086-1.142.258-1.648a3.9 3.9 0 0 1 .745-1.33c.324-.38.716-.673 1.177-.88a3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.549.312a3.747 3.747 0 0 1-1.558-.312 3.513 3.513 0 0 1-1.184-.881 4.002 4.002 0 0 1-.745-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.026.235.384 0 .721-.078 1.01-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.017.243a2.189 2.189 0 0 0-.73.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm11.127 3.19c.335 0 .644-.068.927-.205.284-.137.517-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.363 3.363 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.617 0-1.157-.109-1.617-.327a3.208 3.208 0 0 1-1.14-.896 4.017 4.017 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564.152-.497.378-.935.676-1.314a3.21 3.21 0 0 1 1.14-.897c.46-.218 1-.326 1.617-.326.644 0 1.206.131 1.687.395a2.89 2.89 0 0 1 1.131 1.063c.279.445.431.952.456 1.519h-1.337a2.02 2.02 0 0 0-.288-.919 1.797 1.797 0 0 0-.669-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.906 1.906 0 0 0-.691.684c-.167.283-.288.6-.364.95a5.214 5.214 0 0 0-.107 1.055v.32c0 .359.036.713.107 1.063.07.349.189.665.357.949.172.284.402.511.691.684.293.167.658.25 1.093.25Zm6.267-10.664v11.667h-1.413V92.111h1.413Zm5.02 3.448-3.585 3.836-2.005 2.081-.114-1.496 1.436-1.717 2.552-2.704h1.716Zm-1.283 8.219-2.932-3.92.729-1.253 3.859 5.173h-1.656Zm2.757-.745a.86.86 0 0 1 .22-.6c.152-.167.37-.25.653-.25.284 0 .499.083.646.25a.844.844 0 0 1 .228.6.835.835 0 0 1-.228.593c-.147.162-.362.243-.646.243-.283 0-.501-.081-.653-.243a.85.85 0 0 1-.22-.593Zm7.368-.258c.334 0 .643-.068.926-.205.284-.137.517-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.363 3.363 0 0 1-1.177 1.01c-.486.253-1.02.38-1.602.38-.618 0-1.158-.109-1.618-.327a3.208 3.208 0 0 1-1.14-.896 4.017 4.017 0 0 1-.676-1.307 5.54 5.54 0 0 1-.22-1.572v-.319c0-.552.074-1.073.22-1.564.152-.497.378-.935.676-1.314a3.21 3.21 0 0 1 1.14-.897c.46-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395a2.89 2.89 0 0 1 1.131 1.063c.279.445.431.952.456 1.519h-1.337a2.02 2.02 0 0 0-.288-.919 1.797 1.797 0 0 0-.669-.653 1.866 1.866 0 0 0-.979-.25c-.431 0-.793.085-1.087.257a1.906 1.906 0 0 0-.691.684c-.167.283-.288.6-.364.95a5.214 5.214 0 0 0-.107 1.055v.32c0 .359.036.713.107 1.063.07.349.189.665.357.949.172.284.402.511.691.684.293.167.658.25 1.094.25Zm4.481-3.015v-.175c0-.592.086-1.142.258-1.648.172-.511.42-.955.744-1.33a3.33 3.33 0 0 1 1.178-.88 3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.55.312a3.745 3.745 0 0 1-1.557-.312 3.527 3.527 0 0 1-1.185-.881 4.017 4.017 0 0 1-.744-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.025.235.385 0 .722-.078 1.011-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.018.243a2.195 2.195 0 0 0-.729.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm9.236-2.392v6.585h-1.413v-8.219h1.337l.076 1.633Zm-.288 2.164-.654-.022a5.603 5.603 0 0 1 .221-1.558c.141-.48.351-.898.63-1.253a2.793 2.793 0 0 1 1.041-.82c.415-.198.896-.296 1.443-.296.385 0 .739.055 1.063.167.324.106.605.276.843.509.238.233.423.531.555.896.131.364.197.805.197 1.322v5.476h-1.405V98.37c0-.43-.073-.775-.22-1.033a1.262 1.262 0 0 0-.608-.562 2.192 2.192 0 0 0-.927-.183c-.415 0-.762.074-1.04.22-.279.148-.501.35-.669.608a2.74 2.74 0 0 0-.364.89 4.948 4.948 0 0 0-.106 1.047Zm5.324-.775-.942.29c.005-.451.079-.885.22-1.3a3.52 3.52 0 0 1 .631-1.109 2.98 2.98 0 0 1 1.025-.767c.405-.192.869-.288 1.39-.288.441 0 .831.058 1.17.174.344.117.633.297.866.54.238.238.418.544.539.919.122.374.182.82.182 1.336v5.401h-1.412v-5.416c0-.46-.074-.817-.221-1.07a1.145 1.145 0 0 0-.607-.54 2.432 2.432 0 0 0-.927-.16c-.309 0-.582.054-.82.16a1.695 1.695 0 0 0-.6.44 1.943 1.943 0 0 0-.373.631 2.341 2.341 0 0 0-.121.76Z"}),e.jsx("rect",{width:"99",height:"18",x:"187",y:"90",fill:"color(display-p3 .8745 .8824 .898)",rx:"4"}),e.jsx("path",{fill:"color(display-p3 .8588 .8627 .8667)",d:"M32 118.667h1600v1.111H32z"}),e.jsxs("g",{clipPath:"url(#e)",children:[e.jsx("path",{fill:"color(display-p3 .9608 .9608 .9608)",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#fff",d:"M32 119.778h1531.11v91.417H32z"}),e.jsx("path",{fill:"#000",d:"M248.364 170.986v-11.599h2.101v4.91h5.375v-4.91h2.107v11.599h-2.107v-4.927h-5.375v4.927h-2.101Zm15.891.17c-.849 0-1.586-.187-2.209-.56a3.813 3.813 0 0 1-1.45-1.569c-.339-.672-.509-1.458-.509-2.356 0-.899.17-1.686.509-2.362a3.804 3.804 0 0 1 1.45-1.575c.623-.374 1.36-.56 2.209-.56.85 0 1.586.186 2.209.56a3.758 3.758 0 0 1 1.444 1.575c.344.676.516 1.463.516 2.362 0 .898-.172 1.684-.516 2.356a3.766 3.766 0 0 1-1.444 1.569c-.623.373-1.359.56-2.209.56Zm.012-1.642c.46 0 .845-.127 1.155-.38.31-.256.54-.6.691-1.031.155-.43.232-.909.232-1.438 0-.532-.077-1.014-.232-1.444-.151-.435-.381-.78-.691-1.037-.31-.257-.695-.385-1.155-.385-.472 0-.865.128-1.179.385-.309.257-.541.602-.696 1.037a4.34 4.34 0 0 0-.227 1.444c0 .529.076 1.008.227 1.438.155.431.387.775.696 1.031.314.253.707.38 1.179.38Zm6.216 1.472v-8.699h1.96v1.478h.101c.182-.498.482-.887.901-1.167.419-.283.919-.424 1.501-.424.589 0 1.085.143 1.489.43.408.283.695.67.861 1.161h.091a2.38 2.38 0 0 1 .974-1.155c.461-.291 1.006-.436 1.637-.436.8 0 1.454.253 1.96.758.506.506.759 1.245.759 2.215v5.839h-2.056v-5.522c0-.54-.144-.934-.431-1.184-.287-.253-.638-.379-1.053-.379-.495 0-.882.155-1.161.464-.276.306-.414.705-.414 1.195v5.426h-2.01v-5.607c0-.449-.136-.808-.408-1.076-.268-.268-.619-.402-1.054-.402-.294 0-.562.076-.804.227a1.578 1.578 0 0 0-.578.628 1.97 1.97 0 0 0-.215.94v5.29h-2.05Zm18.484.17c-.872 0-1.626-.181-2.26-.543a3.688 3.688 0 0 1-1.456-1.552c-.339-.672-.509-1.463-.509-2.373 0-.895.17-1.681.509-2.357a3.86 3.86 0 0 1 1.439-1.585c.616-.382 1.339-.572 2.169-.572.536 0 1.042.086 1.518.26.48.17.903.434 1.269.793.37.359.661.816.872 1.371.211.551.317 1.208.317 1.971v.628h-7.13v-1.382h5.165a2.206 2.206 0 0 0-.255-1.047 1.844 1.844 0 0 0-.697-.731 1.95 1.95 0 0 0-1.03-.266c-.42 0-.788.102-1.105.306-.317.2-.564.464-.742.792a2.295 2.295 0 0 0-.266 1.071v1.206c0 .506.093.94.278 1.303.185.359.443.634.775.827.333.189.722.283 1.167.283.298 0 .568-.041.81-.125.242-.086.451-.213.629-.379a1.59 1.59 0 0 0 .402-.617l1.914.215a2.98 2.98 0 0 1-.691 1.325 3.356 3.356 0 0 1-1.291.872c-.525.204-1.125.306-1.801.306Z"}),e.jsx("path",{fill:"color(display-p3 .4196 .4471 .502)",d:"M342.036 170.986h-1.472l4.259-11.599h1.45l4.259 11.599h-1.472l-3.467-9.764h-.09l-3.467 9.764Zm.544-4.531h5.936v1.246h-5.936v-1.246Zm10.078 4.531v-11.599h1.336v4.282h.114c.098-.151.234-.344.408-.578.177-.238.43-.449.758-.634.333-.189.782-.283 1.348-.283.733 0 1.379.183 1.937.549.559.366.995.885 1.309 1.557.313.673.47 1.465.47 2.379 0 .922-.157 1.72-.47 2.396-.314.672-.748 1.193-1.303 1.563-.555.366-1.195.55-1.92.55-.559 0-1.006-.093-1.342-.278-.336-.189-.595-.402-.776-.64a8.822 8.822 0 0 1-.419-.6h-.159v1.336h-1.291Zm1.314-4.349c0 .657.096 1.236.289 1.738.192.499.474.89.844 1.173.37.279.823.419 1.359.419.559 0 1.025-.147 1.399-.442.377-.298.661-.698.849-1.201a4.7 4.7 0 0 0 .289-1.687c0-.612-.094-1.163-.283-1.654-.185-.495-.466-.886-.844-1.173-.374-.29-.844-.436-1.41-.436-.544 0-1.001.138-1.371.414-.37.272-.649.653-.838 1.144-.189.487-.283 1.055-.283 1.705Zm12.264 4.531c-.786 0-1.475-.187-2.068-.561-.589-.374-1.049-.897-1.382-1.569-.328-.672-.492-1.457-.492-2.356 0-.906.164-1.697.492-2.373.333-.676.793-1.201 1.382-1.575.593-.374 1.282-.56 2.068-.56.785 0 1.472.186 2.061.56.593.374 1.054.899 1.382 1.575.332.676.499 1.467.499 2.373 0 .899-.167 1.684-.499 2.356a3.755 3.755 0 0 1-1.382 1.569c-.589.374-1.276.561-2.061.561Zm0-1.201c.596 0 1.087-.153 1.472-.459.385-.306.67-.708.855-1.206a4.624 4.624 0 0 0 .278-1.62 4.67 4.67 0 0 0-.278-1.626 2.736 2.736 0 0 0-.855-1.217c-.385-.31-.876-.465-1.472-.465-.597 0-1.088.155-1.473.465-.385.309-.67.715-.855 1.217a4.67 4.67 0 0 0-.278 1.626c0 .581.093 1.121.278 1.62.185.498.47.9.855 1.206.385.306.876.459 1.473.459Zm11.783-2.537v-5.143h1.337v8.699h-1.337v-1.472h-.09a2.853 2.853 0 0 1-.952 1.127c-.43.306-.974.459-1.631.459-.544 0-1.027-.119-1.45-.357-.423-.242-.755-.604-.997-1.088-.241-.487-.362-1.1-.362-1.84v-5.528h1.337v5.437c0 .634.177 1.14.532 1.518.359.377.815.566 1.371.566.332 0 .67-.085 1.013-.255.348-.17.638-.43.873-.781.237-.351.356-.799.356-1.342Zm7.888-5.143v1.133h-4.509v-1.133h4.509Zm-3.195-2.084h1.337v8.291c0 .378.055.661.164.85a.854.854 0 0 0 .431.374c.177.06.364.09.56.09.147 0 .268-.007.363-.022l.226-.046.272 1.201a2.739 2.739 0 0 1-.379.102 2.788 2.788 0 0 1-.618.057 2.7 2.7 0 0 1-1.11-.244 2.204 2.204 0 0 1-.895-.742c-.234-.332-.351-.751-.351-1.257v-8.654Zm18.122-.816h1.405v7.68c0 .793-.187 1.501-.561 2.124a3.93 3.93 0 0 1-1.569 1.467c-.676.355-1.469.532-2.379.532-.91 0-1.703-.177-2.378-.532a3.972 3.972 0 0 1-1.575-1.467c-.37-.623-.555-1.331-.555-2.124v-7.68h1.405v7.567c0 .566.124 1.07.373 1.512.25.438.605.783 1.065 1.036.465.25 1.02.374 1.665.374.646 0 1.201-.124 1.665-.374.465-.253.82-.598 1.065-1.036.249-.442.374-.946.374-1.512v-7.567Zm10.51 4.848-1.201.34a2.238 2.238 0 0 0-.334-.583 1.618 1.618 0 0 0-.589-.476c-.25-.125-.569-.187-.958-.187-.532 0-.976.123-1.331.368-.351.242-.526.549-.526.923 0 .333.121.595.362.788.242.192.619.353 1.133.481l1.291.317c.778.189 1.358.478 1.739.867.381.385.572.881.572 1.489 0 .499-.143.944-.43 1.337-.284.393-.68.702-1.19.929-.509.226-1.102.34-1.778.34-.887 0-1.622-.193-2.203-.578-.582-.385-.95-.948-1.105-1.688l1.269-.317c.121.468.349.819.685 1.053.34.234.784.352 1.331.352.623 0 1.118-.133 1.484-.397.37-.268.555-.589.555-.963 0-.302-.106-.555-.317-.759-.211-.207-.536-.362-.974-.464l-1.45-.34c-.797-.189-1.382-.481-1.756-.878-.37-.4-.555-.9-.555-1.501 0-.491.138-.925.414-1.302a2.812 2.812 0 0 1 1.138-.89c.483-.215 1.031-.322 1.642-.322.861 0 1.537.188 2.028.566.495.378.846.876 1.054 1.495Z"})]})]})]}),e.jsxs("defs",{children:[e.jsx("clipPath",{id:"a",children:e.jsx("path",{fill:"#fff",d:"M0 0h384v216H0z"})}),e.jsx("clipPath",{id:"c",children:e.jsx("path",{fill:"#fff",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"})}),e.jsx("clipPath",{id:"d",children:e.jsx("path",{fill:"#fff",d:"M128.667 40.889h280v37.778h-280z"})}),e.jsx("clipPath",{id:"e",children:e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"})}),e.jsxs("filter",{id:"b",width:"1706.67",height:"994.444",x:"-21.333",y:"-3.556",colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),e.jsx("feOffset",{dy:"17.778"}),e.jsx("feGaussianBlur",{stdDeviation:"26.667"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_53_37"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_53_37",result:"shape"})]})]})]})};ns.defaultProps={xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 384 216"};var as=function(C){return e.jsxs("svg",{...C,children:[e.jsxs("g",{clipPath:"url(#a)",children:[e.jsx("path",{fill:"color(display-p3 .1255 .3333 .898)",d:"M0 0h384v216H0z"}),e.jsxs("g",{filter:"url(#b)",children:[e.jsx("rect",{width:"1600",height:"887.778",x:"32",y:"32",fill:"#1a1a1a",rx:"12",shapeRendering:"crispEdges"}),e.jsxs("g",{clipPath:"url(#c)",children:[e.jsx("path",{fill:"color(display-p3 .2 .2 .2)",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"55.333",y:"49.778",fill:"color(display-p3 .9255 .4196 .3686)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"77.556",y:"49.778",fill:"color(display-p3 .9569 .749 .3098)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"99.778",y:"49.778",fill:"color(display-p3 .3804 .7686 .3255)",rx:"6.667"}),e.jsxs("g",{clipPath:"url(#d)",children:[e.jsx("path",{fill:"#2a2a2a",d:"M128.667 49.778a8.888 8.888 0 0 1 8.889-8.89h248.888c4.91 0 8.889 3.98 8.889 8.89v28.889H128.667v-28.89Z"}),e.jsx("path",{stroke:"color(display-p3 .8 .8 .8)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"m374.222 56.444 3.334 3.334m0 0 3.333-3.334m-3.333 3.334-3.334 3.333m3.334-3.333 3.333 3.333"}),e.jsx("rect",{width:"180",height:"18",x:"140",y:"51",fill:"color(display-p3 .3 .3 .3)",rx:"4"})]})]}),e.jsx("path",{fill:"#1a1a1a",d:"M32 78.667h1600v40H32z"}),e.jsx("path",{stroke:"color(display-p3 .8 .8 .8)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"M63.111 98.667H49.778m0 0L56.444 92m-6.666 6.667 6.666 6.666m28.889-6.666h13.334m0 0L92 92m6.667 6.667L92 105.333"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",fillRule:"evenodd",d:"M122.278 98.667a5.278 5.278 0 0 1 9.524-3.136l-2.024 2.024h5.555V92l-2.343 2.343a6.944 6.944 0 1 0 .752 7.48.834.834 0 0 0-1.484-.758 5.278 5.278 0 0 1-9.98-2.398Z",clipRule:"evenodd"}),e.jsx("rect",{width:"1360",height:"31.111",x:"152",y:"83.111",fill:"color(display-p3 .2 .2 .2)",rx:"15.556"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",fillRule:"evenodd",d:"M172 93.111a2.778 2.778 0 0 0-2.778 2.778V97h-.555a1.11 1.11 0 0 0-1.111 1.111v5.556c0 .613.497 1.111 1.111 1.111h6.666c.614 0 1.111-.498 1.111-1.111v-5.556A1.11 1.11 0 0 0 175.333 97h-.555v-1.111A2.778 2.778 0 0 0 172 93.11ZM173.667 97v-1.111a1.667 1.667 0 0 0-3.334 0V97h3.334Z",clipRule:"evenodd"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",d:"M195.695 102.373v-4.231c0-.324-.066-.605-.198-.843a1.29 1.29 0 0 0-.577-.562c-.258-.132-.577-.198-.957-.198-.355 0-.666.061-.934.183a1.624 1.624 0 0 0-.623.478 1.05 1.05 0 0 0-.221.638h-1.405c0-.293.076-.585.228-.873.152-.289.37-.55.653-.783a3.271 3.271 0 0 1 1.033-.562 4.072 4.072 0 0 1 1.352-.212c.598 0 1.125.1 1.58.303.461.203.821.51 1.079.92.263.405.395.913.395 1.526v3.828c0 .274.023.565.068.874.051.309.124.575.22.797v.122h-1.466a2.684 2.684 0 0 1-.167-.646 5.26 5.26 0 0 1-.06-.759Zm.243-3.578.015.988h-1.421c-.4 0-.757.032-1.07.098a2.463 2.463 0 0 0-.79.281 1.34 1.34 0 0 0-.487.479 1.273 1.273 0 0 0-.167.661c0 .258.059.493.175.706.117.213.291.382.524.509.238.122.529.182.874.182a2.357 2.357 0 0 0 1.921-.942c.198-.263.304-.519.319-.767l.6.676a2.034 2.034 0 0 1-.288.707 3.402 3.402 0 0 1-1.557 1.329 3.02 3.02 0 0 1-1.2.228c-.557 0-1.046-.109-1.466-.327a2.51 2.51 0 0 1-.973-.873 2.322 2.322 0 0 1-.341-1.238c0-.441.086-.828.258-1.163.172-.339.42-.62.744-.843.324-.228.714-.4 1.17-.516a6.173 6.173 0 0 1 1.527-.175h1.633Zm4.777-1.944v6.927h-1.405v-8.219h1.367l.038 1.292Zm2.567-1.337-.007 1.306a2.035 2.035 0 0 0-.334-.045 3.579 3.579 0 0 0-.35-.015c-.324 0-.61.05-.858.151a1.777 1.777 0 0 0-.63.426c-.173.182-.309.4-.411.653a3.132 3.132 0 0 0-.189.82l-.395.228c0-.496.048-.962.144-1.397.101-.436.256-.82.463-1.155.208-.34.471-.602.79-.79.324-.192.709-.288 1.155-.288.101 0 .217.012.349.038.132.02.223.043.273.068Zm4.436 7.261c.334 0 .643-.068.927-.205.283-.137.516-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.372 3.372 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.618 0-1.157-.109-1.618-.327a3.213 3.213 0 0 1-1.139-.896 3.998 3.998 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564a3.99 3.99 0 0 1 .676-1.314c.304-.38.684-.679 1.139-.897.461-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395.481.258.859.612 1.132 1.063.279.445.431.952.456 1.519h-1.337a2.01 2.01 0 0 0-.289-.919 1.794 1.794 0 0 0-.668-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.898 1.898 0 0 0-.691.684c-.167.283-.289.6-.365.95a5.214 5.214 0 0 0-.106 1.055v.32c0 .359.035.713.106 1.063.071.349.19.665.357.949.172.284.403.511.691.684.294.167.659.25 1.094.25Zm4.846-10.664h1.413v10.072l-.122 1.595h-1.291V92.111Zm6.965 7.49v.159c0 .597-.071 1.152-.212 1.663-.142.507-.35.947-.623 1.322a2.897 2.897 0 0 1-1.003.873c-.395.208-.848.312-1.359.312-.522 0-.98-.089-1.375-.266a2.707 2.707 0 0 1-.988-.782 4.064 4.064 0 0 1-.645-1.231 7.769 7.769 0 0 1-.327-1.625v-.7c.061-.607.17-1.151.327-1.632a4.05 4.05 0 0 1 .645-1.23 2.6 2.6 0 0 1 .988-.783c.39-.182.843-.273 1.359-.273.517 0 .975.1 1.375.303.4.198.734.481 1.003.851a4 4 0 0 1 .623 1.33c.141.51.212 1.08.212 1.708Zm-1.413.159v-.16c0-.41-.038-.795-.113-1.154a2.993 2.993 0 0 0-.365-.957 1.81 1.81 0 0 0-.661-.653c-.273-.162-.61-.243-1.01-.243-.355 0-.663.06-.927.182a2.014 2.014 0 0 0-.661.493 2.64 2.64 0 0 0-.448.7 3.993 3.993 0 0 0-.25.804v1.831c.081.354.212.696.395 1.025.187.324.435.59.744.798.314.207.701.311 1.162.311.38 0 .704-.076.972-.228.274-.157.494-.372.661-.645.172-.274.299-.59.38-.95.081-.359.121-.744.121-1.154Zm4.717-7.649v11.667h-1.412V92.111h1.412Zm1.884 7.649v-.175c0-.592.086-1.142.258-1.648a3.9 3.9 0 0 1 .745-1.33c.324-.38.716-.673 1.177-.88a3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.549.312a3.747 3.747 0 0 1-1.558-.312 3.513 3.513 0 0 1-1.184-.881 4.002 4.002 0 0 1-.745-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.025.235.384 0 .722-.078 1.011-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.018.243a2.195 2.195 0 0 0-.729.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm9.236-2.392v6.585h-1.413v-8.219h1.337l.076 1.633Zm-.288 2.164-.654-.022a5.603 5.603 0 0 1 .221-1.558c.141-.48.351-.898.63-1.253a2.793 2.793 0 0 1 1.041-.82c.415-.198.896-.296 1.443-.296.385 0 .739.055 1.063.167.324.106.605.276.843.509.238.233.423.531.555.896.131.364.197.805.197 1.322v5.476h-1.405V98.37c0-.43-.073-.775-.22-1.033a1.262 1.262 0 0 0-.608-.562 2.192 2.192 0 0 0-.927-.183c-.415 0-.762.074-1.04.22-.279.148-.501.35-.669.608a2.74 2.74 0 0 0-.364.89 4.948 4.948 0 0 0-.106 1.047Zm5.324-.775-.942.29c.005-.451.079-.885.22-1.3a3.52 3.52 0 0 1 .631-1.109 2.98 2.98 0 0 1 1.025-.767c.405-.192.869-.288 1.39-.288.441 0 .831.058 1.17.174.344.117.633.297.866.54.238.238.418.544.539.919.122.374.182.82.182 1.336v5.401h-1.412v-5.416c0-.46-.074-.817-.221-1.07a1.145 1.145 0 0 0-.607-.54 2.432 2.432 0 0 0-.927-.16c-.309 0-.582.054-.82.16a1.695 1.695 0 0 0-.6.44 1.943 1.943 0 0 0-.373.631 2.341 2.341 0 0 0-.121.76Z"}),e.jsx("rect",{width:"99",height:"18",x:"187",y:"90",fill:"color(display-p3 .3 .3 .3)",rx:"4"}),e.jsx("path",{fill:"color(display-p3 .2 .2 .2)",d:"M32 118.667h1600v1.111H32z"}),e.jsxs("g",{clipPath:"url(#e)",children:[e.jsx("path",{fill:"color(display-p3 .1 .1 .1)",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#1a1a1a",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#1a1a1a",d:"M32 119.778h1531.11v91.417H32z"}),e.jsx("path",{fill:"#fff",d:"M248.364 170.986v-11.599h2.101v4.91h5.375v-4.91h2.107v11.599h-2.107v-4.927h-5.375v4.927h-2.101Zm15.891.17c-.849 0-1.586-.187-2.209-.56a3.813 3.813 0 0 1-1.45-1.569c-.339-.672-.509-1.458-.509-2.356 0-.899.17-1.686.509-2.362a3.804 3.804 0 0 1 1.45-1.575c.623-.374 1.36-.56 2.209-.56.85 0 1.586.186 2.209.56a3.758 3.758 0 0 1 1.444 1.575c.344.676.516 1.463.516 2.362 0 .898-.172 1.684-.516 2.356a3.766 3.766 0 0 1-1.444 1.569c-.623.373-1.359.56-2.209.56Zm.012-1.642c.46 0 .845-.127 1.155-.38.31-.256.54-.6.691-1.031.155-.43.232-.909.232-1.438 0-.532-.077-1.014-.232-1.444-.151-.435-.381-.78-.691-1.037-.31-.257-.695-.385-1.155-.385-.472 0-.865.128-1.179.385-.309.257-.541.602-.696 1.037a4.34 4.34 0 0 0-.227 1.444c0 .529.076 1.008.227 1.438.155.431.387.775.696 1.031.314.253.707.38 1.179.38Zm6.216 1.472v-8.699h1.96v1.478h.101c.182-.498.482-.887.901-1.167.419-.283.919-.424 1.501-.424.589 0 1.085.143 1.489.43.408.283.695.67.861 1.161h.091a2.38 2.38 0 0 1 .974-1.155c.461-.291 1.006-.436 1.637-.436.8 0 1.454.253 1.96.758.506.506.759 1.245.759 2.215v5.839h-2.056v-5.522c0-.54-.144-.934-.431-1.184-.287-.253-.638-.379-1.053-.379-.495 0-.882.155-1.161.464-.276.306-.414.705-.414 1.195v5.426h-2.01v-5.607c0-.449-.136-.808-.408-1.076-.268-.268-.619-.402-1.054-.402-.294 0-.562.076-.804.227a1.578 1.578 0 0 0-.578.628 1.97 1.97 0 0 0-.215.94v5.29h-2.05Zm18.484.17c-.872 0-1.626-.181-2.26-.543a3.688 3.688 0 0 1-1.456-1.552c-.339-.672-.509-1.463-.509-2.373 0-.895.17-1.681.509-2.357a3.86 3.86 0 0 1 1.439-1.585c.616-.382 1.339-.572 2.169-.572.536 0 1.042.086 1.518.26.48.17.903.434 1.269.793.37.359.661.816.872 1.371.211.551.317 1.208.317 1.971v.628h-7.13v-1.382h5.165a2.206 2.206 0 0 0-.255-1.047 1.844 1.844 0 0 0-.697-.731 1.95 1.95 0 0 0-1.03-.266c-.42 0-.788.102-1.105.306-.317.2-.564.464-.742.792a2.295 2.295 0 0 0-.266 1.071v1.206c0 .506.093.94.278 1.303.185.359.443.634.775.827.333.189.722.283 1.167.283.298 0 .568-.041.81-.125.242-.086.451-.213.629-.379a1.59 1.59 0 0 0 .402-.617l1.914.215a2.98 2.98 0 0 1-.691 1.325 3.356 3.356 0 0 1-1.291.872c-.525.204-1.125.306-1.801.306Z"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",d:"M342.036 170.986h-1.472l4.259-11.599h1.45l4.259 11.599h-1.472l-3.467-9.764h-.09l-3.467 9.764Zm.544-4.531h5.936v1.246h-5.936v-1.246Zm10.078 4.531v-11.599h1.336v4.282h.114c.098-.151.234-.344.408-.578.177-.238.43-.449.758-.634.333-.189.782-.283 1.348-.283.733 0 1.379.183 1.937.549.559.366.995.885 1.309 1.557.313.673.47 1.465.47 2.379 0 .922-.157 1.72-.47 2.396-.314.672-.748 1.193-1.303 1.563-.555.366-1.195.55-1.92.55-.559 0-1.006-.093-1.342-.278-.336-.189-.595-.402-.776-.64a8.822 8.822 0 0 1-.419-.6h-.159v1.336h-1.291Zm1.314-4.349c0 .657.096 1.236.289 1.738.192.499.474.89.844 1.173.37.279.823.419 1.359.419.559 0 1.025-.147 1.399-.442.377-.298.661-.698.849-1.201a4.7 4.7 0 0 0 .289-1.687c0-.612-.094-1.163-.283-1.654-.185-.495-.466-.886-.844-1.173-.374-.29-.844-.436-1.41-.436-.544 0-1.001.138-1.371.414-.37.272-.649.653-.838 1.144-.189.487-.283 1.055-.283 1.705Zm12.264 4.531c-.786 0-1.475-.187-2.068-.561-.589-.374-1.049-.897-1.382-1.569-.328-.672-.492-1.457-.492-2.356 0-.906.164-1.697.492-2.373.333-.676.793-1.201 1.382-1.575.593-.374 1.282-.56 2.068-.56.785 0 1.472.186 2.061.56.593.374 1.054.899 1.382 1.575.332.676.499 1.467.499 2.373 0 .899-.167 1.684-.499 2.356a3.755 3.755 0 0 1-1.382 1.569c-.589.374-1.276.561-2.061.561Zm0-1.201c.596 0 1.087-.153 1.472-.459.385-.306.67-.708.855-1.206a4.624 4.624 0 0 0 .278-1.62 4.67 4.67 0 0 0-.278-1.626 2.736 2.736 0 0 0-.855-1.217c-.385-.31-.876-.465-1.472-.465-.597 0-1.088.155-1.473.465-.385.309-.67.715-.855 1.217a4.67 4.67 0 0 0-.278 1.626c0 .581.093 1.121.278 1.62.185.498.47.9.855 1.206.385.306.876.459 1.473.459Zm11.783-2.537v-5.143h1.337v8.699h-1.337v-1.472h-.09a2.853 2.853 0 0 1-.952 1.127c-.43.306-.974.459-1.631.459-.544 0-1.027-.119-1.45-.357-.423-.242-.755-.604-.997-1.088-.241-.487-.362-1.1-.362-1.84v-5.528h1.337v5.437c0 .634.177 1.14.532 1.518.359.377.815.566 1.371.566.332 0 .67-.085 1.013-.255.348-.17.638-.43.873-.781.237-.351.356-.799.356-1.342Zm7.888-5.143v1.133h-4.509v-1.133h4.509Zm-3.195-2.084h1.337v8.291c0 .378.055.661.164.85a.854.854 0 0 0 .431.374c.177.06.364.09.56.09.147 0 .268-.007.363-.022l.226-.046.272 1.201a2.739 2.739 0 0 1-.379.102 2.788 2.788 0 0 1-.618.057 2.7 2.7 0 0 1-1.11-.244 2.204 2.204 0 0 1-.895-.742c-.234-.332-.351-.751-.351-1.257v-8.654Zm18.122-.816h1.405v7.68c0 .793-.187 1.501-.561 2.124a3.93 3.93 0 0 1-1.569 1.467c-.676.355-1.469.532-2.379.532-.91 0-1.703-.177-2.378-.532a3.972 3.972 0 0 1-1.575-1.467c-.37-.623-.555-1.331-.555-2.124v-7.68h1.405v7.567c0 .566.124 1.07.373 1.512.25.438.605.783 1.065 1.036.465.25 1.02.374 1.665.374.646 0 1.201-.124 1.665-.374.465-.253.82-.598 1.065-1.036.249-.442.374-.946.374-1.512v-7.567Zm10.51 4.848-1.201.34a2.238 2.238 0 0 0-.334-.583 1.618 1.618 0 0 0-.589-.476c-.25-.125-.569-.187-.958-.187-.532 0-.976.123-1.331.368-.351.242-.526.549-.526.923 0 .333.121.595.362.788.242.192.619.353 1.133.481l1.291.317c.778.189 1.358.478 1.739.867.381.385.572.881.572 1.489 0 .499-.143.944-.43 1.337-.284.393-.68.702-1.19.929-.509.226-1.102.34-1.778.34-.887 0-1.622-.193-2.203-.578-.582-.385-.95-.948-1.105-1.688l1.269-.317c.121.468.349.819.685 1.053.34.234.784.352 1.331.352.623 0 1.118-.133 1.484-.397.37-.268.555-.589.555-.963 0-.302-.106-.555-.317-.759-.211-.207-.536-.362-.974-.464l-1.45-.34c-.797-.189-1.382-.481-1.756-.878-.37-.4-.555-.9-.555-1.501 0-.491.138-.925.414-1.302a2.812 2.812 0 0 1 1.138-.89c.483-.215 1.031-.322 1.642-.322.861 0 1.537.188 2.028.566.495.378.846.876 1.054 1.495Z"})]})]})]}),e.jsxs("defs",{children:[e.jsx("clipPath",{id:"a",children:e.jsx("path",{fill:"#fff",d:"M0 0h384v216H0z"})}),e.jsx("clipPath",{id:"c",children:e.jsx("path",{fill:"#fff",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"})}),e.jsx("clipPath",{id:"d",children:e.jsx("path",{fill:"#fff",d:"M128.667 40.889h280v37.778h-280z"})}),e.jsx("clipPath",{id:"e",children:e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"})}),e.jsxs("filter",{id:"b",width:"1706.67",height:"994.444",x:"-21.333",y:"-3.556",colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),e.jsx("feOffset",{dy:"17.778"}),e.jsx("feGaussianBlur",{stdDeviation:"26.667"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_53_37"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_53_37",result:"shape"})]})]})]})};as.defaultProps={xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 384 216"};var is=function(C){return e.jsxs("svg",{...C,children:[e.jsxs("g",{clipPath:"url(#a)",children:[e.jsx("path",{fill:"color(display-p3 .1255 .3333 .898)",d:"M0 0h384v216H0z"}),e.jsxs("g",{filter:"url(#b)",children:[e.jsx("rect",{width:"1600",height:"887.778",x:"32",y:"32",fill:"#fff",rx:"12",shapeRendering:"crispEdges"}),e.jsxs("g",{clipPath:"url(#c)",children:[e.jsx("path",{fill:"color(display-p3 .8745 .8824 .898)",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"55.333",y:"49.778",fill:"color(display-p3 .9255 .4196 .3686)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"77.556",y:"49.778",fill:"color(display-p3 .9569 .749 .3098)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"99.778",y:"49.778",fill:"color(display-p3 .3804 .7686 .3255)",rx:"6.667"}),e.jsxs("g",{clipPath:"url(#d)",children:[e.jsx("path",{fill:"#fff",d:"M128.667 49.778a8.888 8.888 0 0 1 8.889-8.89h248.888c4.91 0 8.889 3.98 8.889 8.89v28.889H128.667v-28.89Z"}),e.jsx("path",{stroke:"color(display-p3 .2392 .251 .2627)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"m374.222 56.444 3.334 3.334m0 0 3.333-3.334m-3.333 3.334-3.334 3.333m3.334-3.333 3.333 3.333"}),e.jsx("rect",{width:"180",height:"18",x:"140",y:"51",fill:"color(display-p3 .8745 .8824 .898)",rx:"4"})]})]}),e.jsx("path",{fill:"#fff",d:"M32 78.667h1600v40H32z"}),e.jsx("path",{stroke:"color(display-p3 .3765 .3882 .4039)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"M63.111 98.667H49.778m0 0L56.444 92m-6.666 6.667 6.666 6.666m28.889-6.666h13.334m0 0L92 92m6.667 6.667L92 105.333"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",fillRule:"evenodd",d:"M122.278 98.667a5.278 5.278 0 0 1 9.524-3.136l-2.024 2.024h5.555V92l-2.343 2.343a6.944 6.944 0 1 0 .752 7.48.834.834 0 0 0-1.484-.758 5.278 5.278 0 0 1-9.98-2.398Z",clipRule:"evenodd"}),e.jsx("rect",{width:"1360",height:"31.111",x:"152",y:"83.111",fill:"color(display-p3 .9451 .9529 .9569)",rx:"15.556"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",fillRule:"evenodd",d:"M172 93.111a2.778 2.778 0 0 0-2.778 2.778V97h-.555a1.11 1.11 0 0 0-1.111 1.111v5.556c0 .613.497 1.111 1.111 1.111h6.666c.614 0 1.111-.498 1.111-1.111v-5.556A1.11 1.11 0 0 0 175.333 97h-.555v-1.111A2.778 2.778 0 0 0 172 93.11ZM173.667 97v-1.111a1.667 1.667 0 0 0-3.334 0V97h3.334Z",clipRule:"evenodd"}),e.jsx("path",{fill:"color(display-p3 .3765 .3882 .4039)",d:"M195.695 102.373v-4.231c0-.324-.066-.605-.198-.843a1.29 1.29 0 0 0-.577-.562c-.258-.132-.577-.198-.957-.198-.355 0-.666.061-.934.183a1.624 1.624 0 0 0-.623.478 1.05 1.05 0 0 0-.221.638h-1.405c0-.293.076-.585.228-.873.152-.289.37-.55.653-.783a3.271 3.271 0 0 1 1.033-.562 4.072 4.072 0 0 1 1.352-.212c.598 0 1.125.1 1.58.303.461.203.821.51 1.079.92.263.405.395.913.395 1.526v3.828c0 .274.023.565.068.874.051.309.124.575.22.797v.122h-1.466a2.684 2.684 0 0 1-.167-.646 5.26 5.26 0 0 1-.06-.759Zm.243-3.578.015.988h-1.421c-.4 0-.757.032-1.07.098a2.463 2.463 0 0 0-.79.281 1.34 1.34 0 0 0-.487.479 1.273 1.273 0 0 0-.167.661c0 .258.059.493.175.706.117.213.291.382.524.509.238.122.529.182.874.182a2.357 2.357 0 0 0 1.921-.942c.198-.263.304-.519.319-.767l.6.676a2.034 2.034 0 0 1-.288.707 3.402 3.402 0 0 1-1.557 1.329 3.02 3.02 0 0 1-1.2.228c-.557 0-1.046-.109-1.466-.327a2.51 2.51 0 0 1-.973-.873 2.322 2.322 0 0 1-.341-1.238c0-.441.086-.828.258-1.163.172-.339.42-.62.744-.843.324-.228.714-.4 1.17-.516a6.173 6.173 0 0 1 1.527-.175h1.633Zm4.777-1.944v6.927h-1.405v-8.219h1.367l.038 1.292Zm2.567-1.337-.007 1.306a2.035 2.035 0 0 0-.334-.045 3.579 3.579 0 0 0-.35-.015c-.324 0-.61.05-.858.151a1.777 1.777 0 0 0-.63.426c-.173.182-.309.4-.411.653a3.132 3.132 0 0 0-.189.82l-.395.228c0-.496.048-.962.144-1.397.101-.436.256-.82.463-1.155.208-.34.471-.602.79-.79.324-.192.709-.288 1.155-.288.101 0 .217.012.349.038.132.02.223.043.273.068Zm4.436 7.261c.334 0 .643-.068.927-.205.283-.137.516-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.372 3.372 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.618 0-1.157-.109-1.618-.327a3.213 3.213 0 0 1-1.139-.896 3.998 3.998 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564a3.99 3.99 0 0 1 .676-1.314c.304-.38.684-.679 1.139-.897.461-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395.481.258.859.612 1.132 1.063.279.445.431.952.456 1.519h-1.337a2.01 2.01 0 0 0-.289-.919 1.794 1.794 0 0 0-.668-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.898 1.898 0 0 0-.691.684c-.167.283-.289.6-.365.95a5.214 5.214 0 0 0-.106 1.055v.32c0 .359.035.713.106 1.063.071.349.19.665.357.949.172.284.403.511.691.684.294.167.659.25 1.094.25Zm4.846-10.664h1.413v10.072l-.122 1.595h-1.291V92.111Zm6.965 7.49v.159c0 .597-.071 1.152-.212 1.663-.142.507-.35.947-.623 1.322a2.897 2.897 0 0 1-1.003.873c-.395.208-.848.312-1.359.312-.522 0-.98-.089-1.375-.266a2.707 2.707 0 0 1-.988-.782 4.064 4.064 0 0 1-.645-1.231 7.769 7.769 0 0 1-.327-1.625v-.7c.061-.607.17-1.151.327-1.632a4.05 4.05 0 0 1 .645-1.23 2.6 2.6 0 0 1 .988-.783c.39-.182.843-.273 1.359-.273.517 0 .975.1 1.375.303.4.198.734.481 1.003.851a4 4 0 0 1 .623 1.33c.141.51.212 1.08.212 1.708Zm-1.413.159v-.16c0-.41-.038-.795-.113-1.154a2.993 2.993 0 0 0-.365-.957 1.81 1.81 0 0 0-.661-.653c-.273-.162-.61-.243-1.01-.243-.355 0-.663.06-.927.182a2.014 2.014 0 0 0-.661.493 2.64 2.64 0 0 0-.448.7 3.993 3.993 0 0 0-.25.804v1.831c.081.354.212.696.395 1.025.187.324.435.59.744.798.314.207.701.311 1.162.311.38 0 .704-.076.972-.228.274-.157.494-.372.661-.645.172-.274.299-.59.38-.95.081-.359.121-.744.121-1.154Zm4.717-7.649v11.667h-1.412V92.111h1.412Zm1.884 7.649v-.175c0-.592.086-1.142.258-1.648a3.9 3.9 0 0 1 .745-1.33c.324-.38.716-.673 1.177-.88a3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.549.312a3.747 3.747 0 0 1-1.558-.312 3.513 3.513 0 0 1-1.184-.881 4.002 4.002 0 0 1-.745-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.026.235.384 0 .721-.078 1.01-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.017.243a2.189 2.189 0 0 0-.73.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm11.127 3.19c.335 0 .644-.068.927-.205.284-.137.517-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.363 3.363 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.617 0-1.157-.109-1.617-.327a3.208 3.208 0 0 1-1.14-.896 4.017 4.017 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564.152-.497.378-.935.676-1.314a3.21 3.21 0 0 1 1.14-.897c.46-.218 1-.326 1.617-.326.644 0 1.206.131 1.687.395a2.89 2.89 0 0 1 1.131 1.063c.279.445.431.952.456 1.519h-1.337a2.02 2.02 0 0 0-.288-.919 1.797 1.797 0 0 0-.669-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.906 1.906 0 0 0-.691.684c-.167.283-.288.6-.364.95a5.214 5.214 0 0 0-.107 1.055v.32c0 .359.036.713.107 1.063.07.349.189.665.357.949.172.284.402.511.691.684.293.167.658.25 1.093.25Zm6.267-10.664v11.667h-1.413V92.111h1.413Zm5.02 3.448-3.585 3.836-2.005 2.081-.114-1.496 1.436-1.717 2.552-2.704h1.716Zm-1.283 8.219-2.932-3.92.729-1.253 3.859 5.173h-1.656Zm2.757-.745a.86.86 0 0 1 .22-.6c.152-.167.37-.25.653-.25.284 0 .499.083.646.25a.844.844 0 0 1 .228.6.835.835 0 0 1-.228.593c-.147.162-.362.243-.646.243-.283 0-.501-.081-.653-.243a.85.85 0 0 1-.22-.593Zm7.368-.258c.334 0 .643-.068.926-.205.284-.137.517-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.363 3.363 0 0 1-1.177 1.01c-.486.253-1.02.38-1.602.38-.618 0-1.158-.109-1.618-.327a3.208 3.208 0 0 1-1.14-.896 4.017 4.017 0 0 1-.676-1.307 5.54 5.54 0 0 1-.22-1.572v-.319c0-.552.074-1.073.22-1.564.152-.497.378-.935.676-1.314a3.21 3.21 0 0 1 1.14-.897c.46-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395a2.89 2.89 0 0 1 1.131 1.063c.279.445.431.952.456 1.519h-1.337a2.02 2.02 0 0 0-.288-.919 1.797 1.797 0 0 0-.669-.653 1.866 1.866 0 0 0-.979-.25c-.431 0-.793.085-1.087.257a1.906 1.906 0 0 0-.691.684c-.167.283-.288.6-.364.95a5.214 5.214 0 0 0-.107 1.055v.32c0 .359.036.713.107 1.063.07.349.189.665.357.949.172.284.402.511.691.684.293.167.658.25 1.094.25Zm4.481-3.015v-.175c0-.592.086-1.142.258-1.648.172-.511.42-.955.744-1.33a3.33 3.33 0 0 1 1.178-.88 3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.55.312a3.745 3.745 0 0 1-1.557-.312 3.527 3.527 0 0 1-1.185-.881 4.017 4.017 0 0 1-.744-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.025.235.385 0 .722-.078 1.011-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.018.243a2.195 2.195 0 0 0-.729.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm9.236-2.392v6.585h-1.413v-8.219h1.337l.076 1.633Zm-.288 2.164-.654-.022a5.603 5.603 0 0 1 .221-1.558c.141-.48.351-.898.63-1.253a2.793 2.793 0 0 1 1.041-.82c.415-.198.896-.296 1.443-.296.385 0 .739.055 1.063.167.324.106.605.276.843.509.238.233.423.531.555.896.131.364.197.805.197 1.322v5.476h-1.405V98.37c0-.43-.073-.775-.22-1.033a1.262 1.262 0 0 0-.608-.562 2.192 2.192 0 0 0-.927-.183c-.415 0-.762.074-1.04.22-.279.148-.501.35-.669.608a2.74 2.74 0 0 0-.364.89 4.948 4.948 0 0 0-.106 1.047Zm5.324-.775-.942.29c.005-.451.079-.885.22-1.3a3.52 3.52 0 0 1 .631-1.109 2.98 2.98 0 0 1 1.025-.767c.405-.192.869-.288 1.39-.288.441 0 .831.058 1.17.174.344.117.633.297.866.54.238.238.418.544.539.919.122.374.182.82.182 1.336v5.401h-1.412v-5.416c0-.46-.074-.817-.221-1.07a1.145 1.145 0 0 0-.607-.54 2.432 2.432 0 0 0-.927-.16c-.309 0-.582.054-.82.16a1.695 1.695 0 0 0-.6.44 1.943 1.943 0 0 0-.373.631 2.341 2.341 0 0 0-.121.76Z"}),e.jsx("rect",{width:"99",height:"18",x:"187",y:"90",fill:"color(display-p3 .8745 .8824 .898)",rx:"4"}),e.jsx("path",{fill:"color(display-p3 .8588 .8627 .8667)",d:"M32 118.667h1600v1.111H32z"}),e.jsxs("g",{clipPath:"url(#e)",children:[e.jsx("path",{fill:"color(display-p3 .9608 .9608 .9608)",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#fff",d:"M32 119.778h1531.11v91.417H32z"}),e.jsx("rect",{x:"79.723",y:"145.457",width:"119.774",height:"40.059",rx:"8",style:{fill:"color(display-p3 .7569 .7608 .7647)",fillOpacity:"1"}}),e.jsx("path",{fill:"#000",d:"M248.364 170.986v-11.599h2.101v4.91h5.375v-4.91h2.107v11.599h-2.107v-4.927h-5.375v4.927h-2.101Zm15.891.17c-.849 0-1.586-.187-2.209-.56a3.813 3.813 0 0 1-1.45-1.569c-.339-.672-.509-1.458-.509-2.356 0-.899.17-1.686.509-2.362a3.804 3.804 0 0 1 1.45-1.575c.623-.374 1.36-.56 2.209-.56.85 0 1.586.186 2.209.56a3.758 3.758 0 0 1 1.444 1.575c.344.676.516 1.463.516 2.362 0 .898-.172 1.684-.516 2.356a3.766 3.766 0 0 1-1.444 1.569c-.623.373-1.359.56-2.209.56Zm.012-1.642c.46 0 .845-.127 1.155-.38.31-.256.54-.6.691-1.031.155-.43.232-.909.232-1.438 0-.532-.077-1.014-.232-1.444-.151-.435-.381-.78-.691-1.037-.31-.257-.695-.385-1.155-.385-.472 0-.865.128-1.179.385-.309.257-.541.602-.696 1.037a4.34 4.34 0 0 0-.227 1.444c0 .529.076 1.008.227 1.438.155.431.387.775.696 1.031.314.253.707.38 1.179.38Zm6.216 1.472v-8.699h1.96v1.478h.101c.182-.498.482-.887.901-1.167.419-.283.919-.424 1.501-.424.589 0 1.085.143 1.489.43.408.283.695.67.861 1.161h.091a2.38 2.38 0 0 1 .974-1.155c.461-.291 1.006-.436 1.637-.436.8 0 1.454.253 1.96.758.506.506.759 1.245.759 2.215v5.839h-2.056v-5.522c0-.54-.144-.934-.431-1.184-.287-.253-.638-.379-1.053-.379-.495 0-.882.155-1.161.464-.276.306-.414.705-.414 1.195v5.426h-2.01v-5.607c0-.449-.136-.808-.408-1.076-.268-.268-.619-.402-1.054-.402-.294 0-.562.076-.804.227a1.578 1.578 0 0 0-.578.628 1.97 1.97 0 0 0-.215.94v5.29h-2.05Zm18.484.17c-.872 0-1.626-.181-2.26-.543a3.688 3.688 0 0 1-1.456-1.552c-.339-.672-.509-1.463-.509-2.373 0-.895.17-1.681.509-2.357a3.86 3.86 0 0 1 1.439-1.585c.616-.382 1.339-.572 2.169-.572.536 0 1.042.086 1.518.26.48.17.903.434 1.269.793.37.359.661.816.872 1.371.211.551.317 1.208.317 1.971v.628h-7.13v-1.382h5.165a2.206 2.206 0 0 0-.255-1.047 1.844 1.844 0 0 0-.697-.731 1.95 1.95 0 0 0-1.03-.266c-.42 0-.788.102-1.105.306-.317.2-.564.464-.742.792a2.295 2.295 0 0 0-.266 1.071v1.206c0 .506.093.94.278 1.303.185.359.443.634.775.827.333.189.722.283 1.167.283.298 0 .568-.041.81-.125.242-.086.451-.213.629-.379a1.59 1.59 0 0 0 .402-.617l1.914.215a2.98 2.98 0 0 1-.691 1.325 3.356 3.356 0 0 1-1.291.872c-.525.204-1.125.306-1.801.306Z"}),e.jsx("path",{fill:"color(display-p3 .4196 .4471 .502)",d:"M342.036 170.986h-1.472l4.259-11.599h1.45l4.259 11.599h-1.472l-3.467-9.764h-.09l-3.467 9.764Zm.544-4.531h5.936v1.246h-5.936v-1.246Zm10.078 4.531v-11.599h1.336v4.282h.114c.098-.151.234-.344.408-.578.177-.238.43-.449.758-.634.333-.189.782-.283 1.348-.283.733 0 1.379.183 1.937.549.559.366.995.885 1.309 1.557.313.673.47 1.465.47 2.379 0 .922-.157 1.72-.47 2.396-.314.672-.748 1.193-1.303 1.563-.555.366-1.195.55-1.92.55-.559 0-1.006-.093-1.342-.278-.336-.189-.595-.402-.776-.64a8.822 8.822 0 0 1-.419-.6h-.159v1.336h-1.291Zm1.314-4.349c0 .657.096 1.236.289 1.738.192.499.474.89.844 1.173.37.279.823.419 1.359.419.559 0 1.025-.147 1.399-.442.377-.298.661-.698.849-1.201a4.7 4.7 0 0 0 .289-1.687c0-.612-.094-1.163-.283-1.654-.185-.495-.466-.886-.844-1.173-.374-.29-.844-.436-1.41-.436-.544 0-1.001.138-1.371.414-.37.272-.649.653-.838 1.144-.189.487-.283 1.055-.283 1.705Zm12.264 4.531c-.786 0-1.475-.187-2.068-.561-.589-.374-1.049-.897-1.382-1.569-.328-.672-.492-1.457-.492-2.356 0-.906.164-1.697.492-2.373.333-.676.793-1.201 1.382-1.575.593-.374 1.282-.56 2.068-.56.785 0 1.472.186 2.061.56.593.374 1.054.899 1.382 1.575.332.676.499 1.467.499 2.373 0 .899-.167 1.684-.499 2.356a3.755 3.755 0 0 1-1.382 1.569c-.589.374-1.276.561-2.061.561Zm0-1.201c.596 0 1.087-.153 1.472-.459.385-.306.67-.708.855-1.206a4.624 4.624 0 0 0 .278-1.62 4.67 4.67 0 0 0-.278-1.626 2.736 2.736 0 0 0-.855-1.217c-.385-.31-.876-.465-1.472-.465-.597 0-1.088.155-1.473.465-.385.309-.67.715-.855 1.217a4.67 4.67 0 0 0-.278 1.626c0 .581.093 1.121.278 1.62.185.498.47.9.855 1.206.385.306.876.459 1.473.459Zm11.783-2.537v-5.143h1.337v8.699h-1.337v-1.472h-.09a2.853 2.853 0 0 1-.952 1.127c-.43.306-.974.459-1.631.459-.544 0-1.027-.119-1.45-.357-.423-.242-.755-.604-.997-1.088-.241-.487-.362-1.1-.362-1.84v-5.528h1.337v5.437c0 .634.177 1.14.532 1.518.359.377.815.566 1.371.566.332 0 .67-.085 1.013-.255.348-.17.638-.43.873-.781.237-.351.356-.799.356-1.342Zm7.888-5.143v1.133h-4.509v-1.133h4.509Zm-3.195-2.084h1.337v8.291c0 .378.055.661.164.85a.854.854 0 0 0 .431.374c.177.06.364.09.56.09.147 0 .268-.007.363-.022l.226-.046.272 1.201a2.739 2.739 0 0 1-.379.102 2.788 2.788 0 0 1-.618.057 2.7 2.7 0 0 1-1.11-.244 2.204 2.204 0 0 1-.895-.742c-.234-.332-.351-.751-.351-1.257v-8.654Zm18.122-.816h1.405v7.68c0 .793-.187 1.501-.561 2.124a3.93 3.93 0 0 1-1.569 1.467c-.676.355-1.469.532-2.379.532-.91 0-1.703-.177-2.378-.532a3.972 3.972 0 0 1-1.575-1.467c-.37-.623-.555-1.331-.555-2.124v-7.68h1.405v7.567c0 .566.124 1.07.373 1.512.25.438.605.783 1.065 1.036.465.25 1.02.374 1.665.374.646 0 1.201-.124 1.665-.374.465-.253.82-.598 1.065-1.036.249-.442.374-.946.374-1.512v-7.567Zm10.51 4.848-1.201.34a2.238 2.238 0 0 0-.334-.583 1.618 1.618 0 0 0-.589-.476c-.25-.125-.569-.187-.958-.187-.532 0-.976.123-1.331.368-.351.242-.526.549-.526.923 0 .333.121.595.362.788.242.192.619.353 1.133.481l1.291.317c.778.189 1.358.478 1.739.867.381.385.572.881.572 1.489 0 .499-.143.944-.43 1.337-.284.393-.68.702-1.19.929-.509.226-1.102.34-1.778.34-.887 0-1.622-.193-2.203-.578-.582-.385-.95-.948-1.105-1.688l1.269-.317c.121.468.349.819.685 1.053.34.234.784.352 1.331.352.623 0 1.118-.133 1.484-.397.37-.268.555-.589.555-.963 0-.302-.106-.555-.317-.759-.211-.207-.536-.362-.974-.464l-1.45-.34c-.797-.189-1.382-.481-1.756-.878-.37-.4-.555-.9-.555-1.501 0-.491.138-.925.414-1.302a2.812 2.812 0 0 1 1.138-.89c.483-.215 1.031-.322 1.642-.322.861 0 1.537.188 2.028.566.495.378.846.876 1.054 1.495Z"})]})]})]}),e.jsxs("defs",{children:[e.jsx("clipPath",{id:"a",children:e.jsx("path",{fill:"#fff",d:"M0 0h384v216H0z"})}),e.jsx("clipPath",{id:"c",children:e.jsx("path",{fill:"#fff",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"})}),e.jsx("clipPath",{id:"d",children:e.jsx("path",{fill:"#fff",d:"M128.667 40.889h280v37.778h-280z"})}),e.jsx("clipPath",{id:"e",children:e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"})}),e.jsxs("filter",{id:"b",width:"1706.67",height:"994.444",x:"-21.333",y:"-3.556",colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),e.jsx("feOffset",{dy:"17.778"}),e.jsx("feGaussianBlur",{stdDeviation:"26.667"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_53_37"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_53_37",result:"shape"})]})]})]})};is.defaultProps={xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 384 216"};var os=function(C){return e.jsxs("svg",{...C,children:[e.jsxs("g",{clipPath:"url(#a)",children:[e.jsx("path",{fill:"color(display-p3 .1255 .3333 .898)",d:"M0 0h384v216H0z"}),e.jsxs("g",{filter:"url(#b)",children:[e.jsx("rect",{width:"1600",height:"887.778",x:"32",y:"32",fill:"#1a1a1a",rx:"12",shapeRendering:"crispEdges"}),e.jsxs("g",{clipPath:"url(#c)",children:[e.jsx("path",{fill:"color(display-p3 .2 .2 .2)",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"55.333",y:"49.778",fill:"color(display-p3 .9255 .4196 .3686)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"77.556",y:"49.778",fill:"color(display-p3 .9569 .749 .3098)",rx:"6.667"}),e.jsx("rect",{width:"13.333",height:"13.333",x:"99.778",y:"49.778",fill:"color(display-p3 .3804 .7686 .3255)",rx:"6.667"}),e.jsxs("g",{clipPath:"url(#d)",children:[e.jsx("path",{fill:"#2a2a2a",d:"M128.667 49.778a8.888 8.888 0 0 1 8.889-8.89h248.888c4.91 0 8.889 3.98 8.889 8.89v28.889H128.667v-28.89Z"}),e.jsx("path",{stroke:"color(display-p3 .8 .8 .8)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"m374.222 56.444 3.334 3.334m0 0 3.333-3.334m-3.333 3.334-3.334 3.333m3.334-3.333 3.333 3.333"}),e.jsx("rect",{width:"180",height:"18",x:"140",y:"51",fill:"color(display-p3 .3 .3 .3)",rx:"4"})]})]}),e.jsx("path",{fill:"#1a1a1a",d:"M32 78.667h1600v40H32z"}),e.jsx("path",{stroke:"color(display-p3 .8 .8 .8)",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.667",d:"M63.111 98.667H49.778m0 0L56.444 92m-6.666 6.667 6.666 6.666m28.889-6.666h13.334m0 0L92 92m6.667 6.667L92 105.333"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",fillRule:"evenodd",d:"M122.278 98.667a5.278 5.278 0 0 1 9.524-3.136l-2.024 2.024h5.555V92l-2.343 2.343a6.944 6.944 0 1 0 .752 7.48.834.834 0 0 0-1.484-.758 5.278 5.278 0 0 1-9.98-2.398Z",clipRule:"evenodd"}),e.jsx("rect",{width:"1360",height:"31.111",x:"152",y:"83.111",fill:"color(display-p3 .2 .2 .2)",rx:"15.556"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",fillRule:"evenodd",d:"M172 93.111a2.778 2.778 0 0 0-2.778 2.778V97h-.555a1.11 1.11 0 0 0-1.111 1.111v5.556c0 .613.497 1.111 1.111 1.111h6.666c.614 0 1.111-.498 1.111-1.111v-5.556A1.11 1.11 0 0 0 175.333 97h-.555v-1.111A2.778 2.778 0 0 0 172 93.11ZM173.667 97v-1.111a1.667 1.667 0 0 0-3.334 0V97h3.334Z",clipRule:"evenodd"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",d:"M195.695 102.373v-4.231c0-.324-.066-.605-.198-.843a1.29 1.29 0 0 0-.577-.562c-.258-.132-.577-.198-.957-.198-.355 0-.666.061-.934.183a1.624 1.624 0 0 0-.623.478 1.05 1.05 0 0 0-.221.638h-1.405c0-.293.076-.585.228-.873.152-.289.37-.55.653-.783a3.271 3.271 0 0 1 1.033-.562 4.072 4.072 0 0 1 1.352-.212c.598 0 1.125.1 1.58.303.461.203.821.51 1.079.92.263.405.395.913.395 1.526v3.828c0 .274.023.565.068.874.051.309.124.575.22.797v.122h-1.466a2.684 2.684 0 0 1-.167-.646 5.26 5.26 0 0 1-.06-.759Zm.243-3.578.015.988h-1.421c-.4 0-.757.032-1.07.098a2.463 2.463 0 0 0-.79.281 1.34 1.34 0 0 0-.487.479 1.273 1.273 0 0 0-.167.661c0 .258.059.493.175.706.117.213.291.382.524.509.238.122.529.182.874.182a2.357 2.357 0 0 0 1.921-.942c.198-.263.304-.519.319-.767l.6.676a2.034 2.034 0 0 1-.288.707 3.402 3.402 0 0 1-1.557 1.329 3.02 3.02 0 0 1-1.2.228c-.557 0-1.046-.109-1.466-.327a2.51 2.51 0 0 1-.973-.873 2.322 2.322 0 0 1-.341-1.238c0-.441.086-.828.258-1.163.172-.339.42-.62.744-.843.324-.228.714-.4 1.17-.516a6.173 6.173 0 0 1 1.527-.175h1.633Zm4.777-1.944v6.927h-1.405v-8.219h1.367l.038 1.292Zm2.567-1.337-.007 1.306a2.035 2.035 0 0 0-.334-.045 3.579 3.579 0 0 0-.35-.015c-.324 0-.61.05-.858.151a1.777 1.777 0 0 0-.63.426c-.173.182-.309.4-.411.653a3.132 3.132 0 0 0-.189.82l-.395.228c0-.496.048-.962.144-1.397.101-.436.256-.82.463-1.155.208-.34.471-.602.79-.79.324-.192.709-.288 1.155-.288.101 0 .217.012.349.038.132.02.223.043.273.068Zm4.436 7.261c.334 0 .643-.068.927-.205.283-.137.516-.324.699-.562.182-.243.286-.519.311-.828h1.337c-.025.486-.19.939-.494 1.36a3.372 3.372 0 0 1-1.177 1.01c-.486.253-1.02.38-1.603.38-.618 0-1.157-.109-1.618-.327a3.213 3.213 0 0 1-1.139-.896 3.998 3.998 0 0 1-.676-1.307 5.504 5.504 0 0 1-.22-1.572v-.319c0-.552.073-1.073.22-1.564a3.99 3.99 0 0 1 .676-1.314c.304-.38.684-.679 1.139-.897.461-.218 1-.326 1.618-.326.643 0 1.205.131 1.686.395.481.258.859.612 1.132 1.063.279.445.431.952.456 1.519h-1.337a2.01 2.01 0 0 0-.289-.919 1.794 1.794 0 0 0-.668-.653 1.867 1.867 0 0 0-.98-.25c-.43 0-.792.085-1.086.257a1.898 1.898 0 0 0-.691.684c-.167.283-.289.6-.365.95a5.214 5.214 0 0 0-.106 1.055v.32c0 .359.035.713.106 1.063.071.349.19.665.357.949.172.284.403.511.691.684.294.167.659.25 1.094.25Zm4.846-10.664h1.413v10.072l-.122 1.595h-1.291V92.111Zm6.965 7.49v.159c0 .597-.071 1.152-.212 1.663-.142.507-.35.947-.623 1.322a2.897 2.897 0 0 1-1.003.873c-.395.208-.848.312-1.359.312-.522 0-.98-.089-1.375-.266a2.707 2.707 0 0 1-.988-.782 4.064 4.064 0 0 1-.645-1.231 7.769 7.769 0 0 1-.327-1.625v-.7c.061-.607.17-1.151.327-1.632a4.05 4.05 0 0 1 .645-1.23 2.6 2.6 0 0 1 .988-.783c.39-.182.843-.273 1.359-.273.517 0 .975.1 1.375.303.4.198.734.481 1.003.851a4 4 0 0 1 .623 1.33c.141.51.212 1.08.212 1.708Zm-1.413.159v-.16c0-.41-.038-.795-.113-1.154a2.993 2.993 0 0 0-.365-.957 1.81 1.81 0 0 0-.661-.653c-.273-.162-.61-.243-1.01-.243-.355 0-.663.06-.927.182a2.014 2.014 0 0 0-.661.493 2.64 2.64 0 0 0-.448.7 3.993 3.993 0 0 0-.25.804v1.831c.081.354.212.696.395 1.025.187.324.435.59.744.798.314.207.701.311 1.162.311.38 0 .704-.076.972-.228.274-.157.494-.372.661-.645.172-.274.299-.59.38-.95.081-.359.121-.744.121-1.154Zm4.717-7.649v11.667h-1.412V92.111h1.412Zm1.884 7.649v-.175c0-.592.086-1.142.258-1.648a3.9 3.9 0 0 1 .745-1.33c.324-.38.716-.673 1.177-.88a3.653 3.653 0 0 1 1.549-.32c.578 0 1.097.107 1.557.32.466.207.861.5 1.185.88.329.375.58.819.752 1.33.172.506.258 1.056.258 1.648v.175c0 .592-.086 1.142-.258 1.648a3.948 3.948 0 0 1-.752 1.329 3.429 3.429 0 0 1-1.177.881c-.456.208-.972.312-1.549.312a3.747 3.747 0 0 1-1.558-.312 3.513 3.513 0 0 1-1.184-.881 4.002 4.002 0 0 1-.745-1.329 5.093 5.093 0 0 1-.258-1.648Zm1.405-.175v.175c0 .41.048.797.144 1.162.097.359.241.678.433.957a2.2 2.2 0 0 0 .737.661c.294.157.636.235 1.025.235.384 0 .722-.078 1.011-.235.293-.162.536-.383.729-.661.192-.279.337-.598.433-.957.101-.365.152-.752.152-1.162v-.175c0-.405-.051-.787-.152-1.147a2.939 2.939 0 0 0-.441-.964 2.086 2.086 0 0 0-.729-.669 2.046 2.046 0 0 0-1.018-.243c-.385 0-.724.081-1.018.243a2.195 2.195 0 0 0-.729.669c-.192.278-.336.6-.433.964a4.43 4.43 0 0 0-.144 1.147Zm9.236-2.392v6.585h-1.413v-8.219h1.337l.076 1.633Zm-.288 2.164-.654-.022a5.603 5.603 0 0 1 .221-1.558c.141-.48.351-.898.63-1.253a2.793 2.793 0 0 1 1.041-.82c.415-.198.896-.296 1.443-.296.385 0 .739.055 1.063.167.324.106.605.276.843.509.238.233.423.531.555.896.131.364.197.805.197 1.322v5.476h-1.405V98.37c0-.43-.073-.775-.22-1.033a1.262 1.262 0 0 0-.608-.562 2.192 2.192 0 0 0-.927-.183c-.415 0-.762.074-1.04.22-.279.148-.501.35-.669.608a2.74 2.74 0 0 0-.364.89 4.948 4.948 0 0 0-.106 1.047Zm5.324-.775-.942.29c.005-.451.079-.885.22-1.3a3.52 3.52 0 0 1 .631-1.109 2.98 2.98 0 0 1 1.025-.767c.405-.192.869-.288 1.39-.288.441 0 .831.058 1.17.174.344.117.633.297.866.54.238.238.418.544.539.919.122.374.182.82.182 1.336v5.401h-1.412v-5.416c0-.46-.074-.817-.221-1.07a1.145 1.145 0 0 0-.607-.54 2.432 2.432 0 0 0-.927-.16c-.309 0-.582.054-.82.16a1.695 1.695 0 0 0-.6.44 1.943 1.943 0 0 0-.373.631 2.341 2.341 0 0 0-.121.76Z"}),e.jsx("rect",{width:"99",height:"18",x:"187",y:"90",fill:"color(display-p3 .3 .3 .3)",rx:"4"}),e.jsx("path",{fill:"color(display-p3 .2 .2 .2)",d:"M32 118.667h1600v1.111H32z"}),e.jsxs("g",{clipPath:"url(#e)",children:[e.jsx("path",{fill:"color(display-p3 .1 .1 .1)",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#1a1a1a",d:"M32 119.778h1600v800H32z"}),e.jsx("path",{fill:"#1a1a1a",d:"M32 119.778h1531.11v91.417H32z"}),e.jsx("rect",{x:"79.723",y:"145.457",width:"119.774",height:"40.059",rx:"8",style:{fill:"color(display-p3 .3 .3 .3)",fillOpacity:"1"}}),e.jsx("path",{fill:"#fff",d:"M248.364 170.986v-11.599h2.101v4.91h5.375v-4.91h2.107v11.599h-2.107v-4.927h-5.375v4.927h-2.101Zm15.891.17c-.849 0-1.586-.187-2.209-.56a3.813 3.813 0 0 1-1.45-1.569c-.339-.672-.509-1.458-.509-2.356 0-.899.17-1.686.509-2.362a3.804 3.804 0 0 1 1.45-1.575c.623-.374 1.36-.56 2.209-.56.85 0 1.586.186 2.209.56a3.758 3.758 0 0 1 1.444 1.575c.344.676.516 1.463.516 2.362 0 .898-.172 1.684-.516 2.356a3.766 3.766 0 0 1-1.444 1.569c-.623.373-1.359.56-2.209.56Zm.012-1.642c.46 0 .845-.127 1.155-.38.31-.256.54-.6.691-1.031.155-.43.232-.909.232-1.438 0-.532-.077-1.014-.232-1.444-.151-.435-.381-.78-.691-1.037-.31-.257-.695-.385-1.155-.385-.472 0-.865.128-1.179.385-.309.257-.541.602-.696 1.037a4.34 4.34 0 0 0-.227 1.444c0 .529.076 1.008.227 1.438.155.431.387.775.696 1.031.314.253.707.38 1.179.38Zm6.216 1.472v-8.699h1.96v1.478h.101c.182-.498.482-.887.901-1.167.419-.283.919-.424 1.501-.424.589 0 1.085.143 1.489.43.408.283.695.67.861 1.161h.091a2.38 2.38 0 0 1 .974-1.155c.461-.291 1.006-.436 1.637-.436.8 0 1.454.253 1.96.758.506.506.759 1.245.759 2.215v5.839h-2.056v-5.522c0-.54-.144-.934-.431-1.184-.287-.253-.638-.379-1.053-.379-.495 0-.882.155-1.161.464-.276.306-.414.705-.414 1.195v5.426h-2.01v-5.607c0-.449-.136-.808-.408-1.076-.268-.268-.619-.402-1.054-.402-.294 0-.562.076-.804.227a1.578 1.578 0 0 0-.578.628 1.97 1.97 0 0 0-.215.94v5.29h-2.05Zm18.484.17c-.872 0-1.626-.181-2.26-.543a3.688 3.688 0 0 1-1.456-1.552c-.339-.672-.509-1.463-.509-2.373 0-.895.17-1.681.509-2.357a3.86 3.86 0 0 1 1.439-1.585c.616-.382 1.339-.572 2.169-.572.536 0 1.042.086 1.518.26.48.17.903.434 1.269.793.37.359.661.816.872 1.371.211.551.317 1.208.317 1.971v.628h-7.13v-1.382h5.165a2.206 2.206 0 0 0-.255-1.047 1.844 1.844 0 0 0-.697-.731 1.95 1.95 0 0 0-1.03-.266c-.42 0-.788.102-1.105.306-.317.2-.564.464-.742.792a2.295 2.295 0 0 0-.266 1.071v1.206c0 .506.093.94.278 1.303.185.359.443.634.775.827.333.189.722.283 1.167.283.298 0 .568-.041.81-.125.242-.086.451-.213.629-.379a1.59 1.59 0 0 0 .402-.617l1.914.215a2.98 2.98 0 0 1-.691 1.325 3.356 3.356 0 0 1-1.291.872c-.525.204-1.125.306-1.801.306Z"}),e.jsx("path",{fill:"color(display-p3 .8 .8 .8)",d:"M342.036 170.986h-1.472l4.259-11.599h1.45l4.259 11.599h-1.472l-3.467-9.764h-.09l-3.467 9.764Zm.544-4.531h5.936v1.246h-5.936v-1.246Zm10.078 4.531v-11.599h1.336v4.282h.114c.098-.151.234-.344.408-.578.177-.238.43-.449.758-.634.333-.189.782-.283 1.348-.283.733 0 1.379.183 1.937.549.559.366.995.885 1.309 1.557.313.673.47 1.465.47 2.379 0 .922-.157 1.72-.47 2.396-.314.672-.748 1.193-1.303 1.563-.555.366-1.195.55-1.92.55-.559 0-1.006-.093-1.342-.278-.336-.189-.595-.402-.776-.64a8.822 8.822 0 0 1-.419-.6h-.159v1.336h-1.291Zm1.314-4.349c0 .657.096 1.236.289 1.738.192.499.474.89.844 1.173.37.279.823.419 1.359.419.559 0 1.025-.147 1.399-.442.377-.298.661-.698.849-1.201a4.7 4.7 0 0 0 .289-1.687c0-.612-.094-1.163-.283-1.654-.185-.495-.466-.886-.844-1.173-.374-.29-.844-.436-1.41-.436-.544 0-1.001.138-1.371.414-.37.272-.649.653-.838 1.144-.189.487-.283 1.055-.283 1.705Zm12.264 4.531c-.786 0-1.475-.187-2.068-.561-.589-.374-1.049-.897-1.382-1.569-.328-.672-.492-1.457-.492-2.356 0-.906.164-1.697.492-2.373.333-.676.793-1.201 1.382-1.575.593-.374 1.282-.56 2.068-.56.785 0 1.472.186 2.061.56.593.374 1.054.899 1.382 1.575.332.676.499 1.467.499 2.373 0 .899-.167 1.684-.499 2.356a3.755 3.755 0 0 1-1.382 1.569c-.589.374-1.276.561-2.061.561Zm0-1.201c.596 0 1.087-.153 1.472-.459.385-.306.67-.708.855-1.206a4.624 4.624 0 0 0 .278-1.62 4.67 4.67 0 0 0-.278-1.626 2.736 2.736 0 0 0-.855-1.217c-.385-.31-.876-.465-1.472-.465-.597 0-1.088.155-1.473.465-.385.309-.67.715-.855 1.217a4.67 4.67 0 0 0-.278 1.626c0 .581.093 1.121.278 1.62.185.498.47.9.855 1.206.385.306.876.459 1.473.459Zm11.783-2.537v-5.143h1.337v8.699h-1.337v-1.472h-.09a2.853 2.853 0 0 1-.952 1.127c-.43.306-.974.459-1.631.459-.544 0-1.027-.119-1.45-.357-.423-.242-.755-.604-.997-1.088-.241-.487-.362-1.1-.362-1.84v-5.528h1.337v5.437c0 .634.177 1.14.532 1.518.359.377.815.566 1.371.566.332 0 .67-.085 1.013-.255.348-.17.638-.43.873-.781.237-.351.356-.799.356-1.342Zm7.888-5.143v1.133h-4.509v-1.133h4.509Zm-3.195-2.084h1.337v8.291c0 .378.055.661.164.85a.854.854 0 0 0 .431.374c.177.06.364.09.56.09.147 0 .268-.007.363-.022l.226-.046.272 1.201a2.739 2.739 0 0 1-.379.102 2.788 2.788 0 0 1-.618.057 2.7 2.7 0 0 1-1.11-.244 2.204 2.204 0 0 1-.895-.742c-.234-.332-.351-.751-.351-1.257v-8.654Zm18.122-.816h1.405v7.68c0 .793-.187 1.501-.561 2.124a3.93 3.93 0 0 1-1.569 1.467c-.676.355-1.469.532-2.379.532-.91 0-1.703-.177-2.378-.532a3.972 3.972 0 0 1-1.575-1.467c-.37-.623-.555-1.331-.555-2.124v-7.68h1.405v7.567c0 .566.124 1.07.373 1.512.25.438.605.783 1.065 1.036.465.25 1.02.374 1.665.374.646 0 1.201-.124 1.665-.374.465-.253.82-.598 1.065-1.036.249-.442.374-.946.374-1.512v-7.567Zm10.51 4.848-1.201.34a2.238 2.238 0 0 0-.334-.583 1.618 1.618 0 0 0-.589-.476c-.25-.125-.569-.187-.958-.187-.532 0-.976.123-1.331.368-.351.242-.526.549-.526.923 0 .333.121.595.362.788.242.192.619.353 1.133.481l1.291.317c.778.189 1.358.478 1.739.867.381.385.572.881.572 1.489 0 .499-.143.944-.43 1.337-.284.393-.68.702-1.19.929-.509.226-1.102.34-1.778.34-.887 0-1.622-.193-2.203-.578-.582-.385-.95-.948-1.105-1.688l1.269-.317c.121.468.349.819.685 1.053.34.234.784.352 1.331.352.623 0 1.118-.133 1.484-.397.37-.268.555-.589.555-.963 0-.302-.106-.555-.317-.759-.211-.207-.536-.362-.974-.464l-1.45-.34c-.797-.189-1.382-.481-1.756-.878-.37-.4-.555-.9-.555-1.501 0-.491.138-.925.414-1.302a2.812 2.812 0 0 1 1.138-.89c.483-.215 1.031-.322 1.642-.322.861 0 1.537.188 2.028.566.495.378.846.876 1.054 1.495Z"})]})]})]}),e.jsxs("defs",{children:[e.jsx("clipPath",{id:"a",children:e.jsx("path",{fill:"#fff",d:"M0 0h384v216H0z"})}),e.jsx("clipPath",{id:"c",children:e.jsx("path",{fill:"#fff",d:"M32 44c0-6.627 5.373-12 12-12h1588v46.667H32V44Z"})}),e.jsx("clipPath",{id:"d",children:e.jsx("path",{fill:"#fff",d:"M128.667 40.889h280v37.778h-280z"})}),e.jsx("clipPath",{id:"e",children:e.jsx("path",{fill:"#fff",d:"M32 119.778h1600v800H32z"})}),e.jsxs("filter",{id:"b",width:"1706.67",height:"994.444",x:"-21.333",y:"-3.556",colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),e.jsx("feOffset",{dy:"17.778"}),e.jsx("feGaussianBlur",{stdDeviation:"26.667"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_53_37"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_53_37",result:"shape"})]})]})]})};os.defaultProps={xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 384 216"};var ls=function(C){return e.jsxs("svg",{...C,children:[e.jsxs("g",{clipPath:"url(#a)",children:[e.jsx("path",{fill:"#1E4DCF",style:{fill:"color(display-p3 .1176 .302 .8118)",fillOpacity:"1"},d:"M0 0h384v216H0z"}),e.jsxs("g",{filter:"url(#b)",children:[e.jsx("path",{d:"M32 44c0-6.627 5.373-12 12-12h760v184H32V44Z",fill:"#fff",style:{fill:"#fff",fillOpacity:"1"},shapeRendering:"crispEdges"}),e.jsx("path",{d:"M76.565 126H32v90h772V43H159.565c-11.017 0-16.525 0-20.822 1.928a22 22 0 0 0-11.065 11.065c-1.928 4.297-1.928 9.806-1.928 20.822 0 16.024 0 24.035-2.805 30.286a31.997 31.997 0 0 1-16.094 16.094C100.6 126 92.589 126 76.565 126Z",fill:"#F1F3F4",style:{fill:"color(display-p3 .9451 .9529 .9569)",fillOpacity:"1"}}),e.jsx("path",{d:"M206.571 72.046h2.991l4.56 7.934h.188l4.559-7.934h2.992l-6.333 10.602V89.5h-2.625v-6.852l-6.332-10.602Zm20.93 17.718c-1.228 0-2.299-.281-3.213-.843-.915-.563-1.625-1.35-2.131-2.361-.506-1.012-.759-2.194-.759-3.546 0-1.358.253-2.545.759-3.562s1.216-1.807 2.131-2.37c.914-.562 1.985-.843 3.213-.843 1.227 0 2.298.28 3.213.843s1.625 1.353 2.13 2.37c.506 1.017.759 2.204.759 3.562 0 1.353-.253 2.534-.759 3.546-.505 1.011-1.215 1.798-2.13 2.36-.915.563-1.986.844-3.213.844Zm.008-2.139c.796 0 1.455-.21 1.978-.63.522-.421.909-.98 1.159-1.68.255-.698.383-1.468.383-2.31 0-.834-.128-1.602-.383-2.3-.25-.705-.637-1.27-1.159-1.697-.523-.426-1.182-.639-1.978-.639-.801 0-1.466.213-1.994.64-.523.426-.912.991-1.168 1.695a6.789 6.789 0 0 0-.375 2.302c0 .84.125 1.61.375 2.31.256.698.645 1.258 1.168 1.678.528.42 1.193.631 1.994.631Zm17.231-3.554v-7.662h2.557V89.5h-2.506v-2.267h-.136c-.301.699-.784 1.281-1.449 1.747-.659.46-1.48.69-2.463.69-.841 0-1.585-.184-2.233-.553-.642-.376-1.148-.93-1.517-1.663-.364-.732-.546-1.639-.546-2.718v-8.327h2.549v8.02c0 .892.247 1.602.741 2.13.495.53 1.137.793 1.926.793.478 0 .952-.119 1.424-.358.477-.238.872-.6 1.184-1.082.318-.483.475-1.097.469-1.841Zm5.981 5.429V76.41h2.463v2.079h.136a3.164 3.164 0 0 1 1.262-1.662 3.608 3.608 0 0 1 2.062-.614 10.87 10.87 0 0 1 1.083.06v2.437a4.633 4.633 0 0 0-.546-.093 5.2 5.2 0 0 0-.784-.06c-.602 0-1.139.128-1.611.383a2.851 2.851 0 0 0-1.517 2.566V89.5h-2.548Zm25.287-12.87c-.091-.806-.466-1.431-1.125-1.874-.659-.45-1.489-.674-2.489-.674-.716 0-1.335.114-1.858.341-.523.222-.929.529-1.219.92a2.173 2.173 0 0 0-.426 1.322c0 .414.097.772.29 1.074.199.3.457.554.776.758.324.199.67.367 1.039.503.37.13.725.239 1.066.324l1.704.443c.557.136 1.128.321 1.713.554.586.233 1.128.54 1.628.92.5.381.904.853 1.21 1.415.313.563.469 1.236.469 2.02 0 .989-.255 1.867-.767 2.634-.506.767-1.241 1.372-2.207 1.815-.96.443-2.122.665-3.486.665-1.307 0-2.438-.208-3.392-.622-.955-.415-1.702-1.003-2.242-1.765-.539-.767-.838-1.676-.894-2.727h2.642c.051.63.255 1.156.613 1.577a3.32 3.32 0 0 0 1.389.929 5.622 5.622 0 0 0 1.867.298c.744 0 1.406-.116 1.986-.35.585-.238 1.045-.567 1.38-.988.336-.426.503-.923.503-1.491 0-.517-.147-.94-.443-1.27-.29-.33-.685-.603-1.185-.819a11.558 11.558 0 0 0-1.679-.57l-2.062-.563c-1.398-.38-2.506-.94-3.324-1.679-.812-.739-1.219-1.716-1.219-2.932 0-1.005.273-1.883.819-2.633.545-.75 1.284-1.333 2.215-1.748.932-.42 1.983-.63 3.154-.63 1.182 0 2.224.207 3.128.622.909.415 1.625.986 2.147 1.713.523.722.796 1.551.819 2.489h-2.54Zm5.721 12.87V76.41h2.548V89.5h-2.548Zm1.287-15.11c-.444 0-.824-.148-1.142-.444a1.44 1.44 0 0 1-.469-1.074c0-.42.156-.778.469-1.074a1.602 1.602 0 0 1 1.142-.451c.443 0 .821.15 1.133.451.318.296.477.654.477 1.074 0 .415-.159.773-.477 1.074-.312.296-.69.443-1.133.443Zm10.8 2.02v2.044h-7.151V76.41h7.151Zm-5.233-3.137h2.548v12.383c0 .495.074.867.222 1.117.148.244.338.412.571.503.239.085.497.127.776.127.204 0 .383-.014.537-.042l.357-.068.461 2.105a4.29 4.29 0 0 1-.631.17 4.998 4.998 0 0 1-1.023.103 4.49 4.49 0 0 1-1.875-.359 3.22 3.22 0 0 1-1.406-1.159c-.358-.522-.537-1.179-.537-1.968V73.273Zm13.553 16.491c-1.289 0-2.4-.275-3.332-.826-.926-.557-1.642-1.339-2.148-2.344-.5-1.012-.75-2.196-.75-3.554 0-1.341.25-2.523.75-3.546.506-1.022 1.21-1.82 2.114-2.395.909-.573 1.971-.86 3.187-.86.739 0 1.455.122 2.148.366a5.213 5.213 0 0 1 1.867 1.15c.551.523.985 1.202 1.304 2.038.318.83.477 1.838.477 3.025v.904h-10.406v-1.91h7.909c0-.67-.137-1.264-.409-1.78a3.098 3.098 0 0 0-1.151-1.236c-.489-.302-1.062-.452-1.722-.452-.715 0-1.34.176-1.875.528a3.55 3.55 0 0 0-1.227 1.364 3.937 3.937 0 0 0-.426 1.815v1.492c0 .875.153 1.619.46 2.233.313.613.747 1.082 1.304 1.406.557.318 1.208.477 1.952.477.483 0 .923-.068 1.321-.205a2.85 2.85 0 0 0 1.031-.63c.29-.278.512-.622.665-1.031l2.412.434a4.367 4.367 0 0 1-1.04 1.867c-.494.528-1.116.94-1.866 1.236-.745.29-1.594.434-2.549.434Zm29.088-17.718V89.5h-2.42l-8.872-12.801h-.162V89.5h-2.634V72.046h2.438l8.881 12.818h.161V72.045h2.608Zm7.447 17.744c-.829 0-1.579-.154-2.25-.46a3.793 3.793 0 0 1-1.594-1.356c-.386-.59-.579-1.315-.579-2.173 0-.739.142-1.347.426-1.824a3.145 3.145 0 0 1 1.151-1.133 5.998 5.998 0 0 1 1.619-.63c.596-.143 1.204-.25 1.824-.325l1.909-.221c.488-.063.844-.162 1.065-.299.222-.136.333-.358.333-.665v-.06c0-.743-.211-1.32-.631-1.73-.415-.408-1.034-.613-1.858-.613-.858 0-1.534.19-2.028.571-.489.375-.827.793-1.015 1.253l-2.395-.546c.285-.795.699-1.437 1.245-1.926a5.043 5.043 0 0 1 1.9-1.074 7.424 7.424 0 0 1 2.259-.34c.523 0 1.077.062 1.662.187a4.86 4.86 0 0 1 1.653.665c.517.324.941.787 1.27 1.39.33.596.494 1.371.494 2.326V89.5h-2.488v-1.79h-.103c-.164.33-.411.654-.741.972-.33.318-.753.582-1.27.792-.517.21-1.136.316-1.858.316Zm.554-2.046c.705 0 1.307-.139 1.807-.417.506-.279.889-.642 1.151-1.091.267-.455.4-.94.4-1.458v-1.687c-.091.09-.267.176-.528.256-.256.074-.549.139-.878.196-.33.05-.651.099-.963.144-.313.04-.574.074-.784.103a6.307 6.307 0 0 0-1.355.315c-.404.148-.728.36-.972.64-.239.272-.358.636-.358 1.09 0 .63.233 1.108.699 1.432.466.318 1.06.477 1.781.477Zm9.301 1.756V76.41h2.446v2.13h.162a3.374 3.374 0 0 1 1.338-1.688c.619-.409 1.36-.613 2.224-.613.875 0 1.608.204 2.199.613.596.41 1.037.972 1.321 1.688h.136a3.687 3.687 0 0 1 1.492-1.67c.682-.421 1.494-.631 2.437-.631 1.188 0 2.157.372 2.907 1.116.755.744 1.133 1.867 1.133 3.367V89.5h-2.548v-8.54c0-.886-.242-1.528-.725-1.926-.483-.398-1.059-.597-1.73-.597-.829 0-1.474.256-1.934.767-.461.506-.691 1.157-.691 1.952V89.5h-2.54v-8.702c0-.71-.221-1.281-.664-1.713-.444-.432-1.02-.647-1.73-.647-.483 0-.929.127-1.339.383-.403.25-.73.6-.98 1.048-.244.45-.366.97-.366 1.56V89.5h-2.548Zm26.853.264c-1.29 0-2.401-.275-3.333-.826-.926-.557-1.642-1.339-2.148-2.344-.5-1.012-.75-2.196-.75-3.554 0-1.341.25-2.523.75-3.546.506-1.022 1.211-1.82 2.114-2.395.909-.573 1.972-.86 3.188-.86.738 0 1.454.122 2.147.366a5.205 5.205 0 0 1 1.867 1.15c.551.523.986 1.202 1.304 2.038.318.83.477 1.838.477 3.025v.904h-10.406v-1.91h7.909c0-.67-.136-1.264-.409-1.78a3.091 3.091 0 0 0-1.151-1.236c-.488-.302-1.062-.452-1.721-.452-.716 0-1.341.176-1.875.528a3.545 3.545 0 0 0-1.228 1.364 3.937 3.937 0 0 0-.426 1.815v1.492c0 .875.154 1.619.46 2.233a3.336 3.336 0 0 0 1.304 1.406c.557.318 1.208.477 1.952.477.483 0 .923-.068 1.321-.205a2.842 2.842 0 0 0 1.031-.63c.29-.278.512-.622.665-1.031l2.412.434a4.367 4.367 0 0 1-1.04 1.867c-.494.528-1.116.94-1.866 1.236-.744.29-1.594.434-2.548.434ZM85 161.333H62.477l7.574-7.46-2.393-2.366L56 163.007l11.658 11.5 2.393-2.367-7.575-7.459H85v-3.348Z",fill:"#242527",style:{fill:"color(display-p3 .1412 .1451 .1529)",fillOpacity:"1"}}),e.jsx("path",{opacity:".4",d:"M106 164.681h22.524l-7.575 7.46 2.393 2.366 11.658-11.5-11.658-11.5-2.393 2.366 7.575 7.46H106v3.348Z",fill:"#242527",style:{fill:"color(display-p3 .1412 .1451 .1529)",fillOpacity:"1"}}),e.jsx("path",{d:"m181.89 164.538-3.225-.385a9.734 9.734 0 0 1-8.859 8.543 9.74 9.74 0 0 1-5.382-18.303 9.738 9.738 0 0 1 12.074 2.387h-4.055v3.25h9.664v-9.664h-3.249v4.187a12.842 12.842 0 0 0-6.064-3.985 12.995 12.995 0 0 0-13.833 4.172 12.994 12.994 0 0 0-1.431 14.376 13.2 13.2 0 0 0 2.286 3.106 12.987 12.987 0 0 0 13.436 3.071 12.992 12.992 0 0 0 8.638-10.74v-.015Z",fill:"#242527",style:{fill:"color(display-p3 .1412 .1451 .1529)",fillOpacity:"1"}}),e.jsx("path",{d:"M208 161.7c0-12.321 0-18.482 2.398-23.188a22.002 22.002 0 0 1 9.614-9.614c4.706-2.398 10.867-2.398 23.188-2.398H804v73H243.2c-12.321 0-18.482 0-23.188-2.398a22.002 22.002 0 0 1-9.614-9.614C208 182.782 208 176.621 208 164.3v-2.6Z",fill:"#fff",style:{fill:"#fff",fillOpacity:"1"}})]}),e.jsx("rect",{x:"229",y:"145",width:"180",height:"36",rx:"8",fill:"#DFE1E5",style:{fill:"color(display-p3 .8745 .8824 .898)",fillOpacity:"1"}}),e.jsx("rect",{x:"203",y:"66",width:"180",height:"36",rx:"8",fill:"#DFE1E5",style:{fill:"color(display-p3 .8745 .8824 .898)",fillOpacity:"1"}})]}),e.jsxs("defs",{children:[e.jsx("clipPath",{id:"a",children:e.jsx("path",{fill:"#fff",style:{fill:"#fff",fillOpacity:"1"},d:"M0 0h384v216H0z"})}),e.jsxs("filter",{id:"b",x:"-21.333",y:"-3.556",width:"878.667",height:"290.667",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),e.jsx("feOffset",{dy:"17.778"}),e.jsx("feGaussianBlur",{stdDeviation:"26.667"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_13_53"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_13_53",result:"shape"})]})]})]})};ls.defaultProps={width:"384",height:"216",fill:"none",xmlns:"http://www.w3.org/2000/svg"};const on=Object.keys(se.SUPPORTED_LANGUAGES).map(x=>({code:x,name:se.SUPPORTED_LANGUAGES[x].nativeName,enName:se.SUPPORTED_LANGUAGES[x].name})),ln=["name","enName","code"];function gt({blocklet:x,onUpdate:C=()=>{},hasPermission:$=!1,...R}){const{api:_,prefix:b,getSessionInHeader:m}=re(),{t:r}=L.useContext(ue),[p,f]=pt({loading:!1,showTransferOwner:!1,showConfigVault:!1}),h=p.loading||!$,{logoUrl:t,logoDarkUrl:l,rectLogoUrl:o,rectLogoDarkUrl:n,faviconUrl:s,splashPortraitUrl:c,splashLandscapeUrl:a,ogImageUrl:i}=zs({blocklet:x});if(mt(x.status))return null;const u=x.environments.find(v=>v.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_LANGUAGES),g=x.environments.find(v=>v.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_URL),y=x.environments.find(v=>v.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_COPYRIGHT_OWNER),k=x.environments.find(v=>v.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_COPYRIGHT_YEAR),w=[{key:se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_NAME,title:r("blocklet.config.name"),description:r("blocklet.config.nameDesc"),value:x.environments.find(v=>v.key==="BLOCKLET_APP_NAME").value},{key:se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_DESCRIPTION,title:r("blocklet.config.description"),description:r("blocklet.config.descriptionDesc"),value:x.environments.find(v=>v.key==="BLOCKLET_APP_DESCRIPTION").value},{key:se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_URL,title:r("blocklet.config.appUrl"),description:r("blocklet.config.appUrlDesc"),value:g?g.value:""},{key:se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_COPYRIGHT_OWNER,title:r("blocklet.config.copyrightOwner"),description:r("blocklet.config.copyrightDesc"),value:y?y.value:""},{key:se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_COPYRIGHT_YEAR,title:r("blocklet.config.copyrightYear"),description:r("blocklet.config.copyrightDesc"),value:k?k.value:""}],d=async(v,j)=>{const S=[{key:v,value:j}];try{f({loading:!0});const{blocklet:O}=await _.configBlocklet({input:{did:x.meta.did,configs:S}});C(O)}catch(O){Z.error(O.message)}finally{f({loading:!1})}};return e.jsxs(hn,{...R,children:[e.jsxs(A,{children:[e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:r("blocklet.config.baseInfo")}),e.jsx(J,{variant:"body2",sx:{color:"text.secondary"},children:r("blocklet.config.baseInfoDesc")})]}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),w.map(v=>e.jsxs(e.Fragment,{children:[e.jsx(M,{title:v.title,desc:v.description,children:e.jsx(yr,{style:{marginTop:0},disabled:h,loading:p.loading,initialValue:vr.escapeTag(v.value),placeholder:v.title,onSubmit:j=>d(v.key,j)})},v.key),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}})]})),e.jsx(M,{title:r("blocklet.config.languages"),desc:r("blocklet.config.languagesDesc"),children:e.jsx(rs,{style:{marginTop:0},disabled:h,loading:p.loading,options:on,noEmpty:!0,initialValue:u?u.value.split(","):["en","zh"],onSubmit:v=>d("BLOCKLET_APP_LANGUAGES",v),helperText:r("blocklet.config.selectLanguagesTip"),placeholder:r("blocklet.config.languagesSearch"),filterKeys:ln,renderLabel:(v,j)=>j.name===j.enName?`${j.name} (${v.toUpperCase()})`:`${j.name}, ${j.enName} (${v.toUpperCase()})`})}),e.jsxs(A,{sx:{mt:6},children:[e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:r("blocklet.config.logoSettings")}),e.jsx(J,{variant:"body2",sx:{color:"text.secondary"},children:r("blocklet.config.logoSettingsDesc")}),e.jsx(J,{variant:"body2",sx:{color:"warning.main"},children:r("blocklet.config.changeImageTip")})]}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsxs(fn,{children:[e.jsx(M,{title:r("blocklet.config.logoSquare"),desc:`${r("blocklet.config.logoSquareDesc")}
|
|
9
|
-
${r("blocklet.config.logoDesc",{width:512,height:512,maxSize:5})}`,link:"https://www.didwallet.io/",children:e.jsxs(A,{sx:{display:"flex",gap:3,flexWrap:"wrap"},children:[e.jsxs(A,{sx:{alignSelf:"flex-start",display:"flex",flexDirection:"column",gap:3},children:[e.jsx(J,{variant:"body2",children:r("common.lightMode")}),e.jsx(A,{sx:{width:307,height:173,position:"relative",borderRadius:"4px",overflow:"hidden"},children:e.jsx(ct,{name:x.environments.find(v=>v.key==="BLOCKLET_APP_NAME").value,icon:t,did:x.meta.did})}),e.jsx(_e,{did:x.meta.did,width:80,type:"square",prefix:b,url:t,enabled:$,headers:m,aspectRatio:1,children:e.jsx(Y,{variant:"outlined",color:"primary",children:r("common.upload")})})]}),e.jsxs(A,{sx:{alignSelf:"flex-start",display:"flex",flexDirection:"column",gap:3},children:[e.jsx(J,{variant:"body2",children:r("common.darkMode")}),e.jsx(A,{sx:{width:307,height:173,position:"relative",borderRadius:"4px",overflow:"hidden"},children:e.jsx(ct,{dark:!0,name:x.environments.find(v=>v.key==="BLOCKLET_APP_NAME").value,icon:l,did:x.meta.did})}),e.jsx(_e,{did:x.meta.did,width:80,type:"square-dark",prefix:b,url:l,enabled:$,headers:m,aspectRatio:1,children:e.jsx(Y,{variant:"outlined",color:"primary",children:r("common.upload")})})]})]})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:r("blocklet.config.logoRect"),desc:`${r("blocklet.config.logoRectDesc")}`,children:e.jsxs(A,{sx:{display:"flex",gap:3,flexWrap:"wrap"},children:[e.jsxs(A,{sx:{alignSelf:"flex-start",display:"flex",flexDirection:"column",gap:3},children:[e.jsx(J,{variant:"body2",children:r("common.lightMode")}),e.jsxs(A,{sx:{width:307,height:173,position:"relative",borderRadius:"4px",overflow:"hidden"},children:[o?e.jsx(ns,{viewBox:"0 0 384 216",sx:{width:"100%",height:"100%"}}):e.jsx(is,{viewBox:"0 0 384 216",sx:{width:"100%",height:"100%"}}),o&&e.jsx(A,{component:"img",src:o,alt:"app-logo",sx:{position:"absolute",top:112,left:64,maxHeight:40,maxWidth:120}})]}),e.jsx(_e,{did:x.meta.did,width:80,height:"auto",type:"rect",prefix:b,url:o,enabled:$,headers:m,aspectRatio:NaN,minWidth:80,minHeight:120,children:e.jsx(Y,{variant:"outlined",children:r("common.upload")})})]}),e.jsxs(A,{sx:{alignSelf:"flex-start",display:"flex",flexDirection:"column",gap:3},children:[e.jsx(J,{variant:"body2",children:r("common.darkMode")}),e.jsxs(A,{sx:{width:307,height:173,position:"relative",borderRadius:"4px",overflow:"hidden"},children:[n?e.jsx(as,{viewBox:"0 0 384 216",sx:{width:"100%",height:"100%"}}):e.jsx(os,{viewBox:"0 0 384 216",sx:{width:"100%",height:"100%"}}),n&&e.jsx(A,{component:"img",src:n,alt:"app-logo",sx:{position:"absolute",top:112,left:64,maxHeight:40,maxWidth:120}})]}),e.jsx(_e,{did:x.meta.did,width:80,height:"auto",type:"rect-dark",prefix:b,url:n,enabled:$,headers:m,aspectRatio:NaN,minWidth:80,minHeight:120,children:e.jsx(Y,{variant:"outlined",children:r("common.upload")})})]})]})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:r("blocklet.config.logoFavicon"),desc:`${r("blocklet.config.logoFaviconDesc")}
|
|
10
|
-
${r("blocklet.config.logoDesc",{width:512,height:512,maxSize:5})}`,children:e.jsxs(A,{sx:{alignSelf:"flex-start",display:"flex",flexDirection:"column",gap:3},children:[e.jsxs(A,{sx:{width:307,height:173,position:"relative",borderRadius:"4px",overflow:"hidden"},children:[e.jsx(ls,{viewBox:"0 0 384 216",sx:{width:"100%",height:"100%"}}),s&&e.jsx(A,{component:"img",src:s,alt:"app-logo",sx:{position:"absolute",top:62,left:146,width:44,height:44,borderRadius:"12px"}})]}),e.jsx(_e,{did:x.meta.did,width:80,type:"favicon",prefix:b,url:s,enabled:$,headers:m,aspectRatio:1,children:e.jsx(Y,{variant:"outlined",children:r("common.upload")})})]})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:r("blocklet.config.splashPortrait"),desc:r("blocklet.config.splashDesc"),link:"https://www.arcsphere.io/",children:e.jsxs(A,{sx:{display:"flex",gap:3,alignSelf:"flex-start",".uploader-wrapper":{borderRadius:0},flexWrap:"wrap"},children:[e.jsx(_e,{did:x.meta.did,height:400,width:225,type:"splash-portrait",prefix:b,url:c,enabled:$,headers:m,aspectRatio:9/16,minWidth:900,minHeight:1e3,allowSVG:!1}),e.jsx(A,{sx:{width:"100%",maxWidth:400,aspectRatio:"16 / 9",position:"relative"},children:e.jsx(_e,{did:x.meta.did,height:"100%",width:"100%",type:"splash-landscape",prefix:b,url:a,enabled:$,headers:m,aspectRatio:16/9,minWidth:1600,minHeight:900,allowSVG:!1})})]})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:r("blocklet.config.ogImage"),desc:r("blocklet.config.ogImageDesc"),children:e.jsx(A,{sx:{width:"100%",maxWidth:400,aspectRatio:"40 / 21",position:"relative",alignSelf:"flex-start",".uploader-wrapper":{borderRadius:0}},children:e.jsx(_e,{did:x.meta.did,height:"100%",width:"100%",type:"og-image",prefix:b,url:i,enabled:$,headers:m,aspectRatio:40/21,minWidth:1200,minHeight:630,allowSVG:!1})})})]})]})}const cn=Ee(gt,"mutate_blocklets"),dn=Ee(gt,"",ft);function un(x){const{inService:C}=re();return C?e.jsx(dn,{...x}):e.jsx(cn,{...x})}gt.propTypes={blocklet:T.object.isRequired,onUpdate:T.func,hasPermission:T.bool};const hn=ve(A)`
|
|
11
|
-
max-width: 1536px;
|
|
12
|
-
|
|
13
|
-
.config-form {
|
|
14
|
-
flex-grow: 1;
|
|
15
|
-
overflow-y: auto;
|
|
16
|
-
|
|
17
|
-
${x=>x.theme.breakpoints.down("md")} {
|
|
18
|
-
width: 100%;
|
|
19
|
-
flex-shrink: 0;
|
|
20
|
-
transform: translate(0, 0);
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.config-item {
|
|
25
|
-
display: flex;
|
|
26
|
-
align-items: center;
|
|
27
|
-
justify-content: space-between;
|
|
28
|
-
margin: 16px 0;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.config-label {
|
|
32
|
-
font-weight: bold;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.config-desc {
|
|
36
|
-
font-weight: normal;
|
|
37
|
-
font-size: 12px;
|
|
38
|
-
color: #666;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.form-item {
|
|
42
|
-
margin-top: 0;
|
|
43
|
-
}
|
|
44
|
-
`,fn=ve(ie)``,mn=localStorage.getItem("enableDebug")==="true";function cs({onChange:x=()=>{},disabled:C=!1,loading:$=!1,inService:R=!1}){const{t:_}=ae(),{api:b,session:m}=Bt(),{blocklet:r}=oe(),[p,f]=Hs({newAppSk:"",isConnectOpen:!1,confirmDialogOpen:!1}),h=()=>f({isConnectOpen:!1}),t=()=>{if(Nt.isInProgress(r.status)){Z.error(_("blocklet.error.isInProgress"));return}f({confirmDialogOpen:!0})};return e.jsxs(e.Fragment,{children:[e.jsx(M,{title:_("blocklet.config.migrate.button"),desc:_("blocklet.config.migrate.description"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsxs(Y,{style:{flexShrink:0},variant:"contained",color:"primary",size:"small","data-cy":"config-did",disabled:C||$,onClick:t,children:[e.jsx(Wr,{style:{fontSize:"1.3em",marginRight:4}}),_("blocklet.config.migrate.button")]})})}),e.jsxs(e.Fragment,{children:[p.isConnectOpen&&e.jsx(Ft,{popup:!0,open:p.isConnectOpen,forceConnected:!1,saveConnect:!1,action:"rotate-key-pair",checkFn:b.get,checkTimeout:5*60*1e3,onSuccess:()=>{x(),R&&m.logout(),h()},extraParams:{appDid:r.appDid},messages:{title:_("setup.keyPair.title"),scan:_("setup.keyPair.scan"),confirm:_("setup.keyPair.confirm"),success:_("setup.keyPair.success")},onClose:h}),p.confirmDialogOpen&&e.jsx(Bs,{title:e.jsx(J,{sx:{fontSize:"20px",fontWeight:"500"},children:_("blocklet.config.migrate.title")}),description:e.jsx(J,{sx:{fontSize:"14px",color:"#9397A1"},children:_("blocklet.config.migrate.confirm")}),confirm:_("common.confirm"),cancel:_("common.cancel"),onConfirm:()=>f({confirmDialogOpen:!1,isConnectOpen:!0}),onCancel:()=>f({confirmDialogOpen:!1})})]})]})}cs.propTypes={onChange:T.func,disabled:T.bool,loading:T.bool,inService:T.bool};function ds({onCancel:x,onSuccess:C,onError:$=()=>{}}){const{api:R}=L.useContext(Fs),[_,b]=L.useState(!1),{t:m,locale:r}=ae(),[p,f]=L.useState(""),[h,t]=L.useState(!1),[l,o]=L.useState(0),[n,s]=L.useState(""),{endpoint:c}=Ve(),[a,i]=L.useState(!1),u=d=>{f(null),b(!0);try{s(d.result),o(k.length-1)}catch(v){const j=it(v);f(j),$(v)}finally{b(!1)}},g=()=>{t(!0),o(1)},y=()=>{t(!1),o(0)},k=[{body:e.jsxs(A,{children:[e.jsx(J,{children:m("team.transferApp.transferDialog.tips.progress")}),e.jsx(J,{sx:{mt:3,mb:2},children:m("team.transferApp.transferDialog.tips.newOwnerPermissions")})]}),cancel:m("common.cancel"),confirm:m("team.transferApp.transferDialog.createTransferLink"),onCancel:x,onConfirm:g},{cancel:m("common.cancel"),confirm:m("team.transferApp.transferDialog.createTransferLink"),body:()=>e.jsx(Ft,{action:"transfer-app-owner",open:h,locale:r,checkFn:R.get,onClose:y,onSuccess:u,checkTimeout:5*60*1e3,extraParams:{},messages:{title:m("team.transferApp.connectDialog.title"),scan:m("team.transferApp.connectDialog.scan"),confirm:m("team.transferApp.connectDialog.confirm"),success:m("team.transferApp.connectDialog.success")},popup:!0})},{body:()=>{const d=Ns({transferId:n.transferId,endpoint:c});return e.jsxs(e.Fragment,{children:[e.jsx(A,{component:Ae,dangerouslySetInnerHTML:{__html:m("team.transferApp.transferDialog.createSuccessTip1")}}),e.jsx(A,{component:Ae,sx:{mt:2},children:e.jsx(Ae,{children:m("team.transferApp.transferDialog.createSuccessTip3")})}),e.jsxs(A,{children:[e.jsx(A,{component:Ae,sx:{mt:2},children:e.jsx(Ae,{children:m("team.transferApp.transferDialog.createSuccessTip2",{expireDate:Zs(n.expireDate,r)})})}),e.jsx(A,{sx:{my:1},children:e.jsx($r,{children:d})})]}),e.jsx("div",{children:e.jsx(K,{value:"end",control:e.jsx(Te,{checked:a,onChange:v=>i(v.target.checked)}),label:m("team.transferApp.transferDialog.iKnow"),labelPlacement:"end"})})]})},confirm:m("common.confirm"),onConfirm:C}],w=k[l];return e.jsxs(ke,{title:e.jsx(Ae,{className:"title",children:m("team.transferApp.transferDialog.title")}),fullWidth:!0,open:!0,showCloseButton:!1,actions:e.jsxs(e.Fragment,{children:[w.cancel&&e.jsx(te,{onClick:w.onCancel,color:"inherit",children:w.cancel}),e.jsxs(te,{onClick:w.onConfirm,color:"error",disabled:_||l===k.length-1&&!a,variant:"contained",autoFocus:!0,children:[_&&e.jsx(Ie,{size:16}),w.confirm]})]}),children:[e.jsx(Vs,{component:"div",children:typeof w.body=="function"?w.body():w.body}),!!p&&e.jsx(Us,{severity:"error",variant:"icon",children:p})]})}ds.propTypes={onCancel:T.func.isRequired,onSuccess:T.func.isRequired,onError:T.func};const Ae=ve.div`
|
|
45
|
-
font-size: 16px;
|
|
46
|
-
font-weight: bold;
|
|
47
|
-
&.title {
|
|
48
|
-
font-size: 20px;
|
|
49
|
-
}
|
|
50
|
-
`;var Me={},Ye={exports:{}},Et;function pn(){return Et||(Et=1,function(x,C){(function($,R){x.exports=R()})(self,()=>{return $={7629:(_,b,m)=>{const r=m(375),p=m(8571),f=m(9474),h=m(1687),t=m(8652),l=m(8160),o=m(3292),n=m(6354),s=m(8901),c=m(9708),a=m(6914),i=m(2294),u=m(6133),g=m(1152),y=m(8863),k=m(2036),w={Base:class{constructor(d){this.type=d,this.$_root=null,this._definition={},this._reset()}_reset(){this._ids=new i.Ids,this._preferences=null,this._refs=new u.Manager,this._cache=null,this._valids=null,this._invalids=null,this._flags={},this._rules=[],this._singleRules=new Map,this.$_terms={},this.$_temp={ruleset:null,whens:{}}}describe(){return r(typeof c.describe=="function","Manifest functionality disabled"),c.describe(this)}allow(...d){return l.verifyFlat(d,"allow"),this._values(d,"_valids")}alter(d){r(d&&typeof d=="object"&&!Array.isArray(d),"Invalid targets argument"),r(!this._inRuleset(),"Cannot set alterations inside a ruleset");const v=this.clone();v.$_terms.alterations=v.$_terms.alterations||[];for(const j in d){const S=d[j];r(typeof S=="function","Alteration adjuster for",j,"must be a function"),v.$_terms.alterations.push({target:j,adjuster:S})}return v.$_temp.ruleset=!1,v}artifact(d){return r(d!==void 0,"Artifact cannot be undefined"),r(!this._cache,"Cannot set an artifact with a rule cache"),this.$_setFlag("artifact",d)}cast(d){return r(d===!1||typeof d=="string","Invalid to value"),r(d===!1||this._definition.cast[d],"Type",this.type,"does not support casting to",d),this.$_setFlag("cast",d===!1?void 0:d)}default(d,v){return this._default("default",d,v)}description(d){return r(d&&typeof d=="string","Description must be a non-empty string"),this.$_setFlag("description",d)}empty(d){const v=this.clone();return d!==void 0&&(d=v.$_compile(d,{override:!1})),v.$_setFlag("empty",d,{clone:!1})}error(d){return r(d,"Missing error"),r(d instanceof Error||typeof d=="function","Must provide a valid Error object or a function"),this.$_setFlag("error",d)}example(d,v={}){return r(d!==void 0,"Missing example"),l.assertOptions(v,["override"]),this._inner("examples",d,{single:!0,override:v.override})}external(d,v){return typeof d=="object"&&(r(!v,"Cannot combine options with description"),v=d.description,d=d.method),r(typeof d=="function","Method must be a function"),r(v===void 0||v&&typeof v=="string","Description must be a non-empty string"),this._inner("externals",{method:d,description:v},{single:!0})}failover(d,v){return this._default("failover",d,v)}forbidden(){return this.presence("forbidden")}id(d){return d?(r(typeof d=="string","id must be a non-empty string"),r(/^[^\.]+$/.test(d),"id cannot contain period character"),this.$_setFlag("id",d)):this.$_setFlag("id",void 0)}invalid(...d){return this._values(d,"_invalids")}label(d){return r(d&&typeof d=="string","Label name must be a non-empty string"),this.$_setFlag("label",d)}meta(d){return r(d!==void 0,"Meta cannot be undefined"),this._inner("metas",d,{single:!0})}note(...d){r(d.length,"Missing notes");for(const v of d)r(v&&typeof v=="string","Notes must be non-empty strings");return this._inner("notes",d)}only(d=!0){return r(typeof d=="boolean","Invalid mode:",d),this.$_setFlag("only",d)}optional(){return this.presence("optional")}prefs(d){r(d,"Missing preferences"),r(d.context===void 0,"Cannot override context"),r(d.externals===void 0,"Cannot override externals"),r(d.warnings===void 0,"Cannot override warnings"),r(d.debug===void 0,"Cannot override debug"),l.checkPreferences(d);const v=this.clone();return v._preferences=l.preferences(v._preferences,d),v}presence(d){return r(["optional","required","forbidden"].includes(d),"Unknown presence mode",d),this.$_setFlag("presence",d)}raw(d=!0){return this.$_setFlag("result",d?"raw":void 0)}result(d){return r(["raw","strip"].includes(d),"Unknown result mode",d),this.$_setFlag("result",d)}required(){return this.presence("required")}strict(d){const v=this.clone(),j=d!==void 0&&!d;return v._preferences=l.preferences(v._preferences,{convert:j}),v}strip(d=!0){return this.$_setFlag("result",d?"strip":void 0)}tag(...d){r(d.length,"Missing tags");for(const v of d)r(v&&typeof v=="string","Tags must be non-empty strings");return this._inner("tags",d)}unit(d){return r(d&&typeof d=="string","Unit name must be a non-empty string"),this.$_setFlag("unit",d)}valid(...d){l.verifyFlat(d,"valid");const v=this.allow(...d);return v.$_setFlag("only",!!v._valids,{clone:!1}),v}when(d,v){const j=this.clone();j.$_terms.whens||(j.$_terms.whens=[]);const S=o.when(j,d,v);if(!["any","link"].includes(j.type)){const O=S.is?[S]:S.switch;for(const P of O)r(!P.then||P.then.type==="any"||P.then.type===j.type,"Cannot combine",j.type,"with",P.then&&P.then.type),r(!P.otherwise||P.otherwise.type==="any"||P.otherwise.type===j.type,"Cannot combine",j.type,"with",P.otherwise&&P.otherwise.type)}return j.$_terms.whens.push(S),j.$_mutateRebuild()}cache(d){r(!this._inRuleset(),"Cannot set caching inside a ruleset"),r(!this._cache,"Cannot override schema cache"),r(this._flags.artifact===void 0,"Cannot cache a rule with an artifact");const v=this.clone();return v._cache=d||t.provider.provision(),v.$_temp.ruleset=!1,v}clone(){const d=Object.create(Object.getPrototypeOf(this));return this._assign(d)}concat(d){r(l.isSchema(d),"Invalid schema object"),r(this.type==="any"||d.type==="any"||d.type===this.type,"Cannot merge type",this.type,"with another type:",d.type),r(!this._inRuleset(),"Cannot concatenate onto a schema with open ruleset"),r(!d._inRuleset(),"Cannot concatenate a schema with open ruleset");let v=this.clone();if(this.type==="any"&&d.type!=="any"){const j=d.clone();for(const S of Object.keys(v))S!=="type"&&(j[S]=v[S]);v=j}v._ids.concat(d._ids),v._refs.register(d,u.toSibling),v._preferences=v._preferences?l.preferences(v._preferences,d._preferences):d._preferences,v._valids=k.merge(v._valids,d._valids,d._invalids),v._invalids=k.merge(v._invalids,d._invalids,d._valids);for(const j of d._singleRules.keys())v._singleRules.has(j)&&(v._rules=v._rules.filter(S=>S.keep||S.name!==j),v._singleRules.delete(j));for(const j of d._rules)d._definition.rules[j.method].multi||v._singleRules.set(j.name,j),v._rules.push(j);if(v._flags.empty&&d._flags.empty){v._flags.empty=v._flags.empty.concat(d._flags.empty);const j=Object.assign({},d._flags);delete j.empty,h(v._flags,j)}else if(d._flags.empty){v._flags.empty=d._flags.empty;const j=Object.assign({},d._flags);delete j.empty,h(v._flags,j)}else h(v._flags,d._flags);for(const j in d.$_terms){const S=d.$_terms[j];S?v.$_terms[j]?v.$_terms[j]=v.$_terms[j].concat(S):v.$_terms[j]=S.slice():v.$_terms[j]||(v.$_terms[j]=S)}return this.$_root._tracer&&this.$_root._tracer._combine(v,[this,d]),v.$_mutateRebuild()}extend(d){return r(!d.base,"Cannot extend type with another base"),s.type(this,d)}extract(d){return d=Array.isArray(d)?d:d.split("."),this._ids.reach(d)}fork(d,v){r(!this._inRuleset(),"Cannot fork inside a ruleset");let j=this;for(let S of[].concat(d))S=Array.isArray(S)?S:S.split("."),j=j._ids.fork(S,v,j);return j.$_temp.ruleset=!1,j}rule(d){const v=this._definition;l.assertOptions(d,Object.keys(v.modifiers)),r(this.$_temp.ruleset!==!1,"Cannot apply rules to empty ruleset or the last rule added does not support rule properties");const j=this.$_temp.ruleset===null?this._rules.length-1:this.$_temp.ruleset;r(j>=0&&j<this._rules.length,"Cannot apply rules to empty ruleset");const S=this.clone();for(let O=j;O<S._rules.length;++O){const P=S._rules[O],D=p(P);for(const I in d)v.modifiers[I](D,d[I]),r(D.name===P.name,"Cannot change rule name");S._rules[O]=D,S._singleRules.get(D.name)===P&&S._singleRules.set(D.name,D)}return S.$_temp.ruleset=!1,S.$_mutateRebuild()}get ruleset(){r(!this._inRuleset(),"Cannot start a new ruleset without closing the previous one");const d=this.clone();return d.$_temp.ruleset=d._rules.length,d}get $(){return this.ruleset}tailor(d){d=[].concat(d),r(!this._inRuleset(),"Cannot tailor inside a ruleset");let v=this;if(this.$_terms.alterations)for(const{target:j,adjuster:S}of this.$_terms.alterations)d.includes(j)&&(v=S(v),r(l.isSchema(v),"Alteration adjuster for",j,"failed to return a schema object"));return v=v.$_modify({each:j=>j.tailor(d),ref:!1}),v.$_temp.ruleset=!1,v.$_mutateRebuild()}tracer(){return g.location?g.location(this):this}validate(d,v){return y.entry(d,this,v)}validateAsync(d,v){return y.entryAsync(d,this,v)}$_addRule(d){typeof d=="string"&&(d={name:d}),r(d&&typeof d=="object","Invalid options"),r(d.name&&typeof d.name=="string","Invalid rule name");for(const P in d)r(P[0]!=="_","Cannot set private rule properties");const v=Object.assign({},d);v._resolve=[],v.method=v.method||v.name;const j=this._definition.rules[v.method],S=v.args;r(j,"Unknown rule",v.method);const O=this.clone();if(S){r(Object.keys(S).length===1||Object.keys(S).length===this._definition.rules[v.name].args.length,"Invalid rule definition for",this.type,v.name);for(const P in S){let D=S[P];if(j.argsByName){const I=j.argsByName.get(P);if(I.ref&&l.isResolvable(D))v._resolve.push(P),O.$_mutateRegister(D);else if(I.normalize&&(D=I.normalize(D),S[P]=D),I.assert){const B=l.validateArg(D,P,I);r(!B,B,"or reference")}}D!==void 0?S[P]=D:delete S[P]}}return j.multi||(O._ruleRemove(v.name,{clone:!1}),O._singleRules.set(v.name,v)),O.$_temp.ruleset===!1&&(O.$_temp.ruleset=null),j.priority?O._rules.unshift(v):O._rules.push(v),O}$_compile(d,v){return o.schema(this.$_root,d,v)}$_createError(d,v,j,S,O,P={}){const D=P.flags!==!1?this._flags:{},I=P.messages?a.merge(this._definition.messages,P.messages):this._definition.messages;return new n.Report(d,v,j,D,I,S,O)}$_getFlag(d){return this._flags[d]}$_getRule(d){return this._singleRules.get(d)}$_mapLabels(d){return d=Array.isArray(d)?d:d.split("."),this._ids.labels(d)}$_match(d,v,j,S){(j=Object.assign({},j)).abortEarly=!0,j._externals=!1,v.snapshot();const O=!y.validate(d,this,v,j,S).errors;return v.restore(),O}$_modify(d){return l.assertOptions(d,["each","once","ref","schema"]),i.schema(this,d)||this}$_mutateRebuild(){return r(!this._inRuleset(),"Cannot add this rule inside a ruleset"),this._refs.reset(),this._ids.reset(),this.$_modify({each:(d,{source:v,name:j,path:S,key:O})=>{const P=this._definition[v][j]&&this._definition[v][j].register;P!==!1&&this.$_mutateRegister(d,{family:P,key:O})}}),this._definition.rebuild&&this._definition.rebuild(this),this.$_temp.ruleset=!1,this}$_mutateRegister(d,{family:v,key:j}={}){this._refs.register(d,v),this._ids.register(d,{key:j})}$_property(d){return this._definition.properties[d]}$_reach(d){return this._ids.reach(d)}$_rootReferences(){return this._refs.roots()}$_setFlag(d,v,j={}){r(d[0]==="_"||!this._inRuleset(),"Cannot set flag inside a ruleset");const S=this._definition.flags[d]||{};if(f(v,S.default)&&(v=void 0),f(v,this._flags[d]))return this;const O=j.clone!==!1?this.clone():this;return v!==void 0?(O._flags[d]=v,O.$_mutateRegister(v)):delete O._flags[d],d[0]!=="_"&&(O.$_temp.ruleset=!1),O}$_parent(d,...v){return this[d][l.symbols.parent].call(this,...v)}$_validate(d,v,j){return y.validate(d,this,v,j)}_assign(d){d.type=this.type,d.$_root=this.$_root,d.$_temp=Object.assign({},this.$_temp),d.$_temp.whens={},d._ids=this._ids.clone(),d._preferences=this._preferences,d._valids=this._valids&&this._valids.clone(),d._invalids=this._invalids&&this._invalids.clone(),d._rules=this._rules.slice(),d._singleRules=p(this._singleRules,{shallow:!0}),d._refs=this._refs.clone(),d._flags=Object.assign({},this._flags),d._cache=null,d.$_terms={};for(const v in this.$_terms)d.$_terms[v]=this.$_terms[v]?this.$_terms[v].slice():null;d.$_super={};for(const v in this.$_super)d.$_super[v]=this._super[v].bind(d);return d}_bare(){const d=this.clone();d._reset();const v=d._definition.terms;for(const j in v){const S=v[j];d.$_terms[j]=S.init}return d.$_mutateRebuild()}_default(d,v,j={}){return l.assertOptions(j,"literal"),r(v!==void 0,"Missing",d,"value"),r(typeof v=="function"||!j.literal,"Only function value supports literal option"),typeof v=="function"&&j.literal&&(v={[l.symbols.literal]:!0,literal:v}),this.$_setFlag(d,v)}_generate(d,v,j){if(!this.$_terms.whens)return{schema:this};const S=[],O=[];for(let I=0;I<this.$_terms.whens.length;++I){const B=this.$_terms.whens[I];if(B.concat){S.push(B.concat),O.push(`${I}.concat`);continue}const N=B.ref?B.ref.resolve(d,v,j):d,q=B.is?[B]:B.switch,z=O.length;for(let F=0;F<q.length;++F){const{is:V,then:le,otherwise:me}=q[F],be=`${I}${B.switch?"."+F:""}`;if(V.$_match(N,v.nest(V,`${be}.is`),j)){if(le){const De=v.localize([...v.path,`${be}.then`],v.ancestors,v.schemas),{schema:We,id:Le}=le._generate(d,De,j);S.push(We),O.push(`${be}.then${Le?`(${Le})`:""}`);break}}else if(me){const De=v.localize([...v.path,`${be}.otherwise`],v.ancestors,v.schemas),{schema:We,id:Le}=me._generate(d,De,j);S.push(We),O.push(`${be}.otherwise${Le?`(${Le})`:""}`);break}}if(B.break&&O.length>z)break}const P=O.join(", ");if(v.mainstay.tracer.debug(v,"rule","when",P),!P)return{schema:this};if(!v.mainstay.tracer.active&&this.$_temp.whens[P])return{schema:this.$_temp.whens[P],id:P};let D=this;this._definition.generate&&(D=this._definition.generate(this,d,v,j));for(const I of S)D=D.concat(I);return this.$_root._tracer&&this.$_root._tracer._combine(D,[this,...S]),this.$_temp.whens[P]=D,{schema:D,id:P}}_inner(d,v,j={}){r(!this._inRuleset(),`Cannot set ${d} inside a ruleset`);const S=this.clone();return S.$_terms[d]&&!j.override||(S.$_terms[d]=[]),j.single?S.$_terms[d].push(v):S.$_terms[d].push(...v),S.$_temp.ruleset=!1,S}_inRuleset(){return this.$_temp.ruleset!==null&&this.$_temp.ruleset!==!1}_ruleRemove(d,v={}){if(!this._singleRules.has(d))return this;const j=v.clone!==!1?this.clone():this;j._singleRules.delete(d);const S=[];for(let O=0;O<j._rules.length;++O){const P=j._rules[O];P.name!==d||P.keep?S.push(P):j._inRuleset()&&O<j.$_temp.ruleset&&--j.$_temp.ruleset}return j._rules=S,j}_values(d,v){l.verifyFlat(d,v.slice(1,-1));const j=this.clone(),S=d[0]===l.symbols.override;if(S&&(d=d.slice(1)),!j[v]&&d.length?j[v]=new k:S&&(j[v]=d.length?new k:null,j.$_mutateRebuild()),!j[v])return j;S&&j[v].override();for(const O of d){r(O!==void 0,"Cannot call allow/valid/invalid with undefined"),r(O!==l.symbols.override,"Override must be the first value");const P=v==="_invalids"?"_valids":"_invalids";j[P]&&(j[P].remove(O),j[P].length||(r(v==="_valids"||!j._flags.only,"Setting invalid value",O,"leaves schema rejecting all values due to previous valid rule"),j[P]=null)),j[v].add(O,j._refs)}return j}}};w.Base.prototype[l.symbols.any]={version:l.version,compile:o.compile,root:"$_root"},w.Base.prototype.isImmutable=!0,w.Base.prototype.deny=w.Base.prototype.invalid,w.Base.prototype.disallow=w.Base.prototype.invalid,w.Base.prototype.equal=w.Base.prototype.valid,w.Base.prototype.exist=w.Base.prototype.required,w.Base.prototype.not=w.Base.prototype.invalid,w.Base.prototype.options=w.Base.prototype.prefs,w.Base.prototype.preferences=w.Base.prototype.prefs,_.exports=new w.Base},8652:(_,b,m)=>{const r=m(375),p=m(8571),f=m(8160),h={max:1e3,supported:new Set(["undefined","boolean","number","string"])};b.provider={provision:t=>new h.Cache(t)},h.Cache=class{constructor(t={}){f.assertOptions(t,["max"]),r(t.max===void 0||t.max&&t.max>0&&isFinite(t.max),"Invalid max cache size"),this._max=t.max||h.max,this._map=new Map,this._list=new h.List}get length(){return this._map.size}set(t,l){if(t!==null&&!h.supported.has(typeof t))return;let o=this._map.get(t);if(o)return o.value=l,void this._list.first(o);o=this._list.unshift({key:t,value:l}),this._map.set(t,o),this._compact()}get(t){const l=this._map.get(t);if(l)return this._list.first(l),p(l.value)}_compact(){if(this._map.size>this._max){const t=this._list.pop();this._map.delete(t.key)}}},h.List=class{constructor(){this.tail=null,this.head=null}unshift(t){return t.next=null,t.prev=this.head,this.head&&(this.head.next=t),this.head=t,this.tail||(this.tail=t),t}first(t){t!==this.head&&(this._remove(t),this.unshift(t))}pop(){return this._remove(this.tail)}_remove(t){const{next:l,prev:o}=t;return l.prev=o,o&&(o.next=l),t===this.tail&&(this.tail=l),t.prev=null,t.next=null,t}}},8160:(_,b,m)=>{const r=m(375),p=m(7916),f=m(5934);let h,t;const l={isoDate:/^(?:[-+]\d{2})?(?:\d{4}(?!\d{2}\b))(?:(-?)(?:(?:0[1-9]|1[0-2])(?:\1(?:[12]\d|0[1-9]|3[01]))?|W(?:[0-4]\d|5[0-2])(?:-?[1-7])?|(?:00[1-9]|0[1-9]\d|[12]\d{2}|3(?:[0-5]\d|6[1-6])))(?![T]$|[T][\d]+Z$)(?:[T\s](?:(?:(?:[01]\d|2[0-3])(?:(:?)[0-5]\d)?|24\:?00)(?:[.,]\d+(?!:))?)(?:\2[0-5]\d(?:[.,]\d+)?)?(?:[Z]|(?:[+-])(?:[01]\d|2[0-3])(?::?[0-5]\d)?)?)?)?$/};b.version=f.version,b.defaults={abortEarly:!0,allowUnknown:!1,artifacts:!1,cache:!0,context:null,convert:!0,dateFormat:"iso",errors:{escapeHtml:!1,label:"path",language:null,render:!0,stack:!1,wrap:{label:'"',array:"[]"}},externals:!0,messages:{},nonEnumerables:!1,noDefaults:!1,presence:"optional",skipFunctions:!1,stripUnknown:!1,warnings:!1},b.symbols={any:Symbol.for("@hapi/joi/schema"),arraySingle:Symbol("arraySingle"),deepDefault:Symbol("deepDefault"),errors:Symbol("errors"),literal:Symbol("literal"),override:Symbol("override"),parent:Symbol("parent"),prefs:Symbol("prefs"),ref:Symbol("ref"),template:Symbol("template"),values:Symbol("values")},b.assertOptions=function(o,n,s="Options"){r(o&&typeof o=="object"&&!Array.isArray(o),"Options must be of type object");const c=Object.keys(o).filter(a=>!n.includes(a));r(c.length===0,`${s} contain unknown keys: ${c}`)},b.checkPreferences=function(o){t=t||m(3378);const n=t.preferences.validate(o);if(n.error)throw new p([n.error.details[0].message])},b.compare=function(o,n,s){switch(s){case"=":return o===n;case">":return o>n;case"<":return o<n;case">=":return o>=n;case"<=":return o<=n}},b.default=function(o,n){return o===void 0?n:o},b.isIsoDate=function(o){return l.isoDate.test(o)},b.isNumber=function(o){return typeof o=="number"&&!isNaN(o)},b.isResolvable=function(o){return!!o&&(o[b.symbols.ref]||o[b.symbols.template])},b.isSchema=function(o,n={}){const s=o&&o[b.symbols.any];return!!s&&(r(n.legacy||s.version===b.version,"Cannot mix different versions of joi schemas"),!0)},b.isValues=function(o){return o[b.symbols.values]},b.limit=function(o){return Number.isSafeInteger(o)&&o>=0},b.preferences=function(o,n){h=h||m(6914),o=o||{},n=n||{};const s=Object.assign({},o,n);return n.errors&&o.errors&&(s.errors=Object.assign({},o.errors,n.errors),s.errors.wrap=Object.assign({},o.errors.wrap,n.errors.wrap)),n.messages&&(s.messages=h.compile(n.messages,o.messages)),delete s[b.symbols.prefs],s},b.tryWithPath=function(o,n,s={}){try{return o()}catch(c){throw c.path!==void 0?c.path=n+"."+c.path:c.path=n,s.append&&(c.message=`${c.message} (${c.path})`),c}},b.validateArg=function(o,n,{assert:s,message:c}){if(b.isSchema(s)){const a=s.validate(o);return a.error?a.error.message:void 0}if(!s(o))return n?`${n} ${c}`:c},b.verifyFlat=function(o,n){for(const s of o)r(!Array.isArray(s),"Method no longer accepts array arguments:",n)}},3292:(_,b,m)=>{const r=m(375),p=m(8160),f=m(6133),h={};b.schema=function(t,l,o={}){p.assertOptions(o,["appendPath","override"]);try{return h.schema(t,l,o)}catch(n){throw o.appendPath&&n.path!==void 0&&(n.message=`${n.message} (${n.path})`),n}},h.schema=function(t,l,o){r(l!==void 0,"Invalid undefined schema"),Array.isArray(l)&&(r(l.length,"Invalid empty array schema"),l.length===1&&(l=l[0]));const n=(s,...c)=>o.override!==!1?s.valid(t.override,...c):s.valid(...c);if(h.simple(l))return n(t,l);if(typeof l=="function")return t.custom(l);if(r(typeof l=="object","Invalid schema content:",typeof l),p.isResolvable(l))return n(t,l);if(p.isSchema(l))return l;if(Array.isArray(l)){for(const s of l)if(!h.simple(s))return t.alternatives().try(...l);return n(t,...l)}return l instanceof RegExp?t.string().regex(l):l instanceof Date?n(t.date(),l):(r(Object.getPrototypeOf(l)===Object.getPrototypeOf({}),"Schema can only contain plain objects"),t.object().keys(l))},b.ref=function(t,l){return f.isRef(t)?t:f.create(t,l)},b.compile=function(t,l,o={}){p.assertOptions(o,["legacy"]);const n=l&&l[p.symbols.any];if(n)return r(o.legacy||n.version===p.version,"Cannot mix different versions of joi schemas:",n.version,p.version),l;if(typeof l!="object"||!o.legacy)return b.schema(t,l,{appendPath:!0});const s=h.walk(l);return s?s.compile(s.root,l):b.schema(t,l,{appendPath:!0})},h.walk=function(t){if(typeof t!="object")return null;if(Array.isArray(t)){for(const o of t){const n=h.walk(o);if(n)return n}return null}const l=t[p.symbols.any];if(l)return{root:t[l.root],compile:l.compile};r(Object.getPrototypeOf(t)===Object.getPrototypeOf({}),"Schema can only contain plain objects");for(const o in t){const n=h.walk(t[o]);if(n)return n}return null},h.simple=function(t){return t===null||["boolean","string","number"].includes(typeof t)},b.when=function(t,l,o){if(o===void 0&&(r(l&&typeof l=="object","Missing options"),o=l,l=f.create(".")),Array.isArray(o)&&(o={switch:o}),p.assertOptions(o,["is","not","then","otherwise","switch","break"]),p.isSchema(l))return r(o.is===void 0,'"is" can not be used with a schema condition'),r(o.not===void 0,'"not" can not be used with a schema condition'),r(o.switch===void 0,'"switch" can not be used with a schema condition'),h.condition(t,{is:l,then:o.then,otherwise:o.otherwise,break:o.break});if(r(f.isRef(l)||typeof l=="string","Invalid condition:",l),r(o.not===void 0||o.is===void 0,'Cannot combine "is" with "not"'),o.switch===void 0){let s=o;o.not!==void 0&&(s={is:o.not,then:o.otherwise,otherwise:o.then,break:o.break});let c=s.is!==void 0?t.$_compile(s.is):t.$_root.invalid(null,!1,0,"").required();return r(s.then!==void 0||s.otherwise!==void 0,'options must have at least one of "then", "otherwise", or "switch"'),r(s.break===void 0||s.then===void 0||s.otherwise===void 0,"Cannot specify then, otherwise, and break all together"),o.is===void 0||f.isRef(o.is)||p.isSchema(o.is)||(c=c.required()),h.condition(t,{ref:b.ref(l),is:c,then:s.then,otherwise:s.otherwise,break:s.break})}r(Array.isArray(o.switch),'"switch" must be an array'),r(o.is===void 0,'Cannot combine "switch" with "is"'),r(o.not===void 0,'Cannot combine "switch" with "not"'),r(o.then===void 0,'Cannot combine "switch" with "then"');const n={ref:b.ref(l),switch:[],break:o.break};for(let s=0;s<o.switch.length;++s){const c=o.switch[s],a=s===o.switch.length-1;p.assertOptions(c,a?["is","then","otherwise"]:["is","then"]),r(c.is!==void 0,'Switch statement missing "is"'),r(c.then!==void 0,'Switch statement missing "then"');const i={is:t.$_compile(c.is),then:t.$_compile(c.then)};if(f.isRef(c.is)||p.isSchema(c.is)||(i.is=i.is.required()),a){r(o.otherwise===void 0||c.otherwise===void 0,'Cannot specify "otherwise" inside and outside a "switch"');const u=o.otherwise!==void 0?o.otherwise:c.otherwise;u!==void 0&&(r(n.break===void 0,"Cannot specify both otherwise and break"),i.otherwise=t.$_compile(u))}n.switch.push(i)}return n},h.condition=function(t,l){for(const o of["then","otherwise"])l[o]===void 0?delete l[o]:l[o]=t.$_compile(l[o]);return l}},6354:(_,b,m)=>{const r=m(5688),p=m(8160),f=m(3328);b.Report=class{constructor(h,t,l,o,n,s,c){if(this.code=h,this.flags=o,this.messages=n,this.path=s.path,this.prefs=c,this.state=s,this.value=t,this.message=null,this.template=null,this.local=l||{},this.local.label=b.label(this.flags,this.state,this.prefs,this.messages),this.value===void 0||this.local.hasOwnProperty("value")||(this.local.value=this.value),this.path.length){const a=this.path[this.path.length-1];typeof a!="object"&&(this.local.key=a)}}_setTemplate(h){if(this.template=h,!this.flags.label&&this.path.length===0){const t=this._template(this.template,"root");t&&(this.local.label=t)}}toString(){if(this.message)return this.message;const h=this.code;if(!this.prefs.errors.render)return this.code;const t=this._template(this.template)||this._template(this.prefs.messages)||this._template(this.messages);return t===void 0?`Error code "${h}" is not defined, your custom type is missing the correct messages definition`:(this.message=t.render(this.value,this.state,this.prefs,this.local,{errors:this.prefs.errors,messages:[this.prefs.messages,this.messages]}),this.prefs.errors.label||(this.message=this.message.replace(/^"" /,"").trim()),this.message)}_template(h,t){return b.template(this.value,h,t||this.code,this.state,this.prefs)}},b.path=function(h){let t="";for(const l of h)typeof l!="object"&&(typeof l=="string"?(t&&(t+="."),t+=l):t+=`[${l}]`);return t},b.template=function(h,t,l,o,n){if(!t)return;if(f.isTemplate(t))return l!=="root"?t:null;let s=n.errors.language;if(p.isResolvable(s)&&(s=s.resolve(h,o,n)),s&&t[s]){if(t[s][l]!==void 0)return t[s][l];if(t[s]["*"]!==void 0)return t[s]["*"]}return t[l]?t[l]:t["*"]},b.label=function(h,t,l,o){if(!l.errors.label)return"";if(h.label)return h.label;let n=t.path;return l.errors.label==="key"&&t.path.length>1&&(n=t.path.slice(-1)),b.path(n)||b.template(null,l.messages,"root",t,l)||o&&b.template(null,o,"root",t,l)||"value"},b.process=function(h,t,l){if(!h)return null;const{override:o,message:n,details:s}=b.details(h);if(o)return o;if(l.errors.stack)return new b.ValidationError(n,s,t);const c=Error.stackTraceLimit;Error.stackTraceLimit=0;const a=new b.ValidationError(n,s,t);return Error.stackTraceLimit=c,a},b.details=function(h,t={}){let l=[];const o=[];for(const n of h){if(n instanceof Error){if(t.override!==!1)return{override:n};const c=n.toString();l.push(c),o.push({message:c,type:"override",context:{error:n}});continue}const s=n.toString();l.push(s),o.push({message:s,path:n.path.filter(c=>typeof c!="object"),type:n.code,context:n.local})}return l.length>1&&(l=[...new Set(l)]),{message:l.join(". "),details:o}},b.ValidationError=class extends Error{constructor(h,t,l){super(h),this._original=l,this.details=t}static isError(h){return h instanceof b.ValidationError}},b.ValidationError.prototype.isJoi=!0,b.ValidationError.prototype.name="ValidationError",b.ValidationError.prototype.annotate=r.error},8901:(_,b,m)=>{const r=m(375),p=m(8571),f=m(8160),h=m(6914),t={};b.type=function(l,o){const n=Object.getPrototypeOf(l),s=p(n),c=l._assign(Object.create(s)),a=Object.assign({},o);delete a.base,s._definition=a;const i=n._definition||{};a.messages=h.merge(i.messages,a.messages),a.properties=Object.assign({},i.properties,a.properties),c.type=a.type,a.flags=Object.assign({},i.flags,a.flags);const u=Object.assign({},i.terms);if(a.terms)for(const w in a.terms){const d=a.terms[w];r(c.$_terms[w]===void 0,"Invalid term override for",a.type,w),c.$_terms[w]=d.init,u[w]=d}a.terms=u,a.args||(a.args=i.args),a.prepare=t.prepare(a.prepare,i.prepare),a.coerce&&(typeof a.coerce=="function"&&(a.coerce={method:a.coerce}),a.coerce.from&&!Array.isArray(a.coerce.from)&&(a.coerce={method:a.coerce.method,from:[].concat(a.coerce.from)})),a.coerce=t.coerce(a.coerce,i.coerce),a.validate=t.validate(a.validate,i.validate);const g=Object.assign({},i.rules);if(a.rules)for(const w in a.rules){const d=a.rules[w];r(typeof d=="object","Invalid rule definition for",a.type,w);let v=d.method;if(v===void 0&&(v=function(){return this.$_addRule(w)}),v&&(r(!s[w],"Rule conflict in",a.type,w),s[w]=v),r(!g[w],"Rule conflict in",a.type,w),g[w]=d,d.alias){const j=[].concat(d.alias);for(const S of j)s[S]=d.method}d.args&&(d.argsByName=new Map,d.args=d.args.map(j=>(typeof j=="string"&&(j={name:j}),r(!d.argsByName.has(j.name),"Duplicated argument name",j.name),f.isSchema(j.assert)&&(j.assert=j.assert.strict().label(j.name)),d.argsByName.set(j.name,j),j)))}a.rules=g;const y=Object.assign({},i.modifiers);if(a.modifiers)for(const w in a.modifiers){r(!s[w],"Rule conflict in",a.type,w);const d=a.modifiers[w];r(typeof d=="function","Invalid modifier definition for",a.type,w);const v=function(j){return this.rule({[w]:j})};s[w]=v,y[w]=d}if(a.modifiers=y,a.overrides){s._super=n,c.$_super={};for(const w in a.overrides)r(n[w],"Cannot override missing",w),a.overrides[w][f.symbols.parent]=n[w],c.$_super[w]=n[w].bind(c);Object.assign(s,a.overrides)}a.cast=Object.assign({},i.cast,a.cast);const k=Object.assign({},i.manifest,a.manifest);return k.build=t.build(a.manifest&&a.manifest.build,i.manifest&&i.manifest.build),a.manifest=k,a.rebuild=t.rebuild(a.rebuild,i.rebuild),c},t.build=function(l,o){return l&&o?function(n,s){return o(l(n,s),s)}:l||o},t.coerce=function(l,o){return l&&o?{from:l.from&&o.from?[...new Set([...l.from,...o.from])]:null,method(n,s){let c;if((!o.from||o.from.includes(typeof n))&&(c=o.method(n,s),c)){if(c.errors||c.value===void 0)return c;n=c.value}if(!l.from||l.from.includes(typeof n)){const a=l.method(n,s);if(a)return a}return c}}:l||o},t.prepare=function(l,o){return l&&o?function(n,s){const c=l(n,s);if(c){if(c.errors||c.value===void 0)return c;n=c.value}return o(n,s)||c}:l||o},t.rebuild=function(l,o){return l&&o?function(n){o(n),l(n)}:l||o},t.validate=function(l,o){return l&&o?function(n,s){const c=o(n,s);if(c){if(c.errors&&(!Array.isArray(c.errors)||c.errors.length))return c;n=c.value}return l(n,s)||c}:l||o}},5107:(_,b,m)=>{const r=m(375),p=m(8571),f=m(8652),h=m(8160),t=m(3292),l=m(6354),o=m(8901),n=m(9708),s=m(6133),c=m(3328),a=m(1152);let i;const u={types:{alternatives:m(4946),any:m(8068),array:m(546),boolean:m(4937),date:m(7500),function:m(390),link:m(8785),number:m(3832),object:m(8966),string:m(7417),symbol:m(8826)},aliases:{alt:"alternatives",bool:"boolean",func:"function"},root:function(){const g={_types:new Set(Object.keys(u.types))};for(const y of g._types)g[y]=function(...k){return r(!k.length||["alternatives","link","object"].includes(y),"The",y,"type does not allow arguments"),u.generate(this,u.types[y],k)};for(const y of["allow","custom","disallow","equal","exist","forbidden","invalid","not","only","optional","options","prefs","preferences","required","strip","valid","when"])g[y]=function(...k){return this.any()[y](...k)};Object.assign(g,u.methods);for(const y in u.aliases){const k=u.aliases[y];g[y]=g[k]}return g.x=g.expression,a.setup&&a.setup(g),g}};u.methods={ValidationError:l.ValidationError,version:h.version,cache:f.provider,assert(g,y,...k){u.assert(g,y,!0,k)},attempt:(g,y,...k)=>u.assert(g,y,!1,k),build(g){return r(typeof n.build=="function","Manifest functionality disabled"),n.build(this,g)},checkPreferences(g){h.checkPreferences(g)},compile(g,y){return t.compile(this,g,y)},defaults(g){r(typeof g=="function","modifier must be a function");const y=Object.assign({},this);for(const k of y._types){const w=g(y[k]());r(h.isSchema(w),"modifier must return a valid schema object"),y[k]=function(...d){return u.generate(this,w,d)}}return y},expression:(...g)=>new c(...g),extend(...g){h.verifyFlat(g,"extend"),i=i||m(3378),r(g.length,"You need to provide at least one extension"),this.assert(g,i.extensions);const y=Object.assign({},this);y._types=new Set(y._types);for(let k of g){typeof k=="function"&&(k=k(y)),this.assert(k,i.extension);const w=u.expandExtension(k,y);for(const d of w){r(y[d.type]===void 0||y._types.has(d.type),"Cannot override name",d.type);const v=d.base||this.any(),j=o.type(v,d);y._types.add(d.type),y[d.type]=function(...S){return u.generate(this,j,S)}}}return y},isError:l.ValidationError.isError,isExpression:c.isTemplate,isRef:s.isRef,isSchema:h.isSchema,in:(...g)=>s.in(...g),override:h.symbols.override,ref:(...g)=>s.create(...g),types(){const g={};for(const y of this._types)g[y]=this[y]();for(const y in u.aliases)g[y]=this[y]();return g}},u.assert=function(g,y,k,w){const d=w[0]instanceof Error||typeof w[0]=="string"?w[0]:null,v=d!==null?w[1]:w[0],j=y.validate(g,h.preferences({errors:{stack:!0}},v||{}));let S=j.error;if(!S)return j.value;if(d instanceof Error)throw d;const O=k&&typeof S.annotate=="function"?S.annotate():S.message;throw S instanceof l.ValidationError==0&&(S=p(S)),S.message=d?`${d} ${O}`:O,S},u.generate=function(g,y,k){return r(g,"Must be invoked on a Joi instance."),y.$_root=g,y._definition.args&&k.length?y._definition.args(y,...k):y},u.expandExtension=function(g,y){if(typeof g.type=="string")return[g];const k=[];for(const w of y._types)if(g.type.test(w)){const d=Object.assign({},g);d.type=w,d.base=y[w](),k.push(d)}return k},_.exports=u.root()},6914:(_,b,m)=>{const r=m(375),p=m(8571),f=m(3328);b.compile=function(h,t){if(typeof h=="string")return r(!t,"Cannot set single message string"),new f(h);if(f.isTemplate(h))return r(!t,"Cannot set single message template"),h;r(typeof h=="object"&&!Array.isArray(h),"Invalid message options"),t=t?p(t):{};for(let l in h){const o=h[l];if(l==="root"||f.isTemplate(o)){t[l]=o;continue}if(typeof o=="string"){t[l]=new f(o);continue}r(typeof o=="object"&&!Array.isArray(o),"Invalid message for",l);const n=l;for(l in t[n]=t[n]||{},o){const s=o[l];l==="root"||f.isTemplate(s)?t[n][l]=s:(r(typeof s=="string","Invalid message for",l,"in",n),t[n][l]=new f(s))}}return t},b.decompile=function(h){const t={};for(let l in h){const o=h[l];if(l==="root"){t.root=o;continue}if(f.isTemplate(o)){t[l]=o.describe({compact:!0});continue}const n=l;for(l in t[n]={},o){const s=o[l];l!=="root"?t[n][l]=s.describe({compact:!0}):t[n].root=s}}return t},b.merge=function(h,t){if(!h)return b.compile(t);if(!t)return h;if(typeof t=="string")return new f(t);if(f.isTemplate(t))return t;const l=p(h);for(let o in t){const n=t[o];if(o==="root"||f.isTemplate(n)){l[o]=n;continue}if(typeof n=="string"){l[o]=new f(n);continue}r(typeof n=="object"&&!Array.isArray(n),"Invalid message for",o);const s=o;for(o in l[s]=l[s]||{},n){const c=n[o];o==="root"||f.isTemplate(c)?l[s][o]=c:(r(typeof c=="string","Invalid message for",o,"in",s),l[s][o]=new f(c))}}return l}},2294:(_,b,m)=>{const r=m(375),p=m(8160),f=m(6133),h={};b.Ids=h.Ids=class{constructor(){this._byId=new Map,this._byKey=new Map,this._schemaChain=!1}clone(){const t=new h.Ids;return t._byId=new Map(this._byId),t._byKey=new Map(this._byKey),t._schemaChain=this._schemaChain,t}concat(t){t._schemaChain&&(this._schemaChain=!0);for(const[l,o]of t._byId.entries())r(!this._byKey.has(l),"Schema id conflicts with existing key:",l),this._byId.set(l,o);for(const[l,o]of t._byKey.entries())r(!this._byId.has(l),"Schema key conflicts with existing id:",l),this._byKey.set(l,o)}fork(t,l,o){const n=this._collect(t);n.push({schema:o});const s=n.shift();let c={id:s.id,schema:l(s.schema)};r(p.isSchema(c.schema),"adjuster function failed to return a joi schema type");for(const a of n)c={id:a.id,schema:h.fork(a.schema,c.id,c.schema)};return c.schema}labels(t,l=[]){const o=t[0],n=this._get(o);if(!n)return[...l,...t].join(".");const s=t.slice(1);return l=[...l,n.schema._flags.label||o],s.length?n.schema._ids.labels(s,l):l.join(".")}reach(t,l=[]){const o=t[0],n=this._get(o);r(n,"Schema does not contain path",[...l,...t].join("."));const s=t.slice(1);return s.length?n.schema._ids.reach(s,[...l,o]):n.schema}register(t,{key:l}={}){if(!t||!p.isSchema(t))return;(t.$_property("schemaChain")||t._ids._schemaChain)&&(this._schemaChain=!0);const o=t._flags.id;if(o){const n=this._byId.get(o);r(!n||n.schema===t,"Cannot add different schemas with the same id:",o),r(!this._byKey.has(o),"Schema id conflicts with existing key:",o),this._byId.set(o,{schema:t,id:o})}l&&(r(!this._byKey.has(l),"Schema already contains key:",l),r(!this._byId.has(l),"Schema key conflicts with existing id:",l),this._byKey.set(l,{schema:t,id:l}))}reset(){this._byId=new Map,this._byKey=new Map,this._schemaChain=!1}_collect(t,l=[],o=[]){const n=t[0],s=this._get(n);r(s,"Schema does not contain path",[...l,...t].join(".")),o=[s,...o];const c=t.slice(1);return c.length?s.schema._ids._collect(c,[...l,n],o):o}_get(t){return this._byId.get(t)||this._byKey.get(t)}},h.fork=function(t,l,o){const n=b.schema(t,{each:(s,{key:c})=>{if(l===(s._flags.id||c))return o},ref:!1});return n?n.$_mutateRebuild():t},b.schema=function(t,l){let o;for(const n in t._flags){if(n[0]==="_")continue;const s=h.scan(t._flags[n],{source:"flags",name:n},l);s!==void 0&&(o=o||t.clone(),o._flags[n]=s)}for(let n=0;n<t._rules.length;++n){const s=t._rules[n],c=h.scan(s.args,{source:"rules",name:s.name},l);if(c!==void 0){o=o||t.clone();const a=Object.assign({},s);a.args=c,o._rules[n]=a,o._singleRules.get(s.name)===s&&o._singleRules.set(s.name,a)}}for(const n in t.$_terms){if(n[0]==="_")continue;const s=h.scan(t.$_terms[n],{source:"terms",name:n},l);s!==void 0&&(o=o||t.clone(),o.$_terms[n]=s)}return o},h.scan=function(t,l,o,n,s){const c=n||[];if(t===null||typeof t!="object")return;let a;if(Array.isArray(t)){for(let i=0;i<t.length;++i){const u=l.source==="terms"&&l.name==="keys"&&t[i].key,g=h.scan(t[i],l,o,[i,...c],u);g!==void 0&&(a=a||t.slice(),a[i]=g)}return a}if(o.schema!==!1&&p.isSchema(t)||o.ref!==!1&&f.isRef(t)){const i=o.each(t,{...l,path:c,key:s});return i===t?void 0:i}for(const i in t){if(i[0]==="_")continue;const u=h.scan(t[i],l,o,[i,...c],s);u!==void 0&&(a=a||Object.assign({},t),a[i]=u)}return a}},6133:(_,b,m)=>{const r=m(375),p=m(8571),f=m(9621),h=m(8160);let t;const l={symbol:Symbol("ref"),defaults:{adjust:null,in:!1,iterables:null,map:null,separator:".",type:"value"}};b.create=function(o,n={}){r(typeof o=="string","Invalid reference key:",o),h.assertOptions(n,["adjust","ancestor","in","iterables","map","prefix","render","separator"]),r(!n.prefix||typeof n.prefix=="object","options.prefix must be of type object");const s=Object.assign({},l.defaults,n);delete s.prefix;const c=s.separator,a=l.context(o,c,n.prefix);if(s.type=a.type,o=a.key,s.type==="value")if(a.root&&(r(!c||o[0]!==c,"Cannot specify relative path with root prefix"),s.ancestor="root",o||(o=null)),c&&c===o)o=null,s.ancestor=0;else if(s.ancestor!==void 0)r(!c||!o||o[0]!==c,"Cannot combine prefix with ancestor option");else{const[i,u]=l.ancestor(o,c);u&&(o=o.slice(u))===""&&(o=null),s.ancestor=i}return s.path=c?o===null?[]:o.split(c):[o],new l.Ref(s)},b.in=function(o,n={}){return b.create(o,{...n,in:!0})},b.isRef=function(o){return!!o&&!!o[h.symbols.ref]},l.Ref=class{constructor(o){r(typeof o=="object","Invalid reference construction"),h.assertOptions(o,["adjust","ancestor","in","iterables","map","path","render","separator","type","depth","key","root","display"]),r([!1,void 0].includes(o.separator)||typeof o.separator=="string"&&o.separator.length===1,"Invalid separator"),r(!o.adjust||typeof o.adjust=="function","options.adjust must be a function"),r(!o.map||Array.isArray(o.map),"options.map must be an array"),r(!o.map||!o.adjust,"Cannot set both map and adjust options"),Object.assign(this,l.defaults,o),r(this.type==="value"||this.ancestor===void 0,"Non-value references cannot reference ancestors"),Array.isArray(this.map)&&(this.map=new Map(this.map)),this.depth=this.path.length,this.key=this.path.length?this.path.join(this.separator):null,this.root=this.path[0],this.updateDisplay()}resolve(o,n,s,c,a={}){return r(!this.in||a.in,"Invalid in() reference usage"),this.type==="global"?this._resolve(s.context,n,a):this.type==="local"?this._resolve(c,n,a):this.ancestor?this.ancestor==="root"?this._resolve(n.ancestors[n.ancestors.length-1],n,a):(r(this.ancestor<=n.ancestors.length,"Invalid reference exceeds the schema root:",this.display),this._resolve(n.ancestors[this.ancestor-1],n,a)):this._resolve(o,n,a)}_resolve(o,n,s){let c;if(this.type==="value"&&n.mainstay.shadow&&s.shadow!==!1&&(c=n.mainstay.shadow.get(this.absolute(n))),c===void 0&&(c=f(o,this.path,{iterables:this.iterables,functions:!0})),this.adjust&&(c=this.adjust(c)),this.map){const a=this.map.get(c);a!==void 0&&(c=a)}return n.mainstay&&n.mainstay.tracer.resolve(n,this,c),c}toString(){return this.display}absolute(o){return[...o.path.slice(0,-this.ancestor),...this.path]}clone(){return new l.Ref(this)}describe(){const o={path:this.path};this.type!=="value"&&(o.type=this.type),this.separator!=="."&&(o.separator=this.separator),this.type==="value"&&this.ancestor!==1&&(o.ancestor=this.ancestor),this.map&&(o.map=[...this.map]);for(const n of["adjust","iterables","render"])this[n]!==null&&this[n]!==void 0&&(o[n]=this[n]);return this.in!==!1&&(o.in=!0),{ref:o}}updateDisplay(){const o=this.key!==null?this.key:"";if(this.type!=="value")return void(this.display=`ref:${this.type}:${o}`);if(!this.separator)return void(this.display=`ref:${o}`);if(!this.ancestor)return void(this.display=`ref:${this.separator}${o}`);if(this.ancestor==="root")return void(this.display=`ref:root:${o}`);if(this.ancestor===1)return void(this.display=`ref:${o||".."}`);const n=new Array(this.ancestor+1).fill(this.separator).join("");this.display=`ref:${n}${o||""}`}},l.Ref.prototype[h.symbols.ref]=!0,b.build=function(o){return(o=Object.assign({},l.defaults,o)).type==="value"&&o.ancestor===void 0&&(o.ancestor=1),new l.Ref(o)},l.context=function(o,n,s={}){if(o=o.trim(),s){const c=s.global===void 0?"$":s.global;if(c!==n&&o.startsWith(c))return{key:o.slice(c.length),type:"global"};const a=s.local===void 0?"#":s.local;if(a!==n&&o.startsWith(a))return{key:o.slice(a.length),type:"local"};const i=s.root===void 0?"/":s.root;if(i!==n&&o.startsWith(i))return{key:o.slice(i.length),type:"value",root:!0}}return{key:o,type:"value"}},l.ancestor=function(o,n){if(!n)return[1,0];if(o[0]!==n)return[1,0];if(o[1]!==n)return[0,1];let s=2;for(;o[s]===n;)++s;return[s-1,s]},b.toSibling=0,b.toParent=1,b.Manager=class{constructor(){this.refs=[]}register(o,n){if(o)if(n=n===void 0?b.toParent:n,Array.isArray(o))for(const s of o)this.register(s,n);else if(h.isSchema(o))for(const s of o._refs.refs)s.ancestor-n>=0&&this.refs.push({ancestor:s.ancestor-n,root:s.root});else b.isRef(o)&&o.type==="value"&&o.ancestor-n>=0&&this.refs.push({ancestor:o.ancestor-n,root:o.root}),t=t||m(3328),t.isTemplate(o)&&this.register(o.refs(),n)}get length(){return this.refs.length}clone(){const o=new b.Manager;return o.refs=p(this.refs),o}reset(){this.refs=[]}roots(){return this.refs.filter(o=>!o.ancestor).map(o=>o.root)}}},3378:(_,b,m)=>{const r=m(5107),p={};p.wrap=r.string().min(1).max(2).allow(!1),b.preferences=r.object({allowUnknown:r.boolean(),abortEarly:r.boolean(),artifacts:r.boolean(),cache:r.boolean(),context:r.object(),convert:r.boolean(),dateFormat:r.valid("date","iso","string","time","utc"),debug:r.boolean(),errors:{escapeHtml:r.boolean(),label:r.valid("path","key",!1),language:[r.string(),r.object().ref()],render:r.boolean(),stack:r.boolean(),wrap:{label:p.wrap,array:p.wrap,string:p.wrap}},externals:r.boolean(),messages:r.object(),noDefaults:r.boolean(),nonEnumerables:r.boolean(),presence:r.valid("required","optional","forbidden"),skipFunctions:r.boolean(),stripUnknown:r.object({arrays:r.boolean(),objects:r.boolean()}).or("arrays","objects").allow(!0,!1),warnings:r.boolean()}).strict(),p.nameRx=/^[a-zA-Z0-9]\w*$/,p.rule=r.object({alias:r.array().items(r.string().pattern(p.nameRx)).single(),args:r.array().items(r.string(),r.object({name:r.string().pattern(p.nameRx).required(),ref:r.boolean(),assert:r.alternatives([r.function(),r.object().schema()]).conditional("ref",{is:!0,then:r.required()}),normalize:r.function(),message:r.string().when("assert",{is:r.function(),then:r.required()})})),convert:r.boolean(),manifest:r.boolean(),method:r.function().allow(!1),multi:r.boolean(),validate:r.function()}),b.extension=r.object({type:r.alternatives([r.string(),r.object().regex()]).required(),args:r.function(),cast:r.object().pattern(p.nameRx,r.object({from:r.function().maxArity(1).required(),to:r.function().minArity(1).maxArity(2).required()})),base:r.object().schema().when("type",{is:r.object().regex(),then:r.forbidden()}),coerce:[r.function().maxArity(3),r.object({method:r.function().maxArity(3).required(),from:r.array().items(r.string()).single()})],flags:r.object().pattern(p.nameRx,r.object({setter:r.string(),default:r.any()})),manifest:{build:r.function().arity(2)},messages:[r.object(),r.string()],modifiers:r.object().pattern(p.nameRx,r.function().minArity(1).maxArity(2)),overrides:r.object().pattern(p.nameRx,r.function()),prepare:r.function().maxArity(3),rebuild:r.function().arity(1),rules:r.object().pattern(p.nameRx,p.rule),terms:r.object().pattern(p.nameRx,r.object({init:r.array().allow(null).required(),manifest:r.object().pattern(/.+/,[r.valid("schema","single"),r.object({mapped:r.object({from:r.string().required(),to:r.string().required()}).required()})])})),validate:r.function().maxArity(3)}).strict(),b.extensions=r.array().items(r.object(),r.function().arity(1)).strict(),p.desc={buffer:r.object({buffer:r.string()}),func:r.object({function:r.function().required(),options:{literal:!0}}),override:r.object({override:!0}),ref:r.object({ref:r.object({type:r.valid("value","global","local"),path:r.array().required(),separator:r.string().length(1).allow(!1),ancestor:r.number().min(0).integer().allow("root"),map:r.array().items(r.array().length(2)).min(1),adjust:r.function(),iterables:r.boolean(),in:r.boolean(),render:r.boolean()}).required()}),regex:r.object({regex:r.string().min(3)}),special:r.object({special:r.valid("deep").required()}),template:r.object({template:r.string().required(),options:r.object()}),value:r.object({value:r.alternatives([r.object(),r.array()]).required()})},p.desc.entity=r.alternatives([r.array().items(r.link("...")),r.boolean(),r.function(),r.number(),r.string(),p.desc.buffer,p.desc.func,p.desc.ref,p.desc.regex,p.desc.special,p.desc.template,p.desc.value,r.link("/")]),p.desc.values=r.array().items(null,r.boolean(),r.function(),r.number().allow(1/0,-1/0),r.string().allow(""),r.symbol(),p.desc.buffer,p.desc.func,p.desc.override,p.desc.ref,p.desc.regex,p.desc.template,p.desc.value),p.desc.messages=r.object().pattern(/.+/,[r.string(),p.desc.template,r.object().pattern(/.+/,[r.string(),p.desc.template])]),b.description=r.object({type:r.string().required(),flags:r.object({cast:r.string(),default:r.any(),description:r.string(),empty:r.link("/"),failover:p.desc.entity,id:r.string(),label:r.string(),only:!0,presence:["optional","required","forbidden"],result:["raw","strip"],strip:r.boolean(),unit:r.string()}).unknown(),preferences:{allowUnknown:r.boolean(),abortEarly:r.boolean(),artifacts:r.boolean(),cache:r.boolean(),convert:r.boolean(),dateFormat:["date","iso","string","time","utc"],errors:{escapeHtml:r.boolean(),label:["path","key"],language:[r.string(),p.desc.ref],wrap:{label:p.wrap,array:p.wrap}},externals:r.boolean(),messages:p.desc.messages,noDefaults:r.boolean(),nonEnumerables:r.boolean(),presence:["required","optional","forbidden"],skipFunctions:r.boolean(),stripUnknown:r.object({arrays:r.boolean(),objects:r.boolean()}).or("arrays","objects").allow(!0,!1),warnings:r.boolean()},allow:p.desc.values,invalid:p.desc.values,rules:r.array().min(1).items({name:r.string().required(),args:r.object().min(1),keep:r.boolean(),message:[r.string(),p.desc.messages],warn:r.boolean()}),keys:r.object().pattern(/.*/,r.link("/")),link:p.desc.ref}).pattern(/^[a-z]\w*$/,r.any())},493:(_,b,m)=>{const r=m(8571),p=m(9621),f=m(8160),h={value:Symbol("value")};_.exports=h.State=class{constructor(t,l,o){this.path=t,this.ancestors=l,this.mainstay=o.mainstay,this.schemas=o.schemas,this.debug=null}localize(t,l=null,o=null){const n=new h.State(t,l,this);return o&&n.schemas&&(n.schemas=[h.schemas(o),...n.schemas]),n}nest(t,l){const o=new h.State(this.path,this.ancestors,this);return o.schemas=o.schemas&&[h.schemas(t),...o.schemas],o.debug=l,o}shadow(t,l){this.mainstay.shadow=this.mainstay.shadow||new h.Shadow,this.mainstay.shadow.set(this.path,t,l)}snapshot(){this.mainstay.shadow&&(this._snapshot=r(this.mainstay.shadow.node(this.path))),this.mainstay.snapshot()}restore(){this.mainstay.shadow&&(this.mainstay.shadow.override(this.path,this._snapshot),this._snapshot=void 0),this.mainstay.restore()}commit(){this.mainstay.shadow&&(this.mainstay.shadow.override(this.path,this._snapshot),this._snapshot=void 0),this.mainstay.commit()}},h.schemas=function(t){return f.isSchema(t)?{schema:t}:t},h.Shadow=class{constructor(){this._values=null}set(t,l,o){if(!t.length||o==="strip"&&typeof t[t.length-1]=="number")return;this._values=this._values||new Map;let n=this._values;for(let s=0;s<t.length;++s){const c=t[s];let a=n.get(c);a||(a=new Map,n.set(c,a)),n=a}n[h.value]=l}get(t){const l=this.node(t);if(l)return l[h.value]}node(t){if(this._values)return p(this._values,t,{iterables:!0})}override(t,l){if(!this._values)return;const o=t.slice(0,-1),n=t[t.length-1],s=p(this._values,o,{iterables:!0});l?s.set(n,l):s&&s.delete(n)}}},3328:(_,b,m)=>{const r=m(375),p=m(8571),f=m(5277),h=m(1447),t=m(8160),l=m(6354),o=m(6133),n={symbol:Symbol("template"),opens:new Array(1e3).join("\0"),closes:new Array(1e3).join(""),dateFormat:{date:Date.prototype.toDateString,iso:Date.prototype.toISOString,string:Date.prototype.toString,time:Date.prototype.toTimeString,utc:Date.prototype.toUTCString}};_.exports=n.Template=class{constructor(s,c){if(r(typeof s=="string","Template source must be a string"),r(!s.includes("\0")&&!s.includes(""),"Template source cannot contain reserved control characters"),this.source=s,this.rendered=s,this._template=null,c){const{functions:a,...i}=c;this._settings=Object.keys(i).length?p(i):void 0,this._functions=a,this._functions&&(r(Object.keys(this._functions).every(u=>typeof u=="string"),"Functions keys must be strings"),r(Object.values(this._functions).every(u=>typeof u=="function"),"Functions values must be functions"))}else this._settings=void 0,this._functions=void 0;this._parse()}_parse(){if(!this.source.includes("{"))return;const s=n.encode(this.source),c=n.split(s);let a=!1;const i=[],u=c.shift();u&&i.push(u);for(const g of c){const y=g[0]!=="{",k=y?"}":"}}",w=g.indexOf(k);if(w===-1||g[1]==="{"){i.push(`{${n.decode(g)}`);continue}let d=g.slice(y?0:1,w);const v=d[0]===":";v&&(d=d.slice(1));const j=this._ref(n.decode(d),{raw:y,wrapped:v});i.push(j),typeof j!="string"&&(a=!0);const S=g.slice(w+k.length);S&&i.push(n.decode(S))}a?this._template=i:this.rendered=i.join("")}static date(s,c){return n.dateFormat[c.dateFormat].call(s)}describe(s={}){if(!this._settings&&s.compact)return this.source;const c={template:this.source};return this._settings&&(c.options=this._settings),this._functions&&(c.functions=this._functions),c}static build(s){return new n.Template(s.template,s.options||s.functions?{...s.options,functions:s.functions}:void 0)}isDynamic(){return!!this._template}static isTemplate(s){return!!s&&!!s[t.symbols.template]}refs(){if(!this._template)return;const s=[];for(const c of this._template)typeof c!="string"&&s.push(...c.refs);return s}resolve(s,c,a,i){return this._template&&this._template.length===1?this._part(this._template[0],s,c,a,i,{}):this.render(s,c,a,i)}_part(s,...c){return s.ref?s.ref.resolve(...c):s.formula.evaluate(c)}render(s,c,a,i,u={}){if(!this.isDynamic())return this.rendered;const g=[];for(const y of this._template)if(typeof y=="string")g.push(y);else{const k=this._part(y,s,c,a,i,u),w=n.stringify(k,s,c,a,i,u);if(w!==void 0){const d=y.raw||(u.errors&&u.errors.escapeHtml)===!1?w:f(w);g.push(n.wrap(d,y.wrapped&&a.errors.wrap.label))}}return g.join("")}_ref(s,{raw:c,wrapped:a}){const i=[],u=y=>{const k=o.create(y,this._settings);return i.push(k),w=>{const d=k.resolve(...w);return d!==void 0?d:null}};try{const y=this._functions?{...n.functions,...this._functions}:n.functions;var g=new h.Parser(s,{reference:u,functions:y,constants:n.constants})}catch(y){throw y.message=`Invalid template variable "${s}" fails due to: ${y.message}`,y}if(g.single){if(g.single.type==="reference"){const y=i[0];return{ref:y,raw:c,refs:i,wrapped:a||y.type==="local"&&y.key==="label"}}return n.stringify(g.single.value)}return{formula:g,raw:c,refs:i}}toString(){return this.source}},n.Template.prototype[t.symbols.template]=!0,n.Template.prototype.isImmutable=!0,n.encode=function(s){return s.replace(/\\(\{+)/g,(c,a)=>n.opens.slice(0,a.length)).replace(/\\(\}+)/g,(c,a)=>n.closes.slice(0,a.length))},n.decode=function(s){return s.replace(/\u0000/g,"{").replace(/\u0001/g,"}")},n.split=function(s){const c=[];let a="";for(let i=0;i<s.length;++i){const u=s[i];if(u==="{"){let g="";for(;i+1<s.length&&s[i+1]==="{";)g+="{",++i;c.push(a),a=g}else a+=u}return c.push(a),c},n.wrap=function(s,c){return c?c.length===1?`${c}${s}${c}`:`${c[0]}${s}${c[1]}`:s},n.stringify=function(s,c,a,i,u,g={}){const y=typeof s,k=i&&i.errors&&i.errors.wrap||{};let w=!1;if(o.isRef(s)&&s.render&&(w=s.in,s=s.resolve(c,a,i,u,{in:s.in,...g})),s===null)return"null";if(y==="string")return n.wrap(s,g.arrayItems&&k.string);if(y==="number"||y==="function"||y==="symbol")return s.toString();if(y!=="object")return JSON.stringify(s);if(s instanceof Date)return n.Template.date(s,i);if(s instanceof Map){const v=[];for(const[j,S]of s.entries())v.push(`${j.toString()} -> ${S.toString()}`);s=v}if(!Array.isArray(s))return s.toString();const d=[];for(const v of s)d.push(n.stringify(v,c,a,i,u,{arrayItems:!0,...g}));return n.wrap(d.join(", "),!w&&k.array)},n.constants={true:!0,false:!1,null:null,second:1e3,minute:6e4,hour:36e5,day:864e5},n.functions={if:(s,c,a)=>s?c:a,length:s=>typeof s=="string"?s.length:s&&typeof s=="object"?Array.isArray(s)?s.length:Object.keys(s).length:null,msg(s){const[c,a,i,u,g]=this,y=g.messages;if(!y)return"";const k=l.template(c,y[0],s,a,i)||l.template(c,y[1],s,a,i);return k?k.render(c,a,i,u,g):""},number:s=>typeof s=="number"?s:typeof s=="string"?parseFloat(s):typeof s=="boolean"?s?1:0:s instanceof Date?s.getTime():null}},4946:(_,b,m)=>{const r=m(375),p=m(1687),f=m(8068),h=m(8160),t=m(3292),l=m(6354),o=m(6133),n={};_.exports=f.extend({type:"alternatives",flags:{match:{default:"any"}},terms:{matches:{init:[],register:o.toSibling}},args:(s,...c)=>c.length===1&&Array.isArray(c[0])?s.try(...c[0]):s.try(...c),validate(s,c){const{schema:a,error:i,state:u,prefs:g}=c;if(a._flags.match){const k=[],w=[];for(let v=0;v<a.$_terms.matches.length;++v){const j=a.$_terms.matches[v],S=u.nest(j.schema,`match.${v}`);S.snapshot();const O=j.schema.$_validate(s,S,g);O.errors?(w.push(O.errors),S.restore()):(k.push(O.value),S.commit())}if(k.length===0)return{errors:i("alternatives.any",{details:w.map(v=>l.details(v,{override:!1}))})};if(a._flags.match==="one")return k.length===1?{value:k[0]}:{errors:i("alternatives.one")};if(k.length!==a.$_terms.matches.length)return{errors:i("alternatives.all",{details:w.map(v=>l.details(v,{override:!1}))})};const d=v=>v.$_terms.matches.some(j=>j.schema.type==="object"||j.schema.type==="alternatives"&&d(j.schema));return d(a)?{value:k.reduce((v,j)=>p(v,j,{mergeArrays:!1}))}:{value:k[k.length-1]}}const y=[];for(let k=0;k<a.$_terms.matches.length;++k){const w=a.$_terms.matches[k];if(w.schema){const j=u.nest(w.schema,`match.${k}`);j.snapshot();const S=w.schema.$_validate(s,j,g);if(!S.errors)return j.commit(),S;j.restore(),y.push({schema:w.schema,reports:S.errors});continue}const d=w.ref?w.ref.resolve(s,u,g):s,v=w.is?[w]:w.switch;for(let j=0;j<v.length;++j){const S=v[j],{is:O,then:P,otherwise:D}=S,I=`match.${k}${w.switch?"."+j:""}`;if(O.$_match(d,u.nest(O,`${I}.is`),g)){if(P)return P.$_validate(s,u.nest(P,`${I}.then`),g)}else if(D)return D.$_validate(s,u.nest(D,`${I}.otherwise`),g)}}return n.errors(y,c)},rules:{conditional:{method(s,c){r(!this._flags._endedSwitch,"Unreachable condition"),r(!this._flags.match,"Cannot combine match mode",this._flags.match,"with conditional rule"),r(c.break===void 0,"Cannot use break option with alternatives conditional");const a=this.clone(),i=t.when(a,s,c),u=i.is?[i]:i.switch;for(const g of u)if(g.then&&g.otherwise){a.$_setFlag("_endedSwitch",!0,{clone:!1});break}return a.$_terms.matches.push(i),a.$_mutateRebuild()}},match:{method(s){if(r(["any","one","all"].includes(s),"Invalid alternatives match mode",s),s!=="any")for(const c of this.$_terms.matches)r(c.schema,"Cannot combine match mode",s,"with conditional rules");return this.$_setFlag("match",s)}},try:{method(...s){r(s.length,"Missing alternative schemas"),h.verifyFlat(s,"try"),r(!this._flags._endedSwitch,"Unreachable condition");const c=this.clone();for(const a of s)c.$_terms.matches.push({schema:c.$_compile(a)});return c.$_mutateRebuild()}}},overrides:{label(s){return this.$_parent("label",s).$_modify({each:(c,a)=>a.path[0]!=="is"&&typeof c._flags.label!="string"?c.label(s):void 0,ref:!1})}},rebuild(s){s.$_modify({each:c=>{h.isSchema(c)&&c.type==="array"&&s.$_setFlag("_arrayItems",!0,{clone:!1})}})},manifest:{build(s,c){if(c.matches)for(const a of c.matches){const{schema:i,ref:u,is:g,not:y,then:k,otherwise:w}=a;s=i?s.try(i):u?s.conditional(u,{is:g,then:k,not:y,otherwise:w,switch:a.switch}):s.conditional(g,{then:k,otherwise:w})}return s}},messages:{"alternatives.all":"{{#label}} does not match all of the required types","alternatives.any":"{{#label}} does not match any of the allowed types","alternatives.match":"{{#label}} does not match any of the allowed types","alternatives.one":"{{#label}} matches more than one allowed type","alternatives.types":"{{#label}} must be one of {{#types}}"}}),n.errors=function(s,{error:c,state:a}){if(!s.length)return{errors:c("alternatives.any")};if(s.length===1)return{errors:s[0].reports};const i=new Set,u=[];for(const{reports:g,schema:y}of s){if(g.length>1)return n.unmatched(s,c);const k=g[0];if(k instanceof l.Report==0)return n.unmatched(s,c);if(k.state.path.length!==a.path.length){u.push({type:y.type,report:k});continue}if(k.code==="any.only"){for(const v of k.local.valids)i.add(v);continue}const[w,d]=k.code.split(".");d!=="base"?u.push({type:y.type,report:k}):k.code==="object.base"?i.add(k.local.type):i.add(w)}return u.length?u.length===1?{errors:u[0].report}:n.unmatched(s,c):{errors:c("alternatives.types",{types:[...i]})}},n.unmatched=function(s,c){const a=[];for(const i of s)a.push(...i.reports);return{errors:c("alternatives.match",l.details(a,{override:!1}))}}},8068:(_,b,m)=>{const r=m(375),p=m(7629),f=m(8160),h=m(6914);_.exports=p.extend({type:"any",flags:{only:{default:!1}},terms:{alterations:{init:null},examples:{init:null},externals:{init:null},metas:{init:[]},notes:{init:[]},shared:{init:null},tags:{init:[]},whens:{init:null}},rules:{custom:{method(t,l){return r(typeof t=="function","Method must be a function"),r(l===void 0||l&&typeof l=="string","Description must be a non-empty string"),this.$_addRule({name:"custom",args:{method:t,description:l}})},validate(t,l,{method:o}){try{return o(t,l)}catch(n){return l.error("any.custom",{error:n})}},args:["method","description"],multi:!0},messages:{method(t){return this.prefs({messages:t})}},shared:{method(t){r(f.isSchema(t)&&t._flags.id,"Schema must be a schema with an id");const l=this.clone();return l.$_terms.shared=l.$_terms.shared||[],l.$_terms.shared.push(t),l.$_mutateRegister(t),l}},warning:{method(t,l){return r(t&&typeof t=="string","Invalid warning code"),this.$_addRule({name:"warning",args:{code:t,local:l},warn:!0})},validate:(t,l,{code:o,local:n})=>l.error(o,n),args:["code","local"],multi:!0}},modifiers:{keep(t,l=!0){t.keep=l},message(t,l){t.message=h.compile(l)},warn(t,l=!0){t.warn=l}},manifest:{build(t,l){for(const o in l){const n=l[o];if(["examples","externals","metas","notes","tags"].includes(o))for(const s of n)t=t[o.slice(0,-1)](s);else if(o!=="alterations")if(o!=="whens"){if(o==="shared")for(const s of n)t=t.shared(s)}else for(const s of n){const{ref:c,is:a,not:i,then:u,otherwise:g,concat:y}=s;t=y?t.concat(y):c?t.when(c,{is:a,not:i,then:u,otherwise:g,switch:s.switch,break:s.break}):t.when(a,{then:u,otherwise:g,break:s.break})}else{const s={};for(const{target:c,adjuster:a}of n)s[c]=a;t=t.alter(s)}}return t}},messages:{"any.custom":"{{#label}} failed custom validation because {{#error.message}}","any.default":"{{#label}} threw an error when running default method","any.failover":"{{#label}} threw an error when running failover method","any.invalid":"{{#label}} contains an invalid value","any.only":'{{#label}} must be {if(#valids.length == 1, "", "one of ")}{{#valids}}',"any.ref":"{{#label}} {{#arg}} references {{:#ref}} which {{#reason}}","any.required":"{{#label}} is required","any.unknown":"{{#label}} is not allowed"}})},546:(_,b,m)=>{const r=m(375),p=m(9474),f=m(9621),h=m(8068),t=m(8160),l=m(3292),o={};_.exports=h.extend({type:"array",flags:{single:{default:!1},sparse:{default:!1}},terms:{items:{init:[],manifest:"schema"},ordered:{init:[],manifest:"schema"},_exclusions:{init:[]},_inclusions:{init:[]},_requireds:{init:[]}},coerce:{from:"object",method(n,{schema:s,state:c,prefs:a}){if(!Array.isArray(n))return;const i=s.$_getRule("sort");return i?o.sort(s,n,i.args.options,c,a):void 0}},validate(n,{schema:s,error:c}){if(!Array.isArray(n)){if(s._flags.single){const a=[n];return a[t.symbols.arraySingle]=!0,{value:a}}return{errors:c("array.base")}}if(s.$_getRule("items")||s.$_terms.externals)return{value:n.slice()}},rules:{has:{method(n){n=this.$_compile(n,{appendPath:!0});const s=this.$_addRule({name:"has",args:{schema:n}});return s.$_mutateRegister(n),s},validate(n,{state:s,prefs:c,error:a},{schema:i}){const u=[n,...s.ancestors];for(let y=0;y<n.length;++y){const k=s.localize([...s.path,y],u,i);if(i.$_match(n[y],k,c))return n}const g=i._flags.label;return g?a("array.hasKnown",{patternLabel:g}):a("array.hasUnknown",null)},multi:!0},items:{method(...n){t.verifyFlat(n,"items");const s=this.$_addRule("items");for(let c=0;c<n.length;++c){const a=t.tryWithPath(()=>this.$_compile(n[c]),c,{append:!0});s.$_terms.items.push(a)}return s.$_mutateRebuild()},validate(n,{schema:s,error:c,state:a,prefs:i,errorsArray:u}){const g=s.$_terms._requireds.slice(),y=s.$_terms.ordered.slice(),k=[...s.$_terms._inclusions,...g],w=!n[t.symbols.arraySingle];delete n[t.symbols.arraySingle];const d=u();let v=n.length;for(let j=0;j<v;++j){const S=n[j];let O=!1,P=!1;const D=w?j:new Number(j),I=[...a.path,D];if(!s._flags.sparse&&S===void 0){if(d.push(c("array.sparse",{key:D,path:I,pos:j,value:void 0},a.localize(I))),i.abortEarly)return d;y.shift();continue}const B=[n,...a.ancestors];for(const F of s.$_terms._exclusions)if(F.$_match(S,a.localize(I,B,F),i,{presence:"ignore"})){if(d.push(c("array.excludes",{pos:j,value:S},a.localize(I))),i.abortEarly)return d;O=!0,y.shift();break}if(O)continue;if(s.$_terms.ordered.length){if(y.length){const F=y.shift(),V=F.$_validate(S,a.localize(I,B,F),i);if(V.errors){if(d.push(...V.errors),i.abortEarly)return d}else if(F._flags.result==="strip")o.fastSplice(n,j),--j,--v;else{if(!s._flags.sparse&&V.value===void 0){if(d.push(c("array.sparse",{key:D,path:I,pos:j,value:void 0},a.localize(I))),i.abortEarly)return d;continue}n[j]=V.value}continue}if(!s.$_terms.items.length){if(d.push(c("array.orderedLength",{pos:j,limit:s.$_terms.ordered.length})),i.abortEarly)return d;break}}const N=[];let q=g.length;for(let F=0;F<q;++F){const V=a.localize(I,B,g[F]);V.snapshot();const le=g[F].$_validate(S,V,i);if(N[F]=le,!le.errors){if(V.commit(),n[j]=le.value,P=!0,o.fastSplice(g,F),--F,--q,!s._flags.sparse&&le.value===void 0&&(d.push(c("array.sparse",{key:D,path:I,pos:j,value:void 0},a.localize(I))),i.abortEarly))return d;break}V.restore()}if(P)continue;const z=i.stripUnknown&&!!i.stripUnknown.arrays||!1;q=k.length;for(const F of k){let V;const le=g.indexOf(F);if(le!==-1)V=N[le];else{const me=a.localize(I,B,F);if(me.snapshot(),V=F.$_validate(S,me,i),!V.errors){me.commit(),F._flags.result==="strip"?(o.fastSplice(n,j),--j,--v):s._flags.sparse||V.value!==void 0?n[j]=V.value:(d.push(c("array.sparse",{key:D,path:I,pos:j,value:void 0},a.localize(I))),O=!0),P=!0;break}me.restore()}if(q===1){if(z){o.fastSplice(n,j),--j,--v,P=!0;break}if(d.push(...V.errors),i.abortEarly)return d;O=!0;break}}if(!O&&(s.$_terms._inclusions.length||s.$_terms._requireds.length)&&!P){if(z){o.fastSplice(n,j),--j,--v;continue}if(d.push(c("array.includes",{pos:j,value:S},a.localize(I))),i.abortEarly)return d}}return g.length&&o.fillMissedErrors(s,d,g,n,a,i),y.length&&(o.fillOrderedErrors(s,d,y,n,a,i),d.length||o.fillDefault(y,n,a,i)),d.length?d:n},priority:!0,manifest:!1},length:{method(n){return this.$_addRule({name:"length",args:{limit:n},operator:"="})},validate:(n,s,{limit:c},{name:a,operator:i,args:u})=>t.compare(n.length,c,i)?n:s.error("array."+a,{limit:u.limit,value:n}),args:[{name:"limit",ref:!0,assert:t.limit,message:"must be a positive integer"}]},max:{method(n){return this.$_addRule({name:"max",method:"length",args:{limit:n},operator:"<="})}},min:{method(n){return this.$_addRule({name:"min",method:"length",args:{limit:n},operator:">="})}},ordered:{method(...n){t.verifyFlat(n,"ordered");const s=this.$_addRule("items");for(let c=0;c<n.length;++c){const a=t.tryWithPath(()=>this.$_compile(n[c]),c,{append:!0});o.validateSingle(a,s),s.$_mutateRegister(a),s.$_terms.ordered.push(a)}return s.$_mutateRebuild()}},single:{method(n){const s=n===void 0||!!n;return r(!s||!this._flags._arrayItems,"Cannot specify single rule when array has array items"),this.$_setFlag("single",s)}},sort:{method(n={}){t.assertOptions(n,["by","order"]);const s={order:n.order||"ascending"};return n.by&&(s.by=l.ref(n.by,{ancestor:0}),r(!s.by.ancestor,"Cannot sort by ancestor")),this.$_addRule({name:"sort",args:{options:s}})},validate(n,{error:s,state:c,prefs:a,schema:i},{options:u}){const{value:g,errors:y}=o.sort(i,n,u,c,a);if(y)return y;for(let k=0;k<n.length;++k)if(n[k]!==g[k])return s("array.sort",{order:u.order,by:u.by?u.by.key:"value"});return n},convert:!0},sparse:{method(n){const s=n===void 0||!!n;return this._flags.sparse===s?this:(s?this.clone():this.$_addRule("items")).$_setFlag("sparse",s,{clone:!1})}},unique:{method(n,s={}){r(!n||typeof n=="function"||typeof n=="string","comparator must be a function or a string"),t.assertOptions(s,["ignoreUndefined","separator"]);const c={name:"unique",args:{options:s,comparator:n}};if(n)if(typeof n=="string"){const a=t.default(s.separator,".");c.path=a?n.split(a):[n]}else c.comparator=n;return this.$_addRule(c)},validate(n,{state:s,error:c,schema:a},{comparator:i,options:u},{comparator:g,path:y}){const k={string:Object.create(null),number:Object.create(null),undefined:Object.create(null),boolean:Object.create(null),bigint:Object.create(null),object:new Map,function:new Map,custom:new Map},w=g||p,d=u.ignoreUndefined;for(let v=0;v<n.length;++v){const j=y?f(n[v],y):n[v],S=g?k.custom:k[typeof j];if(r(S,"Failed to find unique map container for type",typeof j),S instanceof Map){const O=S.entries();let P;for(;!(P=O.next()).done;)if(w(P.value[0],j)){const D=s.localize([...s.path,v],[n,...s.ancestors]),I={pos:v,value:n[v],dupePos:P.value[1],dupeValue:n[P.value[1]]};return y&&(I.path=i),c("array.unique",I,D)}S.set(j,v)}else{if((!d||j!==void 0)&&S[j]!==void 0){const O={pos:v,value:n[v],dupePos:S[j],dupeValue:n[S[j]]};return y&&(O.path=i),c("array.unique",O,s.localize([...s.path,v],[n,...s.ancestors]))}S[j]=v}}return n},args:["comparator","options"],multi:!0}},cast:{set:{from:Array.isArray,to:(n,s)=>new Set(n)}},rebuild(n){n.$_terms._inclusions=[],n.$_terms._exclusions=[],n.$_terms._requireds=[];for(const s of n.$_terms.items)o.validateSingle(s,n),s._flags.presence==="required"?n.$_terms._requireds.push(s):s._flags.presence==="forbidden"?n.$_terms._exclusions.push(s):n.$_terms._inclusions.push(s);for(const s of n.$_terms.ordered)o.validateSingle(s,n)},manifest:{build:(n,s)=>(s.items&&(n=n.items(...s.items)),s.ordered&&(n=n.ordered(...s.ordered)),n)},messages:{"array.base":"{{#label}} must be an array","array.excludes":"{{#label}} contains an excluded value","array.hasKnown":"{{#label}} does not contain at least one required match for type {:#patternLabel}","array.hasUnknown":"{{#label}} does not contain at least one required match","array.includes":"{{#label}} does not match any of the allowed types","array.includesRequiredBoth":"{{#label}} does not contain {{#knownMisses}} and {{#unknownMisses}} other required value(s)","array.includesRequiredKnowns":"{{#label}} does not contain {{#knownMisses}}","array.includesRequiredUnknowns":"{{#label}} does not contain {{#unknownMisses}} required value(s)","array.length":"{{#label}} must contain {{#limit}} items","array.max":"{{#label}} must contain less than or equal to {{#limit}} items","array.min":"{{#label}} must contain at least {{#limit}} items","array.orderedLength":"{{#label}} must contain at most {{#limit}} items","array.sort":"{{#label}} must be sorted in {#order} order by {{#by}}","array.sort.mismatching":"{{#label}} cannot be sorted due to mismatching types","array.sort.unsupported":"{{#label}} cannot be sorted due to unsupported type {#type}","array.sparse":"{{#label}} must not be a sparse array item","array.unique":"{{#label}} contains a duplicate value"}}),o.fillMissedErrors=function(n,s,c,a,i,u){const g=[];let y=0;for(const k of c){const w=k._flags.label;w?g.push(w):++y}g.length?y?s.push(n.$_createError("array.includesRequiredBoth",a,{knownMisses:g,unknownMisses:y},i,u)):s.push(n.$_createError("array.includesRequiredKnowns",a,{knownMisses:g},i,u)):s.push(n.$_createError("array.includesRequiredUnknowns",a,{unknownMisses:y},i,u))},o.fillOrderedErrors=function(n,s,c,a,i,u){const g=[];for(const y of c)y._flags.presence==="required"&&g.push(y);g.length&&o.fillMissedErrors(n,s,g,a,i,u)},o.fillDefault=function(n,s,c,a){const i=[];let u=!0;for(let g=n.length-1;g>=0;--g){const y=n[g],k=[s,...c.ancestors],w=y.$_validate(void 0,c.localize(c.path,k,y),a).value;if(u){if(w===void 0)continue;u=!1}i.unshift(w)}i.length&&s.push(...i)},o.fastSplice=function(n,s){let c=s;for(;c<n.length;)n[c++]=n[c];--n.length},o.validateSingle=function(n,s){(n.type==="array"||n._flags._arrayItems)&&(r(!s._flags.single,"Cannot specify array item with single rule enabled"),s.$_setFlag("_arrayItems",!0,{clone:!1}))},o.sort=function(n,s,c,a,i){const u=c.order==="ascending"?1:-1,g=-1*u,y=u,k=(w,d)=>{let v=o.compare(w,d,g,y);if(v!==null||(c.by&&(w=c.by.resolve(w,a,i),d=c.by.resolve(d,a,i)),v=o.compare(w,d,g,y),v!==null))return v;const j=typeof w;if(j!==typeof d)throw n.$_createError("array.sort.mismatching",s,null,a,i);if(j!=="number"&&j!=="string")throw n.$_createError("array.sort.unsupported",s,{type:j},a,i);return j==="number"?(w-d)*u:w<d?g:y};try{return{value:s.slice().sort(k)}}catch(w){return{errors:w}}},o.compare=function(n,s,c,a){return n===s?0:n===void 0?1:s===void 0?-1:n===null?a:s===null?c:null}},4937:(_,b,m)=>{const r=m(375),p=m(8068),f=m(8160),h=m(2036),t={isBool:function(l){return typeof l=="boolean"}};_.exports=p.extend({type:"boolean",flags:{sensitive:{default:!1}},terms:{falsy:{init:null,manifest:"values"},truthy:{init:null,manifest:"values"}},coerce(l,{schema:o}){if(typeof l!="boolean"){if(typeof l=="string"){const n=o._flags.sensitive?l:l.toLowerCase();l=n==="true"||n!=="false"&&l}return typeof l!="boolean"&&(l=o.$_terms.truthy&&o.$_terms.truthy.has(l,null,null,!o._flags.sensitive)||(!o.$_terms.falsy||!o.$_terms.falsy.has(l,null,null,!o._flags.sensitive))&&l),{value:l}}},validate(l,{error:o}){if(typeof l!="boolean")return{value:l,errors:o("boolean.base")}},rules:{truthy:{method(...l){f.verifyFlat(l,"truthy");const o=this.clone();o.$_terms.truthy=o.$_terms.truthy||new h;for(let n=0;n<l.length;++n){const s=l[n];r(s!==void 0,"Cannot call truthy with undefined"),o.$_terms.truthy.add(s)}return o}},falsy:{method(...l){f.verifyFlat(l,"falsy");const o=this.clone();o.$_terms.falsy=o.$_terms.falsy||new h;for(let n=0;n<l.length;++n){const s=l[n];r(s!==void 0,"Cannot call falsy with undefined"),o.$_terms.falsy.add(s)}return o}},sensitive:{method(l=!0){return this.$_setFlag("sensitive",l)}}},cast:{number:{from:t.isBool,to:(l,o)=>l?1:0},string:{from:t.isBool,to:(l,o)=>l?"true":"false"}},manifest:{build:(l,o)=>(o.truthy&&(l=l.truthy(...o.truthy)),o.falsy&&(l=l.falsy(...o.falsy)),l)},messages:{"boolean.base":"{{#label}} must be a boolean"}})},7500:(_,b,m)=>{const r=m(375),p=m(8068),f=m(8160),h=m(3328),t={isDate:function(l){return l instanceof Date}};_.exports=p.extend({type:"date",coerce:{from:["number","string"],method:(l,{schema:o})=>({value:t.parse(l,o._flags.format)||l})},validate(l,{schema:o,error:n,prefs:s}){if(l instanceof Date&&!isNaN(l.getTime()))return;const c=o._flags.format;return s.convert&&c&&typeof l=="string"?{value:l,errors:n("date.format",{format:c})}:{value:l,errors:n("date.base")}},rules:{compare:{method:!1,validate(l,o,{date:n},{name:s,operator:c,args:a}){const i=n==="now"?Date.now():n.getTime();return f.compare(l.getTime(),i,c)?l:o.error("date."+s,{limit:a.date,value:l})},args:[{name:"date",ref:!0,normalize:l=>l==="now"?l:t.parse(l),assert:l=>l!==null,message:"must have a valid date format"}]},format:{method(l){return r(["iso","javascript","unix"].includes(l),"Unknown date format",l),this.$_setFlag("format",l)}},greater:{method(l){return this.$_addRule({name:"greater",method:"compare",args:{date:l},operator:">"})}},iso:{method(){return this.format("iso")}},less:{method(l){return this.$_addRule({name:"less",method:"compare",args:{date:l},operator:"<"})}},max:{method(l){return this.$_addRule({name:"max",method:"compare",args:{date:l},operator:"<="})}},min:{method(l){return this.$_addRule({name:"min",method:"compare",args:{date:l},operator:">="})}},timestamp:{method(l="javascript"){return r(["javascript","unix"].includes(l),'"type" must be one of "javascript, unix"'),this.format(l)}}},cast:{number:{from:t.isDate,to:(l,o)=>l.getTime()},string:{from:t.isDate,to:(l,{prefs:o})=>h.date(l,o)}},messages:{"date.base":"{{#label}} must be a valid date","date.format":'{{#label}} must be in {msg("date.format." + #format) || #format} format',"date.greater":"{{#label}} must be greater than {{:#limit}}","date.less":"{{#label}} must be less than {{:#limit}}","date.max":"{{#label}} must be less than or equal to {{:#limit}}","date.min":"{{#label}} must be greater than or equal to {{:#limit}}","date.format.iso":"ISO 8601 date","date.format.javascript":"timestamp or number of milliseconds","date.format.unix":"timestamp or number of seconds"}}),t.parse=function(l,o){if(l instanceof Date)return l;if(typeof l!="string"&&(isNaN(l)||!isFinite(l))||/^\s*$/.test(l))return null;if(o==="iso")return f.isIsoDate(l)?t.date(l.toString()):null;const n=l;if(typeof l=="string"&&/^[+-]?\d+(\.\d+)?$/.test(l)&&(l=parseFloat(l)),o){if(o==="javascript")return t.date(1*l);if(o==="unix")return t.date(1e3*l);if(typeof n=="string")return null}return t.date(l)},t.date=function(l){const o=new Date(l);return isNaN(o.getTime())?null:o}},390:(_,b,m)=>{const r=m(375),p=m(7824);_.exports=p.extend({type:"function",properties:{typeof:"function"},rules:{arity:{method(f){return r(Number.isSafeInteger(f)&&f>=0,"n must be a positive integer"),this.$_addRule({name:"arity",args:{n:f}})},validate:(f,h,{n:t})=>f.length===t?f:h.error("function.arity",{n:t})},class:{method(){return this.$_addRule("class")},validate:(f,h)=>/^\s*class\s/.test(f.toString())?f:h.error("function.class",{value:f})},minArity:{method(f){return r(Number.isSafeInteger(f)&&f>0,"n must be a strict positive integer"),this.$_addRule({name:"minArity",args:{n:f}})},validate:(f,h,{n:t})=>f.length>=t?f:h.error("function.minArity",{n:t})},maxArity:{method(f){return r(Number.isSafeInteger(f)&&f>=0,"n must be a positive integer"),this.$_addRule({name:"maxArity",args:{n:f}})},validate:(f,h,{n:t})=>f.length<=t?f:h.error("function.maxArity",{n:t})}},messages:{"function.arity":"{{#label}} must have an arity of {{#n}}","function.class":"{{#label}} must be a class","function.maxArity":"{{#label}} must have an arity lesser or equal to {{#n}}","function.minArity":"{{#label}} must have an arity greater or equal to {{#n}}"}})},7824:(_,b,m)=>{const r=m(978),p=m(375),f=m(8571),h=m(3652),t=m(8068),l=m(8160),o=m(3292),n=m(6354),s=m(6133),c=m(3328),a={renameDefaults:{alias:!1,multiple:!1,override:!1}};_.exports=t.extend({type:"_keys",properties:{typeof:"object"},flags:{unknown:{default:void 0}},terms:{dependencies:{init:null},keys:{init:null,manifest:{mapped:{from:"schema",to:"key"}}},patterns:{init:null},renames:{init:null}},args:(i,u)=>i.keys(u),validate(i,{schema:u,error:g,state:y,prefs:k}){if(!i||typeof i!==u.$_property("typeof")||Array.isArray(i))return{value:i,errors:g("object.base",{type:u.$_property("typeof")})};if(!(u.$_terms.renames||u.$_terms.dependencies||u.$_terms.keys||u.$_terms.patterns||u.$_terms.externals))return;i=a.clone(i,k);const w=[];if(u.$_terms.renames&&!a.rename(u,i,y,k,w))return{value:i,errors:w};if(!u.$_terms.keys&&!u.$_terms.patterns&&!u.$_terms.dependencies)return{value:i,errors:w};const d=new Set(Object.keys(i));if(u.$_terms.keys){const v=[i,...y.ancestors];for(const j of u.$_terms.keys){const S=j.key,O=i[S];d.delete(S);const P=y.localize([...y.path,S],v,j),D=j.schema.$_validate(O,P,k);if(D.errors){if(k.abortEarly)return{value:i,errors:D.errors};D.value!==void 0&&(i[S]=D.value),w.push(...D.errors)}else j.schema._flags.result==="strip"||D.value===void 0&&O!==void 0?delete i[S]:D.value!==void 0&&(i[S]=D.value)}}if(d.size||u._flags._hasPatternMatch){const v=a.unknown(u,i,d,w,y,k);if(v)return v}if(u.$_terms.dependencies)for(const v of u.$_terms.dependencies){if(v.key!==null&&a.isPresent(v.options)(v.key.resolve(i,y,k,null,{shadow:!1}))===!1)continue;const j=a.dependencies[v.rel](u,v,i,y,k);if(j){const S=u.$_createError(j.code,i,j.context,y,k);if(k.abortEarly)return{value:i,errors:S};w.push(S)}}return{value:i,errors:w}},rules:{and:{method(...i){return l.verifyFlat(i,"and"),a.dependency(this,"and",null,i)}},append:{method(i){return i==null||Object.keys(i).length===0?this:this.keys(i)}},assert:{method(i,u,g){c.isTemplate(i)||(i=o.ref(i)),p(g===void 0||typeof g=="string","Message must be a string"),u=this.$_compile(u,{appendPath:!0});const y=this.$_addRule({name:"assert",args:{subject:i,schema:u,message:g}});return y.$_mutateRegister(i),y.$_mutateRegister(u),y},validate(i,{error:u,prefs:g,state:y},{subject:k,schema:w,message:d}){const v=k.resolve(i,y,g),j=s.isRef(k)?k.absolute(y):[];return w.$_match(v,y.localize(j,[i,...y.ancestors],w),g)?i:u("object.assert",{subject:k,message:d})},args:["subject","schema","message"],multi:!0},instance:{method(i,u){return p(typeof i=="function","constructor must be a function"),u=u||i.name,this.$_addRule({name:"instance",args:{constructor:i,name:u}})},validate:(i,u,{constructor:g,name:y})=>i instanceof g?i:u.error("object.instance",{type:y,value:i}),args:["constructor","name"]},keys:{method(i){p(i===void 0||typeof i=="object","Object schema must be a valid object"),p(!l.isSchema(i),"Object schema cannot be a joi schema");const u=this.clone();if(i)if(Object.keys(i).length){u.$_terms.keys=u.$_terms.keys?u.$_terms.keys.filter(g=>!i.hasOwnProperty(g.key)):new a.Keys;for(const g in i)l.tryWithPath(()=>u.$_terms.keys.push({key:g,schema:this.$_compile(i[g])}),g)}else u.$_terms.keys=new a.Keys;else u.$_terms.keys=null;return u.$_mutateRebuild()}},length:{method(i){return this.$_addRule({name:"length",args:{limit:i},operator:"="})},validate:(i,u,{limit:g},{name:y,operator:k,args:w})=>l.compare(Object.keys(i).length,g,k)?i:u.error("object."+y,{limit:w.limit,value:i}),args:[{name:"limit",ref:!0,assert:l.limit,message:"must be a positive integer"}]},max:{method(i){return this.$_addRule({name:"max",method:"length",args:{limit:i},operator:"<="})}},min:{method(i){return this.$_addRule({name:"min",method:"length",args:{limit:i},operator:">="})}},nand:{method(...i){return l.verifyFlat(i,"nand"),a.dependency(this,"nand",null,i)}},or:{method(...i){return l.verifyFlat(i,"or"),a.dependency(this,"or",null,i)}},oxor:{method(...i){return a.dependency(this,"oxor",null,i)}},pattern:{method(i,u,g={}){const y=i instanceof RegExp;y||(i=this.$_compile(i,{appendPath:!0})),p(u!==void 0,"Invalid rule"),l.assertOptions(g,["fallthrough","matches"]),y&&p(!i.flags.includes("g")&&!i.flags.includes("y"),"pattern should not use global or sticky mode"),u=this.$_compile(u,{appendPath:!0});const k=this.clone();k.$_terms.patterns=k.$_terms.patterns||[];const w={[y?"regex":"schema"]:i,rule:u};return g.matches&&(w.matches=this.$_compile(g.matches),w.matches.type!=="array"&&(w.matches=w.matches.$_root.array().items(w.matches)),k.$_mutateRegister(w.matches),k.$_setFlag("_hasPatternMatch",!0,{clone:!1})),g.fallthrough&&(w.fallthrough=!0),k.$_terms.patterns.push(w),k.$_mutateRegister(u),k}},ref:{method(){return this.$_addRule("ref")},validate:(i,u)=>s.isRef(i)?i:u.error("object.refType",{value:i})},regex:{method(){return this.$_addRule("regex")},validate:(i,u)=>i instanceof RegExp?i:u.error("object.regex",{value:i})},rename:{method(i,u,g={}){p(typeof i=="string"||i instanceof RegExp,"Rename missing the from argument"),p(typeof u=="string"||u instanceof c,"Invalid rename to argument"),p(u!==i,"Cannot rename key to same name:",i),l.assertOptions(g,["alias","ignoreUndefined","override","multiple"]);const y=this.clone();y.$_terms.renames=y.$_terms.renames||[];for(const k of y.$_terms.renames)p(k.from!==i,"Cannot rename the same key multiple times");return u instanceof c&&y.$_mutateRegister(u),y.$_terms.renames.push({from:i,to:u,options:r(a.renameDefaults,g)}),y}},schema:{method(i="any"){return this.$_addRule({name:"schema",args:{type:i}})},validate:(i,u,{type:g})=>!l.isSchema(i)||g!=="any"&&i.type!==g?u.error("object.schema",{type:g}):i},unknown:{method(i){return this.$_setFlag("unknown",i!==!1)}},with:{method(i,u,g={}){return a.dependency(this,"with",i,u,g)}},without:{method(i,u,g={}){return a.dependency(this,"without",i,u,g)}},xor:{method(...i){return l.verifyFlat(i,"xor"),a.dependency(this,"xor",null,i)}}},overrides:{default(i,u){return i===void 0&&(i=l.symbols.deepDefault),this.$_parent("default",i,u)}},rebuild(i){if(i.$_terms.keys){const u=new h.Sorter;for(const g of i.$_terms.keys)l.tryWithPath(()=>u.add(g,{after:g.schema.$_rootReferences(),group:g.key}),g.key);i.$_terms.keys=new a.Keys(...u.nodes)}},manifest:{build(i,u){if(u.keys&&(i=i.keys(u.keys)),u.dependencies)for(const{rel:g,key:y=null,peers:k,options:w}of u.dependencies)i=a.dependency(i,g,y,k,w);if(u.patterns)for(const{regex:g,schema:y,rule:k,fallthrough:w,matches:d}of u.patterns)i=i.pattern(g||y,k,{fallthrough:w,matches:d});if(u.renames)for(const{from:g,to:y,options:k}of u.renames)i=i.rename(g,y,k);return i}},messages:{"object.and":"{{#label}} contains {{#presentWithLabels}} without its required peers {{#missingWithLabels}}","object.assert":'{{#label}} is invalid because {if(#subject.key, `"` + #subject.key + `" failed to ` + (#message || "pass the assertion test"), #message || "the assertion failed")}',"object.base":"{{#label}} must be of type {{#type}}","object.instance":"{{#label}} must be an instance of {{:#type}}","object.length":'{{#label}} must have {{#limit}} key{if(#limit == 1, "", "s")}',"object.max":'{{#label}} must have less than or equal to {{#limit}} key{if(#limit == 1, "", "s")}',"object.min":'{{#label}} must have at least {{#limit}} key{if(#limit == 1, "", "s")}',"object.missing":"{{#label}} must contain at least one of {{#peersWithLabels}}","object.nand":"{{:#mainWithLabel}} must not exist simultaneously with {{#peersWithLabels}}","object.oxor":"{{#label}} contains a conflict between optional exclusive peers {{#peersWithLabels}}","object.pattern.match":"{{#label}} keys failed to match pattern requirements","object.refType":"{{#label}} must be a Joi reference","object.regex":"{{#label}} must be a RegExp object","object.rename.multiple":"{{#label}} cannot rename {{:#from}} because multiple renames are disabled and another key was already renamed to {{:#to}}","object.rename.override":"{{#label}} cannot rename {{:#from}} because override is disabled and target {{:#to}} exists","object.schema":"{{#label}} must be a Joi schema of {{#type}} type","object.unknown":"{{#label}} is not allowed","object.with":"{{:#mainWithLabel}} missing required peer {{:#peerWithLabel}}","object.without":"{{:#mainWithLabel}} conflict with forbidden peer {{:#peerWithLabel}}","object.xor":"{{#label}} contains a conflict between exclusive peers {{#peersWithLabels}}"}}),a.clone=function(i,u){if(typeof i=="object"){if(u.nonEnumerables)return f(i,{shallow:!0});const y=Object.create(Object.getPrototypeOf(i));return Object.assign(y,i),y}const g=function(...y){return i.apply(this,y)};return g.prototype=f(i.prototype),Object.defineProperty(g,"name",{value:i.name,writable:!1}),Object.defineProperty(g,"length",{value:i.length,writable:!1}),Object.assign(g,i),g},a.dependency=function(i,u,g,y,k){p(g===null||typeof g=="string",u,"key must be a strings"),k||(k=y.length>1&&typeof y[y.length-1]=="object"?y.pop():{}),l.assertOptions(k,["separator","isPresent"]),y=[].concat(y);const w=l.default(k.separator,"."),d=[];for(const j of y)p(typeof j=="string",u,"peers must be strings"),d.push(o.ref(j,{separator:w,ancestor:0,prefix:!1}));g!==null&&(g=o.ref(g,{separator:w,ancestor:0,prefix:!1}));const v=i.clone();return v.$_terms.dependencies=v.$_terms.dependencies||[],v.$_terms.dependencies.push(new a.Dependency(u,g,d,y,k)),v},a.dependencies={and(i,u,g,y,k){const w=[],d=[],v=u.peers.length,j=a.isPresent(u.options);for(const S of u.peers)j(S.resolve(g,y,k,null,{shadow:!1}))===!1?w.push(S.key):d.push(S.key);if(w.length!==v&&d.length!==v)return{code:"object.and",context:{present:d,presentWithLabels:a.keysToLabels(i,d),missing:w,missingWithLabels:a.keysToLabels(i,w)}}},nand(i,u,g,y,k){const w=[],d=a.isPresent(u.options);for(const S of u.peers)d(S.resolve(g,y,k,null,{shadow:!1}))&&w.push(S.key);if(w.length!==u.peers.length)return;const v=u.paths[0],j=u.paths.slice(1);return{code:"object.nand",context:{main:v,mainWithLabel:a.keysToLabels(i,v),peers:j,peersWithLabels:a.keysToLabels(i,j)}}},or(i,u,g,y,k){const w=a.isPresent(u.options);for(const d of u.peers)if(w(d.resolve(g,y,k,null,{shadow:!1})))return;return{code:"object.missing",context:{peers:u.paths,peersWithLabels:a.keysToLabels(i,u.paths)}}},oxor(i,u,g,y,k){const w=[],d=a.isPresent(u.options);for(const j of u.peers)d(j.resolve(g,y,k,null,{shadow:!1}))&&w.push(j.key);if(!w.length||w.length===1)return;const v={peers:u.paths,peersWithLabels:a.keysToLabels(i,u.paths)};return v.present=w,v.presentWithLabels=a.keysToLabels(i,w),{code:"object.oxor",context:v}},with(i,u,g,y,k){const w=a.isPresent(u.options);for(const d of u.peers)if(w(d.resolve(g,y,k,null,{shadow:!1}))===!1)return{code:"object.with",context:{main:u.key.key,mainWithLabel:a.keysToLabels(i,u.key.key),peer:d.key,peerWithLabel:a.keysToLabels(i,d.key)}}},without(i,u,g,y,k){const w=a.isPresent(u.options);for(const d of u.peers)if(w(d.resolve(g,y,k,null,{shadow:!1})))return{code:"object.without",context:{main:u.key.key,mainWithLabel:a.keysToLabels(i,u.key.key),peer:d.key,peerWithLabel:a.keysToLabels(i,d.key)}}},xor(i,u,g,y,k){const w=[],d=a.isPresent(u.options);for(const j of u.peers)d(j.resolve(g,y,k,null,{shadow:!1}))&&w.push(j.key);if(w.length===1)return;const v={peers:u.paths,peersWithLabels:a.keysToLabels(i,u.paths)};return w.length===0?{code:"object.missing",context:v}:(v.present=w,v.presentWithLabels=a.keysToLabels(i,w),{code:"object.xor",context:v})}},a.keysToLabels=function(i,u){return Array.isArray(u)?u.map(g=>i.$_mapLabels(g)):i.$_mapLabels(u)},a.isPresent=function(i){return typeof i.isPresent=="function"?i.isPresent:u=>u!==void 0},a.rename=function(i,u,g,y,k){const w={};for(const d of i.$_terms.renames){const v=[],j=typeof d.from!="string";if(j)for(const S in u){if(u[S]===void 0&&d.options.ignoreUndefined||S===d.to)continue;const O=d.from.exec(S);O&&v.push({from:S,to:d.to,match:O})}else!Object.prototype.hasOwnProperty.call(u,d.from)||u[d.from]===void 0&&d.options.ignoreUndefined||v.push(d);for(const S of v){const O=S.from;let P=S.to;if(P instanceof c&&(P=P.render(u,g,y,S.match)),O!==P){if(!d.options.multiple&&w[P]&&(k.push(i.$_createError("object.rename.multiple",u,{from:O,to:P,pattern:j},g,y)),y.abortEarly)||Object.prototype.hasOwnProperty.call(u,P)&&!d.options.override&&!w[P]&&(k.push(i.$_createError("object.rename.override",u,{from:O,to:P,pattern:j},g,y)),y.abortEarly))return!1;u[O]===void 0?delete u[P]:u[P]=u[O],w[P]=!0,d.options.alias||delete u[O]}}}return!0},a.unknown=function(i,u,g,y,k,w){if(i.$_terms.patterns){let d=!1;const v=i.$_terms.patterns.map(S=>{if(S.matches)return d=!0,[]}),j=[u,...k.ancestors];for(const S of g){const O=u[S],P=[...k.path,S];for(let D=0;D<i.$_terms.patterns.length;++D){const I=i.$_terms.patterns[D];if(I.regex){const q=I.regex.test(S);if(k.mainstay.tracer.debug(k,"rule",`pattern.${D}`,q?"pass":"error"),!q)continue}else if(!I.schema.$_match(S,k.nest(I.schema,`pattern.${D}`),w))continue;g.delete(S);const B=k.localize(P,j,{schema:I.rule,key:S}),N=I.rule.$_validate(O,B,w);if(N.errors){if(w.abortEarly)return{value:u,errors:N.errors};y.push(...N.errors)}if(I.matches&&v[D].push(S),u[S]=N.value,!I.fallthrough)break}}if(d)for(let S=0;S<v.length;++S){const O=v[S];if(!O)continue;const P=i.$_terms.patterns[S].matches,D=k.localize(k.path,j,P),I=P.$_validate(O,D,w);if(I.errors){const B=n.details(I.errors,{override:!1});B.matches=O;const N=i.$_createError("object.pattern.match",u,B,k,w);if(w.abortEarly)return{value:u,errors:N};y.push(N)}}}if(g.size&&(i.$_terms.keys||i.$_terms.patterns)){if(w.stripUnknown&&i._flags.unknown===void 0||w.skipFunctions){const d=!(!w.stripUnknown||w.stripUnknown!==!0&&!w.stripUnknown.objects);for(const v of g)d?(delete u[v],g.delete(v)):typeof u[v]=="function"&&g.delete(v)}if(!l.default(i._flags.unknown,w.allowUnknown))for(const d of g){const v=k.localize([...k.path,d],[]),j=i.$_createError("object.unknown",u[d],{child:d},v,w,{flags:!1});if(w.abortEarly)return{value:u,errors:j};y.push(j)}}},a.Dependency=class{constructor(i,u,g,y,k){this.rel=i,this.key=u,this.peers=g,this.paths=y,this.options=k}describe(){const i={rel:this.rel,peers:this.paths};return this.key!==null&&(i.key=this.key.key),this.peers[0].separator!=="."&&(i.options={...i.options,separator:this.peers[0].separator}),this.options.isPresent&&(i.options={...i.options,isPresent:this.options.isPresent}),i}},a.Keys=class extends Array{concat(i){const u=this.slice(),g=new Map;for(let y=0;y<u.length;++y)g.set(u[y].key,y);for(const y of i){const k=y.key,w=g.get(k);w!==void 0?u[w]={key:k,schema:u[w].schema.concat(y.schema)}:u.push(y)}return u}}},8785:(_,b,m)=>{const r=m(375),p=m(8068),f=m(8160),h=m(3292),t=m(6354),l={};_.exports=p.extend({type:"link",properties:{schemaChain:!0},terms:{link:{init:null,manifest:"single",register:!1}},args:(o,n)=>o.ref(n),validate(o,{schema:n,state:s,prefs:c}){r(n.$_terms.link,"Uninitialized link schema");const a=l.generate(n,o,s,c),i=n.$_terms.link[0].ref;return a.$_validate(o,s.nest(a,`link:${i.display}:${a.type}`),c)},generate:(o,n,s,c)=>l.generate(o,n,s,c),rules:{ref:{method(o){r(!this.$_terms.link,"Cannot reinitialize schema"),o=h.ref(o),r(o.type==="value"||o.type==="local","Invalid reference type:",o.type),r(o.type==="local"||o.ancestor==="root"||o.ancestor>0,"Link cannot reference itself");const n=this.clone();return n.$_terms.link=[{ref:o}],n}},relative:{method(o=!0){return this.$_setFlag("relative",o)}}},overrides:{concat(o){r(this.$_terms.link,"Uninitialized link schema"),r(f.isSchema(o),"Invalid schema object"),r(o.type!=="link","Cannot merge type link with another link");const n=this.clone();return n.$_terms.whens||(n.$_terms.whens=[]),n.$_terms.whens.push({concat:o}),n.$_mutateRebuild()}},manifest:{build:(o,n)=>(r(n.link,"Invalid link description missing link"),o.ref(n.link))}}),l.generate=function(o,n,s,c){let a=s.mainstay.links.get(o);if(a)return a._generate(n,s,c).schema;const i=o.$_terms.link[0].ref,{perspective:u,path:g}=l.perspective(i,s);l.assert(u,"which is outside of schema boundaries",i,o,s,c);try{a=g.length?u.$_reach(g):u}catch{l.assert(!1,"to non-existing schema",i,o,s,c)}return l.assert(a.type!=="link","which is another link",i,o,s,c),o._flags.relative||s.mainstay.links.set(o,a),a._generate(n,s,c).schema},l.perspective=function(o,n){if(o.type==="local"){for(const{schema:s,key:c}of n.schemas){if((s._flags.id||c)===o.path[0])return{perspective:s,path:o.path.slice(1)};if(s.$_terms.shared){for(const a of s.$_terms.shared)if(a._flags.id===o.path[0])return{perspective:a,path:o.path.slice(1)}}}return{perspective:null,path:null}}return o.ancestor==="root"?{perspective:n.schemas[n.schemas.length-1].schema,path:o.path}:{perspective:n.schemas[o.ancestor]&&n.schemas[o.ancestor].schema,path:o.path}},l.assert=function(o,n,s,c,a,i){o||r(!1,`"${t.label(c._flags,a,i)}" contains link reference "${s.display}" ${n}`)}},3832:(_,b,m)=>{const r=m(375),p=m(8068),f=m(8160),h={numberRx:/^\s*[+-]?(?:(?:\d+(?:\.\d*)?)|(?:\.\d+))(?:e([+-]?\d+))?\s*$/i,precisionRx:/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/,exponentialPartRegex:/[eE][+-]?\d+$/,leadingSignAndZerosRegex:/^[+-]?(0*)?/,dotRegex:/\./,trailingZerosRegex:/0+$/,decimalPlaces(t){const l=t.toString(),o=l.indexOf("."),n=l.indexOf("e");return(o<0?0:(n<0?l.length:n)-o-1)+(n<0?0:Math.max(0,-parseInt(l.slice(n+1))))}};_.exports=p.extend({type:"number",flags:{unsafe:{default:!1}},coerce:{from:"string",method(t,{schema:l,error:o}){if(!t.match(h.numberRx))return;t=t.trim();const n={value:parseFloat(t)};if(n.value===0&&(n.value=0),!l._flags.unsafe)if(t.match(/e/i)){if(h.extractSignificantDigits(t)!==h.extractSignificantDigits(String(n.value)))return n.errors=o("number.unsafe"),n}else{const s=n.value.toString();if(s.match(/e/i))return n;if(s!==h.normalizeDecimal(t))return n.errors=o("number.unsafe"),n}return n}},validate(t,{schema:l,error:o,prefs:n}){if(t===1/0||t===-1/0)return{value:t,errors:o("number.infinity")};if(!f.isNumber(t))return{value:t,errors:o("number.base")};const s={value:t};if(n.convert){const c=l.$_getRule("precision");if(c){const a=Math.pow(10,c.args.limit);s.value=Math.round(s.value*a)/a}}return s.value===0&&(s.value=0),!l._flags.unsafe&&(t>Number.MAX_SAFE_INTEGER||t<Number.MIN_SAFE_INTEGER)&&(s.errors=o("number.unsafe")),s},rules:{compare:{method:!1,validate:(t,l,{limit:o},{name:n,operator:s,args:c})=>f.compare(t,o,s)?t:l.error("number."+n,{limit:c.limit,value:t}),args:[{name:"limit",ref:!0,assert:f.isNumber,message:"must be a number"}]},greater:{method(t){return this.$_addRule({name:"greater",method:"compare",args:{limit:t},operator:">"})}},integer:{method(){return this.$_addRule("integer")},validate:(t,l)=>Math.trunc(t)-t==0?t:l.error("number.integer")},less:{method(t){return this.$_addRule({name:"less",method:"compare",args:{limit:t},operator:"<"})}},max:{method(t){return this.$_addRule({name:"max",method:"compare",args:{limit:t},operator:"<="})}},min:{method(t){return this.$_addRule({name:"min",method:"compare",args:{limit:t},operator:">="})}},multiple:{method(t){const l=typeof t=="number"?h.decimalPlaces(t):null,o=Math.pow(10,l);return this.$_addRule({name:"multiple",args:{base:t,baseDecimalPlace:l,pfactor:o}})},validate:(t,l,{base:o,baseDecimalPlace:n,pfactor:s},c)=>h.decimalPlaces(t)>n?l.error("number.multiple",{multiple:c.args.base,value:t}):Math.round(s*t)%Math.round(s*o)==0?t:l.error("number.multiple",{multiple:c.args.base,value:t}),args:[{name:"base",ref:!0,assert:t=>typeof t=="number"&&isFinite(t)&&t>0,message:"must be a positive number"},"baseDecimalPlace","pfactor"],multi:!0},negative:{method(){return this.sign("negative")}},port:{method(){return this.$_addRule("port")},validate:(t,l)=>Number.isSafeInteger(t)&&t>=0&&t<=65535?t:l.error("number.port")},positive:{method(){return this.sign("positive")}},precision:{method(t){return r(Number.isSafeInteger(t),"limit must be an integer"),this.$_addRule({name:"precision",args:{limit:t}})},validate(t,l,{limit:o}){const n=t.toString().match(h.precisionRx);return Math.max((n[1]?n[1].length:0)-(n[2]?parseInt(n[2],10):0),0)<=o?t:l.error("number.precision",{limit:o,value:t})},convert:!0},sign:{method(t){return r(["negative","positive"].includes(t),"Invalid sign",t),this.$_addRule({name:"sign",args:{sign:t}})},validate:(t,l,{sign:o})=>o==="negative"&&t<0||o==="positive"&&t>0?t:l.error(`number.${o}`)},unsafe:{method(t=!0){return r(typeof t=="boolean","enabled must be a boolean"),this.$_setFlag("unsafe",t)}}},cast:{string:{from:t=>typeof t=="number",to:(t,l)=>t.toString()}},messages:{"number.base":"{{#label}} must be a number","number.greater":"{{#label}} must be greater than {{#limit}}","number.infinity":"{{#label}} cannot be infinity","number.integer":"{{#label}} must be an integer","number.less":"{{#label}} must be less than {{#limit}}","number.max":"{{#label}} must be less than or equal to {{#limit}}","number.min":"{{#label}} must be greater than or equal to {{#limit}}","number.multiple":"{{#label}} must be a multiple of {{#multiple}}","number.negative":"{{#label}} must be a negative number","number.port":"{{#label}} must be a valid port","number.positive":"{{#label}} must be a positive number","number.precision":"{{#label}} must have no more than {{#limit}} decimal places","number.unsafe":"{{#label}} must be a safe number"}}),h.extractSignificantDigits=function(t){return t.replace(h.exponentialPartRegex,"").replace(h.dotRegex,"").replace(h.trailingZerosRegex,"").replace(h.leadingSignAndZerosRegex,"")},h.normalizeDecimal=function(t){return(t=t.replace(/^\+/,"").replace(/\.0*$/,"").replace(/^(-?)\.([^\.]*)$/,"$10.$2").replace(/^(-?)0+([0-9])/,"$1$2")).includes(".")&&t.endsWith("0")&&(t=t.replace(/0+$/,"")),t==="-0"?"0":t}},8966:(_,b,m)=>{const r=m(7824);_.exports=r.extend({type:"object",cast:{map:{from:p=>p&&typeof p=="object",to:(p,f)=>new Map(Object.entries(p))}}})},7417:(_,b,m)=>{const r=m(375),p=m(5380),f=m(1745),h=m(9959),t=m(6064),l=m(9926),o=m(5752),n=m(8068),s=m(8160),c={tlds:l instanceof Set&&{tlds:{allow:l,deny:null}},base64Regex:{true:{true:/^(?:[\w\-]{2}[\w\-]{2})*(?:[\w\-]{2}==|[\w\-]{3}=)?$/,false:/^(?:[A-Za-z0-9+\/]{2}[A-Za-z0-9+\/]{2})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/},false:{true:/^(?:[\w\-]{2}[\w\-]{2})*(?:[\w\-]{2}(==)?|[\w\-]{3}=?)?$/,false:/^(?:[A-Za-z0-9+\/]{2}[A-Za-z0-9+\/]{2})*(?:[A-Za-z0-9+\/]{2}(==)?|[A-Za-z0-9+\/]{3}=?)?$/}},dataUriRegex:/^data:[\w+.-]+\/[\w+.-]+;((charset=[\w-]+|base64),)?(.*)$/,hexRegex:{withPrefix:/^0x[0-9a-f]+$/i,withOptionalPrefix:/^(?:0x)?[0-9a-f]+$/i,withoutPrefix:/^[0-9a-f]+$/i},ipRegex:h.regex({cidr:"forbidden"}).regex,isoDurationRegex:/^P(?!$)(\d+Y)?(\d+M)?(\d+W)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?$/,guidBrackets:{"{":"}","[":"]","(":")","":""},guidVersions:{uuidv1:"1",uuidv2:"2",uuidv3:"3",uuidv4:"4",uuidv5:"5",uuidv6:"6",uuidv7:"7",uuidv8:"8"},guidSeparators:new Set([void 0,!0,!1,"-",":"]),normalizationForms:["NFC","NFD","NFKC","NFKD"]};_.exports=n.extend({type:"string",flags:{insensitive:{default:!1},truncate:{default:!1}},terms:{replacements:{init:null}},coerce:{from:"string",method(a,{schema:i,state:u,prefs:g}){const y=i.$_getRule("normalize");y&&(a=a.normalize(y.args.form));const k=i.$_getRule("case");k&&(a=k.args.direction==="upper"?a.toLocaleUpperCase():a.toLocaleLowerCase());const w=i.$_getRule("trim");if(w&&w.args.enabled&&(a=a.trim()),i.$_terms.replacements)for(const v of i.$_terms.replacements)a=a.replace(v.pattern,v.replacement);const d=i.$_getRule("hex");if(d&&d.args.options.byteAligned&&a.length%2!=0&&(a=`0${a}`),i.$_getRule("isoDate")){const v=c.isoDate(a);v&&(a=v)}if(i._flags.truncate){const v=i.$_getRule("max");if(v){let j=v.args.limit;if(s.isResolvable(j)&&(j=j.resolve(a,u,g),!s.limit(j)))return{value:a,errors:i.$_createError("any.ref",j,{ref:v.args.limit,arg:"limit",reason:"must be a positive integer"},u,g)};a=a.slice(0,j)}}return{value:a}}},validate(a,{schema:i,error:u}){if(typeof a!="string")return{value:a,errors:u("string.base")};if(a===""){const g=i.$_getRule("min");return g&&g.args.limit===0?void 0:{value:a,errors:u("string.empty")}}},rules:{alphanum:{method(){return this.$_addRule("alphanum")},validate:(a,i)=>/^[a-zA-Z0-9]+$/.test(a)?a:i.error("string.alphanum")},base64:{method(a={}){return s.assertOptions(a,["paddingRequired","urlSafe"]),a={urlSafe:!1,paddingRequired:!0,...a},r(typeof a.paddingRequired=="boolean","paddingRequired must be boolean"),r(typeof a.urlSafe=="boolean","urlSafe must be boolean"),this.$_addRule({name:"base64",args:{options:a}})},validate:(a,i,{options:u})=>c.base64Regex[u.paddingRequired][u.urlSafe].test(a)?a:i.error("string.base64")},case:{method(a){return r(["lower","upper"].includes(a),"Invalid case:",a),this.$_addRule({name:"case",args:{direction:a}})},validate:(a,i,{direction:u})=>u==="lower"&&a===a.toLocaleLowerCase()||u==="upper"&&a===a.toLocaleUpperCase()?a:i.error(`string.${u}case`),convert:!0},creditCard:{method(){return this.$_addRule("creditCard")},validate(a,i){let u=a.length,g=0,y=1;for(;u--;){const k=a.charAt(u)*y;g+=k-9*(k>9),y^=3}return g>0&&g%10==0?a:i.error("string.creditCard")}},dataUri:{method(a={}){return s.assertOptions(a,["paddingRequired"]),a={paddingRequired:!0,...a},r(typeof a.paddingRequired=="boolean","paddingRequired must be boolean"),this.$_addRule({name:"dataUri",args:{options:a}})},validate(a,i,{options:u}){const g=a.match(c.dataUriRegex);return g&&(!g[2]||g[2]!=="base64"||c.base64Regex[u.paddingRequired].false.test(g[3]))?a:i.error("string.dataUri")}},domain:{method(a){a&&s.assertOptions(a,["allowFullyQualified","allowUnicode","maxDomainSegments","minDomainSegments","tlds"]);const i=c.addressOptions(a);return this.$_addRule({name:"domain",args:{options:a},address:i})},validate:(a,i,u,{address:g})=>p.isValid(a,g)?a:i.error("string.domain")},email:{method(a={}){s.assertOptions(a,["allowFullyQualified","allowUnicode","ignoreLength","maxDomainSegments","minDomainSegments","multiple","separator","tlds"]),r(a.multiple===void 0||typeof a.multiple=="boolean","multiple option must be an boolean");const i=c.addressOptions(a),u=new RegExp(`\\s*[${a.separator?t(a.separator):","}]\\s*`);return this.$_addRule({name:"email",args:{options:a},regex:u,address:i})},validate(a,i,{options:u},{regex:g,address:y}){const k=u.multiple?a.split(g):[a],w=[];for(const d of k)f.isValid(d,y)||w.push(d);return w.length?i.error("string.email",{value:a,invalids:w}):a}},guid:{alias:"uuid",method(a={}){s.assertOptions(a,["version","separator"]);let i="";if(a.version){const y=[].concat(a.version);r(y.length>=1,"version must have at least 1 valid version specified");const k=new Set;for(let w=0;w<y.length;++w){const d=y[w];r(typeof d=="string","version at position "+w+" must be a string");const v=c.guidVersions[d.toLowerCase()];r(v,"version at position "+w+" must be one of "+Object.keys(c.guidVersions).join(", ")),r(!k.has(v),"version at position "+w+" must not be a duplicate"),i+=v,k.add(v)}}r(c.guidSeparators.has(a.separator),'separator must be one of true, false, "-", or ":"');const u=a.separator===void 0?"[:-]?":a.separator===!0?"[:-]":a.separator===!1?"[]?":`\\${a.separator}`,g=new RegExp(`^([\\[{\\(]?)[0-9A-F]{8}(${u})[0-9A-F]{4}\\2?[${i||"0-9A-F"}][0-9A-F]{3}\\2?[${i?"89AB":"0-9A-F"}][0-9A-F]{3}\\2?[0-9A-F]{12}([\\]}\\)]?)$`,"i");return this.$_addRule({name:"guid",args:{options:a},regex:g})},validate(a,i,u,{regex:g}){const y=g.exec(a);return y?c.guidBrackets[y[1]]!==y[y.length-1]?i.error("string.guid"):a:i.error("string.guid")}},hex:{method(a={}){return s.assertOptions(a,["byteAligned","prefix"]),a={byteAligned:!1,prefix:!1,...a},r(typeof a.byteAligned=="boolean","byteAligned must be boolean"),r(typeof a.prefix=="boolean"||a.prefix==="optional",'prefix must be boolean or "optional"'),this.$_addRule({name:"hex",args:{options:a}})},validate:(a,i,{options:u})=>(u.prefix==="optional"?c.hexRegex.withOptionalPrefix:u.prefix===!0?c.hexRegex.withPrefix:c.hexRegex.withoutPrefix).test(a)?u.byteAligned&&a.length%2!=0?i.error("string.hexAlign"):a:i.error("string.hex")},hostname:{method(){return this.$_addRule("hostname")},validate:(a,i)=>p.isValid(a,{minDomainSegments:1})||c.ipRegex.test(a)?a:i.error("string.hostname")},insensitive:{method(){return this.$_setFlag("insensitive",!0)}},ip:{method(a={}){s.assertOptions(a,["cidr","version"]);const{cidr:i,versions:u,regex:g}=h.regex(a),y=a.version?u:void 0;return this.$_addRule({name:"ip",args:{options:{cidr:i,version:y}},regex:g})},validate:(a,i,{options:u},{regex:g})=>g.test(a)?a:u.version?i.error("string.ipVersion",{value:a,cidr:u.cidr,version:u.version}):i.error("string.ip",{value:a,cidr:u.cidr})},isoDate:{method(){return this.$_addRule("isoDate")},validate:(a,{error:i})=>c.isoDate(a)?a:i("string.isoDate")},isoDuration:{method(){return this.$_addRule("isoDuration")},validate:(a,i)=>c.isoDurationRegex.test(a)?a:i.error("string.isoDuration")},length:{method(a,i){return c.length(this,"length",a,"=",i)},validate(a,i,{limit:u,encoding:g},{name:y,operator:k,args:w}){const d=!g&&a.length;return s.compare(d,u,k)?a:i.error("string."+y,{limit:w.limit,value:a,encoding:g})},args:[{name:"limit",ref:!0,assert:s.limit,message:"must be a positive integer"},"encoding"]},lowercase:{method(){return this.case("lower")}},max:{method(a,i){return c.length(this,"max",a,"<=",i)},args:["limit","encoding"]},min:{method(a,i){return c.length(this,"min",a,">=",i)},args:["limit","encoding"]},normalize:{method(a="NFC"){return r(c.normalizationForms.includes(a),"normalization form must be one of "+c.normalizationForms.join(", ")),this.$_addRule({name:"normalize",args:{form:a}})},validate:(a,{error:i},{form:u})=>a===a.normalize(u)?a:i("string.normalize",{value:a,form:u}),convert:!0},pattern:{alias:"regex",method(a,i={}){r(a instanceof RegExp,"regex must be a RegExp"),r(!a.flags.includes("g")&&!a.flags.includes("y"),"regex should not use global or sticky mode"),typeof i=="string"&&(i={name:i}),s.assertOptions(i,["invert","name"]);const u=["string.pattern",i.invert?".invert":"",i.name?".name":".base"].join("");return this.$_addRule({name:"pattern",args:{regex:a,options:i},errorCode:u})},validate:(a,i,{regex:u,options:g},{errorCode:y})=>u.test(a)^g.invert?a:i.error(y,{name:g.name,regex:u,value:a}),args:["regex","options"],multi:!0},replace:{method(a,i){typeof a=="string"&&(a=new RegExp(t(a),"g")),r(a instanceof RegExp,"pattern must be a RegExp"),r(typeof i=="string","replacement must be a String");const u=this.clone();return u.$_terms.replacements||(u.$_terms.replacements=[]),u.$_terms.replacements.push({pattern:a,replacement:i}),u}},token:{method(){return this.$_addRule("token")},validate:(a,i)=>/^\w+$/.test(a)?a:i.error("string.token")},trim:{method(a=!0){return r(typeof a=="boolean","enabled must be a boolean"),this.$_addRule({name:"trim",args:{enabled:a}})},validate:(a,i,{enabled:u})=>u&&a!==a.trim()?i.error("string.trim"):a,convert:!0},truncate:{method(a=!0){return r(typeof a=="boolean","enabled must be a boolean"),this.$_setFlag("truncate",a)}},uppercase:{method(){return this.case("upper")}},uri:{method(a={}){s.assertOptions(a,["allowRelative","allowQuerySquareBrackets","domain","relativeOnly","scheme","encodeUri"]),a.domain&&s.assertOptions(a.domain,["allowFullyQualified","allowUnicode","maxDomainSegments","minDomainSegments","tlds"]);const{regex:i,scheme:u}=o.regex(a),g=a.domain?c.addressOptions(a.domain):null;return this.$_addRule({name:"uri",args:{options:a},regex:i,domain:g,scheme:u})},validate(a,i,{options:u},{regex:g,domain:y,scheme:k}){if(["http:/","https:/"].includes(a))return i.error("string.uri");let w=g.exec(a);if(!w&&i.prefs.convert&&u.encodeUri){const d=encodeURI(a);w=g.exec(d),w&&(a=d)}if(w){const d=w[1]||w[2];return!y||u.allowRelative&&!d||p.isValid(d,y)?a:i.error("string.domain",{value:d})}return u.relativeOnly?i.error("string.uriRelativeOnly"):u.scheme?i.error("string.uriCustomScheme",{scheme:k,value:a}):i.error("string.uri")}}},manifest:{build(a,i){if(i.replacements)for(const{pattern:u,replacement:g}of i.replacements)a=a.replace(u,g);return a}},messages:{"string.alphanum":"{{#label}} must only contain alpha-numeric characters","string.base":"{{#label}} must be a string","string.base64":"{{#label}} must be a valid base64 string","string.creditCard":"{{#label}} must be a credit card","string.dataUri":"{{#label}} must be a valid dataUri string","string.domain":"{{#label}} must contain a valid domain name","string.email":"{{#label}} must be a valid email","string.empty":"{{#label}} is not allowed to be empty","string.guid":"{{#label}} must be a valid GUID","string.hex":"{{#label}} must only contain hexadecimal characters","string.hexAlign":"{{#label}} hex decoded representation must be byte aligned","string.hostname":"{{#label}} must be a valid hostname","string.ip":"{{#label}} must be a valid ip address with a {{#cidr}} CIDR","string.ipVersion":"{{#label}} must be a valid ip address of one of the following versions {{#version}} with a {{#cidr}} CIDR","string.isoDate":"{{#label}} must be in iso format","string.isoDuration":"{{#label}} must be a valid ISO 8601 duration","string.length":"{{#label}} length must be {{#limit}} characters long","string.lowercase":"{{#label}} must only contain lowercase characters","string.max":"{{#label}} length must be less than or equal to {{#limit}} characters long","string.min":"{{#label}} length must be at least {{#limit}} characters long","string.normalize":"{{#label}} must be unicode normalized in the {{#form}} form","string.token":"{{#label}} must only contain alpha-numeric and underscore characters","string.pattern.base":"{{#label}} with value {:[.]} fails to match the required pattern: {{#regex}}","string.pattern.name":"{{#label}} with value {:[.]} fails to match the {{#name}} pattern","string.pattern.invert.base":"{{#label}} with value {:[.]} matches the inverted pattern: {{#regex}}","string.pattern.invert.name":"{{#label}} with value {:[.]} matches the inverted {{#name}} pattern","string.trim":"{{#label}} must not have leading or trailing whitespace","string.uri":"{{#label}} must be a valid uri","string.uriCustomScheme":"{{#label}} must be a valid uri with a scheme matching the {{#scheme}} pattern","string.uriRelativeOnly":"{{#label}} must be a valid relative uri","string.uppercase":"{{#label}} must only contain uppercase characters"}}),c.addressOptions=function(a){if(!a)return c.tlds||a;if(r(a.minDomainSegments===void 0||Number.isSafeInteger(a.minDomainSegments)&&a.minDomainSegments>0,"minDomainSegments must be a positive integer"),r(a.maxDomainSegments===void 0||Number.isSafeInteger(a.maxDomainSegments)&&a.maxDomainSegments>0,"maxDomainSegments must be a positive integer"),a.tlds===!1)return a;if(a.tlds===!0||a.tlds===void 0)return r(c.tlds,"Built-in TLD list disabled"),Object.assign({},a,c.tlds);r(typeof a.tlds=="object","tlds must be true, false, or an object");const i=a.tlds.deny;if(i)return Array.isArray(i)&&(a=Object.assign({},a,{tlds:{deny:new Set(i)}})),r(a.tlds.deny instanceof Set,"tlds.deny must be an array, Set, or boolean"),r(!a.tlds.allow,"Cannot specify both tlds.allow and tlds.deny lists"),c.validateTlds(a.tlds.deny,"tlds.deny"),a;const u=a.tlds.allow;return u?u===!0?(r(c.tlds,"Built-in TLD list disabled"),Object.assign({},a,c.tlds)):(Array.isArray(u)&&(a=Object.assign({},a,{tlds:{allow:new Set(u)}})),r(a.tlds.allow instanceof Set,"tlds.allow must be an array, Set, or boolean"),c.validateTlds(a.tlds.allow,"tlds.allow"),a):a},c.validateTlds=function(a,i){for(const u of a)r(p.isValid(u,{minDomainSegments:1,maxDomainSegments:1}),`${i} must contain valid top level domain names`)},c.isoDate=function(a){if(!s.isIsoDate(a))return null;/.*T.*[+-]\d\d$/.test(a)&&(a+="00");const i=new Date(a);return isNaN(i.getTime())?null:i.toISOString()},c.length=function(a,i,u,g,y){return r(!y||!1,"Invalid encoding:",y),a.$_addRule({name:i,method:"length",args:{limit:u,encoding:y},operator:g})}},8826:(_,b,m)=>{const r=m(375),p=m(8068),f={};f.Map=class extends Map{slice(){return new f.Map(this)}},_.exports=p.extend({type:"symbol",terms:{map:{init:new f.Map}},coerce:{method(h,{schema:t,error:l}){const o=t.$_terms.map.get(h);return o&&(h=o),t._flags.only&&typeof h!="symbol"?{value:h,errors:l("symbol.map",{map:t.$_terms.map})}:{value:h}}},validate(h,{error:t}){if(typeof h!="symbol")return{value:h,errors:t("symbol.base")}},rules:{map:{method(h){h&&!h[Symbol.iterator]&&typeof h=="object"&&(h=Object.entries(h)),r(h&&h[Symbol.iterator],"Iterable must be an iterable or object");const t=this.clone(),l=[];for(const o of h){r(o&&o[Symbol.iterator],"Entry must be an iterable");const[n,s]=o;r(typeof n!="object"&&typeof n!="function"&&typeof n!="symbol","Key must not be of type object, function, or Symbol"),r(typeof s=="symbol","Value must be a Symbol"),t.$_terms.map.set(n,s),l.push(s)}return t.valid(...l)}}},manifest:{build:(h,t)=>(t.map&&(h=h.map(t.map)),h)},messages:{"symbol.base":"{{#label}} must be a symbol","symbol.map":"{{#label}} must be one of {{#map}}"}})},8863:(_,b,m)=>{const r=m(375),p=m(8571),f=m(738),h=m(9621),t=m(8160),l=m(6354),o=m(493),n={result:Symbol("result")};b.entry=function(s,c,a){let i=t.defaults;a&&(r(a.warnings===void 0,"Cannot override warnings preference in synchronous validation"),r(a.artifacts===void 0,"Cannot override artifacts preference in synchronous validation"),i=t.preferences(t.defaults,a));const u=n.entry(s,c,i);r(!u.mainstay.externals.length,"Schema with external rules must use validateAsync()");const g={value:u.value};return u.error&&(g.error=u.error),u.mainstay.warnings.length&&(g.warning=l.details(u.mainstay.warnings)),u.mainstay.debug&&(g.debug=u.mainstay.debug),u.mainstay.artifacts&&(g.artifacts=u.mainstay.artifacts),g},b.entryAsync=async function(s,c,a){let i=t.defaults;a&&(i=t.preferences(t.defaults,a));const u=n.entry(s,c,i),g=u.mainstay;if(u.error)throw g.debug&&(u.error.debug=g.debug),u.error;if(g.externals.length){let k=u.value;const w=[];for(const d of g.externals){const v=d.state.path,j=d.schema.type==="link"?g.links.get(d.schema):null;let S,O,P=k;const D=v.length?[k]:[],I=v.length?h(s,v):s;if(v.length){S=v[v.length-1];let B=k;for(const N of v.slice(0,-1))B=B[N],D.unshift(B);O=D[0],P=O[S]}try{const B=(q,z)=>(j||d.schema).$_createError(q,P,z,d.state,i),N=await d.method(P,{schema:d.schema,linked:j,state:d.state,prefs:a,original:I,error:B,errorsArray:n.errorsArray,warn:(q,z)=>g.warnings.push((j||d.schema).$_createError(q,P,z,d.state,i)),message:(q,z)=>(j||d.schema).$_createError("external",P,z,d.state,i,{messages:q})});if(N===void 0||N===P)continue;if(N instanceof l.Report){if(g.tracer.log(d.schema,d.state,"rule","external","error"),w.push(N),i.abortEarly)break;continue}if(Array.isArray(N)&&N[t.symbols.errors]){if(g.tracer.log(d.schema,d.state,"rule","external","error"),w.push(...N),i.abortEarly)break;continue}O?(g.tracer.value(d.state,"rule",P,N,"external"),O[S]=N):(g.tracer.value(d.state,"rule",k,N,"external"),k=N)}catch(B){throw i.errors.label&&(B.message+=` (${d.label})`),B}}if(u.value=k,w.length)throw u.error=l.process(w,s,i),g.debug&&(u.error.debug=g.debug),u.error}if(!i.warnings&&!i.debug&&!i.artifacts)return u.value;const y={value:u.value};return g.warnings.length&&(y.warning=l.details(g.warnings)),g.debug&&(y.debug=g.debug),g.artifacts&&(y.artifacts=g.artifacts),y},n.Mainstay=class{constructor(s,c,a){this.externals=[],this.warnings=[],this.tracer=s,this.debug=c,this.links=a,this.shadow=null,this.artifacts=null,this._snapshots=[]}snapshot(){this._snapshots.push({externals:this.externals.slice(),warnings:this.warnings.slice()})}restore(){const s=this._snapshots.pop();this.externals=s.externals,this.warnings=s.warnings}commit(){this._snapshots.pop()}},n.entry=function(s,c,a){const{tracer:i,cleanup:u}=n.tracer(c,a),g=a.debug?[]:null,y=c._ids._schemaChain?new Map:null,k=new n.Mainstay(i,g,y),w=c._ids._schemaChain?[{schema:c}]:null,d=new o([],[],{mainstay:k,schemas:w}),v=b.validate(s,c,d,a);u&&c.$_root.untrace();const j=l.process(v.errors,s,a);return{value:v.value,error:j,mainstay:k}},n.tracer=function(s,c){return s.$_root._tracer?{tracer:s.$_root._tracer._register(s)}:c.debug?(r(s.$_root.trace,"Debug mode not supported"),{tracer:s.$_root.trace()._register(s),cleanup:!0}):{tracer:n.ignore}},b.validate=function(s,c,a,i,u={}){if(c.$_terms.whens&&(c=c._generate(s,a,i).schema),c._preferences&&(i=n.prefs(c,i)),c._cache&&i.cache){const j=c._cache.get(s);if(a.mainstay.tracer.debug(a,"validate","cached",!!j),j)return j}const g=(j,S,O)=>c.$_createError(j,s,S,O||a,i),y={original:s,prefs:i,schema:c,state:a,error:g,errorsArray:n.errorsArray,warn:(j,S,O)=>a.mainstay.warnings.push(g(j,S,O)),message:(j,S)=>c.$_createError("custom",s,S,a,i,{messages:j})};a.mainstay.tracer.entry(c,a);const k=c._definition;if(k.prepare&&s!==void 0&&i.convert){const j=k.prepare(s,y);if(j){if(a.mainstay.tracer.value(a,"prepare",s,j.value),j.errors)return n.finalize(j.value,[].concat(j.errors),y);s=j.value}}if(k.coerce&&s!==void 0&&i.convert&&(!k.coerce.from||k.coerce.from.includes(typeof s))){const j=k.coerce.method(s,y);if(j){if(a.mainstay.tracer.value(a,"coerced",s,j.value),j.errors)return n.finalize(j.value,[].concat(j.errors),y);s=j.value}}const w=c._flags.empty;w&&w.$_match(n.trim(s,c),a.nest(w),t.defaults)&&(a.mainstay.tracer.value(a,"empty",s,void 0),s=void 0);const d=u.presence||c._flags.presence||(c._flags._endedSwitch?null:i.presence);if(s===void 0){if(d==="forbidden")return n.finalize(s,null,y);if(d==="required")return n.finalize(s,[c.$_createError("any.required",s,null,a,i)],y);if(d==="optional"){if(c._flags.default!==t.symbols.deepDefault)return n.finalize(s,null,y);a.mainstay.tracer.value(a,"default",s,{}),s={}}}else if(d==="forbidden")return n.finalize(s,[c.$_createError("any.unknown",s,null,a,i)],y);const v=[];if(c._valids){const j=c._valids.get(s,a,i,c._flags.insensitive);if(j)return i.convert&&(a.mainstay.tracer.value(a,"valids",s,j.value),s=j.value),a.mainstay.tracer.filter(c,a,"valid",j),n.finalize(s,null,y);if(c._flags.only){const S=c.$_createError("any.only",s,{valids:c._valids.values({display:!0})},a,i);if(i.abortEarly)return n.finalize(s,[S],y);v.push(S)}}if(c._invalids){const j=c._invalids.get(s,a,i,c._flags.insensitive);if(j){a.mainstay.tracer.filter(c,a,"invalid",j);const S=c.$_createError("any.invalid",s,{invalids:c._invalids.values({display:!0})},a,i);if(i.abortEarly)return n.finalize(s,[S],y);v.push(S)}}if(k.validate){const j=k.validate(s,y);if(j&&(a.mainstay.tracer.value(a,"base",s,j.value),s=j.value,j.errors)){if(!Array.isArray(j.errors))return v.push(j.errors),n.finalize(s,v,y);if(j.errors.length)return v.push(...j.errors),n.finalize(s,v,y)}}return c._rules.length?n.rules(s,v,y):n.finalize(s,v,y)},n.rules=function(s,c,a){const{schema:i,state:u,prefs:g}=a;for(const y of i._rules){const k=i._definition.rules[y.method];if(k.convert&&g.convert){u.mainstay.tracer.log(i,u,"rule",y.name,"full");continue}let w,d=y.args;if(y._resolve.length){d=Object.assign({},d);for(const j of y._resolve){const S=k.argsByName.get(j),O=d[j].resolve(s,u,g),P=S.normalize?S.normalize(O):O,D=t.validateArg(P,null,S);if(D){w=i.$_createError("any.ref",O,{arg:j,ref:d[j],reason:D},u,g);break}d[j]=P}}w=w||k.validate(s,a,d,y);const v=n.rule(w,y);if(v.errors){if(u.mainstay.tracer.log(i,u,"rule",y.name,"error"),y.warn){u.mainstay.warnings.push(...v.errors);continue}if(g.abortEarly)return n.finalize(s,v.errors,a);c.push(...v.errors)}else u.mainstay.tracer.log(i,u,"rule",y.name,"pass"),u.mainstay.tracer.value(u,"rule",s,v.value,y.name),s=v.value}return n.finalize(s,c,a)},n.rule=function(s,c){return s instanceof l.Report?(n.error(s,c),{errors:[s],value:null}):Array.isArray(s)&&s[t.symbols.errors]?(s.forEach(a=>n.error(a,c)),{errors:s,value:null}):{errors:null,value:s}},n.error=function(s,c){return c.message&&s._setTemplate(c.message),s},n.finalize=function(s,c,a){c=c||[];const{schema:i,state:u,prefs:g}=a;if(c.length){const k=n.default("failover",void 0,c,a);k!==void 0&&(u.mainstay.tracer.value(u,"failover",s,k),s=k,c=[])}if(c.length&&i._flags.error)if(typeof i._flags.error=="function"){c=i._flags.error(c),Array.isArray(c)||(c=[c]);for(const k of c)r(k instanceof Error||k instanceof l.Report,"error() must return an Error object")}else c=[i._flags.error];if(s===void 0){const k=n.default("default",s,c,a);u.mainstay.tracer.value(u,"default",s,k),s=k}if(i._flags.cast&&s!==void 0){const k=i._definition.cast[i._flags.cast];if(k.from(s)){const w=k.to(s,a);u.mainstay.tracer.value(u,"cast",s,w,i._flags.cast),s=w}}if(i.$_terms.externals&&g.externals&&g._externals!==!1)for(const{method:k}of i.$_terms.externals)u.mainstay.externals.push({method:k,schema:i,state:u,label:l.label(i._flags,u,g)});const y={value:s,errors:c.length?c:null};return i._flags.result&&(y.value=i._flags.result==="strip"?void 0:a.original,u.mainstay.tracer.value(u,i._flags.result,s,y.value),u.shadow(s,i._flags.result)),i._cache&&g.cache!==!1&&!i._refs.length&&i._cache.set(a.original,y),s===void 0||y.errors||i._flags.artifact===void 0||(u.mainstay.artifacts=u.mainstay.artifacts||new Map,u.mainstay.artifacts.has(i._flags.artifact)||u.mainstay.artifacts.set(i._flags.artifact,[]),u.mainstay.artifacts.get(i._flags.artifact).push(u.path)),y},n.prefs=function(s,c){const a=c===t.defaults;return a&&s._preferences[t.symbols.prefs]?s._preferences[t.symbols.prefs]:(c=t.preferences(c,s._preferences),a&&(s._preferences[t.symbols.prefs]=c),c)},n.default=function(s,c,a,i){const{schema:u,state:g,prefs:y}=i,k=u._flags[s];if(y.noDefaults||k===void 0)return c;if(g.mainstay.tracer.log(u,g,"rule",s,"full"),!k)return k;if(typeof k=="function"){const w=k.length?[p(g.ancestors[0]),i]:[];try{return k(...w)}catch(d){return void a.push(u.$_createError(`any.${s}`,null,{error:d},g,y))}}return typeof k!="object"?k:k[t.symbols.literal]?k.literal:t.isResolvable(k)?k.resolve(c,g,y):p(k)},n.trim=function(s,c){if(typeof s!="string")return s;const a=c.$_getRule("trim");return a&&a.args.enabled?s.trim():s},n.ignore={active:!1,debug:f,entry:f,filter:f,log:f,resolve:f,value:f},n.errorsArray=function(){const s=[];return s[t.symbols.errors]=!0,s}},2036:(_,b,m)=>{const r=m(375),p=m(9474),f=m(8160),h={};_.exports=h.Values=class{constructor(t,l){this._values=new Set(t),this._refs=new Set(l),this._lowercase=h.lowercases(t),this._override=!1}get length(){return this._values.size+this._refs.size}add(t,l){f.isResolvable(t)?this._refs.has(t)||(this._refs.add(t),l&&l.register(t)):this.has(t,null,null,!1)||(this._values.add(t),typeof t=="string"&&this._lowercase.set(t.toLowerCase(),t))}static merge(t,l,o){if(t=t||new h.Values,l){if(l._override)return l.clone();for(const n of[...l._values,...l._refs])t.add(n)}if(o)for(const n of[...o._values,...o._refs])t.remove(n);return t.length?t:null}remove(t){f.isResolvable(t)?this._refs.delete(t):(this._values.delete(t),typeof t=="string"&&this._lowercase.delete(t.toLowerCase()))}has(t,l,o,n){return!!this.get(t,l,o,n)}get(t,l,o,n){if(!this.length)return!1;if(this._values.has(t))return{value:t};if(typeof t=="string"&&t&&n){const s=this._lowercase.get(t.toLowerCase());if(s)return{value:s}}if(!this._refs.size&&typeof t!="object")return!1;if(typeof t=="object"){for(const s of this._values)if(p(s,t))return{value:s}}if(l)for(const s of this._refs){const c=s.resolve(t,l,o,null,{in:!0});if(c===void 0)continue;const a=s.in&&typeof c=="object"?Array.isArray(c)?c:Object.keys(c):[c];for(const i of a)if(typeof i==typeof t){if(n&&t&&typeof t=="string"){if(i.toLowerCase()===t.toLowerCase())return{value:i,ref:s}}else if(p(i,t))return{value:i,ref:s}}}return!1}override(){this._override=!0}values(t){if(t&&t.display){const l=[];for(const o of[...this._values,...this._refs])o!==void 0&&l.push(o);return l}return Array.from([...this._values,...this._refs])}clone(){const t=new h.Values(this._values,this._refs);return t._override=this._override,t}concat(t){r(!t._override,"Cannot concat override set of values");const l=new h.Values([...this._values,...t._values],[...this._refs,...t._refs]);return l._override=this._override,l}describe(){const t=[];this._override&&t.push({override:!0});for(const l of this._values.values())t.push(l&&typeof l=="object"?{value:l}:l);for(const l of this._refs.values())t.push(l.describe());return t}},h.Values.prototype[f.symbols.values]=!0,h.Values.prototype.slice=h.Values.prototype.clone,h.lowercases=function(t){const l=new Map;if(t)for(const o of t)typeof o=="string"&&l.set(o.toLowerCase(),o);return l}},978:(_,b,m)=>{const r=m(375),p=m(8571),f=m(1687),h=m(9621),t={};_.exports=function(l,o,n={}){if(r(l&&typeof l=="object","Invalid defaults value: must be an object"),r(!o||o===!0||typeof o=="object","Invalid source value: must be true, falsy or an object"),r(typeof n=="object","Invalid options: must be an object"),!o)return null;if(n.shallow)return t.applyToDefaultsWithShallow(l,o,n);const s=p(l);if(o===!0)return s;const c=n.nullOverride!==void 0&&n.nullOverride;return f(s,o,{nullOverride:c,mergeArrays:!1})},t.applyToDefaultsWithShallow=function(l,o,n){const s=n.shallow;r(Array.isArray(s),"Invalid keys");const c=new Map,a=o===!0?null:new Set;for(let g of s){g=Array.isArray(g)?g:g.split(".");const y=h(l,g);y&&typeof y=="object"?c.set(y,a&&h(o,g)||y):a&&a.add(g)}const i=p(l,{},c);if(!a)return i;for(const g of a)t.reachCopy(i,o,g);const u=n.nullOverride!==void 0&&n.nullOverride;return f(i,o,{nullOverride:u,mergeArrays:!1})},t.reachCopy=function(l,o,n){for(const a of n){if(!(a in o))return;const i=o[a];if(typeof i!="object"||i===null)return;o=i}const s=o;let c=l;for(let a=0;a<n.length-1;++a){const i=n[a];typeof c[i]!="object"&&(c[i]={}),c=c[i]}c[n[n.length-1]]=s}},375:(_,b,m)=>{const r=m(7916);_.exports=function(p,...f){if(!p)throw f.length===1&&f[0]instanceof Error?f[0]:new r(f)}},8571:(_,b,m)=>{const r=m(9621),p=m(4277),f=m(7043),h={needsProtoHack:new Set([p.set,p.map,p.weakSet,p.weakMap])};_.exports=h.clone=function(t,l={},o=null){if(typeof t!="object"||t===null)return t;let n=h.clone,s=o;if(l.shallow){if(l.shallow!==!0)return h.cloneWithShallow(t,l);n=u=>u}else if(s){const u=s.get(t);if(u)return u}else s=new Map;const c=p.getInternalProto(t);if(c===p.buffer)return!1;if(c===p.date)return new Date(t.getTime());if(c===p.regex)return new RegExp(t);const a=h.base(t,c,l);if(a===t)return t;if(s&&s.set(t,a),c===p.set)for(const u of t)a.add(n(u,l,s));else if(c===p.map)for(const[u,g]of t)a.set(u,n(g,l,s));const i=f.keys(t,l);for(const u of i){if(u==="__proto__")continue;if(c===p.array&&u==="length"){a.length=t.length;continue}const g=Object.getOwnPropertyDescriptor(t,u);g?g.get||g.set?Object.defineProperty(a,u,g):g.enumerable?a[u]=n(t[u],l,s):Object.defineProperty(a,u,{enumerable:!1,writable:!0,configurable:!0,value:n(t[u],l,s)}):Object.defineProperty(a,u,{enumerable:!0,writable:!0,configurable:!0,value:n(t[u],l,s)})}return a},h.cloneWithShallow=function(t,l){const o=l.shallow;(l=Object.assign({},l)).shallow=!1;const n=new Map;for(const s of o){const c=r(t,s);typeof c!="object"&&typeof c!="function"||n.set(c,c)}return h.clone(t,l,n)},h.base=function(t,l,o){if(o.prototype===!1)return h.needsProtoHack.has(l)?new l.constructor:l===p.array?[]:{};const n=Object.getPrototypeOf(t);if(n&&n.isImmutable)return t;if(l===p.array){const s=[];return n!==l&&Object.setPrototypeOf(s,n),s}if(h.needsProtoHack.has(l)){const s=new n.constructor;return n!==l&&Object.setPrototypeOf(s,n),s}return Object.create(n)}},9474:(_,b,m)=>{const r=m(4277),p={mismatched:null};_.exports=function(f,h,t){return t=Object.assign({prototype:!0},t),!!p.isDeepEqual(f,h,t,[])},p.isDeepEqual=function(f,h,t,l){if(f===h)return f!==0||1/f==1/h;const o=typeof f;if(o!==typeof h||f===null||h===null)return!1;if(o==="function"){if(!t.deepFunction||f.toString()!==h.toString())return!1}else if(o!=="object")return f!=f&&h!=h;const n=p.getSharedType(f,h,!!t.prototype);switch(n){case r.buffer:return!1;case r.promise:return f===h;case r.regex:return f.toString()===h.toString();case p.mismatched:return!1}for(let s=l.length-1;s>=0;--s)if(l[s].isSame(f,h))return!0;l.push(new p.SeenEntry(f,h));try{return!!p.isDeepEqualObj(n,f,h,t,l)}finally{l.pop()}},p.getSharedType=function(f,h,t){if(t)return Object.getPrototypeOf(f)!==Object.getPrototypeOf(h)?p.mismatched:r.getInternalProto(f);const l=r.getInternalProto(f);return l!==r.getInternalProto(h)?p.mismatched:l},p.valueOf=function(f){const h=f.valueOf;if(h===void 0)return f;try{return h.call(f)}catch(t){return t}},p.hasOwnEnumerableProperty=function(f,h){return Object.prototype.propertyIsEnumerable.call(f,h)},p.isSetSimpleEqual=function(f,h){for(const t of Set.prototype.values.call(f))if(!Set.prototype.has.call(h,t))return!1;return!0},p.isDeepEqualObj=function(f,h,t,l,o){const{isDeepEqual:n,valueOf:s,hasOwnEnumerableProperty:c}=p,{keys:a,getOwnPropertySymbols:i}=Object;if(f===r.array){if(!l.part){if(h.length!==t.length)return!1;for(let w=0;w<h.length;++w)if(!n(h[w],t[w],l,o))return!1;return!0}for(const w of h)for(const d of t)if(n(w,d,l,o))return!0}else if(f===r.set){if(h.size!==t.size)return!1;if(!p.isSetSimpleEqual(h,t)){const w=new Set(Set.prototype.values.call(t));for(const d of Set.prototype.values.call(h)){if(w.delete(d))continue;let v=!1;for(const j of w)if(n(d,j,l,o)){w.delete(j),v=!0;break}if(!v)return!1}}}else if(f===r.map){if(h.size!==t.size)return!1;for(const[w,d]of Map.prototype.entries.call(h))if(d===void 0&&!Map.prototype.has.call(t,w)||!n(d,Map.prototype.get.call(t,w),l,o))return!1}else if(f===r.error&&(h.name!==t.name||h.message!==t.message))return!1;const u=s(h),g=s(t);if((h!==u||t!==g)&&!n(u,g,l,o))return!1;const y=a(h);if(!l.part&&y.length!==a(t).length&&!l.skip)return!1;let k=0;for(const w of y)if(l.skip&&l.skip.includes(w))t[w]===void 0&&++k;else if(!c(t,w)||!n(h[w],t[w],l,o))return!1;if(!l.part&&y.length-k!==a(t).length)return!1;if(l.symbols!==!1){const w=i(h),d=new Set(i(t));for(const v of w){if(!l.skip||!l.skip.includes(v)){if(c(h,v)){if(!c(t,v)||!n(h[v],t[v],l,o))return!1}else if(c(t,v))return!1}d.delete(v)}for(const v of d)if(c(t,v))return!1}return!0},p.SeenEntry=class{constructor(f,h){this.obj=f,this.ref=h}isSame(f,h){return this.obj===f&&this.ref===h}}},7916:(_,b,m)=>{const r=m(8761);_.exports=class extends Error{constructor(p){super(p.filter(f=>f!=="").map(f=>typeof f=="string"?f:f instanceof Error?f.message:r(f)).join(" ")||"Unknown error"),typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,b.assert)}}},5277:_=>{const b={};_.exports=function(m){if(!m)return"";let r="";for(let p=0;p<m.length;++p){const f=m.charCodeAt(p);b.isSafe(f)?r+=m[p]:r+=b.escapeHtmlChar(f)}return r},b.escapeHtmlChar=function(m){return b.namedHtml.get(m)||(m>=256?"&#"+m+";":`&#x${m.toString(16).padStart(2,"0")};`)},b.isSafe=function(m){return b.safeCharCodes.has(m)},b.namedHtml=new Map([[38,"&"],[60,"<"],[62,">"],[34,"""],[160," "],[162,"¢"],[163,"£"],[164,"¤"],[169,"©"],[174,"®"]]),b.safeCharCodes=function(){const m=new Set;for(let r=32;r<123;++r)(r>=97||r>=65&&r<=90||r>=48&&r<=57||r===32||r===46||r===44||r===45||r===58||r===95)&&m.add(r);return m}()},6064:_=>{_.exports=function(b){return b.replace(/[\^\$\.\*\+\-\?\=\!\:\|\\\/\(\)\[\]\{\}\,]/g,"\\$&")}},738:_=>{_.exports=function(){}},1687:(_,b,m)=>{const r=m(375),p=m(8571),f=m(7043),h={};_.exports=h.merge=function(t,l,o){if(r(t&&typeof t=="object","Invalid target value: must be an object"),r(l==null||typeof l=="object","Invalid source value: must be null, undefined, or an object"),!l)return t;if(o=Object.assign({nullOverride:!0,mergeArrays:!0},o),Array.isArray(l)){r(Array.isArray(t),"Cannot merge array onto an object"),o.mergeArrays||(t.length=0);for(let s=0;s<l.length;++s)t.push(p(l[s],{symbols:o.symbols}));return t}const n=f.keys(l,o);for(let s=0;s<n.length;++s){const c=n[s];if(c==="__proto__"||!Object.prototype.propertyIsEnumerable.call(l,c))continue;const a=l[c];if(a&&typeof a=="object"){if(t[c]===a)continue;!t[c]||typeof t[c]!="object"||Array.isArray(t[c])!==Array.isArray(a)||a instanceof Date||a instanceof RegExp?t[c]=p(a,{symbols:o.symbols}):h.merge(t[c],a,o)}else(a!=null||o.nullOverride)&&(t[c]=a)}return t}},9621:(_,b,m)=>{const r=m(375),p={};_.exports=function(f,h,t){if(h===!1||h==null)return f;typeof(t=t||{})=="string"&&(t={separator:t});const l=Array.isArray(h);r(!l||!t.separator,"Separator option is not valid for array-based chain");const o=l?h:h.split(t.separator||".");let n=f;for(let s=0;s<o.length;++s){let c=o[s];const a=t.iterables&&p.iterables(n);if(Array.isArray(n)||a==="set"){const i=Number(c);Number.isInteger(i)&&(c=i<0?n.length+i:i)}if(!n||typeof n=="function"&&t.functions===!1||!a&&n[c]===void 0){r(!t.strict||s+1===o.length,"Missing segment",c,"in reach path ",h),r(typeof n=="object"||t.functions===!0||typeof n!="function","Invalid segment",c,"in reach path ",h),n=t.default;break}n=a?a==="set"?[...n][c]:n.get(c):n[c]}return n},p.iterables=function(f){return f instanceof Set?"set":f instanceof Map?"map":void 0}},8761:_=>{_.exports=function(...b){try{return JSON.stringify(...b)}catch(m){return"[Cannot display object: "+m.message+"]"}}},4277:(_,b)=>{const m={};b=_.exports={array:Array.prototype,buffer:!1,date:Date.prototype,error:Error.prototype,generic:Object.prototype,map:Map.prototype,promise:Promise.prototype,regex:RegExp.prototype,set:Set.prototype,weakMap:WeakMap.prototype,weakSet:WeakSet.prototype},m.typeMap=new Map([["[object Error]",b.error],["[object Map]",b.map],["[object Promise]",b.promise],["[object Set]",b.set],["[object WeakMap]",b.weakMap],["[object WeakSet]",b.weakSet]]),b.getInternalProto=function(r){if(Array.isArray(r))return b.array;if(r instanceof Date)return b.date;if(r instanceof RegExp)return b.regex;if(r instanceof Error)return b.error;const p=Object.prototype.toString.call(r);return m.typeMap.get(p)||b.generic}},7043:(_,b)=>{b.keys=function(m,r={}){return r.symbols!==!1?Reflect.ownKeys(m):Object.getOwnPropertyNames(m)}},3652:(_,b,m)=>{const r=m(375),p={};b.Sorter=class{constructor(){this._items=[],this.nodes=[]}add(f,h){const t=[].concat((h=h||{}).before||[]),l=[].concat(h.after||[]),o=h.group||"?",n=h.sort||0;r(!t.includes(o),`Item cannot come before itself: ${o}`),r(!t.includes("?"),"Item cannot come before unassociated items"),r(!l.includes(o),`Item cannot come after itself: ${o}`),r(!l.includes("?"),"Item cannot come after unassociated items"),Array.isArray(f)||(f=[f]);for(const s of f){const c={seq:this._items.length,sort:n,before:t,after:l,group:o,node:s};this._items.push(c)}if(!h.manual){const s=this._sort();r(s,"item",o!=="?"?`added into group ${o}`:"","created a dependencies error")}return this.nodes}merge(f){Array.isArray(f)||(f=[f]);for(const t of f)if(t)for(const l of t._items)this._items.push(Object.assign({},l));this._items.sort(p.mergeSort);for(let t=0;t<this._items.length;++t)this._items[t].seq=t;const h=this._sort();return r(h,"merge created a dependencies error"),this.nodes}sort(){const f=this._sort();return r(f,"sort created a dependencies error"),this.nodes}_sort(){const f={},h=Object.create(null),t=Object.create(null);for(const c of this._items){const a=c.seq,i=c.group;t[i]=t[i]||[],t[i].push(a),f[a]=c.before;for(const u of c.after)h[u]=h[u]||[],h[u].push(a)}for(const c in f){const a=[];for(const i in f[c]){const u=f[c][i];t[u]=t[u]||[],a.push(...t[u])}f[c]=a}for(const c in h)if(t[c])for(const a of t[c])f[a].push(...h[c]);const l={};for(const c in f){const a=f[c];for(const i of a)l[i]=l[i]||[],l[i].push(c)}const o={},n=[];for(let c=0;c<this._items.length;++c){let a=c;if(l[c]){a=null;for(let i=0;i<this._items.length;++i){if(o[i]===!0)continue;l[i]||(l[i]=[]);const u=l[i].length;let g=0;for(let y=0;y<u;++y)o[l[i][y]]&&++g;if(g===u){a=i;break}}}a!==null&&(o[a]=!0,n.push(a))}if(n.length!==this._items.length)return!1;const s={};for(const c of this._items)s[c.seq]=c;this._items=[],this.nodes=[];for(const c of n){const a=s[c];this.nodes.push(a.node),this._items.push(a)}return!0}},p.mergeSort=(f,h)=>f.sort===h.sort?0:f.sort<h.sort?-1:1},5380:(_,b,m)=>{const r=m(443),p=m(2178),f={minDomainSegments:2,nonAsciiRx:/[^\x00-\x7f]/,domainControlRx:/[\x00-\x20@\:\/\\#!\$&\'\(\)\*\+,;=\?]/,tldSegmentRx:/^[a-zA-Z](?:[a-zA-Z0-9\-]*[a-zA-Z0-9])?$/,domainSegmentRx:/^[a-zA-Z0-9](?:[a-zA-Z0-9\-]*[a-zA-Z0-9])?$/,URL:r.URL||URL};b.analyze=function(h,t={}){if(!h)return p.code("DOMAIN_NON_EMPTY_STRING");if(typeof h!="string")throw new Error("Invalid input: domain must be a string");if(h.length>256)return p.code("DOMAIN_TOO_LONG");if(f.nonAsciiRx.test(h)){if(t.allowUnicode===!1)return p.code("DOMAIN_INVALID_UNICODE_CHARS");h=h.normalize("NFC")}if(f.domainControlRx.test(h))return p.code("DOMAIN_INVALID_CHARS");h=f.punycode(h),t.allowFullyQualified&&h[h.length-1]==="."&&(h=h.slice(0,-1));const l=t.minDomainSegments||f.minDomainSegments,o=h.split(".");if(o.length<l)return p.code("DOMAIN_SEGMENTS_COUNT");if(t.maxDomainSegments&&o.length>t.maxDomainSegments)return p.code("DOMAIN_SEGMENTS_COUNT_MAX");const n=t.tlds;if(n){const s=o[o.length-1].toLowerCase();if(n.deny&&n.deny.has(s)||n.allow&&!n.allow.has(s))return p.code("DOMAIN_FORBIDDEN_TLDS")}for(let s=0;s<o.length;++s){const c=o[s];if(!c.length)return p.code("DOMAIN_EMPTY_SEGMENT");if(c.length>63)return p.code("DOMAIN_LONG_SEGMENT");if(s<o.length-1){if(!f.domainSegmentRx.test(c))return p.code("DOMAIN_INVALID_CHARS")}else if(!f.tldSegmentRx.test(c))return p.code("DOMAIN_INVALID_TLDS_CHARS")}return null},b.isValid=function(h,t){return!b.analyze(h,t)},f.punycode=function(h){h.includes("%")&&(h=h.replace(/%/g,"%25"));try{return new f.URL(`http://${h}`).host}catch{return h}}},1745:(_,b,m)=>{const r=m(9848),p=m(5380),f=m(2178),h={nonAsciiRx:/[^\x00-\x7f]/,encoder:new(r.TextEncoder||TextEncoder)};b.analyze=function(t,l){return h.email(t,l)},b.isValid=function(t,l){return!h.email(t,l)},h.email=function(t,l={}){if(typeof t!="string")throw new Error("Invalid input: email must be a string");if(!t)return f.code("EMPTY_STRING");const o=!h.nonAsciiRx.test(t);if(!o){if(l.allowUnicode===!1)return f.code("FORBIDDEN_UNICODE");t=t.normalize("NFC")}const n=t.split("@");if(n.length!==2)return n.length>2?f.code("MULTIPLE_AT_CHAR"):f.code("MISSING_AT_CHAR");const[s,c]=n;if(!s)return f.code("EMPTY_LOCAL");if(!l.ignoreLength){if(t.length>254)return f.code("ADDRESS_TOO_LONG");if(h.encoder.encode(s).length>64)return f.code("LOCAL_TOO_LONG")}return h.local(s,o)||p.analyze(c,l)},h.local=function(t,l){const o=t.split(".");for(const n of o){if(!n.length)return f.code("EMPTY_LOCAL_SEGMENT");if(l){if(!h.atextRx.test(n))return f.code("INVALID_LOCAL_CHARS")}else for(const s of n){if(h.atextRx.test(s))continue;const c=h.binary(s);if(!h.atomRx.test(c))return f.code("INVALID_LOCAL_CHARS")}}},h.binary=function(t){return Array.from(h.encoder.encode(t)).map(l=>String.fromCharCode(l)).join("")},h.atextRx=/^[\w!#\$%&'\*\+\-/=\?\^`\{\|\}~]+$/,h.atomRx=new RegExp(["(?:[\\xc2-\\xdf][\\x80-\\xbf])","(?:\\xe0[\\xa0-\\xbf][\\x80-\\xbf])|(?:[\\xe1-\\xec][\\x80-\\xbf]{2})|(?:\\xed[\\x80-\\x9f][\\x80-\\xbf])|(?:[\\xee-\\xef][\\x80-\\xbf]{2})","(?:\\xf0[\\x90-\\xbf][\\x80-\\xbf]{2})|(?:[\\xf1-\\xf3][\\x80-\\xbf]{3})|(?:\\xf4[\\x80-\\x8f][\\x80-\\xbf]{2})"].join("|"))},2178:(_,b)=>{b.codes={EMPTY_STRING:"Address must be a non-empty string",FORBIDDEN_UNICODE:"Address contains forbidden Unicode characters",MULTIPLE_AT_CHAR:"Address cannot contain more than one @ character",MISSING_AT_CHAR:"Address must contain one @ character",EMPTY_LOCAL:"Address local part cannot be empty",ADDRESS_TOO_LONG:"Address too long",LOCAL_TOO_LONG:"Address local part too long",EMPTY_LOCAL_SEGMENT:"Address local part contains empty dot-separated segment",INVALID_LOCAL_CHARS:"Address local part contains invalid character",DOMAIN_NON_EMPTY_STRING:"Domain must be a non-empty string",DOMAIN_TOO_LONG:"Domain too long",DOMAIN_INVALID_UNICODE_CHARS:"Domain contains forbidden Unicode characters",DOMAIN_INVALID_CHARS:"Domain contains invalid character",DOMAIN_INVALID_TLDS_CHARS:"Domain contains invalid tld character",DOMAIN_SEGMENTS_COUNT:"Domain lacks the minimum required number of segments",DOMAIN_SEGMENTS_COUNT_MAX:"Domain contains too many segments",DOMAIN_FORBIDDEN_TLDS:"Domain uses forbidden TLD",DOMAIN_EMPTY_SEGMENT:"Domain contains empty dot-separated segment",DOMAIN_LONG_SEGMENT:"Domain contains dot-separated segment that is too long"},b.code=function(m){return{code:m,error:b.codes[m]}}},9959:(_,b,m)=>{const r=m(375),p=m(5752);b.regex=function(f={}){r(f.cidr===void 0||typeof f.cidr=="string","options.cidr must be a string");const h=f.cidr?f.cidr.toLowerCase():"optional";r(["required","optional","forbidden"].includes(h),"options.cidr must be one of required, optional, forbidden"),r(f.version===void 0||typeof f.version=="string"||Array.isArray(f.version),"options.version must be a string or an array of string");let t=f.version||["ipv4","ipv6","ipvfuture"];Array.isArray(t)||(t=[t]),r(t.length>=1,"options.version must have at least 1 version specified");for(let n=0;n<t.length;++n)r(typeof t[n]=="string","options.version must only contain strings"),t[n]=t[n].toLowerCase(),r(["ipv4","ipv6","ipvfuture"].includes(t[n]),"options.version contains unknown version "+t[n]+" - must be one of ipv4, ipv6, ipvfuture");t=Array.from(new Set(t));const l=`(?:${t.map(n=>{if(h==="forbidden")return p.ip[n];const s=`\\/${n==="ipv4"?p.ip.v4Cidr:p.ip.v6Cidr}`;return h==="required"?`${p.ip[n]}${s}`:`${p.ip[n]}(?:${s})?`}).join("|")})`,o=new RegExp(`^${l}$`);return{cidr:h,versions:t,regex:o,raw:l}}},5752:(_,b,m)=>{const r=m(375),p=m(6064),f={generate:function(){const h={},t="\\dA-Fa-f",l="["+t+"]",o="\\w-\\.~",n="!\\$&'\\(\\)\\*\\+,;=",s="%"+t,c=o+s+n+":@",a="["+c+"]",i="(?:0{0,2}\\d|0?[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])";h.ipv4address="(?:"+i+"\\.){3}"+i;const u=l+"{1,4}",g="(?:"+u+":"+u+"|"+h.ipv4address+")",y="(?:"+u+":){6}"+g,k="::(?:"+u+":){5}"+g,w="(?:"+u+")?::(?:"+u+":){4}"+g,d="(?:(?:"+u+":){0,1}"+u+")?::(?:"+u+":){3}"+g,v="(?:(?:"+u+":){0,2}"+u+")?::(?:"+u+":){2}"+g,j="(?:(?:"+u+":){0,3}"+u+")?::"+u+":"+g,S="(?:(?:"+u+":){0,4}"+u+")?::"+g,O="(?:(?:"+u+":){0,5}"+u+")?::"+u,P="(?:(?:"+u+":){0,6}"+u+")?::";h.ipv4Cidr="(?:\\d|[1-2]\\d|3[0-2])",h.ipv6Cidr="(?:0{0,2}\\d|0?[1-9]\\d|1[01]\\d|12[0-8])",h.ipv6address="(?:"+y+"|"+k+"|"+w+"|"+d+"|"+v+"|"+j+"|"+S+"|"+O+"|"+P+")",h.ipvFuture="v"+l+"+\\.["+o+n+":]+",h.scheme="[a-zA-Z][a-zA-Z\\d+-\\.]*",h.schemeRegex=new RegExp(h.scheme);const D="["+o+s+n+":]*",I="["+o+s+n+"]{1,255}",B="(?:\\[(?:"+h.ipv6address+"|"+h.ipvFuture+")\\]|"+h.ipv4address+"|"+I+")",N="(?:"+D+"@)?"+B+"(?::\\d*)?",q="(?:"+D+"@)?("+B+")(?::\\d*)?",z=a+"*",F=a+"+",V="(?:\\/"+z+")*",le="\\/(?:"+F+V+")?",me=F+V,be="["+o+s+n+"@]+"+V,De="(?:\\/\\/\\/"+z+V+")";return h.hierPart="(?:(?:\\/\\/"+N+V+")|"+le+"|"+me+"|"+De+")",h.hierPartCapture="(?:(?:\\/\\/"+q+V+")|"+le+"|"+me+")",h.relativeRef="(?:(?:\\/\\/"+N+V+")|"+le+"|"+be+"|)",h.relativeRefCapture="(?:(?:\\/\\/"+q+V+")|"+le+"|"+be+"|)",h.query="["+c+"\\/\\?]*(?=#|$)",h.queryWithSquareBrackets="["+c+"\\[\\]\\/\\?]*(?=#|$)",h.fragment="["+c+"\\/\\?]*",h}};f.rfc3986=f.generate(),b.ip={v4Cidr:f.rfc3986.ipv4Cidr,v6Cidr:f.rfc3986.ipv6Cidr,ipv4:f.rfc3986.ipv4address,ipv6:f.rfc3986.ipv6address,ipvfuture:f.rfc3986.ipvFuture},f.createRegex=function(h){const t=f.rfc3986,l="(?:\\?"+(h.allowQuerySquareBrackets?t.queryWithSquareBrackets:t.query)+")?(?:#"+t.fragment+")?",o=h.domain?t.relativeRefCapture:t.relativeRef;if(h.relativeOnly)return f.wrap(o+l);let n="";if(h.scheme){r(h.scheme instanceof RegExp||typeof h.scheme=="string"||Array.isArray(h.scheme),"scheme must be a RegExp, String, or Array");const a=[].concat(h.scheme);r(a.length>=1,"scheme must have at least 1 scheme specified");const i=[];for(let u=0;u<a.length;++u){const g=a[u];r(g instanceof RegExp||typeof g=="string","scheme at position "+u+" must be a RegExp or String"),g instanceof RegExp?i.push(g.source.toString()):(r(t.schemeRegex.test(g),"scheme at position "+u+" must be a valid scheme"),i.push(p(g)))}n=i.join("|")}const s="(?:"+(n?"(?:"+n+")":t.scheme)+":"+(h.domain?t.hierPartCapture:t.hierPart)+")",c=h.allowRelative?"(?:"+s+"|"+o+")":s;return f.wrap(c+l,n)},f.wrap=function(h,t){return{raw:h=`(?=.)(?!https?:/(?:$|[^/]))(?!https?:///)(?!https?:[^/])${h}`,regex:new RegExp(`^${h}$`),scheme:t}},f.uriRegex=f.createRegex({}),b.regex=function(h={}){return h.scheme||h.allowRelative||h.relativeOnly||h.allowQuerySquareBrackets||h.domain?f.createRegex(h):f.uriRegex}},1447:(_,b)=>{const m={operators:["!","^","*","/","%","+","-","<","<=",">",">=","==","!=","&&","||","??"],operatorCharacters:["!","^","*","/","%","+","-","<","=",">","&","|","?"],operatorsOrder:[["^"],["*","/","%"],["+","-"],["<","<=",">",">="],["==","!="],["&&"],["||","??"]],operatorsPrefix:["!","n"],literals:{'"':'"',"`":"`","'":"'","[":"]"},numberRx:/^(?:[0-9]*(\.[0-9]*)?){1}$/,tokenRx:/^[\w\$\#\.\@\:\{\}]+$/,symbol:Symbol("formula"),settings:Symbol("settings")};b.Parser=class{constructor(r,p={}){if(!p[m.settings]&&p.constants)for(const f in p.constants){const h=p.constants[f];if(h!==null&&!["boolean","number","string"].includes(typeof h))throw new Error(`Formula constant ${f} contains invalid ${typeof h} value type`)}this.settings=p[m.settings]?p:Object.assign({[m.settings]:!0,constants:{},functions:{}},p),this.single=null,this._parts=null,this._parse(r)}_parse(r){let p=[],f="",h=0,t=!1;const l=n=>{if(h)throw new Error("Formula missing closing parenthesis");const s=p.length?p[p.length-1]:null;if(t||f||n){if(s&&s.type==="reference"&&n===")")return s.type="function",s.value=this._subFormula(f,s.value),void(f="");if(n===")"){const c=new b.Parser(f,this.settings);p.push({type:"segment",value:c})}else if(t){if(t==="]")return p.push({type:"reference",value:f}),void(f="");p.push({type:"literal",value:f})}else if(m.operatorCharacters.includes(f))s&&s.type==="operator"&&m.operators.includes(s.value+f)?s.value+=f:p.push({type:"operator",value:f});else if(f.match(m.numberRx))p.push({type:"constant",value:parseFloat(f)});else if(this.settings.constants[f]!==void 0)p.push({type:"constant",value:this.settings.constants[f]});else{if(!f.match(m.tokenRx))throw new Error(`Formula contains invalid token: ${f}`);p.push({type:"reference",value:f})}f=""}};for(const n of r)t?n===t?(l(),t=!1):f+=n:h?n==="("?(f+=n,++h):n===")"?(--h,h?f+=n:l(n)):f+=n:n in m.literals?t=m.literals[n]:n==="("?(l(),++h):m.operatorCharacters.includes(n)?(l(),f=n,l()):n!==" "?f+=n:l();l(),p=p.map((n,s)=>n.type!=="operator"||n.value!=="-"||s&&p[s-1].type!=="operator"?n:{type:"operator",value:"n"});let o=!1;for(const n of p){if(n.type==="operator"){if(m.operatorsPrefix.includes(n.value))continue;if(!o)throw new Error("Formula contains an operator in invalid position");if(!m.operators.includes(n.value))throw new Error(`Formula contains an unknown operator ${n.value}`)}else if(o)throw new Error("Formula missing expected operator");o=!o}if(!o)throw new Error("Formula contains invalid trailing operator");p.length===1&&["reference","literal","constant"].includes(p[0].type)&&(this.single={type:p[0].type==="reference"?"reference":"value",value:p[0].value}),this._parts=p.map(n=>{if(n.type==="operator")return m.operatorsPrefix.includes(n.value)?n:n.value;if(n.type!=="reference")return n.value;if(this.settings.tokenRx&&!this.settings.tokenRx.test(n.value))throw new Error(`Formula contains invalid reference ${n.value}`);return this.settings.reference?this.settings.reference(n.value):m.reference(n.value)})}_subFormula(r,p){const f=this.settings.functions[p];if(typeof f!="function")throw new Error(`Formula contains unknown function ${p}`);let h=[];if(r){let t="",l=0,o=!1;const n=()=>{if(!t)throw new Error(`Formula contains function ${p} with invalid arguments ${r}`);h.push(t),t=""};for(let s=0;s<r.length;++s){const c=r[s];o?(t+=c,c===o&&(o=!1)):c in m.literals&&!l?(t+=c,o=m.literals[c]):c!==","||l?(t+=c,c==="("?++l:c===")"&&--l):n()}n()}return h=h.map(t=>new b.Parser(t,this.settings)),function(t){const l=[];for(const o of h)l.push(o.evaluate(t));return f.call(t,...l)}}evaluate(r){const p=this._parts.slice();for(let f=p.length-2;f>=0;--f){const h=p[f];if(h&&h.type==="operator"){const t=p[f+1];p.splice(f+1,1);const l=m.evaluate(t,r);p[f]=m.single(h.value,l)}}return m.operatorsOrder.forEach(f=>{for(let h=1;h<p.length-1;)if(f.includes(p[h])){const t=p[h],l=m.evaluate(p[h-1],r),o=m.evaluate(p[h+1],r);p.splice(h,2);const n=m.calculate(t,l,o);p[h-1]=n===0?0:n}else h+=2}),m.evaluate(p[0],r)}},b.Parser.prototype[m.symbol]=!0,m.reference=function(r){return function(p){return p&&p[r]!==void 0?p[r]:null}},m.evaluate=function(r,p){return r===null?null:typeof r=="function"?r(p):r[m.symbol]?r.evaluate(p):r},m.single=function(r,p){if(r==="!")return!p;const f=-p;return f===0?0:f},m.calculate=function(r,p,f){if(r==="??")return m.exists(p)?p:f;if(typeof p=="string"||typeof f=="string"){if(r==="+")return(p=m.exists(p)?p:"")+(m.exists(f)?f:"")}else switch(r){case"^":return Math.pow(p,f);case"*":return p*f;case"/":return p/f;case"%":return p%f;case"+":return p+f;case"-":return p-f}switch(r){case"<":return p<f;case"<=":return p<=f;case">":return p>f;case">=":return p>=f;case"==":return p===f;case"!=":return p!==f;case"&&":return p&&f;case"||":return p||f}return null},m.exists=function(r){return r!=null}},9926:()=>{},5688:()=>{},9708:()=>{},1152:()=>{},443:()=>{},9848:()=>{},5934:_=>{_.exports=JSON.parse('{"version":"17.13.3"}')}},R={},function _(b){var m=R[b];if(m!==void 0)return m.exports;var r=R[b]={exports:{}};return $[b](r,r.exports,_),r.exports}(5107);var $,R})}(Ye)),Ye.exports}var Oe={},Dt;function gn(){if(Dt)return Oe;Dt=1;var x=Oe&&Oe.__importDefault||function(R){return R&&R.__esModule?R:{default:R}};Object.defineProperty(Oe,"__esModule",{value:!0}),Oe.BNExtension=$;const C=x(Ws());function $(R){return{type:"BN",base:R.any(),messages:{"bn.nan":"{{#label}} is not a big number","bn.max":'{{#label}} needs to be less than or equal to "{{#threshold}}"',"bn.min":'{{#label}} needs to be greater than or equal to "{{#threshold}}"',"bn.less":'{{#label}} needs to be less than "{{#threshold}}"',"bn.greater":'{{#label}} needs to be greater than "{{#threshold}}"',"bn.positive":"{{#label}} needs to be positive","bn.negative":"{{#label}} needs to be negative"},prepare(_,b){try{return{value:new C.default(_)}}catch{return{errors:b.error("bn.nan")}}},coerce(_){return{value:_.toString(10)}},validate(_){return{value:_}},rules:{gt:{args:[{name:"threshold",ref:!0,assert:_=>C.default.isBN(_),message:"must be a big number",normalize:_=>new C.default(_)},{name:"equal",assert:_=>typeof _=="boolean",message:"must be a boolean"}],validate(_,b,m){const r=new C.default(_);return m.equal&&r.lt(m.threshold)?b.error("bn.min",m):!m.equal&&r.lte(m.threshold)?b.error("bn.greater",m):_}},lt:{args:[{name:"threshold",ref:!0,assert:_=>C.default.isBN(_),message:"must be a big number",normalize:_=>new C.default(_)},{name:"equal",assert:_=>typeof _=="boolean",message:"must be a boolean"}],validate(_,b,m){const r=new C.default(_);return m.equal&&r.gt(m.threshold)?b.error("bn.max",m):!m.equal&&r.gte(m.threshold)?b.error("bn.less",m):_}},min:{alias:"gte",method(_){return this.$_addRule({name:"gt",args:{threshold:_,equal:!0}})}},max:{alias:"lte",method(_){return this.$_addRule({name:"lt",args:{threshold:_,equal:!0}})}},greater:{alias:"gt",method(_){return this.$_addRule({name:"gt",args:{threshold:_,equal:!1}})}},less:{alias:"lt",method(_){return this.$_addRule({name:"lt",args:{threshold:_,equal:!1}})}},positive:{method(){return this.$_addRule({name:"gt",args:{threshold:0,equal:!1}})}},negative:{method(){return this.$_addRule({name:"lt",args:{threshold:0,equal:!1}})}}}}}return Oe}var Pe={},Lt;function yn(){if(Lt)return Pe;Lt=1;var x=Pe&&Pe.__importDefault||function(m){return m&&m.__esModule?m:{default:m}};Object.defineProperty(Pe,"__esModule",{value:!0}),Pe.DIDExtension=b;const C=x(Js),$=Ks(),R=Gs(),_={pk:Object.keys($.types.KeyType),hash:Object.keys($.types.HashType),role:Object.keys($.types.RoleType)};function b(m){return{type:"DID",base:m.string().trim(),messages:{"did.empty":'Expect {{#label}} to be non-empty string, got "{{#value}}"',"did.invalid":'Expect {{#label}} to be valid did, got "{{#value}}"',"did.wallet":'Expect wallet type of {{#label}} to be "{{#expected}}" wallet, got "{{#actual}}"',"did.pk":'Expect pk type of {{#label}} to be "{{#expected}}", got "{{#actual}}"',"did.hash":'Expect hash type of {{#label}} to be "{{#expected}}", got "{{#actual}}"',"did.role":'Expect role type of {{#label}} to be "{{#expected}}", got "{{#actual}}"',"did.prefix":'Expect prefix of {{#label}} to be "{{#expected}}"'},validate(r,p){return!r||typeof r!="string"?{errors:p.error("did.empty",{value:r})}:(0,R.isValid)(r)===!1?{errors:p.error("did.invalid",{value:r})}:{value:r}},rules:{type:{args:[{name:"key",ref:!0,assert:r=>Object.keys(_).includes(r),message:`must be one of ${Object.keys(_).join(", ")}`},{name:"expected",assert:r=>Object.keys(_).some(p=>_[p].includes(r)),message:"must be valid type"}],validate(r,p,f){const h=(0,R.toTypeInfoStr)(r);return f.key==="pk"&&h.pk!==f.expected?p.error("did.pk",{...f,actual:h.pk}):f.key==="hash"&&h.hash!==f.expected?p.error("did.hash",{...f,actual:h.hash}):f.key==="role"&&h.role!==f.expected?p.error("did.role",{...f,actual:h.role}):r}},pk:{method(r){return this.$_addRule({name:"type",args:{key:"pk",expected:r}})}},hash:{method(r){return this.$_addRule({name:"type",args:{key:"hash",expected:r}})}},role:{method(r){return this.$_addRule({name:"type",args:{key:"role",expected:r}})}},wallet:{method(r){return this.$_addRule({name:"wallet",args:{type:r}})},args:[{name:"type",ref:!0,assert:r=>["arcblock","ethereum","default","eth","passkey"].includes(r),message:"must be a string",normalize:r=>r.trim()}],validate(r,p,f={}){const h=(0,R.toTypeInfo)(r),t=(0,R.toTypeInfoStr)(r);return["ethereum","eth"].includes(f.type)&&(0,C.default)(h,R.DID_TYPE_ETHEREUM)===!1?p.error("did.wallet",{expected:f.type,actual:JSON.stringify(t)}):["arcblock","default"].includes(f.type)&&(0,C.default)(h,R.DID_TYPE_ARCBLOCK)===!1?p.error("did.wallet",{expected:f.type,actual:JSON.stringify(t)}):["passkey"].includes(f.type)&&(0,C.default)(h,R.DID_TYPE_PASSKEY)===!1?p.error("did.wallet",{expected:f.type,actual:JSON.stringify(t)}):r}},prefix:{method(r=""){return this.$_addRule({name:"prefix",args:{str:r}})},args:[{name:"str",ref:!0,assert:r=>["",R.DID_PREFIX].includes(r),message:"must be a string",normalize:r=>r.trim()}],validate(r,p,f={}){return f.str&&r.startsWith(f.str)===!1?p.error("did.prefix",{expected:f.str}):!f.str&&(0,R.toAddress)(r)!==r?p.error("did.prefix",{expected:f.str}):r}}}}}return Pe}var qt;function vn(){return qt||(qt=1,function(x){var C=Me&&Me.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(x,"__esModule",{value:!0}),x.patterns=x.schemas=x.Joi=void 0;const $=C(pn()),R=gn(),_=yn();x.Joi=$.default.extend(_.DIDExtension).extend(R.BNExtension);const b=/^(0x)?([A-Fa-f0-9]{64})$/,m=x.Joi.object({genesisTime:x.Joi.date().iso().required().raw(),genesisTx:x.Joi.string().regex(b).required().allow(""),renaissanceTime:x.Joi.date().iso().required().raw(),renaissanceTx:x.Joi.string().regex(b).required().allow("")}),r=x.Joi.object({address:x.Joi.DID().prefix().role("ROLE_TOKEN").required(),value:x.Joi.BN().positive().required()}),p=x.Joi.object({name:x.Joi.string().min(1).max(256).required(),value:x.Joi.string().min(1).max(1024).required(),description:x.Joi.string().min(1).max(256).optional().allow(""),required:x.Joi.boolean().optional().default(!1)}),f=x.Joi.alternatives().try(x.Joi.DID().prefix().role("ROLE_ACCOUNT"),x.Joi.DID().prefix().role("ROLE_APPLICATION"),x.Joi.DID().prefix().role("ROLE_BLOCKLET"),x.Joi.DID().prefix().wallet("ethereum"),x.Joi.DID().prefix().wallet("passkey")),h=x.Joi.array().items(x.Joi.object({owner:f.required(),tokensList:x.Joi.array().items(r).default([]),assetsList:x.Joi.array().items(x.Joi.DID().prefix().role("ROLE_ASSET")).default([])})),t=x.Joi.array().items({signer:x.Joi.DID().prefix().required(),pk:x.Joi.any().required(),signature:x.Joi.any().required(),delegator:x.Joi.DID().prefix().valid("").optional(),data:x.Joi.any().optional()}),l=x.Joi.object({type:x.Joi.string().min(1).max(32).required(),contractAddress:x.Joi.DID().prefix().wallet("ethereum").required(),chainType:x.Joi.string().min(1).max(32).required(),chainName:x.Joi.string().min(1).max(32).required(),chainId:x.Joi.number().positive().required()}),o=x.Joi.object({type:x.Joi.string().valid("svg","url","uri").required(),content:x.Joi.string().when("type",{is:"uri",then:x.Joi.string().max(20480).dataUri().required()}).when("type",{is:"url",then:x.Joi.string().max(2048).uri({scheme:["http","https"]}).required()})}),n=x.Joi.object({id:x.Joi.string().max(2048).uri({scheme:["http","https"]}).required(),scope:x.Joi.string().valid("public","private").default("public")}),s=x.Joi.object({id:x.Joi.DID().prefix().required(),pk:x.Joi.string().required(),name:x.Joi.string().min(1).max(256).required()}),c={address:x.Joi.DID().prefix().role("ROLE_ASSET").required(),moniker:x.Joi.string().min(2).max(255).required(),data:x.Joi.any().required(),readonly:x.Joi.boolean().default(!1),transferrable:x.Joi.boolean().default(!1),ttl:x.Joi.number().min(0).default(0),parent:x.Joi.DID().prefix().optional().allow(""),issuer:x.Joi.DID().prefix().optional().allow(""),endpoint:n.optional().allow(null).default(null),display:o.optional().allow(null).default(null),tags:x.Joi.array().items(x.Joi.string().min(1).max(64)).max(4).optional()},a={address:x.Joi.DID().prefix().role("ROLE_FACTORY").required(),name:x.Joi.string().min(2).max(255).required(),description:x.Joi.string().min(2).max(255).required(),settlement:x.Joi.string().valid("instant","periodic").default("instant"),limit:x.Joi.number().integer().min(0).default(0),trustedIssuers:x.Joi.array().items(x.Joi.DID().prefix()).max(8).optional(),data:x.Joi.any().optional().allow(null).default(null),display:o.optional().allow(null).default(null),input:x.Joi.object({value:x.Joi.BN().positive().min("0").default("0"),tokens:x.Joi.array().items(r).max(8).optional(),assets:x.Joi.array().items(x.Joi.alternatives().try(x.Joi.DID().prefix().role("ROLE_ASSET"),x.Joi.DID().prefix().role("ROLE_FACTORY"))).max(8).optional(),variables:x.Joi.array().items(x.Joi.object({name:x.Joi.string().min(1).max(255).required(),description:x.Joi.string().max(255).optional().allow(""),required:x.Joi.boolean().required()})).optional()}),output:x.Joi.object({moniker:x.Joi.string().min(2).max(255).required(),data:x.Joi.any().required(),readonly:x.Joi.boolean().default(!1),transferrable:x.Joi.boolean().default(!1),ttl:x.Joi.number().min(0).default(0),parent:x.Joi.string().max(255).required(),issuer:x.Joi.string().max(255).required(),endpoint:n.optional(),display:o.optional(),tags:x.Joi.array().items(x.Joi.string().min(1).max(64)).max(4).optional()}),hooks:x.Joi.array().items(x.Joi.object({name:x.Joi.string().valid("mint","postMint","preMint").required(),type:x.Joi.string().valid("url","contract").required(),hook:x.Joi.string().min(1).max(4096).required(),compiled:x.Joi.array().items(x.Joi.object()).optional()})).optional()};x.schemas={context:m,tokenInput:r,multiInput:h,multiSig:t,foreignToken:l,variableInput:p,nftDisplay:o,nftEndpoint:n,nftIssuer:s,tokenHolder:f,assetProps:c,assetSchema:x.Joi.object(c).options({stripUnknown:!0,noDefaults:!1}),factoryProps:a,factorySchema:x.Joi.object(a).options({stripUnknown:!0,noDefaults:!1})},x.patterns={txHash:b}}(Me)),Me}var xn=vn();function us({onCancel:x,onSuccess:C,blocklet:$}){const{vaults:R=[],appPid:_}=$,{t:b,locale:m}=ae(),{connectApi:r}=Bt(),{api:p}=re(),{teamDid:f}=Ve(),[h,t]=pt({loading:!1,fetching:!1,error:"",address:"",fetched:[],errored:[]});L.useEffect(()=>{if(!je.isValid(h.address))return;const c=je.toAddress(h.address),a=h.fetched.find(u=>u.address===c),i=h.errored.find(u=>u.address===c);!h.fetching&&!a&&!i&&(t({fetching:!0}),Ar(W.MAIN_CHAIN_ENDPOINT).getAccountState({address:c}).then(g=>{g.state?t({fetching:!1,fetched:[...h.fetched.filter(y=>y.address!==c),g.state]}):t({fetching:!1,errored:[...h.errored.filter(y=>y.address!==c),{address:c}]})}).catch(g=>{console.error(g),t({fetching:!1,error:it(g)})}))},[h.address,h.fetching]),L.useEffect(()=>{if(h.address){const c=je.toAddress(h.address);if(!je.isValid(c)){t({error:b("blocklet.config.vault.error.invalid")});return}if(xn.schemas.tokenHolder.validate(c).error){t({error:b("blocklet.config.vault.error.holder")});return}if(R.find(i=>i.did===c)){t({error:b("blocklet.config.vault.error.duplicate")});return}if(Ys([$.appDid,$.appPid,...$.migratedFrom.map(i=>i.appDid)].filter(Boolean)).includes(c)){t({error:b("blocklet.config.vault.error.appDid")});return}}t({error:""})},[h.address]);const l=async()=>{t({loading:!0});try{const c=await p.configVault({input:{teamDid:f,vaultDid:je.toAddress(h.address)}});r.open({locale:m,action:"approve-vault",forceConnected:!1,saveConnect:!1,autoConnect:!1,className:"connect",checkTimeout:10*60*1e3,passkeyBehavior:"none",extraParams:{sessionId:c.sessionId},messages:{title:b("blocklet.config.vault.approve.title"),scan:b(`blocklet.config.vault.approve.${R.length>0?"byLast":"byOwner"}`),confirm:b("blocklet.config.vault.approve.confirm"),success:b("blocklet.config.vault.approve.success")},onSuccess:()=>{r.open({locale:m,action:"config-vault",forceConnected:!1,saveConnect:!1,autoConnect:!1,className:"connect",checkTimeout:10*60*1e3,passkeyBehavior:"none",extraParams:{sessionId:c.sessionId},messages:{title:b("blocklet.config.vault.commit.title"),scan:b("blocklet.config.vault.commit.scan"),confirm:b("blocklet.config.vault.commit.confirm"),success:b("blocklet.config.vault.commit.success")},onSuccess:()=>{t({loading:!1}),C()},onClose:()=>{t({loading:!1}),r.close()}})},onClose:()=>{t({loading:!1}),r.close()}})}catch(c){t({loading:!1,error:it(c)})}},o=je.toAddress(h.address),n=[];je.isValid(o)&&n.push({key:b("blocklet.config.vault.role"),value:e.jsx(ht,{color:"primary",variant:"outlined",size:"small",label:je.toTypeInfoStr(o).role||"-"})});const s=h.fetched.find(c=>c.address===o);return s&&n.push({key:b("blocklet.config.vault.firstSeen"),value:kt(s.context?.genesisTime,"-")},{key:b("blocklet.config.vault.lastSeen"),value:kt(s.context?.renaissanceTime,"-")},{key:b("blocklet.config.vault.migratedFrom"),value:s.migratedFrom.length?s.migratedFrom.map(c=>e.jsx(at,{did:c,showQrcode:!0,compact:!0,size:14,locale:m},c)):"-"},{key:b("blocklet.config.vault.migratedTo"),value:s.migratedTo.length?s.migratedTo.map(c=>e.jsx(at,{did:c,showQrcode:!0,compact:!0,size:14,locale:m},c)):"-"}),e.jsx(ke,{open:!0,fullWidth:!0,showCloseButton:!1,onClose:x,title:e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx(ts,{}),b("blocklet.config.vault.title")]}),actions:e.jsxs(e.Fragment,{children:[e.jsx(te,{onClick:x,children:b("common.cancel")}),e.jsx(te,{onClick:l,variant:"contained",disabled:!!h.error||h.loading,children:b("common.confirm")})]}),children:e.jsxs(ie,{direction:"column",spacing:3,children:[e.jsxs(J,{variant:"body1",gutterBottom:!0,sx:{color:"text.secondary"},children:[b("blocklet.config.vault.desc")," ",b("blocklet.config.vault.tip")]}),R.length>0&&e.jsxs(A,{children:[e.jsxs(J,{variant:"body1",gutterBottom:!0,sx:{color:"text.secondary"},children:[b("blocklet.config.vault.current"),":"]}),e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:.5},children:[e.jsx(Xs,{did:R[R.length-1].did,showQrcode:!0,style:{width:"auto"}}),e.jsx(Or,{vaults:R,appPid:_})]})]}),e.jsx(U,{fullWidth:!0,"data-cy":"input-factory-address",label:b("blocklet.config.vault.address"),error:!!h.error,helperText:h.error,value:h.address,onChange:c=>{t({address:c.target.value,error:""})},slotProps:{input:{endAdornment:h.fetching?e.jsx(Zt,{position:"end",children:e.jsx(Ie,{size:16})}):null}}}),e.jsx(A,{sx:{"& .info-row__name":{fontSize:"14px"},"& .info-row__value":{fontSize:"14px"}},children:n.map(c=>e.jsx(Yt,{valueComponent:"div",nameWidth:120,name:c.key,children:c.value},c.key))})]})})}us.propTypes={onCancel:T.func.isRequired,onSuccess:T.func.isRequired,blocklet:T.object.isRequired};function yt({blocklet:x,onUpdate:C=()=>{},hasPermission:$=!1}){const{info:R,api:_,inService:b}=re(),{t:m,locale:r}=L.useContext(ue),[p,f]=pt({loading:!1,showTransferOwner:!1,showConfigVault:!1}),[h,t]=L.useState(()=>x?.settings?.gateway?.wafPolicy?.enabled??!0),[l,o]=L.useState(()=>!!x?.settings?.enableSessionHardening),[n,s]=L.useState(()=>!!x?.settings?.invite?.enabled),c=p.loading||!$,{did:a}=x.meta,i=b?window.env?.gateway?.wafPolicy?.enabled:R?.routing.wafPolicy?.enabled;if(mt(x.status))return null;const u=x.environments.find(I=>I.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_DELETABLE),g=!u||u.value==="yes",k=x.environments.find(I=>I.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_TENANT_MODE)?.value||se.BLOCKLET_TENANT_MODES.SINGLE,w=(I,B)=>async N=>{if(!p.loading){f({loading:!0});try{const{checked:q}=N.target,{blocklet:z}=await _.configBlocklet({input:{did:x.meta.did,configs:[{key:se.BLOCKLET_CONFIGURABLE_KEY[I],value:B(q)}]}});C(z)}catch(q){Z.error(q.message)}finally{f({loading:!1})}}},d=w("BLOCKLET_DELETABLE",I=>I?"no":"yes"),v=w("BLOCKLET_APP_TENANT_MODE",I=>I?se.BLOCKLET_TENANT_MODES.MULTIPLE:se.BLOCKLET_TENANT_MODES.SINGLE),j=(I,B)=>async N=>{if(!p.loading){f({loading:!0});try{const q=N.target.checked;await _.updateBlockletSettings({input:I(q)}),B&&B(q)}catch(q){Z.error(q.message)}finally{f({loading:!1})}}},S=j(I=>({did:x.meta.did,invite:{enabled:I}}),s),O=j(I=>({did:x.meta.did,gateway:{wafPolicy:{enabled:I}}}),t),P=j(I=>({did:x.meta.did,enableSessionHardening:I}),I=>{o(I),Qs()}),D=async()=>{if(!p.loading){f({loading:!0});try{const{blocklet:I}=await _.getBlocklet({input:{did:x.meta.did}});C(I)}catch(I){Z.error(I.message)}finally{f({loading:!1})}}};return e.jsxs(ie,{p:3,sx:{border:"1px solid red",borderRadius:2,p:3},className:"advanced-config",children:[!b&&e.jsxs(e.Fragment,{children:[e.jsx(M,{title:m("blocklet.config.deletable.name"),desc:m(g?"blocklet.config.deletable.disable":"blocklet.config.deletable.enable"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(pe,{disabled:c,checked:!g,defaultChecked:!0,onChange:d})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}})]}),e.jsx(cs,{inService:b,disabled:c,loading:p.loading,onChange:D}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),b&&e.jsx(jr,{role:"owner",children:I=>(I||mn)&&e.jsxs(e.Fragment,{children:[e.jsx(M,{title:m("blocklet.config.vault.title"),desc:m("blocklet.config.vault.desc"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsxs(te,{variant:"contained",color:"primary",size:"small","data-cy":"config-vault",onClick:()=>f({showConfigVault:!0}),children:[e.jsx(ts,{style:{fontSize:"1.3em",marginRight:4}}),m("blocklet.config.vault.title")]})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),p.showConfigVault&&e.jsx(us,{blocklet:x,onCancel:()=>f({showConfigVault:!1}),onSuccess:()=>f({showConfigVault:!1})}),e.jsx(M,{title:m("team.transferApp.name"),desc:m("team.transferApp.description"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsxs(te,{variant:"contained",edge:"end",color:"primary",size:"small","data-cy":"transfer-app",onClick:()=>f({showTransferOwner:!0}),children:[e.jsx(Xr,{style:{fontSize:"1.3em",marginRight:4}}),m("team.transferApp.name")]})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),p.showTransferOwner&&e.jsx(ds,{onCancel:()=>f({showTransferOwner:!1}),onSuccess:()=>f({showTransferOwner:!1})})]})}),e.jsx(M,{title:m("blocklet.config.clearCache.name"),desc:m("blocklet.config.clearCache.purpose"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(Sr,{teamDid:a})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:m("blocklet.config.rotateSessionKey.name"),desc:m("blocklet.config.rotateSessionKey.purpose"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(Cr,{style:{whiteSpace:"nowrap"},teamDid:a})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:m("blocklet.config.tenantMode.name"),desc:m(`blocklet.config.tenantMode.${k}`),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(pe,{disabled:c,checked:k===se.BLOCKLET_TENANT_MODES.MULTIPLE,onChange:v})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:m("team.invite.setting"),desc:m(`team.invite.${n?"enabled":"disabled"}`),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(pe,{disabled:c,checked:n,onChange:S})})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:e.jsxs(ie,{direction:"row",sx:{alignItems:"center",gap:1},children:[m("setting.form.enableSessionHardening.switchLabel"),e.jsx(X,{title:m("setting.form.enableSessionHardening.switchTips"),children:e.jsx(St,{sx:{ml:.5,fontSize:"20px"},color:"primary"})})]}),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(pe,{disabled:c,checked:l,onChange:P})})}),i&&e.jsxs(e.Fragment,{children:[e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(M,{title:e.jsxs(ie,{direction:"row",sx:{alignItems:"center",gap:1},children:[m("router.gateway.wafPolicy.title"),e.jsx(X,{title:e.jsx(A,{sx:{fontSize:"14px",lineHeight:1.5},children:e.jsx(A,{sx:{color:"common.white",ml:.5},component:"a",href:`https://www.arcblock.io/docs/blocklet-developer/${r}/enable-web-application-firewall`,target:"_blank",rel:"noopener noreferrer",children:m("dashboard.document")})}),children:e.jsx(St,{fontSize:"small",color:"action",sx:{fontSize:16,cursor:"pointer"}})})]}),desc:m("router.gateway.wafPolicy.switchLabel"),children:e.jsx(A,{sx:{alignSelf:{xs:"flex-start",md:"flex-end"}},children:e.jsx(pe,{disabled:c,checked:h,onChange:O})})})]})]})}const bn=Ee(yt,"mutate_blocklets"),jn=Ee(yt,"",ft);function _n(x){const{inService:C}=re();return C?e.jsx(jn,{...x}):e.jsx(bn,{...x})}yt.propTypes={blocklet:T.object.isRequired,onUpdate:T.func,hasPermission:T.bool};function vt({blocklet:x,onUpdate:C=()=>{},hasPermission:$=!1,...R}){const{t:_}=L.useContext(ue);return mt(x.status)?null:e.jsxs(Cn,{...R,children:[e.jsx(un,{blocklet:x,onUpdate:C,hasPermission:$}),e.jsx(A,{sx:{mt:6},children:e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:_("blocklet.config.dangerZone")})}),e.jsx(A,{className:"config-form",component:ee,sx:{my:3}}),e.jsx(A,{sx:{maxWidth:1536},children:e.jsx(_n,{blocklet:x,onUpdate:C,hasPermission:$})})]})}const wn=Ee(vt,"mutate_blocklets"),kn=Ee(vt,"",ft);function Sn(x){const{inService:C}=re();return C?e.jsx(kn,{...x}):e.jsx(wn,{...x})}vt.propTypes={blocklet:T.object.isRequired,onUpdate:T.func,hasPermission:T.bool};const Cn=ve(A)`
|
|
51
|
-
.config-form {
|
|
52
|
-
flex-grow: 1;
|
|
53
|
-
overflow-y: auto;
|
|
54
|
-
${x=>x.theme.breakpoints.down("md")} {
|
|
55
|
-
width: 100%;
|
|
56
|
-
flex-shrink: 0;
|
|
57
|
-
padding: 0 24px;
|
|
58
|
-
transform: translate(0, 0);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
.config-item {
|
|
63
|
-
display: flex;
|
|
64
|
-
align-items: center;
|
|
65
|
-
justify-content: space-between;
|
|
66
|
-
margin: 16px 0;
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
.config-label {
|
|
70
|
-
font-weight: bold;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
.config-desc {
|
|
74
|
-
font-weight: normal;
|
|
75
|
-
font-size: 12px;
|
|
76
|
-
color: #666;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
.form-item {
|
|
80
|
-
margin-top: 0;
|
|
81
|
-
}
|
|
82
|
-
`,xt={width:24,height:24,body:'<path fill="currentColor" d="M5 4v16V4v5v-5Zm3 10h2.675q.275-.575.638-1.075t.812-.925H8q-.425 0-.713.288T7 13q0 .425.288.713T8 14Zm0 4h2.075Q10 17.5 10 17t.075-1H8q-.425 0-.713.288T7 17q0 .425.288.713T8 18Zm-3 4q-.825 0-1.413-.588T3 20V4q0-.825.588-1.413T5 2h7.175q.4 0 .763.15t.637.425l4.85 4.85q.275.275.425.638t.15.762V10.3q-.475-.15-.975-.225T17 10V9h-4q-.425 0-.713-.288T12 8V4H5v16h5.675q.275.575.638 1.075t.812.925H5Zm12-10q2.075 0 3.538 1.463T22 17q0 2.075-1.463 3.538T17 22q-2.075 0-3.538-1.463T12 17q0-2.075 1.463-3.538T17 12Zm0 8q.275 0 .463-.188t.187-.462q0-.275-.187-.463T17 18.7q-.275 0-.463.188t-.187.462q0 .275.188.463T17 20Zm0-6q-.475 0-.875.238t-.65.637q-.1.15-.025.313t.25.237q.15.075.3 0t.275-.2q.125-.175.313-.275t.412-.1q.325 0 .563.213t.237.537q0 .275-.15.463t-.35.387q-.15.15-.313.3t-.287.35q-.075.15-.113.313t-.037.337q0 .225.125.413t.325.187q.2 0 .325-.15t.125-.35q0-.275.15-.488t.35-.412q.3-.275.525-.613t.225-.737q0-.675-.5-1.138T17 14Z"/>'},Xe={enabled:!1,domain:"",clientId:"",clientSecret:""};function Rn(){const{api:x}=re(),{blocklet:C}=oe(),{t:$,locale:R}=ae(),_=C?.meta?.did,b=Object.assign({...Xe},C?.settings?.oauth?.auth0||{}),{handleSubmit:m,control:r,formState:p,watch:f,reset:h}=xe({defaultValues:Re(b,Object.keys(Xe))}),t=f("enabled"),l=E(async i=>{try{const{blocklet:u}=await x.configOAuth({input:{did:_,oauth:JSON.stringify({auth0:i})}}),g=Object.assign({...Xe},u?.settings?.oauth?.auth0||{});h(g),Z.success($("oauth.saveSuccess"))}catch(u){Z.error(u.message||$("oauth.saveFailed"))}}),o=E(i=>i?.trim()?!0:$("oauth.auth0.domainDescription")),n=E(i=>i?.trim()?!0:$("oauth.auth0.clientIdDescription")),s=E(i=>i?.trim()?!0:$("oauth.auth0.clientSecretDescription")),c=E(()=>!0),a=ge(()=>R==="zh"?"https://www.arcblock.io/blog/docs/did-connect/zh/oauth-config-auth0":"https://www.arcblock.io/blog/docs/did-connect/en/oauth-config-auth0",[R]);return e.jsx(A,{children:e.jsxs("form",{onSubmit:m(l),disabled:!0,children:[e.jsx(M,{title:e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx("span",{children:$("oauth.auth0.enable")}),e.jsx(X,{title:$("oauth.viewDocument"),children:e.jsx(A,{component:"a",sx:{display:"inline-block",color:"inherit",fontSize:0,lineHeight:1},href:a,target:"_blank",rel:"noreferrer",children:e.jsx(Q,{icon:xt,fontSize:20})})})]}),mb:2.5,children:e.jsx(H,{name:"enabled",control:r,render:({field:i})=>e.jsx(K,{control:e.jsx(He,{sx:{ml:1},checked:i.value,...i})})})}),e.jsx(M,{title:$("oauth.auth0.domain"),children:e.jsx(H,{name:"domain",control:r,rules:{validate:t?o:c},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.auth0.domain"),error:!!p.errors[i.name],helperText:p.errors[i.name]?.message||" ",disabled:!t})})})}),e.jsx(M,{title:$("oauth.auth0.clientId"),children:e.jsx(H,{name:"clientId",control:r,rules:{validate:t?n:c},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.auth0.clientId"),error:!!p.errors[i.name],helperText:p.errors[i.name]?.message||" ",disabled:!t})})})}),e.jsx(M,{title:$("oauth.auth0.clientSecret"),children:e.jsx(H,{name:"clientSecret",control:r,rules:{validate:t?s:c},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",type:"password",label:$("oauth.auth0.clientSecret"),error:!!p.errors[i.name],helperText:p.errors[i.name]?.message||" ",disabled:!t})})})}),e.jsx(Y,{type:"submit",variant:"contained",onSubmit:m(l),disabled:!p.isDirty,children:$("oauth.save")})]})})}const Qe={enabled:!1,clientId:"",clientSecret:""};function $n(){const{api:x}=re(),{blocklet:C}=oe(),{t:$,locale:R}=ae(),_=C?.meta?.did,b=Object.assign({...Qe},C?.settings?.oauth?.github||{}),{handleSubmit:m,control:r,formState:p,watch:f,reset:h}=xe({defaultValues:Re(b,Object.keys(Qe))}),t=f("enabled"),l=E(async a=>{try{const{blocklet:i}=await x.configOAuth({input:{did:_,oauth:JSON.stringify({github:a})}}),u=Object.assign({...Qe},i?.settings?.oauth?.github||{});h(u),Z.success($("oauth.saveSuccess"))}catch(i){Z.error(i.message||$("oauth.saveFailed"))}}),o=E(a=>a?.trim()?!0:$("oauth.github.clientIdDescription")),n=E(a=>a?.trim()?!0:$("oauth.github.clientSecretDescription")),s=E(()=>!0),c=ge(()=>R==="zh"?"https://www.arcblock.io/blog/docs/did-connect/zh/oauth-config-github":"https://www.arcblock.io/blog/docs/did-connect/en/oauth-config-github",[R]);return e.jsx(A,{children:e.jsxs("form",{onSubmit:m(l),disabled:!0,children:[e.jsx(M,{title:e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx("span",{children:$("oauth.github.enable")}),e.jsx(X,{title:$("oauth.viewDocument"),children:e.jsx(A,{component:"a",sx:{display:"inline-block",color:"inherit",fontSize:0,lineHeight:1},href:c,target:"_blank",rel:"noreferrer",children:e.jsx(Q,{icon:xt,fontSize:20})})})]}),mb:2.5,sx:{"& .section-content":{alignItems:"center"}},children:e.jsx(H,{name:"enabled",control:r,sx:{alignItems:"center"},render:({field:a})=>e.jsx(K,{control:e.jsx(He,{sx:{ml:1},size:"small",checked:a.value,...a})})})}),e.jsx(M,{title:$("oauth.github.clientId"),children:e.jsx(H,{name:"clientId",control:r,rules:{validate:t?o:s},render:({field:a})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...a,size:"small",label:$("oauth.github.clientId"),error:!!p.errors[a.name],helperText:p.errors[a.name]?.message||" ",disabled:!t})})})}),e.jsx(M,{title:$("oauth.github.clientSecret"),children:e.jsx(H,{name:"clientSecret",control:r,rules:{validate:t?n:s},render:({field:a})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...a,size:"small",type:"password",label:$("oauth.github.clientSecret"),error:!!p.errors[a.name],helperText:p.errors[a.name]?.message||" ",disabled:!t})})})}),e.jsx(Y,{type:"submit",variant:"contained",onSubmit:m(l),disabled:!p.isDirty,children:$("oauth.save")})]})})}const et={enabled:!1,clientId:"",clientSecret:""};function An(){const{api:x}=re(),{blocklet:C}=oe(),{t:$,locale:R}=ae(),_=C?.meta?.did,b=Object.assign({...et},C?.settings?.oauth?.google||{}),{handleSubmit:m,control:r,formState:p,watch:f,reset:h}=xe({defaultValues:Re(b,Object.keys(et))}),t=f("enabled"),l=E(async a=>{try{const{blocklet:i}=await x.configOAuth({input:{did:_,oauth:JSON.stringify({google:a})}}),u=Object.assign({...et},i?.settings?.oauth?.google||{});h(u),Z.success($("oauth.saveSuccess"))}catch(i){Z.error(i.message||$("oauth.saveFailed"))}}),o=E(a=>a?.trim()?!0:$("oauth.google.clientIdDescription")),n=E(a=>a?.trim()?!0:$("oauth.google.clientSecretDescription")),s=E(()=>!0),c=ge(()=>R==="zh"?"https://www.arcblock.io/blog/docs/did-connect/zh/oauth-config-google":"https://www.arcblock.io/blog/docs/did-connect/en/oauth-config-google",[R]);return e.jsx(A,{children:e.jsxs("form",{onSubmit:m(l),disabled:!0,children:[e.jsx(M,{title:e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx("span",{children:$("oauth.google.enable")}),e.jsx(X,{title:$("oauth.viewDocument"),children:e.jsx(A,{component:"a",sx:{display:"inline-block",color:"inherit",fontSize:0,lineHeight:1},href:c,target:"_blank",rel:"noreferrer",children:e.jsx(Q,{icon:xt,fontSize:20})})})]}),mb:2.5,children:e.jsx(H,{name:"enabled",control:r,render:({field:a})=>e.jsx(K,{control:e.jsx(He,{sx:{ml:1},checked:a.value,...a})})})}),e.jsx(M,{title:$("oauth.google.clientId"),children:e.jsx(H,{name:"clientId",control:r,rules:{validate:t?o:s},render:({field:a})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...a,size:"small",label:$("oauth.google.clientId"),error:!!p.errors[a.name],helperText:p.errors[a.name]?.message||" ",disabled:!t})})})}),e.jsx(M,{title:$("oauth.google.clientSecret"),children:e.jsx(H,{name:"clientSecret",control:r,rules:{validate:t?n:s},render:({field:a})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...a,size:"small",type:"password",label:$("oauth.google.clientSecret"),error:!!p.errors[a.name],helperText:p.errors[a.name]?.message||" ",disabled:!t})})})}),e.jsx(Y,{type:"submit",variant:"contained",onSubmit:m(l),disabled:!p.isDirty,children:$("oauth.save")})]})})}const tt={enabled:!1,teamId:"",serviceId:"",keyId:"",authKey:"",bundleId:""};function On(){const{api:x}=re(),{blocklet:C}=oe(),{t:$}=ae(),R=C?.meta?.did,_=Object.assign({...tt},C?.settings?.oauth?.apple||{}),{handleSubmit:b,control:m,formState:r,watch:p,reset:f}=xe({defaultValues:Re(_,Object.keys(tt))}),h=p("enabled"),t=E(async i=>{try{const{blocklet:u}=await x.configOAuth({input:{did:R,oauth:JSON.stringify({apple:i})}}),g=Object.assign({...tt},u?.settings?.oauth?.apple||{});f(g),Z.success($("oauth.saveSuccess"))}catch(u){Z.error(u.message||$("oauth.saveFailed"))}}),l=E(i=>i?.trim()?!0:$("oauth.apple.teamIdDescription")),o=E(i=>i?.trim()?!0:$("oauth.apple.serviceIdDescription")),n=E(i=>i?.trim()?!0:$("oauth.apple.keyIdDescription")),s=E(i=>i?.trim()?!0:$("oauth.apple.authKeyDescription")),c=E(i=>i?.trim()?!0:$("oauth.apple.bundleIdDescription")),a=E(()=>!0);return e.jsx(A,{children:e.jsxs("form",{onSubmit:b(t),disabled:!0,children:[e.jsx(M,{title:$("oauth.apple.enable"),mb:2.5,children:e.jsx(H,{name:"enabled",control:m,render:({field:i})=>e.jsx(K,{control:e.jsx(He,{sx:{ml:1},checked:i.value,...i})})})}),e.jsx(M,{title:$("oauth.apple.teamId"),children:e.jsx(H,{name:"teamId",control:m,rules:{validate:h?l:a},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.apple.teamId"),error:!!r.errors[i.name],helperText:r.errors[i.name]?.message||" ",disabled:!h})})})}),e.jsx(M,{title:$("oauth.apple.bundleId"),children:e.jsx(H,{name:"bundleId",control:m,rules:{validate:h?c:a},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.apple.bundleId"),error:!!r.errors[i.name],helperText:r.errors[i.name]?.message||" ",disabled:!h})})})}),e.jsx(M,{title:$("oauth.apple.serviceId"),children:e.jsx(H,{name:"serviceId",control:m,rules:{validate:h?o:a},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.apple.serviceId"),error:!!r.errors[i.name],helperText:r.errors[i.name]?.message||" ",disabled:!h})})})}),e.jsx(M,{title:$("oauth.apple.keyId"),children:e.jsx(H,{name:"keyId",control:m,rules:{validate:h?n:a},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",label:$("oauth.apple.keyId"),error:!!r.errors[i.name],helperText:r.errors[i.name]?.message||" ",disabled:!h})})})}),e.jsx(M,{title:$("oauth.apple.authKey"),children:e.jsx(H,{name:"authKey",control:m,rules:{validate:h?s:a},render:({field:i})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...i,size:"small",type:"password",label:$("oauth.apple.authKey"),multiline:!0,rows:4,error:!!r.errors[i.name],helperText:r.errors[i.name]?.message||" ",disabled:!h})})})}),e.jsx(Y,{type:"submit",variant:"contained",onSubmit:b(t),disabled:!r.isDirty,children:$("oauth.save")})]})})}const st={enabled:!1,clientId:"",clientSecret:""};function Pn(){const{api:x}=re(),{blocklet:C}=oe(),{t:$}=ae(),R=C?.meta?.did,_=Object.assign({...st},C?.settings?.oauth?.twitter||{}),{handleSubmit:b,control:m,formState:r,watch:p,reset:f}=xe({defaultValues:Re(_,Object.keys(st))}),h=p("enabled"),t=E(async s=>{try{const{blocklet:c}=await x.configOAuth({input:{did:R,oauth:JSON.stringify({twitter:s})}}),a=Object.assign({...st},c?.settings?.oauth?.twitter||{});f(a),Z.success($("oauth.saveSuccess"))}catch(c){Z.error(c.message||$("oauth.saveFailed"))}}),l=E(s=>s?.trim()?!0:$("oauth.twitter.clientIdDescription")),o=E(s=>s?.trim()?!0:$("oauth.twitter.clientSecretDescription")),n=E(()=>!0);return e.jsx(A,{children:e.jsxs("form",{onSubmit:b(t),disabled:!0,children:[e.jsx(M,{title:e.jsx(A,{sx:{display:"flex",alignItems:"center",gap:1},children:e.jsx("span",{children:$("oauth.twitter.enable")})}),mb:2.5,sx:{"& .section-content":{alignItems:"center"}},children:e.jsx(H,{name:"enabled",control:m,sx:{alignItems:"center"},render:({field:s})=>e.jsx(K,{control:e.jsx(He,{sx:{ml:1},size:"small",checked:s.value,...s})})})}),e.jsx(M,{title:$("oauth.twitter.clientId"),children:e.jsx(H,{name:"clientId",control:m,rules:{validate:h?l:n},render:({field:s})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...s,size:"small",label:$("oauth.twitter.clientId"),error:!!r.errors[s.name],helperText:r.errors[s.name]?.message||" ",disabled:!h})})})}),e.jsx(M,{title:$("oauth.twitter.clientSecret"),children:e.jsx(H,{name:"clientSecret",control:m,rules:{validate:h?o:n},render:({field:s})=>e.jsx(G,{fullWidth:!0,children:e.jsx(U,{...s,size:"small",type:"password",label:$("oauth.twitter.clientSecret"),error:!!r.errors[s.name],helperText:r.errors[s.name]?.message||" ",disabled:!h})})})}),e.jsx(Y,{type:"submit",variant:"contained",onSubmit:b(t),disabled:!r.isDirty,children:$("oauth.save")})]})})}const Tn={width:24,height:24,body:'<path fill="currentColor" d="M9 20q-.825 0-1.413-.588T7 18q0-.825.588-1.413T9 16q.825 0 1.413.588T11 18q0 .825-.588 1.413T9 20Zm6 0q-.825 0-1.413-.588T13 18q0-.825.588-1.413T15 16q.825 0 1.413.588T17 18q0 .825-.588 1.413T15 20Zm-6-6q-.825 0-1.413-.588T7 12q0-.825.588-1.413T9 10q.825 0 1.413.588T11 12q0 .825-.588 1.413T9 14Zm6 0q-.825 0-1.413-.588T13 12q0-.825.588-1.413T15 10q.825 0 1.413.588T17 12q0 .825-.588 1.413T15 14ZM9 8q-.825 0-1.413-.588T7 6q0-.825.588-1.413T9 4q.825 0 1.413.588T11 6q0 .825-.588 1.413T9 8Zm6 0q-.825 0-1.413-.588T13 6q0-.825.588-1.413T15 4q.825 0 1.413.588T17 6q0 .825-.588 1.413T15 8Z"/>'};function hs({id:x,title:C,children:$,index:R,onMove:_,defaultExpand:b=!1,onEnd:m,icon:r=null}){const[p,f]=L.useState(b),h=L.useRef(null),t=L.useRef(null),[{handlerId:l},o]=Er({accept:"dragItem",collect(i){return{handlerId:i.getHandlerId()}},hover(i,u){if(!h.current)return;const g=i.index,y=R;if(g===y)return;const k=h.current?.getBoundingClientRect(),w=t.current?.getBoundingClientRect(),d=(w.bottom-w.top)/2,j=u.getClientOffset().y-k.top;g<y&&j<d||g>y&&j>d||(_(g,y),i.index=y)}}),[{isDragging:n},s]=Dr({item:{index:R,type:"dragItem"},collect:i=>({isDragging:i.isDragging()}),end:m});s(t),o(h);const c=n?.5:1,a=E(i=>{i.preventDefault(),i.stopPropagation(),f(!p)});return e.jsxs(A,{ref:h,children:[e.jsxs(A,{sx:{cursor:"pointer","&:hover":{backgroundColor:"grey.100"}},ref:t,"data-handler-id":l,children:[e.jsxs(A,{sx:{py:2,px:1,opacity:c,display:"flex",alignItems:"center",gap:.5},draggable:!1,onClick:a,children:[e.jsx(A,{sx:{pointerEvents:"auto",cursor:"grab","&:active":{cursor:"grabbing"},fontSize:0,color:"text.hint","&:hover":{color:"text.secondary"}},children:e.jsx(Q,{fontSize:20,icon:Tn})}),e.jsx(A,{sx:{display:"flex",alignItems:"center",flexShrink:0,mr:.5,transform:"translateY(-1px)"},children:r}),e.jsx(J,{sx:{flex:1},children:C}),e.jsx(ne,{size:"small",sx:{pointerEvents:"auto",transform:p?"":"rotate(180deg)",transition:"transform 0.3s ease"},children:e.jsx(Q,{icon:Pr,style:{transform:"scale(1.5)"}})})]}),e.jsx(ee,{})]}),e.jsx(A,{sx:{pl:4,py:2.5,display:p?"block":"none"},children:$})]})}hs.propTypes={title:T.string.isRequired,id:T.string.isRequired,children:T.node.isRequired,index:T.number.isRequired,onMove:T.func.isRequired,onEnd:T.func.isRequired,defaultExpand:T.bool,icon:T.any};const In=[{name:"github",title:"GitHub",icon:e.jsx(qe,{provider:"github",sx:{width:20,height:20}}),component:e.jsx($n,{})},{name:"google",title:"Google",icon:e.jsx(qe,{provider:"google",sx:{width:20,height:20}}),component:e.jsx(An,{})},{name:"apple",title:"Apple",icon:e.jsx(qe,{provider:"apple",sx:{width:20,height:20}}),component:e.jsx(On,{})},{name:"twitter",title:"Twitter",icon:e.jsx(qe,{provider:"twitter",sx:{width:20,height:20}}),component:e.jsx(Pn,{})},{name:"auth0",title:"Auth0",icon:e.jsx(qe,{provider:"auth0",sx:{width:20,height:20}}),component:e.jsx(Rn,{})}],En=["github","google","apple","twitter","auth0"];function Dn(){const{api:x}=re(),{blocklet:C}=oe(),$=C?.meta?.did,R=C?.settings?.oauth||{},_=Object.keys(R).sort((t,l)=>R[t]?.order!==void 0&&R[l]?.order!==void 0?R[t].order-R[l].order:R[t]?.order!==void 0?-1:1);for(const t of En)_.includes(t)||_.push(t);const b=ye(_.reduce((t,l,o)=>Object.assign(t,{[l]:o}),{})),m=ge(()=>{const t=[...In];return t.sort((l,o)=>b[l.name]-b[o.name]),t.map(l=>({...l,enabled:R[l.name]?.enabled??!1}))},[b.auth0,b.github,b.google]),r={};typeof window<"u"&&(r.context=window);const p=E(async t=>{const l={};Object.keys(t).forEach(o=>{l[o]={order:t[o]}}),await x.configOAuth({input:{did:$,oauth:JSON.stringify(l)}})}),f=E((t,l)=>{const o=m[t],n=m[l];b[o.name]=l,b[n.name]=t}),h=E(async()=>{await p(b)});return e.jsx(A,{sx:{".section-left":{width:"180px"}},children:e.jsx(Lr,{backend:qr,...r,children:m.map((t,l)=>e.jsx(hs,{index:l,id:t.name,title:t.title,icon:t.icon,onMove:f,onEnd:h,defaultExpand:t.enabled,children:t.component},t.name))})})}const Se={ttl:W.SESSION_TTL,cacheTtl:W.SESSION_CACHE_TTL,email:{enabled:!1,requireVerified:!1,requireUnique:!1,trustOauthProviders:!1,trustedIssuers:[],enableDomainBlackList:!1,domainBlackList:[],enableDomainWhiteList:!1,domainWhiteList:[]},phone:{enabled:!1,requireVerified:!1,requireUnique:!1,regionBlackList:[],trustedIssuers:[]},enableBlacklist:!1};function he(x){return e.jsx(Mr,{...x,sx:{transform:"scale(0.75)"}})}function rt(x,C=!1){const $=C?x.ttl*86400:x.ttl/86400;return{...x,ttl:$}}function Ln(){const{api:x}=re(),{blocklet:C}=oe(),$=C?.meta?.did,R=er({},Se,C?.settings?.session||{});Je(R.ttl)&&(R.ttl=Se.ttl),Je(R.cacheTtl)&&(R.cacheTtl=Se.cacheTtl),R.phone||(R.phone=Se.phone),R.email||(R.email=Se.email),Je(R.enableBlacklist)&&(R.enableBlacklist=Se.enableBlacklist);const{handleSubmit:_,control:b,formState:m,reset:r,watch:p}=xe({defaultValues:Re(rt(R),["ttl","cacheTtl","email","phone","enableBlacklist"])}),{t:f}=ae(),h=p("email.enabled"),t=p("phone.enabled"),l=p("email.enableDomainBlackList"),o=p("email.enableDomainWhiteList"),{fields:n,append:s,remove:c}=Ot({control:b,name:"email.domainBlackList"}),{fields:a,append:i,remove:u}=Ot({control:b,name:"email.domainWhiteList"}),g=E(async y=>{try{const{blocklet:k}=await x.updateAppSessionConfig({input:{did:$,config:Ce(rt(y,!0),["phone"])}}),w=Object.assign({},Se,Re(k?.settings?.session||{},["ttl","cacheTtl","email","phone","enableBlacklist"]));r(rt(w)),Z.success(f("common.configSuccess"))}catch(k){Z.error(k.message)}});return e.jsx(qn,{onSubmit:_(g),children:e.jsxs(ie,{direction:"column",sx:{gap:6},children:[e.jsxs(A,{children:[e.jsxs(A,{children:[e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:f("blocklet.config.session.profile")}),e.jsx(A,{component:ee,sx:{my:3}})]}),e.jsxs(ie,{sx:{gap:2},children:[e.jsx(M,{title:f("blocklet.config.session.fullNameEnabled"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(he,{disabled:!0,checked:!0})})}),e.jsx(M,{title:f("blocklet.config.session.avatarEnabled"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(he,{disabled:!0,checked:!0})})}),e.jsx(M,{title:f("blocklet.config.session.emailEnabled"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.enabled",control:b,render:({field:y})=>e.jsx(he,{...y,checked:y.value})})})}),h&&e.jsxs(ie,{direction:"column",sx:{ml:2,gap:.5},children:[e.jsx(M,{title:f("blocklet.config.session.emailRequireVerified"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.requireVerified",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),e.jsx(M,{title:f("blocklet.config.session.emailRequireUnique"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.requireUnique",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),e.jsx(M,{title:f("blocklet.config.session.emailTrustOauthProviders"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.trustOauthProviders",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),e.jsx(M,{title:f("blocklet.config.session.enableDomainBlackList"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.enableDomainBlackList",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),l&&e.jsxs(A,{children:[n.map((y,k)=>e.jsxs(ie,{direction:"row",sx:{alignItems:"center",my:1,maxWidth:"720px"},children:[e.jsx(H,{name:`email.domainBlackList.${k}`,control:b,render:w=>e.jsx(U,{...w.field,size:"small",fullWidth:!0})}),e.jsx(ne,{onClick:()=>c(k),children:e.jsx(Pt,{})})]},y.id)),e.jsx(Y,{startIcon:e.jsx(Tt,{}),onClick:()=>s(""),children:f("blocklet.config.session.addDomain")})]}),e.jsx(M,{title:f("blocklet.config.session.enableDomainWhiteList"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"email.enableDomainWhiteList",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),o&&e.jsxs(A,{children:[a.map((y,k)=>e.jsxs(ie,{direction:"row",sx:{alignItems:"center",my:1,maxWidth:"720px"},children:[e.jsx(H,{name:`email.domainWhiteList.${k}`,control:b,render:w=>e.jsx(U,{...w.field,size:"small",fullWidth:!0})}),e.jsx(ne,{onClick:()=>u(k),children:e.jsx(Pt,{})})]},y.id)),e.jsx(Y,{startIcon:e.jsx(Tt,{}),onClick:()=>i(""),children:f("blocklet.config.session.addDomain")})]})]}),e.jsxs(A,{sx:{display:"none"},children:[e.jsx(M,{title:f("blocklet.config.session.phoneEnabled"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"phone.enabled",control:b,disabled:!0,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),t&&e.jsxs(ie,{direction:"column",sx:{ml:2,mt:1},children:[e.jsx(M,{title:f("blocklet.config.session.phoneRequireVerified"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"phone.requireVerified",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})}),e.jsx(M,{title:f("blocklet.config.session.phoneRequireUnique"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"phone.requireUnique",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})})]})]})]})]}),e.jsxs(A,{children:[e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:f("blocklet.config.session.period")}),e.jsx(A,{component:ee,sx:{my:3}}),e.jsx(ie,{direction:"column",spacing:2,children:e.jsx(H,{name:"ttl",control:b,rules:{min:1,max:30},render:({field:y})=>e.jsx(G,{fullWidth:!0,sx:{mb:2},children:e.jsx(M,{title:f("blocklet.config.session.ttl",{day:y.value}),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{width:"100%",maxWidth:500,px:2},children:e.jsx(zr,{...y,defaultValue:7,step:1,marks:[{value:1,label:f("blocklet.config.session.day",{day:1})},{value:7,label:f("blocklet.config.session.days",{day:7})},{value:14,label:f("blocklet.config.session.days",{day:14})},{value:21,label:f("blocklet.config.session.days",{day:21})},{value:30,label:f("blocklet.config.session.days",{day:30})}],min:1,max:30,valueLabelDisplay:"auto"})})})})})})]}),e.jsxs(A,{children:[e.jsx(J,{variant:"h6",sx:{fontWeight:600},children:f("blocklet.config.session.experimentalSettings")}),e.jsx(A,{component:ee,sx:{my:3}}),e.jsx(ie,{direction:"column",spacing:2,children:e.jsx(M,{title:f("blocklet.config.session.enableBlacklist"),sectionLeftSx:{width:"600px"},children:e.jsx(A,{sx:{alignSelf:"flex-start"},children:e.jsx(H,{name:"enableBlacklist",control:b,render:({field:y})=>e.jsx(K,{sx:{ml:0},control:e.jsx(he,{...y,checked:y.value})})})})})})]}),e.jsx(A,{children:e.jsx(Y,{type:"submit",variant:"contained",disabled:!m.isDirty,children:f("oauth.save")})})]})})}const qn=ve.form`
|
|
83
|
-
max-width: 1536px;
|
|
84
|
-
|
|
85
|
-
.advanced-config {
|
|
86
|
-
border: 0;
|
|
87
|
-
padding: 0;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
.config-form {
|
|
91
|
-
flex-grow: 1;
|
|
92
|
-
overflow-y: auto;
|
|
93
|
-
will-change: transform;
|
|
94
|
-
|
|
95
|
-
&:first-child {
|
|
96
|
-
margin: 0;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
${x=>x.theme.breakpoints.down("md")} {
|
|
100
|
-
width: 100%;
|
|
101
|
-
flex-shrink: 0;
|
|
102
|
-
padding: 0 24px;
|
|
103
|
-
transform: translate(0, 0);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
.config-item {
|
|
108
|
-
display: flex;
|
|
109
|
-
align-items: center;
|
|
110
|
-
justify-content: space-between;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
.config-desc {
|
|
114
|
-
font-weight: normal;
|
|
115
|
-
font-size: 12px;
|
|
116
|
-
color: #666;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
.form-item {
|
|
120
|
-
margin-top: 0;
|
|
121
|
-
}
|
|
122
|
-
`,Mn={width:24,height:24,body:'<path fill="currentColor" d="M6 12.05q0 1.125.425 2.188T7.75 16.2l.25.25V15q0-.425.288-.713T9 14q.425 0 .713.288T10 15v4q0 .425-.288.713T9 20H5q-.425 0-.713-.288T4 19q0-.425.288-.713T5 18h1.75l-.4-.35q-1.3-1.15-1.825-2.625T4 12.05Q4 9.7 5.2 7.787T8.425 4.85q.35-.2.738-.025t.512.575q.125.375-.013.75t-.487.575q-1.45.8-2.313 2.213T6 12.05Zm12-.1q0-1.125-.425-2.187T16.25 7.8L16 7.55V9q0 .425-.288.713T15 10q-.425 0-.713-.288T14 9V5q0-.425.288-.713T15 4h4q.425 0 .713.288T20 5q0 .425-.288.713T19 6h-1.75l.4.35q1.225 1.225 1.788 2.663T20 11.95q0 2.35-1.2 4.263t-3.225 2.937q-.35.2-.737.025t-.513-.575q-.125-.375.013-.75t.487-.575q1.45-.8 2.313-2.212T18 11.95Z"/>'};var nt,Mt;function zn(){if(Mt)return nt;Mt=1;const{DEFAULT_IP_DOMAIN_SUFFIX:x,SLOT_FOR_IP_DNS_SITE:C,DEFAULT_DID_DOMAIN:$}=tr(),{encode:R}=sr();return nt={getIpDnsDomainForBlocklet:m=>`${R(m.meta.did)}-${C}.${x}`,getDidDomainForBlocklet:({did:m,didDomain:r=$})=>`${R(m)}.${r}`},nt}var Hn=zn();function fs({ref:x=null}){const{t:C}=L.useContext(ue),{blocklet:$}=oe(),{api:R}=re(),_=ye({loadingReject:!1,loadingApprove:!1,mode:"view",show:!1,data:{},callback:ce}),m=$e()?.transitions?.duration?.leavingScreen||300,r=E(()=>{_.mode="view",_.data={},_.callback=ce}),p=E(()=>{_.show=!1,setTimeout(()=>{r()},m)}),f=E(s=>{_.mode="view",_.show=!0,_.data=s}),h=E((s,c=ce)=>{_.mode="approve",_.show=!0,_.data=s,_.callback=c});L.useImperativeHandle(x,()=>({open:f,close:p,approve:h}),[f,p,h]);const t=ge(()=>{if(!_.show)return[];_.data.migratedFrom=[_.data.appId,_.data.appPid];const s=["appName","appLogo","appId","appPid","migratedFrom","appDescription","appUrl","version","appliedAt","status","serverId","serverVersion"];return _.data.isMaster!==!1&&sn(s,"appliedAt","status"),s.map(c=>{const a=C(`federated.info.${c}`);let i=_.data[c];if(c==="appName"&&_.data.isMaster&&(i=e.jsxs(A,{children:[e.jsx(Ut,{component:ss}),i]})),["appId","appPid","serverId"].includes(c)&&(i=e.jsx(ot,{children:i})),["appUrl"].includes(c)&&(i=e.jsx(A,{component:"a",href:i,target:"_blank",children:i})),["appLogo"].includes(c)){const u=Vt(`https://${Hn.getDidDomainForBlocklet({did:_.data.appPid})}`,W.WELLKNOWN_SERVICE_PATH_PREFIX,"/blocklet/logo");try{const g=new URL(u);g.searchParams.set("imageFilter","resize"),g.searchParams.set("w","80"),g.searchParams.set("h","80"),i=e.jsx("img",{src:g.href,width:"60",height:"60",alt:_.data.appName})}catch{i=e.jsx("img",{src:u,width:"60",height:"60",alt:_.data.appName})}}return c==="status"&&(i=i&&C(`federated.status.${i}`)),c==="migratedFrom"&&(i=(_.data.migratedFrom||[]).filter(y=>![_.data.appId,_.data.appPid].includes(y)).map(y=>e.jsx(ot,{children:y}))),rr(i)&&(i="-"),{name:a,value:i}})},[_.data]),l=_.mode==="approve",o=E(async()=>{try{_.loadingReject=!0,await R.auditFederatedLogin({input:{memberPid:_.data.appPid,did:$.appPid,status:"rejected"}}),p(),_?.callback(!1)}finally{_.loadingReject=!1}}),n=E(async()=>{try{_.loadingApprove=!0,await R.auditFederatedLogin({input:{memberPid:_.data.appPid,did:$.appPid,status:"approved"}}),p(),_?.callback(!0)}finally{_.loadingApprove=!1}});return e.jsx(ke,{open:_.show,title:C(l?"federated.approveToJoinLogin":"federated.siteDetail"),onClose:p,actions:l?e.jsxs(e.Fragment,{children:[e.jsxs(Y,{color:"error",variant:"contained",onClick:o,disabled:_.loadingReject,children:[_.loadingReject?e.jsx(Ie,{size:16,color:"grey"}):null,C("common.reject")]}),e.jsxs(Y,{variant:"contained",onClick:n,disabled:_.loadingApprove,children:[_.loadingApprove?e.jsx(Ie,{size:16,color:"grey"}):null,C("common.approve")]})]}):e.jsx(Y,{variant:"outlined",onClick:p,children:C("common.close")}),children:t.map(s=>e.jsx(Yt,{style:{alignItems:"flex-start"},valueComponent:"div",nameWidth:180,name:s.name,children:s.value},s.name))})}fs.propTypes={ref:T.any};function bt({ref:x=null}){const $=$e()?.transitions?.duration?.leavingScreen||300,{t:R}=L.useContext(ue),_=ye({show:!1,data:{link:""}}),b=E(()=>{_.data.link=""}),m=E(()=>{_.show=!1,setTimeout(()=>{b()},$)}),r=E(({link:f})=>{_.show=!0,_.data.link=f});L.useImperativeHandle(x,()=>({open:r,close:m}),[r,m]);const p=E(()=>{nr(_.data.link),m()});return e.jsxs(ke,{open:_.show,title:R("federated.joinFederatedLogin"),onClose:m,PaperProps:{style:{minHeight:"unset"}},actions:e.jsx(te,{color:"primary",autoFocus:!0,variant:"contained",onClick:p,children:R("common.copyAndClose")}),children:[e.jsx(A,{sx:{mb:1},children:R("federated.inviteJoinFederatedLoginDescription")}),e.jsx(A,{sx:{"& .copy-button":{display:"none !important"}},children:e.jsx(Hr,{language:"shell",style:{marginBottom:0},children:_.data.link})})]})}bt.propTypes={ref:T.any};function ms({mode:x="member"}){const C=L.useRef(null),$=L.useRef(null),{t:R,locale:_}=L.useContext(ue),{blocklet:b,actions:{refreshBlocklet:m}}=oe(),{confirmApi:r,confirmHolder:p}=Ze(),{api:f}=re(),h=b.settings.federated?.sites||[],t=b.settings.federated?.config||{},l=t.isMaster!==!1,o=h.find(S=>S.appPid===b.appPid),n=ye({loadingSync:!1}),s=E(S=>{$.current?.open(S)}),c=E(S=>{$.current?.approve(S,m)}),a=E(S=>{r.open({title:R("federated.removeFederatedLogin"),content:R("federated.removeFederatedLoginDescription"),confirmButtonText:R("common.confirm"),cancelButtonText:R("common.cancel"),confirmButtonProps:{color:"error"},async onConfirm(O){await f.quitFederatedLogin({input:{did:b.appPid,targetDid:S.appPid}}),O()}})}),i=E(S=>{r.open({title:R("federated.disableFederatedLogin"),content:R("federated.disableFederatedLoginDescription"),confirmButtonText:R("common.confirm"),cancelButtonText:R("common.cancel"),confirmButtonProps:{color:"error"},async onConfirm(O){await f.auditFederatedLogin({input:{memberPid:S.appPid,did:b.appPid,status:"revoked"}}),O()}})}),u=E(S=>{r.open({title:R("federated.enableFederatedLogin"),content:R("federated.enableFederatedLoginDescription"),confirmButtonText:R("common.confirm"),cancelButtonText:R("common.cancel"),async onConfirm(O){await f.auditFederatedLogin({input:{memberPid:S.appPid,did:b.appPid,status:"approved"}}),O()}})}),g=ge(()=>{const S=[{label:R("common.name"),name:"appName",options:{customBodyRenderLite:O=>{const P=h[O],D=P.isMaster!==!1;return e.jsx(A,{sx:{display:"inline-block"},children:e.jsxs(A,{component:"a",href:P.appUrl,target:"_blank",onClick:I=>{I.stopPropagation()},sx:{display:"flex",alignItems:"center"},children:[D&&e.jsx(Ut,{component:ss,style:{marginRight:"4px"}}),P.appName]})})}}},{label:R("common.did"),name:"appId",options:{customBodyRenderLite:O=>{const P=h[O];return e.jsx(ot,{children:P.appId})}}},{label:R("common.status"),name:"status",options:{customBodyRenderLite:O=>{const P=h[O],D=P.isMaster!==!1;return e.jsx(A,{children:D?"-":R(`federated.status.${P.status}`)})}}}];return l&&S.push({label:R("common.actions"),name:"actions",options:{customBodyRenderLite:O=>{const P=h[O],D=P.isMaster!==!1;return e.jsx(A,{sx:{display:"flex",gap:1},children:D?e.jsxs(e.Fragment,{children:[P.status==="rejected"&&e.jsx(te,{variant:"contained",color:"error",size:"small",onClick:I=>{I.stopPropagation()},children:R("federated.status.rejected")}),P.status==="revoked"&&e.jsx(te,{variant:"contained",color:"secondary",size:"small",onClick:I=>{I.stopPropagation()},children:R("federated.status.revoked")})]}):e.jsxs(e.Fragment,{children:[e.jsx(te,{variant:"contained",color:"error",size:"small",onClick:I=>{I.stopPropagation(),a(P)},children:R("federated.quitMember")},"quiteSite"),P.status==="pending"&&e.jsx(te,{variant:"contained",color:"primary",size:"small",onClick:I=>{I.stopPropagation(),c(P)},children:R("federated.status.pending")},"auditSite"),P.status==="approved"&&e.jsx(te,{variant:"contained",color:"error",size:"small",onClick:I=>{I.stopPropagation(),i(P)},style:{whiteSpace:"nowrap"},children:R("federated.revoke")},"revokeSite"),P.status==="revoked"&&e.jsx(te,{variant:"contained",color:"warning",size:"small",onClick:I=>{I.stopPropagation(),u(P)},style:{whiteSpace:"nowrap"},children:R("federated.approve")},"approveSite")]})})}}}),S},[t.appId,h,l,R]),y=ge(()=>({sort:!0,download:!1,filter:!1,print:!1,expandableRowsOnClick:!0,onRowClick(S,{dataIndex:O}){const P=h[O];s(P)}}),[]),k=E(()=>{const S=b.environments.find(O=>O.key===se.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_URL);S?.value?C.current?.open({link:S.value}):Z.error(R("federated.failedToGetFederatedLoginLink"))},[b.site?.domainAliases?.[0]?.href]),w=E(()=>{r.open({title:R("federated.quitFederatedLogin"),content:R("federated.quitFederatedLoginDescription"),confirmButtonText:R("common.confirm"),cancelButtonText:R("common.cancel"),confirmButtonProps:{color:"error"},async onConfirm(S){await f.quitFederatedLogin({input:{did:b.appPid}}),S()}})}),d=E(()=>{r.open({title:R("federated.disbandFederatedLogin"),content:R("federated.disbandFederatedLoginDescription"),confirmButtonText:R("common.confirm"),cancelButtonText:R("common.cancel"),confirmButtonProps:{color:"error"},async onConfirm(S){await f.disbandFederatedLogin({input:{did:b.appPid}}),S()}})}),v=E(async()=>{try{n.loadingSync=!0,await Promise.all([await f.syncFederatedConfig({input:{did:b.appPid}}),ar(500)]),Z.success(R("common.succeeded"))}finally{n.loadingSync=!1}}),j=[];return o.status!=="pending"&&j.push(e.jsx(X,{title:R("federated.syncConfig"),children:e.jsx(ne,{size:"small",onClick:v,disabled:n.loadingSync,sx:[{"@keyframes spin":{from:{transform:"rotate(0deg)"},to:{transform:"rotate(360deg)"}}},n.loadingSync?{animation:"spin 1s linear infinite"}:{}],children:e.jsx(Q,{icon:Mn,style:{fontSize:24}})},"syncConfig")})),x==="master"?(j.push(e.jsx(te,{size:"small",variant:"contained",onClick:k,sx:{ml:1},children:R("federated.inviteJoinFederatedLogin")},"inviteJoinFederatedLogin")),j.push(e.jsx(te,{color:"error",size:"small",variant:"contained",onClick:d,sx:{ml:1},children:R("federated.disbandFederatedLogin")},"disbandFederatedLogin"))):j.push(e.jsx(te,{size:"small",variant:"contained",color:"error",onClick:w,sx:{ml:1},children:R("federated.quitFederatedLogin")},"quitFederatedLogin")),e.jsxs(e.Fragment,{children:[e.jsx(Ue,{className:"main-table",locale:_,data:h,columns:g,customButtons:j,title:e.jsx(A,{className:"table-toolbar-left",children:R("oauth.federated")}),options:y}),p,e.jsx(bt,{ref:C}),e.jsx(fs,{ref:$})]})}ms.propTypes={mode:T.oneOf(["member","master"])};function ps({ref:x=null}){const{t:C}=L.useContext(ue),{api:$}=re(),{blocklet:R}=oe(),_=R?.appPid,m=$e()?.transitions?.duration?.leavingScreen||300,r=ye({loading:!1,show:!1,appUrl:"",appUrlError:"",callback:ce}),p=E(()=>{r.appUrl="",r.appUrlError="",r.callback=ce}),f=E(()=>{r.show=!1,setTimeout(()=>{p()},m)}),h=E((o=ce)=>{r.show=!0,r.callback=o});L.useImperativeHandle(x,()=>({open:h,close:f}),[h,f]);const t=E(o=>{if(!o)throw new Error(C("federated.federatedJoinAppUrlRequired"));if(!ir(o))throw new Error(C("federated.federatedJoinAppUrlInvalid"))}),l=E(async()=>{try{t(r.appUrl),r.loading=!0;const o=await $.joinFederatedLogin({input:{did:_,appUrl:r.appUrl}});r.show=!1,f(),r?.callback(o)}catch(o){r.appUrlError=o.message}finally{r.loading=!1}});return e.jsxs(ke,{open:r.show,title:C("federated.joinFederatedLogin"),onClose:f,PaperProps:{style:{minHeight:"unset"}},actions:e.jsxs(te,{color:"primary",autoFocus:!0,variant:"contained",onClick:l,disabled:r.loading,children:[r.loading?e.jsx(Ie,{size:16,sx:{mr:1},color:"grey"}):null,C("common.confirm")]}),children:[e.jsx(A,{sx:{mb:1},children:C("federated.joinFederatedLoginDescription")}),e.jsx(U,{fullWidth:!0,variant:"outlined",margin:"dense",placeholder:C("federated.federatedJoinAppUrl"),label:C("federated.federatedJoinAppUrl"),value:r.appUrl,error:!!r.appUrlError,helperText:r.appUrlError||"eg: https://www.arcblock.io",onChange:o=>{r.appUrl=o.target.value}})]})}ps.propTypes={ref:T.any};function Bn(){const{t:x}=L.useContext(ue);return e.jsxs(ie,{direction:"row",spacing:2,sx:{alignItems:"flex-start",p:2},children:[e.jsx(Nr,{fontSize:"large",color:"primary"}),e.jsxs(A,{children:[e.jsx(J,{variant:"h6",gutterBottom:!0,children:x("federated.title")}),e.jsx(J,{variant:"body2",sx:{color:"text.secondary"},children:x("federated.description")}),e.jsx(or,{href:"https://www.arcblock.io/blog/zh/did-connect-federated-login-support",underline:"hover",variant:"body2",color:"primary",target:"_blank",sx:{display:"inline-flex",alignItems:"center",mt:1},children:x("federated.link")})]})]})}function Fn(){const x=L.useRef(null),C=L.useRef(null),{t:$}=L.useContext(ue),{blocklet:R,actions:{refreshBlocklet:_}}=oe(),b=E(()=>{const r=R.site?.domainAliases?.[0]?.href;if(r)try{const p=new URL(r);x.current?.open({link:p.origin})}catch{Z.error($("federated.failedToGetFederatedLoginLink"))}},[R.site?.domainAliases?.[0]?.href]),m=E(()=>{C.current?.open(()=>{_()})});if(R.settings.federated?.sites.length>0){const r=R.settings.federated?.config.isMaster!==!1;return e.jsx(ms,{mode:r?"master":"member"})}return e.jsxs(e.Fragment,{children:[e.jsx(A,{sx:{display:"flex",flexDirection:"column",gap:2,justifyContent:"center",alignItems:"center",minHeight:"200px"},children:e.jsxs(A,{sx:{maxWidth:400,borderRadius:2,border:"1px solid",borderColor:"divider"},children:[e.jsx(Bn,{}),e.jsx(ee,{sx:{width:1}}),e.jsxs(ie,{sx:{width:1,p:2,gap:1.5},children:[e.jsx(te,{variant:"contained",onClick:b,sx:{width:1},children:$("federated.inviteJoinFederatedLogin")}),e.jsx(te,{variant:"outlined",onClick:m,sx:{width:1},children:$("federated.joinFederatedLogin")})]})]})}),e.jsx(bt,{ref:x}),e.jsx(ps,{ref:C})]})}function gs({orientation:x="horizontal"}){const{t:C}=L.useContext(ue),$=es({key:"lg"}),R=[{label:e.jsx(A,{sx:{textAlign:"center",width:"100%"},children:C("oauth.commonSettings")}),value:"settings"},{label:e.jsx(A,{sx:{textAlign:"center",width:"100%"},children:C("oauth.federated")}),value:"federated"},{label:e.jsx(A,{sx:{textAlign:"center",width:"100%"},children:C("oauth.oauth")}),value:"oauth"},{label:e.jsx(A,{sx:{textAlign:"center",width:"100%"},children:C("oauth.moreLogin")}),value:"more"}],[_,b]=L.useState(R[0].value),m=ge(()=>({oauth:e.jsx(Dn,{}),federated:e.jsx(Fn,{}),more:e.jsx(Ir,{children:C("oauth.comingSoon")}),settings:e.jsx(Ln,{})}),[C]);return x==="vertical"?e.jsx(Nn,{children:e.jsxs(ie,{direction:{md:"column",lg:"row"},sx:{gap:2},children:[e.jsx(A,{sx:{minWidth:"240px",flexShrink:0},children:e.jsx(Ne,{tabs:R,current:_,orientation:$?"horizontal":"vertical",onChange:b,sx:{borderRight:$?0:1,height:"100%",borderColor:"divider"}})}),e.jsx(A,{sx:{flexGrow:1,minWidth:0},children:e.jsx(A,{sx:{maxWidth:"1200px"},children:m[_]})})]})}):e.jsxs(A,{children:[e.jsx(Ne,{tabs:R,current:_,onChange:b}),e.jsx(A,{sx:{marginTop:"10px"},children:m[_]})]})}gs.propTypes={orientation:T.oneOf(["horizontal","vertical"])};const Nn=ve.div`
|
|
123
|
-
.MuiTab-root {
|
|
124
|
-
text-align: left;
|
|
125
|
-
align-items: flex-start;
|
|
126
|
-
font-weight: normal;
|
|
127
|
-
|
|
128
|
-
div {
|
|
129
|
-
text-align: left;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
.Mui-selected {
|
|
134
|
-
font-weight: bold;
|
|
135
|
-
}
|
|
136
|
-
`,Zn={width:24,height:24,body:'<path fill="currentColor" d="M11 14.2V6q0-.425.288-.713T12 5q.425 0 .713.288T13 6v8.2l2.9-2.9q.275-.275.7-.275t.7.275q.275.275.275.7t-.275.7l-4.6 4.6q-.3.3-.7.3t-.7-.3l-4.6-4.6q-.275-.275-.275-.7t.275-.7q.275-.275.7-.275t.7.275l2.9 2.9Z"/>'},Vn={width:24,height:24,body:'<path fill="currentColor" d="m11 8.8l-2.9 2.9q-.275.275-.7.275t-.7-.275q-.275-.275-.275-.7t.275-.7l4.6-4.6q.3-.3.7-.3t.7.3l4.6 4.6q.275.275.275.7t-.275.7q-.275.275-.7.275t-.7-.275L13 8.8V17q0 .425-.288.713T12 18q-.425 0-.713-.288T11 17V8.8Z"/>'},jt={width:24,height:24,body:'<path fill="currentColor" d="M7 21q-.825 0-1.413-.588T5 19V6q-.425 0-.713-.288T4 5q0-.425.288-.713T5 4h4q0-.425.288-.713T10 3h4q.425 0 .713.288T15 4h4q.425 0 .713.288T20 5q0 .425-.288.713T19 6v13q0 .825-.588 1.413T17 21H7Zm2-4h2V8H9v9Zm4 0h2V8h-2v9Z"/>'},_t={width:24,height:24,body:'<path fill="currentColor" d="M4 21q-.425 0-.713-.288T3 20v-2.425q0-.4.15-.763t.425-.637L16.2 3.575q.3-.275.663-.425t.762-.15q.4 0 .775.15t.65.45L20.425 5q.3.275.437.65T21 6.4q0 .4-.138.763t-.437.662l-12.6 12.6q-.275.275-.638.425t-.762.15H4ZM17.6 7.8L19 6.4L17.6 5l-1.4 1.4l1.4 1.4Z"/>'};function ys({enabled:x,showUp:C=!0,showDown:$=!0,showSwitch:R=!0,showDelete:_=!0,showEdit:b=!0,disableEdit:m=!1,disableSwitch:r=!1,onClickUp:p=()=>{},onClickDown:f=()=>{},onClickSwitch:h=()=>{},onClickDelete:t=()=>{},onClickEdit:l=()=>{}}){const{t:o}=ae();return e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:0},onClick:n=>n.stopPropagation(),children:[b?e.jsx(X,{title:o("common.edit"),children:e.jsx(ne,{size:"small",onClick:l,color:"success",disabled:m,children:e.jsx(Q,{icon:_t,fontSize:18})})}):null,_?e.jsx(X,{title:o("common.delete"),children:e.jsx(ne,{size:"small",onClick:t,color:"error",children:e.jsx(Q,{icon:jt,fontSize:18})})}):null,R?e.jsx(X,{title:o(x?"common.enabled":"common.disabled"),children:e.jsx(pe,{size:"small",checked:x,onClick:h,disabled:r})}):null,C?e.jsx(X,{title:o("common.moveUp"),children:e.jsx(ne,{size:"small",onClick:p,disabled:m,children:e.jsx(Q,{icon:Vn,fontSize:20})})}):null,$?e.jsx(X,{title:o("common.moveDown"),children:e.jsx(ne,{size:"small",onClick:f,disabled:m,children:e.jsx(Q,{icon:Zn,fontSize:20})})}):null]})}ys.propTypes={enabled:T.bool.isRequired,showUp:T.bool,showDown:T.bool,showSwitch:T.bool,showDelete:T.bool,showEdit:T.bool,disableEdit:T.bool,disableSwitch:T.bool,onClickUp:T.func,onClickDown:T.func,onClickSwitch:T.func,onClickDelete:T.func,onClickEdit:T.func};function vs({ref:x=null}){const{t:C}=L.useContext(ue),{blocklet:$}=oe(),{api:R}=re(),_=$?.meta?.did,m=$e()?.transitions?.duration?.leavingScreen||300,r=ye({mode:"add",show:!1,isDefaultRule:!1,callback:ce,get dialogTitle(){return this.mode==="edit"?C("securityRule.edit"):this.mode==="view"?C("securityRule.view"):C("securityRule.add")}}),p=ze(async()=>{const{accessPolicies:S}=await R.getBlockletAccessPolicies({input:{did:_}});return Be(S,O=>O.isProtected?1:0)},{manual:!0}),f=ze(async()=>{const{responseHeaderPolicies:S}=await R.getBlockletResponseHeaderPolicies({input:{did:_}});return Be(S,O=>O.isProtected?1:0)},{manual:!0}),{handleSubmit:h,control:t,watch:l,setValue:o,getValues:n,reset:s,formState:{errors:c}}=xe({mode:"onChange",defaultValues:{componentDid:"",pathPattern:"",responseHeaderPolicyId:"",accessPolicyId:"",remark:""}}),a=E(()=>{s(),r.mode="add"}),i=E(()=>{r.show=!1,setTimeout(()=>{a()},m)}),u=E((S,O=null)=>{r.show=!0,O&&(r.isDefaultRule=O.id===W.SECURITY_RULE_DEFAULT_ID,r.mode="edit",o("componentDid",O.componentDid),o("pathPattern",O.pathPattern),o("responseHeaderPolicyId",O.responseHeaderPolicyId),o("accessPolicyId",O.accessPolicyId),o("remark",O.remark||"")),S?r.callback=S:r.mode="view",p.run(),f.run()});L.useImperativeHandle(x,()=>({open:u,close:i}),[u,i]);const g=E(()=>{const[S,O]=n(["accessPolicyId","responseHeaderPolicyId"]);return!S&&!O?C("securityRule.form.accessPolicyOrResponseHeaderPolicyRequired"):!0}),y=E(S=>{const O=g();if(O===!0){const P=r.isDefaultRule?Ce(S,"componentDid"):S;r.callback(P,i)}else Z.error(O)}),k=l("componentDid"),w=E(S=>{const O=S?.trim();if(!O)return C("common.requiredErrorText",{name:C("securityRule.form.pathPattern")});if(k){if(O.startsWith("/"))return C("securityRule.form.pathPatternErrorText")}else if(!O.startsWith("/")&&O!=="*")return C("securityRule.form.pathPatternErrorText");return!0}),d=E(S=>S?.trim()?!0:C("common.requiredErrorText",{name:C("securityRule.form.accessPolicy")})),v=E(S=>S?.trim()?!0:C("common.requiredErrorText",{name:C("securityRule.form.responseHeaderPolicy")})),j=ge(()=>{const O=($?.children||[]).find(P=>P.meta.did===k);return O?.mountPoint?lr(O.mountPoint):null},[$,k]);return e.jsx(ke,{open:r.show,title:r.dialogTitle,onClose:i,PaperProps:{style:{minHeight:"unset"}},actions:e.jsx(te,{color:"primary",autoFocus:!0,variant:"contained",onClick:h(y),children:C("common.confirm")}),children:e.jsxs("form",{noValidate:!0,autoComplete:"off",children:[r.isDefaultRule?null:e.jsx(H,{name:"componentDid",control:t,render:({field:S})=>e.jsx(Ge,{fullWidth:!0,margin:"dense",size:"small",label:C("securityRule.form.component"),placeholer:C("securityRule.form.componentPlaceholder"),options:$.children.map(O=>({title:O.meta.title,value:O.meta.did,description:O.mountPoint})),error:!!c?.componentDid?.message,helperText:c?.componentDid?.message||"Choose belong to component",...Ce(S,"ref"),readOnly:r.mode==="view"})}),e.jsx(H,{name:"pathPattern",control:t,rules:{validate:w},render:({field:S})=>e.jsx(U,{fullWidth:!0,required:!0,margin:"dense",size:"small",placeholder:C("securityRule.form.pathPatternPlaceholder"),label:C("securityRule.form.pathPattern"),error:!!c?.pathPattern?.message,helperText:c?.pathPattern?.message||"/abc/bcd or /abc or /abc/*",...S,disabled:r.isDefaultRule||r.mode==="view",slotProps:{input:{startAdornment:j?e.jsx(Zt,{position:"start",children:j}):null}}})}),e.jsx(H,{name:"accessPolicyId",control:t,rules:{validate:r.isDefaultRule?d:ce},render:({field:S})=>e.jsx(Ge,{fullWidth:!0,required:r.isDefaultRule,margin:"dense",size:"small",label:C("securityRule.form.accessPolicy"),placeholer:C("securityRule.form.accessPolicyPlaceholder"),options:(p.data||[]).map(O=>({value:O.id,title:O.name,description:O.description})),error:!!c?.accessPolicyId?.message,helperText:c?.accessPolicyId?.message||C("securityRule.form.accessPolicyHelperText"),...Ce(S,"ref"),disabled:r.mode==="view"})}),e.jsx(H,{name:"responseHeaderPolicyId",control:t,rules:{validate:r.isDefaultRule?v:ce},render:({field:S})=>e.jsx(Ge,{fullWidth:!0,required:r.isDefaultRule,margin:"dense",size:"small",label:C("securityRule.form.responseHeaderPolicy"),placeholer:C("securityRule.form.responseHeaderPolicyPlaceholder"),options:(f.data||[]).map(O=>({title:O.name,value:O.id,description:O.description})),error:!!c?.responseHeaderPolicyId?.message,helperText:c?.responseHeaderPolicyId?.message||C("securityRule.form.responseHeaderPolicyHelperText"),...Ce(S,"ref"),disabled:r.mode==="view"})}),e.jsx(H,{name:"remark",control:t,render:({field:S})=>e.jsx(U,{fullWidth:!0,multiline:!0,minRows:3,maxRows:7,size:"small",margin:"dense",placeholder:C("securityRule.form.remarkPlaceholder"),label:C("securityRule.form.remark"),helperText:c?.message,...S,disabled:r.mode==="view"})})]})})}vs.propTypes={ref:T.any};const fe=async(x,C="Failed to saved")=>{try{await x()}catch($){Z.error($?.message||C)}};function Un(){const{t:x,locale:C}=ae(),{blocklet:$}=oe(),{api:R}=re(),_=$?.meta?.did,b=$e(),m=L.useRef(null),r=L.useRef(null),{confirmApi:p,confirmHolder:f}=Ze(),h=ze(async()=>{const{securityRules:d}=await R.getBlockletSecurityRules({input:{did:_,includeDisabled:!0}});return d}),t=d=>d.id===W.SECURITY_RULE_DEFAULT_ID,l=E(d=>($?.children||[]).find(j=>j.meta.did===d)?.mountPoint),o=(h.data||[]).map(d=>{if(d.componentDid){const v=l(d.componentDid);d._disabled=v===void 0}return d}),n=o.filter(d=>!t(d)),s=(d,v)=>{fe(async()=>{const j=d.target.checked;await R.updateBlockletSecurityRule({input:{did:_,data:{id:v.id,enabled:j}}}),Z.success(x("common.succeeded")),h.run()})},c=(d,v,j)=>{fe(async()=>{const S=j-1,O=o[S];await Promise.all([R.updateBlockletSecurityRule({input:{did:_,data:{id:v.id,priority:O.priority}}}),R.updateBlockletSecurityRule({input:{did:_,data:{id:O.id,priority:v.priority}}})]),Z.success(x("common.succeeded")),h.run()})},a=(d,v,j)=>{fe(async()=>{const S=j+1,O=o[S];await Promise.all([R.updateBlockletSecurityRule({input:{did:_,data:{id:v.id,priority:O.priority}}}),R.updateBlockletSecurityRule({input:{did:_,data:{id:O.id,priority:v.priority}}})]),Z.success(x("common.succeeded")),h.run()})},i=()=>{m.current.open((d,v)=>{fe(async()=>{await R.addBlockletSecurityRule({input:{did:_,data:d}}),Z.success(x("common.succeeded")),h.run(),v()})})},u=(d,v)=>{m.current.open((j,S)=>{fe(async()=>{await R.updateBlockletSecurityRule({input:{did:_,data:{...j,id:v.id}}}),Z.success(x("common.succeeded")),h.run(),S()})},v)},g=(d,v)=>{p.open({title:x("securityRule.delete.title"),content:x("securityRule.delete.description"),confirmButtonText:x("common.confirm"),confirmButtonProps:{color:"error"},cancelButtonText:x("common.cancel"),onConfirm(j){fe(async()=>{await R.deleteBlockletSecurityRule({input:{did:_,id:v.id}}),Z.success(x("common.succeeded")),h.run(),j()})}})},y={sort:!1,download:!1,filter:!1,print:!1,search:!1,viewColumns:!1,expandableRowsOnClick:!0,searchDebounceTime:600,onRowClick(d,{dataIndex:v},j){if(r.current?.contains(j.target)){const S=o[v];m.current.open(void 0,S)}},setRowProps:(d,v)=>o[v]._disabled?{title:x("securityRule.useless"),style:{backgroundColor:b.palette.action.disabledBackground,cursor:"default"}}:{}},k=[e.jsx(Y,{size:"small",variant:"outlined",onClick:()=>{h.run()},sx:{mr:1},children:x("common.refresh")},"refresh"),e.jsx(Y,{size:"small",variant:"contained",onClick:i,children:x("common.add")})],w=[{label:x("securityRule.form.pathPattern"),name:"pathPattern",options:{customBodyRenderLite(d){const v=o[d];return e.jsx(A,{sx:{whiteSpace:"nowrap"},children:v.id===W.SECURITY_RULE_DEFAULT_ID?"Default":Vt(l(v.componentDid),v.pathPattern)})}}},{label:x("responseHeaderPolicy.title"),name:"responseHeaderPolicy",options:{customBodyRenderLite(d){return o[d].responseHeaderPolicy?.name}}},{label:x("accessPolicy.title"),name:"accessPolicyId",options:{customBodyRenderLite(d){return o[d].accessPolicy?.name}}},{label:x("securityRule.form.remark"),name:"remark"},{label:x("common.actions"),name:"",width:100,align:"center",verticalKeyAlign:"center",options:{customBodyRenderLite(d){const v=o[d],j=t(v);return e.jsx(ys,{disableEdit:v._disabled,disableSwitch:v._disabled,enabled:v.enabled,showSwitch:!j,showDelete:!j,showUp:d>0&&!j,showDown:d<n.length-1&&!j,onClickSwitch:S=>{s(S,v)},onClickUp:S=>{c(S,v,d)},onClickDown:S=>{a(S,v,d)},onClickEdit:S=>{u(S,v)},onClickDelete:S=>{g(S,v)}})}}}].filter(Boolean);return e.jsxs(A,{sx:{display:"flex",flexDirection:"column",gap:2},ref:r,children:[e.jsx(Ue,{verticalKeyWidth:100,locale:C,title:e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:1},children:[x("securityRule.title")," ",e.jsx(J,{variant:"body2",children:x("securityRule.sortByDescription")})]}),data:o,columns:w,customButtons:k,options:y,loading:h.loading}),e.jsx(vs,{ref:m}),f]})}const xs={width:24,height:24,body:'<path fill="currentColor" d="M5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.588 1.413T19 21H5Zm0-2h14V7H5v12Zm7-2q-2.05 0-3.663-1.113T6 13q.725-1.775 2.337-2.888T12 9q2.05 0 3.663 1.113T18 13q-.725 1.775-2.337 2.888T12 17Zm0-2.5q-.625 0-1.063-.438T10.5 13q0-.625.438-1.063T12 11.5q.625 0 1.063.438T13.5 13q0 .625-.438 1.063T12 14.5Zm0 1q1.05 0 1.775-.725T14.5 13q0-1.05-.725-1.775T12 10.5q-1.05 0-1.775.725T9.5 13q0 1.05.725 1.775T12 15.5Z"/>'},bs=[{value:W.WHO_CAN_ACCESS.ALL,icon:Rr,title:{zh:"面向所有人",en:"Open to Everyone"},description:{zh:"任何人都可以访问应用而不需要身份验证。",en:"Anyone can access this blocklet without authenticating."}},{value:W.WHO_CAN_ACCESS.INVITED,icon:Zr,title:{zh:"仅限受邀",en:"Invite-Only Access"},description:{zh:"仅限受邀用户可访问应用。",en:"Only invited members can access."}},{value:W.WHO_CAN_ACCESS.ADMIN,icon:Jr,title:{zh:"仅限拥有者 & 管理员",en:"Owner & Admin Access."},description:{zh:"仅限拥有者或管理员访问应用。",en:"Only the owner or an admin can access it."}},{value:W.WHO_CAN_ACCESS.OWNER,icon:lt,title:{zh:"仅限拥有者",en:"Owner-Only Access"},description:{zh:"仅限拥有者访问应用。",en:"Only the blocklet owner can access it."}}];function js({value:x,onChange:C,...$}){const R="roles",_="roles_reverse",{t:b,locale:m}=ae(),r=[...bs,{value:R,icon:Br,title:{zh:"指定通行证可访问",en:"Accessible to selected passports"},description:{zh:"只有指定的通行证可以访问",en:"Only specified passports can access"}},{value:_,icon:Vr,title:{zh:"指定通行证不可以访问",en:"Accessible to not selected passports"},description:{zh:"只有指定的通行证不可以访问",en:"Only specified passports can't access"}}];return e.jsx(U,{...$,label:b("blocklet.config.access.description"),select:!0,fullWidth:!0,value:x,onChange:C,slotProps:{select:{renderValue:p=>{const f=r.find(h=>h.value===p);return f?e.jsxs(A,{children:[e.jsx(A,{component:f.icon,sx:{mr:1,fontSize:18,verticalAlign:"text-bottom",color:"text.secondary"}}),f.title[m]||f.title.en]}):null}}},children:r.map(p=>e.jsxs(cr,{value:p.value,sx:{display:"block","& .tip":{fontSize:"12px",color:`${({theme:f})=>f.palette.text.secondary}`}},children:[e.jsxs(A,{sx:{display:"flex",alignItems:"center"},children:[e.jsx(A,{component:p.icon,sx:{mr:1,fontSize:18,verticalAlign:"text-bottom",color:"text.secondary"}}),e.jsx(A,{children:p.title[m]||p.title.en})]}),e.jsx(A,{className:"tip",children:p.description[m]||p.description.en})]}))})}js.propTypes={value:T.string,onChange:T.func};const _s=x=>{const C={name:x.name,description:x.description},{roles:$=null,reverse:R}=x;return $===null?R===!1&&(C.whoCanAccess=W.WHO_CAN_ACCESS.ALL,C.roles=null):$.length===0&&R===!0?(C.whoCanAccess=W.WHO_CAN_ACCESS.INVITED,C.roles=[]):Ct($,[W.WHO_CAN_ACCESS.OWNER])&&R===!1?(C.whoCanAccess=W.WHO_CAN_ACCESS.OWNER,C.roles=[W.WHO_CAN_ACCESS.OWNER]):Ct($,[W.WHO_CAN_ACCESS.OWNER,W.WHO_CAN_ACCESS.ADMIN])&&R===!1?(C.whoCanAccess=W.WHO_CAN_ACCESS.ADMIN,C.roles=[W.WHO_CAN_ACCESS.OWNER,W.WHO_CAN_ACCESS.ADMIN]):(C.whoCanAccess=R?"roles_reverse":"roles",C.roles=$),C},Wn=x=>{const C={name:x.name,description:x.description},{roles:$=null,whoCanAccess:R}=x;return R==="roles"?(C.roles=$,C.reverse=!1):R==="roles_reverse"?(C.roles=$,C.reverse=!0):R===W.WHO_CAN_ACCESS.ALL?(C.roles=null,C.reverse=!1):R===W.WHO_CAN_ACCESS.INVITED?(C.roles=[],C.reverse=!0):R===W.WHO_CAN_ACCESS.OWNER?(C.roles=[W.WHO_CAN_ACCESS.OWNER],C.reverse=!1):R===W.WHO_CAN_ACCESS.ADMIN&&(C.roles=[W.WHO_CAN_ACCESS.OWNER,W.WHO_CAN_ACCESS.ADMIN],C.reverse=!1),C},Jn=x=>x instanceof Object?{origin:x.origin?{override:x.origin?.override??!0,value:x.origin?.value?.join(`
|
|
137
|
-
`),smart:x.origin?.smart??!0}:void 0,methods:x.methods,allowedHeaders:x.allowedHeaders?{override:x.allowedHeaders?.override??!0,value:x.allowedHeaders?.value?.join(`
|
|
138
|
-
`)}:void 0,exposedHeaders:x.exposedHeaders?{override:x.exposedHeaders?.override??!0,value:x.exposedHeaders?.value?.join(`
|
|
139
|
-
`)}:void 0,maxAge:x.maxAge,optionsSuccessStatus:x.optionsSuccessStatus,preflightContinue:x.preflightContinue,credentials:x.credentials}:void 0,Kn=x=>x instanceof Object?{origin:{override:x.origin?.override,value:x.origin?.value?.split(`
|
|
140
|
-
`).filter($=>$),smart:x.origin?.smart},methods:x.methods,allowedHeaders:{override:x.allowedHeaders?.override,value:x.allowedHeaders?.value?.split(`
|
|
141
|
-
`).filter($=>$)},exposedHeaders:{override:x.exposedHeaders?.override,value:x.exposedHeaders?.value?.split(`
|
|
142
|
-
`).filter($=>$)},maxAge:x.maxAge,optionsSuccessStatus:x.optionsSuccessStatus,preflightContinue:x.preflightContinue,credentials:x.credentials}:void 0,Gn=x=>x instanceof Object?{contentSecurityPolicy:x.contentSecurityPolicy,referrerPolicy:x.referrerPolicy,xFrameOptions:x.xFrameOptions,xPoweredBy:x.xPoweredBy,xXssProtection:x.xXssProtection}:void 0,Yn=x=>x instanceof Object?{contentSecurityPolicy:x.contentSecurityPolicy,referrerPolicy:x.referrerPolicy,xFrameOptions:x.xFrameOptions,xPoweredBy:x.xPoweredBy,xXssProtection:x.xXssProtection}:void 0,Xn=x=>{const C=Wt(x);if(x.securityHeader)try{C.securityHeader=JSON.parse(x.securityHeader)}catch{C.securityHeader=null}if(x.cors)try{C.cors=JSON.parse(x.cors)}catch{C.cors=null}return C};function ws({ref:x=null}){const{t:C}=L.useContext(ue),{roles:$}=Ve(),_=$e()?.transitions?.duration?.leavingScreen||300,b=ye({mode:"add",show:!1,callback:ce,get dialogTitle(){return this.mode==="edit"?C("accessPolicy.edit"):this.mode==="view"?C("accessPolicy.view"):C("accessPolicy.add")}}),{handleSubmit:m,control:r,watch:p,setValue:f,reset:h,formState:{errors:t}}=xe({mode:"onChange",defaultValues:{name:"",description:"",roles:null,whoCanAccess:"all"}}),l=E(()=>{h(),b.mode="add"}),o=E(()=>{b.show=!1,setTimeout(()=>{l()},_)}),n=E((y=ce,k=null)=>{if(b.callback=y,b.show=!0,k){k.id?b.mode="edit":b.mode="view";const w=_s(k);f("name",w.name),f("description",w.description),f("roles",w.roles),f("whoCanAccess",w.whoCanAccess)}});L.useImperativeHandle(x,()=>({open:n,close:o}),[n,o]);const s=E(y=>{b.callback(Wn(y),o)}),c=E(y=>y?.trim()?!0:C("common.requiredErrorText",{name:C("accessPolicy.form.name")})),a=p("whoCanAccess"),i=b.mode==="view",u=E(y=>["roles","roles_reverse"].includes(a)&&(!y||y?.length===0)?C("common.requiredErrorText",{name:C("accessPolicy.form.roles")}):!0),g=E(y=>y?.trim()?!0:C("common.requiredErrorText",{name:C("accessPolicy.form.accessType")}));return e.jsx(ke,{open:b.show,title:b.dialogTitle,onClose:o,PaperProps:{style:{minHeight:"unset"}},actions:e.jsx(te,{color:"primary",autoFocus:!0,variant:"contained",onClick:m(s),children:C("common.confirm")}),children:e.jsxs("form",{noValidate:!0,autoComplete:"off",children:[e.jsx(H,{name:"name",control:r,rules:{validate:c},render:({field:y})=>e.jsx(U,{fullWidth:!0,required:!0,margin:"dense",size:"small",disabled:i,placeholder:C("accessPolicy.form.namePlaceholder"),label:C("accessPolicy.form.name"),error:!!t?.name?.message,helperText:t?.name?.message||" ",...y})}),e.jsx(H,{name:"whoCanAccess",control:r,rules:{validate:g},render:({field:y})=>e.jsx(js,{required:!0,size:"small",margin:"dense",disabled:i,error:!!t?.whoCanAccess?.message,helperText:t?.whoCanAccess?.message||" ",...y})}),["roles","roles_reverse"].includes(a)?e.jsx(H,{name:"roles",rules:{validate:u},control:r,render:({field:y})=>e.jsxs(G,{variant:"standard",error:!!t?.roles?.message,children:[e.jsx(Fe,{sx:{display:"flex",flexDirection:"row",mt:-3},children:$.map(k=>e.jsx(K,{control:e.jsx(Te,{disabled:i,size:"small",checked:y.value?.includes(k.name),sx:{p:.75},onChange:(w,d)=>{const v=y.value||[];d?y.onChange([...v,k.name]):y.onChange(v.filter(j=>j!==k.name))}}),label:k.title},k.name))}),e.jsx(zt,{sx:{transform:"translateY(-8px)"},children:t?.roles?.message||" "})]})}):null,e.jsx(H,{name:"description",control:r,render:({field:y})=>e.jsx(U,{fullWidth:!0,multiline:!0,disabled:i,minRows:3,maxRows:7,margin:"dense",size:"small",placeholder:C("accessPolicy.form.descriptionPlaceholder"),label:C("accessPolicy.form.description"),helperText:t?.message,...y})})]})})}ws.propTypes={ref:T.any};function Qn(){const{t:x,locale:C}=ae(),{blocklet:$}=oe(),{api:R}=re(),{roles:_}=Ve(),b=$?.meta?.did,m=L.useRef(null),r=L.useRef(null),{confirmApi:p,confirmHolder:f}=Ze(),h=()=>{},t=ze(async()=>{const{accessPolicies:g}=await R.getBlockletAccessPolicies({input:{did:b}});return Be(g,y=>y.isProtected?1:0)}),l=t.data||[],o=E(()=>{r.current.open((g,y)=>{fe(async()=>{await R.addBlockletAccessPolicy({input:{did:b,data:g}}),Z.success(x("common.succeeded")),t.run(),y()})})}),n=E(g=>{r.current.open((y,k)=>{fe(async()=>{await R.updateBlockletAccessPolicy({input:{did:b,data:{...y,id:g.id}}}),Z.success(x("common.succeeded")),t.run(),k()})},g)}),s=E(g=>{r.current.open((y,k)=>{k()},Ce(g,["id"]))}),c=E(g=>{p.open({title:x("accessPolicy.delete.title"),content:x("accessPolicy.delete.description"),confirmButtonText:x("common.confirm"),confirmButtonProps:{color:"error"},cancelButtonText:x("common.cancel"),onConfirm(y){fe(async()=>{await R.deleteBlockletAccessPolicy({input:{did:b,id:g.id}}),Z.success(x("common.succeeded")),t.run(),y()})}})}),a={sort:!1,download:!1,filter:!1,print:!1,search:!1,viewColumns:!1,expandableRowsOnClick:!0,searchDebounceTime:600,onRowClick(g,{dataIndex:y},k){if(m.current?.contains(k.target)){const w=l[y];s(w)}}},i=[e.jsx(Y,{size:"small",variant:"outlined",onClick:()=>{t.run()},sx:{mr:1},children:x("common.refresh")},"refresh"),e.jsx(Y,{size:"small",variant:"contained",onClick:o,children:x("common.add")})],u=[{label:x("accessPolicy.form.name"),name:"name",options:{customBodyRenderLite(g){const y=l[g],k=y.isProtected?e.jsx(X,{title:"Built-in policy, can't edit",children:e.jsx(A,{component:Q,icon:Jt,sx:{fontSize:16}})}):null;return e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:.5},children:[k," ",y.name]})}}},{label:x("accessPolicy.form.roles"),name:"roles",options:{customBodyRenderLite(g){const y=l[g],k=_s(y);if([W.WHO_CAN_ACCESS.ALL,W.WHO_CAN_ACCESS.INVITED].includes(k.whoCanAccess)){const d=bs.find(v=>v.value===k.whoCanAccess);return d.title?.[C]||d.title?.en}const w=_.filter(d=>y.reverse?!k.roles?.includes(d.name):k.roles?.includes(d.name));return e.jsx(A,{sx:{display:"flex",gap:1,flexWrap:"wrap"},children:w.map(d=>e.jsx(X,{title:d.description,children:e.jsx(ht,{size:"small",label:d.title},d.name)}))})}}},{label:x("accessPolicy.form.description"),name:"description"},{label:x("common.actions"),name:"",width:100,align:"center",verticalKeyAlign:"center",options:{customBodyRenderLite(g){const y=l[g];return e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:0},onClick:k=>k.stopPropagation(),children:[y.isProtected?e.jsx(X,{title:x("common.view"),children:e.jsx(ne,{size:"small",onClick:()=>{s(y,g)},children:e.jsx(Q,{icon:xs,fontSize:18})})}):null,y.isProtected?null:e.jsx(X,{title:x("common.edit"),children:e.jsx(ne,{size:"small",onClick:()=>{n(y,g)},color:"success",children:e.jsx(Q,{icon:_t,fontSize:18})})}),y.isProtected?null:e.jsx(X,{title:x("common.delete"),children:e.jsx(ne,{size:"small",onClick:()=>{c(y,g)},color:"error",children:e.jsx(Q,{icon:jt,fontSize:18})})})]})}}}].filter(Boolean);return e.jsxs(A,{sx:{display:"flex",flexDirection:"column",gap:2},ref:m,children:[e.jsx(Ue,{verticalKeyWidth:100,locale:C,title:x("accessPolicy.title"),data:l,columns:u,customButtons:i,options:a,loading:t.loading,onChange:h}),e.jsx(ws,{ref:r}),f]})}const ea={width:24,height:24,body:'<path fill="currentColor" d="m12 15.375l-6-6l1.4-1.4l4.6 4.6l4.6-4.6l1.4 1.4l-6 6Z"/>'};function dt({title:x,actions:C,children:$=null,defaultValue:R=!0,value:_,onChange:b,showExpand:m=!0}){const r=!we(_),p=ye({open:R}),f=ge(()=>r?_:p.open,[_,r,p.open]),h=E(()=>{r?b(!f):p.open=!p.open});return e.jsxs(Ht,{variant:"outlined",children:[e.jsxs(A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",cursor:"pointer",px:2,py:1,backgroundColor:"grey.50"},onClick:h,children:[e.jsx(A,{sx:{fontWeight:"bold"},children:x}),e.jsxs(A,{sx:{display:"flex",alignItems:"center"},children:[C,m?e.jsx(A,{component:Q,icon:ea,sx:{transform:f?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease",fontSize:"2rem"}}):null]})]}),e.jsx(dr,{in:f,children:e.jsx(Fr,{children:$})})]})}dt.propTypes={title:T.string.isRequired,defaultValue:T.bool,value:T.bool,actions:T.node,children:T.node,onChange:T.func,showExpand:T.bool};const ut={width:24,height:24,body:'<path fill="currentColor" d="M11.95 18q.525 0 .888-.363t.362-.887q0-.525-.362-.888t-.888-.362q-.525 0-.887.363t-.363.887q0 .525.363.888t.887.362Zm.05 4q-2.075 0-3.9-.788t-3.175-2.137q-1.35-1.35-2.137-3.175T2 12q0-2.075.788-3.9t2.137-3.175q1.35-1.35 3.175-2.137T12 2q2.075 0 3.9.788t3.175 2.137q1.35 1.35 2.138 3.175T22 12q0 2.075-.788 3.9t-2.137 3.175q-1.35 1.35-3.175 2.138T12 22Zm0-2q3.35 0 5.675-2.325T20 12q0-3.35-2.325-5.675T12 4Q8.65 4 6.325 6.325T4 12q0 3.35 2.325 5.675T12 20Zm0-8Zm.1-4.3q.625 0 1.088.4t.462 1q0 .55-.337.975t-.763.8q-.575.5-1.012 1.1t-.438 1.35q0 .35.263.588t.612.237q.375 0 .638-.25t.337-.625q.1-.525.45-.938t.75-.787q.575-.55.988-1.2t.412-1.45q0-1.275-1.038-2.087T12.1 6q-.95 0-1.812.4T8.975 7.625q-.175.3-.113.638t.338.512q.35.2.725.125t.625-.425q.275-.375.688-.575t.862-.2Z"/>'};function ks({config:x={},onChange:C=()=>{},disabled:$=!1}){const R=["GET","HEAD","POST","PUT","DELETE","OPTIONS","PATCH"],_={origin:{override:!1,value:"*",smart:!0},methods:{override:!1,value:[...R]},allowedHeaders:{override:!1,value:"*"},exposedHeaders:{override:!1,value:"*"},maxAge:{override:!1,value:void 0},optionsSuccessStatus:{override:!1,value:204},preflightContinue:{override:!1,value:!1},credentials:{override:!1,value:!1},...Kt(x,we)},{t:b}=ae(),m=(f,{override:h,value:t,smart:l})=>{const o={..._?.[f]};!we(l)&&f==="origin"&&(o.smart=l),we(h)||(o.override=h),we(t)||(o.value=t),C({..._,[f]:o})},r=[{title:b("responseHeaderPolicy.form.cors.origin"),override:_.origin.override,smart:_.origin.smart,name:"origin",required:!0,value:_.origin.value,content:e.jsx(G,{fullWidth:!0,sx:{mt:.75,"& .MuiFormHelperText-root":{mx:0}},children:e.jsx(U,{multiline:!0,minRows:4,maxRows:10,disabled:$,variant:"outlined",size:"small",placeholder:b("responseHeaderPolicy.form.cors.originPlaceholder"),helperText:b("responseHeaderPolicy.form.cors.originHelperText"),value:_.origin.value,onChange:f=>{m("origin",{value:f.target.value})}})})},{title:b("responseHeaderPolicy.form.cors.methods"),name:"methods",override:_.methods.override,required:!0,value:_.methods.value,content:e.jsx(Fe,{sx:{flexDirection:"row"},children:R.map(f=>e.jsx(K,{control:e.jsx(Te,{size:"small",disabled:$,checked:_.methods.value.includes(f),onChange:(h,t)=>{m("methods",{value:t?[..._.methods.value,f]:_.methods.value.filter(l=>l!==f)})}}),label:f},f))})},{title:b("responseHeaderPolicy.form.cors.allowedHeaders"),override:_.allowedHeaders.override,name:"allowedHeaders",value:_.allowedHeaders.value,content:e.jsx(G,{fullWidth:!0,sx:{mt:.75,"& .MuiFormHelperText-root":{mx:0}},children:e.jsx(U,{multiline:!0,minRows:3,maxRows:7,disabled:$,variant:"outlined",size:"small",placeholder:b("responseHeaderPolicy.form.cors.allowedHeadersPlaceholder"),helperText:b("responseHeaderPolicy.form.cors.allowedHeadersHelperText"),value:_.allowedHeaders.value,onChange:f=>{m("allowedHeaders",{value:f.target.value})}})})},{title:b("responseHeaderPolicy.form.cors.exposedHeaders"),override:_.exposedHeaders.override,name:"exposedHeaders",value:_.exposedHeaders.value,content:e.jsx(G,{fullWidth:!0,sx:{mt:.75,"& .MuiFormHelperText-root":{mx:0}},children:e.jsx(U,{multiline:!0,minRows:3,maxRows:7,disabled:$,variant:"outlined",size:"small",placeholder:b("responseHeaderPolicy.form.cors.exposedHeadersPlaceholder"),helperText:b("responseHeaderPolicy.form.cors.exposedHeadersHelperText"),value:_.exposedHeaders.value,onChange:f=>{m("exposedHeaders",{value:f.target.value})}})})},{title:b("responseHeaderPolicy.form.cors.maxAge"),override:_.maxAge.override,name:"maxAge",value:_.maxAge.value,content:e.jsx(G,{fullWidth:!0,sx:{mt:.75,"& .MuiFormHelperText-root":{mx:0}},children:e.jsx(U,{type:"number",variant:"outlined",size:"small",disabled:$,value:_.maxAge.value,onChange:f=>{m("maxAge",{value:f.target.value})},helperText:b("responseHeaderPolicy.form.cors.maxAgeHelperText")})})},{title:b("responseHeaderPolicy.form.cors.optionsSuccessStatus"),override:_.optionsSuccessStatus.override,name:"optionsSuccessStatus",value:_.optionsSuccessStatus.value,content:e.jsx(G,{fullWidth:!0,sx:{mt:.75,"& .MuiFormHelperText-root":{mx:0}},children:e.jsx(U,{type:"number",variant:"outlined",size:"small",disabled:$,value:_.optionsSuccessStatus.value,onChange:f=>{m("optionsSuccessStatus",{value:f.target.value})}})})},{title:b("responseHeaderPolicy.form.cors.preflightContinue"),override:_.preflightContinue.override,name:"preflightContinue",value:_.preflightContinue.value,control:e.jsx(pe,{size:"small",disabled:$,checked:_.preflightContinue.value,onChange:(f,h)=>{m("preflightContinue",{value:h})}})},{title:b("responseHeaderPolicy.form.cors.credentials"),override:_.credentials.override,name:"credentials",value:_.credentials.value,control:e.jsx(pe,{size:"small",disabled:$,checked:_.credentials.value,onChange:(f,h)=>{m("credentials",{value:h})}})}];Gt(()=>{C(_)});const p={".PrivateSwitchBase-input+svg":{fontSize:"1rem"},".MuiCheckbox-sizeSmall":{p:.75},".MuiFormControlLabel-label":{fontSize:"0.8rem"}};return e.jsx(Fe,{children:r.map((f,h)=>e.jsxs(L.Fragment,{children:[e.jsxs(A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[e.jsx(K,{sx:{mt:h===0?0:1},control:f.control||e.jsx(A,{sx:{pl:1.35}}),label:f.title,required:f.required},`${f.name}_form`),e.jsxs(A,{children:[f.name==="origin"?e.jsx(K,{control:e.jsx(Te,{size:"small",checked:f.smart,color:"primary",disabled:$,onChange:()=>{m(f.name,{smart:!f.smart})}}),label:e.jsxs(e.Fragment,{children:[b("responseHeaderPolicy.form.cors.smartMode"),e.jsx(X,{title:b("responseHeaderPolicy.form.cors.smartModeHelperText"),children:e.jsx(A,{component:Q,icon:ut,sx:{cursor:"pointer",color:"grey",ml:.5,fontSize:"1.1em"}})})]}),sx:p},`${f.name}_smart`):null,e.jsx(K,{control:e.jsx(Te,{size:"small",checked:f.override,color:"warning",disabled:$,onChange:()=>{m(f.name,{override:!f.override})}}),label:e.jsxs(e.Fragment,{children:[b("responseHeaderPolicy.form.originOverride"),e.jsx(X,{title:b("responseHeaderPolicy.form.originOverrideHelperText"),children:e.jsx(A,{component:Q,icon:ut,sx:{cursor:"pointer",color:"grey",ml:.5,fontSize:"1.1em"}})})]}),sx:{...p,mr:0}},`${f.name}_override`)]})]}),f.content?e.jsx(A,{sx:{ml:3.5},children:f.content},`${f.name}_content`):null]},f.name))})}ks.propTypes={config:T.object,onChange:T.func,disabled:T.bool};function Ss({value:x,onChange:C=()=>{},disabled:$=!1}){const R="sameorigin",_=[{label:"DENY",value:"deny"},{label:"SAMEORIGIN (default)",value:"sameorigin"}],b=m=>{C({action:m.target.value})};return L.useEffect(()=>{x===!0&&C({action:R})},[x]),e.jsx(A,{children:e.jsx(G,{children:e.jsx(Xt,{row:!0,children:_.map(m=>e.jsx(K,{value:m.value,control:e.jsx(Qt,{size:"small",disabled:$,checked:m.value===x?.action,onChange:b,sx:{p:.75}}),label:m.label},m.value))})})})}Ss.propTypes={value:T.oneOfType([T.string,T.bool]).isRequired,onChange:T.func,disabled:T.bool};function Cs({value:x,onChange:C=()=>{},disabled:$=!1}){const R="strict-origin-when-cross-origin",_=[{label:"no-referrer",value:"no-referrer"},{label:"no-referrer-when-downgrade",value:"no-referrer-when-downgrade"},{label:"origin",value:"origin"},{label:"origin-when-cross-origin",value:"origin-when-cross-origin"},{label:"same-origin",value:"same-origin"},{label:"strict-origin",value:"strict-origin"},{label:"strict-origin-when-cross-origin (default)",value:"strict-origin-when-cross-origin"},{label:"unsafe-url",value:"unsafe-url"}],b=m=>{C({policy:m.target.value})};return L.useEffect(()=>{x===!0&&C({policy:R})},[x]),e.jsx(A,{children:e.jsx(G,{children:e.jsx(Xt,{children:_.map(m=>e.jsx(K,{value:m.value,control:e.jsx(Qt,{size:"small",disabled:$,checked:m.value===x?.policy,onChange:b,sx:{p:.75}}),label:m.label},m.value))})})})}Cs.propTypes={value:T.oneOfType([T.string,T.bool]).isRequired,onChange:T.func,disabled:T.func};function Rs({value:x,onChange:C=()=>{},disabled:$=!1}){const R={"default-src":["'self'"],"base-uri":["'self'"],"font-src":["'self'","https:","data:"],"form-action":["'self'"],"frame-ancestors":["'self'"],"img-src":["'self'","data:"],"object-src":["'none'"],"script-src":["'self'"],"script-src-attr":["'none'"],"style-src":["'self'","https:","'unsafe-inline'"],"upgrade-insecure-requests":[]};function _(f){return Object.keys(f).map(h=>[h,f[h].filter(Boolean).join(" ")].filter(Boolean).join(" ")).filter(Boolean).join(`
|
|
143
|
-
`)}const b=_(x?.directives||R),[m,r]=L.useState(b),p=f=>{r(f.target.value);const h=f.target.value.split(`
|
|
144
|
-
`).reduce((t,l)=>{const[o,...n]=l.split(" ");return t[o]=n.filter(s=>s!==""),t},{});C({useDefaults:!1,directives:h})};return L.useEffect(()=>{x===!0&&(C({useDefaults:!1,directives:R}),r(_(R)))},[x]),e.jsx(A,{sx:{mt:1},children:e.jsx(G,{fullWidth:!0,children:e.jsx(U,{fullWidth:!0,multiline:!0,disabled:$,rows:12,size:"small",value:m,onChange:p})})})}Rs.propTypes={value:T.oneOfType([T.object,T.bool]).isRequired,onChange:T.func,disabled:T.bool};function $s({config:x={},onChange:C=()=>{},disabled:$=!1}){const R={contentSecurityPolicy:{override:!1,value:!1},referrerPolicy:{override:!1,value:!1},xFrameOptions:{override:!1,value:!1},xPoweredBy:{override:!1,value:!0},xXssProtection:{override:!1,value:!1},...Kt(x,we)},{t:_}=ae(),b=(p,{override:f,value:h})=>{const t={...R?.[p]};we(f)||(t.override=f),we(h)||(t.value=h),C({...R,[p]:t})},m=[{title:"Content-Security-Policy",name:"contentSecurityPolicy",override:R.contentSecurityPolicy.override,value:!!R.contentSecurityPolicy.value,content:e.jsx(Rs,{disabled:$,value:R.contentSecurityPolicy.value,onChange:p=>{b("contentSecurityPolicy",{value:p})}}),onChange(p){b("contentSecurityPolicy",{value:p})}},{title:"Referrer-Policy",name:"referrerPolicy",override:R.referrerPolicy.override,value:!!R.referrerPolicy.value,content:e.jsx(Cs,{disabled:$,value:R.referrerPolicy.value,onChange:p=>{b("referrerPolicy",{value:p})}}),onChange(p){b("referrerPolicy",{value:p})}},{title:"X-Frame-Options",name:"xFrameOptions",override:R.xFrameOptions.override,value:!!R.xFrameOptions.value,content:e.jsx(Ss,{disabled:$,value:R.xFrameOptions.value,onChange:p=>{b("xFrameOptions",{value:p})}}),onChange(p){b("xFrameOptions",{value:p})}},{title:"Disable X-Powered-By",name:"xPoweredBy",override:R.xPoweredBy.override,value:R.xPoweredBy.value,content:null,onChange(p){b("xPoweredBy",{value:p})}},{title:"X-XSS-Protection",name:"xXssProtection",override:R.xXssProtection.override,value:R.xXssProtection.value,content:null,onChange(p){b("xXssProtection",{value:p})}}];Gt(()=>{C(R)});const r={".PrivateSwitchBase-input+svg":{fontSize:"1rem"},".MuiCheckbox-sizeSmall":{p:.75},".MuiFormControlLabel-label":{fontSize:"0.8rem"}};return e.jsx(Fe,{children:m.map((p,f)=>e.jsxs(L.Fragment,{children:[e.jsxs(A,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[e.jsx(K,{sx:{mt:f===0?0:1},control:e.jsx(pe,{size:"small",disabled:$,checked:p.value,onChange:()=>{p.onChange(!p.value)}},`${p.name}_switch`),label:p.title},`${p.name}_form`),p.value?e.jsx(K,{control:e.jsx(Te,{size:"small",checked:p.override,color:"warning",disabled:$,onChange:()=>{b(p.name,{override:!p.override})}}),label:e.jsxs(e.Fragment,{children:[_("responseHeaderPolicy.form.originOverride"),e.jsx(X,{title:_("responseHeaderPolicy.form.originOverrideHelperText"),children:e.jsx(A,{component:Q,icon:ut,sx:{cursor:"pointer",color:"grey",ml:.5,fontSize:"1.1em"}})})]}),sx:{...r,mr:0}}):null]}),p.value&&p.content?e.jsx(A,{sx:{ml:3.7},children:p.content},`${p.name}_content`):null]},p.name))})}$s.propTypes={config:T.object,onChange:T.func,disabled:T.bool};function As({ref:x=null}){const{t:C}=L.useContext(ue),R=$e()?.transitions?.duration?.leavingScreen||300,_=ye({mode:"add",show:!1,callback:ce,get dialogTitle(){return this.mode==="edit"?C("responseHeaderPolicy.edit"):this.mode==="view"?C("responseHeaderPolicy.view"):C("responseHeaderPolicy.add")},cors:null,securityHeader:null,enableCORS:!1}),{handleSubmit:b,control:m,setValue:r,reset:p,formState:{errors:f}}=xe({mode:"onChange",defaultValues:{name:"",description:""}}),h=E(()=>{p(),_.mode="add",_.enableCORS=!1,_.cors=null,_.securityHeader=null}),t=E(()=>{_.show=!1,setTimeout(()=>{h()},R)}),l=E((i=ce,u=null)=>{_.callback=i,_.show=!0,u&&(u.id?_.mode="edit":_.mode="view",r("name",u.name),r("description",u.description),_.cors=Jn(u.cors),_.securityHeader=Gn(u.securityHeader),_.enableCORS=!!u.cors)});L.useImperativeHandle(x,()=>({open:l,close:t}),[l,t]);const o=_.mode==="view",n=E(i=>{const u=Kn(_.cors),g=Yn(_.securityHeader),y=Wt({...i,cors:_.enableCORS?JSON.stringify(u):null,securityHeader:JSON.stringify(g)});_.callback(y,t)}),s=E(i=>i?.trim()?!0:C("common.requiredErrorText",{name:C("accessPolicy.form.name")})),c=i=>{_.securityHeader=i},a=i=>{_.cors=i};return e.jsx(ke,{open:_.show,title:_.dialogTitle,onClose:t,PaperProps:{style:{minHeight:"unset",width:900,maxWidth:"100%"}},actions:e.jsx(te,{color:"primary",autoFocus:!0,variant:"contained",onClick:b(n),children:C("common.confirm")}),children:e.jsxs("form",{noValidate:!0,autoComplete:"off",children:[e.jsx(H,{name:"name",control:m,rules:{validate:s},render:({field:i})=>e.jsx(U,{fullWidth:!0,required:!0,size:"small",margin:"dense",disabled:o,placeholder:C("accessPolicy.form.namePlaceholder"),label:C("accessPolicy.form.name"),error:!!f?.name?.message,helperText:f?.name?.message||" ",...i})}),e.jsx(H,{name:"description",control:m,render:({field:i})=>e.jsx(U,{fullWidth:!0,multiline:!0,size:"small",margin:"dense",disabled:o,minRows:3,maxRows:7,placeholder:"Description",label:"Description",helperText:f?.description?.message||" ",...i})}),e.jsx(dt,{title:"Cross-origin resource sharing (CORS)",value:_.enableCORS,onChange:i=>{o||(_.enableCORS=i)},showExpand:!1,actions:e.jsx(pe,{size:"small",disabled:o,checked:_.enableCORS}),children:e.jsx(ks,{config:_.cors,onChange:a,disabled:o})}),e.jsx("br",{}),e.jsx(dt,{title:"Security Headers",children:e.jsx($s,{config:_.securityHeader,onChange:c,disabled:o})})]})})}As.propTypes={ref:T.any};function ta(){const{t:x,locale:C}=ae(),{blocklet:$}=oe(),{api:R}=re(),_=$?.meta?.did,b=L.useRef(null),m=L.useRef(null),{confirmApi:r,confirmHolder:p}=Ze(),f=()=>{},h=ze(async()=>{const{responseHeaderPolicies:u}=await R.getBlockletResponseHeaderPolicies({input:{did:_}});return Be(u.map(g=>Xn(g)),g=>g.isProtected?1:0)}),t=h.data||[],l=E(()=>{b.current.open((u,g)=>{fe(async()=>{await R.addBlockletResponseHeaderPolicy({input:{did:_,data:u}}),Z.success(x("common.succeeded")),h.run(),g()})})}),o=E(u=>{b.current.open((g,y)=>{y()},Ce(u,["id"]))}),n=E(u=>{b.current.open((g,y)=>{fe(async()=>{await R.updateBlockletResponseHeaderPolicy({input:{did:_,data:{...g,id:u.id}}}),Z.success(x("common.succeeded")),h.run(),y()})},u)}),s=E(u=>{r.open({title:x("responseHeaderPolicy.delete.title"),content:x("responseHeaderPolicy.delete.description"),confirmButtonText:x("common.confirm"),confirmButtonProps:{color:"error"},cancelButtonText:x("common.cancel"),onConfirm(g){fe(async()=>{await R.deleteBlockletResponseHeaderPolicy({input:{did:_,id:u.id}}),Z.success(x("common.succeeded")),h.run(),g()})}})}),c={sort:!1,download:!1,filter:!1,print:!1,search:!1,viewColumns:!1,expandableRowsOnClick:!0,searchDebounceTime:600,onRowClick(u,{dataIndex:g},y){if(m.current?.contains(y.target)){const k=t[g];o(k)}}},a=[e.jsx(Y,{size:"small",variant:"outlined",onClick:()=>{h.run()},sx:{mr:1},children:x("common.refresh")},"refresh"),e.jsx(Y,{size:"small",variant:"contained",onClick:l,children:x("common.add")},"add")],i=[{label:x("common.name"),name:"name",options:{customBodyRenderLite(u){const g=t[u],y=g.isProtected?e.jsx(X,{title:"Built-in policy, can't edit",children:e.jsx(A,{component:Q,icon:Jt,sx:{fontSize:16}})}):null;return e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:.5},children:[y," ",g.name]})}}},{label:x("common.description"),name:"description"},{label:x("common.actions"),name:"",width:100,align:"center",verticalKeyAlign:"center",options:{customBodyRenderLite(u){const g=t[u];return e.jsxs(A,{sx:{display:"flex",alignItems:"center",gap:0},onClick:y=>y.stopPropagation(),children:[g.isProtected?e.jsx(X,{title:x("common.view"),children:e.jsx(ne,{size:"small",onClick:()=>{o(g,u)},children:e.jsx(Q,{icon:xs,fontSize:18})})}):null,g.isProtected?null:e.jsx(X,{title:x("common.edit"),children:e.jsx(ne,{size:"small",onClick:()=>{n(g,u)},color:"success",children:e.jsx(Q,{icon:_t,fontSize:18})})}),g.isProtected?null:e.jsx(X,{title:x("common.delete"),children:e.jsx(ne,{size:"small",onClick:()=>{s(g,u)},color:"error",children:e.jsx(Q,{icon:jt,fontSize:18})})})]})}}}].filter(Boolean);return e.jsxs(A,{sx:{display:"flex",flexDirection:"column",gap:2},ref:m,children:[e.jsx(Ue,{verticalKeyWidth:100,locale:C,title:x("responseHeaderPolicy.title"),data:t,columns:i,customButtons:a,options:c,loading:h.loading,onChange:f}),e.jsx(As,{ref:b}),p]})}const Os=({tabs:x,blocklet:C,ancestors:$=[],depth:R=1,t:_})=>{const b=[...$.map(r=>r.meta.did),C.meta.did].join("/"),m=!$?.length;x.push({label:e.jsxs(A,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-start",pl:Math.max(1,R-1)*2},children:[m?e.jsx(mr,{size:24,blocklet:C,style:{borderRadius:0}}):e.jsx(pr,{size:24,blocklet:C,ancestors:$,style:{borderRadius:0}}),e.jsx(A,{sx:{ml:2},children:e.jsx(A,{sx:{color:"text.primary"},children:m?_("blocklet.component.container"):Nt.getDisplayName(C,!0)})})]},b),value:b}),C.children.length>0&&C.children.forEach(r=>{Os({tabs:x,blocklet:r,ancestors:[...$,C],depth:R+1,t:_})})};function sa({blocklet:x,onUpdate:C=()=>{},...$}){const{t:R}=ae(),_=ye({expandPref:!0,expandSecurity:!0}),[b,m]=ur(),r=b.get("tab")||"general",p=es(),[f,h]=L.useState(!1),t=[];t.push({label:e.jsxs(A,{"data-cy":"configuration-tab-general",sx:{display:"flex",alignItems:"center"},children:[e.jsx(Yr,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("common.general")})]},"general"),value:"general"}),t.push({label:e.jsxs(A,{"data-cy":"configuration-tab-security-group",sx:{display:"flex",alignItems:"center"},children:[e.jsx(A,{sx:{ml:-2,transform:"translateY(2px)"},children:_.expandSecurity?e.jsx(Rt,{fontSize:"inherit"}):e.jsx($t,{fontSize:"inherit"})}),e.jsx(lt,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("common.security")})]},"securityGroup"),value:"securityGroup"}),_.expandSecurity&&(t.push({label:e.jsxs(A,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-start",pl:2},children:[e.jsx(lt,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("securityRule.title")})]},"security"),value:"security"}),t.push({label:e.jsxs(A,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-start",pl:2},children:[e.jsx(Ur,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("accessPolicy.title")})]},"accessPolicy"),value:"accessPolicy"}),t.push({label:e.jsxs(A,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-start",pl:2},children:[e.jsx(Q,{fontSize:24,style:{flexShrink:0},icon:rn}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("responseHeaderPolicy.title")})]},"responseHeaderPolicy"),value:"responseHeaderPolicy"})),t.push({label:e.jsxs(A,{sx:{display:"flex",alignItems:"center"},"data-cy":"configuration-tab-authentication",children:[e.jsx(Kr,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("common.login")})]},"authentication"),value:"authentication"}),t.push({label:e.jsxs(A,{"data-cy":"configuration-tab-notification",sx:{display:"flex",alignItems:"center"},children:[e.jsx(Gr,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("common.notification")})]},"notification"),value:"notification"}),t.push({label:e.jsxs(A,{"data-cy":"configuration-tab-preference",sx:{display:"flex",alignItems:"center"},children:[e.jsx(A,{sx:{ml:-2,transform:"translateY(2px)"},children:_.expandPref?e.jsx(Rt,{fontSize:"inherit"}):e.jsx($t,{fontSize:"inherit"})}),e.jsx(xr,{sx:{fontSize:24}}),e.jsx(A,{sx:{ml:2,color:"text.primary"},children:R("common.preferences")})]},"preference"),value:"preference"});const l=t.find(c=>c.value===r);_.expandPref&&Os({tabs:t,blocklet:x,t:R});const o=c=>{c==="preference"?_.expandPref=!_.expandPref:c==="securityGroup"?_.expandSecurity=!_.expandSecurity:m(a=>(c==="general"?a.delete("tab"):a.set("tab",c),a)),h(!1)};let n=null;r==="general"?n=e.jsx(Sn,{blocklet:x,onUpdate:C}):r==="security"?n=e.jsx(Un,{}):r==="accessPolicy"?n=e.jsx(Qn,{}):r==="responseHeaderPolicy"?n=e.jsx(ta,{}):r==="authentication"?n=e.jsx(gs,{}):r==="notification"?n=e.jsx(Tr,{}):n=e.jsx(br,{id:r});const s=L.useMemo(()=>({position:"relative",minHeight:"66vh",height:"100%",overflow:"hidden"}),[]);return e.jsxs(ra,{...$,children:[p&&e.jsxs(e.Fragment,{children:[e.jsxs(A,{sx:{color:"primary.main",position:"sticky",top:0,zIndex:2,bgcolor:"background.default",display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[e.jsx(ne,{onClick:()=>h(!0),sx:{mr:1},children:e.jsx(hr,{})}),e.jsx(A,{children:l?.label})]}),e.jsx(fr,{anchor:"left",open:f,onClose:()=>h(!1),slotProps:{paper:{sx:{width:260,".MuiTab-root":{textAlign:"left",alignItems:"flex-start",fontWeight:"normal"}}}},children:e.jsx(Ne,{tabs:t,current:r,orientation:"vertical",onChange:o,sx:{borderRight:1,height:"100%",borderColor:"divider"}})})]}),e.jsxs(Ke,{container:!0,spacing:4,columns:24,children:[!p&&e.jsx(Ke,{size:{xs:24,sm:7,md:5},children:e.jsx(Ne,{tabs:t,current:r,orientation:"vertical",onChange:o,sx:{borderRight:1,height:"100%",borderColor:"divider"}})}),e.jsx(Ke,{size:{xs:24,sm:17,md:19},children:e.jsx(A,{style:s,children:n})})]})]})}sa.propTypes={blocklet:T.object.isRequired,onUpdate:T.func};const ra=ve.div`
|
|
145
|
-
.MuiTab-root {
|
|
146
|
-
text-align: left;
|
|
147
|
-
align-items: flex-start;
|
|
148
|
-
font-weight: normal;
|
|
149
|
-
}
|
|
150
|
-
.Mui-selected {
|
|
151
|
-
font-weight: bold;
|
|
152
|
-
}
|
|
153
|
-
`;export{sa as default};
|