Convert some element ids to classes to avoid collisions when embedding iD

This commit is contained in:
Quincy Morgan
2020-03-20 13:53:17 -07:00
parent f625406ccc
commit c893147e15
16 changed files with 32 additions and 32 deletions
+1 -1
View File
@@ -445,7 +445,7 @@ export function modeDragNode(context) {
var drag = behaviorDrag()
.selector('.layer-touch.points .target')
.surface(d3_select('#map').node())
.surface(d3_select('.main-map').node())
.origin(origin)
.on('start', start)
.on('move', move)
+1 -1
View File
@@ -107,7 +107,7 @@ export function modeDragNote(context) {
var drag = behaviorDrag()
.selector('.layer-touch.markers .target.note.new')
.surface(d3_select('#map').node())
.surface(d3_select('.main-map').node())
.origin(origin)
.on('start', start)
.on('move', move)
+2 -2
View File
@@ -69,7 +69,7 @@ export function svgGeolocate(projection) {
pointsEnter
.append('circle')
.attr('id', 'geolocate-radius')
.attr('class', 'geolocate-radius')
.attr('dx', '0')
.attr('dy', '0')
.attr('fill', 'rgb(15,128,225)')
@@ -88,7 +88,7 @@ export function svgGeolocate(projection) {
groups.merge(pointsEnter)
.attr('transform', transform);
d3_select('#geolocate-radius').attr('r', accuracy(_position.coords.accuracy, geolocation.loc));
layer.select('.geolocate-radius').attr('r', accuracy(_position.coords.accuracy, geolocation.loc));
}
function drawLocation(selection) {
+1 -1
View File
@@ -115,7 +115,7 @@ export function uiInit(context) {
content
.append('div')
.attr('id', 'map')
.attr('class', 'main-map')
.attr('dir', 'ltr')
.call(map);
+3 -3
View File
@@ -72,7 +72,7 @@ export function uiIntro(context) {
let zoom = context.map().zoom();
let background = context.background().baseLayerSource();
let overlays = context.background().overlayLayerSources();
let opacity = d3_selectAll('#map .layer-background').style('opacity');
let opacity = d3_selectAll('.main-map .layer-background').style('opacity');
let caches = osm && osm.caches();
let baseEntities = context.history().graph().base().entities;
@@ -109,7 +109,7 @@ export function uiIntro(context) {
});
d3_selectAll('#map .layer-background').style('opacity', 1);
d3_selectAll('.main-map .layer-background').style('opacity', 1);
let curtain = uiCurtain();
selection.call(curtain);
@@ -156,7 +156,7 @@ export function uiIntro(context) {
curtain.remove();
navwrap.remove();
d3_selectAll('#map .layer-background').style('opacity', opacity);
d3_selectAll('.main-map .layer-background').style('opacity', opacity);
d3_selectAll('button.sidebar-toggle').classed('disabled', false);
if (osm) { osm.toggle(true).reset().caches(caches); }
context.history().reset().merge(Object.values(baseEntities));