mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 19:28:09 +00:00
improvement: add tooltip explaining unknown user actor in audit logs
This commit is contained in:
@@ -1,7 +1,8 @@
|
|||||||
import { faCaretDown, faCaretRight } from "@fortawesome/free-solid-svg-icons";
|
import { faCaretDown, faCaretRight } from "@fortawesome/free-solid-svg-icons";
|
||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
|
import { InfoIcon } from "lucide-react";
|
||||||
|
|
||||||
import { Td, Tr } from "@app/components/v2";
|
import { Td, Tooltip, Tr } from "@app/components/v2";
|
||||||
import { formatDateTime, Timezone } from "@app/helpers/datetime";
|
import { formatDateTime, Timezone } from "@app/helpers/datetime";
|
||||||
import { useToggle } from "@app/hooks";
|
import { useToggle } from "@app/hooks";
|
||||||
import { ActorType } from "@app/hooks/api/auditLogs/enums";
|
import { ActorType } from "@app/hooks/api/auditLogs/enums";
|
||||||
@@ -24,6 +25,15 @@ const Tag = ({ label, value }: TagProps) => {
|
|||||||
<div className="flex items-center space-x-1.5">
|
<div className="flex items-center space-x-1.5">
|
||||||
<div className="rounded-sm bg-mineshaft-600 p-0.5 pl-1 font-mono">{label}:</div>
|
<div className="rounded-sm bg-mineshaft-600 p-0.5 pl-1 font-mono">{label}:</div>
|
||||||
<div>{value}</div>
|
<div>{value}</div>
|
||||||
|
{value === "unknownUser" && (
|
||||||
|
<Tooltip
|
||||||
|
side="right"
|
||||||
|
className="max-w-sm"
|
||||||
|
content="This endpoint doesn't require authentication, so the requesting actor cannot be identified."
|
||||||
|
>
|
||||||
|
<InfoIcon size={14} className="text-mineshaft-300" />
|
||||||
|
</Tooltip>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user