Skip to content

Commit 34fa8cb

Browse files
authored
Merge pull request #491 from k88manish/master
docs: Spelling mistakes correction
2 parents a2e8af5 + cb9d2e5 commit 34fa8cb

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

src/decorators/staticMethods.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import CONSTANT from '../constant'
55

66
const dispatchGlobalEvent = (eventName, opts) => {
7-
// Compatibale with IE
7+
// Compatible with IE
88
// @see http://stackoverflow.com/questions/26596123/internet-explorer-9-10-11-event-constructor-doesnt-work
99
let event
1010

src/decorators/trackRemoval.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* Tracking target removing from DOM.
3-
* It's nessesary to hide tooltip when it's target disappears.
3+
* It's necessary to hide tooltip when it's target disappears.
44
* Otherwise, the tooltip would be shown forever until another target
55
* is triggered.
66
*

src/index.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import React from 'react'
44
import PropTypes from 'prop-types'
55
import classname from 'classnames'
66

7-
/* Decoraters */
7+
/* Decorators */
88
import staticMethods from './decorators/staticMethods'
99
import windowListener from './decorators/windowListener'
1010
import customEvent from './decorators/customEvent'
@@ -246,8 +246,8 @@ class ReactTooltip extends React.Component {
246246
}
247247

248248
/**
249-
* Invoke this before bind listener and ummount the compont
250-
* it is necessary to invloke this even when binding custom event
249+
* Invoke this before bind listener and unmount the component
250+
* it is necessary to invoke this even when binding custom event
251251
* so that the tooltip can switch between custom and default listener
252252
*/
253253
unbindBasicListener (target) {
@@ -366,7 +366,7 @@ class ReactTooltip extends React.Component {
366366
}
367367

368368
/**
369-
* When mouse hover, updatetooltip
369+
* When mouse hover, update tool tip
370370
*/
371371
updateTooltip (e) {
372372
const {delayShow, disable} = this.state
@@ -464,7 +464,7 @@ class ReactTooltip extends React.Component {
464464
}
465465

466466
/**
467-
* Add scroll eventlistener when tooltip show
467+
* Add scroll event listener when tooltip show
468468
* automatically hide the tooltip when scrolling
469469
*/
470470
addScrollListener (currentTarget) {

src/utils/getTipContent.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import React from 'react'
1616
export default function (tip, children, getContent, multiline) {
1717
if (children) return children
1818
if (getContent !== undefined && getContent !== null) return getContent // getContent can be 0, '', etc.
19-
if (getContent === null) return null // Tip not exist and childern is null or undefined
19+
if (getContent === null) return null // Tip not exist and children is null or undefined
2020

2121
const regexp = /<br\s*\/?>/
2222
if (!multiline || multiline === 'false' || !regexp.test(tip)) {

0 commit comments

Comments
 (0)