VilloKodeHode / mega-collab-modul-s

https://mega-collab-modul-s-u9ph.vercel.app
5 stars 0 forks source link

Missing links for navigation #64

Closed kristofferfh closed 1 month ago

kristofferfh commented 1 month ago

I propose updating our menuItems.js file with more structure so that we can use it for a dropdown/hamburger menu. At the same time we can update the file with missing links for the newest pages that has been created.

[
  {
    title: "Home",
    href: "/"
  },{
    title: "Pages",
    children: [
      { title: "Inna", href: "/inna" },
      ...
      { title: "warning", href: "/warning" }
    ]
  },{
    title: "About",
    href: "/"
  },{
    title: "Contact",
    href: "/"
  }
]

Collaborators can then add their own sub categories by simply adding menu to their own tag as show below.

{
  title: "warning",
  href: "/warning",
  children: [
    { title: "Menu 1", href: "/menu1" },
    { title: "Menu 2", href: "/menu2" },
    { title: "Menu 3", href: "/menu3" }
  ]
}
kristofferfh commented 1 month ago

Current changes can be found in https://github.com/VilloKodeHode/mega-collab-modul-s/commit/6d236042facedabaacd079f2367f9c4b23033a45

kristofferfh commented 1 month ago

With these changes we need to change the structure of our components/header/molecule/Navbar.jsx component. I'm opening a new issue #68 so that we can work on updating the component if we want to continue with this new json structure.