Skip to content

📱 Material Popup Card

NOTE

Available on 💎 Ultimate Version Only

✨ Overview

The Material Popup Card allows you to create modal popups in your dashboard that can contain any other lovelace card. It mimics the behavior of modern mobile app sheets, providing a smooth and integrated user experience. Trigger it via browser navigation hash changes.

☀️ Light Mode

Control Light
🌙 Dark Mode

Control Dark

✨ Key Features

  • Hash-based Trigger: Opens automatically when the URL hash matches the configured value (e.g., #popup).
  • Drag-to-Close: Supports intuitive swipe-down gestures to close the popup on mobile.
  • Backdrop Blur: Customizable backdrop blur effect for a modern aesthetic.
  • Nested Cards: Can contain any number of standard or custom lovelace cards.
  • Header Customization: Optional header with title, icon, and additional action buttons.
  • Auto-Close: Configurable timer to automatically close the popup.

⚙️ Configuration

NameTypeDefaultDescription
typestringRequiredcustom:material-popup-card
hashstring#popupThe URL hash that triggers this popup to open.
cardslist[]A list of cards to display inside the popup.
headerobjectOptionalConfiguration for the popup header.
settingsobjectOptionalBehavior settings like auto-close and drag sensitivity.
styleobjectOptionalVisual customization options.

Header Options (header)

NameTypeDefaultDescription
show_headerbooleantrueWhether to display the header.
namestringPopupTitle text displayed in the header.
iconstringOptionalIcon displayed next to the title.
entitystringOptionalEntity to display state/toggle in the header.
button_typestringnameControls header interaction: switch, state, or name.
sub_buttonslist[]List of additional icon buttons in the header.

Settings Options (settings)

NameTypeDescription
auto_closenumberTime in milliseconds to auto-close the popup.
close_by_clicking_outsidebooleanClose the popup when clicking the backdrop.
slide_to_close_distancenumberDistance in pixels required to swipe down to close.

Style Options (style)

NameTypeDescription
width_mobilenumberWidth percentage on mobile devices.
width_desktopnumberWidth in pixels on desktop.
border_radiusnumberBorder radius of the popup card in pixels.
backdrop_blurnumberBlur amount for the backdrop in pixels.

🚀 Usage Examples

Example Configuration:

yaml
type: custom:material-popup-card
hash: "#living-room"
header:
  name: Living Room Controls
  icon: mdi:sofa
  entity: light.living_room
  button_type: switch
cards:
  - type: entities
    entities:
      - entity: light.living_room_main
      - entity: switch.tv_plug
style:
  backdrop_blur: 5
  border_radius: 24