import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:siro_driver/constant/colors.dart';
import 'package:siro_driver/controller/functions/log_out.dart';
import 'package:siro_driver/views/widgets/elevated_btn.dart';
import 'package:siro_driver/views/widgets/my_scafold.dart';

class LogoutCaptain extends StatelessWidget {
  const LogoutCaptain({super.key});

  @override
  Widget build(BuildContext context) {
    return MyScafolld(
      title: 'Log Out Page'.tr,
      body: [
        Center(
          child: Column(
            mainAxisAlignment: MainAxisAlignment.center,
            children: [
              MyElevatedButton(
                  title: 'Log Off'.tr,
                  onPressed: () {
                    LogOutController().logOutCaptain();
                  }),
              const SizedBox(
                height: 30,
              ),
              MyElevatedButton(
                title: 'Delete My Account'.tr,
                onPressed: () {
                  LogOutController().deletecaptainAccount();
                },
                kolor: AppColor.redColor,
              ),
            ],
          ),
        )
      ],
      isleading: true,
    );
  }
}
