@mjhls/mjh-framework 1.0.910-formstack-published-v1 → 1.0.911

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.
Files changed (72) hide show
  1. package/README.md +168 -168
  2. package/dist/cjs/AlgoliaSearch.js +15 -131
  3. package/dist/cjs/AuthWrapper.js +1 -1
  4. package/dist/cjs/ConferenceArticleCard.js +15 -15
  5. package/dist/cjs/ContentCardPaginated.js +2 -1
  6. package/dist/cjs/DeckContent.js +8 -8
  7. package/dist/cjs/DeckQueuePaginated.js +2 -1
  8. package/dist/cjs/EventsDeck.js +17 -17
  9. package/dist/cjs/GridContentPaginated.js +2 -1
  10. package/dist/cjs/HamMagazine.js +9 -9
  11. package/dist/cjs/IssueLanding.js +29 -29
  12. package/dist/cjs/KMTracker.js +15 -15
  13. package/dist/cjs/MasterDeck.js +8 -8
  14. package/dist/cjs/MasterDeckPaginated.js +10 -9
  15. package/dist/cjs/{MediaSeriesCard-68ae756e.js → MediaSeriesCard-d46317f0.js} +1 -1
  16. package/dist/cjs/MediaSeriesLanding.js +6 -6
  17. package/dist/cjs/MediaSeriesLandingPaginated.js +8 -7
  18. package/dist/cjs/NavMagazine.js +10 -10
  19. package/dist/cjs/NavNative.js +9 -9
  20. package/dist/cjs/Pagination-885dcfbd.js +90 -0
  21. package/dist/cjs/PartnerDetailListingPaginated.js +2 -1
  22. package/dist/cjs/PublicationLanding.js +26 -26
  23. package/dist/cjs/QueueDeckExpandedPaginated.js +2 -1
  24. package/dist/cjs/RelatedContent.js +28 -28
  25. package/dist/cjs/RelatedTopicsDropdown.js +10 -10
  26. package/dist/cjs/SeriesListingDeck.js +1 -1
  27. package/dist/cjs/{SeriesSlider-de93a303.js → SeriesSlider-ba0c5d1a.js} +4 -4
  28. package/dist/cjs/SideFooter.js +2 -2
  29. package/dist/cjs/VideoSeriesCard.js +1 -1
  30. package/dist/cjs/View.js +75 -26
  31. package/dist/cjs/YoutubeGroup.js +4 -4
  32. package/dist/cjs/getQuery.js +2 -2
  33. package/dist/cjs/{getTargeting-6d59cc5b.js → getTargeting-9d509319.js} +9 -9
  34. package/dist/cjs/getTargeting.js +1 -1
  35. package/dist/cjs/index.js +3 -2
  36. package/dist/esm/AlgoliaSearch.js +16 -132
  37. package/dist/esm/AuthWrapper.js +1 -1
  38. package/dist/esm/ConferenceArticleCard.js +15 -15
  39. package/dist/esm/ContentCardPaginated.js +2 -1
  40. package/dist/esm/DeckContent.js +8 -8
  41. package/dist/esm/DeckQueuePaginated.js +2 -1
  42. package/dist/esm/EventsDeck.js +17 -17
  43. package/dist/esm/GridContentPaginated.js +2 -1
  44. package/dist/esm/HamMagazine.js +9 -9
  45. package/dist/esm/IssueLanding.js +29 -29
  46. package/dist/esm/KMTracker.js +15 -15
  47. package/dist/esm/MasterDeck.js +8 -8
  48. package/dist/esm/MasterDeckPaginated.js +10 -9
  49. package/dist/esm/{MediaSeriesCard-ec988ce9.js → MediaSeriesCard-b1845b19.js} +1 -1
  50. package/dist/esm/MediaSeriesLanding.js +6 -6
  51. package/dist/esm/MediaSeriesLandingPaginated.js +8 -7
  52. package/dist/esm/NavMagazine.js +10 -10
  53. package/dist/esm/NavNative.js +9 -9
  54. package/dist/esm/Pagination-59436882.js +82 -0
  55. package/dist/esm/PartnerDetailListingPaginated.js +2 -1
  56. package/dist/esm/PublicationLanding.js +26 -26
  57. package/dist/esm/QueueDeckExpandedPaginated.js +2 -1
  58. package/dist/esm/RelatedContent.js +28 -28
  59. package/dist/esm/RelatedTopicsDropdown.js +10 -10
  60. package/dist/esm/SeriesListingDeck.js +1 -1
  61. package/dist/esm/{SeriesSlider-98ad6d97.js → SeriesSlider-45adb8dc.js} +4 -4
  62. package/dist/esm/SideFooter.js +2 -2
  63. package/dist/esm/VideoSeriesCard.js +1 -1
  64. package/dist/esm/View.js +74 -26
  65. package/dist/esm/YoutubeGroup.js +4 -4
  66. package/dist/esm/getQuery.js +2 -2
  67. package/dist/esm/{getTargeting-36031a00.js → getTargeting-4061f839.js} +9 -9
  68. package/dist/esm/getTargeting.js +1 -1
  69. package/dist/esm/index.js +3 -2
  70. package/package.json +114 -113
  71. package/dist/cjs/Pagination-42f92f7c.js +0 -97
  72. package/dist/esm/Pagination-484b86c5.js +0 -90
package/dist/esm/View.js CHANGED
@@ -17,8 +17,8 @@ import { V as VisibilitySensor } from './visibility-sensor-72fd8f8b.js';
17
17
  import SocialShare from './SocialShare.js';
18
18
  import { r as renderAuthor, g as getSerializers } from './index-490f4f21.js';
19
19
  import DFPAdSlot from './AdSlot.js';
20
- import { S as SeriesSlider } from './SeriesSlider-98ad6d97.js';
21
- import { g as getTargeting, a as getContentPlacementUrl } from './getTargeting-36031a00.js';
20
+ import { S as SeriesSlider } from './SeriesSlider-45adb8dc.js';
21
+ import { g as getTargeting, a as getContentPlacementUrl } from './getTargeting-4061f839.js';
22
22
  import getKeywords from './getKeywords.js';
23
23
  import urlFor from './urlFor.js';
24
24
  import { _ as _typeof } from './typeof-e9fc0c5d.js';
@@ -27,6 +27,7 @@ import { s as styleInject } from './style-inject.es-1f59c1d0.js';
27
27
  import './index-755f2cc2.js';
28
28
  import { DiscussionEmbed } from 'disqus-react';
29
29
  import Schema from './Schema.js';
30
+ import FileSaver from 'file-saver';
30
31
  import { _ as _Object$keys } from './keys-31dcdb31.js';
31
32
  import { I as InfiniteScroll } from './index.es-a6137319.js';
32
33
  import { l as lib_3 } from './index-f0fc23eb.js';
@@ -337,7 +338,7 @@ var ISI = function ISI(props) {
337
338
  );
338
339
  };
339
340
 
340
- 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_imgWrapper__5Jx_4 {\r\n display: none;\r\n }\r\n .RelatedArticles-module_mediaCard__3wQbn {\r\n width: 100%;\r\n margin-bottom: 0.5rem;\r\n padding: 0;\r\n }\r\n .RelatedArticles-module_cardTitle__3P-Ib {\r\n font-size: 0.75rem;\r\n margin-bottom: 0;\r\n }\r\n}\r\n";
341
+ var css = ".RelatedArticles-module_mediaContainer__10h9k {\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n margin: 0 -1rem;\n}\n.RelatedArticles-module_mediaCard__3wQbn {\n margin: 0 1rem 1rem;\n width: calc(33% - 1rem);\n display: column;\n flex-direction: row;\n margin-bottom: 0.75rem;\n padding-bottom: 0.75rem;\n border-bottom: none;\n}\n.RelatedArticles-module_mediaCard__3wQbn:last-child {\n border-bottom: none;\n}\n.RelatedArticles-module_cardTitle__3P-Ib {\n font-weight: bold;\n color: #252525;\n margin-bottom: 0.25rem;\n font-size: 15px;\n}\n.RelatedArticles-module_authorListing__1EFg4 span.RelatedArticles-module_text-muted__3b0zX {\n color: #000;\n font-weight: bold;\n}\n.RelatedArticles-module_cardDate__1wOR5 {\n color: var(--dark);\n display: block;\n background: #fff !important;\n margin-bottom: 0;\n}\n.RelatedArticles-module_imgWrapper__5Jx_4 {\n display: block;\n text-align: center;\n margin-bottom: 0.5rem;\n}\n.RelatedArticles-module_imgWrapper__5Jx_4 img {\n height: 135px;\n width: 100%;\n object-fit: cover;\n object-position: center;\n}\n@media screen and (max-width: 1064px) {\n}\n@media screen and (max-width: 968px) {\n .RelatedArticles-module_mediaContainer__10h9k {\n flex-wrap: wrap;\n }\n .RelatedArticles-module_imgWrapper__5Jx_4 {\n display: none;\n }\n .RelatedArticles-module_mediaCard__3wQbn {\n width: 100%;\n margin-bottom: 0.5rem;\n padding: 0;\n }\n .RelatedArticles-module_cardTitle__3P-Ib {\n font-size: 0.75rem;\n margin-bottom: 0;\n }\n}\n";
341
342
  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" };
342
343
  styleInject(css);
343
344
 
@@ -547,7 +548,9 @@ var Article = forwardRef(function (props, ref) {
547
548
  _props$refreshFlag = props.refreshFlag,
548
549
  refreshFlag = _props$refreshFlag === undefined ? false : _props$refreshFlag,
549
550
  disqusConfig = props.disqusConfig,
550
- showDisqus = props.showDisqus;
551
+ showDisqus = props.showDisqus,
552
+ _props$downloadCitati = props.downloadCitation,
553
+ downloadCitation = _props$downloadCitati === undefined ? false : _props$downloadCitati;
551
554
 
552
555
 
553
556
  var targeting = getTargeting(props);
@@ -656,6 +659,53 @@ var Article = forwardRef(function (props, ref) {
656
659
  }
657
660
  return null;
658
661
  };
662
+ var generateRIS = function generateRIS() {
663
+ var fileContent = 'TY - JOUR\n';
664
+ if (issue) {
665
+ if (article.title) {
666
+ fileContent += 'TI - ' + article.title + '\n'; //Title - TI
667
+ fileContent += 'T1 - ' + article.title + '\n'; //Title - T1
668
+ }
669
+ if (issue.publication && issue.publication.name) {
670
+ fileContent += 'T2 - ' + issue.publication.name + '\n'; //Secondary Title - T2
671
+ fileContent += 'JF - ' + issue.publication.name + '\n'; //Journal Name - JF
672
+ }
673
+ if (issue.abbreviatedJournal) {
674
+ fileContent += 'JO - ' + issue.abbreviatedJournal + '\n'; //Journal Name - JO
675
+ }
676
+ if (article.fieldAbstract) fileContent += 'N2 - ' + article.fieldAbstract + '\n'; //Abstract - N2
677
+ if (issue.issueNumber) fileContent += 'IS - ' + issue.issueNumber + '\n'; //Issue Number - IS
678
+ fileContent += 'PB - MJH Life Sciences\n'; //Publisher - PB
679
+ if (issue.year) fileContent += 'PY - ' + issue.year + '\n'; //Published Year - PY
680
+ if (issue.volume) fileContent += 'VL - ' + issue.volume + '\n'; //Volume - VL
681
+ if (issue.url) fileContent += 'L1 - ' + issue.url + '\n'; //Link to PDF - L1
682
+ if (shareOptions && shareOptions.shareBaseUrl) {
683
+ fileContent += 'L2 - ' + (shareOptions.shareBaseUrl + url) + '\n'; //Link to Full-text - L2
684
+ fileContent += 'UR - ' + (shareOptions.shareBaseUrl + url) + '\n'; //Doc URL - UR
685
+ }
686
+ if (props.Website) fileContent += 'LK - https://' + props.Website.liveDomain + '\n'; //Website Link - LK
687
+ if (issue.isbn_issn) {
688
+ fileContent += 'SN - ' + issue.isbn_issn + '\n'; //ISSN/ISBN - TI
689
+ }
690
+ if (pageNumber) {
691
+ if (pageNumber.includes('-')) {
692
+ fileContent += 'SP - ' + pageNumber.split('-')[0] + '\n'; //Start Page - SP
693
+ fileContent += 'EP - ' + pageNumber.split('-')[1] + '\n'; //End Page - EP
694
+ } else {
695
+ fileContent += 'SP - ' + pageNumber + '\n';
696
+ }
697
+ }
698
+ if (article.published) fileContent += 'Y1 - ' + moment(published).format('DD-MMMM-YYYY') + '\n'; //Primary Date - Y1
699
+ fileContent += 'Y2 - ' + moment().format('DD-MMMM-YYYY') + '\n'; //Access Date - Y2
700
+ }
701
+ fileContent += 'ER -\n'; //End of Record
702
+ return fileContent;
703
+ };
704
+ var downloadRIS = function downloadRIS() {
705
+ var fileContent = generateRIS();
706
+ var file = new File([fileContent], 'citation-' + url + '.ris', { type: 'application/x-research-info-systems;charset=utf-8' });
707
+ FileSaver.saveAs(file, 'citation-' + url + '.ris');
708
+ };
659
709
 
660
710
  var RelevantTopics = function RelevantTopics() {
661
711
  if (content_placement && content_placement.length > 0 || documentGroupMapping && documentGroupMapping.length > 0) {
@@ -970,19 +1020,6 @@ var Article = forwardRef(function (props, ref) {
970
1020
 
971
1021
  return false;
972
1022
  };
973
- var checkIfFormAssembly = function checkIfFormAssembly(article) {
974
- if (!article || !article.body) {
975
- return false;
976
- }
977
-
978
- for (var i = 0; i < article.body.length; i++) {
979
- var block = article.body[i];
980
- if (block._type === 'formassembly') {
981
- return true;
982
- }
983
- }
984
- return false;
985
- };
986
1023
  var checkIfMediaSeriesHasVideo = function checkIfMediaSeriesHasVideo(article) {
987
1024
  var seriesInfo = { hasVideo: false, videoIndex: 0 };
988
1025
  if (!article || !article.body) {
@@ -1012,7 +1049,7 @@ var Article = forwardRef(function (props, ref) {
1012
1049
  var shareTitle = article.title;
1013
1050
  var shareSummary = article.summary;
1014
1051
  var shareImage = thumbnail && thumbnail.asset ? urlFor({ client: props.client, source: thumbnail.asset }) : shareImageDefault;
1015
- var siteName = props.website && props.website.title ? props.website.title : '';
1052
+ var siteName = props.Website && props.Website.title ? props.Website.title : '';
1016
1053
  var shareKeywords = getKeywords(props.article).join(',');
1017
1054
 
1018
1055
  var meta = {
@@ -1045,7 +1082,7 @@ var Article = forwardRef(function (props, ref) {
1045
1082
  var episodeNumber = fetchCurrentEpisode(props.sliderData, props.article);
1046
1083
  var isMediaSeries = article.documentGroup && article.documentGroup.isSeries ? true : false;
1047
1084
  var seriesInfo = checkIfMediaSeriesHasVideo(article);
1048
- var isFormAssembly = checkIfFormAssembly(article);
1085
+
1049
1086
  return React__default.createElement(
1050
1087
  React__default.Fragment,
1051
1088
  null,
@@ -1099,7 +1136,7 @@ var Article = forwardRef(function (props, ref) {
1099
1136
  React__default.createElement(
1100
1137
  'div',
1101
1138
  { className: 'left-wrap' },
1102
- !isVideoSeries && !isFormAssembly && showPublished && React__default.createElement(
1139
+ !isVideoSeries && showPublished && React__default.createElement(
1103
1140
  'div',
1104
1141
  null,
1105
1142
  React__default.createElement(
@@ -1259,12 +1296,23 @@ var Article = forwardRef(function (props, ref) {
1259
1296
  )
1260
1297
  )
1261
1298
  ),
1262
- issue && issue.url && React__default.createElement(
1263
- 'a',
1264
- { rel: 'noopener', href: issue.url, target: '_blank', title: 'Download issue' },
1265
- React__default.createElement('img', { style: { margin: '1rem', maxHeight: '40px', maxWidth: '40px' }, src: '/download.png', alt: 'download issue' }),
1266
- 'Download Issue : ',
1267
- issue.name
1299
+ React__default.createElement(
1300
+ 'div',
1301
+ { className: 'downloads-container' },
1302
+ issue && downloadCitation && React__default.createElement(
1303
+ Button,
1304
+ { className: 'ris-download-button', onClick: function onClick() {
1305
+ return downloadRIS();
1306
+ } },
1307
+ 'Download RIS'
1308
+ ),
1309
+ issue && issue.url && React__default.createElement(
1310
+ 'a',
1311
+ { rel: 'noopener', href: issue.url, target: '_blank', title: 'Download issue' },
1312
+ React__default.createElement('img', { style: { margin: '1rem', maxHeight: '40px', maxWidth: '40px' }, src: '/download.png', alt: 'download issue' }),
1313
+ 'Download Issue : ',
1314
+ issue.name
1315
+ )
1268
1316
  )
1269
1317
  ),
1270
1318
  React__default.createElement('div', { className: 'clearfix', style: { minHeight: '1px' } }),
@@ -12,10 +12,10 @@ import 'react-dom';
12
12
  import 'prop-types';
13
13
  import './index-3f5c03b2.js';
14
14
 
15
- /*
16
- GROQ query -
17
- accepts an array of title, URL
18
- `https://img.youtube.com/vi/${getYouTubeId(vid.url)}/hqdefault.jpg`
15
+ /*
16
+ GROQ query -
17
+ accepts an array of title, URL
18
+ `https://img.youtube.com/vi/${getYouTubeId(vid.url)}/hqdefault.jpg`
19
19
  */
20
20
 
21
21
  var YoutubeGroup = function YoutubeGroup(props) {
@@ -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 && defined(published) \n && dateTime(published) <= dateTime(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, 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 },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\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 }';
11
+ 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 && 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 fieldAbstract,\n ...,\n passwordLock,\n password,\n "authorDetails": authorMapping[]->{ displayName, 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 },\n documentGroup-> {\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\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 isbn_issn,\n abbreviatedJournal,\n }\n }';
12
12
  case 'article':
13
- 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 ...,\n passwordLock,\n password,\n issueGroup-> { _id, name, identifier, parent-> },\n "authorDetails": authorMapping[]->{ displayName, 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, 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 },\n documentGroup-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n isSeries,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\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 }';
13
+ 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 fieldAbstract,\n ...,\n passwordLock,\n password,\n issueGroup-> { _id, name, identifier, parent-> },\n "authorDetails": authorMapping[]->{ displayName, 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, 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 },\n documentGroup-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n isSeries,\n showSocialShare,\n \'path\': identifier.current,\n adTargetingURL\n },\n documentGroupMapping[]-> {\n _id,\n name,\n thumbnail,\n parent->{...,parent->},\n isShow,\n showSocialShare,\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 year,\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 isbn_issn,\n abbreviatedJournal,\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 thumbnail{ ..., asset-> },\n taxonomyMapping[]->,\n pdf{asset->},\n } | order(year desc, month desc)\n }';
16
16
  case 'issue':
@@ -2,18 +2,18 @@ import { _ as _extends } from './extends-6d8e3924.js';
2
2
  import { _ as _toConsumableArray } from './toConsumableArray-f7074d7c.js';
3
3
 
4
4
  var getContentPlacementUrl = function getContentPlacementUrl(cp) {
5
- var cp_url = '';
6
- if (cp.ancestor && typeof cp.ancestor == 'string') {
7
- cp_url += (cp_url === '' ? '' : '/') + cp.ancestor;
8
- }
5
+ var cp_url = '';
6
+ if (cp.ancestor && typeof cp.ancestor == 'string') {
7
+ cp_url += (cp_url === '' ? '' : '/') + cp.ancestor;
8
+ }
9
9
 
10
- if (!cp.ancestor && cp.parent && typeof cp.parent == 'string') {
11
- cp_url += (cp_url === '' ? '' : '/') + cp.parent;
12
- }
10
+ if (!cp.ancestor && cp.parent && typeof cp.parent == 'string') {
11
+ cp_url += (cp_url === '' ? '' : '/') + cp.parent;
12
+ }
13
13
 
14
- cp_url += (cp_url === '' ? '' : '/') + (cp.adTargetingURL ? adTargetingURL : cp.path);
14
+ cp_url += (cp_url === '' ? '' : '/') + (cp.adTargetingURL ? adTargetingURL : cp.path);
15
15
 
16
- return cp_url;
16
+ return cp_url;
17
17
  };
18
18
 
19
19
  var getTargeting = function getTargeting(props) {
@@ -1,6 +1,6 @@
1
1
  import './extends-6d8e3924.js';
2
2
  import './toConsumableArray-f7074d7c.js';
3
- export { g as default } from './getTargeting-36031a00.js';
3
+ export { g as default } from './getTargeting-4061f839.js';
4
4
  import './_commonjsHelpers-0c4b6f40.js';
5
5
  import './core.get-iterator-method-ea258bb1.js';
6
6
  import './_object-pie-133f504a.js';
package/dist/esm/index.js CHANGED
@@ -94,7 +94,7 @@ export { default as VideoSeriesLandingPage } from './VideoSeriesLandingPage.js';
94
94
  export { default as ArticleProgramLandingPage } from './ArticleProgramLandingPage.js';
95
95
  export { default as ArticleSeriesLandingPage } from './ArticleSeriesLandingPage.js';
96
96
  export { default as Schema } from './Schema.js';
97
- export { g as getTargeting } from './getTargeting-36031a00.js';
97
+ export { g as getTargeting } from './getTargeting-4061f839.js';
98
98
  export { default as getKeywords } from './getKeywords.js';
99
99
  export { default as getQuery } from './getQuery.js';
100
100
  import './toConsumableArray-f7074d7c.js';
@@ -189,9 +189,10 @@ import 'swr';
189
189
  import 'passport-local';
190
190
  import 'mysql';
191
191
  import './md5-4e42248e.js';
192
- import './SeriesSlider-98ad6d97.js';
192
+ import './SeriesSlider-45adb8dc.js';
193
193
  import './style-inject.es-1f59c1d0.js';
194
194
  import 'disqus-react';
195
+ import 'file-saver';
195
196
  import 'react-twitter-embed';
196
197
  import './ImageSlider-f84174cb.js';
197
198
  import './defineProperty-23a8f8cd.js';
package/package.json CHANGED
@@ -1,113 +1,114 @@
1
- {
2
- "name": "@mjhls/mjh-framework",
3
- "version": "1.0.910-formstack-published-v1",
4
- "description": "Foundation Framework",
5
- "author": "mjh-framework",
6
- "license": "MIT",
7
- "repository": {
8
- "type": "git",
9
- "url": "https://github.com/MJHLS/mjh-framework.git"
10
- },
11
- "main": "dist/cjs/index.js",
12
- "module": "dist/esm/index.js",
13
- "engines": {
14
- "node": ">=8",
15
- "npm": ">=5"
16
- },
17
- "scripts": {
18
- "clean": "rimraf dist",
19
- "test": "cross-env CI=1 react-scripts test --env=jsdom",
20
- "test:watch": "react-scripts test --env=jsdom",
21
- "build": "npm run clean && rollup -c",
22
- "start": "npm run clean && rollup -c -w",
23
- "prepare": "yarn run build",
24
- "predeploy": "cd example && yarn install && yarn run build",
25
- "deploy": "gh-pages -d example/build"
26
- },
27
- "peerDependencies": {
28
- "disqus-react": "^1.0.11",
29
- "next": "^9.0.0",
30
- "prop-types": "^15.5.4",
31
- "react": "^15.0.0 || ^16.0.0",
32
- "react-bootstrap": "^1.0.0-beta.14",
33
- "react-dom": "^15.0.0 || ^16.0.0",
34
- "react-share": "^4.0.1"
35
- },
36
- "devDependencies": {
37
- "@brightcove/react-player-loader": "^1.4.0",
38
- "@rollup/plugin-json": "^4.0.3",
39
- "@sanity/block-content-to-react": "^2.0.7",
40
- "@sanity/image-url": "^0.140.15",
41
- "@svgr/rollup": "2.4.1",
42
- "babel-core": "^6.26.3",
43
- "babel-eslint": "^8.2.5",
44
- "babel-plugin-external-helpers": "^6.22.0",
45
- "babel-plugin-transform-runtime": "^6.23.0",
46
- "babel-preset-env": "^1.7.0",
47
- "babel-preset-react": "^6.24.1",
48
- "babel-preset-stage-0": "^6.24.1",
49
- "cross-env": "^5.1.4",
50
- "eslint": "^5.0.1",
51
- "eslint-config-standard": "^11.0.0",
52
- "eslint-config-standard-react": "^6.0.0",
53
- "eslint-plugin-import": "^2.13.0",
54
- "eslint-plugin-node": "^7.0.1",
55
- "eslint-plugin-promise": "^4.0.0",
56
- "eslint-plugin-react": "^7.10.0",
57
- "eslint-plugin-react-hooks": "^2.3.0",
58
- "eslint-plugin-standard": "^3.1.0",
59
- "get-youtube-id": "^1.0.1",
60
- "gh-pages": "^1.2.0",
61
- "lodash": "^4.17.15",
62
- "md5": "^2.2.1",
63
- "moment": "^2.26.0",
64
- "moment-timezone": "^0.5.31",
65
- "next": "^9.2.0",
66
- "react": "^16.12.0",
67
- "react-bootstrap": "1.4.0",
68
- "react-device-detect": "^1.11.14",
69
- "react-dfp": "^0.19.0",
70
- "react-dom": "^16.12.0",
71
- "react-icons": "^3.8.0",
72
- "react-infinite-scroll-component": "^5.0.4",
73
- "react-lazyload": "^2.6.5",
74
- "react-paginate": "^7.1.3",
75
- "react-player": "^1.15.2",
76
- "react-scripts": "^1.1.4",
77
- "react-share": "^4.0.1",
78
- "react-social-icons": "^4.1.0",
79
- "react-visibility-sensor": "^5.1.1",
80
- "react-youtube": "^7.9.0",
81
- "rimraf": "^3.0.2",
82
- "rollup": "^2.7.3",
83
- "rollup-plugin-babel": "3.0.7",
84
- "rollup-plugin-commonjs": "9.3.4",
85
- "rollup-plugin-node-builtins": "2.1.2",
86
- "rollup-plugin-node-resolve": "3.4.0",
87
- "rollup-plugin-postcss": "1.6.3",
88
- "rollup-plugin-url": "1.4.0"
89
- },
90
- "files": [
91
- "dist"
92
- ],
93
- "dependencies": {
94
- "babel-polyfill": "^6.26.0",
95
- "cookie": "^0.4.1",
96
- "disqus-react": "^1.0.11",
97
- "faunadb": "^4.2.0",
98
- "js-cookie": "^2.2.1",
99
- "next-auth": "^3.2.0",
100
- "next-cookies": "^2.0.3",
101
- "nookies": "^2.4.0",
102
- "react-cookies": "^0.1.1",
103
- "react-facebook": "^8.1.4",
104
- "react-instantsearch-dom": "^6.12.0",
105
- "react-script-tag": "^1.1.2",
106
- "rollup-plugin-peer-deps-external": "^2.2.4",
107
- "shortid": "^2.2.15",
108
- "smoothscroll-polyfill": "^0.4.4",
109
- "striptags": "^3.1.1",
110
- "superagent": "^5.2.2",
111
- "yarn": "^1.22.11"
112
- }
113
- }
1
+ {
2
+ "name": "@mjhls/mjh-framework",
3
+ "version": "1.0.911",
4
+ "description": "Foundation Framework",
5
+ "author": "mjh-framework",
6
+ "license": "MIT",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "https://github.com/MJHLS/mjh-framework.git"
10
+ },
11
+ "main": "dist/cjs/index.js",
12
+ "module": "dist/esm/index.js",
13
+ "engines": {
14
+ "node": ">=8",
15
+ "npm": ">=5"
16
+ },
17
+ "scripts": {
18
+ "clean": "rimraf dist",
19
+ "test": "cross-env CI=1 react-scripts test --env=jsdom",
20
+ "test:watch": "react-scripts test --env=jsdom",
21
+ "build": "npm run clean && rollup -c",
22
+ "start": "npm run clean && rollup -c -w",
23
+ "prepare": "yarn run build",
24
+ "predeploy": "cd example && yarn install && yarn run build",
25
+ "deploy": "gh-pages -d example/build"
26
+ },
27
+ "peerDependencies": {
28
+ "disqus-react": "^1.0.11",
29
+ "next": "^9.0.0",
30
+ "prop-types": "^15.5.4",
31
+ "react": "^15.0.0 || ^16.0.0",
32
+ "react-bootstrap": "^1.0.0-beta.14",
33
+ "react-dom": "^15.0.0 || ^16.0.0",
34
+ "react-share": "^4.0.1"
35
+ },
36
+ "devDependencies": {
37
+ "@brightcove/react-player-loader": "^1.4.0",
38
+ "@rollup/plugin-json": "^4.0.3",
39
+ "@sanity/block-content-to-react": "^2.0.7",
40
+ "@sanity/image-url": "^0.140.15",
41
+ "@svgr/rollup": "2.4.1",
42
+ "babel-core": "^6.26.3",
43
+ "babel-eslint": "^8.2.5",
44
+ "babel-plugin-external-helpers": "^6.22.0",
45
+ "babel-plugin-transform-runtime": "^6.23.0",
46
+ "babel-preset-env": "^1.7.0",
47
+ "babel-preset-react": "^6.24.1",
48
+ "babel-preset-stage-0": "^6.24.1",
49
+ "cross-env": "^5.1.4",
50
+ "eslint": "^5.0.1",
51
+ "eslint-config-standard": "^11.0.0",
52
+ "eslint-config-standard-react": "^6.0.0",
53
+ "eslint-plugin-import": "^2.13.0",
54
+ "eslint-plugin-node": "^7.0.1",
55
+ "eslint-plugin-promise": "^4.0.0",
56
+ "eslint-plugin-react": "^7.10.0",
57
+ "eslint-plugin-react-hooks": "^2.3.0",
58
+ "eslint-plugin-standard": "^3.1.0",
59
+ "file-saver": "^2.0.5",
60
+ "get-youtube-id": "^1.0.1",
61
+ "gh-pages": "^1.2.0",
62
+ "lodash": "^4.17.15",
63
+ "md5": "^2.2.1",
64
+ "moment": "^2.26.0",
65
+ "moment-timezone": "^0.5.31",
66
+ "next": "^9.2.0",
67
+ "react": "^16.12.0",
68
+ "react-bootstrap": "1.4.0",
69
+ "react-device-detect": "^1.11.14",
70
+ "react-dfp": "^0.19.0",
71
+ "react-dom": "^16.12.0",
72
+ "react-icons": "^3.8.0",
73
+ "react-infinite-scroll-component": "^5.0.4",
74
+ "react-lazyload": "^2.6.5",
75
+ "react-paginate": "^7.1.3",
76
+ "react-player": "^1.15.2",
77
+ "react-scripts": "^1.1.4",
78
+ "react-share": "^4.0.1",
79
+ "react-social-icons": "^4.1.0",
80
+ "react-visibility-sensor": "^5.1.1",
81
+ "react-youtube": "^7.9.0",
82
+ "rimraf": "^3.0.2",
83
+ "rollup": "^2.7.3",
84
+ "rollup-plugin-babel": "3.0.7",
85
+ "rollup-plugin-commonjs": "9.3.4",
86
+ "rollup-plugin-node-builtins": "2.1.2",
87
+ "rollup-plugin-node-resolve": "3.4.0",
88
+ "rollup-plugin-postcss": "1.6.3",
89
+ "rollup-plugin-url": "1.4.0"
90
+ },
91
+ "files": [
92
+ "dist"
93
+ ],
94
+ "dependencies": {
95
+ "babel-polyfill": "^6.26.0",
96
+ "cookie": "^0.4.1",
97
+ "disqus-react": "^1.0.11",
98
+ "faunadb": "^4.2.0",
99
+ "js-cookie": "^2.2.1",
100
+ "next-auth": "^3.2.0",
101
+ "next-cookies": "^2.0.3",
102
+ "nookies": "^2.4.0",
103
+ "react-cookies": "^0.1.1",
104
+ "react-facebook": "^8.1.4",
105
+ "react-instantsearch-dom": "^6.12.0",
106
+ "react-script-tag": "^1.1.2",
107
+ "rollup-plugin-peer-deps-external": "^2.2.4",
108
+ "shortid": "^2.2.15",
109
+ "smoothscroll-polyfill": "^0.4.4",
110
+ "striptags": "^3.1.1",
111
+ "superagent": "^5.2.2",
112
+ "yarn": "^1.22.11"
113
+ }
114
+ }