feat: clipboard paste (#1663)
This commit is contained in:
@@ -4,7 +4,7 @@ import { useParams } from 'next/navigation'
|
||||
import { useTranslation } from 'react-i18next'
|
||||
import { imageUpload } from './utils'
|
||||
import type { ImageFile } from '@/types/app'
|
||||
import { TransferMethod } from '@/types/app'
|
||||
import { ALLOW_FILE_EXTENSIONS, TransferMethod } from '@/types/app'
|
||||
import { useToastContext } from '@/app/components/base/toast'
|
||||
|
||||
type UploaderProps = {
|
||||
@@ -90,7 +90,7 @@ const Uploader: FC<UploaderProps> = ({
|
||||
`}
|
||||
onClick={e => (e.target as HTMLInputElement).value = ''}
|
||||
type='file'
|
||||
accept='.png, .jpg, .jpeg, .webp, .gif'
|
||||
accept={ALLOW_FILE_EXTENSIONS.map(ext => `.${ext}`).join(',')}
|
||||
onChange={handleChange}
|
||||
disabled={disabled}
|
||||
/>
|
||||
|
Reference in New Issue
Block a user