69 lines
2.4 KiB
Dart
69 lines
2.4 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:flutter_svg/flutter_svg.dart';
|
|
import 'package:gap/gap.dart';
|
|
import 'package:tanami_app/core/styles/app_color.dart';
|
|
import 'package:tanami_app/core/styles/app_text.dart';
|
|
import 'package:tanami_app/shared/components/text_widget.dart';
|
|
|
|
import '../../../../core/styles/app_images.dart';
|
|
import '../../../../core/utils/language/localizations_delegate.dart';
|
|
|
|
class PinTopSection extends StatelessWidget {
|
|
final String fromScreen;
|
|
const PinTopSection({
|
|
super.key,
|
|
required this.fromScreen,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
var localizations = AppLocalizations.of(context);
|
|
return Column(
|
|
children: [
|
|
const Gap(70),
|
|
Center(
|
|
child: SvgPicture.asset(
|
|
AppImages.welcomeLogo,
|
|
),
|
|
),
|
|
const Gap(40),
|
|
(fromScreen == "login" || fromScreen == "LoginedInUser")
|
|
? Column(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
children: [
|
|
TextWidget().text14W500(
|
|
localizations.translate(AppText.welcomeBackText),
|
|
clr: AppColor.smokeGrayColor),
|
|
TextWidget()
|
|
.text14W700(", Pooja", clr: AppColor.plainBlack),
|
|
],
|
|
),
|
|
TextWidget().text14W500(
|
|
localizations
|
|
.translate(AppText.userYourAppPinToLoginEnterTanami),
|
|
clr: AppColor.smokeGrayColor),
|
|
const Gap(25),
|
|
TextWidget().text14W400(
|
|
localizations.translate(AppText.pinCode),
|
|
clr: AppColor.textLabelColor,
|
|
)
|
|
],
|
|
)
|
|
: fromScreen == "forgot-pin" || fromScreen == "reset-pin"
|
|
? TextWidget().text14W500(
|
|
localizations.translate(AppText.changePinCode),
|
|
clr: AppColor.textLabelColor,
|
|
)
|
|
: TextWidget().text14W500(
|
|
localizations.translate(AppText.createPinCode),
|
|
clr: AppColor.textLabelColor,
|
|
)
|
|
],
|
|
);
|
|
}
|
|
}
|