@mjhls/mjh-framework 1.0.671-beta.0 → 1.0.671
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/dist/cjs/AD.js +1 -1
- package/dist/cjs/AD300x250.js +3 -3
- package/dist/cjs/AD300x250x600.js +3 -3
- package/dist/cjs/AD728x90.js +4 -4
- package/dist/cjs/ADFloatingFooter.js +2 -2
- package/dist/cjs/ADGutter.js +2 -2
- package/dist/cjs/ADSkyscraper.js +2 -2
- package/dist/cjs/ADSponsoredResources.js +2 -2
- package/dist/cjs/ADWebcast.js +2 -2
- package/dist/cjs/ADWelcome.js +2 -2
- package/dist/cjs/AdSlot.js +2 -2
- package/dist/cjs/AdSlotsProvider.js +1 -1
- package/dist/cjs/ArticleCarousel.js +3 -3
- package/dist/cjs/ArticleSeriesListing.js +4 -4
- package/dist/cjs/Auth.js +507 -256
- package/dist/cjs/{BlockContent-091a991f.js → BlockContent-88f69acd.js} +1 -1
- package/dist/cjs/CMEDeck.js +5 -5
- package/dist/cjs/Column3.js +4 -4
- package/dist/cjs/ConferenceArticleCard.js +2 -2
- package/dist/cjs/DeckContent.js +7 -7
- package/dist/cjs/DeckQueue.js +6 -6
- package/dist/cjs/{Dfp-f6a18ed2.js → Dfp-b2bc3b97.js} +1 -1
- package/dist/cjs/EventsDeck.js +5 -5
- package/dist/cjs/ExternalResources.js +7 -7
- package/dist/cjs/Feature.js +3 -3
- package/dist/cjs/ForbesHero.js +2 -2
- package/dist/cjs/GridContent.js +10 -10
- package/dist/cjs/GridHero.js +2 -2
- package/dist/cjs/GroupDeck.js +1 -1
- package/dist/cjs/HamMagazine.js +4 -4
- package/dist/cjs/Hero.js +1 -1
- package/dist/cjs/HorizontalHero.js +2 -2
- package/dist/cjs/IssueContentDeck.js +2 -2
- package/dist/cjs/IssueDeck.js +2 -2
- package/dist/cjs/IssueLanding.js +7 -7
- package/dist/cjs/LeftNav.js +2 -2
- package/dist/cjs/MasterDeck.js +8 -8
- package/dist/cjs/NavMagazine.js +4 -4
- package/dist/cjs/NavNative.js +3 -3
- package/dist/cjs/OncliveHero.js +2 -2
- package/dist/cjs/OncliveLargeHero.js +2 -2
- package/dist/cjs/PartnerDetailListing.js +15 -1212
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/QueueDeckExpanded.js +9 -9
- package/dist/cjs/RecentNews.js +2 -2
- package/dist/cjs/RelatedContent.js +2 -2
- package/dist/cjs/{SocialSearchComponent-81a50f81.js → SocialSearchComponent-962b1344.js} +5 -5
- package/dist/cjs/TaxonomyCard.js +2 -2
- package/dist/cjs/TemplateNormal.js +3 -3
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/Ustream.js +2 -2
- package/dist/cjs/VerticalHero.js +2 -2
- package/dist/cjs/VideoSeriesCard.js +2 -2
- package/dist/cjs/VideoSeriesListing.js +3 -3
- package/dist/cjs/View.js +111 -269
- package/dist/cjs/YahooHero.js +2 -2
- package/dist/cjs/YoutubeGroup.js +1 -1
- package/dist/cjs/getQuery.js +2 -2
- package/dist/cjs/getRelatedArticle.js +5 -354
- package/dist/cjs/getSerializers.js +6 -6
- package/dist/cjs/{getTargeting-9af0ef69.js → getTargeting-fee8c429.js} +2 -2
- package/dist/cjs/getTargeting.js +1 -1
- package/dist/cjs/{index-fa8ed292.js → index-2d0a4911.js} +34 -27
- package/dist/cjs/{index-3294d3bc.js → index-5be2866f.js} +1 -1
- package/dist/cjs/{index-2dddb8be.js → index-94d2f1de.js} +462 -450
- package/dist/cjs/{index-be0c82be.js → index-b5eb3ff8.js} +20 -19
- package/dist/cjs/{index.es-9110add6.js → index.es-ab3f2690.js} +3 -1
- package/dist/cjs/index.js +16 -15
- package/dist/cjs/{main-a4cb15bb.js → main-b6c96c8d.js} +67 -36
- package/dist/cjs/{moment-575fe24c.js → moment-66a6a284.js} +1 -1
- package/dist/cjs/urlFor.js +1 -1
- package/dist/esm/AD.js +1 -1
- package/dist/esm/AD300x250.js +3 -3
- package/dist/esm/AD300x250x600.js +3 -3
- package/dist/esm/AD728x90.js +4 -4
- package/dist/esm/ADFloatingFooter.js +2 -2
- package/dist/esm/ADGutter.js +2 -2
- package/dist/esm/ADSkyscraper.js +2 -2
- package/dist/esm/ADSponsoredResources.js +2 -2
- package/dist/esm/ADWebcast.js +2 -2
- package/dist/esm/ADWelcome.js +2 -2
- package/dist/esm/AdSlot.js +2 -2
- package/dist/esm/AdSlotsProvider.js +1 -1
- package/dist/esm/ArticleCarousel.js +1 -1
- package/dist/esm/ArticleSeriesListing.js +4 -4
- package/dist/esm/Auth.js +499 -248
- package/dist/esm/{BlockContent-e9b4ddcf.js → BlockContent-a614acdf.js} +1 -1
- package/dist/esm/CMEDeck.js +5 -5
- package/dist/esm/Column3.js +4 -4
- package/dist/esm/ConferenceArticleCard.js +2 -2
- package/dist/esm/DeckContent.js +7 -7
- package/dist/esm/DeckQueue.js +6 -6
- package/dist/esm/{Dfp-96b49def.js → Dfp-8a8fca18.js} +1 -1
- package/dist/esm/EventsDeck.js +5 -5
- package/dist/esm/ExternalResources.js +7 -7
- package/dist/esm/Feature.js +3 -3
- package/dist/esm/ForbesHero.js +2 -2
- package/dist/esm/GridContent.js +10 -10
- package/dist/esm/GridHero.js +2 -2
- package/dist/esm/GroupDeck.js +1 -1
- package/dist/esm/HamMagazine.js +4 -4
- package/dist/esm/Hero.js +1 -1
- package/dist/esm/HorizontalHero.js +2 -2
- package/dist/esm/IssueContentDeck.js +2 -2
- package/dist/esm/IssueDeck.js +2 -2
- package/dist/esm/IssueLanding.js +7 -7
- package/dist/esm/LeftNav.js +2 -2
- package/dist/esm/MasterDeck.js +8 -8
- package/dist/esm/NavMagazine.js +4 -4
- package/dist/esm/NavNative.js +3 -3
- package/dist/esm/OncliveHero.js +2 -2
- package/dist/esm/OncliveLargeHero.js +2 -2
- package/dist/esm/PartnerDetailListing.js +13 -1209
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/QueueDeckExpanded.js +9 -9
- package/dist/esm/RecentNews.js +2 -2
- package/dist/esm/RelatedContent.js +2 -2
- package/dist/esm/{SocialSearchComponent-55960ec4.js → SocialSearchComponent-75527dfe.js} +5 -5
- package/dist/esm/TaxonomyCard.js +2 -2
- package/dist/esm/TemplateNormal.js +3 -3
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/Ustream.js +2 -2
- package/dist/esm/VerticalHero.js +2 -2
- package/dist/esm/VideoSeriesCard.js +2 -2
- package/dist/esm/VideoSeriesListing.js +3 -3
- package/dist/esm/View.js +84 -242
- package/dist/esm/YahooHero.js +2 -2
- package/dist/esm/YoutubeGroup.js +1 -1
- package/dist/esm/getQuery.js +2 -2
- package/dist/esm/getRelatedArticle.js +5 -354
- package/dist/esm/getSerializers.js +6 -6
- package/dist/esm/{index-2141b8ab.js → index-1fa94c3a.js} +462 -450
- package/dist/esm/{index-73819142.js → index-51a80699.js} +20 -19
- package/dist/esm/{index-0e45a0b2.js → index-93ec3c59.js} +34 -27
- package/dist/esm/{index-ef6d5dcf.js → index-d2f90501.js} +1 -1
- package/dist/esm/{index.es-29c1cef5.js → index.es-938a3a58.js} +3 -1
- package/dist/esm/index.js +14 -13
- package/dist/esm/{main-5d1e4bd3.js → main-0465b2a0.js} +65 -34
- package/dist/esm/{moment-e2f9b20c.js → moment-12415288.js} +1 -1
- package/dist/esm/urlFor.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/index-bd6c9f56.js +0 -211
- package/dist/esm/index-db3bb315.js +0 -207
- /package/dist/cjs/{ADInfeed-388ec28a.js → ADInfeed-9735aff2.js} +0 -0
- /package/dist/cjs/{ADlgInfeed-5548ff47.js → ADlgInfeed-6bd11848.js} +0 -0
- /package/dist/esm/{ADInfeed-eae0af19.js → ADInfeed-9140aa7d.js} +0 -0
- /package/dist/esm/{ADlgInfeed-2f4c7a7c.js → ADlgInfeed-7656ecd1.js} +0 -0
package/dist/esm/View.js
CHANGED
|
@@ -14,19 +14,19 @@ import './web.dom.iterable-8956f9a5.js';
|
|
|
14
14
|
import { _ as _typeof } from './typeof-08f2c380.js';
|
|
15
15
|
import './_is-array-49698029.js';
|
|
16
16
|
import React__default, { useState, useRef, useEffect } from 'react';
|
|
17
|
-
import { l as lib_3 } from './index-
|
|
17
|
+
import { l as lib_3 } from './index-93ec3c59.js';
|
|
18
18
|
import 'prop-types';
|
|
19
19
|
import 'react-bootstrap/Row';
|
|
20
20
|
import 'react-bootstrap/Col';
|
|
21
|
-
import { m as moment } from './moment-
|
|
21
|
+
import { m as moment } from './moment-12415288.js';
|
|
22
22
|
import { useRouter } from 'next/router';
|
|
23
23
|
import './isSymbol-807e927e.js';
|
|
24
24
|
import './debounce-1a993acf.js';
|
|
25
|
-
import { I as InfiniteScroll } from './index.es-
|
|
25
|
+
import { I as InfiniteScroll } from './index.es-938a3a58.js';
|
|
26
26
|
import 'react-dom';
|
|
27
|
-
import './index-
|
|
27
|
+
import './index-51a80699.js';
|
|
28
28
|
import './index-5f9f807a.js';
|
|
29
|
-
import { m as
|
|
29
|
+
import { m as main_39 } from './main-0465b2a0.js';
|
|
30
30
|
import './entities-7cc3bf45.js';
|
|
31
31
|
import { _ as _JSON$stringify } from './stringify-008c8802.js';
|
|
32
32
|
import { a as _getIterator, _ as _slicedToArray } from './slicedToArray-7021e5df.js';
|
|
@@ -34,7 +34,7 @@ import { a as _asyncToGenerator, r as regenerator } from './asyncToGenerator-7c6
|
|
|
34
34
|
import './_set-species-cede29f8.js';
|
|
35
35
|
import './beam-681a9749.js';
|
|
36
36
|
import DFPAdSlot from './AdSlot.js';
|
|
37
|
-
import { B as BlockContent } from './BlockContent-
|
|
37
|
+
import { B as BlockContent } from './BlockContent-a614acdf.js';
|
|
38
38
|
import './smoothscroll-4b699764.js';
|
|
39
39
|
import './GroupDeck.js';
|
|
40
40
|
import 'react-bootstrap';
|
|
@@ -42,7 +42,7 @@ import './iconBase-602d52fe.js';
|
|
|
42
42
|
import Button from 'react-bootstrap/Button';
|
|
43
43
|
import { _ as _defineProperty } from './defineProperty-b798470d.js';
|
|
44
44
|
import Form from 'react-bootstrap/Form';
|
|
45
|
-
import { I as InscreenSensor, r as renderAuthor, g as getSerializers } from './index-
|
|
45
|
+
import { I as InscreenSensor, r as renderAuthor, g as getSerializers } from './index-1fa94c3a.js';
|
|
46
46
|
import './util-7700fc59.js';
|
|
47
47
|
import './brightcove-react-player-loader.es-83f53e4e.js';
|
|
48
48
|
import 'react-bootstrap/Pagination';
|
|
@@ -54,9 +54,9 @@ import { _ as _Object$keys } from './keys-fc2d4c34.js';
|
|
|
54
54
|
import 'react-bootstrap/Dropdown';
|
|
55
55
|
import { b as FaMinus, c as FaPlus } from './index.esm-cf08bf18.js';
|
|
56
56
|
import getSeriesDetail from './getSeriesDetail.js';
|
|
57
|
-
import '
|
|
58
|
-
import getRelatedArticle from './getRelatedArticle.js';
|
|
57
|
+
import 'nookies';
|
|
59
58
|
import getQuery from './getQuery.js';
|
|
59
|
+
import getRelatedArticle from './getRelatedArticle.js';
|
|
60
60
|
import { g as getTargeting, a as getContentPlacementUrl } from './getTargeting-2acdec91.js';
|
|
61
61
|
import getKeywords from './getKeywords.js';
|
|
62
62
|
import urlFor from './urlFor.js';
|
|
@@ -137,9 +137,9 @@ var DocumentGroup = function DocumentGroup(_ref) {
|
|
|
137
137
|
style: { display: 'flex', flexDirection: 'column', padding: '0 1rem', justifyContent: thumbnailUrl ? 'center' : 'flex-start', alignItems: 'center' } },
|
|
138
138
|
thumbnailUrl && React__default.createElement('img', { style: { maxWidth: '220px', maxHeight: '100px', marginTop: '1rem' }, src: thumbnailUrl, alt: name }),
|
|
139
139
|
!thumbnailUrl && React__default.createElement('p', {
|
|
140
|
-
style: { maxWidth: '315px', margin: '0', color: 'var(--primary)', textAlign: thumbnailUrl ? 'center' :
|
|
140
|
+
style: { maxWidth: '315px', margin: '0', color: 'var(--primary)', textAlign: thumbnailUrl ? 'center' : main_39 ? 'left' : 'right', marginTop: '.25rem' },
|
|
141
141
|
dangerouslySetInnerHTML: { __html: name } }),
|
|
142
|
-
|
|
142
|
+
main_39 && !thumbnailUrl && React__default.createElement(
|
|
143
143
|
'style',
|
|
144
144
|
{ jsx: 'true' },
|
|
145
145
|
'\n a.doc-group {\n display: block !important;\n padding: 0!important;\n }\n '
|
|
@@ -246,7 +246,7 @@ var ISI = function ISI(props) {
|
|
|
246
246
|
);
|
|
247
247
|
};
|
|
248
248
|
|
|
249
|
-
var css = ".RelatedArticles-module_mediaContainer__10h9k {\r\n display: flex;\r\n flex-direction: row;\r\n flex-wrap: nowrap;\r\n margin: 0 -1rem;\r\n}\r\n.RelatedArticles-module_mediaCard__3wQbn {\r\n margin: 0 1rem 1rem;\r\n width: calc(33% - 1rem);\r\n display: column;\r\n flex-direction: row;\r\n margin-bottom: 0.75rem;\r\n border-bottom: none;\r\n}\r\n.RelatedArticles-module_mediaCard__3wQbn:last-child {\r\n border-bottom: none;\r\n}\r\n.RelatedArticles-module_cardTitle__3P-Ib {\r\n font-weight: bold;\r\n color: #252525;\r\n margin-bottom: 0.25rem;\r\n font-size: 15px;\r\n}\r\n.RelatedArticles-module_authorListing__1EFg4 span.RelatedArticles-module_text-muted__3b0zX {\r\n color: #000;\r\n font-weight: bold;\r\n}\r\n.RelatedArticles-module_cardDate__1wOR5 {\r\n color: var(--dark);\r\n display: block;\r\n background: #fff !important;\r\n margin-bottom: 0;\r\n}\r\n.RelatedArticles-module_imgWrapper__5Jx_4 {\r\n display: block;\r\n text-align: center;\r\n margin-bottom: 0.5rem;\r\n}\r\n.RelatedArticles-module_imgWrapper__5Jx_4 img {\r\n height: 135px;\r\n width: 100%;\r\n object-fit: cover;\r\n object-position: center;\r\n}\r\n@media screen and (max-width: 1064px) {\r\n}\r\n@media screen and (max-width: 968px) {\r\n .RelatedArticles-module_mediaContainer__10h9k {\r\n flex-wrap: wrap;\r\n }\r\n .RelatedArticles-module_mediaCard__3wQbn {\r\n width: 100%;\r\n
|
|
249
|
+
var css = ".RelatedArticles-module_mediaContainer__10h9k {\r\n display: flex;\r\n flex-direction: row;\r\n flex-wrap: nowrap;\r\n margin: 0 -1rem;\r\n}\r\n.RelatedArticles-module_mediaCard__3wQbn {\r\n margin: 0 1rem 1rem;\r\n width: calc(33% - 1rem);\r\n display: column;\r\n flex-direction: row;\r\n margin-bottom: 0.75rem;\r\n padding-bottom: 0.75rem;\r\n border-bottom: none;\r\n}\r\n.RelatedArticles-module_mediaCard__3wQbn:last-child {\r\n border-bottom: none;\r\n}\r\n.RelatedArticles-module_cardTitle__3P-Ib {\r\n font-weight: bold;\r\n color: #252525;\r\n margin-bottom: 0.25rem;\r\n font-size: 15px;\r\n}\r\n.RelatedArticles-module_authorListing__1EFg4 span.RelatedArticles-module_text-muted__3b0zX {\r\n color: #000;\r\n font-weight: bold;\r\n}\r\n.RelatedArticles-module_cardDate__1wOR5 {\r\n color: var(--dark);\r\n display: block;\r\n background: #fff !important;\r\n margin-bottom: 0;\r\n}\r\n.RelatedArticles-module_imgWrapper__5Jx_4 {\r\n display: block;\r\n text-align: center;\r\n margin-bottom: 0.5rem;\r\n}\r\n.RelatedArticles-module_imgWrapper__5Jx_4 img {\r\n height: 135px;\r\n width: 100%;\r\n object-fit: cover;\r\n object-position: center;\r\n}\r\n@media screen and (max-width: 1064px) {\r\n}\r\n@media screen and (max-width: 968px) {\r\n .RelatedArticles-module_mediaContainer__10h9k {\r\n flex-wrap: wrap;\r\n }\r\n .RelatedArticles-module_mediaCard__3wQbn {\r\n width: 100%;\r\n }\r\n .RelatedArticles-module_imgWrapper__5Jx_4 img {\r\n width: 100%;\r\n height: auto;\r\n\r\n max-height: 175px;\r\n object-fit: contain;\r\n margin-bottom: 1rem;\r\n }\r\n}\r\n";
|
|
250
250
|
var styles = { "mediaContainer": "RelatedArticles-module_mediaContainer__10h9k", "mediaCard": "RelatedArticles-module_mediaCard__3wQbn", "cardTitle": "RelatedArticles-module_cardTitle__3P-Ib", "authorListing": "RelatedArticles-module_authorListing__1EFg4", "text-muted": "RelatedArticles-module_text-muted__3b0zX", "cardDate": "RelatedArticles-module_cardDate__1wOR5", "imgWrapper": "RelatedArticles-module_imgWrapper__5Jx_4" };
|
|
251
251
|
styleInject(css);
|
|
252
252
|
|
|
@@ -469,56 +469,10 @@ var Article = function Article(props) {
|
|
|
469
469
|
};
|
|
470
470
|
|
|
471
471
|
var RelevantTopics = function RelevantTopics() {
|
|
472
|
-
if (content_placement && content_placement.length > 0 || documentGroupMapping
|
|
473
|
-
var relatedLinks = [];
|
|
474
|
-
if (documentGroupMapping && documentGroupMapping.length > 0) {
|
|
475
|
-
documentGroupMapping.forEach(function (documentGroup) {
|
|
476
|
-
if (documentGroup.parent) {
|
|
477
|
-
relatedLinks = [].concat(_toConsumableArray(relatedLinks), [{ label: documentGroup.name, href: cpModificationRequired ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path }]);
|
|
478
|
-
}
|
|
479
|
-
});
|
|
480
|
-
}
|
|
481
|
-
if (content_placement && content_placement.length > 0) {
|
|
482
|
-
content_placement.filter(function (item) {
|
|
483
|
-
return item.path !== 'news';
|
|
484
|
-
}).forEach(function (cp) {
|
|
485
|
-
var cp_url = cpModificationRequired ? getContentPlacementUrl(cp) : cp.path;
|
|
486
|
-
var href = '/' + cp_url;
|
|
487
|
-
relatedLinks = [].concat(_toConsumableArray(relatedLinks), [{ label: cp.name, href: href }]);
|
|
488
|
-
});
|
|
489
|
-
}
|
|
490
|
-
if (relatedLinks && relatedLinks.length > 0) {
|
|
491
|
-
return React__default.createElement(
|
|
492
|
-
'div',
|
|
493
|
-
null,
|
|
494
|
-
relatedLinks.map(function (relatedLink, index) {
|
|
495
|
-
return React__default.createElement(
|
|
496
|
-
'span',
|
|
497
|
-
{ key: index, className: 'related-link' },
|
|
498
|
-
React__default.createElement(
|
|
499
|
-
'a',
|
|
500
|
-
{ className: 'related-links', style: { color: 'blue' }, href: relatedLink.href },
|
|
501
|
-
relatedLink.label
|
|
502
|
-
),
|
|
503
|
-
React__default.createElement(
|
|
504
|
-
'style',
|
|
505
|
-
{ jsx: 'true' },
|
|
506
|
-
'\n .related-link:not(:first-child):before {\n content: \' | \';\n }\n '
|
|
507
|
-
)
|
|
508
|
-
);
|
|
509
|
-
})
|
|
510
|
-
);
|
|
511
|
-
}
|
|
512
|
-
return null;
|
|
513
|
-
}
|
|
514
|
-
return null;
|
|
515
|
-
};
|
|
516
|
-
|
|
517
|
-
var renderRelatedSection = function renderRelatedSection() {
|
|
518
|
-
if (showRelatedArticles) {
|
|
472
|
+
if (content_placement && content_placement.length > 0 || documentGroupMapping) {
|
|
519
473
|
return React__default.createElement(
|
|
520
|
-
'
|
|
521
|
-
{
|
|
474
|
+
'div',
|
|
475
|
+
{ style: { color: '#262626' } },
|
|
522
476
|
React__default.createElement(
|
|
523
477
|
'p',
|
|
524
478
|
{ className: 'mb-0' },
|
|
@@ -528,21 +482,47 @@ var Article = function Article(props) {
|
|
|
528
482
|
'Related Content:'
|
|
529
483
|
)
|
|
530
484
|
),
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
485
|
+
documentGroupMapping && documentGroupMapping.map(function (documentGroup) {
|
|
486
|
+
if (!documentGroup.parent) {
|
|
487
|
+
return null;
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
return React__default.createElement(
|
|
491
|
+
React__default.Fragment,
|
|
492
|
+
null,
|
|
493
|
+
React__default.createElement(
|
|
494
|
+
'span',
|
|
495
|
+
{ className: '' },
|
|
496
|
+
React__default.createElement(
|
|
497
|
+
'a',
|
|
498
|
+
{
|
|
499
|
+
className: 'related-links',
|
|
500
|
+
style: { color: 'blue' },
|
|
501
|
+
href: cpModificationRequired ? '/' + documentGroup.parent.identifier.current + '/' + documentGroup.path : '/' + documentGroup.path },
|
|
502
|
+
documentGroup.name
|
|
503
|
+
)
|
|
504
|
+
),
|
|
505
|
+
content_placement && content_placement.length ? ' | ' : null
|
|
506
|
+
);
|
|
507
|
+
}),
|
|
508
|
+
content_placement && content_placement.length > 0 ? content_placement.map(function (cp, index) {
|
|
509
|
+
var cp_url = cpModificationRequired ? getContentPlacementUrl(cp) : cp.path;
|
|
510
|
+
var href = '/' + cp_url;
|
|
511
|
+
return React__default.createElement(
|
|
512
|
+
React__default.Fragment,
|
|
513
|
+
{ key: index },
|
|
514
|
+
React__default.createElement(
|
|
515
|
+
'span',
|
|
516
|
+
null,
|
|
517
|
+
React__default.createElement(
|
|
518
|
+
'a',
|
|
519
|
+
{ className: 'related-links', key: index, href: href, style: { color: 'blue' } },
|
|
520
|
+
cp.name
|
|
521
|
+
)
|
|
522
|
+
),
|
|
523
|
+
content_placement.length > index + 1 ? ' | ' : null
|
|
524
|
+
);
|
|
525
|
+
}) : null
|
|
546
526
|
);
|
|
547
527
|
}
|
|
548
528
|
return null;
|
|
@@ -651,7 +631,6 @@ var Article = function Article(props) {
|
|
|
651
631
|
{ id: 'contextual-video-ad-' + payload._id, className: 'contextual-video-ad' },
|
|
652
632
|
React__default.createElement(DFPAdSlot, _extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: checkIsVideoAdFound }))
|
|
653
633
|
),
|
|
654
|
-
renderRelatedSection(),
|
|
655
634
|
React__default.createElement(BlockContent, _extends({
|
|
656
635
|
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
|
|
657
636
|
blocks: [].concat(_toConsumableArray(articleBody.slice(selectedIndex))),
|
|
@@ -719,7 +698,6 @@ var Article = function Article(props) {
|
|
|
719
698
|
React__default.createElement(DFPAdSlot, _extends({}, payload.contextualAD, { refreshFlag: false, checkIsAdFound: _checkIsAdFound }))
|
|
720
699
|
),
|
|
721
700
|
contextualADFlag && React__default.createElement('span', { className: 'clearfix' }),
|
|
722
|
-
renderRelatedSection(),
|
|
723
701
|
React__default.createElement(BlockContent, _extends({
|
|
724
702
|
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
|
|
725
703
|
blocks: [].concat(_toConsumableArray(articleBody.slice(_selectedIndex))),
|
|
@@ -762,31 +740,12 @@ var Article = function Article(props) {
|
|
|
762
740
|
{ id: 'contextual-video-ad-' + payload._id, className: 'contextual-video-ad' },
|
|
763
741
|
React__default.createElement(DFPAdSlot, _extends({}, payload.contextualVideoAD, { refreshFlag: false, checkIsAdFound: _checkIsAdFound2 }))
|
|
764
742
|
),
|
|
765
|
-
renderRelatedSection(),
|
|
766
743
|
React__default.createElement(BlockContent, _extends({
|
|
767
744
|
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
|
|
768
745
|
blocks: [].concat(_toConsumableArray(articleBody.slice(_selectedIndex2))),
|
|
769
746
|
imageOptions: { w: 320, h: 240, fit: 'max' }
|
|
770
747
|
}, client.config()))
|
|
771
748
|
);
|
|
772
|
-
} else if (indexes.length >= 2 && body.length > 3 && showRelatedArticles) {
|
|
773
|
-
var _selectedIndex3 = indexes[1] + 1;
|
|
774
|
-
return React__default.createElement(
|
|
775
|
-
React__default.Fragment,
|
|
776
|
-
null,
|
|
777
|
-
React__default.createElement(BlockContent, _extends({
|
|
778
|
-
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, contextualADFlag, null, null, targeting),
|
|
779
|
-
blocks: [].concat(_toConsumableArray(articleBody.slice(0, _selectedIndex3))),
|
|
780
|
-
imageOptions: { w: 320, h: 240, fit: 'max' }
|
|
781
|
-
}, client.config())),
|
|
782
|
-
React__default.createElement('span', { className: 'clearfix' }),
|
|
783
|
-
renderRelatedSection(),
|
|
784
|
-
React__default.createElement(BlockContent, _extends({
|
|
785
|
-
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, null, null, null, targeting),
|
|
786
|
-
blocks: [].concat(_toConsumableArray(articleBody.slice(_selectedIndex3))),
|
|
787
|
-
imageOptions: { w: 320, h: 240, fit: 'max' }
|
|
788
|
-
}, client.config()))
|
|
789
|
-
);
|
|
790
749
|
} else {
|
|
791
750
|
return React__default.createElement(BlockContent, _extends({
|
|
792
751
|
serializers: getSerializers(client, pageview, videoAccountIDs, onVote, true, drupalLeadSettings, currentPage, false, false, null, props.article.Ads, targeting),
|
|
@@ -974,7 +933,7 @@ var Article = function Article(props) {
|
|
|
974
933
|
React__default.createElement(
|
|
975
934
|
'div',
|
|
976
935
|
{ className: 'ad-box', style: { textAlign: 'center' } },
|
|
977
|
-
|
|
936
|
+
main_39 && !sponsoredFlag && props.article.Ads && props.article.Ads.length > 0 && props.article.Ads.map(function (ad, index) {
|
|
978
937
|
if (index === 0) {
|
|
979
938
|
return React__default.createElement(
|
|
980
939
|
'div',
|
|
@@ -1026,7 +985,21 @@ var Article = function Article(props) {
|
|
|
1026
985
|
issue.name
|
|
1027
986
|
)
|
|
1028
987
|
),
|
|
1029
|
-
React__default.createElement('div', { className: 'clearfix', style: { minHeight: '1px' } })
|
|
988
|
+
React__default.createElement('div', { className: 'clearfix', style: { minHeight: '1px' } }),
|
|
989
|
+
showRelatedArticles && !showIsi && React__default.createElement(
|
|
990
|
+
React__default.Fragment,
|
|
991
|
+
null,
|
|
992
|
+
React__default.createElement(
|
|
993
|
+
'div',
|
|
994
|
+
null,
|
|
995
|
+
React__default.createElement(RelevantTopics, null)
|
|
996
|
+
),
|
|
997
|
+
React__default.createElement(
|
|
998
|
+
'div',
|
|
999
|
+
{ className: 'pt-2' },
|
|
1000
|
+
React__default.createElement(RelatedArticle, { articles: article.relatedArticle, client: client })
|
|
1001
|
+
)
|
|
1002
|
+
)
|
|
1030
1003
|
),
|
|
1031
1004
|
renderIsiContent(props.article)
|
|
1032
1005
|
),
|
|
@@ -1039,7 +1012,7 @@ var Article = function Article(props) {
|
|
|
1039
1012
|
})
|
|
1040
1013
|
)
|
|
1041
1014
|
),
|
|
1042
|
-
|
|
1015
|
+
main_39 && !sponsoredFlag && props.article.Ads && props.article.Ads.length > 0 && props.article.Ads.map(function (ad, index) {
|
|
1043
1016
|
if (index > 0) {
|
|
1044
1017
|
return React__default.createElement(
|
|
1045
1018
|
'div',
|
|
@@ -1079,127 +1052,6 @@ var Article = function Article(props) {
|
|
|
1079
1052
|
|
|
1080
1053
|
var _this = undefined;
|
|
1081
1054
|
|
|
1082
|
-
var getRelatedContents = function () {
|
|
1083
|
-
var _ref = _asyncToGenerator( /*#__PURE__*/regenerator.mark(function _callee() {
|
|
1084
|
-
var client = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
1085
|
-
var article = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
1086
|
-
var prevUrl = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : '/';
|
|
1087
|
-
var articleCount = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 0;
|
|
1088
|
-
|
|
1089
|
-
var _article$url, url, content_placement, documentGroupMapping, issueGroup, params, conditions, taxonomy, documentGroup, relatedContents, relatedContentQuery;
|
|
1090
|
-
|
|
1091
|
-
return regenerator.wrap(function _callee$(_context) {
|
|
1092
|
-
while (1) {
|
|
1093
|
-
switch (_context.prev = _context.next) {
|
|
1094
|
-
case 0:
|
|
1095
|
-
_article$url = article.url;
|
|
1096
|
-
_article$url = _article$url === undefined ? {
|
|
1097
|
-
current: null
|
|
1098
|
-
} : _article$url;
|
|
1099
|
-
url = _article$url.current, content_placement = article.content_placement, documentGroupMapping = article.documentGroupMapping, issueGroup = article.issueGroup;
|
|
1100
|
-
params = { url: url };
|
|
1101
|
-
conditions = '';
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
if (content_placement && content_placement.length > 0) {
|
|
1105
|
-
taxonomy = [];
|
|
1106
|
-
|
|
1107
|
-
content_placement.forEach(function (_ref2) {
|
|
1108
|
-
var path = _ref2.path,
|
|
1109
|
-
_id = _ref2._id;
|
|
1110
|
-
|
|
1111
|
-
if (!_id || typeof _id == 'undefined') {
|
|
1112
|
-
return null;
|
|
1113
|
-
}
|
|
1114
|
-
var prev_url_to_check = prevUrl;
|
|
1115
|
-
if (prev_url_to_check.includes('?')) {
|
|
1116
|
-
prev_url_to_check = prev_url_to_check.split('?')[0];
|
|
1117
|
-
}
|
|
1118
|
-
if (prev_url_to_check.endsWith(path) && _id) taxonomy.push(_id);
|
|
1119
|
-
});
|
|
1120
|
-
if (taxonomy.length === 0) {
|
|
1121
|
-
content_placement.filter(function (_ref3) {
|
|
1122
|
-
var identifier = _ref3.identifier;
|
|
1123
|
-
return identifier !== 'news';
|
|
1124
|
-
}).forEach(function (_ref4) {
|
|
1125
|
-
var _id = _ref4._id;
|
|
1126
|
-
|
|
1127
|
-
if (_id) taxonomy.push(_id);
|
|
1128
|
-
});
|
|
1129
|
-
}
|
|
1130
|
-
if (taxonomy.length > 0) {
|
|
1131
|
-
params = _extends({}, params, { taxonomy: taxonomy });
|
|
1132
|
-
conditions = '&& taxonomyMapping[]._ref in $taxonomy';
|
|
1133
|
-
}
|
|
1134
|
-
}
|
|
1135
|
-
|
|
1136
|
-
if (documentGroupMapping && documentGroupMapping.length > 0) {
|
|
1137
|
-
documentGroup = [];
|
|
1138
|
-
|
|
1139
|
-
documentGroupMapping.forEach(function (_ref5) {
|
|
1140
|
-
var _id = _ref5._id;
|
|
1141
|
-
|
|
1142
|
-
if (_id) documentGroup.push(_id);
|
|
1143
|
-
});
|
|
1144
|
-
if (params.taxonomy && documentGroup.length > 0) {
|
|
1145
|
-
params = _extends({}, params, { documentGroup: documentGroup });
|
|
1146
|
-
conditions = '&& (taxonomyMapping[]._ref in $taxonomy || documentGroupMapping[]._ref in $documentGroup)';
|
|
1147
|
-
}
|
|
1148
|
-
}
|
|
1149
|
-
|
|
1150
|
-
if (issueGroup && issueGroup._ref) {
|
|
1151
|
-
if (params.taxonomy && params.documentGroup) {
|
|
1152
|
-
params = _extends({}, params, { issueAssociation: issueGroup._ref });
|
|
1153
|
-
conditions = '&& (taxonomyMapping[]._ref in $taxonomy || documentGroupMapping[]._ref in $documentGroup || issueGroup._ref == $issueAssociation )';
|
|
1154
|
-
} else if (params.taxonomy) {
|
|
1155
|
-
params = _extends({}, params, { issueAssociation: issueGroup._ref });
|
|
1156
|
-
conditions = '&& (taxonomyMapping[]._ref in $taxonomy || issueGroup._ref == $issueAssociation )';
|
|
1157
|
-
}
|
|
1158
|
-
}
|
|
1159
|
-
|
|
1160
|
-
relatedContents = [];
|
|
1161
|
-
|
|
1162
|
-
if (!(params.taxonomy && params.taxonomy.length > 0)) {
|
|
1163
|
-
_context.next = 21;
|
|
1164
|
-
break;
|
|
1165
|
-
}
|
|
1166
|
-
|
|
1167
|
-
relatedContentQuery = '*[\n _type == "article"\n && defined(title)\n && defined(url)\n && !(_id in path("drafts.**"))\n && is_visible == true\n && passwordLock != true\n && taxonomyMapping[].disableAds != \'true\'\n && contentCategory.name != \'Poll\'\n && contentCategory.name != \'Slideshows\'\n \t&& contentCategory.disableAds != \'true\'\n && ExcludeFromInfiniteScroll != true\n && url.current != $url\n && !defined(body[].videos)\n && published <= \'' + new Date().toISOString() + '\'\n ' + conditions + '\n ]| order(published desc)[' + articleCount + ']\n {\n title,\n url,\n thumbnail\n }';
|
|
1168
|
-
_context.prev = 11;
|
|
1169
|
-
_context.next = 14;
|
|
1170
|
-
return client.fetch(relatedContentQuery, params);
|
|
1171
|
-
|
|
1172
|
-
case 14:
|
|
1173
|
-
relatedContents = _context.sent;
|
|
1174
|
-
|
|
1175
|
-
debugger;
|
|
1176
|
-
_context.next = 21;
|
|
1177
|
-
break;
|
|
1178
|
-
|
|
1179
|
-
case 18:
|
|
1180
|
-
_context.prev = 18;
|
|
1181
|
-
_context.t0 = _context['catch'](11);
|
|
1182
|
-
|
|
1183
|
-
console.error(_context.t0);
|
|
1184
|
-
|
|
1185
|
-
case 21:
|
|
1186
|
-
return _context.abrupt('return', relatedContents);
|
|
1187
|
-
|
|
1188
|
-
case 22:
|
|
1189
|
-
case 'end':
|
|
1190
|
-
return _context.stop();
|
|
1191
|
-
}
|
|
1192
|
-
}
|
|
1193
|
-
}, _callee, _this, [[11, 18]]);
|
|
1194
|
-
}));
|
|
1195
|
-
|
|
1196
|
-
return function getRelatedContents() {
|
|
1197
|
-
return _ref.apply(this, arguments);
|
|
1198
|
-
};
|
|
1199
|
-
}();
|
|
1200
|
-
|
|
1201
|
-
var _this$1 = undefined;
|
|
1202
|
-
|
|
1203
1055
|
var ArticleQueue = function ArticleQueue(props) {
|
|
1204
1056
|
var _props$prevUrl = props.prevUrl,
|
|
1205
1057
|
prevUrl = _props$prevUrl === undefined ? '/' : _props$prevUrl,
|
|
@@ -1233,7 +1085,7 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
1233
1085
|
});
|
|
1234
1086
|
var targeting = getTargeting({ article: activeArticle, cpModificationRequired: cpModificationRequired, position: props.position, prevUrl: prevUrl });
|
|
1235
1087
|
|
|
1236
|
-
if (!
|
|
1088
|
+
if (!main_39) {
|
|
1237
1089
|
lib_3.getGoogletag().then(function (googletag) {
|
|
1238
1090
|
if (window.googletag && googletag.pubadsReady) {
|
|
1239
1091
|
var slots = googletag.pubads().getSlots();
|
|
@@ -1251,7 +1103,7 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
1251
1103
|
});
|
|
1252
1104
|
}
|
|
1253
1105
|
//Refresh leaderboard ad on mobile
|
|
1254
|
-
if (
|
|
1106
|
+
if (main_39) {
|
|
1255
1107
|
var leaderboardSlotId = '';
|
|
1256
1108
|
lib_3.getGoogletag().then(function (googletag) {
|
|
1257
1109
|
if (window.googletag && googletag.pubadsReady) {
|
|
@@ -1325,7 +1177,7 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
1325
1177
|
switch (_context.prev = _context.next) {
|
|
1326
1178
|
case 0:
|
|
1327
1179
|
if (!(article && article._id)) {
|
|
1328
|
-
_context.next =
|
|
1180
|
+
_context.next = 9;
|
|
1329
1181
|
break;
|
|
1330
1182
|
}
|
|
1331
1183
|
|
|
@@ -1337,22 +1189,17 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
1337
1189
|
|
|
1338
1190
|
case 5:
|
|
1339
1191
|
article.relatedArticle = _context.sent;
|
|
1340
|
-
_context.next = 8;
|
|
1341
|
-
return getRelatedContents(null, props.client, article, prevUrl, startingIndex + '..' + endingIndex);
|
|
1342
|
-
|
|
1343
|
-
case 8:
|
|
1344
|
-
article.relatedContents = _context.sent;
|
|
1345
1192
|
targeting = getTargeting({ article: article, cpModificationRequired: cpModificationRequired, prevUrl: prevUrl });
|
|
1346
1193
|
|
|
1347
1194
|
article.Ads = Ads.getRightItems(targeting);
|
|
1348
1195
|
setQueueData([].concat(_toConsumableArray(queueData), [article]));
|
|
1349
1196
|
|
|
1350
|
-
case
|
|
1197
|
+
case 9:
|
|
1351
1198
|
case 'end':
|
|
1352
1199
|
return _context.stop();
|
|
1353
1200
|
}
|
|
1354
1201
|
}
|
|
1355
|
-
}, _callee, _this
|
|
1202
|
+
}, _callee, _this);
|
|
1356
1203
|
}));
|
|
1357
1204
|
|
|
1358
1205
|
return function (_x) {
|
|
@@ -1500,7 +1347,7 @@ var Articles = function Articles(props) {
|
|
|
1500
1347
|
}, _defineProperty(_extends2, 'pageview', pageview), _defineProperty(_extends2, 'onVote', function onVote() {}), _defineProperty(_extends2, 'ISIContent', ISIContent), _defineProperty(_extends2, 'videoAccountIDs', videoAccountIDs), _defineProperty(_extends2, 'sponsoredTaxonomies', []), _defineProperty(_extends2, 'cpModificationRequired', cpModificationRequired), _defineProperty(_extends2, 'Settings', Settings), _defineProperty(_extends2, 'canonicalTag', canonicalTag), _extends2), props));
|
|
1501
1348
|
};
|
|
1502
1349
|
|
|
1503
|
-
var _this$
|
|
1350
|
+
var _this$1 = undefined;
|
|
1504
1351
|
|
|
1505
1352
|
var View = function View(props) {
|
|
1506
1353
|
var router = useRouter();
|
|
@@ -1708,12 +1555,12 @@ View.returnGetInitialProps = function () {
|
|
|
1708
1555
|
}
|
|
1709
1556
|
|
|
1710
1557
|
article.relatedArticle = null;
|
|
1711
|
-
_context.next =
|
|
1558
|
+
_context.next = 18;
|
|
1712
1559
|
break;
|
|
1713
1560
|
|
|
1714
1561
|
case 14:
|
|
1715
1562
|
if (!article) {
|
|
1716
|
-
_context.next =
|
|
1563
|
+
_context.next = 18;
|
|
1717
1564
|
break;
|
|
1718
1565
|
}
|
|
1719
1566
|
|
|
@@ -1722,13 +1569,8 @@ View.returnGetInitialProps = function () {
|
|
|
1722
1569
|
|
|
1723
1570
|
case 17:
|
|
1724
1571
|
article.relatedArticle = _context.sent;
|
|
1725
|
-
_context.next = 20;
|
|
1726
|
-
return getRelatedContents(context, client, article, prevUrl, '0..2');
|
|
1727
1572
|
|
|
1728
|
-
case
|
|
1729
|
-
article.relatedContents = _context.sent;
|
|
1730
|
-
|
|
1731
|
-
case 21:
|
|
1573
|
+
case 18:
|
|
1732
1574
|
return _context.abrupt('return', {
|
|
1733
1575
|
url: url,
|
|
1734
1576
|
sao: sao,
|
|
@@ -1739,12 +1581,12 @@ View.returnGetInitialProps = function () {
|
|
|
1739
1581
|
sponsoredFlag: sponsoredFlag
|
|
1740
1582
|
});
|
|
1741
1583
|
|
|
1742
|
-
case
|
|
1584
|
+
case 19:
|
|
1743
1585
|
case 'end':
|
|
1744
1586
|
return _context.stop();
|
|
1745
1587
|
}
|
|
1746
1588
|
}
|
|
1747
|
-
}, _callee, _this$
|
|
1589
|
+
}, _callee, _this$1);
|
|
1748
1590
|
}));
|
|
1749
1591
|
|
|
1750
1592
|
return function (_x, _x2, _x3, _x4, _x5) {
|
package/dist/esm/YahooHero.js
CHANGED
|
@@ -5,9 +5,9 @@ import './core.get-iterator-method-54d2e411.js';
|
|
|
5
5
|
import './web.dom.iterable-8956f9a5.js';
|
|
6
6
|
import React__default from 'react';
|
|
7
7
|
import 'prop-types';
|
|
8
|
-
import { m as moment } from './moment-
|
|
8
|
+
import { m as moment } from './moment-12415288.js';
|
|
9
9
|
import 'react-dom';
|
|
10
|
-
import { i as imageUrlBuilder } from './index-
|
|
10
|
+
import { i as imageUrlBuilder } from './index-51a80699.js';
|
|
11
11
|
import { L as LazyLoad } from './index-5f9f807a.js';
|
|
12
12
|
import { c as clean_html_1 } from './entities-7cc3bf45.js';
|
|
13
13
|
import './slicedToArray-7021e5df.js';
|
package/dist/esm/YoutubeGroup.js
CHANGED
|
@@ -10,7 +10,7 @@ import './_is-array-49698029.js';
|
|
|
10
10
|
import React__default, { useRef, useState, useEffect } from 'react';
|
|
11
11
|
import 'prop-types';
|
|
12
12
|
import 'react-dom';
|
|
13
|
-
import { i as imageUrlBuilder } from './index-
|
|
13
|
+
import { i as imageUrlBuilder } from './index-51a80699.js';
|
|
14
14
|
import { L as LazyLoad } from './index-5f9f807a.js';
|
|
15
15
|
import { _ as _slicedToArray } from './slicedToArray-7021e5df.js';
|
|
16
16
|
import { s as smoothscroll, g as getYoutubeId } from './smoothscroll-4b699764.js';
|
package/dist/esm/getQuery.js
CHANGED
|
@@ -8,9 +8,9 @@ var getQuery = function getQuery(type) {
|
|
|
8
8
|
|
|
9
9
|
switch (type) {
|
|
10
10
|
case 'related':
|
|
11
|
-
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
|
|
11
|
+
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 }';
|
|
12
12
|
case 'article':
|
|
13
|
-
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
|
|
13
|
+
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 }';
|
|
14
14
|
case 'publication':
|
|
15
15
|
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 }';
|
|
16
16
|
case 'issue':
|