@stoker-platform/web-app 0.5.113 → 0.5.114
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/package.json +1 -1
- package/src/Files.tsx +5 -5
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
package/src/Files.tsx
CHANGED
|
@@ -520,7 +520,7 @@ export const RecordFiles = ({ collection, record }: FilesProps) => {
|
|
|
520
520
|
[uploadFiles, shouldSkipPermissionsDialog, getDefaultPermissions],
|
|
521
521
|
)
|
|
522
522
|
|
|
523
|
-
const handleConfirmFilename = useCallback(
|
|
523
|
+
const handleConfirmFilename = useCallback(() => {
|
|
524
524
|
if (!pendingUploadFile) return
|
|
525
525
|
const trimmedName = editingFilename.trim()
|
|
526
526
|
const validationError = validateStorageName(trimmedName)
|
|
@@ -531,12 +531,12 @@ export const RecordFiles = ({ collection, record }: FilesProps) => {
|
|
|
531
531
|
if (shouldSkipPermissionsDialog()) {
|
|
532
532
|
if (uploadLockRef.current) return
|
|
533
533
|
uploadLockRef.current = true
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
} finally {
|
|
534
|
+
setShowFilenameDialog(false)
|
|
535
|
+
uploadFiles([pendingUploadFile], getDefaultPermissions(), trimmedName).finally(() => {
|
|
537
536
|
uploadLockRef.current = false
|
|
538
|
-
}
|
|
537
|
+
})
|
|
539
538
|
} else {
|
|
539
|
+
setShowFilenameDialog(false)
|
|
540
540
|
setShowPermissionsDialog(true)
|
|
541
541
|
}
|
|
542
542
|
}, [pendingUploadFile, editingFilename, shouldSkipPermissionsDialog, uploadFiles, getDefaultPermissions])
|