Module: elements-sk/nav-button-sk

nav-button-sk

Allows for the creation of a pop-up menu. The actual menu is contained in a sibling element.

nav-button-sk is just a convenience that contains the hamburger menu and toggles the shown property of a sibling 'nav-links-sk'. Other types of popup menus can be created using buttons and icons directly. The children of 'nav-links-sk' do not have to be links, they could be other elements, such as buttons.

Source:
Example
// Using nav-button-sk:
<nav-button-sk></nav-button-sk>
<nav-links-sk shown>
  <a href="">Main</a>
  <a href="">Triage</a>
  <a href="">Alerts</a>
</nav-links-sk>

// Using a button instead of nav-button-sk:
<button onclick="this.nextElementSibling.shown = true;">
  <create-icon-sk></create-icon-sk>
</button>
<nav-links-sk>
  <a href="">New A</a>
  <a href="">New B</a>
  <a href="">New C</a>
</nav-links-sk>

Documentation generated by JSDoc 3.5.5 on Wed Oct 10 2018 16:13:40 GMT-0400 (EDT)