theme property
Theme for AppBar, when isSearchMode == true.
Since you can't just wrap AppBarWithSearchSwitch with Theme widget - this parameter will make it for you.
Example:
...
appBar: AppBarWithSearchSwitch(
theme: Theme.of(context).copyWith(
textSelectionTheme: TextSelectionThemeData(
selectionHandleColor: Theme.of(context).primary,
selectionColor: Theme.of(context).colorScheme.primary.withOpacity(0.5),
cursorColor: Theme.of(context).colorScheme.primary,
),
),
appBarBuilder: (context) {
return AppBar(
title: Text('Your text here'),
See also: titleTextStyle, searchInputDecoration, or just write your own with title.
Implementation
final ThemeData? theme;