Skip to content

MagicStarterDialogShell: bottom overflow when body has many items #21

@anilcancakir

Description

@anilcancakir

Bug

MagicStarterDialogShell overflows at the bottom when the body content exceeds the visible area. Flutter reports "BOTTOM OVERFLOWED BY 16 PIXELS".

Reproduction

Use MagicStarterDialogShell with a body containing 7+ items (e.g. a list of agent role cards with descriptions). The modal clips at the bottom instead of scrolling.

Root Cause Analysis

In lib/src/ui/widgets/magic_starter_dialog_shell.dart lines 65-109:

WDiv(
  className: '${theme.containerClassName} flex flex-col w-full overflow-hidden',
  child: Column(
    mainAxisSize: MainAxisSize.min,
    children: [
      // header...
      Flexible(
        child: ListView(
          shrinkWrap: true,
          // ...
        ),
      ),
      // footer...
    ],
  ),
)

The outer WDiv with flex flex-col creates a Wind UI Flex widget. The inner Column (also a Flex) receives unconstrained height from the WDiv's flex layout. When Column(mainAxisSize: MainAxisSize.min) sizes to its content and that content exceeds the ConstrainedBox(maxHeight: safeHeight * 0.85), the Column overflows because the WDiv flex parent doesn't properly propagate the max-height constraint down through its flex layout to the Column child.

The ListView(shrinkWrap: true) inside Flexible should handle scrolling, but the constraint chain breaks at the WDiv→Column boundary.

Expected Behavior

The body area should scroll when content exceeds the available height. Header and footer should remain sticky (visible).

Screenshots

overflow

  • 7 agent role cards in the body
  • Yellow/black overflow stripe at modal bottom
  • Footer (cancel/confirm buttons) not visible

Environment

  • magic_starter: latest (post safe-area fix 0aaef87)
  • Flutter web (Chrome)
  • Screen: standard desktop viewport

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions