synapse-react-client 4.0.34 → 4.0.36
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/SWC.index.js +1 -1
- package/dist/aridhia-queries/AridhiaKeyFactory.d.ts +24 -0
- package/dist/aridhia-queries/AridhiaKeyFactory.d.ts.map +1 -0
- package/dist/aridhia-queries/AridhiaKeyFactory.js +49 -0
- package/dist/aridhia-queries/AridhiaKeyFactory.js.map +1 -0
- package/dist/aridhia-queries/FairFormPayload.d.ts +45 -0
- package/dist/aridhia-queries/FairFormPayload.d.ts.map +1 -0
- package/dist/aridhia-queries/FairFormPayload.js +0 -0
- package/dist/aridhia-queries/TransferType.d.ts +10 -0
- package/dist/aridhia-queries/TransferType.d.ts.map +1 -0
- package/dist/aridhia-queries/TransferType.js +0 -0
- package/dist/aridhia-queries/aridhiaTokenExchange.js +6 -6
- package/dist/aridhia-queries/index.d.ts +12 -0
- package/dist/aridhia-queries/index.d.ts.map +1 -1
- package/dist/aridhia-queries/index.js +12 -2
- package/dist/aridhia-queries/useAridhiaQuery.d.ts +37 -0
- package/dist/aridhia-queries/useAridhiaQuery.d.ts.map +1 -0
- package/dist/aridhia-queries/useAridhiaQuery.js +71 -0
- package/dist/aridhia-queries/useAridhiaQuery.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetCatalogue.d.ts +6 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetCatalogue.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetCatalogue.js +13 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetCatalogue.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetSettings.d.ts +6 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetSettings.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetSettings.js +13 -0
- package/dist/aridhia-queries/useGetAridhiaDatasetSettings.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDictionaries.d.ts +6 -0
- package/dist/aridhia-queries/useGetAridhiaDictionaries.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaDictionaries.js +13 -0
- package/dist/aridhia-queries/useGetAridhiaDictionaries.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaRequests.d.ts +5 -4
- package/dist/aridhia-queries/useGetAridhiaRequests.d.ts.map +1 -1
- package/dist/aridhia-queries/useGetAridhiaRequests.js +11 -18
- package/dist/aridhia-queries/useGetAridhiaRequests.js.map +1 -1
- package/dist/aridhia-queries/useGetAridhiaWorkflow.d.ts +13 -0
- package/dist/aridhia-queries/useGetAridhiaWorkflow.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkflow.js +19 -0
- package/dist/aridhia-queries/useGetAridhiaWorkflow.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceLocations.d.ts +6 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceLocations.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceLocations.js +13 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceLocations.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceRequestForm.d.ts +19 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceRequestForm.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceRequestForm.js +17 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaceRequestForm.js.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaces.d.ts +6 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaces.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaces.js +19 -0
- package/dist/aridhia-queries/useGetAridhiaWorkspaces.js.map +1 -0
- package/dist/aridhia-queries/useSubmitAridhiaDar.d.ts +27 -0
- package/dist/aridhia-queries/useSubmitAridhiaDar.d.ts.map +1 -0
- package/dist/aridhia-queries/useSubmitAridhiaDar.js +38 -0
- package/dist/aridhia-queries/useSubmitAridhiaDar.js.map +1 -0
- package/dist/assets/icons/curie-head.svg +21 -0
- package/dist/components/AccessRequirement/EntityActionsRequired.d.ts +0 -1
- package/dist/components/AccessRequirement/EntityActionsRequired.d.ts.map +1 -1
- package/dist/components/AccessRequirement/EntityActionsRequired.js +3 -6
- package/dist/components/AccessRequirement/EntityActionsRequired.js.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementList.d.ts +24 -2
- package/dist/components/AccessRequirementList/AccessRequirementList.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementList.js +69 -66
- package/dist/components/AccessRequirementList/AccessRequirementList.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.js +67 -56
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.js +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.d.ts +6 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.js +55 -54
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.js.map +1 -1
- package/dist/components/Aridhia/aridhiaAccessStatusUtils.d.ts +3 -3
- package/dist/components/Aridhia/aridhiaAccessStatusUtils.d.ts.map +1 -1
- package/dist/components/Aridhia/aridhiaAccessStatusUtils.js +1 -1
- package/dist/components/Aridhia/aridhiaAccessStatusUtils.js.map +1 -1
- package/dist/components/CardContainer/CardConfiguration.d.ts +8 -0
- package/dist/components/CardContainer/CardConfiguration.d.ts.map +1 -1
- package/dist/components/ChangePassword/ChangePasswordWithToken.d.ts.map +1 -1
- package/dist/components/ChangePassword/ChangePasswordWithToken.js +58 -23
- package/dist/components/ChangePassword/ChangePasswordWithToken.js.map +1 -1
- package/dist/components/ChangePassword/useChangePasswordFormState.d.ts.map +1 -1
- package/dist/components/ChangePassword/useChangePasswordFormState.js +13 -3
- package/dist/components/ChangePassword/useChangePasswordFormState.js.map +1 -1
- package/dist/components/CreateTableViewWizard/TableNameForm.d.ts.map +1 -1
- package/dist/components/CreateTableViewWizard/TableNameForm.js +11 -14
- package/dist/components/CreateTableViewWizard/TableNameForm.js.map +1 -1
- package/dist/components/DataGrid/SyncGridWithSourceButton.d.ts +1 -1
- package/dist/components/DataGrid/SyncGridWithSourceButton.d.ts.map +1 -1
- package/dist/components/DataGrid/SyncGridWithSourceButton.js +55 -61
- package/dist/components/DataGrid/SyncGridWithSourceButton.js.map +1 -1
- package/dist/components/DataGrid/components/contextMenu.d.ts.map +1 -1
- package/dist/components/DataGrid/components/contextMenu.js +15 -15
- package/dist/components/DataGrid/components/contextMenu.js.map +1 -1
- package/dist/components/DataGrid/useMergeGridWithSource.d.ts +1 -5
- package/dist/components/DataGrid/useMergeGridWithSource.d.ts.map +1 -1
- package/dist/components/DataGrid/useMergeGridWithSource.js +21 -28
- package/dist/components/DataGrid/useMergeGridWithSource.js.map +1 -1
- package/dist/components/DatasetHosting/DatasetDownloadButton.d.ts +35 -0
- package/dist/components/DatasetHosting/DatasetDownloadButton.d.ts.map +1 -0
- package/dist/components/DatasetHosting/DatasetDownloadButton.js +132 -0
- package/dist/components/DatasetHosting/DatasetDownloadButton.js.map +1 -0
- package/dist/components/DatasetHosting/DatasetHosting.d.ts +91 -0
- package/dist/components/DatasetHosting/DatasetHosting.d.ts.map +1 -0
- package/dist/components/DatasetHosting/DatasetHosting.js +58 -0
- package/dist/components/DatasetHosting/DatasetHosting.js.map +1 -0
- package/dist/components/DatasetHosting/index.d.ts +5 -0
- package/dist/components/DatasetHosting/index.d.ts.map +1 -0
- package/dist/components/DatasetHosting/index.js +3 -0
- package/dist/components/DownloadCart/ActionRequiredListItem.d.ts +0 -2
- package/dist/components/DownloadCart/ActionRequiredListItem.d.ts.map +1 -1
- package/dist/components/DownloadCart/ActionRequiredListItem.js +2 -3
- package/dist/components/DownloadCart/ActionRequiredListItem.js.map +1 -1
- package/dist/components/DownloadCart/DownloadCartPage.d.ts +1 -2
- package/dist/components/DownloadCart/DownloadCartPage.d.ts.map +1 -1
- package/dist/components/DownloadCart/DownloadCartPage.js +49 -49
- package/dist/components/DownloadCart/DownloadCartPage.js.map +1 -1
- package/dist/components/DownloadCart/DownloadListActionsRequired.d.ts +1 -5
- package/dist/components/DownloadCart/DownloadListActionsRequired.d.ts.map +1 -1
- package/dist/components/DownloadCart/DownloadListActionsRequired.js +5 -6
- package/dist/components/DownloadCart/DownloadListActionsRequired.js.map +1 -1
- package/dist/components/DownloadCart/RequestDownloadCard.d.ts +0 -2
- package/dist/components/DownloadCart/RequestDownloadCard.d.ts.map +1 -1
- package/dist/components/DownloadCart/RequestDownloadCard.js +28 -32
- package/dist/components/DownloadCart/RequestDownloadCard.js.map +1 -1
- package/dist/components/DownloadCart/TableQueryActionsRequired.d.ts +0 -2
- package/dist/components/DownloadCart/TableQueryActionsRequired.d.ts.map +1 -1
- package/dist/components/DownloadCart/TableQueryActionsRequired.js +7 -8
- package/dist/components/DownloadCart/TableQueryActionsRequired.js.map +1 -1
- package/dist/components/DownloadCart/index.d.ts +1 -2
- package/dist/components/DownloadCart/index.d.ts.map +1 -1
- package/dist/components/DraggableDialog/DraggableDialog.d.ts +2 -1
- package/dist/components/DraggableDialog/DraggableDialog.d.ts.map +1 -1
- package/dist/components/DraggableDialog/DraggableDialog.js +42 -33
- package/dist/components/DraggableDialog/DraggableDialog.js.map +1 -1
- package/dist/components/EntityTreeTable/hooks/useTableColumns.d.ts.map +1 -1
- package/dist/components/EntityTreeTable/hooks/useTableColumns.js +12 -6
- package/dist/components/EntityTreeTable/hooks/useTableColumns.js.map +1 -1
- package/dist/components/ExperimentalMode/ExperimentalMode.js +2 -1
- package/dist/components/ExperimentalMode/ExperimentalMode.js.map +1 -1
- package/dist/components/GenericCard/CardActionButtonStyleContext.d.ts +10 -0
- package/dist/components/GenericCard/CardActionButtonStyleContext.d.ts.map +1 -0
- package/dist/components/GenericCard/CardActionButtonStyleContext.js +10 -0
- package/dist/components/GenericCard/CardActionButtonStyleContext.js.map +1 -0
- package/dist/components/GenericCard/DuoTermTags/DuoTermTags.js +41 -41
- package/dist/components/GenericCard/GenericCardActionButton.d.ts +5 -0
- package/dist/components/GenericCard/GenericCardActionButton.d.ts.map +1 -1
- package/dist/components/GenericCard/GenericCardActionButton.js +28 -11
- package/dist/components/GenericCard/GenericCardActionButton.js.map +1 -1
- package/dist/components/GenericCard/TableRowGenericCard.d.ts +24 -0
- package/dist/components/GenericCard/TableRowGenericCard.d.ts.map +1 -1
- package/dist/components/GenericCard/TableRowGenericCard.js +205 -190
- package/dist/components/GenericCard/TableRowGenericCard.js.map +1 -1
- package/dist/components/JSONArrayEditor/JSONArrayEditor.d.ts.map +1 -1
- package/dist/components/JSONArrayEditor/JSONArrayEditor.js +42 -42
- package/dist/components/JSONArrayEditor/JSONArrayEditor.js.map +1 -1
- package/dist/components/JsonSchemaForm/JsonSchemaForm.css +1 -0
- package/dist/components/JsonSchemaForm/JsonSchemaForm.d.ts.map +1 -1
- package/dist/components/JsonSchemaForm/JsonSchemaForm.js +13 -12
- package/dist/components/JsonSchemaForm/JsonSchemaForm.js.map +1 -1
- package/dist/components/JsonSchemaForm/JsonSchemaForm.module.js +5 -0
- package/dist/components/JsonSchemaForm/JsonSchemaForm.module.js.map +1 -0
- package/dist/components/JsonSchemaForm/JsonSchemaForm.module.scss +109 -0
- package/dist/components/QueryBuilder/QueryBuilderTypes.d.ts +39 -0
- package/dist/components/QueryBuilder/QueryBuilderTypes.d.ts.map +1 -0
- package/dist/components/QueryBuilder/QueryBuilderTypes.js +11 -0
- package/dist/components/QueryBuilder/QueryBuilderTypes.js.map +1 -0
- package/dist/components/QueryBuilder/queryBuilderTranslation.d.ts +48 -0
- package/dist/components/QueryBuilder/queryBuilderTranslation.d.ts.map +1 -0
- package/dist/components/QueryBuilder/queryBuilderTranslation.js +256 -0
- package/dist/components/QueryBuilder/queryBuilderTranslation.js.map +1 -0
- package/dist/components/QueryContext/QueryContext.d.ts +0 -1
- package/dist/components/QueryContext/QueryContext.d.ts.map +1 -1
- package/dist/components/QueryContext/QueryContext.js.map +1 -1
- package/dist/components/QueryWrapper/QueryWrapper.d.ts +0 -1
- package/dist/components/QueryWrapper/QueryWrapper.d.ts.map +1 -1
- package/dist/components/QueryWrapper/QueryWrapper.js +52 -53
- package/dist/components/QueryWrapper/QueryWrapper.js.map +1 -1
- package/dist/components/QueryWrapperErrorBoundary.d.ts.map +1 -1
- package/dist/components/QueryWrapperErrorBoundary.js +4 -11
- package/dist/components/QueryWrapperErrorBoundary.js.map +1 -1
- package/dist/components/QueryWrapperPlotNav/QueryWrapperPlotNav.d.ts +0 -1
- package/dist/components/QueryWrapperPlotNav/QueryWrapperPlotNav.d.ts.map +1 -1
- package/dist/components/QueryWrapperPlotNav/QueryWrapperPlotNav.js.map +1 -1
- package/dist/components/SchemaDrivenAnnotationEditor/SchemaDrivenAnnotationEditor.js +123 -123
- package/dist/components/SchemaDrivenAnnotationEditor/SchemaDrivenAnnotationEditor.js.map +1 -1
- package/dist/components/SearchQueryWrapper/SearchQueryUseQueryOptions.d.ts.map +1 -1
- package/dist/components/SearchQueryWrapper/SearchQueryUseQueryOptions.js +64 -55
- package/dist/components/SearchQueryWrapper/SearchQueryUseQueryOptions.js.map +1 -1
- package/dist/components/SearchQueryWrapper/SearchQueryWrapper.d.ts.map +1 -1
- package/dist/components/SearchQueryWrapper/SearchQueryWrapper.js +0 -1
- package/dist/components/SearchQueryWrapper/SearchQueryWrapper.js.map +1 -1
- package/dist/components/ShareThisPage/ShareThisPage.js +30 -29
- package/dist/components/ShareThisPage/ShareThisPage.js.map +1 -1
- package/dist/components/StorybookComponentWrapper.d.ts.map +1 -1
- package/dist/components/StorybookComponentWrapper.js +15 -10
- package/dist/components/StorybookComponentWrapper.js.map +1 -1
- package/dist/components/SynapseChat/GridAgentChat.d.ts.map +1 -1
- package/dist/components/SynapseChat/GridAgentChat.js +29 -31
- package/dist/components/SynapseChat/GridAgentChat.js.map +1 -1
- package/dist/components/SynapseChat/SynapseChat.d.ts +2 -1
- package/dist/components/SynapseChat/SynapseChat.d.ts.map +1 -1
- package/dist/components/SynapseChat/SynapseChat.js +118 -74
- package/dist/components/SynapseChat/SynapseChat.js.map +1 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.d.ts +3 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.d.ts.map +1 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.js +21 -21
- package/dist/components/SynapseChat/SynapseChatInteraction.js.map +1 -1
- package/dist/components/SynapseChat/SynapseChatMessage.d.ts +1 -0
- package/dist/components/SynapseChat/SynapseChatMessage.d.ts.map +1 -1
- package/dist/components/SynapseChat/SynapseChatMessage.js +9 -8
- package/dist/components/SynapseChat/SynapseChatMessage.js.map +1 -1
- package/dist/components/SynapseChat/SynapsePortalChatDialog.d.ts.map +1 -1
- package/dist/components/SynapseChat/SynapsePortalChatDialog.js +2 -1
- package/dist/components/SynapseChat/SynapsePortalChatDialog.js.map +1 -1
- package/dist/components/SynapseTable/SynapseTable.d.ts.map +1 -1
- package/dist/components/SynapseTable/SynapseTable.js +2 -1
- package/dist/components/SynapseTable/SynapseTable.js.map +1 -1
- package/dist/components/SynapseTable/export/ExternalPlatformActionsRequiredPrecheck.d.ts.map +1 -1
- package/dist/components/SynapseTable/export/ExternalPlatformActionsRequiredPrecheck.js +29 -30
- package/dist/components/SynapseTable/export/ExternalPlatformActionsRequiredPrecheck.js.map +1 -1
- package/dist/components/TanStackTable/StyledTanStackTable.d.ts +7 -0
- package/dist/components/TanStackTable/StyledTanStackTable.d.ts.map +1 -1
- package/dist/components/TanStackTable/StyledTanStackTable.js +68 -48
- package/dist/components/TanStackTable/StyledTanStackTable.js.map +1 -1
- package/dist/components/TanStackTable/TanStackTableUtils.d.ts.map +1 -1
- package/dist/components/TanStackTable/TanStackTableUtils.js +6 -6
- package/dist/components/TanStackTable/TanStackTableUtils.js.map +1 -1
- package/dist/components/TanStackTable/useSyncedTopScrollbar.d.ts +13 -0
- package/dist/components/TanStackTable/useSyncedTopScrollbar.d.ts.map +1 -0
- package/dist/components/TanStackTable/useSyncedTopScrollbar.js +32 -0
- package/dist/components/TanStackTable/useSyncedTopScrollbar.js.map +1 -0
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.d.ts +12 -0
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.d.ts.map +1 -0
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.js +86 -0
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.js.map +1 -0
- package/dist/components/dataaccess/UserAccessRequestHistory/UserAccessRequestHistoryPage.d.ts.map +1 -1
- package/dist/components/dataaccess/UserAccessRequestHistory/UserAccessRequestHistoryPage.js +20 -18
- package/dist/components/dataaccess/UserAccessRequestHistory/UserAccessRequestHistoryPage.js.map +1 -1
- package/dist/components/doi/CreateOrUpdateDoiModal.d.ts.map +1 -1
- package/dist/components/doi/CreateOrUpdateDoiModal.js +10 -13
- package/dist/components/doi/CreateOrUpdateDoiModal.js.map +1 -1
- package/dist/components/entity/page/CreatedByModifiedBy.d.ts.map +1 -1
- package/dist/components/entity/page/CreatedByModifiedBy.js +43 -61
- package/dist/components/entity/page/CreatedByModifiedBy.js.map +1 -1
- package/dist/components/entity/page/createdByModifiedByTooltips.d.ts +7 -0
- package/dist/components/entity/page/createdByModifiedByTooltips.d.ts.map +1 -0
- package/dist/components/entity/page/createdByModifiedByTooltips.js +36 -0
- package/dist/components/entity/page/createdByModifiedByTooltips.js.map +1 -0
- package/dist/components/entity/page/title_bar/useGetEntityTitleBarProperties.d.ts.map +1 -1
- package/dist/components/entity/page/title_bar/useGetEntityTitleBarProperties.js +130 -65
- package/dist/components/entity/page/title_bar/useGetEntityTitleBarProperties.js.map +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +143 -140
- package/dist/components/menu/DropdownMenu.d.ts.map +1 -1
- package/dist/components/menu/DropdownMenu.js +6 -6
- package/dist/components/menu/DropdownMenu.js.map +1 -1
- package/dist/components/widgets/Range.js +8 -2
- package/dist/components/widgets/Range.js.map +1 -1
- package/dist/components/widgets/query-filter/RangeFacetFilter.d.ts.map +1 -1
- package/dist/components/widgets/query-filter/RangeFacetFilter.js +2 -1
- package/dist/components/widgets/query-filter/RangeFacetFilter.js.map +1 -1
- package/dist/components/widgets/query-filter/RangeFacetFilterUI.d.ts.map +1 -1
- package/dist/components/widgets/query-filter/RangeFacetFilterUI.js +19 -19
- package/dist/components/widgets/query-filter/RangeFacetFilterUI.js.map +1 -1
- package/dist/features/entity/metadata-task/components/MetadataTasksPage.js +5 -5
- package/dist/index.js +161 -159
- package/dist/index.js.map +1 -1
- package/dist/mocks/msw/handlers/dataAccessRequestHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/dataAccessRequestHandlers.js +30 -26
- package/dist/mocks/msw/handlers/dataAccessRequestHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/fileHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/fileHandlers.js +22 -22
- package/dist/mocks/msw/handlers/fileHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/resetTwoFactorAuthHandlers.d.ts +1 -0
- package/dist/mocks/msw/handlers/resetTwoFactorAuthHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/resetTwoFactorAuthHandlers.js +7 -1
- package/dist/mocks/msw/handlers/resetTwoFactorAuthHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/userProfileHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/userProfileHandlers.js +40 -36
- package/dist/mocks/msw/handlers/userProfileHandlers.js.map +1 -1
- package/dist/mocks/user/mock_user_profile.d.ts +1 -0
- package/dist/mocks/user/mock_user_profile.d.ts.map +1 -1
- package/dist/mocks/user/mock_user_profile.js +45 -45
- package/dist/mocks/user/mock_user_profile.js.map +1 -1
- package/dist/style/components/_all.scss +0 -1
- package/dist/style/components/_cards.scss +4 -2
- package/dist/style/main.css +1 -1
- package/dist/synapse-queries/KeyFactory.d.ts +2 -0
- package/dist/synapse-queries/KeyFactory.d.ts.map +1 -1
- package/dist/synapse-queries/KeyFactory.js +6 -0
- package/dist/synapse-queries/KeyFactory.js.map +1 -1
- package/dist/synapse-queries/dataaccess/index.js +4 -4
- package/dist/synapse-queries/dataaccess/useEDuc.d.ts +20 -1
- package/dist/synapse-queries/dataaccess/useEDuc.d.ts.map +1 -1
- package/dist/synapse-queries/dataaccess/useEDuc.js +75 -49
- package/dist/synapse-queries/dataaccess/useEDuc.js.map +1 -1
- package/dist/synapse-queries/index.js +190 -188
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/utils/APIConstants.d.ts +2 -0
- package/dist/utils/APIConstants.d.ts.map +1 -1
- package/dist/utils/APIConstants.js +2 -2
- package/dist/utils/APIConstants.js.map +1 -1
- package/dist/utils/AppUtils/session/ApplicationSessionManager.d.ts.map +1 -1
- package/dist/utils/AppUtils/session/ApplicationSessionManager.js +20 -19
- package/dist/utils/AppUtils/session/ApplicationSessionManager.js.map +1 -1
- package/dist/utils/featureflag/FeatureFlags.d.ts +2 -4
- package/dist/utils/featureflag/FeatureFlags.d.ts.map +1 -1
- package/dist/utils/featureflag/FeatureFlags.js +1 -1
- package/dist/utils/featureflag/FeatureFlags.js.map +1 -1
- package/dist/utils/functions/RegularExpressions.d.ts +17 -0
- package/dist/utils/functions/RegularExpressions.d.ts.map +1 -1
- package/dist/utils/functions/RegularExpressions.js +11 -4
- package/dist/utils/functions/RegularExpressions.js.map +1 -1
- package/dist/utils/functions/SqlFunctions.d.ts.map +1 -1
- package/dist/utils/functions/SqlFunctions.js +19 -3
- package/dist/utils/functions/SqlFunctions.js.map +1 -1
- package/dist/utils/hooks/useIsHydrated.d.ts +9 -0
- package/dist/utils/hooks/useIsHydrated.d.ts.map +1 -0
- package/dist/utils/hooks/useIsHydrated.js +10 -0
- package/dist/utils/hooks/useIsHydrated.js.map +1 -0
- package/dist/utils/index.js +16 -16
- package/dist/utils/types/IsType.d.ts +4 -1
- package/dist/utils/types/IsType.d.ts.map +1 -1
- package/dist/utils/types/IsType.js +4 -4
- package/dist/utils/types/IsType.js.map +1 -1
- package/dist/utils/types/index.js +2 -2
- package/package.json +7 -7
- package/dist/components/DataGrid/useMergeGridWithRecordSet.d.ts +0 -12
- package/dist/components/DataGrid/useMergeGridWithRecordSet.d.ts.map +0 -1
- package/dist/components/DataGrid/useMergeGridWithRecordSet.js +0 -25
- package/dist/components/DataGrid/useMergeGridWithRecordSet.js.map +0 -1
- package/dist/style/components/_annotations.scss +0 -110
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
import { DatasetHostingType } from './DatasetHosting';
|
|
3
|
+
export type DatasetDownloadButtonProps = {
|
|
4
|
+
/** The dataset entity id (synId); required to offer the download action. */
|
|
5
|
+
entityId?: string;
|
|
6
|
+
/** The dataset name, shown in the download confirmation. */
|
|
7
|
+
name: string;
|
|
8
|
+
/** The dataset version to add to the download list, if any. */
|
|
9
|
+
version?: number;
|
|
10
|
+
/**
|
|
11
|
+
* The dataset's hosting type. Accepts a raw annotation value (possibly blank,
|
|
12
|
+
* null, or unrecognized); anything unrecognized is treated as `synapse`.
|
|
13
|
+
*/
|
|
14
|
+
hosting?: DatasetHostingType | string | null;
|
|
15
|
+
/** Name of the external repository (e.g. "GEO", "dbGaP"), shown in the label/tooltip. */
|
|
16
|
+
repository?: string;
|
|
17
|
+
/** Destination for the action when the dataset is not downloadable (e.g. dbGaP/EGA). */
|
|
18
|
+
externalUrl?: string;
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
/** Portal target for the download-confirmation dialog (see EntityDownloadConfirmation). */
|
|
21
|
+
downloadConfirmationContainer?: RefObject<HTMLElement | null>;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* The hosting-aware primary action for a dataset.
|
|
25
|
+
* - downloadable types add the dataset to the user's download list.
|
|
26
|
+
* When signed out, the user is prompted to sign in.
|
|
27
|
+
* - `external-access` swaps in an "Access at {repository}" link-out
|
|
28
|
+
* - `unavailable` is a disabled, non-actionable indicator
|
|
29
|
+
*
|
|
30
|
+
* Its appearance follows the nearest `CardActionButtonStyleContext` (via
|
|
31
|
+
* `GenericCardActionButton`), so it matches the card's other action buttons.
|
|
32
|
+
*/
|
|
33
|
+
export declare function DatasetDownloadButton(props: DatasetDownloadButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
34
|
+
export default DatasetDownloadButton;
|
|
35
|
+
//# sourceMappingURL=DatasetDownloadButton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DatasetDownloadButton.d.ts","sourceRoot":"","sources":["../../../src/components/DatasetHosting/DatasetDownloadButton.tsx"],"names":[],"mappings":"AAQA,OAAO,EAAa,SAAS,EAAY,MAAM,OAAO,CAAA;AAOtD,OAAO,EAGL,kBAAkB,EAGnB,MAAM,kBAAkB,CAAA;AAWzB,MAAM,MAAM,0BAA0B,GAAG;IACvC,4EAA4E;IAC5E,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,4DAA4D;IAC5D,IAAI,EAAE,MAAM,CAAA;IACZ,+DAA+D;IAC/D,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB;;;OAGG;IACH,OAAO,CAAC,EAAE,kBAAkB,GAAG,MAAM,GAAG,IAAI,CAAA;IAC5C,yFAAyF;IACzF,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,wFAAwF;IACxF,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,2FAA2F;IAC3F,6BAA6B,CAAC,EAAE,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;CAC9D,CAAA;AA8BD;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,0BAA0B,2CAwJtE;AAED,eAAe,qBAAqB,CAAA"}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { SRC_SIGN_IN_CLASS as e } from "../../utils/SynapseConstants.js";
|
|
2
|
+
import { useSynapseContext as t } from "../../utils/context/SynapseContext.js";
|
|
3
|
+
import "../../utils/index.js";
|
|
4
|
+
import { TargetEnum as n } from "../../utils/html/TargetEnum.js";
|
|
5
|
+
import r from "../GenericCard/GenericCardActionButton.js";
|
|
6
|
+
import { DATASET_HOSTING_CONFIG as i, fillRepository as a, normalizeHosting as o } from "./DatasetHosting.js";
|
|
7
|
+
import { EntityDownloadConfirmation as s } from "../EntityDownloadConfirmation/EntityDownloadConfirmation.js";
|
|
8
|
+
import "../EntityDownloadConfirmation/index.js";
|
|
9
|
+
import { useState as c } from "react";
|
|
10
|
+
import { Tooltip as l, Typography as u } from "@mui/material";
|
|
11
|
+
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
12
|
+
import m from "@mui/icons-material/GetAppTwoTone";
|
|
13
|
+
import h from "@mui/icons-material/PublicOutlined";
|
|
14
|
+
import g from "@mui/icons-material/OpenInNew";
|
|
15
|
+
import _ from "@mui/icons-material/LayersOutlined";
|
|
16
|
+
import v from "@mui/icons-material/BlockOutlined";
|
|
17
|
+
import y from "@mui/icons-material/AssuredWorkloadOutlined";
|
|
18
|
+
import b from "@mui/icons-material/LoginOutlined";
|
|
19
|
+
import { createPortal as x } from "react-dom";
|
|
20
|
+
//#region src/components/DatasetHosting/DatasetDownloadButton.tsx
|
|
21
|
+
var S = {
|
|
22
|
+
download: m,
|
|
23
|
+
cloud: y,
|
|
24
|
+
external: h,
|
|
25
|
+
launch: g,
|
|
26
|
+
mixed: _,
|
|
27
|
+
unavailable: v
|
|
28
|
+
};
|
|
29
|
+
function C(e, t) {
|
|
30
|
+
return e.label.includes("{repository}") && !t ? e.labelWithoutRepository ?? e.label : a(e.label, t) ?? e.label;
|
|
31
|
+
}
|
|
32
|
+
var w = "320px", T = {
|
|
33
|
+
overflow: "hidden",
|
|
34
|
+
textOverflow: "ellipsis",
|
|
35
|
+
whiteSpace: "nowrap",
|
|
36
|
+
minWidth: 0,
|
|
37
|
+
textTransform: "none",
|
|
38
|
+
color: "inherit"
|
|
39
|
+
};
|
|
40
|
+
function E(m) {
|
|
41
|
+
let { entityId: h, name: g, version: _, hosting: v, repository: y, externalUrl: E, disabled: D, downloadConfirmationContainer: O } = m, { isAuthenticated: k } = t(), A = i[o(v)], j = C(A, y), M = a(A.tooltip, y), N = S[A.icon], [P, F] = c(!1), [I, L] = c(!1), [R, z] = c(!1), B = /* @__PURE__ */ f(u, {
|
|
42
|
+
variant: "buttonLink",
|
|
43
|
+
sx: T,
|
|
44
|
+
children: j
|
|
45
|
+
}), V = `${j}, ${g}`;
|
|
46
|
+
if (A.downloadable && h) {
|
|
47
|
+
if (!k) {
|
|
48
|
+
let t = R ? b : N, n = R ? "Sign in to download" : j, i = /* @__PURE__ */ f(r, {
|
|
49
|
+
variant: "outlined",
|
|
50
|
+
color: R ? "error" : "primary",
|
|
51
|
+
"aria-label": `${n}, ${g}`,
|
|
52
|
+
className: R ? e : void 0,
|
|
53
|
+
startIcon: /* @__PURE__ */ f(t, { sx: { fontSize: "16px" } }),
|
|
54
|
+
onClick: (e) => {
|
|
55
|
+
R || (e.stopPropagation(), z(!0));
|
|
56
|
+
},
|
|
57
|
+
sx: {
|
|
58
|
+
maxWidth: w,
|
|
59
|
+
textTransform: "none"
|
|
60
|
+
},
|
|
61
|
+
children: /* @__PURE__ */ f(u, {
|
|
62
|
+
variant: "buttonLink",
|
|
63
|
+
sx: T,
|
|
64
|
+
children: n
|
|
65
|
+
})
|
|
66
|
+
});
|
|
67
|
+
return !R && M ? /* @__PURE__ */ f(l, {
|
|
68
|
+
title: M,
|
|
69
|
+
arrow: !0,
|
|
70
|
+
placement: "top",
|
|
71
|
+
children: /* @__PURE__ */ f("span", { children: i })
|
|
72
|
+
}) : i;
|
|
73
|
+
}
|
|
74
|
+
let t = /* @__PURE__ */ f(r, {
|
|
75
|
+
variant: "outlined",
|
|
76
|
+
"aria-label": V,
|
|
77
|
+
startIcon: /* @__PURE__ */ f(N, { sx: { fontSize: "16px" } }),
|
|
78
|
+
onClick: () => F((e) => !e),
|
|
79
|
+
disabled: D || I,
|
|
80
|
+
sx: {
|
|
81
|
+
maxWidth: w,
|
|
82
|
+
textTransform: "none"
|
|
83
|
+
},
|
|
84
|
+
children: B
|
|
85
|
+
}), n = P ? /* @__PURE__ */ f(s, {
|
|
86
|
+
entityId: h,
|
|
87
|
+
versionNumber: _,
|
|
88
|
+
onIsLoadingChange: L,
|
|
89
|
+
handleClose: () => F(!1)
|
|
90
|
+
}) : null;
|
|
91
|
+
return /* @__PURE__ */ p(d, { children: [M ? /* @__PURE__ */ f(l, {
|
|
92
|
+
title: M,
|
|
93
|
+
arrow: !0,
|
|
94
|
+
placement: "top",
|
|
95
|
+
children: /* @__PURE__ */ f("span", { children: t })
|
|
96
|
+
}) : t, n && (O?.current ? x(n, O.current) : n)] });
|
|
97
|
+
}
|
|
98
|
+
let H = A.isExternalLink && E ? /* @__PURE__ */ f(r, {
|
|
99
|
+
variant: "outlined",
|
|
100
|
+
"aria-label": V,
|
|
101
|
+
href: E,
|
|
102
|
+
target: n.NEW_WINDOW,
|
|
103
|
+
rel: "noopener noreferrer",
|
|
104
|
+
startIcon: /* @__PURE__ */ f(N, { sx: { fontSize: "16px" } }),
|
|
105
|
+
sx: {
|
|
106
|
+
maxWidth: w,
|
|
107
|
+
textTransform: "none",
|
|
108
|
+
"&:visited": { color: "primary.main" }
|
|
109
|
+
},
|
|
110
|
+
children: B
|
|
111
|
+
}) : /* @__PURE__ */ f(r, {
|
|
112
|
+
variant: "outlined",
|
|
113
|
+
"aria-label": V,
|
|
114
|
+
disabled: !0,
|
|
115
|
+
startIcon: /* @__PURE__ */ f(N, { sx: { fontSize: "16px" } }),
|
|
116
|
+
sx: {
|
|
117
|
+
maxWidth: w,
|
|
118
|
+
textTransform: "none"
|
|
119
|
+
},
|
|
120
|
+
children: B
|
|
121
|
+
});
|
|
122
|
+
return M ? /* @__PURE__ */ f(l, {
|
|
123
|
+
title: M,
|
|
124
|
+
arrow: !0,
|
|
125
|
+
placement: "top",
|
|
126
|
+
children: /* @__PURE__ */ f("span", { children: H })
|
|
127
|
+
}) : H;
|
|
128
|
+
}
|
|
129
|
+
//#endregion
|
|
130
|
+
export { E as DatasetDownloadButton, E as default };
|
|
131
|
+
|
|
132
|
+
//# sourceMappingURL=DatasetDownloadButton.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DatasetDownloadButton.js","names":[],"sources":["../../../src/components/DatasetHosting/DatasetDownloadButton.tsx"],"sourcesContent":["import { Tooltip, Typography } from '@mui/material'\nimport GetAppTwoTone from '@mui/icons-material/GetAppTwoTone'\nimport PublicOutlined from '@mui/icons-material/PublicOutlined'\nimport OpenInNew from '@mui/icons-material/OpenInNew'\nimport LayersOutlined from '@mui/icons-material/LayersOutlined'\nimport BlockOutlined from '@mui/icons-material/BlockOutlined'\nimport AssuredWorkloadOutlined from '@mui/icons-material/AssuredWorkloadOutlined'\nimport LoginOutlined from '@mui/icons-material/LoginOutlined'\nimport { ReactNode, RefObject, useState } from 'react'\nimport { createPortal } from 'react-dom'\nimport { TargetEnum } from '@/utils/html/TargetEnum'\nimport { SRC_SIGN_IN_CLASS } from '@/utils/SynapseConstants'\nimport { useSynapseContext } from '@/utils'\nimport GenericCardActionButton from '../GenericCard/GenericCardActionButton'\nimport { EntityDownloadConfirmation } from '../EntityDownloadConfirmation'\nimport {\n DATASET_HOSTING_CONFIG,\n DatasetHostingConfig,\n DatasetHostingType,\n fillRepository,\n normalizeHosting,\n} from './DatasetHosting'\n\nconst ICONS = {\n download: GetAppTwoTone,\n cloud: AssuredWorkloadOutlined,\n external: PublicOutlined,\n launch: OpenInNew,\n mixed: LayersOutlined,\n unavailable: BlockOutlined,\n} as const\n\nexport type DatasetDownloadButtonProps = {\n /** The dataset entity id (synId); required to offer the download action. */\n entityId?: string\n /** The dataset name, shown in the download confirmation. */\n name: string\n /** The dataset version to add to the download list, if any. */\n version?: number\n /**\n * The dataset's hosting type. Accepts a raw annotation value (possibly blank,\n * null, or unrecognized); anything unrecognized is treated as `synapse`.\n */\n hosting?: DatasetHostingType | string | null\n /** Name of the external repository (e.g. \"GEO\", \"dbGaP\"), shown in the label/tooltip. */\n repository?: string\n /** Destination for the action when the dataset is not downloadable (e.g. dbGaP/EGA). */\n externalUrl?: string\n disabled?: boolean\n /** Portal target for the download-confirmation dialog (see EntityDownloadConfirmation). */\n downloadConfirmationContainer?: RefObject<HTMLElement | null>\n}\n\nfunction resolveLabel(\n config: DatasetHostingConfig,\n repository?: string,\n): string {\n if (config.label.includes('{repository}') && !repository) {\n return config.labelWithoutRepository ?? config.label\n }\n return fillRepository(config.label, repository) ?? config.label\n}\n\nconst MAX_WIDTH = '320px'\n\nconst ELLIPSIS = {\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n whiteSpace: 'nowrap',\n minWidth: 0,\n} as const\n\n// The composed labels (\"Download from GEO\", \"Access at dbGaP\") are already\n// sentence-cased, so opt out of the theme button's capitalize transform. `color:\n// inherit` lets the label take the button's color so text and icon always match.\nconst LABEL_SX = {\n ...ELLIPSIS,\n textTransform: 'none',\n color: 'inherit',\n} as const\n\n/**\n * The hosting-aware primary action for a dataset.\n * - downloadable types add the dataset to the user's download list.\n * When signed out, the user is prompted to sign in.\n * - `external-access` swaps in an \"Access at {repository}\" link-out\n * - `unavailable` is a disabled, non-actionable indicator\n *\n * Its appearance follows the nearest `CardActionButtonStyleContext` (via\n * `GenericCardActionButton`), so it matches the card's other action buttons.\n */\nexport function DatasetDownloadButton(props: DatasetDownloadButtonProps) {\n const {\n entityId,\n name,\n version,\n hosting,\n repository,\n externalUrl,\n disabled,\n downloadConfirmationContainer,\n } = props\n const { isAuthenticated } = useSynapseContext()\n const config = DATASET_HOSTING_CONFIG[normalizeHosting(hosting)]\n\n const label = resolveLabel(config, repository)\n const caveat = fillRepository(config.tooltip, repository)\n const Icon = ICONS[config.icon]\n\n const [showConfirmation, setShowConfirmation] = useState(false)\n const [isAdding, setIsAdding] = useState(false)\n const [signInPrompt, setSignInPrompt] = useState(false)\n\n const labelEl = (\n <Typography variant=\"buttonLink\" sx={LABEL_SX}>\n {label}\n </Typography>\n )\n // Every card's button shows the same visible label (\"Download\"), so include the\n // dataset name in the accessible name to distinguish them for screen readers.\n const ariaLabel = `${label}, ${name}`\n\n // Downloadable: a single button that adds the dataset to the download list.\n if (config.downloadable && entityId) {\n // Signed out: keep the button clickable as a call to action rather than\n // greying it out. The first click flips it to a red \"Sign in to download\"\n // prompt that opens the app's sign-in modal (SRC_SIGN_IN_CLASS).\n if (!isAuthenticated) {\n const PromptIcon = signInPrompt ? LoginOutlined : Icon\n const promptLabel = signInPrompt ? 'Sign in to download' : label\n const button = (\n <GenericCardActionButton\n variant=\"outlined\"\n color={signInPrompt ? 'error' : 'primary'}\n aria-label={`${promptLabel}, ${name}`}\n className={signInPrompt ? SRC_SIGN_IN_CLASS : undefined}\n startIcon={<PromptIcon sx={{ fontSize: '16px' }} />}\n onClick={event => {\n if (!signInPrompt) {\n // Swallow this first click: React adds SRC_SIGN_IN_CLASS during the\n // flush, before the event bubbles to the window-level sign-in\n // handler, which would otherwise fire on this same click. The next\n // click on the red CTA bubbles through and triggers sign-in.\n event.stopPropagation()\n setSignInPrompt(true)\n }\n }}\n sx={{ maxWidth: MAX_WIDTH, textTransform: 'none' }}\n >\n <Typography variant=\"buttonLink\" sx={LABEL_SX}>\n {promptLabel}\n </Typography>\n </GenericCardActionButton>\n )\n // Before the prompt, keep the hosting caveat tooltip; once prompting, the\n // red label is the notice, so no tooltip.\n return !signInPrompt && caveat ? (\n <Tooltip title={caveat} arrow placement=\"top\">\n <span>{button}</span>\n </Tooltip>\n ) : (\n button\n )\n }\n\n // Signed in: add the dataset to the download list.\n const button = (\n <GenericCardActionButton\n variant=\"outlined\"\n aria-label={ariaLabel}\n startIcon={<Icon sx={{ fontSize: '16px' }} />}\n onClick={() => setShowConfirmation(value => !value)}\n disabled={disabled || isAdding}\n sx={{ maxWidth: MAX_WIDTH, textTransform: 'none' }}\n >\n {labelEl}\n </GenericCardActionButton>\n )\n const confirmation = showConfirmation ? (\n <EntityDownloadConfirmation\n entityId={entityId}\n versionNumber={version}\n onIsLoadingChange={setIsAdding}\n handleClose={() => setShowConfirmation(false)}\n />\n ) : null\n return (\n <>\n {caveat ? (\n <Tooltip title={caveat} arrow placement=\"top\">\n <span>{button}</span>\n </Tooltip>\n ) : (\n button\n )}\n {confirmation &&\n (downloadConfirmationContainer?.current\n ? createPortal(confirmation, downloadConfirmationContainer.current)\n : confirmation)}\n </>\n )\n }\n\n // Not downloadable: link out to the external repository, or a disabled indicator.\n const control: ReactNode =\n config.isExternalLink && externalUrl ? (\n <GenericCardActionButton\n variant=\"outlined\"\n aria-label={ariaLabel}\n href={externalUrl}\n target={TargetEnum.NEW_WINDOW}\n rel=\"noopener noreferrer\"\n startIcon={<Icon sx={{ fontSize: '16px' }} />}\n sx={{\n maxWidth: MAX_WIDTH,\n textTransform: 'none',\n // As an <a>, a visited link would otherwise darken to primary.dark\n // (theme rule); keep the resting color consistent with the buttons.\n '&:visited': { color: 'primary.main' },\n }}\n >\n {labelEl}\n </GenericCardActionButton>\n ) : (\n <GenericCardActionButton\n variant=\"outlined\"\n aria-label={ariaLabel}\n disabled\n startIcon={<Icon sx={{ fontSize: '16px' }} />}\n sx={{ maxWidth: MAX_WIDTH, textTransform: 'none' }}\n >\n {labelEl}\n </GenericCardActionButton>\n )\n\n return caveat ? (\n <Tooltip title={caveat} arrow placement=\"top\">\n {/* span lets the tooltip work even when the control is disabled */}\n <span>{control}</span>\n </Tooltip>\n ) : (\n control\n )\n}\n\nexport default DatasetDownloadButton\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAuBA,IAAM,IAAQ;CACZ,UAAU;CACV,OAAO;CACP,UAAU;CACV,QAAQ;CACR,OAAO;CACP,aAAa;AACf;AAuBA,SAAS,EACP,GACA,GACQ;CAIR,OAHI,EAAO,MAAM,SAAS,cAAc,KAAK,CAAC,IACrC,EAAO,0BAA0B,EAAO,QAE1C,EAAe,EAAO,OAAO,CAAU,KAAK,EAAO;AAC5D;AAEA,IAAM,IAAY,SAYZ,IAAW;CATf,UAAU;CACV,cAAc;CACd,YAAY;CACZ,UAAU;CAQV,eAAe;CACf,OAAO;AACT;AAYA,SAAgB,EAAsB,GAAmC;CACvE,IAAM,EACJ,aACA,SACA,YACA,YACA,eACA,gBACA,aACA,qCACE,GACE,EAAE,uBAAoB,EAAkB,GACxC,IAAS,EAAuB,EAAiB,CAAO,IAExD,IAAQ,EAAa,GAAQ,CAAU,GACvC,IAAS,EAAe,EAAO,SAAS,CAAU,GAClD,IAAO,EAAM,EAAO,OAEpB,CAAC,GAAkB,KAAuB,EAAS,EAAK,GACxD,CAAC,GAAU,KAAe,EAAS,EAAK,GACxC,CAAC,GAAc,KAAmB,EAAS,EAAK,GAEhD,IACJ,kBAAC,GAAD;EAAY,SAAQ;EAAa,IAAI;YAClC;CACS,CAAA,GAIR,IAAY,GAAG,EAAM,IAAI;CAG/B,IAAI,EAAO,gBAAgB,GAAU;EAInC,IAAI,CAAC,GAAiB;GACpB,IAAM,IAAa,IAAe,IAAgB,GAC5C,IAAc,IAAe,wBAAwB,GACrD,IACJ,kBAAC,GAAD;IACE,SAAQ;IACR,OAAO,IAAe,UAAU;IAChC,cAAY,GAAG,EAAY,IAAI;IAC/B,WAAW,IAAe,IAAoB,KAAA;IAC9C,WAAW,kBAAC,GAAD,EAAY,IAAI,EAAE,UAAU,OAAO,EAAI,CAAA;IAClD,UAAS,MAAS;KAChB,AAAK,MAKH,EAAM,gBAAgB,GACtB,EAAgB,EAAI;IAExB;IACA,IAAI;KAAE,UAAU;KAAW,eAAe;IAAO;cAEjD,kBAAC,GAAD;KAAY,SAAQ;KAAa,IAAI;eAClC;IACS,CAAA;GACW,CAAA;GAI3B,OAAO,CAAC,KAAgB,IACtB,kBAAC,GAAD;IAAS,OAAO;IAAQ,OAAA;IAAM,WAAU;cACtC,kBAAC,QAAD,EAAA,UAAO,EAAa,CAAA;GACb,CAAA,IAET;EAEJ;EAGA,IAAM,IACJ,kBAAC,GAAD;GACE,SAAQ;GACR,cAAY;GACZ,WAAW,kBAAC,GAAD,EAAM,IAAI,EAAE,UAAU,OAAO,EAAI,CAAA;GAC5C,eAAe,GAAoB,MAAS,CAAC,CAAK;GAClD,UAAU,KAAY;GACtB,IAAI;IAAE,UAAU;IAAW,eAAe;GAAO;aAEhD;EACsB,CAAA,GAErB,IAAe,IACnB,kBAAC,GAAD;GACY;GACV,eAAe;GACf,mBAAmB;GACnB,mBAAmB,EAAoB,EAAK;EAC7C,CAAA,IACC;EACJ,OACE,kBAAA,GAAA,EAAA,UAAA,CACG,IACC,kBAAC,GAAD;GAAS,OAAO;GAAQ,OAAA;GAAM,WAAU;aACtC,kBAAC,QAAD,EAAA,UAAO,EAAa,CAAA;EACb,CAAA,IAET,GAED,MACE,GAA+B,UAC5B,EAAa,GAAc,EAA8B,OAAO,IAChE,EACN,EAAA,CAAA;CAEN;CAGA,IAAM,IACJ,EAAO,kBAAkB,IACvB,kBAAC,GAAD;EACE,SAAQ;EACR,cAAY;EACZ,MAAM;EACN,QAAQ,EAAW;EACnB,KAAI;EACJ,WAAW,kBAAC,GAAD,EAAM,IAAI,EAAE,UAAU,OAAO,EAAI,CAAA;EAC5C,IAAI;GACF,UAAU;GACV,eAAe;GAGf,aAAa,EAAE,OAAO,eAAe;EACvC;YAEC;CACsB,CAAA,IAEzB,kBAAC,GAAD;EACE,SAAQ;EACR,cAAY;EACZ,UAAA;EACA,WAAW,kBAAC,GAAD,EAAM,IAAI,EAAE,UAAU,OAAO,EAAI,CAAA;EAC5C,IAAI;GAAE,UAAU;GAAW,eAAe;EAAO;YAEhD;CACsB,CAAA;CAG7B,OAAO,IACL,kBAAC,GAAD;EAAS,OAAO;EAAQ,OAAA;EAAM,WAAU;YAEtC,kBAAC,QAAD,EAAA,UAAO,EAAc,CAAA;CACd,CAAA,IAET;AAEJ"}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Classifies a dataset by where its files are hosted and whether they can be
|
|
3
|
+
* downloaded through Synapse clients. Portals supply this value from a dataset
|
|
4
|
+
* annotation column (e.g. `hostingType`) since dataset cards are query/annotation
|
|
5
|
+
* driven and do not have access to the underlying file handles.
|
|
6
|
+
*
|
|
7
|
+
* The four values map onto two orthogonal realities:
|
|
8
|
+
* - WHERE the files live (Synapse-managed storage vs. a third-party location)
|
|
9
|
+
* - WHETHER Synapse clients can download them (yes vs. access is handled elsewhere)
|
|
10
|
+
*
|
|
11
|
+
* They are collapsed into a single enum so a card can show one predictable,
|
|
12
|
+
* scannable signal.
|
|
13
|
+
*/
|
|
14
|
+
export type DatasetHostingType =
|
|
15
|
+
/** Files are in Synapse/Sage-managed storage (S3/GCP). Standard, fast download. The default. */
|
|
16
|
+
'synapse'
|
|
17
|
+
/**
|
|
18
|
+
* Files are in a cloud bucket owned by a third party (non-Sage S3/GCP, external
|
|
19
|
+
* object store). Downloadable identically to Synapse-hosted files, but the bucket
|
|
20
|
+
* owner could remove them.
|
|
21
|
+
*/
|
|
22
|
+
| 'external-cloud'
|
|
23
|
+
/**
|
|
24
|
+
* Dataset links to files in an external repository (e.g. GEO, ENA) that are
|
|
25
|
+
* directly downloadable through Synapse clients, but served from an external
|
|
26
|
+
* server — so downloads may be slow or links could become dead over time.
|
|
27
|
+
*/
|
|
28
|
+
| 'external-download'
|
|
29
|
+
/**
|
|
30
|
+
* Dataset links to data that is NOT downloadable through Synapse (e.g. dbGaP,
|
|
31
|
+
* EGA). Records are placeholders for data held behind an external access
|
|
32
|
+
* process. No download is offered; the user is sent to the external repository.
|
|
33
|
+
*/
|
|
34
|
+
| 'external-access'
|
|
35
|
+
/**
|
|
36
|
+
* Files in the dataset span more than one location — some are downloadable
|
|
37
|
+
* through Synapse and some are hosted/controlled externally. Download is still
|
|
38
|
+
* offered (it retrieves the Synapse-available subset), but the label and tooltip
|
|
39
|
+
* flag that the rest must be obtained separately.
|
|
40
|
+
*/
|
|
41
|
+
| 'mixed'
|
|
42
|
+
/**
|
|
43
|
+
* The dataset is a record/placeholder whose data is not downloadable through
|
|
44
|
+
* Synapse, and there is no external repository to send the user to either
|
|
45
|
+
* (unlike `external-access`). No download or link action is offered — the card
|
|
46
|
+
* just signals that the data isn't available for download.
|
|
47
|
+
*/
|
|
48
|
+
| 'unavailable';
|
|
49
|
+
export type DatasetHostingConfig = {
|
|
50
|
+
/** Whether the dataset's files can be downloaded through Synapse clients. */
|
|
51
|
+
downloadable: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* If true (and not downloadable), the primary action links out to an external
|
|
54
|
+
* repository (uses externalUrl). If false/absent and not downloadable, the card
|
|
55
|
+
* shows a non-actionable "not available" chip instead of a link.
|
|
56
|
+
*/
|
|
57
|
+
isExternalLink?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Label shown on the chip-style action button. `{repository}` is substituted
|
|
60
|
+
* with the repository name when provided; if the template references
|
|
61
|
+
* `{repository}` but none is given, `labelWithoutRepository` is used instead.
|
|
62
|
+
*/
|
|
63
|
+
label: string;
|
|
64
|
+
/** Fallback label when the template needs a repository but none was provided. */
|
|
65
|
+
labelWithoutRepository?: string;
|
|
66
|
+
/** Tooltip summarizing the hosting/download caveat. `{repository}` is substituted. */
|
|
67
|
+
tooltip?: string;
|
|
68
|
+
/** MUI Chip color used for the button. `default` = neutral/non-actionable. */
|
|
69
|
+
color: 'primary' | 'warning' | 'default';
|
|
70
|
+
/**
|
|
71
|
+
* Icon shown on the button, encoding where the data lives relative to Synapse:
|
|
72
|
+
* - `download`: native, stored in Synapse
|
|
73
|
+
* - `cloud`: third-party managed cloud bucket
|
|
74
|
+
* - `external`: hosted outside Synapse but still downloadable
|
|
75
|
+
* - `launch`: not downloadable here — the user leaves Synapse to access it
|
|
76
|
+
* - `mixed`: files live in more than one location
|
|
77
|
+
* - `unavailable`: not available for download, with no external destination
|
|
78
|
+
*/
|
|
79
|
+
icon: 'download' | 'cloud' | 'external' | 'launch' | 'mixed' | 'unavailable';
|
|
80
|
+
};
|
|
81
|
+
export declare const DATASET_HOSTING_CONFIG: Record<DatasetHostingType, DatasetHostingConfig>;
|
|
82
|
+
/**
|
|
83
|
+
* Coerces a raw annotation value (which is frequently blank, null, or absent for
|
|
84
|
+
* Synapse-hosted/legacy datasets, and could be an unrecognized string) into a
|
|
85
|
+
* valid hosting type. Anything not explicitly recognized falls back to
|
|
86
|
+
* `synapse` — the safe default, which shows a standard Download button and no badge.
|
|
87
|
+
*/
|
|
88
|
+
export declare function normalizeHosting(value?: string | null): DatasetHostingType;
|
|
89
|
+
/** Substitutes the `{repository}` token, falling back to a generic phrase. */
|
|
90
|
+
export declare function fillRepository(template: string | undefined, repository?: string): string | undefined;
|
|
91
|
+
//# sourceMappingURL=DatasetHosting.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DatasetHosting.d.ts","sourceRoot":"","sources":["../../../src/components/DatasetHosting/DatasetHosting.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,kBAAkB;AAC5B,gGAAgG;AAC9F,SAAS;AACX;;;;GAIG;GACD,gBAAgB;AAClB;;;;GAIG;GACD,mBAAmB;AACrB;;;;GAIG;GACD,iBAAiB;AACnB;;;;;GAKG;GACD,OAAO;AACT;;;;;GAKG;GACD,aAAa,CAAA;AAEjB,MAAM,MAAM,oBAAoB,GAAG;IACjC,6EAA6E;IAC7E,YAAY,EAAE,OAAO,CAAA;IACrB;;;;OAIG;IACH,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAA;IACb,iFAAiF;IACjF,sBAAsB,CAAC,EAAE,MAAM,CAAA;IAC/B,sFAAsF;IACtF,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,8EAA8E;IAC9E,KAAK,EAAE,SAAS,GAAG,SAAS,GAAG,SAAS,CAAA;IACxC;;;;;;;;OAQG;IACH,IAAI,EAAE,UAAU,GAAG,OAAO,GAAG,UAAU,GAAG,QAAQ,GAAG,OAAO,GAAG,aAAa,CAAA;CAC7E,CAAA;AAED,eAAO,MAAM,sBAAsB,EAAE,MAAM,CACzC,kBAAkB,EAClB,oBAAoB,CAoDrB,CAAA;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,kBAAkB,CAM1E;AAED,8EAA8E;AAC9E,wBAAgB,cAAc,CAC5B,QAAQ,EAAE,MAAM,GAAG,SAAS,EAC5B,UAAU,CAAC,EAAE,MAAM,GAClB,MAAM,GAAG,SAAS,CAQpB"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
//#region src/components/DatasetHosting/DatasetHosting.ts
|
|
2
|
+
var e = {
|
|
3
|
+
synapse: {
|
|
4
|
+
downloadable: !0,
|
|
5
|
+
label: "Download",
|
|
6
|
+
color: "primary",
|
|
7
|
+
icon: "download"
|
|
8
|
+
},
|
|
9
|
+
"external-cloud": {
|
|
10
|
+
downloadable: !0,
|
|
11
|
+
label: "Download",
|
|
12
|
+
color: "primary",
|
|
13
|
+
icon: "cloud",
|
|
14
|
+
tooltip: "Files are stored in a cloud bucket maintained by a third party. They can be downloaded through Synapse, but the bucket owner could remove them in the future."
|
|
15
|
+
},
|
|
16
|
+
"external-download": {
|
|
17
|
+
downloadable: !0,
|
|
18
|
+
label: "Download from {repository}",
|
|
19
|
+
labelWithoutRepository: "Download from external repository",
|
|
20
|
+
color: "primary",
|
|
21
|
+
icon: "external",
|
|
22
|
+
tooltip: "Files are downloaded from an external repository ({repository}). Downloads route through that repository, so they may be slower or occasionally unavailable."
|
|
23
|
+
},
|
|
24
|
+
"external-access": {
|
|
25
|
+
downloadable: !1,
|
|
26
|
+
isExternalLink: !0,
|
|
27
|
+
label: "Access at {repository}",
|
|
28
|
+
labelWithoutRepository: "Access externally",
|
|
29
|
+
color: "warning",
|
|
30
|
+
icon: "launch",
|
|
31
|
+
tooltip: "These data are not downloadable through Synapse. Access is managed by {repository} and may require a separate application or process."
|
|
32
|
+
},
|
|
33
|
+
mixed: {
|
|
34
|
+
downloadable: !0,
|
|
35
|
+
label: "Download available files",
|
|
36
|
+
color: "primary",
|
|
37
|
+
icon: "mixed",
|
|
38
|
+
tooltip: "Files in this dataset live in more than one location. Some can be downloaded through Synapse; others are hosted externally and must be obtained separately from {repository}."
|
|
39
|
+
},
|
|
40
|
+
unavailable: {
|
|
41
|
+
downloadable: !1,
|
|
42
|
+
label: "Not available for download",
|
|
43
|
+
color: "default",
|
|
44
|
+
icon: "unavailable",
|
|
45
|
+
tooltip: "This dataset is indexed for discovery, but its data is not available for download through Synapse."
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
function t(t) {
|
|
49
|
+
let n = t?.trim();
|
|
50
|
+
return n && n in e ? n : "synapse";
|
|
51
|
+
}
|
|
52
|
+
function n(e, t) {
|
|
53
|
+
return e && e.replaceAll("{repository}", t ?? "the external repository");
|
|
54
|
+
}
|
|
55
|
+
//#endregion
|
|
56
|
+
export { e as DATASET_HOSTING_CONFIG, n as fillRepository, t as normalizeHosting };
|
|
57
|
+
|
|
58
|
+
//# sourceMappingURL=DatasetHosting.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DatasetHosting.js","names":[],"sources":["../../../src/components/DatasetHosting/DatasetHosting.ts"],"sourcesContent":["/**\n * Classifies a dataset by where its files are hosted and whether they can be\n * downloaded through Synapse clients. Portals supply this value from a dataset\n * annotation column (e.g. `hostingType`) since dataset cards are query/annotation\n * driven and do not have access to the underlying file handles.\n *\n * The four values map onto two orthogonal realities:\n * - WHERE the files live (Synapse-managed storage vs. a third-party location)\n * - WHETHER Synapse clients can download them (yes vs. access is handled elsewhere)\n *\n * They are collapsed into a single enum so a card can show one predictable,\n * scannable signal.\n */\nexport type DatasetHostingType =\n /** Files are in Synapse/Sage-managed storage (S3/GCP). Standard, fast download. The default. */\n | 'synapse'\n /**\n * Files are in a cloud bucket owned by a third party (non-Sage S3/GCP, external\n * object store). Downloadable identically to Synapse-hosted files, but the bucket\n * owner could remove them.\n */\n | 'external-cloud'\n /**\n * Dataset links to files in an external repository (e.g. GEO, ENA) that are\n * directly downloadable through Synapse clients, but served from an external\n * server — so downloads may be slow or links could become dead over time.\n */\n | 'external-download'\n /**\n * Dataset links to data that is NOT downloadable through Synapse (e.g. dbGaP,\n * EGA). Records are placeholders for data held behind an external access\n * process. No download is offered; the user is sent to the external repository.\n */\n | 'external-access'\n /**\n * Files in the dataset span more than one location — some are downloadable\n * through Synapse and some are hosted/controlled externally. Download is still\n * offered (it retrieves the Synapse-available subset), but the label and tooltip\n * flag that the rest must be obtained separately.\n */\n | 'mixed'\n /**\n * The dataset is a record/placeholder whose data is not downloadable through\n * Synapse, and there is no external repository to send the user to either\n * (unlike `external-access`). No download or link action is offered — the card\n * just signals that the data isn't available for download.\n */\n | 'unavailable'\n\nexport type DatasetHostingConfig = {\n /** Whether the dataset's files can be downloaded through Synapse clients. */\n downloadable: boolean\n /**\n * If true (and not downloadable), the primary action links out to an external\n * repository (uses externalUrl). If false/absent and not downloadable, the card\n * shows a non-actionable \"not available\" chip instead of a link.\n */\n isExternalLink?: boolean\n /**\n * Label shown on the chip-style action button. `{repository}` is substituted\n * with the repository name when provided; if the template references\n * `{repository}` but none is given, `labelWithoutRepository` is used instead.\n */\n label: string\n /** Fallback label when the template needs a repository but none was provided. */\n labelWithoutRepository?: string\n /** Tooltip summarizing the hosting/download caveat. `{repository}` is substituted. */\n tooltip?: string\n /** MUI Chip color used for the button. `default` = neutral/non-actionable. */\n color: 'primary' | 'warning' | 'default'\n /**\n * Icon shown on the button, encoding where the data lives relative to Synapse:\n * - `download`: native, stored in Synapse\n * - `cloud`: third-party managed cloud bucket\n * - `external`: hosted outside Synapse but still downloadable\n * - `launch`: not downloadable here — the user leaves Synapse to access it\n * - `mixed`: files live in more than one location\n * - `unavailable`: not available for download, with no external destination\n */\n icon: 'download' | 'cloud' | 'external' | 'launch' | 'mixed' | 'unavailable'\n}\n\nexport const DATASET_HOSTING_CONFIG: Record<\n DatasetHostingType,\n DatasetHostingConfig\n> = {\n synapse: {\n downloadable: true,\n label: 'Download',\n color: 'primary',\n icon: 'download',\n // No caveat — the default, expected experience.\n },\n 'external-cloud': {\n downloadable: true,\n label: 'Download',\n color: 'primary',\n icon: 'cloud',\n tooltip:\n 'Files are stored in a cloud bucket maintained by a third party. They can be downloaded through Synapse, but the bucket owner could remove them in the future.',\n },\n 'external-download': {\n downloadable: true,\n label: 'Download from {repository}',\n labelWithoutRepository: 'Download from external repository',\n color: 'primary',\n icon: 'external',\n tooltip:\n 'Files are downloaded from an external repository ({repository}). Downloads route through that repository, so they may be slower or occasionally unavailable.',\n },\n 'external-access': {\n downloadable: false,\n isExternalLink: true,\n label: 'Access at {repository}',\n labelWithoutRepository: 'Access externally',\n color: 'warning',\n icon: 'launch',\n tooltip:\n 'These data are not downloadable through Synapse. Access is managed by {repository} and may require a separate application or process.',\n },\n mixed: {\n downloadable: true,\n label: 'Download available files',\n color: 'primary',\n icon: 'mixed',\n tooltip:\n 'Files in this dataset live in more than one location. Some can be downloaded through Synapse; others are hosted externally and must be obtained separately from {repository}.',\n },\n unavailable: {\n downloadable: false,\n label: 'Not available for download',\n color: 'default',\n icon: 'unavailable',\n tooltip:\n 'This dataset is indexed for discovery, but its data is not available for download through Synapse.',\n },\n}\n\n/**\n * Coerces a raw annotation value (which is frequently blank, null, or absent for\n * Synapse-hosted/legacy datasets, and could be an unrecognized string) into a\n * valid hosting type. Anything not explicitly recognized falls back to\n * `synapse` — the safe default, which shows a standard Download button and no badge.\n */\nexport function normalizeHosting(value?: string | null): DatasetHostingType {\n const trimmed = value?.trim()\n if (trimmed && trimmed in DATASET_HOSTING_CONFIG) {\n return trimmed as DatasetHostingType\n }\n return 'synapse'\n}\n\n/** Substitutes the `{repository}` token, falling back to a generic phrase. */\nexport function fillRepository(\n template: string | undefined,\n repository?: string,\n): string | undefined {\n if (!template) {\n return template\n }\n return template.replaceAll(\n '{repository}',\n repository ?? 'the external repository',\n )\n}\n"],"mappings":";AAkFA,IAAa,IAGT;CACF,SAAS;EACP,cAAc;EACd,OAAO;EACP,OAAO;EACP,MAAM;CAER;CACA,kBAAkB;EAChB,cAAc;EACd,OAAO;EACP,OAAO;EACP,MAAM;EACN,SACE;CACJ;CACA,qBAAqB;EACnB,cAAc;EACd,OAAO;EACP,wBAAwB;EACxB,OAAO;EACP,MAAM;EACN,SACE;CACJ;CACA,mBAAmB;EACjB,cAAc;EACd,gBAAgB;EAChB,OAAO;EACP,wBAAwB;EACxB,OAAO;EACP,MAAM;EACN,SACE;CACJ;CACA,OAAO;EACL,cAAc;EACd,OAAO;EACP,OAAO;EACP,MAAM;EACN,SACE;CACJ;CACA,aAAa;EACX,cAAc;EACd,OAAO;EACP,OAAO;EACP,MAAM;EACN,SACE;CACJ;AACF;AAQA,SAAgB,EAAiB,GAA2C;CAC1E,IAAM,IAAU,GAAO,KAAK;CAI5B,OAHI,KAAW,KAAW,IACjB,IAEF;AACT;AAGA,SAAgB,EACd,GACA,GACoB;CAIpB,OAHK,KAGE,EAAS,WACd,gBACA,KAAc,yBAChB;AACF"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { DATASET_HOSTING_CONFIG, fillRepository, normalizeHosting, } from './DatasetHosting';
|
|
2
|
+
export type { DatasetHostingType, DatasetHostingConfig } from './DatasetHosting';
|
|
3
|
+
export { DatasetDownloadButton, default as DatasetDownloadButtonDefault, } from './DatasetDownloadButton';
|
|
4
|
+
export type { DatasetDownloadButtonProps } from './DatasetDownloadButton';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/DatasetHosting/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,sBAAsB,EACtB,cAAc,EACd,gBAAgB,GACjB,MAAM,kBAAkB,CAAA;AACzB,YAAY,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAA;AAChF,OAAO,EACL,qBAAqB,EACrB,OAAO,IAAI,4BAA4B,GACxC,MAAM,yBAAyB,CAAA;AAChC,YAAY,EAAE,0BAA0B,EAAE,MAAM,yBAAyB,CAAA"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { DATASET_HOSTING_CONFIG as e, fillRepository as t, normalizeHosting as n } from "./DatasetHosting.js";
|
|
2
|
+
import { DatasetDownloadButton as r } from "./DatasetDownloadButton.js";
|
|
3
|
+
export { e as DATASET_HOSTING_CONFIG, r as DatasetDownloadButton, r as DatasetDownloadButtonDefault, t as fillRepository, n as normalizeHosting };
|
|
@@ -2,8 +2,6 @@ import { Action } from '@sage-bionetworks/synapse-types';
|
|
|
2
2
|
export type ActionRequiredListItemProps = {
|
|
3
3
|
action: Action;
|
|
4
4
|
count?: number;
|
|
5
|
-
/** Invoked when a user clicks "View Sharing Settings" for a set of files that require the Download permission*/
|
|
6
|
-
onViewSharingSettingsClicked?: (benefactorId: string) => void;
|
|
7
5
|
};
|
|
8
6
|
export declare function ActionRequiredListItem(props: ActionRequiredListItemProps): import("react/jsx-runtime").JSX.Element;
|
|
9
7
|
//# sourceMappingURL=ActionRequiredListItem.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionRequiredListItem.d.ts","sourceRoot":"","sources":["../../../src/components/DownloadCart/ActionRequiredListItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAA;AAKxD,MAAM,MAAM,2BAA2B,GAAG;IACxC,MAAM,EAAE,MAAM,CAAA;IACd,KAAK,CAAC,EAAE,MAAM,CAAA;
|
|
1
|
+
{"version":3,"file":"ActionRequiredListItem.d.ts","sourceRoot":"","sources":["../../../src/components/DownloadCart/ActionRequiredListItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAA;AAKxD,MAAM,MAAM,2BAA2B,GAAG;IACxC,MAAM,EAAE,MAAM,CAAA;IACd,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AAED,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,2BAA2B,2CAmCxE"}
|
|
@@ -4,7 +4,7 @@ import { EnableTwoFaRequirementCard as n } from "./EnableTwoFaRequirementCard.js
|
|
|
4
4
|
import { Fragment as r, jsx as i } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/DownloadCart/ActionRequiredListItem.tsx
|
|
6
6
|
function a(a) {
|
|
7
|
-
let { action: o, count: s
|
|
7
|
+
let { action: o, count: s } = a;
|
|
8
8
|
switch (o.concreteType) {
|
|
9
9
|
case "org.sagebionetworks.repo.model.download.MeetAccessRequirement": return /* @__PURE__ */ i(e, {
|
|
10
10
|
accessRequirementId: o.accessRequirementId,
|
|
@@ -12,8 +12,7 @@ function a(a) {
|
|
|
12
12
|
}, o.accessRequirementId);
|
|
13
13
|
case "org.sagebionetworks.repo.model.download.RequestDownload": return /* @__PURE__ */ i(t, {
|
|
14
14
|
entityId: `syn${o.benefactorId}`,
|
|
15
|
-
count: s
|
|
16
|
-
onViewSharingSettingsClicked: c
|
|
15
|
+
count: s
|
|
17
16
|
}, o.benefactorId);
|
|
18
17
|
case "org.sagebionetworks.repo.model.download.EnableTwoFa": return /* @__PURE__ */ i(n, {
|
|
19
18
|
accessRequirementId: o.accessRequirementId,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionRequiredListItem.js","names":[],"sources":["../../../src/components/DownloadCart/ActionRequiredListItem.tsx"],"sourcesContent":["import { Action } from '@sage-bionetworks/synapse-types'\nimport { MeetAccessRequirementCard } from './MeetAccessRequirementCard'\nimport { RequestDownloadCard } from './RequestDownloadCard'\nimport { EnableTwoFaRequirementCard } from './EnableTwoFaRequirementCard'\n\nexport type ActionRequiredListItemProps = {\n action: Action\n count?: number\n
|
|
1
|
+
{"version":3,"file":"ActionRequiredListItem.js","names":[],"sources":["../../../src/components/DownloadCart/ActionRequiredListItem.tsx"],"sourcesContent":["import { Action } from '@sage-bionetworks/synapse-types'\nimport { MeetAccessRequirementCard } from './MeetAccessRequirementCard'\nimport { RequestDownloadCard } from './RequestDownloadCard'\nimport { EnableTwoFaRequirementCard } from './EnableTwoFaRequirementCard'\n\nexport type ActionRequiredListItemProps = {\n action: Action\n count?: number\n}\n\nexport function ActionRequiredListItem(props: ActionRequiredListItemProps) {\n const { action, count } = props\n switch (action.concreteType) {\n case 'org.sagebionetworks.repo.model.download.MeetAccessRequirement': {\n return (\n <MeetAccessRequirementCard\n key={action.accessRequirementId}\n accessRequirementId={action.accessRequirementId}\n count={count}\n />\n )\n }\n case 'org.sagebionetworks.repo.model.download.RequestDownload': {\n return (\n <RequestDownloadCard\n key={action.benefactorId}\n entityId={`syn${action.benefactorId}`}\n count={count}\n />\n )\n }\n case 'org.sagebionetworks.repo.model.download.EnableTwoFa': {\n return (\n <EnableTwoFaRequirementCard\n key={action.accessRequirementId}\n accessRequirementId={action.accessRequirementId}\n count={count}\n />\n )\n }\n\n // case not supported yet\n default:\n return <></>\n }\n}\n"],"mappings":";;;;;AAUA,SAAgB,EAAuB,GAAoC;CACzE,IAAM,EAAE,WAAQ,aAAU;CAC1B,QAAQ,EAAO,cAAf;EACE,KAAK,iEACH,OACE,kBAAC,GAAD;GAEE,qBAAqB,EAAO;GACrB;EACR,GAHM,EAAO,mBAGb;EAGL,KAAK,2DACH,OACE,kBAAC,GAAD;GAEE,UAAU,MAAM,EAAO;GAChB;EACR,GAHM,EAAO,YAGb;EAGL,KAAK,uDACH,OACE,kBAAC,GAAD;GAEE,qBAAqB,EAAO;GACrB;EACR,GAHM,EAAO,mBAGb;EAKL,SACE,OAAO,kBAAA,GAAA,CAAI,CAAA;CACf;AACF"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { DownloadListActionsRequiredProps } from './DownloadListActionsRequired';
|
|
2
1
|
/**
|
|
3
2
|
* Show the Download Cart page.
|
|
4
3
|
*/
|
|
5
|
-
export declare function DownloadCartPage(
|
|
4
|
+
export declare function DownloadCartPage(): import("react/jsx-runtime").JSX.Element;
|
|
6
5
|
export default DownloadCartPage;
|
|
7
6
|
//# sourceMappingURL=DownloadCartPage.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DownloadCartPage.d.ts","sourceRoot":"","sources":["../../../src/components/DownloadCart/DownloadCartPage.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DownloadCartPage.d.ts","sourceRoot":"","sources":["../../../src/components/DownloadCart/DownloadCartPage.tsx"],"names":[],"mappings":"AAkCA;;GAEG;AACH,wBAAgB,gBAAgB,4CAye/B;AAED,eAAe,gBAAgB,CAAA"}
|