mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
This commit is contained in:
parent
781a2c437c
commit
b407c62083
2 changed files with 10 additions and 4 deletions
|
@ -159,9 +159,13 @@ export const TableView = injectI18n(
|
|||
};
|
||||
|
||||
private closePopoverFor = (id: string) => () => {
|
||||
this.setState(prevState => ({
|
||||
isPopoverOpen: prevState.isPopoverOpen.filter(subject => subject !== id),
|
||||
}));
|
||||
if (this.state.isPopoverOpen.includes(id)) {
|
||||
this.setState(prevState => {
|
||||
return {
|
||||
isPopoverOpen: prevState.isPopoverOpen.filter(subject => subject !== id),
|
||||
};
|
||||
});
|
||||
}
|
||||
};
|
||||
}
|
||||
);
|
||||
|
|
|
@ -90,7 +90,9 @@ export class Node extends React.PureComponent<Props, State> {
|
|||
};
|
||||
|
||||
private closePopover = () => {
|
||||
this.setState({ isPopoverOpen: false });
|
||||
if (this.state.isPopoverOpen) {
|
||||
this.setState({ isPopoverOpen: false });
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue