From 89b7abf471a96dad65dea8676ffd48e87fbae278 Mon Sep 17 00:00:00 2001 From: "Leon.Schmidt" Date: Thu, 6 Aug 2026 16:58:07 +0200 Subject: [PATCH] ENH - render hosted photo assets --- frontend/src/views/apps/PhotosApp.vue | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/frontend/src/views/apps/PhotosApp.vue b/frontend/src/views/apps/PhotosApp.vue index 2b015de..6ac2a53 100644 --- a/frontend/src/views/apps/PhotosApp.vue +++ b/frontend/src/views/apps/PhotosApp.vue @@ -4,6 +4,7 @@ import { computed, ref } from 'vue' import { useMediaStore } from '@/stores/media' import { usePhoneStore } from '@/stores/phone' +import type { PhonePhoto } from '@/stores/media' const media = useMediaStore() const phone = usePhoneStore() @@ -26,6 +27,20 @@ const filtered = computed(() => phone.t(photo.titleKey).toLowerCase().includes(query.value.toLowerCase()), ), ) + +function photoStyle(photo?: PhonePhoto): Record { + if (!photo) return {} + return { + background: photo.gradient, + ...(photo.url + ? { + backgroundImage: `url(${photo.url})`, + backgroundPosition: 'center', + backgroundSize: 'cover', + } + : {}), + } +}