content: import 'package:flutter/material.dart';
  import 'package:flutter_svg/flutter_svg.dart';
  
  import 'package:get/get.dart';
  import 'package:go_absensi/app/style/app_color.dart';
  
  import '../controllers/forgot_password_controller.dart';
  
  class ForgotPasswordView extends GetView<ForgotPasswordController> {
    @override
    Widget build(BuildContext context) {
      return Scaffold(
        backgroundColor: AppColor.primary,
        appBar: AppBar(
          automaticallyImplyLeading: true,
          leading: IconButton(
            icon: SvgPicture.asset(
              'assets/icons/arrow-left.svg',
              color: Colors.white,
            ),
            onPressed: () => Get.back(),
          ),
          backgroundColor: Colors.transparent,
          elevation: 0,
        ),
        extendBodyBehindAppBar: true,
        body: ListView(
          shrinkWrap: true,
          children: [
            Container(
              height: MediaQuery.of(context).size.height * 35 / 100,
              width: MediaQuery.of(context).size.width,
              padding: EdgeInsets.only(left: 32),
              decoration: BoxDecoration(
                gradient: AppColor.primaryGradient,
                image: DecorationImage(
                  image: AssetImage('assets/images/pattern-1-1.png'),
                  fit: BoxFit.cover,
                ),
              ),
            ),
            Container(
              height: MediaQuery.of(context).size.height * 65 / 100,
              width: MediaQuery.of(context).size.width,
              color: Colors.white,
              padding: EdgeInsets.only(left: 20, right: 20, top: 36, bottom: 84),
              child: Column(
                mainAxisAlignment: MainAxisAlignment.start,
                crossAxisAlignment: CrossAxisAlignment.start,
                children: [
                  Container(
                    margin: EdgeInsets.only(bottom: 24),
                    child: Column(
                      crossAxisAlignment: CrossAxisAlignment.start,
                      children: [
                        Text(
                          'Reset Password',
                          style: TextStyle(
                            fontSize: 18,
                            fontFamily: 'poppins',
                            fontWeight: FontWeight.w600,
                          ),
                        ),
                        SizedBox(height: 8),
                        Text(
                          "We will send password reset link to\nyour email.",
                          style: TextStyle(
                            color: AppColor.secondarySoft,
                            height: 150 / 100,
                          ),
                        ),
                      ],
                    ),
                  ),
                  Container(
                    width: MediaQuery.of(context).size.width,
                    padding: EdgeInsets.only(left: 14, right: 14, top: 4),
                    margin: EdgeInsets.only(bottom: 24),
                    decoration: BoxDecoration(
                      color: Colors.white,
                      borderRadius: BorderRadius.circular(8),
                      border: Border.all(width: 1, color: AppColor.secondaryExtraSoft),
                    ),
                    child: TextField(
                      style: TextStyle(fontSize: 14, fontFamily: 'poppins'),
                      maxLines: 1,
                      controller: controller.emailC,
                      decoration: InputDecoration(
                        label: Text(
                          "Email",
                          style: TextStyle(
                            color: AppColor.secondarySoft,
                            fontSize: 14,
                          ),
                        ),
                        floatingLabelBehavior: FloatingLabelBehavior.always,
                        border: InputBorder.none,
                        hintText: "youremail@email.com",
                        hintStyle: TextStyle(
                          fontSize: 14,
                          fontFamily: 'poppins',
                          fontWeight: FontWeight.w500,
                          color: AppColor.secondarySoft,
                        ),
                      ),
                    ),
                  ),
                  Obx(
                    () => Container(
                      width: MediaQuery.of(context).size.width,
                      child: ElevatedButton(
                        onPressed: () async {
                          if (controller.isLoading.isFalse) {
                            await controller.sendEmail();
                          }
                        },
                        child: Text(
                          (controller.isLoading.isFalse) ? 'Send to email' : 'Loading...',
                          style: TextStyle(
                            fontSize: 16,
                            fontFamily: 'poppins',
                            fontWeight: FontWeight.w500,
                          ),
                        ),
                        style: ElevatedButton.styleFrom(
                          padding: EdgeInsets.symmetric(vertical: 18), 
                          backgroundColor: AppColor.primary,
                          elevation: 0,
                          shape: RoundedRectangleBorder(
                            borderRadius: BorderRadius.circular(8),
                          ),
                        ),
                      ),
                    ),
                  ),
                ],
              ),
            ),
          ],
        ),
      );
      // return Scaffold(
      //   appBar: AppBar(
      //     title: Text('ForgotPasswordView'),
      //     centerTitle: true,
      //   ),
      //   body: ListView(
      //     shrinkWrap: true,
      //     padding: EdgeInsets.all(16),
      //     children: [
      //       TextField(
      //         controller: controller.emailC,
      //         autocorrect: false,
      //         decoration: InputDecoration(
      //           border: OutlineInputBorder(),
      //           labelText: 'Email',
      //         ),
      //       ),
      //       Obx(
      //         () => ElevatedButton(
      //           onPressed: () async {
      //             if (controller.isLoading.isFalse) {
      //               await controller.sendEmail();
      //             }
      //           },
      //           child: Text(controller.isLoading.isFalse ? 'Send Reset Password Link' : "Loading..."),
      //         ),
      //       ),
      //     ],
      //   ),
      // );
    }
  }
  