[solved] OH3 how to set opacity with background image on location card

I am searching for the right way to set an opacity on an image of a location label card.

This does not seem to work:

slots:
  OG_Bad:
    - component: oh-location-card
      config:
        backgroundImage: /static/Badezimmer1.jpg
        style:
          postion: absolute
          opacity: 0.5
        badges:
          - windows
          - temperature

I don’t know about opacity but you can adjust the brightness.

          config:
            backgroundImage: /static/garage.jpg
            backgroundImageStyle:
              filter: brightness(60%)

60% has worked well for me.

1 Like

Thanks Rich, that is what i was searching for!

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.