-1

I have a chart (photo 1), I want to limit the zoom limit for the user so that at maximum zoom the result was as in photo 1, now as in photo 2. The option with setting fixRightEdge: true is not suitable. in this case rightOffset: 10 does not work and the graph is too close to the right side (can this be changed?)

enter image description here enter image description here

devid
  • 1

1 Answers1

0

Within the TimeScale options, you can have a look at the following:

  • fixLeftEdge
  • fixRightEdge

Additionally, the TimeScaleApi has many methods for controlling the visible range of the chart.

You could also look into adding Whitespace data to the end of the series if you want to leave space on the right side of the plot. Whitespace data is a datapoint with a time but no value.

SlicedSilver
  • 381
  • 1
  • 4
  • If fixRightEdge: true is set, then rightOffset: 20 doesn't work. How to make it work? Perhaps this can be changed in the lightweight-charts.standalone.production.js file itself? – devid Feb 18 '23 at 03:13