@civicactions/cmsds-open-data-components 4.0.4-alpha.0 → 4.0.4-oe
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.js +149 -129
- package/dist/main.js.map +1 -1
- package/dist/types.d.ts +26 -26
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -2258,15 +2258,19 @@ function $7264a673914aa746$export$2b9377795161999(type) {
|
|
|
2258
2258
|
|
|
2259
2259
|
|
|
2260
2260
|
|
|
2261
|
-
const $64a351d3fd8413c3$var$HeaderResizeElement = ({ table: table, header: header, sortElement: sortElement, setAriaLiveFeedback: setAriaLiveFeedback })=>{
|
|
2261
|
+
const $64a351d3fd8413c3$var$HeaderResizeElement = ({ table: table, header: header, sortElement: sortElement, setAriaLiveFeedback: setAriaLiveFeedback, id: id })=>{
|
|
2262
2262
|
const [columnResizing, setColumnResizing] = (0, $hgUW1$useState)("");
|
|
2263
|
+
// Fix for JSX in Data Dictionary Title header cell
|
|
2264
|
+
const ariaLabel = header.id === "titleResizable" ? "Title" : header.column.columnDef.header;
|
|
2263
2265
|
return /*#__PURE__*/ (0, $hgUW1$jsxs)("th", {
|
|
2264
2266
|
key: header.id,
|
|
2265
2267
|
style: {
|
|
2266
2268
|
width: header.getSize()
|
|
2267
2269
|
},
|
|
2270
|
+
id: id,
|
|
2268
2271
|
title: typeof header.column.columnDef.header === "string" ? header.column.columnDef.header : "",
|
|
2269
2272
|
className: "ds-u-border-y--2 ds-u-padding--2 ds-u-border--dark ds-u-font-weight--bold",
|
|
2273
|
+
"aria-sort": header.column.getIsSorted() === "asc" ? "ascending" : header.column.getIsSorted() === "desc" ? "descending" : "none",
|
|
2270
2274
|
children: [
|
|
2271
2275
|
/*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
2272
2276
|
className: "ds-u-display--flex",
|
|
@@ -2279,7 +2283,7 @@ const $64a351d3fd8413c3$var$HeaderResizeElement = ({ table: table, header: heade
|
|
|
2279
2283
|
sortElement && /*#__PURE__*/ (0, $hgUW1$jsx)("button", {
|
|
2280
2284
|
onClick: header.column.getToggleSortingHandler(),
|
|
2281
2285
|
className: header.column.getCanSort() ? `cursor-pointer select-none ds-u-focus-visible ${sortElement(header.column.getIsSorted())}` : "",
|
|
2282
|
-
"aria-label": `${
|
|
2286
|
+
"aria-label": `${ariaLabel} sort order`
|
|
2283
2287
|
})
|
|
2284
2288
|
]
|
|
2285
2289
|
}),
|
|
@@ -2287,7 +2291,7 @@ const $64a351d3fd8413c3$var$HeaderResizeElement = ({ table: table, header: heade
|
|
|
2287
2291
|
onMouseDown: header.getResizeHandler(),
|
|
2288
2292
|
onTouchStart: header.getResizeHandler(),
|
|
2289
2293
|
className: `dc-c-resize-handle ds-u-focus-visible ${header.column.getIsResizing() || header.column.id == columnResizing ? "isResizing" : ""}`,
|
|
2290
|
-
"aria-label": `Resize ${
|
|
2294
|
+
"aria-label": `Resize ${ariaLabel} column`,
|
|
2291
2295
|
onKeyDown: (e)=>{
|
|
2292
2296
|
const columnSizingObject = table.getState().columnSizing;
|
|
2293
2297
|
switch(e.key){
|
|
@@ -2373,6 +2377,7 @@ const $23763e27eda0e8d7$var$FixedSizeTHead = ({ table: table, sortElement: sortE
|
|
|
2373
2377
|
},
|
|
2374
2378
|
title: header.column.columnDef.header,
|
|
2375
2379
|
className: "ds-u-border-y--2 ds-u-padding--2 ds-u-border--dark ds-u-font-weight--bold",
|
|
2380
|
+
"aria-sort": header.column.getIsSorted() === "asc" ? "ascending" : header.column.getIsSorted() === "desc" ? "descending" : "none",
|
|
2376
2381
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
2377
2382
|
onClick: header.column.getToggleSortingHandler(),
|
|
2378
2383
|
className: "ds-u-display--flex",
|
|
@@ -4539,42 +4544,6 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4539
4544
|
window.history.pushState({}, "", `${url.origin}${url.pathname}${urlString}`);
|
|
4540
4545
|
}
|
|
4541
4546
|
const pageSize = defaultPageSize;
|
|
4542
|
-
(0, $hgUW1$useEffect)(()=>{
|
|
4543
|
-
const baseNumber = Number(totalItems) > 0 ? 1 : 0;
|
|
4544
|
-
const startingNumber = baseNumber + (Number(pageSize) * Number(page) - Number(pageSize));
|
|
4545
|
-
const endingNumber = Number(pageSize) * Number(page);
|
|
4546
|
-
setCurrentResultNumbers({
|
|
4547
|
-
total: Number(totalItems),
|
|
4548
|
-
startingNumber: Number(totalItems) >= startingNumber ? startingNumber : 0,
|
|
4549
|
-
endingNumber: Number(totalItems) < endingNumber ? Number(totalItems) : endingNumber
|
|
4550
|
-
});
|
|
4551
|
-
setTimeout(()=>{
|
|
4552
|
-
setAnnouncementText(`Showing ${startingNumber} to ${endingNumber} of ${totalItems} datasets`);
|
|
4553
|
-
}, 100);
|
|
4554
|
-
if (totalItems <= 0 && currentResultNumbers !== null) setNoResults(true);
|
|
4555
|
-
else setNoResults(false);
|
|
4556
|
-
}, [
|
|
4557
|
-
totalItems,
|
|
4558
|
-
pageSize,
|
|
4559
|
-
page
|
|
4560
|
-
]);
|
|
4561
|
-
(0, $hgUW1$useEffect)(()=>{
|
|
4562
|
-
if (page !== 1 && (transformedParams.fulltext !== fulltext || transformedParams.selectedFacets !== selectedFacets)) setPage(1);
|
|
4563
|
-
}, [
|
|
4564
|
-
fulltext,
|
|
4565
|
-
selectedFacets
|
|
4566
|
-
]);
|
|
4567
|
-
(0, $hgUW1$useEffect)(()=>{
|
|
4568
|
-
if (totalItems !== null && totalItems !== undefined && totalItems > 0) {
|
|
4569
|
-
var params = buildSearchParams(true);
|
|
4570
|
-
if (params !== location.search) setSearchParams(params);
|
|
4571
|
-
}
|
|
4572
|
-
}, [
|
|
4573
|
-
page,
|
|
4574
|
-
sort,
|
|
4575
|
-
sortOrder,
|
|
4576
|
-
totalItems
|
|
4577
|
-
]);
|
|
4578
4547
|
function resetFilters() {
|
|
4579
4548
|
setFullText(defaultFulltext);
|
|
4580
4549
|
setFilterText(defaultFulltext);
|
|
@@ -4622,6 +4591,50 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4622
4591
|
theme: null,
|
|
4623
4592
|
keyword: null
|
|
4624
4593
|
};
|
|
4594
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4595
|
+
const baseNumber = Number(totalItems) > 0 ? 1 : 0;
|
|
4596
|
+
const startingNumber = baseNumber + (Number(pageSize) * Number(page) - Number(pageSize));
|
|
4597
|
+
const endingNumber = Number(pageSize) * Number(page);
|
|
4598
|
+
setCurrentResultNumbers({
|
|
4599
|
+
total: Number(totalItems),
|
|
4600
|
+
startingNumber: Number(totalItems) >= startingNumber ? startingNumber : 0,
|
|
4601
|
+
endingNumber: Number(totalItems) < endingNumber ? Number(totalItems) : endingNumber
|
|
4602
|
+
});
|
|
4603
|
+
if (totalItems <= 0 && currentResultNumbers !== null) setNoResults(true);
|
|
4604
|
+
else setNoResults(false);
|
|
4605
|
+
}, [
|
|
4606
|
+
totalItems,
|
|
4607
|
+
pageSize,
|
|
4608
|
+
page
|
|
4609
|
+
]);
|
|
4610
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4611
|
+
if (page !== 1 && (transformedParams.fulltext !== fulltext || transformedParams.selectedFacets !== selectedFacets)) setPage(1);
|
|
4612
|
+
}, [
|
|
4613
|
+
fulltext,
|
|
4614
|
+
selectedFacets
|
|
4615
|
+
]);
|
|
4616
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4617
|
+
if (totalItems !== null && totalItems !== undefined && totalItems > 0) {
|
|
4618
|
+
var params = buildSearchParams(true);
|
|
4619
|
+
if (params !== location.search) setSearchParams(params);
|
|
4620
|
+
}
|
|
4621
|
+
}, [
|
|
4622
|
+
page,
|
|
4623
|
+
sort,
|
|
4624
|
+
sortOrder,
|
|
4625
|
+
totalItems
|
|
4626
|
+
]);
|
|
4627
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4628
|
+
// No results found
|
|
4629
|
+
if (noResults) setAnnouncementText("No results found.");
|
|
4630
|
+
else if (!isPending && (!data || !data.data.results)) setAnnouncementText("Could not connect to the API.");
|
|
4631
|
+
else setAnnouncementText(`Showing ${currentResultNumbers.startingNumber} to ${currentResultNumbers.endingNumber} of ${currentResultNumbers.total} datasets`);
|
|
4632
|
+
}, [
|
|
4633
|
+
data,
|
|
4634
|
+
isPending,
|
|
4635
|
+
noResults,
|
|
4636
|
+
currentResultNumbers
|
|
4637
|
+
]);
|
|
4625
4638
|
return /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
4626
4639
|
children: [
|
|
4627
4640
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $5723016a5461c1ca$export$2e2bcd8739ae039), {
|
|
@@ -4630,6 +4643,15 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4630
4643
|
/*#__PURE__*/ (0, $hgUW1$jsxs)("section", {
|
|
4631
4644
|
className: "ds-l-container",
|
|
4632
4645
|
children: [
|
|
4646
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4647
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4648
|
+
className: "ds-u-visibility--screen-reader",
|
|
4649
|
+
"aria-live": "assertive",
|
|
4650
|
+
"aria-atomic": "true",
|
|
4651
|
+
"data-testid": "currentResults",
|
|
4652
|
+
children: announcementText
|
|
4653
|
+
})
|
|
4654
|
+
}),
|
|
4633
4655
|
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4634
4656
|
className: "ds-l-row",
|
|
4635
4657
|
children: /*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
@@ -4714,34 +4736,23 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4714
4736
|
/*#__PURE__*/ (0, $hgUW1$jsxs)("div", {
|
|
4715
4737
|
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",
|
|
4716
4738
|
children: [
|
|
4717
|
-
enablePagination && /*#__PURE__*/ (0, $hgUW1$
|
|
4739
|
+
enablePagination && /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4718
4740
|
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--8 ds-u-sm-padding-left--0",
|
|
4719
|
-
children:
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
|
|
4724
|
-
|
|
4725
|
-
|
|
4726
|
-
|
|
4727
|
-
|
|
4728
|
-
|
|
4729
|
-
|
|
4730
|
-
|
|
4731
|
-
|
|
4732
|
-
" datasets"
|
|
4733
|
-
]
|
|
4734
|
-
})
|
|
4735
|
-
}),
|
|
4736
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4737
|
-
className: "ds-u-visibility--screen-reader",
|
|
4738
|
-
role: "status",
|
|
4739
|
-
"aria-live": "assertive",
|
|
4740
|
-
"aria-atomic": "true",
|
|
4741
|
-
"data-testid": "currentResults",
|
|
4742
|
-
children: announcementText
|
|
4741
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4742
|
+
className: "ds-u-margin-y--0",
|
|
4743
|
+
children: currentResultNumbers && data && /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
4744
|
+
children: [
|
|
4745
|
+
"Showing ",
|
|
4746
|
+
currentResultNumbers.startingNumber,
|
|
4747
|
+
" -",
|
|
4748
|
+
" ",
|
|
4749
|
+
currentResultNumbers.endingNumber,
|
|
4750
|
+
" of ",
|
|
4751
|
+
data.data.total,
|
|
4752
|
+
" datasets"
|
|
4753
|
+
]
|
|
4743
4754
|
})
|
|
4744
|
-
|
|
4755
|
+
})
|
|
4745
4756
|
}),
|
|
4746
4757
|
enableSort && /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4747
4758
|
className: "ds-l-col--12 ds-l-sm-col--6 ds-l-md-col--4 ds-u-sm-padding-right--0",
|
|
@@ -4762,6 +4773,7 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4762
4773
|
children: [
|
|
4763
4774
|
noResults && /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
4764
4775
|
variation: "error",
|
|
4776
|
+
role: "region",
|
|
4765
4777
|
heading: "No results found."
|
|
4766
4778
|
}),
|
|
4767
4779
|
data && data.data.results ? Object.keys(data.data.results).map((key)=>{
|
|
@@ -4789,6 +4801,7 @@ const $e873081a6e8f024e$var$DatasetSearch = (props)=>{
|
|
|
4789
4801
|
}, item.identifier);
|
|
4790
4802
|
}) : /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
4791
4803
|
variation: "error",
|
|
4804
|
+
role: "region",
|
|
4792
4805
|
heading: "Could not connect to the API."
|
|
4793
4806
|
})
|
|
4794
4807
|
]
|
|
@@ -4901,37 +4914,6 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
4901
4914
|
}
|
|
4902
4915
|
};
|
|
4903
4916
|
const pageSize = defaultPageSize;
|
|
4904
|
-
(0, $hgUW1$useEffect)(()=>{
|
|
4905
|
-
// Update browser URL with current search params
|
|
4906
|
-
const params = buildSearchParams(true);
|
|
4907
|
-
const url = new URL(window.location.href);
|
|
4908
|
-
window.history.pushState({}, "", `${url.origin}${url.pathname}${params}`);
|
|
4909
|
-
const baseNumber = Number(totalItems) > 0 ? 1 : 0;
|
|
4910
|
-
const startingNumber = baseNumber + (Number(pageSize) * Number(page) - Number(pageSize));
|
|
4911
|
-
const endingNumber = Number(pageSize) * Number(page);
|
|
4912
|
-
setCurrentResultNumbers({
|
|
4913
|
-
total: Number(totalItems),
|
|
4914
|
-
startingNumber: Number(totalItems) >= startingNumber ? startingNumber : 0,
|
|
4915
|
-
endingNumber: Number(totalItems) < endingNumber ? Number(totalItems) : endingNumber
|
|
4916
|
-
});
|
|
4917
|
-
setTimeout(()=>{
|
|
4918
|
-
setAnnouncementText(`Showing ${startingNumber} to ${endingNumber} of ${totalItems} datasets`);
|
|
4919
|
-
}, 100);
|
|
4920
|
-
if (totalItems <= 0 && currentResultNumbers !== null) setNoResults(true);
|
|
4921
|
-
else setNoResults(false);
|
|
4922
|
-
}, [
|
|
4923
|
-
totalItems,
|
|
4924
|
-
pageSize,
|
|
4925
|
-
page
|
|
4926
|
-
]);
|
|
4927
|
-
(0, $hgUW1$useEffect)(()=>{
|
|
4928
|
-
var params = buildSearchParams(true);
|
|
4929
|
-
if (params !== location.search) setSearchParams(params);
|
|
4930
|
-
}, [
|
|
4931
|
-
page,
|
|
4932
|
-
sort,
|
|
4933
|
-
sortOrder
|
|
4934
|
-
]);
|
|
4935
4917
|
function buildSearchParams(includePage) {
|
|
4936
4918
|
let newParams = {};
|
|
4937
4919
|
if (Number(page) !== 1 && includePage) newParams.page = page;
|
|
@@ -4961,6 +4943,45 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
4961
4943
|
}
|
|
4962
4944
|
});
|
|
4963
4945
|
if (data && data.data.total && totalItems != data.data.total) setTotalItems(data.data.total);
|
|
4946
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4947
|
+
// Update browser URL with current search params
|
|
4948
|
+
const params = buildSearchParams(true);
|
|
4949
|
+
const url = new URL(window.location.href);
|
|
4950
|
+
window.history.pushState({}, "", `${url.origin}${url.pathname}${params}`);
|
|
4951
|
+
const baseNumber = Number(totalItems) > 0 ? 1 : 0;
|
|
4952
|
+
const startingNumber = baseNumber + (Number(pageSize) * Number(page) - Number(pageSize));
|
|
4953
|
+
const endingNumber = Number(pageSize) * Number(page);
|
|
4954
|
+
setCurrentResultNumbers({
|
|
4955
|
+
total: Number(totalItems),
|
|
4956
|
+
startingNumber: Number(totalItems) >= startingNumber ? startingNumber : 0,
|
|
4957
|
+
endingNumber: Number(totalItems) < endingNumber ? Number(totalItems) : endingNumber
|
|
4958
|
+
});
|
|
4959
|
+
if (totalItems <= 0 && currentResultNumbers !== null) setNoResults(true);
|
|
4960
|
+
else setNoResults(false);
|
|
4961
|
+
}, [
|
|
4962
|
+
totalItems,
|
|
4963
|
+
pageSize,
|
|
4964
|
+
page
|
|
4965
|
+
]);
|
|
4966
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4967
|
+
var params = buildSearchParams(true);
|
|
4968
|
+
if (params !== location.search) setSearchParams(params);
|
|
4969
|
+
}, [
|
|
4970
|
+
page,
|
|
4971
|
+
sort,
|
|
4972
|
+
sortOrder
|
|
4973
|
+
]);
|
|
4974
|
+
(0, $hgUW1$useEffect)(()=>{
|
|
4975
|
+
// No results found
|
|
4976
|
+
if (noResults) setAnnouncementText("No results found.");
|
|
4977
|
+
else if (!isPending && (!data || !data.data.results)) setAnnouncementText("Could not connect to the API.");
|
|
4978
|
+
else setAnnouncementText(`Showing ${currentResultNumbers.startingNumber} to ${currentResultNumbers.endingNumber} of ${currentResultNumbers.total} datasets`);
|
|
4979
|
+
}, [
|
|
4980
|
+
data,
|
|
4981
|
+
isPending,
|
|
4982
|
+
noResults,
|
|
4983
|
+
currentResultNumbers
|
|
4984
|
+
]);
|
|
4964
4985
|
return /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
4965
4986
|
children: [
|
|
4966
4987
|
/*#__PURE__*/ (0, $hgUW1$jsx)((0, $5723016a5461c1ca$export$2e2bcd8739ae039), {
|
|
@@ -4969,6 +4990,15 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
4969
4990
|
/*#__PURE__*/ (0, $hgUW1$jsxs)("section", {
|
|
4970
4991
|
className: "ds-l-container",
|
|
4971
4992
|
children: [
|
|
4993
|
+
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4994
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
4995
|
+
className: "ds-u-visibility--screen-reader",
|
|
4996
|
+
"aria-live": "assertive",
|
|
4997
|
+
"aria-atomic": "true",
|
|
4998
|
+
"data-testid": "currentResults",
|
|
4999
|
+
children: announcementText
|
|
5000
|
+
})
|
|
5001
|
+
}),
|
|
4972
5002
|
/*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
4973
5003
|
className: "ds-l-row",
|
|
4974
5004
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
@@ -5009,33 +5039,22 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
5009
5039
|
className: "ds-u-margin-bottom--3",
|
|
5010
5040
|
children: introText ? introText : null
|
|
5011
5041
|
}),
|
|
5012
|
-
enablePagination && /*#__PURE__*/ (0, $hgUW1$
|
|
5013
|
-
children:
|
|
5014
|
-
|
|
5015
|
-
|
|
5016
|
-
|
|
5017
|
-
|
|
5018
|
-
|
|
5019
|
-
|
|
5020
|
-
|
|
5021
|
-
|
|
5022
|
-
|
|
5023
|
-
|
|
5024
|
-
|
|
5025
|
-
|
|
5026
|
-
" datasets"
|
|
5027
|
-
]
|
|
5028
|
-
})
|
|
5029
|
-
}),
|
|
5030
|
-
/*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
5031
|
-
className: "ds-u-visibility--screen-reader",
|
|
5032
|
-
role: "status",
|
|
5033
|
-
"aria-live": "assertive",
|
|
5034
|
-
"aria-atomic": "true",
|
|
5035
|
-
"data-testid": "currentResults",
|
|
5036
|
-
children: announcementText
|
|
5042
|
+
enablePagination && /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
5043
|
+
children: /*#__PURE__*/ (0, $hgUW1$jsx)("p", {
|
|
5044
|
+
className: "ds-u-margin-y--0",
|
|
5045
|
+
children: currentResultNumbers && data && /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$Fragment), {
|
|
5046
|
+
children: [
|
|
5047
|
+
"Showing ",
|
|
5048
|
+
currentResultNumbers.startingNumber,
|
|
5049
|
+
" -",
|
|
5050
|
+
" ",
|
|
5051
|
+
currentResultNumbers.endingNumber,
|
|
5052
|
+
" of ",
|
|
5053
|
+
data.data.total,
|
|
5054
|
+
" datasets"
|
|
5055
|
+
]
|
|
5037
5056
|
})
|
|
5038
|
-
|
|
5057
|
+
})
|
|
5039
5058
|
})
|
|
5040
5059
|
]
|
|
5041
5060
|
}),
|
|
@@ -5058,6 +5077,7 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
5058
5077
|
children: [
|
|
5059
5078
|
noResults && /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
5060
5079
|
variation: "error",
|
|
5080
|
+
role: "region",
|
|
5061
5081
|
heading: "No results found."
|
|
5062
5082
|
}),
|
|
5063
5083
|
data && data.data.results ? Object.keys(data.data.results).map((key)=>{
|
|
@@ -5072,6 +5092,7 @@ const $550bcc185f420ff5$var$DatasetList = ({ rootUrl: rootUrl, enableSort: enabl
|
|
|
5072
5092
|
}, item.identifier);
|
|
5073
5093
|
}) : /*#__PURE__*/ (0, $hgUW1$jsx)((0, $hgUW1$Alert), {
|
|
5074
5094
|
variation: "error",
|
|
5095
|
+
role: "region",
|
|
5075
5096
|
heading: "Could not connect to the API."
|
|
5076
5097
|
})
|
|
5077
5098
|
]
|
|
@@ -5941,7 +5962,8 @@ const $6765a74df807d015$var$DataDictionaryTable = ({ tableColumns: tableColumns,
|
|
|
5941
5962
|
table: table,
|
|
5942
5963
|
header: header,
|
|
5943
5964
|
setAriaLiveFeedback: setAriaLiveFeedback,
|
|
5944
|
-
sortElement: sortElement
|
|
5965
|
+
sortElement: sortElement,
|
|
5966
|
+
id: "dataDictionary_" + header.id
|
|
5945
5967
|
}, header.id + "_resize") : /*#__PURE__*/ (0, $hgUW1$jsxs)((0, $hgUW1$TableCell), {
|
|
5946
5968
|
key: header.id,
|
|
5947
5969
|
className: `ds-u-border-y--2 ds-u-border--dark ds-u-border-x--0`,
|
|
@@ -6294,7 +6316,7 @@ const $2bd73bb95b0c04ed$var$DatasetDescription = ({ distribution: distribution,
|
|
|
6294
6316
|
if (distribution.data && distribution.data.description) newDescription = distribution.data.description;
|
|
6295
6317
|
else if (dataset.description) newDescription = dataset.description;
|
|
6296
6318
|
}
|
|
6297
|
-
if (
|
|
6319
|
+
if (description !== newDescription && updateAriaLive) updateAriaLive(newDescription);
|
|
6298
6320
|
setDescription(newDescription);
|
|
6299
6321
|
}, [
|
|
6300
6322
|
resource,
|
|
@@ -6306,11 +6328,9 @@ const $2bd73bb95b0c04ed$var$DatasetDescription = ({ distribution: distribution,
|
|
|
6306
6328
|
className: "ds-u-measure--wide ds-u-margin-bottom--7",
|
|
6307
6329
|
children: /*#__PURE__*/ (0, $hgUW1$jsx)("div", {
|
|
6308
6330
|
className: "ds-u-margin-top--0 dc-c-metadata-description",
|
|
6309
|
-
|
|
6310
|
-
|
|
6311
|
-
|
|
6312
|
-
}
|
|
6313
|
-
}) : description
|
|
6331
|
+
dangerouslySetInnerHTML: {
|
|
6332
|
+
__html: (0, $hgUW1$dompurify).sanitize(description)
|
|
6333
|
+
}
|
|
6314
6334
|
})
|
|
6315
6335
|
});
|
|
6316
6336
|
};
|