From de557ae2f6a33dff7e19a51d618c9438a4996ac1 Mon Sep 17 00:00:00 2001 From: Dhia Gharsallaoui Date: Tue, 20 Aug 2024 11:18:53 +0200 Subject: [PATCH] disable account verification menu when all addresses are verified --- src/pkg/ui.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pkg/ui.ts b/src/pkg/ui.ts index 51d59d43..90584eb3 100644 --- a/src/pkg/ui.ts +++ b/src/pkg/ui.ts @@ -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, @@ -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", },