Skip to content

Commit

Permalink
disable account verification menu when all addresses are verified
Browse files Browse the repository at this point in the history
  • Loading branch information
dhia-gharsallaoui committed Aug 20, 2024
1 parent ddf94f3 commit de557ae
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/pkg/ui.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ export const navigationMenu = ({
return link
})

const accountVerified = !session?.identity?.verifiable_addresses?.some(address => !address.verified)

return Nav({
className: "main-nav",
navTitle: navTitle,
Expand Down Expand Up @@ -84,7 +86,7 @@ export const navigationMenu = ({
href: "verification",
iconLeft: "user-check",
iconRight: "up-right-from-square",
disabled: false,
disabled: accountVerified,
testId: "verification",
target: "_blank",
},
Expand Down

0 comments on commit de557ae

Please sign in to comment.