Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lint issues at main branch #171

Merged
merged 1 commit into from
Apr 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/Global.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ declare global {
//The types below, are useful for TypeScript intellisense.
type GoogleMapsAlgorithm = OriginalAlgorithm;
type GoogleMapsCluster = OriginalCluster;
type GoogleMapsMarker = google.maps.Marker | google.maps.marker.AdvancedMarkerElement;
type GoogleMapsMarkerClusterer = OriginalMarkerClusterer;
type GoogleMapsMarkerClustererOptions = OriginalMarkerClustererOptions;
type GoogleMapsClusterRenderer = OriginalRenderer;
Expand Down
6 changes: 3 additions & 3 deletions src/Providers/Maps/Google/Features/GoogleMarkerClusterer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ namespace Provider.Maps.Google.Feature {
public addMarker(marker: OSFramework.Maps.Marker.IMarker): void {
if (this.isEnabled && marker.isReady) {
// We need to make sure that a redraw is triggered whenever a new marker is added to the clusters
this._markerClusterer.addMarker(marker.provider, false);
this._markerClusterer.addMarker(marker.provider as GoogleMapsMarker, false);
}
}

Expand Down Expand Up @@ -146,7 +146,7 @@ namespace Provider.Maps.Google.Feature {
public removeMarker(marker: OSFramework.Maps.Marker.IMarker): void {
if (this.isEnabled && marker.isReady) {
// We need to make sure that a redraw is triggered whenever a new marker is removed from the clusters
this._markerClusterer?.removeMarker(marker.provider, false);
this._markerClusterer?.removeMarker(marker.provider as GoogleMapsMarker, false);
}
}

Expand All @@ -155,7 +155,7 @@ namespace Provider.Maps.Google.Feature {
}

public setClusterRenderer(renderer: OSFramework.Maps.Feature.IMarkerClustererRender) {
this._renderer = renderer;
this._renderer = renderer as GoogleMapsClusterRenderer;
if (this.isEnabled) {
this._rebuildClusters();
}
Expand Down
Loading