getAppBarOnlyTitleWithSearch method
dynamic
getAppBarOnlyTitleWithSearch({})
Implementation
getAppBarOnlyTitleWithSearch(
{String? title,
List<Widget>? actions,
bool showLogo = true,
bool isBackButtonVisible = false,
bool isTransparent = false,
Function? backButtonCallback,
Widget? businessLogo,
required Function(String) onSearchValueChanged,
TextEditingController? controller,
String? hintText,
}) {
return CustomPrefferedSizedWidget(
height: 120,
child: Container(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
AppBar(
automaticallyImplyLeading: false,
elevation: 0,
actionsIconTheme: IconThemeData(color: AppColors.appColorBlack65),
centerTitle: false,
actions: actions,
backgroundColor: isTransparent?AppColors.appColorTransparent:AppColors.appColorWhite,
title: Row(
mainAxisAlignment: MainAxisAlignment.start,
mainAxisSize: MainAxisSize.min,
children: [
Visibility(
visible: isBackButtonVisible,
child: InkWell(
onTap: backButtonCallback as void Function()?,
child: Padding(
padding: const EdgeInsets.only(right: 8.0, left: 8),
child: Icon(
Icons.keyboard_backspace_rounded,
size: 24,
color: AppColors.appColorBlack85,
),
),
),
),
businessLogo ?? Container(),
const SizedBox(
width: 4,
),
Flexible(
child: Text(
title!,
style: TextStyleElements.headline6.copyWith(
fontWeight: FontWeight.w600,
color: AppColors.appColorBlack85,
fontSize: 24),
overflow: TextOverflow.ellipsis,
textAlign: TextAlign.center,
),
),
],
),
),
SearchBox(
controller: controller,
onvalueChanged: onSearchValueChanged,
hintText: hintText ??= "Search",
)
],
),
decoration: BoxDecoration(
boxShadow: <BoxShadow>[
BoxShadow(
color: AppColors.appColorBackground,
blurRadius: 15.0,
offset: const Offset(0.0, 0.75))
],
color: AppColors.appColorBackground,
),
),
);
}