fix: prevent duplicate uploads and group asset commits
This commit is contained in:
@@ -35,6 +35,8 @@ export default function UploadZone() {
|
||||
|
||||
const {
|
||||
isUploading,
|
||||
isChecking,
|
||||
isResolvingDriveError,
|
||||
globalError,
|
||||
setGlobalError,
|
||||
overwriteConfirm,
|
||||
@@ -43,6 +45,7 @@ export default function UploadZone() {
|
||||
setNoChangesFolder,
|
||||
driveError,
|
||||
handleUpload,
|
||||
handleOverwriteCancel,
|
||||
handleDriveContinue,
|
||||
handleDriveCancel,
|
||||
handleCancel,
|
||||
@@ -93,7 +96,7 @@ export default function UploadZone() {
|
||||
secret={secret}
|
||||
secretVisible={secretVisible}
|
||||
secretError={secretError}
|
||||
disabled={isUploading}
|
||||
disabled={isUploading || isChecking}
|
||||
onChange={handleSecretChange}
|
||||
onToggleVisible={toggleSecretVisible}
|
||||
/>
|
||||
@@ -101,7 +104,7 @@ export default function UploadZone() {
|
||||
{entries.length === 0 && (
|
||||
<div>
|
||||
<FolderDropzone
|
||||
isUploading={isUploading}
|
||||
isUploading={isUploading || isChecking}
|
||||
onFolderSelected={handleFolderSelected}
|
||||
onError={setGlobalError}
|
||||
/>
|
||||
@@ -128,6 +131,7 @@ export default function UploadZone() {
|
||||
|
||||
<ActionButtons
|
||||
isUploading={isUploading}
|
||||
isChecking={isChecking}
|
||||
isSecretEmpty={isSecretEmpty}
|
||||
hasPendingOrErrors={hasPendingOrErrors}
|
||||
allDone={allDone}
|
||||
@@ -141,8 +145,9 @@ export default function UploadZone() {
|
||||
<OverwriteConfirmModal
|
||||
folderName={overwriteConfirm.folderName}
|
||||
diffs={overwriteConfirm.diffs}
|
||||
onCancel={() => setOverwriteConfirm(null)}
|
||||
onCancel={handleOverwriteCancel}
|
||||
onConfirm={proceedUpload}
|
||||
disabled={isUploading || isChecking || isResolvingDriveError}
|
||||
/>
|
||||
)}
|
||||
|
||||
@@ -162,6 +167,7 @@ export default function UploadZone() {
|
||||
error={driveError.error}
|
||||
onCancel={handleDriveCancel}
|
||||
onContinue={handleDriveContinue}
|
||||
disabled={isResolvingDriveError}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user