PictureInPictureWindow:width 属性

Limited availability

This feature is not Baseline because it does not work in some of the most widely-used browsers.

PictureInPictureWindow 接口的 width 只读属性返回浮动视频窗口的宽度(以像素为单位)。

语法

js
pictureInPictureWindow.width

一个正整数,表示画中画窗口打开时浮动视频窗口的宽度(像素)。否则返回 0

规范

Specification
Picture-in-Picture
# ref-for-dom-pictureinpicturewindow-width

浏览器兼容性

BCD tables only load in the browser

参见