Actually it worked out well being at the end because I have them all static now in one row.
Tell me more! Did not know this. I knew about changing sizes but not aspect ratiosā¦
I would love to get the camera feeds into the dash (maybe the camera widget can be modified?) so this may come in handy to know. If you have a link or pointer, or just want to spell it out for me, Iām sure others would also benefit from it being here.
I never noticed the iframe widget until you mentioned it, as it doesnāt appear to be documented, but I am also unable to get anything but a blank widget.
@aimc is this not an officially supported widget yet?
The iframe widget is one you get for free when you create a dashboard - I havenāt ever used it and it has no spcific significance for HA but it should work.
Ok, gotchaā¦ thatās too bad, since it appears to be broken. The only thing my dashboard is missing is the ability to integrate external data, static text data, or even custom data that does not conform to one of the HA widgets, I was so excited when I saw iframe but if it ever worked before it has since broken.
Thanks for the link to the aspect ratio steps, much appreciated! Between HADashboard and AppDaemon, I am in heaven!!!
@jbags81 had this working with the iframe widget in his dashboard and I posted to the thread asking him to share how he got it to work but he never replied back. Maybe heāll see his mention in this thread and check in.
From what I can see, thereās a CURL involved to actually get the data source, which Dashing then processes. I never got around to it but I started reading the repo here:
That was exactly what I needed to get it working!!!
You donāt need the CURL part if you are doing it inline, so all you need to do is replace the contents of iframe.coffee you posted into the iframe.coffee in HADashboard so that it includes both of those $(@node) lines
Then I just added scrolling=ānoā to the existing iframe.html and it just works
Of course in the example where data-id=āiframeId1ā, that can be anything, and has to be different if you have more than 1 iframe in your dashboard, but yeah, works perfectly!
Of course this will break the next time @aimc does an update, so I have made a backup of my iframe widget folder so I can replace it after each upgrade.
@aimc, you think it would be possible to add these changes to the iframe widget so it will work even after an update?
I had the answer staring me in the face the whole time. I never thought to check iframe.coffee. I guess if I run into any of the other widgets having issues, I should check against latest source.
I made the suggested changes and itās working great now! My only problem is my radar map is too big for the widget. Iām using a gif radar map and I guess thereās no way to resize it, iād have to make the widget too big.
Yeah, I just noticed that as wellā¦ Iām only seeing the top left corner of my contentā¦ hmmmā¦ gonna mess with itā¦ gotta be a way to have the source display based upon the dimensions of the widget.
Could beā¦ gonna do some researchā¦ Iāve had this kind of issue in the past using iframes in other web development projects, so thereās gotta be something out there
Yeah, I tried implementing it but saw no discernible difference in the outcome. Other than that page sounding like what we needed, most of what I am finding is of the mindset that it is not possible to resize the content from another source, as the browser simply sees the iframe as a separate browser window, therefore it renders the source material as if the iframe were a full screen. The source material would have to be changed to render specifically for the size of your iframe.
If your radar map is a gif, you should try the BigImage widget, it auto resizes images to fit the size of the widget. I just tried it with a snapshot url feeding directly off one of my cameras in the house and it resized it correctly, showing the entire field of view of the camera, but resized to the size of my widget. It works with still images and video feeds
I looked at that but the only problem is there is no provision for updating. Youād have to set up a cron job with curl and grab the radar map in a timed interval and copy it to a directory for local display.
Itās too bad we can import the camera class from HA; that would sole all our problems.