Skip to content

Commit

Permalink
Merge branch 'refs/heads/feat/argent-one-button-connector' into beta
Browse files Browse the repository at this point in the history
  • Loading branch information
Cussone committed Nov 8, 2024
2 parents 1f59f8d + 093f637 commit d93a9f5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,11 @@ export const connect = async ({
modal.$destroy()
}
} catch (error) {
modal.$set({ layout: Layout.failure })
if (
[Layout.connecting, Layout.qrCode].includes(modal.getLayout())
) {
modal.$set({ layout: Layout.failure })
}
reject(error)
}
},
Expand Down
1 change: 1 addition & 0 deletions src/modal/Modal.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ interface ModalProps {
interface ModalInstance extends SvelteComponent {
$set(props: Partial<ModalProps>): void
$destroy(): void
getLayout: () => Layout
}
3 changes: 3 additions & 0 deletions src/modal/Modal.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
function setLayout(newLayout: Layout): void {
layout = newLayout
}
export function getLayout() {
return layout
}
export let modalWallets: ModalWallet[] = []
export let selectedWallet: ModalWallet | null = null
Expand Down

0 comments on commit d93a9f5

Please sign in to comment.