@@ -52,6 +52,7 @@ import { PROJECTS_URL } from "../../../../../site-config/hca-dcp/dev/config";
5252import {
5353 ROUTE_BULK_DOWNLOAD ,
5454 ROUTE_EXPORT_TO_TERRA ,
55+ ROUTE_MANIFEST_DOWNLOAD ,
5556} from "../../../../../site-config/hca-dcp/dev/export/constants" ;
5657import {
5758 processAggregatedOrArrayValue ,
@@ -562,6 +563,23 @@ export const buildExportMethodHeroCurlCommand = (
562563 return getExportMethodHero ( tabValue , title ) ;
563564} ;
564565
566+ /**
567+ * Build props for manifest download Hero component.
568+ * @param _ - Unused.
569+ * @param viewContext - View context.
570+ * @returns model to be used as props for the Hero component.
571+ */
572+ export const buildExportMethodHeroManifestDownload = (
573+ _ : Unused ,
574+ viewContext : ViewContext
575+ ) : React . ComponentProps < typeof C . BackPageHero > => {
576+ const title = "Request File Manifest" ;
577+ const {
578+ exploreState : { tabValue } ,
579+ } = viewContext ;
580+ return getExportMethodHero ( tabValue , title ) ;
581+ } ;
582+
565583/**
566584 * Build props for export to terra Hero component.
567585 * @param _ - Unused.
@@ -579,6 +597,21 @@ export const buildExportMethodHeroTerra = (
579597 return getExportMethodHero ( tabValue , title ) ;
580598} ;
581599
600+ /**
601+ * Build props for ExportMethod component for display of the manifest download section.
602+ * @returns model to be used as props for the ExportMethod component.
603+ */
604+ export const buildExportMethodManifestDownload = ( ) : React . ComponentProps <
605+ typeof C . ExportMethod
606+ > => ( {
607+ buttonLabel : "Request File Manifest" ,
608+ description :
609+ "Request a file manifest for the current query containing the full list of selected files and the metadata for each file." ,
610+ disabled : false ,
611+ route : ROUTE_MANIFEST_DOWNLOAD ,
612+ title : "Download a File Manifest with Metadata for the Selected Data" ,
613+ } ) ;
614+
582615/**
583616 * Build props for ExportMethod component for display of the export to terra section.
584617 * @returns model to be used as props for the ExportMethod component.
@@ -797,6 +830,34 @@ export const buildLibraryConstructionApproach = (
797830 } ;
798831} ;
799832
833+ /**
834+ * Build props for ManifestDownload component.
835+ * @param _ - Unused.
836+ * @param viewContext - View context.
837+ * @returns model to be used as props for the ManifestDownload component.
838+ */
839+ export const buildManifestDownload = (
840+ _ : Unused ,
841+ viewContext : ViewContext
842+ ) : React . ComponentProps < typeof C . ManifestDownload > => {
843+ const {
844+ exploreState : { filterState } ,
845+ fileManifestState,
846+ } = viewContext ;
847+ // Get the form facets.
848+ const formFacet = getFormFacets ( fileManifestState ) ;
849+ return {
850+ ManifestDownloadForm : C . ManifestDownloadForm ,
851+ ManifestDownloadStart : MDX . ManifestDownloadStart ,
852+ ManifestDownloadSuccess : MDX . ManifestDownloadSuccess ,
853+ fileManifestState,
854+ fileManifestType : FILE_MANIFEST_TYPE . DOWNLOAD_MANIFEST ,
855+ fileSummaryFacetName : HCA_DCP_CATEGORY_KEY . FILE_FORMAT ,
856+ filters : filterState ,
857+ formFacet,
858+ } ;
859+ } ;
860+
800861/**
801862 * Build props for the project title Link component from the given entity response.
802863 * @param projectsResponse - Response model return from the entity response API.
0 commit comments