Commit Graph

1096 Commits

Author SHA1 Message Date
schroda
9625436518 get first unread chapter from original chapter list (#250)
The first unread chapter was retrieved from the filtered and sorted chapter list, which could result in e.g. incorrectly recognizing the latest released chapter as the first unread chapter.

Ideally the server would return the manga with its last read chapter, but this is currently not available.
2023-03-03 13:09:11 +03:30
schroda
c6257acdf1 Show empty library in case search doesn't match anything (#251)
* Show empty library in case search doesn't match anything

In case the search didn't match anything all mangas where shown instead of an empty library.

* Rename filter manga function parameter and variable

Makes it easier to read
2023-03-01 22:08:12 +03:30
Daniel
96fd1cf73b remove manually created typing d ts file (#249)
* Rename file

".d.ts" files are files that are automatically generated during compilation (in case option is set) and shouldn't be created manually.

* Export types and interfaces

* Add missing imports
2023-02-24 19:10:37 +03:30
Daniel
1914a61edd Add GitHub Action to run tsc on pull request events (#232) 2023-02-24 19:08:44 +03:30
Weblate (bot)
56fe90d049 Translations update from Hosted Weblate (#241)
* Added translation using Weblate (Norwegian Bokmål)

* Translated using Weblate (French)

Currently translated at 100.0% (2 of 2 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/fr/

* Deleted translation using Weblate (French)

* Translated using Weblate (Norwegian Bokmål)

Currently translated at 100.0% (2 of 2 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/nb_NO/

* Deleted translation using Weblate (Norwegian Bokmål)

* Added translation using Weblate (German)

* Added translation using Weblate (Arabic)

* Translated using Weblate (German)

Currently translated at 20.0% (1 of 5 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/de/

* Added translation using Weblate (Spanish)

* Translated using Weblate (Arabic)

Currently translated at 11.1% (1 of 9 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/ar/

* Translated using Weblate (Spanish)

Currently translated at 100.0% (9 of 9 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/es/

* Added translation using Weblate (French)

* Translated using Weblate (German)

Currently translated at 100.0% (9 of 9 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/de/

* Translated using Weblate (French)

Currently translated at 100.0% (9 of 9 strings)

Translation: Suwayomi/Tachidesk-WebUI
Translate-URL: https://hosted.weblate.org/projects/suwayomi/tachidesk-webui/fr/

---------

Co-authored-by: Allan Nordhøy <epost@anotheragency.no>
Co-authored-by: Aria Moradi <aria.moradi007@gmail.com>
Co-authored-by: Shippo <Shipox@users.noreply.hosted.weblate.org>
Co-authored-by: PedroJLR <jacobnchrono@gmail.com>
Co-authored-by: J. Lavoie <j.lavoie@net-c.ca>
2023-02-19 19:54:03 +03:30
Daniel
cd1d24ada7 Add logic to migrate metadata values (#227)
Makes it possible to rename or fix values of already saved metadata without the user losing his data
2023-02-17 15:40:44 +03:30
akabhirav
5473d14eae Adds search by genre to WebUI (#238)
* add pagination to library and fix some prettier issues

* add genre search support like tachiyomi android app

* Search by genre like you do in tachiyomi mobile app

---------

Co-authored-by: akxer <>
2023-02-16 09:26:09 +03:30
Aria Moradi
94e45c2133 add translation keys 2023-02-14 20:08:03 +03:30
Aria Moradi
688358f673 add translation keys 2023-02-14 16:47:38 +03:30
Aria Moradi
76d44bd657 clean up translations 2023-02-14 16:28:37 +03:30
Aria Moradi
6f3bc1bc4e add translation notice 2023-02-13 20:31:25 +03:30
Aria Moradi
ce83914599 add translation files 2023-02-13 20:23:53 +03:30
Aria Moradi
1c7c3e566c add i18n (#239) 2023-02-13 20:21:44 +03:30
akabhirav
aaedbb7be9 add pagination to library and fix some prettier issues (#237)
Co-authored-by: akxer <>
2023-02-12 18:43:41 +03:30
Daniel
ad9a12b2ec Fix reader nav bar scroll to page (#236)
* Correctly scroll to page

Using "curPage" as the "initialPage" broke "scrolling up".
The page got reset to the first page in that case

* Support resume and scrolling to page for "DoublePagedPager"

* Support resume and scrolling to page for "PagedPager"

* Prevent "ReaderNavBar" from disappearing in "VerticalPager"

Due to handling the overflow on the "root" div and the "nav bar" being sticky and having a combined with of 100vw with the "vertical pager", once the first page was reached, that was behind the 100vw, the "nav bar" got moved out of the screen.
This made using the "nav bar" unusable for the "vertical pager".
2023-02-12 18:42:17 +03:30
Daniel
b16b9eb55a Fix lint error (#235) 2023-02-12 18:41:29 +03:30
Daniel
baa2f680f7 add chapter dropdown to reader nav bar (#229)
* Add chapter dropdown to reader chapter nav buttons

Makes it possible to select a specific chapter inside the reader without having to leave and open the manga page

* Always show chapter nav buttons

In case they are unusable, they will be disabled
2023-02-08 21:07:39 +03:30
Daniel
c7aaed8378 Add chapter page dropdown (#230)
Makes it possible to select a specific page of the current chapter
2023-02-08 20:56:09 +03:30
Daniel
2c11708c92 increase prettier line length to 120 (#233)
* [Prettier] Increase max line length to 120

100 is quite low, especially on modern monitors.
The length is also reached quite quickly with 4 spaces per tab depending on the indentation depth

* [Prettier] Increase max line length to 120 - Fix formatting
2023-02-08 20:49:26 +03:30
Daniel
b958d74b92 Fix import path (#228) 2023-02-06 12:37:26 +03:30
Daniel
4e0a860dfd add prettier for auto formatting (#231)
* [Prettier] Add "prettier"

Makes the formatting of the code consistent.
By using the eslint-plugin-prettier formatting issues will be highlighted as a lint error.
These errors will be auto fixed by running "lint --fix" (which can be done automatically on file save)

* [Prettier] Add "prettier" - Fix formatting
2023-02-06 12:36:33 +03:30
Daniel
2eeea41a45 force absolute import path (#223)
* Add "no-relative-import-paths" eslint plugin

* Add "no-relative-import-paths" eslint plugin - Fix imports
2023-02-05 18:45:20 +03:30
Daniel
144b4cdb49 Ignore filters while searching (#226)
Search was only searching in the filtered manga, thus, it was not possible to find a manga that was not included in the set filters
2023-02-05 18:44:05 +03:30
Daniel
70ae857132 add GitHub action on pushing to run lint (#224)
* Add script to run eslint for the project

* Add GitHub Action for linting

Prevent merges with linting errors

* Rename GitHub Action "build_push" to "build_push_master"
2023-01-10 01:27:17 +03:30
Daniel
fc9dc35b60 show more detailed upload dates for today and yesterday (#222)
* Always show month and day of the chapters release date with 2 digits

In case the month or date is one digit a leading 0 will be added

* Show more detailed upload date information for chapter uploads from today or yesterday

In case the upload date is from today or yesterday the shown upload date will be e.g. "Today at 02:50", otherwise, just the date will be shown e.g. "04.01.2023"
2023-01-07 19:16:07 +03:30
Daniel
c92977844e Add tooltip containing full manga title to title of manga (#221)
In case the title is truncated it's still possible to view the full manga title.
Same way as it is done on e.g. Twitch or YouTube
2023-01-07 19:14:39 +03:30
Daniel
f7b369b95d set browser tab title (#220)
* Update the browser tab title

The tab title will be set to the same title as the "NavigationBar" with "- Tachidesk" as the suffix

* Set the manga title and chapter name as browser tab title in the reader

While the reader is still loading the "mangaId" and the "chapterIndex" will be set as the title.
2023-01-07 19:14:00 +03:30
Daniel
9702728771 add logic for metadata migration (#218)
* [#215] Handle metadata migration

Makes it possible to change "metadata keys" and the "app metadata key prefix" without losing data

* [#215] Fix checking and handling missing reader settings in metadata

With the new migration logic missing reader settings couldn't be detected anymore in case the metadata included outdated app metadata keys for the reader settings.

* [#215] Fix name of "IReaderSettings" property
2023-01-06 20:49:45 +03:30
Daniel
7642b5808c [#211] Refresh Library after a update (#212)
Library had to be refreshed manually to see the latest manga updates.
2023-01-06 20:05:26 +03:30
Daniel
dca968fdb7 make default reader settings changeable (#217)
* [#214] Move "reader settings" util functions into new file

* [#214] Extract "options" of "ReaderSettings" to new component

* [#214] Add component for changing the default reader settings

* [#214] Add default "ReaderSettings" to "Settings"

* [#214] Use default "ReaderSettings" stored on the server

Wait for both "manga" and "defaultSettings" to be loaded.
Otherwise, by the time the "manga" response was received, the "defaultSettings" might be still loading and thus, the local fallback "default" settings will get used as the "default settings"

* [#214] Save and update "ReaderSettings" options in case they are missing

- Manga gets read the first time => save settings in metadata
- Default settings get opened the first time => save settings in global metadata
2023-01-06 20:04:16 +03:30
Daniel
46ac5d5531 Save reader settings per manga in Meta (#216)
* [#213] Add missing "meta" property

- IManga
- IMangaCard (optional)
- IChapter
- ICategory

* [#213] Add util functions for handling metadata

- global server
- manga
- chapter
- category

* [#213] Use "ReaderSettings" from the manga metadata

- get ReaderSettings from manga metadata
- remove unnecessary check "make sure settings has all the keys"
    in case the stored settings in the metadata are outdated they will be filled with default values

* [#213] Reload manga only in case "mangaId" changed

In case the chapter is still from the same manga, a reload is unnecessary

* [#213] Only update the changed reader setting

Otherwise the app has to send patch requests to the server for every setting even if it didn't change

* [#213] Hide "openButton" on first render in case "navBar" is shown

The "openButton" was always set to be visible event in case the navBar was shown on the first render

* [#213] Open the "ReaderNavBar" if needed after receiving new settings

Otherwise, the drawer won't open in case the "navBar" was hidden on the first render since the default state in that case was set to false

* [#213] Update "ReaderSettings" after receiving the manga response

Otherwise, the default settings aren't getting removed

* [#213] Hide/Show "OpenButton" when opening/closing the drawer

Otherwise, the button stays hidden until it gets updated due to scrolling

* [#213] Keep "ReaderNavBar" state when opening prev/next chapter

In case the navBar wasn't sticky but opened, it got closed when the prev/next chapter got opened

* [#213] Prevent "ReaderNavBar" from closing when changing "staticNav" setting
2023-01-06 19:45:29 +03:30
Daniel
34bafee3aa fix library update progress rendering (#210)
* Fix library update progress rendering

The websocket sends a list with mangas for each category (completed, running, pending) instead of a number.
This resulted in the progress to always be 0

* Prevent TypeError

The "UpdateStatus" can have a "statusMap" that contains not data.

Co-authored-by: schroda <github@dasch.simplelogin.com>
2023-01-01 20:28:23 +03:30
amr
2e3f57677e Created a GridLayout enum and updated all locations to use it. (#208)
So, that we can more easily refactor the code later
2022-12-20 08:35:31 +03:30
Valter Martinek
7312e92d07 Fix "back" pagination on double page layout in reader for spread pages (#203)
* Update logic for determining if page should be single or double in double layout to cover issue #181

* Simplify code, add special handling for last page
2022-11-26 19:30:33 +03:30
Valter Martinek
8dfc89ee17 Refactor/download queue and cleanup visuals overall (#202)
* Move context providers and configuration providers to separate component, extract theme to separate file

* Use custom palette color instead of direct colors

* Replace different clicable things with CardActionArea to get transition and links

* Refactor DownloadQueue, update layout, unify all the download progress indicators

* Unify active filter indicator

* Use divider instead of hr

* Fix background color in extensions light theme

* Fix thumbnail overlay in library screen list view

* Don't show download button on downloaded updates
2022-11-26 16:21:56 +03:30
Valter Martinek
bfca70a44c Add safezone to scroll end detection to prevent edge cases when scrolling to the end would not detect end (#201) 2022-11-26 16:20:53 +03:30
Valter Martinek
12cfc81aa8 Hide overflowing text in reader title if text can't be wrapped (#199) 2022-11-24 23:35:18 +03:30
Valter Martinek
7aa4d2f3de Verticall scroll navigation and fix (#200)
* Remove scroll tracking from Page component

* Replace initial scrolling trigger with initialPage prop to be more clear on when to scroll to inital page

* Add current page tracking back to HorizontalPager

* Memoize prevChapter and nextChapter functions

* Rewrite navigation in vertical pager to scroll by screen percentage instead of whole pages, refactor code

* Handle last pages explicitly to fix issue with small last pages
2022-11-24 23:35:05 +03:30
Valter Martinek
31a3679e06 Scroll window to top when PagedPager changes page (#198) 2022-11-24 23:34:39 +03:30
Valter Martinek
62816338f3 Refactor and fix sorting in library (#197) 2022-11-24 23:34:30 +03:30
Valter Martinek
154b357c40 Options panels refactoring (#196)
* Refactor library options to match chapter options using shared component

* Disable some eslint rules

* Cleanup SourceOptions layout to use same components as other panels
2022-11-24 12:11:03 +03:30
Valter Martinek
3972d7757f Fix navbar back button behavior (#195)
* Enable passing backLink through location state. Explicitly handle cases for BACK

* Allow pages to override default backLink. Fix manga page back link

* Cleanup
2022-11-21 04:03:45 +03:30
Valter Martinek
68f67273aa Feature/batch chapter actions (#194)
* Add batch delete chapters

* Add remaining batch actions
2022-11-21 04:03:21 +03:30
Valter Martinek
1510c5a093 Memoize empty view face so it does not change on rerender (#193) 2022-11-10 21:31:29 +03:30
Valter Martinek
4a4e8b2cde Feature/batch chapter download (#191)
* Add NavbarToolbar component for rendering items in toolbar through portal

* Refactor Manga screen, move chapters filtering to toolbar menu, cleanup ChapterOptions

* Fix warning

* Update layout of ChapterList and add selection for chapters, add batch download, move stuff around

* Add space to bookmark icon

* Clear actions when leaving source mangas page

* Move bookmark icon back inline and align it correctly with text

* Fixup MangaDetails buttons to update cache properly so buttons in manga menu are updated

* Move chapters filter to ChapterList

* Fixup error display overlapping with loaded content when revalidation fails

* Fixup spacing around ChapterList title

* Only show small progress if manga is loaded so there is not to many spinners

* Prevent title wrapping

* Add icon buttons to desktop sizes of manga toolbar menu
2022-11-09 20:39:15 +03:30
Aria Moradi
e828582fd4 update browserlist 2022-11-07 20:23:43 +03:30
Valter Martinek
dcc1634b6f Update typescript dependency (#190) 2022-11-06 23:43:09 +03:30
Valter Martinek
a64aad126a Check download queue for changes and reload chapters if any chapter download changes state. (#189) 2022-11-06 23:19:44 +03:30
Valter Martinek
14265164a4 Feature/swr for simple queries (#187)
* Refactor simple queries with useSWR hook

* Fix plus button in Extensions screen

* Add type to categories query

* Add useQuery abstraction which adds loading attribute

* Reload categories even if reorder fails
2022-11-03 00:18:22 +03:30
Valter Martinek
6f8755fa05 Feature/swr for library screens (#186)
* Wrap data fetching in library and manga screen with swr for better dev and user experience. Refactor some API calls and data handling. Add manual refresh to manga detail.

* Fix manga card layout

* Fix refresh button position on small screens

* Revert "Fix manga card layout"

This reverts commit d85da3d8385e1ef64feed1789e4cd4591c8bd563.

* Fix manga not setting title

* Move chapters loading to Manga component, join data fetching, add auto online fetch if fetched data is old

* Revert some changes
2022-11-02 13:12:02 +03:30