ComboStrap UI - Menu bar
Table of Contents
About
A menubar is an horizontal navigational bar with links and dropdown menu that should be used in the page header.
Inside a menu component, you can add:
- a group to group navigational element such as a dropdown menu
- a collapse container to group the element that will collapse
- a button
Syntax
<menubar breakpoint="lg" position="normal" align="left" theme="light">
where:
- breakpoint is one of the breakpoint code (xs,'sm, md, lg (Default), xl) when the menu bar will collapse.
- position is one of normal (default), top (bottom is not yet supported)
- align defines the horizontal placement. Possible values: left(Default) or center
- theme defines the luminance of the text. You can specify light (default) or dark
The default background-color is a light background.
Example
A menubar with two dropdown menu and the search box at the right
- The start of the menubar.
<menubar breakpoint="sm">
<brand class="pt-0" title="Brand">
<icon name="desktop-mac-dashboard" /> Brandly
</brand>
- Collapse to indicate all elements that will collapse when the size of the screen is lower than the menubar breakpoint
<collapse>
- A group with expand=“true” to push the element that are not in the group at the right side of the page
<group expand="true">
- Two dropdown menu
<dropdown name="Call to Action" >
[[card|Card]]
[[button|Button]]
</dropdown>
<dropdown name="UI Box">
[[note|Note]]
[[card|Card]]
[[blockquote|Blockquote]]
</dropdown>
- The end of the group
</group>
- The search bar
<search/>
- The end of the element to collapse (ie we collapse all drop down and the search bar
</collapse>
</menubar>
- Output
A dark menubar
<menubar theme="dark" background-color="dark" breakpoint="xs">
<brand title="ComboStrap Home">
<icon name="logo.svg" />
ComboStrap
</brand>
<collapse>
<group>
[[#|Home]]
[[#|Features]]
[[#|Release]]
Menubar text with an inline element
</group>
</collapse>
</menubar>