@abtnode/webapp 1.16.30-beta-5d9c2c41 → 1.16.30-beta-e7a90fb2
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/{Add-240wNjwq.js → Add-nimIss-R.js} +1 -1
- package/dist/assets/{ArrowDropDown-C_UcQOEh.js → ArrowDropDown-SDLo8AU6.js} +1 -1
- package/dist/assets/{Autocomplete-BcT7Oksd.js → Autocomplete-mLMpcAAZ.js} +1 -1
- package/dist/assets/{Breadcrumbs-6lYKQe5b.js → Breadcrumbs-Bt0YLDiP.js} +1 -1
- package/dist/assets/{ButtonGroup-D2VNVq8p.js → ButtonGroup-BIMC9S6K.js} +1 -1
- package/dist/assets/{CheckCircle-C3oHDZBR.js → CheckCircle-__Xpcyhc.js} +1 -1
- package/dist/assets/{ChevronLeft-CsFylH21.js → ChevronLeft-DFREsjdS.js} +1 -1
- package/dist/assets/{ChevronRight-DB27L3xw.js → ChevronRight-SbPIKwoC.js} +1 -1
- package/dist/assets/{Close-B0TqWuc9.js → Close-BpEmkp97.js} +1 -1
- package/dist/assets/{Delete-DmepPquU.js → Delete-B-wviuP1.js} +1 -1
- package/dist/assets/DeleteOutline-DU3a7Mie.js +1 -0
- package/dist/assets/DeleteOutline-Dy_sSwNK.js +1 -0
- package/dist/assets/{Done-DcWcwr60.js → Done-DEwehpwv.js} +1 -1
- package/dist/assets/{Edit-D1BvuH2M.js → Edit-DK6KZi0P.js} +1 -1
- package/dist/assets/{EditIcon-CDlQ1Y8-.js → EditIcon-FDN14b0G.js} +1 -1
- package/dist/assets/{ExpandMore-CK0-Eu1n.js → ExpandMore-CoMbEsJD.js} +1 -1
- package/dist/assets/{FilterList-Bw1ZqePf.js → FilterList-BSbt4VER.js} +1 -1
- package/dist/assets/{Google-DmQIUmmK.js → Google-DvvB9-RU.js} +1 -1
- package/dist/assets/{Https-CdebkXl3.js → Https-CHMUgx6-.js} +1 -1
- package/dist/assets/{InputAdornment-BRIOp0gH.js → InputAdornment-C_X3KhDA.js} +1 -1
- package/dist/assets/{InputLabel-C31crC9j.js → InputLabel-qD-ek4kX.js} +1 -1
- package/dist/assets/{LastPage-15pWD2wJ.js → LastPage-DRexSCl8.js} +1 -1
- package/dist/assets/{Launch-CMM_hnCO.js → Launch-CXTnJ_ZP.js} +1 -1
- package/dist/assets/{Link-C4-IDwJx.js → Link-BVKoqsek.js} +1 -1
- package/dist/assets/{LoadingButton-hwdCNe1X.js → LoadingButton-DHGZB25W.js} +1 -1
- package/dist/assets/{LockIcon-DGv96agC.js → LockIcon-DGE39kAx.js} +1 -1
- package/dist/assets/{Loop-B2Vl1OiI.js → Loop-DQi2cfGf.js} +1 -1
- package/dist/assets/{MoreHoriz-q-g-RPDL.js → MoreHoriz-BXgBR7_l.js} +1 -1
- package/dist/assets/{MoreVert-s3M1upT5.js → MoreVert-xXktVXrB.js} +1 -1
- package/dist/assets/{Pagination-B5dMIe8j.js → Pagination-DnPfWmf4.js} +1 -1
- package/dist/assets/{Public-CF6xMrln.js → Public-DZG9u5nc.js} +1 -1
- package/dist/assets/{SchemaReference.es-BLQMCHdi.js → SchemaReference.es-DknvTEzi.js} +1 -1
- package/dist/assets/{Search-B0peOjeQ.js → Search-D2g_vALD.js} +1 -1
- package/dist/assets/{Select-C--LsVoO.js → Select-DEE1eR0K.js} +1 -1
- package/dist/assets/{Skeleton-CaItownp.js → Skeleton-m_lkZ6lH.js} +1 -1
- package/dist/assets/{Slider-BA1jwO1h.js → Slider-CBmIjsNj.js} +1 -1
- package/dist/assets/{Stepper-BQ3ikYJX.js → Stepper-D4h3SXw3.js} +1 -1
- package/dist/assets/{TextField-D1TVUQl2.js → TextField-Cml5LlcX.js} +1 -1
- package/dist/assets/{ToggleButtonGroup-CbsnXtMY.js → ToggleButtonGroup-DdMGIkJV.js} +1 -1
- package/dist/assets/{ViewList-C8_Q1ZaL.js → ViewList-Lg33z4FS.js} +1 -1
- package/dist/assets/{actions-DkIxbagz.js → actions-CCw2fiQZ.js} +1 -1
- package/dist/assets/actions-Rsfuoore.js +11 -0
- package/dist/assets/{agreement-DxK9sfKx.js → agreement-C2LFpgfH.js} +1 -1
- package/dist/assets/api-_ETsEoGC.js +1 -0
- package/dist/assets/{app-avatar-C7ZZG5lQ.js → app-avatar-Z0pI74yn.js} +1 -1
- package/dist/assets/{audit-logs-CrN9QYVu.js → audit-logs-CGjF68d3.js} +1 -1
- package/dist/assets/blocklet-D8qZlMLE.js +1 -0
- package/dist/assets/{brace-fold.es-Byk4OhlU.js → brace-fold.es-D-xxO9tk.js} +1 -1
- package/dist/assets/{bundle-avatar-BDTyLzjh.js → bundle-avatar-k-apmNe0.js} +1 -1
- package/dist/assets/{chart-BXerkWdt.js → chart-BHydpm-Q.js} +1 -1
- package/dist/assets/{click-to-copy-CK-Mkhd0.js → click-to-copy--CxmqZHP.js} +1 -1
- package/dist/assets/{closebrackets.es-CTZfsjeS.js → closebrackets.es-CV5tiUGf.js} +1 -1
- package/dist/assets/{codemirror.es-CosWD2iy.js → codemirror.es-BSwJ_jke.js} +1 -1
- package/dist/assets/{comment.es-DxS_C5_M.js → comment.es-CN939E1H.js} +1 -1
- package/dist/assets/{config-navigation-D8N_TmOY.js → config-navigation-BKucf5SM.js} +1 -1
- package/dist/assets/{delete-confirm-BKnCoOpO.js → delete-confirm-DOwYzFRf.js} +1 -1
- package/dist/assets/{detail-BmlatkjD.js → detail-BBO1G3ZP.js} +3 -3
- package/dist/assets/{dialog.es-Bg0EeV0q.js → dialog.es-K7-bZIzF.js} +1 -1
- package/dist/assets/{download-C0fC4yYB.js → download-D88K6-GQ.js} +1 -1
- package/dist/assets/{foldgutter.es-pqkwUOpu.js → foldgutter.es-DPSTEVXv.js} +1 -1
- package/dist/assets/getValidReactChildren-86LVJ_ka.js +1 -0
- package/dist/assets/{hint.es-EAu4kf7y.js → hint.es-DHTbet23.js} +1 -1
- package/dist/assets/{hint.es2-BFhwDvJp.js → hint.es2-DaSN5I8T.js} +1 -1
- package/dist/assets/{iframe-DCJ7N4jM.js → iframe-DjGjc5CU.js} +1 -1
- package/dist/assets/{index-DIrIbW6w.js → index-6hnZjYIo.js} +1 -1
- package/dist/assets/{index-BPY6z3Rs.js → index-AO3oCF1x.js} +3 -3
- package/dist/assets/{index-B4PWSsiR.js → index-BGI6bUJP.js} +1 -1
- package/dist/assets/{index-7fpoPAbz.js → index-BGXvULAc.js} +1 -1
- package/dist/assets/{index-CRLxFVWY.js → index-BHdqgom8.js} +4 -4
- package/dist/assets/{index-Ch9-jINY.js → index-BKhW6tEi.js} +1 -1
- package/dist/assets/{index-c1dR1RcA.js → index-BPHA36fg.js} +1 -1
- package/dist/assets/{index-C8xCbxUE.js → index-Blc0lQcO.js} +1 -1
- package/dist/assets/{index-CmFVyjgY.js → index-BsbdXNYr.js} +1 -1
- package/dist/assets/{index-CheSXyoA.js → index-C1KbWOak.js} +3 -3
- package/dist/assets/{index-CuOQXV32.js → index-C4Q4NeqR.js} +1 -1
- package/dist/assets/{index-BUnnmW1r.js → index-CAo0UcQ2.js} +1 -1
- package/dist/assets/{index-C1PiAS_Y.js → index-CBTLvRHC.js} +1 -1
- package/dist/assets/{index-BH1hVJpW.js → index-CE0mBRzM.js} +1 -1
- package/dist/assets/{index-nsaxnXRB.js → index-CF-WslF6.js} +1 -1
- package/dist/assets/{index-wRDZOUMs.js → index-CeV4jn0N.js} +1 -1
- package/dist/assets/{index-M9-_GBvS.js → index-CgsfYcwc.js} +1 -1
- package/dist/assets/{index-CIV9Tvzf.js → index-ChCCjycd.js} +1 -1
- package/dist/assets/{index-DnZQlEKp.js → index-Co3JrBLr.js} +1 -1
- package/dist/assets/{index-DxuvuH9i.js → index-Cpw6Ga8g.js} +1 -1
- package/dist/assets/index-CqrpWUFf.js +21 -0
- package/dist/assets/{index-BI-i5kKF.js → index-D-FCWV-1.js} +1 -1
- package/dist/assets/{index-D8KWuR1-.js → index-D3GDvQdK.js} +1 -1
- package/dist/assets/{index-BJXHdeeV.js → index-D3_NSRjd.js} +1 -1
- package/dist/assets/{index-B_FDrImE.js → index-DBP_eUf8.js} +1 -1
- package/dist/assets/{index-Cu-S2eZJ.js → index-DBjm0dlo.js} +1 -1
- package/dist/assets/{index-DqnDo97c.js → index-DGNm6YxS.js} +1 -1
- package/dist/assets/{index-BMfXnuvp.js → index-DKrhe0Pd.js} +1 -1
- package/dist/assets/index-DUXbXc9f.js +68 -0
- package/dist/assets/index-D_qCD-1x.js +80 -0
- package/dist/assets/{index-CZrhCkal.js → index-Daw6hKm4.js} +1 -1
- package/dist/assets/index-De9X8iTH.js +292 -0
- package/dist/assets/{index-DdIvdpgD.js → index-Dj8gJMNb.js} +1 -1
- package/dist/assets/{index-D9XZ1bG6.js → index-Dx95ER6O.js} +1 -1
- package/dist/assets/{index-qU6j-u6W.js → index-DxgXNSd2.js} +14 -14
- package/dist/assets/{index-de76ek1K.js → index-Mn9Cn8cU.js} +1 -1
- package/dist/assets/{index-BeN4ZgCH.js → index-TQDBcpeB.js} +1 -1
- package/dist/assets/{index-CGjwUKrb.js → index-ZTQq6T3W.js} +1 -1
- package/dist/assets/{index-CDRbsQoL.js → index-cqDbkK4O.js} +1 -1
- package/dist/assets/{index-DivETz-Z.js → index-f7aL1bUo.js} +5 -5
- package/dist/assets/{index-CDre3mnK.js → index-guvEPGrM.js} +3 -3
- package/dist/assets/{index-Cx3miQZ4.js → index-mgj182ld.js} +3 -2
- package/dist/assets/{index-ClZOvGLQ.js → index-o8JHOBc-.js} +1 -1
- package/dist/assets/{index-BvnS-7-1.js → index-wB3ekx1K.js} +1 -1
- package/dist/assets/{index.es-CZDnnfg-.js → index.es-39a3Nx9Z.js} +1 -1
- package/dist/assets/{index.esm-Dkpk3RMi.js → index.esm-VCHOqK12.js} +1 -1
- package/dist/assets/{info-addon.es-B1aKFVvv.js → info-addon.es-BC4uTAVC.js} +1 -1
- package/dist/assets/{info.es-DTXDBN9z.js → info.es-BOB5BDAa.js} +1 -1
- package/dist/assets/{install-from-url-DjctVTOl.js → install-from-url-BlpJ_JCL.js} +1 -1
- package/dist/assets/{invitation-DSdBJgkC.js → invitation-B9vV54jI.js} +1 -1
- package/dist/assets/{is-path-prefix-equal-C6zlDhVp.js → is-path-prefix-equal-5RuRfdDZ.js} +1 -1
- package/dist/assets/{isEqual-0cnx2qOS.js → isEqual-BMA5WXPh.js} +1 -1
- package/dist/assets/{item-Dln-w3Iq.js → item-BCjdddLT.js} +1 -1
- package/dist/assets/{javascript.es-DKea0oPd.js → javascript.es-CKHSRONz.js} +1 -1
- package/dist/assets/{jump-to-line.es-DmWSMR-E.js → jump-to-line.es-BGiUhkkZ.js} +1 -1
- package/dist/assets/{jump.es-CQGzFoAd.js → jump.es-jlQKmx9y.js} +1 -1
- package/dist/assets/{line-BIpTQfTJ.js → line-BQ1AqKfx.js} +3 -3
- package/dist/assets/{lint.es-BAY5Woc0.js → lint.es-Ccw618G7.js} +1 -1
- package/dist/assets/{lint.es2-C4O9zzDQ.js → lint.es2-EOTuUPIZ.js} +1 -1
- package/dist/assets/{lint.es3-q80vs6e3.js → lint.es3-DvHlvUn_.js} +1 -1
- package/dist/assets/{list-header-DuWvRnX_.js → list-header-RtdpLA8N.js} +1 -1
- package/dist/assets/{log-U-Oy1msj.js → log-C240GbUG.js} +1 -1
- package/dist/assets/{lottie-D0zUdkp5.js → lottie-DlriAay1.js} +1 -1
- package/dist/assets/{matchbrackets.es-B_OCWqIS.js → matchbrackets.es-C5JsbqKa.js} +1 -1
- package/dist/assets/{memory-CESYopLm.js → memory-DmcKHXq0.js} +1 -1
- package/dist/assets/{mode.es-DVfsqtAx.js → mode.es-mDILARJO.js} +1 -1
- package/dist/assets/{mode.es2-gg_0Yels.js → mode.es2-BBLB98Wl.js} +1 -1
- package/dist/assets/{mode.es3-CWCOwidy.js → mode.es3-Bp7C6PMW.js} +1 -1
- package/dist/assets/{onlineParser.es-CTZOlUJG.js → onlineParser.es-BoSRyIcT.js} +1 -1
- package/dist/assets/{overview-D7OPOkGE.js → overview-_Rxbv1NB.js} +1 -1
- package/dist/assets/{react-Blm3BSvE.js → react-DuJ5ZkKy.js} +16 -16
- package/dist/assets/{redux-CaV6uiOr.js → redux-B1Qumh5U.js} +1 -1
- package/dist/assets/{resource-dialog-Cbfivwvi.js → resource-dialog-WWRI08PV.js} +1 -1
- package/dist/assets/{runtime-BE0JWW3n.js → runtime-5oxnTidw.js} +1 -1
- package/dist/assets/{schema-BKkMgYH9.js → schema-5ne-6Bp4.js} +1 -1
- package/dist/assets/sdk-Go6IWQIY.js +1 -0
- package/dist/assets/{search.es-CGDd2k_t.js → search.es-R2FORdVe.js} +1 -1
- package/dist/assets/{searchcursor.es-xO-dGzm1.js → searchcursor.es-DO5Jf4gN.js} +1 -1
- package/dist/assets/service-VyIQYaE6.js +1 -0
- package/dist/assets/{shorten-label-CZVhjulh.js → shorten-label-CZlXdSOl.js} +1 -1
- package/dist/assets/{show-hint.es-opE1QlXT.js → show-hint.es-Bx2uNweg.js} +1 -1
- package/dist/assets/{slicedToArray-C3_toPJB.js → slicedToArray-Bg3ityWL.js} +1 -1
- package/dist/assets/{spaces-Swq2BNwF.js → spaces-fC9EAj53.js} +1 -1
- package/dist/assets/{status-dc380TH5.js → status-BXJ91n7W.js} +1 -1
- package/dist/assets/{sublime.es-Bw3Iznmf.js → sublime.es-DHZMehLW.js} +1 -1
- package/dist/assets/{switch-control-CcMPAAj7.js → switch-control-BuiDLx3e.js} +1 -1
- package/dist/assets/{table-icons-TmY--eR2.js → table-icons-bAAAjGK1.js} +2 -2
- package/dist/assets/{team-CBZV1UuS.js → team-QnBuJ2rq.js} +1 -1
- package/dist/assets/{toUpper-Bjz0AMGp.js → toUpper-CFRRtQH6.js} +1 -1
- package/dist/assets/{traffic-wydTjZWz.js → traffic-CNgUOmfv.js} +1 -1
- package/dist/assets/{url-evaluation-Oli2ZbAu.js → url-evaluation-BTdmiGRO.js} +1 -1
- package/dist/assets/{url-join-BPHLmPis.js → url-join-CiWL3EAW.js} +1 -1
- package/dist/assets/{use-blocklet-info-for-connect-did-spaces-DRjxN2RW.js → use-blocklet-info-for-connect-did-spaces-CMsH-TzL.js} +1 -1
- package/dist/assets/{useLocalStorage-DABDAbRI.js → useLocalStorage-D6Ii7-Uk.js} +1 -1
- package/dist/assets/{useThemeProps-Cqic-E0U.js → useThemeProps-BlrL4N8K.js} +1 -1
- package/dist/assets/{util-DMkhCe5T.js → util-DSMcrouF.js} +1 -1
- package/dist/assets/{wait-container-7MRBml26.js → wait-container-BRhHYdS-.js} +1 -1
- package/dist/assets/{withStyles-mttjYCTj.js → withStyles-CHrv3QJu.js} +1 -1
- package/dist/assets/{wrap-locale-Dy0OLcMz.js → wrap-locale-D-OFTljj.js} +1 -1
- package/dist/index.html +1 -1
- package/dist/service-worker.js +1 -1
- package/package.json +1 -1
- package/dist/assets/DeleteOutline-o5TFeql0.js +0 -1
- package/dist/assets/actions-Drufb-pQ.js +0 -11
- package/dist/assets/api-DOcnwqon.js +0 -1
- package/dist/assets/blocklet-DX4HGT6b.js +0 -1
- package/dist/assets/getValidReactChildren-Bwdvi5zb.js +0 -1
- package/dist/assets/index-6XBeHuD_.js +0 -292
- package/dist/assets/index-B8Hu4oNh.js +0 -80
- package/dist/assets/index-CGyIRwUl.js +0 -21
- package/dist/assets/index-HwE3ySwC.js +0 -68
- package/dist/assets/sdk-DM3m0pIz.js +0 -1
- package/dist/assets/service-CqEmzSuD.js +0 -1
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
import{q as je,n as N,P as S,r as D,f as ye,j as e,C as V,i as Ce,u as de,t as K,v as ve,w as Se,D as Be,B as z,x as we,m as L,y as De,z as Ae,A as pe,E as $,F as Te,d as Ee,H as Ie,J as Le,K as se,M as Pe,N as W,O as oe,Q as j,R as Re,S as _,U as _e,V as Fe,X as Ne}from"./index-CRLxFVWY.js";import{_ as ne}from"./useLocalStorage-DABDAbRI.js";import{g as Ue,D as Oe}from"./index-CDRbsQoL.js";import{E as Me}from"./index-c1dR1RcA.js";import{B as le}from"./status-dc380TH5.js";import{D as We,u as ze,B as re}from"./actions-Drufb-pQ.js";import{l as ae}from"./index-BvnS-7-1.js";import{u as ue,W as $e}from"./url-evaluation-Oli2ZbAu.js";import{I as qe,B as Ve}from"./install-from-url-DjctVTOl.js";import{B as ie}from"./app-avatar-C7ZZG5lQ.js";import{d as Ke}from"./Add-240wNjwq.js";import{S as E}from"./index-ClZOvGLQ.js";import{i as Qe,a as Xe}from"./schema-BKkMgYH9.js";import{T as ce}from"./TextField-D1TVUQl2.js";import{F as He,S as Je}from"./Select-C--LsVoO.js";import"./FilterList-Bw1ZqePf.js";import"./useThemeProps-Cqic-E0U.js";import"./Delete-DmepPquU.js";import"./InputLabel-C31crC9j.js";import"./LastPage-15pWD2wJ.js";import"./index-BH1hVJpW.js";import"./redux-CaV6uiOr.js";import"./Search-B0peOjeQ.js";import"./MoreVert-s3M1upT5.js";import"./ButtonGroup-D2VNVq8p.js";import"./getValidReactChildren-Bwdvi5zb.js";import"./isEqual-0cnx2qOS.js";import"./index-D8KWuR1-.js";import"./Stepper-BQ3ikYJX.js";import"./ExpandMore-CK0-Eu1n.js";import"./index-C1PiAS_Y.js";const Ge=(p,c)=>{if(!p)return"";const m=new URL(p),l=new URLSearchParams(m.searchParams),b=new URL(je(m.origin,c));return b.search=l.toString(),b.toString()};function F({blocklet:p,skipAccessibilityCheck:c=!1,...m}){const{t:l}=D.useContext(ye),{urls:b,loading:n,recommendedUrl:u}=ue(p);if(n&&!c)return e.jsx(V,{size:12,...m});const f=c?b[0]:u;return f?e.jsx(Ze,{...m,children:e.jsx(Ye,{children:e.jsx(Ce,{href:f,target:"_blank",className:"blocklet-interface",underline:"hover",children:l("common.open")})})}):l("blocklet.router.noAccessibleUrl")}const Ye=N.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
margin: 4px 0;
|
|
4
|
-
`,Ze=N.div`
|
|
5
|
-
.blocklet-interface {
|
|
6
|
-
display: flex;
|
|
7
|
-
align-items: center;
|
|
8
|
-
justify-content: flex-start;
|
|
9
|
-
white-space: nowrap;
|
|
10
|
-
|
|
11
|
-
img {
|
|
12
|
-
margin-right: 4px;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
`;F.propTypes={blocklet:S.object.isRequired,skipAccessibilityCheck:S.bool};F.defaultProps={skipAccessibilityCheck:!1};function Q({onCancel:p,onSuccess:c}){const{info:m}=de(),{t:l}=K(),{api:b}=ve(),[n,u]=Se({loading:!1,title:"",titleError:"",description:"",descriptionError:"",isConnectOpen:!1}),f={title:o=>{var i,r;return((r=(i=Qe.messages({"*":l("blocklet.titleValidationError")}).validate(o))==null?void 0:i.error)==null?void 0:r.message)||""},description:o=>{var i,r;return((r=(i=Xe.messages({"*":l("blocklet.descriptionValidationError")}).validate(o))==null?void 0:i.error)==null?void 0:r.message)||""}},k=()=>{u({loading:!0,isConnectOpen:!0})},y=o=>{u({loading:!1,isConnectOpen:!1}),c(o)},C=()=>{u({loading:!1,isConnectOpen:!1})},v=o=>{const{value:i,name:r}=o.target;u({[`${r}Error`]:i?f[r](i):""})},B=o=>{const{value:i,name:r}=o.target,x=`${r}Error`;n[x]?u({[r]:i,[x]:i?f[r](i):""}):u({[r]:i})};return e.jsxs(e.Fragment,{children:[e.jsx(Be,{title:l("blocklet.installFromCreate"),fullWidth:!0,maxWidth:"sm",onClose:()=>p(),showCloseButton:!0,open:!0,actions:e.jsxs(e.Fragment,{children:[e.jsx(z,{onClick:o=>{o.stopPropagation(),p()},color:"inherit",children:l("common.cancel")}),e.jsxs(z,{onClick:o=>{o.stopPropagation(),k()},color:"primary","data-cy":"install-blocklet-next-step",variant:"contained",disabled:n.loading||n.titleError||n.descriptionError||!n.title||!n.description,style:{marginLeft:8},children:[n.loading&&e.jsx(V,{size:16}),l("common.create")]})]}),children:e.jsx(we,{component:"div",children:e.jsxs(L,{component:"div",children:[e.jsx(ce,{style:{marginBottom:24},label:`Blocklet ${l("common.title")}`,autoComplete:"off",variant:"outlined",fullWidth:!0,autoFocus:!0,name:"title",value:n.title,onBlur:v,onChange:B,error:!!n.titleError,helperText:n.titleError,disabled:n.loading}),e.jsx(ce,{label:`Blocklet ${l("common.description")}`,autoComplete:"off",variant:"outlined",fullWidth:!0,name:"description",value:n.description,onBlur:v,onChange:B,error:!!n.descriptionError,helperText:n.descriptionError,disabled:n.loading})]})})}),e.jsx(De,{popup:!0,open:n.isConnectOpen,forceConnected:!1,className:"launch-from-create-auth",action:"launch-free-blocklet-by-session",checkFn:b.get,checkTimeout:5*60*1e3,webWalletUrl:Ae(m),onSuccess:y,extraParams:{title:n.title,description:n.description},messages:{title:l("setup.keyPair.title"),scan:l("setup.keyPair.scan"),confirm:l("setup.keyPair.confirm"),success:l("setup.keyPair.success")},onClose:C})]})}Q.propTypes={onCancel:S.func.isRequired,onSuccess:S.func.isRequired};Q.defaultProps={};function X({onCreate:p}){const c=pe(),{t:m}=K(),[l,b]=D.useState(""),[n,u]=D.useState(""),[f,k]=D.useState(null),[y,C]=D.useState(null),v=()=>{k(null)},B=()=>{k({onCancel:()=>{v(),k(null)},onSuccess:()=>{v()}})},o=()=>{C({onCancel:()=>{C(null)},onSuccess:(...x)=>{C(null),p(...x)}})},i=()=>{const x=new URL("http://localhost");x.searchParams.set("restoreFrom","server"),x.searchParams.set("serverUrl",window.location.href),c(`/blocklets/restore${x.search}`)},r=()=>{c("/blocklets/restore")};return e.jsxs(e.Fragment,{children:[e.jsxs(E,{onClick:()=>c("/store"),menuButtonProps:{"data-cy":"open-install-menu"},menu:[e.jsx(E.Item,{"data-cy":"open-install-form",onClick:()=>B(),children:m("blocklet.installFromUrl")},"1"),e.jsx(E.Item,{"data-cy":"open-create-form",onClick:()=>o(),children:m("blocklet.installFromCreate")},"2"),e.jsx(E.Item,{"data-cy":"open-install-from-spaces",onClick:()=>r(),children:m("blocklet.restoreFromSpaces.title")},"3"),e.jsx(E.Item,{"data-cy":"open-install-from-spaces",onClick:()=>i(),children:m("blocklet.installFromDiskBackup")},"3")].filter(Boolean),children:[e.jsx(Ke,{}),m("blocklet.installFromMarket")]}),!!l&&e.jsx($,{variant:"error",message:l,onClose:()=>b("")}),!!n&&e.jsx($,{variant:"success",duration:3e3,message:n,onClose:()=>u("")}),f&&e.jsx(qe,{onCancel:f.onCancel,onSuccess:f.onSuccess}),y&&e.jsx(Q,{onCancel:y.onCancel,onSuccess:y.onSuccess})]})}X.propTypes={onCreate:S.func};X.defaultProps={onCreate:()=>{}};function q({blocklet:p,children:c}){const{urls:m}=ue(p),l=m[0];return c(l||"")}q.propTypes={blocklet:S.object.isRequired,children:S.func.isRequired};const I="internal",me="external";function Rt(){return e.jsx(We,{children:e.jsx(et,{})})}function et(){const p=pe(),c=de(),[m,l]=Te(),{data:b,externalData:n,error:u,refresh:f,loading:k}=Ee(),{deletingBlocklets:y,addDeletingDid:C,removeDeletingDid:v,matchDeletingDid:B}=ze(),{t:o,locale:i}=K(),[r,x]=D.useState(m.get("searchText")),[fe]=ne("show-external-blocklet-actions",!1),xe=[{id:I,name:o("blocklet.internal")},{id:me,name:o("blocklet.external")}],[A,he]=ne("blocklet-type-filter",I),H=A===I?b:n,be=(c==null?void 0:c.info.mode)!==Ie.NODE_MODES.SERVERLESS,J=a=>Ge(a,".well-known/service/admin/overview");B(H.map(a=>a.meta.did));const G=({action:a,blocklet:R})=>{a==="remove"&&C(R.meta.did)},Y=a=>{if(a.error){$.error(a.error.message),a.action==="remove"&&v(a.blocklet.meta.did);return}a.action==="remove"&&c.refresh({silent:!0})},Z=Le(a=>a.breakpoints.up("md"));let P=null;const U=H||[];if(u)P=e.jsx(se,{severity:"error",variant:"icon",children:e.jsxs("div",{children:[Pe(u),e.jsx(z,{onClick:()=>f({silent:!1}),children:e.jsx("span",{style:{color:"#44cdc6",textDecoration:"underline"},children:o("common.retry")})})]})});else if(U.length>0||k){const a=["installedAt","startedAt","stoppedAt","createdAt"],R=s=>{if(s.status==="starting")return new Date("2199").getTime();if(s.status==="running"){if(s.appRuntimeInfo)return s.appRuntimeInfo.startAt;if(s.startedAt)return s.startedAt.getTime()}return 0};let h=U.map(s=>(a.forEach(t=>{if(s[t]){const g=new Date(s[t]);s[t]=g}}),s)).sort((s,t)=>{const g=R(s);return R(t)-g});r&&(h=h.filter(s=>{var d;const t=W.getDisplayName(s)||"",g=((d=s.site)==null?void 0:d.domainAliases)||[],w=ae.isValid(r)?ae.toAddress(r):r,T=r.trim().toLocaleLowerCase();return s.appDid===w||s.appPid===w||t.toLocaleLowerCase().includes(T)||g.some(M=>{var te;return(te=M.value)==null?void 0:te.toLocaleLowerCase().includes(T)})}));const O=Ue("blocklets-list");O.searchText&&!r&&x(O.searchText);const ke=[{label:o("common.name"),name:"meta.title",options:{customBodyRenderLite(s){const t=h[s];return e.jsx(q,{blocklet:t,children:g=>e.jsx(oe,{to:J(g),target:"_blank",className:"blocklet-name-wrapper",children:e.jsxs(L,{component:"strong",variant:"body1",className:"blocklet-name",children:[e.jsx(ie,{blocklet:t,style:{marginRight:8}}),e.jsxs(j,{children:[e.jsx(j,{children:W.getDisplayName(t)}),e.jsxs(j,{children:[e.jsx(Ve,{mode:t.mode||""}),!Re(t.controller)&&e.jsx($e,{type:"primary",children:o("blocklet.external")})]})]})]})},t.meta.did)},t.meta.did)}}},A===I?{label:o("common.visit"),name:"runtimeInfo.pid",align:"left",options:{sort:!1,customBodyRenderLite(s){const t=h[s];return e.jsx(F,{blocklet:t},t.meta.did)}}}:null,{label:o("common.uptime"),name:"runtimeInfo.uptime",options:{customBodyRenderLite(s){const t=h[s];return t.status==="running"&&t.appRuntimeInfo?e.jsx(_,{value:t.appRuntimeInfo.startAt,locale:i},t.meta.did):""}}},{label:o("common.installedAt"),name:"installedAt",options:{customBodyRenderLite(s){const t=h[s];return t.installedAt?e.jsx(_,{value:t.installedAt.getTime(),locale:i},t.meta.did):t.createdAt?e.jsx(_,{value:t.createdAt.getTime(),locale:i},t.meta.did):""}}},{label:o("common.updatedAt"),name:"updatedAt",options:{customBodyRenderLite(s){const t=h[s];return e.jsx(_,{value:t.updatedAt,locale:i},t.meta.did)}}},{label:o("common.status"),name:"status",width:120,align:"center",options:{customBodyRenderLite(s){const t=h[s];return e.jsx(le,{"data-cy":"blocklet-status","status-blocklet-did":t.meta.did,status:y.includes(t.meta.did)?"deleting":t.status,source:t.source,progress:t.progress},t.meta.did)}}},A===I||fe?{label:o("common.actions"),name:"",width:90,options:{sort:!1,customBodyRenderLite(s){const t=h[s];return e.jsx(re,{blocklet:t,variant:"menu",onStart:G,onComplete:Y},t.meta.did)}}}:null].filter(Boolean),ee={};Z||(ee.TableBody=function(t){if(k)return e.jsx(Ne,{relative:"parent",children:e.jsx(V,{})});const{page:g,rowsPerPage:w}=t,T=h.slice(g*w,(g+1)*w);return T.length?e.jsx("div",{children:T.map(d=>e.jsx(q,{blocklet:d,children:M=>e.jsxs(j,{className:"blocklet-item--mobile",display:"flex",justifyContent:"space-between",alignItems:"center",children:[e.jsx(ie,{className:"blocklet__avatar",blocklet:d,size:Z?40:60}),e.jsxs(oe,{className:"blocklet__content",to:J(M),target:"_blank",children:[e.jsxs(j,{display:"flex",justifyContent:"space-between",alignItems:"flex-start",children:[e.jsx(L,{component:"strong",variant:"body1",className:"blocklet__name",children:W.getDisplayName(d,!0)}),e.jsx(re,{blocklet:d,variant:"menu",onStart:G,onComplete:Y},d.meta.did)]}),e.jsxs(L,{component:"small",className:"blocklet__addons",children:[e.jsx(j,{display:"flex",alignItems:"center",children:e.jsx(F,{blocklet:d,style:{marginLeft:16,fontSize:14}})}),e.jsx(le,{"status-blocklet-did":d.meta.did,status:d.status,source:d.source,progress:d.progress},d.meta.did)]})]})]})},d.meta.did))}):e.jsx(Me,{children:o("common.empty")})}),P=e.jsx(tt,{children:e.jsx(Oe,{loading:k,className:"blocklet-list",title:e.jsx(j,{display:"flex",alignItems:"center",children:o("blocklet.index.tableTitle")}),locale:i,data:h,columns:ke,durable:"blocklets-list",options:{download:!1,filter:!1,print:!1,searchPlaceholder:o("common.search"),searchAlwaysOpen:!1,sortOrder:{name:"uptime",direction:"desc"},searchDebounceTime:300,onSearchChange:s=>{x(s),l({searchText:s??""})},customSearch:()=>!0,...O,searchText:r},components:ee})})}else U.length===0&&(P=e.jsx(se,{severity:"warning",variant:"icon",children:o("blocklet.index.noBlocklet")}));const ge=n&&n.length>0;return e.jsxs(st,{children:[e.jsxs(L,{component:"h2",variant:"h4",className:"page-header",color:"textPrimary",children:[e.jsxs(j,{display:"flex",alignItems:"center",children:[o("common.blocklets"),(ge||A===me)&&e.jsx(He,{sx:{ml:1},children:e.jsx(Je,{value:A,onChange:a=>he(a.target.value),size:"small",children:xe.map(a=>e.jsx(_e,{value:a.id,children:o(a.name)},a.id))})})]}),e.jsx(Fe,{permission:"mutate_blocklets",children:be&&e.jsx(X,{onCreate:a=>{p(`/blocklets/${a.appDid}/components`)}})})]}),P]})}const tt=N.div`
|
|
16
|
-
.blocklet-item--mobile {
|
|
17
|
-
padding: 16px 0;
|
|
18
|
-
}
|
|
19
|
-
`,st=N.main`
|
|
20
|
-
.page-header {
|
|
21
|
-
display: flex;
|
|
22
|
-
justify-content: space-between;
|
|
23
|
-
align-items: center;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.blocklet-list {
|
|
27
|
-
.blocklet-item--mobile {
|
|
28
|
-
.blocklet__avatar {
|
|
29
|
-
margin-right: -60px;
|
|
30
|
-
}
|
|
31
|
-
.blocklet__content {
|
|
32
|
-
padding-left: 68px;
|
|
33
|
-
flex: 1;
|
|
34
|
-
display: flex;
|
|
35
|
-
flex-direction: column;
|
|
36
|
-
z-index: 1;
|
|
37
|
-
}
|
|
38
|
-
.blocklet__name {
|
|
39
|
-
font-weight: bold;
|
|
40
|
-
text-decoration: none;
|
|
41
|
-
white-space: normal;
|
|
42
|
-
word-break: break-all;
|
|
43
|
-
}
|
|
44
|
-
.blocklet__addons {
|
|
45
|
-
display: flex;
|
|
46
|
-
justify-content: space-between;
|
|
47
|
-
margin-top: 5px;
|
|
48
|
-
margin-bottom: -10px;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
.blocklet-name-wrapper {
|
|
52
|
-
display: flex;
|
|
53
|
-
flex-direction: row;
|
|
54
|
-
align-items: center;
|
|
55
|
-
justify-content: flex-start;
|
|
56
|
-
}
|
|
57
|
-
.blocklet-name {
|
|
58
|
-
font-weight: bold;
|
|
59
|
-
text-decoration: underline;
|
|
60
|
-
display: flex;
|
|
61
|
-
align-items: center;
|
|
62
|
-
white-space: normal;
|
|
63
|
-
word-break: break-all;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
.blocklet-interface {
|
|
67
|
-
display: flex;
|
|
68
|
-
align-items: center;
|
|
69
|
-
justify-content: flex-start;
|
|
70
|
-
|
|
71
|
-
img {
|
|
72
|
-
margin-right: 4px;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.MuiToolbar-root {
|
|
77
|
-
display: flex;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
`;export{et as BlockletList,Rt as default};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import{aj as X,A as N,r as p,a as Z,b as ee,P as x,t as j,u as P,z as te,au as $,N as _,j as t,y as q,av as se,q as S,m as v,D as M,aw as oe,V as O,ax as re,B as W,C as z,ay as ne,E as K,M as V,az as ae,aA as ie,aB as le,H as ce,aC as B,i as ue,n as H,a9 as de,a4 as pe,a6 as he,a7 as fe,aD as me,a8 as ge,Q as xe}from"./index-CRLxFVWY.js";import{_ as D}from"./useLocalStorage-DABDAbRI.js";import{c as be,C as ke,A as ye,D as Se,B as je,S as G,a as Pe,b as we}from"./item-Dln-w3Iq.js";import{d as Re}from"./ArrowDropDown-C_UcQOEh.js";import{B as ve}from"./Breadcrumbs-6lYKQe5b.js";import"./index-DxuvuH9i.js";import"./index-ZG7jWpak.js";import"./index-c1dR1RcA.js";import"./Search-B0peOjeQ.js";import"./index-BMfXnuvp.js";import"./Select-C--LsVoO.js";import"./InputAdornment-BRIOp0gH.js";import"./preact.module-DJUF--8d.js";import"./Add-240wNjwq.js";import"./TextField-D1TVUQl2.js";import"./InputLabel-C31crC9j.js";import"./Launch-CMM_hnCO.js";import"./Done-DcWcwr60.js";import"./DeleteOutline-o5TFeql0.js";import"./delete-confirm-BKnCoOpO.js";import"./click-to-copy-CK-Mkhd0.js";import"./shorten-label-CZVhjulh.js";import"./blocklet-DX4HGT6b.js";import"./MoreVert-s3M1upT5.js";import"./ButtonGroup-D2VNVq8p.js";import"./getValidReactChildren-Bwdvi5zb.js";function Ce(e){const n=X(),c=N(),[s,o]=D(`sid:blocklet:purchase:${e}`),[l,u]=p.useState(!1),[h,a]=p.useState(null),d=()=>{const{pathname:r,searchParams:m}=new URL(window.location.href),b=window.env&&window.env.apiPrefix?window.env.apiPrefix:"/";m.get("sid")&&(o(""),c(r.replace(b,"/"),{replace:!0}))},i=!!(n.get("assetDid")&&s&&n.get("sid")===s);return Z(ee.BlockletEvents.purchaseChange,r=>{r.did===e&&(a(r.session),["declined","confirmed","error"].includes(r.session.status)&&(u(!0),setTimeout(d,2e3)))}),p.useEffect(()=>{h&&h.id!==s&&o(h.id)},[h]),{hasCompleted:l,hasPurchased:i,session:h,setSession:a,doRedirect:d}}function E({meta:e,onCancel:n,handlePaySuccess:c,storeUrl:s}){const{t:o}=j(),{info:l}=P(),[u,h]=p.useState("both"),[a,d]=p.useState(1),i=te(l),r=$(e,l,s),m=R=>{R!==u&&h(R)},b=()=>{u&&(d(2),u==="verify"&&(window.location.href=r))},k=(R,L)=>{L!=="backdropClick"&&n()},w=()=>{c(r)},f=_.getDisplayName({meta:e});if(u==="purchase"&&a===2)return t.jsx(q,{open:!0,popup:!0,baseUrl:s,action:"acquire-asset",checkFn:se.create({baseURL:S(s,"/store")}).get,onSuccess:w,onClose:n,checkTimeout:60*5e3,extraParams:{factory:e.nftFactory},webWalletUrl:i,disableClose:!0,saveConnect:!1,showDownload:!1,messages:{title:o("store.purchase.auth.title",{name:f}),scan:o("store.purchase.auth.scan"),confirm:o("store.purchase.auth.confirm"),success:t.jsxs(t.Fragment,{children:[t.jsx(v,{gutterBottom:!0,children:o("store.purchase.auth.success")}),t.jsxs(v,{variant:"subtitle2",children:[" ",o("store.purchase.autoLaunch",{name:f})]})]})}});const g=M;return t.jsx(g,{title:o("store.purchase.title",{name:f}),disableEscapeKeyDown:!0,open:!0,fullWidth:!0,onClose:k,children:t.jsx("div",{style:{marginBottom:16},children:t.jsx(ke,{action:u,onNext:b,onSelect:m})})})}E.propTypes={...be,storeUrl:x.string.isRequired,handlePaySuccess:x.func};E.defaultProps={handlePaySuccess:e=>{setTimeout(()=>{window.location.href=e},1e3)}};function U({meta:e,buttonText:n,storeUrl:c,isResource:s}){const{t:o}=j(),l=N(),{info:u}=P(),{api:h}=oe(),a=_.isFreeBlocklet(e)===!1,[d,i]=p.useState(!1),{hasPurchased:r}=Ce(e.did),[m,b]=p.useState(!1),[k]=D("instant-blocklet-install",!1),[w,f]=p.useState(!1),g=p.useMemo(()=>d?o(a?"blocklet.status.purchasing":"blocklet.status.waiting"):"",[d,o,a]),R=p.useMemo(()=>s?o("blocklet.status.resource"):a?n.purchase:n.launch,[a,n,s]),L=y=>{y.preventDefault(),y.stopPropagation();try{if(i(!0),a){b(!0);return}if(k){f(!0);return}if(!a){const C=$(e,u,c);window.location.href=C}}catch(C){K.error(V(C),{autoHideDuration:5e3}),console.error("Blocklet installed failed",C)}finally{i(!1)}},Q=()=>{i(!1),b(!1)},Y=y=>{i(!1),f(!1),l(`/blocklets/${y.appDid}/components`)},J=()=>{i(!1),f(!1)};return t.jsxs(t.Fragment,{children:[t.jsx(ye,{children:t.jsx(O,{permission:"mutate_blocklets",children:y=>t.jsx(re,{title:s?o("launchBlocklet.error.resourceBlocklet"):"",children:t.jsx(W,{onClick:L,size:"small",sx:{cursor:s?"not-allowed":"pointer"},disabled:!!(g||!y),variant:"outlined",color:"primary","data-cy":"install-blocklet",children:g?t.jsxs(t.Fragment,{children:[t.jsx(z,{size:16,style:{marginRight:3}}),g]}):R},e.did)})})}),(r||m)&&t.jsx(E,{method:"launch",meta:e,mode:"both",onCancel:Q,storeUrl:c}),w&&t.jsx(q,{popup:!0,open:!0,forceConnected:!1,className:"launch-from-url-auth",action:"launch-free-blocklet-by-session",checkFn:h.get,checkTimeout:5*60*1e3,onSuccess:Y,extraParams:{title:e.title,blockletMetaUrl:decodeURIComponent(ne(c,e.did).trim())},messages:{title:o("setup.keyPair.title"),scan:o("setup.keyPair.scan"),confirm:o("setup.keyPair.confirm"),success:o("setup.keyPair.success")},onClose:J})]})}U.propTypes={isResource:x.bool,meta:x.object.isRequired,buttonText:x.shape({purchase:x.string.isRequired,launch:x.string.isRequired}).isRequired,storeUrl:x.string.isRequired};U.defaultProps={isResource:!1};const De=(e,n,c)=>{const s=de(n);return S(c,`/blocklets/${e.did}/?server-url=${s}`)},F=({meta:e,attribute:n,value:c})=>e._formatted?e._formatted[n]:c;function T({blocklet:e,endpoint:n}){const{t:c}=j(),s=P();let o=S(s.imgPrefix,"blocklet.png");const l=n;if(l.startsWith("http")&&e.logo)o=S(l,le(e.did,e.logo,e.version));else{let r=(window.env.apiPrefix||"/").replace(/^\/+/,"").replace(/\/+$/,"");r&&(r=`/${r}`),o=S(r,`/blocklet/logo/${e.did}`)}try{const i=new URL(o);i.searchParams.set("v",e.version||+new Date),o=i.href}catch{}const u=(s==null?void 0:s.info.mode)!==ce.NODE_MODES.SERVERLESS,h=i=>i.currentTarget.contains(i.target)?!0:(i.preventDefault(),!1),a={meta:e,buttonText:{purchase:c("common.purchase"),launch:c("common.launch")},storeUrl:l};let d=null;return u&&(d=t.jsx("div",{style:{display:"flex",alignItems:"center"},children:t.jsx(U,{isResource:!(B.hasStartEngine(e)||B.isGatewayBlocklet(e)||B.isPackBlocklet(e)),...a})})),t.jsx(ue,{href:De(e,s.info,n),style:{color:"initial",textDecoration:"none"},onClick:h,target:"_blank",children:t.jsx(Le,{title:F({meta:e,attribute:"title",value:e.title||e.name}),did:e.did,description:F({meta:e,attribute:"description",value:e.description}),cover:e.logo?o:"",version:e.version,button:d})})}T.propTypes={blocklet:x.object.isRequired,endpoint:x.string};T.defaultProps={endpoint:""};function I({storeUrl:e,handleSearchSelect:n,extraFilter:c,...s}){var r;const{locale:o}=j(),l=P(),[u,h]=p.useState({}),a=m=>{h(m)},d=e,i=(r=l==null?void 0:l.info)==null?void 0:r.version;return p.useEffect(()=>{h({})},[d]),t.jsx(ae,{FallbackComponent:ie,resetKeys:[d],children:t.jsx("div",{...s,children:t.jsx(Se,{blockletRender:m=>{const b={...m,endpoint:d};return t.jsx(T,{...b})},baseSearch:!0,endpoint:d,locale:o,onFilterChange:a,onSearchSelect:n,filters:u,extraFilter:c,serverVersion:i})})})}I.propTypes={storeUrl:x.string.isRequired,handleSearchSelect:x.func,extraFilter:x.func};I.defaultProps={handleSearchSelect:null,extraFilter:void 0};const Le=H(je)`
|
|
2
|
-
.ms-highlight {
|
|
3
|
-
color: ${e=>e.theme.palette.primary.main};
|
|
4
|
-
}
|
|
5
|
-
`,Be=pe(()=>({buttonText:{textTransform:"none !important"},iconRoot:{minWidth:24},menuName:{display:"flex",flexDirection:"column",marginRight:"100px","& span":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}}})),A=p.forwardRef(({onChange:e,onDelete:n},c)=>{const{info:s}=P(),{t:o}=j(),[l,u]=p.useState(!1),[h,a]=p.useState(!1),[d,i]=p.useState(-1),r=Be(),[m,b]=D(G),k=Math.max(s.blockletRegistryList.findIndex(f=>f.url===m),0),w=f=>{try{u(!0),i(f);const g=s.blockletRegistryList[f];b(g.url),e(g.url),a(!1)}catch(g){console.error(g),K.error(`${o("store.blockletRegistry.changeFailed")} ${V(g)}`)}finally{u(!1)}};return p.useImperativeHandle(c,()=>({setOpen:a})),t.jsxs(t.Fragment,{children:[t.jsx(W,{classes:{text:r.buttonText},color:"secondary","data-cy":"store-toggle",onClick:()=>{a(!0)},endIcon:t.jsx(Re,{}),children:t.jsx(v,{color:"secondary",children:s.blockletRegistryList[k].name})}),t.jsx(M,{title:o("store.blockletRegistry.switchRegistry"),disableEscapeKeyDown:!0,disablePortal:!1,fullWidth:!0,open:h,onClose:()=>a(!1),children:t.jsxs(he,{className:r.tabPanel,children:[s.blockletRegistryList.map((f,g)=>t.jsxs(fe,{button:!0,disabled:l,selected:k===g,"data-cy":"store-switch",onClick:()=>{if(!l){if(g===k){a(!1);return}w(g)}},children:[d===g&&l&&t.jsx(me,{className:r.iconRoot,children:t.jsx(z,{size:16})}),t.jsx(ge,{children:t.jsx(Pe,{teamDid:s.did,store:f,onDelete:()=>n(f.url)})})]},f.url)),t.jsx(O,{permission:"mutate_node",children:f=>t.jsx(we,{disabled:l||!f,onAdd:e,teamDid:s.did,blockletRegistryList:s.blockletRegistryList})})]})})]})});A.propTypes={onChange:x.func,onDelete:x.func};A.defaultProps={onChange:()=>{},onDelete:()=>{}};const Ee=A;function nt(){const{t:e}=j(),{info:n}=P(),[c]=D(G),{blockletRegistryList:s}=n,o=s.find(r=>c===r.url)||s[0],[l,u]=p.useState(o.url),h=n.routing.adminPath,a=S(window.location.origin,h),d=({detailUrl:r})=>{const m=new URL(r);m.searchParams.set("server-url",a);const b=document.createElement("a");b.setAttribute("target","_blank"),b.setAttribute("href",m.href),b.click()},i=p.useRef(null);return t.jsxs(Ue,{children:[t.jsxs(ve,{separator:"›","aria-label":"breadcrumb",className:"page-breadcrumb",children:[t.jsx(v,{color:"textPrimary",children:e("common.store")}),t.jsx(Ee,{ref:i,onChange:r=>u(r),onDelete:r=>{var m;l===r&&u((m=n.blockletRegistryList[0])==null?void 0:m.url)}})]}),t.jsx(xe,{className:"store-header",display:"flex",justifyContent:"space-between",p:0,m:0,children:t.jsx(v,{component:"h2",variant:"h4",className:"page-header",color:"textPrimary",children:e("store.headerDescription")})}),t.jsx(I,{className:"blocklet-list",handleSearchSelect:d,storeUrl:l})]})}const Ue=H.main`
|
|
6
|
-
@media (max-width: ${e=>e.theme.breakpoints.values.sm}px) {
|
|
7
|
-
.store-header {
|
|
8
|
-
flex-direction: column;
|
|
9
|
-
margin-bottom: 32px !important;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.page-header {
|
|
13
|
-
margin-bottom: 16px !important;
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
.blocklet-list {
|
|
17
|
-
aside:hover {
|
|
18
|
-
height: calc(100vh - 235px);
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
`;export{nt as default};
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import{a0 as J,r as x,bl as N,aP as ve,E as v,M as G,b as K,t as O,j as e,P as f,z as Ke,av as le,q as V,ak as Ve,m as y,Q as j,y as de,D as Ge,B as te,C as Z,x as Xe,K as We,n as ke,f as Ye,l as qe,aK as ne,aL as oe,U as _,aD as $,a8 as ee,a3 as _e,a2 as $e,a$ as et,J as tt,cg as st,W as nt,L as ot,$ as at,H as M,bc as q,i as it,T as ce,ax as rt,hm as ct,G as ye,X as lt,R as dt}from"./index-CRLxFVWY.js";import{S as Se}from"./index-ClZOvGLQ.js";import{u as P}from"./blocklet-DX4HGT6b.js";import"./api-DOcnwqon.js";import{u as Ie,P as pt}from"./use-blocklet-info-for-connect-did-spaces-DRjxN2RW.js";import{c as ut,h as ht,e as se,g as Ae,f as mt,i as Ce,j as ft,k as xt,l as Be,d as gt}from"./spaces-Swq2BNwF.js";import{T as jt}from"./TextField-D1TVUQl2.js";import{I as yt}from"./index-D8KWuR1-.js";import{S as De}from"./switch-control-CcMPAAj7.js";import{d as St}from"./MoreHoriz-q-g-RPDL.js";import{d as At}from"./DeleteOutline-o5TFeql0.js";import{e as Ct}from"./mode-B2dWMeTO.js";import{D as Bt}from"./index-CDRbsQoL.js";import"./ExpandMore-CK0-Eu1n.js";import"./ButtonGroup-D2VNVq8p.js";import"./getValidReactChildren-Bwdvi5zb.js";import"./index-BJXHdeeV.js";import"./Select-C--LsVoO.js";import"./InputLabel-C31crC9j.js";import"./index-BMfXnuvp.js";import"./FilterList-Bw1ZqePf.js";import"./useThemeProps-Cqic-E0U.js";import"./Delete-DmepPquU.js";import"./LastPage-15pWD2wJ.js";import"./index-BH1hVJpW.js";import"./redux-CaV6uiOr.js";import"./Search-B0peOjeQ.js";import"./index-c1dR1RcA.js";import"./MoreVert-s3M1upT5.js";async function vt({blockletDid:t,nodeApi:s,spaceGateways:a}){let n=!1;const l=await Promise.all(a.map(async c=>{let{name:o}=c;const r=await ut(c.endpoint);return!J.isEmpty(r)&&r!==o&&(o=r,n=!0),{...c,name:o}}));return n&&await Promise.all(l.filter(c=>c.did).map(c=>s.updateBlockletSpaceGateway({input:{did:t,where:{did:c.did},spaceGateway:{...c}}}))),l}function kt({setLoading:t,refresh:s}={}){var r;const{blocklet:a}=P(),n=(r=a==null?void 0:a.meta)==null?void 0:r.did,[l,c]=x.useState([]),{api:o}=N();return ve(async()=>{try{if(!n){c([]);return}t==null||t(!0);const{spaceGateways:d}=await o.getBlockletSpaceGateways({input:{did:n}}),p=await vt({blockletDid:n,nodeApi:o,spaceGateways:d});c(p??[])}catch(d){console.error(d),v.error(G(d))}finally{t==null||t(!1)}},[n,s]),{spaceGateways:l}}function Ee({deps:t,setLoading:s}={deps:[],setLoading:()=>{}}){var r;const{blocklet:a}=P(),[n,l]=x.useState([]),{api:c}=N(),o=J.debounce(async()=>{try{if(s(!0),!a){l([]);return}const{backups:d}=await c.getBlockletBackups({input:{did:a.meta.did}});l(d??[])}catch(d){console.error(d),v.error(G(d))}finally{s(!1)}},2e3);return ve(async()=>{o()},[(r=a==null?void 0:a.meta)==null?void 0:r.did].concat(t)),{backups:n}}function It({appDid:t}){const{backups:s}=Ee(),[a,n]=x.useState({message:"",progress:0,completed:!1}),l=N(),{ws:{useSubscription:c}}=l;return c(K.BlockletEvents.backupProgress,o=>{t===(o==null?void 0:o.appDid)&&n(()=>({...o}))},[t]),x.useEffect(()=>{var o;if(s!=null&&s.length&&J.isNull((o=s[0])==null?void 0:o.status)){const[r]=s;n(()=>({message:r.message,progress:r.progress,completed:r.progress>=100}))}},[s]),a}const Ue=x.createContext({}),{Provider:Dt,Consumer:ys}=Ue;function pe({children:t}){var C;const{t:s}=O(),{api:a}=N(),{blocklet:n}=P(),[l,c]=x.useState(!1),[o,r]=x.useState(!1),{spaceGateways:d}=kt({refresh:o,setLoading:c}),p=It({appDid:n==null?void 0:n.appDid}),[m,D]=x.useState(!1),S=x.useMemo(()=>ht(n==null?void 0:n.environments),[n,o,m]),[g,A]=x.useState(!1),{backups:k}=Ee({deps:[p],setLoading:A}),[H,I]=x.useState(d==null?void 0:d.find(i=>i.endpoint===S)),E=(C=n==null?void 0:n.settings)==null?void 0:C.autoBackup,u=()=>{r(i=>!i)},F=()=>{D(i=>!i)},U=async i=>{await a.updateAutoBackup({input:{did:n.meta.did,autoBackup:i}})},R=async(i,w)=>{d.push({...i,loading:!0}),await a.addBlockletSpaceGateway({input:{did:n.meta.did,spaceGateway:i}}),S!==w&&await a.configBlocklet({input:{did:[n.meta.did],configs:[{key:K.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_BACKUP_ENDPOINT,value:w}]}}),u(),I(i)},B=async i=>{i&&(i.endpoint===S&&(await a.configBlocklet({input:{did:[n.meta.did],configs:[{key:K.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_BACKUP_ENDPOINT,value:""}]}}),E!=null&&E.enabled&&await U({enabled:!1})),await a.deleteBlockletSpaceGateway({input:{did:n.meta.did,spaceGatewayDid:i==null?void 0:i.did}}),u(),I(i))},T=async i=>{await a.updateBlockletSpaceGateway({input:{did:n.meta.did,where:{did:i.did},spaceGateway:i}}),S!==i.endpoint&&await a.configBlocklet({input:{did:[n.meta.did],configs:[{key:K.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_BACKUP_ENDPOINT,value:i.endpoint}]}}),v.success(s("storage.spaces.connectedWithName",{name:(i==null?void 0:i.name)??"DID Spaces"})),u()},h=i=>(i==null?void 0:i.endpoint)===S;return e.jsx(Dt,{value:{spaceGateways:d,selectedSpaceGateway:H,addSpaceGateway:R,deleteSpaceGateway:B,updateSpaceGateway:T,refreshSpaceGateways:u,spaceGatewaysLoading:l,spaceGatewayIsSelected:h,updateAutoBackup:U,backupEndpoint:S,backupProgress:p,backups:k,backupsLoading:g,refreshBackupEndpoint:F,autoBackup:E},children:t})}pe.propTypes={children:f.any.isRequired};pe.defaultProps={};function Q(){return x.useContext(Ue)}function ae({...t}){const{blocklet:s}=P(),{info:a}=N(),{t:n,locale:l}=O(),[c,o]=x.useState(""),[r,d]=x.useState(!1),[p,m]=x.useState(!1),[D,S]=x.useState(""),g=Ie({blocklet:s}),A=Ke(a),{spaceGateways:k,addSpaceGateway:H}=Q(),[I,E]=x.useState({open:!1,action:"connect-to-did-spaces",checkTimeout:1e3*300,checkFn:le.create({baseURL:V(window.location.origin,Ve())}).get,messages:{title:n("storage.spaces.provideNFT.title",{appName:g.appName},l),scan:n("storage.spaces.provideNFT.scan",{appName:g.appName},l),confirm:"",success:e.jsx(y,{gutterBottom:!0,children:n("storage.spaces.provideNFT.success")})},onClose:()=>{E(h=>({...h,open:!1}))}}),[u,F]=x.useState({open:!1,action:"one-click-authorization",checkTimeout:1e3*300,messages:{title:n("storage.spaces.authorize.title",{appName:g.appName},l),scan:n("storage.spaces.authorize.scan",{appName:g.appName},l),confirm:"",success:e.jsx(y,{gutterBottom:!0,children:n("storage.spaces.authorize.success")})},onClose:()=>{F(h=>({...h,open:!1}))}}),U=async({endpoint:h,name:C,did:i})=>{const w=await Ae(h);if(!await Ce(w)){v.error(n("storage.spaces.gateway.add.invalidUrl"));return}if(k.some(W=>W.endpoint===h)){v.error(n("storage.spaces.gateway.add.duplicate",{name:C}));return}const L={name:C,did:i,url:w,endpoint:h};await H(L,h),v.success(n("storage.spaces.connectedWithName",{name:(L==null?void 0:L.name)??"DID Spaces"}))},R=async(h,C)=>{try{if(!J.isEmpty(h.spaceGateway))await U(C(h.spaceGateway));else{const i=C(h.endpoint),w=h.space?C(h.space):{};await U({endpoint:i,did:se(i),name:"DID Space",...w})}F(i=>({...i,open:!1})),o(null),E(i=>({...i,open:!1}))}catch(i){console.error(i),v.error(G(i))}},B=()=>{E(h=>({...h,open:!0,extraParams:{appPid:s.appPid,appName:g.appName,appDescription:g.appDescription,scopes:g.scopes,appUrl:g.appUrl,referrer:g.referrer,nodeDid:a.did}}))},T=async()=>{try{d(!0);const h=await Ae(c),C=mt(h),i=new URL(h).searchParams.get("spaceDid");if(!await Ce(C))throw new Error(n("storage.spaces.gateway.add.invalidUrl"));F(w=>({...w,open:!0,prefix:V(C,"space/api/did"),baseUrl:new URL(C).origin,checkFn:le.create({baseURL:V(C,"space")}).get,extraParams:{appDid:g.appDid,appName:g.appName,appDescription:g.appDescription,scopes:g.scopes,appUrl:g.appUrl,referrer:g.referrer,nodeDid:a.did,spaceDid:i}})),m(!1)}catch(h){const C=`${n("storage.spaces.gateway.add.failed",l)}: ${G(h)}`;S(C)}finally{d(!1)}};return e.jsxs(j,{children:[e.jsx(Se,{color:"primary",style:{textTransform:"none !important",fontSize:"1rem"},size:"small",onClick:B,menu:[e.jsx(Se.Item,{sx:{textTransform:"none"},onClick:()=>m(!0),size:"small",...t,children:n("storage.spaces.connect.useSpaceGateway")},"1")],children:e.jsx(y,{sx:{fontWeight:"bold",textTransform:"none"},children:n("storage.spaces.connect.useWallet")})}),e.jsx(de,{forceConnected:!1,saveConnect:!1,prefix:I.prefix,open:I.open,popup:!0,action:I.action,webWalletUrl:A,baseUrl:I.baseUrl,checkFn:I.checkFn,onSuccess:R,onClose:I.onClose,checkTimeout:I.checkTimeout,extraParams:I.extraParams,messages:I.messages,locale:l}),e.jsx(de,{forceConnected:!1,saveConnect:!1,prefix:u.prefix,open:u.open,popup:!0,action:u.action,baseUrl:u.baseUrl,checkFn:u.checkFn,onSuccess:R,onClose:u.onClose,checkTimeout:u.checkTimeout,extraParams:u.extraParams,messages:u.messages,locale:l}),e.jsxs(Ge,{title:n("storage.spaces.gateway.add.title"),fullWidth:!0,maxWidth:"md",open:p,onClose:()=>m(!1),PaperProps:{style:{minHeight:"auto"}},actions:e.jsxs(e.Fragment,{children:[e.jsx(te,{onClick:h=>{h.stopPropagation(),m(!1)},color:"inherit",children:n("common.cancel")}),e.jsxs(te,{onClick:T,color:"primary",disabled:r||!c,variant:"contained",autoFocus:!0,children:[r&&e.jsx(Z,{size:16}),n("common.confirm")]})]}),children:[e.jsx("div",{style:{paddingTop:12,overflowY:"hidden"},children:e.jsx(Xe,{component:"div",children:e.jsx(y,{component:"div",children:e.jsx(jt,{label:n("storage.spaces.gateway.add.label"),autoComplete:"off",variant:"outlined",name:"url",fullWidth:!0,value:c,onChange:h=>{S(null),o(h.target.value)},disabled:r,onKeyPress:async h=>{h.key==="Enter"&&await T()},autoFocus:!0})})})}),!!D&&e.jsx(We,{severity:"error",style:{width:"100%"},children:D})]})]})}ae.propTypes={};ae.defaultProps={};function we({...t}){const{t:s}=x.useContext(Ye),{blocklet:a,loadingDiskInfo:n,actions:l}=P();if(x.useEffect(()=>{l.refreshBlocklet({showError:!1,attachDiskInfo:!0})},[]),a.diskInfo){const c=(d,p,m)=>e.jsxs(y,{children:[d," ",e.jsx("strong",{children:p?qe(p):"empty"})]}),o=a.environments.reduce((d,p)=>(d[p.key]=p.value,d),{}),r=[{key:"appDir",name:s("blocklet.diskInfo.appDir"),value:c(o.BLOCKLET_APP_DIR,a.diskInfo.app)},{key:"dataDir",name:s("blocklet.diskInfo.dataDir"),value:c(o.BLOCKLET_DATA_DIR,a.diskInfo.data)},{key:"logDir",name:s("blocklet.diskInfo.logDir"),value:c(o.BLOCKLET_LOG_DIR,a.diskInfo.log)},{key:"cacheDir",name:s("blocklet.diskInfo.cacheDir"),value:c(o.BLOCKLET_CACHE_DIR,a.diskInfo.cache)}];return e.jsx(Et,{component:"div",...t,children:r.map(d=>e.jsx(yt,{valueComponent:"div",nameWidth:120,name:d.name,children:d.value},d.key))})}return n?e.jsx(Z,{}):e.jsx(y,{children:s("blocklet.diskInfo.empty")})}const Et=ke(y)``;var be=function(s){return e.jsxs("svg",{...s,children:[e.jsxs("g",{filter:"url(#a)",children:[e.jsx("path",{d:"M56.97 2a12 12 0 0 0-8.485 3.515l-40.97 40.97A12 12 0 0 0 4 54.971V240c0 6.627 5.373 12 12 12h196c6.627 0 12-5.373 12-12V14c0-6.627-5.373-12-12-12H56.97Z",fill:"#DDD"}),e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"m49.192 6.222-40.97 40.97A11 11 0 0 0 5 54.971V240c0 6.075 4.925 11 11 11h196c6.075 0 11-4.925 11-11V14c0-6.075-4.925-11-11-11H56.97a11 11 0 0 0-7.778 3.222Zm-.707-.707A12 12 0 0 1 56.971 2H212c6.627 0 12 5.373 12 12v226c0 6.627-5.373 12-12 12H16c-6.627 0-12-5.373-12-12V54.97a12 12 0 0 1 3.515-8.485l40.97-40.97Z",fill:"#000",fillOpacity:".08"}),e.jsx("mask",{id:"b",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:"4",y:"2",width:"220",height:"250",children:e.jsx("path",{d:"M56.97 2a12 12 0 0 0-8.485 3.515l-40.97 40.97A12 12 0 0 0 4 54.971V240c0 6.627 5.373 12 12 12h196c6.627 0 12-5.373 12-12V14c0-6.627-5.373-12-12-12H56.97Z",fill:"#D9D9D9"})}),e.jsxs("g",{mask:"url(#b)",children:[e.jsx("path",{opacity:".5",fill:"url(#c)",d:"M4 2h220v128H4z"}),e.jsx("path",{opacity:".1",fill:"url(#d)",d:"M4 130h220v122H4z"}),e.jsx("path",{d:"M33.045 169h-3.767v-11.636h3.887c1.14 0 2.12.233 2.937.698a4.61 4.61 0 0 1 1.881 1.995c.44.863.659 1.899.659 3.108 0 1.212-.222 2.254-.665 3.125a4.668 4.668 0 0 1-1.909 2.011c-.833.466-1.84.699-3.023.699Zm-2.01-1.534h1.914c.886 0 1.623-.167 2.21-.5a3.152 3.152 0 0 0 1.318-1.46c.292-.64.438-1.421.438-2.341 0-.913-.146-1.688-.438-2.324a3.095 3.095 0 0 0-1.29-1.449c-.572-.33-1.282-.494-2.13-.494h-2.023v8.568Zm11.546-10.102V169h-1.756v-11.636h1.756ZM48.905 169h-3.767v-11.636h3.886c1.14 0 2.12.233 2.938.698a4.609 4.609 0 0 1 1.88 1.995c.44.863.66 1.899.66 3.108 0 1.212-.222 2.254-.665 3.125a4.667 4.667 0 0 1-1.91 2.011c-.833.466-1.84.699-3.022.699Zm-2.011-1.534h1.914c.887 0 1.623-.167 2.21-.5a3.151 3.151 0 0 0 1.319-1.46c.291-.64.437-1.421.437-2.341 0-.913-.146-1.688-.437-2.324a3.095 3.095 0 0 0-1.29-1.449c-.572-.33-1.282-.494-2.13-.494h-2.023v8.568Zm20.372-7.046a1.662 1.662 0 0 0-.75-1.25c-.44-.299-.993-.448-1.66-.448-.477 0-.89.075-1.238.227a1.91 1.91 0 0 0-.813.613c-.189.258-.284.552-.284.881 0 .277.065.515.194.716.132.201.304.369.516.506.216.132.447.244.694.335.246.087.483.159.71.216l1.136.295c.371.091.752.214 1.142.37.39.155.752.36 1.086.613.333.254.602.568.806.944.209.374.313.823.313 1.346 0 .659-.17 1.244-.511 1.756-.338.511-.828.915-1.472 1.21-.64.295-1.415.443-2.324.443-.871 0-1.625-.138-2.261-.415-.637-.276-1.135-.668-1.495-1.176-.36-.511-.558-1.117-.596-1.818h1.761c.034.421.17.771.41 1.051.242.277.55.483.925.62.38.132.794.198 1.245.198.496 0 .937-.077 1.324-.233.39-.159.697-.378.92-.659a1.56 1.56 0 0 0 .335-.994c0-.345-.098-.627-.295-.847a2.191 2.191 0 0 0-.79-.545 7.725 7.725 0 0 0-1.12-.381l-1.374-.375c-.932-.253-1.67-.627-2.216-1.119-.542-.492-.813-1.144-.813-1.955 0-.67.182-1.255.546-1.755.363-.5.856-.888 1.477-1.165.621-.28 1.322-.42 2.102-.42.788 0 1.483.138 2.085.414.607.277 1.084.658 1.432 1.142.349.481.53 1.034.546 1.659h-1.693Zm3.813 11.853v-12h1.66v1.415h.142c.098-.182.24-.393.426-.631.185-.239.443-.447.772-.625.33-.182.766-.273 1.307-.273.705 0 1.334.178 1.887.534.553.356.987.869 1.3 1.54.319.67.478 1.477.478 2.42 0 .944-.157 1.752-.472 2.427-.314.67-.746 1.187-1.295 1.551-.55.36-1.176.539-1.88.539-.53 0-.965-.089-1.302-.267a2.457 2.457 0 0 1-.784-.625 4.667 4.667 0 0 1-.437-.636h-.103v4.631H71.08Zm1.665-7.637c0 .614.09 1.152.267 1.614.178.462.436.824.773 1.085.337.258.75.387 1.239.387.507 0 .931-.135 1.273-.404.34-.273.598-.642.772-1.108.178-.466.267-.99.267-1.574 0-.575-.087-1.092-.261-1.551-.17-.458-.428-.82-.773-1.085-.34-.265-.767-.398-1.278-.398-.493 0-.91.127-1.25.381-.337.254-.593.608-.767 1.062-.175.455-.262.985-.262 1.591Zm10.75 4.557a3.557 3.557 0 0 1-1.5-.307 2.523 2.523 0 0 1-1.062-.903c-.258-.394-.386-.877-.386-1.449 0-.492.094-.898.283-1.216.19-.318.446-.57.768-.756a4.036 4.036 0 0 1 1.08-.42c.397-.095.802-.167 1.215-.216l1.273-.148c.325-.041.562-.108.71-.198.148-.091.222-.239.222-.444v-.039c0-.497-.14-.881-.42-1.154-.277-.273-.69-.409-1.24-.409-.572 0-1.022.127-1.352.381-.325.25-.55.528-.676.835l-1.597-.364c.19-.53.466-.958.83-1.284.368-.329.79-.568 1.267-.716.477-.151.98-.227 1.506-.227.348 0 .718.042 1.108.125.394.08.761.227 1.102.443.345.216.627.525.847.926.22.398.33.915.33 1.552V169h-1.66v-1.193h-.068c-.11.22-.275.435-.495.648-.22.212-.501.388-.846.528s-.758.21-1.239.21Zm.37-1.363c.47 0 .87-.093 1.204-.279.337-.185.593-.428.767-.727.178-.303.267-.627.267-.972v-1.125c-.06.061-.178.118-.352.171-.17.049-.365.093-.585.13-.22.034-.434.067-.642.097l-.523.068c-.33.042-.63.112-.903.21a1.553 1.553 0 0 0-.648.427c-.16.181-.239.424-.239.727 0 .42.156.738.466.954.31.212.707.319 1.188.319Zm9.876 1.346c-.845 0-1.572-.191-2.182-.574a3.796 3.796 0 0 1-1.398-1.596c-.325-.678-.488-1.455-.488-2.33 0-.886.166-1.668.5-2.346a3.832 3.832 0 0 1 1.409-1.597c.606-.383 1.32-.574 2.142-.574.663 0 1.254.123 1.773.369.519.243.937.584 1.255 1.023.322.44.514.953.574 1.54h-1.653c-.091-.409-.3-.761-.625-1.057-.322-.295-.754-.443-1.296-.443a2.11 2.11 0 0 0-1.244.375c-.352.246-.627.598-.824 1.057-.197.454-.295.992-.295 1.613 0 .637.096 1.186.29 1.648.193.462.466.82.818 1.074.356.254.774.381 1.255.381.322 0 .614-.059.875-.177.266-.121.487-.293.665-.517.182-.223.309-.492.38-.806h1.654a3.211 3.211 0 0 1-.55 1.511 3.165 3.165 0 0 1-1.234 1.045c-.511.254-1.111.381-1.8.381Zm9.163 0c-.859 0-1.6-.184-2.221-.551a3.732 3.732 0 0 1-1.432-1.563c-.333-.674-.5-1.464-.5-2.369 0-.894.167-1.682.5-2.363a3.887 3.887 0 0 1 1.409-1.597c.606-.383 1.314-.574 2.125-.574.493 0 .97.082 1.432.244.462.163.877.419 1.244.767.368.349.657.802.87 1.358.212.553.318 1.226.318 2.017v.603H99.71v-1.273h5.273c0-.447-.091-.843-.273-1.187a2.052 2.052 0 0 0-.767-.824c-.326-.201-.708-.302-1.148-.302a2.22 2.22 0 0 0-1.25.353 2.364 2.364 0 0 0-.818.909 2.626 2.626 0 0 0-.284 1.21v.994c0 .584.102 1.08.307 1.489.208.409.498.722.869.938.372.212.805.318 1.301.318a2.7 2.7 0 0 0 .881-.137c.265-.094.494-.234.688-.42.193-.186.341-.415.443-.688l1.608.29c-.129.474-.36.888-.693 1.244-.33.353-.745.627-1.245.824-.496.194-1.062.29-1.699.29Z",fill:"#fff"}),e.jsx("path",{d:"M117.604 47.263 121.523 45h14.267v41.862h-14.267l-15.335-8.854V53.854l1.818-1.05 3.2 1.848-1.818 1.05V76.16l12.993 7.502h10.209V48.2h-10.209l-1.577.91-3.2-1.847Z",fill:"url(#e)"}),e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M119.402 76.16V55.701L106.409 48.2H96.2v35.462h10.209l1.582-.913 3.2 1.847-3.924 2.266H93V45h14.267l15.335 8.854v24.154l-1.813 1.046-3.2-1.847 1.813-1.047Z",fill:"url(#f)"}),e.jsxs("g",{clipPath:"url(#g)",fillRule:"evenodd",clipRule:"evenodd",fill:"#fff",children:[e.jsx("path",{d:"m50.928 216.089 1.034 2.852h-2.503l1.028-2.842a4.95 4.95 0 0 0 .107-.338 7.17 7.17 0 0 0 .111-.409c.075.297.15.542.223.737Zm2.28 5.591h.796l-2.775-7.352h-1.043l-2.774 7.352h.795a.338.338 0 0 0 .223-.077.425.425 0 0 0 .127-.179l.615-1.705h3.07l.617 1.705a.399.399 0 0 0 .126.184.339.339 0 0 0 .223.072Zm4.823-.963a2.023 2.023 0 0 1-.67.098h-1.455v-2.453h1.456c.5 0 .871.106 1.11.318.24.208.36.495.36.86 0 .184-.028.355-.083.512a1.005 1.005 0 0 1-.262.399 1.2 1.2 0 0 1-.456.266Zm-2.125-3.128v-2.406h1.237c.498 0 .865.095 1.101.286.236.192.355.497.355.917 0 .369-.125.662-.374.881-.246.215-.623.322-1.13.322h-1.189Zm2.358-3.128a4.106 4.106 0 0 0-1.12-.133h-2.27v7.352h2.507c.391 0 .74-.051 1.048-.154.307-.102.566-.247.776-.435.21-.188.37-.409.48-.665.11-.26.165-.547.165-.861 0-.904-.506-1.462-1.518-1.674.22-.075.41-.169.572-.281a1.79 1.79 0 0 0 .403-.379c.106-.144.186-.297.237-.461.052-.164.078-.335.078-.512a2.1 2.1 0 0 0-.146-.804 1.49 1.49 0 0 0-.441-.609 2.073 2.073 0 0 0-.771-.384Zm7.535.778h-2.212v6.441h-1.028v-6.441h-2.222v-.911H65.8v.911Zm2.439.564h-1.13v1.193h1.13v-1.193Zm-1.13 2.983h1.13v1.193h-1.13v-1.193Z",fillOpacity:".8"}),e.jsx("path",{d:"M28.247 221.771V214h3.894c.99.072 1.765.944 1.765 1.998v3.77c0 1.106-.85 2.003-1.897 2.003h-3.762ZM36.355 214h-1.011v7.783h1.01V214Zm-7.097 6.704v-5.642h2.751c.49 0 .886.419.886.936v3.77c0 .517-.396.936-.886.936h-2.75ZM37.775 214v7.771h3.762c1.047 0 1.897-.897 1.897-2.003v-3.77c0-1.054-.774-1.926-1.765-1.998h-3.894Zm6.946 1.803h1.13v1.193h-1.13v-1.193Zm1.13 2.983h-1.13v1.193h1.13v-1.193Zm-7.065-3.724v5.642h2.75c.49 0 .887-.419.887-.936v-3.77c0-.517-.397-.936-.886-.936h-2.751Z"})]}),e.jsx("circle",{cx:"191.32",cy:"218",r:"10",fill:"url(#h)"}),e.jsx("path",{d:"m192.064 213.333.976-.564h3.554v10.427h-3.286a1 1 0 0 1-.5-.134l-3.588-2.071v-6.016l.453-.262.797.46-.453.262v5.096l3.237 1.868h2.543v-8.833h-2.543l-.393.227-.797-.46Z",fill:"#fff"}),e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M192.512 220.531v-5.096l-3.237-1.869h-2.543v8.833h2.543l.394-.227.797.46-.977.564h-3.554v-10.427h3.554l3.82 2.206v6.016l-.452.261-.797-.461.452-.26Z",fill:"#fff"})]})]}),e.jsxs("defs",{children:[e.jsxs("linearGradient",{id:"d",x1:"114",y1:"130",x2:"114",y2:"252",gradientUnits:"userSpaceOnUse",children:[e.jsx("stop",{stopColor:"#101010"}),e.jsx("stop",{offset:"1",stopColor:"#272727"})]}),e.jsxs("linearGradient",{id:"e",x1:"120.989",y1:"45",x2:"120.989",y2:"86.862",gradientUnits:"userSpaceOnUse",children:[e.jsx("stop",{stopColor:"#fff",stopOpacity:".4"}),e.jsx("stop",{offset:"1",stopColor:"#fff"})]}),e.jsxs("linearGradient",{id:"f",x1:"107.801",y1:"45",x2:"107.801",y2:"86.862",gradientUnits:"userSpaceOnUse",children:[e.jsx("stop",{stopColor:"#fff"}),e.jsx("stop",{offset:"1",stopColor:"#fff",stopOpacity:".4"})]}),e.jsxs("radialGradient",{id:"h",cx:"0",cy:"0",r:"1",gradientUnits:"userSpaceOnUse",gradientTransform:"matrix(17 -8.76924 6.97565 13.52294 183.166 221)",children:[e.jsx("stop",{stopColor:"#016BED"}),e.jsx("stop",{offset:".699",stopColor:"#4498FB"}),e.jsx("stop",{offset:"1",stopColor:"#9DFFE8"})]}),e.jsx("clipPath",{id:"g",children:e.jsx("path",{fill:"#fff",transform:"translate(28 214)",d:"M0 0h40.32v8H0z"})}),e.jsx("pattern",{id:"c",patternContentUnits:"objectBoundingBox",width:"1",height:"1",children:e.jsx("use",{xlinkHref:"#i",transform:"scale(.00455 .00781)"})}),e.jsxs("filter",{id:"a",x:"0",y:"0",width:"228",height:"258",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[e.jsx("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),e.jsx("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),e.jsx("feOffset",{dy:"2"}),e.jsx("feGaussianBlur",{stdDeviation:"2"}),e.jsx("feComposite",{in2:"hardAlpha",operator:"out"}),e.jsx("feColorMatrix",{values:"0 0 0 0 0.0631944 0 0 0 0 0.242785 0 0 0 0 0.403472 0 0 0 0.2 0"}),e.jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_1410_22507"}),e.jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_1410_22507",result:"shape"})]}),e.jsx("image",{id:"i",width:"220",height:"128",xlinkHref:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANwAAACABAMAAACSOBo+AAAAG1BMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACUUeIgAAAACXRSTlMSFhk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hN9JkkJkd5BjQFPoUcwjJdTm0mx0024NmOvVgxASvU9TonFxUqG8cUTy3m5s3i7BqLbFkKcfxLQYhAXfjam0yFFd3PZE9wlXWfHYKlg2cFlTcnwRH6z8DpSfQHidMhElmCMb07li9ceHQHFknk/98f4KJRLpX6xQEXVAnJxlr8Aw6/qb0wu9SNolstScB0izxmMC5DiytBJd9Rcm3RGf42aiddmUTM4d4dgdjiT+vMPX0/RzfZdLoZ4aQqPzhx9plNI3QyvsMZHn2j2wOECoTtkfJt89O+eYUnXB/gFxHxPmOeL9ogAAAABJRU5ErkJggg=="})]})]})};be.defaultProps={width:"228",height:"258",fill:"none",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"};function Re(){const{t}=O();return e.jsxs(j,{children:[e.jsxs(j,{minHeight:"40vh",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",alignContent:"center",children:[e.jsx(be,{style:{width:250,height:250}}),e.jsx(y,{marginTop:"24px",marginBottom:"24px",children:t("storage.spaces.connect.provider")}),e.jsx(ae,{})]}),e.jsx(y,{fontSize:"1.2rem",fontWeight:"bold",mb:2,children:t("common.dataStorage")}),e.jsx(we,{})]})}Re.propTypes={};var ue={},Ut=oe;Object.defineProperty(ue,"__esModule",{value:!0});var Te=ue.default=void 0,wt=Ut(ne()),bt=e;Te=ue.default=(0,wt.default)((0,bt.jsx)("path",{d:"M6 6v2h8.59L5 17.59 6.41 19 16 9.41V18h2V6z"}),"ArrowOutward");var he={},Rt=oe;Object.defineProperty(he,"__esModule",{value:!0});var Oe=he.default=void 0,Tt=Rt(ne()),Ot=e;Oe=he.default=(0,Tt.default)((0,Ot.jsx)("path",{d:"M14.69 2.21 4.33 11.49c-.64.58-.28 1.65.58 1.73L13 14l-4.85 6.76c-.22.31-.19.74.08 1.01.3.3.77.31 1.08.02l10.36-9.28c.64-.58.28-1.65-.58-1.73L11 10l4.85-6.76c.22-.31.19-.74-.08-1.01-.3-.3-.77-.31-1.08-.02"}),"ElectricBoltOutlined");var me={},Ft=oe;Object.defineProperty(me,"__esModule",{value:!0});var Fe=me.default=void 0,Lt=Ft(ne()),Mt=e;Fe=me.default=(0,Lt.default)((0,Mt.jsx)("path",{d:"m9.17 6 2 2H20v10H4V6zM10 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2h-8z"}),"FolderOutlined");function fe({spaceGateway:t,onDelete:s}){const{t:a}=O(),[n,l]=x.useState(!1),[c,o]=x.useState(!1),r=(p,m)=>{p==null||p.preventDefault(),p==null||p.stopPropagation(),l(m)},d=async p=>{try{p==null||p.stopPropagation(),o(!0),await s(t),l(!1)}catch(m){console.error(m),v.error(`${a("storage.space.gateway.delete.failed")}: ${G(m)}`)}finally{o(!1)}};return e.jsxs(e.Fragment,{children:[e.jsxs(_,{color:"red",onClick:p=>r(p,!0),children:[e.jsx($,{style:{minWidth:24,color:"red"},children:e.jsx(At,{fontSize:"small"})}),e.jsx(ee,{style:{color:"red"},children:a("common.delete")})]}),e.jsx(_e,{title:e.jsx(y,{variant:"h6",children:a("common.delConfirmDescription",{data:`${t==null?void 0:t.name}`})}),open:n,confirmButton:{text:a("common.confirm"),props:{variant:"contained",color:"error",loading:c}},cancelButton:{text:a("common.cancel"),props:{variant:"contained",color:"primary"},loading:c},onConfirm:d,onCancel:p=>r(p,!1)})]})}fe.propTypes={onDelete:f.func,spaceGateway:f.shape({name:f.string.isRequired,url:f.string.isRequired,protected:f.bool}).isRequired};fe.defaultProps={onDelete:()=>{}};function xe({spaceGateway:t,connected:s,onDelete:a,onConnect:n,enableSwitchToSpace:l,backupInProgress:c,...o}){const[r,d]=x.useState(null),{t:p}=O(),[m,D]=x.useState(!1),S=(A,k)=>{A.stopPropagation(),A.preventDefault(),d(k&&A.currentTarget)},g=async A=>{try{D(!0),S(A,!1),await n(t)}catch(k){console.error(k),v.error(k.message)}finally{D(!1)}};return e.jsxs(e.Fragment,{children:[e.jsx($e,{"aria-label":"more","aria-controls":"actions-menu","aria-haspopup":"true","data-cy":"trigger-blocklet-actions",onClick:A=>S(A,!0),size:"small",...o,children:m||t!=null&&t.loading?e.jsx(Z,{size:"24px"}):e.jsx(St,{})}),e.jsxs(et,{id:"simple-menu",anchorEl:r,keepMounted:!0,open:!!r,onClose:A=>S(A,!1),children:[e.jsxs(_,{onClick:A=>{S(A,!1),window.open(t.endpoint?ft(t.endpoint):t.url)},children:[e.jsx($,{style:{minWidth:24},children:e.jsx(Te,{fontSize:"small"})}),e.jsx(ee,{children:p("common.open")})]}),e.jsxs(_,{onClick:A=>{S(A,!1),window.open(xt(t.endpoint))},children:[e.jsx($,{style:{minWidth:24},children:e.jsx(Fe,{fontSize:"small"})}),e.jsx(ee,{children:p("storage.spaces.strategy.viewBackupFiles")})]}),!s&&l&&e.jsxs(_,{onClick:g,children:[e.jsx($,{style:{minWidth:24},children:e.jsx(Oe,{fontSize:"small"})}),e.jsx(ee,{children:p("storage.spaces.connect.switchToSpace")})]}),!c&&e.jsx(fe,{spaceGateway:t,onDelete:a})]})]})}xe.propTypes={spaceGateway:f.shape({name:f.string.isRequired,url:f.string.isRequired,protected:f.bool,endpoint:f.string.isRequired,loading:f.bool}).isRequired,connected:f.bool.isRequired,enableSwitchToSpace:f.bool,onDelete:f.func,onConnect:f.func,backupInProgress:f.bool};xe.defaultProps={onDelete:()=>{},onConnect:()=>{},enableSwitchToSpace:!0,backupInProgress:!1};var Le=function(s){return e.jsx("svg",{...s,children:e.jsx("circle",{cx:"4",cy:"4",r:"4",fill:"#25C99B"})})};Le.defaultProps={width:"8",height:"8",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var Me=function(s){return e.jsx("svg",{...s,children:e.jsx("circle",{cx:"4",cy:"4",r:"4",fill:"#F16E6E"})})};Me.defaultProps={width:"8",height:"8",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function ge({spaceGateway:t,connected:s,onDelete:a,onBackupNow:n,...l}){const c=tt(b=>b.breakpoints.down("md")),{t:o,locale:r}=O(),{blocklet:d}=P(),{api:p,info:{did:m}}=N(),{appDid:D,appName:S,appDescription:g,scopes:A,appUrl:k,referrer:H}=Ie({blocklet:d}),{updateSpaceGateway:I,backupEndpoint:E,backupProgress:u,refreshBackupEndpoint:F}=Q(),[U,R]=x.useState(!1),[B,T]=x.useState({open:!1,action:"one-click-authorization",checkTimeout:1e3*300,messages:{title:o("storage.spaces.authorize.title",{appName:S},r),scan:o("storage.spaces.authorize.scan",{appName:S},r),confirm:"",success:e.jsx(y,{gutterBottom:!0,children:o("storage.spaces.authorize.success")})},onClose:()=>{T(b=>({...b,open:!1}))}}),{data:h,loading:C}=st(async()=>s?Be(E):!0,{refreshDeps:[s,E,B==null?void 0:B.open,U]}),i=s&&h,w=s&&!U&&h&&!(t!=null&&t.loading),X=s&&U&&h,L=s&&!h&&!C&&!U,W=async()=>{if(await Be(t==null?void 0:t.endpoint)){await p.configBlocklet({input:{did:[d.meta.did],configs:[{key:K.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_APP_BACKUP_ENDPOINT,value:t.endpoint}]}}),F(),v.success(o("storage.spaces.connect.switchToSpaceSucceeded",{name:t.name?`(${t.name})`:""}));return}T(Y=>({...Y,open:!0,prefix:V(t.url,"space/api/did"),baseUrl:new URL(t.url).origin,checkFn:le.create({baseURL:V(t.url,"space")}).get,extraParams:{appDid:D,appName:S,appDescription:g,scopes:A,appUrl:k,referrer:H,nodeDid:m,spaceDid:t.did}}))},Je=async(b,Y)=>{const ie=Y(b.endpoint),Qe=se(ie),z=b.space?Y(b.space):{};if(t.did&&Qe!==t.did){T(re=>({...re,open:!1})),v.error(o("storage.spaces.gateway.switch.failedForMismatchSpace",{name:z!=null&&z.name?z.name:""}));return}const He={...t,name:z.name??"DID Space",did:z.did??se(ie),endpoint:ie};await I(He),T(re=>({...re,open:!1}))},Ze=async()=>{try{if(U)return;R(!0),await n()}catch(b){console.error(b),v.error(b.message)}finally{R(!0)}};return x.useEffect(()=>{u!=null&&u.completed?((u==null?void 0:u.progress)===100&&v.success(o("storage.spaces.backupSuccessfully")),R(!1),u.progress=0,u.message=""):u.progress&&R(!0)},[u]),e.jsxs(Nt,{sx:{backgroundColor:s?"#F0FDFF":"inherit","&:hover":{backgroundColor:s?"#F0FDFF":"#FBFBFB"},borderRadius:"8px"},display:"flex",flexDirection:"column",padding:"4px 20px 12px",...l,children:[e.jsxs(j,{display:"flex",alignItems:"center",children:[e.jsxs(j,{flex:1,children:[i&&e.jsxs(y,{color:"primary",fontSize:14,children:[e.jsx(Le,{style:{marginRight:"8px"}}),o("storage.spaces.connected.tag")]}),L&&e.jsxs(y,{color:"error",fontSize:14,children:[e.jsx(Me,{style:{marginRight:"8px"}}),o("storage.spaces.disconnected.tag")]})]}),e.jsx(xe,{sx:{padding:"4px"},spaceGateway:t,connected:s,onDelete:a,onConnect:W,enableSwitchToSpace:(u==null?void 0:u.completed)||J.isEmpty(u==null?void 0:u.message),backupInProgress:X})]}),e.jsxs(j,{display:"flex",children:[e.jsxs(j,{display:"flex",flexDirection:"column",flex:"1",minWidth:0,children:[e.jsx(y,{className:"spaces-name",fontSize:"1rem",fontWeight:"bold",children:t.name}),e.jsx(j,{className:"spaces-address",display:X?"none":"flex",color:"#9397A1",marginTop:"4px",children:e.jsx(y,{sx:{display:"inline-flex",alignItems:"center",fontSize:"14px"},color:"#9397A1",children:t.did&&e.jsx(nt,{copyable:!1,size:14,compact:!0,responsive:!1,did:t.did})})}),e.jsxs(j,{className:"spaces-backup",display:"flex",alignItems:"center",marginTop:"8px",flex:1,children:[w&&e.jsxs(j,{className:"backup-strategy",display:"flex",alignItems:"center",minWidth:"72px",children:[e.jsx(te,{variant:"contained",size:"small",onClick:Ze,children:o("storage.spaces.strategy.backupNow")}),Ct&&e.jsx(De,{name:"enable-auto-backup",title:"coming soon",disabled:!0,labelProps:{label:e.jsx(y,{sx:{marginRight:"8px",fontSize:"16px"},children:e.jsx("span",{children:o("storage.spaces.strategy.autoBackup")})})},style:{marginLeft:"64px"}})]}),X&&e.jsxs(j,{className:"backup-progress",display:"flex",flexDirection:"column",alignItems:"center",marginLeft:c&&"16px",width:"90%",marginRight:"auto",alignSelf:"flex-end",children:[e.jsx(y,{color:"primary",children:u==null?void 0:u.message}),e.jsxs(j,{sx:{display:"flex",alignItems:"center"},width:"100%",children:[e.jsx(j,{sx:{width:"100%",mr:1},children:e.jsx(ot,{color:"primary",variant:"determinate",value:u==null?void 0:u.progress})}),e.jsx(j,{sx:{maxWidth:"100%"},children:e.jsxs(y,{variant:"body2",color:"text.secondary",children:[u==null?void 0:u.progress,"%"]})})]})]}),L&&e.jsx(j,{className:"backup-strategy",display:"flex",alignItems:"center",minWidth:"72px",children:e.jsx(te,{color:"error",variant:"contained",size:"small",onClick:W,children:o("storage.spaces.disconnected.reconnectNow")})})]})]}),e.jsx(pt,{alt:t.did,src:gt(t.endpoint),width:"72px",height:"72px"})]}),e.jsx(de,{forceConnected:!1,saveConnect:!1,prefix:B.prefix,open:B.open,popup:!0,action:B.action,baseUrl:B.baseUrl,checkFn:B.checkFn,onSuccess:Je,onClose:B.onClose,checkTimeout:B.checkTimeout,extraParams:B.extraParams,messages:B.messages,locale:r},"get-endpoint"),e.jsx(j,{className:`selected-container ${s?"selected":""}`,children:e.jsx(at,{className:"selected-icon"})})]})}ge.propTypes={spaceGateway:f.shape({did:f.string.isRequired,name:f.string.isRequired,url:f.string.isRequired,endpoint:f.string.isRequired,protected:f.bool,loading:f.bool}).isRequired,connected:f.bool.isRequired,progress:f.any.isRequired,onDelete:f.func,onBackupNow:f.func};ge.defaultProps={onDelete:()=>{},onBackupNow:()=>{}};const Nt=ke(j)`
|
|
2
|
-
box-sizing: border-box;
|
|
3
|
-
position: relative;
|
|
4
|
-
min-height: 136px;
|
|
5
|
-
border: 1px solid #f8f8f8;
|
|
6
|
-
|
|
7
|
-
.selected-container {
|
|
8
|
-
position: absolute;
|
|
9
|
-
right: 0px;
|
|
10
|
-
bottom: 0px;
|
|
11
|
-
display: flex;
|
|
12
|
-
-webkit-box-pack: end;
|
|
13
|
-
justify-content: flex-end;
|
|
14
|
-
align-items: flex-end;
|
|
15
|
-
width: 32px;
|
|
16
|
-
height: 32px;
|
|
17
|
-
border-radius: 0px 0px 8px;
|
|
18
|
-
color: rgb(255, 255, 255);
|
|
19
|
-
overflow: hidden;
|
|
20
|
-
transition: all 0.4s ease 0s;
|
|
21
|
-
|
|
22
|
-
&::after {
|
|
23
|
-
position: absolute;
|
|
24
|
-
z-index: 0;
|
|
25
|
-
left: 60px;
|
|
26
|
-
top: 60px;
|
|
27
|
-
display: block;
|
|
28
|
-
width: 0px;
|
|
29
|
-
height: 0px;
|
|
30
|
-
border-width: 16px;
|
|
31
|
-
border-style: solid;
|
|
32
|
-
border-color: transparent #1dc1c7 #1dc1c7 transparent;
|
|
33
|
-
transition: all 0.1s ease 0s;
|
|
34
|
-
content: '';
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.selected-icon {
|
|
38
|
-
visibility: hidden;
|
|
39
|
-
width: 60%;
|
|
40
|
-
height: 60%;
|
|
41
|
-
position: relative;
|
|
42
|
-
z-index: 2;
|
|
43
|
-
margin: 0px 1px 1px 0px;
|
|
44
|
-
font-size: 16px;
|
|
45
|
-
transition: all 0.2s ease 0s;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.selected-container.selected {
|
|
50
|
-
&::after {
|
|
51
|
-
left: 0px;
|
|
52
|
-
top: 0px;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.selected-icon {
|
|
56
|
-
visibility: visible;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.spaces {
|
|
61
|
-
&-name {
|
|
62
|
-
margin-right: 12px;
|
|
63
|
-
white-space: nowrap;
|
|
64
|
-
overflow: hidden;
|
|
65
|
-
text-overflow: ellipsis;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
`;var je={},Pt=oe;Object.defineProperty(je,"__esModule",{value:!0});var Ne=je.default=void 0,zt=Pt(ne()),Jt=e;Ne=je.default=(0,zt.default)((0,Jt.jsx)("path",{d:"M11 18h2v-2h-2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4"}),"HelpOutline");function Pe({...t}){const{t:s,locale:a}=O(),{spaceGateways:n,backups:l}=Q(),c=[{label:"DID Spaces",name:"target",options:{customBodyRenderLite:o=>{var A;const{targetUrl:r,targetName:d,status:p,createdAt:m}=l[o],D=p===M.BACKUPS.STATUS.PROGRESS&&q().diff(m,"hours")>=M.BACKUPS.TIMEOUT_HOURS,S=p===M.BACKUPS.STATUS.SUCCEEDED&&!D,g=d||((A=n.find(k=>r==null?void 0:r.includes(se(k==null?void 0:k.endpoint))))==null?void 0:A.name)||"Unknown DID Space";return S?e.jsx(it,{fontSize:"16px",href:r,target:"_blank",children:g}):e.jsx(y,{variant:"body1",fontSize:"16px",children:g})}}},{label:s("common.strategy"),name:"strategy",options:{customBodyRender:o=>{const r=s(o===0?"common.auto":"common.manual");return e.jsx(ce,{children:r})}}},{label:s("common.startTime"),name:"createdAt",options:{customBodyRender:o=>q(o).format("YYYY-MM-DD HH:mm:ss")}},{label:s("common.endTime"),name:"updatedAt",options:{customBodyRender:o=>J.isEmpty(o)?"":q(o).format("YYYY-MM-DD HH:mm:ss")}},{label:s("common.status"),name:"status",options:{customBodyRenderLite:o=>{const{status:r,message:d,createdAt:p}=(l==null?void 0:l[o])??{},m=r===M.BACKUPS.STATUS.PROGRESS&&q().diff(p,"hours")>=M.BACKUPS.TIMEOUT_HOURS,D=m&&s("common.timeoutError"),S=r===M.BACKUPS.STATUS.PROGRESS&&!m,g=r===M.BACKUPS.STATUS.SUCCEEDED&&!m;return S?e.jsxs(y,{display:"inline-flex",alignItems:"center",fontSize:"14px",children:[e.jsx(Z,{sx:{marginRight:"4px"},size:"12px"}),s("common.progress")]}):g?e.jsx(ce,{type:"success",children:s("common.succeeded")}):e.jsxs(j,{display:"inline-flex",alignItems:"center",children:[e.jsx(ce,{type:"error",children:s("common.failed")})," ",e.jsx(rt,{style:{display:"flex",alignItems:"center",flexShrink:0},title:d||D,children:e.jsx(ct,{children:e.jsx(Ne,{style:{width:"24px",height:"24px"},color:"error"})})})]})}}}];return e.jsx(j,{...t,children:l!=null&&l.length?e.jsx(Bt,{title:e.jsx(y,{fontSize:"1.2rem",fontWeight:"bold",children:s("storage.spaces.backup.records")}),data:l,columns:c,emptyNode:s("storage.spaces.record.emptyData",a),options:{download:!1,filter:!1,print:!1}}):e.jsxs(e.Fragment,{children:[e.jsx(j,{display:"flex",height:"56px",lineHeight:"56px",alignItems:"center",children:e.jsx(y,{fontSize:"1.2rem",fontWeight:"bold",children:s("storage.spaces.backup.records")})}),e.jsx(j,{color:"#9397A1",marginTop:"16px",marginBottom:"24px",children:s("storage.spaces.record.emptyData")})]})})}Pe.propTypes={};function ze({...t}){const{t:s}=O(),{autoBackup:a,updateAutoBackup:n}=Q(),l=async()=>{try{const c=!(a!=null&&a.enabled);await n({enabled:c}),v.success(s(c?"storage.spaces.autoBackup.enabled":"storage.spaces.autoBackup.disabled"))}catch(c){v.error(c.message)}};return e.jsx(De,{checked:!!(a!=null&&a.enabled),onChange:l,name:"enableWelcomePage",labelProps:{label:e.jsx(y,{marginRight:"8px",children:e.jsx("span",{children:s("storage.spaces.autoBackup.title")})})},style:{...t.style}})}ze.propTypes={};function Zt(){const{t}=O(),{blocklet:s}=P(),{api:a}=N(),{spaceGateways:n,spaceGatewaysLoading:l,deleteSpaceGateway:c,spaceGatewayIsSelected:o}=Q(),r=l&&!(n!=null&&n.length),d=async m=>{await c(m),v.success(t("storage.spaces.gateway.delete.succeeded",{name:`(${m.name})`}))},p=async()=>{await a.backupBlocklet({input:{appDid:s.appDid,to:"spaces"}})};return e.jsxs(j,{display:"flex",flexDirection:"column",children:[e.jsxs(j,{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between",marginBottom:"12px",children:[e.jsx(y,{fontSize:"1.2rem",fontWeight:"bold",flexGrow:1,children:t("storage.spaces.connected.title")}),e.jsx(ze,{style:{marginRight:"32px"}}),e.jsx(ae,{})]}),e.jsx(j,{children:r?e.jsx(j,{display:"flex",justifyContent:"center",children:e.jsx(Z,{})}):e.jsx(ye,{container:!0,spacing:1,children:n.map(m=>e.jsx(ye,{item:!0,xs:12,md:6,children:e.jsx(ge,{style:{marginTop:"12px"},spaceGateway:m,connected:o(m),onDelete:d,onBackupNow:p},m.endpoint)}))})}),e.jsx(Pe,{sx:{marginTop:"24px"}}),e.jsx(y,{fontSize:"1.2rem",fontWeight:"bold",mb:2,children:t("common.dataStorage")}),e.jsx(we,{})]})}function Qt(){const{spaceGatewaysLoading:t,spaceGateways:s}=Q();return t?e.jsx(lt,{relative:"parent",children:e.jsx(Z,{})}):dt(s)?e.jsx(Re,{}):e.jsx(Zt,{})}function Ss(){return e.jsx(pe,{children:e.jsx(Qt,{})})}export{Ss as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{gc as o}from"./index-CRLxFVWY.js";const t=new o,l=t;export{l as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as m,f as l,N as s,j as o,P as a}from"./index-CRLxFVWY.js";import{T as c,M as n,t as u}from"./table-icons-TmY--eR2.js";import"./FilterList-Bw1ZqePf.js";import"./useThemeProps-Cqic-E0U.js";import"./Select-C--LsVoO.js";import"./Delete-DmepPquU.js";import"./InputLabel-C31crC9j.js";import"./TextField-D1TVUQl2.js";import"./LastPage-15pWD2wJ.js";import"./slicedToArray-C3_toPJB.js";import"./Search-B0peOjeQ.js";import"./actions-Drufb-pQ.js";import"./useLocalStorage-DABDAbRI.js";import"./MoreVert-s3M1upT5.js";import"./ButtonGroup-D2VNVq8p.js";import"./getValidReactChildren-Bwdvi5zb.js";import"./status-dc380TH5.js";import"./url-evaluation-Oli2ZbAu.js";import"./ChevronLeft-CsFylH21.js";import"./Edit-D1BvuH2M.js";import"./ChevronRight-DB27L3xw.js";import"./DeleteOutline-o5TFeql0.js";import"./redux-CaV6uiOr.js";import"./Skeleton-CaItownp.js";import"./InputAdornment-BRIOp0gH.js";import"./index-BUnnmW1r.js";import"./memoize-one.esm-BdPwpGay.js";import"./Add-240wNjwq.js";import"./ArrowDropDown-C_UcQOEh.js";function d({blocklet:i,...r}){const{t}=m.useContext(l),e=s.getBlockletServices(i);if(e.length===0)return o.jsx("div",{children:t("blocklet.noService")});const p=[{title:t("common.name"),field:"name"},{title:t("common.protocol"),field:"protocol"},{title:t("common.port"),field:"port"},{title:t("blocklet.upstreamPort"),field:"upstreamPort"}];return o.jsx(c,{...r,children:o.jsx(n,{columns:p,icons:{...u},options:{sorting:!1,emptyRowsWhenPaging:!1,actionsColumnIndex:-1,tableLayout:"auto",maxBodyHeight:"100%",search:!1,pageSize:1e3,pageSizeOptions:[1e3]},localization:{body:{emptyDataSourceMessage:t("blocklet.noService")}},data:e})})}d.propTypes={blocklet:a.object.isRequired};export{d as default};
|