import React from "react"; import { useTranslation } from "react-i18next"; import { FormGroup, PageSection, Switch } from "@patternfly/react-core"; import { FormAccess } from "../components/form-access/FormAccess"; import { HelpItem } from "../components/help-enabler/HelpItem"; import { FormPanel } from "../components/scroll-form/FormPanel"; import type RealmRepresentation from "@keycloak/keycloak-admin-client/lib/defs/realmRepresentation"; type RealmSettingsLoginTabProps = { save: (realm: RealmRepresentation) => void; realm: RealmRepresentation; }; export const RealmSettingsLoginTab = ({ save, realm, }: RealmSettingsLoginTabProps) => { const { t } = useTranslation("realm-settings"); return ( } hasNoPaddingTop > { save({ ...realm, registrationAllowed: value }); }} /> } hasNoPaddingTop > { save({ ...realm, resetPasswordAllowed: value }); }} /> } hasNoPaddingTop > { save({ ...realm, rememberMe: value }); }} /> } hasNoPaddingTop > { save({ ...realm, registrationEmailAsUsername: value }); }} /> } hasNoPaddingTop > { save({ ...realm, loginWithEmailAllowed: value }); }} /> } hasNoPaddingTop > { save({ ...realm, duplicateEmailsAllowed: value }); }} isDisabled={ realm?.loginWithEmailAllowed || realm?.registrationEmailAsUsername } /> } hasNoPaddingTop > { save({ ...realm, verifyEmail: value }); }} /> ); };