[PR #7041] [MERGED] feat: add ai message content to document page #7700

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/7041
Author: @richardshiue
Created: 12/24/2024
Status: Merged
Merged: 12/26/2024
Merged by: @richardshiue

Base: mainHead: feat/save-ai-response-as-page


📝 Commits (10+)

  • 0e29bd4 feat: add ai response content to page
  • 4b71bdd chore: apply suggestions from code review
  • f141162 chore: apply suggestions from code review
  • 146e82a chore: reorganize code
  • 7bf30f0 chore: i18n
  • 5f1fe07 chore: enable opening the document in the sidebar
  • 6f9843f fix: async await
  • c86b59f chore: rename ai message action bar widget
  • a252929 feat: make transactions be reflected in the opened document
  • cc683cf chore: merge remote-tracking branch 'upstream/main' into this one

📊 Changes

15 files changed (+690 additions, -219 deletions)

View changed files

frontend/appflowy_flutter/lib/plugins/ai_chat/application/chat_edit_document_service.dart (+96 -0)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/application/chat_select_sources_cubit.dart (+1 -3)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/chat_page.dart (+3 -18)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/desktop_ai_prompt_input.dart (+0 -4)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/mobile_ai_prompt_input.dart (+0 -4)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/select_sources_bottom_sheet.dart (+1 -3)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/select_sources_menu.dart (+18 -9)
frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/ai_message_action_bar.dart (+451 -0)
📝 frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/ai_message_bubble.dart (+49 -160)
frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/message_util.dart (+24 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/application/document_bloc.dart (+20 -1)
📝 frontend/appflowy_flutter/lib/plugins/document/application/editor_transaction_adapter.dart (+13 -14)
📝 frontend/appflowy_flutter/test/unit_test/editor/transaction_adapter_test.dart (+2 -2)
frontend/resources/flowy_icons/16x/ai_add_to_page.svg (+5 -0)
📝 frontend/resources/translations/en.json (+7 -1)

📄 Description

Screenshot 2024-12-24 at 9 07 22 PM

does not currently support opening the document in the right side panel on desktop, nor pushing the view on mobile.

Feature Preview


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/7041 **Author:** [@richardshiue](https://github.com/richardshiue) **Created:** 12/24/2024 **Status:** ✅ Merged **Merged:** 12/26/2024 **Merged by:** [@richardshiue](https://github.com/richardshiue) **Base:** `main` ← **Head:** `feat/save-ai-response-as-page` --- ### 📝 Commits (10+) - [`0e29bd4`](https://github.com/AppFlowy-IO/AppFlowy/commit/0e29bd4f89a9eb432b57950bea52bec240e582d7) feat: add ai response content to page - [`4b71bdd`](https://github.com/AppFlowy-IO/AppFlowy/commit/4b71bdd2fbda751f45eb0b8bc734fd344cafec20) chore: apply suggestions from code review - [`f141162`](https://github.com/AppFlowy-IO/AppFlowy/commit/f141162d799d8a3aefc8b743a1d8a8b400610da6) chore: apply suggestions from code review - [`146e82a`](https://github.com/AppFlowy-IO/AppFlowy/commit/146e82a9834edeecd5d4b6013e144105b1ee7f1f) chore: reorganize code - [`7bf30f0`](https://github.com/AppFlowy-IO/AppFlowy/commit/7bf30f0bc43272427764594076b66e7055fe47d2) chore: i18n - [`5f1fe07`](https://github.com/AppFlowy-IO/AppFlowy/commit/5f1fe0798d67f2b4ef705934c54781a95705d37c) chore: enable opening the document in the sidebar - [`6f9843f`](https://github.com/AppFlowy-IO/AppFlowy/commit/6f9843f3bb35fe39364e2dfa911fd0719448932a) fix: async await - [`c86b59f`](https://github.com/AppFlowy-IO/AppFlowy/commit/c86b59f8464c701fb38f7e28648ee76923451005) chore: rename ai message action bar widget - [`a252929`](https://github.com/AppFlowy-IO/AppFlowy/commit/a252929eab8078550987471cd0f4ec479f9c6cea) feat: make transactions be reflected in the opened document - [`cc683cf`](https://github.com/AppFlowy-IO/AppFlowy/commit/cc683cf0baded3d73b7f590e9bd45fd4ceb2c80a) chore: merge remote-tracking branch 'upstream/main' into this one ### 📊 Changes **15 files changed** (+690 additions, -219 deletions) <details> <summary>View changed files</summary> ➕ `frontend/appflowy_flutter/lib/plugins/ai_chat/application/chat_edit_document_service.dart` (+96 -0) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/application/chat_select_sources_cubit.dart` (+1 -3) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/chat_page.dart` (+3 -18) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/desktop_ai_prompt_input.dart` (+0 -4) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/mobile_ai_prompt_input.dart` (+0 -4) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/select_sources_bottom_sheet.dart` (+1 -3) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/chat_input/select_sources_menu.dart` (+18 -9) ➕ `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/ai_message_action_bar.dart` (+451 -0) 📝 `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/ai_message_bubble.dart` (+49 -160) ➕ `frontend/appflowy_flutter/lib/plugins/ai_chat/presentation/message/message_util.dart` (+24 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/application/document_bloc.dart` (+20 -1) 📝 `frontend/appflowy_flutter/lib/plugins/document/application/editor_transaction_adapter.dart` (+13 -14) 📝 `frontend/appflowy_flutter/test/unit_test/editor/transaction_adapter_test.dart` (+2 -2) ➕ `frontend/resources/flowy_icons/16x/ai_add_to_page.svg` (+5 -0) 📝 `frontend/resources/translations/en.json` (+7 -1) </details> ### 📄 Description ![Screenshot 2024-12-24 at 9 07 22 PM](https://github.com/user-attachments/assets/65058856-b33a-4505-a4e6-463ed8e28b56) ~~does not currently support opening the document in the right side panel on desktop, nor pushing the view on mobile.~~ ### Feature Preview <!--- 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) - [ ] 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. - [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#7700
No description provided.