Skip to content

Commit 8ffd25a

Browse files
author
Dharmik79
committed
added the tag for the svg to avoid showing the detailed information for the wallet
1 parent c382229 commit 8ffd25a

File tree

1 file changed

+9
-10
lines changed
  • src/components/FindWallet/WalletTable

1 file changed

+9
-10
lines changed

src/components/FindWallet/WalletTable/index.tsx

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -309,15 +309,9 @@ const WalletTable = ({
309309
sliceSize
310310
)
311311

312-
const showMoreInfo = (wallet, event) => {
312+
const showMoreInfo = (wallet) => {
313313
// Prevent expanding the wallet more info section when clicking on the "Visit website" button
314-
let classList = event?.target?.classList
315-
if (
316-
Object.values(classList)?.includes("chakra-button") ||
317-
Object.values(classList)?.includes("css-1bbj57d")
318-
) {
319-
return
320-
}
314+
321315
updateMoreInfo(wallet.key)
322316
// Log "more info" event only on expanding
323317
wallet.moreInfo &&
@@ -336,10 +330,15 @@ const WalletTable = ({
336330
<Wallet
337331
// Make wallets more info section open on 'Enter'
338332
onKeyUp={(e) => {
339-
if (e.key === "Enter") showMoreInfo(wallet, e)
333+
if (e.key === "Enter") showMoreInfo(wallet)
340334
}}
341335
onClick={(e) => {
342-
showMoreInfo(wallet, e)
336+
if (
337+
(e.target as HTMLTableRowElement).tagName === "A" ||
338+
(e.target as HTMLTableRowElement).tagName === "svg"
339+
)
340+
return
341+
showMoreInfo(wallet)
343342
}}
344343
>
345344
<Td lineHeight="revert">

0 commit comments

Comments
 (0)