-
-
Notifications
You must be signed in to change notification settings - Fork 371
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
some kind resize(width, height) API #36
Comments
i would recommend that you first measure the size of the container you intend to put the charts into using something like element.getBoundingClientRect() and use those metrics to create the uPlot instances. i have no plans to implement auto or fluid sizing in the core, since most of this can be handled outside the lib. and most of the time is not necessary after initial render anyhow. if you need to resize the plots after initial render. i can maybe add a |
A resize() would work perfectly!
…On Mon, Oct 28, 2019, 12:09 PM Leon Sorokin ***@***.***> wrote:
i would recommend that you first measure the size of the container you
intend to put the charts into using something like
element.getBoundingClientRect()
<https://developer.mozilla.org/en-US/docs/Web/API/Element/getBoundingClientRect>
and use those metrics to create the uPlot instances.
i have no plans to implement auto or fluid sizing in the core, since most
of this can be done handled outside the lib. and most of the time is not
necessary after initial render anyhow.
if you need to resize the plots after initial render. i can maybe add a .resize(width,
height) method so you can use that after init.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#36?email_source=notifications&email_token=AAJJQMAE3NIPJF3VVBNA4O3QQ42HXA5CNFSM4JF6NLLKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECOBWFA#issuecomment-547101460>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJJQMBJSWPHCF2G2UO4IALQQ42HXANCNFSM4JF6NLLA>
.
|
this is now available as |
yes, it takes a single |
Use case: Our sensor dashboards are shared by a team of 7 scientists. Some of them have their screens rotated (portrait). They both want to maximize screen usage without changing the code.
Would it be possible to add a "stretch to fit" option?
The text was updated successfully, but these errors were encountered: