0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-16 12:32:39 +00:00

HeaderList now in nav > ul > li

This commit is contained in:
G.Ambatte
2025-01-06 23:20:52 +13:00
parent cf16566da8
commit 06005009e4
2 changed files with 23 additions and 19 deletions

View File

@@ -45,9 +45,11 @@ const HeaderNav = React.forwardRef(({}, pagesRef)=>{
}; };
return <div className='headerNav'> return <nav className='headerNav'>
<ul>
{renderHeaderLinks()} {renderHeaderLinks()}
</div>; </ul>
</nav>;
} }
); );
@@ -61,11 +63,11 @@ const HeaderNavItem = ({ link, text, depth, className })=>{
return text.trim(); return text.trim();
}; };
return <p> return <li>
<a href={`#${link}`} target='_self' className={className}> <a href={`#${link}`} target='_self' className={className}>
<span style={{ display: 'inline-block', width: `${depth * 0.5}em` }}></span>{trimString(text, depth)} <span style={{ display: 'inline-block', width: `${depth * 0.5}em` }}></span>{trimString(text, depth)}
</a> </a>
</p>; </li>;
}; };
export default HeaderNav; export default HeaderNav;

View File

@@ -1,6 +1,6 @@
.headerNav { .headerNav {
position: fixed; position: fixed;
top: 30px; top: 32px;
left: 0px; left: 0px;
padding: 5px 10px; padding: 5px 10px;
background-color: #ccc; background-color: #ccc;
@@ -17,6 +17,8 @@
.navIcon { .navIcon {
cursor: pointer; cursor: pointer;
} }
li {
list-style-type: none;
a { a {
font-family: 'Open Sans'; font-family: 'Open Sans';
font-size: 12px; font-size: 12px;
@@ -30,6 +32,6 @@
&.pageLink { &.pageLink {
font-weight: 900; font-weight: 900;
} }
}
} }
} }