-
Notifications
You must be signed in to change notification settings - Fork 198
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: exception on prev node text direction null #404
Merged
LucasXu0
merged 4 commits into
AppFlowy-IO:main
from
zoli:fix/previous-node-text-direction-null
Aug 29, 2023
Merged
fix: exception on prev node text direction null #404
LucasXu0
merged 4 commits into
AppFlowy-IO:main
from
zoli:fix/previous-node-text-direction-null
Aug 29, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Introduced default text direction property on editor style. which accepts rtl|ltr|auto for controlling default fallback direction. Before this we had something controlled by Directionality but it had two problems: 1. It didn't accept auto text direction. We had to introduce our own Directionality component. 2. Directionality also affects layout direction, for example setting Directionality to RTL will cause the handlers and other things move to right side of the screen. While this is good but there are cases which we don't want to change whole layout direction but only the text default direction to for example auto.
The code was throwing excenption on changing current node text direction to auto when the previous node had text direction attribute with null value. Also changed to only use direct previous node text direction and direct parent for inheriting text direction when the current node text direction is auto and undeterminable (e.g. empty text).
zoli
changed the title
feat: default text direction property
fix: exception on prev node text direction null
Aug 22, 2023
Codecov Report
@@ Coverage Diff @@
## main #404 +/- ##
==========================================
+ Coverage 80.58% 80.59% +0.01%
==========================================
Files 255 255
Lines 10448 10455 +7
==========================================
+ Hits 8419 8426 +7
Misses 2029 2029
|
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The code was throwing exception on changing the current node text
direction to auto when the previous node had a text direction attribute
with null value.
Also changed to only use direct previous node text direction and
direct parent for inheriting text direction when the current node
text direction is auto and undeterminable (e.g. empty text).
This should get merged after #402.