Commit Graph

4318 Commits

Author SHA1 Message Date
Evert Timberg
41612d1320
Convert the curve helpers to TS (#10733)
* Convert the curve helpers to TS
* Remove old type
2022-10-07 08:28:24 -04:00
Evert Timberg
06bbadb00f
Convert the PointElement to TS (#10730)
Co-authored-by: Chart.js <>
2022-10-07 08:28:03 -04:00
Brainshaker95
813943ac72
Types: Change grid option of CartesianScaleOptions and RadialLinearScaleOptions to Partial of GridLineOptions (#10760) 2022-10-07 07:36:57 +03:00
Jacco van den Berg
72b185afa6
Allow to configure X and Y axis ID in TS for bubble charts (#10739)
* Update namespace

* Allow for x and y axisId to be passed to bubbledataset controller
2022-10-06 22:41:51 +03:00
Evert Timberg
e6892a92cb
Convert helpers.extra to TS (#10728)
Co-authored-by: Chart.js <>
2022-10-06 15:37:42 -04:00
wenzdey
1d6b8f3b44
Updated dead sample link (#10748)
* Updated dead sample link

* Updated option sample
2022-10-06 10:36:26 -04:00
stockiNail
c51d697d7f
Use the correct area to clip for dataset drawing when stacked scales are used (#10691)
* Use the correct area to clip when stacked scales are used

* adds test cases

* fix CI issue

* apply review

* Update .size-limit.cjs

Co-authored-by: Jacco van den Berg <jaccoberg2281@gmail.com>

Co-authored-by: Jacco van den Berg <jaccoberg2281@gmail.com>
2022-10-01 21:26:45 +03:00
Evert Timberg
740ae60db0
Export declare const enums (#10729)
Co-authored-by: Chart.js <>
2022-09-30 16:13:35 -04:00
Luciano Santana
6f4b365d8b
Types: Export UpdateModeEnum as const (#10726)
Co-authored-by: Luciano Santana <contacto@lucianosantana.net>
2022-09-30 11:15:59 -04:00
Dan Onoshko
d1e118aea8
refactor: move batch of helpers to ts (#10722)
* refactor: move batch of helpers to ts

* refactor: review fixes
2022-09-30 09:48:12 -04:00
Dan Onoshko
52cf8e8a94
fix: aspect ratio calc (#10693) 2022-09-28 15:31:19 -04:00
Jacco van den Berg
dec3d2338f
Update namespace (#10719) 2022-09-28 07:54:58 +03:00
Jacco van den Berg
dea889b980
Add defaults to plugin interface (#10712) 2022-09-27 13:39:48 +02:00
Jacco van den Berg
b6322f3ab5
add ts explanation and unify display of snipets (#10708) 2022-09-27 13:39:35 +02:00
Jacco van den Berg
fbaf28e4f8
Use guard clause typings (#10683)
* Use guard clasue

* use function type instead of build in function
2022-09-27 14:00:48 +03:00
Jacco van den Berg
5f37ba6fc4
Add warning if filler plugin is used but not registered (#10702)
* add warning if filler plugin is used but not registered

* fix lint

* increase size limit

* add test, only put warning in dataset controller

* fix register in docs, remove commented code

* remove other mr

* add documentation

* Apply suggestions from code review

Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>

* Also return false if plugin is disabled by options

* improve warning message

* undo docs changes

* update test

Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>
2022-09-26 20:20:54 +02:00
Jacco van den Berg
a8b7def547
Exclude dist folder form linting (#10701) 2022-09-24 23:21:17 +02:00
Dan Onoshko
22f32af1bc
fix: calc visible points on update (#10667) 2022-09-24 17:01:47 -04:00
Kartik
1253ceddb1
FIX: render multiline legend items without overlapping (#10532) (#10641)
* FIX: render multiline legend items without overlapping (#10532)

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* CLN: Extract method to fix codeclimate line count

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* CLN: Shift helper methods from class to module scope

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* TST: Add test with fixtures

Co-authored-by: kartik <codebull707@gmail.com>

* FIX: Fix test case for multiline label

Co-authored-by: kartik <codebull707@gmail.com>

* 10532-ENH: Calculate legend item width for multiline labels

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* 10532-TST: use spriteText and non-empty labels for test

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* 10532-FIX: failing test case due to legendItem.text being undefined

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>

* 10532-FIX: Update compression size

Co-authored-by: kartik <codebull707@gmail.com>

Co-authored-by: Nirav Chavda <nmchavda99@gmail.com>
2022-09-16 09:46:53 -04:00
stockiNail
d4e106cc9c
Provide an empty object when the target of the resolver is undefined (#10655)
* Provide an empty object when the target of the proxy is undefined

* changes check on subGetTarget function

* adds test case

* fixes lint
2022-09-15 12:12:35 -04:00
Dan Onoshko
47cb9e1f76
feat: typescript node next support (#10661) 2022-09-14 06:44:57 -04:00
Jacco van den Berg
cc65c2bac2
Fix autoskip logic (#10663)
* fix autoskip logic

* add test

* fix lint erro

* Update variable name
2022-09-13 19:33:22 +02:00
Rupert B
1c9e536de2
Update line-boundaries.md (#10666)
Fixed broken link in docs
2022-09-13 19:32:48 +02:00
stockiNail
9871aaa262
Use ticks.steSize instead of time.stepSize on time and timeseries scales (#10653) 2022-09-10 18:46:26 +03:00
Dan Onoshko
83a41c2e0c
fix: types and tests (#10660) 2022-09-10 11:36:50 -04:00
Lonylis
21305e2883
Update bar data type to comply with floating bar charts data (#10652)
* Update index.d.ts

Floating bars charts can take an array of array.
https://www.chartjs.org/docs/latest/samples/bar/floating.html

* Update types/index.d.ts

Co-authored-by: Jacco van den Berg <jaccoberg2281@gmail.com>

* floating bar chart data validation

Co-authored-by: Jacco van den Berg <jaccoberg2281@gmail.com>
2022-09-06 09:42:04 -04:00
Dan Onoshko
0c51ecd451
fix: respect aspect ratio with container height (#10646)
* fix: respect aspect ratio with container height

* docs: add info into migration guide
2022-09-02 08:03:41 -04:00
Dan Onoshko
8ff853c60e
feat: remove default axis override when custom id is given (#10643)
* feat: remove default axis override when custom id is given

* docs: add info into migration guide

* test: fix tests for the feat

* docs: add info into migration guide

* test: fix tests for the feat

* feat: review fixes

* feat: review fixes
2022-09-02 07:52:48 +03:00
Dominic Jean
0edb2ac604
enable pointStyleWidth for all legend style (#10639) 2022-09-01 06:37:12 -04:00
Alex
eee1bf257b
Update release.yml (#10642) 2022-08-31 09:54:21 -04:00
Evert Timberg
b95ba3d5c3
Convert the easing helpers to typescript (#10627)
Co-authored-by: Chart.js <>
2022-08-31 09:53:54 -04:00
Jacco van den Berg
818b933c92
Bump markdown-it in docs (#10632)
* bump dep

* regenerate lock with new pnpm
2022-08-31 16:46:23 +03:00
Jacco van den Berg
08a5c572e8
Update link to master umd build (#10645) 2022-08-31 08:24:21 +02:00
Devesh Pal
74f50df250
Fix broken link (#10640) 2022-08-29 17:02:08 -04:00
Dan Onoshko
f957aad352
docs: fix images loading (#10621)
* docs: fix images loading

* docs: temporary restore configureWebpack

* docs: rm html-webpack-plugin
2022-08-23 15:30:03 +02:00
Jukka Kurkela
1d6b8cc047
Document components for bundle optimization (#10569)
* Update integration.md

* Update integration.md

* Fix typo

* Another typo

* Update docs/getting-started/integration.md

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>

* Update docs/getting-started/integration.md

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>

* review update

* version

Co-authored-by: Rich Lott <artfulrobot@users.noreply.github.com>
Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>
2022-08-23 08:41:20 +03:00
Jacco van den Berg
432d1e6a60
move option to correct namespace (#10613)
* move option to correct namespace

* change plugin name from snake_case to camelCase
2022-08-22 22:44:04 +02:00
Jacco van den Berg
b0a06d1652
fix filter paramater in package.json (#10614) 2022-08-22 23:30:29 +03:00
Jacco van den Berg
3c33d87dd2
Remove tooltip constructor fallbacks, this.chart and this._chart (#10612)
* remove tooltip fallbacks/backwards compatability in constructor

* increase size limit
2022-08-22 21:17:40 +02:00
Jacco van den Berg
fc8a63e26b
fix lint in docs (#10611) 2022-08-22 21:00:26 +02:00
Ben McCann
9258f250b6
Switch to pnpm (#10576) 2022-08-22 20:42:43 +02:00
Jacco van den Berg
96633cc0f6
Documentation: how to add static typing to plugins (#10607)
* Add documentation on how to add static typing to plugins

* make the options optional

* Fix syntax
2022-08-22 21:20:35 +03:00
Jukka Kurkela
3b76488373
Refine logarithmic scaling / tick generation (#9166)
* Refine logarithmic scaling / tick generation

* Disable autoSkip on reverese test

* Reduce ticks, fix min
2022-08-22 14:05:27 -04:00
Dan Onoshko
2031cdf051
Preparing the project for TypeScript (#10595)
* Add Typescript to the build
* Converts the `helpers.core` to Typescript as an example
* Converts the `core.element` to Typescript
2022-08-22 11:58:57 -04:00
Grant Hynd
75793eb86f
fix: allow beforeTooltipDraw to be cancelable (#10598) 2022-08-22 17:33:02 +02:00
Jon Dufresne
eaee1ad63b
Use the element's window in getComputedstyle (#10608) 2022-08-22 17:29:36 +02:00
Jacco van den Berg
3eb947719e
Put the border opts in own object (#10571)
* put borderOpts in own object

* document z option

* remove todo and change scaleId to id

* update some tests

* clean bit, remove console log

* fix failing test

* lint

* Remove comment
2022-08-18 15:07:46 +02:00
Jacco van den Berg
49b16c9678
Change react integration test to TS (#10605)
* switch to ts

* change web integration test to TS

* remove space

* lint things

* one more lint

* Add spaces
2022-08-18 08:42:40 -04:00
Dan Onoshko
e7372ade24
fix: same-looking tooltips on charts (#10548)
* fix: same-looking tooltips on multiseries charts

* fix: same-looknig tooltips on all chart types

* chore: restore tooltip plugin

* docs: additions to migration guide

* docs: remove labels from scatter and bubble examples

* docs: review fix
2022-08-18 07:34:35 -04:00
Jacco van den Berg
d09e424a0a
Use borderRadius for legend and remove fallbacks (#10551)
* Use borderRadius for legend

* re enable test

* fix lint

* add note in migration guide

* Update types/index.d.ts

Co-authored-by: Jukka Kurkela <jukka.kurkela@gmail.com>
2022-08-18 07:34:18 -04:00