-
Notifications
You must be signed in to change notification settings - Fork 123
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
125 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import 'package:easy_localization/easy_localization.dart'; | ||
import 'package:evently/generated/locale_keys.g.dart'; | ||
import 'package:evently/utils/evently_app_theme.dart'; | ||
import 'package:evently/utils/space_utils.dart'; | ||
import 'package:evently/widgets/clipped_button.dart'; | ||
import 'package:flutter/material.dart'; | ||
import 'package:flutter_screenutil/flutter_screenutil.dart'; | ||
|
||
class BottomButtons extends StatelessWidget { | ||
const BottomButtons({ | ||
super.key, | ||
required this.onPressContinue, | ||
required this.onPressSaveDraft, | ||
required this.isContinueEnable, | ||
}); | ||
|
||
final VoidCallback onPressContinue; | ||
final VoidCallback onPressSaveDraft; | ||
final bool isContinueEnable; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Column( | ||
children: [ | ||
ClippedButton( | ||
title: LocaleKeys.continue_key.tr(), | ||
bgColor: isContinueEnable ? EventlyAppTheme.kBlue : EventlyAppTheme.kGery03, | ||
textColor: EventlyAppTheme.kWhite, | ||
onPressed: onPressContinue, | ||
cuttingHeight: 15.h, | ||
clipperType: ClipperType.bottomLeftTopRight, | ||
isShadow: false, | ||
fontWeight: FontWeight.w700, | ||
), | ||
const VerticalSpace(10), | ||
Center( | ||
child: InkWell( | ||
onTap: onPressSaveDraft, | ||
child: Text( | ||
LocaleKeys.save_draft.tr(), | ||
style: TextStyle(color: EventlyAppTheme.kTextGrey02, fontSize: 14.sp, fontWeight: FontWeight.w700), | ||
), | ||
), | ||
), | ||
const VerticalSpace(5), | ||
], | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import 'package:evently/utils/evently_app_theme.dart'; | ||
import 'package:evently/viewmodels/create_event_viewmodel.dart'; | ||
import 'package:flutter/material.dart'; | ||
import 'package:flutter_screenutil/flutter_screenutil.dart'; | ||
import 'package:provider/provider.dart'; | ||
|
||
class PageAppBar extends StatelessWidget { | ||
const PageAppBar({ | ||
super.key, | ||
required this.onPressBack, | ||
}); | ||
|
||
final VoidCallback onPressBack; | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
final createEventViewModel = context.watch<CreateEventViewModel>(); | ||
return Stack( | ||
alignment: Alignment.center, | ||
children: [ | ||
Align( | ||
alignment: Alignment.centerLeft, | ||
child: ValueListenableBuilder( | ||
valueListenable: createEventViewModel.currentPage, | ||
builder: (_, int currentPage, __) => Padding( | ||
padding: const EdgeInsets.only(left: 10), | ||
child: IconButton( | ||
onPressed: onPressBack, | ||
icon: const Icon( | ||
Icons.arrow_back_ios, | ||
color: EventlyAppTheme.kGrey02, | ||
), | ||
)), | ||
)), | ||
ValueListenableBuilder( | ||
valueListenable: createEventViewModel.currentPage, | ||
builder: (_, int currentPage, __) { | ||
return Text( | ||
createEventViewModel.pageTitles[createEventViewModel.currentPage.value], | ||
style: Theme.of(context).textTheme.bodyLarge!.copyWith(fontSize: 18.sp, fontWeight: FontWeight.w700, color: EventlyAppTheme.kTextDarkBlue), | ||
); | ||
}, | ||
), | ||
], | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters