@mjhls/mjh-framework 1.0.390 → 1.0.391

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 CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
- # mjh-framework v. 1.0.390
2
+ # mjh-framework v. 1.0.391
3
3
 
4
4
 
5
5
  > Foundation Framework
package/dist/cjs/index.js CHANGED
@@ -18126,6 +18126,41 @@ var KMTracker = function KMTracker(props) {
18126
18126
  }
18127
18127
  };
18128
18128
 
18129
+ var getSeriesDetail = function getSeriesDetail(article, currentSeries) {
18130
+ //For use in getInitialProps to return series detail to display next/prev links when javascript is disabled
18131
+ if (!currentSeries) {
18132
+ return {
18133
+ seriesUrl: '',
18134
+ currentSeries: false,
18135
+ prevUrl: false,
18136
+ nextUrl: false
18137
+
18138
+ };
18139
+ }
18140
+ var nextUrl = false;
18141
+ var prevUrl = false;
18142
+ var galleryBody = article.body.find(function (body) {
18143
+ if (body._type == 'youtubeGallery') {
18144
+ return body;
18145
+ }
18146
+ });
18147
+ if (currentSeries >= 1 && currentSeries < galleryBody.videos.length) {
18148
+ nextUrl = '/view/' + article.url.current + '?seriesVid=' + (parseInt(currentSeries) + 1);
18149
+ }
18150
+ if (currentSeries > 1 && currentSeries <= galleryBody.videos.length) {
18151
+ prevUrl = '/view/' + article.url.current + '?seriesVid=' + (parseInt(currentSeries) - 1);
18152
+ }
18153
+ var seriesDetail = {
18154
+ seriesUrl: article.url.current,
18155
+ currentSeries: currentSeries,
18156
+ nextUrl: nextUrl,
18157
+ prevUrl: prevUrl,
18158
+ type: 'Video'
18159
+ };
18160
+
18161
+ return seriesDetail;
18162
+ };
18163
+
18129
18164
  var returnFormField = function returnFormField(_ref) {
18130
18165
  var name = _ref.name,
18131
18166
  label = _ref.label,
@@ -22152,3 +22187,4 @@ exports.SocialShare = SocialShare$1;
22152
22187
  exports.VerticalHero = VerticalHero;
22153
22188
  exports.YahooHero = YahooHero;
22154
22189
  exports.getSerializers = getSerializers;
22190
+ exports.getSeriesDetail = getSeriesDetail;
package/dist/esm/index.js CHANGED
@@ -18123,6 +18123,41 @@ var KMTracker = function KMTracker(props) {
18123
18123
  }
18124
18124
  };
18125
18125
 
18126
+ var getSeriesDetail = function getSeriesDetail(article, currentSeries) {
18127
+ //For use in getInitialProps to return series detail to display next/prev links when javascript is disabled
18128
+ if (!currentSeries) {
18129
+ return {
18130
+ seriesUrl: '',
18131
+ currentSeries: false,
18132
+ prevUrl: false,
18133
+ nextUrl: false
18134
+
18135
+ };
18136
+ }
18137
+ var nextUrl = false;
18138
+ var prevUrl = false;
18139
+ var galleryBody = article.body.find(function (body) {
18140
+ if (body._type == 'youtubeGallery') {
18141
+ return body;
18142
+ }
18143
+ });
18144
+ if (currentSeries >= 1 && currentSeries < galleryBody.videos.length) {
18145
+ nextUrl = '/view/' + article.url.current + '?seriesVid=' + (parseInt(currentSeries) + 1);
18146
+ }
18147
+ if (currentSeries > 1 && currentSeries <= galleryBody.videos.length) {
18148
+ prevUrl = '/view/' + article.url.current + '?seriesVid=' + (parseInt(currentSeries) - 1);
18149
+ }
18150
+ var seriesDetail = {
18151
+ seriesUrl: article.url.current,
18152
+ currentSeries: currentSeries,
18153
+ nextUrl: nextUrl,
18154
+ prevUrl: prevUrl,
18155
+ type: 'Video'
18156
+ };
18157
+
18158
+ return seriesDetail;
18159
+ };
18160
+
18126
18161
  var returnFormField = function returnFormField(_ref) {
18127
18162
  var name = _ref.name,
18128
18163
  label = _ref.label,
@@ -22081,4 +22116,4 @@ var auth = {
22081
22116
  ProcessData: ProcessData_1
22082
22117
  };
22083
22118
 
22084
- export { AD300x250, AD300x250x600, ADFloatingFooter, ADFooter, ADGutter, ADSponsoredResources, ADWelcome, AccordionPanel, AdSlotsProvider, AlphabeticList, ArticleDetailDropdown, ArticleQueue, auth as Auth, Breadcrumbs$1 as Breadcrumbs, CMEDeck, ConferenceArticleCard, EventsDeck, Feature, fbsHero as ForbesHero, GridHero, Hero, HighlightenVideo, HorizontalHero, InfiniteScrollDeck, KMTracker, OncliveHero, OncliveLargeHero, PdfDownload, PublicationLanding, RelatedContent, RelatedTopicsDropdown, SetCookie, SocialShare$1 as SocialShare, VerticalHero, YahooHero, getSerializers };
22119
+ export { AD300x250, AD300x250x600, ADFloatingFooter, ADFooter, ADGutter, ADSponsoredResources, ADWelcome, AccordionPanel, AdSlotsProvider, AlphabeticList, ArticleDetailDropdown, ArticleQueue, auth as Auth, Breadcrumbs$1 as Breadcrumbs, CMEDeck, ConferenceArticleCard, EventsDeck, Feature, fbsHero as ForbesHero, GridHero, Hero, HighlightenVideo, HorizontalHero, InfiniteScrollDeck, KMTracker, OncliveHero, OncliveLargeHero, PdfDownload, PublicationLanding, RelatedContent, RelatedTopicsDropdown, SetCookie, SocialShare$1 as SocialShare, VerticalHero, YahooHero, getSerializers, getSeriesDetail };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mjhls/mjh-framework",
3
- "version": "1.0.390",
3
+ "version": "1.0.391",
4
4
  "description": "Foundation Framework",
5
5
  "author": "mjh-framework",
6
6
  "license": "MIT",