|
|
@@ -24,123 +24,123 @@ class TipsDialog {
|
|
|
backType: SmartBackType.block,
|
|
|
clickMaskDismiss: true,
|
|
|
maskColor: ColorName.black70,
|
|
|
+ alignment: Alignment.center,
|
|
|
builder: (_) {
|
|
|
- return Scaffold(
|
|
|
- backgroundColor: Colors.transparent,
|
|
|
- body: Column(
|
|
|
- crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
- mainAxisAlignment: MainAxisAlignment.center,
|
|
|
- children: [
|
|
|
- Container(
|
|
|
- width: double.infinity,
|
|
|
- margin: EdgeInsets.symmetric(horizontal: 31.w),
|
|
|
- decoration: ShapeDecoration(
|
|
|
- color: Colors.white,
|
|
|
- shape: RoundedRectangleBorder(
|
|
|
- borderRadius: BorderRadius.circular(20.r),
|
|
|
- ),
|
|
|
+ return Column(
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
+ mainAxisAlignment: MainAxisAlignment.center,
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ width: double.infinity,
|
|
|
+ margin: EdgeInsets.symmetric(horizontal: 31.w),
|
|
|
+ decoration: ShapeDecoration(
|
|
|
+ color: Colors.white,
|
|
|
+ shape: RoundedRectangleBorder(
|
|
|
+ borderRadius: BorderRadius.circular(20.r),
|
|
|
),
|
|
|
- child: Stack(
|
|
|
- children: [
|
|
|
- Container(
|
|
|
- padding: EdgeInsets.symmetric(
|
|
|
- horizontal: 16.w,
|
|
|
- vertical: 24.h,
|
|
|
- ),
|
|
|
- child: Column(
|
|
|
- mainAxisSize: MainAxisSize.min,
|
|
|
- crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
- mainAxisAlignment: MainAxisAlignment.center,
|
|
|
- children: [
|
|
|
- Text(
|
|
|
- title ?? "",
|
|
|
- style: Styles.getTextStyleBlack204W500(16.sp),
|
|
|
- ),
|
|
|
- SizedBox(height: 16.h),
|
|
|
- Text(
|
|
|
- desc ?? "",
|
|
|
- style: Styles.getTextStyleBlack204W400(14.sp),
|
|
|
- ),
|
|
|
- SizedBox(height: 20.h),
|
|
|
- Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: [
|
|
|
- Expanded(
|
|
|
- child: GestureDetector(
|
|
|
- onTap: () {
|
|
|
- if (btnCancel != null) {
|
|
|
- btnCancel();
|
|
|
- }
|
|
|
- SmartDialog.dismiss();
|
|
|
- },
|
|
|
- child: Container(
|
|
|
- height: 48.h,
|
|
|
- alignment: Alignment.center,
|
|
|
- decoration: ShapeDecoration(
|
|
|
- color: const Color(0xFFF5F4F9),
|
|
|
- shape: RoundedRectangleBorder(
|
|
|
- borderRadius: BorderRadius.circular(
|
|
|
- 31.r,
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ child: Stack(
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ padding: EdgeInsets.symmetric(
|
|
|
+ horizontal: 16.w,
|
|
|
+ vertical: 24.h,
|
|
|
+ ),
|
|
|
+ child: Column(
|
|
|
+ mainAxisSize: MainAxisSize.min,
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
+ mainAxisAlignment: MainAxisAlignment.center,
|
|
|
+ children: [
|
|
|
+ Text(
|
|
|
+ title ?? "",
|
|
|
+ style: Styles.getTextStyleBlack204W500(16.sp),
|
|
|
+ ),
|
|
|
+ SizedBox(height: 16.h),
|
|
|
+ Text(
|
|
|
+ desc ?? "",
|
|
|
+ style: Styles.getTextStyleBlack204W400(14.sp),
|
|
|
+ ),
|
|
|
+ SizedBox(height: 20.h),
|
|
|
+ Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: [
|
|
|
+ Expanded(
|
|
|
+ child: GestureDetector(
|
|
|
+ onTap: () {
|
|
|
+ if (btnCancel != null) {
|
|
|
+ btnCancel();
|
|
|
+ }
|
|
|
+ SmartDialog.dismiss();
|
|
|
+ },
|
|
|
+ child: Container(
|
|
|
+ height: 48.h,
|
|
|
+ alignment: Alignment.center,
|
|
|
+ decoration: ShapeDecoration(
|
|
|
+ color: const Color(0xFFF5F4F9),
|
|
|
+ shape: RoundedRectangleBorder(
|
|
|
+ borderRadius: BorderRadius.circular(
|
|
|
+ 31.r,
|
|
|
),
|
|
|
),
|
|
|
- child: Text(
|
|
|
- btnCancelText ?? "",
|
|
|
- style: Styles.getTextStyleBlack204W500(
|
|
|
- 16.sp,
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ child: Text(
|
|
|
+ btnCancelText ?? "",
|
|
|
+ style: TextStyle(
|
|
|
+ color: Color(0xFF949396),
|
|
|
+ fontSize: 16.sp,
|
|
|
+ fontWeight: FontWeight.w500,
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
- SizedBox(width: 16.w),
|
|
|
- Expanded(
|
|
|
- child: GestureDetector(
|
|
|
- onTap: () {
|
|
|
- if (btnConfirm != null) {
|
|
|
- btnConfirm();
|
|
|
- }
|
|
|
- SmartDialog.dismiss(tag: tag);
|
|
|
- },
|
|
|
- child: Container(
|
|
|
- height: 48.h,
|
|
|
- alignment: Alignment.center,
|
|
|
- decoration:
|
|
|
- Styles.getActivateButtonDecoration(
|
|
|
- 31.r,
|
|
|
- ),
|
|
|
- child: Text(
|
|
|
- btnConfirmText ?? "",
|
|
|
- style: Styles.getTextStyleWhiteW500(
|
|
|
- 16.sp,
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ SizedBox(width: 16.w),
|
|
|
+ Expanded(
|
|
|
+ child: GestureDetector(
|
|
|
+ onTap: () {
|
|
|
+ if (btnConfirm != null) {
|
|
|
+ btnConfirm();
|
|
|
+ }
|
|
|
+ SmartDialog.dismiss(tag: tag);
|
|
|
+ },
|
|
|
+ child: Container(
|
|
|
+ height: 48.h,
|
|
|
+ alignment: Alignment.center,
|
|
|
+ decoration:
|
|
|
+ Styles.getActivateButtonDecoration(
|
|
|
+ 31.r,
|
|
|
+ ),
|
|
|
+ child: Text(
|
|
|
+ btnConfirmText ?? "",
|
|
|
+ style: Styles.getTextStyleWhiteW500(
|
|
|
+ 16.sp,
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
- ],
|
|
|
- ),
|
|
|
- ],
|
|
|
- ),
|
|
|
- ),
|
|
|
- Positioned(
|
|
|
- right: 14.w,
|
|
|
- top: 14.h,
|
|
|
- child: GestureDetector(
|
|
|
- onTap: () {
|
|
|
- SmartDialog.dismiss();
|
|
|
- },
|
|
|
- child: Assets.images.iconCustomDialogClose.image(
|
|
|
- width: 24.w,
|
|
|
- height: 24.h,
|
|
|
+ ),
|
|
|
+ ],
|
|
|
),
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ Positioned(
|
|
|
+ right: 14.w,
|
|
|
+ top: 14.h,
|
|
|
+ child: GestureDetector(
|
|
|
+ onTap: () {
|
|
|
+ SmartDialog.dismiss();
|
|
|
+ },
|
|
|
+ child: Assets.images.iconCustomDialogClose.image(
|
|
|
+ width: 24.w,
|
|
|
+ height: 24.h,
|
|
|
),
|
|
|
),
|
|
|
- ],
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
),
|
|
|
- ],
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
);
|
|
|
},
|
|
|
);
|