Add minor UX improvements
Build and push Docker image / build-and-push (push) Successful in 1m45s

This commit is contained in:
2026-08-31 05:36:14 +02:00
parent 7daf2b1783
commit b10a22442c
-8
View File
@@ -19,12 +19,6 @@ export default function Gallery({
string | null string | null
>(null); >(null);
/*
* Update the URL without causing a Next.js navigation.
*
* router.replace() would render the server page again, causing
* /api/images and /api/tags to be requested again.
*/
const setFullScreenImage = useCallback((imageId: string | null) => { const setFullScreenImage = useCallback((imageId: string | null) => {
setFullScreenImageIdState(imageId); setFullScreenImageIdState(imageId);
@@ -43,7 +37,6 @@ export default function Gallery({
); );
}, []); }, []);
// Read a fullscreen image from the initial URL.
useEffect(() => { useEffect(() => {
const synchronizeWithUrl = () => { const synchronizeWithUrl = () => {
const params = new URLSearchParams(window.location.search); const params = new URLSearchParams(window.location.search);
@@ -59,7 +52,6 @@ export default function Gallery({
}; };
}, []); }, []);
// Prevent the gallery page from scrolling while the modal is open.
useEffect(() => { useEffect(() => {
if (!fullScreenImageId) { if (!fullScreenImageId) {
return; return;