feat: render text field if selected option custom

This commit is contained in:
karishmas6
2024-08-29 23:03:47 +05:30
parent 553c977870
commit a8248ae1b0

View File

@@ -190,15 +190,15 @@ export const InterpretationLog = () => {
<FormControlLabel value="10" control={<Radio />} label="10" /> <FormControlLabel value="10" control={<Radio />} label="10" />
<FormControlLabel value="100" control={<Radio />} label="100" /> <FormControlLabel value="100" control={<Radio />} label="100" />
<FormControlLabel value="custom" control={<Radio />} label="Custom" /> <FormControlLabel value="custom" control={<Radio />} label="Custom" />
{customValue && ( {selectedOption === 'custom' && (
<input                         <TextField
type="number"                           type="number"
value={customValue}                           value={customValue}
onChange={{}}                           onChange={handleCustomValueChange}
placeholder="Enter custom value"                           placeholder="Enter number"
style={{ marginLeft: 10 }}                           sx={{ marginLeft: '10px', marginTop: '10px', color: 'white' }}
/>                         />
)}                       )}
</RadioGroup> </RadioGroup>
</FormControl> </FormControl>