Skip to content

Instantly share code, notes, and snippets.

@gaearon
Created August 15, 2014 15:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gaearon/9c617a16d8c64cbdab6a to your computer and use it in GitHub Desktop.
Save gaearon/9c617a16d8c64cbdab6a to your computer and use it in GitHub Desktop.
var Popover = React.createClass({
mixins: [ClassNameMixin],
className: 'Popover',
propTypes: {
anchorOffset: React.PropTypes.oneOf(['normal', 'fromRoundBtn', 'fromSmallRoundBtn']),
expandFrom: React.PropTypes.shape({
horizontal: React.PropTypes.oneOf(['left', 'center', 'right']).isRequired,
vertical: React.PropTypes.oneOf(['top', 'bottom']).isRequired
}),
body: React.PropTypes.component.isRequired,
title: React.PropTypes.renderable,
subtitle: React.PropTypes.renderable,
onClose: React.PropTypes.func.isRequired,
fromEl: React.PropTypes.shape({
getBoundingClientRect: React.PropTypes.func.isRequired
}).isRequired
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment