@mjhls/mjh-framework 1.0.221 → 1.0.223
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 +174 -174
- package/dist/cjs/AdSlot-d87cef08.js +69 -0
- package/dist/cjs/DeckContent.js +116 -59
- package/dist/cjs/DeckQueue.js +3 -3
- package/dist/cjs/{Dfp-c4f1f12a.js → Dfp-8b6f25fe.js} +1 -1
- package/dist/cjs/{GridContent-089aa22c.js → GridContent-8b0ebfec.js} +26 -10
- package/dist/cjs/GridContent.js +5 -4
- package/dist/cjs/IssueContentDeck.js +1 -1
- package/dist/cjs/IssueDeck.js +1 -1
- package/dist/cjs/MasterDeck.js +11 -11
- package/dist/cjs/{Normal-47d9e184.js → Normal-78631b6e.js} +78 -93
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/QueueDeckExpanded.js +6 -5
- package/dist/cjs/{TaxonomyCard-d97685e2.js → TaxonomyCard-f24d8ec9.js} +1 -1
- package/dist/cjs/TaxonomyCard.js +2 -2
- package/dist/cjs/TemplateNormal.js +3 -2
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/VideoSeriesListing.js +2 -2
- package/dist/cjs/{YoutubeGroup-ad994d02.js → YoutubeGroup-d2d9e57c.js} +4 -4
- package/dist/cjs/YoutubeGroup.js +1 -1
- package/dist/cjs/{index-a4c53ff4.js → index-eb596973.js} +18 -18
- package/dist/cjs/index.js +203 -182
- package/dist/cjs/{main-58839f4e.js → main-c1bd47fe.js} +6 -6
- package/dist/cjs/{visibility-sensor-bea3105d.js → visibility-sensor-59b2685c.js} +2501 -1437
- package/dist/esm/AdSlot-b67f8534.js +64 -0
- package/dist/esm/DeckContent.js +116 -59
- package/dist/esm/DeckQueue.js +3 -3
- package/dist/esm/{Dfp-6731ac01.js → Dfp-6c8d69e6.js} +1 -1
- package/dist/esm/{GridContent-214acb61.js → GridContent-0777cc42.js} +26 -10
- package/dist/esm/GridContent.js +5 -4
- package/dist/esm/IssueContentDeck.js +1 -1
- package/dist/esm/IssueDeck.js +1 -1
- package/dist/esm/MasterDeck.js +11 -11
- package/dist/esm/{Normal-be430fa9.js → Normal-7d33c7bf.js} +78 -92
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/QueueDeckExpanded.js +6 -5
- package/dist/esm/{TaxonomyCard-f9c93953.js → TaxonomyCard-ca8c7c8a.js} +1 -1
- package/dist/esm/TaxonomyCard.js +2 -2
- package/dist/esm/TemplateNormal.js +3 -2
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/VideoSeriesListing.js +2 -2
- package/dist/esm/{YoutubeGroup-1368335c.js → YoutubeGroup-d3b92eb5.js} +4 -4
- package/dist/esm/YoutubeGroup.js +1 -1
- package/dist/esm/{index-ca4ff5cb.js → index-b7bbf1d4.js} +18 -18
- package/dist/esm/index.js +204 -183
- package/dist/esm/{main-dea495b7.js → main-2504c03f.js} +6 -6
- package/dist/esm/{visibility-sensor-675d3fa1.js → visibility-sensor-61158020.js} +2501 -1437
- package/package.json +93 -93
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import React__default, { useState } from 'react';
|
|
2
|
+
import { b as lib_2 } from './index-6a79dad6.js';
|
|
3
|
+
import PropTypes from 'prop-types';
|
|
4
|
+
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
5
|
+
import { s as slicedToArray } from './_babelHelpers-67c05996.js';
|
|
6
|
+
|
|
7
|
+
var DFPAdSlot = function DFPAdSlot(_ref) {
|
|
8
|
+
var adUnit = _ref.adUnit,
|
|
9
|
+
sizeMapping = _ref.sizeMapping,
|
|
10
|
+
className = _ref.className,
|
|
11
|
+
slotId = _ref.slotId,
|
|
12
|
+
sizes = _ref.sizes,
|
|
13
|
+
_ref$targeting = _ref.targeting,
|
|
14
|
+
targeting = _ref$targeting === undefined ? {} : _ref$targeting;
|
|
15
|
+
|
|
16
|
+
var _useState = useState(false),
|
|
17
|
+
_useState2 = slicedToArray(_useState, 2),
|
|
18
|
+
adRendered = _useState2[0],
|
|
19
|
+
setAdRendered = _useState2[1];
|
|
20
|
+
|
|
21
|
+
var _useState3 = useState(false),
|
|
22
|
+
_useState4 = slicedToArray(_useState3, 2),
|
|
23
|
+
adRefreshable = _useState4[0],
|
|
24
|
+
setAdRefreshable = _useState4[1];
|
|
25
|
+
|
|
26
|
+
var handleVisibilityChange = debounce_1(function (_ref2) {
|
|
27
|
+
var event = _ref2.event;
|
|
28
|
+
|
|
29
|
+
if (event.inViewPercentage <= 0) {
|
|
30
|
+
setAdRefreshable(false);
|
|
31
|
+
} else {
|
|
32
|
+
setAdRefreshable(true);
|
|
33
|
+
}
|
|
34
|
+
}, 500);
|
|
35
|
+
|
|
36
|
+
return React__default.createElement(
|
|
37
|
+
'div',
|
|
38
|
+
{ className: className },
|
|
39
|
+
React__default.createElement(lib_2, {
|
|
40
|
+
slotId: slotId,
|
|
41
|
+
sizes: sizes,
|
|
42
|
+
adUnit: adUnit,
|
|
43
|
+
sizeMapping: sizeMapping,
|
|
44
|
+
targetingArguments: targeting,
|
|
45
|
+
onSlotRender: function onSlotRender(eventData) {
|
|
46
|
+
setAdRendered(true);
|
|
47
|
+
},
|
|
48
|
+
onSlotVisibilityChanged: handleVisibilityChange,
|
|
49
|
+
shouldRefresh: function shouldRefresh() {
|
|
50
|
+
if (adRendered && adRefreshable) return true;else return false;
|
|
51
|
+
}
|
|
52
|
+
})
|
|
53
|
+
);
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
DFPAdSlot.propTypes = {
|
|
57
|
+
adUnit: PropTypes.string.isRequired,
|
|
58
|
+
slotId: PropTypes.string,
|
|
59
|
+
className: PropTypes.string,
|
|
60
|
+
sizeMapping: PropTypes.array,
|
|
61
|
+
sizes: PropTypes.array
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
export { DFPAdSlot as D };
|
package/dist/esm/DeckContent.js
CHANGED
|
@@ -6,16 +6,17 @@ import Container from 'react-bootstrap/Container';
|
|
|
6
6
|
import Row from 'react-bootstrap/Row';
|
|
7
7
|
import Col from 'react-bootstrap/Col';
|
|
8
8
|
import Card from 'react-bootstrap/Card';
|
|
9
|
-
import { I as InfiniteScroll, V as VisibilitySensor, m as moment } from './visibility-sensor-
|
|
9
|
+
import { I as InfiniteScroll, V as VisibilitySensor, m as moment } from './visibility-sensor-61158020.js';
|
|
10
10
|
import 'next/link';
|
|
11
11
|
import { withRouter } from 'next/router';
|
|
12
12
|
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
13
13
|
import 'react-dom';
|
|
14
|
-
import { i as imageUrlBuilder } from './index-
|
|
14
|
+
import { i as imageUrlBuilder } from './index-b7bbf1d4.js';
|
|
15
15
|
import { L as LazyLoad } from './index-3c1ee9ab.js';
|
|
16
|
-
import { a as main_36 } from './main-
|
|
16
|
+
import { a as main_36 } from './main-2504c03f.js';
|
|
17
17
|
import { c as clean_html_1 } from './entities-e85d3a4a.js';
|
|
18
18
|
import { i as inherits, c as createClass, a as classCallCheck, p as possibleConstructorReturn, _ as _extends, t as toConsumableArray } from './_babelHelpers-67c05996.js';
|
|
19
|
+
import { D as DFPAdSlot } from './AdSlot-b67f8534.js';
|
|
19
20
|
|
|
20
21
|
var DeckContent = function (_React$Component) {
|
|
21
22
|
inherits(DeckContent, _React$Component);
|
|
@@ -156,14 +157,14 @@ var DeckContent = function (_React$Component) {
|
|
|
156
157
|
var newPath = pageNumber === 1 ? '' + path : path + '?page=' + pageNumber;
|
|
157
158
|
|
|
158
159
|
// please leave this for later debug purpose : Yong Jun.
|
|
159
|
-
/* console.log('page change reported', {
|
|
160
|
-
currentPage: currentPage,
|
|
161
|
-
pageNumber: pageNumber,
|
|
162
|
-
pathname: pathname,
|
|
163
|
-
path: path,
|
|
164
|
-
newPath: newPath,
|
|
165
|
-
firstPage: pageNumber === 1,
|
|
166
|
-
queryString: queryString
|
|
160
|
+
/* console.log('page change reported', {
|
|
161
|
+
currentPage: currentPage,
|
|
162
|
+
pageNumber: pageNumber,
|
|
163
|
+
pathname: pathname,
|
|
164
|
+
path: path,
|
|
165
|
+
newPath: newPath,
|
|
166
|
+
firstPage: pageNumber === 1,
|
|
167
|
+
queryString: queryString
|
|
167
168
|
}) */
|
|
168
169
|
|
|
169
170
|
if (pageview) {
|
|
@@ -216,16 +217,47 @@ var DeckContent = function (_React$Component) {
|
|
|
216
217
|
);
|
|
217
218
|
}
|
|
218
219
|
} else return null;
|
|
219
|
-
}, _this.cardLoader = function (page, columns, variant) {
|
|
220
|
+
}, _this.cardLoader = function (page, columns, variant, showBI, brandInsight) {
|
|
220
221
|
var mode = variant && variant === 'bottom' ? 'column-reverse' : 'column';
|
|
221
222
|
|
|
222
223
|
var itemCounter = 0;
|
|
223
224
|
var lgVar = 12;
|
|
224
225
|
var numberOfItemsBeforeAd = 6;
|
|
226
|
+
|
|
227
|
+
var insert = function insert(arr, index, newElement) {
|
|
228
|
+
return [].concat(toConsumableArray(arr.slice(0, index)), [newElement], toConsumableArray(arr.slice(index)));
|
|
229
|
+
};
|
|
230
|
+
var articles = [];
|
|
231
|
+
if (showBI) {
|
|
232
|
+
var data = _this.state.data;
|
|
233
|
+
articles = data;
|
|
234
|
+
var pos = 3;
|
|
235
|
+
for (var i = 1; pos < articles.length; i++) {
|
|
236
|
+
var inFeedAd = {
|
|
237
|
+
adUnit: brandInsight.adUnit,
|
|
238
|
+
className: brandInsight.className,
|
|
239
|
+
networkID: brandInsight.networkID,
|
|
240
|
+
sizes: brandInsight.sizes,
|
|
241
|
+
slotId: brandInsight.slotId,
|
|
242
|
+
targeting: {
|
|
243
|
+
pos: 'article' + i,
|
|
244
|
+
content_placement: brandInsight.targeting.content_placement,
|
|
245
|
+
document_url: brandInsight.targeting.document_url
|
|
246
|
+
},
|
|
247
|
+
_type: 'BrandInsight'
|
|
248
|
+
};
|
|
249
|
+
|
|
250
|
+
articles = insert(articles, pos, inFeedAd);
|
|
251
|
+
pos += brandInsight.interval + 1;
|
|
252
|
+
}
|
|
253
|
+
} else {
|
|
254
|
+
articles = _this.state.data;
|
|
255
|
+
}
|
|
256
|
+
|
|
225
257
|
return React__default.createElement(
|
|
226
258
|
Row,
|
|
227
259
|
null,
|
|
228
|
-
|
|
260
|
+
articles && articles.map(function (row, index) {
|
|
229
261
|
if (columns === 'rotate' && itemCounter % 3 === 0) {
|
|
230
262
|
lgVar = 12;
|
|
231
263
|
} else if (columns && columns !== 'rotate') {
|
|
@@ -233,64 +265,87 @@ var DeckContent = function (_React$Component) {
|
|
|
233
265
|
} else {
|
|
234
266
|
lgVar = 6;
|
|
235
267
|
}
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
React__default.Fragment,
|
|
241
|
-
{ key: itemCounter },
|
|
242
|
-
React__default.createElement(
|
|
243
|
-
VisibilitySensor,
|
|
244
|
-
{
|
|
245
|
-
onChange: function onChange(isVisible) {
|
|
246
|
-
isVisible && _this.changePageNumber(pageNumber);
|
|
247
|
-
} },
|
|
268
|
+
if (row._type === 'BrandInsight' && row.adUnit) {
|
|
269
|
+
return React__default.createElement(
|
|
270
|
+
React__default.Fragment,
|
|
271
|
+
{ key: itemCounter, className: 'brand-insight-wrapper' },
|
|
248
272
|
React__default.createElement(
|
|
249
273
|
Col,
|
|
250
|
-
{
|
|
274
|
+
{ sm: 12, counter: itemCounter++, style: { display: 'flex', flex: '1 0 auto' } },
|
|
251
275
|
React__default.createElement(
|
|
252
276
|
Card,
|
|
253
|
-
{ className: 'content-card', style: { flexDirection:
|
|
254
|
-
(row.thumbnail && row.thumbnail.asset || _this.props.defaultImage) && React__default.createElement(
|
|
255
|
-
'a',
|
|
256
|
-
{ href: _this.mapping[contentCategoryName] + '/' + row.url.current },
|
|
257
|
-
React__default.createElement(
|
|
258
|
-
LazyLoad,
|
|
259
|
-
{ height: _this.props.imageHeight },
|
|
260
|
-
React__default.createElement(Card.Img, { variant: 'top', src: _this.renderCardImage(row, page), alt: row.thumbnail && row.thumbnail.asset ? row.thumbnail.asset.originalFilename : '' })
|
|
261
|
-
)
|
|
262
|
-
),
|
|
277
|
+
{ className: 'content-card ad-wrapper', style: { flexDirection: index === 0 || index % 4 === 0 ? 'top' : 'row' } },
|
|
263
278
|
React__default.createElement(
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
React__default.createElement(
|
|
279
|
+
'div',
|
|
280
|
+
{ className: row.className, style: { width: '100%', height: 'auto' } },
|
|
281
|
+
React__default.createElement(DFPAdSlot, { networkID: row.networkID, adUnit: row.adUnit, slotId: row.slotId, targeting: row.targeting, sizes: row.sizes })
|
|
282
|
+
)
|
|
283
|
+
)
|
|
284
|
+
)
|
|
285
|
+
);
|
|
286
|
+
} else {
|
|
287
|
+
var pageNumber = row.pageNumber || _this.state.page;
|
|
288
|
+
var contentCategoryName = row.contentCategory && row.contentCategory.name && _this.mapping[row.contentCategory.name] ? row.contentCategory.name : 'Articles';
|
|
289
|
+
return React__default.createElement(
|
|
290
|
+
React__default.Fragment,
|
|
291
|
+
{ key: itemCounter },
|
|
292
|
+
React__default.createElement(
|
|
293
|
+
VisibilitySensor,
|
|
294
|
+
{
|
|
295
|
+
onChange: function onChange(isVisible) {
|
|
296
|
+
isVisible && _this.changePageNumber(pageNumber);
|
|
297
|
+
} },
|
|
298
|
+
React__default.createElement(
|
|
299
|
+
Col,
|
|
300
|
+
{ md: 12, lg: lgVar, counter: itemCounter++, style: { display: 'flex', flex: '1 0 auto' } },
|
|
301
|
+
React__default.createElement(
|
|
302
|
+
Card,
|
|
303
|
+
{ className: 'content-card', style: { flexDirection: mode } },
|
|
304
|
+
(row.thumbnail && row.thumbnail.asset || _this.props.defaultImage) && React__default.createElement(
|
|
267
305
|
'a',
|
|
268
306
|
{ href: _this.mapping[contentCategoryName] + '/' + row.url.current },
|
|
269
307
|
React__default.createElement(
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
308
|
+
LazyLoad,
|
|
309
|
+
{ height: _this.props.imageHeight },
|
|
310
|
+
React__default.createElement(Card.Img, {
|
|
311
|
+
variant: 'top',
|
|
312
|
+
src: _this.renderCardImage(row, page),
|
|
313
|
+
alt: row.thumbnail && row.thumbnail.asset ? row.thumbnail.asset.originalFilename : ''
|
|
314
|
+
})
|
|
273
315
|
)
|
|
274
316
|
),
|
|
275
|
-
_this.props.showPublished && row.published && React__default.createElement(
|
|
276
|
-
Card.Subtitle,
|
|
277
|
-
null,
|
|
278
|
-
moment(row.published).format('MMMM DD, YYYY')
|
|
279
|
-
),
|
|
280
|
-
_this.props.showAuthor && row.authorMapping && row.authorMapping.length > 0 && row.authorMapping.map(function (authorDetail, index) {
|
|
281
|
-
return _this.renderAuthor(authorDetail, index, row.authorMapping.length);
|
|
282
|
-
}),
|
|
283
317
|
React__default.createElement(
|
|
284
|
-
Card.
|
|
318
|
+
Card.Body,
|
|
285
319
|
null,
|
|
286
|
-
|
|
320
|
+
React__default.createElement(
|
|
321
|
+
'a',
|
|
322
|
+
{ href: _this.mapping[contentCategoryName] + '/' + row.url.current },
|
|
323
|
+
React__default.createElement(
|
|
324
|
+
Card.Title,
|
|
325
|
+
null,
|
|
326
|
+
row.title
|
|
327
|
+
)
|
|
328
|
+
),
|
|
329
|
+
_this.props.showPublished && row.published && React__default.createElement(
|
|
330
|
+
Card.Subtitle,
|
|
331
|
+
null,
|
|
332
|
+
moment(row.published).format('MMMM DD, YYYY')
|
|
333
|
+
),
|
|
334
|
+
_this.props.showAuthor && row.authorMapping && row.authorMapping.length > 0 && row.authorMapping.map(function (authorDetail, index) {
|
|
335
|
+
return _this.renderAuthor(authorDetail, index, row.authorMapping.length);
|
|
336
|
+
}),
|
|
337
|
+
React__default.createElement(
|
|
338
|
+
Card.Text,
|
|
339
|
+
null,
|
|
340
|
+
clean_html_1(row.summary)
|
|
341
|
+
)
|
|
287
342
|
)
|
|
288
343
|
)
|
|
289
344
|
)
|
|
290
|
-
)
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
345
|
+
),
|
|
346
|
+
main_36 && _this.props.rightItems && (index + 1) % numberOfItemsBeforeAd === 0 && _this.renderMobileAd(index, numberOfItemsBeforeAd)
|
|
347
|
+
);
|
|
348
|
+
}
|
|
294
349
|
})
|
|
295
350
|
);
|
|
296
351
|
}, _this.renderMobileAd = function (index, numberOfItemsBeforeAd) {
|
|
@@ -354,7 +409,9 @@ var DeckContent = function (_React$Component) {
|
|
|
354
409
|
columns = _props.columns,
|
|
355
410
|
variant = _props.variant,
|
|
356
411
|
autoScroll = _props.autoScroll,
|
|
357
|
-
page = _props.page
|
|
412
|
+
page = _props.page,
|
|
413
|
+
showBI = _props.showBI,
|
|
414
|
+
brandInsight = _props.brandInsight;
|
|
358
415
|
|
|
359
416
|
|
|
360
417
|
return React__default.createElement(
|
|
@@ -369,7 +426,7 @@ var DeckContent = function (_React$Component) {
|
|
|
369
426
|
React__default.createElement(
|
|
370
427
|
Container,
|
|
371
428
|
null,
|
|
372
|
-
this.cardLoader(page, columns, variant)
|
|
429
|
+
this.cardLoader(page, columns, variant, showBI, brandInsight)
|
|
373
430
|
)
|
|
374
431
|
),
|
|
375
432
|
React__default.createElement(
|
|
@@ -383,7 +440,7 @@ var DeckContent = function (_React$Component) {
|
|
|
383
440
|
React__default.createElement(
|
|
384
441
|
Container,
|
|
385
442
|
null,
|
|
386
|
-
this.cardLoader(page, columns, variant)
|
|
443
|
+
this.cardLoader(page, columns, variant, showBI, brandInsight)
|
|
387
444
|
),
|
|
388
445
|
React__default.createElement(
|
|
389
446
|
'div',
|
package/dist/esm/DeckQueue.js
CHANGED
|
@@ -6,14 +6,14 @@ import Container from 'react-bootstrap/Container';
|
|
|
6
6
|
import Row from 'react-bootstrap/Row';
|
|
7
7
|
import Col from 'react-bootstrap/Col';
|
|
8
8
|
import Card from 'react-bootstrap/Card';
|
|
9
|
-
import { V as VisibilitySensor, m as moment, I as InfiniteScroll } from './visibility-sensor-
|
|
9
|
+
import { V as VisibilitySensor, m as moment, I as InfiniteScroll } from './visibility-sensor-61158020.js';
|
|
10
10
|
import 'next/link';
|
|
11
11
|
import { withRouter } from 'next/router';
|
|
12
12
|
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
13
13
|
import 'react-dom';
|
|
14
|
-
import { i as imageUrlBuilder } from './index-
|
|
14
|
+
import { i as imageUrlBuilder } from './index-b7bbf1d4.js';
|
|
15
15
|
import { L as LazyLoad } from './index-3c1ee9ab.js';
|
|
16
|
-
import { a as main_36 } from './main-
|
|
16
|
+
import { a as main_36 } from './main-2504c03f.js';
|
|
17
17
|
import { c as clean_html_1 } from './entities-e85d3a4a.js';
|
|
18
18
|
import { i as inherits, c as createClass, a as classCallCheck, p as possibleConstructorReturn, _ as _extends, t as toConsumableArray } from './_babelHelpers-67c05996.js';
|
|
19
19
|
import { g as get_1 } from './get-b074314b.js';
|
|
@@ -2,7 +2,7 @@ import React__default, { useState } from 'react';
|
|
|
2
2
|
import './_commonjsHelpers-ae1b5db5.js';
|
|
3
3
|
import { l as lib_1, b as lib_2 } from './index-6a79dad6.js';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import { V as VisibilitySensor } from './visibility-sensor-
|
|
5
|
+
import { V as VisibilitySensor } from './visibility-sensor-61158020.js';
|
|
6
6
|
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
7
7
|
import 'react-dom';
|
|
8
8
|
import { s as slicedToArray } from './_babelHelpers-67c05996.js';
|
|
@@ -4,19 +4,20 @@ import Container from 'react-bootstrap/Container';
|
|
|
4
4
|
import Row from 'react-bootstrap/Row';
|
|
5
5
|
import Col from 'react-bootstrap/Col';
|
|
6
6
|
import Card from 'react-bootstrap/Card';
|
|
7
|
-
import { m as moment, V as VisibilitySensor, I as InfiniteScroll } from './visibility-sensor-
|
|
7
|
+
import { m as moment, V as VisibilitySensor, I as InfiniteScroll } from './visibility-sensor-61158020.js';
|
|
8
8
|
import 'next/link';
|
|
9
9
|
import { withRouter } from 'next/router';
|
|
10
10
|
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
11
|
-
import { i as imageUrlBuilder } from './index-
|
|
11
|
+
import { i as imageUrlBuilder } from './index-b7bbf1d4.js';
|
|
12
12
|
import { L as LazyLoad } from './index-3c1ee9ab.js';
|
|
13
|
-
import { a as main_36 } from './main-
|
|
13
|
+
import { a as main_36 } from './main-2504c03f.js';
|
|
14
14
|
import { c as clean_html_1 } from './entities-e85d3a4a.js';
|
|
15
15
|
import { i as inherits, c as createClass, t as toConsumableArray, a as classCallCheck, p as possibleConstructorReturn, _ as _extends } from './_babelHelpers-67c05996.js';
|
|
16
|
+
import { D as DFPAdSlot } from './AdSlot-b67f8534.js';
|
|
16
17
|
import { g as get_1 } from './get-b074314b.js';
|
|
17
18
|
|
|
18
19
|
var Dfp = React__default.lazy(function () {
|
|
19
|
-
return import('./Dfp-
|
|
20
|
+
return import('./Dfp-6c8d69e6.js');
|
|
20
21
|
});
|
|
21
22
|
|
|
22
23
|
var AD = function AD(props) {
|
|
@@ -336,11 +337,22 @@ var GridContent = function (_React$Component) {
|
|
|
336
337
|
var data = this.state.data;
|
|
337
338
|
posts = data;
|
|
338
339
|
var pos = 3;
|
|
339
|
-
var i = 1;
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
340
|
+
for (var i = 1; pos < posts.length; i++) {
|
|
341
|
+
var inFeedAd = {
|
|
342
|
+
adUnit: brandInsight.adUnit,
|
|
343
|
+
className: brandInsight.className,
|
|
344
|
+
networkID: brandInsight.networkID,
|
|
345
|
+
sizes: brandInsight.sizes,
|
|
346
|
+
slotId: brandInsight.slotId,
|
|
347
|
+
targeting: {
|
|
348
|
+
pos: 'article' + i,
|
|
349
|
+
content_placement: brandInsight.targeting.content_placement,
|
|
350
|
+
document_url: brandInsight.targeting.document_url
|
|
351
|
+
},
|
|
352
|
+
_type: 'BrandInsight'
|
|
353
|
+
};
|
|
354
|
+
|
|
355
|
+
posts = insert(posts, pos, inFeedAd);
|
|
344
356
|
pos += brandInsight.interval + 1;
|
|
345
357
|
}
|
|
346
358
|
} else {
|
|
@@ -488,7 +500,11 @@ var GridContent = function (_React$Component) {
|
|
|
488
500
|
React__default.createElement(
|
|
489
501
|
Card,
|
|
490
502
|
{ className: 'content-card ad-wrapper', style: { flexDirection: index === 0 || index % 4 === 0 ? 'top' : 'row' } },
|
|
491
|
-
React__default.createElement(
|
|
503
|
+
React__default.createElement(
|
|
504
|
+
'div',
|
|
505
|
+
{ className: row.className },
|
|
506
|
+
React__default.createElement(DFPAdSlot, { networkID: row.networkID, adUnit: row.adUnit, slotId: row.slotId, targeting: row.targeting, sizes: row.sizes })
|
|
507
|
+
)
|
|
492
508
|
)
|
|
493
509
|
)
|
|
494
510
|
);
|
package/dist/esm/GridContent.js
CHANGED
|
@@ -6,15 +6,16 @@ import 'react-bootstrap/Container';
|
|
|
6
6
|
import 'react-bootstrap/Row';
|
|
7
7
|
import 'react-bootstrap/Col';
|
|
8
8
|
import 'react-bootstrap/Card';
|
|
9
|
-
import './visibility-sensor-
|
|
9
|
+
import './visibility-sensor-61158020.js';
|
|
10
10
|
import 'next/link';
|
|
11
11
|
import 'next/router';
|
|
12
12
|
import './debounce-dc0c02e5.js';
|
|
13
13
|
import 'react-dom';
|
|
14
|
-
import './index-
|
|
14
|
+
import './index-b7bbf1d4.js';
|
|
15
15
|
import './index-3c1ee9ab.js';
|
|
16
|
-
import './main-
|
|
16
|
+
import './main-2504c03f.js';
|
|
17
17
|
import './entities-e85d3a4a.js';
|
|
18
18
|
import './_babelHelpers-67c05996.js';
|
|
19
|
+
import './AdSlot-b67f8534.js';
|
|
19
20
|
import './get-b074314b.js';
|
|
20
|
-
export { G as default } from './GridContent-
|
|
21
|
+
export { G as default } from './GridContent-0777cc42.js';
|
|
@@ -6,7 +6,7 @@ import Col from 'react-bootstrap/Col';
|
|
|
6
6
|
import Card from 'react-bootstrap/Card';
|
|
7
7
|
import 'next/link';
|
|
8
8
|
import 'react-dom';
|
|
9
|
-
import { i as imageUrlBuilder } from './index-
|
|
9
|
+
import { i as imageUrlBuilder } from './index-b7bbf1d4.js';
|
|
10
10
|
import { L as LazyLoad } from './index-3c1ee9ab.js';
|
|
11
11
|
import Badge from 'react-bootstrap/Badge';
|
|
12
12
|
|
package/dist/esm/IssueDeck.js
CHANGED
|
@@ -6,7 +6,7 @@ import Col from 'react-bootstrap/Col';
|
|
|
6
6
|
import Card from 'react-bootstrap/Card';
|
|
7
7
|
import 'next/link';
|
|
8
8
|
import 'react-dom';
|
|
9
|
-
import { i as imageUrlBuilder } from './index-
|
|
9
|
+
import { i as imageUrlBuilder } from './index-b7bbf1d4.js';
|
|
10
10
|
import { L as LazyLoad } from './index-3c1ee9ab.js';
|
|
11
11
|
import Button from 'react-bootstrap/Button';
|
|
12
12
|
|
package/dist/esm/MasterDeck.js
CHANGED
|
@@ -6,13 +6,13 @@ import Container from 'react-bootstrap/Container';
|
|
|
6
6
|
import Row from 'react-bootstrap/Row';
|
|
7
7
|
import 'react-bootstrap/Col';
|
|
8
8
|
import 'react-bootstrap/Card';
|
|
9
|
-
import { I as InfiniteScroll, V as VisibilitySensor } from './visibility-sensor-
|
|
9
|
+
import { I as InfiniteScroll, V as VisibilitySensor } from './visibility-sensor-61158020.js';
|
|
10
10
|
import 'next/link';
|
|
11
11
|
import { withRouter } from 'next/router';
|
|
12
12
|
import { d as debounce_1 } from './debounce-dc0c02e5.js';
|
|
13
13
|
import 'react-dom';
|
|
14
|
-
import './index-
|
|
15
|
-
import { a as main_36 } from './main-
|
|
14
|
+
import './index-b7bbf1d4.js';
|
|
15
|
+
import { a as main_36 } from './main-2504c03f.js';
|
|
16
16
|
import { i as inherits, c as createClass, a as classCallCheck, p as possibleConstructorReturn, _ as _extends, t as toConsumableArray } from './_babelHelpers-67c05996.js';
|
|
17
17
|
|
|
18
18
|
var MasterDeck = function (_React$Component) {
|
|
@@ -158,14 +158,14 @@ var MasterDeck = function (_React$Component) {
|
|
|
158
158
|
var newPath = pageNumber === 1 ? '' + path : path + '?page=' + pageNumber;
|
|
159
159
|
|
|
160
160
|
// please leave this for later debug purpose : Yong Jun.
|
|
161
|
-
/* console.log('page change reported', {
|
|
162
|
-
currentPage: currentPage,
|
|
163
|
-
pageNumber: pageNumber,
|
|
164
|
-
pathname: pathname,
|
|
165
|
-
path: path,
|
|
166
|
-
newPath: newPath,
|
|
167
|
-
firstPage: pageNumber === 1,
|
|
168
|
-
queryString: queryString
|
|
161
|
+
/* console.log('page change reported', {
|
|
162
|
+
currentPage: currentPage,
|
|
163
|
+
pageNumber: pageNumber,
|
|
164
|
+
pathname: pathname,
|
|
165
|
+
path: path,
|
|
166
|
+
newPath: newPath,
|
|
167
|
+
firstPage: pageNumber === 1,
|
|
168
|
+
queryString: queryString
|
|
169
169
|
}) */
|
|
170
170
|
|
|
171
171
|
if (pageview) {
|