| OLD | NEW |
| 1 | 1 |
| 2 | 2 |
| 3 /** | 3 /** |
| 4 * Use `Polymer.PaperInputBehavior` to implement inputs with `<paper-input-con
tainer>`. This | 4 * Use `Polymer.PaperInputBehavior` to implement inputs with `<paper-input-con
tainer>`. This |
| 5 * behavior is implemented by `<paper-input>`. It exposes a number of properti
es from | 5 * behavior is implemented by `<paper-input>`. It exposes a number of properti
es from |
| 6 * `<paper-input-container>` and `<input is="iron-input">` and they should be
bound in your | 6 * `<paper-input-container>` and `<input is="iron-input">` and they should be
bound in your |
| 7 * template. | 7 * template. |
| 8 * | 8 * |
| 9 * The input element can be accessed by the `inputElement` property if you nee
d to access | 9 * The input element can be accessed by the `inputElement` property if you nee
d to access |
| 10 * properties or methods that are not exposed. | 10 * properties or methods that are not exposed. |
| 11 * @polymerBehavior | 11 * @polymerBehavior Polymer.PaperInputBehavior |
| 12 */ | 12 */ |
| 13 Polymer.PaperInputBehavior = { | 13 Polymer.PaperInputBehaviorImpl = { |
| 14 | 14 |
| 15 properties: { | 15 properties: { |
| 16 | 16 |
| 17 /** | 17 /** |
| 18 * The label for this input. Bind this to `<paper-input-container>`'s `lab
el` property. | 18 * The label for this input. Bind this to `<paper-input-container>`'s `lab
el` property. |
| 19 */ | 19 */ |
| 20 label: { | 20 label: { |
| 21 type: String | 21 type: String |
| 22 }, | 22 }, |
| 23 | 23 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 | 66 |
| 67 /** | 67 /** |
| 68 * The type of the input. The supported types are `text`, `number` and `pa
ssword`. Bind this | 68 * The type of the input. The supported types are `text`, `number` and `pa
ssword`. Bind this |
| 69 * to the `<input is="iron-input">`'s `type` property. | 69 * to the `<input is="iron-input">`'s `type` property. |
| 70 */ | 70 */ |
| 71 type: { | 71 type: { |
| 72 type: String | 72 type: String |
| 73 }, | 73 }, |
| 74 | 74 |
| 75 /** | 75 /** |
| 76 * The datalist of the input (if any). This should match the id of an exis
ting <datalist>. Bind this |
| 77 * to the `<input is="iron-input">`'s `list` property. |
| 78 */ |
| 79 list: { |
| 80 type: String |
| 81 }, |
| 82 |
| 83 /** |
| 76 * A pattern to validate the `input` with. Bind this to the `<input is="ir
on-input">`'s | 84 * A pattern to validate the `input` with. Bind this to the `<input is="ir
on-input">`'s |
| 77 * `pattern` property. | 85 * `pattern` property. |
| 78 */ | 86 */ |
| 79 pattern: { | 87 pattern: { |
| 80 type: String | 88 type: String |
| 81 }, | 89 }, |
| 82 | 90 |
| 83 /** | 91 /** |
| 84 * Set to true to mark the input as required. Bind this to the `<input is=
"iron-input">`'s | 92 * Set to true to mark the input as required. Bind this to the `<input is=
"iron-input">`'s |
| 85 * `required` property. | 93 * `required` property. |
| (...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 labelledBy = label.id; | 304 labelledBy = label.id; |
| 297 } else { | 305 } else { |
| 298 labelledBy = 'paper-input-label-' + new Date().getUTCMilliseconds(); | 306 labelledBy = 'paper-input-label-' + new Date().getUTCMilliseconds(); |
| 299 label.id = labelledBy; | 307 label.id = labelledBy; |
| 300 } | 308 } |
| 301 this._ariaLabelledBy = labelledBy; | 309 this._ariaLabelledBy = labelledBy; |
| 302 } | 310 } |
| 303 | 311 |
| 304 }; | 312 }; |
| 305 | 313 |
| 314 Polymer.PaperInputBehavior = [Polymer.IronControlState, Polymer.PaperInputBeha
viorImpl]; |
| 315 |
| OLD | NEW |