Files
driver_tripz/lib/views/widgets/elevated_btn.dart
Hamza-Ayed d74646a511 2/15/1
2024-02-15 14:00:57 +03:00

32 lines
772 B
Dart

import 'package:flutter/material.dart';
import 'package:SEFER/constant/style.dart';
import '../../constant/colors.dart';
class MyElevatedButton extends StatelessWidget {
final String title;
final VoidCallback onPressed;
final Color kolor;
const MyElevatedButton({
Key? key,
required this.title,
required this.onPressed,
this.kolor = AppColor.primaryColor,
}) : super(key: key);
@override
Widget build(BuildContext context) {
return ElevatedButton(
style: ButtonStyle(
backgroundColor: MaterialStateProperty.all(kolor),
),
onPressed: onPressed,
child: Text(
title,
textAlign: TextAlign.center,
style: AppStyle.title.copyWith(color: AppColor.secondaryColor),
),
);
}
}