@applicaster/zapp-react-native-ui-components 15.0.0-alpha.7012242426 → 15.0.0-alpha.7122965878
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.
|
@@ -46,7 +46,6 @@ import {
|
|
|
46
46
|
PlayerContainerContextProvider,
|
|
47
47
|
} from "./PlayerContainerContext";
|
|
48
48
|
import { FocusableGroup } from "@applicaster/zapp-react-native-ui-components/Components/FocusableGroup";
|
|
49
|
-
import { ErrorDisplay } from "./ErrorDisplay";
|
|
50
49
|
import { PlayerFocusableWrapperView } from "./WappersView/PlayerFocusableWrapperView";
|
|
51
50
|
import { FocusableGroupMainContainerId } from "./index";
|
|
52
51
|
import { isPlayable } from "@applicaster/zapp-react-native-utils/navigationUtils/itemTypeMatchers";
|
|
@@ -339,12 +338,6 @@ const PlayerContainerComponent = (props: Props) => {
|
|
|
339
338
|
playerContainerLogger.error(errorObj);
|
|
340
339
|
|
|
341
340
|
setState({ error: errorObj });
|
|
342
|
-
|
|
343
|
-
if (!isTvOS) {
|
|
344
|
-
setTimeout(() => {
|
|
345
|
-
close();
|
|
346
|
-
}, 800);
|
|
347
|
-
}
|
|
348
341
|
},
|
|
349
342
|
[close]
|
|
350
343
|
);
|
|
@@ -695,8 +688,6 @@ const PlayerContainerComponent = (props: Props) => {
|
|
|
695
688
|
</Player>
|
|
696
689
|
)}
|
|
697
690
|
</PlayerFocusableWrapperView>
|
|
698
|
-
|
|
699
|
-
{state.error ? <ErrorDisplay error={state.error} /> : null}
|
|
700
691
|
</View>
|
|
701
692
|
{/* Components container */}
|
|
702
693
|
{isInlineTV && context.showComponentsContainer ? (
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/zapp-react-native-ui-components",
|
|
3
|
-
"version": "15.0.0-alpha.
|
|
3
|
+
"version": "15.0.0-alpha.7122965878",
|
|
4
4
|
"description": "Applicaster Zapp React Native ui components for the Quick Brick App",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -28,10 +28,10 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/applicaster/quickbrick#readme",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@applicaster/applicaster-types": "15.0.0-alpha.
|
|
32
|
-
"@applicaster/zapp-react-native-bridge": "15.0.0-alpha.
|
|
33
|
-
"@applicaster/zapp-react-native-redux": "15.0.0-alpha.
|
|
34
|
-
"@applicaster/zapp-react-native-utils": "15.0.0-alpha.
|
|
31
|
+
"@applicaster/applicaster-types": "15.0.0-alpha.7122965878",
|
|
32
|
+
"@applicaster/zapp-react-native-bridge": "15.0.0-alpha.7122965878",
|
|
33
|
+
"@applicaster/zapp-react-native-redux": "15.0.0-alpha.7122965878",
|
|
34
|
+
"@applicaster/zapp-react-native-utils": "15.0.0-alpha.7122965878",
|
|
35
35
|
"fast-json-stable-stringify": "^2.1.0",
|
|
36
36
|
"promise": "^8.3.0",
|
|
37
37
|
"url": "^0.11.0",
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import * as R from "ramda";
|
|
3
|
-
import { Text, TextStyle, View, ViewStyle } from "react-native";
|
|
4
|
-
|
|
5
|
-
import { getLocalizations } from "@applicaster/zapp-react-native-utils/localizationUtils";
|
|
6
|
-
import { getAppStylesColor } from "@applicaster/zapp-react-native-utils/stylesUtils";
|
|
7
|
-
import { useTheme } from "@applicaster/zapp-react-native-utils/theme";
|
|
8
|
-
import { styleKeys } from "@applicaster/zapp-react-native-utils/styleKeysUtils";
|
|
9
|
-
|
|
10
|
-
type Props = {
|
|
11
|
-
styles: {};
|
|
12
|
-
error: {};
|
|
13
|
-
remoteConfigurations: { localizations: {} };
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
const defaultAppStyles = {
|
|
17
|
-
loading_error_label: {
|
|
18
|
-
color: "#aaa",
|
|
19
|
-
},
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
const textStyles = (appStyles = defaultAppStyles): TextStyle => ({
|
|
23
|
-
color: getAppStylesColor("loading_error_label", appStyles),
|
|
24
|
-
fontSize: 36,
|
|
25
|
-
textAlign: "center",
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
const errorStyles = ({ backgroundColor }): ViewStyle => ({
|
|
29
|
-
flex: 1,
|
|
30
|
-
width: "100%",
|
|
31
|
-
height: "100%",
|
|
32
|
-
justifyContent: "center",
|
|
33
|
-
alignItems: "center",
|
|
34
|
-
position: "absolute",
|
|
35
|
-
zIndex: 100,
|
|
36
|
-
backgroundColor,
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
export function ErrorDisplayComponent({
|
|
40
|
-
styles,
|
|
41
|
-
remoteConfigurations: { localizations },
|
|
42
|
-
}: Props) {
|
|
43
|
-
const theme = useTheme();
|
|
44
|
-
const backgroundColor = theme?.app_background_color;
|
|
45
|
-
|
|
46
|
-
const { stream_error_message = "Cannot play stream" } = getLocalizations({
|
|
47
|
-
localizations,
|
|
48
|
-
});
|
|
49
|
-
|
|
50
|
-
const appStyles = R.prop(styleKeys.style_namespace, styles);
|
|
51
|
-
|
|
52
|
-
return (
|
|
53
|
-
<View style={errorStyles({ backgroundColor })}>
|
|
54
|
-
<Text style={textStyles(appStyles)}>{stream_error_message}</Text>
|
|
55
|
-
</View>
|
|
56
|
-
);
|
|
57
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as R from "ramda";
|
|
2
|
-
|
|
3
|
-
import { connectToStore } from "@applicaster/zapp-react-native-redux/utils/connectToStore";
|
|
4
|
-
|
|
5
|
-
import { ErrorDisplayComponent } from "./ErrorDisplay";
|
|
6
|
-
|
|
7
|
-
export const ErrorDisplay = R.compose(
|
|
8
|
-
connectToStore(R.pick(["remoteConfigurations"]))
|
|
9
|
-
)(ErrorDisplayComponent);
|