-
Notifications
You must be signed in to change notification settings - Fork 229
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
responsive charts #78
Comments
This is a proposed hack in a very simplistic form... The smoothie charts builder page on the smoothie website sort of has a responsive nature in how you can customize the width and the height of a chart. Now, if the requirement is to have responsive width for a chart, how about listening to the window resize event, and then adjusting the chart width attribute on resize?
The problem with this approach is the width is not truly responsive: the width does adjust, and the line is not distorted, but the line remains static and does not update to the new width. |
I'm not sure if changing the attribute is any different from changing the width property of the canvas element directly in Javascript, but I made a CodePen that adjusts the chart width for a window.onresize event and scale teh height to a quarter of the width: http://codepen.io/anon/pen/MpWvjX |
This is now supported. See http://smoothiecharts.org/examples/responsive.html |
It would be awesome if smoothie charts could be updated to be responsive. Looks like there have been a few investigations into this in the past, yet nothing has come of it.
The text was updated successfully, but these errors were encountered: