@civicactions/cmsds-open-data-components 3.8.4-alpha.1 → 3.9.0-alpha.1
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/dist/main.css +39 -29
- package/dist/main.css.map +1 -1
- package/dist/main.js +211 -374
- package/dist/main.js.map +1 -1
- package/dist/types.d.ts +6 -42
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "./main.css";
|
|
2
2
|
import {jsx as $hgUW1$jsx, jsxs as $hgUW1$jsxs, Fragment as $hgUW1$Fragment} from "react/jsx-runtime";
|
|
3
|
-
import {Accordion as $hgUW1$Accordion, AccordionItem as $hgUW1$AccordionItem, Button as $hgUW1$Button, CloseIconThin as $hgUW1$CloseIconThin, ArrowIcon as $hgUW1$ArrowIcon, Spinner as $hgUW1$Spinner, Alert as $hgUW1$Alert, Dialog as $hgUW1$Dialog, TextField as $hgUW1$TextField, Tooltip as $hgUW1$Tooltip,
|
|
3
|
+
import {Accordion as $hgUW1$Accordion, AccordionItem as $hgUW1$AccordionItem, Button as $hgUW1$Button, CloseIconThin as $hgUW1$CloseIconThin, ArrowIcon as $hgUW1$ArrowIcon, Spinner as $hgUW1$Spinner, Alert as $hgUW1$Alert, Dialog as $hgUW1$Dialog, TextField as $hgUW1$TextField, Tooltip as $hgUW1$Tooltip, Dropdown as $hgUW1$Dropdown, Choice as $hgUW1$Choice, Pagination as $hgUW1$Pagination, Badge as $hgUW1$Badge, Table as $hgUW1$Table, TableHead as $hgUW1$TableHead, TableRow as $hgUW1$TableRow, TableCell as $hgUW1$TableCell, TableBody as $hgUW1$TableBody, Tabs as $hgUW1$Tabs, TabPanel as $hgUW1$TabPanel, TooltipIcon as $hgUW1$TooltipIcon} from "@cmsgov/design-system";
|
|
4
4
|
import $hgUW1$react, {createContext as $hgUW1$createContext, useState as $hgUW1$useState, useRef as $hgUW1$useRef, useEffect as $hgUW1$useEffect, useContext as $hgUW1$useContext, useMemo as $hgUW1$useMemo, useCallback as $hgUW1$useCallback} from "react";
|
|
5
|
-
import {NavLink as $hgUW1$NavLink,
|
|
5
|
+
import {NavLink as $hgUW1$NavLink, useSearchParams as $hgUW1$useSearchParams, Link as $hgUW1$Link, useNavigate as $hgUW1$useNavigate, useLocation as $hgUW1$useLocation} from "react-router-dom";
|
|
6
6
|
import $hgUW1$qs from "qs";
|
|
7
7
|
import $hgUW1$axios from "axios";
|
|
8
8
|
import {useQuery as $hgUW1$useQuery, QueryClient as $hgUW1$QueryClient, QueryClientProvider as $hgUW1$QueryClientProvider} from "@tanstack/react-query";
|
|
@@ -275,7 +275,6 @@ var $11500a65bd7d9cf1$export$2e2bcd8739ae039 = $11500a65bd7d9cf1$var$HeaderConte
|
|
|
275
275
|
|
|
276
276
|
|
|
277
277
|
|
|
278
|
-
|
|
279
278
|
const $61ff88fb3f6ee2c8$var$queryClient = new (0, $hgUW1$QueryClient)({
|
|
280
279
|
defaultOptions: {
|
|
281
280
|
queries: {
|
|
@@ -299,37 +298,19 @@ var $61ff88fb3f6ee2c8$export$2e2bcd8739ae039 = $61ff88fb3f6ee2c8$var$withQueryPr
|
|
|
299
298
|
|
|
300
299
|
|
|
301
300
|
|
|
302
|
-
|
|
303
301
|
const $4808982eba3feb88$var$DatasetListSubmenuItem = (props)=>{
|
|
304
|
-
const
|
|
305
|
-
minWidth: 1024
|
|
306
|
-
});
|
|
307
|
-
const { title: title, identifier: identifier, paginationEnabled: paginationEnabled, dataDictionaryLinks: dataDictionaryLinks } = props;
|
|
308
|
-
let linkContainerClasses = "ds-u-margin-bottom--2";
|
|
309
|
-
if (dataDictionaryLinks) linkContainerClasses += " ds-l-col--6 ds-u-padding-right--0";
|
|
310
|
-
else linkContainerClasses += " ds-l-col--auto ds-u-padding-left--0";
|
|
311
|
-
let linkClasses = "ds-u-display--block ds-u-text-align--left";
|
|
312
|
-
if (desktop) {
|
|
313
|
-
linkContainerClasses = "ds-u-padding-x--0";
|
|
314
|
-
linkClasses += " ds-l-col--4 ds-l-md-col--auto";
|
|
315
|
-
}
|
|
302
|
+
const { title: title, identifier: identifier, linkClasses: linkClasses } = props;
|
|
316
303
|
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
317
|
-
className: "dc-c-list-item
|
|
318
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)(
|
|
319
|
-
className: `
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
to: `/dataset/${identifier}`,
|
|
325
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)("h2", {
|
|
326
|
-
className: "ds-l-col--12 ds-text-heading--md",
|
|
327
|
-
children: title
|
|
328
|
-
})
|
|
329
|
-
})
|
|
304
|
+
className: "dc-c-list-item",
|
|
305
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$NavLink), {
|
|
306
|
+
className: `ds-u-display-flex ds-u-align-items--center ds-u-text-align--left ${linkClasses}`,
|
|
307
|
+
to: `/dataset/${identifier}`,
|
|
308
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
309
|
+
className: "ds-text-heading--md ds-u-margin-left--0",
|
|
310
|
+
children: title
|
|
330
311
|
})
|
|
331
312
|
})
|
|
332
|
-
});
|
|
313
|
+
}, identifier);
|
|
333
314
|
};
|
|
334
315
|
var $4808982eba3feb88$export$2e2bcd8739ae039 = $4808982eba3feb88$var$DatasetListSubmenuItem;
|
|
335
316
|
|
|
@@ -401,21 +382,20 @@ async function $eff7d34c30f5a0fc$export$2d2256cb46e92ff7(rootUrl, options, ACA)
|
|
|
401
382
|
|
|
402
383
|
|
|
403
384
|
|
|
385
|
+
|
|
404
386
|
const $844981eac9b63865$export$eccc29c8d0ff408 = (0, $hgUW1$createContext)({
|
|
405
387
|
ACA: undefined
|
|
406
388
|
});
|
|
407
389
|
|
|
408
390
|
|
|
409
|
-
const $
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
}, dataDictionaryLinks: dataDictionaryLinks = false } = props;
|
|
391
|
+
const $10bc3aae21fc1572$var$DatasetListSubmenu = ({ rootUrl: rootUrl, enablePagination: enablePagination = true, defaultPageSize: defaultPageSize = 4, defaultSort: defaultSort = {
|
|
392
|
+
defaultSort: "modified",
|
|
393
|
+
defaultOrder: "desc"
|
|
394
|
+
}, dataDictionaryLinks: dataDictionaryLinks = false, location: location, subLinkClasses: subLinkClasses })=>{
|
|
414
395
|
const { ACA: ACA } = (0, $hgUW1$useContext)((0, $844981eac9b63865$export$eccc29c8d0ff408));
|
|
415
396
|
const defaultSortBy = "";
|
|
416
397
|
const defaultSortOrder = "";
|
|
417
398
|
const defaultPage = 1;
|
|
418
|
-
const location = (0, $hgUW1$useLocation)();
|
|
419
399
|
const transformedParams = (0, $eff7d34c30f5a0fc$export$60ec7cc1d341a524)(location.search, defaultSort);
|
|
420
400
|
const [currentResultNumbers, setCurrentResultNumbers] = (0, $hgUW1$useState)({
|
|
421
401
|
total: 0,
|
|
@@ -492,49 +472,43 @@ const $9384a736d4d6f425$var$DatasetListSubmenu = (props)=>{
|
|
|
492
472
|
if (data && data.data.total && totalItems != data.data.total) setTotalItems(data.data.total);
|
|
493
473
|
return /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Fragment), {
|
|
494
474
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("section", {
|
|
495
|
-
className: "
|
|
496
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)(
|
|
497
|
-
className: "ds-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
475
|
+
className: " dkan-c-site-menu--sub-menu",
|
|
476
|
+
children: isPending ? /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Spinner), {
|
|
477
|
+
className: "ds-u-valign--middle",
|
|
478
|
+
"aria-valuetext": "Dataset Search loading",
|
|
479
|
+
role: "status"
|
|
480
|
+
}) : /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
481
|
+
children: [
|
|
482
|
+
/*#__PURE__*/ (0, $hgUW1$jsxs)("ol", {
|
|
483
|
+
className: "dc-dataset-search-list ds-u-padding--0 ds-u-margin-top--0 ds-u-lg-margin-top--2 ds-u-margin-bottom--2 ds-u-display--block",
|
|
484
|
+
"data-testid": "results-list",
|
|
505
485
|
children: [
|
|
506
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)(
|
|
507
|
-
|
|
486
|
+
noResults && /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
487
|
+
variation: "error",
|
|
488
|
+
heading: "No results found."
|
|
508
489
|
}),
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
})
|
|
530
|
-
]
|
|
531
|
-
}),
|
|
532
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
533
|
-
className: "ds-u-display--flex ds-u-justify-content--between ds-u-align-items--end ds-u-flex-wrap--reverse ds-u-sm-flex-wrap--wrap",
|
|
534
|
-
children: enablePagination && /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
535
|
-
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8",
|
|
490
|
+
data && data.data.results ? Object.keys(data.data.results).map((key)=>{
|
|
491
|
+
return data.data.results[key];
|
|
492
|
+
}).map((item)=>{
|
|
493
|
+
return /*#__PURE__*/ (0, $hgUW1$jsx)((0, $4808982eba3feb88$export$2e2bcd8739ae039), {
|
|
494
|
+
title: item.title,
|
|
495
|
+
identifier: item.identifier,
|
|
496
|
+
linkClasses: subLinkClasses
|
|
497
|
+
}, item.identifier);
|
|
498
|
+
}) : /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
499
|
+
variation: "error",
|
|
500
|
+
heading: "Could not connect to the API."
|
|
501
|
+
})
|
|
502
|
+
]
|
|
503
|
+
}),
|
|
504
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
505
|
+
className: "ds-u-display--flex ds-u-justify-content--between ds-u-align-items--center ds-u-border-top--1 ds-u-padding-top--3 ds-u-padding-bottom--2 ds-u-margin-x--3 ds-u-lg-margin-x--0",
|
|
506
|
+
children: enablePagination && /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
507
|
+
children: [
|
|
508
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
509
|
+
className: "",
|
|
536
510
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
537
|
-
className: "ds-u-margin-y--0",
|
|
511
|
+
className: "ds-u-margin-y--0 ds-u-font-size--sm",
|
|
538
512
|
"aria-hidden": "true",
|
|
539
513
|
children: currentResultNumbers && data && /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
540
514
|
children: [
|
|
@@ -545,23 +519,41 @@ const $9384a736d4d6f425$var$DatasetListSubmenu = (props)=>{
|
|
|
545
519
|
]
|
|
546
520
|
})
|
|
547
521
|
})
|
|
522
|
+
}),
|
|
523
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
524
|
+
className: "",
|
|
525
|
+
children: data && data.data.total > 0 && /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Link), {
|
|
526
|
+
className: "ds-u-padding--0 ds-c-button ds-c-button--ghost dkan-c-header--link",
|
|
527
|
+
to: `../whats-new`,
|
|
528
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("span", {
|
|
529
|
+
className: "ds-text-heading--md",
|
|
530
|
+
children: [
|
|
531
|
+
" ",
|
|
532
|
+
`View all ${data.data.total} entries`,
|
|
533
|
+
" "
|
|
534
|
+
]
|
|
535
|
+
})
|
|
536
|
+
})
|
|
548
537
|
})
|
|
549
|
-
|
|
550
|
-
|
|
538
|
+
]
|
|
539
|
+
})
|
|
551
540
|
})
|
|
552
|
-
|
|
541
|
+
]
|
|
553
542
|
})
|
|
554
543
|
})
|
|
555
544
|
});
|
|
556
545
|
};
|
|
557
|
-
var $
|
|
546
|
+
var $10bc3aae21fc1572$export$2e2bcd8739ae039 = (0, $61ff88fb3f6ee2c8$export$2e2bcd8739ae039)($10bc3aae21fc1572$var$DatasetListSubmenu);
|
|
547
|
+
|
|
548
|
+
|
|
558
549
|
|
|
559
550
|
|
|
560
551
|
|
|
561
552
|
|
|
562
553
|
|
|
563
|
-
const $
|
|
564
|
-
|
|
554
|
+
const $6d0cf21faac6a2dd$var$SubMenuStaticList = ({ submenuArray: submenuArray, subLinkClasses: subLinkClasses, setIsExpanded: setIsExpanded })=>{
|
|
555
|
+
// Render a static list of submenu items as listed in the assets/menu.jsx file.
|
|
556
|
+
let submenuItems = submenuArray.map((s)=>{
|
|
565
557
|
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
566
558
|
children: s.external || s.drupalPage ? /*#__PURE__*/ (0, $hgUW1$jsxs)("a", {
|
|
567
559
|
href: s.url,
|
|
@@ -575,7 +567,7 @@ const $4f153ca537d853e5$var$SubMenuStaticItem = (submenuArray, subLinkClasses)=>
|
|
|
575
567
|
}) : /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$NavLink), {
|
|
576
568
|
to: s.url,
|
|
577
569
|
className: `ds-u-display-flex ds-u-align-items--center ${subLinkClasses}`,
|
|
578
|
-
onClick: ()=>setIsExpanded(
|
|
570
|
+
onClick: ()=>setIsExpanded((prev)=>!prev),
|
|
579
571
|
children: [
|
|
580
572
|
s.icon ?? null,
|
|
581
573
|
/*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
@@ -585,19 +577,16 @@ const $4f153ca537d853e5$var$SubMenuStaticItem = (submenuArray, subLinkClasses)=>
|
|
|
585
577
|
})
|
|
586
578
|
}, s.id);
|
|
587
579
|
});
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
rootUrl: rootUrl,
|
|
592
|
-
location: location,
|
|
593
|
-
formClassName: "ds-u-display--flex ds-u-align-items--end ds-u-justify-content--between ds-u-margin-bottom--2",
|
|
594
|
-
fulltextLabelClassName: "",
|
|
595
|
-
fulltextPlaceholder: "",
|
|
596
|
-
fulltextLabel: "Dataset submenu List"
|
|
580
|
+
return /*#__PURE__*/ (0, $hgUW1$jsx)("ul", {
|
|
581
|
+
className: `dkan-c-site-menu--sub-menu`,
|
|
582
|
+
children: submenuItems
|
|
597
583
|
});
|
|
598
584
|
};
|
|
585
|
+
var $6d0cf21faac6a2dd$export$2e2bcd8739ae039 = $6d0cf21faac6a2dd$var$SubMenuStaticList;
|
|
586
|
+
|
|
587
|
+
|
|
599
588
|
const $4f153ca537d853e5$var$SubMenu = ({ link: link, linkClasses: linkClasses, subLinkClasses: subLinkClasses, wrapLabel: wrapLabel = true })=>{
|
|
600
|
-
const [
|
|
589
|
+
const [isExpanded, setIsExpanded] = (0, $hgUW1$useState)(false);
|
|
601
590
|
const headerContext = (0, $hgUW1$react).useContext((0, $11500a65bd7d9cf1$export$2e2bcd8739ae039));
|
|
602
591
|
const innerHtml = wrapLabel ? /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
603
592
|
children: link.label
|
|
@@ -607,10 +596,10 @@ const $4f153ca537d853e5$var$SubMenu = ({ link: link, linkClasses: linkClasses, s
|
|
|
607
596
|
let currentMenu = null;
|
|
608
597
|
if (menu.current) currentMenu = menu.current;
|
|
609
598
|
function handleClickOutside(event) {
|
|
610
|
-
if (currentMenu && !currentMenu.contains(event.target))
|
|
599
|
+
if (currentMenu && !currentMenu.contains(event.target)) setIsExpanded(false);
|
|
611
600
|
}
|
|
612
601
|
function handleFocusOut(event) {
|
|
613
|
-
if (currentMenu && !currentMenu.contains(event.relatedTarget))
|
|
602
|
+
if (currentMenu && !currentMenu.contains(event.relatedTarget)) setIsExpanded(false);
|
|
614
603
|
}
|
|
615
604
|
document.addEventListener("mousedown", handleClickOutside);
|
|
616
605
|
currentMenu?.addEventListener("focusout", handleFocusOut);
|
|
@@ -619,15 +608,26 @@ const $4f153ca537d853e5$var$SubMenu = ({ link: link, linkClasses: linkClasses, s
|
|
|
619
608
|
if (currentMenu) currentMenu.removeEventListener("focusout", handleFocusOut);
|
|
620
609
|
};
|
|
621
610
|
}, [
|
|
622
|
-
|
|
611
|
+
isExpanded
|
|
623
612
|
]);
|
|
624
613
|
let submenuBlock;
|
|
625
614
|
if (link.submenu) {
|
|
626
|
-
if (Array.isArray(link.submenu)) submenuBlock = $
|
|
627
|
-
|
|
615
|
+
if (Array.isArray(link.submenu)) submenuBlock = /*#__PURE__*/ (0, $hgUW1$jsx)((0, $6d0cf21faac6a2dd$export$2e2bcd8739ae039), {
|
|
616
|
+
submenuArray: link.submenu,
|
|
617
|
+
subLinkClasses: subLinkClasses,
|
|
618
|
+
setIsExpanded: setIsExpanded
|
|
619
|
+
});
|
|
620
|
+
else if (/*#__PURE__*/ (0, $hgUW1$react).isValidElement(link.submenu)) {
|
|
621
|
+
const { rootUrl: rootUrl, location: location } = link.submenu.props;
|
|
622
|
+
submenuBlock = /*#__PURE__*/ (0, $hgUW1$jsx)((0, $10bc3aae21fc1572$export$2e2bcd8739ae039), {
|
|
623
|
+
location: location,
|
|
624
|
+
rootUrl: rootUrl,
|
|
625
|
+
subLinkClasses: subLinkClasses
|
|
626
|
+
});
|
|
627
|
+
}
|
|
628
628
|
}
|
|
629
629
|
return /*#__PURE__*/ (0, $hgUW1$jsxs)("li", {
|
|
630
|
-
className: `dkan-c-nav-submenu has-submenu${
|
|
630
|
+
className: `dkan-c-nav-submenu has-submenu${isExpanded ? " open" : ""}`,
|
|
631
631
|
ref: menu,
|
|
632
632
|
children: [
|
|
633
633
|
/*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Button), {
|
|
@@ -635,23 +635,20 @@ const $4f153ca537d853e5$var$SubMenu = ({ link: link, linkClasses: linkClasses, s
|
|
|
635
635
|
onDark: headerContext.onDark,
|
|
636
636
|
className: `${linkClasses}`,
|
|
637
637
|
"aria-haspopup": "true",
|
|
638
|
-
"aria-expanded":
|
|
638
|
+
"aria-expanded": isExpanded,
|
|
639
639
|
onClick: (e)=>{
|
|
640
640
|
e.preventDefault();
|
|
641
|
-
|
|
641
|
+
setIsExpanded(!isExpanded);
|
|
642
642
|
},
|
|
643
643
|
children: [
|
|
644
644
|
innerHtml,
|
|
645
645
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$ArrowIcon), {
|
|
646
646
|
className: "ds-u-margin-left--1",
|
|
647
|
-
direction:
|
|
647
|
+
direction: isExpanded ? "down" : "right"
|
|
648
648
|
})
|
|
649
649
|
]
|
|
650
650
|
}),
|
|
651
|
-
|
|
652
|
-
className: "dkan-c-site-menu--sub-menu",
|
|
653
|
-
children: submenuBlock
|
|
654
|
-
})
|
|
651
|
+
submenuBlock
|
|
655
652
|
]
|
|
656
653
|
});
|
|
657
654
|
};
|
|
@@ -1101,99 +1098,6 @@ var $59a079354baa335c$export$2e2bcd8739ae039 = $59a079354baa335c$var$Hero;
|
|
|
1101
1098
|
|
|
1102
1099
|
|
|
1103
1100
|
|
|
1104
|
-
const $bd76a91923d7e8a7$var$TransformedDate = ({ date: date, options: options = {
|
|
1105
|
-
year: "numeric",
|
|
1106
|
-
month: "long",
|
|
1107
|
-
day: "numeric",
|
|
1108
|
-
timeZone: "UTC"
|
|
1109
|
-
} })=>{
|
|
1110
|
-
const rawDate = new Date(date);
|
|
1111
|
-
let modifiedDate = "";
|
|
1112
|
-
if (rawDate) modifiedDate = rawDate.toLocaleDateString("en-US", options);
|
|
1113
|
-
return /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Fragment), {
|
|
1114
|
-
children: modifiedDate
|
|
1115
|
-
});
|
|
1116
|
-
};
|
|
1117
|
-
var $bd76a91923d7e8a7$export$2e2bcd8739ae039 = $bd76a91923d7e8a7$var$TransformedDate;
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
const $c068004d499082cc$var$DatasetListItem = (props)=>{
|
|
1122
|
-
const desktop = (0, $hgUW1$useMediaQuery)({
|
|
1123
|
-
minWidth: 1024
|
|
1124
|
-
});
|
|
1125
|
-
const { title: title, modified: modified, identifier: identifier, paginationEnabled: paginationEnabled, dataDictionaryLinks: dataDictionaryLinks } = props;
|
|
1126
|
-
let linkContainerClasses = "ds-u-margin-bottom--2";
|
|
1127
|
-
if (dataDictionaryLinks) linkContainerClasses += " ds-l-col--6 ds-u-padding-right--0";
|
|
1128
|
-
else linkContainerClasses += " ds-l-col--auto ds-u-padding-left--0";
|
|
1129
|
-
let linkClasses = "ds-u-display--block ds-u-text-align--left";
|
|
1130
|
-
if (desktop) {
|
|
1131
|
-
linkContainerClasses = "ds-u-padding-x--0";
|
|
1132
|
-
linkClasses += " ds-l-col--4 ds-l-md-col--auto";
|
|
1133
|
-
}
|
|
1134
|
-
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
1135
|
-
className: "dc-c-list-item ds-u-padding-top--4",
|
|
1136
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1137
|
-
className: `dc-c-searchlist-item ${paginationEnabled ? "ds-u-border-top--1" : "ds-u-border-bottom--1 ds-u-padding-bottom--3"}`,
|
|
1138
|
-
children: [
|
|
1139
|
-
/*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1140
|
-
className: "ds-l-row ds-u-align-items--start",
|
|
1141
|
-
children: [
|
|
1142
|
-
/*#__PURE__*/ (0, $hgUW1$jsxs)("span", {
|
|
1143
|
-
id: `dataset-${identifier}-updated-date`,
|
|
1144
|
-
className: `ds-l-col--12 ds-u-text-align--left ds-text-heading--sm ${paginationEnabled ? "ds-u-padding-top--3" : "ds-u-padding-top--0"}`,
|
|
1145
|
-
children: [
|
|
1146
|
-
"Updated ",
|
|
1147
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $bd76a91923d7e8a7$export$2e2bcd8739ae039), {
|
|
1148
|
-
date: modified
|
|
1149
|
-
})
|
|
1150
|
-
]
|
|
1151
|
-
}),
|
|
1152
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("h2", {
|
|
1153
|
-
className: "ds-l-col--12 ds-text-heading--2xl",
|
|
1154
|
-
children: title
|
|
1155
|
-
})
|
|
1156
|
-
]
|
|
1157
|
-
}),
|
|
1158
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1159
|
-
className: "ds-l-row",
|
|
1160
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1161
|
-
className: "ds-l-col--12 ds-l-md-col--12 ds-u-margin-top--2",
|
|
1162
|
-
children: [
|
|
1163
|
-
"The ",
|
|
1164
|
-
title,
|
|
1165
|
-
" dataset was updated."
|
|
1166
|
-
]
|
|
1167
|
-
})
|
|
1168
|
-
}),
|
|
1169
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1170
|
-
className: "ds-l-row",
|
|
1171
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1172
|
-
className: "ds-l-col--12",
|
|
1173
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1174
|
-
"aria-describedby": `dataset-${identifier}-updated-date`,
|
|
1175
|
-
to: `/dataset/${identifier}`,
|
|
1176
|
-
children: [
|
|
1177
|
-
"View the Dataset for ",
|
|
1178
|
-
title,
|
|
1179
|
-
" "
|
|
1180
|
-
]
|
|
1181
|
-
})
|
|
1182
|
-
})
|
|
1183
|
-
})
|
|
1184
|
-
]
|
|
1185
|
-
})
|
|
1186
|
-
});
|
|
1187
|
-
};
|
|
1188
|
-
var $c068004d499082cc$export$2e2bcd8739ae039 = $c068004d499082cc$var$DatasetListItem;
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
1101
|
|
|
1198
1102
|
|
|
1199
1103
|
|
|
@@ -1432,6 +1336,23 @@ var $b61856b23f5f58a2$export$2e2bcd8739ae039 = $b61856b23f5f58a2$var$LargeFileDi
|
|
|
1432
1336
|
|
|
1433
1337
|
|
|
1434
1338
|
|
|
1339
|
+
const $bd76a91923d7e8a7$var$TransformedDate = ({ date: date, options: options = {
|
|
1340
|
+
year: "numeric",
|
|
1341
|
+
month: "long",
|
|
1342
|
+
day: "numeric",
|
|
1343
|
+
timeZone: "UTC"
|
|
1344
|
+
} })=>{
|
|
1345
|
+
const rawDate = new Date(date);
|
|
1346
|
+
let modifiedDate = "";
|
|
1347
|
+
if (rawDate) modifiedDate = rawDate.toLocaleDateString("en-US", options);
|
|
1348
|
+
return /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Fragment), {
|
|
1349
|
+
children: modifiedDate
|
|
1350
|
+
});
|
|
1351
|
+
};
|
|
1352
|
+
var $bd76a91923d7e8a7$export$2e2bcd8739ae039 = $bd76a91923d7e8a7$var$TransformedDate;
|
|
1353
|
+
|
|
1354
|
+
|
|
1355
|
+
|
|
1435
1356
|
|
|
1436
1357
|
|
|
1437
1358
|
function $1a2bf34e2a8f6b80$export$59a943b34a82e690(textString, textLength = 240) {
|
|
@@ -1450,126 +1371,11 @@ function $1a2bf34e2a8f6b80$export$59a943b34a82e690(textString, textLength = 240)
|
|
|
1450
1371
|
|
|
1451
1372
|
|
|
1452
1373
|
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
const $17711e94d2ce0ee4$var$DatasetDateItem = (props)=>{
|
|
1460
|
-
const { type: type, date: date, boldLabel: boldLabel = false, displayTooltips: displayTooltips = true } = props;
|
|
1461
|
-
const dateText = {
|
|
1462
|
-
modified: "Last Modified",
|
|
1463
|
-
released: "Released",
|
|
1464
|
-
refresh: "Planned Update"
|
|
1465
|
-
};
|
|
1466
|
-
const tooltipContent = {
|
|
1467
|
-
modified: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
1468
|
-
children: [
|
|
1469
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("strong", {
|
|
1470
|
-
children: "Last Modified: "
|
|
1471
|
-
}),
|
|
1472
|
-
" The date the ",
|
|
1473
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("br", {}),
|
|
1474
|
-
"dataset was last updated."
|
|
1475
|
-
]
|
|
1476
|
-
}),
|
|
1477
|
-
released: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
1478
|
-
children: [
|
|
1479
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("strong", {
|
|
1480
|
-
children: "Released: "
|
|
1481
|
-
}),
|
|
1482
|
-
" The date the most ",
|
|
1483
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("br", {}),
|
|
1484
|
-
"recent dataset was made available",
|
|
1485
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("br", {}),
|
|
1486
|
-
"to the public."
|
|
1487
|
-
]
|
|
1488
|
-
}),
|
|
1489
|
-
refresh: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
1490
|
-
children: [
|
|
1491
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("strong", {
|
|
1492
|
-
children: "Planned Update:"
|
|
1493
|
-
}),
|
|
1494
|
-
" The date the ",
|
|
1495
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("br", {}),
|
|
1496
|
-
"dataset is scheduled to be updated."
|
|
1497
|
-
]
|
|
1498
|
-
})
|
|
1499
|
-
};
|
|
1500
|
-
return /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1501
|
-
className: `dataset-date-item${boldLabel ? " bold-label" : ""}`,
|
|
1502
|
-
children: [
|
|
1503
|
-
/*#__PURE__*/ (0, $hgUW1$jsxs)("span", {
|
|
1504
|
-
className: "dataset-data-item-label",
|
|
1505
|
-
children: [
|
|
1506
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1507
|
-
children: dateText[type]
|
|
1508
|
-
}),
|
|
1509
|
-
": ",
|
|
1510
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $bd76a91923d7e8a7$export$2e2bcd8739ae039), {
|
|
1511
|
-
date: date
|
|
1512
|
-
})
|
|
1513
|
-
]
|
|
1514
|
-
}),
|
|
1515
|
-
displayTooltips === true && /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Tooltip), {
|
|
1516
|
-
"aria-label": dateText[type],
|
|
1517
|
-
className: "ds-c-tooltip__trigger-icon ds-u-display--inline ds-u-padding-left--0 ds-uw-padding-right--0",
|
|
1518
|
-
title: tooltipContent[type],
|
|
1519
|
-
placement: "top",
|
|
1520
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$TooltipIcon), {})
|
|
1521
|
-
})
|
|
1522
|
-
]
|
|
1523
|
-
});
|
|
1524
|
-
};
|
|
1525
|
-
var $17711e94d2ce0ee4$export$2e2bcd8739ae039 = $17711e94d2ce0ee4$var$DatasetDateItem;
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
const $20de4fedf33d4f9a$var$DatasetDate = (props)=>{
|
|
1529
|
-
const { date: date, updatedBoldLabel: updatedBoldLabel = false, releasedBoldLabel: releasedBoldLabel = false, refreshBoldLabel: refreshBoldLabel = false, displayTooltips: displayTooltips = true } = props;
|
|
1530
|
-
const { modified: modified, released: released, refresh: refresh } = date;
|
|
1531
|
-
// Create an array of date items to render
|
|
1532
|
-
const dateItems = [];
|
|
1533
|
-
if (modified) dateItems.push(/*#__PURE__*/ (0, $hgUW1$jsx)((0, $17711e94d2ce0ee4$export$2e2bcd8739ae039), {
|
|
1534
|
-
displayTooltips: displayTooltips,
|
|
1535
|
-
type: "modified",
|
|
1536
|
-
date: modified,
|
|
1537
|
-
boldLabel: updatedBoldLabel
|
|
1538
|
-
}, "modified"));
|
|
1539
|
-
if (released) dateItems.push(/*#__PURE__*/ (0, $hgUW1$jsx)((0, $17711e94d2ce0ee4$export$2e2bcd8739ae039), {
|
|
1540
|
-
displayTooltips: displayTooltips,
|
|
1541
|
-
type: "released",
|
|
1542
|
-
date: released,
|
|
1543
|
-
boldLabel: releasedBoldLabel
|
|
1544
|
-
}, "released"));
|
|
1545
|
-
if (refresh) dateItems.push(/*#__PURE__*/ (0, $hgUW1$jsx)((0, $17711e94d2ce0ee4$export$2e2bcd8739ae039), {
|
|
1546
|
-
displayTooltips: displayTooltips,
|
|
1547
|
-
type: "refresh",
|
|
1548
|
-
date: refresh,
|
|
1549
|
-
boldLabel: refreshBoldLabel
|
|
1550
|
-
}, "refresh"));
|
|
1551
|
-
return /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1552
|
-
className: "dataset-date",
|
|
1553
|
-
children: dateItems.map((item, index)=>/*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$react).Fragment, {
|
|
1554
|
-
children: [
|
|
1555
|
-
item,
|
|
1556
|
-
index < dateItems.length - 1 && /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1557
|
-
className: "bullet-point",
|
|
1558
|
-
children: "\u2022"
|
|
1559
|
-
})
|
|
1560
|
-
]
|
|
1561
|
-
}, index))
|
|
1562
|
-
});
|
|
1563
|
-
};
|
|
1564
|
-
var $20de4fedf33d4f9a$export$2e2bcd8739ae039 = $20de4fedf33d4f9a$var$DatasetDate;
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
1374
|
const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
1568
1375
|
const desktop = (0, $hgUW1$useMediaQuery)({
|
|
1569
1376
|
minWidth: 1024
|
|
1570
1377
|
});
|
|
1571
|
-
const { title: title, modified: modified, description: description, downloadUrl: downloadUrl, largeFile: largeFile = false, paginationEnabled: paginationEnabled, dataDictionaryLinks: dataDictionaryLinks
|
|
1572
|
-
const location = (0, $hgUW1$useLocation)();
|
|
1378
|
+
const { title: title, modified: modified, description: description, identifier: identifier, downloadUrl: downloadUrl, largeFile: largeFile = false, paginationEnabled: paginationEnabled, dataDictionaryLinks: dataDictionaryLinks } = props;
|
|
1573
1379
|
let linkContainerClasses = "ds-u-margin-bottom--2";
|
|
1574
1380
|
if (dataDictionaryLinks) linkContainerClasses += " ds-l-col--6 ds-u-padding-right--0";
|
|
1575
1381
|
else linkContainerClasses += " ds-l-col--auto ds-u-padding-left--0";
|
|
@@ -1578,53 +1384,19 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1578
1384
|
linkContainerClasses = "ds-u-padding-x--0";
|
|
1579
1385
|
linkClasses += " ds-l-col--4 ds-l-md-col--auto";
|
|
1580
1386
|
}
|
|
1581
|
-
let themes;
|
|
1582
|
-
if (theme && showTopics) themes = /*#__PURE__*/ (0, $hgUW1$jsx)("ul", {
|
|
1583
|
-
className: "theme-list item-theme",
|
|
1584
|
-
children: theme.map((topic, index)=>{
|
|
1585
|
-
const title = topic || "Unknown Topic";
|
|
1586
|
-
const prefix = "topics";
|
|
1587
|
-
// Use the provided slug or fallback to a simple slug generation
|
|
1588
|
-
const slug = topicSlugs?.[title];
|
|
1589
|
-
const link = `/${prefix}/${slug}`;
|
|
1590
|
-
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
1591
|
-
className: "ds-u-fill--primary ds-u-radius--pill",
|
|
1592
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Link), {
|
|
1593
|
-
to: link,
|
|
1594
|
-
state: {
|
|
1595
|
-
fromUrl: location.pathname,
|
|
1596
|
-
fromTitle: false,
|
|
1597
|
-
fromSearchList: location.pathname.includes("search")
|
|
1598
|
-
},
|
|
1599
|
-
children: title
|
|
1600
|
-
})
|
|
1601
|
-
}, `dist-${title}-${index}`);
|
|
1602
|
-
})
|
|
1603
|
-
});
|
|
1604
|
-
const date = {
|
|
1605
|
-
modified: modified,
|
|
1606
|
-
released: released,
|
|
1607
|
-
refresh: refresh
|
|
1608
|
-
};
|
|
1609
|
-
const url = `/dataset/${identifier}`;
|
|
1610
1387
|
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
1611
1388
|
className: "dc-c-search-list-item ds-u-padding-top--3",
|
|
1612
1389
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1613
1390
|
className: `dc-c-searchlist-item ${paginationEnabled ? "ds-u-border-top--1" : "ds-u-border-bottom--1 ds-u-padding-bottom--3"}`,
|
|
1614
1391
|
children: [
|
|
1615
|
-
themes,
|
|
1616
1392
|
/*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1617
1393
|
className: "ds-l-row ds-u-align-items--start",
|
|
1618
1394
|
children: [
|
|
1619
|
-
|
|
1395
|
+
/*#__PURE__*/ (0, $hgUW1$jsxs)("span", {
|
|
1620
1396
|
id: `dataset-${identifier}-updated-date`,
|
|
1621
1397
|
className: `ds-l-col--12 ds-u-text-align--right ${paginationEnabled ? "ds-u-padding-top--2" : "ds-u-padding-top--0"}`,
|
|
1622
1398
|
children: [
|
|
1623
|
-
|
|
1624
|
-
className: "ds-u-font-weight--bold",
|
|
1625
|
-
children: "Updated:"
|
|
1626
|
-
}),
|
|
1627
|
-
" ",
|
|
1399
|
+
"Updated ",
|
|
1628
1400
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $bd76a91923d7e8a7$export$2e2bcd8739ae039), {
|
|
1629
1401
|
date: modified
|
|
1630
1402
|
})
|
|
@@ -1634,7 +1406,7 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1634
1406
|
className: "ds-l-col--12 ds-text-heading--2xl",
|
|
1635
1407
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Link), {
|
|
1636
1408
|
"aria-describedby": `dataset-${identifier}-updated-date`,
|
|
1637
|
-
to:
|
|
1409
|
+
to: `/dataset/${identifier}`,
|
|
1638
1410
|
children: title
|
|
1639
1411
|
})
|
|
1640
1412
|
})
|
|
@@ -1647,15 +1419,8 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1647
1419
|
children: (0, $1a2bf34e2a8f6b80$export$59a943b34a82e690)(description)
|
|
1648
1420
|
})
|
|
1649
1421
|
}),
|
|
1650
|
-
showDateDetails && /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1651
|
-
className: "dataset-dates",
|
|
1652
|
-
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $20de4fedf33d4f9a$export$2e2bcd8739ae039), {
|
|
1653
|
-
date: date,
|
|
1654
|
-
displayTooltips: false
|
|
1655
|
-
})
|
|
1656
|
-
}),
|
|
1657
1422
|
downloadUrl ? /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1658
|
-
className: `ds-u-margin-top--3 ds-u-padding-left--0
|
|
1423
|
+
className: `ds-u-margin-top--3 ds-u-padding-left--0`,
|
|
1659
1424
|
children: largeFile ? /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1660
1425
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)((0, $b61856b23f5f58a2$export$2e2bcd8739ae039), {
|
|
1661
1426
|
downloadUrl: downloadUrl
|
|
@@ -1680,7 +1445,7 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1680
1445
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1681
1446
|
className: linkClasses,
|
|
1682
1447
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1683
|
-
to:
|
|
1448
|
+
to: `/dataset/${identifier}#data-table`,
|
|
1684
1449
|
children: [
|
|
1685
1450
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $b38839fd67928f42$export$2e2bcd8739ae039), {
|
|
1686
1451
|
id: "data-table"
|
|
@@ -1695,7 +1460,7 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1695
1460
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1696
1461
|
className: linkClasses,
|
|
1697
1462
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1698
|
-
to:
|
|
1463
|
+
to: `/dataset/${identifier}#overview`,
|
|
1699
1464
|
children: [
|
|
1700
1465
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $b38839fd67928f42$export$2e2bcd8739ae039), {
|
|
1701
1466
|
id: "overview"
|
|
@@ -1710,7 +1475,7 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1710
1475
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1711
1476
|
className: linkClasses,
|
|
1712
1477
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1713
|
-
to:
|
|
1478
|
+
to: `/dataset/${identifier}#data-dictionary`,
|
|
1714
1479
|
children: [
|
|
1715
1480
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $b38839fd67928f42$export$2e2bcd8739ae039), {
|
|
1716
1481
|
id: "data-dictionary"
|
|
@@ -1725,7 +1490,7 @@ const $52c6454cae137465$var$DatasetSearchListItem = (props)=>{
|
|
|
1725
1490
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("span", {
|
|
1726
1491
|
className: linkClasses,
|
|
1727
1492
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1728
|
-
to:
|
|
1493
|
+
to: `/dataset/${identifier}#api`,
|
|
1729
1494
|
children: [
|
|
1730
1495
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $b38839fd67928f42$export$2e2bcd8739ae039), {
|
|
1731
1496
|
id: "api"
|
|
@@ -1750,6 +1515,81 @@ var $52c6454cae137465$export$2e2bcd8739ae039 = $52c6454cae137465$var$DatasetSear
|
|
|
1750
1515
|
|
|
1751
1516
|
|
|
1752
1517
|
|
|
1518
|
+
const $c068004d499082cc$var$DatasetListItem = (props)=>{
|
|
1519
|
+
const desktop = (0, $hgUW1$useMediaQuery)({
|
|
1520
|
+
minWidth: 1024
|
|
1521
|
+
});
|
|
1522
|
+
const { title: title, modified: modified, identifier: identifier, paginationEnabled: paginationEnabled, dataDictionaryLinks: dataDictionaryLinks } = props;
|
|
1523
|
+
let linkContainerClasses = "ds-u-margin-bottom--2";
|
|
1524
|
+
if (dataDictionaryLinks) linkContainerClasses += " ds-l-col--6 ds-u-padding-right--0";
|
|
1525
|
+
else linkContainerClasses += " ds-l-col--auto ds-u-padding-left--0";
|
|
1526
|
+
let linkClasses = "ds-u-display--block ds-u-text-align--left";
|
|
1527
|
+
if (desktop) {
|
|
1528
|
+
linkContainerClasses = "ds-u-padding-x--0";
|
|
1529
|
+
linkClasses += " ds-l-col--4 ds-l-md-col--auto";
|
|
1530
|
+
}
|
|
1531
|
+
return /*#__PURE__*/ (0, $hgUW1$jsx)("li", {
|
|
1532
|
+
className: "dc-c-list-item ds-u-padding-top--4",
|
|
1533
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1534
|
+
className: `dc-c-searchlist-item ${paginationEnabled ? "ds-u-border-top--1" : "ds-u-border-bottom--1 ds-u-padding-bottom--3"}`,
|
|
1535
|
+
children: [
|
|
1536
|
+
/*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1537
|
+
className: "ds-l-row ds-u-align-items--start",
|
|
1538
|
+
children: [
|
|
1539
|
+
/*#__PURE__*/ (0, $hgUW1$jsxs)("span", {
|
|
1540
|
+
id: `dataset-${identifier}-updated-date`,
|
|
1541
|
+
className: `ds-l-col--12 ds-u-text-align--left ds-text-heading--sm ${paginationEnabled ? "ds-u-padding-top--3" : "ds-u-padding-top--0"}`,
|
|
1542
|
+
children: [
|
|
1543
|
+
"Updated ",
|
|
1544
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $bd76a91923d7e8a7$export$2e2bcd8739ae039), {
|
|
1545
|
+
date: modified
|
|
1546
|
+
})
|
|
1547
|
+
]
|
|
1548
|
+
}),
|
|
1549
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("h2", {
|
|
1550
|
+
className: "ds-l-col--12 ds-text-heading--2xl",
|
|
1551
|
+
children: title
|
|
1552
|
+
})
|
|
1553
|
+
]
|
|
1554
|
+
}),
|
|
1555
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1556
|
+
className: "ds-l-row",
|
|
1557
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
1558
|
+
className: "ds-l-col--12 ds-l-md-col--12 ds-u-margin-top--2",
|
|
1559
|
+
children: [
|
|
1560
|
+
"The ",
|
|
1561
|
+
title,
|
|
1562
|
+
" dataset was updated."
|
|
1563
|
+
]
|
|
1564
|
+
})
|
|
1565
|
+
}),
|
|
1566
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1567
|
+
className: "ds-l-row",
|
|
1568
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
1569
|
+
className: "ds-l-col--12",
|
|
1570
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Link), {
|
|
1571
|
+
"aria-describedby": `dataset-${identifier}-updated-date`,
|
|
1572
|
+
to: `/dataset/${identifier}`,
|
|
1573
|
+
children: [
|
|
1574
|
+
"View the Dataset for ",
|
|
1575
|
+
title,
|
|
1576
|
+
" "
|
|
1577
|
+
]
|
|
1578
|
+
})
|
|
1579
|
+
})
|
|
1580
|
+
})
|
|
1581
|
+
]
|
|
1582
|
+
})
|
|
1583
|
+
});
|
|
1584
|
+
};
|
|
1585
|
+
var $c068004d499082cc$export$2e2bcd8739ae039 = $c068004d499082cc$var$DatasetListItem;
|
|
1586
|
+
|
|
1587
|
+
|
|
1588
|
+
|
|
1589
|
+
|
|
1590
|
+
|
|
1591
|
+
|
|
1592
|
+
|
|
1753
1593
|
|
|
1754
1594
|
|
|
1755
1595
|
const $789279954d8eff7f$var$ApiDocumentation = ({ endpoint: endpoint })=>{
|
|
@@ -4326,7 +4166,7 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4326
4166
|
className: "ds-u-display--flex ds-u-justify-content--between ds-u-align-items--end ds-u-flex-wrap--reverse ds-u-sm-flex-wrap--wrap",
|
|
4327
4167
|
children: [
|
|
4328
4168
|
enablePagination && /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
4329
|
-
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8",
|
|
4169
|
+
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8 ds-u-sm-padding-left--0",
|
|
4330
4170
|
children: [
|
|
4331
4171
|
/*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4332
4172
|
className: "ds-u-margin-y--0",
|
|
@@ -4387,7 +4227,6 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4387
4227
|
if (item.theme.includes(theme)) showLargeFile = true;
|
|
4388
4228
|
});
|
|
4389
4229
|
return /*#__PURE__*/ (0, $hgUW1$jsx)((0, $52c6454cae137465$export$2e2bcd8739ae039), {
|
|
4390
|
-
location: location,
|
|
4391
4230
|
title: item.title,
|
|
4392
4231
|
modified: item.modified,
|
|
4393
4232
|
description: item.description,
|
|
@@ -4446,11 +4285,10 @@ var $e873081a6e8f024e$export$2e2bcd8739ae039 = (0, $61ff88fb3f6ee2c8$export$2e2b
|
|
|
4446
4285
|
|
|
4447
4286
|
|
|
4448
4287
|
|
|
4449
|
-
const $550bcc185f420ff5$var$DatasetList = (
|
|
4450
|
-
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
}, pageTitle: pageTitle = "What's New ", showLargeFileWarning: showLargeFileWarning = false, introText: introText = "", dataDictionaryLinks: dataDictionaryLinks = false } = props;
|
|
4288
|
+
const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enableSort = true, enablePagination: enablePagination = true, defaultPageSize: defaultPageSize = 10, defaultSort: defaultSort = {
|
|
4289
|
+
defaultSort: "modified",
|
|
4290
|
+
defaultOrder: "desc"
|
|
4291
|
+
}, pageTitle: pageTitle = "What's New ", showLargeFileWarning: showLargeFileWarning = false, introText: introText = "", dataDictionaryLinks: dataDictionaryLinks = false })=>{
|
|
4454
4292
|
const { ACA: ACA } = (0, $hgUW1$useContext)((0, $844981eac9b63865$export$eccc29c8d0ff408));
|
|
4455
4293
|
const sortOptions = [
|
|
4456
4294
|
{
|
|
@@ -4617,7 +4455,7 @@ const $550bcc185f420ff5$var$DatasetList = (props)=>{
|
|
|
4617
4455
|
className: "ds-u-display--flex ds-u-justify-content--between ds-u-align-items--end ds-u-flex-wrap--reverse ds-u-sm-flex-wrap--wrap",
|
|
4618
4456
|
children: [
|
|
4619
4457
|
enablePagination && /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
4620
|
-
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8",
|
|
4458
|
+
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8 ds-u-sm-padding-left--0",
|
|
4621
4459
|
children: [
|
|
4622
4460
|
/*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4623
4461
|
className: "ds-u-margin-y--0",
|
|
@@ -4722,7 +4560,6 @@ var $550bcc185f420ff5$export$2e2bcd8739ae039 = (0, $61ff88fb3f6ee2c8$export$2e2b
|
|
|
4722
4560
|
|
|
4723
4561
|
|
|
4724
4562
|
|
|
4725
|
-
|
|
4726
4563
|
const $b4aa9c66f2e86959$var$useMetastoreDataset = (datasetId, rootAPIUrl)=>{
|
|
4727
4564
|
const [dataset, setDataset] = (0, $hgUW1$useState)({
|
|
4728
4565
|
title: "",
|
|
@@ -7660,5 +7497,5 @@ var $90fb213ab8eeb2e7$export$2e2bcd8739ae039 = $90fb213ab8eeb2e7$var$useScrollTo
|
|
|
7660
7497
|
|
|
7661
7498
|
|
|
7662
7499
|
|
|
7663
|
-
export {$e49d4387bed21287$export$2e2bcd8739ae039 as ApiRowLimitNotice, $a8accc31bf9e0bda$export$2e2bcd8739ae039 as CMSTopNav, $c49454ea7d1c4579$export$2e2bcd8739ae039 as ErrorBoundary, $046ded0064bd0a3d$export$2e2bcd8739ae039 as FAQAccordion, $b939b31651e82908$export$2e2bcd8739ae039 as HeaderNav, $1555e1cb3eb7b3e3$export$2e2bcd8739ae039 as HeaderNavIconLink, $fea9297ba4dd394c$export$2e2bcd8739ae039 as HeaderSearch, $9a8892c5ac150556$export$2e2bcd8739ae039 as HeaderSiteTitle, $3c72c298c3a7f21f$export$2e2bcd8739ae039 as HeaderTagline, $403833a4b442d5df$export$2e2bcd8739ae039 as MobileMenuButton, $f57121650539d8c5$export$2e2bcd8739ae039 as NavBar, $953b286f7778640e$export$2e2bcd8739ae039 as SidebarNavigation, $b0968edc60d7d3a4$export$2e2bcd8739ae039 as SidebarPage, $4f153ca537d853e5$export$2e2bcd8739ae039 as SubMenu, $59a079354baa335c$export$2e2bcd8739ae039 as Hero, $
|
|
7500
|
+
export {$e49d4387bed21287$export$2e2bcd8739ae039 as ApiRowLimitNotice, $a8accc31bf9e0bda$export$2e2bcd8739ae039 as CMSTopNav, $c49454ea7d1c4579$export$2e2bcd8739ae039 as ErrorBoundary, $046ded0064bd0a3d$export$2e2bcd8739ae039 as FAQAccordion, $b939b31651e82908$export$2e2bcd8739ae039 as HeaderNav, $1555e1cb3eb7b3e3$export$2e2bcd8739ae039 as HeaderNavIconLink, $fea9297ba4dd394c$export$2e2bcd8739ae039 as HeaderSearch, $9a8892c5ac150556$export$2e2bcd8739ae039 as HeaderSiteTitle, $3c72c298c3a7f21f$export$2e2bcd8739ae039 as HeaderTagline, $403833a4b442d5df$export$2e2bcd8739ae039 as MobileMenuButton, $f57121650539d8c5$export$2e2bcd8739ae039 as NavBar, $953b286f7778640e$export$2e2bcd8739ae039 as SidebarNavigation, $b0968edc60d7d3a4$export$2e2bcd8739ae039 as SidebarPage, $4f153ca537d853e5$export$2e2bcd8739ae039 as SubMenu, $59a079354baa335c$export$2e2bcd8739ae039 as Hero, $52c6454cae137465$export$2e2bcd8739ae039 as DatasetSearchListItem, $c068004d499082cc$export$2e2bcd8739ae039 as DatasetListItem, $10bc3aae21fc1572$export$2e2bcd8739ae039 as DatasetListSubmenu, $789279954d8eff7f$export$2e2bcd8739ae039 as ApiDocumentation, $af099c546cb226c7$export$2e2bcd8739ae039 as ResourceHeader, $626282d9a03c51d5$export$2e2bcd8739ae039 as ResourcePreview, $072291d44ce1834a$export$2e2bcd8739ae039 as ResourceFooter, $ec3e23baa005dc03$export$2e2bcd8739ae039 as Breadcrumb, $bd76a91923d7e8a7$export$2e2bcd8739ae039 as TransformedDate, $d98f94c79ddf4e0e$export$2e2bcd8739ae039 as DataTable, $bdb071ea3a6d3466$export$2e2bcd8739ae039 as SearchInput, $5644ebd2c3dbfd7b$export$eea3a12df15499ca as buildRows, $2ed0091f7e32d1e6$export$2e2bcd8739ae039 as DataTablePageResults, $1a2bf34e2a8f6b80$export$59a943b34a82e690 as truncateText, $c96c4b9ef7203c1f$export$2e2bcd8739ae039 as APIPage, $026cb986f9fea2b1$export$2e2bcd8739ae039 as PageNotFound, $e873081a6e8f024e$export$2e2bcd8739ae039 as DatasetSearch, $550bcc185f420ff5$export$2e2bcd8739ae039 as DatasetList, $a0f13962e513caa1$export$2e2bcd8739ae039 as Dataset, $a35cf16d1488f54e$export$2e2bcd8739ae039 as DatasetTable, $b9af6ce5e2c06331$export$2e2bcd8739ae039 as Header, $a6df0aa147323304$export$2e2bcd8739ae039 as Footer, $669d2782ec2e2250$export$2e2bcd8739ae039 as SpecsAndLimits, $8b67b7ee3fcfb629$export$2e2bcd8739ae039 as StoredQueryPage, $f61ecf9f84951a61$export$2e2bcd8739ae039 as FilteredResource, $bef7bff2823feea2$export$2e2bcd8739ae039 as QueryTitle, $7264a673914aa746$export$2b9377795161999 as buildOperatorOptions, $7264a673914aa746$export$e284ae5d89467c8f as convertUTCToLocalDate, $7264a673914aa746$export$6b5e57d20078142b as cleanText, $7264a673914aa746$export$8049e8f40a9bdfb8 as buildCustomColHeaders, $11500a65bd7d9cf1$export$2e2bcd8739ae039 as HeaderContext, $43a30d745a7bbc86$export$2e2bcd8739ae039 as DataTableContext, $ebda441784d176a5$export$2e2bcd8739ae039 as ManageColumnsContext, $844981eac9b63865$export$eccc29c8d0ff408 as ACAContext, $efc410f5f7ac5ef3$export$2e2bcd8739ae039 as useSearchAPI, $1d3d480a9cfaabe0$export$2e2bcd8739ae039 as useDatastore, $aa4450dcbeef3ac0$export$385a5aba38cc3325 as transformTableSortToQuerySort, $eb7821d186b1a389$export$2e2bcd8739ae039 as useAddLoginLink, $90fb213ab8eeb2e7$export$2e2bcd8739ae039 as useScrollToTop, $b4aa9c66f2e86959$export$2e2bcd8739ae039 as useMetastoreDataset, $61ff88fb3f6ee2c8$export$2e2bcd8739ae039 as withQueryProvider, $6d5c0212e738499b$export$34e95918366a058e as acaToParams, $6da0396069e23175$export$bc27cf7ecf44639d as defaultMetadataMapping};
|
|
7664
7501
|
//# sourceMappingURL=main.js.map
|