Skip to content

Props Types depreciated  #58

@Gnative

Description

@Gnative

In case anyone comes looking here is a patch-package for React Natives removal of PropTypes

diff --git a/node_modules/react-native-settings-list/index.js b/node_modules/react-native-settings-list/index.js
index 00e7242..0c61679 100644
--- a/node_modules/react-native-settings-list/index.js
+++ b/node_modules/react-native-settings-list/index.js
@@ -12,19 +12,19 @@ import {
   ScrollView,
   TextInput,
   Switch,
-  Image,
-  ViewPropTypes
+  Image
 } from 'react-native';
-
+import { ImagePropTypes, TextPropTypes, ViewPropTypes } from 'deprecated-react-native-prop-types'
 const ARROW_ICON = require('./img/icon-arrow-settings.png');
 
+console.log('Settings', ViewPropTypes.style)
 class SettingsList extends React.Component {
   static propTypes = {
     backgroundColor: PropTypes.string,
     borderColor: PropTypes.string,
     defaultItemSize: PropTypes.number,
     underlayColor: PropTypes.string,
-    defaultTitleStyle: Text.propTypes.style,
+    defaultTitleStyle: TextPropTypes.style,
     defaultTitleInfoPosition: PropTypes.string,
     scrollViewProps: PropTypes.object,
   };
@@ -276,7 +276,7 @@ const styles = StyleSheet.create({
 SettingsList.Header = createReactClass({
   propTypes: {
     headerText: PropTypes.string,
-    headerStyle: Text.propTypes.style,
+    headerStyle: TextPropTypes.style,
     headerRef: PropTypes.func,
     headerNumberOfLines: PropTypes.number,
   },
@@ -302,7 +302,7 @@ SettingsList.Item = createReactClass({
      * Title being displayed
      */
     title: PropTypes.string,
-    titleStyle: Text.propTypes.style,
+    titleStyle: TextPropTypes.style,
     /**
      * Icon displayed on the left of the settings item
      */
@@ -323,7 +323,7 @@ SettingsList.Item = createReactClass({
     /**
      * Editable Right Side Style
      */
-    editableTextStyle: Text.propTypes.style,
+    editableTextStyle: TextPropTypes.style,
 
     /**
      * Individual item width.  Can be globally set in the parent.  Will become deprecated
@@ -358,7 +358,7 @@ SettingsList.Item = createReactClass({
     hasNavArrow: PropTypes.bool,
     arrowIcon: PropTypes.node,
 
-    arrowStyle: Image.propTypes.style,
+    arrowStyle: ImagePropTypes.style,
     /**
      * Enable or disable a Switch component
      */
@@ -379,7 +379,7 @@ SettingsList.Item = createReactClass({
      * Right side information on the setting item
      */
     titleInfo: PropTypes.string,
-    titleInfoStyle: Text.propTypes.style,
+    titleInfoStyle: TextPropTypes.style,
     /**
      * If 'Bottom', info is placed beneath the title
      */

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions