Address PR comments

This commit is contained in:
Carlos Monastyrski
2025-08-13 20:13:34 -07:00
parent b479406ba0
commit 91a76f50ca
7 changed files with 138 additions and 89 deletions
@@ -43,12 +43,15 @@ export const useUpdateDynamicSecret = () => {
);
return data.dynamicSecret;
},
onSuccess: (_, { path, environmentSlug, projectSlug }) => {
onSuccess: (_, { path, environmentSlug, projectSlug, name }) => {
// TODO: optimize but currently don't pass projectId
queryClient.invalidateQueries({ queryKey: dashboardKeys.all() });
queryClient.invalidateQueries({
queryKey: dynamicSecretKeys.list({ path, projectSlug, environmentSlug })
});
queryClient.invalidateQueries({
queryKey: dynamicSecretKeys.details({ path, projectSlug, environmentSlug, name })
});
}
});
};
@@ -363,13 +363,15 @@ export type TDynamicSecretProvider =
projectId: string;
clusterId: string;
roles: string[];
buckets: string | Array<{
name: string;
scopes?: Array<{
name: string;
collections?: string[];
}>;
}>;
buckets:
| string
| Array<{
name: string;
scopes?: Array<{
name: string;
collections?: string[];
}>;
}>;
passwordRequirements?: {
length: number;
required: {