WindowControlsOverlay: thuộc tính visible
Khả dụng hạn chế
This feature is not Baseline because it does not work in some of the most widely-used browsers.
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
Thuộc tính chỉ đọc visible của giao diện WindowControlsOverlay trả về một Boolean cho biết lớp phủ điều khiển cửa sổ có hiển thị hay không.
Lớp phủ điều khiển cửa sổ sẽ không hiển thị nếu:
- Thành viên
display_overridecủa Web App Manifest không được đặt thànhwindow-controls-overlay. - Hoặc, nếu người dùng đã từ chối tính năng này.
Giá trị
Một giá trị boolean.
Ví dụ
js
if (navigator.windowControlsOverlay.visible) {
// Execute code if the controls overlay is visible.
} else {
// Do something else when it isn't visible.
}
Thông số kỹ thuật
| Thông số kỹ thuật |
|---|
| Window Controls Overlay> # the-visible-attribute> |
Tương thích trình duyệt
Xem thêm
- Giao diện
WindowControlsOverlaymà nó thuộc về.