@arcblock/did-connect-react 3.4.13 → 3.4.15

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.
@@ -1,44 +1,44 @@
1
- import { jsx as t, jsxs as b, Fragment as He } from "react/jsx-runtime";
2
- import { use as Ve, useRef as ce, useState as Ye, useEffect as le } from "react";
1
+ import { jsx as t, jsxs as b, Fragment as Ge } from "react/jsx-runtime";
2
+ import { use as Ye, useRef as ae, useState as Ke, useEffect as le } from "react";
3
3
  import e from "prop-types";
4
- import { Box as i, Skeleton as Ge, Divider as Ke } from "@mui/material";
5
- import { useUpdate as Qe, useSize as Xe, useCreation as u, useMount as ue, useMemoizedFn as F, useDebounceFn as Je, usePrevious as Ze, useUpdateEffect as $e } from "ahooks";
6
- import C from "lodash/noop";
7
- import et from "lodash/isUndefined";
8
- import tt from "@arcblock/ux/lib/CloseButton";
9
- import { DID_CONNECT_MEDIUM_WIDTH as N, LOGIN_PROVIDER_NAME as ot, DID_CONNECT_SMALL_WIDTH as rt, OAUTH_PROVIDER as j, LOGIN_PROVIDER as nt } from "@arcblock/ux/lib/Util/constant";
10
- import it from "@arcblock/ux/lib/QRCode";
11
- import { DIDConnectFooter as st } from "@arcblock/ux/lib/DIDConnect";
12
- import { useTheme as at } from "@arcblock/ux/lib/Theme";
13
- import ct from "@arcblock/ux/lib/DIDConnect/provider-icon";
4
+ import { Box as i, Skeleton as Qe, Divider as Xe } from "@mui/material";
5
+ import { useUpdate as Je, useMemoizedFn as S, useSize as Ze, useCreation as d, useMount as ue, useDebounceFn as $e, usePrevious as et, useUpdateEffect as tt } from "ahooks";
6
+ import w from "lodash/noop";
7
+ import ot from "lodash/isUndefined";
8
+ import rt from "@arcblock/ux/lib/CloseButton";
9
+ import { WALLET_LOGIN_METHOD as nt, LAST_USED_LOGIN_METHOD as st, DID_CONNECT_MEDIUM_WIDTH as F, LOGIN_PROVIDER_NAME as it, DID_CONNECT_SMALL_WIDTH as ct, OAUTH_PROVIDER as j, LOGIN_PROVIDER as at } from "@arcblock/ux/lib/Util/constant";
10
+ import lt from "@arcblock/ux/lib/QRCode";
11
+ import { DIDConnectFooter as ut } from "@arcblock/ux/lib/DIDConnect";
12
+ import { useTheme as dt } from "@arcblock/ux/lib/Theme";
13
+ import ft from "@arcblock/ux/lib/DIDConnect/provider-icon";
14
14
  import "@fontsource/lexend/400.css";
15
15
  import "@fontsource/lexend/600.css";
16
- import { SessionContext as lt } from "../Session/context.js";
17
- import { StateProvider as ut, useStateContext as dt } from "./contexts/state.js";
18
- import ft from "./components/login-item/connect-provider-list.js";
19
- import mt from "./components/auto-height.js";
20
- import pt from "./hooks/token.js";
21
- import { useOAuth as ht } from "../OAuth/context.js";
22
- import bt from "./components/connect-status.js";
23
- import { usePasskey as gt } from "../Passkey/context.js";
24
- import { CHECK_STATUS_INTERVAL as xt, API_DID_PREFIX as Ct, BUSY_STATUS as w, DEFAULT_TIMEOUT as yt } from "../constant.js";
16
+ import { SessionContext as mt } from "../Session/context.js";
17
+ import { StateProvider as pt, useStateContext as ht } from "./contexts/state.js";
18
+ import gt from "./components/login-item/connect-provider-list.js";
19
+ import bt from "./components/auto-height.js";
20
+ import xt from "./hooks/token.js";
21
+ import { useOAuth as Ct } from "../OAuth/context.js";
22
+ import St from "./components/connect-status.js";
23
+ import { usePasskey as wt } from "../Passkey/context.js";
24
+ import { CHECK_STATUS_INTERVAL as yt, API_DID_PREFIX as kt, BUSY_STATUS as I, DEFAULT_TIMEOUT as It } from "../constant.js";
25
25
  import "../utils.js";
26
- import St from "./components/did-connect-title.js";
27
- import kt from "./components/download-tips.js";
28
- import wt from "./hooks/provider-list.js";
29
- import It from "./hooks/auth-url.js";
26
+ import _t from "./components/did-connect-title.js";
27
+ import Tt from "./components/download-tips.js";
28
+ import Dt from "./hooks/provider-list.js";
29
+ import Ot from "./hooks/auth-url.js";
30
30
  import { getWalletDid as vt } from "../User/use-did.js";
31
31
  import Pt from "./fallback-connect.js";
32
- import { getWebWalletUrl as _t } from "@arcblock/ux/lib/Util/wallet";
32
+ import { getWebWalletUrl as Rt } from "@arcblock/ux/lib/Util/wallet";
33
33
  function de({
34
34
  hideCloseButton: y = !1,
35
- mode: p = "dialog",
36
- action: I,
37
- baseUrl: g = "",
38
- checkFn: v,
39
- checkInterval: P = xt,
40
- checkTimeout: _ = yt * 1e3,
41
- prefix: D = Ct,
35
+ mode: h = "dialog",
36
+ action: _,
37
+ baseUrl: x = "",
38
+ checkFn: T,
39
+ checkInterval: D = yt,
40
+ checkTimeout: O = It * 1e3,
41
+ prefix: v = kt,
42
42
  tokenKey: B = "_t_",
43
43
  locale: q = "en",
44
44
  encKey: fe = "_ek_",
@@ -47,45 +47,48 @@ function de({
47
47
  saveConnect: pe = !0,
48
48
  useSocket: he = !0,
49
49
  allowWallet: V = !0,
50
- provider: be = "",
51
- messages: d = {},
52
- passkeyBehavior: Y = "none",
53
- webWalletUrl: ge = _t(),
50
+ provider: ge = "",
51
+ messages: f = {},
52
+ passkeyBehavior: G = "none",
53
+ webWalletUrl: be = Rt(),
54
54
  enabledConnectTypes: xe = ["web", "mobile", ...Object.keys(j)],
55
- extraContent: G = null,
56
- disableSwitchApp: T = !1,
55
+ extraContent: Y = null,
56
+ disableSwitchApp: P = !1,
57
57
  magicToken: K = void 0,
58
58
  customItems: Ce = [],
59
- onClose: O = C,
60
- onError: Q = C,
61
- onSuccess: R = C,
62
- onRecreateSession: X = C,
63
- setColor: ye = C
59
+ onClose: R = w,
60
+ onError: Q = w,
61
+ onSuccess: A = w,
62
+ onRecreateSession: Se = w,
63
+ setColor: we = w
64
64
  }) {
65
- const A = at(), J = Qe(), Se = Ve(lt), ke = vt(Se?.session?.user), {
66
- t: Z,
67
- staticState: we,
68
- connectState: s,
69
- extraParams: Ie,
70
- currentAppInfo: ve,
71
- currentAppColor: W,
65
+ const W = dt(), X = Je(), ye = Ye(mt), ke = vt(ye?.session?.user), {
66
+ t: J,
67
+ staticState: Ie,
68
+ connectState: n,
69
+ extraParams: _e,
70
+ currentAppInfo: Te,
71
+ currentAppColor: E,
72
72
  // 插件相关
73
- selectedPlugin: a,
74
- blocklet: $,
75
- masterBlocklet: Pe,
76
- showWalletOptions: f,
77
- setShowWalletOptions: _e,
78
- lastLoginMethod: De
79
- } = dt(), { state: o, generate: ee, cancelWhenScanned: Te } = pt({
80
- action: I,
81
- baseUrl: g,
82
- checkFn: v,
83
- checkInterval: P,
84
- checkTimeout: _,
85
- extraParams: Ie,
86
- prefix: D,
73
+ selectedPlugin: c,
74
+ blocklet: Z,
75
+ masterBlocklet: De,
76
+ showWalletOptions: m,
77
+ setShowWalletOptions: Oe,
78
+ lastLoginMethod: ve
79
+ } = ht(), Pe = S((...g) => {
80
+ const u = n.walletMethod || nt.SCAN;
81
+ return localStorage.setItem(st, u), A(...g);
82
+ }), { state: o, generate: $, cancelWhenScanned: Re } = xt({
83
+ action: _,
84
+ baseUrl: x,
85
+ checkFn: T,
86
+ checkInterval: D,
87
+ checkTimeout: O,
88
+ extraParams: _e,
89
+ prefix: v,
87
90
  onError: Q,
88
- onSuccess: R,
91
+ onSuccess: Pe,
89
92
  locale: q,
90
93
  tokenKey: B,
91
94
  encKey: fe,
@@ -93,117 +96,119 @@ function de({
93
96
  forceConnected: H === !0 ? ke || !0 : H,
94
97
  saveConnect: pe,
95
98
  useSocket: he,
96
- provider: be
97
- }), z = ce(!1), te = ce(null), x = Xe(te), oe = u(() => x ? x.width < N - 50 : !0, [x, x?.width]), [re, Oe] = Ye(!1);
99
+ provider: ge
100
+ }), L = ae(!1), ee = ae(null), C = Ze(ee), te = d(() => C ? C.width < F - 50 : !0, [C, C?.width]), [oe, Ae] = Ke(!1);
98
101
  ue(() => {
99
- Oe(x?.width < N - 50);
102
+ Ae(C?.width < F - 50);
100
103
  });
101
- const { oauthState: c, setBaseUrl: Re } = ht(), { passkeyState: l, setTargetAppPid: Ae } = gt();
104
+ const { oauthState: a, setBaseUrl: We } = Ct(), { passkeyState: l, setTargetAppPid: Ee } = wt();
102
105
  ue(() => {
103
- Re(g), Ae($?.appPid), o.reset(), c.reset(), l.reset();
106
+ We(x), Ee(Z?.appPid), o.reset(), a.reset(), l.reset();
104
107
  }), le(() => {
105
- ye(W);
106
- }, [W]);
107
- const We = u(() => ({
108
- confirm: d.confirm,
109
- success: d.success,
110
- error: a?.state?.error || o.error || l.error || c.error || ""
108
+ we(E);
109
+ }, [E]);
110
+ const Le = d(() => ({
111
+ confirm: f.confirm,
112
+ success: f.success,
113
+ error: c?.state?.error || o.error || l.error || a.error || ""
111
114
  }), [
112
- d.confirm,
113
- d.success,
115
+ f.confirm,
116
+ f.success,
114
117
  o.error,
115
- c.error,
118
+ a.error,
116
119
  l.error,
117
- a?.state?.error
118
- ]), S = u(() => w.includes(l.status) || w.includes(c.status) || w.includes(o.status) || w.includes(a?.state?.computedStatus), [o.status, c.status, l.status, a?.state?.computedStatus]), ne = F(async () => {
119
- X(), c.reset(), l.reset(), await ee(!1);
120
- }), ze = F(() => {
121
- s?.retryConnect();
122
- }), Ee = F(() => {
123
- X(), c.reset(), l.reset(), a?.state?.reset(), we.current.cancelCount++, Te();
124
- }), { run: Le } = Je(
120
+ c?.state?.error
121
+ ]), k = d(() => I.includes(l.status) || I.includes(a.status) || I.includes(o.status) || I.includes(c?.state?.computedStatus), [o.status, a.status, l.status, c?.state?.computedStatus]), re = S(() => {
122
+ n.chooseMethod = "wallet", n.walletMethod = "", Se();
123
+ }), ne = S(async () => {
124
+ re(), a.reset(), l.reset(), await $(!1);
125
+ }), Me = S(() => {
126
+ n?.retryConnect();
127
+ }), ze = S(() => {
128
+ re(), a.reset(), l.reset(), c?.state?.reset(), Ie.current.cancelCount++, Re();
129
+ }), { run: Ne } = $e(
125
130
  () => {
126
- z.current || o.status === "timeout" && (z.current = !0, o.reset(), ne(), z.current = !1);
131
+ L.current || o.status === "timeout" && (L.current = !0, o.reset(), ne(), L.current = !1);
127
132
  },
128
133
  { leading: !0, trailing: !1 }
129
134
  );
130
- le(Le, [o.status]);
131
- const Me = u(() => ot[s.chooseMethod] || "DID Wallet", [s.chooseMethod]), { providerList: Ue, hideQRCode: m, hideChooseList: r, loadingProviderList: Fe } = wt({
135
+ le(Ne, [o.status]);
136
+ const Ue = d(() => it[n.chooseMethod] || "DID Wallet", [n.chooseMethod]), { providerList: Fe, hideQRCode: p, hideChooseList: r, loadingProviderList: je } = Dt({
132
137
  action: o.action,
133
- sourceAppPid: s?.sourceAppPid,
138
+ sourceAppPid: n?.sourceAppPid,
134
139
  allowWallet: V,
135
- passkeyBehavior: Y,
136
- mode: p,
137
- blocklet: s?.sourceAppPid ? Pe : $,
138
- isSmallView: oe,
139
- lastLoginMethod: De
140
- }), Ne = Ze(s?.sourceAppPid);
141
- $e(() => {
142
- et(Ne) || ee();
143
- }, [s?.sourceAppPid]);
144
- const n = (k) => {
145
- const h = A.spacing(k);
146
- return parseInt(h, 10);
147
- }, je = u(() => y ? null : /* @__PURE__ */ t(
148
- tt,
140
+ passkeyBehavior: G,
141
+ mode: h,
142
+ blocklet: n?.sourceAppPid ? De : Z,
143
+ isSmallView: te,
144
+ lastLoginMethod: ve
145
+ }), Be = et(n?.sourceAppPid);
146
+ tt(() => {
147
+ ot(Be) || $();
148
+ }, [n?.sourceAppPid]);
149
+ const s = (g) => {
150
+ const u = W.spacing(g);
151
+ return parseInt(u, 10);
152
+ }, qe = d(() => y ? null : /* @__PURE__ */ t(
153
+ rt,
149
154
  {
150
- onClose: O,
155
+ onClose: R,
151
156
  sx: {
152
157
  position: "absolute",
153
158
  right: 14,
154
159
  top: 14
155
160
  }
156
161
  }
157
- ), [y, O]), Be = /* @__PURE__ */ t(
162
+ ), [y, R]), He = /* @__PURE__ */ t(
158
163
  i,
159
164
  {
160
165
  sx: {
161
166
  flex: 1,
162
- display: S ? "flex" : "none",
167
+ display: k ? "flex" : "none",
163
168
  alignItems: "center",
164
169
  justifyContent: "center"
165
170
  },
166
171
  children: /* @__PURE__ */ t(i, { children: /* @__PURE__ */ t(
167
- bt,
172
+ St,
168
173
  {
169
- status: a?.state?.computedStatus || c.status || l.status || o.status,
174
+ status: c?.state?.computedStatus || a.status || l.status || o.status,
170
175
  nextWorkflow: o.nextWorkflow,
171
176
  mfaCode: o.mfaCode,
172
- onCancel: Ee,
173
- onRetry: ze,
174
- onClose: O,
175
- messages: We,
177
+ onCancel: ze,
178
+ onRetry: Me,
179
+ onClose: R,
180
+ messages: Le,
176
181
  locale: q,
177
182
  className: "did-connect__auth-status auth-status",
178
- loadingIcon: s.chooseMethod ? /* @__PURE__ */ t(ct, { provider: s.chooseMethod, sx: { color: "text.primary" } }) : null,
179
- chooseMethod: Me,
180
- hideRetry: s.chooseMethod === "email",
183
+ loadingIcon: n.chooseMethod ? /* @__PURE__ */ t(ft, { provider: n.chooseMethod, sx: { color: "text.primary" } }) : null,
184
+ chooseMethod: Ue,
185
+ hideRetry: n.chooseMethod === "email",
181
186
  hideBack: !!K
182
187
  }
183
188
  ) })
184
189
  }
185
- ), ie = It({ disableSwitchApp: T, tokenState: o }), E = u(() => {
186
- const k = A.mode === "dark" ? A.palette.grey[600] : "white";
187
- let h = r ? 240 - n(3) * 2 : 196 - n(2) * 2, U = r ? 3 : 2;
188
- return f && (U = 1, h += n(U) * 2), /* @__PURE__ */ t(
190
+ ), se = Ot({ disableSwitchApp: P, tokenState: o }), M = d(() => {
191
+ const g = W.mode === "dark" ? W.palette.grey[600] : "white";
192
+ let u = r ? 240 - s(3) * 2 : 196 - s(2) * 2, U = r ? 3 : 2;
193
+ return m && (U = 1, u += s(U) * 2), /* @__PURE__ */ t(
189
194
  i,
190
195
  {
191
196
  className: "did-connect__qrcode",
192
197
  sx: {
193
198
  p: U,
194
- width: (r ? 240 : 196) + n(1) * 2,
195
- height: (r ? 240 : 196) + n(1) * 2
199
+ width: (r ? 240 : 196) + s(1) * 2,
200
+ height: (r ? 240 : 196) + s(1) * 2
196
201
  },
197
202
  children: o.url ? /* @__PURE__ */ t(
198
- it,
203
+ lt,
199
204
  {
200
- data: ie,
201
- size: h,
205
+ data: se,
206
+ size: u,
202
207
  sx: {
203
- width: h + n(1) * 2,
204
- height: h + n(1) * 2,
208
+ width: u + s(1) * 2,
209
+ height: u + s(1) * 2,
205
210
  flex: 1,
206
- backgroundColor: k,
211
+ backgroundColor: g,
207
212
  p: 1,
208
213
  fontSize: 0,
209
214
  textAlign: "center",
@@ -214,21 +219,21 @@ function de({
214
219
  },
215
220
  config: {
216
221
  backgroundOptions: {
217
- color: k
222
+ color: g
218
223
  }
219
224
  }
220
225
  }
221
226
  ) : /* @__PURE__ */ t(
222
- Ge,
227
+ Qe,
223
228
  {
224
229
  animation: "wave",
225
230
  variant: "rectangular",
226
231
  sx: {
227
232
  position: "absolute",
228
- left: n(2) + 1,
229
- right: n(2) + 1,
230
- top: n(2) + 1,
231
- bottom: n(2) + 1,
233
+ left: s(2) + 1,
234
+ right: s(2) + 1,
235
+ top: s(2) + 1,
236
+ bottom: s(2) + 1,
232
237
  borderRadius: 1,
233
238
  zIndex: 1,
234
239
  width: "auto",
@@ -238,7 +243,7 @@ function de({
238
243
  )
239
244
  }
240
245
  );
241
- }, [ie, r, f]), qe = u(() => r ? "column-reverse" : !m && re ? "column" : "row", [r, re, m]), se = u(() => E ? /* @__PURE__ */ t(
246
+ }, [se, r, m]), Ve = d(() => r ? "column-reverse" : !p && oe ? "column" : "row", [r, oe, p]), ie = d(() => M ? /* @__PURE__ */ t(
242
247
  i,
243
248
  {
244
249
  sx: {
@@ -255,7 +260,7 @@ function de({
255
260
  sx: {
256
261
  fontSize: 0,
257
262
  position: "relative",
258
- ...f ? {
263
+ ...m ? {
259
264
  mt: r ? 4 : 2.5,
260
265
  mb: 0
261
266
  } : {
@@ -264,7 +269,7 @@ function de({
264
269
  }
265
270
  },
266
271
  children: [
267
- E,
272
+ M,
268
273
  /* @__PURE__ */ b(
269
274
  i,
270
275
  {
@@ -274,7 +279,7 @@ function de({
274
279
  fontSize: 12,
275
280
  zIndex: 1,
276
281
  whiteSpace: "nowrap",
277
- ...f ? {
282
+ ...m ? {
278
283
  top: r ? -8 : -4,
279
284
  transform: "translateY(-100%)"
280
285
  } : {
@@ -286,11 +291,11 @@ function de({
286
291
  textAlign: "center"
287
292
  },
288
293
  children: [
289
- Z("scanWithWallet1"),
294
+ J("scanWithWallet1"),
290
295
  " ",
291
- /* @__PURE__ */ t(kt, {}),
296
+ /* @__PURE__ */ t(Tt, {}),
292
297
  " ",
293
- Z("scanWithWallet2")
298
+ J("scanWithWallet2")
294
299
  ]
295
300
  }
296
301
  )
@@ -298,25 +303,25 @@ function de({
298
303
  }
299
304
  )
300
305
  }
301
- ) : null, [E, r, f]), L = /* @__PURE__ */ b(
306
+ ) : null, [M, r, m]), z = /* @__PURE__ */ b(
302
307
  i,
303
308
  {
304
309
  className: "did-connect__body",
305
310
  sx: {
306
311
  display: "flex",
307
- flexDirection: qe,
312
+ flexDirection: Ve,
308
313
  justifyContent: "center",
309
314
  alignItems: "stretch",
310
315
  flex: 1,
311
- gap: !m && oe ? 0 : 1.5,
316
+ gap: !p && te ? 0 : 1.5,
312
317
  overflow: "visible",
313
318
  px: r ? 2 : 0
314
319
  },
315
320
  children: [
316
- !S && !m ? /* @__PURE__ */ b(He, { children: [
317
- se,
321
+ !k && !p ? /* @__PURE__ */ b(Ge, { children: [
322
+ ie,
318
323
  r ? null : /* @__PURE__ */ t(i, { children: /* @__PURE__ */ t(
319
- Ke,
324
+ Xe,
320
325
  {
321
326
  orientation: "vertical",
322
327
  sx: {
@@ -338,34 +343,34 @@ function de({
338
343
  flex: 1
339
344
  },
340
345
  children: [
341
- Be,
346
+ He,
342
347
  /* @__PURE__ */ t(
343
- ft,
348
+ gt,
344
349
  {
345
350
  slotProps: {
346
351
  root: {
347
- sx: [S ? { display: "none" } : {}]
352
+ sx: [k ? { display: "none" } : {}]
348
353
  }
349
354
  },
350
355
  allowWallet: V,
351
- size: m && p !== "dialog" ? "normal" : "small",
356
+ size: p && h !== "dialog" ? "normal" : "small",
352
357
  tokenState: o,
353
- hideQRCode: m,
354
- messages: d,
358
+ hideQRCode: p,
359
+ messages: f,
355
360
  tokenKey: B,
356
- onSuccess: R,
357
- passkeyBehavior: Y,
358
- webWalletUrl: ge,
359
- extraContent: G,
361
+ onSuccess: A,
362
+ passkeyBehavior: G,
363
+ webWalletUrl: be,
364
+ extraContent: Y,
360
365
  enabledConnectTypes: xe,
361
366
  onReset: ne,
362
- disableSwitchApp: T,
363
- forceUpdate: J,
367
+ disableSwitchApp: P,
368
+ forceUpdate: X,
364
369
  magicToken: K,
365
- baseUrl: g,
370
+ baseUrl: x,
366
371
  customItems: Ce,
367
- providerList: Ue,
368
- qrcode: se
372
+ providerList: Fe,
373
+ qrcode: ie
369
374
  }
370
375
  )
371
376
  ]
@@ -374,18 +379,18 @@ function de({
374
379
  ]
375
380
  }
376
381
  );
377
- let M = L;
378
- a ? M = a.renderPlaceholder({
379
- fallback: L,
380
- forceUpdate: J,
381
- onSuccess: R,
382
+ let N = z;
383
+ c ? N = c.renderPlaceholder({
384
+ fallback: z,
385
+ forceUpdate: X,
386
+ onSuccess: A,
382
387
  onError: Q
383
- }) : M = L;
384
- const ae = m || S ? rt : N;
385
- return Fe ? /* @__PURE__ */ t(Pt, {}) : /* @__PURE__ */ b(
388
+ }) : N = z;
389
+ const ce = p || k ? ct : F;
390
+ return je ? /* @__PURE__ */ t(Pt, {}) : /* @__PURE__ */ b(
386
391
  i,
387
392
  {
388
- ref: te,
393
+ ref: ee,
389
394
  className: "did-connect__root",
390
395
  sx: {
391
396
  backgroundColor: "background.default",
@@ -396,7 +401,7 @@ function de({
396
401
  maxWidth: "100%",
397
402
  width: (
398
403
  // eslint-disable-next-line no-nested-ternary
399
- p === "drawer" ? "100%" : f ? ae - 20 : ae
404
+ h === "drawer" ? "100%" : m ? ce - 20 : ce
400
405
  ),
401
406
  transition: "width 0.2s ease-in-out",
402
407
  margin: "auto",
@@ -407,19 +412,19 @@ function de({
407
412
  children: [
408
413
  /* @__PURE__ */ t(i, { "data-did-auth-url": o.url, sx: { display: "none" } }),
409
414
  /* @__PURE__ */ t(
410
- St,
415
+ _t,
411
416
  {
412
- title: d.title,
413
- description: d.scan,
414
- extraContent: G,
415
- disableSwitchApp: T,
416
- showWalletOptions: f,
417
- onBack: () => _e(!1)
417
+ title: f.title,
418
+ description: f.scan,
419
+ extraContent: Y,
420
+ disableSwitchApp: P,
421
+ showWalletOptions: m,
422
+ onBack: () => Oe(!1)
418
423
  }
419
424
  ),
420
- /* @__PURE__ */ t(mt, { initHeight: 72, children: M }),
421
- /* @__PURE__ */ t(st, { currentAppInfo: ve, currentAppColor: W }),
422
- je
425
+ /* @__PURE__ */ t(bt, { initHeight: 72, children: N }),
426
+ /* @__PURE__ */ t(ut, { currentAppInfo: Te, currentAppColor: E }),
427
+ qe
423
428
  ]
424
429
  }
425
430
  );
@@ -446,7 +451,7 @@ de.propTypes = {
446
451
  enabledConnectTypes: e.arrayOf(e.oneOf(["web", "mobile", ...Object.keys(j)])),
447
452
  webWalletUrl: e.string,
448
453
  allowWallet: e.bool,
449
- provider: e.oneOf([nt.WALLET, ...Object.keys(j), ""]),
454
+ provider: e.oneOf([at.WALLET, ...Object.keys(j), ""]),
450
455
  hideCloseButton: e.bool,
451
456
  disableSwitchApp: e.bool,
452
457
  onClose: e.func,
@@ -457,18 +462,18 @@ de.propTypes = {
457
462
  magicToken: e.string,
458
463
  customItems: e.arrayOf(e.node)
459
464
  };
460
- function Dt({ testOnlyBorderColor: y = void 0, ...p }) {
461
- const { checkFn: I, extraParams: g = {}, blocklet: v, masterBlocklet: P, action: _, locale: D = "en" } = p;
462
- if (typeof I != "function")
465
+ function At({ testOnlyBorderColor: y = void 0, ...h }) {
466
+ const { checkFn: _, extraParams: x = {}, blocklet: T, masterBlocklet: D, action: O, locale: v = "en" } = h;
467
+ if (typeof _ != "function")
463
468
  throw new Error("Cannot initialize did connect component without a fetchFn");
464
469
  return /* @__PURE__ */ t(
465
- ut,
470
+ pt,
466
471
  {
467
- blocklet: v,
468
- masterBlocklet: P,
469
- action: _,
470
- locale: D,
471
- extraParams: g,
472
+ blocklet: T,
473
+ masterBlocklet: D,
474
+ action: O,
475
+ locale: v,
476
+ extraParams: x,
472
477
  testOnlyBorderColor: y,
473
478
  sx: {
474
479
  position: "relative",
@@ -482,11 +487,11 @@ function Dt({ testOnlyBorderColor: y = void 0, ...p }) {
482
487
  boxSizing: "border-box"
483
488
  }
484
489
  },
485
- children: /* @__PURE__ */ t(de, { ...p })
490
+ children: /* @__PURE__ */ t(de, { ...h })
486
491
  }
487
492
  );
488
493
  }
489
- Dt.propTypes = {
494
+ At.propTypes = {
490
495
  checkFn: e.func.isRequired,
491
496
  extraParams: e.object,
492
497
  blocklet: e.object.isRequired,
@@ -496,5 +501,5 @@ Dt.propTypes = {
496
501
  testOnlyBorderColor: e.string
497
502
  };
498
503
  export {
499
- Dt as default
504
+ At as default
500
505
  };