Adding base project of flutter-hybrid
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../../Utils/color_constants.dart';
|
||||
import '../../theme/app_style.dart';
|
||||
|
||||
|
||||
// ignore: must_be_immutable
|
||||
class AppbarTitle extends StatelessWidget {
|
||||
AppbarTitle({required this.text, this.margin, this.onTap});
|
||||
|
||||
String text;
|
||||
|
||||
EdgeInsetsGeometry? margin;
|
||||
|
||||
Function? onTap;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return GestureDetector(
|
||||
onTap: () {
|
||||
onTap?.call();
|
||||
},
|
||||
child: Padding(
|
||||
padding: margin ?? EdgeInsets.zero,
|
||||
child: Text(
|
||||
text,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
textAlign: TextAlign.left,
|
||||
style: AppStyle.txtGilroySemiBold24.copyWith(
|
||||
color: ColorConstant.blueGray900,
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user