feat(frontend): 2-column layout for EngagementFormPage in edit mode
In edit mode with canEditEngagements, wraps [form | C2ConfigCard] in a lg:grid-cols-2 responsive grid with items-start alignment. Stacks to single column on screens narrower than lg. In create mode, retains the existing max-w-2xl single-column layout. No logic changes. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -124,7 +124,7 @@ export function EngagementFormPage(): JSX.Element {
|
||||
const submitting = createMutation.isPending || patchMutation.isPending;
|
||||
|
||||
return (
|
||||
<div className="flex flex-col gap-xl max-w-2xl">
|
||||
<div className="flex flex-col gap-xl">
|
||||
<header>
|
||||
<h1 className="text-[32px] font-medium leading-none">
|
||||
{editing ? 'Edit engagement' : 'New engagement'}
|
||||
@@ -136,6 +136,13 @@ export function EngagementFormPage(): JSX.Element {
|
||||
</p>
|
||||
</header>
|
||||
|
||||
<div
|
||||
className={
|
||||
editing && canEditEngagements
|
||||
? 'grid grid-cols-1 lg:grid-cols-2 gap-xl items-start'
|
||||
: 'max-w-2xl'
|
||||
}
|
||||
>
|
||||
<form onSubmit={onSubmit} noValidate className="card-product flex flex-col gap-md">
|
||||
<FormField label="Name" htmlFor="eng-name" required error={errors.name}>
|
||||
<TextInput
|
||||
@@ -222,5 +229,6 @@ export function EngagementFormPage(): JSX.Element {
|
||||
<C2ConfigCard engagementId={numericId} />
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user