Skip to content

feat(manga): manga library type — series grouping, reading loop, AniList/MangaDex metadata + status badge - #137

Closed
fluxis wants to merge 59 commits into
Silo-Server:mainfrom
fluxis:feat/manga-library-type
Closed

fluxis wants to merge 59 commits into
Silo-Server:mainfrom
fluxis:feat/manga-library-type

Conversation

@fluxis

@fluxis fluxis commented Jun 11, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ Prerequisite

Requires Silo-Server/silo-plugin-sdk#4 merged and tagged v0.7.0 before this can build.
The final commit pins github.com/Silo-Server/silo-plugin-sdk v0.7.0, which adds MetadataItem.status. go.sum already carries the canonical v0.7.0 content hashes, so CI will resolve cleanly the moment the tag exists — no further go.sum edits needed.

Problem

Silo had no first-class manga library type. Manga sit awkwardly between ebooks (per-file .cbz/.epub) and series (one enrichment target per title with many child items): scanning a manga folder as loose ebooks produced one card per volume with no series-level cover, synopsis, or read-through, and library-listing sections (recently-added/released/random) were polluted by individual chapters.

Approach

A new type='manga' library forked from the ebook pipeline:

  • Scanner groups .cbz/.epub under a series folder into one type='manga' series plus linked type='ebook' chapter items (manga_chapters join table). One card, one enrichment target.
  • Catalog/browse/detail surface per-series volume + chapter counts, per-chapter read state, and a continue/start-reading loop; library-listing sections exclude manga chapters so only the series card shows.
  • Metadata is provided by the new external silo-plugin-manga-metadata plugin (metadata_provider.v1, capability manga-metadata), enriching series with cover, synopsis, genres, author/artist, year, banner-as-backdrop, and publication status (Ongoing/Completed/Hiatus/Cancelled/Upcoming). Status flows through MetadataItem.status → ShowStatus → a color-coded chip on the detail page and browse cards.
  • Status badge required a new SDK field (MetadataItem.status, field 31). The host consumes it at internal/metadata/plugin_provider.go; the final commit here de-vendors the temporary SDK copy and depends on the published v0.7.0.

Deferred follow-ups

  1. Per-source N+1 in the ebook/audiobook enrichers — manga enrichment batches provider-id lookups, but the sibling ebook/audiobook enrichers still issue one lookup per item. Generalizing the batched path is left as a separate change to keep this PR scoped.
  2. Secondary-field backfill is admin-reset-only by design — backdrop/status backfill for already-matched series runs on an explicit admin "refresh metadata", not automatically, to avoid a full re-enrichment storm. Documented as intentional.
  3. Catalog registration — the plugin still needs an entry in Silo-Server/silo-plugins for one-click install (tracked separately).

Testing

  • go build ./... + go vet ./internal/metadata/... green in a golang:1.26 + libvips-dev container against the published-style v0.7.0 dependency.
  • Frontend: ESLint 0 errors, Prettier clean, 1048/1048 vitest tests pass.
  • make verify-local-paths clean (no absolute paths / worktree IDs in committed docs).
  • Exercised live on the test deployment (manga library scan → AniList/MangaDex enrichment → status chip render).

AI-use disclosure

Implemented with assistance from Claude Code (Claude). All code was reviewed, built, and tested locally by the author before submission.

Summary by CodeRabbit

Release Notes

  • New Features
    • Added full manga library type support with catalog browsing and search integration.
    • Browse individual manga chapters with reading progress tracking and viewer.
    • Display manga series details including chapter listings, file information, and read status.
    • Show publication/airing status (ongoing, completed, etc.) on media items.
    • Display chapter and volume counts on manga series titles.

@coderabbitai

coderabbitai Bot commented Jun 11, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 5a66340c-7f63-49b0-98b9-1e163e4a8b8e

📥 Commits

Reviewing files that changed from the base of the PR and between 6781c20 and 232484f.

⛔ Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
📒 Files selected for processing (81)
  • .gitignore
  • cmd/silo/main.go
  • go.mod
  • internal/api/handlers/catalog_resources.go
  • internal/api/handlers/items.go
  • internal/api/handlers/libraries.go
  • internal/api/handlers/libraries_metadata_levels_test.go
  • internal/api/handlers/sections.go
  • internal/api/router.go
  • internal/catalog/browse.go
  • internal/catalog/browse_manga_counts_test.go
  • internal/catalog/catalog_parser_test.go
  • internal/catalog/catalog_resolver.go
  • internal/catalog/catalog_resolver_test.go
  • internal/catalog/detail.go
  • internal/catalog/detail_manga_test.go
  • internal/catalog/discovery_repo.go
  • internal/catalog/item_repo.go
  • internal/catalog/library_repo.go
  • internal/catalog/manga_chapter_exclusion_test.go
  • internal/catalog/manga_files.go
  • internal/catalog/media_scope_test.go
  • internal/catalog/provider_id_repo.go
  • internal/catalog/query_definition.go
  • internal/catalog/query_definition_test.go
  • internal/catalog/query_executor.go
  • internal/ebooks/enrichment.go
  • internal/manga/enrichment.go
  • internal/manga/enrichment_test.go
  • internal/metadata/merge.go
  • internal/metadata/plugin_provider.go
  • internal/metadata/types.go
  • internal/models/media.go
  • internal/scanner/manga_chapters_repo.go
  • internal/scanner/manga_chapters_repo_test.go
  • internal/scanner/manga_parse.go
  • internal/scanner/manga_parse_test.go
  • internal/scanner/manga_scan.go
  • internal/scanner/scanner.go
  • internal/scanner/scanner_test.go
  • internal/sections/defaults.go
  • internal/sections/defaults_test.go
  • internal/sections/fetcher.go
  • internal/sections/fetcher_continue_watching_test.go
  • internal/sections/generated.go
  • internal/sections/manga_chapter_exclusion_test.go
  • internal/sections/manga_latest_volume_poster_test.go
  • internal/taskmanager/tasks/sync_manga_metadata.go
  • migrations/sql/20260610193238_manga_chapters.sql
  • migrations/sql/20260611003847_manga_enrichment_state.sql
  • web/src/api/types.ts
  • web/src/app.css
  • web/src/components/ContinueWatchingCard.tsx
  • web/src/components/FilterRuleEditor.tsx
  • web/src/components/GlobalSearch.tsx
  • web/src/components/ItemCard.test.tsx
  • web/src/components/ItemCard.tsx
  • web/src/components/MangaFilesDialog.tsx
  • web/src/components/MediaItemMenu.tsx
  • web/src/components/admin/libraries/libraryTypes.ts
  • web/src/components/admin/libraries/useLibraryForm.ts
  • web/src/components/catalog/CatalogFilterBar.tsx
  • web/src/components/collections/CollectionGuidedRulesEditor.tsx
  • web/src/hooks/queries/catalogRead.ts
  • web/src/lib/mangaChapters.test.ts
  • web/src/lib/mangaChapters.ts
  • web/src/lib/mediaNavigation.ts
  • web/src/lib/querySortOptions.ts
  • web/src/pages/EbookReader.test.tsx
  • web/src/pages/EbookReader.tsx
  • web/src/pages/ItemDetail/DetailHero.tsx
  • web/src/pages/ItemDetail/MangaContent.test.tsx
  • web/src/pages/ItemDetail/MangaContent.tsx
  • web/src/pages/ItemDetail/components/HeroCrewLine.tsx
  • web/src/pages/ItemDetail/components/MetadataBadges.tsx
  • web/src/pages/ItemDetail/index.tsx
  • web/src/pages/ItemDetail/watchedState.test.ts
  • web/src/pages/ItemDetail/watchedState.ts
  • web/src/pages/LibraryBrowse.tsx
  • web/src/pages/libraryPageSearchParams.test.ts
  • web/src/pages/libraryPageSearchParams.ts

📝 Walkthrough

Walkthrough

Adds manga support across storage, scanning, catalog responses, section logic, enrichment, tasks, and web UI. It also introduces manga-specific query scopes, counts, detail payloads, and file-list views.

Changes

Manga support

Layer / File(s) Summary
Shared contracts and validation
migrations/sql/*, internal/models/media.go, internal/metadata/*, internal/catalog/query_definition.go, internal/api/handlers/libraries.go, web/src/api/types.ts, web/src/pages/libraryPageSearchParams.ts, web/src/lib/querySortOptions.ts
Manga fields, metadata status, query scopes, and related validation/type mappings are added across backend and web contracts.
Scanner and enrichment pipeline
internal/scanner/*, internal/manga/enrichment.go, internal/ebooks/enrichment.go, internal/taskmanager/tasks/sync_manga_metadata.go, cmd/silo/main.go, go.mod
Manga parsing, chapter persistence, folder scanning, metadata enrichment, and the background sync task are wired into server startup.
Catalog detail and listing paths
internal/catalog/*, internal/api/handlers/catalog_resources.go, internal/api/handlers/items.go, internal/api/router.go
Browse, search, detail, provider ID, and manga-files endpoints now return manga-specific counts, chapter lists, and file metadata while excluding chapter sub-items from general catalog listings.
Sections and web UI
internal/sections/*, web/src/components/*, web/src/pages/*, web/src/hooks/queries/catalogRead.ts, web/src/lib/mangaChapters.ts
Section generation, continue-watching cards, item detail pages, catalog filters, reader navigation, and manga file dialogs are updated for manga-specific rendering and navigation.
Local compose ignore
.gitignore
docker-compose.override.yml is ignored as a local-only file.

🎯 4 (Complex) | ⏱️ ~60 minutes

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

fluxis and others added 28 commits June 11, 2026 17:18
Forks the ebooks library type into a 'manga' type: series detected from the
folder tree as a first-class type='manga' item, .cbz/.cbr chapters stay
readable ebook items linked via a new manga_chapters table, browse shows series
cards, enrichment targets the series item at content level 'manga'. Hands off to
a follow-on plugin spec for the manga metadata source.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ern (no test-DB)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add TestParseMangaIndexCorpus — 36 real-world scanlation filenames
covering bare chapter, decimal chapter, v/vol-prefix volume, and
c/ch-prefix chapter patterns; asserts <5% miss rate.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds mangaChapterWrite (pure, unit-tested), upsertMangaChapter, and
listMangaChapters following the ebook/audiobook thin-SQL pattern.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add isMangaLibraryType helper (unexported, matching the style of
isEbookLibraryType / isAudiobookLibraryType) with a corresponding
TestIsMangaLibraryType unit test.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Map library type "manga" to content level ["manga"] in
metadataContentLevelsForLibraryType so that seedDefaultChain seeds a
manga-level metadata provider chain when a manga library is created.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Accept "manga" as a valid media_scope so a manga library browses only its
type='manga' series items; the per-chapter type='ebook' items are naturally
excluded because MediaScopeItemTypes("manga") expands to {"manga"}. Add the
manga default library sections (scoped to media_scope='manga') so the library
feed shows series cards. Refresh the two media_scope validation error messages.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
For a type='manga' item, attach its chapters to the detail response via a new
MangaDetailExtension. fetchMangaChapters joins manga_chapters to media_items on
the chapter content ID, scopes to the series, and orders by chapter_index
(NULLS LAST) then sort_title — matching the scanner's chapter ordering.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add MangaChapter/MangaDetailExtension TS types mirroring the host
catalog structs, wire manga? onto ItemDetail, and admit "manga" as a
QueryDefinition.media_scope. Scope manga libraries to media_scope=manga
in browse (host expands it to type=manga series items) while reusing the
ebook sort universe via getLibrarySortRelevanceScope. Add isMangaLibraryType.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add MangaContent detail view: a DetailHero series header plus a chapter
list grouped by volume. groupMangaChapters (pure, unit-tested) buckets
chapters by their volume token, orders chapters within a group by
chapter_index (nulls last) and orders groups by their minimum index;
loose (volume-less) chapters collapse into a trailing "Chapters" group.
Each chapter links to the existing ebook reader by content_id alone
(file_id is optional — the reader resolves the file server-side), reusing
buildMediaPlayHref. Admit "manga" into ItemDetail.type and wire the
detail switch. Continue-reading is deferred (needs per-chapter progress
fan-out / a last-read timestamp not in the current payload).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adding "manga" to the shared ItemDetail["type"] and
QueryDefinition["media_scope"] unions leaked into consumers with narrower
local types, breaking the production tsc build. Fixes:

- mediaNavigation: admit "manga" into PlayableMediaType. Manga series are
  not directly playable (you open the detail page and read a chapter,
  itself an ebook item), so buildMediaPlayHref falls through to the item
  href for them, like series/season.
- FilterRuleEditor: add "manga" to FilterRuleMediaScope and relabel
  "watched" -> "Read" for manga as well as ebook (manga is read).
- CollectionGuidedRulesEditor: add "manga" to GuidedFormState.mediaScope,
  a "Manga" media-type option, ebook-like "Read Status" labels, and map
  manga -> ebook sort-relevance scope (manga has no dedicated sort scope).
- CatalogFilterBar (cascading leak surfaced after the above): add a
  "Manga" scope option and map manga -> ebook sort-relevance scope in both
  scope handlers.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add cleanMangaSeriesName which repeatedly strips trailing parenthetical
groups (year, year-range, Digital, release-group tags) then trims any
dangling dash, so folder names like "404 Demons (Digital) (Oak)" resolve
to "404 Demons". Wire it into mangaSeriesFromPath so both the series
title and the mangaSeriesGroupKey identity key use the cleaned value.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…lumes

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Numbers inside a series title (e.g. "404 Demons", "365 Days to the
Wedding") were wrongly grabbed as the chapter number because
parseMangaIndex matched the first bare number in the full filename.
mangaIndexForFile now strips the series-name prefix before delegating
to parseMangaIndex, so only the number that follows the title is used.
reconcileMangaFile in manga_scan.go is updated to call mangaIndexForFile
instead of parseMangaIndex directly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…items

Manga series items are file-less virtual parents; the shared
ReconcileFolderMembership swept them every scan because they have no
media_file. Exclude type='manga' from file-presence membership reconciliation,
and add a manga-scan step that deletes only series with zero remaining chapters.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Manga chapters are type='ebook' parts of a series; the ebook enrichment sweep
was searching each one against book sources (Gutenberg/Anna's/etc.) and failing
in a pointless storm. Exclude items with a manga_chapters link; series-level
enrichment is handled separately.
…project 2)

New silo-plugin-manga-metadata (AniList, high-confidence matching) + a host
MangaEnricher for type='manga' series; default-enabled metadata source for manga
libraries.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Mirrors ebook_enrichment_state: dedicated failure counter for the manga
enrichment sweep so it does not contend with media_items.refresh_failures.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
fluxis and others added 27 commits June 11, 2026 17:18
mangaVolYearIssue early-return was returning the year token (e.g. "Vol.2003")
as the volume label, which the frontend couldn't prettify to "Volume N".
Now returns "v<issue>" (e.g. "v04") so the existing frontend regex ^v?(\d+)$
renders it as "Volume 4" correctly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add an optional manga_chapter_count / manga_volume_count to the browse
item type and render a top-right "Vols N" / "Ch N" chip on ItemCard,
strictly gated on type==='manga'. The label prefers "Vols" when the
volume count dominates, "Ch" otherwise; the chip is hidden when the
chapter count is missing or non-positive. No other card type renders it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The ebook reader's back action defaulted to the chapter's own item
detail (/item/<chapter>), whose back returned to the reader — an
infinite loop for manga chapters. The reader now honors an explicit
backTo search param when present, navigating there instead. Absent for
normal ebooks, so their back behavior is unchanged. Only manga chapter
rows pass backTo, keeping the fix manga-only.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Each manga chapter/volume row now offers Read (the existing reader link,
now carrying a backTo to the series), Mark-read (the shared watched-state
mutation per chapter content_id), and Download (lazily fetches the
chapter's file versions on demand and opens the shared
DownloadVersionPicker, gated on user.download_allowed). The
volume-unit / loose-chapter / section structure from buildMangaList is
unchanged. Scoped to MangaContent only; EbookContent is untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Prevents open-redirect / javascript:-URI XSS from a crafted ?backTo= URL.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Manga chapters are ebook items, so a chapter is "read" when the viewer's
ebook_reader_progress row crosses the finished threshold. fetchMangaChapters
now LEFT JOINs that table scoped to the AccessFilter's user_id/profile_id and
exposes a per-chapter Read bool on MangaChapter, threaded through
buildMangaExtension. The detail payload previously carried no read state, so
the row toggle always started unread.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
MangaChapter now carries an optional read flag from the detail payload, and
MangaRow seeds its mark-read toggle from chapter.read instead of always
starting unread. The optimistic toggle + shared watched mutation are
unchanged; only the initial value is seeded.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ndom + other library-listing sections

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…50->200

- sweep stats now separate enriched / no_match / failed: a stamped no-match
  was counted (and logged) as an enrichment, which masked a collapse of the
  real match rate during the backfill
- batch size 50 -> 200 (SILO_MANGA_ENRICH_BATCH overrides): with the plugin
  serving GetMetadata from its search cache an item costs one rate-limited
  AniList request, so a sweep still fits the 5-minute task interval

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…eal budget

140 items x ~2.1s/request fits the interval; an overlong sweep makes the task
manager drop the next trigger and the effective rate falls below the AniList
budget.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
manga_chapter_count/manga_volume_count were only added to BrowseRepository,
but /library/{id}?tab=library flows through previewQuerySource ->
QueryExecutor.PreviewPage, which selects qualifiedListItemColumns and scans
with scanItems - so manga cards never carried the counts and the Vols/Ch
poster chip stayed hidden.

Append mangaCountColumns to the preview-page SELECT and scan them via a new
scanItemsWithMangaCounts (nil for non-manga rows, mirroring scanBrowseItems).
Extract listItemScanDests so the three scan variants share one destination
list instead of duplicating the 48-column scan.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…Read

- chip: show distinct-volume and loose-chapter counts side by side instead
  of the single 'Vols N'/'Ch N' heuristic; mangaCountColumns now counts
  DISTINCT volume tokens (rows sharing a volume are one volume) and only
  un-volumed rows as chapters
- watched-state labels: type='manga' fell through to the video default, so
  the card dot menu and detail page said 'Mark Watched' - manga now uses
  the ebook reading verbs (Mark Read / Mark Unread, 'Marked as read' toast)
- format MangaContent.test.tsx (pre-existing prettier miss)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ckfill

- cache remote backdrops like posters (cacheRemoteImages generalizes the
  poster-only path; failures keep the provider URL, which still renders)
- claim arm for enriched items missing a backdrop: fetched by stored
  provider ID (search skipped - no rate spend, no re-match risk) and only
  the backdrop is written; stamping after the attempt keeps banner-less
  series from being re-claimed every sweep
- backfill = one-time SQL clearing last_refreshed for poster-set/
  backdrop-empty manga

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…re cards, file details

Fixes the four high-priority findings from the manga UX review plus a
file-inspector request:

- H1: series hero gets a Continue / Start Reading / Read Again CTA
  targeting the first unread chapter (firstUnreadChapter over the ordered
  list), plus an overflow menu (View Details, admin Refresh Metadata)
- H2: the reader resolves its owning manga series (chapter detail now
  carries series_id/series_title) and offers next-chapter navigation: a
  header next button and an end-of-book floating CTA at >=99.5% progress;
  back defaults to the series even without a backTo param
- H3: chapter rows show a persistent read check + muted title, and the
  mark-read mutation carries series_id so the series detail cache
  invalidates (read states no longer revert on revisit)
- H4: continue-reading cards for manga chapters present the series:
  sections payload resolves chapter->series linkage, the card heading/image
  link to the series, and meta lines launch the reader
- View Details: manga series menus (card dot menu + detail overflow) open
  a file inspector showing folder paths and per-chapter file names/sizes
  via GET /catalog/items/{id}/manga-files; paths are stripped for viewers
  without file-path visibility (item-versions policy)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…t scope

Second batch from the manga UX review (M1-M7):

- M1: multi-chapter volume sections are collapsible (fully read sections
  start collapsed) with sticky headers, and long series get a 'Jump to
  <next unread>' anchor above the list
- M2: the series hero shows the author line (HeroCrewLine learns Author
  credits with person links; DetailHero now renders crewLine and genre
  chips independently) and Volumes/Chapters badges
- M3: browse-card count chip abbreviates to '12 Vol - 3 Ch' so it fits
  narrow cards without occluding covers
- M4: manga gets its own sort scope: Duration/Bitrate (meaningless for
  file-less series rows) disappear, reading labels (Date Read / Reads)
  apply, Author stays
- M5: global search labels manga results 'Manga' instead of the raw type
- M6: chapters carry the viewer's reading fraction; part-read rows show an
  inline progress bar + percent
- M7: chapter rows show the extracted cover thumbnail (presigned
  poster_url on the chapters payload) instead of a generic icon

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…-state hint

- buildMangaList buckets volumes by canonical numeric token so mixed
  release naming (v01 + 1) yields one Volume 1 instead of duplicates
- cbz/cbr readers start with the side panel closed and hide prose-only
  chrome (reading ruler, TTS, typography/font controls, hyphenation,
  writing mode) while keeping comic-relevant settings (theme, brightness,
  margin, right-to-left, spread, flow)
- manga empty state mentions chapters appear after the library scan

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- vendor the unpublished plugin SDK (adds MetadataItem.status) under
  internal/compat/ with a relative go.mod replace, following the
  zishang520-webtransport-go convention; swap to the published module
  before the upstream PR
- map plugin status into MetadataResult.ShowStatus, persist it during
  manga enrichment, and show it as the hero status badge (show_status was
  already on the detail payload and MetadataBadges)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… status)

The backdrop-only claim arm becomes a secondary-fields pass: enriched items
missing a backdrop and/or publication status are claimed, fetched by stored
provider ID, and only the missing secondary fields are written. Lets the
new status field backfill across the already-enriched library instead of
applying only to future enrichments.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…data

The new MetadataResult.ShowStatus never reached the accumulated result the
manga enricher persists from - the field-by-field merges didn't know it, so
the status backfill pass obtained nothing. Regression-tested on both paths.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
filterMangaProviderIDs passed the scanner's manga_series identity row
through, so the search-skip-when-already-matched guard saw provider IDs on
every item and never searched: unmatched items went straight to a by-ID
fetch with no usable ID and were stamped as terminal no-match without a
single provider request (and the MangaDex fallback was never consulted).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The override unpublishes the bundled redis/postgres host ports
(ports: !override []). It is a per-deployment, local-only file: ignoring it
keeps a rebase from main and git clean -fd from disturbing it, and keeps it
out of any PR. Its accidental absence once exposed Redis to the internet.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…me-count consistency

- enrichWithProviders: set accumulator.HasMetadata after a provider result
  merges (MergeMetadata doesn't propagate it). Without this, a confident
  match carrying only genres/authors/status/year but no cover and no overview
  failed the no-match check and was discarded + terminally stamped.
- byChapterIndex: both un-indexed chapters yield POSITIVE_INFINITY, so the
  subtraction was Infinity-Infinity=NaN (Array.sort treats NaN as 0, leaving
  order undefined). Compare explicitly for a stable order.
- MangaContent volume/chapter badges: derive counts from the rendered
  buildMangaList entries (which canonicalize v01 ≡ 1) instead of raw distinct
  volume tokens, so the badge can no longer say '2 Volumes' over one row.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…set-only

The secondary arm (poster present, backdrop/status missing) requires
last_refreshed IS NULL, so it is only reachable when an operator resets
last_refreshed to backfill a newly-added field — not an automatic periodic
re-check (which would re-fetch banner-less series every sweep). Documents the
intent so it does not read as dead code.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ider-id lookup

- Continue Reading now collapses multiple in-progress chapters of the same
  manga into one card (most recently read kept), mirroring the episode→series
  collapse. The reading section resolves chapter→series linkage into itemMeta
  (applyMangaChapterSeriesMeta) and runs the shared
  collapseContinueWatchingSeriesCandidates, which the reading path previously
  skipped.
- claimBatch resolves provider IDs for the whole batch in one query via the
  new ProviderIDRepository.GetByContentIDs (content_id = ANY), replacing the
  per-item GetByContentID N+1.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…le chips

- Color-coded publication status pill (Ongoing/Completed/Hiatus/Cancelled/
  Upcoming) in the manga card's top-left corner, mirroring the vol/chapter
  count chip top-right. Strictly manga-gated; show_status was already on the
  browse payload.
- New .glass-chip (78% surface vs glass-subtle's 40%) for the manga count +
  status pills so the labels stay legible over busy cover art.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Replace the vendored internal/compat/silo-plugin-sdk copy with a normal
dependency on the published SDK module at v0.7.0, which adds
MetadataItem.status (publication/airing status) consumed by the manga
status badge at internal/metadata/plugin_provider.go.

- go.mod: pin v0.7.0, drop the local-path replace directive
- remove the vendored internal/compat/silo-plugin-sdk tree
- Dockerfile: drop the vendored-SDK COPY
- strip the manga design docs/plans from docs/superpowers (internal)

Requires Silo-Server/silo-plugin-sdk#4 merged and tagged v0.7.0.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Quick104
Quick104 force-pushed the feat/manga-library-type branch from 662d1c5 to 232484f Compare June 11, 2026 21:19
@Quick104

Copy link
Copy Markdown
Contributor

Recreated as #138 from the clean rebased branch: #138

@Quick104 Quick104 closed this Jun 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants