@quintype/arrow 3.15.1-perf.1 → 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.
Files changed (167) hide show
  1. package/atoms/Author/index.js +48 -2128
  2. package/atoms/Author/styles.arrow.css +1 -1
  3. package/atoms/AuthorWithTime/index.js +116 -2556
  4. package/atoms/AuthorWithTime/styles.arrow.css +1 -1
  5. package/atoms/CollectionName/index.js +48 -2127
  6. package/atoms/CollectionName/styles.arrow.css +1 -1
  7. package/atoms/ExtendedLoadMore/{index-6f8c780e.js → index-0f809dd9.js} +73 -62
  8. package/atoms/ExtendedLoadMore/index-142f015c.js +476 -0
  9. package/atoms/ExtendedLoadMore/{index-2d713010.js → index-37a9ccff.js} +63 -47
  10. package/atoms/ExtendedLoadMore/{index-8345922c.js → index-446679c8.js} +67 -51
  11. package/atoms/ExtendedLoadMore/{index-6daa674c.js → index-44f97338.js} +86 -68
  12. package/atoms/ExtendedLoadMore/{index-c8f346d0.js → index-57dd4870.js} +80 -64
  13. package/atoms/ExtendedLoadMore/{index-7eb05b3d.js → index-66dd4dbd.js} +70 -54
  14. package/atoms/ExtendedLoadMore/{index-6cb56d1a.js → index-8462c597.js} +93 -80
  15. package/atoms/ExtendedLoadMore/{index-aa8b8ab8.js → index-93cb06d1.js} +252 -226
  16. package/atoms/ExtendedLoadMore/index-afd44863.js +95 -0
  17. package/atoms/ExtendedLoadMore/{index-5a7900ba.js → index-b5754c5d.js} +67 -53
  18. package/atoms/ExtendedLoadMore/{index-4191a84c.js → index-bbaf526e.js} +78 -62
  19. package/atoms/ExtendedLoadMore/{index-99af722e.js → index-cfb262ef.js} +65 -48
  20. package/atoms/ExtendedLoadMore/index.js +20 -5
  21. package/atoms/ExtendedLoadMore/styles.arrow.css +1 -1
  22. package/atoms/Headline/index.js +95 -2175
  23. package/atoms/Headline/styles.arrow.css +1 -1
  24. package/atoms/HeroImage/index.js +91 -2230
  25. package/atoms/HeroImage/styles.arrow.css +1 -1
  26. package/atoms/LoadmoreButton/index.js +40 -2133
  27. package/atoms/LoadmoreButton/styles.arrow.css +1 -1
  28. package/atoms/ScrollSnap/index.js +89 -2241
  29. package/atoms/ScrollSnap/styles.arrow.css +1 -1
  30. package/atoms/SectionTag/index.js +40 -2120
  31. package/atoms/SectionTag/styles.arrow.css +1 -1
  32. package/atoms/Subheadline/index.js +35 -2115
  33. package/atoms/Subheadline/styles.arrow.css +1 -1
  34. package/atoms/TimeStamp/index.js +43 -2483
  35. package/atoms/TimeStamp/styles.arrow.css +1 -1
  36. package/molecules/KeyEvents/index.js +95 -2606
  37. package/molecules/KeyEvents/styles.arrow.css +1 -1
  38. package/molecules/PageIntroductionCard/index.js +59 -2487
  39. package/molecules/PageIntroductionCard/styles.arrow.css +1 -1
  40. package/molecules/SocialShareTemplate/index.js +213 -2800
  41. package/molecules/SocialShareTemplate/styles.arrow.css +1 -1
  42. package/molecules/StoryCard/index.js +308 -2816
  43. package/molecules/StoryCard/styles.arrow.css +1 -1
  44. package/molecules/StoryElementCard/index.js +611 -3352
  45. package/molecules/StoryElementCard/styles.arrow.css +1 -1
  46. package/molecules/StorycardContent/index.js +218 -2658
  47. package/molecules/StorycardContent/styles.arrow.css +1 -1
  48. package/package.json +1 -1
  49. package/rows/AlternateCollectionFilter/index.js +438 -2993
  50. package/rows/AlternateCollectionFilter/styles.arrow.css +1 -1
  51. package/rows/AsideCollection/index.js +432 -2987
  52. package/rows/AsideCollection/styles.arrow.css +1 -1
  53. package/rows/AstrologyCollection/index.js +411 -2966
  54. package/rows/AstrologyCollection/styles.arrow.css +1 -1
  55. package/rows/AuthorIntroductionCard/index.js +183 -2890
  56. package/rows/AuthorIntroductionCard/styles.arrow.css +1 -1
  57. package/rows/AuthorsList/index.js +217 -2936
  58. package/rows/AuthorsList/styles.arrow.css +1 -1
  59. package/rows/CollectionFilter/index.js +453 -3008
  60. package/rows/CollectionFilter/styles.arrow.css +1 -1
  61. package/rows/ElevenStories/index.js +439 -2959
  62. package/rows/ElevenStories/styles.arrow.css +1 -1
  63. package/rows/FourColFiveStories/index.js +374 -2872
  64. package/rows/FourColFiveStories/styles.arrow.css +1 -1
  65. package/rows/FourColGrid/index.js +426 -2927
  66. package/rows/FourColGrid/styles.arrow.css +1 -1
  67. package/rows/FourColPortraitStories/index.js +430 -2931
  68. package/rows/FourColPortraitStories/styles.arrow.css +1 -1
  69. package/rows/FourColSixteenStories/index.js +368 -2894
  70. package/rows/FourColSixteenStories/styles.arrow.css +1 -1
  71. package/rows/FourColTwelveStories/index.js +387 -2900
  72. package/rows/FourColTwelveStories/styles.arrow.css +1 -1
  73. package/rows/FourStorySlider/index.js +443 -2963
  74. package/rows/FourStorySlider/styles.arrow.css +1 -1
  75. package/rows/FourStorySliderPortrait/index.js +444 -2964
  76. package/rows/FourStorySliderPortrait/styles.arrow.css +1 -1
  77. package/rows/FourTabbedBigStorySlider/index.js +403 -2923
  78. package/rows/FourTabbedBigStorySlider/styles.arrow.css +1 -1
  79. package/rows/FullScreenSlider/index.js +422 -2942
  80. package/rows/FullScreenSlider/styles.arrow.css +1 -1
  81. package/rows/HalfScreenSlider/index.js +390 -2910
  82. package/rows/HalfScreenSlider/styles.arrow.css +1 -1
  83. package/rows/ListComponent/index.js +398 -2918
  84. package/rows/ListComponent/styles.arrow.css +1 -1
  85. package/rows/Listicles/index.js +189 -2375
  86. package/rows/Listicles/styles.arrow.css +1 -1
  87. package/rows/MagazineEditions/index.js +128 -2580
  88. package/rows/MagazineEditions/styles.arrow.css +1 -1
  89. package/rows/MagazineHeaderCard/index.js +125 -2577
  90. package/rows/MagazineHeaderCard/styles.arrow.css +1 -1
  91. package/rows/MagazineWidget/index.js +408 -2928
  92. package/rows/MagazineWidget/styles.arrow.css +1 -1
  93. package/rows/OneColStoryList/index.js +439 -2940
  94. package/rows/OneColStoryList/styles.arrow.css +1 -1
  95. package/rows/OpinionCollection/index.js +308 -2800
  96. package/rows/OpinionCollection/styles.arrow.css +1 -1
  97. package/rows/SixColSixStories/index.js +405 -2906
  98. package/rows/SixColSixStories/styles.arrow.css +1 -1
  99. package/rows/StoryCollection/index.js +432 -2987
  100. package/rows/StoryCollection/styles.arrow.css +1 -1
  101. package/rows/TagIntroductionCard/index.js +35 -1833
  102. package/rows/TagIntroductionCard/styles.arrow.css +1 -1
  103. package/rows/ThreeColFlexStories/index.js +421 -2922
  104. package/rows/ThreeColFlexStories/styles.arrow.css +1 -1
  105. package/rows/ThreeColFourteenStories/index.js +358 -2871
  106. package/rows/ThreeColFourteenStories/styles.arrow.css +1 -1
  107. package/rows/ThreeColGrid/index.js +428 -2929
  108. package/rows/ThreeColGrid/styles.arrow.css +1 -1
  109. package/rows/ThreeColSevenStory/index.js +406 -2926
  110. package/rows/ThreeColSevenStory/styles.arrow.css +1 -1
  111. package/rows/ThreeColSixStories/index.js +400 -2920
  112. package/rows/ThreeColSixStories/styles.arrow.css +1 -1
  113. package/rows/ThreeColTwelveStories/index.js +383 -2909
  114. package/rows/ThreeColTwelveStories/styles.arrow.css +1 -1
  115. package/rows/TwoColFourStories/index.js +395 -2915
  116. package/rows/TwoColFourStories/styles.arrow.css +1 -1
  117. package/rows/TwoColFourStoryHighlight/index.js +398 -2924
  118. package/rows/TwoColFourStoryHighlight/styles.arrow.css +1 -1
  119. package/rows/TwoColSevenStories/index.js +400 -2920
  120. package/rows/TwoColSevenStories/styles.arrow.css +1 -1
  121. package/rows/TwoColSixStories/index.js +398 -2924
  122. package/rows/TwoColSixStories/styles.arrow.css +1 -1
  123. package/rows/TwoColTenStoriesSidebar/index.js +418 -2938
  124. package/rows/TwoColTenStoriesSidebar/styles.arrow.css +1 -1
  125. package/rows/TwoColThreeStories/index.js +392 -2912
  126. package/rows/TwoColThreeStories/styles.arrow.css +1 -1
  127. package/story-elements/AlsoRead/index.js +92 -2229
  128. package/story-elements/AlsoRead/styles.arrow.css +1 -1
  129. package/story-elements/Attachment/index.js +53 -1899
  130. package/story-elements/Attachment/styles.arrow.css +1 -1
  131. package/story-elements/BigFact/index.js +49 -1895
  132. package/story-elements/BigFact/styles.arrow.css +1 -1
  133. package/story-elements/BlockQuote/index.js +79 -2206
  134. package/story-elements/BlockQuote/styles.arrow.css +1 -1
  135. package/story-elements/Blurb/index.js +52 -1957
  136. package/story-elements/Blurb/styles.arrow.css +1 -1
  137. package/story-elements/Image/index.js +147 -2329
  138. package/story-elements/Image/styles.arrow.css +1 -1
  139. package/story-elements/ImageGallery/index.js +135 -2317
  140. package/story-elements/ImageGallery/styles.arrow.css +1 -1
  141. package/story-elements/ImageSlideshow/index.js +173 -2355
  142. package/story-elements/ImageSlideshow/styles.arrow.css +1 -1
  143. package/story-elements/QuestionAnswer/index.js +79 -2207
  144. package/story-elements/QuestionAnswer/styles.arrow.css +1 -1
  145. package/story-elements/Quote/index.js +52 -1898
  146. package/story-elements/Quote/styles.arrow.css +1 -1
  147. package/story-elements/Reference/index.js +53 -1899
  148. package/story-elements/Reference/styles.arrow.css +1 -1
  149. package/story-elements/StoryElement/index.js +34 -1738
  150. package/story-elements/Summary/index.js +56 -1902
  151. package/story-elements/Summary/styles.arrow.css +1 -1
  152. package/story-elements/Text/index.js +48 -2176
  153. package/story-elements/Text/styles.arrow.css +1 -1
  154. package/story-elements/Video/index.js +35 -1739
  155. package/story-elements/Video/styles.arrow.css +1 -1
  156. package/story-templates/ListicleStoryTemplate/index.js +1182 -4038
  157. package/story-templates/ListicleStoryTemplate/styles.arrow.css +1 -1
  158. package/story-templates/LiveBlogStoryTemplate/index.js +1377 -4233
  159. package/story-templates/LiveBlogStoryTemplate/styles.arrow.css +1 -1
  160. package/story-templates/PhotoStoryTemplate/index.js +1162 -4018
  161. package/story-templates/PhotoStoryTemplate/styles.arrow.css +1 -1
  162. package/story-templates/TextStoryTemplate/index.js +1277 -4133
  163. package/story-templates/TextStoryTemplate/styles.arrow.css +1 -1
  164. package/story-templates/VideoStoryTemplate/index.js +1231 -4087
  165. package/story-templates/VideoStoryTemplate/styles.arrow.css +1 -1
  166. package/atoms/ExtendedLoadMore/index-e39b3ca8.js +0 -3023
  167. package/atoms/ExtendedLoadMore/index-f6e578e3.js +0 -86
@@ -1,2498 +1,66 @@
1
- import React, { useContext, createContext, useState, useEffect, useRef } from 'react';
2
- import { connect, useDispatch, useSelector } from 'react-redux';
3
- import PropTypes, { PropTypes as PropTypes$1 } from 'prop-types';
4
- import { Link, ResponsiveImage, LinkBase, collectionToStories } from '@quintype/components';
5
- import Timeago from 'react-timeago';
6
- import { utcToZonedTime, format } from 'date-fns-tz';
7
- import ReactDOM from 'react-dom';
8
-
9
- function _defineProperty(obj, key, value) {
10
- if (key in obj) {
11
- Object.defineProperty(obj, key, {
12
- value: value,
13
- enumerable: true,
14
- configurable: true,
15
- writable: true
16
- });
17
- } else {
18
- obj[key] = value;
19
- }
20
-
21
- return obj;
22
- }
23
-
24
- var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
25
-
26
- function getDefaultExportFromCjs (x) {
27
- return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
28
- }
29
-
30
- function createCommonjsModule(fn) {
31
- var module = { exports: {} };
32
- return fn(module, module.exports), module.exports;
33
- }
34
-
35
- var optionsDefaults_1 = createCommonjsModule(function (module, exports) {
36
-
37
- Object.defineProperty(exports, "__esModule", {
38
- value: true
39
- });
40
- exports["default"] = void 0;
41
- var optionsDefaults = {
42
- attributeNames: {
43
- styleName: 'className'
44
- },
45
- generateScopedName: '[path]___[name]__[local]___[hash:base64:5]',
46
- handleMissingStyleName: 'throw'
47
- };
48
- var _default = optionsDefaults;
49
- exports["default"] = _default;
50
-
51
-
52
- });
53
-
54
- var getClassName = createCommonjsModule(function (module, exports) {
55
-
56
- Object.defineProperty(exports, "__esModule", {
57
- value: true
58
- });
59
- exports["default"] = void 0;
60
-
61
- var _optionsDefaults = _interopRequireDefault(optionsDefaults_1);
62
-
63
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
64
-
65
- var isNamespacedStyleName = function isNamespacedStyleName(styleName) {
66
- return styleName.indexOf('.') !== -1;
67
- };
68
-
69
- var handleError = function handleError(message, handleMissingStyleName) {
70
- if (handleMissingStyleName === 'throw') {
71
- throw new Error(message);
72
- } else if (handleMissingStyleName === 'warn') {
73
- // eslint-disable-next-line no-console
74
- console.warn(message);
75
- }
76
-
77
- return null;
78
- };
79
-
80
- var getClassNameForNamespacedStyleName = function getClassNameForNamespacedStyleName(styleName, styleModuleImportMap, handleMissingStyleNameOption) {
81
- // Note:
82
- // Do not use the desctructing syntax with Babel.
83
- // Desctructing adds _slicedToArray helper.
84
- var styleNameParts = styleName.split('.');
85
- var importName = styleNameParts[0];
86
- var moduleName = styleNameParts[1];
87
- var handleMissingStyleName = handleMissingStyleNameOption || _optionsDefaults["default"].handleMissingStyleName;
88
-
89
- if (!moduleName) {
90
- return handleError('Invalid style name: ' + styleName, handleMissingStyleName);
91
- }
92
-
93
- if (!styleModuleImportMap[importName]) {
94
- return handleError('CSS module import does not exist: ' + importName, handleMissingStyleName);
95
- }
96
-
97
- if (!styleModuleImportMap[importName][moduleName]) {
98
- return handleError('CSS module does not exist: ' + moduleName, handleMissingStyleName);
99
- }
100
-
101
- return styleModuleImportMap[importName][moduleName];
102
- };
103
-
104
- var getClassNameFromMultipleImports = function getClassNameFromMultipleImports(styleName, styleModuleImportMap, handleMissingStyleNameOption) {
105
- var handleMissingStyleName = handleMissingStyleNameOption || _optionsDefaults["default"].handleMissingStyleName;
106
- var importKeysWithMatches = Object.keys(styleModuleImportMap).map(function (importKey) {
107
- return styleModuleImportMap[importKey][styleName] && importKey;
108
- }).filter(function (importKey) {
109
- return importKey;
110
- });
111
-
112
- if (importKeysWithMatches.length > 1) {
113
- throw new Error('Cannot resolve styleName "' + styleName + '" because it is present in multiple imports:' + '\n\n\t' + importKeysWithMatches.join('\n\t') + '\n\nYou can resolve this by using a named import, e.g:' + '\n\n\timport foo from "' + importKeysWithMatches[0] + '";' + '\n\t<div styleName="foo.' + styleName + '" />' + '\n\n');
114
- }
115
-
116
- if (importKeysWithMatches.length === 0) {
117
- return handleError('Could not resolve the styleName \'' + styleName + '\'.', handleMissingStyleName);
118
- }
119
-
120
- return styleModuleImportMap[importKeysWithMatches[0]][styleName];
121
- };
122
-
123
- var _default = function _default(styleNameValue, styleModuleImportMap, options) {
124
- var styleModuleImportMapKeys = Object.keys(styleModuleImportMap);
125
-
126
- var _ref = options || {},
127
- _ref$handleMissingSty = _ref.handleMissingStyleName,
128
- handleMissingStyleName = _ref$handleMissingSty === void 0 ? _optionsDefaults["default"].handleMissingStyleName : _ref$handleMissingSty,
129
- _ref$autoResolveMulti = _ref.autoResolveMultipleImports,
130
- autoResolveMultipleImports = _ref$autoResolveMulti === void 0 ? _optionsDefaults["default"].autoResolveMultipleImports : _ref$autoResolveMulti;
131
-
132
- if (!styleNameValue) {
133
- return '';
134
- }
135
-
136
- return styleNameValue.split(' ').filter(function (styleName) {
137
- return styleName;
138
- }).map(function (styleName) {
139
- if (isNamespacedStyleName(styleName)) {
140
- return getClassNameForNamespacedStyleName(styleName, styleModuleImportMap, handleMissingStyleName);
141
- }
142
-
143
- if (styleModuleImportMapKeys.length === 0) {
144
- throw new Error('Cannot use styleName attribute for style name \'' + styleName + '\' without importing at least one stylesheet.');
145
- }
146
-
147
- if (styleModuleImportMapKeys.length > 1) {
148
- if (!autoResolveMultipleImports) {
149
- throw new Error('Cannot use anonymous style name \'' + styleName + '\' with more than one stylesheet import without setting \'autoResolveMultipleImports\' to true.');
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var _defineProperty = require('@babel/runtime/helpers/defineProperty');
6
+ var _getClassName = require('babel-plugin-react-css-modules/dist/browser/getClassName');
7
+ var React = require('react');
8
+ var reactRedux = require('react-redux');
9
+ var lodash = require('lodash');
10
+ var PropTypes = require('prop-types');
11
+ var components = require('@quintype/components');
12
+ require('@babel/runtime/helpers/asyncToGenerator');
13
+ require('@babel/runtime/helpers/typeof');
14
+ require('@babel/runtime/regenerator');
15
+ var Timeago = require('react-timeago');
16
+ var dateFnsTz = require('date-fns-tz');
17
+ var ReactDOM = require('react-dom');
18
+ var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
19
+
20
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
21
+
22
+ function _interopNamespace(e) {
23
+ if (e && e.__esModule) return e;
24
+ var n = Object.create(null);
25
+ if (e) {
26
+ Object.keys(e).forEach(function (k) {
27
+ if (k !== 'default') {
28
+ var d = Object.getOwnPropertyDescriptor(e, k);
29
+ Object.defineProperty(n, k, d.get ? d : {
30
+ enumerable: true,
31
+ get: function () { return e[k]; }
32
+ });
150
33
  }
151
-
152
- return getClassNameFromMultipleImports(styleName, styleModuleImportMap, handleMissingStyleName);
153
- }
154
-
155
- var styleModuleMap = styleModuleImportMap[styleModuleImportMapKeys[0]];
156
-
157
- if (!styleModuleMap[styleName]) {
158
- return handleError('Could not resolve the styleName \'' + styleName + '\'.', handleMissingStyleName);
159
- }
160
-
161
- return styleModuleMap[styleName];
162
- }).filter(function (className) {
163
- // Remove any styles which could not be found (if handleMissingStyleName === 'ignore')
164
- return className;
165
- }).join(' ');
166
- };
167
-
168
- exports["default"] = _default;
169
-
170
-
171
- });
172
-
173
- var _getClassName = /*@__PURE__*/getDefaultExportFromCjs(getClassName);
174
-
175
- /**
176
- * Checks if `value` is classified as an `Array` object.
177
- *
178
- * @static
179
- * @memberOf _
180
- * @since 0.1.0
181
- * @category Lang
182
- * @param {*} value The value to check.
183
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
184
- * @example
185
- *
186
- * _.isArray([1, 2, 3]);
187
- * // => true
188
- *
189
- * _.isArray(document.body.children);
190
- * // => false
191
- *
192
- * _.isArray('abc');
193
- * // => false
194
- *
195
- * _.isArray(_.noop);
196
- * // => false
197
- */
198
- var isArray = Array.isArray;
199
-
200
- var isArray_1 = isArray;
201
-
202
- /** Detect free variable `global` from Node.js. */
203
-
204
- var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
205
-
206
- var _freeGlobal = freeGlobal;
207
-
208
- /** Detect free variable `self`. */
209
- var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
210
-
211
- /** Used as a reference to the global object. */
212
- var root = _freeGlobal || freeSelf || Function('return this')();
213
-
214
- var _root = root;
215
-
216
- /** Built-in value references. */
217
- var Symbol$1 = _root.Symbol;
218
-
219
- var _Symbol = Symbol$1;
220
-
221
- /** Used for built-in method references. */
222
- var objectProto$4 = Object.prototype;
223
-
224
- /** Used to check objects for own properties. */
225
- var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
226
-
227
- /**
228
- * Used to resolve the
229
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
230
- * of values.
231
- */
232
- var nativeObjectToString$1 = objectProto$4.toString;
233
-
234
- /** Built-in value references. */
235
- var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined;
236
-
237
- /**
238
- * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
239
- *
240
- * @private
241
- * @param {*} value The value to query.
242
- * @returns {string} Returns the raw `toStringTag`.
243
- */
244
- function getRawTag(value) {
245
- var isOwn = hasOwnProperty$3.call(value, symToStringTag$1),
246
- tag = value[symToStringTag$1];
247
-
248
- try {
249
- value[symToStringTag$1] = undefined;
250
- var unmasked = true;
251
- } catch (e) {}
252
-
253
- var result = nativeObjectToString$1.call(value);
254
- if (unmasked) {
255
- if (isOwn) {
256
- value[symToStringTag$1] = tag;
257
- } else {
258
- delete value[symToStringTag$1];
259
- }
260
- }
261
- return result;
262
- }
263
-
264
- var _getRawTag = getRawTag;
265
-
266
- /** Used for built-in method references. */
267
- var objectProto$3 = Object.prototype;
268
-
269
- /**
270
- * Used to resolve the
271
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
272
- * of values.
273
- */
274
- var nativeObjectToString = objectProto$3.toString;
275
-
276
- /**
277
- * Converts `value` to a string using `Object.prototype.toString`.
278
- *
279
- * @private
280
- * @param {*} value The value to convert.
281
- * @returns {string} Returns the converted string.
282
- */
283
- function objectToString(value) {
284
- return nativeObjectToString.call(value);
285
- }
286
-
287
- var _objectToString = objectToString;
288
-
289
- /** `Object#toString` result references. */
290
- var nullTag = '[object Null]',
291
- undefinedTag = '[object Undefined]';
292
-
293
- /** Built-in value references. */
294
- var symToStringTag = _Symbol ? _Symbol.toStringTag : undefined;
295
-
296
- /**
297
- * The base implementation of `getTag` without fallbacks for buggy environments.
298
- *
299
- * @private
300
- * @param {*} value The value to query.
301
- * @returns {string} Returns the `toStringTag`.
302
- */
303
- function baseGetTag(value) {
304
- if (value == null) {
305
- return value === undefined ? undefinedTag : nullTag;
306
- }
307
- return (symToStringTag && symToStringTag in Object(value))
308
- ? _getRawTag(value)
309
- : _objectToString(value);
310
- }
311
-
312
- var _baseGetTag = baseGetTag;
313
-
314
- /**
315
- * Checks if `value` is object-like. A value is object-like if it's not `null`
316
- * and has a `typeof` result of "object".
317
- *
318
- * @static
319
- * @memberOf _
320
- * @since 4.0.0
321
- * @category Lang
322
- * @param {*} value The value to check.
323
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
324
- * @example
325
- *
326
- * _.isObjectLike({});
327
- * // => true
328
- *
329
- * _.isObjectLike([1, 2, 3]);
330
- * // => true
331
- *
332
- * _.isObjectLike(_.noop);
333
- * // => false
334
- *
335
- * _.isObjectLike(null);
336
- * // => false
337
- */
338
- function isObjectLike(value) {
339
- return value != null && typeof value == 'object';
340
- }
341
-
342
- var isObjectLike_1 = isObjectLike;
343
-
344
- /** `Object#toString` result references. */
345
- var symbolTag = '[object Symbol]';
346
-
347
- /**
348
- * Checks if `value` is classified as a `Symbol` primitive or object.
349
- *
350
- * @static
351
- * @memberOf _
352
- * @since 4.0.0
353
- * @category Lang
354
- * @param {*} value The value to check.
355
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
356
- * @example
357
- *
358
- * _.isSymbol(Symbol.iterator);
359
- * // => true
360
- *
361
- * _.isSymbol('abc');
362
- * // => false
363
- */
364
- function isSymbol(value) {
365
- return typeof value == 'symbol' ||
366
- (isObjectLike_1(value) && _baseGetTag(value) == symbolTag);
367
- }
368
-
369
- var isSymbol_1 = isSymbol;
370
-
371
- /** Used to match property names within property paths. */
372
- var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
373
- reIsPlainProp = /^\w*$/;
374
-
375
- /**
376
- * Checks if `value` is a property name and not a property path.
377
- *
378
- * @private
379
- * @param {*} value The value to check.
380
- * @param {Object} [object] The object to query keys on.
381
- * @returns {boolean} Returns `true` if `value` is a property name, else `false`.
382
- */
383
- function isKey(value, object) {
384
- if (isArray_1(value)) {
385
- return false;
386
- }
387
- var type = typeof value;
388
- if (type == 'number' || type == 'symbol' || type == 'boolean' ||
389
- value == null || isSymbol_1(value)) {
390
- return true;
391
- }
392
- return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||
393
- (object != null && value in Object(object));
394
- }
395
-
396
- var _isKey = isKey;
397
-
398
- /**
399
- * Checks if `value` is the
400
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
401
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
402
- *
403
- * @static
404
- * @memberOf _
405
- * @since 0.1.0
406
- * @category Lang
407
- * @param {*} value The value to check.
408
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
409
- * @example
410
- *
411
- * _.isObject({});
412
- * // => true
413
- *
414
- * _.isObject([1, 2, 3]);
415
- * // => true
416
- *
417
- * _.isObject(_.noop);
418
- * // => true
419
- *
420
- * _.isObject(null);
421
- * // => false
422
- */
423
- function isObject(value) {
424
- var type = typeof value;
425
- return value != null && (type == 'object' || type == 'function');
426
- }
427
-
428
- var isObject_1 = isObject;
429
-
430
- /** `Object#toString` result references. */
431
- var asyncTag = '[object AsyncFunction]',
432
- funcTag = '[object Function]',
433
- genTag = '[object GeneratorFunction]',
434
- proxyTag = '[object Proxy]';
435
-
436
- /**
437
- * Checks if `value` is classified as a `Function` object.
438
- *
439
- * @static
440
- * @memberOf _
441
- * @since 0.1.0
442
- * @category Lang
443
- * @param {*} value The value to check.
444
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
445
- * @example
446
- *
447
- * _.isFunction(_);
448
- * // => true
449
- *
450
- * _.isFunction(/abc/);
451
- * // => false
452
- */
453
- function isFunction(value) {
454
- if (!isObject_1(value)) {
455
- return false;
456
- }
457
- // The use of `Object#toString` avoids issues with the `typeof` operator
458
- // in Safari 9 which returns 'object' for typed arrays and other constructors.
459
- var tag = _baseGetTag(value);
460
- return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
461
- }
462
-
463
- var isFunction_1 = isFunction;
464
-
465
- /** Used to detect overreaching core-js shims. */
466
- var coreJsData = _root['__core-js_shared__'];
467
-
468
- var _coreJsData = coreJsData;
469
-
470
- /** Used to detect methods masquerading as native. */
471
- var maskSrcKey = (function() {
472
- var uid = /[^.]+$/.exec(_coreJsData && _coreJsData.keys && _coreJsData.keys.IE_PROTO || '');
473
- return uid ? ('Symbol(src)_1.' + uid) : '';
474
- }());
475
-
476
- /**
477
- * Checks if `func` has its source masked.
478
- *
479
- * @private
480
- * @param {Function} func The function to check.
481
- * @returns {boolean} Returns `true` if `func` is masked, else `false`.
482
- */
483
- function isMasked(func) {
484
- return !!maskSrcKey && (maskSrcKey in func);
485
- }
486
-
487
- var _isMasked = isMasked;
488
-
489
- /** Used for built-in method references. */
490
- var funcProto$1 = Function.prototype;
491
-
492
- /** Used to resolve the decompiled source of functions. */
493
- var funcToString$1 = funcProto$1.toString;
494
-
495
- /**
496
- * Converts `func` to its source code.
497
- *
498
- * @private
499
- * @param {Function} func The function to convert.
500
- * @returns {string} Returns the source code.
501
- */
502
- function toSource(func) {
503
- if (func != null) {
504
- try {
505
- return funcToString$1.call(func);
506
- } catch (e) {}
507
- try {
508
- return (func + '');
509
- } catch (e) {}
510
- }
511
- return '';
512
- }
513
-
514
- var _toSource = toSource;
515
-
516
- /**
517
- * Used to match `RegExp`
518
- * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
519
- */
520
- var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
521
-
522
- /** Used to detect host constructors (Safari). */
523
- var reIsHostCtor = /^\[object .+?Constructor\]$/;
524
-
525
- /** Used for built-in method references. */
526
- var funcProto = Function.prototype,
527
- objectProto$2 = Object.prototype;
528
-
529
- /** Used to resolve the decompiled source of functions. */
530
- var funcToString = funcProto.toString;
531
-
532
- /** Used to check objects for own properties. */
533
- var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
534
-
535
- /** Used to detect if a method is native. */
536
- var reIsNative = RegExp('^' +
537
- funcToString.call(hasOwnProperty$2).replace(reRegExpChar, '\\$&')
538
- .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
539
- );
540
-
541
- /**
542
- * The base implementation of `_.isNative` without bad shim checks.
543
- *
544
- * @private
545
- * @param {*} value The value to check.
546
- * @returns {boolean} Returns `true` if `value` is a native function,
547
- * else `false`.
548
- */
549
- function baseIsNative(value) {
550
- if (!isObject_1(value) || _isMasked(value)) {
551
- return false;
552
- }
553
- var pattern = isFunction_1(value) ? reIsNative : reIsHostCtor;
554
- return pattern.test(_toSource(value));
555
- }
556
-
557
- var _baseIsNative = baseIsNative;
558
-
559
- /**
560
- * Gets the value at `key` of `object`.
561
- *
562
- * @private
563
- * @param {Object} [object] The object to query.
564
- * @param {string} key The key of the property to get.
565
- * @returns {*} Returns the property value.
566
- */
567
- function getValue(object, key) {
568
- return object == null ? undefined : object[key];
569
- }
570
-
571
- var _getValue = getValue;
572
-
573
- /**
574
- * Gets the native function at `key` of `object`.
575
- *
576
- * @private
577
- * @param {Object} object The object to query.
578
- * @param {string} key The key of the method to get.
579
- * @returns {*} Returns the function if it's native, else `undefined`.
580
- */
581
- function getNative(object, key) {
582
- var value = _getValue(object, key);
583
- return _baseIsNative(value) ? value : undefined;
584
- }
585
-
586
- var _getNative = getNative;
587
-
588
- /* Built-in method references that are verified to be native. */
589
- var nativeCreate = _getNative(Object, 'create');
590
-
591
- var _nativeCreate = nativeCreate;
592
-
593
- /**
594
- * Removes all key-value entries from the hash.
595
- *
596
- * @private
597
- * @name clear
598
- * @memberOf Hash
599
- */
600
- function hashClear() {
601
- this.__data__ = _nativeCreate ? _nativeCreate(null) : {};
602
- this.size = 0;
603
- }
604
-
605
- var _hashClear = hashClear;
606
-
607
- /**
608
- * Removes `key` and its value from the hash.
609
- *
610
- * @private
611
- * @name delete
612
- * @memberOf Hash
613
- * @param {Object} hash The hash to modify.
614
- * @param {string} key The key of the value to remove.
615
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
616
- */
617
- function hashDelete(key) {
618
- var result = this.has(key) && delete this.__data__[key];
619
- this.size -= result ? 1 : 0;
620
- return result;
621
- }
622
-
623
- var _hashDelete = hashDelete;
624
-
625
- /** Used to stand-in for `undefined` hash values. */
626
- var HASH_UNDEFINED$1 = '__lodash_hash_undefined__';
627
-
628
- /** Used for built-in method references. */
629
- var objectProto$1 = Object.prototype;
630
-
631
- /** Used to check objects for own properties. */
632
- var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
633
-
634
- /**
635
- * Gets the hash value for `key`.
636
- *
637
- * @private
638
- * @name get
639
- * @memberOf Hash
640
- * @param {string} key The key of the value to get.
641
- * @returns {*} Returns the entry value.
642
- */
643
- function hashGet(key) {
644
- var data = this.__data__;
645
- if (_nativeCreate) {
646
- var result = data[key];
647
- return result === HASH_UNDEFINED$1 ? undefined : result;
648
- }
649
- return hasOwnProperty$1.call(data, key) ? data[key] : undefined;
650
- }
651
-
652
- var _hashGet = hashGet;
653
-
654
- /** Used for built-in method references. */
655
- var objectProto = Object.prototype;
656
-
657
- /** Used to check objects for own properties. */
658
- var hasOwnProperty = objectProto.hasOwnProperty;
659
-
660
- /**
661
- * Checks if a hash value for `key` exists.
662
- *
663
- * @private
664
- * @name has
665
- * @memberOf Hash
666
- * @param {string} key The key of the entry to check.
667
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
668
- */
669
- function hashHas(key) {
670
- var data = this.__data__;
671
- return _nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);
672
- }
673
-
674
- var _hashHas = hashHas;
675
-
676
- /** Used to stand-in for `undefined` hash values. */
677
- var HASH_UNDEFINED = '__lodash_hash_undefined__';
678
-
679
- /**
680
- * Sets the hash `key` to `value`.
681
- *
682
- * @private
683
- * @name set
684
- * @memberOf Hash
685
- * @param {string} key The key of the value to set.
686
- * @param {*} value The value to set.
687
- * @returns {Object} Returns the hash instance.
688
- */
689
- function hashSet(key, value) {
690
- var data = this.__data__;
691
- this.size += this.has(key) ? 0 : 1;
692
- data[key] = (_nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
693
- return this;
694
- }
695
-
696
- var _hashSet = hashSet;
697
-
698
- /**
699
- * Creates a hash object.
700
- *
701
- * @private
702
- * @constructor
703
- * @param {Array} [entries] The key-value pairs to cache.
704
- */
705
- function Hash(entries) {
706
- var index = -1,
707
- length = entries == null ? 0 : entries.length;
708
-
709
- this.clear();
710
- while (++index < length) {
711
- var entry = entries[index];
712
- this.set(entry[0], entry[1]);
713
- }
714
- }
715
-
716
- // Add methods to `Hash`.
717
- Hash.prototype.clear = _hashClear;
718
- Hash.prototype['delete'] = _hashDelete;
719
- Hash.prototype.get = _hashGet;
720
- Hash.prototype.has = _hashHas;
721
- Hash.prototype.set = _hashSet;
722
-
723
- var _Hash = Hash;
724
-
725
- /**
726
- * Removes all key-value entries from the list cache.
727
- *
728
- * @private
729
- * @name clear
730
- * @memberOf ListCache
731
- */
732
- function listCacheClear() {
733
- this.__data__ = [];
734
- this.size = 0;
735
- }
736
-
737
- var _listCacheClear = listCacheClear;
738
-
739
- /**
740
- * Performs a
741
- * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
742
- * comparison between two values to determine if they are equivalent.
743
- *
744
- * @static
745
- * @memberOf _
746
- * @since 4.0.0
747
- * @category Lang
748
- * @param {*} value The value to compare.
749
- * @param {*} other The other value to compare.
750
- * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
751
- * @example
752
- *
753
- * var object = { 'a': 1 };
754
- * var other = { 'a': 1 };
755
- *
756
- * _.eq(object, object);
757
- * // => true
758
- *
759
- * _.eq(object, other);
760
- * // => false
761
- *
762
- * _.eq('a', 'a');
763
- * // => true
764
- *
765
- * _.eq('a', Object('a'));
766
- * // => false
767
- *
768
- * _.eq(NaN, NaN);
769
- * // => true
770
- */
771
- function eq(value, other) {
772
- return value === other || (value !== value && other !== other);
773
- }
774
-
775
- var eq_1 = eq;
776
-
777
- /**
778
- * Gets the index at which the `key` is found in `array` of key-value pairs.
779
- *
780
- * @private
781
- * @param {Array} array The array to inspect.
782
- * @param {*} key The key to search for.
783
- * @returns {number} Returns the index of the matched value, else `-1`.
784
- */
785
- function assocIndexOf(array, key) {
786
- var length = array.length;
787
- while (length--) {
788
- if (eq_1(array[length][0], key)) {
789
- return length;
790
- }
791
- }
792
- return -1;
793
- }
794
-
795
- var _assocIndexOf = assocIndexOf;
796
-
797
- /** Used for built-in method references. */
798
- var arrayProto = Array.prototype;
799
-
800
- /** Built-in value references. */
801
- var splice = arrayProto.splice;
802
-
803
- /**
804
- * Removes `key` and its value from the list cache.
805
- *
806
- * @private
807
- * @name delete
808
- * @memberOf ListCache
809
- * @param {string} key The key of the value to remove.
810
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
811
- */
812
- function listCacheDelete(key) {
813
- var data = this.__data__,
814
- index = _assocIndexOf(data, key);
815
-
816
- if (index < 0) {
817
- return false;
818
- }
819
- var lastIndex = data.length - 1;
820
- if (index == lastIndex) {
821
- data.pop();
822
- } else {
823
- splice.call(data, index, 1);
824
- }
825
- --this.size;
826
- return true;
827
- }
828
-
829
- var _listCacheDelete = listCacheDelete;
830
-
831
- /**
832
- * Gets the list cache value for `key`.
833
- *
834
- * @private
835
- * @name get
836
- * @memberOf ListCache
837
- * @param {string} key The key of the value to get.
838
- * @returns {*} Returns the entry value.
839
- */
840
- function listCacheGet(key) {
841
- var data = this.__data__,
842
- index = _assocIndexOf(data, key);
843
-
844
- return index < 0 ? undefined : data[index][1];
845
- }
846
-
847
- var _listCacheGet = listCacheGet;
848
-
849
- /**
850
- * Checks if a list cache value for `key` exists.
851
- *
852
- * @private
853
- * @name has
854
- * @memberOf ListCache
855
- * @param {string} key The key of the entry to check.
856
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
857
- */
858
- function listCacheHas(key) {
859
- return _assocIndexOf(this.__data__, key) > -1;
860
- }
861
-
862
- var _listCacheHas = listCacheHas;
863
-
864
- /**
865
- * Sets the list cache `key` to `value`.
866
- *
867
- * @private
868
- * @name set
869
- * @memberOf ListCache
870
- * @param {string} key The key of the value to set.
871
- * @param {*} value The value to set.
872
- * @returns {Object} Returns the list cache instance.
873
- */
874
- function listCacheSet(key, value) {
875
- var data = this.__data__,
876
- index = _assocIndexOf(data, key);
877
-
878
- if (index < 0) {
879
- ++this.size;
880
- data.push([key, value]);
881
- } else {
882
- data[index][1] = value;
883
- }
884
- return this;
885
- }
886
-
887
- var _listCacheSet = listCacheSet;
888
-
889
- /**
890
- * Creates an list cache object.
891
- *
892
- * @private
893
- * @constructor
894
- * @param {Array} [entries] The key-value pairs to cache.
895
- */
896
- function ListCache(entries) {
897
- var index = -1,
898
- length = entries == null ? 0 : entries.length;
899
-
900
- this.clear();
901
- while (++index < length) {
902
- var entry = entries[index];
903
- this.set(entry[0], entry[1]);
904
- }
905
- }
906
-
907
- // Add methods to `ListCache`.
908
- ListCache.prototype.clear = _listCacheClear;
909
- ListCache.prototype['delete'] = _listCacheDelete;
910
- ListCache.prototype.get = _listCacheGet;
911
- ListCache.prototype.has = _listCacheHas;
912
- ListCache.prototype.set = _listCacheSet;
913
-
914
- var _ListCache = ListCache;
915
-
916
- /* Built-in method references that are verified to be native. */
917
- var Map = _getNative(_root, 'Map');
918
-
919
- var _Map = Map;
920
-
921
- /**
922
- * Removes all key-value entries from the map.
923
- *
924
- * @private
925
- * @name clear
926
- * @memberOf MapCache
927
- */
928
- function mapCacheClear() {
929
- this.size = 0;
930
- this.__data__ = {
931
- 'hash': new _Hash,
932
- 'map': new (_Map || _ListCache),
933
- 'string': new _Hash
934
- };
935
- }
936
-
937
- var _mapCacheClear = mapCacheClear;
938
-
939
- /**
940
- * Checks if `value` is suitable for use as unique object key.
941
- *
942
- * @private
943
- * @param {*} value The value to check.
944
- * @returns {boolean} Returns `true` if `value` is suitable, else `false`.
945
- */
946
- function isKeyable(value) {
947
- var type = typeof value;
948
- return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
949
- ? (value !== '__proto__')
950
- : (value === null);
951
- }
952
-
953
- var _isKeyable = isKeyable;
954
-
955
- /**
956
- * Gets the data for `map`.
957
- *
958
- * @private
959
- * @param {Object} map The map to query.
960
- * @param {string} key The reference key.
961
- * @returns {*} Returns the map data.
962
- */
963
- function getMapData(map, key) {
964
- var data = map.__data__;
965
- return _isKeyable(key)
966
- ? data[typeof key == 'string' ? 'string' : 'hash']
967
- : data.map;
968
- }
969
-
970
- var _getMapData = getMapData;
971
-
972
- /**
973
- * Removes `key` and its value from the map.
974
- *
975
- * @private
976
- * @name delete
977
- * @memberOf MapCache
978
- * @param {string} key The key of the value to remove.
979
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
980
- */
981
- function mapCacheDelete(key) {
982
- var result = _getMapData(this, key)['delete'](key);
983
- this.size -= result ? 1 : 0;
984
- return result;
985
- }
986
-
987
- var _mapCacheDelete = mapCacheDelete;
988
-
989
- /**
990
- * Gets the map value for `key`.
991
- *
992
- * @private
993
- * @name get
994
- * @memberOf MapCache
995
- * @param {string} key The key of the value to get.
996
- * @returns {*} Returns the entry value.
997
- */
998
- function mapCacheGet(key) {
999
- return _getMapData(this, key).get(key);
1000
- }
1001
-
1002
- var _mapCacheGet = mapCacheGet;
1003
-
1004
- /**
1005
- * Checks if a map value for `key` exists.
1006
- *
1007
- * @private
1008
- * @name has
1009
- * @memberOf MapCache
1010
- * @param {string} key The key of the entry to check.
1011
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
1012
- */
1013
- function mapCacheHas(key) {
1014
- return _getMapData(this, key).has(key);
1015
- }
1016
-
1017
- var _mapCacheHas = mapCacheHas;
1018
-
1019
- /**
1020
- * Sets the map `key` to `value`.
1021
- *
1022
- * @private
1023
- * @name set
1024
- * @memberOf MapCache
1025
- * @param {string} key The key of the value to set.
1026
- * @param {*} value The value to set.
1027
- * @returns {Object} Returns the map cache instance.
1028
- */
1029
- function mapCacheSet(key, value) {
1030
- var data = _getMapData(this, key),
1031
- size = data.size;
1032
-
1033
- data.set(key, value);
1034
- this.size += data.size == size ? 0 : 1;
1035
- return this;
1036
- }
1037
-
1038
- var _mapCacheSet = mapCacheSet;
1039
-
1040
- /**
1041
- * Creates a map cache object to store key-value pairs.
1042
- *
1043
- * @private
1044
- * @constructor
1045
- * @param {Array} [entries] The key-value pairs to cache.
1046
- */
1047
- function MapCache(entries) {
1048
- var index = -1,
1049
- length = entries == null ? 0 : entries.length;
1050
-
1051
- this.clear();
1052
- while (++index < length) {
1053
- var entry = entries[index];
1054
- this.set(entry[0], entry[1]);
1055
- }
1056
- }
1057
-
1058
- // Add methods to `MapCache`.
1059
- MapCache.prototype.clear = _mapCacheClear;
1060
- MapCache.prototype['delete'] = _mapCacheDelete;
1061
- MapCache.prototype.get = _mapCacheGet;
1062
- MapCache.prototype.has = _mapCacheHas;
1063
- MapCache.prototype.set = _mapCacheSet;
1064
-
1065
- var _MapCache = MapCache;
1066
-
1067
- /** Error message constants. */
1068
- var FUNC_ERROR_TEXT = 'Expected a function';
1069
-
1070
- /**
1071
- * Creates a function that memoizes the result of `func`. If `resolver` is
1072
- * provided, it determines the cache key for storing the result based on the
1073
- * arguments provided to the memoized function. By default, the first argument
1074
- * provided to the memoized function is used as the map cache key. The `func`
1075
- * is invoked with the `this` binding of the memoized function.
1076
- *
1077
- * **Note:** The cache is exposed as the `cache` property on the memoized
1078
- * function. Its creation may be customized by replacing the `_.memoize.Cache`
1079
- * constructor with one whose instances implement the
1080
- * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)
1081
- * method interface of `clear`, `delete`, `get`, `has`, and `set`.
1082
- *
1083
- * @static
1084
- * @memberOf _
1085
- * @since 0.1.0
1086
- * @category Function
1087
- * @param {Function} func The function to have its output memoized.
1088
- * @param {Function} [resolver] The function to resolve the cache key.
1089
- * @returns {Function} Returns the new memoized function.
1090
- * @example
1091
- *
1092
- * var object = { 'a': 1, 'b': 2 };
1093
- * var other = { 'c': 3, 'd': 4 };
1094
- *
1095
- * var values = _.memoize(_.values);
1096
- * values(object);
1097
- * // => [1, 2]
1098
- *
1099
- * values(other);
1100
- * // => [3, 4]
1101
- *
1102
- * object.a = 2;
1103
- * values(object);
1104
- * // => [1, 2]
1105
- *
1106
- * // Modify the result cache.
1107
- * values.cache.set(object, ['a', 'b']);
1108
- * values(object);
1109
- * // => ['a', 'b']
1110
- *
1111
- * // Replace `_.memoize.Cache`.
1112
- * _.memoize.Cache = WeakMap;
1113
- */
1114
- function memoize(func, resolver) {
1115
- if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {
1116
- throw new TypeError(FUNC_ERROR_TEXT);
1117
- }
1118
- var memoized = function() {
1119
- var args = arguments,
1120
- key = resolver ? resolver.apply(this, args) : args[0],
1121
- cache = memoized.cache;
1122
-
1123
- if (cache.has(key)) {
1124
- return cache.get(key);
1125
- }
1126
- var result = func.apply(this, args);
1127
- memoized.cache = cache.set(key, result) || cache;
1128
- return result;
1129
- };
1130
- memoized.cache = new (memoize.Cache || _MapCache);
1131
- return memoized;
1132
- }
1133
-
1134
- // Expose `MapCache`.
1135
- memoize.Cache = _MapCache;
1136
-
1137
- var memoize_1 = memoize;
1138
-
1139
- /** Used as the maximum memoize cache size. */
1140
- var MAX_MEMOIZE_SIZE = 500;
1141
-
1142
- /**
1143
- * A specialized version of `_.memoize` which clears the memoized function's
1144
- * cache when it exceeds `MAX_MEMOIZE_SIZE`.
1145
- *
1146
- * @private
1147
- * @param {Function} func The function to have its output memoized.
1148
- * @returns {Function} Returns the new memoized function.
1149
- */
1150
- function memoizeCapped(func) {
1151
- var result = memoize_1(func, function(key) {
1152
- if (cache.size === MAX_MEMOIZE_SIZE) {
1153
- cache.clear();
1154
- }
1155
- return key;
1156
- });
1157
-
1158
- var cache = result.cache;
1159
- return result;
1160
- }
1161
-
1162
- var _memoizeCapped = memoizeCapped;
1163
-
1164
- /** Used to match property names within property paths. */
1165
- var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
1166
-
1167
- /** Used to match backslashes in property paths. */
1168
- var reEscapeChar = /\\(\\)?/g;
1169
-
1170
- /**
1171
- * Converts `string` to a property path array.
1172
- *
1173
- * @private
1174
- * @param {string} string The string to convert.
1175
- * @returns {Array} Returns the property path array.
1176
- */
1177
- var stringToPath = _memoizeCapped(function(string) {
1178
- var result = [];
1179
- if (string.charCodeAt(0) === 46 /* . */) {
1180
- result.push('');
1181
- }
1182
- string.replace(rePropName, function(match, number, quote, subString) {
1183
- result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));
1184
- });
1185
- return result;
1186
- });
1187
-
1188
- var _stringToPath = stringToPath;
1189
-
1190
- /**
1191
- * A specialized version of `_.map` for arrays without support for iteratee
1192
- * shorthands.
1193
- *
1194
- * @private
1195
- * @param {Array} [array] The array to iterate over.
1196
- * @param {Function} iteratee The function invoked per iteration.
1197
- * @returns {Array} Returns the new mapped array.
1198
- */
1199
- function arrayMap(array, iteratee) {
1200
- var index = -1,
1201
- length = array == null ? 0 : array.length,
1202
- result = Array(length);
1203
-
1204
- while (++index < length) {
1205
- result[index] = iteratee(array[index], index, array);
1206
- }
1207
- return result;
1208
- }
1209
-
1210
- var _arrayMap = arrayMap;
1211
-
1212
- /** Used as references for various `Number` constants. */
1213
- var INFINITY$1 = 1 / 0;
1214
-
1215
- /** Used to convert symbols to primitives and strings. */
1216
- var symbolProto = _Symbol ? _Symbol.prototype : undefined,
1217
- symbolToString = symbolProto ? symbolProto.toString : undefined;
1218
-
1219
- /**
1220
- * The base implementation of `_.toString` which doesn't convert nullish
1221
- * values to empty strings.
1222
- *
1223
- * @private
1224
- * @param {*} value The value to process.
1225
- * @returns {string} Returns the string.
1226
- */
1227
- function baseToString(value) {
1228
- // Exit early for strings to avoid a performance hit in some environments.
1229
- if (typeof value == 'string') {
1230
- return value;
1231
- }
1232
- if (isArray_1(value)) {
1233
- // Recursively convert values (susceptible to call stack limits).
1234
- return _arrayMap(value, baseToString) + '';
1235
- }
1236
- if (isSymbol_1(value)) {
1237
- return symbolToString ? symbolToString.call(value) : '';
1238
- }
1239
- var result = (value + '');
1240
- return (result == '0' && (1 / value) == -INFINITY$1) ? '-0' : result;
1241
- }
1242
-
1243
- var _baseToString = baseToString;
1244
-
1245
- /**
1246
- * Converts `value` to a string. An empty string is returned for `null`
1247
- * and `undefined` values. The sign of `-0` is preserved.
1248
- *
1249
- * @static
1250
- * @memberOf _
1251
- * @since 4.0.0
1252
- * @category Lang
1253
- * @param {*} value The value to convert.
1254
- * @returns {string} Returns the converted string.
1255
- * @example
1256
- *
1257
- * _.toString(null);
1258
- * // => ''
1259
- *
1260
- * _.toString(-0);
1261
- * // => '-0'
1262
- *
1263
- * _.toString([1, 2, 3]);
1264
- * // => '1,2,3'
1265
- */
1266
- function toString(value) {
1267
- return value == null ? '' : _baseToString(value);
1268
- }
1269
-
1270
- var toString_1 = toString;
1271
-
1272
- /**
1273
- * Casts `value` to a path array if it's not one.
1274
- *
1275
- * @private
1276
- * @param {*} value The value to inspect.
1277
- * @param {Object} [object] The object to query keys on.
1278
- * @returns {Array} Returns the cast property path array.
1279
- */
1280
- function castPath(value, object) {
1281
- if (isArray_1(value)) {
1282
- return value;
1283
- }
1284
- return _isKey(value, object) ? [value] : _stringToPath(toString_1(value));
1285
- }
1286
-
1287
- var _castPath = castPath;
1288
-
1289
- /** Used as references for various `Number` constants. */
1290
- var INFINITY = 1 / 0;
1291
-
1292
- /**
1293
- * Converts `value` to a string key if it's not a string or symbol.
1294
- *
1295
- * @private
1296
- * @param {*} value The value to inspect.
1297
- * @returns {string|symbol} Returns the key.
1298
- */
1299
- function toKey(value) {
1300
- if (typeof value == 'string' || isSymbol_1(value)) {
1301
- return value;
1302
- }
1303
- var result = (value + '');
1304
- return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
1305
- }
1306
-
1307
- var _toKey = toKey;
1308
-
1309
- /**
1310
- * The base implementation of `_.get` without support for default values.
1311
- *
1312
- * @private
1313
- * @param {Object} object The object to query.
1314
- * @param {Array|string} path The path of the property to get.
1315
- * @returns {*} Returns the resolved value.
1316
- */
1317
- function baseGet(object, path) {
1318
- path = _castPath(path, object);
1319
-
1320
- var index = 0,
1321
- length = path.length;
1322
-
1323
- while (object != null && index < length) {
1324
- object = object[_toKey(path[index++])];
34
+ });
1325
35
  }
1326
- return (index && index == length) ? object : undefined;
36
+ n["default"] = e;
37
+ return Object.freeze(n);
1327
38
  }
1328
39
 
1329
- var _baseGet = baseGet;
1330
-
1331
- /**
1332
- * Gets the value at `path` of `object`. If the resolved value is
1333
- * `undefined`, the `defaultValue` is returned in its place.
1334
- *
1335
- * @static
1336
- * @memberOf _
1337
- * @since 3.7.0
1338
- * @category Object
1339
- * @param {Object} object The object to query.
1340
- * @param {Array|string} path The path of the property to get.
1341
- * @param {*} [defaultValue] The value returned for `undefined` resolved values.
1342
- * @returns {*} Returns the resolved value.
1343
- * @example
1344
- *
1345
- * var object = { 'a': [{ 'b': { 'c': 3 } }] };
1346
- *
1347
- * _.get(object, 'a[0].b.c');
1348
- * // => 3
1349
- *
1350
- * _.get(object, ['a', '0', 'b', 'c']);
1351
- * // => 3
1352
- *
1353
- * _.get(object, 'a.b.c', 'default');
1354
- * // => 'default'
1355
- */
1356
- function get(object, path, defaultValue) {
1357
- var result = object == null ? undefined : _baseGet(object, path);
1358
- return result === undefined ? defaultValue : result;
1359
- }
1360
-
1361
- var get_1 = get;
40
+ var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_defineProperty);
41
+ var _getClassName__default = /*#__PURE__*/_interopDefaultLegacy(_getClassName);
42
+ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
43
+ var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
44
+ var Timeago__default = /*#__PURE__*/_interopDefaultLegacy(Timeago);
45
+ var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM);
46
+ var _slicedToArray__default = /*#__PURE__*/_interopDefaultLegacy(_slicedToArray);
1362
47
 
1363
- var StateContext = /*#__PURE__*/createContext(); // eslint-disable-next-line react/display-name
48
+ var StateContext = /*#__PURE__*/React.createContext(); // eslint-disable-next-line react/display-name
1364
49
 
1365
50
  var StateProvider = function StateProvider(RowComponent) {
1366
51
  return function (props) {
1367
52
  return (
1368
53
  /*#__PURE__*/
1369
54
  // eslint-disable-next-line react/prop-types
1370
- React.createElement(StateContext.Provider, {
55
+ React__default["default"].createElement(StateContext.Provider, {
1371
56
  value: props.config
1372
- }, /*#__PURE__*/React.createElement(RowComponent, props))
57
+ }, /*#__PURE__*/React__default["default"].createElement(RowComponent, props))
1373
58
  );
1374
59
  };
1375
60
  };
1376
61
  var useStateValue = function useStateValue() {
1377
- return useContext(StateContext);
1378
- };
1379
-
1380
- /**
1381
- * Copyright (c) 2014-present, Facebook, Inc.
1382
- *
1383
- * This source code is licensed under the MIT license found in the
1384
- * LICENSE file in the root directory of this source tree.
1385
- */
1386
-
1387
- createCommonjsModule(function (module) {
1388
- var runtime = (function (exports) {
1389
-
1390
- var Op = Object.prototype;
1391
- var hasOwn = Op.hasOwnProperty;
1392
- var undefined$1; // More compressible than void 0.
1393
- var $Symbol = typeof Symbol === "function" ? Symbol : {};
1394
- var iteratorSymbol = $Symbol.iterator || "@@iterator";
1395
- var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
1396
- var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
1397
-
1398
- function define(obj, key, value) {
1399
- Object.defineProperty(obj, key, {
1400
- value: value,
1401
- enumerable: true,
1402
- configurable: true,
1403
- writable: true
1404
- });
1405
- return obj[key];
1406
- }
1407
- try {
1408
- // IE 8 has a broken Object.defineProperty that only works on DOM objects.
1409
- define({}, "");
1410
- } catch (err) {
1411
- define = function(obj, key, value) {
1412
- return obj[key] = value;
1413
- };
1414
- }
1415
-
1416
- function wrap(innerFn, outerFn, self, tryLocsList) {
1417
- // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
1418
- var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
1419
- var generator = Object.create(protoGenerator.prototype);
1420
- var context = new Context(tryLocsList || []);
1421
-
1422
- // The ._invoke method unifies the implementations of the .next,
1423
- // .throw, and .return methods.
1424
- generator._invoke = makeInvokeMethod(innerFn, self, context);
1425
-
1426
- return generator;
1427
- }
1428
- exports.wrap = wrap;
1429
-
1430
- // Try/catch helper to minimize deoptimizations. Returns a completion
1431
- // record like context.tryEntries[i].completion. This interface could
1432
- // have been (and was previously) designed to take a closure to be
1433
- // invoked without arguments, but in all the cases we care about we
1434
- // already have an existing method we want to call, so there's no need
1435
- // to create a new function object. We can even get away with assuming
1436
- // the method takes exactly one argument, since that happens to be true
1437
- // in every case, so we don't have to touch the arguments object. The
1438
- // only additional allocation required is the completion record, which
1439
- // has a stable shape and so hopefully should be cheap to allocate.
1440
- function tryCatch(fn, obj, arg) {
1441
- try {
1442
- return { type: "normal", arg: fn.call(obj, arg) };
1443
- } catch (err) {
1444
- return { type: "throw", arg: err };
1445
- }
1446
- }
1447
-
1448
- var GenStateSuspendedStart = "suspendedStart";
1449
- var GenStateSuspendedYield = "suspendedYield";
1450
- var GenStateExecuting = "executing";
1451
- var GenStateCompleted = "completed";
1452
-
1453
- // Returning this object from the innerFn has the same effect as
1454
- // breaking out of the dispatch switch statement.
1455
- var ContinueSentinel = {};
1456
-
1457
- // Dummy constructor functions that we use as the .constructor and
1458
- // .constructor.prototype properties for functions that return Generator
1459
- // objects. For full spec compliance, you may wish to configure your
1460
- // minifier not to mangle the names of these two functions.
1461
- function Generator() {}
1462
- function GeneratorFunction() {}
1463
- function GeneratorFunctionPrototype() {}
1464
-
1465
- // This is a polyfill for %IteratorPrototype% for environments that
1466
- // don't natively support it.
1467
- var IteratorPrototype = {};
1468
- define(IteratorPrototype, iteratorSymbol, function () {
1469
- return this;
1470
- });
1471
-
1472
- var getProto = Object.getPrototypeOf;
1473
- var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
1474
- if (NativeIteratorPrototype &&
1475
- NativeIteratorPrototype !== Op &&
1476
- hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
1477
- // This environment has a native %IteratorPrototype%; use it instead
1478
- // of the polyfill.
1479
- IteratorPrototype = NativeIteratorPrototype;
1480
- }
1481
-
1482
- var Gp = GeneratorFunctionPrototype.prototype =
1483
- Generator.prototype = Object.create(IteratorPrototype);
1484
- GeneratorFunction.prototype = GeneratorFunctionPrototype;
1485
- define(Gp, "constructor", GeneratorFunctionPrototype);
1486
- define(GeneratorFunctionPrototype, "constructor", GeneratorFunction);
1487
- GeneratorFunction.displayName = define(
1488
- GeneratorFunctionPrototype,
1489
- toStringTagSymbol,
1490
- "GeneratorFunction"
1491
- );
1492
-
1493
- // Helper for defining the .next, .throw, and .return methods of the
1494
- // Iterator interface in terms of a single ._invoke method.
1495
- function defineIteratorMethods(prototype) {
1496
- ["next", "throw", "return"].forEach(function(method) {
1497
- define(prototype, method, function(arg) {
1498
- return this._invoke(method, arg);
1499
- });
1500
- });
1501
- }
1502
-
1503
- exports.isGeneratorFunction = function(genFun) {
1504
- var ctor = typeof genFun === "function" && genFun.constructor;
1505
- return ctor
1506
- ? ctor === GeneratorFunction ||
1507
- // For the native GeneratorFunction constructor, the best we can
1508
- // do is to check its .name property.
1509
- (ctor.displayName || ctor.name) === "GeneratorFunction"
1510
- : false;
1511
- };
1512
-
1513
- exports.mark = function(genFun) {
1514
- if (Object.setPrototypeOf) {
1515
- Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
1516
- } else {
1517
- genFun.__proto__ = GeneratorFunctionPrototype;
1518
- define(genFun, toStringTagSymbol, "GeneratorFunction");
1519
- }
1520
- genFun.prototype = Object.create(Gp);
1521
- return genFun;
1522
- };
1523
-
1524
- // Within the body of any async function, `await x` is transformed to
1525
- // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
1526
- // `hasOwn.call(value, "__await")` to determine if the yielded value is
1527
- // meant to be awaited.
1528
- exports.awrap = function(arg) {
1529
- return { __await: arg };
1530
- };
1531
-
1532
- function AsyncIterator(generator, PromiseImpl) {
1533
- function invoke(method, arg, resolve, reject) {
1534
- var record = tryCatch(generator[method], generator, arg);
1535
- if (record.type === "throw") {
1536
- reject(record.arg);
1537
- } else {
1538
- var result = record.arg;
1539
- var value = result.value;
1540
- if (value &&
1541
- typeof value === "object" &&
1542
- hasOwn.call(value, "__await")) {
1543
- return PromiseImpl.resolve(value.__await).then(function(value) {
1544
- invoke("next", value, resolve, reject);
1545
- }, function(err) {
1546
- invoke("throw", err, resolve, reject);
1547
- });
1548
- }
1549
-
1550
- return PromiseImpl.resolve(value).then(function(unwrapped) {
1551
- // When a yielded Promise is resolved, its final value becomes
1552
- // the .value of the Promise<{value,done}> result for the
1553
- // current iteration.
1554
- result.value = unwrapped;
1555
- resolve(result);
1556
- }, function(error) {
1557
- // If a rejected Promise was yielded, throw the rejection back
1558
- // into the async generator function so it can be handled there.
1559
- return invoke("throw", error, resolve, reject);
1560
- });
1561
- }
1562
- }
1563
-
1564
- var previousPromise;
1565
-
1566
- function enqueue(method, arg) {
1567
- function callInvokeWithMethodAndArg() {
1568
- return new PromiseImpl(function(resolve, reject) {
1569
- invoke(method, arg, resolve, reject);
1570
- });
1571
- }
1572
-
1573
- return previousPromise =
1574
- // If enqueue has been called before, then we want to wait until
1575
- // all previous Promises have been resolved before calling invoke,
1576
- // so that results are always delivered in the correct order. If
1577
- // enqueue has not been called before, then it is important to
1578
- // call invoke immediately, without waiting on a callback to fire,
1579
- // so that the async generator function has the opportunity to do
1580
- // any necessary setup in a predictable way. This predictability
1581
- // is why the Promise constructor synchronously invokes its
1582
- // executor callback, and why async functions synchronously
1583
- // execute code before the first await. Since we implement simple
1584
- // async functions in terms of async generators, it is especially
1585
- // important to get this right, even though it requires care.
1586
- previousPromise ? previousPromise.then(
1587
- callInvokeWithMethodAndArg,
1588
- // Avoid propagating failures to Promises returned by later
1589
- // invocations of the iterator.
1590
- callInvokeWithMethodAndArg
1591
- ) : callInvokeWithMethodAndArg();
1592
- }
1593
-
1594
- // Define the unified helper method that is used to implement .next,
1595
- // .throw, and .return (see defineIteratorMethods).
1596
- this._invoke = enqueue;
1597
- }
1598
-
1599
- defineIteratorMethods(AsyncIterator.prototype);
1600
- define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
1601
- return this;
1602
- });
1603
- exports.AsyncIterator = AsyncIterator;
1604
-
1605
- // Note that simple async functions are implemented on top of
1606
- // AsyncIterator objects; they just return a Promise for the value of
1607
- // the final result produced by the iterator.
1608
- exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
1609
- if (PromiseImpl === void 0) PromiseImpl = Promise;
1610
-
1611
- var iter = new AsyncIterator(
1612
- wrap(innerFn, outerFn, self, tryLocsList),
1613
- PromiseImpl
1614
- );
1615
-
1616
- return exports.isGeneratorFunction(outerFn)
1617
- ? iter // If outerFn is a generator, return the full iterator.
1618
- : iter.next().then(function(result) {
1619
- return result.done ? result.value : iter.next();
1620
- });
1621
- };
1622
-
1623
- function makeInvokeMethod(innerFn, self, context) {
1624
- var state = GenStateSuspendedStart;
1625
-
1626
- return function invoke(method, arg) {
1627
- if (state === GenStateExecuting) {
1628
- throw new Error("Generator is already running");
1629
- }
1630
-
1631
- if (state === GenStateCompleted) {
1632
- if (method === "throw") {
1633
- throw arg;
1634
- }
1635
-
1636
- // Be forgiving, per 25.3.3.3.3 of the spec:
1637
- // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
1638
- return doneResult();
1639
- }
1640
-
1641
- context.method = method;
1642
- context.arg = arg;
1643
-
1644
- while (true) {
1645
- var delegate = context.delegate;
1646
- if (delegate) {
1647
- var delegateResult = maybeInvokeDelegate(delegate, context);
1648
- if (delegateResult) {
1649
- if (delegateResult === ContinueSentinel) continue;
1650
- return delegateResult;
1651
- }
1652
- }
1653
-
1654
- if (context.method === "next") {
1655
- // Setting context._sent for legacy support of Babel's
1656
- // function.sent implementation.
1657
- context.sent = context._sent = context.arg;
1658
-
1659
- } else if (context.method === "throw") {
1660
- if (state === GenStateSuspendedStart) {
1661
- state = GenStateCompleted;
1662
- throw context.arg;
1663
- }
1664
-
1665
- context.dispatchException(context.arg);
1666
-
1667
- } else if (context.method === "return") {
1668
- context.abrupt("return", context.arg);
1669
- }
1670
-
1671
- state = GenStateExecuting;
1672
-
1673
- var record = tryCatch(innerFn, self, context);
1674
- if (record.type === "normal") {
1675
- // If an exception is thrown from innerFn, we leave state ===
1676
- // GenStateExecuting and loop back for another invocation.
1677
- state = context.done
1678
- ? GenStateCompleted
1679
- : GenStateSuspendedYield;
1680
-
1681
- if (record.arg === ContinueSentinel) {
1682
- continue;
1683
- }
1684
-
1685
- return {
1686
- value: record.arg,
1687
- done: context.done
1688
- };
1689
-
1690
- } else if (record.type === "throw") {
1691
- state = GenStateCompleted;
1692
- // Dispatch the exception by looping back around to the
1693
- // context.dispatchException(context.arg) call above.
1694
- context.method = "throw";
1695
- context.arg = record.arg;
1696
- }
1697
- }
1698
- };
1699
- }
1700
-
1701
- // Call delegate.iterator[context.method](context.arg) and handle the
1702
- // result, either by returning a { value, done } result from the
1703
- // delegate iterator, or by modifying context.method and context.arg,
1704
- // setting context.delegate to null, and returning the ContinueSentinel.
1705
- function maybeInvokeDelegate(delegate, context) {
1706
- var method = delegate.iterator[context.method];
1707
- if (method === undefined$1) {
1708
- // A .throw or .return when the delegate iterator has no .throw
1709
- // method always terminates the yield* loop.
1710
- context.delegate = null;
1711
-
1712
- if (context.method === "throw") {
1713
- // Note: ["return"] must be used for ES3 parsing compatibility.
1714
- if (delegate.iterator["return"]) {
1715
- // If the delegate iterator has a return method, give it a
1716
- // chance to clean up.
1717
- context.method = "return";
1718
- context.arg = undefined$1;
1719
- maybeInvokeDelegate(delegate, context);
1720
-
1721
- if (context.method === "throw") {
1722
- // If maybeInvokeDelegate(context) changed context.method from
1723
- // "return" to "throw", let that override the TypeError below.
1724
- return ContinueSentinel;
1725
- }
1726
- }
1727
-
1728
- context.method = "throw";
1729
- context.arg = new TypeError(
1730
- "The iterator does not provide a 'throw' method");
1731
- }
1732
-
1733
- return ContinueSentinel;
1734
- }
1735
-
1736
- var record = tryCatch(method, delegate.iterator, context.arg);
1737
-
1738
- if (record.type === "throw") {
1739
- context.method = "throw";
1740
- context.arg = record.arg;
1741
- context.delegate = null;
1742
- return ContinueSentinel;
1743
- }
1744
-
1745
- var info = record.arg;
1746
-
1747
- if (! info) {
1748
- context.method = "throw";
1749
- context.arg = new TypeError("iterator result is not an object");
1750
- context.delegate = null;
1751
- return ContinueSentinel;
1752
- }
1753
-
1754
- if (info.done) {
1755
- // Assign the result of the finished delegate to the temporary
1756
- // variable specified by delegate.resultName (see delegateYield).
1757
- context[delegate.resultName] = info.value;
1758
-
1759
- // Resume execution at the desired location (see delegateYield).
1760
- context.next = delegate.nextLoc;
1761
-
1762
- // If context.method was "throw" but the delegate handled the
1763
- // exception, let the outer generator proceed normally. If
1764
- // context.method was "next", forget context.arg since it has been
1765
- // "consumed" by the delegate iterator. If context.method was
1766
- // "return", allow the original .return call to continue in the
1767
- // outer generator.
1768
- if (context.method !== "return") {
1769
- context.method = "next";
1770
- context.arg = undefined$1;
1771
- }
1772
-
1773
- } else {
1774
- // Re-yield the result returned by the delegate method.
1775
- return info;
1776
- }
1777
-
1778
- // The delegate iterator is finished, so forget it and continue with
1779
- // the outer generator.
1780
- context.delegate = null;
1781
- return ContinueSentinel;
1782
- }
1783
-
1784
- // Define Generator.prototype.{next,throw,return} in terms of the
1785
- // unified ._invoke helper method.
1786
- defineIteratorMethods(Gp);
1787
-
1788
- define(Gp, toStringTagSymbol, "Generator");
1789
-
1790
- // A Generator should always return itself as the iterator object when the
1791
- // @@iterator function is called on it. Some browsers' implementations of the
1792
- // iterator prototype chain incorrectly implement this, causing the Generator
1793
- // object to not be returned from this call. This ensures that doesn't happen.
1794
- // See https://github.com/facebook/regenerator/issues/274 for more details.
1795
- define(Gp, iteratorSymbol, function() {
1796
- return this;
1797
- });
1798
-
1799
- define(Gp, "toString", function() {
1800
- return "[object Generator]";
1801
- });
1802
-
1803
- function pushTryEntry(locs) {
1804
- var entry = { tryLoc: locs[0] };
1805
-
1806
- if (1 in locs) {
1807
- entry.catchLoc = locs[1];
1808
- }
1809
-
1810
- if (2 in locs) {
1811
- entry.finallyLoc = locs[2];
1812
- entry.afterLoc = locs[3];
1813
- }
1814
-
1815
- this.tryEntries.push(entry);
1816
- }
1817
-
1818
- function resetTryEntry(entry) {
1819
- var record = entry.completion || {};
1820
- record.type = "normal";
1821
- delete record.arg;
1822
- entry.completion = record;
1823
- }
1824
-
1825
- function Context(tryLocsList) {
1826
- // The root entry object (effectively a try statement without a catch
1827
- // or a finally block) gives us a place to store values thrown from
1828
- // locations where there is no enclosing try statement.
1829
- this.tryEntries = [{ tryLoc: "root" }];
1830
- tryLocsList.forEach(pushTryEntry, this);
1831
- this.reset(true);
1832
- }
1833
-
1834
- exports.keys = function(object) {
1835
- var keys = [];
1836
- for (var key in object) {
1837
- keys.push(key);
1838
- }
1839
- keys.reverse();
1840
-
1841
- // Rather than returning an object with a next method, we keep
1842
- // things simple and return the next function itself.
1843
- return function next() {
1844
- while (keys.length) {
1845
- var key = keys.pop();
1846
- if (key in object) {
1847
- next.value = key;
1848
- next.done = false;
1849
- return next;
1850
- }
1851
- }
1852
-
1853
- // To avoid creating an additional object, we just hang the .value
1854
- // and .done properties off the next function object itself. This
1855
- // also ensures that the minifier will not anonymize the function.
1856
- next.done = true;
1857
- return next;
1858
- };
1859
- };
1860
-
1861
- function values(iterable) {
1862
- if (iterable) {
1863
- var iteratorMethod = iterable[iteratorSymbol];
1864
- if (iteratorMethod) {
1865
- return iteratorMethod.call(iterable);
1866
- }
1867
-
1868
- if (typeof iterable.next === "function") {
1869
- return iterable;
1870
- }
1871
-
1872
- if (!isNaN(iterable.length)) {
1873
- var i = -1, next = function next() {
1874
- while (++i < iterable.length) {
1875
- if (hasOwn.call(iterable, i)) {
1876
- next.value = iterable[i];
1877
- next.done = false;
1878
- return next;
1879
- }
1880
- }
1881
-
1882
- next.value = undefined$1;
1883
- next.done = true;
1884
-
1885
- return next;
1886
- };
1887
-
1888
- return next.next = next;
1889
- }
1890
- }
1891
-
1892
- // Return an iterator with no values.
1893
- return { next: doneResult };
1894
- }
1895
- exports.values = values;
1896
-
1897
- function doneResult() {
1898
- return { value: undefined$1, done: true };
1899
- }
1900
-
1901
- Context.prototype = {
1902
- constructor: Context,
1903
-
1904
- reset: function(skipTempReset) {
1905
- this.prev = 0;
1906
- this.next = 0;
1907
- // Resetting context._sent for legacy support of Babel's
1908
- // function.sent implementation.
1909
- this.sent = this._sent = undefined$1;
1910
- this.done = false;
1911
- this.delegate = null;
1912
-
1913
- this.method = "next";
1914
- this.arg = undefined$1;
1915
-
1916
- this.tryEntries.forEach(resetTryEntry);
1917
-
1918
- if (!skipTempReset) {
1919
- for (var name in this) {
1920
- // Not sure about the optimal order of these conditions:
1921
- if (name.charAt(0) === "t" &&
1922
- hasOwn.call(this, name) &&
1923
- !isNaN(+name.slice(1))) {
1924
- this[name] = undefined$1;
1925
- }
1926
- }
1927
- }
1928
- },
1929
-
1930
- stop: function() {
1931
- this.done = true;
1932
-
1933
- var rootEntry = this.tryEntries[0];
1934
- var rootRecord = rootEntry.completion;
1935
- if (rootRecord.type === "throw") {
1936
- throw rootRecord.arg;
1937
- }
1938
-
1939
- return this.rval;
1940
- },
1941
-
1942
- dispatchException: function(exception) {
1943
- if (this.done) {
1944
- throw exception;
1945
- }
1946
-
1947
- var context = this;
1948
- function handle(loc, caught) {
1949
- record.type = "throw";
1950
- record.arg = exception;
1951
- context.next = loc;
1952
-
1953
- if (caught) {
1954
- // If the dispatched exception was caught by a catch block,
1955
- // then let that catch block handle the exception normally.
1956
- context.method = "next";
1957
- context.arg = undefined$1;
1958
- }
1959
-
1960
- return !! caught;
1961
- }
1962
-
1963
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
1964
- var entry = this.tryEntries[i];
1965
- var record = entry.completion;
1966
-
1967
- if (entry.tryLoc === "root") {
1968
- // Exception thrown outside of any try block that could handle
1969
- // it, so set the completion value of the entire function to
1970
- // throw the exception.
1971
- return handle("end");
1972
- }
1973
-
1974
- if (entry.tryLoc <= this.prev) {
1975
- var hasCatch = hasOwn.call(entry, "catchLoc");
1976
- var hasFinally = hasOwn.call(entry, "finallyLoc");
1977
-
1978
- if (hasCatch && hasFinally) {
1979
- if (this.prev < entry.catchLoc) {
1980
- return handle(entry.catchLoc, true);
1981
- } else if (this.prev < entry.finallyLoc) {
1982
- return handle(entry.finallyLoc);
1983
- }
1984
-
1985
- } else if (hasCatch) {
1986
- if (this.prev < entry.catchLoc) {
1987
- return handle(entry.catchLoc, true);
1988
- }
1989
-
1990
- } else if (hasFinally) {
1991
- if (this.prev < entry.finallyLoc) {
1992
- return handle(entry.finallyLoc);
1993
- }
1994
-
1995
- } else {
1996
- throw new Error("try statement without catch or finally");
1997
- }
1998
- }
1999
- }
2000
- },
2001
-
2002
- abrupt: function(type, arg) {
2003
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
2004
- var entry = this.tryEntries[i];
2005
- if (entry.tryLoc <= this.prev &&
2006
- hasOwn.call(entry, "finallyLoc") &&
2007
- this.prev < entry.finallyLoc) {
2008
- var finallyEntry = entry;
2009
- break;
2010
- }
2011
- }
2012
-
2013
- if (finallyEntry &&
2014
- (type === "break" ||
2015
- type === "continue") &&
2016
- finallyEntry.tryLoc <= arg &&
2017
- arg <= finallyEntry.finallyLoc) {
2018
- // Ignore the finally entry if control is not jumping to a
2019
- // location outside the try/catch block.
2020
- finallyEntry = null;
2021
- }
2022
-
2023
- var record = finallyEntry ? finallyEntry.completion : {};
2024
- record.type = type;
2025
- record.arg = arg;
2026
-
2027
- if (finallyEntry) {
2028
- this.method = "next";
2029
- this.next = finallyEntry.finallyLoc;
2030
- return ContinueSentinel;
2031
- }
2032
-
2033
- return this.complete(record);
2034
- },
2035
-
2036
- complete: function(record, afterLoc) {
2037
- if (record.type === "throw") {
2038
- throw record.arg;
2039
- }
2040
-
2041
- if (record.type === "break" ||
2042
- record.type === "continue") {
2043
- this.next = record.arg;
2044
- } else if (record.type === "return") {
2045
- this.rval = this.arg = record.arg;
2046
- this.method = "return";
2047
- this.next = "end";
2048
- } else if (record.type === "normal" && afterLoc) {
2049
- this.next = afterLoc;
2050
- }
2051
-
2052
- return ContinueSentinel;
2053
- },
2054
-
2055
- finish: function(finallyLoc) {
2056
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
2057
- var entry = this.tryEntries[i];
2058
- if (entry.finallyLoc === finallyLoc) {
2059
- this.complete(entry.completion, entry.afterLoc);
2060
- resetTryEntry(entry);
2061
- return ContinueSentinel;
2062
- }
2063
- }
2064
- },
2065
-
2066
- "catch": function(tryLoc) {
2067
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
2068
- var entry = this.tryEntries[i];
2069
- if (entry.tryLoc === tryLoc) {
2070
- var record = entry.completion;
2071
- if (record.type === "throw") {
2072
- var thrown = record.arg;
2073
- resetTryEntry(entry);
2074
- }
2075
- return thrown;
2076
- }
2077
- }
2078
-
2079
- // The context.catch method must only be called with a location
2080
- // argument that corresponds to a known catch block.
2081
- throw new Error("illegal catch attempt");
2082
- },
2083
-
2084
- delegateYield: function(iterable, resultName, nextLoc) {
2085
- this.delegate = {
2086
- iterator: values(iterable),
2087
- resultName: resultName,
2088
- nextLoc: nextLoc
2089
- };
2090
-
2091
- if (this.method === "next") {
2092
- // Deliberately forget the last sent value so that we don't
2093
- // accidentally pass it on to the delegate.
2094
- this.arg = undefined$1;
2095
- }
2096
-
2097
- return ContinueSentinel;
2098
- }
2099
- };
2100
-
2101
- // Regardless of whether this script is executing as a CommonJS module
2102
- // or not, return the runtime object so that we can declare the variable
2103
- // regeneratorRuntime in the outer scope, which allows this module to be
2104
- // injected easily by `bin/regenerator --include-runtime script.js`.
2105
- return exports;
2106
-
2107
- }(
2108
- // If this script is executing as a CommonJS module, use module.exports
2109
- // as the regeneratorRuntime namespace. Otherwise create a new empty
2110
- // object. Either way, the resulting object will be used to initialize
2111
- // the regeneratorRuntime variable at the top of this file.
2112
- module.exports
2113
- ));
2114
-
2115
- try {
2116
- regeneratorRuntime = runtime;
2117
- } catch (accidentalStrictMode) {
2118
- // This module should not be running in strict mode, so the above
2119
- // assignment should always work unless something is misconfigured. Just
2120
- // in case runtime.js accidentally runs in strict mode, in modern engines
2121
- // we can explicitly access globalThis. In older engines we can escape
2122
- // strict mode using a global Function call. This could conceivably fail
2123
- // if a Content Security Policy forbids using Function, but in that case
2124
- // the proper solution is to fix the accidental strict mode problem. If
2125
- // you've misconfigured your bundler to force strict mode and applied a
2126
- // CSP to forbid Function, and you're not willing to fix either of those
2127
- // problems, please detail your unique predicament in a GitHub issue.
2128
- if (typeof globalThis === "object") {
2129
- globalThis.regeneratorRuntime = runtime;
2130
- } else {
2131
- Function("r", "regeneratorRuntime = r")(runtime);
2132
- }
2133
- }
2134
- });
2135
-
2136
- /**
2137
- * A specialized version of `_.reduce` for arrays without support for
2138
- * iteratee shorthands.
2139
- *
2140
- * @private
2141
- * @param {Array} [array] The array to iterate over.
2142
- * @param {Function} iteratee The function invoked per iteration.
2143
- * @param {*} [accumulator] The initial value.
2144
- * @param {boolean} [initAccum] Specify using the first element of `array` as
2145
- * the initial value.
2146
- * @returns {*} Returns the accumulated value.
2147
- */
2148
- function arrayReduce(array, iteratee, accumulator, initAccum) {
2149
- var index = -1,
2150
- length = array == null ? 0 : array.length;
2151
-
2152
- if (initAccum && length) {
2153
- accumulator = array[++index];
2154
- }
2155
- while (++index < length) {
2156
- accumulator = iteratee(accumulator, array[index], index, array);
2157
- }
2158
- return accumulator;
2159
- }
2160
-
2161
- var _arrayReduce = arrayReduce;
2162
-
2163
- /**
2164
- * The base implementation of `_.propertyOf` without support for deep paths.
2165
- *
2166
- * @private
2167
- * @param {Object} object The object to query.
2168
- * @returns {Function} Returns the new accessor function.
2169
- */
2170
- function basePropertyOf(object) {
2171
- return function(key) {
2172
- return object == null ? undefined : object[key];
2173
- };
2174
- }
2175
-
2176
- var _basePropertyOf = basePropertyOf;
2177
-
2178
- /** Used to map Latin Unicode letters to basic Latin letters. */
2179
- var deburredLetters = {
2180
- // Latin-1 Supplement block.
2181
- '\xc0': 'A', '\xc1': 'A', '\xc2': 'A', '\xc3': 'A', '\xc4': 'A', '\xc5': 'A',
2182
- '\xe0': 'a', '\xe1': 'a', '\xe2': 'a', '\xe3': 'a', '\xe4': 'a', '\xe5': 'a',
2183
- '\xc7': 'C', '\xe7': 'c',
2184
- '\xd0': 'D', '\xf0': 'd',
2185
- '\xc8': 'E', '\xc9': 'E', '\xca': 'E', '\xcb': 'E',
2186
- '\xe8': 'e', '\xe9': 'e', '\xea': 'e', '\xeb': 'e',
2187
- '\xcc': 'I', '\xcd': 'I', '\xce': 'I', '\xcf': 'I',
2188
- '\xec': 'i', '\xed': 'i', '\xee': 'i', '\xef': 'i',
2189
- '\xd1': 'N', '\xf1': 'n',
2190
- '\xd2': 'O', '\xd3': 'O', '\xd4': 'O', '\xd5': 'O', '\xd6': 'O', '\xd8': 'O',
2191
- '\xf2': 'o', '\xf3': 'o', '\xf4': 'o', '\xf5': 'o', '\xf6': 'o', '\xf8': 'o',
2192
- '\xd9': 'U', '\xda': 'U', '\xdb': 'U', '\xdc': 'U',
2193
- '\xf9': 'u', '\xfa': 'u', '\xfb': 'u', '\xfc': 'u',
2194
- '\xdd': 'Y', '\xfd': 'y', '\xff': 'y',
2195
- '\xc6': 'Ae', '\xe6': 'ae',
2196
- '\xde': 'Th', '\xfe': 'th',
2197
- '\xdf': 'ss',
2198
- // Latin Extended-A block.
2199
- '\u0100': 'A', '\u0102': 'A', '\u0104': 'A',
2200
- '\u0101': 'a', '\u0103': 'a', '\u0105': 'a',
2201
- '\u0106': 'C', '\u0108': 'C', '\u010a': 'C', '\u010c': 'C',
2202
- '\u0107': 'c', '\u0109': 'c', '\u010b': 'c', '\u010d': 'c',
2203
- '\u010e': 'D', '\u0110': 'D', '\u010f': 'd', '\u0111': 'd',
2204
- '\u0112': 'E', '\u0114': 'E', '\u0116': 'E', '\u0118': 'E', '\u011a': 'E',
2205
- '\u0113': 'e', '\u0115': 'e', '\u0117': 'e', '\u0119': 'e', '\u011b': 'e',
2206
- '\u011c': 'G', '\u011e': 'G', '\u0120': 'G', '\u0122': 'G',
2207
- '\u011d': 'g', '\u011f': 'g', '\u0121': 'g', '\u0123': 'g',
2208
- '\u0124': 'H', '\u0126': 'H', '\u0125': 'h', '\u0127': 'h',
2209
- '\u0128': 'I', '\u012a': 'I', '\u012c': 'I', '\u012e': 'I', '\u0130': 'I',
2210
- '\u0129': 'i', '\u012b': 'i', '\u012d': 'i', '\u012f': 'i', '\u0131': 'i',
2211
- '\u0134': 'J', '\u0135': 'j',
2212
- '\u0136': 'K', '\u0137': 'k', '\u0138': 'k',
2213
- '\u0139': 'L', '\u013b': 'L', '\u013d': 'L', '\u013f': 'L', '\u0141': 'L',
2214
- '\u013a': 'l', '\u013c': 'l', '\u013e': 'l', '\u0140': 'l', '\u0142': 'l',
2215
- '\u0143': 'N', '\u0145': 'N', '\u0147': 'N', '\u014a': 'N',
2216
- '\u0144': 'n', '\u0146': 'n', '\u0148': 'n', '\u014b': 'n',
2217
- '\u014c': 'O', '\u014e': 'O', '\u0150': 'O',
2218
- '\u014d': 'o', '\u014f': 'o', '\u0151': 'o',
2219
- '\u0154': 'R', '\u0156': 'R', '\u0158': 'R',
2220
- '\u0155': 'r', '\u0157': 'r', '\u0159': 'r',
2221
- '\u015a': 'S', '\u015c': 'S', '\u015e': 'S', '\u0160': 'S',
2222
- '\u015b': 's', '\u015d': 's', '\u015f': 's', '\u0161': 's',
2223
- '\u0162': 'T', '\u0164': 'T', '\u0166': 'T',
2224
- '\u0163': 't', '\u0165': 't', '\u0167': 't',
2225
- '\u0168': 'U', '\u016a': 'U', '\u016c': 'U', '\u016e': 'U', '\u0170': 'U', '\u0172': 'U',
2226
- '\u0169': 'u', '\u016b': 'u', '\u016d': 'u', '\u016f': 'u', '\u0171': 'u', '\u0173': 'u',
2227
- '\u0174': 'W', '\u0175': 'w',
2228
- '\u0176': 'Y', '\u0177': 'y', '\u0178': 'Y',
2229
- '\u0179': 'Z', '\u017b': 'Z', '\u017d': 'Z',
2230
- '\u017a': 'z', '\u017c': 'z', '\u017e': 'z',
2231
- '\u0132': 'IJ', '\u0133': 'ij',
2232
- '\u0152': 'Oe', '\u0153': 'oe',
2233
- '\u0149': "'n", '\u017f': 's'
2234
- };
2235
-
2236
- /**
2237
- * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A
2238
- * letters to basic Latin letters.
2239
- *
2240
- * @private
2241
- * @param {string} letter The matched letter to deburr.
2242
- * @returns {string} Returns the deburred letter.
2243
- */
2244
- var deburrLetter = _basePropertyOf(deburredLetters);
2245
-
2246
- var _deburrLetter = deburrLetter;
2247
-
2248
- /** Used to match Latin Unicode letters (excluding mathematical operators). */
2249
- var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g;
2250
-
2251
- /** Used to compose unicode character classes. */
2252
- var rsComboMarksRange$1 = '\\u0300-\\u036f',
2253
- reComboHalfMarksRange$1 = '\\ufe20-\\ufe2f',
2254
- rsComboSymbolsRange$1 = '\\u20d0-\\u20ff',
2255
- rsComboRange$1 = rsComboMarksRange$1 + reComboHalfMarksRange$1 + rsComboSymbolsRange$1;
2256
-
2257
- /** Used to compose unicode capture groups. */
2258
- var rsCombo$1 = '[' + rsComboRange$1 + ']';
2259
-
2260
- /**
2261
- * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and
2262
- * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).
2263
- */
2264
- var reComboMark = RegExp(rsCombo$1, 'g');
2265
-
2266
- /**
2267
- * Deburrs `string` by converting
2268
- * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)
2269
- * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)
2270
- * letters to basic Latin letters and removing
2271
- * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).
2272
- *
2273
- * @static
2274
- * @memberOf _
2275
- * @since 3.0.0
2276
- * @category String
2277
- * @param {string} [string=''] The string to deburr.
2278
- * @returns {string} Returns the deburred string.
2279
- * @example
2280
- *
2281
- * _.deburr('déjà vu');
2282
- * // => 'deja vu'
2283
- */
2284
- function deburr(string) {
2285
- string = toString_1(string);
2286
- return string && string.replace(reLatin, _deburrLetter).replace(reComboMark, '');
2287
- }
2288
-
2289
- var deburr_1 = deburr;
2290
-
2291
- /** Used to match words composed of alphanumeric characters. */
2292
- var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
2293
-
2294
- /**
2295
- * Splits an ASCII `string` into an array of its words.
2296
- *
2297
- * @private
2298
- * @param {string} The string to inspect.
2299
- * @returns {Array} Returns the words of `string`.
2300
- */
2301
- function asciiWords(string) {
2302
- return string.match(reAsciiWord) || [];
2303
- }
2304
-
2305
- var _asciiWords = asciiWords;
2306
-
2307
- /** Used to detect strings that need a more robust regexp to match words. */
2308
- var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
2309
-
2310
- /**
2311
- * Checks if `string` contains a word composed of Unicode symbols.
2312
- *
2313
- * @private
2314
- * @param {string} string The string to inspect.
2315
- * @returns {boolean} Returns `true` if a word is found, else `false`.
2316
- */
2317
- function hasUnicodeWord(string) {
2318
- return reHasUnicodeWord.test(string);
2319
- }
2320
-
2321
- var _hasUnicodeWord = hasUnicodeWord;
2322
-
2323
- /** Used to compose unicode character classes. */
2324
- var rsAstralRange = '\\ud800-\\udfff',
2325
- rsComboMarksRange = '\\u0300-\\u036f',
2326
- reComboHalfMarksRange = '\\ufe20-\\ufe2f',
2327
- rsComboSymbolsRange = '\\u20d0-\\u20ff',
2328
- rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,
2329
- rsDingbatRange = '\\u2700-\\u27bf',
2330
- rsLowerRange = 'a-z\\xdf-\\xf6\\xf8-\\xff',
2331
- rsMathOpRange = '\\xac\\xb1\\xd7\\xf7',
2332
- rsNonCharRange = '\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf',
2333
- rsPunctuationRange = '\\u2000-\\u206f',
2334
- rsSpaceRange = ' \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000',
2335
- rsUpperRange = 'A-Z\\xc0-\\xd6\\xd8-\\xde',
2336
- rsVarRange = '\\ufe0e\\ufe0f',
2337
- rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;
2338
-
2339
- /** Used to compose unicode capture groups. */
2340
- var rsApos$1 = "['\u2019]",
2341
- rsBreak = '[' + rsBreakRange + ']',
2342
- rsCombo = '[' + rsComboRange + ']',
2343
- rsDigits = '\\d+',
2344
- rsDingbat = '[' + rsDingbatRange + ']',
2345
- rsLower = '[' + rsLowerRange + ']',
2346
- rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',
2347
- rsFitz = '\\ud83c[\\udffb-\\udfff]',
2348
- rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',
2349
- rsNonAstral = '[^' + rsAstralRange + ']',
2350
- rsRegional = '(?:\\ud83c[\\udde6-\\uddff]){2}',
2351
- rsSurrPair = '[\\ud800-\\udbff][\\udc00-\\udfff]',
2352
- rsUpper = '[' + rsUpperRange + ']',
2353
- rsZWJ = '\\u200d';
2354
-
2355
- /** Used to compose unicode regexes. */
2356
- var rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',
2357
- rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',
2358
- rsOptContrLower = '(?:' + rsApos$1 + '(?:d|ll|m|re|s|t|ve))?',
2359
- rsOptContrUpper = '(?:' + rsApos$1 + '(?:D|LL|M|RE|S|T|VE))?',
2360
- reOptMod = rsModifier + '?',
2361
- rsOptVar = '[' + rsVarRange + ']?',
2362
- rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',
2363
- rsOrdLower = '\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])',
2364
- rsOrdUpper = '\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])',
2365
- rsSeq = rsOptVar + reOptMod + rsOptJoin,
2366
- rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;
2367
-
2368
- /** Used to match complex or compound words. */
2369
- var reUnicodeWord = RegExp([
2370
- rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',
2371
- rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',
2372
- rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,
2373
- rsUpper + '+' + rsOptContrUpper,
2374
- rsOrdUpper,
2375
- rsOrdLower,
2376
- rsDigits,
2377
- rsEmoji
2378
- ].join('|'), 'g');
2379
-
2380
- /**
2381
- * Splits a Unicode `string` into an array of its words.
2382
- *
2383
- * @private
2384
- * @param {string} The string to inspect.
2385
- * @returns {Array} Returns the words of `string`.
2386
- */
2387
- function unicodeWords(string) {
2388
- return string.match(reUnicodeWord) || [];
2389
- }
2390
-
2391
- var _unicodeWords = unicodeWords;
2392
-
2393
- /**
2394
- * Splits `string` into an array of its words.
2395
- *
2396
- * @static
2397
- * @memberOf _
2398
- * @since 3.0.0
2399
- * @category String
2400
- * @param {string} [string=''] The string to inspect.
2401
- * @param {RegExp|string} [pattern] The pattern to match words.
2402
- * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
2403
- * @returns {Array} Returns the words of `string`.
2404
- * @example
2405
- *
2406
- * _.words('fred, barney, & pebbles');
2407
- * // => ['fred', 'barney', 'pebbles']
2408
- *
2409
- * _.words('fred, barney, & pebbles', /[^, ]+/g);
2410
- * // => ['fred', 'barney', '&', 'pebbles']
2411
- */
2412
- function words(string, pattern, guard) {
2413
- string = toString_1(string);
2414
- pattern = guard ? undefined : pattern;
2415
-
2416
- if (pattern === undefined) {
2417
- return _hasUnicodeWord(string) ? _unicodeWords(string) : _asciiWords(string);
2418
- }
2419
- return string.match(pattern) || [];
2420
- }
2421
-
2422
- var words_1 = words;
2423
-
2424
- /** Used to compose unicode capture groups. */
2425
- var rsApos = "['\u2019]";
2426
-
2427
- /** Used to match apostrophes. */
2428
- var reApos = RegExp(rsApos, 'g');
2429
-
2430
- /**
2431
- * Creates a function like `_.camelCase`.
2432
- *
2433
- * @private
2434
- * @param {Function} callback The function to combine each word.
2435
- * @returns {Function} Returns the new compounder function.
2436
- */
2437
- function createCompounder(callback) {
2438
- return function(string) {
2439
- return _arrayReduce(words_1(deburr_1(string).replace(reApos, '')), callback, '');
2440
- };
2441
- }
2442
-
2443
- var _createCompounder = createCompounder;
2444
-
2445
- /**
2446
- * Converts `string`, as space separated words, to upper case.
2447
- *
2448
- * @static
2449
- * @memberOf _
2450
- * @since 4.0.0
2451
- * @category String
2452
- * @param {string} [string=''] The string to convert.
2453
- * @returns {string} Returns the upper cased string.
2454
- * @example
2455
- *
2456
- * _.upperCase('--foo-bar');
2457
- * // => 'FOO BAR'
2458
- *
2459
- * _.upperCase('fooBar');
2460
- * // => 'FOO BAR'
2461
- *
2462
- * _.upperCase('__foo_bar__');
2463
- * // => 'FOO BAR'
2464
- */
2465
- var upperCase = _createCompounder(function(result, word, index) {
2466
- return result + (index ? ' ' : '') + word.toUpperCase();
2467
- });
2468
-
2469
- var upperCase_1 = upperCase;
2470
-
2471
- /**
2472
- * Converts `string`, as space separated words, to lower case.
2473
- *
2474
- * @static
2475
- * @memberOf _
2476
- * @since 4.0.0
2477
- * @category String
2478
- * @param {string} [string=''] The string to convert.
2479
- * @returns {string} Returns the lower cased string.
2480
- * @example
2481
- *
2482
- * _.lowerCase('--Foo-Bar--');
2483
- * // => 'foo bar'
2484
- *
2485
- * _.lowerCase('fooBar');
2486
- * // => 'foo bar'
2487
- *
2488
- * _.lowerCase('__FOO_BAR__');
2489
- * // => 'foo bar'
2490
- */
2491
- var lowerCase = _createCompounder(function(result, word, index) {
2492
- return result + (index ? ' ' : '') + word.toLowerCase();
2493
- });
2494
-
2495
- var lowerCase_1 = lowerCase;
62
+ return React.useContext(StateContext);
63
+ };
2496
64
 
2497
65
  var timestampToFormat = function timestampToFormat(value, unit, suffix, timestamp) {
2498
66
  var config = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};
@@ -2513,7 +81,7 @@ var timestampToFormat = function timestampToFormat(value, unit, suffix, timestam
2513
81
  var localizedMonth = month;
2514
82
 
2515
83
  if (isUpperCase) {
2516
- localizedMonth = upperCase_1(month);
84
+ localizedMonth = lodash.upperCase(month);
2517
85
  }
2518
86
 
2519
87
  var year = dateTime.getFullYear();
@@ -2526,7 +94,7 @@ var timestampToFormat = function timestampToFormat(value, unit, suffix, timestam
2526
94
  var timetoShow;
2527
95
 
2528
96
  if (localizedMonths) {
2529
- localizedMonth = get_1(localizedMonths, [lowerCase_1(month)]) || month;
97
+ localizedMonth = lodash.get(localizedMonths, [lodash.lowerCase(month)]) || month;
2530
98
  }
2531
99
 
2532
100
  if (localizedMeridiem) {
@@ -2556,17 +124,17 @@ function formatter(value, unit, suffix, date, config) {
2556
124
  var showDateForUnits = ["day", "week", "month", "year"]; // suffix here refers to ago
2557
125
  // unit here refers to seconds, minute, minutes,...
2558
126
 
2559
- var localizedSuffix = get_1(config, ["localizedPublishTime", suffix]) || suffix;
127
+ var localizedSuffix = lodash.get(config, ["localizedPublishTime", suffix]) || suffix;
2560
128
  var localizedUnitOfTime;
2561
129
 
2562
130
  if (unit === "hour" && value > 23 || showDateForUnits.indexOf(unit) !== -1) {
2563
131
  return timestampToFormat(value, unit, suffix, date, config);
2564
132
  } else if (value > 1) {
2565
- localizedUnitOfTime = get_1(config, ["localizedPublishTime", "".concat(unit, "s")]) || "".concat(unit, "s");
133
+ localizedUnitOfTime = lodash.get(config, ["localizedPublishTime", "".concat(unit, "s")]) || "".concat(unit, "s");
2566
134
  return "".concat(value, " ").concat(localizedUnitOfTime, " ").concat(localizedSuffix);
2567
135
  }
2568
136
 
2569
- localizedUnitOfTime = get_1(config, ["localizedPublishTime", unit]) || unit;
137
+ localizedUnitOfTime = lodash.get(config, ["localizedPublishTime", unit]) || unit;
2570
138
  return "".concat(value, " ").concat(localizedUnitOfTime, " ").concat(localizedSuffix, " ");
2571
139
  }
2572
140
 
@@ -2619,10 +187,10 @@ var clientWidths = {
2619
187
  tablet: 1024
2620
188
  };
2621
189
  var clientWidth = function clientWidth(device) {
2622
- var foundDeviceWidth = get_1(clientWidths, device);
190
+ var foundDeviceWidth = lodash.get(clientWidths, device);
2623
191
 
2624
192
  if (foundDeviceWidth) {
2625
- return get_1(global, "document.documentElement.clientWidth") <= foundDeviceWidth;
193
+ return lodash.get(global, "document.documentElement.clientWidth") <= foundDeviceWidth;
2626
194
  }
2627
195
 
2628
196
  return false;
@@ -2664,7 +232,7 @@ var getSlug = function getSlug(collection) {
2664
232
  var isSection = collection.template === "section";
2665
233
 
2666
234
  if (isSection) {
2667
- var sectionId = get_1(collection, ["metadata", "section", "0", "id"], "");
235
+ var sectionId = lodash.get(collection, ["metadata", "section", "0", "id"], "");
2668
236
  var sections = config.sections;
2669
237
  var section = sections && sections.find(function (section) {
2670
238
  return section.id === sectionId;
@@ -2680,21 +248,21 @@ function isExternalStory() {
2680
248
  storyTemplate = _story$storyTemplate === void 0 ? "" : _story$storyTemplate,
2681
249
  _story$metadata = story.metadata,
2682
250
  metadata = _story$metadata === void 0 ? {} : _story$metadata;
2683
- return storyTemplate === "news-elsewhere" ? get_1(metadata, ["reference-url"], "") : "";
251
+ return storyTemplate === "news-elsewhere" ? lodash.get(metadata, ["reference-url"], "") : "";
2684
252
  } // Adds target='_blank' attribute to anchor tags if not present
2685
- PropTypes.shape({
2686
- "sketches-host": PropTypes.string,
2687
- "cdn-name": PropTypes.string,
2688
- "cdn-image": PropTypes.string
253
+ PropTypes__default["default"].shape({
254
+ "sketches-host": PropTypes__default["default"].string,
255
+ "cdn-name": PropTypes__default["default"].string,
256
+ "cdn-image": PropTypes__default["default"].string
2689
257
  });
2690
- PropTypes.shape({
2691
- headline: PropTypes.string,
2692
- "last-published-at": PropTypes.number,
2693
- subheadline: PropTypes.string
258
+ PropTypes__default["default"].shape({
259
+ headline: PropTypes__default["default"].string,
260
+ "last-published-at": PropTypes__default["default"].number,
261
+ subheadline: PropTypes__default["default"].string
2694
262
  });
2695
263
  var getStoryUrl = function getStoryUrl(story) {
2696
264
  var defaultValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "";
2697
- return get_1(story, ["story-template"]) === "news-elsewhere" ? get_1(story, ["metadata", "reference-url"], "") : story.url || defaultValue;
265
+ return lodash.get(story, ["story-template"]) === "news-elsewhere" ? lodash.get(story, ["metadata", "reference-url"], "") : story.url || defaultValue;
2698
266
  };
2699
267
  var navigateTo = function navigateTo(dispatch) {
2700
268
  var url = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "";
@@ -2734,17 +302,17 @@ var getTimeStamp = function getTimeStamp(date, _formatter) {
2734
302
  var timezone = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : null;
2735
303
 
2736
304
  if (timezone && template === "story") {
2737
- var zonedTime = timezone && utcToZonedTime(date, timezone);
2738
- var formatZonedTime = zonedTime && format(zonedTime, "yyyy-MM-dd'T'HH:mm:ssXXX", {
305
+ var zonedTime = timezone && dateFnsTz.utcToZonedTime(date, timezone);
306
+ var formatZonedTime = zonedTime && dateFnsTz.format(zonedTime, "yyyy-MM-dd'T'HH:mm:ssXXX", {
2739
307
  timeZone: timezone
2740
308
  });
2741
309
  var timeStamp = timestampToFormat("", "", "", date, config);
2742
- return /*#__PURE__*/React.createElement("time", {
310
+ return /*#__PURE__*/React__default["default"].createElement("time", {
2743
311
  dateTime: formatZonedTime
2744
312
  }, timeStamp);
2745
313
  }
2746
314
 
2747
- return /*#__PURE__*/React.createElement(Timeago, {
315
+ return /*#__PURE__*/React__default["default"].createElement(Timeago__default["default"], {
2748
316
  date: date,
2749
317
  formatter: function formatter(value, unit, suffix, date) {
2750
318
  return _formatter(value, unit, suffix, date, config);
@@ -2775,9 +343,9 @@ var AuthorBase = function AuthorBase(_ref) {
2775
343
  _ref$config = _ref.config,
2776
344
  config = _ref$config === void 0 ? {} : _ref$config;
2777
345
  var configData = useStateValue() || {};
2778
- var isAuthor = get_1(configData, ["showAuthor"], true);
346
+ var isAuthor = lodash.get(configData, ["showAuthor"], true);
2779
347
 
2780
- var _get = get_1(story, ["authors", "0"], ""),
348
+ var _get = lodash.get(story, ["authors", "0"], ""),
2781
349
  avatarUrl = _get["avatar-url"],
2782
350
  avatarS3Key = _get["avatar-s3-key"],
2783
351
  authorName = _get.name,
@@ -2785,17 +353,17 @@ var AuthorBase = function AuthorBase(_ref) {
2785
353
 
2786
354
  var isBottomClasses = isBottom ? "bottom-fix" : "";
2787
355
  var textColor = getTextColor(configData.theme);
2788
- var mountAt = get_1(config, ["mountAt"], "");
356
+ var mountAt = lodash.get(config, ["mountAt"], "");
2789
357
 
2790
358
  var authorImage = function authorImage(dir) {
2791
359
  if (!avatarUrl && !avatarS3Key) {
2792
360
  return null;
2793
361
  }
2794
362
 
2795
- return /*#__PURE__*/React.createElement("div", {
363
+ return /*#__PURE__*/React__default["default"].createElement("div", {
2796
364
  "data-test-id": "author-image",
2797
- className: _getClassName("author-image ".concat(dir, "-image"), _styleModuleImportMap$a)
2798
- }, /*#__PURE__*/React.createElement("figure", null, avatarS3Key ? /*#__PURE__*/React.createElement(ResponsiveImage, {
365
+ className: _getClassName__default["default"]("author-image ".concat(dir, "-image"), _styleModuleImportMap$a)
366
+ }, /*#__PURE__*/React__default["default"].createElement("figure", null, avatarS3Key ? /*#__PURE__*/React__default["default"].createElement(components.ResponsiveImage, {
2799
367
  slug: avatarS3Key,
2800
368
  "aspect-ratio": [1, 1],
2801
369
  defaultWidth: 400,
@@ -2803,49 +371,49 @@ var AuthorBase = function AuthorBase(_ref) {
2803
371
  auto: ["format", "compress"]
2804
372
  },
2805
373
  alt: authorName
2806
- }) : /*#__PURE__*/React.createElement("img", {
374
+ }) : /*#__PURE__*/React__default["default"].createElement("img", {
2807
375
  src: avatarUrl
2808
376
  })));
2809
377
  };
2810
378
 
2811
379
  var isPrefix = function isPrefix(dir) {
2812
380
  if (prefix) {
2813
- return /*#__PURE__*/React.createElement("div", {
2814
- className: "arr-author-prefix " + _getClassName("prefix ".concat(textColor), _styleModuleImportMap$a)
381
+ return /*#__PURE__*/React__default["default"].createElement("div", {
382
+ className: "arr-author-prefix " + _getClassName__default["default"]("prefix ".concat(textColor), _styleModuleImportMap$a)
2815
383
  }, prefix);
2816
384
  }
2817
385
 
2818
386
  return !hideAuthorImage && authorImage(dir);
2819
387
  };
2820
388
 
2821
- return /*#__PURE__*/React.createElement(React.Fragment, null, isAuthor && /*#__PURE__*/React.createElement(Link, {
389
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isAuthor && /*#__PURE__*/React__default["default"].createElement(components.Link, {
2822
390
  href: "".concat(mountAt, "/author/") + slug,
2823
391
  "aria-label": "author-name",
2824
- className: "author-name arr-author-name arrow-component " + _getClassName("author ".concat(isBottomClasses), _styleModuleImportMap$a)
2825
- }, isPrefix("ltr"), /*#__PURE__*/React.createElement("div", {
392
+ className: "author-name arr-author-name arrow-component " + _getClassName__default["default"]("author ".concat(isBottomClasses), _styleModuleImportMap$a)
393
+ }, isPrefix("ltr"), /*#__PURE__*/React__default["default"].createElement("div", {
2826
394
  "data-test-id": "author-name",
2827
- className: "author-name " + _getClassName("author-name ".concat(textColor), _styleModuleImportMap$a)
395
+ className: "author-name " + _getClassName__default["default"]("author-name ".concat(textColor), _styleModuleImportMap$a)
2828
396
  }, authorName || story["author-name"]), !prefix && isPrefix("rtl")));
2829
397
  };
2830
398
 
2831
399
  function mapStateToProps$1(state) {
2832
400
  return {
2833
- config: get_1(state, ["qt", "config"], {})
401
+ config: lodash.get(state, ["qt", "config"], {})
2834
402
  };
2835
403
  }
2836
404
 
2837
- var Author = connect(mapStateToProps$1)(AuthorBase);
405
+ var Author = reactRedux.connect(mapStateToProps$1)(AuthorBase);
2838
406
  AuthorBase.propTypes = {
2839
407
  /** The Story Object from the API response */
2840
- story: PropTypes.object.isRequired,
408
+ story: PropTypes__default["default"].object.isRequired,
2841
409
 
2842
410
  /** Hide Author Avatar Image */
2843
- hideAuthorImage: PropTypes.bool,
411
+ hideAuthorImage: PropTypes__default["default"].bool,
2844
412
  // fix Author bottom of the storyCard
2845
- isBottom: PropTypes.bool,
413
+ isBottom: PropTypes__default["default"].bool,
2846
414
  // fix prefix before the author name
2847
- prefix: PropTypes.string,
2848
- config: PropTypes.object
415
+ prefix: PropTypes__default["default"].string,
416
+ config: PropTypes__default["default"].object
2849
417
  };
2850
418
  AuthorBase.defaultProps = {
2851
419
  hideAuthorImage: false,
@@ -2859,7 +427,7 @@ var CrownIcon = function CrownIcon(_ref) {
2859
427
  _ref$color = _ref.color,
2860
428
  color = _ref$color === void 0 ? "#D8D8D8" : _ref$color,
2861
429
  positionTop = _ref.positionTop;
2862
- return /*#__PURE__*/React.createElement("svg", {
430
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
2863
431
  xmlns: "http://www.w3.org/2000/svg",
2864
432
  width: width,
2865
433
  height: height,
@@ -2868,28 +436,28 @@ var CrownIcon = function CrownIcon(_ref) {
2868
436
  position: "relative",
2869
437
  top: positionTop
2870
438
  }
2871
- }, /*#__PURE__*/React.createElement("g", {
439
+ }, /*#__PURE__*/React__default["default"].createElement("g", {
2872
440
  fill: "none",
2873
441
  fillRule: "evenodd",
2874
442
  stroke: "none",
2875
443
  strokeWidth: "1"
2876
- }, /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("g", {
444
+ }, /*#__PURE__*/React__default["default"].createElement("g", null, /*#__PURE__*/React__default["default"].createElement("g", {
2877
445
  transform: "translate(8 8)"
2878
- }, /*#__PURE__*/React.createElement("path", {
446
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
2879
447
  d: "M0 0H24V24H0z"
2880
- }), /*#__PURE__*/React.createElement("g", {
448
+ }), /*#__PURE__*/React__default["default"].createElement("g", {
2881
449
  fill: color,
2882
450
  fillRule: "nonzero",
2883
451
  transform: "translate(0 2)"
2884
- }, /*#__PURE__*/React.createElement("path", {
452
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
2885
453
  d: "M21.043 19.553c0-.743-.601-1.344-1.344-1.344h-15.4a1.343 1.343 0 100 2.688h15.4c.743 0 1.344-.603 1.344-1.344zM1.598 8.673c.022 0 .042 0 .064-.003l2.131 7.713h16.411l2.132-7.713c.022 0 .041.003.063.003a1.599 1.599 0 10-1.52-1.108L17.025 9.82 12.882 2.95a1.599 1.599 0 10-1.765 0L6.976 9.82 3.121 7.565a1.599 1.599 0 10-1.523 1.107z"
2886
454
  }))))));
2887
455
  };
2888
456
  CrownIcon.propTypes = {
2889
- height: PropTypes.string,
2890
- width: PropTypes.string,
2891
- color: PropTypes.string,
2892
- positionTop: PropTypes.string
457
+ height: PropTypes__default["default"].string,
458
+ width: PropTypes__default["default"].string,
459
+ color: PropTypes__default["default"].string,
460
+ positionTop: PropTypes__default["default"].string
2893
461
  };
2894
462
 
2895
463
  var KeyIcon = function KeyIcon(_ref) {
@@ -2898,7 +466,7 @@ var KeyIcon = function KeyIcon(_ref) {
2898
466
  _ref$color = _ref.color,
2899
467
  color = _ref$color === void 0 ? "#D5D5D5" : _ref$color,
2900
468
  positionTop = _ref.positionTop;
2901
- return /*#__PURE__*/React.createElement("svg", {
469
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
2902
470
  xmlns: "http://www.w3.org/2000/svg",
2903
471
  width: width,
2904
472
  height: height,
@@ -2907,16 +475,16 @@ var KeyIcon = function KeyIcon(_ref) {
2907
475
  position: "relative",
2908
476
  top: positionTop
2909
477
  }
2910
- }, /*#__PURE__*/React.createElement("g", {
478
+ }, /*#__PURE__*/React__default["default"].createElement("g", {
2911
479
  fill: "none",
2912
480
  fillRule: "evenodd",
2913
481
  stroke: "none",
2914
482
  strokeWidth: "1"
2915
- }, /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("g", {
483
+ }, /*#__PURE__*/React__default["default"].createElement("g", null, /*#__PURE__*/React__default["default"].createElement("g", {
2916
484
  transform: "translate(8 8)"
2917
- }, /*#__PURE__*/React.createElement("path", {
485
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
2918
486
  d: "M0 0H24V24H0z"
2919
- }), /*#__PURE__*/React.createElement("path", {
487
+ }), /*#__PURE__*/React__default["default"].createElement("path", {
2920
488
  fill: color,
2921
489
  fillRule: "nonzero",
2922
490
  d: "M12.71 4.364A6.54 6.54 0 000 6.545a6.54 6.54 0 0012.71 2.182h4.745v4.364h4.363V8.727H24V4.364H12.71zM6.544 8.727a2.181 2.181 0 110-4.362 2.181 2.181 0 010 4.362z",
@@ -2924,10 +492,10 @@ var KeyIcon = function KeyIcon(_ref) {
2924
492
  })))));
2925
493
  };
2926
494
  KeyIcon.propTypes = {
2927
- height: PropTypes.string,
2928
- width: PropTypes.string,
2929
- color: PropTypes.string,
2930
- positionTop: PropTypes.string
495
+ height: PropTypes__default["default"].string,
496
+ width: PropTypes__default["default"].string,
497
+ color: PropTypes__default["default"].string,
498
+ positionTop: PropTypes__default["default"].string
2931
499
  };
2932
500
 
2933
501
  var LockIcon = function LockIcon(_ref) {
@@ -2936,7 +504,7 @@ var LockIcon = function LockIcon(_ref) {
2936
504
  _ref$color = _ref.color,
2937
505
  color = _ref$color === void 0 ? "#D5D5D5" : _ref$color,
2938
506
  positionTop = _ref.positionTop;
2939
- return /*#__PURE__*/React.createElement("svg", {
507
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
2940
508
  xmlns: "http://www.w3.org/2000/svg",
2941
509
  width: width,
2942
510
  height: height,
@@ -2945,28 +513,28 @@ var LockIcon = function LockIcon(_ref) {
2945
513
  position: "relative",
2946
514
  top: positionTop
2947
515
  }
2948
- }, /*#__PURE__*/React.createElement("g", {
516
+ }, /*#__PURE__*/React__default["default"].createElement("g", {
2949
517
  fill: "none",
2950
518
  fillRule: "evenodd",
2951
519
  stroke: "none",
2952
520
  strokeWidth: "1"
2953
- }, /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("g", {
521
+ }, /*#__PURE__*/React__default["default"].createElement("g", null, /*#__PURE__*/React__default["default"].createElement("g", {
2954
522
  transform: "translate(8 8)"
2955
- }, /*#__PURE__*/React.createElement("path", {
523
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
2956
524
  d: "M0 0H24V24H0z"
2957
- }), /*#__PURE__*/React.createElement("g", {
525
+ }), /*#__PURE__*/React__default["default"].createElement("g", {
2958
526
  fill: color,
2959
527
  fillRule: "nonzero",
2960
528
  transform: "translate(3)"
2961
- }, /*#__PURE__*/React.createElement("path", {
529
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
2962
530
  d: "M15.692 9h-.747V6c0-3.31-2.681-6-5.978-6C5.67 0 2.989 2.69 2.989 6v3h-.747A2.249 2.249 0 000 11.25v10.5A2.249 2.249 0 002.242 24h13.45a2.249 2.249 0 002.242-2.25v-10.5A2.249 2.249 0 0015.692 9zM4.982 6c0-2.206 1.787-4 3.985-4s3.985 1.794 3.985 4v3h-7.97V6z"
2963
531
  }))))));
2964
532
  };
2965
533
  LockIcon.propTypes = {
2966
- height: PropTypes.string,
2967
- width: PropTypes.string,
2968
- color: PropTypes.string,
2969
- positionTop: PropTypes.string
534
+ height: PropTypes__default["default"].string,
535
+ width: PropTypes__default["default"].string,
536
+ color: PropTypes__default["default"].string,
537
+ positionTop: PropTypes__default["default"].string
2970
538
  };
2971
539
 
2972
540
  var StarIcon = function StarIcon(_ref) {
@@ -2976,7 +544,7 @@ var StarIcon = function StarIcon(_ref) {
2976
544
  color = _ref$color === void 0 ? "#D5D5D5" : _ref$color,
2977
545
  _ref$positionTop = _ref.positionTop,
2978
546
  positionTop = _ref$positionTop === void 0 ? "" : _ref$positionTop;
2979
- return /*#__PURE__*/React.createElement("svg", {
547
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
2980
548
  xmlns: "http://www.w3.org/2000/svg",
2981
549
  width: width,
2982
550
  height: height,
@@ -2985,21 +553,21 @@ var StarIcon = function StarIcon(_ref) {
2985
553
  position: "relative",
2986
554
  top: positionTop
2987
555
  }
2988
- }, /*#__PURE__*/React.createElement("g", {
556
+ }, /*#__PURE__*/React__default["default"].createElement("g", {
2989
557
  fill: "none",
2990
558
  fillRule: "evenodd",
2991
559
  stroke: "none",
2992
560
  strokeWidth: "1"
2993
- }, /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("path", {
561
+ }, /*#__PURE__*/React__default["default"].createElement("g", null, /*#__PURE__*/React__default["default"].createElement("path", {
2994
562
  fill: color,
2995
563
  d: "M20 26L12.946577 29.7082039 14.2936609 21.854102 8.5873218 16.2917961 16.4732885 15.145898 20 8 23.5267115 15.145898 31.4126782 16.2917961 25.7063391 21.854102 27.053423 29.7082039z"
2996
564
  }))));
2997
565
  };
2998
566
  StarIcon.propTypes = {
2999
- height: PropTypes.string,
3000
- width: PropTypes.string,
3001
- color: PropTypes.string,
3002
- positionTop: PropTypes.string
567
+ height: PropTypes__default["default"].string,
568
+ width: PropTypes__default["default"].string,
569
+ color: PropTypes__default["default"].string,
570
+ positionTop: PropTypes__default["default"].string
3003
571
  };
3004
572
 
3005
573
  var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
@@ -3011,7 +579,7 @@ var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
3011
579
 
3012
580
  switch (iconType) {
3013
581
  case "crown":
3014
- return /*#__PURE__*/React.createElement(CrownIcon, {
582
+ return /*#__PURE__*/React__default["default"].createElement(CrownIcon, {
3015
583
  width: width,
3016
584
  height: height,
3017
585
  color: color,
@@ -3019,7 +587,7 @@ var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
3019
587
  });
3020
588
 
3021
589
  case "lock":
3022
- return /*#__PURE__*/React.createElement(LockIcon, {
590
+ return /*#__PURE__*/React__default["default"].createElement(LockIcon, {
3023
591
  width: width,
3024
592
  height: height,
3025
593
  color: color,
@@ -3027,7 +595,7 @@ var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
3027
595
  });
3028
596
 
3029
597
  case "key":
3030
- return /*#__PURE__*/React.createElement(KeyIcon, {
598
+ return /*#__PURE__*/React__default["default"].createElement(KeyIcon, {
3031
599
  width: width,
3032
600
  height: height,
3033
601
  color: color,
@@ -3035,7 +603,7 @@ var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
3035
603
  });
3036
604
 
3037
605
  default:
3038
- return /*#__PURE__*/React.createElement(StarIcon, {
606
+ return /*#__PURE__*/React__default["default"].createElement(StarIcon, {
3039
607
  width: width,
3040
608
  height: height,
3041
609
  color: color,
@@ -3044,21 +612,21 @@ var PremiumStoryIcon = function PremiumStoryIcon(_ref) {
3044
612
  }
3045
613
  };
3046
614
  PremiumStoryIcon.propTypes = {
3047
- width: PropTypes.string,
3048
- height: PropTypes.string,
3049
- color: PropTypes.string,
3050
- iconType: PropTypes.string,
3051
- positionTop: PropTypes.string
615
+ width: PropTypes__default["default"].string,
616
+ height: PropTypes__default["default"].string,
617
+ color: PropTypes__default["default"].string,
618
+ iconType: PropTypes__default["default"].string,
619
+ positionTop: PropTypes__default["default"].string
3052
620
  };
3053
621
 
3054
622
  function LiveIcon() {
3055
- return /*#__PURE__*/React.createElement("svg", {
623
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
3056
624
  className: "live-icon",
3057
625
  xmlns: "http://www.w3.org/2000/svg",
3058
626
  width: "25",
3059
627
  height: "24",
3060
628
  viewBox: "0 0 25 24"
3061
- }, /*#__PURE__*/React.createElement("path", {
629
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
3062
630
  fill: "#ff5858",
3063
631
  d: "M12 18a6 6 0 110-12 6 6 0 010 12zm0 2.5a8.5 8.5 0 110-17 8.5 8.5 0 010 17zm0-1a7.5 7.5 0 100-15 7.5 7.5 0 000 15z"
3064
632
  }));
@@ -3087,8 +655,8 @@ var Headline = function Headline(_ref) {
3087
655
  enablePremiumStoryIcon = _premiumStoryIconConf3 === void 0 ? false : _premiumStoryIconConf3,
3088
656
  _premiumStoryIconConf4 = premiumStoryIconConfig.showLiveIcon,
3089
657
  showLiveIcon = _premiumStoryIconConf4 === void 0 ? false : _premiumStoryIconConf4;
3090
- var alternateHeadline = get_1(story, ["alternative", "home", "default", "headline"]);
3091
- var premiumStory = enablePremiumStoryIcon && get_1(story, ["access"]) === "subscription";
658
+ var alternateHeadline = lodash.get(story, ["alternative", "home", "default", "headline"]);
659
+ var premiumStory = enablePremiumStoryIcon && lodash.get(story, ["access"]) === "subscription";
3092
660
  var headline = alternateHeadline || story.headline;
3093
661
  var HeaderTag = "h" + headerLevel;
3094
662
 
@@ -3114,38 +682,38 @@ var Headline = function Headline(_ref) {
3114
682
  var textColor = getTextColor(configData.theme);
3115
683
  var wrapperClass = premiumStory ? "wrapper" : "";
3116
684
  var iconSize = "24px";
3117
- var enableLiveIcon = showLiveIcon && story["story-template"] === "live-blog" && !get_1(story, ["metadata", "is-closed"], false);
3118
- return /*#__PURE__*/React.createElement("div", {
685
+ var enableLiveIcon = showLiveIcon && story["story-template"] === "live-blog" && !lodash.get(story, ["metadata", "is-closed"], false);
686
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3119
687
  "data-test-id": "headline",
3120
- className: "arrow-component arr--headline " + _getClassName(wrapperClass, _styleModuleImportMap$9)
3121
- }, premiumStory && /*#__PURE__*/React.createElement(PremiumStoryIcon, {
688
+ className: "arrow-component arr--headline " + _getClassName__default["default"](wrapperClass, _styleModuleImportMap$9)
689
+ }, premiumStory && /*#__PURE__*/React__default["default"].createElement(PremiumStoryIcon, {
3122
690
  width: iconSize,
3123
691
  height: iconSize,
3124
692
  color: iconColor,
3125
693
  iconType: iconStyle,
3126
694
  positionTop: positionHeadline()
3127
- }), isLink ? /*#__PURE__*/React.createElement(Link, {
695
+ }), isLink ? /*#__PURE__*/React__default["default"].createElement(components.Link, {
3128
696
  href: getStoryUrl(story, "/".concat(story.slug)),
3129
697
  externalLink: isExternalStory(story),
3130
698
  "aria-label": "headline"
3131
- }, /*#__PURE__*/React.createElement(HeaderTag, {
3132
- className: _getClassName("headline ".concat(textColor), _styleModuleImportMap$9)
3133
- }, enableLiveIcon && /*#__PURE__*/React.createElement(LiveIcon, null), headline)) : /*#__PURE__*/React.createElement(HeaderTag, {
3134
- className: _getClassName("headline ".concat(textColor), _styleModuleImportMap$9)
3135
- }, enableLiveIcon && /*#__PURE__*/React.createElement(LiveIcon, null), headline));
699
+ }, /*#__PURE__*/React__default["default"].createElement(HeaderTag, {
700
+ className: _getClassName__default["default"]("headline ".concat(textColor), _styleModuleImportMap$9)
701
+ }, enableLiveIcon && /*#__PURE__*/React__default["default"].createElement(LiveIcon, null), headline)) : /*#__PURE__*/React__default["default"].createElement(HeaderTag, {
702
+ className: _getClassName__default["default"]("headline ".concat(textColor), _styleModuleImportMap$9)
703
+ }, enableLiveIcon && /*#__PURE__*/React__default["default"].createElement(LiveIcon, null), headline));
3136
704
  };
3137
705
  Headline.propTypes = {
3138
706
  /** The Story Object from the API response */
3139
- story: PropTypes.object.isRequired,
707
+ story: PropTypes__default["default"].object.isRequired,
3140
708
 
3141
709
  /** Header tags ranging h1-h6, where h[headerLevel] */
3142
- headerLevel: PropTypes.string,
3143
- premiumStoryIconConfig: PropTypes.shape({
3144
- iconColor: PropTypes.string,
3145
- iconType: PropTypes.string,
3146
- enablePremiumStoryIcon: PropTypes.bool
710
+ headerLevel: PropTypes__default["default"].string,
711
+ premiumStoryIconConfig: PropTypes__default["default"].shape({
712
+ iconColor: PropTypes__default["default"].string,
713
+ iconType: PropTypes__default["default"].string,
714
+ enablePremiumStoryIcon: PropTypes__default["default"].bool
3147
715
  }),
3148
- isLink: PropTypes.bool
716
+ isLink: PropTypes__default["default"].bool
3149
717
  };
3150
718
  Headline.defaultProps = {
3151
719
  headerLevel: "6",
@@ -3157,20 +725,20 @@ var UserFallbackIcon = function UserFallbackIcon(_ref) {
3157
725
  width = _ref$width === void 0 ? 120 : _ref$width,
3158
726
  _ref$height = _ref.height,
3159
727
  height = _ref$height === void 0 ? 120 : _ref$height;
3160
- return /*#__PURE__*/React.createElement("svg", {
728
+ return /*#__PURE__*/React__default["default"].createElement("svg", {
3161
729
  width: width,
3162
730
  height: height,
3163
731
  viewBox: "0 0 120 120",
3164
732
  xmlns: "http://www.w3.org/2000/svg"
3165
- }, /*#__PURE__*/React.createElement("path", {
733
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
3166
734
  d: "M93.28 108.98c-1.055-17.675-15.47-31.678-33.098-31.678-17.708 0-32.173 14.129-33.11 31.916 9.415 6.311 20.741 9.993 32.927 9.993 12.338 0 23.795-3.774 33.28-10.23l.001-.001zM58.584 73.283c9.928 0 17.977-8.275 17.977-18.483 0-10.209-8.049-18.484-17.977-18.484-9.929 0-17.977 8.275-17.977 18.484 0 10.208 8.048 18.483 17.977 18.483zM60 120C26.863 120 0 93.137 0 60S26.863 0 60 0s60 26.863 60 60-26.863 60-60 60z",
3167
735
  fill: "#DADADA",
3168
736
  fillRule: "nonzero"
3169
737
  }));
3170
738
  };
3171
739
  UserFallbackIcon.propTypes = {
3172
- width: PropTypes.object,
3173
- height: PropTypes.object
740
+ width: PropTypes__default["default"].object,
741
+ height: PropTypes__default["default"].object
3174
742
  };
3175
743
 
3176
744
  var _styleModuleImportMap$8 = {
@@ -3190,12 +758,12 @@ var authorWithImage = function authorWithImage(author, templateStyle) {
3190
758
  var avatarUrl = author["avatar-url"],
3191
759
  avatarS3Key = author["avatar-s3-key"],
3192
760
  name = author.name;
3193
- return /*#__PURE__*/React.createElement("div", {
761
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3194
762
  "data-test-id": "author-image",
3195
- className: "arr--author-image " + _getClassName("author-image ".concat(templateStyle), _styleModuleImportMap$8)
3196
- }, /*#__PURE__*/React.createElement("figure", {
763
+ className: "arr--author-image " + _getClassName__default["default"]("author-image ".concat(templateStyle), _styleModuleImportMap$8)
764
+ }, /*#__PURE__*/React__default["default"].createElement("figure", {
3197
765
  className: "author-image-m_image-container__19WNd"
3198
- }, avatarS3Key ? /*#__PURE__*/React.createElement(ResponsiveImage, {
766
+ }, avatarS3Key ? /*#__PURE__*/React__default["default"].createElement(components.ResponsiveImage, {
3199
767
  slug: avatarS3Key,
3200
768
  alt: name,
3201
769
  defaultWidth: 250,
@@ -3205,9 +773,9 @@ var authorWithImage = function authorWithImage(author, templateStyle) {
3205
773
  imgParams: {
3206
774
  auto: ["format", "compress"]
3207
775
  }
3208
- }) : avatarUrl ? /*#__PURE__*/React.createElement("img", {
776
+ }) : avatarUrl ? /*#__PURE__*/React__default["default"].createElement("img", {
3209
777
  src: avatarUrl
3210
- }) : /*#__PURE__*/React.createElement(UserFallbackIcon, null)));
778
+ }) : /*#__PURE__*/React__default["default"].createElement(UserFallbackIcon, null)));
3211
779
  };
3212
780
 
3213
781
  var AuthorImage = function AuthorImage(_ref) {
@@ -3221,19 +789,19 @@ var AuthorImage = function AuthorImage(_ref) {
3221
789
  var mountAt = config.mountAt || "";
3222
790
  var templateStyle = "";
3223
791
  if (template === "smallerCircle") templateStyle = "smaller-circle";else if (template === "smallCircle") templateStyle = "small-circle";else if (template === "square") templateStyle = "square";
3224
- if (slug) return /*#__PURE__*/React.createElement(Link, {
792
+ if (slug) return /*#__PURE__*/React__default["default"].createElement(components.Link, {
3225
793
  href: "".concat(mountAt, "/author/") + slug
3226
794
  }, authorWithImage(author, templateStyle));else return authorWithImage(author, templateStyle);
3227
795
  };
3228
796
 
3229
797
  AuthorImage.propTypes = {
3230
- author: PropTypes.shape({
3231
- "avatar-url": PropTypes.string,
3232
- "avatar-s3-key": PropTypes.string,
3233
- name: PropTypes.string,
3234
- slug: PropTypes.string
798
+ author: PropTypes__default["default"].shape({
799
+ "avatar-url": PropTypes__default["default"].string,
800
+ "avatar-s3-key": PropTypes__default["default"].string,
801
+ name: PropTypes__default["default"].string,
802
+ slug: PropTypes__default["default"].string
3235
803
  }),
3236
- template: PropTypes.string
804
+ template: PropTypes__default["default"].string
3237
805
  };
3238
806
 
3239
807
  var LoadMoreTarget = function LoadMoreTarget(_ref) {
@@ -3241,7 +809,7 @@ var LoadMoreTarget = function LoadMoreTarget(_ref) {
3241
809
  componentName = _ref.componentName,
3242
810
  offset = _ref.offset,
3243
811
  limit = _ref.limit;
3244
- return /*#__PURE__*/React.createElement("div", {
812
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3245
813
  id: "ELM-".concat(collection.id),
3246
814
  "data-collection-slug": collection["slug"],
3247
815
  "data-component-name": componentName,
@@ -3250,13 +818,13 @@ var LoadMoreTarget = function LoadMoreTarget(_ref) {
3250
818
  });
3251
819
  };
3252
820
  LoadMoreTarget.propTypes = {
3253
- collection: PropTypes.shape({
3254
- id: PropTypes.string,
3255
- slug: PropTypes.string
821
+ collection: PropTypes__default["default"].shape({
822
+ id: PropTypes__default["default"].string,
823
+ slug: PropTypes__default["default"].string
3256
824
  }),
3257
- componentName: PropTypes.string,
3258
- offset: PropTypes.number,
3259
- limit: PropTypes.number
825
+ componentName: PropTypes__default["default"].string,
826
+ offset: PropTypes__default["default"].number,
827
+ limit: PropTypes__default["default"].number
3260
828
  };
3261
829
 
3262
830
  var _styleModuleImportMap$7 = {
@@ -3284,7 +852,7 @@ var CollectionNameBase = function CollectionNameBase(_ref) {
3284
852
  _ref$navigate = _ref.navigate,
3285
853
  navigate = _ref$navigate === void 0 ? true : _ref$navigate;
3286
854
  var collectionTitle = useStateValue() || {};
3287
- var showRowTitle = get_1(collectionTitle, ["showRowTitle"], true);
855
+ var showRowTitle = lodash.get(collectionTitle, ["showRowTitle"], true);
3288
856
  var supportedTemplates = ["borderLeft", "borderBottom", "crossLine", "borderBottomFull"];
3289
857
  var templateStyle = supportedTemplates.includes(collectionNameTemplate) ? " collection-".concat(collectionNameTemplate) : "";
3290
858
  var slug = navigate && collection && getSlug(collection, config) || "";
@@ -3295,7 +863,7 @@ var CollectionNameBase = function CollectionNameBase(_ref) {
3295
863
  var borderBottomFullStyle = templateStyle.includes("collection-borderBottomFull") ? "4px solid ".concat(CollectionNameBorderColor) : "";
3296
864
 
3297
865
  var borderBottomStyle = function borderBottomStyle() {
3298
- return templateStyle.includes("collection-borderBottom") && !templateStyle.includes("collection-borderBottomFull") ? /*#__PURE__*/React.createElement("div", {
866
+ return templateStyle.includes("collection-borderBottom") && !templateStyle.includes("collection-borderBottomFull") ? /*#__PURE__*/React__default["default"].createElement("div", {
3299
867
  className: "collection-name-m_border-bottom__1MnlV",
3300
868
  style: {
3301
869
  borderBottom: "4px solid ".concat(CollectionNameBorderColor)
@@ -3355,40 +923,40 @@ var CollectionNameBase = function CollectionNameBase(_ref) {
3355
923
  }
3356
924
  };
3357
925
 
3358
- return /*#__PURE__*/React.createElement(React.Fragment, null, showRowTitle && collectionName && /*#__PURE__*/React.createElement("div", {
926
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, showRowTitle && collectionName && /*#__PURE__*/React__default["default"].createElement("div", {
3359
927
  style: {
3360
928
  borderBottom: borderBottomFullStyle
3361
929
  },
3362
930
  "data-test-id": "collection-name",
3363
- className: ("arr--collection-name arrow-component ".concat(templateStyle) ? "arr--collection-name arrow-component ".concat(templateStyle) + " " : "") + _getClassName("collection ".concat(textColor, " ").concat(templateStyle), _styleModuleImportMap$7)
3364
- }, templateStyle.includes("collection-borderLeft") && /*#__PURE__*/React.createElement("span", {
931
+ className: ("arr--collection-name arrow-component ".concat(templateStyle) ? "arr--collection-name arrow-component ".concat(templateStyle) + " " : "") + _getClassName__default["default"]("collection ".concat(textColor, " ").concat(templateStyle), _styleModuleImportMap$7)
932
+ }, templateStyle.includes("collection-borderLeft") && /*#__PURE__*/React__default["default"].createElement("span", {
3365
933
  className: "arr-collection-name-border-left collection-name-m_border-left__3_pYw",
3366
934
  style: {
3367
935
  color: CollectionNameBorderColor,
3368
936
  fontSize: getBorderHeight()
3369
937
  }
3370
- }), slug && !slug.includes(undefined) ? /*#__PURE__*/React.createElement(Link, {
938
+ }), slug && !slug.includes(undefined) ? /*#__PURE__*/React__default["default"].createElement(components.Link, {
3371
939
  href: slug,
3372
940
  "aria-label": "collection-name"
3373
- }, /*#__PURE__*/React.createElement(HeaderTag, null, collectionName)) : /*#__PURE__*/React.createElement(HeaderTag, null, collectionName), borderBottomStyle()));
941
+ }, /*#__PURE__*/React__default["default"].createElement(HeaderTag, null, collectionName)) : /*#__PURE__*/React__default["default"].createElement(HeaderTag, null, collectionName), borderBottomStyle()));
3374
942
  };
3375
943
  CollectionNameBase.propTypes = {
3376
944
  /** Collection name border color */
3377
- collectionNameBorderColor: PropTypes$1.string,
945
+ collectionNameBorderColor: PropTypes.PropTypes.string,
3378
946
 
3379
947
  /** The Collection Object from the API response */
3380
- collection: PropTypes$1.object,
948
+ collection: PropTypes.PropTypes.object,
3381
949
 
3382
950
  /** The publisher config from the API response */
3383
- config: PropTypes$1.object,
951
+ config: PropTypes.PropTypes.object,
3384
952
 
3385
953
  /** The style template for the component */
3386
- collectionNameTemplate: PropTypes$1.oneOf(["", "borderLeft", "borderBottom", "crossLine", "borderBottomFull"]),
954
+ collectionNameTemplate: PropTypes.PropTypes.oneOf(["", "borderLeft", "borderBottom", "crossLine", "borderBottomFull"]),
3387
955
 
3388
956
  /** Header tags ranging h1-h6, where h[headerLevel] */
3389
- headerLevel: PropTypes$1.string,
3390
- customCollectionName: PropTypes$1.string,
3391
- navigate: PropTypes$1.bool
957
+ headerLevel: PropTypes.PropTypes.string,
958
+ customCollectionName: PropTypes.PropTypes.string,
959
+ navigate: PropTypes.PropTypes.bool
3392
960
  };
3393
961
  CollectionNameBase.defaultProps = {
3394
962
  collectionNameTemplate: "",
@@ -3397,11 +965,11 @@ CollectionNameBase.defaultProps = {
3397
965
 
3398
966
  function mapStateToProps(state) {
3399
967
  return {
3400
- config: get_1(state, ["qt", "config"], {})
968
+ config: lodash.get(state, ["qt", "config"], {})
3401
969
  };
3402
970
  }
3403
971
 
3404
- var CollectionName = connect(mapStateToProps)(CollectionNameBase);
972
+ var CollectionName = reactRedux.connect(mapStateToProps)(CollectionNameBase);
3405
973
 
3406
974
  var _styleModuleImportMap$6 = {
3407
975
  "./timestamp.m.css": {
@@ -3418,22 +986,22 @@ var TimeStamp = function TimeStamp(_ref) {
3418
986
  _ref$config = _ref.config,
3419
987
  config = _ref$config === void 0 ? {} : _ref$config;
3420
988
  var configState = useStateValue() || {};
3421
- var isTime = get_1(config, ["showTime"], get_1(configState, ["showTime"], true));
989
+ var isTime = lodash.get(config, ["showTime"], lodash.get(configState, ["showTime"], true));
3422
990
  var time = story["last-published-at"] || story["first-published-at"];
3423
991
  var isBottomClasses = isBottom ? "bottom-fix" : "";
3424
992
  var textColor = getTextColor(configState.theme);
3425
- return /*#__PURE__*/React.createElement(React.Fragment, null, isTime && /*#__PURE__*/React.createElement("div", {
993
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isTime && /*#__PURE__*/React__default["default"].createElement("div", {
3426
994
  "data-test-id": "publish-time",
3427
- className: "time arr--publish-time " + _getClassName("time ".concat(textColor, " ").concat(isBottomClasses), _styleModuleImportMap$6)
3428
- }, /*#__PURE__*/React.createElement("div", {
995
+ className: "time arr--publish-time " + _getClassName__default["default"]("time ".concat(textColor, " ").concat(isBottomClasses), _styleModuleImportMap$6)
996
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
3429
997
  className: "timestamp-m_time-wrapper__3O2lM"
3430
998
  }, getTimeStamp(time, formatter, config))));
3431
999
  };
3432
1000
  TimeStamp.propTypes = {
3433
1001
  /** The Story Object from the API response */
3434
- story: PropTypes.object,
3435
- isBottom: PropTypes.bool,
3436
- config: PropTypes.object
1002
+ story: PropTypes__default["default"].object,
1003
+ isBottom: PropTypes__default["default"].bool,
1004
+ config: PropTypes__default["default"].object
3437
1005
  };
3438
1006
 
3439
1007
  var _styleModuleImportMap$5 = {
@@ -3449,14 +1017,14 @@ var Dot = function Dot(_ref) {
3449
1017
  height = _ref$height === void 0 ? "3px" : _ref$height,
3450
1018
  _ref$color = _ref.color,
3451
1019
  color = _ref$color === void 0 ? "light" : _ref$color;
3452
- return /*#__PURE__*/React.createElement("div", {
3453
- className: _getClassName(color, _styleModuleImportMap$5)
3454
- }, /*#__PURE__*/React.createElement("svg", {
1020
+ return /*#__PURE__*/React__default["default"].createElement("div", {
1021
+ className: _getClassName__default["default"](color, _styleModuleImportMap$5)
1022
+ }, /*#__PURE__*/React__default["default"].createElement("svg", {
3455
1023
  xmlns: "http://www.w3.org/2000/svg",
3456
1024
  width: width,
3457
1025
  height: height,
3458
1026
  viewBox: "0 0 3 3"
3459
- }, /*#__PURE__*/React.createElement("circle", {
1027
+ }, /*#__PURE__*/React__default["default"].createElement("circle", {
3460
1028
  cx: "87",
3461
1029
  cy: "9",
3462
1030
  r: "1",
@@ -3467,9 +1035,9 @@ var Dot = function Dot(_ref) {
3467
1035
  };
3468
1036
  Dot.propTypes = {
3469
1037
  /** height , width and color of the dot icon */
3470
- color: PropTypes.string,
3471
- width: PropTypes.string,
3472
- height: PropTypes.string
1038
+ color: PropTypes__default["default"].string,
1039
+ width: PropTypes__default["default"].string,
1040
+ height: PropTypes__default["default"].string
3473
1041
  };
3474
1042
 
3475
1043
  var _styleModuleImportMap$4 = {
@@ -3485,22 +1053,22 @@ var Divider = function Divider(_ref) {
3485
1053
  height = _ref$height === void 0 ? "10" : _ref$height,
3486
1054
  _ref$color = _ref.color,
3487
1055
  color = _ref$color === void 0 ? "light" : _ref$color;
3488
- return /*#__PURE__*/React.createElement("div", {
3489
- className: _getClassName(color, _styleModuleImportMap$4)
3490
- }, /*#__PURE__*/React.createElement("svg", {
1056
+ return /*#__PURE__*/React__default["default"].createElement("div", {
1057
+ className: _getClassName__default["default"](color, _styleModuleImportMap$4)
1058
+ }, /*#__PURE__*/React__default["default"].createElement("svg", {
3491
1059
  xmlns: "http://www.w3.org/2000/svg",
3492
1060
  width: width,
3493
1061
  height: height
3494
- }, /*#__PURE__*/React.createElement("path", {
1062
+ }, /*#__PURE__*/React__default["default"].createElement("path", {
3495
1063
  fill: "inherit",
3496
1064
  d: "M0 0h1v10H0z"
3497
1065
  })));
3498
1066
  };
3499
1067
  Divider.propTypes = {
3500
1068
  /** height , width and color of the dot icon */
3501
- color: PropTypes.string,
3502
- width: PropTypes.string,
3503
- height: PropTypes.string
1069
+ color: PropTypes__default["default"].string,
1070
+ width: PropTypes__default["default"].string,
1071
+ height: PropTypes__default["default"].string
3504
1072
  };
3505
1073
 
3506
1074
  var _styleModuleImportMap$3 = {
@@ -3518,28 +1086,28 @@ var ReadTime = function ReadTime(_ref) {
3518
1086
  _ref$isLightTheme = _ref.isLightTheme,
3519
1087
  isLightTheme = _ref$isLightTheme === void 0 ? false : _ref$isLightTheme;
3520
1088
  var config = useStateValue() || {};
3521
- var showReadTime = get_1(config, ["showReadTime"]) || get_1(opts, ["showReadTime"], true);
3522
- var readTime = get_1(story, ["read-time"], 0);
1089
+ var showReadTime = lodash.get(config, ["showReadTime"]) || lodash.get(opts, ["showReadTime"], true);
1090
+ var readTime = lodash.get(story, ["read-time"], 0);
3523
1091
  var textColor = isLightTheme ? "light" : getTextColor(config.theme);
3524
1092
  if (!showReadTime || !readTime) return null;
3525
- var timeToRead = get_1(opts, ["localizedTimeToRead"]) || "min read";
3526
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
1093
+ var timeToRead = lodash.get(opts, ["localizedTimeToRead"]) || "min read";
1094
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
3527
1095
  "data-test-id": "read-time",
3528
- className: "arrow-component arr--read-time " + _getClassName("read-time-wrapper ".concat(textColor), _styleModuleImportMap$3)
3529
- }, /*#__PURE__*/React.createElement("span", {
1096
+ className: "arrow-component arr--read-time " + _getClassName__default["default"]("read-time-wrapper ".concat(textColor), _styleModuleImportMap$3)
1097
+ }, /*#__PURE__*/React__default["default"].createElement("span", {
3530
1098
  className: "read-time-indicator read-time-m_dot-indicator__3Sqh2"
3531
- }, /*#__PURE__*/React.createElement(Dot, {
1099
+ }, /*#__PURE__*/React__default["default"].createElement(Dot, {
3532
1100
  color: textColor
3533
- })), /*#__PURE__*/React.createElement("span", null, readTime, " ", timeToRead)));
1101
+ })), /*#__PURE__*/React__default["default"].createElement("span", null, readTime, " ", timeToRead)));
3534
1102
  };
3535
1103
  ReadTime.propTypes = {
3536
- story: PropTypes.shape({
3537
- "read-time": PropTypes.number
1104
+ story: PropTypes__default["default"].shape({
1105
+ "read-time": PropTypes__default["default"].number
3538
1106
  }),
3539
- opts: PropTypes.shape({
3540
- showReadTime: PropTypes.bool
1107
+ opts: PropTypes__default["default"].shape({
1108
+ showReadTime: PropTypes__default["default"].bool
3541
1109
  }),
3542
- isLightTheme: PropTypes.bool
1110
+ isLightTheme: PropTypes__default["default"].bool
3543
1111
  };
3544
1112
 
3545
1113
  var _styleModuleImportMap$2 = {
@@ -3561,42 +1129,42 @@ var AuthorWithTime = function AuthorWithTime(_ref) {
3561
1129
  config = _ref$config === void 0 ? {} : _ref$config,
3562
1130
  isLightTheme = _ref.isLightTheme;
3563
1131
  var configState = useStateValue() || {};
3564
- var isAuthor = get_1(config, ["showAuthor"], get_1(configState, ["showAuthor"], true));
3565
- var isTime = get_1(config, ["showTime"], get_1(configState, ["showTime"], true));
3566
- var isReadTime = get_1(configState, ["showReadTime"], true);
1132
+ var isAuthor = lodash.get(config, ["showAuthor"], lodash.get(configState, ["showAuthor"], true));
1133
+ var isTime = lodash.get(config, ["showTime"], lodash.get(configState, ["showTime"], true));
1134
+ var isReadTime = lodash.get(configState, ["showReadTime"], true);
3567
1135
  var isBottomClasses = isBottom ? "bottom-fix" : "";
3568
1136
  var seperatorStyle = separator === "dot" ? "dot" : "dash";
3569
1137
  var textColor = isLightTheme ? "light" : getTextColor(configState.theme);
3570
1138
 
3571
1139
  var getSeparator = function getSeparator() {
3572
1140
  if (separator === "divider") {
3573
- return /*#__PURE__*/React.createElement(Divider, {
1141
+ return /*#__PURE__*/React__default["default"].createElement(Divider, {
3574
1142
  color: textColor
3575
1143
  });
3576
1144
  }
3577
1145
 
3578
- return /*#__PURE__*/React.createElement(Dot, {
1146
+ return /*#__PURE__*/React__default["default"].createElement(Dot, {
3579
1147
  color: textColor
3580
1148
  });
3581
1149
  };
3582
1150
 
3583
1151
  var getTimeStamp = function getTimeStamp() {
3584
1152
  if (!isTime) return null;
3585
- return /*#__PURE__*/React.createElement(React.Fragment, null, isAuthor && /*#__PURE__*/React.createElement("span", {
3586
- className: "arr-separator " + _getClassName("".concat(seperatorStyle), _styleModuleImportMap$2)
3587
- }, getSeparator()), /*#__PURE__*/React.createElement(TimeStamp, {
1153
+ return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isAuthor && /*#__PURE__*/React__default["default"].createElement("span", {
1154
+ className: "arr-separator " + _getClassName__default["default"]("".concat(seperatorStyle), _styleModuleImportMap$2)
1155
+ }, getSeparator()), /*#__PURE__*/React__default["default"].createElement(TimeStamp, {
3588
1156
  story: story,
3589
1157
  config: config
3590
- }), isReadTime && /*#__PURE__*/React.createElement(ReadTime, {
1158
+ }), isReadTime && /*#__PURE__*/React__default["default"].createElement(ReadTime, {
3591
1159
  story: story,
3592
1160
  opts: config,
3593
1161
  isLightTheme: isLightTheme
3594
1162
  }));
3595
1163
  };
3596
1164
 
3597
- return /*#__PURE__*/React.createElement("div", {
3598
- className: "arr--author-time " + _getClassName("author-time-wrapper ".concat(isBottomClasses), _styleModuleImportMap$2)
3599
- }, isAuthor ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Author, {
1165
+ return /*#__PURE__*/React__default["default"].createElement("div", {
1166
+ className: "arr--author-time " + _getClassName__default["default"]("author-time-wrapper ".concat(isBottomClasses), _styleModuleImportMap$2)
1167
+ }, isAuthor ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(Author, {
3600
1168
  story: story,
3601
1169
  isBottom: true,
3602
1170
  hideAuthorImage: hideAuthorImage,
@@ -3604,19 +1172,19 @@ var AuthorWithTime = function AuthorWithTime(_ref) {
3604
1172
  }), getTimeStamp()) : getTimeStamp());
3605
1173
  };
3606
1174
  AuthorWithTime.propTypes = {
3607
- story: PropTypes.object,
1175
+ story: PropTypes__default["default"].object,
3608
1176
 
3609
1177
  /** Style of separator between the Author & Timestamp */
3610
- separator: PropTypes.oneOf(["dot", "divider"]),
1178
+ separator: PropTypes__default["default"].oneOf(["dot", "divider"]),
3611
1179
 
3612
1180
  /** hide the author image */
3613
- hideAuthorImage: PropTypes.bool,
1181
+ hideAuthorImage: PropTypes__default["default"].bool,
3614
1182
  // fix author and time at the end
3615
- isBottom: PropTypes.bool,
1183
+ isBottom: PropTypes__default["default"].bool,
3616
1184
  // fix prefix before the author name
3617
- prefix: PropTypes.string,
3618
- config: PropTypes.object,
3619
- isLightTheme: PropTypes.bool
1185
+ prefix: PropTypes__default["default"].string,
1186
+ config: PropTypes__default["default"].object,
1187
+ isLightTheme: PropTypes__default["default"].bool
3620
1188
  };
3621
1189
  AuthorWithTime.defaultProps = {
3622
1190
  separator: "dot",
@@ -3637,7 +1205,7 @@ var _styleModuleImportMap$1 = {
3637
1205
 
3638
1206
  function ownKeys$1(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; }
3639
1207
 
3640
- function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$1(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$1(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
1208
+ function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$1(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$1(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
3641
1209
  var LoadmoreButton = function LoadmoreButton(_ref) {
3642
1210
  var _ref$config = _ref.config,
3643
1211
  config = _ref$config === void 0 ? {} : _ref$config,
@@ -3658,89 +1226,28 @@ var LoadmoreButton = function LoadmoreButton(_ref) {
3658
1226
  if (!showButton) return null;
3659
1227
  var textColor = getTextColor(theme);
3660
1228
  var slug = customUrlPath ? "/".concat(customUrlPath) : generateNavigateSlug(collection, _objectSpread$1(_objectSpread$1({}, qtConfig), config));
3661
- return template === "SubsequentLoadCount" ? /*#__PURE__*/React.createElement("div", {
1229
+ return template === "SubsequentLoadCount" ? /*#__PURE__*/React__default["default"].createElement("div", {
3662
1230
  onClick: onClick,
3663
1231
  "data-test-id": "load-more",
3664
- className: "arr--button " + _getClassName("button ".concat(textColor, " default"), _styleModuleImportMap$1)
3665
- }, buttonText) : /*#__PURE__*/React.createElement(LinkBase, {
1232
+ className: "arr--button " + _getClassName__default["default"]("button ".concat(textColor, " default"), _styleModuleImportMap$1)
1233
+ }, buttonText) : /*#__PURE__*/React__default["default"].createElement(components.LinkBase, {
3666
1234
  href: slug,
3667
1235
  navigateTo: navigate,
3668
1236
  "data-test-id": "load-more",
3669
1237
  "aria-label": "load-more"
3670
- }, /*#__PURE__*/React.createElement("div", {
3671
- className: "arr--button " + _getClassName("button ".concat(textColor, " default"), _styleModuleImportMap$1)
1238
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
1239
+ className: "arr--button " + _getClassName__default["default"]("button ".concat(textColor, " default"), _styleModuleImportMap$1)
3672
1240
  }, buttonText));
3673
1241
  };
3674
1242
  LoadmoreButton.propTypes = {
3675
- collection: PropTypes.object,
3676
- template: PropTypes.string,
3677
- config: PropTypes.object,
3678
- onClick: PropTypes.func,
3679
- navigate: PropTypes.func,
3680
- qtConfig: PropTypes.object
1243
+ collection: PropTypes__default["default"].object,
1244
+ template: PropTypes__default["default"].string,
1245
+ config: PropTypes__default["default"].object,
1246
+ onClick: PropTypes__default["default"].func,
1247
+ navigate: PropTypes__default["default"].func,
1248
+ qtConfig: PropTypes__default["default"].object
3681
1249
  };
3682
1250
 
3683
- function _arrayWithHoles(arr) {
3684
- if (Array.isArray(arr)) return arr;
3685
- }
3686
-
3687
- function _iterableToArrayLimit(arr, i) {
3688
- var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
3689
-
3690
- if (_i == null) return;
3691
- var _arr = [];
3692
- var _n = true;
3693
- var _d = false;
3694
-
3695
- var _s, _e;
3696
-
3697
- try {
3698
- for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
3699
- _arr.push(_s.value);
3700
-
3701
- if (i && _arr.length === i) break;
3702
- }
3703
- } catch (err) {
3704
- _d = true;
3705
- _e = err;
3706
- } finally {
3707
- try {
3708
- if (!_n && _i["return"] != null) _i["return"]();
3709
- } finally {
3710
- if (_d) throw _e;
3711
- }
3712
- }
3713
-
3714
- return _arr;
3715
- }
3716
-
3717
- function _arrayLikeToArray(arr, len) {
3718
- if (len == null || len > arr.length) len = arr.length;
3719
-
3720
- for (var i = 0, arr2 = new Array(len); i < len; i++) {
3721
- arr2[i] = arr[i];
3722
- }
3723
-
3724
- return arr2;
3725
- }
3726
-
3727
- function _unsupportedIterableToArray(o, minLen) {
3728
- if (!o) return;
3729
- if (typeof o === "string") return _arrayLikeToArray(o, minLen);
3730
- var n = Object.prototype.toString.call(o).slice(8, -1);
3731
- if (n === "Object" && o.constructor) n = o.constructor.name;
3732
- if (n === "Map" || n === "Set") return Array.from(o);
3733
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
3734
- }
3735
-
3736
- function _nonIterableRest() {
3737
- throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3738
- }
3739
-
3740
- function _slicedToArray(arr, i) {
3741
- return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
3742
- }
3743
-
3744
1251
  var isClient = typeof window !== "undefined";
3745
1252
 
3746
1253
  var hasIntersectionObserverSupport = function hasIntersectionObserverSupport() {
@@ -3750,7 +1257,7 @@ var hasIntersectionObserverSupport = function hasIntersectionObserverSupport() {
3750
1257
 
3751
1258
 
3752
1259
  var getIntersectionObserver = function getIntersectionObserver() {
3753
- return Promise.resolve(isClient && !hasIntersectionObserverSupport() && import('intersection-observer'));
1260
+ return Promise.resolve(isClient && !hasIntersectionObserverSupport() && Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require('intersection-observer')); }));
3754
1261
  }; // options for intersection observer in order to improve the effect
3755
1262
 
3756
1263
 
@@ -3783,12 +1290,12 @@ var getObserver = function getObserver() {
3783
1290
  var useNearScreen = (function (_ref) {
3784
1291
  var ref = _ref.ref;
3785
1292
 
3786
- var _useState = useState(false),
3787
- _useState2 = _slicedToArray(_useState, 2),
1293
+ var _useState = React.useState(false),
1294
+ _useState2 = _slicedToArray__default["default"](_useState, 2),
3788
1295
  show = _useState2[0],
3789
1296
  setShow = _useState2[1];
3790
1297
 
3791
- useEffect(function () {
1298
+ React.useEffect(function () {
3792
1299
  var current = ref.current;
3793
1300
  if (!current) return; // get observer async and only when needed
3794
1301
 
@@ -3815,36 +1322,36 @@ var EMPTY_HTML = {
3815
1322
  var isServer = typeof window === "undefined";
3816
1323
  var ProgressiveHydration = function ProgressiveHydration(props) {
3817
1324
  var children = props.children;
3818
- var ref = useRef(null);
1325
+ var ref = React.useRef(null);
3819
1326
  var isNearScreen = useNearScreen({
3820
1327
  ref: ref
3821
1328
  });
3822
- useEffect(function () {
1329
+ React.useEffect(function () {
3823
1330
  var el = ref.current; // CLIENT:
3824
1331
  // If we want to force the hydration OR the element is near screen
3825
1332
  // then we hydrate the content to get the functionality ready
3826
1333
 
3827
1334
  if (isNearScreen) {
3828
1335
  var action = el.hasChildNodes() ? "hydrate" : "render";
3829
- ReactDOM[action](children, el);
1336
+ ReactDOM__default["default"][action](children, el);
3830
1337
  }
3831
1338
  }, [children, isNearScreen]); // SERVER: Just render the content as usual
3832
1339
 
3833
1340
  if (isServer) {
3834
- return /*#__PURE__*/React.createElement("div", {
1341
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3835
1342
  ref: ref
3836
1343
  }, children);
3837
1344
  } // CLIENT: Avoid hydration until we say so
3838
1345
 
3839
1346
 
3840
- return /*#__PURE__*/React.createElement("div", {
1347
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3841
1348
  ref: ref,
3842
1349
  suppressHydrationWarning: true,
3843
1350
  dangerouslySetInnerHTML: EMPTY_HTML
3844
1351
  });
3845
1352
  };
3846
1353
  ProgressiveHydration.propTypes = {
3847
- children: PropTypes.element
1354
+ children: PropTypes__default["default"].element
3848
1355
  };
3849
1356
 
3850
1357
  var _styleModuleImportMap = {
@@ -3868,7 +1375,7 @@ var _styleModuleImportMap = {
3868
1375
 
3869
1376
  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; }
3870
1377
 
3871
- 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(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; }
1378
+ 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; }
3872
1379
 
3873
1380
  var loadMore = function loadMore(_ref) {
3874
1381
  var isLoading = _ref.isLoading,
@@ -3889,7 +1396,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3889
1396
  isLoadMoreVisible = _ref2.isLoadMoreVisible,
3890
1397
  isLoading = _ref2.isLoading,
3891
1398
  isolatedLoadMore = _ref2.isolatedLoadMore;
3892
- var stories = collectionToStories(collection);
1399
+ var stories = components.collectionToStories(collection);
3893
1400
  var _config$theme = config.theme,
3894
1401
  theme = _config$theme === void 0 ? "" : _config$theme,
3895
1402
  _config$footerButton = config.footerButton,
@@ -3905,15 +1412,15 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3905
1412
  _config$subsequentLoa = config.subsequentLoadCount,
3906
1413
  subsequentLoadCount = _config$subsequentLoa === void 0 ? 3 : _config$subsequentLoa;
3907
1414
 
3908
- var _get = get_1(slotConfig, [0], {}),
1415
+ var _get = lodash.get(slotConfig, [0], {}),
3909
1416
  _get$type = _get.type,
3910
1417
  type = _get$type === void 0 ? "story" : _get$type,
3911
1418
  _get$component = _get.component,
3912
1419
  component = _get$component === void 0 ? null : _get$component;
3913
1420
 
3914
- var dispatch = useDispatch();
3915
- var qtConfig = useSelector(function (state) {
3916
- return get_1(state, ["qt", "config"], {});
1421
+ var dispatch = reactRedux.useDispatch();
1422
+ var qtConfig = reactRedux.useSelector(function (state) {
1423
+ return lodash.get(state, ["qt", "config"], {});
3917
1424
  });
3918
1425
  if (!stories.length) return null;
3919
1426
  var textColor = getTextColor(theme);
@@ -3925,7 +1432,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3925
1432
  if (!isLoadMoreVisible) return null;
3926
1433
 
3927
1434
  if (isolatedLoadMore) {
3928
- return /*#__PURE__*/React.createElement(LoadMoreTarget, {
1435
+ return /*#__PURE__*/React__default["default"].createElement(LoadMoreTarget, {
3929
1436
  collection: collection,
3930
1437
  componentName: "OpinionCollection",
3931
1438
  offset: stories.length,
@@ -3934,7 +1441,7 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3934
1441
  }
3935
1442
 
3936
1443
  var url = generateNavigateSlug(collection, qtConfig);
3937
- return /*#__PURE__*/React.createElement(ProgressiveHydration, null, /*#__PURE__*/React.createElement(LoadmoreButton, {
1444
+ return /*#__PURE__*/React__default["default"].createElement(ProgressiveHydration, null, /*#__PURE__*/React__default["default"].createElement(LoadmoreButton, {
3938
1445
  config: config,
3939
1446
  collection: collection,
3940
1447
  template: footerButton,
@@ -3949,21 +1456,21 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3949
1456
  };
3950
1457
 
3951
1458
  var getAuthorCard = function getAuthorCard(story) {
3952
- var authorData = get_1(story, ["authors", "0"]);
3953
- return /*#__PURE__*/React.createElement("div", {
1459
+ var authorData = lodash.get(story, ["authors", "0"]);
1460
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3954
1461
  "data-test-id": "story-card"
3955
- }, /*#__PURE__*/React.createElement(Author, {
1462
+ }, /*#__PURE__*/React__default["default"].createElement(Author, {
3956
1463
  story: story,
3957
1464
  hideAuthorImage: true
3958
- }), /*#__PURE__*/React.createElement("div", {
1465
+ }), /*#__PURE__*/React__default["default"].createElement("div", {
3959
1466
  className: "opinion-collection-m_headline-author__2H6Tv"
3960
- }, /*#__PURE__*/React.createElement(Headline, {
1467
+ }, /*#__PURE__*/React__default["default"].createElement(Headline, {
3961
1468
  story: story
3962
- }), /*#__PURE__*/React.createElement(AuthorImage, {
1469
+ }), /*#__PURE__*/React__default["default"].createElement(AuthorImage, {
3963
1470
  author: authorData,
3964
1471
  template: "smallerCircle",
3965
1472
  config: config
3966
- })), /*#__PURE__*/React.createElement(AuthorWithTime, {
1473
+ })), /*#__PURE__*/React__default["default"].createElement(AuthorWithTime, {
3967
1474
  story: story,
3968
1475
  config: _objectSpread(_objectSpread({}, config), {}, {
3969
1476
  disableMeridiem: true,
@@ -3973,31 +1480,31 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
3973
1480
  };
3974
1481
 
3975
1482
  var countStyleName = stories.length === 2 || stories.length === 3 ? "count-".concat(stories.length) : "";
3976
- return /*#__PURE__*/React.createElement("div", {
1483
+ return /*#__PURE__*/React__default["default"].createElement("div", {
3977
1484
  className: "full-width-with-padding arrow-component",
3978
1485
  "data-test-id": "opinion-collection",
3979
1486
  style: {
3980
1487
  backgroundColor: theme,
3981
1488
  color: textColor
3982
1489
  }
3983
- }, /*#__PURE__*/React.createElement("div", {
1490
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
3984
1491
  className: "opinion-collection-m_opinion-collection__1Bc7h",
3985
1492
  style: {
3986
1493
  backgroundColor: theme,
3987
1494
  color: textColor
3988
1495
  }
3989
- }, /*#__PURE__*/React.createElement(CollectionName, {
1496
+ }, /*#__PURE__*/React__default["default"].createElement(CollectionName, {
3990
1497
  collection: collection,
3991
1498
  collectionNameTemplate: collectionNameTemplate,
3992
1499
  collectionNameBorderColor: collectionNameBorderColor,
3993
1500
  headerLevel: 2
3994
- }), /*#__PURE__*/React.createElement("div", {
3995
- className: ("content-wrapper ".concat(borderStyle, " ").concat(textColor) ? "content-wrapper ".concat(borderStyle, " ").concat(textColor) + " " : "") + _getClassName("content-wrapper ".concat(borderStyle, " ").concat(textColor, " ").concat(adStyle), _styleModuleImportMap)
3996
- }, slot ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
3997
- className: "wrapper-with-ads " + _getClassName("wrapper-with-ads ".concat(countStyleName), _styleModuleImportMap)
1501
+ }), /*#__PURE__*/React__default["default"].createElement("div", {
1502
+ 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)
1503
+ }, slot ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
1504
+ className: "wrapper-with-ads " + _getClassName__default["default"]("wrapper-with-ads ".concat(countStyleName), _styleModuleImportMap)
3998
1505
  }, stories.slice(0, 4).map(function (story) {
3999
1506
  return getAuthorCard(story);
4000
- })), /*#__PURE__*/React.createElement("div", {
1507
+ })), /*#__PURE__*/React__default["default"].createElement("div", {
4001
1508
  className: "opinion-collection-m_ad-slot__2ZpaC"
4002
1509
  }, slot)) : stories.map(function (story) {
4003
1510
  return getAuthorCard(story);
@@ -4009,20 +1516,20 @@ var OpinionCollectionBase = function OpinionCollectionBase(_ref2) {
4009
1516
  })));
4010
1517
  };
4011
1518
  OpinionCollectionBase.propTypes = {
4012
- collection: PropTypes.object,
4013
- config: PropTypes.shape({
4014
- collectionNameBorderColor: PropTypes.string,
4015
- theme: PropTypes.string,
4016
- collectionNameTemplate: PropTypes.string,
4017
- footerButton: PropTypes.string,
4018
- border: PropTypes.string,
4019
- slotConfig: PropTypes.array,
4020
- subsequentLoadCount: PropTypes.number
1519
+ collection: PropTypes__default["default"].object,
1520
+ config: PropTypes__default["default"].shape({
1521
+ collectionNameBorderColor: PropTypes__default["default"].string,
1522
+ theme: PropTypes__default["default"].string,
1523
+ collectionNameTemplate: PropTypes__default["default"].string,
1524
+ footerButton: PropTypes__default["default"].string,
1525
+ border: PropTypes__default["default"].string,
1526
+ slotConfig: PropTypes__default["default"].array,
1527
+ subsequentLoadCount: PropTypes__default["default"].number
4021
1528
  }),
4022
- getMoreStories: PropTypes.func,
4023
- isLoading: PropTypes.bool,
4024
- isLoadMoreVisible: PropTypes.bool,
4025
- isolatedLoadMore: PropTypes.bool
1529
+ getMoreStories: PropTypes__default["default"].func,
1530
+ isLoading: PropTypes__default["default"].bool,
1531
+ isLoadMoreVisible: PropTypes__default["default"].bool,
1532
+ isolatedLoadMore: PropTypes__default["default"].bool
4026
1533
  };
4027
1534
  OpinionCollectionBase.defaultProps = {
4028
1535
  getMoreStories: function getMoreStories() {},
@@ -4034,4 +1541,5 @@ OpinionCollectionBase.defaultProps = {
4034
1541
  };
4035
1542
  var OpinionCollection = StateProvider(OpinionCollectionBase);
4036
1543
 
4037
- export { OpinionCollection, OpinionCollectionBase };
1544
+ exports.OpinionCollection = OpinionCollection;
1545
+ exports.OpinionCollectionBase = OpinionCollectionBase;