Lib: Assign imgclass also to image container

This commit is contained in:
2025-02-26 22:27:43 +01:00
parent c119567a90
commit 5b02b37e38

View File

@ -19,7 +19,7 @@
/** Optional extra style for the lazy <div> container */
containerstyle?: string;
/** Additional classes to insert */
/** Additional classes to insert for container + image */
imgclass?: string;
/** Slightly zoom the image on mouse-hover */
@ -55,7 +55,7 @@
<div
use:lazyload
onLazyVisible={lazy_visible_handler}
class="overflow-hidden"
class="overflow-hidden {imgclass}"
style="aspect-ratio: {imgwidth} / {imgheight}; max-width: {imgwidth}px; max-height: {imgheight}px; {containerstyle ??
''}"
>