mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-03 06:27:11 +01:00
18 lines
447 B
TypeScript
18 lines
447 B
TypeScript
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>
|
|
)
|
|
}
|