@mjhls/mjh-framework 1.0.128 → 1.0.130
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 +2 -1
- package/dist/index.es.js +89 -47
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +89 -46
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
package/dist/index.es.js
CHANGED
|
@@ -24,6 +24,8 @@ import NavDropdown from 'react-bootstrap/NavDropdown';
|
|
|
24
24
|
import Pagination from 'react-bootstrap/Pagination';
|
|
25
25
|
import Carousel$1 from 'react-bootstrap/Carousel';
|
|
26
26
|
import Breadcrumb from 'react-bootstrap/Breadcrumb';
|
|
27
|
+
import DropdownButton from 'react-bootstrap/DropdownButton';
|
|
28
|
+
import Dropdown$1 from 'react-bootstrap/Dropdown';
|
|
27
29
|
|
|
28
30
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
29
31
|
|
|
@@ -12162,7 +12164,7 @@ var cardLoader = function cardLoader(data, builder, mapping, values, seoPaginate
|
|
|
12162
12164
|
}),
|
|
12163
12165
|
React__default.createElement(
|
|
12164
12166
|
'style',
|
|
12165
|
-
{ jsx: true },
|
|
12167
|
+
{ jsx: 'true' },
|
|
12166
12168
|
'\n .img-wrapper img {\n max-height: 200px;\n width: 100%;\n object-fit: cover;\n }\n @media only screen and (min-width: 768px) {\n .img-wrapper {\n width: 42%;\n }\n .img-wrapper > img {\n padding-right: 1em;\n }\n }\n @media only screen and (max-width: 767px) {\n .img-wrapper {\n width: 100%;\n }\n .img-wrapper img {\n padding-bottom: 1em;\n }\n .media {\n flex-direction: column;\n }\n }\n '
|
|
12167
12169
|
)
|
|
12168
12170
|
);
|
|
@@ -18439,11 +18441,12 @@ var TableShow = function TableShow(_ref) {
|
|
|
18439
18441
|
};
|
|
18440
18442
|
|
|
18441
18443
|
var Media$2 = function Media$$1(_ref) {
|
|
18442
|
-
var
|
|
18443
|
-
|
|
18444
|
-
|
|
18445
|
-
|
|
18446
|
-
|
|
18444
|
+
var node$$1 = _ref.node,
|
|
18445
|
+
client = _ref.client;
|
|
18446
|
+
var uploadDoc = node$$1.upload_doc,
|
|
18447
|
+
poster = node$$1.poster,
|
|
18448
|
+
blank = node$$1.blank,
|
|
18449
|
+
caption = node$$1.caption;
|
|
18447
18450
|
|
|
18448
18451
|
var builder = imageUrlBuilder(client);
|
|
18449
18452
|
|
|
@@ -18452,49 +18455,33 @@ var Media$2 = function Media$$1(_ref) {
|
|
|
18452
18455
|
};
|
|
18453
18456
|
|
|
18454
18457
|
var renderFigure = function renderFigure(uploadDoc, poster, blank, caption) {
|
|
18455
|
-
if (uploadDoc && uploadDoc.asset
|
|
18456
|
-
|
|
18457
|
-
|
|
18458
|
-
|
|
18459
|
-
|
|
18460
|
-
|
|
18461
|
-
|
|
18462
|
-
|
|
18463
|
-
src: urlFor(poster
|
|
18464
|
-
fluid: true
|
|
18465
|
-
}),
|
|
18466
|
-
caption && React__default.createElement(
|
|
18467
|
-
Figure.Caption,
|
|
18468
|
-
null,
|
|
18469
|
-
caption
|
|
18458
|
+
if (uploadDoc && uploadDoc.asset) {
|
|
18459
|
+
if (poster && poster.asset) {
|
|
18460
|
+
return React__default.createElement(
|
|
18461
|
+
Figure,
|
|
18462
|
+
{ className: 'mb-3' },
|
|
18463
|
+
React__default.createElement(
|
|
18464
|
+
'a',
|
|
18465
|
+
{ href: uploadDoc.asset.url, target: blank ? '_blank' : '_self' },
|
|
18466
|
+
React__default.createElement(Figure.Image, { src: urlFor(poster).url(), fluid: true })
|
|
18470
18467
|
)
|
|
18471
|
-
)
|
|
18472
|
-
)
|
|
18473
|
-
|
|
18474
|
-
|
|
18475
|
-
|
|
18476
|
-
{ className: 'd-block text-center mb-3' },
|
|
18477
|
-
React__default.createElement(Figure.Image, {
|
|
18478
|
-
src: urlFor(poster.asset).url()
|
|
18479
|
-
}),
|
|
18480
|
-
caption && React__default.createElement(
|
|
18481
|
-
Figure.Caption,
|
|
18482
|
-
null,
|
|
18468
|
+
);
|
|
18469
|
+
} else if (caption && caption !== '') {
|
|
18470
|
+
return React__default.createElement(
|
|
18471
|
+
'a',
|
|
18472
|
+
{ href: uploadDoc.asset.url, target: blank ? '_blank' : '_self', className: 'd-block text-center' },
|
|
18483
18473
|
caption
|
|
18484
|
-
)
|
|
18485
|
-
|
|
18474
|
+
);
|
|
18475
|
+
}
|
|
18476
|
+
return null;
|
|
18486
18477
|
}
|
|
18478
|
+
return null;
|
|
18487
18479
|
};
|
|
18488
18480
|
|
|
18489
18481
|
return React__default.createElement(
|
|
18490
18482
|
React__default.Fragment,
|
|
18491
18483
|
null,
|
|
18492
|
-
renderFigure(uploadDoc, poster, blank, caption)
|
|
18493
|
-
!poster && uploadDoc && uploadDoc.asset && React__default.createElement(
|
|
18494
|
-
'a',
|
|
18495
|
-
{ href: uploadDoc.asset.url, target: blank ? '_blank' : '_self' },
|
|
18496
|
-
caption
|
|
18497
|
-
)
|
|
18484
|
+
renderFigure(uploadDoc, poster, blank, caption)
|
|
18498
18485
|
);
|
|
18499
18486
|
};
|
|
18500
18487
|
|
|
@@ -25942,12 +25929,8 @@ var getSerializers$1 = function getSerializers(client, pageview, videoAccountIDs
|
|
|
25942
25929
|
},
|
|
25943
25930
|
media: function media(_ref7) {
|
|
25944
25931
|
var node = _ref7.node;
|
|
25945
|
-
var upload_doc = node.upload_doc,
|
|
25946
|
-
poster = node.poster,
|
|
25947
|
-
caption = node.caption,
|
|
25948
|
-
blank = node.blank;
|
|
25949
25932
|
|
|
25950
|
-
return React__default.createElement(Media$2, {
|
|
25933
|
+
return React__default.createElement(Media$2, { node: node, client: client });
|
|
25951
25934
|
},
|
|
25952
25935
|
iframe: function iframe(_ref8) {
|
|
25953
25936
|
var node = _ref8.node;
|
|
@@ -26560,5 +26543,64 @@ var PdfDownload = function PdfDownload(props) {
|
|
|
26560
26543
|
);
|
|
26561
26544
|
};
|
|
26562
26545
|
|
|
26563
|
-
|
|
26546
|
+
var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
|
|
26547
|
+
var parentTaxonomy = _ref.parentTaxonomy,
|
|
26548
|
+
subTaxonomies = _ref.subTaxonomies,
|
|
26549
|
+
_ref$page = _ref.page,
|
|
26550
|
+
page = _ref$page === undefined ? '/' : _ref$page,
|
|
26551
|
+
_ref$exclude = _ref.exclude,
|
|
26552
|
+
exclude = _ref$exclude === undefined ? 'clinical' : _ref$exclude,
|
|
26553
|
+
_ref$variant = _ref.variant,
|
|
26554
|
+
variant = _ref$variant === undefined ? 'primary' : _ref$variant,
|
|
26555
|
+
_ref$className = _ref.className,
|
|
26556
|
+
className = _ref$className === undefined ? '' : _ref$className;
|
|
26557
|
+
|
|
26558
|
+
/*
|
|
26559
|
+
Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
|
|
26560
|
+
example:
|
|
26561
|
+
<RelatedTopicDropdown
|
|
26562
|
+
page='/clinical'
|
|
26563
|
+
exclude="clinical"
|
|
26564
|
+
className='mb-3'
|
|
26565
|
+
parentTaxonomy={props.parentTaxonomy}
|
|
26566
|
+
subTaxonomies={props.subTaxonomies}
|
|
26567
|
+
/>
|
|
26568
|
+
*/
|
|
26569
|
+
if (subTaxonomies.length === 0) {
|
|
26570
|
+
if (parentTaxonomy.identifier == exclude) {
|
|
26571
|
+
return '';
|
|
26572
|
+
}
|
|
26573
|
+
return React__default.createElement(
|
|
26574
|
+
'div',
|
|
26575
|
+
{ id: 'related_dropdown', className: className },
|
|
26576
|
+
React__default.createElement(
|
|
26577
|
+
DropdownButton,
|
|
26578
|
+
{ id: 'related_button', variant: variant, title: 'Related Topics' },
|
|
26579
|
+
React__default.createElement(
|
|
26580
|
+
Dropdown$1.Item,
|
|
26581
|
+
{ href: parentTaxonomy.identifier },
|
|
26582
|
+
parentTaxonomy.name
|
|
26583
|
+
)
|
|
26584
|
+
)
|
|
26585
|
+
);
|
|
26586
|
+
} else {
|
|
26587
|
+
return React__default.createElement(
|
|
26588
|
+
'div',
|
|
26589
|
+
{ id: 'related_dropdown', className: className },
|
|
26590
|
+
React__default.createElement(
|
|
26591
|
+
DropdownButton,
|
|
26592
|
+
{ id: 'related_button', variant: variant, title: 'Related Topics' },
|
|
26593
|
+
subTaxonomies.length > 0 && subTaxonomies.map(function (taxonomy, index) {
|
|
26594
|
+
return React__default.createElement(
|
|
26595
|
+
Dropdown$1.Item,
|
|
26596
|
+
{ key: index, href: page + '/' + taxonomy.identifier },
|
|
26597
|
+
taxonomy.name
|
|
26598
|
+
);
|
|
26599
|
+
})
|
|
26600
|
+
)
|
|
26601
|
+
);
|
|
26602
|
+
}
|
|
26603
|
+
};
|
|
26604
|
+
|
|
26605
|
+
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, TemplateNormal, AD, AD300x250, AD300x250x600, AD728x90, ADFooter, getSerializers$1 as getSerializers, Search, Feature, Breadcrumbs, SetCookie, Hero, AlphabeticList, PdfDownload, RelatedTopicsDropdown };
|
|
26564
26606
|
//# sourceMappingURL=index.es.js.map
|