Maybe new Image...?
This commit is contained in:
9
src/components/BackgroundImage.astro
Normal file
9
src/components/BackgroundImage.astro
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
import { Image } from "astro:assets";
|
||||
import localBau from "@images/90.png";
|
||||
---
|
||||
|
||||
<Image src={localBau} alt="Bau" widths={[240, 540, 720, 1080, 1920, localBau.width]}
|
||||
sizes={`(max-width: 240px) 240px, (max-width: 540px) 540px, (max-width: 720px) 720px, (max-width: 1080px) 1080px, (max-width: 1920px) 1920px, ${localBau.width}px`}
|
||||
class="w-full h-full object-cover rounded-b-2xl shadow-2xl" quality={100}
|
||||
draggable="false" loading="eager"/>
|
||||
Reference in New Issue
Block a user