@quintype/arrow 3.15.1-perf.3 → 3.15.1-perf.4
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/atoms/Author/index.js +14 -2103
- package/atoms/Author/styles.arrow.css +1 -1
- package/atoms/AuthorWithTime/index.js +32 -2482
- package/atoms/AuthorWithTime/styles.arrow.css +1 -1
- package/atoms/CollectionName/index.js +12 -2101
- package/atoms/CollectionName/styles.arrow.css +1 -1
- package/atoms/ExtendedLoadMore/{index-b22f1843.js → index-0f809dd9.js} +10 -7
- package/atoms/ExtendedLoadMore/index-142f015c.js +476 -0
- package/atoms/ExtendedLoadMore/{index-bc129cb8.js → index-37a9ccff.js} +18 -10
- package/atoms/ExtendedLoadMore/{index-6e083738.js → index-446679c8.js} +20 -12
- package/atoms/ExtendedLoadMore/{index-9e0d32b7.js → index-44f97338.js} +19 -9
- package/atoms/ExtendedLoadMore/{index-b5936059.js → index-57dd4870.js} +15 -7
- package/atoms/ExtendedLoadMore/{index-fee73a14.js → index-66dd4dbd.js} +15 -7
- package/atoms/ExtendedLoadMore/{index-5c8eda4a.js → index-8462c597.js} +21 -16
- package/atoms/ExtendedLoadMore/{index-3c4ac692.js → index-93cb06d1.js} +42 -51
- package/atoms/ExtendedLoadMore/{index-4ddfe28d.js → index-afd44863.js} +6 -4
- package/atoms/ExtendedLoadMore/{index-3976fac4.js → index-b5754c5d.js} +20 -14
- package/atoms/ExtendedLoadMore/{index-a5c95f84.js → index-bbaf526e.js} +16 -8
- package/atoms/ExtendedLoadMore/{index-6ecceae4.js → index-cfb262ef.js} +18 -9
- package/atoms/ExtendedLoadMore/index.js +8 -1
- package/atoms/ExtendedLoadMore/styles.arrow.css +1 -1
- package/atoms/Headline/index.js +14 -2103
- package/atoms/Headline/styles.arrow.css +1 -1
- package/atoms/HeroImage/index.js +22 -2170
- package/atoms/HeroImage/styles.arrow.css +1 -1
- package/atoms/LoadmoreButton/index.js +12 -2114
- package/atoms/LoadmoreButton/styles.arrow.css +1 -1
- package/atoms/ScrollSnap/index.js +17 -2178
- package/atoms/ScrollSnap/styles.arrow.css +1 -1
- package/atoms/SectionTag/index.js +10 -2099
- package/atoms/SectionTag/styles.arrow.css +1 -1
- package/atoms/Subheadline/index.js +8 -2097
- package/atoms/Subheadline/styles.arrow.css +1 -1
- package/atoms/TimeStamp/index.js +13 -2463
- package/atoms/TimeStamp/styles.arrow.css +1 -1
- package/molecules/KeyEvents/index.js +23 -2545
- package/molecules/KeyEvents/styles.arrow.css +1 -1
- package/molecules/PageIntroductionCard/index.js +17 -2454
- package/molecules/PageIntroductionCard/styles.arrow.css +1 -1
- package/molecules/SocialShareTemplate/index.js +144 -2740
- package/molecules/SocialShareTemplate/styles.arrow.css +1 -1
- package/molecules/StoryCard/index.js +64 -2582
- package/molecules/StoryCard/styles.arrow.css +1 -1
- package/molecules/StoryElementCard/index.js +123 -2893
- package/molecules/StoryElementCard/styles.arrow.css +1 -1
- package/molecules/StorycardContent/index.js +45 -2495
- package/molecules/StorycardContent/styles.arrow.css +1 -1
- package/package.json +1 -1
- package/rows/AlternateCollectionFilter/index.js +92 -2659
- package/rows/AlternateCollectionFilter/styles.arrow.css +1 -1
- package/rows/AsideCollection/index.js +92 -2659
- package/rows/AsideCollection/styles.arrow.css +1 -1
- package/rows/AstrologyCollection/index.js +89 -2656
- package/rows/AstrologyCollection/styles.arrow.css +1 -1
- package/rows/AuthorIntroductionCard/index.js +27 -2743
- package/rows/AuthorIntroductionCard/styles.arrow.css +1 -1
- package/rows/AuthorsList/index.js +34 -2763
- package/rows/AuthorsList/styles.arrow.css +1 -1
- package/rows/CollectionFilter/index.js +91 -2658
- package/rows/CollectionFilter/styles.arrow.css +1 -1
- package/rows/ElevenStories/index.js +81 -2612
- package/rows/ElevenStories/styles.arrow.css +1 -1
- package/rows/FourColFiveStories/index.js +75 -2603
- package/rows/FourColFiveStories/styles.arrow.css +1 -1
- package/rows/FourColGrid/index.js +92 -2623
- package/rows/FourColGrid/styles.arrow.css +1 -1
- package/rows/FourColPortraitStories/index.js +91 -2622
- package/rows/FourColPortraitStories/styles.arrow.css +1 -1
- package/rows/FourColSixteenStories/index.js +80 -2617
- package/rows/FourColSixteenStories/styles.arrow.css +1 -1
- package/rows/FourColTwelveStories/index.js +72 -2596
- package/rows/FourColTwelveStories/styles.arrow.css +1 -1
- package/rows/FourStorySlider/index.js +84 -2615
- package/rows/FourStorySlider/styles.arrow.css +1 -1
- package/rows/FourStorySliderPortrait/index.js +84 -2615
- package/rows/FourStorySliderPortrait/styles.arrow.css +1 -1
- package/rows/FourTabbedBigStorySlider/index.js +80 -2611
- package/rows/FourTabbedBigStorySlider/styles.arrow.css +1 -1
- package/rows/FullScreenSlider/index.js +85 -2616
- package/rows/FullScreenSlider/styles.arrow.css +1 -1
- package/rows/HalfScreenSlider/index.js +81 -2612
- package/rows/HalfScreenSlider/styles.arrow.css +1 -1
- package/rows/ListComponent/index.js +75 -2606
- package/rows/ListComponent/styles.arrow.css +1 -1
- package/rows/Listicles/index.js +38 -2235
- package/rows/Listicles/styles.arrow.css +1 -1
- package/rows/MagazineEditions/index.js +24 -2487
- package/rows/MagazineEditions/styles.arrow.css +1 -1
- package/rows/MagazineHeaderCard/index.js +26 -2489
- package/rows/MagazineHeaderCard/styles.arrow.css +1 -1
- package/rows/MagazineWidget/index.js +81 -2612
- package/rows/MagazineWidget/styles.arrow.css +1 -1
- package/rows/OneColStoryList/index.js +92 -2623
- package/rows/OneColStoryList/styles.arrow.css +1 -1
- package/rows/OpinionCollection/index.js +61 -2583
- package/rows/OpinionCollection/styles.arrow.css +1 -1
- package/rows/SixColSixStories/index.js +91 -2622
- package/rows/SixColSixStories/styles.arrow.css +1 -1
- package/rows/StoryCollection/index.js +92 -2659
- package/rows/StoryCollection/styles.arrow.css +1 -1
- package/rows/TagIntroductionCard/index.js +9 -1816
- package/rows/TagIntroductionCard/styles.arrow.css +1 -1
- package/rows/ThreeColFlexStories/index.js +91 -2622
- package/rows/ThreeColFlexStories/styles.arrow.css +1 -1
- package/rows/ThreeColFourteenStories/index.js +72 -2596
- package/rows/ThreeColFourteenStories/styles.arrow.css +1 -1
- package/rows/ThreeColGrid/index.js +94 -2625
- package/rows/ThreeColGrid/styles.arrow.css +1 -1
- package/rows/ThreeColSevenStory/index.js +84 -2615
- package/rows/ThreeColSevenStory/styles.arrow.css +1 -1
- package/rows/ThreeColSixStories/index.js +76 -2607
- package/rows/ThreeColSixStories/styles.arrow.css +1 -1
- package/rows/ThreeColTwelveStories/index.js +80 -2617
- package/rows/ThreeColTwelveStories/styles.arrow.css +1 -1
- package/rows/TwoColFourStories/index.js +78 -2609
- package/rows/TwoColFourStories/styles.arrow.css +1 -1
- package/rows/TwoColFourStoryHighlight/index.js +80 -2617
- package/rows/TwoColFourStoryHighlight/styles.arrow.css +1 -1
- package/rows/TwoColSevenStories/index.js +77 -2608
- package/rows/TwoColSevenStories/styles.arrow.css +1 -1
- package/rows/TwoColSixStories/index.js +82 -2619
- package/rows/TwoColSixStories/styles.arrow.css +1 -1
- package/rows/TwoColTenStoriesSidebar/index.js +79 -2610
- package/rows/TwoColTenStoriesSidebar/styles.arrow.css +1 -1
- package/rows/TwoColThreeStories/index.js +75 -2606
- package/rows/TwoColThreeStories/styles.arrow.css +1 -1
- package/story-elements/AlsoRead/index.js +24 -2170
- package/story-elements/AlsoRead/styles.arrow.css +1 -1
- package/story-elements/Attachment/index.js +15 -1870
- package/story-elements/Attachment/styles.arrow.css +1 -1
- package/story-elements/BigFact/index.js +16 -1871
- package/story-elements/BigFact/styles.arrow.css +1 -1
- package/story-elements/BlockQuote/index.js +20 -2157
- package/story-elements/BlockQuote/styles.arrow.css +1 -1
- package/story-elements/Blurb/index.js +18 -1932
- package/story-elements/Blurb/styles.arrow.css +1 -1
- package/story-elements/Image/index.js +42 -2251
- package/story-elements/Image/styles.arrow.css +1 -1
- package/story-elements/ImageGallery/index.js +45 -2254
- package/story-elements/ImageGallery/styles.arrow.css +1 -1
- package/story-elements/ImageSlideshow/index.js +48 -2257
- package/story-elements/ImageSlideshow/styles.arrow.css +1 -1
- package/story-elements/QuestionAnswer/index.js +26 -2163
- package/story-elements/QuestionAnswer/styles.arrow.css +1 -1
- package/story-elements/Quote/index.js +17 -1872
- package/story-elements/Quote/styles.arrow.css +1 -1
- package/story-elements/Reference/index.js +15 -1870
- package/story-elements/Reference/styles.arrow.css +1 -1
- package/story-elements/StoryElement/index.js +12 -1725
- package/story-elements/Summary/index.js +18 -1873
- package/story-elements/Summary/styles.arrow.css +1 -1
- package/story-elements/Text/index.js +16 -2153
- package/story-elements/Text/styles.arrow.css +1 -1
- package/story-elements/Video/index.js +12 -1725
- package/story-elements/Video/styles.arrow.css +1 -1
- package/story-templates/ListicleStoryTemplate/index.js +282 -3167
- package/story-templates/ListicleStoryTemplate/styles.arrow.css +1 -1
- package/story-templates/LiveBlogStoryTemplate/index.js +504 -3389
- package/story-templates/LiveBlogStoryTemplate/styles.arrow.css +1 -1
- package/story-templates/PhotoStoryTemplate/index.js +287 -3172
- package/story-templates/PhotoStoryTemplate/styles.arrow.css +1 -1
- package/story-templates/TextStoryTemplate/index.js +416 -3301
- package/story-templates/TextStoryTemplate/styles.arrow.css +1 -1
- package/story-templates/VideoStoryTemplate/index.js +382 -3267
- package/story-templates/VideoStoryTemplate/styles.arrow.css +1 -1
- package/atoms/ExtendedLoadMore/index-e7cde739.js +0 -3051
|
@@ -1,17 +1,27 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var _defineProperty = require('@babel/runtime/helpers/defineProperty');
|
|
4
|
+
var _getClassName = require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var reactRedux = require('react-redux');
|
|
7
|
+
var lodash = require('lodash');
|
|
7
8
|
var PropTypes = require('prop-types');
|
|
8
9
|
var components = require('@quintype/components');
|
|
10
|
+
var index$1 = require('./index-93cb06d1.js');
|
|
11
|
+
var index = require('./index-142f015c.js');
|
|
9
12
|
require('react-dom');
|
|
13
|
+
require('@babel/runtime/helpers/slicedToArray');
|
|
14
|
+
require('@babel/runtime/helpers/toConsumableArray');
|
|
15
|
+
require('@babel/runtime/helpers/asyncToGenerator');
|
|
16
|
+
require('@babel/runtime/regenerator');
|
|
17
|
+
require('@babel/runtime/helpers/typeof');
|
|
10
18
|
require('react-timeago');
|
|
11
19
|
require('date-fns-tz');
|
|
12
20
|
|
|
13
21
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
14
22
|
|
|
23
|
+
var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_defineProperty);
|
|
24
|
+
var _getClassName__default = /*#__PURE__*/_interopDefaultLegacy(_getClassName);
|
|
15
25
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
16
26
|
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
|
|
17
27
|
|
|
@@ -55,7 +65,7 @@ var authorWithImage = function authorWithImage(author, templateStyle) {
|
|
|
55
65
|
name = author.name;
|
|
56
66
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
57
67
|
"data-test-id": "author-image",
|
|
58
|
-
className: "arr--author-image " +
|
|
68
|
+
className: "arr--author-image " + _getClassName__default["default"]("author-image ".concat(templateStyle), _styleModuleImportMap$1)
|
|
59
69
|
}, /*#__PURE__*/React__default["default"].createElement("figure", {
|
|
60
70
|
className: "author-image-m_image-container__19WNd"
|
|
61
71
|
}, avatarS3Key ? /*#__PURE__*/React__default["default"].createElement(components.ResponsiveImage, {
|
|
@@ -120,7 +130,7 @@ var _styleModuleImportMap = {
|
|
|
120
130
|
|
|
121
131
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
122
132
|
|
|
123
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
133
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
124
134
|
|
|
125
135
|
var loadMore = function loadMore(_ref) {
|
|
126
136
|
var isLoading = _ref.isLoading,
|
|
@@ -157,7 +167,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
|
|
|
157
167
|
_config$subsequentLoa = config.subsequentLoadCount,
|
|
158
168
|
subsequentLoadCount = _config$subsequentLoa === void 0 ? 3 : _config$subsequentLoa;
|
|
159
169
|
|
|
160
|
-
var _get =
|
|
170
|
+
var _get = lodash.get(slotConfig, [0], {}),
|
|
161
171
|
_get$type = _get.type,
|
|
162
172
|
type = _get$type === void 0 ? "story" : _get$type,
|
|
163
173
|
_get$component = _get.component,
|
|
@@ -165,7 +175,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
|
|
|
165
175
|
|
|
166
176
|
var dispatch = reactRedux.useDispatch();
|
|
167
177
|
var qtConfig = reactRedux.useSelector(function (state) {
|
|
168
|
-
return
|
|
178
|
+
return lodash.get(state, ["qt", "config"], {});
|
|
169
179
|
});
|
|
170
180
|
if (!stories.length) return null;
|
|
171
181
|
var textColor = index.getTextColor(theme);
|
|
@@ -201,7 +211,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
|
|
|
201
211
|
};
|
|
202
212
|
|
|
203
213
|
var getAuthorCard = function getAuthorCard(story) {
|
|
204
|
-
var authorData =
|
|
214
|
+
var authorData = lodash.get(story, ["authors", "0"]);
|
|
205
215
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
206
216
|
"data-test-id": "story-card"
|
|
207
217
|
}, /*#__PURE__*/React__default["default"].createElement(index$1.Author, {
|
|
@@ -244,9 +254,9 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
|
|
|
244
254
|
collectionNameBorderColor: collectionNameBorderColor,
|
|
245
255
|
headerLevel: 2
|
|
246
256
|
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
247
|
-
className: ("content-wrapper ".concat(borderStyle, " ").concat(textColor) ? "content-wrapper ".concat(borderStyle, " ").concat(textColor) + " " : "") +
|
|
257
|
+
className: ("content-wrapper ".concat(borderStyle, " ").concat(textColor) ? "content-wrapper ".concat(borderStyle, " ").concat(textColor) + " " : "") + _getClassName__default["default"]("content-wrapper ".concat(borderStyle, " ").concat(textColor, " ").concat(adStyle), _styleModuleImportMap)
|
|
248
258
|
}, slot ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
249
|
-
className: "wrapper-with-ads " +
|
|
259
|
+
className: "wrapper-with-ads " + _getClassName__default["default"]("wrapper-with-ads ".concat(countStyleName), _styleModuleImportMap)
|
|
250
260
|
}, stories.slice(0, 4).map(function (story) {
|
|
251
261
|
return getAuthorCard(story);
|
|
252
262
|
})), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -1,16 +1,24 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var components = require('@quintype/components');
|
|
4
|
-
var
|
|
4
|
+
var lodash = require('lodash');
|
|
5
5
|
var PropTypes = require('prop-types');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var reactRedux = require('react-redux');
|
|
8
|
-
var index$1 = require('./index-
|
|
9
|
-
var index
|
|
10
|
-
var index$
|
|
8
|
+
var index$1 = require('./index-93cb06d1.js');
|
|
9
|
+
var index = require('./index-142f015c.js');
|
|
10
|
+
var index$3 = require('./index-8462c597.js');
|
|
11
|
+
var index$2 = require('./index-0f809dd9.js');
|
|
12
|
+
require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
13
|
+
require('@babel/runtime/helpers/defineProperty');
|
|
14
|
+
require('react-dom');
|
|
15
|
+
require('@babel/runtime/helpers/slicedToArray');
|
|
16
|
+
require('@babel/runtime/helpers/toConsumableArray');
|
|
17
|
+
require('@babel/runtime/helpers/asyncToGenerator');
|
|
18
|
+
require('@babel/runtime/regenerator');
|
|
19
|
+
require('@babel/runtime/helpers/typeof');
|
|
11
20
|
require('react-timeago');
|
|
12
21
|
require('date-fns-tz');
|
|
13
|
-
require('react-dom');
|
|
14
22
|
|
|
15
23
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
16
24
|
|
|
@@ -99,7 +107,7 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
|
|
|
99
107
|
_config$subsequentLoa = config.subsequentLoadCount,
|
|
100
108
|
subsequentLoadCount = _config$subsequentLoa === void 0 ? 3 : _config$subsequentLoa;
|
|
101
109
|
|
|
102
|
-
var _get =
|
|
110
|
+
var _get = lodash.get(slotConfig, [0], {}),
|
|
103
111
|
_get$type = _get.type,
|
|
104
112
|
type = _get$type === void 0 ? "story" : _get$type,
|
|
105
113
|
component = _get.component;
|
|
@@ -110,7 +118,7 @@ var ThreeColFlexStoriesBase = function ThreeColFlexStoriesBase(_ref3) {
|
|
|
110
118
|
var stories = type !== "story" ? collectionItems : components.collectionToStories(collection);
|
|
111
119
|
var dispatch = reactRedux.useDispatch();
|
|
112
120
|
var qtConfig = reactRedux.useSelector(function (state) {
|
|
113
|
-
return
|
|
121
|
+
return lodash.get(state, ["qt", "config"], {});
|
|
114
122
|
});
|
|
115
123
|
|
|
116
124
|
var getLoadMore = function getLoadMore(opts) {
|
|
@@ -2,16 +2,24 @@
|
|
|
2
2
|
|
|
3
3
|
var React = require('react');
|
|
4
4
|
var reactRedux = require('react-redux');
|
|
5
|
-
var
|
|
5
|
+
var lodash = require('lodash');
|
|
6
6
|
var PropTypes = require('prop-types');
|
|
7
7
|
var components = require('@quintype/components');
|
|
8
|
-
var index = require('./index-
|
|
9
|
-
var index$
|
|
10
|
-
var index$
|
|
11
|
-
var index$
|
|
8
|
+
var index = require('./index-93cb06d1.js');
|
|
9
|
+
var index$1 = require('./index-142f015c.js');
|
|
10
|
+
var index$2 = require('./index-0f809dd9.js');
|
|
11
|
+
var index$4 = require('./index-afd44863.js');
|
|
12
|
+
var index$3 = require('./index-8462c597.js');
|
|
13
|
+
require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
14
|
+
require('@babel/runtime/helpers/defineProperty');
|
|
15
|
+
require('react-dom');
|
|
16
|
+
require('@babel/runtime/helpers/slicedToArray');
|
|
17
|
+
require('@babel/runtime/helpers/toConsumableArray');
|
|
18
|
+
require('@babel/runtime/helpers/asyncToGenerator');
|
|
19
|
+
require('@babel/runtime/regenerator');
|
|
20
|
+
require('@babel/runtime/helpers/typeof');
|
|
12
21
|
require('react-timeago');
|
|
13
22
|
require('date-fns-tz');
|
|
14
|
-
require('react-dom');
|
|
15
23
|
|
|
16
24
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
17
25
|
|
|
@@ -110,7 +118,7 @@ var FourColPortraitStoriesBase = function FourColPortraitStoriesBase(_ref2) {
|
|
|
110
118
|
var textColor = index$1.getTextColor(theme);
|
|
111
119
|
var dispatch = reactRedux.useDispatch();
|
|
112
120
|
var qtConfig = reactRedux.useSelector(function (state) {
|
|
113
|
-
return
|
|
121
|
+
return lodash.get(state, ["qt", "config"], {});
|
|
114
122
|
});
|
|
115
123
|
|
|
116
124
|
var getLoadMore = function getLoadMore(opts) {
|
|
@@ -1,14 +1,19 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
|
|
4
|
+
var _getClassName = require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
4
5
|
var components = require('@quintype/components');
|
|
6
|
+
var lodash = require('lodash');
|
|
5
7
|
var PropTypes = require('prop-types');
|
|
6
8
|
var React = require('react');
|
|
7
9
|
var reactRedux = require('react-redux');
|
|
8
|
-
var index = require('./index-
|
|
10
|
+
var index$1 = require('./index-142f015c.js');
|
|
11
|
+
var index = require('./index-93cb06d1.js');
|
|
9
12
|
|
|
10
13
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
11
14
|
|
|
15
|
+
var _slicedToArray__default = /*#__PURE__*/_interopDefaultLegacy(_slicedToArray);
|
|
16
|
+
var _getClassName__default = /*#__PURE__*/_interopDefaultLegacy(_getClassName);
|
|
12
17
|
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
|
|
13
18
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
14
19
|
|
|
@@ -152,7 +157,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
152
157
|
return null;
|
|
153
158
|
} : _config$StoryTemplate;
|
|
154
159
|
var showImagePlaceholder = reactRedux.useSelector(function (state) {
|
|
155
|
-
return
|
|
160
|
+
return lodash.get(state, ["qt", "config", "showPlaceholder"]);
|
|
156
161
|
});
|
|
157
162
|
var getPlaceholderStyleName = showImagePlaceholder ? "placeholder" : "";
|
|
158
163
|
var fullBleed = FullBleed ? "" : "with-padding";
|
|
@@ -161,7 +166,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
161
166
|
var heroImageMobClasses = isHorizontalMobile ? "right-padding-mob" : "";
|
|
162
167
|
|
|
163
168
|
var getPadding = function getPadding(aspectRatio) {
|
|
164
|
-
var _aspectRatio =
|
|
169
|
+
var _aspectRatio = _slicedToArray__default["default"](aspectRatio, 2),
|
|
165
170
|
height = _aspectRatio[0],
|
|
166
171
|
width = _aspectRatio[1];
|
|
167
172
|
|
|
@@ -173,7 +178,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
173
178
|
return 0;
|
|
174
179
|
};
|
|
175
180
|
|
|
176
|
-
var _aspectRatio2 =
|
|
181
|
+
var _aspectRatio2 = _slicedToArray__default["default"](aspectRatio, 2),
|
|
177
182
|
mobileAspectRatio = _aspectRatio2[0],
|
|
178
183
|
_aspectRatio2$ = _aspectRatio2[1],
|
|
179
184
|
desktopAspectRatio = _aspectRatio2$ === void 0 ? mobileAspectRatio : _aspectRatio2$;
|
|
@@ -181,8 +186,8 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
181
186
|
var isMobile = index$1.clientWidth("mobile");
|
|
182
187
|
var imageAspectRatio = isMobile ? mobileAspectRatio : desktopAspectRatio;
|
|
183
188
|
var imagePadding = isMobile ? getPadding(mobileAspectRatio) : getPadding(desktopAspectRatio);
|
|
184
|
-
var slug =
|
|
185
|
-
var hyperLink =
|
|
189
|
+
var slug = lodash.get(story, ["hero-image-s3-key"]) || lodash.get(story, ["alternative", "home", "default", "hero-image", "hero-image-s3-key"]);
|
|
190
|
+
var hyperLink = lodash.get(story, ["hero-image-hyperlink"], "");
|
|
186
191
|
|
|
187
192
|
var fallbackImage = function fallbackImage() {
|
|
188
193
|
if (!slug) {
|
|
@@ -191,7 +196,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
191
196
|
style: {
|
|
192
197
|
paddingTop: imagePadding + "%"
|
|
193
198
|
},
|
|
194
|
-
className: "arr--responsive-hero-image " +
|
|
199
|
+
className: "arr--responsive-hero-image " + _getClassName__default["default"]("image ".concat(getPlaceholderStyleName), _styleModuleImportMap$1)
|
|
195
200
|
}, /*#__PURE__*/React__default["default"].createElement("img", {
|
|
196
201
|
className: "qt-image",
|
|
197
202
|
"data-src": "".concat(fallbackImageUrl),
|
|
@@ -204,7 +209,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
204
209
|
style: {
|
|
205
210
|
paddingTop: imagePadding + "%"
|
|
206
211
|
},
|
|
207
|
-
className: "arr--fallback-hero-image " +
|
|
212
|
+
className: "arr--fallback-hero-image " + _getClassName__default["default"]("image ".concat(getPlaceholderStyleName), _styleModuleImportMap$1)
|
|
208
213
|
}, /*#__PURE__*/React__default["default"].createElement(StoryTemplateIcon, {
|
|
209
214
|
storyTemplate: story["story-template"]
|
|
210
215
|
}), /*#__PURE__*/React__default["default"].createElement(FallbackImage, null)) : null);
|
|
@@ -214,7 +219,7 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
214
219
|
style: {
|
|
215
220
|
paddingTop: imagePadding + "%"
|
|
216
221
|
},
|
|
217
|
-
className: "arr--responsive-hero-image " +
|
|
222
|
+
className: "arr--responsive-hero-image " + _getClassName__default["default"]("image ".concat(getPlaceholderStyleName), _styleModuleImportMap$1)
|
|
218
223
|
}, /*#__PURE__*/React__default["default"].createElement(StoryTemplateIcon, {
|
|
219
224
|
storyTemplate: story["story-template"]
|
|
220
225
|
}), /*#__PURE__*/React__default["default"].createElement(components.ResponsiveHeroImage, {
|
|
@@ -233,13 +238,13 @@ var HeroImage = function HeroImage(_ref) {
|
|
|
233
238
|
|
|
234
239
|
return story && (isStoryPageImage ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
235
240
|
"data-test-id": "arr--hero-image",
|
|
236
|
-
className: "arr--hero-image " +
|
|
241
|
+
className: "arr--hero-image " + _getClassName__default["default"]("".concat(heroImageClass, " ").concat(fullBleed, " ").concat(heroImageMobClasses), _styleModuleImportMap$1)
|
|
237
242
|
}, fallbackImage()) : /*#__PURE__*/React__default["default"].createElement(components.Link, {
|
|
238
243
|
"data-test-id": "arr--hero-image",
|
|
239
244
|
href: index$1.getStoryUrl(story, "/".concat(story.slug)),
|
|
240
245
|
externalLink: index$1.isExternalStory(story),
|
|
241
246
|
"aria-label": "fallback-hero-image",
|
|
242
|
-
className: "arr--hero-image " +
|
|
247
|
+
className: "arr--hero-image " + _getClassName__default["default"]("".concat(heroImageClass, " ").concat(fullBleed, " ").concat(heroImageMobClasses), _styleModuleImportMap$1)
|
|
243
248
|
}, fallbackImage()));
|
|
244
249
|
};
|
|
245
250
|
HeroImage.propTypes = {
|
|
@@ -302,9 +307,9 @@ var SectionTag = function SectionTag(_ref) {
|
|
|
302
307
|
borderColor = _ref$borderColor === void 0 ? "" : _ref$borderColor,
|
|
303
308
|
isLightTheme = _ref.isLightTheme;
|
|
304
309
|
var config = index.useStateValue() || {};
|
|
305
|
-
var isSection =
|
|
306
|
-
var templateFromRowContext =
|
|
307
|
-
var section =
|
|
310
|
+
var isSection = lodash.get(config, ["showSection"], true);
|
|
311
|
+
var templateFromRowContext = lodash.get(config, ["sectionTagTemplate"]);
|
|
312
|
+
var section = lodash.get(story, ["sections", 0], "");
|
|
308
313
|
var supportedTemplates = ["borderBottomSml", "borderLeft", "solid"];
|
|
309
314
|
var getUrl = section ? section["section-url"] : "/";
|
|
310
315
|
var colorToApplyContrast = template === "solid" || templateFromRowContext === "solid" ? borderColor : config.theme;
|
|
@@ -326,7 +331,7 @@ var SectionTag = function SectionTag(_ref) {
|
|
|
326
331
|
style: {
|
|
327
332
|
backgroundColor: templateStyle.includes("section-solid") ? sectionTagBorderColor : ""
|
|
328
333
|
},
|
|
329
|
-
className: "section-tag arrow-component " +
|
|
334
|
+
className: "section-tag arrow-component " + _getClassName__default["default"]("".concat(textColor, " ").concat(templateStyle), _styleModuleImportMap)
|
|
330
335
|
}, templateStyle.includes("section-borderLeft") && /*#__PURE__*/React__default["default"].createElement("span", {
|
|
331
336
|
className: "section-m_border-left__2oUyp",
|
|
332
337
|
style: {
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _getClassName = require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
4
4
|
var React = require('react');
|
|
5
5
|
var PropTypes = require('prop-types');
|
|
6
6
|
var components = require('@quintype/components');
|
|
7
|
+
var lodash = require('lodash');
|
|
8
|
+
var index = require('./index-142f015c.js');
|
|
7
9
|
var reactRedux = require('react-redux');
|
|
10
|
+
var _defineProperty = require('@babel/runtime/helpers/defineProperty');
|
|
8
11
|
var ReactDOM = require('react-dom');
|
|
12
|
+
var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
|
|
9
13
|
|
|
10
14
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
11
15
|
|
|
@@ -27,9 +31,12 @@ function _interopNamespace(e) {
|
|
|
27
31
|
return Object.freeze(n);
|
|
28
32
|
}
|
|
29
33
|
|
|
34
|
+
var _getClassName__default = /*#__PURE__*/_interopDefaultLegacy(_getClassName);
|
|
30
35
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
31
36
|
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
|
|
37
|
+
var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_defineProperty);
|
|
32
38
|
var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM);
|
|
39
|
+
var _slicedToArray__default = /*#__PURE__*/_interopDefaultLegacy(_slicedToArray);
|
|
33
40
|
|
|
34
41
|
var StateContext = /*#__PURE__*/React.createContext(); // eslint-disable-next-line react/display-name
|
|
35
42
|
|
|
@@ -282,8 +289,8 @@ var Headline = function Headline(_ref) {
|
|
|
282
289
|
enablePremiumStoryIcon = _premiumStoryIconConf3 === void 0 ? false : _premiumStoryIconConf3,
|
|
283
290
|
_premiumStoryIconConf4 = premiumStoryIconConfig.showLiveIcon,
|
|
284
291
|
showLiveIcon = _premiumStoryIconConf4 === void 0 ? false : _premiumStoryIconConf4;
|
|
285
|
-
var alternateHeadline =
|
|
286
|
-
var premiumStory = enablePremiumStoryIcon &&
|
|
292
|
+
var alternateHeadline = lodash.get(story, ["alternative", "home", "default", "headline"]);
|
|
293
|
+
var premiumStory = enablePremiumStoryIcon && lodash.get(story, ["access"]) === "subscription";
|
|
287
294
|
var headline = alternateHeadline || story.headline;
|
|
288
295
|
var HeaderTag = "h" + headerLevel;
|
|
289
296
|
|
|
@@ -309,10 +316,10 @@ var Headline = function Headline(_ref) {
|
|
|
309
316
|
var textColor = index.getTextColor(configData.theme);
|
|
310
317
|
var wrapperClass = premiumStory ? "wrapper" : "";
|
|
311
318
|
var iconSize = "24px";
|
|
312
|
-
var enableLiveIcon = showLiveIcon && story["story-template"] === "live-blog" && !
|
|
319
|
+
var enableLiveIcon = showLiveIcon && story["story-template"] === "live-blog" && !lodash.get(story, ["metadata", "is-closed"], false);
|
|
313
320
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
314
321
|
"data-test-id": "headline",
|
|
315
|
-
className: "arrow-component arr--headline " +
|
|
322
|
+
className: "arrow-component arr--headline " + _getClassName__default["default"](wrapperClass, _styleModuleImportMap$8)
|
|
316
323
|
}, premiumStory && /*#__PURE__*/React__default["default"].createElement(PremiumStoryIcon, {
|
|
317
324
|
width: iconSize,
|
|
318
325
|
height: iconSize,
|
|
@@ -324,9 +331,9 @@ var Headline = function Headline(_ref) {
|
|
|
324
331
|
externalLink: index.isExternalStory(story),
|
|
325
332
|
"aria-label": "headline"
|
|
326
333
|
}, /*#__PURE__*/React__default["default"].createElement(HeaderTag, {
|
|
327
|
-
className:
|
|
334
|
+
className: _getClassName__default["default"]("headline ".concat(textColor), _styleModuleImportMap$8)
|
|
328
335
|
}, enableLiveIcon && /*#__PURE__*/React__default["default"].createElement(LiveIcon, null), headline)) : /*#__PURE__*/React__default["default"].createElement(HeaderTag, {
|
|
329
|
-
className:
|
|
336
|
+
className: _getClassName__default["default"]("headline ".concat(textColor), _styleModuleImportMap$8)
|
|
330
337
|
}, enableLiveIcon && /*#__PURE__*/React__default["default"].createElement(LiveIcon, null), headline));
|
|
331
338
|
};
|
|
332
339
|
Headline.propTypes = {
|
|
@@ -362,13 +369,13 @@ var TimeStamp = function TimeStamp(_ref) {
|
|
|
362
369
|
_ref$config = _ref.config,
|
|
363
370
|
config = _ref$config === void 0 ? {} : _ref$config;
|
|
364
371
|
var configState = useStateValue() || {};
|
|
365
|
-
var isTime =
|
|
372
|
+
var isTime = lodash.get(config, ["showTime"], lodash.get(configState, ["showTime"], true));
|
|
366
373
|
var time = story["last-published-at"] || story["first-published-at"];
|
|
367
374
|
var isBottomClasses = isBottom ? "bottom-fix" : "";
|
|
368
375
|
var textColor = index.getTextColor(configState.theme);
|
|
369
376
|
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isTime && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
370
377
|
"data-test-id": "publish-time",
|
|
371
|
-
className: "time arr--publish-time " +
|
|
378
|
+
className: "time arr--publish-time " + _getClassName__default["default"]("time ".concat(textColor, " ").concat(isBottomClasses), _styleModuleImportMap$7)
|
|
372
379
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
373
380
|
className: "timestamp-m_time-wrapper__3O2lM"
|
|
374
381
|
}, index.getTimeStamp(time, index.formatter, config))));
|
|
@@ -403,9 +410,9 @@ var AuthorBase = function AuthorBase(_ref) {
|
|
|
403
410
|
_ref$config = _ref.config,
|
|
404
411
|
config = _ref$config === void 0 ? {} : _ref$config;
|
|
405
412
|
var configData = useStateValue() || {};
|
|
406
|
-
var isAuthor =
|
|
413
|
+
var isAuthor = lodash.get(configData, ["showAuthor"], true);
|
|
407
414
|
|
|
408
|
-
var _get =
|
|
415
|
+
var _get = lodash.get(story, ["authors", "0"], ""),
|
|
409
416
|
avatarUrl = _get["avatar-url"],
|
|
410
417
|
avatarS3Key = _get["avatar-s3-key"],
|
|
411
418
|
authorName = _get.name,
|
|
@@ -413,7 +420,7 @@ var AuthorBase = function AuthorBase(_ref) {
|
|
|
413
420
|
|
|
414
421
|
var isBottomClasses = isBottom ? "bottom-fix" : "";
|
|
415
422
|
var textColor = index.getTextColor(configData.theme);
|
|
416
|
-
var mountAt =
|
|
423
|
+
var mountAt = lodash.get(config, ["mountAt"], "");
|
|
417
424
|
|
|
418
425
|
var authorImage = function authorImage(dir) {
|
|
419
426
|
if (!avatarUrl && !avatarS3Key) {
|
|
@@ -422,7 +429,7 @@ var AuthorBase = function AuthorBase(_ref) {
|
|
|
422
429
|
|
|
423
430
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
424
431
|
"data-test-id": "author-image",
|
|
425
|
-
className:
|
|
432
|
+
className: _getClassName__default["default"]("author-image ".concat(dir, "-image"), _styleModuleImportMap$6)
|
|
426
433
|
}, /*#__PURE__*/React__default["default"].createElement("figure", null, avatarS3Key ? /*#__PURE__*/React__default["default"].createElement(components.ResponsiveImage, {
|
|
427
434
|
slug: avatarS3Key,
|
|
428
435
|
"aspect-ratio": [1, 1],
|
|
@@ -439,7 +446,7 @@ var AuthorBase = function AuthorBase(_ref) {
|
|
|
439
446
|
var isPrefix = function isPrefix(dir) {
|
|
440
447
|
if (prefix) {
|
|
441
448
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
442
|
-
className: "arr-author-prefix " +
|
|
449
|
+
className: "arr-author-prefix " + _getClassName__default["default"]("prefix ".concat(textColor), _styleModuleImportMap$6)
|
|
443
450
|
}, prefix);
|
|
444
451
|
}
|
|
445
452
|
|
|
@@ -449,16 +456,16 @@ var AuthorBase = function AuthorBase(_ref) {
|
|
|
449
456
|
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isAuthor && /*#__PURE__*/React__default["default"].createElement(components.Link, {
|
|
450
457
|
href: "".concat(mountAt, "/author/") + slug,
|
|
451
458
|
"aria-label": "author-name",
|
|
452
|
-
className: "author-name arr-author-name arrow-component " +
|
|
459
|
+
className: "author-name arr-author-name arrow-component " + _getClassName__default["default"]("author ".concat(isBottomClasses), _styleModuleImportMap$6)
|
|
453
460
|
}, isPrefix("ltr"), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
454
461
|
"data-test-id": "author-name",
|
|
455
|
-
className: "author-name " +
|
|
462
|
+
className: "author-name " + _getClassName__default["default"]("author-name ".concat(textColor), _styleModuleImportMap$6)
|
|
456
463
|
}, authorName || story["author-name"]), !prefix && isPrefix("rtl")));
|
|
457
464
|
};
|
|
458
465
|
|
|
459
466
|
function mapStateToProps$1(state) {
|
|
460
467
|
return {
|
|
461
|
-
config:
|
|
468
|
+
config: lodash.get(state, ["qt", "config"], {})
|
|
462
469
|
};
|
|
463
470
|
}
|
|
464
471
|
|
|
@@ -495,7 +502,7 @@ var Dot = function Dot(_ref) {
|
|
|
495
502
|
_ref$color = _ref.color,
|
|
496
503
|
color = _ref$color === void 0 ? "light" : _ref$color;
|
|
497
504
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
498
|
-
className:
|
|
505
|
+
className: _getClassName__default["default"](color, _styleModuleImportMap$5)
|
|
499
506
|
}, /*#__PURE__*/React__default["default"].createElement("svg", {
|
|
500
507
|
xmlns: "http://www.w3.org/2000/svg",
|
|
501
508
|
width: width,
|
|
@@ -531,7 +538,7 @@ var Divider = function Divider(_ref) {
|
|
|
531
538
|
_ref$color = _ref.color,
|
|
532
539
|
color = _ref$color === void 0 ? "light" : _ref$color;
|
|
533
540
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
534
|
-
className:
|
|
541
|
+
className: _getClassName__default["default"](color, _styleModuleImportMap$4)
|
|
535
542
|
}, /*#__PURE__*/React__default["default"].createElement("svg", {
|
|
536
543
|
xmlns: "http://www.w3.org/2000/svg",
|
|
537
544
|
width: width,
|
|
@@ -563,14 +570,14 @@ var ReadTime = function ReadTime(_ref) {
|
|
|
563
570
|
_ref$isLightTheme = _ref.isLightTheme,
|
|
564
571
|
isLightTheme = _ref$isLightTheme === void 0 ? false : _ref$isLightTheme;
|
|
565
572
|
var config = useStateValue() || {};
|
|
566
|
-
var showReadTime =
|
|
567
|
-
var readTime =
|
|
573
|
+
var showReadTime = lodash.get(config, ["showReadTime"]) || lodash.get(opts, ["showReadTime"], true);
|
|
574
|
+
var readTime = lodash.get(story, ["read-time"], 0);
|
|
568
575
|
var textColor = isLightTheme ? "light" : index.getTextColor(config.theme);
|
|
569
576
|
if (!showReadTime || !readTime) return null;
|
|
570
|
-
var timeToRead =
|
|
577
|
+
var timeToRead = lodash.get(opts, ["localizedTimeToRead"]) || "min read";
|
|
571
578
|
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
572
579
|
"data-test-id": "read-time",
|
|
573
|
-
className: "arrow-component arr--read-time " +
|
|
580
|
+
className: "arrow-component arr--read-time " + _getClassName__default["default"]("read-time-wrapper ".concat(textColor), _styleModuleImportMap$3)
|
|
574
581
|
}, /*#__PURE__*/React__default["default"].createElement("span", {
|
|
575
582
|
className: "read-time-indicator read-time-m_dot-indicator__3Sqh2"
|
|
576
583
|
}, /*#__PURE__*/React__default["default"].createElement(Dot, {
|
|
@@ -606,9 +613,9 @@ var AuthorWithTime = function AuthorWithTime(_ref) {
|
|
|
606
613
|
config = _ref$config === void 0 ? {} : _ref$config,
|
|
607
614
|
isLightTheme = _ref.isLightTheme;
|
|
608
615
|
var configState = useStateValue() || {};
|
|
609
|
-
var isAuthor =
|
|
610
|
-
var isTime =
|
|
611
|
-
var isReadTime =
|
|
616
|
+
var isAuthor = lodash.get(config, ["showAuthor"], lodash.get(configState, ["showAuthor"], true));
|
|
617
|
+
var isTime = lodash.get(config, ["showTime"], lodash.get(configState, ["showTime"], true));
|
|
618
|
+
var isReadTime = lodash.get(configState, ["showReadTime"], true);
|
|
612
619
|
var isBottomClasses = isBottom ? "bottom-fix" : "";
|
|
613
620
|
var seperatorStyle = separator === "dot" ? "dot" : "dash";
|
|
614
621
|
var textColor = isLightTheme ? "light" : index.getTextColor(configState.theme);
|
|
@@ -628,7 +635,7 @@ var AuthorWithTime = function AuthorWithTime(_ref) {
|
|
|
628
635
|
var getTimeStamp = function getTimeStamp() {
|
|
629
636
|
if (!isTime) return null;
|
|
630
637
|
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isAuthor && /*#__PURE__*/React__default["default"].createElement("span", {
|
|
631
|
-
className: "arr-separator " +
|
|
638
|
+
className: "arr-separator " + _getClassName__default["default"]("".concat(seperatorStyle), _styleModuleImportMap$2)
|
|
632
639
|
}, getSeparator()), /*#__PURE__*/React__default["default"].createElement(TimeStamp, {
|
|
633
640
|
story: story,
|
|
634
641
|
config: config
|
|
@@ -640,7 +647,7 @@ var AuthorWithTime = function AuthorWithTime(_ref) {
|
|
|
640
647
|
};
|
|
641
648
|
|
|
642
649
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
643
|
-
className: "arr--author-time " +
|
|
650
|
+
className: "arr--author-time " + _getClassName__default["default"]("author-time-wrapper ".concat(isBottomClasses), _styleModuleImportMap$2)
|
|
644
651
|
}, isAuthor ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(Author, {
|
|
645
652
|
story: story,
|
|
646
653
|
isBottom: true,
|
|
@@ -696,7 +703,7 @@ var CollectionNameBase = function CollectionNameBase(_ref) {
|
|
|
696
703
|
_ref$navigate = _ref.navigate,
|
|
697
704
|
navigate = _ref$navigate === void 0 ? true : _ref$navigate;
|
|
698
705
|
var collectionTitle = useStateValue() || {};
|
|
699
|
-
var showRowTitle =
|
|
706
|
+
var showRowTitle = lodash.get(collectionTitle, ["showRowTitle"], true);
|
|
700
707
|
var supportedTemplates = ["borderLeft", "borderBottom", "crossLine", "borderBottomFull"];
|
|
701
708
|
var templateStyle = supportedTemplates.includes(collectionNameTemplate) ? " collection-".concat(collectionNameTemplate) : "";
|
|
702
709
|
var slug = navigate && collection && index.getSlug(collection, config) || "";
|
|
@@ -772,7 +779,7 @@ var CollectionNameBase = function CollectionNameBase(_ref) {
|
|
|
772
779
|
borderBottom: borderBottomFullStyle
|
|
773
780
|
},
|
|
774
781
|
"data-test-id": "collection-name",
|
|
775
|
-
className: ("arr--collection-name arrow-component ".concat(templateStyle) ? "arr--collection-name arrow-component ".concat(templateStyle) + " " : "") +
|
|
782
|
+
className: ("arr--collection-name arrow-component ".concat(templateStyle) ? "arr--collection-name arrow-component ".concat(templateStyle) + " " : "") + _getClassName__default["default"]("collection ".concat(textColor, " ").concat(templateStyle), _styleModuleImportMap$1)
|
|
776
783
|
}, templateStyle.includes("collection-borderLeft") && /*#__PURE__*/React__default["default"].createElement("span", {
|
|
777
784
|
className: "arr-collection-name-border-left collection-name-m_border-left__3_pYw",
|
|
778
785
|
style: {
|
|
@@ -809,27 +816,12 @@ CollectionNameBase.defaultProps = {
|
|
|
809
816
|
|
|
810
817
|
function mapStateToProps(state) {
|
|
811
818
|
return {
|
|
812
|
-
config:
|
|
819
|
+
config: lodash.get(state, ["qt", "config"], {})
|
|
813
820
|
};
|
|
814
821
|
}
|
|
815
822
|
|
|
816
823
|
var CollectionName = reactRedux.connect(mapStateToProps)(CollectionNameBase);
|
|
817
824
|
|
|
818
|
-
function _defineProperty(obj, key, value) {
|
|
819
|
-
if (key in obj) {
|
|
820
|
-
Object.defineProperty(obj, key, {
|
|
821
|
-
value: value,
|
|
822
|
-
enumerable: true,
|
|
823
|
-
configurable: true,
|
|
824
|
-
writable: true
|
|
825
|
-
});
|
|
826
|
-
} else {
|
|
827
|
-
obj[key] = value;
|
|
828
|
-
}
|
|
829
|
-
|
|
830
|
-
return obj;
|
|
831
|
-
}
|
|
832
|
-
|
|
833
825
|
var _styleModuleImportMap = {
|
|
834
826
|
"./load-more.m.css": {
|
|
835
827
|
"button": "load-more-m_button__1mmf1",
|
|
@@ -841,7 +833,7 @@ var _styleModuleImportMap = {
|
|
|
841
833
|
|
|
842
834
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
843
835
|
|
|
844
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
836
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
845
837
|
var LoadmoreButton = function LoadmoreButton(_ref) {
|
|
846
838
|
var _ref$config = _ref.config,
|
|
847
839
|
config = _ref$config === void 0 ? {} : _ref$config,
|
|
@@ -865,14 +857,14 @@ var LoadmoreButton = function LoadmoreButton(_ref) {
|
|
|
865
857
|
return template === "SubsequentLoadCount" ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
866
858
|
onClick: onClick,
|
|
867
859
|
"data-test-id": "load-more",
|
|
868
|
-
className: "arr--button " +
|
|
860
|
+
className: "arr--button " + _getClassName__default["default"]("button ".concat(textColor, " default"), _styleModuleImportMap)
|
|
869
861
|
}, buttonText) : /*#__PURE__*/React__default["default"].createElement(components.LinkBase, {
|
|
870
862
|
href: slug,
|
|
871
863
|
navigateTo: navigate,
|
|
872
864
|
"data-test-id": "load-more",
|
|
873
865
|
"aria-label": "load-more"
|
|
874
866
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
875
|
-
className: "arr--button " +
|
|
867
|
+
className: "arr--button " + _getClassName__default["default"]("button ".concat(textColor, " default"), _styleModuleImportMap)
|
|
876
868
|
}, buttonText));
|
|
877
869
|
};
|
|
878
870
|
LoadmoreButton.propTypes = {
|
|
@@ -927,7 +919,7 @@ var useNearScreen = (function (_ref) {
|
|
|
927
919
|
var ref = _ref.ref;
|
|
928
920
|
|
|
929
921
|
var _useState = React.useState(false),
|
|
930
|
-
_useState2 =
|
|
922
|
+
_useState2 = _slicedToArray__default["default"](_useState, 2),
|
|
931
923
|
show = _useState2[0],
|
|
932
924
|
setShow = _useState2[1];
|
|
933
925
|
|
|
@@ -1021,5 +1013,4 @@ exports.LoadMoreTarget = LoadMoreTarget;
|
|
|
1021
1013
|
exports.LoadmoreButton = LoadmoreButton;
|
|
1022
1014
|
exports.ProgressiveHydration = ProgressiveHydration;
|
|
1023
1015
|
exports.StateProvider = StateProvider;
|
|
1024
|
-
exports._defineProperty = _defineProperty;
|
|
1025
1016
|
exports.useStateValue = useStateValue;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _getClassName = require('babel-plugin-react-css-modules/dist/browser/getClassName');
|
|
4
4
|
var React = require('react');
|
|
5
|
-
var index$2 = require('./index-
|
|
6
|
-
var index$1 = require('./index-
|
|
5
|
+
var index$2 = require('./index-93cb06d1.js');
|
|
6
|
+
var index$1 = require('./index-8462c597.js');
|
|
7
|
+
var index = require('./index-142f015c.js');
|
|
7
8
|
var PropTypes = require('prop-types');
|
|
8
9
|
|
|
9
10
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
10
11
|
|
|
12
|
+
var _getClassName__default = /*#__PURE__*/_interopDefaultLegacy(_getClassName);
|
|
11
13
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
12
14
|
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
|
|
13
15
|
|
|
@@ -38,7 +40,7 @@ var StorycardContent = function StorycardContent(_ref) {
|
|
|
38
40
|
backgroundColor: theme,
|
|
39
41
|
color: textColor
|
|
40
42
|
},
|
|
41
|
-
className: "arr--content-wrapper " +
|
|
43
|
+
className: "arr--content-wrapper " + _getClassName__default["default"]("wrapper ".concat(borderTemplate, " ").concat(horizontalCard), _styleModuleImportMap)
|
|
42
44
|
}, children || /*#__PURE__*/React__default["default"].createElement(DefaultStoryCardContent, {
|
|
43
45
|
story: story,
|
|
44
46
|
headerLevel: headerLevel,
|