The detection didn't work properly in case the selected manga was in a different language than English or the current active translation.
In that case it didn't work because the translation for that locale wasn't loaded.
So to ensure that the translation exists for each language, we have to hardcode it.
The pages should get shifted to
- the left when enabling
- the right when disabling
the setting.
Currently, the "page push" is inverted.
This can cause the page that is most likely being read to get pushed out of the screen. Which then requires the user to change the page.
Example:
Active page: 1+2
Enable setting: -> 2 (currently) instead of -> 1
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"
In continuous reading modes the pages are always rendered regardless of if they are visible or not. This is the case to prevent layout shifts when prepending pages while scrolling up.
However, this means that a pages "load priority" and its "should load" flag changes everytime the current page changes, which causes unnecessary rerenders.
The "load priority" and "should load" flag do not matter once a page has been loaded and therefore should stay consistent once loaded.
When scrolling really fast, the delta value could increase, which leads to incorrect trackpad detection, because the delta value is not consistent over consecutive scroll events
When increasing the window, the main reader container did not immediately reflect the change and was still smaller than the available width.
In case the viewed pages were filling the full width, this then caused the horizontal scrollbar to appear until the resize action was finished.
Ensure the restored page index is based on the page index at the start of a resize event to maintain consistency.
At least in the continuous horizontal mode, it was possible to sometimes cause the page to change while resizing.
After the slice states got reset, the base reset function just reverted all those resets and only reset the base states in the store (manga, scrollbar, ...)