@mjhls/mjh-framework 1.0.189 → 1.0.190

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.189
2
+ # mjh-framework v. 1.0.190
3
3
 
4
4
 
5
5
 
package/dist/index.es.js CHANGED
@@ -14197,20 +14197,6 @@ var MasterDeck = function (_React$Component) {
14197
14197
  };
14198
14198
  }
14199
14199
  });
14200
- }, _this.urlFor = function (source) {
14201
- var client = _this.props.client;
14202
-
14203
- var builder = imageUrlBuilder(client);
14204
- return builder.image(source).auto('format');
14205
- }, _this.renderCardImage = function (row, page) {
14206
- if (row.thumbnail && row.thumbnail.asset) {
14207
- var url = _this.urlFor(row.thumbnail);
14208
- if (_this.props.imageHeight) url = url.height(_this.props.imageHeight);
14209
- if (_this.props.imageWidth) url = url.width(_this.props.imageWidth);
14210
- return url.url();
14211
- } else {
14212
- return _this.defaultImage;
14213
- }
14214
14200
  }, _this.changePageNumber = function (pageNumber) {
14215
14201
  var _this$props2 = _this.props,
14216
14202
  seoPaginate = _this$props2.seoPaginate,
@@ -14281,50 +14267,6 @@ var MasterDeck = function (_React$Component) {
14281
14267
  });
14282
14268
  }
14283
14269
  }
14284
- }, _this.renderAuthor = function (authorDetail, index$$1, length) {
14285
- if (authorDetail) {
14286
- var _id = authorDetail._id,
14287
- displayName = authorDetail.displayName,
14288
- url = authorDetail.url;
14289
-
14290
- if (displayName && url && url.current) {
14291
- return React__default.createElement(
14292
- 'div',
14293
- { key: _id },
14294
- index$$1 === 0 && React__default.createElement(
14295
- 'span',
14296
- { className: 'pr-1' },
14297
- 'By'
14298
- ),
14299
- React__default.createElement(
14300
- Link,
14301
- { href: '/authors/[url]', as: '/authors/' + url.current },
14302
- React__default.createElement(
14303
- 'a',
14304
- { className: 'text-muted' },
14305
- displayName,
14306
- length !== index$$1 + 1 && React__default.createElement('br', null)
14307
- )
14308
- )
14309
- );
14310
- } else if (displayName) {
14311
- return React__default.createElement(
14312
- 'div',
14313
- { key: _id },
14314
- index$$1 === 0 && React__default.createElement(
14315
- 'span',
14316
- { className: 'pr-1' },
14317
- 'By'
14318
- ),
14319
- React__default.createElement(
14320
- 'span',
14321
- { className: 'text-muted' },
14322
- displayName,
14323
- length !== index$$1 + 1 && React__default.createElement('br', null)
14324
- )
14325
- );
14326
- }
14327
- } else return null;
14328
14270
  }, _this.cardLoader = function (page, columns, variant) {
14329
14271
  var numberOfItemsBeforeAd = 6;
14330
14272
  return React__default.createElement(
@@ -14332,7 +14274,6 @@ var MasterDeck = function (_React$Component) {
14332
14274
  null,
14333
14275
  _this.state.data && _this.state.data.map(function (row, index$$1) {
14334
14276
  var pageNumber = row.pageNumber || _this.state.page;
14335
- var contentCategoryName = row.contentCategory && row.contentCategory.name && _this.mapping[row.contentCategory.name] ? row.contentCategory.name : 'Articles';
14336
14277
 
14337
14278
  return React__default.createElement(
14338
14279
  React__default.Fragment,
@@ -14343,7 +14284,7 @@ var MasterDeck = function (_React$Component) {
14343
14284
  onChange: function onChange(isVisible) {
14344
14285
  isVisible && _this.changePageNumber(pageNumber);
14345
14286
  } },
14346
- React__default.createElement(_this2.Deck, { data: row, variant: variant, index: index$$1 })
14287
+ React__default.createElement(_this2.Deck, { data: row, variant: variant, index: index$$1, client: _this.props.client })
14347
14288
  ),
14348
14289
  main_36 && _this.rightItems && (index$$1 + 1) % numberOfItemsBeforeAd === 0 && React__default.createElement(
14349
14290
  'div',
@@ -15632,7 +15573,7 @@ var Column3 = function Column3(props) {
15632
15573
  Col,
15633
15574
  { md: true, className: 'leftCol', style: { width: '200px' } },
15634
15575
  React__default.createElement(LeftNav, { leftItems: leftItems }),
15635
- website && website.sideFooterContent && website.sideFooterContent.length && website.showFooterOnLeftSide && React__default.createElement(SideFooter, { website: website, logo: logo })
15576
+ website && website.sideFooterContent && website.sideFooterContent.length && website.showFooterOnLeftSide && React__default.createElement(SideFooter, { website: website, cache: website.cache, logo: logo })
15636
15577
  ),
15637
15578
  React__default.createElement(
15638
15579
  Col,
@@ -15676,7 +15617,7 @@ var Column3 = function Column3(props) {
15676
15617
  row.component
15677
15618
  );
15678
15619
  }),
15679
- website && website.sideFooterContent && website.sideFooterContent.length && !website.showFooterOnLeftSide && React__default.createElement(SideFooter, { website: website, logo: logo })
15620
+ website && website.sideFooterContent && website.sideFooterContent.length && !website.showFooterOnLeftSide && React__default.createElement(SideFooter, { website: website, cache: website.cache, logo: logo })
15680
15621
  )
15681
15622
  )
15682
15623
  )
@@ -17014,7 +16955,7 @@ var HamMagazine = function HamMagazine(props) {
17014
16955
  ),
17015
16956
  React__default.createElement(
17016
16957
  Navbar,
17017
- { variant: 'dark', expand: 'lg', bg: 'primary', ref: navRef, style: { width: '100%' } },
16958
+ { variant: 'dark', expand: 'xl', bg: 'primary', ref: navRef, style: { width: '100%' } },
17018
16959
  React__default.createElement(
17019
16960
  Container,
17020
16961
  { className: 'mobile-nav' },
@@ -17141,7 +17082,7 @@ var HamMagazine = function HamMagazine(props) {
17141
17082
  React__default.createElement(
17142
17083
  'style',
17143
17084
  { jsx: 'true' },
17144
- '\n .sticky-home {\n position: relative;\n top: -3px;\n left: -6px;\n cursor: pointer;\n }\n .nav-item svg {\n margin-bottom: 2px;\n }\n #nav-login,\n #nav-logout,\n #nav-register {\n padding: 0.5rem;\n cursor: pointer;\n }\n #nav-mobile-login,\n #nav-mobile-logout,\n #nav-mobile-register {\n display: none;\n }\n #nav-mobile-logout,\n #nav-mobile-login {\n position: absolute;\n right: 1rem;\n }\n #nav-mobile-register {\n position: absolute;\n left: 1rem;\n }\n @media screen and (max-width: 376px) {\n .mobile-nav .nav-toggle .form-inline .mobile-search {\n width: 60%;\n }\n .mobile-nav .nav-toggle .form-inline {\n width: 70%;\n }\n }\n @media screen and (max-width: 328px) {\n .mobile-nav .nav-toggle .form-inline .mobile-search {\n margin-right: 5px;\n }\n }\n @media screen and (max-width: 767px) {\n .logo {\n width: 100%;\n padding-left: 10px;\n padding-right: 10px;\n }\n }\n @media screen and (max-width: 991px) {\n .nav-close {\n position: sticky;\n top: -70px;\n }\n .nav-open {\n position: relative;\n }\n\n .mobile-nav .nav-toggle {\n width: 100%;\n }\n\n .android-nav {\n max-height: 80vh;\n }\n\n .ios-nav {\n max-height: none;\n }\n\n .navbar.bg-primary {\n overflow: auto;\n }\n\n .mobile-nav .nav-toggle .navbar-toggler {\n float: left;\n height: 45px;\n }\n .mobile-nav .nav-toggle .form-inline {\n float: right;\n margin: 4px 0px 0px 0px;\n }\n .mobile-nav .form-inline .mobile-search {\n width: auto;\n }\n .sticky-home {\n display: none;\n }\n .dropdown-menu {\n max-height: 315px;\n overflow: auto;\n }\n ::-webkit-scrollbar {\n width: 10px;\n }\n ::-webkit-scrollbar-thumb {\n border-radius: 4px;\n background-color: rgba(214, 214, 214, 0.8);\n box-shadow: 0 0 1px rgba(255, 255, 255, 0.5);\n -webkit-box-shadow: 0 0 1px rgba(255, 255, 255, 0.5);\n }\n .navbar-expand-lg .show#basic-navbar-sub {\n display: block;\n }\n .navbar .mobile-nav .navbar-collapse.show {\n padding-bottom: 10px;\n border-bottom: 0.5px solid white;\n }\n .navbar .mobile-nav .navbar-collapse .form-inline {\n display: none;\n }\n .navbar .mobile-nav .navbar-collapse {\n margin-top: 15px;\n }\n .navbar .mobile-nav .navbar-collapse:last-child {\n border-bottom: none;\n margin-bottom: 0px;\n padding-bottom: 0px;\n margin-top: 0px;\n padding-top: 10px;\n }\n .navbar .mobile-nav .navbar-collapse .nav-footer ul {\n list-style-type: none;\n padding: inherit;\n margin-bottom: 0rem;\n }\n .navbar .mobile-nav .navbar-collapse .nav-footer .nav-link {\n text-transform: capitalize !important;\n font-weight: 300;\n }\n .navbar .mobile-nav .dropdown-item:focus {\n background-color: #696969;\n }\n .navbar .mobile-nav .dropdown-menu .dropdown-item {\n color: white;\n }\n .navbar .mobile-nav .dropdown-menu {\n background: inherit;\n border: none;\n }\n .navbar .mobile-nav .dropdown-menu.show {\n max-height: 100px;\n }\n }\n @media screen and (min-width: 992px) {\n .nav-close {\n position: sticky;\n top: -70px;\n }\n #basic-navbar-sub {\n display: none !important;\n }\n .navbar .mobile-nav .dropdown-menu .dropdown-item {\n color: #696969;\n }\n .navbar .mobile-nav .dropdown-menu {\n background: white;\n border: 1 px solid #708090;\n }\n .mobile-nav .nav-toggle .form-inline {\n display: none;\n }\n }\n @media screen and (max-width: 1199px) {\n #nav-mobile-login,\n #nav-mobile-logout,\n #nav-mobile-register {\n display: block;\n }\n .navbar-top {\n flex-direction: row;\n justify-content: space-around !important;\n align-items: center;\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n width: 100%;\n }\n }\n '
17085
+ '\n .sticky-home {\n position: relative;\n top: -3px;\n left: -6px;\n cursor: pointer;\n }\n .nav-item svg {\n margin-bottom: 2px;\n }\n #nav-login,\n #nav-logout,\n #nav-register {\n padding: 0.5rem;\n cursor: pointer;\n }\n #nav-mobile-login,\n #nav-mobile-logout,\n #nav-mobile-register {\n display: none;\n }\n #nav-mobile-logout,\n #nav-mobile-login {\n position: absolute;\n right: 1rem;\n }\n #nav-mobile-register {\n position: absolute;\n left: 1rem;\n }\n @media screen and (max-width: 376px) {\n .mobile-nav .nav-toggle .form-inline .mobile-search {\n width: 60%;\n }\n .mobile-nav .nav-toggle .form-inline {\n width: 70%;\n }\n }\n @media screen and (max-width: 328px) {\n .mobile-nav .nav-toggle .form-inline .mobile-search {\n margin-right: 5px;\n }\n }\n @media screen and (max-width: 767px) {\n .logo {\n width: 100%;\n padding-left: 10px;\n padding-right: 10px;\n }\n }\n @media screen and (max-width: 1199px) {\n .nav-close {\n position: sticky;\n top: -70px;\n }\n .nav-open {\n position: relative;\n }\n\n .mobile-nav .nav-toggle {\n width: 100%;\n }\n\n .android-nav {\n max-height: 80vh;\n }\n\n .ios-nav {\n max-height: none;\n }\n\n .navbar.bg-primary {\n overflow: auto;\n }\n\n .mobile-nav .nav-toggle .navbar-toggler {\n float: left;\n height: 45px;\n }\n .mobile-nav .nav-toggle .form-inline {\n float: right;\n margin: 4px 0px 0px 0px;\n }\n .mobile-nav .form-inline .mobile-search {\n width: auto;\n }\n .sticky-home {\n display: none;\n }\n .dropdown-menu {\n max-height: 315px;\n overflow: auto;\n }\n ::-webkit-scrollbar {\n width: 10px;\n }\n ::-webkit-scrollbar-thumb {\n border-radius: 4px;\n background-color: rgba(214, 214, 214, 0.8);\n box-shadow: 0 0 1px rgba(255, 255, 255, 0.5);\n -webkit-box-shadow: 0 0 1px rgba(255, 255, 255, 0.5);\n }\n .navbar-expand-xl .show#basic-navbar-sub {\n display: block;\n }\n .navbar .mobile-nav .navbar-collapse.show {\n padding-bottom: 10px;\n border-bottom: 0.5px solid white;\n }\n .navbar .mobile-nav .navbar-collapse .form-inline {\n display: none;\n }\n .navbar .mobile-nav .navbar-collapse {\n margin-top: 15px;\n }\n .navbar .mobile-nav .navbar-collapse:last-child {\n border-bottom: none;\n margin-bottom: 0px;\n padding-bottom: 0px;\n margin-top: 0px;\n padding-top: 10px;\n }\n .navbar .mobile-nav .navbar-collapse .nav-footer ul {\n list-style-type: none;\n padding: inherit;\n margin-bottom: 0rem;\n }\n .navbar .mobile-nav .navbar-collapse .nav-footer .nav-link {\n text-transform: capitalize !important;\n font-weight: 300;\n }\n .navbar .mobile-nav .dropdown-item:focus {\n background-color: #696969;\n }\n .navbar .mobile-nav .dropdown-menu .dropdown-item {\n color: white;\n }\n .navbar .mobile-nav .dropdown-menu {\n background: inherit;\n border: none;\n }\n .navbar .mobile-nav .dropdown-menu.show {\n max-height: 100px;\n }\n }\n @media screen and (min-width: 1200px) {\n .nav-close {\n position: sticky;\n top: -70px;\n }\n #basic-navbar-sub {\n display: none !important;\n }\n .navbar .mobile-nav .dropdown-menu .dropdown-item {\n color: #696969;\n }\n .navbar .mobile-nav .dropdown-menu {\n background: white;\n border: 1 px solid #708090;\n }\n .mobile-nav .nav-toggle .form-inline {\n display: none;\n }\n }\n @media screen and (max-width: 1199px) {\n #nav-mobile-login,\n #nav-mobile-logout,\n #nav-mobile-register {\n display: block;\n }\n .navbar-top {\n flex-direction: row;\n justify-content: space-around !important;\n align-items: center;\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n width: 100%;\n }\n }\n '
17145
17086
  )
17146
17087
  );
17147
17088
  };
@@ -17554,7 +17495,7 @@ var urlFor$2 = function urlFor(source, builder) {
17554
17495
 
17555
17496
  var onChangeSlide = function onChangeSlide(selectedIndex, router) {
17556
17497
  var pageNumber = selectedIndex + 1;
17557
- var href = '/view/' + router.query.url + '/?page=' + pageNumber;
17498
+ var href = '/view/' + router.query.url + '?page=' + pageNumber;
17558
17499
  Router.push(router.pathname, pageNumber > 1 ? href : '/view/' + router.query.url, { shallow: true });
17559
17500
  };
17560
17501
 
@@ -30255,5 +30196,88 @@ var RelatedContent = function RelatedContent(props) {
30255
30196
  );
30256
30197
  };
30257
30198
 
30258
- export { ContentCard as DeckContent, GridContent$1 as GridContent, Queue as DeckQueue, ThumbnailCard, TaxonomyCard, GroupDeck, YoutubeGroup, QueueDeckExpanded, VideoSeriesListing$1 as VideoSeriesListing, MasterDeck$1 as MasterDeck, PublicationDeck, IssueDeck, IssueContentDeck, Column1, Column2, Column3, Header, LeftNav, AccordionPanel, SocialShare, PageFilter, NavMagazine, NavNative, NavNormal, NavDvm, HamMagazine, TemplateNormal, AD, AD300x250, AD300x250x600, AD728x90, ADFooter, getSerializers$1 as getSerializers, Search, Feature, Breadcrumbs, SetCookie, Hero, AlphabeticList, PdfDownload, RelatedTopicsDropdown, Ustream, SideFooter, fbsHero as ForbesHero, HorizontalHero, OncliveHero, OncliveLargeHero, VerticalHero, YahooHero, RelatedContent };
30199
+ /*
30200
+ Example usage - targetedonc.com/latest-conference
30201
+ const query = `*[!(_id in path("drafts.**")) && _type == "article" && defined(title) && is_visible == true && published <= '${today}' && references('b49d36b8-aa56-4183-a2bc-1568c229fb72') ] | order(published desc) [$from...$to] {
30202
+ ...,
30203
+ title,
30204
+ summary,
30205
+ thumbnail,
30206
+ url,
30207
+ published,
30208
+ documentGroup->,
30209
+ contentCategory->,
30210
+ 'pageNumber': ${currentPage}
30211
+ }`
30212
+
30213
+ const posts = await client.fetch(query, params)
30214
+ */
30215
+
30216
+ var ConferenceArticleCard = function ConferenceArticleCard(props) {
30217
+ var data = props.data,
30218
+ variant = props.variant,
30219
+ index = props.index,
30220
+ client = props.client;
30221
+
30222
+
30223
+ var builder = imageUrlBuilder(client);
30224
+
30225
+ function urlFor(source) {
30226
+ return builder.image(source);
30227
+ }
30228
+
30229
+ //title, thumbnail, summary, published, documentGroup.identifier.current, documentGroup.identifier.name
30230
+ return React__default.createElement(
30231
+ 'div',
30232
+ { className: 'conference-media' },
30233
+ React__default.createElement(
30234
+ 'a',
30235
+ { className: 'img-wrapper', href: '/view/study-depicts-complexity-of-met-exon-14-mutation-testing' },
30236
+ React__default.createElement('img', {
30237
+ className: 'mr-3 img-fluid',
30238
+ src: data.thumbnail && urlFor(data.thumbnail.asset).width(350).url(),
30239
+ alt: data.title
30240
+ })
30241
+ ),
30242
+ React__default.createElement(
30243
+ 'div',
30244
+ { className: 'media-body' },
30245
+ React__default.createElement(
30246
+ 'a',
30247
+ { href: '/view/study-depicts-complexity-of-met-exon-14-mutation-testing' },
30248
+ React__default.createElement(
30249
+ 'h4',
30250
+ { className: 'conf-media__card-title' },
30251
+ data.title
30252
+ )
30253
+ ),
30254
+ React__default.createElement(
30255
+ 'p',
30256
+ { className: 'conf-media__card-text' },
30257
+ moment(data.published).format('MMMM Do YYYY, h:mma')
30258
+ ),
30259
+ React__default.createElement(
30260
+ 'p',
30261
+ { className: 'mb-1 conference-group' },
30262
+ React__default.createElement(
30263
+ Link,
30264
+ { href: '/conference/[url]', as: '/conference/' + data.documentGroup.identifier.current },
30265
+ React__default.createElement(
30266
+ 'a',
30267
+ { alt: data.thumbnail.alt || data.title },
30268
+ data.documentGroup.name
30269
+ )
30270
+ )
30271
+ ),
30272
+ React__default.createElement('p', { className: 'pt-2 card-text', dangerouslySetInnerHTML: { __html: data.summary } })
30273
+ ),
30274
+ React__default.createElement(
30275
+ 'style',
30276
+ { jsx: 'true' },
30277
+ '\n .conference-media {\n display: flex;\n flex-direction: row;\n margin-bottom: 1.25rem;\n padding-bottom: 1.25rem;\n border-bottom: 1px solid #ddd;\n }\n .conf-media__card-title {\n font-weight: bold;\n color: #252525;\n margin-bottom: 0.5rem;\n font-size: 1.5rem;\n }\n .conf-media__card-text {\n color: var(--dark);\n margin-bottom: 0.25rem;\n }\n .conference-media a img {\n width: 175px;\n min-width: 175px;\n height: auto;\n object-fit: contain;\n }\n .conference-media .conference-group {\n background: #003767;\n color: white;\n border-radius: 5px;\n display: inline-block;\n padding: 0 0.25rem;\n }\n .conference-media .conference-group a {\n color: white;\n font-size: 0.8rem;\n }\n @media screen and (max-width: 1064px) {\n .conf-media__card-title {\n font-size: 1.1rem;\n }\n }\n @media screen and (max-width: 768px) {\n .conference-media {\n flex-direction: column;\n }\n .conference-media a img {\n width: 100%;\n height: auto;\n max-height: 175px;\n object-fit: contain;\n margin-bottom: 1rem;\n }\n }\n '
30278
+ )
30279
+ );
30280
+ };
30281
+
30282
+ export { ContentCard as DeckContent, GridContent$1 as GridContent, Queue as DeckQueue, ThumbnailCard, TaxonomyCard, GroupDeck, YoutubeGroup, QueueDeckExpanded, VideoSeriesListing$1 as VideoSeriesListing, MasterDeck$1 as MasterDeck, PublicationDeck, IssueDeck, IssueContentDeck, Column1, Column2, Column3, Header, LeftNav, AccordionPanel, SocialShare, PageFilter, NavMagazine, NavNative, NavNormal, NavDvm, HamMagazine, TemplateNormal, AD, AD300x250, AD300x250x600, AD728x90, ADFooter, getSerializers$1 as getSerializers, Search, Feature, Breadcrumbs, SetCookie, Hero, AlphabeticList, PdfDownload, RelatedTopicsDropdown, Ustream, SideFooter, fbsHero as ForbesHero, HorizontalHero, OncliveHero, OncliveLargeHero, VerticalHero, YahooHero, RelatedContent, ConferenceArticleCard };
30259
30283
  //# sourceMappingURL=index.es.js.map