scan button and padding bottom scan button
This commit is contained in:
@@ -21,6 +21,9 @@ class _HomeScreenState extends State<HomeScreen> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final Size size = MediaQuery.of(context).size;
|
||||
final screenWidth = MediaQuery.of(context).size.width;
|
||||
final buttonScanSize = screenWidth * 0.20;
|
||||
final double bottomPadding = (9000 / screenWidth).clamp(0, 0.2);
|
||||
return Scaffold(
|
||||
// appBar: AppBar(
|
||||
// elevation: 0,
|
||||
@@ -237,9 +240,10 @@ class _HomeScreenState extends State<HomeScreen> {
|
||||
],
|
||||
),
|
||||
Positioned(bottom: 0, left: 0, right: 0, child: MainMenu()),
|
||||
|
||||
Positioned(
|
||||
bottom: 8,
|
||||
left: MediaQuery.of(context).size.width / 2 - 38,
|
||||
bottom: bottomPadding * 32,
|
||||
left: (screenWidth - buttonScanSize) / 2,
|
||||
child: Transform.translate(
|
||||
offset: Offset(0, -20),
|
||||
child: ScanButton(),
|
||||
|
||||
@@ -36,6 +36,9 @@ class _KoleksiScreenState extends State<KoleksiScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final screenWidth = MediaQuery.of(context).size.width;
|
||||
final buttonScanSize = screenWidth * 0.20;
|
||||
final double bottomPadding = (9000 / screenWidth).clamp(0, 0.2);
|
||||
return Scaffold(
|
||||
extendBody: true,
|
||||
body: Stack(
|
||||
@@ -150,8 +153,8 @@ class _KoleksiScreenState extends State<KoleksiScreen> {
|
||||
),
|
||||
Positioned(bottom: 0, left: 0, right: 0, child: MainMenu()),
|
||||
Positioned(
|
||||
bottom: 8,
|
||||
left: MediaQuery.of(context).size.width / 2 - 38,
|
||||
bottom: bottomPadding * 32,
|
||||
left: (screenWidth - buttonScanSize) / 2,
|
||||
child: Transform.translate(
|
||||
offset: Offset(0, -20),
|
||||
child: ScanButton(),
|
||||
|
||||
@@ -57,6 +57,9 @@ class _PustakaScreenState extends State<PustakaScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final screenWidth = MediaQuery.of(context).size.width;
|
||||
final buttonScanSize = screenWidth * 0.20;
|
||||
final double bottomPadding = (9000 / screenWidth).clamp(0, 0.2);
|
||||
List<Map<String, dynamic>> filteredCollections =
|
||||
_collections
|
||||
.where(
|
||||
@@ -290,8 +293,8 @@ class _PustakaScreenState extends State<PustakaScreen> {
|
||||
],
|
||||
),
|
||||
Positioned(
|
||||
bottom: 8,
|
||||
left: MediaQuery.of(context).size.width / 2 - 38,
|
||||
bottom: bottomPadding * 32,
|
||||
left: (screenWidth - buttonScanSize) / 2,
|
||||
child: Transform.translate(
|
||||
offset: Offset(0, -20),
|
||||
child: ScanButton(),
|
||||
|
||||
@@ -54,6 +54,9 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final screenWidth = MediaQuery.of(context).size.width;
|
||||
final buttonScanSize = screenWidth * 0.20;
|
||||
final double bottomPadding = (9000 / screenWidth).clamp(0, 0.2);
|
||||
return Scaffold(
|
||||
backgroundColor: const Color.fromARGB(255, 255, 255, 255),
|
||||
body: Stack(
|
||||
@@ -341,8 +344,8 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
),
|
||||
Positioned(bottom: 0, left: 0, right: 0, child: MainMenu()),
|
||||
Positioned(
|
||||
bottom: 8,
|
||||
left: MediaQuery.of(context).size.width / 2 - 38,
|
||||
bottom: bottomPadding * 32,
|
||||
left: (screenWidth - buttonScanSize) / 2,
|
||||
child: Transform.translate(
|
||||
offset: Offset(0, -20),
|
||||
child: ScanButton(),
|
||||
|
||||
Reference in New Issue
Block a user