Skip to content

Demos

Empty

<DataInput.LastName
onChange={(value) => console.log('onChange', value)}
/>

Placeholder

<DataInput.LastName
placeholder="Enter email address..."
onChange={(value) => console.log('onChange', value)}
/>

Label

<DataInput.LastName
label="Label text"
onChange={(value) => console.log('onChange', value)}
/>

Label and value

<DataInput.LastName
label="Label text"
value="Smith"
onChange={(value) => console.log('onChange', value)}
/>

Disabled

<DataInput.LastName
value="Smith"
label="Label text"
onChange={(value) => console.log('onChange', value)}
disabled
/>

Error

This is what is wrong...
<DataInput.LastName
value="Unnamed"
label="Label text"
onChange={(value) => console.log('onChange', value)}
error={new FormError('This is what is wrong...')}
/>

Validation - Required

<DataInput.LastName
value="Smith"
label="Label text"
onChange={(value) => console.log('onChange', value)}
required
/>