As question suggested i want to hide the play/Pause button from "Youtube" player.
I am using https://github.com/youtube/youtube-ios-player-helper
问题建议我想隐藏“Youtube”播放器中的播放/暂停按钮。我正在使用https://github.com/youtube/youtube-ios-player-helper
and setting the playerVars parameter like this:
并设置playerVars参数,如下所示:
let playerVars = [
"controls" : 0,
"playsinline" : 1,
"autohide" : 0,
"showinfo" : 0,
"modestbranding" : 0
]
1 个解决方案
#1
1
The three parameters I found useful are:
我发现有用的三个参数是:
showinfo=0
controls=0
autohide=1
showinfo=0
makes sure the video does not display the title on the top of the video frame.
showinfo = 0确保视频不显示视频帧顶部的标题。
controls=0
hides the bottom bar with the play button, volume, etc.
controls = 0用播放按钮,音量等隐藏底栏。
autohide=1
hides the controls until you hover over them, which is probably the most useful.
autohide = 1隐藏控件,直到将鼠标悬停在它们上面,这可能是最有用的。
All the official docs are here.
所有官方文档都在这里。
But you can use embed with custom CSS to hide or adjust he location of the Play button.
但您可以使用嵌入自定义CSS来隐藏或调整播放按钮的位置。
button.ytp-large-play-button.ytp-button {
display: none;
}
#1
1
The three parameters I found useful are:
我发现有用的三个参数是:
showinfo=0
controls=0
autohide=1
showinfo=0
makes sure the video does not display the title on the top of the video frame.
showinfo = 0确保视频不显示视频帧顶部的标题。
controls=0
hides the bottom bar with the play button, volume, etc.
controls = 0用播放按钮,音量等隐藏底栏。
autohide=1
hides the controls until you hover over them, which is probably the most useful.
autohide = 1隐藏控件,直到将鼠标悬停在它们上面,这可能是最有用的。
All the official docs are here.
所有官方文档都在这里。
But you can use embed with custom CSS to hide or adjust he location of the Play button.
但您可以使用嵌入自定义CSS来隐藏或调整播放按钮的位置。
button.ytp-large-play-button.ytp-button {
display: none;
}