[PR #1566] [MERGED] chore: deprecate InputTextField #4826

Closed
opened 2026-03-23 22:16:00 +00:00 by mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/AppFlowy-IO/AppFlowy/pull/1566
Author: @richardshiue
Created: 12/11/2022
Status: Merged
Merged: 12/21/2022
Merged by: @appflowy

Base: mainHead: deprecate-rounded-input-field


📝 Commits (1)

  • c298f02 chore: deprecate InputTextField

📊 Changes

9 files changed (+43 additions, -126 deletions)

View changed files

📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/checklist_cell/checklist_prograss_bar.dart (+1 -0)
📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/select_option_cell/select_option_editor.dart (+1 -1)
frontend/app_flowy/lib/plugins/grid/presentation/widgets/common/text_field.dart (+0 -108)
frontend/app_flowy/lib/plugins/grid/presentation/widgets/common/type_option_separator.dart (+16 -0)
📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/date.dart (+1 -1)
📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/number.dart (+5 -7)
📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/select_option.dart (+4 -3)
📝 frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/select_option_editor.dart (+2 -1)
📝 frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text_field.dart (+13 -5)

📄 Description

This PR deprecates the InputTextField wrapper around RoundedInputField which itself will be deprecated in favor of FlowyTextField. It also makes the following changes to FlowyTextField:

  • change the non-focused border color (check by pressing return after filtering through number formats) from blue to grey
  • allow supplying a FocusNode instead of creating one in the widget.
  • add optional onEditingComplete field to override its default behavior if needed. It's overridden in the add select option because focus shouldn't be given up.
  • call setState() after submitting an input and autoclearing. Without this, the suffix text won't update if the parent widget doesn't get rebuilt, since changing the controller text doesn't call onChanged. (check by submitting an existing option in the select option header editor)
  • don't submit the existing text if focus is lost.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/AppFlowy-IO/AppFlowy/pull/1566 **Author:** [@richardshiue](https://github.com/richardshiue) **Created:** 12/11/2022 **Status:** ✅ Merged **Merged:** 12/21/2022 **Merged by:** [@appflowy](https://github.com/appflowy) **Base:** `main` ← **Head:** `deprecate-rounded-input-field` --- ### 📝 Commits (1) - [`c298f02`](https://github.com/AppFlowy-IO/AppFlowy/commit/c298f023a0f33f65a50bb3391d5ed53a1b509325) chore: deprecate InputTextField ### 📊 Changes **9 files changed** (+43 additions, -126 deletions) <details> <summary>View changed files</summary> 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/checklist_cell/checklist_prograss_bar.dart` (+1 -0) 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/cell/select_option_cell/select_option_editor.dart` (+1 -1) ➖ `frontend/app_flowy/lib/plugins/grid/presentation/widgets/common/text_field.dart` (+0 -108) ➕ `frontend/app_flowy/lib/plugins/grid/presentation/widgets/common/type_option_separator.dart` (+16 -0) 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/date.dart` (+1 -1) 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/number.dart` (+5 -7) 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/select_option.dart` (+4 -3) 📝 `frontend/app_flowy/lib/plugins/grid/presentation/widgets/header/type_option/select_option_editor.dart` (+2 -1) 📝 `frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text_field.dart` (+13 -5) </details> ### 📄 Description This PR deprecates the `InputTextField` wrapper around `RoundedInputField` which itself will be deprecated in favor of `FlowyTextField`. It also makes the following changes to `FlowyTextField`: - change the non-focused border color (check by pressing return after filtering through number formats) from blue to grey - allow supplying a `FocusNode` instead of creating one in the widget. - add optional `onEditingComplete` field to override its [default behavior](https://api.flutter.dev/flutter/material/TextField/onEditingComplete.html) if needed. It's overridden in the add select option because focus shouldn't be given up. - call `setState()` after submitting an input and autoclearing. Without this, the suffix text won't update if the parent widget doesn't get rebuilt, since changing the controller text [doesn't call `onChanged`](https://github.com/flutter/flutter/issues/83171#issuecomment-1126878806). (check by submitting an existing option in the select option header editor) - don't submit the existing text if focus is lost. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
mirror 2026-03-23 22:16:00 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
AppFlowy-IO/AppFlowy#4826
No description provided.