Skip to content
This repository was archived by the owner on Oct 6, 2020. It is now read-only.

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Md2Menu

Menu is a list of options that displays when triggered.

[md2-menu]

Directives

Name Description
md2-menu Menu directive
md2-menu-trigger Trigger event on to toggle menu using the directive
md2-menu-content Display menu content using the directive
md2-menu-item Display list of item using the directive

Attributes

Attributes Value Description
x-position `before after`
y-position `above below`

Examples

A menu would have the following markup.

<div md2-menu>
  <button md2-menu-trigger>Right Menu <span class="caret"></span></button>
  <div md2-menu-content x-position="before">
    <a md2-menu-item>Badman</a>
    <a md2-menu-item>Sadman</a>
    <a md2-menu-item>Lieman</a>
    <div md2-menu-item>
      <button md2-menu-trigger>2nd Level Menu <span class="caret"></span></button>
      <div md2-menu-content>
        <a md2-menu-item>Badman</a>
        <a md2-menu-item>Sadman</a>
        <a md2-menu-item>Lieman</a>
      </div>
    </div>
  </div>
</div>