Commit Graph

234 Commits

Author SHA1 Message Date
Talla2XLC
7c14ab74aa
Add new align 'inner' for X axis (#10106)
* Add new align for X axis

new align 'left-right' for options.scales['x'].ticks namespace will allow users to aling ticks: 'start" for first (left) tick and 'end' for last (right) tick

* corrected name of aligment to "inner", documentation and add test for inner labels

* delete unnecessary changes

* corrected logic for reverse axis, add tests for reverse axis and withoutY axis

* corrected chart paddings for "inner" tick align

* code clearness

* Update types/index.esm.d.ts

Co-authored-by: Jacco van den Berg <39033624+LeeLenaleee@users.noreply.github.com>

Co-authored-by: Talla2XLC <alexey.ivanov@epc.com.ru>
Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>
Co-authored-by: Jacco van den Berg <39033624+LeeLenaleee@users.noreply.github.com>
2022-02-12 10:07:00 -05:00
Jérémy Morel
b1876a4b8a
Add missing mouse events to CoreChartOptions.events type (#10124)
* add missing mouse events to CoreChartOptions.events type

* allow all html event names in CoreChartOptions.events
2022-02-09 07:45:30 -05:00
Evert Timberg
cb81592989
Allow spanGaps to be specified on LineOptions (#10133) 2022-02-06 15:11:02 -05:00
Evert Timberg
c869972b60
Ensure that min/max of TimeScaleOptions can be a string (#10137) 2022-02-06 13:53:03 -05:00
Andy
aebbb5afff
fix: allow colors as array (#10075)
* fix: allow colors as array

* Revert "fix: allow colors as array"

This reverts commit 632e2ee917.

* fix: allow colors as array

* Update types/index.esm.d.ts

Co-authored-by: Jacco van den Berg <39033624+LeeLenaleee@users.noreply.github.com>

Co-authored-by: Jacco van den Berg <39033624+LeeLenaleee@users.noreply.github.com>
2022-02-05 19:51:01 +02:00
Evert Timberg
2995775f68
Correct type for updateHoverStyle (#10131)
* Correct type for updateHoverStyle
* Lint fixes
2022-02-05 09:26:31 -05:00
Evert Timberg
49dc77ec0b
Type Chart.legend property (#10130) 2022-02-05 09:13:05 -05:00
Jacco van den Berg
cc807b22d3
add SubTitle to ts test register (#10117) 2022-01-31 12:15:33 -05:00
Jacco van den Berg
6283c6f15b
Change repeating alingment string to single type (#10111)
* Change repeating alignment to single type for ease of maintenance
* improved naming
2022-01-29 11:46:37 -05:00
Dimitri Papadopoulos Orfanos
a7d98fb1a0
Fix typos found by codespell (#10103) 2022-01-27 09:24:55 -05:00
Jacco van den Berg
ec67123df8
move scriptable or array to helper function (#10078) 2022-01-16 17:06:56 -05:00
Jacco van den Berg
4d918f5afa
add typing and docs for maxTicksLimit all scales (#10057)
* add typing and docs for maxTicksLimit time scale

* change maxTicksLimit to base  instead of each scale seperatly since its done in the core.scale
2022-01-11 15:57:35 -05:00
Jukka Kurkela
a5b46a859c
Bump version to 3.7.0, update deps (#10011)
* Bump version to 3.7.0, update deps

* Fix issues from updated packages
2021-12-23 20:55:39 +02:00
t-mangoe
961533c115
Add centerPointLabels option for linear radial scale (#9949)
* center point labels to slices in polar chart

* remove unnecessary comments

* put the code together in one line

* fix the code according to the code review

* Undo changes related to the createContext function

* add documentation and types.
2021-12-21 20:27:07 +02:00
Jacco van den Berg
30bebefc40
Types/ type suggestedMin and suggestedMax for time scale (#9986)
* type suggestedMin and suggestedMax for time scale

* implement feedback
2021-12-14 13:41:47 -05:00
Jacco van den Berg
0a5c058d7a
Types/Allow min-max as string timescale (#9985)
* allow for string in time scale min max config

* add min-max type to docs

* typo
2021-12-14 11:50:37 -05:00
Jukka Kurkela
ba6b446b04
Limit active element changes to chartArea (#9970)
* Limit active element changes to chartArea

* CC, remove duplicate ChartEvent interface

* CC2
2021-12-08 16:44:45 +02:00
Josh Kelley
d83f0467da
Improvements to tooltip positioners (#9944)
* Improve positioner types; allow overriding xAlign and yAlign

* More type improvements; pass in Chart as third parameter

* Expose chart as part of TooltipModel

I initially passed the Chart element as the third parameter to the positioner; however, Scale and LegendElement elements expose `this.chart`, and sample code for positioners used `this._chart`, so documenting the chart member and giving it a public name seems to make more sense.

* Update documentation

* Fix documentation

* Fix issues from code review
2021-12-06 07:39:06 -05:00
Jacco van den Berg
e7aec8c301
add beforeDestroy hook (#9933)
* add `beforeDestroy` hook
* add documentation of destroy lifecycle, add `afterDestroy` hook and deprecate destroy
2021-12-05 09:05:18 -05:00
Jacco van den Berg
d1daf1ac08
allow for multiline labels in tick callback (#9937) 2021-12-05 08:57:44 -05:00
Luuk de Vlieger
7784fbfded
Support "r" axis for non-intersecting interaction (#9919)
* Support "r" axis for non-intersecting interaction

* Extract some interaction functionality

* Remove whitespace and semicolons

* WIP: add interaction test

* Update documentation

* Fix test

* Add another test

* Update axis params

* Add additional axis check to binary search

* Update axis type
2021-12-05 08:57:07 -05:00
Jacco van den Berg
6d3a1c5fa6
Feature/active elements on top (#9920)
* add flag to draw active items on top

* add documentation and types

* remove redundent check

* added test

* resolve linting errors

* increase tollerance

* remove axes for better test, hope no tolerance needed
2021-12-05 08:56:53 -05:00
Jukka Kurkela
cd9d5289a4
Add borderJoinStyle option for arc elements (#9877)
* Add borderJoinStyle option for arc elements
* docs + types
* Consistently enumerate the possible choices
2021-12-05 08:56:37 -05:00
carsonalh
5e5339d01c
Update stale documentation for axis titles (#9683)
* Update stale documentation for axis titles (#9682)

Updated the documentation for the types on axis labels.

In the corresponding `index.esm.d.ts` file, put JSDoc descriptions for
the properties to match the now-updated documentation.

* Clean up axis title labels documentation (#9682)

Inserted extra information in the documentation for the type of the
padding, inserted missing full stops.

In the type file, added JSDoc for undocumented properties.

* Update docs/axes/labelling.md

* Update types/index.esm.d.ts

Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>
2021-11-29 23:37:34 +02:00
Evert Timberg
67aa6eb985
Add a note about the type parameters of the ChartData type (#9917) 2021-11-28 13:01:14 -05:00
Evert Timberg
f8992a6168
Doughnut chart options have an offset property (#9916) 2021-11-28 13:01:00 -05:00
Jacco van den Berg
6c63f7a01b
Types: add autopadding to typing (#9858)
* add autopadding to types

* fix failing test
2021-11-15 23:23:51 +02:00
Jukka Kurkela
e43730eb4d
Fix incomplete TS type for Chart.register + others (#9855) 2021-11-15 12:56:56 -05:00
Jukka Kurkela
2988a6c6dc
Fix type linting and indent errors (#9843)
* Fix type linting and indent errors
* Properly indent comments too
2021-11-11 15:00:52 -05:00
NorthBlue333
7da77a560e
update animation event to include currentStep instead of currentState (#9837) 2021-11-11 18:54:17 +02:00
Jacco van den Berg
359d171683
update animation event to include inital variable (#9834) 2021-11-11 07:20:48 +02:00
Jukka Kurkela
1749e57918
Remove scriptability from defaults.font types (#9794)
* Remove scriptability from defaults.font types

* Remove failing test
2021-10-29 07:32:12 -04:00
Jacco van den Berg
10106e4ec6
Fix object notation border width barchart (#9800)
* make object available for bar as border Radius

* override only the bar borderWidth prop

* spacing
2021-10-26 08:50:07 -04:00
Jukka Kurkela
6a250de81d
Add chart, p0.raw, p1.raw to segment context (#9761)
* Add chart, p0.raw, p1.raw to segment context

* Types
2021-10-15 15:56:29 -04:00
Jukka Kurkela
bc5e5cbf11
Disable animations for BasicPlatform (offcreen) (#9751)
* Disable animations for BasicPlatform (offcreen)
* Update types
2021-10-11 14:37:25 -04:00
Jukka Kurkela
7993fc95dc
Types: Move tooltip methods to model from plugin (#9729) 2021-10-06 08:53:27 -04:00
Evert Timberg
00712f19d6
Support false for doughnut and polar area chart animation options (#9699) 2021-10-01 19:17:36 +03:00
Jukka Kurkela
c3a53f06d7
Bar: fix too thick borders (#9678) 2021-09-25 07:52:03 +03:00
Jukka Kurkela
990a2890d5
Fix some typings issues (#9680)
* Types: Add scope to ticks.callback

* Fix some typings issues
2021-09-24 18:13:53 -04:00
David Sandoz
0e64e53a59
Add align to interface of scale title config (#9634) 2021-09-08 07:26:43 -04:00
aha-oretama
61e3eca198
fix getRelativePosition type definition (#9610)
* fix getRelativePosition type definition

* Update helpers.dom.d.ts

Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>
2021-09-06 09:14:00 -04:00
Evert Timberg
f5c9a656ef
Configurable tooltip box padding (#9625) 2021-09-06 09:13:21 -04:00
Evert Timberg
0cdadd2560
Enable per-corner border radius in tooltip (#9620) 2021-09-05 13:07:28 -04:00
Evert Timberg
6c47a984b0
Remove offscreen canvas (#9617) 2021-09-05 12:59:23 -04:00
Jukka Kurkela
3ed94559dd
Add missing typings of helpers, add automatic test (#9570)
* Add missing typings of helpers, add automatic test

* Add error handling to autogen.js
2021-09-01 20:27:26 -04:00
Evert Timberg
2c8c6ac9ec
Grid line z property in TS types (#9550) 2021-08-14 20:17:12 +03:00
Jacco van den Berg
85cddc8928
Add number to the title scale padding as input type (#9546) 2021-08-13 08:28:10 -04:00
Jukka Kurkela
b4441417ae
Types: Add tooltip to chart instance (#9490) 2021-07-28 07:57:55 -04:00
Jukka Kurkela
1c837a9c12
Fix _isPointInArea helper when no area is provided (#9489) 2021-07-28 07:57:35 -04:00
Jukka Kurkela
243c9707d6
Types: Change context.chart to plain Chart (#9477) 2021-07-27 08:26:54 -04:00