Skip to content

Commit

Permalink
Feat/wc modal (#2213)
Browse files Browse the repository at this point in the history
  • Loading branch information
foodaka authored Oct 14, 2024
1 parent 3e89d74 commit 30d0a63
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"@visx/shape": "^2.12.2",
"@visx/tooltip": "^2.16.0",
"@walletconnect/ethereum-provider": "^2.13.3",
"@walletconnect/modal": "^2.6.2",
"@walletconnect/modal": "2.7.0",
"@web3-react/abstract-connector": "^6.0.7",
"@web3-react/core": "^6.1.9",
"@web3-react/frame-connector": "^6.0.9",
Expand Down
2 changes: 1 addition & 1 deletion src/components/WalletConnection/WalletModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const WalletModal = () => {
const { isWalletModalOpen, setWalletModalOpen } = useWalletModalContext();

return (
<BasicModal open={isWalletModalOpen} setOpen={setWalletModalOpen}>
<BasicModal disableEnforceFocus={true} open={isWalletModalOpen} setOpen={setWalletModalOpen}>
<WalletSelector />
</BasicModal>
);
Expand Down
3 changes: 3 additions & 0 deletions src/components/primitives/BasicModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export interface BasicModalProps {
setOpen: (value: boolean) => void;
withCloseButton?: boolean;
contentMaxWidth?: number;
disableEnforceFocus?: boolean;
}

export const BasicModal = ({
Expand All @@ -16,6 +17,7 @@ export const BasicModal = ({
withCloseButton = true,
contentMaxWidth = 420,
children,
disableEnforceFocus,
...props
}: BasicModalProps) => {
const handleClose = () => setOpen(false);
Expand All @@ -24,6 +26,7 @@ export const BasicModal = ({
<Modal
open={open}
onClose={handleClose}
disableEnforceFocus={disableEnforceFocus} // Used for wallet modal connection
sx={{
display: 'flex',
flexDirection: 'column',
Expand Down
27 changes: 26 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4576,6 +4576,13 @@
dependencies:
valtio "1.11.2"

"@walletconnect/[email protected]":
version "2.7.0"
resolved "https://registry.yarnpkg.com/@walletconnect/modal-core/-/modal-core-2.7.0.tgz#73c13c3b7b0abf9ccdbac9b242254a86327ce0a4"
integrity sha512-oyMIfdlNdpyKF2kTJowTixZSo0PGlCJRdssUN/EZdA6H6v03hZnf09JnwpljZNfir2M65Dvjm/15nGrDQnlxSA==
dependencies:
valtio "1.11.2"

"@walletconnect/[email protected]":
version "2.6.2"
resolved "https://registry.yarnpkg.com/@walletconnect/modal-ui/-/modal-ui-2.6.2.tgz#fa57c087c57b7f76aaae93deab0f84bb68b59cf9"
Expand All @@ -4586,14 +4593,32 @@
motion "10.16.2"
qrcode "1.5.3"

"@walletconnect/[email protected]", "@walletconnect/modal@^2.6.2":
"@walletconnect/[email protected]":
version "2.7.0"
resolved "https://registry.yarnpkg.com/@walletconnect/modal-ui/-/modal-ui-2.7.0.tgz#dbbb7ee46a5a25f7d39db622706f2d197b268cbb"
integrity sha512-gERYvU7D7K1ANCN/8vUgsE0d2hnRemfAFZ2novm9aZBg7TEd/4EgB+AqbJ+1dc7GhOL6dazckVq78TgccHb7mQ==
dependencies:
"@walletconnect/modal-core" "2.7.0"
lit "2.8.0"
motion "10.16.2"
qrcode "1.5.3"

"@walletconnect/[email protected]":
version "2.6.2"
resolved "https://registry.yarnpkg.com/@walletconnect/modal/-/modal-2.6.2.tgz#4b534a836f5039eeb3268b80be7217a94dd12651"
integrity sha512-eFopgKi8AjKf/0U4SemvcYw9zlLpx9njVN8sf6DAkowC2Md0gPU/UNEbH1Wwj407pEKnEds98pKWib1NN1ACoA==
dependencies:
"@walletconnect/modal-core" "2.6.2"
"@walletconnect/modal-ui" "2.6.2"

"@walletconnect/[email protected]":
version "2.7.0"
resolved "https://registry.yarnpkg.com/@walletconnect/modal/-/modal-2.7.0.tgz#55f969796d104cce1205f5f844d8f8438b79723a"
integrity sha512-RQVt58oJ+rwqnPcIvRFeMGKuXb9qkgSmwz4noF8JZGUym3gUAzVs+uW2NQ1Owm9XOJAV+sANrtJ+VoVq1ftElw==
dependencies:
"@walletconnect/modal-core" "2.7.0"
"@walletconnect/modal-ui" "2.7.0"

"@walletconnect/[email protected]":
version "1.0.10"
resolved "https://registry.yarnpkg.com/@walletconnect/relay-api/-/relay-api-1.0.10.tgz#5aef3cd07c21582b968136179aa75849dcc65499"
Expand Down

2 comments on commit 30d0a63

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit was deployed on ipfs

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit was deployed on ipfs

Please sign in to comment.