Advertisement
raidolo

Bubble Card with minigraph

Jun 11th, 2025
1,086
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 5.05 KB | None | 0 0
  1. type: vertical-stack
  2.         cards:
  3.           - type: custom:bubble-card
  4.             card_type: pop-up
  5.             name: Sensor
  6.             icon: mdi:motion-sensor
  7.             state: null
  8.             hash: "#motions"
  9.             is_sidebar_hidden: true
  10.             styles: >-
  11.               .bubble-pop-up {
  12.                 background: transparent);          
  13.                 }    
  14.               .close-pop-up {
  15.                 background-color: transparent;
  16.               }
  17.               .bubble-button-card-container {
  18.                 background: transparent !important;
  19.               }  
  20.               .icon-container {background-color:var(--red)!important;}
  21.               .icon-container > ha-icon
  22.               {color:var(--black)!important;opacity:1!important;}
  23.               .bubble-icon {
  24.                 --mdc-icon-size: 22px !important;
  25.               }
  26.             bg_blur: "20"
  27.             shadow_opacity: "20"
  28.             bg_opacity: "88"
  29.             margin_top_mobile: 10px
  30.             margin_top_desktop: 10px
  31.             card_layout: large
  32.           - type: custom:stack-in-card
  33.             cards:
  34.               - type: custom:button-card
  35.                 entity: sensor.10063d1e68bfa731_distance
  36.                 icon: mdi:jellyfish
  37.                 show_entity_picture: true
  38.                 name: Jellyfin
  39.                 styles:
  40.                   card:
  41.                     - border-style: none
  42.                     - box-shadow: 0px 0px 10px -9px black
  43.                   custom_fields:
  44.                     temp:
  45.                       - filter: opacity(100%)
  46.                       - justify-self: start
  47.                       - margin-left: 10px
  48.                       - margin-top: 20px
  49.                       - padding-bottom: 10%
  50.                       - font-size: 65%
  51.                     graph:
  52.                       - padding-top: 0%
  53.                       - width: 100%
  54.                       - height: 100%
  55.                       - margin-bottom: "-3%"
  56.                   icon:
  57.                     - width: 25px
  58.                     - color: auto
  59.                     - margin-right: 10px
  60.                     - margin-top: 5px
  61.                   name:
  62.                     - font-size: 90%
  63.                     - font-weight: var(--mcg-title-font-weight, 500)
  64.                     - justify-self: start
  65.                     - margin-top: 20px
  66.                     - margin-left: 10px
  67.                     - margin-bottom: 10px
  68.                     - opacity: 0.65
  69.                     - text-align: center
  70.                   grid:
  71.                     - grid-template-areas: "\"n i\" \"temp temp\" \"graph graph\""
  72.                     - grid-template-columns: 1fr min-content
  73.                     - grid-template-rows: 1fr min-content min-content min-content
  74.                 custom_fields:
  75.                   temp: |
  76.                    [[[
  77.                       return `<ha-icon
  78.                         icon="mdi:cpu-64-bit"
  79.                         style="width:18px; height: 18px; color:#ff8c00;">
  80.                         </ha-icon><span style="font-size:120%; font-weight: 300;">
  81.                         ${states['sensor.10063d1e68bfa731_distance'].state}%</span>
  82.                         <ha-icon
  83.                         icon="mdi:memory"
  84.                         style="width: 18px; height: 18px; color: #3399ff;">
  85.                         </ha-icon><span style="font-size:120%; font-weight: 300; text-align: center;">
  86.                         ${states['sensor.10063d1e68bfa731_distance'].state}MiB</span>`
  87.                     ]]]
  88.                 card_mod:
  89.                   style: |
  90.                    ha-card {
  91.                       z-index: 1;
  92.                       height: 100px !important;
  93.                     }
  94.               - type: custom:mini-graph-card
  95.                 entities:
  96.                   - entity: sensor.10063d1e68bfa731_distance
  97.                     name: CPU
  98.                     color: "#ff8c00"
  99.                   - entity: sensor.10063d1e68bfa731_distance
  100.                     name: Memory
  101.                     color: "#3399ff"
  102.                     y_axis: secondary
  103.                 height: 50
  104.                 hours_to_show: 24
  105.                 line_width: 3
  106.                 font_size: 50
  107.                 animate: true
  108.                 show:
  109.                   name: false
  110.                   icon: false
  111.                   state: false
  112.                   legend: false
  113.                   fill: fade
  114.                 card_mod:
  115.                   style: |
  116.                    ha-card {
  117.                       position: absolute !important;
  118.                       height: 100%;
  119.                       width: 100%;
  120.                       top: 0px;
  121.                       --ha-card-border-width: 0;
  122.                     }
  123.                     ha-card:after {
  124.                       content: "";
  125.                       position: absolute;
  126.                       width: 100%;
  127.                       height: 100%;
  128.                       background: linear-gradient(to right, var(--card-background-color) 20%, transparent);
  129.                     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement