mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #8199 from overleaf/ii-settings-ts-fixes
[web] Fix TS errors in settings area GitOrigin-RevId: 48f3695570bd794b4865bd45a29aa6fc9bf57502
This commit is contained in:
parent
5bc28ffa8c
commit
20d5291308
3 changed files with 14 additions and 7 deletions
|
@ -120,7 +120,8 @@ function AddEmail() {
|
|||
/>
|
||||
</Cell>
|
||||
</Col>
|
||||
{ssoAvailableForDomain(newEmailMatchedDomain) ? (
|
||||
{newEmailMatchedDomain &&
|
||||
ssoAvailableForDomain(newEmailMatchedDomain) ? (
|
||||
<Col md={8}>
|
||||
<Cell>
|
||||
<SsoLinkingInfo
|
||||
|
|
|
@ -125,11 +125,17 @@ function Input({ onChange, handleAddNewEmail }: InputProps) {
|
|||
|
||||
if (suggestion) {
|
||||
setInputValueAndResetSuggestion()
|
||||
} else {
|
||||
const match = matchLocalAndDomain(inputValue)
|
||||
if (match.local && match.domain) {
|
||||
handleAddNewEmail()
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
if (!inputValue) {
|
||||
return
|
||||
}
|
||||
|
||||
const match = matchLocalAndDomain(inputValue)
|
||||
if (match.local && match.domain) {
|
||||
handleAddNewEmail()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ function Email({ userEmailData }: EmailProps) {
|
|||
const { t } = useTranslation()
|
||||
|
||||
const ssoAvailable = ssoAvailableForInstitution(
|
||||
userEmailData.affiliation?.institution
|
||||
userEmailData.affiliation?.institution || null
|
||||
)
|
||||
|
||||
return (
|
||||
|
|
Loading…
Reference in a new issue