fix: navbar selected link

This commit is contained in:
TrèsAbhi committed 2024-09-23 10:19:11 -05:00
1 parent a54ba78dbf
commit 53c0f48437
4 files changed
+10 -11

No files matched your search

+3 -4
View File
@@ -142,10 +142,9 @@ const isBranchNamed =
(branch) =>
branch !== assertSecret(import.meta.env.PUBLIC_ASSET_BRANCH),
);
// const selected = window.location.pathname.startsWith(
// `/tools/${tool.id}`,
// );
const selected = false;
const selected = Astro.url.pathname.startsWith(
`/tools/${tool.id}`,
);
if (unavailableOnBranch) return null;