mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Merge pull request #2046 from omnivore-app/fix/upload-progress
Fix issues with progress not being displayed on upload complete
This commit is contained in:
commit
1ae0b9e6dd
1 changed files with 3 additions and 2 deletions
|
|
@ -115,7 +115,7 @@ export function UploadModal(props: UploadModalProps): JSX.Element {
|
|||
id: uuidv4(),
|
||||
file: file,
|
||||
name: file.name,
|
||||
percent: 0,
|
||||
progress: 0,
|
||||
status: 'inprogress',
|
||||
}
|
||||
})
|
||||
|
|
@ -160,6 +160,7 @@ export function UploadModal(props: UploadModalProps): JSX.Element {
|
|||
},
|
||||
})
|
||||
|
||||
file.progress = 100
|
||||
file.status = 'success'
|
||||
setUploadFiles([...allFiles])
|
||||
} catch (error) {
|
||||
|
|
@ -306,7 +307,7 @@ export function UploadModal(props: UploadModalProps): JSX.Element {
|
|||
>
|
||||
{file.name}
|
||||
</Box>
|
||||
{file.progress == 100 ? (
|
||||
{file.status != 'inprogress' ? (
|
||||
<HStack
|
||||
alignment="center"
|
||||
css={{ marginLeft: 'auto', fontSize: '14px' }}
|
||||
|
|
|
|||
Loading…
Reference in a new issue