Add fullscreen icon on the front mage

This commit is contained in:
kwaroran
2024-03-15 07:56:38 +09:00
parent a8a83475e3
commit aad072294e
2 changed files with 13 additions and 2 deletions

View File

@@ -1468,4 +1468,8 @@ export async function fetchNative(url:string, arg:{
export function textifyReadableStream(stream:ReadableStream<Uint8Array>){
return new Response(stream).text()
}
export function toggleFullscreen(){
document.fullscreenElement ? document.exitFullscreen() : document.documentElement.requestFullscreen()
}