From 96a010b166c6ec034b9ce32212070372c344825d Mon Sep 17 00:00:00 2001 From: 4gray Date: Thu, 14 May 2026 21:50:10 +0200 Subject: [PATCH] feat(playback): diagnose browser stream access errors Entire-Checkpoint: f957cd9849e0 --- apps/web/src/assets/i18n/ar.json | 60 ++++++++++--------- apps/web/src/assets/i18n/ary.json | 60 ++++++++++--------- apps/web/src/assets/i18n/by.json | 60 ++++++++++--------- apps/web/src/assets/i18n/de.json | 60 ++++++++++--------- apps/web/src/assets/i18n/el.json | 60 ++++++++++--------- apps/web/src/assets/i18n/en.json | 60 ++++++++++--------- apps/web/src/assets/i18n/es.json | 60 ++++++++++--------- apps/web/src/assets/i18n/fr.json | 60 ++++++++++--------- apps/web/src/assets/i18n/it.json | 60 ++++++++++--------- apps/web/src/assets/i18n/ja.json | 60 ++++++++++--------- apps/web/src/assets/i18n/ko.json | 60 ++++++++++--------- apps/web/src/assets/i18n/nl.json | 60 ++++++++++--------- apps/web/src/assets/i18n/pl.json | 60 ++++++++++--------- apps/web/src/assets/i18n/pt.json | 60 ++++++++++--------- apps/web/src/assets/i18n/ru.json | 60 ++++++++++--------- apps/web/src/assets/i18n/tr.json | 60 ++++++++++--------- apps/web/src/assets/i18n/zh.json | 60 ++++++++++--------- apps/web/src/assets/i18n/zhtw.json | 60 ++++++++++--------- .../playback-diagnostics.util.spec.ts | 53 ++++++++++++++++ .../playback-diagnostics.util.ts | 36 +++++++++-- .../web-player-view.component.spec.ts | 26 ++++++++ .../web-player-view.component.ts | 2 + 22 files changed, 689 insertions(+), 508 deletions(-) diff --git a/apps/web/src/assets/i18n/ar.json b/apps/web/src/assets/i18n/ar.json index 723daab4f..c712b9a50 100644 --- a/apps/web/src/assets/i18n/ar.json +++ b/apps/web/src/assets/i18n/ar.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "السمة الفاتحة", "SYSTEM_THEME": "سمة النظام" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "إخفاء قائمة القنوات", "SHOW_CHANNELS_LIST": "إظهار قائمة القنوات", diff --git a/apps/web/src/assets/i18n/ary.json b/apps/web/src/assets/i18n/ary.json index e21c67da6..2b7d4f321 100644 --- a/apps/web/src/assets/i18n/ary.json +++ b/apps/web/src/assets/i18n/ary.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "المظهر الفاتح", "SYSTEM_THEME": "مظهر النظام" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "إخفاء قائمة القنوات", "SHOW_CHANNELS_LIST": "إظهار قائمة القنوات", diff --git a/apps/web/src/assets/i18n/by.json b/apps/web/src/assets/i18n/by.json index 38a14c918..77037ce1f 100644 --- a/apps/web/src/assets/i18n/by.json +++ b/apps/web/src/assets/i18n/by.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Светлая тэма", "SYSTEM_THEME": "Сістэмная тэма" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Схаваць спіс каналаў", "SHOW_CHANNELS_LIST": "Паказаць спіс каналаў", diff --git a/apps/web/src/assets/i18n/de.json b/apps/web/src/assets/i18n/de.json index 6cbf84c63..dbcd57b82 100644 --- a/apps/web/src/assets/i18n/de.json +++ b/apps/web/src/assets/i18n/de.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Hell", "SYSTEM_THEME": "System" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Senderliste ausblenden", "SHOW_CHANNELS_LIST": "Senderliste einblenden", diff --git a/apps/web/src/assets/i18n/el.json b/apps/web/src/assets/i18n/el.json index 169dd5d95..8ccb9a5d3 100644 --- a/apps/web/src/assets/i18n/el.json +++ b/apps/web/src/assets/i18n/el.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Ανοιχτόχρωμο θέμα", "SYSTEM_THEME": "Θέμα συστήματος" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Απόκρυψη λίστας καναλιών", "SHOW_CHANNELS_LIST": "Εμφάνιση λίστας καναλιών", diff --git a/apps/web/src/assets/i18n/en.json b/apps/web/src/assets/i18n/en.json index faf73197b..f2a00f2fe 100644 --- a/apps/web/src/assets/i18n/en.json +++ b/apps/web/src/assets/i18n/en.json @@ -366,35 +366,39 @@ "LIGHT_THEME": "Light theme", "SYSTEM_THEME": "System theme" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Hide channels list", "SHOW_CHANNELS_LIST": "Show channels list", diff --git a/apps/web/src/assets/i18n/es.json b/apps/web/src/assets/i18n/es.json index 7ccfed620..f24a62cb6 100644 --- a/apps/web/src/assets/i18n/es.json +++ b/apps/web/src/assets/i18n/es.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Tema claro", "SYSTEM_THEME": "Tema del sistema" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Ocultar lista de canales", "SHOW_CHANNELS_LIST": "Mostrar lista de canales", diff --git a/apps/web/src/assets/i18n/fr.json b/apps/web/src/assets/i18n/fr.json index 35e451955..fb59f39af 100644 --- a/apps/web/src/assets/i18n/fr.json +++ b/apps/web/src/assets/i18n/fr.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Thème clair", "SYSTEM_THEME": "Thème du système" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Masquer la liste des chaînes", "SHOW_CHANNELS_LIST": "Afficher la liste des chaînes", diff --git a/apps/web/src/assets/i18n/it.json b/apps/web/src/assets/i18n/it.json index 81b47e2ec..c0d475eb6 100644 --- a/apps/web/src/assets/i18n/it.json +++ b/apps/web/src/assets/i18n/it.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Tema chiaro", "SYSTEM_THEME": "Tema di sistema" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Nascondi elenco canali", "SHOW_CHANNELS_LIST": "Mostra elenco canali", diff --git a/apps/web/src/assets/i18n/ja.json b/apps/web/src/assets/i18n/ja.json index 653ae142e..cc0fdabca 100644 --- a/apps/web/src/assets/i18n/ja.json +++ b/apps/web/src/assets/i18n/ja.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "ライトテーマ", "SYSTEM_THEME": "システムテーマ" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "チャンネル一覧を非表示", "SHOW_CHANNELS_LIST": "チャンネル一覧を表示", diff --git a/apps/web/src/assets/i18n/ko.json b/apps/web/src/assets/i18n/ko.json index 73b698b3f..1683de803 100644 --- a/apps/web/src/assets/i18n/ko.json +++ b/apps/web/src/assets/i18n/ko.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "밝은 테마", "SYSTEM_THEME": "시스템 테마" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "채널 목록 숨기기", "SHOW_CHANNELS_LIST": "채널 목록 표시", diff --git a/apps/web/src/assets/i18n/nl.json b/apps/web/src/assets/i18n/nl.json index e4a4f28e2..da59ff376 100644 --- a/apps/web/src/assets/i18n/nl.json +++ b/apps/web/src/assets/i18n/nl.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Licht thema", "SYSTEM_THEME": "Systeemthema" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Zenderlijst verbergen", "SHOW_CHANNELS_LIST": "Zenderlijst tonen", diff --git a/apps/web/src/assets/i18n/pl.json b/apps/web/src/assets/i18n/pl.json index c0293fa21..24bcb4618 100644 --- a/apps/web/src/assets/i18n/pl.json +++ b/apps/web/src/assets/i18n/pl.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Jasny motyw", "SYSTEM_THEME": "Motyw systemowy" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Ukryj listę kanałów", "SHOW_CHANNELS_LIST": "Pokaż listę kanałów", diff --git a/apps/web/src/assets/i18n/pt.json b/apps/web/src/assets/i18n/pt.json index 6cada2740..b0e76969e 100644 --- a/apps/web/src/assets/i18n/pt.json +++ b/apps/web/src/assets/i18n/pt.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Tema claro", "SYSTEM_THEME": "Tema do sistema" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Ocultar lista de canais", "SHOW_CHANNELS_LIST": "Mostrar lista de canais", diff --git a/apps/web/src/assets/i18n/ru.json b/apps/web/src/assets/i18n/ru.json index af1480a04..da68eed5e 100644 --- a/apps/web/src/assets/i18n/ru.json +++ b/apps/web/src/assets/i18n/ru.json @@ -364,35 +364,39 @@ "LIGHT_THEME": "Светлая тема", "SYSTEM_THEME": "Системная тема" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "Контейнер потока, вероятно, не поддерживается встроенным браузерным плеером", - "DESCRIPTION": "Chromium/Electron может не воспроизводить этот контейнер внутри приложения. Попробуйте MPV или VLC с более широкой поддержкой кодеков." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "Кодек потока, вероятно, не поддерживается встроенным браузерным плеером", - "DESCRIPTION": "Поток сообщает кодеки, которые встроенный Chromium-плеер может не декодировать. MPV или VLC часто справляются с такими потоками." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "Браузерный плеер не смог декодировать этот поток", - "DESCRIPTION": "Воспроизведение началось, но медиапайплайн завершился ошибкой декодирования. Внешний плеер может обработать этот поток лучше." - }, - "NETWORK_ERROR": { - "TITLE": "Не удалось загрузить поток", - "DESCRIPTION": "Плеер сообщил сетевую ошибку или ошибку загрузки у провайдера. Проверьте URL потока, заголовки или доступность провайдера." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "Поток может быть зашифрован или защищен DRM", - "DESCRIPTION": "Браузерный плеер не может продолжить из-за ошибки ключа или шифрования. Внешний плеер тоже может не помочь, если требуется DRM провайдера." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "Браузерный плеер сообщил ошибку воспроизведения", - "DESCRIPTION": "Поток не воспроизвелся во встроенном плеере, но ошибка не указала конкретную причину в кодеке, контейнере или сети." - }, - "ACTION_OPEN_MPV": "Открыть в MPV", - "ACTION_OPEN_VLC": "Открыть в VLC", - "ACTION_COPY_URL": "Скопировать URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "Контейнер потока, вероятно, не поддерживается встроенным браузерным плеером", + "DESCRIPTION": "Chromium/Electron может не воспроизводить этот контейнер внутри приложения. Попробуйте MPV или VLC с более широкой поддержкой кодеков." }, + "UNSUPPORTED_CODEC": { + "TITLE": "Кодек потока, вероятно, не поддерживается встроенным браузерным плеером", + "DESCRIPTION": "Поток сообщает кодеки, которые встроенный Chromium-плеер может не декодировать. MPV или VLC часто справляются с такими потоками." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "Браузерный плеер не смог декодировать этот поток", + "DESCRIPTION": "Воспроизведение началось, но медиапайплайн завершился ошибкой декодирования. Внешний плеер может обработать этот поток лучше." + }, + "NETWORK_ERROR": { + "TITLE": "Не удалось загрузить поток", + "DESCRIPTION": "Плеер сообщил сетевую ошибку или ошибку загрузки у провайдера. Проверьте URL потока, заголовки или доступность провайдера." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "Браузерный плеер не получил доступ к потоку", + "DESCRIPTION": "Запрос может быть заблокирован CORS, mixed content или требованиями провайдера/прокси к заголовкам. MPV или VLC часто обходят такие ограничения браузерного плеера." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "Поток может быть зашифрован или защищен DRM", + "DESCRIPTION": "Браузерный плеер не может продолжить из-за ошибки ключа или шифрования. Внешний плеер тоже может не помочь, если требуется DRM провайдера." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "Браузерный плеер сообщил ошибку воспроизведения", + "DESCRIPTION": "Поток не воспроизвелся во встроенном плеере, но ошибка не указала конкретную причину в кодеке, контейнере или сети." + }, + "ACTION_OPEN_MPV": "Открыть в MPV", + "ACTION_OPEN_VLC": "Открыть в VLC", + "ACTION_COPY_URL": "Скопировать URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Скрыть список каналов", "SHOW_CHANNELS_LIST": "Показать список каналов", diff --git a/apps/web/src/assets/i18n/tr.json b/apps/web/src/assets/i18n/tr.json index 059d257f1..b86da3b85 100644 --- a/apps/web/src/assets/i18n/tr.json +++ b/apps/web/src/assets/i18n/tr.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "Açık tema", "SYSTEM_THEME": "Sistem teması" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "Kanal listesini gizle", "SHOW_CHANNELS_LIST": "Kanal listesini göster", diff --git a/apps/web/src/assets/i18n/zh.json b/apps/web/src/assets/i18n/zh.json index a2096f120..cb3c029f2 100644 --- a/apps/web/src/assets/i18n/zh.json +++ b/apps/web/src/assets/i18n/zh.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "明亮模式", "SYSTEM_THEME": "跟随系统" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "隐藏频道列表", "SHOW_CHANNELS_LIST": "显示频道列表", diff --git a/apps/web/src/assets/i18n/zhtw.json b/apps/web/src/assets/i18n/zhtw.json index 747260097..d19ead863 100644 --- a/apps/web/src/assets/i18n/zhtw.json +++ b/apps/web/src/assets/i18n/zhtw.json @@ -360,35 +360,39 @@ "LIGHT_THEME": "亮色主題", "SYSTEM_THEME": "跟隨系統" }, - "PLAYBACK_DIAGNOSTICS": { - "UNSUPPORTED_CONTAINER": { - "TITLE": "This stream container is likely unsupported by the browser player", - "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." - }, - "UNSUPPORTED_CODEC": { - "TITLE": "This stream codec is likely unsupported by the browser player", - "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." - }, - "MEDIA_DECODE_ERROR": { - "TITLE": "The browser player could not decode this stream", - "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." - }, - "NETWORK_ERROR": { - "TITLE": "The stream could not be loaded", - "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." - }, - "DRM_OR_ENCRYPTION": { - "TITLE": "This stream may be encrypted or DRM-protected", - "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." - }, - "UNKNOWN_PLAYBACK_ERROR": { - "TITLE": "The browser player reported a playback error", - "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." - }, - "ACTION_OPEN_MPV": "Open in MPV", - "ACTION_OPEN_VLC": "Open in VLC", - "ACTION_COPY_URL": "Copy URL" + "PLAYBACK_DIAGNOSTICS": { + "UNSUPPORTED_CONTAINER": { + "TITLE": "This stream container is likely unsupported by the browser player", + "DESCRIPTION": "Chromium/Electron may not decode this container inline. Try MPV or VLC for broader codec support." }, + "UNSUPPORTED_CODEC": { + "TITLE": "This stream codec is likely unsupported by the browser player", + "DESCRIPTION": "The stream advertises codecs that the built-in Chromium player may not decode. MPV or VLC can often play it." + }, + "MEDIA_DECODE_ERROR": { + "TITLE": "The browser player could not decode this stream", + "DESCRIPTION": "Playback started but the media pipeline failed while decoding. An external player may handle this stream better." + }, + "NETWORK_ERROR": { + "TITLE": "The stream could not be loaded", + "DESCRIPTION": "The player reported a network or provider loading error. Check the stream URL, headers, or provider availability." + }, + "BROWSER_ACCESS_ERROR": { + "TITLE": "The browser player could not access this stream", + "DESCRIPTION": "The request may be blocked by CORS, mixed content, or provider header/proxy restrictions. MPV or VLC can often bypass browser-player access limits." + }, + "DRM_OR_ENCRYPTION": { + "TITLE": "This stream may be encrypted or DRM-protected", + "DESCRIPTION": "The browser player cannot continue with the reported encryption/key error. External playback may still fail if provider DRM is required." + }, + "UNKNOWN_PLAYBACK_ERROR": { + "TITLE": "The browser player reported a playback error", + "DESCRIPTION": "The stream failed in the built-in player, but the error did not identify a specific codec, container, or network cause." + }, + "ACTION_OPEN_MPV": "Open in MPV", + "ACTION_OPEN_VLC": "Open in VLC", + "ACTION_COPY_URL": "Copy URL" + }, "LAYOUT": { "HIDE_CHANNELS_LIST": "隱藏頻道列表", "SHOW_CHANNELS_LIST": "顯示頻道列表", diff --git a/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.spec.ts b/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.spec.ts index 423d49c75..cd3c281c4 100644 --- a/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.spec.ts +++ b/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.spec.ts @@ -89,6 +89,59 @@ describe('playback diagnostics', () => { expect(issue.externalFallbackRecommended).toBe(false); }); + it('classifies HLS browser access blocks separately from provider network failures', () => { + const issue = classifyHlsPlaybackIssue( + { + type: 'networkError', + details: + 'manifestLoadError Mixed Content: The page at https://app.example was loaded over HTTPS, but requested an insecure stream http://provider.example/live.m3u8. This request has been blocked.', + fatal: true, + }, + createPlaybackSourceMetadata({ + url: 'http://provider.example/live.m3u8', + player: 'videojs', + }) + ); + + expect(issue.code).toBe('browser-access-error'); + expect(issue.externalFallbackRecommended).toBe(true); + }); + + it('classifies native CORS failures as browser access errors', () => { + const issue = classifyNativePlaybackIssue( + { + code: 2, + message: + 'Access to media at https://provider.example/live.m3u8 from origin app://iptvnator has been blocked by CORS policy: No Access-Control-Allow-Origin header is present.', + }, + createPlaybackSourceMetadata({ + url: 'https://provider.example/live.m3u8', + player: 'html5', + }) + ); + + expect(issue.code).toBe('browser-access-error'); + expect(issue.externalFallbackRecommended).toBe(true); + }); + + it('classifies mpegts browser fetch restrictions separately from generic network errors', () => { + const issue = classifyMpegTsPlaybackIssue( + { + type: 'NetworkError', + details: + 'Fetch blocked by access-control policy while loading segment', + }, + createPlaybackSourceMetadata({ + url: 'https://provider.example/live/channel.ts', + mimeType: 'video/mp2t', + player: 'videojs', + }) + ); + + expect(issue.code).toBe('browser-access-error'); + expect(issue.externalFallbackRecommended).toBe(true); + }); + it('classifies mpegts codec errors as unsupported codec fallbacks', () => { const issue = classifyMpegTsPlaybackIssue( { diff --git a/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.ts b/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.ts index d30008a03..87580a8fc 100644 --- a/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.ts +++ b/libs/ui/playback/src/lib/playback-diagnostics/playback-diagnostics.util.ts @@ -1,11 +1,15 @@ import { getExtensionFromUrl } from 'm3u-utils'; -import type { ExternalPlayerName, ResolvedPortalPlayback } from 'shared-interfaces'; +import type { + ExternalPlayerName, + ResolvedPortalPlayback, +} from 'shared-interfaces'; export const PlaybackDiagnosticCode = { UnsupportedContainer: 'unsupported-container', UnsupportedCodec: 'unsupported-codec', MediaDecodeError: 'media-decode-error', NetworkError: 'network-error', + BrowserAccessError: 'browser-access-error', DrmOrEncryption: 'drm-or-encryption', UnknownPlaybackError: 'unknown-playback-error', } as const; @@ -147,10 +151,13 @@ export function classifyNativePlaybackIssue( ): PlaybackDiagnostic { const nativeErrorCode = error?.code; const nativeErrorMessage = error?.message || undefined; + const lowerNativeErrorMessage = nativeErrorMessage?.toLowerCase() ?? ''; if (nativeErrorCode === NETWORK_ERROR_CODE) { return createDiagnostic({ - code: PlaybackDiagnosticCode.NetworkError, + code: isBrowserAccessFailure(lowerNativeErrorMessage) + ? PlaybackDiagnosticCode.BrowserAccessError + : PlaybackDiagnosticCode.NetworkError, source: PlaybackDiagnosticSource.Native, metadata, nativeErrorCode, @@ -203,7 +210,9 @@ export function classifyHlsPlaybackIssue( if (isNetworkFailure(lowerType, lowerDetails)) { return createDiagnostic({ - code: PlaybackDiagnosticCode.NetworkError, + code: isBrowserAccessFailure(lowerDetails) + ? PlaybackDiagnosticCode.BrowserAccessError + : PlaybackDiagnosticCode.NetworkError, source: PlaybackDiagnosticSource.Hls, metadata: mergedMetadata, details, @@ -255,7 +264,9 @@ export function classifyMpegTsPlaybackIssue( if (isNetworkFailure(lowerType, lowerDetails)) { return createDiagnostic({ - code: PlaybackDiagnosticCode.NetworkError, + code: isBrowserAccessFailure(lowerDetails) + ? PlaybackDiagnosticCode.BrowserAccessError + : PlaybackDiagnosticCode.NetworkError, source: PlaybackDiagnosticSource.MpegTs, metadata, details, @@ -357,6 +368,7 @@ function isExternalFallbackRecommended(code: PlaybackDiagnosticCode): boolean { code === PlaybackDiagnosticCode.UnsupportedContainer || code === PlaybackDiagnosticCode.UnsupportedCodec || code === PlaybackDiagnosticCode.MediaDecodeError || + code === PlaybackDiagnosticCode.BrowserAccessError || code === PlaybackDiagnosticCode.DrmOrEncryption ); } @@ -481,6 +493,22 @@ function isNetworkFailure(type: string, details: string): boolean { ); } +function isBrowserAccessFailure(details: string): boolean { + return ( + details.includes('cors') || + details.includes('cross-origin') || + details.includes('cross origin') || + details.includes('access-control') || + details.includes('access control') || + details.includes('mixed content') || + details.includes('blocked by') || + details.includes('has been blocked') || + details.includes('not allowed to load local resource') || + details.includes('err_blocked') || + details.includes('err_cleartext') + ); +} + function isCodecFailure(details: string): boolean { return ( details.includes('codec') || diff --git a/libs/ui/playback/src/lib/web-player-view/web-player-view.component.spec.ts b/libs/ui/playback/src/lib/web-player-view/web-player-view.component.spec.ts index d37a4c1be..2a6d26213 100644 --- a/libs/ui/playback/src/lib/web-player-view/web-player-view.component.spec.ts +++ b/libs/ui/playback/src/lib/web-player-view/web-player-view.component.spec.ts @@ -187,6 +187,17 @@ describe('WebPlayerViewComponent', () => { }, ]); }); + + it('uses browser access diagnostic translation keys', () => { + const issue = createBrowserAccessDiagnostic(); + + expect(component.getDiagnosticTitleKey(issue)).toBe( + 'PLAYBACK_DIAGNOSTICS.BROWSER_ACCESS_ERROR.TITLE' + ); + expect(component.getDiagnosticDescriptionKey(issue)).toBe( + 'PLAYBACK_DIAGNOSTICS.BROWSER_ACCESS_ERROR.DESCRIPTION' + ); + }); }); function createUnsupportedContainerDiagnostic(): PlaybackDiagnostic { @@ -202,3 +213,18 @@ function createUnsupportedContainerDiagnostic(): PlaybackDiagnostic { externalFallbackRecommended: true, }; } + +function createBrowserAccessDiagnostic(): PlaybackDiagnostic { + return { + code: PlaybackDiagnosticCode.BrowserAccessError, + source: PlaybackDiagnosticSource.Hls, + sourceUrl: 'https://provider.example/live.m3u8', + container: 'm3u8', + mimeType: 'application/x-mpegURL', + player: 'videojs', + audioCodecs: [], + videoCodecs: [], + details: 'blocked by CORS policy', + externalFallbackRecommended: true, + }; +} diff --git a/libs/ui/playback/src/lib/web-player-view/web-player-view.component.ts b/libs/ui/playback/src/lib/web-player-view/web-player-view.component.ts index 45b4982c7..3beaf7557 100644 --- a/libs/ui/playback/src/lib/web-player-view/web-player-view.component.ts +++ b/libs/ui/playback/src/lib/web-player-view/web-player-view.component.ts @@ -181,6 +181,8 @@ export class WebPlayerViewComponent { return 'PLAYBACK_DIAGNOSTICS.MEDIA_DECODE_ERROR'; case PlaybackDiagnosticCode.NetworkError: return 'PLAYBACK_DIAGNOSTICS.NETWORK_ERROR'; + case PlaybackDiagnosticCode.BrowserAccessError: + return 'PLAYBACK_DIAGNOSTICS.BROWSER_ACCESS_ERROR'; case PlaybackDiagnosticCode.DrmOrEncryption: return 'PLAYBACK_DIAGNOSTICS.DRM_OR_ENCRYPTION'; case PlaybackDiagnosticCode.UnknownPlaybackError: