"use client"; import type { ReactNode } from "react"; import { CreateFlowStepShell, type CreateFlowContentTopBelowMd, } from "./CreateFlowStepShell"; import { CREATE_FLOW_MD_UP_COLUMN_MAX_CLASS } from "./createFlowLayoutTokens"; export type CreateFlowSelectShellLgVerticalAlign = "center" | "start"; interface CreateFlowTwoColumnSelectShellProps { header: ReactNode; children: ReactNode; /** * Top padding below create-flow chrome. Select steps use `space-1400`; right-rail uses `space-800` * (Figma Flow — Right Rail). */ contentTopBelowMd?: CreateFlowContentTopBelowMd; /** * At `lg+`, layout variant: `"center"` = vertically centered pair (community size/structure). * `"start"` = top-weighted layout with a scrollable right column (core values, right-rail): uses `items-stretch` * so the right column gets a bounded height; `items-start` would grow with content and break scroll. */ lgVerticalAlign?: CreateFlowSelectShellLgVerticalAlign; } /** * Two-column layout for create-flow select steps (community size/structure, core values) and * {@link RightRailScreen} (decision approaches). Below `lg` (1024px), one column + main scrolls. * At `lg+`, mirrors {@link CompletedScreen}: static header column + scrollable controls column * (`min-h-0` + `overflow-y-auto` height chain; see completed page right rail). */ export function CreateFlowTwoColumnSelectShell({ header, children, contentTopBelowMd = "space-1400", lgVerticalAlign = "center", }: CreateFlowTwoColumnSelectShellProps) { /** `stretch` is required for `min-h-0` + `overflow-y-auto` on the right column. */ const rowLgCrossAlignClass = lgVerticalAlign === "start" ? "lg:items-stretch" : "lg:items-center"; const leftLgMainJustifyClass = lgVerticalAlign === "start" ? "lg:justify-start" : "lg:justify-center"; return (
{header}
{children}
); }