diff --git a/src/components/media-modal.jsx b/src/components/media-modal.jsx
index 77980f80..721b6ef6 100644
--- a/src/components/media-modal.jsx
+++ b/src/components/media-modal.jsx
@@ -245,7 +245,9 @@ function MediaModal({
left: carouselRef.current.clientWidth * (currentIndex - 1),
behavior: 'smooth',
});
- carouselRef.current.focus();
+ setTimeout(() => {
+ carouselRef.current.focus();
+ }, 100);
}}
>
@@ -261,7 +263,9 @@ function MediaModal({
left: carouselRef.current.clientWidth * (currentIndex + 1),
behavior: 'smooth',
});
- carouselRef.current.focus();
+ setTimeout(() => {
+ carouselRef.current.focus();
+ }, 100);
}}
>