Skip to content

Add zoomScale, rename doPan to pan, doZoom to zoom#478

Merged
kurkle merged 2 commits intochartjs:masterfrom
kurkle:api-polish
Apr 30, 2021
Merged

Add zoomScale, rename doPan to pan, doZoom to zoom#478
kurkle merged 2 commits intochartjs:masterfrom
kurkle:api-polish

Conversation

@kurkle
Copy link
Copy Markdown
Member

@kurkle kurkle commented Apr 29, 2021

Resolves #126

I was about to just document setting the min and max + chart.update() method, but that way you lose the ability to reset zoom to previous value. So concluded its better to have that functionality built-in.

  • Add zoomScale export and chart instance function
  • Add sample usage of zoomScale
  • Rename exported doPan to pan and doZoom to zoom for consistency with instance API.
  • Add any transition mode support to all of these methods
  • Add augmentation of UpdateModeEnum to include 'zoom'

@kurkle kurkle merged commit a9d8494 into chartjs:master Apr 30, 2021
@kurkle kurkle mentioned this pull request May 2, 2021
@kurkle kurkle deleted the api-polish branch July 1, 2021 05:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Zooming to a specific value

1 participant