re added floating action (#500)
This commit is contained in:
parent
e75deb3305
commit
a27045c617
2 changed files with 10 additions and 5 deletions
|
@ -240,7 +240,12 @@ export const ClientSettings = ({ save, reset }: ClientSettingsProps) => {
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
<SaveReset name="settings" save={save} reset={reset} />
|
<SaveReset
|
||||||
|
className="keycloak__form_actions"
|
||||||
|
name="settings"
|
||||||
|
save={save}
|
||||||
|
reset={reset}
|
||||||
|
/>
|
||||||
</FormAccess>
|
</FormAccess>
|
||||||
</ScrollForm>
|
</ScrollForm>
|
||||||
</>
|
</>
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { ActionGroup, Button } from "@patternfly/react-core";
|
import { ActionGroup, ActionGroupProps, Button } from "@patternfly/react-core";
|
||||||
|
|
||||||
type SaveResetProps = {
|
type SaveResetProps = ActionGroupProps & {
|
||||||
name: string;
|
name: string;
|
||||||
save: () => void;
|
save: () => void;
|
||||||
reset: () => void;
|
reset: () => void;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const SaveReset = ({ name, save, reset }: SaveResetProps) => {
|
export const SaveReset = ({ name, save, reset, ...rest }: SaveResetProps) => {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
return (
|
return (
|
||||||
<ActionGroup>
|
<ActionGroup {...rest}>
|
||||||
<Button data-testid={name + "Save"} variant="tertiary" onClick={save}>
|
<Button data-testid={name + "Save"} variant="tertiary" onClick={save}>
|
||||||
{t("common:save")}
|
{t("common:save")}
|
||||||
</Button>
|
</Button>
|
||||||
|
|
Loading…
Reference in a new issue