Skip to content

Conversation

@kurkle
Copy link
Member

@kurkle kurkle commented Oct 31, 2019

This PR changes the default clipping so it will clip at chartArea edge, if the scale defining that edge is limited at that end (by ticks.min/ticks.max). If min/max is not defined, the current clipping rules apply (borderWidth / 2 outside chartArea)

Overriding this clipping is also allowed per dataset:

clip: 10 // would clip 10px outside chartArea on each edge
clip: -10 // would clip 10px inside chartArea on each edge
clip: false // would not clip
clip: 0 // would clip to chartArea
clip: { left: 10, right: -10, top: false, bottom: 0) // per edge config

Fixes: #6631

@etimberg etimberg merged commit fa1d329 into chartjs:2.9 Oct 31, 2019
etimberg pushed a commit that referenced this pull request Nov 2, 2019
@kurkle kurkle deleted the clip-2.9 branch November 13, 2019 06:10
exwm pushed a commit to exwm/Chart.js that referenced this pull request Apr 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants