mirror of
https://github.com/grafana/grafana.git
synced 2025-09-23 18:52:33 +08:00
Resize map on changing browser size (#47084)
This commit is contained in:
@ -120,6 +120,12 @@ export class GeomapPanel extends Component<Props, State> {
|
||||
return true; // always?
|
||||
}
|
||||
|
||||
componentDidUpdate(prevProps: Props) {
|
||||
if (this.map && (this.props.height !== prevProps.height || this.props.width !== prevProps.width)) {
|
||||
this.map.updateSize();
|
||||
}
|
||||
}
|
||||
|
||||
/** This function will actually update the JSON model */
|
||||
private doOptionsUpdate(selected: number) {
|
||||
const { options, onOptionsChange } = this.props;
|
||||
|
Reference in New Issue
Block a user