import React, { useState, FormEvent } from "react"; import { useTranslation } from "react-i18next"; import { FormGroup, TextInput, Form, Dropdown, DropdownToggle, DropdownItem, Switch, TextArea, PageSection, } from "@patternfly/react-core"; import { useForm } from "react-hook-form"; import { ScrollForm } from "../components/scroll-form/ScrollForm"; import { ClientDescription } from "./ClientDescription"; import { ClientRepresentation } from "./models/client-model"; import { CapabilityConfig } from "./add/CapabilityConfig"; type ClientSettingsProps = { client: ClientRepresentation; }; export const ClientSettings = ({ client: clientInit }: ClientSettingsProps) => { const { t } = useTranslation("clients"); const [client, setClient] = useState({ ...clientInit }); const form = useForm(); const onChange = ( value: string | boolean, event: FormEvent ) => { const target = event.target; const name = (target as HTMLInputElement).name; setClient({ ...client, [name]: value, }); }; return (
{}}> {t("loginTheme")} } dropdownItems={[ Link, , ]} />