@gen3/frontend 0.10.93 → 0.10.95
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 +5530 -3555
- package/dist/cjs/index.js.map +1 -1
- package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts +64 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts.map +1 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.js +38 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.js.map +1 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts +2 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts.map +1 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js +141 -0
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js.map +1 -0
- package/dist/dts/components/DropdownMenu/index.d.ts +3 -0
- package/dist/dts/components/DropdownMenu/index.d.ts.map +1 -0
- package/dist/dts/components/DropdownMenu/index.js +3 -0
- package/dist/dts/components/DropdownMenu/index.js.map +1 -0
- package/dist/dts/components/Login/LoginProvidersPanel.d.ts.map +1 -1
- package/dist/dts/components/Login/LoginProvidersPanel.js +1 -1
- package/dist/dts/components/Login/LoginProvidersPanel.js.map +1 -1
- package/dist/dts/components/MessageCards/EmptyTableMessage.d.ts +5 -0
- package/dist/dts/components/MessageCards/EmptyTableMessage.d.ts.map +1 -0
- package/dist/dts/components/MessageCards/EmptyTableMessage.js +9 -0
- package/dist/dts/components/MessageCards/EmptyTableMessage.js.map +1 -0
- package/dist/dts/components/MessageCards/ErrorMessage.d.ts +7 -0
- package/dist/dts/components/MessageCards/ErrorMessage.d.ts.map +1 -0
- package/dist/dts/components/MessageCards/ErrorMessage.js +8 -0
- package/dist/dts/components/MessageCards/ErrorMessage.js.map +1 -0
- package/dist/dts/components/charts/echarts/BarChart.d.ts.map +1 -1
- package/dist/dts/components/charts/echarts/BarChart.js +42 -4
- package/dist/dts/components/charts/echarts/BarChart.js.map +1 -1
- package/dist/dts/components/charts/echarts/ReactECharts.js +1 -1
- package/dist/dts/components/charts/echarts/ReactECharts.js.map +1 -1
- package/dist/dts/components/charts/utils.d.ts +1 -1
- package/dist/dts/components/charts/utils.d.ts.map +1 -1
- package/dist/dts/components/charts/utils.js +2 -4
- package/dist/dts/components/charts/utils.js.map +1 -1
- package/dist/dts/components/facets/EnumFacet.d.ts +2 -1
- package/dist/dts/components/facets/EnumFacet.d.ts.map +1 -1
- package/dist/dts/components/facets/EnumFacet.js.map +1 -1
- package/dist/dts/components/facets/FacetEnumList.d.ts.map +1 -1
- package/dist/dts/components/facets/FacetEnumList.js +7 -30
- package/dist/dts/components/facets/FacetEnumList.js.map +1 -1
- package/dist/dts/components/facets/FacetSelector.d.ts +1 -1
- package/dist/dts/components/facets/FacetSelector.d.ts.map +1 -1
- package/dist/dts/components/facets/FacetSelector.js +3 -1
- package/dist/dts/components/facets/FacetSelector.js.map +1 -1
- package/dist/dts/components/facets/types.d.ts +1 -0
- package/dist/dts/components/facets/types.d.ts.map +1 -1
- package/dist/dts/components/facets/types.js.map +1 -1
- package/dist/dts/components/facets/utils.d.ts +4 -2
- package/dist/dts/components/facets/utils.d.ts.map +1 -1
- package/dist/dts/components/facets/utils.js +27 -1
- package/dist/dts/components/facets/utils.js.map +1 -1
- package/dist/dts/features/Analysis/AnalysisCardCompact.stories.d.ts +4 -4
- package/dist/dts/features/CohortBuilder/AccessLevel.d.ts +8 -0
- package/dist/dts/features/CohortBuilder/AccessLevel.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/AccessLevel.js +20 -0
- package/dist/dts/features/CohortBuilder/AccessLevel.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortBuilder.d.ts +1 -0
- package/dist/dts/features/CohortBuilder/CohortBuilder.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/CohortBuilder.js +4 -19
- package/dist/dts/features/CohortBuilder/CohortBuilder.js.map +1 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts +20 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js +37 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortManager.d.ts +18 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortManager.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortManager.js +149 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortManager.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts +9 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js +122 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts +19 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js +52 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts +10 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js +37 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts +13 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js +33 -0
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts +7 -0
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.js +80 -0
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts +5 -0
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js +5 -0
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts +5 -0
- package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/index.js +4 -0
- package/dist/dts/features/CohortBuilder/CohortManager/index.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts +13 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js +15 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts +4 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js +8 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts +32 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js +190 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts +2 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js +145 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts +29 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js +79 -0
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts +5 -0
- package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/style.js +21 -0
- package/dist/dts/features/CohortBuilder/CohortManager/style.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts +49 -0
- package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManager/types.js +2 -0
- package/dist/dts/features/CohortBuilder/CohortManager/types.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManagerAndExpression.d.ts +6 -0
- package/dist/dts/features/CohortBuilder/CohortManagerAndExpression.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortManagerAndExpression.js +21 -0
- package/dist/dts/features/CohortBuilder/CohortManagerAndExpression.js.map +1 -0
- package/dist/dts/features/CohortBuilder/CohortPanel.d.ts +6 -2
- package/dist/dts/features/CohortBuilder/CohortPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/CohortPanel.js +15 -19
- package/dist/dts/features/CohortBuilder/CohortPanel.js.map +1 -1
- package/dist/dts/features/CohortBuilder/CohortSelector.d.ts +8 -1
- package/dist/dts/features/CohortBuilder/CohortSelector.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/CohortSelector.js +51 -10
- package/dist/dts/features/CohortBuilder/CohortSelector.js.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ArrayCellRenderer.d.ts +6 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ArrayCellRenderer.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ArrayCellRenderer.js +32 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ArrayCellRenderer.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/QueryRowDetailsPanel.d.ts +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/QueryRowDetailsPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/QueryRowDetailsPanel.js +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/QueryRowDetailsPanel.js.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/types.d.ts +2 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExploreTableDetails/types.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.d.ts +3 -2
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.js +56 -60
- package/dist/dts/features/CohortBuilder/ExplorerTable/ExplorerTable.js.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExpandingSubtable.d.ts +4 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExpandingSubtable.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExpandingSubtable.js +48 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExpandingSubtable.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExplorerTableSubtable.d.ts +4 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExplorerTableSubtable.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExplorerTableSubtable.js +81 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/ExplorerTableSubtable.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableAccordian.d.ts +9 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableAccordian.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableAccordian.js +22 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableAccordian.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableStack.d.ts +9 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableStack.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableStack.js +17 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/SubtableStack.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/types.d.ts +12 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/types.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/types.js +2 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/SubTables/types.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/types.d.ts +52 -12
- package/dist/dts/features/CohortBuilder/ExplorerTable/types.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/utils.d.ts +4 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/utils.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/ExplorerTable/utils.js +70 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/utils.js.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/AccordianPanel.d.ts +1 -1
- package/dist/dts/features/CohortBuilder/Panels/AccordianPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/AccordianPanel.js +2 -2
- package/dist/dts/features/CohortBuilder/Panels/AccordianPanel.js.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/DropdownPanel.d.ts +1 -1
- package/dist/dts/features/CohortBuilder/Panels/DropdownPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/DropdownPanel.js +5 -4
- package/dist/dts/features/CohortBuilder/Panels/DropdownPanel.js.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/TabbedPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/TabbedPanel.js +2 -1
- package/dist/dts/features/CohortBuilder/Panels/TabbedPanel.js.map +1 -1
- package/dist/dts/features/CohortBuilder/Panels/types.d.ts +4 -1
- package/dist/dts/features/CohortBuilder/Panels/types.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/QueryExpression/QueryExpressionSection.js.map +1 -1
- package/dist/dts/features/CohortBuilder/index.d.ts +5 -2
- package/dist/dts/features/CohortBuilder/index.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/index.js +4 -1
- package/dist/dts/features/CohortBuilder/index.js.map +1 -1
- package/dist/dts/features/CohortBuilder/types.d.ts +13 -5
- package/dist/dts/features/CohortBuilder/types.d.ts.map +1 -1
- package/dist/dts/features/CohortBuilder/types.js +6 -0
- package/dist/dts/features/CohortBuilder/types.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/ChartsAndFacetsPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/ChartsAndFacetsPanel.js +19 -11
- package/dist/dts/features/CohortDiscovery/ChartsAndFacetsPanel.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/CohortDiscovery.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/CohortDiscovery.js +23 -8
- package/dist/dts/features/CohortDiscovery/CohortDiscovery.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.d.ts +6 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.js +71 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManager.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerMiddleware.d.ts +2 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerMiddleware.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerMiddleware.js +36 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerMiddleware.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSelectors.d.ts +417 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSelectors.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSelectors.js +45 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSelectors.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSlice.d.ts +95 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSlice.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSlice.js +388 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortManagerSlice.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts +64 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js +574 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/types.d.ts +7 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/types.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/types.js +2 -0
- package/dist/dts/features/CohortDiscovery/CohortManagment/types.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/FacetSelectionPanel.d.ts +1 -1
- package/dist/dts/features/CohortDiscovery/FacetSelectionPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/FacetSelectionPanel.js +1 -1
- package/dist/dts/features/CohortDiscovery/FacetSelectionPanel.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/FilterExpandSlice.d.ts +1 -1
- package/dist/dts/features/CohortDiscovery/FilterExpandSlice.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/FilterExpandSlice.js +1 -1
- package/dist/dts/features/CohortDiscovery/FilterExpandSlice.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/FilterPanels/EnumFacetPanel.d.ts +2 -1
- package/dist/dts/features/CohortDiscovery/FilterPanels/EnumFacetPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/FilterPanels/EnumFacetPanel.js +22 -6
- package/dist/dts/features/CohortDiscovery/FilterPanels/EnumFacetPanel.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/FilterPanels/FacetPanelDataHeader.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/IndexPanel.d.ts +1 -1
- package/dist/dts/features/CohortDiscovery/IndexPanel.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/IndexPanel.js +41 -33
- package/dist/dts/features/CohortDiscovery/IndexPanel.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/Requests/hooks.d.ts +22 -0
- package/dist/dts/features/CohortDiscovery/Requests/hooks.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/Requests/hooks.js +147 -0
- package/dist/dts/features/CohortDiscovery/Requests/hooks.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js +284 -0
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.d.ts +8 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.js +9 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.d.ts +10 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.js +231 -0
- package/dist/dts/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/SelectedFacetsSlice.d.ts +3 -4
- package/dist/dts/features/CohortDiscovery/SelectedFacetsSlice.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/SelectedFacetsSlice.js +6 -11
- package/dist/dts/features/CohortDiscovery/SelectedFacetsSlice.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/TabbedIndex.d.ts +8 -0
- package/dist/dts/features/CohortDiscovery/TabbedIndex.d.ts.map +1 -0
- package/dist/dts/features/CohortDiscovery/TabbedIndex.js +15 -0
- package/dist/dts/features/CohortDiscovery/TabbedIndex.js.map +1 -0
- package/dist/dts/features/CohortDiscovery/api/analysisApiCohortDiscovery.js +2 -2
- package/dist/dts/features/CohortDiscovery/api/analysisApiCohortDiscovery.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/appApi.d.ts +19 -3
- package/dist/dts/features/CohortDiscovery/appApi.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/appApi.js +11 -3
- package/dist/dts/features/CohortDiscovery/appApi.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/hooks.d.ts +12 -0
- package/dist/dts/features/CohortDiscovery/hooks.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/hooks.js +42 -1
- package/dist/dts/features/CohortDiscovery/hooks.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/registerApp.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/registerApp.js +5 -3
- package/dist/dts/features/CohortDiscovery/registerApp.js.map +1 -1
- package/dist/dts/features/CohortDiscovery/types.d.ts +57 -0
- package/dist/dts/features/CohortDiscovery/types.d.ts.map +1 -1
- package/dist/dts/features/CohortDiscovery/types.js +35 -1
- package/dist/dts/features/CohortDiscovery/types.js.map +1 -1
- package/dist/dts/features/CohortSimilarity/appApi.d.ts +4 -6
- package/dist/dts/features/CohortSimilarity/appApi.d.ts.map +1 -1
- package/dist/dts/features/CohortSimilarity/appApi.js +3 -1
- package/dist/dts/features/CohortSimilarity/appApi.js.map +1 -1
- package/dist/dts/features/CohortSimilarity/registerApp.d.ts.map +1 -1
- package/dist/dts/features/CohortSimilarity/registerApp.js +1 -3
- package/dist/dts/features/CohortSimilarity/registerApp.js.map +1 -1
- package/dist/dts/features/DataLibrary/DatasetAccordionControl.d.ts.map +1 -1
- package/dist/dts/features/DataLibrary/DatasetAccordionControl.js +2 -2
- package/dist/dts/features/DataLibrary/DatasetAccordionControl.js.map +1 -1
- package/dist/dts/features/DataLibrary/SearchAndActions.js +1 -1
- package/dist/dts/features/DataLibrary/SearchAndActions.js.map +1 -1
- package/dist/dts/features/DataLibrary/tables/SelectedItemsTable.d.ts.map +1 -1
- package/dist/dts/features/DataLibrary/tables/SelectedItemsTable.js +1 -1
- package/dist/dts/features/DataLibrary/tables/SelectedItemsTable.js.map +1 -1
- package/dist/dts/features/DataLibrary/tests/utils.unit.test.js +2 -1
- package/dist/dts/features/DataLibrary/tests/utils.unit.test.js.map +1 -1
- package/dist/dts/features/DataLibrary/utils.d.ts +0 -10
- package/dist/dts/features/DataLibrary/utils.d.ts.map +1 -1
- package/dist/dts/features/DataLibrary/utils.js +0 -34
- package/dist/dts/features/DataLibrary/utils.js.map +1 -1
- package/dist/dts/features/Dictionary/CategoryPanel.d.ts.map +1 -1
- package/dist/dts/features/Dictionary/CategoryPanel.js +9 -9
- package/dist/dts/features/Dictionary/CategoryPanel.js.map +1 -1
- package/dist/dts/features/Dictionary/DictionaryWithContext.d.ts.map +1 -1
- package/dist/dts/features/Dictionary/DictionaryWithContext.js.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/IndexedMetadata/DataLoader.js.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/DataLoader.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/DataLoader.js +2 -2
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/DataLoader.js.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/filterByTags.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/filterByTags.js +1 -1
- package/dist/dts/features/Discovery/DataLoaders/MDSAllLocal/filterByTags.js.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/utils.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DataLoaders/utils.js +1 -1
- package/dist/dts/features/Discovery/DataLoaders/utils.js.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryIndexPanel.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryIndexPanel.js +8 -6
- package/dist/dts/features/Discovery/DiscoveryIndexPanel.js.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryProvider.d.ts +0 -3
- package/dist/dts/features/Discovery/DiscoveryProvider.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryProvider.js +0 -5
- package/dist/dts/features/Discovery/DiscoveryProvider.js.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryTable.d.ts.map +1 -1
- package/dist/dts/features/Discovery/DiscoveryTable.js +7 -5
- package/dist/dts/features/Discovery/DiscoveryTable.js.map +1 -1
- package/dist/dts/features/Discovery/StudyDetails/StudyItems.d.ts.map +1 -1
- package/dist/dts/features/Discovery/StudyDetails/StudyItems.js +3 -1
- package/dist/dts/features/Discovery/StudyDetails/StudyItems.js.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/CellRenderers.d.ts +2 -3
- package/dist/dts/features/Discovery/TableRenderers/CellRenderers.d.ts.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/CellRenderers.js +3 -3
- package/dist/dts/features/Discovery/TableRenderers/CellRenderers.js.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/DataAccessCellRenderers.d.ts +1 -2
- package/dist/dts/features/Discovery/TableRenderers/DataAccessCellRenderers.d.ts.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/DataAccessCellRenderers.js +5 -6
- package/dist/dts/features/Discovery/TableRenderers/DataAccessCellRenderers.js.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/RowRendererFactory.d.ts +1 -1
- package/dist/dts/features/Discovery/TableRenderers/RowRendererFactory.d.ts.map +1 -1
- package/dist/dts/features/Discovery/TableRenderers/RowRenderers.d.ts +1 -1
- package/dist/dts/features/Discovery/TableRenderers/RowRenderers.d.ts.map +1 -1
- package/dist/dts/features/Discovery/index.d.ts +2 -4
- package/dist/dts/features/Discovery/index.d.ts.map +1 -1
- package/dist/dts/features/Discovery/index.js +1 -3
- package/dist/dts/features/Discovery/index.js.map +1 -1
- package/dist/dts/features/Discovery/types.d.ts +3 -107
- package/dist/dts/features/Discovery/types.d.ts.map +1 -1
- package/dist/dts/features/Discovery/types.js +0 -16
- package/dist/dts/features/Discovery/types.js.map +1 -1
- package/dist/dts/features/Discovery/utils.d.ts +2 -8
- package/dist/dts/features/Discovery/utils.d.ts.map +1 -1
- package/dist/dts/features/Discovery/utils.js +1 -28
- package/dist/dts/features/Discovery/utils.js.map +1 -1
- package/dist/dts/features/Navigation/Banner.d.ts +2 -1
- package/dist/dts/features/Navigation/Banner.d.ts.map +1 -1
- package/dist/dts/features/Navigation/Banner.js +0 -1
- package/dist/dts/features/Navigation/Banner.js.map +1 -1
- package/dist/dts/features/Navigation/Footer/FooterColumn.d.ts.map +1 -1
- package/dist/dts/features/Navigation/Footer/FooterColumn.js.map +1 -1
- package/dist/dts/features/Navigation/NavPageLayout.js +2 -2
- package/dist/dts/features/Navigation/NavPageLayout.js.map +1 -1
- package/dist/dts/features/Navigation/index.d.ts +2 -2
- package/dist/dts/features/Navigation/index.d.ts.map +1 -1
- package/dist/dts/features/Navigation/index.js.map +1 -1
- package/dist/dts/features/Study/StudyDetails/DetailsAuthorizationIcon.d.ts +9 -0
- package/dist/dts/features/Study/StudyDetails/DetailsAuthorizationIcon.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/DetailsAuthorizationIcon.js +11 -0
- package/dist/dts/features/Study/StudyDetails/DetailsAuthorizationIcon.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/RendererFactory.d.ts +19 -0
- package/dist/dts/features/Study/StudyDetails/RendererFactory.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/RendererFactory.js +56 -0
- package/dist/dts/features/Study/StudyDetails/RendererFactory.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.d.ts +15 -0
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.js +44 -0
- package/dist/dts/features/Study/StudyDetails/SinglePageStudyDetailsPanel.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetails.d.ts +10 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetails.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetails.js +36 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetails.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetailsPanel.d.ts +10 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetailsPanel.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetailsPanel.js +19 -0
- package/dist/dts/features/Study/StudyDetails/StudyDetailsPanel.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroup.d.ts +8 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroup.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroup.js +31 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroup.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroupPanel.d.ts +9 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroupPanel.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroupPanel.js +11 -0
- package/dist/dts/features/Study/StudyDetails/StudyGroupPanel.js.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyItems.d.ts +5 -0
- package/dist/dts/features/Study/StudyDetails/StudyItems.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyDetails/StudyItems.js +283 -0
- package/dist/dts/features/Study/StudyDetails/StudyItems.js.map +1 -0
- package/dist/dts/features/Study/StudyPage/DownloadLinksPanel.d.ts +10 -0
- package/dist/dts/features/Study/StudyPage/DownloadLinksPanel.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyPage/DownloadLinksPanel.js +45 -0
- package/dist/dts/features/Study/StudyPage/DownloadLinksPanel.js.map +1 -0
- package/dist/dts/features/Study/StudyPage/StudyPage.d.ts +10 -0
- package/dist/dts/features/Study/StudyPage/StudyPage.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyPage/StudyPage.js +11 -0
- package/dist/dts/features/Study/StudyPage/StudyPage.js.map +1 -0
- package/dist/dts/features/Study/StudyPage/StudyPageGroup.d.ts +9 -0
- package/dist/dts/features/Study/StudyPage/StudyPageGroup.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyPage/StudyPageGroup.js +8 -0
- package/dist/dts/features/Study/StudyPage/StudyPageGroup.js.map +1 -0
- package/dist/dts/features/Study/StudyProvider.d.ts +12 -0
- package/dist/dts/features/Study/StudyProvider.d.ts.map +1 -0
- package/dist/dts/features/Study/StudyProvider.js +23 -0
- package/dist/dts/features/Study/StudyProvider.js.map +1 -0
- package/dist/dts/features/Study/TableRenderers/CellRenderers.d.ts +3 -0
- package/dist/dts/features/Study/TableRenderers/CellRenderers.d.ts.map +1 -0
- package/dist/dts/features/Study/TableRenderers/CellRenderers.js +20 -0
- package/dist/dts/features/Study/TableRenderers/CellRenderers.js.map +1 -0
- package/dist/dts/features/Study/TableRenderers/types.d.ts +14 -0
- package/dist/dts/features/Study/TableRenderers/types.d.ts.map +1 -0
- package/dist/dts/features/Study/TableRenderers/types.js +2 -0
- package/dist/dts/features/Study/TableRenderers/types.js.map +1 -0
- package/dist/dts/features/Study/index.d.ts +5 -0
- package/dist/dts/features/Study/index.d.ts.map +1 -0
- package/dist/dts/features/Study/index.js +4 -0
- package/dist/dts/features/Study/index.js.map +1 -0
- package/dist/dts/features/Study/types.d.ts +91 -0
- package/dist/dts/features/Study/types.d.ts.map +1 -0
- package/dist/dts/features/Study/types.js +8 -0
- package/dist/dts/features/Study/types.js.map +1 -0
- package/dist/dts/features/Study/utils.d.ts +10 -0
- package/dist/dts/features/Study/utils.d.ts.map +1 -0
- package/dist/dts/features/Study/utils.js +28 -0
- package/dist/dts/features/Study/utils.js.map +1 -0
- package/dist/dts/features/Workspace/admin/WorkspacePanelsEditor.d.ts.map +1 -1
- package/dist/dts/features/Workspace/admin/WorkspacePanelsEditor.js.map +1 -1
- package/dist/dts/index.d.ts +3 -1
- package/dist/dts/index.d.ts.map +1 -1
- package/dist/dts/index.js +7 -1
- package/dist/dts/index.js.map +1 -1
- package/dist/dts/lib/session/session.d.ts.map +1 -1
- package/dist/dts/lib/session/session.js +16 -32
- package/dist/dts/lib/session/session.js.map +1 -1
- package/dist/dts/pages/Explorer/data.d.ts.map +1 -1
- package/dist/dts/pages/Explorer/data.js +28 -22
- package/dist/dts/pages/Explorer/data.js.map +1 -1
- package/dist/dts/pages/admin/analysis/Analysis.d.ts +1 -1
- package/dist/dts/pages/admin/analysis/Analysis.d.ts.map +1 -1
- package/dist/dts/pages/admin/analysis/Analysis.js +1 -1
- package/dist/dts/pages/admin/analysis/Analysis.js.map +1 -1
- package/dist/dts/types/icons.d.ts +4 -0
- package/dist/dts/types/icons.d.ts.map +1 -0
- package/dist/dts/types/icons.js +5 -0
- package/dist/dts/types/icons.js.map +1 -0
- package/dist/dts/utils/access.d.ts +10 -0
- package/dist/dts/utils/access.d.ts.map +1 -0
- package/dist/dts/utils/access.js +11 -0
- package/dist/dts/utils/access.js.map +1 -0
- package/dist/dts/utils/authMapping.d.ts +4 -0
- package/dist/dts/utils/authMapping.d.ts.map +1 -1
- package/dist/dts/utils/authMapping.js.map +1 -1
- package/dist/dts/utils/convertResourcePathsToTree.d.ts +8 -0
- package/dist/dts/utils/convertResourcePathsToTree.d.ts.map +1 -0
- package/dist/dts/utils/convertResourcePathsToTree.js +43 -0
- package/dist/dts/utils/convertResourcePathsToTree.js.map +1 -0
- package/dist/dts/utils/dataAuthorization.d.ts +11 -0
- package/dist/dts/utils/dataAuthorization.d.ts.map +1 -0
- package/dist/dts/utils/dataAuthorization.js +2 -0
- package/dist/dts/utils/dataAuthorization.js.map +1 -0
- package/dist/dts/utils/date.d.ts +16 -0
- package/dist/dts/utils/date.d.ts.map +1 -1
- package/dist/dts/utils/date.js +54 -8
- package/dist/dts/utils/date.js.map +1 -1
- package/dist/dts/utils/index.d.ts +2 -0
- package/dist/dts/utils/index.d.ts.map +1 -1
- package/dist/dts/utils/index.js +2 -0
- package/dist/dts/utils/index.js.map +1 -1
- package/dist/dts/utils/layout.d.ts +2 -0
- package/dist/dts/utils/layout.d.ts.map +1 -0
- package/dist/dts/utils/layout.js +20 -0
- package/dist/dts/utils/layout.js.map +1 -0
- package/dist/dts/utils/tests/convertResourcePathsToTree.unit.test.d.ts +2 -0
- package/dist/dts/utils/tests/convertResourcePathsToTree.unit.test.d.ts.map +1 -0
- package/dist/dts/utils/tests/convertResourcePathsToTree.unit.test.js +150 -0
- package/dist/dts/utils/tests/convertResourcePathsToTree.unit.test.js.map +1 -0
- package/dist/esm/index.js +5935 -3966
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +216 -146
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +7 -7
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveModal.d.ts +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveModal.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveModal.js +0 -2
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveModal.js.map +0 -1
- package/dist/dts/features/CohortDiscovery/ActionButtonGroup.d.ts +0 -3
- package/dist/dts/features/CohortDiscovery/ActionButtonGroup.d.ts.map +0 -1
- package/dist/dts/features/CohortDiscovery/ActionButtonGroup.js +0 -13
- package/dist/dts/features/CohortDiscovery/ActionButtonGroup.js.map +0 -1
|
@@ -0,0 +1,284 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// import {
|
|
3
|
+
// createSelector,
|
|
4
|
+
// createEntityAdapter,
|
|
5
|
+
// createSlice,
|
|
6
|
+
// PayloadAction,
|
|
7
|
+
// EntityState,
|
|
8
|
+
// } from '@reduxjs/toolkit';
|
|
9
|
+
// import { FilterSet, IndexedFilterSet, Operation } from '@gen3/core';
|
|
10
|
+
// import { AppState } from './appApi';
|
|
11
|
+
// import { Cohort, CohortId, newCohort } from './types';
|
|
12
|
+
//
|
|
13
|
+
// const EmptyFilterSet: FilterSet = { mode: 'and', root: {} };
|
|
14
|
+
//
|
|
15
|
+
// // Create the entity adapter
|
|
16
|
+
// export const cohortsAdapter = createEntityAdapter<Cohort, CohortId>({
|
|
17
|
+
// // Select the id as the primary key
|
|
18
|
+
// selectId: (cohort: Cohort) => cohort.id,
|
|
19
|
+
// // Optional: Sort by name if needed
|
|
20
|
+
// sortComparer: (a, b) => {
|
|
21
|
+
// if (a.modifiedDatetime <= b.modifiedDatetime) return 1;
|
|
22
|
+
// else return -1;
|
|
23
|
+
// },
|
|
24
|
+
// });
|
|
25
|
+
//
|
|
26
|
+
// export interface SavedCohortsState {
|
|
27
|
+
// currentCohortId: string;
|
|
28
|
+
// }
|
|
29
|
+
//
|
|
30
|
+
// const DEFAULT_COHORT_ID = 'default';
|
|
31
|
+
// const DEFAULT_COHORT_NAME = 'Default';
|
|
32
|
+
//
|
|
33
|
+
// const DefaultCohort = newCohort(DEFAULT_COHORT_NAME, {}, DEFAULT_COHORT_ID);
|
|
34
|
+
//
|
|
35
|
+
// const emptyInitialState = cohortsAdapter.getInitialState<SavedCohortsState>({
|
|
36
|
+
// currentCohortId: DEFAULT_COHORT_ID,
|
|
37
|
+
// });
|
|
38
|
+
//
|
|
39
|
+
// const initialState = cohortsAdapter.addOne(emptyInitialState, DefaultCohort);
|
|
40
|
+
//
|
|
41
|
+
// interface AddCohortParams {
|
|
42
|
+
// name: string;
|
|
43
|
+
// filters: IndexedFilterSet;
|
|
44
|
+
// }
|
|
45
|
+
//
|
|
46
|
+
// interface UpdateFilterParams {
|
|
47
|
+
// index: string;
|
|
48
|
+
// field: string;
|
|
49
|
+
// filter: Operation;
|
|
50
|
+
// }
|
|
51
|
+
//
|
|
52
|
+
// interface SetFilterParams {
|
|
53
|
+
// index: string;
|
|
54
|
+
// filters: FilterSet;
|
|
55
|
+
// }
|
|
56
|
+
//
|
|
57
|
+
// interface RemoveFilterParams {
|
|
58
|
+
// index: string;
|
|
59
|
+
// field: string;
|
|
60
|
+
// }
|
|
61
|
+
//
|
|
62
|
+
// interface ClearAllFilterParams {
|
|
63
|
+
// index: string;
|
|
64
|
+
// }
|
|
65
|
+
//
|
|
66
|
+
// // Create a slice with reducers
|
|
67
|
+
// export const cohortPersistenceSlice = createSlice({
|
|
68
|
+
// name: 'CohortDiscovery/CohortManager',
|
|
69
|
+
// initialState: initialState,
|
|
70
|
+
// reducers: {
|
|
71
|
+
// resetCurrentCohortId: (state) => {
|
|
72
|
+
// state.currentCohortId = DEFAULT_COHORT_ID;
|
|
73
|
+
// },
|
|
74
|
+
// setCurrentCohortId: (state, action: PayloadAction<string>) => {
|
|
75
|
+
// state.currentCohortId = action.payload;
|
|
76
|
+
// },
|
|
77
|
+
// // Add a single cohort
|
|
78
|
+
// saveCohort: (state, action: PayloadAction<AddCohortParams>) => {
|
|
79
|
+
// const cohort = newCohort(
|
|
80
|
+
// action.payload.name,
|
|
81
|
+
// action.payload.filters,
|
|
82
|
+
// undefined,
|
|
83
|
+
// true,
|
|
84
|
+
// );
|
|
85
|
+
// cohortsAdapter.setOne(state, cohort);
|
|
86
|
+
// },
|
|
87
|
+
// // Remove a cohort
|
|
88
|
+
// removeSavedCohort: (state, action: PayloadAction<string>) => {
|
|
89
|
+
// // do not remove the default cohort
|
|
90
|
+
// if (action.payload === DEFAULT_COHORT_ID) {
|
|
91
|
+
// return;
|
|
92
|
+
// }
|
|
93
|
+
// cohortsAdapter.removeOne(state, action.payload);
|
|
94
|
+
// state.currentCohortId = DEFAULT_COHORT_ID;
|
|
95
|
+
// },
|
|
96
|
+
// // Remove multiple cohorts
|
|
97
|
+
// removeAllSavedCohorts: (state) => {
|
|
98
|
+
// cohortsAdapter.removeMany(state, Object.keys(state.entities));
|
|
99
|
+
// cohortsAdapter.addOne(state, DefaultCohort);
|
|
100
|
+
// state.currentCohortId = DEFAULT_COHORT_ID;
|
|
101
|
+
// },
|
|
102
|
+
// updateCohortFilter: (state, action: PayloadAction<UpdateFilterParams>) => {
|
|
103
|
+
// const { index, field, filter } = action.payload;
|
|
104
|
+
// const currentCohort = getCurrentCohort(state);
|
|
105
|
+
// cohortsAdapter.updateOne(state, {
|
|
106
|
+
// id: currentCohort.id,
|
|
107
|
+
// changes: {
|
|
108
|
+
// filters: {
|
|
109
|
+
// ...currentCohort.filters,
|
|
110
|
+
// [index]: {
|
|
111
|
+
// mode: currentCohort.filters?.[index]?.mode ?? 'and',
|
|
112
|
+
// root: {
|
|
113
|
+
// ...(currentCohort.filters?.[index]?.root ?? {}),
|
|
114
|
+
// [field]: filter,
|
|
115
|
+
// },
|
|
116
|
+
// },
|
|
117
|
+
// },
|
|
118
|
+
// modified: true,
|
|
119
|
+
// modifiedDatetime: new Date().toISOString(),
|
|
120
|
+
// },
|
|
121
|
+
// });
|
|
122
|
+
// },
|
|
123
|
+
// setCohortFilter: (state, action: PayloadAction<SetFilterParams>) => {
|
|
124
|
+
// const { index, filters } = action.payload;
|
|
125
|
+
// const currentCohort = getCurrentCohort(state);
|
|
126
|
+
// cohortsAdapter.updateOne(state, {
|
|
127
|
+
// id: currentCohort.id,
|
|
128
|
+
// changes: {
|
|
129
|
+
// filters: {
|
|
130
|
+
// ...currentCohort.filters,
|
|
131
|
+
// [index]: filters,
|
|
132
|
+
// },
|
|
133
|
+
// modified: true,
|
|
134
|
+
// modifiedDatetime: new Date().toISOString(),
|
|
135
|
+
// },
|
|
136
|
+
// });
|
|
137
|
+
// },
|
|
138
|
+
// setAllIndexFilters: (state, action: PayloadAction<IndexedFilterSet>) => {
|
|
139
|
+
// const currentCohort = getCurrentCohort(state);
|
|
140
|
+
// cohortsAdapter.updateOne(state, {
|
|
141
|
+
// id: currentCohort.id,
|
|
142
|
+
// changes: {
|
|
143
|
+
// filters: action.payload,
|
|
144
|
+
// modified: true,
|
|
145
|
+
// modifiedDatetime: new Date().toISOString(),
|
|
146
|
+
// },
|
|
147
|
+
// });
|
|
148
|
+
// },
|
|
149
|
+
// removeCohortFilter: (state, action: PayloadAction<RemoveFilterParams>) => {
|
|
150
|
+
// const { index, field } = action.payload;
|
|
151
|
+
// const currentCohort = getCurrentCohort(state);
|
|
152
|
+
// const filters = currentCohort.filters?.[index]?.root;
|
|
153
|
+
// if (!filters) {
|
|
154
|
+
// return;
|
|
155
|
+
// }
|
|
156
|
+
// const { [field]: _a, ...updated } = filters;
|
|
157
|
+
// cohortsAdapter.updateOne(state, {
|
|
158
|
+
// id: currentCohort.id,
|
|
159
|
+
// changes: {
|
|
160
|
+
// filters: {
|
|
161
|
+
// ...currentCohort.filters,
|
|
162
|
+
// [index]: {
|
|
163
|
+
// mode: currentCohort.filters[index].mode,
|
|
164
|
+
// root: updated,
|
|
165
|
+
// },
|
|
166
|
+
// },
|
|
167
|
+
// modified: true,
|
|
168
|
+
// modifiedDatetime: new Date().toISOString(),
|
|
169
|
+
// },
|
|
170
|
+
// });
|
|
171
|
+
// },
|
|
172
|
+
// clearCohortFilters: (
|
|
173
|
+
// state,
|
|
174
|
+
// action: PayloadAction<ClearAllFilterParams>,
|
|
175
|
+
// ) => {
|
|
176
|
+
// const { index } = action.payload;
|
|
177
|
+
// const currentCohort = getCurrentCohort(state);
|
|
178
|
+
// cohortsAdapter.updateOne(state, {
|
|
179
|
+
// id: currentCohort.id,
|
|
180
|
+
// changes: {
|
|
181
|
+
// filters: {
|
|
182
|
+
// ...currentCohort.filters,
|
|
183
|
+
// [index]: {
|
|
184
|
+
// // empty filter set
|
|
185
|
+
// mode: 'and',
|
|
186
|
+
// root: {},
|
|
187
|
+
// } as FilterSet,
|
|
188
|
+
// },
|
|
189
|
+
// modified: true,
|
|
190
|
+
// modifiedDatetime: new Date().toISOString(),
|
|
191
|
+
// },
|
|
192
|
+
// });
|
|
193
|
+
// },
|
|
194
|
+
// },
|
|
195
|
+
// });
|
|
196
|
+
//
|
|
197
|
+
// const getCurrentCohort = (
|
|
198
|
+
// state: EntityState<Cohort, CohortId> & SavedCohortsState,
|
|
199
|
+
// ): Cohort => {
|
|
200
|
+
// if (state.currentCohortId) {
|
|
201
|
+
// return state.entities[state.currentCohortId];
|
|
202
|
+
// }
|
|
203
|
+
// return state.entities[DEFAULT_COHORT_ID];
|
|
204
|
+
// };
|
|
205
|
+
//
|
|
206
|
+
// // Export actions
|
|
207
|
+
// export const {
|
|
208
|
+
// saveCohort,
|
|
209
|
+
// removeSavedCohort,
|
|
210
|
+
// resetCurrentCohortId,
|
|
211
|
+
// removeAllSavedCohorts,
|
|
212
|
+
// setCurrentCohortId,
|
|
213
|
+
// updateCohortFilter,
|
|
214
|
+
// setCohortFilter,
|
|
215
|
+
// removeCohortFilter,
|
|
216
|
+
// clearCohortFilters,
|
|
217
|
+
// setAllIndexFilters,
|
|
218
|
+
// } = cohortPersistenceSlice.actions;
|
|
219
|
+
//
|
|
220
|
+
// // Export selectors
|
|
221
|
+
// export const {
|
|
222
|
+
// selectAll: selectAllSavedCohorts,
|
|
223
|
+
// selectTotal: selectTotalCohorts,
|
|
224
|
+
// selectById: selectSavedCohortById,
|
|
225
|
+
// } = cohortsAdapter.getSelectors((state: AppState) => state.savedCohorts);
|
|
226
|
+
//
|
|
227
|
+
// /**
|
|
228
|
+
// * Selects the currently active cohort from the state.
|
|
229
|
+
// * Returns the cohort object corresponding to the currentCohortId,
|
|
230
|
+
// * or undefined if no cohort is currently selected.
|
|
231
|
+
// *
|
|
232
|
+
// * @param state - The application state
|
|
233
|
+
// * @returns The current Cohort object or undefined
|
|
234
|
+
// */
|
|
235
|
+
// export const selectCurrentCohort = (state: AppState): Cohort => {
|
|
236
|
+
// const { currentCohortId, entities } = state.savedCohorts;
|
|
237
|
+
//
|
|
238
|
+
// if (!currentCohortId || !entities) {
|
|
239
|
+
// return DefaultCohort;
|
|
240
|
+
// }
|
|
241
|
+
//
|
|
242
|
+
// return entities[currentCohortId];
|
|
243
|
+
// };
|
|
244
|
+
//
|
|
245
|
+
// export const selectCurrentCohortId = (state: AppState): string =>
|
|
246
|
+
// state.savedCohorts.currentCohortId;
|
|
247
|
+
//
|
|
248
|
+
// export const selectCohortIdToNameMap = createSelector(
|
|
249
|
+
// [selectAllSavedCohorts],
|
|
250
|
+
// (cohorts) => {
|
|
251
|
+
// return cohorts.reduce<Record<CohortId, string>>((acc, cohort) => {
|
|
252
|
+
// acc[cohort.id] = cohort.name;
|
|
253
|
+
// return acc;
|
|
254
|
+
// }, {});
|
|
255
|
+
// },
|
|
256
|
+
// );
|
|
257
|
+
//
|
|
258
|
+
// export const selectCurrentCohortName = createSelector(
|
|
259
|
+
// [selectCurrentCohort],
|
|
260
|
+
// (cohort) => cohort.name,
|
|
261
|
+
// );
|
|
262
|
+
//
|
|
263
|
+
// export const selectCurrentCohortFilters = createSelector(
|
|
264
|
+
// [selectCurrentCohort],
|
|
265
|
+
// (cohort) => cohort.filters,
|
|
266
|
+
// );
|
|
267
|
+
//
|
|
268
|
+
// export const selectCurrentIndexedFilterByName = createSelector(
|
|
269
|
+
// [selectCurrentCohort, (state, index, field) => ({ index, field })],
|
|
270
|
+
// (cohort, params) => {
|
|
271
|
+
// return cohort.filters[params.index]?.root[params.field];
|
|
272
|
+
// },
|
|
273
|
+
// );
|
|
274
|
+
//
|
|
275
|
+
// export const selectCurrentCohortIndexFilters = createSelector(
|
|
276
|
+
// [selectCurrentCohort, (state, index) => index],
|
|
277
|
+
// (cohort, index) => {
|
|
278
|
+
// return cohort.filters?.[index] ?? EmptyFilterSet;
|
|
279
|
+
// },
|
|
280
|
+
// );
|
|
281
|
+
//
|
|
282
|
+
// // Export reducer
|
|
283
|
+
// export const saveCohortPersistenceReducer = cohortPersistenceSlice.reducer;
|
|
284
|
+
//# sourceMappingURL=SavedCohortManagerSlice.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SavedCohortManagerSlice.js","sourceRoot":"","sources":["../../../../src/features/CohortDiscovery/SavedCohortManagerSlice.ts"],"names":[],"mappings":";AAAA,WAAW;AACX,oBAAoB;AACpB,yBAAyB;AACzB,iBAAiB;AACjB,mBAAmB;AACnB,iBAAiB;AACjB,6BAA6B;AAC7B,uEAAuE;AACvE,uCAAuC;AACvC,yDAAyD;AACzD,EAAE;AACF,+DAA+D;AAC/D,EAAE;AACF,+BAA+B;AAC/B,wEAAwE;AACxE,wCAAwC;AACxC,6CAA6C;AAC7C,wCAAwC;AACxC,8BAA8B;AAC9B,8DAA8D;AAC9D,sBAAsB;AACtB,OAAO;AACP,MAAM;AAC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,EAAE;AACF,oBAAoB;AACpB,iBAAiB;AACjB,gBAAgB;AAChB,uBAAuB;AACvB,0BAA0B;AAC1B,2BAA2B;AAC3B,wBAAwB;AACxB,wBAAwB;AACxB,qBAAqB;AACrB,wBAAwB;AACxB,wBAAwB;AACxB,wBAAwB;AACxB,sCAAsC;AACtC,EAAE;AACF,sBAAsB;AACtB,iBAAiB;AACjB,sCAAsC;AACtC,qCAAqC;AACrC,uCAAuC;AACvC,4EAA4E;AAC5E,EAAE;AACF,MAAM;AACN,yDAAyD;AACzD,qEAAqE;AACrE,sDAAsD;AACtD,KAAK;AACL,0CAA0C;AAC1C,qDAAqD;AACrD,MAAM;AACN,oEAAoE;AACpE,8DAA8D;AAC9D,EAAE;AACF,yCAAyC;AACzC,4BAA4B;AAC5B,MAAM;AACN,EAAE;AACF,sCAAsC;AACtC,KAAK;AACL,EAAE;AACF,oEAAoE;AACpE,wCAAwC;AACxC,EAAE;AACF,yDAAyD;AACzD,6BAA6B;AAC7B,mBAAmB;AACnB,yEAAyE;AACzE,sCAAsC;AACtC,oBAAoB;AACpB,cAAc;AACd,OAAO;AACP,KAAK;AACL,EAAE;AACF,yDAAyD;AACzD,2BAA2B;AAC3B,6BAA6B;AAC7B,KAAK;AACL,EAAE;AACF,4DAA4D;AAC5D,2BAA2B;AAC3B,gCAAgC;AAChC,KAAK;AACL,EAAE;AACF,kEAAkE;AAClE,wEAAwE;AACxE,0BAA0B;AAC1B,+DAA+D;AAC/D,OAAO;AACP,KAAK;AACL,EAAE;AACF,iEAAiE;AACjE,oDAAoD;AACpD,yBAAyB;AACzB,wDAAwD;AACxD,OAAO;AACP,KAAK;AACL,EAAE;AACF,oBAAoB;AACpB,8EAA8E"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { IndexResourceField, SupportServiceConfiguration } from '../types';
|
|
2
|
+
interface SavedCohortsPanelProps {
|
|
3
|
+
indexResources: IndexResourceField;
|
|
4
|
+
remoteSupportService: SupportServiceConfiguration;
|
|
5
|
+
}
|
|
6
|
+
declare const SavedCohortsPanel: ({ indexResources, remoteSupportService, }: SavedCohortsPanelProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default SavedCohortsPanel;
|
|
8
|
+
//# sourceMappingURL=SavedCohortsPanel.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SavedCohortsPanel.d.ts","sourceRoot":"","sources":["../../../../../src/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,kBAAkB,EAAE,2BAA2B,EAAE,MAAM,UAAU,CAAC;AAE3E,UAAU,sBAAsB;IAC9B,cAAc,EAAE,kBAAkB,CAAC;IACnC,oBAAoB,EAAE,2BAA2B,CAAC;CACnD;AAED,QAAA,MAAM,iBAAiB,GAAI,2CAGxB,sBAAsB,4CAaxB,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Group, Stack } from '@mantine/core';
|
|
3
|
+
import SavedCohortsTable from './SavedCohortsTable';
|
|
4
|
+
var SavedCohortsPanel = function (_a) {
|
|
5
|
+
var indexResources = _a.indexResources, remoteSupportService = _a.remoteSupportService;
|
|
6
|
+
return (_jsx(_Fragment, { children: _jsx(Stack, { className: "w-100 m-2", children: _jsx(Group, { className: "w-100 bg-base-light p-4", children: _jsx(SavedCohortsTable, { indexResources: indexResources, remoteSupportService: remoteSupportService }) }) }) }));
|
|
7
|
+
};
|
|
8
|
+
export default SavedCohortsPanel;
|
|
9
|
+
//# sourceMappingURL=SavedCohortsPanel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SavedCohortsPanel.js","sourceRoot":"","sources":["../../../../../src/features/CohortDiscovery/SavedCohorts/SavedCohortsPanel.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,iBAAiB,MAAM,qBAAqB,CAAC;AAQpD,IAAM,iBAAiB,GAAG,UAAC,EAGF;QAFvB,cAAc,oBAAA,EACd,oBAAoB,0BAAA;IAEpB,OAAO,CACL,4BACE,KAAC,KAAK,IAAC,SAAS,EAAC,WAAW,YAC1B,KAAC,KAAK,IAAC,SAAS,EAAC,yBAAyB,YACxC,KAAC,iBAAiB,IAChB,cAAc,EAAE,cAAc,EAC9B,oBAAoB,EAAE,oBAAoB,GAC1C,GACI,GACF,GACP,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IndexResourceField, SupportServiceConfiguration } from '../types';
|
|
3
|
+
interface SavedCohortsTableProps {
|
|
4
|
+
indexResources: IndexResourceField;
|
|
5
|
+
remoteSupportService: SupportServiceConfiguration;
|
|
6
|
+
size?: string;
|
|
7
|
+
}
|
|
8
|
+
declare const SavedCohortsTable: React.FC<SavedCohortsTableProps>;
|
|
9
|
+
export default SavedCohortsTable;
|
|
10
|
+
//# sourceMappingURL=SavedCohortsTable.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SavedCohortsTable.d.ts","sourceRoot":"","sources":["../../../../../src/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAsBvC,OAAO,EAGL,kBAAkB,EAClB,2BAA2B,EAC5B,MAAM,UAAU,CAAC;AA6BlB,UAAU,sBAAsB;IAC9B,cAAc,EAAE,kBAAkB,CAAC;IACnC,oBAAoB,EAAE,2BAA2B,CAAC;IAClD,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,QAAA,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CAmPvD,CAAC;AACF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
13
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
14
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
15
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
16
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
17
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
18
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
22
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
23
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
24
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
|
+
function step(op) {
|
|
26
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
28
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
|
+
switch (op[0]) {
|
|
31
|
+
case 0: case 1: t = op; break;
|
|
32
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
33
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
34
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
35
|
+
default:
|
|
36
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
37
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
38
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
39
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
40
|
+
if (t[2]) _.ops.pop();
|
|
41
|
+
_.trys.pop(); continue;
|
|
42
|
+
}
|
|
43
|
+
op = body.call(thisArg, _);
|
|
44
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
45
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
49
|
+
import { useMemo } from 'react';
|
|
50
|
+
import { useAppDispatch } from '../appApi';
|
|
51
|
+
import { MantineReactTable, useMantineReactTable, } from 'mantine-react-table';
|
|
52
|
+
import { useDeepCompareMemo } from 'use-deep-compare';
|
|
53
|
+
import { ActionIcon, Group, Text, Tooltip, useMantineTheme, } from '@mantine/core';
|
|
54
|
+
import { modals } from '@mantine/modals';
|
|
55
|
+
import { Icon } from '@iconify/react';
|
|
56
|
+
import { notifications } from '@mantine/notifications';
|
|
57
|
+
import { IconSize } from '../../../utils/sizes';
|
|
58
|
+
import { removeCohort } from '../CohortManagment/CohortManagerSlice';
|
|
59
|
+
import { selectAllCohorts } from '../CohortManagment/CohortManagerSelectors';
|
|
60
|
+
import { useAppSelector } from '../appApi';
|
|
61
|
+
import { addDataAccessRequest, selectCohortToRequestId, } from '../RequestManagerSlice';
|
|
62
|
+
import DataAccessRequestForm from '../Requests/DataAccessRequestForm';
|
|
63
|
+
import { formatDate } from '../../../utils/date';
|
|
64
|
+
import { commonTableSettings } from '../tableSettings';
|
|
65
|
+
import { queryAllResources, QueryAllIndexedError } from '../Requests/hooks';
|
|
66
|
+
import { useLazyGetAggsNoFilterSelfQuery, useCreateRequestMutation, useCoreSelector, selectUserDetails, isHttpStatusError, getRemoteSupportServiceRegistry, MissingServiceConfigurationError, } from '@gen3/core';
|
|
67
|
+
var REQUESTOR_HTTP_ERROR_MESSAGES = {
|
|
68
|
+
401: 'You are not authorized to request access to this data. Please contact the site administrator.',
|
|
69
|
+
403: 'You do not have the correct permissions to request this resource. Please contact the site administrator.',
|
|
70
|
+
};
|
|
71
|
+
var SavedCohortsTable = function (_a) {
|
|
72
|
+
var indexResources = _a.indexResources, remoteSupportService = _a.remoteSupportService, _b = _a.size, size = _b === void 0 ? 'md' : _b;
|
|
73
|
+
var appDispatch = useAppDispatch();
|
|
74
|
+
var getGetAggs = useLazyGetAggsNoFilterSelfQuery()[0];
|
|
75
|
+
var _c = useCreateRequestMutation(), requestQuery = _c[0], requestResults = _c[1];
|
|
76
|
+
var user = useCoreSelector(selectUserDetails);
|
|
77
|
+
console.log(user);
|
|
78
|
+
var columns = useMemo(function () { return [
|
|
79
|
+
{
|
|
80
|
+
accessorKey: 'name', //access nested data with dot notation
|
|
81
|
+
header: 'Name',
|
|
82
|
+
Cell: function (_a) {
|
|
83
|
+
var cell = _a.cell;
|
|
84
|
+
return _jsxs(Text, { children: [cell.getValue(), " "] });
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
accessorKey: 'createdDatetime',
|
|
89
|
+
header: 'Modified Date',
|
|
90
|
+
Cell: function (_a) {
|
|
91
|
+
var cell = _a.cell;
|
|
92
|
+
return _jsxs(Text, { children: [formatDate(cell.getValue()), " "] });
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
accessorKey: 'modifiedDatetime', //normal accessorKey
|
|
97
|
+
header: 'Created Date',
|
|
98
|
+
Cell: function (_a) {
|
|
99
|
+
var cell = _a.cell;
|
|
100
|
+
return _jsxs(Text, { children: [formatDate(cell.getValue()), " "] });
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
accessorKey: 'requested', //normal accessorKey
|
|
105
|
+
header: 'Requested',
|
|
106
|
+
Cell: function (_a) {
|
|
107
|
+
var cell = _a.cell;
|
|
108
|
+
return cell.getValue() === 'true' && (_jsx(Icon, { icon: "gen3:check", height: "2em", width: "2em", color: "green" }));
|
|
109
|
+
},
|
|
110
|
+
},
|
|
111
|
+
]; }, []);
|
|
112
|
+
var iconSize = IconSize[size] || IconSize['sm'];
|
|
113
|
+
var theme = useMantineTheme();
|
|
114
|
+
var data = useAppSelector(selectAllCohorts);
|
|
115
|
+
var requestByCohortId = useAppSelector(selectCohortToRequestId);
|
|
116
|
+
var tData = useDeepCompareMemo(function () {
|
|
117
|
+
return data.map(function (cohort) { return (__assign(__assign({}, cohort), { requested: (requestByCohortId[cohort.id] ? 'true' : 'false') })); });
|
|
118
|
+
}, [data, requestByCohortId]);
|
|
119
|
+
var handleSubmission = function (cohortId, values) { return __awaiter(void 0, void 0, void 0, function () {
|
|
120
|
+
var cohort, resources, request, zendeskRequestAction, error_1, httpError;
|
|
121
|
+
var _a, _b, _c, _d;
|
|
122
|
+
return __generator(this, function (_e) {
|
|
123
|
+
switch (_e.label) {
|
|
124
|
+
case 0:
|
|
125
|
+
cohort = data.find(function (obj) { return obj.id === cohortId; });
|
|
126
|
+
if (!(cohort && values)) return [3 /*break*/, 6];
|
|
127
|
+
_e.label = 1;
|
|
128
|
+
case 1:
|
|
129
|
+
_e.trys.push([1, 5, , 6]);
|
|
130
|
+
return [4 /*yield*/, queryAllResources(cohort.filters, indexResources, getGetAggs)];
|
|
131
|
+
case 2:
|
|
132
|
+
resources = _e.sent();
|
|
133
|
+
return [4 /*yield*/, requestQuery({
|
|
134
|
+
resource_paths: resources,
|
|
135
|
+
}).unwrap()];
|
|
136
|
+
case 3:
|
|
137
|
+
request = _e.sent();
|
|
138
|
+
zendeskRequestAction = getRemoteSupportServiceRegistry().getSupportService(remoteSupportService.service);
|
|
139
|
+
return [4 /*yield*/, zendeskRequestAction({
|
|
140
|
+
subject: "Request for access to ".concat(cohort.name),
|
|
141
|
+
fullName: "".concat(values.name),
|
|
142
|
+
email: "".concat(values.email),
|
|
143
|
+
contents: "Requestor: ".concat(values.name, " (").concat(values.email, ")") +
|
|
144
|
+
"\n\nCohort: ".concat(cohort.name) +
|
|
145
|
+
"\n\nResources: ".concat(resources.join(', ')) +
|
|
146
|
+
"\n\nRequestor ID: ".concat((user === null || user === void 0 ? void 0 : user.username) || 'unknown') +
|
|
147
|
+
"\n\nRequest ID: ".concat(request.request_id) +
|
|
148
|
+
"\n\nRequest URL: ".concat(window.location.href) +
|
|
149
|
+
"\n\nRequestor Email: ".concat(values.email) +
|
|
150
|
+
"\n\nRequestor Name: ".concat(values.name) +
|
|
151
|
+
"\n\nRequestor Organization: ".concat(values.organization),
|
|
152
|
+
}, remoteSupportService.configuration)];
|
|
153
|
+
case 4:
|
|
154
|
+
_e.sent();
|
|
155
|
+
// update the request store
|
|
156
|
+
appDispatch(addDataAccessRequest({
|
|
157
|
+
cohortId: cohortId,
|
|
158
|
+
id: (_a = request.request_id) !== null && _a !== void 0 ? _a : 'unknown',
|
|
159
|
+
name: values.name,
|
|
160
|
+
email: values.email,
|
|
161
|
+
status: (_b = request.status) !== null && _b !== void 0 ? _b : 'unknown',
|
|
162
|
+
organization: values.organization,
|
|
163
|
+
createdDatetime: (_c = request.created_time) !== null && _c !== void 0 ? _c : 'unknown',
|
|
164
|
+
updatedDatetime: (_d = request.updated_time) !== null && _d !== void 0 ? _d : 'unknown',
|
|
165
|
+
}));
|
|
166
|
+
// Close the modal after a successful dispatch
|
|
167
|
+
close();
|
|
168
|
+
return [3 /*break*/, 6];
|
|
169
|
+
case 5:
|
|
170
|
+
error_1 = _e.sent();
|
|
171
|
+
if (error_1 instanceof QueryAllIndexedError) {
|
|
172
|
+
notifications.show({
|
|
173
|
+
title: 'Request Cohort',
|
|
174
|
+
message: "Error while getting resources for cohort: ".concat(error_1.message),
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
else if (isHttpStatusError(error_1)) {
|
|
178
|
+
httpError = error_1;
|
|
179
|
+
notifications.show({
|
|
180
|
+
title: 'Request Cohort',
|
|
181
|
+
message: REQUESTOR_HTTP_ERROR_MESSAGES[httpError.status] ||
|
|
182
|
+
"Error while submitting resource request for cohorts",
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
else if (error_1 instanceof MissingServiceConfigurationError) {
|
|
186
|
+
notifications.show({
|
|
187
|
+
title: 'Request Cohort',
|
|
188
|
+
message: "Error while submitting resource request for cohorts: ".concat(error_1.message),
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
else if (error_1 instanceof Error) {
|
|
192
|
+
notifications.show({
|
|
193
|
+
title: 'Request Cohort',
|
|
194
|
+
message: "Error while submitting resource request for cohorts: ".concat(error_1.message),
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
else {
|
|
198
|
+
notifications.show({
|
|
199
|
+
title: 'Request Cohort',
|
|
200
|
+
message: 'Unknown error while submitting resource request for cohorts',
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
return [3 /*break*/, 6];
|
|
204
|
+
case 6: return [2 /*return*/];
|
|
205
|
+
}
|
|
206
|
+
});
|
|
207
|
+
}); };
|
|
208
|
+
var table = useMantineReactTable(__assign(__assign({ columns: columns, data: tData, getRowId: function (originalRow) { return originalRow.id; } }, commonTableSettings()), { positionActionsColumn: 'last', renderRowActions: function (_a) {
|
|
209
|
+
var row = _a.row;
|
|
210
|
+
return (_jsxs(Group, { wrap: "nowrap", gap: "xs", children: [_jsx(Tooltip, { label: "Submit Data Access Request", withArrow: true, children: _jsx(ActionIcon, { color: "accent.4", variant: "transparent", "aria-label": "Submit Data Access Request", onClick: function () {
|
|
211
|
+
var modelId = modals.open({
|
|
212
|
+
title: 'DATA ACCESS REQUEST',
|
|
213
|
+
children: (_jsx(DataAccessRequestForm, { cohortId: row.id, submitFunction: handleSubmission, close: function () { return modals.close(modelId); } })),
|
|
214
|
+
});
|
|
215
|
+
}, children: _jsx(Icon, { icon: "gen3:request", height: iconSize, width: iconSize, color: theme.colors.secondary[4] }) }) }), _jsx(Tooltip, { label: "Select Cohort", withArrow: true, children: _jsx(ActionIcon, { color: "accent.4", variant: "transparent", "aria-label": "Select cohort", onClick: function () { }, children: _jsx(Icon, { icon: "gen3:cohort", height: iconSize, width: iconSize, color: theme.colors.secondary[4] }) }) }), _jsx(Tooltip, { label: "Delete Cohort", withArrow: true, children: _jsx(ActionIcon, { color: "accent.4", variant: "transparent", "aria-label": "Delete saved cohort", onClick: function () {
|
|
216
|
+
modals.openConfirmModal({
|
|
217
|
+
title: 'Delete Cohort',
|
|
218
|
+
centered: true,
|
|
219
|
+
children: (_jsx(Text, { size: "sm", children: "Are you sure you want to delete your cohort? Deleted cohorts cannot be restored." })),
|
|
220
|
+
labels: { confirm: 'Delete Cohort', cancel: 'Cancel' },
|
|
221
|
+
confirmProps: { color: theme.colors.utility[2] },
|
|
222
|
+
onConfirm: function () {
|
|
223
|
+
appDispatch(removeCohort(row.id));
|
|
224
|
+
},
|
|
225
|
+
});
|
|
226
|
+
}, children: _jsx(Icon, { icon: "gen3:delete", height: iconSize, width: iconSize, color: theme.colors.secondary[4] }) }) })] }));
|
|
227
|
+
} }));
|
|
228
|
+
return (_jsx(_Fragment, { children: _jsx("div", { className: "inline-block overflow-x-scroll w-full", children: _jsx(MantineReactTable, { table: table }) }) }));
|
|
229
|
+
};
|
|
230
|
+
export default SavedCohortsTable;
|
|
231
|
+
//# sourceMappingURL=SavedCohortsTable.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SavedCohortsTable.js","sourceRoot":"","sources":["../../../../../src/features/CohortDiscovery/SavedCohorts/SavedCohortsTable.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAc,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAC3C,OAAO,EACL,iBAAiB,EACjB,oBAAoB,GAErB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AACtD,OAAO,EACL,UAAU,EACV,KAAK,EACL,IAAI,EACJ,OAAO,EACP,eAAe,GAChB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAC;AACrE,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAO3C,OAAO,EACL,oBAAoB,EACpB,uBAAuB,GACxB,MAAM,wBAAwB,CAAC;AAChC,OAAO,qBAAqB,MAAM,mCAAmC,CAAC;AACtE,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,iBAAiB,EAAE,oBAAoB,EAAE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,EAAE,QAAQ,EACf,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,GAChC,GACS,GACL,EACV,KAAC,OAAO,IAAC,KAAK,EAAC,eAAe,EAAC,SAAS,kBACtC,KAAC,UAAU,IACT,KAAK,EAAC,UAAU,EAChB,OAAO,EAAC,aAAa,gBACV,qBAAqB,EAChC,OAAO,EAAE;gCACP,MAAM,CAAC,gBAAgB,CAAC;oCACtB,KAAK,EAAE,eAAe;oCACtB,QAAQ,EAAE,IAAI;oCACd,QAAQ,EAAE,CACR,KAAC,IAAI,IAAC,IAAI,EAAC,IAAI,iGAGR,CACR;oCACD,MAAM,EAAE,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAE;oCACtD,YAAY,EAAE,EAAE,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;oCAChD,SAAS,EAAE;wCACT,WAAW,CAAC,YAAY,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC;oCACpC,CAAC;iCACF,CAAC,CAAC;4BACL,CAAC,YAED,KAAC,IAAI,IACH,IAAI,EAAC,aAAa,EAClB,MAAM,EAAE,QAAQ,EAChB,KAAK,EAAE,QAAQ,EACf,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,GAChC,GACS,GACL,IACJ,CACT;QA3E8B,CA2E9B,IACD,CAAC;IAEH,OAAO,CACL,4BACE,cAAK,SAAS,EAAC,uCAAuC,YACpD,KAAC,iBAAiB,IAAC,KAAK,EAAE,KAAK,GAAI,GAC/B,GACL,CACJ,CAAC;AACJ,CAAC,CAAC;AACF,eAAe,iBAAiB,CAAC"}
|
|
@@ -4,11 +4,10 @@ export declare const selectedFacetsReducer: import("redux").Reducer<SelectedInde
|
|
|
4
4
|
export declare const addFacetSelection: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
5
5
|
index: string;
|
|
6
6
|
field: string;
|
|
7
|
-
}, "CohortDiscovery/
|
|
7
|
+
}, "CohortDiscovery/selectedFacets/addFacetSelection">, removeFacetSelection: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
8
8
|
index: string;
|
|
9
9
|
field: string;
|
|
10
|
-
}, "CohortDiscovery/
|
|
11
|
-
export declare const selectSelectedFacetsFromIndex: (state: AppState, index: string
|
|
12
|
-
export declare const selectAllFiltersCollapsed: (state: AppState) => boolean;
|
|
10
|
+
}, "CohortDiscovery/selectedFacets/removeFacetSelection">;
|
|
11
|
+
export declare const selectSelectedFacetsFromIndex: (state: AppState, index: string) => string[];
|
|
13
12
|
export {};
|
|
14
13
|
//# sourceMappingURL=SelectedFacetsSlice.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectedFacetsSlice.d.ts","sourceRoot":"","sources":["../../../../src/features/CohortDiscovery/SelectedFacetsSlice.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEpC,KAAK,oBAAoB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"SelectedFacetsSlice.d.ts","sourceRoot":"","sources":["../../../../src/features/CohortDiscovery/SelectedFacetsSlice.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEpC,KAAK,oBAAoB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;AA4CrD,eAAO,MAAM,qBAAqB,+CAA4B,CAAC;AAE/D,eAAO,MAAQ,iBAAiB;WApCK,MAAM;WAAS,MAAM;wDAoCxB,oBAAoB;WAlBjB,MAAM;WAAS,MAAM;yDAmB/B,CAAC;AAE5B,eAAO,MAAM,6BAA6B,GACxC,OAAO,QAAQ,EACf,OAAO,MAAM,KACZ,MAAM,EAAsC,CAAC"}
|
|
@@ -22,7 +22,7 @@ var _a;
|
|
|
22
22
|
import { createSlice } from '@reduxjs/toolkit';
|
|
23
23
|
var initialState = {};
|
|
24
24
|
var selectIndexFacets = createSlice({
|
|
25
|
-
name: 'CohortDiscovery/
|
|
25
|
+
name: 'CohortDiscovery/selectedFacets',
|
|
26
26
|
initialState: initialState,
|
|
27
27
|
reducers: {
|
|
28
28
|
addFacetSelection: function (state, action) {
|
|
@@ -37,20 +37,15 @@ var selectIndexFacets = createSlice({
|
|
|
37
37
|
},
|
|
38
38
|
removeFacetSelection: function (state, action) {
|
|
39
39
|
var _a;
|
|
40
|
-
if (!(action.payload.index in state
|
|
40
|
+
if (!(action.payload.index in state))
|
|
41
41
|
return state;
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
_a));
|
|
46
|
-
}
|
|
42
|
+
return __assign(__assign({}, state), (_a = {},
|
|
43
|
+
_a[action.payload.index] = state[action.payload.index].filter(function (x) { return x != action.payload.field; }),
|
|
44
|
+
_a));
|
|
47
45
|
},
|
|
48
46
|
},
|
|
49
47
|
});
|
|
50
48
|
export var selectedFacetsReducer = selectIndexFacets.reducer;
|
|
51
49
|
export var addFacetSelection = (_a = selectIndexFacets.actions, _a.addFacetSelection), removeFacetSelection = _a.removeFacetSelection;
|
|
52
|
-
export var selectSelectedFacetsFromIndex = function (state, index
|
|
53
|
-
export var selectAllFiltersCollapsed = function (state) {
|
|
54
|
-
return Object.values(state.filtersExpandedState).every(function (e) { return !e; });
|
|
55
|
-
};
|
|
50
|
+
export var selectSelectedFacetsFromIndex = function (state, index) { return state.selectedIndexFacets[index]; };
|
|
56
51
|
//# sourceMappingURL=SelectedFacetsSlice.js.map
|