question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add support/fix? for card-mod

See original GitHub issue

Describe the solution you’d like

Picture elements does not support customizing padding in style, for that you need to use card-mod But it seems this card does not support card-mod yet or it does not work as suppose to.

NOTE: card-mod only works on cards that contain a ha-card element. This includes almost every card which can be seen, but not e.g. conditional, entity_filter, vertical-stack, horizontal-stack, grid.

I put this configuration at the bottom of frigate-hass-card for testing purposes:

card_mod:
  style: |
    ha-card {
      color: red;
    }

As we see in image below, this card has <ha-card> element, but card-mod styles does not inject declared styles. There is card-mod element, but style is empty(filled with <!---->)

image

And this image below shows how it looks when it’s injected in Picture Elements card

image

Current situation: image

What’s my goal with 0px padding: image

Maybe there is easier way to do this that I can’t think of now?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
peledziuscommented, Feb 6, 2022

@dermotduffy Thank you so much for this, works flawlessly!

1reaction
dermotduffycommented, Feb 6, 2022
Read more comments on GitHub >

github_iconTop Results From Across the Web

thomasloven/lovelace-card-mod: Add CSS styles to ... - GitHub
card-mod 3. Allows you to apply CSS styles to various elements of the Home Assistant frontend. Installing. hacs_badge. Install using HACS or see...
Read more >
Card-mod - Add css styles to any lovelace card
🔹 Card-mod - Add css styles to any lovelace card - Dashboards & Frontend - Home Assistant Community.
Read more >
card-mod-helper
card-mod -helper. A Home Assistant tool for figuring out card-mod element selectors for themes. Open Chrome DevTools by right-clicking on a card and ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found