mirror of
https://github.com/chartjs/Chart.js.git
synced 2024-10-06 12:19:08 +02:00
Add test for normalized option (#8552)
This commit is contained in:
parent
3214005322
commit
cc8e513d0f
39
test/fixtures/scale.timeseries/normalize.js
vendored
Normal file
39
test/fixtures/scale.timeseries/normalize.js
vendored
Normal file
@ -0,0 +1,39 @@
|
||||
module.exports = {
|
||||
threshold: 0.01,
|
||||
config: {
|
||||
type: 'line',
|
||||
data: {
|
||||
datasets: [{
|
||||
data: [
|
||||
{x: '2017', y: null},
|
||||
{x: '2018', y: 1},
|
||||
{x: '2019', y: 2},
|
||||
{x: '2020', y: 3},
|
||||
{x: '2021', y: 4}
|
||||
],
|
||||
fill: false
|
||||
}]
|
||||
},
|
||||
options: {
|
||||
normalized: true,
|
||||
scales: {
|
||||
x: {
|
||||
type: 'timeseries',
|
||||
time: {
|
||||
parser: 'YYYY'
|
||||
},
|
||||
distribution: 'linear',
|
||||
ticks: {
|
||||
source: 'data'
|
||||
}
|
||||
},
|
||||
y: {
|
||||
display: false
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
options: {
|
||||
spriteText: true
|
||||
}
|
||||
};
|
BIN
test/fixtures/scale.timeseries/normalize.png
vendored
Normal file
BIN
test/fixtures/scale.timeseries/normalize.png
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 22 KiB |
Loading…
Reference in New Issue
Block a user