Skip to content

[Refactor] Timestamp links in comments open external browser instead of seeking video#13416

Open
Ecomont wants to merge 5 commits intoTeamNewPipe:refactorfrom
Ecomont:fix/comment-timestamp-seek
Open

[Refactor] Timestamp links in comments open external browser instead of seeking video#13416
Ecomont wants to merge 5 commits intoTeamNewPipe:refactorfrom
Ecomont:fix/comment-timestamp-seek

Conversation

@Ecomont
Copy link
Copy Markdown

@Ecomont Ecomont commented Apr 13, 2026

What is it?

  • Bugfix (user facing)
  • Feature (user facing) ⚠️ Your PR must target the refactor branch
  • Codebase improvement (dev facing)
  • Meta improvement to the project (dev facing)

Description of the changes in your PR

  • Add timestamp click handling to DescriptionText in Compose.
  • Detect timestamp patterns in comment text and convert them into clickable timestamp links.
  • Pass an onTimestampClick callback from the comments UI down to the text component.
  • Make timestamp clicks in comments seek the currently opened video instead of opening an external browser or app.
  • Keep normal non-timestamp links handled as regular links.
  • Reuse the existing timestamp parsing logic instead of introducing a separate parser.

Before/After Screenshots/Screen Record

  • Before:
bugVideo.mp4
  • After:
afterVideo.mp4

Fixes the following issue(s)

APK testing

The APK can be found by going to the "Checks" tab below the title. On the left pane, click on "CI", scroll down to "artifacts" and click "app" to download the zip file which contains the debug APK of this PR. You can find more info and a video demonstration on this wiki page.

Due diligence

@github-actions github-actions bot added the size/medium PRs with less than 250 changed lines label Apr 13, 2026
@ShareASmile ShareASmile added bug Issue is related to a bug comments Anything to do with comments and comment replies under videos/audios rewrite Issues and PRs related to rewrite labels Apr 13, 2026
@github-project-automation github-project-automation bot moved this to In Progress in Rewrite Apr 13, 2026
@ShareASmile ShareASmile added the regression A bug that didn't exist in prior versions but appeared after a certain change label Apr 13, 2026
Copy link
Copy Markdown
Member

@theimpulson theimpulson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the work. Please address some minor nitpicks. Looks good to me otherwise.

Comment thread app/src/main/java/org/schabi/newpipe/ui/components/common/DescriptionText.kt Outdated
Comment thread app/src/main/java/org/schabi/newpipe/ui/components/common/DescriptionText.kt Outdated
Comment thread app/src/main/java/org/schabi/newpipe/ui/components/common/DescriptionText.kt Outdated
Comment thread app/src/main/java/org/schabi/newpipe/ui/components/video/comment/Comment.kt Outdated
@theimpulson
Copy link
Copy Markdown
Member

It would be nice to make sure the functionality change, if any, gets mirrored in dev as well even if it needs rewrite to ensure both branch behaves the same.

@Idadelveloper
Copy link
Copy Markdown

Nice! This partially solves #11715.

Comment thread app/src/main/java/org/schabi/newpipe/ui/components/common/DescriptionText.kt Outdated
Ecomont added 2 commits April 17, 2026 08:24
When a timestamp link in the video description is tapped, expand the
AppBar to reveal the player in addition to seeking. This mirrors the
existing behaviour in the comments tab
@github-actions github-actions bot added size/large PRs with less than 750 changed lines and removed size/medium PRs with less than 250 changed lines labels Apr 17, 2026
@Ecomont Ecomont requested review from AudricV and theimpulson April 18, 2026 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Issue is related to a bug comments Anything to do with comments and comment replies under videos/audios regression A bug that didn't exist in prior versions but appeared after a certain change rewrite Issues and PRs related to rewrite size/large PRs with less than 750 changed lines

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

5 participants