Skip to content

Commit

Permalink
Fix the readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
nathggns authored and chinchang committed Mar 2, 2013
1 parent a3986a1 commit d17a92e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Expand Up @@ -27,16 +27,18 @@ or
<link rel="stylesheet" href="hint.min.css"></link>
```

Any element in your markup which needs to have a tooltip has to be given atleast 2 classes: <code>hint</code> & any one of `hint--top`, `hint--bottom`, `hint--left`, `hint--right` to position the tooltip.
Any element in your markup which needs to have a tooltip has to be given at least one class: any one of `hint--top`, `hint--bottom`, `hint--left`, `hint--right` to position the tooltip.

The `hint` class can also be used if you're looking for older browser support. However, this class is redundant in newer browsers.

```html
Hello Sir, <span class="hint hint--bottom">hover me.</span>
Hello Sir, <span class="hint--bottom">hover me.</span>
```

The tooltip text needs to be given using the `data-hint` attribute on that element.

```html
Hello Sir, <span class="hint hint--bottom" data-hint="Thank you!">hover me.</span>
Hello Sir, <span class="hint--bottom" data-hint="Thank you!">hover me.</span>
```

Use it with other available modifiers in various combinations. Available modifiers:
Expand Down

0 comments on commit d17a92e

Please sign in to comment.