-
-
- );
-};
diff --git a/frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/shared/SshAccountFields.tsx b/frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/SshAccountForm.tsx
similarity index 57%
rename from frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/shared/SshAccountFields.tsx
rename to frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/SshAccountForm.tsx
index 091120c4e..fc8ea7acb 100644
--- a/frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/shared/SshAccountFields.tsx
+++ b/frontend/src/pages/pam/PamAccountsPage/components/PamAccountForm/SshAccountForm.tsx
@@ -1,11 +1,63 @@
import { useEffect, useState } from "react";
-import { Controller, useFormContext, useWatch } from "react-hook-form";
+import { Controller, FormProvider, useForm, useFormContext, useWatch } from "react-hook-form";
+import { zodResolver } from "@hookform/resolvers/zod";
+import { z } from "zod";
-import { FormControl, Input, Select, SelectItem, TextArea } from "@app/components/v2";
+import {
+ Button,
+ FormControl,
+ Input,
+ ModalClose,
+ Select,
+ SelectItem,
+ TextArea
+} from "@app/components/v2";
+import { PamResourceType, TSSHAccount } from "@app/hooks/api/pam";
import { UNCHANGED_PASSWORD_SENTINEL } from "@app/hooks/api/pam/constants";
import { SSHAuthMethod } from "@app/hooks/api/pam/types/ssh-resource";
-export const SshAccountFields = ({ isUpdate }: { isUpdate: boolean }) => {
+import { GenericAccountFields, genericAccountFieldsSchema } from "./GenericAccountFields";
+
+type Props = {
+ account?: TSSHAccount;
+ resourceId?: string;
+ resourceType?: PamResourceType;
+ onSubmit: (formData: FormData) => Promise