forked from eatvio/eatvio_app
go router
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
// ignore_for_file: unused_local_variable
|
||||
|
||||
import 'package:go_router/go_router.dart';
|
||||
|
||||
import 'bloc/diary_edit_bloc.dart';
|
||||
import 'models/diary_edit_model.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -47,10 +49,10 @@ class DiaryEditScreen extends StatelessWidget {
|
||||
}
|
||||
|
||||
Widget _buildDiaryEditScreen(BuildContext context, DiaryEditLoadedState state) {
|
||||
mediaQueryData = MediaQuery.of(context);
|
||||
return RefreshIndicator(
|
||||
onRefresh: refreshPage(context),
|
||||
child: Stack(
|
||||
alignment: Alignment.bottomCenter,
|
||||
children: [
|
||||
FormBuilder(
|
||||
child: SafeArea(
|
||||
@@ -89,12 +91,7 @@ class DiaryEditScreen extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
left: 16.h,
|
||||
right: 16.h,
|
||||
bottom: 50.v, // Adjusted position to lift the button higher
|
||||
child: _buildEndDay(context),
|
||||
),
|
||||
_buildEndDay(context),
|
||||
],
|
||||
),
|
||||
);
|
||||
@@ -106,7 +103,7 @@ class DiaryEditScreen extends StatelessWidget {
|
||||
margin: EdgeInsets.only(
|
||||
left: 16.h,
|
||||
right: 16.h,
|
||||
bottom: 41.v,
|
||||
bottom: 16.v,
|
||||
),
|
||||
buttonStyle: CustomButtonStyles.outlinePrimaryTL15,
|
||||
decoration: BoxDecoration(
|
||||
@@ -147,7 +144,10 @@ class DiaryEditScreen extends StatelessWidget {
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
CustomImageView(imagePath: ImageConstant.imgArrowLeft, onTap: onTapBack()),
|
||||
CustomImageView(
|
||||
imagePath: ImageConstant.imgArrowLeft,
|
||||
onTap: () => GoRouter.of(context).pop(),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsets.only(top: 1.v),
|
||||
child: Column(
|
||||
@@ -172,12 +172,6 @@ class DiaryEditScreen extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
|
||||
onTapBack() {
|
||||
return () {
|
||||
NavigatorService.goBack();
|
||||
};
|
||||
}
|
||||
|
||||
/// Section Widget
|
||||
_buildAddProduct(BuildContext context, DiaryEditLoadedState state) {
|
||||
return CustomOutlinedButton(
|
||||
|
||||
Reference in New Issue
Block a user