Commit Graph

5953 Commits

Author SHA1 Message Date
javara999 4900efbca5 feat: add BookOasis document reader and text settings
Update website / update_website (release) Waiting to run
Build & Test / Build & Test App (push) Has been cancelled
2026-09-19 10:58:14 +09:00
MajorTanya a7179805ad Use & write Year, Month, Day info in ComicInfo (#3967)
* Use & write Year, Month, Day info in ComicInfo

Currently, users can only modify the date Mihon displays in the
chapter list by manipulating the _last modified date_ of the file.
This is obviously inconvenient, especially since the ComicInfo spec
includes Year, Month, and Day fields for this exact purpose.

If present, this reads the date at start of day in the current default
system time zone (which matches how we use Chapter.dateUpload with
relativeDateText, for example).

If Year is not specified, the entire date process is skipped.
If Month is not specified, it is set to January.
If Day is not specified, it is set to the first.

The parsed date (if any) is set as the Chapter's `date_upload` which
is used for display in the app.

Additionally, Mihon now includes this info in the written
ComicInfo.xml file for downloaded chapters. This will be convenient
for many more users, not least of which those who move
source-downloaded chapters to Local Source to read from there.

---

I used kotlinx.datetime because it's what we use for date parsing in
non-i18n places already.

* Changelog
2026-09-16 08:23:25 +06:00
AntsyLich 1c43addeca Resolve Injekt dependencies directly from the Metro graph (#3965)
The previous setup had a circular dependency between Injekt
registration and extension loading.

In regard to #3931, I've moved the culprit ExtensionManager out of
Injekt altogether, alongside CoverCache, PreferenceStore and
TrackPreferences, none of which a source needs.
2026-09-15 15:57:48 +06:00
MajorTanya b2cda03e3a Use modern OpenDocument for backup file selection (#3948)
This might also fix the underlying problem of #3947.

I don't have any nonstandard devices available, but this works fine
in an A17 Pixel emulator & on my A14 Xiaomi device.

Looks like the GetContent approach was merely carried over from older
code without being updated to the more modern OpenDocument contract.
2026-09-15 02:20:09 +06:00
AntsyLich fdc2d40a1d Reload extensions when relevant settings are updated (#3954) 2026-09-14 22:41:53 +06:00
AntsyLich e6d8efe6f8 Expose installed extensions that failed to load (#3953) 2026-09-14 21:34:55 +06:00
AntsyLich 0e0bc6972a Allow user to load installed extensions regardless of content warning (#3952) 2026-09-14 21:22:32 +06:00
w a5cd541bdf webgpuviewer: Fix menu hiding when navigating in long strip (#3956) 2026-09-14 21:01:27 +06:00
AntsyLich 0fbaa1ecec Replace extension NSFW flag with content warning app-wide (#3951) 2026-09-14 15:00:06 +00:00
w 7418f4e7bc Bump webgpuviewer (#3949)
* Continuous background color

* Use ImageDecoder instead of Kim

* Only get tag when in dual mode

* Update libs.versions.toml

* Make progress circle smaller and animate progress

* Fix long strip showing the menu at ends
2026-09-14 03:38:00 +06:00
MajorTanya 2d1a8bbeff Tighten AniList rate limit (#3942)
https://docs.anilist.co/guide/rate-limiting
2026-09-12 19:54:10 +00:00
AntsyLich 60e74b8d8f Don't try to create slider state when slider can't or won't be rendered (#3941) 2026-09-12 22:34:39 +06:00
Mend Renovate 6ef6e81814 Update dependency com.google.android.material:material to v1.14.0 (#3226)
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2026-09-12 18:23:14 +06:00
Mend Renovate 855918bbf4 Update dependency androidx.compose:compose-bom-alpha to v2026.09.00 (#3752)
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2026-09-12 18:21:37 +06:00
Mend Renovate 6c6eff3ab8 Update markdown to v0.45.0 (#3806)
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
2026-09-12 18:21:24 +06:00
AntsyLich d435dd9217 Switch to upstream Injekt
The patch is redundant given we switched to Metro DI and don't use `Injekt.addSingletonFactory` anymore
2026-09-12 16:04:58 +06:00
w d17ad1e002 Bump webgpuviewer (#3933)
* add disable zoom out

* add hdr

* Fix dual mode page progress and cleanup

* webgpu viewer add page gap setting

* Update libs.versions.toml
2026-09-12 11:57:02 +06:00
MajorTanya 1e054ea14d Fix inverted MAL OAuth expiry check logic (#3927) 2026-09-10 16:28:53 +00:00
Darkphoenix 35bb84705e Fix GPU texture leak when a decoded page is no longer usable (#3872) 2026-09-09 22:22:36 +00:00
MajorTanya aebf11a749 Make tracker utils package-internal (#3908)
It gets really annoying to use any of them when they have name
collisions. Especially extensions on Track or basic public functions.

Also make some same-file extension function in the MangaUpdates
package method on the class they extended.

I would have done the same for the DTOs themselves but any that are
used on method signatures have to be public and then all their members
also have to be public. We'd end up with a confusing mess of some
internal and some public DTOs, even at the top level (since generics
can be internal to the `dto` package (e.g. with parseAs<...>) but
return annotations cannot be).
2026-09-08 11:26:21 +06:00
Secozzi 5b69dbad81 Fix default category and manga sometimes not having their category restored (#3891) 2026-09-06 21:32:38 +06:00
Secozzi a82baac3ef Fixed crash caused by incorrect handling of kitsu score type from login (#3887)
* track/kitsu: Fixed crash caused by incorrect handling of score type from login

* revert changelog

* turn into lowercase when accessing map
2026-09-06 21:30:38 +06:00
MajorTanya 5e99306e5f Minor tracking refactors (#3900)
* Make tracker Api classes take their tracker's ID

Also made the name consistently `trackerId` since `trackId` can be
confusing in the context of Tracks that also carry several IDs.

Also made the public constants in TrackerManager entirely redundant,
so trackers are all equally getting their ID defined in their
constructor call now.

* Explicitly mark unused Exceptions as such

* Make isExpired method of BGMOAuth data class

As opposed to an extension defined in the same file

* Kavita: thumbnail_url -> thumbnailUrl

With a SerialName annotation of course

* Suwayomi: Remove redundant with(json)

Both of these requests don't use parseAs so this not required.

* Bangumi: Don't recreate OAuth object for storing

* Remove unused attribute from tracker OAuth classes

Mostly `token_type`.
Also removed `user_id` from BGMOAuth and `scope` & `expiresIn` from
MangaBakaOAuth (which already provides `expiresAt`).

* Use kotlin.time durations for token expiry math

Something like `Clock.System.now().plus(1.hours)` is much easier to
read than `System.getEpochMillis() + 3600`.

Also lets us use the `epochSeconds` attribute where the given
timestamps are seconds-resolution.

* Bangumi: Remove redundant apply block

* Kavita: Misc simplifications

* Use parseAs in tracker interceptors

* MAL: Use existing setAuth to store refresh token
2026-09-06 21:26:33 +06:00
w f3125ab897 Bump webgpuviewer (#3886)
* Add continuous min width

* Add dual page flip transition, separate some dual config

* Fix progress on sides for dual

* re-organize and minor fixes

* Reverse pan when vertical and zoom start right

* add flip to single

* Simple page size heuristics for dual selection

* zoom minimum wideness

* Fix continuous page progress

* continuous dynamic cache size

* Update libs.versions.toml
2026-09-04 21:18:18 +06:00
MajorTanya 21af65b100 Fix unhelpful generic 401 error on AniList expiry (#3888)
A leftover of what I assume was the v1 API behaviour handling manually
multiplied the `expires` values by 1,000, supposedly to make it a
millisecond value. However, AL tokens have been saved as milliseconds
since at least the v2 API implementation in 2018, so this has made
every expiry comparison ludicrously impossible.

Example:
millisecond timestamp:
1788529931115 (2026-09-04T13:52:11.115Z)
*1,000
1788529931115000 (+58646-04-04T21:45:15Z)

So any expiry comparisons would say "yes this token is still totally
valid", causing Mihon to send expired credentials and AL to respond
with a 401.

With these changes (which include some loosely associated clean-up),
we now correctly identify expired credentials before we attempt any AL
requests & actually show a toast with the "Token expired." error
message for the first time in 8 years or so?

I was able to keep the new ALOAuth shape compatible with
already-serialized data, though whenever a user (re-)links AL from now
on, both the `token_type` and `expiresIn` fields won't exist any more.
Since they had no use in the current code anyway, I don't consider
this a problem.

I took the liberty of adding basic instructions to the error message
but these can't be i18n'd properly so I kept it short and sweet.

---

Side effect of expired credentials is Mihon erasing the token in
storage, meaning AL disappears from the tracker sheet until re-linked.
I would say this is acceptable, but we might see panicked users in
support saying "Mihon deleted my AL links" or something.
2026-09-04 21:07:05 +06:00
천재웅 056d9baeeb Migrate composeGrid to new group ID (#3877) 2026-08-30 17:45:42 +00:00
MajorTanya baad5c59bb Clean up some missed unused imports (#3876) 2026-08-30 23:43:36 +06:00
AntsyLich 34a33ed4f8 Use filled icon for library continue reading button 2026-08-30 23:30:28 +06:00
AntsyLich 7f342ca076 Use built-in DelegateLastClassLoader for extensions (#3874)
Assisted-by: Claude:claude-opus-5
2026-08-29 16:07:51 +00:00
AntsyLich b695940114 Switch to Material Symbols and use Valkyrie for ImageVector generation (#3873)
* Add material symbols icon module

Assisted-by: Claude:claude-opus-5

* Replace material icons with material symbols

Assisted-by: Claude:claude-opus-5

* Add simple icons module and migrate CustomIcons

Assisted-by: Claude:claude-opus-5
2026-08-29 21:39:55 +06:00
w bb24e904a9 Bump webgpuviewer, fix navigation directions and long strip bounds (#3870)
* Keep previous page when jumping pages

* Fix navigation directions

* fix continuous jump after navigate

* webgpuviewer config

* Fade in loaded pages

* async onPageChange

* Update libs.versions.toml
2026-08-28 17:42:37 +00:00
AntsyLich 5fadea61e7 Make the source manager surface suspend (#3869)
Assisted-by: Claude:claude-opus-5
2026-08-28 23:36:28 +06:00
w 0854bde12e Bump webgpuviewer, imagedecoder, fixes (#3852)
* Bump webgpuviewer, imagedecoder, fixes

Render transition page using text renderer
Fix progress page in dual
Fix animations in dual
Re-do crop bounds

* Fix navigation buttons and zoom start

* Update libs.versions.toml
2026-08-26 19:24:32 +06:00
w e3813028bd Bump webgpuviewer, fix animated images background color (#3843) 2026-08-23 14:06:12 +06:00
AntsyLich 270b78ba95 Wait for extensions to load before the list is propagated (#3841) 2026-08-22 20:37:01 +00:00
AntsyLich 46c8f07c12 Limit vertical divider height in global search toolbar (#3839) 2026-08-22 19:56:26 +00:00
AntsyLich a2c24ff042 Use upstream scaffold (#3834) 2026-08-22 02:22:45 +00:00
MajorTanya 31d3c23717 Migrate to Kitsu's GraphQL API (#3792)
While there are still some nasty corners (multiple shapes of error
response, unhandled error types on their end, etc.), this is a
functional, feature-parity replacement for the JSON:API API we were
using before.

According to the GraphQL docs, searching by title still goes via
Algolia.
2026-08-22 04:46:35 +06:00
w 497e266256 Fix page loading for webgpuviewer and bump version (#3823) 2026-08-20 18:15:18 +00:00
MajorTanya 0974e787ad Use Shikimori's update endpoint (#3810)
No idea why it was originally going via the
addition endpoint but Shikimori's v1 and v2 APIs
have a dedicated endpoint to update a list entry
via PATCH or PUT (interchangeable, both allow
partial payloads).

Splitting off the update path revealed that
findLibManga would return a non-null track, which
in turn causes the update call to fail with a 404
due to `library_id` being null.

After further investigation, I realised that
findLibManga should always return null if the
title is not in the user's library, not just in
refreshes.
2026-08-21 00:12:48 +06:00
MajorTanya 01bfaa99ad Add support for using the user's chosen Kitsu rating scales (#3818)
Add support for different Kitsu rating scales

Includes a database migration because we have been scaling Kitsu's
2-20 `ratingTwenty` integer value to a 1-10 (step 0.5) value and
stored that in the database.

I'm also "rounding" the values to the next lowest valid one in the
current rating system to mirror Kitsu's behaviour for this. Both Kitsu
and the app keep the misfit value around until the score is otherwise
edited, at which point the interface constrains the user selection to
only valid values (for the current system).

Maybe the RatingSystem data class is overkill, but a previous version
of mine had three constants for each system that had to be manually
associated at each corner. Encapsulating those in a little map of data
classes seemed the more ergonomic solution.
2026-08-21 00:11:27 +06:00
MajorTanya 3cc0d2c324 Trim MAL & MB id: query before lookup (#3793)
This was included for all other trackers in #3776 but these two had
prefix search before.

It's a small change, but it can go a long way when using `id:` with
copy-pasted IDs from elsewhere which come with starting or trailing
whitespace.
2026-08-17 23:43:50 +06:00
w f75f2598a3 Fix fit height to in new renderer and bump webgpuviewer (#3801) 2026-08-17 23:08:09 +06:00
MajorTanya c613b52503 Add score info to MangaUpdates search results (#3795)
Also added author info for `id:` prefix search results since those hit
the single-series endpoint instead of `/search`, which does not
include author information (I wish it did).

Maybe unintuitive but the info is nice to have when available.
2026-08-17 16:28:25 +06:00
AntsyLich b2015d1ef3 Migrate to Metro DI (#3608)
Assisted-by: Claude:claude-opus-5
2026-08-16 18:47:48 +00:00
AntsyLich 5fa5f7e159 Load extensions off the main thread (#3788)
Assisted-by: Claude:claude-opus-5
2026-08-16 16:35:38 +00:00
w 00fb597ae9 Drop legacy decoder (#3786) 2026-08-16 15:48:58 +00:00
MajorTanya a81b7bce9a Add id: prefix search for rest of third-party trackers (#3776)
* Add id: prefix search to AniList

* Add id: prefix search to Bangumi

* Add id: prefix search to Kitsu

* Add id: prefix search to MangaUpdates

* Add id: prefix search to Shikimori

* Add id: prefix search to Hikka

Since Hikka doesn't use integer IDs and instead relies solely on a slug system,
users have to supply the slug to the `id:` search (so not `id:123` but
`id:sousou-no-frieren-97e05f` to get the Frieren manga specifically)

It's asymmetrical to the other trackers, but I thought keeping the prefix
consistent was more important than to be true to the tracker's internal
workings.

* Parse MU string IDs as base36 Longs

Turns out that's what the random strings in the URL are.

Co-authored-by: BrutuZ <7104931+BrutuZ@users.noreply.github.com>

* [skip ci] Add Changelog

---------

Co-authored-by: BrutuZ <7104931+BrutuZ@users.noreply.github.com>
2026-08-16 03:51:54 +06:00
Secozzi abdecb3cb4 Show updates and upcoming filter icon as active for categories (#3772) 2026-08-15 21:19:05 +06:00
AntsyLich ed30766a9f Match WebGPU reader background and transition colors to the old reader (#3765)
Assisted-by: Claude:claude-opus-5
2026-08-14 20:50:56 +00:00