Skip to content

Commit

Permalink
Fixed #1780 - Improve float label support in overlay selects
Browse files Browse the repository at this point in the history
  • Loading branch information
mertsincan committed Jan 26, 2021
1 parent 2388583 commit 0babfa1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/cascadeselect/CascadeSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ export class CascadeSelect extends Component {
'p-disabled': this.props.disabled,
'p-focus': this.state.focused,
'p-inputwrapper-filled': this.props.value,
'p-inputwrapper-focus': this.state.focused
'p-inputwrapper-focus': this.state.focused || this.state.overlayVisible
});

let keyboardHelper = this.renderKeyboardHelper();
Expand Down
2 changes: 1 addition & 1 deletion src/components/dropdown/Dropdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ export class Dropdown extends Component {
'p-focus': this.state.focused,
'p-dropdown-clearable': this.props.showClear && !this.props.disabled,
'p-inputwrapper-filled': this.props.value,
'p-inputwrapper-focus': this.state.focused
'p-inputwrapper-focus': this.state.focused || this.state.overlayVisible
});
let selectedOption = this.findOption(this.props.value);

Expand Down
2 changes: 1 addition & 1 deletion src/components/multiselect/MultiSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ export class MultiSelect extends Component {
'p-multiselect-clearable': this.props.showClear && !this.props.disabled,
'p-focus': this.state.focused,
'p-inputwrapper-filled': this.props.value && this.props.value.length > 0,
'p-inputwrapper-focus': this.state.focused
'p-inputwrapper-focus': this.state.focused || this.state.overlayVisible
}, this.props.className);
let label = this.renderLabel();
let clearIcon = this.renderClearIcon();
Expand Down

0 comments on commit 0babfa1

Please sign in to comment.