-
Notifications
You must be signed in to change notification settings - Fork 58
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 android rich text errors #949
Conversation
commit 72f934e Merge: c935c81 d46cebd Author: Stefanos Togkoulidis <[email protected]> Date: Thu May 2 10:32:48 2019 +0300 Merge branch 'develop' into fix/list-handling-in-android commit c935c81 Author: Stefanos Togkoulidis <[email protected]> Date: Thu May 2 09:48:36 2019 +0300 Don't use a lambda, to avoid bringing in Java8 features commit d46cebd Merge: 42d8443 09f1ca7 Author: etoledom <[email protected]> Date: Wed May 1 09:37:06 2019 +0200 Merge pull request #890 from wordpress-mobile/issue/autoscroll-on-list-block [iOS] Activate autoscroll on ListBlock commit 04610cc Author: Stefanos Togkoulidis <[email protected]> Date: Wed May 1 00:56:33 2019 +0300 Need to include the kotlin plugin dep location commit 52832ce Merge: 897d272 42d8443 Author: Stefanos Togkoulidis <[email protected]> Date: Wed May 1 00:26:57 2019 +0300 Merge branch 'develop' into fix/list-handling-in-android commit 897d272 Author: Stefanos Togkoulidis <[email protected]> Date: Wed May 1 00:11:36 2019 +0300 Set Aztec t delete the Enter for paragraph block commit ca2a93f Author: Stefanos Togkoulidis <[email protected]> Date: Tue Apr 30 20:24:28 2019 +0300 Update GB from its master commit 0417343 Author: Stefanos Togkoulidis <[email protected]> Date: Tue Apr 30 19:58:53 2019 +0300 Utilize isEnterPressedUnderway commit 991f8a8 Author: Stefanos Togkoulidis <[email protected]> Date: Tue Apr 30 18:10:09 2019 +0300 Use Aztec helper isEnterPressedUnderway commit 09f1ca7 Merge: 61b52cb 42d8443 Author: etoledom <[email protected]> Date: Tue Apr 30 13:26:04 2019 +0200 Merge branch 'develop' into issue/autoscroll-on-list-block commit 61b52cb Author: etoledom <[email protected]> Date: Tue Apr 30 13:25:10 2019 +0200 Update gutenberg ref to master commit 57c8de0 Author: Stefanos Togkoulidis <[email protected]> Date: Fri Apr 26 15:13:02 2019 +0300 Use a git tag to try please JitPack commit ab4f3e3 Author: Stefanos Togkoulidis <[email protected]> Date: Fri Apr 26 15:07:33 2019 +0300 Use shortened hash version to try please JitPack commit ce92f47 Author: Stefanos Togkoulidis <[email protected]> Date: Fri Apr 26 14:43:16 2019 +0300 Update Aztec ref commit 7897f98 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 16:07:12 2019 +0300 Update Aztec ref commit 76678c9 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 15:13:06 2019 +0300 Minimize diff commit cd97945 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 13:03:12 2019 +0300 Update GB hash commit c3f094a Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 12:44:16 2019 +0300 Update GB hash commit 7391049 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 12:02:19 2019 +0300 Update GB hash commit 70112bf Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 04:11:43 2019 +0300 Update GB hash commit 91c222e Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 03:21:56 2019 +0300 Update GB hash to use iOS regression fixes commit 1786fab Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 03:20:19 2019 +0300 Use simplified access to EnterPressedUnderway commit 166b206 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 03:15:37 2019 +0300 Remove temporary code commit d17e5d2 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 02:05:01 2019 +0300 Use Aztec ref with the Enter processing fix commit bbda142 Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 02:00:41 2019 +0300 Use the GB hash with the rich-text fix commit 8889b8d Author: Stefanos Togkoulidis <[email protected]> Date: Thu Apr 25 01:58:58 2019 +0300 Don't emit text changed event when Enter detected The Enter event (ReactAztecEnterEvent) will have the text that the RN side needs to process through the format-lib and hopefully match Aztec's processing. commit 38cdc59 Author: Stefanos Togkoulidis <[email protected]> Date: Tue Apr 23 11:54:54 2019 +0300 Use passed selection when Enter already altered text commit 2372231 Author: Stefanos Togkoulidis <[email protected]> Date: Tue Apr 23 10:11:51 2019 +0300 Signal if text has already been changed commit 1a4f344 Author: etoledom <[email protected]> Date: Fri Apr 19 18:14:16 2019 +0200 Update gutenberg ref commit abc09d1 Merge: c6ca773 0be0fa2 Author: etoledom <[email protected]> Date: Fri Apr 19 17:49:27 2019 +0200 Merge branch 'develop' into issue/autoscroll-on-list-block commit c6ca773 Author: etoledom <[email protected]> Date: Fri Apr 19 17:49:17 2019 +0200 Update gutenberg ref commit a521284 Author: etoledom <[email protected]> Date: Thu Apr 18 17:01:53 2019 +0200 Update gutenberg ref
Generated by 🚫 dangerJS |
Tried out 95f7d9a and there's an event loop happening (apparently). It happens in various cases when typing but managed to capture one when typing and deleting some text in a paragraph: I think the "key" detail in order to replicate is to have some typing/deleting happening fast enough and then the issue arises. |
EDIT: Fixed by WordPress/gutenberg@cc12da7 and WordPress/gutenberg@1421cdd Testing on iOS I found a strange behavior with the list block:
I was able to reproduce the same behavior on Android. |
Tests run by using Google Board on my Nexus 5X running Android 7.1 Test 1 Test 2 |
Steps to repro a merge problem:
|
We've been working on some fixes and @etoledom and I have some commits to share. Will merge to this branch now. |
EDIT: Fixed by WordPress/gutenberg@86894ea Found an issue on split (iOS and Android): Steps to reproduce:
|
I noticed a minor(?) problem when trying to remove a block by tapping
This seems like a minor issue, but better to not underestimate it, since it may uncover other issues we're missing from testing. |
Will now merge the branches with the fixes I was working on over the last few days, so we can coordinate on a single branch/PR. |
There's an undo bug where an extra character is appearing, which is a web-side issue. Tracked in WordPress/gutenberg#15619. |
The undo issue reported by @daniloercoli in #949 (comment) is happening on the web too (I tried https://frontenberg.tomjn.com/ as well as local WP on GB hash eea04cf and happens there too) so, not a native mobile related issue. |
I found some odd things splitting lists and trying to undo the changes:
|
@@ -84,6 +84,8 @@ | |||
public ReactAztecText(ThemedReactContext reactContext) { | |||
super(reactContext); | |||
|
|||
setGutenbergMode(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @Tug @hypest I have tried to test WPAndroid against this PR and it's crashing with this error: java.lang.NoSuchMethodError: No virtual method setGutenbergMode(Z)V in class Lorg/wordpress/mobile/ReactNativeAztec/ReactAztecText
...... I have realized that I forgot to update aztecVersion on WPAndroid, so everything is ok :)
This seems to be fixed by: #973
Just tested this and it's working good now! 🎉 EDIT: Fixed by WordPress/gutenberg@50527d3 With the last updates, I found a small issue on iOS: Sometimes the formats won't go away by pressing the format buttons. It's easiest to reproduce in the lists block, but it also happens in paragraph. I couldn't reproduce it in Android, just iOS:
|
The format library doesn't seem to recognize bold with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!! 🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
!
Gutenberg PR: WordPress/gutenberg#15392
This fixes RichText errors on merge and split.
Most of the work is in the GB PR.
Important fix in this PR:
clearSelectedBlock
on focus that would reset the block selection and thus cause error in the MERGE_BLOCKS effect that need it initializedOther fixes:
mergeBlocks
inBlockHolder
to be closer to the web versionTesting Instructions (on both Android and iOS)