@gen3/frontend 0.11.18 → 0.11.20
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/cjs/index.js +197 -90
- package/dist/cjs/index.js.map +1 -1
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.d.ts +4 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.d.ts.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.js +192 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.js.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.stories.d.ts +13 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.stories.d.ts.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.stories.js +53 -0
- package/dist/dts/components/AddtoDataLibrary/AddToDataLibrary.stories.js.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.d.ts +15 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.d.ts.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.js +37 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.js.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.stories.d.ts +13 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.stories.d.ts.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.stories.js +15 -0
- package/dist/dts/components/AddtoDataLibrary/DataLibraryActionButton.stories.js.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/types.d.ts +21 -0
- package/dist/dts/components/AddtoDataLibrary/types.d.ts.map +1 -0
- package/dist/dts/components/AddtoDataLibrary/types.js +2 -0
- package/dist/dts/components/AddtoDataLibrary/types.js.map +1 -0
- package/dist/dts/components/Details/DetailsDrawer.d.ts +2 -2
- package/dist/dts/components/Details/DetailsDrawer.d.ts.map +1 -1
- package/dist/dts/components/Details/DetailsDrawer.js +2 -2
- package/dist/dts/components/Details/DetailsDrawer.js.map +1 -1
- package/dist/dts/components/Providers/Gen3Provider.d.ts +22 -22
- package/dist/dts/components/charts/Charts.d.ts.map +1 -1
- package/dist/dts/components/charts/Charts.js +14 -12
- package/dist/dts/components/charts/Charts.js.map +1 -1
- package/dist/dts/features/Analysis/AnalysisCardCompact.stories.d.ts +6 -6
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/types.d.ts +2 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/types.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.js +30 -4
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.js +1 -1
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.js.map +1 -1
- package/dist/dts/features/Navigation/Footer/FooterColumn.d.ts.map +1 -1
- package/dist/dts/features/Navigation/Footer/FooterColumn.js +3 -0
- package/dist/dts/features/Navigation/Footer/FooterColumn.js.map +1 -1
- package/dist/dts/features/Navigation/Footer/types.d.ts +1 -0
- package/dist/dts/features/Navigation/Footer/types.d.ts.map +1 -1
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.js +4 -4
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.js.map +1 -1
- package/dist/dts/features/Study/StudyDetails/StudyItems.d.ts.map +1 -1
- package/dist/dts/features/Study/StudyDetails/StudyItems.js +9 -5
- package/dist/dts/features/Study/StudyDetails/StudyItems.js.map +1 -1
- package/dist/esm/index.js +197 -90
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +25 -23
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -3
package/dist/esm/index.js
CHANGED
|
@@ -2166,6 +2166,36 @@ const processRangeKeyLabel = (key)=>{
|
|
|
2166
2166
|
}, {});
|
|
2167
2167
|
};
|
|
2168
2168
|
|
|
2169
|
+
const OverflowTooltippedLabel = ({ children, label, className = 'flex-grow font-heading text-md pt-0.5' })=>{
|
|
2170
|
+
const [showTooltip, setShowTooltip] = useState(false);
|
|
2171
|
+
return /*#__PURE__*/ jsx(Tooltip, {
|
|
2172
|
+
label: label,
|
|
2173
|
+
disabled: !showTooltip,
|
|
2174
|
+
position: "top-start",
|
|
2175
|
+
offset: 5,
|
|
2176
|
+
multiline: true,
|
|
2177
|
+
withArrow: true,
|
|
2178
|
+
arrowOffset: 20,
|
|
2179
|
+
classNames: {
|
|
2180
|
+
tooltip: 'bg-base-min bg-opacity-90 text-base-contrast-min shadow-lg font-content font-medium text-xs',
|
|
2181
|
+
arrow: 'bg-base-min bg-opacity-90'
|
|
2182
|
+
},
|
|
2183
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
2184
|
+
className: `${className} truncate ... `,
|
|
2185
|
+
ref: (el)=>{
|
|
2186
|
+
if (el) {
|
|
2187
|
+
if (el.clientWidth < el.scrollWidth) {
|
|
2188
|
+
setShowTooltip(true);
|
|
2189
|
+
} else {
|
|
2190
|
+
setShowTooltip(false);
|
|
2191
|
+
}
|
|
2192
|
+
}
|
|
2193
|
+
},
|
|
2194
|
+
children: children
|
|
2195
|
+
})
|
|
2196
|
+
});
|
|
2197
|
+
};
|
|
2198
|
+
|
|
2169
2199
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
2170
2200
|
function DefaultItemRenderer(_props) {
|
|
2171
2201
|
return /*#__PURE__*/ jsx("span", {
|
|
@@ -2652,16 +2682,25 @@ const LegendRows = ({ data })=>{
|
|
|
2652
2682
|
const limitedRows = moreThanMaxRows ? data.slice(0, MAX_LEGEND_ROWS) : data;
|
|
2653
2683
|
return limitedRows.map((element, elIndex)=>/*#__PURE__*/ jsxs(Table.Tr, {
|
|
2654
2684
|
children: [
|
|
2655
|
-
/*#__PURE__*/
|
|
2656
|
-
children:
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2685
|
+
/*#__PURE__*/ jsx(Table.Td, {
|
|
2686
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
2687
|
+
className: "flex flex-nowrap items-center overflow-hidden",
|
|
2688
|
+
children: [
|
|
2689
|
+
/*#__PURE__*/ jsx(ColorSwatch, {
|
|
2690
|
+
className: "inline-block mr-2 align-middle",
|
|
2691
|
+
size: "1em",
|
|
2692
|
+
radius: "xs",
|
|
2693
|
+
color: chartColors?.[elIndex % chartColors.length] || ''
|
|
2694
|
+
}),
|
|
2695
|
+
/*#__PURE__*/ jsx(OverflowTooltippedLabel, {
|
|
2696
|
+
label: element.key.toString(),
|
|
2697
|
+
children: /*#__PURE__*/ jsx("span", {
|
|
2698
|
+
className: "text-sm font-medium font-content",
|
|
2699
|
+
children: element.key.toString()
|
|
2700
|
+
})
|
|
2701
|
+
})
|
|
2702
|
+
]
|
|
2703
|
+
})
|
|
2665
2704
|
}),
|
|
2666
2705
|
/*#__PURE__*/ jsx(Table.Td, {
|
|
2667
2706
|
className: "text-right",
|
|
@@ -2699,25 +2738,35 @@ const LegendOverflow = ({ chart, data, chartTitle, counts })=>{
|
|
|
2699
2738
|
children: /*#__PURE__*/ jsx(Table, {
|
|
2700
2739
|
withRowBorders: false,
|
|
2701
2740
|
classNames: {
|
|
2702
|
-
table: '',
|
|
2741
|
+
table: 'w-full table-fixed',
|
|
2703
2742
|
td: 'p-1 leading-3'
|
|
2704
2743
|
},
|
|
2705
2744
|
children: /*#__PURE__*/ jsx(Table.Tbody, {
|
|
2706
2745
|
children: data.map((element, elIndex)=>/*#__PURE__*/ jsxs(Table.Tr, {
|
|
2746
|
+
className: `${elIndex === 0 ? 'overflow-hidden text-ellipsis whitespace-nowrap' : 'last:text-right'}`,
|
|
2707
2747
|
children: [
|
|
2708
|
-
/*#__PURE__*/
|
|
2709
|
-
children:
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2748
|
+
/*#__PURE__*/ jsx(Table.Td, {
|
|
2749
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
2750
|
+
className: "flex flex-nowrap items-center",
|
|
2751
|
+
children: [
|
|
2752
|
+
/*#__PURE__*/ jsx(ColorSwatch, {
|
|
2753
|
+
className: "inline-block mr-2 align-middle",
|
|
2754
|
+
size: "1em",
|
|
2755
|
+
radius: "xs",
|
|
2756
|
+
color: chartColors?.[elIndex % chartColors.length] || ''
|
|
2757
|
+
}),
|
|
2758
|
+
/*#__PURE__*/ jsx(OverflowTooltippedLabel, {
|
|
2759
|
+
label: element.key.toString(),
|
|
2760
|
+
children: /*#__PURE__*/ jsx("span", {
|
|
2761
|
+
className: "text-sm font-medium font-content",
|
|
2762
|
+
children: element.key.toString()
|
|
2763
|
+
})
|
|
2764
|
+
})
|
|
2765
|
+
]
|
|
2766
|
+
})
|
|
2718
2767
|
}),
|
|
2719
2768
|
/*#__PURE__*/ jsx(Table.Td, {
|
|
2720
|
-
className: "text-right",
|
|
2769
|
+
className: "w-[10%] text-right",
|
|
2721
2770
|
children: element.count
|
|
2722
2771
|
})
|
|
2723
2772
|
]
|
|
@@ -2795,31 +2844,35 @@ const Charts = ({ charts, data, counts, isSuccess, numCols = DEFAULT_COLS, style
|
|
|
2795
2844
|
inheritPadding: true,
|
|
2796
2845
|
py: "xs",
|
|
2797
2846
|
withBorder: style === 'box',
|
|
2798
|
-
children: /*#__PURE__*/
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2847
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
2848
|
+
className: "w-full",
|
|
2849
|
+
children: /*#__PURE__*/ jsxs(Table, {
|
|
2850
|
+
withRowBorders: false,
|
|
2851
|
+
classNames: {
|
|
2852
|
+
table: 'w-full table-fixed',
|
|
2853
|
+
td: 'p-1 leading-3',
|
|
2854
|
+
th: 'p-1 leading-3 [text-shadow:_1px_0_#000]',
|
|
2855
|
+
thead: 'border-b',
|
|
2856
|
+
tbody: "before:content-[''] before:block before:p-1"
|
|
2857
|
+
},
|
|
2858
|
+
children: [
|
|
2859
|
+
/*#__PURE__*/ jsx(Table.Thead, {
|
|
2860
|
+
children: /*#__PURE__*/ jsx(Table.Tr, {
|
|
2861
|
+
children: dataKeys.map((el, i)=>/*#__PURE__*/ jsx(Table.Th, {
|
|
2862
|
+
className: `${i === 0 ? 'w-[90%] overflow-hidden text-ellipsis whitespace-nowrap' : 'last:text-right'}`,
|
|
2863
|
+
children: charts[field]?.dataLabels?.[el] || /*#__PURE__*/ jsx(React__default.Fragment, {
|
|
2864
|
+
children: " "
|
|
2865
|
+
})
|
|
2866
|
+
}, i))
|
|
2867
|
+
})
|
|
2868
|
+
}),
|
|
2869
|
+
/*#__PURE__*/ jsx(Table.Tbody, {
|
|
2870
|
+
children: data === undefined ? '' : /*#__PURE__*/ jsx(LegendRows, {
|
|
2871
|
+
data: data[field]
|
|
2872
|
+
})
|
|
2820
2873
|
})
|
|
2821
|
-
|
|
2822
|
-
|
|
2874
|
+
]
|
|
2875
|
+
})
|
|
2823
2876
|
})
|
|
2824
2877
|
}),
|
|
2825
2878
|
showLegends && moreThanMaxRows && /*#__PURE__*/ jsx(Card.Section, {
|
|
@@ -3850,36 +3903,6 @@ flex items-start justify-between items-center flex-nowrap bg-secondary px-1.5 ro
|
|
|
3850
3903
|
});
|
|
3851
3904
|
};
|
|
3852
3905
|
|
|
3853
|
-
const OverflowTooltippedLabel = ({ children, label, className = 'flex-grow font-heading text-md pt-0.5' })=>{
|
|
3854
|
-
const [showTooltip, setShowTooltip] = useState(false);
|
|
3855
|
-
return /*#__PURE__*/ jsx(Tooltip, {
|
|
3856
|
-
label: label,
|
|
3857
|
-
disabled: !showTooltip,
|
|
3858
|
-
position: "top-start",
|
|
3859
|
-
offset: 5,
|
|
3860
|
-
multiline: true,
|
|
3861
|
-
withArrow: true,
|
|
3862
|
-
arrowOffset: 20,
|
|
3863
|
-
classNames: {
|
|
3864
|
-
tooltip: 'bg-base-min bg-opacity-90 text-base-contrast-min shadow-lg font-content font-medium text-xs',
|
|
3865
|
-
arrow: 'bg-base-min bg-opacity-90'
|
|
3866
|
-
},
|
|
3867
|
-
children: /*#__PURE__*/ jsx("div", {
|
|
3868
|
-
className: `${className} truncate ... `,
|
|
3869
|
-
ref: (el)=>{
|
|
3870
|
-
if (el) {
|
|
3871
|
-
if (el.clientWidth < el.scrollWidth) {
|
|
3872
|
-
setShowTooltip(true);
|
|
3873
|
-
} else {
|
|
3874
|
-
setShowTooltip(false);
|
|
3875
|
-
}
|
|
3876
|
-
}
|
|
3877
|
-
},
|
|
3878
|
-
children: children
|
|
3879
|
-
})
|
|
3880
|
-
});
|
|
3881
|
-
};
|
|
3882
|
-
|
|
3883
3906
|
const FacetEnumList = ({ field, facetName, hooks, valueLabel, isSettings = false, isFacetView = true, isSearching = false, showPercent = false, hideIfEmpty = false, showSorting = true, sort = 'value-dsc', moveValuesToBottom = [], excludeValues = [] })=>{
|
|
3884
3907
|
const [isGroupExpanded, setIsGroupExpanded] = useState(false);
|
|
3885
3908
|
const cardRef = useRef(null);
|
|
@@ -5776,6 +5799,20 @@ const FooterRowComponent = ({ item, rowClassname })=>{
|
|
|
5776
5799
|
case 'Icon':
|
|
5777
5800
|
{
|
|
5778
5801
|
const logo = item[itemType];
|
|
5802
|
+
if (logo.href) {
|
|
5803
|
+
return /*#__PURE__*/ jsx("a", {
|
|
5804
|
+
href: logo.href,
|
|
5805
|
+
target: "_blank",
|
|
5806
|
+
rel: "noopener noreferrer",
|
|
5807
|
+
className: className,
|
|
5808
|
+
children: /*#__PURE__*/ jsx(Image, {
|
|
5809
|
+
src: `${logo.logo}`,
|
|
5810
|
+
width: logo.width,
|
|
5811
|
+
height: logo.height,
|
|
5812
|
+
alt: logo.description
|
|
5813
|
+
})
|
|
5814
|
+
}, `icons-${logo.logo}`);
|
|
5815
|
+
}
|
|
5779
5816
|
return /*#__PURE__*/ jsx(Image, {
|
|
5780
5817
|
src: `${logo.logo}`,
|
|
5781
5818
|
width: logo.width,
|
|
@@ -7211,10 +7248,16 @@ const createFieldRendererElement = (field, resource)=>{
|
|
|
7211
7248
|
json: resource,
|
|
7212
7249
|
path: field.field
|
|
7213
7250
|
});
|
|
7214
|
-
if (resourceFieldValue
|
|
7251
|
+
if (!isArray(resourceFieldValue) || resourceFieldValue.length == 0 || resourceFieldValue[0] === null) {
|
|
7215
7252
|
if (field.includeIfNotAvailable === false) return null;
|
|
7216
|
-
if (field.valueIfNotAvailable)
|
|
7217
|
-
|
|
7253
|
+
if (field.valueIfNotAvailable) {
|
|
7254
|
+
resourceFieldValue = field.valueIfNotAvailable;
|
|
7255
|
+
} else {
|
|
7256
|
+
resourceFieldValue = '';
|
|
7257
|
+
}
|
|
7258
|
+
} else {
|
|
7259
|
+
resourceFieldValue = resourceFieldValue[0];
|
|
7260
|
+
}
|
|
7218
7261
|
const label = field.includeLabel === undefined || field?.includeLabel ? field.name : undefined;
|
|
7219
7262
|
const studyFieldRenderer = StudyDetailsRenderer(field.contentType, field?.renderer ?? 'default');
|
|
7220
7263
|
switch(field.contentType){
|
|
@@ -7471,17 +7514,17 @@ const SinglePageStudyDetailsPanel = ({ data, studyConfig, authorization })=>{
|
|
|
7471
7514
|
children: "Study Details Panel not configured"
|
|
7472
7515
|
});
|
|
7473
7516
|
} else {
|
|
7474
|
-
return studyConfig?.fieldsToShow.map((
|
|
7517
|
+
return studyConfig?.fieldsToShow.map((fieldToShow)=>{
|
|
7475
7518
|
return /*#__PURE__*/ jsx("div", {
|
|
7476
|
-
className: `px-2 ${
|
|
7519
|
+
className: `px-2 ${fieldToShow.groupWidth == 'full' || fieldToShow.groupWidth === undefined ? 'w-full' : 'w-1/2'}`,
|
|
7477
7520
|
children: /*#__PURE__*/ jsxs("div", {
|
|
7478
7521
|
className: "flex flex-col",
|
|
7479
7522
|
children: [
|
|
7480
|
-
|
|
7523
|
+
fieldToShow?.groupName ? /*#__PURE__*/ jsx("div", {
|
|
7481
7524
|
className: "text-lg font-bold",
|
|
7482
|
-
children:
|
|
7525
|
+
children: fieldToShow.groupName
|
|
7483
7526
|
}) : null,
|
|
7484
|
-
|
|
7527
|
+
fieldToShow.fields.map((field)=>{
|
|
7485
7528
|
const element = createFieldRendererElement(field, data);
|
|
7486
7529
|
if (element !== null) {
|
|
7487
7530
|
return /*#__PURE__*/ jsx("div", {
|
|
@@ -7492,7 +7535,7 @@ const SinglePageStudyDetailsPanel = ({ data, studyConfig, authorization })=>{
|
|
|
7492
7535
|
})
|
|
7493
7536
|
]
|
|
7494
7537
|
})
|
|
7495
|
-
}, `${
|
|
7538
|
+
}, `${fieldToShow.fields.join('-')}-details`);
|
|
7496
7539
|
});
|
|
7497
7540
|
}
|
|
7498
7541
|
}, [
|
|
@@ -11396,6 +11439,48 @@ const DetailsModal = ({ title, id, row, classNames, panel, panelProps, onClose,
|
|
|
11396
11439
|
});
|
|
11397
11440
|
};
|
|
11398
11441
|
|
|
11442
|
+
const DetailsDrawer = ({ id, title, panel, panelProps })=>{
|
|
11443
|
+
const [opened, { open, close }] = useDisclosure(id !== undefined);
|
|
11444
|
+
useEffect(()=>{
|
|
11445
|
+
if (id !== undefined) open();
|
|
11446
|
+
else close();
|
|
11447
|
+
}, [
|
|
11448
|
+
close,
|
|
11449
|
+
id,
|
|
11450
|
+
open
|
|
11451
|
+
]);
|
|
11452
|
+
return /*#__PURE__*/ jsxs(Drawer.Root, {
|
|
11453
|
+
opened: opened,
|
|
11454
|
+
onClose: close,
|
|
11455
|
+
size: "50%",
|
|
11456
|
+
position: "right",
|
|
11457
|
+
children: [
|
|
11458
|
+
/*#__PURE__*/ jsx(Drawer.Overlay, {
|
|
11459
|
+
opacity: 0.5,
|
|
11460
|
+
blur: 4
|
|
11461
|
+
}),
|
|
11462
|
+
/*#__PURE__*/ jsxs(Drawer.Content, {
|
|
11463
|
+
children: [
|
|
11464
|
+
/*#__PURE__*/ jsx(Drawer.Header, {
|
|
11465
|
+
children: /*#__PURE__*/ jsx(Button, {
|
|
11466
|
+
leftSection: /*#__PURE__*/ jsx(MdKeyboardDoubleArrowLeft, {}),
|
|
11467
|
+
onClick: close,
|
|
11468
|
+
variant: "outline",
|
|
11469
|
+
children: "Back"
|
|
11470
|
+
})
|
|
11471
|
+
}),
|
|
11472
|
+
/*#__PURE__*/ jsx(Drawer.Body, {
|
|
11473
|
+
children: panel({
|
|
11474
|
+
id: id,
|
|
11475
|
+
...panelProps
|
|
11476
|
+
})
|
|
11477
|
+
})
|
|
11478
|
+
]
|
|
11479
|
+
})
|
|
11480
|
+
]
|
|
11481
|
+
});
|
|
11482
|
+
};
|
|
11483
|
+
|
|
11399
11484
|
// TODO need to type this
|
|
11400
11485
|
const RenderArrayCell = ({ cell })=>{
|
|
11401
11486
|
const value = cell.getValue();
|
|
@@ -11866,7 +11951,10 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
11866
11951
|
pageIndex: 0,
|
|
11867
11952
|
pageSize: 10
|
|
11868
11953
|
});
|
|
11869
|
-
const DetailsComponent =
|
|
11954
|
+
const DetailsComponent = useMemo(()=>{
|
|
11955
|
+
if (!tableConfig?.detailsConfig || !tableConfig?.detailsConfig?.panel || tableConfig?.detailsConfig?.mode === 'none') return null;
|
|
11956
|
+
return tableConfig?.detailsConfig?.panelContainer === 'drawer' ? DetailsDrawer : DetailsModal;
|
|
11957
|
+
}, []);
|
|
11870
11958
|
const [sorting, setSorting] = useState([]);
|
|
11871
11959
|
const [rowSelection, setRowSelection] = useState({});
|
|
11872
11960
|
const [selectedRow, setSelectedRow] = useState(undefined);
|
|
@@ -11959,6 +12047,12 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
11959
12047
|
onPaginationChange: setPagination,
|
|
11960
12048
|
onSortingChange: setSorting,
|
|
11961
12049
|
enableTopToolbar: false,
|
|
12050
|
+
enableExpandAll: false,
|
|
12051
|
+
displayColumnDefOptions: {
|
|
12052
|
+
'mrt-row-expand': {
|
|
12053
|
+
enableHiding: true
|
|
12054
|
+
}
|
|
12055
|
+
},
|
|
11962
12056
|
enableExpanding: !!tableConfig?.detailsConfig,
|
|
11963
12057
|
getRowId: getRowId(tableConfig),
|
|
11964
12058
|
rowCount: totalRowCount,
|
|
@@ -11968,6 +12062,16 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
11968
12062
|
localization: {
|
|
11969
12063
|
rowsPerPage: limitLabel
|
|
11970
12064
|
},
|
|
12065
|
+
// mantineExpandAllButtonProps: {
|
|
12066
|
+
// style: {
|
|
12067
|
+
// visibility: 'hidden',
|
|
12068
|
+
// },
|
|
12069
|
+
// },
|
|
12070
|
+
// mantineExpandButtonProps: {
|
|
12071
|
+
// style: {
|
|
12072
|
+
// visibility: 'hidden',
|
|
12073
|
+
// },
|
|
12074
|
+
// },
|
|
11971
12075
|
mantineTableProps: {
|
|
11972
12076
|
style: {
|
|
11973
12077
|
backgroundColor: 'var(--mantine-color-base-1)',
|
|
@@ -11999,7 +12103,10 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
11999
12103
|
showProgressBars: isFetching,
|
|
12000
12104
|
showAlertBanner: isError,
|
|
12001
12105
|
density: 'xs',
|
|
12002
|
-
rowSelection: rowSelection
|
|
12106
|
+
rowSelection: rowSelection,
|
|
12107
|
+
columnVisibility: {
|
|
12108
|
+
'mrt-row-expand': false
|
|
12109
|
+
}
|
|
12003
12110
|
},
|
|
12004
12111
|
mantineTableBodyRowProps: tableConfig.detailsConfig?.mode === 'click' ? ({ row })=>({
|
|
12005
12112
|
onClick: ()=>{
|
|
@@ -12034,7 +12141,7 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
12034
12141
|
return /*#__PURE__*/ jsx(React__default.Fragment, {
|
|
12035
12142
|
children: /*#__PURE__*/ jsxs(StudyProvider, {
|
|
12036
12143
|
children: [
|
|
12037
|
-
|
|
12144
|
+
DetailsComponent && /*#__PURE__*/ jsx(DetailsComponent, {
|
|
12038
12145
|
title: tableConfig?.detailsConfig?.title,
|
|
12039
12146
|
id: Object.keys(rowSelection).length > 0 ? Object.keys(rowSelection).at(0) : undefined,
|
|
12040
12147
|
row: selectedRow,
|
|
@@ -12047,7 +12154,7 @@ const DEFAULT_PAGE_LIMIT = 10000;
|
|
|
12047
12154
|
...tableConfig?.detailsConfig?.params ?? {},
|
|
12048
12155
|
accessibility
|
|
12049
12156
|
}
|
|
12050
|
-
})
|
|
12157
|
+
}),
|
|
12051
12158
|
/*#__PURE__*/ jsx("div", {
|
|
12052
12159
|
className: "inline-block overflow-x-scroll",
|
|
12053
12160
|
children: /*#__PURE__*/ jsx(MantineReactTable, {
|
|
@@ -16307,7 +16414,7 @@ const CohortManagerPanel = ({ indexResources, remoteSupportService, size = 'md'
|
|
|
16307
16414
|
]);
|
|
16308
16415
|
useDeepCompareEffect(()=>{
|
|
16309
16416
|
if (!currentCohort) {
|
|
16310
|
-
setCurrentCohortId(allCohorts[0].id);
|
|
16417
|
+
appDispatch(setCurrentCohortId(allCohorts[0].id));
|
|
16311
16418
|
}
|
|
16312
16419
|
}, [
|
|
16313
16420
|
allCohorts,
|