Commit 3234f47a authored by Mike Bostock's avatar Mike Bostock
Browse files

Merge branch 'fix-subscale-time-scale-nice'

parents 840a2d1f d5b18a65
{
"name": "d3",
"version": "3.3.12",
"version": "3.3.13",
"main": "d3.js",
"scripts": [
"d3.js"
......
......@@ -10,7 +10,7 @@
"animation",
"canvas"
],
"version": "3.3.12",
"version": "3.3.13",
"main": "index-browserify.js",
"scripts": [
"d3.js",
......
d3 = function() {
var d3 = {
version: "3.3.12"
version: "3.3.13"
};
if (!Date.now) Date.now = function() {
return +new Date();
......@@ -9242,7 +9242,9 @@ d3 = function() {
var d3_time_scaleMilliseconds = {
range: function(start, stop, step) {
return d3.range(+start, +stop, step).map(d3_time_scaleDate);
}
},
floor: d3_identity,
ceil: d3_identity
};
var d3_time_scaleUTCMethods = d3_time_scaleLocalMethods.map(function(m) {
return [ m[0].utc, m[1] ];
......
This diff is collapsed.
{
"name": "d3",
"version": "3.3.12",
"version": "3.3.13",
"description": "A small, free JavaScript library for manipulating documents based on data.",
"keywords": [
"dom",
......
d3 = (function(){
var d3 = {version: "3.3.12"}; // semver
var d3 = {version: "3.3.13"}; // semver
import "../arrays/bisect";
import "../arrays/range";
import "../core/identity";
import "../core/rebind";
import "../core/true";
import "../scale/linear";
......@@ -161,5 +162,7 @@ d3_time.scale = function() {
var d3_time_scaleMilliseconds = {
range: function(start, stop, step) {
return d3.range(+start, +stop, step).map(d3_time_scaleDate);
}
},
floor: d3_identity,
ceil: d3_identity
};
......@@ -43,6 +43,11 @@ suite.addBatch({
"nicing a polylinear domain only affects the extent": function(linear) {
var x = linear().domain([local(2009, 0, 1, 0, 12), local(2009, 0, 1, 23, 48), local(2009, 0, 2, 23, 48)]).nice(_.time.day);
assert.deepEqual(x.domain(), [local(2009, 0, 1), local(2009, 0, 1, 23, 48), local(2009, 0, 3)]);
},
"nice succeeds on sub-second intervals": function(scale) {
var domain = [local(2013, 0, 1, 12, 0, 0), local(2013, 0, 1, 12, 0, 8)];
var x = scale().domain(domain);
assert.deepEqual(x.nice().domain(), domain);
}
},
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment