ember-cli-mdc-menu-surface
v3.0.17
Published
ember-cli addon for @material/menu-surface.
Downloads
290
Maintainers
Readme
ember-cli-mdc-menu-surface
ember-cli addon for @material/menu-surface
.
Installation
ember install ember-cli-mdc-menu-surface
Components and Mixins
Components
Modifiers
MdcMenuSurface
Description
Add a menu surface component to the page.
Usage
<MdcMenuSurface @open=[true|false]
@quickOpen=[true|false]
@anchor=[HTMLElement|string]
@anchorMargin=[number]
@anchorCorner=[string]
@position=["fixed"|"absolute"]
@left=number
@top=number />
Attributes
open
- Trigger the surface to openquickOpen
- Enable quick openanchor
- Optional anchor point for the menu surfaceanchorMargin
- Margin between the menu surface and anchoranchorCorner
- Corner of achor element to affix menu surfaceposition
- Either "fixed" or "absolute"left
- Left position of the menu (works only in absolute mode)top
- Top position of the menu (works only in absolute mode)
mdc-menu-surface-anchor
Description
The {{mdc-menu-surface-anchor}}
modifier defines the anchor element for a menu.
Usage
<div class="toolbar" {{mdc-menu-surface-anchor}}>
<button {{on "click" this.toggleMenu}}>Open Menu</button>
<MdcMenuSurface @open={{this.openMenu}}>
<!-- -->
</MdcMenuSurface>
</div>