-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix unable to add markers when autoSize chart option is enabled #1281
Conversation
@victorbrambati Thank you for your PR. We will conduct the code review and QA process before merging, but this will hopefully be done soon. |
@SlicedSilver Surprising! Any changes that you need, you can reply me. |
@victorbrambati I also think it would be good to have a graphics e2e test case which covers this bug. I'm happy to do it but wanted to check first if you wanted to work on this. |
@SlicedSilver Yes I want work on it. |
Great :) Thank you. Here is a some documentation on the graphics tests: https://github.com/tradingview/lightweight-charts/tree/master/tests#graphics You essentially just need to make a There are some examples there which you can use for inspiration, and you could do something similar to the Glitch example on the bug report. |
Thank you @victorbrambati |
@SlicedSilver You're welcome. |
Co-authored-by: Kirill Chetverikov <kirchet@yandex.ru>
Type of PR: bugfix
PR checklist:
autoSize
chart option is enabled #1271N/A
Documentation updateOverview of change:
timeScale.isEmpty()
was returning true. This because there a condition with awidth === 0
. To resolve this issue, an initial size was added so that the markers could be recalculated._recalculateMarkers()
to be easier to read.Glitch Code Sandbox link:
https://glitch.com/edit/#!/hurricane-mahogany-output