Commit 4488a4cd by Ivana Huckova Committed by GitHub

Explore/Loki: Fix scrolling of context when leaving context window (#25838)

* Fix jumping layout

* Update log row hover background only if context is not open
parent d1e6214a
...@@ -91,19 +91,23 @@ class UnThemedLogRow extends PureComponent<Props, State> { ...@@ -91,19 +91,23 @@ class UnThemedLogRow extends PureComponent<Props, State> {
}; };
/** /**
* We are using onMouse events to change background of Log Details Table to hover-state-background when * We are using onMouse events to change background of Log Details Table to hover-state-background when hovered over Log
* hovered over Log Row and vice versa. This can't be done with css because we use 2 separate table rows without common parent element. * Row and vice versa, when context is not open. This can't be done with css because we use 2 separate table rows without common parent element.
*/ */
addHoverBackground = () => { addHoverBackground = () => {
if (!this.state.showContext) {
this.setState({ this.setState({
hasHoverBackground: true, hasHoverBackground: true,
}); });
}
}; };
clearHoverBackground = () => { clearHoverBackground = () => {
if (!this.state.showContext) {
this.setState({ this.setState({
hasHoverBackground: false, hasHoverBackground: false,
}); });
}
}; };
toggleDetails = () => { toggleDetails = () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment