searchBar property

Widget? searchBar
final

Optional search widget displayed below the large title.

Typically a GlassSearchBar. When provided, the widget collapses in Phase 2 — after the large title has fully scrolled away — matching iOS 26's two-phase UINavigationBar search collapse behaviour.

In iPhone Duo's vertical bar strip it leaves the scroll view, as searchable does natively: a magnifier sits at the bottom of the strip, and a tap on it opens this widget along the bottom of the content, with a ✕ in the strip that closes it again. The navigation bar hides while it is open (GlassLargeTitleController.isSearchPresented), and the field takes focus. The strip's field is 48pt tall, so a GlassSearchBar there should set its height to match.

Implementation

final Widget? searchBar;