Advertisement
Guest User

Untitled

a guest
Apr 6th, 2025
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.17 KB | Source Code | 0 0
  1. decluttering_templates:
  2. mushroom_custom_area_card:
  3. card:
  4. type: custom:vertical-stack-in-card
  5. cards:
  6. - type: custom:mushroom-template-card
  7. primary: '[[title]]'
  8. secondary: '[[secondary_text]]'
  9. icon: '[[icon]]'
  10. icon_color: '[[icon_color]]'
  11. entity: '[[main_entity]]'
  12. fill_container: true
  13. multiline_secondary: true
  14. layout: horizontal
  15. tap_action:
  16. action: navigate
  17. navigation_path: /lovelace/[[url]]
  18. card_mod:
  19. style:
  20. mushroom-state-info$: |
  21. .container {
  22. --card-secondary-font-size: 10px;
  23. --card-secondary-color: grey;
  24. --card-primary-font-size: 15px;
  25. }
  26. mushroom-shape-icon$: |
  27. .shape {
  28. --icon-symbol-size: 40px;
  29. --icon-size: 60px;
  30. }
  31. - type: custom:mushroom-chips-card
  32. chips: '[[chips_second]]'
  33. alignment: end
  34. card_mod:
  35. style: |
  36. :host {
  37. /* We'll store the single icon_color variable here */
  38. --my-color: [[icon_color]];
  39. position: relative; /* needed for ::before layering */
  40. }
  41. ha-card {
  42. /* Make the card itself transparent, so the pseudo-element shows through */
  43. position: relative;
  44. z-index: 1;
  45. background: none !important;
  46.  
  47. --chip-box-shadow: none;
  48. --chip-background: none;
  49. --chip-icon-size: 20px;
  50.  
  51. }
  52. ha-card::before {
  53. content: "";
  54. position: absolute;
  55. z-index: 0;
  56. top: 0;
  57. right: 0;
  58. bottom: 0;
  59. left: 0;
  60.  
  61. /* This is your translucent background overlay */
  62. background-color: var(--my-color);
  63. opacity: 0.4; /* partial transparency => "lighter" effect */
  64. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement