@applicaster/quick-brick-player 12.0.0-alpha.7257632022 → 12.0.0-alpha.7725319213
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/package.json +4 -4
- package/src/Player/index.tsx +32 -10
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/quick-brick-player",
|
|
3
|
-
"version": "12.0.0-alpha.
|
|
3
|
+
"version": "12.0.0-alpha.7725319213",
|
|
4
4
|
"description": "Quick Brick Player",
|
|
5
5
|
"main": "./src/index.ts",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -38,9 +38,9 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@applicaster/quick-brick-mobile-transport-controls": "12.0.0-rc.11",
|
|
40
40
|
"@applicaster/quick-brick-tv-transport-controls": "11.0.0-rc.133",
|
|
41
|
-
"@applicaster/zapp-react-native-tvos-app": "12.0.0-alpha.
|
|
42
|
-
"@applicaster/zapp-react-native-ui-components": "12.0.0-alpha.
|
|
43
|
-
"@applicaster/zapp-react-native-utils": "12.0.0-alpha.
|
|
41
|
+
"@applicaster/zapp-react-native-tvos-app": "12.0.0-alpha.7725319213",
|
|
42
|
+
"@applicaster/zapp-react-native-ui-components": "12.0.0-alpha.7725319213",
|
|
43
|
+
"@applicaster/zapp-react-native-utils": "12.0.0-alpha.7725319213",
|
|
44
44
|
"keymirror": "^0.1.1",
|
|
45
45
|
"react-native-web-linear-gradient": "1.1.2",
|
|
46
46
|
"shaka-player": "4.3.5",
|
package/src/Player/index.tsx
CHANGED
|
@@ -36,6 +36,10 @@ import { AudioPlayerWrapper } from "./AudioLayer/AudioPlayerWrapper";
|
|
|
36
36
|
import { playerManager } from "@applicaster/zapp-react-native-utils/appUtils";
|
|
37
37
|
import { getAllAccessibilityProps } from "@applicaster/zapp-react-native-utils/configurationUtils";
|
|
38
38
|
import { PlayNextData } from "@applicaster/zapp-react-native-ui-components/Components/PlayerContainer/PlayerContainer";
|
|
39
|
+
import {
|
|
40
|
+
getTargetScreenDataFromEntry
|
|
41
|
+
} from "@applicaster/zapp-react-native-utils/reactHooks/screen/useTargetScreenData";
|
|
42
|
+
import { isAppleTV } from "@applicaster/zapp-react-native-ui-components/Helpers/Platform";
|
|
39
43
|
|
|
40
44
|
const RNPlayerManager = {
|
|
41
45
|
QuickBrickPlayerPlugin: isApplePlatform()
|
|
@@ -755,7 +759,6 @@ export default class VideoPlayer extends React.Component<
|
|
|
755
759
|
render() {
|
|
756
760
|
const {
|
|
757
761
|
castAction,
|
|
758
|
-
controls,
|
|
759
762
|
docked,
|
|
760
763
|
entry,
|
|
761
764
|
fullscreen,
|
|
@@ -812,16 +815,32 @@ export default class VideoPlayer extends React.Component<
|
|
|
812
815
|
const liveCatchUpEnabled =
|
|
813
816
|
this.props.pluginConfiguration?.liveCatchUpEnabled;
|
|
814
817
|
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
+
// TODO: Get screen data more reliable way useCurrentScreenData
|
|
819
|
+
const screenData = getTargetScreenDataFromEntry(this.props.playableItem);
|
|
820
|
+
|
|
821
|
+
const isInlineTV = screenData?.ui_components?.length > 0 && isTV();
|
|
818
822
|
|
|
819
|
-
|
|
823
|
+
let platformSpecificProps: any = isApplePlatform()
|
|
820
824
|
? {
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
+
resizeMode: nativeResizeMode,
|
|
826
|
+
} : {};
|
|
827
|
+
|
|
828
|
+
const supportsNativeControls = !!this.props.controller?.supportsNativeControls?.();
|
|
829
|
+
|
|
830
|
+
const controls = isAppleTV()
|
|
831
|
+
? supportsNativeControls && isInlineTV && !this.getPlayNextData()
|
|
832
|
+
: supportsNativeControls && !this.getPlayNextData();
|
|
833
|
+
|
|
834
|
+
platformSpecificProps = {
|
|
835
|
+
...platformSpecificProps,
|
|
836
|
+
controls
|
|
837
|
+
};
|
|
838
|
+
|
|
839
|
+
console.log("Anton Player render2 ", {
|
|
840
|
+
platformSpecificProps,
|
|
841
|
+
isNotInlineTv: !isInlineTV,
|
|
842
|
+
hasNoPlayNextData: !this.getPlayNextData()
|
|
843
|
+
});
|
|
825
844
|
|
|
826
845
|
const pictureInPictureEnabled =
|
|
827
846
|
this.props.pluginConfiguration?.pictureInPictureEnabled;
|
|
@@ -830,7 +849,6 @@ export default class VideoPlayer extends React.Component<
|
|
|
830
849
|
entry, // Must be passed first in list
|
|
831
850
|
...platformSpecificProps,
|
|
832
851
|
audioTrackId,
|
|
833
|
-
controls,
|
|
834
852
|
docked,
|
|
835
853
|
enableAutoAudioTrackSelection,
|
|
836
854
|
fullscreen, // TODO: Check fullscreen params not crash
|
|
@@ -958,6 +976,8 @@ export default class VideoPlayer extends React.Component<
|
|
|
958
976
|
? styles.playerContainerTransparent
|
|
959
977
|
: styles.playerContainerBlack;
|
|
960
978
|
|
|
979
|
+
console.log("Anton Player render", {screenData, props: this.props, nativeProps});
|
|
980
|
+
|
|
961
981
|
const isInline = () => {
|
|
962
982
|
if (isTV()) {
|
|
963
983
|
return inline;
|
|
@@ -1087,6 +1107,7 @@ export default class VideoPlayer extends React.Component<
|
|
|
1087
1107
|
listener={this.props.listener}
|
|
1088
1108
|
style={getStyle(playerDimensions)}
|
|
1089
1109
|
pluginConfiguration={this.getPluginConfiguration()}
|
|
1110
|
+
controller={this.props.controller}
|
|
1090
1111
|
>
|
|
1091
1112
|
{this.childrenWithPlayNext()}
|
|
1092
1113
|
</this.props.PlayerComponent>
|
|
@@ -1123,6 +1144,7 @@ export default class VideoPlayer extends React.Component<
|
|
|
1123
1144
|
listener={this.props.listener}
|
|
1124
1145
|
style={this.takeParentStyle}
|
|
1125
1146
|
pluginConfiguration={this.getPluginConfiguration()}
|
|
1147
|
+
controller={this.props.controller}
|
|
1126
1148
|
>
|
|
1127
1149
|
{this.childrenWithPlayNext()}
|
|
1128
1150
|
</this.props.PlayerComponent>
|