Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

when use the min and max in time scale line chart.the graph overflow.thank you #3784

Closed
Ai01 opened this issue Jan 12, 2017 · 3 comments
Closed

Comments

@Ai01
Copy link

Ai01 commented Jan 12, 2017

l don't know how to fix the flow state
2017-01-12 10 41 28

@Ai01
Copy link
Author

Ai01 commented Jan 12, 2017

` var timeFormat = 'MM/DD/YYYY HH:mm:SS';

function startDateString(days) {
  var date = moment().format(timeFormat);
  return date;
}

function endDateString(hours) {
  var date = moment().add(hours, 'h').format(timeFormat);
  return date;
}

xAxes: [{
type: "time",
position: 'bottom',
time: {
displayFormat: 'HH:mm',
unit: 'hour',
min: startDateString(),
max: endDateString(5)
},
scaleLabel: {
display: true,
labelString: 'Time'
},
ticks: {
maxRotation: 0,
userCallback: function(value, index, values) {
//show ticks 10 minutes apart
if (index % 10 == 0) {
return value;
} else {
return null;
}
}
}
}],`

@etimberg
Copy link
Member

Can you try building from master? This was implemented in #3658

@etimberg
Copy link
Member

Actually, I think this might be a duplicate of another issue, #3613
Closing in favour of the older issue

@etimberg etimberg removed this from the Version 2.6 milestone May 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants