From 7ed78a34ce8efac9d3f39fc1e1c56e47720c97d6 Mon Sep 17 00:00:00 2001 From: Michael Bond Date: Mon, 4 Nov 2024 10:46:54 -0500 Subject: [PATCH] Hide badges for undocumented games Reference #59 and #60 --- .../MainTabPages/BadgesComponent.razor | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/Pkmds.Web/Components/MainTabPages/BadgesComponent.razor b/Pkmds.Web/Components/MainTabPages/BadgesComponent.razor index 8c17e196..00deab47 100644 --- a/Pkmds.Web/Components/MainTabPages/BadgesComponent.razor +++ b/Pkmds.Web/Components/MainTabPages/BadgesComponent.razor @@ -1,13 +1,17 @@ @inherits BasePkmdsComponent -@{ - var badges = GetSaveFileBadgesValue(); +@if (AppState.SaveFile is SAV7b { Context: EntityContext.Gen7b } or SAV9SV { Context: EntityContext.Gen9 }) +{ } -@for (var i = 0; i < badges.Count; i++) +else { - var badgeIndex = i; - + var badges = GetSaveFileBadgesValue(); + @for (var i = 0; i < badges.Count; i++) + { + var badgeIndex = i; + + } }