251 files
This commit is contained in:
@@ -22,6 +22,7 @@ from .const import (
|
||||
SERVICE_LIST_HIDDEN_PHOTOS,
|
||||
)
|
||||
from .store import SlideshowStore
|
||||
from .viewers import async_register_websocket as async_register_viewer_websocket
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
@@ -336,6 +337,7 @@ async def async_setup(hass: HomeAssistant, config: dict) -> bool:
|
||||
"""
|
||||
hass.data.setdefault(DOMAIN, {})
|
||||
await _async_register_card(hass)
|
||||
async_register_viewer_websocket(hass)
|
||||
|
||||
async def _retry_lovelace_resource(_event) -> None:
|
||||
if hass.data.get(DOMAIN, {}).get("lovelace_resource_registered"):
|
||||
@@ -456,6 +458,14 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||
# itself never has to render a transition burst on the event loop.
|
||||
await _async_register_card(hass)
|
||||
|
||||
# Streams video slides to the card (provider credentials stay server-side).
|
||||
try:
|
||||
from .video import async_register_video_view
|
||||
|
||||
async_register_video_view(hass)
|
||||
except Exception: # noqa: BLE001 - stills keep working without it
|
||||
_LOGGER.exception("Failed to register Album Slideshow video view")
|
||||
|
||||
await _async_cleanup_legacy_entities(hass, entry)
|
||||
|
||||
store = SlideshowStore()
|
||||
|
||||
Reference in New Issue
Block a user