forked from react-native-component/react-native-smart-badge
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor PropTypes and move from View.propTypes to ViewPropTypes due …
…to deprecated APIs breaking from RN 0.49 on; Update README to state new minimum RN version for lib; this fixes react-native-component#5
- Loading branch information
Showing
2 changed files
with
6 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,14 +5,13 @@ | |
* Copyright (c) 2016 react-native-component <[email protected]> | ||
*/ | ||
|
||
import React, { | ||
Component, | ||
PropTypes, | ||
} from 'react' | ||
import React, { Component } from 'react'; | ||
import { PropTypes } from 'prop-types'; | ||
import { | ||
View, | ||
Text, | ||
StyleSheet, | ||
ViewPropTypes | ||
} from 'react-native' | ||
|
||
const styles = StyleSheet.create({ | ||
|
@@ -45,7 +44,7 @@ export default class Badge extends Component { | |
static propTypes = { | ||
//borderRadius: PropTypes.number, //number 18, null 5 | ||
extraPaddingHorizontal: PropTypes.number, | ||
style: View.propTypes.style, | ||
style: ViewPropTypes.style, | ||
textStyle: Text.propTypes.style, | ||
minHeight: PropTypes.number, | ||
minWidth: PropTypes.number, | ||
|
@@ -104,4 +103,4 @@ export default class Badge extends Component { | |
}); | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters