diff --git a/services/web/frontend/js/features/settings/components/account-info-section.tsx b/services/web/frontend/js/features/settings/components/account-info-section.tsx
index 4bbd9df24a..72b2598c6d 100644
--- a/services/web/frontend/js/features/settings/components/account-info-section.tsx
+++ b/services/web/frontend/js/features/settings/components/account-info-section.tsx
@@ -1,5 +1,4 @@
import { useState } from 'react'
-import { ControlLabel, FormControl, FormGroup } from 'react-bootstrap'
import { useTranslation } from 'react-i18next'
import {
getUserFacingMessage,
@@ -11,6 +10,10 @@ import useAsync from '../../../shared/hooks/use-async'
import { useUserContext } from '../../../shared/context/user-context'
import ButtonWrapper from '@/features/ui/components/bootstrap-5/wrappers/button-wrapper'
import NotificationWrapper from '@/features/ui/components/bootstrap-5/wrappers/notification-wrapper'
+import FormGroupWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-group-wrapper'
+import FormLabelWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-label-wrapper'
+import FormControlWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-control-wrapper'
+import FormText from '@/features/ui/components/bootstrap-5/form/form-text'
function AccountInfoSection() {
const { t } = useTranslation()
@@ -104,20 +107,20 @@ function AccountInfoSection() {
required={false}
/>
{isSuccess ? (
-
+
-
+
) : null}
{isError ? (
-
+
-
+
) : null}
{canUpdateEmail || canUpdateNames ? (
- ) => {
+ const handleInvalid = (event: React.InvalidEvent) => {
event.preventDefault()
}
const handleChangeAndValidity = (
- event: React.ChangeEvent
+ event: React.ChangeEvent
) => {
handleChange(event)
setValidationMessage(event.target.validationMessage)
@@ -174,18 +175,17 @@ function ReadOrWriteFormGroup({
if (!canEdit) {
return (
-
- {label}
-
-
+
+ {label}
+
+
)
}
return (
-
- {label}
-
+ {label}
+
- {validationMessage ? (
- {validationMessage}
- ) : null}
-
+ {validationMessage && {validationMessage}}
+
)
}
diff --git a/services/web/frontend/js/features/settings/components/emails/add-email/country-input.tsx b/services/web/frontend/js/features/settings/components/emails/add-email/country-input.tsx
index 3f2a518c32..e506a054c4 100644
--- a/services/web/frontend/js/features/settings/components/emails/add-email/country-input.tsx
+++ b/services/web/frontend/js/features/settings/components/emails/add-email/country-input.tsx
@@ -4,6 +4,7 @@ import { useCombobox } from 'downshift'
import classnames from 'classnames'
import countries, { CountryCode } from '../../../data/countries-list'
import { bsVersion } from '@/features/utils/bootstrap-5'
+import FormControlWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-control-wrapper'
type CountryInputProps = {
setValue: React.Dispatch>
@@ -62,7 +63,7 @@ function Downshift({ setValue, inputRef }: CountryInputProps) {
>
{t('country')}
- ) => {
setInputValue(event.target.value)
@@ -74,8 +75,6 @@ function Downshift({ setValue, inputRef }: CountryInputProps) {
},
ref: inputRef,
})}
- className="form-control"
- type="text"
placeholder={t('country')}
/>
diff --git a/services/web/frontend/js/features/settings/components/emails/add-email/input.tsx b/services/web/frontend/js/features/settings/components/emails/add-email/input.tsx
index 478dc06812..60fd1201fd 100644
--- a/services/web/frontend/js/features/settings/components/emails/add-email/input.tsx
+++ b/services/web/frontend/js/features/settings/components/emails/add-email/input.tsx
@@ -11,6 +11,7 @@ import { getJSON } from '../../../../../infrastructure/fetch-json'
import useAbortController from '../../../../../shared/hooks/use-abort-controller'
import domainBlocklist from '../../../domain-blocklist'
import { debugConsole } from '@/utils/debugging'
+import FormControlWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-control-wrapper'
const LOCAL_AND_DOMAIN_REGEX = /([^@]+)@(.+)/
@@ -48,7 +49,7 @@ type InputProps = {
function Input({ onChange, handleAddNewEmail }: InputProps) {
const { signal } = useAbortController()
- const inputRef = useRef(null)
+ const inputRef = useRef(null)
const [suggestion, setSuggestion] = useState(null)
const [inputValue, setInputValue] = useState(null)
const [matchedDomain, setMatchedDomain] = useState(null)
@@ -161,15 +162,16 @@ function Input({ onChange, handleAddNewEmail }: InputProps) {
return (
-
-
- {suggestion || ''}
-
-
-
-
+
-
+
-
-
+
-
+
>
)}
{isRoleAndDepartmentVisible && (
<>
-
+
-
-
+
+
-
+
>
)}
>
diff --git a/services/web/frontend/js/features/settings/components/emails/downshift-input.tsx b/services/web/frontend/js/features/settings/components/emails/downshift-input.tsx
index cde10bb936..234fffae60 100644
--- a/services/web/frontend/js/features/settings/components/emails/downshift-input.tsx
+++ b/services/web/frontend/js/features/settings/components/emails/downshift-input.tsx
@@ -3,6 +3,7 @@ import { useCombobox } from 'downshift'
import classnames from 'classnames'
import { escapeRegExp } from 'lodash'
import { bsVersion } from '@/features/utils/bootstrap-5'
+import FormControlWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-control-wrapper'
type DownshiftInputProps = {
highlightMatches?: boolean
@@ -97,7 +98,7 @@ function Downshift({
>
{label}
- ) => {
setValue(event.target.value)
@@ -109,8 +110,6 @@ function Downshift({
},
ref: inputRef,
})}
- className="form-control"
- type="text"
placeholder={placeholder}
disabled={disabled}
/>
diff --git a/services/web/frontend/js/features/settings/components/emails/institution-and-role.tsx b/services/web/frontend/js/features/settings/components/emails/institution-and-role.tsx
index bd36dca917..f8e6d611a8 100644
--- a/services/web/frontend/js/features/settings/components/emails/institution-and-role.tsx
+++ b/services/web/frontend/js/features/settings/components/emails/institution-and-role.tsx
@@ -10,6 +10,7 @@ import defaultRoles from '../../data/roles'
import defaultDepartments from '../../data/departments'
import { University } from '../../../../../../types/university'
import ButtonWrapper from '@/features/ui/components/bootstrap-5/wrappers/button-wrapper'
+import FormGroupWrapper from '@/features/ui/components/bootstrap-5/wrappers/form-group-wrapper'
type InstitutionAndRoleProps = {
userEmailData: UserEmailData
@@ -120,7 +121,7 @@ function InstitutionAndRole({ userEmailData }: InstitutionAndRoleProps) {
) : (