preload next & prev grid image modal

This commit is contained in:
Martti Malmi
2023-12-19 16:19:59 +02:00
parent c1c99f1b9e
commit 47f70b0157
4 changed files with 21 additions and 5 deletions

View File

@ -8,6 +8,7 @@ import getEventMedia from "@/Element/Event/getEventMedia";
interface SpotlightThreadModalProps {
thread: NostrLink;
className?: string;
onClose?: () => void;
onBack?: () => void;
onNext?: () => void;
@ -24,7 +25,7 @@ export function SpotlightThreadModal(props: SpotlightThreadModalProps) {
};
return (
<Modal id="thread-overlay" onClose={onClose} bodyClassName={"flex flex-1"}>
<Modal className={props.className} onClose={onClose} bodyClassName={"flex flex-1"}>
<ThreadContextWrapper link={props.thread}>
<div className="flex flex-row h-screen w-screen">
<div className="flex w-full md:w-2/3 items-center justify-center overflow-hidden" onClick={onClickBg}>