aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAstound <kirito@disroot.org>2024-01-29 05:06:38 +0800
committerAstound <kirito@disroot.org>2024-01-29 05:06:38 +0800
commit3ee2df7faaac2f97a3b0cb28b43854cc11cd97a9 (patch)
treefd48a37d78b749f7342fb2667b83153c2abda0f5
parentd2c883c21142e952acab0cd8dea010814e0cb648 (diff)
downloadyt-local-3ee2df7faaac2f97a3b0cb28b43854cc11cd97a9.tar.lz
yt-local-3ee2df7faaac2f97a3b0cb28b43854cc11cd97a9.tar.xz
yt-local-3ee2df7faaac2f97a3b0cb28b43854cc11cd97a9.zip
Refactor styles on video playback page
Made changes to the styles on the video playback page to enhance visibility and address issues with the video player. Added a new custom style file for Plyr, and removed redundant and unused styles in watch.css. Specific changes: - Added custom_plyr.css for Plyr styles. - Removed redundant styles related to playback issues in watch.css
-rw-r--r--youtube/static/modules/plyr/custom_plyr.css22
-rw-r--r--youtube/static/watch.css14
-rw-r--r--youtube/templates/watch.html8
3 files changed, 23 insertions, 21 deletions
diff --git a/youtube/static/modules/plyr/custom_plyr.css b/youtube/static/modules/plyr/custom_plyr.css
new file mode 100644
index 0000000..7658321
--- /dev/null
+++ b/youtube/static/modules/plyr/custom_plyr.css
@@ -0,0 +1,22 @@
+/* Prevent this div from blocking right-click menu for video
+e.g. Firefox playback speed options */
+.plyr__poster {
+ display: none;
+}
+
+/* plyr fix */
+.plyr:-moz-full-screen video {
+ max-height: initial;
+}
+
+.plyr:-webkit-full-screen video {
+ max-height: initial;
+}
+
+.plyr:-ms-fullscreen video {
+ max-height: initial;
+}
+
+.plyr:fullscreen video {
+ max-height: initial;
+}
diff --git a/youtube/static/watch.css b/youtube/static/watch.css
index 849e22b..460bba3 100644
--- a/youtube/static/watch.css
+++ b/youtube/static/watch.css
@@ -24,20 +24,6 @@ video {
max-height: calc(100vh/1.5);
}
-/* plyr fix */
-.plyr:-moz-full-screen video {
- max-height: initial;
-}
-.plyr:-webkit-full-screen video {
- max-height: initial;
-}
-.plyr:-ms-fullscreen video {
- max-height: initial;
-}
-.plyr:fullscreen video {
- max-height: initial;
-}
-
a:link {
color: var(--link);
}
diff --git a/youtube/templates/watch.html b/youtube/templates/watch.html
index 9cf9657..0991457 100644
--- a/youtube/templates/watch.html
+++ b/youtube/templates/watch.html
@@ -8,14 +8,8 @@
{% if settings.use_video_player == 2 %}
<!-- plyr -->
<link href="/youtube.com/static/modules/plyr/plyr.css" rel="stylesheet">
+ <link href="/youtube.com/static/modules/plyr/custom_plyr.css" rel="stylesheet">
<!--/ plyr -->
- <style>
- /* Prevent this div from blocking right-click menu for video
- e.g. Firefox playback speed options */
- .plyr__poster {
- display: none !important;
- }
- </style>
{% endif %}
{% endblock style %}