Imporve image lazy loading

This commit is contained in:
2026-01-28 12:15:08 +01:00
parent 43fc752535
commit 80e3aa95d8
5 changed files with 47 additions and 80 deletions

View File

@@ -77,6 +77,16 @@ div.luxtools-gallery img.luxtools-thumb {
width: 150px;
height: 150px;
object-fit: cover;
/* Placeholder while lazy-loaded image is pending.
* Uses custom property from inline style if thumb_placeholder is configured,
* otherwise falls back to built-in SVG icon. */
background-color: @ini_background;
background-image: var(--luxtools-placeholder, url(images/placeholder.svg));
background-position: center;
background-repeat: no-repeat;
/* contain works well for both: configured placeholder fills the area,
* built-in SVG icon stays small and centered */
background-size: contain;
}
/* Filename overlay (single line, muted). */