全宽 Vimeo 嵌入无响应
Full-Width Vimeo Embed non-responsive
我在 div
中嵌入了一个 vimeo,它是视口的全宽。该视频在几天内运行良好,但现在播放按钮(和所有其他按钮)完全没有响应。
我试过摆弄 z-index
但没用。
<div class="full-screen-vid">
<iframe src="https://player.vimeo.com/video/192013765" width="100%" height="700" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
</div>
.full-screen-vid {
width: 100vw;
position: relative;
left: 50%;
right: 50%;
margin-left: -50vw;
margin-right: -50vw;
margin-top: 90px;
z-index: -1;
}
我在控制台中收到一条奇怪的消息,我查找并尝试修复它,但我认为这不是问题所在(或整个问题),因为如果我从full-screen-vid
,它工作正常。
控制台消息:
Refused to load the script'data:application/javascript;base64,KGZ1bmN0aW9xxxxIGZ1…xxxxxxxxxxxx='
because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline'
https://f.vimeocdn.com https://ssl.google-analytics.com https://js-agent.newrelic.com https://bam.nr-data.net https://f.vimeocdn.com".
单独加载 <iframe>
,添加 full-screen-vid
class,应该可以。
我在 div
中嵌入了一个 vimeo,它是视口的全宽。该视频在几天内运行良好,但现在播放按钮(和所有其他按钮)完全没有响应。
我试过摆弄 z-index
但没用。
<div class="full-screen-vid">
<iframe src="https://player.vimeo.com/video/192013765" width="100%" height="700" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
</div>
.full-screen-vid {
width: 100vw;
position: relative;
left: 50%;
right: 50%;
margin-left: -50vw;
margin-right: -50vw;
margin-top: 90px;
z-index: -1;
}
我在控制台中收到一条奇怪的消息,我查找并尝试修复它,但我认为这不是问题所在(或整个问题),因为如果我从full-screen-vid
,它工作正常。
控制台消息:
Refused to load the script'data:application/javascript;base64,KGZ1bmN0aW9xxxxIGZ1…xxxxxxxxxxxx='
because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline'
https://f.vimeocdn.com https://ssl.google-analytics.com https://js-agent.newrelic.com https://bam.nr-data.net https://f.vimeocdn.com".
单独加载 <iframe>
,添加 full-screen-vid
class,应该可以。