Skip to content

Commit 45c980a

Browse files
authored
Set role="application" (#467)
1 parent 391f96d commit 45c980a

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/mapml-viewer.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,9 @@ export class MapViewer extends HTMLElement {
219219

220220
this.setControls(false,false,true);
221221
this._crosshair = M.crosshair().addTo(this._map);
222-
222+
223+
// https://github.com/Maps4HTML/Web-Map-Custom-Element/issues/274
224+
this.setAttribute('role', 'application');
223225
// Make the Leaflet container element programmatically identifiable
224226
// (https://github.com/Leaflet/Leaflet/issues/7193).
225227
this._container.setAttribute('role', 'region');

src/web-map.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,8 @@ export class WebMap extends HTMLMapElement {
254254
this.poster.style.display = 'none';
255255
}
256256

257+
// https://github.com/Maps4HTML/Web-Map-Custom-Element/issues/274
258+
this.setAttribute('role', 'application');
257259
// Make the Leaflet container element programmatically identifiable
258260
// (https://github.com/Leaflet/Leaflet/issues/7193).
259261
this._container.setAttribute('role', 'region');

0 commit comments

Comments
 (0)