X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/5c58f00c2e80bfe0e5b0665b74e5a973fabb2db4..ce404d1afba755ca09ffb62b5d649259da503d4e:/vendor/assets/iD/iD.js diff --git a/vendor/assets/iD/iD.js b/vendor/assets/iD/iD.js index f3da45171..2ecfaf525 100644 --- a/vendor/assets/iD/iD.js +++ b/vendor/assets/iD/iD.js @@ -174,11 +174,13 @@ } })(this); -d3 = (function(){ - var d3 = {version: "3.3.10"}; // semver -d3.ascending = function(a, b) { +!function(){ + var d3 = {version: "3.4.6"}; // semver +d3.ascending = d3_ascending; + +function d3_ascending(a, b) { return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN; -}; +} d3.descending = function(a, b) { return b < a ? -1 : b > a ? 1 : b >= a ? 0 : NaN; }; @@ -250,17 +252,17 @@ function d3_number(x) { } d3.mean = function(array, f) { - var n = array.length, + var s = 0, + n = array.length, a, - m = 0, i = -1, - j = 0; + j = n; if (arguments.length === 1) { - while (++i < n) if (d3_number(a = array[i])) m += (a - m) / ++j; + while (++i < n) if (d3_number(a = array[i])) s += a; else --j; } else { - while (++i < n) if (d3_number(a = f.call(array, array[i], i))) m += (a - m) / ++j; + while (++i < n) if (d3_number(a = f.call(array, array[i], i))) s += a; else --j; } - return j ? m : undefined; + return j ? s / j : undefined; }; // R-7 per d3.quantile = function(values, p) { @@ -274,16 +276,17 @@ d3.quantile = function(values, p) { d3.median = function(array, f) { if (arguments.length > 1) array = array.map(f); array = array.filter(d3_number); - return array.length ? d3.quantile(array.sort(d3.ascending), .5) : undefined; + return array.length ? d3.quantile(array.sort(d3_ascending), .5) : undefined; }; -d3.bisector = function(f) { + +function d3_bisector(compare) { return { left: function(a, x, lo, hi) { if (arguments.length < 3) lo = 0; if (arguments.length < 4) hi = a.length; while (lo < hi) { var mid = lo + hi >>> 1; - if (f.call(a, a[mid], mid) < x) lo = mid + 1; + if (compare(a[mid], x) < 0) lo = mid + 1; else hi = mid; } return lo; @@ -293,17 +296,23 @@ d3.bisector = function(f) { if (arguments.length < 4) hi = a.length; while (lo < hi) { var mid = lo + hi >>> 1; - if (x < f.call(a, a[mid], mid)) hi = mid; + if (compare(a[mid], x) > 0) hi = mid; else lo = mid + 1; } return lo; } }; -}; +} -var d3_bisector = d3.bisector(function(d) { return d; }); -d3.bisectLeft = d3_bisector.left; -d3.bisect = d3.bisectRight = d3_bisector.right; +var d3_bisect = d3_bisector(d3_ascending); +d3.bisectLeft = d3_bisect.left; +d3.bisect = d3.bisectRight = d3_bisect.right; + +d3.bisector = function(f) { + return d3_bisector(f.length === 1 + ? function(d, x) { return d3_ascending(f(d), x); } + : f); +}; d3.shuffle = function(array) { var m = array.length, t, i; while (m) { @@ -425,24 +434,15 @@ d3.map = function(object) { function d3_Map() {} d3_class(d3_Map, { - has: function(key) { - return d3_map_prefix + key in this; - }, + has: d3_map_has, get: function(key) { return this[d3_map_prefix + key]; }, set: function(key, value) { return this[d3_map_prefix + key] = value; }, - remove: function(key) { - key = d3_map_prefix + key; - return key in this && delete this[key]; - }, - keys: function() { - var keys = []; - this.forEach(function(key) { keys.push(key); }); - return keys; - }, + remove: d3_map_remove, + keys: d3_map_keys, values: function() { var values = []; this.forEach(function(key, value) { values.push(value); }); @@ -453,18 +453,42 @@ d3_class(d3_Map, { this.forEach(function(key, value) { entries.push({key: key, value: value}); }); return entries; }, + size: d3_map_size, + empty: d3_map_empty, forEach: function(f) { - for (var key in this) { - if (key.charCodeAt(0) === d3_map_prefixCode) { - f.call(this, key.substring(1), this[key]); - } - } + for (var key in this) if (key.charCodeAt(0) === d3_map_prefixCode) f.call(this, key.substring(1), this[key]); } }); var d3_map_prefix = "\0", // prevent collision with built-ins d3_map_prefixCode = d3_map_prefix.charCodeAt(0); +function d3_map_has(key) { + return d3_map_prefix + key in this; +} + +function d3_map_remove(key) { + key = d3_map_prefix + key; + return key in this && delete this[key]; +} + +function d3_map_keys() { + var keys = []; + this.forEach(function(key) { keys.push(key); }); + return keys; +} + +function d3_map_size() { + var size = 0; + for (var key in this) if (key.charCodeAt(0) === d3_map_prefixCode) ++size; + return size; +} + +function d3_map_empty() { + for (var key in this) if (key.charCodeAt(0) === d3_map_prefixCode) return false; + return true; +} + d3.nest = function() { var nest = {}, keys = [], @@ -570,9 +594,7 @@ d3.set = function(array) { function d3_Set() {} d3_class(d3_Set, { - has: function(value) { - return d3_map_prefix + value in this; - }, + has: d3_map_has, add: function(value) { this[d3_map_prefix + value] = true; return value; @@ -581,19 +603,11 @@ d3_class(d3_Set, { value = d3_map_prefix + value; return value in this && delete this[value]; }, - values: function() { - var values = []; - this.forEach(function(value) { - values.push(value); - }); - return values; - }, + values: d3_map_keys, + size: d3_map_size, + empty: d3_map_empty, forEach: function(f) { - for (var value in this) { - if (value.charCodeAt(0) === d3_map_prefixCode) { - f.call(this, value.substring(1)); - } - } + for (var value in this) if (value.charCodeAt(0) === d3_map_prefixCode) f.call(this, value.substring(1)); } }); d3.behavior = {}; @@ -794,7 +808,7 @@ var d3_select = function(s, n) { return n.querySelector(s); }, // Prefer Sizzle, if available. if (typeof Sizzle === "function") { d3_select = function(s, n) { return Sizzle(s, n)[0] || null; }; - d3_selectAll = function(s, n) { return Sizzle.uniqueSort(Sizzle(s, n)); }; + d3_selectAll = Sizzle; d3_selectMatches = Sizzle.matchesSelector; } @@ -954,7 +968,7 @@ d3_selectionPrototype.classed = function(name, value) { // probably doesn't support it on SVG elements (which can be animated). if (typeof name === "string") { var node = this.node(), - n = (name = name.trim().split(/^|\s+/g)).length, + n = (name = d3_selection_classes(name)).length, i = -1; if (value = node.classList) { while (++i < n) if (!value.contains(name[i])) return false; @@ -979,9 +993,13 @@ function d3_selection_classedRe(name) { return new RegExp("(?:^|\\s+)" + d3.requote(name) + "(?:\\s+|$)", "g"); } +function d3_selection_classes(name) { + return name.trim().split(/^|\s+/); +} + // Multiple class names are allowed (e.g., "foo bar"). function d3_selection_classed(name, value) { - name = name.trim().split(/\s+/).map(d3_selection_classedName); + name = d3_selection_classes(name).map(d3_selection_classedName); var n = name.length; function classedConstant() { @@ -1328,7 +1346,7 @@ d3_selectionPrototype.sort = function(comparator) { }; function d3_selection_sortComparator(comparator) { - if (!arguments.length) comparator = d3.ascending; + if (!arguments.length) comparator = d3_ascending; return function(a, b) { return a && b ? comparator(a.__data__, b.__data__) : !a - !b; }; @@ -1608,29 +1626,12 @@ d3.mouse = function(container) { return d3_mousePoint(container, d3_eventSource()); }; -// https://bugs.webkit.org/show_bug.cgi?id=44083 -var d3_mouse_bug44083 = /WebKit/.test(d3_window.navigator.userAgent) ? -1 : 0; - function d3_mousePoint(container, e) { if (e.changedTouches) e = e.changedTouches[0]; var svg = container.ownerSVGElement || container; if (svg.createSVGPoint) { var point = svg.createSVGPoint(); - if (d3_mouse_bug44083 < 0 && (d3_window.scrollX || d3_window.scrollY)) { - svg = d3.select("body").append("svg").style({ - position: "absolute", - top: 0, - left: 0, - margin: 0, - padding: 0, - border: "none" - }, "important"); - var ctm = svg[0][0].getScreenCTM(); - d3_mouse_bug44083 = !(ctm.f || ctm.e); - svg.remove(); - } - if (d3_mouse_bug44083) point.x = e.pageX, point.y = e.pageY; - else point.x = e.clientX, point.y = e.clientY; + point.x = e.clientX, point.y = e.clientY; point = point.matrixTransform(container.getScreenCTM().inverse()); return [point.x, point.y]; } @@ -1658,6 +1659,14 @@ function d3_sgn(x) { return x > 0 ? 1 : x < 0 ? -1 : 0; } +// Returns the 2D cross product of AB and AC vectors, i.e., the z-component of +// the 3D cross product in a quadrant I Cartesian coordinate system (+x is +// right, +y is up). Returns a positive value if ABC is counter-clockwise, +// negative if clockwise, and zero if the points are collinear. +function d3_cross2d(a, b, c) { + return (b[0] - a[0]) * (c[1] - a[1]) - (b[1] - a[1]) * (c[0] - a[0]); +} + function d3_acos(x) { return x > 1 ? 0 : x < -1 ? π : Math.acos(x); } @@ -1756,37 +1765,37 @@ d3.behavior.zoom = function() { zoom.event = function(g) { g.each(function() { - var event_ = event.of(this, arguments), + var dispatch = event.of(this, arguments), view1 = view; if (d3_transitionInheritId) { - d3.select(this).transition() - .each("start.zoom", function() { - view = this.__chart__ || {x: 0, y: 0, k: 1}; // pre-transition state - zoomstarted(event_); - }) - .tween("zoom:zoom", function() { - var dx = size[0], - dy = size[1], - cx = dx / 2, - cy = dy / 2, - i = d3.interpolateZoom( - [(cx - view.x) / view.k, (cy - view.y) / view.k, dx / view.k], - [(cx - view1.x) / view1.k, (cy - view1.y) / view1.k, dx / view1.k] - ); - return function(t) { - var l = i(t), k = dx / l[2]; - this.__chart__ = view = {x: cx - l[0] * k, y: cy - l[1] * k, k: k}; - zoomed(event_); - }; - }) - .each("end.zoom", function() { - zoomended(event_); - }); + d3.select(this).transition() + .each("start.zoom", function() { + view = this.__chart__ || {x: 0, y: 0, k: 1}; // pre-transition state + zoomstarted(dispatch); + }) + .tween("zoom:zoom", function() { + var dx = size[0], + dy = size[1], + cx = dx / 2, + cy = dy / 2, + i = d3.interpolateZoom( + [(cx - view.x) / view.k, (cy - view.y) / view.k, dx / view.k], + [(cx - view1.x) / view1.k, (cy - view1.y) / view1.k, dx / view1.k] + ); + return function(t) { + var l = i(t), k = dx / l[2]; + this.__chart__ = view = {x: cx - l[0] * k, y: cy - l[1] * k, k: k}; + zoomed(dispatch); + }; + }) + .each("end.zoom", function() { + zoomended(dispatch); + }); } else { this.__chart__ = view; - zoomstarted(event_); - zoomed(event_); - zoomended(event_); + zoomstarted(dispatch); + zoomed(dispatch); + zoomended(dispatch); } }); } @@ -1862,65 +1871,65 @@ d3.behavior.zoom = function() { if (y1) y1.domain(y0.range().map(function(y) { return (y - view.y) / view.k; }).map(y0.invert)); } - function zoomstarted(event) { - event({type: "zoomstart"}); + function zoomstarted(dispatch) { + dispatch({type: "zoomstart"}); } - function zoomed(event) { + function zoomed(dispatch) { rescale(); - event({type: "zoom", scale: view.k, translate: [view.x, view.y]}); + dispatch({type: "zoom", scale: view.k, translate: [view.x, view.y]}); } - function zoomended(event) { - event({type: "zoomend"}); + function zoomended(dispatch) { + dispatch({type: "zoomend"}); } function mousedowned() { - var target = this, - event_ = event.of(target, arguments), - eventTarget = d3.event.target, + var that = this, + target = d3.event.target, + dispatch = event.of(that, arguments), dragged = 0, - w = d3.select(d3_window).on(mousemove, moved).on(mouseup, ended), - l = location(d3.mouse(target)), + subject = d3.select(d3_window).on(mousemove, moved).on(mouseup, ended), + location0 = location(d3.mouse(that)), dragRestore = d3_event_dragSuppress(); - d3_selection_interrupt.call(target); - zoomstarted(event_); + d3_selection_interrupt.call(that); + zoomstarted(dispatch); function moved() { dragged = 1; - translateTo(d3.mouse(target), l); - zoomed(event_); + translateTo(d3.mouse(that), location0); + zoomed(dispatch); } function ended() { - w.on(mousemove, d3_window === target ? mousewheelreset : null).on(mouseup, null); - dragRestore(dragged && d3.event.target === eventTarget); - zoomended(event_); + subject.on(mousemove, d3_window === that ? mousewheelreset : null).on(mouseup, null); + dragRestore(dragged && d3.event.target === target); + zoomended(dispatch); } } // These closures persist for as long as at least one touch is active. function touchstarted() { - var target = this, - event_ = event.of(target, arguments), + var that = this, + dispatch = event.of(that, arguments), locations0 = {}, // touchstart locations distance0 = 0, // distance² between initial touches scale0, // scale when we started touching - eventId = d3.event.changedTouches[0].identifier, - touchmove = "touchmove.zoom-" + eventId, - touchend = "touchend.zoom-" + eventId, - w = d3.select(d3_window).on(touchmove, moved).on(touchend, ended), - t = d3.select(target).on(mousedown, null).on(touchstart, started), // prevent duplicate events + zoomName = ".zoom-" + d3.event.changedTouches[0].identifier, + touchmove = "touchmove" + zoomName, + touchend = "touchend" + zoomName, + target = d3.select(d3.event.target).on(touchmove, moved).on(touchend, ended), + subject = d3.select(that).on(mousedown, null).on(touchstart, started), // prevent duplicate events dragRestore = d3_event_dragSuppress(); - d3_selection_interrupt.call(target); + d3_selection_interrupt.call(that); started(); - zoomstarted(event_); + zoomstarted(dispatch); // Updates locations of any touches in locations0. function relocate() { - var touches = d3.touches(target); + var touches = d3.touches(that); scale0 = view.k; touches.forEach(function(t) { if (t.identifier in locations0) locations0[t.identifier] = location(t); @@ -1945,7 +1954,7 @@ d3.behavior.zoom = function() { scaleTo(view.k * 2); translateTo(p, l); d3_eventPreventDefault(); - zoomed(event_); + zoomed(dispatch); } touchtime = now; } else if (touches.length > 1) { @@ -1956,7 +1965,7 @@ d3.behavior.zoom = function() { } function moved() { - var touches = d3.touches(target), + var touches = d3.touches(that), p0, l0, p1, l1; for (var i = 0, n = touches.length; i < n; ++i, l1 = null) { @@ -1977,7 +1986,7 @@ d3.behavior.zoom = function() { touchtime = null; translateTo(p0, l0); - zoomed(event_); + zoomed(dispatch); } function ended() { @@ -1995,24 +2004,24 @@ d3.behavior.zoom = function() { } } // Otherwise, remove touchmove and touchend listeners. - w.on(touchmove, null).on(touchend, null); - t.on(mousedown, mousedowned).on(touchstart, touchstarted); + target.on(zoomName, null); + subject.on(mousedown, mousedowned).on(touchstart, touchstarted); dragRestore(); - zoomended(event_); + zoomended(dispatch); } } function mousewheeled() { - var event_ = event.of(this, arguments); + var dispatch = event.of(this, arguments); if (mousewheelTimer) clearTimeout(mousewheelTimer); - else d3_selection_interrupt.call(this), zoomstarted(event_); - mousewheelTimer = setTimeout(function() { mousewheelTimer = null; zoomended(event_); }, 50); + else d3_selection_interrupt.call(this), zoomstarted(dispatch); + mousewheelTimer = setTimeout(function() { mousewheelTimer = null; zoomended(dispatch); }, 50); d3_eventPreventDefault(); var point = center || d3.mouse(this); if (!translate0) translate0 = location(point); scaleTo(Math.pow(2, d3_behavior_zoomDelta() * .002) * view.k); translateTo(point, translate0); - zoomed(event_); + zoomed(dispatch); } function mousewheelreset() { @@ -2020,15 +2029,15 @@ d3.behavior.zoom = function() { } function dblclicked() { - var event_ = event.of(this, arguments), + var dispatch = event.of(this, arguments), p = d3.mouse(this), l = location(p), k = Math.log(view.k) / Math.LN2; - zoomstarted(event_); + zoomstarted(dispatch); scaleTo(Math.pow(2, d3.event.shiftKey ? Math.ceil(k) - 1 : Math.floor(k) + 1)); translateTo(p, l); - zoomed(event_); - zoomended(event_); + zoomed(dispatch); + zoomended(dispatch); } return d3.rebind(zoom, event, "on"); @@ -2047,6 +2056,15 @@ function d3_functor(v) { d3.functor = d3_functor; +d3.touch = function(container, touches, identifier) { + if (arguments.length < 3) identifier = touches, touches = d3_eventSource().changedTouches; + if (touches) for (var i = 0, n = touches.length, touch; i < n; ++i) { + if ((touch = touches[i]).identifier === identifier) { + return d3_mousePoint(container, touch); + } + } +}; + var d3_timer_queueHead, d3_timer_queueTail, d3_timer_interval, // is an interval (or frame) active? @@ -2257,7 +2275,6 @@ function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { clip.lineEnd = ringEnd; segments = []; polygon = []; - listener.polygonStart(); }, polygonEnd: function() { clip.point = point; @@ -2267,13 +2284,15 @@ function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { segments = d3.merge(segments); var clipStartInside = d3_geo_pointInPolygon(rotatedClipStart, polygon); if (segments.length) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; d3_geo_clipPolygon(segments, d3_geo_clipSort, clipStartInside, interpolate, listener); } else if (clipStartInside) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; listener.lineStart(); interpolate(null, null, 1, listener); listener.lineEnd(); } - listener.polygonEnd(); + if (polygonStarted) listener.polygonEnd(), polygonStarted = false; segments = polygon = null; }, sphere: function() { @@ -2300,6 +2319,7 @@ function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { var buffer = d3_geo_clipBufferListener(), ringListener = clipLine(buffer), + polygonStarted = false, polygon, ring; @@ -2335,9 +2355,12 @@ function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { var n = segment.length - 1, i = -1, point; - listener.lineStart(); - while (++i < n) listener.point((point = segment[i])[0], point[1]); - listener.lineEnd(); + if (n > 0) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; + listener.lineStart(); + while (++i < n) listener.point((point = segment[i])[0], point[1]); + listener.lineEnd(); + } return; } @@ -2531,11 +2554,13 @@ function d3_geo_areaRingStart() { // previous point, current point. Uses a formula derived from Cagnoli’s // theorem. See Todhunter, Spherical Trig. (1871), Sec. 103, Eq. (2). var dλ = λ - λ0, + sdλ = dλ >= 0 ? 1 : -1, + adλ = sdλ * dλ, cosφ = Math.cos(φ), sinφ = Math.sin(φ), k = sinφ0 * sinφ, - u = cosφ0 * cosφ + k * Math.cos(dλ), - v = k * Math.sin(dλ); + u = cosφ0 * cosφ + k * Math.cos(adλ), + v = k * sdλ * Math.sin(adλ); d3_geo_areaRingSum.add(Math.atan2(v, u)); // Advance the previous points. @@ -2622,11 +2647,13 @@ function d3_geo_pointInPolygon(point, polygon) { sinφ = Math.sin(φ), cosφ = Math.cos(φ), dλ = λ - λ0, - antimeridian = abs(dλ) > π, + sdλ = dλ >= 0 ? 1 : -1, + adλ = sdλ * dλ, + antimeridian = adλ > π, k = sinφ0 * sinφ; - d3_geo_areaRingSum.add(Math.atan2(k * Math.sin(dλ), cosφ0 * cosφ + k * Math.cos(dλ))); + d3_geo_areaRingSum.add(Math.atan2(k * sdλ * Math.sin(adλ), cosφ0 * cosφ + k * Math.cos(adλ))); - polarAngle += antimeridian ? dλ + (dλ >= 0 ? τ : -τ): dλ; + polarAngle += antimeridian ? dλ + sdλ * τ : dλ; // Are the longitudes either side of the point's meridian, and are the // latitudes smaller than the parallel? @@ -3218,9 +3245,9 @@ function d3_geo_clipExtent(x0, y0, x1, y1) { for (var j = 1, v = polygon[i], m = v.length, a = v[0], b; j < m; ++j) { b = v[j]; if (a[1] <= y) { - if (b[1] > y && isLeft(a, b, p) > 0) ++wn; + if (b[1] > y && d3_cross2d(a, b, p) > 0) ++wn; } else { - if (b[1] <= y && isLeft(a, b, p) < 0) --wn; + if (b[1] <= y && d3_cross2d(a, b, p) < 0) --wn; } a = b; } @@ -3228,10 +3255,6 @@ function d3_geo_clipExtent(x0, y0, x1, y1) { return wn !== 0; } - function isLeft(a, b, c) { - return (b[0] - a[0]) * (c[1] - a[1]) - (c[0] - a[0]) * (b[1] - a[1]); - } - function interpolate(from, to, direction, listener) { var a = 0, a1 = 0; if (from == null || @@ -4546,6 +4569,131 @@ function d3_geom_polygonClosed(coordinates) { b = coordinates[coordinates.length - 1]; return !(a[0] - b[0] || a[1] - b[1]); } +function d3_geom_pointX(d) { + return d[0]; +} + +function d3_geom_pointY(d) { + return d[1]; +} + +/** + * Computes the 2D convex hull of a set of points using Graham's scanning + * algorithm. The algorithm has been implemented as described in Cormen, + * Leiserson, and Rivest's Introduction to Algorithms. The running time of + * this algorithm is O(n log n), where n is the number of input points. + * + * @param vertices [[x1, y1], [x2, y2], …] + * @returns polygon [[x1, y1], [x2, y2], …] + */ +d3.geom.hull = function(vertices) { + var x = d3_geom_pointX, + y = d3_geom_pointY; + + if (arguments.length) return hull(vertices); + + function hull(data) { + if (data.length < 3) return []; + + var fx = d3_functor(x), + fy = d3_functor(y), + n = data.length, + vertices, // TODO use parallel arrays + plen = n - 1, + points = [], + stack = [], + d, + i, j, h = 0, x1, y1, x2, y2, u, v, a, sp; + + if (fx === d3_geom_pointX && y === d3_geom_pointY) vertices = data; + else for (i = 0, vertices = []; i < n; ++i) { + vertices.push([+fx.call(this, d = data[i], i), +fy.call(this, d, i)]); + } + + // find the starting ref point: leftmost point with the minimum y coord + for (i = 1; i < n; ++i) { + if (vertices[i][1] < vertices[h][1] + || vertices[i][1] == vertices[h][1] + && vertices[i][0] < vertices[h][0]) h = i; + } + + // calculate polar angles from ref point and sort + for (i = 0; i < n; ++i) { + if (i === h) continue; + y1 = vertices[i][1] - vertices[h][1]; + x1 = vertices[i][0] - vertices[h][0]; + points.push({angle: Math.atan2(y1, x1), index: i}); + } + points.sort(function(a, b) { return a.angle - b.angle; }); + + // toss out duplicate angles + a = points[0].angle; + v = points[0].index; + u = 0; + for (i = 1; i < plen; ++i) { + j = points[i].index; + if (a == points[i].angle) { + // keep angle for point most distant from the reference + x1 = vertices[v][0] - vertices[h][0]; + y1 = vertices[v][1] - vertices[h][1]; + x2 = vertices[j][0] - vertices[h][0]; + y2 = vertices[j][1] - vertices[h][1]; + if (x1 * x1 + y1 * y1 >= x2 * x2 + y2 * y2) { + points[i].index = -1; + continue; + } else { + points[u].index = -1; + } + } + a = points[i].angle; + u = i; + v = j; + } + + // initialize the stack + stack.push(h); + for (i = 0, j = 0; i < 2; ++j) { + if (points[j].index > -1) { + stack.push(points[j].index); + i++; + } + } + sp = stack.length; + + // do graham's scan + for (; j < plen; ++j) { + if (points[j].index < 0) continue; // skip tossed out points + while (!d3_geom_hullCCW(stack[sp - 2], stack[sp - 1], points[j].index, vertices)) { + --sp; + } + stack[sp++] = points[j].index; + } + + // construct the hull + var poly = []; + for (i = sp - 1; i >= 0; --i) poly.push(data[stack[i]]); + return poly; + } + + hull.x = function(_) { + return arguments.length ? (x = _, hull) : x; + }; + + hull.y = function(_) { + return arguments.length ? (y = _, hull) : y; + }; + + return hull; +}; + +// are three points in counter-clockwise order? +function d3_geom_hullCCW(i1, i2, i3, v) { + var t, a, b, c, d, e, f; + t = v[i1]; a = t[0]; b = t[1]; + t = v[i2]; c = t[0]; d = t[1]; + t = v[i3]; e = t[0]; f = t[1]; + return (f - b) * (c - a) - (d - b) * (e - a) > 0; +} var d3_ease_default = function() { return d3_identity; }; @@ -4995,7 +5143,7 @@ function d3_rgb_parse(format, rgb, hsl) { b = 0, // blue channel; int in [0, 255] m1, // CSS color specification match m2, // CSS color specification type (e.g., rgb) - name; + color; /* Handle hsl, rgb. */ m1 = /([a-z]+)\((.*)\)/i.exec(format); @@ -5020,22 +5168,19 @@ function d3_rgb_parse(format, rgb, hsl) { } /* Named colors. */ - if (name = d3_rgb_names.get(format)) return rgb(name.r, name.g, name.b); + if (color = d3_rgb_names.get(format)) return rgb(color.r, color.g, color.b); /* Hexadecimal colors: #rgb and #rrggbb. */ - if (format != null && format.charAt(0) === "#") { + if (format != null && format.charAt(0) === "#" && !isNaN(color = parseInt(format.substring(1), 16))) { if (format.length === 4) { - r = format.charAt(1); r += r; - g = format.charAt(2); g += g; - b = format.charAt(3); b += b; + r = (color & 0xf00) >> 4; r = (r >> 4) | r; + g = (color & 0xf0); g = (g >> 4) | g; + b = (color & 0xf); b = (b << 4) | b; } else if (format.length === 7) { - r = format.substring(1, 3); - g = format.substring(3, 5); - b = format.substring(5, 7); + r = (color & 0xff0000) >> 16; + g = (color & 0xff00) >> 8; + b = (color & 0xff); } - r = parseInt(r, 16); - g = parseInt(g, 16); - b = parseInt(b, 16); } return rgb(r, g, b); @@ -5304,89 +5449,55 @@ function d3_interpolateNumber(a, b) { d3.interpolateString = d3_interpolateString; function d3_interpolateString(a, b) { - var m, // current match - i, // current index - j, // current index (for coalescing) - s0 = 0, // start index of current string prefix - s1 = 0, // end index of current string prefix + var bi = d3_interpolate_numberA.lastIndex = d3_interpolate_numberB.lastIndex = 0, // scan index for next number in b + am, // current match in a + bm, // current match in b + bs, // string preceding current number in b, if any + i = -1, // index in s s = [], // string constants and placeholders - q = [], // number interpolators - n, // q.length - o; + q = []; // number interpolators // Coerce inputs to strings. a = a + "", b = b + ""; - // Reset our regular expression! - d3_interpolate_number.lastIndex = 0; - - // Find all numbers in b. - for (i = 0; m = d3_interpolate_number.exec(b); ++i) { - if (m.index) s.push(b.substring(s0, s1 = m.index)); - q.push({i: s.length, x: m[0]}); - s.push(null); - s0 = d3_interpolate_number.lastIndex; - } - if (s0 < b.length) s.push(b.substring(s0)); - - // Find all numbers in a. - for (i = 0, n = q.length; (m = d3_interpolate_number.exec(a)) && i < n; ++i) { - o = q[i]; - if (o.x == m[0]) { // The numbers match, so coalesce. - if (o.i) { - if (s[o.i + 1] == null) { // This match is followed by another number. - s[o.i - 1] += o.x; - s.splice(o.i, 1); - for (j = i + 1; j < n; ++j) q[j].i--; - } else { // This match is followed by a string, so coalesce twice. - s[o.i - 1] += o.x + s[o.i + 1]; - s.splice(o.i, 2); - for (j = i + 1; j < n; ++j) q[j].i -= 2; - } - } else { - if (s[o.i + 1] == null) { // This match is followed by another number. - s[o.i] = o.x; - } else { // This match is followed by a string, so coalesce twice. - s[o.i] = o.x + s[o.i + 1]; - s.splice(o.i + 1, 1); - for (j = i + 1; j < n; ++j) q[j].i--; - } - } - q.splice(i, 1); - n--; - i--; - } else { - o.x = d3_interpolateNumber(parseFloat(m[0]), parseFloat(o.x)); - } + // Interpolate pairs of numbers in a & b. + while ((am = d3_interpolate_numberA.exec(a)) + && (bm = d3_interpolate_numberB.exec(b))) { + if ((bs = bm.index) > bi) { // a string precedes the next number in b + bs = b.substring(bi, bs); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; + } + if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match + if (s[i]) s[i] += bm; // coalesce with previous string + else s[++i] = bm; + } else { // interpolate non-matching numbers + s[++i] = null; + q.push({i: i, x: d3_interpolateNumber(am, bm)}); + } + bi = d3_interpolate_numberB.lastIndex; } - // Remove any numbers in b not found in a. - while (i < n) { - o = q.pop(); - if (s[o.i + 1] == null) { // This match is followed by another number. - s[o.i] = o.x; - } else { // This match is followed by a string, so coalesce twice. - s[o.i] = o.x + s[o.i + 1]; - s.splice(o.i + 1, 1); - } - n--; + // Add remains of b. + if (bi < b.length) { + bs = b.substring(bi); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; } // Special optimization for only a single match. - if (s.length === 1) { - return s[0] == null - ? (o = q[0].x, function(t) { return o(t) + ""; }) - : function() { return b; }; - } - // Otherwise, interpolate each of the numbers and rejoin the string. - return function(t) { - for (i = 0; i < n; ++i) s[(o = q[i]).i] = o.x(t); - return s.join(""); - }; + return s.length < 2 + ? (q[0] ? (b = q[0].x, function(t) { return b(t) + ""; }) + : function() { return b; }) + : (b = q.length, function(t) { + for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t); + return s.join(""); + }); } -var d3_interpolate_number = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g; +var d3_interpolate_numberA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, + d3_interpolate_numberB = new RegExp(d3_interpolate_numberA.source, "g"); d3.interpolate = d3_interpolate; @@ -5401,7 +5512,8 @@ d3.interpolators = [ var t = typeof b; return (t === "string" ? (d3_rgb_names.has(b) || /^(#|rgb\(|hsl\()/.test(b) ? d3_interpolateRgb : d3_interpolateString) : b instanceof d3_Color ? d3_interpolateRgb - : t === "object" ? (Array.isArray(b) ? d3_interpolateArray : d3_interpolateObject) + : Array.isArray(b) ? d3_interpolateArray + : t === "object" && isNaN(b) ? d3_interpolateObject : d3_interpolateNumber)(a, b); } ]; @@ -5664,6 +5776,7 @@ d3_transitionPrototype.ease = function(value) { d3_transitionPrototype.delay = function(value) { var id = this.id; + if (arguments.length < 1) return this.node().__transition__[id].delay; return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { node.__transition__[id].delay = +value.call(node, node.__data__, i, j); } : (value = +value, function(node) { node.__transition__[id].delay = value; })); @@ -5671,6 +5784,7 @@ d3_transitionPrototype.delay = function(value) { d3_transitionPrototype.duration = function(value) { var id = this.id; + if (arguments.length < 1) return this.node().__transition__[id].duration; return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { node.__transition__[id].duration = Math.max(1, value.call(node, node.__data__, i, j)); } : (value = Math.max(1, value), function(node) { node.__transition__[id].duration = value; })); @@ -5932,8 +6046,14 @@ function d3_html(request) { d3.xml = d3_xhrType(function(request) { return request.responseXML; }); - return d3; -})(); + if (typeof define === "function" && define.amd) { + define(d3); + } else if (typeof module === "object" && module.exports) { + module.exports = d3; + } else { + this.d3 = d3; + } +}(); d3.combobox = function() { var event = d3.dispatch('accept'), data = [], @@ -6930,7 +7050,7 @@ var JXON = new (function () { /** * @license * Lo-Dash 2.3.0 (Custom Build) - * Build: `lodash include="any,assign,bind,clone,compact,contains,debounce,difference,each,every,extend,filter,find,first,forEach,groupBy,indexOf,intersection,isEmpty,isEqual,isFunction,keys,last,map,omit,pairs,pluck,reject,some,throttle,union,uniq,unique,values,without,flatten,value,chain,cloneDeep,merge" exports="global,node"` + * Build: `lodash --debug --output js/lib/lodash.js include="any,assign,bind,clone,compact,contains,debounce,difference,each,every,extend,filter,find,first,forEach,groupBy,indexOf,intersection,isEmpty,isEqual,isFunction,keys,last,map,omit,pairs,pluck,reject,some,throttle,union,uniq,unique,values,without,flatten,value,chain,cloneDeep,merge,pick" exports="global,node"` * Copyright 2012-2013 The Dojo Foundation * Based on Underscore.js 1.5.2 * Copyright 2009-2013 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors @@ -9233,6 +9353,57 @@ var JXON = new (function () { return result; } + /** + * Creates a shallow clone of `object` composed of the specified properties. + * Property names may be specified as individual arguments or as arrays of + * property names. If a callback is provided it will be executed for each + * property of `object` picking the properties the callback returns truey + * for. The callback is bound to `thisArg` and invoked with three arguments; + * (value, key, object). + * + * @static + * @memberOf _ + * @category Objects + * @param {Object} object The source object. + * @param {Function|...string|string[]} [callback] The function called per + * iteration or property names to pick, specified as individual property + * names or arrays of property names. + * @param {*} [thisArg] The `this` binding of `callback`. + * @returns {Object} Returns an object composed of the picked properties. + * @example + * + * _.pick({ 'name': 'fred', '_userid': 'fred1' }, 'name'); + * // => { 'name': 'fred' } + * + * _.pick({ 'name': 'fred', '_userid': 'fred1' }, function(value, key) { + * return key.charAt(0) != '_'; + * }); + * // => { 'name': 'fred' } + */ + function pick(object, callback, thisArg) { + var result = {}; + if (typeof callback != 'function') { + var index = -1, + props = baseFlatten(arguments, true, false, 1), + length = isObject(object) ? props.length : 0; + + while (++index < length) { + var key = props[index]; + if (key in object) { + result[key] = object[key]; + } + } + } else { + callback = lodash.createCallback(callback, thisArg, 3); + forIn(object, function(value, key, object) { + if (callback(value, key, object)) { + result[key] = value; + } + }); + } + return result; + } + /** * Creates an array composed of the own enumerable property values of `object`. * @@ -10759,6 +10930,7 @@ var JXON = new (function () { lodash.merge = merge; lodash.omit = omit; lodash.pairs = pairs; + lodash.pick = pick; lodash.pluck = pluck; lodash.reject = reject; lodash.throttle = throttle; @@ -16038,52 +16210,7 @@ window.iD = function () { }; /* Projection */ - function rawMercator() { - var project = d3.geo.mercator.raw, - k = 512 / Math.PI, // scale - x = 0, y = 0, // translate - clipExtent = [[0, 0], [0, 0]]; - - function projection(point) { - point = project(point[0] * Math.PI / 180, point[1] * Math.PI / 180); - return [point[0] * k + x, y - point[1] * k]; - } - - projection.invert = function(point) { - point = project.invert((point[0] - x) / k, (y - point[1]) / k); - return point && [point[0] * 180 / Math.PI, point[1] * 180 / Math.PI]; - }; - - projection.scale = function(_) { - if (!arguments.length) return k; - k = +_; - return projection; - }; - - projection.translate = function(_) { - if (!arguments.length) return [x, y]; - x = +_[0]; - y = +_[1]; - return projection; - }; - - projection.clipExtent = function(_) { - if (!arguments.length) return clipExtent; - clipExtent = _; - return projection; - }; - - projection.stream = d3.geo.transform({ - point: function(x, y) { - x = projection([x, y]); - this.stream.point(x[0], x[1]); - } - }).stream; - - return projection; - } - - context.projection = rawMercator(); + context.projection = iD.geo.RawMercator(); /* Background */ var background = iD.Background(context); @@ -16151,7 +16278,7 @@ window.iD = function () { return d3.rebind(context, dispatch, 'on'); }; -iD.version = '1.3.8'; +iD.version = '1.4.0'; (function() { var detected = {}; @@ -16622,6 +16749,13 @@ iD.geo.interp = function(p1, p2, t) { p1[1] + (p2[1] - p1[1]) * t]; }; +// 2D cross product of OA and OB vectors, i.e. z-component of their 3D cross product. +// Returns a positive value, if OAB makes a counter-clockwise turn, +// negative for clockwise turn, and zero if the points are collinear. +iD.geo.cross = function(o, a, b) { + return (a[0] - o[0]) * (b[1] - o[1]) - (a[1] - o[1]) * (b[0] - o[0]); +}; + // http://jsperf.com/id-dist-optimization iD.geo.euclideanDistance = function(a, b) { var x = a[0] - b[0], y = a[1] - b[1]; @@ -16639,6 +16773,14 @@ iD.geo.edgeEqual = function(a, b) { (a[0] === b[1] && a[1] === b[0]); }; +// Return the counterclockwise angle in the range (-pi, pi) +// between the positive X axis and the line intersecting a and b. +iD.geo.angle = function(a, b, projection) { + a = projection(a.loc); + b = projection(b.loc); + return Math.atan2(b[1] - a[1], b[0] - a[0]); +}; + // Choose the edge with the minimal distance from `point` to its orthogonal // projection onto that edge, if such a projection exists, or the distance to // the closest vertex on that edge. Returns an object with the `index` of the @@ -16804,6 +16946,146 @@ _.extend(iD.geo.Extent.prototype, { return [this[0][0], this[0][1], this[1][0], this[1][1]].join(','); } }); +iD.geo.Turn = function(turn) { + if (!(this instanceof iD.geo.Turn)) + return new iD.geo.Turn(turn); + _.extend(this, turn); +}; + +iD.geo.Intersection = function(graph, vertexId) { + var vertex = graph.entity(vertexId), + highways = []; + + // Pre-split ways that would need to be split in + // order to add a restriction. The real split will + // happen when the restriction is added. + graph.parentWays(vertex).forEach(function(way) { + if (!way.tags.highway || way.isArea() || way.isDegenerate()) + return; + + if (way.affix(vertexId)) { + highways.push(way); + } else { + var idx = _.indexOf(way.nodes, vertex.id, 1), + wayA = iD.Way({id: way.id + '-a', tags: way.tags, nodes: way.nodes.slice(0, idx + 1)}), + wayB = iD.Way({id: way.id + '-b', tags: way.tags, nodes: way.nodes.slice(idx)}); + + graph = graph.replace(wayA); + graph = graph.replace(wayB); + + highways.push(wayA); + highways.push(wayB); + } + }); + + var intersection = { + highways: highways, + graph: graph + }; + + intersection.turns = function(fromNodeID) { + if (!fromNodeID) + return []; + + var way = _.find(highways, function(way) { return way.contains(fromNodeID); }); + if (way.first() === vertex.id && way.tags.oneway === 'yes') + return []; + if (way.last() === vertex.id && way.tags.oneway === '-1') + return []; + + function withRestriction(turn) { + graph.parentRelations(graph.entity(turn.from.way)).forEach(function(relation) { + if (relation.tags.type !== 'restriction') + return; + + var f = relation.memberByRole('from'), + t = relation.memberByRole('to'), + v = relation.memberByRole('via'); + + if (f && f.id === turn.from.way && + v && v.id === turn.via.node && + t && t.id === turn.to.way) { + turn.restriction = relation.id; + } else if (/^only_/.test(relation.tags.restriction) && + f && f.id === turn.from.way && + v && v.id === turn.via.node && + t && t.id !== turn.to.way) { + turn.restriction = relation.id; + turn.indirect_restriction = true; + } + }); + + return iD.geo.Turn(turn); + } + + var from = { + node: way.nodes[way.first() === vertex.id ? 1 : way.nodes.length - 2], + way: way.id.split(/-(a|b)/)[0] + }, + via = {node: vertex.id}, + turns = []; + + highways.forEach(function(parent) { + if (parent === way) + return; + + var index = parent.nodes.indexOf(vertex.id); + + // backward + if (parent.first() !== vertex.id && parent.tags.oneway !== 'yes') { + turns.push(withRestriction({ + from: from, + via: via, + to: {node: parent.nodes[index - 1], way: parent.id.split(/-(a|b)/)[0]} + })); + } + + // forward + if (parent.last() !== vertex.id && parent.tags.oneway !== '-1') { + turns.push(withRestriction({ + from: from, + via: via, + to: {node: parent.nodes[index + 1], way: parent.id.split(/-(a|b)/)[0]} + })); + } + }); + + // U-turn + if (way.tags.oneway !== 'yes' && way.tags.oneway !== '-1') { + turns.push(withRestriction({ + from: from, + via: via, + to: from, + u: true + })); + } + + return turns; + }; + + return intersection; +}; + +iD.geo.inferRestriction = function(from, via, to, projection) { + var angle = iD.geo.angle(via, from, projection) - + iD.geo.angle(via, to, projection); + + angle = angle * 180 / Math.PI; + + while (angle < 0) + angle += 360; + + if (angle < 23) + return 'no_u_turn'; + if (angle < 158) + return 'no_right_turn'; + if (angle < 202) + return 'no_straight_on'; + if (angle < 336) + return 'no_left_turn'; + + return 'no_u_turn'; +}; // For fixing up rendering of multipolygons with tags on the outer member. // https://github.com/openstreetmap/iD/issues/613 iD.geo.isSimpleMultipolygonOuterMember = function(entity, graph) { @@ -16939,67 +17221,55 @@ iD.geo.joinWays = function(array, graph) { return joined; }; -iD.geo.turns = function(graph, entityID) { - var way = graph.entity(entityID); - if (way.type !== 'way' || !way.tags.highway || way.isArea()) - return []; - - function withRestriction(turn) { - graph.parentRelations(turn.from).forEach(function(relation) { - if (relation.tags.type !== 'restriction') - return; - - var f = relation.memberByRole('from'), - t = relation.memberByRole('to'), - v = relation.memberByRole('via'); - - if (f && f.id === turn.from.id && - t && t.id === turn.to.id && - v && v.id === turn.via.id) { - turn.restriction = relation; - } - }); +/* + Bypasses features of D3's default projection stream pipeline that are unnecessary: + * Antimeridian clipping + * Spherical rotation + * Resampling +*/ +iD.geo.RawMercator = function () { + var project = d3.geo.mercator.raw, + k = 512 / Math.PI, // scale + x = 0, y = 0, // translate + clipExtent = [[0, 0], [0, 0]]; - return turn; + function projection(point) { + point = project(point[0] * Math.PI / 180, point[1] * Math.PI / 180); + return [point[0] * k + x, y - point[1] * k]; } - var turns = []; + projection.invert = function(point) { + point = project.invert((point[0] - x) / k, (y - point[1]) / k); + return point && [point[0] * 180 / Math.PI, point[1] * 180 / Math.PI]; + }; - [way.first(), way.last()].forEach(function(nodeID) { - var node = graph.entity(nodeID); - graph.parentWays(node).forEach(function(parent) { - if (parent === way || parent.isDegenerate() || !parent.tags.highway) - return; - if (way.first() === node.id && way.tags.oneway === 'yes') - return; - if (way.last() === node.id && way.tags.oneway === '-1') - return; + projection.scale = function(_) { + if (!arguments.length) return k; + k = +_; + return projection; + }; - var index = parent.nodes.indexOf(node.id); + projection.translate = function(_) { + if (!arguments.length) return [x, y]; + x = +_[0]; + y = +_[1]; + return projection; + }; - // backward - if (parent.first() !== node.id && parent.tags.oneway !== 'yes') { - turns.push(withRestriction({ - from: way, - to: parent, - via: node, - toward: graph.entity(parent.nodes[index - 1]) - })); - } + projection.clipExtent = function(_) { + if (!arguments.length) return clipExtent; + clipExtent = _; + return projection; + }; - // forward - if (parent.last() !== node.id && parent.tags.oneway !== '-1') { - turns.push(withRestriction({ - from: way, - to: parent, - via: node, - toward: graph.entity(parent.nodes[index + 1]) - })); - } - }); - }); + projection.stream = d3.geo.transform({ + point: function(x, y) { + x = projection([x, y]); + this.stream.point(x[0], x[1]); + } + }).stream; - return turns; + return projection; }; iD.actions = {}; iD.actions.AddEntity = function(way) { @@ -17092,12 +17362,17 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { maxAngle = (maxAngle || 20) * Math.PI / 180; var action = function(graph) { - var way = graph.entity(wayId), - nodes = _.uniq(graph.childNodes(way)), + var way = graph.entity(wayId); + + if (!way.isConvex(graph)) { + graph = action.makeConvex(graph); + } + + var nodes = _.uniq(graph.childNodes(way)), keyNodes = nodes.filter(function(n) { return graph.parentWays(n).length !== 1; }), points = nodes.map(function(n) { return projection(n.loc); }), keyPoints = keyNodes.map(function(n) { return projection(n.loc); }), - centroid = d3.geom.polygon(points).centroid(), + centroid = (points.length === 2) ? iD.geo.interp(points[0], points[1], 0.5) : d3.geom.polygon(points).centroid(), radius = d3.median(points, function(p) { return iD.geo.euclideanDistance(centroid, p); }), sign = d3.geom.polygon(points).area() > 0 ? 1 : -1, ids; @@ -17118,16 +17393,19 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { // key points and nodes are those connected to the ways, // they are projected onto the circle, inbetween nodes are moved - // to constant internals between key nodes, extra inbetween nodes are + // to constant intervals between key nodes, extra inbetween nodes are // added if necessary. for (var i = 0; i < keyPoints.length; i++) { var nextKeyNodeIndex = (i + 1) % keyNodes.length, - startNodeIndex = nodes.indexOf(keyNodes[i]), - endNodeIndex = nodes.indexOf(keyNodes[nextKeyNodeIndex]), + startNode = keyNodes[i], + endNode = keyNodes[nextKeyNodeIndex], + startNodeIndex = nodes.indexOf(startNode), + endNodeIndex = nodes.indexOf(endNode), numberNewPoints = -1, indexRange = endNodeIndex - startNodeIndex, distance, totalAngle, eachAngle, startAngle, endAngle, - angle, loc, node, j; + angle, loc, node, j, + inBetweenNodes = []; if (indexRange < 0) { indexRange += nodes.length; @@ -17135,6 +17413,7 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { // position this key node distance = iD.geo.euclideanDistance(centroid, keyPoints[i]); + if (distance === 0) { distance = 1e-4; } keyPoints[i] = [ centroid[0] + (keyPoints[i][0] - centroid[0]) / distance * radius, centroid[1] + (keyPoints[i][1] - centroid[1]) / distance * radius]; @@ -17146,7 +17425,7 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { totalAngle = endAngle - startAngle; // detects looping around -pi/pi - if (totalAngle*sign > 0) { + if (totalAngle * sign > 0) { totalAngle = -sign * (2 * Math.PI - Math.abs(totalAngle)); } @@ -17177,7 +17456,40 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { graph = graph.replace(node); nodes.splice(endNodeIndex + j, 0, node); + inBetweenNodes.push(node.id); } + + // Check for other ways that share these keyNodes.. + // If keyNodes are adjacent in both ways, + // we can add inBetween nodes to that shared way too.. + if (indexRange === 1 && inBetweenNodes.length) { + var startIndex1 = way.nodes.lastIndexOf(startNode.id), + endIndex1 = way.nodes.lastIndexOf(endNode.id), + wayDirection1 = (endIndex1 - startIndex1); + if (wayDirection1 < -1) { wayDirection1 = 1;} + + /*jshint -W083 */ + _.each(_.without(graph.parentWays(keyNodes[i]), way), function(sharedWay) { + if (sharedWay.areAdjacent(startNode.id, endNode.id)) { + var startIndex2 = sharedWay.nodes.lastIndexOf(startNode.id), + endIndex2 = sharedWay.nodes.lastIndexOf(endNode.id), + wayDirection2 = (endIndex2 - startIndex2), + insertAt = endIndex2; + if (wayDirection2 < -1) { wayDirection2 = 1;} + + if (wayDirection1 !== wayDirection2) { + inBetweenNodes.reverse(); + insertAt = startIndex2; + } + for (j = 0; j < inBetweenNodes.length; j++) { + sharedWay = sharedWay.addNode(inBetweenNodes[j], insertAt + j); + } + graph = graph.replace(sharedWay); + } + }); + /*jshint +W083 */ + } + } // update the way to have all the new nodes @@ -17190,6 +17502,38 @@ iD.actions.Circularize = function(wayId, projection, maxAngle) { return graph; }; + action.makeConvex = function(graph) { + var way = graph.entity(wayId), + nodes = _.uniq(graph.childNodes(way)), + points = nodes.map(function(n) { return projection(n.loc); }), + sign = d3.geom.polygon(points).area() > 0 ? 1 : -1, + hull = d3.geom.hull(points); + + // D3 convex hulls go counterclockwise.. + if (sign === -1) { + nodes.reverse(); + points.reverse(); + } + + for (var i = 0; i < hull.length - 1; i++) { + var startIndex = points.indexOf(hull[i]), + endIndex = points.indexOf(hull[i+1]), + indexRange = (endIndex - startIndex); + + if (indexRange < 0) { + indexRange += nodes.length; + } + + // move interior nodes to the surface of the convex hull.. + for (var j = 1; j < indexRange; j++) { + var point = iD.geo.interp(hull[i], hull[i+1], j / indexRange), + node = nodes[(j + startIndex) % nodes.length].move(projection.invert(point)); + graph = graph.replace(node); + } + } + return graph; + }; + action.disabled = function(graph) { if (!graph.entity(wayId).isClosed()) return 'not_closed'; @@ -17460,41 +17804,52 @@ iD.actions.Disconnect = function(nodeId, newNodeId) { var action = function(graph) { var node = graph.entity(nodeId), - replacements = action.replacements(graph); + connections = action.connections(graph); + + connections.forEach(function(connection) { + var way = graph.entity(connection.wayID), + newNode = iD.Node({id: newNodeId, loc: node.loc, tags: node.tags}); - replacements.forEach(function(replacement) { - var newNode = iD.Node({id: newNodeId, loc: node.loc, tags: node.tags}); graph = graph.replace(newNode); - graph = graph.replace(graph.entity(replacement.wayID).updateNode(newNode.id, replacement.index)); + if (connection.index === 0 && way.isArea()) { + // replace shared node with shared node.. + graph = graph.replace(way.replaceNode(way.nodes[0], newNode.id)); + } else { + // replace shared node with multiple new nodes.. + graph = graph.replace(way.updateNode(newNode.id, connection.index)); + } }); return graph; }; - action.replacements = function(graph) { + action.connections = function(graph) { var candidates = [], keeping = false, - parents = graph.parentWays(graph.entity(nodeId)); + parentWays = graph.parentWays(graph.entity(nodeId)); - parents.forEach(function(parent) { - if (wayIds && wayIds.indexOf(parent.id) === -1) { + parentWays.forEach(function(way) { + if (wayIds && wayIds.indexOf(way.id) === -1) { keeping = true; return; } - - parent.nodes.forEach(function(waynode, index) { - if (waynode === nodeId) { - candidates.push({wayID: parent.id, index: index}); - } - }); + if (way.isArea() && (way.nodes[0] === nodeId)) { + candidates.push({wayID: way.id, index: 0}); + } else { + way.nodes.forEach(function(waynode, index) { + if (waynode === nodeId) { + candidates.push({wayID: way.id, index: index}); + } + }); + } }); return keeping ? candidates : candidates.slice(1); }; action.disabled = function(graph) { - var replacements = action.replacements(graph); - if (replacements.length === 0 || (wayIds && wayIds.length !== replacements.length)) + var connections = action.connections(graph); + if (connections.length === 0 || (wayIds && wayIds.length !== connections.length)) return 'not_connected'; }; @@ -17960,6 +18315,95 @@ iD.actions.Orthogonalize = function(wayId, projection) { return action; }; +// Create a restriction relation for `turn`, which must have the following structure: +// +// { +// from: { node: , way: }, +// via: { node: }, +// to: { node: , way: }, +// restriction: <'no_right_turn', 'no_left_turn', etc.> +// } +// +// This specifies a restriction of type `restriction` when traveling from +// `from.node` in `from.way` toward `to.node` in `to.way` via `via.node`. +// (The action does not check that these entities form a valid intersection.) +// +// If `restriction` is not provided, it is automatically determined by the +// angle of the turn: +// +// 0-23 degrees: no_u_turn +// 23-158 degrees: no_right_turn +// 158-202 degrees: no_straight_on +// 202-326 degrees: no_left_turn +// 336-360 degrees: no_u_turn +// +// If necessary, the `from` and `to` ways are split. In these cases, `from.node` +// and `to.node` are used to determine which portion of the split ways become +// members of the restriction. +// +// For testing convenience, accepts an ID to assign to the new relation. +// Normally, this will be undefined and the relation will automatically +// be assigned a new ID. +// +iD.actions.RestrictTurn = function(turn, projection, restrictionId) { + return function(graph) { + var from = graph.entity(turn.from.way), + via = graph.entity(turn.via.node), + to = graph.entity(turn.to.way); + + function split(toOrFrom) { + var newID = toOrFrom.newID || iD.Way().id; + graph = iD.actions.Split(via.id, [newID]) + .limitWays([toOrFrom.way])(graph); + + var a = graph.entity(newID), + b = graph.entity(toOrFrom.way); + + if (a.nodes.indexOf(toOrFrom.node) !== -1) { + return [a, b]; + } else { + return [b, a]; + } + } + + if (!from.affix(via.id)) { + if (turn.from.node === turn.to.node) { + // U-turn + from = to = split(turn.from)[0]; + } else if (turn.from.way === turn.to.way) { + // Straight-on + var s = split(turn.from); + from = s[0]; + to = s[1]; + } else { + // Other + from = split(turn.from)[0]; + } + } + + if (!to.affix(via.id)) { + to = split(turn.to)[0]; + } + + return graph.replace(iD.Relation({ + id: restrictionId, + tags: { + type: 'restriction', + restriction: turn.restriction || + iD.geo.inferRestriction( + graph.entity(turn.from.node), + via, + graph.entity(turn.to.node), + projection) + }, + members: [ + {id: from.id, type: 'way', role: 'from'}, + {id: via.id, type: 'node', role: 'via'}, + {id: to.id, type: 'way', role: 'to'} + ] + })); + }; +}; /* Order the nodes of a way in reverse order and reverse any direction dependent tags other than `oneway`. (We assume that correcting a backwards oneway is the primary @@ -18334,6 +18778,29 @@ iD.actions.Straighten = function(wayId, projection) { return action; }; +// Remove the effects of `turn.restriction` on `turn`, which must have the +// following structure: +// +// { +// from: { node: , way: }, +// via: { node: }, +// to: { node: , way: }, +// restriction: +// } +// +// In the simple case, `restriction` is a reference to a `no_*` restriction +// on the turn itself. In this case, it is simply deleted. +// +// The more complex case is where `restriction` references an `only_*` +// restriction on a different turn in the same intersection. In that case, +// that restriction is also deleted, but at the same time restrictions on +// the turns other than the first two are created. +// +iD.actions.UnrestrictTurn = function(turn) { + return function(graph) { + return iD.actions.DeleteRelation(turn.restriction)(graph); + }; +}; iD.behavior = {}; iD.behavior.AddWay = function(context) { var event = d3.dispatch('start', 'startFromWay', 'startFromNode'), @@ -19137,8 +19604,6 @@ iD.behavior.Lasso = function(context) { .on('mouseup.lasso', mouseup); d3.event.stopPropagation(); - d3.event.preventDefault(); - } } @@ -20360,8 +20825,10 @@ iD.operations.Circularize = function(selectedIDs, context) { }; operation.available = function() { + var entity = context.entity(entityId); return selectedIDs.length === 1 && - context.entity(entityId).type === 'way'; + entity.type === 'way' && + _.uniq(entity.nodes).length > 1; }; operation.disabled = function() { @@ -20478,15 +20945,15 @@ iD.operations.Delete = function(selectedIDs, context) { } } - context.perform( - action, - annotation); - if (nextSelectedID && context.hasEntity(nextSelectedID)) { context.enter(iD.modes.Select(context, [nextSelectedID])); } else { context.enter(iD.modes.Browse(context)); } + + context.perform( + action, + annotation); }; operation.available = function() { @@ -20839,6 +21306,7 @@ iD.areaKeys = { "bench": true, "clock": true, "drinking_water": true, + "parking_entrance": true, "post_box": true, "telephone": true, "vending_machine": true, @@ -21124,7 +21592,7 @@ iD.areaKeys = { connection.changesetTags = function(comment, imageryUsed) { var tags = { - imagery_used: imageryUsed.join(';'), + imagery_used: imageryUsed.join(';').substr(0, 255), created_by: 'iD ' + iD.version }; @@ -21606,6 +22074,10 @@ iD.Entity.prototype = { }); }, + isHighwayIntersection: function() { + return false; + }, + deprecatedTags: function() { var tags = _.pairs(this.tags); var deprecated = {}; @@ -22254,6 +22726,14 @@ _.extend(iD.Node.prototype, { }); }, + isHighwayIntersection: function(resolver) { + return resolver.transient(this, 'isHighwayIntersection', function() { + return resolver.parentWays(this).filter(function(parent) { + return parent.tags.highway && parent.geometry(resolver) === 'line'; + }).length > 1; + }); + }, + asJXON: function(changeset_id) { var r = { node: { @@ -22277,6 +22757,38 @@ _.extend(iD.Node.prototype, { }; } }); +iD.oneWayTags = { + 'aerialway': { + 'chair_lift': true, + 'mixed_lift': true, + 't-bar': true, + 'j-bar': true, + 'platter': true, + 'rope_tow': true, + 'magic_carpet': true, + 'yes': true + }, + 'highway': { + 'motorway': true, + 'motorway_link': true + }, + 'junction': { + 'roundabout': true + }, + 'man_made': { + 'piste:halfpipe': true, + 'pipeline': true + }, + 'piste:type': { + 'downhill': true, + 'sled': true, + 'yes': true + }, + 'waterway': { + 'river': true, + 'stream': true + } +}; iD.Relation = iD.Entity.relation = function iD_Relation() { if (!(this instanceof iD_Relation)) { return (new iD_Relation()).initialize(arguments); @@ -22666,18 +23178,46 @@ _.extend(iD.Way.prototype, { }, isOneWay: function() { - return this.tags.oneway === 'yes' || - this.tags.oneway === '1' || - this.tags.oneway === '-1' || - this.tags.waterway === 'river' || - this.tags.waterway === 'stream' || - this.tags.junction === 'roundabout'; + // explicit oneway tag.. + if (['yes', '1', '-1'].indexOf(this.tags.oneway) !== -1) { return true; } + if (['no', '0'].indexOf(this.tags.oneway) !== -1) { return false; } + + // implied oneway tag.. + for (var key in this.tags) { + if (key in iD.oneWayTags && (this.tags[key] in iD.oneWayTags[key])) + return true; + } + return false; }, isClosed: function() { return this.nodes.length > 0 && this.first() === this.last(); }, + isConvex: function(resolver) { + if (!this.isClosed() || this.isDegenerate()) return null; + + var nodes = _.uniq(resolver.childNodes(this)), + coords = _.pluck(nodes, 'loc'), + curr = 0, prev = 0; + + for (var i = 0; i < coords.length; i++) { + var o = coords[(i+1) % coords.length], + a = coords[i], + b = coords[(i+2) % coords.length], + res = iD.geo.cross(o, a, b); + + curr = (res > 0) ? 1 : (res < 0) ? -1 : 0; + if (curr === 0) { + continue; + } else if (prev && curr !== prev) { + return false; + } + prev = curr; + } + return true; + }, + isArea: function() { if (this.tags.area === 'yes') return true; @@ -23398,30 +23938,7 @@ iD.Map = function(context) { if (difference) { var complete = difference.complete(map.extent()); all = _.compact(_.values(complete)); - filter = function(d) { - if (d.type === 'midpoint') { - - var a = d.edge[0], - b = d.edge[1]; - - // redraw a midpoint if it needs to be - // - moved (either edge node moved) - // - deleted (edge nodes not consecutive in any parent way) - if (a in complete || b in complete) return true; - - var parentsWays = graph.parentWays({ id: a }); - for (var i = 0; i < parentsWays.length; i++) { - var nodes = parentsWays[i].nodes; - for (var n = 0; n < nodes.length; n++) { - if (nodes[n] === a && (nodes[n - 1] === b || nodes[n + 1] === b)) return false; - } - } - return true; - - } else { - return d.id in complete; - } - }; + filter = function(d) { return d.id in complete; }; } else if (extent) { all = context.intersects(map.extent().intersection(extent)); @@ -23997,6 +24514,7 @@ iD.svg.Areas = function(projection) { beach: 'beach', scrub: 'scrub', construction: 'construction', + military: 'construction', cemetery: 'cemetery', grave_yard: 'cemetery', meadow: 'meadow', @@ -24093,6 +24611,135 @@ iD.svg.Areas = function(projection) { .attr('d', path); }; }; +/* + A standalone SVG element that contains only a `defs` sub-element. To be + used once globally, since defs IDs must be unique within a document. +*/ +iD.svg.Defs = function(context) { + function autosize(image) { + var img = document.createElement('img'); + img.src = image.attr('xlink:href'); + img.onload = function() { + image.attr({ + width: img.width, + height: img.height + }); + }; + } + + function SpriteDefinition(id, href, data) { + return function(defs) { + defs.append('image') + .attr('id', id) + .attr('xlink:href', href) + .call(autosize); + + defs.selectAll() + .data(data) + .enter().append('use') + .attr('id', function(d) { return d.key; }) + .attr('transform', function(d) { return 'translate(-' + d.value[0] + ',-' + d.value[1] + ')'; }) + .attr('xlink:href', '#' + id); + }; + } + + return function (selection) { + var defs = selection.append('defs'); + + defs.append('marker') + .attr({ + id: 'oneway-marker', + viewBox: '0 0 10 10', + refY: 2.5, + refX: 5, + markerWidth: 2, + markerHeight: 2, + orient: 'auto' + }) + .append('path') + .attr('d', 'M 5 3 L 0 3 L 0 2 L 5 2 L 5 0 L 10 2.5 L 5 5 z'); + + var patterns = defs.selectAll('pattern') + .data([ + // pattern name, pattern image name + ['wetland', 'wetland'], + ['construction', 'construction'], + ['cemetery', 'cemetery'], + ['orchard', 'orchard'], + ['farmland', 'farmland'], + ['beach', 'dots'], + ['scrub', 'dots'], + ['meadow', 'dots'] + ]) + .enter() + .append('pattern') + .attr({ + id: function (d) { + return 'pattern-' + d[0]; + }, + width: 32, + height: 32, + patternUnits: 'userSpaceOnUse' + }); + + patterns.append('rect') + .attr({ + x: 0, + y: 0, + width: 32, + height: 32, + 'class': function (d) { + return 'pattern-color-' + d[0]; + } + }); + + patterns.append('image') + .attr({ + x: 0, + y: 0, + width: 32, + height: 32 + }) + .attr('xlink:href', function (d) { + return context.imagePath('pattern/' + d[1] + '.png'); + }); + + defs.selectAll() + .data([12, 18, 20, 32, 45]) + .enter().append('clipPath') + .attr('id', function (d) { + return 'clip-square-' + d; + }) + .append('rect') + .attr('x', 0) + .attr('y', 0) + .attr('width', function (d) { + return d; + }) + .attr('height', function (d) { + return d; + }); + + var maki = []; + _.forEach(iD.data.featureIcons, function (dimensions, name) { + if (dimensions['12'] && dimensions['18'] && dimensions['24']) { + maki.push({key: 'maki-' + name + '-12', value: dimensions['12']}); + maki.push({key: 'maki-' + name + '-18', value: dimensions['18']}); + maki.push({key: 'maki-' + name + '-24', value: dimensions['24']}); + } + }); + + defs.call(SpriteDefinition( + 'sprite', + context.imagePath('sprite.svg'), + d3.entries(iD.data.operations))); + + defs.call(SpriteDefinition( + 'maki-sprite', + context.imagePath('maki-sprite.png'), + maki)); + }; +}; iD.svg.Labels = function(projection, context) { var path = d3.geo.path().projection(projection); @@ -24647,39 +25294,50 @@ iD.svg.Midpoints = function(projection, context) { for (var i = 0; i < entities.length; i++) { var entity = entities[i]; - if (entity.type !== 'way') continue; - if (context.selectedIDs().indexOf(entity.id) < 0) continue; + if (entity.type !== 'way') + continue; + if (!filter(entity)) + continue; + if (context.selectedIDs().indexOf(entity.id) < 0) + continue; var nodes = graph.childNodes(entity); - - // skip the last node because it is always repeated for (var j = 0; j < nodes.length - 1; j++) { var a = nodes[j], b = nodes[j + 1], id = [a.id, b.id].sort().join('-'); - // Redraw midpoints in two cases: - // 1. One of the two endpoint nodes changed (e.g. was moved). - // 2. A node was deleted. The midpoint between the two new - // endpoints needs to be redrawn. In this case only the - // way will be in the diff. - if (!midpoints[id] && (filter(a) || filter(b) || filter(entity))) { + if (midpoints[id]) { + midpoints[id].parents.push(entity); + } else { var loc = iD.geo.interp(a.loc, b.loc, 0.5); if (extent.intersects(loc) && iD.geo.euclideanDistance(projection(a.loc), projection(b.loc)) > 40) { midpoints[id] = { type: 'midpoint', id: id, loc: loc, - edge: [a.id, b.id] + edge: [a.id, b.id], + parents: [entity] }; } } } } + function midpointFilter(d) { + if (midpoints[d.id]) + return true; + + for (var i = 0; i < d.parents.length; i++) + if (filter(d.parents[i])) + return true; + + return false; + } + var groups = surface.select('.layer-hit').selectAll('g.midpoint') - .filter(filter) + .filter(midpointFilter) .data(_.values(midpoints), function(d) { return d.id; }); var group = groups.enter() @@ -24773,192 +25431,8 @@ iD.svg.Points = function(projection, context) { return drawPoints; }; -iD.svg.Restrictions = function(context) { - var projection = context.projection; - - function drawRestrictions(surface) { - var turns = drawRestrictions.turns(context.graph(), context.selectedIDs()); - - var groups = surface.select('.layer-hit').selectAll('g.restriction') - .data(turns, iD.Entity.key); - - var enter = groups.enter().append('g') - .attr('class', 'restriction'); - - enter.append('circle') - .attr('class', 'restriction') - .attr('r', 4); - - groups - .attr('transform', function(restriction) { - var via = context.entity(restriction.memberByRole('via').id); - return iD.svg.PointTransform(projection)(via); - }); - - groups.exit() - .remove(); - - return this; - } - - drawRestrictions.turns = function (graph, selectedIDs) { - if (selectedIDs.length !== 1) - return []; - - var from = graph.entity(selectedIDs[0]); - if (from.type !== 'way') - return []; - - return graph.parentRelations(from).filter(function(relation) { - var f = relation.memberById(from.id), - t = relation.memberByRole('to'), - v = relation.memberByRole('via'); - - return relation.tags.type === 'restriction' && f.role === 'from' && - t && t.type === 'way' && graph.hasEntity(t.id) && - v && v.type === 'node' && graph.hasEntity(v.id) && - !graph.entity(t.id).isDegenerate() && - !graph.entity(f.id).isDegenerate() && - graph.entity(t.id).affix(v.id) && - graph.entity(f.id).affix(v.id); - }); - }; - - drawRestrictions.datum = function(graph, from, restriction, projection) { - var to = graph.entity(restriction.memberByRole('to').id), - a = graph.entity(restriction.memberByRole('via').id), - b; - - if (to.first() === a.id) { - b = graph.entity(to.nodes[1]); - } else { - b = graph.entity(to.nodes[to.nodes.length - 2]); - } - - a = projection(a.loc); - b = projection(b.loc); - - return { - from: from, - to: to, - restriction: restriction, - angle: Math.atan2(b[1] - a[1], b[0] - a[0]) - }; - }; - - return drawRestrictions; -}; -iD.svg.Surface = function(context) { - function autosize(image) { - var img = document.createElement('img'); - img.src = image.attr('xlink:href'); - img.onload = function() { - image.attr({ - width: img.width, - height: img.height - }); - }; - } - - function SpriteDefinition(id, href, data) { - return function(defs) { - defs.append('image') - .attr('id', id) - .attr('xlink:href', href) - .call(autosize); - - defs.selectAll() - .data(data) - .enter().append('use') - .attr('id', function(d) { return d.key; }) - .attr('transform', function(d) { return 'translate(-' + d.value[0] + ',-' + d.value[1] + ')'; }) - .attr('xlink:href', '#' + id); - }; - } - - return function drawSurface(selection) { - var defs = selection.append('defs'); - - defs.append('marker') - .attr({ - id: 'oneway-marker', - viewBox: '0 0 10 10', - refY: 2.5, - refX: 5, - markerWidth: 2, - markerHeight: 2, - orient: 'auto' - }) - .append('path') - .attr('d', 'M 5 3 L 0 3 L 0 2 L 5 2 L 5 0 L 10 2.5 L 5 5 z'); - - var patterns = defs.selectAll('pattern') - .data([ - // pattern name, pattern image name - ['wetland', 'wetland'], - ['construction', 'construction'], - ['cemetery', 'cemetery'], - ['orchard', 'orchard'], - ['farmland', 'farmland'], - ['beach', 'dots'], - ['scrub', 'dots'], - ['meadow', 'dots']]) - .enter() - .append('pattern') - .attr({ - id: function(d) { return 'pattern-' + d[0]; }, - width: 32, - height: 32, - patternUnits: 'userSpaceOnUse' - }); - - patterns.append('rect') - .attr({ - x: 0, - y: 0, - width: 32, - height: 32, - 'class': function(d) { return 'pattern-color-' + d[0]; } - }); - - patterns.append('image') - .attr({ - x: 0, - y: 0, - width: 32, - height: 32 - }) - .attr('xlink:href', function(d) { return context.imagePath('pattern/' + d[1] + '.png'); }); - - defs.selectAll() - .data([12, 18, 20]) - .enter().append('clipPath') - .attr('id', function(d) { return 'clip-square-' + d; }) - .append('rect') - .attr('x', 0) - .attr('y', 0) - .attr('width', function(d) { return d; }) - .attr('height', function(d) { return d; }); - - var maki = []; - _.forEach(iD.data.featureIcons, function(dimensions, name) { - if (dimensions['12'] && dimensions['18'] && dimensions['24']) { - maki.push({key: 'maki-' + name + '-12', value: dimensions['12']}); - maki.push({key: 'maki-' + name + '-18', value: dimensions['18']}); - maki.push({key: 'maki-' + name + '-24', value: dimensions['24']}); - } - }); - - defs.call(SpriteDefinition( - 'sprite', - context.imagePath('sprite.svg'), - d3.entries(iD.data.operations))); - - defs.call(SpriteDefinition( - 'maki-sprite', - context.imagePath('maki-sprite.png'), - maki)); - +iD.svg.Surface = function() { + return function (selection) { var layers = selection.selectAll('.layer') .data(['fill', 'shadow', 'casing', 'stroke', 'oneway', 'hit', 'halo', 'label']); @@ -24968,12 +25442,12 @@ iD.svg.Surface = function(context) { }; iD.svg.TagClasses = function() { var primary = [ - 'highway', 'railway', 'waterway', 'aeroway', 'motorway', - 'boundary', 'power', 'amenity', 'natural', 'landuse', - 'building', 'leisure', 'place' + 'building', 'highway', 'railway', 'waterway', 'aeroway', + 'motorway', 'boundary', 'power', 'amenity', 'natural', 'landuse', + 'leisure', 'place' ], secondary = [ - 'oneway', 'bridge', 'tunnel', 'construction' + 'oneway', 'bridge', 'tunnel', 'construction', 'embankment', 'cutting' ], tagClassRe = /^tag-/, tags = function(entity) { return entity.tags; }; @@ -25021,6 +25495,77 @@ iD.svg.TagClasses = function() { return tagClasses; }; +iD.svg.Turns = function(projection) { + return function(surface, graph, turns) { + function key(turn) { + return [turn.from.node + turn.via.node + turn.to.node].join('-'); + } + + function icon(turn) { + var u = turn.u ? '-u' : ''; + if (!turn.restriction) + return '#icon-restriction-yes' + u; + var restriction = graph.entity(turn.restriction).tags.restriction; + return '#icon-restriction-' + + (!turn.indirect_restriction && /^only_/.test(restriction) ? 'only' : 'no') + u; + } + + var groups = surface.select('.layer-hit').selectAll('g.turn') + .data(turns, key); + + // Enter + + var enter = groups.enter().append('g') + .attr('class', 'turn'); + + var nEnter = enter.filter(function (turn) { return !turn.u; }); + + nEnter.append('rect') + .attr('transform', 'translate(-12, -12)') + .attr('width', '45') + .attr('height', '25'); + + nEnter.append('use') + .attr('transform', 'translate(-12, -12)') + .attr('clip-path', 'url(#clip-square-45)'); + + var uEnter = enter.filter(function (turn) { return turn.u; }); + + uEnter.append('circle') + .attr('r', '16'); + + uEnter.append('use') + .attr('transform', 'translate(-16, -16)') + .attr('clip-path', 'url(#clip-square-32)'); + + // Update + + groups + .attr('transform', function (turn) { + var v = graph.entity(turn.via.node), + t = graph.entity(turn.to.node), + a = iD.geo.angle(v, t, projection), + p = projection(v.loc), + r = turn.u ? 0 : 60; + + return 'translate(' + (r * Math.cos(a) + p[0]) + ',' + (r * Math.sin(a) + p[1]) + ')' + + 'rotate(' + a * 180 / Math.PI + ')'; + }); + + groups.select('use') + .attr('xlink:href', icon); + + groups.select('rect'); + groups.select('circle'); + + // Exit + + groups.exit() + .remove(); + + return this; + }; +}; iD.svg.Vertices = function(projection, context) { var radiuses = { // z16-, z17, z18+, tagged @@ -25185,6 +25730,10 @@ iD.ui = function(context) { map.centerZoom([-77.02271, 38.90085], 20); } + container.append('svg') + .attr('id', 'defs') + .call(iD.svg.Defs(context)); + container.append('div') .attr('id', 'sidebar') .attr('class', 'col4') @@ -25499,7 +26048,8 @@ iD.ui.Background = function(context) { ['right', [-1, 0]], ['bottom', [0, 1]]], opacityDefault = (context.storage('background-opacity') !== null) ? - (+context.storage('background-opacity')) : 0.5; + (+context.storage('background-opacity')) : 0.5, + customTemplate = ''; // Can be 0 from <1.3.0 use or due to issue #1923. if (opacityDefault === 0) opacityDefault = 0.5; @@ -25539,15 +26089,20 @@ iD.ui.Background = function(context) { selectLayer(); } - function clickCustom() { + function editCustom() { d3.event.preventDefault(); - var template = window.prompt(t('background.custom_prompt')); - if (!template || template.indexOf('google.com') !== -1 || - template.indexOf('googleapis.com') !== -1 || - template.indexOf('google.ru') !== -1) { + var template = window.prompt(t('background.custom_prompt'), customTemplate); + if (!template || + template.indexOf('google.com') !== -1 || + template.indexOf('googleapis.com') !== -1 || + template.indexOf('google.ru') !== -1) { selectLayer(); return; } + setCustom(template); + } + + function setCustom(template) { context.background().baseLayerSource(iD.BackgroundSource.Custom(template)); selectLayer(); } @@ -25611,6 +26166,11 @@ iD.ui.Background = function(context) { .property('checked', showsGpx); selectLayer(); + + var source = context.background().baseLayerSource(); + if (source.id === 'custom') { + customTemplate = source.template; + } } function clickNudge(d) { @@ -25717,12 +26277,27 @@ iD.ui.Background = function(context) { .attr('class', 'custom_layer') .datum(iD.BackgroundSource.Custom()); + custom.append('button') + .attr('class', 'layer-browse') + .call(bootstrap.tooltip() + .title(t('background.custom_button')) + .placement('left')) + .on('click', editCustom) + .append('span') + .attr('class', 'icon geocode'); + var label = custom.append('label'); label.append('input') .attr('type', 'radio') .attr('name', 'layers') - .on('change', clickCustom); + .on('change', function () { + if (customTemplate) { + setCustom(customTemplate); + } else { + editCustom(); + } + }); label.append('span') .text(t('background.custom')); @@ -26221,6 +26796,8 @@ iD.ui.EntityEditor = function(context) { preset, reference; + var presetEditor = iD.ui.preset(context) + .on('change', changeTags); var rawTagEditor = iD.ui.RawTagEditor(context) .on('change', changeTags); @@ -26307,12 +26884,11 @@ iD.ui.EntityEditor = function(context) { .text(preset.name()); $body.select('.inspector-preset') - .call(iD.ui.preset(context) + .call(presetEditor .preset(preset) .entityID(id) .tags(tags) - .state(state) - .on('change', changeTags)); + .state(state)); $body.select('.raw-tag-editor') .call(rawTagEditor @@ -26349,11 +26925,13 @@ iD.ui.EntityEditor = function(context) { function clean(o) { var out = {}, k, v; + /*jshint -W083 */ for (k in o) { if (k && (v = o[k]) !== undefined) { - out[k] = v.trim(); + out[k] = v.split(';').map(function(s) { return s.trim(); }).join(';'); } } + /*jshint +W083 */ return out; } @@ -26871,7 +27449,12 @@ iD.ui.Inspector = function(context) { var $presetPane = $wrap.select('.preset-list-pane'); var $editorPane = $wrap.select('.entity-editor-pane'); - var showEditor = state === 'hover' || context.entity(entityID).isUsed(context.graph()); + var graph = context.graph(), + entity = context.entity(entityID), + showEditor = state === 'hover' || + entity.isUsed(graph) || + entity.isHighwayIntersection(graph); + if (showEditor) { $wrap.style('right', '0%'); $editorPane.call(entityEditor); @@ -27399,6 +27982,10 @@ iD.ui.preset = function(context) { } }); + if (entity.isHighwayIntersection(context.graph())) { + fields.push(UIField(context.presets().field('restrictions'), entity, true)); + } + context.presets().universal().forEach(function(field) { if (preset.fields.indexOf(field) < 0) { fields.push(UIField(field, entity)); @@ -27461,7 +28048,7 @@ iD.ui.preset = function(context) { return field.present(); }) .each(function(field) { - var reference = iD.ui.TagReference({key: field.key}); + var reference = iD.ui.TagReference(field.reference || {key: field.key}); if (state === 'hover') { reference.showing(false); @@ -27504,7 +28091,7 @@ iD.ui.preset = function(context) { function show(field) { field.show = true; - presets(selection); + context.presets()(selection); field.input.focus(); } @@ -27523,6 +28110,7 @@ iD.ui.preset = function(context) { presets.preset = function(_) { if (!arguments.length) return preset; + if (preset && preset.id === _.id) return presets; preset = _; fields = null; return presets; @@ -27543,6 +28131,7 @@ iD.ui.preset = function(context) { presets.entityID = function(_) { if (!arguments.length) return id; + if (id === _) return presets; id = _; fields = null; return presets; @@ -27568,7 +28157,7 @@ iD.ui.PresetIcon = function() { $fill.enter().append('div'); $fill.attr('class', function() { - var s = 'preset-icon-fill icon-' + geom; + var s = 'preset-icon-fill preset-icon-fill-' + geom; for (var i in p.tags) { s += ' tag-' + i + ' tag-' + i + '-' + p.tags[i]; } @@ -28466,10 +29055,22 @@ iD.ui.RawTagEditor = function(context) { } function keyChange(d) { - var tag = {}; - tag[d.key] = undefined; - tag[this.value] = d.value; - d.key = this.value; // Maintain DOM identity through the subsequent update. + var kOld = d.key, + kNew = this.value.trim(), + tag = {}; + + if (kNew && kNew !== kOld) { + var match = kNew.match(/^(.*?)(?:_(\d+))?$/), + base = match[1], + suffix = +(match[2] || 1); + while (tags[kNew]) { // rename key if already in use + kNew = base + '_' + suffix++; + } + } + tag[kOld] = undefined; + tag[kNew] = d.value; + d.key = kNew; // Maintain DOM identity through the subsequent update. + this.value = kNew; event.change(tag); } @@ -28772,6 +29373,7 @@ iD.ui.Sidebar = function(context) { sidebar.hide = function() { featureListWrap.classed('inspector-hidden', false); + inspectorWrap.classed('inspector-hidden', true); if (current) current.remove(); current = null; }; @@ -29332,10 +29934,11 @@ iD.ui.preset.access = function(field) { } access.options = function(type) { - var options = ['no', 'permissive', 'private', 'designated', 'destination']; + var options = ['no', 'permissive', 'private', 'destination']; if (type !== 'access') { options.unshift('yes'); + options.push('designated'); } return options.map(function(option) { @@ -29348,65 +29951,104 @@ iD.ui.preset.access = function(field) { var placeholders = { footway: { - foot: 'yes', + foot: 'designated', motor_vehicle: 'no' }, steps: { foot: 'yes', - motor_vehicle: 'no' + motor_vehicle: 'no', + bicycle: 'no', + horse: 'no' }, pedestrian: { foot: 'yes', motor_vehicle: 'no' }, cycleway: { - bicycle: 'yes', - motor_vehicle: 'no' + motor_vehicle: 'no', + bicycle: 'designated' }, bridleway: { - horse: 'yes' + motor_vehicle: 'no', + horse: 'designated' }, path: { - motor_vehicle: 'no' + foot: 'yes', + motor_vehicle: 'no', + bicycle: 'yes', + horse: 'yes' }, motorway: { - motor_vehicle: 'yes' + foot: 'no', + motor_vehicle: 'yes', + bicycle: 'no', + horse: 'no' }, trunk: { motor_vehicle: 'yes' }, primary: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, secondary: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, tertiary: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, residential: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, unclassified: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, service: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, motorway_link: { - motor_vehicle: 'yes' + foot: 'no', + motor_vehicle: 'yes', + bicycle: 'no', + horse: 'no' }, trunk_link: { motor_vehicle: 'yes' }, primary_link: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, secondary_link: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' }, tertiary_link: { - motor_vehicle: 'yes' + foot: 'yes', + motor_vehicle: 'yes', + bicycle: 'yes', + horse: 'yes' } }; @@ -29422,7 +30064,9 @@ iD.ui.preset.access = function(field) { _.forEach(placeholders[tags.highway], function(value, key) { items.selectAll('#preset-input-access-' + key) - .attr('placeholder', value); + .attr('placeholder', function() { + return (tags.access && (value === 'yes' || value === 'designated')) ? tags.access : value; + }); }); }; @@ -29559,10 +30203,6 @@ iD.ui.preset.address = function(field, context) { city = wrap.select('.addr-city'); postcode = wrap.select('.addr-postcode'); - wrap.selectAll('input') - .on('blur', change) - .on('change', change); - street .call(d3.combobox() .fetcher(function(value, callback) { @@ -29580,6 +30220,10 @@ iD.ui.preset.address = function(field, context) { .fetcher(function(value, callback) { callback(getPostCodes()); })); + + wrap.selectAll('input') + .on('blur', change) + .on('change', change); } function change() { @@ -29610,15 +30254,41 @@ iD.ui.preset.address = function(field, context) { return d3.rebind(address, event, 'on'); }; -iD.ui.preset.check = function(field) { +iD.ui.preset.check = +iD.ui.preset.defaultcheck = function(field) { var event = d3.dispatch('change'), - values = [undefined, 'yes', 'no'], - value, - box, - text, - label; + options = field.strings && field.strings.options, + values = [], + texts = [], + entity, value, box, text, label; + + if (options) { + for (var k in options) { + values.push(k === 'undefined' ? undefined : k); + texts.push(field.t('check.' + k, { 'default': options[k] })); + } + } else { + values = [undefined, 'yes']; + texts = [t('inspector.unknown'), t('inspector.check.yes')]; + if (field.type === 'check') { + values.push('no'); + texts.push(t('inspector.check.no')); + } + } var check = function(selection) { + // hack: pretend oneway field is a oneway_yes field + // where implied oneway tag exists (e.g. `junction=roundabout`) #2220, #1841 + if (field.id === 'oneway') { + for (var key in entity.tags) { + if (key in iD.oneWayTags && (entity.tags[key] in iD.oneWayTags[key])) { + texts.shift(); + texts.unshift(t('presets.fields.oneway_yes.check.undefined', { 'default': 'Assumed to be Yes' })); + break; + } + } + } + selection.classed('checkselect', 'true'); label = selection.selectAll('.preset-input-wrap') @@ -29628,18 +30298,18 @@ iD.ui.preset.check = function(field) { .attr('class', 'preset-input-wrap'); enter.append('input') - .property('indeterminate', true) + .property('indeterminate', field.type === 'check') .attr('type', 'checkbox') .attr('id', 'preset-input-' + field.id); enter.append('span') - .text(t('inspector.unknown')) + .text(texts[0]) .attr('class', 'value'); box = label.select('input') .on('click', function() { var t = {}; - t[field.key] = values[(values.indexOf(value) + 1) % 3]; + t[field.key] = values[(values.indexOf(value) + 1) % values.length]; event.change(t); d3.event.stopPropagation(); }); @@ -29647,11 +30317,17 @@ iD.ui.preset.check = function(field) { text = label.select('span.value'); }; + check.entity = function(_) { + if (!arguments.length) return entity; + entity = _; + return check; + }; + check.tags = function(tags) { value = tags[field.key]; - box.property('indeterminate', !value); + box.property('indeterminate', field.type === 'check' && !value); box.property('checked', value === 'yes'); - text.text(value ? t('inspector.check.' + value, {default: value}) : t('inspector.unknown')); + text.text(texts[values.indexOf(value)]); label.classed('set', !!value); }; @@ -29677,6 +30353,7 @@ iD.ui.preset.typeCombo = function(field) { .attr('id', 'preset-input-' + field.id); input + .call(combobox) .on('change', change) .on('blur', change) .each(function() { @@ -29689,13 +30366,12 @@ iD.ui.preset.typeCombo = function(field) { if (!err) options(_.pluck(data, 'value')); }); } - }) - .call(combobox); + }); function options(opts) { combobox.data(opts.map(function(d) { var o = {}; - o.title = o.value = d.replace('_', ' '); + o.title = o.value = d.replace(/_+/g, ' '); return o; })); @@ -29707,7 +30383,12 @@ iD.ui.preset.typeCombo = function(field) { } function change() { - var value = input.value().replace(' ', '_'); + var value = input.value() + .split(';') + .map(function(s) { return s.trim(); }) + .join(';') + .replace(/\s+/g, '_'); + if (field.type === 'typeCombo' && !value) value = 'yes'; var t = {}; @@ -29727,36 +30408,6 @@ iD.ui.preset.typeCombo = function(field) { return d3.rebind(combo, event, 'on'); }; -iD.ui.preset.defaultcheck = function(field) { - var event = d3.dispatch('change'), - input; - - function check(selection) { - input = selection.selectAll('input') - .data([0]); - - input.enter().append('input') - .attr('type', 'checkbox') - .attr('id', 'preset-input-' + field.id); - - input - .on('change', function() { - var t = {}; - t[field.key] = input.property('checked') ? field.value || 'yes' : undefined; - event.change(t); - }); - } - - check.tags = function(tags) { - input.property('checked', !!tags[field.key] && tags[field.key] !== 'no'); - }; - - check.focus = function() { - input.node().focus(); - }; - - return d3.rebind(check, event, 'on'); -}; iD.ui.preset.text = iD.ui.preset.number = iD.ui.preset.tel = @@ -29839,10 +30490,6 @@ iD.ui.preset.localized = function(field, context) { .attr('class', 'localized-main') .attr('placeholder', field.placeholder()); - input - .on('blur', change) - .on('change', change); - if (field.id === 'name') { var preset = context.presets().match(entity, context.graph()); input.call(d3.combobox().fetcher( @@ -29850,6 +30497,10 @@ iD.ui.preset.localized = function(field, context) { )); } + input + .on('blur', change) + .on('change', change); + var translateButton = selection.selectAll('.localized-add') .data([0]); @@ -30079,9 +30730,9 @@ iD.ui.preset.maxspeed = function(field, context) { .attr('placeholder', field.placeholder()); input + .call(combobox) .on('change', change) - .on('blur', change) - .call(combobox); + .on('blur', change); var childNodes = context.graph().childNodes(context.entity(entity.id)), loc = childNodes[~~(childNodes.length/2)].loc; @@ -30241,6 +30892,145 @@ iD.ui.preset.radio = function(field) { return d3.rebind(radio, event, 'on'); }; +iD.ui.preset.restrictions = function(field, context) { + var event = d3.dispatch('change'), + vertexID, + fromNodeID; + + function restrictions(selection) { + var wrap = selection.selectAll('.preset-input-wrap') + .data([0]); + + var enter = wrap.enter().append('div') + .attr('class', 'preset-input-wrap'); + + enter.append('div') + .attr('class', 'restriction-help'); + + enter.append('svg') + .call(iD.svg.Surface(context)) + .call(iD.behavior.Hover(context)); + + var intersection = iD.geo.Intersection(context.graph(), vertexID), + graph = intersection.graph, + vertex = graph.entity(vertexID), + surface = wrap.selectAll('svg'), + filter = function () { return true; }, + extent = iD.geo.Extent(), + projection = iD.geo.RawMercator(), + lines = iD.svg.Lines(projection, context), + vertices = iD.svg.Vertices(projection, context), + turns = iD.svg.Turns(projection, context); + + var d = wrap.dimensions(), + c = [d[0] / 2, d[1] / 2], + z = 21; + + projection + .scale(256 * Math.pow(2, z) / (2 * Math.PI)); + + var s = projection(vertex.loc); + + projection + .translate([c[0] - s[0], c[1] - s[1]]) + .clipExtent([[0, 0], d]); + + surface + .call(vertices, graph, [vertex], filter, extent, z) + .call(lines, graph, intersection.highways, filter) + .call(turns, graph, intersection.turns(fromNodeID)); + + surface + .on('click.restrictions', click) + .on('mouseover.restrictions', mouseover) + .on('mouseout.restrictions', mouseout); + + surface + .selectAll('.selected') + .classed('selected', false); + + if (fromNodeID) { + surface + .selectAll('.' + _.find(intersection.highways, function(way) { return way.contains(fromNodeID); }).id) + .classed('selected', true); + } + + mouseout(); + + context.history() + .on('change.restrictions', render); + + d3.select(window) + .on('resize.restrictions', render); + + function click() { + var datum = d3.event.target.__data__; + if (datum instanceof iD.Entity) { + fromNodeID = datum.nodes[(datum.first() === vertexID) ? 1 : datum.nodes.length - 2]; + render(); + } else if (datum instanceof iD.geo.Turn) { + if (datum.restriction) { + context.perform( + iD.actions.UnrestrictTurn(datum, projection), + t('operations.restriction.annotation.delete')); + } else { + context.perform( + iD.actions.RestrictTurn(datum, projection), + t('operations.restriction.annotation.create')); + } + } + } + + function mouseover() { + var datum = d3.event.target.__data__; + if (datum instanceof iD.geo.Turn) { + var graph = context.graph(), + presets = context.presets(), + preset; + + if (datum.restriction) { + preset = presets.match(graph.entity(datum.restriction), graph); + } else { + preset = presets.item('type/restriction/' + + iD.geo.inferRestriction( + graph.entity(datum.from.node), + graph.entity(datum.via.node), + graph.entity(datum.to.node), + projection)); + } + + wrap.selectAll('.restriction-help') + .text(t('operations.restriction.help.' + + (datum.restriction ? 'toggle_off' : 'toggle_on'), + {restriction: preset.name()})); + } + } + + function mouseout() { + wrap.selectAll('.restriction-help') + .text(t('operations.restriction.help.' + + (fromNodeID ? 'toggle' : 'select'))); + } + + function render() { + if (context.hasEntity(vertexID)) { + restrictions(selection); + } + } + } + + restrictions.entity = function(_) { + if (!vertexID || vertexID !== _.id) { + fromNodeID = null; + vertexID = _.id; + } + }; + + restrictions.tags = function() {}; + restrictions.focus = function() {}; + + return d3.rebind(restrictions, event, 'on'); +}; iD.ui.preset.textarea = function(field) { var event = d3.dispatch('change'), @@ -30319,9 +31109,9 @@ iD.ui.preset.wikipedia = function(field, context) { .value('English'); lang + .call(langcombo) .on('blur', changeLang) - .on('change', changeLang) - .call(langcombo); + .on('change', changeLang); title = selection.selectAll('input.wiki-title') .data([0]); @@ -30332,9 +31122,9 @@ iD.ui.preset.wikipedia = function(field, context) { .attr('id', 'preset-input-' + field.id); title + .call(titlecombo) .on('blur', change) - .on('change', change) - .call(titlecombo); + .on('change', change); link = selection.selectAll('a.wiki-link') .data([0]); @@ -31185,7 +31975,7 @@ iD.presets.Field = function(id, field) { field.id = id; field.matchGeometry = function(geometry) { - return !field.geometry || field.geometry.indexOf(geometry) >= 0; + return !field.geometry || field.geometry === geometry; }; field.t = function(scope, options) { @@ -38246,6 +39036,42 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms_url": "http://geo.nls.uk/maps/", "terms_text": "National Library of Scotland Historic Maps" }, + { + "name": "Ireland British War Office 1:25k GSGS 3906", + "type": "tms", + "template": "http://mapwarper.net/layers/tile/101/{zoom}/{x}/{y}.png", + "scaleExtent": [ + 0, + 18 + ], + "polygon": [ + [ + [ + -10.71, + 51.32 + ], + [ + -10.71, + 55.46 + ], + [ + -5.37, + 55.46 + ], + [ + -5.37, + 51.32 + ], + [ + -10.71, + 51.32 + ] + ] + ], + "terms_url": "http://wiki.openstreetmap.org/wiki/WikiProject_Ireland#Trinity_College_Dublin", + "terms_text": "Glucksman Map Library, Trinity College Dublin", + "id": "GSGS3906" + }, { "name": "Ireland British War Office One-Inch 1941-43 GSGS 4136", "type": "tms", @@ -38475,7 +39301,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ] ], "terms_url": "http://geo.nls.uk/maps/", - "terms_text": "National Library of Scotland Historic Maps" + "terms_text": "National Library of Scotland Historic Maps", + "id": "GSGS4136" }, { "name": "Ireland EEA CORINE 2006", @@ -41654,22 +42481,23 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "overlay": true }, { - "name": "MapBox Satellite", + "name": "MapQuest Open Aerial", + "type": "tms", + "template": "http://oatile{switch:1,2,3,4}.mqcdn.com/tiles/1.0.0/sat/{zoom}/{x}/{y}.png", + "default": true + }, + { + "name": "Mapbox Satellite", "type": "tms", "description": "Satellite and aerial imagery.", "template": "http://{switch:a,b,c}.tiles.mapbox.com/v3/openstreetmap.map-4wvf9l0l/{zoom}/{x}/{y}.png", "scaleExtent": [ 0, - 16 + 19 ], "terms_url": "http://www.mapbox.com/about/maps/", "terms_text": "Terms & Feedback", - "default": true - }, - { - "name": "MapQuest Open Aerial", - "type": "tms", - "template": "http://oatile{switch:1,2,3,4}.mqcdn.com/tiles/1.0.0/sat/{zoom}/{x}/{y}.png", + "id": "Mapbox", "default": true }, { @@ -62940,7 +63768,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "fields": [ "ref", - "surface" + "surface", + "length", + "width" ], "tags": { "aeroway": "runway" @@ -63221,6 +64051,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Sharing" }, "amenity/car_wash": { + "icon": "car", "geometry": [ "point", "area" @@ -63233,6 +64064,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "name": "Car Wash" }, + "amenity/charging_station": { + "icon": "car", + "geometry": [ + "point", + "area" + ], + "tags": { + "amenity": "charging_station" + }, + "fields": [ + "operator" + ], + "terms": [ + "EV", + "Electric Vehicle", + "Supercharger" + ], + "name": "Charging Station" + }, "amenity/childcare": { "icon": "school", "fields": [ @@ -63335,6 +64185,17 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [], "name": "College" }, + "amenity/compressed_air": { + "icon": "car", + "geometry": [ + "point", + "area" + ], + "tags": { + "amenity": "compressed_air" + }, + "name": "Compressed Air" + }, "amenity/courthouse": { "fields": [ "operator", @@ -63391,6 +64252,26 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "opening_hours" ] }, + "amenity/dojo": { + "icon": "pitch", + "geometry": [ + "point", + "area" + ], + "terms": [ + "martial arts", + "dojo", + "dojang" + ], + "tags": { + "amenity": "dojo" + }, + "fields": [ + "address", + "sport" + ], + "name": "Dojo / Martial Arts Academy" + }, "amenity/drinking_water": { "icon": "water", "geometry": [ @@ -63638,6 +64519,20 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [], "name": "Car Parking" }, + "amenity/parking_entrance": { + "icon": "entrance", + "geometry": [ + "vertex" + ], + "tags": { + "amenity": "parking_entrance" + }, + "fields": [ + "access_simple", + "ref" + ], + "name": "Parking Garage Entrance/Exit" + }, "amenity/pharmacy": { "icon": "pharmacy", "fields": [ @@ -64594,8 +65489,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "fields": [ "building", "levels", - "address", - "smoking" + "address" ], "geometry": [ "area" @@ -64791,7 +65685,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "tags": { "building": "entrance" }, - "name": "Entrance", + "name": "Entrance/Exit", "searchable": false }, "building/garage": { @@ -65641,18 +66535,18 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "opening_hours" ] }, - "craft/photographic_labratory": { - "name": "Photographic Labratory", + "craft/photographic_laboratory": { + "name": "Photographic Laboratory", "geometry": [ "point", "area" ], "terms": [ - "photographic labratory", + "photographic laboratory", "film developer" ], "tags": { - "craft": "photographic_labratory" + "craft": "photographic_laboratory" }, "icon": "camera", "fields": [ @@ -66116,13 +67010,15 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "access_simple", "address" ], - "name": "Entrance" + "name": "Entrance/Exit" }, "footway/crossing": { "fields": [ "crossing", "access", - "surface" + "surface", + "sloped_curb", + "tactile_paving" ], "geometry": [ "line" @@ -66131,16 +67027,37 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "highway": "footway", "footway": "crossing" }, + "terms": [], + "name": "Crossing" + }, + "footway/crosswalk": { + "fields": [ + "crossing", + "access", + "surface", + "sloped_curb", + "tactile_paving" + ], + "geometry": [ + "line" + ], + "tags": { + "highway": "footway", + "footway": "crossing", + "crossing": "zebra" + }, "terms": [ "crosswalk", "zebra crossing" ], - "name": "Crossing" + "name": "Crosswalk" }, "footway/sidewalk": { "fields": [ "surface", "lit", + "width", + "structure", "access" ], "geometry": [ @@ -66153,6 +67070,15 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [], "name": "Sidewalk" }, + "ford": { + "geometry": [ + "vertex" + ], + "tags": { + "ford": "yes" + }, + "name": "Ford" + }, "golf/bunker": { "icon": "golf", "geometry": [ @@ -66276,9 +67202,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "highway/bridleway": { "fields": [ - "access", "surface", - "structure" + "width", + "structure", + "access" ], "icon": "highway-bridleway", "geometry": [ @@ -66314,7 +67241,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "highway/crossing": { "fields": [ - "crossing" + "crossing", + "sloped_curb", + "tactile_paving" ], "geometry": [ "vertex" @@ -66322,20 +67251,37 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "tags": { "highway": "crossing" }, + "terms": [], + "name": "Crossing" + }, + "highway/crosswalk": { + "fields": [ + "crossing", + "sloped_curb", + "tactile_paving" + ], + "geometry": [ + "vertex" + ], + "tags": { + "highway": "crossing", + "crossing": "zebra" + }, "terms": [ "crosswalk", "zebra crossing" ], - "name": "Crossing" + "name": "Crosswalk" }, "highway/cycleway": { "icon": "highway-cycleway", "fields": [ "surface", "lit", + "width", + "oneway", "structure", - "access", - "oneway" + "access" ], "geometry": [ "line" @@ -66349,9 +67295,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "highway/footway": { "icon": "highway-footway", "fields": [ + "surface", + "lit", + "width", "structure", - "access", - "surface" + "access" ], "geometry": [ "line", @@ -66420,7 +67368,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "highway/motorway": { "icon": "highway-motorway", "fields": [ - "oneway", + "oneway_yes", "maxspeed", "structure", "access", @@ -66447,7 +67395,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "fields": [ "ref" ], - "name": "Motorway Junction" + "name": "Motorway Junction / Exit" }, "highway/motorway_link": { "icon": "highway-motorway-link", @@ -66475,10 +67423,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "highway/path": { "icon": "highway-path", "fields": [ + "surface", + "width", "structure", "access", "sac_scale", - "surface", "incline", "trail_visibility", "ref" @@ -66494,9 +67443,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "highway/pedestrian": { "fields": [ - "access", + "surface", + "lit", + "width", "oneway", - "surface" + "structure", + "access" ], "geometry": [ "line", @@ -66763,8 +67715,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "highway/steps": { "fields": [ - "access", - "surface" + "surface", + "lit", + "width", + "access" ], "icon": "highway-steps", "geometry": [ @@ -67095,7 +68049,22 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [], "name": "Cemetery" }, + "landuse/churchyard": { + "fields": [ + "religion", + "denomination" + ], + "geometry": [ + "area" + ], + "tags": { + "landuse": "churchyard" + }, + "terms": [], + "name": "Churchyard" + }, "landuse/commercial": { + "icon": "commercial", "geometry": [ "point", "area" @@ -67228,6 +68197,16 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [], "name": "Meadow" }, + "landuse/military": { + "geometry": [ + "area" + ], + "tags": { + "landuse": "military" + }, + "terms": [], + "name": "Military" + }, "landuse/orchard": { "fields": [ "trees" @@ -67255,6 +68234,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Quarry" }, "landuse/residential": { + "icon": "building", "geometry": [ "point", "area" @@ -67453,7 +68433,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "icon": "pitch", "fields": [ "sport", - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67468,7 +68449,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/pitch/american_football": { "icon": "america-football", "fields": [ - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67483,6 +68465,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "leisure/pitch/baseball": { "icon": "baseball", + "fields": [ + "lit" + ], "geometry": [ "point", "area" @@ -67498,7 +68483,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "icon": "basketball", "fields": [ "surface", - "hoops" + "hoops", + "lit" ], "geometry": [ "point", @@ -67514,7 +68500,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/pitch/skateboard": { "icon": "pitch", "fields": [ - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67530,7 +68517,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/pitch/soccer": { "icon": "soccer", "fields": [ - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67546,7 +68534,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/pitch/tennis": { "icon": "tennis", "fields": [ - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67562,7 +68551,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/pitch/volleyball": { "icon": "pitch", "fields": [ - "surface" + "surface", + "lit" ], "geometry": [ "point", @@ -67601,6 +68591,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Slipway" }, "leisure/sports_center": { + "icon": "pitch", "geometry": [ "point", "area" @@ -67611,10 +68602,13 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": [ "gym" ], - "icon": "sports", - "name": "Sports Center" + "fields": [ + "sport" + ], + "name": "Sports Center / Gym" }, "leisure/stadium": { + "icon": "pitch", "geometry": [ "point", "area" @@ -67645,7 +68639,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure/track": { "icon": "pitch", "fields": [ - "surface" + "surface", + "lit", + "width" ], "geometry": [ "point", @@ -68571,6 +69567,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "place/city": { "icon": "city", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -68582,6 +69581,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "place/hamlet": { "icon": "triangle-stroked", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -68623,6 +69625,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "place/locality": { "icon": "marker", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -68634,6 +69639,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "place/neighbourhood": { "icon": "triangle-stroked", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -68646,8 +69654,29 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "name": "Neighborhood" }, + "place/suburb": { + "icon": "triangle-stroked", + "fields": [ + "population" + ], + "geometry": [ + "point", + "area" + ], + "tags": { + "place": "suburb" + }, + "terms": [ + "Boro", + "Quarter" + ], + "name": "Borough" + }, "place/town": { "icon": "town", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -68659,6 +69688,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "place/village": { "icon": "village", + "fields": [ + "population" + ], "geometry": [ "point", "area" @@ -69268,7 +70300,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Dealership" }, "shop/car_parts": { - "icon": "shop", + "icon": "car", "fields": [ "address", "building_area", @@ -69285,7 +70317,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Parts Store" }, "shop/car_repair": { - "icon": "shop", + "icon": "car", "fields": [ "address", "building_area", @@ -69302,7 +70334,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Repair Shop" }, "shop/chemist": { - "icon": "shop", + "icon": "chemist", "fields": [ "address", "building_area", @@ -69507,7 +70539,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "tags": { "shop": "fishmonger" }, - "name": "Fishmonger" + "name": "Fishmonger", + "searchable": false }, "shop/florist": { "icon": "shop", @@ -69622,7 +70655,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Greengrocer" }, "shop/hairdresser": { - "icon": "shop", + "icon": "hairdresser", "fields": [ "address", "building_area", @@ -69778,7 +70811,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Mall" }, "shop/mobile_phone": { - "icon": "shop", + "icon": "mobilephone", "fields": [ "address", "building_area", @@ -69795,7 +70828,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Mobile Phone Store" }, "shop/motorcycle": { - "icon": "shop", + "icon": "scooter", "fields": [ "address", "building_area", @@ -69913,6 +70946,26 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "name": "Photography Store" }, + "shop/seafood": { + "icon": "shop", + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "geometry": [ + "point", + "vertex", + "area" + ], + "tags": { + "shop": "seafood" + }, + "terms": [ + "fishmonger" + ], + "name": "Seafood Shop" + }, "shop/shoes": { "icon": "shop", "fields": [ @@ -70107,6 +71160,26 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "name": "Video Store" }, + "shop/wine": { + "icon": "alcohol-shop", + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "geometry": [ + "point", + "vertex", + "area" + ], + "tags": { + "shop": "wine" + }, + "terms": [ + "winery" + ], + "name": "Wine Shop" + }, "tourism": { "fields": [ "tourism" @@ -70464,9 +71537,108 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Restriction", "icon": "restriction", "fields": [ - "restriction" + "restriction", + "except" ] }, + "type/restriction/no_left_turn": { + "name": "No Left Turn", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "no_left_turn" + }, + "fields": [ + "except" + ], + "icon": "restriction-no-left-turn" + }, + "type/restriction/no_right_turn": { + "name": "No Right Turn", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "no_right_turn" + }, + "fields": [ + "except" + ], + "icon": "restriction-no-right-turn" + }, + "type/restriction/no_straight_on": { + "name": "No Straight On", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "no_straight_on" + }, + "fields": [ + "except" + ], + "icon": "restriction-no-straight-on" + }, + "type/restriction/no_u_turn": { + "name": "No U-turn", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "no_u_turn" + }, + "fields": [ + "except" + ], + "icon": "restriction-no-u-turn" + }, + "type/restriction/only_left_turn": { + "name": "Left Turn Only", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "only_left_turn" + }, + "fields": [ + "except" + ], + "icon": "restriction-only-left-turn" + }, + "type/restriction/only_right_turn": { + "name": "Right Turn Only", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "only_right_turn" + }, + "fields": [ + "except" + ], + "icon": "restriction-only-right-turn" + }, + "type/restriction/only_straight_on": { + "name": "No Turns", + "geometry": [ + "relation" + ], + "tags": { + "type": "restriction", + "restriction": "only_straight_on" + }, + "fields": [ + "except" + ], + "icon": "restriction-only-straight-on" + }, "type/route": { "geometry": [ "relation" @@ -70689,6 +71861,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "waterway/canal": { "icon": "waterway-canal", + "fields": [ + "width" + ], "geometry": [ "line" ], @@ -70739,7 +71914,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "waterway/river": { "icon": "waterway-river", "fields": [ - "tunnel" + "tunnel", + "width" ], "geometry": [ "line" @@ -70777,8 +71953,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "waterway/stream": { "icon": "waterway-stream", "fields": [ - "layer", - "tunnel" + "tunnel", + "width" ], "geometry": [ "line" @@ -71073,25 +72249,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Sainsbury's": { - "tags": { - "name": "Sainsbury's", - "amenity": "fuel" - }, - "name": "Sainsbury's", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/OMV": { "tags": { "name": "OMV", @@ -71130,25 +72287,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Tesco": { - "tags": { - "name": "Tesco", - "amenity": "fuel" - }, - "name": "Tesco", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/JET": { "tags": { "name": "JET", @@ -71168,25 +72306,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Morrisons": { - "tags": { - "name": "Morrisons", - "amenity": "fuel" - }, - "name": "Morrisons", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/United": { "tags": { "name": "United", @@ -71206,25 +72325,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Canadian Tire": { - "tags": { - "name": "Canadian Tire", - "amenity": "fuel" - }, - "name": "Canadian Tire", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Mobil": { "tags": { "name": "Mobil", @@ -71301,25 +72401,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/ABC": { - "tags": { - "name": "ABC", - "amenity": "fuel" - }, - "name": "ABC", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/ARAL": { "tags": { "name": "ARAL", @@ -71396,25 +72477,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Intermarché": { - "tags": { - "name": "Intermarché", - "amenity": "fuel" - }, - "name": "Intermarché", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Total Access": { "tags": { "name": "Total Access", @@ -71434,44 +72496,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Super U": { - "tags": { - "name": "Super U", - "amenity": "fuel" - }, - "name": "Super U", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, - "amenity/fuel/Auchan": { - "tags": { - "name": "Auchan", - "amenity": "fuel" - }, - "name": "Auchan", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Elf": { "tags": { "name": "Elf", @@ -71491,25 +72515,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Carrefour": { - "tags": { - "name": "Carrefour", - "amenity": "fuel" - }, - "name": "Carrefour", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Station Service E. Leclerc": { "tags": { "name": "Station Service E. Leclerc", @@ -71852,25 +72857,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Raiffeisenbank": { - "tags": { - "name": "Raiffeisenbank", - "amenity": "fuel" - }, - "name": "Raiffeisenbank", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Tamoil": { "tags": { "name": "Tamoil", @@ -71966,25 +72952,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Coop": { - "tags": { - "name": "Coop", - "amenity": "fuel" - }, - "name": "Coop", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Orlen": { "tags": { "name": "Orlen", @@ -72194,25 +73161,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/7-Eleven": { - "tags": { - "name": "7-Eleven", - "amenity": "fuel" - }, - "name": "7-Eleven", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Agrola": { "tags": { "name": "Agrola", @@ -73334,25 +74282,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Wawa": { - "tags": { - "name": "Wawa", - "amenity": "fuel" - }, - "name": "Wawa", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Pertamina": { "tags": { "name": "Pertamina", @@ -73848,25 +74777,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Circle K": { - "tags": { - "name": "Circle K", - "amenity": "fuel" - }, - "name": "Circle K", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Posto Ipiranga": { "tags": { "name": "Posto Ipiranga", @@ -74019,25 +74929,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/Stewart's": { - "tags": { - "name": "Stewart's", - "amenity": "fuel" - }, - "name": "Stewart's", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Posto BR": { "tags": { "name": "Posto BR", @@ -74209,25 +75100,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/fuel/H-E-B": { - "tags": { - "name": "H-E-B", - "amenity": "fuel" - }, - "name": "H-E-B", - "icon": "fuel", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "address", - "building_area" - ], - "suggestion": true - }, "amenity/fuel/Укрнафта": { "tags": { "name": "Укрнафта", @@ -75304,6 +76176,28 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "amenity/fast_food/Subway": { + "tags": { + "name": "Subway", + "cuisine": "sandwich", + "amenity": "fast_food" + }, + "name": "Subway", + "icon": "fast-food", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "cuisine", + "building_area", + "address", + "opening_hours", + "smoking" + ], + "suggestion": true + }, "amenity/fast_food/Burger King": { "tags": { "name": "Burger King", @@ -80011,6 +80905,26 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "amenity/bank/Raiffeisenbank": { + "tags": { + "name": "Raiffeisenbank", + "amenity": "bank" + }, + "name": "Raiffeisenbank", + "icon": "bank", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "atm", + "building_area", + "address", + "opening_hours" + ], + "suggestion": true + }, "amenity/bank/Yorkshire Bank": { "tags": { "name": "Yorkshire Bank", @@ -85730,26 +86644,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "amenity/pharmacy/Радуга": { - "tags": { - "name": "Радуга", - "amenity": "pharmacy" - }, - "name": "Радуга", - "icon": "pharmacy", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address", - "opening_hours" - ], - "suggestion": true - }, "amenity/pharmacy/サンドラッグ": { "tags": { "name": "サンドラッグ", @@ -86910,6 +87804,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Morrisons": { + "tags": { + "name": "Morrisons", + "shop": "supermarket" + }, + "name": "Morrisons", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Interspar": { "tags": { "name": "Interspar", @@ -86948,6 +87861,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Sainsbury's": { + "tags": { + "name": "Sainsbury's", + "shop": "supermarket" + }, + "name": "Sainsbury's", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Lidl": { "tags": { "name": "Lidl", @@ -87024,6 +87956,44 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Coop": { + "tags": { + "name": "Coop", + "shop": "supermarket" + }, + "name": "Coop", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, + "shop/supermarket/Tesco": { + "tags": { + "name": "Tesco", + "shop": "supermarket" + }, + "name": "Tesco", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Woolworths": { "tags": { "name": "Woolworths", @@ -87366,25 +88336,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Tesco Express": { - "tags": { - "name": "Tesco Express", - "shop": "supermarket" - }, - "name": "Tesco Express", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/King Soopers": { "tags": { "name": "King Soopers", @@ -87499,6 +88450,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Carrefour": { + "tags": { + "name": "Carrefour", + "shop": "supermarket" + }, + "name": "Carrefour", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Waitrose": { "tags": { "name": "Waitrose", @@ -87898,6 +88868,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Super U": { + "tags": { + "name": "Super U", + "shop": "supermarket" + }, + "name": "Super U", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Metro": { "tags": { "name": "Metro", @@ -88126,25 +89115,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/COOP Jednota": { - "tags": { - "name": "COOP Jednota", - "shop": "supermarket" - }, - "name": "COOP Jednota", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Rema 1000": { "tags": { "name": "Rema 1000", @@ -88772,6 +89742,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/supermarket/Auchan": { + "tags": { + "name": "Auchan", + "shop": "supermarket" + }, + "name": "Auchan", + "icon": "grocery", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "operator", + "building_area", + "address" + ], + "suggestion": true + }, "shop/supermarket/Mercadona": { "tags": { "name": "Mercadona", @@ -88924,12 +89913,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Costcutter": { + "shop/supermarket/Maxi": { "tags": { - "name": "Costcutter", + "name": "Maxi", "shop": "supermarket" }, - "name": "Costcutter", + "name": "Maxi", "icon": "grocery", "geometry": [ "point", @@ -88943,12 +89932,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Maxi": { + "shop/supermarket/Colruyt": { "tags": { - "name": "Maxi", + "name": "Colruyt", "shop": "supermarket" }, - "name": "Maxi", + "name": "Colruyt", "icon": "grocery", "geometry": [ "point", @@ -88962,12 +89951,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Colruyt": { + "shop/supermarket/The Co-operative": { "tags": { - "name": "Colruyt", + "name": "The Co-operative", "shop": "supermarket" }, - "name": "Colruyt", + "name": "The Co-operative", "icon": "grocery", "geometry": [ "point", @@ -88981,12 +89970,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/The Co-operative": { + "shop/supermarket/Intermarché": { "tags": { - "name": "The Co-operative", + "name": "Intermarché", "shop": "supermarket" }, - "name": "The Co-operative", + "name": "Intermarché", "icon": "grocery", "geometry": [ "point", @@ -89171,25 +90160,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/dm": { - "tags": { - "name": "dm", - "shop": "supermarket" - }, - "name": "dm", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Kvickly": { "tags": { "name": "Kvickly", @@ -89437,25 +90407,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Petit Casino": { - "tags": { - "name": "Petit Casino", - "shop": "supermarket" - }, - "name": "Petit Casino", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Wasgau": { "tags": { "name": "Wasgau", @@ -90045,25 +90996,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Fressnapf": { - "tags": { - "name": "Fressnapf", - "shop": "supermarket" - }, - "name": "Fressnapf", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Coop Konsum": { "tags": { "name": "Coop Konsum", @@ -90311,25 +91243,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Centra": { - "tags": { - "name": "Centra", - "shop": "supermarket" - }, - "name": "Centra", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Квартал": { "tags": { "name": "Квартал", @@ -90919,12 +91832,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Атак": { + "shop/supermarket/H-E-B": { "tags": { - "name": "Атак", + "name": "H-E-B", "shop": "supermarket" }, - "name": "Атак", + "name": "H-E-B", "icon": "grocery", "geometry": [ "point", @@ -90938,12 +91851,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Полушка": { + "shop/supermarket/Атак": { "tags": { - "name": "Полушка", + "name": "Атак", "shop": "supermarket" }, - "name": "Полушка", + "name": "Атак", "icon": "grocery", "geometry": [ "point", @@ -90957,12 +91870,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Extra": { + "shop/supermarket/Полушка": { "tags": { - "name": "Extra", + "name": "Полушка", "shop": "supermarket" }, - "name": "Extra", + "name": "Полушка", "icon": "grocery", "geometry": [ "point", @@ -90976,12 +91889,12 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Lewiatan": { + "shop/supermarket/Extra": { "tags": { - "name": "Lewiatan", + "name": "Extra", "shop": "supermarket" }, - "name": "Lewiatan", + "name": "Extra", "icon": "grocery", "geometry": [ "point", @@ -91033,25 +91946,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Społem": { - "tags": { - "name": "Społem", - "shop": "supermarket" - }, - "name": "Społem", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Bodega Aurrera": { "tags": { "name": "Bodega Aurrera", @@ -91128,25 +92022,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/supermarket/Магазин": { - "tags": { - "name": "Магазин", - "shop": "supermarket" - }, - "name": "Магазин", - "icon": "grocery", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "operator", - "building_area", - "address" - ], - "suggestion": true - }, "shop/supermarket/Монетка": { "tags": { "name": "Монетка", @@ -91584,6 +92459,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Tesco Express": { + "tags": { + "name": "Tesco Express", + "shop": "convenience" + }, + "name": "Tesco Express", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/One Stop": { "tags": { "name": "One Stop", @@ -91622,6 +92516,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/7-Eleven": { + "tags": { + "name": "7-Eleven", + "shop": "convenience" + }, + "name": "7-Eleven", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Sale": { "tags": { "name": "Sale", @@ -91660,6 +92573,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/COOP Jednota": { + "tags": { + "name": "COOP Jednota", + "shop": "convenience" + }, + "name": "COOP Jednota", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Mac's": { "tags": { "name": "Mac's", @@ -91736,6 +92668,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Costcutter": { + "tags": { + "name": "Costcutter", + "shop": "convenience" + }, + "name": "Costcutter", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Valintatalo": { "tags": { "name": "Valintatalo", @@ -91755,6 +92706,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Circle K": { + "tags": { + "name": "Circle K", + "shop": "convenience" + }, + "name": "Circle K", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/セブンイレブン": { "tags": { "name": "セブンイレブン", @@ -91795,6 +92765,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Petit Casino": { + "tags": { + "name": "Petit Casino", + "shop": "convenience" + }, + "name": "Petit Casino", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Mace": { "tags": { "name": "Mace", @@ -92004,6 +92993,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/ABC": { + "tags": { + "name": "ABC", + "shop": "convenience" + }, + "name": "ABC", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/ミニストップ": { "tags": { "name": "ミニストップ", @@ -92235,6 +93243,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Магазин": { + "tags": { + "name": "Магазин", + "shop": "convenience" + }, + "name": "Магазин", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Гастроном": { "tags": { "name": "Гастроном", @@ -92273,6 +93300,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Centra": { + "tags": { + "name": "Centra", + "shop": "convenience" + }, + "name": "Centra", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/サークルK": { "tags": { "name": "サークルK", @@ -92293,6 +93339,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Wawa": { + "tags": { + "name": "Wawa", + "shop": "convenience" + }, + "name": "Wawa", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Proxi": { "tags": { "name": "Proxi", @@ -92464,6 +93529,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Społem": { + "tags": { + "name": "Społem", + "shop": "convenience" + }, + "name": "Społem", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Cumberland Farms": { "tags": { "name": "Cumberland Farms", @@ -92502,6 +93586,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Kiosk": { + "tags": { + "name": "Kiosk", + "shop": "convenience" + }, + "name": "Kiosk", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/24 часа": { "tags": { "name": "24 часа", @@ -92597,6 +93700,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Stewart's": { + "tags": { + "name": "Stewart's", + "shop": "convenience" + }, + "name": "Stewart's", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Продукти": { "tags": { "name": "Продукти", @@ -92635,6 +93757,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Радуга": { + "tags": { + "name": "Радуга", + "shop": "convenience" + }, + "name": "Радуга", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/ローソンストア100": { "tags": { "name": "ローソンストア100", @@ -93015,6 +94156,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Lewiatan": { + "tags": { + "name": "Lewiatan", + "shop": "convenience" + }, + "name": "Lewiatan", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/Продуктовый магазин": { "tags": { "name": "Продуктовый магазин", @@ -93243,6 +94403,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/convenience/Boutique": { + "tags": { + "name": "Boutique", + "shop": "convenience" + }, + "name": "Boutique", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/convenience/მარკეტი (Market)": { "tags": { "name": "მარკეტი (Market)", @@ -93281,13 +94460,32 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/chemist/dm": { + "tags": { + "name": "dm", + "shop": "chemist" + }, + "name": "dm", + "icon": "chemist", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/chemist/Müller": { "tags": { "name": "Müller", "shop": "chemist" }, "name": "Müller", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93306,7 +94504,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Schlecker", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93325,7 +94523,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Etos", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93344,7 +94542,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Bipa", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93363,7 +94561,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Rossmann", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93382,7 +94580,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "DM Drogeriemarkt", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93401,7 +94599,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Ihr Platz", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93420,7 +94618,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Douglas", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93439,26 +94637,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "chemist" }, "name": "Kruidvat", - "icon": "shop", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, - "shop/car_repair/Peugeot": { - "tags": { - "name": "Peugeot", - "shop": "car_repair" - }, - "name": "Peugeot", - "icon": "shop", + "icon": "chemist", "geometry": [ "point", "vertex", @@ -93477,7 +94656,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Kwik Fit", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93496,7 +94675,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "ATU", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93515,7 +94694,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Kwik-Fit", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93534,7 +94713,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Midas", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93553,7 +94732,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Feu Vert", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93572,7 +94751,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Norauto", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93591,45 +94770,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Speedy", - "icon": "shop", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, - "shop/car_repair/Автозапчасти": { - "tags": { - "name": "Автозапчасти", - "shop": "car_repair" - }, - "name": "Автозапчасти", - "icon": "shop", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, - "shop/car_repair/Renault": { - "tags": { - "name": "Renault", - "shop": "car_repair" - }, - "name": "Renault", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93648,7 +94789,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Pit Stop", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93667,7 +94808,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Jiffy Lube", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93686,7 +94827,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Шиномонтаж", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93705,7 +94846,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "СТО", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93724,7 +94865,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "O'Reilly Auto Parts", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93743,7 +94884,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Carglass", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93762,26 +94903,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "шиномонтаж", - "icon": "shop", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, - "shop/car_repair/Citroen": { - "tags": { - "name": "Citroen", - "shop": "car_repair" - }, - "name": "Citroen", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93800,7 +94922,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Euromaster", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93819,7 +94941,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Firestone", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93838,7 +94960,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "AutoZone", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93857,7 +94979,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Автосервис", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93876,7 +94998,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Advance Auto Parts", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -93895,7 +95017,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "car_repair" }, "name": "Roady", - "icon": "shop", + "icon": "car", "geometry": [ "point", "vertex", @@ -94402,6 +95524,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/doityourself/Canadian Tire": { + "tags": { + "name": "Canadian Tire", + "shop": "doityourself" + }, + "name": "Canadian Tire", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/doityourself/Leroy Merlin": { "tags": { "name": "Leroy Merlin", @@ -94630,25 +95771,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/doityourself/Хозтовары": { - "tags": { - "name": "Хозтовары", - "shop": "doityourself" - }, - "name": "Хозтовары", - "icon": "shop", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, "shop/doityourself/Стройматериалы": { "tags": { "name": "Стройматериалы", @@ -94818,6 +95940,42 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/car/Citroen": { + "tags": { + "name": "Citroen", + "shop": "car" + }, + "name": "Citroen", + "icon": "car", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "opening_hours" + ], + "suggestion": true + }, + "shop/car/Renault": { + "tags": { + "name": "Renault", + "shop": "car" + }, + "name": "Renault", + "icon": "car", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "opening_hours" + ], + "suggestion": true + }, "shop/car/Mercedes-Benz": { "tags": { "name": "Mercedes-Benz", @@ -94944,6 +96102,24 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/car/Автозапчасти": { + "tags": { + "name": "Автозапчасти", + "shop": "car" + }, + "name": "Автозапчасти", + "icon": "car", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "opening_hours" + ], + "suggestion": true + }, "shop/car/Opel": { "tags": { "name": "Opel", @@ -95052,6 +96228,24 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/car/Peugeot": { + "tags": { + "name": "Peugeot", + "shop": "car" + }, + "name": "Peugeot", + "icon": "car", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "opening_hours" + ], + "suggestion": true + }, "shop/car/Hyundai": { "tags": { "name": "Hyundai", @@ -95599,25 +96793,6 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, - "shop/clothes/Deichmann": { - "tags": { - "name": "Deichmann", - "shop": "clothes" - }, - "name": "Deichmann", - "icon": "clothing-store", - "geometry": [ - "point", - "vertex", - "area" - ], - "fields": [ - "address", - "building_area", - "opening_hours" - ], - "suggestion": true - }, "shop/clothes/Lindex": { "tags": { "name": "Lindex", @@ -97898,6 +99073,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/pet/Fressnapf": { + "tags": { + "name": "Fressnapf", + "shop": "pet" + }, + "name": "Fressnapf", + "icon": "dog-park", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/pet/PetSmart": { "tags": { "name": "PetSmart", @@ -97993,6 +99187,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/shoes/Deichmann": { + "tags": { + "name": "Deichmann", + "shop": "shoes" + }, + "name": "Deichmann", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/shoes/Reno": { "tags": { "name": "Reno", @@ -98683,7 +99896,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Билайн", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98702,7 +99915,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "ソフトバンクショップ (SoftBank shop)", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98721,7 +99934,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Vodafone", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98740,7 +99953,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "O2", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98759,7 +99972,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Carphone Warehouse", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98778,7 +99991,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Orange", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98797,7 +100010,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Verizon Wireless", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98816,7 +100029,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Sprint", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98835,7 +100048,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "T-Mobile", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98854,7 +100067,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "МТС", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98873,7 +100086,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Евросеть", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98892,7 +100105,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Bell", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98911,7 +100124,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "The Phone House", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98930,7 +100143,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "SFR", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98949,7 +100162,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Связной", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98968,7 +100181,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Мегафон", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -98987,7 +100200,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "AT&T", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -99006,7 +100219,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "ドコモショップ (docomo shop)", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -99025,7 +100238,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "au", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -99044,7 +100257,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Movistar", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -99063,7 +100276,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "mobile_phone" }, "name": "Bitė", - "icon": "shop", + "icon": "mobilephone", "geometry": [ "point", "vertex", @@ -99120,7 +100333,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Klier", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99139,7 +100352,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Supercuts", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99158,7 +100371,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Hairkiller", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99177,7 +100390,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Great Clips", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99196,7 +100409,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Парикмахерская", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99215,7 +100428,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Стиль", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99234,7 +100447,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Fryzjer", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99253,7 +100466,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Franck Provost", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99272,7 +100485,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": "hairdresser" }, "name": "Салон красоты", - "icon": "shop", + "icon": "hairdresser", "geometry": [ "point", "vertex", @@ -99304,13 +100517,32 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "suggestion": true }, + "shop/hardware/Хозтовары": { + "tags": { + "name": "Хозтовары", + "shop": "hardware" + }, + "name": "Хозтовары", + "icon": "shop", + "geometry": [ + "point", + "vertex", + "area" + ], + "fields": [ + "address", + "building_area", + "opening_hours" + ], + "suggestion": true + }, "shop/motorcycle/Yamaha": { "tags": { "name": "Yamaha", "shop": "motorcycle" }, "name": "Yamaha", - "icon": "shop", + "icon": "scooter", "geometry": [ "point", "vertex", @@ -99356,7 +100588,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "point" ], "vertex": [ - "highway/crossing", + "highway/crosswalk", "railway/level_crossing", "highway/traffic_signals", "highway/turning_circle", @@ -99366,8 +100598,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," ], "relation": [ "category-route", + "category-restriction", "type/boundary", - "type/restriction", "type/multipolygon", "relation" ] @@ -99413,7 +100645,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "landuse/farmyard", "landuse/forest", "landuse/meadow", - "landuse/cemetery" + "landuse/cemetery", + "landuse/military" ] }, "category-path": { @@ -99441,6 +100674,21 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "railway/abandoned" ] }, + "category-restriction": { + "geometry": "relation", + "name": "Restriction", + "icon": "restriction", + "members": [ + "type/restriction/no_left_turn", + "type/restriction/no_right_turn", + "type/restriction/no_straight_on", + "type/restriction/no_u_turn", + "type/restriction/only_left_turn", + "type/restriction/only_right_turn", + "type/restriction/only_straight_on", + "type/restriction" + ] + }, "category-road": { "geometry": "line", "name": "Road", @@ -99516,6 +100764,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "bicycle", "horse" ], + "reference": { + "key": "access" + }, "type": "access", "label": "Access", "placeholder": "Unknown", @@ -99574,6 +100825,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "addr:city", "addr:postcode" ], + "reference": { + "key": "addr" + }, "icon": "address", "universal": true, "label": "Address", @@ -99696,7 +100950,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "building_area": { "key": "building", - "type": "check", + "type": "defaultcheck", "default": "yes", "geometry": "area", "label": "Building" @@ -99823,6 +101077,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "typeCombo", "label": "Type" }, + "except": { + "key": "except", + "type": "combo", + "label": "Exceptions" + }, "fax": { "key": "fax", "type": "tel", @@ -99855,6 +101114,51 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "combo", "label": "Fuel" }, + "fuel/biodiesel": { + "key": "fuel:biodiesel", + "type": "check", + "label": "Sells Biodiesel" + }, + "fuel/diesel": { + "key": "fuel:diesel", + "type": "check", + "label": "Sells Diesel" + }, + "fuel/e10": { + "key": "fuel:e10", + "type": "check", + "label": "Sells E10" + }, + "fuel/e85": { + "key": "fuel:e85", + "type": "check", + "label": "Sells E85" + }, + "fuel/lpg": { + "key": "fuel:lpg", + "type": "check", + "label": "Sells Propane" + }, + "fuel/octane_100": { + "key": "fuel:octane_100", + "type": "check", + "label": "Sells Racing Gasoline" + }, + "fuel/octane_91": { + "key": "fuel:octane_91", + "type": "check", + "label": "Sells Regular Gasoline" + }, + "fuel/octane_95": { + "key": "fuel:octane_95", + "type": "check", + "label": "Sells Midgrade Gasoline" + }, + "fuel/octane_98": { + "key": "fuel:octane_98", + "type": "check", + "label": "Sells Premium Gasoline" + }, "gauge": { "key": "gauge", "type": "combo", @@ -99965,6 +101269,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "typeCombo", "label": "Type" }, + "length": { + "key": "length", + "type": "number", + "label": "Length (Meters)" + }, "levels": { "key": "building:levels", "type": "number", @@ -100023,13 +101332,27 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "oneway": { "key": "oneway", "type": "check", - "label": "One Way" + "label": "One Way", + "strings": { + "options": { + "undefined": "Assumed to be No", + "yes": "Yes", + "no": "No" + } + } }, "oneway_yes": { "key": "oneway", "type": "check", "default": "yes", - "label": "One Way" + "label": "One Way", + "strings": { + "options": { + "undefined": "Assumed to be Yes", + "yes": "Yes", + "no": "No" + } + } }, "opening_hours": { "key": "opening_hours", @@ -100094,6 +101417,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "typeCombo", "label": "Type" }, + "population": { + "key": "population", + "type": "text", + "label": "Population" + }, "power": { "key": "power", "type": "typeCombo", @@ -100164,6 +101492,15 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "combo", "label": "Type" }, + "restrictions": { + "type": "restrictions", + "geometry": "vertex", + "icon": "restrictions", + "reference": { + "rtype": "restriction" + }, + "label": "Turn Restrictions" + }, "route": { "key": "route", "type": "combo", @@ -100220,6 +101557,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "typeCombo", "label": "Type" }, + "sloped_curb": { + "key": "sloped_curb", + "type": "combo", + "label": "Sloped Curb" + }, "smoking": { "key": "smoking", "type": "combo", @@ -100283,7 +101625,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "bridge", "tunnel", "embankment", - "cutting" + "cutting", + "ford" ], "label": "Structure", "placeholder": "Unknown", @@ -100292,7 +101635,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "bridge": "Bridge", "tunnel": "Tunnel", "embankment": "Embankment", - "cutting": "Cutting" + "cutting": "Cutting", + "ford": "Ford" } } }, @@ -100315,6 +101659,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "type": "combo", "label": "Surface" }, + "tactile_paving": { + "key": "tactile_paving", + "type": "check", + "label": "Tactile Paving" + }, "toilets/disposal": { "key": "toilets:disposal", "type": "combo", @@ -100400,6 +101749,11 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "universal": true, "label": "Wheelchair Access" }, + "width": { + "key": "width", + "type": "number", + "label": "Width (Meters)" + }, "wikipedia": { "key": "wikipedia", "type": "wikipedia", @@ -111830,6 +113184,62 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," 504 ] }, + "hairdresser": { + "12": [ + 42, + 528 + ], + "18": [ + 24, + 528 + ], + "24": [ + 0, + 528 + ] + }, + "chemist": { + "12": [ + 96, + 528 + ], + "18": [ + 78, + 528 + ], + "24": [ + 54, + 528 + ] + }, + "mobilephone": { + "12": [ + 150, + 528 + ], + "18": [ + 132, + 528 + ], + "24": [ + 108, + 528 + ] + }, + "scooter": { + "12": [ + 204, + 528 + ], + "18": [ + 186, + 528 + ], + "24": [ + 162, + 528 + ] + }, "highway-motorway": { "line": [ 20, @@ -112153,6 +113563,48 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," 920, 25 ] + }, + "restriction-no-straight-on": { + "relation": [ + 980, + 25 + ] + }, + "restriction-no-u-turn": { + "relation": [ + 1040, + 25 + ] + }, + "restriction-no-left-turn": { + "relation": [ + 1100, + 25 + ] + }, + "restriction-no-right-turn": { + "relation": [ + 1160, + 25 + ] + }, + "restriction-only-straight-on": { + "relation": [ + 1220, + 25 + ] + }, + "restriction-only-left-turn": { + "relation": [ + 1280, + 25 + ] + }, + "restriction-only-right-turn": { + "relation": [ + 1340, + 25 + ] } }, "operations": { @@ -112251,6 +113703,30 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "icon-operation-disabled-continue": [ 220, 160 + ], + "icon-restriction-yes": [ + 50, + 80 + ], + "icon-restriction-no": [ + 95, + 80 + ], + "icon-restriction-only": [ + 140, + 80 + ], + "icon-restriction-yes-u": [ + 185, + 80 + ], + "icon-restriction-no-u": [ + 230, + 80 + ], + "icon-restriction-only-u": [ + 275, + 80 ] }, "locales": [ @@ -112308,6 +113784,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "sl", "es", "sv", + "tl", "ta", "te", "tr", @@ -112498,6 +113975,18 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "not_eligible": "Lines can't be split at their beginning or end.", "multiple_ways": "There are too many lines here to split." + }, + "restriction": { + "help": { + "select": "Click to select a road segment.", + "toggle": "Click to toggle turn restrictions.", + "toggle_on": "Click to add a \"{restriction}\" restriction.", + "toggle_off": "Click to remove the \"{restriction}\" restriction." + }, + "annotation": { + "create": "Added a turn restriction", + "delete": "Deleted a turn restriction" + } } }, "undo": { @@ -112587,7 +114076,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "percent_brightness": "{opacity}% brightness", "none": "None", "custom": "Custom", - "custom_prompt": "Enter a tile template. Valid tokens are {z}, {x}, {y} for Z/X/Y scheme and {u} for quadtile scheme.", + "custom_button": "Edit custom background", + "custom_prompt": "Enter a tile URL template. Valid tokens are {z}, {x}, {y} for Z/X/Y scheme and {u} for quadtile scheme.", "fix_misalignment": "Fix alignment", "reset": "reset" }, @@ -112731,6 +114221,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "category-rail": { "name": "Rail" }, + "category-restriction": { + "name": "Restriction" + }, "category-road": { "name": "Road" }, @@ -112913,6 +114406,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "entrance": { "label": "Type" }, + "except": { + "label": "Exceptions" + }, "fax": { "label": "Fax", "placeholder": "+31 42 123 4567" @@ -112929,6 +114425,33 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "fuel": { "label": "Fuel" }, + "fuel/biodiesel": { + "label": "Sells Biodiesel" + }, + "fuel/diesel": { + "label": "Sells Diesel" + }, + "fuel/e10": { + "label": "Sells E10" + }, + "fuel/e85": { + "label": "Sells E85" + }, + "fuel/lpg": { + "label": "Sells Propane" + }, + "fuel/octane_100": { + "label": "Sells Racing Gasoline" + }, + "fuel/octane_91": { + "label": "Sells Regular Gasoline" + }, + "fuel/octane_95": { + "label": "Sells Midgrade Gasoline" + }, + "fuel/octane_98": { + "label": "Sells Premium Gasoline" + }, "gauge": { "label": "Gauge" }, @@ -112994,6 +114517,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "leisure": { "label": "Type" }, + "length": { + "label": "Length (Meters)" + }, "levels": { "label": "Levels", "placeholder": "2, 4, 6..." @@ -113028,10 +114554,20 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "label": "Type" }, "oneway": { - "label": "One Way" + "label": "One Way", + "options": { + "undefined": "Assumed to be No", + "yes": "Yes", + "no": "No" + } }, "oneway_yes": { - "label": "One Way" + "label": "One Way", + "options": { + "undefined": "Assumed to be Yes", + "yes": "Yes", + "no": "No" + } }, "opening_hours": { "label": "Hours" @@ -113065,6 +114601,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "place": { "label": "Type" }, + "population": { + "label": "Population" + }, "power": { "label": "Type" }, @@ -113104,6 +114643,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "restriction": { "label": "Type" }, + "restrictions": { + "label": "Turn Restrictions" + }, "route": { "label": "Type" }, @@ -113128,6 +114670,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "shop": { "label": "Type" }, + "sloped_curb": { + "label": "Sloped Curb" + }, "smoking": { "label": "Smoking" }, @@ -113151,7 +114696,8 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "bridge": "Bridge", "tunnel": "Tunnel", "embankment": "Embankment", - "cutting": "Cutting" + "cutting": "Cutting", + "ford": "Ford" } }, "studio_type": { @@ -113163,6 +114709,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "surface": { "label": "Surface" }, + "tactile_paving": { + "label": "Tactile Paving" + }, "toilets/disposal": { "label": "Disposal" }, @@ -113206,6 +114755,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "wheelchair": { "label": "Wheelchair Access" }, + "width": { + "label": "Width (Meters)" + }, "wikipedia": { "label": "Wikipedia" }, @@ -113350,6 +114902,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Wash", "terms": "" }, + "amenity/charging_station": { + "name": "Charging Station", + "terms": "EV,Electric Vehicle,Supercharger" + }, "amenity/childcare": { "name": "Childcare", "terms": "nursery,orphanage,playgroup" @@ -113370,6 +114926,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "College", "terms": "" }, + "amenity/compressed_air": { + "name": "Compressed Air", + "terms": "" + }, "amenity/courthouse": { "name": "Courthouse", "terms": "" @@ -113382,6 +114942,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Doctor", "terms": "doctor,doctor's office" }, + "amenity/dojo": { + "name": "Dojo / Martial Arts Academy", + "terms": "martial arts,dojo,dojang" + }, "amenity/drinking_water": { "name": "Drinking Water", "terms": "water fountain,potable water" @@ -113434,6 +114998,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Car Parking", "terms": "" }, + "amenity/parking_entrance": { + "name": "Parking Garage Entrance/Exit", + "terms": "" + }, "amenity/pharmacy": { "name": "Pharmacy", "terms": "" @@ -113679,7 +115247,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": "" }, "building/entrance": { - "name": "Entrance", + "name": "Entrance/Exit", "terms": "" }, "building/garage": { @@ -113862,9 +115430,9 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Photographer", "terms": "photographer" }, - "craft/photographic_labratory": { - "name": "Photographic Labratory", - "terms": "photographic labratory,film developer" + "craft/photographic_laboratory": { + "name": "Photographic Laboratory", + "terms": "photographic laboratory,film developer" }, "craft/plasterer": { "name": "Plasterer", @@ -113959,17 +115527,25 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": "" }, "entrance": { - "name": "Entrance", + "name": "Entrance/Exit", "terms": "" }, "footway/crossing": { "name": "Crossing", + "terms": "" + }, + "footway/crosswalk": { + "name": "Crosswalk", "terms": "crosswalk,zebra crossing" }, "footway/sidewalk": { "name": "Sidewalk", "terms": "" }, + "ford": { + "name": "Ford", + "terms": "" + }, "golf/bunker": { "name": "Sand Trap", "terms": "hazard,bunker" @@ -114016,6 +115592,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," }, "highway/crossing": { "name": "Crossing", + "terms": "" + }, + "highway/crosswalk": { + "name": "Crosswalk", "terms": "crosswalk,zebra crossing" }, "highway/cycleway": { @@ -114039,7 +115619,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": "" }, "highway/motorway_junction": { - "name": "Motorway Junction", + "name": "Motorway Junction / Exit", "terms": "" }, "highway/motorway_link": { @@ -114202,6 +115782,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Cemetery", "terms": "" }, + "landuse/churchyard": { + "name": "Churchyard", + "terms": "" + }, "landuse/commercial": { "name": "Commercial", "terms": "" @@ -114242,6 +115826,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Meadow", "terms": "" }, + "landuse/military": { + "name": "Military", + "terms": "" + }, "landuse/orchard": { "name": "Orchard", "terms": "" @@ -114343,7 +115931,7 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "terms": "" }, "leisure/sports_center": { - "name": "Sports Center", + "name": "Sports Center / Gym", "terms": "gym" }, "leisure/stadium": { @@ -114634,6 +116222,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Neighborhood", "terms": "neighbourhood" }, + "place/suburb": { + "name": "Borough", + "terms": "Boro,Quarter" + }, "place/town": { "name": "Town", "terms": "" @@ -114946,6 +116538,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Photography Store", "terms": "" }, + "shop/seafood": { + "name": "Seafood Shop", + "terms": "fishmonger" + }, "shop/shoes": { "name": "Shoe Store", "terms": "" @@ -114986,6 +116582,10 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Video Store", "terms": "" }, + "shop/wine": { + "name": "Wine Shop", + "terms": "winery" + }, "tourism": { "name": "Tourism", "terms": "" @@ -115070,6 +116670,34 @@ iD.introGraph = '{"n185954700":{"id":"n185954700","loc":[-85.642244,41.939081]," "name": "Restriction", "terms": "" }, + "type/restriction/no_left_turn": { + "name": "No Left Turn", + "terms": "" + }, + "type/restriction/no_right_turn": { + "name": "No Right Turn", + "terms": "" + }, + "type/restriction/no_straight_on": { + "name": "No Straight On", + "terms": "" + }, + "type/restriction/no_u_turn": { + "name": "No U-turn", + "terms": "" + }, + "type/restriction/only_left_turn": { + "name": "Left Turn Only", + "terms": "" + }, + "type/restriction/only_right_turn": { + "name": "Right Turn Only", + "terms": "" + }, + "type/restriction/only_straight_on": { + "name": "No Turns", + "terms": "" + }, "type/route": { "name": "Route", "terms": ""