Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

account and session detail sheet tweaks

x032205550b44403b41
diff --git a/frontend/src/pages/pam/PamAccountsPage/components/AccountDetailSheet.tsx b/frontend/src/pages/pam/PamAccountsPage/components/AccountDetailSheet.tsx
index 8c11a8ed6b..d57ecd4e35 100644
--- a/frontend/src/pages/pam/PamAccountsPage/components/AccountDetailSheet.tsx
+++ b/frontend/src/pages/pam/PamAccountsPage/components/AccountDetailSheet.tsx
@@ -656,9 +656,9 @@ export const AccountDetailSheet = ({ isOpen, accountId, onOpenChange }: Props) =
: [];
const folderSubtitle = account?.folderName ? (
- <span className="flex items-center gap-1.5">
- <FolderOpen className="size-3.5" />
- {account.folderName}
+ <span className="flex min-w-0 items-center gap-1.5">
+ <FolderOpen className="size-3.5 shrink-0" />
+ <span className="truncate">{account.folderName}</span>
</span>
) : undefined;
diff --git a/frontend/src/pages/pam/PamSessionsPage/components/SessionDetailSheet.tsx b/frontend/src/pages/pam/PamSessionsPage/components/SessionDetailSheet.tsx
index 0d76577e32..d03bc77b12 100644
--- a/frontend/src/pages/pam/PamSessionsPage/components/SessionDetailSheet.tsx
+++ b/frontend/src/pages/pam/PamSessionsPage/components/SessionDetailSheet.tsx
@@ -183,6 +183,9 @@ export const SessionDetailSheet = ({ sessionId, isOpen, onOpenChange, onTerminat
const statusConfig = STATUS_BADGE[session.status];
const typeName = accountTypeMap[session.accountType]?.name ?? session.accountType;
+ const emptyValue = <span className="text-muted">—</span>;
+ const duration = formatDuration(session);
+
const metadata: { label: string; value: ReactNode }[] = [
{
label: "Status",
@@ -194,16 +197,18 @@ export const SessionDetailSheet = ({ sessionId, isOpen, onOpenChange, onTerminat
)
},
{ label: "Email", value: session.actorEmail },
- { label: "Folder", value: session.folderName || "-" },
+ { label: "Folder", value: session.folderName || emptyValue },
{
label: "Started",
- value: session.startedAt ? format(new Date(session.startedAt), "MMM d, yyyy h:mm a") : "-"
+ value: session.startedAt
+ ? format(new Date(session.startedAt), "MMM d, yyyy h:mm a")
+ : emptyValue
},
{
label: "Ended",
value: session.endedAt ? format(new Date(session.endedAt), "MMM d, yyyy h:mm a") : "Ongoing"
},
- { label: "Duration", value: formatDuration(session) },
+ { label: "Duration", value: duration === "—" ? emptyValue : duration },
{ label: "IP Address", value: session.actorIp },
...(session.reason ? [{ label: "Reason", value: session.reason }] : [])
];