From 470a58a3fa125dfb8c342b204fa53e9c34bbf9cd Mon Sep 17 00:00:00 2001 From: itoshi Date: Sat, 26 Jul 2025 11:48:41 +0300 Subject: [PATCH] fix: Fix `panorama` + route scale data --- src/pages/Route/route-preview/Constants.ts | 8 +++---- src/pages/Route/route-preview/Widgets.tsx | 4 ++-- src/pages/Route/route-preview/index.tsx | 1 + src/pages/Snapshot/SnapshotListPage/index.tsx | 3 +++ src/widgets/MediaArea/index.tsx | 1 + src/widgets/MediaViewer/index.tsx | 24 +++++++++++-------- src/widgets/SnapshotRestore/index.tsx | 22 +++++++++++++---- 7 files changed, 43 insertions(+), 20 deletions(-) diff --git a/src/pages/Route/route-preview/Constants.ts b/src/pages/Route/route-preview/Constants.ts index 8fe8b8f..1c4add7 100644 --- a/src/pages/Route/route-preview/Constants.ts +++ b/src/pages/Route/route-preview/Constants.ts @@ -1,7 +1,7 @@ -export const UP_SCALE = 30000; -export const PATH_WIDTH = 15; -export const STATION_RADIUS = 20; -export const STATION_OUTLINE_WIDTH = 10; +export const UP_SCALE = 10000; +export const PATH_WIDTH = 5; +export const STATION_RADIUS = 8; +export const STATION_OUTLINE_WIDTH = 4; export const SIGHT_SIZE = 40; export const SCALE_FACTOR = 50; diff --git a/src/pages/Route/route-preview/Widgets.tsx b/src/pages/Route/route-preview/Widgets.tsx index 000c26d..24945dd 100644 --- a/src/pages/Route/route-preview/Widgets.tsx +++ b/src/pages/Route/route-preview/Widgets.tsx @@ -57,8 +57,8 @@ export function Widgets() { mb: 1, }} > - - + + { return (
+ diff --git a/src/pages/Snapshot/SnapshotListPage/index.tsx b/src/pages/Snapshot/SnapshotListPage/index.tsx index 20c048c..ed44b30 100644 --- a/src/pages/Snapshot/SnapshotListPage/index.tsx +++ b/src/pages/Snapshot/SnapshotListPage/index.tsx @@ -117,12 +117,15 @@ export const SnapshotListPage = observer(() => { { + setIsLoading(true); if (rowId) { await restoreSnapshot(rowId); } setIsRestoreModalOpen(false); setRowId(null); + setIsLoading(false); }} onCancel={() => { setIsRestoreModalOpen(false); diff --git a/src/widgets/MediaArea/index.tsx b/src/widgets/MediaArea/index.tsx index c786352..702f512 100644 --- a/src/widgets/MediaArea/index.tsx +++ b/src/widgets/MediaArea/index.tsx @@ -109,6 +109,7 @@ export const MediaArea = observer( media_type: m.media_type, filename: m.filename, }} + height="40px" /> + -