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

WIP: Add Jellyfin support #505

Merged
merged 1 commit into from
Sep 14, 2024
Merged

Conversation

shekhirin
Copy link
Contributor

@shekhirin shekhirin commented Aug 25, 2024

Closes #442

The API itself is very similar to Emby, with minor changes to ApiClient.

TODO:

  • When the subtitle selection dialog is opened before subtitles are loaded, entries will have a spinner until you re-open the dialog
  • Auto-pause works, but auto-play doesn't. Video element detection seems to work (because pause works), but hover event listener does not.
  • Subtitles are hovering on top of media progress and controls bar image
  • Jellyfin pages.json entry shouldn't conflict with Emby, because hash is different, but I didn't test it.
  • I did a hacky timeout with five retries to fetch the subtitles, but I'm not sure if that's the best way to do it. I see that netflix-page.ts has the same approach.

Other than that, it works pretty well 🙂
image

@shekhirin shekhirin changed the title WIP: Add jellyfin support WIP: Add Jellyfin support Aug 25, 2024
@killergerbah
Copy link
Owner

Thanks for your work! Just some general comments on the TODOs you listed:

When the subtitle selection dialog is opened before subtitles are loaded, entries will have a spinner until you re-open the dialog

This is a problem in general with the subtitle track selector dialog. Not necessary to fix with the functionality you're adding but definitely a welcome fix it you'd like to attempt it.

Auto-pause works, but auto-play doesn't. Video element detection seems to work (because pause works), but hover event listener does not.

Auto-play works by detecting hover on top of the video element, in order to deal with the case where users are mousing inside a popup dictionary like Yomitan (don't want to auto-play in that case). So I suspect there is something about Jellyfin making the video hover detection not work.

Subtitles are hovering on top of media progress and controls bar

This is a side effect of how subtitles are rendered in general in order to keep the subtitles text selectable and I don't think it's necessary to fix. Users have the option to adjust the position of the subtitles.

@bpwhelan
Copy link
Contributor

bpwhelan commented Sep 11, 2024

@shekhirin Hey, would you consider this still WIP? I added Emby support to asbplayer and all the things you listed are "technically" issues in Emby too.

@killergerbah may have a different opinion though.

@shekhirin
Copy link
Contributor Author

shekhirin commented Sep 11, 2024

@shekhirin Hey, would you consider this still WIP? I added Emby support to asbplayer and all the things you listed are "technically" issues in Emby too.

I see, then it's ready for review 😄 I've been using this for the past weeks and it's been good so far.

@shekhirin shekhirin marked this pull request as ready for review September 11, 2024 15:54
@killergerbah
Copy link
Owner

Thanks!

@killergerbah killergerbah merged commit 1f23d2a into killergerbah:main Sep 14, 2024
1 check failed
@killergerbah killergerbah added this to the Extension v1.5.0 milestone Sep 14, 2024
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.

[Feature Request] Add automatic subtitle detection for Jellyfin
3 participants