@abtnode/webapp 1.17.3-beta-20251128-095123-a76cb6bc → 1.17.4-beta-20251201-095907-eebbbbce
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-jQWZxlKZ.js → AdapterDayjs-DFNTS6uL.js} +1 -1
- package/dist/assets/{Add-CM0i44L2.js → Add-DMoAJUVW.js} +1 -1
- package/dist/assets/ArrowDropDown-BS1FI8Dx.js +1 -0
- package/dist/assets/{Autocomplete-BBHR-e2e.js → Autocomplete-DzPelkmw.js} +1 -1
- package/dist/assets/{Breadcrumbs-BaZ8MiUq.js → Breadcrumbs-4tdPlLhJ.js} +1 -1
- package/dist/assets/{ButtonGroup-B_6MNBFc.js → ButtonGroup-Dlkb94HL.js} +1 -1
- package/dist/assets/{CSSTransition-C6uS6QtZ.js → CSSTransition-Cp9IAg_E.js} +1 -1
- package/dist/assets/{CallMerge-CQP5GPxe.js → CallMerge-B41lkD5_.js} +1 -1
- package/dist/assets/{CardContent-Ck7ja9MC.js → CardContent-yvDYaO_0.js} +1 -1
- package/dist/assets/{ChevronLeft-C7cSHp9l.js → ChevronLeft-CZ7VDJCP.js} +1 -1
- package/dist/assets/{ChevronRight-BUUZmp3v.js → ChevronRight-W_01-zFQ.js} +1 -1
- package/dist/assets/{Clear-CFi5u92e.js → Clear-3aQ_ViuO.js} +1 -1
- package/dist/assets/{DeleteOutline-BHEKXTkO.js → DeleteOutline-CduYjOSi.js} +1 -1
- package/dist/assets/{Done-DXPJGUWm.js → Done-D_cfJoKY.js} +1 -1
- package/dist/assets/{Edit-JIlB-sRA.js → Edit-CAoHCh26.js} +1 -1
- package/dist/assets/{ErrorOutline-DBqK27X8.js → ErrorOutline-ClBFY-zS.js} +1 -1
- package/dist/assets/{FilterList-DqZHJbRG.js → FilterList-CoyfX8VL.js} +1 -1
- package/dist/assets/{Google-KJc6rb0J.js → Google-QOJseWnL.js} +1 -1
- package/dist/assets/{HelpOutline-DswUhBxG.js → HelpOutline-DNkRe_xv.js} +1 -1
- package/dist/assets/{KeyboardArrowDown-BRIRZ0lk.js → KeyboardArrowDown-DACNodoq.js} +1 -1
- package/dist/assets/{Launch-_uZBB3hy.js → Launch-BOUgHkwm.js} +1 -1
- package/dist/assets/{Link-CvXyobEJ.js → Link-BFLUKKmj.js} +1 -1
- package/dist/assets/{ListItemButton-BRQYff97.js → ListItemButton-BrJjYcfY.js} +1 -1
- package/dist/assets/{ListSubheader-BHGxSe1E.js → ListSubheader-Dz5YbKqQ.js} +1 -1
- package/dist/assets/{LoadingButton-BhZ8iOtK.js → LoadingButton-DSQ0SJvD.js} +1 -1
- package/dist/assets/{MoreVert-Ck4O28kx.js → MoreVert-Crfla2Nw.js} +1 -1
- package/dist/assets/{OpenInNew-BJk7hIVB.js → OpenInNew-CMikwXJg.js} +1 -1
- package/dist/assets/{Refresh-kyiL1qX1.js → Refresh-BRw0lNlx.js} +1 -1
- package/dist/assets/{Search-BiQ8hlgr.js → Search-DihRAr8J.js} +1 -1
- package/dist/assets/{Stepper-BJZfb2Le.js → Stepper-DSYfudJh.js} +1 -1
- package/dist/assets/{Switch-UORzToTA.js → Switch-DXK3jQx6.js} +1 -1
- package/dist/assets/{TableSearch-BQiqRB7D.js → TableSearch-DTa-kQYq.js} +1 -1
- package/dist/assets/{ToggleButtonGroup-CbzWaH4A.js → ToggleButtonGroup-BgcjoBhH.js} +1 -1
- package/dist/assets/{UnfoldMore-DZ3laWH7.js → UnfoldMore-Obeukjjc.js} +1 -1
- package/dist/assets/{Verified-M-1m4RTW.js → Verified-BkNsmE5y.js} +1 -1
- package/dist/assets/{VerifiedUser-C7mhQBkH.js → VerifiedUser-DF0KlG8V.js} +1 -1
- package/dist/assets/{ViewList-DC04kVZ7.js → ViewList-Dsx5HTn1.js} +1 -1
- package/dist/assets/{_createAggregator-BcN4GRYz.js → _createAggregator-ysrcf9Bc.js} +1 -1
- package/dist/assets/{actions-DSVBY-iK.js → actions-B68pZ6f6.js} +1 -1
- package/dist/assets/{actions-e0cgLZ3F.js → actions-BQYoCyzD.js} +1 -1
- package/dist/assets/{agreement-CMStdtDl.js → agreement-3umjEU1n.js} +1 -1
- package/dist/assets/api-DtECYdKn.js +1 -0
- package/dist/assets/{appearance-BbYVAqwM.js → appearance-BYqWOedE.js} +1 -1
- package/dist/assets/{audit-logs-B2Hvy3ws.js → audit-logs-C8Rj-VnC.js} +1 -1
- package/dist/assets/{base-chart-Do9WtdQs.js → base-chart-C7SG2Os5.js} +1 -1
- package/dist/assets/{blocklet-Cu8go6Cl.js → blocklet-BwZNRhqB.js} +1 -1
- package/dist/assets/{chain-tpP2d9Lm.js → chain-BLr2de5j.js} +1 -1
- package/dist/assets/{click-to-copy-BpBPaRWz.js → click-to-copy-_XuYTLfd.js} +1 -1
- package/dist/assets/cloneDeep-9Rjs5zfn.js +1 -0
- package/dist/assets/{collapse-DRRC0SCd.js → collapse-C4RswaYj.js} +1 -1
- package/dist/assets/{config-navigation-Ntc_O8HF.js → config-navigation-m1HAHHAI.js} +3 -3
- package/dist/assets/{connect-to-CTjQfAN3.js → connect-to-CQeSm0MO.js} +1 -1
- package/dist/assets/{cssMode-MKOimR8r.js → cssMode-CMNPagen.js} +1 -1
- package/dist/assets/{delete-confirm-DwwucGed.js → delete-confirm-B3AhdXCf.js} +1 -1
- package/dist/assets/{depsEqual-DJ4V1mTU.js → depsEqual-C1JyiMkY.js} +1 -1
- package/dist/assets/{detail-BAwVCAFb.js → detail-C3pyFMHM.js} +3 -3
- package/dist/assets/{domains-rlp68m61.js → domains-DIeIwNFc.js} +1 -1
- package/dist/assets/{download-CizjGT3a.js → download-PFug1xLJ.js} +1 -1
- package/dist/assets/{edit.svg-CpLTrX1j.js → edit.svg-BWsZcaur.js} +1 -1
- package/dist/assets/emotion-cache.browser.esm-DR87qH_k.js +1 -0
- package/dist/assets/engine-XiroAPK-.js +1 -0
- package/dist/assets/{freemarker2-dI1M-X6u.js → freemarker2-D3LU0XC5.js} +1 -1
- package/dist/assets/{get-safe-url-CHuz2b-I.js → get-safe-url-B8fUDSaQ.js} +1 -1
- package/dist/assets/getValidReactChildren-Dxx0sUSA.js +1 -0
- package/dist/assets/{graphqlMode-B_WmUdLw.js → graphqlMode-CZh0WEg3.js} +2 -2
- package/dist/assets/{handlebars-CRMti49n.js → handlebars-BoyJQaGG.js} +1 -1
- package/dist/assets/{html-ermJICEG.js → html-DiNtivy_.js} +1 -1
- package/dist/assets/{html-title-BQwqe1Ck.js → html-title-DZPr9ErN.js} +1 -1
- package/dist/assets/{htmlMode-B0bBi3DI.js → htmlMode-swm5QVbw.js} +1 -1
- package/dist/assets/{iframe-9SAgwJDT.js → iframe-DloJgn9Q.js} +1 -1
- package/dist/assets/{index-BGQR0TyN.js → index-1u2jtyuS.js} +1 -1
- package/dist/assets/{index-DuqULJQe.js → index-2MD_vALi.js} +1 -1
- package/dist/assets/{index-CcHEbeR3.js → index-B-t0c3Sa.js} +1 -1
- package/dist/assets/{index-D1jZ55Sb.js → index-B0J8LV_Q.js} +1 -1
- package/dist/assets/{index-mI9L2BhQ.js → index-BBE5QVnT.js} +1 -1
- package/dist/assets/{index-CNd2lEI7.js → index-BNSnUR0A.js} +1 -1
- package/dist/assets/{index-Bkx9VtR1.js → index-BOgaS_mp.js} +3 -3
- package/dist/assets/{index-CeI21XVA.js → index-BPL2xXU0.js} +1 -1
- package/dist/assets/{index-CBDLDE06.js → index-BScjYdDP.js} +3 -3
- package/dist/assets/{index-C3PPN1sd.js → index-B_irEVal.js} +1 -1
- package/dist/assets/{index-CTialFzy.js → index-BiECtx8f.js} +1 -1
- package/dist/assets/{index-DtnSIrsF.js → index-BktUsUuI.js} +1 -1
- package/dist/assets/{index-DcBZKU5L.js → index-BoLEbVjY.js} +1 -1
- package/dist/assets/{index-Dz_Rmjb-.js → index-BpTQAo8p.js} +1 -1
- package/dist/assets/{index-B6xNHlEj.js → index-BsUgU8Em.js} +3 -3
- package/dist/assets/{index-IfVDnuZk.js → index-C1n8OjtU.js} +1 -1
- package/dist/assets/{index-D9QeG2FZ.js → index-C6qm0jMc.js} +1 -1
- package/dist/assets/{index-zysAnh52.js → index-CCqeWXbH.js} +2 -2
- package/dist/assets/{index-yXEFoIGg.js → index-CI77BW6M.js} +1 -1
- package/dist/assets/{index-D6WMVz-u.js → index-CIJ5EXA3.js} +1 -1
- package/dist/assets/{index-BR8r-K4S.js → index-CKHzfPKz.js} +1 -1
- package/dist/assets/{index-CmgnJ9Ac.js → index-CSzOTG6W.js} +9 -9
- package/dist/assets/{index-DO977Avs.js → index-C_lSg5BT.js} +1 -1
- package/dist/assets/index-ClIHkf52.js +1 -0
- package/dist/assets/{index-BkBk9uDM.js → index-ClciYnBs.js} +1 -1
- package/dist/assets/{index-BC4-BsXp.js → index-Cm4YjlwL.js} +1 -1
- package/dist/assets/{index-CCDLY5yo.js → index-CqjL56RL.js} +1 -1
- package/dist/assets/{index-BNQ03H5g.js → index-Cwj1cT7X.js} +1 -1
- package/dist/assets/{index-2c1VoOd9.js → index-DN1FR838.js} +3 -3
- package/dist/assets/{index-CeMW5u5M.js → index-DS6pTkmU.js} +1 -1
- package/dist/assets/{index-C34tPvay.js → index-DW37Hc5m.js} +1 -1
- package/dist/assets/{index-DtbxvdaD.js → index-D_Ja8zFw.js} +1 -1
- package/dist/assets/{index-DCmGZYYq.js → index-D_vvbtGZ.js} +1 -1
- package/dist/assets/{index-D-Q5yWhn.js → index-DalOLs5N.js} +1 -1
- package/dist/assets/{index-CuNku1ac.js → index-Dcx5YP4F.js} +1 -1
- package/dist/assets/{index-OJESZDQE.js → index-Dosi9lN2.js} +1 -1
- package/dist/assets/{index-CZVLqYhR.js → index-DtEm4DlR.js} +1 -1
- package/dist/assets/{index-DUpNrHpg.js → index-DzIQue5G.js} +1 -1
- package/dist/assets/{index-vpxPTR3F.js → index-DzMTdOui.js} +1 -1
- package/dist/assets/{index-EhtXyCtH.js → index-EO1T3ubZ.js} +1 -1
- package/dist/assets/{index-DF8exUsL.js → index-PexLSZpT.js} +1 -1
- package/dist/assets/index-UxFoihcG.js +606 -0
- package/dist/assets/{index-DGZbMOLi.js → index-aZK5B1rf.js} +1 -1
- package/dist/assets/{index-DOFLIkPm.js → index-aiY7k_D_.js} +1 -1
- package/dist/assets/{index-n0Dm2HUt.js → index-oVsaWj9v.js} +1 -1
- package/dist/assets/{index-gDj2o7RF.js → index-p4uzP6uF.js} +1 -1
- package/dist/assets/{index.esm-CgpVcU8p.js → index.esm-0qTLMRcM.js} +1 -1
- package/dist/assets/{install-from-url-jU_rZbjX.js → install-from-url-D4BZhujU.js} +1 -1
- package/dist/assets/{invitation-DX_ynvNX.js → invitation-7JPfzYsz.js} +1 -1
- package/dist/assets/{is-path-prefix-equal-VKe4yShn.js → is-path-prefix-equal-By5q4Tar.js} +1 -1
- package/dist/assets/{item-D0BOEDZA.js → item-BIq4iEQn.js} +1 -1
- package/dist/assets/{javascript-DCfUrb2b.js → javascript-B_b2FAHq.js} +1 -1
- package/dist/assets/{jsonMode-DflwradV.js → jsonMode-De4-g9Kb.js} +1 -1
- package/dist/assets/{liquid-v5CyzMO1.js → liquid-gACWVLj5.js} +1 -1
- package/dist/assets/{list-header-BsNw1q-X.js → list-header-DLDug_Pi.js} +1 -1
- package/dist/assets/{lock.svg-DcfL5WSZ.js → lock.svg-BzS6KpeB.js} +1 -1
- package/dist/assets/{log-v9e9l2M0.js → log-B-hBZSCU.js} +1 -1
- package/dist/assets/{lottie-react.esm-CCtixTZh.js → lottie-react.esm-CIMHKb6b.js} +1 -1
- package/dist/assets/{mdx-Ctxzc90y.js → mdx-QEop8_Eo.js} +1 -1
- package/dist/assets/{memory-BBW5cukR.js → memory-B3cgfihx.js} +1 -1
- package/dist/assets/{metric-gyu0g4Df.js → metric-Cof1oNBC.js} +1 -1
- package/dist/assets/omit-B3Qfr75J.js +1 -0
- package/dist/assets/{overview-CGezXNcq.js → overview-Bg8w97tG.js} +1 -1
- package/dist/assets/{permission-Dh9Y-pMK.js → permission-BFEhHSn7.js} +1 -1
- package/dist/assets/{preference-CSylIZyx.js → preference-BruWxN0I.js} +3 -3
- package/dist/assets/{python-OTBVRvfx.js → python-BjdcRw1L.js} +1 -1
- package/dist/assets/{raf-schd.esm-CeLqNu5n.js → raf-schd.esm-CzegtaBG.js} +1 -1
- package/dist/assets/{razor-Dz96HacP.js → razor-IcRt_b4C.js} +1 -1
- package/dist/assets/{rotate-session-key-sNZ4agRi.js → rotate-session-key-168u3XBv.js} +1 -1
- package/dist/assets/{runtime-44wcxPEo.js → runtime-_J5cuOkf.js} +1 -1
- package/dist/assets/schema-C7mAV9wx.js +1 -0
- package/dist/assets/sdk-Dn9cGqw6.js +1 -0
- package/dist/assets/{service-CrTKbt09.js → service-C07l8A9I.js} +1 -1
- package/dist/assets/{shorten-label-azqzn6Q0.js → shorten-label-lyN5fJdD.js} +1 -1
- package/dist/assets/{simple-select-Cjwynh2P.js → simple-select-DstcGmRv.js} +1 -1
- package/dist/assets/{spaces-CImRuKfl.js → spaces-DJOIEEkJ.js} +1 -1
- package/dist/assets/{status-BVLGfZ_U.js → status-DQyrCw3T.js} +1 -1
- package/dist/assets/{status-DqZQuuxT.js → status-DjHRNPcT.js} +1 -1
- package/dist/assets/{switch-control-uPmfeqt7.js → switch-control-BmkF4vyJ.js} +1 -1
- package/dist/assets/{table-icons-j1shPhg0.js → table-icons-GRr0eBoB.js} +1 -1
- package/dist/assets/{team-BOavcC7l.js → team-Dn5co06a.js} +1 -1
- package/dist/assets/{toLower-DFhqc1Tx.js → toLower-ysbVZcXo.js} +1 -1
- package/dist/assets/toUpper-B_tZoZUo.js +1 -0
- package/dist/assets/{traffic-Dk3MPYPo.js → traffic-DlmGH1wr.js} +1 -1
- package/dist/assets/{tsMode-DtrLBL88.js → tsMode-CApNVpTQ.js} +1 -1
- package/dist/assets/{typescript-B_jxVxfT.js → typescript-C-UJmhZH.js} +1 -1
- package/dist/assets/{url-evaluation-CKpb4hS-.js → url-evaluation-D0KhcJoH.js} +1 -1
- package/dist/assets/{url-join-_MGxS-GP.js → url-join-DF4J2tJs.js} +1 -1
- package/dist/assets/{use-mobile-CYJJmSLZ.js → use-mobile-BN298Cwf.js} +1 -1
- package/dist/assets/{use-mobile-DehCuxqg.js → use-mobile-BRO-uubG.js} +1 -1
- package/dist/assets/{useAsync-EJ0V06fl.js → useAsync-ihOYfxyw.js} +1 -1
- package/dist/assets/{useAsyncRetry-DTCkIRbI.js → useAsyncRetry-Bo43j2ED.js} +1 -1
- package/dist/assets/{useLocalStorage-C5c8IOKv.js → useLocalStorage-DdFQ0H8D.js} +1 -1
- package/dist/assets/{useThemeProps-Ddo6kYr5.js → useThemeProps-7IPePURq.js} +1 -1
- package/dist/assets/{util-CQYGkX3v.js → util-B8wHWVVx.js} +1 -1
- package/dist/assets/{wait-container-Dt2QEBDD.js → wait-container-CYtuj1LZ.js} +1 -1
- package/dist/assets/{without-wallet-DwaGUGcr.js → without-wallet-BBF6F6X8.js} +1 -1
- package/dist/assets/wrap-locale-C5FvK0v2.js +1 -0
- package/dist/assets/{xml-TYsadqlU.js → xml-CtHgzjfR.js} +1 -1
- package/dist/assets/{yaml-BeTZvw1b.js → yaml-UcfMMR9d.js} +1 -1
- package/dist/index.html +1 -1
- package/dist/service-worker.js +1 -1
- package/package.json +1 -1
- package/dist/assets/ArrowDropDown-BrtzEFq8.js +0 -1
- package/dist/assets/api-DxqoYz8S.js +0 -1
- package/dist/assets/cloneDeep-BAowUJcW.js +0 -1
- package/dist/assets/emotion-cache.browser.esm-BLI6o2QB.js +0 -1
- package/dist/assets/engine-d9ZSaCl8.js +0 -1
- package/dist/assets/getValidReactChildren-C8GIEouH.js +0 -1
- package/dist/assets/index-B0_NefDz.js +0 -1
- package/dist/assets/index-BVtHC_qD.js +0 -606
- package/dist/assets/omit-B1xspwKB.js +0 -1
- package/dist/assets/schema-DTRR0KGi.js +0 -1
- package/dist/assets/sdk-DH9OjvLO.js +0 -1
- package/dist/assets/toUpper-BIz-OTsX.js +0 -1
- package/dist/assets/wrap-locale-BSXSKo1t.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{aF as ks,j as t,aH as on,bn as Oe,bo as Ds,V as ye,N as Fe,r as Y,O as Bn,P as $n,S as Pn,Q as Un,K as $,bp as Nt,o as j,n as Bs,v as vn,C as $s,ac as yt,aV as Fn,t as Mn,bd as Ps,s as ve,Z as Us,bq as Be,br as Fs,bs as js,p as Ks,y as ze,$ as xt,aU as Hs,R as zs,at as Gs,H as Ws,m as Zs,bt as Sn,W as Ys,bu as At,bv as St,bw as Tt,bx as qs,i as Xs,T as Ue,by as Vs,ay as dt,a3 as gt,aR as pt,bk as Js,bz as Qs,U as ea,X as na,bA as ta,A as sa,u as aa,bm as ia,d as oa,bB as ra}from"./index-2c1VoOd9.js";import{u as ca,T as la}from"./html-title-BQwqe1Ck.js";import ua from"./audit-logs-B2Hvy3ws.js";import{T as Rt,M as da}from"./index-yXEFoIGg.js";import{r as Ct,P as ga}from"./index-mI9L2BhQ.js";import{u as Ge,T as pa}from"./team-BOavcC7l.js";import{g as ba,H as fa}from"./index-CZVLqYhR.js";import{D as ma}from"./url-evaluation-CKpb4hS-.js";import{R as Ea}from"./Refresh-kyiL1qX1.js";import{E as ha}from"./Edit-JIlB-sRA.js";import{y as _a}from"./index-DOFLIkPm.js";import{A as Na}from"./Add-CM0i44L2.js";import{C as Ln}from"./click-to-copy-BpBPaRWz.js";import{f as ya}from"./index-BojVbZw0.js";import{D as xa}from"./delete-confirm-DwwucGed.js";import{P as Aa}from"./permission-Dh9Y-pMK.js";import{u as Sa}from"./blocklet-Cu8go6Cl.js";import{u as jn}from"./use-mobile-DehCuxqg.js";import{A as Ta}from"./actions-DSVBY-iK.js";import{u as Ra}from"./useAsyncRetry-DTCkIRbI.js";import"./TableSearch-BQiqRB7D.js";import"./Search-BiQ8hlgr.js";import"./Clear-CFi5u92e.js";import"./useLocalStorage-C5c8IOKv.js";import"./index-gDj2o7RF.js";import"./decode-DPztD6kB.js";import"./UnfoldMore-DZ3laWH7.js";import"./shorten-label-azqzn6Q0.js";import"./ViewList-DC04kVZ7.js";import"./index-CeMW5u5M.js";import"./ButtonGroup-B_6MNBFc.js";import"./getValidReactChildren-C8GIEouH.js";import"./index.esm-CgpVcU8p.js";import"./Google-KJc6rb0J.js";import"./cloneDeep-BAowUJcW.js";import"./Autocomplete-BBHR-e2e.js";import"./ListSubheader-BHGxSe1E.js";import"./AdapterDayjs-jQWZxlKZ.js";import"./useThemeProps-Ddo6kYr5.js";import"./CSSTransition-C6uS6QtZ.js";import"./visuallyHidden-Dan1xhjv.js";import"./index-BNQ03H5g.js";import"./Verified-M-1m4RTW.js";import"./DeleteOutline-BHEKXTkO.js";import"./ErrorOutline-DBqK27X8.js";import"./index-n0Dm2HUt.js";import"./emotion-cache.browser.esm-BLI6o2QB.js";import"./sdk-DH9OjvLO.js";import"./index-C34tPvay.js";import"./ua-parser-DP5omx3I.js";import"./edit.svg-CpLTrX1j.js";import"./list-header-BsNw1q-X.js";import"./chain-tpP2d9Lm.js";import"./ToggleButtonGroup-CbzWaH4A.js";import"./lock.svg-DcfL5WSZ.js";import"./FilterList-DqZHJbRG.js";import"./index-D6WMVz-u.js";import"./redux-DfszZyTl.js";import"./typeof-QjJsDpFa.js";import"./depsEqual-DJ4V1mTU.js";import"./MoreVert-Ck4O28kx.js";import"./useAsync-EJ0V06fl.js";const Ca=ks(t.jsx("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm-1 4 6 6v10c0 1.1-.9 2-2 2H7.99C6.89 23 6 22.1 6 21l.01-14c0-1.1.89-2 1.99-2zm-1 7h5.5L14 6.5z"}));function Kn({value:e}){const{t:s,locale:a}=ye(),i=new Date;return new Date(e)<i?t.jsxs("span",{style:{color:"red"},children:[t.jsx(Fe,{value:e,locale:a}),`${s("setting.accessKey.expired",{time:""})}`]}):t.jsx(Fe,{mode:"daysLeft",value:e,locale:a,type:"all"})}Kn.propTypes={value:j.string.isRequired};function Hn({value:e,onChange:s,...a}){const{t:i}=ye(),g=Y.useMemo(()=>[{value:"signature",title:i("setting.accessKey.signature"),description:i("setting.accessKey.signatureDesc")},{value:"simple",title:i("setting.accessKey.simple"),description:i("setting.accessKey.simpleDesc")}],[i]);return t.jsxs(Bn,{style:{width:"100%"},variant:"outlined",...a,children:[t.jsx($n,{children:i("setting.accessKey.authType")}),t.jsx(Pn,{value:e,onChange:s,fullWidth:!0,label:i("setting.accessKey.authType"),IconComponent:E=>t.jsx(Nt,{...E,width:20,height:20}),children:g.map(E=>t.jsx(Un,{value:E.value,children:t.jsxs($,{children:[t.jsx("span",{children:E.title}),t.jsx($,{sx:{maxWidth:510,fontSize:12,color:"#999",whiteSpace:"normal"},children:E.description})]})},E.value))})]})}Hn.propTypes={value:j.string.isRequired,onChange:j.func.isRequired};const zn=()=>{const e=on.RBAC_CONFIG.roles.filter(g=>g.passport),{inService:s}=Oe(),{roles:a}=Ge(),i=[...e,...s?a:[]];return Ds(i,"name").filter(g=>g.name!==on.ROLES.OWNER)};function wt(){const{session:e}=Bs(),s=zn();return Y.useMemo(()=>{if(!e?.user?.role)return[];if(["owner","admin"].includes(e.user.role))return s;const i=s.filter(E=>E.name==="guest");return[...s.filter(E=>E.name!=="guest").filter(E=>e.user.passports.find(_=>_.role===E.name)),...i]},[s,e?.user?.passports,e?.user?.role])}function It({onCreate:e=()=>{},remark:s=""}){const{api:a}=Oe(),{teamDid:i}=Ge(),{t:g}=ye(),[E,_]=Y.useState(!1),[l,h]=Y.useState(null),u=wt(),y=()=>{_(!1),h(null)},T=async f=>{const{remark:v,passport:A,authType:b}=f;_(!0);const C=await a.createAccessKey({input:{teamDid:i,remark:v.trim(),passport:A,expireAt:f.expireAt?new Date(f.expireAt).getTime():null,authType:b}}),{data:B}=C;e(B),h(null),_(!1)},c={title:`${g("common.create")} ${g("accessKey")}`,description:(f,v,A)=>t.jsxs(Fn,{sx:{gap:3},children:[t.jsx(Mn,{label:g("setting.accessKey.tip"),autoComplete:"off",variant:"outlined",name:"remark",fullWidth:!0,autoFocus:!0,margin:"dense",value:f.remark,onChange:b=>{v({...f,remark:b.target.value,__disableConfirm:!f.passport||!b.target.value.trim()}),b.target.value.trim()?A(""):A(g("setting.accessKey.remarkInvalid"))},slotProps:{htmlInput:{"data-cy":"remark-input"}}}),t.jsxs(Bn,{style:{width:"100%"},variant:"outlined",children:[t.jsx($n,{sx:{width:"calc(100% - 46px)"},children:g("setting.accessKey.passport")}),t.jsx(Pn,{"data-cy":"create-access-key-select-passport",value:f.passport,onChange:b=>{const C=b.target.value;A(null),v({...f,passport:C,__disableConfirm:!f.remark||!C})},fullWidth:!0,label:g("setting.accessKey.passport"),disabled:E,IconComponent:b=>t.jsx(Nt,{...b,width:20,height:20}),children:u.map(b=>t.jsx(Un,{value:b.name,"data-cy":`create-access-key-passport-option-${b.name}`,children:t.jsxs($,{children:[t.jsx("span",{children:b.title||b.name}),t.jsx($,{sx:{maxWidth:440,fontSize:12,color:"#999",whiteSpace:"normal",textAlign:"justify"},children:b.description})]})},b.name))})]}),t.jsx(Hn,{value:f.authType,onChange:b=>{v({...f,authType:b.target.value})}}),t.jsx(Rt,{placeholder:g("setting.accessKey.expireTime"),value:f.expireAt,onChange:b=>{v({...f,expireAt:b,__disableConfirm:!f.passport||!f.remark||!b})}})]}),confirm:g("common.confirm"),cancel:g("common.cancel"),color:"primary",params:{remark:s,authType:"signature",__disableConfirm:!s.trim()},onConfirm:T,onCancel:y};return t.jsxs(t.Fragment,{children:[t.jsxs(vn,{sx:{color:"common.white"},edge:"end",variant:"contained",color:"primary","data-cy":"add-access-key-btn",onClick:()=>h(c),className:"rule-action",children:[E?t.jsx($s,{size:16}):t.jsx(Na,{style:{fontSize:16}}),g("common.create")]}),l&&t.jsx(yt,{title:l.title,description:l.description,confirm:l.confirm,color:l.color,cancel:l.cancel,params:l.params,onConfirm:l.onConfirm,onCancel:l.onCancel})]})}It.propTypes={remark:j.string,onCreate:j.func};var Tn,bt;function wa(){if(bt)return Tn;bt=1;function e(n){return n instanceof Map?n.clear=n.delete=n.set=function(){throw new Error("map is read-only")}:n instanceof Set&&(n.add=n.clear=n.delete=function(){throw new Error("set is read-only")}),Object.freeze(n),Object.getOwnPropertyNames(n).forEach(o=>{const d=n[o],w=typeof d;(w==="object"||w==="function")&&!Object.isFrozen(d)&&e(d)}),n}class s{constructor(o){o.data===void 0&&(o.data={}),this.data=o.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function a(n){return n.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function i(n,...o){const d=Object.create(null);for(const w in n)d[w]=n[w];return o.forEach(function(w){for(const J in w)d[J]=w[J]}),d}const g="</span>",E=n=>!!n.scope,_=(n,{prefix:o})=>{if(n.startsWith("language:"))return n.replace("language:","language-");if(n.includes(".")){const d=n.split(".");return[`${o}${d.shift()}`,...d.map((w,J)=>`${w}${"_".repeat(J+1)}`)].join(" ")}return`${o}${n}`};class l{constructor(o,d){this.buffer="",this.classPrefix=d.classPrefix,o.walk(this)}addText(o){this.buffer+=a(o)}openNode(o){if(!E(o))return;const d=_(o.scope,{prefix:this.classPrefix});this.span(d)}closeNode(o){E(o)&&(this.buffer+=g)}value(){return this.buffer}span(o){this.buffer+=`<span class="${o}">`}}const h=(n={})=>{const o={children:[]};return Object.assign(o,n),o};class u{constructor(){this.rootNode=h(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(o){this.top.children.push(o)}openNode(o){const d=h({scope:o});this.add(d),this.stack.push(d)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(o){return this.constructor._walk(o,this.rootNode)}static _walk(o,d){return typeof d=="string"?o.addText(d):d.children&&(o.openNode(d),d.children.forEach(w=>this._walk(o,w)),o.closeNode(d)),o}static _collapse(o){typeof o!="string"&&o.children&&(o.children.every(d=>typeof d=="string")?o.children=[o.children.join("")]:o.children.forEach(d=>{u._collapse(d)}))}}class y extends u{constructor(o){super(),this.options=o}addText(o){o!==""&&this.add(o)}startScope(o){this.openNode(o)}endScope(){this.closeNode()}__addSublanguage(o,d){const w=o.root;d&&(w.scope=`language:${d}`),this.add(w)}toHTML(){return new l(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function T(n){return n?typeof n=="string"?n:n.source:null}function c(n){return A("(?=",n,")")}function f(n){return A("(?:",n,")*")}function v(n){return A("(?:",n,")?")}function A(...n){return n.map(d=>T(d)).join("")}function b(n){const o=n[n.length-1];return typeof o=="object"&&o.constructor===Object?(n.splice(n.length-1,1),o):{}}function C(...n){return"("+(b(n).capture?"":"?:")+n.map(w=>T(w)).join("|")+")"}function B(n){return new RegExp(n.toString()+"|").exec("").length-1}function M(n,o){const d=n&&n.exec(o);return d&&d.index===0}const P=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function k(n,{joinWith:o}){let d=0;return n.map(w=>{d+=1;const J=d;let Q=T(w),N="";for(;Q.length>0;){const m=P.exec(Q);if(!m){N+=Q;break}N+=Q.substring(0,m.index),Q=Q.substring(m.index+m[0].length),m[0][0]==="\\"&&m[1]?N+="\\"+String(Number(m[1])+J):(N+=m[0],m[0]==="("&&d++)}return N}).map(w=>`(${w})`).join(o)}const q=/\b\B/,ge="[a-zA-Z]\\w*",ae="[a-zA-Z_]\\w*",ne="\\b\\d+(\\.\\d+)?",be="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",Ee="\\b(0b[01]+)",fe="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",I=(n={})=>{const o=/^#![ ]*\//;return n.binary&&(n.begin=A(o,/.*\b/,n.binary,/\b.*/)),i({scope:"meta",begin:o,end:/$/,relevance:0,"on:begin":(d,w)=>{d.index!==0&&w.ignoreMatch()}},n)},G={begin:"\\\\[\\s\\S]",relevance:0},V={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[G]},X={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[G]},xe={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},U=function(n,o,d={}){const w=i({scope:"comment",begin:n,end:o,contains:[]},d);w.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const J=C("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return w.contains.push({begin:A(/[ ]+/,"(",J,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),w},ie=U("//","$"),ue=U("/\\*","\\*/"),ce=U("#","$"),oe={scope:"number",begin:ne,relevance:0},Ae={scope:"number",begin:be,relevance:0},ln={scope:"number",begin:Ee,relevance:0},We={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[G,{begin:/\[/,end:/\]/,relevance:0,contains:[G]}]},je={scope:"title",begin:ge,relevance:0},un={scope:"title",begin:ae,relevance:0},Ze={begin:"\\.\\s*"+ae,relevance:0};var Me=Object.freeze({__proto__:null,APOS_STRING_MODE:V,BACKSLASH_ESCAPE:G,BINARY_NUMBER_MODE:ln,BINARY_NUMBER_RE:Ee,COMMENT:U,C_BLOCK_COMMENT_MODE:ue,C_LINE_COMMENT_MODE:ie,C_NUMBER_MODE:Ae,C_NUMBER_RE:be,END_SAME_AS_BEGIN:function(n){return Object.assign(n,{"on:begin":(o,d)=>{d.data._beginMatch=o[1]},"on:end":(o,d)=>{d.data._beginMatch!==o[1]&&d.ignoreMatch()}})},HASH_COMMENT_MODE:ce,IDENT_RE:ge,MATCH_NOTHING_RE:q,METHOD_GUARD:Ze,NUMBER_MODE:oe,NUMBER_RE:ne,PHRASAL_WORDS_MODE:xe,QUOTE_STRING_MODE:X,REGEXP_MODE:We,RE_STARTERS_RE:fe,SHEBANG:I,TITLE_MODE:je,UNDERSCORE_IDENT_RE:ae,UNDERSCORE_TITLE_MODE:un});function dn(n,o){n.input[n.index-1]==="."&&o.ignoreMatch()}function gn(n,o){n.className!==void 0&&(n.scope=n.className,delete n.className)}function pn(n,o){o&&n.beginKeywords&&(n.begin="\\b("+n.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",n.__beforeBegin=dn,n.keywords=n.keywords||n.beginKeywords,delete n.beginKeywords,n.relevance===void 0&&(n.relevance=0))}function bn(n,o){Array.isArray(n.illegal)&&(n.illegal=C(...n.illegal))}function fn(n,o){if(n.match){if(n.begin||n.end)throw new Error("begin & end are not supported with match");n.begin=n.match,delete n.match}}function K(n,o){n.relevance===void 0&&(n.relevance=1)}const Le=(n,o)=>{if(!n.beforeMatch)return;if(n.starts)throw new Error("beforeMatch cannot be used with starts");const d=Object.assign({},n);Object.keys(n).forEach(w=>{delete n[w]}),n.keywords=d.keywords,n.begin=A(d.beforeMatch,c(d.begin)),n.starts={relevance:0,contains:[Object.assign(d,{endsParent:!0})]},n.relevance=0,delete d.beforeMatch},Ce=["of","and","for","in","not","or","if","then","parent","list","value"],mn="keyword";function qn(n,o,d=mn){const w=Object.create(null);return typeof n=="string"?J(d,n.split(" ")):Array.isArray(n)?J(d,n):Object.keys(n).forEach(function(Q){Object.assign(w,qn(n[Q],o,Q))}),w;function J(Q,N){o&&(N=N.map(m=>m.toLowerCase())),N.forEach(function(m){const R=m.split("|");w[R[0]]=[Q,is(R[0],R[1])]})}}function is(n,o){return o?Number(o):os(n)?0:1}function os(n){return Ce.includes(n.toLowerCase())}const Xn={},we=n=>{console.error(n)},Vn=(n,...o)=>{console.log(`WARN: ${n}`,...o)},ke=(n,o)=>{Xn[`${n}/${o}`]||(console.log(`Deprecated as of ${n}. ${o}`),Xn[`${n}/${o}`]=!0)},Ye=new Error;function Jn(n,o,{key:d}){let w=0;const J=n[d],Q={},N={};for(let m=1;m<=o.length;m++)N[m+w]=J[m],Q[m+w]=!0,w+=B(o[m-1]);n[d]=N,n[d]._emit=Q,n[d]._multi=!0}function rs(n){if(Array.isArray(n.begin)){if(n.skip||n.excludeBegin||n.returnBegin)throw we("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Ye;if(typeof n.beginScope!="object"||n.beginScope===null)throw we("beginScope must be object"),Ye;Jn(n,n.begin,{key:"beginScope"}),n.begin=k(n.begin,{joinWith:""})}}function cs(n){if(Array.isArray(n.end)){if(n.skip||n.excludeEnd||n.returnEnd)throw we("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Ye;if(typeof n.endScope!="object"||n.endScope===null)throw we("endScope must be object"),Ye;Jn(n,n.end,{key:"endScope"}),n.end=k(n.end,{joinWith:""})}}function ls(n){n.scope&&typeof n.scope=="object"&&n.scope!==null&&(n.beginScope=n.scope,delete n.scope)}function us(n){ls(n),typeof n.beginScope=="string"&&(n.beginScope={_wrap:n.beginScope}),typeof n.endScope=="string"&&(n.endScope={_wrap:n.endScope}),rs(n),cs(n)}function ds(n){function o(N,m){return new RegExp(T(N),"m"+(n.case_insensitive?"i":"")+(n.unicodeRegex?"u":"")+(m?"g":""))}class d{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(m,R){R.position=this.position++,this.matchIndexes[this.matchAt]=R,this.regexes.push([R,m]),this.matchAt+=B(m)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const m=this.regexes.map(R=>R[1]);this.matcherRe=o(k(m,{joinWith:"|"}),!0),this.lastIndex=0}exec(m){this.matcherRe.lastIndex=this.lastIndex;const R=this.matcherRe.exec(m);if(!R)return null;const se=R.findIndex((Ke,hn)=>hn>0&&Ke!==void 0),ee=this.matchIndexes[se];return R.splice(0,se),Object.assign(R,ee)}}class w{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(m){if(this.multiRegexes[m])return this.multiRegexes[m];const R=new d;return this.rules.slice(m).forEach(([se,ee])=>R.addRule(se,ee)),R.compile(),this.multiRegexes[m]=R,R}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(m,R){this.rules.push([m,R]),R.type==="begin"&&this.count++}exec(m){const R=this.getMatcher(this.regexIndex);R.lastIndex=this.lastIndex;let se=R.exec(m);if(this.resumingScanAtSamePosition()&&!(se&&se.index===this.lastIndex)){const ee=this.getMatcher(0);ee.lastIndex=this.lastIndex+1,se=ee.exec(m)}return se&&(this.regexIndex+=se.position+1,this.regexIndex===this.count&&this.considerAll()),se}}function J(N){const m=new w;return N.contains.forEach(R=>m.addRule(R.begin,{rule:R,type:"begin"})),N.terminatorEnd&&m.addRule(N.terminatorEnd,{type:"end"}),N.illegal&&m.addRule(N.illegal,{type:"illegal"}),m}function Q(N,m){const R=N;if(N.isCompiled)return R;[gn,fn,us,Le].forEach(ee=>ee(N,m)),n.compilerExtensions.forEach(ee=>ee(N,m)),N.__beforeBegin=null,[pn,bn,K].forEach(ee=>ee(N,m)),N.isCompiled=!0;let se=null;return typeof N.keywords=="object"&&N.keywords.$pattern&&(N.keywords=Object.assign({},N.keywords),se=N.keywords.$pattern,delete N.keywords.$pattern),se=se||/\w+/,N.keywords&&(N.keywords=qn(N.keywords,n.case_insensitive)),R.keywordPatternRe=o(se,!0),m&&(N.begin||(N.begin=/\B|\b/),R.beginRe=o(R.begin),!N.end&&!N.endsWithParent&&(N.end=/\B|\b/),N.end&&(R.endRe=o(R.end)),R.terminatorEnd=T(R.end)||"",N.endsWithParent&&m.terminatorEnd&&(R.terminatorEnd+=(N.end?"|":"")+m.terminatorEnd)),N.illegal&&(R.illegalRe=o(N.illegal)),N.contains||(N.contains=[]),N.contains=[].concat(...N.contains.map(function(ee){return gs(ee==="self"?N:ee)})),N.contains.forEach(function(ee){Q(ee,R)}),N.starts&&Q(N.starts,m),R.matcher=J(R),R}if(n.compilerExtensions||(n.compilerExtensions=[]),n.contains&&n.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return n.classNameAliases=i(n.classNameAliases||{}),Q(n)}function Qn(n){return n?n.endsWithParent||Qn(n.starts):!1}function gs(n){return n.variants&&!n.cachedVariants&&(n.cachedVariants=n.variants.map(function(o){return i(n,{variants:null},o)})),n.cachedVariants?n.cachedVariants:Qn(n)?i(n,{starts:n.starts?i(n.starts):null}):Object.isFrozen(n)?i(n):n}var ps="11.11.1";class bs extends Error{constructor(o,d){super(o),this.name="HTMLInjectionError",this.html=d}}const En=a,et=i,nt=Symbol("nomatch"),fs=7,tt=function(n){const o=Object.create(null),d=Object.create(null),w=[];let J=!0;const Q="Could not find the language '{}', did you forget to load/include a language module?",N={disableAutodetect:!0,name:"Plain text",contains:[]};let m={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:y};function R(r){return m.noHighlightRe.test(r)}function se(r){let S=r.className+" ";S+=r.parentNode?r.parentNode.className:"";const D=m.languageDetectRe.exec(S);if(D){const W=Te(D[1]);return W||(Vn(Q.replace("{}",D[1])),Vn("Falling back to no-highlight mode for this block.",r)),W?D[1]:"no-highlight"}return S.split(/\s+/).find(W=>R(W)||Te(W))}function ee(r,S,D){let W="",te="";typeof S=="object"?(W=r,D=S.ignoreIllegals,te=S.language):(ke("10.7.0","highlight(lang, code, ...args) has been deprecated."),ke("10.7.0",`Please use highlight(code, options) instead.
|
|
1
|
+
import{aF as ks,j as t,aH as on,bn as Oe,bo as Ds,V as ye,N as Fe,r as Y,O as Bn,P as $n,S as Pn,Q as Un,K as $,bp as Nt,o as j,n as Bs,v as vn,C as $s,ac as yt,aV as Fn,t as Mn,bd as Ps,s as ve,Z as Us,bq as Be,br as Fs,bs as js,p as Ks,y as ze,$ as xt,aU as Hs,R as zs,at as Gs,H as Ws,m as Zs,bt as Sn,W as Ys,bu as At,bv as St,bw as Tt,bx as qs,i as Xs,T as Ue,by as Vs,ay as dt,a3 as gt,aR as pt,bk as Js,bz as Qs,U as ea,X as na,bA as ta,A as sa,u as aa,bm as ia,d as oa,bB as ra}from"./index-DN1FR838.js";import{u as ca,T as la}from"./html-title-DZPr9ErN.js";import ua from"./audit-logs-C8Rj-VnC.js";import{T as Rt,M as da}from"./index-CI77BW6M.js";import{r as Ct,P as ga}from"./index-BBE5QVnT.js";import{u as Ge,T as pa}from"./team-Dn5co06a.js";import{g as ba,H as fa}from"./index-DtEm4DlR.js";import{D as ma}from"./url-evaluation-D0KhcJoH.js";import{R as Ea}from"./Refresh-BRw0lNlx.js";import{E as ha}from"./Edit-CAoHCh26.js";import{y as _a}from"./index-aiY7k_D_.js";import{A as Na}from"./Add-DMoAJUVW.js";import{C as Ln}from"./click-to-copy-_XuYTLfd.js";import{f as ya}from"./index-BojVbZw0.js";import{D as xa}from"./delete-confirm-B3AhdXCf.js";import{P as Aa}from"./permission-BFEhHSn7.js";import{u as Sa}from"./blocklet-BwZNRhqB.js";import{u as jn}from"./use-mobile-BRO-uubG.js";import{A as Ta}from"./actions-B68pZ6f6.js";import{u as Ra}from"./useAsyncRetry-Bo43j2ED.js";import"./TableSearch-DTa-kQYq.js";import"./Search-DihRAr8J.js";import"./Clear-3aQ_ViuO.js";import"./useLocalStorage-DdFQ0H8D.js";import"./index-p4uzP6uF.js";import"./decode-DPztD6kB.js";import"./UnfoldMore-Obeukjjc.js";import"./shorten-label-lyN5fJdD.js";import"./ViewList-Dsx5HTn1.js";import"./index-DS6pTkmU.js";import"./ButtonGroup-Dlkb94HL.js";import"./getValidReactChildren-Dxx0sUSA.js";import"./index.esm-0qTLMRcM.js";import"./Google-QOJseWnL.js";import"./cloneDeep-9Rjs5zfn.js";import"./Autocomplete-DzPelkmw.js";import"./ListSubheader-Dz5YbKqQ.js";import"./AdapterDayjs-DFNTS6uL.js";import"./useThemeProps-7IPePURq.js";import"./CSSTransition-Cp9IAg_E.js";import"./visuallyHidden-Dan1xhjv.js";import"./index-Cwj1cT7X.js";import"./Verified-BkNsmE5y.js";import"./DeleteOutline-CduYjOSi.js";import"./ErrorOutline-ClBFY-zS.js";import"./index-oVsaWj9v.js";import"./emotion-cache.browser.esm-DR87qH_k.js";import"./sdk-Dn9cGqw6.js";import"./index-DW37Hc5m.js";import"./ua-parser-DP5omx3I.js";import"./edit.svg-BWsZcaur.js";import"./list-header-DLDug_Pi.js";import"./chain-BLr2de5j.js";import"./ToggleButtonGroup-BgcjoBhH.js";import"./lock.svg-BzS6KpeB.js";import"./FilterList-CoyfX8VL.js";import"./index-CIJ5EXA3.js";import"./redux-DfszZyTl.js";import"./typeof-QjJsDpFa.js";import"./depsEqual-C1JyiMkY.js";import"./MoreVert-Crfla2Nw.js";import"./useAsync-ihOYfxyw.js";const Ca=ks(t.jsx("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm-1 4 6 6v10c0 1.1-.9 2-2 2H7.99C6.89 23 6 22.1 6 21l.01-14c0-1.1.89-2 1.99-2zm-1 7h5.5L14 6.5z"}));function Kn({value:e}){const{t:s,locale:a}=ye(),i=new Date;return new Date(e)<i?t.jsxs("span",{style:{color:"red"},children:[t.jsx(Fe,{value:e,locale:a}),`${s("setting.accessKey.expired",{time:""})}`]}):t.jsx(Fe,{mode:"daysLeft",value:e,locale:a,type:"all"})}Kn.propTypes={value:j.string.isRequired};function Hn({value:e,onChange:s,...a}){const{t:i}=ye(),g=Y.useMemo(()=>[{value:"signature",title:i("setting.accessKey.signature"),description:i("setting.accessKey.signatureDesc")},{value:"simple",title:i("setting.accessKey.simple"),description:i("setting.accessKey.simpleDesc")}],[i]);return t.jsxs(Bn,{style:{width:"100%"},variant:"outlined",...a,children:[t.jsx($n,{children:i("setting.accessKey.authType")}),t.jsx(Pn,{value:e,onChange:s,fullWidth:!0,label:i("setting.accessKey.authType"),IconComponent:E=>t.jsx(Nt,{...E,width:20,height:20}),children:g.map(E=>t.jsx(Un,{value:E.value,children:t.jsxs($,{children:[t.jsx("span",{children:E.title}),t.jsx($,{sx:{maxWidth:510,fontSize:12,color:"#999",whiteSpace:"normal"},children:E.description})]})},E.value))})]})}Hn.propTypes={value:j.string.isRequired,onChange:j.func.isRequired};const zn=()=>{const e=on.RBAC_CONFIG.roles.filter(g=>g.passport),{inService:s}=Oe(),{roles:a}=Ge(),i=[...e,...s?a:[]];return Ds(i,"name").filter(g=>g.name!==on.ROLES.OWNER)};function wt(){const{session:e}=Bs(),s=zn();return Y.useMemo(()=>{if(!e?.user?.role)return[];if(["owner","admin"].includes(e.user.role))return s;const i=s.filter(E=>E.name==="guest");return[...s.filter(E=>E.name!=="guest").filter(E=>e.user.passports.find(_=>_.role===E.name)),...i]},[s,e?.user?.passports,e?.user?.role])}function It({onCreate:e=()=>{},remark:s=""}){const{api:a}=Oe(),{teamDid:i}=Ge(),{t:g}=ye(),[E,_]=Y.useState(!1),[l,h]=Y.useState(null),u=wt(),y=()=>{_(!1),h(null)},T=async f=>{const{remark:v,passport:A,authType:b}=f;_(!0);const C=await a.createAccessKey({input:{teamDid:i,remark:v.trim(),passport:A,expireAt:f.expireAt?new Date(f.expireAt).getTime():null,authType:b}}),{data:B}=C;e(B),h(null),_(!1)},c={title:`${g("common.create")} ${g("accessKey")}`,description:(f,v,A)=>t.jsxs(Fn,{sx:{gap:3},children:[t.jsx(Mn,{label:g("setting.accessKey.tip"),autoComplete:"off",variant:"outlined",name:"remark",fullWidth:!0,autoFocus:!0,margin:"dense",value:f.remark,onChange:b=>{v({...f,remark:b.target.value,__disableConfirm:!f.passport||!b.target.value.trim()}),b.target.value.trim()?A(""):A(g("setting.accessKey.remarkInvalid"))},slotProps:{htmlInput:{"data-cy":"remark-input"}}}),t.jsxs(Bn,{style:{width:"100%"},variant:"outlined",children:[t.jsx($n,{sx:{width:"calc(100% - 46px)"},children:g("setting.accessKey.passport")}),t.jsx(Pn,{"data-cy":"create-access-key-select-passport",value:f.passport,onChange:b=>{const C=b.target.value;A(null),v({...f,passport:C,__disableConfirm:!f.remark||!C})},fullWidth:!0,label:g("setting.accessKey.passport"),disabled:E,IconComponent:b=>t.jsx(Nt,{...b,width:20,height:20}),children:u.map(b=>t.jsx(Un,{value:b.name,"data-cy":`create-access-key-passport-option-${b.name}`,children:t.jsxs($,{children:[t.jsx("span",{children:b.title||b.name}),t.jsx($,{sx:{maxWidth:440,fontSize:12,color:"#999",whiteSpace:"normal",textAlign:"justify"},children:b.description})]})},b.name))})]}),t.jsx(Hn,{value:f.authType,onChange:b=>{v({...f,authType:b.target.value})}}),t.jsx(Rt,{placeholder:g("setting.accessKey.expireTime"),value:f.expireAt,onChange:b=>{v({...f,expireAt:b,__disableConfirm:!f.passport||!f.remark||!b})}})]}),confirm:g("common.confirm"),cancel:g("common.cancel"),color:"primary",params:{remark:s,authType:"signature",__disableConfirm:!s.trim()},onConfirm:T,onCancel:y};return t.jsxs(t.Fragment,{children:[t.jsxs(vn,{sx:{color:"common.white"},edge:"end",variant:"contained",color:"primary","data-cy":"add-access-key-btn",onClick:()=>h(c),className:"rule-action",children:[E?t.jsx($s,{size:16}):t.jsx(Na,{style:{fontSize:16}}),g("common.create")]}),l&&t.jsx(yt,{title:l.title,description:l.description,confirm:l.confirm,color:l.color,cancel:l.cancel,params:l.params,onConfirm:l.onConfirm,onCancel:l.onCancel})]})}It.propTypes={remark:j.string,onCreate:j.func};var Tn,bt;function wa(){if(bt)return Tn;bt=1;function e(n){return n instanceof Map?n.clear=n.delete=n.set=function(){throw new Error("map is read-only")}:n instanceof Set&&(n.add=n.clear=n.delete=function(){throw new Error("set is read-only")}),Object.freeze(n),Object.getOwnPropertyNames(n).forEach(o=>{const d=n[o],w=typeof d;(w==="object"||w==="function")&&!Object.isFrozen(d)&&e(d)}),n}class s{constructor(o){o.data===void 0&&(o.data={}),this.data=o.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function a(n){return n.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function i(n,...o){const d=Object.create(null);for(const w in n)d[w]=n[w];return o.forEach(function(w){for(const J in w)d[J]=w[J]}),d}const g="</span>",E=n=>!!n.scope,_=(n,{prefix:o})=>{if(n.startsWith("language:"))return n.replace("language:","language-");if(n.includes(".")){const d=n.split(".");return[`${o}${d.shift()}`,...d.map((w,J)=>`${w}${"_".repeat(J+1)}`)].join(" ")}return`${o}${n}`};class l{constructor(o,d){this.buffer="",this.classPrefix=d.classPrefix,o.walk(this)}addText(o){this.buffer+=a(o)}openNode(o){if(!E(o))return;const d=_(o.scope,{prefix:this.classPrefix});this.span(d)}closeNode(o){E(o)&&(this.buffer+=g)}value(){return this.buffer}span(o){this.buffer+=`<span class="${o}">`}}const h=(n={})=>{const o={children:[]};return Object.assign(o,n),o};class u{constructor(){this.rootNode=h(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(o){this.top.children.push(o)}openNode(o){const d=h({scope:o});this.add(d),this.stack.push(d)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(o){return this.constructor._walk(o,this.rootNode)}static _walk(o,d){return typeof d=="string"?o.addText(d):d.children&&(o.openNode(d),d.children.forEach(w=>this._walk(o,w)),o.closeNode(d)),o}static _collapse(o){typeof o!="string"&&o.children&&(o.children.every(d=>typeof d=="string")?o.children=[o.children.join("")]:o.children.forEach(d=>{u._collapse(d)}))}}class y extends u{constructor(o){super(),this.options=o}addText(o){o!==""&&this.add(o)}startScope(o){this.openNode(o)}endScope(){this.closeNode()}__addSublanguage(o,d){const w=o.root;d&&(w.scope=`language:${d}`),this.add(w)}toHTML(){return new l(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function T(n){return n?typeof n=="string"?n:n.source:null}function c(n){return A("(?=",n,")")}function f(n){return A("(?:",n,")*")}function v(n){return A("(?:",n,")?")}function A(...n){return n.map(d=>T(d)).join("")}function b(n){const o=n[n.length-1];return typeof o=="object"&&o.constructor===Object?(n.splice(n.length-1,1),o):{}}function C(...n){return"("+(b(n).capture?"":"?:")+n.map(w=>T(w)).join("|")+")"}function B(n){return new RegExp(n.toString()+"|").exec("").length-1}function M(n,o){const d=n&&n.exec(o);return d&&d.index===0}const P=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function k(n,{joinWith:o}){let d=0;return n.map(w=>{d+=1;const J=d;let Q=T(w),N="";for(;Q.length>0;){const m=P.exec(Q);if(!m){N+=Q;break}N+=Q.substring(0,m.index),Q=Q.substring(m.index+m[0].length),m[0][0]==="\\"&&m[1]?N+="\\"+String(Number(m[1])+J):(N+=m[0],m[0]==="("&&d++)}return N}).map(w=>`(${w})`).join(o)}const q=/\b\B/,ge="[a-zA-Z]\\w*",ae="[a-zA-Z_]\\w*",ne="\\b\\d+(\\.\\d+)?",be="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",Ee="\\b(0b[01]+)",fe="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",I=(n={})=>{const o=/^#![ ]*\//;return n.binary&&(n.begin=A(o,/.*\b/,n.binary,/\b.*/)),i({scope:"meta",begin:o,end:/$/,relevance:0,"on:begin":(d,w)=>{d.index!==0&&w.ignoreMatch()}},n)},G={begin:"\\\\[\\s\\S]",relevance:0},V={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[G]},X={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[G]},xe={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},U=function(n,o,d={}){const w=i({scope:"comment",begin:n,end:o,contains:[]},d);w.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const J=C("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return w.contains.push({begin:A(/[ ]+/,"(",J,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),w},ie=U("//","$"),ue=U("/\\*","\\*/"),ce=U("#","$"),oe={scope:"number",begin:ne,relevance:0},Ae={scope:"number",begin:be,relevance:0},ln={scope:"number",begin:Ee,relevance:0},We={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[G,{begin:/\[/,end:/\]/,relevance:0,contains:[G]}]},je={scope:"title",begin:ge,relevance:0},un={scope:"title",begin:ae,relevance:0},Ze={begin:"\\.\\s*"+ae,relevance:0};var Me=Object.freeze({__proto__:null,APOS_STRING_MODE:V,BACKSLASH_ESCAPE:G,BINARY_NUMBER_MODE:ln,BINARY_NUMBER_RE:Ee,COMMENT:U,C_BLOCK_COMMENT_MODE:ue,C_LINE_COMMENT_MODE:ie,C_NUMBER_MODE:Ae,C_NUMBER_RE:be,END_SAME_AS_BEGIN:function(n){return Object.assign(n,{"on:begin":(o,d)=>{d.data._beginMatch=o[1]},"on:end":(o,d)=>{d.data._beginMatch!==o[1]&&d.ignoreMatch()}})},HASH_COMMENT_MODE:ce,IDENT_RE:ge,MATCH_NOTHING_RE:q,METHOD_GUARD:Ze,NUMBER_MODE:oe,NUMBER_RE:ne,PHRASAL_WORDS_MODE:xe,QUOTE_STRING_MODE:X,REGEXP_MODE:We,RE_STARTERS_RE:fe,SHEBANG:I,TITLE_MODE:je,UNDERSCORE_IDENT_RE:ae,UNDERSCORE_TITLE_MODE:un});function dn(n,o){n.input[n.index-1]==="."&&o.ignoreMatch()}function gn(n,o){n.className!==void 0&&(n.scope=n.className,delete n.className)}function pn(n,o){o&&n.beginKeywords&&(n.begin="\\b("+n.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",n.__beforeBegin=dn,n.keywords=n.keywords||n.beginKeywords,delete n.beginKeywords,n.relevance===void 0&&(n.relevance=0))}function bn(n,o){Array.isArray(n.illegal)&&(n.illegal=C(...n.illegal))}function fn(n,o){if(n.match){if(n.begin||n.end)throw new Error("begin & end are not supported with match");n.begin=n.match,delete n.match}}function K(n,o){n.relevance===void 0&&(n.relevance=1)}const Le=(n,o)=>{if(!n.beforeMatch)return;if(n.starts)throw new Error("beforeMatch cannot be used with starts");const d=Object.assign({},n);Object.keys(n).forEach(w=>{delete n[w]}),n.keywords=d.keywords,n.begin=A(d.beforeMatch,c(d.begin)),n.starts={relevance:0,contains:[Object.assign(d,{endsParent:!0})]},n.relevance=0,delete d.beforeMatch},Ce=["of","and","for","in","not","or","if","then","parent","list","value"],mn="keyword";function qn(n,o,d=mn){const w=Object.create(null);return typeof n=="string"?J(d,n.split(" ")):Array.isArray(n)?J(d,n):Object.keys(n).forEach(function(Q){Object.assign(w,qn(n[Q],o,Q))}),w;function J(Q,N){o&&(N=N.map(m=>m.toLowerCase())),N.forEach(function(m){const R=m.split("|");w[R[0]]=[Q,is(R[0],R[1])]})}}function is(n,o){return o?Number(o):os(n)?0:1}function os(n){return Ce.includes(n.toLowerCase())}const Xn={},we=n=>{console.error(n)},Vn=(n,...o)=>{console.log(`WARN: ${n}`,...o)},ke=(n,o)=>{Xn[`${n}/${o}`]||(console.log(`Deprecated as of ${n}. ${o}`),Xn[`${n}/${o}`]=!0)},Ye=new Error;function Jn(n,o,{key:d}){let w=0;const J=n[d],Q={},N={};for(let m=1;m<=o.length;m++)N[m+w]=J[m],Q[m+w]=!0,w+=B(o[m-1]);n[d]=N,n[d]._emit=Q,n[d]._multi=!0}function rs(n){if(Array.isArray(n.begin)){if(n.skip||n.excludeBegin||n.returnBegin)throw we("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Ye;if(typeof n.beginScope!="object"||n.beginScope===null)throw we("beginScope must be object"),Ye;Jn(n,n.begin,{key:"beginScope"}),n.begin=k(n.begin,{joinWith:""})}}function cs(n){if(Array.isArray(n.end)){if(n.skip||n.excludeEnd||n.returnEnd)throw we("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Ye;if(typeof n.endScope!="object"||n.endScope===null)throw we("endScope must be object"),Ye;Jn(n,n.end,{key:"endScope"}),n.end=k(n.end,{joinWith:""})}}function ls(n){n.scope&&typeof n.scope=="object"&&n.scope!==null&&(n.beginScope=n.scope,delete n.scope)}function us(n){ls(n),typeof n.beginScope=="string"&&(n.beginScope={_wrap:n.beginScope}),typeof n.endScope=="string"&&(n.endScope={_wrap:n.endScope}),rs(n),cs(n)}function ds(n){function o(N,m){return new RegExp(T(N),"m"+(n.case_insensitive?"i":"")+(n.unicodeRegex?"u":"")+(m?"g":""))}class d{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(m,R){R.position=this.position++,this.matchIndexes[this.matchAt]=R,this.regexes.push([R,m]),this.matchAt+=B(m)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const m=this.regexes.map(R=>R[1]);this.matcherRe=o(k(m,{joinWith:"|"}),!0),this.lastIndex=0}exec(m){this.matcherRe.lastIndex=this.lastIndex;const R=this.matcherRe.exec(m);if(!R)return null;const se=R.findIndex((Ke,hn)=>hn>0&&Ke!==void 0),ee=this.matchIndexes[se];return R.splice(0,se),Object.assign(R,ee)}}class w{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(m){if(this.multiRegexes[m])return this.multiRegexes[m];const R=new d;return this.rules.slice(m).forEach(([se,ee])=>R.addRule(se,ee)),R.compile(),this.multiRegexes[m]=R,R}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(m,R){this.rules.push([m,R]),R.type==="begin"&&this.count++}exec(m){const R=this.getMatcher(this.regexIndex);R.lastIndex=this.lastIndex;let se=R.exec(m);if(this.resumingScanAtSamePosition()&&!(se&&se.index===this.lastIndex)){const ee=this.getMatcher(0);ee.lastIndex=this.lastIndex+1,se=ee.exec(m)}return se&&(this.regexIndex+=se.position+1,this.regexIndex===this.count&&this.considerAll()),se}}function J(N){const m=new w;return N.contains.forEach(R=>m.addRule(R.begin,{rule:R,type:"begin"})),N.terminatorEnd&&m.addRule(N.terminatorEnd,{type:"end"}),N.illegal&&m.addRule(N.illegal,{type:"illegal"}),m}function Q(N,m){const R=N;if(N.isCompiled)return R;[gn,fn,us,Le].forEach(ee=>ee(N,m)),n.compilerExtensions.forEach(ee=>ee(N,m)),N.__beforeBegin=null,[pn,bn,K].forEach(ee=>ee(N,m)),N.isCompiled=!0;let se=null;return typeof N.keywords=="object"&&N.keywords.$pattern&&(N.keywords=Object.assign({},N.keywords),se=N.keywords.$pattern,delete N.keywords.$pattern),se=se||/\w+/,N.keywords&&(N.keywords=qn(N.keywords,n.case_insensitive)),R.keywordPatternRe=o(se,!0),m&&(N.begin||(N.begin=/\B|\b/),R.beginRe=o(R.begin),!N.end&&!N.endsWithParent&&(N.end=/\B|\b/),N.end&&(R.endRe=o(R.end)),R.terminatorEnd=T(R.end)||"",N.endsWithParent&&m.terminatorEnd&&(R.terminatorEnd+=(N.end?"|":"")+m.terminatorEnd)),N.illegal&&(R.illegalRe=o(N.illegal)),N.contains||(N.contains=[]),N.contains=[].concat(...N.contains.map(function(ee){return gs(ee==="self"?N:ee)})),N.contains.forEach(function(ee){Q(ee,R)}),N.starts&&Q(N.starts,m),R.matcher=J(R),R}if(n.compilerExtensions||(n.compilerExtensions=[]),n.contains&&n.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return n.classNameAliases=i(n.classNameAliases||{}),Q(n)}function Qn(n){return n?n.endsWithParent||Qn(n.starts):!1}function gs(n){return n.variants&&!n.cachedVariants&&(n.cachedVariants=n.variants.map(function(o){return i(n,{variants:null},o)})),n.cachedVariants?n.cachedVariants:Qn(n)?i(n,{starts:n.starts?i(n.starts):null}):Object.isFrozen(n)?i(n):n}var ps="11.11.1";class bs extends Error{constructor(o,d){super(o),this.name="HTMLInjectionError",this.html=d}}const En=a,et=i,nt=Symbol("nomatch"),fs=7,tt=function(n){const o=Object.create(null),d=Object.create(null),w=[];let J=!0;const Q="Could not find the language '{}', did you forget to load/include a language module?",N={disableAutodetect:!0,name:"Plain text",contains:[]};let m={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:y};function R(r){return m.noHighlightRe.test(r)}function se(r){let S=r.className+" ";S+=r.parentNode?r.parentNode.className:"";const D=m.languageDetectRe.exec(S);if(D){const W=Te(D[1]);return W||(Vn(Q.replace("{}",D[1])),Vn("Falling back to no-highlight mode for this block.",r)),W?D[1]:"no-highlight"}return S.split(/\s+/).find(W=>R(W)||Te(W))}function ee(r,S,D){let W="",te="";typeof S=="object"?(W=r,D=S.ignoreIllegals,te=S.language):(ke("10.7.0","highlight(lang, code, ...args) has been deprecated."),ke("10.7.0",`Please use highlight(code, options) instead.
|
|
2
2
|
https://github.com/highlightjs/highlight.js/issues/2277`),te=r,W=S),D===void 0&&(D=!0);const me={code:W,language:te};Xe("before:highlight",me);const Re=me.result?me.result:Ke(me.language,me.code,D);return Re.code=me.code,Xe("after:highlight",Re),Re}function Ke(r,S,D,W){const te=Object.create(null);function me(p,x){return p.keywords[x]}function Re(){if(!O.keywords){re.addText(Z);return}let p=0;O.keywordPatternRe.lastIndex=0;let x=O.keywordPatternRe.exec(Z),L="";for(;x;){L+=Z.substring(p,x.index);const F=_e.case_insensitive?x[0].toLowerCase():x[0],le=me(O,F);if(le){const[Se,Ms]=le;if(re.addText(L),L="",te[F]=(te[F]||0)+1,te[F]<=fs&&(Qe+=Ms),Se.startsWith("_"))L+=x[0];else{const Ls=_e.classNameAliases[Se]||Se;he(x[0],Ls)}}else L+=x[0];p=O.keywordPatternRe.lastIndex,x=O.keywordPatternRe.exec(Z)}L+=Z.substring(p),re.addText(L)}function Ve(){if(Z==="")return;let p=null;if(typeof O.subLanguage=="string"){if(!o[O.subLanguage]){re.addText(Z);return}p=Ke(O.subLanguage,Z,!0,ut[O.subLanguage]),ut[O.subLanguage]=p._top}else p=_n(Z,O.subLanguage.length?O.subLanguage:null);O.relevance>0&&(Qe+=p.relevance),re.__addSublanguage(p._emitter,p.language)}function pe(){O.subLanguage!=null?Ve():Re(),Z=""}function he(p,x){p!==""&&(re.startScope(x),re.addText(p),re.endScope())}function ot(p,x){let L=1;const F=x.length-1;for(;L<=F;){if(!p._emit[L]){L++;continue}const le=_e.classNameAliases[p[L]]||p[L],Se=x[L];le?he(Se,le):(Z=Se,Re(),Z=""),L++}}function rt(p,x){return p.scope&&typeof p.scope=="string"&&re.openNode(_e.classNameAliases[p.scope]||p.scope),p.beginScope&&(p.beginScope._wrap?(he(Z,_e.classNameAliases[p.beginScope._wrap]||p.beginScope._wrap),Z=""):p.beginScope._multi&&(ot(p.beginScope,x),Z="")),O=Object.create(p,{parent:{value:O}}),O}function ct(p,x,L){let F=M(p.endRe,L);if(F){if(p["on:end"]){const le=new s(p);p["on:end"](x,le),le.isMatchIgnored&&(F=!1)}if(F){for(;p.endsParent&&p.parent;)p=p.parent;return p}}if(p.endsWithParent)return ct(p.parent,x,L)}function Cs(p){return O.matcher.regexIndex===0?(Z+=p[0],1):(An=!0,0)}function ws(p){const x=p[0],L=p.rule,F=new s(L),le=[L.__beforeBegin,L["on:begin"]];for(const Se of le)if(Se&&(Se(p,F),F.isMatchIgnored))return Cs(x);return L.skip?Z+=x:(L.excludeBegin&&(Z+=x),pe(),!L.returnBegin&&!L.excludeBegin&&(Z=x)),rt(L,p),L.returnBegin?0:x.length}function Is(p){const x=p[0],L=S.substring(p.index),F=ct(O,p,L);if(!F)return nt;const le=O;O.endScope&&O.endScope._wrap?(pe(),he(x,O.endScope._wrap)):O.endScope&&O.endScope._multi?(pe(),ot(O.endScope,p)):le.skip?Z+=x:(le.returnEnd||le.excludeEnd||(Z+=x),pe(),le.excludeEnd&&(Z=x));do O.scope&&re.closeNode(),!O.skip&&!O.subLanguage&&(Qe+=O.relevance),O=O.parent;while(O!==F.parent);return F.starts&&rt(F.starts,p),le.returnEnd?0:x.length}function Os(){const p=[];for(let x=O;x!==_e;x=x.parent)x.scope&&p.unshift(x.scope);p.forEach(x=>re.openNode(x))}let Je={};function lt(p,x){const L=x&&x[0];if(Z+=p,L==null)return pe(),0;if(Je.type==="begin"&&x.type==="end"&&Je.index===x.index&&L===""){if(Z+=S.slice(x.index,x.index+1),!J){const F=new Error(`0 width match regex (${r})`);throw F.languageName=r,F.badRule=Je.rule,F}return 1}if(Je=x,x.type==="begin")return ws(x);if(x.type==="illegal"&&!D){const F=new Error('Illegal lexeme "'+L+'" for mode "'+(O.scope||"<unnamed>")+'"');throw F.mode=O,F}else if(x.type==="end"){const F=Is(x);if(F!==nt)return F}if(x.type==="illegal"&&L==="")return Z+=`
|
|
3
3
|
`,1;if(xn>1e5&&xn>x.index*3)throw new Error("potential infinite loop, way more iterations than matches");return Z+=L,L.length}const _e=Te(r);if(!_e)throw we(Q.replace("{}",r)),new Error('Unknown language: "'+r+'"');const vs=ds(_e);let yn="",O=W||vs;const ut={},re=new m.__emitter(m);Os();let Z="",Qe=0,Ie=0,xn=0,An=!1;try{if(_e.__emitTokens)_e.__emitTokens(S,re);else{for(O.matcher.considerAll();;){xn++,An?An=!1:O.matcher.considerAll(),O.matcher.lastIndex=Ie;const p=O.matcher.exec(S);if(!p)break;const x=S.substring(Ie,p.index),L=lt(x,p);Ie=p.index+L}lt(S.substring(Ie))}return re.finalize(),yn=re.toHTML(),{language:r,value:yn,relevance:Qe,illegal:!1,_emitter:re,_top:O}}catch(p){if(p.message&&p.message.includes("Illegal"))return{language:r,value:En(S),illegal:!0,relevance:0,_illegalBy:{message:p.message,index:Ie,context:S.slice(Ie-100,Ie+100),mode:p.mode,resultSoFar:yn},_emitter:re};if(J)return{language:r,value:En(S),illegal:!1,relevance:0,errorRaised:p,_emitter:re,_top:O};throw p}}function hn(r){const S={value:En(r),illegal:!1,relevance:0,_top:N,_emitter:new m.__emitter(m)};return S._emitter.addText(r),S}function _n(r,S){S=S||m.languages||Object.keys(o);const D=hn(r),W=S.filter(Te).filter(it).map(pe=>Ke(pe,r,!1));W.unshift(D);const te=W.sort((pe,he)=>{if(pe.relevance!==he.relevance)return he.relevance-pe.relevance;if(pe.language&&he.language){if(Te(pe.language).supersetOf===he.language)return 1;if(Te(he.language).supersetOf===pe.language)return-1}return 0}),[me,Re]=te,Ve=me;return Ve.secondBest=Re,Ve}function ms(r,S,D){const W=S&&d[S]||D;r.classList.add("hljs"),r.classList.add(`language-${W}`)}function Nn(r){let S=null;const D=se(r);if(R(D))return;if(Xe("before:highlightElement",{el:r,language:D}),r.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",r);return}if(r.children.length>0&&(m.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(r)),m.throwUnescapedHTML))throw new bs("One of your code blocks includes unescaped HTML.",r.innerHTML);S=r;const W=S.textContent,te=D?ee(W,{language:D,ignoreIllegals:!0}):_n(W);r.innerHTML=te.value,r.dataset.highlighted="yes",ms(r,D,te.language),r.result={language:te.language,re:te.relevance,relevance:te.relevance},te.secondBest&&(r.secondBest={language:te.secondBest.language,relevance:te.secondBest.relevance}),Xe("after:highlightElement",{el:r,result:te,text:W})}function Es(r){m=et(m,r)}const hs=()=>{qe(),ke("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function _s(){qe(),ke("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let st=!1;function qe(){function r(){qe()}if(document.readyState==="loading"){st||window.addEventListener("DOMContentLoaded",r,!1),st=!0;return}document.querySelectorAll(m.cssSelector).forEach(Nn)}function Ns(r,S){let D=null;try{D=S(n)}catch(W){if(we("Language definition for '{}' could not be registered.".replace("{}",r)),J)we(W);else throw W;D=N}D.name||(D.name=r),o[r]=D,D.rawDefinition=S.bind(null,n),D.aliases&&at(D.aliases,{languageName:r})}function ys(r){delete o[r];for(const S of Object.keys(d))d[S]===r&&delete d[S]}function xs(){return Object.keys(o)}function Te(r){return r=(r||"").toLowerCase(),o[r]||o[d[r]]}function at(r,{languageName:S}){typeof r=="string"&&(r=[r]),r.forEach(D=>{d[D.toLowerCase()]=S})}function it(r){const S=Te(r);return S&&!S.disableAutodetect}function As(r){r["before:highlightBlock"]&&!r["before:highlightElement"]&&(r["before:highlightElement"]=S=>{r["before:highlightBlock"](Object.assign({block:S.el},S))}),r["after:highlightBlock"]&&!r["after:highlightElement"]&&(r["after:highlightElement"]=S=>{r["after:highlightBlock"](Object.assign({block:S.el},S))})}function Ss(r){As(r),w.push(r)}function Ts(r){const S=w.indexOf(r);S!==-1&&w.splice(S,1)}function Xe(r,S){const D=r;w.forEach(function(W){W[D]&&W[D](S)})}function Rs(r){return ke("10.7.0","highlightBlock will be removed entirely in v12.0"),ke("10.7.0","Please use highlightElement now."),Nn(r)}Object.assign(n,{highlight:ee,highlightAuto:_n,highlightAll:qe,highlightElement:Nn,highlightBlock:Rs,configure:Es,initHighlighting:hs,initHighlightingOnLoad:_s,registerLanguage:Ns,unregisterLanguage:ys,listLanguages:xs,getLanguage:Te,registerAliases:at,autoDetection:it,inherit:et,addPlugin:Ss,removePlugin:Ts}),n.debugMode=function(){J=!1},n.safeMode=function(){J=!0},n.versionString=ps,n.regex={concat:A,lookahead:c,either:C,optional:v,anyNumberOfTimes:f};for(const r in Me)typeof Me[r]=="object"&&e(Me[r]);return Object.assign(n,Me),n},De=tt({});return De.newInstance=()=>tt({}),Tn=De,De.HighlightJS=De,De.default=De,Tn}var Ia=wa();const z=Ps(Ia),ft="[A-Za-z$_][0-9A-Za-z$_]*",Oa=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends","using"],va=["true","false","null","undefined","NaN","Infinity"],Ot=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],vt=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],Mt=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],Ma=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],La=[].concat(Mt,Ot,vt);function Gn(e){const s=e.regex,a=(U,{after:ie})=>{const ue="</"+U[0].slice(1);return U.input.indexOf(ue,ie)!==-1},i=ft,g={begin:"<>",end:"</>"},E=/<[A-Za-z0-9\\._:-]+\s*\/>/,_={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(U,ie)=>{const ue=U[0].length+U.index,ce=U.input[ue];if(ce==="<"||ce===","){ie.ignoreMatch();return}ce===">"&&(a(U,{after:ue})||ie.ignoreMatch());let oe;const Ae=U.input.substring(ue);if(oe=Ae.match(/^\s*=/)){ie.ignoreMatch();return}if((oe=Ae.match(/^\s+extends\s+/))&&oe.index===0){ie.ignoreMatch();return}}},l={$pattern:ft,keyword:Oa,literal:va,built_in:La,"variable.language":Ma},h="[0-9](_?[0-9])*",u=`\\.(${h})`,y="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",T={className:"number",variants:[{begin:`(\\b(${y})((${u})|\\.)?|(${u}))[eE][+-]?(${h})\\b`},{begin:`\\b(${y})\\b((${u})\\b|\\.)?|(${u})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},c={className:"subst",begin:"\\$\\{",end:"\\}",keywords:l,contains:[]},f={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"xml"}},v={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"css"}},A={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"graphql"}},b={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,c]},B={className:"comment",variants:[e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:i+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},M=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,f,v,A,b,{match:/\$\d+/},T];c.contains=M.concat({begin:/\{/,end:/\}/,keywords:l,contains:["self"].concat(M)});const P=[].concat(B,c.contains),k=P.concat([{begin:/(\s*)\(/,end:/\)/,keywords:l,contains:["self"].concat(P)}]),q={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:k},ge={variants:[{match:[/class/,/\s+/,i,/\s+/,/extends/,/\s+/,s.concat(i,"(",s.concat(/\./,i),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,i],scope:{1:"keyword",3:"title.class"}}]},ae={relevance:0,match:s.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...Ot,...vt]}},ne={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},be={variants:[{match:[/function/,/\s+/,i,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[q],illegal:/%/},Ee={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function fe(U){return s.concat("(?!",U.join("|"),")")}const I={match:s.concat(/\b/,fe([...Mt,"super","import"].map(U=>`${U}\\s*\\(`)),i,s.lookahead(/\s*\(/)),className:"title.function",relevance:0},G={begin:s.concat(/\./,s.lookahead(s.concat(i,/(?![0-9A-Za-z$_(])/))),end:i,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},V={match:[/get|set/,/\s+/,i,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},q]},X="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",xe={match:[/const|var|let/,/\s+/,i,/\s*/,/=\s*/,/(async\s*)?/,s.lookahead(X)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[q]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:l,exports:{PARAMS_CONTAINS:k,CLASS_REFERENCE:ae},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),ne,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,f,v,A,b,B,{match:/\$\d+/},T,ae,{scope:"attr",match:i+s.lookahead(":"),relevance:0},xe,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[B,e.REGEXP_MODE,{className:"function",begin:X,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:k}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:g.begin,end:g.end},{match:E},{begin:_.begin,"on:begin":_.isTrulyOpeningTag,end:_.end}],subLanguage:"xml",contains:[{begin:_.begin,end:_.end,skip:!0,contains:["self"]}]}]},be,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[q,e.inherit(e.TITLE_MODE,{begin:i,className:"title.function"})]},{match:/\.\.\./,relevance:0},G,{match:"\\$"+i,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[q]},I,Ee,ge,V,{match:/\$[(.]/}]}}const rn="[A-Za-z$_][0-9A-Za-z$_]*",Lt=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends","using"],kt=["true","false","null","undefined","NaN","Infinity"],Dt=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],Bt=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],$t=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],Pt=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],Ut=[].concat($t,Dt,Bt);function ka(e){const s=e.regex,a=(U,{after:ie})=>{const ue="</"+U[0].slice(1);return U.input.indexOf(ue,ie)!==-1},i=rn,g={begin:"<>",end:"</>"},E=/<[A-Za-z0-9\\._:-]+\s*\/>/,_={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(U,ie)=>{const ue=U[0].length+U.index,ce=U.input[ue];if(ce==="<"||ce===","){ie.ignoreMatch();return}ce===">"&&(a(U,{after:ue})||ie.ignoreMatch());let oe;const Ae=U.input.substring(ue);if(oe=Ae.match(/^\s*=/)){ie.ignoreMatch();return}if((oe=Ae.match(/^\s+extends\s+/))&&oe.index===0){ie.ignoreMatch();return}}},l={$pattern:rn,keyword:Lt,literal:kt,built_in:Ut,"variable.language":Pt},h="[0-9](_?[0-9])*",u=`\\.(${h})`,y="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",T={className:"number",variants:[{begin:`(\\b(${y})((${u})|\\.)?|(${u}))[eE][+-]?(${h})\\b`},{begin:`\\b(${y})\\b((${u})\\b|\\.)?|(${u})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},c={className:"subst",begin:"\\$\\{",end:"\\}",keywords:l,contains:[]},f={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"xml"}},v={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"css"}},A={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,c],subLanguage:"graphql"}},b={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,c]},B={className:"comment",variants:[e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:i+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},M=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,f,v,A,b,{match:/\$\d+/},T];c.contains=M.concat({begin:/\{/,end:/\}/,keywords:l,contains:["self"].concat(M)});const P=[].concat(B,c.contains),k=P.concat([{begin:/(\s*)\(/,end:/\)/,keywords:l,contains:["self"].concat(P)}]),q={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:k},ge={variants:[{match:[/class/,/\s+/,i,/\s+/,/extends/,/\s+/,s.concat(i,"(",s.concat(/\./,i),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,i],scope:{1:"keyword",3:"title.class"}}]},ae={relevance:0,match:s.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...Dt,...Bt]}},ne={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},be={variants:[{match:[/function/,/\s+/,i,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[q],illegal:/%/},Ee={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function fe(U){return s.concat("(?!",U.join("|"),")")}const I={match:s.concat(/\b/,fe([...$t,"super","import"].map(U=>`${U}\\s*\\(`)),i,s.lookahead(/\s*\(/)),className:"title.function",relevance:0},G={begin:s.concat(/\./,s.lookahead(s.concat(i,/(?![0-9A-Za-z$_(])/))),end:i,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},V={match:[/get|set/,/\s+/,i,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},q]},X="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",xe={match:[/const|var|let/,/\s+/,i,/\s*/,/=\s*/,/(async\s*)?/,s.lookahead(X)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[q]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:l,exports:{PARAMS_CONTAINS:k,CLASS_REFERENCE:ae},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),ne,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,f,v,A,b,B,{match:/\$\d+/},T,ae,{scope:"attr",match:i+s.lookahead(":"),relevance:0},xe,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[B,e.REGEXP_MODE,{className:"function",begin:X,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:k}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:g.begin,end:g.end},{match:E},{begin:_.begin,"on:begin":_.isTrulyOpeningTag,end:_.end}],subLanguage:"xml",contains:[{begin:_.begin,end:_.end,skip:!0,contains:["self"]}]}]},be,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[q,e.inherit(e.TITLE_MODE,{begin:i,className:"title.function"})]},{match:/\.\.\./,relevance:0},G,{match:"\\$"+i,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[q]},I,Ee,ge,V,{match:/\$[(.]/}]}}function Wn(e){const s=e.regex,a=ka(e),i=rn,g=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],E={begin:[/namespace/,/\s+/,e.IDENT_RE],beginScope:{1:"keyword",3:"title.class"}},_={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:g},contains:[a.exports.CLASS_REFERENCE]},l={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},h=["type","interface","public","private","protected","implements","declare","abstract","readonly","enum","override","satisfies"],u={$pattern:rn,keyword:Lt.concat(h),literal:kt,built_in:Ut.concat(g),"variable.language":Pt},y={className:"meta",begin:"@"+i},T=(A,b,C)=>{const B=A.contains.findIndex(M=>M.label===b);if(B===-1)throw new Error("can not find mode to replace");A.contains.splice(B,1,C)};Object.assign(a.keywords,u),a.exports.PARAMS_CONTAINS.push(y);const c=a.contains.find(A=>A.scope==="attr"),f=Object.assign({},c,{match:s.concat(i,s.lookahead(/\s*\?:/))});a.exports.PARAMS_CONTAINS.push([a.exports.CLASS_REFERENCE,c,f]),a.contains=a.contains.concat([y,E,_,f]),T(a,"shebang",e.SHEBANG()),T(a,"use_strict",l);const v=a.contains.find(A=>A.label==="func.def");return v.relevance=0,Object.assign(a,{name:"TypeScript",aliases:["ts","tsx","mts","cts"]}),a}function Da(e){const s={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},a={match:/[{}[\],:]/,className:"punctuation",relevance:0},i=["true","false","null"],g={scope:"literal",beginKeywords:i.join(" ")};return{name:"JSON",aliases:["jsonc"],keywords:{literal:i},contains:[s,a,e.QUOTE_STRING_MODE,g,e.C_NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}function Ba(e){const s=e.regex,a="[a-zA-Z_][a-zA-Z0-9_.]*(!|\\?)?",i="[a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?",_={$pattern:a,keyword:["after","alias","and","case","catch","cond","defstruct","defguard","do","else","end","fn","for","if","import","in","not","or","quote","raise","receive","require","reraise","rescue","try","unless","unquote","unquote_splicing","use","when","with|0"],literal:["false","nil","true"]},l={className:"subst",begin:/#\{/,end:/\}/,keywords:_},h={className:"number",begin:"(\\b0o[0-7_]+)|(\\b0b[01_]+)|(\\b0x[0-9a-fA-F_]+)|(-?\\b[0-9][0-9_]*(\\.[0-9_]+([eE][-+]?[0-9]+)?)?)",relevance:0},y={match:/\\[\s\S]/,scope:"char.escape",relevance:0},T=`[/|([{<"']`,c=[{begin:/"/,end:/"/},{begin:/'/,end:/'/},{begin:/\//,end:/\//},{begin:/\|/,end:/\|/},{begin:/\(/,end:/\)/},{begin:/\[/,end:/\]/},{begin:/\{/,end:/\}/},{begin:/</,end:/>/}],f=k=>({scope:"char.escape",begin:s.concat(/\\/,k),relevance:0}),v={className:"string",begin:"~[a-z](?="+T+")",contains:c.map(k=>e.inherit(k,{contains:[f(k.end),y,l]}))},A={className:"string",begin:"~[A-Z](?="+T+")",contains:c.map(k=>e.inherit(k,{contains:[f(k.end)]}))},b={className:"regex",variants:[{begin:"~r(?="+T+")",contains:c.map(k=>e.inherit(k,{end:s.concat(k.end,/[uismxfU]{0,7}/),contains:[f(k.end),y,l]}))},{begin:"~R(?="+T+")",contains:c.map(k=>e.inherit(k,{end:s.concat(k.end,/[uismxfU]{0,7}/),contains:[f(k.end)]}))}]},C={className:"string",contains:[e.BACKSLASH_ESCAPE,l],variants:[{begin:/"""/,end:/"""/},{begin:/'''/,end:/'''/},{begin:/~S"""/,end:/"""/,contains:[]},{begin:/~S"/,end:/"/,contains:[]},{begin:/~S'''/,end:/'''/,contains:[]},{begin:/~S'/,end:/'/,contains:[]},{begin:/'/,end:/'/},{begin:/"/,end:/"/}]},B={className:"function",beginKeywords:"def defp defmacro defmacrop",end:/\B\b/,contains:[e.inherit(e.TITLE_MODE,{begin:a,endsParent:!0})]},M=e.inherit(B,{className:"class",beginKeywords:"defimpl defmodule defprotocol defrecord",end:/\bdo\b|$|;/}),P=[C,b,A,v,e.HASH_COMMENT_MODE,M,B,{begin:"::"},{className:"symbol",begin:":(?![\\s:])",contains:[C,{begin:i}],relevance:0},{className:"symbol",begin:a+":(?!:)",relevance:0},{className:"title.class",begin:/(\b[A-Z][a-zA-Z0-9_]+)/,relevance:0},h,{className:"variable",begin:"(\\$\\W)|((\\$|@@?)(\\w+))"}];return l.contains=P,{name:"Elixir",aliases:["ex","exs"],keywords:_,contains:P}}var $e="[0-9](_*[0-9])*",en=`\\.(${$e})`,nn="[0-9a-fA-F](_*[0-9a-fA-F])*",mt={className:"number",variants:[{begin:`(\\b(${$e})((${en})|\\.)?|(${en}))[eE][+-]?(${$e})[fFdD]?\\b`},{begin:`\\b(${$e})((${en})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${en})[fFdD]?\\b`},{begin:`\\b(${$e})[fFdD]\\b`},{begin:`\\b0[xX]((${nn})\\.?|(${nn})?\\.(${nn}))[pP][+-]?(${$e})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${nn})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function Ft(e,s,a){return a===-1?"":e.replace(s,i=>Ft(e,s,a-1))}function $a(e){const s=e.regex,a="[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*",i=a+Ft("(?:<"+a+"~~~(?:\\s*,\\s*"+a+"~~~)*>)?",/~~~/g,2),h={keyword:["synchronized","abstract","private","var","static","if","const ","for","while","strictfp","finally","protected","import","native","final","void","enum","else","break","transient","catch","instanceof","volatile","case","assert","package","default","public","try","switch","continue","throws","protected","public","private","module","requires","exports","do","sealed","yield","permits","goto","when"],literal:["false","true","null"],type:["char","boolean","long","float","int","byte","short","double"],built_in:["super","this"]},u={className:"meta",begin:"@"+a,contains:[{begin:/\(/,end:/\)/,contains:["self"]}]},y={className:"params",begin:/\(/,end:/\)/,keywords:h,relevance:0,contains:[e.C_BLOCK_COMMENT_MODE],endsParent:!0};return{name:"Java",aliases:["jsp"],keywords:h,illegal:/<\/|#/,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]}),{begin:/import java\.[a-z]+\./,keywords:"import",relevance:2},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{begin:/"""/,end:/"""/,className:"string",contains:[e.BACKSLASH_ESCAPE]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{match:[/\b(?:class|interface|enum|extends|implements|new)/,/\s+/,a],className:{1:"keyword",3:"title.class"}},{match:/non-sealed/,scope:"keyword"},{begin:[s.concat(/(?!else)/,a),/\s+/,a,/\s+/,/=(?!=)/],className:{1:"type",3:"variable",5:"operator"}},{begin:[/record/,/\s+/,a],className:{1:"keyword",3:"title.class"},contains:[y,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"new throw return else",relevance:0},{begin:["(?:"+i+"\\s+)",e.UNDERSCORE_IDENT_RE,/\s*(?=\()/],className:{2:"title.function"},keywords:h,contains:[{className:"params",begin:/\(/,end:/\)/,keywords:h,relevance:0,contains:[u,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,mt,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},mt,u]}}function jt(e){return e?typeof e=="string"?e:e.source:null}function He(e){return H("(?=",e,")")}function H(...e){return e.map(a=>jt(a)).join("")}function Pa(e){const s=e[e.length-1];return typeof s=="object"&&s.constructor===Object?(e.splice(e.length-1,1),s):{}}function de(...e){return"("+(Pa(e).capture?"":"?:")+e.map(i=>jt(i)).join("|")+")"}const Zn=e=>H(/\b/,e,/\w$/.test(e)?/\b/:/\B/),Ua=["Protocol","Type"].map(Zn),Et=["init","self"].map(Zn),Fa=["Any","Self"],Rn=["actor","any","associatedtype","async","await",/as\?/,/as!/,"as","borrowing","break","case","catch","class","consume","consuming","continue","convenience","copy","default","defer","deinit","didSet","distributed","do","dynamic","each","else","enum","extension","fallthrough",/fileprivate\(set\)/,"fileprivate","final","for","func","get","guard","if","import","indirect","infix",/init\?/,/init!/,"inout",/internal\(set\)/,"internal","in","is","isolated","nonisolated","lazy","let","macro","mutating","nonmutating",/open\(set\)/,"open","operator","optional","override","package","postfix","precedencegroup","prefix",/private\(set\)/,"private","protocol",/public\(set\)/,"public","repeat","required","rethrows","return","set","some","static","struct","subscript","super","switch","throws","throw",/try\?/,/try!/,"try","typealias",/unowned\(safe\)/,/unowned\(unsafe\)/,"unowned","var","weak","where","while","willSet"],ht=["false","nil","true"],ja=["assignment","associativity","higherThan","left","lowerThan","none","right"],Ka=["#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warning"],_t=["abs","all","any","assert","assertionFailure","debugPrint","dump","fatalError","getVaList","isKnownUniquelyReferenced","max","min","numericCast","pointwiseMax","pointwiseMin","precondition","preconditionFailure","print","readLine","repeatElement","sequence","stride","swap","swift_unboxFromSwiftValueWithType","transcode","type","unsafeBitCast","unsafeDowncast","withExtendedLifetime","withUnsafeMutablePointer","withUnsafePointer","withVaList","withoutActuallyEscaping","zip"],Kt=de(/[/=\-+!*%<>&|^~?]/,/[\u00A1-\u00A7]/,/[\u00A9\u00AB]/,/[\u00AC\u00AE]/,/[\u00B0\u00B1]/,/[\u00B6\u00BB\u00BF\u00D7\u00F7]/,/[\u2016-\u2017]/,/[\u2020-\u2027]/,/[\u2030-\u203E]/,/[\u2041-\u2053]/,/[\u2055-\u205E]/,/[\u2190-\u23FF]/,/[\u2500-\u2775]/,/[\u2794-\u2BFF]/,/[\u2E00-\u2E7F]/,/[\u3001-\u3003]/,/[\u3008-\u3020]/,/[\u3030]/),Ht=de(Kt,/[\u0300-\u036F]/,/[\u1DC0-\u1DFF]/,/[\u20D0-\u20FF]/,/[\uFE00-\uFE0F]/,/[\uFE20-\uFE2F]/),Cn=H(Kt,Ht,"*"),zt=de(/[a-zA-Z_]/,/[\u00A8\u00AA\u00AD\u00AF\u00B2-\u00B5\u00B7-\u00BA]/,/[\u00BC-\u00BE\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF]/,/[\u0100-\u02FF\u0370-\u167F\u1681-\u180D\u180F-\u1DBF]/,/[\u1E00-\u1FFF]/,/[\u200B-\u200D\u202A-\u202E\u203F-\u2040\u2054\u2060-\u206F]/,/[\u2070-\u20CF\u2100-\u218F\u2460-\u24FF\u2776-\u2793]/,/[\u2C00-\u2DFF\u2E80-\u2FFF]/,/[\u3004-\u3007\u3021-\u302F\u3031-\u303F\u3040-\uD7FF]/,/[\uF900-\uFD3D\uFD40-\uFDCF\uFDF0-\uFE1F\uFE30-\uFE44]/,/[\uFE47-\uFEFE\uFF00-\uFFFD]/),cn=de(zt,/\d/,/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE20-\uFE2F]/),Ne=H(zt,cn,"*"),tn=H(/[A-Z]/,cn,"*"),Ha=["attached","autoclosure",H(/convention\(/,de("swift","block","c"),/\)/),"discardableResult","dynamicCallable","dynamicMemberLookup","escaping","freestanding","frozen","GKInspectable","IBAction","IBDesignable","IBInspectable","IBOutlet","IBSegueAction","inlinable","main","nonobjc","NSApplicationMain","NSCopying","NSManaged",H(/objc\(/,Ne,/\)/),"objc","objcMembers","propertyWrapper","requires_stored_property_inits","resultBuilder","Sendable","testable","UIApplicationMain","unchecked","unknown","usableFromInline","warn_unqualified_access"],za=["iOS","iOSApplicationExtension","macOS","macOSApplicationExtension","macCatalyst","macCatalystApplicationExtension","watchOS","watchOSApplicationExtension","tvOS","tvOSApplicationExtension","swift"];function Ga(e){const s={match:/\s+/,relevance:0},a=e.COMMENT("/\\*","\\*/",{contains:["self"]}),i=[e.C_LINE_COMMENT_MODE,a],g={match:[/\./,de(...Ua,...Et)],className:{2:"keyword"}},E={match:H(/\./,de(...Rn)),relevance:0},_=Rn.filter(K=>typeof K=="string").concat(["_|0"]),l=Rn.filter(K=>typeof K!="string").concat(Fa).map(Zn),h={variants:[{className:"keyword",match:de(...l,...Et)}]},u={$pattern:de(/\b\w+/,/#\w+/),keyword:_.concat(Ka),literal:ht},y=[g,E,h],T={match:H(/\./,de(..._t)),relevance:0},c={className:"built_in",match:H(/\b/,de(..._t),/(?=\()/)},f=[T,c],v={match:/->/,relevance:0},A={className:"operator",relevance:0,variants:[{match:Cn},{match:`\\.(\\.|${Ht})+`}]},b=[v,A],C="([0-9]_*)+",B="([0-9a-fA-F]_*)+",M={className:"number",relevance:0,variants:[{match:`\\b(${C})(\\.(${C}))?([eE][+-]?(${C}))?\\b`},{match:`\\b0x(${B})(\\.(${B}))?([pP][+-]?(${C}))?\\b`},{match:/\b0o([0-7]_*)+\b/},{match:/\b0b([01]_*)+\b/}]},P=(K="")=>({className:"subst",variants:[{match:H(/\\/,K,/[0\\tnr"']/)},{match:H(/\\/,K,/u\{[0-9a-fA-F]{1,8}\}/)}]}),k=(K="")=>({className:"subst",match:H(/\\/,K,/[\t ]*(?:[\r\n]|\r\n)/)}),q=(K="")=>({className:"subst",label:"interpol",begin:H(/\\/,K,/\(/),end:/\)/}),ge=(K="")=>({begin:H(K,/"""/),end:H(/"""/,K),contains:[P(K),k(K),q(K)]}),ae=(K="")=>({begin:H(K,/"/),end:H(/"/,K),contains:[P(K),q(K)]}),ne={className:"string",variants:[ge(),ge("#"),ge("##"),ge("###"),ae(),ae("#"),ae("##"),ae("###")]},be=[e.BACKSLASH_ESCAPE,{begin:/\[/,end:/\]/,relevance:0,contains:[e.BACKSLASH_ESCAPE]}],Ee={begin:/\/[^\s](?=[^/\n]*\/)/,end:/\//,contains:be},fe=K=>{const Le=H(K,/\//),Ce=H(/\//,K);return{begin:Le,end:Ce,contains:[...be,{scope:"comment",begin:`#(?!.*${Ce})`,end:/$/}]}},I={scope:"regexp",variants:[fe("###"),fe("##"),fe("#"),Ee]},G={match:H(/`/,Ne,/`/)},V={className:"variable",match:/\$\d+/},X={className:"variable",match:`\\$${cn}+`},xe=[G,V,X],U={match:/(@|#(un)?)available/,scope:"keyword",starts:{contains:[{begin:/\(/,end:/\)/,keywords:za,contains:[...b,M,ne]}]}},ie={scope:"keyword",match:H(/@/,de(...Ha),He(de(/\(/,/\s+/)))},ue={scope:"meta",match:H(/@/,Ne)},ce=[U,ie,ue],oe={match:He(/\b[A-Z]/),relevance:0,contains:[{className:"type",match:H(/(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)/,cn,"+")},{className:"type",match:tn,relevance:0},{match:/[?!]+/,relevance:0},{match:/\.\.\./,relevance:0},{match:H(/\s+&\s+/,He(tn)),relevance:0}]},Ae={begin:/</,end:/>/,keywords:u,contains:[...i,...y,...ce,v,oe]};oe.contains.push(Ae);const ln={match:H(Ne,/\s*:/),keywords:"_|0",relevance:0},We={begin:/\(/,end:/\)/,relevance:0,keywords:u,contains:["self",ln,...i,I,...y,...f,...b,M,ne,...xe,...ce,oe]},je={begin:/</,end:/>/,keywords:"repeat each",contains:[...i,oe]},un={begin:de(He(H(Ne,/\s*:/)),He(H(Ne,/\s+/,Ne,/\s*:/))),end:/:/,relevance:0,contains:[{className:"keyword",match:/\b_\b/},{className:"params",match:Ne}]},Ze={begin:/\(/,end:/\)/,keywords:u,contains:[un,...i,...y,...b,M,ne,...ce,oe,We],endsParent:!0,illegal:/["']/},Yn={match:[/(func|macro)/,/\s+/,de(G.match,Ne,Cn)],className:{1:"keyword",3:"title.function"},contains:[je,Ze,s],illegal:[/\[/,/%/]},Me={match:[/\b(?:subscript|init[?!]?)/,/\s*(?=[<(])/],className:{1:"keyword"},contains:[je,Ze,s],illegal:/\[|%/},dn={match:[/operator/,/\s+/,Cn],className:{1:"keyword",3:"title"}},gn={begin:[/precedencegroup/,/\s+/,tn],className:{1:"keyword",3:"title"},contains:[oe],keywords:[...ja,...ht],end:/}/},pn={match:[/class\b/,/\s+/,/func\b/,/\s+/,/\b[A-Za-z_][A-Za-z0-9_]*\b/],scope:{1:"keyword",3:"keyword",5:"title.function"}},bn={match:[/class\b/,/\s+/,/var\b/],scope:{1:"keyword",3:"keyword"}},fn={begin:[/(struct|protocol|class|extension|enum|actor)/,/\s+/,Ne,/\s*/],beginScope:{1:"keyword",3:"title.class"},keywords:u,contains:[je,...y,{begin:/:/,end:/\{/,keywords:u,contains:[{scope:"title.class.inherited",match:tn},...y],relevance:0}]};for(const K of ne.variants){const Le=K.contains.find(mn=>mn.label==="interpol");Le.keywords=u;const Ce=[...y,...f,...b,M,ne,...xe];Le.contains=[...Ce,{begin:/\(/,end:/\)/,contains:["self",...Ce]}]}return{name:"Swift",keywords:u,contains:[...i,Yn,Me,pn,bn,fn,dn,gn,{beginKeywords:"import",end:/$/,contains:[...i],relevance:0},I,...y,...f,...b,M,ne,...xe,...ce,oe,We]}}function Gt(e){const s={className:"built_in",begin:"\\b(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)\\w+"},a=/[a-zA-Z@][a-zA-Z0-9_]*/,l={"variable.language":["this","super"],$pattern:a,keyword:["while","export","sizeof","typedef","const","struct","for","union","volatile","static","mutable","if","do","return","goto","enum","else","break","extern","asm","case","default","register","explicit","typename","switch","continue","inline","readonly","assign","readwrite","self","@synchronized","id","typeof","nonatomic","IBOutlet","IBAction","strong","weak","copy","in","out","inout","bycopy","byref","oneway","__strong","__weak","__block","__autoreleasing","@private","@protected","@public","@try","@property","@end","@throw","@catch","@finally","@autoreleasepool","@synthesize","@dynamic","@selector","@optional","@required","@encode","@package","@import","@defs","@compatibility_alias","__bridge","__bridge_transfer","__bridge_retained","__bridge_retain","__covariant","__contravariant","__kindof","_Nonnull","_Nullable","_Null_unspecified","__FUNCTION__","__PRETTY_FUNCTION__","__attribute__","getter","setter","retain","unsafe_unretained","nonnull","nullable","null_unspecified","null_resettable","class","instancetype","NS_DESIGNATED_INITIALIZER","NS_UNAVAILABLE","NS_REQUIRES_SUPER","NS_RETURNS_INNER_POINTER","NS_INLINE","NS_AVAILABLE","NS_DEPRECATED","NS_ENUM","NS_OPTIONS","NS_SWIFT_UNAVAILABLE","NS_ASSUME_NONNULL_BEGIN","NS_ASSUME_NONNULL_END","NS_REFINED_FOR_SWIFT","NS_SWIFT_NAME","NS_SWIFT_NOTHROW","NS_DURING","NS_HANDLER","NS_ENDHANDLER","NS_VALUERETURN","NS_VOIDRETURN"],literal:["false","true","FALSE","TRUE","nil","YES","NO","NULL"],built_in:["dispatch_once_t","dispatch_queue_t","dispatch_sync","dispatch_async","dispatch_once"],type:["int","float","char","unsigned","signed","short","long","double","wchar_t","unichar","void","bool","BOOL","id|0","_Bool"]},h={$pattern:a,keyword:["@interface","@class","@protocol","@implementation"]};return{name:"Objective-C",aliases:["mm","objc","obj-c","obj-c++","objective-c++"],keywords:l,illegal:"</",contains:[s,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,e.C_NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,{className:"string",variants:[{begin:'@"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]}]},{className:"meta",begin:/#\s*[a-z]+\b/,end:/$/,keywords:{keyword:"if else elif endif define undef warning error line pragma ifdef ifndef include"},contains:[{begin:/\\\n/,relevance:0},e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),{className:"string",begin:/<.*?>/,end:/$/,illegal:"\\n"},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{className:"class",begin:"("+h.keyword.join("|")+")\\b",end:/(\{|$)/,excludeEnd:!0,keywords:h,contains:[e.UNDERSCORE_TITLE_MODE]},{begin:"\\."+e.UNDERSCORE_IDENT_RE,relevance:0}]}}var Pe="[0-9](_*[0-9])*",sn=`\\.(${Pe})`,an="[0-9a-fA-F](_*[0-9a-fA-F])*",Wa={className:"number",variants:[{begin:`(\\b(${Pe})((${sn})|\\.)?|(${sn}))[eE][+-]?(${Pe})[fFdD]?\\b`},{begin:`\\b(${Pe})((${sn})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${sn})[fFdD]?\\b`},{begin:`\\b(${Pe})[fFdD]\\b`},{begin:`\\b0[xX]((${an})\\.?|(${an})?\\.(${an}))[pP][+-]?(${Pe})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${an})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function Wt(e){const s={keyword:"abstract as val var vararg get set class object open private protected public noinline crossinline dynamic final enum if else do while for when throw try catch finally import package is in fun override companion reified inline lateinit init interface annotation data sealed internal infix operator out by constructor super tailrec where const inner suspend typealias external expect actual",built_in:"Byte Short Char Int Long Boolean Float Double Void Unit Nothing",literal:"true false null"},a={className:"keyword",begin:/\b(break|continue|return|this)\b/,starts:{contains:[{className:"symbol",begin:/@\w+/}]}},i={className:"symbol",begin:e.UNDERSCORE_IDENT_RE+"@"},g={className:"subst",begin:/\$\{/,end:/\}/,contains:[e.C_NUMBER_MODE]},E={className:"variable",begin:"\\$"+e.UNDERSCORE_IDENT_RE},_={className:"string",variants:[{begin:'"""',end:'"""(?=[^"])',contains:[E,g]},{begin:"'",end:"'",illegal:/\n/,contains:[e.BACKSLASH_ESCAPE]},{begin:'"',end:'"',illegal:/\n/,contains:[e.BACKSLASH_ESCAPE,E,g]}]};g.contains.push(_);const l={className:"meta",begin:"@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\s*:(?:\\s*"+e.UNDERSCORE_IDENT_RE+")?"},h={className:"meta",begin:"@"+e.UNDERSCORE_IDENT_RE,contains:[{begin:/\(/,end:/\)/,contains:[e.inherit(_,{className:"string"}),"self"]}]},u=Wa,y=e.COMMENT("/\\*","\\*/",{contains:[e.C_BLOCK_COMMENT_MODE]}),T={variants:[{className:"type",begin:e.UNDERSCORE_IDENT_RE},{begin:/\(/,end:/\)/,contains:[]}]},c=T;return c.variants[1].contains=[T],T.variants[1].contains=[c],{name:"Kotlin",aliases:["kt","kts"],keywords:s,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"}]}),e.C_LINE_COMMENT_MODE,y,a,i,l,h,{className:"function",beginKeywords:"fun",end:"[(]|$",returnBegin:!0,excludeEnd:!0,keywords:s,relevance:5,contains:[{begin:e.UNDERSCORE_IDENT_RE+"\\s*\\(",returnBegin:!0,relevance:0,contains:[e.UNDERSCORE_TITLE_MODE]},{className:"type",begin:/</,end:/>/,keywords:"reified",relevance:0},{className:"params",begin:/\(/,end:/\)/,endsParent:!0,keywords:s,relevance:0,contains:[{begin:/:/,end:/[=,\/]/,endsWithParent:!0,contains:[T,e.C_LINE_COMMENT_MODE,y],relevance:0},e.C_LINE_COMMENT_MODE,y,l,h,_,e.C_NUMBER_MODE]},y]},{begin:[/class|interface|trait/,/\s+/,e.UNDERSCORE_IDENT_RE],beginScope:{3:"title.class"},keywords:"class interface trait",end:/[:\{(]|$/,excludeEnd:!0,illegal:"extends implements",contains:[{beginKeywords:"public protected internal private constructor"},e.UNDERSCORE_TITLE_MODE,{className:"type",begin:/</,end:/>/,excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:/[,:]\s*/,end:/[<\(,){\s]|$/,excludeBegin:!0,returnEnd:!0},l,h]},_,{className:"meta",begin:"^#!/usr/bin/env",end:"$",illegal:`
|
|
4
4
|
`},u]}}function Zt(e){const s=["package","import","option","optional","required","repeated","group","oneof"],a=["double","float","int32","int64","uint32","uint64","sint32","sint64","fixed32","fixed64","sfixed32","sfixed64","bool","string","bytes"],i={match:[/(message|enum|service)\s+/,e.IDENT_RE],scope:{1:"keyword",2:"title.class"}};return{name:"Protocol Buffers",aliases:["proto"],keywords:{keyword:s,type:a,literal:["true","false"]},contains:[e.QUOTE_STRING_MODE,e.NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,i,{className:"function",beginKeywords:"rpc",end:/[{;]/,excludeEnd:!0,keywords:"rpc returns"},{begin:/^\s*[A-Z_]+(?=\s*=[^\n]+;$)/}]}}function Yt(e){const s=e.regex,a=new RegExp("[\\p{XID_Start}_]\\p{XID_Continue}*","u"),i=["and","as","assert","async","await","break","case","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","match","nonlocal|10","not","or","pass","raise","return","try","while","with","yield"],l={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:i,built_in:["__import__","abs","all","any","ascii","bin","bool","breakpoint","bytearray","bytes","callable","chr","classmethod","compile","complex","delattr","dict","dir","divmod","enumerate","eval","exec","filter","float","format","frozenset","getattr","globals","hasattr","hash","help","hex","id","input","int","isinstance","issubclass","iter","len","list","locals","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","range","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","vars","zip"],literal:["__debug__","Ellipsis","False","None","NotImplemented","True"],type:["Any","Callable","Coroutine","Dict","List","Literal","Generic","Optional","Sequence","Set","Tuple","Type","Union"]},h={className:"meta",begin:/^(>>>|\.\.\.) /},u={className:"subst",begin:/\{/,end:/\}/,keywords:l,illegal:/#/},y={begin:/\{\{/,relevance:0},T={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,h],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,h],relevance:10},{begin:/([fF][rR]|[rR][fF]|[fF])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,h,y,u]},{begin:/([fF][rR]|[rR][fF]|[fF])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,h,y,u]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fF][rR]|[rR][fF]|[fF])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,y,u]},{begin:/([fF][rR]|[rR][fF]|[fF])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,y,u]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},c="[0-9](_?[0-9])*",f=`(\\b(${c}))?\\.(${c})|\\b(${c})\\.`,v=`\\b|${i.join("|")}`,A={className:"number",relevance:0,variants:[{begin:`(\\b(${c})|(${f}))[eE][+-]?(${c})[jJ]?(?=${v})`},{begin:`(${f})[jJ]?`},{begin:`\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${v})`},{begin:`\\b0[bB](_?[01])+[lL]?(?=${v})`},{begin:`\\b0[oO](_?[0-7])+[lL]?(?=${v})`},{begin:`\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${v})`},{begin:`\\b(${c})[jJ](?=${v})`}]},b={className:"comment",begin:s.lookahead(/# type:/),end:/$/,keywords:l,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},C={className:"params",variants:[{className:"",begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:["self",h,A,T,e.HASH_COMMENT_MODE]}]};return u.contains=[T,A,h],{name:"Python",aliases:["py","gyp","ipython"],unicodeRegex:!0,keywords:l,illegal:/(<\/|\?)|=>/,contains:[h,A,{scope:"variable.language",match:/\bself\b/},{beginKeywords:"if",relevance:0},{match:/\bor\b/,scope:"keyword"},T,b,e.HASH_COMMENT_MODE,{match:[/\bdef/,/\s+/,a],scope:{1:"keyword",3:"title.function"},contains:[C]},{variants:[{match:[/\bclass/,/\s+/,a,/\s*/,/\(\s*/,a,/\s*\)/]},{match:[/\bclass/,/\s+/,a]}],scope:{1:"keyword",3:"title.class",6:"title.class.inherited"}},{className:"meta",begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[A,C,T]}]}}function qt(e){const s="true false yes no null",a="[\\w#;/?:@&=+$,.~*'()[\\]]+",i={className:"attr",variants:[{begin:/[\w*@][\w*@ :()\./-]*:(?=[ \t]|$)/},{begin:/"[\w*@][\w*@ :()\./-]*":(?=[ \t]|$)/},{begin:/'[\w*@][\w*@ :()\./-]*':(?=[ \t]|$)/}]},g={className:"template-variable",variants:[{begin:/\{\{/,end:/\}\}/},{begin:/%\{/,end:/\}/}]},E={className:"string",relevance:0,begin:/'/,end:/'/,contains:[{match:/''/,scope:"char.escape",relevance:0}]},_={className:"string",relevance:0,variants:[{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,g]},l=e.inherit(_,{variants:[{begin:/'/,end:/'/,contains:[{begin:/''/,relevance:0}]},{begin:/"/,end:/"/},{begin:/[^\s,{}[\]]+/}]}),c={className:"number",begin:"\\b"+"[0-9]{4}(-[0-9][0-9]){0,2}"+"([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?"+"(\\.[0-9]*)?"+"([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?"+"\\b"},f={end:",",endsWithParent:!0,excludeEnd:!0,keywords:s,relevance:0},v={begin:/\{/,end:/\}/,contains:[f],illegal:"\\n",relevance:0},A={begin:"\\[",end:"\\]",contains:[f],illegal:"\\n",relevance:0},b=[i,{className:"meta",begin:"^---\\s*$",relevance:10},{className:"string",begin:"[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*"},{begin:"<%[%=-]?",end:"[%-]?%>",subLanguage:"ruby",excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:"!\\w+!"+a},{className:"type",begin:"!<"+a+">"},{className:"type",begin:"!"+a},{className:"type",begin:"!!"+a},{className:"meta",begin:"&"+e.UNDERSCORE_IDENT_RE+"$"},{className:"meta",begin:"\\*"+e.UNDERSCORE_IDENT_RE+"$"},{className:"bullet",begin:"-(?=[ ]|$)",relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:s,keywords:{literal:s}},c,{className:"number",begin:e.C_NUMBER_RE+"\\b",relevance:0},v,A,E,_],C=[...b];return C.pop(),C.push(l),f.contains=C,{name:"YAML",case_insensitive:!0,aliases:["yml"],contains:b}}function Xt(e){return{name:"Shell Session",aliases:["console","shellsession"],contains:[{className:"meta.prompt",begin:/^\s{0,3}[/~\w\d[\]()@-]*[>%$#][ ]?/,starts:{end:/[^\\](?=\s*$)/,subLanguage:"bash"}}]}}function Vt(e){const s=e.regex;return{name:"Diff",aliases:["patch"],contains:[{className:"meta",relevance:10,match:s.either(/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,/^\*\*\* +\d+,\d+ +\*\*\*\*$/,/^--- +\d+,\d+ +----$/)},{className:"comment",variants:[{begin:s.either(/Index: /,/^index/,/={3,}/,/^-{3}/,/^\*{3} /,/^\+{3}/,/^diff --git/),end:/$/},{match:/^\*{15}$/}]},{className:"addition",begin:/^\+/,end:/$/},{className:"deletion",begin:/^-/,end:/$/},{className:"addition",begin:/^!/,end:/$/}]}}function Jt(e){return{name:"Plain text",aliases:["text","txt"],disableAutodetect:!0}}function Za(e){const s=e.regex,a={begin:/<\/?[A-Za-z_]/,end:">",subLanguage:"xml",relevance:0},i={begin:"^[-\\*]{3,}",end:"$"},g={className:"code",variants:[{begin:"(`{3,})[^`](.|\\n)*?\\1`*[ ]*"},{begin:"(~{3,})[^~](.|\\n)*?\\1~*[ ]*"},{begin:"```",end:"```+[ ]*$"},{begin:"~~~",end:"~~~+[ ]*$"},{begin:"`.+?`"},{begin:"(?=^( {4}|\\t))",contains:[{begin:"^( {4}|\\t)",end:"(\\n)$"}],relevance:0}]},E={className:"bullet",begin:"^[ ]*([*+-]|(\\d+\\.))(?=\\s+)",end:"\\s+",excludeEnd:!0},_={begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:"symbol",begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:"link",begin:/:\s*/,end:/$/,excludeBegin:!0}]},l=/[A-Za-z][A-Za-z0-9+.-]*/,h={variants:[{begin:/\[.+?\]\[.*?\]/,relevance:0},{begin:/\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,relevance:2},{begin:s.concat(/\[.+?\]\(/,l,/:\/\/.*?\)/),relevance:2},{begin:/\[.+?\]\([./?&#].*?\)/,relevance:1},{begin:/\[.*?\]\(.*?\)/,relevance:0}],returnBegin:!0,contains:[{match:/\[(?=\])/},{className:"string",relevance:0,begin:"\\[",end:"\\]",excludeBegin:!0,returnEnd:!0},{className:"link",relevance:0,begin:"\\]\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0},{className:"symbol",relevance:0,begin:"\\]\\[",end:"\\]",excludeBegin:!0,excludeEnd:!0}]},u={className:"strong",contains:[],variants:[{begin:/_{2}(?!\s)/,end:/_{2}/},{begin:/\*{2}(?!\s)/,end:/\*{2}/}]},y={className:"emphasis",contains:[],variants:[{begin:/\*(?![*\s])/,end:/\*/},{begin:/_(?![_\s])/,end:/_/,relevance:0}]},T=e.inherit(u,{contains:[]}),c=e.inherit(y,{contains:[]});u.contains.push(c),y.contains.push(T);let f=[a,h];return[u,y,T,c].forEach(C=>{C.contains=C.contains.concat(f)}),f=f.concat(u,y),{name:"Markdown",aliases:["md","mkdown","mkd"],contains:[{className:"section",variants:[{begin:"^#{1,6}",end:"$",contains:f},{begin:"(?=^.+?\\n[=-]{2,}$)",contains:[{begin:"^[=-]*$"},{begin:"^",end:"\\n",contains:f}]}]},a,E,u,y,{className:"quote",begin:"^>\\s+",contains:f,end:"$"},g,i,h,_,{scope:"literal",match:/&([a-zA-Z0-9]+|#[0-9]{1,7}|#[Xx][0-9a-fA-F]{1,6});/}]}}const Ya=ve("div")`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{aF as Ge,j as e,bn as gt,r as g,bD as J,bf as H,H as q,aH as D,g as xt,o as d,h as ee,at as bt,ay as jt,K as C,T as U,V as Q,eO as Fe,O as Pe,ik as Ye,bj as Te,aU as Ie,R as Ee,bA as Ne,b3 as qe,b1 as Ae,C as Je,f as Qe,f0 as Xe,aP as De,W as yt,as as Ze,il as et,v as Oe,f2 as tt,bq as je,fJ as st,dD as St,s as ie,af as pe,G as Ue,au as vt,im as Ct,io as Nt,$ as nt,ip as wt,iq as Rt,ir as Tt,is as It,N as Et,bx as it,E as At,J as Dt,P as Ot,S as Lt,Q as $e,it as kt,a3 as Ft}from"./index-2c1VoOd9.js";import{d as Pt,H as at,g as _t}from"./index-CZVLqYhR.js";import{R as _e,S as Bt}from"./actions-e0cgLZ3F.js";import{B as zt}from"./index-C3PPN1sd.js";import{S as me}from"./shorten-label-azqzn6Q0.js";import{v as ot}from"./index-BNQ03H5g.js";import{T as Wt}from"./html-title-BQwqe1Ck.js";import{R as Mt}from"./Refresh-kyiL1qX1.js";import{D as Kt,g as Ht}from"./traffic-Dk3MPYPo.js";import{u as qt}from"./use-mobile-DehCuxqg.js";import"./FilterList-DqZHJbRG.js";import"./CSSTransition-C6uS6QtZ.js";import"./emotion-cache.browser.esm-BLI6o2QB.js";import"./index-D6WMVz-u.js";import"./redux-DfszZyTl.js";import"./typeof-QjJsDpFa.js";import"./depsEqual-DJ4V1mTU.js";import"./index-DOFLIkPm.js";import"./TableSearch-BQiqRB7D.js";import"./Search-BiQ8hlgr.js";import"./Clear-CFi5u92e.js";import"./MoreVert-Ck4O28kx.js";import"./useLocalStorage-C5c8IOKv.js";import"./url-evaluation-CKpb4hS-.js";import"./get-safe-url-CHuz2b-I.js";import"./ButtonGroup-B_6MNBFc.js";import"./getValidReactChildren-C8GIEouH.js";import"./permission-Dh9Y-pMK.js";import"./index.esm-CgpVcU8p.js";import"./collapse-DRRC0SCd.js";import"./blocklet-Cu8go6Cl.js";import"./Switch-UORzToTA.js";import"./iframe-9SAgwJDT.js";import"./ChevronLeft-C7cSHp9l.js";import"./ChevronRight-BUUZmp3v.js";import"./index-DBii9-f-.js";import"./base-chart-Do9WtdQs.js";import"./index-IfVDnuZk.js";import"./AdapterDayjs-jQWZxlKZ.js";import"./useThemeProps-Ddo6kYr5.js";import"./visuallyHidden-Dan1xhjv.js";const Ut=Ge(e.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2M4 12c0-4.42 3.58-8 8-8 1.85 0 3.55.63 4.9 1.69L5.69 16.9C4.63 15.55 4 13.85 4 12m8 8c-1.85 0-3.55-.63-4.9-1.69L18.31 7.1C19.37 8.45 20 10.15 20 12c0 4.42-3.58 8-8 8"})),$t=Ge(e.jsx("path",{d:"M16.59 7.58 10 14.17l-3.59-3.58L5 12l5 5 8-8zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"})),rt=g.createContext({}),{Provider:Vt,Consumer:on}=rt;function Gt({children:t,blocklet:s=""}){const{api:n,inService:r,ws:{useSubscription:o}}=gt(),[l,x]=g.useState([]),[f,y]=g.useState({total:0,pageSize:20,pageCount:0,page:1}),h=J(()=>s.meta?.did,[s]),[b,S]=g.useState([]),[B,_]=g.useState({}),R=J(()=>l.length?new Set(l.map(m=>m.id)):new Set,[l]),$=async({page:m=1,pageSize:N=20,...O}={})=>{if(!h)return[];try{const A={paging:{page:m,pageSize:N},...O,teamDid:h,dateRange:O.dateRange?[H(O.dateRange[0]).toISOString(),H(O.dateRange[1]).toISOString()]:void 0},{dids:w,...L}=A;let P="";w&&w.includes("system")&&(P="system");const ae=w?w.filter(oe=>oe!=="system"):[],se={...L,source:P,componentDids:ae},Z=await n.getNotificationSendLog({input:se});return _(se),x(Z.list),y(Z.paging),Z.list}catch(A){return q.error(A.message),[]}},M=async()=>{const m=await n.getNotificationComponents({input:{teamDid:h}});S(m.componentDids)},k=g.useCallback(m=>{const N=s.children.find(O=>O.meta?.did===m);if(N)return N.ancestors=[s],N},[s]),F=async({notificationId:m,receivers:N,channels:O,...A})=>{await n.resendNotification({input:{teamDid:h,notificationId:m,receivers:N,channels:O.map(w=>w==="wallet"?D.NOTIFICATION_SEND_CHANNEL.WALLET:w==="pushKit"?D.NOTIFICATION_SEND_CHANNEL.PUSH:w),...A}})},V=g.useCallback(async m=>(await n.getUser({input:{teamDid:h,user:{did:m},options:{enableConnectedAccount:!0}}})).user,[n,h]),G=g.useCallback(async({page:m=1,pageSize:N=20,...O}={})=>{try{const A={paging:{page:m,pageSize:N},...O,userName:O.searchText||"",teamDid:h,dateRange:O.dateRange?[H(O.dateRange[0]).toISOString(),H(O.dateRange[1]).toISOString()]:void 0};return await n.getReceivers({input:A})}catch(A){throw q.error(A.message),A}},[n,h]);g.useEffect(()=>{h&&M()},[h]),o(D.EVENTS.NOTIFICATION_BLOCKLET_UPDATE,m=>{R.has(m.notificationId)&&$(B)},[R,B]),o(D.EVENTS.NOTIFICATION_BLOCKLET_CREATE,m=>{R.has(m.id)||$(B)},[R,B]);const X={fetch:$,data:l,paging:f,blocklet:s,getComponent:k,resendNotification:F,getUser:V,componentDids:b,getReceivers:G,inService:r,teamDid:h};return e.jsx(Vt,{value:{notificationRecords:X},children:t})}function Be(){const{notificationRecords:t}=g.useContext(rt);return t}he.propTypes={severity:d.oneOf(Object.values(["info","success","error","warning"])).isRequired};const Yt={info:"primary",success:"success",error:"error",warning:"warning"};function he({severity:t="info"}){return e.jsx(xt,{type:Yt[t],children:t})}const Jt=(t,s,n="")=>{if(!n||!s)return"";switch(n){case D.NOTIFICATION_SEND_FAILED_REASON.USER_DISABLED:return t("notification.sendStatus.reason.disabled",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.CHANNEL_UNAVAILABLE:return t("notification.sendStatus.reason.unavailable",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.CHANNEL_DISABLED:return t("notification.sendStatus.reason.notSent",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.NOT_ONLINE:return t("notification.sendStatus.reason.offline");default:return n}};function lt(t,s,n={}){const{status:r,updatedAt:o,reason:l="",channel:x="wallet"}=n,f=o?t("notification.sendStatus.sentTime",{date:bt(o,s)}):"",y=Jt(t,x,l);return r===D.NOTIFICATION_SEND_STATUS.FAILED?{status:"failed",title:t("notification.sendStatus.failed"),sentTime:f,reason:y}:r===D.NOTIFICATION_SEND_STATUS.SENT?{status:"success",title:t("notification.sendStatus.success"),sentTime:f}:{status:"pending",title:t("notification.sendStatus.pending"),reason:y,sentTime:f}}const Le={pending:"#aaaaaa",success:"#34BE74",failed:"#D0021B"},ke=["wallet","pushKit","email"],Ve=["info","success","error","warning"],ct=t=>{const{settings:s}=t;return s?.notification?.email?.enabled},dt=t=>{const{settings:s}=t;return s?.notification?.pushKit?.enabled},Qt=(t,s)=>{const n=ee(s,"extra.notifications.email",!0);return{available:ct(t),enabled:n}},Xt=(t,s)=>{const n=ee(s,"extra.notifications.push",!0);return{available:dt(t),enabled:n}},Zt=t=>({enabled:ee(t,"extra.notifications.wallet",!0)}),es=t=>({enabled:ee(t,"extra.webhooks",[]).length>0}),xe=(t=3)=>new Promise(s=>{setTimeout(()=>{s()},t*1e3)}),ts=(t,s)=>s==="wallet"||s==="webhook"?[{channel:s,type:"enabled",pass:t("notification.sendStatus.reason.enabled",{channel:s}),fail:t("notification.sendStatus.reason.disabled",{channel:s})}]:s==="pushKit"||s==="email"?[{channel:s,type:"available",pass:t("notification.sendStatus.reason.available",{channel:s}),fail:t("notification.sendStatus.reason.unavailable",{channel:s})},{channel:s,type:"enabled",pass:t("notification.sendStatus.reason.enabled",{channel:s}),fail:t("notification.sendStatus.reason.disabled",{channel:s})}]:[],be=(t=[])=>{const s=H().startOf("day");return t.filter(n=>H(n.sendAt).isSame(s,"day")).length},ss=(t,s="")=>{if(s&&ke.includes(s)){const l=`${s}SendRecord`,x=ee(t,l,[]);return be(x)}const n=ee(t,"webhook",{}),r=Object.keys(n??{})??[];if(s&&r.includes(s)){const l=n[s]??[];return be(l)}const o={};return ke.forEach(l=>{const x=`${l}SendRecord`,f=ee(t,x,[]),y=be(f);o[l]=y}),r.length>0&&r.forEach(l=>{const x=n[l]??[],f=be(x);o[l]=f}),o},ye=(t,s,n)=>{if(!Array.isArray(t))throw new Error("Invalid filterList or index");return t[n].splice(s,1),t},Se=(t,s)=>{if(!Array.isArray(s))throw new Error("filters must be an array");return s.length?!s.includes(t):!1},ns=t=>{switch(t){case D.NOTIFICATION_SEND_CHANNEL.WALLET:return"Wallet";case D.NOTIFICATION_SEND_CHANNEL.PUSH:return"Push Kit";case D.NOTIFICATION_SEND_CHANNEL.EMAIL:return"Email";case D.NOTIFICATION_SEND_CHANNEL.WEBHOOK:return"Webhook";default:return""}},ut=()=>({components:{MUIDataTableFilter:{styleOverrides:{header:{marginBottom:0,p:{margin:0}},root:{"& .MuiGrid-container":{marginTop:0,"& .MuiGrid-item":{paddingTop:0}}}}},MuiPopover:{styleOverrides:{root:{"&.MuiPopover-root":{"& .MuiPaper-root:has(.filter-container)":{width:"420px"}}}}}}});function te({config:t,enableTooltip:s=!0,showTitle:n=!1,children:r=null}){const{status:o,title:l="",sentTime:x="",reason:f=""}=t,y=[l,f].filter(Boolean).join(", ");return e.jsx(jt,{title:s?e.jsxs(e.Fragment,{children:[e.jsx(U,{color:"inherit",sx:{fontSize:12},children:y}),e.jsx("span",{children:x})]}):null,arrow:!0,placement:"top",children:e.jsxs(C,{sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px"},children:[e.jsxs(C,{sx:{position:"relative",minHeight:14,minWidth:14,display:"flex",alignItems:"center",justifyContent:"center"},children:[e.jsx(C,{style:{opacity:.15},sx:{position:"absolute",width:"100%",height:"100%",borderRadius:"50%",bgcolor:Le[o]}}),e.jsx(C,{sx:{position:"absolute",width:"55%",height:"55%",borderRadius:"50%",bgcolor:Le[o]}})]}),e.jsx(U,{color:"inherit",sx:{fontSize:12},children:n?l:r})]})})}te.propTypes={config:d.object.isRequired,enableTooltip:d.bool,showTitle:d.bool,children:d.node};ve.propTypes={list:d.array.isRequired,label:d.string.isRequired,onDelete:d.func};function ve({list:t,label:s,onDelete:n=()=>{}}){const{t:r,locale:o}=Q();return e.jsxs(C,{sx:{display:"flex",gap:1,alignItems:"center"},children:[e.jsxs(U,{children:[s,": "]}),t.map(l=>{const x=lt(r,o,{status:l});return e.jsx(Fe,{size:"small",label:e.jsx(C,{sx:{display:"flex",alignItems:"center",gap:"4px"},children:e.jsx(te,{config:x,enableTooltip:!1,children:x.title})}),onDelete:f=>n(f,l)},l)})]})}ze.propTypes={filterList:d.array.isRequired,onChange:d.func.isRequired,index:d.number.isRequired,column:d.object.isRequired,filterValues:d.array.isRequired,label:d.string.isRequired,renderLabel:d.func.isRequired};function ze({filterList:t,onChange:s,index:n,column:r,filterValues:o,label:l,renderLabel:x}){return e.jsxs(Pe,{className:"filter-container",children:[e.jsx(Ye,{component:"legend",children:l}),e.jsx(Te,{row:!0,children:o.map(f=>e.jsx(Ie,{control:e.jsx(Ee,{checked:t[n].indexOf(f.value??f)>-1,onChange:y=>{const h=[...t];y.target.checked?h[n]=[...h[n],f.value??f]:h[n]=h[n].filter(b=>b!==(f.value??f)),s(h[n],n,r)},name:f.value??f}),label:e.jsx("span",{style:{display:"flex",alignItems:"center"},children:x(f)})},f.value??f))})]})}function Re(t){return e.jsx(ze,{...t,renderLabel:s=>e.jsx(te,{enableTooltip:!1,config:{status:s.status},children:s.label})})}ce.propTypes={status:d.number.isRequired,updatedAt:d.string.isRequired,reason:d.string,channel:d.string,onResend:d.func};function ce({status:t,updatedAt:s,reason:n="",channel:r="wallet",onResend:o}){const{t:l,locale:x}=Q(),f=lt(l,x,{status:t,updatedAt:s,reason:n,channel:r});return e.jsxs(C,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx(te,{config:f,showTitle:!0}),f.status!=="success"&&e.jsx(Ne,{className:"resend-btn",size:"small",startIcon:e.jsx(_e,{}),sx:{fontSize:12,color:"rgba(0, 0, 0, 0.87)",fontWeight:400,".MuiButton-startIcon":{mr:"2px"}},onClick:o,children:l("notification.resend")})]})}We.propTypes={value:d.array.isRequired,onChange:d.func};function We({value:t,onChange:s}){const{locale:n}=Q(),r=H().toDate(),[o,l]=g.useState(null),x=g.useCallback(h=>{l(o?null:h.currentTarget)},[o]),f=!!o,y=g.useCallback(h=>{if(!h.startDate||!h.endDate){q.error("Please select a date range");return}if(H(h.startDate).isAfter(h.endDate)||!H(h.startDate).isValid()||!H(h.endDate).isValid()){q.error("Invalid date range");return}s([h.startDate,h.endDate]),l(null)},[s]);return e.jsxs("div",{children:[e.jsx(U,{component:"div",variant:"h5",color:"textPrimary",style:{fontSize:18,fontWeight:"bold"},sx:{mb:0},children:e.jsxs(Ne,{onClick:x,variant:"outlined",size:"small",color:"inherit",children:[qe(t[0],n)," - ",qe(t[1],n)]})}),e.jsx(Ae,{open:f,anchorEl:o,onClose:()=>{l(null)},anchorOrigin:{vertical:"bottom",horizontal:"left"},children:e.jsx(Kt,{open:!0,maxDate:r,initialDateRange:{startDate:t[0],endDate:t[1]},toggle:x,definedRanges:Ht(r),onChange:y})})]})}Me.propTypes={itemComponent:d.elementType.isRequired};function Me({itemComponent:t,...s}){const{t:n}=Q();return!s?.filterList?.filter(o=>o.length).length?null:e.jsxs(C,{sx:{display:"flex",gap:1,alignItems:"center"},children:[e.jsx("div",{className:"toolbar-filter-title",children:n("notification.filter")}),e.jsx("div",{className:"toolbar-filter-content",children:e.jsx(Pt.TableFilterList,{...s,ItemComponent:t})})]})}function Ke({label:t,onDelete:s,canDelete:n=()=>!0,...r}){const o=s&&typeof s=="function"?s:void 0;let l=!0;return n&&typeof n=="function"&&(l=n({label:t,...r})),e.jsx(Fe,{label:t,variant:"outlined",...o&&l?{onDelete:o}:{}})}Ke.propTypes={label:d.string.isRequired,onDelete:d.func,canDelete:d.func};const is=[{label:"Wallet",value:"app",checked:!0},{label:"Email",value:"email",checked:!0},{label:"Push Kit",value:"push",checked:!0},{label:"Webhook",value:"webhook",checked:!0}];pt.propTypes={loading:d.bool,onCancel:d.func,onConfirm:d.func};function pt({loading:t=!1,onCancel:s=()=>{},onConfirm:n=()=>{}}){const{t:r}=Q(),[o,l]=g.useState(is),[x,f]=g.useState(!0),y=(b,S)=>{S.checked=b.target.checked;const B=o.map(_=>({..._,checked:_.value===S.value?S.checked:_.checked}));l(B)},h=b=>{b.stopPropagation(),n({channels:o.filter(S=>S.checked).map(S=>S.value),isResendFailedOnly:x})};return e.jsxs(C,{className:"resend-config",sx:{padding:"16px 24px"},children:[e.jsx(U,{variant:"body1",component:"div",className:"check-title",sx:{fontWeight:700,mb:1},children:r("notification.config")}),e.jsx(C,{className:"choose-channel",children:e.jsxs(Pe,{component:"fieldset",variant:"standard",children:[e.jsx(Ye,{component:"legend",children:r("notification.selectChannels")}),e.jsx(Te,{sx:{display:"flex",flexDirection:"row",flexWrap:"wrap",gap:1},children:o.map(b=>e.jsx(Ie,{control:e.jsx(Ee,{checked:b.checked,onChange:S=>y(S,b),name:b.value}),label:b.label},b.value))})]})}),e.jsx(C,{className:"resend-config-footer",children:e.jsx(Te,{children:e.jsx(Ie,{control:e.jsx(Ee,{checked:x,onChange:b=>f(b.target.checked)}),label:r("notification.resendFailedOnly")})})}),e.jsxs(C,{className:"resend-config-footer-tip",sx:{display:"flex",justifyContent:"flex-end",gap:1},children:[e.jsx(Ne,{onClick:b=>{b.stopPropagation(),s()},color:"inherit",children:r("common.cancel")}),e.jsxs(Ne,{onClick:h,color:"primary",disabled:t,variant:"contained",autoFocus:!0,style:{marginLeft:8},children:[t&&e.jsx(Je,{size:16}),r("common.confirm")]})]})]})}ft.propTypes={notificationId:d.string.isRequired,handleResend:d.func,resending:d.bool};function ft({notificationId:t,handleResend:s,resending:n=!1}){const{t:r,locale:o}=Q(),l=Qe(),x=g.useMemo(()=>Xe(l,ut()),[l]),{getReceivers:f,inService:y,teamDid:h,getUser:b,blocklet:S}=Be(),[B,_]=g.useState(!1),[R,$]=g.useState([]),M=De({anchorEl:null,position:null}),k=De({anchorEl:null,position:null}),[F,V]=g.useState(null),[G,X]=g.useState({total:0,pageSize:10,pageCount:0,page:1}),[m,N]=g.useState({searchText:"",page:1,pageSize:10,walletSendStatus:[],pushKitSendStatus:[],emailSendStatus:[],dateRange:[H().subtract(1,"month").startOf("day").toDate(),H().endOf("day").toDate()]}),[O,A]=g.useState([]),w=[{label:r("notification.sendStatus.pending"),value:0,status:"pending"},{label:r("notification.sendStatus.success"),value:1,status:"success"},{label:r("notification.sendStatus.failed"),value:2,status:"failed"}],L=async()=>{if(!B&&t)try{_(!0);const i=await f({notificationId:t,...m}),a=i.list.map(c=>({...c,receiverUser:{...c.receiverUser,avatar:st(c.receiverUser.avatar,h,y)}}));$(a),X(i.paging),_(!1)}catch(i){q.error(i.message),_(!1)}};g.useEffect(()=>{L()},[m]);const P=i=>{i.stopPropagation();const a=i.currentTarget;k.anchorEl=a;const c=a.getBoundingClientRect();k.position={top:c.top+window.scrollY,left:c.left+window.scrollX}},ae=i=>i.data.length?e.jsx("div",{style:{display:"flex",alignItems:"center",padding:"10px"},children:e.jsx(Oe,{className:"resend-btn",size:"small",color:"primary",variant:"contained",startIcon:e.jsx(_e,{}),sx:{".MuiButton-startIcon":{mr:"2px"}},onClick:P,children:r("notification.resend")})}):null,se={sort:!1,download:!1,print:!1,selectableRows:"multiple",searchPlaceholder:r("common.search"),searchAlwaysOpen:!1,filterType:"checkbox",searchDebounceTime:300,page:G.page-1,rowsPerPage:G.pageSize,count:G.total,searchText:m.searchText,tableBodyMaxHeight:"calc(80vh - 260px)",rowsSelected:O,onRowSelectionChange:(i,a)=>{A(a.map(c=>c.dataIndex))},customToolbarSelect:ae},Z=({page:i,rowsPerPage:a,searchText:c,filterList:v})=>{const[,z=[],Y=[],K=[]]=v;m.pageSize!==a?N(W=>({...W,pageSize:a,page:1})):m.page!==i+1?N(W=>({...W,page:i+1})):m.searchText!==c?N(W=>({...W,searchText:c,page:1})):pe(z,m.walletSendStatus)?pe(Y,m.pushKitSendStatus)?pe(K,m.emailSendStatus)||N(W=>({...W,emailSendStatus:K,page:1})):N(W=>({...W,pushKitSendStatus:Y,page:1})):N(W=>({...W,walletSendStatus:z,page:1}))},oe=g.useCallback(async(i,a)=>{if(!a)return!1;const c=await b(a);return c?i==="wallet"?Zt(c):i==="email"?Qt(S,c):i==="pushKit"?Xt(S,c):i==="webhook"?es(c):!0:!1},[b,S]),we=g.useCallback(i=>ts(r,i),[r]),ne=()=>{M.anchorEl=null,M.position=null,V(null)},re=()=>{k.anchorEl=null,k.position=null},ge=async(i,a,c=!0,v="")=>{if(!(!a.length||!i.length))try{s(i,a,c,v),k.anchorEl||(await xe(.5),ne())}catch(z){console.error("handleResend error",{error:z})}},p=async({channels:i,isResendFailedOnly:a})=>{const c=O.map(v=>R[v].receiver);await ge(i,c,a),await xe(.5),re(),A([])},u=async(i,a=[],c=!0)=>{try{await ge(["webhook"],[i.receiver],c,a)}catch(v){q.error(v.response?v.response.statusText:v.message)}},j=async(i,a,c,v=[],z=!0)=>{if(i.stopPropagation(),ss(a,c)>=4){q.warning(r("notification.resendLimit"));return}if(!ke.includes(c)){await u(a,v,z);return}if(i){const K=i.currentTarget,W=K.getBoundingClientRect();M.anchorEl=K,M.position={top:W.top+window.scrollY,left:W.left+window.scrollX}}V({channel:c});try{const K=await oe(c,a.receiver);await xe(1),V({channel:c,result:K}),(typeof K=="boolean"&&K||St(K)&&Object.values(K).every(W=>!!W))&&(await s([c],[a.receiver],z),k.anchorEl||(await xe(.5),ne()))}catch(K){q.error(K.message)}},I=i=>{N(a=>({...a,dateRange:i,page:1}))},E=(i,a,c,v)=>{i.stopPropagation();const z=c.filter(Y=>Y!==a);N(Y=>({...Y,[v]:z,page:1}))},T=J(()=>[{label:r("notification.receiver"),name:"receiver",width:200,options:{filter:!1,customBodyRenderLite:i=>{const{receiverUser:a,receiver:c}=R[i];return a?e.jsxs(C,{"data-cy":`member-name-${a.fullName}`,sx:{display:"flex",alignItems:"center",gap:1,justifyContent:"flex-start"},children:[e.jsx(Ze,{src:`${a.avatar}?imageFilter=resize&w=48&h=48`,size:32,did:c,shape:"circle",style:{borderRadius:"100%",overflow:"hidden"}}),e.jsx(me,{children:a.fullName})]},c):e.jsx(yt,{size:14,responsive:!1,compact:!0,copyable:!1,did:c})}}},{label:"Wallet",name:"walletSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),filter:!0,filterType:"custom",filterList:m.walletSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Wallet",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[1].options.filterList,"walletSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Wallet",filterList:i,onChange:a,index:c,column:v,filterValues:w})},customBodyRenderLite:i=>{const{walletSendStatus:a,walletSendAt:c,walletSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"wallet",onResend:z=>j(z,R[i],"wallet",[],!1)})}}},{label:"Push Kit",name:"pushKitSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{pushKitSendStatus:a,pushKitSendAt:c,pushKitSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"pushkit",onResend:z=>j(z,R[i],"pushKit",[],!1)})},filter:!0,filterType:"custom",filterList:m.pushKitSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Push Kit",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[2].options.filterList,"pushKitSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Push Kit",filterList:i,onChange:a,index:c,column:v,filterValues:w})}}},{label:"Email",name:"emailSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{emailSendStatus:a,emailSendAt:c,emailSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"email",onResend:z=>j(z,R[i],"email",[],!1)})},filter:!0,filterType:"custom",filterList:m.emailSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Email",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[3].options.filterList,"emailSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Email",filterList:i,onChange:a,index:c,column:v,filterValues:w})}}},{label:"Webhook",name:"webhook",width:200,options:{filter:!1,setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{webhook:a}=R[i];if(!a)return null;const c=Object.entries(a)[0];if(!c)return null;const[v,z]=c,Y=z[0];return e.jsx(C,{sx:{display:"flex",flexDirection:"column",gap:1},children:e.jsxs(C,{className:"webhook-item",sx:{fontSize:12},children:[e.jsx(me,{maxLength:30,children:v},v),e.jsx(ce,{status:Y.status,updatedAt:Y.sendAt,reason:Y.failedReason,channel:"webhook",onResend:K=>j(K,R[i],"webhook",[v],!1)})]},v)})}}},{label:r("common.createdAt"),name:"createdAt",width:100,options:{filter:!1,customBodyRenderLite:i=>{const{createdAt:a}=R[i];return e.jsx(et,{value:a,locale:o,shouldUpdate:!0})}}}],[R,o,m,r]),le=[e.jsx(We,{value:m.dateRange,onChange:I},"date-picker"),e.jsx(Oe,{variant:"contained",size:"small",color:"primary",loading:B,startIcon:e.jsx(Mt,{}),onClick:()=>L(),sx:{".MuiButton-startIcon":{mr:"2px"}},style:{marginLeft:8},children:r("common.refresh")},"refresh")];return e.jsx(C,{sx:{overflow:"auto",".MuiTableCell-head":{whiteSpace:"nowrap",fontWeight:"bold"},".MuiTableCell-root":{paddingRight:"8px",whiteSpace:"nowrap"}},children:e.jsx(os,{children:e.jsxs(tt,{theme:x,children:[e.jsx(at,{className:"receivers-table",locale:o,loading:B,columns:T,data:R,onChange:Z,options:se,customButtons:le,components:{TableFilterList:i=>e.jsx(Me,{...i,itemComponent:a=>e.jsx(Ke,{...a,canDelete:()=>!1})})}}),M.anchorEl&&e.jsx(Ae,{open:!!M.anchorEl,anchorReference:"anchorPosition",anchorPosition:M.position,onClose:ne,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},children:e.jsxs(rs,{children:[e.jsxs(U,{variant:"body1",component:"div",className:"check-title",children:[F?.channel," Checking"]}),e.jsx(C,{sx:{display:"flex",flexDirection:"column",gap:"4px"},children:we(F?.channel).map(i=>{const{type:a,pass:c,fail:v}=i;return!F?.result||F?.result?.[a]?e.jsxs(U,{variant:"body1",component:"div",className:"check-item",sx:{display:"flex",alignItems:"center",gap:"4px",color:F?.result?.[a]?je.success.main:"inherit"},children:[F?.result?e.jsx($t,{}):e.jsx(Je,{size:12,sx:{color:je.primary.main}}),e.jsx("span",{children:c})]},a):e.jsxs(U,{variant:"body1",component:"div",className:"check-item",sx:{display:"flex",alignItems:"center",gap:"4px",color:je.error.main},children:[e.jsx(Ut,{}),e.jsx("span",{children:v})]},a)})})]})}),k.anchorEl&&e.jsx(Ae,{open:!!k.anchorEl,anchorReference:"anchorPosition",anchorPosition:k.position,onClose:re,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},children:e.jsx(pt,{loading:n,onCancel:re,onConfirm:p})})]})})})}const as=g.memo(ft),os=ie.div`
|
|
1
|
+
import{aF as Ge,j as e,bn as gt,r as g,bD as J,bf as H,H as q,aH as D,g as xt,o as d,h as ee,at as bt,ay as jt,K as C,T as U,V as Q,eO as Fe,O as Pe,ik as Ye,bj as Te,aU as Ie,R as Ee,bA as Ne,b3 as qe,b1 as Ae,C as Je,f as Qe,f0 as Xe,aP as De,W as yt,as as Ze,il as et,v as Oe,f2 as tt,bq as je,fJ as st,dD as St,s as ie,af as pe,G as Ue,au as vt,im as Ct,io as Nt,$ as nt,ip as wt,iq as Rt,ir as Tt,is as It,N as Et,bx as it,E as At,J as Dt,P as Ot,S as Lt,Q as $e,it as kt,a3 as Ft}from"./index-DN1FR838.js";import{d as Pt,H as at,g as _t}from"./index-DtEm4DlR.js";import{R as _e,S as Bt}from"./actions-BQYoCyzD.js";import{B as zt}from"./index-B_irEVal.js";import{S as me}from"./shorten-label-lyN5fJdD.js";import{v as ot}from"./index-Cwj1cT7X.js";import{T as Wt}from"./html-title-DZPr9ErN.js";import{R as Mt}from"./Refresh-BRw0lNlx.js";import{D as Kt,g as Ht}from"./traffic-DlmGH1wr.js";import{u as qt}from"./use-mobile-BRO-uubG.js";import"./FilterList-CoyfX8VL.js";import"./CSSTransition-Cp9IAg_E.js";import"./emotion-cache.browser.esm-DR87qH_k.js";import"./index-CIJ5EXA3.js";import"./redux-DfszZyTl.js";import"./typeof-QjJsDpFa.js";import"./depsEqual-C1JyiMkY.js";import"./index-aiY7k_D_.js";import"./TableSearch-DTa-kQYq.js";import"./Search-DihRAr8J.js";import"./Clear-3aQ_ViuO.js";import"./MoreVert-Crfla2Nw.js";import"./useLocalStorage-DdFQ0H8D.js";import"./url-evaluation-D0KhcJoH.js";import"./get-safe-url-B8fUDSaQ.js";import"./ButtonGroup-Dlkb94HL.js";import"./getValidReactChildren-Dxx0sUSA.js";import"./permission-BFEhHSn7.js";import"./index.esm-0qTLMRcM.js";import"./collapse-C4RswaYj.js";import"./blocklet-BwZNRhqB.js";import"./Switch-DXK3jQx6.js";import"./iframe-DloJgn9Q.js";import"./ChevronLeft-CZ7VDJCP.js";import"./ChevronRight-W_01-zFQ.js";import"./index-DBii9-f-.js";import"./base-chart-C7SG2Os5.js";import"./index-C1n8OjtU.js";import"./AdapterDayjs-DFNTS6uL.js";import"./useThemeProps-7IPePURq.js";import"./visuallyHidden-Dan1xhjv.js";const Ut=Ge(e.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2M4 12c0-4.42 3.58-8 8-8 1.85 0 3.55.63 4.9 1.69L5.69 16.9C4.63 15.55 4 13.85 4 12m8 8c-1.85 0-3.55-.63-4.9-1.69L18.31 7.1C19.37 8.45 20 10.15 20 12c0 4.42-3.58 8-8 8"})),$t=Ge(e.jsx("path",{d:"M16.59 7.58 10 14.17l-3.59-3.58L5 12l5 5 8-8zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"})),rt=g.createContext({}),{Provider:Vt,Consumer:on}=rt;function Gt({children:t,blocklet:s=""}){const{api:n,inService:r,ws:{useSubscription:o}}=gt(),[l,x]=g.useState([]),[f,y]=g.useState({total:0,pageSize:20,pageCount:0,page:1}),h=J(()=>s.meta?.did,[s]),[b,S]=g.useState([]),[B,_]=g.useState({}),R=J(()=>l.length?new Set(l.map(m=>m.id)):new Set,[l]),$=async({page:m=1,pageSize:N=20,...O}={})=>{if(!h)return[];try{const A={paging:{page:m,pageSize:N},...O,teamDid:h,dateRange:O.dateRange?[H(O.dateRange[0]).toISOString(),H(O.dateRange[1]).toISOString()]:void 0},{dids:w,...L}=A;let P="";w&&w.includes("system")&&(P="system");const ae=w?w.filter(oe=>oe!=="system"):[],se={...L,source:P,componentDids:ae},Z=await n.getNotificationSendLog({input:se});return _(se),x(Z.list),y(Z.paging),Z.list}catch(A){return q.error(A.message),[]}},M=async()=>{const m=await n.getNotificationComponents({input:{teamDid:h}});S(m.componentDids)},k=g.useCallback(m=>{const N=s.children.find(O=>O.meta?.did===m);if(N)return N.ancestors=[s],N},[s]),F=async({notificationId:m,receivers:N,channels:O,...A})=>{await n.resendNotification({input:{teamDid:h,notificationId:m,receivers:N,channels:O.map(w=>w==="wallet"?D.NOTIFICATION_SEND_CHANNEL.WALLET:w==="pushKit"?D.NOTIFICATION_SEND_CHANNEL.PUSH:w),...A}})},V=g.useCallback(async m=>(await n.getUser({input:{teamDid:h,user:{did:m},options:{enableConnectedAccount:!0}}})).user,[n,h]),G=g.useCallback(async({page:m=1,pageSize:N=20,...O}={})=>{try{const A={paging:{page:m,pageSize:N},...O,userName:O.searchText||"",teamDid:h,dateRange:O.dateRange?[H(O.dateRange[0]).toISOString(),H(O.dateRange[1]).toISOString()]:void 0};return await n.getReceivers({input:A})}catch(A){throw q.error(A.message),A}},[n,h]);g.useEffect(()=>{h&&M()},[h]),o(D.EVENTS.NOTIFICATION_BLOCKLET_UPDATE,m=>{R.has(m.notificationId)&&$(B)},[R,B]),o(D.EVENTS.NOTIFICATION_BLOCKLET_CREATE,m=>{R.has(m.id)||$(B)},[R,B]);const X={fetch:$,data:l,paging:f,blocklet:s,getComponent:k,resendNotification:F,getUser:V,componentDids:b,getReceivers:G,inService:r,teamDid:h};return e.jsx(Vt,{value:{notificationRecords:X},children:t})}function Be(){const{notificationRecords:t}=g.useContext(rt);return t}he.propTypes={severity:d.oneOf(Object.values(["info","success","error","warning"])).isRequired};const Yt={info:"primary",success:"success",error:"error",warning:"warning"};function he({severity:t="info"}){return e.jsx(xt,{type:Yt[t],children:t})}const Jt=(t,s,n="")=>{if(!n||!s)return"";switch(n){case D.NOTIFICATION_SEND_FAILED_REASON.USER_DISABLED:return t("notification.sendStatus.reason.disabled",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.CHANNEL_UNAVAILABLE:return t("notification.sendStatus.reason.unavailable",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.CHANNEL_DISABLED:return t("notification.sendStatus.reason.notSent",{channel:s});case D.NOTIFICATION_SEND_FAILED_REASON.NOT_ONLINE:return t("notification.sendStatus.reason.offline");default:return n}};function lt(t,s,n={}){const{status:r,updatedAt:o,reason:l="",channel:x="wallet"}=n,f=o?t("notification.sendStatus.sentTime",{date:bt(o,s)}):"",y=Jt(t,x,l);return r===D.NOTIFICATION_SEND_STATUS.FAILED?{status:"failed",title:t("notification.sendStatus.failed"),sentTime:f,reason:y}:r===D.NOTIFICATION_SEND_STATUS.SENT?{status:"success",title:t("notification.sendStatus.success"),sentTime:f}:{status:"pending",title:t("notification.sendStatus.pending"),reason:y,sentTime:f}}const Le={pending:"#aaaaaa",success:"#34BE74",failed:"#D0021B"},ke=["wallet","pushKit","email"],Ve=["info","success","error","warning"],ct=t=>{const{settings:s}=t;return s?.notification?.email?.enabled},dt=t=>{const{settings:s}=t;return s?.notification?.pushKit?.enabled},Qt=(t,s)=>{const n=ee(s,"extra.notifications.email",!0);return{available:ct(t),enabled:n}},Xt=(t,s)=>{const n=ee(s,"extra.notifications.push",!0);return{available:dt(t),enabled:n}},Zt=t=>({enabled:ee(t,"extra.notifications.wallet",!0)}),es=t=>({enabled:ee(t,"extra.webhooks",[]).length>0}),xe=(t=3)=>new Promise(s=>{setTimeout(()=>{s()},t*1e3)}),ts=(t,s)=>s==="wallet"||s==="webhook"?[{channel:s,type:"enabled",pass:t("notification.sendStatus.reason.enabled",{channel:s}),fail:t("notification.sendStatus.reason.disabled",{channel:s})}]:s==="pushKit"||s==="email"?[{channel:s,type:"available",pass:t("notification.sendStatus.reason.available",{channel:s}),fail:t("notification.sendStatus.reason.unavailable",{channel:s})},{channel:s,type:"enabled",pass:t("notification.sendStatus.reason.enabled",{channel:s}),fail:t("notification.sendStatus.reason.disabled",{channel:s})}]:[],be=(t=[])=>{const s=H().startOf("day");return t.filter(n=>H(n.sendAt).isSame(s,"day")).length},ss=(t,s="")=>{if(s&&ke.includes(s)){const l=`${s}SendRecord`,x=ee(t,l,[]);return be(x)}const n=ee(t,"webhook",{}),r=Object.keys(n??{})??[];if(s&&r.includes(s)){const l=n[s]??[];return be(l)}const o={};return ke.forEach(l=>{const x=`${l}SendRecord`,f=ee(t,x,[]),y=be(f);o[l]=y}),r.length>0&&r.forEach(l=>{const x=n[l]??[],f=be(x);o[l]=f}),o},ye=(t,s,n)=>{if(!Array.isArray(t))throw new Error("Invalid filterList or index");return t[n].splice(s,1),t},Se=(t,s)=>{if(!Array.isArray(s))throw new Error("filters must be an array");return s.length?!s.includes(t):!1},ns=t=>{switch(t){case D.NOTIFICATION_SEND_CHANNEL.WALLET:return"Wallet";case D.NOTIFICATION_SEND_CHANNEL.PUSH:return"Push Kit";case D.NOTIFICATION_SEND_CHANNEL.EMAIL:return"Email";case D.NOTIFICATION_SEND_CHANNEL.WEBHOOK:return"Webhook";default:return""}},ut=()=>({components:{MUIDataTableFilter:{styleOverrides:{header:{marginBottom:0,p:{margin:0}},root:{"& .MuiGrid-container":{marginTop:0,"& .MuiGrid-item":{paddingTop:0}}}}},MuiPopover:{styleOverrides:{root:{"&.MuiPopover-root":{"& .MuiPaper-root:has(.filter-container)":{width:"420px"}}}}}}});function te({config:t,enableTooltip:s=!0,showTitle:n=!1,children:r=null}){const{status:o,title:l="",sentTime:x="",reason:f=""}=t,y=[l,f].filter(Boolean).join(", ");return e.jsx(jt,{title:s?e.jsxs(e.Fragment,{children:[e.jsx(U,{color:"inherit",sx:{fontSize:12},children:y}),e.jsx("span",{children:x})]}):null,arrow:!0,placement:"top",children:e.jsxs(C,{sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px"},children:[e.jsxs(C,{sx:{position:"relative",minHeight:14,minWidth:14,display:"flex",alignItems:"center",justifyContent:"center"},children:[e.jsx(C,{style:{opacity:.15},sx:{position:"absolute",width:"100%",height:"100%",borderRadius:"50%",bgcolor:Le[o]}}),e.jsx(C,{sx:{position:"absolute",width:"55%",height:"55%",borderRadius:"50%",bgcolor:Le[o]}})]}),e.jsx(U,{color:"inherit",sx:{fontSize:12},children:n?l:r})]})})}te.propTypes={config:d.object.isRequired,enableTooltip:d.bool,showTitle:d.bool,children:d.node};ve.propTypes={list:d.array.isRequired,label:d.string.isRequired,onDelete:d.func};function ve({list:t,label:s,onDelete:n=()=>{}}){const{t:r,locale:o}=Q();return e.jsxs(C,{sx:{display:"flex",gap:1,alignItems:"center"},children:[e.jsxs(U,{children:[s,": "]}),t.map(l=>{const x=lt(r,o,{status:l});return e.jsx(Fe,{size:"small",label:e.jsx(C,{sx:{display:"flex",alignItems:"center",gap:"4px"},children:e.jsx(te,{config:x,enableTooltip:!1,children:x.title})}),onDelete:f=>n(f,l)},l)})]})}ze.propTypes={filterList:d.array.isRequired,onChange:d.func.isRequired,index:d.number.isRequired,column:d.object.isRequired,filterValues:d.array.isRequired,label:d.string.isRequired,renderLabel:d.func.isRequired};function ze({filterList:t,onChange:s,index:n,column:r,filterValues:o,label:l,renderLabel:x}){return e.jsxs(Pe,{className:"filter-container",children:[e.jsx(Ye,{component:"legend",children:l}),e.jsx(Te,{row:!0,children:o.map(f=>e.jsx(Ie,{control:e.jsx(Ee,{checked:t[n].indexOf(f.value??f)>-1,onChange:y=>{const h=[...t];y.target.checked?h[n]=[...h[n],f.value??f]:h[n]=h[n].filter(b=>b!==(f.value??f)),s(h[n],n,r)},name:f.value??f}),label:e.jsx("span",{style:{display:"flex",alignItems:"center"},children:x(f)})},f.value??f))})]})}function Re(t){return e.jsx(ze,{...t,renderLabel:s=>e.jsx(te,{enableTooltip:!1,config:{status:s.status},children:s.label})})}ce.propTypes={status:d.number.isRequired,updatedAt:d.string.isRequired,reason:d.string,channel:d.string,onResend:d.func};function ce({status:t,updatedAt:s,reason:n="",channel:r="wallet",onResend:o}){const{t:l,locale:x}=Q(),f=lt(l,x,{status:t,updatedAt:s,reason:n,channel:r});return e.jsxs(C,{sx:{display:"flex",alignItems:"center",gap:1},children:[e.jsx(te,{config:f,showTitle:!0}),f.status!=="success"&&e.jsx(Ne,{className:"resend-btn",size:"small",startIcon:e.jsx(_e,{}),sx:{fontSize:12,color:"rgba(0, 0, 0, 0.87)",fontWeight:400,".MuiButton-startIcon":{mr:"2px"}},onClick:o,children:l("notification.resend")})]})}We.propTypes={value:d.array.isRequired,onChange:d.func};function We({value:t,onChange:s}){const{locale:n}=Q(),r=H().toDate(),[o,l]=g.useState(null),x=g.useCallback(h=>{l(o?null:h.currentTarget)},[o]),f=!!o,y=g.useCallback(h=>{if(!h.startDate||!h.endDate){q.error("Please select a date range");return}if(H(h.startDate).isAfter(h.endDate)||!H(h.startDate).isValid()||!H(h.endDate).isValid()){q.error("Invalid date range");return}s([h.startDate,h.endDate]),l(null)},[s]);return e.jsxs("div",{children:[e.jsx(U,{component:"div",variant:"h5",color:"textPrimary",style:{fontSize:18,fontWeight:"bold"},sx:{mb:0},children:e.jsxs(Ne,{onClick:x,variant:"outlined",size:"small",color:"inherit",children:[qe(t[0],n)," - ",qe(t[1],n)]})}),e.jsx(Ae,{open:f,anchorEl:o,onClose:()=>{l(null)},anchorOrigin:{vertical:"bottom",horizontal:"left"},children:e.jsx(Kt,{open:!0,maxDate:r,initialDateRange:{startDate:t[0],endDate:t[1]},toggle:x,definedRanges:Ht(r),onChange:y})})]})}Me.propTypes={itemComponent:d.elementType.isRequired};function Me({itemComponent:t,...s}){const{t:n}=Q();return!s?.filterList?.filter(o=>o.length).length?null:e.jsxs(C,{sx:{display:"flex",gap:1,alignItems:"center"},children:[e.jsx("div",{className:"toolbar-filter-title",children:n("notification.filter")}),e.jsx("div",{className:"toolbar-filter-content",children:e.jsx(Pt.TableFilterList,{...s,ItemComponent:t})})]})}function Ke({label:t,onDelete:s,canDelete:n=()=>!0,...r}){const o=s&&typeof s=="function"?s:void 0;let l=!0;return n&&typeof n=="function"&&(l=n({label:t,...r})),e.jsx(Fe,{label:t,variant:"outlined",...o&&l?{onDelete:o}:{}})}Ke.propTypes={label:d.string.isRequired,onDelete:d.func,canDelete:d.func};const is=[{label:"Wallet",value:"app",checked:!0},{label:"Email",value:"email",checked:!0},{label:"Push Kit",value:"push",checked:!0},{label:"Webhook",value:"webhook",checked:!0}];pt.propTypes={loading:d.bool,onCancel:d.func,onConfirm:d.func};function pt({loading:t=!1,onCancel:s=()=>{},onConfirm:n=()=>{}}){const{t:r}=Q(),[o,l]=g.useState(is),[x,f]=g.useState(!0),y=(b,S)=>{S.checked=b.target.checked;const B=o.map(_=>({..._,checked:_.value===S.value?S.checked:_.checked}));l(B)},h=b=>{b.stopPropagation(),n({channels:o.filter(S=>S.checked).map(S=>S.value),isResendFailedOnly:x})};return e.jsxs(C,{className:"resend-config",sx:{padding:"16px 24px"},children:[e.jsx(U,{variant:"body1",component:"div",className:"check-title",sx:{fontWeight:700,mb:1},children:r("notification.config")}),e.jsx(C,{className:"choose-channel",children:e.jsxs(Pe,{component:"fieldset",variant:"standard",children:[e.jsx(Ye,{component:"legend",children:r("notification.selectChannels")}),e.jsx(Te,{sx:{display:"flex",flexDirection:"row",flexWrap:"wrap",gap:1},children:o.map(b=>e.jsx(Ie,{control:e.jsx(Ee,{checked:b.checked,onChange:S=>y(S,b),name:b.value}),label:b.label},b.value))})]})}),e.jsx(C,{className:"resend-config-footer",children:e.jsx(Te,{children:e.jsx(Ie,{control:e.jsx(Ee,{checked:x,onChange:b=>f(b.target.checked)}),label:r("notification.resendFailedOnly")})})}),e.jsxs(C,{className:"resend-config-footer-tip",sx:{display:"flex",justifyContent:"flex-end",gap:1},children:[e.jsx(Ne,{onClick:b=>{b.stopPropagation(),s()},color:"inherit",children:r("common.cancel")}),e.jsxs(Ne,{onClick:h,color:"primary",disabled:t,variant:"contained",autoFocus:!0,style:{marginLeft:8},children:[t&&e.jsx(Je,{size:16}),r("common.confirm")]})]})]})}ft.propTypes={notificationId:d.string.isRequired,handleResend:d.func,resending:d.bool};function ft({notificationId:t,handleResend:s,resending:n=!1}){const{t:r,locale:o}=Q(),l=Qe(),x=g.useMemo(()=>Xe(l,ut()),[l]),{getReceivers:f,inService:y,teamDid:h,getUser:b,blocklet:S}=Be(),[B,_]=g.useState(!1),[R,$]=g.useState([]),M=De({anchorEl:null,position:null}),k=De({anchorEl:null,position:null}),[F,V]=g.useState(null),[G,X]=g.useState({total:0,pageSize:10,pageCount:0,page:1}),[m,N]=g.useState({searchText:"",page:1,pageSize:10,walletSendStatus:[],pushKitSendStatus:[],emailSendStatus:[],dateRange:[H().subtract(1,"month").startOf("day").toDate(),H().endOf("day").toDate()]}),[O,A]=g.useState([]),w=[{label:r("notification.sendStatus.pending"),value:0,status:"pending"},{label:r("notification.sendStatus.success"),value:1,status:"success"},{label:r("notification.sendStatus.failed"),value:2,status:"failed"}],L=async()=>{if(!B&&t)try{_(!0);const i=await f({notificationId:t,...m}),a=i.list.map(c=>({...c,receiverUser:{...c.receiverUser,avatar:st(c.receiverUser.avatar,h,y)}}));$(a),X(i.paging),_(!1)}catch(i){q.error(i.message),_(!1)}};g.useEffect(()=>{L()},[m]);const P=i=>{i.stopPropagation();const a=i.currentTarget;k.anchorEl=a;const c=a.getBoundingClientRect();k.position={top:c.top+window.scrollY,left:c.left+window.scrollX}},ae=i=>i.data.length?e.jsx("div",{style:{display:"flex",alignItems:"center",padding:"10px"},children:e.jsx(Oe,{className:"resend-btn",size:"small",color:"primary",variant:"contained",startIcon:e.jsx(_e,{}),sx:{".MuiButton-startIcon":{mr:"2px"}},onClick:P,children:r("notification.resend")})}):null,se={sort:!1,download:!1,print:!1,selectableRows:"multiple",searchPlaceholder:r("common.search"),searchAlwaysOpen:!1,filterType:"checkbox",searchDebounceTime:300,page:G.page-1,rowsPerPage:G.pageSize,count:G.total,searchText:m.searchText,tableBodyMaxHeight:"calc(80vh - 260px)",rowsSelected:O,onRowSelectionChange:(i,a)=>{A(a.map(c=>c.dataIndex))},customToolbarSelect:ae},Z=({page:i,rowsPerPage:a,searchText:c,filterList:v})=>{const[,z=[],Y=[],K=[]]=v;m.pageSize!==a?N(W=>({...W,pageSize:a,page:1})):m.page!==i+1?N(W=>({...W,page:i+1})):m.searchText!==c?N(W=>({...W,searchText:c,page:1})):pe(z,m.walletSendStatus)?pe(Y,m.pushKitSendStatus)?pe(K,m.emailSendStatus)||N(W=>({...W,emailSendStatus:K,page:1})):N(W=>({...W,pushKitSendStatus:Y,page:1})):N(W=>({...W,walletSendStatus:z,page:1}))},oe=g.useCallback(async(i,a)=>{if(!a)return!1;const c=await b(a);return c?i==="wallet"?Zt(c):i==="email"?Qt(S,c):i==="pushKit"?Xt(S,c):i==="webhook"?es(c):!0:!1},[b,S]),we=g.useCallback(i=>ts(r,i),[r]),ne=()=>{M.anchorEl=null,M.position=null,V(null)},re=()=>{k.anchorEl=null,k.position=null},ge=async(i,a,c=!0,v="")=>{if(!(!a.length||!i.length))try{s(i,a,c,v),k.anchorEl||(await xe(.5),ne())}catch(z){console.error("handleResend error",{error:z})}},p=async({channels:i,isResendFailedOnly:a})=>{const c=O.map(v=>R[v].receiver);await ge(i,c,a),await xe(.5),re(),A([])},u=async(i,a=[],c=!0)=>{try{await ge(["webhook"],[i.receiver],c,a)}catch(v){q.error(v.response?v.response.statusText:v.message)}},j=async(i,a,c,v=[],z=!0)=>{if(i.stopPropagation(),ss(a,c)>=4){q.warning(r("notification.resendLimit"));return}if(!ke.includes(c)){await u(a,v,z);return}if(i){const K=i.currentTarget,W=K.getBoundingClientRect();M.anchorEl=K,M.position={top:W.top+window.scrollY,left:W.left+window.scrollX}}V({channel:c});try{const K=await oe(c,a.receiver);await xe(1),V({channel:c,result:K}),(typeof K=="boolean"&&K||St(K)&&Object.values(K).every(W=>!!W))&&(await s([c],[a.receiver],z),k.anchorEl||(await xe(.5),ne()))}catch(K){q.error(K.message)}},I=i=>{N(a=>({...a,dateRange:i,page:1}))},E=(i,a,c,v)=>{i.stopPropagation();const z=c.filter(Y=>Y!==a);N(Y=>({...Y,[v]:z,page:1}))},T=J(()=>[{label:r("notification.receiver"),name:"receiver",width:200,options:{filter:!1,customBodyRenderLite:i=>{const{receiverUser:a,receiver:c}=R[i];return a?e.jsxs(C,{"data-cy":`member-name-${a.fullName}`,sx:{display:"flex",alignItems:"center",gap:1,justifyContent:"flex-start"},children:[e.jsx(Ze,{src:`${a.avatar}?imageFilter=resize&w=48&h=48`,size:32,did:c,shape:"circle",style:{borderRadius:"100%",overflow:"hidden"}}),e.jsx(me,{children:a.fullName})]},c):e.jsx(yt,{size:14,responsive:!1,compact:!0,copyable:!1,did:c})}}},{label:"Wallet",name:"walletSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),filter:!0,filterType:"custom",filterList:m.walletSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Wallet",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[1].options.filterList,"walletSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Wallet",filterList:i,onChange:a,index:c,column:v,filterValues:w})},customBodyRenderLite:i=>{const{walletSendStatus:a,walletSendAt:c,walletSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"wallet",onResend:z=>j(z,R[i],"wallet",[],!1)})}}},{label:"Push Kit",name:"pushKitSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{pushKitSendStatus:a,pushKitSendAt:c,pushKitSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"pushkit",onResend:z=>j(z,R[i],"pushKit",[],!1)})},filter:!0,filterType:"custom",filterList:m.pushKitSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Push Kit",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[2].options.filterList,"pushKitSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Push Kit",filterList:i,onChange:a,index:c,column:v,filterValues:w})}}},{label:"Email",name:"emailSendStatus",width:200,options:{setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{emailSendStatus:a,emailSendAt:c,emailSendFailedReason:v}=R[i];return e.jsx(ce,{status:a,updatedAt:c,reason:v,channel:"email",onResend:z=>j(z,R[i],"email",[],!1)})},filter:!0,filterType:"custom",filterList:m.emailSendStatus??[],customFilterListOptions:{render:i=>e.jsx(ve,{list:i,label:"Email",onDelete:(a,c)=>{a.stopPropagation(),E(a,c,T[3].options.filterList,"emailSendStatus")}}),update:ye},filterOptions:{names:w,fullWidth:!0,logic:Se,display:(i,a,c,v)=>e.jsx(Re,{label:"Email",filterList:i,onChange:a,index:c,column:v,filterValues:w})}}},{label:"Webhook",name:"webhook",width:200,options:{filter:!1,setCellProps:()=>({className:"sent-status-cell"}),customBodyRenderLite:i=>{const{webhook:a}=R[i];if(!a)return null;const c=Object.entries(a)[0];if(!c)return null;const[v,z]=c,Y=z[0];return e.jsx(C,{sx:{display:"flex",flexDirection:"column",gap:1},children:e.jsxs(C,{className:"webhook-item",sx:{fontSize:12},children:[e.jsx(me,{maxLength:30,children:v},v),e.jsx(ce,{status:Y.status,updatedAt:Y.sendAt,reason:Y.failedReason,channel:"webhook",onResend:K=>j(K,R[i],"webhook",[v],!1)})]},v)})}}},{label:r("common.createdAt"),name:"createdAt",width:100,options:{filter:!1,customBodyRenderLite:i=>{const{createdAt:a}=R[i];return e.jsx(et,{value:a,locale:o,shouldUpdate:!0})}}}],[R,o,m,r]),le=[e.jsx(We,{value:m.dateRange,onChange:I},"date-picker"),e.jsx(Oe,{variant:"contained",size:"small",color:"primary",loading:B,startIcon:e.jsx(Mt,{}),onClick:()=>L(),sx:{".MuiButton-startIcon":{mr:"2px"}},style:{marginLeft:8},children:r("common.refresh")},"refresh")];return e.jsx(C,{sx:{overflow:"auto",".MuiTableCell-head":{whiteSpace:"nowrap",fontWeight:"bold"},".MuiTableCell-root":{paddingRight:"8px",whiteSpace:"nowrap"}},children:e.jsx(os,{children:e.jsxs(tt,{theme:x,children:[e.jsx(at,{className:"receivers-table",locale:o,loading:B,columns:T,data:R,onChange:Z,options:se,customButtons:le,components:{TableFilterList:i=>e.jsx(Me,{...i,itemComponent:a=>e.jsx(Ke,{...a,canDelete:()=>!1})})}}),M.anchorEl&&e.jsx(Ae,{open:!!M.anchorEl,anchorReference:"anchorPosition",anchorPosition:M.position,onClose:ne,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},children:e.jsxs(rs,{children:[e.jsxs(U,{variant:"body1",component:"div",className:"check-title",children:[F?.channel," Checking"]}),e.jsx(C,{sx:{display:"flex",flexDirection:"column",gap:"4px"},children:we(F?.channel).map(i=>{const{type:a,pass:c,fail:v}=i;return!F?.result||F?.result?.[a]?e.jsxs(U,{variant:"body1",component:"div",className:"check-item",sx:{display:"flex",alignItems:"center",gap:"4px",color:F?.result?.[a]?je.success.main:"inherit"},children:[F?.result?e.jsx($t,{}):e.jsx(Je,{size:12,sx:{color:je.primary.main}}),e.jsx("span",{children:c})]},a):e.jsxs(U,{variant:"body1",component:"div",className:"check-item",sx:{display:"flex",alignItems:"center",gap:"4px",color:je.error.main},children:[e.jsx(Ut,{}),e.jsx("span",{children:v})]},a)})})]})}),k.anchorEl&&e.jsx(Ae,{open:!!k.anchorEl,anchorReference:"anchorPosition",anchorPosition:k.position,onClose:re,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"left"},children:e.jsx(pt,{loading:n,onCancel:re,onConfirm:p})})]})})})}const as=g.memo(ft),os=ie.div`
|
|
2
2
|
td.MuiTableCell-footer {
|
|
3
3
|
border: none !important;
|
|
4
4
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{cs as u,r as o,p as x,ct as r,B as g,j as s,K as m,cu as d}from"./index-
|
|
1
|
+
import{cs as u,r as o,p as x,ct as r,B as g,j as s,K as m,cu as d}from"./index-DN1FR838.js";function P(){const i=u(),{blocklets:c,refresh:l}=i,{t:p}=o.useContext(x),y=r.generateKey(),[a]=g();return o.useEffect(()=>{const n=r.getNotificationQueryParams(y)??{},t=a.get("entityId"),e=a.get("severity"),f={...n,...e?{severity:e==="all"?[]:e.split(","),paging:{...n.paging,page:1}}:{},...t?{entityId:t==="all"?[]:t.split(",")}:{},componentDid:[]};l(f)},[]),s.jsxs(m,{children:[s.jsx("h1",{children:p("notification.title")}),s.jsx(d,{tabType:"line",blocklets:c,context:i,filterType:"entity",type:"server"})]})}export{P as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ez as k}from"./index-
|
|
1
|
+
import{ez as k}from"./index-DN1FR838.js";var m,C;function S(){if(C)return m;C=1;function v(o){if(typeof o!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(o))}function A(o,e){for(var r="",i=0,f=-1,t=0,n,l=0;l<=o.length;++l){if(l<o.length)n=o.charCodeAt(l);else{if(n===47)break;n=47}if(n===47){if(!(f===l-1||t===1))if(f!==l-1&&t===2){if(r.length<2||i!==2||r.charCodeAt(r.length-1)!==46||r.charCodeAt(r.length-2)!==46){if(r.length>2){var s=r.lastIndexOf("/");if(s!==r.length-1){s===-1?(r="",i=0):(r=r.slice(0,s),i=r.length-1-r.lastIndexOf("/")),f=l,t=0;continue}}else if(r.length===2||r.length===1){r="",i=0,f=l,t=0;continue}}e&&(r.length>0?r+="/..":r="..",i=2)}else r.length>0?r+="/"+o.slice(f+1,l):r=o.slice(f+1,l),i=l-f-1;f=l,t=0}else n===46&&t!==-1?++t:t=-1}return r}function b(o,e){var r=e.dir||e.root,i=e.base||(e.name||"")+(e.ext||"");return r?r===e.root?r+i:r+o+i:i}var g={resolve:function(){for(var e="",r=!1,i,f=arguments.length-1;f>=-1&&!r;f--){var t;f>=0?t=arguments[f]:(i===void 0&&(i=k.cwd()),t=i),v(t),t.length!==0&&(e=t+"/"+e,r=t.charCodeAt(0)===47)}return e=A(e,!r),r?e.length>0?"/"+e:"/":e.length>0?e:"."},normalize:function(e){if(v(e),e.length===0)return".";var r=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return e=A(e,!r),e.length===0&&!r&&(e="."),e.length>0&&i&&(e+="/"),r?"/"+e:e},isAbsolute:function(e){return v(e),e.length>0&&e.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var e,r=0;r<arguments.length;++r){var i=arguments[r];v(i),i.length>0&&(e===void 0?e=i:e+="/"+i)}return e===void 0?".":g.normalize(e)},relative:function(e,r){if(v(e),v(r),e===r||(e=g.resolve(e),r=g.resolve(r),e===r))return"";for(var i=1;i<e.length&&e.charCodeAt(i)===47;++i);for(var f=e.length,t=f-i,n=1;n<r.length&&r.charCodeAt(n)===47;++n);for(var l=r.length,s=l-n,c=t<s?t:s,u=-1,a=0;a<=c;++a){if(a===c){if(s>c){if(r.charCodeAt(n+a)===47)return r.slice(n+a+1);if(a===0)return r.slice(n+a)}else t>c&&(e.charCodeAt(i+a)===47?u=a:a===0&&(u=0));break}var h=e.charCodeAt(i+a),y=r.charCodeAt(n+a);if(h!==y)break;h===47&&(u=a)}var d="";for(a=i+u+1;a<=f;++a)(a===f||e.charCodeAt(a)===47)&&(d.length===0?d+="..":d+="/..");return d.length>0?d+r.slice(n+u):(n+=u,r.charCodeAt(n)===47&&++n,r.slice(n))},_makeLong:function(e){return e},dirname:function(e){if(v(e),e.length===0)return".";for(var r=e.charCodeAt(0),i=r===47,f=-1,t=!0,n=e.length-1;n>=1;--n)if(r=e.charCodeAt(n),r===47){if(!t){f=n;break}}else t=!1;return f===-1?i?"/":".":i&&f===1?"//":e.slice(0,f)},basename:function(e,r){if(r!==void 0&&typeof r!="string")throw new TypeError('"ext" argument must be a string');v(e);var i=0,f=-1,t=!0,n;if(r!==void 0&&r.length>0&&r.length<=e.length){if(r.length===e.length&&r===e)return"";var l=r.length-1,s=-1;for(n=e.length-1;n>=0;--n){var c=e.charCodeAt(n);if(c===47){if(!t){i=n+1;break}}else s===-1&&(t=!1,s=n+1),l>=0&&(c===r.charCodeAt(l)?--l===-1&&(f=n):(l=-1,f=s))}return i===f?f=s:f===-1&&(f=e.length),e.slice(i,f)}else{for(n=e.length-1;n>=0;--n)if(e.charCodeAt(n)===47){if(!t){i=n+1;break}}else f===-1&&(t=!1,f=n+1);return f===-1?"":e.slice(i,f)}},extname:function(e){v(e);for(var r=-1,i=0,f=-1,t=!0,n=0,l=e.length-1;l>=0;--l){var s=e.charCodeAt(l);if(s===47){if(!t){i=l+1;break}continue}f===-1&&(t=!1,f=l+1),s===46?r===-1?r=l:n!==1&&(n=1):r!==-1&&(n=-1)}return r===-1||f===-1||n===0||n===1&&r===f-1&&r===i+1?"":e.slice(r,f)},format:function(e){if(e===null||typeof e!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return b("/",e)},parse:function(e){v(e);var r={root:"",dir:"",base:"",ext:"",name:""};if(e.length===0)return r;var i=e.charCodeAt(0),f=i===47,t;f?(r.root="/",t=1):t=0;for(var n=-1,l=0,s=-1,c=!0,u=e.length-1,a=0;u>=t;--u){if(i=e.charCodeAt(u),i===47){if(!c){l=u+1;break}continue}s===-1&&(c=!1,s=u+1),i===46?n===-1?n=u:a!==1&&(a=1):n!==-1&&(a=-1)}return n===-1||s===-1||a===0||a===1&&n===s-1&&n===l+1?s!==-1&&(l===0&&f?r.base=r.name=e.slice(1,s):r.base=r.name=e.slice(l,s)):(l===0&&f?(r.name=e.slice(1,n),r.base=e.slice(1,s)):(r.name=e.slice(l,n),r.base=e.slice(l,s)),r.ext=e.slice(n,s)),l>0?r.dir=e.slice(0,l-1):f&&(r.dir="/"),r},sep:"/",delimiter:":",win32:null,posix:null};return g.posix=g,m=g,m}export{S as r};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e,aH as r,r as n,p as o,T as i,s as a}from"./index-2c1VoOd9.js";const s=({...t})=>e.jsxs("div",{...t,children:[e.jsx("h3",{children:"End User License Agreement for Blocklet Server"}),e.jsxs("p",{children:["Blocklet Server License Agreement ",r.COPYRIGHT_OWNER," version 2020-08-28"]}),e.jsx("p",{children:"Blocklet Server LICENSE AGREEMENT"}),e.jsxs("p",{children:["PLEASE READ THIS END USER LICENCE AGREEMENT CAREFULLY. This Blocklet Server License Agreement ('Agreement') is a legal agreement between you (the 'End User') and ",r.COPYRIGHT_OWNER," (ARCBLOCK) for the Blocklet Server software (the 'Software') licensed to End User hereunder and supplied to End User. The term Software includes any APIs, software modules, and any associated materials and 'online' or electronic documentation. This Agreement applies to End User's use of the Software but it shall be superseded by any signed agreement between End User and ARCBLOCK concerning the Software."]}),e.jsx("p",{children:"By installing or using the Software, You agree to accept and to be bound by this Agreement at all times. If You do not agree with one of these, please do not install or use the Software."}),e.jsx("h4",{children:"1. Software license"}),e.jsx("p",{children:"Notwithstanding any reference to 'sale' or 'purchase', the Software is licensed, not sold. Subject to the terms and conditions of this Agreement, ARCBLOCK grants End User a non-exclusive, non-transferable right to access and use the Software as part of the services for End User's use ('Authorized Use') in object form in the products, versions, and number of installed instances as purchased from ARCBLOCK."}),e.jsx("h4",{children:"2. Limitations"}),e.jsx("p",{children:"2.1. Restrictions. End User shall not itself, or through any parent, subsidiary, affiliate, agent or other third party: (a) sell, lease, license, distribute, sublicense or otherwise transfer in whole or in part, the Software to a third party; (b) decompile, disassemble, translate, reverse engineer or otherwise attempt to derive source code from the Software except to the limited extent, if any, that applicable law permits such acts notwithstanding any contractual prohibitions, provided, however, before End User exercises any rights that End User believes to be entitled to based on mandatory law, End User shall provide ARCBLOCK with thirty (30) days prior written notice and provide all reasonably requested information to allow ARCBLOCK to assess End User's claim and, at ARCBLOCK sole discretion, to provide alternatives that reduce any adverse impact on ARCBLOCK's intellectual property or other rights; (c) allow access or permit use of the Software by any third party except authorized third party contractors solely to provide services to End User, provided that End User shall be liable for all acts and omissions of such authorized third party contractors; (d) modify or create derivative works based upon the Software; (e) disclose the results of any benchmark test of the Software to any third party; (f) change any proprietary rights notices which appear in the Software; or (g) circumvent the license keys embedded within the Software."}),e.jsx("p",{children:"2.2. Software Transfer. Upon written consent from ARCBLOCK, which will not be unreasonably withheld, End User may permanently transfer all of its rights under this Agreement; provided that the recipient agrees to the terms of this Agreement."}),e.jsx("p",{children:"2.3. High Risk Activities. The Software is not intended for use in hazardous environments requiring fail safe performance (such as, without limitation, the planning, construction, maintenance, control, or direct operation of nuclear facilities, aircraft navigation or communication systems, air traffic control, medical device and life support machines, or weapon systems) in which the failure of the Software could lead to death, personal injury or physical and environmental damage ('High Risk Activities'). Accordingly, this Agreement excludes any High Risk Activities and End User agrees not to use the Software in connection with High Risk Activities."}),e.jsx("h4",{children:"3. Ownership"}),e.jsx("p",{children:"The Software is protected by copyright laws and international copyright treaties, as well as other intellectual property laws and treaties. ARCBLOCK owns all rights, title and interest in the copyrights, patents and all other intellectual property rights in and to the Software and any accompanying printed materials, and all derivative works thereof."}),e.jsx("h4",{children:"4. Open source programs"}),e.jsx("p",{children:"The Software may include individual open source software components, each of which has its own copyright and its own applicable license conditions. The open source software components are licensed to End User under the terms of the applicable open source license conditions and/or copyright notices that can be found in the licenses file, the related documentation or other materials accompanying the Software."}),e.jsx("h4",{children:"5. Trademarks"}),e.jsx("p",{children:"The marks 'ARCBLOCK', ‘BLOCKLETS’ and ‘Blocklet Server’ are trademarks of ARCBLOCK. ARCBLOCK's failure to list a trademark in this Section shall not constitute a waiver of any trademark rights. All other trademarks in the Software not owned by ARCBLOCK are the property of their respective owners."}),e.jsx("h4",{children:"6. Disclaimer and Warranty"}),e.jsx("p",{children:"6.1. DISCLAIMER OF WARRANTIES. THE SOFTWARE IS PROVIDED 'AS IS' WITHOUT WARRANTY OF ANY KIND AND ARCBLOCK EXPRESSLY DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED OR ARISING OUT OF A COURSE OF CONDUCT OR COURSE OF DEALING, INCLUDING ALL WARRANTIES OF TITLE, PERFORMANCE, USE, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON INFRINGEMENT AND THE ABSENCE OF LATENT OR OTHER DEFECTS, WHETHER OR NOT DISCOVERABLE. ARCBLOCK MAKES NO WARRANTY REGARDING NON INTERRUPTION OF USE. NO ORAL OR WRITTEN STATEMENT PROVIDED BY ARCBLOCK SHALL CREATE ANY WARRANTY."}),e.jsx("p",{children:"6.2. LIMITATION OF LIABILITY. THE ENTIRE RISK AS TO THE RESULTS AND PERFORMANCE OF THE SOFTWARE IS ASSUMED BY END USER. ARCBLOCK SHALL NOT HAVE ANY LIABILITY TO END USER OR ANY OTHER PARTY FOR ANY INDIRECT, INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES WHATSOEVER, INCLUDING, BUT NOT LIMITED TO, LOSS OF REVENUE, PROFIT OR OPPORTUNITY, LOST OR DAMAGED DATA OR OTHER COMMERCIAL OR ECONOMIC LOSS, EVEN IF ARCBLOCK HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES, OR THEY ARE FORESEEABLE. ARCBLOCK'S MAXIMUM AGGREGATE LIABILITY RELATING TO THIS AGREEMENT OR THE SOFTWARE SHALL NOT EXCEED THE AMOUNT PAID BY END USER FOR THE SOFTWARE."}),e.jsx("p",{children:"6.3. ALLOCATION. THE PROVISIONS OF THIS SECTION ALLOCATE RISKS UNDER THIS AGREEMENT BETWEEN ARCBLOCK AND END USER. ARCBLOCK'S LICENSING FEES FOR THE SOFTWARE REFLECT THIS ALLOCATION OF RISKS AND LIMITATION OF LIABILITY. THE FOREGOING LIMITATIONS, EXCLUSIONS AND DISCLAIMERS APPLY TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, EVEN IF ANY REMEDY FAILS IN ITS ESSENTIAL PURPOSE."}),e.jsx("p",{children:"6.4. Limitation. Because some jurisdictions do not allow certain disclaimers, exclusions or limitations of warranties, damages or liability, the above disclaimers, exclusions or limitations may not apply to End User and, therefore, shall apply only to the maximum extent allowed under applicable law."}),e.jsx("h4",{children:"7. Term"}),e.jsx("p",{children:"This Agreement is effective until terminated. End Users may terminate the Agreement at any time by returning or destroying all copies of the Software and related documentation. End User's rights under this Agreement will terminate automatically if End User fails to comply with the Agreement."}),e.jsx("h4",{children:"8. Miscellaneous"}),e.jsx("p",{children:"8.1. Governing Law. This Agreement shall be governed by the laws of the State of Washington, without reference to the principles of conflicts of law. The provisions of the Uniform Computerized Information Transaction Act and United Nations Convention on Contracts for the International Sale of Goods shall not apply to this Agreement. Any litigation related to this Agreement shall be brought in the state or federal courts located in Washington, and only in those courts and each party irrevocably waives any objections to such venue. Notwithstanding anything to the contrary herein, ARCBLOCK shall be entitled to seek injunctive or other equitable relief, wherever ARCBLOCK deems appropriate in any jurisdiction, in order to preserve or enforce ARCBLOCK's rights for any breach or threatened breach of this Agreement."}),e.jsx("p",{children:"8.2. Severability. Every term, condition or provision of this Agreement is severable from the others. If a court or an arbitrator of competent jurisdiction holds any term, condition or provision of this Agreement to be invalid, unenforceable or illegal in whole or in part for any reason, the validity and enforceability of the remaining terms, conditions or provisions, or portions of them, will not be affected."}),e.jsx("p",{children:"8.3. Confidentiality. Except as expressly allowed by this Agreement, End User will not use or disclose any Software or related technology, idea, algorithm or information ('Confidential Information') except to the extent End User can document that it is generally available for use and disclosure by the public without charge or license. End User shall hold the Confidential Information in trust and confidence and avoid the disclosure or release thereof to any other person or entity by using the same degree of care as it uses to avoid unauthorized use, disclosure, or dissemination of its own Confidential Information of a similar nature, but not less than reasonable care. End User may disclose Confidential Information as required to comply with binding orders of governmental entities that have jurisdiction over it; provided that End User gives ARCBLOCK reasonable written notice to allow ARCBLOCK to seek a protective order or other appropriate remedy, discloses only such Confidential Information as is required by the governmental entity, and uses commercially reasonable efforts to obtain confidential treatment for any Confidential Information disclosed. End User recognizes and agrees that there is no adequate remedy at law for a breach of this Section, that such a breach would irreparably harm ARCBLOCK and that ARCBLOCK is entitled to equitable relief (without need to post a bond) with respect to any such breach or potential breach in addition to any other remedies."}),e.jsx("p",{children:"8.4. Indemnity. End User shall defend, indemnify and hold harmless ARCBLOCK, and its officers, directors, employees and agents (the ARCBLOCK indemnities’), from and against all suits, claims, demands, losses, liabilities, damages and expenses (including reasonable attorneys' fees and costs) that the ARCBLOCK Indemnities may suffer or incur in connection with: (i) any third party claim arising from End User's breach of this Agreement; and (ii) any infringement by End User of ARCBLOCK's intellectual property rights in the Software."}),e.jsx("p",{children:"8.5. Entire Agreement and Waiver. The Agreement is the sole, final and entire agreement between the parties with respect to the subject matter hereof, may only be amended in writing signed by both ARCBLOCK License parties. A failure or delay in enforcing any provisions, exercising any option or requiring performance, be construed to be a waiver by ARCBLOCK."}),e.jsx("p",{children:"8.6. Marketing. ARCBLOCK may use End User's name and company logo on its customer list and web site, and link to End User's web site."}),e.jsx("p",{children:"8.7. Independent Contractor. The relationship of the parties is that of independent contractors. Neither party will be deemed to be the legal representative of the other nor will it have any right to bind the other party to any contract or commitment. This Agreement does not, and will not, be construed to create an employer employee, agency, joint venture or partnership relationship between the parties. Each party agrees to assume complete responsibility for its own employees regarding federal or state laws, including employers' liability and tax withholding, worker's compensation, social security, unemployment insurance, and OSHA requirements."}),e.jsx("p",{children:"8.8. Notices. All notices must be in writing and will be effective three (3) days after the date sent to each party's corporate headquarters."}),e.jsx("p",{children:"8.9. Audit. During the term of this Agreement and for one (1) year following termination or expiration (but no more than once in a calendar year), ARCBLOCK and its auditors may inspect End User's records relating to its reproduction and use of the Software for the purposes of verifying End User's compliance with this Agreement. End User shall cooperate fully with ARCBLOCK and its auditors in conducting audits and provide reasonable assistance. If an underpayment is discovered, End User shall promptly pay such amount and End User shall reimburse ARCBLOCK for the cost of the audit."}),e.jsx("p",{children:`8.10. Government Regulation. End User acknowledges that the Software is subject to export restrictions by the U.S. government and import restrictions by certain foreign governments. End User may not export or re-export the Software except in compliance with the U.S. Export Administration Act and the related rules and regulations and similar non-U.S. government restrictions, if applicable. End User shall not and shall not allow any third party to remove or export from the United States or allow the export or re export of any part of the Software or any direct product thereof: (i) into (or to a national or resident of) any embargoed or terrorist supporting country; (ii) to anyone on the U.S. Commerce Department's Table of Denial Orders or U.S. Treasury Department's list of Specially Designated Nationals; (iii) to any country to which such export or re export is restricted or prohibited, or as to which the U.S. government or any agency thereof requires an export license or other governmental approval at the time of export or re export without first obtaining such license or approval; or (iv) otherwise in violation of any export or import restrictions, laws or regulations of any United States or foreign agency or authority. End User agrees to the foregoing and warrants that it is not located in, under the control of, or a national or resident of any such prohibited country or on any such prohibited party list. The Software is further restricted from being used for terrorist activity, or for the design or development of nuclear, chemical, or biological weapons or missile technology without the prior permission of the U.S. government. The Software and accompanying documentation are deemed to be "commercial computer software" and "commercial computer software documentation", respectively, pursuant to DFAR Section 227.7202 and FAR Section 12.212(b), as applicable. Any use, modification, reproduction, release, performing, displaying or disclosing of the Software and related documentation by the U.S. Government shall be governed solely by the terms of this Agreement.`})]});function h(){const{t}=n.useContext(o);return e.jsxs(l,{children:[e.jsx(i,{component:"h2",variant:"h4",className:"page-header",color:"textPrimary",children:t("setup.steps.eula")}),e.jsx(s,{})]})}const l=a.main`
|
|
1
|
+
import{j as e,aH as r,r as n,p as o,T as i,s as a}from"./index-DN1FR838.js";const s=({...t})=>e.jsxs("div",{...t,children:[e.jsx("h3",{children:"End User License Agreement for Blocklet Server"}),e.jsxs("p",{children:["Blocklet Server License Agreement ",r.COPYRIGHT_OWNER," version 2020-08-28"]}),e.jsx("p",{children:"Blocklet Server LICENSE AGREEMENT"}),e.jsxs("p",{children:["PLEASE READ THIS END USER LICENCE AGREEMENT CAREFULLY. This Blocklet Server License Agreement ('Agreement') is a legal agreement between you (the 'End User') and ",r.COPYRIGHT_OWNER," (ARCBLOCK) for the Blocklet Server software (the 'Software') licensed to End User hereunder and supplied to End User. The term Software includes any APIs, software modules, and any associated materials and 'online' or electronic documentation. This Agreement applies to End User's use of the Software but it shall be superseded by any signed agreement between End User and ARCBLOCK concerning the Software."]}),e.jsx("p",{children:"By installing or using the Software, You agree to accept and to be bound by this Agreement at all times. If You do not agree with one of these, please do not install or use the Software."}),e.jsx("h4",{children:"1. Software license"}),e.jsx("p",{children:"Notwithstanding any reference to 'sale' or 'purchase', the Software is licensed, not sold. Subject to the terms and conditions of this Agreement, ARCBLOCK grants End User a non-exclusive, non-transferable right to access and use the Software as part of the services for End User's use ('Authorized Use') in object form in the products, versions, and number of installed instances as purchased from ARCBLOCK."}),e.jsx("h4",{children:"2. Limitations"}),e.jsx("p",{children:"2.1. Restrictions. End User shall not itself, or through any parent, subsidiary, affiliate, agent or other third party: (a) sell, lease, license, distribute, sublicense or otherwise transfer in whole or in part, the Software to a third party; (b) decompile, disassemble, translate, reverse engineer or otherwise attempt to derive source code from the Software except to the limited extent, if any, that applicable law permits such acts notwithstanding any contractual prohibitions, provided, however, before End User exercises any rights that End User believes to be entitled to based on mandatory law, End User shall provide ARCBLOCK with thirty (30) days prior written notice and provide all reasonably requested information to allow ARCBLOCK to assess End User's claim and, at ARCBLOCK sole discretion, to provide alternatives that reduce any adverse impact on ARCBLOCK's intellectual property or other rights; (c) allow access or permit use of the Software by any third party except authorized third party contractors solely to provide services to End User, provided that End User shall be liable for all acts and omissions of such authorized third party contractors; (d) modify or create derivative works based upon the Software; (e) disclose the results of any benchmark test of the Software to any third party; (f) change any proprietary rights notices which appear in the Software; or (g) circumvent the license keys embedded within the Software."}),e.jsx("p",{children:"2.2. Software Transfer. Upon written consent from ARCBLOCK, which will not be unreasonably withheld, End User may permanently transfer all of its rights under this Agreement; provided that the recipient agrees to the terms of this Agreement."}),e.jsx("p",{children:"2.3. High Risk Activities. The Software is not intended for use in hazardous environments requiring fail safe performance (such as, without limitation, the planning, construction, maintenance, control, or direct operation of nuclear facilities, aircraft navigation or communication systems, air traffic control, medical device and life support machines, or weapon systems) in which the failure of the Software could lead to death, personal injury or physical and environmental damage ('High Risk Activities'). Accordingly, this Agreement excludes any High Risk Activities and End User agrees not to use the Software in connection with High Risk Activities."}),e.jsx("h4",{children:"3. Ownership"}),e.jsx("p",{children:"The Software is protected by copyright laws and international copyright treaties, as well as other intellectual property laws and treaties. ARCBLOCK owns all rights, title and interest in the copyrights, patents and all other intellectual property rights in and to the Software and any accompanying printed materials, and all derivative works thereof."}),e.jsx("h4",{children:"4. Open source programs"}),e.jsx("p",{children:"The Software may include individual open source software components, each of which has its own copyright and its own applicable license conditions. The open source software components are licensed to End User under the terms of the applicable open source license conditions and/or copyright notices that can be found in the licenses file, the related documentation or other materials accompanying the Software."}),e.jsx("h4",{children:"5. Trademarks"}),e.jsx("p",{children:"The marks 'ARCBLOCK', ‘BLOCKLETS’ and ‘Blocklet Server’ are trademarks of ARCBLOCK. ARCBLOCK's failure to list a trademark in this Section shall not constitute a waiver of any trademark rights. All other trademarks in the Software not owned by ARCBLOCK are the property of their respective owners."}),e.jsx("h4",{children:"6. Disclaimer and Warranty"}),e.jsx("p",{children:"6.1. DISCLAIMER OF WARRANTIES. THE SOFTWARE IS PROVIDED 'AS IS' WITHOUT WARRANTY OF ANY KIND AND ARCBLOCK EXPRESSLY DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED OR ARISING OUT OF A COURSE OF CONDUCT OR COURSE OF DEALING, INCLUDING ALL WARRANTIES OF TITLE, PERFORMANCE, USE, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON INFRINGEMENT AND THE ABSENCE OF LATENT OR OTHER DEFECTS, WHETHER OR NOT DISCOVERABLE. ARCBLOCK MAKES NO WARRANTY REGARDING NON INTERRUPTION OF USE. NO ORAL OR WRITTEN STATEMENT PROVIDED BY ARCBLOCK SHALL CREATE ANY WARRANTY."}),e.jsx("p",{children:"6.2. LIMITATION OF LIABILITY. THE ENTIRE RISK AS TO THE RESULTS AND PERFORMANCE OF THE SOFTWARE IS ASSUMED BY END USER. ARCBLOCK SHALL NOT HAVE ANY LIABILITY TO END USER OR ANY OTHER PARTY FOR ANY INDIRECT, INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES WHATSOEVER, INCLUDING, BUT NOT LIMITED TO, LOSS OF REVENUE, PROFIT OR OPPORTUNITY, LOST OR DAMAGED DATA OR OTHER COMMERCIAL OR ECONOMIC LOSS, EVEN IF ARCBLOCK HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES, OR THEY ARE FORESEEABLE. ARCBLOCK'S MAXIMUM AGGREGATE LIABILITY RELATING TO THIS AGREEMENT OR THE SOFTWARE SHALL NOT EXCEED THE AMOUNT PAID BY END USER FOR THE SOFTWARE."}),e.jsx("p",{children:"6.3. ALLOCATION. THE PROVISIONS OF THIS SECTION ALLOCATE RISKS UNDER THIS AGREEMENT BETWEEN ARCBLOCK AND END USER. ARCBLOCK'S LICENSING FEES FOR THE SOFTWARE REFLECT THIS ALLOCATION OF RISKS AND LIMITATION OF LIABILITY. THE FOREGOING LIMITATIONS, EXCLUSIONS AND DISCLAIMERS APPLY TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, EVEN IF ANY REMEDY FAILS IN ITS ESSENTIAL PURPOSE."}),e.jsx("p",{children:"6.4. Limitation. Because some jurisdictions do not allow certain disclaimers, exclusions or limitations of warranties, damages or liability, the above disclaimers, exclusions or limitations may not apply to End User and, therefore, shall apply only to the maximum extent allowed under applicable law."}),e.jsx("h4",{children:"7. Term"}),e.jsx("p",{children:"This Agreement is effective until terminated. End Users may terminate the Agreement at any time by returning or destroying all copies of the Software and related documentation. End User's rights under this Agreement will terminate automatically if End User fails to comply with the Agreement."}),e.jsx("h4",{children:"8. Miscellaneous"}),e.jsx("p",{children:"8.1. Governing Law. This Agreement shall be governed by the laws of the State of Washington, without reference to the principles of conflicts of law. The provisions of the Uniform Computerized Information Transaction Act and United Nations Convention on Contracts for the International Sale of Goods shall not apply to this Agreement. Any litigation related to this Agreement shall be brought in the state or federal courts located in Washington, and only in those courts and each party irrevocably waives any objections to such venue. Notwithstanding anything to the contrary herein, ARCBLOCK shall be entitled to seek injunctive or other equitable relief, wherever ARCBLOCK deems appropriate in any jurisdiction, in order to preserve or enforce ARCBLOCK's rights for any breach or threatened breach of this Agreement."}),e.jsx("p",{children:"8.2. Severability. Every term, condition or provision of this Agreement is severable from the others. If a court or an arbitrator of competent jurisdiction holds any term, condition or provision of this Agreement to be invalid, unenforceable or illegal in whole or in part for any reason, the validity and enforceability of the remaining terms, conditions or provisions, or portions of them, will not be affected."}),e.jsx("p",{children:"8.3. Confidentiality. Except as expressly allowed by this Agreement, End User will not use or disclose any Software or related technology, idea, algorithm or information ('Confidential Information') except to the extent End User can document that it is generally available for use and disclosure by the public without charge or license. End User shall hold the Confidential Information in trust and confidence and avoid the disclosure or release thereof to any other person or entity by using the same degree of care as it uses to avoid unauthorized use, disclosure, or dissemination of its own Confidential Information of a similar nature, but not less than reasonable care. End User may disclose Confidential Information as required to comply with binding orders of governmental entities that have jurisdiction over it; provided that End User gives ARCBLOCK reasonable written notice to allow ARCBLOCK to seek a protective order or other appropriate remedy, discloses only such Confidential Information as is required by the governmental entity, and uses commercially reasonable efforts to obtain confidential treatment for any Confidential Information disclosed. End User recognizes and agrees that there is no adequate remedy at law for a breach of this Section, that such a breach would irreparably harm ARCBLOCK and that ARCBLOCK is entitled to equitable relief (without need to post a bond) with respect to any such breach or potential breach in addition to any other remedies."}),e.jsx("p",{children:"8.4. Indemnity. End User shall defend, indemnify and hold harmless ARCBLOCK, and its officers, directors, employees and agents (the ARCBLOCK indemnities’), from and against all suits, claims, demands, losses, liabilities, damages and expenses (including reasonable attorneys' fees and costs) that the ARCBLOCK Indemnities may suffer or incur in connection with: (i) any third party claim arising from End User's breach of this Agreement; and (ii) any infringement by End User of ARCBLOCK's intellectual property rights in the Software."}),e.jsx("p",{children:"8.5. Entire Agreement and Waiver. The Agreement is the sole, final and entire agreement between the parties with respect to the subject matter hereof, may only be amended in writing signed by both ARCBLOCK License parties. A failure or delay in enforcing any provisions, exercising any option or requiring performance, be construed to be a waiver by ARCBLOCK."}),e.jsx("p",{children:"8.6. Marketing. ARCBLOCK may use End User's name and company logo on its customer list and web site, and link to End User's web site."}),e.jsx("p",{children:"8.7. Independent Contractor. The relationship of the parties is that of independent contractors. Neither party will be deemed to be the legal representative of the other nor will it have any right to bind the other party to any contract or commitment. This Agreement does not, and will not, be construed to create an employer employee, agency, joint venture or partnership relationship between the parties. Each party agrees to assume complete responsibility for its own employees regarding federal or state laws, including employers' liability and tax withholding, worker's compensation, social security, unemployment insurance, and OSHA requirements."}),e.jsx("p",{children:"8.8. Notices. All notices must be in writing and will be effective three (3) days after the date sent to each party's corporate headquarters."}),e.jsx("p",{children:"8.9. Audit. During the term of this Agreement and for one (1) year following termination or expiration (but no more than once in a calendar year), ARCBLOCK and its auditors may inspect End User's records relating to its reproduction and use of the Software for the purposes of verifying End User's compliance with this Agreement. End User shall cooperate fully with ARCBLOCK and its auditors in conducting audits and provide reasonable assistance. If an underpayment is discovered, End User shall promptly pay such amount and End User shall reimburse ARCBLOCK for the cost of the audit."}),e.jsx("p",{children:`8.10. Government Regulation. End User acknowledges that the Software is subject to export restrictions by the U.S. government and import restrictions by certain foreign governments. End User may not export or re-export the Software except in compliance with the U.S. Export Administration Act and the related rules and regulations and similar non-U.S. government restrictions, if applicable. End User shall not and shall not allow any third party to remove or export from the United States or allow the export or re export of any part of the Software or any direct product thereof: (i) into (or to a national or resident of) any embargoed or terrorist supporting country; (ii) to anyone on the U.S. Commerce Department's Table of Denial Orders or U.S. Treasury Department's list of Specially Designated Nationals; (iii) to any country to which such export or re export is restricted or prohibited, or as to which the U.S. government or any agency thereof requires an export license or other governmental approval at the time of export or re export without first obtaining such license or approval; or (iv) otherwise in violation of any export or import restrictions, laws or regulations of any United States or foreign agency or authority. End User agrees to the foregoing and warrants that it is not located in, under the control of, or a national or resident of any such prohibited country or on any such prohibited party list. The Software is further restricted from being used for terrorist activity, or for the design or development of nuclear, chemical, or biological weapons or missile technology without the prior permission of the U.S. government. The Software and accompanying documentation are deemed to be "commercial computer software" and "commercial computer software documentation", respectively, pursuant to DFAR Section 227.7202 and FAR Section 12.212(b), as applicable. Any use, modification, reproduction, release, performing, displaying or disclosing of the Software and related documentation by the U.S. Government shall be governed solely by the terms of this Agreement.`})]});function h(){const{t}=n.useContext(o);return e.jsxs(l,{children:[e.jsx(i,{component:"h2",variant:"h4",className:"page-header",color:"textPrimary",children:t("setup.steps.eula")}),e.jsx(s,{})]})}const l=a.main`
|
|
2
2
|
.page-header {
|
|
3
3
|
display: flex;
|
|
4
4
|
justify-content: space-between;
|