Skip to content

Commit

Permalink
Pass EuiSuperSelect's popoverClassName to the popover's panel
Browse files Browse the repository at this point in the history
  • Loading branch information
zumwalt committed Jun 20, 2019
1 parent c107d3a commit c9d2a57
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 @@ -5,6 +5,7 @@
- Added `magnifyWithMinus` and `magnifyWithPlus` glyphs to `EuiIcon` ([2056](https://github.com/elastic/eui/pull/2056))
- Added a fully black (no matter the theme) color SASS variable `$euiColorInk` ([2060](https://github.com/elastic/eui/pull/2060))
- Added `autoFocus` prop to `EuiTabbedContent` ([2062](https://github.com/elastic/eui/pull/2062))
- Pass `EuiSuperSelect`'s `popoverClassName` to the popover's panel ([#2065](https://github.com/elastic/eui/pull/2065))

**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 c9d2a57

Please sign in to comment.