@applicaster/zapp-react-native-ui-components 13.0.0-rc.68 → 13.0.0-rc.69

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.
@@ -91,6 +91,15 @@ export type PlayNextData = {
91
91
  onPlayNextPerformNextVideoPlay: () => void;
92
92
  };
93
93
 
94
+ export type PlayerState = {
95
+ duration: number;
96
+ currentTime?: number;
97
+ seekableDuration: number;
98
+ isLive: boolean;
99
+ isBuffering: boolean;
100
+ isPaused: boolean;
101
+ };
102
+
94
103
  const focusableBottomContainerId = "player-container-bottom";
95
104
 
96
105
  // Styles
@@ -34,6 +34,7 @@ type Props = {
34
34
  getStaticComponentFeed: any;
35
35
  pullToRefreshPipesV1RefreshingStateUpdater: () => boolean;
36
36
  refreshingPipesV1?: boolean;
37
+ stickyHeaderIndices?: number[];
37
38
  };
38
39
 
39
40
  const styles = StyleSheet.create({
@@ -61,6 +62,7 @@ function ComponentsMapComponent(props: Props) {
61
62
  // TODO: Remove when pipes v1 is deprecated.
62
63
  pullToRefreshPipesV1RefreshingStateUpdater,
63
64
  refreshingPipesV1,
65
+ stickyHeaderIndices,
64
66
  } = props;
65
67
 
66
68
  const flatListRef = React.useRef<FlatList | null>(null);
@@ -274,6 +276,7 @@ function ComponentsMapComponent(props: Props) {
274
276
  overScrollMode={Platform.OS === "android" ? "never" : "auto"}
275
277
  scrollIndicatorInsets={scrollIndicatorInsets}
276
278
  extraData={feed}
279
+ stickyHeaderIndices={stickyHeaderIndices}
277
280
  onLayout={handleOnLayout}
278
281
  removeClippedSubviews
279
282
  initialNumToRender={3}
@@ -28,10 +28,10 @@ type Return = {
28
28
  // TODO: Take this value from Zapp configuration, when feature is added to GeneralScreen
29
29
  const SHOULD_FAIL_ON_COMPONENT_LOADING = false;
30
30
 
31
- const createLoadingStateObservable = () =>
31
+ const createLoadingStateObservable = (count: number) =>
32
32
  new BehaviorSubject<LoadingState>({
33
33
  index: -1,
34
- done: false,
34
+ done: count === 0,
35
35
  waitForAllComponents: SHOULD_FAIL_ON_COMPONENT_LOADING,
36
36
  });
37
37
 
@@ -43,7 +43,7 @@ export const useLoadingState = (
43
43
  const [loadingError, setLoadingError] = React.useState(null);
44
44
 
45
45
  const loadingState = useRefWithInitialValue<BehaviorSubject<LoadingState>>(
46
- createLoadingStateObservable
46
+ () => createLoadingStateObservable(count)
47
47
  );
48
48
 
49
49
  const arePreviousComponentsLoaded = React.useCallback((index) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/zapp-react-native-ui-components",
3
- "version": "13.0.0-rc.68",
3
+ "version": "13.0.0-rc.69",
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",
@@ -32,10 +32,10 @@
32
32
  "redux-mock-store": "^1.5.3"
33
33
  },
34
34
  "dependencies": {
35
- "@applicaster/applicaster-types": "13.0.0-rc.68",
36
- "@applicaster/zapp-react-native-bridge": "13.0.0-rc.68",
37
- "@applicaster/zapp-react-native-redux": "13.0.0-rc.68",
38
- "@applicaster/zapp-react-native-utils": "13.0.0-rc.68",
35
+ "@applicaster/applicaster-types": "13.0.0-rc.69",
36
+ "@applicaster/zapp-react-native-bridge": "13.0.0-rc.69",
37
+ "@applicaster/zapp-react-native-redux": "13.0.0-rc.69",
38
+ "@applicaster/zapp-react-native-utils": "13.0.0-rc.69",
39
39
  "promise": "^8.3.0",
40
40
  "react-router-native": "^5.1.2",
41
41
  "url": "^0.11.0",