moepoi.dev/lib/screens/resume.dart

119 lines
4 KiB
Dart
Raw Normal View History

2022-06-05 05:18:03 +02:00
import 'package:flutter/material.dart';
import 'package:moepoi_site/components/resume_experience.dart';
import 'package:moepoi_site/components/resume_education.dart';
import 'package:moepoi_site/components/resume_language.dart';
2022-08-08 09:56:25 +02:00
import 'package:moepoi_site/utils/utils.dart'
show
HideScrollGlow,
kDesktopBreakPoint,
kMobileBreakpoint,
kTabletBreakpoint;
2022-06-05 05:18:03 +02:00
class Resume extends StatefulWidget {
const Resume({Key? key}) : super(key: key);
@override
State<Resume> createState() => _ResumeState();
}
class _ResumeState extends State<Resume> {
@override
Widget build(BuildContext context) {
return Title(
title: 'Moe Poi | Resume',
color: const Color.fromARGB(255, 80, 192, 144),
child: Scaffold(
2022-08-08 09:56:25 +02:00
appBar: AppBar(
title: const Text(
'Resume',
style: TextStyle(
color: Colors.black,
fontWeight: FontWeight.w700,
fontSize: 40.0),
2022-06-05 05:18:03 +02:00
),
2022-08-08 09:56:25 +02:00
centerTitle: true,
backgroundColor: Colors.transparent,
elevation: 0.0,
automaticallyImplyLeading: false,
actions: [
Container(
margin: const EdgeInsets.only(right: 20),
child: IconButton(
icon: const Icon(
Icons.close,
color: Color.fromARGB(255, 80, 192, 144),
),
onPressed: () {
Navigator.pop(context);
},
),
2022-06-05 05:18:03 +02:00
),
2022-08-08 09:56:25 +02:00
],
),
body: LayoutBuilder(builder: (context, dimension) {
Widget desktop = ScrollConfiguration(
behavior: HideScrollGlow(),
child: ListView(shrinkWrap: true, children: [
const SizedBox(
height: 50.0,
),
SizedBox(
height: 500,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: [
const Flexible(
flex: 1,
child: ResumeExperience(),
),
Flexible(
flex: 1,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: const [
Flexible(flex: 1, child: ResumeEducation()),
Flexible(flex: 1, child: ResumeLanguage()),
],
),
)
]))
]));
Widget mobile = ScrollConfiguration(
behavior: HideScrollGlow(),
child: Center(
child: ListView(
// crossAxisCount: 1,
padding: const EdgeInsets.all(15.0),
shrinkWrap: true,
// childAspectRatio: 0.8,
children: const [
ResumeExperience(),
SizedBox(
height: 30.0,
),
ResumeEducation(),
SizedBox(
height: 30.0,
),
ResumeLanguage(),
]),
));
if (dimension.maxWidth <= kMobileBreakpoint) {
return mobile;
} else if (dimension.maxWidth > kMobileBreakpoint &&
dimension.maxWidth <= kTabletBreakpoint) {
return desktop;
} else if (dimension.maxWidth > kTabletBreakpoint &&
dimension.maxWidth <= kDesktopBreakPoint) {
return desktop;
} else {
return desktop;
}
})),
2022-06-05 05:18:03 +02:00
);
}
2022-08-08 09:56:25 +02:00
}