TF-460 Implement get identity for mobile
This commit is contained in:
@@ -5,18 +5,25 @@ import 'package:flutter_svg/flutter_svg.dart';
|
||||
@immutable
|
||||
class PopupMenuItemWidget extends StatelessWidget {
|
||||
|
||||
final Function onCallBack;
|
||||
final Function onTapCallback;
|
||||
final String icon;
|
||||
final String name;
|
||||
final Color? iconColor;
|
||||
final String? iconSelection;
|
||||
|
||||
PopupMenuItemWidget(this.icon, this.name, this.onCallBack, {this.iconSelection, this.iconColor});
|
||||
PopupMenuItemWidget(
|
||||
this.icon,
|
||||
this.name,
|
||||
this.onTapCallback,
|
||||
{
|
||||
this.iconSelection,
|
||||
this.iconColor
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return InkWell(
|
||||
onTap: () => onCallBack.call(),
|
||||
onTap: () => onTapCallback.call(),
|
||||
child: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 20, vertical: 16),
|
||||
child: SizedBox(
|
||||
|
||||
@@ -45,38 +45,37 @@ class SearchBarView {
|
||||
}
|
||||
|
||||
Widget build() {
|
||||
return InkWell(
|
||||
onTap: () => _onOpenSearchViewAction?.call(),
|
||||
borderRadius: BorderRadius.all(Radius.circular(10)),
|
||||
child: Container(
|
||||
key: Key('search_bar_widget'),
|
||||
alignment: Alignment.topCenter,
|
||||
height: _heightSearchBar ?? 40,
|
||||
width: _maxSizeWidth ?? double.infinity,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
color: AppColor.colorBgSearchBar),
|
||||
padding: _padding ?? EdgeInsets.zero,
|
||||
margin: _margin ?? EdgeInsets.zero,
|
||||
child: MediaQuery(
|
||||
data: MediaQueryData(padding: EdgeInsets.zero),
|
||||
child: Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
buildIconWeb(
|
||||
splashRadius: 12,
|
||||
icon: SvgPicture.asset(_imagePaths.icSearchBar, width: 16, height: 16, fit: BoxFit.fill),
|
||||
onTap: () => _onOpenSearchViewAction?.call()),
|
||||
Expanded(child:
|
||||
Transform(transform: Matrix4.translationValues(-5, 0.0, 0.0),
|
||||
child: Text(
|
||||
_hintTextSearch ?? '',
|
||||
maxLines: 1,
|
||||
style: TextStyle(fontSize: kIsWeb ? 15 : 17, color: AppColor.colorHintSearchBar))))
|
||||
]
|
||||
)
|
||||
)
|
||||
),
|
||||
return Container(
|
||||
key: Key('search_bar_widget'),
|
||||
alignment: Alignment.topCenter,
|
||||
height: _heightSearchBar ?? 40,
|
||||
width: _maxSizeWidth ?? double.infinity,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
color: AppColor.colorBgSearchBar),
|
||||
padding: _padding ?? EdgeInsets.zero,
|
||||
margin: _margin ?? EdgeInsets.zero,
|
||||
child: InkWell(
|
||||
onTap: () => _onOpenSearchViewAction?.call(),
|
||||
borderRadius: BorderRadius.all(Radius.circular(10)),
|
||||
child: MediaQuery(
|
||||
data: MediaQueryData(padding: EdgeInsets.zero),
|
||||
child: Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
buildIconWeb(
|
||||
splashRadius: 12,
|
||||
icon: SvgPicture.asset(_imagePaths.icSearchBar, width: 16, height: 16, fit: BoxFit.fill),
|
||||
onTap: () => _onOpenSearchViewAction?.call()),
|
||||
Expanded(child:
|
||||
Transform(transform: Matrix4.translationValues(-5, 0.0, 0.0),
|
||||
child: Text(
|
||||
_hintTextSearch ?? '',
|
||||
maxLines: 1,
|
||||
style: TextStyle(fontSize: kIsWeb ? 15 : 17, color: AppColor.colorHintSearchBar))))
|
||||
]
|
||||
)
|
||||
)),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user