1
0
mirror of https://github.com/chinchang/web-maker.git synced 2025-07-26 08:11:17 +02:00
This commit is contained in:
Kushagra Gour
2024-03-12 23:38:05 +05:30
parent 6e5e33a146
commit 00b105a352
4 changed files with 127 additions and 6 deletions

View File

@@ -6,6 +6,7 @@ import { copyToClipboard } from '../utils';
import { Trans } from '@lingui/macro';
import { ProBadge } from './ProBadge';
import { LoaderWithText } from './Loader';
import { Text } from './Text';
const Assets = () => {
const [files, setFiles] = useState([]);
@@ -174,12 +175,19 @@ const Assets = () => {
{isUploading ? <div class="asset-manager__progress-bar"></div> : null}
<div style={{ visibility: isUploading ? 'hidden' : 'visible' }}>
<p>Drop file here to upload</p>
<input
type="file"
onChange={handleFileUpload}
style={{ marginTop: 'auto' }}
/>
<VStack gap={1} align="center">
<Text tag="p" align="center">
Drop files here to upload
</Text>
<Text tag="p" appearance="secondary" align="center">
File should be max 300KB in size
</Text>
<input
type="file"
onChange={handleFileUpload}
style={{ marginTop: 'auto' }}
/>
</VStack>
</div>
</div>
{isFetchingFiles && <LoaderWithText>Fetching files...</LoaderWithText>}