]> git.ipfire.org Git - thirdparty/Chart.js.git/commit
Bugfix: return nearest non-null point on interaction when spanGaps=true (#11986)
authorMariss Tubelis <mariss@mariss.no>
Fri, 3 Jan 2025 15:50:56 +0000 (16:50 +0100)
committerGitHub <noreply@github.com>
Fri, 3 Jan 2025 15:50:56 +0000 (10:50 -0500)
commita77a63b16bc99fb588ca5252bfa62a09f32db2a6
tree975f9680e4a93d7c44c4c14c74ac03fdc0d5c55b
parent1e3d6e5711d60ed7f5212b62cfd3a6ce6ff4b503
Bugfix: return nearest non-null point on interaction when spanGaps=true (#11986)

* First step in fixing the bug of spanGaps null point interaction

* Complete bugfix of spanGaps null point interaction

* Add two tests in core.interaction.tests for the bugfix change

* Remove odd line break

* Use isNullOrUndef helper for point value checks

* Add 10 more test cases for nearest interaction when spanGaps=true
src/core/core.interaction.js
src/helpers/helpers.extras.ts
test/specs/core.interaction.tests.js