forked from firka/student-legacy
30 lines
804 B
Dart
Executable File
30 lines
804 B
Dart
Executable File
import 'package:flutter/material.dart';
|
|
|
|
class LoginButton extends StatelessWidget {
|
|
const LoginButton({super.key, required this.onPressed, required this.child});
|
|
|
|
final void Function()? onPressed;
|
|
final Widget? child;
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MaterialButton(
|
|
elevation: 0,
|
|
focusElevation: 0,
|
|
hoverElevation: 0,
|
|
highlightElevation: 0,
|
|
minWidth: MediaQuery.of(context).size.width - 64.0,
|
|
onPressed: onPressed,
|
|
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(12.0)),
|
|
color: Colors.white,
|
|
textColor: Colors.black,
|
|
child: Padding(
|
|
padding: const EdgeInsets.symmetric(
|
|
vertical: 15.0,
|
|
),
|
|
child: child,
|
|
),
|
|
);
|
|
}
|
|
}
|