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

Disable preloading of subtitles in video.js #283

Merged
merged 1 commit into from
Aug 2, 2024

Conversation

dan-niles
Copy link
Collaborator

@dan-niles dan-niles commented Aug 2, 2024

Close #38

This PR disables the preloading of subtitles in video.js for zimui. Changes include:

  • Set preloadTextTracks as false for both html5 and ogvjs tech plugins.

Tested on Chrome v127 and Safari 11.1

@dan-niles dan-niles self-assigned this Aug 2, 2024
@dan-niles dan-niles marked this pull request as ready for review August 2, 2024 06:13
Copy link

codecov bot commented Aug 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 1.54%. Comparing base (402bf37) to head (b5753e0).

Additional details and impacted files
@@          Coverage Diff          @@
##            main    #283   +/-   ##
=====================================
  Coverage   1.54%   1.54%           
=====================================
  Files         11      11           
  Lines       1102    1102           
  Branches     162     162           
=====================================
  Hits          17      17           
  Misses      1085    1085           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dan-niles dan-niles requested a review from benoit74 August 2, 2024 06:14
Copy link
Collaborator

@benoit74 benoit74 left a comment

Choose a reason for hiding this comment

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

Please add a mention that we patched this file in the comment block where we referenced the source and commit-id, with a link to this specific commit, otherwise it will get lost next time we update / it will be hard to remember what needs to be patched.

Please also open an issue + a PR at https://github.com/HuongNV13/videojs-ogvjs so that we have a chance this is merged upstream + we share this with "the world".

@dan-niles
Copy link
Collaborator Author

I made a mistake here. It looks like we don't need to edit the videojs-ogvjs plugin. The plugin already extends the Tech class of video.js which means we can directly use the preloadTextTracks option for ogvjs without any modifications to the plugin.

Copy link
Collaborator

@benoit74 benoit74 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@benoit74 benoit74 merged commit 60b85b5 into main Aug 2, 2024
7 checks passed
@benoit74 benoit74 deleted the disable-subtitles-preloading branch August 2, 2024 08:53
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.

Do not preload subtitles in video.JS
2 participants