mirror of
https://github.com/iv-org/invidious.git
synced 2025-11-23 09:55:29 +00:00
Add support for player styles
This currently includes the following styles: - Invidious, the default - YouTube, using a centered play button and always visible video control bar Implements https://github.com/omarroth/invidious/issues/670. Supersedes https://github.com/omarroth/invidious/pull/661.
This commit is contained in:
@@ -1478,6 +1478,9 @@ post "/preferences" do |env|
|
||||
speed = env.params.body["speed"]?.try &.as(String).to_f32?
|
||||
speed ||= CONFIG.default_user_preferences.speed
|
||||
|
||||
player_style = env.params.body["player_style"]?.try &.as(String)
|
||||
player_style ||= CONFIG.default_user_preferences.player_style
|
||||
|
||||
quality = env.params.body["quality"]?.try &.as(String)
|
||||
quality ||= CONFIG.default_user_preferences.quality
|
||||
|
||||
@@ -1546,6 +1549,7 @@ post "/preferences" do |env|
|
||||
locale: locale,
|
||||
max_results: max_results,
|
||||
notifications_only: notifications_only,
|
||||
player_style: player_style,
|
||||
quality: quality,
|
||||
redirect_feed: redirect_feed,
|
||||
related_videos: related_videos,
|
||||
|
||||
Reference in New Issue
Block a user