mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-07-04 19:21:51 +00:00
fix(ui): unify alert modal footer buttons and modal footer spacing
Align the alert form modal footer with the launch scan and triage note modals: Cancel (outline) on the left, submit group on the right, all size lg. Standardize the vertical gap between the last field and the footer to 32px across the alert, launch scan, and triage modals.
This commit is contained in:
@@ -594,22 +594,31 @@ const AlertFormModalContent = ({
|
||||
{errors.root && (
|
||||
<div className="text-text-error-primary text-sm">{errors.root}</div>
|
||||
)}
|
||||
<div className="flex justify-end gap-2">
|
||||
<Button variant="outline" onClick={() => onOpenChange(false)}>
|
||||
{/* mt-4 lifts the gap-4 container spacing to 32px so the distance to
|
||||
the footer matches the launch scan and triage note modals. */}
|
||||
<div className="mt-4 flex w-full justify-between gap-4">
|
||||
<Button
|
||||
variant="outline"
|
||||
size="lg"
|
||||
onClick={() => onOpenChange(false)}
|
||||
>
|
||||
Cancel
|
||||
</Button>
|
||||
{editingAlert && (
|
||||
<Button
|
||||
variant="outline"
|
||||
onClick={handlePreview}
|
||||
disabled={previewLoading || saving}
|
||||
>
|
||||
{previewLoading ? "Running..." : "Test"}
|
||||
<div className="flex gap-4">
|
||||
{editingAlert && (
|
||||
<Button
|
||||
variant="outline"
|
||||
size="lg"
|
||||
onClick={handlePreview}
|
||||
disabled={previewLoading || saving}
|
||||
>
|
||||
{previewLoading ? "Running..." : "Test"}
|
||||
</Button>
|
||||
)}
|
||||
<Button size="lg" onClick={handleSubmit} disabled={saving}>
|
||||
{submitLabel}
|
||||
</Button>
|
||||
)}
|
||||
<Button onClick={handleSubmit} disabled={saving}>
|
||||
{submitLabel}
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Modal>
|
||||
|
||||
@@ -235,7 +235,9 @@ export function FindingNoteModal({
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="flex w-full justify-between gap-4">
|
||||
{/* mt-3 lifts the gap-5 form spacing to 32px so the distance to the
|
||||
footer matches the launch scan and alert modals. */}
|
||||
<div className="mt-3 flex w-full justify-between gap-4">
|
||||
<Button
|
||||
type="button"
|
||||
variant="outline"
|
||||
|
||||
Reference in New Issue
Block a user