Skip to content

Commit

Permalink
Move hasLabel condition to text input style
Browse files Browse the repository at this point in the history
  • Loading branch information
AlfredoAlc committed Oct 7, 2021
1 parent 31bd3c0 commit 714aedf
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/components/ExpensiTextInput/BaseExpensiTextInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,6 @@ class BaseExpensiTextInput extends Component {
<View
style={[
styles.expensiTextInputContainer,
!hasLabel && styles.pv0,
this.state.isFocused && styles.borderColorFocus,
(hasError || errorText) && styles.borderColorDanger,
]}
Expand Down Expand Up @@ -194,7 +193,7 @@ class BaseExpensiTextInput extends Component {
placeholder={(this.state.isFocused || !label) ? placeholder : null}
placeholderTextColor={themeColors.placeholderText}
underlineColorAndroid="transparent"
style={inputStyle}
style={[inputStyle, !hasLabel && styles.pv0,]}
multiline={multiline}
onFocus={this.onFocus}
onBlur={this.onBlur}
Expand Down

0 comments on commit 714aedf

Please sign in to comment.