diff --git a/package-lock.json b/package-lock.json index 3c83cf4d2998c..dffe10eb527e8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14589,7 +14589,7 @@ "react-native-hsv-color-picker": "git+https://github.com/wordpress-mobile/react-native-hsv-color-picker.git#dfe4d06595fefc9b4d48ce0ced029076c80dab74", "react-native-keyboard-aware-scroll-view": "git+https://github.com/wordpress-mobile/react-native-keyboard-aware-scroll-view.git#6febe4faf7ff51579087bac105f62be8e4c4015d", "react-native-linear-gradient": "git+https://github.com/wordpress-mobile/react-native-linear-gradient.git#deafc7a7b3dcfdc2a2d8327b5727cb393f1cabf7", - "react-native-modal": "^6.5.0", + "react-native-modal": "^11.10.0", "react-native-prompt-android": "git+https://github.com/wordpress-mobile/react-native-prompt-android.git#6406b77d0162262c868bcbbaa0766bfafbf43742", "react-native-reanimated": "git+https://github.com/wordpress-mobile/react-native-reanimated.git#047ae6064e2bcfdaeb1f25d1d38157359ba96cb6", "react-native-safe-area": "^0.5.0", @@ -50370,12 +50370,12 @@ "from": "git+https://github.com/wordpress-mobile/react-native-linear-gradient.git#deafc7a7b3dcfdc2a2d8327b5727cb393f1cabf7" }, "react-native-modal": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/react-native-modal/-/react-native-modal-6.5.0.tgz", - "integrity": "sha512-ewchdETAGd32xLGLK93NETEGkRcePtN7ZwjmLSQnNW1Zd0SRUYE8NqftjamPyfKvK0i2DZjX4YAghGZTqaRUbA==", + "version": "11.10.0", + "resolved": "https://registry.npmjs.org/react-native-modal/-/react-native-modal-11.10.0.tgz", + "integrity": "sha512-syRYDJYSh16bR37R5EKU9T/wC+5bEOfF17IUqf5URdhbEDd+hxyMInC++l45E8oI+MtdOaEp9yAws5xDqk8dnA==", "requires": { - "prop-types": "^15.6.1", - "react-native-animatable": "^1.2.4" + "prop-types": "^15.6.2", + "react-native-animatable": "1.3.3" } }, "react-native-prompt-android": { diff --git a/packages/block-editor/src/components/floating-toolbar/index.native.js b/packages/block-editor/src/components/floating-toolbar/index.native.js index 50fce7857ff59..f4ebf1d9ebe8d 100644 --- a/packages/block-editor/src/components/floating-toolbar/index.native.js +++ b/packages/block-editor/src/components/floating-toolbar/index.native.js @@ -6,7 +6,7 @@ import { Animated, Easing, View, Platform } from 'react-native'; /** * WordPress dependencies */ -import { ToolbarButton, Toolbar } from '@wordpress/components'; +import { ToolbarButton, ToolbarGroup } from '@wordpress/components'; import { useEffect, useState, useRef } from '@wordpress/element'; import { withSelect, withDispatch } from '@wordpress/data'; import { compose } from '@wordpress/compose'; @@ -83,7 +83,7 @@ const FloatingToolbar = ( { pointerEvents={ showFloatingToolbar ? 'auto' : 'none' } > { showNavUpButton && ( - + } /> - + ) } { + AccessibilityInfo.isScreenReaderEnabled().done( ( isEnabled ) => { if ( isEnabled ) { const isIOS = Platform.OS === 'ios'; const announcement = isOpen diff --git a/packages/block-editor/src/components/ungroup-button/index.native.js b/packages/block-editor/src/components/ungroup-button/index.native.js index 1e2b7ad4df893..65180144ba2ed 100644 --- a/packages/block-editor/src/components/ungroup-button/index.native.js +++ b/packages/block-editor/src/components/ungroup-button/index.native.js @@ -7,7 +7,7 @@ import { noop } from 'lodash'; * WordPress dependencies */ import { store as blocksStore } from '@wordpress/blocks'; -import { Toolbar, ToolbarButton } from '@wordpress/components'; +import { ToolbarGroup, ToolbarButton } from '@wordpress/components'; import { __ } from '@wordpress/i18n'; import { withSelect, withDispatch } from '@wordpress/data'; import { compose } from '@wordpress/compose'; @@ -23,13 +23,13 @@ export function UngroupButton( { onConvertFromGroup, isUngroupable = false } ) { return null; } return ( - + - + ); } diff --git a/packages/components/src/focal-point-picker/index.native.js b/packages/components/src/focal-point-picker/index.native.js index ba81919c1a054..3d9547bdb4eb1 100644 --- a/packages/components/src/focal-point-picker/index.native.js +++ b/packages/components/src/focal-point-picker/index.native.js @@ -92,10 +92,10 @@ function FocalPointPicker( props ) { pan.extractOffset(); // Set offset to current value }, // Move cursor to match delta drag - onPanResponderMove: Animated.event( [ - null, - { dx: pan.x, dy: pan.y }, - ] ), + onPanResponderMove: Animated.event( + [ null, { dx: pan.x, dy: pan.y } ], + { useNativeDriver: false } + ), onPanResponderRelease: ( event ) => { shouldEnableBottomSheetScroll( true ); pan.flattenOffset(); // Flatten offset into value diff --git a/packages/components/src/mobile/bottom-sheet/index.native.js b/packages/components/src/mobile/bottom-sheet/index.native.js index b026bd36c3d90..6848b6863e473 100644 --- a/packages/components/src/mobile/bottom-sheet/index.native.js +++ b/packages/components/src/mobile/bottom-sheet/index.native.js @@ -495,7 +495,7 @@ class BottomSheet extends Component { backdropOpacity={ 0.2 } onBackdropPress={ this.onCloseBottomSheet } onBackButtonPress={ this.onHardwareButtonPress } - onSwipe={ this.onCloseBottomSheet } + onSwipeComplete={ this.onCloseBottomSheet } onDismiss={ Platform.OS === 'ios' ? this.onDismiss : undefined } onModalHide={ Platform.OS === 'android' ? this.onDismiss : undefined diff --git a/packages/edit-post/src/components/header/header-toolbar/index.native.js b/packages/edit-post/src/components/header/header-toolbar/index.native.js index 903f8c0a8fee6..4f02824fb8baa 100644 --- a/packages/edit-post/src/components/header/header-toolbar/index.native.js +++ b/packages/edit-post/src/components/header/header-toolbar/index.native.js @@ -16,7 +16,7 @@ import { BlockToolbar, store as blockEditorStore, } from '@wordpress/block-editor'; -import { Toolbar, ToolbarButton } from '@wordpress/components'; +import { ToolbarGroup, ToolbarButton } from '@wordpress/components'; import { keyboardClose, undo as undoIcon, @@ -94,7 +94,7 @@ function HeaderToolbar( { { showKeyboardHideButton && ( - + - + ) } ); diff --git a/packages/edit-post/src/components/visual-editor/index.native.js b/packages/edit-post/src/components/visual-editor/index.native.js index 82ea41896894d..886e56e493938 100644 --- a/packages/edit-post/src/components/visual-editor/index.native.js +++ b/packages/edit-post/src/components/visual-editor/index.native.js @@ -24,7 +24,7 @@ export default class VisualEditor extends Component { }; } - componentWillMount() { + componentDidMount() { this.keyboardDidShow = Keyboard.addListener( 'keyboardDidShow', this.keyboardDidShow diff --git a/packages/react-native-editor/package.json b/packages/react-native-editor/package.json index 7e37526eb26f9..610078d40c323 100644 --- a/packages/react-native-editor/package.json +++ b/packages/react-native-editor/package.json @@ -62,7 +62,7 @@ "react-native-hsv-color-picker": "git+https://github.com/wordpress-mobile/react-native-hsv-color-picker#dfe4d06595fefc9b4d48ce0ced029076c80dab74", "react-native-keyboard-aware-scroll-view": "git+https://github.com/wordpress-mobile/react-native-keyboard-aware-scroll-view.git#6febe4faf7ff51579087bac105f62be8e4c4015d", "react-native-linear-gradient": "git+https://github.com/wordpress-mobile/react-native-linear-gradient.git#deafc7a7b3dcfdc2a2d8327b5727cb393f1cabf7", - "react-native-modal": "^6.5.0", + "react-native-modal": "^11.10.0", "react-native-prompt-android": "git+https://github.com/wordpress-mobile/react-native-prompt-android.git#6406b77d0162262c868bcbbaa0766bfafbf43742", "react-native-reanimated": "git+https://github.com/wordpress-mobile/react-native-reanimated.git#047ae6064e2bcfdaeb1f25d1d38157359ba96cb6", "react-native-safe-area": "^0.5.0", diff --git a/patches/metro+0.64.0.patch b/patches/metro+0.64.0.patch new file mode 100644 index 0000000000000..249ae5cecd324 --- /dev/null +++ b/patches/metro+0.64.0.patch @@ -0,0 +1,13 @@ +diff --git a/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js b/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js +index 5f32fc5..2b80fda 100644 +--- a/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js ++++ b/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js +@@ -346,7 +346,7 @@ class UnableToResolveError extends Error { + try { + file = fs.readFileSync(this.originModulePath, "utf8"); + } catch (error) { +- if (error.code === "ENOENT") { ++ if (error.code === "ENOENT" || error.code === 'EISDIR') { + // We're probably dealing with a virtualised file system where + // `this.originModulePath` doesn't actually exist on disk. + // We can't show a code frame, but there's no need to let this I/O