Some things I recognized while fiddling around with the ECharts:
Line charts (and maybe other chart types) will set its own background in dark mode, instead of being transparent as in light mode - so that custom styling on the enclosing component gets hidden behind.
I could imagine that executing js functions isn’t allowed for security reasons?! Or did I miss anything here?
I think adding the single axis (timeline)-chart could also be helpful in the future, to achieve something like the BasicUI timeline inside the MainUI without have to fiddle something similar with f7-components:
See → Timeline for Basic UI - #15 by Mihai_Badea
The single axis type, looks like it would fit that use-case?!
Maybe you’ll find time give me some advice here or at least use this for future development of the implementation.
I’m on 3.1 snapshot now, too, and testing around.
One big issue for me: On my android devices the charts are not displayed, neither the chart pages nor the chart widgets.
It will show the legend, the min/max balloons, the points, but not the bars or the lines of the series.
Hey! I have been using/testing with Safari and Chrome from both laptop and iPhone and did not notice any problems - however, based on your feedback did try to access OH through https://home.myopenhab.org/... and while it renders perfectly fine on my laptop (both Safari and Chrome), it does not seem to render i.e. gauge on my iPhone (again, in both Safari and Chrome) - will check what is going on, but first will upgrade to a more recent snapshot since I’m still on #2155 … but don’t think this will change anything. Small hint, you can always upgrade MainUI using
Just checked why gauge would not work on my iPhone - and seen that js files did not yet contain the new additions - so cleared browser cache + did a purge cache in the about section - now everything loads in both Safari and Chrome on my iPhone too.
I have tried this, and at least on my Android 9 Tablet in Chrome it did not work. I cleared the browser cache and went to About->Reload on openhab (not sure if that’s exactly how it’s called in english).
Could it be that the period expression is not yet evaluated? It will only take hardcoded values for now - at least for me:
Only if you’re using HTTPS and the service worker (that’s in charge of caching) was registered. It cannot register if you’re not on a so-called “secure origin”. On myopenhab.org these conditions are satisfied so you get the caching and other features (like the ability to install as a PWA from Chrome or Firefox, and use speech recognition in the HABot chat box).
Yes, the caching when in PWA mode (with the service worker) is much more aggressive and will basically cache the entire application (JS, CSS, fonts) so the network will only be used for the API calls and eventual images.
But I have one more question. Is it possible to display several time series on top of each other. I need something like this for my photovoltaic system. The total power consumption is made up of the solar power plus the battery power plus the income from the grid. These three values added together give the total consumption. Can I display this in the graph? I found a similar example in the dikumentantion of the echarts. I can’t get this to work though.