import React, { FC } from 'react'
import { MEDIA_DEFAULT_MAX_SIZE } from '../../constants'
import FileField from './file-field'

interface Props {
    name: string
    label?: string
    help?: string
}

const ImageField: FC<Props> = ({ name, label = 'Image', help = 'Approx 128 x 128. Max 5 MBs.' }) => {
    return (
        <FileField
            name={name}
            label={label}
            width={128}
            height={128}
            help={help}
            previewWidth={64}
            maxSize={MEDIA_DEFAULT_MAX_SIZE} />
    )
}

export default ImageField
