Skip to content

Commit cf33ce2

Browse files
authored
Merge pull request #218 from NickFitz/capabilities-wip
Capability: Pan, Zoom and Re-centre a Map
2 parents e298d79 + c537466 commit cf33ce2

File tree

1 file changed

+45
-7
lines changed

1 file changed

+45
-7
lines changed

index.html

+45-7
Original file line numberDiff line numberDiff line change
@@ -5196,15 +5196,31 @@ <h5>Conclusion</h5>
51965196
<section id="capability-pan-zoom-or-re-centre-map" data-ucr-role="capability">
51975197
<h4>Pan, zoom, or re-centre a map</h4>
51985198
<p>
5199-
Description to follow
5199+
Developers expect to be able to control a map by changing its centre and/or zoom level,
5200+
and may also wish to support the capability of resetting a map to its view as originally presented.
5201+
If the map view cannot be dynamically modified by an application,
5202+
as opposed to changes by direct user interaction with the map,
5203+
then it offers fewer advantages over a static map view.
5204+
</p>
5205+
<p>
5206+
It is usually also desirable that such changes can be accomplished in a manner that gives sufficient
5207+
visual feedback to the user that a change is occurring,
5208+
for example by animating the transition rather than simply redrawing the map with the new view,
5209+
which may not be immediately noticeable to the user.
5210+
</p>
5211+
<p>
5212+
Accessibility is an important consideration when the state of a map is altered dynamically.
5213+
Thought should be given to how the change can be made known to assistive technologies so that the user
5214+
is fully informed and thus cognisant of the current state of the map at all times.
52005215
</p>
52015216
<p class="issue discussion" data-number="67">
52025217
Discuss this section on GitHub.
52035218
</p>
52045219

52055220
<h5>Existing implementations</h5>
52065221
<p>
5207-
Existing implementation support:
5222+
All the reviewed JavaScript API implementations support changing the bounds, centre, and zoom level of a map,
5223+
and allow such transitions to be animated.
52085224
</p>
52095225
<dl data-ucr-role="implementation-notes">
52105226
<!-- Use dt elements to name the implementation, using the id string to create an auto-link.
@@ -5220,8 +5236,12 @@ <h5>Existing implementations</h5>
52205236
<dt>leaflet-api</dt>
52215237
<dt>open-layers-api</dt>
52225238
<dt>d3-geographies-api</dt>
5223-
<dd><a>not applicable</a>:
5239+
<dd><a>full support</a>:
52245240
<!-- details about what is/isn't supported -->
5241+
<p>
5242+
Animated transitions are supported by calling specific methods with names such as <code>flyTo</code>
5243+
or via a Boolean parameter to a more general method such as <code>setView</code>.
5244+
</p>
52255245
</dd>
52265246
</dl>
52275247

@@ -5230,13 +5250,17 @@ <h5>Supported use cases</h5>
52305250

52315251
<h5>Uses beyond mapping</h5>
52325252
<p>
5233-
ToDo
5253+
This capability would be relevant to use of web map technology for the display of non-geographic imagery,
5254+
such as navigating the view to relevant parts of a complex diagram as the user progresses through related content.
52345255
</p>
52355256

52365257
<h5>Related web specifications</h5>
52375258
<p>
52385259
<!-- Any existing/proposed specs that address similar needs or otherwise interact.
52395260
Include links with proper ReSpec references. -->
5261+
<a href="https://github.com/w3c/csswg-drafts/issues/5275">
5262+
[css-overflow] Consider adding new CSS primitive for per-element panning and zooming (for web maps) #5275
5263+
</a>
52405264
</p>
52415265

52425266
<h5>Conclusion</h5>
@@ -5246,13 +5270,27 @@ <h5>Conclusion</h5>
52465270
See examples.
52475271
-->
52485272
<p>
5249-
Based on the limited data, we are <a data-ucr-role="conclusion">undecided</a> about whether this should be a requirement.
5273+
As this is capability is required for any dynamic update of a map view such as would be expected of a map-based application,
5274+
it is a <a data-ucr-role="conclusion">requirement</a> for embedded web maps.
52505275
</p>
52515276
<ul data-ucr-role="conclusion-notes">
52525277
<!-- bullet-point notes summarizing implementation details / blocking issues.
52535278
Add tags to the start of a point with an empty `<a data-ucr-role="tag"></a>` where the text content or href matches a tag `id` value. -->
5254-
<li><a data-ucr-role="tag" href=""></a>
5255-
<!-- short summary of how the tag applies -->
5279+
<li><a data-ucr-role="tag" href="">privacy-potential</a>
5280+
As there is the potential for third-party scripts to observe the panning and zooming of a map,
5281+
there is a risk with current implementations of this feature exposing an individual's or corporation's
5282+
interest in particular locations.
5283+
This risk would be mitigated with appropriate browser-level security.
5284+
</li>
5285+
<li><a data-ucr-role="tag" href="">accessibility-potential</a>
5286+
Current implementations can only represent changes in the map state in a semantically meaningful form
5287+
to a limited degree via such mechanisms as [[[ARIA]]] live regions.
5288+
A browser implementation would be better able to provide meaningful representations of such changes to assistive
5289+
technologies.
5290+
</li>
5291+
<li><a data-ucr-role="tag" href="">performance-potential</a>
5292+
As current implementations rely on extensive manipulation of DOM nodes to achieve these effects,
5293+
it is probable that a native implementation would be much more efficient.
52565294
</li>
52575295
</ul>
52585296
</section>

0 commit comments

Comments
 (0)