@mjhls/mjh-framework 1.0.341 → 1.0.343
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/{Figure-a47ec3a7.js → Figure-b308d6a2.js} +4 -2
- package/dist/cjs/IssueContentDeck.js +7 -7
- package/dist/cjs/index.js +22 -12
- package/dist/esm/{Figure-584ac0c8.js → Figure-6394d22a.js} +4 -2
- package/dist/esm/IssueContentDeck.js +7 -7
- package/dist/esm/index.js +22 -12
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -40,7 +40,9 @@ var FigureComponent = function FigureComponent(props) {
|
|
|
40
40
|
blank = node.blank,
|
|
41
41
|
link = node.link,
|
|
42
42
|
_node$alignment = node.alignment,
|
|
43
|
-
alignment = _node$alignment === undefined ? 'center' : _node$alignment
|
|
43
|
+
alignment = _node$alignment === undefined ? 'center' : _node$alignment,
|
|
44
|
+
_node$class_name = node.class_name,
|
|
45
|
+
class_name = _node$class_name === undefined ? 'd-block' : _node$class_name;
|
|
44
46
|
var _node$widthP = node.widthP,
|
|
45
47
|
widthP = _node$widthP === undefined ? 'auto' : _node$widthP;
|
|
46
48
|
|
|
@@ -97,7 +99,7 @@ var FigureComponent = function FigureComponent(props) {
|
|
|
97
99
|
null,
|
|
98
100
|
imageWidth !== null && imageFloat !== null && React__default.createElement(
|
|
99
101
|
reactBootstrap.Figure,
|
|
100
|
-
{ className: '
|
|
102
|
+
{ className: '' + class_name, style: { width: imageWidth, maxWidth: '100%', clear: 'both', float: imageFloat, margin: figureMargin } },
|
|
101
103
|
link ? React__default.createElement(
|
|
102
104
|
'a',
|
|
103
105
|
{ target: blank ? '_blank' : '_self', href: link },
|
|
@@ -49,11 +49,11 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
49
49
|
imageWidth = props.imageWidth,
|
|
50
50
|
client = props.client,
|
|
51
51
|
Settings = props.Settings,
|
|
52
|
-
|
|
52
|
+
index = props.index;
|
|
53
53
|
|
|
54
54
|
return React__default.createElement(
|
|
55
55
|
Col,
|
|
56
|
-
{ md: 12, lg: 12, style: { display: 'flex', flex: '1 0 auto' }, key:
|
|
56
|
+
{ md: 12, lg: 12, style: { display: 'flex', flex: '1 0 auto' }, key: index },
|
|
57
57
|
React__default.createElement(
|
|
58
58
|
Card,
|
|
59
59
|
{ style: { boxShadow: 'none', borderBottom: '1px solid #aaa', paddingBottom: '1rem' } },
|
|
@@ -123,11 +123,11 @@ var PublicationDeckBlock = function PublicationDeckBlock(props) {
|
|
|
123
123
|
imageWidth = props.imageWidth,
|
|
124
124
|
client = props.client,
|
|
125
125
|
Settings = props.Settings,
|
|
126
|
-
|
|
126
|
+
index = props.index;
|
|
127
127
|
|
|
128
128
|
return React__default.createElement(
|
|
129
129
|
Col,
|
|
130
|
-
{ md: 12, lg: 6, style: { display: 'flex', flex: '1 0 auto' }, key:
|
|
130
|
+
{ md: 12, lg: 6, style: { display: 'flex', flex: '1 0 auto' }, key: index },
|
|
131
131
|
React__default.createElement(
|
|
132
132
|
Card,
|
|
133
133
|
null,
|
|
@@ -173,7 +173,7 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
173
173
|
data && data.length ? data.map(function (row, index) {
|
|
174
174
|
if (variant === 'stack') {
|
|
175
175
|
return row.url && row.url.current && React__default.createElement(PublicationDeckStack, {
|
|
176
|
-
|
|
176
|
+
index: index,
|
|
177
177
|
title: row.title,
|
|
178
178
|
coverImage: row.thumbnail,
|
|
179
179
|
link: row.url.current,
|
|
@@ -183,12 +183,12 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
183
183
|
imageWidth: imageWidth,
|
|
184
184
|
client: client,
|
|
185
185
|
published: row.published,
|
|
186
|
-
author: row.authorMapping.displayName
|
|
186
|
+
author: row.authorMapping && row.authorMapping.displayName ? row.authorMapping.displayName : '',
|
|
187
187
|
summary: row.summary
|
|
188
188
|
});
|
|
189
189
|
}
|
|
190
190
|
return React__default.createElement(PublicationDeckBlock, {
|
|
191
|
-
|
|
191
|
+
index: index,
|
|
192
192
|
title: row.title,
|
|
193
193
|
coverImage: row.thumbnail,
|
|
194
194
|
link: row.url.current,
|
package/dist/cjs/index.js
CHANGED
|
@@ -13671,7 +13671,7 @@ var NativeAd = function NativeAd(props) {
|
|
|
13671
13671
|
};
|
|
13672
13672
|
|
|
13673
13673
|
var Figure = dynamic(function () {
|
|
13674
|
-
return Promise.resolve().then(function () { return require('./Figure-
|
|
13674
|
+
return Promise.resolve().then(function () { return require('./Figure-b308d6a2.js'); });
|
|
13675
13675
|
}, { ssr: false });
|
|
13676
13676
|
|
|
13677
13677
|
var checkUrlIsExternal = function checkUrlIsExternal(url) {
|
|
@@ -16446,6 +16446,16 @@ var Article = function Article(props) {
|
|
|
16446
16446
|
})
|
|
16447
16447
|
});
|
|
16448
16448
|
var selectedIndex = indexes[1] + 1;
|
|
16449
|
+
|
|
16450
|
+
var checkIsAdFound = function checkIsAdFound(isFound) {
|
|
16451
|
+
if (!isFound) {
|
|
16452
|
+
var parent = document.getElementById('contextual-native-ad-' + payload._id);
|
|
16453
|
+
parent.style.height = '0%';
|
|
16454
|
+
parent.style.width = '0%';
|
|
16455
|
+
parent.style.display = 'none';
|
|
16456
|
+
}
|
|
16457
|
+
};
|
|
16458
|
+
|
|
16449
16459
|
return React__default.createElement(
|
|
16450
16460
|
React__default.Fragment,
|
|
16451
16461
|
null,
|
|
@@ -16456,8 +16466,8 @@ var Article = function Article(props) {
|
|
|
16456
16466
|
}, client.config())),
|
|
16457
16467
|
React__default.createElement(
|
|
16458
16468
|
'div',
|
|
16459
|
-
{ className: 'contextual-native-ad' },
|
|
16460
|
-
React__default.createElement(AdSlot.DFPAdSlot, _extends$2._extends({}, payload.contextualAD, { refreshFlag: false }))
|
|
16469
|
+
{ id: 'contextual-native-ad-' + payload._id, className: 'contextual-native-ad' },
|
|
16470
|
+
React__default.createElement(AdSlot.DFPAdSlot, _extends$2._extends({}, payload.contextualAD, { refreshFlag: false, checkIsAdFound: checkIsAdFound }))
|
|
16461
16471
|
),
|
|
16462
16472
|
React__default.createElement(TaxonomyCard.BlockContent, _extends$2._extends({
|
|
16463
16473
|
serializers: getSerializers(client, pageview, videoAccountIDs, function () {}, true, drupalLeadSettings),
|
|
@@ -16833,15 +16843,15 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
16833
16843
|
|
|
16834
16844
|
var changeMeta = function changeMeta(meta) {
|
|
16835
16845
|
document.title = meta.shareTitle;
|
|
16836
|
-
document.querySelector('meta[name="description"]').setAttribute(
|
|
16837
|
-
document.querySelector('meta[property="og:url"]').setAttribute(
|
|
16838
|
-
document.querySelector('meta[property="og:title"]').setAttribute(
|
|
16839
|
-
document.querySelector('meta[property="og:site_name"]').setAttribute(
|
|
16840
|
-
document.querySelector('meta[property="og:description"]').setAttribute(
|
|
16841
|
-
document.querySelector('meta[name="twitter:title"]').setAttribute(
|
|
16842
|
-
document.querySelector('meta[name="twitter:image"]').setAttribute(
|
|
16843
|
-
document.querySelector('meta[name="twitter:site"]').setAttribute(
|
|
16844
|
-
document.querySelector('meta[name="twitter:description"]').setAttribute(
|
|
16846
|
+
document.querySelector('meta[name="description"]').setAttribute('content', meta.shareSummary);
|
|
16847
|
+
document.querySelector('meta[property="og:url"]').setAttribute('content', meta.shareUrl);
|
|
16848
|
+
document.querySelector('meta[property="og:title"]').setAttribute('content', meta.shareTitle);
|
|
16849
|
+
document.querySelector('meta[property="og:site_name"]').setAttribute('content', meta.shareVia);
|
|
16850
|
+
document.querySelector('meta[property="og:description"]').setAttribute('content', meta.shareSummary);
|
|
16851
|
+
document.querySelector('meta[name="twitter:title"]').setAttribute('content', meta.shareTitle);
|
|
16852
|
+
document.querySelector('meta[name="twitter:image"]').setAttribute('content', meta.shareImage);
|
|
16853
|
+
document.querySelector('meta[name="twitter:site"]').setAttribute('content', meta.shareVia);
|
|
16854
|
+
document.querySelector('meta[name="twitter:description"]').setAttribute('content', meta.shareSummary);
|
|
16845
16855
|
};
|
|
16846
16856
|
|
|
16847
16857
|
var changeUrl = function changeUrl(path, visibility, meta) {
|
|
@@ -35,7 +35,9 @@ var FigureComponent = function FigureComponent(props) {
|
|
|
35
35
|
blank = node.blank,
|
|
36
36
|
link = node.link,
|
|
37
37
|
_node$alignment = node.alignment,
|
|
38
|
-
alignment = _node$alignment === undefined ? 'center' : _node$alignment
|
|
38
|
+
alignment = _node$alignment === undefined ? 'center' : _node$alignment,
|
|
39
|
+
_node$class_name = node.class_name,
|
|
40
|
+
class_name = _node$class_name === undefined ? 'd-block' : _node$class_name;
|
|
39
41
|
var _node$widthP = node.widthP,
|
|
40
42
|
widthP = _node$widthP === undefined ? 'auto' : _node$widthP;
|
|
41
43
|
|
|
@@ -92,7 +94,7 @@ var FigureComponent = function FigureComponent(props) {
|
|
|
92
94
|
null,
|
|
93
95
|
imageWidth !== null && imageFloat !== null && React__default.createElement(
|
|
94
96
|
Figure$1,
|
|
95
|
-
{ className: '
|
|
97
|
+
{ className: '' + class_name, style: { width: imageWidth, maxWidth: '100%', clear: 'both', float: imageFloat, margin: figureMargin } },
|
|
96
98
|
link ? React__default.createElement(
|
|
97
99
|
'a',
|
|
98
100
|
{ target: blank ? '_blank' : '_self', href: link },
|
|
@@ -44,11 +44,11 @@ var PublicationDeckStack = function PublicationDeckStack(props) {
|
|
|
44
44
|
imageWidth = props.imageWidth,
|
|
45
45
|
client = props.client,
|
|
46
46
|
Settings = props.Settings,
|
|
47
|
-
|
|
47
|
+
index = props.index;
|
|
48
48
|
|
|
49
49
|
return React__default.createElement(
|
|
50
50
|
Col,
|
|
51
|
-
{ md: 12, lg: 12, style: { display: 'flex', flex: '1 0 auto' }, key:
|
|
51
|
+
{ md: 12, lg: 12, style: { display: 'flex', flex: '1 0 auto' }, key: index },
|
|
52
52
|
React__default.createElement(
|
|
53
53
|
Card,
|
|
54
54
|
{ style: { boxShadow: 'none', borderBottom: '1px solid #aaa', paddingBottom: '1rem' } },
|
|
@@ -118,11 +118,11 @@ var PublicationDeckBlock = function PublicationDeckBlock(props) {
|
|
|
118
118
|
imageWidth = props.imageWidth,
|
|
119
119
|
client = props.client,
|
|
120
120
|
Settings = props.Settings,
|
|
121
|
-
|
|
121
|
+
index = props.index;
|
|
122
122
|
|
|
123
123
|
return React__default.createElement(
|
|
124
124
|
Col,
|
|
125
|
-
{ md: 12, lg: 6, style: { display: 'flex', flex: '1 0 auto' }, key:
|
|
125
|
+
{ md: 12, lg: 6, style: { display: 'flex', flex: '1 0 auto' }, key: index },
|
|
126
126
|
React__default.createElement(
|
|
127
127
|
Card,
|
|
128
128
|
null,
|
|
@@ -168,7 +168,7 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
168
168
|
data && data.length ? data.map(function (row, index) {
|
|
169
169
|
if (variant === 'stack') {
|
|
170
170
|
return row.url && row.url.current && React__default.createElement(PublicationDeckStack, {
|
|
171
|
-
|
|
171
|
+
index: index,
|
|
172
172
|
title: row.title,
|
|
173
173
|
coverImage: row.thumbnail,
|
|
174
174
|
link: row.url.current,
|
|
@@ -178,12 +178,12 @@ var IssueContentDeck = function IssueContentDeck(props) {
|
|
|
178
178
|
imageWidth: imageWidth,
|
|
179
179
|
client: client,
|
|
180
180
|
published: row.published,
|
|
181
|
-
author: row.authorMapping.displayName
|
|
181
|
+
author: row.authorMapping && row.authorMapping.displayName ? row.authorMapping.displayName : '',
|
|
182
182
|
summary: row.summary
|
|
183
183
|
});
|
|
184
184
|
}
|
|
185
185
|
return React__default.createElement(PublicationDeckBlock, {
|
|
186
|
-
|
|
186
|
+
index: index,
|
|
187
187
|
title: row.title,
|
|
188
188
|
coverImage: row.thumbnail,
|
|
189
189
|
link: row.url.current,
|
package/dist/esm/index.js
CHANGED
|
@@ -13668,7 +13668,7 @@ var NativeAd = function NativeAd(props) {
|
|
|
13668
13668
|
};
|
|
13669
13669
|
|
|
13670
13670
|
var Figure = dynamic(function () {
|
|
13671
|
-
return import('./Figure-
|
|
13671
|
+
return import('./Figure-6394d22a.js');
|
|
13672
13672
|
}, { ssr: false });
|
|
13673
13673
|
|
|
13674
13674
|
var checkUrlIsExternal = function checkUrlIsExternal(url) {
|
|
@@ -16443,6 +16443,16 @@ var Article = function Article(props) {
|
|
|
16443
16443
|
})
|
|
16444
16444
|
});
|
|
16445
16445
|
var selectedIndex = indexes[1] + 1;
|
|
16446
|
+
|
|
16447
|
+
var checkIsAdFound = function checkIsAdFound(isFound) {
|
|
16448
|
+
if (!isFound) {
|
|
16449
|
+
var parent = document.getElementById('contextual-native-ad-' + payload._id);
|
|
16450
|
+
parent.style.height = '0%';
|
|
16451
|
+
parent.style.width = '0%';
|
|
16452
|
+
parent.style.display = 'none';
|
|
16453
|
+
}
|
|
16454
|
+
};
|
|
16455
|
+
|
|
16446
16456
|
return React__default.createElement(
|
|
16447
16457
|
React__default.Fragment,
|
|
16448
16458
|
null,
|
|
@@ -16453,8 +16463,8 @@ var Article = function Article(props) {
|
|
|
16453
16463
|
}, client.config())),
|
|
16454
16464
|
React__default.createElement(
|
|
16455
16465
|
'div',
|
|
16456
|
-
{ className: 'contextual-native-ad' },
|
|
16457
|
-
React__default.createElement(DFPAdSlot, _extends$2({}, payload.contextualAD, { refreshFlag: false }))
|
|
16466
|
+
{ id: 'contextual-native-ad-' + payload._id, className: 'contextual-native-ad' },
|
|
16467
|
+
React__default.createElement(DFPAdSlot, _extends$2({}, payload.contextualAD, { refreshFlag: false, checkIsAdFound: checkIsAdFound }))
|
|
16458
16468
|
),
|
|
16459
16469
|
React__default.createElement(BlockContent, _extends$2({
|
|
16460
16470
|
serializers: getSerializers(client, pageview, videoAccountIDs, function () {}, true, drupalLeadSettings),
|
|
@@ -16830,15 +16840,15 @@ var ArticleQueue = function ArticleQueue(props) {
|
|
|
16830
16840
|
|
|
16831
16841
|
var changeMeta = function changeMeta(meta) {
|
|
16832
16842
|
document.title = meta.shareTitle;
|
|
16833
|
-
document.querySelector('meta[name="description"]').setAttribute(
|
|
16834
|
-
document.querySelector('meta[property="og:url"]').setAttribute(
|
|
16835
|
-
document.querySelector('meta[property="og:title"]').setAttribute(
|
|
16836
|
-
document.querySelector('meta[property="og:site_name"]').setAttribute(
|
|
16837
|
-
document.querySelector('meta[property="og:description"]').setAttribute(
|
|
16838
|
-
document.querySelector('meta[name="twitter:title"]').setAttribute(
|
|
16839
|
-
document.querySelector('meta[name="twitter:image"]').setAttribute(
|
|
16840
|
-
document.querySelector('meta[name="twitter:site"]').setAttribute(
|
|
16841
|
-
document.querySelector('meta[name="twitter:description"]').setAttribute(
|
|
16843
|
+
document.querySelector('meta[name="description"]').setAttribute('content', meta.shareSummary);
|
|
16844
|
+
document.querySelector('meta[property="og:url"]').setAttribute('content', meta.shareUrl);
|
|
16845
|
+
document.querySelector('meta[property="og:title"]').setAttribute('content', meta.shareTitle);
|
|
16846
|
+
document.querySelector('meta[property="og:site_name"]').setAttribute('content', meta.shareVia);
|
|
16847
|
+
document.querySelector('meta[property="og:description"]').setAttribute('content', meta.shareSummary);
|
|
16848
|
+
document.querySelector('meta[name="twitter:title"]').setAttribute('content', meta.shareTitle);
|
|
16849
|
+
document.querySelector('meta[name="twitter:image"]').setAttribute('content', meta.shareImage);
|
|
16850
|
+
document.querySelector('meta[name="twitter:site"]').setAttribute('content', meta.shareVia);
|
|
16851
|
+
document.querySelector('meta[name="twitter:description"]').setAttribute('content', meta.shareSummary);
|
|
16842
16852
|
};
|
|
16843
16853
|
|
|
16844
16854
|
var changeUrl = function changeUrl(path, visibility, meta) {
|