How to optimize show_value text position? #406
Unanswered
r-jean-pierre
asked this question in
Q&A
Replies: 3 comments 9 replies
-
Time offsets are indeed the only way I found to do it, but you could also try changing the anchoring with https://plotly.com/javascript/reference/scatter/#scatter-textposition |
Beta Was this translation helpful? Give feedback.
4 replies
-
So, I confirm, it works!
|
Beta Was this translation helpful? Give feedback.
1 reply
-
Just for my own knowledge, inside the $fn({getFromConfig, vars}), is there any way to have some information such as the HA card width or the browser/screenh width? |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I saw some examples of
time_offset
hacks to adapt the horizontal shift ofshow_value
position,but until now it seems they are somehow "hardcoded" as they make use of
hours_to_show
So the question is how to adapt to dynamic zoom or clicks on
rangeselector
to makeshow_value
location not to inside the graph or to inside the right margin? Of course it would have been wonderful to be set in pixels, but I doubt it is possibleI suppose it has something to do with
time_offset
ex
and maybevisible_range
and some maths about proportionality, but after some toying, I failed (as usual...)If someone can give an hint, it would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions