Chart.js/test/fixtures/controller.line/clip/specified.json
Jukka Kurkela ce74eb76a1 Convert axis options from arrays to objects (#6773)
* Convert axis options from arrays to objects

* Updated all chart type defaults
* Throw errors when axis type or position are not specified
* Avoid raising unnecessary errors when merging options into the default configs

* Fix additional tests

* Ensure scale defaults are set if type is not explicitly defined

* Another step

* Include `scale` as `firstIDs.r`

* update docs

* Update for buildOrUpdateScales

* Update migration guide

* Add test back
2019-11-21 18:46:49 -05:00

78 lines
2.1 KiB
JSON

{
"config": {
"type": "scatter",
"data": {
"datasets": [
{
"showLine": true,
"borderColor": "red",
"data": [{"x":-4,"y":-4},{"x":4,"y":4}],
"clip": false
},
{
"showLine": true,
"borderColor": "green",
"data": [{"x":-4,"y":-5},{"x":4,"y":3}],
"clip": 5
},
{
"showLine": true,
"borderColor": "blue",
"data": [{"x":-4,"y":-3},{"x":4,"y":5}],
"clip": -5
},
{
"showLine": true,
"borderColor": "brown",
"data": [{"x":-3,"y":-3},{"x":-1,"y":3},{"x":1,"y":-2},{"x":2,"y":3}],
"clip": {
"top": 8,
"left": false,
"right": -20,
"bottom": -20
}
}
]
},
"options": {
"responsive": false,
"legend": false,
"title": false,
"scales": {
"x": {
"min": -2,
"max": 2,
"ticks": {
"display": false
}
},
"y": {
"min": -2,
"max": 2,
"ticks": {
"display": false
}
}
},
"layout": {
"padding": 24
},
"elements": {
"line": {
"fill": false,
"borderWidth": 20
},
"point": {
"radius": 0
}
}
}
},
"options": {
"canvas": {
"height": 256,
"width": 512
}
}
}