[PR #7038] [MERGED] feat: refactor slash menu items to support showing in table cell #7702

Closed
opened 2026-03-23 23:20:49 +00:00 by mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/AppFlowy-IO/AppFlowy/pull/7038
Author: @LucasXu0
Created: 12/24/2024
Status: Merged
Merged: 12/25/2024
Merged by: @LucasXu0

Base: mainHead: slash_menu_in_table_cell


📝 Commits (10+)

  • f9c75c6 feat: refactor slash menu items to support showing in table cell
  • 3876dbc chore: remove default slash menu items
  • 61ef196 feat: support customizing slash commands in table cell
  • 6c35945 fix: unable to delete math equation
  • 37a885b fix: underline issue
  • 75dc6b2 feat: support text align in table
  • 59992d7 fix: image alignment doesn't work in simple table cell
  • e866df3 fix: reduce the padding in table cell
  • be8c149 fix: drag column / row error in table
  • ce0a812 test: support slash menu in table

📊 Changes

46 files changed (+1947 additions, -924 deletions)

View changed files

📝 frontend/appflowy_flutter/integration_test/desktop/document/document_with_simple_table_test.dart (+97 -0)
📝 frontend/appflowy_flutter/integration_test/mobile/document/simple_table_test.dart (+1 -10)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_configuration.dart (+104 -46)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_page.dart (+22 -48)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/callout/callout_block_component.dart (+1 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/file/file_block_component.dart (+2 -2)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/image/custom_image_block_component/image_menu.dart (+1 -1)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/math_equation/math_equation_block_component.dart (+40 -4)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/mention_date_block.dart (+7 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/mention_page_block.dart (+0 -1)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/slash_menu_items.dart (+0 -47)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/plugins.dart (+2 -1)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/shortcuts/character_shortcuts.dart (+3 -3)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_cell_block_component.dart (+59 -11)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_operations/simple_table_node_extension.dart (+6 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_widgets/simple_table_feedback.dart (+18 -10)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_command.dart (+145 -0)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items.dart (+0 -736)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items/ai_writer_item.dart (+55 -0)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items/bulleted_list_item.dart (+29 -0)

...and 26 more files

📄 Description

Feature Preview

closes https://github.com/AppFlowy-IO/AppFlowy/issues/7011
closes https://github.com/AppFlowy-IO/AppFlowy/issues/7010

Screenshot 2024-12-24 at 14 23 35
  • support slash menu in table cell on desktop
    • customize slash menu items when displayed in a table cell
      • Text
      • H1 - H3
      • Image
      • Bulleted list
      • Numbered list
      • To-do list
      • Divider
      • Quote
      • Table (in a separate PR)
      • Link to page
      • Callout
      • Math equation
      • Code
      • Toggles
      • Toggle H1 - H3
      • Emoji
      • Date or Reminder
      • File
      • Document
    • unable to delete some blocks
      • math equation
      • sub page block
      • code block
  • tests

PR Checklist

  • My code adheres to AppFlowy's Conventions
  • I've listed at least one issue that this PR fixes in the description above.
  • I've added a test(s) to validate changes in this PR, or this PR only contains semantic changes.
  • All existing tests are passing.

🔄 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/7038 **Author:** [@LucasXu0](https://github.com/LucasXu0) **Created:** 12/24/2024 **Status:** ✅ Merged **Merged:** 12/25/2024 **Merged by:** [@LucasXu0](https://github.com/LucasXu0) **Base:** `main` ← **Head:** `slash_menu_in_table_cell` --- ### 📝 Commits (10+) - [`f9c75c6`](https://github.com/AppFlowy-IO/AppFlowy/commit/f9c75c6e091dd0265dd88c137f9668bcf194df57) feat: refactor slash menu items to support showing in table cell - [`3876dbc`](https://github.com/AppFlowy-IO/AppFlowy/commit/3876dbcfcc1d85afdc380a0c13bae65f658bf915) chore: remove default slash menu items - [`61ef196`](https://github.com/AppFlowy-IO/AppFlowy/commit/61ef196ee6fe95fc877dec6d6b3da42fd58350eb) feat: support customizing slash commands in table cell - [`6c35945`](https://github.com/AppFlowy-IO/AppFlowy/commit/6c35945a75c783cecb9c4bd1aa20565bb2336929) fix: unable to delete math equation - [`37a885b`](https://github.com/AppFlowy-IO/AppFlowy/commit/37a885b831b0fcbd17b6b9aed404cb9909f255f8) fix: underline issue - [`75dc6b2`](https://github.com/AppFlowy-IO/AppFlowy/commit/75dc6b2e4bb91e1ad71966736fc44a033ee181cf) feat: support text align in table - [`59992d7`](https://github.com/AppFlowy-IO/AppFlowy/commit/59992d72d6e0b3aff5cce288be794b8f9ad2b2cf) fix: image alignment doesn't work in simple table cell - [`e866df3`](https://github.com/AppFlowy-IO/AppFlowy/commit/e866df33a216693d7bff7a86f2fa7c17f4143449) fix: reduce the padding in table cell - [`be8c149`](https://github.com/AppFlowy-IO/AppFlowy/commit/be8c14932ad8c9c621e5c0ea5de26f8f8fa66660) fix: drag column / row error in table - [`ce0a812`](https://github.com/AppFlowy-IO/AppFlowy/commit/ce0a812c64afca7ed13d6f2a2cd92144fa3a5893) test: support slash menu in table ### 📊 Changes **46 files changed** (+1947 additions, -924 deletions) <details> <summary>View changed files</summary> 📝 `frontend/appflowy_flutter/integration_test/desktop/document/document_with_simple_table_test.dart` (+97 -0) 📝 `frontend/appflowy_flutter/integration_test/mobile/document/simple_table_test.dart` (+1 -10) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_configuration.dart` (+104 -46) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_page.dart` (+22 -48) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/callout/callout_block_component.dart` (+1 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/file/file_block_component.dart` (+2 -2) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/image/custom_image_block_component/image_menu.dart` (+1 -1) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/math_equation/math_equation_block_component.dart` (+40 -4) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/mention_date_block.dart` (+7 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/mention_page_block.dart` (+0 -1) ➖ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/mention/slash_menu_items.dart` (+0 -47) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/plugins.dart` (+2 -1) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/shortcuts/character_shortcuts.dart` (+3 -3) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_cell_block_component.dart` (+59 -11) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_operations/simple_table_node_extension.dart` (+6 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/simple_table/simple_table_widgets/simple_table_feedback.dart` (+18 -10) ➕ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_command.dart` (+145 -0) ➖ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items.dart` (+0 -736) ➕ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items/ai_writer_item.dart` (+55 -0) ➕ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/slash_menu/slash_menu_items/bulleted_list_item.dart` (+29 -0) _...and 26 more files_ </details> ### 📄 Description <!--- Thank you for submitting a pull request to AppFlowy. The team will dedicate their best efforts to reviewing and approving your pull request. If you have any questions about the project or feedback for us, please join our [Discord](https://discord.gg/wdjWUXXhtw). --> <!--- If your pull request adds a new feature, please drag and drop a video into this section to showcase what you've done! If not, you may delete this section. --> ### Feature Preview closes https://github.com/AppFlowy-IO/AppFlowy/issues/7011 closes https://github.com/AppFlowy-IO/AppFlowy/issues/7010 <img width="1523" alt="Screenshot 2024-12-24 at 14 23 35" src="https://github.com/user-attachments/assets/17af8f95-f15a-4932-8997-bb72d13f0b2b" /> - [x] support slash menu in table cell on desktop - [x] customize slash menu items when displayed in a table cell - [x] Text - [x] H1 - H3 - [x] Image - [x] Bulleted list - [x] Numbered list - [x] To-do list - [x] Divider - [x] Quote - [ ] Table (in a separate PR) - [x] Link to page - [x] Callout - [x] Math equation - [x] Code - [x] Toggles - [x] Toggle H1 - H3 - [x] Emoji - [x] Date or Reminder - [x] File - [x] Document - [x] unable to delete some blocks - [x] math equation - [x] sub page block - [x] code block - [x] tests <!--- List at least one issue here that this PR addresses. If it fixes the issue, please use the [fixes](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/using-keywords-in-issues-and-pull-requests) keyword to close the issue. For example: fixes https://github.com/AppFlowy-IO/AppFlowy/pull/2106 --> --- <!--- Before you mark this PR ready for review, run through this checklist! --> #### PR Checklist - [x] My code adheres to [AppFlowy's Conventions](https://docs.appflowy.io/docs/documentation/software-contributions/conventions) - [x] I've listed at least one issue that this PR fixes in the description above. - [x] I've added a test(s) to validate changes in this PR, or this PR only contains semantic changes. - [x] All existing tests are passing. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
mirror 2026-03-23 23:20:49 +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#7702
No description provided.