123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347 |
- /**
- * Copyright (c) Facebook, Inc. and its affiliates.
- *
- * This source code is licensed under the MIT license found in the
- * LICENSE file in the root directory of this source tree.
- *
- * @flow
- * @format
- */
- 'use strict';
- import ReactNativeViewViewConfigAndroid from './ReactNativeViewViewConfigAndroid';
- import {Platform} from 'react-native';
- const ReactNativeViewConfig = {
- uiViewClassName: 'RCTView',
- baseModuleName: null,
- Manager: 'ViewManager',
- Commands: ({}: {...}),
- Constants: ({}: {...}),
- bubblingEventTypes: {
- ...ReactNativeViewViewConfigAndroid.bubblingEventTypes,
- topBlur: {
- phasedRegistrationNames: {
- bubbled: 'onBlur',
- captured: 'onBlurCapture',
- },
- },
- topChange: {
- phasedRegistrationNames: {
- bubbled: 'onChange',
- captured: 'onChangeCapture',
- },
- },
- topEndEditing: {
- phasedRegistrationNames: {
- bubbled: 'onEndEditing',
- captured: 'onEndEditingCapture',
- },
- },
- topFocus: {
- phasedRegistrationNames: {
- bubbled: 'onFocus',
- captured: 'onFocusCapture',
- },
- },
- topKeyPress: {
- phasedRegistrationNames: {
- bubbled: 'onKeyPress',
- captured: 'onKeyPressCapture',
- },
- },
- topPress: {
- phasedRegistrationNames: {
- bubbled: 'onPress',
- captured: 'onPressCapture',
- },
- },
- topSubmitEditing: {
- phasedRegistrationNames: {
- bubbled: 'onSubmitEditing',
- captured: 'onSubmitEditingCapture',
- },
- },
- topTouchCancel: {
- phasedRegistrationNames: {
- bubbled: 'onTouchCancel',
- captured: 'onTouchCancelCapture',
- },
- },
- topTouchEnd: {
- phasedRegistrationNames: {
- bubbled: 'onTouchEnd',
- captured: 'onTouchEndCapture',
- },
- },
- topTouchMove: {
- phasedRegistrationNames: {
- bubbled: 'onTouchMove',
- captured: 'onTouchMoveCapture',
- },
- },
- topTouchStart: {
- phasedRegistrationNames: {
- bubbled: 'onTouchStart',
- captured: 'onTouchStartCapture',
- },
- },
- },
- directEventTypes: {
- ...ReactNativeViewViewConfigAndroid.directEventTypes,
- topAccessibilityAction: {
- registrationName: 'onAccessibilityAction',
- },
- topAccessibilityEscape: {
- registrationName: 'onAccessibilityEscape',
- },
- topAccessibilityTap: {
- registrationName: 'onAccessibilityTap',
- },
- topLayout: {
- registrationName: 'onLayout',
- },
- topMagicTap: {
- registrationName: 'onMagicTap',
- },
- // Events for react-native-gesture-handler (T45765076)
- // Remove once this library can handle JS View Configs
- onGestureHandlerEvent: {
- registrationName: 'onGestureHandlerEvent',
- },
- onGestureHandlerStateChange: {
- registrationName: 'onGestureHandlerStateChange',
- },
- },
- validAttributes: {
- ...ReactNativeViewViewConfigAndroid.validAttributes,
- accessibilityActions: true,
- accessibilityElementsHidden: true,
- accessibilityHint: true,
- accessibilityIgnoresInvertColors: true,
- accessibilityLabel: true,
- accessibilityLiveRegion: true,
- accessibilityRole: true,
- accessibilityStates: true, // TODO: Can be removed after next release
- accessibilityState: true,
- accessibilityValue: true,
- accessibilityViewIsModal: true,
- accessible: true,
- alignContent: true,
- alignItems: true,
- alignSelf: true,
- aspectRatio: true,
- backfaceVisibility: true,
- backgroundColor: {process: require('../../StyleSheet/processColor')},
- borderBottomColor: {process: require('../../StyleSheet/processColor')},
- borderBottomEndRadius: true,
- borderBottomLeftRadius: true,
- borderBottomRightRadius: true,
- borderBottomStartRadius: true,
- borderBottomWidth: true,
- borderColor: {process: require('../../StyleSheet/processColor')},
- borderEndColor: {process: require('../../StyleSheet/processColor')},
- borderEndWidth: true,
- borderLeftColor: {process: require('../../StyleSheet/processColor')},
- borderLeftWidth: true,
- borderRadius: true,
- borderRightColor: {process: require('../../StyleSheet/processColor')},
- borderRightWidth: true,
- borderStartColor: {process: require('../../StyleSheet/processColor')},
- borderStartWidth: true,
- borderStyle: true,
- borderTopColor: {process: require('../../StyleSheet/processColor')},
- borderTopEndRadius: true,
- borderTopLeftRadius: true,
- borderTopRightRadius: true,
- borderTopStartRadius: true,
- borderTopWidth: true,
- borderWidth: true,
- bottom: true,
- clickable: true,
- collapsable: true,
- direction: true,
- display: true,
- elevation: true,
- end: true,
- flex: true,
- flexBasis: true,
- flexDirection: true,
- flexGrow: true,
- flexShrink: true,
- flexWrap: true,
- height: true,
- hitSlop: {diff: (require('../../Utilities/differ/insetsDiffer'): any)},
- importantForAccessibility: true,
- justifyContent: true,
- left: true,
- margin: true,
- marginBottom: true,
- marginEnd: true,
- marginHorizontal: true,
- marginLeft: true,
- marginRight: true,
- marginStart: true,
- marginTop: true,
- marginVertical: true,
- maxHeight: true,
- maxWidth: true,
- minHeight: true,
- minWidth: true,
- nativeID: true,
- needsOffscreenAlphaCompositing: true,
- onAccessibilityAction: true,
- onAccessibilityEscape: true,
- onAccessibilityTap: true,
- onLayout: true,
- onMagicTap: true,
- opacity: true,
- overflow: true,
- padding: true,
- paddingBottom: true,
- paddingEnd: true,
- paddingHorizontal: true,
- paddingLeft: true,
- paddingRight: true,
- paddingStart: true,
- paddingTop: true,
- paddingVertical: true,
- pointerEvents: true,
- position: true,
- removeClippedSubviews: true,
- renderToHardwareTextureAndroid: true,
- right: true,
- rotation: true,
- scaleX: true,
- scaleY: true,
- shadowColor: {process: require('../../StyleSheet/processColor')},
- shadowOffset: {diff: require('../../Utilities/differ/sizesDiffer')},
- shadowOpacity: true,
- shadowRadius: true,
- shouldRasterizeIOS: true,
- start: true,
- style: {
- alignContent: true,
- alignItems: true,
- alignSelf: true,
- aspectRatio: true,
- backfaceVisibility: true,
- backgroundColor: {process: require('../../StyleSheet/processColor')},
- borderBottomColor: {process: require('../../StyleSheet/processColor')},
- borderBottomEndRadius: true,
- borderBottomLeftRadius: true,
- borderBottomRightRadius: true,
- borderBottomStartRadius: true,
- borderBottomWidth: true,
- borderColor: {process: require('../../StyleSheet/processColor')},
- borderEndColor: {process: require('../../StyleSheet/processColor')},
- borderEndWidth: true,
- borderLeftColor: {process: require('../../StyleSheet/processColor')},
- borderLeftWidth: true,
- borderRadius: true,
- borderRightColor: {process: require('../../StyleSheet/processColor')},
- borderRightWidth: true,
- borderStartColor: {process: require('../../StyleSheet/processColor')},
- borderStartWidth: true,
- borderStyle: true,
- borderTopColor: {process: require('../../StyleSheet/processColor')},
- borderTopEndRadius: true,
- borderTopLeftRadius: true,
- borderTopRightRadius: true,
- borderTopStartRadius: true,
- borderTopWidth: true,
- borderWidth: true,
- bottom: true,
- color: {process: require('../../StyleSheet/processColor')},
- decomposedMatrix: true,
- direction: true,
- display: true,
- elevation: true,
- end: true,
- flex: true,
- flexBasis: true,
- flexDirection: true,
- flexGrow: true,
- flexShrink: true,
- flexWrap: true,
- fontFamily: true,
- fontSize: true,
- fontStyle: true,
- fontVariant: true,
- fontWeight: true,
- height: true,
- includeFontPadding: true,
- justifyContent: true,
- left: true,
- letterSpacing: true,
- lineHeight: true,
- margin: true,
- marginBottom: true,
- marginEnd: true,
- marginHorizontal: true,
- marginLeft: true,
- marginRight: true,
- marginStart: true,
- marginTop: true,
- marginVertical: true,
- maxHeight: true,
- maxWidth: true,
- minHeight: true,
- minWidth: true,
- opacity: true,
- overflow: true,
- overlayColor: {process: require('../../StyleSheet/processColor')},
- padding: true,
- paddingBottom: true,
- paddingEnd: true,
- paddingHorizontal: true,
- paddingLeft: true,
- paddingRight: true,
- paddingStart: true,
- paddingTop: true,
- paddingVertical: true,
- position: true,
- resizeMode: true,
- right: true,
- rotation: true,
- scaleX: true,
- scaleY: true,
- shadowColor: {process: require('../../StyleSheet/processColor')},
- shadowOffset: {diff: require('../../Utilities/differ/sizesDiffer')},
- shadowOpacity: true,
- shadowRadius: true,
- start: true,
- textAlign: true,
- textAlignVertical: true,
- textDecorationColor: {process: require('../../StyleSheet/processColor')},
- textDecorationLine: true,
- textDecorationStyle: true,
- textShadowColor: {process: require('../../StyleSheet/processColor')},
- textShadowOffset: true,
- textShadowRadius: true,
- textTransform: true,
- tintColor: {process: require('../../StyleSheet/processColor')},
- top: true,
- transform: ((Platform.OS === 'ios'
- ? {diff: require('../../Utilities/differ/matricesDiffer')}
- : {process: require('../../StyleSheet/processTransform')}): any),
- transformMatrix: true,
- translateX: true,
- translateY: true,
- width: true,
- writingDirection: true,
- zIndex: true,
- },
- testID: true,
- top: true,
- transform: ((Platform.OS === 'ios'
- ? {diff: require('../../Utilities/differ/matricesDiffer')}
- : {process: require('../../StyleSheet/processTransform')}): any),
- translateX: true,
- translateY: true,
- width: true,
- zIndex: true,
- },
- };
- module.exports = ReactNativeViewConfig;
|