Commit Graph

41 Commits

Author SHA1 Message Date
Jukka Kurkela
81acad9f2b
Bubble: Properly parse radius for non-object data (#9764) 2021-10-15 07:57:39 -04:00
Alex Van Liew
f8a9d60fd5
[feat] support crossAlign on mirrored y-axis (#9563) 2021-08-18 07:48:36 -04:00
Jacco van den Berg
259f8e8471
lower default value of grid z index so it draws behind chart elements (#9426) 2021-07-16 11:16:31 -04:00
Evert Timberg
11045a731a
Fix center axis title positions (#9413)
* Fix the title positions for center positioned axes

* Handle center position for vertical axes

* Tests
2021-07-15 08:20:22 -04:00
Jukka Kurkela
7265bb51d5
Update chartjs-test-utils and mis-sized fixtures (#9135) 2021-05-20 14:59:55 +03:00
Jukka Kurkela
3e319f79ab
Scale: draw border on separate layer after grid (#8936) 2021-04-18 07:38:46 -04:00
Evert Timberg
af7965fc31
Cartesian scale tick backdrop (#8931) 2021-04-18 12:49:22 +03:00
Jukka Kurkela
8e535c574c
Skip ticks by callback value as documented (#8914) 2021-04-17 07:28:33 -04:00
Jukka Kurkela
7fab66ccd1
Support mirror option on x-axis (#8867) 2021-04-10 09:01:38 -04:00
Jukka Kurkela
1ffdecfe68
Consider dynamically positioned scales for padding (#8868) 2021-04-10 08:58:39 -04:00
Jukka Kurkela
e1ddaa8992
Dissociate border options from grid options (#8823)
* Dissociate border options from grid options
* Update docs
2021-04-04 14:19:07 -04:00
Jukka Kurkela
1a5a15265a
Revert "Scale: draw offset grid for labels before autoSkip (#8748)" (#8752)
This reverts commit cdba66ccef.
2021-03-30 08:00:19 -04:00
Jukka Kurkela
cdba66ccef
Scale: draw offset grid for labels before autoSkip (#8748)
* Scale: draw offset grid for labels before autoSkip
* fix tests
2021-03-29 16:53:47 -04:00
Jukka Kurkela
416062bf68
Update tick positioning (#8657)
* Update tick positioning
* Update tests
2021-03-17 18:22:21 -04:00
Jukka Kurkela
79cc6d3206
Use maxOverflow as minimum layout padding (#8650)
* Use maxOverflow as minimum layout padding

* fixes
2021-03-16 16:32:29 -04:00
Evert Timberg
6ac89cbb25
Rename scale gridLines options to be clearer (#8628)
* Rename `options.gridLines` to `options.grid`

* Rename `offsetGridLines` to `offset`
2021-03-13 19:49:09 +02:00
Jukka Kurkela
9799dbd5a0
Scale: autoSkip before fit (#8627)
Scale: autoSkip now occurs before fit in the update process
2021-03-13 11:36:12 -05:00
Jukka Kurkela
bedc3f1575
Fix autoSkip (#8619)
* Fix autoSkip
* Add tests
2021-03-11 16:25:16 -05:00
Jukka Kurkela
d48a62a4e9
Add backgroundColor for scales (#8606)
* Add backgroundColor for scales
* Loosen the threshold
2021-03-10 08:18:10 -05:00
Jukka Kurkela
f7ebedc367
Scale: refactor drawTitle, add tests (#8598)
* Scale: refactor drawTitle, add tests
* CC, lint
* update
2021-03-09 08:35:43 -05:00
Evert Timberg
279b6ae1da
Enable multi-line axis titles (#8579) 2021-03-06 10:18:32 -05:00
Jukka Kurkela
5285735c0f
Fix ticks.mirror (#8482) 2021-02-21 14:27:14 -05:00
Jukka Kurkela
ddfbcf777a
Update eslint-config-chartjs to v0.3.0 (#8406) 2021-02-10 08:21:39 -05:00
LeeLenaleee
ae0c8dd457
align text inside chart for far-aligned labels passing test (#8359)
* align text inside chart for far-aligned labels

* added fix for failing test on suggestion of @kurkle

Co-authored-by: Marcel Samyn <marcel.samyn@lab900.com>
2021-01-31 15:19:40 -05:00
Evert Timberg
da0535e1ff
Horizontal axis with center position should display labels (#8221)
* Horizontal axes with center positions should have labels
* Linting
* Test updates
* Increase the tolerance for one test
2020-12-22 11:33:53 -05:00
Evert Timberg
55a26e69ba
Add options to configure tick styling independent of grid lines (#8215)
* Enable axis tick styling independent of grid lines
* Change tickMarkLength to tickLength for consistency with new options
* Add new scale options to TS definitions
2020-12-22 11:27:57 -05:00
Jukka Kurkela
021561072b
Disable all plugins when options.plugins = false (#8098)
Disabling all plugins when options.plugins = false
2020-11-23 17:58:03 -05:00
Evert Timberg
1ca60808b4
Shorten alignment settings for axes (#7886)
* Rename crossAlignment to crossAlign
* Update alignment to align for cartesian axes
2020-10-14 08:27:54 -04:00
Evert Timberg
29f1358328
Cartesian axis label cross alignment (#7874)
* Refactor Y axis alignment to it's own method
* Label Cross alignment
* Add documentation of new setting
* Update docs with live sample
2020-10-12 10:22:13 -04:00
Evert Timberg
dc4eac6323
Cartesian axis text alignment (#7846)
* Generate textBaseline per tick label
* Enable configuration of tick alignment
* Add image based tests of text alignment options
2020-10-10 11:38:55 -04:00
Jukka Kurkela
59a1af91ac
Replace horizontalBar with indexAxis: 'y' (#7514)
* Replace horizontalBar with indexAxis: 'y'
* Fix drawing of line for last x-position
* Consistently determine axis of scale
* Add test
2020-06-18 17:35:52 -04:00
Evert Timberg
4ab6d7cc2a
Enable override settings for the axis border (#6883)
* Enable override settings for the axis border - #4041

Adds two new options to the cartesian axis: `borderColor` and `borderWidth`
which are used to control the border drawn at the edge of the axis area.
If these options are not set, the first grid line settings are used.

* Correct spelling
2020-01-03 13:55:50 -05:00
Evert Timberg
374b7491a3
Allow axes to be centered on the chart area (#6818)
Allow axes to be centered on the chart area or at a dynamic position based on another axis
2019-12-16 18:17:42 -05:00
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
Jukka Kurkela
7f97adf5a0 Move scale defining options up from ticks (#6738)
* Move scale defining options up from `ticks`
* Include `ticks.reverse` in v3-migration
2019-11-15 12:11:13 -05:00
Jukka Kurkela
91466ae358 Remove remaingin zeroLine* references (#6728) 2019-11-11 12:12:11 -05:00
Evert Timberg
94afa63450
Remove zeroLineIndex functionality (#6697)
* Remove zeroLineIndex functionality

* Remove docs

* Code review updates
2019-11-07 06:27:49 -05:00
Akihiko Kusanagi
40495ec9d0 Fix the rounding issue of floating point numbers in category scale (#5880)
- Remove `Math.round` in the category scale code
- Add `helpers._alignPixel` to align grid/tick/axis border lines
- Fix grid/tick/axis border line calculation
- Add a check of the width of the axis border
- Refactor core.scale code
2018-12-09 11:34:34 +01:00
Evert Timberg
85169c5603
Proper tick position for right positioned axis (#5401)
* Proper tick position for right positioned axis
* Test for tick mark drawing
2018-04-11 18:16:32 -04:00
andig
ea703a54bf Implement scale label padding (#4646) 2017-09-10 13:15:47 -04:00
Suhaib Khan
b03ab1ca45 Fix labelOffset not working for vertical axes (#4249) 2017-07-15 10:19:16 +02:00