Feat: This feature is not used
This commit is contained in:
parent
e8ce225010
commit
c3219c13f0
|
@ -22,10 +22,6 @@
|
|||
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
|
||||
android:hardwareAccelerated="true"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
<!-- Specifies an Android theme to apply to this Activity as soon as
|
||||
the Android process has started. This theme is visible to the user
|
||||
while the Flutter UI initializes. After that, this theme continues
|
||||
to determine the Window background behind the Flutter UI. -->
|
||||
<meta-data
|
||||
android:name="io.flutter.embedding.android.NormalTheme"
|
||||
android:resource="@style/NormalTheme"
|
||||
|
@ -33,19 +29,20 @@
|
|||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
|
||||
<!-- Penambahan kode baru -->
|
||||
<!-- <category android:name="android.intent.category.BROWSABLE"/>
|
||||
<data
|
||||
android:scheme="https"
|
||||
android:host="eporter.page.link"/> -->
|
||||
<!-- Penambahan kode baru -->
|
||||
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<!-- Don't delete the meta-data below.
|
||||
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
|
||||
<meta-data
|
||||
android:name="flutterEmbedding"
|
||||
android:value="2" />
|
||||
</application>
|
||||
<!-- Required to query activities that can process text, see:
|
||||
https://developer.android.com/training/package-visibility and
|
||||
https://developer.android.com/reference/android/content/Intent#ACTION_PROCESS_TEXT.
|
||||
|
||||
In particular, this is used by the Flutter engine in io.flutter.plugin.text.ProcessTextPlugin. -->
|
||||
<queries>
|
||||
<intent>
|
||||
<action android:name="android.intent.action.PROCESS_TEXT"/>
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M9.52051 2.00692C9.19138 1.98298 8.85413 2.01662 8.52344 2.11434L7.33984 2.46493C6.07862 2.83793 5.09317 3.83862 4.75976 5.10165C4.01948 7.91052 4.86634 11.2352 7.07031 14.9776C9.27119 18.7149 11.779 21.0901 14.6113 21.8653C15.8868 22.2144 17.2624 21.8809 18.2285 20.9835L19.1289 20.1485C20.1364 19.2131 20.2866 17.655 19.4727 16.5479L18.1719 14.7813C17.4746 13.8343 16.2455 13.431 15.1152 13.7706L13.0801 14.38C12.9946 14.4049 12.7902 14.2886 12.6123 14.1349L12.6113 14.1339C12.2945 13.8583 11.8554 13.3014 11.3857 12.505V12.504C10.8821 11.6486 10.6673 11.0892 10.5811 10.7589C10.4948 10.4284 10.5157 10.3882 10.5283 10.2765C10.5349 10.2207 10.5614 10.1691 10.6064 10.128L10.6074 10.127L12.125 8.73934C12.9944 7.94452 13.2569 6.67434 12.7666 5.60555L11.8516 3.60946V3.60848C11.4208 2.66943 10.5076 2.07873 9.52051 2.00692ZM9.41211 3.50302C9.87121 3.53732 10.294 3.81269 10.4873 4.23446L11.4033 6.23055C11.625 6.71377 11.5138 7.26672 11.1133 7.6329L9.5957 9.01962C9.2846 9.30328 9.08565 9.69002 9.03808 10.1075V10.1085C9.02569 10.2183 8.99641 10.6265 9.12988 11.1378C9.26335 11.649 9.53891 12.3252 10.0928 13.2657H10.0937C10.6105 14.1422 11.099 14.8081 11.6279 15.2677H11.6289C11.8007 15.4164 12.5206 16.1064 13.5 15.8204L13.5029 15.8194L15.5469 15.2071C16.0776 15.0477 16.6451 15.2381 16.9639 15.671L18.2646 17.4376C18.633 17.9394 18.5686 18.6216 18.1084 19.0489L17.208 19.8849C16.6322 20.42 15.7771 20.6289 15.0068 20.4181C12.7172 19.7913 10.4514 17.7627 8.36328 14.2169C6.27225 10.6663 5.61825 7.72959 6.20996 5.48446C6.40556 4.74349 7.00485 4.1284 7.76562 3.90341L8.94824 3.55282C9.10229 3.5073 9.25908 3.49158 9.41211 3.50302Z" fill="#6B7280"/>
|
||||
</svg>
|
After Width: | Height: | Size: 1.7 KiB |
|
@ -53,6 +53,7 @@ class CustomeIcons {
|
|||
static SvgPicture RemoveOutline({double? size, Color? color}) => getIcon('ic_remove', color: color);
|
||||
static SvgPicture UploadOutline({double? size, Color? color}) => getIcon('ic_upload', color: color);
|
||||
static SvgPicture ScrollOutline({double? size, Color? color}) => getIcon('ic_scroll_outline', color: color);
|
||||
static SvgPicture PhoneOutline({double? size, Color? color}) => getIcon('ic_phone', color: color);
|
||||
|
||||
static SvgPicture ScrollFilled({double? size, Color? color}) => getIcon('ic_scroll_filled', color: color);
|
||||
static SvgPicture FlightSeatFilled({double? size, Color? color}) => getIcon('ic_flight_seat_filled', color: color);
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
import 'package:e_porter/_core/constants/colors.dart';
|
||||
import 'package:e_porter/_core/constants/typography.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
|
||||
class CustomText {
|
||||
CustomText._();
|
||||
|
||||
static Widget textPadding8(
|
||||
String text, {
|
||||
Color? color,
|
||||
FontWeight? fontWeight,
|
||||
}) {
|
||||
return Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 8.w),
|
||||
child: TypographyStyles.body(
|
||||
text,
|
||||
color: color ?? GrayColors.gray800,
|
||||
fontWeight: fontWeight ?? FontWeight.w500,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -8,6 +8,13 @@ class Validators {
|
|||
return null;
|
||||
}
|
||||
|
||||
static String? validatorPhone(String? value) {
|
||||
if (value == null || value.isEmpty) {
|
||||
return 'Nomor Telepon tidak boleh kosong';
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static String? validatorPassword(String? value) {
|
||||
if (value == null || value.isEmpty) {
|
||||
return 'Password tidak boleh kosong';
|
||||
|
|
|
@ -1,7 +1,12 @@
|
|||
// ignore_for_file: deprecated_member_use
|
||||
// import 'package:firebase_dynamic_links/firebase_dynamic_links.dart';
|
||||
// import 'package:e_porter/presentation/controllers/profil_controller.dart';
|
||||
// import 'package:firebase_auth/firebase_auth.dart';
|
||||
import 'dart:developer';
|
||||
import 'package:e_porter/domain/bindings/app_binding.dart';
|
||||
import 'package:e_porter/presentation/screens/routes/app_rountes.dart';
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
@ -11,6 +16,7 @@ void main() async {
|
|||
await Firebase.initializeApp();
|
||||
|
||||
log("Firebase Initialized Successfully!");
|
||||
log(">>> Firebase project: ${Firebase.app().options.projectId}");
|
||||
runApp(MyApp(initialRoute: Routes.SPLASH));
|
||||
}
|
||||
|
||||
|
@ -34,3 +40,45 @@ class MyApp extends StatelessWidget {
|
|||
);
|
||||
}
|
||||
}
|
||||
|
||||
// @override
|
||||
// void initState() {
|
||||
// super.initState();
|
||||
// _initDynamicLinks();
|
||||
// }
|
||||
|
||||
// void _initDynamicLinks() async {
|
||||
// final PendingDynamicLinkData? data = await FirebaseDynamicLinks.instance.getInitialLink();
|
||||
// _handleLink(data);
|
||||
|
||||
// FirebaseDynamicLinks.instance.onLink.listen((data) {
|
||||
// _handleLink(data);
|
||||
// }).onError((e) {
|
||||
// // ignore
|
||||
// });
|
||||
// }
|
||||
|
||||
// void _handleLink(PendingDynamicLinkData? data) {
|
||||
// final Uri? deepLink = data?.link;
|
||||
// if (deepLink == null) return;
|
||||
|
||||
// final mode = deepLink.queryParameters['mode'];
|
||||
// final oobCode = deepLink.queryParameters['oobCode'];
|
||||
// if (mode == 'verifyEmail' && oobCode != null) {
|
||||
// FirebaseAuth.instance.applyActionCode(oobCode).then((_) async {
|
||||
// // 1) informasikan sukses
|
||||
// Get.snackbar("Sukses", "Email baru Anda telah terverifikasi.");
|
||||
|
||||
// // 2) reload profile agar UI dan prefs ter-update
|
||||
// final profilC = Get.find<ProfilController>();
|
||||
// await profilC.reloadProfile();
|
||||
|
||||
// // 3) (opsional) kembali ke layar Informasi Biodata
|
||||
// if (Get.currentRoute != Routes.INFORMATIONS) {
|
||||
// Get.toNamed(Routes.INFORMATIONS);
|
||||
// }
|
||||
// }).catchError((err) {
|
||||
// Get.snackbar("Gagal Verifikasi", err.toString());
|
||||
// });
|
||||
// }
|
||||
// }
|
|
@ -0,0 +1,103 @@
|
|||
import 'package:e_porter/_core/component/appbar/appbar_component.dart';
|
||||
import 'package:e_porter/_core/component/button/button_fill.dart';
|
||||
import 'package:e_porter/_core/component/card/custome_shadow_cotainner.dart';
|
||||
import 'package:e_porter/_core/component/text/custom_text.dart';
|
||||
import 'package:e_porter/_core/constants/colors.dart';
|
||||
import 'package:e_porter/_core/validators/validators.dart';
|
||||
import 'package:e_porter/presentation/controllers/profil_controller.dart';
|
||||
import 'package:e_porter/presentation/screens/auth/component/Input_form.dart';
|
||||
import 'package:e_porter/presentation/screens/auth/component/Input_password.dart';
|
||||
import 'package:e_porter/presentation/screens/profile/component/header_information.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
||||
class ChangeEmailScreen extends StatefulWidget {
|
||||
const ChangeEmailScreen({super.key});
|
||||
|
||||
@override
|
||||
State<ChangeEmailScreen> createState() => _ChangeEmailScreenState();
|
||||
}
|
||||
|
||||
class _ChangeEmailScreenState extends State<ChangeEmailScreen> {
|
||||
// final _authController = Get.find<ProfilController>();
|
||||
final _formKey = GlobalKey<FormState>();
|
||||
final _oldPassword = TextEditingController();
|
||||
final _newEmail = TextEditingController();
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
backgroundColor: GrayColors.gray50,
|
||||
appBar: DefaultAppbarComponent(
|
||||
title: 'Ganti Email',
|
||||
textColor: Colors.white,
|
||||
backgroundColors: PrimaryColors.primary800,
|
||||
onTab: () {
|
||||
Get.back();
|
||||
},
|
||||
),
|
||||
body: SafeArea(
|
||||
child: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.w, vertical: 20.h),
|
||||
child: SingleChildScrollView(
|
||||
child: Form(
|
||||
key: _formKey,
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
HeaderInformation(
|
||||
title:
|
||||
'Apakah anda yakin ingin mengganti email akun?. Silahkan masukkan password lama anda sebagai konfirmasi dan masukkan email baru anda',
|
||||
),
|
||||
SizedBox(height: 32.h),
|
||||
CustomText.textPadding8('Password Lama'),
|
||||
SizedBox(height: 16.h),
|
||||
InputPassword(
|
||||
controller: _oldPassword,
|
||||
hintText: '••••••••••',
|
||||
svgIconPath: 'assets/icons/ic_padlock.svg',
|
||||
validator: Validators.validatorPassword,
|
||||
),
|
||||
SizedBox(height: 20.h),
|
||||
CustomText.textPadding8('Email Baru'),
|
||||
SizedBox(height: 16.h),
|
||||
InputForm(
|
||||
controller: _newEmail,
|
||||
hintText: 'example@gmail.com',
|
||||
svgIconPath: 'assets/icons/ic_email.svg',
|
||||
validator: Validators.validatorEmail,
|
||||
textInputType: TextInputType.emailAddress,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
// bottomNavigationBar: Obx(() {
|
||||
// return CustomeShadowCotainner(
|
||||
// child: _authController.isChangingEmail.value
|
||||
// ? Center(
|
||||
// child: CircularProgressIndicator(color: PrimaryColors.primary800),
|
||||
// )
|
||||
// : ButtonFill(
|
||||
// text: 'Simpan',
|
||||
// textColor: Colors.white,
|
||||
// onTap: () async {
|
||||
// if (!_formKey.currentState!.validate()) return;
|
||||
// await _authController.changeEmailFlow(
|
||||
// oldPassword: _oldPassword.text,
|
||||
// newEmail: _newEmail.text.trim(),
|
||||
// );
|
||||
// // if (success) {
|
||||
// // _oldPassword.clear();
|
||||
// // _newEmail.clear();
|
||||
// // FocusScope.of(context).unfocus();
|
||||
// // }
|
||||
// },
|
||||
// ));
|
||||
// }),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -61,6 +61,7 @@ dependencies:
|
|||
mobile_scanner: ^6.0.10
|
||||
pdf: ^3.11.3
|
||||
printing: ^5.14.2
|
||||
# firebase_dynamic_links: ^6.1.5
|
||||
|
||||
# workmanager: ^0.5.2
|
||||
# pin_code_fields: ^8.0.1
|
||||
|
|
Loading…
Reference in New Issue