summaryrefslogtreecommitdiffstats
path: root/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error-extracted.js
blob: 4cea279fc190f7c021694eb52a29c0c8a200a273 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37


(function() {

  Polymer({

    is: 'paper-input-error',

    behaviors: [
      Polymer.PaperInputAddonBehavior
    ],

    hostAttributes: {
      'role': 'alert'
    },

    properties: {

      /**
       * True if the error is showing.
       */
      invalid: {
        readOnly: true,
        reflectToAttribute: true,
        type: Boolean
      }

    },

    update: function(state) {
      this._setInvalid(state.invalid);
    }

  })

})();