fix: upload image (#1522)

This commit is contained in:
zxhlyh
2023-11-16 11:56:11 +08:00
committed by GitHub
parent d9336d9ae4
commit cfbfd59b8f
7 changed files with 40 additions and 7 deletions

View File

@@ -88,6 +88,7 @@ const Uploader: FC<UploaderProps> = ({
absolute block inset-0 opacity-0 text-[0]
${disabled ? 'cursor-not-allowed' : 'cursor-pointer'}
`}
onClick={e => (e.target as HTMLInputElement).value = ''}
type='file'
accept='.png, .jpg, .jpeg, .webp, .gif'
onChange={handleChange}