From 730ee21651c5399cd7389675cf8d9b37f3da1e6d Mon Sep 17 00:00:00 2001 From: Huang Xin Date: Fri, 2 Jan 2026 15:44:47 +0100 Subject: [PATCH] fix(android): don't navigate back with the back button for more predictable navigation (#2835) This will revert the link navigation with back button in #2454. This will close #2833 and more user reports that found back link navigation confusing. --- apps/readest-app/src/app/reader/components/Reader.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/readest-app/src/app/reader/components/Reader.tsx b/apps/readest-app/src/app/reader/components/Reader.tsx index f131aa59..c9541542 100644 --- a/apps/readest-app/src/app/reader/components/Reader.tsx +++ b/apps/readest-app/src/app/reader/components/Reader.tsx @@ -57,7 +57,7 @@ const Reader: React.FC<{ ids?: string }> = ({ ids }) => { const { settings } = useSettingsStore(); const { libraryLoaded } = useLibrary(); const { sideBarBookKey } = useSidebarStore(); - const { hoveredBookKey, getView } = useReaderStore(); + const { hoveredBookKey } = useReaderStore(); const { showSystemUI, dismissSystemUI } = useThemeStore(); const { getScreenBrightness, setScreenBrightness } = useDeviceControlStore(); const { acquireBackKeyInterception, releaseBackKeyInterception } = useDeviceControlStore(); @@ -100,14 +100,11 @@ const Reader: React.FC<{ ids?: string }> = ({ ids }) => { }, [appService]); const handleKeyDown = (event: CustomEvent) => { - const view = getView(sideBarBookKey!); if (event.detail.keyName === 'Back') { if (getIsSideBarVisible()) { setSideBarVisible(false); } else if (getIsNotebookVisible()) { setNotebookVisible(false); - } else if (view?.history.canGoBack) { - view.history.back(); } else { eventDispatcher.dispatch('close-reader'); router.back();