chrvadala / react-svg-pan-zoom

:eyes: A React component that adds pan and zoom features to SVG
https://chrvadala.github.io/react-svg-pan-zoom/
MIT License
684 stars 126 forks source link

[react-svg-pan-zoom] Documentation of the `Value` object #176

Open kasbah opened 4 years ago

kasbah commented 4 years ago

Making use of react-svg-pan-zoom (thank you very much for an amazing library!) I find myself working quite a bit with the Value object but as far as I could see it's not really documented. I had to guess that Value.a seems to represent the zoom factor for instance. It would be nice to have some documentation of what all the fields in this object represent.

WouterrV commented 1 year ago

What I figured out so far:

const zoomLevel = zoomPanValues.a;
const xTranslation = zoomPanValues.e;
const yTranslation = zoomPanValues.f;