import React from 'react'

import InputWrapper from './inputWrapper'

interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
  label: string
}

export default function Input(props: InputProps) {
  const { label, required, type = 'text', ...rest } = props

  return (
    <InputWrapper label="label" required={required}>
      <input type={type} required={required} className="input-text" {...rest} />
    </InputWrapper>
  )
}
