userOrderCancelled.dart 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. import 'package:flutter/material.dart';
  2. import '../home_page.dart';
  3. class userOrderCancelled extends StatelessWidget {
  4. const userOrderCancelled({Key? key}) : super(key: key);
  5. @override
  6. Widget build(BuildContext context) {
  7. return Scaffold(
  8. backgroundColor: Colors.white,
  9. body: Padding(
  10. padding: const EdgeInsets.all(16.0),
  11. child: Column(
  12. mainAxisAlignment: MainAxisAlignment.center,
  13. crossAxisAlignment: CrossAxisAlignment.center,
  14. children: [
  15. const Text(
  16. 'Opps..',
  17. style: TextStyle(
  18. fontFamily: 'Poppins',
  19. fontSize: 20,
  20. fontWeight: FontWeight.bold,
  21. color: Colors.black, // Adjust color as needed
  22. ),
  23. ),
  24. const SizedBox(height: 10),
  25. const Text(
  26. 'Your driver cancelled this order',
  27. style: TextStyle(
  28. fontFamily: 'Poppins',
  29. fontSize: 20,
  30. fontWeight: FontWeight.bold,
  31. color: Colors.black, // Adjust color as needed
  32. ),
  33. ),
  34. const SizedBox(height: 70),
  35. Align(
  36. alignment: Alignment.center,
  37. child:
  38. Container(
  39. width: 334,
  40. height: 65,
  41. decoration: BoxDecoration(
  42. borderRadius: BorderRadius.circular(10),
  43. color: const Color.fromRGBO(119, 97, 255, 1.0),
  44. ),
  45. child: TextButton(
  46. onPressed: () {
  47. // Handle Next button press
  48. Navigator.push(
  49. context,
  50. MaterialPageRoute(builder: (context) => HomePage()),
  51. );
  52. },
  53. child: const Text(
  54. 'Back to main page',
  55. style: TextStyle(
  56. fontFamily: 'Poppins',
  57. fontSize: 17,
  58. fontWeight: FontWeight.bold,
  59. color: Colors.white,
  60. ),
  61. ),
  62. ),
  63. ),
  64. ),
  65. const SizedBox(height: 10),
  66. ],
  67. ),
  68. ),
  69. );
  70. }
  71. }