Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds arrowDirection prop #17

Merged
merged 6 commits into from
Jun 10, 2016
Merged

Conversation

imartingraham
Copy link
Contributor

This adds the ability to declare where the ToolTip displays

longPress: React.PropTypes.bool,
...TouchableHighlight.propTypes,
};

var ViewClass = React.createClass({
showMenu: function() {
ToolTipMenu.show(findNodeHandle(this.refs.toolTipText), this.getOptionTexts());
ToolTipMenu.show(findNodeHandle(this.refs.toolTipText), this.getOptionTexts(), this.props.arrowDirection || 'down');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can use defaultProps for this

@jrichardlai
Copy link
Collaborator

Thanks for the PR, can you update the doc too?

@imartingraham
Copy link
Contributor Author

@jrichardlai Updated the documentation, PropType declaration and set the defaultProp value for arrowDirection

longPress: React.PropTypes.bool,
...TouchableHighlight.propTypes,
};

var ViewClass = React.createClass({
getDefaultProps: function() {
return {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you use 2 spaces here :)!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All fixed!

@jrichardlai
Copy link
Collaborator

Thanks!

@jrichardlai jrichardlai merged commit d101571 into chirag04:master Jun 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants