react-hook-form-antd icon indicating copy to clipboard operation
react-hook-form-antd copied to clipboard

Antd select borders doesn't change on error

Open rin-st opened this issue 1 year ago โ€ข 2 comments

Component doesn't change status of antd Select depending on error

Expected behavior: passing status: 'error' to Select if field has error, so border will be red

rin-st avatar Nov 15 '23 20:11 rin-st

Hi @rin-st , we have the same issue, but I have solved this issue by copying this component to my local (without changing) and creating my own component.

https://github.com/jsun969/react-hook-form-antd/blob/main/src/FormItem.tsx

and it works as it should.

ahmadnzr avatar Jan 01 '24 16:01 ahmadnzr

Thank you @ahmadnzr ! But I think it's not a solution. You'll need to do it on every update of the lib. I also found a solution using antd Form.Item + react-hook-form Controller, but with this lib it would be easier

rin-st avatar Jan 02 '24 11:01 rin-st