@abtnode/webapp 1.16.22-beta-079a9053 → 1.16.22-beta-5bf86cd3
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/build/asset-manifest.json +48 -48
- package/build/index.html +1 -1
- package/build/service-worker.js +1 -1
- package/build/static/js/{1371.08ecc84e.chunk.js → 1371.4f86888b.chunk.js} +1 -1
- package/build/static/js/1524.3b0ec35f.chunk.js +1 -0
- package/build/static/js/{1685.c6f7a83f.chunk.js → 1685.24d88e27.chunk.js} +2 -2
- package/build/static/js/2168.62300f53.chunk.js +1 -0
- package/build/static/js/{2183.e57ce8a2.chunk.js → 2183.ddd3936e.chunk.js} +1 -1
- package/build/static/js/{2334.6c96ef7e.chunk.js → 2334.84a8e434.chunk.js} +1 -1
- package/build/static/js/2365.16f3dbc1.chunk.js +1 -0
- package/build/static/js/{2537.a919ce43.chunk.js → 2537.10cf10fb.chunk.js} +1 -1
- package/build/static/js/271.ebf7defb.chunk.js +1 -0
- package/build/static/js/2743.7ccb1ce1.chunk.js +1 -0
- package/build/static/js/2746.fd77f428.chunk.js +1 -0
- package/build/static/js/{2960.e4c10af0.chunk.js → 2960.dc7a03a7.chunk.js} +1 -1
- package/build/static/js/3058.7f0e2deb.chunk.js +1 -0
- package/build/static/js/{3135.f99a1aa8.chunk.js → 3135.06e7d03e.chunk.js} +1 -1
- package/build/static/js/{3216.4aabeb78.chunk.js → 3216.5aaf107a.chunk.js} +1 -1
- package/build/static/js/3883.0112051a.chunk.js +1 -0
- package/build/static/js/406.c80917a9.chunk.js +1 -0
- package/build/static/js/436.f127179d.chunk.js +1 -0
- package/build/static/js/4382.a5f73253.chunk.js +2 -0
- package/build/static/js/{2365.a3571172.chunk.js → 4494.765058da.chunk.js} +1 -1
- package/build/static/js/{4509.04d35bd4.chunk.js → 4509.3cdaa94a.chunk.js} +2 -2
- package/build/static/js/4549.eb1a0008.chunk.js +1 -0
- package/build/static/js/{4775.124a71e4.chunk.js → 4775.b81d9965.chunk.js} +1 -1
- package/build/static/js/4901.ea8e5819.chunk.js +1 -0
- package/build/static/js/5015.bfc1ea50.chunk.js +1 -0
- package/build/static/js/{5074.5643e827.chunk.js → 5074.217389e9.chunk.js} +1 -1
- package/build/static/js/5374.31d70f69.chunk.js +1 -0
- package/build/static/js/{5526.7f392e7e.chunk.js → 5526.9376db8c.chunk.js} +2 -2
- package/build/static/js/5760.a3d6922a.chunk.js +1 -0
- package/build/static/js/{5887.530ce24e.chunk.js → 5887.6dc2a410.chunk.js} +2 -2
- package/build/static/js/5914.67e3aeec.chunk.js +2 -0
- package/build/static/js/592.88e3bf00.chunk.js +2 -0
- package/build/static/js/{5979.4e4ebbf1.chunk.js → 5979.75079fe1.chunk.js} +1 -1
- package/build/static/js/6016.d86b229d.chunk.js +1 -0
- package/build/static/js/{6230.467a9016.chunk.js → 6230.3bb084aa.chunk.js} +1 -1
- package/build/static/js/6511.ee040676.chunk.js +1 -0
- package/build/static/js/{6931.4d7ae323.chunk.js → 6931.d2496fd4.chunk.js} +1 -1
- package/build/static/js/6950.e6d42b1a.chunk.js +1 -0
- package/build/static/js/{7657.60faa231.chunk.js → 7657.3acd5e07.chunk.js} +2 -2
- package/build/static/js/7687.5f2226d4.chunk.js +1 -0
- package/build/static/js/{7875.a04872ec.chunk.js → 7875.904b3a92.chunk.js} +2 -2
- package/build/static/js/{8219.33f29652.chunk.js → 8219.07ee6bf9.chunk.js} +1 -1
- package/build/static/js/{9249.96584fcc.chunk.js → 9249.7f9c1c36.chunk.js} +1 -1
- package/build/static/js/9327.4c7b52f8.chunk.js +1 -0
- package/build/static/js/95.c12b33e8.chunk.js +1 -0
- package/build/static/js/{9552.29d817f2.chunk.js → 9552.87dae9a5.chunk.js} +1 -1
- package/build/static/js/main.3831c581.js +2 -0
- package/build/static/js/{main.f7eb1485.js.LICENSE.txt → main.3831c581.js.LICENSE.txt} +1 -1
- package/package.json +1 -1
- package/build/static/js/1185.4672e754.chunk.js +0 -2
- package/build/static/js/1524.dd0af8c0.chunk.js +0 -1
- package/build/static/js/2168.0e7f9ae7.chunk.js +0 -1
- package/build/static/js/2529.061c5064.chunk.js +0 -1
- package/build/static/js/271.f7901bf2.chunk.js +0 -1
- package/build/static/js/2743.99b9b3be.chunk.js +0 -1
- package/build/static/js/3058.cea35b61.chunk.js +0 -1
- package/build/static/js/3137.93dab4d8.chunk.js +0 -1
- package/build/static/js/3883.062d06a9.chunk.js +0 -1
- package/build/static/js/406.37ef18fa.chunk.js +0 -1
- package/build/static/js/4382.f8edadf8.chunk.js +0 -2
- package/build/static/js/4549.295531bf.chunk.js +0 -1
- package/build/static/js/4901.7dab9c36.chunk.js +0 -1
- package/build/static/js/5015.c33215f2.chunk.js +0 -1
- package/build/static/js/5509.2e6eb7fd.chunk.js +0 -1
- package/build/static/js/5760.02d5f257.chunk.js +0 -1
- package/build/static/js/5914.fbf45688.chunk.js +0 -2
- package/build/static/js/6016.036a6045.chunk.js +0 -1
- package/build/static/js/6511.44e20630.chunk.js +0 -1
- package/build/static/js/6580.fc3c74eb.chunk.js +0 -1
- package/build/static/js/6950.9da8ac88.chunk.js +0 -1
- package/build/static/js/7687.c54b6889.chunk.js +0 -1
- package/build/static/js/9327.cefafd96.chunk.js +0 -1
- package/build/static/js/95.08f81beb.chunk.js +0 -1
- package/build/static/js/main.f7eb1485.js +0 -2
- /package/build/static/js/{1685.c6f7a83f.chunk.js.LICENSE.txt → 1685.24d88e27.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{4382.f8edadf8.chunk.js.LICENSE.txt → 4382.a5f73253.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{4509.04d35bd4.chunk.js.LICENSE.txt → 4509.3cdaa94a.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{5526.7f392e7e.chunk.js.LICENSE.txt → 5526.9376db8c.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{5887.530ce24e.chunk.js.LICENSE.txt → 5887.6dc2a410.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{5914.fbf45688.chunk.js.LICENSE.txt → 5914.67e3aeec.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{1185.4672e754.chunk.js.LICENSE.txt → 592.88e3bf00.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{7657.60faa231.chunk.js.LICENSE.txt → 7657.3acd5e07.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{7875.a04872ec.chunk.js.LICENSE.txt → 7875.904b3a92.chunk.js.LICENSE.txt} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
(self.webpackChunk_abtnode_webapp=self.webpackChunk_abtnode_webapp||[]).push([[8219],{24460:(e,n,t)=>{const a=t(93845);e.exports=e=>a((e||"").replace(/^[@./-]/,"").replace(/[@./_]/g,"-"))},92379:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>u});var a=t(55898),i=t.n(a),l=t(39948),o=t(80576),r=t(51177),s=t(74490),d=t(67654),c=t(43077),p=t(13644),m=t(96266);function u(e){let{blocklet:n,...t}=e;const a=((null===n||void 0===n?void 0:n.children)||[]).map((e=>({did:e.meta.did,name:e.meta.title,types:["error","info","access","stdout","stderr"]}))),[i,u]=(0,d.Z)("blocklet-log-".concat(n.meta.did),"");let[g,h]=i.split(",");var x;a.find((e=>e.did===g))||(g=null===(x=a[0])||void 0===x?void 0:x.did);const f=(0,m.jsx)(o.Z,{sx:{minWidth:240},children:(0,m.jsx)(r.Z,{value:g,onChange:e=>{u([e.target.value,h].join(","))},size:"small",children:a.map((e=>(0,m.jsx)(s.Z,{value:e.did,children:e.name},e.did)))})}),b=a.find((e=>e.did===g))||a[0]||n.meta;return(0,m.jsx)(l.Z,{height:{xs:"calc(100vh - 444px)",sm:"calc(100vh - 508px)",md:"calc(100vh - 445px)"},...t,children:(0,m.jsx)(c.l,{logId:b===n.meta?"blocklet-".concat(n.meta.did):"blocklet-".concat(n.meta.did,"/").concat(b.did),initialData:['Tip: this tab will only show runtime logs. Please go to "Blocklet Server" to view other lifecycle logs of the blocklet (install/start/stop...)',"\r\n\r\n"],prepend:f,postpend:(0,m.jsx)(p.Z,{id:n.meta.did,name:n.meta.name}),name:b.name,types:b.types,defaultTypeIndex:h,onTypeChange:e=>{const n=b.types.indexOf(e);u([g,n||0].join(","))}},b.did)})}u.propTypes={blocklet:i().object.isRequired}},13644:(e,n,t)=>{"use strict";t.d(n,{Z:()=>k});var a=t(5057),i=t(55898),l=t.n(i),o=t(1577),r=t.n(o),s=t(39948),d=t(63878),c=t(80576),p=t(51177),m=t(74490),u=t(44846),g=t(28726),h=t(68420),x=t(13128),f=t(24460),b=t.n(f),y=t(86229),v=t(58238),w=t(96266);const j=[1,7];function k(e){let{id:n,name:t}=e;const{t:i}=(0,h.PE)(),{restApi:l,inService:o}=(0,v.h6)(),[f,k]=(0,a.useState)(!1),[Z,C]=(0,a.useState)(!1),[T,E]=(0,a.useState)(1);return[(0,w.jsx)(s.Z,{display:"flex",alignItems:"center",style:{gap:16},children:(0,w.jsxs)(g.Z,{"data-cy":"download-logs",variant:"outlined",onClick:()=>k(!0),disabled:Z,children:[Z?(0,w.jsx)(u.Z,{size:16}):(0,w.jsx)(d.Z,{fontSize:"small",style:{transform:"translateY(2px)"}}),(0,w.jsx)(s.Z,{ml:.5,children:i("common.download")})]})}),f&&(0,w.jsx)(x.ZP,{open:!0,onClose:()=>{k(!1)},disableEscapeKeyDown:!0,title:i("common.download"),PaperProps:{style:{minHeight:"auto"}},actions:(0,w.jsxs)(g.Z,{"data-cy":"download-logs",variant:"outlined",onClick:()=>(async()=>{if(!Z)try{C(!0);const e=o?"":"/".concat(n),a=await l.get("/download/log".concat(e,"?days=").concat(T),{responseType:"blob"}),i=URL.createObjectURL(a.data),s=document.createElement("a");s.href=i,s.setAttribute("download","".concat(b()(t||n),".").concat(r()().format("YYYYMMDDHHmmss"),".log.zip")),document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(i),C(!1),k(!1)}catch(e){C(!1),y.Z.error(e.message)}})(),disabled:Z,children:[Z&&(0,w.jsx)(u.Z,{size:16}),(0,w.jsx)(s.Z,{ml:.5,children:i("common.confirm")})]}),children:(0,w.jsx)(s.Z,{mb:2,display:"flex",justifyContent:"center",children:(0,w.jsx)(c.Z,{size:"small",fullWidth:!0,children:(0,w.jsx)(p.Z,{value:T,onChange:e=>{E(e.target.value)},children:j.map((e=>(0,w.jsx)(m.Z,{value:e,children:i("log.lastDays.".concat(e))},e)))})})})})]}k.propTypes={id:l().string.isRequired,name:l().string},k.defaultProps={name:""}},43077:(e,n,t)=>{"use strict";t.d(n,{l:()=>y});var a=t(71171),i=t(5057),l=t(33518),o=t(55898),r=t.n(o),s=t(56556),d=t(
|
|
1
|
+
(self.webpackChunk_abtnode_webapp=self.webpackChunk_abtnode_webapp||[]).push([[8219],{24460:(e,n,t)=>{const a=t(93845);e.exports=e=>a((e||"").replace(/^[@./-]/,"").replace(/[@./_]/g,"-"))},92379:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>u});var a=t(55898),i=t.n(a),l=t(39948),o=t(80576),r=t(51177),s=t(74490),d=t(67654),c=t(43077),p=t(13644),m=t(96266);function u(e){let{blocklet:n,...t}=e;const a=((null===n||void 0===n?void 0:n.children)||[]).map((e=>({did:e.meta.did,name:e.meta.title,types:["error","info","access","stdout","stderr"]}))),[i,u]=(0,d.Z)("blocklet-log-".concat(n.meta.did),"");let[g,h]=i.split(",");var x;a.find((e=>e.did===g))||(g=null===(x=a[0])||void 0===x?void 0:x.did);const f=(0,m.jsx)(o.Z,{sx:{minWidth:240},children:(0,m.jsx)(r.Z,{value:g,onChange:e=>{u([e.target.value,h].join(","))},size:"small",children:a.map((e=>(0,m.jsx)(s.Z,{value:e.did,children:e.name},e.did)))})}),b=a.find((e=>e.did===g))||a[0]||n.meta;return(0,m.jsx)(l.Z,{height:{xs:"calc(100vh - 444px)",sm:"calc(100vh - 508px)",md:"calc(100vh - 445px)"},...t,children:(0,m.jsx)(c.l,{logId:b===n.meta?"blocklet-".concat(n.meta.did):"blocklet-".concat(n.meta.did,"/").concat(b.did),initialData:['Tip: this tab will only show runtime logs. Please go to "Blocklet Server" to view other lifecycle logs of the blocklet (install/start/stop...)',"\r\n\r\n"],prepend:f,postpend:(0,m.jsx)(p.Z,{id:n.meta.did,name:n.meta.name}),name:b.name,types:b.types,defaultTypeIndex:h,onTypeChange:e=>{const n=b.types.indexOf(e);u([g,n||0].join(","))}},b.did)})}u.propTypes={blocklet:i().object.isRequired}},13644:(e,n,t)=>{"use strict";t.d(n,{Z:()=>k});var a=t(5057),i=t(55898),l=t.n(i),o=t(1577),r=t.n(o),s=t(39948),d=t(63878),c=t(80576),p=t(51177),m=t(74490),u=t(44846),g=t(28726),h=t(68420),x=t(13128),f=t(24460),b=t.n(f),y=t(86229),v=t(58238),w=t(96266);const j=[1,7];function k(e){let{id:n,name:t}=e;const{t:i}=(0,h.PE)(),{restApi:l,inService:o}=(0,v.h6)(),[f,k]=(0,a.useState)(!1),[Z,C]=(0,a.useState)(!1),[T,E]=(0,a.useState)(1);return[(0,w.jsx)(s.Z,{display:"flex",alignItems:"center",style:{gap:16},children:(0,w.jsxs)(g.Z,{"data-cy":"download-logs",variant:"outlined",onClick:()=>k(!0),disabled:Z,children:[Z?(0,w.jsx)(u.Z,{size:16}):(0,w.jsx)(d.Z,{fontSize:"small",style:{transform:"translateY(2px)"}}),(0,w.jsx)(s.Z,{ml:.5,children:i("common.download")})]})}),f&&(0,w.jsx)(x.ZP,{open:!0,onClose:()=>{k(!1)},disableEscapeKeyDown:!0,title:i("common.download"),PaperProps:{style:{minHeight:"auto"}},actions:(0,w.jsxs)(g.Z,{"data-cy":"download-logs",variant:"outlined",onClick:()=>(async()=>{if(!Z)try{C(!0);const e=o?"":"/".concat(n),a=await l.get("/download/log".concat(e,"?days=").concat(T),{responseType:"blob"}),i=URL.createObjectURL(a.data),s=document.createElement("a");s.href=i,s.setAttribute("download","".concat(b()(t||n),".").concat(r()().format("YYYYMMDDHHmmss"),".log.zip")),document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(i),C(!1),k(!1)}catch(e){C(!1),y.Z.error(e.message)}})(),disabled:Z,children:[Z&&(0,w.jsx)(u.Z,{size:16}),(0,w.jsx)(s.Z,{ml:.5,children:i("common.confirm")})]}),children:(0,w.jsx)(s.Z,{mb:2,display:"flex",justifyContent:"center",children:(0,w.jsx)(c.Z,{size:"small",fullWidth:!0,children:(0,w.jsx)(p.Z,{value:T,onChange:e=>{E(e.target.value)},children:j.map((e=>(0,w.jsx)(m.Z,{value:e,children:i("log.lastDays.".concat(e))},e)))})})})})]}k.propTypes={id:l().string.isRequired,name:l().string},k.defaultProps={name:""}},43077:(e,n,t)=>{"use strict";t.d(n,{l:()=>y});var a=t(71171),i=t(5057),l=t(33518),o=t(55898),r=t.n(o),s=t(56556),d=t(80633),c=t(72904),p=t(9746),m=t(12726),u=t(14491);const g=function(){const[e,n]=(0,i.useState)(+new Date);return(0,m.Z)((()=>{n(+new Date)}),1e3),(0,u.mr)(e,"MMMM Do YYYY, h:mm:ss a")};var h,x,f=t(58238),b=t(96266);function y(e){let{name:n,logId:t,types:a,defaultTypeIndex:l,initialData:o,prepend:r,postpend:p,onTypeChange:m,...u}=e;const{ws:{useSubscription:g}}=(0,f.h6)(),h={info:"Info",error:"Error",access:"Access",stdout:"stdout",stderr:"stderr",pm2:"PM2"},x=(0,c.Z)((e=>e.breakpoints.down("md"))),[y,j]=(0,i.useState)(a[l||0]),[k,Z]=(0,i.useState)(),C=(0,i.useRef)({});return(0,i.useEffect)((()=>{a.forEach((e=>{const t=C.current[e];t&&(t.write("Collecting ".concat(e," logs for ").concat(n,"...")),t.write("\r\n\r\n"),o.forEach((e=>t.write(e))))}))}),[]),g("log.".concat(t),(e=>{k||Z(e.logFiles||{});const n=C.current[e.level];n&&(n.write(e.data.replace(/.\n/g,(e=>"\r\n"===e?e:"".concat(e[0],"\r\n\r\n")))),n.write("\r\n\r\n"))}),[]),(0,b.jsxs)(v,{...u,children:[(0,b.jsxs)("div",{className:"log-terminal-group-head",children:[(0,b.jsxs)("div",{className:"log-terminal-group-head-start",children:[r,(0,b.jsx)(d.Z,{variant:"outlined",size:x?"small":"medium",children:a.map((e=>{const n=e===y?{variant:"contained"}:{};return(0,b.jsx)(s.Z,{...n,onClick:()=>{j(e),m(e)},children:h[e]},e)}))})]}),(0,b.jsx)("div",{className:"log-terminal-group-head-end",children:p})]}),(0,b.jsx)("div",{className:"log-terminal-group-terminals",children:a.map((e=>(0,b.jsx)(w,{ref:n=>{C.current[e]=n},logFile:null===k||void 0===k?void 0:k[e],style:{visibility:e===y?"visible":"hidden"}},e)))})]})}y.propTypes={name:r().string.isRequired,logId:r().string.isRequired,types:r().arrayOf(r().string),defaultTypeIndex:r().number,initialData:r().arrayOf(r().string),prepend:r().node,postpend:r().node,onTypeChange:r().func},y.defaultProps={types:["error","info","access","stdout","stderr"],defaultTypeIndex:0,initialData:[],prepend:null,postpend:null,onTypeChange:()=>{}};const v=l.Z.div(h||(h=(0,a.Z)(["\n display: flex;\n flex-direction: column;\n height: 100%;\n .log-terminal-group-head {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding-bottom: 16px;\n }\n\n .log-terminal-group-head-start {\n flex: 0 0 auto;\n display: flex;\n align-items: center;\n gap: 16px;\n "," {\n flex-direction: column;\n align-items: start;\n }\n }\n\n .log-terminal-group-head-end {\n flex: 0 0 auto;\n display: flex;\n align-items: center;\n gap: 16px;\n "," {\n flex-direction: column;\n align-items: start;\n }\n }\n .log-terminal-group-terminals {\n flex: 1;\n position: relative;\n overflow: hidden;\n > * {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n }\n }\n"])),(e=>e.theme.breakpoints.down("md")),(e=>e.theme.breakpoints.down("md"))),w=(0,i.forwardRef)(((e,n)=>{let{logFile:t,...a}=e;return(0,b.jsxs)(j,{...a,children:[(0,b.jsxs)("div",{className:"log-terminal-top",children:[(0,b.jsx)(g,{}),t&&(0,b.jsx)("span",{children:t})]}),(0,b.jsx)("div",{className:"log-terminal-container",style:{position:"relative"},children:(0,b.jsx)(p.Z,{ref:n,style:{width:"100%",boxSizing:"border-box",height:"100%"},options:{theme:{background:"#2C313C",foreground:"#EEEEEE"}}})})]})}));w.propTypes={logFile:r().string},w.defaultProps={logFile:""};const j=l.Z.div(x||(x=(0,a.Z)(["\n height: 100%;\n display: flex;\n flex-direction: column;\n .log-terminal-top {\n flex: 0 0 auto;\n display: flex;\n justify-content: space-between;\n align-items: center;\n flex-wrap: wrap;\n padding: 8px;\n font-size: 14px;\n color: aquamarine;\n background: darkgray;\n word-break: break-word;\n }\n .log-terminal-container {\n flex: 1;\n height: 100%;\n padding: 8px;\n overflow: hidden;\n background: #2c313c;\n }\n\n .xterm-viewport::-webkit-scrollbar {\n width: 10px;\n }\n .xterm-viewport::-webkit-scrollbar-track {\n opacity: 0;\n }\n .xterm-viewport::-webkit-scrollbar-thumb {\n min-height: 20px;\n background-color: #ffffff20;\n }\n"])))}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunk_abtnode_webapp=self.webpackChunk_abtnode_webapp||[]).push([[9249],{49249:(e,n,t)=>{t.r(n),t.d(n,{default:()=>k});var s,i=t(71171),a=t(5057),o=t(33518),d=t(85493),l=t(11750),c=t(76005),r=t(39948),h=t(35966),u=t(28726),p=t(43316),f=t(8326),x=t(68420),b=t(35432),v=t(5766),m=t(70284),g=t(96266);const w=(0,o.Z)(h.Z)(s||(s=(0,i.Z)(["\n .header {\n text-align: center;\n margin-bottom: 8px;\n }\n\n .subheader {\n text-align: center;\n margin-bottom: 24px;\n }\n\n .login {\n padding: 24px;\n height: auto;\n min-height: 480px;\n display: flex;\n flex-direction: column;\n }\n\n .connect {\n background: #fafafa;\n }\n"]))),P=(0,v.Z)((function(e){var n,t,s,i;let{SessionContext:o,webWalletUrl:h}=e;const{api:v,session:P}=(0,a.useContext)(o),{t:Z,locale:j}=(0,a.useContext)(x.RD),[C,k]=(0,a.useState)(!1),W=(0,d.useNavigate)(),{setPassportId:N}=(0,m.Z)(),_={},{searchParams:E}=new URL(window.location.href),I=E.get("id");return I&&(_.id=I),(0,g.jsx)(w,{children:C?(0,g.jsx)("div",{className:"login",children:(0,g.jsx)("div",{className:"connect",children:(0,g.jsxs)(r.Z,{textAlign:"center",children:[(0,g.jsx)(r.Z,{mb:3,color:"success.main",children:(0,g.jsx)(c.Z,{style:{fontSize:60}})}),(0,g.jsx)(l.Z,{component:"p",variant:"body1",className:"subheader",children:Z("issuePassport.dialog.success")}),(0,g.jsx)(r.Z,{mt:3,children:(0,g.jsx)(u.Z,{variant:"contained",color:"primary",onClick:()=>{var e;try{P.logout()}catch(n){}((null===(e=window.env)||void 0===e?void 0:e.apiPrefix)||"").startsWith(b.WELLKNOWN_SERVICE_PATH_PREFIX)?W("".concat(b.WELLKNOWN_SERVICE_PATH_PREFIX,"/login"),{replace:!0}):W("/",{replace:!0})},children:Z("issuePassport.dialog.loginWithPassport")})})]})})}):(0,g.jsx)(f.Z,{did:(null===(n=window)||void 0===n||null===(t=n.blocklet)||void 0===t?void 0:t.appPid)||(null===(s=window)||void 0===s||null===(i=s.env)||void 0===i?void 0:i.appPid),children:(0,g.jsx)(r.Z,{sx:{width:"560px",maxWidth:"100%",height:"100%"},children:(0,g.jsx)(p.Z,{className:"connect",action:"issue-passport",forceConnected:!1,autoConnect:!1,checkFn:v.get,checkTimeout:6e5,webWalletUrl:h,onSuccess:e=>{null!==e&&void 0!==e&&e.passportId&&N(e.passportId),k(!0)},locale:j,messages:{title:Z("issuePassport.title"),scan:Z("issuePassport.description",{name:window.env.appName}),confirm:Z("issuePassport.dialog.confirm"),success:Z("issuePassport.dialog.success")},extraParams:_})})})})}));var Z=t(75793),j=t(25339),C=t(74094);function k(){const{info:e}=(0,Z.h6)(),n=(0,C.yP)(e);return(0,g.jsx)(P,{SessionContext:j.B3,webWalletUrl:n})}},5766:(e,n,t)=>{t.d(n,{Z:()=>c});var s=t(68420),i=t(77668),a=t.n(i),o=t(2586);const d={en:a()(o.Z),ar:()=>t.e(4465).then(t.bind(t,4465)).then((e=>a()(e.default))),de:()=>t.e(3803).then(t.bind(t,43803)).then((e=>a()(e.default))),es:()=>t.e(3930).then(t.bind(t,23930)).then((e=>a()(e.default))),fr:()=>t.e(2019).then(t.bind(t,82019)).then((e=>a()(e.default))),hi:()=>t.e(8590).then(t.bind(t,78768)).then((e=>a()(e.default))),id:()=>t.e(1575).then(t.bind(t,61575)).then((e=>a()(e.default))),ja:()=>t.e(233).then(t.bind(t,90233)).then((e=>a()(e.default))),ko:()=>t.e(8170).then(t.bind(t,48170)).then((e=>a()(e.default))),pt:()=>t.e(9586).then(t.bind(t,69586)).then((e=>a()(e.default))),ru:()=>t.e(1059).then(t.bind(t,81059)).then((e=>a()(e.default))),th:()=>t.e(5748).then(t.bind(t,55748)).then((e=>a()(e.default))),vi:()=>t.e(6906).then(t.bind(t,56906)).then((e=>a()(e.default))),"zh-TW":()=>t.e(4423).then(t.bind(t,64423)).then((e=>a()(e.default))),zh:()=>t.e(6944).then(t.bind(t,56944)).then((e=>a()(e.default)))};var l=t(96266);function c(e){return function(n){return(0,l.jsx)(s.Iw,{translations:d,children:(0,l.jsx)(e,{...n})})}}},76005:(e,n,t)=>{var s=t(71600);n.Z=void 0;var i=s(t(56930)),a=t(96266)
|
|
1
|
+
"use strict";(self.webpackChunk_abtnode_webapp=self.webpackChunk_abtnode_webapp||[]).push([[9249],{49249:(e,n,t)=>{t.r(n),t.d(n,{default:()=>k});var s,i=t(71171),a=t(5057),o=t(33518),d=t(85493),l=t(11750),c=t(76005),r=t(39948),h=t(35966),u=t(28726),p=t(43316),f=t(8326),x=t(68420),b=t(35432),v=t(5766),m=t(70284),g=t(96266);const w=(0,o.Z)(h.Z)(s||(s=(0,i.Z)(["\n .header {\n text-align: center;\n margin-bottom: 8px;\n }\n\n .subheader {\n text-align: center;\n margin-bottom: 24px;\n }\n\n .login {\n padding: 24px;\n height: auto;\n min-height: 480px;\n display: flex;\n flex-direction: column;\n }\n\n .connect {\n background: #fafafa;\n }\n"]))),P=(0,v.Z)((function(e){var n,t,s,i;let{SessionContext:o,webWalletUrl:h}=e;const{api:v,session:P}=(0,a.useContext)(o),{t:Z,locale:j}=(0,a.useContext)(x.RD),[C,k]=(0,a.useState)(!1),W=(0,d.useNavigate)(),{setPassportId:N}=(0,m.Z)(),_={},{searchParams:E}=new URL(window.location.href),I=E.get("id");return I&&(_.id=I),(0,g.jsx)(w,{children:C?(0,g.jsx)("div",{className:"login",children:(0,g.jsx)("div",{className:"connect",children:(0,g.jsxs)(r.Z,{textAlign:"center",children:[(0,g.jsx)(r.Z,{mb:3,color:"success.main",children:(0,g.jsx)(c.Z,{style:{fontSize:60}})}),(0,g.jsx)(l.Z,{component:"p",variant:"body1",className:"subheader",children:Z("issuePassport.dialog.success")}),(0,g.jsx)(r.Z,{mt:3,children:(0,g.jsx)(u.Z,{variant:"contained",color:"primary",onClick:()=>{var e;try{P.logout()}catch(n){}((null===(e=window.env)||void 0===e?void 0:e.apiPrefix)||"").startsWith(b.WELLKNOWN_SERVICE_PATH_PREFIX)?W("".concat(b.WELLKNOWN_SERVICE_PATH_PREFIX,"/login"),{replace:!0}):W("/",{replace:!0})},children:Z("issuePassport.dialog.loginWithPassport")})})]})})}):(0,g.jsx)(f.Z,{did:(null===(n=window)||void 0===n||null===(t=n.blocklet)||void 0===t?void 0:t.appPid)||(null===(s=window)||void 0===s||null===(i=s.env)||void 0===i?void 0:i.appPid),children:(0,g.jsx)(r.Z,{sx:{width:"560px",maxWidth:"100%",height:"100%"},children:(0,g.jsx)(p.Z,{className:"connect",action:"issue-passport",forceConnected:!1,autoConnect:!1,checkFn:v.get,checkTimeout:6e5,webWalletUrl:h,onSuccess:e=>{null!==e&&void 0!==e&&e.passportId&&N(e.passportId),k(!0)},locale:j,messages:{title:Z("issuePassport.title"),scan:Z("issuePassport.description",{name:window.env.appName}),confirm:Z("issuePassport.dialog.confirm"),success:Z("issuePassport.dialog.success")},extraParams:_})})})})}));var Z=t(75793),j=t(25339),C=t(74094);function k(){const{info:e}=(0,Z.h6)(),n=(0,C.yP)(e);return(0,g.jsx)(P,{SessionContext:j.B3,webWalletUrl:n})}},5766:(e,n,t)=>{t.d(n,{Z:()=>c});var s=t(68420),i=t(77668),a=t.n(i),o=t(2586);const d={en:a()(o.Z),ar:()=>t.e(4465).then(t.bind(t,4465)).then((e=>a()(e.default))),de:()=>t.e(3803).then(t.bind(t,43803)).then((e=>a()(e.default))),es:()=>t.e(3930).then(t.bind(t,23930)).then((e=>a()(e.default))),fr:()=>t.e(2019).then(t.bind(t,82019)).then((e=>a()(e.default))),hi:()=>t.e(8590).then(t.bind(t,78768)).then((e=>a()(e.default))),id:()=>t.e(1575).then(t.bind(t,61575)).then((e=>a()(e.default))),ja:()=>t.e(233).then(t.bind(t,90233)).then((e=>a()(e.default))),ko:()=>t.e(8170).then(t.bind(t,48170)).then((e=>a()(e.default))),pt:()=>t.e(9586).then(t.bind(t,69586)).then((e=>a()(e.default))),ru:()=>t.e(1059).then(t.bind(t,81059)).then((e=>a()(e.default))),th:()=>t.e(5748).then(t.bind(t,55748)).then((e=>a()(e.default))),vi:()=>t.e(6906).then(t.bind(t,56906)).then((e=>a()(e.default))),"zh-TW":()=>t.e(4423).then(t.bind(t,64423)).then((e=>a()(e.default))),zh:()=>t.e(6944).then(t.bind(t,56944)).then((e=>a()(e.default)))};var l=t(96266);function c(e){return function(n){return(0,l.jsx)(s.Iw,{translations:d,children:(0,l.jsx)(e,{...n})})}}},76005:(e,n,t)=>{var s=t(71600);n.Z=void 0;var i=s(t(56930)),a=t(96266);n.Z=(0,i.default)((0,a.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m-2 15-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8z"}),"CheckCircle")}}]);
|