mirror of
https://github.com/SyncrowIOT/syncrow-app.git
synced 2025-07-15 09:45:22 +00:00
46 lines
1.6 KiB
Dart
46 lines
1.6 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:flutter_svg/svg.dart';
|
|
import 'package:syncrow_app/features/shared_widgets/text_widgets/body_small.dart';
|
|
import 'package:syncrow_app/generated/assets.dart';
|
|
import 'package:syncrow_app/utils/resource_manager/color_manager.dart';
|
|
import 'package:syncrow_app/utils/resource_manager/font_manager.dart';
|
|
|
|
class SuccessDialog extends StatelessWidget {
|
|
final double dialogWidth;
|
|
final String message;
|
|
|
|
const SuccessDialog(
|
|
{super.key, this.dialogWidth = 160, required this.message});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Dialog(
|
|
backgroundColor: Colors.transparent,
|
|
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(20)),
|
|
child: Container(
|
|
width: dialogWidth,
|
|
height: 120,
|
|
decoration: BoxDecoration(
|
|
color: ColorsManager.blackColor.withOpacity(0.7),
|
|
borderRadius: BorderRadius.circular(15),
|
|
),
|
|
child: Column(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
SvgPicture.asset(
|
|
Assets.assetsSuccessWhite,
|
|
width: 50,
|
|
height: 50,
|
|
),
|
|
const SizedBox(height: 20),
|
|
BodySmall(
|
|
text: message,
|
|
fontColor: ColorsManager.onPrimaryColor,
|
|
fontSize: FontSize.s16),
|
|
],
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|