keycloak-scim/src/user-federation/LdapSettingsAdvanced.tsx
Sarah Rambacher 6b3990e1b9
540 user fed settings (#198)
* all fields roughed in working on tab

* reduce to just the settings without page

* remove unused imports

* fix some comments

* correct some typos and capitalization

* remove ldap translation
2020-10-30 16:15:37 -04:00

81 lines
2.3 KiB
TypeScript

import { Form, FormGroup, Switch } from "@patternfly/react-core";
import { useTranslation } from "react-i18next";
import React from "react";
import { HelpItem } from "../components/help-enabler/HelpItem";
export const LdapSettingsAdvanced = () => {
const { t } = useTranslation("user-federation");
const helpText = useTranslation("user-federation-help").t;
return (
<>
<Form isHorizontal>
<FormGroup
label={t("enableLdapv3Password")}
labelIcon={
<HelpItem
helpText={helpText("enableLdapv3PasswordHelp")}
forLabel={t("enableLdapv3Password")}
forID="kc-enable-ldapv3-password"
/>
}
fieldId="kc-enable-ldapv3-password"
hasNoPaddingTop
>
<Switch
id={"kc-enable-ldapv3-password"}
isChecked={false}
isDisabled={false}
onChange={() => undefined as any}
label={t("common:on")}
labelOff={t("common:off")}
/>
</FormGroup>
<FormGroup
label={t("validatePasswordPolicy")}
labelIcon={
<HelpItem
helpText={helpText("validatePasswordPolicyHelp")}
forLabel={t("validatePasswordPolicy")}
forID="kc-validate-password-policy"
/>
}
fieldId="kc-validate-password-policy"
hasNoPaddingTop
>
<Switch
id={"kc-validate-password-policy"}
isChecked={false}
isDisabled={false}
onChange={() => undefined as any}
label={t("common:on")}
labelOff={t("common:off")}
/>
</FormGroup>
<FormGroup
label={t("trustEmail")}
labelIcon={
<HelpItem
helpText={helpText("trustEmailHelp")}
forLabel={t("trustEmail")}
forID="kc-trust-email"
/>
}
fieldId="kc-trust-email"
hasNoPaddingTop
>
<Switch
id={"kc-trust-email"}
isChecked={false}
isDisabled={false}
onChange={() => undefined as any}
label={t("common:on")}
labelOff={t("common:off")}
/>
</FormGroup>
</Form>
</>
);
};