[PR #2456] [MERGED] Support toggle list block #5244

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

📋 Pull Request Information

Original PR: https://github.com/AppFlowy-IO/AppFlowy/pull/2456
Author: @qinluhe
Created: 5/4/2023
Status: Merged
Merged: 5/5/2023
Merged by: @qinluhe

Base: developHead: feat/toggle-list-block


📝 Commits (1)

  • 901b331 feat: support toggle list

📊 Changes

13 files changed (+231 additions, -46 deletions)

View changed files

📝 frontend/appflowy_tauri/src/appflowy_app/components/document/BulletedListBlock/index.tsx (+1 -1)
📝 frontend/appflowy_tauri/src/appflowy_app/components/document/Node/index.tsx (+7 -2)
📝 frontend/appflowy_tauri/src/appflowy_app/components/document/NumberedListBlock/index.tsx (+1 -1)
📝 frontend/appflowy_tauri/src/appflowy_app/components/document/TextBlock/events/TurnIntoEvents.hooks.ts (+3 -1)
📝 frontend/appflowy_tauri/src/appflowy_app/components/document/TextBlock/index.tsx (+1 -1)
📝 frontend/appflowy_tauri/src/appflowy_app/components/document/TodoListBlock/index.tsx (+1 -1)
frontend/appflowy_tauri/src/appflowy_app/components/document/ToggleListBlock/ToggleListBlock.hooks.ts (+38 -0)
frontend/appflowy_tauri/src/appflowy_app/components/document/ToggleListBlock/index.tsx (+41 -0)
📝 frontend/appflowy_tauri/src/appflowy_app/constants/document/config.ts (+82 -12)
📝 frontend/appflowy_tauri/src/appflowy_app/interfaces/document.ts (+7 -0)
📝 frontend/appflowy_tauri/src/appflowy_app/stores/reducers/document/async-actions/blocks/text/split.ts (+36 -13)
📝 frontend/appflowy_tauri/src/appflowy_app/utils/document/blocks/common.ts (+0 -14)
📝 frontend/appflowy_tauri/src/appflowy_app/utils/document/blocks/index.ts (+13 -0)

📄 Description

This branch is based on https://github.com/AppFlowy-IO/AppFlowy/pull/2453

Feature Preview

  • Support turn into Toggle List Block via >
  • Support toggle collapsed with shortcut cmd + enter in mac and ctrl + enter in windows
image

PR Checklist

  • My code adheres to the AppFlowy Style Guide
  • 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/2456 **Author:** [@qinluhe](https://github.com/qinluhe) **Created:** 5/4/2023 **Status:** ✅ Merged **Merged:** 5/5/2023 **Merged by:** [@qinluhe](https://github.com/qinluhe) **Base:** `develop` ← **Head:** `feat/toggle-list-block` --- ### 📝 Commits (1) - [`901b331`](https://github.com/AppFlowy-IO/AppFlowy/commit/901b33101185285a8df553c14c9b8ed570927d1f) feat: support toggle list ### 📊 Changes **13 files changed** (+231 additions, -46 deletions) <details> <summary>View changed files</summary> 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/BulletedListBlock/index.tsx` (+1 -1) 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/Node/index.tsx` (+7 -2) 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/NumberedListBlock/index.tsx` (+1 -1) 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/TextBlock/events/TurnIntoEvents.hooks.ts` (+3 -1) 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/TextBlock/index.tsx` (+1 -1) 📝 `frontend/appflowy_tauri/src/appflowy_app/components/document/TodoListBlock/index.tsx` (+1 -1) ➕ `frontend/appflowy_tauri/src/appflowy_app/components/document/ToggleListBlock/ToggleListBlock.hooks.ts` (+38 -0) ➕ `frontend/appflowy_tauri/src/appflowy_app/components/document/ToggleListBlock/index.tsx` (+41 -0) 📝 `frontend/appflowy_tauri/src/appflowy_app/constants/document/config.ts` (+82 -12) 📝 `frontend/appflowy_tauri/src/appflowy_app/interfaces/document.ts` (+7 -0) 📝 `frontend/appflowy_tauri/src/appflowy_app/stores/reducers/document/async-actions/blocks/text/split.ts` (+36 -13) 📝 `frontend/appflowy_tauri/src/appflowy_app/utils/document/blocks/common.ts` (+0 -14) 📝 `frontend/appflowy_tauri/src/appflowy_app/utils/document/blocks/index.ts` (+13 -0) </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). --> This branch is based on https://github.com/AppFlowy-IO/AppFlowy/pull/2453 <!--- 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 - [x] Support turn into Toggle List Block via `> ` - [x] Support toggle collapsed with shortcut `cmd + enter` in mac and `ctrl + enter` in windows <img width="357" alt="image" src="https://user-images.githubusercontent.com/108015703/236142283-83594a44-58e9-41f5-b53d-5571d7e6f484.png"> <!--- 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 - [ ] My code adheres to the [AppFlowy Style Guide](https://appflowy.gitbook.io/docs/essential-documentation/contribute-to-appflowy/software-contributions/submitting-code/style-guides) - [ ] 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. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
mirror 2026-03-23 22:17:52 +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#5244
No description provided.