File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
frontend/appflowy_flutter/lib
mobile/presentation/database/board/widgets
plugins/database_view/board/application Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,11 @@ class _GroupCardHeaderState extends State<GroupCardHeader> {
8585 ),
8686 maxLines: 1 ,
8787 style: titleTextStyle,
88+ onTapOutside: (_) => context.read <BoardBloc >().add (
89+ // group header switch from TextField to Text
90+ // group name won't be changed
91+ BoardEvent .endEditingHeader (widget.groupData.id, null ),
92+ ),
8893 );
8994 }
9095
Original file line number Diff line number Diff line change @@ -211,7 +211,7 @@ class BoardBloc extends Bloc<BoardEvent, BoardState> {
211211 state.copyWith (isEditingHeader: true , editingHeaderId: groupId),
212212 );
213213 },
214- endEditingHeader: (String groupId, String groupName) async {
214+ endEditingHeader: (String groupId, String ? groupName) async {
215215 await groupBackendSvc.updateGroup (
216216 fieldId: groupControllers.values.first.group.fieldId,
217217 groupId: groupId,
@@ -505,7 +505,7 @@ class BoardEvent with _$BoardEvent {
505505 const factory BoardEvent .createGroup (String name) = _CreateGroup ;
506506 const factory BoardEvent .startEditingHeader (String groupId) =
507507 _StartEditingHeader ;
508- const factory BoardEvent .endEditingHeader (String groupId, String groupName) =
508+ const factory BoardEvent .endEditingHeader (String groupId, String ? groupName) =
509509 _EndEditingHeader ;
510510 const factory BoardEvent .didCreateRow (
511511 GroupPB group,
You can’t perform that action at this time.
0 commit comments