Commit Graph

588 Commits

Author SHA1 Message Date
schroda
1345cfe624 Update manga category selection in case categories changed (#518)
After a manga got added to the library, the category selection dialog did not show the categories the manga got automatically added to.
The selection only got updated after the dialog got closed and opened again

Regression was introduced with 446deeae06
2023-12-27 17:20:28 +01:00
schroda
446deeae06 Feature/library manga actions (#506)
* Extend "IMangaGridProps" from "DefaultGridProps"

* Move library manga filtering into hook

* Add logic to select mangas

* Add manga actions

* Remove cache only policy for category mangas

Unclear why this was added

* Prevent SelectionFAB from being hidden by the mobile footer

On e.g. the library page, the footer is visible and thus, the fab was not completely visible

* Update categories of manga only after clicking "OK"

Previously, selecting a category resulted in an immediate mutation.
To be able to reuse the "CategorySelect" component to change the categories of multiple mangas at once, this behaviour is not suited.

* Add action to change categories of multiple mangas

* Cancel selection mode after removal from library

The mangas would still be selected and other action could get performed. However, this should only be possible for mangas that are in the library

* Remove unintentionally added console log

Accidentally added with 980da657d9
2023-12-25 21:37:45 +01:00
schroda
c115fcd573 Feature/make selection logic reusable (#515)
* Introduce "selectable collection" hook

* Extract "select all" button into component

* Make "SelectionFABActionItem" reusable

Was to tightly coupled to chapters

* Make "SelectionFAB" reusable

Was to tightly coupled to chapters
2023-12-25 21:20:00 +01:00
schroda
168e8f82f6 Use "Footer" to prevent fab overlapping the last item (#517) 2023-12-25 21:15:31 +01:00
schroda
09d1cf91e0 Prevent navigation state update in case path already changed (#511)
The fix of e4beafb11f only worked in dev env and not in prod.
This prevents the navigation state update from getting triggered in case the path has changed in the meantime
2023-12-24 02:36:09 +01:00
schroda
e4beafb11f Cancel the navigation state update correctly (#507)
The timeout was never canceled in case the tab changed, thus, it kept updating the navigation state for the previous tab and the new tab.
2023-12-23 15:15:14 +01:00
schroda
2f8c284c8b Add continue read button to library (#505) 2023-12-19 15:17:00 +01:00
schroda
953ebbe5a6 Add button to mark all chapters as read 2023-12-18 22:46:50 +01:00
schroda
5010b706fd Add button to download all chapters 2023-12-18 22:46:50 +01:00
schroda
90cec35358 Add button to quickly select all chapters 2023-12-18 22:46:50 +01:00
schroda
226f2e170f Handle line breaks in the manga description 2023-12-18 22:46:42 +01:00
schroda
f542c17fd6 Update download subscription to server changes
The download subscription now sends messages for finished downloads, thus, it's not required anymore to refetch the chapters.
2023-12-16 20:35:35 +01:00
schroda
abee8c7c55 Use virtuoso grid state to restore the previous scroll position (#492) 2023-12-10 15:58:28 +01:00
schroda
7d574a29f6 Correctly calculate the remaining time till the next update check (#491) 2023-12-10 00:08:33 +01:00
schroda
9cb72243d6 Automatically check for server updates (#489) 2023-12-09 23:20:52 +01:00
schroda
78310496aa Feature/about screen add option to check for and trigger updates (#485)
* [VersionMapping] Require server version "r1436" for preview

* Move ts util types to new type file

* Add buttons for updating server and webUI
2023-12-09 23:08:27 +01:00
schroda
2caf88ce51 Remove incorrect "ListItemSecondaryAction" usage (#486) 2023-12-09 14:16:59 +01:00
schroda
db5d3ff7c0 Remove "directLink" prop (#488)
Is not required anymore since "Link" of react-router-dom is a "<a>" element now anyway.
It also caused the following warning

"react-dom.development.js:86  Warning: React does not recognize the `directLink` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `directlink` instead. If you accidentally passed it from a parent component, remove it from the DOM element"
2023-12-09 14:16:44 +01:00
schroda
ad0f072651 Feature/automatic chapter deletion more options (#484)
* Add missing translations keys

* [Codegen] Update to latest server schema changes

* [VersionMapping] Require server version "r1431" for preview

* Rename "deleteChaptersAutoMarkedRead" metadata setting

* Add more options to auto delete chapters while reading

Makes it possible to delete the last to fifth to last read chapter instead of only being able to delete the last read chapter
2023-12-05 22:20:13 +01:00
schroda
ee03c56684 Fix/mark previous as read action includes the selected chapter (#483)
* Exclude the current chapter in the "mark prev as read" action

* Prevent unnecessary request for first chapter

In case "mark prev as read" gets called for the first chapter, the is no chapter to mark as read, thus, no request has to be sent
2023-12-05 22:18:53 +01:00
schroda
ee9811bf53 Correctly detect keyboard input "Enter" (#479)
The "code" property returns the physical key that was pressed.
Thus, e.g. "Enter" on the numpad is "NumpadEnter" and not "Enter".
2023-11-26 14:29:03 +01:00
schroda
c6cc7c14dd Update the "lastRunningState" in case update was triggered outside of app (#478) 2023-11-25 18:20:49 +01:00
schroda
47b077cbf5 Feature/update dependencies (#477)
* Remove accidentally committed script

* Update dependencies

* [ESLint] Fix issues

* Remove unnecessary "??" operator

* Update "vite" to v5.x

* Disable "no default export" rule in vite config
2023-11-25 18:13:51 +01:00
schroda
2006ca9109 Feature/handle disabled download ahead limit by default (#475)
* Add a description to the dialog

* Set the default limit to the lowest possible value
2023-11-25 17:15:07 +01:00
schroda
7c69a4a5a1 Feature/global update last timestamp use stale data while fetching (#473)
* Cache last update timestamp

* Correctly detect update as finished

The update status on server side does not get reset, thus, in case a previous update was finished, it would get detected as finished and handled once on the initial render.
2023-11-25 15:35:36 +01:00
schroda
aa01d6712b Update extensions list after extension update (#471) 2023-11-24 03:20:16 +01:00
schroda
7adc28a35c Feature/gql improve queries mutations subscriptions (#470)
* [Codegen] Request less fields for category mutations

* [Codegen] Request less fields for chapter mutations

* [Codegen] Request less fields for downloader mutations

* [Codegen] Request less fields for extension mutations

* [Codegen] Request less fields for manga mutations

* [Codegen] Request less fields for source mutations

* [Codegen] Request less fields for updater subscription

* [Codegen] Request less fields for downloader subscription

* [Codegen] Combine chapter update mutations
2023-11-24 03:17:49 +01:00
schroda
3766540ce5 Add WebUI settings (#460)
* Add WebUI settings

* [VersionMapping] Require server version "r1427" for preview
2023-11-20 22:14:24 +01:00
schroda
cdf9229457 Feature/global update show last update time (#468)
* Show last global update timestamp

* Add update button to "Updates" screen
2023-11-19 22:43:29 +01:00
schroda
99ba45eceb Use mui tooltip for manga titles (#467) 2023-11-19 22:43:21 +01:00
schroda
d12ac27b61 Feature/download ahead while reading (#464)
* Download next chapters when marking chapter as read while reading

* Add "auto delete chapter" settings

* Delete chapter after finished reading

* Delete chapters after marking them as read

* Improve "mark previous as read" action

Send only ids of chapters that are actually unread
2023-11-19 21:17:35 +01:00
schroda
197ee5c94b Persist server settings when disabling them (#462)
Some settings use 0 as the disabled state.
In this case, the previous enabled value was lost.
To prevent this, the last value now gets saved and set again when enabling the setting again
2023-11-19 00:13:49 +01:00
schroda
1fd9b4e744 Disable disallowed settings (#461) 2023-11-19 00:10:30 +01:00
schroda
cac60fed2c Feature/server settings (#458)
* Move "Server Address" setting to server settings

* Rename "ServerDirSetting" to "TextSetting"

* Use "TextSetting" for server address

* Reset value when closing the dialog

* Support passwords in "TextSetting"

* Add server settings
2023-11-18 19:55:44 +01:00
schroda
8d4687428f Fix/app search (#456)
* Auto open search correctly in global search

* Update search input when navigating to previous/next location

* Revert: Navigate to previous page when canceling search

Has to many edge cases and fixing them would require a global history stack which gets saved in the location state.
This then would lead to the apps internal back navigation to be the same as the browsers which is not wanted, since you should not get moved deeper into the apps navigation when clicking the back button

* Correctly autofocus search input

Sometimes the autofocus did not work, since the input did not exist yet by the time the timeout was triggered

* Restore search input open state when navigation to previous/next location

* Restore search input focus when navigating to previous/next location
2023-11-12 19:04:40 +01:00
schroda
35c34b6d1b Feature/search bar improvements (#455)
* Require search to be committed with enter

* Extract back navigation logic into hook

* Navigate to previous page when canceling search

This makes the search the next page in the history stack instead of making it the previous one

* Close and open search depending on the location and available query

* Navigate to previous page in case new query is empty
2023-11-12 03:21:26 +01:00
schroda
0c7498dba6 Prevent pages from getting selected while dragging (#454) 2023-11-12 01:48:10 +01:00
schroda
dabe88385d Feature/reader vertical pager keyboard bindings scrolling (#452)
* Scroll up when clicking shift + space

* Add keyboard bindings to arrow up and down

Align scroll amount with using other keys like space, arrow right/left

* Add scroll inversion with shift to other key bindings

* Scroll per mouse dragging
2023-11-12 01:41:20 +01:00
schroda
9b96560a17 Feature/settings backup (#453)
* Show loading indicator for "NumberSetting"

* [i18n] Add lowercase interpolation format

* Add required dependencies for time settings

* Dynamically import dayjs locales for languages

* Add backup settings
2023-11-12 01:41:10 +01:00
schroda
a0a52b11a1 Fix/pagination of sources which require pages to be fetched in order (#451)
* Handle sources that do not support revalidation

At least e-hentai is not able to handle out of order pagination requests.
E.g. in case the last request was for page 1 and the next one is for page 3, the result will be for page 2, because e-hentai just ignores the request page number and just returns the next page after the last fetched one.

* Optionally clear source browse cache when opening component

At least e-hentai is not able to handle out of order pagination requests.
The revalidation logic will cause exactly this.
Due to this, the revalidation for these sources is disabled.
To prevent an out of date cache, it gets cleared when routing to the source component
2023-11-11 23:43:22 +01:00
schroda
9284e46c45 Prevent SelectionFAB from being behind the "ChapterCard" checkbox (#445)
The MUI Checkbox component has a z-index of 1, which causes it to register the mouse events instead of the "SelectionFAB" which is visually in front of it
2023-11-05 17:22:35 +01:00
schroda
4ab61723e7 Add missing tooltips (#444) 2023-11-05 17:22:29 +01:00
schroda
a6cc757d50 Feature/global update settings update manga metadata (#441)
* Add "updateMangas" setting to global update settings

* Sort "en.json" alphabetically
2023-11-04 14:55:25 +01:00
schroda
14e7af9a4a Feature/modify download settings (#429)
* [Codegen] Update settings fragment

* Extract logic to change a number setting

* Show slider for global update interval setting

* Add download settings
2023-11-04 14:40:43 +01:00
schroda
529fcf2d25 Mark first chapter as read for "mark previous as read" (#435) 2023-10-29 13:32:47 +01:00
schroda
4c6e9a8aa1 Do not add mangas to the default category (#433)
The default category is used as a fallback and should never be actually mapped to mangas in the database.
However, when using the update manga category mutation the server still creates this mapping, which then leads to issues with getting mangas for the default category
2023-10-29 13:15:17 +01:00
schroda
678df88068 Feature/modify global update settings (#432)
* Move setting components in "settings" folder

* Add setting to change global update automation
2023-10-29 02:01:59 +02:00
schroda
4c6d507405 Feature/show backup restore progress (#431)
* Extract "Progress" component

* Show backup restore progress
2023-10-29 01:49:27 +02:00
schroda
5a5b12a9e1 [ESLint] Prefer named exports (#427) 2023-10-28 00:32:02 +02:00
schroda
68e7b4b16d Feature/library global update exclude manga with state (#281)
* Extract global update settings

* Add option to exclude mangas with specific state from global update
2023-10-27 23:39:05 +02:00