Skip to content

Commit 12711f2

Browse files
committed
d3.svg.*: namespaces are optional as of v2.6.0.
1 parent 5a87998 commit 12711f2

5 files changed

Lines changed: 20 additions & 20 deletions

File tree

d3.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3646,7 +3646,7 @@ function d3_svg_mousePoint(container, e) {
36463646
var point = (container.ownerSVGElement || container).createSVGPoint();
36473647
if ((d3_mouse_bug44083 < 0) && (window.scrollX || window.scrollY)) {
36483648
var svg = d3.select(document.body)
3649-
.append("svg:svg")
3649+
.append("svg")
36503650
.style("position", "absolute")
36513651
.style("top", 0)
36523652
.style("left", 0);
@@ -3807,30 +3807,30 @@ d3.svg.axis = function() {
38073807
// Minor ticks.
38083808
var subticks = d3_svg_axisSubdivide(scale, ticks, tickSubdivide),
38093809
subtick = g.selectAll(".minor").data(subticks, String),
3810-
subtickEnter = subtick.enter().insert("svg:line", "g").attr("class", "tick minor").style("opacity", 1e-6),
3810+
subtickEnter = subtick.enter().insert("line", "g").attr("class", "tick minor").style("opacity", 1e-6),
38113811
subtickExit = transition(subtick.exit()).style("opacity", 1e-6).remove(),
38123812
subtickUpdate = transition(subtick).style("opacity", 1);
38133813

38143814
// Major ticks.
38153815
var tick = g.selectAll("g").data(ticks, String),
3816-
tickEnter = tick.enter().insert("svg:g", "path").style("opacity", 1e-6),
3816+
tickEnter = tick.enter().insert("g", "path").style("opacity", 1e-6),
38173817
tickExit = transition(tick.exit()).style("opacity", 1e-6).remove(),
38183818
tickUpdate = transition(tick).style("opacity", 1),
38193819
tickTransform;
38203820

38213821
// Domain.
38223822
var range = d3_scaleRange(scale),
38233823
path = g.selectAll(".domain").data([0]),
3824-
pathEnter = path.enter().append("svg:path").attr("class", "domain"),
3824+
pathEnter = path.enter().append("path").attr("class", "domain"),
38253825
pathUpdate = transition(path);
38263826

38273827
// Stash a snapshot of the new scale, and retrieve the old snapshot.
38283828
var scale1 = scale.copy(),
38293829
scale0 = this.__chart__ || scale1;
38303830
this.__chart__ = scale1;
38313831

3832-
tickEnter.append("svg:line").attr("class", "tick");
3833-
tickEnter.append("svg:text");
3832+
tickEnter.append("line").attr("class", "tick");
3833+
tickEnter.append("text");
38343834
tickUpdate.select("text").text(tickFormat);
38353835

38363836
switch (orient) {
@@ -3991,19 +3991,19 @@ d3.svg.brush = function() {
39913991
e;
39923992

39933993
// An invisible, mouseable area for starting a new brush.
3994-
bg.enter().append("svg:rect")
3994+
bg.enter().append("rect")
39953995
.attr("class", "background")
39963996
.style("visibility", "hidden")
39973997
.style("pointer-events", "all")
39983998
.style("cursor", "crosshair");
39993999

40004000
// The visible brush extent; style this as you like!
4001-
fg.enter().append("svg:rect")
4001+
fg.enter().append("rect")
40024002
.attr("class", "extent")
40034003
.style("cursor", "move");
40044004

40054005
// More invisible rects for resizing the extent.
4006-
tz.enter().append("svg:rect")
4006+
tz.enter().append("rect")
40074007
.attr("class", function(d) { return "resize " + d; })
40084008
.attr("width", 6)
40094009
.attr("height", 6)

d3.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/svg/axis.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,30 +34,30 @@ d3.svg.axis = function() {
3434
// Minor ticks.
3535
var subticks = d3_svg_axisSubdivide(scale, ticks, tickSubdivide),
3636
subtick = g.selectAll(".minor").data(subticks, String),
37-
subtickEnter = subtick.enter().insert("svg:line", "g").attr("class", "tick minor").style("opacity", 1e-6),
37+
subtickEnter = subtick.enter().insert("line", "g").attr("class", "tick minor").style("opacity", 1e-6),
3838
subtickExit = transition(subtick.exit()).style("opacity", 1e-6).remove(),
3939
subtickUpdate = transition(subtick).style("opacity", 1);
4040

4141
// Major ticks.
4242
var tick = g.selectAll("g").data(ticks, String),
43-
tickEnter = tick.enter().insert("svg:g", "path").style("opacity", 1e-6),
43+
tickEnter = tick.enter().insert("g", "path").style("opacity", 1e-6),
4444
tickExit = transition(tick.exit()).style("opacity", 1e-6).remove(),
4545
tickUpdate = transition(tick).style("opacity", 1),
4646
tickTransform;
4747

4848
// Domain.
4949
var range = d3_scaleRange(scale),
5050
path = g.selectAll(".domain").data([0]),
51-
pathEnter = path.enter().append("svg:path").attr("class", "domain"),
51+
pathEnter = path.enter().append("path").attr("class", "domain"),
5252
pathUpdate = transition(path);
5353

5454
// Stash a snapshot of the new scale, and retrieve the old snapshot.
5555
var scale1 = scale.copy(),
5656
scale0 = this.__chart__ || scale1;
5757
this.__chart__ = scale1;
5858

59-
tickEnter.append("svg:line").attr("class", "tick");
60-
tickEnter.append("svg:text");
59+
tickEnter.append("line").attr("class", "tick");
60+
tickEnter.append("text");
6161
tickUpdate.select("text").text(tickFormat);
6262

6363
switch (orient) {

src/svg/brush.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,19 @@ d3.svg.brush = function() {
1818
e;
1919

2020
// An invisible, mouseable area for starting a new brush.
21-
bg.enter().append("svg:rect")
21+
bg.enter().append("rect")
2222
.attr("class", "background")
2323
.style("visibility", "hidden")
2424
.style("pointer-events", "all")
2525
.style("cursor", "crosshair");
2626

2727
// The visible brush extent; style this as you like!
28-
fg.enter().append("svg:rect")
28+
fg.enter().append("rect")
2929
.attr("class", "extent")
3030
.style("cursor", "move");
3131

3232
// More invisible rects for resizing the extent.
33-
tz.enter().append("svg:rect")
33+
tz.enter().append("rect")
3434
.attr("class", function(d) { return "resize " + d; })
3535
.attr("width", 6)
3636
.attr("height", 6)

src/svg/mouse.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function d3_svg_mousePoint(container, e) {
99
var point = (container.ownerSVGElement || container).createSVGPoint();
1010
if ((d3_mouse_bug44083 < 0) && (window.scrollX || window.scrollY)) {
1111
var svg = d3.select(document.body)
12-
.append("svg:svg")
12+
.append("svg")
1313
.style("position", "absolute")
1414
.style("top", 0)
1515
.style("left", 0);

0 commit comments

Comments
 (0)