From f00e1ebf20cab9cd92e06a01d0eb2ee03e2953ac Mon Sep 17 00:00:00 2001 From: Richard Shiue <71320345+richardshiue@users.noreply.github.com> Date: Mon, 4 Nov 2024 09:30:32 +0300 Subject: [PATCH] chore: remove focus when starting to create a card from the bottom (#6709) --- .../database/board/application/board_actions_bloc.dart | 1 + .../lib/plugins/database/board/presentation/board_page.dart | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/frontend/appflowy_flutter/lib/plugins/database/board/application/board_actions_bloc.dart b/frontend/appflowy_flutter/lib/plugins/database/board/application/board_actions_bloc.dart index 99da7d48f0392..12a1603430867 100644 --- a/frontend/appflowy_flutter/lib/plugins/database/board/application/board_actions_bloc.dart +++ b/frontend/appflowy_flutter/lib/plugins/database/board/application/board_actions_bloc.dart @@ -40,6 +40,7 @@ class BoardActionsCubit extends Cubit { } void startCreateBottomRow(String groupId) { + emit(const BoardActionsState.setFocus(groupedRowIds: [])); emit(BoardActionsState.startCreateBottomRow(groupId: groupId)); emit(const BoardActionsState.initial()); } diff --git a/frontend/appflowy_flutter/lib/plugins/database/board/presentation/board_page.dart b/frontend/appflowy_flutter/lib/plugins/database/board/presentation/board_page.dart index 66395724df215..26807f4afc0d1 100644 --- a/frontend/appflowy_flutter/lib/plugins/database/board/presentation/board_page.dart +++ b/frontend/appflowy_flutter/lib/plugins/database/board/presentation/board_page.dart @@ -534,7 +534,9 @@ class _BoardColumnFooterState extends State { color: Theme.of(context).hintColor, ), onTap: () { - setState(() => _isCreating = true); + context + .read() + .startCreateBottomRow(widget.columnData.id); }, ), ),