From 60c8e016da2ed39cb5d3d4b381cc0f4a14f1ea77 Mon Sep 17 00:00:00 2001 From: neoapps-dev Date: Sun, 26 Apr 2026 15:15:36 +0300 Subject: [PATCH] fix: screenshots:// on windows again --- public/Skins/700.png | Bin 0 -> 2646 bytes src/components/views/ScreenshotsView.tsx | 157 +++++++++---- src/components/views/SkinsView.tsx | 1 + src/components/views/VersionsView.tsx | 277 +++++++++++++++++------ 4 files changed, 318 insertions(+), 117 deletions(-) create mode 100644 public/Skins/700.png diff --git a/public/Skins/700.png b/public/Skins/700.png new file mode 100644 index 0000000000000000000000000000000000000000..b6b61edfbee29c5fb548740eb36ccfcf993dff7c GIT binary patch literal 2646 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 Ef*4#Eod5s; literal 0 HcmV?d00001 diff --git a/src/components/views/ScreenshotsView.tsx b/src/components/views/ScreenshotsView.tsx index d215569..c0aa53a 100644 --- a/src/components/views/ScreenshotsView.tsx +++ b/src/components/views/ScreenshotsView.tsx @@ -1,14 +1,23 @@ import { useState, useEffect, memo } from "react"; import { motion, AnimatePresence } from "framer-motion"; -import { useUI, useAudio, useGame, useConfig } from "../../context/LauncherContext"; -import { ScreenshotService, ScreenshotInfo } from "../../services/ScreenshotService"; +import { + useUI, + useAudio, + useGame, + useConfig, +} from "../../context/LauncherContext"; +import { + ScreenshotService, + ScreenshotInfo, +} from "../../services/ScreenshotService"; const ScreenshotsView = memo(function ScreenshotsView() { const { setActiveView } = useUI(); const { playPressSound, playBackSound } = useAudio(); const { editions } = useGame(); const { animationsEnabled } = useConfig(); const [screenshots, setScreenshots] = useState([]); - const [selectedScreenshot, setSelectedScreenshot] = useState(null); + const [selectedScreenshot, setSelectedScreenshot] = + useState(null); const [loading, setLoading] = useState(true); const [gridFocusIndex, setGridFocusIndex] = useState(0); const [modalFocusIndex, setModalFocusIndex] = useState(0); @@ -35,7 +44,9 @@ const ScreenshotsView = memo(function ScreenshotsView() { if (!selectedScreenshot) return; playPressSound(); await ScreenshotService.deleteScreenshot(selectedScreenshot.path); - setScreenshots((prev) => prev.filter((s) => s.path !== selectedScreenshot.path)); + setScreenshots((prev) => + prev.filter((s) => s.path !== selectedScreenshot.path), + ); setSelectedScreenshot(null); setShowDeleteConfirm(false); }; @@ -47,7 +58,11 @@ const ScreenshotsView = memo(function ScreenshotsView() { if (e.key === "Escape" || e.key === "Backspace") { playBackSound(); setShowDeleteConfirm(false); - } else if (e.key === "ArrowLeft" || e.key === "ArrowRight" || e.key === "Tab") { + } else if ( + e.key === "ArrowLeft" || + e.key === "ArrowRight" || + e.key === "Tab" + ) { e.preventDefault(); playPressSound(); setDeleteConfirmFocusIndex((prev) => (prev === 0 ? 1 : 0)); @@ -78,8 +93,7 @@ const ScreenshotsView = memo(function ScreenshotsView() { playPressSound(); setDeleteConfirmFocusIndex(0); setShowDeleteConfirm(true); - } - else if (modalFocusIndex === 2) { + } else if (modalFocusIndex === 2) { playBackSound(); setSelectedScreenshot(null); } @@ -87,17 +101,22 @@ const ScreenshotsView = memo(function ScreenshotsView() { return; } - const cols = window.innerWidth >= 1024 ? 4 : window.innerWidth >= 768 ? 3 : 2; + const cols = + window.innerWidth >= 1024 ? 4 : window.innerWidth >= 768 ? 3 : 2; if (e.key === "Escape" || e.key === "Backspace") { handleBack(); } else if (e.key === "ArrowLeft") { setGridFocusIndex((prev) => (prev > 0 ? prev - 1 : prev)); } else if (e.key === "ArrowRight") { - setGridFocusIndex((prev) => (prev < screenshots.length - 1 ? prev + 1 : prev)); + setGridFocusIndex((prev) => + prev < screenshots.length - 1 ? prev + 1 : prev, + ); } else if (e.key === "ArrowUp") { setGridFocusIndex((prev) => (prev >= cols ? prev - cols : prev)); } else if (e.key === "ArrowDown") { - setGridFocusIndex((prev) => (prev <= screenshots.length - 1 - cols ? prev + cols : prev)); + setGridFocusIndex((prev) => + prev <= screenshots.length - 1 - cols ? prev + cols : prev, + ); } else if (e.key === "Enter") { if (screenshots[gridFocusIndex]) { playPressSound(); @@ -109,7 +128,15 @@ const ScreenshotsView = memo(function ScreenshotsView() { window.addEventListener("keydown", handleKeyDown); return () => window.removeEventListener("keydown", handleKeyDown); - }, [loading, selectedScreenshot, gridFocusIndex, modalFocusIndex, screenshots, showDeleteConfirm, deleteConfirmFocusIndex]); + }, [ + loading, + selectedScreenshot, + gridFocusIndex, + modalFocusIndex, + screenshots, + showDeleteConfirm, + deleteConfirmFocusIndex, + ]); useEffect(() => { if (!selectedScreenshot) { @@ -139,12 +166,18 @@ const ScreenshotsView = memo(function ScreenshotsView() {
{loading ? (
- Scanning Archives... + + Scanning Archives... +
) : screenshots.length === 0 ? (
- No screenshots found - Take some in-game with F2 + + No screenshots found + + + Take some in-game with F2 +
) : (
@@ -165,19 +198,23 @@ const ScreenshotsView = memo(function ScreenshotsView() { `} style={{ backgroundImage: "url('/images/frame_background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', - boxShadow: gridFocusIndex === index ? '0 0 20px rgba(255, 255, 85, 0.2)' : 'none', + backgroundSize: "100% 100%", + imageRendering: "pixelated", + boxShadow: + gridFocusIndex === index + ? "0 0 20px rgba(255, 255, 85, 0.2)" + : "none", }} >
{ss.name} { - (e.target as HTMLImageElement).src = "/images/Folder_Icon.png"; + (e.target as HTMLImageElement).src = + "/images/Folder_Icon.png"; }} />
@@ -212,11 +249,17 @@ const ScreenshotsView = memo(function ScreenshotsView() { `} style={{ backgroundImage: "url('/images/Button_Background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated' + backgroundSize: "100% 100%", + imageRendering: "pixelated", + }} + onMouseEnter={(e) => { + (e.currentTarget as HTMLButtonElement).style.backgroundImage = + "url('/images/button_highlighted.png')"; + }} + onMouseLeave={(e) => { + (e.currentTarget as HTMLButtonElement).style.backgroundImage = + "url('/images/Button_Background.png')"; }} - onMouseEnter={(e) => { (e.currentTarget as HTMLButtonElement).style.backgroundImage = "url('/images/button_highlighted.png')"; }} - onMouseLeave={(e) => { (e.currentTarget as HTMLButtonElement).style.backgroundImage = "url('/images/Button_Background.png')"; }} > Back @@ -239,17 +282,18 @@ const ScreenshotsView = memo(function ScreenshotsView() { className="relative max-w-5xl w-full flex flex-col items-center border-2 border-[#555] rounded-sm p-2" style={{ backgroundImage: "url('/images/frame_background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', + backgroundSize: "100% 100%", + imageRendering: "pixelated", }} onClick={(e) => e.stopPropagation()} >
{ - (e.target as HTMLImageElement).src = "/images/Pack_Icon.png"; + (e.target as HTMLImageElement).src = + "/images/Pack_Icon.png"; }} />
@@ -258,7 +302,10 @@ const ScreenshotsView = memo(function ScreenshotsView() { {selectedScreenshot.name} - Captured on {new Date(selectedScreenshot.date * 1000).toLocaleString()} + Captured on{" "} + {new Date( + selectedScreenshot.date * 1000, + ).toLocaleString()}
{getEditionLogo(selectedScreenshot.instanceId) && ( @@ -280,9 +327,12 @@ const ScreenshotsView = memo(function ScreenshotsView() { ${modalFocusIndex === 0 ? "text-[#FFFF55] scale-105" : "text-white"} `} style={{ - backgroundImage: modalFocusIndex === 0 ? "url('/images/button_highlighted.png')" : "url('/images/Button_Background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', + backgroundImage: + modalFocusIndex === 0 + ? "url('/images/button_highlighted.png')" + : "url('/images/Button_Background.png')", + backgroundSize: "100% 100%", + imageRendering: "pixelated", }} > OPEN FOLDER @@ -299,9 +349,12 @@ const ScreenshotsView = memo(function ScreenshotsView() { ${modalFocusIndex === 1 ? "text-[#FF5555] scale-105" : "text-white"} `} style={{ - backgroundImage: modalFocusIndex === 1 ? "url('/images/button_highlighted.png')" : "url('/images/Button_Background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', + backgroundImage: + modalFocusIndex === 1 + ? "url('/images/button_highlighted.png')" + : "url('/images/Button_Background.png')", + backgroundSize: "100% 100%", + imageRendering: "pixelated", }} > DELETE @@ -314,9 +367,12 @@ const ScreenshotsView = memo(function ScreenshotsView() { ${modalFocusIndex === 2 ? "text-[#FFFF55] scale-105" : "text-white"} `} style={{ - backgroundImage: modalFocusIndex === 2 ? "url('/images/button_highlighted.png')" : "url('/images/Button_Background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', + backgroundImage: + modalFocusIndex === 2 + ? "url('/images/button_highlighted.png')" + : "url('/images/Button_Background.png')", + backgroundSize: "100% 100%", + imageRendering: "pixelated", }} > CLOSE @@ -342,8 +398,8 @@ const ScreenshotsView = memo(function ScreenshotsView() { className="w-[420px] p-6 border-2 border-[#555] rounded-sm flex flex-col items-center" style={{ backgroundImage: "url('/images/frame_background.png')", - backgroundSize: '100% 100%', - imageRendering: 'pixelated', + backgroundSize: "100% 100%", + imageRendering: "pixelated", }} onClick={(e) => e.stopPropagation()} > @@ -354,15 +410,21 @@ const ScreenshotsView = memo(function ScreenshotsView() {
@@ -314,18 +361,31 @@ const VersionsView = memo(function VersionsView() { e.stopPropagation(); handleCancelDownload(); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'cancel' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "cancel" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-red-600" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'cancel') || (focusIndex === i && focusBtn === 1) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "cancel") || + (focusIndex === i && focusBtn === 1) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} > - + @@ -337,13 +397,18 @@ const VersionsView = memo(function VersionsView() { e.stopPropagation(); if (!downloadingId) toggleInstall(edition.id); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'download' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "download" }) + } onMouseLeave={() => setHoveredBtn(null)} className={`w-8 h-8 flex items-center justify-center ${downloadingId ? "text-gray-400 cursor-not-allowed" : "text-[#3a3a3a]"}`} style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'download') || (focusIndex === i && focusBtn === 1) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "download") || + (focusIndex === i && focusBtn === 1) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", opacity: downloadingId ? 0.5 : 1, @@ -366,18 +431,31 @@ const VersionsView = memo(function VersionsView() { e.stopPropagation(); handleCancelDownload(); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'cancel' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "cancel" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-red-600" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'cancel') || (focusIndex === i && focusBtn === 1) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "cancel") || + (focusIndex === i && focusBtn === 1) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} > - + @@ -388,13 +466,18 @@ const VersionsView = memo(function VersionsView() { e.stopPropagation(); if (!downloadingId) toggleInstall(edition.id); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'update' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "update" }) + } onMouseLeave={() => setHoveredBtn(null)} className={`w-8 h-8 flex items-center justify-center ${downloadingId ? "text-gray-400 cursor-not-allowed" : "text-[#3a3a3a]"}`} style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'update') || (focusIndex === i && focusBtn === 1) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "update") || + (focusIndex === i && focusBtn === 1) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", opacity: downloadingId ? 0.5 : 1, @@ -414,13 +497,18 @@ const VersionsView = memo(function VersionsView() { playPressSound(); TauriService.openInstanceFolder(edition.id); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'folder' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "folder" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-[#3a3a3a]" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'folder') || (focusIndex === i && focusBtn === 2) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "folder") || + (focusIndex === i && focusBtn === 2) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} @@ -438,13 +526,18 @@ const VersionsView = memo(function VersionsView() { playBackSound(); setDeleteConfirmEdition(edition); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'delete' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "delete" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-[#3a3a3a]" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'delete') || (focusIndex === i && focusBtn === 3) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "delete") || + (focusIndex === i && focusBtn === 3) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} @@ -465,18 +558,31 @@ const VersionsView = memo(function VersionsView() { setEditingEdition(edition); setIsImportModalOpen(true); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'edit' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "edit" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-[#3a3a3a]" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'edit') || (focusIndex === i && focusBtn === 4) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "edit") || + (focusIndex === i && focusBtn === 4) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} > - + @@ -487,18 +593,31 @@ const VersionsView = memo(function VersionsView() { playBackSound(); onDeleteEdition(edition.id); }} - onMouseEnter={() => setHoveredBtn({ row: i, btn: 'delete' })} + onMouseEnter={() => + setHoveredBtn({ row: i, btn: "delete" }) + } onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-red-600" style={{ - backgroundImage: (hoveredBtn?.row === i && hoveredBtn?.btn === 'delete') || (focusIndex === i && focusBtn === 3) - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === i && + hoveredBtn?.btn === "delete") || + (focusIndex === i && focusBtn === 3) + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} > - + @@ -525,14 +644,25 @@ const VersionsView = memo(function VersionsView() { onMouseLeave={() => setHoveredBtn(null)} className="w-8 h-8 flex items-center justify-center text-[#3a3a3a]" style={{ - backgroundImage: (hoveredBtn?.row === editions.length && hoveredBtn?.btn === 'add') || focusIndex === editions.length - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === editions.length && + hoveredBtn?.btn === "add") || + focusIndex === editions.length + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} > - + @@ -547,9 +677,12 @@ const VersionsView = memo(function VersionsView() { title="Import Custom TU" className="w-8 h-8 flex items-center justify-center text-[#3a3a3a]" style={{ - backgroundImage: (hoveredBtn?.row === editions.length && hoveredBtn?.btn === 'folder_import') || focusIndex === editions.length + 1 - ? "url('/images/Button_Square_Highlighted.png')" - : "url('/images/Button_Square.png')", + backgroundImage: + (hoveredBtn?.row === editions.length && + hoveredBtn?.btn === "folder_import") || + focusIndex === editions.length + 1 + ? "url('/images/Button_Square_Highlighted.png')" + : "url('/images/Button_Square.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} @@ -576,9 +709,10 @@ const VersionsView = memo(function VersionsView() { }} className="w-48 h-10 flex items-center justify-center text-xl mc-text-shadow outline-none border-none text-white" style={{ - backgroundImage: focusIndex === editions.length + 2 - ? "url('/images/button_highlighted.png')" - : "url('/images/Button_Background.png')", + backgroundImage: + focusIndex === editions.length + 2 + ? "url('/images/button_highlighted.png')" + : "url('/images/Button_Background.png')", backgroundSize: "100% 100%", imageRendering: "pixelated", }} @@ -623,7 +757,8 @@ const VersionsView = memo(function VersionsView() { Delete {deleteConfirmEdition.name}?

- Warning: All your saves and worlds for this version will be permanently deleted! + Warning: All your saves and worlds for this version will be + permanently deleted!