From c1363afb555d37d8d6a1330ac93839ac01d55baa Mon Sep 17 00:00:00 2001
From: DrMint <29893320+DrMint@users.noreply.github.com>
Date: Fri, 24 May 2024 19:23:17 +0200
Subject: [PATCH] Added hotkey to navigate scans
---
src/components/Lightbox.astro | 42 ++++++++++++++++++++++++++++++-----
1 file changed, 37 insertions(+), 5 deletions(-)
diff --git a/src/components/Lightbox.astro b/src/components/Lightbox.astro
index 03e3d40..a59df5c 100644
--- a/src/components/Lightbox.astro
+++ b/src/components/Lightbox.astro
@@ -1,5 +1,4 @@
---
-import Button from "components/Button.astro";
import {
type EndpointCredit,
type EndpointImage,
@@ -14,6 +13,7 @@ import type { ComponentProps } from "astro/types";
import AppLayoutDescription from "./AppLayout/components/AppLayoutDescription.astro";
import Attributes from "./Attributes.astro";
import { sizesToSrcset } from "src/utils/img";
+import { Icon } from "astro-icon/components";
interface Props {
previousImageHref?: string | undefined;
@@ -55,10 +55,11 @@ const hasNavigation = previousImageHref || nextImageHref;
{
hasNavigation && (
-
+
)
}
@@ -76,10 +77,11 @@ const hasNavigation = previousImageHref || nextImageHref;
{
hasNavigation && (
-
+
)
}
@@ -160,3 +162,33 @@ const hasNavigation = previousImageHref || nextImageHref;
overflow-wrap: anywhere;
}
+
+{/* ------------------------------------------- JS --------------------------------------------- */}
+
+