How to Customize this Zoom Out feature and zoom in should be remain same

Hello There,
I want to customize the zoom out feature so it’s range should be fluctuate as per the given range and also re-plotling should remain with last applied zoom level.
Currently facing issue like if we call the plot method then replotting is happening and previous zoom level got lost.

i’m trying in React.