googlemaps / googlemaps/js-adv-markers-utils

It is not possible to open info window for marker anchor

Open
#35 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
14
Forks
10
Avg merge
2m
Merged PRs (30d)
7

Description

### Operating system

Any

### Browser Version

Any

### How severe is the bug?

high

### Bug description

In order to open `InfoWindow` we need to pass `AdvancedMarkerElement` instance to `InfoWindow.prototype.open` as `anchor`. It is possible to do it by using `marker.markerView_`, but it is not legal, this instance variable has dangling underscore.

### Steps to reproduce

```
const marker = new Marker({
map,
position: {
lat: 1,
lng: 2,
}
});
const infoWindow = new googleApi.InfoWindow({
content: 'some content',
});
infoWindow.open(map, marker);
```

### Console log output

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.