@mjhls/mjh-framework 1.0.645 → 1.0.647

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 (86) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/AD.js +1 -1
  3. package/dist/cjs/AD300x250.js +2 -2
  4. package/dist/cjs/AD300x250x600.js +2 -2
  5. package/dist/cjs/AD728x90.js +2 -2
  6. package/dist/cjs/ADFloatingFooter.js +2 -2
  7. package/dist/cjs/ADGutter.js +2 -2
  8. package/dist/cjs/ADSkyscraper.js +2 -2
  9. package/dist/cjs/ADSponsoredResources.js +2 -2
  10. package/dist/cjs/ADWebcast.js +2 -2
  11. package/dist/cjs/ADWelcome.js +2 -2
  12. package/dist/cjs/AdSlot.js +2 -2
  13. package/dist/cjs/ArticleSeriesListing.js +2 -2
  14. package/dist/cjs/CMEDeck.js +2 -2
  15. package/dist/cjs/Column2.js +2 -3
  16. package/dist/cjs/Column3.js +3 -4
  17. package/dist/cjs/DeckContent.js +3 -3
  18. package/dist/cjs/DeckQueue.js +3 -4
  19. package/dist/cjs/{Dfp-ffaf5981.js → Dfp-b2bc3b97.js} +2 -2
  20. package/dist/cjs/ExternalResources.js +3 -3
  21. package/dist/cjs/GridContent.js +5 -6
  22. package/dist/cjs/IssueLanding.js +4 -4
  23. package/dist/cjs/LeftNav.js +2 -2
  24. package/dist/cjs/MasterDeck.js +6 -5
  25. package/dist/cjs/PartnerDetailListing.js +5 -5
  26. package/dist/cjs/QueueDeckExpanded.js +4 -4
  27. package/dist/cjs/SideFooter.js +2 -3
  28. package/dist/cjs/TemplateNormal.js +3 -4
  29. package/dist/cjs/VideoSeriesListing.js +96 -20
  30. package/dist/cjs/View.js +37 -29
  31. package/dist/cjs/{debounce-32e57002.js → debounce-eb287781.js} +1 -2
  32. package/dist/cjs/{get-5dfcdc33.js → get-68c52cb1.js} +90 -7
  33. package/dist/cjs/getQuery.js +2 -2
  34. package/dist/cjs/getSerializers.js +3 -3
  35. package/dist/cjs/{getTargeting-87eb9994.js → getTargeting-fee8c429.js} +32 -1
  36. package/dist/cjs/getTargeting.js +1 -1
  37. package/dist/cjs/index.js +9 -12
  38. package/dist/cjs/{isSymbol-488934a7.js → isSymbol-04666465.js} +0 -2
  39. package/dist/esm/AD.js +1 -1
  40. package/dist/esm/AD300x250.js +2 -2
  41. package/dist/esm/AD300x250x600.js +2 -2
  42. package/dist/esm/AD728x90.js +2 -2
  43. package/dist/esm/ADFloatingFooter.js +2 -2
  44. package/dist/esm/ADGutter.js +2 -2
  45. package/dist/esm/ADSkyscraper.js +2 -2
  46. package/dist/esm/ADSponsoredResources.js +2 -2
  47. package/dist/esm/ADWebcast.js +2 -2
  48. package/dist/esm/ADWelcome.js +2 -2
  49. package/dist/esm/AdSlot.js +2 -2
  50. package/dist/esm/ArticleSeriesListing.js +2 -2
  51. package/dist/esm/CMEDeck.js +2 -2
  52. package/dist/esm/Column2.js +2 -3
  53. package/dist/esm/Column3.js +3 -4
  54. package/dist/esm/DeckContent.js +3 -3
  55. package/dist/esm/DeckQueue.js +3 -4
  56. package/dist/esm/{Dfp-4f966af0.js → Dfp-43d61e01.js} +2 -2
  57. package/dist/esm/ExternalResources.js +3 -3
  58. package/dist/esm/GridContent.js +5 -6
  59. package/dist/esm/IssueLanding.js +4 -4
  60. package/dist/esm/LeftNav.js +2 -2
  61. package/dist/esm/MasterDeck.js +6 -5
  62. package/dist/esm/PartnerDetailListing.js +5 -5
  63. package/dist/esm/QueueDeckExpanded.js +4 -4
  64. package/dist/esm/SideFooter.js +2 -3
  65. package/dist/esm/TemplateNormal.js +3 -4
  66. package/dist/esm/VideoSeriesListing.js +96 -20
  67. package/dist/esm/View.js +34 -26
  68. package/dist/esm/{debounce-a0d9abca.js → debounce-1a993acf.js} +2 -2
  69. package/dist/esm/{get-58d2f7cc.js → get-5ee14cda.js} +85 -2
  70. package/dist/esm/getQuery.js +2 -2
  71. package/dist/esm/getSerializers.js +3 -3
  72. package/dist/esm/{getTargeting-3cc3f97d.js → getTargeting-11d623e4.js} +32 -1
  73. package/dist/esm/getTargeting.js +1 -1
  74. package/dist/esm/index.js +8 -10
  75. package/dist/esm/{isSymbol-47f5ff3b.js → isSymbol-807e927e.js} +1 -1
  76. package/package.json +1 -1
  77. package/dist/cjs/ArticleQueue.js +0 -1689
  78. package/dist/cjs/_arrayMap-3b4a0f75.js +0 -91
  79. package/dist/esm/ArticleQueue.js +0 -1684
  80. package/dist/esm/_arrayMap-818441dd.js +0 -87
  81. /package/dist/cjs/{ADInfeed-350decaa.js → ADInfeed-eaa6c661.js} +0 -0
  82. /package/dist/cjs/{ADlgInfeed-7d61609b.js → ADlgInfeed-f25eb4f7.js} +0 -0
  83. /package/dist/cjs/{index-1620daac.js → index-4f22007d.js} +0 -0
  84. /package/dist/esm/{ADInfeed-fd7a62b1.js → ADInfeed-3c4773f8.js} +0 -0
  85. /package/dist/esm/{ADlgInfeed-79c771d6.js → ADlgInfeed-5a52301f.js} +0 -0
  86. /package/dist/esm/{index-fe4d6d6e.js → index-4b48a31f.js} +0 -0
package/dist/cjs/View.js CHANGED
@@ -26,8 +26,8 @@ require('react-bootstrap/Col');
26
26
  var moment = require('./moment-66a6a284.js');
27
27
  var Router = require('next/router');
28
28
  var Router__default = _interopDefault(Router);
29
- require('./isSymbol-488934a7.js');
30
- require('./debounce-32e57002.js');
29
+ require('./isSymbol-04666465.js');
30
+ require('./debounce-eb287781.js');
31
31
  var index_es = require('./index.es-ab3f2690.js');
32
32
  require('react-dom');
33
33
  require('./index-b5eb3ff8.js');
@@ -45,7 +45,7 @@ require('./smoothscroll-95231a70.js');
45
45
  require('./GroupDeck.js');
46
46
  require('react-bootstrap');
47
47
  var Button = _interopDefault(require('react-bootstrap/Button'));
48
- var getSerializers = require('./index-1620daac.js');
48
+ var getSerializers = require('./index-4f22007d.js');
49
49
  require('./util-f2c1b65b.js');
50
50
  require('./brightcove-react-player-loader.es-156bd4d6.js');
51
51
  require('react-bootstrap/Pagination');
@@ -55,14 +55,14 @@ require('react-share');
55
55
  var SocialShare = require('./SocialShare.js');
56
56
  var Form = _interopDefault(require('react-bootstrap/Form'));
57
57
  var FormControl = _interopDefault(require('react-bootstrap/FormControl'));
58
- var keys$1 = require('./keys-a586b7a0.js');
58
+ var keys = require('./keys-a586b7a0.js');
59
59
  require('react-bootstrap/Dropdown');
60
- var getKeywords = require('./getKeywords.js');
61
60
  var getSeriesDetail = require('./getSeriesDetail.js');
62
61
  require('nookies');
63
62
  var getQuery = require('./getQuery.js');
64
63
  var getRelatedArticle = require('./getRelatedArticle.js');
65
- var getTargeting = require('./getTargeting-87eb9994.js');
64
+ var getTargeting = require('./getTargeting-fee8c429.js');
65
+ var getKeywords = require('./getKeywords.js');
66
66
  var urlFor = require('./urlFor.js');
67
67
  var styleInject_es = require('./style-inject.es-dcee06b6.js');
68
68
 
@@ -121,7 +121,7 @@ var DocumentGroup = function DocumentGroup(_ref) {
121
121
  var article = _ref.article,
122
122
  client = _ref.client;
123
123
 
124
- if (!article.documentGroup) {
124
+ if (!article.documentGroupMapping) {
125
125
  return null;
126
126
  }
127
127
  var name = getDocumentGroupName(article.documentGroup);
@@ -314,7 +314,7 @@ var Article = function Article(props) {
314
314
  var url = _props$article$url.current,
315
315
  issue = _props$article.issue,
316
316
  source = _props$article.source,
317
- documentGroup = _props$article.documentGroup,
317
+ documentGroupMapping = _props$article.documentGroupMapping,
318
318
  regionalPages = props.regionalPages,
319
319
  nationalPage = props.nationalPage,
320
320
  ISIContent = props.ISIContent,
@@ -405,7 +405,7 @@ var Article = function Article(props) {
405
405
  };
406
406
 
407
407
  var RelevantTopics = function RelevantTopics() {
408
- if (content_placement && content_placement.length > 0 || documentGroup) {
408
+ if (content_placement && content_placement.length > 0 || documentGroupMapping) {
409
409
  return React__default.createElement(
410
410
  'div',
411
411
  { style: { color: '#262626' } },
@@ -418,23 +418,29 @@ var Article = function Article(props) {
418
418
  'Related Content:'
419
419
  )
420
420
  ),
421
- documentGroup && documentGroup.parent && React__default.createElement(
422
- React__default.Fragment,
423
- null,
424
- React__default.createElement(
425
- 'span',
426
- { className: '' },
421
+ documentGroupMapping && documentGroupMapping.map(function (documentGroup) {
422
+ if (!documentGroup.parent) {
423
+ return null;
424
+ }
425
+
426
+ return React__default.createElement(
427
+ React__default.Fragment,
428
+ null,
427
429
  React__default.createElement(
428
- 'a',
429
- {
430
- className: 'related-links',
431
- style: { color: 'blue' },
432
- href: cpModificationRequired ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path },
433
- documentGroup.name
434
- )
435
- ),
436
- content_placement && content_placement.length ? ' | ' : null
437
- ),
430
+ 'span',
431
+ { className: '' },
432
+ React__default.createElement(
433
+ 'a',
434
+ {
435
+ className: 'related-links',
436
+ style: { color: 'blue' },
437
+ href: cpModificationRequired ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path },
438
+ documentGroup.name
439
+ )
440
+ ),
441
+ content_placement && content_placement.length ? ' | ' : null
442
+ );
443
+ }),
438
444
  content_placement && content_placement.length > 0 ? content_placement.map(function (cp, index) {
439
445
  var cp_url = cpModificationRequired ? getTargeting.getContentPlacementUrl(cp) : cp.path;
440
446
  var href = '/' + cp_url;
@@ -1011,7 +1017,7 @@ var ArticleQueue = function ArticleQueue(props) {
1011
1017
  var pos = slot.getTargeting('pos');
1012
1018
 
1013
1019
  slot.clearTargeting();
1014
- keys$1._Object$keys(targeting).forEach(function (key) {
1020
+ keys._Object$keys(targeting).forEach(function (key) {
1015
1021
  slot.setTargeting(key, targeting[key]);
1016
1022
  });
1017
1023
  slot.setTargeting('pos', pos);
@@ -1032,7 +1038,7 @@ var ArticleQueue = function ArticleQueue(props) {
1032
1038
  //gets the slotId of the leaderboard ad to refresh
1033
1039
  leaderboardSlotId = slot.getSlotId().getDomId();
1034
1040
  slot.clearTargeting();
1035
- keys$1._Object$keys(targeting).forEach(function (key) {
1041
+ keys._Object$keys(targeting).forEach(function (key) {
1036
1042
  slot.setTargeting(key, targeting[key]);
1037
1043
  });
1038
1044
  slot.setTargeting('pos', pos);
@@ -1282,7 +1288,9 @@ var View = function View(props) {
1282
1288
  _props$showRelatedArt = props.showRelatedArticles,
1283
1289
  showRelatedArticles = _props$showRelatedArt === undefined ? false : _props$showRelatedArt,
1284
1290
  _props$canonicalTag = props.canonicalTag,
1285
- canonicalTag = _props$canonicalTag === undefined ? true : _props$canonicalTag;
1291
+ canonicalTag = _props$canonicalTag === undefined ? true : _props$canonicalTag,
1292
+ _props$infiniteScroll = props.infiniteScrollFlag,
1293
+ infiniteScrollFlag = _props$infiniteScroll === undefined ? true : _props$infiniteScroll;
1286
1294
  var _props$article = props.article,
1287
1295
  _props$article$passwo = _props$article.passwordLock,
1288
1296
  passwordLock = _props$article$passwo === undefined ? false : _props$article$passwo,
@@ -1340,7 +1348,7 @@ var View = function View(props) {
1340
1348
 
1341
1349
  var isVideoSeries = checkVideoSeries(props.article);
1342
1350
  var isArticleSeries = checkArticleSeries(props.article);
1343
- var needInfiniteScroll = ['Articles', 'Videos', 'Podcasts'].includes(article.category.name) && article.taxonomyMapping && article.passwordLock !== true && !isVideoSeries && !isArticleSeries && !article.ExcludeFromInfiniteScroll && !sponsoredFlag;
1351
+ var needInfiniteScroll = ['Articles', 'Videos', 'Podcasts'].includes(article.category.name) && article.taxonomyMapping && article.passwordLock !== true && !isVideoSeries && !isArticleSeries && !article.ExcludeFromInfiniteScroll && !sponsoredFlag && infiniteScrollFlag;
1344
1352
 
1345
1353
  if (['Articles', 'Videos', 'Podcasts'].includes(article.category.name)) {
1346
1354
  description = null;
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var isSymbol = require('./isSymbol-488934a7.js');
3
+ var isSymbol = require('./isSymbol-04666465.js');
4
4
 
5
5
  /**
6
6
  * Gets the timestamp of the number of milliseconds that have elapsed since
@@ -277,4 +277,3 @@ function debounce(func, wait, options) {
277
277
  var debounce_1 = debounce;
278
278
 
279
279
  exports.debounce_1 = debounce_1;
280
- exports.toNumber_1 = toNumber_1;
@@ -1,7 +1,33 @@
1
1
  'use strict';
2
2
 
3
- var isSymbol = require('./isSymbol-488934a7.js');
4
- var _arrayMap = require('./_arrayMap-3b4a0f75.js');
3
+ var isSymbol = require('./isSymbol-04666465.js');
4
+
5
+ /**
6
+ * Checks if `value` is classified as an `Array` object.
7
+ *
8
+ * @static
9
+ * @memberOf _
10
+ * @since 0.1.0
11
+ * @category Lang
12
+ * @param {*} value The value to check.
13
+ * @returns {boolean} Returns `true` if `value` is an array, else `false`.
14
+ * @example
15
+ *
16
+ * _.isArray([1, 2, 3]);
17
+ * // => true
18
+ *
19
+ * _.isArray(document.body.children);
20
+ * // => false
21
+ *
22
+ * _.isArray('abc');
23
+ * // => false
24
+ *
25
+ * _.isArray(_.noop);
26
+ * // => false
27
+ */
28
+ var isArray = Array.isArray;
29
+
30
+ var isArray_1 = isArray;
5
31
 
6
32
  /** Used to match property names within property paths. */
7
33
  var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
@@ -16,7 +42,7 @@ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
16
42
  * @returns {boolean} Returns `true` if `value` is a property name, else `false`.
17
43
  */
18
44
  function isKey(value, object) {
19
- if (_arrayMap.isArray_1(value)) {
45
+ if (isArray_1(value)) {
20
46
  return false;
21
47
  }
22
48
  var type = typeof value;
@@ -30,6 +56,41 @@ function isKey(value, object) {
30
56
 
31
57
  var _isKey = isKey;
32
58
 
59
+ /** `Object#toString` result references. */
60
+ var asyncTag = '[object AsyncFunction]',
61
+ funcTag = '[object Function]',
62
+ genTag = '[object GeneratorFunction]',
63
+ proxyTag = '[object Proxy]';
64
+
65
+ /**
66
+ * Checks if `value` is classified as a `Function` object.
67
+ *
68
+ * @static
69
+ * @memberOf _
70
+ * @since 0.1.0
71
+ * @category Lang
72
+ * @param {*} value The value to check.
73
+ * @returns {boolean} Returns `true` if `value` is a function, else `false`.
74
+ * @example
75
+ *
76
+ * _.isFunction(_);
77
+ * // => true
78
+ *
79
+ * _.isFunction(/abc/);
80
+ * // => false
81
+ */
82
+ function isFunction(value) {
83
+ if (!isSymbol.isObject_1(value)) {
84
+ return false;
85
+ }
86
+ // The use of `Object#toString` avoids issues with the `typeof` operator
87
+ // in Safari 9 which returns 'object' for typed arrays and other constructors.
88
+ var tag = isSymbol._baseGetTag(value);
89
+ return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
90
+ }
91
+
92
+ var isFunction_1 = isFunction;
93
+
33
94
  /** Used to detect overreaching core-js shims. */
34
95
  var coreJsData = isSymbol._root['__core-js_shared__'];
35
96
 
@@ -118,7 +179,7 @@ function baseIsNative(value) {
118
179
  if (!isSymbol.isObject_1(value) || _isMasked(value)) {
119
180
  return false;
120
181
  }
121
- var pattern = _arrayMap.isFunction_1(value) ? reIsNative : reIsHostCtor;
182
+ var pattern = isFunction_1(value) ? reIsNative : reIsHostCtor;
122
183
  return pattern.test(_toSource(value));
123
184
  }
124
185
 
@@ -755,6 +816,28 @@ var stringToPath = _memoizeCapped(function(string) {
755
816
 
756
817
  var _stringToPath = stringToPath;
757
818
 
819
+ /**
820
+ * A specialized version of `_.map` for arrays without support for iteratee
821
+ * shorthands.
822
+ *
823
+ * @private
824
+ * @param {Array} [array] The array to iterate over.
825
+ * @param {Function} iteratee The function invoked per iteration.
826
+ * @returns {Array} Returns the new mapped array.
827
+ */
828
+ function arrayMap(array, iteratee) {
829
+ var index = -1,
830
+ length = array == null ? 0 : array.length,
831
+ result = Array(length);
832
+
833
+ while (++index < length) {
834
+ result[index] = iteratee(array[index], index, array);
835
+ }
836
+ return result;
837
+ }
838
+
839
+ var _arrayMap = arrayMap;
840
+
758
841
  /** Used as references for various `Number` constants. */
759
842
  var INFINITY = 1 / 0;
760
843
 
@@ -775,9 +858,9 @@ function baseToString(value) {
775
858
  if (typeof value == 'string') {
776
859
  return value;
777
860
  }
778
- if (_arrayMap.isArray_1(value)) {
861
+ if (isArray_1(value)) {
779
862
  // Recursively convert values (susceptible to call stack limits).
780
- return _arrayMap._arrayMap(value, baseToString) + '';
863
+ return _arrayMap(value, baseToString) + '';
781
864
  }
782
865
  if (isSymbol.isSymbol_1(value)) {
783
866
  return symbolToString ? symbolToString.call(value) : '';
@@ -824,7 +907,7 @@ var toString_1 = toString;
824
907
  * @returns {Array} Returns the cast property path array.
825
908
  */
826
909
  function castPath(value, object) {
827
- if (_arrayMap.isArray_1(value)) {
910
+ if (isArray_1(value)) {
828
911
  return value;
829
912
  }
830
913
  return _isKey(value, object) ? [value] : _stringToPath(toString_1(value));
@@ -10,9 +10,9 @@ var getQuery = function getQuery(type) {
10
10
 
11
11
  switch (type) {
12
12
  case 'related':
13
- return '*[\n _type == "article"\n && defined(title)\n && defined(url)\n && !(_id in path("drafts.**"))\n && is_visible == true\n && published <= now()\n && passwordLock!=true\n && taxonomyMapping[]._ref in $taxonomy\n && taxonomyMapping[].disableAds != \'true\'\n && contentCategory->.name != \'Poll\'\n && contentCategory->.name != \'Slideshows\'\n && contentCategory->.disableAds != \'true\'\n && ExcludeFromInfiniteScroll !=true\n && url.current != $url\n && !defined(body[].videos)\n ' + conditions + '\n ]| order(published desc)[' + (articleCount ? articleCount : '$index') + ']{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n body[] {\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier,\n disableAds\n },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n \'issue\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.issueGroup._ref][0] {\n name,\n \'path\': identifier.current,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current\n },\n \'url\' : pdf.asset-> url\n }\n }';
13
+ return '*[\n _type == "article"\n && defined(title)\n && defined(url)\n && !(_id in path("drafts.**"))\n && is_visible == true\n && published <= now()\n && passwordLock!=true\n && taxonomyMapping[]._ref in $taxonomy\n && taxonomyMapping[].disableAds != \'true\'\n && contentCategory->.name != \'Poll\'\n && contentCategory->.name != \'Slideshows\'\n && contentCategory->.disableAds != \'true\'\n && ExcludeFromInfiniteScroll !=true\n && url.current != $url\n && !defined(body[].videos)\n ' + conditions + '\n ]| order(published desc)[' + (articleCount ? articleCount : '$index') + ']{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n body[] {\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier,\n disableAds\n },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n documentGroupMapping[]-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n \'issue\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.issueGroup._ref][0] {\n name,\n \'path\': identifier.current,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current\n },\n \'url\' : pdf.asset-> url\n }\n }';
14
14
  case 'article':
15
- return '*[\n _type == "article"\n && !(_id in path("drafts.**"))\n && defined(title)\n && defined(url)\n && url.current == $url\n ' + conditions + '\n ][0]{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n body[] {\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n },\n medias[]{\n ...,\n upload_doc {\n _type,\n asset-> \n } \n },\n articles[]{\n ...,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n ...,\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier\n },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n \'category\':contentCategory->{\n name,\n disableAds\n },\n \'issue\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.issueGroup._ref][0] {\n name,\n volume,\n \'issueNumber\': number,\n \'articleSource\': source,\n \'path\': identifier.current,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current\n },\n \'url\' : pdf.asset-> url\n }\n\n }';
15
+ return '*[\n _type == "article"\n && !(_id in path("drafts.**"))\n && defined(title)\n && defined(url)\n && url.current == $url\n ' + conditions + '\n ][0]{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n body[] {\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n },\n medias[]{\n ...,\n upload_doc {\n _type,\n asset-> \n } \n },\n articles[]{\n ...,\n "authorDetails": authorMapping[]->{ displayName, url, profileImage, biography },\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n ...,\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier\n },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n documentGroupMapping[]-> {\n name,\n thumbnail,\n parent->{...,parent->},\n \'path\': identifier.current\n },\n \'category\':contentCategory->{\n name,\n disableAds\n },\n \'issue\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.issueGroup._ref][0] {\n name,\n volume,\n \'issueNumber\': number,\n \'articleSource\': source,\n \'path\': identifier.current,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current\n },\n \'url\' : pdf.asset-> url\n }\n\n }';
16
16
  case 'publication':
17
17
  return '*[_type == \'publication\'\n && identifier.current == $publication\n ' + conditions + '][0] {\n ' + params + '\n ...,\n \'issues\': *[_type == \'publication\'\n && is_visible\n && references(^._id)\n && defined(identifier)] {\n ...,\n pdf{asset->}\n } | order(year desc, month desc)\n }';
18
18
  case 'issue':
@@ -22,8 +22,8 @@ require('react-bootstrap/Row');
22
22
  require('react-bootstrap/Col');
23
23
  require('./moment-66a6a284.js');
24
24
  require('next/router');
25
- require('./isSymbol-488934a7.js');
26
- require('./debounce-32e57002.js');
25
+ require('./isSymbol-04666465.js');
26
+ require('./debounce-eb287781.js');
27
27
  require('react-dom');
28
28
  require('./index-b5eb3ff8.js');
29
29
  require('./index-da796b8c.js');
@@ -40,7 +40,7 @@ require('./smoothscroll-95231a70.js');
40
40
  require('./GroupDeck.js');
41
41
  require('react-bootstrap');
42
42
  require('react-bootstrap/Button');
43
- var getSerializers = require('./index-1620daac.js');
43
+ var getSerializers = require('./index-4f22007d.js');
44
44
  require('./util-f2c1b65b.js');
45
45
  require('./brightcove-react-player-loader.es-156bd4d6.js');
46
46
  require('react-bootstrap/Pagination');
@@ -49,6 +49,7 @@ var getTargeting = function getTargeting(props) {
49
49
  path: ''
50
50
  } : _article$documentGrou;
51
51
  var document_group = _article$documentGrou.path,
52
+ document_groups = article.document_groups,
52
53
  content_placement = article.content_placement;
53
54
 
54
55
  var context = url;
@@ -86,10 +87,40 @@ var getTargeting = function getTargeting(props) {
86
87
  } else {
87
88
  content_placement_urls = ['/'];
88
89
  }
90
+
91
+ var document_group_urls = [];
92
+ if (document_groups && prevUrl && prevUrl.length) {
93
+ document_groups.forEach(function (item) {
94
+ var path = item.path;
95
+ if (cpModificationRequired) {
96
+ path = getContentPlacementUrl(item);
97
+ }
98
+
99
+ var previous_url_to_check = prevUrl;
100
+ if (prevUrl.includes('?')) {
101
+ previous_url_to_check = prevUrl.split('?')[0];
102
+ }
103
+
104
+ if (previous_url_to_check.endsWith(path)) {
105
+ document_group_urls.push(path);
106
+ }
107
+ });
108
+ }
109
+
110
+ if (document_groups) {
111
+ if (document_group_urls.length === 0) {
112
+ document_group_urls = document_groups.map(function (item) {
113
+ return cpModificationRequired ? getContentPlacementUrl(item) : item.path;
114
+ });
115
+ }
116
+ } else {
117
+ document_group_urls = [document_group];
118
+ }
119
+
89
120
  var articleKeywords = [].concat(toConsumableArray._toConsumableArray(internalTag), toConsumableArray._toConsumableArray(userDefinedTag), toConsumableArray._toConsumableArray(SponsorshipTag), toConsumableArray._toConsumableArray(seoTag));
90
121
  var targeting = {
91
122
  tags: articleKeywords,
92
- document_group: [document_group],
123
+ document_group: document_group_urls,
93
124
  document_url: [url],
94
125
  content_placement: content_placement_urls
95
126
  };
@@ -8,7 +8,7 @@ require('./toConsumableArray-9a3476fe.js');
8
8
  require('./core.get-iterator-method-f62321d4.js');
9
9
  require('./_object-pie-68c5bcbc.js');
10
10
  require('./extends-60837c34.js');
11
- var getTargeting = require('./getTargeting-87eb9994.js');
11
+ var getTargeting = require('./getTargeting-fee8c429.js');
12
12
 
13
13
 
14
14
 
package/dist/cjs/index.js CHANGED
@@ -26,8 +26,8 @@ require('react-bootstrap/Col');
26
26
  require('react-bootstrap/Card');
27
27
  require('./moment-66a6a284.js');
28
28
  require('next/router');
29
- require('./isSymbol-488934a7.js');
30
- require('./debounce-32e57002.js');
29
+ require('./isSymbol-04666465.js');
30
+ require('./debounce-eb287781.js');
31
31
  require('./index.es-ab3f2690.js');
32
32
  require('react-dom');
33
33
  require('./visibility-sensor-0c45a583.js');
@@ -41,12 +41,11 @@ require('./asyncToGenerator-533d476a.js');
41
41
  require('./_set-species-f92c67c5.js');
42
42
  var Segment = require('./beam-7217b7e7.js');
43
43
  var AdSlot = require('./AdSlot.js');
44
- require('./ADInfeed-350decaa.js');
44
+ require('./ADInfeed-eaa6c661.js');
45
45
  var DeckContent = require('./DeckContent.js');
46
46
  require('./lodash-fc2922d0.js');
47
- require('./ADlgInfeed-7d61609b.js');
48
- require('./_arrayMap-3b4a0f75.js');
49
- require('./get-5dfcdc33.js');
47
+ require('./ADlgInfeed-f25eb4f7.js');
48
+ require('./get-68c52cb1.js');
50
49
  var AD = require('./AD.js');
51
50
  require('./AuthorComponent-bb831b74.js');
52
51
  var GridContent = require('./GridContent.js');
@@ -77,7 +76,7 @@ require('./index-5be2866f.js');
77
76
  require('./js.cookie-a511c430.js');
78
77
  var EventsDeck = require('./EventsDeck.js');
79
78
  var CMEDeck = require('./CMEDeck.js');
80
- var getSerializers = require('./index-1620daac.js');
79
+ var getSerializers = require('./index-4f22007d.js');
81
80
  require('./util-f2c1b65b.js');
82
81
  require('./brightcove-react-player-loader.es-156bd4d6.js');
83
82
  require('react-bootstrap/Pagination');
@@ -145,8 +144,6 @@ var PublicationLanding = require('./PublicationLanding.js');
145
144
  var IssueLanding = require('./IssueLanding.js');
146
145
  require('react-bootstrap/Modal');
147
146
  var PopUpModal = require('./PopUpModal.js');
148
- var ArticleQueue = require('./ArticleQueue.js');
149
- var getKeywords = require('./getKeywords.js');
150
147
  var RelatedContent = require('./RelatedContent.js');
151
148
  var ForbesHero = require('./ForbesHero.js');
152
149
  var HorizontalHero = require('./HorizontalHero.js');
@@ -166,8 +163,9 @@ var Auth = require('./Auth.js');
166
163
  require('swr');
167
164
  require('passport-local');
168
165
  require('mysql');
169
- var getTargeting = require('./getTargeting-87eb9994.js');
166
+ var getTargeting = require('./getTargeting-fee8c429.js');
170
167
  var View = require('./View.js');
168
+ var getKeywords = require('./getKeywords.js');
171
169
  var urlFor = require('./urlFor.js');
172
170
  require('./style-inject.es-dcee06b6.js');
173
171
  require('react-twitter-embed');
@@ -238,8 +236,6 @@ exports.HighlightenVideo = HighlightenVideo;
238
236
  exports.PublicationLanding = PublicationLanding;
239
237
  exports.IssueLanding = IssueLanding;
240
238
  exports.PopUpModal = PopUpModal;
241
- exports.ArticleQueue = ArticleQueue;
242
- exports.getKeywords = getKeywords;
243
239
  exports.RelatedContent = RelatedContent;
244
240
  exports.ForbesHero = ForbesHero;
245
241
  exports.HorizontalHero = HorizontalHero;
@@ -257,5 +253,6 @@ exports.getRelatedArticle = getRelatedArticle;
257
253
  exports.Auth = Auth.default;
258
254
  exports.getTargeting = getTargeting.getTargeting;
259
255
  exports.View = View;
256
+ exports.getKeywords = getKeywords;
260
257
  exports.urlFor = urlFor;
261
258
  exports.PartnerDetailListing = PartnerDetailListing;
@@ -204,8 +204,6 @@ var isSymbol_1 = isSymbol;
204
204
 
205
205
  exports._Symbol = _Symbol;
206
206
  exports._baseGetTag = _baseGetTag;
207
- exports._freeGlobal = _freeGlobal;
208
207
  exports._root = _root;
209
- exports.isObjectLike_1 = isObjectLike_1;
210
208
  exports.isObject_1 = isObject_1;
211
209
  exports.isSymbol_1 = isSymbol_1;
package/dist/esm/AD.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import React__default, { Suspense } from 'react';
2
2
 
3
3
  var Dfp = React__default.lazy(function () {
4
- return import('./Dfp-4f966af0.js');
4
+ return import('./Dfp-43d61e01.js');
5
5
  });
6
6
 
7
7
  var AD = function AD(props) {
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import { m as main_39 } from './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import { m as main_39 } from './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import { m as main_39 } from './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState, useEffect } from 'react';
9
9
  import './index-93ec3c59.js';
10
10
  import 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import './debounce-1a993acf.js';
13
13
  import './main-0465b2a0.js';
14
14
  import { _ as _JSON$stringify } from './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -8,8 +8,8 @@ import './web.dom.iterable-03c5ba1c.js';
8
8
  import React__default, { useState } from 'react';
9
9
  import { a as lib_2 } from './index-93ec3c59.js';
10
10
  import PropTypes from 'prop-types';
11
- import './isSymbol-47f5ff3b.js';
12
- import { d as debounce_1 } from './debounce-a0d9abca.js';
11
+ import './isSymbol-807e927e.js';
12
+ import { d as debounce_1 } from './debounce-1a993acf.js';
13
13
  import { b as main_16 } from './main-0465b2a0.js';
14
14
  import './stringify-feadff37.js';
15
15
  import { _ as _slicedToArray } from './slicedToArray-5fb01661.js';
@@ -17,8 +17,8 @@ import 'prop-types';
17
17
  import Container from 'react-bootstrap/Container';
18
18
  import './moment-12415288.js';
19
19
  import { withRouter } from 'next/router';
20
- import './isSymbol-47f5ff3b.js';
21
- import { d as debounce_1 } from './debounce-a0d9abca.js';
20
+ import './isSymbol-807e927e.js';
21
+ import { d as debounce_1 } from './debounce-1a993acf.js';
22
22
  import { I as InfiniteScroll } from './index.es-938a3a58.js';
23
23
  import 'react-dom';
24
24
  import { V as VisibilitySensor } from './visibility-sensor-0baa4eea.js';