Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: table block bugs #431

Merged
merged 10 commits into from
Aug 31, 2023
Merged

Conversation

LucasXu0
Copy link
Collaborator

  • send transaction after resizing the table
  • apply selection after inserting the table
  • fix some tests

@codecov
Copy link

codecov bot commented Aug 30, 2023

Codecov Report

Patch coverage: 78.43% and project coverage change: +0.22% 🎉

Comparison is base (a912c1c) 79.72% compared to head (7cbf5ff) 79.95%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #431      +/-   ##
==========================================
+ Coverage   79.72%   79.95%   +0.22%     
==========================================
  Files         274      274              
  Lines       11406    11457      +51     
==========================================
+ Hits         9093     9160      +67     
+ Misses       2313     2297      -16     
Files Changed Coverage Δ
...onent/table_block_component/table_action_menu.dart 0.00% <0.00%> (ø)
...t/table_block_component/table_block_component.dart 58.94% <0.00%> (-3.98%) ⬇️
...ponent/table_block_component/table_col_border.dart 51.21% <0.00%> (-5.54%) ⬇️
...ck_component/table_block_component/table_view.dart 72.97% <0.00%> (+3.74%) ⬆️
...tcuts/character_shortcut_events/slash_command.dart 67.74% <85.71%> (+5.24%) ⬆️
..._component/table_block_component/table_action.dart 84.15% <87.34%> (+11.43%) ⬆️
...le_block_component/table_cell_block_component.dart 92.45% <100.00%> (+2.45%) ⬆️
...ock_component/table_block_component/table_col.dart 96.77% <100.00%> (+0.34%) ⬆️
...omponent/table_block_component/table_commands.dart 86.66% <100.00%> (ø)
...ck_component/table_block_component/table_node.dart 97.93% <100.00%> (+0.02%) ⬆️
... and 1 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

pass only transaction to methods directly.
With current transaction adapter in Appflowy which creates `BlockActionPB`
for `documentService` (backend). Its not possible to have multiple
`InsertOperation`s separately as a single transaction (multiple
`transaction.insertNode()`). The `BlockActionPB` creator (`toBlockAction`)
can't figure out the `prevId` (previous node of inserting node id), The
first insert operations shifts all next nodes path.
Because of this situation we decided to apply the insert operations one by
one.
@LucasXu0 LucasXu0 merged commit f205f80 into AppFlowy-IO:main Aug 31, 2023
9 of 10 checks passed
q200892907 added a commit to q200892907/appflowy-editor that referenced this pull request Sep 5, 2023
* main:
  feat: simplify auto scroll behavior in ScrollServiceWidget (AppFlowy-IO#437)
  chore: bump version 1.3.0 (AppFlowy-IO#435)
  fix: better column resize performance (AppFlowy-IO#434)
  fix: table padding and selection (AppFlowy-IO#432)
  fix: table block bugs (AppFlowy-IO#431)
  fix: refactor text alignment handling in block components
  Revert "fix: remove flutter overlay (AppFlowy-IO#358)" (AppFlowy-IO#427)
  feat: support alignment for block component (AppFlowy-IO#425)
  fix: remove flutter overlay (AppFlowy-IO#358)
  feat: toggle highlight using ctrl/cmd + shift + h (AppFlowy-IO#333)
  feat: table plugin (AppFlowy-IO#62)
  feat: editor state update node (AppFlowy-IO#405)
  fix: exception on prev node text direction null (AppFlowy-IO#404)
  fix: html encoder not adding multiple text decorations (AppFlowy-IO#424)
  feat: default text direction property (AppFlowy-IO#402)
  fix: fixed the cursor not moving to next line after inserting divider (AppFlowy-IO#371)
  chore: update theme colors for editor
  feat: refactor floating toolbar positioning logic
  fix: update resizable image width calculation with minimum width constraint
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.

2 participants