diff --git a/Makefile b/Makefile index 5d0077846..85de984aa 100644 --- a/Makefile +++ b/Makefile @@ -18,7 +18,6 @@ all: \ js/lib/d3.keybinding.js \ js/lib/d3.one.js \ js/lib/d3.size.js \ - js/lib/d3.tail.js \ js/lib/d3.trigger.js \ js/lib/d3.typeahead.js \ js/lib/jxon.js \ diff --git a/combobox.html b/combobox.html index 34deb2d21..663355663 100644 --- a/combobox.html +++ b/combobox.html @@ -23,7 +23,6 @@ - @@ -70,6 +69,7 @@ + diff --git a/index.html b/index.html index 7d76a8712..80868f252 100644 --- a/index.html +++ b/index.html @@ -25,7 +25,6 @@ - @@ -92,6 +91,7 @@ + diff --git a/js/id/renderer/map.js b/js/id/renderer/map.js index be4366355..f672c55ed 100644 --- a/js/id/renderer/map.js +++ b/js/id/renderer/map.js @@ -21,7 +21,7 @@ iD.Map = function(context) { areas = iD.svg.Areas(roundedProjection), midpoints = iD.svg.Midpoints(roundedProjection), labels = iD.svg.Labels(roundedProjection), - tail = d3.tail(), + tail = iD.ui.Tail(), surface, tilegroup; function map(selection) { diff --git a/js/lib/d3.tail.js b/js/id/ui/tail.js similarity index 96% rename from js/lib/d3.tail.js rename to js/id/ui/tail.js index 497bde4e1..6ea83ed87 100644 --- a/js/lib/d3.tail.js +++ b/js/id/ui/tail.js @@ -1,4 +1,4 @@ -d3.tail = function() { +iD.ui.Tail = function() { var text = false, container, inner, @@ -7,8 +7,7 @@ d3.tail = function() { selection_size = [0, 0], transformProp = iD.util.prefixCSSProperty('Transform'); - var tail = function(selection) { - + function tail(selection) { d3.select(window).on('resize.tail-size', function() { selection_size = selection.size(); }); @@ -59,8 +58,7 @@ d3.tail = function() { } if (!container) setup(); - - }; + } tail.text = function(_) { if (!arguments.length) return text; diff --git a/test/index.html b/test/index.html index 948a4bc57..d7c22b43e 100644 --- a/test/index.html +++ b/test/index.html @@ -26,7 +26,6 @@ - @@ -78,6 +77,7 @@ +