Skip to content

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

fix(pam): move transaction status and controls to the right of the query toolbar

bernie-gf0ed2d7529ec
diff --git a/frontend/src/pages/pam/PamDataExplorerPage/components/QueryToolbar.tsx b/frontend/src/pages/pam/PamDataExplorerPage/components/QueryToolbar.tsx
index 34151f6e7e..58c8f29729 100644
--- a/frontend/src/pages/pam/PamDataExplorerPage/components/QueryToolbar.tsx
+++ b/frontend/src/pages/pam/PamDataExplorerPage/components/QueryToolbar.tsx
@@ -24,21 +24,23 @@ export function QueryToolbar({
onCancel
}: Props) {
return (
- <div className="flex shrink-0 items-center gap-3 border-b border-mineshaft-600 bg-bunker-800 px-3 py-1.5">
- {isRunning ? (
- <Button size="xs" variant="outline" onClick={onCancel} className="gap-1.5">
- <SquareIcon className="size-3 text-red-400" />
- Cancel
- </Button>
- ) : (
- <Button size="xs" onClick={() => onRun()} className="gap-1.5">
- <PlayIcon className="size-3" />
- {hasSelection ? "Run Selection" : "Run"}
- <span className="opacity-60">{isMac ? "⌘" : "Ctrl"} ↵</span>
- </Button>
- )}
+ <div className="flex shrink-0 items-center justify-between border-b border-mineshaft-600 bg-bunker-800 px-3 py-1.5">
+ <div className="flex items-center gap-3">
+ {isRunning ? (
+ <Button size="xs" variant="outline" onClick={onCancel} className="gap-1.5">
+ <SquareIcon className="size-3 text-red-400" />
+ Cancel
+ </Button>
+ ) : (
+ <Button size="xs" onClick={() => onRun()} className="gap-1.5">
+ <PlayIcon className="size-3" />
+ {hasSelection ? "Run Selection" : "Run"}
+ <span className="opacity-60">{isMac ? "⌘" : "Ctrl"} ↵</span>
+ </Button>
+ )}
+ </div>
{isInTransaction && (
- <>
+ <div className="flex items-center gap-3">
<span className="rounded bg-yellow-500/15 px-2 py-0.5 text-xs font-medium text-yellow-400">
Transaction open
</span>
@@ -62,7 +64,7 @@ export function QueryToolbar({
<RotateCcwIcon className="size-3" />
Rollback
</Button>
- </>
+ </div>
)}
</div>
);