bitmovin-player-react-native 0.44.1-alpha.0 → 1.0.0-alpha.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/.eslintignore +11 -0
- package/.eslintrc.js +7 -0
- package/.gitattributes +3 -0
- package/.prettierignore +11 -0
- package/.ruby-version +1 -0
- package/.swiftlint.yml +171 -0
- package/Brewfile +2 -0
- package/CHANGELOG.md +627 -0
- package/CONTRIBUTING.md +255 -0
- package/TODO.md +0 -0
- package/android/.editorconfig +8 -0
- package/android/build.gradle +78 -75
- package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/gradle/wrapper/gradle-wrapper.properties +7 -0
- package/android/gradle.properties +1 -0
- package/android/gradlew +248 -0
- package/android/gradlew.bat +92 -0
- package/android/ktlint.gradle +31 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/ActivityLifecycleListener.kt +51 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/BitmovinCastManagerModule.kt +32 -55
- package/android/src/main/java/com/bitmovin/player/reactnative/BufferModule.kt +33 -45
- package/android/src/main/java/com/bitmovin/player/reactnative/CustomMessageHandlerModule.kt +84 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/DebugModule.kt +6 -14
- package/android/src/main/java/com/bitmovin/player/reactnative/DecoderConfigModule.kt +89 -44
- package/android/src/main/java/com/bitmovin/player/reactnative/DrmModule.kt +80 -99
- package/android/src/main/java/com/bitmovin/player/reactnative/EventSubscription.kt +22 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/FullscreenHandlerModule.kt +100 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/MediaSessionPlaybackManager.kt +5 -5
- package/android/src/main/java/com/bitmovin/player/reactnative/NetworkModule.kt +98 -56
- package/android/src/main/java/com/bitmovin/player/reactnative/OfflineModule.kt +132 -186
- package/android/src/main/java/com/bitmovin/player/reactnative/PlayerAnalyticsModule.kt +37 -36
- package/android/src/main/java/com/bitmovin/player/reactnative/PlayerModule.kt +252 -528
- package/android/src/main/java/com/bitmovin/player/reactnative/RNPlayerPackage.kt +11 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/RNPlayerView.kt +558 -213
- package/android/src/main/java/com/bitmovin/player/reactnative/RNPlayerViewManager.kt +99 -286
- package/android/src/main/java/com/bitmovin/player/reactnative/ResultWaiter.kt +58 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/SourceModule.kt +77 -151
- package/android/src/main/java/com/bitmovin/player/reactnative/Types.kt +44 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/UuidModule.kt +12 -15
- package/android/src/main/java/com/bitmovin/player/reactnative/converter/JsonConverter.kt +296 -456
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/ListExtension.kt +89 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/MapExtension.kt +95 -0
- package/android/src/main/java/com/bitmovin/player/reactnative/offline/OfflineContentManagerBridge.kt +20 -52
- package/android/src/main/java/com/bitmovin/player/reactnative/ui/CustomMessageHandlerBridge.kt +10 -20
- package/android/src/main/java/com/bitmovin/player/reactnative/ui/FullscreenHandlerBridge.kt +4 -9
- package/app.plugin.js +21 -0
- package/build/BitmovinPlayerReactNative.types.d.ts +18 -0
- package/build/BitmovinPlayerReactNative.types.d.ts.map +1 -0
- package/build/BitmovinPlayerReactNative.types.js +2 -0
- package/build/BitmovinPlayerReactNative.types.js.map +1 -0
- package/build/adaptationConfig.d.ts +18 -0
- package/build/adaptationConfig.d.ts.map +1 -0
- package/build/adaptationConfig.js +2 -0
- package/build/adaptationConfig.js.map +1 -0
- package/build/advertising.d.ts +175 -0
- package/build/advertising.d.ts.map +1 -0
- package/build/advertising.js +37 -0
- package/build/advertising.js.map +1 -0
- package/build/analytics/config.d.ts +194 -0
- package/build/analytics/config.d.ts.map +1 -0
- package/build/analytics/config.js +2 -0
- package/build/analytics/config.js.map +1 -0
- package/build/analytics/index.d.ts +3 -0
- package/build/analytics/index.d.ts.map +1 -0
- package/build/analytics/index.js +3 -0
- package/build/analytics/index.js.map +1 -0
- package/build/analytics/player.d.ts +24 -0
- package/build/analytics/player.d.ts.map +1 -0
- package/build/analytics/player.js +30 -0
- package/build/analytics/player.js.map +1 -0
- package/build/analytics/playerAnalyticsModule.d.ts +13 -0
- package/build/analytics/playerAnalyticsModule.d.ts.map +1 -0
- package/build/analytics/playerAnalyticsModule.js +3 -0
- package/build/analytics/playerAnalyticsModule.js.map +1 -0
- package/build/audioSession.d.ts +33 -0
- package/build/audioSession.d.ts.map +1 -0
- package/build/audioSession.js +21 -0
- package/build/audioSession.js.map +1 -0
- package/build/audioTrack.d.ts +39 -0
- package/build/audioTrack.d.ts.map +1 -0
- package/build/audioTrack.js +2 -0
- package/build/audioTrack.js.map +1 -0
- package/build/bitmovinCastManager.d.ts +58 -0
- package/build/bitmovinCastManager.d.ts.map +1 -0
- package/build/bitmovinCastManager.js +64 -0
- package/build/bitmovinCastManager.js.map +1 -0
- package/build/bufferApi.d.ts +85 -0
- package/build/bufferApi.d.ts.map +1 -0
- package/build/bufferApi.js +60 -0
- package/build/bufferApi.js.map +1 -0
- package/build/bufferConfig.d.ts +42 -0
- package/build/bufferConfig.d.ts.map +1 -0
- package/build/bufferConfig.js +2 -0
- package/build/bufferConfig.js.map +1 -0
- package/build/components/PlayerView/events.d.ts +310 -0
- package/build/components/PlayerView/events.d.ts.map +1 -0
- package/build/components/PlayerView/events.js +2 -0
- package/build/components/PlayerView/events.js.map +1 -0
- package/build/components/PlayerView/index.d.ts +10 -0
- package/build/components/PlayerView/index.d.ts.map +1 -0
- package/build/components/PlayerView/index.js +72 -0
- package/build/components/PlayerView/index.js.map +1 -0
- package/build/components/PlayerView/native.d.ts +30 -0
- package/build/components/PlayerView/native.d.ts.map +1 -0
- package/build/components/PlayerView/native.js +6 -0
- package/build/components/PlayerView/native.js.map +1 -0
- package/build/components/PlayerView/nativeEvents.d.ts +437 -0
- package/build/components/PlayerView/nativeEvents.d.ts.map +1 -0
- package/build/components/PlayerView/nativeEvents.js +2 -0
- package/build/components/PlayerView/nativeEvents.js.map +1 -0
- package/build/components/PlayerView/pictureInPictureConfig.d.ts +22 -0
- package/build/components/PlayerView/pictureInPictureConfig.d.ts.map +1 -0
- package/build/components/PlayerView/pictureInPictureConfig.js +2 -0
- package/build/components/PlayerView/pictureInPictureConfig.js.map +1 -0
- package/build/components/PlayerView/playerViewConfig.d.ts +111 -0
- package/build/components/PlayerView/playerViewConfig.d.ts.map +1 -0
- package/build/components/PlayerView/playerViewConfig.js +51 -0
- package/build/components/PlayerView/playerViewConfig.js.map +1 -0
- package/build/components/PlayerView/properties.d.ts +61 -0
- package/build/components/PlayerView/properties.d.ts.map +1 -0
- package/build/components/PlayerView/properties.js +2 -0
- package/build/components/PlayerView/properties.js.map +1 -0
- package/build/components/index.d.ts +5 -0
- package/build/components/index.d.ts.map +1 -0
- package/build/components/index.js +5 -0
- package/build/components/index.js.map +1 -0
- package/build/debug.d.ts +46 -0
- package/build/debug.d.ts.map +1 -0
- package/build/debug.js +52 -0
- package/build/debug.js.map +1 -0
- package/build/decoder/decoderConfig.d.ts +96 -0
- package/build/decoder/decoderConfig.d.ts.map +1 -0
- package/build/decoder/decoderConfig.js +6 -0
- package/build/decoder/decoderConfig.js.map +1 -0
- package/build/decoder/decoderConfigModule.d.ts +14 -0
- package/build/decoder/decoderConfigModule.d.ts.map +1 -0
- package/build/decoder/decoderConfigModule.js +31 -0
- package/build/decoder/decoderConfigModule.js.map +1 -0
- package/build/decoder/index.d.ts +26 -0
- package/build/decoder/index.d.ts.map +1 -0
- package/build/decoder/index.js +50 -0
- package/build/decoder/index.js.map +1 -0
- package/build/drm/drmModule.d.ts +55 -0
- package/build/drm/drmModule.d.ts.map +1 -0
- package/build/drm/drmModule.js +3 -0
- package/build/drm/drmModule.js.map +1 -0
- package/build/drm/fairplayConfig.d.ts +91 -0
- package/build/drm/fairplayConfig.d.ts.map +1 -0
- package/build/drm/fairplayConfig.js +2 -0
- package/build/drm/fairplayConfig.js.map +1 -0
- package/build/drm/index.d.ts +112 -0
- package/build/drm/index.d.ts.map +1 -0
- package/build/drm/index.js +191 -0
- package/build/drm/index.js.map +1 -0
- package/build/drm/widevineConfig.d.ts +58 -0
- package/build/drm/widevineConfig.d.ts.map +1 -0
- package/build/drm/widevineConfig.js +2 -0
- package/build/drm/widevineConfig.js.map +1 -0
- package/build/events.d.ts +692 -0
- package/build/events.d.ts.map +1 -0
- package/build/events.js +2 -0
- package/build/events.js.map +1 -0
- package/build/hooks/index.d.ts +2 -0
- package/build/hooks/index.d.ts.map +1 -0
- package/build/hooks/index.js +2 -0
- package/build/hooks/index.js.map +1 -0
- package/build/hooks/usePlayer.d.ts +8 -0
- package/build/hooks/usePlayer.d.ts.map +1 -0
- package/build/hooks/usePlayer.js +10 -0
- package/build/hooks/usePlayer.js.map +1 -0
- package/build/hooks/useProxy.d.ts +18 -0
- package/build/hooks/useProxy.d.ts.map +1 -0
- package/build/hooks/useProxy.js +16 -0
- package/build/hooks/useProxy.js.map +1 -0
- package/build/index.d.ts +32 -0
- package/build/index.d.ts.map +1 -0
- package/build/index.js +32 -0
- package/build/index.js.map +1 -0
- package/build/liveConfig.d.ts +13 -0
- package/build/liveConfig.d.ts.map +1 -0
- package/build/liveConfig.js +2 -0
- package/build/liveConfig.js.map +1 -0
- package/build/media.d.ts +85 -0
- package/build/media.d.ts.map +1 -0
- package/build/media.js +2 -0
- package/build/media.js.map +1 -0
- package/build/mediaControlConfig.d.ts +62 -0
- package/build/mediaControlConfig.d.ts.map +1 -0
- package/build/mediaControlConfig.js +2 -0
- package/build/mediaControlConfig.js.map +1 -0
- package/build/mediaTrackRole.d.ts +28 -0
- package/build/mediaTrackRole.d.ts.map +1 -0
- package/build/mediaTrackRole.js +2 -0
- package/build/mediaTrackRole.js.map +1 -0
- package/build/modules/AudioSessionModule.d.ts +8 -0
- package/build/modules/AudioSessionModule.d.ts.map +1 -0
- package/build/modules/AudioSessionModule.js +7 -0
- package/build/modules/AudioSessionModule.js.map +1 -0
- package/build/modules/BitmovinCastManagerModule.d.ts +11 -0
- package/build/modules/BitmovinCastManagerModule.d.ts.map +1 -0
- package/build/modules/BitmovinCastManagerModule.js +3 -0
- package/build/modules/BitmovinCastManagerModule.js.map +1 -0
- package/build/modules/BufferModule.d.ts +16 -0
- package/build/modules/BufferModule.d.ts.map +1 -0
- package/build/modules/BufferModule.js +3 -0
- package/build/modules/BufferModule.js.map +1 -0
- package/build/modules/DebugModule.d.ts +8 -0
- package/build/modules/DebugModule.d.ts.map +1 -0
- package/build/modules/DebugModule.js +3 -0
- package/build/modules/DebugModule.js.map +1 -0
- package/build/modules/PlayerModule.d.ts +188 -0
- package/build/modules/PlayerModule.d.ts.map +1 -0
- package/build/modules/PlayerModule.js +3 -0
- package/build/modules/PlayerModule.js.map +1 -0
- package/build/modules/SourceModule.d.ts +51 -0
- package/build/modules/SourceModule.d.ts.map +1 -0
- package/build/modules/SourceModule.js +3 -0
- package/build/modules/SourceModule.js.map +1 -0
- package/build/modules/UuidModule.d.ts +8 -0
- package/build/modules/UuidModule.d.ts.map +1 -0
- package/build/modules/UuidModule.js +3 -0
- package/build/modules/UuidModule.js.map +1 -0
- package/build/nativeInstance.d.ts +49 -0
- package/build/nativeInstance.d.ts.map +1 -0
- package/build/nativeInstance.js +20 -0
- package/build/nativeInstance.js.map +1 -0
- package/build/network/index.d.ts +50 -0
- package/build/network/index.d.ts.map +1 -0
- package/build/network/index.js +102 -0
- package/build/network/index.js.map +1 -0
- package/build/network/networkConfig.d.ts +151 -0
- package/build/network/networkConfig.d.ts.map +1 -0
- package/build/network/networkConfig.js +21 -0
- package/build/network/networkConfig.js.map +1 -0
- package/build/network/networkModule.d.ts +29 -0
- package/build/network/networkModule.d.ts.map +1 -0
- package/build/network/networkModule.js +3 -0
- package/build/network/networkModule.js.map +1 -0
- package/build/offline/index.d.ts +8 -0
- package/build/offline/index.d.ts.map +1 -0
- package/build/offline/index.js +8 -0
- package/build/offline/index.js.map +1 -0
- package/build/offline/offlineContentConfig.d.ts +18 -0
- package/build/offline/offlineContentConfig.d.ts.map +1 -0
- package/build/offline/offlineContentConfig.js +2 -0
- package/build/offline/offlineContentConfig.js.map +1 -0
- package/build/offline/offlineContentManager.d.ts +90 -0
- package/build/offline/offlineContentManager.d.ts.map +1 -0
- package/build/offline/offlineContentManager.js +177 -0
- package/build/offline/offlineContentManager.js.map +1 -0
- package/build/offline/offlineContentManagerListener.d.ts +174 -0
- package/build/offline/offlineContentManagerListener.d.ts.map +1 -0
- package/build/offline/offlineContentManagerListener.js +17 -0
- package/build/offline/offlineContentManagerListener.js.map +1 -0
- package/build/offline/offlineContentOptions.d.ts +29 -0
- package/build/offline/offlineContentOptions.d.ts.map +1 -0
- package/build/offline/offlineContentOptions.js +2 -0
- package/build/offline/offlineContentOptions.js.map +1 -0
- package/build/offline/offlineDownloadRequest.d.ts +19 -0
- package/build/offline/offlineDownloadRequest.d.ts.map +1 -0
- package/build/offline/offlineDownloadRequest.js +2 -0
- package/build/offline/offlineDownloadRequest.js.map +1 -0
- package/build/offline/offlineModule.d.ts +32 -0
- package/build/offline/offlineModule.d.ts.map +1 -0
- package/build/offline/offlineModule.js +3 -0
- package/build/offline/offlineModule.js.map +1 -0
- package/build/offline/offlineSourceOptions.d.ts +12 -0
- package/build/offline/offlineSourceOptions.d.ts.map +1 -0
- package/build/offline/offlineSourceOptions.js +2 -0
- package/build/offline/offlineSourceOptions.js.map +1 -0
- package/build/offline/offlineState.d.ts +23 -0
- package/build/offline/offlineState.d.ts.map +1 -0
- package/build/offline/offlineState.js +24 -0
- package/build/offline/offlineState.js.map +1 -0
- package/build/playbackConfig.d.ts +88 -0
- package/build/playbackConfig.d.ts.map +1 -0
- package/build/playbackConfig.js +2 -0
- package/build/playbackConfig.js.map +1 -0
- package/build/player.d.ts +308 -0
- package/build/player.d.ts.map +1 -0
- package/build/player.js +445 -0
- package/build/player.js.map +1 -0
- package/build/playerConfig.d.ts +83 -0
- package/build/playerConfig.d.ts.map +1 -0
- package/build/playerConfig.js +2 -0
- package/build/playerConfig.js.map +1 -0
- package/build/remoteControlConfig.d.ts +38 -0
- package/build/remoteControlConfig.d.ts.map +1 -0
- package/build/remoteControlConfig.js +2 -0
- package/build/remoteControlConfig.js.map +1 -0
- package/build/source.d.ts +216 -0
- package/build/source.d.ts.map +1 -0
- package/build/source.js +167 -0
- package/build/source.js.map +1 -0
- package/build/styleConfig.d.ts +120 -0
- package/build/styleConfig.d.ts.map +1 -0
- package/build/styleConfig.js +38 -0
- package/build/styleConfig.js.map +1 -0
- package/build/subtitleFormat.d.ts +27 -0
- package/build/subtitleFormat.d.ts.map +1 -0
- package/build/subtitleFormat.js +28 -0
- package/build/subtitleFormat.js.map +1 -0
- package/build/subtitleTrack.d.ts +55 -0
- package/build/subtitleTrack.d.ts.map +1 -0
- package/build/subtitleTrack.js +2 -0
- package/build/subtitleTrack.js.map +1 -0
- package/build/thumbnail.d.ts +38 -0
- package/build/thumbnail.d.ts.map +1 -0
- package/build/thumbnail.js +2 -0
- package/build/thumbnail.js.map +1 -0
- package/build/tweaksConfig.d.ts +197 -0
- package/build/tweaksConfig.d.ts.map +1 -0
- package/build/tweaksConfig.js +25 -0
- package/build/tweaksConfig.js.map +1 -0
- package/build/ui/customMessageHandlerModule.d.ts +27 -0
- package/build/ui/customMessageHandlerModule.d.ts.map +1 -0
- package/build/ui/customMessageHandlerModule.js +3 -0
- package/build/ui/customMessageHandlerModule.js.map +1 -0
- package/build/ui/custommessagehandler.d.ts +56 -0
- package/build/ui/custommessagehandler.d.ts.map +1 -0
- package/build/ui/custommessagehandler.js +54 -0
- package/build/ui/custommessagehandler.js.map +1 -0
- package/build/ui/custommessagehandlerbridge.d.ts +33 -0
- package/build/ui/custommessagehandlerbridge.d.ts.map +1 -0
- package/build/ui/custommessagehandlerbridge.js +72 -0
- package/build/ui/custommessagehandlerbridge.js.map +1 -0
- package/build/ui/custommessagesender.d.ts +5 -0
- package/build/ui/custommessagesender.d.ts.map +1 -0
- package/build/ui/custommessagesender.js +2 -0
- package/build/ui/custommessagesender.js.map +1 -0
- package/build/ui/fullscreenHandlerModule.d.ts +20 -0
- package/build/ui/fullscreenHandlerModule.d.ts.map +1 -0
- package/build/ui/fullscreenHandlerModule.js +3 -0
- package/build/ui/fullscreenHandlerModule.js.map +1 -0
- package/build/ui/fullscreenhandler.d.ts +18 -0
- package/build/ui/fullscreenhandler.d.ts.map +1 -0
- package/build/ui/fullscreenhandler.js +2 -0
- package/build/ui/fullscreenhandler.js.map +1 -0
- package/build/ui/fullscreenhandlerbridge.d.ts +26 -0
- package/build/ui/fullscreenhandlerbridge.d.ts.map +1 -0
- package/build/ui/fullscreenhandlerbridge.js +67 -0
- package/build/ui/fullscreenhandlerbridge.js.map +1 -0
- package/build/ui/index.d.ts +3 -0
- package/build/ui/index.d.ts.map +1 -0
- package/build/ui/index.js +3 -0
- package/build/ui/index.js.map +1 -0
- package/expo-module.config.json +40 -0
- package/ios/AppLifecycleDelegate.swift +25 -0
- package/ios/AudioSessionModule.swift +14 -40
- package/ios/BitmovinCastManagerModule.swift +30 -69
- package/ios/BufferModule.swift +26 -62
- package/ios/CustomMessageHandlerBridge.swift +11 -18
- package/ios/CustomMessageHandlerModule.swift +61 -63
- package/ios/DebugModule.swift +6 -27
- package/ios/DrmModule.swift +105 -379
- package/ios/Event+JSON.swift +1 -0
- package/ios/FullscreenHandlerBridge.swift +12 -5
- package/ios/FullscreenHandlerModule.swift +73 -57
- package/ios/LockedBox.swift +21 -0
- package/ios/ModuleRegistry+Generics.swift +11 -0
- package/ios/NetworkModule.swift +78 -82
- package/ios/OfflineContentManagerBridge.swift +11 -38
- package/ios/OfflineModule.swift +136 -454
- package/ios/PlayerAnalyticsModule.swift +24 -52
- package/ios/PlayerModule.swift +192 -770
- package/ios/RCTConvert+BitmovinPlayer.swift +38 -312
- package/ios/RNBitmovinPlayer.h +1 -8
- package/ios/RNBitmovinPlayer.podspec +47 -0
- package/ios/RNPlayerView.swift +600 -77
- package/ios/RNPlayerViewManager.swift +96 -210
- package/ios/Registry.swift +2 -2
- package/ios/ResultWaiter.swift +66 -0
- package/ios/SourceModule.swift +104 -223
- package/ios/UuidModule.swift +9 -18
- package/package.json +67 -71
- package/plugin/build/FeatureFlags.d.ts +24 -0
- package/plugin/build/FeatureFlags.js +2 -0
- package/plugin/build/index.d.ts +7 -0
- package/plugin/build/index.js +10 -0
- package/plugin/build/withAppGradleDependencies.d.ts +7 -0
- package/plugin/build/withAppGradleDependencies.js +49 -0
- package/plugin/build/withBitmovinAndroidConfig.d.ts +7 -0
- package/plugin/build/withBitmovinAndroidConfig.js +159 -0
- package/plugin/build/withBitmovinConfig.d.ts +7 -0
- package/plugin/build/withBitmovinConfig.js +21 -0
- package/plugin/build/withBitmovinIosConfig.d.ts +7 -0
- package/plugin/build/withBitmovinIosConfig.js +53 -0
- package/plugin/src/FeatureFlags.ts +21 -0
- package/plugin/src/index.ts +9 -0
- package/plugin/src/withAppGradleDependencies.ts +80 -0
- package/plugin/src/withBitmovinAndroidConfig.ts +224 -0
- package/plugin/src/withBitmovinConfig.ts +24 -0
- package/plugin/src/withBitmovinIosConfig.ts +71 -0
- package/plugin/tsconfig.json +9 -0
- package/plugin/tsconfig.tsbuildinfo +1 -0
- package/prettier.config.js +7 -0
- package/scripts/format-android.sh +2 -0
- package/scripts/format-swift.sh +3 -0
- package/scripts/lint-android.sh +2 -0
- package/scripts/lint-swift.sh +3 -0
- package/scripts/pre-commit.sh +14 -0
- package/scripts/setup-hooks.sh +58 -0
- package/src/BitmovinPlayerReactNative.types.ts +19 -0
- package/src/adaptationConfig.ts +1 -1
- package/src/advertising.ts +1 -1
- package/src/analytics/config.ts +4 -4
- package/src/analytics/player.ts +4 -6
- package/src/analytics/playerAnalyticsModule.ts +19 -0
- package/src/audioSession.ts +4 -6
- package/src/audioTrack.ts +1 -1
- package/src/bitmovinCastManager.ts +14 -10
- package/src/bufferApi.ts +1 -3
- package/src/bufferConfig.ts +2 -2
- package/src/components/PlayerView/events.ts +92 -94
- package/src/components/PlayerView/index.tsx +109 -159
- package/src/components/PlayerView/native.ts +24 -11
- package/src/components/PlayerView/nativeEvents.ts +113 -94
- package/src/components/PlayerView/pictureInPictureConfig.ts +1 -1
- package/src/components/PlayerView/playerViewConfig.ts +4 -8
- package/src/components/PlayerView/properties.ts +23 -22
- package/src/debug.ts +1 -3
- package/src/decoder/decoderConfig.ts +3 -3
- package/src/decoder/decoderConfigModule.ts +62 -0
- package/src/decoder/index.ts +32 -16
- package/src/drm/drmModule.ts +84 -0
- package/src/drm/fairplayConfig.ts +1 -1
- package/src/drm/index.ts +130 -40
- package/src/drm/widevineConfig.ts +5 -5
- package/src/events.ts +47 -41
- package/src/hooks/useProxy.ts +13 -20
- package/src/mediaControlConfig.ts +1 -1
- package/src/modules/AudioSessionModule.ts +13 -0
- package/src/modules/BitmovinCastManagerModule.ts +14 -0
- package/src/modules/BufferModule.ts +18 -0
- package/src/modules/DebugModule.ts +9 -0
- package/src/modules/PlayerModule.ts +251 -0
- package/src/modules/SourceModule.ts +74 -0
- package/src/modules/UuidModule.ts +9 -0
- package/src/nativeInstance.ts +3 -3
- package/src/network/index.ts +42 -15
- package/src/network/networkConfig.ts +3 -3
- package/src/network/networkModule.ts +51 -0
- package/src/offline/offlineContentConfig.ts +1 -1
- package/src/offline/offlineContentManager.ts +15 -50
- package/src/offline/offlineContentManagerListener.ts +20 -23
- package/src/offline/offlineContentOptions.ts +2 -2
- package/src/offline/offlineDownloadRequest.ts +1 -1
- package/src/offline/offlineModule.ts +46 -0
- package/src/offline/offlineSourceOptions.ts +2 -2
- package/src/offline/offlineState.ts +1 -1
- package/src/playbackConfig.ts +5 -6
- package/src/player.ts +53 -48
- package/src/source.ts +15 -14
- package/src/styleConfig.ts +5 -5
- package/src/subtitleFormat.ts +5 -5
- package/src/subtitleTrack.ts +1 -1
- package/src/tweaksConfig.ts +16 -16
- package/src/ui/customMessageHandlerModule.ts +46 -0
- package/src/ui/custommessagehandlerbridge.ts +45 -18
- package/src/ui/fullscreenHandlerModule.ts +35 -0
- package/src/ui/fullscreenhandlerbridge.ts +35 -15
- package/tsconfig.json +9 -0
- package/typedoc.json +23 -0
- package/RNBitmovinPlayer.podspec +0 -26
- package/android/src/main/java/com/bitmovin/player/reactnative/BitmovinBaseModule.kt +0 -114
- package/android/src/main/java/com/bitmovin/player/reactnative/EventRelay.kt +0 -47
- package/android/src/main/java/com/bitmovin/player/reactnative/RNPlayerViewPackage.kt +0 -48
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/ReactContextExtension.kt +0 -24
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/ReadableArray.kt +0 -20
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/ReadableMap.kt +0 -15
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/ReadableMapExtension.kt +0 -57
- package/android/src/main/java/com/bitmovin/player/reactnative/extensions/WritableMap.kt +0 -27
- package/android/src/main/java/com/bitmovin/player/reactnative/ui/CustomMessageHandlerModule.kt +0 -86
- package/android/src/main/java/com/bitmovin/player/reactnative/ui/FullscreenHandlerModule.kt +0 -78
- package/ios/AudioSessionModule.m +0 -10
- package/ios/BitmovinCastManagerModule.m +0 -14
- package/ios/BufferModule.m +0 -8
- package/ios/CustomMessageHandlerModule.m +0 -10
- package/ios/DebugModule.m +0 -7
- package/ios/DrmModule.m +0 -16
- package/ios/FullscreenHandlerModule.m +0 -10
- package/ios/NetworkModule.m +0 -10
- package/ios/OfflineModule.m +0 -19
- package/ios/PlayerAnalyticsModule.m +0 -8
- package/ios/PlayerModule.m +0 -130
- package/ios/PreprocessHttpRequestDelegateBridge.swift +0 -30
- package/ios/RCTBridge+Generics.swift +0 -6
- package/ios/RNBitmovinPlayer.xcodeproj/project.pbxproj +0 -303
- package/ios/RNPlayerView+PlayerListener.swift +0 -229
- package/ios/RNPlayerView+UserInterfaceListener.swift +0 -35
- package/ios/RNPlayerViewManager.m +0 -79
- package/ios/SourceModule.m +0 -42
- package/ios/UuidModule.m +0 -9
- package/lib/index.d.mts +0 -4303
- package/lib/index.d.ts +0 -4303
- package/lib/index.js +0 -1895
- package/lib/index.mjs +0 -1836
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents different types of media.
|
|
3
|
+
*/
|
|
4
|
+
export declare enum MediaType {
|
|
5
|
+
/**
|
|
6
|
+
* Audio media type.
|
|
7
|
+
*/
|
|
8
|
+
AUDIO = "audio",
|
|
9
|
+
/**
|
|
10
|
+
* Video media type.
|
|
11
|
+
*/
|
|
12
|
+
VIDEO = "video"
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Represents different types of buffered data.
|
|
16
|
+
*/
|
|
17
|
+
export declare enum BufferType {
|
|
18
|
+
/**
|
|
19
|
+
* Represents the buffered data starting at the current playback time.
|
|
20
|
+
*/
|
|
21
|
+
FORWARD_DURATION = "forwardDuration",
|
|
22
|
+
/**
|
|
23
|
+
* Represents the buffered data up until the current playback time.
|
|
24
|
+
*/
|
|
25
|
+
BACKWARD_DURATION = "backwardDuration"
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Holds different information about the buffer levels.
|
|
29
|
+
*/
|
|
30
|
+
export interface BufferLevel {
|
|
31
|
+
/**
|
|
32
|
+
* The amount of currently buffered data, e.g. audio or video buffer level.
|
|
33
|
+
*/
|
|
34
|
+
level?: number;
|
|
35
|
+
/**
|
|
36
|
+
* The target buffer level the player tries to maintain.
|
|
37
|
+
*/
|
|
38
|
+
targetLevel?: number;
|
|
39
|
+
/**
|
|
40
|
+
* The media type the buffer data applies to.
|
|
41
|
+
*/
|
|
42
|
+
media?: MediaType;
|
|
43
|
+
/**
|
|
44
|
+
* The buffer type the buffer data applies to.
|
|
45
|
+
*/
|
|
46
|
+
type?: BufferType;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Collection of {@link BufferLevel} objects
|
|
50
|
+
*/
|
|
51
|
+
export interface BufferLevels {
|
|
52
|
+
/**
|
|
53
|
+
* {@link BufferLevel} for {@link MediaType.AUDIO}.
|
|
54
|
+
*/
|
|
55
|
+
audio: BufferLevel;
|
|
56
|
+
/**
|
|
57
|
+
* {@link BufferLevel} for {@link MediaType.VIDEO}.
|
|
58
|
+
*/
|
|
59
|
+
video: BufferLevel;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Provides the means to configure buffer settings and to query the current buffer state.
|
|
63
|
+
* Accessible through {@link Player.buffer}.
|
|
64
|
+
*/
|
|
65
|
+
export declare class BufferApi {
|
|
66
|
+
/**
|
|
67
|
+
* The native player id that this buffer api is attached to.
|
|
68
|
+
*/
|
|
69
|
+
readonly nativeId: string;
|
|
70
|
+
constructor(playerId: string);
|
|
71
|
+
/**
|
|
72
|
+
* Gets the {@link BufferLevel|buffer level} from the Player
|
|
73
|
+
* @param type The {@link BufferType} to return the level for.
|
|
74
|
+
* @returns a {@link BufferLevels} that contains {@link BufferLevel} values for audio and video.
|
|
75
|
+
*/
|
|
76
|
+
getLevel: (type: BufferType) => Promise<BufferLevels>;
|
|
77
|
+
/**
|
|
78
|
+
* Sets the target buffer level for the chosen buffer {@link BufferType} across all {@link MediaType} options.
|
|
79
|
+
*
|
|
80
|
+
* @param type The {@link BufferType} to set the target level for. On iOS and tvOS, only {@link BufferType.FORWARD_DURATION} is supported.
|
|
81
|
+
* @param value The value to set. On iOS and tvOS when passing `0`, the player will choose an appropriate forward buffer duration suitable for most use-cases. On Android setting to `0` will have no effect.
|
|
82
|
+
*/
|
|
83
|
+
setTargetLevel: (type: BufferType, value: number) => Promise<void>;
|
|
84
|
+
}
|
|
85
|
+
//# sourceMappingURL=bufferApi.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bufferApi.d.ts","sourceRoot":"","sources":["../src/bufferApi.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,oBAAY,SAAS;IACnB;;OAEG;IACH,KAAK,UAAU;IACf;;OAEG;IACH,KAAK,UAAU;CAChB;AAED;;GAEG;AACH,oBAAY,UAAU;IACpB;;OAEG;IACH,gBAAgB,oBAAoB;IACpC;;OAEG;IACH,iBAAiB,qBAAqB;CACvC;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB;;OAEG;IACH,IAAI,CAAC,EAAE,UAAU,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,KAAK,EAAE,WAAW,CAAC;IACnB;;OAEG;IACH,KAAK,EAAE,WAAW,CAAC;CACpB;AAED;;;GAGG;AACH,qBAAa,SAAS;IACpB;;OAEG;IACH,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;gBAEd,QAAQ,EAAE,MAAM;IAI5B;;;;OAIG;IACH,QAAQ,GAAU,MAAM,UAAU,KAAG,OAAO,CAAC,YAAY,CAAC,CAExD;IAEF;;;;;OAKG;IACH,cAAc,GAAU,MAAM,UAAU,EAAE,OAAO,MAAM,KAAG,OAAO,CAAC,IAAI,CAAC,CAErE;CACH"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import BufferModule from './modules/BufferModule';
|
|
2
|
+
/**
|
|
3
|
+
* Represents different types of media.
|
|
4
|
+
*/
|
|
5
|
+
export var MediaType;
|
|
6
|
+
(function (MediaType) {
|
|
7
|
+
/**
|
|
8
|
+
* Audio media type.
|
|
9
|
+
*/
|
|
10
|
+
MediaType["AUDIO"] = "audio";
|
|
11
|
+
/**
|
|
12
|
+
* Video media type.
|
|
13
|
+
*/
|
|
14
|
+
MediaType["VIDEO"] = "video";
|
|
15
|
+
})(MediaType || (MediaType = {}));
|
|
16
|
+
/**
|
|
17
|
+
* Represents different types of buffered data.
|
|
18
|
+
*/
|
|
19
|
+
export var BufferType;
|
|
20
|
+
(function (BufferType) {
|
|
21
|
+
/**
|
|
22
|
+
* Represents the buffered data starting at the current playback time.
|
|
23
|
+
*/
|
|
24
|
+
BufferType["FORWARD_DURATION"] = "forwardDuration";
|
|
25
|
+
/**
|
|
26
|
+
* Represents the buffered data up until the current playback time.
|
|
27
|
+
*/
|
|
28
|
+
BufferType["BACKWARD_DURATION"] = "backwardDuration";
|
|
29
|
+
})(BufferType || (BufferType = {}));
|
|
30
|
+
/**
|
|
31
|
+
* Provides the means to configure buffer settings and to query the current buffer state.
|
|
32
|
+
* Accessible through {@link Player.buffer}.
|
|
33
|
+
*/
|
|
34
|
+
export class BufferApi {
|
|
35
|
+
/**
|
|
36
|
+
* The native player id that this buffer api is attached to.
|
|
37
|
+
*/
|
|
38
|
+
nativeId;
|
|
39
|
+
constructor(playerId) {
|
|
40
|
+
this.nativeId = playerId;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Gets the {@link BufferLevel|buffer level} from the Player
|
|
44
|
+
* @param type The {@link BufferType} to return the level for.
|
|
45
|
+
* @returns a {@link BufferLevels} that contains {@link BufferLevel} values for audio and video.
|
|
46
|
+
*/
|
|
47
|
+
getLevel = async (type) => {
|
|
48
|
+
return BufferModule.getLevel(this.nativeId, type);
|
|
49
|
+
};
|
|
50
|
+
/**
|
|
51
|
+
* Sets the target buffer level for the chosen buffer {@link BufferType} across all {@link MediaType} options.
|
|
52
|
+
*
|
|
53
|
+
* @param type The {@link BufferType} to set the target level for. On iOS and tvOS, only {@link BufferType.FORWARD_DURATION} is supported.
|
|
54
|
+
* @param value The value to set. On iOS and tvOS when passing `0`, the player will choose an appropriate forward buffer duration suitable for most use-cases. On Android setting to `0` will have no effect.
|
|
55
|
+
*/
|
|
56
|
+
setTargetLevel = async (type, value) => {
|
|
57
|
+
return BufferModule.setTargetLevel(this.nativeId, type, value);
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
//# sourceMappingURL=bufferApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bufferApi.js","sourceRoot":"","sources":["../src/bufferApi.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAElD;;GAEG;AACH,MAAM,CAAN,IAAY,SASX;AATD,WAAY,SAAS;IACnB;;OAEG;IACH,4BAAe,CAAA;IACf;;OAEG;IACH,4BAAe,CAAA;AACjB,CAAC,EATW,SAAS,KAAT,SAAS,QASpB;AAED;;GAEG;AACH,MAAM,CAAN,IAAY,UASX;AATD,WAAY,UAAU;IACpB;;OAEG;IACH,kDAAoC,CAAA;IACpC;;OAEG;IACH,oDAAsC,CAAA;AACxC,CAAC,EATW,UAAU,KAAV,UAAU,QASrB;AAsCD;;;GAGG;AACH,MAAM,OAAO,SAAS;IACpB;;OAEG;IACM,QAAQ,CAAS;IAE1B,YAAY,QAAgB;QAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAED;;;;OAIG;IACH,QAAQ,GAAG,KAAK,EAAE,IAAgB,EAAyB,EAAE;QAC3D,OAAO,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC;IACpD,CAAC,CAAC;IAEF;;;;;OAKG;IACH,cAAc,GAAG,KAAK,EAAE,IAAgB,EAAE,KAAa,EAAiB,EAAE;QACxE,OAAO,YAAY,CAAC,cAAc,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC;IACjE,CAAC,CAAC;CACH","sourcesContent":["import BufferModule from './modules/BufferModule';\n\n/**\n * Represents different types of media.\n */\nexport enum MediaType {\n /**\n * Audio media type.\n */\n AUDIO = 'audio',\n /**\n * Video media type.\n */\n VIDEO = 'video',\n}\n\n/**\n * Represents different types of buffered data.\n */\nexport enum BufferType {\n /**\n * Represents the buffered data starting at the current playback time.\n */\n FORWARD_DURATION = 'forwardDuration',\n /**\n * Represents the buffered data up until the current playback time.\n */\n BACKWARD_DURATION = 'backwardDuration',\n}\n\n/**\n * Holds different information about the buffer levels.\n */\nexport interface BufferLevel {\n /**\n * The amount of currently buffered data, e.g. audio or video buffer level.\n */\n level?: number;\n /**\n * The target buffer level the player tries to maintain.\n */\n targetLevel?: number;\n /**\n * The media type the buffer data applies to.\n */\n media?: MediaType;\n /**\n * The buffer type the buffer data applies to.\n */\n type?: BufferType;\n}\n\n/**\n * Collection of {@link BufferLevel} objects\n */\nexport interface BufferLevels {\n /**\n * {@link BufferLevel} for {@link MediaType.AUDIO}.\n */\n audio: BufferLevel;\n /**\n * {@link BufferLevel} for {@link MediaType.VIDEO}.\n */\n video: BufferLevel;\n}\n\n/**\n * Provides the means to configure buffer settings and to query the current buffer state.\n * Accessible through {@link Player.buffer}.\n */\nexport class BufferApi {\n /**\n * The native player id that this buffer api is attached to.\n */\n readonly nativeId: string;\n\n constructor(playerId: string) {\n this.nativeId = playerId;\n }\n\n /**\n * Gets the {@link BufferLevel|buffer level} from the Player\n * @param type The {@link BufferType} to return the level for.\n * @returns a {@link BufferLevels} that contains {@link BufferLevel} values for audio and video.\n */\n getLevel = async (type: BufferType): Promise<BufferLevels> => {\n return BufferModule.getLevel(this.nativeId, type);\n };\n\n /**\n * Sets the target buffer level for the chosen buffer {@link BufferType} across all {@link MediaType} options.\n *\n * @param type The {@link BufferType} to set the target level for. On iOS and tvOS, only {@link BufferType.FORWARD_DURATION} is supported.\n * @param value The value to set. On iOS and tvOS when passing `0`, the player will choose an appropriate forward buffer duration suitable for most use-cases. On Android setting to `0` will have no effect.\n */\n setTargetLevel = async (type: BufferType, value: number): Promise<void> => {\n return BufferModule.setTargetLevel(this.nativeId, type, value);\n };\n}\n"]}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Configures buffer target levels for different MediaTypes.
|
|
3
|
+
*/
|
|
4
|
+
export interface BufferMediaTypeConfig {
|
|
5
|
+
/**
|
|
6
|
+
* The amount of data in seconds the player tries to buffer in advance.
|
|
7
|
+
*
|
|
8
|
+
* iOS and tvOS, only: If set to `0`, the player will choose an appropriate forward buffer duration suitable
|
|
9
|
+
* for most use-cases.
|
|
10
|
+
*
|
|
11
|
+
* Default value is `0` on iOS and tvOS, `50` on Android
|
|
12
|
+
*/
|
|
13
|
+
forwardDuration?: number;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Player buffer config object to configure buffering behavior.
|
|
17
|
+
*/
|
|
18
|
+
export interface BufferConfig {
|
|
19
|
+
/**
|
|
20
|
+
* Configures various settings for the audio and video buffer.
|
|
21
|
+
*/
|
|
22
|
+
audioAndVideo?: BufferMediaTypeConfig;
|
|
23
|
+
/**
|
|
24
|
+
* Amount of seconds the player buffers before playback starts again after a stall. This value is
|
|
25
|
+
* restricted to the maximum value of the buffer minus 0.5 seconds.
|
|
26
|
+
*
|
|
27
|
+
* Default is `5` seconds.
|
|
28
|
+
*
|
|
29
|
+
* @remarks Platform: Android
|
|
30
|
+
*/
|
|
31
|
+
restartThreshold?: number;
|
|
32
|
+
/**
|
|
33
|
+
* Amount of seconds the player buffers before playback starts. This value is restricted to the
|
|
34
|
+
* maximum value of the buffer minus 0.5 seconds.
|
|
35
|
+
*
|
|
36
|
+
* Default is `2.5` seconds.
|
|
37
|
+
*
|
|
38
|
+
* @remarks Platform: Android
|
|
39
|
+
*/
|
|
40
|
+
startupThreshold?: number;
|
|
41
|
+
}
|
|
42
|
+
//# sourceMappingURL=bufferConfig.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bufferConfig.d.ts","sourceRoot":"","sources":["../src/bufferConfig.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;;;;;OAOG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,aAAa,CAAC,EAAE,qBAAqB,CAAC;IACtC;;;;;;;OAOG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;;;;OAOG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bufferConfig.js","sourceRoot":"","sources":["../src/bufferConfig.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Configures buffer target levels for different MediaTypes.\n */\nexport interface BufferMediaTypeConfig {\n /**\n * The amount of data in seconds the player tries to buffer in advance.\n *\n * iOS and tvOS, only: If set to `0`, the player will choose an appropriate forward buffer duration suitable\n * for most use-cases.\n *\n * Default value is `0` on iOS and tvOS, `50` on Android\n */\n forwardDuration?: number;\n}\n\n/**\n * Player buffer config object to configure buffering behavior.\n */\nexport interface BufferConfig {\n /**\n * Configures various settings for the audio and video buffer.\n */\n audioAndVideo?: BufferMediaTypeConfig;\n /**\n * Amount of seconds the player buffers before playback starts again after a stall. This value is\n * restricted to the maximum value of the buffer minus 0.5 seconds.\n *\n * Default is `5` seconds.\n *\n * @remarks Platform: Android\n */\n restartThreshold?: number;\n /**\n * Amount of seconds the player buffers before playback starts. This value is restricted to the\n * maximum value of the buffer minus 0.5 seconds.\n *\n * Default is `2.5` seconds.\n *\n * @remarks Platform: Android\n */\n startupThreshold?: number;\n}\n"]}
|
|
@@ -0,0 +1,310 @@
|
|
|
1
|
+
import { AdBreakFinishedEvent, AdBreakStartedEvent, AdClickedEvent, AdErrorEvent, AdFinishedEvent, AdManifestLoadedEvent, AdManifestLoadEvent, AdQuartileEvent, AdScheduledEvent, AdSkippedEvent, AdStartedEvent, CastAvailableEvent, CastPausedEvent, CastPlaybackFinishedEvent, CastPlayingEvent, CastStartedEvent, CastStartEvent, CastStoppedEvent, CastTimeUpdatedEvent, CastWaitingForDeviceEvent, DestroyEvent, Event, FullscreenEnabledEvent, FullscreenDisabledEvent, FullscreenEnterEvent, FullscreenExitEvent, MutedEvent, PausedEvent, PictureInPictureAvailabilityChangedEvent, PictureInPictureEnterEvent, PictureInPictureEnteredEvent, PictureInPictureExitEvent, PictureInPictureExitedEvent, PlaybackFinishedEvent, PlayerActiveEvent, PlayerErrorEvent, PlayerWarningEvent, PlayEvent, PlayingEvent, ReadyEvent, SeekedEvent, SeekEvent, TimeShiftEvent, TimeShiftedEvent, StallStartedEvent, StallEndedEvent, SourceErrorEvent, SourceLoadedEvent, SourceLoadEvent, SourceUnloadedEvent, SourceWarningEvent, AudioAddedEvent, AudioChangedEvent, AudioRemovedEvent, SubtitleAddedEvent, SubtitleChangedEvent, SubtitleRemovedEvent, TimeChangedEvent, UnmutedEvent, VideoPlaybackQualityChangedEvent, DownloadFinishedEvent, VideoDownloadQualityChangedEvent, PlaybackSpeedChangedEvent, CueEnterEvent, CueExitEvent } from '../../events';
|
|
2
|
+
/**
|
|
3
|
+
* Event props for `PlayerView`.
|
|
4
|
+
*
|
|
5
|
+
* Note the events of `PlayerView` are simply a proxy over
|
|
6
|
+
* the events from `NativePlayerView` just removing RN's bubbling data.
|
|
7
|
+
*/
|
|
8
|
+
export type PlayerViewEvents = {
|
|
9
|
+
/**
|
|
10
|
+
* Event emitted when an ad break has finished.
|
|
11
|
+
*/
|
|
12
|
+
onAdBreakFinished?: (event: AdBreakFinishedEvent) => void;
|
|
13
|
+
/**
|
|
14
|
+
* Event emitted when an ad break has started.
|
|
15
|
+
*/
|
|
16
|
+
onAdBreakStarted?: (event: AdBreakStartedEvent) => void;
|
|
17
|
+
/**
|
|
18
|
+
* Event emitted when an ad has been clicked.
|
|
19
|
+
*/
|
|
20
|
+
onAdClicked?: (event: AdClickedEvent) => void;
|
|
21
|
+
/**
|
|
22
|
+
* Event emitted when an ad error has occurred.
|
|
23
|
+
*/
|
|
24
|
+
onAdError?: (event: AdErrorEvent) => void;
|
|
25
|
+
/**
|
|
26
|
+
* Event emitted when an ad has finished.
|
|
27
|
+
*/
|
|
28
|
+
onAdFinished?: (event: AdFinishedEvent) => void;
|
|
29
|
+
/**
|
|
30
|
+
* Event emitted when an ad manifest starts loading.
|
|
31
|
+
*/
|
|
32
|
+
onAdManifestLoad?: (event: AdManifestLoadEvent) => void;
|
|
33
|
+
/**
|
|
34
|
+
* Event emitted when an ad manifest has been loaded.
|
|
35
|
+
*/
|
|
36
|
+
onAdManifestLoaded?: (event: AdManifestLoadedEvent) => void;
|
|
37
|
+
/**
|
|
38
|
+
* Event emitted when an ad quartile has been reached.
|
|
39
|
+
*/
|
|
40
|
+
onAdQuartile?: (event: AdQuartileEvent) => void;
|
|
41
|
+
/**
|
|
42
|
+
* Event emitted when an ad has been scheduled.
|
|
43
|
+
*/
|
|
44
|
+
onAdScheduled?: (event: AdScheduledEvent) => void;
|
|
45
|
+
/**
|
|
46
|
+
* Event emitted when an ad has been skipped.
|
|
47
|
+
*/
|
|
48
|
+
onAdSkipped?: (event: AdSkippedEvent) => void;
|
|
49
|
+
/**
|
|
50
|
+
* Event emitted when an ad has started.
|
|
51
|
+
*/
|
|
52
|
+
onAdStarted?: (event: AdStartedEvent) => void;
|
|
53
|
+
/**
|
|
54
|
+
* Event emitted when casting to a cast-compatible device is available.
|
|
55
|
+
*
|
|
56
|
+
* @remarks Platform: iOS, Android
|
|
57
|
+
*/
|
|
58
|
+
onCastAvailable?: (event: CastAvailableEvent) => void;
|
|
59
|
+
/**
|
|
60
|
+
* Event emitted when the playback on a cast-compatible device was paused.
|
|
61
|
+
*
|
|
62
|
+
* @remarks Platform: iOS, Android
|
|
63
|
+
*/
|
|
64
|
+
onCastPaused?: (event: CastPausedEvent) => void;
|
|
65
|
+
/**
|
|
66
|
+
* Event emitted when the playback on a cast-compatible device has finished.
|
|
67
|
+
*
|
|
68
|
+
* @remarks Platform: iOS, Android
|
|
69
|
+
*/
|
|
70
|
+
onCastPlaybackFinished?: (event: CastPlaybackFinishedEvent) => void;
|
|
71
|
+
/**
|
|
72
|
+
* Event emitted when playback on a cast-compatible device has started.
|
|
73
|
+
*
|
|
74
|
+
* @remarks Platform: iOS, Android
|
|
75
|
+
*/
|
|
76
|
+
onCastPlaying?: (event: CastPlayingEvent) => void;
|
|
77
|
+
/**
|
|
78
|
+
* Event emitted when the cast app is launched successfully.
|
|
79
|
+
*
|
|
80
|
+
* @remarks Platform: iOS, Android
|
|
81
|
+
*/
|
|
82
|
+
onCastStarted?: (event: CastStartedEvent) => void;
|
|
83
|
+
/**
|
|
84
|
+
* Event emitted when casting is initiated, but the user still needs to choose which device should be used.
|
|
85
|
+
*
|
|
86
|
+
* @remarks Platform: iOS, Android
|
|
87
|
+
*/
|
|
88
|
+
onCastStart?: (event: CastStartEvent) => void;
|
|
89
|
+
/**
|
|
90
|
+
* Event emitted when casting to a cast-compatible device is stopped.
|
|
91
|
+
*
|
|
92
|
+
* @remarks Platform: iOS, Android
|
|
93
|
+
*/
|
|
94
|
+
onCastStopped?: (event: CastStoppedEvent) => void;
|
|
95
|
+
/**
|
|
96
|
+
* Event emitted when the time update from the currently used cast-compatible device is received.
|
|
97
|
+
*
|
|
98
|
+
* @remarks Platform: iOS, Android
|
|
99
|
+
*/
|
|
100
|
+
onCastTimeUpdated?: (event: CastTimeUpdatedEvent) => void;
|
|
101
|
+
/**
|
|
102
|
+
* Event emitted when a cast-compatible device has been chosen and the player is waiting for the device to get ready for
|
|
103
|
+
* playback.
|
|
104
|
+
*
|
|
105
|
+
* @remarks Platform: iOS, Android
|
|
106
|
+
*/
|
|
107
|
+
onCastWaitingForDevice?: (event: CastWaitingForDeviceEvent) => void;
|
|
108
|
+
/**
|
|
109
|
+
* Event emitted when a subtitle entry transitions into the active status.
|
|
110
|
+
*/
|
|
111
|
+
onCueEnter?: (event: CueEnterEvent) => void;
|
|
112
|
+
/**
|
|
113
|
+
* Event emitted when an active subtitle entry transitions into the inactive status.
|
|
114
|
+
*/
|
|
115
|
+
onCueExit?: (event: CueExitEvent) => void;
|
|
116
|
+
/**
|
|
117
|
+
* Event emitted when the player is destroyed.
|
|
118
|
+
*/
|
|
119
|
+
onDestroy?: (event: DestroyEvent) => void;
|
|
120
|
+
/**
|
|
121
|
+
* Emitted when a download was finished.
|
|
122
|
+
*/
|
|
123
|
+
onDownloadFinished?: (event: DownloadFinishedEvent) => void;
|
|
124
|
+
/**
|
|
125
|
+
* All events emitted by the player.
|
|
126
|
+
*/
|
|
127
|
+
onEvent?: (event: Event) => void;
|
|
128
|
+
/**
|
|
129
|
+
* Event emitted when fullscreen mode has been enabled.
|
|
130
|
+
*
|
|
131
|
+
* @remarks Platform: iOS, Android
|
|
132
|
+
*/
|
|
133
|
+
onFullscreenEnabled?: (event: FullscreenEnabledEvent) => void;
|
|
134
|
+
/**
|
|
135
|
+
* Event emitted when fullscreen mode has been disabled.
|
|
136
|
+
*
|
|
137
|
+
* @remarks Platform: iOS, Android
|
|
138
|
+
*/
|
|
139
|
+
onFullscreenDisabled?: (event: FullscreenDisabledEvent) => void;
|
|
140
|
+
/**
|
|
141
|
+
* Event emitted when fullscreen mode has been entered.
|
|
142
|
+
*
|
|
143
|
+
* @remarks Platform: iOS, Android
|
|
144
|
+
*/
|
|
145
|
+
onFullscreenEnter?: (event: FullscreenEnterEvent) => void;
|
|
146
|
+
/**
|
|
147
|
+
* Event emitted when fullscreen mode has been exited.
|
|
148
|
+
*
|
|
149
|
+
* @remarks Platform: iOS, Android
|
|
150
|
+
*/
|
|
151
|
+
onFullscreenExit?: (event: FullscreenExitEvent) => void;
|
|
152
|
+
/**
|
|
153
|
+
* Event emitted when the player has been muted.
|
|
154
|
+
*/
|
|
155
|
+
onMuted?: (event: MutedEvent) => void;
|
|
156
|
+
/**
|
|
157
|
+
* Event emitted when the player has been paused.
|
|
158
|
+
*/
|
|
159
|
+
onPaused?: (event: PausedEvent) => void;
|
|
160
|
+
/**
|
|
161
|
+
* Event mitted when the availability of the Picture in Picture mode changed.
|
|
162
|
+
*/
|
|
163
|
+
onPictureInPictureAvailabilityChanged?: (event: PictureInPictureAvailabilityChangedEvent) => void;
|
|
164
|
+
/**
|
|
165
|
+
* Event emitted when the player enters Picture in Picture mode.
|
|
166
|
+
*/
|
|
167
|
+
onPictureInPictureEnter?: (event: PictureInPictureEnterEvent) => void;
|
|
168
|
+
/**
|
|
169
|
+
* Event emitted when the player entered Picture in Picture mode.
|
|
170
|
+
*
|
|
171
|
+
* @remarks Platform: iOS
|
|
172
|
+
*/
|
|
173
|
+
onPictureInPictureEntered?: (event: PictureInPictureEnteredEvent) => void;
|
|
174
|
+
/**
|
|
175
|
+
* Event emitted when the player exits Picture in Picture mode.
|
|
176
|
+
*/
|
|
177
|
+
onPictureInPictureExit?: (event: PictureInPictureExitEvent) => void;
|
|
178
|
+
/**
|
|
179
|
+
* Event emitted when the player exited Picture in Picture mode.
|
|
180
|
+
*
|
|
181
|
+
* @remarks Platform: iOS
|
|
182
|
+
*/
|
|
183
|
+
onPictureInPictureExited?: (event: PictureInPictureExitedEvent) => void;
|
|
184
|
+
/**
|
|
185
|
+
* Event emitted when the player received an intention to start/resume playback.
|
|
186
|
+
*/
|
|
187
|
+
onPlay?: (event: PlayEvent) => void;
|
|
188
|
+
/**
|
|
189
|
+
* Event emitted when the playback of the current media has finished.
|
|
190
|
+
*/
|
|
191
|
+
onPlaybackFinished?: (event: PlaybackFinishedEvent) => void;
|
|
192
|
+
/**
|
|
193
|
+
* Emitted when the player transitions from one playback speed to another.
|
|
194
|
+
* @remarks Platform: iOS, tvOS
|
|
195
|
+
*/
|
|
196
|
+
onPlaybackSpeedChanged?: (event: PlaybackSpeedChangedEvent) => void;
|
|
197
|
+
/**
|
|
198
|
+
* Event emitted when a source is loaded into the player.
|
|
199
|
+
* Seeking and time shifting are allowed as soon as this event is seen.
|
|
200
|
+
*/
|
|
201
|
+
onPlayerActive?: (event: PlayerActiveEvent) => void;
|
|
202
|
+
/**
|
|
203
|
+
* Event Emitted when a player error occurred.
|
|
204
|
+
*/
|
|
205
|
+
onPlayerError?: (event: PlayerErrorEvent) => void;
|
|
206
|
+
/**
|
|
207
|
+
* Event emitted when a player warning occurred.
|
|
208
|
+
*/
|
|
209
|
+
onPlayerWarning?: (event: PlayerWarningEvent) => void;
|
|
210
|
+
/**
|
|
211
|
+
* Emitted when playback has started.
|
|
212
|
+
*/
|
|
213
|
+
onPlaying?: (event: PlayingEvent) => void;
|
|
214
|
+
/**
|
|
215
|
+
* Emitted when the player is ready for immediate playback, because initial audio/video
|
|
216
|
+
* has been downloaded.
|
|
217
|
+
*/
|
|
218
|
+
onReady?: (event: ReadyEvent) => void;
|
|
219
|
+
/**
|
|
220
|
+
* Event emitted when the player is about to seek to a new position.
|
|
221
|
+
* Only applies to VoD streams.
|
|
222
|
+
*/
|
|
223
|
+
onSeek?: (event: SeekEvent) => void;
|
|
224
|
+
/**
|
|
225
|
+
* Event emitted when seeking has finished and data to continue playback is available.
|
|
226
|
+
* Only applies to VoD streams.
|
|
227
|
+
*/
|
|
228
|
+
onSeeked?: (event: SeekedEvent) => void;
|
|
229
|
+
/**
|
|
230
|
+
* Event mitted when the player starts time shifting.
|
|
231
|
+
* Only applies to live streams.
|
|
232
|
+
*/
|
|
233
|
+
onTimeShift?: (event: TimeShiftEvent) => void;
|
|
234
|
+
/**
|
|
235
|
+
* Event emitted when time shifting has finished and data is available to continue playback.
|
|
236
|
+
* Only applies to live streams.
|
|
237
|
+
*/
|
|
238
|
+
onTimeShifted?: (event: TimeShiftedEvent) => void;
|
|
239
|
+
/**
|
|
240
|
+
* Event emitted when the player begins to stall and to buffer due to an empty buffer.
|
|
241
|
+
*/
|
|
242
|
+
onStallStarted?: (event: StallStartedEvent) => void;
|
|
243
|
+
/**
|
|
244
|
+
* Event emitted when the player ends stalling, due to enough data in the buffer.
|
|
245
|
+
*/
|
|
246
|
+
onStallEnded?: (event: StallEndedEvent) => void;
|
|
247
|
+
/**
|
|
248
|
+
* Event emitted when a source error occurred.
|
|
249
|
+
*/
|
|
250
|
+
onSourceError?: (event: SourceErrorEvent) => void;
|
|
251
|
+
/**
|
|
252
|
+
* Event emitted when a new source loading has started.
|
|
253
|
+
*/
|
|
254
|
+
onSourceLoad?: (event: SourceLoadEvent) => void;
|
|
255
|
+
/**
|
|
256
|
+
* Event emitted when a new source is loaded.
|
|
257
|
+
* This does not mean that the source is immediately ready for playback.
|
|
258
|
+
* `ReadyEvent` indicates the player is ready for immediate playback.
|
|
259
|
+
*/
|
|
260
|
+
onSourceLoaded?: (event: SourceLoadedEvent) => void;
|
|
261
|
+
/**
|
|
262
|
+
* Event emitted when the current source has been unloaded.
|
|
263
|
+
*/
|
|
264
|
+
onSourceUnloaded?: (event: SourceUnloadedEvent) => void;
|
|
265
|
+
/**
|
|
266
|
+
* Event emitted when a source warning occurred.
|
|
267
|
+
*/
|
|
268
|
+
onSourceWarning?: (event: SourceWarningEvent) => void;
|
|
269
|
+
/**
|
|
270
|
+
* Event emitted when a new audio track is added to the player.
|
|
271
|
+
*/
|
|
272
|
+
onAudioAdded?: (event: AudioAddedEvent) => void;
|
|
273
|
+
/**
|
|
274
|
+
* Event emitted when the player's selected audio track has changed.
|
|
275
|
+
*/
|
|
276
|
+
onAudioChanged?: (event: AudioChangedEvent) => void;
|
|
277
|
+
/**
|
|
278
|
+
* Event emitted when an audio track is removed from the player.
|
|
279
|
+
*/
|
|
280
|
+
onAudioRemoved?: (event: AudioRemovedEvent) => void;
|
|
281
|
+
/**
|
|
282
|
+
* Event emitted when a new subtitle track is added to the player.
|
|
283
|
+
*/
|
|
284
|
+
onSubtitleAdded?: (event: SubtitleAddedEvent) => void;
|
|
285
|
+
/**
|
|
286
|
+
* Event emitted when the player's selected subtitle track has changed.
|
|
287
|
+
*/
|
|
288
|
+
onSubtitleChanged?: (event: SubtitleChangedEvent) => void;
|
|
289
|
+
/**
|
|
290
|
+
* Event emitted when a subtitle track is removed from the player.
|
|
291
|
+
*/
|
|
292
|
+
onSubtitleRemoved?: (event: SubtitleRemovedEvent) => void;
|
|
293
|
+
/**
|
|
294
|
+
* Event emitted when the current playback time has changed.
|
|
295
|
+
*/
|
|
296
|
+
onTimeChanged?: (event: TimeChangedEvent) => void;
|
|
297
|
+
/**
|
|
298
|
+
* Emitted when the player is unmuted.
|
|
299
|
+
*/
|
|
300
|
+
onUnmuted?: (event: UnmutedEvent) => void;
|
|
301
|
+
/**
|
|
302
|
+
* Emitted when current video download quality has changed.
|
|
303
|
+
*/
|
|
304
|
+
onVideoDownloadQualityChanged?: (event: VideoDownloadQualityChangedEvent) => void;
|
|
305
|
+
/**
|
|
306
|
+
* Emitted when the current video playback quality has changed.
|
|
307
|
+
*/
|
|
308
|
+
onVideoPlaybackQualityChanged?: (event: VideoPlaybackQualityChangedEvent) => void;
|
|
309
|
+
};
|
|
310
|
+
//# sourceMappingURL=events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../../src/components/PlayerView/events.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,mBAAmB,EACnB,cAAc,EACd,YAAY,EACZ,eAAe,EACf,qBAAqB,EACrB,mBAAmB,EACnB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,yBAAyB,EACzB,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,oBAAoB,EACpB,yBAAyB,EACzB,YAAY,EACZ,KAAK,EACL,sBAAsB,EACtB,uBAAuB,EACvB,oBAAoB,EACpB,mBAAmB,EACnB,UAAU,EACV,WAAW,EACX,wCAAwC,EACxC,0BAA0B,EAC1B,4BAA4B,EAC5B,yBAAyB,EACzB,2BAA2B,EAC3B,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,SAAS,EACT,YAAY,EACZ,UAAU,EACV,WAAW,EACX,SAAS,EACT,cAAc,EACd,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EACf,iBAAiB,EACjB,iBAAiB,EACjB,kBAAkB,EAClB,oBAAoB,EACp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AC;IACpD;;OAEG;IACH,eAAe,CAAC,EAAE,CAAC,KAAK,EAAE,kBAAkB,KAAK,IAAI,CAAC;IACtD;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,KAAK,IAAI,CAAC;IAC1D;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,KAAK,IAAI,CAAC;IAC1D;;OAEG;IACH,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,gBAAgB,KAAK,IAAI,CAAC;IAClD;;OAEG;IACH,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAC1C;;OAEG;IACH,6BAA6B,CAAC,EAAE,CAC9B,KAAK,EAAE,gCAAgC,KACpC,IAAI,CAAC;IACV;;OAEG;IACH,6BAA6B,CAAC,EAAE,CAC9B,KAAK,EAAE,gCAAgC,KACpC,IAAI,CAAC;CACX,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../../src/components/PlayerView/events.ts"],"names":[],"mappings":"","sourcesContent":["import {\n AdBreakFinishedEvent,\n AdBreakStartedEvent,\n AdClickedEvent,\n AdErrorEvent,\n AdFinishedEvent,\n AdManifestLoadedEvent,\n AdManifestLoadEvent,\n AdQuartileEvent,\n AdScheduledEvent,\n AdSkippedEvent,\n AdStartedEvent,\n CastAvailableEvent,\n CastPausedEvent,\n CastPlaybackFinishedEvent,\n CastPlayingEvent,\n CastStartedEvent,\n CastStartEvent,\n CastStoppedEvent,\n CastTimeUpdatedEvent,\n CastWaitingForDeviceEvent,\n DestroyEvent,\n Event,\n FullscreenEnabledEvent,\n FullscreenDisabledEvent,\n FullscreenEnterEvent,\n FullscreenExitEvent,\n MutedEvent,\n PausedEvent,\n PictureInPictureAvailabilityChangedEvent,\n PictureInPictureEnterEvent,\n PictureInPictureEnteredEvent,\n PictureInPictureExitEvent,\n PictureInPictureExitedEvent,\n PlaybackFinishedEvent,\n PlayerActiveEvent,\n PlayerErrorEvent,\n PlayerWarningEvent,\n PlayEvent,\n PlayingEvent,\n ReadyEvent,\n SeekedEvent,\n SeekEvent,\n TimeShiftEvent,\n TimeShiftedEvent,\n StallStartedEvent,\n StallEndedEvent,\n SourceErrorEvent,\n SourceLoadedEvent,\n SourceLoadEvent,\n SourceUnloadedEvent,\n SourceWarningEvent,\n AudioAddedEvent,\n AudioChangedEvent,\n AudioRemovedEvent,\n SubtitleAddedEvent,\n SubtitleChangedEvent,\n SubtitleRemovedEvent,\n TimeChangedEvent,\n UnmutedEvent,\n VideoPlaybackQualityChangedEvent,\n DownloadFinishedEvent,\n VideoDownloadQualityChangedEvent,\n PlaybackSpeedChangedEvent,\n CueEnterEvent,\n CueExitEvent,\n} from '../../events';\n\n/**\n * Event props for `PlayerView`.\n *\n * Note the events of `PlayerView` are simply a proxy over\n * the events from `NativePlayerView` just removing RN's bubbling data.\n */\nexport type PlayerViewEvents = {\n /**\n * Event emitted when an ad break has finished.\n */\n onAdBreakFinished?: (event: AdBreakFinishedEvent) => void;\n /**\n * Event emitted when an ad break has started.\n */\n onAdBreakStarted?: (event: AdBreakStartedEvent) => void;\n /**\n * Event emitted when an ad has been clicked.\n */\n onAdClicked?: (event: AdClickedEvent) => void;\n /**\n * Event emitted when an ad error has occurred.\n */\n onAdError?: (event: AdErrorEvent) => void;\n /**\n * Event emitted when an ad has finished.\n */\n onAdFinished?: (event: AdFinishedEvent) => void;\n /**\n * Event emitted when an ad manifest starts loading.\n */\n onAdManifestLoad?: (event: AdManifestLoadEvent) => void;\n /**\n * Event emitted when an ad manifest has been loaded.\n */\n onAdManifestLoaded?: (event: AdManifestLoadedEvent) => void;\n /**\n * Event emitted when an ad quartile has been reached.\n */\n onAdQuartile?: (event: AdQuartileEvent) => void;\n /**\n * Event emitted when an ad has been scheduled.\n */\n onAdScheduled?: (event: AdScheduledEvent) => void;\n /**\n * Event emitted when an ad has been skipped.\n */\n onAdSkipped?: (event: AdSkippedEvent) => void;\n /**\n * Event emitted when an ad has started.\n */\n onAdStarted?: (event: AdStartedEvent) => void;\n /**\n * Event emitted when casting to a cast-compatible device is available.\n *\n * @remarks Platform: iOS, Android\n */\n onCastAvailable?: (event: CastAvailableEvent) => void;\n /**\n * Event emitted when the playback on a cast-compatible device was paused.\n *\n * @remarks Platform: iOS, Android\n */\n onCastPaused?: (event: CastPausedEvent) => void;\n /**\n * Event emitted when the playback on a cast-compatible device has finished.\n *\n * @remarks Platform: iOS, Android\n */\n onCastPlaybackFinished?: (event: CastPlaybackFinishedEvent) => void;\n /**\n * Event emitted when playback on a cast-compatible device has started.\n *\n * @remarks Platform: iOS, Android\n */\n onCastPlaying?: (event: CastPlayingEvent) => void;\n /**\n * Event emitted when the cast app is launched successfully.\n *\n * @remarks Platform: iOS, Android\n */\n onCastStarted?: (event: CastStartedEvent) => void;\n /**\n * Event emitted when casting is initiated, but the user still needs to choose which device should be used.\n *\n * @remarks Platform: iOS, Android\n */\n onCastStart?: (event: CastStartEvent) => void;\n /**\n * Event emitted when casting to a cast-compatible device is stopped.\n *\n * @remarks Platform: iOS, Android\n */\n onCastStopped?: (event: CastStoppedEvent) => void;\n /**\n * Event emitted when the time update from the currently used cast-compatible device is received.\n *\n * @remarks Platform: iOS, Android\n */\n onCastTimeUpdated?: (event: CastTimeUpdatedEvent) => void;\n /**\n * Event emitted when a cast-compatible device has been chosen and the player is waiting for the device to get ready for\n * playback.\n *\n * @remarks Platform: iOS, Android\n */\n onCastWaitingForDevice?: (event: CastWaitingForDeviceEvent) => void;\n /**\n * Event emitted when a subtitle entry transitions into the active status.\n */\n onCueEnter?: (event: CueEnterEvent) => void;\n /**\n * Event emitted when an active subtitle entry transitions into the inactive status.\n */\n onCueExit?: (event: CueExitEvent) => void;\n /**\n * Event emitted when the player is destroyed.\n */\n onDestroy?: (event: DestroyEvent) => void;\n /**\n * Emitted when a download was finished.\n */\n onDownloadFinished?: (event: DownloadFinishedEvent) => void;\n /**\n * All events emitted by the player.\n */\n onEvent?: (event: Event) => void;\n /**\n * Event emitted when fullscreen mode has been enabled.\n *\n * @remarks Platform: iOS, Android\n */\n onFullscreenEnabled?: (event: FullscreenEnabledEvent) => void;\n /**\n * Event emitted when fullscreen mode has been disabled.\n *\n * @remarks Platform: iOS, Android\n */\n onFullscreenDisabled?: (event: FullscreenDisabledEvent) => void;\n /**\n * Event emitted when fullscreen mode has been entered.\n *\n * @remarks Platform: iOS, Android\n */\n onFullscreenEnter?: (event: FullscreenEnterEvent) => void;\n /**\n * Event emitted when fullscreen mode has been exited.\n *\n * @remarks Platform: iOS, Android\n */\n onFullscreenExit?: (event: FullscreenExitEvent) => void;\n /**\n * Event emitted when the player has been muted.\n */\n onMuted?: (event: MutedEvent) => void;\n /**\n * Event emitted when the player has been paused.\n */\n onPaused?: (event: PausedEvent) => void;\n /**\n * Event mitted when the availability of the Picture in Picture mode changed.\n */\n onPictureInPictureAvailabilityChanged?: (\n event: PictureInPictureAvailabilityChangedEvent\n ) => void;\n /**\n * Event emitted when the player enters Picture in Picture mode.\n */\n onPictureInPictureEnter?: (event: PictureInPictureEnterEvent) => void;\n /**\n * Event emitted when the player entered Picture in Picture mode.\n *\n * @remarks Platform: iOS\n */\n onPictureInPictureEntered?: (event: PictureInPictureEnteredEvent) => void;\n /**\n * Event emitted when the player exits Picture in Picture mode.\n */\n onPictureInPictureExit?: (event: PictureInPictureExitEvent) => void;\n /**\n * Event emitted when the player exited Picture in Picture mode.\n *\n * @remarks Platform: iOS\n */\n onPictureInPictureExited?: (event: PictureInPictureExitedEvent) => void;\n /**\n * Event emitted when the player received an intention to start/resume playback.\n */\n onPlay?: (event: PlayEvent) => void;\n /**\n * Event emitted when the playback of the current media has finished.\n */\n onPlaybackFinished?: (event: PlaybackFinishedEvent) => void;\n /**\n * Emitted when the player transitions from one playback speed to another.\n * @remarks Platform: iOS, tvOS\n */\n onPlaybackSpeedChanged?: (event: PlaybackSpeedChangedEvent) => void;\n /**\n * Event emitted when a source is loaded into the player.\n * Seeking and time shifting are allowed as soon as this event is seen.\n */\n onPlayerActive?: (event: PlayerActiveEvent) => void;\n /**\n * Event Emitted when a player error occurred.\n */\n onPlayerError?: (event: PlayerErrorEvent) => void;\n /**\n * Event emitted when a player warning occurred.\n */\n onPlayerWarning?: (event: PlayerWarningEvent) => void;\n /**\n * Emitted when playback has started.\n */\n onPlaying?: (event: PlayingEvent) => void;\n /**\n * Emitted when the player is ready for immediate playback, because initial audio/video\n * has been downloaded.\n */\n onReady?: (event: ReadyEvent) => void;\n /**\n * Event emitted when the player is about to seek to a new position.\n * Only applies to VoD streams.\n */\n onSeek?: (event: SeekEvent) => void;\n /**\n * Event emitted when seeking has finished and data to continue playback is available.\n * Only applies to VoD streams.\n */\n onSeeked?: (event: SeekedEvent) => void;\n /**\n * Event mitted when the player starts time shifting.\n * Only applies to live streams.\n */\n onTimeShift?: (event: TimeShiftEvent) => void;\n /**\n * Event emitted when time shifting has finished and data is available to continue playback.\n * Only applies to live streams.\n */\n onTimeShifted?: (event: TimeShiftedEvent) => void;\n /**\n * Event emitted when the player begins to stall and to buffer due to an empty buffer.\n */\n onStallStarted?: (event: StallStartedEvent) => void;\n /**\n * Event emitted when the player ends stalling, due to enough data in the buffer.\n */\n onStallEnded?: (event: StallEndedEvent) => void;\n /**\n * Event emitted when a source error occurred.\n */\n onSourceError?: (event: SourceErrorEvent) => void;\n /**\n * Event emitted when a new source loading has started.\n */\n onSourceLoad?: (event: SourceLoadEvent) => void;\n /**\n * Event emitted when a new source is loaded.\n * This does not mean that the source is immediately ready for playback.\n * `ReadyEvent` indicates the player is ready for immediate playback.\n */\n onSourceLoaded?: (event: SourceLoadedEvent) => void;\n /**\n * Event emitted when the current source has been unloaded.\n */\n onSourceUnloaded?: (event: SourceUnloadedEvent) => void;\n /**\n * Event emitted when a source warning occurred.\n */\n onSourceWarning?: (event: SourceWarningEvent) => void;\n /**\n * Event emitted when a new audio track is added to the player.\n */\n onAudioAdded?: (event: AudioAddedEvent) => void;\n /**\n * Event emitted when the player's selected audio track has changed.\n */\n onAudioChanged?: (event: AudioChangedEvent) => void;\n /**\n * Event emitted when an audio track is removed from the player.\n */\n onAudioRemoved?: (event: AudioRemovedEvent) => void;\n /**\n * Event emitted when a new subtitle track is added to the player.\n */\n onSubtitleAdded?: (event: SubtitleAddedEvent) => void;\n /**\n * Event emitted when the player's selected subtitle track has changed.\n */\n onSubtitleChanged?: (event: SubtitleChangedEvent) => void;\n /**\n * Event emitted when a subtitle track is removed from the player.\n */\n onSubtitleRemoved?: (event: SubtitleRemovedEvent) => void;\n /**\n * Event emitted when the current playback time has changed.\n */\n onTimeChanged?: (event: TimeChangedEvent) => void;\n /**\n * Emitted when the player is unmuted.\n */\n onUnmuted?: (event: UnmutedEvent) => void;\n /**\n * Emitted when current video download quality has changed.\n */\n onVideoDownloadQualityChanged?: (\n event: VideoDownloadQualityChangedEvent\n ) => void;\n /**\n * Emitted when the current video playback quality has changed.\n */\n onVideoPlaybackQualityChanged?: (\n event: VideoPlaybackQualityChangedEvent\n ) => void;\n};\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { PlayerViewProps } from './properties';
|
|
3
|
+
/**
|
|
4
|
+
* Component that provides the Bitmovin Player UI and default UI handling to an attached `Player` instance.
|
|
5
|
+
* This component needs a `Player` instance to work properly so make sure one is passed to it as a prop.
|
|
6
|
+
*
|
|
7
|
+
* @param options configuration options
|
|
8
|
+
*/
|
|
9
|
+
export declare function PlayerView({ viewRef, style, player, config, fullscreenHandler, customMessageHandler, isFullscreenRequested, scalingMode, isPictureInPictureRequested, ...props }: PlayerViewProps): false | React.JSX.Element;
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/PlayerView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAO3D,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAW/C;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,EACzB,OAAO,EACP,KAAK,EACL,MAAM,EACN,MAAM,EACN,iBAAiB,EACjB,oBAAoB,EACpB,qBAA6B,EAC7B,WAAW,EACX,2BAAmC,EACnC,GAAG,KAAK,EACT,EAAE,eAAe,6BAqJjB"}
|