From e0fec7ffa3d34f35aa5b61e5cb635c3c0e72e05a Mon Sep 17 00:00:00 2001 From: qtchaos <72168435+qtchaos@users.noreply.github.com> Date: Fri, 15 Mar 2024 17:30:37 +0200 Subject: [PATCH 1/3] fix: add check for setPositionState to avoid TypeError --- src/components/player/internals/MediaSession.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/components/player/internals/MediaSession.tsx b/src/components/player/internals/MediaSession.tsx index 1dc7e737..73594793 100644 --- a/src/components/player/internals/MediaSession.tsx +++ b/src/components/player/internals/MediaSession.tsx @@ -32,6 +32,9 @@ export function MediaSession() { const updatePositionState = useCallback( (position: number) => { + // If the browser doesn't support setPositionState, return + if (typeof navigator.mediaSession.setPositionState !== "function") return; + // If the updated position needs to be buffered, queue an update if (position > data.progress.buffered) { shouldUpdatePositionState.current = true; From 162da3b22b206a0fe7c4923d37a414264ec79fc7 Mon Sep 17 00:00:00 2001 From: Honkertonken <94032937+Honkertonken@users.noreply.github.com> Date: Sat, 16 Mar 2024 13:12:34 +0530 Subject: [PATCH 2/3] Update vercel.json --- vercel.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/vercel.json b/vercel.json index c4639dd2..6ed1f7c3 100644 --- a/vercel.json +++ b/vercel.json @@ -1,5 +1,10 @@ { - "routes": [{ "src": "/[^.]+", "dest": "/", "status": 200 }], + "rewrites": [ + { + "source": "/(.*)", + "destination": "/" + } + ], "headers": [ { "source": "/(.*)", From 2a0e46a97d364ebf08c9faf3adba2ffe8ff9929f Mon Sep 17 00:00:00 2001 From: William Oldham Date: Sat, 16 Mar 2024 12:54:59 +0000 Subject: [PATCH 3/3] Fix #1016 - Capitalisation of zh-Hant broke traditional Chinese --- src/assets/languages.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/assets/languages.ts b/src/assets/languages.ts index e575d454..8077a5b1 100644 --- a/src/assets/languages.ts +++ b/src/assets/languages.ts @@ -82,7 +82,7 @@ export const locales = { ko, sl, ta, - "zh-HANT": zhhant, + "zh-Hant": zhhant, is, ru, gl,