Maps4HTML / HTML-Map-Element-UseCases-Requirements

Use cases and requirements for Maps on the Web
https://maps4html.org/HTML-Map-Element-UseCases-Requirements/
Other
22 stars 12 forks source link

Use case (author / website visitor): Have the map widget adjust to available space responsively #174

Open AmeliaBR opened 4 years ago

AmeliaBR commented 4 years ago

As discussed in #168, ideally map viewer widgets would be responsive for easily adapting to the device size.

Not sure whether to list this as an authoring use case (want the widget to fit your site design), or as an end-user use case (want the widget to fit your device, whether or not the author thought about it).

Malvoz commented 4 years ago

As discussed in #168

That discussion mainly revolves around having the map viewer not be wider than the viewport. But no other HTML element is responsive by default, I don't think the map viewer should be.

max-width: 100% on the map viewer element should be sufficient to achieve responsiveness.

Or is this about having the exposed user interface (MapML's definition for reference) adapt to the available space?

Comparing to video, if a default control doesn't have enough space, it is display: none (in Chrome at least):

Chrome hides controls if not enough space

Additionally, it'd probably be convenient if the UA would hide certain "secondary" but default controls in a menu:

video menu example video menu open example

Edit: I brought this up in https://github.com/WICG/open-ui/issues/213#issuecomment-735245069 (issue for improving the standard media elements).