@quintype/native-components 2.19.18 → 2.19.20

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/CHANGELOG.md CHANGED
@@ -2,6 +2,21 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [2.19.20](https://github.com/quintype/native-components/compare/v2.19.19...v2.19.20) (2022-11-07)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * **android:** Fixes Nov 4 critical issue that breaks Android :hammer: ([e6d6c27](https://github.com/quintype/native-components/commit/e6d6c27e55ddbe9542ef3c7733273e4bbe9a1aa2))
11
+
12
+ ### [2.19.19](https://github.com/quintype/native-components/compare/v2.19.18...v2.19.19) (2022-08-24)
13
+
14
+
15
+ ### Bug Fixes
16
+
17
+ * **Ads:** Change midcontentAd logic for video-story :hammer: ([#186](https://github.com/quintype/native-components/issues/186)) ([b04a16c](https://github.com/quintype/native-components/commit/b04a16cb74f06c3a3f5639df31b39b2ecd4b6704))
18
+ * **deps:** Fixes dependency-conflict due to incorrect react-native version :hammer: ([b43e8ae](https://github.com/quintype/native-components/commit/b43e8ae0e4cf92d3fce21336c3cdd6c2d73db582))
19
+
5
20
  ### [2.19.18](https://github.com/quintype/native-components/compare/v2.19.17...v2.19.18) (2022-07-04)
6
21
 
7
22
  ### [2.19.17](https://github.com/quintype/native-components/compare/v2.19.14...v2.19.17) (2022-06-29)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quintype/native-components",
3
- "version": "2.19.18",
3
+ "version": "2.19.20",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -29,8 +29,8 @@
29
29
  "peerDependencies": {
30
30
  "@react-navigation/native": ">=5.7.3",
31
31
  "lodash": ">=4.17.20",
32
- "react": ">=16.13.1",
33
- "react-native": ">=0.63.2",
32
+ "react": ">=17.0.2",
33
+ "react-native": ">=0.67.5",
34
34
  "react-native-fast-image": ">=8.3.2",
35
35
  "react-native-pdf": ">=6.2.0",
36
36
  "react-native-webview": ">=11.0.0",
@@ -53,8 +53,8 @@
53
53
  "husky": "^4.2.5",
54
54
  "jest": "^26.4.0",
55
55
  "metro-react-native-babel-preset": "^0.62.0",
56
- "react": "^16.13.1",
57
- "react-native": "^0.68.0",
56
+ "react": "17.0.2",
57
+ "react-native": "0.67.4",
58
58
  "react-native-device-info": "^5.6.5",
59
59
  "react-native-gesture-handler": "^1.9.0",
60
60
  "react-native-svg": "^12.3.0",
@@ -119,9 +119,11 @@ const getStoryCards = (
119
119
  )}
120
120
  {/* Skip first card if it's a listicle */}
121
121
 
122
- {source.length > 1 && (!STORY_TYPES.VIDEO_STORY || source.length > 2) && isMiddleIndexOfArray(index, source) && getAd(true)}
123
- {/* ^ Requesting Ad if there are multiple cards. Sending param true for mid-content ad
124
- If the story is from video template and have single card then not showing mid-ad */}
122
+ {source.length > (storyType === STORY_TYPES.VIDEO_STORY ? 2 : 1)
123
+ && isMiddleIndexOfArray(index, source)
124
+ && getAd(true)}
125
+ {/* ^ Requesting mid-content-ad if there are > 1 card
126
+ (> 2 cards in case of video story since the 1st card gets rendered in header). */}
125
127
 
126
128
  {(card['story-elements'] || []).map((storyElement, index, source) => {
127
129
  /* Skip the first video element for video story */
@@ -130,10 +132,12 @@ const getStoryCards = (
130
132
  return (
131
133
  <>
132
134
  {cards.length === 1
133
- && source.length > 1
134
- && isMiddleIndexOfArray(index, source)
135
- && getAd(true)}
136
- {/* ^ Requesting Ad if there's just one card but multiple elements. Sending param true for mid-content ad */}
135
+ && source.length > (storyType === STORY_TYPES.VIDEO_STORY ? 2 : 1)
136
+ && isMiddleIndexOfArray(index, source)
137
+ && getAd(true)}
138
+ {/* ^ In the case of a story having just 1 card,
139
+ requesting mid-content-Ad if there are > 1 story-elements in that card
140
+ (> 2 story-elements in case of video story since the 1st story-element gets rendered in header). */}
137
141
 
138
142
  <StoryContent
139
143
  testID={contentTestID}