feat: date picker ui revamp (#4044)

* feat: date picker editor

* feat: refactor date picker on mobile

* chore: update background color

* feat: date picker UI revamp

* feat: optimize the scroll behavior

* chore: remove unused code
This commit is contained in:
Lucas.Xu
2023-11-29 21:02:04 +08:00
committed by GitHub
parent 551e012147
commit 8665a25b39
18 changed files with 640 additions and 335 deletions

View File

@ -1,7 +1,7 @@
import 'package:appflowy/mobile/presentation/database/card/card.dart';
import 'package:appflowy/mobile/presentation/database/card/card_detail/mobile_create_row_field_screen.dart';
import 'package:appflowy/mobile/presentation/database/card/card_property_edit/card_property_edit_screen.dart';
import 'package:appflowy/mobile/presentation/database/card/row/cells/cells.dart';
import 'package:appflowy/mobile/presentation/database/date_picker/mobile_date_picker_screen.dart';
import 'package:appflowy/mobile/presentation/database/mobile_board_screen.dart';
import 'package:appflowy/mobile/presentation/database/mobile_calendar_events_screen.dart';
import 'package:appflowy/mobile/presentation/database/mobile_calendar_screen.dart';
@ -539,11 +539,18 @@ GoRoute _mobileDateCellEditScreenRoute() {
path: MobileDateCellEditScreen.routeName,
pageBuilder: (context, state) {
final args = state.extra as Map<String, dynamic>;
final cellController = args[MobileDateCellEditScreen.argCellController];
return MaterialPage(
child: MobileDateCellEditScreen(cellController),
final controller = args[MobileDateCellEditScreen.dateCellController];
final fullScreen = args[MobileDateCellEditScreen.fullScreen];
return CustomTransitionPage(
transitionsBuilder: (_, __, ___, child) => child,
fullscreenDialog: true,
opaque: false,
barrierDismissible: true,
barrierColor: Theme.of(context).bottomSheetTheme.modalBarrierColor,
child: MobileDateCellEditScreen(
controller: controller,
showAsFullScreen: fullScreen ?? true,
),
);
},
);