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

Fix for #158, getposition error #162

Merged
merged 1 commit into from
Jul 30, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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.