@mjhls/mjh-framework 1.0.454 → 1.0.456
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 +1 -1
- package/dist/cjs/ArticleQueue.js +1 -1
- package/dist/cjs/IssueContentDeck.js +33 -12
- package/dist/cjs/PublicationLanding.js +4 -4
- package/dist/cjs/QueueDeckExpanded.js +19 -4
- package/dist/cjs/View.js +1 -1
- package/dist/cjs/{getTargeting-ec7dd217.js → getTargeting-37612527.js} +9 -22
- package/dist/cjs/getTargeting.js +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/esm/ArticleQueue.js +1 -1
- package/dist/esm/IssueContentDeck.js +33 -12
- package/dist/esm/PublicationLanding.js +4 -4
- package/dist/esm/QueueDeckExpanded.js +19 -4
- package/dist/esm/View.js +1 -1
- package/dist/esm/{getTargeting-02118961.js → getTargeting-8f4bd5db.js} +9 -22
- package/dist/esm/getTargeting.js +1 -1
- package/dist/esm/index.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
package/dist/cjs/ArticleQueue.js
CHANGED
|
@@ -619,7 +619,7 @@ var Article = function Article(props) {
|
|
|
619
619
|
React__default.createElement(
|
|
620
620
|
'style',
|
|
621
621
|
{ jsx: 'true' },
|
|
622
|
-
'\n
|
|
622
|
+
'\n .sanityDisplayLabel {\n margin: .5rem 0;\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
623
623
|
)
|
|
624
624
|
);
|
|
625
625
|
};
|
|
@@ -54,7 +54,8 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
54
54
|
imageWidth = props.imageWidth,
|
|
55
55
|
client = props.client,
|
|
56
56
|
Settings = props.Settings,
|
|
57
|
-
index = props.index
|
|
57
|
+
index = props.index,
|
|
58
|
+
source = props.source;
|
|
58
59
|
|
|
59
60
|
return React__default.createElement(
|
|
60
61
|
Col,
|
|
@@ -64,19 +65,28 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
64
65
|
{ style: { boxShadow: 'none', borderBottom: '1px solid #aaa', paddingBottom: '1rem' } },
|
|
65
66
|
React__default.createElement(
|
|
66
67
|
'div',
|
|
67
|
-
{ style: { display: 'flex', flex: '1 0 auto' } },
|
|
68
|
+
{ style: { display: 'flex', flex: '1 0 auto', paddingBottom: '1rem' } },
|
|
68
69
|
coverImage && React__default.createElement(
|
|
69
|
-
'
|
|
70
|
-
{
|
|
70
|
+
'div',
|
|
71
|
+
{ style: { display: 'flex', flexDirection: 'column', justifyContent: 'center' } },
|
|
71
72
|
React__default.createElement(
|
|
72
|
-
|
|
73
|
-
{
|
|
74
|
-
React__default.createElement(
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
73
|
+
'a',
|
|
74
|
+
{ href: '/view/' + link },
|
|
75
|
+
React__default.createElement(
|
|
76
|
+
index$2.LazyLoad,
|
|
77
|
+
{ height: imageHeight },
|
|
78
|
+
React__default.createElement(Card.Img, {
|
|
79
|
+
variant: 'right',
|
|
80
|
+
src: renderCardImage({ coverImage: coverImage, imageHeight: imageHeight, imageWidth: imageWidth, client: client, Settings: Settings }),
|
|
81
|
+
alt: title,
|
|
82
|
+
style: { width: '170px', height: 'auto', objectFit: 'contain', padding: '0.25rem', float: 'left' }
|
|
83
|
+
})
|
|
84
|
+
)
|
|
85
|
+
),
|
|
86
|
+
source && React__default.createElement(
|
|
87
|
+
'div',
|
|
88
|
+
{ className: 'mb-2 sanityDisplayLabel displayLabelThumb' },
|
|
89
|
+
source
|
|
80
90
|
)
|
|
81
91
|
),
|
|
82
92
|
React__default.createElement(
|
|
@@ -104,6 +114,11 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
104
114
|
React__default.createElement(
|
|
105
115
|
'div',
|
|
106
116
|
{ style: { float: 'left' } },
|
|
117
|
+
source && !coverImage && React__default.createElement(
|
|
118
|
+
'div',
|
|
119
|
+
{ className: 'mb-2 sanityDisplayLabel' },
|
|
120
|
+
source
|
|
121
|
+
),
|
|
107
122
|
React__default.createElement(
|
|
108
123
|
'p',
|
|
109
124
|
{ style: { color: '#484848', fontSize: '.9rem', fontWeight: '600' }, className: 'mb-0' },
|
|
@@ -194,6 +209,7 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
194
209
|
imageHeight: imageHeight,
|
|
195
210
|
imageWidth: imageWidth,
|
|
196
211
|
client: client,
|
|
212
|
+
source: row.source,
|
|
197
213
|
published: row.published,
|
|
198
214
|
author: row.authorMapping && row.authorMapping.length > 0 ? row.authorMapping : [],
|
|
199
215
|
summary: row.summary
|
|
@@ -222,6 +238,11 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
222
238
|
'New content coming soon, please check back later.'
|
|
223
239
|
)
|
|
224
240
|
)
|
|
241
|
+
),
|
|
242
|
+
React__default.createElement(
|
|
243
|
+
'style',
|
|
244
|
+
{ jsx: 'true' },
|
|
245
|
+
'\n .displayLabelThumb {\n margin: 0 auto;\n margin-top: -1.25rem;\n background-color: white;\n position: relative;\n }\n .sanityDisplayLabel {\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
225
246
|
)
|
|
226
247
|
);
|
|
227
248
|
};
|
|
@@ -500,10 +500,10 @@ var PublicationLanding = function PublicationLanding(props) {
|
|
|
500
500
|
null,
|
|
501
501
|
issue.name
|
|
502
502
|
),
|
|
503
|
-
issue.
|
|
503
|
+
issue.source && React__default.createElement(
|
|
504
504
|
'p',
|
|
505
|
-
{ className: '
|
|
506
|
-
issue.
|
|
505
|
+
{ className: 'sanityDisplayLabel' },
|
|
506
|
+
issue.source
|
|
507
507
|
),
|
|
508
508
|
issue.volume && issue.number && React__default.createElement(
|
|
509
509
|
'p',
|
|
@@ -544,7 +544,7 @@ var PublicationLanding = function PublicationLanding(props) {
|
|
|
544
544
|
React__default.createElement(
|
|
545
545
|
'style',
|
|
546
546
|
{ jsx: 'true' },
|
|
547
|
-
'\n .issueCard.card:hover {\n cursor: default;\n }\n '
|
|
547
|
+
'\n .issueCard.card:hover {\n cursor: default;\n }\n .sanityDisplayLabel {\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
548
548
|
)
|
|
549
549
|
);
|
|
550
550
|
};
|
|
@@ -257,6 +257,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
257
257
|
index$2.LazyLoad,
|
|
258
258
|
{ height: imageHeight },
|
|
259
259
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
260
|
+
),
|
|
261
|
+
article.source && React__default.createElement(
|
|
262
|
+
'div',
|
|
263
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
264
|
+
article.source
|
|
260
265
|
)
|
|
261
266
|
),
|
|
262
267
|
React__default.createElement(
|
|
@@ -281,7 +286,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
281
286
|
{ height: 50 },
|
|
282
287
|
React__default.createElement(AuthorComponent.AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
283
288
|
),
|
|
284
|
-
article.source && React__default.createElement(
|
|
289
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
285
290
|
'div',
|
|
286
291
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
287
292
|
article.source
|
|
@@ -353,6 +358,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
353
358
|
index$2.LazyLoad,
|
|
354
359
|
{ height: imageHeight },
|
|
355
360
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
361
|
+
),
|
|
362
|
+
article.source && React__default.createElement(
|
|
363
|
+
'div',
|
|
364
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
365
|
+
article.source
|
|
356
366
|
)
|
|
357
367
|
),
|
|
358
368
|
React__default.createElement(
|
|
@@ -377,7 +387,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
377
387
|
{ height: 50 },
|
|
378
388
|
React__default.createElement(AuthorComponent.AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
379
389
|
),
|
|
380
|
-
article.source && React__default.createElement(
|
|
390
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
381
391
|
'div',
|
|
382
392
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
383
393
|
article.source
|
|
@@ -457,6 +467,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
457
467
|
index$2.LazyLoad,
|
|
458
468
|
{ height: imageHeight },
|
|
459
469
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'mr-3 img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
470
|
+
),
|
|
471
|
+
article.source && React__default.createElement(
|
|
472
|
+
'div',
|
|
473
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
474
|
+
article.source
|
|
460
475
|
)
|
|
461
476
|
),
|
|
462
477
|
React__default.createElement(
|
|
@@ -485,7 +500,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
485
500
|
React__default.createElement(AuthorComponent.AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
486
501
|
)
|
|
487
502
|
),
|
|
488
|
-
article.source && React__default.createElement(
|
|
503
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
489
504
|
'div',
|
|
490
505
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
491
506
|
article.source
|
|
@@ -549,7 +564,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
549
564
|
React__default.createElement(
|
|
550
565
|
'style',
|
|
551
566
|
{ jsx: 'true' },
|
|
552
|
-
'\n .sanityDisplayLabel {\n margin: 0.5rem 0;\n border: 1px solid black;\n width: fit-content;\n padding: 5px;\n }\n .feature-media > .media-body {\n -webkit-box-flex: none;\n -ms-flex: none;\n flex: none;\n }\n .img-wrapper img {\n max-height: 240px;\n height: auto;\n width: 100%;\n object-fit: contain;\n }\n .feature-wrapper {\n height: 100%;\n width: 100%;\n }\n .feature-wrapper img {\n width: 100%;\n margin-bottom: 1em;\n }\n @media only screen and (min-width: 768px) {\n .img-wrapper > img {\n padding-right: 1em;\n }\n }\n @media only screen and (max-width: 767px) {\n .img-wrapper {\n width: 100%;\n }\n .img-wrapper img {\n padding-bottom: 1em;\n }\n .media {\n flex-direction: column !important;\n }\n }\n '
|
|
567
|
+
'\n .displayLabelThumb{\n margin: 0 auto;\n margin-top: -1.25rem;\n background-color: white;\n position: relative;\n }\n .sanityDisplayLabel {\n margin: 0.5rem 0;\n border: 1px solid black;\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n .feature-media > .media-body {\n -webkit-box-flex: none;\n -ms-flex: none;\n flex: none;\n }\n .img-wrapper img {\n max-height: 240px;\n height: auto;\n width: 100%;\n object-fit: contain;\n }\n .feature-wrapper {\n height: 100%;\n width: 100%;\n }\n .feature-wrapper img {\n width: 100%;\n margin-bottom: 1em;\n }\n @media only screen and (min-width: 768px) {\n .img-wrapper > img {\n padding-right: 1em;\n }\n }\n @media only screen and (max-width: 767px) {\n .img-wrapper {\n width: 100%;\n }\n .img-wrapper img {\n padding-bottom: 1em;\n }\n .media {\n flex-direction: column !important;\n }\n }\n '
|
|
553
568
|
)
|
|
554
569
|
);
|
|
555
570
|
};
|
package/dist/cjs/View.js
CHANGED
|
@@ -57,7 +57,7 @@ var getSerializers = require('./getSerializers.js');
|
|
|
57
57
|
require('./util-f2c1b65b.js');
|
|
58
58
|
require('react-bootstrap/Pagination');
|
|
59
59
|
require('next/dynamic');
|
|
60
|
-
var getTargeting = require('./getTargeting-
|
|
60
|
+
var getTargeting = require('./getTargeting-37612527.js');
|
|
61
61
|
var urlFor = require('./urlFor.js');
|
|
62
62
|
|
|
63
63
|
var renderAuthor = function renderAuthor(authorName, authorURL, index, length) {
|
|
@@ -52,8 +52,6 @@ var getTargeting = function getTargeting(props) {
|
|
|
52
52
|
context = context && context.split('?')[0];
|
|
53
53
|
context = context && context.split('&')[0];
|
|
54
54
|
var content_placement_urls = [];
|
|
55
|
-
// New variable to store document group
|
|
56
|
-
var document_group_urls = [];
|
|
57
55
|
if (content_placement && prevUrl && prevUrl.length) {
|
|
58
56
|
content_placement.forEach(function (item) {
|
|
59
57
|
var path = item.path;
|
|
@@ -72,32 +70,21 @@ var getTargeting = function getTargeting(props) {
|
|
|
72
70
|
});
|
|
73
71
|
}
|
|
74
72
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
73
|
+
if (content_placement) {
|
|
74
|
+
if (content_placement_urls.length === 0) {
|
|
75
|
+
content_placement_urls = content_placement.map(function (item) {
|
|
76
|
+
return cpModificationRequired ? getContentPlacementUrl(item) : item.path;
|
|
77
|
+
});
|
|
80
78
|
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
document_group_urls.push(document_group);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
// Updating condition to set content_placement only when 'document_group_urls' and 'content_placement_urls' is empty.
|
|
88
|
-
if (content_placement && content_placement_urls.length === 0 && document_group_urls.length === 0) {
|
|
89
|
-
content_placement_urls = content_placement.map(function (item) {
|
|
90
|
-
return cpModificationRequired ? getContentPlacementUrl(item) : item.path;
|
|
91
|
-
});
|
|
79
|
+
} else {
|
|
80
|
+
content_placement_urls = ['/'];
|
|
92
81
|
}
|
|
93
|
-
|
|
94
82
|
var articleKeywords = [].concat(toConsumableArray._toConsumableArray(internalTag), toConsumableArray._toConsumableArray(userDefinedTag), toConsumableArray._toConsumableArray(SponsorshipTag), toConsumableArray._toConsumableArray(seoTag));
|
|
95
83
|
var targeting = {
|
|
96
84
|
tags: articleKeywords,
|
|
97
|
-
|
|
98
|
-
document_group: content_placement_urls && content_placement_urls.length ? '' : document_group_urls,
|
|
85
|
+
document_group: [document_group],
|
|
99
86
|
document_url: [url],
|
|
100
|
-
content_placement:
|
|
87
|
+
content_placement: content_placement_urls
|
|
101
88
|
};
|
|
102
89
|
|
|
103
90
|
if (article.issue && article.issue.path) {
|
package/dist/cjs/getTargeting.js
CHANGED
|
@@ -8,7 +8,7 @@ require('./from-ea347372.js');
|
|
|
8
8
|
require('./toConsumableArray-ca04303b.js');
|
|
9
9
|
require('./_object-pie-68c5bcbc.js');
|
|
10
10
|
require('./extends-60837c34.js');
|
|
11
|
-
var getTargeting = require('./getTargeting-
|
|
11
|
+
var getTargeting = require('./getTargeting-37612527.js');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
|
package/dist/cjs/index.js
CHANGED
|
@@ -158,7 +158,7 @@ require('swr');
|
|
|
158
158
|
require('passport-local');
|
|
159
159
|
require('mysql');
|
|
160
160
|
var View = require('./View.js');
|
|
161
|
-
var getTargeting = require('./getTargeting-
|
|
161
|
+
var getTargeting = require('./getTargeting-37612527.js');
|
|
162
162
|
var urlFor = require('./urlFor.js');
|
|
163
163
|
var getKeywords = require('./getKeywords.js');
|
|
164
164
|
var getQuery = require('./getQuery.js');
|
package/dist/esm/ArticleQueue.js
CHANGED
|
@@ -614,7 +614,7 @@ var Article = function Article(props) {
|
|
|
614
614
|
React__default.createElement(
|
|
615
615
|
'style',
|
|
616
616
|
{ jsx: 'true' },
|
|
617
|
-
'\n
|
|
617
|
+
'\n .sanityDisplayLabel {\n margin: .5rem 0;\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
618
618
|
)
|
|
619
619
|
);
|
|
620
620
|
};
|
|
@@ -49,7 +49,8 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
49
49
|
imageWidth = props.imageWidth,
|
|
50
50
|
client = props.client,
|
|
51
51
|
Settings = props.Settings,
|
|
52
|
-
index = props.index
|
|
52
|
+
index = props.index,
|
|
53
|
+
source = props.source;
|
|
53
54
|
|
|
54
55
|
return React__default.createElement(
|
|
55
56
|
Col,
|
|
@@ -59,19 +60,28 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
59
60
|
{ style: { boxShadow: 'none', borderBottom: '1px solid #aaa', paddingBottom: '1rem' } },
|
|
60
61
|
React__default.createElement(
|
|
61
62
|
'div',
|
|
62
|
-
{ style: { display: 'flex', flex: '1 0 auto' } },
|
|
63
|
+
{ style: { display: 'flex', flex: '1 0 auto', paddingBottom: '1rem' } },
|
|
63
64
|
coverImage && React__default.createElement(
|
|
64
|
-
'
|
|
65
|
-
{
|
|
65
|
+
'div',
|
|
66
|
+
{ style: { display: 'flex', flexDirection: 'column', justifyContent: 'center' } },
|
|
66
67
|
React__default.createElement(
|
|
67
|
-
|
|
68
|
-
{
|
|
69
|
-
React__default.createElement(
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
68
|
+
'a',
|
|
69
|
+
{ href: '/view/' + link },
|
|
70
|
+
React__default.createElement(
|
|
71
|
+
LazyLoad,
|
|
72
|
+
{ height: imageHeight },
|
|
73
|
+
React__default.createElement(Card.Img, {
|
|
74
|
+
variant: 'right',
|
|
75
|
+
src: renderCardImage({ coverImage: coverImage, imageHeight: imageHeight, imageWidth: imageWidth, client: client, Settings: Settings }),
|
|
76
|
+
alt: title,
|
|
77
|
+
style: { width: '170px', height: 'auto', objectFit: 'contain', padding: '0.25rem', float: 'left' }
|
|
78
|
+
})
|
|
79
|
+
)
|
|
80
|
+
),
|
|
81
|
+
source && React__default.createElement(
|
|
82
|
+
'div',
|
|
83
|
+
{ className: 'mb-2 sanityDisplayLabel displayLabelThumb' },
|
|
84
|
+
source
|
|
75
85
|
)
|
|
76
86
|
),
|
|
77
87
|
React__default.createElement(
|
|
@@ -99,6 +109,11 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
99
109
|
React__default.createElement(
|
|
100
110
|
'div',
|
|
101
111
|
{ style: { float: 'left' } },
|
|
112
|
+
source && !coverImage && React__default.createElement(
|
|
113
|
+
'div',
|
|
114
|
+
{ className: 'mb-2 sanityDisplayLabel' },
|
|
115
|
+
source
|
|
116
|
+
),
|
|
102
117
|
React__default.createElement(
|
|
103
118
|
'p',
|
|
104
119
|
{ style: { color: '#484848', fontSize: '.9rem', fontWeight: '600' }, className: 'mb-0' },
|
|
@@ -189,6 +204,7 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
189
204
|
imageHeight: imageHeight,
|
|
190
205
|
imageWidth: imageWidth,
|
|
191
206
|
client: client,
|
|
207
|
+
source: row.source,
|
|
192
208
|
published: row.published,
|
|
193
209
|
author: row.authorMapping && row.authorMapping.length > 0 ? row.authorMapping : [],
|
|
194
210
|
summary: row.summary
|
|
@@ -217,6 +233,11 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
217
233
|
'New content coming soon, please check back later.'
|
|
218
234
|
)
|
|
219
235
|
)
|
|
236
|
+
),
|
|
237
|
+
React__default.createElement(
|
|
238
|
+
'style',
|
|
239
|
+
{ jsx: 'true' },
|
|
240
|
+
'\n .displayLabelThumb {\n margin: 0 auto;\n margin-top: -1.25rem;\n background-color: white;\n position: relative;\n }\n .sanityDisplayLabel {\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
220
241
|
)
|
|
221
242
|
);
|
|
222
243
|
};
|
|
@@ -494,10 +494,10 @@ var PublicationLanding = function PublicationLanding(props) {
|
|
|
494
494
|
null,
|
|
495
495
|
issue.name
|
|
496
496
|
),
|
|
497
|
-
issue.
|
|
497
|
+
issue.source && React__default.createElement(
|
|
498
498
|
'p',
|
|
499
|
-
{ className: '
|
|
500
|
-
issue.
|
|
499
|
+
{ className: 'sanityDisplayLabel' },
|
|
500
|
+
issue.source
|
|
501
501
|
),
|
|
502
502
|
issue.volume && issue.number && React__default.createElement(
|
|
503
503
|
'p',
|
|
@@ -538,7 +538,7 @@ var PublicationLanding = function PublicationLanding(props) {
|
|
|
538
538
|
React__default.createElement(
|
|
539
539
|
'style',
|
|
540
540
|
{ jsx: 'true' },
|
|
541
|
-
'\n .issueCard.card:hover {\n cursor: default;\n }\n '
|
|
541
|
+
'\n .issueCard.card:hover {\n cursor: default;\n }\n .sanityDisplayLabel {\n border: 2px solid var(--franchise-primary, #484848);\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n '
|
|
542
542
|
)
|
|
543
543
|
);
|
|
544
544
|
};
|
|
@@ -251,6 +251,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
251
251
|
LazyLoad,
|
|
252
252
|
{ height: imageHeight },
|
|
253
253
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
254
|
+
),
|
|
255
|
+
article.source && React__default.createElement(
|
|
256
|
+
'div',
|
|
257
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
258
|
+
article.source
|
|
254
259
|
)
|
|
255
260
|
),
|
|
256
261
|
React__default.createElement(
|
|
@@ -275,7 +280,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
275
280
|
{ height: 50 },
|
|
276
281
|
React__default.createElement(AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
277
282
|
),
|
|
278
|
-
article.source && React__default.createElement(
|
|
283
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
279
284
|
'div',
|
|
280
285
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
281
286
|
article.source
|
|
@@ -347,6 +352,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
347
352
|
LazyLoad,
|
|
348
353
|
{ height: imageHeight },
|
|
349
354
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
355
|
+
),
|
|
356
|
+
article.source && React__default.createElement(
|
|
357
|
+
'div',
|
|
358
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
359
|
+
article.source
|
|
350
360
|
)
|
|
351
361
|
),
|
|
352
362
|
React__default.createElement(
|
|
@@ -371,7 +381,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
371
381
|
{ height: 50 },
|
|
372
382
|
React__default.createElement(AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
373
383
|
),
|
|
374
|
-
article.source && React__default.createElement(
|
|
384
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
375
385
|
'div',
|
|
376
386
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
377
387
|
article.source
|
|
@@ -451,6 +461,11 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
451
461
|
LazyLoad,
|
|
452
462
|
{ height: imageHeight },
|
|
453
463
|
article.thumbnail && article.thumbnail.asset ? React__default.createElement('img', { className: 'mr-3 img-fluid', src: renderCardImage(article, builder, imageHeight, imageWidth), alt: article.title }) : article.thumbnail ? React__default.createElement('img', { src: article.thumbnail, className: 'mr-3', alt: article.title }) : React__default.createElement('img', { src: defaultImage, src2: article.thumbnail, className: 'mr-3', width: '240', height: '135', alt: article.title })
|
|
464
|
+
),
|
|
465
|
+
article.source && React__default.createElement(
|
|
466
|
+
'div',
|
|
467
|
+
{ className: 'mb-1 sanityDisplayLabel displayLabelThumb' },
|
|
468
|
+
article.source
|
|
454
469
|
)
|
|
455
470
|
),
|
|
456
471
|
React__default.createElement(
|
|
@@ -479,7 +494,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
479
494
|
React__default.createElement(AuthorComponent, { key: index.toString(), index: index, authors: article.authorMapping })
|
|
480
495
|
)
|
|
481
496
|
),
|
|
482
|
-
article.source && React__default.createElement(
|
|
497
|
+
!article.thumbnail && !defaultImage && article.source && React__default.createElement(
|
|
483
498
|
'div',
|
|
484
499
|
{ className: 'mb-1 sanityDisplayLabel' },
|
|
485
500
|
article.source
|
|
@@ -543,7 +558,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
543
558
|
React__default.createElement(
|
|
544
559
|
'style',
|
|
545
560
|
{ jsx: 'true' },
|
|
546
|
-
'\n .sanityDisplayLabel {\n margin: 0.5rem 0;\n border: 1px solid black;\n width: fit-content;\n padding: 5px;\n }\n .feature-media > .media-body {\n -webkit-box-flex: none;\n -ms-flex: none;\n flex: none;\n }\n .img-wrapper img {\n max-height: 240px;\n height: auto;\n width: 100%;\n object-fit: contain;\n }\n .feature-wrapper {\n height: 100%;\n width: 100%;\n }\n .feature-wrapper img {\n width: 100%;\n margin-bottom: 1em;\n }\n @media only screen and (min-width: 768px) {\n .img-wrapper > img {\n padding-right: 1em;\n }\n }\n @media only screen and (max-width: 767px) {\n .img-wrapper {\n width: 100%;\n }\n .img-wrapper img {\n padding-bottom: 1em;\n }\n .media {\n flex-direction: column !important;\n }\n }\n '
|
|
561
|
+
'\n .displayLabelThumb{\n margin: 0 auto;\n margin-top: -1.25rem;\n background-color: white;\n position: relative;\n }\n .sanityDisplayLabel {\n margin: 0.5rem 0;\n border: 1px solid black;\n width: fit-content;\n padding: 5px;\n color: var(--franchise-primary, #484848);\n border-radius: 2px;\n }\n .feature-media > .media-body {\n -webkit-box-flex: none;\n -ms-flex: none;\n flex: none;\n }\n .img-wrapper img {\n max-height: 240px;\n height: auto;\n width: 100%;\n object-fit: contain;\n }\n .feature-wrapper {\n height: 100%;\n width: 100%;\n }\n .feature-wrapper img {\n width: 100%;\n margin-bottom: 1em;\n }\n @media only screen and (min-width: 768px) {\n .img-wrapper > img {\n padding-right: 1em;\n }\n }\n @media only screen and (max-width: 767px) {\n .img-wrapper {\n width: 100%;\n }\n .img-wrapper img {\n padding-bottom: 1em;\n }\n .media {\n flex-direction: column !important;\n }\n }\n '
|
|
547
562
|
)
|
|
548
563
|
);
|
|
549
564
|
};
|
package/dist/esm/View.js
CHANGED
|
@@ -52,7 +52,7 @@ import getSerializers from './getSerializers.js';
|
|
|
52
52
|
import './util-7700fc59.js';
|
|
53
53
|
import 'react-bootstrap/Pagination';
|
|
54
54
|
import 'next/dynamic';
|
|
55
|
-
import { a as getContentPlacementUrl, g as getTargeting } from './getTargeting-
|
|
55
|
+
import { a as getContentPlacementUrl, g as getTargeting } from './getTargeting-8f4bd5db.js';
|
|
56
56
|
import urlFor from './urlFor.js';
|
|
57
57
|
|
|
58
58
|
var renderAuthor = function renderAuthor(authorName, authorURL, index, length) {
|
|
@@ -50,8 +50,6 @@ var getTargeting = function getTargeting(props) {
|
|
|
50
50
|
context = context && context.split('?')[0];
|
|
51
51
|
context = context && context.split('&')[0];
|
|
52
52
|
var content_placement_urls = [];
|
|
53
|
-
// New variable to store document group
|
|
54
|
-
var document_group_urls = [];
|
|
55
53
|
if (content_placement && prevUrl && prevUrl.length) {
|
|
56
54
|
content_placement.forEach(function (item) {
|
|
57
55
|
var path = item.path;
|
|
@@ -70,32 +68,21 @@ var getTargeting = function getTargeting(props) {
|
|
|
70
68
|
});
|
|
71
69
|
}
|
|
72
70
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
71
|
+
if (content_placement) {
|
|
72
|
+
if (content_placement_urls.length === 0) {
|
|
73
|
+
content_placement_urls = content_placement.map(function (item) {
|
|
74
|
+
return cpModificationRequired ? getContentPlacementUrl(item) : item.path;
|
|
75
|
+
});
|
|
78
76
|
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
document_group_urls.push(document_group);
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
// Updating condition to set content_placement only when 'document_group_urls' and 'content_placement_urls' is empty.
|
|
86
|
-
if (content_placement && content_placement_urls.length === 0 && document_group_urls.length === 0) {
|
|
87
|
-
content_placement_urls = content_placement.map(function (item) {
|
|
88
|
-
return cpModificationRequired ? getContentPlacementUrl(item) : item.path;
|
|
89
|
-
});
|
|
77
|
+
} else {
|
|
78
|
+
content_placement_urls = ['/'];
|
|
90
79
|
}
|
|
91
|
-
|
|
92
80
|
var articleKeywords = [].concat(_toConsumableArray(internalTag), _toConsumableArray(userDefinedTag), _toConsumableArray(SponsorshipTag), _toConsumableArray(seoTag));
|
|
93
81
|
var targeting = {
|
|
94
82
|
tags: articleKeywords,
|
|
95
|
-
|
|
96
|
-
document_group: content_placement_urls && content_placement_urls.length ? '' : document_group_urls,
|
|
83
|
+
document_group: [document_group],
|
|
97
84
|
document_url: [url],
|
|
98
|
-
content_placement:
|
|
85
|
+
content_placement: content_placement_urls
|
|
99
86
|
};
|
|
100
87
|
|
|
101
88
|
if (article.issue && article.issue.path) {
|
package/dist/esm/getTargeting.js
CHANGED
package/dist/esm/index.js
CHANGED
|
@@ -154,7 +154,7 @@ import 'swr';
|
|
|
154
154
|
import 'passport-local';
|
|
155
155
|
import 'mysql';
|
|
156
156
|
export { default as View } from './View.js';
|
|
157
|
-
export { g as getTargeting } from './getTargeting-
|
|
157
|
+
export { g as getTargeting } from './getTargeting-8f4bd5db.js';
|
|
158
158
|
export { default as urlFor } from './urlFor.js';
|
|
159
159
|
export { default as getKeywords } from './getKeywords.js';
|
|
160
160
|
export { default as getQuery } from './getQuery.js';
|