[GH-ISSUE #5247] [FR] Master issue for Code Block improvements #2322

Open
opened 2026-03-23 21:21:27 +00:00 by mirror · 4 comments
Owner

Originally created by @Xazin on GitHub (May 2, 2024).
Original GitHub issue: https://github.com/AppFlowy-IO/AppFlowy/issues/5247

Description

Improvements:

  • Enable hide line numbers
  • Show the language that is guessed by the "Auto" option
  • Allow changing the indentation level
  • Bracket completion
  • Collapse code block
  • Auto indentation improvement after opening brakcet

Impact

More control over the behavior of the code block depending on the usage and language.

Additional Context

Code block is over at https://github.com/AppFlowy-IO/AppFlowy-plugins

Much of the implementations can be done in the main repository, but there is a need for some enablers in the plugins repository.

Originally created by @Xazin on GitHub (May 2, 2024). Original GitHub issue: https://github.com/AppFlowy-IO/AppFlowy/issues/5247 ### Description Improvements: - [ ] Enable hide line numbers - [ ] Show the language that is guessed by the "Auto" option - [ ] Allow changing the indentation level - [ ] Bracket completion - [ ] Collapse code block - [ ] Auto indentation improvement after opening brakcet ### Impact More control over the behavior of the code block depending on the usage and language. ### Additional Context Code block is over at https://github.com/AppFlowy-IO/AppFlowy-plugins Much of the implementations can be done in the main repository, but there is a need for some enablers in the plugins repository.
Author
Owner

@MayurSMahajan commented on GitHub (May 3, 2024):

I did some basic Bracket Completion using Character Shortcut Events:
https://github.com/MayurSMahajan/code_block/blob/main/lib/src/utils/shortcuts/character_shortcuts/braces_shortcut.dart

<!-- gh-comment-id:2093002571 --> @MayurSMahajan commented on GitHub (May 3, 2024): I did some basic Bracket Completion using Character Shortcut Events: https://github.com/MayurSMahajan/code_block/blob/main/lib/src/utils/shortcuts/character_shortcuts/braces_shortcut.dart
Author
Owner

@smartyhero commented on GitHub (May 7, 2024):

Can it support automatic line wrapping switching?

<!-- gh-comment-id:2097785964 --> @smartyhero commented on GitHub (May 7, 2024): Can it support automatic line wrapping switching?
Author
Owner

@Xazin commented on GitHub (May 7, 2024):

Can it support automatic line wrapping switching?

Yes, I need to find a suitable implementation for line number replacement when wrapping lines though.

<!-- gh-comment-id:2097788684 --> @Xazin commented on GitHub (May 7, 2024): > Can it support automatic line wrapping switching? Yes, I need to find a suitable implementation for line number replacement when wrapping lines though.
Author
Owner

@smartyhero commented on GitHub (May 7, 2024):

I'm not sure if I described it clearly, I need a function like this

https://github.com/AppFlowy-IO/AppFlowy/assets/76774978/0e2b1578-36f2-4d2a-8236-31110d2f1911

<!-- gh-comment-id:2097805617 --> @smartyhero commented on GitHub (May 7, 2024): I'm not sure if I described it clearly, I need a function like this https://github.com/AppFlowy-IO/AppFlowy/assets/76774978/0e2b1578-36f2-4d2a-8236-31110d2f1911
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#2322
No description provided.