]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/standalone/videos/test-embed.ts
Merge branch 'release/4.2.0' into develop
[github/Chocobozzz/PeerTube.git] / client / src / standalone / videos / test-embed.ts
index a051f1f89d75974fbd6320b15e081738f73b4edb..18c338a2da583d303c259fe2cb49a8b89e2a3d6f 100644 (file)
@@ -15,6 +15,8 @@ window.addEventListener('load', async () => {
     ? `/video-playlists/embed/${elementId}?api=1`
     : `/videos/embed/${elementId}?api=1`
 
+  iframe.sandbox.add('allow-same-origin', 'allow-scripts', 'allow-popups')
+
   const mainElement = document.querySelector('#host')
   mainElement.appendChild(iframe)
 
@@ -47,7 +49,7 @@ window.addEventListener('load', async () => {
   let playbackRates: number[] = []
   let currentRate = await player.getPlaybackRate()
 
-  const updateRates = async () => {
+  const updateRates = () => {
     const rateListEl = document.querySelector('#rate-list')
     rateListEl.innerHTML = ''
 
@@ -84,8 +86,6 @@ window.addEventListener('load', async () => {
     captionEl.innerHTML = ''
 
     captions.forEach(c => {
-      console.log(c)
-
       if (c.mode === 'showing') {
         const itemEl = document.createElement('strong')
         itemEl.innerText = `${c.label} (active)`