bluesky-social / social-app

The Bluesky Social application for Web, iOS, and Android
https://bsky.app
MIT License
8.19k stars 1.09k forks source link

Feature request: Support YouTube Timestamps #3943

Open Mennaruuk opened 4 months ago

Mennaruuk commented 4 months ago

Is your feature request related to a problem? Please describe.

YouTube has a feature where a user can directly link to a particular timestamp in the video. That way, when someone watches the video, it immediately jumps to that point. It's super helpful, as it avoids having viewers skip back and forth until they find the right spot.

Describe the solution you'd like

I want Bluesky to include the timestamp when a timestamped video link is inserted. The current behavior is that all links with a timestamp begin from 0:00, thus ignoring the timestamp parameter.

Describe alternatives you've considered

I tell readers the timestamp in my posts, but this isn't ideal, and can take up some precious space when the character limit is 300.

Example URL

https://youtu.be/T6eK-2OQtew?si=fs1T7_cU9xvLdhqQ&t=54

Additional context

Thank you.

mary-ext commented 4 months ago

Are you sure the YouTube embeds aren't starting at the timestamp you've specified? because this has been fixed 4 months ago (https://github.com/bluesky-social/social-app/pull/2565)

mary-ext commented 4 months ago

Can confirm they are still working, tested on Web 1.81.0 (Firefox Nightly 127 and Chromium 124) and Android 1.80.0, using the link you've specified in this issue https://youtu.be/T6eK-2OQtew?si=fs1T7_cU9xvLdhqQ&t=54.

Mennaruuk commented 4 months ago

Can confirm they are still working, tested on Web 1.81.0 (Firefox Nightly 127 and Chromium 124) and Android 1.80.0, using the link you've specified in this issue https://youtu.be/T6eK-2OQtew?si=fs1T7_cU9xvLdhqQ&t=54.

I see what's wrong. Links containing the si parameter work. Links that don't contain it don't. If you can, please try the following link:

https://youtu.be/T6eK-2OQtew&t=51

mary-ext commented 4 months ago

That link is incorrect, you'd need it to be ?t=, not &t= as it's the start of the query. Like so, https://youtu.be/T6eK-2OQtew?t=51

Seems to me that YouTube does a naive conversion from youtu.be to youtube.com, hence why the link you provided even worked at all, I'm not sure if we should be replicating that naive behavior here (because this is not how URL links are supposed to work)

Mennaruuk commented 4 months ago

Perhaps you're right. It's not YouTube's fault. I remove the si part because it's a tracking parameter. When added, YouTube can track who is sharing videos with who. I simply resort to manually deleting the whole parameter. I know I can change the &t= to ?t= every time, but I thought it would be nice if Bluesky can automatically do this, or maybe it can remove this stupid si parameter since it serves no purpose other than provide YouTube with privacy-invading info. But whatever you do I'm happy with!

highlighted.jpg