diff options
Diffstat (limited to 'support/doc/api/embeds.md')
-rw-r--r-- | support/doc/api/embeds.md | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/support/doc/api/embeds.md b/support/doc/api/embeds.md index d64615764..bc3b5304c 100644 --- a/support/doc/api/embeds.md +++ b/support/doc/api/embeds.md | |||
@@ -49,6 +49,59 @@ player.seek(32) | |||
49 | player.pause() | 49 | player.pause() |
50 | ``` | 50 | ``` |
51 | 51 | ||
52 | # URL parameters | ||
53 | |||
54 | You can customize PeerTube player by specifying URL query parameters. | ||
55 | For example `https://my-instance.example.com/videos/embed/52a10666-3a18-4e73-93da-e8d3c12c305a??start=1s&stop=18s&loop=1&autoplay=1&muted=1&warningTitle=0&controlBar=0&peertubeLink=0&p2p=0` | ||
56 | |||
57 | ## start | ||
58 | |||
59 | Start the video at a specific time. | ||
60 | Value must be raw seconds or a duration (`3m4s`) | ||
61 | |||
62 | ## stop | ||
63 | |||
64 | Stop the video at a specific time. | ||
65 | Value must be raw seconds or a duration (`54s`) | ||
66 | |||
67 | ## controls | ||
68 | |||
69 | Mimics video HTML element `controls` attribute, meaning that all controls (including big play button, control bar, etc.) will be removed. | ||
70 | It can be useful if you want to have a full control of the PeerTube player. | ||
71 | |||
72 | Value must be `0` or `1`. | ||
73 | |||
74 | ## controlBar | ||
75 | |||
76 | Hide control bar when the video is played. | ||
77 | |||
78 | Value must be `0` or `1`. | ||
79 | |||
80 | ## peertubeLink | ||
81 | |||
82 | Hide PeerTube link in control bar. | ||
83 | |||
84 | Value must be `0` or `1`. | ||
85 | |||
86 | ## muted | ||
87 | |||
88 | Mute the video by default. | ||
89 | |||
90 | Value must be `0` or `1`. | ||
91 | |||
92 | ## loop | ||
93 | |||
94 | Automatically start again the video when it ends. | ||
95 | |||
96 | Value must be `0` or `1`. | ||
97 | |||
98 | ## subtitle | ||
99 | |||
100 | Auto select a subtitle by default. | ||
101 | |||
102 | Value must be a valid subtitle ISO code (`fr`, `en`, etc.). | ||
103 | |||
104 | |||
52 | # Methods | 105 | # Methods |
53 | 106 | ||
54 | ## `play() : Promise<void>` | 107 | ## `play() : Promise<void>` |