-
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
Native support for BlockList #14662
Native support for BlockList #14662
Conversation
@@ -15,6 +15,9 @@ import * as more from './more'; | |||
import * as paragraph from './paragraph'; | |||
import * as image from './image'; | |||
import * as nextpage from './nextpage'; | |||
import * as UnsupportedBlock from './mobile/unsupported-block'; |
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.
I'm wondering whether it should be moved to gutenberg-mobile
project. It's something that is specific only to the mobile project so doesn't quite makes sense here as it doesn't have web alternative.
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.
#14577 's goal is to actually rename unsupported-block
to missing
, so we are in sync with the web part. I agree it might look confusing to have a rnmobile only block in the core block library but it isn't exposed to the web version and I think it's only temporary. We need those dependencies in gutenberg
as they are required by other part of the code, see https://github.com/WordPress/gutenberg/pull/14662/files#diff-61ba183209a287f5b2da76defa6e20fbR7 and https://github.com/WordPress/gutenberg/pull/14662/files#diff-8aa4726165b0e0cdb260abe61e3329ceR10 for instance.
Moreover, our goal is to actually move most of the gutenberg-mobile
JS code to the gutenberg project, so keeping "unrelated to the web" code out of the gutenberg
repo isn't compatible with this approach
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.
#14577 's goal is to actually rename
unsupported-block
tomissing
, so we are in sync with the web part.
This would be awesome and exactly addresses my point.
5d3fcac
to
fed27ef
Compare
Rebased ontop of master and brought latest changes from gutenberg-mobile. |
76661f1
to
a595f33
Compare
e350f06
to
3d29632
Compare
3d29632
to
61128c0
Compare
Closing this PR. Progress of this is now being monitored on wordpress-mobile/gutenberg-mobile#958 |
Description
This PR adds native support for BlockList and various related components. It basically ports our block management code from
gutenberg-mobile
togutenberg
.This is a first step towards having inner block support in native.
Here is the list of components which now have native/rnmobile support:
BlockList
(ported fromBlockManager
https://github.com/wordpress-mobile/gutenberg-mobile/blob/develop/src/block-management/block-manager.js)BlockListBlock
(ported fromBlockHolder
https://github.com/wordpress-mobile/gutenberg-mobile/blob/develop/src/block-management/block-holder.js)Inserter
(ported fromBlockPicker
https://github.com/wordpress-mobile/gutenberg-mobile/blob/develop/src/block-management/block-picker.js)BlockInspector
(ported fromInlineToolbar
https://github.com/wordpress-mobile/gutenberg-mobile/blob/develop/src/block-management/inline-toolbar/index.js)BlockToolbar
(ported fromBlockToolbar
https://github.com/wordpress-mobile/gutenberg-mobile/blob/develop/src/block-management/block-toolbar.js)It also port some mobile specific components and add them to
packages/components/src/mobile/
:KeyboardAvoidingView
,KeyboardAwareFlatList
andReadableContentView
(ported from https://github.com/wordpress-mobile/gutenberg-mobile/tree/develop/src/components)BottomSheet
andPicker
from (moved frompackage/block-editor/src/components/mobile/
) since those are not specific to the BlockEditorHow has this been tested?
More details of the changes and testing instructions are given on the gubenberg-mobile PR:
wordpress-mobile/gutenberg-mobile#789