calintat / minimal

Personal blog theme powered by Hugo
https://themes.gohugo.io/minimal/
MIT License
404 stars 222 forks source link

Update Navbar to handle Hugo Children #101

Open Lnaden opened 4 years ago

Lnaden commented 4 years ago

This enables the header's Navbar to take advantage of the Hugo config.* files' menu.menu child/parent relations. I added a simple static carat for the dropdowns as well since this is using bootstrap 3. As I understand, bootstrap 4 adds the carat automatically, not really sure though.

The appearance of the dropdown menu isn't great, but I don't know CSS really, so I'm not sure how to clean this up. Feel free to make suggestions or edit yourself if you want.

This may fall outside of the scope of what this repo's vision is for minimal, but I wanted to propose it anyways so it ha the option to use more Hugo features.

Lnaden commented 4 years ago

I made a change which makes the menu actually look correctly now by making it a ul instead of a div class. The items now correctly list in a vertical stack as well.

yli110-stat697 commented 1 year ago

Hi @Lnaden and @calintat This is exactly something I was looking for! And I just copied @Lnaden 's code to have my own header.html and I got what I wanted! Thank you!!