-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Issue#1006: Make bottom margin editable for Chart visualization #1007
Conversation
@@ -121,6 +121,8 @@ | |||
angular.module('plotly', []) | |||
.constant('ColorPalette', ColorPalette) | |||
.directive('plotlyChart', function () { | |||
var baseHeight = 250; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not calculate the height based on the height that is passed to the directive?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another option is to skip setting height here and delegate this to Plotly (by setting the height of the div and only specifying the margin size).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello Arik,
Kumar has gone on vacation and I'm going to pick up where he left off. Which alternative approach would you prefer we take? Delegating to Plotly sounds more elegant. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[image: Inline image 2]
I'm having the same difficulty.
On Wed, Apr 27, 2016 at 3:45 PM, Chris Kozak notifications@github.com
wrote:
In rd_ui/app/scripts/directives/plotly.js
#1007 (comment):@@ -121,6 +121,8 @@
angular.module('plotly', [])
.constant('ColorPalette', ColorPalette)
.directive('plotlyChart', function () {
var baseHeight = 250;
Hello Arik,
Kumar has gone on vacation and I'm going to pick up where he left off.
Which alternative approach would you prefer we take? Delegating to Plotly
sounds more elegant. What do you think?—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
https://github.com/getredash/redash/pull/1007/files/303e158eb1484e9694d90ea27face9465a56d3cc#r61323291
Thanks! |
@arikfr Removed the logic to calculate the height, and instead letting plotly to choose the right height based on the bottom margin. It seems to be working. |
@arikfr any feedback on the latest change? |
Thanks! |
Issue#1006: Make bottom margin editable for Chart visualization
This addresses Issue #1006 by allowing user to modify bottom margin for Chart visualization. When the margin is modified, it adjusts the hight accordingly.