File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/components/shared/field Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ export const FIELD_TAGS = {
1111interface FieldProps {
1212 className ?: string ;
1313 inputClassName ?: string ;
14- name : string ;
14+ name ? : string ;
1515 borderColor ?: string ;
1616 type ?: string ;
1717 children ?: ReactNode ;
@@ -45,17 +45,17 @@ const Field = forwardRef<any, FieldProps>(
4545 className = { clsx (
4646 'remove-autocomplete-styles w-full appearance-none rounded-md border border-gray-70 px-4 text-black transition-colors duration-200 placeholder:text-gray-60 placeholder-shown:text-gray-70 focus:border-white focus:shadow-field-focus focus:outline-none md:px-3' ,
4747 ( Tag === FIELD_TAGS . INPUT || Tag === FIELD_TAGS . SELECT ) && 'h-14 md:h-12' ,
48- Tag === FIELD_TAGS . TEXTAREA && 'md: min-h-24 min-h- [104px] py-4' ,
48+ Tag === FIELD_TAGS . TEXTAREA && 'min-h-[104px] py-4 md:min-h-24 ' ,
4949 Tag === FIELD_TAGS . SELECT &&
5050 'bg-white bg-[url(/images/chevron-down.svg)] bg-[center_right_1rem] bg-no-repeat' ,
5151 error ? 'border-none shadow-field-error' : borderColor ,
5252 inputClassName ,
5353 ) }
5454 ref = { ref }
55- name = { name }
5655 type = { Tag !== FIELD_TAGS . SELECT ? type : undefined }
5756 disabled = { isDisabled }
5857 { ...otherProps }
58+ { ...( name && { name } ) }
5959 >
6060 { Tag === FIELD_TAGS . SELECT ? children : null }
6161 </ Tag >
You can’t perform that action at this time.
0 commit comments