Skip to content

Commit

Permalink
Pass EuiSuperSelect's popoverClassName to the popover's panel (#2068)
Browse files Browse the repository at this point in the history
  • Loading branch information
zumwalt authored Jun 20, 2019
1 parent 765704b commit 82f22d8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
- Changed `popout` glyph in `EuiIcon` to look more like external link ([2064](https://github.com/elastic/eui/pull/2064))
- Tweaked `SuperDatePicker` to make the start/end date selection more obvious ([#2049](https://github.com/elastic/eui/pull/2049))
- Added `toSentenceCase` string service ([#2049](https://github.com/elastic/eui/pull/2049))
- Pass `EuiSuperSelect`'s `popoverClassName` to the popover's panel ([#2068](https://github.com/elastic/eui/pull/2068))

**Bug fixes**

Expand Down
6 changes: 5 additions & 1 deletion src/components/form/super_select/super_select.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,10 @@ export class EuiSuperSelect extends Component {
popoverClassName
);

const popoverPanelClasses = classNames('euiSuperSelect__popoverPanel', {
[`${popoverClassName}__popoverPanel`]: !!popoverClassName,
});

const buttonClasses = classNames(
{
'euiSuperSelect--isOpen__button': this.state.isPopoverOpen,
Expand Down Expand Up @@ -232,7 +236,7 @@ export class EuiSuperSelect extends Component {
<EuiPopover
className={popoverClasses}
anchorClassName="euiSuperSelect__popoverAnchor"
panelClassName="euiSuperSelect__popoverPanel"
panelClassName={popoverPanelClasses}
button={button}
isOpen={isOpen || this.state.isPopoverOpen}
closePopover={this.closePopover}
Expand Down

0 comments on commit 82f22d8

Please sign in to comment.