fixed weird issue with some dots not showing up

master
Matt Huntington 8 years ago
parent a7d4efea06
commit 8a02443b86

@ -4,17 +4,17 @@ var HEIGHT = 600;
var runs = [ var runs = [
{ {
id: 1, id: 1,
date: 'October 1, 2017 at 4:00pm', date: 'October 1, 2017 at 4:00PM',
distance: 5.2 distance: 5.2
}, },
{ {
id: 2, id: 2,
date: 'October 2, 2017 at 5:00pm', date: 'October 2, 2017 at 5:00PM',
distance: 6.4 distance: 7.0725
}, },
{ {
id: 3, id: 3,
date: 'October 3, 2017 at 6:00pm', date: 'October 3, 2017 at 6:00PM',
distance: 8.7 distance: 8.7
} }
] ]
@ -24,7 +24,7 @@ d3.select('svg')
.style('height', HEIGHT); .style('height', HEIGHT);
var xScale = d3.scaleTime(); var xScale = d3.scaleTime();
var parseTime = d3.timeParse("%B%e, %Y at%-I:%M%p"); var parseTime = d3.timeParse("%B%e, %Y at %-I:%M%p");
xScale.range([0,WIDTH]); xScale.range([0,WIDTH]);
xDomain = d3.extent(runs, function(datum, index){ xDomain = d3.extent(runs, function(datum, index){
return parseTime(datum.date); return parseTime(datum.date);

Loading…
Cancel
Save