Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse YouTube comments as HTML #928

Merged
merged 1 commit into from
Nov 27, 2022
Merged

Conversation

FireMasterK
Copy link
Member

  • I carefully read the contribution guidelines and agree to them.
  • I have tested the API against NewPipe.
  • I agree to create a pull request for NewPipe as soon as possible to make it compatible with the changed API.

This change is to add support for clickable timestamps and URLs.

@AudricV AudricV added enhancement youtube service, https://www.youtube.com/ labels Sep 17, 2022
Copy link
Member

@Stypox Stypox left a comment

Choose a reason for hiding this comment

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

Looks good to me, thanks!
@AudricV feel free to merge these small PRs without waiting for my or anyone's approval ;-)

@Stypox Stypox merged commit 60fb30f into TeamNewPipe:dev Nov 27, 2022
@AudricV
Copy link
Member

AudricV commented Nov 27, 2022

@Stypox I was not agree to merge this. getCommentText should return a plain text, not HTML (see PeerTube's CommentsInfoItemExtractor implementation).

Also, how NewPipe would handle this? It will probably display the comment with HTML tags.

If we want to return HTML, we should generalize the Description class, like already suggested, and return this class instead of a String.

@Stypox
Copy link
Member

Stypox commented Nov 27, 2022

Well then write a comment if you already thought about this... When I looked at this PR I didn't find any comment saying it should not be merged...

Just like descriptions can come in many formats, can't comments do so too?

@FireMasterK
Copy link
Member Author

@Stypox I was not agree to merge this. getCommentText should return a plain text, not HTML (see PeerTube's CommentsInfoItemExtractor implementation).

Express that! Even if its just 1 line it helps.

Also, how NewPipe would handle this? It will probably display the comment with HTML tags.

Descriptions currently are also HTML? Currently, I think it may do that. I think it should be easy to fix that?

If we want to return HTML, we should generalize the Description class, like already suggested, and return this class instead of a String.

That could be done indeed. Would you like a PR for this?

@FireMasterK FireMasterK deleted the comment-urls branch November 27, 2022 20:43
@AudricV
Copy link
Member

AudricV commented Nov 27, 2022

Express that! Even if its just 1 line it helps.

I didn't have the time to do so and then I forgot a bit this PR, sorry!

That could be done indeed. Would you like a PR for this?

Yes, it would be great!

@Stypox
Copy link
Member

Stypox commented Nov 27, 2022

I didn't have the time to do so and then I forgot a bit this PR, sorry!

That's fine, commits can be reverted anyway in case the Description PR takes some time ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement youtube service, https://www.youtube.com/
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants