Disabled field
Reading Disabled status from Node props:
Loading...
function FormDemo() {const DisabledInput = ({ node, handler }) => {const { value, disabled } = nodereturn (<div><input disabled={disabled} value={value} onChange={handler.handleChange} /></div>)}const form = useForm({onSubmit(values) {alert(JSON.stringify(values, null, 2))console.log('values', values)},components: {DisabledInput,},children: [{label: 'First Name',name: 'firstName',component: 'DisabledInput',disabled: true,value: 'Steve',},{label: 'Last Name',name: 'lastName',component: 'DisabledInput',value: 'Jobs',},{component: 'Submit',text: 'Submit',},],})return <Form form={form} />}
LIVE DEMO