Switch global error menu icon to vectorized MD asset
[chromium-blink-merge.git] / third_party / polymer / v1_0 / components-chromium / paper-behaviors / paper-button-behavior-extracted.js
blob91386dee7893d859ffe0c24f4e9fdff1964fa1a4
1 /** @polymerBehavior */
2 Polymer.PaperButtonBehaviorImpl = {
4 properties: {
6 _elevation: {
7 type: Number
12 observers: [
13 '_calculateElevation(focused, disabled, active, pressed, receivedFocusFromKeyboard)'
16 hostAttributes: {
17 role: 'button',
18 tabindex: '0'
21 _calculateElevation: function() {
22 var e = 1;
23 if (this.disabled) {
24 e = 0;
25 } else if (this.active || this.pressed) {
26 e = 4;
27 } else if (this.receivedFocusFromKeyboard) {
28 e = 3;
30 this._elevation = e;
34 /** @polymerBehavior */
35 Polymer.PaperButtonBehavior = [
36 Polymer.IronButtonState,
37 Polymer.IronControlState,
38 Polymer.PaperButtonBehaviorImpl