Skip to content

Commit

Permalink
fix: remove unsupported argument (remove since Chrome 70+)
Browse files Browse the repository at this point in the history
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
  • Loading branch information
Antreesy authored and backportbot[bot] committed Sep 25, 2024
1 parent f07219c commit a8c7e58
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/composables/useDocumentFullscreen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ import { createSharedComposable } from '@vueuse/core'
import { readonly, ref, onBeforeMount, onBeforeUnmount } from 'vue'
import type { Ref, DeepReadonly } from 'vue'

interface WebkitElement extends Element {
ALLOW_KEYBOARD_INPUT: FullscreenOptions;
}

/**
* Composable to check whether the page is displayed at fullscreen
* @return {DeepReadonly<Ref<boolean>>} - computed boolean whether the page is displayed at fullscreen
Expand Down Expand Up @@ -45,7 +41,7 @@ export async function enableFullscreen() {
if (element.requestFullscreen) {
await element.requestFullscreen()
} else if (element.webkitRequestFullscreen) {
await element.webkitRequestFullscreen((Element as unknown as WebkitElement).ALLOW_KEYBOARD_INPUT)
await element.webkitRequestFullscreen()
}
}

Expand Down

0 comments on commit a8c7e58

Please sign in to comment.