Skip to content

Commit

Permalink
fix merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolethoen committed Jun 25, 2019
2 parents 33485ba + 669ae07 commit 601a7d9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
Expand Up @@ -2,6 +2,7 @@
title: 'Pagination'
cssPrefix: null
propComponents: ['Pagination']
typescript: true
---

import { Pagination, PaginationVariant } from '@patternfly/react-core';
Expand Down
Expand Up @@ -44,7 +44,7 @@ interface PaginationOptionsMenuState {
}

export class PaginationOptionsMenu extends React.Component<PaginationOptionsMenuProps, PaginationOptionsMenuState> {

private parentRef = React.createRef<HTMLDivElement>();
static defaultProps = {
className: '',
widgetId: '',
Expand Down Expand Up @@ -112,19 +112,14 @@ export class PaginationOptionsMenu extends React.Component<PaginationOptionsMenu
const { className, widgetId, itemsPerPageTitle, dropDirection, optionsToggle, perPageOptions, toggleTemplate, firstIndex, lastIndex, itemCount, itemsTitle } = this.props;
const { isOpen } = this.state;

let parentRef = null;
const setParentRef = (ref: HTMLElement) => {
parentRef = ref;
};

return (
<div
className={css(styles.optionsMenu, className)}
ref={setParentRef}
ref={this.parentRef}
>
<span id={`${widgetId}-label`} hidden>
{itemsPerPageTitle}:
</span>
<span id={`${widgetId}-label`} hidden>
{itemsPerPageTitle}:
</span>
<Dropdown
direction={dropDirection}
onSelect={this.onSelect}
Expand All @@ -141,7 +136,7 @@ export class PaginationOptionsMenu extends React.Component<PaginationOptionsMenu
itemCount={itemCount}
itemsTitle={itemsTitle}
toggleTemplate={toggleTemplate}
parentRef={parentRef}
parentRef={this.parentRef.current}
/>
}
dropdownItems={this.renderItems()}
Expand Down

0 comments on commit 601a7d9

Please sign in to comment.