From 4f490c1e0687e49d386cbce112a419bb3c8580e6 Mon Sep 17 00:00:00 2001 From: Florian Maul Date: Sun, 13 Aug 2023 13:40:08 +0200 Subject: [PATCH] fix: Fixed issue with right arrow not working --- src/components/GridView/index.tsx | 3 ++- src/components/env.ts | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/components/GridView/index.tsx b/src/components/GridView/index.tsx index c35d96f..2246ee9 100644 --- a/src/components/GridView/index.tsx +++ b/src/components/GridView/index.tsx @@ -26,8 +26,9 @@ const GridView = ({ settings, images }: GridViewProps) => { const onKeyDown = (event: KeyboardEvent) => { console.log(event); + if (event.key === 'ArrowRight') { - setActiveImageIdx(idx => (idx !== undefined && idx < sortedImages.length - 1 ? idx + 1 : idx)); + setActiveImageIdx(idx => idx !== undefined ? idx + 1 : 0); } if (event.key === 'ArrowLeft') { setActiveImageIdx(idx => (idx !== undefined && idx > 0 ? idx - 1 : idx)); diff --git a/src/components/env.ts b/src/components/env.ts index 4fc1ffa..fd39762 100644 --- a/src/components/env.ts +++ b/src/components/env.ts @@ -74,9 +74,9 @@ export const adultContentTags = [ 'naked', 'nakedart', 'nasstr', - 'adult', - 'nude', 'nodestr', + 'nsfw', + 'nude', 'nudeart', 'nudes', 'onlyfans',