mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Streaming: Fixes an issue with time series panel and streaming data source when scrolling back from being out of view (#31431)
* Streaming: Fixes an issue with time series panel and streaming data source when scrolling back from being out of view * Slight tweak
This commit is contained in:
parent
070d512c57
commit
59c060f1f1
@ -136,9 +136,12 @@ export class PanelChrome extends Component<Props, State> {
|
||||
// So in this context we can only do a single call to setState
|
||||
onDataUpdate(data: PanelData) {
|
||||
if (!this.props.isInView) {
|
||||
// Ignore events when not visible.
|
||||
// The call will be repeated when the panel comes into view
|
||||
this.setState({ refreshWhenInView: true });
|
||||
if (data.state !== LoadingState.Streaming) {
|
||||
// Ignore events when not visible.
|
||||
// The call will be repeated when the panel comes into view
|
||||
this.setState({ refreshWhenInView: true });
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user