aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets
diff options
context:
space:
mode:
authorWilliam Lahti <wilahti@gmail.com>2018-07-10 08:47:56 -0700
committerChocobozzz <me@florianbigard.com>2018-07-10 17:47:56 +0200
commit999417328bde0e60cd59318fc1c18672356254ce (patch)
tree22673fcbd4dc333e3362912b2c813e97a41c765f /client/src/assets
parent0b755f3b27190ea4d9c301ede0955b2736605f4c (diff)
downloadPeerTube-999417328bde0e60cd59318fc1c18672356254ce.tar.gz
PeerTube-999417328bde0e60cd59318fc1c18672356254ce.tar.zst
PeerTube-999417328bde0e60cd59318fc1c18672356254ce.zip
Ability to programmatically control embeds (#776)
* first stab at jschannel based player api * semicolon purge * more method-level docs; consolidate definitions * missing definitions * better match peertube's class conventions * styling for embed tester * basic docs * add `getVolume` * document the test-embed feature
Diffstat (limited to 'client/src/assets')
-rw-r--r--client/src/assets/player/peertube-player.ts9
1 files changed, 7 insertions, 2 deletions
diff --git a/client/src/assets/player/peertube-player.ts b/client/src/assets/player/peertube-player.ts
index 7e339990c..baae740fe 100644
--- a/client/src/assets/player/peertube-player.ts
+++ b/client/src/assets/player/peertube-player.ts
@@ -29,10 +29,15 @@ function getVideojsOptions (options: {
29 peertubeLink: boolean, 29 peertubeLink: boolean,
30 poster: string, 30 poster: string,
31 startTime: number 31 startTime: number
32 theaterMode: boolean 32 theaterMode: boolean,
33 controls?: boolean,
34 muted?: boolean,
35 loop?: boolean
33}) { 36}) {
34 const videojsOptions = { 37 const videojsOptions = {
35 controls: true, 38 controls: options.controls !== undefined ? options.controls : true,
39 muted: options.controls !== undefined ? options.muted : false,
40 loop: options.loop !== undefined ? options.loop : false,
36 poster: options.poster, 41 poster: options.poster,
37 autoplay: false, 42 autoplay: false,
38 inactivityTimeout: options.inactivityTimeout, 43 inactivityTimeout: options.inactivityTimeout,