Closed geospatialem closed 6 years ago
@nwisehart can you take a look at these changes and incorporate them via TypeScript into the app? Also when you add the legend can you make it configurable so when its in the app gallery users can choose the 'corner' of the app where the legend displays.
@geospatialem we'll get these moved in to an updated version using TS. Thanks for submitting the pull request.
Thanks @kellyhutchins! Hoping to get on the TypeScript bandwagon soon to make more well-rounded PR's in the future. Thanks for helping build this great example! 💯
created a typescript ready pull request under the branch Esri/a11y-map/tree/legend
Will close this PR and merge from that updated branch
Added an accessible dynamic legend to the top right corner of the map.
The legend has a
h2
heading indicating "Map legend layers:". The heading is not displayed to a sighted user by using theoffscreen
class. The ":" character in the heading aims to add a break in speech when a screen reader reads the map layer present in the legend.Using the title a
h3
heading is added to indicate the name of the map layer (Trailheads):To ensure the page heading structure is met a
h1
heading was added to the map, also hidden to sighted users using theoffscreen
class.The final heading structure is as follows:
h1
: a11y Maph2
: Map legend layers:h3
: TrailheadsUpdates tested on iOS with: VoiceOver, aXe, WAVE, and ChromeVox.
cc #11
P.S. Apologies, typescript was not used in this PR.