46 lines
1.1 KiB
Dart
46 lines
1.1 KiB
Dart
|
import 'package:flutter/material.dart';
|
||
|
import 'package:go_router/go_router.dart';
|
||
|
import 'package:kalodings/calendar.dart';
|
||
|
|
||
|
class AppDrawer extends StatelessWidget {
|
||
|
const AppDrawer({
|
||
|
super.key,
|
||
|
});
|
||
|
|
||
|
@override
|
||
|
Widget build(BuildContext context) {
|
||
|
return Drawer(
|
||
|
child: ListView(
|
||
|
padding: EdgeInsets.zero,
|
||
|
children: [
|
||
|
DrawerHeader(
|
||
|
decoration: const BoxDecoration(
|
||
|
color: Colors.redAccent,
|
||
|
),
|
||
|
child: ListTile(
|
||
|
leading: IconButton(
|
||
|
icon: const Icon(Icons.close),
|
||
|
onPressed: () {
|
||
|
Navigator.pop(context);
|
||
|
},
|
||
|
),
|
||
|
title: const Text('Menü')),
|
||
|
),
|
||
|
ListTile(
|
||
|
trailing: const Icon(Icons.calendar_month),
|
||
|
title: const Text('Kalender'),
|
||
|
onTap: () {
|
||
|
context.goNamed('calendar');
|
||
|
},
|
||
|
),
|
||
|
ListTile(
|
||
|
title: const Text('Einstellungen'),
|
||
|
trailing: const Icon(Icons.settings),
|
||
|
onTap: () {},
|
||
|
),
|
||
|
],
|
||
|
),
|
||
|
);
|
||
|
}
|
||
|
}
|