-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
### What problem does this PR solve? Feat: Add FilesTable #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
- Loading branch information
Showing
20 changed files
with
824 additions
and
51 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
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,13 @@ | ||
import { Skeleton } from '@/components/ui/skeleton'; | ||
|
||
export function SkeletonCard() { | ||
return ( | ||
<div className="flex flex-col space-y-3 items-center"> | ||
<Skeleton className="h-[125px] w-[250px] rounded-xl" /> | ||
<div className="space-y-2 w-[250px]"> | ||
<Skeleton className="h-4 w-[250px]" /> | ||
<Skeleton className="h-4 w-[200px]" /> | ||
</div> | ||
</div> | ||
); | ||
} |
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,27 @@ | ||
import { PropsWithChildren } from 'react'; | ||
import { SkeletonCard } from './skeleton-card'; | ||
import { TableCell, TableRow } from './ui/table'; | ||
|
||
type IProps = { columnsLength: number }; | ||
|
||
function Row({ children, columnsLength }: PropsWithChildren & IProps) { | ||
return ( | ||
<TableRow> | ||
<TableCell colSpan={columnsLength} className="h-24 text-center "> | ||
{children} | ||
</TableCell> | ||
</TableRow> | ||
); | ||
} | ||
|
||
export function TableSkeleton({ columnsLength }: { columnsLength: number }) { | ||
return ( | ||
<Row columnsLength={columnsLength}> | ||
<SkeletonCard></SkeletonCard> | ||
</Row> | ||
); | ||
} | ||
|
||
export function TableEmpty({ columnsLength }: { columnsLength: number }) { | ||
return <Row columnsLength={columnsLength}>No results.</Row>; | ||
} |
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
Oops, something went wrong.