feat: added support for recursive file creation

This commit is contained in:
Akhil Mohan
2023-10-11 17:19:34 +05:30
parent 5e4d4f56e3
commit 4f5946b252
13 changed files with 138 additions and 66 deletions
@@ -124,13 +124,15 @@ export const SecretListView = ({
comment,
tags,
skipMultilineEncoding,
newKey
newKey,
secretId
}: Partial<{
value: string;
comment: string;
tags: string[];
skipMultilineEncoding: boolean;
newKey: string;
secretId: string;
}> = {}
) => {
if (operation === "delete") {
@@ -139,7 +141,8 @@ export const SecretListView = ({
workspaceId,
secretPath,
secretName: key,
type
type,
secretId
});
return;
}
@@ -249,9 +252,9 @@ export const SecretListView = ({
);
const handleSecretDelete = useCallback(async () => {
const { key } = popUp.deleteSecret?.data as DecryptedSecret;
const { key, _id: secretId } = popUp.deleteSecret?.data as DecryptedSecret;
try {
await handleSecretOperation("delete", "shared", key);
await handleSecretOperation("delete", "shared", key, { secretId });
queryClient.invalidateQueries(
secretKeys.getProjectSecret({ workspaceId, environment, secretPath })
);