Skip to content

Commit

Permalink
Merge pull request #162 from wwayne/fix
Browse files Browse the repository at this point in the history
Fix for #158, getposition error
  • Loading branch information
wwayne authored Jul 30, 2016
2 parents 9fe3f0b + 3b95275 commit a90c76a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
6 changes: 2 additions & 4 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class ReactTooltip extends Component {
constructor (props) {
super(props)
this.state = {
place: '', // Direction of tooltip
place: 'top', // Direction of tooltip
type: 'dark', // Color theme of tooltip
effect: 'float', // float or fixed
show: false,
Expand Down Expand Up @@ -275,10 +275,8 @@ class ReactTooltip extends Component {
if (!this.mount) return

const resetState = (resetPlace) => {
const newPlace = resetPlace ? '' : this.state.place
this.setState({
show: false,
place: newPlace
show: false
})
this.removeScrollListener()
}
Expand Down
2 changes: 1 addition & 1 deletion src/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
padding: 8px 21px;
position: fixed;
pointer-events: none;
transition: opacity 0.3s ease-out , margin-top 0.3s ease-out, margin-left 0.3s ease-out;
transition: opacity 0.3s ease-out;
top: -999em;
visibility: hidden;
z-index: 999;
Expand Down
2 changes: 1 addition & 1 deletion src/style.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a90c76a

Please sign in to comment.