-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #415 from IQSS/feature/405-files-tab-content-infin…
…ite-scrolling 405 Infinite Scrolling on Dataset Files
- Loading branch information
Showing
56 changed files
with
2,325 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { FilePreview } from './FilePreview' | ||
|
||
export interface FilesWithCount { | ||
files: FilePreview[] | ||
totalFilesCount: number | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
src/files/domain/useCases/getFilesByDatasetPersistentIdWithCount.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { FileRepository } from '../repositories/FileRepository' | ||
import { FileCriteria } from '../models/FileCriteria' | ||
import { DatasetVersion } from '../../../dataset/domain/models/Dataset' | ||
import { FilePaginationInfo } from '../models/FilePaginationInfo' | ||
import { FilesWithCount } from '../models/FilesWithCount' | ||
|
||
export async function getFilesByDatasetPersistentIdWithCount( | ||
fileRepository: FileRepository, | ||
datasetPersistentId: string, | ||
datasetVersion: DatasetVersion, | ||
paginationInfo?: FilePaginationInfo, | ||
criteria?: FileCriteria | ||
): Promise<FilesWithCount> { | ||
return fileRepository | ||
.getAllByDatasetPersistentIdWithCount( | ||
datasetPersistentId, | ||
datasetVersion, | ||
paginationInfo, | ||
criteria | ||
) | ||
.catch((error: Error) => { | ||
throw new Error(error.message) | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export const FILES_TAB_INFINITE_SCROLL_ENABLED = true |
17 changes: 17 additions & 0 deletions
17
src/sections/dataset/dataset-files/DatasetFilesScrollable.module.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
.files-scrollable-container { | ||
min-height: 400px; | ||
max-height: 650px; | ||
overflow-y: auto; | ||
|
||
&--empty { | ||
min-height: auto; | ||
} | ||
|
||
.criteria-form-container { | ||
position: sticky; | ||
top: 0; | ||
z-index: 2; | ||
padding: 0.25rem 0.25rem 1rem; | ||
background: var(--bs-white); | ||
} | ||
} |
Oops, something went wrong.