@applicaster/zapp-react-native-ui-components 12.0.0-rc.62 → 12.0.0-rc.63

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.
@@ -4,6 +4,7 @@ import { usePlayer } from "@applicaster/zapp-react-native-utils/appUtils/playerM
4
4
 
5
5
  type DynamicBadgeProps = {
6
6
  cellUUID?: string;
7
+ uri?: string;
7
8
  };
8
9
 
9
10
  const DynamicBadgeComponent = (props: DynamicBadgeProps) => {
@@ -12,11 +13,12 @@ const DynamicBadgeComponent = (props: DynamicBadgeProps) => {
12
13
  // TODO: Initial value should depends on player state (playing or not)
13
14
  const [showImage, setShowImage] = React.useState(true);
14
15
  const player = usePlayer(playerId);
16
+ const uri = props?.uri;
15
17
 
16
18
  React.useEffect(() => {
17
19
  if (playerId && player) {
18
20
  return player.addListener({
19
- id: "dynamic-badges",
21
+ id: `dynamic-badges-${uri}`,
20
22
  listener: {
21
23
  onPlayerClose: () => {
22
24
  setShowImage(true);
@@ -35,7 +37,7 @@ const DynamicBadgeComponent = (props: DynamicBadgeProps) => {
35
37
  } else {
36
38
  setShowImage(true);
37
39
  }
38
- }, [player]);
40
+ }, [player, uri]);
39
41
 
40
42
  if (!showImage) {
41
43
  return null;
@@ -96,7 +96,7 @@ const getEdges = (isTablet: boolean, isInlineModal: boolean) => {
96
96
  }
97
97
 
98
98
  if (!isInlineModal && Platform.OS === "android") {
99
- return [];
99
+ return ["top", "left", "right", "bottom"];
100
100
  }
101
101
 
102
102
  return ["top"];
@@ -161,7 +161,7 @@ export const PlayerWrapper = (props: Props) => {
161
161
  width: isInlineModal && docked ? undefined : baseDimensions.width,
162
162
  aspectRatio: !isInlineModal && !pip ? getScreenAspectRatio() : 16 / 9,
163
163
  }),
164
- [baseDimensions, isInlineModal, pip]
164
+ [baseDimensions, isInlineModal, pip, docked]
165
165
  );
166
166
 
167
167
  const containerDimensions: DimensionsT = React.useMemo(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/zapp-react-native-ui-components",
3
- "version": "12.0.0-rc.62",
3
+ "version": "12.0.0-rc.63",
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",
@@ -34,10 +34,10 @@
34
34
  "redux-mock-store": "^1.5.3"
35
35
  },
36
36
  "dependencies": {
37
- "@applicaster/applicaster-types": "12.0.0-rc.62",
38
- "@applicaster/zapp-react-native-bridge": "12.0.0-rc.62",
39
- "@applicaster/zapp-react-native-redux": "12.0.0-rc.62",
40
- "@applicaster/zapp-react-native-utils": "12.0.0-rc.62",
37
+ "@applicaster/applicaster-types": "12.0.0-rc.63",
38
+ "@applicaster/zapp-react-native-bridge": "12.0.0-rc.63",
39
+ "@applicaster/zapp-react-native-redux": "12.0.0-rc.63",
40
+ "@applicaster/zapp-react-native-utils": "12.0.0-rc.63",
41
41
  "promise": "^8.3.0",
42
42
  "react-router-native": "^5.1.2",
43
43
  "url": "^0.11.0",