diff --git a/packages/block-library/src/image/edit.native.js b/packages/block-library/src/image/edit.native.js index ab7af710e4e6dc..fde82c5a717770 100644 --- a/packages/block-library/src/image/edit.native.js +++ b/packages/block-library/src/image/edit.native.js @@ -7,7 +7,9 @@ import RNReactNativeGutenbergBridge from 'react-native-gutenberg-bridge'; /** * Internal dependencies */ -import { MediaPlaceholder, RichText } from '@wordpress/editor'; +import { MediaPlaceholder, RichText, BlockControls } from '@wordpress/editor'; +import { Toolbar, IconButton } from '@wordpress/components'; +import { __ } from '@wordpress/i18n'; export default function ImageEdit( props ) { const { attributes, isSelected, setAttributes } = props; @@ -20,8 +22,6 @@ export default function ImageEdit( props ) { }; const onMediaLibraryPress = () => { - // Call onMediaLibraryPress from the Native<->RN bridge. It should trigger an image picker from - // the WordPress media library and call the provided callback to set the image URL. RNReactNativeGutenbergBridge.onMediaLibraryPress( ( mediaUrl ) => { if ( mediaUrl ) { setAttributes( { url: mediaUrl } ); @@ -38,8 +38,22 @@ export default function ImageEdit( props ) { ); } + const toolbarEditButton = ( + + + + ); + return ( + + { toolbarEditButton } +