Initial commit: Penyerahan final Source code Tugas Akhir
This commit is contained in:
64
lib/widgets/login_regist/footer.dart
Normal file
64
lib/widgets/login_regist/footer.dart
Normal file
@ -0,0 +1,64 @@
|
||||
import 'package:flutter/gestures.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:initial_folder/providers/theme_provider.dart';
|
||||
import 'package:initial_folder/size_config.dart';
|
||||
import 'package:initial_folder/theme.dart';
|
||||
import 'package:initial_folder/widgets/terms_and_privacy.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class Footer extends StatelessWidget {
|
||||
const Footer(
|
||||
{Key? key,
|
||||
required this.textOne,
|
||||
required this.textTwo,
|
||||
required this.route,
|
||||
this.height = 48.0})
|
||||
: super(key: key);
|
||||
final String textOne;
|
||||
final String textTwo;
|
||||
final String route;
|
||||
final double height;
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final themeProvider = Provider.of<ThemeProvider>(context);
|
||||
return Column(
|
||||
children: [
|
||||
Container(
|
||||
// padding: EdgeInsets.only(
|
||||
// left: getProportionateScreenWidth(5),
|
||||
// top: getProportionateScreenWidth(5)),
|
||||
alignment: Alignment.center,
|
||||
child: RichText(
|
||||
text: TextSpan(
|
||||
children: <TextSpan>[
|
||||
TextSpan(
|
||||
text: textOne,
|
||||
style: thirdTextStyle.copyWith(
|
||||
color: fifteenColor,
|
||||
),
|
||||
),
|
||||
TextSpan(
|
||||
text: textTwo,
|
||||
style: primaryTextStyle.copyWith(
|
||||
color: themeProvider.themeData == ThemeClass.darkmode
|
||||
?primaryColor : primaryColorligtmode, fontWeight: bold),
|
||||
recognizer: TapGestureRecognizer()
|
||||
..onTap = () {
|
||||
Navigator.of(context).pushNamedAndRemoveUntil(
|
||||
route, (Route<dynamic> route) => false);
|
||||
//Navigator.pushNamed(context, route);
|
||||
}),
|
||||
],
|
||||
style: primaryTextStyle.copyWith(
|
||||
color: tenthColor,
|
||||
fontWeight: reguler,
|
||||
fontSize: getProportionateScreenWidth(14),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
SizedBox(height: getProportionateScreenHeight(35)),
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user