aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/static/js/plyr-start.js
diff options
context:
space:
mode:
authorJesús <heckyel@hyperbola.info>2021-05-22 17:05:39 -0500
committerJesús <heckyel@hyperbola.info>2021-05-22 17:05:39 -0500
commitb3abec81e14b583400eebb120de8e5c4b7ca1da2 (patch)
treeace867440dbf8d26b082c9730a52bb883eb19d90 /youtube/static/js/plyr-start.js
parente44647f1064c994237f6266b9b53b49a0d34db7e (diff)
downloadyt-local-b3abec81e14b583400eebb120de8e5c4b7ca1da2.tar.lz
yt-local-b3abec81e14b583400eebb120de8e5c4b7ca1da2.tar.xz
yt-local-b3abec81e14b583400eebb120de8e5c4b7ca1da2.zip
Add plyr as main player
Also plyr supports switch quality
Diffstat (limited to 'youtube/static/js/plyr-start.js')
-rw-r--r--youtube/static/js/plyr-start.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/youtube/static/js/plyr-start.js b/youtube/static/js/plyr-start.js
new file mode 100644
index 0000000..aae3002
--- /dev/null
+++ b/youtube/static/js/plyr-start.js
@@ -0,0 +1,23 @@
+// @license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3-or-Later
+const player = new Plyr(document.getElementById('js-video-player'), {
+ disableContextMenu: false,
+ captions: {
+ active: true,
+ language: 'en'
+ },
+ controls: [
+ 'play-large',
+ 'play',
+ 'progress',
+ 'current-time',
+ 'mute',
+ 'volume',
+ 'captions',
+ 'settings',
+ 'fullscreen'
+ ],
+ iconUrl: "/youtube.com/static/modules/plyr/plyr.svg",
+ blankVideo: "/youtube.com/static/modules/plyr/blank.webm",
+ debug: false
+});
+// @license-end