@npo/player 1.29.1 → 2.0.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +32 -24
- package/dist/logErrorEvent-DbEp9rzx.js +25 -0
- package/dist/logErrorEvent-DbEp9rzx.js.map +1 -0
- package/dist/main-XvJyWo8j.js +53061 -0
- package/dist/main-XvJyWo8j.js.map +1 -0
- package/dist/main.d.ts +1163 -0
- package/dist/npoplayer-audio.es.js +19 -0
- package/dist/npoplayer-audio.es.js.map +1 -0
- package/dist/npoplayer-audio.umd.js +53088 -0
- package/dist/npoplayer-audio.umd.js.map +1 -0
- package/package.json +72 -86
- package/CHANGELOG.md +0 -3
- package/LICENSE +0 -15
- package/lib/js/markers/updateLiveMarkers.d.ts +0 -9
- package/lib/js/markers/updateLiveMarkers.js +0 -56
- package/lib/js/markers/updateLiveMarkers.test.d.ts +0 -1
- package/lib/js/markers/updateLiveMarkers.test.js +0 -63
- package/lib/js/playeractions/handlers/handleoffsets.d.ts +0 -4
- package/lib/js/playeractions/handlers/handleoffsets.js +0 -58
- package/lib/js/playeractions/handlers/handleoffsets.test.d.ts +0 -1
- package/lib/js/playeractions/handlers/handleoffsets.test.js +0 -93
- package/lib/js/playeractions/handlers/mediasessionactions.d.ts +0 -7
- package/lib/js/playeractions/handlers/mediasessionactions.js +0 -123
- package/lib/js/playeractions/handlers/processplayerconfig.d.ts +0 -3
- package/lib/js/playeractions/handlers/processplayerconfig.js +0 -56
- package/lib/js/playeractions/handlers/processplayerconfig.test.d.ts +0 -1
- package/lib/js/playeractions/handlers/processplayerconfig.test.js +0 -116
- package/lib/js/playeractions/handlers/processsourceconfig.d.ts +0 -15
- package/lib/js/playeractions/handlers/processsourceconfig.js +0 -234
- package/lib/js/playeractions/handlers/processsourceconfig.test.d.ts +0 -1
- package/lib/js/playeractions/handlers/processsourceconfig.test.js +0 -25
- package/lib/js/playeractions/handlers/removereplayclass.d.ts +0 -2
- package/lib/js/playeractions/handlers/removereplayclass.js +0 -12
- package/lib/js/playeractions/handlers/removereplayclass.test.d.ts +0 -1
- package/lib/js/playeractions/handlers/removereplayclass.test.js +0 -33
- package/lib/js/playeractions/playeractions.d.ts +0 -3
- package/lib/js/playeractions/playeractions.js +0 -3
- package/lib/js/settings/localization.d.ts +0 -82
- package/lib/js/settings/localization.js +0 -7
- package/lib/js/settings/settings.user-agent.d.ts +0 -1
- package/lib/js/settings/settings.user-agent.js +0 -1
- package/lib/js/utilities/utilities.element.d.ts +0 -16
- package/lib/js/utilities/utilities.element.js +0 -18
- package/lib/js/utilities/utilities.element.test.d.ts +0 -1
- package/lib/js/utilities/utilities.element.test.js +0 -38
- package/lib/js/utilities/utilities.jwt.d.ts +0 -5
- package/lib/js/utilities/utilities.jwt.js +0 -44
- package/lib/js/utilities/utilities.jwt.test.d.ts +0 -1
- package/lib/js/utilities/utilities.jwt.test.js +0 -32
- package/lib/js/utilities/utilities.locale.d.ts +0 -2
- package/lib/js/utilities/utilities.locale.js +0 -4
- package/lib/js/utilities/utilities.locale.test.d.ts +0 -1
- package/lib/js/utilities/utilities.locale.test.js +0 -10
- package/lib/js/utilities/utilities.module.d.ts +0 -1
- package/lib/js/utilities/utilities.module.js +0 -4
- package/lib/js/utilities/utilities.module.test.d.ts +0 -1
- package/lib/js/utilities/utilities.module.test.js +0 -19
- package/lib/js/utilities/utilities.prid.d.ts +0 -6
- package/lib/js/utilities/utilities.prid.js +0 -8
- package/lib/js/utilities/utilities.prid.test.d.ts +0 -1
- package/lib/js/utilities/utilities.prid.test.js +0 -46
- package/lib/js/utilities/utilities.stream.d.ts +0 -7
- package/lib/js/utilities/utilities.stream.js +0 -19
- package/lib/js/utilities/utilities.stream.test.d.ts +0 -1
- package/lib/js/utilities/utilities.stream.test.js +0 -32
- package/lib/js/utilities/utilities.text.d.ts +0 -1
- package/lib/js/utilities/utilities.text.js +0 -3
- package/lib/js/utilities/utilities.text.test.d.ts +0 -1
- package/lib/js/utilities/utilities.text.test.js +0 -18
- package/lib/js/utilities/utilities.time.d.ts +0 -1
- package/lib/js/utilities/utilities.time.js +0 -3
- package/lib/js/utilities/utilities.time.test.d.ts +0 -1
- package/lib/js/utilities/utilities.time.test.js +0 -8
- package/lib/js/utilities/utilities.url.d.ts +0 -3
- package/lib/js/utilities/utilities.url.js +0 -29
- package/lib/js/utilities/utilities.url.test.d.ts +0 -1
- package/lib/js/utilities/utilities.url.test.js +0 -46
- package/lib/js/utilities/utilities.user-agent.d.ts +0 -3
- package/lib/js/utilities/utilities.user-agent.js +0 -13
- package/lib/js/utilities/utilities.user-agent.test.d.ts +0 -1
- package/lib/js/utilities/utilities.user-agent.test.js +0 -60
- package/lib/js/utilities/utilities.version.d.ts +0 -1
- package/lib/js/utilities/utilities.version.js +0 -26
- package/lib/js/utilities/utilities.version.test.d.ts +0 -1
- package/lib/js/utilities/utilities.version.test.js +0 -26
- package/lib/lang/nl.json +0 -77
- package/lib/lang/subtitleLabels/nl.json +0 -14
- package/lib/npoplayer.d.ts +0 -64
- package/lib/npoplayer.js +0 -428
- package/lib/npoplayer.test.d.ts +0 -1
- package/lib/npoplayer.test.js +0 -22
- package/lib/package.json +0 -105
- package/lib/services/a11y/setup.d.ts +0 -2
- package/lib/services/a11y/setup.js +0 -15
- package/lib/services/a11y/setup.test.d.ts +0 -1
- package/lib/services/a11y/setup.test.js +0 -88
- package/lib/services/advertHandlers/discardAdBreak.d.ts +0 -2
- package/lib/services/advertHandlers/discardAdBreak.js +0 -9
- package/lib/services/advertHandlers/discardAdBreak.test.d.ts +0 -1
- package/lib/services/advertHandlers/discardAdBreak.test.js +0 -40
- package/lib/services/advertHandlers/handlePreRolls.d.ts +0 -2
- package/lib/services/advertHandlers/handlePreRolls.js +0 -136
- package/lib/services/advertHandlers/handlePrerolls.test.d.ts +0 -1
- package/lib/services/advertHandlers/handlePrerolls.test.js +0 -112
- package/lib/services/avTypeHandlers/getAVType.d.ts +0 -2
- package/lib/services/avTypeHandlers/getAVType.js +0 -9
- package/lib/services/avTypeHandlers/getAVType.test.d.ts +0 -1
- package/lib/services/avTypeHandlers/getAVType.test.js +0 -18
- package/lib/services/backButton/backButton.d.ts +0 -2
- package/lib/services/backButton/backButton.js +0 -24
- package/lib/services/cdnProviders/cdnProviders.d.ts +0 -4
- package/lib/services/cdnProviders/cdnProviders.js +0 -24
- package/lib/services/cdnProviders/cndProviders.test.d.ts +0 -1
- package/lib/services/cdnProviders/cndProviders.test.js +0 -22
- package/lib/services/chapterHandlers/chapterHandler.d.ts +0 -35
- package/lib/services/chapterHandlers/chapterHandler.js +0 -230
- package/lib/services/drmHandlers/constants.d.ts +0 -15
- package/lib/services/drmHandlers/constants.js +0 -13
- package/lib/services/drmHandlers/decideprofile.d.ts +0 -2
- package/lib/services/drmHandlers/decideprofile.js +0 -57
- package/lib/services/drmHandlers/decideprofile.test.d.ts +0 -1
- package/lib/services/drmHandlers/decideprofile.test.js +0 -38
- package/lib/services/drmHandlers/drmhandlers.d.ts +0 -2
- package/lib/services/drmHandlers/drmhandlers.js +0 -2
- package/lib/services/drmHandlers/utils.d.ts +0 -5
- package/lib/services/drmHandlers/utils.js +0 -29
- package/lib/services/drmHandlers/utils.test.d.ts +0 -1
- package/lib/services/drmHandlers/utils.test.js +0 -81
- package/lib/services/drmHandlers/verifydrm.d.ts +0 -2
- package/lib/services/drmHandlers/verifydrm.js +0 -39
- package/lib/services/drmHandlers/verifydrm.test.d.ts +0 -1
- package/lib/services/drmHandlers/verifydrm.test.js +0 -112
- package/lib/services/errors/errorBackground.test.d.ts +0 -1
- package/lib/services/errors/errorBackground.test.js +0 -48
- package/lib/services/errors/errorHandler.d.ts +0 -5
- package/lib/services/errors/errorHandler.js +0 -59
- package/lib/services/errors/errorHandler.test.d.ts +0 -1
- package/lib/services/errors/errorHandler.test.js +0 -148
- package/lib/services/errors/errorRetryHandler.d.ts +0 -2
- package/lib/services/errors/errorRetryHandler.js +0 -14
- package/lib/services/errors/errorRetryHandler.test.d.ts +0 -1
- package/lib/services/errors/errorRetryHandler.test.js +0 -62
- package/lib/services/errors/errorText.d.ts +0 -2
- package/lib/services/errors/errorText.js +0 -62
- package/lib/services/errors/errorText.test.d.ts +0 -1
- package/lib/services/errors/errorText.test.js +0 -66
- package/lib/services/eventListenerHandlers/removeEventListeners.d.ts +0 -2
- package/lib/services/eventListenerHandlers/removeEventListeners.js +0 -24
- package/lib/services/eventListenerHandlers/removeEventListeners.test.d.ts +0 -1
- package/lib/services/eventListenerHandlers/removeEventListeners.test.js +0 -36
- package/lib/services/infoPanel/infoPanel.d.ts +0 -3
- package/lib/services/infoPanel/infoPanel.js +0 -35
- package/lib/services/infoPanel/infoPanel.test.d.ts +0 -1
- package/lib/services/infoPanel/infoPanel.test.js +0 -70
- package/lib/services/keyboardHandlers/resolvekeypress.d.ts +0 -2
- package/lib/services/keyboardHandlers/resolvekeypress.js +0 -63
- package/lib/services/keyboardHandlers/resolvekeypress.test.d.ts +0 -1
- package/lib/services/keyboardHandlers/resolvekeypress.test.js +0 -92
- package/lib/services/liveStreamHandlers/handleLiveStreamControls.d.ts +0 -6
- package/lib/services/liveStreamHandlers/handleLiveStreamControls.js +0 -36
- package/lib/services/liveStreamHandlers/handleLiveStreamControls.test.d.ts +0 -2
- package/lib/services/liveStreamHandlers/handleLiveStreamControls.test.js +0 -65
- package/lib/services/localStorageHandlers/localStorageHandlers.d.ts +0 -4
- package/lib/services/localStorageHandlers/localStorageHandlers.js +0 -36
- package/lib/services/localStorageHandlers/localStorageHandlers.test.d.ts +0 -1
- package/lib/services/localStorageHandlers/localStorageHandlers.test.js +0 -104
- package/lib/services/nicamHandlers/nicamhandler.d.ts +0 -6
- package/lib/services/nicamHandlers/nicamhandler.js +0 -69
- package/lib/services/nicamHandlers/nicamhandler.test.d.ts +0 -1
- package/lib/services/nicamHandlers/nicamhandler.test.js +0 -127
- package/lib/services/npoPlayerAPI/contants.d.ts +0 -25
- package/lib/services/npoPlayerAPI/contants.js +0 -11
- package/lib/services/npoPlayerAPI/npoPlayerAPI.d.ts +0 -53
- package/lib/services/npoPlayerAPI/npoPlayerAPI.js +0 -193
- package/lib/services/npoPlayerAPI/npoPlayerAPI.test.d.ts +0 -1
- package/lib/services/npoPlayerAPI/npoPlayerAPI.test.js +0 -127
- package/lib/services/npoPlayerAPI/playerModules.d.ts +0 -1
- package/lib/services/npoPlayerAPI/playerModules.js +0 -48
- package/lib/services/preferences/handlePreferences.d.ts +0 -2
- package/lib/services/preferences/handlePreferences.js +0 -47
- package/lib/services/preferences/handlePreferences.test.d.ts +0 -1
- package/lib/services/preferences/handlePreferences.test.js +0 -138
- package/lib/services/segmentHandlers/addSegmentEventListeners.d.ts +0 -2
- package/lib/services/segmentHandlers/addSegmentEventListeners.js +0 -15
- package/lib/services/segmentHandlers/addSegmentEventListeners.test.d.ts +0 -1
- package/lib/services/segmentHandlers/addSegmentEventListeners.test.js +0 -44
- package/lib/services/segmentHandlers/convertFragmentToSegment.d.ts +0 -2
- package/lib/services/segmentHandlers/convertFragmentToSegment.js +0 -8
- package/lib/services/segmentHandlers/convertFragmentToSegment.test.d.ts +0 -1
- package/lib/services/segmentHandlers/convertFragmentToSegment.test.js +0 -17
- package/lib/services/segmentHandlers/handleSegmentSeek.d.ts +0 -5
- package/lib/services/segmentHandlers/handleSegmentSeek.js +0 -15
- package/lib/services/segmentHandlers/handleSegmentSeek.test.d.ts +0 -1
- package/lib/services/segmentHandlers/handleSegmentSeek.test.js +0 -73
- package/lib/services/segmentHandlers/handleSegmentTimeChanged.d.ts +0 -2
- package/lib/services/segmentHandlers/handleSegmentTimeChanged.js +0 -21
- package/lib/services/segmentHandlers/handleSegmentTimeChanged.test.d.ts +0 -1
- package/lib/services/segmentHandlers/handleSegmentTimeChanged.test.js +0 -43
- package/lib/services/segmentHandlers/initSegment.d.ts +0 -7
- package/lib/services/segmentHandlers/initSegment.js +0 -10
- package/lib/services/segmentHandlers/initSegment.test.d.ts +0 -1
- package/lib/services/segmentHandlers/initSegment.test.js +0 -38
- package/lib/services/segmentHandlers/isSegmentInBounds.d.ts +0 -2
- package/lib/services/segmentHandlers/isSegmentInBounds.js +0 -5
- package/lib/services/segmentHandlers/isSegmentInBounds.test.d.ts +0 -1
- package/lib/services/segmentHandlers/isSegmentInBounds.test.js +0 -27
- package/lib/services/segmentHandlers/setSegmentMarkers.d.ts +0 -2
- package/lib/services/segmentHandlers/setSegmentMarkers.js +0 -25
- package/lib/services/segmentHandlers/setSegmentMarkers.test.d.ts +0 -1
- package/lib/services/segmentHandlers/setSegmentMarkers.test.js +0 -32
- package/lib/services/services.d.ts +0 -34
- package/lib/services/services.js +0 -129
- package/lib/services/streamFetchHandler/fetchStream.d.ts +0 -2
- package/lib/services/streamFetchHandler/fetchStream.js +0 -49
- package/lib/services/streamFetchHandler/fetchstream.test.d.ts +0 -1
- package/lib/services/streamFetchHandler/fetchstream.test.js +0 -92
- package/lib/services/streamoptionsHandlers/streamOptionsHandler.d.ts +0 -6
- package/lib/services/streamoptionsHandlers/streamOptionsHandler.js +0 -80
- package/lib/services/streamoptionsHandlers/streamOptionsHandler.test.d.ts +0 -1
- package/lib/services/streamoptionsHandlers/streamOptionsHandler.test.js +0 -199
- package/lib/services/trackingHandlers/eventBinding.d.ts +0 -2
- package/lib/services/trackingHandlers/eventBinding.js +0 -129
- package/lib/services/trackingHandlers/eventBinding.test.d.ts +0 -1
- package/lib/services/trackingHandlers/eventBinding.test.js +0 -145
- package/lib/services/trackingHandlers/eventLogging.d.ts +0 -2
- package/lib/services/trackingHandlers/eventLogging.js +0 -37
- package/lib/services/trackingHandlers/eventLogging.test.d.ts +0 -1
- package/lib/services/trackingHandlers/eventLogging.test.js +0 -63
- package/lib/services/trackingHandlers/index.d.ts +0 -3
- package/lib/services/trackingHandlers/index.js +0 -3
- package/lib/services/trackingHandlers/playerTrackerInit.d.ts +0 -2
- package/lib/services/trackingHandlers/playerTrackerInit.js +0 -20
- package/lib/services/trackingHandlers/playerTrackerInit.test.d.ts +0 -1
- package/lib/services/trackingHandlers/playerTrackerInit.test.js +0 -75
- package/lib/services/trackingHandlers/playerTrackerStart.d.ts +0 -2
- package/lib/services/trackingHandlers/playerTrackerStart.js +0 -28
- package/lib/services/trackingHandlers/playerTrackerStart.test.d.ts +0 -1
- package/lib/services/trackingHandlers/playerTrackerStart.test.js +0 -76
- package/lib/services/trackingHandlers/streamTrackerInit.d.ts +0 -3
- package/lib/services/trackingHandlers/streamTrackerInit.js +0 -27
- package/lib/services/trackingHandlers/streamTrackerInit.test.d.ts +0 -1
- package/lib/services/trackingHandlers/streamTrackerInit.test.js +0 -84
- package/lib/services/uiHandlers/uiVisiblityHandler.d.ts +0 -3
- package/lib/services/uiHandlers/uiVisiblityHandler.js +0 -32
- package/lib/services/uiHandlers/uiVisiblityHandler.test.d.ts +0 -1
- package/lib/services/uiHandlers/uiVisiblityHandler.test.js +0 -62
- package/lib/services/verticalVideoHandlers/handleVerticalVideoControls.d.ts +0 -2
- package/lib/services/verticalVideoHandlers/handleVerticalVideoControls.js +0 -6
- package/lib/services/verticalVideoHandlers/handleVerticalVideoControls.test.d.ts +0 -1
- package/lib/services/verticalVideoHandlers/handleVerticalVideoControls.test.js +0 -23
- package/lib/services/verticalVideoHandlers/handleVerticalVideoSettings.d.ts +0 -2
- package/lib/services/verticalVideoHandlers/handleVerticalVideoSettings.js +0 -26
- package/lib/services/verticalVideoHandlers/handleVerticalVideoSettings.test.d.ts +0 -1
- package/lib/services/verticalVideoHandlers/handleVerticalVideoSettings.test.js +0 -73
- package/lib/src/js/markers/updateLiveMarkers.d.ts +0 -9
- package/lib/src/js/markers/updateLiveMarkers.test.d.ts +0 -1
- package/lib/src/js/playeractions/handlers/handleoffsets.d.ts +0 -4
- package/lib/src/js/playeractions/handlers/handleoffsets.test.d.ts +0 -1
- package/lib/src/js/playeractions/handlers/mediasessionactions.d.ts +0 -7
- package/lib/src/js/playeractions/handlers/processplayerconfig.d.ts +0 -3
- package/lib/src/js/playeractions/handlers/processplayerconfig.test.d.ts +0 -1
- package/lib/src/js/playeractions/handlers/processsourceconfig.d.ts +0 -15
- package/lib/src/js/playeractions/handlers/processsourceconfig.test.d.ts +0 -1
- package/lib/src/js/playeractions/handlers/removereplayclass.d.ts +0 -2
- package/lib/src/js/playeractions/handlers/removereplayclass.test.d.ts +0 -1
- package/lib/src/js/playeractions/playeractions.d.ts +0 -3
- package/lib/src/js/settings/localization.d.ts +0 -82
- package/lib/src/js/settings/settings.user-agent.d.ts +0 -1
- package/lib/src/js/utilities/utilities.element.d.ts +0 -16
- package/lib/src/js/utilities/utilities.element.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.jwt.d.ts +0 -5
- package/lib/src/js/utilities/utilities.jwt.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.locale.d.ts +0 -2
- package/lib/src/js/utilities/utilities.locale.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.module.d.ts +0 -1
- package/lib/src/js/utilities/utilities.module.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.prid.d.ts +0 -6
- package/lib/src/js/utilities/utilities.prid.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.stream.d.ts +0 -7
- package/lib/src/js/utilities/utilities.stream.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.text.d.ts +0 -1
- package/lib/src/js/utilities/utilities.text.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.time.d.ts +0 -1
- package/lib/src/js/utilities/utilities.time.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.url.d.ts +0 -3
- package/lib/src/js/utilities/utilities.url.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.user-agent.d.ts +0 -3
- package/lib/src/js/utilities/utilities.user-agent.test.d.ts +0 -1
- package/lib/src/js/utilities/utilities.version.d.ts +0 -1
- package/lib/src/js/utilities/utilities.version.test.d.ts +0 -1
- package/lib/src/npoplayer.d.ts +0 -64
- package/lib/src/npoplayer.test.d.ts +0 -1
- package/lib/src/services/a11y/setup.d.ts +0 -2
- package/lib/src/services/a11y/setup.test.d.ts +0 -1
- package/lib/src/services/advertHandlers/discardAdBreak.d.ts +0 -2
- package/lib/src/services/advertHandlers/discardAdBreak.test.d.ts +0 -1
- package/lib/src/services/advertHandlers/handlePreRolls.d.ts +0 -2
- package/lib/src/services/advertHandlers/handlePrerolls.test.d.ts +0 -1
- package/lib/src/services/avTypeHandlers/getAVType.d.ts +0 -2
- package/lib/src/services/avTypeHandlers/getAVType.test.d.ts +0 -1
- package/lib/src/services/backButton/backButton.d.ts +0 -2
- package/lib/src/services/cdnProviders/cdnProviders.d.ts +0 -4
- package/lib/src/services/cdnProviders/cndProviders.test.d.ts +0 -1
- package/lib/src/services/chapterHandlers/chapterHandler.d.ts +0 -35
- package/lib/src/services/drmHandlers/constants.d.ts +0 -15
- package/lib/src/services/drmHandlers/decideprofile.d.ts +0 -2
- package/lib/src/services/drmHandlers/decideprofile.test.d.ts +0 -1
- package/lib/src/services/drmHandlers/drmhandlers.d.ts +0 -2
- package/lib/src/services/drmHandlers/utils.d.ts +0 -5
- package/lib/src/services/drmHandlers/utils.test.d.ts +0 -1
- package/lib/src/services/drmHandlers/verifydrm.d.ts +0 -2
- package/lib/src/services/drmHandlers/verifydrm.test.d.ts +0 -1
- package/lib/src/services/errors/errorBackground.test.d.ts +0 -1
- package/lib/src/services/errors/errorHandler.d.ts +0 -5
- package/lib/src/services/errors/errorHandler.test.d.ts +0 -1
- package/lib/src/services/errors/errorRetryHandler.d.ts +0 -2
- package/lib/src/services/errors/errorRetryHandler.test.d.ts +0 -1
- package/lib/src/services/errors/errorText.d.ts +0 -2
- package/lib/src/services/errors/errorText.test.d.ts +0 -1
- package/lib/src/services/eventListenerHandlers/removeEventListeners.d.ts +0 -2
- package/lib/src/services/eventListenerHandlers/removeEventListeners.test.d.ts +0 -1
- package/lib/src/services/infoPanel/infoPanel.d.ts +0 -3
- package/lib/src/services/infoPanel/infoPanel.test.d.ts +0 -1
- package/lib/src/services/keyboardHandlers/resolvekeypress.d.ts +0 -2
- package/lib/src/services/keyboardHandlers/resolvekeypress.test.d.ts +0 -1
- package/lib/src/services/liveStreamHandlers/handleLiveStreamControls.d.ts +0 -6
- package/lib/src/services/liveStreamHandlers/handleLiveStreamControls.test.d.ts +0 -2
- package/lib/src/services/localStorageHandlers/localStorageHandlers.d.ts +0 -4
- package/lib/src/services/localStorageHandlers/localStorageHandlers.test.d.ts +0 -1
- package/lib/src/services/nicamHandlers/nicamhandler.d.ts +0 -6
- package/lib/src/services/nicamHandlers/nicamhandler.test.d.ts +0 -1
- package/lib/src/services/npoPlayerAPI/contants.d.ts +0 -25
- package/lib/src/services/npoPlayerAPI/npoPlayerAPI.d.ts +0 -53
- package/lib/src/services/npoPlayerAPI/npoPlayerAPI.test.d.ts +0 -1
- package/lib/src/services/npoPlayerAPI/playerModules.d.ts +0 -1
- package/lib/src/services/preferences/handlePreferences.d.ts +0 -2
- package/lib/src/services/preferences/handlePreferences.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/addSegmentEventListeners.d.ts +0 -2
- package/lib/src/services/segmentHandlers/addSegmentEventListeners.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/convertFragmentToSegment.d.ts +0 -2
- package/lib/src/services/segmentHandlers/convertFragmentToSegment.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/handleSegmentSeek.d.ts +0 -5
- package/lib/src/services/segmentHandlers/handleSegmentSeek.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/handleSegmentTimeChanged.d.ts +0 -2
- package/lib/src/services/segmentHandlers/handleSegmentTimeChanged.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/initSegment.d.ts +0 -7
- package/lib/src/services/segmentHandlers/initSegment.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/isSegmentInBounds.d.ts +0 -2
- package/lib/src/services/segmentHandlers/isSegmentInBounds.test.d.ts +0 -1
- package/lib/src/services/segmentHandlers/setSegmentMarkers.d.ts +0 -2
- package/lib/src/services/segmentHandlers/setSegmentMarkers.test.d.ts +0 -1
- package/lib/src/services/services.d.ts +0 -34
- package/lib/src/services/streamFetchHandler/fetchStream.d.ts +0 -2
- package/lib/src/services/streamFetchHandler/fetchstream.test.d.ts +0 -1
- package/lib/src/services/streamoptionsHandlers/streamOptionsHandler.d.ts +0 -6
- package/lib/src/services/streamoptionsHandlers/streamOptionsHandler.test.d.ts +0 -1
- package/lib/src/services/trackingHandlers/eventBinding.d.ts +0 -2
- package/lib/src/services/trackingHandlers/eventBinding.test.d.ts +0 -1
- package/lib/src/services/trackingHandlers/eventLogging.d.ts +0 -2
- package/lib/src/services/trackingHandlers/eventLogging.test.d.ts +0 -1
- package/lib/src/services/trackingHandlers/index.d.ts +0 -3
- package/lib/src/services/trackingHandlers/playerTrackerInit.d.ts +0 -2
- package/lib/src/services/trackingHandlers/playerTrackerInit.test.d.ts +0 -1
- package/lib/src/services/trackingHandlers/playerTrackerStart.d.ts +0 -2
- package/lib/src/services/trackingHandlers/playerTrackerStart.test.d.ts +0 -1
- package/lib/src/services/trackingHandlers/streamTrackerInit.d.ts +0 -3
- package/lib/src/services/trackingHandlers/streamTrackerInit.test.d.ts +0 -1
- package/lib/src/services/uiHandlers/uiVisiblityHandler.d.ts +0 -3
- package/lib/src/services/uiHandlers/uiVisiblityHandler.test.d.ts +0 -1
- package/lib/src/services/verticalVideoHandlers/handleVerticalVideoControls.d.ts +0 -2
- package/lib/src/services/verticalVideoHandlers/handleVerticalVideoControls.test.d.ts +0 -1
- package/lib/src/services/verticalVideoHandlers/handleVerticalVideoSettings.d.ts +0 -2
- package/lib/src/services/verticalVideoHandlers/handleVerticalVideoSettings.test.d.ts +0 -1
- package/lib/src/types/classes.d.ts +0 -10
- package/lib/src/types/events.d.ts +0 -98
- package/lib/src/types/interfaces.d.ts +0 -246
- package/lib/src/ui/components/adbutton.d.ts +0 -4
- package/lib/src/ui/components/adlabel.d.ts +0 -4
- package/lib/src/ui/components/audio/controlbar.d.ts +0 -3
- package/lib/src/ui/components/backButton.d.ts +0 -2
- package/lib/src/ui/components/buttons.d.ts +0 -42
- package/lib/src/ui/components/controlbar.d.ts +0 -3
- package/lib/src/ui/components/ctabar.d.ts +0 -4
- package/lib/src/ui/components/infopanel/infopanel.d.ts +0 -3
- package/lib/src/ui/components/infopanel/togglebutton.d.ts +0 -3
- package/lib/src/ui/components/playnext.d.ts +0 -4
- package/lib/src/ui/components/seekbar.d.ts +0 -6
- package/lib/src/ui/components/settingspanel.d.ts +0 -3
- package/lib/src/ui/components/titlebar.d.ts +0 -3
- package/lib/src/ui/components/topbar.d.ts +0 -3
- package/lib/src/ui/components/verticalvideo/controlbar.d.ts +0 -3
- package/lib/src/ui/components/verticalvideo/settingspanel.d.ts +0 -2
- package/lib/src/ui/handlers/accessibilityhandler.d.ts +0 -2
- package/lib/src/ui/handlers/accessibilityhandler.test.d.ts +0 -1
- package/lib/src/ui/handlers/domhandlers.d.ts +0 -3
- package/lib/src/ui/handlers/domhandlers.test.d.ts +0 -1
- package/lib/src/ui/handlers/listboxhandlers.d.ts +0 -19
- package/lib/src/ui/handlers/playnextscreen.d.ts +0 -6
- package/lib/src/ui/handlers/playnextscreen.test.d.ts +0 -1
- package/lib/src/ui/handlers/timecontrolhandlers.d.ts +0 -3
- package/lib/src/ui/uicontainer.d.ts +0 -3
- package/lib/src/ui/uicontainer.test.d.ts +0 -1
- package/lib/tests/jest.setup-files-after-env.d.ts +0 -0
- package/lib/tests/jest.setup-files-after-env.js +0 -6
- package/lib/tests/jest.setup-tests.d.ts +0 -1
- package/lib/tests/jest.setup-tests.js +0 -2
- package/lib/tests/mocks/mockLogEmitter.d.ts +0 -2
- package/lib/tests/mocks/mockLogEmitter.js +0 -20
- package/lib/tests/mocks/mockNpoplayer.d.ts +0 -2
- package/lib/tests/mocks/mockNpoplayer.js +0 -105
- package/lib/tests/mocks/mockPlayerAPI.d.ts +0 -3
- package/lib/tests/mocks/mockPlayerAPI.js +0 -195
- package/lib/tests/mocks/mockPlayerUi.d.ts +0 -64
- package/lib/tests/mocks/mockPlayerUi.js +0 -251
- package/lib/tests/mocks/mockStreamObject.d.ts +0 -2
- package/lib/tests/mocks/mockStreamObject.js +0 -21
- package/lib/tests/mocks/playerContextMock.d.ts +0 -7
- package/lib/tests/mocks/playerContextMock.js +0 -153
- package/lib/types/classes.d.ts +0 -10
- package/lib/types/classes.js +0 -15
- package/lib/types/events.d.ts +0 -98
- package/lib/types/events.js +0 -184
- package/lib/types/interfaces.d.ts +0 -246
- package/lib/types/interfaces.js +0 -20
- package/lib/ui/components/adbutton.d.ts +0 -4
- package/lib/ui/components/adbutton.js +0 -12
- package/lib/ui/components/adlabel.d.ts +0 -4
- package/lib/ui/components/adlabel.js +0 -8
- package/lib/ui/components/audio/controlbar.d.ts +0 -3
- package/lib/ui/components/audio/controlbar.js +0 -23
- package/lib/ui/components/backButton.d.ts +0 -2
- package/lib/ui/components/backButton.js +0 -8
- package/lib/ui/components/buttons.d.ts +0 -42
- package/lib/ui/components/buttons.js +0 -144
- package/lib/ui/components/controlbar.d.ts +0 -3
- package/lib/ui/components/controlbar.js +0 -40
- package/lib/ui/components/ctabar.d.ts +0 -4
- package/lib/ui/components/ctabar.js +0 -28
- package/lib/ui/components/infopanel/infopanel.d.ts +0 -3
- package/lib/ui/components/infopanel/infopanel.js +0 -42
- package/lib/ui/components/infopanel/togglebutton.d.ts +0 -3
- package/lib/ui/components/infopanel/togglebutton.js +0 -18
- package/lib/ui/components/playnext.d.ts +0 -4
- package/lib/ui/components/playnext.js +0 -10
- package/lib/ui/components/seekbar.d.ts +0 -6
- package/lib/ui/components/seekbar.js +0 -26
- package/lib/ui/components/settingspanel.d.ts +0 -3
- package/lib/ui/components/settingspanel.js +0 -159
- package/lib/ui/components/titlebar.d.ts +0 -3
- package/lib/ui/components/titlebar.js +0 -14
- package/lib/ui/components/topbar.d.ts +0 -3
- package/lib/ui/components/topbar.js +0 -36
- package/lib/ui/components/verticalvideo/controlbar.d.ts +0 -3
- package/lib/ui/components/verticalvideo/controlbar.js +0 -40
- package/lib/ui/components/verticalvideo/settingspanel.d.ts +0 -2
- package/lib/ui/components/verticalvideo/settingspanel.js +0 -25
- package/lib/ui/handlers/accessibilityhandler.d.ts +0 -2
- package/lib/ui/handlers/accessibilityhandler.js +0 -22
- package/lib/ui/handlers/accessibilityhandler.test.d.ts +0 -1
- package/lib/ui/handlers/accessibilityhandler.test.js +0 -54
- package/lib/ui/handlers/domhandlers.d.ts +0 -3
- package/lib/ui/handlers/domhandlers.js +0 -7
- package/lib/ui/handlers/domhandlers.test.d.ts +0 -1
- package/lib/ui/handlers/domhandlers.test.js +0 -31
- package/lib/ui/handlers/listboxhandlers.d.ts +0 -19
- package/lib/ui/handlers/listboxhandlers.js +0 -43
- package/lib/ui/handlers/playnextscreen.d.ts +0 -6
- package/lib/ui/handlers/playnextscreen.js +0 -28
- package/lib/ui/handlers/playnextscreen.test.d.ts +0 -1
- package/lib/ui/handlers/playnextscreen.test.js +0 -57
- package/lib/ui/handlers/timecontrolhandlers.d.ts +0 -3
- package/lib/ui/handlers/timecontrolhandlers.js +0 -17
- package/lib/ui/uicontainer.d.ts +0 -3
- package/lib/ui/uicontainer.js +0 -80
- package/lib/ui/uicontainer.test.d.ts +0 -1
- package/lib/ui/uicontainer.test.js +0 -84
- package/src/style/components/_advert.scss +0 -119
- package/src/style/components/_audio.scss +0 -4
- package/src/style/components/_back-button.scss +0 -42
- package/src/style/components/_buffering.scss +0 -69
- package/src/style/components/_controlbars.scss +0 -26
- package/src/style/components/_error.scss +0 -71
- package/src/style/components/_hugeplaybacktogglebutton.scss +0 -97
- package/src/style/components/_icons.scss +0 -177
- package/src/style/components/_infopanel.scss +0 -105
- package/src/style/components/_metadata.scss +0 -52
- package/src/style/components/_nicam.scss +0 -117
- package/src/style/components/_playnext.scss +0 -72
- package/src/style/components/_poster.scss +0 -3
- package/src/style/components/_replay.scss +0 -25
- package/src/style/components/_seekbar.scss +0 -114
- package/src/style/components/_seekbarthumbnail.scss +0 -61
- package/src/style/components/_settingspanel.scss +0 -290
- package/src/style/components/_subtitles.scss +0 -78
- package/src/style/components/_textbuttons.scss +0 -82
- package/src/style/components/_volumeslider.scss +0 -94
- package/src/style/components/audio/_bottombar.scss +0 -54
- package/src/style/components/audio/_buffering.scss +0 -8
- package/src/style/components/audio/_errors.scss +0 -13
- package/src/style/components/audio/_metadata.scss +0 -60
- package/src/style/components/audio/_playbutton.scss +0 -54
- package/src/style/components/audio/_poster.scss +0 -19
- package/src/style/components/audio/_replay.scss +0 -28
- package/src/style/components/audio/_seekbar.scss +0 -28
- package/src/style/components/audio/_topbar.scss +0 -35
- package/src/style/components/audio/_vars.scss +0 -5
- package/src/style/components/audio/_volumeslider.scss +0 -41
- package/src/style/components/vertical-video/_bottombar.scss +0 -60
- package/src/style/components/vertical-video/_buttons.scss +0 -25
- package/src/style/components/vertical-video/_hugeplaybacktogglebutton.scss +0 -34
- package/src/style/components/vertical-video/_seekbar.scss +0 -19
- package/src/style/components/vertical-video/_settingsbutton.scss +0 -7
- package/src/style/components/vertical-video/_settingspanel.scss +0 -31
- package/src/style/components/vertical-video/_shortvideo.scss +0 -14
- package/src/style/components/vertical-video/_subtitles.scss +0 -3
- package/src/style/components/vertical-video/_topbar.scss +0 -58
- package/src/style/components/vertical-video/_volumeslider.scss +0 -9
- package/src/style/npoplayer.css +0 -908
- package/src/style/npoplayer.scss +0 -58
- package/src/style/variants/_player-audio-only.scss +0 -32
- package/src/style/variants/_player-audio.scss +0 -55
- package/src/style/variants/_player-base.scss +0 -101
- package/src/style/variants/_player-debug.scss +0 -14
- package/src/style/variants/_player-large.scss +0 -99
- package/src/style/variants/_player-medium.scss +0 -68
- package/src/style/variants/_player-small.scss +0 -203
- package/src/style/variants/_player-vertical.scss +0 -23
- package/src/style/vars/_audio.scss +0 -5
- package/src/style/vars/_colors.scss +0 -25
- package/src/style/vars/_fonts.scss +0 -26
- package/src/style/vars/_icons.scss +0 -29
- package/src/style/vars/_z-index.scss +0 -1
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { getElementByQuery, updateClassFromElementByQuery } from './utilities.element';
|
|
2
|
-
const CLASS = 'element-class';
|
|
3
|
-
const NEW_CLASS = 'new-class';
|
|
4
|
-
const ID = 'element-id';
|
|
5
|
-
const PARENT_ELEMENT = document.createElement('div');
|
|
6
|
-
const CHILD_ELEMENT_WITH_ID = document.createElement('div');
|
|
7
|
-
const CHILD_ELEMENT_WITH_CLASS = document.createElement('div');
|
|
8
|
-
CHILD_ELEMENT_WITH_ID.setAttribute('id', ID);
|
|
9
|
-
CHILD_ELEMENT_WITH_CLASS.setAttribute('class', CLASS);
|
|
10
|
-
PARENT_ELEMENT.appendChild(CHILD_ELEMENT_WITH_ID);
|
|
11
|
-
PARENT_ELEMENT.appendChild(CHILD_ELEMENT_WITH_CLASS);
|
|
12
|
-
describe('getElementByQuery', () => {
|
|
13
|
-
it('should return the child element', () => {
|
|
14
|
-
expect(getElementByQuery({ container: PARENT_ELEMENT, query: `#${ID}` })).toEqual(CHILD_ELEMENT_WITH_ID);
|
|
15
|
-
});
|
|
16
|
-
});
|
|
17
|
-
describe('updateClassFromElementByQuery', () => {
|
|
18
|
-
it('should remove the specified class from the queried element', () => {
|
|
19
|
-
updateClassFromElementByQuery({
|
|
20
|
-
container: PARENT_ELEMENT,
|
|
21
|
-
query: `.${CLASS}`,
|
|
22
|
-
className: CLASS,
|
|
23
|
-
condition: false
|
|
24
|
-
});
|
|
25
|
-
expect(PARENT_ELEMENT.querySelector(`.${CLASS}`)).toBeNull();
|
|
26
|
-
});
|
|
27
|
-
it('should add the specified class to the queried element', () => {
|
|
28
|
-
const ELEMENT_WITHOUT_CLASS = document.createElement('div');
|
|
29
|
-
PARENT_ELEMENT.appendChild(ELEMENT_WITHOUT_CLASS);
|
|
30
|
-
updateClassFromElementByQuery({
|
|
31
|
-
container: PARENT_ELEMENT,
|
|
32
|
-
query: 'div:not([class])',
|
|
33
|
-
className: NEW_CLASS,
|
|
34
|
-
condition: true
|
|
35
|
-
});
|
|
36
|
-
expect(PARENT_ELEMENT.querySelector(`.${NEW_CLASS}`)).not.toBeNull();
|
|
37
|
-
});
|
|
38
|
-
});
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export declare const convertBase64ToObject: (value: string) => Record<string, any>;
|
|
2
|
-
export declare const convertJwtToBase64: (jwt: string) => string;
|
|
3
|
-
export declare function isJWTToken(token: string): boolean;
|
|
4
|
-
export declare function getJwtIat(jwt: string): number;
|
|
5
|
-
export declare function isJwtFresh(jwt: string, maxAgeSeconds?: number): boolean;
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
export const convertBase64ToObject = (value) => {
|
|
2
|
-
try {
|
|
3
|
-
const decodedValue = [...window.atob(value)];
|
|
4
|
-
const mappedValue = decodedValue.map((c) => {
|
|
5
|
-
const codePoint = c.codePointAt(0);
|
|
6
|
-
if (codePoint === undefined)
|
|
7
|
-
return;
|
|
8
|
-
return '%' + ('00' + codePoint.toString(16)).slice(-2);
|
|
9
|
-
});
|
|
10
|
-
return JSON.parse(decodeURIComponent(mappedValue.join('')));
|
|
11
|
-
}
|
|
12
|
-
catch {
|
|
13
|
-
return {};
|
|
14
|
-
}
|
|
15
|
-
};
|
|
16
|
-
export const convertJwtToBase64 = (jwt) => {
|
|
17
|
-
return jwt.toString().split('.')[1].replace('-', '+').replace('_', '/');
|
|
18
|
-
};
|
|
19
|
-
export function isJWTToken(token) {
|
|
20
|
-
const JWT_REGEX = /^(?:[\w=-]+\.){2}[\w+./=-]+$/;
|
|
21
|
-
return JWT_REGEX.test(token);
|
|
22
|
-
}
|
|
23
|
-
export function getJwtIat(jwt) {
|
|
24
|
-
const parts = jwt.split('.');
|
|
25
|
-
if (parts.length !== 3) {
|
|
26
|
-
throw new Error('Invalid JWT format');
|
|
27
|
-
}
|
|
28
|
-
const payloadJson = Buffer.from(parts[1], 'base64').toString('utf8');
|
|
29
|
-
const payload = JSON.parse(payloadJson);
|
|
30
|
-
if (typeof payload.iat !== 'number') {
|
|
31
|
-
throw new TypeError('JWT `iat` claim missing or not a number');
|
|
32
|
-
}
|
|
33
|
-
return payload.iat;
|
|
34
|
-
}
|
|
35
|
-
export function isJwtFresh(jwt, maxAgeSeconds = 3600) {
|
|
36
|
-
try {
|
|
37
|
-
const issuedAt = getJwtIat(jwt);
|
|
38
|
-
const ageSeconds = Date.now() / 1000 - issuedAt;
|
|
39
|
-
return ageSeconds <= maxAgeSeconds;
|
|
40
|
-
}
|
|
41
|
-
catch {
|
|
42
|
-
return false;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { convertBase64ToObject, convertJwtToBase64, isJWTToken } from './utilities.jwt';
|
|
2
|
-
describe('convertBase64ToObject', () => {
|
|
3
|
-
test('base64 string should return an object', () => {
|
|
4
|
-
const BASE64 = 'eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ';
|
|
5
|
-
const exptectedObject = { sub: '1234567890', name: 'John Doe', iat: 1516239022 };
|
|
6
|
-
expect(convertBase64ToObject(BASE64)).toMatchObject(exptectedObject);
|
|
7
|
-
});
|
|
8
|
-
test('invalid base64 string should return an empty object', () => {
|
|
9
|
-
expect(convertBase64ToObject('e2ludmFsaWRPYmplY3R9=')).toMatchObject({});
|
|
10
|
-
});
|
|
11
|
-
});
|
|
12
|
-
describe('convertJwtToBase64', () => {
|
|
13
|
-
test('convert a JWT to a base64 string', () => {
|
|
14
|
-
const BASE64 = 'eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ';
|
|
15
|
-
const JWT = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c';
|
|
16
|
-
expect(convertJwtToBase64(JWT)).toBe(BASE64);
|
|
17
|
-
});
|
|
18
|
-
});
|
|
19
|
-
describe('isJWTToken', () => {
|
|
20
|
-
test('valid JWT token should return true', () => {
|
|
21
|
-
const validToken = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJucG8iLCJpYXQiOjE3MDA1Nzk4ODgsImxpY2Vuc2VfcHJvZmlsZSI6IndlYiIsImRybV90eXBlIjoid2lkZXZpbmUiLCJjbGllbnRfaXAiOiIzMS4yMS4yMDUuMTcxIn0.mxNDb_gx8nqwc5p-PwSPnJgjPB8_L-niXm_gIcgkQBw';
|
|
22
|
-
expect(isJWTToken(validToken)).toBe(true);
|
|
23
|
-
});
|
|
24
|
-
test('invalid JWT token should return false', () => {
|
|
25
|
-
const invalidToken = 'invalidToken';
|
|
26
|
-
expect(isJWTToken(invalidToken)).toBe(false);
|
|
27
|
-
});
|
|
28
|
-
test('an url input should return false, despite 3 dots', () => {
|
|
29
|
-
const invalidToken = 'https://www.example.com';
|
|
30
|
-
expect(isJWTToken(invalidToken)).toBe(false);
|
|
31
|
-
});
|
|
32
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { i18n } from 'bitmovin-player-ui/dist/js/framework/localization/i18n';
|
|
2
|
-
import { localizeKey } from './utilities.locale';
|
|
3
|
-
const KEY = 'settings.value';
|
|
4
|
-
describe('localizeKey', () => {
|
|
5
|
-
it('should return a localized key', () => {
|
|
6
|
-
const spy = jest.spyOn(i18n, 'getLocalizer');
|
|
7
|
-
localizeKey(KEY);
|
|
8
|
-
expect(spy).toHaveBeenCalledWith(KEY);
|
|
9
|
-
});
|
|
10
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function getModuleExport(module: unknown): unknown;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { getModuleExport } from './utilities.module';
|
|
2
|
-
describe('getModuleExport', () => {
|
|
3
|
-
it('should return null for the module', () => {
|
|
4
|
-
const MODULE = undefined;
|
|
5
|
-
expect(getModuleExport(MODULE)).toBeUndefined();
|
|
6
|
-
});
|
|
7
|
-
it('should return a string as module', () => {
|
|
8
|
-
const MODULE = 'module';
|
|
9
|
-
expect(getModuleExport(MODULE)).toBe(MODULE);
|
|
10
|
-
});
|
|
11
|
-
it('should return a non-default object as module', () => {
|
|
12
|
-
const MODULE = { module: true };
|
|
13
|
-
expect(getModuleExport(MODULE)).toMatchObject(MODULE);
|
|
14
|
-
});
|
|
15
|
-
it('should return the default module', () => {
|
|
16
|
-
const MODULE = { default: true };
|
|
17
|
-
expect(getModuleExport(MODULE)).toBeTruthy();
|
|
18
|
-
});
|
|
19
|
-
});
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { isJWTToken } from './utilities.jwt';
|
|
2
|
-
export function getAnalyticsPrid(params) {
|
|
3
|
-
const { source, sourceConfig, streamObject } = params;
|
|
4
|
-
if (isJWTToken(source)) {
|
|
5
|
-
return streamObject?.metadata?.prid ?? '';
|
|
6
|
-
}
|
|
7
|
-
return sourceConfig?.metadata?.prid ?? source;
|
|
8
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { mockStreamObject } from '../../../tests/mocks/mockStreamObject';
|
|
2
|
-
import { getAnalyticsPrid } from './utilities.prid';
|
|
3
|
-
describe('getAnalyticsPrid', () => {
|
|
4
|
-
it('should return the prid from streamObject if the source is a JWT token', () => {
|
|
5
|
-
const result = getAnalyticsPrid({
|
|
6
|
-
source: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c',
|
|
7
|
-
sourceConfig: undefined,
|
|
8
|
-
streamObject: {
|
|
9
|
-
...mockStreamObject,
|
|
10
|
-
metadata: {
|
|
11
|
-
...mockStreamObject.metadata,
|
|
12
|
-
prid: '123'
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
});
|
|
16
|
-
expect(result).toBe('123');
|
|
17
|
-
});
|
|
18
|
-
it('should return an empty string if the source is a JWT token but no prid is present in streamObject', () => {
|
|
19
|
-
const result = getAnalyticsPrid({
|
|
20
|
-
source: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c',
|
|
21
|
-
sourceConfig: undefined,
|
|
22
|
-
streamObject: {
|
|
23
|
-
...mockStreamObject
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
expect(result).toBe('');
|
|
27
|
-
});
|
|
28
|
-
it('should return the prid from sourceConfig if the source is a media file URL', () => {
|
|
29
|
-
const result = getAnalyticsPrid({
|
|
30
|
-
source: 'https://example.com/media/video.mp4',
|
|
31
|
-
sourceConfig: { metadata: { prid: '456' } },
|
|
32
|
-
streamObject: undefined
|
|
33
|
-
});
|
|
34
|
-
expect(result).toBe('456');
|
|
35
|
-
});
|
|
36
|
-
it('should return the source (media file URL) if no prid is found', () => {
|
|
37
|
-
const result = getAnalyticsPrid({
|
|
38
|
-
source: 'https://example.com/media/audio.mp3',
|
|
39
|
-
sourceConfig: undefined,
|
|
40
|
-
streamObject: {
|
|
41
|
-
...mockStreamObject
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
expect(result).toBe('https://example.com/media/audio.mp3');
|
|
45
|
-
});
|
|
46
|
-
});
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
interface StreamDurationInSecondsParams {
|
|
2
|
-
duration: string | number | undefined;
|
|
3
|
-
durationIsInMs?: boolean;
|
|
4
|
-
}
|
|
5
|
-
export declare function getStreamDurationInSeconds(params: StreamDurationInSecondsParams): number;
|
|
6
|
-
export declare function validatePrid(prid: string | undefined): string;
|
|
7
|
-
export {};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { convertMsToSeconds } from './utilities.time';
|
|
2
|
-
export function getStreamDurationInSeconds(params) {
|
|
3
|
-
const { duration, durationIsInMs } = params;
|
|
4
|
-
if (duration === undefined || duration === Number.POSITIVE_INFINITY) {
|
|
5
|
-
return -1;
|
|
6
|
-
}
|
|
7
|
-
if (durationIsInMs) {
|
|
8
|
-
return convertMsToSeconds(Number(duration));
|
|
9
|
-
}
|
|
10
|
-
else if (Number.isFinite(+duration)) {
|
|
11
|
-
return Number(duration);
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
return -1;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
export function validatePrid(prid) {
|
|
18
|
-
return prid !== '' && prid !== undefined ? prid : 'unknown';
|
|
19
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { getStreamDurationInSeconds, validatePrid } from './utilities.stream';
|
|
2
|
-
describe('getStreamDurationInSeconds', () => {
|
|
3
|
-
it('shoud return -1 for an undefined duration', () => {
|
|
4
|
-
expect(getStreamDurationInSeconds({ duration: undefined })).toBe(-1);
|
|
5
|
-
});
|
|
6
|
-
it('shoud return -1 for an infinite duration', () => {
|
|
7
|
-
expect(getStreamDurationInSeconds({ duration: Number.POSITIVE_INFINITY })).toBe(-1);
|
|
8
|
-
});
|
|
9
|
-
it('shoud return the duration in seconds with a string as input', () => {
|
|
10
|
-
expect(getStreamDurationInSeconds({ duration: '10' })).toBe(10);
|
|
11
|
-
});
|
|
12
|
-
it('shoud return the duration in seconds with a number as input', () => {
|
|
13
|
-
expect(getStreamDurationInSeconds({ duration: 10 })).toBe(10);
|
|
14
|
-
});
|
|
15
|
-
it('shoud return the duration in seconds with a string as input in ms', () => {
|
|
16
|
-
expect(getStreamDurationInSeconds({ duration: '10000', durationIsInMs: true })).toBe(10);
|
|
17
|
-
});
|
|
18
|
-
it('shoud return the duration in seconds with a number as input in ms', () => {
|
|
19
|
-
expect(getStreamDurationInSeconds({ duration: 10000, durationIsInMs: true })).toBe(10);
|
|
20
|
-
});
|
|
21
|
-
});
|
|
22
|
-
describe('validatePrid', () => {
|
|
23
|
-
it('should return "unknown" for an empty prid', () => {
|
|
24
|
-
expect(validatePrid('')).toBe('unknown');
|
|
25
|
-
});
|
|
26
|
-
it('should return "unknown" for a null value', () => {
|
|
27
|
-
expect(validatePrid(undefined)).toBe('unknown');
|
|
28
|
-
});
|
|
29
|
-
it('should return the prid', () => {
|
|
30
|
-
expect(validatePrid('PRID')).toBe('PRID');
|
|
31
|
-
});
|
|
32
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function replaceSpecialCharacters(text: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { replaceSpecialCharacters } from './utilities.text';
|
|
2
|
-
describe('replaceSpecialCharacters', () => {
|
|
3
|
-
it('should replace special characters with their hexadecimal representation', () => {
|
|
4
|
-
const inputText = 'This is a test with ( and * characters.';
|
|
5
|
-
const result = replaceSpecialCharacters(inputText);
|
|
6
|
-
expect(result).toBe('This is a test with %28 and %2A characters.');
|
|
7
|
-
});
|
|
8
|
-
it('should handle an empty string', () => {
|
|
9
|
-
const inputText = '';
|
|
10
|
-
const result = replaceSpecialCharacters(inputText);
|
|
11
|
-
expect(result).toBe('');
|
|
12
|
-
});
|
|
13
|
-
it('should handle a string with no special characters', () => {
|
|
14
|
-
const inputText = 'This is a normal string without special characters.';
|
|
15
|
-
const result = replaceSpecialCharacters(inputText);
|
|
16
|
-
expect(result).toBe(inputText);
|
|
17
|
-
});
|
|
18
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function convertMsToSeconds(ms: number): number;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { convertMsToSeconds } from './utilities.time';
|
|
2
|
-
describe('convertMsToSeconds', () => {
|
|
3
|
-
test('convert milliseconds to seconds', () => {
|
|
4
|
-
const TIME_IN_MS = 5000;
|
|
5
|
-
const TIME_IN_SECONDS = 5;
|
|
6
|
-
expect(convertMsToSeconds(TIME_IN_MS)).toBe(TIME_IN_SECONDS);
|
|
7
|
-
});
|
|
8
|
-
});
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
const supportedMediaTypes = [
|
|
2
|
-
'video/',
|
|
3
|
-
'audio/',
|
|
4
|
-
'application/octet-stream',
|
|
5
|
-
'application/mp4',
|
|
6
|
-
'application/x-mpegURL',
|
|
7
|
-
'application/vnd.apple.mpegurl',
|
|
8
|
-
'application/ogg'
|
|
9
|
-
];
|
|
10
|
-
export async function isMediaUrl(url) {
|
|
11
|
-
if (!isUrl(url))
|
|
12
|
-
return false;
|
|
13
|
-
try {
|
|
14
|
-
const response = await fetch(url, { method: 'HEAD' });
|
|
15
|
-
const header = response.headers.get('Content-Type') ?? '';
|
|
16
|
-
return supportedMediaTypes.some((mediaType) => header.startsWith(mediaType));
|
|
17
|
-
}
|
|
18
|
-
catch (error) {
|
|
19
|
-
console.error('Failed to fetch the URL', error);
|
|
20
|
-
return false;
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
export function isUrl(url) {
|
|
24
|
-
const URL_REGEX = /^(http|https):\/\/(?:www\.)?[\dA-Za-z-]+(?:\.[A-Za-z]{2,})+(?:\/[^ "]+)?(?:\?.*)?$/;
|
|
25
|
-
return URL_REGEX.test(url);
|
|
26
|
-
}
|
|
27
|
-
export const removeTrailingSlash = (url) => {
|
|
28
|
-
return url.endsWith('/') ? url.slice(0, -1) : url;
|
|
29
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import fetchMock from 'jest-fetch-mock';
|
|
2
|
-
import { isMediaUrl, isUrl, removeTrailingSlash } from './utilities.url';
|
|
3
|
-
fetchMock.enableMocks();
|
|
4
|
-
const INVALID_URL = 'invalidurl';
|
|
5
|
-
const VALID_URL = 'https://example.com';
|
|
6
|
-
describe('isMediaUrl', () => {
|
|
7
|
-
it('should return false for an invalid url', async () => {
|
|
8
|
-
expect(await isMediaUrl(INVALID_URL)).toBeFalsy();
|
|
9
|
-
});
|
|
10
|
-
it('should fail to fetch the url and return false', async () => {
|
|
11
|
-
expect(await isMediaUrl(VALID_URL)).toBeFalsy();
|
|
12
|
-
});
|
|
13
|
-
it('should not contain a header with a mediaType and return false', async () => {
|
|
14
|
-
fetchMock.mockResponseOnce('', { headers: { 'Content-Type': 'application/json' } });
|
|
15
|
-
expect(await isMediaUrl(VALID_URL)).toBeFalsy();
|
|
16
|
-
});
|
|
17
|
-
it('should contain a header with a mediaType and return true', async () => {
|
|
18
|
-
fetchMock.mockResponseOnce('', { headers: { 'Content-Type': 'application/vnd.apple.mpegurl' } });
|
|
19
|
-
expect(await isMediaUrl(VALID_URL)).toBeTruthy();
|
|
20
|
-
});
|
|
21
|
-
});
|
|
22
|
-
describe('isUrl', () => {
|
|
23
|
-
test('valid URL should return true', () => {
|
|
24
|
-
const VALID_URL = 'https://www.example.com';
|
|
25
|
-
expect(isUrl(VALID_URL)).toBeTruthy();
|
|
26
|
-
});
|
|
27
|
-
test('valid URL with parameters should return true', () => {
|
|
28
|
-
const VALID_URL = 'https://www.example.com?foo=bar';
|
|
29
|
-
expect(isUrl(VALID_URL)).toBeTruthy();
|
|
30
|
-
});
|
|
31
|
-
test('valid URL with parameters should return true', () => {
|
|
32
|
-
const VALID_URL = 'https://example.com';
|
|
33
|
-
expect(isUrl(VALID_URL)).toBeTruthy();
|
|
34
|
-
});
|
|
35
|
-
test('invalid URL should return false', () => {
|
|
36
|
-
const INVALID_URL = 'invalidurl';
|
|
37
|
-
expect(isUrl(INVALID_URL)).toBeFalsy();
|
|
38
|
-
});
|
|
39
|
-
});
|
|
40
|
-
describe('removeTrailingSlash', () => {
|
|
41
|
-
test('trailing slash should be removed from url', () => {
|
|
42
|
-
const URL_BASE = 'https://www.example.com';
|
|
43
|
-
const URL_WITH_TRAILING_SLASH = URL_BASE + '/';
|
|
44
|
-
expect(removeTrailingSlash(URL_WITH_TRAILING_SLASH)).toBe(URL_BASE);
|
|
45
|
-
});
|
|
46
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { supportedKeySystems } from '../settings/settings.user-agent';
|
|
2
|
-
export function isFairPlayDrmSupported(keySystems) {
|
|
3
|
-
return keySystems.some((keySystem) => window.WebKitMediaKeys?.isTypeSupported(keySystem, 'video/mp4'));
|
|
4
|
-
}
|
|
5
|
-
export const isSafariUserAgent = (userAgent) => userAgent.includes('Safari') &&
|
|
6
|
-
!userAgent.includes('Chrome') &&
|
|
7
|
-
!userAgent.includes('IEMobile') &&
|
|
8
|
-
!userAgent.includes('Edge') &&
|
|
9
|
-
!userAgent.includes('Chromium') &&
|
|
10
|
-
!userAgent.includes('Android');
|
|
11
|
-
export function isSafari() {
|
|
12
|
-
return isSafariUserAgent(navigator.userAgent) || isFairPlayDrmSupported(supportedKeySystems);
|
|
13
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { isFairPlayDrmSupported, isSafari, isSafariUserAgent } from './utilities.user-agent';
|
|
2
|
-
const defaultKeySystems = ['com.apple.fps.1_0', 'com.apple.fps.2_0'];
|
|
3
|
-
describe('isFairPlayDrmSupported', () => {
|
|
4
|
-
it('should call WebKitMediaKeys.isTypeSupported with the right parameters', () => {
|
|
5
|
-
const isTypeSupported = jest.fn();
|
|
6
|
-
Object.defineProperty(window, 'WebKitMediaKeys', {
|
|
7
|
-
value: { isTypeSupported },
|
|
8
|
-
writable: true
|
|
9
|
-
});
|
|
10
|
-
isFairPlayDrmSupported(defaultKeySystems);
|
|
11
|
-
expect(isTypeSupported).toHaveBeenCalledWith('com.apple.fps.1_0', 'video/mp4');
|
|
12
|
-
expect(isTypeSupported).toHaveBeenCalledWith('com.apple.fps.2_0', 'video/mp4');
|
|
13
|
-
});
|
|
14
|
-
it('should return false if WebKitMediaKeys is not available', () => {
|
|
15
|
-
Object.defineProperty(window, 'WebKitMediaKeys', {
|
|
16
|
-
value: undefined,
|
|
17
|
-
writable: true
|
|
18
|
-
});
|
|
19
|
-
expect(isFairPlayDrmSupported(defaultKeySystems)).toBe(false);
|
|
20
|
-
});
|
|
21
|
-
it('should return false if an empty array of key systems is provided', () => {
|
|
22
|
-
Object.defineProperty(window, 'WebKitMediaKeys', {
|
|
23
|
-
value: { isTypeSupported: () => true },
|
|
24
|
-
writable: true
|
|
25
|
-
});
|
|
26
|
-
expect(isFairPlayDrmSupported([])).toBe(false);
|
|
27
|
-
});
|
|
28
|
-
});
|
|
29
|
-
describe('isSafariUserAgent', () => {
|
|
30
|
-
it('should return true for Safari', () => {
|
|
31
|
-
expect(isSafariUserAgent('Safari')).toBe(true);
|
|
32
|
-
});
|
|
33
|
-
it('should return false for other user agents', () => {
|
|
34
|
-
expect(isSafariUserAgent('Chrome')).toBe(false);
|
|
35
|
-
expect(isSafariUserAgent('IEMobile')).toBe(false);
|
|
36
|
-
expect(isSafariUserAgent('Edge')).toBe(false);
|
|
37
|
-
expect(isSafariUserAgent('Chromium')).toBe(false);
|
|
38
|
-
expect(isSafariUserAgent('Android')).toBe(false);
|
|
39
|
-
});
|
|
40
|
-
});
|
|
41
|
-
describe('isSafari', () => {
|
|
42
|
-
it('should return true if the user agent is Safari', () => {
|
|
43
|
-
jest.spyOn(global.navigator, 'userAgent', 'get').mockReturnValue('Safari');
|
|
44
|
-
expect(isSafari()).toBe(true);
|
|
45
|
-
});
|
|
46
|
-
it('should return true if FairPlayDrm is supported', () => {
|
|
47
|
-
;
|
|
48
|
-
window.WebKitMediaKeys = function () { };
|
|
49
|
-
window.WebKitMediaKeys.isTypeSupported = () => true;
|
|
50
|
-
jest.spyOn(global.navigator, 'userAgent', 'get').mockReturnValue('Chrome');
|
|
51
|
-
expect(isSafari()).toBe(true);
|
|
52
|
-
});
|
|
53
|
-
it('should return false if the user agent is not Safari and FairPlayDrm is not supported', () => {
|
|
54
|
-
;
|
|
55
|
-
window.WebKitMediaKeys = function () { };
|
|
56
|
-
window.WebKitMediaKeys.isTypeSupported = () => false;
|
|
57
|
-
jest.spyOn(global.navigator, 'userAgent', 'get').mockReturnValue('Safari Chrome IEMobile Edge Chromium Android');
|
|
58
|
-
expect(isSafari()).toBe(false);
|
|
59
|
-
});
|
|
60
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function logVersion(version: string): void;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
export function logVersion(version) {
|
|
2
|
-
const ASCII_ART = `
|
|
3
|
-
╔▒▒╖
|
|
4
|
-
_╔╠╠╠╠╠╠╠φ_
|
|
5
|
-
_#╠╠╠╠╠╠╠╠╠╠╠#_
|
|
6
|
-
╓╔╠╠╠╠╝╝╠╠╠╠╠╠╠╠╠▒,
|
|
7
|
-
╔╬╠╠╠╠╠ '╚╠╠╠╠╠╠╠╠▒╖
|
|
8
|
-
╔╬╠╠╠╠╠╠╠ '╚╠╠╠╠╠╠╠╬╦
|
|
9
|
-
_╓╠╠╠╠╠╠╠╠╠╠ '╚╠╠╠╠╠╠╠╖╖
|
|
10
|
-
╠╠╠╠╠╠╠╠╠╠╠╠ ╠╠╠╠╠╠╠╠▒
|
|
11
|
-
╬╠╠╠╠╠╠╠╠╠╠╠ _╔╬╠╠╠╠╠╠╠╝
|
|
12
|
-
\`╝╠╠╠╠╠╠╠╠╠ _╔╠╠╠╠╠╠╠╠╠╩\`
|
|
13
|
-
\`╚╠╠╠╠╠╠╠ _╔╬╠╠╠╠╠╠╠╠╠╩
|
|
14
|
-
╙╠╠╠╠╠▒╗φ╬╠╠╠╠╠╠╠╠╠╠╜
|
|
15
|
-
╙╬╠╠╠╠╠╠╠╠╠╠╠╠╠╠╙
|
|
16
|
-
'╬╠╠╠╠╠╠╠╠╠╝^
|
|
17
|
-
\`╝╠╠╠╠╠╩\`
|
|
18
|
-
\`╙╙╙
|
|
19
|
-
`;
|
|
20
|
-
const COLOR_CODE = '#f56A00';
|
|
21
|
-
const TITLE = 'NPO Player';
|
|
22
|
-
const TITLE_STYLE = `font-size: 24px; font-weight: bold; color: ${COLOR_CODE}; padding: 2px 4px;`;
|
|
23
|
-
const VERSION_STRING = 'v' + String(version);
|
|
24
|
-
const VERSION_STYLE = 'font-size: 24px; font-weight: bold; padding: 2px 4px;';
|
|
25
|
-
console.log(`%c${ASCII_ART}%c${TITLE} %c${VERSION_STRING}`, `color: ${COLOR_CODE}; background-color: rgb(11, 28, 54);`, TITLE_STYLE, VERSION_STYLE);
|
|
26
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { logVersion } from './utilities.version';
|
|
2
|
-
describe('logVersion', () => {
|
|
3
|
-
it('should print the current version', () => {
|
|
4
|
-
const logSpy = jest.spyOn(console, 'log');
|
|
5
|
-
logVersion('1.0.0');
|
|
6
|
-
const ASCII_ART = `
|
|
7
|
-
╔▒▒╖
|
|
8
|
-
_╔╠╠╠╠╠╠╠φ_
|
|
9
|
-
_#╠╠╠╠╠╠╠╠╠╠╠#_
|
|
10
|
-
╓╔╠╠╠╠╝╝╠╠╠╠╠╠╠╠╠▒,
|
|
11
|
-
╔╬╠╠╠╠╠ '╚╠╠╠╠╠╠╠╠▒╖
|
|
12
|
-
╔╬╠╠╠╠╠╠╠ '╚╠╠╠╠╠╠╠╬╦
|
|
13
|
-
_╓╠╠╠╠╠╠╠╠╠╠ '╚╠╠╠╠╠╠╠╖╖
|
|
14
|
-
╠╠╠╠╠╠╠╠╠╠╠╠ ╠╠╠╠╠╠╠╠▒
|
|
15
|
-
╬╠╠╠╠╠╠╠╠╠╠╠ _╔╬╠╠╠╠╠╠╠╝
|
|
16
|
-
\`╝╠╠╠╠╠╠╠╠╠ _╔╠╠╠╠╠╠╠╠╠╩\`
|
|
17
|
-
\`╚╠╠╠╠╠╠╠ _╔╬╠╠╠╠╠╠╠╠╠╩
|
|
18
|
-
╙╠╠╠╠╠▒╗φ╬╠╠╠╠╠╠╠╠╠╠╜
|
|
19
|
-
╙╬╠╠╠╠╠╠╠╠╠╠╠╠╠╠╙
|
|
20
|
-
'╬╠╠╠╠╠╠╠╠╠╝^
|
|
21
|
-
\`╝╠╠╠╠╠╩\`
|
|
22
|
-
\`╙╙╙
|
|
23
|
-
`;
|
|
24
|
-
expect(logSpy).toHaveBeenCalledWith(`%c${ASCII_ART}%cNPO Player %cv1.0.0`, 'color: #f56A00; background-color: rgb(11, 28, 54);', 'font-size: 24px; font-weight: bold; color: #f56A00; padding: 2px 4px;', 'font-size: 24px; font-weight: bold; padding: 2px 4px;');
|
|
25
|
-
});
|
|
26
|
-
});
|