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

[Feature request] Support for Jellyfin Media Player #22

Closed
LeviSnoot opened this issue Aug 5, 2022 · 12 comments
Closed

[Feature request] Support for Jellyfin Media Player #22

LeviSnoot opened this issue Aug 5, 2022 · 12 comments

Comments

@LeviSnoot
Copy link

LeviSnoot commented Aug 5, 2022

Support for JMP/JMP-web should be relatively easy to implement, since it uses only a slightly modified version of jellyfin-web.

Unfortunately, when I inject the script into JMP's index.html by adding <script plugin="Jellyscrub" version="1.0.0.4 src="/Trickplay/ClientScript"></script> or <script plugin="Jellyscrub" version="1.0.0.0 src="/Trickplay/ClientScript"></script> (not sure if the version numbering makes a difference, just following instructions from readme.md), I get the following result:

JellyfinMediaPlayer_2022-08-05_15-08-29.mp4

Is there anything besides the index.html that needs to be done to get the script working?

@nicknsy
Copy link
Owner

nicknsy commented Aug 5, 2022

In JMP 1.8.1 support for (some) third-party plugins has been added, including Jellyscrub. I've updated the README to reflect this.

"In the JMP desktop client (version >= 1.8.1), click on your profile image, go to "Client Settings", and tick "Jellyscrub" under plugin support. Restart for changes to take effect."

Old Instructions Since the web files are all included at compile time (I think), there's no easy way to do this for everyone without forking those repositories and making custom binaries, which I don't really want to do atm.

However, there is a pretty easy way to do this on an individual device basis if you're up for doing it. This works on mac too but the index.html is under /Applications/Jellyfin Media Player.app/Contents/Resources/web-client/desktop/ instead of Program Files. Also replace localhost:8096 with the actual base URL to your jellyfin server.

Paste the contents of https://github.com/nicknsy/jellyscrub/blob/main/Nick.Plugin.Jellyscrub/Api/trickplay.js into the ClientScript file

2022-08-05.13-28-52_Trim.mp4

@LeviSnoot
Copy link
Author

This worked perfectly! Thanks for the detailed video instructions, made it super easy to get everything working!

@tydog98
Copy link

tydog98 commented Aug 31, 2022

If anyone is wondering the location for the Linux Flatpak is:
/var/lib/flatpak/app/com.github.iwalton3.jellyfin-media-player/current/546e6d2801e142b3035d81843f03ce87793a14d42823ea8d14bb96232b70bf83/files/share/jellyfinmediaplayer/web-client/desktop

@TheHYPO35
Copy link

Can you clarify where the text comes from that you pasted into the document that became ClientScript?

@nicknsy
Copy link
Owner

nicknsy commented Dec 7, 2022

Can you clarify where the text comes from that you pasted into the document that became ClientScript?

Yup, forgot about that in the video.

https://github.com/nicknsy/jellyscrub/blob/main/Nick.Plugin.Jellyscrub/Api/trickplay.js

@NeuroDawg
Copy link

I'm trying to update my desktop client, but I see there's a difference in the video and what is in the current version of trickplay.js. The current version of trickplay.js has the following:
const MANIFEST_ENDPOINT = basePath + 'Trickplay/{itemId}/GetManifest';
Do I change this to:
const MANIFEST_ENDPOINT = 'https://mydomain/Trickplay/{itemId}/GetManifest';
or to something else?
Do I need to also change the following line? Or is there a different change that should be made?

Thanks!

@Mavyre
Copy link

Mavyre commented Jan 27, 2023

Do I need to also change the following line? Or is there a different change that should be made?

You can skip the file copying part, directly include the clienscript like that
<script plugin="Jellyscrub" version="1.0.0.0 src="http://yourjellyfinaddress/Trickplay/ClientScript"></script>

The new basePath thing will make it work. Tested and approved!

@NeuroDawg
Copy link

NeuroDawg commented Feb 11, 2023

Ok, I feel like an idiot, but I can't get this to work with my desktop client. Is there perhaps a cache I need to clear somewhere?

Here's what I've done:
First try:

  1. I've created a file "ClientScript" (plain text file, contents copied from https://github.com/nicknsy/jellyscrub/blob/main/Nick.Plugin.Jellyscrub/Api/trickplay.js) in my 'C:\Program Files\Jellyfin\Jellyfin Media Player\web-client\desktop\Trickplay' directory.
  2. I edited the 'index.html'file in ''C:\Program Files\Jellyfin\Jellyfin Media Player\web-client\desktop' and inserted '<script plugin="Jellyscrub" version="1.0.0.0 src="Trickplay/ClientScript"></script>' immediately before the </body> tag.

This resulted in only seeing the chapter images when I scrub the timeline.

Second try:

  1. Same as first try, but with '<script plugin="Jellyscrub" version="1.0.0.0 src="/Trickplay/ClientScript"></script>' (difference of leading slash) inserted into index.html.

Still no dice. All I see is chapter images.

Third try:

  1. Inserted '<script plugin="Jellyscrub" version="1.0.0.0 src="https://jellyfin.mydomain.us/Trickplay/ClientScript"></script>' into my index.html file. I can access the ClientScript if I enter the above URI into my browser, so I know it's visible/readable.

Again, still simply seeing the chapter images when I scrub the timeline.

This plugin is working perfectly with my iOS app and the web client. I just can't make it work with the desktop app.

What am I doing wrong? I'm using the desktop app on Win10, and my JF server is in a docker container running on an Ubuntu 22.04 server.

@iwalton3
Copy link

This will be supported in Jellyfin Media Player 1.8.0. You need to enable a plugin in settings for it to work.

@NeuroDawg
Copy link

This will be supported in Jellyfin Media Player 1.8.0. You need to enable a plugin in settings for it to work.

Great!

@ausar47
Copy link

ausar47 commented Jun 9, 2023

Could you please share your CSS? That looks great to me. Besides, how does Jellyfin show "Chapter"? I always want my Jellyfin to show Chapter like mpv does. Many Thanks!

@LeviSnoot
Copy link
Author

Could you please share your CSS? That looks great to me. Besides, how does Jellyfin show "Chapter"? I always want my Jellyfin to show Chapter like mpv does. Many Thanks!

My CSS is a modified version of prayag17 / JellySkin. I'm not going to share my modifications as they are very rough in places and you're better off modding it to your own liking instead.

I believe Jellyfin shows chapter text as default behaviour. At least I don't remember "enabling" any feature like that.

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

No branches or pull requests

8 participants