-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
[RNMobile] Fix ShouldInsertAtTheTop
setting calculation
#32110
Conversation
Size Change: -36 B (0%) Total Size: 1.86 MB
ℹ️ View Unchanged
|
Hey @fluiddot 👋 I was doing some testing and found an issue where after finishing the testing steps, if I select the second block and try to add a new one the TestiOS.mov |
I experienced that too but I don't think it's related to these changes because it can be also reproduced on production (I tested on version WPiOS EDIT: If you type after selecting a paragraph block then the insertion point is correct 🤷♂️ . |
You're right, I checked it and it's the same. Alright, we should open an issue to track it 😄 One question, does it work for you on Android? It is not working for me but I wanna double-check is not an issue on my side and the local build: AndroidTest.mov |
Ok, I'll open an issue as soon as possible.
Nope, it doesn't work either for me, it's happening the same as on iOS. After selecting the title, it always shows the insertion point at the beginning of the post. |
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! It brings back the functionality we had before.
@geriux could you take a look at the GB-mobile PR related to this one? Thanks 🙇 ! |
I've just opened this issue with the problem you spotted, thanks for your help 🙇 ! |
gutenberg-mobile
PR: wordpress-mobile/gutenberg-mobile#3538Description
When the title is selected, we enforce the insertion point to be
index: 0
by a setting named__experimentalShouldInsertAtTheTop
(code reference). This setting was being calculated inuseBlockEditorSettings
but after the changes introduced in the reusable block PR, now the settings specific to the native version are calculated and memoized in the native version ofuseBlockEditorSettings
so as the setting wasn't included then the value never updates.This PR basically moves the calculation of
__experimentalShouldInsertAtTheTop
to the native version ofuseBlockEditorSettings
.How has this been tested?
Screenshots
insertion-point-test.mp4
Types of changes
Bug fix
Checklist:
*.native.js
files for terms that need renaming or removal).