mirror of
https://github.com/google-map-react/google-map-react.git
synced 2025-12-08 18:26:32 +00:00
Fix force mouse move if child count changed
This commit is contained in:
parent
5ee5a8c808
commit
64ca283d23
@ -77,8 +77,16 @@ export default class GoogleMapMarkers extends Component {
|
||||
return;
|
||||
}
|
||||
|
||||
const prevChildCount = (this.state.children || []).length;
|
||||
|
||||
const state = this._getState();
|
||||
this.setState(state);
|
||||
|
||||
this.setState(
|
||||
state,
|
||||
() =>
|
||||
(state.children || []).length !== prevChildCount &&
|
||||
this._onMouseChangeHandler()
|
||||
);
|
||||
}
|
||||
|
||||
_onChildClick = () => {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user