Skip to content

Commit

Permalink
fix(textfield): disallow outline or box style for fullwidth textfield
Browse files Browse the repository at this point in the history
fixes #243
  • Loading branch information
stasson committed Feb 11, 2018
1 parent 8cc88e2 commit 2d2502d
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions components/textfield/mdc-textfield.vue
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,8 @@ export default {
'mdc-text-field--dense': this.dense,
'mdc-text-field--fullwidth': this.fullwidth,
'mdc-text-field--textarea': this.multiline,
'mdc-text-field--box': this.box,
'mdc-text-field--outlined': this.outline,
'mdc-text-field--box': !this.fullwidth && this.box,
'mdc-text-field--outlined': !this.fullwidth && this.outline,
},
inputClasses: {
'mdc-text-field__input': true
Expand Down Expand Up @@ -190,13 +190,13 @@ export default {
return this.help ? 'help-' + this._uid: undefined
},
hasLabel () {
return this.label && !this.fullwidth
return !this.fullwidth && this.label
},
hasOutline () {
return this.outline
return !this.fullwidth && this.outline
},
hasBottomLine () {
return !this.outline && !this.multiline
return !this.hasOutline && !this.multiline
},
hasLeadingIcon () {
if ((this.leadingIcon || this.$slots['leading-icon'])
Expand Down

0 comments on commit 2d2502d

Please sign in to comment.