| OLD | NEW |
| (Empty) |
| 1 Polymer('paper-menu-button-overlay-container');; | |
| 2 | |
| 3 Polymer('paper-menu-button', { | |
| 4 | |
| 5 publish: { | |
| 6 | |
| 7 /** | |
| 8 * If true, this menu is currently visible. | |
| 9 * | |
| 10 * @attribute opened | |
| 11 * @type boolean | |
| 12 * @default false | |
| 13 */ | |
| 14 opened: { value: false, reflect: true }, | |
| 15 | |
| 16 /** | |
| 17 * The horizontal alignment of the pulldown menu relative to the button. | |
| 18 * | |
| 19 * @attribute halign | |
| 20 * @type 'left' | 'right' | |
| 21 * @default 'left' | |
| 22 */ | |
| 23 halign: { value: 'left', reflect: true }, | |
| 24 | |
| 25 /** | |
| 26 * The vertical alignment of the pulldown menu relative to the button. | |
| 27 * | |
| 28 * @attribute valign | |
| 29 * @type 'bottom' | 'top' | |
| 30 * @default 'top' | |
| 31 */ | |
| 32 valign: {value: 'top', reflect: true} | |
| 33 }, | |
| 34 | |
| 35 /** | |
| 36 * The URL of an image for the icon. Should not use `icon` property | |
| 37 * if you are using this property. | |
| 38 * | |
| 39 * @attribute src | |
| 40 * @type string | |
| 41 * @default '' | |
| 42 */ | |
| 43 src: '', | |
| 44 | |
| 45 /** | |
| 46 * Specifies the icon name or index in the set of icons available in | |
| 47 * the icon set. Should not use `src` property if you are using this | |
| 48 * property. | |
| 49 * | |
| 50 * @attribute icon | |
| 51 * @type string | |
| 52 * @default '' | |
| 53 */ | |
| 54 icon: '', | |
| 55 | |
| 56 slow: false, | |
| 57 | |
| 58 tapAction: function() { | |
| 59 if (this.disabled) { | |
| 60 return; | |
| 61 } | |
| 62 | |
| 63 this.super(); | |
| 64 this.toggle(); | |
| 65 }, | |
| 66 | |
| 67 /** | |
| 68 * Toggle the opened state of the menu. | |
| 69 * | |
| 70 * @method toggle | |
| 71 */ | |
| 72 toggle: function() { | |
| 73 this.opened = !this.opened; | |
| 74 } | |
| 75 | |
| 76 }); | |
| 77 | |
| OLD | NEW |