[v9.3.x] Canvas: Inconsistent border behavior (#61804)

This commit is contained in:
Grot (@grafanabot)
2023-01-19 18:59:59 +00:00
committed by GitHub
parent 6ba3cceb79
commit 30f8d97b48
@@ -153,7 +153,7 @@ export class CanvasPanel extends Component<Props, State> {
};
shouldComponentUpdate(nextProps: Props, nextState: State) {
const { width, height, data } = this.props;
const { width, height, data, options } = this.props;
let changed = false;
if (width !== nextProps.width || height !== nextProps.height) {
@@ -166,6 +166,11 @@ export class CanvasPanel extends Component<Props, State> {
changed = true;
}
if (options !== nextProps.options && !this.scene.ignoreDataUpdate) {
this.scene.updateData(nextProps.data);
changed = true;
}
if (this.state.refresh !== nextState.refresh) {
changed = true;
}