Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Adrien Thiery committed May 10, 2021
1 parent fbbbc8d commit 6e0ded3
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
16 changes: 10 additions & 6 deletions OpenGraphAwareInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,24 +73,28 @@ export default class OpenGraphAwareInput extends Component<Props, State> {
0,
this.props.resultLimit
);

const { containerStyle, iconStyle, iconSource, onIconPress, showIcon, textInputStyle, ...rest } = this.props;

return (
<View style={[styles.container, this.props.containerStyle]}>
<View style={[styles.container, containerStyle]}>
<TextInput
onChange={this.handleTextInputChange}
style={[styles.input, this.props.textInputStyle]}
style={[styles.input, textInputStyle]}
{...rest}
/>
{ogDataToDisplay.map((meta, i) => (
<OpenGraphDisplay
key={i}
data={meta}
onIconPress={
this.props.showIcon
? this.props.onIconPress
showIcon
? onIconPress
|| this.handleDismissOpengraph
: null
}
iconSource={this.props.iconSource}
iconStyle={this.props.iconStyle}
iconSource={iconSource}
iconStyle={iconStyle}
/>
))}
</View>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "A set of components and utils useful to extract opengraph data directly from your react-native app",
"main": "index.js",
"scripts": {
"test": "mocha --compilers js:babel-core/register --reporter spec"
"test": "mocha --require babel-core/register --reporter spec"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit 6e0ded3

Please sign in to comment.