mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-20 21:18:18 +00:00
Merge branch 'main' of https://github.com/Infisical/infisical into feat/laravel-forge-app-conn-and-secret-sync
This commit is contained in:
+1
@@ -260,6 +260,7 @@ export const CommitDetailsTab = ({
|
||||
Commit History
|
||||
</Button>
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title={`${parsedCommitDetails.changes?.message}` || "No message"}
|
||||
description={
|
||||
<>
|
||||
|
||||
+1
@@ -307,6 +307,7 @@ export const RollbackPreviewTab = (): JSX.Element => {
|
||||
<div className="h-full w-full">
|
||||
<div>
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title={`Restore folder at commit ${selectedCommitId.substring(0, 8)}`}
|
||||
description={`Will return all changes in this folder to how they appeared at the point of commit ${selectedCommitId.substring(0, 8)}. Any modifications made after this commit will be undone.`}
|
||||
/>
|
||||
|
||||
@@ -49,6 +49,7 @@ export const CommitsPage = () => {
|
||||
<div className="mx-auto flex h-full w-full max-w-7xl justify-center bg-bunker-800 py-4 text-white">
|
||||
<div className="w-full max-w-[75vw]">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Commits"
|
||||
description="Track, inspect, and restore your secrets and folders with confidence. View the complete history of changes made to your environment, examine specific modifications at each commit point, and preview the exact impact before rolling back to previous states."
|
||||
/>
|
||||
|
||||
+1
@@ -94,6 +94,7 @@ export const IntegrationDetailsByIDPage = () => {
|
||||
{integration ? (
|
||||
<div className="mx-auto mb-6 w-full max-w-7xl">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title={`${integrationSlugNameMapping[integration.integration]} Integration`}
|
||||
>
|
||||
<DropdownMenu>
|
||||
|
||||
@@ -48,6 +48,7 @@ export const IntegrationsListPage = () => {
|
||||
<div className="relative container mx-auto max-w-7xl pb-12 text-white">
|
||||
<div className="mb-8">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Integrations"
|
||||
description="Manage integrations with third-party services."
|
||||
/>
|
||||
|
||||
@@ -914,6 +914,7 @@ export const OverviewPage = () => {
|
||||
<div className="relative mx-auto max-w-7xl text-mineshaft-50 dark:scheme-dark">
|
||||
<div className="flex w-full items-baseline justify-between">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Secrets Overview"
|
||||
description={
|
||||
<p className="text-md text-bunker-300">
|
||||
|
||||
+18
-15
@@ -82,6 +82,7 @@ type Props = {
|
||||
isImported: boolean;
|
||||
}[];
|
||||
}[];
|
||||
isSecretPresent?: boolean;
|
||||
};
|
||||
|
||||
export const SecretEditRow = ({
|
||||
@@ -101,7 +102,8 @@ export const SecretEditRow = ({
|
||||
isRotatedSecret,
|
||||
importedBy,
|
||||
importedSecret,
|
||||
isEmpty
|
||||
isEmpty,
|
||||
isSecretPresent
|
||||
}: Props) => {
|
||||
const { handlePopUpOpen, handlePopUpToggle, handlePopUpClose, popUp } = usePopUp([
|
||||
"editSecret"
|
||||
@@ -113,20 +115,21 @@ export const SecretEditRow = ({
|
||||
|
||||
const [isFieldFocused, setIsFieldFocused] = useToggle();
|
||||
|
||||
const fetchSecretValueParams = importedSecret
|
||||
? {
|
||||
environment: importedSecret.environment,
|
||||
secretPath: importedSecret.secretPath,
|
||||
secretKey: importedSecret.secret?.key ?? "",
|
||||
projectId: currentProject.id
|
||||
}
|
||||
: {
|
||||
environment,
|
||||
secretPath,
|
||||
secretKey: secretName,
|
||||
projectId: currentProject.id,
|
||||
isOverride
|
||||
};
|
||||
const fetchSecretValueParams =
|
||||
importedSecret && !isSecretPresent
|
||||
? {
|
||||
environment: importedSecret.environment,
|
||||
secretPath: importedSecret.secretPath,
|
||||
secretKey: importedSecret.secret?.key ?? "",
|
||||
projectId: currentProject.id
|
||||
}
|
||||
: {
|
||||
environment,
|
||||
secretPath,
|
||||
secretKey: secretName,
|
||||
projectId: currentProject.id,
|
||||
isOverride
|
||||
};
|
||||
|
||||
// scott: only fetch value if secret exists, has non-empty value and user has permission
|
||||
const canFetchValue = Boolean(importedSecret ?? secretId) && !isEmpty && !secretValueHidden;
|
||||
|
||||
+1
@@ -284,6 +284,7 @@ export const SecretOverviewTableRow = ({
|
||||
environment={slug}
|
||||
isRotatedSecret={secret?.isRotatedSecret}
|
||||
importedBy={importedBy}
|
||||
isSecretPresent={Boolean(secret)}
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -40,6 +40,7 @@ export const SecretApprovalsPage = () => {
|
||||
</Helmet>
|
||||
<div className="container mx-auto h-full w-full max-w-7xl bg-bunker-800 text-white">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Approval Workflows"
|
||||
description="Create approval policies for any modifications to secrets in sensitive environments and folders."
|
||||
/>
|
||||
|
||||
@@ -762,6 +762,7 @@ const Page = () => {
|
||||
return (
|
||||
<div className="container mx-auto flex max-w-7xl flex-col text-mineshaft-50 dark:scheme-dark">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Secrets Management"
|
||||
description={
|
||||
<p className="text-md text-bunker-300">
|
||||
|
||||
+3
-3
@@ -79,7 +79,7 @@ type Props = {
|
||||
isSelected?: boolean;
|
||||
onToggleSecretSelect: (secret: SecretV3RawSanitized) => void;
|
||||
tags: WsTag[];
|
||||
onCreateTag: () => void;
|
||||
onCreateTag: (secret?: SecretV3RawSanitized) => void;
|
||||
environment: string;
|
||||
secretPath: string;
|
||||
onShareSecret: (sec: SecretV3RawSanitized) => void;
|
||||
@@ -731,7 +731,7 @@ export const SecretItem = memo(
|
||||
className="h-3 w-3"
|
||||
/>
|
||||
}
|
||||
onClick={onCreateTag}
|
||||
onClick={() => onCreateTag(secret)}
|
||||
>
|
||||
Create a tag
|
||||
</Button>
|
||||
@@ -924,7 +924,7 @@ export const SecretItem = memo(
|
||||
className="h-3 w-3"
|
||||
/>
|
||||
}
|
||||
onClick={onCreateTag}
|
||||
onClick={() => onCreateTag(secret)}
|
||||
>
|
||||
Create a tag
|
||||
</Button>
|
||||
|
||||
+25
-1
@@ -465,6 +465,22 @@ export const SecretListView = ({
|
||||
[environment, secretPath, isProtectedBranch, isBatchMode, projectId, addPendingChange]
|
||||
);
|
||||
|
||||
// Function to append newly created tag to the current secret
|
||||
const append = useCallback(
|
||||
(newTag: WsTag) => {
|
||||
const currentSecret = popUp.createTag.data as SecretV3RawSanitized;
|
||||
if (!currentSecret) return;
|
||||
|
||||
const updatedTags = [...(currentSecret.tags || []), { id: newTag.id, slug: newTag.slug }];
|
||||
|
||||
handleSaveSecret(currentSecret, {
|
||||
...currentSecret,
|
||||
tags: updatedTags
|
||||
});
|
||||
},
|
||||
[popUp.createTag.data, handleSaveSecret]
|
||||
);
|
||||
|
||||
const handleSecretDelete = useCallback(async () => {
|
||||
const {
|
||||
key,
|
||||
@@ -552,7 +568,13 @@ export const SecretListView = ({
|
||||
]);
|
||||
|
||||
// for optimization on minimise re-rendering of secret items
|
||||
const onCreateTag = useCallback(() => handlePopUpOpen("createTag"), []);
|
||||
const onCreateTag = useCallback((secret?: SecretV3RawSanitized) => {
|
||||
if (secret) {
|
||||
handlePopUpOpen("createTag", secret);
|
||||
} else {
|
||||
handlePopUpOpen("createTag");
|
||||
}
|
||||
}, []);
|
||||
const onDeleteSecret = useCallback(
|
||||
(sec: SecretV3RawSanitized) => handlePopUpOpen("deleteSecret", sec),
|
||||
[]
|
||||
@@ -640,6 +662,8 @@ export const SecretListView = ({
|
||||
<CreateTagModal
|
||||
isOpen={popUp.createTag.isOpen}
|
||||
onToggle={(isOpen) => handlePopUpToggle("createTag", isOpen)}
|
||||
append={append}
|
||||
currentSecret={popUp.createTag.data}
|
||||
/>
|
||||
<AddShareSecretModal popUp={popUp} handlePopUpToggle={handlePopUpToggle} />
|
||||
</>
|
||||
|
||||
@@ -147,6 +147,7 @@ const Page = () => {
|
||||
return (
|
||||
<div className="container mx-auto w-full max-w-7xl bg-bunker-800 text-white">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Secret Rotation"
|
||||
description="Stop manually rotating secrets and automate credential rotation."
|
||||
>
|
||||
|
||||
@@ -42,6 +42,7 @@ export const SettingsPage = () => {
|
||||
</Helmet>
|
||||
<div className="w-full max-w-7xl">
|
||||
<PageHeader
|
||||
scope="project"
|
||||
title="Settings"
|
||||
description="Configure your secret manager's encryption, environments, webhooks and other configurations."
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user