55 lines
1.3 KiB
Dart
55 lines
1.3 KiB
Dart
import 'package:flutter/cupertino.dart';
|
|
import 'package:flutter/material.dart';
|
|
import 'package:provider/provider.dart';
|
|
import 'package:sf_app_platform/payments/domain/ports/theme_port.dart';
|
|
import 'package:sf_app_platform/payments/view/screens/core/activity_list.dart';
|
|
|
|
class AlertScreen extends StatefulWidget {
|
|
const AlertScreen({super.key});
|
|
|
|
@override
|
|
State<StatefulWidget> createState() => AlertScreenState();
|
|
}
|
|
|
|
class AlertScreenState extends State<AlertScreen> {
|
|
|
|
final activity = [
|
|
{"type": "goal"},
|
|
{"type": "wage", "amount": 5},
|
|
{"type": "lock"},
|
|
{"type": "lock"}
|
|
];
|
|
bool edit = false;
|
|
|
|
@override
|
|
void initState() {
|
|
edit = false;
|
|
super.initState();
|
|
}
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
ThemePort theme = context.read<ThemePort>();
|
|
|
|
return Scaffold(
|
|
backgroundColor: theme.getColorFor(ThemeCode.background_secondary),
|
|
body: Container(
|
|
margin: EdgeInsets.all(30),
|
|
child: Column(
|
|
children: [
|
|
Row(
|
|
children: [
|
|
Text("Alertas"),
|
|
Spacer(),
|
|
TextButton(
|
|
onPressed: () => setState(() {edit = !edit;}),
|
|
child: Text("Editar"))
|
|
],
|
|
),
|
|
ActivityList(activity: activity, edit: edit)
|
|
],
|
|
),
|
|
),
|
|
);
|
|
}
|
|
} |