Skip to content

Commit

Permalink
Add autocorrect and autocapitalize to paper-input passThru attributes (
Browse files Browse the repository at this point in the history
  • Loading branch information
dpatz authored and miguelcobain committed Jan 16, 2017
1 parent f61ead7 commit 01f0a05
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
2 changes: 2 additions & 0 deletions addon/templates/components/paper-input.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@

accept={{passThru.accept}}
autocomplete={{passThru.autocomplete}}
autocorrect={{passThru.autocorrect}}
autocapitalize={{passThru.autocapitalize}}
autosave={{passThru.autosave}}
form={{passThru.form}}
formaction={{passThru.formaction}}
Expand Down
22 changes: 22 additions & 0 deletions tests/integration/components/paper-input-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,28 @@ test('renders input with attribute autocomplete', function(assert) {
assert.equal(actual, expected);
});

test('renders input with attribute autocorrect', function(assert) {
assert.expect(1);

this.render(hbs`{{paper-input passThru=(hash autocorrect="autocorrect") onChange=dummyOnChange}}`);

let actual = this.$('md-input-container input').attr('autocorrect');
let expected = 'autocorrect';

assert.equal(actual, expected);
});

test('renders input with attribute autocapitalize', function(assert) {
assert.expect(1);

this.render(hbs`{{paper-input passThru=(hash autocapitalize="autocapitalize") onChange=dummyOnChange}}`);

let actual = this.$('md-input-container input').attr('autocapitalize');
let expected = 'autocapitalize';

assert.equal(actual, expected);
});

test('renders input with attribute form', function(assert) {
assert.expect(1);

Expand Down

0 comments on commit 01f0a05

Please sign in to comment.