import 'package:flutter/material.dart'; import 'src/views/rutas.dart'; void main() { runApp(const MyApp()); } class MyApp extends StatelessWidget { const MyApp({super.key}); @override Widget build(BuildContext context) { return MaterialApp( debugShowCheckedModeBanner: false, title: 'Hackaton App', home: const RegistroView(), ); } } class RegistroView extends StatelessWidget { const RegistroView({super.key}); final Color colorAzul = const Color(0xFF0F0D38); final Color colorVerde = const Color(0xFF2E4D31); @override Widget build(BuildContext context) { return Scaffold( backgroundColor: Colors.white, appBar: AppBar( backgroundColor: colorAzul, title: const Text('Registro', style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 28)), centerTitle: true, ), body: SingleChildScrollView( padding: const EdgeInsets.all(30.0), child: Column( children: [ const SizedBox(height: 20), _buildInput(Icons.person_outline, 'Nombre'), _buildInput(Icons.person_outline, 'Apellidos'), _buildInput(Icons.email_outlined, 'Correo'), _buildInput(Icons.lock_outline, 'ContraseƱa'), const SizedBox(height: 50), Row( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ ElevatedButton( style: ElevatedButton.styleFrom( backgroundColor: colorAzul, padding: const EdgeInsets.symmetric(horizontal: 30, vertical: 15), shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(15)) ), onPressed: () { Navigator.push(context, MaterialPageRoute(builder: (context) => const HorariosView())); }, child: const Text('Registrar', style: TextStyle(color: Colors.white, fontSize: 18)), ), ElevatedButton( style: ElevatedButton.styleFrom( backgroundColor: colorAzul, padding: const EdgeInsets.symmetric(horizontal: 30, vertical: 15), shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(15)) ), onPressed: () {}, child: const Text('Iniciar Sesion', style: TextStyle(color: Colors.white, fontSize: 18)), ), ], ) ], ), ), ); } Widget _buildInput(IconData icon, String hint) { return Padding( padding: const EdgeInsets.symmetric(vertical: 15), child: Row( children: [ Container( padding: const EdgeInsets.all(10), decoration: BoxDecoration( shape: BoxShape.circle, border: Border.all(color: Colors.black, width: 2), ), child: Icon(icon, size: 40, color: Colors.black), ), const SizedBox(width: 15), Expanded( child: TextField( decoration: InputDecoration( hintText: hint, hintStyle: TextStyle(color: colorVerde.withOpacity(0.5), fontWeight: FontWeight.bold, fontSize: 22), contentPadding: const EdgeInsets.symmetric(horizontal: 20, vertical: 15), enabledBorder: OutlineInputBorder( borderRadius: BorderRadius.circular(30), borderSide: BorderSide(color: colorVerde, width: 4), ), ), ), ), ], ), ); } }