@@ -206,8 +209,8 @@ const HTTPCertificateModal = EasyModal.create(({ visible, remove }: InnerModalPr
)}
-
-
+
+ >
);
});
diff --git a/frontend/src/modals/PermissionsModal.tsx b/frontend/src/modals/PermissionsModal.tsx
index d363de9ed..3c808abf0 100644
--- a/frontend/src/modals/PermissionsModal.tsx
+++ b/frontend/src/modals/PermissionsModal.tsx
@@ -1,7 +1,8 @@
import { useQueryClient } from "@tanstack/react-query";
import cn from "classnames";
import EasyModal, { type InnerModalProps } from "ez-modal-react";
-import { Field, Form, Formik } from "formik";
+import { Field, Form } from "formik";
+import { FormModal } from "src/components/Form";
import { type ReactNode, useState } from "react";
import { Alert } from "react-bootstrap";
import Modal from "react-bootstrap/Modal";
@@ -133,7 +134,7 @@ const PermissionsModal = EasyModal.create(({ id, visible, remove }: Props) => {
const isAdmin = data?.roles.indexOf("admin") !== -1;
return (
-
+ <>
{!isLoading && error && (
{error?.message || "Unknown error"}
@@ -141,7 +142,9 @@ const PermissionsModal = EasyModal.create(({ id, visible, remove }: Props) => {
)}
{isLoading && }
{!isLoading && data && (
- {
}
onSubmit={onSubmit}
>
- {() => (
+ {({ onHide }) => (
)}
-
+
)}
-
+ >
);
});
diff --git a/frontend/src/modals/ProxyHostModal.tsx b/frontend/src/modals/ProxyHostModal.tsx
index 3227be51b..65f74a9fe 100644
--- a/frontend/src/modals/ProxyHostModal.tsx
+++ b/frontend/src/modals/ProxyHostModal.tsx
@@ -1,7 +1,8 @@
import { IconSettings } from "@tabler/icons-react";
import cn from "classnames";
import EasyModal, { type InnerModalProps } from "ez-modal-react";
-import { Field, Form, Formik } from "formik";
+import { Field, Form } from "formik";
+import { FormModal } from "src/components/Form";
import { type ReactNode, useState } from "react";
import { Alert } from "react-bootstrap";
import Modal from "react-bootstrap/Modal";
@@ -60,7 +61,7 @@ const ProxyHostModal = EasyModal.create(({ id, visible, remove }: Props) => {
};
return (
-
+ <>
{!isLoading && (error || userError) && (
{error?.message || userError?.message || "Unknown error"}
@@ -68,7 +69,9 @@ const ProxyHostModal = EasyModal.create(({ id, visible, remove }: Props) => {
)}
{isLoading || (userIsLoading && )}
{!isLoading && !userIsLoading && data && currentUser && (
- {
}
onSubmit={onSubmit}
>
- {() => (
+ {({ onHide }) => (