import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; class MenuWidget extends StatelessWidget { const MenuWidget({super.key}); @override Widget build(BuildContext context) { return Drawer( child: ListView( padding: EdgeInsets.zero, children: [ const DrawerHeader( decoration: BoxDecoration( color: Colors.blue, ), child: Text( 'Menu App', style: TextStyle( color: Colors.white, fontSize: 24, ), ), ), ListTile( leading: const Icon(Icons.message), title: const Text('Mensajes'), onTap: () { Navigator.pop(context); // Close the drawer }, ), ListTile( leading: const Icon(Icons.settings), title: const Text('Configuraciones'), onTap: () { Navigator.pop(context); // Close the drawer }, ), ], ), ); } }