Skip to content

Commit

Permalink
updated menu navigation to check the initial url
Browse files Browse the repository at this point in the history
  • Loading branch information
Ciphrox committed Mar 1, 2025
1 parent abcc187 commit d5cc50c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/layouts/Navigation.astro
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const DefaultIcon = ({ text }: { text: string }) => {
.map((p) => {
const gradientUrl = `url(#gradient-${p.name ?? p.title})`;
return (
<li class={`nav--list__item ${currentPath === p.path ? "active" : ""}`}>
<li class={`nav--list__item ${currentPath.split("/")[1] === p.path.split("/")[1] ? "active" : ""}`}>
<a href={p.path}>
<span class="iconx">
{p.icon ? (
Expand Down

0 comments on commit d5cc50c

Please sign in to comment.