diff --git a/app/frontend/src/javascript/components/authentication-provider/provider-form.tsx b/app/frontend/src/javascript/components/authentication-provider/provider-form.tsx index f628f7a92..14675b889 100644 --- a/app/frontend/src/javascript/components/authentication-provider/provider-form.tsx +++ b/app/frontend/src/javascript/components/authentication-provider/provider-form.tsx @@ -4,9 +4,9 @@ import { react2angular } from 'react2angular'; import { AuthenticationProvider } from '../../models/authentication-provider'; import { Loader } from '../base/loader'; import { IApplication } from '../../models/application'; -import { RHFInput } from '../base/rhf-input'; +import { FormInput } from '../form/form-input'; import { useTranslation } from 'react-i18next'; -import { FabSelect } from '../base/fab-select'; +import { FormSelect } from '../form/form-select'; declare const Application: IApplication; @@ -46,8 +46,8 @@ export const ProviderForm: React.FC = ({ action, provider, on return (
- - + + ); diff --git a/app/frontend/src/javascript/components/base/rhf-input.tsx b/app/frontend/src/javascript/components/form/form-input.tsx similarity index 72% rename from app/frontend/src/javascript/components/base/rhf-input.tsx rename to app/frontend/src/javascript/components/form/form-input.tsx index cb2acb672..456be40c7 100644 --- a/app/frontend/src/javascript/components/base/rhf-input.tsx +++ b/app/frontend/src/javascript/components/form/form-input.tsx @@ -4,7 +4,7 @@ import { FieldValues } from 'react-hook-form/dist/types/fields'; import { FieldPath } from 'react-hook-form/dist/types/path'; import { FormComponent } from '../../models/form-component'; -interface RHFInputProps extends InputHTMLAttributes, FormComponent{ +interface FormInputProps extends InputHTMLAttributes, FormComponent{ id: string, label?: string, tooltip?: string, @@ -16,10 +16,10 @@ interface RHFInputProps extends InputHTMLAttributes({ id, register, label, tooltip, defaultValue, icon, className, rules, readOnly, disabled, type, addOn, addOnClassName, placeholder, error, step }: RHFInputProps) => { +export const FormInput = ({ id, register, label, tooltip, defaultValue, icon, className, rules, readOnly, disabled, type, addOn, addOnClassName, placeholder, error, step }: FormInputProps) => { // Compose classnames from props const classNames = ` - rhf-input ${className || ''} + form-input ${className || ''} ${error && error[id] ? 'is-incorrect' : ''} ${rules && rules.required ? 'is-required' : ''} ${readOnly ? 'is-readOnly' : ''} @@ -27,12 +27,12 @@ export const RHFInput = ({ id, register, label return (