Skip to content

Commit

Permalink
More changes to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
a-coox committed Feb 6, 2018
1 parent 1493fd6 commit bc5bbae
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,35 @@ Simply add a `simpleTyper` class to any element, and the text to be typed as a `
simpleTyper.init().start($('#example')[0]);
```

* simpleTyper.init(): Initialise the plugin
* simpleTyper.start(*element*): Start the typing effect on this non-jQuery element.
* simpleTyper.stop(*element*): Force the effect to stop on this non-jQuery element. Note: the effect
* **simpleTyper.init():** Initialise the plugin
* **simpleTyper.start(*element*)**: Start the typing effect on this non-jQuery element.
* **simpleTyper.stop(*element*)**: Force the effect to stop on this non-jQuery element. Note: the effect
stops automatically upon completion.
* simpleTyper.startAll(): This will start the typing animation on every applicable element.
* simpleTyper.settings(*settings*): override default settings with an `object` (see below for detail).
* **simpleTyper.startAll()**: This will start the typing animation on every applicable element.
* **simpleTyper.settings(*settings*)**: override default settings with an `object` (see below for detail).

## Settings
These can be passed in as a object to `simpleTyper.settings()`, or applied directly to an element by adding
`data-typer-{your-property}="{your-value}"`.

### speed
Type: `Number` (ms), Default: `1000`

How long it will take for a letter to be typed.

### delay
Type: `Number` (ms), Default: `0`

A delay between when `simpleTyper.start()` is called and when the animation begins.

### random
Type: `Number` (fraction), Default: `0.1`

A multiplier (0 to 1) which randomly shifts the `speed` attribute. This adds realism to the animation.

### cursorSpeed
Type: `Number` (ms), Default: `500`

How fast the cursor blinks. Note: cursor must be implemented in CSS using `.simpleTyperCursor`.

### cursorStopDelay
Expand Down

0 comments on commit bc5bbae

Please sign in to comment.