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

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 (166) hide show
  1. package/cjs/index.js +14589 -0
  2. package/package.json +1 -1
  3. package/atoms/Author/index.js +0 -2250
  4. package/atoms/Author/styles.arrow.css +0 -1
  5. package/atoms/AuthorWithTime/index.js +0 -2954
  6. package/atoms/AuthorWithTime/styles.arrow.css +0 -1
  7. package/atoms/CollectionName/index.js +0 -2334
  8. package/atoms/CollectionName/styles.arrow.css +0 -1
  9. package/atoms/ExtendedLoadMore/index-0519e570.js +0 -243
  10. package/atoms/ExtendedLoadMore/index-1256e453.js +0 -175
  11. package/atoms/ExtendedLoadMore/index-1e444d20.js +0 -990
  12. package/atoms/ExtendedLoadMore/index-4356ce04.js +0 -282
  13. package/atoms/ExtendedLoadMore/index-81eb3978.js +0 -86
  14. package/atoms/ExtendedLoadMore/index-aba6b278.js +0 -166
  15. package/atoms/ExtendedLoadMore/index-ad3c83c3.js +0 -3023
  16. package/atoms/ExtendedLoadMore/index-beed3a68.js +0 -240
  17. package/atoms/ExtendedLoadMore/index-c2f73d18.js +0 -199
  18. package/atoms/ExtendedLoadMore/index-c61a16dc.js +0 -350
  19. package/atoms/ExtendedLoadMore/index-d0f6c865.js +0 -181
  20. package/atoms/ExtendedLoadMore/index-e4cf9cb7.js +0 -223
  21. package/atoms/ExtendedLoadMore/index-fd651f70.js +0 -175
  22. package/atoms/ExtendedLoadMore/index.js +0 -5
  23. package/atoms/ExtendedLoadMore/styles.arrow.css +0 -1
  24. package/atoms/Headline/index.js +0 -2459
  25. package/atoms/Headline/styles.arrow.css +0 -1
  26. package/atoms/HeroImage/index.js +0 -2475
  27. package/atoms/HeroImage/styles.arrow.css +0 -1
  28. package/atoms/LoadmoreButton/index.js +0 -2268
  29. package/atoms/LoadmoreButton/styles.arrow.css +0 -1
  30. package/atoms/ScrollSnap/index.js +0 -2531
  31. package/atoms/ScrollSnap/styles.arrow.css +0 -1
  32. package/atoms/SectionTag/index.js +0 -2220
  33. package/atoms/SectionTag/styles.arrow.css +0 -1
  34. package/atoms/Subheadline/index.js +0 -2200
  35. package/atoms/Subheadline/styles.arrow.css +0 -1
  36. package/atoms/TimeStamp/index.js +0 -2661
  37. package/atoms/TimeStamp/styles.arrow.css +0 -1
  38. package/molecules/KeyEvents/index.js +0 -2968
  39. package/molecules/KeyEvents/styles.arrow.css +0 -1
  40. package/molecules/PageIntroductionCard/index.js +0 -2676
  41. package/molecules/PageIntroductionCard/styles.arrow.css +0 -1
  42. package/molecules/SocialShareTemplate/index.js +0 -3093
  43. package/molecules/SocialShareTemplate/styles.arrow.css +0 -1
  44. package/molecules/StoryCard/index.js +0 -3938
  45. package/molecules/StoryCard/styles.arrow.css +0 -1
  46. package/molecules/StoryElementCard/index.js +0 -5832
  47. package/molecules/StoryElementCard/styles.arrow.css +0 -1
  48. package/molecules/StorycardContent/index.js +0 -3416
  49. package/molecules/StorycardContent/styles.arrow.css +0 -1
  50. package/rows/AlternateCollectionFilter/index.js +0 -4744
  51. package/rows/AlternateCollectionFilter/styles.arrow.css +0 -1
  52. package/rows/AsideCollection/index.js +0 -4690
  53. package/rows/AsideCollection/styles.arrow.css +0 -1
  54. package/rows/AstrologyCollection/index.js +0 -4661
  55. package/rows/AstrologyCollection/styles.arrow.css +0 -1
  56. package/rows/AuthorIntroductionCard/index.js +0 -3520
  57. package/rows/AuthorIntroductionCard/styles.arrow.css +0 -1
  58. package/rows/AuthorsList/index.js +0 -3715
  59. package/rows/AuthorsList/styles.arrow.css +0 -1
  60. package/rows/CollectionFilter/index.js +0 -4834
  61. package/rows/CollectionFilter/styles.arrow.css +0 -1
  62. package/rows/ElevenStories/index.js +0 -4638
  63. package/rows/ElevenStories/styles.arrow.css +0 -1
  64. package/rows/FourColFiveStories/index.js +0 -4359
  65. package/rows/FourColFiveStories/styles.arrow.css +0 -1
  66. package/rows/FourColGrid/index.js +0 -4584
  67. package/rows/FourColGrid/styles.arrow.css +0 -1
  68. package/rows/FourColPortraitStories/index.js +0 -4617
  69. package/rows/FourColPortraitStories/styles.arrow.css +0 -1
  70. package/rows/FourColSixteenStories/index.js +0 -4375
  71. package/rows/FourColSixteenStories/styles.arrow.css +0 -1
  72. package/rows/FourColTwelveStories/index.js +0 -4335
  73. package/rows/FourColTwelveStories/styles.arrow.css +0 -1
  74. package/rows/FourStorySlider/index.js +0 -4743
  75. package/rows/FourStorySlider/styles.arrow.css +0 -1
  76. package/rows/FourStorySliderPortrait/index.js +0 -4746
  77. package/rows/FourStorySliderPortrait/styles.arrow.css +0 -1
  78. package/rows/FourTabbedBigStorySlider/index.js +0 -4505
  79. package/rows/FourTabbedBigStorySlider/styles.arrow.css +0 -1
  80. package/rows/FullScreenSlider/index.js +0 -4661
  81. package/rows/FullScreenSlider/styles.arrow.css +0 -1
  82. package/rows/HalfScreenSlider/index.js +0 -4514
  83. package/rows/HalfScreenSlider/styles.arrow.css +0 -1
  84. package/rows/ListComponent/index.js +0 -4462
  85. package/rows/ListComponent/styles.arrow.css +0 -1
  86. package/rows/Listicles/index.js +0 -3131
  87. package/rows/Listicles/styles.arrow.css +0 -1
  88. package/rows/MagazineEditions/index.js +0 -3142
  89. package/rows/MagazineEditions/styles.arrow.css +0 -1
  90. package/rows/MagazineHeaderCard/index.js +0 -3136
  91. package/rows/MagazineHeaderCard/styles.arrow.css +0 -1
  92. package/rows/MagazineWidget/index.js +0 -4514
  93. package/rows/MagazineWidget/styles.arrow.css +0 -1
  94. package/rows/OneColStoryList/index.js +0 -4670
  95. package/rows/OneColStoryList/styles.arrow.css +0 -1
  96. package/rows/OpinionCollection/index.js +0 -4037
  97. package/rows/OpinionCollection/styles.arrow.css +0 -1
  98. package/rows/SixColSixStories/index.js +0 -4515
  99. package/rows/SixColSixStories/styles.arrow.css +0 -1
  100. package/rows/StoryCollection/index.js +0 -4690
  101. package/rows/StoryCollection/styles.arrow.css +0 -1
  102. package/rows/TagIntroductionCard/index.js +0 -1901
  103. package/rows/TagIntroductionCard/styles.arrow.css +0 -1
  104. package/rows/ThreeColFlexStories/index.js +0 -4575
  105. package/rows/ThreeColFlexStories/styles.arrow.css +0 -1
  106. package/rows/ThreeColFourteenStories/index.js +0 -4283
  107. package/rows/ThreeColFourteenStories/styles.arrow.css +0 -1
  108. package/rows/ThreeColGrid/index.js +0 -4605
  109. package/rows/ThreeColGrid/styles.arrow.css +0 -1
  110. package/rows/ThreeColSevenStory/index.js +0 -4502
  111. package/rows/ThreeColSevenStory/styles.arrow.css +0 -1
  112. package/rows/ThreeColSixStories/index.js +0 -4485
  113. package/rows/ThreeColSixStories/styles.arrow.css +0 -1
  114. package/rows/ThreeColTwelveStories/index.js +0 -4380
  115. package/rows/ThreeColTwelveStories/styles.arrow.css +0 -1
  116. package/rows/TwoColFourStories/index.js +0 -4463
  117. package/rows/TwoColFourStories/styles.arrow.css +0 -1
  118. package/rows/TwoColFourStoryHighlight/index.js +0 -4456
  119. package/rows/TwoColFourStoryHighlight/styles.arrow.css +0 -1
  120. package/rows/TwoColSevenStories/index.js +0 -4490
  121. package/rows/TwoColSevenStories/styles.arrow.css +0 -1
  122. package/rows/TwoColSixStories/index.js +0 -4489
  123. package/rows/TwoColSixStories/styles.arrow.css +0 -1
  124. package/rows/TwoColTenStoriesSidebar/index.js +0 -4549
  125. package/rows/TwoColTenStoriesSidebar/styles.arrow.css +0 -1
  126. package/rows/TwoColThreeStories/index.js +0 -4436
  127. package/rows/TwoColThreeStories/styles.arrow.css +0 -1
  128. package/story-elements/AlsoRead/index.js +0 -2457
  129. package/story-elements/AlsoRead/styles.arrow.css +0 -1
  130. package/story-elements/Attachment/index.js +0 -2013
  131. package/story-elements/Attachment/styles.arrow.css +0 -1
  132. package/story-elements/BigFact/index.js +0 -1983
  133. package/story-elements/BigFact/styles.arrow.css +0 -1
  134. package/story-elements/BlockQuote/index.js +0 -2431
  135. package/story-elements/BlockQuote/styles.arrow.css +0 -1
  136. package/story-elements/Blurb/index.js +0 -2094
  137. package/story-elements/Blurb/styles.arrow.css +0 -1
  138. package/story-elements/Image/index.js +0 -2711
  139. package/story-elements/Image/styles.arrow.css +0 -1
  140. package/story-elements/ImageGallery/index.js +0 -2644
  141. package/story-elements/ImageGallery/styles.arrow.css +0 -1
  142. package/story-elements/ImageSlideshow/index.js +0 -2955
  143. package/story-elements/ImageSlideshow/styles.arrow.css +0 -1
  144. package/story-elements/QuestionAnswer/index.js +0 -2395
  145. package/story-elements/QuestionAnswer/styles.arrow.css +0 -1
  146. package/story-elements/Quote/index.js +0 -2012
  147. package/story-elements/Quote/styles.arrow.css +0 -1
  148. package/story-elements/Reference/index.js +0 -2006
  149. package/story-elements/Reference/styles.arrow.css +0 -1
  150. package/story-elements/StoryElement/index.js +0 -1779
  151. package/story-elements/Summary/index.js +0 -2036
  152. package/story-elements/Summary/styles.arrow.css +0 -1
  153. package/story-elements/Text/index.js +0 -2293
  154. package/story-elements/Text/styles.arrow.css +0 -1
  155. package/story-elements/Video/index.js +0 -1785
  156. package/story-elements/Video/styles.arrow.css +0 -1
  157. package/story-templates/ListicleStoryTemplate/index.js +0 -8442
  158. package/story-templates/ListicleStoryTemplate/styles.arrow.css +0 -1
  159. package/story-templates/LiveBlogStoryTemplate/index.js +0 -8618
  160. package/story-templates/LiveBlogStoryTemplate/styles.arrow.css +0 -1
  161. package/story-templates/PhotoStoryTemplate/index.js +0 -8420
  162. package/story-templates/PhotoStoryTemplate/styles.arrow.css +0 -1
  163. package/story-templates/TextStoryTemplate/index.js +0 -8493
  164. package/story-templates/TextStoryTemplate/styles.arrow.css +0 -1
  165. package/story-templates/VideoStoryTemplate/index.js +0 -8352
  166. package/story-templates/VideoStoryTemplate/styles.arrow.css +0 -1
@@ -1,2955 +0,0 @@
1
- import { Link, LazyLoadImages, ResponsiveImage } from '@quintype/components';
2
- import PropTypes, { number, string, func, array, bool } from 'prop-types';
3
- import React, { useState, Suspense, lazy, useContext, createContext, useRef, useEffect } from 'react';
4
- import 'react-timeago';
5
- import 'date-fns-tz';
6
- import { useSelector } from 'react-redux';
7
-
8
- /**
9
- * Checks if `value` is classified as an `Array` object.
10
- *
11
- * @static
12
- * @memberOf _
13
- * @since 0.1.0
14
- * @category Lang
15
- * @param {*} value The value to check.
16
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
17
- * @example
18
- *
19
- * _.isArray([1, 2, 3]);
20
- * // => true
21
- *
22
- * _.isArray(document.body.children);
23
- * // => false
24
- *
25
- * _.isArray('abc');
26
- * // => false
27
- *
28
- * _.isArray(_.noop);
29
- * // => false
30
- */
31
- var isArray = Array.isArray;
32
-
33
- var isArray_1 = isArray;
34
-
35
- var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
36
-
37
- function getDefaultExportFromCjs (x) {
38
- return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
39
- }
40
-
41
- function createCommonjsModule(fn) {
42
- var module = { exports: {} };
43
- return fn(module, module.exports), module.exports;
44
- }
45
-
46
- /** Detect free variable `global` from Node.js. */
47
-
48
- var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
49
-
50
- var _freeGlobal = freeGlobal;
51
-
52
- /** Detect free variable `self`. */
53
- var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
54
-
55
- /** Used as a reference to the global object. */
56
- var root = _freeGlobal || freeSelf || Function('return this')();
57
-
58
- var _root = root;
59
-
60
- /** Built-in value references. */
61
- var Symbol$1 = _root.Symbol;
62
-
63
- var _Symbol = Symbol$1;
64
-
65
- /** Used for built-in method references. */
66
- var objectProto$4 = Object.prototype;
67
-
68
- /** Used to check objects for own properties. */
69
- var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
70
-
71
- /**
72
- * Used to resolve the
73
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
74
- * of values.
75
- */
76
- var nativeObjectToString$1 = objectProto$4.toString;
77
-
78
- /** Built-in value references. */
79
- var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined;
80
-
81
- /**
82
- * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
83
- *
84
- * @private
85
- * @param {*} value The value to query.
86
- * @returns {string} Returns the raw `toStringTag`.
87
- */
88
- function getRawTag(value) {
89
- var isOwn = hasOwnProperty$3.call(value, symToStringTag$1),
90
- tag = value[symToStringTag$1];
91
-
92
- try {
93
- value[symToStringTag$1] = undefined;
94
- var unmasked = true;
95
- } catch (e) {}
96
-
97
- var result = nativeObjectToString$1.call(value);
98
- if (unmasked) {
99
- if (isOwn) {
100
- value[symToStringTag$1] = tag;
101
- } else {
102
- delete value[symToStringTag$1];
103
- }
104
- }
105
- return result;
106
- }
107
-
108
- var _getRawTag = getRawTag;
109
-
110
- /** Used for built-in method references. */
111
- var objectProto$3 = Object.prototype;
112
-
113
- /**
114
- * Used to resolve the
115
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
116
- * of values.
117
- */
118
- var nativeObjectToString = objectProto$3.toString;
119
-
120
- /**
121
- * Converts `value` to a string using `Object.prototype.toString`.
122
- *
123
- * @private
124
- * @param {*} value The value to convert.
125
- * @returns {string} Returns the converted string.
126
- */
127
- function objectToString(value) {
128
- return nativeObjectToString.call(value);
129
- }
130
-
131
- var _objectToString = objectToString;
132
-
133
- /** `Object#toString` result references. */
134
- var nullTag = '[object Null]',
135
- undefinedTag = '[object Undefined]';
136
-
137
- /** Built-in value references. */
138
- var symToStringTag = _Symbol ? _Symbol.toStringTag : undefined;
139
-
140
- /**
141
- * The base implementation of `getTag` without fallbacks for buggy environments.
142
- *
143
- * @private
144
- * @param {*} value The value to query.
145
- * @returns {string} Returns the `toStringTag`.
146
- */
147
- function baseGetTag(value) {
148
- if (value == null) {
149
- return value === undefined ? undefinedTag : nullTag;
150
- }
151
- return (symToStringTag && symToStringTag in Object(value))
152
- ? _getRawTag(value)
153
- : _objectToString(value);
154
- }
155
-
156
- var _baseGetTag = baseGetTag;
157
-
158
- /**
159
- * Checks if `value` is object-like. A value is object-like if it's not `null`
160
- * and has a `typeof` result of "object".
161
- *
162
- * @static
163
- * @memberOf _
164
- * @since 4.0.0
165
- * @category Lang
166
- * @param {*} value The value to check.
167
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
168
- * @example
169
- *
170
- * _.isObjectLike({});
171
- * // => true
172
- *
173
- * _.isObjectLike([1, 2, 3]);
174
- * // => true
175
- *
176
- * _.isObjectLike(_.noop);
177
- * // => false
178
- *
179
- * _.isObjectLike(null);
180
- * // => false
181
- */
182
- function isObjectLike(value) {
183
- return value != null && typeof value == 'object';
184
- }
185
-
186
- var isObjectLike_1 = isObjectLike;
187
-
188
- /** `Object#toString` result references. */
189
- var symbolTag = '[object Symbol]';
190
-
191
- /**
192
- * Checks if `value` is classified as a `Symbol` primitive or object.
193
- *
194
- * @static
195
- * @memberOf _
196
- * @since 4.0.0
197
- * @category Lang
198
- * @param {*} value The value to check.
199
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
200
- * @example
201
- *
202
- * _.isSymbol(Symbol.iterator);
203
- * // => true
204
- *
205
- * _.isSymbol('abc');
206
- * // => false
207
- */
208
- function isSymbol(value) {
209
- return typeof value == 'symbol' ||
210
- (isObjectLike_1(value) && _baseGetTag(value) == symbolTag);
211
- }
212
-
213
- var isSymbol_1 = isSymbol;
214
-
215
- /** Used to match property names within property paths. */
216
- var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
217
- reIsPlainProp = /^\w*$/;
218
-
219
- /**
220
- * Checks if `value` is a property name and not a property path.
221
- *
222
- * @private
223
- * @param {*} value The value to check.
224
- * @param {Object} [object] The object to query keys on.
225
- * @returns {boolean} Returns `true` if `value` is a property name, else `false`.
226
- */
227
- function isKey(value, object) {
228
- if (isArray_1(value)) {
229
- return false;
230
- }
231
- var type = typeof value;
232
- if (type == 'number' || type == 'symbol' || type == 'boolean' ||
233
- value == null || isSymbol_1(value)) {
234
- return true;
235
- }
236
- return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||
237
- (object != null && value in Object(object));
238
- }
239
-
240
- var _isKey = isKey;
241
-
242
- /**
243
- * Checks if `value` is the
244
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
245
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
246
- *
247
- * @static
248
- * @memberOf _
249
- * @since 0.1.0
250
- * @category Lang
251
- * @param {*} value The value to check.
252
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
253
- * @example
254
- *
255
- * _.isObject({});
256
- * // => true
257
- *
258
- * _.isObject([1, 2, 3]);
259
- * // => true
260
- *
261
- * _.isObject(_.noop);
262
- * // => true
263
- *
264
- * _.isObject(null);
265
- * // => false
266
- */
267
- function isObject(value) {
268
- var type = typeof value;
269
- return value != null && (type == 'object' || type == 'function');
270
- }
271
-
272
- var isObject_1 = isObject;
273
-
274
- /** `Object#toString` result references. */
275
- var asyncTag = '[object AsyncFunction]',
276
- funcTag = '[object Function]',
277
- genTag = '[object GeneratorFunction]',
278
- proxyTag = '[object Proxy]';
279
-
280
- /**
281
- * Checks if `value` is classified as a `Function` object.
282
- *
283
- * @static
284
- * @memberOf _
285
- * @since 0.1.0
286
- * @category Lang
287
- * @param {*} value The value to check.
288
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
289
- * @example
290
- *
291
- * _.isFunction(_);
292
- * // => true
293
- *
294
- * _.isFunction(/abc/);
295
- * // => false
296
- */
297
- function isFunction(value) {
298
- if (!isObject_1(value)) {
299
- return false;
300
- }
301
- // The use of `Object#toString` avoids issues with the `typeof` operator
302
- // in Safari 9 which returns 'object' for typed arrays and other constructors.
303
- var tag = _baseGetTag(value);
304
- return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
305
- }
306
-
307
- var isFunction_1 = isFunction;
308
-
309
- /** Used to detect overreaching core-js shims. */
310
- var coreJsData = _root['__core-js_shared__'];
311
-
312
- var _coreJsData = coreJsData;
313
-
314
- /** Used to detect methods masquerading as native. */
315
- var maskSrcKey = (function() {
316
- var uid = /[^.]+$/.exec(_coreJsData && _coreJsData.keys && _coreJsData.keys.IE_PROTO || '');
317
- return uid ? ('Symbol(src)_1.' + uid) : '';
318
- }());
319
-
320
- /**
321
- * Checks if `func` has its source masked.
322
- *
323
- * @private
324
- * @param {Function} func The function to check.
325
- * @returns {boolean} Returns `true` if `func` is masked, else `false`.
326
- */
327
- function isMasked(func) {
328
- return !!maskSrcKey && (maskSrcKey in func);
329
- }
330
-
331
- var _isMasked = isMasked;
332
-
333
- /** Used for built-in method references. */
334
- var funcProto$1 = Function.prototype;
335
-
336
- /** Used to resolve the decompiled source of functions. */
337
- var funcToString$1 = funcProto$1.toString;
338
-
339
- /**
340
- * Converts `func` to its source code.
341
- *
342
- * @private
343
- * @param {Function} func The function to convert.
344
- * @returns {string} Returns the source code.
345
- */
346
- function toSource(func) {
347
- if (func != null) {
348
- try {
349
- return funcToString$1.call(func);
350
- } catch (e) {}
351
- try {
352
- return (func + '');
353
- } catch (e) {}
354
- }
355
- return '';
356
- }
357
-
358
- var _toSource = toSource;
359
-
360
- /**
361
- * Used to match `RegExp`
362
- * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
363
- */
364
- var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
365
-
366
- /** Used to detect host constructors (Safari). */
367
- var reIsHostCtor = /^\[object .+?Constructor\]$/;
368
-
369
- /** Used for built-in method references. */
370
- var funcProto = Function.prototype,
371
- objectProto$2 = Object.prototype;
372
-
373
- /** Used to resolve the decompiled source of functions. */
374
- var funcToString = funcProto.toString;
375
-
376
- /** Used to check objects for own properties. */
377
- var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
378
-
379
- /** Used to detect if a method is native. */
380
- var reIsNative = RegExp('^' +
381
- funcToString.call(hasOwnProperty$2).replace(reRegExpChar, '\\$&')
382
- .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
383
- );
384
-
385
- /**
386
- * The base implementation of `_.isNative` without bad shim checks.
387
- *
388
- * @private
389
- * @param {*} value The value to check.
390
- * @returns {boolean} Returns `true` if `value` is a native function,
391
- * else `false`.
392
- */
393
- function baseIsNative(value) {
394
- if (!isObject_1(value) || _isMasked(value)) {
395
- return false;
396
- }
397
- var pattern = isFunction_1(value) ? reIsNative : reIsHostCtor;
398
- return pattern.test(_toSource(value));
399
- }
400
-
401
- var _baseIsNative = baseIsNative;
402
-
403
- /**
404
- * Gets the value at `key` of `object`.
405
- *
406
- * @private
407
- * @param {Object} [object] The object to query.
408
- * @param {string} key The key of the property to get.
409
- * @returns {*} Returns the property value.
410
- */
411
- function getValue(object, key) {
412
- return object == null ? undefined : object[key];
413
- }
414
-
415
- var _getValue = getValue;
416
-
417
- /**
418
- * Gets the native function at `key` of `object`.
419
- *
420
- * @private
421
- * @param {Object} object The object to query.
422
- * @param {string} key The key of the method to get.
423
- * @returns {*} Returns the function if it's native, else `undefined`.
424
- */
425
- function getNative(object, key) {
426
- var value = _getValue(object, key);
427
- return _baseIsNative(value) ? value : undefined;
428
- }
429
-
430
- var _getNative = getNative;
431
-
432
- /* Built-in method references that are verified to be native. */
433
- var nativeCreate = _getNative(Object, 'create');
434
-
435
- var _nativeCreate = nativeCreate;
436
-
437
- /**
438
- * Removes all key-value entries from the hash.
439
- *
440
- * @private
441
- * @name clear
442
- * @memberOf Hash
443
- */
444
- function hashClear() {
445
- this.__data__ = _nativeCreate ? _nativeCreate(null) : {};
446
- this.size = 0;
447
- }
448
-
449
- var _hashClear = hashClear;
450
-
451
- /**
452
- * Removes `key` and its value from the hash.
453
- *
454
- * @private
455
- * @name delete
456
- * @memberOf Hash
457
- * @param {Object} hash The hash to modify.
458
- * @param {string} key The key of the value to remove.
459
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
460
- */
461
- function hashDelete(key) {
462
- var result = this.has(key) && delete this.__data__[key];
463
- this.size -= result ? 1 : 0;
464
- return result;
465
- }
466
-
467
- var _hashDelete = hashDelete;
468
-
469
- /** Used to stand-in for `undefined` hash values. */
470
- var HASH_UNDEFINED$1 = '__lodash_hash_undefined__';
471
-
472
- /** Used for built-in method references. */
473
- var objectProto$1 = Object.prototype;
474
-
475
- /** Used to check objects for own properties. */
476
- var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
477
-
478
- /**
479
- * Gets the hash value for `key`.
480
- *
481
- * @private
482
- * @name get
483
- * @memberOf Hash
484
- * @param {string} key The key of the value to get.
485
- * @returns {*} Returns the entry value.
486
- */
487
- function hashGet(key) {
488
- var data = this.__data__;
489
- if (_nativeCreate) {
490
- var result = data[key];
491
- return result === HASH_UNDEFINED$1 ? undefined : result;
492
- }
493
- return hasOwnProperty$1.call(data, key) ? data[key] : undefined;
494
- }
495
-
496
- var _hashGet = hashGet;
497
-
498
- /** Used for built-in method references. */
499
- var objectProto = Object.prototype;
500
-
501
- /** Used to check objects for own properties. */
502
- var hasOwnProperty = objectProto.hasOwnProperty;
503
-
504
- /**
505
- * Checks if a hash value for `key` exists.
506
- *
507
- * @private
508
- * @name has
509
- * @memberOf Hash
510
- * @param {string} key The key of the entry to check.
511
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
512
- */
513
- function hashHas(key) {
514
- var data = this.__data__;
515
- return _nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);
516
- }
517
-
518
- var _hashHas = hashHas;
519
-
520
- /** Used to stand-in for `undefined` hash values. */
521
- var HASH_UNDEFINED = '__lodash_hash_undefined__';
522
-
523
- /**
524
- * Sets the hash `key` to `value`.
525
- *
526
- * @private
527
- * @name set
528
- * @memberOf Hash
529
- * @param {string} key The key of the value to set.
530
- * @param {*} value The value to set.
531
- * @returns {Object} Returns the hash instance.
532
- */
533
- function hashSet(key, value) {
534
- var data = this.__data__;
535
- this.size += this.has(key) ? 0 : 1;
536
- data[key] = (_nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
537
- return this;
538
- }
539
-
540
- var _hashSet = hashSet;
541
-
542
- /**
543
- * Creates a hash object.
544
- *
545
- * @private
546
- * @constructor
547
- * @param {Array} [entries] The key-value pairs to cache.
548
- */
549
- function Hash(entries) {
550
- var index = -1,
551
- length = entries == null ? 0 : entries.length;
552
-
553
- this.clear();
554
- while (++index < length) {
555
- var entry = entries[index];
556
- this.set(entry[0], entry[1]);
557
- }
558
- }
559
-
560
- // Add methods to `Hash`.
561
- Hash.prototype.clear = _hashClear;
562
- Hash.prototype['delete'] = _hashDelete;
563
- Hash.prototype.get = _hashGet;
564
- Hash.prototype.has = _hashHas;
565
- Hash.prototype.set = _hashSet;
566
-
567
- var _Hash = Hash;
568
-
569
- /**
570
- * Removes all key-value entries from the list cache.
571
- *
572
- * @private
573
- * @name clear
574
- * @memberOf ListCache
575
- */
576
- function listCacheClear() {
577
- this.__data__ = [];
578
- this.size = 0;
579
- }
580
-
581
- var _listCacheClear = listCacheClear;
582
-
583
- /**
584
- * Performs a
585
- * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
586
- * comparison between two values to determine if they are equivalent.
587
- *
588
- * @static
589
- * @memberOf _
590
- * @since 4.0.0
591
- * @category Lang
592
- * @param {*} value The value to compare.
593
- * @param {*} other The other value to compare.
594
- * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
595
- * @example
596
- *
597
- * var object = { 'a': 1 };
598
- * var other = { 'a': 1 };
599
- *
600
- * _.eq(object, object);
601
- * // => true
602
- *
603
- * _.eq(object, other);
604
- * // => false
605
- *
606
- * _.eq('a', 'a');
607
- * // => true
608
- *
609
- * _.eq('a', Object('a'));
610
- * // => false
611
- *
612
- * _.eq(NaN, NaN);
613
- * // => true
614
- */
615
- function eq(value, other) {
616
- return value === other || (value !== value && other !== other);
617
- }
618
-
619
- var eq_1 = eq;
620
-
621
- /**
622
- * Gets the index at which the `key` is found in `array` of key-value pairs.
623
- *
624
- * @private
625
- * @param {Array} array The array to inspect.
626
- * @param {*} key The key to search for.
627
- * @returns {number} Returns the index of the matched value, else `-1`.
628
- */
629
- function assocIndexOf(array, key) {
630
- var length = array.length;
631
- while (length--) {
632
- if (eq_1(array[length][0], key)) {
633
- return length;
634
- }
635
- }
636
- return -1;
637
- }
638
-
639
- var _assocIndexOf = assocIndexOf;
640
-
641
- /** Used for built-in method references. */
642
- var arrayProto = Array.prototype;
643
-
644
- /** Built-in value references. */
645
- var splice = arrayProto.splice;
646
-
647
- /**
648
- * Removes `key` and its value from the list cache.
649
- *
650
- * @private
651
- * @name delete
652
- * @memberOf ListCache
653
- * @param {string} key The key of the value to remove.
654
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
655
- */
656
- function listCacheDelete(key) {
657
- var data = this.__data__,
658
- index = _assocIndexOf(data, key);
659
-
660
- if (index < 0) {
661
- return false;
662
- }
663
- var lastIndex = data.length - 1;
664
- if (index == lastIndex) {
665
- data.pop();
666
- } else {
667
- splice.call(data, index, 1);
668
- }
669
- --this.size;
670
- return true;
671
- }
672
-
673
- var _listCacheDelete = listCacheDelete;
674
-
675
- /**
676
- * Gets the list cache value for `key`.
677
- *
678
- * @private
679
- * @name get
680
- * @memberOf ListCache
681
- * @param {string} key The key of the value to get.
682
- * @returns {*} Returns the entry value.
683
- */
684
- function listCacheGet(key) {
685
- var data = this.__data__,
686
- index = _assocIndexOf(data, key);
687
-
688
- return index < 0 ? undefined : data[index][1];
689
- }
690
-
691
- var _listCacheGet = listCacheGet;
692
-
693
- /**
694
- * Checks if a list cache value for `key` exists.
695
- *
696
- * @private
697
- * @name has
698
- * @memberOf ListCache
699
- * @param {string} key The key of the entry to check.
700
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
701
- */
702
- function listCacheHas(key) {
703
- return _assocIndexOf(this.__data__, key) > -1;
704
- }
705
-
706
- var _listCacheHas = listCacheHas;
707
-
708
- /**
709
- * Sets the list cache `key` to `value`.
710
- *
711
- * @private
712
- * @name set
713
- * @memberOf ListCache
714
- * @param {string} key The key of the value to set.
715
- * @param {*} value The value to set.
716
- * @returns {Object} Returns the list cache instance.
717
- */
718
- function listCacheSet(key, value) {
719
- var data = this.__data__,
720
- index = _assocIndexOf(data, key);
721
-
722
- if (index < 0) {
723
- ++this.size;
724
- data.push([key, value]);
725
- } else {
726
- data[index][1] = value;
727
- }
728
- return this;
729
- }
730
-
731
- var _listCacheSet = listCacheSet;
732
-
733
- /**
734
- * Creates an list cache object.
735
- *
736
- * @private
737
- * @constructor
738
- * @param {Array} [entries] The key-value pairs to cache.
739
- */
740
- function ListCache(entries) {
741
- var index = -1,
742
- length = entries == null ? 0 : entries.length;
743
-
744
- this.clear();
745
- while (++index < length) {
746
- var entry = entries[index];
747
- this.set(entry[0], entry[1]);
748
- }
749
- }
750
-
751
- // Add methods to `ListCache`.
752
- ListCache.prototype.clear = _listCacheClear;
753
- ListCache.prototype['delete'] = _listCacheDelete;
754
- ListCache.prototype.get = _listCacheGet;
755
- ListCache.prototype.has = _listCacheHas;
756
- ListCache.prototype.set = _listCacheSet;
757
-
758
- var _ListCache = ListCache;
759
-
760
- /* Built-in method references that are verified to be native. */
761
- var Map = _getNative(_root, 'Map');
762
-
763
- var _Map = Map;
764
-
765
- /**
766
- * Removes all key-value entries from the map.
767
- *
768
- * @private
769
- * @name clear
770
- * @memberOf MapCache
771
- */
772
- function mapCacheClear() {
773
- this.size = 0;
774
- this.__data__ = {
775
- 'hash': new _Hash,
776
- 'map': new (_Map || _ListCache),
777
- 'string': new _Hash
778
- };
779
- }
780
-
781
- var _mapCacheClear = mapCacheClear;
782
-
783
- /**
784
- * Checks if `value` is suitable for use as unique object key.
785
- *
786
- * @private
787
- * @param {*} value The value to check.
788
- * @returns {boolean} Returns `true` if `value` is suitable, else `false`.
789
- */
790
- function isKeyable(value) {
791
- var type = typeof value;
792
- return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
793
- ? (value !== '__proto__')
794
- : (value === null);
795
- }
796
-
797
- var _isKeyable = isKeyable;
798
-
799
- /**
800
- * Gets the data for `map`.
801
- *
802
- * @private
803
- * @param {Object} map The map to query.
804
- * @param {string} key The reference key.
805
- * @returns {*} Returns the map data.
806
- */
807
- function getMapData(map, key) {
808
- var data = map.__data__;
809
- return _isKeyable(key)
810
- ? data[typeof key == 'string' ? 'string' : 'hash']
811
- : data.map;
812
- }
813
-
814
- var _getMapData = getMapData;
815
-
816
- /**
817
- * Removes `key` and its value from the map.
818
- *
819
- * @private
820
- * @name delete
821
- * @memberOf MapCache
822
- * @param {string} key The key of the value to remove.
823
- * @returns {boolean} Returns `true` if the entry was removed, else `false`.
824
- */
825
- function mapCacheDelete(key) {
826
- var result = _getMapData(this, key)['delete'](key);
827
- this.size -= result ? 1 : 0;
828
- return result;
829
- }
830
-
831
- var _mapCacheDelete = mapCacheDelete;
832
-
833
- /**
834
- * Gets the map value for `key`.
835
- *
836
- * @private
837
- * @name get
838
- * @memberOf MapCache
839
- * @param {string} key The key of the value to get.
840
- * @returns {*} Returns the entry value.
841
- */
842
- function mapCacheGet(key) {
843
- return _getMapData(this, key).get(key);
844
- }
845
-
846
- var _mapCacheGet = mapCacheGet;
847
-
848
- /**
849
- * Checks if a map value for `key` exists.
850
- *
851
- * @private
852
- * @name has
853
- * @memberOf MapCache
854
- * @param {string} key The key of the entry to check.
855
- * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
856
- */
857
- function mapCacheHas(key) {
858
- return _getMapData(this, key).has(key);
859
- }
860
-
861
- var _mapCacheHas = mapCacheHas;
862
-
863
- /**
864
- * Sets the map `key` to `value`.
865
- *
866
- * @private
867
- * @name set
868
- * @memberOf MapCache
869
- * @param {string} key The key of the value to set.
870
- * @param {*} value The value to set.
871
- * @returns {Object} Returns the map cache instance.
872
- */
873
- function mapCacheSet(key, value) {
874
- var data = _getMapData(this, key),
875
- size = data.size;
876
-
877
- data.set(key, value);
878
- this.size += data.size == size ? 0 : 1;
879
- return this;
880
- }
881
-
882
- var _mapCacheSet = mapCacheSet;
883
-
884
- /**
885
- * Creates a map cache object to store key-value pairs.
886
- *
887
- * @private
888
- * @constructor
889
- * @param {Array} [entries] The key-value pairs to cache.
890
- */
891
- function MapCache(entries) {
892
- var index = -1,
893
- length = entries == null ? 0 : entries.length;
894
-
895
- this.clear();
896
- while (++index < length) {
897
- var entry = entries[index];
898
- this.set(entry[0], entry[1]);
899
- }
900
- }
901
-
902
- // Add methods to `MapCache`.
903
- MapCache.prototype.clear = _mapCacheClear;
904
- MapCache.prototype['delete'] = _mapCacheDelete;
905
- MapCache.prototype.get = _mapCacheGet;
906
- MapCache.prototype.has = _mapCacheHas;
907
- MapCache.prototype.set = _mapCacheSet;
908
-
909
- var _MapCache = MapCache;
910
-
911
- /** Error message constants. */
912
- var FUNC_ERROR_TEXT = 'Expected a function';
913
-
914
- /**
915
- * Creates a function that memoizes the result of `func`. If `resolver` is
916
- * provided, it determines the cache key for storing the result based on the
917
- * arguments provided to the memoized function. By default, the first argument
918
- * provided to the memoized function is used as the map cache key. The `func`
919
- * is invoked with the `this` binding of the memoized function.
920
- *
921
- * **Note:** The cache is exposed as the `cache` property on the memoized
922
- * function. Its creation may be customized by replacing the `_.memoize.Cache`
923
- * constructor with one whose instances implement the
924
- * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)
925
- * method interface of `clear`, `delete`, `get`, `has`, and `set`.
926
- *
927
- * @static
928
- * @memberOf _
929
- * @since 0.1.0
930
- * @category Function
931
- * @param {Function} func The function to have its output memoized.
932
- * @param {Function} [resolver] The function to resolve the cache key.
933
- * @returns {Function} Returns the new memoized function.
934
- * @example
935
- *
936
- * var object = { 'a': 1, 'b': 2 };
937
- * var other = { 'c': 3, 'd': 4 };
938
- *
939
- * var values = _.memoize(_.values);
940
- * values(object);
941
- * // => [1, 2]
942
- *
943
- * values(other);
944
- * // => [3, 4]
945
- *
946
- * object.a = 2;
947
- * values(object);
948
- * // => [1, 2]
949
- *
950
- * // Modify the result cache.
951
- * values.cache.set(object, ['a', 'b']);
952
- * values(object);
953
- * // => ['a', 'b']
954
- *
955
- * // Replace `_.memoize.Cache`.
956
- * _.memoize.Cache = WeakMap;
957
- */
958
- function memoize(func, resolver) {
959
- if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {
960
- throw new TypeError(FUNC_ERROR_TEXT);
961
- }
962
- var memoized = function() {
963
- var args = arguments,
964
- key = resolver ? resolver.apply(this, args) : args[0],
965
- cache = memoized.cache;
966
-
967
- if (cache.has(key)) {
968
- return cache.get(key);
969
- }
970
- var result = func.apply(this, args);
971
- memoized.cache = cache.set(key, result) || cache;
972
- return result;
973
- };
974
- memoized.cache = new (memoize.Cache || _MapCache);
975
- return memoized;
976
- }
977
-
978
- // Expose `MapCache`.
979
- memoize.Cache = _MapCache;
980
-
981
- var memoize_1 = memoize;
982
-
983
- /** Used as the maximum memoize cache size. */
984
- var MAX_MEMOIZE_SIZE = 500;
985
-
986
- /**
987
- * A specialized version of `_.memoize` which clears the memoized function's
988
- * cache when it exceeds `MAX_MEMOIZE_SIZE`.
989
- *
990
- * @private
991
- * @param {Function} func The function to have its output memoized.
992
- * @returns {Function} Returns the new memoized function.
993
- */
994
- function memoizeCapped(func) {
995
- var result = memoize_1(func, function(key) {
996
- if (cache.size === MAX_MEMOIZE_SIZE) {
997
- cache.clear();
998
- }
999
- return key;
1000
- });
1001
-
1002
- var cache = result.cache;
1003
- return result;
1004
- }
1005
-
1006
- var _memoizeCapped = memoizeCapped;
1007
-
1008
- /** Used to match property names within property paths. */
1009
- var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
1010
-
1011
- /** Used to match backslashes in property paths. */
1012
- var reEscapeChar = /\\(\\)?/g;
1013
-
1014
- /**
1015
- * Converts `string` to a property path array.
1016
- *
1017
- * @private
1018
- * @param {string} string The string to convert.
1019
- * @returns {Array} Returns the property path array.
1020
- */
1021
- var stringToPath = _memoizeCapped(function(string) {
1022
- var result = [];
1023
- if (string.charCodeAt(0) === 46 /* . */) {
1024
- result.push('');
1025
- }
1026
- string.replace(rePropName, function(match, number, quote, subString) {
1027
- result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));
1028
- });
1029
- return result;
1030
- });
1031
-
1032
- var _stringToPath = stringToPath;
1033
-
1034
- /**
1035
- * A specialized version of `_.map` for arrays without support for iteratee
1036
- * shorthands.
1037
- *
1038
- * @private
1039
- * @param {Array} [array] The array to iterate over.
1040
- * @param {Function} iteratee The function invoked per iteration.
1041
- * @returns {Array} Returns the new mapped array.
1042
- */
1043
- function arrayMap(array, iteratee) {
1044
- var index = -1,
1045
- length = array == null ? 0 : array.length,
1046
- result = Array(length);
1047
-
1048
- while (++index < length) {
1049
- result[index] = iteratee(array[index], index, array);
1050
- }
1051
- return result;
1052
- }
1053
-
1054
- var _arrayMap = arrayMap;
1055
-
1056
- /** Used as references for various `Number` constants. */
1057
- var INFINITY$1 = 1 / 0;
1058
-
1059
- /** Used to convert symbols to primitives and strings. */
1060
- var symbolProto = _Symbol ? _Symbol.prototype : undefined,
1061
- symbolToString = symbolProto ? symbolProto.toString : undefined;
1062
-
1063
- /**
1064
- * The base implementation of `_.toString` which doesn't convert nullish
1065
- * values to empty strings.
1066
- *
1067
- * @private
1068
- * @param {*} value The value to process.
1069
- * @returns {string} Returns the string.
1070
- */
1071
- function baseToString(value) {
1072
- // Exit early for strings to avoid a performance hit in some environments.
1073
- if (typeof value == 'string') {
1074
- return value;
1075
- }
1076
- if (isArray_1(value)) {
1077
- // Recursively convert values (susceptible to call stack limits).
1078
- return _arrayMap(value, baseToString) + '';
1079
- }
1080
- if (isSymbol_1(value)) {
1081
- return symbolToString ? symbolToString.call(value) : '';
1082
- }
1083
- var result = (value + '');
1084
- return (result == '0' && (1 / value) == -INFINITY$1) ? '-0' : result;
1085
- }
1086
-
1087
- var _baseToString = baseToString;
1088
-
1089
- /**
1090
- * Converts `value` to a string. An empty string is returned for `null`
1091
- * and `undefined` values. The sign of `-0` is preserved.
1092
- *
1093
- * @static
1094
- * @memberOf _
1095
- * @since 4.0.0
1096
- * @category Lang
1097
- * @param {*} value The value to convert.
1098
- * @returns {string} Returns the converted string.
1099
- * @example
1100
- *
1101
- * _.toString(null);
1102
- * // => ''
1103
- *
1104
- * _.toString(-0);
1105
- * // => '-0'
1106
- *
1107
- * _.toString([1, 2, 3]);
1108
- * // => '1,2,3'
1109
- */
1110
- function toString(value) {
1111
- return value == null ? '' : _baseToString(value);
1112
- }
1113
-
1114
- var toString_1 = toString;
1115
-
1116
- /**
1117
- * Casts `value` to a path array if it's not one.
1118
- *
1119
- * @private
1120
- * @param {*} value The value to inspect.
1121
- * @param {Object} [object] The object to query keys on.
1122
- * @returns {Array} Returns the cast property path array.
1123
- */
1124
- function castPath(value, object) {
1125
- if (isArray_1(value)) {
1126
- return value;
1127
- }
1128
- return _isKey(value, object) ? [value] : _stringToPath(toString_1(value));
1129
- }
1130
-
1131
- var _castPath = castPath;
1132
-
1133
- /** Used as references for various `Number` constants. */
1134
- var INFINITY = 1 / 0;
1135
-
1136
- /**
1137
- * Converts `value` to a string key if it's not a string or symbol.
1138
- *
1139
- * @private
1140
- * @param {*} value The value to inspect.
1141
- * @returns {string|symbol} Returns the key.
1142
- */
1143
- function toKey(value) {
1144
- if (typeof value == 'string' || isSymbol_1(value)) {
1145
- return value;
1146
- }
1147
- var result = (value + '');
1148
- return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
1149
- }
1150
-
1151
- var _toKey = toKey;
1152
-
1153
- /**
1154
- * The base implementation of `_.get` without support for default values.
1155
- *
1156
- * @private
1157
- * @param {Object} object The object to query.
1158
- * @param {Array|string} path The path of the property to get.
1159
- * @returns {*} Returns the resolved value.
1160
- */
1161
- function baseGet(object, path) {
1162
- path = _castPath(path, object);
1163
-
1164
- var index = 0,
1165
- length = path.length;
1166
-
1167
- while (object != null && index < length) {
1168
- object = object[_toKey(path[index++])];
1169
- }
1170
- return (index && index == length) ? object : undefined;
1171
- }
1172
-
1173
- var _baseGet = baseGet;
1174
-
1175
- /**
1176
- * Gets the value at `path` of `object`. If the resolved value is
1177
- * `undefined`, the `defaultValue` is returned in its place.
1178
- *
1179
- * @static
1180
- * @memberOf _
1181
- * @since 3.7.0
1182
- * @category Object
1183
- * @param {Object} object The object to query.
1184
- * @param {Array|string} path The path of the property to get.
1185
- * @param {*} [defaultValue] The value returned for `undefined` resolved values.
1186
- * @returns {*} Returns the resolved value.
1187
- * @example
1188
- *
1189
- * var object = { 'a': [{ 'b': { 'c': 3 } }] };
1190
- *
1191
- * _.get(object, 'a[0].b.c');
1192
- * // => 3
1193
- *
1194
- * _.get(object, ['a', '0', 'b', 'c']);
1195
- * // => 3
1196
- *
1197
- * _.get(object, 'a.b.c', 'default');
1198
- * // => 'default'
1199
- */
1200
- function get(object, path, defaultValue) {
1201
- var result = object == null ? undefined : _baseGet(object, path);
1202
- return result === undefined ? defaultValue : result;
1203
- }
1204
-
1205
- var get_1 = get;
1206
-
1207
- /**
1208
- * Copyright (c) 2014-present, Facebook, Inc.
1209
- *
1210
- * This source code is licensed under the MIT license found in the
1211
- * LICENSE file in the root directory of this source tree.
1212
- */
1213
-
1214
- createCommonjsModule(function (module) {
1215
- var runtime = (function (exports) {
1216
-
1217
- var Op = Object.prototype;
1218
- var hasOwn = Op.hasOwnProperty;
1219
- var undefined$1; // More compressible than void 0.
1220
- var $Symbol = typeof Symbol === "function" ? Symbol : {};
1221
- var iteratorSymbol = $Symbol.iterator || "@@iterator";
1222
- var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
1223
- var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
1224
-
1225
- function define(obj, key, value) {
1226
- Object.defineProperty(obj, key, {
1227
- value: value,
1228
- enumerable: true,
1229
- configurable: true,
1230
- writable: true
1231
- });
1232
- return obj[key];
1233
- }
1234
- try {
1235
- // IE 8 has a broken Object.defineProperty that only works on DOM objects.
1236
- define({}, "");
1237
- } catch (err) {
1238
- define = function(obj, key, value) {
1239
- return obj[key] = value;
1240
- };
1241
- }
1242
-
1243
- function wrap(innerFn, outerFn, self, tryLocsList) {
1244
- // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
1245
- var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
1246
- var generator = Object.create(protoGenerator.prototype);
1247
- var context = new Context(tryLocsList || []);
1248
-
1249
- // The ._invoke method unifies the implementations of the .next,
1250
- // .throw, and .return methods.
1251
- generator._invoke = makeInvokeMethod(innerFn, self, context);
1252
-
1253
- return generator;
1254
- }
1255
- exports.wrap = wrap;
1256
-
1257
- // Try/catch helper to minimize deoptimizations. Returns a completion
1258
- // record like context.tryEntries[i].completion. This interface could
1259
- // have been (and was previously) designed to take a closure to be
1260
- // invoked without arguments, but in all the cases we care about we
1261
- // already have an existing method we want to call, so there's no need
1262
- // to create a new function object. We can even get away with assuming
1263
- // the method takes exactly one argument, since that happens to be true
1264
- // in every case, so we don't have to touch the arguments object. The
1265
- // only additional allocation required is the completion record, which
1266
- // has a stable shape and so hopefully should be cheap to allocate.
1267
- function tryCatch(fn, obj, arg) {
1268
- try {
1269
- return { type: "normal", arg: fn.call(obj, arg) };
1270
- } catch (err) {
1271
- return { type: "throw", arg: err };
1272
- }
1273
- }
1274
-
1275
- var GenStateSuspendedStart = "suspendedStart";
1276
- var GenStateSuspendedYield = "suspendedYield";
1277
- var GenStateExecuting = "executing";
1278
- var GenStateCompleted = "completed";
1279
-
1280
- // Returning this object from the innerFn has the same effect as
1281
- // breaking out of the dispatch switch statement.
1282
- var ContinueSentinel = {};
1283
-
1284
- // Dummy constructor functions that we use as the .constructor and
1285
- // .constructor.prototype properties for functions that return Generator
1286
- // objects. For full spec compliance, you may wish to configure your
1287
- // minifier not to mangle the names of these two functions.
1288
- function Generator() {}
1289
- function GeneratorFunction() {}
1290
- function GeneratorFunctionPrototype() {}
1291
-
1292
- // This is a polyfill for %IteratorPrototype% for environments that
1293
- // don't natively support it.
1294
- var IteratorPrototype = {};
1295
- define(IteratorPrototype, iteratorSymbol, function () {
1296
- return this;
1297
- });
1298
-
1299
- var getProto = Object.getPrototypeOf;
1300
- var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
1301
- if (NativeIteratorPrototype &&
1302
- NativeIteratorPrototype !== Op &&
1303
- hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
1304
- // This environment has a native %IteratorPrototype%; use it instead
1305
- // of the polyfill.
1306
- IteratorPrototype = NativeIteratorPrototype;
1307
- }
1308
-
1309
- var Gp = GeneratorFunctionPrototype.prototype =
1310
- Generator.prototype = Object.create(IteratorPrototype);
1311
- GeneratorFunction.prototype = GeneratorFunctionPrototype;
1312
- define(Gp, "constructor", GeneratorFunctionPrototype);
1313
- define(GeneratorFunctionPrototype, "constructor", GeneratorFunction);
1314
- GeneratorFunction.displayName = define(
1315
- GeneratorFunctionPrototype,
1316
- toStringTagSymbol,
1317
- "GeneratorFunction"
1318
- );
1319
-
1320
- // Helper for defining the .next, .throw, and .return methods of the
1321
- // Iterator interface in terms of a single ._invoke method.
1322
- function defineIteratorMethods(prototype) {
1323
- ["next", "throw", "return"].forEach(function(method) {
1324
- define(prototype, method, function(arg) {
1325
- return this._invoke(method, arg);
1326
- });
1327
- });
1328
- }
1329
-
1330
- exports.isGeneratorFunction = function(genFun) {
1331
- var ctor = typeof genFun === "function" && genFun.constructor;
1332
- return ctor
1333
- ? ctor === GeneratorFunction ||
1334
- // For the native GeneratorFunction constructor, the best we can
1335
- // do is to check its .name property.
1336
- (ctor.displayName || ctor.name) === "GeneratorFunction"
1337
- : false;
1338
- };
1339
-
1340
- exports.mark = function(genFun) {
1341
- if (Object.setPrototypeOf) {
1342
- Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
1343
- } else {
1344
- genFun.__proto__ = GeneratorFunctionPrototype;
1345
- define(genFun, toStringTagSymbol, "GeneratorFunction");
1346
- }
1347
- genFun.prototype = Object.create(Gp);
1348
- return genFun;
1349
- };
1350
-
1351
- // Within the body of any async function, `await x` is transformed to
1352
- // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
1353
- // `hasOwn.call(value, "__await")` to determine if the yielded value is
1354
- // meant to be awaited.
1355
- exports.awrap = function(arg) {
1356
- return { __await: arg };
1357
- };
1358
-
1359
- function AsyncIterator(generator, PromiseImpl) {
1360
- function invoke(method, arg, resolve, reject) {
1361
- var record = tryCatch(generator[method], generator, arg);
1362
- if (record.type === "throw") {
1363
- reject(record.arg);
1364
- } else {
1365
- var result = record.arg;
1366
- var value = result.value;
1367
- if (value &&
1368
- typeof value === "object" &&
1369
- hasOwn.call(value, "__await")) {
1370
- return PromiseImpl.resolve(value.__await).then(function(value) {
1371
- invoke("next", value, resolve, reject);
1372
- }, function(err) {
1373
- invoke("throw", err, resolve, reject);
1374
- });
1375
- }
1376
-
1377
- return PromiseImpl.resolve(value).then(function(unwrapped) {
1378
- // When a yielded Promise is resolved, its final value becomes
1379
- // the .value of the Promise<{value,done}> result for the
1380
- // current iteration.
1381
- result.value = unwrapped;
1382
- resolve(result);
1383
- }, function(error) {
1384
- // If a rejected Promise was yielded, throw the rejection back
1385
- // into the async generator function so it can be handled there.
1386
- return invoke("throw", error, resolve, reject);
1387
- });
1388
- }
1389
- }
1390
-
1391
- var previousPromise;
1392
-
1393
- function enqueue(method, arg) {
1394
- function callInvokeWithMethodAndArg() {
1395
- return new PromiseImpl(function(resolve, reject) {
1396
- invoke(method, arg, resolve, reject);
1397
- });
1398
- }
1399
-
1400
- return previousPromise =
1401
- // If enqueue has been called before, then we want to wait until
1402
- // all previous Promises have been resolved before calling invoke,
1403
- // so that results are always delivered in the correct order. If
1404
- // enqueue has not been called before, then it is important to
1405
- // call invoke immediately, without waiting on a callback to fire,
1406
- // so that the async generator function has the opportunity to do
1407
- // any necessary setup in a predictable way. This predictability
1408
- // is why the Promise constructor synchronously invokes its
1409
- // executor callback, and why async functions synchronously
1410
- // execute code before the first await. Since we implement simple
1411
- // async functions in terms of async generators, it is especially
1412
- // important to get this right, even though it requires care.
1413
- previousPromise ? previousPromise.then(
1414
- callInvokeWithMethodAndArg,
1415
- // Avoid propagating failures to Promises returned by later
1416
- // invocations of the iterator.
1417
- callInvokeWithMethodAndArg
1418
- ) : callInvokeWithMethodAndArg();
1419
- }
1420
-
1421
- // Define the unified helper method that is used to implement .next,
1422
- // .throw, and .return (see defineIteratorMethods).
1423
- this._invoke = enqueue;
1424
- }
1425
-
1426
- defineIteratorMethods(AsyncIterator.prototype);
1427
- define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
1428
- return this;
1429
- });
1430
- exports.AsyncIterator = AsyncIterator;
1431
-
1432
- // Note that simple async functions are implemented on top of
1433
- // AsyncIterator objects; they just return a Promise for the value of
1434
- // the final result produced by the iterator.
1435
- exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
1436
- if (PromiseImpl === void 0) PromiseImpl = Promise;
1437
-
1438
- var iter = new AsyncIterator(
1439
- wrap(innerFn, outerFn, self, tryLocsList),
1440
- PromiseImpl
1441
- );
1442
-
1443
- return exports.isGeneratorFunction(outerFn)
1444
- ? iter // If outerFn is a generator, return the full iterator.
1445
- : iter.next().then(function(result) {
1446
- return result.done ? result.value : iter.next();
1447
- });
1448
- };
1449
-
1450
- function makeInvokeMethod(innerFn, self, context) {
1451
- var state = GenStateSuspendedStart;
1452
-
1453
- return function invoke(method, arg) {
1454
- if (state === GenStateExecuting) {
1455
- throw new Error("Generator is already running");
1456
- }
1457
-
1458
- if (state === GenStateCompleted) {
1459
- if (method === "throw") {
1460
- throw arg;
1461
- }
1462
-
1463
- // Be forgiving, per 25.3.3.3.3 of the spec:
1464
- // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
1465
- return doneResult();
1466
- }
1467
-
1468
- context.method = method;
1469
- context.arg = arg;
1470
-
1471
- while (true) {
1472
- var delegate = context.delegate;
1473
- if (delegate) {
1474
- var delegateResult = maybeInvokeDelegate(delegate, context);
1475
- if (delegateResult) {
1476
- if (delegateResult === ContinueSentinel) continue;
1477
- return delegateResult;
1478
- }
1479
- }
1480
-
1481
- if (context.method === "next") {
1482
- // Setting context._sent for legacy support of Babel's
1483
- // function.sent implementation.
1484
- context.sent = context._sent = context.arg;
1485
-
1486
- } else if (context.method === "throw") {
1487
- if (state === GenStateSuspendedStart) {
1488
- state = GenStateCompleted;
1489
- throw context.arg;
1490
- }
1491
-
1492
- context.dispatchException(context.arg);
1493
-
1494
- } else if (context.method === "return") {
1495
- context.abrupt("return", context.arg);
1496
- }
1497
-
1498
- state = GenStateExecuting;
1499
-
1500
- var record = tryCatch(innerFn, self, context);
1501
- if (record.type === "normal") {
1502
- // If an exception is thrown from innerFn, we leave state ===
1503
- // GenStateExecuting and loop back for another invocation.
1504
- state = context.done
1505
- ? GenStateCompleted
1506
- : GenStateSuspendedYield;
1507
-
1508
- if (record.arg === ContinueSentinel) {
1509
- continue;
1510
- }
1511
-
1512
- return {
1513
- value: record.arg,
1514
- done: context.done
1515
- };
1516
-
1517
- } else if (record.type === "throw") {
1518
- state = GenStateCompleted;
1519
- // Dispatch the exception by looping back around to the
1520
- // context.dispatchException(context.arg) call above.
1521
- context.method = "throw";
1522
- context.arg = record.arg;
1523
- }
1524
- }
1525
- };
1526
- }
1527
-
1528
- // Call delegate.iterator[context.method](context.arg) and handle the
1529
- // result, either by returning a { value, done } result from the
1530
- // delegate iterator, or by modifying context.method and context.arg,
1531
- // setting context.delegate to null, and returning the ContinueSentinel.
1532
- function maybeInvokeDelegate(delegate, context) {
1533
- var method = delegate.iterator[context.method];
1534
- if (method === undefined$1) {
1535
- // A .throw or .return when the delegate iterator has no .throw
1536
- // method always terminates the yield* loop.
1537
- context.delegate = null;
1538
-
1539
- if (context.method === "throw") {
1540
- // Note: ["return"] must be used for ES3 parsing compatibility.
1541
- if (delegate.iterator["return"]) {
1542
- // If the delegate iterator has a return method, give it a
1543
- // chance to clean up.
1544
- context.method = "return";
1545
- context.arg = undefined$1;
1546
- maybeInvokeDelegate(delegate, context);
1547
-
1548
- if (context.method === "throw") {
1549
- // If maybeInvokeDelegate(context) changed context.method from
1550
- // "return" to "throw", let that override the TypeError below.
1551
- return ContinueSentinel;
1552
- }
1553
- }
1554
-
1555
- context.method = "throw";
1556
- context.arg = new TypeError(
1557
- "The iterator does not provide a 'throw' method");
1558
- }
1559
-
1560
- return ContinueSentinel;
1561
- }
1562
-
1563
- var record = tryCatch(method, delegate.iterator, context.arg);
1564
-
1565
- if (record.type === "throw") {
1566
- context.method = "throw";
1567
- context.arg = record.arg;
1568
- context.delegate = null;
1569
- return ContinueSentinel;
1570
- }
1571
-
1572
- var info = record.arg;
1573
-
1574
- if (! info) {
1575
- context.method = "throw";
1576
- context.arg = new TypeError("iterator result is not an object");
1577
- context.delegate = null;
1578
- return ContinueSentinel;
1579
- }
1580
-
1581
- if (info.done) {
1582
- // Assign the result of the finished delegate to the temporary
1583
- // variable specified by delegate.resultName (see delegateYield).
1584
- context[delegate.resultName] = info.value;
1585
-
1586
- // Resume execution at the desired location (see delegateYield).
1587
- context.next = delegate.nextLoc;
1588
-
1589
- // If context.method was "throw" but the delegate handled the
1590
- // exception, let the outer generator proceed normally. If
1591
- // context.method was "next", forget context.arg since it has been
1592
- // "consumed" by the delegate iterator. If context.method was
1593
- // "return", allow the original .return call to continue in the
1594
- // outer generator.
1595
- if (context.method !== "return") {
1596
- context.method = "next";
1597
- context.arg = undefined$1;
1598
- }
1599
-
1600
- } else {
1601
- // Re-yield the result returned by the delegate method.
1602
- return info;
1603
- }
1604
-
1605
- // The delegate iterator is finished, so forget it and continue with
1606
- // the outer generator.
1607
- context.delegate = null;
1608
- return ContinueSentinel;
1609
- }
1610
-
1611
- // Define Generator.prototype.{next,throw,return} in terms of the
1612
- // unified ._invoke helper method.
1613
- defineIteratorMethods(Gp);
1614
-
1615
- define(Gp, toStringTagSymbol, "Generator");
1616
-
1617
- // A Generator should always return itself as the iterator object when the
1618
- // @@iterator function is called on it. Some browsers' implementations of the
1619
- // iterator prototype chain incorrectly implement this, causing the Generator
1620
- // object to not be returned from this call. This ensures that doesn't happen.
1621
- // See https://github.com/facebook/regenerator/issues/274 for more details.
1622
- define(Gp, iteratorSymbol, function() {
1623
- return this;
1624
- });
1625
-
1626
- define(Gp, "toString", function() {
1627
- return "[object Generator]";
1628
- });
1629
-
1630
- function pushTryEntry(locs) {
1631
- var entry = { tryLoc: locs[0] };
1632
-
1633
- if (1 in locs) {
1634
- entry.catchLoc = locs[1];
1635
- }
1636
-
1637
- if (2 in locs) {
1638
- entry.finallyLoc = locs[2];
1639
- entry.afterLoc = locs[3];
1640
- }
1641
-
1642
- this.tryEntries.push(entry);
1643
- }
1644
-
1645
- function resetTryEntry(entry) {
1646
- var record = entry.completion || {};
1647
- record.type = "normal";
1648
- delete record.arg;
1649
- entry.completion = record;
1650
- }
1651
-
1652
- function Context(tryLocsList) {
1653
- // The root entry object (effectively a try statement without a catch
1654
- // or a finally block) gives us a place to store values thrown from
1655
- // locations where there is no enclosing try statement.
1656
- this.tryEntries = [{ tryLoc: "root" }];
1657
- tryLocsList.forEach(pushTryEntry, this);
1658
- this.reset(true);
1659
- }
1660
-
1661
- exports.keys = function(object) {
1662
- var keys = [];
1663
- for (var key in object) {
1664
- keys.push(key);
1665
- }
1666
- keys.reverse();
1667
-
1668
- // Rather than returning an object with a next method, we keep
1669
- // things simple and return the next function itself.
1670
- return function next() {
1671
- while (keys.length) {
1672
- var key = keys.pop();
1673
- if (key in object) {
1674
- next.value = key;
1675
- next.done = false;
1676
- return next;
1677
- }
1678
- }
1679
-
1680
- // To avoid creating an additional object, we just hang the .value
1681
- // and .done properties off the next function object itself. This
1682
- // also ensures that the minifier will not anonymize the function.
1683
- next.done = true;
1684
- return next;
1685
- };
1686
- };
1687
-
1688
- function values(iterable) {
1689
- if (iterable) {
1690
- var iteratorMethod = iterable[iteratorSymbol];
1691
- if (iteratorMethod) {
1692
- return iteratorMethod.call(iterable);
1693
- }
1694
-
1695
- if (typeof iterable.next === "function") {
1696
- return iterable;
1697
- }
1698
-
1699
- if (!isNaN(iterable.length)) {
1700
- var i = -1, next = function next() {
1701
- while (++i < iterable.length) {
1702
- if (hasOwn.call(iterable, i)) {
1703
- next.value = iterable[i];
1704
- next.done = false;
1705
- return next;
1706
- }
1707
- }
1708
-
1709
- next.value = undefined$1;
1710
- next.done = true;
1711
-
1712
- return next;
1713
- };
1714
-
1715
- return next.next = next;
1716
- }
1717
- }
1718
-
1719
- // Return an iterator with no values.
1720
- return { next: doneResult };
1721
- }
1722
- exports.values = values;
1723
-
1724
- function doneResult() {
1725
- return { value: undefined$1, done: true };
1726
- }
1727
-
1728
- Context.prototype = {
1729
- constructor: Context,
1730
-
1731
- reset: function(skipTempReset) {
1732
- this.prev = 0;
1733
- this.next = 0;
1734
- // Resetting context._sent for legacy support of Babel's
1735
- // function.sent implementation.
1736
- this.sent = this._sent = undefined$1;
1737
- this.done = false;
1738
- this.delegate = null;
1739
-
1740
- this.method = "next";
1741
- this.arg = undefined$1;
1742
-
1743
- this.tryEntries.forEach(resetTryEntry);
1744
-
1745
- if (!skipTempReset) {
1746
- for (var name in this) {
1747
- // Not sure about the optimal order of these conditions:
1748
- if (name.charAt(0) === "t" &&
1749
- hasOwn.call(this, name) &&
1750
- !isNaN(+name.slice(1))) {
1751
- this[name] = undefined$1;
1752
- }
1753
- }
1754
- }
1755
- },
1756
-
1757
- stop: function() {
1758
- this.done = true;
1759
-
1760
- var rootEntry = this.tryEntries[0];
1761
- var rootRecord = rootEntry.completion;
1762
- if (rootRecord.type === "throw") {
1763
- throw rootRecord.arg;
1764
- }
1765
-
1766
- return this.rval;
1767
- },
1768
-
1769
- dispatchException: function(exception) {
1770
- if (this.done) {
1771
- throw exception;
1772
- }
1773
-
1774
- var context = this;
1775
- function handle(loc, caught) {
1776
- record.type = "throw";
1777
- record.arg = exception;
1778
- context.next = loc;
1779
-
1780
- if (caught) {
1781
- // If the dispatched exception was caught by a catch block,
1782
- // then let that catch block handle the exception normally.
1783
- context.method = "next";
1784
- context.arg = undefined$1;
1785
- }
1786
-
1787
- return !! caught;
1788
- }
1789
-
1790
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
1791
- var entry = this.tryEntries[i];
1792
- var record = entry.completion;
1793
-
1794
- if (entry.tryLoc === "root") {
1795
- // Exception thrown outside of any try block that could handle
1796
- // it, so set the completion value of the entire function to
1797
- // throw the exception.
1798
- return handle("end");
1799
- }
1800
-
1801
- if (entry.tryLoc <= this.prev) {
1802
- var hasCatch = hasOwn.call(entry, "catchLoc");
1803
- var hasFinally = hasOwn.call(entry, "finallyLoc");
1804
-
1805
- if (hasCatch && hasFinally) {
1806
- if (this.prev < entry.catchLoc) {
1807
- return handle(entry.catchLoc, true);
1808
- } else if (this.prev < entry.finallyLoc) {
1809
- return handle(entry.finallyLoc);
1810
- }
1811
-
1812
- } else if (hasCatch) {
1813
- if (this.prev < entry.catchLoc) {
1814
- return handle(entry.catchLoc, true);
1815
- }
1816
-
1817
- } else if (hasFinally) {
1818
- if (this.prev < entry.finallyLoc) {
1819
- return handle(entry.finallyLoc);
1820
- }
1821
-
1822
- } else {
1823
- throw new Error("try statement without catch or finally");
1824
- }
1825
- }
1826
- }
1827
- },
1828
-
1829
- abrupt: function(type, arg) {
1830
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
1831
- var entry = this.tryEntries[i];
1832
- if (entry.tryLoc <= this.prev &&
1833
- hasOwn.call(entry, "finallyLoc") &&
1834
- this.prev < entry.finallyLoc) {
1835
- var finallyEntry = entry;
1836
- break;
1837
- }
1838
- }
1839
-
1840
- if (finallyEntry &&
1841
- (type === "break" ||
1842
- type === "continue") &&
1843
- finallyEntry.tryLoc <= arg &&
1844
- arg <= finallyEntry.finallyLoc) {
1845
- // Ignore the finally entry if control is not jumping to a
1846
- // location outside the try/catch block.
1847
- finallyEntry = null;
1848
- }
1849
-
1850
- var record = finallyEntry ? finallyEntry.completion : {};
1851
- record.type = type;
1852
- record.arg = arg;
1853
-
1854
- if (finallyEntry) {
1855
- this.method = "next";
1856
- this.next = finallyEntry.finallyLoc;
1857
- return ContinueSentinel;
1858
- }
1859
-
1860
- return this.complete(record);
1861
- },
1862
-
1863
- complete: function(record, afterLoc) {
1864
- if (record.type === "throw") {
1865
- throw record.arg;
1866
- }
1867
-
1868
- if (record.type === "break" ||
1869
- record.type === "continue") {
1870
- this.next = record.arg;
1871
- } else if (record.type === "return") {
1872
- this.rval = this.arg = record.arg;
1873
- this.method = "return";
1874
- this.next = "end";
1875
- } else if (record.type === "normal" && afterLoc) {
1876
- this.next = afterLoc;
1877
- }
1878
-
1879
- return ContinueSentinel;
1880
- },
1881
-
1882
- finish: function(finallyLoc) {
1883
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
1884
- var entry = this.tryEntries[i];
1885
- if (entry.finallyLoc === finallyLoc) {
1886
- this.complete(entry.completion, entry.afterLoc);
1887
- resetTryEntry(entry);
1888
- return ContinueSentinel;
1889
- }
1890
- }
1891
- },
1892
-
1893
- "catch": function(tryLoc) {
1894
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
1895
- var entry = this.tryEntries[i];
1896
- if (entry.tryLoc === tryLoc) {
1897
- var record = entry.completion;
1898
- if (record.type === "throw") {
1899
- var thrown = record.arg;
1900
- resetTryEntry(entry);
1901
- }
1902
- return thrown;
1903
- }
1904
- }
1905
-
1906
- // The context.catch method must only be called with a location
1907
- // argument that corresponds to a known catch block.
1908
- throw new Error("illegal catch attempt");
1909
- },
1910
-
1911
- delegateYield: function(iterable, resultName, nextLoc) {
1912
- this.delegate = {
1913
- iterator: values(iterable),
1914
- resultName: resultName,
1915
- nextLoc: nextLoc
1916
- };
1917
-
1918
- if (this.method === "next") {
1919
- // Deliberately forget the last sent value so that we don't
1920
- // accidentally pass it on to the delegate.
1921
- this.arg = undefined$1;
1922
- }
1923
-
1924
- return ContinueSentinel;
1925
- }
1926
- };
1927
-
1928
- // Regardless of whether this script is executing as a CommonJS module
1929
- // or not, return the runtime object so that we can declare the variable
1930
- // regeneratorRuntime in the outer scope, which allows this module to be
1931
- // injected easily by `bin/regenerator --include-runtime script.js`.
1932
- return exports;
1933
-
1934
- }(
1935
- // If this script is executing as a CommonJS module, use module.exports
1936
- // as the regeneratorRuntime namespace. Otherwise create a new empty
1937
- // object. Either way, the resulting object will be used to initialize
1938
- // the regeneratorRuntime variable at the top of this file.
1939
- module.exports
1940
- ));
1941
-
1942
- try {
1943
- regeneratorRuntime = runtime;
1944
- } catch (accidentalStrictMode) {
1945
- // This module should not be running in strict mode, so the above
1946
- // assignment should always work unless something is misconfigured. Just
1947
- // in case runtime.js accidentally runs in strict mode, in modern engines
1948
- // we can explicitly access globalThis. In older engines we can escape
1949
- // strict mode using a global Function call. This could conceivably fail
1950
- // if a Content Security Policy forbids using Function, but in that case
1951
- // the proper solution is to fix the accidental strict mode problem. If
1952
- // you've misconfigured your bundler to force strict mode and applied a
1953
- // CSP to forbid Function, and you're not willing to fix either of those
1954
- // problems, please detail your unique predicament in a GitHub issue.
1955
- if (typeof globalThis === "object") {
1956
- globalThis.regeneratorRuntime = runtime;
1957
- } else {
1958
- Function("r", "regeneratorRuntime = r")(runtime);
1959
- }
1960
- }
1961
- });
1962
-
1963
- var hexToRGB = function hexToRGB(hex) {
1964
- var r = parseInt(hex.slice(1, 3), 16);
1965
- var g = parseInt(hex.slice(3, 5), 16);
1966
- var b = parseInt(hex.slice(5, 7), 16);
1967
- return {
1968
- r: r,
1969
- g: g,
1970
- b: b
1971
- };
1972
- };
1973
- var getLuminanceOfColor = function getLuminanceOfColor(hex) {
1974
- var _hexToRGB = hexToRGB(hex),
1975
- r = _hexToRGB.r,
1976
- g = _hexToRGB.g,
1977
- b = _hexToRGB.b;
1978
-
1979
- return r * 0.299 + g * 0.587 + b * 0.114;
1980
- };
1981
- var rgbToHex = function rgbToHex() {
1982
- var color = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "rgba(255, 255, 255, 0)";
1983
- var rgba = color.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i);
1984
- return rgba && rgba.length === 4 ? "#" + ("0" + parseInt(rgba[1], 10).toString(16)).slice(-2) + ("0" + parseInt(rgba[2], 10).toString(16)).slice(-2) + ("0" + parseInt(rgba[3], 10).toString(16)).slice(-2) : color;
1985
- };
1986
- var getTextColor = function getTextColor() {
1987
- var theme = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "rgb(255,255,255)";
1988
- var isRegexCheck = /^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(theme);
1989
- var getHexValue = !isRegexCheck ? rgbToHex(theme) : theme;
1990
- var textColor = getLuminanceOfColor(getHexValue) < 155 ? "light" : "dark";
1991
- return textColor;
1992
- };
1993
- PropTypes.shape({
1994
- "sketches-host": PropTypes.string,
1995
- "cdn-name": PropTypes.string,
1996
- "cdn-image": PropTypes.string
1997
- });
1998
- var shapeStory = PropTypes.shape({
1999
- headline: PropTypes.string,
2000
- "last-published-at": PropTypes.number,
2001
- subheadline: PropTypes.string
2002
- });
2003
-
2004
- function _extends() {
2005
- _extends = Object.assign || function (target) {
2006
- for (var i = 1; i < arguments.length; i++) {
2007
- var source = arguments[i];
2008
-
2009
- for (var key in source) {
2010
- if (Object.prototype.hasOwnProperty.call(source, key)) {
2011
- target[key] = source[key];
2012
- }
2013
- }
2014
- }
2015
-
2016
- return target;
2017
- };
2018
-
2019
- return _extends.apply(this, arguments);
2020
- }
2021
-
2022
- function _defineProperty(obj, key, value) {
2023
- if (key in obj) {
2024
- Object.defineProperty(obj, key, {
2025
- value: value,
2026
- enumerable: true,
2027
- configurable: true,
2028
- writable: true
2029
- });
2030
- } else {
2031
- obj[key] = value;
2032
- }
2033
-
2034
- return obj;
2035
- }
2036
-
2037
- function _arrayWithHoles(arr) {
2038
- if (Array.isArray(arr)) return arr;
2039
- }
2040
-
2041
- function _iterableToArrayLimit(arr, i) {
2042
- var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
2043
-
2044
- if (_i == null) return;
2045
- var _arr = [];
2046
- var _n = true;
2047
- var _d = false;
2048
-
2049
- var _s, _e;
2050
-
2051
- try {
2052
- for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
2053
- _arr.push(_s.value);
2054
-
2055
- if (i && _arr.length === i) break;
2056
- }
2057
- } catch (err) {
2058
- _d = true;
2059
- _e = err;
2060
- } finally {
2061
- try {
2062
- if (!_n && _i["return"] != null) _i["return"]();
2063
- } finally {
2064
- if (_d) throw _e;
2065
- }
2066
- }
2067
-
2068
- return _arr;
2069
- }
2070
-
2071
- function _arrayLikeToArray(arr, len) {
2072
- if (len == null || len > arr.length) len = arr.length;
2073
-
2074
- for (var i = 0, arr2 = new Array(len); i < len; i++) {
2075
- arr2[i] = arr[i];
2076
- }
2077
-
2078
- return arr2;
2079
- }
2080
-
2081
- function _unsupportedIterableToArray(o, minLen) {
2082
- if (!o) return;
2083
- if (typeof o === "string") return _arrayLikeToArray(o, minLen);
2084
- var n = Object.prototype.toString.call(o).slice(8, -1);
2085
- if (n === "Object" && o.constructor) n = o.constructor.name;
2086
- if (n === "Map" || n === "Set") return Array.from(o);
2087
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
2088
- }
2089
-
2090
- function _nonIterableRest() {
2091
- throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
2092
- }
2093
-
2094
- function _slicedToArray(arr, i) {
2095
- return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
2096
- }
2097
-
2098
- var Loading = function Loading(_ref) {
2099
- _ref.width;
2100
- _ref.height;
2101
- _ref.iconColor;
2102
- return /*#__PURE__*/React.createElement("div", {
2103
- className: "loading-m_loading-indicator__2Dlst"
2104
- }, /*#__PURE__*/React.createElement("svg", {
2105
- width: "40",
2106
- height: "40",
2107
- xmlns: "http://www.w3.org/2000/svg",
2108
- viewBox: "0 0 100 100",
2109
- preserveAspectRatio: "xMidYMid"
2110
- }, /*#__PURE__*/React.createElement("circle", {
2111
- cx: "84",
2112
- cy: "50",
2113
- r: "0",
2114
- fill: "currentColor"
2115
- }, /*#__PURE__*/React.createElement("animate", {
2116
- attributeName: "r",
2117
- values: "10;0;0;0;0",
2118
- keyTimes: "0;0.25;0.5;0.75;1",
2119
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2120
- calcMode: "spline",
2121
- dur: "2s",
2122
- repeatCount: "indefinite",
2123
- begin: "0s"
2124
- }), /*#__PURE__*/React.createElement("animate", {
2125
- attributeName: "cx",
2126
- values: "84;84;84;84;84",
2127
- keyTimes: "0;0.25;0.5;0.75;1",
2128
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2129
- calcMode: "spline",
2130
- dur: "2s",
2131
- repeatCount: "indefinite",
2132
- begin: "0s"
2133
- })), /*#__PURE__*/React.createElement("circle", {
2134
- cx: "84",
2135
- cy: "50",
2136
- r: ".709",
2137
- fill: "currentColor"
2138
- }, /*#__PURE__*/React.createElement("animate", {
2139
- attributeName: "r",
2140
- values: "0;10;10;10;0",
2141
- keyTimes: "0;0.25;0.5;0.75;1",
2142
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2143
- calcMode: "spline",
2144
- dur: "2s",
2145
- repeatCount: "indefinite",
2146
- begin: "-1s"
2147
- }), /*#__PURE__*/React.createElement("animate", {
2148
- attributeName: "cx",
2149
- values: "16;16;50;84;84",
2150
- keyTimes: "0;0.25;0.5;0.75;1",
2151
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2152
- calcMode: "spline",
2153
- dur: "2s",
2154
- repeatCount: "indefinite",
2155
- begin: "-1s"
2156
- })), /*#__PURE__*/React.createElement("circle", {
2157
- cx: "81.59",
2158
- cy: "50",
2159
- r: "10",
2160
- fill: "currentColor"
2161
- }, /*#__PURE__*/React.createElement("animate", {
2162
- attributeName: "r",
2163
- values: "0;10;10;10;0",
2164
- keyTimes: "0;0.25;0.5;0.75;1",
2165
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2166
- calcMode: "spline",
2167
- dur: "2s",
2168
- repeatCount: "indefinite",
2169
- begin: "-0.5s"
2170
- }), /*#__PURE__*/React.createElement("animate", {
2171
- attributeName: "cx",
2172
- values: "16;16;50;84;84",
2173
- keyTimes: "0;0.25;0.5;0.75;1",
2174
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2175
- calcMode: "spline",
2176
- dur: "2s",
2177
- repeatCount: "indefinite",
2178
- begin: "-0.5s"
2179
- })), /*#__PURE__*/React.createElement("circle", {
2180
- cx: "47.59",
2181
- cy: "50",
2182
- r: "10",
2183
- fill: "currentColor"
2184
- }, /*#__PURE__*/React.createElement("animate", {
2185
- attributeName: "r",
2186
- values: "0;10;10;10;0",
2187
- keyTimes: "0;0.25;0.5;0.75;1",
2188
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2189
- calcMode: "spline",
2190
- dur: "2s",
2191
- repeatCount: "indefinite",
2192
- begin: "0s"
2193
- }), /*#__PURE__*/React.createElement("animate", {
2194
- attributeName: "cx",
2195
- values: "16;16;50;84;84",
2196
- keyTimes: "0;0.25;0.5;0.75;1",
2197
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2198
- calcMode: "spline",
2199
- dur: "2s",
2200
- repeatCount: "indefinite",
2201
- begin: "0s"
2202
- })), /*#__PURE__*/React.createElement("circle", {
2203
- cx: "16",
2204
- cy: "50",
2205
- r: "9.291",
2206
- fill: "currentColor"
2207
- }, /*#__PURE__*/React.createElement("animate", {
2208
- attributeName: "r",
2209
- values: "0;0;10;10;10",
2210
- keyTimes: "0;0.25;0.5;0.75;1",
2211
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2212
- calcMode: "spline",
2213
- dur: "2s",
2214
- repeatCount: "indefinite",
2215
- begin: "0s"
2216
- }), /*#__PURE__*/React.createElement("animate", {
2217
- attributeName: "cx",
2218
- values: "16;16;16;50;84",
2219
- keyTimes: "0;0.25;0.5;0.75;1",
2220
- keySplines: "0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1;0 0.5 0.5 1",
2221
- calcMode: "spline",
2222
- dur: "2s",
2223
- repeatCount: "indefinite",
2224
- begin: "0s"
2225
- }))));
2226
- };
2227
- Loading.propTypes = {
2228
- width: PropTypes.object,
2229
- height: PropTypes.object,
2230
- iconColor: PropTypes.object
2231
- };
2232
-
2233
- var HyperLinkIcon = function HyperLinkIcon() {
2234
- return /*#__PURE__*/React.createElement("svg", {
2235
- xmlns: "http://www.w3.org/2000/svg",
2236
- width: "36",
2237
- height: "28"
2238
- }, /*#__PURE__*/React.createElement("g", {
2239
- fill: "none",
2240
- fillRule: "evenodd"
2241
- }, /*#__PURE__*/React.createElement("rect", {
2242
- width: "36",
2243
- height: "28",
2244
- fill: "#3D6FCF",
2245
- rx: "4"
2246
- }), /*#__PURE__*/React.createElement("path", {
2247
- stroke: "#FFF",
2248
- strokeLinecap: "round",
2249
- strokeLinejoin: "round",
2250
- strokeWidth: "2",
2251
- d: "M22 14.667v4c0 .736-.597 1.333-1.333 1.333h-7.334A1.333 1.333 0 0112 18.667v-7.334c0-.736.597-1.333 1.333-1.333h4M20 8h4v4m-7.333 3.333L24 8"
2252
- })));
2253
- };
2254
-
2255
- var HyperLink = function HyperLink(_ref) {
2256
- var _ref$hyperLink = _ref.hyperLink,
2257
- hyperLink = _ref$hyperLink === void 0 ? "" : _ref$hyperLink;
2258
- if (!hyperLink) return null;
2259
- return /*#__PURE__*/React.createElement(Link, {
2260
- href: hyperLink,
2261
- "aria-label": "hyperlink-button",
2262
- className: "arr--hyperlink-button hyperlink-m_hyperlink-button__1CqWx",
2263
- target: "_blank",
2264
- rel: "noopener noreferrer"
2265
- }, /*#__PURE__*/React.createElement(HyperLinkIcon, null));
2266
- };
2267
- HyperLink.propTypes = {
2268
- hyperLink: PropTypes.string
2269
- };
2270
-
2271
- 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; }
2272
-
2273
- 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; }
2274
- var Lightbox = /*#__PURE__*/lazy(function () {
2275
- return import('react-image-lightbox');
2276
- });
2277
- var FullScreenImages = function FullScreenImages(_ref) {
2278
- var _ref$imageSlug = _ref.imageSlug,
2279
- imageSlug = _ref$imageSlug === void 0 ? "" : _ref$imageSlug,
2280
- template = _ref.template,
2281
- _ref$element = _ref.element,
2282
- element = _ref$element === void 0 ? {} : _ref$element,
2283
- props = _ref.props;
2284
- var cdnImage = useSelector(function (state) {
2285
- return get_1(state, ["qt", "config", "cdn-image"]);
2286
- });
2287
-
2288
- var _useState = useState(0),
2289
- _useState2 = _slicedToArray(_useState, 2),
2290
- photoIndex = _useState2[0],
2291
- handleImage = _useState2[1];
2292
-
2293
- var _useState3 = useState(false),
2294
- _useState4 = _slicedToArray(_useState3, 2),
2295
- isOpen = _useState4[0],
2296
- handleOpen = _useState4[1];
2297
-
2298
- var deviceWidth = get_1(global, ["innerWidth"], 0);
2299
- var hyperlinks = get_1(element, ["story-elements"], []).map(function (image) {
2300
- return image.hyperlink;
2301
- });
2302
- var imageUrlList = [];
2303
-
2304
- if (!imageSlug) {
2305
- imageUrlList = get_1(element, ["story-elements"], []).map(function (image) {
2306
- return "//".concat(cdnImage, "/").concat(image["image-s3-key"], "?w=").concat(deviceWidth);
2307
- });
2308
- }
2309
-
2310
- var onClickHandler = function onClickHandler(index) {
2311
- handleOpen(true);
2312
- handleImage(index);
2313
- };
2314
-
2315
- var onClickKey = imageSlug ? "onClick" : "onClickHandler";
2316
- var imageUrlListLength = imageUrlList.length;
2317
-
2318
- var onMoveNext = function onMoveNext(imageUrlListLength) {
2319
- var next = (photoIndex + 1) % imageUrlListLength;
2320
- handleImage(next);
2321
- };
2322
-
2323
- var onMovePrev = function onMovePrev(imageUrlListLength) {
2324
- var prev = (photoIndex + imageUrlListLength - 1) % imageUrlListLength;
2325
- handleImage(prev);
2326
- };
2327
-
2328
- var onClose = function onClose() {
2329
- handleImage(0);
2330
- handleOpen(false);
2331
- };
2332
-
2333
- var getHyperLink = function getHyperLink() {
2334
- if (element.hyperlink || hyperlinks[photoIndex]) {
2335
- return /*#__PURE__*/React.createElement(HyperLink, {
2336
- hyperLink: element.hyperlink || hyperlinks[photoIndex]
2337
- });
2338
- }
2339
-
2340
- return null;
2341
- };
2342
-
2343
- var lightboxProps = imageSlug ? {
2344
- mainSrc: "//".concat(cdnImage, "/").concat(imageSlug, "?w=").concat(deviceWidth),
2345
- toolbarButtons: [getHyperLink()]
2346
- } : {
2347
- mainSrc: imageUrlList[photoIndex],
2348
- nextSrc: imageUrlList[(photoIndex + 1) % imageUrlListLength],
2349
- prevSrc: imageUrlList[(photoIndex + imageUrlListLength - 1) % imageUrlListLength],
2350
- onMoveNextRequest: function onMoveNextRequest() {
2351
- return onMoveNext(imageUrlListLength);
2352
- },
2353
- onMovePrevRequest: function onMovePrevRequest() {
2354
- return onMovePrev(imageUrlListLength);
2355
- },
2356
- toolbarButtons: [getHyperLink()]
2357
- };
2358
-
2359
- var LoadingScreen = function LoadingScreen() {
2360
- return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Loading, null));
2361
- };
2362
-
2363
- return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(template, _objectSpread(_defineProperty({}, onClickKey, onClickHandler), props)), isOpen ? /*#__PURE__*/React.createElement(Suspense, {
2364
- fallback: /*#__PURE__*/React.createElement(LoadingScreen, null)
2365
- }, /*#__PURE__*/React.createElement(Lightbox, _extends({
2366
- wrapperClassName: "arr--image-lightbox",
2367
- onCloseRequest: onClose
2368
- }, lightboxProps))) : null);
2369
- };
2370
- FullScreenImages.propTypes = {
2371
- imageSlug: PropTypes.string,
2372
- template: PropTypes.func,
2373
- element: PropTypes.shape({
2374
- "story-elements": PropTypes.array
2375
- }),
2376
- props: PropTypes.object
2377
- };
2378
-
2379
- function _objectWithoutPropertiesLoose(source, excluded) {
2380
- if (source == null) return {};
2381
- var target = {};
2382
- var sourceKeys = Object.keys(source);
2383
- var key, i;
2384
-
2385
- for (i = 0; i < sourceKeys.length; i++) {
2386
- key = sourceKeys[i];
2387
- if (excluded.indexOf(key) >= 0) continue;
2388
- target[key] = source[key];
2389
- }
2390
-
2391
- return target;
2392
- }
2393
-
2394
- function _objectWithoutProperties(source, excluded) {
2395
- if (source == null) return {};
2396
- var target = _objectWithoutPropertiesLoose(source, excluded);
2397
- var key, i;
2398
-
2399
- if (Object.getOwnPropertySymbols) {
2400
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
2401
-
2402
- for (i = 0; i < sourceSymbolKeys.length; i++) {
2403
- key = sourceSymbolKeys[i];
2404
- if (excluded.indexOf(key) >= 0) continue;
2405
- if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
2406
- target[key] = source[key];
2407
- }
2408
- }
2409
-
2410
- return target;
2411
- }
2412
-
2413
- var _excluded = ["element", "render"];
2414
- var withElementWrapper = function withElementWrapper(StoryElement) {
2415
- return function (props) {
2416
- var element = props.element,
2417
- render = props.render,
2418
- restProps = _objectWithoutProperties(props, _excluded);
2419
-
2420
- if (!element) return null;
2421
- if (render && typeof render === "function") return render(props);
2422
- return /*#__PURE__*/React.createElement(StoryElement, _extends({}, restProps, {
2423
- element: element
2424
- }));
2425
- };
2426
- };
2427
- withElementWrapper.propTypes = {
2428
- StoryElement: PropTypes.element
2429
- };
2430
-
2431
- var optionsDefaults_1 = createCommonjsModule(function (module, exports) {
2432
-
2433
- Object.defineProperty(exports, "__esModule", {
2434
- value: true
2435
- });
2436
- exports["default"] = void 0;
2437
- var optionsDefaults = {
2438
- attributeNames: {
2439
- styleName: 'className'
2440
- },
2441
- generateScopedName: '[path]___[name]__[local]___[hash:base64:5]',
2442
- handleMissingStyleName: 'throw'
2443
- };
2444
- var _default = optionsDefaults;
2445
- exports["default"] = _default;
2446
-
2447
-
2448
- });
2449
-
2450
- var getClassName = createCommonjsModule(function (module, exports) {
2451
-
2452
- Object.defineProperty(exports, "__esModule", {
2453
- value: true
2454
- });
2455
- exports["default"] = void 0;
2456
-
2457
- var _optionsDefaults = _interopRequireDefault(optionsDefaults_1);
2458
-
2459
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
2460
-
2461
- var isNamespacedStyleName = function isNamespacedStyleName(styleName) {
2462
- return styleName.indexOf('.') !== -1;
2463
- };
2464
-
2465
- var handleError = function handleError(message, handleMissingStyleName) {
2466
- if (handleMissingStyleName === 'throw') {
2467
- throw new Error(message);
2468
- } else if (handleMissingStyleName === 'warn') {
2469
- // eslint-disable-next-line no-console
2470
- console.warn(message);
2471
- }
2472
-
2473
- return null;
2474
- };
2475
-
2476
- var getClassNameForNamespacedStyleName = function getClassNameForNamespacedStyleName(styleName, styleModuleImportMap, handleMissingStyleNameOption) {
2477
- // Note:
2478
- // Do not use the desctructing syntax with Babel.
2479
- // Desctructing adds _slicedToArray helper.
2480
- var styleNameParts = styleName.split('.');
2481
- var importName = styleNameParts[0];
2482
- var moduleName = styleNameParts[1];
2483
- var handleMissingStyleName = handleMissingStyleNameOption || _optionsDefaults["default"].handleMissingStyleName;
2484
-
2485
- if (!moduleName) {
2486
- return handleError('Invalid style name: ' + styleName, handleMissingStyleName);
2487
- }
2488
-
2489
- if (!styleModuleImportMap[importName]) {
2490
- return handleError('CSS module import does not exist: ' + importName, handleMissingStyleName);
2491
- }
2492
-
2493
- if (!styleModuleImportMap[importName][moduleName]) {
2494
- return handleError('CSS module does not exist: ' + moduleName, handleMissingStyleName);
2495
- }
2496
-
2497
- return styleModuleImportMap[importName][moduleName];
2498
- };
2499
-
2500
- var getClassNameFromMultipleImports = function getClassNameFromMultipleImports(styleName, styleModuleImportMap, handleMissingStyleNameOption) {
2501
- var handleMissingStyleName = handleMissingStyleNameOption || _optionsDefaults["default"].handleMissingStyleName;
2502
- var importKeysWithMatches = Object.keys(styleModuleImportMap).map(function (importKey) {
2503
- return styleModuleImportMap[importKey][styleName] && importKey;
2504
- }).filter(function (importKey) {
2505
- return importKey;
2506
- });
2507
-
2508
- if (importKeysWithMatches.length > 1) {
2509
- 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');
2510
- }
2511
-
2512
- if (importKeysWithMatches.length === 0) {
2513
- return handleError('Could not resolve the styleName \'' + styleName + '\'.', handleMissingStyleName);
2514
- }
2515
-
2516
- return styleModuleImportMap[importKeysWithMatches[0]][styleName];
2517
- };
2518
-
2519
- var _default = function _default(styleNameValue, styleModuleImportMap, options) {
2520
- var styleModuleImportMapKeys = Object.keys(styleModuleImportMap);
2521
-
2522
- var _ref = options || {},
2523
- _ref$handleMissingSty = _ref.handleMissingStyleName,
2524
- handleMissingStyleName = _ref$handleMissingSty === void 0 ? _optionsDefaults["default"].handleMissingStyleName : _ref$handleMissingSty,
2525
- _ref$autoResolveMulti = _ref.autoResolveMultipleImports,
2526
- autoResolveMultipleImports = _ref$autoResolveMulti === void 0 ? _optionsDefaults["default"].autoResolveMultipleImports : _ref$autoResolveMulti;
2527
-
2528
- if (!styleNameValue) {
2529
- return '';
2530
- }
2531
-
2532
- return styleNameValue.split(' ').filter(function (styleName) {
2533
- return styleName;
2534
- }).map(function (styleName) {
2535
- if (isNamespacedStyleName(styleName)) {
2536
- return getClassNameForNamespacedStyleName(styleName, styleModuleImportMap, handleMissingStyleName);
2537
- }
2538
-
2539
- if (styleModuleImportMapKeys.length === 0) {
2540
- throw new Error('Cannot use styleName attribute for style name \'' + styleName + '\' without importing at least one stylesheet.');
2541
- }
2542
-
2543
- if (styleModuleImportMapKeys.length > 1) {
2544
- if (!autoResolveMultipleImports) {
2545
- throw new Error('Cannot use anonymous style name \'' + styleName + '\' with more than one stylesheet import without setting \'autoResolveMultipleImports\' to true.');
2546
- }
2547
-
2548
- return getClassNameFromMultipleImports(styleName, styleModuleImportMap, handleMissingStyleName);
2549
- }
2550
-
2551
- var styleModuleMap = styleModuleImportMap[styleModuleImportMapKeys[0]];
2552
-
2553
- if (!styleModuleMap[styleName]) {
2554
- return handleError('Could not resolve the styleName \'' + styleName + '\'.', handleMissingStyleName);
2555
- }
2556
-
2557
- return styleModuleMap[styleName];
2558
- }).filter(function (className) {
2559
- // Remove any styles which could not be found (if handleMissingStyleName === 'ignore')
2560
- return className;
2561
- }).join(' ');
2562
- };
2563
-
2564
- exports["default"] = _default;
2565
-
2566
-
2567
- });
2568
-
2569
- var _getClassName = /*@__PURE__*/getDefaultExportFromCjs(getClassName);
2570
-
2571
- var LeftArrow = function LeftArrow(_ref) {
2572
- var _ref$color = _ref.color,
2573
- color = _ref$color === void 0 ? "#333" : _ref$color;
2574
- return /*#__PURE__*/React.createElement("svg", {
2575
- xmlns: "http://www.w3.org/2000/svg",
2576
- width: "16",
2577
- height: "16",
2578
- viewBox: "0 0 10 16"
2579
- }, /*#__PURE__*/React.createElement("g", {
2580
- fill: "none",
2581
- fillRule: "nonzero"
2582
- }, /*#__PURE__*/React.createElement("path", {
2583
- d: "M17 20H-7V-4h24z",
2584
- opacity: ".384"
2585
- }), /*#__PURE__*/React.createElement("path", {
2586
- stroke: color,
2587
- d: "M9 16L1 8l8-8"
2588
- })));
2589
- };
2590
- LeftArrow.propTypes = {
2591
- color: PropTypes.string
2592
- };
2593
-
2594
- var RightArrow = function RightArrow(_ref) {
2595
- var _ref$color = _ref.color,
2596
- color = _ref$color === void 0 ? "#333" : _ref$color;
2597
- return /*#__PURE__*/React.createElement("svg", {
2598
- xmlns: "http://www.w3.org/2000/svg",
2599
- width: "16",
2600
- height: "16",
2601
- viewBox: "0 0 10 16"
2602
- }, /*#__PURE__*/React.createElement("g", {
2603
- fill: "none",
2604
- fillRule: "nonzero"
2605
- }, /*#__PURE__*/React.createElement("path", {
2606
- d: "M-7-4h24v24H-7z",
2607
- opacity: ".384"
2608
- }), /*#__PURE__*/React.createElement("path", {
2609
- stroke: color,
2610
- d: "M1 0l8 8-8 8"
2611
- })));
2612
- };
2613
- RightArrow.propTypes = {
2614
- color: PropTypes.string
2615
- };
2616
-
2617
- var StateContext = /*#__PURE__*/createContext(); // eslint-disable-next-line react/display-name
2618
- var useStateValue = function useStateValue() {
2619
- return useContext(StateContext);
2620
- };
2621
-
2622
- var _styleModuleImportMap$1 = {
2623
- "./slider-arrow.m.css": {
2624
- "arrow": "slider-arrow-m_arrow__1eBUU",
2625
- "left-arrow-dark": "slider-arrow-m_left-arrow-dark__3mTJS",
2626
- "right-arrow-dark": "slider-arrow-m_right-arrow-dark__3hWZe",
2627
- "left-arrow-light": "slider-arrow-m_left-arrow-light__2ipUK",
2628
- "right-arrow-light": "slider-arrow-m_right-arrow-light__3omMU",
2629
- "left-arrow-ltr": "slider-arrow-m_left-arrow-ltr__1ngNF",
2630
- "right-arrow-ltr": "slider-arrow-m_right-arrow-ltr__2svWX",
2631
- "left-arrow-rtl": "slider-arrow-m_left-arrow-rtl__2ynyn",
2632
- "right-arrow-rtl": "slider-arrow-m_right-arrow-rtl__1GjPz"
2633
- }
2634
- };
2635
- var SliderArrow = function SliderArrow(_ref) {
2636
- var selectedIndex = _ref.selectedIndex,
2637
- previousClick = _ref.previousClick,
2638
- nextClick = _ref.nextClick,
2639
- noOfItems = _ref.noOfItems,
2640
- perView = _ref.perView,
2641
- languageDirection = _ref.languageDirection;
2642
-
2643
- if (noOfItems < 1) {
2644
- return null;
2645
- }
2646
-
2647
- var config = useStateValue() || {};
2648
- var textColor = getTextColor(config.theme);
2649
-
2650
- var rightArrowView = function rightArrowView() {
2651
- if (selectedIndex >= noOfItems - perView) return false;
2652
- return true;
2653
- };
2654
-
2655
- var getLeftArrowClassName = languageDirection === "rtl" ? "left-arrow-rtl" : "left-arrow-ltr";
2656
- var getRightArrowClassName = languageDirection === "rtl" ? "right-arrow-rtl" : "right-arrow-ltr";
2657
- return /*#__PURE__*/React.createElement(React.Fragment, null, selectedIndex !== 0 ? /*#__PURE__*/React.createElement("button", {
2658
- onClick: previousClick,
2659
- className: ("left-arrow ".concat(getLeftArrowClassName) ? "left-arrow ".concat(getLeftArrowClassName) + " " : "") + _getClassName("arrow left-arrow-".concat(textColor, " ").concat(getLeftArrowClassName), _styleModuleImportMap$1)
2660
- }, /*#__PURE__*/React.createElement(LeftArrow, {
2661
- color: textColor === "dark" ? "#fff" : "#333"
2662
- })) : null, selectedIndex < noOfItems - 1 && rightArrowView() ? /*#__PURE__*/React.createElement("button", {
2663
- onClick: nextClick,
2664
- className: ("right-arrow ".concat(getRightArrowClassName) ? "right-arrow ".concat(getRightArrowClassName) + " " : "") + _getClassName("arrow right-arrow-".concat(textColor, " ").concat(getRightArrowClassName), _styleModuleImportMap$1)
2665
- }, /*#__PURE__*/React.createElement(RightArrow, {
2666
- color: textColor === "dark" ? "#fff" : "#333"
2667
- })) : null);
2668
- };
2669
- SliderArrow.propTypes = {
2670
- noOfItems: number,
2671
- perView: number,
2672
- slideIndicator: string,
2673
- previousClick: func,
2674
- nextClick: func,
2675
- selectedIndex: number,
2676
- languageDirection: string
2677
- };
2678
-
2679
- var _styleModuleImportMap = {
2680
- "./slider-indicator.m.css": {
2681
- "indicators": "slider-indicator-m_indicators__3MNXc",
2682
- "indicator": "slider-indicator-m_indicator__gTv3x",
2683
- "indicator-button": "slider-indicator-m_indicator-button__1e82r",
2684
- "indicator-dots": "slider-indicator-m_indicator-dots__2TR3H",
2685
- "indicator-dots-dark": "slider-indicator-m_indicator-dots-dark__sGrev",
2686
- "indicator-dots-light": "slider-indicator-m_indicator-dots-light__2nPn-",
2687
- "indicator-dashes": "slider-indicator-m_indicator-dashes__DyNCE",
2688
- "indicator-dashes-dark": "slider-indicator-m_indicator-dashes-dark__VrqJI",
2689
- "indicator-dashes-light": "slider-indicator-m_indicator-dashes-light__34ESx"
2690
- }
2691
- };
2692
- var SliderIndicator = function SliderIndicator(_ref) {
2693
- var indicatorItems = _ref.indicatorItems,
2694
- indicatorClick = _ref.indicatorClick,
2695
- selectedIndex = _ref.selectedIndex,
2696
- indicatorType = _ref.indicatorType;
2697
-
2698
- if (indicatorItems.length < 1) {
2699
- return null;
2700
- }
2701
-
2702
- var config = useStateValue() || {};
2703
- var textColor = getTextColor(config.theme);
2704
- return /*#__PURE__*/React.createElement("ul", {
2705
- className: "slider-indicators slider-indicator-m_indicators__3MNXc"
2706
- }, indicatorItems.map(function (_, index) {
2707
- return /*#__PURE__*/React.createElement("li", {
2708
- key: "slider-".concat(index),
2709
- className: "indicator slider-indicator-m_indicator__gTv3x",
2710
- onClick: function onClick(e) {
2711
- return indicatorClick(e, index);
2712
- }
2713
- }, /*#__PURE__*/React.createElement("button", {
2714
- "aria-pressed": selectedIndex === index ? "true" : "false",
2715
- className: ("indicator-button indicator-".concat(indicatorType) ? "indicator-button indicator-".concat(indicatorType) + " " : "") + _getClassName("indicator-button indicator-".concat(indicatorType, " indicator-").concat(indicatorType, "-").concat(textColor), _styleModuleImportMap)
2716
- }));
2717
- }));
2718
- };
2719
- SliderIndicator.propTypes = {
2720
- indicatorItems: array,
2721
- perView: number,
2722
- indicatorType: string,
2723
- indicatorClick: func,
2724
- selectedIndex: number
2725
- };
2726
-
2727
- var smoothScroll = function smoothScroll(node, topOrLeft, horizontal) {
2728
- var _node$scrollTo;
2729
-
2730
- node.scrollTo((_node$scrollTo = {}, _defineProperty(_node$scrollTo, horizontal ? "left" : "top", topOrLeft), _defineProperty(_node$scrollTo, "behavior", "smooth"), _node$scrollTo));
2731
- };
2732
-
2733
- var updateItemSelection = function updateItemSelection(index, languageDirection, scroller, noOfItems) {
2734
- var getScrollValue = Math.floor(scroller.current.scrollWidth * (index / noOfItems));
2735
- var scrollValue = languageDirection === "rtl" ? getScrollValue * -1 : getScrollValue;
2736
- smoothScroll(scroller.current, scrollValue, true);
2737
- };
2738
-
2739
- var setIndicatorValue = function setIndicatorValue(func, ms) {
2740
- var timeout;
2741
- return function () {
2742
- clearTimeout(timeout);
2743
- timeout = setTimeout(function () {
2744
- timeout = null;
2745
- func();
2746
- }, ms);
2747
- };
2748
- };
2749
-
2750
- var ScrollSnap = function ScrollSnap(_ref) {
2751
- var children = _ref.children,
2752
- isArrow = _ref.isArrow,
2753
- interval = _ref.interval,
2754
- isInfinite = _ref.isInfinite,
2755
- pauseOnHover = _ref.pauseOnHover,
2756
- perView = _ref.perView,
2757
- slideIndicator = _ref.slideIndicator;
2758
-
2759
- var _useState = useState(0),
2760
- _useState2 = _slicedToArray(_useState, 2),
2761
- selectedIndex = _useState2[0],
2762
- setSelectedIndex = _useState2[1];
2763
-
2764
- var _useState3 = useState(false),
2765
- _useState4 = _slicedToArray(_useState3, 2),
2766
- autoScroll = _useState4[0],
2767
- setAutoScroll = _useState4[1];
2768
-
2769
- var languageDirection = useSelector(function (state) {
2770
- return get_1(state, ["qt", "config", "language", "direction"], "ltr");
2771
- });
2772
- var noOfItems = children ? children.length : 0;
2773
- var scroller = useRef(null);
2774
- var numberOfIndicatorsToShow = children.length - (perView - 1);
2775
- var indicatorItems = children.slice(0, numberOfIndicatorsToShow);
2776
- useEffect(function () {
2777
- if (scroller.current) {
2778
- scroller.current.addEventListener("scroll", setIndicatorValue(function () {
2779
- var value = Math.round(scroller.current.scrollLeft / scroller.current.scrollWidth * noOfItems);
2780
- setSelectedIndex(Math.abs(value));
2781
- }, 150)); // For Default Selection if selectedIndex is not 0 then manually select it
2782
-
2783
- if (selectedIndex !== 0) {
2784
- updateItemSelection(selectedIndex);
2785
- }
2786
- }
2787
-
2788
- return function () {
2789
- scroller.current.removeEventListener("scroll", setIndicatorValue);
2790
- };
2791
- }, []); // Infinite scroll
2792
-
2793
- useEffect(function () {
2794
- if (isInfinite && !autoScroll) {
2795
- var timer = setInterval(function () {
2796
- infiniteScroll();
2797
- }, interval);
2798
- return function () {
2799
- clearInterval(timer);
2800
- };
2801
- }
2802
- }, [isInfinite, autoScroll]);
2803
-
2804
- var infiniteScroll = function infiniteScroll() {
2805
- setSelectedIndex(function (value) {
2806
- var newIndex = value === noOfItems - perView ? 0 : value + 1;
2807
- updateItemSelection(newIndex, languageDirection, scroller, noOfItems);
2808
- return newIndex;
2809
- });
2810
- };
2811
-
2812
- var pauseAutoPlay = function pauseAutoPlay() {
2813
- pauseOnHover && setAutoScroll(!autoScroll);
2814
- };
2815
-
2816
- var indicatorClick = function indicatorClick(e, newIndex) {
2817
- e.preventDefault();
2818
- e.stopPropagation();
2819
- setSelectedIndex(newIndex);
2820
- updateItemSelection(newIndex, languageDirection, scroller, noOfItems);
2821
- };
2822
-
2823
- var nextClick = function nextClick(e) {
2824
- e.preventDefault();
2825
- e.stopPropagation();
2826
-
2827
- if (selectedIndex < noOfItems) {
2828
- var newIndex = selectedIndex + 1;
2829
- setSelectedIndex(newIndex);
2830
- updateItemSelection(newIndex, languageDirection, scroller, noOfItems);
2831
- }
2832
- };
2833
-
2834
- var previousClick = function previousClick(e) {
2835
- e.preventDefault();
2836
- e.stopPropagation();
2837
- var newIndex = selectedIndex - 1;
2838
- setSelectedIndex(newIndex);
2839
- updateItemSelection(newIndex, languageDirection, scroller, noOfItems);
2840
- };
2841
-
2842
- return /*#__PURE__*/React.createElement("div", {
2843
- className: "scroll-snap-container"
2844
- }, /*#__PURE__*/React.createElement("div", {
2845
- className: "scroll-snap-wrapper scroll-snap-m_wrapper__1Rz9v",
2846
- onMouseEnter: pauseAutoPlay,
2847
- onMouseLeave: pauseAutoPlay
2848
- }, /*#__PURE__*/React.createElement("div", {
2849
- ref: scroller,
2850
- className: "scroll-snap-carousel scroll-snap-m_carousel__2m3cg"
2851
- }, children), isArrow && /*#__PURE__*/React.createElement(SliderArrow, {
2852
- noOfItems: noOfItems,
2853
- perView: perView,
2854
- previousClick: previousClick,
2855
- nextClick: nextClick,
2856
- selectedIndex: selectedIndex,
2857
- languageDirection: languageDirection
2858
- })), children.length > perView && slideIndicator !== "none" && /*#__PURE__*/React.createElement(SliderIndicator, {
2859
- indicatorItems: indicatorItems,
2860
- indicatorClick: indicatorClick,
2861
- selectedIndex: selectedIndex,
2862
- indicatorType: slideIndicator
2863
- }));
2864
- };
2865
- ScrollSnap.defaultProps = {
2866
- isArrow: true,
2867
- isInfinite: false,
2868
- interval: 4000,
2869
- pauseOnHover: true,
2870
- perView: 1,
2871
- slideIndicator: "dots"
2872
- };
2873
- ScrollSnap.propTypes = {
2874
- children: array.isRequired,
2875
- isArrow: bool,
2876
- isInfinite: bool,
2877
- interval: number,
2878
- pauseOnHover: bool,
2879
- perView: number,
2880
- slideIndicator: string
2881
- };
2882
-
2883
- var ImageSlideshowBase = function ImageSlideshowBase(props) {
2884
- if (!props.element) return null;
2885
-
2886
- var Slide = function Slide(image, index, onClickHandler) {
2887
- var id = image.id,
2888
- imageS3Key = image["image-s3-key"],
2889
- metadata = image.metadata,
2890
- title = image.title,
2891
- _image$hyperlink = image.hyperlink,
2892
- hyperlink = _image$hyperlink === void 0 ? "" : _image$hyperlink;
2893
- return /*#__PURE__*/React.createElement("div", {
2894
- className: "image-slideshow-m_slide__3URCC",
2895
- key: id
2896
- }, /*#__PURE__*/React.createElement("figure", {
2897
- key: id,
2898
- className: "image-slideshow-m_image-container__2VTEK",
2899
- onClick: function onClick() {
2900
- return onClickHandler(index);
2901
- }
2902
- }, /*#__PURE__*/React.createElement(LazyLoadImages, {
2903
- margin: "0px"
2904
- }, /*#__PURE__*/React.createElement(ResponsiveImage, {
2905
- slug: imageS3Key,
2906
- metadata: metadata,
2907
- "aspect-ratio": [16, 9],
2908
- defaultWidth: 480,
2909
- widths: [250, 480, 640],
2910
- imgParams: {
2911
- auto: ["format", "compress"]
2912
- },
2913
- className: "image-slideshow-m_image__1p1fO",
2914
- alt: title
2915
- }))), hyperlink && /*#__PURE__*/React.createElement(HyperLink, {
2916
- hyperLink: hyperlink
2917
- }), /*#__PURE__*/React.createElement("p", {
2918
- className: "image-slideshow-m_caption__mWpmc",
2919
- dangerouslySetInnerHTML: {
2920
- __html: title
2921
- }
2922
- }));
2923
- };
2924
-
2925
- var ImageSlideshowTemplate = function ImageSlideshowTemplate(_ref) {
2926
- var onClickHandler = _ref.onClickHandler;
2927
- var storyElements = get_1(props, ["element", "story-elements"], []);
2928
- return /*#__PURE__*/React.createElement("div", {
2929
- className: "arr--image-slideshow-element image-slideshow-m_slideshow__3jRFX",
2930
- "data-test-id": "image-slideshow"
2931
- }, /*#__PURE__*/React.createElement(ScrollSnap, {
2932
- slideIndicator: "none"
2933
- }, storyElements.map(function (image, index) {
2934
- return Slide(image, index, onClickHandler);
2935
- })));
2936
- };
2937
-
2938
- ImageSlideshowTemplate.propTypes = {
2939
- onClickHandler: PropTypes.func
2940
- };
2941
- return /*#__PURE__*/React.createElement(FullScreenImages, {
2942
- template: ImageSlideshowTemplate,
2943
- element: props.element
2944
- });
2945
- };
2946
-
2947
- ImageSlideshowBase.propTypes = {
2948
- element: PropTypes.shape({
2949
- "story-elements": PropTypes.array
2950
- }),
2951
- story: shapeStory
2952
- };
2953
- var ImageSlideshow = withElementWrapper(ImageSlideshowBase);
2954
-
2955
- export { ImageSlideshow };