Skip to content

Commit 9f243f0

Browse files
committed
Fix many typos, mostly from hammerjs/hammerjs.github.io#13
1 parent 12a3720 commit 9f243f0

File tree

4 files changed

+18
-17
lines changed

4 files changed

+18
-17
lines changed

api.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ You should only use this when you're fine with the default setup, or have set yo
2424
Just your element, and options. the options will be merged with Hammer.defaults. Also,
2525
the recognizer set as defined in `Hammer.defaults.preset` will be added.
2626

27-
If you'll pass an empty `recognizer` option, no initial recognizers will be added.
27+
If you pass an empty `recognizer` option, no initial recognizers will be added.
2828

2929
````js
3030
var myElement = document.getElementById('hitarea');
@@ -34,7 +34,7 @@ var mc = new Hammer(myElement);
3434
---
3535

3636
## Hammer.defaults
37-
The defaults when creating an instance that are merged being with your options.
37+
The defaults when creating an instance. They'll be merged with the options that you provide.
3838

3939
### touchAction: 'compute'
4040
Accepts the `compute`, `auto`, `pan-y`, `pan-x` and `none` values. The default option will choose the
@@ -47,8 +47,8 @@ Let Hammer also fire DOM events. This is a bit slower, so disabled by default. R
4747
Accepts a boolean, or a function that should return a boolean which is.
4848

4949
### cssProps: {....}
50-
A collection of css properties that improve the handling of the input events. For details [take a look at
51-
the JSDoc.]({{site.baseurl}}/jsdoc/Hammer.defaults.cssProps.html)
50+
A collection of CSS properties that improve the handling of the input events. For details [take a look at
51+
the JSDoc]({{site.baseurl}}/jsdoc/Hammer.defaults.cssProps.html).
5252

5353
### preset: [....]
5454
Default recognizer setup when calling `Hammer()`. When creating a new Manager these will be skipped.
@@ -95,7 +95,7 @@ mc.set({ enable: true });
9595
### get(string), add(Recognizer) and remove(Recognizer)
9696
Add a new `Recognizer` instance to the Manager. The order of adding is also the order of the recognizers being
9797
executed. Just like the `get` method, it returns the added `Recognizer` instance.
98-
The `get` and `remove` methods takes the event name (from a recognizer) or a recognizer instance as an argument.
98+
The `get` and `remove` methods take the event name (from a recognizer) or a recognizer instance as an argument.
9999

100100
Add and remove also accept an array of recognizers.
101101

@@ -117,8 +117,9 @@ mc.remove([myPinchRecognizer, 'rotate']);
117117
````
118118

119119
### on(events, handler) and .off(events, [handler])
120-
Listen to events triggered by the added recognizers, or remove the binded events. Accepts multiple events seperated
121-
by a space.
120+
121+
Listen to events triggered by the added recognizers, or remove the
122+
bound events. Accepts space-separated list of event names.
122123

123124
````js
124125
mc.on("pinch", function(ev) {
@@ -151,8 +152,8 @@ Change an option on the recognizer instance. Using this method is recommended,
151152
because it will update the `touchAction` value if needed.
152153

153154
### recognizeWith(otherRecognizer) and dropRecognizeWith(otherRecognizer)
154-
Run the recognizer simultaneous with the given other recognizer, in both directions. This is usable for like
155-
combining a pan with a swipe at the end, or a pinch with the ability to rotate the target as well. Dropping the
155+
Run the recognizer simultaneously with the given other recognizer, in both directions. This could be used to
156+
combine a pan with a swipe at the end, or a pinch with the ability to rotate the target as well. Dropping the
156157
connection only removes the link on the recognizer, not on the other recognizer. Both accept an
157158
array of recognizers.
158159

@@ -184,7 +185,7 @@ hammertime.on("hammer.input", function(ev) {
184185
---
185186

186187
## Event object
187-
All events that Hammer triggers all receive an event object containing the following properties.
188+
All events that Hammer triggers receive an event object containing the following properties.
188189

189190
| Name | Value |
190191
|-----------------------|-------|
@@ -215,8 +216,8 @@ All events that Hammer triggers all receive an event object containing the follo
215216
---
216217

217218
## Constants
218-
All constants are defined at the `Hammer` object. Since it are binary flags,
219-
you can use bitwise operators on it. MDN has some excellent
219+
All constants are defined at the `Hammer` object. Since they are binary flags,
220+
you can use bitwise operators on them. MDN has some excellent
220221
[documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Bitwise_Operators)
221222
about this.
222223

getting-started.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ title: Getting Started
44
---
55

66
# Getting Started
7-
Hammer is a open-source library that can recognize gestures made by touch, mouse and pointerEvents.
7+
Hammer is an open-source library that can recognize gestures made by touch, mouse, and pointerEvents.
88
It doesn't have any dependencies, and it's small, only __{{site.data.hammer.gzipped}} minified + gzipped__!
99

1010
- [Minified code (v{{site.data.hammer.version}})](/dist/hammer.min.js)
@@ -15,7 +15,7 @@ It doesn't have any dependencies, and it's small, only __{{site.data.hammer.gzip
1515

1616
> ##### What's new in 2.0?
1717
It's completely rewritten, with reusable gesture recognizers, and improved support for the recent mobile
18-
browsers by making use of the touch-action css property when possible. Also support for multiple Hammer
18+
browsers by making use of the touch-action CSS property when possible. Also support for multiple Hammer
1919
instances at the same time, so multi-touch becomes possible.
2020

2121
---

require-failure.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ Multiple taps on the same element can be easily recognized on this way:
3232
var hammer = new Hammer(el, {});
3333

3434
var singleTap = new Hammer.Tap({ event: 'singletap' });
35-
var doubleTap = new Hammer.Tap({event: 'doubletap', taps: 2 });
36-
var tripleTap = new Hammer.Tap({event: 'tripletap', taps: 3 });
35+
var doubleTap = new Hammer.Tap({ event: 'doubletap', taps: 2 });
36+
var tripleTap = new Hammer.Tap({ event: 'tripletap', taps: 3 });
3737

3838
hammer.add([tripleTap, doubleTap, singleTap]);
3939

tips.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ able to recognize these gestures. An option would be to provide an alternative w
1414

1515
### Test on a real device
1616
Sometimes Hammer just needs some fine-tuning, like the swipe velocity or some other thresholds. Also,
17-
for better performance on slower devices your should try to keep you callbacks as simple as possible.
17+
for better performance on slower devices your should try to keep your callbacks as simple as possible.
1818
Sites like [JankFree.org](http://jankfree.org/) have articles about how to improve the performance.
1919

2020
### Remove tap highlight on Windows Phone

0 commit comments

Comments
 (0)