Hi,
When we create a reactive web app, there is a header at top of any page, which contains logo and navigation links. I can see that it's present under UI Flows > Common, in the interface.
1) Is it possible to completely remove this default header and create one from scratch?
The vertical/sidenav is only shown on smaller screens, while on larger screens the horizontal menu is shown, I want the vertical nav on all screen sizes.
2) I can target it through css media queries but is there any built in way to hide the horizontal menu and show the sidenav menu on all screen sizes?
3) Is there any way to dynamically generate the nav/menu by fetching the items/links from database?
4) How can I create multilevel(dropdown style) nav menu?
Please note that I prefer not to use any 3rd party component from forge.
Thanks.
Hi
1) The default application template contains various Layouts. You can inspect them in the Layout UI Flow.
A setting on the application theme tells OutSystems which Layout to use as default whenever you create a new screen.
You can, however, change the layout any time by removing it and adding another one. Layouts are just Blocks and can be used in the Widget tree just like any other block. You can also completely remove a layout from a screen, and you can create your own Layouts (always remember that Layouts are just Blocks and can be used accordingly).
2) You can start with the LayoutSideMenu and modify it to suit your needs.
3) Sure. You can modify the existing Menu block. Add an Aggregate to fetch your menu entries and use the List Widget to dynamically populate the links.
4) You can use the Submenu Widget to create dropdown style menu items.
"I prefer not to use any 3rd party component from forge" -> Then don't do :-) Even if you do not use them, they are a clever way to learn how to do things. Sure, not all of them are good or even have decent quality, but they can be a useful source for your own implementation.
Best
Stefan
1) In the layout you can choose which web block to have in the header. You can modify the Menu web block or just replace it with another one.
2) I'm not exactly sure I understood this one, but if you want a side menu, you can use the "LayoutSideMenu" as the layout for you screens. You can choose this in your theme:
3) Yes, you can fetch data from the database and use a list of links to dynamically generate these items.
4) The OutSystems UI has the Submenu widget that should do the trick.
Let me know if this helps,
Pedro