feat(player): move comments and the description onto InnerTube and bring the player surfaces onto Material 3 Expressive - #1048
Merged
Conversation
…timestamp spans from the InnerTube watch response
… InnerTube, prefetch a bounded run of pages and keep the extractor as the fallback
…add the timed filter and the total, show creator hearts and badges, and drop the two icons that did nothing
…ted text and header factoids, fetched once per video and only when a surface asks
…row groups, merge the duplicated playback header and put the codec chips on the shared filter chip
…d toggle group, group both dialogs' rows and make the resolution badges neutral
…e subscribe button in the player and put the action row on expressive buttons with haptics
…d line, give the settings pages their top margin, and rebuild the description sheet on artwork-tinted cards
…script built from the caption track the player already resolved
…ts, give it search and playback sync, branch comment replies on curved connectors, and mark description links the way the server describes them
… comment timestamps with it too, and rebuild the queue dock around what plays next
…hed by this branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Moves the video player's comments and description onto the native InnerTube schemas, and brings the player's sheets, dialogs and buttons onto Material 3 Expressive.
Comments now come from InnerTube instead of the extractor, so the section's own sort menu, its real total, creator hearts, author badges and per-comment timestamps are read rather than guessed. The description is built from the watch page's attributed text and header factoids, with a new transcript and creator card beside it. The settings pages, download dialogs, action row and queue dock were reworked on M3 Expressive components and the app's own theme tokens.
Related issue
Closes #791
Closes #794
Closes #956
Change type
Validation
./gradlew :app:assembleGithubDebug./gradlew :app:testGithubDebugUnitTest— 1,676 tests, 0 failures (was 1,626 onmain; +50 new)./gradlew :app:compileFossDebugKotlin, and Spotless applied to every touched fileTest device and Android version: Xiaomi POCO X6 Pro, Android 16
Exercised on device: comments (sort chips, the timed filter, pinned and creator badges, reply threads), the transcript (segments, search, follow-along), the description (factoid cards, collapsed body, social links, creator card), the player settings pages, both download dialogs and the queue dock.
Risk and compatibility
Comments and description now depend on the InnerTube watch response. One
nextrequest per video is made lazily, the first time a surface asks for it, and cached — a video whose comments and description are never opened costs nothing, and nothing was added to the playback path. If the comment response cannot be parsed, the repository falls back to the extractor, so a schema change on YouTube's side degrades the section rather than emptying it.The transcript reads the caption track the player already resolves for subtitles, asking for
json3and dropping theaAppendroll-up repeats. It replaces thefmtalready on the URL rather than appending a second one. One request per track, cached.Sorting is server-side now. YouTube offers Top and Newest only; Oldest is kept and clearly re-orders the pages already loaded. Comment like counts are the abbreviated figures the response carries ("529K"), as YouTube itself shows them.
A bounded run of three further comment pages is prefetched after the first, sequentially and cancelled on a sort change or video change, so the Timed filter has something to filter.
The author-avatar repair fetches the extractor path needed are gone; InnerTube carries the avatar inline.
Removes four hardcoded colours (
Color.Gray,Color.DarkGray, the accent-coloured download badges, the queue dock's primary-tinted tile and outline).Visual changes by design: settings rows are Material 3 segmented groups, the description sheet is rebuilt on artwork-tinted cards, the subscribe button is the extra-small size in the player only, and the action row is on Expressive buttons with haptics.
The dead thumbs-down and reply icons are removed from each comment rather than made to work; posting and liking comments needs an account session and is not part of this PR.
Known, separate from this PR:
YouTube.transcript()(the YouTube-subtitle lyrics provider) returns HTTP 400 for every video — theget_transcriptendpoint it calls is gone. Untouched here.The change does not introduce secrets, private data, or unexpected telemetry.
New user-facing text uses Android string resources.
Dependency and lockfile changes are intentional and limited to this PR — no dependency changes.
Room schema changes include the required version bump and migration, or this PR does not change the Room schema.
Breaking changes and upgrade steps are clearly documented — none.