@reown/appkit-cdn 0.0.3 → 0.0.5

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.
Files changed (37) hide show
  1. package/dist/{W3MFrameProviderSingleton-BpWUndnw.cjs → W3MFrameProviderSingleton-DqZPnx6B.cjs} +83 -83
  2. package/dist/{W3MFrameProviderSingleton-CuVI_88U.js → W3MFrameProviderSingleton-zbQ4ONFs.js} +1598 -1553
  3. package/dist/ethers.cjs +1 -1
  4. package/dist/ethers.js +3034 -2938
  5. package/dist/{hooks.module-C2zxEs4Z.js → hooks.module-DyR4RIBB.js} +1 -1
  6. package/dist/{hooks.module-BmccViTi.cjs → hooks.module-i4FRb7XO.cjs} +1 -1
  7. package/dist/{index-qHZ88Aei.cjs → index-Bn8aTBEA.cjs} +1 -1
  8. package/dist/{index-DIBheNE_.js → index-CEUqb47P.js} +43 -43
  9. package/dist/{index--u0BBJui.js → index-COp74Nlv.js} +10 -10
  10. package/dist/{index-B5dlb2GK.cjs → index-CZ0JZE3-.cjs} +1 -1
  11. package/dist/{index-CjczsdX0.js → index-CZTNKbSO.js} +2 -2
  12. package/dist/{index-CytFwM4F.cjs → index-Dfn2LY62.cjs} +1 -1
  13. package/dist/index-DoLWLaij.cjs +64 -0
  14. package/dist/{index-_fb0kPJf.js → index-DxEKvu_F.js} +1 -1
  15. package/dist/{index-DoNvH4sY.cjs → index-DxUwf3RH.cjs} +1 -1
  16. package/dist/{index-DxKsnlAL.cjs → index-FG_60MTM.cjs} +1 -1
  17. package/dist/{index-BGcCLdgU.js → index-KQ0ug1oF.js} +2 -2
  18. package/dist/{index-DTZ3zFoi.js → index-Obv6EKFg.js} +2 -2
  19. package/dist/{index-CEbNT_sk.cjs → index-UcSnSk_O.cjs} +1 -1
  20. package/dist/{index-BzzLy8QO.js → index-eRHpwmcb.js} +36 -36
  21. package/dist/{index-Cbfs_-YJ.js → index-ghwtTzEg.js} +5 -5
  22. package/dist/{index-e2XnZub2.cjs → index-mgWAnOON.cjs} +1 -1
  23. package/dist/{index.es-Dzy36BN7.js → index.es-BGqGHUjM.js} +249 -249
  24. package/dist/{index.es-wptiKBWB.cjs → index.es-D9jJiMUr.cjs} +2 -2
  25. package/dist/{metamask-sdk-vSsaK2qA.js → metamask-sdk-DvRJGKsF.js} +1 -1
  26. package/dist/{metamask-sdk-CH4ak2WC.cjs → metamask-sdk-h3UYWtaU.cjs} +1 -1
  27. package/dist/{native-DUnMHCku.cjs → native-DMERvs7m.cjs} +1 -1
  28. package/dist/{native-DZv9b0EL.js → native-Da5kImuF.js} +1 -1
  29. package/dist/{w3m-modal-Cb8iN1Y9.js → w3m-modal-5wuX5WJr.js} +55 -73
  30. package/dist/w3m-modal-CFTtpDDX.cjs +149 -0
  31. package/dist/{wagmi-Dnkdlm7T.js → wagmi-DrOzbDZW.js} +3914 -3796
  32. package/dist/{wagmi-Cz2I9r-O.cjs → wagmi-DwngeQQv.cjs} +14 -14
  33. package/dist/wagmi.cjs +1 -1
  34. package/dist/wagmi.js +2 -2
  35. package/package.json +5 -5
  36. package/dist/index-BgSdiVHK.cjs +0 -64
  37. package/dist/w3m-modal-pgEnMCmq.cjs +0 -149
@@ -1,5 +1,5 @@
1
- import { q as g, u as v, M as n, m as d, y as m, O as p, b5 as y, x as C, v as k, R as h, U as S, K as E, z as A, a as f, f as x, c as N, w as c, t as O, b6 as L } from "./W3MFrameProviderSingleton-CuVI_88U.js";
2
- const K = g`
1
+ import { u as v, w as y, M as n, g as h, O as f, b6 as C, o as m, z as k, x as S, R as c, U as x, L as A, D as E, a as b, c as O, y as w, v as N, b7 as L } from "./W3MFrameProviderSingleton-zbQ4ONFs.js";
2
+ const K = v`
3
3
  :host {
4
4
  z-index: var(--w3m-z-index);
5
5
  display: block;
@@ -124,25 +124,25 @@ const K = g`
124
124
  }
125
125
  }
126
126
  `;
127
- var l = function(w, e, t, i) {
128
- var o = arguments.length, s = o < 3 ? e : i === null ? i = Object.getOwnPropertyDescriptor(e, t) : i, r;
127
+ var d = function(u, e, t, i) {
128
+ var o = arguments.length, s = o < 3 ? e : i === null ? i = Object.getOwnPropertyDescriptor(e, t) : i, a;
129
129
  if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
130
- s = Reflect.decorate(w, e, t, i);
130
+ s = Reflect.decorate(u, e, t, i);
131
131
  else
132
- for (var u = w.length - 1; u >= 0; u--)
133
- (r = w[u]) && (s = (o < 3 ? r(s) : o > 3 ? r(e, t, s) : r(e, t)) || s);
132
+ for (var l = u.length - 1; l >= 0; l--)
133
+ (a = u[l]) && (s = (o < 3 ? a(s) : o > 3 ? a(e, t, s) : a(e, t)) || s);
134
134
  return o > 3 && s && Object.defineProperty(e, t, s), s;
135
135
  };
136
- const b = "scroll-lock";
137
- let a = class extends v {
136
+ const g = "scroll-lock";
137
+ let r = class extends y {
138
138
  constructor() {
139
- super(), this.unsubscribe = [], this.abortController = void 0, this.open = n.state.open, this.caipAddress = d.state.caipAddress, this.caipNetwork = m.state.caipNetwork, this.isSiweEnabled = p.state.isSiweEnabled, this.connected = d.state.isConnected, this.loading = n.state.loading, this.shake = n.state.shake, this.initializeTheming(), y.prefetch(), this.unsubscribe.push(n.subscribeKey("open", (e) => e ? this.onOpen() : this.onClose()), n.subscribeKey("shake", (e) => this.shake = e), n.subscribeKey("loading", (e) => this.onLoadingChange(e)), d.subscribeKey("isConnected", (e) => this.onIsConnectedChange(e)), m.subscribeKey("caipNetwork", (e) => this.onNewNetwork(e)), d.subscribeKey("caipAddress", (e) => this.onNewAddress(e)), d.subscribeKey("siweStatus", (e) => this.onSiweStatusChange(e)), p.subscribeKey("isSiweEnabled", (e) => this.isSiweEnabled = e)), C.sendEvent({ type: "track", event: "MODAL_LOADED" });
139
+ super(), this.unsubscribe = [], this.abortController = void 0, this.open = n.state.open, this.caipAddress = h.state.activeCaipAddress, this.caipNetwork = h.state.activeCaipNetwork, this.isSiweEnabled = f.state.isSiweEnabled, this.shake = n.state.shake, this.initializeTheming(), C.prefetch(), this.unsubscribe.push(n.subscribeKey("open", (e) => e ? this.onOpen() : this.onClose()), n.subscribeKey("shake", (e) => this.shake = e), m.subscribeKey("siweStatus", (e) => this.onSiweStatusChange(e), "eip155"), h.subscribeKey("activeCaipNetwork", (e) => this.onNewNetwork(e)), h.subscribeKey("activeCaipAddress", (e) => this.onNewAddress(e)), f.subscribeKey("isSiweEnabled", (e) => this.isSiweEnabled = e)), k.sendEvent({ type: "track", event: "MODAL_LOADED" });
140
140
  }
141
141
  disconnectedCallback() {
142
142
  this.unsubscribe.forEach((e) => e()), this.onRemoveKeyboardListener();
143
143
  }
144
144
  render() {
145
- return this.open ? k`
145
+ return this.open ? S`
146
146
  <wui-flex @click=${this.onOverlayClick.bind(this)} data-testid="w3m-modal-overlay">
147
147
  <wui-card
148
148
  shake="${this.shake}"
@@ -163,26 +163,26 @@ let a = class extends v {
163
163
  e.target === e.currentTarget && await this.handleClose();
164
164
  }
165
165
  async handleClose() {
166
- const e = h.state.view === "ConnectingSiwe", t = h.state.view === "ApproveTransaction";
166
+ const e = c.state.view === "ConnectingSiwe", t = c.state.view === "ApproveTransaction";
167
167
  if (this.isSiweEnabled) {
168
- const { SIWEController: i } = await import("./index-DIBheNE_.js");
168
+ const { SIWEController: i } = await import("./index-CEUqb47P.js");
169
169
  i.state.status !== "success" && (e || t) ? n.shake() : n.close();
170
170
  } else
171
171
  n.close();
172
172
  }
173
173
  initializeTheming() {
174
- const { themeVariables: e, themeMode: t } = L.state, i = S.getColorTheme(t);
175
- E(e, i);
174
+ const { themeVariables: e, themeMode: t } = L.state, i = x.getColorTheme(t);
175
+ A(e, i);
176
176
  }
177
177
  onClose() {
178
- this.open = !1, this.classList.remove("open"), this.onScrollUnlock(), A.hide(), this.onRemoveKeyboardListener();
178
+ this.open = !1, this.classList.remove("open"), this.onScrollUnlock(), E.hide(), this.onRemoveKeyboardListener();
179
179
  }
180
180
  onOpen() {
181
181
  this.open = !0, this.classList.add("open"), this.onScrollLock(), this.onAddKeyboardListener();
182
182
  }
183
183
  onScrollLock() {
184
184
  const e = document.createElement("style");
185
- e.dataset.w3m = b, e.textContent = `
185
+ e.dataset.w3m = g, e.textContent = `
186
186
  body {
187
187
  touch-action: none;
188
188
  overflow: hidden;
@@ -194,7 +194,7 @@ let a = class extends v {
194
194
  `, document.head.appendChild(e);
195
195
  }
196
196
  onScrollUnlock() {
197
- const e = document.head.querySelector(`style[data-w3m="${b}"]`);
197
+ const e = document.head.querySelector(`style[data-w3m="${g}"]`);
198
198
  e && e.remove();
199
199
  }
200
200
  onAddKeyboardListener() {
@@ -214,77 +214,59 @@ let a = class extends v {
214
214
  var e;
215
215
  (e = this.abortController) == null || e.abort(), this.abortController = void 0;
216
216
  }
217
- async onNewAddress(e) {
218
- var o;
219
- if (!this.connected || this.loading)
220
- return;
221
- const t = f.getPlainAddress(this.caipAddress), i = f.getPlainAddress(e);
222
- if (this.caipAddress = e, this.isSiweEnabled) {
223
- const { SIWEController: s } = await import("./index-DIBheNE_.js");
224
- await s.getSession() && t && i && t !== i && (o = s.state._client) != null && o.options.signOutOnAccountChange && (await s.signOut(), this.onSiweNavigation());
225
- }
226
- }
227
- async onIsConnectedChange(e) {
228
- const t = this.connected;
229
- if (e && this.isSiweEnabled) {
230
- const { SIWEController: i } = await import("./index-DIBheNE_.js");
231
- await i.getSession() || this.onSiweNavigation();
232
- } else
233
- !t && e && (n.close(), h.reset("Connect"));
234
- this.connected = e;
235
- }
236
217
  onSiweStatusChange(e) {
237
218
  e === "success" && n.close();
238
219
  }
239
- onLoadingChange(e) {
240
- this.loading = e;
220
+ async onNewAddress(e) {
221
+ var o;
222
+ const t = this.caipAddress ? b.getPlainAddress(this.caipAddress) : void 0, i = e ? b.getPlainAddress(e) : void 0;
223
+ if (this.isSiweEnabled) {
224
+ const { SIWEController: s } = await import("./index-CEUqb47P.js"), a = m.state.siweStatus === "success";
225
+ !t && i ? this.onSiweNavigation() : a && t && i && t !== i && (o = s.state._client) != null && o.options.signOutOnAccountChange && (await s.signOut(), this.onSiweNavigation());
226
+ }
227
+ this.caipAddress = e;
241
228
  }
242
229
  async onNewNetwork(e) {
243
- var o, s;
244
- if (!this.connected) {
230
+ var o, s, a, l;
231
+ if (!this.caipAddress) {
245
232
  this.caipNetwork = e;
246
233
  return;
247
234
  }
248
- const t = (o = this.caipNetwork) == null ? void 0 : o.id, i = e == null ? void 0 : e.id;
235
+ const t = (s = (o = this.caipNetwork) == null ? void 0 : o.id) == null ? void 0 : s.toString(), i = (a = e == null ? void 0 : e.id) == null ? void 0 : a.toString();
249
236
  if (t && i && t !== i)
250
237
  if (this.isSiweEnabled) {
251
- const { SIWEController: r } = await import("./index-DIBheNE_.js");
252
- await r.getSession() && (s = r.state._client) != null && s.options.signOutOnNetworkChange && (await r.signOut(), this.onSiweNavigation());
238
+ const { SIWEController: p } = await import("./index-CEUqb47P.js");
239
+ (l = p.state._client) != null && l.options.signOutOnNetworkChange ? (await p.signOut(), this.onSiweNavigation()) : c.goBack();
253
240
  } else
254
- h.goBack();
241
+ c.goBack();
255
242
  this.caipNetwork = e;
256
243
  }
257
244
  onSiweNavigation() {
258
- x.state.activeChain === N.CHAIN.EVM && (this.open ? h.replace("ConnectingSiwe") : n.open({
245
+ const e = h.state.activeChain === O.CHAIN.EVM;
246
+ !(m.state.siweStatus === "success") && e ? this.open ? c.replace("ConnectingSiwe") : n.open({
259
247
  view: "ConnectingSiwe"
260
- }));
248
+ }) : c.goBack();
261
249
  }
262
250
  };
263
- a.styles = K;
264
- l([
265
- c()
266
- ], a.prototype, "open", void 0);
267
- l([
268
- c()
269
- ], a.prototype, "caipAddress", void 0);
270
- l([
271
- c()
272
- ], a.prototype, "caipNetwork", void 0);
273
- l([
274
- c()
275
- ], a.prototype, "isSiweEnabled", void 0);
276
- l([
277
- c()
278
- ], a.prototype, "connected", void 0);
279
- l([
280
- c()
281
- ], a.prototype, "loading", void 0);
282
- l([
283
- c()
284
- ], a.prototype, "shake", void 0);
285
- a = l([
286
- O("w3m-modal")
287
- ], a);
251
+ r.styles = K;
252
+ d([
253
+ w()
254
+ ], r.prototype, "open", void 0);
255
+ d([
256
+ w()
257
+ ], r.prototype, "caipAddress", void 0);
258
+ d([
259
+ w()
260
+ ], r.prototype, "caipNetwork", void 0);
261
+ d([
262
+ w()
263
+ ], r.prototype, "isSiweEnabled", void 0);
264
+ d([
265
+ w()
266
+ ], r.prototype, "shake", void 0);
267
+ r = d([
268
+ N("w3m-modal")
269
+ ], r);
288
270
  export {
289
- a as W3mModal
271
+ r as W3mModal
290
272
  };
@@ -0,0 +1,149 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./W3MFrameProviderSingleton-DqZPnx6B.cjs"),u=t.i`
2
+ :host {
3
+ z-index: var(--w3m-z-index);
4
+ display: block;
5
+ backface-visibility: hidden;
6
+ will-change: opacity;
7
+ position: fixed;
8
+ top: 0;
9
+ left: 0;
10
+ right: 0;
11
+ bottom: 0;
12
+ pointer-events: none;
13
+ opacity: 0;
14
+ background-color: var(--wui-cover);
15
+ transition: opacity 0.2s var(--wui-ease-out-power-2);
16
+ will-change: opacity;
17
+ }
18
+
19
+ :host(.open) {
20
+ opacity: 1;
21
+ }
22
+
23
+ wui-card {
24
+ max-width: var(--w3m-modal-width);
25
+ width: 100%;
26
+ position: relative;
27
+ animation: zoom-in 0.2s var(--wui-ease-out-power-2);
28
+ animation-fill-mode: backwards;
29
+ outline: none;
30
+ }
31
+
32
+ wui-card[shake='true'] {
33
+ animation:
34
+ zoom-in 0.2s var(--wui-ease-out-power-2),
35
+ w3m-shake 0.5s var(--wui-ease-out-power-2);
36
+ }
37
+
38
+ wui-flex {
39
+ overflow-x: hidden;
40
+ overflow-y: auto;
41
+ display: flex;
42
+ align-items: center;
43
+ justify-content: center;
44
+ width: 100%;
45
+ height: 100%;
46
+ }
47
+
48
+ @media (max-height: 700px) and (min-width: 431px) {
49
+ wui-flex {
50
+ align-items: flex-start;
51
+ }
52
+
53
+ wui-card {
54
+ margin: var(--wui-spacing-xxl) 0px;
55
+ }
56
+ }
57
+
58
+ @media (max-width: 430px) {
59
+ wui-flex {
60
+ align-items: flex-end;
61
+ }
62
+
63
+ wui-card {
64
+ max-width: 100%;
65
+ border-bottom-left-radius: 0;
66
+ border-bottom-right-radius: 0;
67
+ border-bottom: none;
68
+ animation: slide-in 0.2s var(--wui-ease-out-power-2);
69
+ }
70
+
71
+ wui-card[shake='true'] {
72
+ animation:
73
+ slide-in 0.2s var(--wui-ease-out-power-2),
74
+ w3m-shake 0.5s var(--wui-ease-out-power-2);
75
+ }
76
+ }
77
+
78
+ @keyframes zoom-in {
79
+ 0% {
80
+ transform: scale(0.95) translateY(0);
81
+ }
82
+ 100% {
83
+ transform: scale(1) translateY(0);
84
+ }
85
+ }
86
+
87
+ @keyframes slide-in {
88
+ 0% {
89
+ transform: scale(1) translateY(50px);
90
+ }
91
+ 100% {
92
+ transform: scale(1) translateY(0);
93
+ }
94
+ }
95
+
96
+ @keyframes w3m-shake {
97
+ 0% {
98
+ transform: scale(1) rotate(0deg);
99
+ }
100
+ 20% {
101
+ transform: scale(1) rotate(-1deg);
102
+ }
103
+ 40% {
104
+ transform: scale(1) rotate(1.5deg);
105
+ }
106
+ 60% {
107
+ transform: scale(1) rotate(-1.5deg);
108
+ }
109
+ 80% {
110
+ transform: scale(1) rotate(1deg);
111
+ }
112
+ 100% {
113
+ transform: scale(1) rotate(0deg);
114
+ }
115
+ }
116
+
117
+ @keyframes w3m-view-height {
118
+ from {
119
+ height: var(--prev-height);
120
+ }
121
+ to {
122
+ height: var(--new-height);
123
+ }
124
+ }
125
+ `;var l=function(d,e,o,i){var s=arguments.length,n=s<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,o):i,r;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")n=Reflect.decorate(d,e,o,i);else for(var a=d.length-1;a>=0;a--)(r=d[a])&&(n=(s<3?r(n):s>3?r(e,o,n):r(e,o))||n);return s>3&&n&&Object.defineProperty(e,o,n),n};const h="scroll-lock";exports.W3mModal=class extends t.h{constructor(){super(),this.unsubscribe=[],this.abortController=void 0,this.open=t.ModalController.state.open,this.caipAddress=t.ChainController.state.activeCaipAddress,this.caipNetwork=t.ChainController.state.activeCaipNetwork,this.isSiweEnabled=t.OptionsController.state.isSiweEnabled,this.shake=t.ModalController.state.shake,this.initializeTheming(),t.ApiController.prefetch(),this.unsubscribe.push(t.ModalController.subscribeKey("open",e=>e?this.onOpen():this.onClose()),t.ModalController.subscribeKey("shake",e=>this.shake=e),t.AccountController.subscribeKey("siweStatus",e=>this.onSiweStatusChange(e),"eip155"),t.ChainController.subscribeKey("activeCaipNetwork",e=>this.onNewNetwork(e)),t.ChainController.subscribeKey("activeCaipAddress",e=>this.onNewAddress(e)),t.OptionsController.subscribeKey("isSiweEnabled",e=>this.isSiweEnabled=e)),t.EventsController.sendEvent({type:"track",event:"MODAL_LOADED"})}disconnectedCallback(){this.unsubscribe.forEach(e=>e()),this.onRemoveKeyboardListener()}render(){return this.open?t.ke`
126
+ <wui-flex @click=${this.onOverlayClick.bind(this)} data-testid="w3m-modal-overlay">
127
+ <wui-card
128
+ shake="${this.shake}"
129
+ role="alertdialog"
130
+ aria-modal="true"
131
+ tabindex="0"
132
+ data-testid="w3m-modal-card"
133
+ >
134
+ <w3m-header></w3m-header>
135
+ <w3m-router></w3m-router>
136
+ <w3m-snackbar></w3m-snackbar>
137
+ </wui-card>
138
+ </wui-flex>
139
+ <w3m-tooltip></w3m-tooltip>
140
+ `:null}async onOverlayClick(e){e.target===e.currentTarget&&await this.handleClose()}async handleClose(){const e=t.RouterController.state.view==="ConnectingSiwe",o=t.RouterController.state.view==="ApproveTransaction";if(this.isSiweEnabled){const{SIWEController:i}=await Promise.resolve().then(()=>require("./index-DoLWLaij.cjs"));i.state.status!=="success"&&(e||o)?t.ModalController.shake():t.ModalController.close()}else t.ModalController.close()}initializeTheming(){const{themeVariables:e,themeMode:o}=t.ThemeController.state,i=t.UiHelperUtil.getColorTheme(o);t.initializeTheming(e,i)}onClose(){this.open=!1,this.classList.remove("open"),this.onScrollUnlock(),t.SnackController.hide(),this.onRemoveKeyboardListener()}onOpen(){this.open=!0,this.classList.add("open"),this.onScrollLock(),this.onAddKeyboardListener()}onScrollLock(){const e=document.createElement("style");e.dataset.w3m=h,e.textContent=`
141
+ body {
142
+ touch-action: none;
143
+ overflow: hidden;
144
+ overscroll-behavior: contain;
145
+ }
146
+ w3m-modal {
147
+ pointer-events: auto;
148
+ }
149
+ `,document.head.appendChild(e)}onScrollUnlock(){const e=document.head.querySelector(`style[data-w3m="${h}"]`);e&&e.remove()}onAddKeyboardListener(){var o;this.abortController=new AbortController;const e=(o=this.shadowRoot)==null?void 0:o.querySelector("wui-card");e==null||e.focus(),window.addEventListener("keydown",i=>{if(i.key==="Escape")this.handleClose();else if(i.key==="Tab"){const{tagName:s}=i.target;s&&!s.includes("W3M-")&&!s.includes("WUI-")&&(e==null||e.focus())}},this.abortController)}onRemoveKeyboardListener(){var e;(e=this.abortController)==null||e.abort(),this.abortController=void 0}onSiweStatusChange(e){e==="success"&&t.ModalController.close()}async onNewAddress(e){var s;const o=this.caipAddress?t.CoreHelperUtil.getPlainAddress(this.caipAddress):void 0,i=e?t.CoreHelperUtil.getPlainAddress(e):void 0;if(this.isSiweEnabled){const{SIWEController:n}=await Promise.resolve().then(()=>require("./index-DoLWLaij.cjs")),r=t.AccountController.state.siweStatus==="success";!o&&i?this.onSiweNavigation():r&&o&&i&&o!==i&&(s=n.state._client)!=null&&s.options.signOutOnAccountChange&&(await n.signOut(),this.onSiweNavigation())}this.caipAddress=e}async onNewNetwork(e){var s,n,r,a;if(!this.caipAddress){this.caipNetwork=e;return}const o=(n=(s=this.caipNetwork)==null?void 0:s.id)==null?void 0:n.toString(),i=(r=e==null?void 0:e.id)==null?void 0:r.toString();if(o&&i&&o!==i)if(this.isSiweEnabled){const{SIWEController:c}=await Promise.resolve().then(()=>require("./index-DoLWLaij.cjs"));(a=c.state._client)!=null&&a.options.signOutOnNetworkChange?(await c.signOut(),this.onSiweNavigation()):t.RouterController.goBack()}else t.RouterController.goBack();this.caipNetwork=e}onSiweNavigation(){const e=t.ChainController.state.activeChain===t.ConstantsUtil$1.CHAIN.EVM;!(t.AccountController.state.siweStatus==="success")&&e?this.open?t.RouterController.replace("ConnectingSiwe"):t.ModalController.open({view:"ConnectingSiwe"}):t.RouterController.goBack()}};exports.W3mModal.styles=u;l([t.r()],exports.W3mModal.prototype,"open",void 0);l([t.r()],exports.W3mModal.prototype,"caipAddress",void 0);l([t.r()],exports.W3mModal.prototype,"caipNetwork",void 0);l([t.r()],exports.W3mModal.prototype,"isSiweEnabled",void 0);l([t.r()],exports.W3mModal.prototype,"shake",void 0);exports.W3mModal=l([t.customElement("w3m-modal")],exports.W3mModal);