synapse-react-client 4.0.44 → 4.0.46
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.d.ts +1 -1
- package/dist/SWC.index.js +2 -2
- package/dist/SWC.index.js.map +1 -1
- package/dist/aridhia-queries/AridhiaKeyFactory.d.ts +1 -0
- package/dist/aridhia-queries/AridhiaKeyFactory.d.ts.map +1 -1
- package/dist/aridhia-queries/AridhiaKeyFactory.js +3 -0
- package/dist/aridhia-queries/AridhiaKeyFactory.js.map +1 -1
- package/dist/aridhia-queries/aridhiaTokenExchange.js +6 -6
- package/dist/aridhia-queries/index.d.ts +1 -0
- package/dist/aridhia-queries/index.d.ts.map +1 -1
- package/dist/aridhia-queries/index.js +11 -10
- package/dist/aridhia-queries/useGetAridhiaVocabularyTerm.d.ts +19 -0
- package/dist/aridhia-queries/useGetAridhiaVocabularyTerm.d.ts.map +1 -0
- package/dist/aridhia-queries/useGetAridhiaVocabularyTerm.js +14 -0
- package/dist/aridhia-queries/useGetAridhiaVocabularyTerm.js.map +1 -0
- package/dist/components/AccessRequirementList/AccessApprovalCheckMark.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/AccessApprovalCheckMark.js +6 -4
- package/dist/components/AccessRequirementList/AccessApprovalCheckMark.js.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementList.d.ts +2 -1
- package/dist/components/AccessRequirementList/AccessRequirementList.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementList.js +126 -125
- package/dist/components/AccessRequirementList/AccessRequirementList.js.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementListItem.d.ts +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementListItem.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/AccessRequirementListItem.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/AccessorRequirementHelpText.js +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/AccessorRequirementHelpText.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.js +28 -16
- 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 +99 -97
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ResearchProjectForm/ResearchProjectForm.js +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ResearchProjectForm/ResearchProjectForm.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ReviewCollaboratorsAndSigningOfficialAccordion.js +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ReviewCollaboratorsAndSigningOfficialAccordion.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.js +11 -8
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/SignatureStatusStep/SignatureStatusStep.js.map +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/requestFlowTypes.d.ts +1 -1
- package/dist/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/requestFlowTypes.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/RequestDataStep.d.ts +1 -4
- package/dist/components/AccessRequirementList/RequestDataStep.d.ts.map +1 -1
- package/dist/components/AccessRequirementList/RequestDataStep.js +15 -18
- package/dist/components/AccessRequirementList/RequestDataStep.js.map +1 -1
- package/dist/components/AccessTokenPage/AccessTokenPage.js +1 -1
- package/dist/components/AccessTokenPage/AccessTokenPage.js.map +1 -1
- package/dist/components/AcknowledgementsPage/AcknowledgementsPage.js +1 -1
- package/dist/components/AcknowledgementsPage/AcknowledgementsPage.js.map +1 -1
- package/dist/components/Aridhia/DarWizard/DarSectionForm.d.ts.map +1 -1
- package/dist/components/Aridhia/DarWizard/DarSectionForm.js +17 -13
- package/dist/components/Aridhia/DarWizard/DarSectionForm.js.map +1 -1
- package/dist/components/Aridhia/DarWizard/DarSubmittedPanel.d.ts +3 -3
- package/dist/components/Aridhia/DarWizard/DarSubmittedPanel.d.ts.map +1 -1
- package/dist/components/Aridhia/DarWizard/DarSubmittedPanel.js +33 -34
- package/dist/components/Aridhia/DarWizard/DarSubmittedPanel.js.map +1 -1
- package/dist/components/Aridhia/fairFormToRjsf.js +1 -1
- package/dist/components/Aridhia/fairFormToRjsf.js.map +1 -1
- package/dist/components/Authentication/LastLoginInfo.js +1 -1
- package/dist/components/Authentication/LastLoginInfo.js.map +1 -1
- package/dist/components/CertificationQuiz/CertificationQuiz.js +1 -1
- package/dist/components/CertificationQuiz/CertificationQuiz.js.map +1 -1
- package/dist/components/ChallengeSubmission/AvailableEvaluationQueueList.js +1 -1
- package/dist/components/ChallengeSubmission/AvailableEvaluationQueueList.js.map +1 -1
- package/dist/components/ChallengeSubmission/EvaluationQueueCurrentRoundInfo.js +1 -1
- package/dist/components/ChallengeSubmission/EvaluationQueueCurrentRoundInfo.js.map +1 -1
- package/dist/components/ChallengeSubmission/SubmissionDirectoryList.js +6 -6
- package/dist/components/ChallengeSubmission/SubmissionDirectoryList.js.map +1 -1
- package/dist/components/ChallengeTeamWizard/ChallengeTeamTable.d.ts.map +1 -1
- package/dist/components/ChallengeTeamWizard/ChallengeTeamTable.js +4 -4
- package/dist/components/ChallengeTeamWizard/ChallengeTeamTable.js.map +1 -1
- package/dist/components/ChallengeTeamWizard/SelectChallengeTeam.js +4 -4
- package/dist/components/CitationPopover/CitationPopoverContent.js +4 -4
- package/dist/components/CitationPopover/CitationPopoverContent.js.map +1 -1
- package/dist/components/ComponentCollapse.d.ts.map +1 -1
- package/dist/components/ComponentCollapse.js +2 -1
- package/dist/components/ComponentCollapse.js.map +1 -1
- package/dist/components/CreateOrUpdateAccessRequirementWizard/CreateOrUpdateAccessRequirementWizard.d.ts.map +1 -1
- package/dist/components/CreateOrUpdateAccessRequirementWizard/CreateOrUpdateAccessRequirementWizard.js +52 -49
- package/dist/components/CreateOrUpdateAccessRequirementWizard/CreateOrUpdateAccessRequirementWizard.js.map +1 -1
- package/dist/components/DataGrid/SynapseGrid.d.ts.map +1 -1
- package/dist/components/DataGrid/SynapseGrid.js +231 -219
- package/dist/components/DataGrid/SynapseGrid.js.map +1 -1
- package/dist/components/DataGrid/SyncGridWithSourceButton.d.ts.map +1 -1
- package/dist/components/DataGrid/SyncGridWithSourceButton.js +5 -4
- package/dist/components/DataGrid/SyncGridWithSourceButton.js.map +1 -1
- package/dist/components/DataGrid/components/ColumnHeaderWithTooltip.d.ts.map +1 -1
- package/dist/components/DataGrid/components/ColumnHeaderWithTooltip.js +7 -5
- package/dist/components/DataGrid/components/ColumnHeaderWithTooltip.js.map +1 -1
- package/dist/components/DataGrid/components/ExportCsvFromGridButton.js +4 -4
- package/dist/components/DataGrid/components/ExportCsvFromGridButton.js.map +1 -1
- package/dist/components/DataGrid/components/ReorderColumnsButton.js +4 -4
- package/dist/components/DataGrid/components/ReorderColumnsButton.js.map +1 -1
- package/dist/components/DataGrid/components/ReorderColumnsDialog.d.ts.map +1 -1
- package/dist/components/DataGrid/components/ReorderColumnsDialog.js +12 -8
- package/dist/components/DataGrid/components/ReorderColumnsDialog.js.map +1 -1
- package/dist/components/DataGrid/components/UploadCsvToGridButton.js +1 -1
- package/dist/components/DataGrid/components/UploadCsvToGridButton.js.map +1 -1
- package/dist/components/DataGrid/hooks/useGridUndoRedo.js +5 -5
- package/dist/components/DataGrid/utils/applyModelChange.d.ts.map +1 -1
- package/dist/components/DataGrid/utils/applyModelChange.js +14 -14
- package/dist/components/DataGrid/utils/applyModelChange.js.map +1 -1
- package/dist/components/DataGrid/utils/columnFactory.js +1 -1
- package/dist/components/DataGrid/utils/columnFactory.js.map +1 -1
- package/dist/components/DataGrid/utils/splitPatch.d.ts.map +1 -1
- package/dist/components/DataGrid/utils/splitPatch.js +22 -13
- package/dist/components/DataGrid/utils/splitPatch.js.map +1 -1
- package/dist/components/DownloadCart/DownloadCartPage.js +1 -1
- package/dist/components/DownloadCart/DownloadCartPage.js.map +1 -1
- package/dist/components/DownloadCart/DownloadIneligibleForPackagingFilesFromListButton.d.ts.map +1 -1
- package/dist/components/DownloadCart/DownloadIneligibleForPackagingFilesFromListButton.js +2 -1
- package/dist/components/DownloadCart/DownloadIneligibleForPackagingFilesFromListButton.js.map +1 -1
- package/dist/components/DownloadCart/DownloadIneligibleForPackagingFilesFromListButton.module.js.map +1 -1
- package/dist/components/DownloadCart/DownloadIneligibleForPackagingFilesFromListButton.module.scss +1 -3
- package/dist/components/EntityBadgeIcons/EntityBadgeIcons.d.ts.map +1 -1
- package/dist/components/EntityBadgeIcons/EntityBadgeIcons.js +16 -10
- package/dist/components/EntityBadgeIcons/EntityBadgeIcons.js.map +1 -1
- package/dist/components/EntityDownloadButton/EntityDownloadButton.js +1 -1
- package/dist/components/EntityDownloadButton/EntityDownloadButton.js.map +1 -1
- package/dist/components/EntityFinder/EntityFinder.js +4 -4
- package/dist/components/EntityFinder/EntityIdTextField.js +1 -1
- package/dist/components/EntityFinder/EntityIdTextField.js.map +1 -1
- package/dist/components/EntityFinder/tree/VirtualizedTree.d.ts.map +1 -1
- package/dist/components/EntityFinder/tree/VirtualizedTree.js +5 -4
- package/dist/components/EntityFinder/tree/VirtualizedTree.js.map +1 -1
- package/dist/components/EntityHeaderTable/EntityHeaderTable.js +1 -1
- package/dist/components/EntityHeaderTable/EntityHeaderTable.js.map +1 -1
- package/dist/components/EntityTreeTable/components/EntityNameCell.d.ts.map +1 -1
- package/dist/components/EntityTreeTable/components/EntityNameCell.js +2 -1
- package/dist/components/EntityTreeTable/components/EntityNameCell.js.map +1 -1
- package/dist/components/EntityUpload/FileUploadProgress.d.ts.map +1 -1
- package/dist/components/EntityUpload/FileUploadProgress.js +11 -7
- package/dist/components/EntityUpload/FileUploadProgress.js.map +1 -1
- package/dist/components/Evaluation/round_limits/EvaluationRoundLimitOptionsList.d.ts.map +1 -1
- package/dist/components/Evaluation/round_limits/EvaluationRoundLimitOptionsList.js +4 -3
- package/dist/components/Evaluation/round_limits/EvaluationRoundLimitOptionsList.js.map +1 -1
- package/dist/components/ExperimentalMode/ExperimentalMode.js +1 -1
- package/dist/components/ExperimentalMode/ExperimentalMode.js.map +1 -1
- package/dist/components/ExternalFileHandleLink/ExternalFileHandleLink.js +1 -1
- package/dist/components/ExternalFileHandleLink/ExternalFileHandleLink.js.map +1 -1
- package/dist/components/FormTemplateEditor/ChoiceOptionsEditor.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/ChoiceOptionsEditor.js +2 -1
- package/dist/components/FormTemplateEditor/ChoiceOptionsEditor.js.map +1 -1
- package/dist/components/FormTemplateEditor/FieldDefinitionDrawer.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/FieldDefinitionDrawer.js +2 -1
- package/dist/components/FormTemplateEditor/FieldDefinitionDrawer.js.map +1 -1
- package/dist/components/FormTemplateEditor/FieldLibrary.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/FieldLibrary.js +2 -1
- package/dist/components/FormTemplateEditor/FieldLibrary.js.map +1 -1
- package/dist/components/FormTemplateEditor/FieldLibraryRow.js +4 -4
- package/dist/components/FormTemplateEditor/FieldLibraryRow.js.map +1 -1
- package/dist/components/FormTemplateEditor/FormStructurePanel.js +1 -1
- package/dist/components/FormTemplateEditor/FormStructurePanel.js.map +1 -1
- package/dist/components/FormTemplateEditor/FormTemplateEditorForm.js +1 -1
- package/dist/components/FormTemplateEditor/FormTemplateEditorForm.js.map +1 -1
- package/dist/components/FormTemplateEditor/StepCard.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/StepCard.js +15 -10
- package/dist/components/FormTemplateEditor/StepCard.js.map +1 -1
- package/dist/components/FormTemplateEditor/StepFieldRow.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/StepFieldRow.js +11 -6
- package/dist/components/FormTemplateEditor/StepFieldRow.js.map +1 -1
- package/dist/components/FormTemplateEditor/TemplateFileHandleField.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/TemplateFileHandleField.js +2 -1
- package/dist/components/FormTemplateEditor/TemplateFileHandleField.js.map +1 -1
- package/dist/components/FormTemplateEditor/useSaveFormTemplate.d.ts.map +1 -1
- package/dist/components/FormTemplateEditor/useSaveFormTemplate.js.map +1 -1
- package/dist/components/FormTemplateReferenceField/FormTemplatePreviewDialog.d.ts +9 -0
- package/dist/components/FormTemplateReferenceField/FormTemplatePreviewDialog.d.ts.map +1 -0
- package/dist/components/FormTemplateReferenceField/FormTemplatePreviewDialog.js +45 -0
- package/dist/components/FormTemplateReferenceField/FormTemplatePreviewDialog.js.map +1 -0
- package/dist/components/FormTemplateReferenceField/FormTemplateReferenceField.d.ts +22 -0
- package/dist/components/FormTemplateReferenceField/FormTemplateReferenceField.d.ts.map +1 -0
- package/dist/components/FormTemplateReferenceField/FormTemplateReferenceField.js +139 -0
- package/dist/components/FormTemplateReferenceField/FormTemplateReferenceField.js.map +1 -0
- package/dist/components/Forum/ForumTable.d.ts +17 -5
- package/dist/components/Forum/ForumTable.d.ts.map +1 -1
- package/dist/components/Forum/ForumTable.js +94 -77
- package/dist/components/Forum/ForumTable.js.map +1 -1
- package/dist/components/GenericCard/DuoTermTags/DuoTermTags.js +45 -45
- package/dist/components/GenericCard/PortalDOI/PortalDOI.js +5 -5
- package/dist/components/GenericCard/PortalDOI/PortalDOI.js.map +1 -1
- package/dist/components/GenericCard/TableRowGenericCard.js +1 -1
- package/dist/components/GenericCard/TableRowGenericCard.js.map +1 -1
- package/dist/components/HelpPopover/HelpPopover.js +1 -1
- package/dist/components/HelpPopover/HelpPopover.js.map +1 -1
- package/dist/components/IconSvg/IconSvg.d.ts.map +1 -1
- package/dist/components/IconSvg/IconSvg.js +154 -47
- package/dist/components/IconSvg/IconSvg.js.map +1 -1
- package/dist/components/JsonSchemaForm/templates/ButtonTemplate.d.ts.map +1 -1
- package/dist/components/JsonSchemaForm/templates/ButtonTemplate.js +19 -16
- package/dist/components/JsonSchemaForm/templates/ButtonTemplate.js.map +1 -1
- package/dist/components/JsonSchemaForm/templates/RJSFInputLabel.d.ts.map +1 -1
- package/dist/components/JsonSchemaForm/templates/RJSFInputLabel.js +2 -1
- package/dist/components/JsonSchemaForm/templates/RJSFInputLabel.js.map +1 -1
- package/dist/components/JsonSchemaForm/widgets/PhoneWidget.d.ts +9 -0
- package/dist/components/JsonSchemaForm/widgets/PhoneWidget.d.ts.map +1 -0
- package/dist/components/JsonSchemaForm/widgets/PhoneWidget.js +21 -0
- package/dist/components/JsonSchemaForm/widgets/PhoneWidget.js.map +1 -0
- package/dist/components/Markdown/MarkdownCollapse.d.ts.map +1 -1
- package/dist/components/Markdown/MarkdownCollapse.js +3 -1
- package/dist/components/Markdown/MarkdownCollapse.js.map +1 -1
- package/dist/components/MissingQueryResultsWarning/MissingQueryResultsWarning.js +1 -1
- package/dist/components/MissingQueryResultsWarning/MissingQueryResultsWarning.js.map +1 -1
- package/dist/components/OAuthClientManagement/OAuthManagement.js +14 -13
- package/dist/components/OAuthClientManagement/OAuthManagement.js.map +1 -1
- package/dist/components/PortalList/PortalCard.d.ts.map +1 -1
- package/dist/components/PortalList/PortalCard.js +6 -5
- package/dist/components/PortalList/PortalCard.js.map +1 -1
- package/dist/components/PortalList/PortalList.js +4 -4
- package/dist/components/PortalList/PortalList.js.map +1 -1
- package/dist/components/ProjectVisibilityChip/ProjectVisibilityChip.js +6 -6
- package/dist/components/QueryBuilder/FilterConditionRow.js +4 -4
- package/dist/components/QueryCountButton/QueryCountButton.js +5 -5
- package/dist/components/QueryCountButton/QueryCountButton.js.map +1 -1
- package/dist/components/ReleaseCard/ReleaseCardLarge.js +5 -5
- package/dist/components/ReleaseCard/ReleaseCardLarge.js.map +1 -1
- package/dist/components/SetAccessRequirementCommonFields/SetAccessRequirementCommonFields.d.ts.map +1 -1
- package/dist/components/SetAccessRequirementCommonFields/SetAccessRequirementCommonFields.js +142 -108
- package/dist/components/SetAccessRequirementCommonFields/SetAccessRequirementCommonFields.js.map +1 -1
- package/dist/components/SetBasicAccessRequirementFields/AccessorRequirements.d.ts.map +1 -1
- package/dist/components/SetBasicAccessRequirementFields/AccessorRequirements.js +15 -15
- package/dist/components/SetBasicAccessRequirementFields/AccessorRequirements.js.map +1 -1
- package/dist/components/SetManagedAccessRequirementFields/SetManagedAccessRequirementFields.d.ts.map +1 -1
- package/dist/components/SetManagedAccessRequirementFields/SetManagedAccessRequirementFields.js +57 -55
- package/dist/components/SetManagedAccessRequirementFields/SetManagedAccessRequirementFields.js.map +1 -1
- package/dist/components/ShareThisPage/ShareThisPage.js +4 -4
- package/dist/components/ShareThisPage/ShareThisPage.js.map +1 -1
- package/dist/components/SustainabilityScorecard/DialLayout.js +1 -1
- package/dist/components/SustainabilityScorecard/DialLayout.js.map +1 -1
- package/dist/components/SustainabilityScorecard/SustainabilityScorecard.js +1 -1
- package/dist/components/SustainabilityScorecard/SustainabilityScorecard.js.map +1 -1
- package/dist/components/SynapseChat/SynapseChat.js +1 -1
- package/dist/components/SynapseChat/SynapseChat.js.map +1 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.d.ts.map +1 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.js +2 -1
- package/dist/components/SynapseChat/SynapseChatInteraction.js.map +1 -1
- package/dist/components/SynapseChat/components/ChatInputArea/ChatInputArea.js +1 -1
- package/dist/components/SynapseChat/components/ChatInputArea/ChatInputArea.js.map +1 -1
- package/dist/components/SynapseFooter/SynapseFooter.js +1 -1
- package/dist/components/SynapseFooter/SynapseFooter.js.map +1 -1
- package/dist/components/SynapseHomepageV2/SynapseFeaturedDatasetItem.js +1 -1
- package/dist/components/SynapseHomepageV2/SynapseFeaturedDatasetItem.js.map +1 -1
- package/dist/components/SynapseHomepageV2/SynapseHomepageNavBar.d.ts.map +1 -1
- package/dist/components/SynapseHomepageV2/SynapseHomepageNavBar.js +2 -1
- package/dist/components/SynapseHomepageV2/SynapseHomepageNavBar.js.map +1 -1
- package/dist/components/SynapseHomepageV2/SynapseInActionItem.js +4 -4
- package/dist/components/SynapseHomepageV2/SynapseInActionItem.js.map +1 -1
- package/dist/components/SynapseHomepageV2/SynapseTrendingProjectsItem.js +1 -1
- package/dist/components/SynapseHomepageV2/SynapseTrendingProjectsItem.js.map +1 -1
- package/dist/components/SynapseNavDrawer/SynapseNavDrawer.d.ts.map +1 -1
- package/dist/components/SynapseNavDrawer/SynapseNavDrawer.js +4 -1
- package/dist/components/SynapseNavDrawer/SynapseNavDrawer.js.map +1 -1
- package/dist/components/SynapsePortalBanners/SynapsePortalBanners.js +1 -1
- package/dist/components/SynapsePortalBanners/SynapsePortalBanners.js.map +1 -1
- package/dist/components/SynapseSearchPageResults/SynapseSearchPageResults.js +1 -1
- package/dist/components/SynapseSearchPageResults/SynapseSearchPageResults.js.map +1 -1
- package/dist/components/SynapseSearchPageResults/SynapseSearchResultsCard.d.ts.map +1 -1
- package/dist/components/SynapseSearchPageResults/SynapseSearchResultsCard.js +12 -9
- package/dist/components/SynapseSearchPageResults/SynapseSearchResultsCard.js.map +1 -1
- package/dist/components/SynapseTable/RowSelection/RowSelectionControls.js +4 -4
- package/dist/components/SynapseTable/RowSelection/RowSelectionControls.js.map +1 -1
- package/dist/components/SynapseTable/datasets/DatasetItemsEditor.js +140 -140
- package/dist/components/SynapseTable/datasets/DatasetItemsEditor.js.map +1 -1
- package/dist/components/TableColumnSchemaEditor/ColumnModelForm.js +1 -1
- package/dist/components/TableColumnSchemaEditor/ColumnModelForm.js.map +1 -1
- package/dist/components/TableColumnSchemaEditor/ImportTableColumnsButton.js +1 -1
- package/dist/components/TableColumnSchemaEditor/ImportTableColumnsButton.js.map +1 -1
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaEditorUtils.d.ts.map +1 -1
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaEditorUtils.js.map +1 -1
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaForm.js +9 -9
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaForm.js.map +1 -1
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaFormActions.d.ts.map +1 -1
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaFormActions.js +6 -4
- package/dist/components/TableColumnSchemaEditor/TableColumnSchemaFormActions.js.map +1 -1
- package/dist/components/TanStackTable/ColumnHeader.js +1 -1
- package/dist/components/TanStackTable/ColumnHeader.js.map +1 -1
- package/dist/components/TeamSubjectsSelector/TeamBadgeOrError.js +1 -1
- package/dist/components/TeamSubjectsSelector/TeamBadgeOrError.js.map +1 -1
- package/dist/components/TeamSubjectsSelector/TeamSubjectsSelector.d.ts.map +1 -1
- package/dist/components/TeamSubjectsSelector/TeamSubjectsSelector.js +4 -3
- package/dist/components/TeamSubjectsSelector/TeamSubjectsSelector.js.map +1 -1
- package/dist/components/Webhook/WebhookDashboard.js +1 -1
- package/dist/components/Webhook/WebhookDashboard.js.map +1 -1
- package/dist/components/dataaccess/AccessRequirementDashboard.js +4 -4
- package/dist/components/dataaccess/AccessRequirementDashboard.js.map +1 -1
- package/dist/components/dataaccess/AccessRequirementTable.js +1 -1
- package/dist/components/dataaccess/AccessRequirementTable.js.map +1 -1
- package/dist/components/dataaccess/EDucTemplateTable.d.ts.map +1 -1
- package/dist/components/dataaccess/EDucTemplateTable.js +13 -11
- package/dist/components/dataaccess/EDucTemplateTable.js.map +1 -1
- package/dist/components/dataaccess/FormTemplateTable.js +6 -6
- package/dist/components/dataaccess/FormTemplateTable.js.map +1 -1
- package/dist/components/dataaccess/ReviewerDashboard.js +17 -17
- package/dist/components/dataaccess/ReviewerDashboard.js.map +1 -1
- package/dist/components/dataaccess/SubmissionPage/SubmissionPage.js +4 -4
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.d.ts.map +1 -1
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.js +4 -1
- package/dist/components/dataaccess/UserAccessRequestHistory/InFlightEDucSignaturesTable.js.map +1 -1
- package/dist/components/doi/CreateOrUpdateDoiModal.js +1 -1
- package/dist/components/doi/CreateOrUpdateDoiModal.js.map +1 -1
- package/dist/components/download_list/DownloadDetails.d.ts.map +1 -1
- package/dist/components/download_list/DownloadDetails.js +12 -10
- package/dist/components/download_list/DownloadDetails.js.map +1 -1
- package/dist/components/entity/metadata/AnnotationsTable.js +1 -1
- package/dist/components/entity/metadata/AnnotationsTable.js.map +1 -1
- package/dist/components/entity/page/CreatedByModifiedBy.js +1 -1
- package/dist/components/entity/page/CreatedByModifiedBy.js.map +1 -1
- package/dist/components/entity/page/action_menu/EntityActionMenu.d.ts.map +1 -1
- package/dist/components/entity/page/action_menu/EntityActionMenu.js.map +1 -1
- package/dist/components/entity/page/title_bar/useGetEntityTitleBarProperties.js +1 -1
- package/dist/components/entity/page/title_bar/useGetEntityTitleBarProperties.js.map +1 -1
- package/dist/components/error/ErrorChip.d.ts.map +1 -1
- package/dist/components/error/ErrorChip.js +2 -1
- package/dist/components/error/ErrorChip.js.map +1 -1
- package/dist/components/table/CsvPreview/CreateTableFromCsvDialog.js +14 -14
- package/dist/components/table/CsvPreview/CsvPreviewWithOptions.js +4 -4
- package/dist/components/table/CsvPreview/CsvPreviewWithOptions.js.map +1 -1
- package/dist/components/widgets/facet-nav/FacetNavPanel.js +1 -1
- package/dist/components/widgets/facet-nav/FacetNavPanel.js.map +1 -1
- package/dist/features/curator/dashboard/components/NextStepButton.d.ts.map +1 -1
- package/dist/features/curator/dashboard/components/NextStepButton.js +7 -6
- package/dist/features/curator/dashboard/components/NextStepButton.js.map +1 -1
- package/dist/features/entity/metadata-task/components/CreateOrUpdateCurationTaskDialog.js +8 -8
- package/dist/features/entity/metadata-task/components/CreateOrUpdateCurationTaskDialog.js.map +1 -1
- package/dist/features/entity/metadata-task/components/MetadataTaskTableActionCell.js +4 -4
- package/dist/features/entity/metadata-task/components/MetadataTaskTableActionCell.js.map +1 -1
- package/dist/features/entity/metadata-task/components/MetadataTasksPage.js +4 -4
- package/dist/features/entity/metadata-task/components/MetadataTasksPage.js.map +1 -1
- package/dist/features/entity/metadata-task/components/MetadataTasksTableAssigneeCell.js +1 -1
- package/dist/features/entity/metadata-task/components/MetadataTasksTableAssigneeCell.js.map +1 -1
- package/dist/features/entity/metadata-task/create-task/CurateTaskForm.js +4 -4
- package/dist/features/entity/metadata-task/create-task/CurateTaskForm.js.map +1 -1
- package/dist/features/entity/metadata-task/create-task/TaskCategoryCard.js +1 -1
- package/dist/features/entity/metadata-task/create-task/TaskCategoryCard.js.map +1 -1
- package/dist/features/entity/metadata-task/create-task/TaskFormHeader.js +1 -1
- package/dist/features/entity/metadata-task/create-task/TaskFormHeader.js.map +1 -1
- package/dist/features/entity/metadata-task/create-task/curationTaskFlowRoutes.js +10 -10
- package/dist/features/entity/metadata-task/create-task/curationTaskFlowRoutes.js.map +1 -1
- package/dist/features/team/invitation/components/OpenInvitationsToUserCard.js +1 -1
- package/dist/features/team/invitation/components/OpenInvitationsToUserCard.js.map +1 -1
- package/dist/mocks/accessRequirement/mockJsonSchemaAccessRequirements.d.ts +5 -0
- package/dist/mocks/accessRequirement/mockJsonSchemaAccessRequirements.d.ts.map +1 -1
- package/dist/mocks/accessRequirement/mockJsonSchemaAccessRequirements.js +37 -26
- package/dist/mocks/accessRequirement/mockJsonSchemaAccessRequirements.js.map +1 -1
- package/dist/mocks/msw/handlers/aridhiaHandlers.d.ts +8 -0
- package/dist/mocks/msw/handlers/aridhiaHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/aridhiaHandlers.js +52 -41
- package/dist/mocks/msw/handlers/aridhiaHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/discussionHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/discussionHandlers.js +40 -33
- package/dist/mocks/msw/handlers/discussionHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/entityHandlers.d.ts.map +1 -1
- package/dist/mocks/msw/handlers/entityHandlers.js +70 -67
- package/dist/mocks/msw/handlers/entityHandlers.js.map +1 -1
- package/dist/mocks/msw/handlers/gridHandlers.js +2 -2
- package/dist/mocks/msw/handlers/gridHandlers.js.map +1 -1
- package/dist/mocks/msw/server.d.ts.map +1 -1
- package/dist/mocks/msw/server.js +4 -2
- package/dist/mocks/msw/server.js.map +1 -1
- package/dist/synapse-client/SynapseClient.d.ts +10 -0
- package/dist/synapse-client/SynapseClient.d.ts.map +1 -1
- package/dist/synapse-client/SynapseClient.js +486 -482
- package/dist/synapse-client/SynapseClient.js.map +1 -1
- package/dist/synapse-client/index.js +3 -3
- package/dist/synapse-queries/KeyFactory.d.ts +13 -1
- package/dist/synapse-queries/KeyFactory.d.ts.map +1 -1
- package/dist/synapse-queries/KeyFactory.js +11 -1
- package/dist/synapse-queries/KeyFactory.js.map +1 -1
- package/dist/synapse-queries/dataaccess/index.js +4 -4
- package/dist/synapse-queries/dataaccess/useAccessRequirements.d.ts.map +1 -1
- package/dist/synapse-queries/dataaccess/useAccessRequirements.js +4 -1
- package/dist/synapse-queries/dataaccess/useAccessRequirements.js.map +1 -1
- package/dist/synapse-queries/dataaccess/useEDuc.d.ts +19 -5
- package/dist/synapse-queries/dataaccess/useEDuc.d.ts.map +1 -1
- package/dist/synapse-queries/dataaccess/useEDuc.js +29 -21
- package/dist/synapse-queries/dataaccess/useEDuc.js.map +1 -1
- package/dist/synapse-queries/dataaccess/useFormTemplate.d.ts +12 -0
- package/dist/synapse-queries/dataaccess/useFormTemplate.d.ts.map +1 -1
- package/dist/synapse-queries/dataaccess/useFormTemplate.js +52 -30
- package/dist/synapse-queries/dataaccess/useFormTemplate.js.map +1 -1
- package/dist/synapse-queries/forum/useForum.d.ts +5 -1
- package/dist/synapse-queries/forum/useForum.d.ts.map +1 -1
- package/dist/synapse-queries/forum/useForum.js +23 -1
- package/dist/synapse-queries/forum/useForum.js.map +1 -1
- package/dist/synapse-queries/index.js +185 -184
- package/dist/synapse-queries/jsonschema/useCreateJsonSchema.d.ts +5 -3
- package/dist/synapse-queries/jsonschema/useCreateJsonSchema.d.ts.map +1 -1
- package/dist/synapse-queries/jsonschema/useCreateJsonSchema.js +12 -15
- package/dist/synapse-queries/jsonschema/useCreateJsonSchema.js.map +1 -1
- package/dist/synapse-queries/user/useGetUserChallenges.d.ts.map +1 -1
- package/dist/synapse-queries/user/useGetUserChallenges.js.map +1 -1
- package/dist/theme/DefaultTheme.d.ts.map +1 -1
- package/dist/theme/DefaultTheme.js +4 -1
- package/dist/theme/DefaultTheme.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/utils/APIConstants.d.ts.map +1 -1
- package/dist/utils/APIConstants.js.map +1 -1
- package/dist/utils/AppUtils/AppUtils.js +1 -1
- package/dist/utils/AppUtils/AppUtils.js.map +1 -1
- package/dist/utils/featureflag/FeatureFlags.d.ts.map +1 -1
- package/dist/utils/featureflag/FeatureFlags.js.map +1 -1
- package/dist/utils/functions/EntityTypeUtils.d.ts.map +1 -1
- package/dist/utils/functions/EntityTypeUtils.js.map +1 -1
- package/dist/utils/functions/getEndpoint.d.ts +1 -0
- package/dist/utils/functions/getEndpoint.d.ts.map +1 -1
- package/dist/utils/functions/getEndpoint.js +3 -3
- package/dist/utils/functions/getEndpoint.js.map +1 -1
- package/dist/utils/types/RequestableAccessRequirement.d.ts +8 -0
- package/dist/utils/types/RequestableAccessRequirement.d.ts.map +1 -0
- package/dist/utils/types/RequestableAccessRequirement.js +9 -0
- package/dist/utils/types/RequestableAccessRequirement.js.map +1 -0
- package/package.json +6 -5
- package/dist/testutils/ReactQueryMockUtils.js +0 -676
- package/dist/testutils/ReactQueryMockUtils.js.map +0 -1
|
@@ -15,10 +15,10 @@ import { FileHandleAssociateType as pe } from "@sage-bionetworks/synapse-types";
|
|
|
15
15
|
//#region src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.tsx
|
|
16
16
|
var g = "500px", _ = "Send for electronic signature", v = "Keep your existing DUC or send a new one?", y = "Keep Existing DUC", b = "Send new DUC", x = "Restart DUC signing?", S = "I understand, send new DUC", me = "Sorry, we couldn't check the status of your existing signature request.", he = "Sorry, we couldn't apply your changes to your existing signature request.", ge = "Sorry, we couldn't cancel your existing signature request.", _e = "Sorry, we couldn't send your DUC for electronic signature.";
|
|
17
17
|
function C(u) {
|
|
18
|
-
let { managedACTAccessRequirement: C, onHide: ye, onBackClicked: be, onSendForSignature: E, onManualUpload: xe, previewSrcOverride: D } = u, { data: O, isLoading:
|
|
18
|
+
let { managedACTAccessRequirement: C, onHide: ye, onBackClicked: be, onSendForSignature: E, onManualUpload: xe, previewSrcOverride: D } = u, { data: O, isLoading: k } = t(String(C.id), {
|
|
19
19
|
staleTime: Infinity,
|
|
20
20
|
throwOnError: !0
|
|
21
|
-
}),
|
|
21
|
+
}), A = O?.id, j = String(C.id), M = !!O?.eDucSignatureEnvelopeId, { data: Se, isLoading: Ce, error: N } = r(A ?? "", { enabled: !!A }), P = Se?.fileHandleId, { blobUrl: F, error: I } = ce(D || !P || !A ? void 0 : e.getPortalFileHandleServletUrl(P, A, pe.DataAccessRequestAttachment)), { mutateAsync: we, isPending: Te, error: L, reset: Ee } = n(), { mutate: De, isPending: Oe, error: R, reset: ke } = ne({ onSuccess: () => E() }), { mutateAsync: Ae, isPending: je, error: z, reset: Me } = re(), { mutate: B, isPending: Ne, error: V, reset: Pe } = te({ onSuccess: () => E() }), { data: H, isLoading: Fe } = ee(A ?? "", { enabled: !!A }), U = H?.remaining != null && H.remaining <= 0, W = U && !M, [G, K] = o(null), [Ie, q] = o(!1), J = Te || Oe || je || Ne, Y = k || !!A && Ce || !D && !!P && !F && !I, X = Y || !D && !F || J, Le = X || Fe || W, Z = L && {
|
|
22
22
|
title: me,
|
|
23
23
|
reason: L.reason
|
|
24
24
|
} || R && {
|
|
@@ -30,23 +30,35 @@ function C(u) {
|
|
|
30
30
|
} || V && {
|
|
31
31
|
title: _e,
|
|
32
32
|
reason: V.reason
|
|
33
|
-
} ||
|
|
33
|
+
} || Ie && {
|
|
34
34
|
title: "Sorry, you've used all of your electronic signature requests.",
|
|
35
35
|
reason: /* @__PURE__ */ m(a, { quota: H?.quota })
|
|
36
|
-
},
|
|
37
|
-
|
|
38
|
-
},
|
|
39
|
-
if (!
|
|
40
|
-
if (
|
|
41
|
-
B(
|
|
36
|
+
}, Re = () => {
|
|
37
|
+
Ee(), ke(), Me(), Pe(), q(!1);
|
|
38
|
+
}, ze = async () => {
|
|
39
|
+
if (!A) return;
|
|
40
|
+
if (Re(), !M) {
|
|
41
|
+
B({
|
|
42
|
+
requestId: A,
|
|
43
|
+
accessRequirementId: j
|
|
44
|
+
});
|
|
42
45
|
return;
|
|
43
46
|
}
|
|
44
|
-
let e = await
|
|
47
|
+
let e = await we(A).catch(() => null);
|
|
45
48
|
e !== null && (e ? K("keepOrReplace") : U ? q(!0) : K("restartSigning"));
|
|
46
|
-
},
|
|
47
|
-
|
|
49
|
+
}, Be = () => {
|
|
50
|
+
A && (K(null), De({
|
|
51
|
+
requestId: A,
|
|
52
|
+
accessRequirementId: j
|
|
53
|
+
}));
|
|
48
54
|
}, Q = async () => {
|
|
49
|
-
|
|
55
|
+
A && (K(null), await Ae({
|
|
56
|
+
requestId: A,
|
|
57
|
+
accessRequirementId: j
|
|
58
|
+
}).then(() => !0, () => !1) && B({
|
|
59
|
+
requestId: A,
|
|
60
|
+
accessRequirementId: j
|
|
61
|
+
}));
|
|
50
62
|
}, $ = () => {
|
|
51
63
|
K(null);
|
|
52
64
|
};
|
|
@@ -116,9 +128,9 @@ function C(u) {
|
|
|
116
128
|
component: "span",
|
|
117
129
|
children: /* @__PURE__ */ m(l, {
|
|
118
130
|
variant: "contained",
|
|
119
|
-
disabled:
|
|
131
|
+
disabled: Le,
|
|
120
132
|
onClick: () => {
|
|
121
|
-
|
|
133
|
+
ze();
|
|
122
134
|
},
|
|
123
135
|
children: J ? "Sending..." : _
|
|
124
136
|
})
|
|
@@ -179,7 +191,7 @@ function C(u) {
|
|
|
179
191
|
}),
|
|
180
192
|
/* @__PURE__ */ m(l, {
|
|
181
193
|
variant: "contained",
|
|
182
|
-
onClick:
|
|
194
|
+
onClick: Be,
|
|
183
195
|
children: y
|
|
184
196
|
})
|
|
185
197
|
] })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EDucPreviewStep.js","names":[],"sources":["../../../../../src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.tsx"],"sourcesContent":["import { ConfirmationDialog } from '@/components/ConfirmationDialog'\nimport { CANCEL_BUTTON_TEXT } from '@/components/ConfirmationDialog/ConfirmationDialog'\nimport { DialogBase } from '@/components/DialogBase'\nimport {\n useCheckDataAccessRequestSignatureUpdatable,\n useGetDataAccessRequestForUpdate,\n useGetDataAccessRequestPreview,\n useGetDataAccessRequestSignatureQuota,\n useInitiateDataAccessRequestSignature,\n useUpdateDataAccessRequestSignature,\n useVoidDataAccessRequestSignature,\n} from '@/synapse-queries'\nimport SynapseClient from '@/synapse-client'\nimport {\n Alert,\n Box,\n Button,\n ButtonProps,\n DialogActions,\n DialogContent,\n Divider,\n Skeleton,\n Stack,\n Tooltip,\n Typography,\n} from '@mui/material'\nimport { FileHandleAssociateType } from '@sage-bionetworks/synapse-types'\nimport { ReactNode, useState } from 'react'\nimport { useFetchBlobUrl } from '@/utils/hooks/useFetchBlobUrl'\nimport { DialogBaseTitle } from '../../../DialogBase'\nimport {\n SIGNATURE_QUOTA_EXHAUSTED_TITLE,\n SignatureQuotaExhaustedMessage,\n} from '../eDucSignatureUtils'\nimport { longFieldLabelSx } from '../styles'\nimport { RequestFlowAccessRequirement } from '../requestFlowTypes'\n\nconst PDF_PREVIEW_HEIGHT = '500px'\n\nexport const SEND_FOR_SIGNATURE_BUTTON_TEXT = 'Send for electronic signature'\n\nexport const KEEP_OR_REPLACE_DIALOG_TITLE =\n 'Keep your existing DUC or send a new one?'\nexport const KEEP_EXISTING_DUC_BUTTON_TEXT = 'Keep Existing DUC'\nexport const SEND_NEW_DUC_BUTTON_TEXT = 'Send new DUC'\n\nexport const RESTART_SIGNING_DIALOG_TITLE = 'Restart DUC signing?'\nexport const RESTART_SIGNING_CONFIRM_BUTTON_TEXT = 'I understand, send new DUC'\n\nconst PRECHECK_ERROR_TITLE =\n \"Sorry, we couldn't check the status of your existing signature request.\"\nconst UPDATE_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't apply your changes to your existing signature request.\"\nconst VOID_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't cancel your existing signature request.\"\nconst INITIATE_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't send your DUC for electronic signature.\"\n\nexport type EDucPreviewStepProps = {\n managedACTAccessRequirement: RequestFlowAccessRequirement\n onHide: () => void\n onBackClicked: () => void\n onSendForSignature: () => void\n onManualUpload: () => void\n /**\n * Optional iframe `src` override for demos and stories. When set, the blob fetch is skipped\n * and this URL is used directly as the iframe src. Production callers should not set this.\n */\n previewSrcOverride?: string\n}\n\n/**\n * Wizard step shown after the \"Review / Create a DUC\" step (PORTALS-4414).\n * Displays the generated eDUC document in an iframe so the user can review it\n * before sending it for electronic signature (PORTALS-4378) or manually printing and\n * uploading a signed PDF (PORTALS-4379).\n */\nexport default function EDucPreviewStep(props: EDucPreviewStepProps) {\n const {\n managedACTAccessRequirement,\n onHide,\n onBackClicked,\n onSendForSignature,\n onManualUpload,\n previewSrcOverride,\n } = props\n\n const { data: dataAccessRequest, isLoading: isLoadingDar } =\n useGetDataAccessRequestForUpdate(String(managedACTAccessRequirement.id), {\n staleTime: Infinity,\n throwOnError: true,\n })\n\n const requestId = dataAccessRequest?.id\n const hasSignatureEnvelope = Boolean(\n dataAccessRequest?.eDucSignatureEnvelopeId,\n )\n\n // Once the user commits to sending, the preview query must not run again: GET\n // /dataAccessRequest/{id}/preview has server-side side effects (it creates a signature envelope\n // and resets the DAR to draft), and every signature mutation invalidates the DAR query key --\n // which would otherwise refetch the preview between the DELETE and the POST below. PLFM-9938\n // tracks making that endpoint side-effect free; until it lands the call stays a query (callers\n // read it declaratively) and this latch is what keeps it from firing at the wrong moment.\n //\n // This latches for the lifetime of the step rather than clearing when a send fails. Re-enabling\n // the query would refetch it (the preview is stale the moment it lands), firing those side\n // effects behind an error message -- worst of all after a successful void, where it would mint a\n // replacement envelope the user never asked for. The already-fetched preview stays on screen, and\n // leaving and re-entering the step regenerates it.\n const [hasStartedSendSequence, setHasStartedSendSequence] = useState(false)\n\n const {\n data: previewFileHandle,\n isLoading: isLoadingPreview,\n error: previewError,\n } = useGetDataAccessRequestPreview(requestId ?? '', {\n enabled: Boolean(requestId) && !hasStartedSendSequence,\n })\n\n const previewFileHandleId = previewFileHandle?.fileHandleId\n const { blobUrl, error: blobError } = useFetchBlobUrl(\n previewSrcOverride || !previewFileHandleId || !requestId\n ? undefined\n : SynapseClient.getPortalFileHandleServletUrl(\n previewFileHandleId,\n requestId,\n FileHandleAssociateType.DataAccessRequestAttachment,\n ),\n )\n\n const {\n mutateAsync: checkSignatureUpdatable,\n isPending: isCheckingSignatureUpdatable,\n error: precheckError,\n reset: resetPrecheck,\n } = useCheckDataAccessRequestSignatureUpdatable()\n\n const {\n mutate: updateSignature,\n isPending: isUpdatingSignature,\n error: updateSignatureError,\n reset: resetUpdateSignature,\n } = useUpdateDataAccessRequestSignature({\n onSuccess: () => onSendForSignature(),\n })\n\n const {\n mutateAsync: voidSignature,\n isPending: isVoidingSignature,\n error: voidSignatureError,\n reset: resetVoidSignature,\n } = useVoidDataAccessRequestSignature()\n\n const {\n mutate: initiateSignature,\n isPending: isInitiatingSignature,\n error: initiateSignatureError,\n reset: resetInitiateSignature,\n } = useInitiateDataAccessRequestSignature({\n onSuccess: () => onSendForSignature(),\n })\n\n // Preflight the quota so we can disable the send-for-signature action when the user is at\n // or over their limit. A fetch error falls back to the current enabled behavior so a quota\n // service outage doesn't spuriously block valid requests.\n const { data: signatureQuota, isLoading: isLoadingQuota } =\n useGetDataAccessRequestSignatureQuota(requestId ?? '', {\n enabled: Boolean(requestId),\n })\n const isAtOrOverQuota =\n signatureQuota?.remaining != null && signatureQuota.remaining <= 0\n // Only routing a new envelope spends a quota unit. With no envelope in flight, routing a new one\n // is the only thing Send can do, so an exhausted quota blocks the button outright. With one in\n // flight, Send may instead correct that envelope for free -- and only the server's precheck knows\n // which -- so the button stays enabled and the confirmation it opens gates the paid path.\n const isSendBlockedByQuota = isAtOrOverQuota && !hasSignatureEnvelope\n\n // Which send-confirmation the precheck selected, or `null` for none. Once an envelope exists,\n // Send always stops for an explicit decision from the user: either they choose between keeping\n // and replacing it, or they acknowledge that replacing it is the only option left.\n const [openConfirmation, setOpenConfirmation] = useState<\n 'keepOrReplace' | 'restartSigning' | null\n >(null)\n // Set when the server rejects an update that the client expected to succeed, leaving a recreate\n // -- which the user has no quota for -- as the only way forward.\n const [isRecreateBlockedByQuota, setIsRecreateBlockedByQuota] =\n useState(false)\n\n // The precheck and the mutation it selects are presented as a single action, so the button\n // stays in its sending state for the whole sequence rather than flickering between calls.\n const isSendingForSignature =\n isCheckingSignatureUpdatable ||\n isUpdatingSignature ||\n isVoidingSignature ||\n isInitiatingSignature\n\n const isLoading =\n isLoadingDar ||\n (Boolean(requestId) && isLoadingPreview) ||\n (!previewSrcOverride && !!previewFileHandleId && !blobUrl && !blobError)\n const actionsDisabled =\n isLoading || (!previewSrcOverride && !blobUrl) || isSendingForSignature\n // The quota governs what Send is allowed to do, so keep it disabled until that answer lands\n // rather than letting the user start a send we may be about to block. Deliberately not folded\n // into `isLoading`: the preview skeleton shouldn't wait on the quota, and the manual\n // print-and-upload path spends no quota and stays available throughout.\n const isSendDisabled =\n actionsDisabled || isLoadingQuota || isSendBlockedByQuota\n\n const sendError =\n (precheckError && {\n title: PRECHECK_ERROR_TITLE,\n reason: precheckError.reason,\n }) ||\n (updateSignatureError && {\n title: UPDATE_SIGNATURE_ERROR_TITLE,\n reason: updateSignatureError.reason,\n }) ||\n (voidSignatureError && {\n title: VOID_SIGNATURE_ERROR_TITLE,\n reason: voidSignatureError.reason,\n }) ||\n (initiateSignatureError && {\n title: INITIATE_SIGNATURE_ERROR_TITLE,\n reason: initiateSignatureError.reason,\n }) ||\n (isRecreateBlockedByQuota && {\n title: SIGNATURE_QUOTA_EXHAUSTED_TITLE,\n reason: <SignatureQuotaExhaustedMessage quota={signatureQuota?.quota} />,\n })\n\n const resetSendErrors = () => {\n resetPrecheck()\n resetUpdateSignature()\n resetVoidSignature()\n resetInitiateSignature()\n setIsRecreateBlockedByQuota(false)\n }\n\n const handleSendForSignature = async () => {\n if (!requestId) return\n resetSendErrors()\n setHasStartedSendSequence(true)\n\n if (!hasSignatureEnvelope) {\n initiateSignature(requestId)\n return\n }\n\n // `null` means the precheck itself failed; its error is surfaced by the alert below.\n const canUpdateEnvelope = await checkSignatureUpdatable(requestId).catch(\n () => null,\n )\n if (canUpdateEnvelope === null) {\n return\n }\n if (canUpdateEnvelope) {\n // Only the user knows whether their edits are material enough to warrant re-signing, so\n // the choice between correcting and replacing the envelope is theirs.\n setOpenConfirmation('keepOrReplace')\n } else if (isAtOrOverQuota) {\n // Replacing spends a routing the user doesn't have, so there is nothing to confirm.\n setIsRecreateBlockedByQuota(true)\n } else {\n setOpenConfirmation('restartSigning')\n }\n }\n\n const handleKeepExistingDuc = () => {\n if (!requestId) return\n setOpenConfirmation(null)\n updateSignature(requestId)\n }\n\n const handleSendNewDuc = async () => {\n if (!requestId) return\n setOpenConfirmation(null)\n const isVoided = await voidSignature(requestId).then(\n () => true,\n () => false,\n )\n if (!isVoided) {\n return\n }\n initiateSignature(requestId)\n }\n\n // Dismissing leaves the request untouched, so the user is still free to fall back to the\n // manual print-and-upload path.\n const handleCancelConfirmation = () => {\n setOpenConfirmation(null)\n }\n\n return (\n <>\n <DialogBaseTitle title={'Request Access'} onCancel={onHide} />\n <DialogContent>\n <Typography variant={'body1'} sx={{ fontWeight: 700, mb: 1 }}>\n Take a minute to preview your DUC\n </Typography>\n <Typography variant={'body1'} sx={{ ...longFieldLabelSx, mb: 2 }}>\n Please ensure that all information is correct, as incorrect\n information will result in the rejection of your access request. Use\n the Back button to return to previous steps and modify any details.\n </Typography>\n\n {isLoading && (\n <Skeleton\n variant={'rectangular'}\n width={'100%'}\n height={PDF_PREVIEW_HEIGHT}\n data-testid={'EDucPreviewStep-loading'}\n />\n )}\n {!isLoading && (previewError || blobError) && (\n <Alert severity={'error'}>\n <strong>Sorry, we couldn't load your DUC preview.</strong>\n <br />\n {previewError?.reason ?? blobError?.message}\n </Alert>\n )}\n {!isLoading &&\n !previewError &&\n !blobError &&\n (previewSrcOverride || blobUrl) && (\n <iframe\n title={'eDUC preview'}\n src={previewSrcOverride ?? blobUrl}\n style={{ border: 0, width: '100%', height: PDF_PREVIEW_HEIGHT }}\n />\n )}\n\n <Box\n sx={{\n mt: 3,\n border: '1px solid',\n borderColor: 'grey.300',\n borderRadius: 1,\n }}\n >\n <ActionRow\n title={'Email DUC to Collaborators'}\n description={\n 'Complete and sign the DUC online by emailing a secure DocuSign link to your listed collaborators. Notifications will be sent directly to the email address associated with their Synapse accounts. This is fastest way to get access.'\n }\n action={\n <Tooltip\n title={\n isSendBlockedByQuota ? (\n <SignatureQuotaExhaustedMessage\n quota={signatureQuota?.quota}\n />\n ) : (\n ''\n )\n }\n arrow\n disableHoverListener={!isSendBlockedByQuota}\n disableFocusListener={!isSendBlockedByQuota}\n disableTouchListener={!isSendBlockedByQuota}\n >\n {/* Tooltip wrapper Box is needed because MUI Tooltip does not fire on disabled children directly. */}\n <Box component={'span'}>\n <Button\n variant={'contained'}\n disabled={isSendDisabled}\n onClick={() => {\n handleSendForSignature()\n }}\n >\n {isSendingForSignature\n ? 'Sending...'\n : SEND_FOR_SIGNATURE_BUTTON_TEXT}\n </Button>\n </Box>\n </Tooltip>\n }\n />\n <Divider />\n <ActionRow\n title={'Print and upload a PDF instead'}\n description={\n 'Download the DUC, sign it by hand, and upload the completed document.'\n }\n action={\n <Button\n variant={'outlined'}\n disabled={actionsDisabled}\n onClick={onManualUpload}\n >\n Manually print and upload PDF\n </Button>\n }\n />\n </Box>\n {sendError && (\n <Alert severity={'error'} sx={{ mt: 2 }}>\n <strong>{sendError.title}</strong>\n <br />\n {sendError.reason}\n </Alert>\n )}\n </DialogContent>\n <DialogActions>\n <Button variant={'outlined'} onClick={onBackClicked}>\n Back\n </Button>\n </DialogActions>\n <DialogBase\n open={openConfirmation === 'keepOrReplace'}\n title={KEEP_OR_REPLACE_DIALOG_TITLE}\n content={\n <>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n Your DUC was already signed and submitted. If your changes\n don't affect what's on it, you can keep it and resubmit.\n If they do, you'll need a new DUC, and your PI or Project\n Lead, Signing Official, and any named Collaborators will need to\n sign again.\n </Typography>\n <RemainingEDucAllowance remaining={signatureQuota?.remaining} />\n </>\n }\n onCancel={handleCancelConfirmation}\n actions={\n <>\n <Button variant={'outlined'} onClick={handleCancelConfirmation}>\n {CANCEL_BUTTON_TEXT}\n </Button>\n <SendNewDucButton\n quota={signatureQuota?.quota}\n isAtOrOverQuota={isAtOrOverQuota}\n variant={'outlined'}\n onClick={() => {\n handleSendNewDuc()\n }}\n >\n {SEND_NEW_DUC_BUTTON_TEXT}\n </SendNewDucButton>\n <Button variant={'contained'} onClick={handleKeepExistingDuc}>\n {KEEP_EXISTING_DUC_BUTTON_TEXT}\n </Button>\n </>\n }\n />\n <ConfirmationDialog\n open={openConfirmation === 'restartSigning'}\n title={RESTART_SIGNING_DIALOG_TITLE}\n content={\n <>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n Your DUC was already submitted for review, so it can't be\n edited. To submit your changes, we'll close the current DUC\n and send a new one for signature. Your PI or Project Lead, Signing\n Official, and any named Collaborators will need to sign again.\n </Typography>\n <RemainingEDucAllowance remaining={signatureQuota?.remaining} />\n </>\n }\n confirmButtonProps={{ children: RESTART_SIGNING_CONFIRM_BUTTON_TEXT }}\n onConfirm={() => {\n handleSendNewDuc()\n }}\n onCancel={handleCancelConfirmation}\n />\n </>\n )\n}\n\n/**\n * The month's remaining electronic DUC allowance. Omitted rather than guessed at when the quota\n * request has not resolved.\n */\nfunction RemainingEDucAllowance(props: { remaining: number | undefined }) {\n const { remaining } = props\n if (remaining == null) {\n return null\n }\n return (\n <Typography variant={'body1'} sx={{ ...longFieldLabelSx, mt: 2 }}>\n You can create <strong>{remaining}</strong> more electronic{' '}\n {remaining === 1 ? 'DUC' : 'DUCs'} this month.\n </Typography>\n )\n}\n\n/**\n * The \"send a new DUC\" action, disabled with an explanation when the user has no routings left.\n * Replacing an envelope always spends one, so this is the only action in the keep-or-replace\n * dialog that the quota can block.\n */\nfunction SendNewDucButton(\n props: ButtonProps & { quota: number | undefined; isAtOrOverQuota: boolean },\n) {\n const { quota, isAtOrOverQuota, ...buttonProps } = props\n return (\n <Tooltip\n title={\n isAtOrOverQuota ? <SignatureQuotaExhaustedMessage quota={quota} /> : ''\n }\n arrow\n disableHoverListener={!isAtOrOverQuota}\n disableFocusListener={!isAtOrOverQuota}\n disableTouchListener={!isAtOrOverQuota}\n >\n {/* Tooltip wrapper Box is needed because MUI Tooltip does not fire on disabled children directly. */}\n <Box component={'span'}>\n <Button {...buttonProps} disabled={isAtOrOverQuota} />\n </Box>\n </Tooltip>\n )\n}\n\nfunction ActionRow(props: {\n title: string\n description: string\n action: ReactNode\n}) {\n const { title, description, action } = props\n return (\n <Stack\n direction={{ xs: 'column', sm: 'row' }}\n sx={{ alignItems: { sm: 'center' }, gap: 2, p: 2 }}\n >\n <Box sx={{ flexGrow: 1 }}>\n <Typography variant={'body1'} sx={{ fontWeight: 700, mb: 0.5 }}>\n {title}\n </Typography>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n {description}\n </Typography>\n </Box>\n <Box sx={{ flexShrink: 0 }}>{action}</Box>\n </Stack>\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;AAqCA,IAAM,IAAqB,SAEd,IAAiC,iCAEjC,IACX,6CACW,IAAgC,qBAChC,IAA2B,gBAE3B,IAA+B,wBAC/B,IAAsC,8BAE7C,KACJ,2EACI,KACJ,6EACI,KACJ,8DACI,KACJ;AAqBF,SAAwB,EAAgB,GAA6B;CACnE,IAAM,EACJ,gCACA,YACA,mBACA,uBACA,oBACA,0BACE,GAEE,EAAE,MAAM,GAAmB,WAAW,OAC1C,EAAiC,OAAO,EAA4B,EAAE,GAAG;EACvE,WAAW;EACX,cAAc;CAChB,CAAC,GAEG,IAAY,GAAmB,IAC/B,IAAuB,EAC3B,GAAmB,yBAef,CAAC,GAAwB,KAA6B,EAAS,EAAK,GAEpE,EACJ,MAAM,IACN,WAAW,IACX,OAAO,MACL,EAA+B,KAAa,IAAI,EAClD,SAAS,EAAQ,KAAc,CAAC,EAClC,CAAC,GAEK,IAAsB,IAAmB,cACzC,EAAE,YAAS,OAAO,MAAc,GACpC,KAAsB,CAAC,KAAuB,CAAC,IAC3C,KAAA,IACA,EAAc,8BACZ,GACA,GACA,GAAwB,2BAC1B,CACN,GAEM,EACJ,aAAa,IACb,WAAW,IACX,OAAO,GACP,OAAO,OACL,EAA4C,GAE1C,EACJ,QAAQ,IACR,WAAW,IACX,OAAO,GACP,OAAO,OACL,GAAoC,EACtC,iBAAiB,EAAmB,EACtC,CAAC,GAEK,EACJ,aAAa,IACb,WAAW,IACX,OAAO,GACP,O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AAA,CACT;MACL,kBAAC,GAAD;GAAK,IAAI,EAAE,YAAY,EAAE;aAAI;EAAY,CAAA,CACpC;;AAEX"}
|
|
1
|
+
{"version":3,"file":"EDucPreviewStep.js","names":[],"sources":["../../../../../src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/EDucPreviewStep/EDucPreviewStep.tsx"],"sourcesContent":["import { ConfirmationDialog } from '@/components/ConfirmationDialog'\nimport { CANCEL_BUTTON_TEXT } from '@/components/ConfirmationDialog/ConfirmationDialog'\nimport { DialogBase } from '@/components/DialogBase'\nimport {\n useCheckDataAccessRequestSignatureUpdatable,\n useGetDataAccessRequestForUpdate,\n useGetDataAccessRequestPreview,\n useGetDataAccessRequestSignatureQuota,\n useInitiateDataAccessRequestSignature,\n useUpdateDataAccessRequestSignature,\n useVoidDataAccessRequestSignature,\n} from '@/synapse-queries'\nimport SynapseClient from '@/synapse-client'\nimport {\n Alert,\n Box,\n Button,\n ButtonProps,\n DialogActions,\n DialogContent,\n Divider,\n Skeleton,\n Stack,\n Tooltip,\n Typography,\n} from '@mui/material'\nimport { FileHandleAssociateType } from '@sage-bionetworks/synapse-types'\nimport { ReactNode, useState } from 'react'\nimport { useFetchBlobUrl } from '@/utils/hooks/useFetchBlobUrl'\nimport { DialogBaseTitle } from '../../../DialogBase'\nimport {\n SIGNATURE_QUOTA_EXHAUSTED_TITLE,\n SignatureQuotaExhaustedMessage,\n} from '../eDucSignatureUtils'\nimport { longFieldLabelSx } from '../styles'\nimport { RequestFlowAccessRequirement } from '../requestFlowTypes'\n\nconst PDF_PREVIEW_HEIGHT = '500px'\n\nexport const SEND_FOR_SIGNATURE_BUTTON_TEXT = 'Send for electronic signature'\n\nexport const KEEP_OR_REPLACE_DIALOG_TITLE =\n 'Keep your existing DUC or send a new one?'\nexport const KEEP_EXISTING_DUC_BUTTON_TEXT = 'Keep Existing DUC'\nexport const SEND_NEW_DUC_BUTTON_TEXT = 'Send new DUC'\n\nexport const RESTART_SIGNING_DIALOG_TITLE = 'Restart DUC signing?'\nexport const RESTART_SIGNING_CONFIRM_BUTTON_TEXT = 'I understand, send new DUC'\n\nconst PRECHECK_ERROR_TITLE =\n \"Sorry, we couldn't check the status of your existing signature request.\"\nconst UPDATE_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't apply your changes to your existing signature request.\"\nconst VOID_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't cancel your existing signature request.\"\nconst INITIATE_SIGNATURE_ERROR_TITLE =\n \"Sorry, we couldn't send your DUC for electronic signature.\"\n\nexport type EDucPreviewStepProps = {\n managedACTAccessRequirement: RequestFlowAccessRequirement\n onHide: () => void\n onBackClicked: () => void\n onSendForSignature: () => void\n onManualUpload: () => void\n /**\n * Optional iframe `src` override for demos and stories. When set, the blob fetch is skipped\n * and this URL is used directly as the iframe src. Production callers should not set this.\n */\n previewSrcOverride?: string\n}\n\n/**\n * Wizard step shown after the \"Review / Create a DUC\" step (PORTALS-4414).\n * Displays the generated eDUC document in an iframe so the user can review it\n * before sending it for electronic signature (PORTALS-4378) or manually printing and\n * uploading a signed PDF (PORTALS-4379).\n */\nexport default function EDucPreviewStep(props: EDucPreviewStepProps) {\n const {\n managedACTAccessRequirement,\n onHide,\n onBackClicked,\n onSendForSignature,\n onManualUpload,\n previewSrcOverride,\n } = props\n\n const { data: dataAccessRequest, isLoading: isLoadingDar } =\n useGetDataAccessRequestForUpdate(String(managedACTAccessRequirement.id), {\n staleTime: Infinity,\n throwOnError: true,\n })\n\n const requestId = dataAccessRequest?.id\n const accessRequirementId = String(managedACTAccessRequirement.id)\n // Set only once a routing has actually been sent -- generating the preview leaves the request\n // untouched -- so this cleanly separates a first send from a re-send. The signature mutations\n // invalidate this query, so a send from an earlier pass through the wizard is reflected here.\n const hasSignatureEnvelope = Boolean(\n dataAccessRequest?.eDucSignatureEnvelopeId,\n )\n\n const {\n data: previewFileHandle,\n isLoading: isLoadingPreview,\n error: previewError,\n } = useGetDataAccessRequestPreview(requestId ?? '', {\n enabled: Boolean(requestId),\n })\n\n const previewFileHandleId = previewFileHandle?.fileHandleId\n const { blobUrl, error: blobError } = useFetchBlobUrl(\n previewSrcOverride || !previewFileHandleId || !requestId\n ? undefined\n : SynapseClient.getPortalFileHandleServletUrl(\n previewFileHandleId,\n requestId,\n FileHandleAssociateType.DataAccessRequestAttachment,\n ),\n )\n\n const {\n mutateAsync: checkSignatureUpdatable,\n isPending: isCheckingSignatureUpdatable,\n error: precheckError,\n reset: resetPrecheck,\n } = useCheckDataAccessRequestSignatureUpdatable()\n\n const {\n mutate: updateSignature,\n isPending: isUpdatingSignature,\n error: updateSignatureError,\n reset: resetUpdateSignature,\n } = useUpdateDataAccessRequestSignature({\n onSuccess: () => onSendForSignature(),\n })\n\n const {\n mutateAsync: voidSignature,\n isPending: isVoidingSignature,\n error: voidSignatureError,\n reset: resetVoidSignature,\n } = useVoidDataAccessRequestSignature()\n\n const {\n mutate: initiateSignature,\n isPending: isInitiatingSignature,\n error: initiateSignatureError,\n reset: resetInitiateSignature,\n } = useInitiateDataAccessRequestSignature({\n onSuccess: () => onSendForSignature(),\n })\n\n // Preflight the quota so we can disable the send-for-signature action when the user is at\n // or over their limit. A fetch error falls back to the current enabled behavior so a quota\n // service outage doesn't spuriously block valid requests.\n const { data: signatureQuota, isLoading: isLoadingQuota } =\n useGetDataAccessRequestSignatureQuota(requestId ?? '', {\n enabled: Boolean(requestId),\n })\n const isAtOrOverQuota =\n signatureQuota?.remaining != null && signatureQuota.remaining <= 0\n // Only routing a new envelope spends a quota unit. With no envelope in flight, routing a new one\n // is the only thing Send can do, so an exhausted quota blocks the button outright. With one in\n // flight, Send may instead correct that envelope for free -- and only the server's precheck knows\n // which -- so the button stays enabled and the confirmation it opens gates the paid path.\n const isSendBlockedByQuota = isAtOrOverQuota && !hasSignatureEnvelope\n\n // Which send-confirmation the precheck selected, or `null` for none. Once an envelope exists,\n // Send always stops for an explicit decision from the user: either they choose between keeping\n // and replacing it, or they acknowledge that replacing it is the only option left.\n const [openConfirmation, setOpenConfirmation] = useState<\n 'keepOrReplace' | 'restartSigning' | null\n >(null)\n // Set when the server rejects an update that the client expected to succeed, leaving a recreate\n // -- which the user has no quota for -- as the only way forward.\n const [isRecreateBlockedByQuota, setIsRecreateBlockedByQuota] =\n useState(false)\n\n // The precheck and the mutation it selects are presented as a single action, so the button\n // stays in its sending state for the whole sequence rather than flickering between calls.\n const isSendingForSignature =\n isCheckingSignatureUpdatable ||\n isUpdatingSignature ||\n isVoidingSignature ||\n isInitiatingSignature\n\n const isLoading =\n isLoadingDar ||\n (Boolean(requestId) && isLoadingPreview) ||\n (!previewSrcOverride && !!previewFileHandleId && !blobUrl && !blobError)\n const actionsDisabled =\n isLoading || (!previewSrcOverride && !blobUrl) || isSendingForSignature\n // The quota governs what Send is allowed to do, so keep it disabled until that answer lands\n // rather than letting the user start a send we may be about to block. Deliberately not folded\n // into `isLoading`: the preview skeleton shouldn't wait on the quota, and the manual\n // print-and-upload path spends no quota and stays available throughout.\n const isSendDisabled =\n actionsDisabled || isLoadingQuota || isSendBlockedByQuota\n\n const sendError =\n (precheckError && {\n title: PRECHECK_ERROR_TITLE,\n reason: precheckError.reason,\n }) ||\n (updateSignatureError && {\n title: UPDATE_SIGNATURE_ERROR_TITLE,\n reason: updateSignatureError.reason,\n }) ||\n (voidSignatureError && {\n title: VOID_SIGNATURE_ERROR_TITLE,\n reason: voidSignatureError.reason,\n }) ||\n (initiateSignatureError && {\n title: INITIATE_SIGNATURE_ERROR_TITLE,\n reason: initiateSignatureError.reason,\n }) ||\n (isRecreateBlockedByQuota && {\n title: SIGNATURE_QUOTA_EXHAUSTED_TITLE,\n reason: <SignatureQuotaExhaustedMessage quota={signatureQuota?.quota} />,\n })\n\n const resetSendErrors = () => {\n resetPrecheck()\n resetUpdateSignature()\n resetVoidSignature()\n resetInitiateSignature()\n setIsRecreateBlockedByQuota(false)\n }\n\n const handleSendForSignature = async () => {\n if (!requestId) return\n resetSendErrors()\n\n // Routing creates the envelope as well as sending it, so with nothing in flight there is no\n // existing envelope to reconcile against.\n if (!hasSignatureEnvelope) {\n initiateSignature({ requestId, accessRequirementId })\n return\n }\n\n // `null` means the precheck itself failed; its error is surfaced by the alert below.\n const canUpdateEnvelope = await checkSignatureUpdatable(requestId).catch(\n () => null,\n )\n if (canUpdateEnvelope === null) {\n return\n }\n if (canUpdateEnvelope) {\n // Only the user knows whether their edits are material enough to warrant re-signing, so\n // the choice between correcting and replacing the envelope is theirs.\n setOpenConfirmation('keepOrReplace')\n } else if (isAtOrOverQuota) {\n // Replacing spends a routing the user doesn't have, so there is nothing to confirm.\n setIsRecreateBlockedByQuota(true)\n } else {\n setOpenConfirmation('restartSigning')\n }\n }\n\n const handleKeepExistingDuc = () => {\n if (!requestId) return\n setOpenConfirmation(null)\n updateSignature({ requestId, accessRequirementId })\n }\n\n const handleSendNewDuc = async () => {\n if (!requestId) return\n setOpenConfirmation(null)\n const isVoided = await voidSignature({\n requestId,\n accessRequirementId,\n }).then(\n () => true,\n () => false,\n )\n if (!isVoided) {\n return\n }\n initiateSignature({ requestId, accessRequirementId })\n }\n\n // Dismissing leaves the request untouched, so the user is still free to fall back to the\n // manual print-and-upload path.\n const handleCancelConfirmation = () => {\n setOpenConfirmation(null)\n }\n\n return (\n <>\n <DialogBaseTitle title={'Request Access'} onCancel={onHide} />\n <DialogContent>\n <Typography variant={'body1'} sx={{ fontWeight: 700, mb: 1 }}>\n Take a minute to preview your DUC\n </Typography>\n <Typography variant={'body1'} sx={{ ...longFieldLabelSx, mb: 2 }}>\n Please ensure that all information is correct, as incorrect\n information will result in the rejection of your access request. Use\n the Back button to return to previous steps and modify any details.\n </Typography>\n\n {isLoading && (\n <Skeleton\n variant={'rectangular'}\n width={'100%'}\n height={PDF_PREVIEW_HEIGHT}\n data-testid={'EDucPreviewStep-loading'}\n />\n )}\n {!isLoading && (previewError || blobError) && (\n <Alert severity={'error'}>\n <strong>Sorry, we couldn't load your DUC preview.</strong>\n <br />\n {previewError?.reason ?? blobError?.message}\n </Alert>\n )}\n {!isLoading &&\n !previewError &&\n !blobError &&\n (previewSrcOverride || blobUrl) && (\n <iframe\n title={'eDUC preview'}\n src={previewSrcOverride ?? blobUrl}\n style={{ border: 0, width: '100%', height: PDF_PREVIEW_HEIGHT }}\n />\n )}\n\n <Box\n sx={{\n mt: 3,\n border: '1px solid',\n borderColor: 'grey.300',\n borderRadius: 1,\n }}\n >\n <ActionRow\n title={'Email DUC to Collaborators'}\n description={\n 'Complete and sign the DUC online by emailing a secure DocuSign link to your listed collaborators. Notifications will be sent directly to the email address associated with their Synapse accounts. This is fastest way to get access.'\n }\n action={\n <Tooltip\n title={\n isSendBlockedByQuota ? (\n <SignatureQuotaExhaustedMessage\n quota={signatureQuota?.quota}\n />\n ) : (\n ''\n )\n }\n arrow\n disableHoverListener={!isSendBlockedByQuota}\n disableFocusListener={!isSendBlockedByQuota}\n disableTouchListener={!isSendBlockedByQuota}\n >\n {/* Tooltip wrapper Box is needed because MUI Tooltip does not fire on disabled children directly. */}\n <Box component={'span'}>\n <Button\n variant={'contained'}\n disabled={isSendDisabled}\n onClick={() => {\n handleSendForSignature()\n }}\n >\n {isSendingForSignature\n ? 'Sending...'\n : SEND_FOR_SIGNATURE_BUTTON_TEXT}\n </Button>\n </Box>\n </Tooltip>\n }\n />\n <Divider />\n <ActionRow\n title={'Print and upload a PDF instead'}\n description={\n 'Download the DUC, sign it by hand, and upload the completed document.'\n }\n action={\n <Button\n variant={'outlined'}\n disabled={actionsDisabled}\n onClick={onManualUpload}\n >\n Manually print and upload PDF\n </Button>\n }\n />\n </Box>\n {sendError && (\n <Alert severity={'error'} sx={{ mt: 2 }}>\n <strong>{sendError.title}</strong>\n <br />\n {sendError.reason}\n </Alert>\n )}\n </DialogContent>\n <DialogActions>\n <Button variant={'outlined'} onClick={onBackClicked}>\n Back\n </Button>\n </DialogActions>\n <DialogBase\n open={openConfirmation === 'keepOrReplace'}\n title={KEEP_OR_REPLACE_DIALOG_TITLE}\n content={\n <>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n Your DUC was already signed and submitted. If your changes\n don't affect what's on it, you can keep it and resubmit.\n If they do, you'll need a new DUC, and your PI or Project\n Lead, Signing Official, and any named Collaborators will need to\n sign again.\n </Typography>\n <RemainingEDucAllowance remaining={signatureQuota?.remaining} />\n </>\n }\n onCancel={handleCancelConfirmation}\n actions={\n <>\n <Button variant={'outlined'} onClick={handleCancelConfirmation}>\n {CANCEL_BUTTON_TEXT}\n </Button>\n <SendNewDucButton\n quota={signatureQuota?.quota}\n isAtOrOverQuota={isAtOrOverQuota}\n variant={'outlined'}\n onClick={() => {\n handleSendNewDuc()\n }}\n >\n {SEND_NEW_DUC_BUTTON_TEXT}\n </SendNewDucButton>\n <Button variant={'contained'} onClick={handleKeepExistingDuc}>\n {KEEP_EXISTING_DUC_BUTTON_TEXT}\n </Button>\n </>\n }\n />\n <ConfirmationDialog\n open={openConfirmation === 'restartSigning'}\n title={RESTART_SIGNING_DIALOG_TITLE}\n content={\n <>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n Your DUC was already submitted for review, so it can't be\n edited. To submit your changes, we'll close the current DUC\n and send a new one for signature. Your PI or Project Lead, Signing\n Official, and any named Collaborators will need to sign again.\n </Typography>\n <RemainingEDucAllowance remaining={signatureQuota?.remaining} />\n </>\n }\n confirmButtonProps={{ children: RESTART_SIGNING_CONFIRM_BUTTON_TEXT }}\n onConfirm={() => {\n handleSendNewDuc()\n }}\n onCancel={handleCancelConfirmation}\n />\n </>\n )\n}\n\n/**\n * The month's remaining electronic DUC allowance. Omitted rather than guessed at when the quota\n * request has not resolved.\n */\nfunction RemainingEDucAllowance(props: { remaining: number | undefined }) {\n const { remaining } = props\n if (remaining == null) {\n return null\n }\n return (\n <Typography variant={'body1'} sx={{ ...longFieldLabelSx, mt: 2 }}>\n You can create <strong>{remaining}</strong> more electronic{' '}\n {remaining === 1 ? 'DUC' : 'DUCs'} this month.\n </Typography>\n )\n}\n\n/**\n * The \"send a new DUC\" action, disabled with an explanation when the user has no routings left.\n * Replacing an envelope always spends one, so this is the only action in the keep-or-replace\n * dialog that the quota can block.\n */\nfunction SendNewDucButton(\n props: ButtonProps & { quota: number | undefined; isAtOrOverQuota: boolean },\n) {\n const { quota, isAtOrOverQuota, ...buttonProps } = props\n return (\n <Tooltip\n title={\n isAtOrOverQuota ? <SignatureQuotaExhaustedMessage quota={quota} /> : ''\n }\n arrow\n disableHoverListener={!isAtOrOverQuota}\n disableFocusListener={!isAtOrOverQuota}\n disableTouchListener={!isAtOrOverQuota}\n >\n {/* Tooltip wrapper Box is needed because MUI Tooltip does not fire on disabled children directly. */}\n <Box component={'span'}>\n <Button {...buttonProps} disabled={isAtOrOverQuota} />\n </Box>\n </Tooltip>\n )\n}\n\nfunction ActionRow(props: {\n title: string\n description: string\n action: ReactNode\n}) {\n const { title, description, action } = props\n return (\n <Stack\n direction={{ xs: 'column', sm: 'row' }}\n sx={{ alignItems: { sm: 'center' }, gap: 2, p: 2 }}\n >\n <Box sx={{ flexGrow: 1 }}>\n <Typography variant={'body1'} sx={{ fontWeight: 700, mb: 0.5 }}>\n {title}\n </Typography>\n <Typography variant={'body1'} sx={longFieldLabelSx}>\n {description}\n </Typography>\n </Box>\n <Box sx={{ flexShrink: 0 }}>{action}</Box>\n </Stack>\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;AAqCA,IAAM,IAAqB,SAEd,IAAiC,iCAEjC,IACX,6CACW,IAAgC,qBAChC,IAA2B,gBAE3B,IAA+B,wBAC/B,IAAsC,8BAE7C,KACJ,2EACI,KACJ,6EACI,KACJ,8DACI,KACJ;AAqBF,SAAwB,EAAgB,GAA6B;CACnE,IAAM,EACJ,gCACA,YACA,mBACA,uBACA,oBACA,0BACE,GAEE,EAAE,MAAM,GAAmB,WAAW,MAC1C,EAAiC,OAAO,EAA4B,EAAE,GAAG;EACvE,WAAW;EACX,cAAc;CAChB,CAAC,GAEG,IAAY,GAAmB,IAC/B,IAAsB,OAAO,EAA4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,CAAC;YAGvB,kBAAC,GAAD;GAAK,WAAW;aACd,kBAAC,GAAD;IAAQ,GAAI;IAAa,UAAU;GAAkB,CAAA;EAClD,CAAA;CACE,CAAA;AAEb;AAEA,SAAS,EAAU,GAIhB;CACD,IAAM,EAAE,UAAO,gBAAa,cAAW;CACvC,OACE,kBAAC,GAAD;EACE,WAAW;GAAE,IAAI;GAAU,IAAI;EAAM;EACrC,IAAI;GAAE,YAAY,EAAE,IAAI,SAAS;GAAG,KAAK;GAAG,GAAG;EAAE;YAFnD,CAIE,kBAAC,GAAD;GAAK,IAAI,EAAE,UAAU,EAAE;aAAvB,CACE,kBAAC,GAAD;IAAY,SAAS;IAAS,IAAI;KAAE,YAAY;KAAK,IAAI;IAAI;cAC1D;GACS,CAAA,GACZ,kBAAC,GAAD;IAAY,SAAS;IAAS,IAAI;cAC/B;GACS,CAAA,CACT;MACL,kBAAC,GAAD;GAAK,IAAI,EAAE,YAAY,EAAE;aAAI;EAAY,CAAA,CACpC;;AAEX"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ManualUploadDucStep.d.ts","sourceRoot":"","sources":["../../../../../src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAGL,sBAAsB,EAEvB,MAAM,iCAAiC,CAAA;AAOxC,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAA;AAElE,MAAM,MAAM,wBAAwB,GAAG;IACrC,2BAA2B,EAAE,4BAA4B,CAAA;IACzD,SAAS,EAAE,MAAM,CAAA;IACjB,WAAW,EAAE,sBAAsB,CAAA;IACnC,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,aAAa,EAAE,MAAM,IAAI,CAAA;IACzB,mBAAmB,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAA;IACnD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAA;CAC9B,CAAA;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,KAAK,EAAE,wBAAwB,
|
|
1
|
+
{"version":3,"file":"ManualUploadDucStep.d.ts","sourceRoot":"","sources":["../../../../../src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAGL,sBAAsB,EAEvB,MAAM,iCAAiC,CAAA;AAOxC,OAAO,EAAE,4BAA4B,EAAE,MAAM,qBAAqB,CAAA;AAElE,MAAM,MAAM,wBAAwB,GAAG;IACrC,2BAA2B,EAAE,4BAA4B,CAAA;IACzD,SAAS,EAAE,MAAM,CAAA;IACjB,WAAW,EAAE,sBAAsB,CAAA;IACnC,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,aAAa,EAAE,MAAM,IAAI,CAAA;IACzB,mBAAmB,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,IAAI,CAAA;IACnD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAA;CAC9B,CAAA;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,KAAK,EAAE,wBAAwB,2CA4R1E"}
|
|
@@ -1,106 +1,108 @@
|
|
|
1
1
|
import e from "../../../../synapse-client/index.js";
|
|
2
2
|
import { useSubmitDataAccessRequest as t } from "../../../../synapse-queries/dataaccess/useDataAccessSubmission.js";
|
|
3
3
|
import { useGetDataAccessRequestForUpdate as n, useUpdateDataAccessRequest as r } from "../../../../synapse-queries/dataaccess/useAccessRequirements.js";
|
|
4
|
-
import { useGetDataAccessRequestPreview as
|
|
4
|
+
import { useGetDataAccessRequestPreview as i, useVoidDataAccessRequestSignature as a } from "../../../../synapse-queries/dataaccess/useEDuc.js";
|
|
5
5
|
import "../../../../synapse-queries/index.js";
|
|
6
|
-
import { DialogBaseTitle as
|
|
7
|
-
import
|
|
8
|
-
import { longFieldLabelSx as
|
|
9
|
-
import { UploadDocumentField as
|
|
10
|
-
import { ReviewCollaboratorsAndSigningOfficialAccordion as
|
|
11
|
-
import { useState as
|
|
12
|
-
import { Alert as
|
|
13
|
-
import { Fragment as
|
|
14
|
-
import { FileHandleAssociateType as
|
|
6
|
+
import { DialogBaseTitle as o } from "../../../DialogBase.js";
|
|
7
|
+
import s from "../../../IconSvg/IconSvg.js";
|
|
8
|
+
import { longFieldLabelSx as c } from "../styles.js";
|
|
9
|
+
import { UploadDocumentField as l } from "../UploadDocumentField.js";
|
|
10
|
+
import { ReviewCollaboratorsAndSigningOfficialAccordion as u } from "../ReviewCollaboratorsAndSigningOfficialAccordion.js";
|
|
11
|
+
import { useState as d } from "react";
|
|
12
|
+
import { Alert as f, Box as p, Button as m, DialogActions as h, DialogContent as g, Skeleton as _, Stack as v, Typography as y } from "@mui/material";
|
|
13
|
+
import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
14
|
+
import { FileHandleAssociateType as C } from "@sage-bionetworks/synapse-types";
|
|
15
15
|
//#region src/components/AccessRequirementList/ManagedACTAccessRequirementRequestFlow/ManualUploadDucStep/ManualUploadDucStep.tsx
|
|
16
|
-
function
|
|
17
|
-
let { managedACTAccessRequirement:
|
|
16
|
+
function w(w) {
|
|
17
|
+
let { managedACTAccessRequirement: T, subjectId: E, subjectType: D, onHide: ee, onBackClicked: O, onSubmissionCreated: k, downloadHrefOverride: A } = w, { data: j, isLoading: M, refetch: N } = n(String(T.id), {
|
|
18
18
|
staleTime: Infinity,
|
|
19
19
|
throwOnError: !0
|
|
20
|
-
}),
|
|
21
|
-
onSuccess: (e) =>
|
|
22
|
-
onError: (e) =>
|
|
23
|
-
}),
|
|
20
|
+
}), { data: P, isLoading: F, error: I } = i(j?.id ?? "", { enabled: !!j?.id && !A }), L = P?.fileHandleId, R = A ?? (L && j?.id ? e.getPortalFileHandleServletUrl(L, j.id, C.DataAccessRequestAttachment) : void 0), [z, B] = d(), [V, H] = d(), { mutate: U, mutateAsync: W, isPending: G } = r({ onError: (e) => B(e.reason) }), { mutateAsync: K, isPending: q } = a({ onError: (e) => B(e.reason) }), { mutate: J, isPending: Y } = t({
|
|
21
|
+
onSuccess: (e) => k(e.submissionId),
|
|
22
|
+
onError: (e) => H(e.reason)
|
|
23
|
+
}), X = j?.accessorChanges ?? [], Z = j?.principalInvestigator, Q = j?.signingOfficial, $ = j?.ducFileHandleId, te = $ && j?.id ? [{
|
|
24
24
|
fileHandleId: $,
|
|
25
|
-
associateObjectType:
|
|
26
|
-
associateObjectId:
|
|
27
|
-
}] : [],
|
|
28
|
-
if (!e.success || !e.resp || !
|
|
25
|
+
associateObjectType: C.DataAccessRequestAttachment,
|
|
26
|
+
associateObjectId: j.id
|
|
27
|
+
}] : [], ne = M || F || !R, re = M || !j || !$ || G || q || Y, ie = async (e) => {
|
|
28
|
+
if (!e.success || !e.resp || !j) {
|
|
29
29
|
let t = e.error, n = t && typeof t.reason == "string" ? t.reason : void 0;
|
|
30
|
-
n &&
|
|
30
|
+
n && B(n);
|
|
31
31
|
return;
|
|
32
32
|
}
|
|
33
|
-
|
|
34
|
-
let t = !!
|
|
33
|
+
B(void 0);
|
|
34
|
+
let t = !!j.eDucSignatureEnvelopeId, n = j;
|
|
35
35
|
if (t) {
|
|
36
|
-
P(!0);
|
|
37
36
|
try {
|
|
38
|
-
await
|
|
37
|
+
await K({
|
|
38
|
+
requestId: j.id,
|
|
39
|
+
accessRequirementId: String(T.id)
|
|
40
|
+
});
|
|
39
41
|
} catch {
|
|
40
42
|
return;
|
|
41
43
|
}
|
|
42
|
-
n = (await
|
|
44
|
+
n = (await N()).data ?? j;
|
|
43
45
|
}
|
|
44
|
-
|
|
46
|
+
U({
|
|
45
47
|
...n,
|
|
46
48
|
ducFileHandleId: e.resp.fileHandleId
|
|
47
49
|
});
|
|
48
|
-
},
|
|
49
|
-
if (!
|
|
50
|
-
|
|
51
|
-
let e = await
|
|
52
|
-
e &&
|
|
50
|
+
}, ae = async () => {
|
|
51
|
+
if (!j) return;
|
|
52
|
+
H(void 0);
|
|
53
|
+
let e = await W(j).catch(() => null);
|
|
54
|
+
e && J({
|
|
53
55
|
request: {
|
|
54
56
|
requestId: e.id,
|
|
55
57
|
requestEtag: e.etag,
|
|
56
|
-
subjectId:
|
|
57
|
-
subjectType:
|
|
58
|
+
subjectId: E,
|
|
59
|
+
subjectType: D
|
|
58
60
|
},
|
|
59
|
-
accessRequirementId: String(
|
|
61
|
+
accessRequirementId: String(T.id)
|
|
60
62
|
});
|
|
61
63
|
};
|
|
62
|
-
return /* @__PURE__ */
|
|
63
|
-
/* @__PURE__ */
|
|
64
|
+
return /* @__PURE__ */ S(b, { children: [
|
|
65
|
+
/* @__PURE__ */ x(o, {
|
|
64
66
|
title: "Request Access",
|
|
65
|
-
onCancel:
|
|
67
|
+
onCancel: ee
|
|
66
68
|
}),
|
|
67
|
-
/* @__PURE__ */
|
|
68
|
-
/* @__PURE__ */
|
|
69
|
+
/* @__PURE__ */ x(g, { children: /* @__PURE__ */ S(p, { children: [
|
|
70
|
+
/* @__PURE__ */ x(y, {
|
|
69
71
|
variant: "headline3",
|
|
70
72
|
sx: { mb: 2 },
|
|
71
73
|
children: "Submit a signed PDF instead of e-signatures"
|
|
72
74
|
}),
|
|
73
|
-
/* @__PURE__ */
|
|
75
|
+
/* @__PURE__ */ x(y, {
|
|
74
76
|
variant: "body1",
|
|
75
77
|
sx: {
|
|
76
|
-
...
|
|
78
|
+
...c,
|
|
77
79
|
mb: 2
|
|
78
80
|
},
|
|
79
81
|
children: "Instead of signing the Data Use Certificate (DUC) using DocuSign, you can download the DUC as a PDF and then upload it after it has been signed by your collaborators, your project lead, and your Signing Official."
|
|
80
82
|
}),
|
|
81
|
-
/* @__PURE__ */
|
|
83
|
+
/* @__PURE__ */ x(y, {
|
|
82
84
|
variant: "body1",
|
|
83
85
|
sx: {
|
|
84
|
-
...
|
|
86
|
+
...c,
|
|
85
87
|
mb: 3
|
|
86
88
|
},
|
|
87
89
|
children: "However, we recommend using e-signatures, as it is usually faster, and prevents common errors which can result in your request being rejected."
|
|
88
90
|
}),
|
|
89
|
-
/* @__PURE__ */
|
|
91
|
+
/* @__PURE__ */ x(p, {
|
|
90
92
|
sx: { mb: 3 },
|
|
91
|
-
children: /* @__PURE__ */
|
|
92
|
-
accessorChanges:
|
|
93
|
-
principalInvestigator:
|
|
94
|
-
signingOfficial:
|
|
95
|
-
isLoading:
|
|
93
|
+
children: /* @__PURE__ */ x(u, {
|
|
94
|
+
accessorChanges: X,
|
|
95
|
+
principalInvestigator: Z,
|
|
96
|
+
signingOfficial: Q,
|
|
97
|
+
isLoading: M
|
|
96
98
|
})
|
|
97
99
|
}),
|
|
98
|
-
/* @__PURE__ */
|
|
100
|
+
/* @__PURE__ */ x(y, {
|
|
99
101
|
variant: "headline3",
|
|
100
102
|
sx: { mb: 2 },
|
|
101
103
|
children: "Instructions"
|
|
102
104
|
}),
|
|
103
|
-
/* @__PURE__ */
|
|
105
|
+
/* @__PURE__ */ S(v, {
|
|
104
106
|
direction: {
|
|
105
107
|
xs: "column",
|
|
106
108
|
md: "row"
|
|
@@ -109,10 +111,10 @@ function C(C) {
|
|
|
109
111
|
gap: 4,
|
|
110
112
|
alignItems: "flex-start"
|
|
111
113
|
},
|
|
112
|
-
children: [/* @__PURE__ */
|
|
114
|
+
children: [/* @__PURE__ */ S(p, {
|
|
113
115
|
sx: { flex: 1 },
|
|
114
116
|
children: [
|
|
115
|
-
/* @__PURE__ */
|
|
117
|
+
/* @__PURE__ */ x(y, {
|
|
116
118
|
variant: "body1",
|
|
117
119
|
sx: {
|
|
118
120
|
fontWeight: 700,
|
|
@@ -120,47 +122,47 @@ function C(C) {
|
|
|
120
122
|
},
|
|
121
123
|
children: "Step 1. Download your Data Use Certificate"
|
|
122
124
|
}),
|
|
123
|
-
/* @__PURE__ */
|
|
125
|
+
/* @__PURE__ */ x(y, {
|
|
124
126
|
variant: "body1",
|
|
125
127
|
sx: {
|
|
126
|
-
...
|
|
128
|
+
...c,
|
|
127
129
|
mb: 2
|
|
128
130
|
},
|
|
129
131
|
children: "As a first step, you will need to download a PDF of the Data Use Certificate with the names of your Collaborators and Signing Official. Make sure the names are correct and complete before downloading."
|
|
130
132
|
}),
|
|
131
|
-
/* @__PURE__ */
|
|
133
|
+
/* @__PURE__ */ x(y, {
|
|
132
134
|
variant: "body1",
|
|
133
135
|
sx: {
|
|
134
|
-
...
|
|
136
|
+
...c,
|
|
135
137
|
mb: 2
|
|
136
138
|
},
|
|
137
139
|
children: "If needed, you can modify the printed list of collaborators by adding or removing names on the paper copy before uploading."
|
|
138
140
|
}),
|
|
139
|
-
|
|
141
|
+
I ? /* @__PURE__ */ S(f, {
|
|
140
142
|
severity: "error",
|
|
141
143
|
children: [
|
|
142
|
-
/* @__PURE__ */
|
|
143
|
-
/* @__PURE__ */
|
|
144
|
-
|
|
144
|
+
/* @__PURE__ */ x("strong", { children: "Sorry, we couldn't prepare your DUC for download." }),
|
|
145
|
+
/* @__PURE__ */ x("br", {}),
|
|
146
|
+
I.reason
|
|
145
147
|
]
|
|
146
|
-
}) : /* @__PURE__ */
|
|
148
|
+
}) : /* @__PURE__ */ x(m, {
|
|
147
149
|
component: "a",
|
|
148
|
-
href:
|
|
150
|
+
href: R ?? void 0,
|
|
149
151
|
target: "_blank",
|
|
150
152
|
rel: "noopener",
|
|
151
153
|
variant: "outlined",
|
|
152
|
-
disabled:
|
|
153
|
-
endIcon: /* @__PURE__ */
|
|
154
|
+
disabled: ne,
|
|
155
|
+
endIcon: /* @__PURE__ */ x(s, {
|
|
154
156
|
icon: "download",
|
|
155
157
|
wrap: !1
|
|
156
158
|
}),
|
|
157
159
|
children: "Download DUC for Signatures"
|
|
158
160
|
})
|
|
159
161
|
]
|
|
160
|
-
}), /* @__PURE__ */
|
|
162
|
+
}), /* @__PURE__ */ S(p, {
|
|
161
163
|
sx: { flex: 1 },
|
|
162
164
|
children: [
|
|
163
|
-
/* @__PURE__ */
|
|
165
|
+
/* @__PURE__ */ x(y, {
|
|
164
166
|
variant: "body1",
|
|
165
167
|
sx: {
|
|
166
168
|
fontWeight: 700,
|
|
@@ -168,76 +170,76 @@ function C(C) {
|
|
|
168
170
|
},
|
|
169
171
|
children: "Step 2. Fill out and upload a Data Use Certificate"
|
|
170
172
|
}),
|
|
171
|
-
/* @__PURE__ */
|
|
173
|
+
/* @__PURE__ */ x(y, {
|
|
172
174
|
variant: "body1",
|
|
173
175
|
sx: {
|
|
174
|
-
...
|
|
176
|
+
...c,
|
|
175
177
|
mb: 2
|
|
176
178
|
},
|
|
177
179
|
children: "You must download and fill out a Data Use Certificate (DUC). Be sure to upload the completed DUC below."
|
|
178
180
|
}),
|
|
179
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ S(y, {
|
|
180
182
|
variant: "body1",
|
|
181
183
|
component: "ol",
|
|
182
184
|
sx: {
|
|
183
|
-
...
|
|
185
|
+
...c,
|
|
184
186
|
mb: 2,
|
|
185
187
|
pl: 3
|
|
186
188
|
},
|
|
187
189
|
children: [
|
|
188
|
-
/* @__PURE__ */
|
|
189
|
-
/* @__PURE__ */
|
|
190
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ x("li", { children: "Download the DUC document." }),
|
|
191
|
+
/* @__PURE__ */ x("li", { children: "Fill out the DUC, following the instructions in the PDF." }),
|
|
192
|
+
/* @__PURE__ */ x("li", { children: "Upload the completed certificate using the button below:" })
|
|
191
193
|
]
|
|
192
194
|
}),
|
|
193
|
-
|
|
195
|
+
M ? /* @__PURE__ */ x(_, {
|
|
194
196
|
variant: "rectangular",
|
|
195
197
|
width: 200,
|
|
196
198
|
height: 36
|
|
197
|
-
}) : /* @__PURE__ */
|
|
199
|
+
}) : /* @__PURE__ */ x(l, {
|
|
198
200
|
id: "signed-duc",
|
|
199
201
|
documentName: "Signed DUC",
|
|
200
|
-
isLoading:
|
|
202
|
+
isLoading: G || q,
|
|
201
203
|
uploadCallback: (e) => {
|
|
202
|
-
|
|
204
|
+
ie(e);
|
|
203
205
|
},
|
|
204
|
-
fileHandleAssociations:
|
|
206
|
+
fileHandleAssociations: te
|
|
205
207
|
})
|
|
206
208
|
]
|
|
207
209
|
})]
|
|
208
210
|
}),
|
|
209
|
-
|
|
211
|
+
z && /* @__PURE__ */ S(f, {
|
|
210
212
|
severity: "error",
|
|
211
213
|
sx: { mt: 2 },
|
|
212
214
|
children: [
|
|
213
|
-
/* @__PURE__ */
|
|
214
|
-
/* @__PURE__ */
|
|
215
|
-
|
|
215
|
+
/* @__PURE__ */ x("strong", { children: "Sorry, we couldn't save your change." }),
|
|
216
|
+
/* @__PURE__ */ x("br", {}),
|
|
217
|
+
z
|
|
216
218
|
]
|
|
217
219
|
}),
|
|
218
|
-
|
|
220
|
+
V && /* @__PURE__ */ S(f, {
|
|
219
221
|
severity: "error",
|
|
220
222
|
sx: { mt: 2 },
|
|
221
223
|
children: [
|
|
222
|
-
/* @__PURE__ */
|
|
223
|
-
/* @__PURE__ */
|
|
224
|
-
|
|
224
|
+
/* @__PURE__ */ x("strong", { children: "Sorry, we couldn't submit your request." }),
|
|
225
|
+
/* @__PURE__ */ x("br", {}),
|
|
226
|
+
V
|
|
225
227
|
]
|
|
226
228
|
})
|
|
227
229
|
] }) }),
|
|
228
|
-
/* @__PURE__ */
|
|
229
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ S(h, { children: [
|
|
231
|
+
/* @__PURE__ */ x(m, {
|
|
230
232
|
variant: "outlined",
|
|
231
|
-
onClick:
|
|
233
|
+
onClick: O,
|
|
232
234
|
children: "Back"
|
|
233
235
|
}),
|
|
234
|
-
/* @__PURE__ */
|
|
235
|
-
/* @__PURE__ */
|
|
236
|
+
/* @__PURE__ */ x(p, { sx: { flexGrow: 1 } }),
|
|
237
|
+
/* @__PURE__ */ x(m, {
|
|
236
238
|
variant: "contained",
|
|
237
|
-
disabled:
|
|
238
|
-
loading:
|
|
239
|
+
disabled: re,
|
|
240
|
+
loading: Y,
|
|
239
241
|
onClick: () => {
|
|
240
|
-
|
|
242
|
+
ae();
|
|
241
243
|
},
|
|
242
244
|
children: "Submit Request"
|
|
243
245
|
})
|
|
@@ -245,6 +247,6 @@ function C(C) {
|
|
|
245
247
|
] });
|
|
246
248
|
}
|
|
247
249
|
//#endregion
|
|
248
|
-
export {
|
|
250
|
+
export { w as default };
|
|
249
251
|
|
|
250
252
|
//# sourceMappingURL=ManualUploadDucStep.js.map
|