@mjhls/mjh-framework 1.0.971-nofollow-v5 → 1.0.972-masterdeck-pagination-v1

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 (44) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/ArticleProgramLandingPage.js +1 -1
  3. package/dist/cjs/ContentCardPaginated.js +1 -1
  4. package/dist/cjs/DeckQueuePaginated.js +1 -1
  5. package/dist/cjs/ExternalResources.js +1 -1
  6. package/dist/cjs/GridContentPaginated.js +1 -1
  7. package/dist/cjs/HorizontalArticleListing.js +1 -1
  8. package/dist/cjs/IssueLanding.js +1 -1
  9. package/dist/cjs/MasterDeckPaginated.js +1 -1
  10. package/dist/cjs/{MediaSeriesCard-772340e7.js → MediaSeriesCard-b81ba298.js} +1 -1
  11. package/dist/cjs/MediaSeriesLanding.js +2 -2
  12. package/dist/cjs/MediaSeriesLandingPaginated.js +3 -3
  13. package/dist/cjs/{Pagination-30bb1ca1.js → Pagination-2a3d0103.js} +1 -1
  14. package/dist/cjs/PartnerDetailListing.js +1 -1
  15. package/dist/cjs/PartnerDetailListingPaginated.js +2 -2
  16. package/dist/cjs/QueueDeckExpandedPaginated.js +1 -1
  17. package/dist/cjs/TaxonomyDescription.js +13 -9
  18. package/dist/cjs/VideoProgramLandingPage.js +1 -1
  19. package/dist/cjs/View.js +2 -1
  20. package/dist/cjs/getSerializers.js +5 -5
  21. package/dist/cjs/{index-d394c167.js → index-eb1c583d.js} +29 -72
  22. package/dist/cjs/index.js +1 -1
  23. package/dist/esm/ArticleProgramLandingPage.js +1 -1
  24. package/dist/esm/ContentCardPaginated.js +1 -1
  25. package/dist/esm/DeckQueuePaginated.js +1 -1
  26. package/dist/esm/ExternalResources.js +1 -1
  27. package/dist/esm/GridContentPaginated.js +1 -1
  28. package/dist/esm/HorizontalArticleListing.js +1 -1
  29. package/dist/esm/IssueLanding.js +1 -1
  30. package/dist/esm/MasterDeckPaginated.js +1 -1
  31. package/dist/esm/{MediaSeriesCard-2c3369cb.js → MediaSeriesCard-e3b52a0f.js} +1 -1
  32. package/dist/esm/MediaSeriesLanding.js +2 -2
  33. package/dist/esm/MediaSeriesLandingPaginated.js +3 -3
  34. package/dist/esm/{Pagination-194dd03f.js → Pagination-dc30727b.js} +1 -1
  35. package/dist/esm/PartnerDetailListing.js +1 -1
  36. package/dist/esm/PartnerDetailListingPaginated.js +2 -2
  37. package/dist/esm/QueueDeckExpandedPaginated.js +1 -1
  38. package/dist/esm/TaxonomyDescription.js +13 -9
  39. package/dist/esm/VideoProgramLandingPage.js +1 -1
  40. package/dist/esm/View.js +2 -1
  41. package/dist/esm/getSerializers.js +5 -5
  42. package/dist/esm/{index-c94edea2.js → index-264bbd3c.js} +29 -72
  43. package/dist/esm/index.js +1 -1
  44. package/package.json +1 -1
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # mjh-framework v. 1.0.971
1
+ # mjh-framework v. 1.0.972
2
2
 
3
3
  [![NPM](https://img.shields.io/npm/v/mjh-framework.svg)](https://www.npmjs.com/package/mjh-framework) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)
4
4
 
@@ -5,7 +5,7 @@ var slicedToArray = require('./slicedToArray-067dd3bc.js');
5
5
  var _extends = require('./extends-7c86182f.js');
6
6
  var React = require('react');
7
7
  var BlockContent = require('./BlockContent-9ebd251f.js');
8
- var getSerializers = require('./index-d394c167.js');
8
+ var getSerializers = require('./index-eb1c583d.js');
9
9
  var ArticleSeriesListing = require('./ArticleSeriesListing.js');
10
10
  require('./_commonjsHelpers-06173234.js');
11
11
  require('./core.get-iterator-method-5643aa10.js');
@@ -17,7 +17,7 @@ var index$1 = require('./index-eadd5035.js');
17
17
  var main = require('./main-f1c77adb.js');
18
18
  var entities = require('./entities-df1aed86.js');
19
19
  var ADInfeed = require('./ADInfeed-81006615.js');
20
- var Pagination = require('./Pagination-30bb1ca1.js');
20
+ var Pagination = require('./Pagination-2a3d0103.js');
21
21
  var Spinner = require('react-bootstrap/Spinner');
22
22
  require('./_commonjsHelpers-06173234.js');
23
23
  require('./core.get-iterator-method-5643aa10.js');
@@ -18,7 +18,7 @@ var get = require('./get-5839e5b5.js');
18
18
  var main = require('./main-f1c77adb.js');
19
19
  var urlFor = require('./urlFor.js');
20
20
  var entities = require('./entities-df1aed86.js');
21
- var Pagination = require('./Pagination-30bb1ca1.js');
21
+ var Pagination = require('./Pagination-2a3d0103.js');
22
22
  require('./_commonjsHelpers-06173234.js');
23
23
  require('./core.get-iterator-method-5643aa10.js');
24
24
  require('./web.dom.iterable-d98303e0.js');
@@ -4,7 +4,7 @@ var _extends = require('./extends-7c86182f.js');
4
4
  var slicedToArray = require('./slicedToArray-067dd3bc.js');
5
5
  var React = require('react');
6
6
  var BlockContent = require('./BlockContent-9ebd251f.js');
7
- var getSerializers = require('./index-d394c167.js');
7
+ var getSerializers = require('./index-eb1c583d.js');
8
8
  var index = require('./index-f86bb269.js');
9
9
  var Router = require('next/router');
10
10
  var Button = require('react-bootstrap/Button');
@@ -24,7 +24,7 @@ var urlFor = require('./urlFor.js');
24
24
  var main = require('./main-f1c77adb.js');
25
25
  var AuthorComponent = require('./AuthorComponent-39b37d84.js');
26
26
  var PublicationFeature = require('./PublicationFeature-5ccf9b13.js');
27
- var Pagination = require('./Pagination-30bb1ca1.js');
27
+ var Pagination = require('./Pagination-2a3d0103.js');
28
28
  var Spinner = require('react-bootstrap/Spinner');
29
29
  require('./_commonjsHelpers-06173234.js');
30
30
  require('./core.get-iterator-method-5643aa10.js');
@@ -5,7 +5,7 @@ var React = require('react');
5
5
  var ArticleCarousel = require('./ArticleCarousel.js');
6
6
  var index_esm = require('./index.esm-d81454e7.js');
7
7
  var BlockContent = require('./BlockContent-9ebd251f.js');
8
- var getSerializers = require('./index-d394c167.js');
8
+ var getSerializers = require('./index-eb1c583d.js');
9
9
  require('./_commonjsHelpers-06173234.js');
10
10
  require('./core.get-iterator-method-5643aa10.js');
11
11
  require('./_object-pie-083f2dd6.js');
@@ -5,7 +5,7 @@ var React = require('react');
5
5
  var QueueDeckExpanded = require('./QueueDeckExpanded.js');
6
6
  var Breadcrumbs = require('./Breadcrumbs.js');
7
7
  var BlockContent = require('./BlockContent-9ebd251f.js');
8
- var getSerializers = require('./index-d394c167.js');
8
+ var getSerializers = require('./index-eb1c583d.js');
9
9
  require('./_commonjsHelpers-06173234.js');
10
10
  require('./core.get-iterator-method-5643aa10.js');
11
11
  require('./_object-pie-083f2dd6.js');
@@ -14,7 +14,7 @@ var lodash = require('./lodash-f0783643.js');
14
14
  var main = require('./main-f1c77adb.js');
15
15
  var ADlgInfeed = require('./ADlgInfeed-0db07099.js');
16
16
  var ADInfeed = require('./ADInfeed-81006615.js');
17
- var Pagination = require('./Pagination-30bb1ca1.js');
17
+ var Pagination = require('./Pagination-2a3d0103.js');
18
18
  require('./_commonjsHelpers-06173234.js');
19
19
  require('./core.get-iterator-method-5643aa10.js');
20
20
  require('./web.dom.iterable-d98303e0.js');
@@ -11,7 +11,7 @@ var urlFor = require('./urlFor.js');
11
11
  var moment = require('./moment-aca40de1.js');
12
12
  var styleInject_es = require('./style-inject.es-dcee06b6.js');
13
13
  var BlockContent = require('./BlockContent-9ebd251f.js');
14
- var getSerializers = require('./index-d394c167.js');
14
+ var getSerializers = require('./index-eb1c583d.js');
15
15
 
16
16
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
17
17
 
@@ -5,13 +5,13 @@ var _typeof = require('./typeof-567e31ff.js');
5
5
  var _extends = require('./extends-7c86182f.js');
6
6
  var slicedToArray = require('./slicedToArray-067dd3bc.js');
7
7
  var React = require('react');
8
- var MediaSeriesCard = require('./MediaSeriesCard-772340e7.js');
8
+ var MediaSeriesCard = require('./MediaSeriesCard-b81ba298.js');
9
9
  require('./index-50be6759.js');
10
10
  require('react-dom');
11
11
  var Link = require('next/link');
12
12
  var MasterDeck = require('./MasterDeck.js');
13
13
  var BlockContent = require('./BlockContent-9ebd251f.js');
14
- var getSerializers = require('./index-d394c167.js');
14
+ var getSerializers = require('./index-eb1c583d.js');
15
15
  require('./_commonjsHelpers-06173234.js');
16
16
  require('./core.get-iterator-method-5643aa10.js');
17
17
  require('./web.dom.iterable-d98303e0.js');
@@ -5,13 +5,13 @@ var _typeof = require('./typeof-567e31ff.js');
5
5
  var _extends = require('./extends-7c86182f.js');
6
6
  var slicedToArray = require('./slicedToArray-067dd3bc.js');
7
7
  var React = require('react');
8
- var MediaSeriesCard = require('./MediaSeriesCard-772340e7.js');
8
+ var MediaSeriesCard = require('./MediaSeriesCard-b81ba298.js');
9
9
  require('./index-50be6759.js');
10
10
  require('react-dom');
11
11
  var Link = require('next/link');
12
12
  var BlockContent = require('./BlockContent-9ebd251f.js');
13
13
  var MasterDeckPaginated = require('./MasterDeckPaginated.js');
14
- var getSerializers = require('./index-d394c167.js');
14
+ var getSerializers = require('./index-eb1c583d.js');
15
15
  require('./_commonjsHelpers-06173234.js');
16
16
  require('./core.get-iterator-method-5643aa10.js');
17
17
  require('./web.dom.iterable-d98303e0.js');
@@ -46,7 +46,7 @@ require('./toNumber-5e1fac58.js');
46
46
  require('./Beam.js');
47
47
  require('./Segment.js');
48
48
  require('./ADInfeed-81006615.js');
49
- require('./Pagination-30bb1ca1.js');
49
+ require('./Pagination-2a3d0103.js');
50
50
  require('react-bootstrap/Button');
51
51
  require('./index.esm-d51c9ac6.js');
52
52
  require('./iconBase-be4097c0.js');
@@ -45,7 +45,7 @@ var Pagination = function Pagination(props) {
45
45
  _onPageChange(currentPage + 1);
46
46
  },
47
47
  disabled: currentPage === pageCount,
48
- href: '?page=' + (currentPage + 1) },
48
+ href: currentPage === pageCount ? '' : '?page=' + (currentPage + 1) },
49
49
  'NEXT PAGE',
50
50
  React__default['default'].createElement(index_esm.FaArrowRight, { className: 'fa-arrow-right' })
51
51
  )
@@ -13,7 +13,7 @@ var QueueDeckExpanded = require('./QueueDeckExpanded.js');
13
13
  var Breadcrumbs = require('./Breadcrumbs.js');
14
14
  var Feature = require('./Feature.js');
15
15
  var urlFor = require('./urlFor.js');
16
- var getSerializers = require('./index-d394c167.js');
16
+ var getSerializers = require('./index-eb1c583d.js');
17
17
  var BlockContent = require('./BlockContent-9ebd251f.js');
18
18
  require('./_commonjsHelpers-06173234.js');
19
19
  require('./core.get-iterator-method-5643aa10.js');
@@ -13,7 +13,7 @@ var QueueDeckExpandedPaginated = require('./QueueDeckExpandedPaginated.js');
13
13
  var Breadcrumbs = require('./Breadcrumbs.js');
14
14
  var Feature = require('./Feature.js');
15
15
  var urlFor = require('./urlFor.js');
16
- var getSerializers = require('./index-d394c167.js');
16
+ var getSerializers = require('./index-eb1c583d.js');
17
17
  var BlockContent = require('./BlockContent-9ebd251f.js');
18
18
  require('./_commonjsHelpers-06173234.js');
19
19
  require('./core.get-iterator-method-5643aa10.js');
@@ -46,7 +46,7 @@ require('./AuthorComponent-39b37d84.js');
46
46
  require('./ADlgInfeed-0db07099.js');
47
47
  require('./getContentCategory-f38a4c00.js');
48
48
  require('./timeDifferenceCalc.js');
49
- require('./Pagination-30bb1ca1.js');
49
+ require('./Pagination-2a3d0103.js');
50
50
  require('react-bootstrap/Button');
51
51
  require('./index.esm-d51c9ac6.js');
52
52
  require('./iconBase-be4097c0.js');
@@ -19,7 +19,7 @@ var ADlgInfeed = require('./ADlgInfeed-0db07099.js');
19
19
  var getContentCategory = require('./getContentCategory-f38a4c00.js');
20
20
  var timeDifferenceCalc = require('./timeDifferenceCalc.js');
21
21
  var urlFor = require('./urlFor.js');
22
- var Pagination = require('./Pagination-30bb1ca1.js');
22
+ var Pagination = require('./Pagination-2a3d0103.js');
23
23
  require('./_commonjsHelpers-06173234.js');
24
24
  require('./core.get-iterator-method-5643aa10.js');
25
25
  require('./web.dom.iterable-d98303e0.js');
@@ -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-d394c167.js');
10
+ var getSerializers = require('./index-eb1c583d.js');
11
11
  require('./_commonjsHelpers-06173234.js');
12
12
  require('./core.get-iterator-method-5643aa10.js');
13
13
  require('./_object-pie-083f2dd6.js');
@@ -162,7 +162,7 @@ TaxonomyDescription.getDescription = function () {
162
162
  var _ref3 = asyncToGenerator._asyncToGenerator( /*#__PURE__*/asyncToGenerator.regenerator.mark(function _callee2() {
163
163
  var url = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
164
164
  var client = arguments[1];
165
- var query, summary;
165
+ var query, summary, taxonomyData;
166
166
  return asyncToGenerator.regenerator.wrap(function _callee2$(_context2) {
167
167
  while (1) {
168
168
  switch (_context2.prev = _context2.next) {
@@ -174,25 +174,29 @@ TaxonomyDescription.getDescription = function () {
174
174
  return client.fetch(query);
175
175
 
176
176
  case 5:
177
- summary = _context2.sent;
178
- _context2.next = 11;
177
+ taxonomyData = _context2.sent;
178
+
179
+ if (taxonomyData.summary) {
180
+ summary = taxonomyData.summary;
181
+ }
182
+ _context2.next = 12;
179
183
  break;
180
184
 
181
- case 8:
182
- _context2.prev = 8;
185
+ case 9:
186
+ _context2.prev = 9;
183
187
  _context2.t0 = _context2['catch'](2);
184
188
 
185
189
  console.error(_context2.t0);
186
190
 
187
- case 11:
191
+ case 12:
188
192
  return _context2.abrupt('return', summary);
189
193
 
190
- case 12:
194
+ case 13:
191
195
  case 'end':
192
196
  return _context2.stop();
193
197
  }
194
198
  }
195
- }, _callee2, _this, [[2, 8]]);
199
+ }, _callee2, _this, [[2, 9]]);
196
200
  }));
197
201
 
198
202
  return function () {
@@ -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-d394c167.js');
10
+ var getSerializers = require('./index-eb1c583d.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-d394c167.js');
20
+ var getSerializers = require('./index-eb1c583d.js');
21
21
  var AdSlot = require('./AdSlot.js');
22
22
  var SeriesSlider = require('./SeriesSlider-74546d19.js');
23
23
  var getTargeting = require('./getTargeting-dab97fe1.js');
@@ -966,6 +966,7 @@ var Article = React__default['default'].memo(React.forwardRef(function (props, r
966
966
  useSegmentRecommendedArticles = _props$useSegmentReco === undefined ? false : _props$useSegmentReco;
967
967
  var sliderData = props.sliderData;
968
968
 
969
+
969
970
  var disableEpisodeNumber = false;
970
971
  if (article && article.documentGroup && article.documentGroup.disableEpisodeNumber === true) {
971
972
  disableEpisodeNumber = true;
@@ -1,13 +1,15 @@
1
1
  'use strict';
2
2
 
3
+ require('./extends-7c86182f.js');
3
4
  require('react');
4
- var getSerializers = require('./index-d394c167.js');
5
+ var getSerializers = require('./index-eb1c583d.js');
5
6
  require('./BlockContent-9ebd251f.js');
6
7
  require('./entities-df1aed86.js');
7
- require('./slicedToArray-067dd3bc.js');
8
8
  require('./_commonjsHelpers-06173234.js');
9
- require('./web.dom.iterable-d98303e0.js');
10
9
  require('./core.get-iterator-method-5643aa10.js');
10
+ require('./_object-pie-083f2dd6.js');
11
+ require('./slicedToArray-067dd3bc.js');
12
+ require('./web.dom.iterable-d98303e0.js');
11
13
  require('react-bootstrap');
12
14
  require('./urlFor.js');
13
15
  require('./index-d48b231c.js');
@@ -24,8 +26,6 @@ require('./_library-dd23b178.js');
24
26
  require('./_iter-detect-b1df62f0.js');
25
27
  require('./Segment.js');
26
28
  require('./main-f1c77adb.js');
27
- require('./extends-7c86182f.js');
28
- require('./_object-pie-083f2dd6.js');
29
29
  require('./urlForFile-29d3815a.js');
30
30
  require('./index-eadd5035.js');
31
31
  require('react-dom');
@@ -1,5 +1,6 @@
1
1
  'use strict';
2
2
 
3
+ var _extends = require('./extends-7c86182f.js');
3
4
  var React = require('react');
4
5
  var slicedToArray = require('./slicedToArray-067dd3bc.js');
5
6
  var reactBootstrap = require('react-bootstrap');
@@ -14,7 +15,6 @@ require('./Beam.js');
14
15
  var Segment = require('./Segment.js');
15
16
  var main = require('./main-f1c77adb.js');
16
17
  var BlockContent = require('./BlockContent-9ebd251f.js');
17
- var _extends = require('./extends-7c86182f.js');
18
18
  var urlForFile = require('./urlForFile-29d3815a.js');
19
19
  var index$2 = require('./index-eadd5035.js');
20
20
  var asyncToGenerator = require('./asyncToGenerator-77821af0.js');
@@ -10391,15 +10391,6 @@ var DigiohSmartTag = function DigiohSmartTag(props) {
10391
10391
  return React__default['default'].createElement('div', { id: FormID });
10392
10392
  };
10393
10393
 
10394
- var siteArray = ['aestheticsauthority.com', 'ajmc.com', 'appliedclinicaltrialsonline.com', 'biopharminternational.com', 'cancernetwork.com', 'cannabissciencetech.com', 'centerforbiosimilars.com', 'chromatographyonline.com', 'contagionlive.com', 'contemporaryclinic.com', 'contemporaryobgyn.net', 'contemporarypediatrics.com', 'curetoday.com', 'dentalproductsreport.com', 'dermatologytimes.com', 'diagnosticimaging.com', 'drugtopics.com', 'dvm360.com', 'endocrinologynetwork.com', 'europe.ophthalmologytimes.com', 'formularywatch.com', 'hcplive.com', 'infectioncontroltoday.com', 'managedhealthcareexecutive.com', 'medicaleconomics.com', 'modernretina.com', 'neurologylive.com', 'nutritionaloutlook.com', 'onclive.com', 'oncnursingnews.com', 'ophthalmologytimes.com', 'optometrytimes.com', 'patientcareonline.com', 'pharmaceuticalcommerce.com', 'pharmacytimes.com', 'pharmexec.com', 'pharmtech.com', 'physicianspractice.com', 'practicalcardiology.com', 'psychiatrictimes.com', 'rheumatologynetwork.com', 'spectroscopyonline.com', 'targetedonc.com', 'turbomachinerymag.com', 'urologytimes.com'];
10395
-
10396
- var checkUrlIsExternal = function checkUrlIsExternal(url) {
10397
- if (/https?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|http?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|(^mailto)/i.test(url)) {
10398
- return true;
10399
- }
10400
- return false;
10401
- };
10402
-
10403
10394
  var ScrollToElement = function ScrollToElement(elementId) {
10404
10395
  var element = document.getElementById(elementId);
10405
10396
  if (element) {
@@ -10414,66 +10405,11 @@ var ScrollToElement = function ScrollToElement(elementId) {
10414
10405
  }
10415
10406
  };
10416
10407
 
10417
- var ExternalLink = function ExternalLink(props) {
10418
- var children = props.children,
10419
- _props$mark = props.mark,
10420
- href = _props$mark.href,
10421
- blank = _props$mark.blank,
10422
- color = _props$mark.color,
10423
- nofollow = _props$mark.nofollow;
10424
-
10425
- var _useState = React.useState(null),
10426
- _useState2 = slicedToArray._slicedToArray(_useState, 2),
10427
- ogUrl = _useState2[0],
10428
- setOgUrl = _useState2[1];
10429
-
10430
- React.useEffect(function () {
10431
- if (window.location.href) {
10432
- !ogUrl && setOgUrl(String(window.location.host).replace('www.', ''));
10433
- }
10434
- }, []);
10435
- var isExernalUrl = checkUrlIsExternal(href);
10436
- var checkBaseUrl = function checkBaseUrl(url) {
10437
- if (url.includes('http://') || url.includes('https://')) {
10438
- //to remove http:// or https:// to check URLs
10439
- url = url.replace('www.', '').split('/').slice(2, 3).join('/');
10440
- }
10441
- return ogUrl && ogUrl.includes(url.replace('www.', '').split('/').slice(0, 1).join('/')) || siteArray.includes(url.replace('www.', '').split('/').slice(0, 1).join('/')) ? true : false;
10442
- };
10443
- var checkNoFollow = function checkNoFollow(url, nofollow) {
10444
- if (url && !isExernalUrl || url && checkBaseUrl(url)) {
10445
- //if not external url, nofollow is disabled
10446
- return '';
10447
- } else if (url && nofollow) {
10448
- //if not external url and nofollow is enabled, nofollow
10449
- return 'nofollow';
10450
- } else {
10451
- //if not external url and nofollow is disabled, no nofollow
10452
- return '';
10453
- }
10454
- };
10455
-
10456
- if (href && href.charAt(0) === '#') {
10457
- var elementId = href.slice(1);
10458
- if (articleId) elementId = elementId + '-' + articleId;
10459
- return React__default['default'].createElement(
10460
- 'a',
10461
- { onClick: function onClick() {
10462
- return ScrollToElement(elementId);
10463
- } },
10464
- children
10465
- );
10408
+ var checkUrlIsExternal = function checkUrlIsExternal(url) {
10409
+ if (/https?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|http?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|(^mailto)/i.test(url)) {
10410
+ return true;
10466
10411
  }
10467
- var linkRel = checkNoFollow(href, nofollow) + ' ' + (blank && !checkBaseUrl(href) ? 'noreferrer noopener' : '');
10468
- return href ? linkRel.trim().length > 0 ? React__default['default'].createElement(
10469
- 'a',
10470
- _extends._extends({ rel: linkRel.trim(), href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10471
- children
10472
- ) : React__default['default'].createElement(
10473
- 'a',
10474
- _extends._extends({ href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10475
- children
10476
- ) : children;
10412
+ return false;
10477
10413
  };
10478
10414
 
10479
10415
  var convertEntities = function convertEntities(props) {
@@ -10516,8 +10452,8 @@ var getSerializers = function getSerializers() {
10516
10452
  authorImgHeight = props[15],
10517
10453
  audioAutoplay = props[16];
10518
10454
 
10519
- var nextVideo = article && article.nextVideo ? article.nextVideo : null;
10520
10455
 
10456
+ var nextVideo = article && article.nextVideo ? article.nextVideo : null;
10521
10457
  return {
10522
10458
  types: {
10523
10459
  undefined: function undefined$1() {
@@ -10701,9 +10637,30 @@ var getSerializers = function getSerializers() {
10701
10637
  },
10702
10638
  link: function link(props) {
10703
10639
  var children = props.children,
10704
- mark = props.mark;
10640
+ _props$mark = props.mark,
10641
+ href = _props$mark.href,
10642
+ blank = _props$mark.blank,
10643
+ color = _props$mark.color;
10644
+
10645
+
10646
+ if (href && href.charAt(0) === '#') {
10647
+ var elementId = href.slice(1);
10648
+ if (articleId) elementId = elementId + '-' + articleId;
10649
+ return React__default['default'].createElement(
10650
+ 'a',
10651
+ { onClick: function onClick() {
10652
+ return ScrollToElement(elementId);
10653
+ } },
10654
+ children
10655
+ );
10656
+ }
10705
10657
 
10706
- return React__default['default'].createElement(ExternalLink, { children: children, mark: mark });
10658
+ var isExernalUrl = checkUrlIsExternal(href);
10659
+ return href ? React__default['default'].createElement(
10660
+ 'a',
10661
+ _extends._extends({ rel: blank ? 'noopener' : '', href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10662
+ children
10663
+ ) : children;
10707
10664
  },
10708
10665
  alignleft: function alignleft(_ref23) {
10709
10666
  var children = _ref23.children;
package/dist/cjs/index.js CHANGED
@@ -90,7 +90,7 @@ var VerticalHero = require('./VerticalHero.js');
90
90
  var YahooHero = require('./YahooHero.js');
91
91
  var GridHero = require('./GridHero.js');
92
92
  var ConferenceArticleCard = require('./ConferenceArticleCard.js');
93
- var getSerializers = require('./index-d394c167.js');
93
+ var getSerializers = require('./index-eb1c583d.js');
94
94
  var Beam = require('./Beam.js');
95
95
  var Segment = require('./Segment.js');
96
96
  var KMTracker = require('./KMTracker.js');
@@ -3,7 +3,7 @@ import { _ as _slicedToArray } from './slicedToArray-6ebcbfea.js';
3
3
  import { _ as _extends } from './extends-6d8e3924.js';
4
4
  import React__default from 'react';
5
5
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
6
- import { g as getSerializers } from './index-c94edea2.js';
6
+ import { g as getSerializers } from './index-264bbd3c.js';
7
7
  import ArticleSeriesListing from './ArticleSeriesListing.js';
8
8
  import './_commonjsHelpers-0c4b6f40.js';
9
9
  import './core.get-iterator-method-ea258bb1.js';
@@ -15,7 +15,7 @@ import { L as LazyLoad } from './index-755f2cc2.js';
15
15
  import { m as main_43 } from './main-1894c974.js';
16
16
  import { c as clean_html_1 } from './entities-6d9154b4.js';
17
17
  import { A as ADInfeed } from './ADInfeed-6d1fc6bf.js';
18
- import { P as Pagination } from './Pagination-194dd03f.js';
18
+ import { P as Pagination } from './Pagination-dc30727b.js';
19
19
  import Spinner from 'react-bootstrap/Spinner';
20
20
  import './_commonjsHelpers-0c4b6f40.js';
21
21
  import './core.get-iterator-method-ea258bb1.js';
@@ -16,7 +16,7 @@ import { g as get_1 } from './get-3c308da4.js';
16
16
  import { m as main_43 } from './main-1894c974.js';
17
17
  import urlFor from './urlFor.js';
18
18
  import { c as clean_html_1 } from './entities-6d9154b4.js';
19
- import { P as Pagination } from './Pagination-194dd03f.js';
19
+ import { P as Pagination } from './Pagination-dc30727b.js';
20
20
  import './_commonjsHelpers-0c4b6f40.js';
21
21
  import './core.get-iterator-method-ea258bb1.js';
22
22
  import './web.dom.iterable-ab4dea5c.js';
@@ -2,7 +2,7 @@ import { _ as _extends } from './extends-6d8e3924.js';
2
2
  import { _ as _slicedToArray } from './slicedToArray-6ebcbfea.js';
3
3
  import React__default, { useState, useEffect } from 'react';
4
4
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
5
- import { g as getSerializers } from './index-c94edea2.js';
5
+ import { g as getSerializers } from './index-264bbd3c.js';
6
6
  import { m as momentTimezone } from './index-79cfd25c.js';
7
7
  import { useRouter } from 'next/router';
8
8
  import Button from 'react-bootstrap/Button';
@@ -22,7 +22,7 @@ import urlFor from './urlFor.js';
22
22
  import { m as main_43 } from './main-1894c974.js';
23
23
  import { A as AuthorComponent } from './AuthorComponent-11adff02.js';
24
24
  import { P as PublicationFeature } from './PublicationFeature-d88e76b9.js';
25
- import { P as Pagination } from './Pagination-194dd03f.js';
25
+ import { P as Pagination } from './Pagination-dc30727b.js';
26
26
  import Spinner from 'react-bootstrap/Spinner';
27
27
  import './_commonjsHelpers-0c4b6f40.js';
28
28
  import './core.get-iterator-method-ea258bb1.js';
@@ -3,7 +3,7 @@ import React__default from 'react';
3
3
  import ArticleCarousel from './ArticleCarousel.js';
4
4
  import { I as IoIosArrowForward } from './index.esm-eb1e8e80.js';
5
5
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
6
- import { g as getSerializers } from './index-c94edea2.js';
6
+ import { g as getSerializers } from './index-264bbd3c.js';
7
7
  import './_commonjsHelpers-0c4b6f40.js';
8
8
  import './core.get-iterator-method-ea258bb1.js';
9
9
  import './_object-pie-133f504a.js';
@@ -3,7 +3,7 @@ import React__default from 'react';
3
3
  import QueueDeckExpanded from './QueueDeckExpanded.js';
4
4
  import Breadcrumbs from './Breadcrumbs.js';
5
5
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
6
- import { g as getSerializers } from './index-c94edea2.js';
6
+ import { g as getSerializers } from './index-264bbd3c.js';
7
7
  import './_commonjsHelpers-0c4b6f40.js';
8
8
  import './core.get-iterator-method-ea258bb1.js';
9
9
  import './_object-pie-133f504a.js';
@@ -12,7 +12,7 @@ import { l as lodash } from './lodash-f97fd99a.js';
12
12
  import { m as main_43 } from './main-1894c974.js';
13
13
  import { A as ADlgInfeed } from './ADlgInfeed-dc36c928.js';
14
14
  import { A as ADInfeed } from './ADInfeed-6d1fc6bf.js';
15
- import { P as Pagination } from './Pagination-194dd03f.js';
15
+ import { P as Pagination } from './Pagination-dc30727b.js';
16
16
  import './_commonjsHelpers-0c4b6f40.js';
17
17
  import './core.get-iterator-method-ea258bb1.js';
18
18
  import './web.dom.iterable-ab4dea5c.js';
@@ -9,7 +9,7 @@ import urlFor from './urlFor.js';
9
9
  import { m as moment } from './moment-bc12cb97.js';
10
10
  import { s as styleInject } from './style-inject.es-1f59c1d0.js';
11
11
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
12
- import { g as getSerializers } from './index-c94edea2.js';
12
+ import { g as getSerializers } from './index-264bbd3c.js';
13
13
 
14
14
  /**
15
15
  * Copyright (c) 2013-present, Facebook, Inc.
@@ -3,13 +3,13 @@ import { _ as _typeof } from './typeof-e9fc0c5d.js';
3
3
  import { _ as _extends } from './extends-6d8e3924.js';
4
4
  import { _ as _slicedToArray } from './slicedToArray-6ebcbfea.js';
5
5
  import React__default, { useState, useEffect } from 'react';
6
- import { M as MediaSeriesCard, D as DropdownButton, a as Dropdown } from './MediaSeriesCard-2c3369cb.js';
6
+ import { M as MediaSeriesCard, D as DropdownButton, a as Dropdown } from './MediaSeriesCard-e3b52a0f.js';
7
7
  import './index-98ca9cec.js';
8
8
  import 'react-dom';
9
9
  import Link from 'next/link';
10
10
  import MasterDeck from './MasterDeck.js';
11
11
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
12
- import { g as getSerializers } from './index-c94edea2.js';
12
+ import { g as getSerializers } from './index-264bbd3c.js';
13
13
  import './_commonjsHelpers-0c4b6f40.js';
14
14
  import './core.get-iterator-method-ea258bb1.js';
15
15
  import './web.dom.iterable-ab4dea5c.js';
@@ -3,13 +3,13 @@ import { _ as _typeof } from './typeof-e9fc0c5d.js';
3
3
  import { _ as _extends } from './extends-6d8e3924.js';
4
4
  import { _ as _slicedToArray } from './slicedToArray-6ebcbfea.js';
5
5
  import React__default, { useState, useEffect } from 'react';
6
- import { M as MediaSeriesCard, D as DropdownButton, a as Dropdown } from './MediaSeriesCard-2c3369cb.js';
6
+ import { M as MediaSeriesCard, D as DropdownButton, a as Dropdown } from './MediaSeriesCard-e3b52a0f.js';
7
7
  import './index-98ca9cec.js';
8
8
  import 'react-dom';
9
9
  import Link from 'next/link';
10
10
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
11
11
  import MasterDeck from './MasterDeckPaginated.js';
12
- import { g as getSerializers } from './index-c94edea2.js';
12
+ import { g as getSerializers } from './index-264bbd3c.js';
13
13
  import './_commonjsHelpers-0c4b6f40.js';
14
14
  import './core.get-iterator-method-ea258bb1.js';
15
15
  import './web.dom.iterable-ab4dea5c.js';
@@ -44,7 +44,7 @@ import './toNumber-5aeba6e7.js';
44
44
  import './Beam.js';
45
45
  import './Segment.js';
46
46
  import './ADInfeed-6d1fc6bf.js';
47
- import './Pagination-194dd03f.js';
47
+ import './Pagination-dc30727b.js';
48
48
  import 'react-bootstrap/Button';
49
49
  import './index.esm-1bd8a0a8.js';
50
50
  import './iconBase-ccc56b97.js';
@@ -38,7 +38,7 @@ var Pagination = function Pagination(props) {
38
38
  _onPageChange(currentPage + 1);
39
39
  },
40
40
  disabled: currentPage === pageCount,
41
- href: '?page=' + (currentPage + 1) },
41
+ href: currentPage === pageCount ? '' : '?page=' + (currentPage + 1) },
42
42
  'NEXT PAGE',
43
43
  React__default.createElement(FaArrowRight, { className: 'fa-arrow-right' })
44
44
  )
@@ -11,7 +11,7 @@ import QueueDeckExpanded from './QueueDeckExpanded.js';
11
11
  import Breadcrumbs from './Breadcrumbs.js';
12
12
  import Feature from './Feature.js';
13
13
  import urlFor from './urlFor.js';
14
- import { g as getSerializers } from './index-c94edea2.js';
14
+ import { g as getSerializers } from './index-264bbd3c.js';
15
15
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
16
16
  import './_commonjsHelpers-0c4b6f40.js';
17
17
  import './core.get-iterator-method-ea258bb1.js';
@@ -11,7 +11,7 @@ import QueueDeckExpanded from './QueueDeckExpandedPaginated.js';
11
11
  import Breadcrumbs from './Breadcrumbs.js';
12
12
  import Feature from './Feature.js';
13
13
  import urlFor from './urlFor.js';
14
- import { g as getSerializers } from './index-c94edea2.js';
14
+ import { g as getSerializers } from './index-264bbd3c.js';
15
15
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
16
16
  import './_commonjsHelpers-0c4b6f40.js';
17
17
  import './core.get-iterator-method-ea258bb1.js';
@@ -44,7 +44,7 @@ import './AuthorComponent-11adff02.js';
44
44
  import './ADlgInfeed-dc36c928.js';
45
45
  import './getContentCategory-15dcc413.js';
46
46
  import './timeDifferenceCalc.js';
47
- import './Pagination-194dd03f.js';
47
+ import './Pagination-dc30727b.js';
48
48
  import 'react-bootstrap/Button';
49
49
  import './index.esm-1bd8a0a8.js';
50
50
  import './iconBase-ccc56b97.js';
@@ -17,7 +17,7 @@ import { A as ADlgInfeed } from './ADlgInfeed-dc36c928.js';
17
17
  import { g as getContentCategory } from './getContentCategory-15dcc413.js';
18
18
  import timeDifferenceCalc from './timeDifferenceCalc.js';
19
19
  import urlFor from './urlFor.js';
20
- import { P as Pagination } from './Pagination-194dd03f.js';
20
+ import { P as Pagination } from './Pagination-dc30727b.js';
21
21
  import './_commonjsHelpers-0c4b6f40.js';
22
22
  import './core.get-iterator-method-ea258bb1.js';
23
23
  import './web.dom.iterable-ab4dea5c.js';
@@ -5,7 +5,7 @@ import React__default, { useState, useEffect } from 'react';
5
5
  import { useRouter } from 'next/router';
6
6
  import Head from 'next/head';
7
7
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
8
- import { g as getSerializers } from './index-c94edea2.js';
8
+ import { g as getSerializers } from './index-264bbd3c.js';
9
9
  import './_commonjsHelpers-0c4b6f40.js';
10
10
  import './core.get-iterator-method-ea258bb1.js';
11
11
  import './_object-pie-133f504a.js';
@@ -155,7 +155,7 @@ TaxonomyDescription.getDescription = function () {
155
155
  var _ref3 = _asyncToGenerator( /*#__PURE__*/regenerator.mark(function _callee2() {
156
156
  var url = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
157
157
  var client = arguments[1];
158
- var query, summary;
158
+ var query, summary, taxonomyData;
159
159
  return regenerator.wrap(function _callee2$(_context2) {
160
160
  while (1) {
161
161
  switch (_context2.prev = _context2.next) {
@@ -167,25 +167,29 @@ TaxonomyDescription.getDescription = function () {
167
167
  return client.fetch(query);
168
168
 
169
169
  case 5:
170
- summary = _context2.sent;
171
- _context2.next = 11;
170
+ taxonomyData = _context2.sent;
171
+
172
+ if (taxonomyData.summary) {
173
+ summary = taxonomyData.summary;
174
+ }
175
+ _context2.next = 12;
172
176
  break;
173
177
 
174
- case 8:
175
- _context2.prev = 8;
178
+ case 9:
179
+ _context2.prev = 9;
176
180
  _context2.t0 = _context2['catch'](2);
177
181
 
178
182
  console.error(_context2.t0);
179
183
 
180
- case 11:
184
+ case 12:
181
185
  return _context2.abrupt('return', summary);
182
186
 
183
- case 12:
187
+ case 13:
184
188
  case 'end':
185
189
  return _context2.stop();
186
190
  }
187
191
  }
188
- }, _callee2, _this, [[2, 8]]);
192
+ }, _callee2, _this, [[2, 9]]);
189
193
  }));
190
194
 
191
195
  return function () {
@@ -5,7 +5,7 @@ import { B as BlockContent } from './BlockContent-1e73bd2c.js';
5
5
  import Col from 'react-bootstrap/Col';
6
6
  import Form from 'react-bootstrap/Form';
7
7
  import Button from 'react-bootstrap/Button';
8
- import { g as getSerializers } from './index-c94edea2.js';
8
+ import { g as getSerializers } from './index-264bbd3c.js';
9
9
  import VideoSeriesListing from './VideoSeriesListing.js';
10
10
  import './_commonjsHelpers-0c4b6f40.js';
11
11
  import './core.get-iterator-method-ea258bb1.js';
package/dist/esm/View.js CHANGED
@@ -15,7 +15,7 @@ import FormControl from 'react-bootstrap/FormControl';
15
15
  import Button from 'react-bootstrap/Button';
16
16
  import { V as VisibilitySensor } from './visibility-sensor-72fd8f8b.js';
17
17
  import SocialShare from './SocialShare.js';
18
- import { r as renderAuthor, g as getSerializers } from './index-c94edea2.js';
18
+ import { r as renderAuthor, g as getSerializers } from './index-264bbd3c.js';
19
19
  import DFPAdSlot from './AdSlot.js';
20
20
  import { S as SeriesSlider } from './SeriesSlider-e495571f.js';
21
21
  import { a as getContentPlacementUrl, g as getTargeting } from './getTargeting-04d979c9.js';
@@ -956,6 +956,7 @@ var Article = React__default.memo(forwardRef(function (props, ref) {
956
956
  useSegmentRecommendedArticles = _props$useSegmentReco === undefined ? false : _props$useSegmentReco;
957
957
  var sliderData = props.sliderData;
958
958
 
959
+
959
960
  var disableEpisodeNumber = false;
960
961
  if (article && article.documentGroup && article.documentGroup.disableEpisodeNumber === true) {
961
962
  disableEpisodeNumber = true;
@@ -1,11 +1,13 @@
1
+ import './extends-6d8e3924.js';
1
2
  import 'react';
2
- export { g as default } from './index-c94edea2.js';
3
+ export { g as default } from './index-264bbd3c.js';
3
4
  import './BlockContent-1e73bd2c.js';
4
5
  import './entities-6d9154b4.js';
5
- import './slicedToArray-6ebcbfea.js';
6
6
  import './_commonjsHelpers-0c4b6f40.js';
7
- import './web.dom.iterable-ab4dea5c.js';
8
7
  import './core.get-iterator-method-ea258bb1.js';
8
+ import './_object-pie-133f504a.js';
9
+ import './slicedToArray-6ebcbfea.js';
10
+ import './web.dom.iterable-ab4dea5c.js';
9
11
  import 'react-bootstrap';
10
12
  import './urlFor.js';
11
13
  import './index-3f5c03b2.js';
@@ -22,8 +24,6 @@ import './_library-528f1934.js';
22
24
  import './_iter-detect-98db3b07.js';
23
25
  import './Segment.js';
24
26
  import './main-1894c974.js';
25
- import './extends-6d8e3924.js';
26
- import './_object-pie-133f504a.js';
27
27
  import './urlForFile-b69adffc.js';
28
28
  import './index-755f2cc2.js';
29
29
  import 'react-dom';
@@ -1,3 +1,4 @@
1
+ import { _ as _extends, b as _extends$1 } from './extends-6d8e3924.js';
1
2
  import React__default, { useState, useEffect, useRef, useLayoutEffect, useCallback } from 'react';
2
3
  import { _ as _slicedToArray, a as _getIterator } from './slicedToArray-6ebcbfea.js';
3
4
  import { Carousel, Table, Figure as Figure$1, Card, Row, Col, Button as Button$1, ProgressBar } from 'react-bootstrap';
@@ -12,7 +13,6 @@ import './Beam.js';
12
13
  import Segment from './Segment.js';
13
14
  import { e as main_18, b as main_42, m as main_43 } from './main-1894c974.js';
14
15
  import { B as BlockContent } from './BlockContent-1e73bd2c.js';
15
- import { _ as _extends, b as _extends$1 } from './extends-6d8e3924.js';
16
16
  import { u as urlForFile } from './urlForFile-b69adffc.js';
17
17
  import { L as LazyLoad } from './index-755f2cc2.js';
18
18
  import { _ as _asyncToGenerator, r as regenerator } from './asyncToGenerator-958ef5fc.js';
@@ -10371,15 +10371,6 @@ var DigiohSmartTag = function DigiohSmartTag(props) {
10371
10371
  return React__default.createElement('div', { id: FormID });
10372
10372
  };
10373
10373
 
10374
- var siteArray = ['aestheticsauthority.com', 'ajmc.com', 'appliedclinicaltrialsonline.com', 'biopharminternational.com', 'cancernetwork.com', 'cannabissciencetech.com', 'centerforbiosimilars.com', 'chromatographyonline.com', 'contagionlive.com', 'contemporaryclinic.com', 'contemporaryobgyn.net', 'contemporarypediatrics.com', 'curetoday.com', 'dentalproductsreport.com', 'dermatologytimes.com', 'diagnosticimaging.com', 'drugtopics.com', 'dvm360.com', 'endocrinologynetwork.com', 'europe.ophthalmologytimes.com', 'formularywatch.com', 'hcplive.com', 'infectioncontroltoday.com', 'managedhealthcareexecutive.com', 'medicaleconomics.com', 'modernretina.com', 'neurologylive.com', 'nutritionaloutlook.com', 'onclive.com', 'oncnursingnews.com', 'ophthalmologytimes.com', 'optometrytimes.com', 'patientcareonline.com', 'pharmaceuticalcommerce.com', 'pharmacytimes.com', 'pharmexec.com', 'pharmtech.com', 'physicianspractice.com', 'practicalcardiology.com', 'psychiatrictimes.com', 'rheumatologynetwork.com', 'spectroscopyonline.com', 'targetedonc.com', 'turbomachinerymag.com', 'urologytimes.com'];
10375
-
10376
- var checkUrlIsExternal = function checkUrlIsExternal(url) {
10377
- if (/https?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|http?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|(^mailto)/i.test(url)) {
10378
- return true;
10379
- }
10380
- return false;
10381
- };
10382
-
10383
10374
  var ScrollToElement = function ScrollToElement(elementId) {
10384
10375
  var element = document.getElementById(elementId);
10385
10376
  if (element) {
@@ -10394,66 +10385,11 @@ var ScrollToElement = function ScrollToElement(elementId) {
10394
10385
  }
10395
10386
  };
10396
10387
 
10397
- var ExternalLink = function ExternalLink(props) {
10398
- var children = props.children,
10399
- _props$mark = props.mark,
10400
- href = _props$mark.href,
10401
- blank = _props$mark.blank,
10402
- color = _props$mark.color,
10403
- nofollow = _props$mark.nofollow;
10404
-
10405
- var _useState = useState(null),
10406
- _useState2 = _slicedToArray(_useState, 2),
10407
- ogUrl = _useState2[0],
10408
- setOgUrl = _useState2[1];
10409
-
10410
- useEffect(function () {
10411
- if (window.location.href) {
10412
- !ogUrl && setOgUrl(String(window.location.host).replace('www.', ''));
10413
- }
10414
- }, []);
10415
- var isExernalUrl = checkUrlIsExternal(href);
10416
- var checkBaseUrl = function checkBaseUrl(url) {
10417
- if (url.includes('http://') || url.includes('https://')) {
10418
- //to remove http:// or https:// to check URLs
10419
- url = url.replace('www.', '').split('/').slice(2, 3).join('/');
10420
- }
10421
- return ogUrl && ogUrl.includes(url.replace('www.', '').split('/').slice(0, 1).join('/')) || siteArray.includes(url.replace('www.', '').split('/').slice(0, 1).join('/')) ? true : false;
10422
- };
10423
- var checkNoFollow = function checkNoFollow(url, nofollow) {
10424
- if (url && !isExernalUrl || url && checkBaseUrl(url)) {
10425
- //if not external url, nofollow is disabled
10426
- return '';
10427
- } else if (url && nofollow) {
10428
- //if not external url and nofollow is enabled, nofollow
10429
- return 'nofollow';
10430
- } else {
10431
- //if not external url and nofollow is disabled, no nofollow
10432
- return '';
10433
- }
10434
- };
10435
-
10436
- if (href && href.charAt(0) === '#') {
10437
- var elementId = href.slice(1);
10438
- if (articleId) elementId = elementId + '-' + articleId;
10439
- return React__default.createElement(
10440
- 'a',
10441
- { onClick: function onClick() {
10442
- return ScrollToElement(elementId);
10443
- } },
10444
- children
10445
- );
10388
+ var checkUrlIsExternal = function checkUrlIsExternal(url) {
10389
+ if (/https?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|http?:\/\/((?:[\w\d-]+\.)+[\w\d]{2,})|(^mailto)/i.test(url)) {
10390
+ return true;
10446
10391
  }
10447
- var linkRel = checkNoFollow(href, nofollow) + ' ' + (blank && !checkBaseUrl(href) ? 'noreferrer noopener' : '');
10448
- return href ? linkRel.trim().length > 0 ? React__default.createElement(
10449
- 'a',
10450
- _extends({ rel: linkRel.trim(), href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10451
- children
10452
- ) : React__default.createElement(
10453
- 'a',
10454
- _extends({ href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10455
- children
10456
- ) : children;
10392
+ return false;
10457
10393
  };
10458
10394
 
10459
10395
  var convertEntities = function convertEntities(props) {
@@ -10496,8 +10432,8 @@ var getSerializers = function getSerializers() {
10496
10432
  authorImgHeight = props[15],
10497
10433
  audioAutoplay = props[16];
10498
10434
 
10499
- var nextVideo = article && article.nextVideo ? article.nextVideo : null;
10500
10435
 
10436
+ var nextVideo = article && article.nextVideo ? article.nextVideo : null;
10501
10437
  return {
10502
10438
  types: {
10503
10439
  undefined: function undefined$1() {
@@ -10681,9 +10617,30 @@ var getSerializers = function getSerializers() {
10681
10617
  },
10682
10618
  link: function link(props) {
10683
10619
  var children = props.children,
10684
- mark = props.mark;
10620
+ _props$mark = props.mark,
10621
+ href = _props$mark.href,
10622
+ blank = _props$mark.blank,
10623
+ color = _props$mark.color;
10624
+
10625
+
10626
+ if (href && href.charAt(0) === '#') {
10627
+ var elementId = href.slice(1);
10628
+ if (articleId) elementId = elementId + '-' + articleId;
10629
+ return React__default.createElement(
10630
+ 'a',
10631
+ { onClick: function onClick() {
10632
+ return ScrollToElement(elementId);
10633
+ } },
10634
+ children
10635
+ );
10636
+ }
10685
10637
 
10686
- return React__default.createElement(ExternalLink, { children: children, mark: mark });
10638
+ var isExernalUrl = checkUrlIsExternal(href);
10639
+ return href ? React__default.createElement(
10640
+ 'a',
10641
+ _extends({ rel: blank ? 'noopener' : '', href: isExernalUrl ? href : '/' + href, target: blank ? '_blank' : '_self' }, color && color.hex && { style: { color: color.hex } }),
10642
+ children
10643
+ ) : children;
10687
10644
  },
10688
10645
  alignleft: function alignleft(_ref23) {
10689
10646
  var children = _ref23.children;
package/dist/esm/index.js CHANGED
@@ -87,7 +87,7 @@ export { default as VerticalHero } from './VerticalHero.js';
87
87
  export { default as YahooHero } from './YahooHero.js';
88
88
  export { default as GridHero } from './GridHero.js';
89
89
  export { default as ConferenceArticleCard } from './ConferenceArticleCard.js';
90
- export { g as getSerializers } from './index-c94edea2.js';
90
+ export { g as getSerializers } from './index-264bbd3c.js';
91
91
  export { default as Beam } from './Beam.js';
92
92
  export { default as Segment } from './Segment.js';
93
93
  export { default as KMTracker } from './KMTracker.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mjhls/mjh-framework",
3
- "version": "1.0.971-nofollow-v5",
3
+ "version": "1.0.972-masterdeck-pagination-v1",
4
4
  "description": "Foundation Framework",
5
5
  "author": "mjh-framework",
6
6
  "license": "MIT",