paper-dropdown-menu
paper-dropdown-menu copied to clipboard
paper-dropdown-menu could expose property ignoreSelect from paper-menu-button
The way it's currently implemented, there is no way of keeping the dropdown menu from closing when you deselect an item.
Example:
<dom-module id="my-component">
<template>
<paper-dropdown-menu id="dropdownMenu">
<iron-selector id="selector" class="dropdown-content" multi>
<paper-checkbox checked>foo</paper-checkbox>
<paper-checkbox checked>bar</paper-checkbox>
<paper-checkbox checked>foo bar</paper-checkbox>
</iron-selector>
</paper-dropdown-menu>
</template>
</dom-module>
The dropdown closes when any checkbox is closed. The following workaround keeps the issue from happening, but it's not very elegant:
ready: function() {
this.$.dropdownMenu.$.menuButton.ignoreSelect = true;
}
you can try this
ready: function() {
this.$.dropdownMenu.ignoreSelect = true;
}
it is a little shorter
SGTM
+1