| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
@kurkle this only updates the docs, but from the PR description I would expect code to have changed as well. Did you accidentally leave some changes off of the PR? |
Sorry, something went wrong.
Its so small change, you missed it. Had any ☕️ yet 😄 |
Sorry, something went wrong.
|
Haha. Sorry This change looks fine to me, but I'm curious why ticks.source: 'data' wouldn't allow you to accomplish the same thing? The other thing I wonder is if any other scales would need this same functionality |
Sorry, something went wrong.
|
I wonder if we can extend the same pattern to the category scale and close out #3193 too |
Sorry, something went wrong.
category scale already supports this, and additionally xLabes/yLabels: Chart.js/src/scales/scale.category.js Lines 15 to 18 in 2a96d83 Not quite sure how this would solve #3193? |
Sorry, something went wrong.
Can't find the chart right now , but for example if there is no data for all desired labels. |
Sorry, something went wrong.
|
@kurkle You might want to update the time scale document? |
Sorry, something went wrong.
There was a problem hiding this comment.
Looks good! I'm curious why linear scales don't need any change to support labels in the scale options?
Sorry, something went wrong.
linear scales just don't support labels in any way (yet). I'd leave that for another PR. |
Sorry, something went wrong.
|
I thought linear scales was using labels to determine the position the x position of each data: data: {
labels: [0, 2, 6, 8],
datasets: [{
data: [1, 4, 8, 2]
}]
}
// e.q.
data: [
{x: 0, y: 1},
{x: 2, y: 4},
{x: 6, y: 8},
{x: 8, y: 2}
] |
Sorry, something went wrong.
|
@simonbrunel It does not work: Pen Chart.js/src/controllers/controller.line.js Lines 21 to 23 in e5c68e2 |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Currently time scale only reads labels from data.labels.
If both axes are time scales, this is not sufficient.
So this PR allows specifying labels under scale options also.