@mjhls/mjh-framework 1.0.637 → 1.0.639

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
- # mjh-framework v. 1.0.637
2
+ # mjh-framework v. 1.0.639
3
3
 
4
4
  > Foundation Framework
5
5
 
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- require('./inherits-c9f99d47.js');
15
+ require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  var _typeof = require('./typeof-725500bc.js');
@@ -45,7 +45,7 @@ require('./smoothscroll-95231a70.js');
45
45
  require('./GroupDeck.js');
46
46
  require('react-bootstrap');
47
47
  require('react-bootstrap/Button');
48
- var getSerializers = require('./index-87fd5322.js');
48
+ var getSerializers = require('./index-8c869759.js');
49
49
  require('./util-f2c1b65b.js');
50
50
  require('./brightcove-react-player-loader.es-156bd4d6.js');
51
51
  require('react-bootstrap/Pagination');
@@ -10,7 +10,7 @@ require('./core.get-iterator-method-f62321d4.js');
10
10
  require('./_object-pie-68c5bcbc.js');
11
11
  var _extends = require('./extends-60837c34.js');
12
12
  require('./_object-sap-5e74ba08.js');
13
- var inherits = require('./inherits-c9f99d47.js');
13
+ var inherits = require('./inherits-513d81cd.js');
14
14
  require('./define-property-f4d12f4e.js');
15
15
  require('./web.dom.iterable-a0e279c1.js');
16
16
  require('./typeof-725500bc.js');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- var inherits = require('./inherits-c9f99d47.js');
15
+ var inherits = require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- var inherits = require('./inherits-c9f99d47.js');
15
+ var inherits = require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- require('./inherits-c9f99d47.js');
15
+ require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -45,7 +45,7 @@ require('./GroupDeck.js');
45
45
  require('react-bootstrap');
46
46
  var Button = _interopDefault(require('react-bootstrap/Button'));
47
47
  var index$3 = require('./index-5be2866f.js');
48
- var getSerializers = require('./index-87fd5322.js');
48
+ var getSerializers = require('./index-8c869759.js');
49
49
  require('./util-f2c1b65b.js');
50
50
  require('./brightcove-react-player-loader.es-156bd4d6.js');
51
51
  require('react-bootstrap/Pagination');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- var inherits = require('./inherits-c9f99d47.js');
15
+ var inherits = require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- var inherits = require('./inherits-c9f99d47.js');
15
+ var inherits = require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- require('./inherits-c9f99d47.js');
15
+ require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -51,7 +51,7 @@ require('./GroupDeck.js');
51
51
  require('react-bootstrap');
52
52
  var QueueDeckExpanded = require('./QueueDeckExpanded.js');
53
53
  require('react-bootstrap/Button');
54
- var getSerializers = require('./index-87fd5322.js');
54
+ var getSerializers = require('./index-8c869759.js');
55
55
  require('./util-f2c1b65b.js');
56
56
  require('./brightcove-react-player-loader.es-156bd4d6.js');
57
57
  require('react-bootstrap/Pagination');
@@ -8,7 +8,7 @@ require('./es6.string.iterator-cc0bbaa4.js');
8
8
  require('./_library-dd23b178.js');
9
9
  require('./_object-pie-68c5bcbc.js');
10
10
  require('./web.dom.iterable-a0e279c1.js');
11
- var _typeof = require('./typeof-725500bc.js');
11
+ var _typeof$1 = require('./typeof-725500bc.js');
12
12
  require('./_is-array-754e012d.js');
13
13
  var React = require('react');
14
14
  var React__default = _interopDefault(React);
@@ -48,7 +48,7 @@ var VideoSeriesCard = function VideoSeriesCard(props) {
48
48
  index$2.LazyLoad,
49
49
  null,
50
50
  React__default.createElement('img', {
51
- src: data.thumbnail && data.thumbnail.asset ? builder.image(data.thumbnail).url() : data.thumbnail && _typeof._typeof(data.thumbnail == 'string') ? data.thumbnail : defaultImage
51
+ src: data.thumbnail && data.thumbnail.asset ? builder.image(data.thumbnail).url() : data.thumbnail && _typeof$1._typeof(data.thumbnail == 'string') ? data.thumbnail : defaultImage
52
52
  })
53
53
  )
54
54
  )
@@ -10,7 +10,7 @@ require('./core.get-iterator-method-f62321d4.js');
10
10
  require('./_object-pie-68c5bcbc.js');
11
11
  var _extends = require('./extends-60837c34.js');
12
12
  require('./_object-sap-5e74ba08.js');
13
- var inherits = require('./inherits-c9f99d47.js');
13
+ var inherits = require('./inherits-513d81cd.js');
14
14
  require('./define-property-f4d12f4e.js');
15
15
  require('./web.dom.iterable-a0e279c1.js');
16
16
  require('./typeof-725500bc.js');
package/dist/cjs/View.js CHANGED
@@ -12,10 +12,10 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  var _extends = require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- require('./inherits-c9f99d47.js');
15
+ require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
- var _typeof = require('./typeof-725500bc.js');
18
+ var _typeof$1 = require('./typeof-725500bc.js');
19
19
  require('./_is-array-754e012d.js');
20
20
  var React = require('react');
21
21
  var React__default = _interopDefault(React);
@@ -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-87fd5322.js');
48
+ var getSerializers = require('./index-8c869759.js');
49
49
  require('./util-f2c1b65b.js');
50
50
  require('./brightcove-react-player-loader.es-156bd4d6.js');
51
51
  require('react-bootstrap/Pagination');
@@ -152,7 +152,7 @@ var DocumentGroup = function DocumentGroup(_ref) {
152
152
 
153
153
  var findIndex = function findIndex(arr) {
154
154
  var indexes = [];
155
- if ((typeof arr === 'undefined' ? 'undefined' : _typeof._typeof(arr)) === 'object') {
155
+ if ((typeof arr === 'undefined' ? 'undefined' : _typeof$1._typeof(arr)) === 'object') {
156
156
  var _iteratorNormalCompletion = true;
157
157
  var _didIteratorError = false;
158
158
  var _iteratorError = undefined;
@@ -328,6 +328,8 @@ var Article = function Article(props) {
328
328
  sponsoredFlag = _props$sponsoredFlag === undefined ? false : _props$sponsoredFlag,
329
329
  _props$authorImgHeigh = props.authorImgHeight,
330
330
  authorImgHeight = _props$authorImgHeigh === undefined ? 270 : _props$authorImgHeigh;
331
+
332
+ var targeting = getTargeting.getTargeting(props);
331
333
  var onChangeArticle = props.onChangeArticle;
332
334
 
333
335
  //If sponsored flag, disable contextual ads
@@ -543,7 +545,7 @@ var Article = function Article(props) {
543
545
  React__default.Fragment,
544
546
  null,
545
547
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
546
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
548
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
547
549
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(0, selectedIndex))),
548
550
  imageOptions: { w: 320, h: 240, fit: 'max' }
549
551
  }, client.config())),
@@ -560,7 +562,7 @@ var Article = function Article(props) {
560
562
  React__default.createElement(AdSlot, _extends._extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: checkIsVideoAdFound }))
561
563
  ),
562
564
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
563
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
565
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
564
566
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(selectedIndex))),
565
567
  imageOptions: { w: 320, h: 240, fit: 'max' }
566
568
  }, client.config()))
@@ -615,7 +617,7 @@ var Article = function Article(props) {
615
617
  React__default.Fragment,
616
618
  null,
617
619
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
618
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
620
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
619
621
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(0, _selectedIndex))),
620
622
  imageOptions: { w: 320, h: 240, fit: 'max' }
621
623
  }, client.config())),
@@ -627,7 +629,7 @@ var Article = function Article(props) {
627
629
  ),
628
630
  contextualADFlag && React__default.createElement('span', { className: 'clearfix' }),
629
631
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
630
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
632
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
631
633
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(_selectedIndex))),
632
634
  imageOptions: { w: 320, h: 240, fit: 'max' }
633
635
  }, client.config()))
@@ -658,7 +660,7 @@ var Article = function Article(props) {
658
660
  React__default.Fragment,
659
661
  null,
660
662
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
661
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
663
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
662
664
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(0, _selectedIndex2))),
663
665
  imageOptions: { w: 320, h: 240, fit: 'max' }
664
666
  }, client.config())),
@@ -669,14 +671,14 @@ var Article = function Article(props) {
669
671
  React__default.createElement(AdSlot, _extends._extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: _checkIsAdFound2 }))
670
672
  ),
671
673
  React__default.createElement(BlockContent.BlockContent, _extends._extends({
672
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
674
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
673
675
  blocks: [].concat(toConsumableArray._toConsumableArray(articleBody.slice(_selectedIndex2))),
674
676
  imageOptions: { w: 320, h: 240, fit: 'max' }
675
677
  }, client.config()))
676
678
  );
677
679
  } else {
678
680
  return React__default.createElement(BlockContent.BlockContent, _extends._extends({
679
- serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, false, null, props.article.Ads),
681
+ serializers: getSerializers.getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, false, null, props.article.Ads, targeting),
680
682
  blocks: articleBody,
681
683
  imageOptions: { w: 320, h: 240, fit: 'max' }
682
684
  }, client.config()));
@@ -1324,8 +1326,21 @@ var View = function View(props) {
1324
1326
  return false;
1325
1327
  };
1326
1328
 
1329
+ var checkArticleSeries = function checkArticleSeries(article) {
1330
+ if (!article || !article.body) {
1331
+ return false;
1332
+ }
1333
+ for (var i = 0; i < article.body.length; i++) {
1334
+ if (article.body[i]._type === 'articleSeries') {
1335
+ return true;
1336
+ }
1337
+ }
1338
+ return false;
1339
+ };
1340
+
1327
1341
  var isVideoSeries = checkVideoSeries(props.article);
1328
- var needInfiniteScroll = ['Articles', 'Videos', 'Podcasts'].includes(article.category.name) && article.taxonomyMapping && article.passwordLock !== true && !isVideoSeries && !article.ExcludeFromInfiniteScroll && !sponsoredFlag;
1342
+ 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;
1329
1344
 
1330
1345
  if (['Articles', 'Videos', 'Podcasts'].includes(article.category.name)) {
1331
1346
  description = null;
@@ -10,7 +10,7 @@ require('./core.get-iterator-method-f62321d4.js');
10
10
  require('./_object-pie-68c5bcbc.js');
11
11
  require('./extends-60837c34.js');
12
12
  require('./_object-sap-5e74ba08.js');
13
- require('./inherits-c9f99d47.js');
13
+ require('./inherits-513d81cd.js');
14
14
  require('./define-property-f4d12f4e.js');
15
15
  require('./web.dom.iterable-a0e279c1.js');
16
16
  require('./typeof-725500bc.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-87fd5322.js');
43
+ var getSerializers = require('./index-8c869759.js');
44
44
  require('./util-f2c1b65b.js');
45
45
  require('./brightcove-react-player-loader.es-156bd4d6.js');
46
46
  require('react-bootstrap/Pagination');
@@ -5,7 +5,8 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'defau
5
5
  var _commonjsHelpers = require('./_commonjsHelpers-06173234.js');
6
6
  var toConsumableArray = require('./toConsumableArray-9a3476fe.js');
7
7
  var _extends = require('./extends-60837c34.js');
8
- var inherits = require('./inherits-c9f99d47.js');
8
+ var inherits = require('./inherits-513d81cd.js');
9
+ var _typeof$1 = require('./typeof-725500bc.js');
9
10
  var React = require('react');
10
11
  var React__default = _interopDefault(React);
11
12
  var index = require('./index-2d0a4911.js');
@@ -2183,7 +2184,9 @@ var Video = function Video(_ref) {
2183
2184
  _ref$autoplay = _ref.autoplay,
2184
2185
  autoplay = _ref$autoplay === undefined ? false : _ref$autoplay,
2185
2186
  _ref$autoplayNextVide = _ref.autoplayNextVideo,
2186
- autoplayNextVideo = _ref$autoplayNextVide === undefined ? function () {} : _ref$autoplayNextVide;
2187
+ autoplayNextVideo = _ref$autoplayNextVide === undefined ? function () {} : _ref$autoplayNextVide,
2188
+ _ref$targeting = _ref.targeting,
2189
+ targeting = _ref$targeting === undefined ? null : _ref$targeting;
2187
2190
  var source = node.source,
2188
2191
  videoID = node.videoID,
2189
2192
  playlistID = node.playlistID,
@@ -2206,7 +2209,12 @@ var Video = function Video(_ref) {
2206
2209
  var onVideoSuccess = function onVideoSuccess(success) {
2207
2210
  //console.log('success:', success.ref)
2208
2211
  var player = success.ref;
2209
-
2212
+ if (_typeof$1._typeof(player.ima3) === 'object' && player.ima3.settings && player.ima3.settings.serverUrl && targeting !== null) {
2213
+ player.ima3.settings.debug = true;
2214
+ if (targeting.content_placement && targeting.document_url) {
2215
+ player.ima3.settings.serverUrl = player.ima3.settings.serverUrl + '&cust_params=' + encodeURIComponent('content_placement=' + targeting.content_placement + '&document_url=' + targeting.document_url);
2216
+ }
2217
+ }
2210
2218
  // this is video ready
2211
2219
  player.on('loadedmetadata', function (evt) {
2212
2220
  //console.log('loadedmetadata:', evt)
@@ -8027,8 +8035,9 @@ var ArticleSeries = function ArticleSeries(_ref) {
8027
8035
  var router = Router.useRouter();
8028
8036
 
8029
8037
  var refArray = React.useRef([]);
8038
+ var adRefArray = React.useRef([]);
8030
8039
 
8031
- var _useState = React.useState(77),
8040
+ var _useState = React.useState(100),
8032
8041
  _useState2 = slicedToArray._slicedToArray(_useState, 2),
8033
8042
  NavoffsetTop = _useState2[0],
8034
8043
  setNavoffsetTop = _useState2[1];
@@ -8105,26 +8114,26 @@ var ArticleSeries = function ArticleSeries(_ref) {
8105
8114
  };
8106
8115
 
8107
8116
  React.useEffect(function () {
8108
- if (!firstLoad) {
8109
- scrollToArticle();
8110
- }
8111
8117
  try {
8112
- setNavoffsetTop(document.getElementById('navbar-ham').offsetHeight);
8118
+ setNavoffsetTop(document.getElementById('navbar-ham').offsetHeight - 15);
8113
8119
  } catch (e) {}
8114
8120
  }, []);
8115
8121
 
8116
8122
  var scrollToArticle = function scrollToArticle(id) {
8117
8123
  var localArticleID = id ? id : selectedArticle;
8118
8124
  var findArticle = function findArticle(ref) {
8119
- return ref.props.id === localArticleID;
8125
+ if (ref) {
8126
+ return ref.props.id === localArticleID;
8127
+ }
8128
+ return false;
8120
8129
  };
8121
8130
  var indexOfRef = refArray.current.findIndex(findArticle);
8122
8131
 
8123
8132
  if (indexOfRef >= 0) {
8124
- //console.log(refArray.current[indexOfRef].wraperRef.current)
8125
- refArray.current[indexOfRef].wraperRef.current.scrollIntoView({ behavior: 'smooth' });
8126
- window.scrollTo({ top: refArray.current[indexOfRef].wraperRef.current.offsetTop + NavoffsetTop, behavior: 'smooth' });
8133
+ //refArray.current[indexOfRef].wraperRef.current.scrollIntoView({ behavior: 'smooth' })
8134
+ window.scrollTo({ top: refArray.current[indexOfRef].wraperRef.current.offsetTop - NavoffsetTop, behavior: 'smooth' });
8127
8135
  }
8136
+ setFirstLoad(true);
8128
8137
  };
8129
8138
 
8130
8139
  var renderAuthorBiography = function renderAuthorBiography(biography) {
@@ -8139,10 +8148,10 @@ var ArticleSeries = function ArticleSeries(_ref) {
8139
8148
  // Change URL and do other changes
8140
8149
  var doChanges = function doChanges() {
8141
8150
  if (firstLoad) {
8142
- window.history.pushState({ page: path }, '', newPath);
8151
+ refreshAD();
8143
8152
  }
8153
+ window.history.pushState({ page: path }, '', newPath);
8144
8154
  document.title = title;
8145
- refreshAD();
8146
8155
  setFirstLoad(true);
8147
8156
  };
8148
8157
 
@@ -8182,6 +8191,26 @@ var ArticleSeries = function ArticleSeries(_ref) {
8182
8191
  };
8183
8192
  });
8184
8193
 
8194
+ React.useEffect(function () {
8195
+ if (!firstLoad) {
8196
+ if (main.main_39) {
8197
+ grabLoadedAds();
8198
+ }
8199
+ }
8200
+ }, []);
8201
+
8202
+ var grabLoadedAds = function grabLoadedAds() {
8203
+ console.dir(index.lib_3);
8204
+ index.lib_3.getGoogletag().then(function (googletag) {
8205
+ var checkIfReady = window.setInterval(function () {
8206
+ if (window.googletag && googletag.pubadsReady) {
8207
+ clearInterval(checkIfReady);
8208
+ scrollToArticle();
8209
+ }
8210
+ }, 1000);
8211
+ });
8212
+ };
8213
+
8185
8214
  var refreshAD = function refreshAD(path) {
8186
8215
  //const activeArticle = path
8187
8216
  //let targeting = getTargeting({ article: activeArticle, cpModificationRequired, position: props.position, prevUrl })
@@ -8223,13 +8252,38 @@ var ArticleSeries = function ArticleSeries(_ref) {
8223
8252
  )
8224
8253
  ),
8225
8254
  React__default.createElement('hr', { className: 'article-seperater' }),
8255
+ React__default.createElement(
8256
+ 'div',
8257
+ { className: 'ad-box', style: { textAlign: 'center' } },
8258
+ main.main_39 && Ads.map(function (ad, index) {
8259
+ if (index === 0) {
8260
+ return React__default.createElement(
8261
+ 'div',
8262
+ {
8263
+ key: 'addid-1',
8264
+ id: 'addid-1',
8265
+ ref: function ref(ele) {
8266
+ return adRefArray.current[0] = ele;
8267
+ },
8268
+ style: {
8269
+ display: 'flex',
8270
+ flex: '1 0 auto',
8271
+ justifyContent: 'center',
8272
+ alignItems: 'center',
8273
+ textAlign: 'center'
8274
+ } },
8275
+ ad.component
8276
+ );
8277
+ }
8278
+ })
8279
+ ),
8226
8280
  React__default.createElement(
8227
8281
  'div',
8228
8282
  { className: 'article-container', style: { marginBottom: '2rem' } },
8229
8283
  nodes.articles.map(function (article, index) {
8230
8284
  return React__default.createElement(
8231
- React__default.Fragment,
8232
- null,
8285
+ 'div',
8286
+ { key: article.title },
8233
8287
  React__default.createElement(
8234
8288
  InscreenSensor,
8235
8289
  {
@@ -8299,13 +8353,16 @@ var ArticleSeries = function ArticleSeries(_ref) {
8299
8353
  React__default.createElement(
8300
8354
  'div',
8301
8355
  { className: 'ad-box', style: { textAlign: 'center' } },
8302
- main.main_39 && nodes.articles.length - 1 !== index && Ads.map(function (ad, index) {
8303
- if (index === 0) {
8356
+ main.main_39 && nodes.articles.length - 1 !== index && Ads.map(function (ad, innerIndex) {
8357
+ if (innerIndex === 0) {
8304
8358
  return React__default.createElement(
8305
8359
  'div',
8306
8360
  {
8307
- key: index,
8308
- id: 'addid-' + index,
8361
+ key: 'addid-' + (index + 2),
8362
+ id: 'addid-' + (index + 2),
8363
+ ref: function ref(ele) {
8364
+ return adRefArray.current[index + 1] = ele;
8365
+ },
8309
8366
  style: {
8310
8367
  display: 'flex',
8311
8368
  flex: '1 0 auto',
@@ -8611,7 +8668,8 @@ var getSerializers = function getSerializers() {
8611
8668
  _props$2 = props[8],
8612
8669
  contextualADFlag = _props$2 === undefined ? false : _props$2,
8613
8670
  articleId = props[9],
8614
- Ads = props[10];
8671
+ Ads = props[10],
8672
+ targeting = props[11];
8615
8673
 
8616
8674
  return {
8617
8675
  types: {
@@ -8677,7 +8735,7 @@ var getSerializers = function getSerializers() {
8677
8735
  video: function video(_ref11) {
8678
8736
  var node = _ref11.node;
8679
8737
 
8680
- return React__default.createElement(Video, { node: node, autoplay: autoplay, accountIDs: videoAccountIDs || {} });
8738
+ return React__default.createElement(Video, { node: node, autoplay: autoplay, accountIDs: videoAccountIDs || {}, targeting: targeting });
8681
8739
  },
8682
8740
  audio: function audio(_ref12) {
8683
8741
  var node = _ref12.node;
package/dist/cjs/index.js CHANGED
@@ -12,7 +12,7 @@ require('./core.get-iterator-method-f62321d4.js');
12
12
  require('./_object-pie-68c5bcbc.js');
13
13
  require('./extends-60837c34.js');
14
14
  require('./_object-sap-5e74ba08.js');
15
- require('./inherits-c9f99d47.js');
15
+ require('./inherits-513d81cd.js');
16
16
  require('./define-property-f4d12f4e.js');
17
17
  require('./web.dom.iterable-a0e279c1.js');
18
18
  require('./typeof-725500bc.js');
@@ -77,7 +77,7 @@ require('./index-5be2866f.js');
77
77
  require('./js.cookie-a511c430.js');
78
78
  var EventsDeck = require('./EventsDeck.js');
79
79
  var CMEDeck = require('./CMEDeck.js');
80
- var getSerializers = require('./index-87fd5322.js');
80
+ var getSerializers = require('./index-8c869759.js');
81
81
  require('./util-f2c1b65b.js');
82
82
  require('./brightcove-react-player-loader.es-156bd4d6.js');
83
83
  require('react-bootstrap/Pagination');
@@ -5,7 +5,7 @@ var _toObject = require('./_to-object-329a650b.js');
5
5
  var es6_string_iterator = require('./es6.string.iterator-cc0bbaa4.js');
6
6
  var _objectSap = require('./_object-sap-5e74ba08.js');
7
7
  var defineProperty = require('./define-property-f4d12f4e.js');
8
- var _typeof = require('./typeof-725500bc.js');
8
+ var _typeof$1 = require('./typeof-725500bc.js');
9
9
 
10
10
  // 19.1.2.9 Object.getPrototypeOf(O)
11
11
 
@@ -75,7 +75,7 @@ exports.__esModule = true;
75
75
 
76
76
 
77
77
 
78
- var _typeof3 = _interopRequireDefault(_typeof._typeof_1);
78
+ var _typeof3 = _interopRequireDefault(_typeof$1._typeof_1);
79
79
 
80
80
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
81
81
 
@@ -102,7 +102,7 @@ var _setProto = {
102
102
  set: Object.setPrototypeOf || ('__proto__' in {} ? // eslint-disable-line
103
103
  function (test, buggy, set) {
104
104
  try {
105
- set = _toObject._ctx(Function.call, _typeof._objectGopd.f(Object.prototype, '__proto__').set, 2);
105
+ set = _toObject._ctx(Function.call, _typeof$1._objectGopd.f(Object.prototype, '__proto__').set, 2);
106
106
  set(test, []);
107
107
  buggy = !(test instanceof Array);
108
108
  } catch (e) { buggy = true; }
@@ -156,7 +156,7 @@ var _create2 = _interopRequireDefault(create$1);
156
156
 
157
157
 
158
158
 
159
- var _typeof3 = _interopRequireDefault(_typeof._typeof_1);
159
+ var _typeof3 = _interopRequireDefault(_typeof$1._typeof_1);
160
160
 
161
161
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
162
162
 
@@ -40,7 +40,7 @@ import './smoothscroll-4b699764.js';
40
40
  import './GroupDeck.js';
41
41
  import 'react-bootstrap';
42
42
  import 'react-bootstrap/Button';
43
- import { I as InscreenSensor, g as getSerializers } from './index-539e2942.js';
43
+ import { I as InscreenSensor, g as getSerializers } from './index-ccfe8253.js';
44
44
  import './util-7700fc59.js';
45
45
  import './brightcove-react-player-loader.es-83f53e4e.js';
46
46
  import 'react-bootstrap/Pagination';
@@ -39,7 +39,7 @@ import './GroupDeck.js';
39
39
  import 'react-bootstrap';
40
40
  import Button from 'react-bootstrap/Button';
41
41
  import { m as momentTimezone } from './index-d2f90501.js';
42
- import { g as getSerializers } from './index-539e2942.js';
42
+ import { g as getSerializers } from './index-ccfe8253.js';
43
43
  import './util-7700fc59.js';
44
44
  import './brightcove-react-player-loader.es-83f53e4e.js';
45
45
  import 'react-bootstrap/Pagination';
@@ -46,7 +46,7 @@ import './GroupDeck.js';
46
46
  import 'react-bootstrap';
47
47
  import QueueDeckExpanded from './QueueDeckExpanded.js';
48
48
  import 'react-bootstrap/Button';
49
- import { g as getSerializers } from './index-539e2942.js';
49
+ import { g as getSerializers } from './index-ccfe8253.js';
50
50
  import './util-7700fc59.js';
51
51
  import './brightcove-react-player-loader.es-83f53e4e.js';
52
52
  import 'react-bootstrap/Pagination';
package/dist/esm/View.js CHANGED
@@ -39,7 +39,7 @@ import './smoothscroll-4b699764.js';
39
39
  import './GroupDeck.js';
40
40
  import 'react-bootstrap';
41
41
  import Button from 'react-bootstrap/Button';
42
- import { I as InscreenSensor, r as renderAuthor, g as getSerializers } from './index-539e2942.js';
42
+ import { I as InscreenSensor, r as renderAuthor, g as getSerializers } from './index-ccfe8253.js';
43
43
  import './util-7700fc59.js';
44
44
  import './brightcove-react-player-loader.es-83f53e4e.js';
45
45
  import 'react-bootstrap/Pagination';
@@ -322,6 +322,8 @@ var Article = function Article(props) {
322
322
  sponsoredFlag = _props$sponsoredFlag === undefined ? false : _props$sponsoredFlag,
323
323
  _props$authorImgHeigh = props.authorImgHeight,
324
324
  authorImgHeight = _props$authorImgHeigh === undefined ? 270 : _props$authorImgHeigh;
325
+
326
+ var targeting = getTargeting(props);
325
327
  var onChangeArticle = props.onChangeArticle;
326
328
 
327
329
  //If sponsored flag, disable contextual ads
@@ -537,7 +539,7 @@ var Article = function Article(props) {
537
539
  React__default.Fragment,
538
540
  null,
539
541
  React__default.createElement(BlockContent, _extends({
540
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
542
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
541
543
  blocks: [].concat(_toConsumableArray(articleBody.slice(0, selectedIndex))),
542
544
  imageOptions: { w: 320, h: 240, fit: 'max' }
543
545
  }, client.config())),
@@ -554,7 +556,7 @@ var Article = function Article(props) {
554
556
  React__default.createElement(DFPAdSlot, _extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: checkIsVideoAdFound }))
555
557
  ),
556
558
  React__default.createElement(BlockContent, _extends({
557
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
559
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
558
560
  blocks: [].concat(_toConsumableArray(articleBody.slice(selectedIndex))),
559
561
  imageOptions: { w: 320, h: 240, fit: 'max' }
560
562
  }, client.config()))
@@ -609,7 +611,7 @@ var Article = function Article(props) {
609
611
  React__default.Fragment,
610
612
  null,
611
613
  React__default.createElement(BlockContent, _extends({
612
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
614
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
613
615
  blocks: [].concat(_toConsumableArray(articleBody.slice(0, _selectedIndex))),
614
616
  imageOptions: { w: 320, h: 240, fit: 'max' }
615
617
  }, client.config())),
@@ -621,7 +623,7 @@ var Article = function Article(props) {
621
623
  ),
622
624
  contextualADFlag && React__default.createElement('span', { className: 'clearfix' }),
623
625
  React__default.createElement(BlockContent, _extends({
624
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
626
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
625
627
  blocks: [].concat(_toConsumableArray(articleBody.slice(_selectedIndex))),
626
628
  imageOptions: { w: 320, h: 240, fit: 'max' }
627
629
  }, client.config()))
@@ -652,7 +654,7 @@ var Article = function Article(props) {
652
654
  React__default.Fragment,
653
655
  null,
654
656
  React__default.createElement(BlockContent, _extends({
655
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag),
657
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
656
658
  blocks: [].concat(_toConsumableArray(articleBody.slice(0, _selectedIndex2))),
657
659
  imageOptions: { w: 320, h: 240, fit: 'max' }
658
660
  }, client.config())),
@@ -663,14 +665,14 @@ var Article = function Article(props) {
663
665
  React__default.createElement(DFPAdSlot, _extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: _checkIsAdFound2 }))
664
666
  ),
665
667
  React__default.createElement(BlockContent, _extends({
666
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false),
668
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
667
669
  blocks: [].concat(_toConsumableArray(articleBody.slice(_selectedIndex2))),
668
670
  imageOptions: { w: 320, h: 240, fit: 'max' }
669
671
  }, client.config()))
670
672
  );
671
673
  } else {
672
674
  return React__default.createElement(BlockContent, _extends({
673
- serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, false, null, props.article.Ads),
675
+ serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, false, null, props.article.Ads, targeting),
674
676
  blocks: articleBody,
675
677
  imageOptions: { w: 320, h: 240, fit: 'max' }
676
678
  }, client.config()));
@@ -1318,8 +1320,21 @@ var View = function View(props) {
1318
1320
  return false;
1319
1321
  };
1320
1322
 
1323
+ var checkArticleSeries = function checkArticleSeries(article) {
1324
+ if (!article || !article.body) {
1325
+ return false;
1326
+ }
1327
+ for (var i = 0; i < article.body.length; i++) {
1328
+ if (article.body[i]._type === 'articleSeries') {
1329
+ return true;
1330
+ }
1331
+ }
1332
+ return false;
1333
+ };
1334
+
1321
1335
  var isVideoSeries = checkVideoSeries(props.article);
1322
- var needInfiniteScroll = ['Articles', 'Videos', 'Podcasts'].includes(article.category.name) && article.taxonomyMapping && article.passwordLock !== true && !isVideoSeries && !article.ExcludeFromInfiniteScroll && !sponsoredFlag;
1336
+ var isArticleSeries = checkArticleSeries(props.article);
1337
+ var needInfiniteScroll = ['Articles', 'Videos', 'Podcasts'].includes(article.category.name) && article.taxonomyMapping && article.passwordLock !== true && !isVideoSeries && !isArticleSeries && !article.ExcludeFromInfiniteScroll && !sponsoredFlag;
1323
1338
 
1324
1339
  if (['Articles', 'Videos', 'Podcasts'].includes(article.category.name)) {
1325
1340
  description = null;
@@ -38,7 +38,7 @@ import './smoothscroll-4b699764.js';
38
38
  import './GroupDeck.js';
39
39
  import 'react-bootstrap';
40
40
  import 'react-bootstrap/Button';
41
- export { g as default } from './index-539e2942.js';
41
+ export { g as default } from './index-ccfe8253.js';
42
42
  import './util-7700fc59.js';
43
43
  import './brightcove-react-player-loader.es-83f53e4e.js';
44
44
  import 'react-bootstrap/Pagination';
@@ -2,6 +2,7 @@ import { c as createCommonjsModule, u as unwrapExports } from './_commonjsHelper
2
2
  import { a as _Array$from, _ as _toConsumableArray } from './toConsumableArray-e7f3f5a6.js';
3
3
  import { _ as _extends } from './extends-229166d5.js';
4
4
  import { _ as _inherits$1, a as _classCallCheck$1, b as _possibleConstructorReturn$1, c as _Object$getPrototypeOf, d as _createClass$1 } from './inherits-9ddef7b3.js';
5
+ import { _ as _typeof$1 } from './typeof-fea75829.js';
5
6
  import React__default, { useState, useEffect, useRef } from 'react';
6
7
  import { l as lib_3 } from './index-93ec3c59.js';
7
8
  import PropTypes from 'prop-types';
@@ -2176,7 +2177,9 @@ var Video = function Video(_ref) {
2176
2177
  _ref$autoplay = _ref.autoplay,
2177
2178
  autoplay = _ref$autoplay === undefined ? false : _ref$autoplay,
2178
2179
  _ref$autoplayNextVide = _ref.autoplayNextVideo,
2179
- autoplayNextVideo = _ref$autoplayNextVide === undefined ? function () {} : _ref$autoplayNextVide;
2180
+ autoplayNextVideo = _ref$autoplayNextVide === undefined ? function () {} : _ref$autoplayNextVide,
2181
+ _ref$targeting = _ref.targeting,
2182
+ targeting = _ref$targeting === undefined ? null : _ref$targeting;
2180
2183
  var source = node.source,
2181
2184
  videoID = node.videoID,
2182
2185
  playlistID = node.playlistID,
@@ -2199,7 +2202,12 @@ var Video = function Video(_ref) {
2199
2202
  var onVideoSuccess = function onVideoSuccess(success) {
2200
2203
  //console.log('success:', success.ref)
2201
2204
  var player = success.ref;
2202
-
2205
+ if (_typeof$1(player.ima3) === 'object' && player.ima3.settings && player.ima3.settings.serverUrl && targeting !== null) {
2206
+ player.ima3.settings.debug = true;
2207
+ if (targeting.content_placement && targeting.document_url) {
2208
+ player.ima3.settings.serverUrl = player.ima3.settings.serverUrl + '&cust_params=' + encodeURIComponent('content_placement=' + targeting.content_placement + '&document_url=' + targeting.document_url);
2209
+ }
2210
+ }
2203
2211
  // this is video ready
2204
2212
  player.on('loadedmetadata', function (evt) {
2205
2213
  //console.log('loadedmetadata:', evt)
@@ -8020,8 +8028,9 @@ var ArticleSeries = function ArticleSeries(_ref) {
8020
8028
  var router = useRouter();
8021
8029
 
8022
8030
  var refArray = useRef([]);
8031
+ var adRefArray = useRef([]);
8023
8032
 
8024
- var _useState = useState(77),
8033
+ var _useState = useState(100),
8025
8034
  _useState2 = _slicedToArray(_useState, 2),
8026
8035
  NavoffsetTop = _useState2[0],
8027
8036
  setNavoffsetTop = _useState2[1];
@@ -8098,26 +8107,26 @@ var ArticleSeries = function ArticleSeries(_ref) {
8098
8107
  };
8099
8108
 
8100
8109
  useEffect(function () {
8101
- if (!firstLoad) {
8102
- scrollToArticle();
8103
- }
8104
8110
  try {
8105
- setNavoffsetTop(document.getElementById('navbar-ham').offsetHeight);
8111
+ setNavoffsetTop(document.getElementById('navbar-ham').offsetHeight - 15);
8106
8112
  } catch (e) {}
8107
8113
  }, []);
8108
8114
 
8109
8115
  var scrollToArticle = function scrollToArticle(id) {
8110
8116
  var localArticleID = id ? id : selectedArticle;
8111
8117
  var findArticle = function findArticle(ref) {
8112
- return ref.props.id === localArticleID;
8118
+ if (ref) {
8119
+ return ref.props.id === localArticleID;
8120
+ }
8121
+ return false;
8113
8122
  };
8114
8123
  var indexOfRef = refArray.current.findIndex(findArticle);
8115
8124
 
8116
8125
  if (indexOfRef >= 0) {
8117
- //console.log(refArray.current[indexOfRef].wraperRef.current)
8118
- refArray.current[indexOfRef].wraperRef.current.scrollIntoView({ behavior: 'smooth' });
8119
- window.scrollTo({ top: refArray.current[indexOfRef].wraperRef.current.offsetTop + NavoffsetTop, behavior: 'smooth' });
8126
+ //refArray.current[indexOfRef].wraperRef.current.scrollIntoView({ behavior: 'smooth' })
8127
+ window.scrollTo({ top: refArray.current[indexOfRef].wraperRef.current.offsetTop - NavoffsetTop, behavior: 'smooth' });
8120
8128
  }
8129
+ setFirstLoad(true);
8121
8130
  };
8122
8131
 
8123
8132
  var renderAuthorBiography = function renderAuthorBiography(biography) {
@@ -8132,10 +8141,10 @@ var ArticleSeries = function ArticleSeries(_ref) {
8132
8141
  // Change URL and do other changes
8133
8142
  var doChanges = function doChanges() {
8134
8143
  if (firstLoad) {
8135
- window.history.pushState({ page: path }, '', newPath);
8144
+ refreshAD();
8136
8145
  }
8146
+ window.history.pushState({ page: path }, '', newPath);
8137
8147
  document.title = title;
8138
- refreshAD();
8139
8148
  setFirstLoad(true);
8140
8149
  };
8141
8150
 
@@ -8175,6 +8184,26 @@ var ArticleSeries = function ArticleSeries(_ref) {
8175
8184
  };
8176
8185
  });
8177
8186
 
8187
+ useEffect(function () {
8188
+ if (!firstLoad) {
8189
+ if (main_39) {
8190
+ grabLoadedAds();
8191
+ }
8192
+ }
8193
+ }, []);
8194
+
8195
+ var grabLoadedAds = function grabLoadedAds() {
8196
+ console.dir(lib_3);
8197
+ lib_3.getGoogletag().then(function (googletag) {
8198
+ var checkIfReady = window.setInterval(function () {
8199
+ if (window.googletag && googletag.pubadsReady) {
8200
+ clearInterval(checkIfReady);
8201
+ scrollToArticle();
8202
+ }
8203
+ }, 1000);
8204
+ });
8205
+ };
8206
+
8178
8207
  var refreshAD = function refreshAD(path) {
8179
8208
  //const activeArticle = path
8180
8209
  //let targeting = getTargeting({ article: activeArticle, cpModificationRequired, position: props.position, prevUrl })
@@ -8216,13 +8245,38 @@ var ArticleSeries = function ArticleSeries(_ref) {
8216
8245
  )
8217
8246
  ),
8218
8247
  React__default.createElement('hr', { className: 'article-seperater' }),
8248
+ React__default.createElement(
8249
+ 'div',
8250
+ { className: 'ad-box', style: { textAlign: 'center' } },
8251
+ main_39 && Ads.map(function (ad, index) {
8252
+ if (index === 0) {
8253
+ return React__default.createElement(
8254
+ 'div',
8255
+ {
8256
+ key: 'addid-1',
8257
+ id: 'addid-1',
8258
+ ref: function ref(ele) {
8259
+ return adRefArray.current[0] = ele;
8260
+ },
8261
+ style: {
8262
+ display: 'flex',
8263
+ flex: '1 0 auto',
8264
+ justifyContent: 'center',
8265
+ alignItems: 'center',
8266
+ textAlign: 'center'
8267
+ } },
8268
+ ad.component
8269
+ );
8270
+ }
8271
+ })
8272
+ ),
8219
8273
  React__default.createElement(
8220
8274
  'div',
8221
8275
  { className: 'article-container', style: { marginBottom: '2rem' } },
8222
8276
  nodes.articles.map(function (article, index) {
8223
8277
  return React__default.createElement(
8224
- React__default.Fragment,
8225
- null,
8278
+ 'div',
8279
+ { key: article.title },
8226
8280
  React__default.createElement(
8227
8281
  InscreenSensor,
8228
8282
  {
@@ -8292,13 +8346,16 @@ var ArticleSeries = function ArticleSeries(_ref) {
8292
8346
  React__default.createElement(
8293
8347
  'div',
8294
8348
  { className: 'ad-box', style: { textAlign: 'center' } },
8295
- main_39 && nodes.articles.length - 1 !== index && Ads.map(function (ad, index) {
8296
- if (index === 0) {
8349
+ main_39 && nodes.articles.length - 1 !== index && Ads.map(function (ad, innerIndex) {
8350
+ if (innerIndex === 0) {
8297
8351
  return React__default.createElement(
8298
8352
  'div',
8299
8353
  {
8300
- key: index,
8301
- id: 'addid-' + index,
8354
+ key: 'addid-' + (index + 2),
8355
+ id: 'addid-' + (index + 2),
8356
+ ref: function ref(ele) {
8357
+ return adRefArray.current[index + 1] = ele;
8358
+ },
8302
8359
  style: {
8303
8360
  display: 'flex',
8304
8361
  flex: '1 0 auto',
@@ -8604,7 +8661,8 @@ var getSerializers = function getSerializers() {
8604
8661
  _props$2 = props[8],
8605
8662
  contextualADFlag = _props$2 === undefined ? false : _props$2,
8606
8663
  articleId = props[9],
8607
- Ads = props[10];
8664
+ Ads = props[10],
8665
+ targeting = props[11];
8608
8666
 
8609
8667
  return {
8610
8668
  types: {
@@ -8670,7 +8728,7 @@ var getSerializers = function getSerializers() {
8670
8728
  video: function video(_ref11) {
8671
8729
  var node = _ref11.node;
8672
8730
 
8673
- return React__default.createElement(Video, { node: node, autoplay: autoplay, accountIDs: videoAccountIDs || {} });
8731
+ return React__default.createElement(Video, { node: node, autoplay: autoplay, accountIDs: videoAccountIDs || {}, targeting: targeting });
8674
8732
  },
8675
8733
  audio: function audio(_ref12) {
8676
8734
  var node = _ref12.node;
package/dist/esm/index.js CHANGED
@@ -73,7 +73,7 @@ import './index-d2f90501.js';
73
73
  import './js.cookie-6874175c.js';
74
74
  export { default as EventsDeck } from './EventsDeck.js';
75
75
  export { default as CMEDeck } from './CMEDeck.js';
76
- export { g as getSerializers } from './index-539e2942.js';
76
+ export { g as getSerializers } from './index-ccfe8253.js';
77
77
  import './util-7700fc59.js';
78
78
  import './brightcove-react-player-loader.es-83f53e4e.js';
79
79
  import 'react-bootstrap/Pagination';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mjhls/mjh-framework",
3
- "version": "1.0.637",
3
+ "version": "1.0.639",
4
4
  "description": "Foundation Framework",
5
5
  "author": "mjh-framework",
6
6
  "license": "MIT",