Skip to content

Commit

Permalink
Merge pull request #262 from Trombach/fix/background-image
Browse files Browse the repository at this point in the history
use `Image` instead of `Picture` for background
  • Loading branch information
Trombach authored Jun 13, 2024
2 parents 700af11 + 6af9f46 commit 9e8c3e8
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/silly-toys-call.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"homepage": patch
---

use `Image` instead of `Picture` for background
2 changes: 1 addition & 1 deletion src/components/Nav/NavLink.astro
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const isActive = href === pathname || href === pathname.replace(/\/$/, "");
transition:name="active-link"
class:list={[
"absolute -right-4 top-[calc(50%-(theme(spacing.2)/2))] h-2 w-2 rounded-full bg-foreground",
"group-hover:scale transition-transform group-hover:scale-x-[2.0] group-hover:scale-y-[0.1]",
"transition-transform group-hover:scale-x-[2.0] group-hover:scale-y-[0.1]",
"lg:left-[calc(50%-(theme(spacing.2)/2))] lg:top-9",
]}
/>
Expand Down
4 changes: 2 additions & 2 deletions src/layouts/Background.astro
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
import BackgroundImage from "@images/gradient.avif";
import { Picture } from "astro:assets";
import { Image } from "astro:assets";
---

<div
Expand All @@ -10,7 +10,7 @@ import { Picture } from "astro:assets";
"relative",
]}
>
<Picture
<Image
transition:persist="background"
src={BackgroundImage}
alt="Background"
Expand Down

1 comment on commit 9e8c3e8

@vercel
Copy link

@vercel vercel bot commented on 9e8c3e8 Jun 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

astro-homepage – ./

astro-homepage-trombachs-projects.vercel.app
astro-homepage-git-main-trombachs-projects.vercel.app

Please sign in to comment.