@abtnode/blocklet-services 1.16.13-beta-423a40b1 → 1.16.13-beta-d17a7de4
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/api/routes/blocklet.js +25 -0
- package/api/services/static.js +4 -0
- package/api/util/index.js +1 -1
- package/build/asset-manifest.json +70 -69
- package/build/index.html +1 -1
- package/build/service-worker.js +3 -0
- package/build/service-worker.js.LICENSE.txt +1 -0
- package/build/service-worker.js.map +1 -0
- package/build/static/css/main.7ea79dc8.css +2 -0
- package/build/static/js/343.2a12718c.chunk.js +2 -0
- package/build/static/js/716.1c25a58a.chunk.js +2 -0
- package/build/static/js/main.9c09d1dd.js +3 -0
- package/package.json +31 -24
- package/build/manifest.json +0 -15
- package/build/static/css/main.632501d5.css +0 -2
- package/build/static/js/343.eb7c9faf.chunk.js +0 -2
- package/build/static/js/716.69235521.chunk.js +0 -2
- package/build/static/js/main.af84eb83.js +0 -3
- /package/build/static/js/{main.af84eb83.js.LICENSE.txt → main.9c09d1dd.js.LICENSE.txt} +0 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_abtnode_blocklet_services=self.webpackChunk_abtnode_blocklet_services||[]).push([[716],{44716:function(e,n,t){t.r(n);var o,c=t(71171),r=t(32723),a=t(34795),s=t(30969),i=t(16380),l=t(30734),d=t(86822),u=t(94308),f=t(38361),p=t(6779),h=t(81721),g=t(99811),w=t(7284),x=t(42167),m=t(41362),v=t(20244),_=t(4485),P=t(38507),I=t(37574),k=function(e){setTimeout((function(){var n=new URL(window.location.href).searchParams.get("redirect");if(n){var t=decodeURIComponent(n);t.startsWith(v.WELLKNOWN_SERVICE_PATH_PREFIX)?e(t,{replace:!0}):window.location=t}else window.location=window.env.pathPrefix||"/"}),50)};n.default=function(){var e=(0,_.Tt)(),n=e.api,t=e.session,o=(0,x.useLocaleContext)(),c=o.t,i=o.locale,b=(0,m.default)().getPassportId,L=(0,l.useNavigate)(),R=new URL(window.location.href).searchParams,j=R.get("redirect"),C=R.get("forceStayLogin"),T=window.blocklet.trustedFactories||[],y=function(){var e=(0,a.Z)((0,r.Z)().mark((function e(n,o){return(0,r.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(0,P.ZB)(o(n.sessionToken)),(0,P.zI)(o(n.refreshToken)),e.next=4,t.refresh();case 4:C&&k(L);case 5:case"end":return e.stop()}}),e)})));return function(n,t){return e.apply(this,arguments)}}();(0,s.useEffect)((function(){null!==t&&void 0!==t&&t.user&&!C&&k(L)}),[null===t||void 0===t?void 0:t.user]);var N={passportId:b()},W=R.get("componentId");return W&&(N.componentId=W),t.loading||t.user&&!C?(0,I.jsx)(h.default,{children:(0,I.jsx)(u.Z,{})}):(0,I.jsx)(E,{children:(0,I.jsx)("div",{className:"connect-wrapper",children:(0,I.jsx)(w.default,{className:"connect",action:"login",checkFn:n.get,checkTimeout:6e5,webWalletUrl:(0,P.yP)(),onSuccess:y,onError:function(e){g.default.error(e.message)},locale:i,messages:{title:c("login.dialog.title"),scan:c("login.dialog.scan"),confirm:c("login.dialog.confirm"),success:c("login.dialog.success")},extraParams:N,extraContent:(0,I.jsxs)(f.Z,{textAlign:"center",fontSize:14,children:[(0,I.jsx)(d.Link,{to:"".concat(v.WELLKNOWN_SERVICE_PATH_PREFIX,"/lost-passport?redirect=").concat(encodeURIComponent("".concat(window.location.pathname).concat(window.location.search))),style:{marginRight:24,color:"#4598FA"},children:c("lostPassport.title")}),T.length>0&&(0,I.jsx)(p.Z,{title:c("exchangePassport.tooltip",{collections:T.map((function(e){return e.factoryAddress}))}),placement:"top-end",enterTouchDelay:0,children:(0,I.jsx)(d.Link,{to:"".concat(v.WELLKNOWN_SERVICE_PATH_PREFIX,"/exchange-passport?redirect=").concat(encodeURIComponent(j||"/")),style:{color:"#4598FA"},children:c("exchangePassport.title")})})]})})})})};var E=i.default.div(o||(o=(0,c.Z)(["\n box-sizing: border-box;\n width: 100%;\n height: 100vh;\n position: relative;\n display: flex;\n flex-direction: column;\n .connect-wrapper {\n flex: 1;\n }\n .connect {\n background: #fafafa;\n }\n"])))},41362:function(e,n,t){var o=t(43681).default;Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=(0,r.default)("passportId",""),n=o(e,3),t=n[0],c=n[1],a=n[2];return{getPassportId:function(){return setTimeout((function(){a()}),0),t||""},setPassportId:c}};var c,r=(c=t(17708))&&c.__esModule?c:{default:c}}}]);
|
|
2
|
+
//# sourceMappingURL=716.1c25a58a.chunk.js.map
|