Webpage Card background

Hello,

I’m using a Webpage Card to integrate a custom chart. My issue is that the background of iframe can’t be transparent to have the general theme background.
My card yaml configuration :

type: iframe
url: /local/chart/chart.html?v=1
aspect_ratio: 70%

I set

background: transparent;

to html and body in chart.html

The iframe HTML render :
image

I saw that

allowtransparency="true"

could allow transparency on iframe. Would it be possible to add this ? Or to add styling on Webpage Card to choose.

Thanks

2 Likes

I think it’s not an issue with the card itself. Note that if you remove the <meta name="color-scheme" content="dark"> tag from <html><head>, then the iframe will have the correct (transparent) background.