mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-17 10:01:20 -08:00
chore: Update screen.orientation.lock usage for autoOrientation plugin
This commit is contained in:
1 parent
574bb14643
commit
d86840749b
3 files changed
+5
-5
No files matched your search
@@ -44,7 +44,7 @@ export default function autoOrientation(art) {
|
||||
(videoWidth < videoHeight && viewWidth > viewHeight)
|
||||
) {
|
||||
const oppositeOrientation = lastOrientation.startsWith('portrait') ? 'landscape' : 'portrait';
|
||||
await screen.orientation.lock(oppositeOrientation);
|
||||
await screen.orientation.lock?.(oppositeOrientation);
|
||||
addClass($player, 'art-auto-orientation-fullscreen');
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in new issue
Block a user