Commit caa14fd5 authored by Budi Prasetyo's avatar Budi Prasetyo

scroll

parent 9453ef13
......@@ -21,8 +21,8 @@ class _loginState extends State<login> {
final formKey = GlobalKey<FormState>();
String _usmail = '';
String _uspswd = '';
TextEditingController _editingController = TextEditingController();
TextEditingController _editingController2 = TextEditingController();
final TextEditingController _editingController = TextEditingController();
final TextEditingController _editingController2 = TextEditingController();
@override
Widget build(BuildContext context) {
......
......@@ -37,13 +37,13 @@ class _ContactUsState extends State<ContactUs> {
? AppBarKecil()
: AppbarHomeLarge(screenSize, context, Colors.black, Colors.black,
Colors.black, Colors.black, Colors.blue),
drawer: DrawerMedApp(),
drawer: const DrawerMedApp(),
body: ResponsiveWidget.isSmallScreen(context)
? ListView(
children: [
const ContactUs1_small(),
children: const [
ContactUs1_small(),
ContactUs2_small(),
const FooterSmall(),
FooterSmall(),
],
)
: ListView(
......
import 'package:flutter/material.dart';
import 'package:medapp_eksad/appbar/appbar_home.dart';
import 'package:medapp_eksad/screen/contact_us/contact_us2.dart';
import 'package:medapp_eksad/screen/footer.dart';
import 'package:medapp_eksad/screen/solution/our_solution.dart';
import 'package:medapp_eksad/screen/solution/our_solution2.dart';
......@@ -27,6 +28,16 @@ class Solutions extends StatefulWidget {
class _SolutionsState extends State<Solutions> {
final GlobalKey<ScaffoldState> _scaffoldKey = GlobalKey<ScaffoldState>();
ScrollController controller2 = ScrollController();
void _scrollToIndex(double index) {
controller2.animateTo(index,
duration: const Duration(seconds: 1),
curve: Curves.fastLinearToSlowEaseIn);
}
@override
Widget build(BuildContext context) {
setPageTitle('MeddApp Solutions', context);
......@@ -48,16 +59,46 @@ class _SolutionsState extends State<Solutions> {
],
)
: ListView(
children: const [
OurSolution(),
controller: controller2,
children: [
OurSolution(button: ButtonSolution(context),),
OurSolution2(),
OurSolution3(),
ContactUs2(),
Footer(),
],
),
);
}
ElevatedButton ButtonSolution(BuildContext context) {
return ElevatedButton(
onPressed: () {
_scrollToIndex(1500);
},
style: ElevatedButton.styleFrom(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10),
),
primary: Color.fromARGB(255, 48, 104, 170),
// shape: MaterialStateProperty.all(RoundedRectangleBorder(borderRadius: BorderRadius.circular(30.0))),
),
child: const Text(
'FREE DEMO',
style: TextStyle(
fontSize: 19,
fontWeight: FontWeight.w500,
letterSpacing: 1.1,
color: Colors.white),
),
);
}
AppBar AppBarKecil() {
return AppBar(
leading: IconButton(
......
......@@ -2,14 +2,12 @@ import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';
import 'package:show_up_animation/show_up_animation.dart';
class OurSolution extends StatefulWidget {
const OurSolution({Key? key}) : super(key: key);
@override
State<OurSolution> createState() => _OurSolutionState();
}
class OurSolution extends StatelessWidget {
const OurSolution({Key? key,required this.button}) : super(key: key);
final Widget button;
class _OurSolutionState extends State<OurSolution> {
@override
Widget build(BuildContext context) {
var screenSize = MediaQuery.of(context).size;
......@@ -88,26 +86,7 @@ class _OurSolutionState extends State<OurSolution> {
curve: Curves.bounceIn,
direction: Direction.horizontal,
offset: -0.2,
child: ElevatedButton(
onPressed: () {
Navigator.pushNamed(context, '/register');
},
style: ElevatedButton.styleFrom(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10),
),
primary: Color.fromARGB(255, 48, 104, 170),
// shape: MaterialStateProperty.all(RoundedRectangleBorder(borderRadius: BorderRadius.circular(30.0))),
),
child: const Text(
'FREE DEMO',
style: TextStyle(
fontSize: 19,
fontWeight: FontWeight.w500,
letterSpacing: 1.1,
color: Colors.white),
),
),
child: button,
),
),
const SizedBox(
......@@ -121,3 +100,126 @@ class _OurSolutionState extends State<OurSolution> {
);
}
}
// class OurSolution extends StatefulWidget {
// const OurSolution({Key? key,required this.button}) : super(key: key);
//
// final Widget button;
//
// @override
// State<OurSolution> createState() => _OurSolutionState();
// }
//
// class _OurSolutionState extends State<OurSolution> {
// @override
// Widget build(BuildContext context) {
// var screenSize = MediaQuery.of(context).size;
// return Stack(
// children: [
// Container(
// width: screenSize.width,
// height: screenSize.height * 0.8,
// decoration: const BoxDecoration(
// image: DecorationImage(
// image: AssetImage(
// "assets/images/solution.jpg",
// ),
// alignment: Alignment.topCenter,
// fit: BoxFit.cover),
// ),
// ),
// const SizedBox(
// height: 10,
// ),
// SizedBox(
// width: screenSize.width,
// height: screenSize.height * 0.5,
//
// // ),
// ),
// Container(
// padding: EdgeInsets.only(right: screenSize.width * 0.5),
// child: Center(
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.center,
// mainAxisAlignment: MainAxisAlignment.spaceEvenly,
// children: [
// const SizedBox(height: 70),
// Container(
// height: screenSize.height * 0.10,
// child: ShowUpAnimation(
// delayStart: const Duration(seconds: 1),
// curve: Curves.bounceIn,
// direction: Direction.horizontal,
// offset: -0.2,
// child: Text(
// 'Find & Get the Best Talent',
// style: GoogleFonts.poppins(
// fontSize: 34,
// fontWeight: FontWeight.bold,
// color: Colors.white),
// textAlign: TextAlign.center,
// ),
// ),
// ),
// const SizedBox(height: 10),
// Container(
// width: screenSize.width * 0.28,
// height: screenSize.height * 0.15,
// child: ShowUpAnimation(
// delayStart: const Duration(seconds: 1),
// curve: Curves.decelerate,
// direction: Direction.horizontal,
// child: Text(
// 'Register for free now, find our Best Talent, and enjoy our unlimited hires at a low cost',
// style: GoogleFonts.poppins(
// fontSize: 18,
// letterSpacing: 1.8,
// height: 1.4,
// fontWeight: FontWeight.bold,
// color: Colors.white),
// textAlign: TextAlign.center,
// ),
// ),
// ),
// Container(
// height: 50,
// child: ShowUpAnimation(
// delayStart: const Duration(seconds: 1),
// curve: Curves.bounceIn,
// direction: Direction.horizontal,
// offset: -0.2,
// child: ElevatedButton(
// onPressed: () {
// Navigator.pushNamed(context, '/register');
// },
// style: ElevatedButton.styleFrom(
// shape: RoundedRectangleBorder(
// borderRadius: BorderRadius.circular(10),
// ),
// primary: Color.fromARGB(255, 48, 104, 170),
// // shape: MaterialStateProperty.all(RoundedRectangleBorder(borderRadius: BorderRadius.circular(30.0))),
// ),
// child: const Text(
// 'FREE DEMO',
// style: TextStyle(
// fontSize: 19,
// fontWeight: FontWeight.w500,
// letterSpacing: 1.1,
// color: Colors.white),
// ),
// ),
// ),
// ),
// const SizedBox(
// height: 10,
// )
// ],
// ),
// ),
// ),
// ],
// );
// }
// }
......@@ -16,7 +16,7 @@ class _OurSolution3State extends State<OurSolution3> {
return Container(
padding: const EdgeInsets.all(10),
width: screenSize.width,
height: screenSize.height * 0.75,
height: screenSize.height * 0.83,
child: Column(
children: <Widget>[
const SizedBox(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment