gui work
This commit is contained in:
parent
8380cb8e6a
commit
9d787f761f
3 changed files with 33 additions and 8 deletions
|
|
@ -773,6 +773,28 @@ const FileUpload = () => {
|
|||
|
||||
{/* Content */}
|
||||
<div className="px-6 pb-6 pt-5">
|
||||
{/* No Folders - Show create folder prompt instead of upload UI */}
|
||||
{!preSelectedCollectionId && isCollectionsInitialized && !isLoadingCollections && availableCollections.length === 0 ? (
|
||||
<div className="text-center py-12">
|
||||
<div className={`h-20 w-20 ${getThemeClasses("bg-muted")} rounded-2xl flex items-center justify-center mx-auto mb-4`}>
|
||||
<FolderIcon className="h-10 w-10 text-gray-400" />
|
||||
</div>
|
||||
<h3 className={`text-xl font-semibold mb-2 ${getThemeClasses("text-primary")}`}>
|
||||
No folders yet
|
||||
</h3>
|
||||
<p className={`mb-6 max-w-md mx-auto ${getThemeClasses("text-secondary")}`}>
|
||||
You need to create a folder before you can upload files. Folders help you organize your encrypted files.
|
||||
</p>
|
||||
<Button
|
||||
onClick={() => navigate("/file-manager/collections/create")}
|
||||
variant="primary"
|
||||
icon={FolderIcon}
|
||||
>
|
||||
Create Your First Folder
|
||||
</Button>
|
||||
</div>
|
||||
) : (
|
||||
<>
|
||||
<div className={`grid grid-cols-1 gap-8 ${preSelectedCollectionId ? "lg:grid-cols-3" : ""}`}>
|
||||
{/* Upload Area */}
|
||||
<div className={`space-y-6 ${preSelectedCollectionId ? "lg:col-span-2" : ""}`}>
|
||||
|
|
@ -1339,6 +1361,8 @@ const FileUpload = () => {
|
|||
)}
|
||||
</div>
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
</Card>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue