When using blobs (e.g. due to authentication), manually refreshing caused the thumbnail to break on the manga page.
This was caused because the image got cleaned up, but did not get reloaded again because it was considered to be already loaded.
Regression 3a27461598
Lingui expects the codes to be compliant to BCP-47 while weblate was not set up to create the resource files in that format.
And react-i18next was able to just handle them.
fixes#1058
Switch to "lingui" for better DX.
Tried to persist existing languages as much as possible.
Removed "vite-plugin-node-polyfills" because it's incompatible with "lingui"
* feat(settings): refactor and implement KOReader Sync settings page
Refactors the KOReader Sync settings section into its own dedicated page and implements the full connection and configuration flow.
The previous implementation in the main server settings was outdated and incomplete. This change aligns the frontend with the latest backend logic and provides a complete user experience.
Key changes include:
- Separated the UI into two states: a login form for initial connection and a configuration panel for existing connections.
- Implemented `connectKoSyncAccount` and `logoutKoSyncAccount` mutations to handle authentication with the KOReader Sync server.
- Updated the `SERVER_SETTINGS` GraphQL fragment to use the new `koreaderSyncStrategyForward` and `koreaderSyncStrategyBackward` fields, removing the deprecated `koreaderSyncStrategy`.
- Moved all KOReader Sync settings from the generic Server Settings page to a dedicated route at `/settings/koreader-sync`.
- Restructured and improved i18n keys for better clarity and consistency.
Ran `yarn gql:codegen` to regenerate GraphQL types and helpers.
* Extract credentials login into component
* Update to server changes and cleanup
---------
Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>
This caused the reader to "jump to random pages" because it caused the image to get unrendered and rendered again, leading to layout shifts.
This issue existed already for a long time but could only rarely be observed because of the hacky "cache check" logic.
The changes from 9ed05f3fc0 caused this issue to be consistent in case the new service worker could not get installed due to not meeting the required installation prerequisites. If that was the case, the cache check always returned false causing the above-described behavior.
fixes#929
The server is not requesting these images through an extension; thus, it is not a problem to send them directly to the server since there is no problem of getting the server "stuck" due to extension rate limits.
Improves the image request logic by making it possible to check if an image is cached.
In case an image is cached, it does not need to be put into the image queue because it won't be sent to the server.
In case the previous page in the history should be ignored, the back button just went back to the root page (library).
Instead, it should try to go back to the next page in the history until there is no page to go back to anymore.
With 12ef012e4b this has no benefit anymore, because the app now always checks if authentication is enabled by the server first before any other request can be sent.
Caused issue for some languages, e.g., for all the different chinese languages, which are not all specified in the "IsoLanguages". These languages all incorrectly used the standard native chinese name which resulted in multiple different source groups with the same group name.
* Add dynamic subpath support for WebUI
- Add SubpathConfig utility for server-side subpath detection
- Configure React Router basename from server config
- Update API base URL handling for subpath compatibility
- Fix asset loading with relative paths
- Add VITE_SUBPATH environment variable for development
- Update locales and manifest paths for subpath support
Closes#174
* Move VITE_SUBPATH interface to vite-env.d.ts
* Ensure production bundle always uses relative base
Previously, the drag-scroll implementation used incremental relative positioning
which accumulated rounding errors over time. This caused the mouse cursor to
gradually drift away from its original position during prolonged drag operations,
particularly noticeable on slower hardware or systems with lower frame rates.
The fix switches from cumulative delta updates to absolute positioning:
- Track initial mouse and scroll positions when drag starts
- Calculate scroll position as: initialScroll - (currentMouse - initialMouse)
- This ensures the visual position remains locked throughout the entire drag
This change eliminates drift by avoiding cumulative floating-point
errors that occurred with the previous += approach.
1. Inverted Logic: The code adds the mouse delta to scrollLeft/scrollTop, but this is backwards. When you drag right, you want the content to move left (scroll increases), and vice versa.
2. Cumulative Rounding Errors: Using += with floating-point deltas accumulates rounding errors over time, especially on slower hardware where mousemove events may be processed less frequently or with more delay.
3. Frame Rate Dependency: On slower hardware, if the browser can't keep up with all mouse events, some movements get skipped, but the positions still update, causing the reference point to drift.