react-native-theoplayer 1.0.0 → 1.3.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.
Files changed (379) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +54 -18
  3. package/android/.gradle/7.0.2/dependencies-accessors/dependencies-accessors.lock +0 -0
  4. package/android/.gradle/7.0.2/dependencies-accessors/gc.properties +0 -0
  5. package/android/.gradle/7.0.2/executionHistory/executionHistory.lock +0 -0
  6. package/android/.gradle/7.0.2/fileChanges/last-build.bin +0 -0
  7. package/android/.gradle/7.0.2/fileHashes/fileHashes.bin +0 -0
  8. package/android/.gradle/7.0.2/fileHashes/fileHashes.lock +0 -0
  9. package/android/.gradle/7.0.2/gc.properties +0 -0
  10. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  11. package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
  12. package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  13. package/android/.gradle/checksums/checksums.lock +0 -0
  14. package/android/.gradle/checksums/md5-checksums.bin +0 -0
  15. package/android/.gradle/checksums/sha1-checksums.bin +0 -0
  16. package/android/.gradle/vcs-1/gc.properties +0 -0
  17. package/android/.idea/compiler.xml +6 -0
  18. package/android/.idea/gradle.xml +18 -0
  19. package/android/.idea/jarRepositories.xml +40 -0
  20. package/android/.idea/libraries/Gradle__androidx_activity_activity_1_1_0_aar.xml +13 -0
  21. package/android/.idea/libraries/Gradle__androidx_annotation_annotation_1_2_0.xml +11 -0
  22. package/android/.idea/libraries/Gradle__androidx_appcompat_appcompat_1_1_0_aar.xml +16 -0
  23. package/android/.idea/libraries/Gradle__androidx_appcompat_appcompat_resources_1_1_0_aar.xml +13 -0
  24. package/android/.idea/libraries/Gradle__androidx_arch_core_core_common_2_1_0.xml +11 -0
  25. package/android/.idea/libraries/Gradle__androidx_arch_core_core_runtime_2_1_0_aar.xml +13 -0
  26. package/android/.idea/libraries/Gradle__androidx_asynclayoutinflater_asynclayoutinflater_1_0_0_aar.xml +13 -0
  27. package/android/.idea/libraries/Gradle__androidx_browser_browser_1_3_0_aar.xml +16 -0
  28. package/android/.idea/libraries/Gradle__androidx_collection_collection_1_1_0.xml +11 -0
  29. package/android/.idea/libraries/Gradle__androidx_coordinatorlayout_coordinatorlayout_1_0_0_aar.xml +16 -0
  30. package/android/.idea/libraries/Gradle__androidx_core_core_1_2_0_aar.xml +16 -0
  31. package/android/.idea/libraries/Gradle__androidx_cursoradapter_cursoradapter_1_0_0_aar.xml +13 -0
  32. package/android/.idea/libraries/Gradle__androidx_customview_customview_1_0_0_aar.xml +13 -0
  33. package/android/.idea/libraries/Gradle__androidx_documentfile_documentfile_1_0_0_aar.xml +13 -0
  34. package/android/.idea/libraries/Gradle__androidx_drawerlayout_drawerlayout_1_0_0_aar.xml +16 -0
  35. package/android/.idea/libraries/Gradle__androidx_fragment_fragment_1_2_4_aar.xml +16 -0
  36. package/android/.idea/libraries/Gradle__androidx_interpolator_interpolator_1_0_0_aar.xml +13 -0
  37. package/android/.idea/libraries/Gradle__androidx_legacy_legacy_support_core_ui_1_0_0_aar.xml +13 -0
  38. package/android/.idea/libraries/Gradle__androidx_legacy_legacy_support_core_utils_1_0_0_aar.xml +13 -0
  39. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_common_2_2_0.xml +11 -0
  40. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_2_0_0_aar.xml +13 -0
  41. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_core_2_2_0_aar.xml +13 -0
  42. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_runtime_2_2_0_aar.xml +13 -0
  43. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_viewmodel_2_2_0_aar.xml +13 -0
  44. package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_viewmodel_savedstate_2_2_0_aar.xml +13 -0
  45. package/android/.idea/libraries/Gradle__androidx_loader_loader_1_0_0_aar.xml +13 -0
  46. package/android/.idea/libraries/Gradle__androidx_localbroadcastmanager_localbroadcastmanager_1_0_0_aar.xml +13 -0
  47. package/android/.idea/libraries/Gradle__androidx_preference_preference_1_1_1_aar.xml +13 -0
  48. package/android/.idea/libraries/Gradle__androidx_print_print_1_0_0_aar.xml +16 -0
  49. package/android/.idea/libraries/Gradle__androidx_recyclerview_recyclerview_1_0_0_aar.xml +16 -0
  50. package/android/.idea/libraries/Gradle__androidx_savedstate_savedstate_1_0_0_aar.xml +13 -0
  51. package/android/.idea/libraries/Gradle__androidx_slidingpanelayout_slidingpanelayout_1_0_0_aar.xml +13 -0
  52. package/android/.idea/libraries/Gradle__androidx_swiperefreshlayout_swiperefreshlayout_1_0_0_aar.xml +16 -0
  53. package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_1_1_0_aar.xml +13 -0
  54. package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_animated_1_1_0_aar.xml +13 -0
  55. package/android/.idea/libraries/Gradle__androidx_versionedparcelable_versionedparcelable_1_1_0_aar.xml +13 -0
  56. package/android/.idea/libraries/Gradle__androidx_viewpager_viewpager_1_0_0_aar.xml +13 -0
  57. package/android/.idea/libraries/Gradle__com_facebook_fbjni_fbjni_java_only_0_0_3.xml +13 -0
  58. package/android/.idea/libraries/Gradle__com_facebook_fresco_drawee_2_0_0_aar.xml +15 -0
  59. package/android/.idea/libraries/Gradle__com_facebook_fresco_fbcore_2_0_0_aar.xml +18 -0
  60. package/android/.idea/libraries/Gradle__com_facebook_fresco_fresco_2_0_0_aar.xml +18 -0
  61. package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_2_0_0_aar.xml +18 -0
  62. package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_base_2_0_0_aar.xml +18 -0
  63. package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_okhttp3_2_0_0_aar.xml +15 -0
  64. package/android/.idea/libraries/Gradle__com_facebook_fresco_nativeimagefilters_2_0_0_aar.xml +15 -0
  65. package/android/.idea/libraries/Gradle__com_facebook_fresco_nativeimagetranscoder_2_0_0_aar.xml +15 -0
  66. package/android/.idea/libraries/Gradle__com_facebook_infer_annotation_infer_annotation_0_11_2.xml +13 -0
  67. package/android/.idea/libraries/Gradle__com_facebook_react_react_native_0_64_2_aar.xml +18 -0
  68. package/android/.idea/libraries/Gradle__com_facebook_soloader_annotation_0_9_0.xml +13 -0
  69. package/android/.idea/libraries/Gradle__com_facebook_soloader_nativeloader_0_9_0.xml +13 -0
  70. package/android/.idea/libraries/Gradle__com_facebook_soloader_soloader_0_9_0_aar.xml +15 -0
  71. package/android/.idea/libraries/Gradle__com_facebook_yoga_proguard_annotations_1_14_1.xml +13 -0
  72. package/android/.idea/libraries/Gradle__com_google_ads_interactivemedia_v3_interactivemedia_3_25_1.xml +9 -0
  73. package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_ads_identifier_17_1_0_aar.xml +13 -0
  74. package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_appset_16_0_0_aar.xml +13 -0
  75. package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_base_17_6_0_aar.xml +13 -0
  76. package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_basement_17_6_0_aar.xml +13 -0
  77. package/android/.idea/libraries/Gradle__com_google_android_gms_play_services_tasks_17_2_1_aar.xml +13 -0
  78. package/android/.idea/libraries/Gradle__com_google_code_findbugs_jsr305_3_0_2.xml +13 -0
  79. package/android/.idea/libraries/Gradle__com_google_code_gson_gson_2_8_2.xml +13 -0
  80. package/android/.idea/libraries/Gradle__com_google_guava_listenablefuture_1_0.xml +13 -0
  81. package/android/.idea/libraries/Gradle__com_squareup_okhttp3_okhttp_3_12_12.xml +13 -0
  82. package/android/.idea/libraries/Gradle__com_squareup_okhttp3_okhttp_urlconnection_3_12_12.xml +13 -0
  83. package/android/.idea/libraries/Gradle__com_squareup_okio_okio_1_17_5.xml +13 -0
  84. package/android/.idea/libraries/Gradle__com_theoplayer_theoplayer_sdk_android_unified_3_6_1_aar.xml +12 -0
  85. package/android/.idea/libraries/Gradle__com_theoplayer_theoplayer_sdk_android_unified_ads_3_6_1_aar.xml +11 -0
  86. package/android/.idea/libraries/Gradle__com_theoplayer_theoplayer_sdk_android_unified_ads_ima_3_6_1_aar.xml +11 -0
  87. package/android/.idea/libraries/Gradle__javax_inject_javax_inject_1.xml +13 -0
  88. package/android/.idea/misc.xml +9 -0
  89. package/android/.idea/modules/android.androidTest.iml +105 -0
  90. package/android/.idea/modules/android.iml +40 -0
  91. package/android/.idea/modules/android.main.iml +113 -0
  92. package/android/.idea/modules/android.unitTest.iml +100 -0
  93. package/android/.idea/modules.xml +11 -0
  94. package/android/.idea/vcs.xml +6 -0
  95. package/android/build.gradle +89 -0
  96. package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  97. package/android/gradle/wrapper/gradle-wrapper.properties +5 -0
  98. package/android/gradlew +185 -0
  99. package/android/gradlew.bat +89 -0
  100. package/android/local.properties +8 -0
  101. package/android/src/main/AndroidManifest.xml +6 -0
  102. package/android/src/main/java/com/theoplayer/PlayerConfigHelper.java +30 -0
  103. package/android/src/main/java/com/theoplayer/ReactTHEOplayerPackage.java +27 -0
  104. package/android/src/main/java/com/theoplayer/ReactTHEOplayerView.java +420 -0
  105. package/android/src/main/java/com/theoplayer/ReactTHEOplayerViewManager.java +114 -0
  106. package/android/src/main/java/com/theoplayer/SourceHelper.java +224 -0
  107. package/android/src/main/java/com/theoplayer/TimeUpdateRate.java +8 -0
  108. package/android/src/main/java/com/theoplayer/VideoEventEmitter.java +410 -0
  109. package/android/src/main/java/com/theoplayer/track/TextTrackCueEventType.java +11 -0
  110. package/android/src/main/java/com/theoplayer/track/TrackEventType.java +11 -0
  111. package/android/src/main/java/com/theoplayer/track/TrackListInfo.java +204 -0
  112. package/ios/THEOplayerRCTBridge.m +46 -0
  113. package/ios/THEOplayerRCTDebug.swift +16 -0
  114. package/ios/THEOplayerRCTMetadataAggregator.swift +169 -0
  115. package/ios/THEOplayerRCTView.swift +423 -0
  116. package/ios/THEOplayerRCTViewEventHandler.swift +493 -0
  117. package/ios/THEOplayerRCTViewManager.swift +23 -0
  118. package/ios/Theoplayer-Bridging-Header.h +5 -0
  119. package/ios/Theoplayer.xcodeproj/project.pbxproj +296 -0
  120. package/lib/commonjs/api/THEOplayerView.js +6 -0
  121. package/lib/commonjs/api/THEOplayerView.js.map +1 -0
  122. package/lib/commonjs/api/barrel.js +97 -0
  123. package/lib/commonjs/api/barrel.js.map +1 -0
  124. package/lib/commonjs/api/config/PlayerConfiguration.js +2 -0
  125. package/lib/commonjs/api/config/PlayerConfiguration.js.map +1 -0
  126. package/lib/commonjs/api/config/barrel.js +19 -0
  127. package/lib/commonjs/api/config/barrel.js.map +1 -0
  128. package/lib/commonjs/api/error/PlayerError.js +2 -0
  129. package/lib/commonjs/api/error/PlayerError.js.map +1 -0
  130. package/lib/commonjs/api/error/barrel.js +19 -0
  131. package/lib/commonjs/api/error/barrel.js.map +1 -0
  132. package/lib/commonjs/api/event/PlayerEvent.js +6 -0
  133. package/lib/commonjs/api/event/PlayerEvent.js.map +1 -0
  134. package/lib/commonjs/api/event/TrackEvent.js +22 -0
  135. package/lib/commonjs/api/event/TrackEvent.js.map +1 -0
  136. package/lib/commonjs/api/event/barrel.js +32 -0
  137. package/lib/commonjs/api/event/barrel.js.map +1 -0
  138. package/lib/commonjs/api/source/SourceDescription.js +6 -0
  139. package/lib/commonjs/api/source/SourceDescription.js.map +1 -0
  140. package/lib/commonjs/api/source/ads/Ads.js +2 -0
  141. package/lib/commonjs/api/source/ads/Ads.js.map +1 -0
  142. package/lib/commonjs/api/source/barrel.js +58 -0
  143. package/lib/commonjs/api/source/barrel.js.map +1 -0
  144. package/lib/commonjs/api/source/dash/DashPlaybackConfiguration.js +2 -0
  145. package/lib/commonjs/api/source/dash/DashPlaybackConfiguration.js.map +1 -0
  146. package/lib/commonjs/api/source/dash/barrel.js +19 -0
  147. package/lib/commonjs/api/source/dash/barrel.js.map +1 -0
  148. package/lib/commonjs/api/source/drm/DRMConfiguration.js +2 -0
  149. package/lib/commonjs/api/source/drm/DRMConfiguration.js.map +1 -0
  150. package/lib/commonjs/api/source/drm/barrel.js +19 -0
  151. package/lib/commonjs/api/source/drm/barrel.js.map +1 -0
  152. package/lib/commonjs/api/source/hls/HlsPlaybackConfiguration.js +2 -0
  153. package/lib/commonjs/api/source/hls/HlsPlaybackConfiguration.js.map +1 -0
  154. package/lib/commonjs/api/source/hls/barrel.js +19 -0
  155. package/lib/commonjs/api/source/hls/barrel.js.map +1 -0
  156. package/lib/commonjs/api/timeranges/TimeRange.js +2 -0
  157. package/lib/commonjs/api/timeranges/TimeRange.js.map +1 -0
  158. package/lib/commonjs/api/timeranges/barrel.js +19 -0
  159. package/lib/commonjs/api/timeranges/barrel.js.map +1 -0
  160. package/lib/commonjs/api/track/MediaTrack.js +6 -0
  161. package/lib/commonjs/api/track/MediaTrack.js.map +1 -0
  162. package/lib/commonjs/api/track/Quality.js +2 -0
  163. package/lib/commonjs/api/track/Quality.js.map +1 -0
  164. package/lib/commonjs/api/track/TextTrack.js +72 -0
  165. package/lib/commonjs/api/track/TextTrack.js.map +1 -0
  166. package/lib/commonjs/api/track/TextTrackCue.js +2 -0
  167. package/lib/commonjs/api/track/TextTrackCue.js.map +1 -0
  168. package/lib/commonjs/api/track/Track.js +2 -0
  169. package/lib/commonjs/api/track/Track.js.map +1 -0
  170. package/lib/commonjs/api/track/barrel.js +71 -0
  171. package/lib/commonjs/api/track/barrel.js.map +1 -0
  172. package/lib/commonjs/index.js +31 -0
  173. package/lib/commonjs/index.js.map +1 -0
  174. package/lib/commonjs/internal/THEOplayerView.js +274 -0
  175. package/lib/commonjs/internal/THEOplayerView.js.map +1 -0
  176. package/lib/commonjs/internal/THEOplayerView.style.js +22 -0
  177. package/lib/commonjs/internal/THEOplayerView.style.js.map +1 -0
  178. package/lib/commonjs/internal/THEOplayerView.web.js +512 -0
  179. package/lib/commonjs/internal/THEOplayerView.web.js.map +1 -0
  180. package/lib/commonjs/internal/web/TrackUtils.js +68 -0
  181. package/lib/commonjs/internal/web/TrackUtils.js.map +1 -0
  182. package/lib/module/api/THEOplayerView.js +2 -0
  183. package/lib/module/api/THEOplayerView.js.map +1 -0
  184. package/lib/module/api/barrel.js +8 -0
  185. package/lib/module/api/barrel.js.map +1 -0
  186. package/lib/module/api/config/PlayerConfiguration.js +2 -0
  187. package/lib/module/api/config/PlayerConfiguration.js.map +1 -0
  188. package/lib/module/api/config/barrel.js +2 -0
  189. package/lib/module/api/config/barrel.js.map +1 -0
  190. package/lib/module/api/error/PlayerError.js +2 -0
  191. package/lib/module/api/error/PlayerError.js.map +1 -0
  192. package/lib/module/api/error/barrel.js +2 -0
  193. package/lib/module/api/error/barrel.js.map +1 -0
  194. package/lib/module/api/event/PlayerEvent.js +2 -0
  195. package/lib/module/api/event/PlayerEvent.js.map +1 -0
  196. package/lib/module/api/event/TrackEvent.js +14 -0
  197. package/lib/module/api/event/TrackEvent.js.map +1 -0
  198. package/lib/module/api/event/barrel.js +3 -0
  199. package/lib/module/api/event/barrel.js.map +1 -0
  200. package/lib/module/api/source/SourceDescription.js +2 -0
  201. package/lib/module/api/source/SourceDescription.js.map +1 -0
  202. package/lib/module/api/source/ads/Ads.js +2 -0
  203. package/lib/module/api/source/ads/Ads.js.map +1 -0
  204. package/lib/module/api/source/barrel.js +5 -0
  205. package/lib/module/api/source/barrel.js.map +1 -0
  206. package/lib/module/api/source/dash/DashPlaybackConfiguration.js +2 -0
  207. package/lib/module/api/source/dash/DashPlaybackConfiguration.js.map +1 -0
  208. package/lib/module/api/source/dash/barrel.js +2 -0
  209. package/lib/module/api/source/dash/barrel.js.map +1 -0
  210. package/lib/module/api/source/drm/DRMConfiguration.js +2 -0
  211. package/lib/module/api/source/drm/DRMConfiguration.js.map +1 -0
  212. package/lib/module/api/source/drm/barrel.js +2 -0
  213. package/lib/module/api/source/drm/barrel.js.map +1 -0
  214. package/lib/module/api/source/hls/HlsPlaybackConfiguration.js +2 -0
  215. package/lib/module/api/source/hls/HlsPlaybackConfiguration.js.map +1 -0
  216. package/lib/module/api/source/hls/barrel.js +2 -0
  217. package/lib/module/api/source/hls/barrel.js.map +1 -0
  218. package/lib/module/api/timeranges/TimeRange.js +2 -0
  219. package/lib/module/api/timeranges/TimeRange.js.map +1 -0
  220. package/lib/module/api/timeranges/barrel.js +2 -0
  221. package/lib/module/api/timeranges/barrel.js.map +1 -0
  222. package/lib/module/api/track/MediaTrack.js +2 -0
  223. package/lib/module/api/track/MediaTrack.js.map +1 -0
  224. package/lib/module/api/track/Quality.js +2 -0
  225. package/lib/module/api/track/Quality.js.map +1 -0
  226. package/lib/module/api/track/TextTrack.js +47 -0
  227. package/lib/module/api/track/TextTrack.js.map +1 -0
  228. package/lib/module/api/track/TextTrackCue.js +2 -0
  229. package/lib/module/api/track/TextTrackCue.js.map +1 -0
  230. package/lib/module/api/track/Track.js +2 -0
  231. package/lib/module/api/track/Track.js.map +1 -0
  232. package/lib/module/api/track/barrel.js +6 -0
  233. package/lib/module/api/track/barrel.js.map +1 -0
  234. package/lib/module/index.js +3 -0
  235. package/lib/module/index.js.map +1 -0
  236. package/lib/module/internal/THEOplayerView.js +256 -0
  237. package/lib/module/internal/THEOplayerView.js.map +1 -0
  238. package/lib/module/internal/THEOplayerView.style.js +12 -0
  239. package/lib/module/internal/THEOplayerView.style.js.map +1 -0
  240. package/lib/module/internal/THEOplayerView.web.js +495 -0
  241. package/lib/module/internal/THEOplayerView.web.js.map +1 -0
  242. package/lib/module/internal/web/TrackUtils.js +57 -0
  243. package/lib/module/internal/web/TrackUtils.js.map +1 -0
  244. package/lib/typescript/babel.config.d.ts +1 -0
  245. package/lib/typescript/lib/commonjs/api/THEOplayerView.d.ts +1 -0
  246. package/lib/typescript/lib/commonjs/api/barrel.d.ts +1 -0
  247. package/lib/typescript/lib/commonjs/api/config/PlayerConfiguration.d.ts +0 -0
  248. package/lib/typescript/lib/commonjs/api/config/barrel.d.ts +1 -0
  249. package/lib/typescript/lib/commonjs/api/error/PlayerError.d.ts +0 -0
  250. package/lib/typescript/lib/commonjs/api/error/barrel.d.ts +1 -0
  251. package/lib/typescript/lib/commonjs/api/event/PlayerEvent.d.ts +1 -0
  252. package/lib/typescript/lib/commonjs/api/event/TrackEvent.d.ts +5 -0
  253. package/lib/typescript/lib/commonjs/api/event/barrel.d.ts +1 -0
  254. package/lib/typescript/lib/commonjs/api/source/SourceDescription.d.ts +1 -0
  255. package/lib/typescript/lib/commonjs/api/source/ads/Ads.d.ts +0 -0
  256. package/lib/typescript/lib/commonjs/api/source/barrel.d.ts +1 -0
  257. package/lib/typescript/lib/commonjs/api/source/dash/DashPlaybackConfiguration.d.ts +0 -0
  258. package/lib/typescript/lib/commonjs/api/source/dash/barrel.d.ts +1 -0
  259. package/lib/typescript/lib/commonjs/api/source/drm/DRMConfiguration.d.ts +0 -0
  260. package/lib/typescript/lib/commonjs/api/source/drm/barrel.d.ts +1 -0
  261. package/lib/typescript/lib/commonjs/api/source/hls/HlsPlaybackConfiguration.d.ts +0 -0
  262. package/lib/typescript/lib/commonjs/api/source/hls/barrel.d.ts +1 -0
  263. package/lib/typescript/lib/commonjs/api/timeranges/TimeRange.d.ts +0 -0
  264. package/lib/typescript/lib/commonjs/api/timeranges/barrel.d.ts +1 -0
  265. package/lib/typescript/lib/commonjs/api/track/MediaTrack.d.ts +1 -0
  266. package/lib/typescript/lib/commonjs/api/track/Quality.d.ts +0 -0
  267. package/lib/typescript/lib/commonjs/api/track/TextTrack.d.ts +21 -0
  268. package/lib/typescript/lib/commonjs/api/track/TextTrackCue.d.ts +0 -0
  269. package/lib/typescript/lib/commonjs/api/track/Track.d.ts +0 -0
  270. package/lib/typescript/lib/commonjs/api/track/barrel.d.ts +1 -0
  271. package/lib/typescript/lib/commonjs/index.d.ts +3 -0
  272. package/lib/typescript/lib/commonjs/internal/THEOplayerView.d.ts +14 -0
  273. package/lib/typescript/lib/commonjs/internal/THEOplayerView.style.d.ts +12 -0
  274. package/lib/typescript/lib/commonjs/internal/THEOplayerView.web.d.ts +17 -0
  275. package/lib/typescript/lib/commonjs/internal/web/TrackUtils.d.ts +30 -0
  276. package/lib/typescript/lib/module/api/THEOplayerView.d.ts +1 -0
  277. package/lib/typescript/lib/module/api/barrel.d.ts +7 -0
  278. package/lib/typescript/lib/module/api/config/PlayerConfiguration.d.ts +0 -0
  279. package/lib/typescript/lib/module/api/config/barrel.d.ts +1 -0
  280. package/lib/typescript/lib/module/api/error/PlayerError.d.ts +0 -0
  281. package/lib/typescript/lib/module/api/error/barrel.d.ts +1 -0
  282. package/lib/typescript/lib/module/api/event/PlayerEvent.d.ts +1 -0
  283. package/lib/typescript/lib/module/api/event/TrackEvent.d.ts +2 -0
  284. package/lib/typescript/lib/module/api/event/barrel.d.ts +2 -0
  285. package/lib/typescript/lib/module/api/source/SourceDescription.d.ts +1 -0
  286. package/lib/typescript/lib/module/api/source/ads/Ads.d.ts +0 -0
  287. package/lib/typescript/lib/module/api/source/barrel.d.ts +4 -0
  288. package/lib/typescript/lib/module/api/source/dash/DashPlaybackConfiguration.d.ts +0 -0
  289. package/lib/typescript/lib/module/api/source/dash/barrel.d.ts +1 -0
  290. package/lib/typescript/lib/module/api/source/drm/DRMConfiguration.d.ts +0 -0
  291. package/lib/typescript/lib/module/api/source/drm/barrel.d.ts +1 -0
  292. package/lib/typescript/lib/module/api/source/hls/HlsPlaybackConfiguration.d.ts +0 -0
  293. package/lib/typescript/lib/module/api/source/hls/barrel.d.ts +1 -0
  294. package/lib/typescript/lib/module/api/timeranges/TimeRange.d.ts +0 -0
  295. package/lib/typescript/lib/module/api/timeranges/barrel.d.ts +1 -0
  296. package/lib/typescript/lib/module/api/track/MediaTrack.d.ts +1 -0
  297. package/lib/typescript/lib/module/api/track/Quality.d.ts +0 -0
  298. package/lib/typescript/lib/module/api/track/TextTrack.d.ts +20 -0
  299. package/lib/typescript/lib/module/api/track/TextTrackCue.d.ts +0 -0
  300. package/lib/typescript/lib/module/api/track/Track.d.ts +0 -0
  301. package/lib/typescript/lib/module/api/track/barrel.d.ts +2 -0
  302. package/lib/typescript/lib/module/index.d.ts +2 -0
  303. package/lib/typescript/lib/module/internal/THEOplayerView.d.ts +9 -0
  304. package/lib/typescript/lib/module/internal/THEOplayerView.style.d.ts +11 -0
  305. package/lib/typescript/lib/module/internal/THEOplayerView.web.d.ts +10 -0
  306. package/lib/typescript/lib/module/internal/web/TrackUtils.d.ts +29 -0
  307. package/lib/typescript/src/api/THEOplayerView.d.ts +178 -0
  308. package/lib/typescript/src/api/barrel.d.ts +7 -0
  309. package/lib/typescript/src/api/config/PlayerConfiguration.d.ts +14 -0
  310. package/lib/typescript/src/api/config/barrel.d.ts +1 -0
  311. package/lib/typescript/src/api/error/PlayerError.d.ts +4 -0
  312. package/lib/typescript/src/api/error/barrel.d.ts +1 -0
  313. package/lib/typescript/src/api/event/PlayerEvent.d.ts +56 -0
  314. package/lib/typescript/src/api/event/TrackEvent.d.ts +46 -0
  315. package/lib/typescript/src/api/event/barrel.d.ts +2 -0
  316. package/lib/typescript/src/api/source/SourceDescription.d.ts +268 -0
  317. package/lib/typescript/src/api/source/ads/Ads.d.ts +94 -0
  318. package/lib/typescript/src/api/source/barrel.d.ts +4 -0
  319. package/lib/typescript/src/api/source/dash/DashPlaybackConfiguration.d.ts +44 -0
  320. package/lib/typescript/src/api/source/dash/barrel.d.ts +1 -0
  321. package/lib/typescript/src/api/source/drm/DRMConfiguration.d.ts +262 -0
  322. package/lib/typescript/src/api/source/drm/barrel.d.ts +1 -0
  323. package/lib/typescript/src/api/source/hls/HlsPlaybackConfiguration.d.ts +37 -0
  324. package/lib/typescript/src/api/source/hls/barrel.d.ts +1 -0
  325. package/lib/typescript/src/api/timeranges/TimeRange.d.ts +4 -0
  326. package/lib/typescript/src/api/timeranges/barrel.d.ts +1 -0
  327. package/lib/typescript/src/api/track/MediaTrack.d.ts +55 -0
  328. package/lib/typescript/src/api/track/Quality.d.ts +79 -0
  329. package/lib/typescript/src/api/track/TextTrack.d.ts +86 -0
  330. package/lib/typescript/src/api/track/TextTrackCue.d.ts +38 -0
  331. package/lib/typescript/src/api/track/Track.d.ts +43 -0
  332. package/lib/typescript/src/api/track/barrel.d.ts +5 -0
  333. package/lib/typescript/src/index.d.ts +2 -0
  334. package/lib/typescript/src/internal/THEOplayerView.d.ts +71 -0
  335. package/lib/typescript/src/internal/THEOplayerView.style.d.ts +11 -0
  336. package/lib/typescript/src/internal/THEOplayerView.web.d.ts +22 -0
  337. package/lib/typescript/src/internal/web/TrackUtils.d.ts +5 -0
  338. package/package.json +115 -9
  339. package/react-native-theoplayer.podspec +20 -0
  340. package/src/api/THEOplayerView.ts +221 -0
  341. package/src/api/barrel.ts +7 -0
  342. package/src/api/config/PlayerConfiguration.ts +16 -0
  343. package/src/api/config/barrel.ts +1 -0
  344. package/src/api/error/PlayerError.ts +4 -0
  345. package/src/api/error/barrel.ts +1 -0
  346. package/src/api/event/PlayerEvent.ts +66 -0
  347. package/src/api/event/TrackEvent.ts +55 -0
  348. package/src/api/event/barrel.ts +2 -0
  349. package/src/api/source/SourceDescription.ts +292 -0
  350. package/src/api/source/ads/Ads.ts +101 -0
  351. package/src/api/source/barrel.ts +4 -0
  352. package/src/api/source/dash/DashPlaybackConfiguration.ts +45 -0
  353. package/src/api/source/dash/barrel.ts +1 -0
  354. package/src/api/source/drm/DRMConfiguration.ts +287 -0
  355. package/src/api/source/drm/barrel.ts +1 -0
  356. package/src/api/source/hls/HlsPlaybackConfiguration.ts +38 -0
  357. package/src/api/source/hls/barrel.ts +1 -0
  358. package/src/api/timeranges/TimeRange.ts +5 -0
  359. package/src/api/timeranges/barrel.ts +1 -0
  360. package/src/api/track/MediaTrack.ts +65 -0
  361. package/src/api/track/Quality.ts +91 -0
  362. package/src/api/track/TextTrack.ts +133 -0
  363. package/src/api/track/TextTrackCue.ts +42 -0
  364. package/src/api/track/Track.ts +47 -0
  365. package/src/api/track/barrel.ts +5 -0
  366. package/src/index.tsx +2 -0
  367. package/src/internal/THEOplayerView.style.ts +12 -0
  368. package/src/internal/THEOplayerView.tsx +301 -0
  369. package/src/internal/THEOplayerView.web.tsx +399 -0
  370. package/src/internal/web/TrackUtils.ts +44 -0
  371. package/.gitattributes +0 -1
  372. package/index.js +0 -5
  373. package/ios/IOSNativeToast.h +0 -18
  374. package/ios/IOSNativeToast.m +0 -49
  375. package/ios/RNTheoplayer.h +0 -11
  376. package/ios/RNTheoplayer.m +0 -15
  377. package/ios/RNTheoplayer.podspec +0 -23
  378. package/ios/RNTheoplayer.xcodeproj/project.pbxproj +0 -417
  379. package/ios/RNTheoplayer.xcworkspace/contents.xcworkspacedata +0 -9
@@ -0,0 +1,268 @@
1
+ /**
2
+ * Represents a media resource.
3
+ *
4
+ * @remarks
5
+ * <br/> - Can be a string value representing the URL of a media resource, a {@link TypedSource}.
6
+ *
7
+ * @public
8
+ */
9
+ import type { DashPlaybackConfiguration } from './dash/DashPlaybackConfiguration';
10
+ import type { DRMConfiguration } from './drm/DRMConfiguration';
11
+ import type { HlsPlaybackConfiguration } from './hls/HlsPlaybackConfiguration';
12
+ import type { AdDescription } from './ads/Ads';
13
+ export declare type Source = TypedSource;
14
+ /**
15
+ * A media resource or list of media resources.
16
+ *
17
+ * @remarks
18
+ * <br/> - The order of sources when using a list determines their priority when attempting playback.
19
+ *
20
+ * @public
21
+ */
22
+ export declare type Sources = Source | Source[];
23
+ /**
24
+ * The cross-origin setting of a source, represented by a value from the following list:
25
+ * <br/> - `'anonymous'`: CORS requests will have the credentials flag set to 'same-origin'.
26
+ * <br/> - `'use-credentials'`: CORS requests will have the credentials flag set to 'include'.
27
+ * <br/> - `''`: Setting the empty string is the same as `'anonymous'`
28
+ *
29
+ * @remarks
30
+ * <br/> - See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_settings_attributes | The crossorigin attribute: Requesting CORS access to content}
31
+ *
32
+ * @public
33
+ */
34
+ export declare type CrossOriginSetting = '' | 'anonymous' | 'use-credentials';
35
+ /**
36
+ * Describes the configuration of a player's source.
37
+ *
38
+ * @public
39
+ */
40
+ export interface SourceConfiguration {
41
+ /**
42
+ * List of {@link AdDescription}s to be queued for playback.
43
+ */
44
+ ads?: AdDescription[];
45
+ /**
46
+ * Content protection configuration.
47
+ */
48
+ contentProtection?: DRMConfiguration;
49
+ /**
50
+ * The poster of the media source.
51
+ *
52
+ * @remarks
53
+ * <br/> - An empty string (`''`) clears the current poster.
54
+ * <br/> - This poster has priority over {@link ChromelessPlayer.poster}.
55
+ */
56
+ poster?: string;
57
+ /**
58
+ * List of text tracks to be side-loaded with the media source.
59
+ *
60
+ * @remarks
61
+ * <br/> - A source change will reset side-loaded text tracks.
62
+ */
63
+ textTracks?: TextTrackDescription[];
64
+ /**
65
+ * The URL of a time server used by the player to synchronise the time in DASH sources.
66
+ *
67
+ * @remarks
68
+ * <br/> - The time server should return time in ISO-8601 format.
69
+ * <br/> - Overrides the time server provided the DASH manifest's `<UTCTiming>`.
70
+ * <br/> - All sources will use the time server. Alternatively, for one source use {@link BaseSource.timeServer}.
71
+ */
72
+ timeServer?: string;
73
+ }
74
+ /**
75
+ * Describes the configuration of a player's source.
76
+ *
77
+ * @public
78
+ */
79
+ export interface SourceDescription extends SourceConfiguration {
80
+ /**
81
+ * One or more media resources for playback.
82
+ *
83
+ * @remarks
84
+ * <br/> - Multiple media sources should be used to increase platform compatibility. See examples below for important use cases.
85
+ * <br/> - The player will try each source in the provided order.
86
+ *
87
+ * @example
88
+ * In this example, the player will first try to play the DASH source.
89
+ * This might fail if the browser does not support the {@link https://www.widevine.com/ | Widevine} or {@link https://www.microsoft.com/playready/ | PlayReady} CDM, for example on Safari.
90
+ * In that case, the player will try to play the HLS source instead.
91
+ *
92
+ * ```
93
+ * [{
94
+ * src: 'dash-source-with-drm.mpd'
95
+ * contentProtection: {
96
+ * widevine: {
97
+ * licenseAcquisitionURL: 'https://license.company.com/wv'
98
+ * },
99
+ * playready: {
100
+ * licenseAcquisitionURL: 'https://license.company.com/pr'
101
+ * }
102
+ * }
103
+ * },{
104
+ * src: 'hls-source-with-drm.m3u8',
105
+ * contentProtection: {
106
+ * fairplay: {
107
+ * certificateURL: 'https://license.company.com/fp'
108
+ * }
109
+ * }
110
+ * }]
111
+ * ```
112
+ *
113
+ * @example
114
+ * In this example, the player will first try to play the DASH source.
115
+ * This might fail if the browser does not support the {@link https://developer.mozilla.org/en-US/docs/Web/API/Media_Source_Extensions_API | Media Source Extensions API}.
116
+ * In that case, the player will try to play the MP4 source instead, though without features such as adaptive bitrate switching.
117
+ *
118
+ * ```
119
+ * [{
120
+ * src: 'source.mpd'
121
+ * },{
122
+ * src: 'source.mp4'
123
+ * }]
124
+ * ```
125
+ */
126
+ sources?: Sources;
127
+ }
128
+ /**
129
+ * Describes the configuration of a side-loaded text track.
130
+ *
131
+ * @public
132
+ */
133
+ export interface TextTrackDescription {
134
+ /**
135
+ * Whether the text track should be enabled by default.
136
+ *
137
+ * @remarks
138
+ * <br/> - Only one text track per {@link TextTrack.kind} may be marked as default.
139
+ *
140
+ * @defaultValue `false`
141
+ */
142
+ default?: boolean;
143
+ /**
144
+ * The kind of the text track, represented by a value from the following list:
145
+ * <br/> - `'subtitles'`: The track provides subtitles, used to display subtitles in a video.
146
+ * <br/> - `'captions'`: The track provides a translation of dialogue and sound effects (suitable for users with a hearing impairment).
147
+ * <br/> - `'descriptions'`: The track provides a textual description of the video (suitable for users with a vision impairment).
148
+ * <br/> - `'chapters'`: The track provides chapter titles (suitable for navigating the media resource).
149
+ * <br/> - `'metadata'`: The track provides content used by scripts and is not visible for users.
150
+ *
151
+ * @remarks
152
+ * <br/> - If an unrecognized value is provided, the player will interpret it as `'metadata'`.
153
+ *
154
+ * @defaultValue `'subtitles'`
155
+ */
156
+ kind?: string;
157
+ /**
158
+ * The format of the track, represented by a value from the following list:
159
+ * <br/> - `'srt'`
160
+ * <br/> - `'ttml'`
161
+ * <br/> - `'webvtt'`
162
+ * <br/> - `'emsg'`
163
+ * <br/> - `'eventstream'`
164
+ * <br/> - `'id3'`
165
+ * <br/> - `'cea608'`
166
+ * <br/> - `'daterange'`
167
+ *
168
+ * @defaultValue `''`
169
+ */
170
+ format?: string;
171
+ /**
172
+ * The source URL of the text track.
173
+ */
174
+ src: string;
175
+ /**
176
+ * The language of the text track.
177
+ */
178
+ srclang?: string;
179
+ /**
180
+ * A label for the text track.
181
+ *
182
+ * @remarks
183
+ * <br/> - This will be used as an identifier on the player API and in the UI.
184
+ */
185
+ label?: string;
186
+ /**
187
+ * The identifier of this text track.
188
+ *
189
+ * @internal
190
+ */
191
+ id?: string;
192
+ }
193
+ /**
194
+ * Represents the common properties of a media resource.
195
+ *
196
+ * @public
197
+ */
198
+ export interface BaseSource {
199
+ /**
200
+ * The URL of a time server used by the player to synchronise the time in DASH sources.
201
+ *
202
+ * @remarks
203
+ * <br/> - Available since v2.47.0.
204
+ * <br/> - The time server should return time in ISO-8601 format.
205
+ * <br/> - Overrides the time server provided the DASH manifest's `<UTCTiming>`.
206
+ * <br/> - Only this source will use the time server. Alternatively, for all source use {@link SourceConfiguration.timeServer}.
207
+ */
208
+ timeServer?: string;
209
+ /**
210
+ * Whether the source should be played in the low-latency-mode of the player.
211
+ *
212
+ * @defaultValue `false`
213
+ *
214
+ * @remarks
215
+ * <br/> - This setting must be `true` when using Low-Latency CMAF with ABR.
216
+ * <br/> - Available since v2.62.0.
217
+ */
218
+ lowLatency?: boolean;
219
+ /**
220
+ * The configuration for controlling playback of an MPEG-DASH stream.
221
+ *
222
+ * @remarks
223
+ * <br/> - Available since v2.79.0.
224
+ * <br/> - Ignored for non-DASH streams.
225
+ */
226
+ dash?: DashPlaybackConfiguration;
227
+ /**
228
+ * The configuration for controlling playback of an HLS stream.
229
+ *
230
+ * @remarks
231
+ * <br/> - Available since v2.82.0.
232
+ * <br/> - Ignored for non-HLS streams.
233
+ */
234
+ hls?: HlsPlaybackConfiguration;
235
+ }
236
+ /**
237
+ * Represents a media resource characterized by a URL to the resource and optionally information about the resource.
238
+ *
239
+ * @public
240
+ */
241
+ export interface TypedSource extends BaseSource {
242
+ /**
243
+ * The source URL of the media resource.
244
+ *
245
+ * @remarks
246
+ * <br/> - Required if the `ssai` property is absent.
247
+ * <br/> - Available since v2.4.0.
248
+ */
249
+ src?: string;
250
+ /**
251
+ * The content type (MIME type) of the media resource, represented by a value from the following list:
252
+ * <br/> - `'application/dash+xml'`: The media resource is an MPEG-DASH stream.
253
+ * <br/> - `'application/x-mpegURL'` or `'application/vnd.apple.mpegurl'`: The media resource is an HLS stream.
254
+ * <br/> - `'video/mp4'`, `'video/webm'` and other formats: The media resource should use native HTML5 playback if supported by the browser.
255
+ * <br/> - `'application/vnd.theo.hesp+json'`: The media resource is an HESP stream.
256
+ *
257
+ * @remarks
258
+ * <br/> - Available since v2.4.0.
259
+ */
260
+ type?: string;
261
+ /**
262
+ * The content protection parameters for the media resource.
263
+ *
264
+ * @remarks
265
+ * <br/> - Available since v2.15.0.
266
+ */
267
+ contentProtection?: DRMConfiguration;
268
+ }
@@ -0,0 +1,94 @@
1
+ /**
2
+ * The type of ad source:
3
+ * <br/> - `'vast'`: The source is a VAST resource.
4
+ * <br/> - `'vmap'`: The source is a VMAP resource.
5
+ * <br/> - `'adrule'`: The source is a Ad Rule resource.
6
+ *
7
+ * @remarks
8
+ * <br/> - An ad rule is a simplified VMAP alternative only available in the Google IMA integration.
9
+ *
10
+ * @public
11
+ */
12
+ export declare type AdSourceType = 'vast' | 'vmap' | 'adrule';
13
+ /**
14
+ * Describes the source of the ad.
15
+ *
16
+ * @public
17
+ */
18
+ export interface AdSource {
19
+ /**
20
+ * The URL of the ad resource.
21
+ */
22
+ src: string;
23
+ /**
24
+ * The type of ad resource.
25
+ *
26
+ * @defaultValue 'vmap' when set through {@link SourceConfiguration.ads} without a time offset, otherwise 'vast'.
27
+ */
28
+ type?: AdSourceType;
29
+ }
30
+ /**
31
+ * Describes an ad break request.
32
+ *
33
+ * @public
34
+ */
35
+ export interface AdDescription {
36
+ /**
37
+ * The integration of the ad break.
38
+ *
39
+ * @defaultValue `'theo'`
40
+ */
41
+ integration?: AdIntegrationKind;
42
+ /**
43
+ * Whether the ad replaces playback of the content.
44
+ *
45
+ * @remarks
46
+ * <br/> - When the ad ends, the content will resume at the ad break's offset plus its duration.
47
+ *
48
+ * @defaultValue
49
+ * <br/> - `true` for live content,
50
+ * <br/> - `false` for VOD content
51
+ */
52
+ replaceContent?: boolean;
53
+ /**
54
+ * A source which contains the location of ad resources to be scheduled.
55
+ *
56
+ * @remarks
57
+ * <br/> - Important: This should *not* be an array of sources.
58
+ * <br/> - VPAID support is limited to the `'google-ima'` integration.
59
+ * <br/> - Not specifying this property should only happen when using a third party ad integration that uses an other system of specifying which ads to schedule
60
+ */
61
+ sources?: string | AdSource;
62
+ /**
63
+ * Offset after which the ad break will start.
64
+ *
65
+ * Possible formats:
66
+ * <br/> - A number for the offset in seconds.
67
+ * <br/> - `'start'` for a preroll.
68
+ * <br/> - `'end'` for a postroll.
69
+ * <br/> - `'HH:MM:SS.mmm'` for a timestamp in the playback window.
70
+ * <br/> - A percentage string (XX%) for a proportion of the content duration.
71
+ *
72
+ * @remarks
73
+ * <br/> - A timestamp which is not in the playback window will result in the ad break not being started.
74
+ * <br/> - VMAP resources will ignore this value as they contain an internal offset.
75
+ * <br/> - Since 2.18, numbers are supported for the Google IMA integration, since 2.21 other formats as well.
76
+ *
77
+ * @defaultValue `'start'`
78
+ *
79
+ */
80
+ timeOffset?: string | number;
81
+ }
82
+ /**
83
+ * The integration of an ad break, represented by a value from the following list:
84
+ * <br/> - `'theo'`: Default ad playback.
85
+ * <br/> - `'google-ima'`: {@link https://developers.google.com/interactive-media-ads/docs/sdks/html5|Google IMA} pre-integrated ad playback.
86
+ * <br/> - `'spotx'`: {@link https://developer.spotxchange.com/|SpotX} pre-integrated ad playback.
87
+ * <br/> - `'freewheel'`: {@link https://vi.freewheel.tv/|FreeWheel} pre-integrated ad playback.
88
+ *
89
+ * @remarks
90
+ * <br/> - An empty string defaults to `'theo'`.
91
+ *
92
+ * @public
93
+ */
94
+ export declare type AdIntegrationKind = '' | 'theo' | 'google-ima' | 'spotx' | 'freewheel';
@@ -0,0 +1,4 @@
1
+ export * from './drm/barrel';
2
+ export * from './dash/barrel';
3
+ export * from './hls/barrel';
4
+ export * from './SourceDescription';
@@ -0,0 +1,44 @@
1
+ /**
2
+ * The strategy for period switches (see {@link DashPlaybackConfiguration.useSeamlessPeriodSwitch}), represented by a value from the following list:
3
+ * <br/> - `'auto'`: The player uses seamless switches if the platform supports it, and hard switches otherwise.
4
+ * This is the default.
5
+ * <br/> - `'never'`: The player never uses a seamless switch, and always uses a hard switch.
6
+ * Use this if you notice that the player is attempting but failing to preload the next period on the current platform.
7
+ * <br/> - `'always'`: The player always uses a seamless switch, and never uses a hard switch.
8
+ * Use this if you notice that the player never preloads the next period, even though you know that the current platform
9
+ * should support it.
10
+ *
11
+ * @public
12
+ */
13
+ export declare type SeamlessPeriodSwitchStrategy = 'auto' | 'always' | 'never';
14
+ /**
15
+ * Represents a configuration for controlling playback of an MPEG-DASH stream.
16
+ *
17
+ * @remarks
18
+ * <br/> - Available since v2.79.0.
19
+ *
20
+ * @public
21
+ */
22
+ export interface DashPlaybackConfiguration {
23
+ /**
24
+ * Whether to seamlessly switch between DASH periods.
25
+ *
26
+ * @remarks
27
+ * The player supports two strategies for handling a switch between two periods in an MPEG-DASH stream:
28
+ * <br/> - <strong>Seamless</strong>: Once the player is done buffering the current period, it immediately starts buffering the next period.
29
+ * This requires that the current period and the next period have compatible codecs and content protection, or that the platform
30
+ * supports buffering different codecs in a single player. Because the next period is preloaded ahead of time, this makes the actual
31
+ * switch between periods (almost) completely seamless.
32
+ * <br/> - <strong>Hard</strong>: The player waits until playback reaches the end of the current period before buffering and playing the next
33
+ * period. Because the buffering is not done ahead of time, this may result in a noticeable stall at the start of the next period.
34
+ * However, this strategy does not require any special platform support, so it works on any platform or device.
35
+ *
36
+ * By default, the player will automatically choose between a seamless or a hard period switch based on the codecs and content protection of
37
+ * the two periods, and the support information reported by the platform. However, if you notice that the player makes an incorrect decision
38
+ * on certain streams or platforms, you can use this option to override its behavior as a stopgap solution. (You should still report this
39
+ * problem to THEOplayer support, so we can improve the player's default behavior and you can remove this override.)
40
+ *
41
+ * @defaultValue `'auto'`
42
+ */
43
+ useSeamlessPeriodSwitch?: SeamlessPeriodSwitchStrategy;
44
+ }
@@ -0,0 +1 @@
1
+ export * from './DashPlaybackConfiguration';
@@ -0,0 +1,262 @@
1
+ /**
2
+ * Describes the key system configuration.
3
+ *
4
+ * @public
5
+ */
6
+ export interface KeySystemConfiguration {
7
+ /**
8
+ * Property to indicate whether the ability to persist state is required. This includes session data and any other type of state. The player will forward this information to the CDM when requesting access to the media key system.
9
+ *
10
+ * Available values are:
11
+ * - "required": This will instruct the player to make the key sessions persistent.
12
+ * - "optional": Choice of making use of a persistent key session is up to the player.
13
+ * - "not-allowed": A temporary key session will be used.
14
+ */
15
+ persistentState?: 'required' | 'optional' | 'not-allowed';
16
+ /**
17
+ * Used to indicate if media key sessions can be shared across different instances, for example different browser profiles, player instances or applications. The player will forward this information to the CDM when requesting access to the media key system.
18
+ * Available values are:
19
+ * - “required”
20
+ * - “optional”
21
+ * - “not-allowed”
22
+ */
23
+ distinctiveIdentifier?: 'required' | 'optional' | 'not-allowed';
24
+ /**
25
+ * Allows to configure the robustness level required for audio data. The robustness level can be used to define the DRM security level. If the security level requested is not available on the platform, playback will fail.
26
+ *
27
+ * Following values are supported for Widevine:
28
+ * - "": Lowest security level
29
+ * - "SW_SECURE_CRYPTO": Secure decryption in software is required. This matches Widevine L3.
30
+ * - "SW_SECURE_DECODE": Media data is to be decoded securely in software. This matches Widevine L3.
31
+ * - "HW_SECURE_CRYPTO": Secure decryption in hardware is required. This matches Widevine L2.
32
+ * - "HW_SECURE_DECODE": Media data is to be decoded securely in hardware. This matches Widevine L1.
33
+ * - "HW_SECURE_ALL": The media pipeline must be decrypted and decoded securely in hardware. This matches Widevine L1.
34
+ */
35
+ audioRobustness?: string;
36
+ /**
37
+ * Allows to configure the robustness level required for video data. The robustness level can be used to define the DRM security level. If the security level requested is not available on the platform, playback will fail.
38
+ *
39
+ * Following values are supported for Widevine:
40
+ *
41
+ * - "": Lowest security level
42
+ * - "SW_SECURE_CRYPTO": Secure decryption in software is required. This matches Widevine L3.
43
+ * - "SW_SECURE_DECODE": Media data is to be decoded securely in software. This matches Widevine L3.
44
+ * - "HW_SECURE_CRYPTO": Secure decryption in hardware is required. This matches Widevine L2.
45
+ * - "HW_SECURE_DECODE": Media data is to be decoded securely in hardware. This matches Widevine L1.
46
+ * - "HW_SECURE_ALL": The media pipeline must be decrypted and decoded securely in hardware. This matches Widevine L1.
47
+ */
48
+ videoRobustness?: string;
49
+ /**
50
+ * The licence acquisition URL.
51
+ *
52
+ * @remarks
53
+ * <br/> - If provided, the player will send license requests for the intended DRM scheme to the provided value.
54
+ * <br/> - If not provided, the player will use the default license acquisition URLs.
55
+ */
56
+ licenseAcquisitionURL?: string;
57
+ /**
58
+ * The licence type.
59
+ *
60
+ * @internal
61
+ */
62
+ licenseType?: LicenseType;
63
+ /**
64
+ * Record of HTTP headers for the licence acquisition request.
65
+ * Each entry contains a header name with associated value.
66
+ */
67
+ headers?: {
68
+ [headerName: string]: string;
69
+ };
70
+ /**
71
+ * Whether the player is allowed to use credentials for cross-origin requests.
72
+ *
73
+ * @remarks
74
+ * <br/> - Credentials are cookies, authorization headers or TLS client certificates.
75
+ *
76
+ * @defaultValue `false`
77
+ */
78
+ useCredentials?: boolean;
79
+ /**
80
+ * Record of query parameters for the licence acquisition request.
81
+ * Each entry contains a query parameter name with associated value.
82
+ */
83
+ queryParameters?: {
84
+ [key: string]: any;
85
+ };
86
+ /**
87
+ * The certificate for the key system. This can be either an ArrayBuffer or Uint8Array containing the raw certificate bytes or a base64-encoded variant of this.
88
+ */
89
+ certificate?: string;
90
+ /**
91
+ * Process the certificate's request.
92
+ *
93
+ * @deprecated Please use {@link registerContentProtectionIntegration} and {@link ContentProtectionIntegration.onCertificateRequest} instead.
94
+ */
95
+ certificateRequestProcessor?: DRMProcessor;
96
+ /**
97
+ * Process the certificate's response.
98
+ *
99
+ * @deprecated Please use {@link registerContentProtectionIntegration} and {@link ContentProtectionIntegration.onCertificateResponse} instead.
100
+ */
101
+ certificateResponseProcessor?: DRMProcessor;
102
+ /**
103
+ * Process the license's request.
104
+ *
105
+ * @deprecated Please use {@link registerContentProtectionIntegration} and {@link ContentProtectionIntegration.onLicenseRequest} instead.
106
+ */
107
+ licenseRequestProcessor?: DRMProcessor;
108
+ /**
109
+ * Process the license's response.
110
+ *
111
+ * @deprecated Please use {@link registerContentProtectionIntegration} and {@link ContentProtectionIntegration.onLicenseResponse} instead.
112
+ */
113
+ licenseResponseProcessor?: DRMProcessor;
114
+ }
115
+ /**
116
+ * The type of the licence, represented by a value from the following list:
117
+ * <br/> - `'temporary'`
118
+ * <br/> - `'persistent'`
119
+ *
120
+ * @public
121
+ */
122
+ export declare type LicenseType = 'temporary' | 'persistent';
123
+ /**
124
+ * Describes the FairPlay key system configuration.
125
+ *
126
+ * @public
127
+ */
128
+ export interface FairPlayKeySystemConfiguration extends KeySystemConfiguration {
129
+ /**
130
+ * The URL of the certificate.
131
+ */
132
+ certificateURL?: string;
133
+ }
134
+ /**
135
+ * Describes the PlayReady key system configuration.
136
+ *
137
+ * @public
138
+ */
139
+ export interface PlayReadyKeySystemConfiguration extends KeySystemConfiguration {
140
+ /**
141
+ * Custom data which will be passed to the CDM.
142
+ */
143
+ customData?: string;
144
+ }
145
+ /**
146
+ * Describes the Widevine key system configuration.
147
+ *
148
+ * @public
149
+ */
150
+ export declare type WidevineKeySystemConfiguration = KeySystemConfiguration;
151
+ /**
152
+ * A function which processes DRM data.
153
+ *
154
+ * @public
155
+ */
156
+ export declare type DRMProcessor = (arrayBuffer: ArrayBuffer) => ArrayBuffer;
157
+ /**
158
+ * Describes the ClearKey key system configuration.
159
+ *
160
+ * @public
161
+ */
162
+ export interface ClearkeyKeySystemConfiguration extends KeySystemConfiguration {
163
+ /**
164
+ * List of decryption keys.
165
+ */
166
+ keys?: ClearkeyDecryptionKey[];
167
+ }
168
+ /**
169
+ * Describes the ClearKey decryption key.
170
+ *
171
+ * @public
172
+ */
173
+ export interface ClearkeyDecryptionKey {
174
+ /**
175
+ * The identifier of the key.
176
+ *
177
+ * @remarks
178
+ * <br/> - This is a base64url encoding of the octet sequence containing the key ID.
179
+ * <br/> - See {@link https://www.w3.org/TR/encrypted-media/#clear-key-license-format | Clear Key License Format}.
180
+ */
181
+ id: string;
182
+ /**
183
+ * The value of the key.
184
+ *
185
+ * @remarks
186
+ * <br/> - The base64url encoding of the octet sequence containing the symmetric key value.
187
+ * <br/> - See {@link https://www.w3.org/TR/encrypted-media/#clear-key-license-format | Clear Key License Format}.
188
+ */
189
+ value: string;
190
+ }
191
+ /**
192
+ * Describes the AES128 key system configuration.
193
+ *
194
+ * @public
195
+ */
196
+ export interface AES128KeySystemConfiguration {
197
+ /**
198
+ * Whether the player is allowed to use credentials for cross-origin requests.
199
+ *
200
+ * @remarks
201
+ * <br/> - Credentials are cookies, authorization headers or TLS client certificates.
202
+ *
203
+ * @defaultValue `false`
204
+ */
205
+ useCredentials?: true;
206
+ }
207
+ /**
208
+ * Describes the configuration of the DRM.
209
+ *
210
+ * @public
211
+ */
212
+ export interface DRMConfiguration {
213
+ /**
214
+ * The identifier of the DRM integration.
215
+ */
216
+ integration?: string;
217
+ /**
218
+ * The configuration of the FairPlay key system.
219
+ */
220
+ fairplay?: FairPlayKeySystemConfiguration;
221
+ /**
222
+ * The configuration of the PlayReady key system.
223
+ */
224
+ playready?: PlayReadyKeySystemConfiguration;
225
+ /**
226
+ * The configuration of the Widevine key system.
227
+ */
228
+ widevine?: WidevineKeySystemConfiguration;
229
+ /**
230
+ * The configuration of the ClearKey key system.
231
+ */
232
+ clearkey?: ClearkeyKeySystemConfiguration;
233
+ /**
234
+ * The configuration of the AES key system.
235
+ */
236
+ aes128?: AES128KeySystemConfiguration;
237
+ /**
238
+ * An object of key/value pairs which can be used to pass in specific parameters related to a source into a
239
+ * {@link ContentProtectionIntegration}.
240
+ */
241
+ integrationParameters?: {
242
+ [parameterName: string]: any;
243
+ };
244
+ /**
245
+ * An ordered list of URNs of key systems as specified by https://dashif.org/identifiers/content_protection/, or one of the following identifiers:
246
+ *
247
+ * `"widevine"` alias for `"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed"`
248
+ * `"fairplay"` alias for `"urn:uuid:94ce86fb-07bb-4b43-adb8-93d2fa968ca2"`
249
+ * `"playready"` alias for `"urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95"`
250
+ *
251
+ * The first key system in this list which is supported on the given platform will be used for playback.
252
+ *
253
+ * Default value is ['widevine', 'playready', 'fairplay'].
254
+ */
255
+ preferredKeySystems?: Array<KeySystemId | string>;
256
+ }
257
+ /**
258
+ * The id of a key system. Possible values are 'widevine', 'fairplay' and 'playready'.
259
+ *
260
+ * @public
261
+ */
262
+ export declare type KeySystemId = 'widevine' | 'fairplay' | 'playready';
@@ -0,0 +1 @@
1
+ export * from './DRMConfiguration';