@mjhls/mjh-framework 1.0.994-Cypress → 1.0.994-CypressV2
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/ArticleProgramLandingPage.js +1 -1
- package/dist/cjs/CypressTesting.js +4 -3
- package/dist/cjs/ExternalResources.js +1 -1
- package/dist/cjs/HamMagazine.js +20 -20
- package/dist/cjs/HorizontalArticleListing.js +1 -1
- package/dist/cjs/IssueLanding.js +1 -1
- package/dist/cjs/MediaSeriesCard-2e5cd247.js +81 -0
- package/dist/cjs/MediaSeriesLanding.js +17 -16
- package/dist/cjs/MediaSeriesLandingPaginated.js +16 -15
- package/dist/cjs/PartnerDetailListing.js +1 -1
- package/dist/cjs/PartnerDetailListingPaginated.js +30 -8
- package/dist/cjs/PodcastsLanding.js +235 -0
- package/dist/cjs/TaxonomyDescription.js +1 -1
- package/dist/cjs/{MediaSeriesCard-cf144b71.js → Tooltip-f075b7ef.js} +0 -73
- package/dist/cjs/VideoProgramLandingPage.js +1 -1
- package/dist/cjs/View.js +51 -38
- package/dist/cjs/getQuery.js +1 -1
- package/dist/cjs/getSerializers.js +1 -1
- package/dist/cjs/{index-e9d3f910.js → index-f95a3c0f.js} +20 -7
- package/dist/cjs/index.js +1 -1
- package/dist/esm/ArticleProgramLandingPage.js +1 -1
- package/dist/esm/CypressTesting.js +4 -3
- package/dist/esm/ExternalResources.js +1 -1
- package/dist/esm/HamMagazine.js +18 -18
- package/dist/esm/HorizontalArticleListing.js +1 -1
- package/dist/esm/IssueLanding.js +1 -1
- package/dist/esm/MediaSeriesCard-afb517a5.js +75 -0
- package/dist/esm/MediaSeriesLanding.js +8 -7
- package/dist/esm/MediaSeriesLandingPaginated.js +7 -6
- package/dist/esm/PartnerDetailListing.js +1 -1
- package/dist/esm/PartnerDetailListingPaginated.js +30 -8
- package/dist/esm/PodcastsLanding.js +228 -0
- package/dist/esm/TaxonomyDescription.js +1 -1
- package/dist/esm/{MediaSeriesCard-2a65b9da.js → Tooltip-95655b44.js} +1 -73
- package/dist/esm/VideoProgramLandingPage.js +1 -1
- package/dist/esm/View.js +51 -38
- package/dist/esm/getQuery.js +1 -1
- package/dist/esm/getSerializers.js +1 -1
- package/dist/esm/{index-9a58ca55.js → index-04817712.js} +20 -7
- package/dist/esm/index.js +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var asyncToGenerator = require('./asyncToGenerator-77821af0.js');
|
|
4
|
+
var _extends = require('./extends-7c86182f.js');
|
|
5
|
+
var slicedToArray = require('./slicedToArray-067dd3bc.js');
|
|
6
|
+
var React = require('react');
|
|
7
|
+
var Link = require('next/link');
|
|
8
|
+
var MasterDeck = require('./MasterDeck.js');
|
|
9
|
+
var MediaSeriesCard = require('./MediaSeriesCard-2e5cd247.js');
|
|
10
|
+
var BlockContent = require('./BlockContent-9ebd251f.js');
|
|
11
|
+
var getSerializers = require('./index-f95a3c0f.js');
|
|
12
|
+
require('./_commonjsHelpers-06173234.js');
|
|
13
|
+
require('./core.get-iterator-method-5643aa10.js');
|
|
14
|
+
require('./web.dom.iterable-d98303e0.js');
|
|
15
|
+
require('./_library-dd23b178.js');
|
|
16
|
+
require('./_iter-detect-b1df62f0.js');
|
|
17
|
+
require('./_object-pie-083f2dd6.js');
|
|
18
|
+
require('./toConsumableArray-d7797c2b.js');
|
|
19
|
+
require('./inherits-de66ea16.js');
|
|
20
|
+
require('./_object-sap-d1978572.js');
|
|
21
|
+
require('./define-property-e8404b64.js');
|
|
22
|
+
require('./typeof-567e31ff.js');
|
|
23
|
+
require('./_is-array-54228b29.js');
|
|
24
|
+
require('./index-fc2f1ca2.js');
|
|
25
|
+
require('./events-1b438fe7.js');
|
|
26
|
+
require('prop-types');
|
|
27
|
+
require('react-bootstrap/Container');
|
|
28
|
+
require('react-bootstrap/Row');
|
|
29
|
+
require('react-bootstrap/Col');
|
|
30
|
+
require('react-bootstrap/Card');
|
|
31
|
+
require('./moment-aca40de1.js');
|
|
32
|
+
require('next/router');
|
|
33
|
+
require('./lodash-f0783643.js');
|
|
34
|
+
require('./debounce-d4a2369b.js');
|
|
35
|
+
require('./isSymbol-03abbdf0.js');
|
|
36
|
+
require('./toNumber-5e1fac58.js');
|
|
37
|
+
require('./index.es-f3e47207.js');
|
|
38
|
+
require('./visibility-sensor-eb2c5b69.js');
|
|
39
|
+
require('react-dom');
|
|
40
|
+
require('./index-d48b231c.js');
|
|
41
|
+
require('./ADlgInfeed-b5a3d436.js');
|
|
42
|
+
require('./AdSlot.js');
|
|
43
|
+
require('./Beam.js');
|
|
44
|
+
require('./stringify-f7a37a8d.js');
|
|
45
|
+
require('./Segment.js');
|
|
46
|
+
require('./main-f1c77adb.js');
|
|
47
|
+
require('./ADInfeed-e87afe8a.js');
|
|
48
|
+
require('./index-eadd5035.js');
|
|
49
|
+
require('./urlFor.js');
|
|
50
|
+
require('./style-inject.es-dcee06b6.js');
|
|
51
|
+
require('react-bootstrap');
|
|
52
|
+
require('./index-187c967e.js');
|
|
53
|
+
require('./util-93a37fd0.js');
|
|
54
|
+
require('./urlForFile-29d3815a.js');
|
|
55
|
+
require('./brightcove-react-player-loader.es-a195642e.js');
|
|
56
|
+
require('react-bootstrap/Modal');
|
|
57
|
+
require('react-bootstrap/Button');
|
|
58
|
+
require('react-bootstrap/Form');
|
|
59
|
+
require('react-ga');
|
|
60
|
+
require('./GroupDeck.js');
|
|
61
|
+
require('./smoothscroll-99df7f93.js');
|
|
62
|
+
require('./SocialShare.js');
|
|
63
|
+
require('next/head');
|
|
64
|
+
require('react-share');
|
|
65
|
+
require('./_object-to-array-ce86cae7.js');
|
|
66
|
+
require('react-bootstrap/Pagination');
|
|
67
|
+
require('./entities-df1aed86.js');
|
|
68
|
+
require('./index.esm-d81454e7.js');
|
|
69
|
+
require('./iconBase-be4097c0.js');
|
|
70
|
+
require('react-bootstrap/Figure');
|
|
71
|
+
require('react-bootstrap/OverlayTrigger');
|
|
72
|
+
require('react-bootstrap/Tooltip');
|
|
73
|
+
require('react-bootstrap/Popover');
|
|
74
|
+
require('./checkSisterSite-b29833b2.js');
|
|
75
|
+
|
|
76
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
77
|
+
|
|
78
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
79
|
+
var Link__default = /*#__PURE__*/_interopDefaultLegacy(Link);
|
|
80
|
+
|
|
81
|
+
var _this = undefined;
|
|
82
|
+
|
|
83
|
+
var PodcastsLanding = function PodcastsLanding(props) {
|
|
84
|
+
var client = props.client,
|
|
85
|
+
pageview = props.pageview,
|
|
86
|
+
currentPage = props.currentPage;
|
|
87
|
+
props.taxonomyId;
|
|
88
|
+
props.parentUrl;
|
|
89
|
+
var nextPagePostsCount = props.nextPagePostsCount;
|
|
90
|
+
|
|
91
|
+
var _useState = React.useState(props.seriesData),
|
|
92
|
+
_useState2 = slicedToArray._slicedToArray(_useState, 2),
|
|
93
|
+
seriesData = _useState2[0];
|
|
94
|
+
_useState2[1];
|
|
95
|
+
|
|
96
|
+
var _useState3 = React.useState(props.params),
|
|
97
|
+
_useState4 = slicedToArray._slicedToArray(_useState3, 2),
|
|
98
|
+
params = _useState4[0];
|
|
99
|
+
_useState4[1];
|
|
100
|
+
|
|
101
|
+
var _useState5 = React.useState(props.query),
|
|
102
|
+
_useState6 = slicedToArray._slicedToArray(_useState5, 2),
|
|
103
|
+
query = _useState6[0];
|
|
104
|
+
_useState6[1];
|
|
105
|
+
|
|
106
|
+
if (props.statusCode === 404) {
|
|
107
|
+
return React__default['default'].createElement(
|
|
108
|
+
'div',
|
|
109
|
+
{ className: 'd-flex flex-column align-items-center mt-3' },
|
|
110
|
+
React__default['default'].createElement(
|
|
111
|
+
'h3',
|
|
112
|
+
null,
|
|
113
|
+
'404: Resource not found'
|
|
114
|
+
),
|
|
115
|
+
React__default['default'].createElement(
|
|
116
|
+
'p',
|
|
117
|
+
null,
|
|
118
|
+
'We seem to have misplaced the page you\'re looking for. Sorry! Please try checking the URL for errors.'
|
|
119
|
+
),
|
|
120
|
+
React__default['default'].createElement(
|
|
121
|
+
'p',
|
|
122
|
+
null,
|
|
123
|
+
'Click here to',
|
|
124
|
+
React__default['default'].createElement(
|
|
125
|
+
Link__default['default'],
|
|
126
|
+
{ href: '/' },
|
|
127
|
+
React__default['default'].createElement(
|
|
128
|
+
'a',
|
|
129
|
+
{ style: { color: 'blue', textDecoration: 'underline' } },
|
|
130
|
+
' return to homepage.'
|
|
131
|
+
)
|
|
132
|
+
)
|
|
133
|
+
)
|
|
134
|
+
);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
return React__default['default'].createElement(
|
|
138
|
+
'div',
|
|
139
|
+
{ className: 'mb-5' },
|
|
140
|
+
props.taxonomy && props.taxonomy.summary && React__default['default'].createElement(BlockContent.BlockContent, { style: { marginTop: '1rem !important' }, blocks: props.taxonomy.summary, serializers: getSerializers.getSerializers(client) }),
|
|
141
|
+
React__default['default'].createElement('hr', { style: { marginTop: '2rem', marginBottom: '2rem' } }),
|
|
142
|
+
seriesData && React__default['default'].createElement(MasterDeck, {
|
|
143
|
+
deck: MediaSeriesCard.MediaSeriesCard,
|
|
144
|
+
variant: 'left',
|
|
145
|
+
defaultImage: '/placeholder.jpg',
|
|
146
|
+
client: client,
|
|
147
|
+
dataRecord: seriesData,
|
|
148
|
+
query: query && query,
|
|
149
|
+
params: params && params,
|
|
150
|
+
currentPage: currentPage,
|
|
151
|
+
pageview: pageview,
|
|
152
|
+
autoScroll: true,
|
|
153
|
+
seoPaginate: true,
|
|
154
|
+
nextPagePostsCount: nextPagePostsCount
|
|
155
|
+
})
|
|
156
|
+
);
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
PodcastsLanding.getInitialData = function () {
|
|
160
|
+
var _ref = asyncToGenerator._asyncToGenerator( /*#__PURE__*/asyncToGenerator.regenerator.mark(function _callee(ctx, client, cache) {
|
|
161
|
+
var urlQuery, pathname, identifier, itemsPerPage, currentPage, start, statusCode, params, taxonomyId, seriesQuery, seriesData, nextPagePostsCount;
|
|
162
|
+
return asyncToGenerator.regenerator.wrap(function _callee$(_context) {
|
|
163
|
+
while (1) {
|
|
164
|
+
switch (_context.prev = _context.next) {
|
|
165
|
+
case 0:
|
|
166
|
+
urlQuery = ctx.query, pathname = ctx.pathname;
|
|
167
|
+
identifier = pathname.replace('/', '');
|
|
168
|
+
itemsPerPage = 10;
|
|
169
|
+
currentPage = urlQuery.page ? parseInt(urlQuery.page) : 1;
|
|
170
|
+
start = (currentPage - 1) * itemsPerPage;
|
|
171
|
+
statusCode = 200;
|
|
172
|
+
params = {
|
|
173
|
+
count: itemsPerPage,
|
|
174
|
+
from: start,
|
|
175
|
+
to: start + itemsPerPage,
|
|
176
|
+
url: pathname,
|
|
177
|
+
itemsPerPage: itemsPerPage
|
|
178
|
+
};
|
|
179
|
+
_context.next = 9;
|
|
180
|
+
return client.fetch('*[_type == \'taxonomy\' && identifier == \'' + identifier + '\'][0]{\n _id, \n name,\n summary,\n pixelTrackingCode->\n }');
|
|
181
|
+
|
|
182
|
+
case 9:
|
|
183
|
+
taxonomyId = _context.sent;
|
|
184
|
+
|
|
185
|
+
// const taxonomyId = await client.fetch(`*[_type == 'taxonomy' && _id == '6d748e0d-7946-4a14-968e-ca8182f06c1e']`)
|
|
186
|
+
// console.log('taxonomyId', taxonomyId)
|
|
187
|
+
seriesQuery = '*[_type == \'taxonomy\' && isMainTopic == true && references(\'' + taxonomyId._id + '\')] | order(published desc) [$from...$to] {\n _id,\n name,\n identifier,\n thumbnail{ ..., asset-> },\n summary,\n \'pageNumber\': ' + currentPage + ',\n \'parentUrl\': \'' + identifier + '\'\n }';
|
|
188
|
+
_context.next = 13;
|
|
189
|
+
return client.fetch(seriesQuery, params);
|
|
190
|
+
|
|
191
|
+
case 13:
|
|
192
|
+
seriesData = _context.sent;
|
|
193
|
+
|
|
194
|
+
seriesData.forEach(function (seriesObj) {
|
|
195
|
+
seriesObj.description = seriesObj.summary;
|
|
196
|
+
seriesObj.identifier = { _type: 'slug', current: seriesObj.identifier };
|
|
197
|
+
});
|
|
198
|
+
_context.next = 17;
|
|
199
|
+
return client.fetch('count(' + seriesQuery + ')', _extends._extends({}, params, { from: params.to, to: params.to + itemsPerPage }));
|
|
200
|
+
|
|
201
|
+
case 17:
|
|
202
|
+
nextPagePostsCount = _context.sent;
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
if (currentPage > 1 && seriesData.length === 0) {
|
|
206
|
+
statusCode = 404;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
return _context.abrupt('return', {
|
|
210
|
+
seriesData: seriesData,
|
|
211
|
+
query: seriesQuery,
|
|
212
|
+
params: params,
|
|
213
|
+
currentPage: currentPage,
|
|
214
|
+
identifier: identifier,
|
|
215
|
+
taxonomyId: taxonomyId,
|
|
216
|
+
parentUrl: identifier,
|
|
217
|
+
statusCode: statusCode,
|
|
218
|
+
taxonomy: taxonomyId,
|
|
219
|
+
nextPagePostsCount: nextPagePostsCount
|
|
220
|
+
});
|
|
221
|
+
|
|
222
|
+
case 20:
|
|
223
|
+
case 'end':
|
|
224
|
+
return _context.stop();
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
}, _callee, _this);
|
|
228
|
+
}));
|
|
229
|
+
|
|
230
|
+
return function (_x, _x2, _x3) {
|
|
231
|
+
return _ref.apply(this, arguments);
|
|
232
|
+
};
|
|
233
|
+
}();
|
|
234
|
+
|
|
235
|
+
module.exports = PodcastsLanding;
|
|
@@ -7,7 +7,7 @@ var React = require('react');
|
|
|
7
7
|
var Router = require('next/router');
|
|
8
8
|
var Head = require('next/head');
|
|
9
9
|
var BlockContent = require('./BlockContent-9ebd251f.js');
|
|
10
|
-
var getSerializers = require('./index-
|
|
10
|
+
var getSerializers = require('./index-f95a3c0f.js');
|
|
11
11
|
require('./_commonjsHelpers-06173234.js');
|
|
12
12
|
require('./core.get-iterator-method-5643aa10.js');
|
|
13
13
|
require('./_object-pie-083f2dd6.js');
|
|
@@ -5,13 +5,6 @@ var React = require('react');
|
|
|
5
5
|
var PropTypes = require('prop-types');
|
|
6
6
|
var ReactDOM = require('react-dom');
|
|
7
7
|
var _commonjsHelpers = require('./_commonjsHelpers-06173234.js');
|
|
8
|
-
var _typeof = require('./typeof-567e31ff.js');
|
|
9
|
-
var index$1 = require('./index-eadd5035.js');
|
|
10
|
-
var urlFor = require('./urlFor.js');
|
|
11
|
-
var moment = require('./moment-aca40de1.js');
|
|
12
|
-
var styleInject_es = require('./style-inject.es-dcee06b6.js');
|
|
13
|
-
var BlockContent = require('./BlockContent-9ebd251f.js');
|
|
14
|
-
var getSerializers = require('./index-e9d3f910.js');
|
|
15
8
|
|
|
16
9
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
17
10
|
|
|
@@ -9457,71 +9450,5 @@ var Tooltip = React__default['default'].forwardRef(function (_ref, ref) {
|
|
|
9457
9450
|
Tooltip.defaultProps = defaultProps;
|
|
9458
9451
|
Tooltip.displayName = 'Tooltip';
|
|
9459
9452
|
|
|
9460
|
-
var css = ".MediaSeriesCard-module_article__SAFYK {\n width: 100%;\n margin: 0 0 1rem 0;\n}\n.MediaSeriesCard-module_article__SAFYK a {\n display: flex;\n width: 100%;\n color: #000000;\n}\n.MediaSeriesCard-module_thumb__3jRAU {\n width: 25%;\n}\n.MediaSeriesCard-module_thumb__3jRAU img {\n width: 100%;\n height: auto;\n}\n.MediaSeriesCard-module_info__3L7_o {\n width: 75%;\n font-size: 1rem;\n}\n.MediaSeriesCard-module_info__3L7_o h2 {\n font-weight: bold;\n font-size: 1.25rem;\n margin: 0;\n}\n.MediaSeriesCard-module_published__E4oiz {\n color: #6d6d6d;\n margin: 0;\n}\n.MediaSeriesCard-module_summary__1xanh {\n margin: 0.5rem 0 0 0;\n}\n.MediaSeriesCard-module_author__e5fuR {\n margin: 0;\n}\n.MediaSeriesCard-module_author__e5fuR span {\n color: #6d6d6d;\n}\n.MediaSeriesCard-module_name__2m5KY {\n font-size: 1.3rem;\n font-weight: bold;\n}\n@media only screen and (max-width: 568px) {\n .MediaSeriesCard-module_article__SAFYK {\n margin: 1rem 0;\n box-shadow: 2px 4px 8px rgba(0,0,0,.2);\n }\n .MediaSeriesCard-module_article__SAFYK a {\n flex-direction: column;\n align-items: center;\n }\n .MediaSeriesCard-module_thumb__3jRAU {\n overflow: hidden;\n width: 100%;\n margin-bottom: 1rem;\n }\n .MediaSeriesCard-module_thumb__3jRAU img{\n border-radius: 10px 10px 0 0; \n }\n .MediaSeriesCard-module_thumb__3jRAU figure {\n margin: 0;\n }\n .MediaSeriesCard-module_info__3L7_o {\n width: 90%;\n padding: 0rem !important;\n }\n .MediaSeriesCard-module_info__3L7_o h2 {\n font-size: 1rem;\n }\n .MediaSeriesCard-module_name__2m5KY {\n font-size: 1rem;\n \n }\n}\n";
|
|
9461
|
-
var styles = { "article": "MediaSeriesCard-module_article__SAFYK", "thumb": "MediaSeriesCard-module_thumb__3jRAU", "info": "MediaSeriesCard-module_info__3L7_o", "published": "MediaSeriesCard-module_published__E4oiz", "summary": "MediaSeriesCard-module_summary__1xanh", "author": "MediaSeriesCard-module_author__e5fuR", "name": "MediaSeriesCard-module_name__2m5KY" };
|
|
9462
|
-
styleInject_es.styleInject(css);
|
|
9463
|
-
|
|
9464
|
-
var MediaSeriesCard = function MediaSeriesCard(props) {
|
|
9465
|
-
var data = props.data,
|
|
9466
|
-
variant = props.variant,
|
|
9467
|
-
defaultImage = props.defaultImage,
|
|
9468
|
-
client = props.client;
|
|
9469
|
-
|
|
9470
|
-
|
|
9471
|
-
return React__default['default'].createElement(
|
|
9472
|
-
'div',
|
|
9473
|
-
{ className: 'media-series-article ' + styles.article },
|
|
9474
|
-
React__default['default'].createElement(
|
|
9475
|
-
'a',
|
|
9476
|
-
{ href: '/' + data.parentUrl + '/' + data.identifier.current, style: variant === 'right' ? { flexDirection: 'row-reverse' } : {} },
|
|
9477
|
-
React__default['default'].createElement(
|
|
9478
|
-
'div',
|
|
9479
|
-
{ className: 'media-series-thumbnail ' + styles.thumb },
|
|
9480
|
-
data.thumbnail && data.thumbnail.asset && React__default['default'].createElement(
|
|
9481
|
-
'figure',
|
|
9482
|
-
null,
|
|
9483
|
-
React__default['default'].createElement(
|
|
9484
|
-
index$1.LazyLoad,
|
|
9485
|
-
null,
|
|
9486
|
-
React__default['default'].createElement('img', {
|
|
9487
|
-
src: data.thumbnail && data.thumbnail.asset ? urlFor({ client: client, source: data.thumbnail }) : data.thumbnail && _typeof._typeof(data.thumbnail == 'string') ? data.thumbnail : defaultImage
|
|
9488
|
-
})
|
|
9489
|
-
)
|
|
9490
|
-
)
|
|
9491
|
-
),
|
|
9492
|
-
React__default['default'].createElement(
|
|
9493
|
-
'div',
|
|
9494
|
-
{ className: 'media-series-info ' + styles.info, style: variant === 'right' ? { padding: '0 1rem 0 0' } : { padding: ' 0 0 0 1rem' } },
|
|
9495
|
-
React__default['default'].createElement(
|
|
9496
|
-
'div',
|
|
9497
|
-
{ className: 'media-series-name ' + styles.name },
|
|
9498
|
-
data.name
|
|
9499
|
-
),
|
|
9500
|
-
data.published && React__default['default'].createElement(
|
|
9501
|
-
'p',
|
|
9502
|
-
{ className: 'media-series-published ' + styles.published },
|
|
9503
|
-
moment.moment(data.published).format('MMMM Do YYYY')
|
|
9504
|
-
),
|
|
9505
|
-
data.authorMapping && data.authorMapping.displayName && React__default['default'].createElement(
|
|
9506
|
-
'p',
|
|
9507
|
-
{ className: 'media-series-author ' + styles.author },
|
|
9508
|
-
'By ',
|
|
9509
|
-
React__default['default'].createElement(
|
|
9510
|
-
'span',
|
|
9511
|
-
null,
|
|
9512
|
-
data.authorMapping.displayName
|
|
9513
|
-
)
|
|
9514
|
-
),
|
|
9515
|
-
data.description && React__default['default'].createElement(
|
|
9516
|
-
'div',
|
|
9517
|
-
{ className: 'media-series-desc' },
|
|
9518
|
-
React__default['default'].createElement(BlockContent.BlockContent, { blocks: data.description, serializers: getSerializers.getSerializers(client) })
|
|
9519
|
-
)
|
|
9520
|
-
)
|
|
9521
|
-
)
|
|
9522
|
-
);
|
|
9523
|
-
};
|
|
9524
|
-
|
|
9525
9453
|
exports.Dropdown = Dropdown;
|
|
9526
9454
|
exports.DropdownButton = DropdownButton;
|
|
9527
|
-
exports.MediaSeriesCard = MediaSeriesCard;
|
|
@@ -7,7 +7,7 @@ var BlockContent = require('./BlockContent-9ebd251f.js');
|
|
|
7
7
|
var Col = require('react-bootstrap/Col');
|
|
8
8
|
var Form = require('react-bootstrap/Form');
|
|
9
9
|
var Button = require('react-bootstrap/Button');
|
|
10
|
-
var getSerializers = require('./index-
|
|
10
|
+
var getSerializers = require('./index-f95a3c0f.js');
|
|
11
11
|
var VideoSeriesListing = require('./VideoSeriesListing.js');
|
|
12
12
|
require('./_commonjsHelpers-06173234.js');
|
|
13
13
|
require('./core.get-iterator-method-5643aa10.js');
|
package/dist/cjs/View.js
CHANGED
|
@@ -17,7 +17,7 @@ var FormControl = require('react-bootstrap/FormControl');
|
|
|
17
17
|
var Button = require('react-bootstrap/Button');
|
|
18
18
|
var visibilitySensor = require('./visibility-sensor-eb2c5b69.js');
|
|
19
19
|
var SocialShare = require('./SocialShare.js');
|
|
20
|
-
var getSerializers = require('./index-
|
|
20
|
+
var getSerializers = require('./index-f95a3c0f.js');
|
|
21
21
|
var AdSlot = require('./AdSlot.js');
|
|
22
22
|
var SeriesSlider = require('./SeriesSlider-594b19eb.js');
|
|
23
23
|
var getTargeting = require('./getTargeting-ba942d9a.js');
|
|
@@ -1028,6 +1028,8 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1028
1028
|
downloadCitation = _props$downloadCitati === undefined ? false : _props$downloadCitati,
|
|
1029
1029
|
_props$useSegmentReco = props.useSegmentRecommendedArticles,
|
|
1030
1030
|
useSegmentRecommendedArticles = _props$useSegmentReco === undefined ? false : _props$useSegmentReco,
|
|
1031
|
+
showIssueNameOnly = props.showIssueNameOnly,
|
|
1032
|
+
showPageNumber = props.showPageNumber,
|
|
1031
1033
|
emailList = props.emailList,
|
|
1032
1034
|
articleRecs = props.articleRecs;
|
|
1033
1035
|
var sliderData = props.sliderData;
|
|
@@ -1038,9 +1040,9 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1038
1040
|
if (article && article.documentGroup && article.documentGroup.disableEpisodeNumber === true) {
|
|
1039
1041
|
disableEpisodeNumber = true;
|
|
1040
1042
|
}
|
|
1041
|
-
var logicforDisplayingEpisodeNumber = disableEpisodeNumber
|
|
1043
|
+
var logicforDisplayingEpisodeNumber = !disableEpisodeNumber;
|
|
1042
1044
|
var targeting = getTargeting.getTargeting(props);
|
|
1043
|
-
//remove slider data if toggled
|
|
1045
|
+
// remove slider data if toggled
|
|
1044
1046
|
if (article && article.documentGroup && article.documentGroup.hideSeriesSlider === true) {
|
|
1045
1047
|
sliderData = null;
|
|
1046
1048
|
}
|
|
@@ -1064,12 +1066,12 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1064
1066
|
}
|
|
1065
1067
|
}
|
|
1066
1068
|
|
|
1067
|
-
//if showSocialShare is not disabled for entire site, check article taxonomy, docgroup, authors for showSocialShare === false
|
|
1069
|
+
// if showSocialShare is not disabled for entire site, check article taxonomy, docgroup, authors for showSocialShare === false
|
|
1068
1070
|
if (showSocialShare) {
|
|
1069
1071
|
showSocialShare = getSocialShareDisableFlag(props.article);
|
|
1070
1072
|
}
|
|
1071
1073
|
|
|
1072
|
-
//If sponsored flag, disable contextual ads
|
|
1074
|
+
// If sponsored flag, disable contextual ads
|
|
1073
1075
|
if (sponsoredFlag) {
|
|
1074
1076
|
article.contextualVideoAD = false;
|
|
1075
1077
|
article.contextualAD = false;
|
|
@@ -1078,7 +1080,7 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1078
1080
|
if (article.disableRelatedContent) {
|
|
1079
1081
|
showRelatedArticles = false;
|
|
1080
1082
|
}
|
|
1081
|
-
//This was being done in ArticleQueue2 which wasnt effecting articles excluded from infinite scroll, moved inside article component
|
|
1083
|
+
// This was being done in ArticleQueue2 which wasnt effecting articles excluded from infinite scroll, moved inside article component
|
|
1082
1084
|
if (!sponsoredFlag && Ads.getVideoContextualAD) {
|
|
1083
1085
|
article.contextualVideoAD = Ads.getVideoContextualAD(getTargeting.getTargeting(props, 'in-context_video'));
|
|
1084
1086
|
}
|
|
@@ -1159,9 +1161,11 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1159
1161
|
|
|
1160
1162
|
var getAbstract = function getAbstract() {
|
|
1161
1163
|
return article.abstract && article.abstract.map(function (block) {
|
|
1162
|
-
if (block.children)
|
|
1163
|
-
|
|
1164
|
-
|
|
1164
|
+
if (block.children) {
|
|
1165
|
+
return block.children.map(function (child) {
|
|
1166
|
+
if (child._type === 'span') return child.text;
|
|
1167
|
+
});
|
|
1168
|
+
}
|
|
1165
1169
|
}).join(' ');
|
|
1166
1170
|
};
|
|
1167
1171
|
|
|
@@ -1179,52 +1183,52 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1179
1183
|
var fileContent = 'TY - JOUR\n';
|
|
1180
1184
|
if (issue) {
|
|
1181
1185
|
if (article.title) {
|
|
1182
|
-
fileContent += 'TI - ' + article.title + '\n'; //Title - TI
|
|
1183
|
-
fileContent += 'T1 - ' + article.title + '\n'; //Title - T1
|
|
1186
|
+
fileContent += 'TI - ' + article.title + '\n'; // Title - TI
|
|
1187
|
+
fileContent += 'T1 - ' + article.title + '\n'; // Title - T1
|
|
1184
1188
|
}
|
|
1185
1189
|
if (authorDetails && authorDetails.length) {
|
|
1186
1190
|
authorDetails.map(function (authorDetail, index) {
|
|
1187
1191
|
return fileContent += 'AU - ' + (authorDetail.firstName && authorDetail.lastName ? authorDetail.lastName + ', ' + authorDetail.firstName : '' + authorDetail.displayName) + '\n';
|
|
1188
|
-
} //Author
|
|
1192
|
+
} // Author
|
|
1189
1193
|
);
|
|
1190
1194
|
}
|
|
1191
1195
|
if (issue.publication && issue.publication.name) {
|
|
1192
|
-
fileContent += 'T2 - ' + issue.publication.name + '\n'; //Secondary Title - T2
|
|
1193
|
-
fileContent += 'JF - ' + issue.publication.name + '\n'; //Journal Name - JF
|
|
1196
|
+
fileContent += 'T2 - ' + issue.publication.name + '\n'; // Secondary Title - T2
|
|
1197
|
+
fileContent += 'JF - ' + issue.publication.name + '\n'; // Journal Name - JF
|
|
1194
1198
|
}
|
|
1195
1199
|
if (issue.name) {
|
|
1196
|
-
fileContent += 'T3 - ' + issue.name + '\n'; //Issue Name - T3
|
|
1200
|
+
fileContent += 'T3 - ' + issue.name + '\n'; // Issue Name - T3
|
|
1197
1201
|
}
|
|
1198
1202
|
if (issue.abbreviatedJournal) {
|
|
1199
|
-
fileContent += 'JO - ' + issue.abbreviatedJournal + '\n'; //Journal Name - JO
|
|
1203
|
+
fileContent += 'JO - ' + issue.abbreviatedJournal + '\n'; // Journal Name - JO
|
|
1200
1204
|
}
|
|
1201
|
-
if (article.abstract) fileContent += 'AB - ' + getAbstract() + '\n'; //Abstract - AB
|
|
1202
|
-
if (article.abstract) fileContent += 'N2 - ' + getAbstract() + '\n'; //Abstract - N2
|
|
1203
|
-
if (issue.issueNumber) fileContent += 'IS - ' + issue.issueNumber + '\n'; //Issue Number - IS
|
|
1204
|
-
fileContent += 'PB - MJH Life Sciences\n'; //Publisher - PB
|
|
1205
|
-
if (issue.year) fileContent += 'PY - ' + issue.year + '\n'; //Published Year - PY
|
|
1206
|
-
if (issue.volume) fileContent += 'VL - ' + issue.volume + '\n'; //Volume - VL
|
|
1207
|
-
if (issue.url) fileContent += 'L1 - ' + issue.url + '\n'; //Link to PDF - L1
|
|
1205
|
+
if (article.abstract) fileContent += 'AB - ' + getAbstract() + '\n'; // Abstract - AB
|
|
1206
|
+
if (article.abstract) fileContent += 'N2 - ' + getAbstract() + '\n'; // Abstract - N2
|
|
1207
|
+
if (issue.issueNumber) fileContent += 'IS - ' + issue.issueNumber + '\n'; // Issue Number - IS
|
|
1208
|
+
fileContent += 'PB - MJH Life Sciences\n'; // Publisher - PB
|
|
1209
|
+
if (issue.year) fileContent += 'PY - ' + issue.year + '\n'; // Published Year - PY
|
|
1210
|
+
if (issue.volume) fileContent += 'VL - ' + issue.volume + '\n'; // Volume - VL
|
|
1211
|
+
if (issue.url) fileContent += 'L1 - ' + issue.url + '\n'; // Link to PDF - L1
|
|
1208
1212
|
if (shareOptions && shareOptions.shareBaseUrl) {
|
|
1209
|
-
fileContent += 'L2 - ' + (shareOptions.shareBaseUrl + url) + '\n'; //Link to Full-text - L2
|
|
1210
|
-
fileContent += 'UR - ' + (shareOptions.shareBaseUrl + url) + '\n'; //Doc URL - UR
|
|
1213
|
+
fileContent += 'L2 - ' + (shareOptions.shareBaseUrl + url) + '\n'; // Link to Full-text - L2
|
|
1214
|
+
fileContent += 'UR - ' + (shareOptions.shareBaseUrl + url) + '\n'; // Doc URL - UR
|
|
1211
1215
|
}
|
|
1212
|
-
if (props.Website) fileContent += 'LK - https://' + props.Website.liveDomain + '\n'; //Website Link - LK
|
|
1216
|
+
if (props.Website) fileContent += 'LK - https://' + props.Website.liveDomain + '\n'; // Website Link - LK
|
|
1213
1217
|
if (issue.isbn_issn) {
|
|
1214
|
-
fileContent += 'SN - ' + issue.isbn_issn + '\n'; //ISSN/ISBN - TI
|
|
1218
|
+
fileContent += 'SN - ' + issue.isbn_issn + '\n'; // ISSN/ISBN - TI
|
|
1215
1219
|
}
|
|
1216
1220
|
if (pageNumber) {
|
|
1217
1221
|
if (pageNumber.includes('-')) {
|
|
1218
|
-
fileContent += 'SP - ' + pageNumber.split('-')[0] + '\n'; //Start Page - SP
|
|
1219
|
-
fileContent += 'EP - ' + pageNumber.split('-')[1] + '\n'; //End Page - EP
|
|
1222
|
+
fileContent += 'SP - ' + pageNumber.split('-')[0] + '\n'; // Start Page - SP
|
|
1223
|
+
fileContent += 'EP - ' + pageNumber.split('-')[1] + '\n'; // End Page - EP
|
|
1220
1224
|
} else {
|
|
1221
1225
|
fileContent += 'SP - ' + pageNumber + '\n';
|
|
1222
1226
|
}
|
|
1223
1227
|
}
|
|
1224
|
-
if (article.published) fileContent += 'Y1 - ' + moment.moment(published).format('DD-MMMM-YYYY') + '\n'; //Primary Date - Y1
|
|
1225
|
-
fileContent += 'Y2 - ' + moment.moment().format('DD-MMMM-YYYY') + '\n'; //Access Date - Y2
|
|
1228
|
+
if (article.published) fileContent += 'Y1 - ' + moment.moment(published).format('DD-MMMM-YYYY') + '\n'; // Primary Date - Y1
|
|
1229
|
+
fileContent += 'Y2 - ' + moment.moment().format('DD-MMMM-YYYY') + '\n'; // Access Date - Y2
|
|
1226
1230
|
}
|
|
1227
|
-
fileContent += 'ER -\n'; //End of Record
|
|
1231
|
+
fileContent += 'ER -\n'; // End of Record
|
|
1228
1232
|
return fileContent;
|
|
1229
1233
|
};
|
|
1230
1234
|
var getAuthorList = function getAuthorList() {
|
|
@@ -1787,7 +1791,7 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1787
1791
|
{ className: 'volume-issue' },
|
|
1788
1792
|
issue.publication && issue.publication.name && React__default['default'].createElement(
|
|
1789
1793
|
'span',
|
|
1790
|
-
{ className: 'mb-0' },
|
|
1794
|
+
{ className: 'mb-0-pub' },
|
|
1791
1795
|
React__default['default'].createElement(
|
|
1792
1796
|
'b',
|
|
1793
1797
|
null,
|
|
@@ -1796,17 +1800,22 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1796
1800
|
',',
|
|
1797
1801
|
' '
|
|
1798
1802
|
),
|
|
1799
|
-
issue.name && React__default['default'].createElement(
|
|
1803
|
+
issue.name && showIssueNameOnly === undefined ? React__default['default'].createElement(
|
|
1800
1804
|
'span',
|
|
1801
1805
|
{ className: 'mb-0' },
|
|
1802
1806
|
issue.name,
|
|
1803
1807
|
', '
|
|
1804
|
-
)
|
|
1808
|
+
) : issue.name && showIssueNameOnly === false ? React__default['default'].createElement(
|
|
1809
|
+
'span',
|
|
1810
|
+
{ className: 'mb-0' },
|
|
1811
|
+
issue.name,
|
|
1812
|
+
', '
|
|
1813
|
+
) : null,
|
|
1805
1814
|
issue.volume && React__default['default'].createElement(
|
|
1806
1815
|
'span',
|
|
1807
1816
|
null,
|
|
1808
1817
|
'Volume ' + issue.volume,
|
|
1809
|
-
','
|
|
1818
|
+
', '
|
|
1810
1819
|
),
|
|
1811
1820
|
issue.issueNumber && React__default['default'].createElement(
|
|
1812
1821
|
'span',
|
|
@@ -1814,11 +1823,15 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
|
|
|
1814
1823
|
' Issue ' + issue.issueNumber
|
|
1815
1824
|
)
|
|
1816
1825
|
),
|
|
1817
|
-
pageNumber && React__default['default'].createElement(
|
|
1826
|
+
pageNumber && showPageNumber ? React__default['default'].createElement(
|
|
1818
1827
|
'div',
|
|
1819
1828
|
{ className: 'article-pageNumber' },
|
|
1820
1829
|
'Pages: ' + pageNumber
|
|
1821
|
-
)
|
|
1830
|
+
) : pageNumber && showPageNumber === undefined ? React__default['default'].createElement(
|
|
1831
|
+
'div',
|
|
1832
|
+
{ className: 'article-pageNumber' },
|
|
1833
|
+
'Pages: ' + pageNumber
|
|
1834
|
+
) : null
|
|
1822
1835
|
),
|
|
1823
1836
|
React__default['default'].createElement(
|
|
1824
1837
|
'div',
|
package/dist/cjs/getQuery.js
CHANGED
|
@@ -13,7 +13,7 @@ var getQuery = function getQuery(type) {
|
|
|
13
13
|
case 'related':
|
|
14
14
|
return '*[\n _type == "article"\n && defined(title)\n && defined(url)\n && !(_id in path("drafts.**"))\n && is_visible == true\n && defined(published) \n && dateTime(published) <= dateTime(now())\n && passwordLock!=true\n && isHealthcareProfessional != 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 && !defined(body[].quizzes)\n && !defined(body[].slides)\n && !defined(body[].articles)\n ' + conditions + '\n ]| order(published desc)[' + (articleCount ? articleCount : '$index') + ']{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n abstract,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, firstName, lastName, url, profileImage, biography, showSocialShare },\n body[] {\n ...,\n asset->,\n images[]{\n ...,\n asset->\n },\n content[]{\n ...,\n asset->\n },\n videos[]{\n ...,\n thumbnail{\n _type,\n asset->\n }\n },\n response[]{\n ...,\n asset->\n },\n quizzes[]{\n ...,\n answer[]{\n ...,\n asset->\n },\n question[]{\n ...,\n asset->\n }\n },\n poster {\n _type,\n asset->\n },\n slides[]{\n ...,\n slideshowImage{\n ...,\n asset->\n }\n },\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n }\n },\n \'category\':contentCategory->{\n name,\n disableAds\n },\n \'content_placement\': taxonomyMapping[]-> {\n _id,\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier,\n disableAds,\n showSocialShare,\n pixelTrackingCode->\n },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL,\n hideSeriesSlider,\n pixelTrackingCode->\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL,\n hideSeriesSlider,\n pixelTrackingCode->\n },\n \'issue\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.issueGroup._ref][0] {\n name,\n \'path\': identifier.current,\n show_download_ris_button,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current,\n show_download_ris_button,\n },\n \'url\' : pdf.asset-> url,\n \'pdf\': pdf.asset->,\n isbn_issn,\n abbreviatedJournal,\n }\n }';
|
|
15
15
|
case 'article':
|
|
16
|
-
return '*[\n _type == "article"\n && !(_id in path("drafts.**"))\n && defined(title)\n && defined(url)\n && is_visible != false\n && url.current == $url\n ' + conditions + '\n ][0]{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n abstract,\n ...,\n passwordLock,\n password,\n issueGroup-> { _id, name, identifier, parent-> },\n "authorDetails": authorMapping[]->{ displayName, firstName, lastName, url, profileImage, biography, showSocialShare },\n body[] {\n ...,\n asset->,\n images[]{\n ...,\n asset->\n },\n content[]{\n ...,\n asset->\n },\n videos[]{\n ...,\n thumbnail{\n _type,\n asset->\n }\n },\n response[]{\n ...,\n asset->\n },\n quizzes[]{\n ...,\n answer[]{\n ...,\n asset->\n },\n question[]{\n ...,\n asset->\n }\n },\n poster {\n _type,\n asset->\n },\n slides[]{\n ...,\n slideshowImage{\n ...,\n asset->\n }\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 poster {\n _type,\n asset-> \n }\n },\n articles[]{\n ...,\n thumbnail{\n ...,\n asset-> \n },\n "authorDetails": authorMapping[]->{ displayName, firstName, lastName, url, profileImage, biography, showSocialShare },\n text[]{\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n },\n }\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n ...,\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier,\n showSocialShare,\n pixelTrackingCode->\n },\n documentGroup-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n isSeries,\n disableEpisodeNumber,\n excludeRelatedContents,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL,\n hideSeriesSlider,\n pixelTrackingCode->\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n isSeries,\n disableEpisodeNumber,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n excludeRelatedContents,\n \'path\': identifier.current,\n hideSeriesSlider,\n pixelTrackingCode->\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 year,\n \'issueNumber\': number,\n \'articleSource\': source,\n \'path\': identifier.current,\n show_download_ris_button,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current,\n show_download_ris_button,\n },\n \'url\' : pdf.asset-> url,\n \'pdf\': pdf.asset->,\n isbn_issn,\n abbreviatedJournal,\n }\n\n }';
|
|
16
|
+
return '*[\n _type == "article"\n && !(_id in path("drafts.**"))\n && defined(title)\n && defined(url)\n && is_visible != false\n && url.current == $url\n ' + conditions + '\n ][0]{\n ' + params + '\n title,\n published,\n summary,\n thumbnail,\n abstract,\n ...,\n passwordLock,\n password,\n issueGroup-> { _id, name, identifier, showIssueNameOnly, showPageNumber, parent-> },\n "authorDetails": authorMapping[]->{ displayName, firstName, lastName, url, profileImage, biography, showSocialShare },\n body[] {\n ...,\n asset->,\n images[]{\n ...,\n asset->\n },\n content[]{\n ...,\n asset->\n },\n videos[]{\n ...,\n thumbnail{\n _type,\n asset->\n }\n },\n response[]{\n ...,\n asset->\n },\n quizzes[]{\n ...,\n answer[]{\n ...,\n asset->\n },\n question[]{\n ...,\n asset->\n }\n },\n poster {\n _type,\n asset->\n },\n slides[]{\n ...,\n slideshowImage{\n ...,\n asset->\n }\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 poster {\n _type,\n asset-> \n }\n },\n articles[]{\n ...,\n thumbnail{\n ...,\n asset-> \n },\n "authorDetails": authorMapping[]->{ displayName, firstName, lastName, url, profileImage, biography, showSocialShare },\n text[]{\n ...,\n upload_doc {\n _type,\n asset->\n },\n uploadAudio {\n _type,\n asset->\n },\n }\n }\n },\n \'content_placement\': taxonomyMapping[]-> {\n ...,\n \'ancestor\': parent->parent->identifier,\n \'parent\': parent->identifier,\n \'name\': name,\n \'path\': identifier,\n showSocialShare,\n pixelTrackingCode->\n },\n documentGroup-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n isSeries,\n disableEpisodeNumber,\n excludeRelatedContents,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL,\n hideSeriesSlider,\n pixelTrackingCode->\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n isSeries,\n disableEpisodeNumber,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n excludeRelatedContents,\n \'path\': identifier.current,\n hideSeriesSlider,\n pixelTrackingCode->\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 year,\n \'issueNumber\': number,\n \'articleSource\': source,\n \'path\': identifier.current,\n show_download_ris_button,\n \'publication\' : *[_type == \'publication\' && !(_id in path("drafts.**")) && is_visible == true && _id == ^.parent._ref][0] {\n name,\n \'path\': identifier.current,\n show_download_ris_button,\n },\n \'url\' : pdf.asset-> url,\n \'pdf\': pdf.asset->,\n isbn_issn,\n abbreviatedJournal,\n }\n\n }';
|
|
17
17
|
case 'publication':
|
|
18
18
|
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 thumbnail{ ..., asset-> },\n taxonomyMapping[]->,\n pdf{asset->},\n } | order(year desc, month desc)\n }';
|
|
19
19
|
case 'issue':
|