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

Make map-properties popup size dynamic #1017

Merged
merged 2 commits into from
Dec 6, 2024
Merged

Conversation

yushan-mu
Copy link
Contributor

Fixes #893

const map = layer._map;
const popupOptions = {
autoClose: false,
autoPan: true,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the autoPan value was the default false and that was intentional so that the map wouldn't keep panning and pulling in new features, which might be a problem for a screenreader user (?). That was my theory anyhow. I guess we can keep this value and see if it engenders any comment from anyone else though.

@@ -70,11 +70,18 @@ export var TemplatedFeaturesLayer = Layer.extend({
projection: map.options.projection,
mapEl: this._linkEl.getMapEl(),
onEachFeature: function (properties, geometry) {
const popupOptions = {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the autoPan value was the default false and that was intentional so that the map wouldn't keep panning and pulling in new features, which might be a problem for a screenreader user (?). That was my theory anyhow. I guess we can keep this value and see if it engenders any comment from anyone else though.

Copy link
Member

@prushforth prushforth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work! Merge when ready. Thanks!

@prushforth prushforth marked this pull request as ready for review December 6, 2024 18:50
@yushan-mu yushan-mu merged commit b194b30 into Maps4HTML:main Dec 6, 2024
1 check passed
@yushan-mu yushan-mu deleted the issue-893 branch December 6, 2024 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make map-properties popup size dynamic
2 participants