Skip to content

Update shaka-player to 4.16.x#7919

Merged
FreeTubeBot merged 13 commits intoFreeTubeApp:developmentfrom
absidue:update-shaka-player
Sep 16, 2025
Merged

Update shaka-player to 4.16.x#7919
FreeTubeBot merged 13 commits intoFreeTubeApp:developmentfrom
absidue:update-shaka-player

Conversation

@absidue
Copy link
Member

@absidue absidue commented Aug 24, 2025

Pull Request Type

  • Feature Implementation
  • Other

Related issue

Description

shaka-player 4.15 includes a redesigned player UI, which required a few changes to our custom player components as well as the CSS. As the UI changes increase the spacing between the player buttons, I also thought this was a good momement to address Move player controls to the overflow menu which we have been planning to do for a while now. Additionally I switched our audio track selector over to the new getAudioTracks() and selectAudioTrack() API.

shaka-player 4.16 changed from using the Material Icons font in the CSS file to using SVGs created via JavaScript, this does mean that the JavaScript file is larger but we no longer need to download the Material Icons font and patch the CSS file to reference the downloaded version.

Screenshots

shaka-player UI changes

Testing

Try playing some videos and test that the various UI components work correctly.

Desktop

  • OS: Windows
  • OS Version: 10

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 24, 2025 14:28
@github-actions github-actions bot added PR: dependencies Pull requests that update a dependency file PR: waiting for review For PRs that are complete, tested, and ready for review labels Aug 24, 2025
@PikachuEXE
Copy link
Member

All scroll over player functions not working (I tried all
image

@efb4f5ff-1298-471a-8973-3d47447115dc efb4f5ff-1298-471a-8973-3d47447115dc added PR: changes requested and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Aug 25, 2025
@PikachuEXE
Copy link
Member

Adding classList.contains('shaka-controls-container') to handleControlsContainerWheel seems to work

@efb4f5ff-1298-471a-8973-3d47447115dc

i change the volume with the slider but the color wont adjust

Freetube.8Hbapf9cpa.mp4

@efb4f5ff-1298-471a-8973-3d47447115dc

FYI: v4.16.0 just released

@absidue
Copy link
Member Author

absidue commented Aug 26, 2025

I'll change this PR to jump straight to 4.16.0 then, no point doing two separate PRs right after each other (4.16 will also require more changes than just bumping the version).

@absidue absidue changed the title Update shaka-player to 4.15.x Update shaka-player to 4.16.x Aug 28, 2025
@absidue absidue added PR: waiting for review For PRs that are complete, tested, and ready for review and removed PR: changes requested labels Aug 28, 2025
@absidue
Copy link
Member Author

absidue commented Aug 28, 2025

@efb4f5ff-1298-471a-8973-3d47447115dc That issue is caused by touch interactions triggering the mouse wheel event that we add to the volume slider, so you can adjust it by hovering over it and scrolling. I don't know why touch interactions trigger touch events and wheel events at the same time but that's what is causing the problem here.

@PikachuEXE
Copy link
Member

PikachuEXE commented Aug 28, 2025

Not review for this PR but SABR implementation seems broken (renderer process taking 100% CPU) after merging this (no code conflict) and I have no idea why...
(Note: only SABR, current DASH implementation is fine

A request stuck in pending?
image

Update 1: even non SABR request can be stuck
image

Update 2: Also got stuck in 4.5.12, not sure if the cause is the same though
image

Update 3: After using local shaka-player repo to checkout tags (long process), it seems to be shaka-project/shaka-player#8782 causing the issue

Update 4: Issue with our custom URL triggering a bug in https://github.com/shaka-project/shaka-player/blob/v4.16.0/lib/util/cmcd_manager.js#L1348, adding a fake host seems to workaround it

Update 5: Submitted issue shaka-project/shaka-player#9050

@PikachuEXE
Copy link
Member

Testing SABR with this PR: https://github.com/PikachuEXE/FreeTube/actions/runs/17323879326
Will approve after testing for ~ 1 week (no issues so far last few days

Copy link
Member

@efb4f5ff-1298-471a-8973-3d47447115dc efb4f5ff-1298-471a-8973-3d47447115dc left a comment

Choose a reason for hiding this comment

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

Error while testing various window sizes

VirtualBoxVM_YIOKFNvgUw.mp4

How player icons looked like in an earlier build of this PR. These look correct to me

FreeTube_hzfOG7gheN

How they look now

VirtualBoxVM_NwdSKYIoQY

@absidue
Copy link
Member Author

absidue commented Sep 1, 2025

@efb4f5ff-1298-471a-8973-3d47447115dc That error message is not from us, that's coming from webpack's dev server intercepting errors to show in that popup, in this case it's a warning from Electron that an event handler is too slow and may cause performance problems during the resize but as there is nothing in the console I'm pretty sure it is happening inside shaka-player. (reminder that we need to turn off that webpack dev server overlay, as this is not the first time that it has shown irrelevant errors)

The only icon of concern is the theatre mode one, all others are different because shaka-player changed Material Icons to Material Symbols to in 0.16.x.

@absidue
Copy link
Member Author

absidue commented Sep 9, 2025

@PikachuEXE It's been 9 days, any issues?

@PikachuEXE
Copy link
Member

No issue
I can see https://github.com/shaka-project/shaka-player/releases/tag/v4.16.1 released which should be included for prefers-reduced-transparency and a fix which enables me to remove the workaround
After that we can merge this

@absidue
Copy link
Member Author

absidue commented Sep 10, 2025

Done!

PikachuEXE
PikachuEXE previously approved these changes Sep 11, 2025
@PikachuEXE
Copy link
Member

reminder that we need to turn off that webpack dev server overlay

Separate PR I guess

@github-actions

This comment was marked as resolved.

@github-actions github-actions bot added PR: merge conflicts / rebase needed and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Sep 12, 2025
@github-actions
Copy link
Contributor

Conflicts have been resolved. A maintainer will review the pull request shortly.

@absidue absidue added the PR: waiting for review For PRs that are complete, tested, and ready for review label Sep 12, 2025
@PikachuEXE
Copy link
Member

@efb4f5ff-1298-471a-8973-3d47447115dc

This comment was marked as outdated.

@FreeTubeBot FreeTubeBot merged commit f5ac1a3 into FreeTubeApp:development Sep 16, 2025
5 checks passed
@github-actions github-actions bot removed the PR: waiting for review For PRs that are complete, tested, and ready for review label Sep 16, 2025
PikachuEXE added a commit to PikachuEXE/FreeTube that referenced this pull request Sep 17, 2025
* development:
  Translated using Weblate (Portuguese (Brazil))
  Update shaka-player to 4.16.x (FreeTubeApp#7919)
  Translated using Weblate (Portuguese (Brazil))
  Translated using Weblate (Portuguese (Brazil))
  [Feature]: Hide videos immediately when marking as watched (FreeTubeApp#7866)
  Bump actions/setup-node from 4 to 5 (FreeTubeApp#8000)
PikachuEXE added a commit to NishPatel101/FreeTube that referenced this pull request Sep 17, 2025
* development: (65 commits)
  Translated using Weblate (Portuguese (Brazil))
  Update shaka-player to 4.16.x (FreeTubeApp#7919)
  Translated using Weblate (Portuguese (Brazil))
  Translated using Weblate (Portuguese (Brazil))
  [Feature]: Hide videos immediately when marking as watched (FreeTubeApp#7866)
  Bump actions/setup-node from 4 to 5 (FreeTubeApp#8000)
  Bump mikefarah/yq from 4.47.1 to 4.47.2 (FreeTubeApp#8039)
  Bump marked from 16.2.1 to 16.3.0 (FreeTubeApp#8040)
  Bump eslint-plugin-jsdoc from 57.0.3 to 57.0.8 in the eslint group (FreeTubeApp#8038)
  Adjust homebrew link to maintainers tap (FreeTubeApp#8041)
  Remove n argument in sed (FreeTubeApp#8033)
  Translated using Weblate (Russian)
  Bump eslint-plugin-jsdoc from 56.1.2 to 57.0.3 in the eslint group (FreeTubeApp#8030)
  Bump youtubei.js from 15.1.0 to 15.1.1 (FreeTubeApp#8031)
  Translated using Weblate (Polish)
  Bump eslint-plugin-jsdoc from 55.0.0 to 56.1.2 in the eslint group (FreeTubeApp#8020)
  Bump lefthook from 1.12.4 to 1.13.0 (FreeTubeApp#8026)
  Bump swiper from 11.2.10 to 12.0.1 (FreeTubeApp#8024)
  Bump globals from 16.3.0 to 16.4.0 (FreeTubeApp#8023)
  Bump package version from 0.23.8 to 0.23.9 (FreeTubeApp#8027)
  ...
@absidue absidue deleted the update-shaka-player branch September 17, 2025 08:03
caetano-dev pushed a commit to caetano-dev/FreeTube that referenced this pull request Sep 17, 2025
* Update shaka-player to 4.15.x

* Move some items into the overflow menu on all player sizes

* Fix mouse wheel actions

* Update shaka-player to 4.16.x

* Re-order entries in the overflow menu on mobile

* Fix player icons

* Optimise audio track handling

* Upstream prefers-reduced-transparency for shaka-player's UI elements

* Update shaka-player to 4.16.1
This was referenced Sep 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: dependencies Pull requests that update a dependency file

Projects

None yet

6 participants