Files
be_happy_public/lib/presentation/components/fine_notification_card.dart
2026-05-12 12:02:40 +03:00

91 lines
2.7 KiB
Dart
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import 'package:bot_toast/bot_toast.dart';
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';
class FineNotificationCard extends StatelessWidget {
final VoidCallback onClose;
const FineNotificationCard({
super.key,
required this.onClose,
});
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.symmetric(horizontal: 20),
child: Stack(
clipBehavior: Clip.none,
children: [
Container(
padding: const EdgeInsets.fromLTRB(24, 10, 20, 24),
decoration: BoxDecoration(
color: const Color(0xFF2D2B4D),
borderRadius: BorderRadius.circular(32),
),
child: Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const SizedBox(height: 8),
const Padding(
padding: EdgeInsets.only(left: 64),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'У вас имеются неоплаченные штрафы',
style: TextStyle(
color: Colors.white,
fontSize: 18,
fontWeight: FontWeight.bold,
),
),
SizedBox(height: 12),
Text(
'Оплатите штраф, чтобы начать поездку',
style: TextStyle(
color: Colors.white70,
fontSize: 14,
height: 1.2,
),
),
],
),
),
],
),
),
Positioned(
top: -20,
left: -30,
child: Image.asset(
'assets/icons/card-screen.png',
width: 120,
height: 120,
fit: BoxFit.contain,
),
),
Positioned(
top: 15,
right: 15,
child: GestureDetector(
onTap: onClose,
child: Container(
padding: const EdgeInsets.all(6),
decoration: BoxDecoration(
color: Colors.white.withOpacity(0.2),
shape: BoxShape.circle,
),
child: const Icon(Icons.close, color: Colors.white70, size: 20),
),
),
),
],
),
);
}
}