Skip to content

refactor(input): extract BlockEditCoordinator (iOS & Android)#591

Merged
hryhoriiK97 merged 1 commit into
mainfrom
hryhoriiK97/extract-block-edit-coordinator
Jul 25, 2026
Merged

refactor(input): extract BlockEditCoordinator (iOS & Android)#591
hryhoriiK97 merged 1 commit into
mainfrom
hryhoriiK97/extract-block-edit-coordinator

Conversation

@hryhoriiK97

Copy link
Copy Markdown
Collaborator

What/Why?

Phase 3 of the input architecture refactor: moves block-editing operations (toggle block type, toggle list, change depth) and block query helpers (blockAtPosition, listBlockAtPosition, headingLevel) into a dedicated BlockEditCoordinator on each platform.

The view retains the keyboard interception (handleListKey), UI effects (formatting, typing attributes, empty bullet marker, anchor sync, cursor sizing), and event emission. The coordinator owns pure block-store mutations and query logic, accepting text + selection as parameters and returning results the view acts on.

Testing

PR Checklist

  • Code compiles and runs on iOS
  • Code compiles and runs on Android
  • Updated documentation/README if applicable
  • Ran example app to verify changes
  • E2E tests are passing
  • Required E2E tests have been added (if applicable)

Phase 3 of the input architecture refactor: moves block-editing
operations (toggle block type, toggle list, change depth) and block
query helpers (blockAtPosition, listBlockAtPosition, headingLevel)
into a dedicated BlockEditCoordinator on each platform.

The view retains the keyboard interception (handleListKey), UI
effects (formatting, typing attributes, empty bullet marker, anchor
sync, cursor sizing), and event emission. The coordinator owns pure
block-store mutations and query logic, accepting text + selection
as parameters and returning results the view acts on.

~250 lines removed from the two views, ~350 lines in two new files.

Co-authored-by: Cursor <cursoragent@cursor.com>
@hryhoriiK97
hryhoriiK97 merged commit 817082a into main Jul 25, 2026
8 checks passed
@hryhoriiK97
hryhoriiK97 deleted the hryhoriiK97/extract-block-edit-coordinator branch July 25, 2026 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant