Commit graph

7906 commits

Author SHA1 Message Date
Secozzi
3d3069c77e
Ignore "intent://" urls on webview
ignore intent urls

Co-authored-by: bapeey <90949336+bapeey@users.noreply.github.com>
2024-10-30 11:59:31 +01:00
renovate[bot]
357e43c69c
fix(deps): update dependency androidx.activity:activity-compose to v1.9.2 (#1189)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 52036e5664cbcf552de706adee6e0b4b972fe1c3)
2024-10-30 11:57:25 +01:00
renovate[bot]
9b1b176f03
fix(deps): update dependency com.google.accompanist:accompanist-systemuicontroller to v0.36.0 (#1192)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 29a74509a4af475694551808e317df96ea1146ad)
2024-10-30 11:57:20 +01:00
renovate[bot]
305a067d74
fix(deps): update lifecycle.version to v2.8.5 (#1190)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 0e956cbb518e0e0827c1e7dfde8427cb8660a9fb)
2024-10-30 11:57:16 +01:00
AntsyLich
0d9a7ca709
Switch to stable compose
(cherry picked from commit 2baffa62cade1abd978d5fd03151b47fc87fd31e)
2024-10-30 11:57:10 +01:00
Secozzi
202eaf4f49
Fix moving of openFileDescriptor 2024-10-30 11:56:32 +01:00
Secozzi
341c53af96
Merge remote-tracking branch 'origin/master' into mihonmerge
# Conflicts:
#	i18n/src/commonMain/moko-resources/ar/strings.xml
#	i18n/src/commonMain/moko-resources/as/strings.xml
#	i18n/src/commonMain/moko-resources/it/strings.xml
#	i18n/src/commonMain/moko-resources/ja/strings.xml
#	i18n/src/commonMain/moko-resources/pl/strings.xml
#	i18n/src/commonMain/moko-resources/vi/strings.xml
#	i18n/src/commonMain/moko-resources/zh-rCN/strings.xml
2024-10-30 11:44:29 +01:00
AntsyLich
a095952e0f
Use new library for injekt with inorichi patch
(cherry picked from commit c929854ae9)
2024-10-30 11:42:54 +01:00
AntsyLich
3599a38ad6
Move archive related code to :core:archive
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-30 11:42:29 +01:00
Secozzi
c6b34e5bc6
Rename LocalesConfigPlugin file to LocalesConfigTask
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-29 23:11:08 +01:00
Secozzi
443de1f8bd
Fix Kitsu ratingTwenty being typed as String
The API docs and the responses type `ratingTwenty` as a "number" (Int
in Kotlin, it's divided by 2 for a .5 step scale 0-10). It's nullable
because an entry without a user rating returns `null` in that field.

Co-authored-by: MajorTanya <39014446+MajorTanya@users.noreply.github.com>
2024-10-29 23:10:14 +01:00
renovate[bot]
9bff941de0
fix(deps): update dependency com.android.tools:desugar_jdk_libs to v2.1.2 (#1188)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit c4d2fffb12c83c76cf48a85cbc9d7d754a4da39c)
2024-10-29 23:08:47 +01:00
Secozzi
32ce7e4407
Migrate some classpaths to gradle plugins
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-29 23:07:16 +01:00
Secozzi
67af9a79ba
Option to update trackers when chapter marked as read
* Track when marked as read

* Add dismiss to snack bar

* i18n & ignore decimal chapters

* Detekt would have caught that 🤣

* `Ok` > `Yes`

* Dont prompt if untracked or current > new

* Move to MangaScreenModel

* Suggestions

Co-Authored-By: AntsyLich <59261191+AntsyLich@users.noreply.github.com>

* Review 2

* toggleAllSelections first

---------

Co-authored-by: Roshan Varughese <40583749+Animeboynz@users.noreply.github.com>
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-29 22:56:38 +01:00
Smol Ame
e0e69b3085
Enable 'Split Tall Images' by default (#1185)
(cherry picked from commit 9c1905ede750f0229fad1a01431058b1cc9fb32d)
2024-10-29 22:48:40 +01:00
Secozzi
f9b3c7c77a
Use DTOs to parse tracking API responses
* Migrate tracking APIs to DTOs

Changes the handling of tracker API responses to be parsed to DTOs
instead of doing so "manually" by use of `jsonPrimitive`s and/or
`Json.decodeFromString` invocations.

This greatly simplifies the API response handling.

Renamed constants to SCREAMING_SNAKE_CASE.

Largely tried to name the DTOs in a uniform pattern, with the
tracker's (short) name at the beginning of file and data class names
(ALOAuth instead of OAuth, etc).

With these changes, no area of the code base should be using
`jsonPrimitive` and/or `Json.decodeFromString` anymore.

* Fix wrong types in KitsuAlgoliaSearchItem

This API returns start and end dates as Long and the score as Double.

Kitsu's docs claim they're strings (and they are, when requesting
manga details from Kitsu directly) but the Algolia search results
return Longs and Double, respectively.

* Apply review changes

- Renamed `BangumiX` classes to `BGMX` classes.
- Renamed `toXStatus` and `toXScore` to `toApiStatus` and `toApiScore`

* Handle migration from detekt to spotless

Removed Suppressions added for detekt.

Specifically removed:
- `SwallowedException` where an exception ends as a default value
- `MagicNumber`
- `CyclomaticComplexMethod`
- `TooGenericExceptionThrown`

Also ran spotlessApply which changed SMAddMangaResponse

* Fix Kitsu failing to add series

The `included` attribute seems to only appear when the user already
has the entry in their Kitsu list.

Since both `data` and `included` are required for `firstToTrack`, a
guard clause has been added before all its calls.

* Fix empty Bangumi error when entry doesn't exist

Previously, the non-null assertion (!!) would cause a
NullPointerException and a Toast with
"Bangumi error: " (no message) when the user had removed their list
entry from Bangumi through other means like the website.

Now it will show "Bangumi error: Could not find manga".

This is analogous to the error shown by Kitsu under these
circumstances.

* Fix Shikimori ignoring missing remote entry

The user would see no indication that Shikimori could not properly
refresh the track from the remote. This change causes the error Toast
notification to pop up with the following message
"Shikimori error: Could not find manga".

This is analogous to Kitsu and Bangumi.

* Remove usage of let where not needed

These particular occurrences weren't needed because properties are
directly accessible to further act upon. This neatly simplifies these
clauses.

* Remove missed let

Co-authored-by: MajorTanya <39014446+MajorTanya@users.noreply.github.com>
2024-10-29 22:46:31 +01:00
Secozzi
d236999c6b
Fix import issue caused by version bump 2024-10-28 22:52:00 +01:00
Secozzi
d58e121fa3
spotlessApply my beloved 2024-10-28 11:59:32 +01:00
Secozzi
dd17832428
Add stable marker to Manga data class
Co-authored-by: ivan <12537387+ivaniskandar@users.noreply.github.com>
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:57:58 +01:00
Secozzi
2abb7be491
Collect MangaScreen state with lifecycle
Co-authored-by: ivan <12537387+ivaniskandar@users.noreply.github.com>
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:44:25 +01:00
Secozzi
10882a5f84
PagerPageHolder: lazy init loading indicator
Co-authored-by: ivan <12537387+ivaniskandar@users.noreply.github.com>
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:39:23 +01:00
Secozzi
00183cc9e5
Use feature flags in compose compiler plugin
And slight cleanup

Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:36:57 +01:00
renovate[bot]
b5d8f73982
fix(deps): update dependency com.android.tools.build:gradle to v8.6.0 (#1178)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit f74071ab0a70c4fd649b451e58841539d011496a)
2024-10-28 11:35:13 +01:00
renovate[bot]
abf81bd4c4
fix(deps): update dependency com.android.tools:desugar_jdk_libs to v2.1.1 (#1172)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 7fb3ef48e4fafce471173111fe1632754e5e9e99)
2024-10-28 11:35:10 +01:00
renovate[bot]
f180f88ad3
fix(deps): update serialization.version to v1.7.2 (#1173)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

(cherry picked from commit 1837faa573f11a6b97fe13f358d6fa0e980c2ef7)
2024-10-28 11:35:06 +01:00
Secozzi
c27bf3f6b1
Remove legacy broken source and history backup
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:33:19 +01:00
Secozzi
a3da190a23
Hide keyboard when a Tracker SearchResultItem is clicked
* Hide keyboard on select

* Code Review Suggestion

Co-authored-by: Roshan Varughese <40583749+Animeboynz@users.noreply.github.com>
2024-10-28 11:25:30 +01:00
renovate[bot]
83ab0e5ff2
chore(deps): update gradle/actions action to v4.0.1 (#1165)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit d26c010e57ac0ed802cc811a029864972adfbb71)
2024-10-28 11:23:14 +01:00
renovate[bot]
a922a59499
fix(deps): update dependency com.android.tools:desugar_jdk_libs to v2.1.0 (#1162)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 607e56a4ec6393a3bfd25fe74cbae676fd94df22)
2024-10-28 11:23:10 +01:00
Secozzi
d694c7e4d4
Add "show entry" action to download notifications (#1159)
* Add 'show entry' to download notifications

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>

* fixup! Add 'show entry' to download notifications

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>

* fixup! Add 'show entry' to download notifications

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>

* spotless! Add 'show entry' to download notifications

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>

Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>

* fixup! spotless- Apply suggestions from code review

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>

---------

Signed-off-by: Catting <5874051+mm12@users.noreply.github.com>
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-28 11:22:18 +01:00
Secozzi
e9891c25aa
Add confirmation when adding repo via URI
* Add confirmation when adding repo via URI

* Blank lines

* Suggestions

* Reverting Changes

* Removing Unused Imports

Co-authored-by: Roshan Varughese <40583749+Animeboynz@users.noreply.github.com>
2024-10-28 11:09:28 +01:00
Secozzi
c275d0909d
Respect privacy settings in extension update notification
* Hide Extension Names in Update Notifications when Content is Hidden

* Moving `val` inside if

* [skip ci] Update CHANGELOG.md

Co-authored-by: Roshan Varughese <40583749+Animeboynz@users.noreply.github.com>
2024-10-28 11:03:31 +01:00
renovate[bot]
cb3e616890
fix(deps): update aboutlib.version to v11.2.3 (#1151)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit fba9bacdc19dee7cdf9e3d1cb4ee4a496fa7b514)
2024-10-28 10:58:25 +01:00
Secozzi
8937e92b53
Add option to skip downloading duplicate read chapters
* Add query to get chapter count by manga and chapter number

* Add functions to get chapter count by manga and chapter number

* Only count read chapters

* Add interactor

* Savepoint

* Extract new chapter logic to separate function

* Update javadocs

* Add preference to toggle new functionality

* Add todo

* Add debug logcat

* Use string resource instead of hardcoding title

* Add temporary logcat for debugging

* Fix detekt issues

* Update javadocs

* Update download unread chapters preference

* Remove debug logcat calls

* Update javadocs

* Resolve issue where read chapters were still being downloaded during manual manga fetch

* Apply code review changes

* Apply code review changes

* Revert "Apply code review changes"

This reverts commit 1a2dce7.

* Revert "Apply code review changes"

This reverts commit ac2a778.

* Group download chapter logic inside the interactor GetChaptersToDownload

* Update javadocs

* Apply code review

* Apply code review

* Apply code review

* Update CHANGELOG.md to include the new feature

* Run spotless

* Update domain/src/main/java/mihon/domain/chapter/interactor/FilterChaptersForDownload.kt

---------

Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
Co-authored-by: Dani <17619547+shabnix@users.noreply.github.com>
2024-10-28 10:52:51 +01:00
Secozzi
11f30c885d
Fix lint errors 2024-10-28 10:51:57 +01:00
renovate[bot]
905975b6b7
fix(deps): update moko to v0.24.2 (#1148)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 379d5878266ba0287bfcc4a06452c27d70f33ba1)
2024-10-27 21:47:35 +01:00
renovate[bot]
6ee421e27f
chore(deps): update kotlin monorepo to v2.0.20 (#1144)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 034ec4cb120c0f36cad1303de1314c28c4ec4969)
2024-10-27 21:47:31 +01:00
renovate[bot]
803ea32afc
fix(deps): update dependency dev.chrisbanes.compose:compose-bom to v2024.08.00-alpha02 (#1143)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 24817675320855cb01250acca87b97dd7ac8a399)
2024-10-27 21:47:28 +01:00
renovate[bot]
ca864ba788
fix(deps): update dependency androidx.benchmark:benchmark-macro-junit4 to v1.3.0 (#1142)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 08ae51ea8c5ceccc8c5c65120f387d7b19d18052)
2024-10-27 21:47:11 +01:00
Hosted Weblate
e7cfb8e55b
Translations update from Hosted Weblate
Co-authored-by: Ahmed seif al-nasr <ahmdsyfalnsr2@gmail.com>
Co-authored-by: Anas KANJO <anas.kanjo2022@gmail.com>
Co-authored-by: Dexroneum <Rozhenkov69@gmail.com>
Co-authored-by: Frosted <cinardogan110@gmail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Infy's Tagalog Translations <ced.paltep10@gmail.com>
Co-authored-by: Lyfja <45209212+lyfja@users.noreply.github.com>
Co-authored-by: TheKingTermux <achmadmaulana0233@gmail.com>
Co-authored-by: bittin1ddc447d824349b2 <bittin@reimu.nl>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Co-authored-by: gekka <1778962971@qq.com>
Co-authored-by: ɴᴇᴋᴏ <s99095lkjjim@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon-plurals/tr/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/ar/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/de/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/es/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/fil/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/id/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/ja/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/ru/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/sv/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/tr/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/zh_Hans/
Translate-URL: https://hosted.weblate.org/projects/mihon/mihon/zh_Hant/
Translation: Mihon/Mihon
Translation: Mihon/Mihon Plurals

(cherry picked from commit 4387ae5ff3131dd4aaaacd75fa6e82e7b322d474)
2024-10-27 21:46:57 +01:00
Secozzi
1cae533d65
Address spotless lint errors 2024-10-27 21:36:32 +01:00
AntsyLich
93258dcbb9
Add spotless (with ktlint) (#1136)
(cherry picked from commit 5ae8095ef1ed2ae9f98486f9148e933c77a28692)
2024-10-27 11:04:17 +01:00
Secozzi
5ee7807ae2
Generate locales_config.xml in build dir
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2024-10-27 11:03:10 +01:00
Secozzi
324a4850a3
Remove more detekt annotations 2024-10-27 10:52:26 +01:00
AntsyLich
aeb17fa859
Remove detekt (#1130)
Annoying. More annoying in this project.

(cherry picked from commit 777ae2461e1eb277a3aa0c998ff69e4f100387a1)
2024-10-27 10:38:00 +01:00
renovate[bot]
410832fba6
fix(deps): update dependency org.conscrypt:conscrypt-android to v2.5.3 (#1135)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit b2f1719c50365279e157a3b9ee015fc6c13a9a92)
2024-10-27 10:30:17 +01:00
renovate[bot]
8a46384e70
chore(deps): update dependency gradle to v8.10 (#1122)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 3f050a83dd0907e0ffb56a1e1833f9de5b10b329)
2024-10-27 10:30:13 +01:00
renovate[bot]
c1dc6b5e0e
fix(deps): update dependency org.junit.jupiter:junit-jupiter to v5.11.0 (#1121)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
(cherry picked from commit 6f4e3f776f98d7a47dfa33b2cdfe992fc211ec28)
2024-10-27 10:30:11 +01:00
FooIbar
fa3966151e
Add comment about RecyclerView cache size (#1119)
Note for forks: Increasing cache size may cause OOM on API < 26, better
to make it API 26+ only.

(cherry picked from commit 1c47a6b9b35c622200c731cdbbc076f5263e8d06)
2024-10-27 10:30:03 +01:00
AntsyLich
748ac38599
Remove WebViewClientCompat
(cherry picked from commit f4348df8709529b7b2319485fc8eb54c6e8173c7)
2024-10-27 10:29:19 +01:00