CartButton molecule + progress bar on all wizard layouts

- New CartButton molecule: outlined pill trigger with receipt icon,
  "Your Plan" label + formatted total in brand colour. Click opens
  DialogShell with items grouped by section via LineItem, total row,
  empty state. Mobile collapses to icon + price.
- WizardLayout: remove STEPPER_VARIANTS whitelist — stepper bar now
  renders on any layout variant when progressStepper/runningTotal props
  are provided (StepperBar already returns null when both empty)
- Thread progressStepper + runningTotal props to DateTimeStep, VenueStep,
  SummaryStep, PaymentStep (joins 8 pages that already had them)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-31 15:19:20 +11:00
parent 7a06f89e84
commit e73ccf36dd
8 changed files with 302 additions and 6 deletions

View File

@@ -70,6 +70,10 @@ export interface DateTimeStepProps {
showScheduling?: boolean;
/** Navigation bar — passed through to WizardLayout */
navigation?: React.ReactNode;
/** Progress stepper */
progressStepper?: React.ReactNode;
/** Running total widget (e.g. CartButton) */
runningTotal?: React.ReactNode;
/** Hide the help bar */
hideHelpBar?: boolean;
/** MUI sx prop for the root */
@@ -115,6 +119,8 @@ export const DateTimeStep: React.FC<DateTimeStepProps> = ({
showNameFields = true,
showScheduling = true,
navigation,
progressStepper,
runningTotal,
hideHelpBar,
sx,
}) => {
@@ -154,6 +160,8 @@ export const DateTimeStep: React.FC<DateTimeStepProps> = ({
<WizardLayout
variant="centered-form"
navigation={navigation}
progressStepper={progressStepper}
runningTotal={runningTotal}
showBackLink={!!onBack}
backLabel="Back"
onBack={onBack}

View File

@@ -70,6 +70,8 @@ export interface PaymentStepProps {
navigation?: React.ReactNode;
/** Progress stepper */
progressStepper?: React.ReactNode;
/** Running total widget (e.g. CartButton) */
runningTotal?: React.ReactNode;
/** Hide the help bar */
hideHelpBar?: boolean;
/** MUI sx prop */
@@ -108,6 +110,7 @@ export const PaymentStep: React.FC<PaymentStepProps> = ({
cardFormSlot,
navigation,
progressStepper,
runningTotal,
hideHelpBar,
sx,
}) => {
@@ -118,6 +121,7 @@ export const PaymentStep: React.FC<PaymentStepProps> = ({
variant="centered-form"
navigation={navigation}
progressStepper={progressStepper}
runningTotal={runningTotal}
showBackLink={!!onBack}
backLabel="Back"
onBack={onBack}

View File

@@ -101,6 +101,8 @@ export interface SummaryStepProps {
navigation?: React.ReactNode;
/** Progress stepper */
progressStepper?: React.ReactNode;
/** Running total widget (e.g. CartButton) */
runningTotal?: React.ReactNode;
/** Hide the help bar */
hideHelpBar?: boolean;
/** MUI sx prop */
@@ -287,6 +289,7 @@ export const SummaryStep: React.FC<SummaryStepProps> = ({
isPrePlanning = false,
navigation,
progressStepper,
runningTotal,
hideHelpBar,
sx,
}) => {
@@ -297,6 +300,7 @@ export const SummaryStep: React.FC<SummaryStepProps> = ({
variant="centered-form"
navigation={navigation}
progressStepper={progressStepper}
runningTotal={runningTotal}
showBackLink={!!onBack}
backLabel="Back"
onBack={onBack}

View File

@@ -52,6 +52,10 @@ export interface VenueStepProps {
mapPanel?: React.ReactNode;
/** Navigation bar — passed through to WizardLayout */
navigation?: React.ReactNode;
/** Progress stepper */
progressStepper?: React.ReactNode;
/** Running total widget (e.g. CartButton) */
runningTotal?: React.ReactNode;
/** MUI sx prop for the root */
sx?: SxProps<Theme>;
}
@@ -90,6 +94,8 @@ export const VenueStep: React.FC<VenueStepProps> = ({
isPrePlanning = false,
mapPanel,
navigation,
progressStepper,
runningTotal,
sx,
}) => {
const subheading = isPrePlanning
@@ -100,6 +106,8 @@ export const VenueStep: React.FC<VenueStepProps> = ({
<WizardLayout
variant="list-map"
navigation={navigation}
progressStepper={progressStepper}
runningTotal={runningTotal}
showBackLink
backLabel="Back"
onBack={onBack}