前端全屏模式切换
js
const isBigScreen = ref(false)
const handleScreen = () => {
if (isBigScreen.value) {
document.exitFullscreen()
isBigScreen.value = false
} else {
isBigScreen.value = true
document.documentElement.requestFullscreen() // 请求全屏模式
}
}