@quintype/arrow 3.15.1-perf.2 → 3.15.1-perf.3

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.
Files changed (92) hide show
  1. package/atoms/Author/index.js +38 -29
  2. package/atoms/AuthorWithTime/index.js +83 -73
  3. package/atoms/CollectionName/index.js +40 -30
  4. package/atoms/ExtendedLoadMore/{index-d0f6c865.js → index-3976fac4.js} +59 -51
  5. package/atoms/ExtendedLoadMore/{index-1e444d20.js → index-3c4ac692.js} +243 -208
  6. package/atoms/ExtendedLoadMore/index-4ddfe28d.js +93 -0
  7. package/atoms/ExtendedLoadMore/{index-c61a16dc.js → index-5c8eda4a.js} +88 -80
  8. package/atoms/ExtendedLoadMore/{index-1256e453.js → index-6e083738.js} +60 -52
  9. package/atoms/ExtendedLoadMore/{index-fd651f70.js → index-6ecceae4.js} +58 -50
  10. package/atoms/ExtendedLoadMore/{index-4356ce04.js → index-9e0d32b7.js} +76 -68
  11. package/atoms/ExtendedLoadMore/{index-beed3a68.js → index-a5c95f84.js} +70 -62
  12. package/atoms/ExtendedLoadMore/{index-0519e570.js → index-b22f1843.js} +70 -62
  13. package/atoms/ExtendedLoadMore/{index-e4cf9cb7.js → index-b5936059.js} +72 -64
  14. package/atoms/ExtendedLoadMore/{index-aba6b278.js → index-bc129cb8.js} +57 -49
  15. package/atoms/ExtendedLoadMore/{index-ad3c83c3.js → index-e7cde739.js} +74 -46
  16. package/atoms/ExtendedLoadMore/{index-c2f73d18.js → index-fee73a14.js} +62 -54
  17. package/atoms/ExtendedLoadMore/index.js +13 -5
  18. package/atoms/ExtendedLoadMore/styles.arrow.css +1 -1
  19. package/atoms/Headline/index.js +85 -76
  20. package/atoms/HeroImage/index.js +69 -60
  21. package/atoms/LoadmoreButton/index.js +32 -23
  22. package/atoms/ScrollSnap/index.js +72 -63
  23. package/atoms/SectionTag/index.js +34 -25
  24. package/atoms/Subheadline/index.js +31 -22
  25. package/atoms/TimeStamp/index.js +34 -24
  26. package/molecules/KeyEvents/index.js +72 -61
  27. package/molecules/PageIntroductionCard/index.js +43 -34
  28. package/molecules/SocialShareTemplate/index.js +97 -88
  29. package/molecules/StoryCard/index.js +242 -232
  30. package/molecules/StoryElementCard/index.js +512 -483
  31. package/molecules/StorycardContent/index.js +172 -162
  32. package/package.json +1 -1
  33. package/rows/AlternateCollectionFilter/index.js +345 -333
  34. package/rows/AsideCollection/index.js +340 -328
  35. package/rows/AstrologyCollection/index.js +321 -309
  36. package/rows/AuthorIntroductionCard/index.js +157 -148
  37. package/rows/AuthorsList/index.js +184 -174
  38. package/rows/CollectionFilter/index.js +361 -349
  39. package/rows/ElevenStories/index.js +357 -346
  40. package/rows/FourColFiveStories/index.js +304 -274
  41. package/rows/FourColGrid/index.js +351 -321
  42. package/rows/FourColPortraitStories/index.js +357 -327
  43. package/rows/FourColSixteenStories/index.js +288 -277
  44. package/rows/FourColTwelveStories/index.js +315 -304
  45. package/rows/FourStorySlider/index.js +358 -347
  46. package/rows/FourStorySliderPortrait/index.js +359 -348
  47. package/rows/FourTabbedBigStorySlider/index.js +322 -311
  48. package/rows/FullScreenSlider/index.js +336 -325
  49. package/rows/HalfScreenSlider/index.js +308 -297
  50. package/rows/ListComponent/index.js +322 -311
  51. package/rows/Listicles/index.js +150 -139
  52. package/rows/MagazineEditions/index.js +104 -93
  53. package/rows/MagazineHeaderCard/index.js +104 -93
  54. package/rows/MagazineWidget/index.js +326 -315
  55. package/rows/OneColStoryList/index.js +365 -335
  56. package/rows/OpinionCollection/index.js +250 -220
  57. package/rows/SixColSixStories/index.js +333 -303
  58. package/rows/StoryCollection/index.js +340 -328
  59. package/rows/TagIntroductionCard/index.js +30 -21
  60. package/rows/ThreeColFlexStories/index.js +348 -318
  61. package/rows/ThreeColFourteenStories/index.js +285 -274
  62. package/rows/ThreeColGrid/index.js +352 -322
  63. package/rows/ThreeColSevenStory/index.js +322 -311
  64. package/rows/ThreeColSixStories/index.js +323 -312
  65. package/rows/ThreeColTwelveStories/index.js +302 -291
  66. package/rows/TwoColFourStories/index.js +316 -305
  67. package/rows/TwoColFourStoryHighlight/index.js +317 -306
  68. package/rows/TwoColSevenStories/index.js +322 -311
  69. package/rows/TwoColSixStories/index.js +316 -305
  70. package/rows/TwoColTenStoriesSidebar/index.js +338 -327
  71. package/rows/TwoColThreeStories/index.js +316 -305
  72. package/story-elements/AlsoRead/index.js +70 -61
  73. package/story-elements/Attachment/index.js +40 -31
  74. package/story-elements/BigFact/index.js +35 -26
  75. package/story-elements/BlockQuote/index.js +61 -51
  76. package/story-elements/Blurb/index.js +36 -27
  77. package/story-elements/Image/index.js +113 -86
  78. package/story-elements/ImageGallery/index.js +98 -71
  79. package/story-elements/ImageSlideshow/index.js +147 -120
  80. package/story-elements/QuestionAnswer/index.js +55 -46
  81. package/story-elements/Quote/index.js +37 -28
  82. package/story-elements/Reference/index.js +40 -31
  83. package/story-elements/StoryElement/index.js +28 -19
  84. package/story-elements/Summary/index.js +40 -31
  85. package/story-elements/Text/index.js +34 -25
  86. package/story-elements/Video/index.js +29 -20
  87. package/story-templates/ListicleStoryTemplate/index.js +937 -908
  88. package/story-templates/LiveBlogStoryTemplate/index.js +942 -913
  89. package/story-templates/PhotoStoryTemplate/index.js +912 -883
  90. package/story-templates/TextStoryTemplate/index.js +931 -902
  91. package/story-templates/VideoStoryTemplate/index.js +897 -868
  92. package/atoms/ExtendedLoadMore/index-81eb3978.js +0 -86
@@ -1,8 +1,15 @@
1
- import { a as get_1, g as getTextColor, _ as _getClassName, t as truncate, i as isEmpty, r as rgbToHex } from './index-ad3c83c3.js';
2
- import React from 'react';
3
- import { u as useStateValue, H as Headline, A as AuthorWithTime } from './index-1e444d20.js';
4
- import PropTypes from 'prop-types';
5
- import { H as HeroImage, S as SectionTag } from './index-c61a16dc.js';
1
+ 'use strict';
2
+
3
+ var index$1 = require('./index-e7cde739.js');
4
+ var React = require('react');
5
+ var index = require('./index-3c4ac692.js');
6
+ var PropTypes = require('prop-types');
7
+ var index$2 = require('./index-5c8eda4a.js');
8
+
9
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
10
+
11
+ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
12
+ var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
6
13
 
7
14
  var _styleModuleImportMap$1 = {
8
15
  "./subheadline.m.css": {
@@ -20,29 +27,29 @@ var Subheadline = function Subheadline(_ref) {
20
27
  clazzName = _ref$clazzName === void 0 ? "" : _ref$clazzName,
21
28
  forceShowAtom = _ref.forceShowAtom,
22
29
  showFullContent = _ref.showFullContent;
23
- var config = useStateValue() || {};
24
- var subheadline = forceShowAtom || get_1(config, ["showSubheadline"], true);
30
+ var config = index.useStateValue() || {};
31
+ var subheadline = forceShowAtom || index$1.get_1(config, ["showSubheadline"], true);
25
32
  if (!subheadline) return null;
26
- var textColor = getTextColor(config.theme);
27
- return /*#__PURE__*/React.createElement("div", {
33
+ var textColor = index$1.getTextColor(config.theme);
34
+ return /*#__PURE__*/React__default["default"].createElement("div", {
28
35
  style: {
29
36
  WebkitLineClamp: lineClamp
30
37
  },
31
38
  "data-test-id": "subheadline",
32
- className: ("p-alt arr--sub-headline arrow-component ".concat(clazzName) ? "p-alt arr--sub-headline arrow-component ".concat(clazzName) + " " : "") + _getClassName("subheadline ".concat(textColor), _styleModuleImportMap$1)
33
- }, showFullContent || typeof lineClamp === "number" ? story.subheadline : truncate(story.subheadline, truncateChars, true));
39
+ className: ("p-alt arr--sub-headline arrow-component ".concat(clazzName) ? "p-alt arr--sub-headline arrow-component ".concat(clazzName) + " " : "") + index$1._getClassName("subheadline ".concat(textColor), _styleModuleImportMap$1)
40
+ }, showFullContent || typeof lineClamp === "number" ? story.subheadline : index$1.truncate(story.subheadline, truncateChars, true));
34
41
  };
35
42
  Subheadline.propTypes = {
36
43
  /** The Story Object from the API response */
37
- story: PropTypes.object.isRequired,
44
+ story: PropTypes__default["default"].object.isRequired,
38
45
  // Restricts the number of lines for subheadline.
39
- lineClamp: PropTypes.number,
46
+ lineClamp: PropTypes__default["default"].number,
40
47
 
41
48
  /** Number of characters to truncate the subheadline */
42
- truncateChars: PropTypes.number,
43
- clazzName: PropTypes.string,
44
- forceShowAtom: PropTypes.bool,
45
- showFullContent: PropTypes.bool
49
+ truncateChars: PropTypes__default["default"].number,
50
+ clazzName: PropTypes__default["default"].string,
51
+ forceShowAtom: PropTypes__default["default"].bool,
52
+ showFullContent: PropTypes__default["default"].bool
46
53
  };
47
54
  Subheadline.defaultProps = {
48
55
  forceShowAtom: false,
@@ -91,7 +98,7 @@ var StoryCard = function StoryCard(_ref) {
91
98
  prefix = _ref.prefix,
92
99
  config = _ref.config,
93
100
  isHorizontalWithImageLast = _ref.isHorizontalWithImageLast;
94
- if (!story || isEmpty(story)) return /*#__PURE__*/React.createElement("div", null);
101
+ if (!story || index$1.isEmpty(story)) return /*#__PURE__*/React__default["default"].createElement("div", null);
95
102
  var borderOptions = ["default", "full", "bottom", "boxShadow"];
96
103
  var borderTemplate = borderOptions.includes(border) ? "border-".concat(border) : ""; // TODO optimize conditions
97
104
 
@@ -99,9 +106,9 @@ var StoryCard = function StoryCard(_ref) {
99
106
  if (isHorizontal) horizontalCardStyle = "horizontal-card";else if (isHorizontalWithImageLast) horizontalCardStyle = "horizontal-image-last";
100
107
  var bgImageClasses = useImageAsBackground ? "backgroung-img" : "";
101
108
  var bgImgContentOverlapClass = bgImgContentOverlap ? "content-overlap" : "";
102
- var textColor = getTextColor(theme);
109
+ var textColor = index$1.getTextColor(theme);
103
110
  var horizontalMobileClasses = isHorizontalMobile ? "horizontal-mob" : "";
104
- var defaultStorycard = /*#__PURE__*/React.createElement(DefaultStoryCard, {
111
+ var defaultStorycard = /*#__PURE__*/React__default["default"].createElement(DefaultStoryCard, {
105
112
  story: story,
106
113
  aspectRatio: aspectRatio,
107
114
  border: border,
@@ -115,13 +122,13 @@ var StoryCard = function StoryCard(_ref) {
115
122
  config: config,
116
123
  isHorizontalWithImageLast: isHorizontalWithImageLast
117
124
  });
118
- return /*#__PURE__*/React.createElement("div", {
125
+ return /*#__PURE__*/React__default["default"].createElement("div", {
119
126
  "data-test-id": "story-card",
120
127
  style: {
121
128
  backgroundColor: theme,
122
129
  color: textColor
123
130
  },
124
- className: "arr--story-card " + _getClassName("card ".concat(horizontalCardStyle, " ").concat(borderTemplate, " ").concat(textColor, " ").concat(bgImageClasses, " ").concat(bgImgContentOverlapClass, " ").concat(horizontalMobileClasses), _styleModuleImportMap)
131
+ className: "arr--story-card " + index$1._getClassName("card ".concat(horizontalCardStyle, " ").concat(borderTemplate, " ").concat(textColor, " ").concat(bgImageClasses, " ").concat(bgImgContentOverlapClass, " ").concat(horizontalMobileClasses), _styleModuleImportMap)
125
132
  }, children || defaultStorycard);
126
133
  };
127
134
 
@@ -141,94 +148,94 @@ var DefaultStoryCard = function DefaultStoryCard(_ref2) {
141
148
  isHorizontalWithImageLast = _ref2.isHorizontalWithImageLast,
142
149
  config = _ref2.config;
143
150
  var alignment = centerAlign ? "center-align" : "";
144
- var SectionTagborderColor = rgbToHex(borderColor);
151
+ var SectionTagborderColor = index$1.rgbToHex(borderColor);
145
152
  var _config$localizationC = config.localizationConfig,
146
153
  localizationConfig = _config$localizationC === void 0 ? {} : _config$localizationC;
147
- return /*#__PURE__*/React.createElement(React.Fragment, null, isHorizontal ? /*#__PURE__*/React.createElement(HeroImage, {
154
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isHorizontal ? /*#__PURE__*/React__default["default"].createElement(index$2.HeroImage, {
148
155
  config: config,
149
156
  story: story,
150
157
  isHorizontal: true,
151
158
  isHorizontalMobile: isHorizontalMobile,
152
159
  aspectRatio: aspectRatio
153
- }) : isHorizontalWithImageLast ? /*#__PURE__*/React.createElement(HeroImage, {
160
+ }) : isHorizontalWithImageLast ? /*#__PURE__*/React__default["default"].createElement(index$2.HeroImage, {
154
161
  config: config,
155
162
  story: story,
156
163
  isHorizontalWithImageLast: true,
157
164
  isHorizontalMobile: isHorizontalMobile,
158
165
  aspectRatio: aspectRatio
159
- }) : /*#__PURE__*/React.createElement(HeroImage, {
166
+ }) : /*#__PURE__*/React__default["default"].createElement(index$2.HeroImage, {
160
167
  story: story,
161
168
  config: config,
162
169
  isHorizontalMobile: isHorizontalMobile,
163
170
  aspectRatio: aspectRatio
164
- }), /*#__PURE__*/React.createElement("div", {
165
- className: "arr--story-content " + _getClassName("content ".concat(alignment), _styleModuleImportMap)
166
- }, /*#__PURE__*/React.createElement(SectionTag, {
171
+ }), /*#__PURE__*/React__default["default"].createElement("div", {
172
+ className: "arr--story-content " + index$1._getClassName("content ".concat(alignment), _styleModuleImportMap)
173
+ }, /*#__PURE__*/React__default["default"].createElement(index$2.SectionTag, {
167
174
  story: story,
168
175
  borderColor: SectionTagborderColor
169
- }), /*#__PURE__*/React.createElement(Headline, {
176
+ }), /*#__PURE__*/React__default["default"].createElement(index.Headline, {
170
177
  story: story,
171
178
  headerLevel: headerLevel,
172
179
  premiumStoryIconConfig: config
173
- }), /*#__PURE__*/React.createElement(AuthorWithTime, {
180
+ }), /*#__PURE__*/React__default["default"].createElement(index.AuthorWithTime, {
174
181
  config: localizationConfig,
175
182
  story: story,
176
183
  isBottom: true,
177
184
  prefix: prefix,
178
185
  hideAuthorImage: hideAuthorImage
179
- }), /*#__PURE__*/React.createElement(Subheadline, {
186
+ }), /*#__PURE__*/React__default["default"].createElement(Subheadline, {
180
187
  story: story
181
188
  })));
182
189
  };
183
190
 
184
191
  DefaultStoryCard.propTypes = {
185
- story: PropTypes.object.isRequired,
186
- border: PropTypes.oneOfType([PropTypes.string]),
187
- isBottom: PropTypes.bool,
188
- isHorizontal: PropTypes.bool,
189
- aspectRatio: PropTypes.oneOfType([PropTypes.array]),
190
- isHorizontalMobile: PropTypes.bool,
191
- centerAlign: PropTypes.bool,
192
- headerLevel: PropTypes.string,
193
- borderColor: PropTypes.string,
194
- hideAuthorImage: PropTypes.bool,
195
- prefix: PropTypes.string,
196
- config: PropTypes.object,
197
- isHorizontalWithImageLast: PropTypes.bool
192
+ story: PropTypes__default["default"].object.isRequired,
193
+ border: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string]),
194
+ isBottom: PropTypes__default["default"].bool,
195
+ isHorizontal: PropTypes__default["default"].bool,
196
+ aspectRatio: PropTypes__default["default"].oneOfType([PropTypes__default["default"].array]),
197
+ isHorizontalMobile: PropTypes__default["default"].bool,
198
+ centerAlign: PropTypes__default["default"].bool,
199
+ headerLevel: PropTypes__default["default"].string,
200
+ borderColor: PropTypes__default["default"].string,
201
+ hideAuthorImage: PropTypes__default["default"].bool,
202
+ prefix: PropTypes__default["default"].string,
203
+ config: PropTypes__default["default"].object,
204
+ isHorizontalWithImageLast: PropTypes__default["default"].bool
198
205
  };
199
206
  StoryCard.propTypes = {
200
207
  /** The Story Object from the API response */
201
- story: PropTypes.object.isRequired,
202
- children: PropTypes.node,
208
+ story: PropTypes__default["default"].object.isRequired,
209
+ children: PropTypes__default["default"].node,
203
210
 
204
211
  /** Flip the Story Card to Horizonal mode */
205
- isHorizontal: PropTypes.bool,
212
+ isHorizontal: PropTypes__default["default"].bool,
206
213
 
207
214
  /** Add border to the Story Card */
208
- border: PropTypes.oneOfType([PropTypes.string]),
215
+ border: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string]),
209
216
  // story card with background image
210
- useImageAsBackground: PropTypes.bool,
217
+ useImageAsBackground: PropTypes__default["default"].bool,
211
218
  // story card content overlap with image
212
- bgImgContentOverlap: PropTypes.bool,
219
+ bgImgContentOverlap: PropTypes__default["default"].bool,
213
220
 
214
221
  /** add aspect ratio for hero image */
215
- aspectRatio: PropTypes.oneOfType([PropTypes.array]),
222
+ aspectRatio: PropTypes__default["default"].oneOfType([PropTypes__default["default"].array]),
216
223
 
217
224
  /** add theme(dark /light/custom color) for storycard */
218
- theme: PropTypes.string,
225
+ theme: PropTypes__default["default"].string,
219
226
 
220
227
  /** flip the story card mobile design horizontal */
221
- isHorizontalMobile: PropTypes.bool,
228
+ isHorizontalMobile: PropTypes__default["default"].bool,
222
229
  // make content center align in desktop and left align in mobile
223
- centerAlign: PropTypes.bool,
224
- headerLevel: PropTypes.string,
225
- borderColor: PropTypes.string,
230
+ centerAlign: PropTypes__default["default"].bool,
231
+ headerLevel: PropTypes__default["default"].string,
232
+ borderColor: PropTypes__default["default"].string,
226
233
  // handle author image through storycard
227
- hideAuthorImage: PropTypes.bool,
234
+ hideAuthorImage: PropTypes__default["default"].bool,
228
235
  // handle author prefix through storycard
229
- prefix: PropTypes.string,
230
- config: PropTypes.object,
231
- isHorizontalWithImageLast: PropTypes.bool
236
+ prefix: PropTypes__default["default"].string,
237
+ config: PropTypes__default["default"].object,
238
+ isHorizontalWithImageLast: PropTypes__default["default"].bool
232
239
  };
233
240
  StoryCard.defaultProps = {
234
241
  isHorizontal: false,
@@ -240,4 +247,5 @@ StoryCard.defaultProps = {
240
247
  isHorizontalWithImageLast: false
241
248
  };
242
249
 
243
- export { StoryCard as S, Subheadline as a };
250
+ exports.StoryCard = StoryCard;
251
+ exports.Subheadline = Subheadline;
@@ -1,14 +1,21 @@
1
- import { collectionToStories } from '@quintype/components';
2
- import { a as get_1, l as getSlot, g as getTextColor, b as generateNavigateSlug, n as navigateTo } from './index-ad3c83c3.js';
3
- import PropTypes from 'prop-types';
4
- import React from 'react';
5
- import { useDispatch, useSelector } from 'react-redux';
6
- import { C as CollectionName, S as StateProvider, H as Headline, A as AuthorWithTime, L as LoadMoreTarget, P as ProgressiveHydration, a as LoadmoreButton } from './index-1e444d20.js';
7
- import { H as HeroImage, S as SectionTag } from './index-c61a16dc.js';
8
- import { S as StoryCard } from './index-0519e570.js';
9
- import 'react-timeago';
10
- import 'date-fns-tz';
11
- import 'react-dom';
1
+ 'use strict';
2
+
3
+ var components = require('@quintype/components');
4
+ var index = require('./index-e7cde739.js');
5
+ var PropTypes = require('prop-types');
6
+ var React = require('react');
7
+ var reactRedux = require('react-redux');
8
+ var index$1 = require('./index-3c4ac692.js');
9
+ var index$3 = require('./index-5c8eda4a.js');
10
+ var index$2 = require('./index-b22f1843.js');
11
+ require('react-timeago');
12
+ require('date-fns-tz');
13
+ require('react-dom');
14
+
15
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
16
+
17
+ var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
18
+ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
12
19
 
13
20
  var FlexCard = function FlexCard(_ref) {
14
21
  var _ref$story = _ref.story,
@@ -23,28 +30,28 @@ var FlexCard = function FlexCard(_ref) {
23
30
  theme = _config$theme === void 0 ? "" : _config$theme,
24
31
  _config$localizationC = config.localizationConfig,
25
32
  localizationConfig = _config$localizationC === void 0 ? {} : _config$localizationC;
26
- return /*#__PURE__*/React.createElement("div", {
33
+ return /*#__PURE__*/React__default["default"].createElement("div", {
27
34
  className: "three-col-flex-stories-m_card__2uZ3Q"
28
- }, /*#__PURE__*/React.createElement(StoryCard, {
35
+ }, /*#__PURE__*/React__default["default"].createElement(index$2.StoryCard, {
29
36
  story: story,
30
37
  isHorizontal: true,
31
38
  theme: theme,
32
39
  border: border,
33
40
  borderColor: borderColor,
34
41
  config: config
35
- }, /*#__PURE__*/React.createElement(HeroImage, {
42
+ }, /*#__PURE__*/React__default["default"].createElement(index$3.HeroImage, {
36
43
  story: story,
37
44
  aspectRatio: [[9, 5], [9, 5]]
38
- }), /*#__PURE__*/React.createElement("div", {
45
+ }), /*#__PURE__*/React__default["default"].createElement("div", {
39
46
  className: "small-card-container three-col-flex-stories-m_card-content__1z9nt"
40
- }, /*#__PURE__*/React.createElement(SectionTag, {
47
+ }, /*#__PURE__*/React__default["default"].createElement(index$3.SectionTag, {
41
48
  story: story,
42
49
  borderColor: borderColor
43
- }), /*#__PURE__*/React.createElement(Headline, {
50
+ }), /*#__PURE__*/React__default["default"].createElement(index$1.Headline, {
44
51
  story: story,
45
52
  headerLevel: "6",
46
53
  premiumStoryIconConfig: config
47
- }), /*#__PURE__*/React.createElement(AuthorWithTime, {
54
+ }), /*#__PURE__*/React__default["default"].createElement(index$1.AuthorWithTime, {
48
55
  config: localizationConfig,
49
56
  story: story,
50
57
  prefix: "By"
@@ -73,7 +80,7 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
73
80
  isLoading = _ref3.isLoading,
74
81
  isolatedLoadMore = _ref3.isolatedLoadMore,
75
82
  hideFirstCard = _ref3.hideFirstCard;
76
- var collectionItems = collectionToStories(collection);
83
+ var collectionItems = components.collectionToStories(collection);
77
84
 
78
85
  if (collectionItems.length < 1) {
79
86
  return null;
@@ -92,25 +99,25 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
92
99
  _config$subsequentLoa = config.subsequentLoadCount,
93
100
  subsequentLoadCount = _config$subsequentLoa === void 0 ? 3 : _config$subsequentLoa;
94
101
 
95
- var _get = get_1(slotConfig, [0], {}),
102
+ var _get = index.get_1(slotConfig, [0], {}),
96
103
  _get$type = _get.type,
97
104
  type = _get$type === void 0 ? "story" : _get$type,
98
105
  component = _get.component;
99
106
 
100
107
  var isAdWidgetEnabled = type === "ad" || type === "widget";
101
- var adWidgetSlot = isAdWidgetEnabled ? getSlot(type, component) : null;
102
- var textColor = getTextColor(theme);
103
- var stories = type !== "story" ? collectionItems : collectionToStories(collection);
104
- var dispatch = useDispatch();
105
- var qtConfig = useSelector(function (state) {
106
- return get_1(state, ["qt", "config"], {});
108
+ var adWidgetSlot = isAdWidgetEnabled ? index.getSlot(type, component) : null;
109
+ var textColor = index.getTextColor(theme);
110
+ var stories = type !== "story" ? collectionItems : components.collectionToStories(collection);
111
+ var dispatch = reactRedux.useDispatch();
112
+ var qtConfig = reactRedux.useSelector(function (state) {
113
+ return index.get_1(state, ["qt", "config"], {});
107
114
  });
108
115
 
109
116
  var getLoadMore = function getLoadMore(opts) {
110
117
  if (!isLoadMoreVisible) return null;
111
118
 
112
119
  if (isolatedLoadMore) {
113
- return /*#__PURE__*/React.createElement(LoadMoreTarget, {
120
+ return /*#__PURE__*/React__default["default"].createElement(index$1.LoadMoreTarget, {
114
121
  collection: collection,
115
122
  componentName: "ThreeColFlexStories",
116
123
  offset: stories.length,
@@ -118,8 +125,8 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
118
125
  });
119
126
  }
120
127
 
121
- var url = generateNavigateSlug(collection, qtConfig);
122
- return /*#__PURE__*/React.createElement(ProgressiveHydration, null, /*#__PURE__*/React.createElement(LoadmoreButton, {
128
+ var url = index.generateNavigateSlug(collection, qtConfig);
129
+ return /*#__PURE__*/React__default["default"].createElement(index$1.ProgressiveHydration, null, /*#__PURE__*/React__default["default"].createElement(index$1.LoadmoreButton, {
123
130
  config: config,
124
131
  collection: collection,
125
132
  template: footerButton,
@@ -127,50 +134,50 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
127
134
  return loadMore(opts);
128
135
  },
129
136
  navigate: function navigate() {
130
- return navigateTo(dispatch, url);
137
+ return index.navigateTo(dispatch, url);
131
138
  },
132
139
  qtConfig: qtConfig
133
140
  }));
134
141
  };
135
142
 
136
- return /*#__PURE__*/React.createElement("div", {
143
+ return /*#__PURE__*/React__default["default"].createElement("div", {
137
144
  className: "full-width-with-padding arrow-component",
138
145
  "data-test-id": "three-col-flex-stories",
139
146
  style: {
140
147
  backgroundColor: theme,
141
148
  color: textColor
142
149
  }
143
- }, /*#__PURE__*/React.createElement("div", {
150
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
144
151
  className: "three-col-flex-stories-m_wrapper__3SQMq"
145
- }, /*#__PURE__*/React.createElement(CollectionName, {
152
+ }, /*#__PURE__*/React__default["default"].createElement(index$1.CollectionName, {
146
153
  collection: collection,
147
154
  collectionNameTemplate: collectionNameTemplate,
148
155
  collectionNameBorderColor: collectionNameBorderColor,
149
156
  headerLevel: "2"
150
- }), isAdWidgetEnabled && !hideFirstCard ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
157
+ }), isAdWidgetEnabled && !hideFirstCard ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
151
158
  className: "three-col-flex-stories-m_row-with-ad__1gPPN"
152
- }, /*#__PURE__*/React.createElement("div", {
159
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
153
160
  className: "three-col-flex-stories-m_card-with-ad__32z5M"
154
161
  }, stories.slice(0, 4).map(function (story) {
155
- return /*#__PURE__*/React.createElement(FlexCard, {
162
+ return /*#__PURE__*/React__default["default"].createElement(FlexCard, {
156
163
  story: story,
157
164
  config: config,
158
165
  key: story.id
159
166
  });
160
- })), /*#__PURE__*/React.createElement("div", {
167
+ })), /*#__PURE__*/React__default["default"].createElement("div", {
161
168
  className: "three-col-flex-stories-m_ad-wrapper__3dmfM"
162
- }, adWidgetSlot)), /*#__PURE__*/React.createElement("div", {
169
+ }, adWidgetSlot)), /*#__PURE__*/React__default["default"].createElement("div", {
163
170
  className: "three-col-flex-stories-m_card-row__3WMb3"
164
171
  }, stories.slice(4).map(function (story) {
165
- return /*#__PURE__*/React.createElement(FlexCard, {
172
+ return /*#__PURE__*/React__default["default"].createElement(FlexCard, {
166
173
  story: story,
167
174
  config: config,
168
175
  key: story.id
169
176
  });
170
- }))) : /*#__PURE__*/React.createElement("div", {
177
+ }))) : /*#__PURE__*/React__default["default"].createElement("div", {
171
178
  className: "three-col-flex-stories-m_card-row__3WMb3"
172
179
  }, stories.map(function (story) {
173
- return /*#__PURE__*/React.createElement(FlexCard, {
180
+ return /*#__PURE__*/React__default["default"].createElement(FlexCard, {
174
181
  story: story,
175
182
  config: config,
176
183
  key: story.id
@@ -184,32 +191,32 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
184
191
  };
185
192
  ThreeColFlexStoriesBase.propTypes = {
186
193
  /** collection is the array of objects which is returning by API */
187
- collection: PropTypes.object.isRequired,
194
+ collection: PropTypes__default["default"].object.isRequired,
188
195
 
189
196
  /** The config for the Row */
190
- config: PropTypes.shape({
191
- borderColor: PropTypes.string,
192
- theme: PropTypes.string,
193
- border: PropTypes.string,
194
- slotConfig: PropTypes.array,
195
- footerButton: PropTypes.string,
196
- collectionNameTemplate: PropTypes.string,
197
- collectionNameBorderColor: PropTypes.string,
198
- subsequentLoadCount: PropTypes.number
197
+ config: PropTypes__default["default"].shape({
198
+ borderColor: PropTypes__default["default"].string,
199
+ theme: PropTypes__default["default"].string,
200
+ border: PropTypes__default["default"].string,
201
+ slotConfig: PropTypes__default["default"].array,
202
+ footerButton: PropTypes__default["default"].string,
203
+ collectionNameTemplate: PropTypes__default["default"].string,
204
+ collectionNameBorderColor: PropTypes__default["default"].string,
205
+ subsequentLoadCount: PropTypes__default["default"].number
199
206
  }),
200
- getMoreStories: PropTypes.func,
201
- isLoadMoreVisible: PropTypes.bool,
202
- isLoading: PropTypes.bool,
203
- isolatedLoadMore: PropTypes.bool,
204
- hideFirstCard: PropTypes.bool
207
+ getMoreStories: PropTypes__default["default"].func,
208
+ isLoadMoreVisible: PropTypes__default["default"].bool,
209
+ isLoading: PropTypes__default["default"].bool,
210
+ isolatedLoadMore: PropTypes__default["default"].bool,
211
+ hideFirstCard: PropTypes__default["default"].bool
205
212
  };
206
213
  FlexCard.propTypes = {
207
- story: PropTypes.object.isRequired,
208
- config: PropTypes.shape({
209
- borderColor: PropTypes.string,
210
- theme: PropTypes.string,
211
- border: PropTypes.string,
212
- localizationConfig: PropTypes.object
214
+ story: PropTypes__default["default"].object.isRequired,
215
+ config: PropTypes__default["default"].shape({
216
+ borderColor: PropTypes__default["default"].string,
217
+ theme: PropTypes__default["default"].string,
218
+ border: PropTypes__default["default"].string,
219
+ localizationConfig: PropTypes__default["default"].object
213
220
  })
214
221
  };
215
222
  ThreeColFlexStoriesBase.defaultProps = {
@@ -218,6 +225,7 @@ ThreeColFlexStoriesBase.defaultProps = {
218
225
  isLoading: false,
219
226
  hideFirstCard: false
220
227
  };
221
- var ThreeColFlexStories = StateProvider(ThreeColFlexStoriesBase);
228
+ var ThreeColFlexStories = index$1.StateProvider(ThreeColFlexStoriesBase);
222
229
 
223
- export { ThreeColFlexStories, ThreeColFlexStoriesBase };
230
+ exports.ThreeColFlexStories = ThreeColFlexStories;
231
+ exports.ThreeColFlexStoriesBase = ThreeColFlexStoriesBase;