course-work/lib/ui/fabs/addorderfab.dart

24 lines
729 B
Dart
Raw Normal View History

2022-12-27 07:01:37 +00:00
import 'package:flutter/material.dart';
2022-12-27 09:09:00 +00:00
import 'package:selfprivacy/ui/orderspage.dart';
2022-12-27 07:01:37 +00:00
class AddOrderFab extends StatelessWidget {
const AddOrderFab({super.key});
@override
Widget build(final BuildContext context) => FloatingActionButton(
2022-12-27 07:01:37 +00:00
heroTag: 'new_order_fab',
onPressed: () {
showModalBottomSheet<void>(
context: context,
isScrollControlled: true,
backgroundColor: Colors.transparent,
builder: (final BuildContext context) => Padding(
padding: MediaQuery.of(context).viewInsets,
2022-12-27 09:09:00 +00:00
child: const OrdersDetails(),
2022-12-27 07:01:37 +00:00
),
);
},
child: const Icon(Icons.add_alarm_outlined),
);
}