Skip to content

Commit

Permalink
fix: wrap radio, checkbox in span to allow custom styles
Browse files Browse the repository at this point in the history
  • Loading branch information
makepanic committed Jan 24, 2018
1 parent 4d7b6a9 commit f8bbf2e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions addon/templates/components/validated-input.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@
focusOut = (action "setDirty")
disabled = disabled
}}
{{option.label}}</label>
<span>{{option.label}}</span>
</label>
</div>
{{/each}}

Expand All @@ -81,7 +82,7 @@
update = (action "update")
focusOut = (action "setDirty")
}}
{{label}}
<span>{{label}}</span>
</label>
</div>

Expand Down
1 change: 1 addition & 0 deletions tests/integration/components/validated-form-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ test('it renders a radio group', function(assert) {
assert.equal(this.$('label').eq(1).text().trim(), 'Option 1');
assert.equal(this.$('label').eq(2).text().trim(), 'Option 2');
assert.equal(this.$('label').eq(3).text().trim(), 'Option 3');
assert.equal(this.$('label > span').length, 3, 'Wraps all label text in span');
});

test('it renders a radio group with block form', function(assert) {
Expand Down

0 comments on commit f8bbf2e

Please sign in to comment.