Commit Graph

425 Commits

Author SHA1 Message Date
Shirish
cdee6f4efa [skip ci] Feat: Add OPDS Configs to Server Settings tab (#945)
* Add OPDS config settings

* Address PR comments

* Update serverVersion for PREVIEW

* Add "opdsUseBinaryFileSizes" setting

---------

Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>
2025-07-12 00:41:59 +02:00
schroda
74f0fec02d Fix dnd on touch devices 2025-07-09 00:22:21 +02:00
schroda
1c9d62659f Include "meta" field in manga library fragment
The chapter list options stored in the meta are required for the download action
2025-07-08 22:02:25 +02:00
schroda
fad590eb5d Add "order" filter to chapters query key 2025-07-08 21:56:21 +02:00
schroda
592ca7881e Update download status query cache on external download enqueue
Downloads that got enqueued from outside the webui never got added to the download status query.
To be able to see them, a page refresh was required.
2025-06-28 01:21:31 +02:00
schroda
914262dfac Revert unwanted generated graphql type changes
Accidentally updated some generated graphql types 2e105a0539
2025-06-23 02:01:28 +02:00
schroda
2e105a0539 Introduce "Extension info" screen 2025-06-23 00:05:16 +02:00
schroda
1721c15079 Properly reset state after backup import 2025-06-08 18:47:33 +02:00
schroda
29d0e3ae55 Update download status state via subscription
The download query type (DownloadStatus) and download subscription type (DownloadUpdates) are different.
This means that the download state in the cache does not get automatically updated from the state provided in the subscription.
2025-05-30 21:26:35 +02:00
schroda
c3b22f92a9 Restore virtuoso states on browser back navigation
- manga chapter list
- library duplicates
- updates
- history
- download queue
2025-05-25 16:09:53 +02:00
schroda
822e47084e Add functionality to pin sources 2025-05-17 22:17:15 +02:00
schroda
5d5cd5ac59 Include missing manga data in updater subscription
E.g., the unread chapter count of a manga was not updated in case new chapters were found during the update.

Regression b673047517
2025-05-09 01:49:30 +02:00
schroda
0733c930d4 Save chapter list options on server 2025-04-20 21:45:26 +02:00
schroda
213f561fe4 Replace "react-beautiful-dnd" with "dnd-kit"
"react-beautiful-dnd" has been deprecated for quite some time
2025-04-18 20:55:17 +02:00
schroda
ecbc0e3be2 Support different languages for auto webtoon detection 2025-04-18 00:34:26 +02:00
schroda
898cc200f0 Remove "Infinity" usage 2025-04-18 00:34:23 +02:00
schroda
76167ebb67 Set sensible gql ws-client retry attempt count 2025-04-18 00:34:22 +02:00
schroda
791ccf1f6a Handle server version changes
Server version now contains the "revision" as the "patch" number
2025-04-07 00:01:54 +02:00
schroda
9ad1af4846 Prevent mui card ripple on child element click 2025-04-02 01:25:17 +02:00
Constantin Piber
8079cadae5 Basic modal for switching extension settings (#907)
* Basic modal for switching extension settings

* Improve network usage by including field in query directly

Requesting individually is stupid, when it's a field that is already
available on the server

* Improve extension slider usability

- Always render the element, fixes animations
- Store the selected item in state, allows the back-button to re-open
  dialog

* Update src/modules/extension/components/ExtensionOptions.tsx

Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>

* Update src/modules/extension/components/ExtensionOptions.tsx

Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>

* Fix suggestions

* Use dialog instead of optionsPanel

* Extension options remove redundant NSFW info

* Apply suggestions from code review

Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>

* Use proper dialog title and content for settings dialog

* Use `string | undefined` instead of `string | null` to satisfy `tsc`

---------

Co-authored-by: schroda <50052685+schroda@users.noreply.github.com>
2025-03-24 23:24:12 +01:00
schroda
b673047517 Update to server gql library update changes 2025-03-23 04:04:08 +01:00
schroda
c7611e4ae1 Remove unnecessary virtuoso "group item counts" mapping 2025-03-10 21:58:13 +01:00
Jack
9e5fa7d81a Add history page (#897)
* Add History module and integrate it into the app

Introduce the History module with components for displaying chapter updates, including UI for grouped updates by date. Update routing and constants to incorporate the new /history path.

* Replace "Updates" and "History" with unified "Recent" module

Merged the "Updates" and "History" screens into a single unified "Recent" module with corresponding navigation updates. Adjusted GraphQL types and localization files to reflect the changes. This simplifies navigation and improves user experience.

* Refactor History screen to remove unused components.

Removed unused states, layout effects, and props related to last update timestamp. Renamed variables for better clarity and updated labels and error messages to align with the history context. Simplified component structure for improved maintainability.

* ```
Refactor tab handling and integrate dynamic height adjustments.

Renamed enums for better clarity and consistency. Implemented a `tabsMenuHeight` prop to dynamically adjust component layouts based on observed height changes using `useResizeObserver`. Updated the `Updates` component to consider the calculated heights for improved rendering.
```

* Refactor `groupByDate` parameter and add `lastReadAt` field

Renamed `updates` to `histories` in `groupByDate` for clarity and added a debugging log for input data. Updated GraphQL fragment to include the `lastReadAt` field to support additional functionality.

* Refactor `groupByDate` parameter and add `lastReadAt` field

Renamed `updates` to `histories` in `groupByDate` for clarity and added a debugging log for input data. Updated GraphQL fragment to include the `lastReadAt` field to support additional functionality.

* Refactor `groupByDate` parameter and add `lastReadAt` field

Renamed `updates` to `histories` in `groupByDate` for clarity and added a debugging log for input data. Updated GraphQL fragment to include the `lastReadAt` field to support additional functionality.

* Refactor `groupByDate` parameter and add `lastReadAt` field

Renamed `updates` to `histories` in `groupByDate` for clarity and added a debugging log for input data. Updated GraphQL fragment to include the `lastReadAt` field to support additional functionality.

* "Optimize GraphQL type definition formatting in generated file

Condensed the formatting of the GetChaptersHistoryQuery type to a single line for improved readability and consistency. This change does not affect functionality but enhances maintainability of the generated code."

* Remove UpdateChecker component from History screen

The UpdateChecker component and its related navbar action have been removed from the History screen. This simplifies the navbar setup and eliminates unused functionality in this context.

* Refactor chapter fragment and type references

Updated `ChapterRecentListFieldsFragment` to `ChapterUpdateListFieldsFragment` for better alignment with naming conventions. Adjusted type imports and query structures to maintain consistency across files. No functional changes introduced.

* Refactor padding calculation logic in Updates screen.

Renamed state variable and refactored its logic for clarity and consistency. The updated logic now uses a more descriptive name, `listPadding`, to enhance code readability and maintainability.

* Pass `tabsMenuHeight` prop to History component

Added `tabsMenuHeight` prop to the `History` component to properly calculate the height for the `StyledGroupedVirtuoso` element. This ensures consistency with other components and improves layout rendering.

* Revert package.json

* Add last page read tracking to chapter history

Introduced "lastPageRead" and "pageCount" fields to track progress in chapter history. Updated UI to display the last page read along with total pages for chapters. Adjusted localization files to support the new "page" label.

* Remove last page read display from ChapterHistoryCard

The "last page read" information was removed from the ChapterHistoryCard component for a cleaner UI. This change simplifies the card's design by showing only the chapter name and relevant download state.

* Forcing an empty commit.

* Replace "Recent" screen with separate "Updates" and "History".

The "Recent" feature has been split into two distinct screens, "Updates" and "History", for improved clarity and functionality. Routes, icons, and components have been updated accordingly, and redundant code related to "Recent" has been removed.

* Clean

* Revert vi.json

* Remove unnecessary `useLocation` hook and update state logic.

The `useLocation` hook was removed as it was not used elsewhere in the component. The state property for the routing logic was updated to use `Chapters.getReaderOpenChapterLocationState` for better encapsulation and clarity.

* Update history localization by removing unused "page" key

Removed the "page" key from the "history" section in the localization file as it is no longer in use. This cleanup helps keep the translation file consistent and easier to maintain.

---------

Co-authored-by: NamNH <namitonguyen@gmail.com>
2025-03-10 21:53:40 +01:00
schroda
ffd6c5867f Fix "coerceIn" for calls with max < min
Previously the min value was ignored in case the max value was less than the min value.
E.g. coerceIn(5, 0, -1) would be -1 instead of 0
2025-02-12 19:55:46 +01:00
schroda
c79ccf3523 Improve memoization of "ReaderTransitionPage"
- use chapter properties instead of chapter object
- only pass "handleBack" in case the transition page is for the first or last chapter
2025-02-03 17:17:35 +01:00
schroda
3698c19aba Properly enable cors for images by default 2025-01-26 17:18:27 +01:00
schroda
25e3fc7808 Load images with cors allowed
Without allowing cors it is e.g. not possible to extract colors from an image
2025-01-26 04:20:59 +01:00
schroda
a56fd08bf6 Include http status on rest fetch failure 2025-01-26 03:30:35 +01:00
schroda
c42e51b6f9 Infer server port only in dev env 2025-01-23 13:15:08 +01:00
schroda
a22a4bf546 Switch to "colorSchemes" from "palette" API in mui theme
"colorSchemes" is the preferred api starting from mui v6
2025-01-17 01:25:55 +01:00
schroda
63a6cfcfb3 Add merge function for "DownloadStatus" "queue" field 2025-01-12 20:55:08 +01:00
schroda
e25aa98365 Do not update "download status" on "download updates"
For large download queues this makes the app unusable.

At the moment this is not needed anyway and once it is, it needs to be improved and only be done in the "download queue" page since the queue is only use there
2025-01-12 20:47:16 +01:00
schroda
10a77722cc Remove outdated "download types" from apollo cache 2025-01-12 20:28:20 +01:00
schroda
57f73636a0 Read chapter download status from cache
Instead of getting the whole download status, which contains all queued/active downloads, the download status should be read from the cache for only the required chapters
2025-01-12 14:09:10 +01:00
schroda
530ae1578f Prevent invalid values for "auto scroll speed"
The min/max limit was only acknowledged when the value was changed via MUIs step logic.
In case the number got inputted via keystrokes the limits did not get applied
2024-12-29 23:41:26 +01:00
schroda
33e184ba18 Add "auto webtoon mode" option to reader 2024-12-27 02:51:35 +01:00
schroda
5dbf1aa8e0 Adjust ReaderChapterTransition text color
Text color was never adjusted based on the selected "reader background color"
2024-12-25 02:36:53 +01:00
schroda
94b0e25df2 Update "apollo-upload-client" to v18.x
- apollo-upload-client v18.0.1
- @types/apollo-upload-client v18
2024-12-24 14:19:40 +01:00
schroda
89cab26f73 Fix typing after "apollo-client" update to v3.12.4 2024-12-24 00:36:26 +01:00
schroda
3949363474 Include actual error in snackbar 2024-12-20 17:24:40 +01:00
schroda
916abd3bb1 Resume chapter at specific page
- open from outside reader
 - is read
  - yes: 1st page
  - no : last read page
- inside reader via
 - chapter selection: first page
 - previous chapter : last page
 - next chapter     : first page
2024-12-09 02:38:37 +01:00
schroda
a607f7f368 Reader settings 2024-12-09 02:38:37 +01:00
schroda
7434ed0152 Reader progress bars 2024-12-09 02:38:37 +01:00
schroda
12e8939267 Prevent duplicated downloads in download queue
The mutation to add chapters to the download queue returns the current download queue.

Thus, the local queue already includes the new downloads and adding them blindly in the download subscription will cause them to be in the local queue twice.
2024-12-09 02:38:37 +01:00
schroda
1e109e7d32 Remove deprecated "gqlDebugLogsEnabled" setting 2024-11-28 12:22:17 +01:00
schroda
0c02de5b92 Correctly get total library size
The total size was the sum of all categories, which could include duplicates, since manga can be in multiple categories.

This still will show an incorrect number, because server side there is the same issue with the "mangas" query including duplicates in the total count, however, once this is fixed, the correct count will be displayed
2024-11-28 12:20:36 +01:00
schroda
a819d45489 Update to server download subscription changes 2024-11-28 12:17:55 +01:00
schroda
87ee1330d4 Prevent blinking on reader page switch on firefox
on firefox images are decoded async which causes a "flicker/blinking" when they're getting visible for the first time
this is an issue especially in the reader because pages that should not be shown are rendered but
not displayed, which then causes this issue once they get displayed
2024-11-13 15:47:03 +01:00
schroda
f9938edb75 Extract aborting image requests into function 2024-11-13 14:41:26 +01:00
schroda
e90d705610 Add option to update all updatable extensions 2024-11-04 01:30:09 +01:00