Lovelace: Problem with local_file camera and disconnecting Wi-Fi

I use an appdaemon app, that downloads a “meteogram” once a day and saves it as a png in

/config/www/meteograms/meteogram.png

I show the png via a local_file camera:

camera:
  - platform: local_file
    name: Meteogram
    file_path: /config/www/meteograms/meteogram.png

and a picture-elements card:

      - type: picture-elements
        image: /local/meteograms/meteogram.png
        elements:
          - type: image
            entity: camera.meteogram
            camera_image: camera.meteogram
            style:
              left: 50%
              top: 50%
              width: 100%
              height: 100%

When I load the frontend, everything is fine. But as soon, as the displaying device (e.g. a tablet) looses wi-fi connection for a few seconds, it looks like this screenshot - the huge grey bar - and it does not change to normal any more:

What I tried without success:

  • generic camera, but this didn’t work (maybe my fault?)
camera:
  - platform: generic
    name: Meteogram_generic
    still_image_url: https://127.0.0.1:8123/local/meteograms/meteogram.png
    verify_ssl: false
  • Picture-entity card
cards:
  - type: picture-entity
    entity: camera.meteogram
    show_name: false
    show_state: false

Can anyone please help me?

Ah, I forgot some information: when I reload the page, the png is completely shown again, the grey bar disappears until the next disconnect occurs.
These disconnects are only 1 or a few seconds, but enough for making trouble…

I’m using the generic camera with a direct link to yr weather.

- platform: generic
  still_image_url: https://www.yr.no/place/Germany/Bavaria/W%C3%BCrzburg/meteogram.svg
  name: YR Vorhersage 48h
  content_type: 'image/svg+xml'

I’m not having Wi-Fi disconnects, so not sure if this helps.

Thank you for your answer.
I use a meteogram from meteograms.com, because they are very customizable. But they are delivered as png.
I think the Wi-Fi module of the tablet is not good, that’s why I have those disconnects. But I see the same effect when I open Lovelace frontend on my PC, go to another tab for some time, and then come back to Lovelace. I think Chrome sets unused tabs to some sleep mode or something, where the connection is stopped for some time.