How should I implement prev & next in Image app
Unanswered
Black Caiman posted this in #help-forum
![Avatar](https://cdn.discordapp.com/embed/avatars/1.png)
Black CaimanOP
I was trying to clone https://www.pexels.com/
I'm almost there, Just one thing is missing from website. that is, when i click on an image from image-grid, I need next and prev buttons right next to modal.
Main issue is, Image-grid is renders a list of images. These images data is in homepage.
When user clicks on one of the image, we open a modal at
That modal should have
But the image list data is in
I'm really stuck at this stage for a while now. Any hints will be appreciated.
PS: I got the modal working itself, thanks to Parallel & Intercept routes.
Thanks in advance ðŸ™
I'm almost there, Just one thing is missing from website. that is, when i click on an image from image-grid, I need next and prev buttons right next to modal.
Main issue is, Image-grid is renders a list of images. These images data is in homepage.
When user clicks on one of the image, we open a modal at
/image/<ID>
(if user refreshes, it becomes whole page)That modal should have
<
& >
buttons on left and right, to directly visit other images without closing modal and clicking on next image.But the image list data is in
/
(homepage) itself, so idk how to get that in /image/<ID>
page.I'm really stuck at this stage for a while now. Any hints will be appreciated.
PS: I got the modal working itself, thanks to Parallel & Intercept routes.
Thanks in advance ðŸ™
![Image](https://cdn.discordapp.com/attachments/1163139182680621056/1163139185469837453/Screenshot_2023-10-15_at_9.09.43_PM.png?ex=653e7cc7&is=652c07c7&hm=aea522fb0ab58f13b971ac1c4385f60e68f8639ad33633cc1eae37f1cf9a415a&)