Skip to content

Commit 86054c1

Browse files
committed
PR merge fixes
1 parent e625953 commit 86054c1

File tree

9 files changed

+174
-298
lines changed

9 files changed

+174
-298
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/dist
22
node_modules
33
npm-debug.log
4+
package-lock.json
45
.DS_Store

README.md

Lines changed: 18 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ where the reducer transforms an accumulator value based on each item iterated ov
4949
5050
**Parameters**
5151

52-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to reduce
53-
- `reducer` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function, gets passed `(accumulator, value, index, array)` and returns a new value for `accumulator`
54-
- `accumulator` **any?** Optional initial accumulator value
52+
- `array` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to reduce
53+
- `reducer` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** Async function, gets passed `(accumulator, value, index, array)` and returns a new value for `accumulator`
54+
- `accumulator` **\[any]** Optional initial accumulator value
5555

5656
**Examples**
5757

@@ -68,29 +68,6 @@ await reduce(
6868

6969
Returns **any** final `accumulator` value
7070

71-
### map
72-
73-
Invoke an async transform function on each item in the given Array **in parallel**,
74-
returning the resulting Array of mapped/transformed items.
75-
76-
> This is an asynchronous, parallelized version of `Array.prototype.map()`.
77-
78-
**Parameters**
79-
80-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to map over
81-
- `mapper` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function, gets passed `(value, index, array)`, returns the new value.
82-
83-
**Examples**
84-
85-
```javascript
86-
await map(
87-
['foo', 'baz'],
88-
async v => await fetch(v)
89-
)
90-
```
91-
92-
Returns **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** resulting mapped/transformed values.
93-
9471
### filter
9572

9673
Invoke an async filter function on each item in the given Array **in parallel**,
@@ -100,8 +77,8 @@ returning an Array of values for which the filter function returned a truthy val
10077
10178
**Parameters**
10279

103-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to filter
104-
- `filterer` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, returns true to keep the value in the resulting filtered Array.
80+
- `array` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to filter
81+
- `filterer` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, returns true to keep the value in the resulting filtered Array.
10582

10683
**Examples**
10784

@@ -112,7 +89,7 @@ await filter(
11289
)
11390
```
11491

115-
Returns **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** resulting filtered values
92+
Returns **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** resulting filtered values
11693

11794
### find
11895

@@ -123,8 +100,8 @@ Invoke an async function on each item in the given Array **in parallel**,
123100
124101
**Parameters**
125102

126-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to find
127-
- `predicate` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, returns true to be the find result.
103+
- `array` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to find
104+
- `predicate` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, returns true to be the find result.
128105

129106
**Examples**
130107

@@ -145,8 +122,8 @@ Checks if predicate returns truthy for **all** elements of collection **in paral
145122
146123
**Parameters**
147124

148-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to iterate over.
149-
- `predicate` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, The function invoked per iteration.
125+
- `array` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to iterate over.
126+
- `predicate` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, The function invoked per iteration.
150127

151128
**Examples**
152129

@@ -157,7 +134,7 @@ await every(
157134
)
158135
```
159136

160-
Returns **[Boolean](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean)** Returns true if **all** element passes the predicate check, else false.
137+
Returns **[Boolean](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)** Returns true if **all** element passes the predicate check, else false.
161138

162139
### some
163140

@@ -167,8 +144,8 @@ Checks if predicate returns truthy for **any** element of collection **in parall
167144
168145
**Parameters**
169146

170-
- `array` **[Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to iterate over.
171-
- `filterer` **[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, The function invoked per iteration.
147+
- `array` **[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)** The Array to iterate over.
148+
- `filterer` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** Async function. Gets passed `(value, index, array)`, The function invoked per iteration.
172149

173150
**Examples**
174151

@@ -179,15 +156,15 @@ await some(
179156
)
180157
```
181158

182-
Returns **[Boolean](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean)** Returns true if **any** element passes the predicate check, else false.
159+
Returns **[Boolean](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean)** Returns true if **any** element passes the predicate check, else false.
183160

184161
### parallel
185162

186163
Invoke all async functions in an Array or Object **in parallel**, returning the result.
187164

188165
**Parameters**
189166

190-
- `list` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)> | [Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)<[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)>)** Array/Object with values that are async functions to invoke.
167+
- `list` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)> | [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)<[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)>)** Array/Object with values that are async functions to invoke.
191168

192169
**Examples**
193170

@@ -198,15 +175,15 @@ await parallel([
198175
])
199176
```
200177

201-
Returns **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object))** same structure as `list` input, but with values now resolved.
178+
Returns **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object))** same structure as `list` input, but with values now resolved.
202179

203180
### series
204181

205182
Invoke all async functions in an Array or Object **sequentially**, returning the result.
206183

207184
**Parameters**
208185

209-
- `list` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)> | [Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)<[Function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Statements/function)>)** Array/Object with values that are async functions to invoke.
186+
- `list` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)> | [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)<[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)>)** Array/Object with values that are async functions to invoke.
210187

211188
**Examples**
212189

@@ -217,4 +194,4 @@ await series([
217194
])
218195
```
219196

220-
Returns **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object))** same structure as `list` input, but with values now resolved.
197+
Returns **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object))** same structure as `list` input, but with values now resolved.

docs/assets/anchor.js

Lines changed: 50 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
'use strict';
2-
31
/*!
42
* AnchorJS - v1.2.1 - 2015-07-02
53
* https://github.com/bryanbraun/anchorjs
64
* Copyright (c) 2015 Bryan Braun; Licensed MIT
75
*/
86

97
function AnchorJS(options) {
8+
'use strict';
9+
1010
this.options = options || {};
1111

12-
this._applyRemainingDefaultOptions = function (opts) {
12+
this._applyRemainingDefaultOptions = function(opts) {
1313
this.options.icon = this.options.hasOwnProperty('icon') ? opts.icon : '\ue9cb'; // Accepts characters (and also URLs?), like '#', '¶', '❡', or '§'.
1414
this.options.visible = this.options.hasOwnProperty('visible') ? opts.visible : 'hover'; // Also accepts 'always'
1515
this.options.placement = this.options.hasOwnProperty('placement') ? opts.placement : 'right'; // Also accepts 'left'
@@ -18,8 +18,19 @@ function AnchorJS(options) {
1818

1919
this._applyRemainingDefaultOptions(options);
2020

21-
this.add = function (selector) {
22-
var elements, elsWithIds, idList, elementID, i, roughText, tidyText, index, count, newTidyText, readableID, anchor;
21+
this.add = function(selector) {
22+
var elements,
23+
elsWithIds,
24+
idList,
25+
elementID,
26+
i,
27+
roughText,
28+
tidyText,
29+
index,
30+
count,
31+
newTidyText,
32+
readableID,
33+
anchor;
2334

2435
this._applyRemainingDefaultOptions(this.options);
2536

@@ -44,6 +55,7 @@ function AnchorJS(options) {
4455
});
4556

4657
for (i = 0; i < elements.length; i++) {
58+
4759
if (elements[i].hasAttribute('id')) {
4860
elementID = elements[i].getAttribute('id');
4961
} else {
@@ -53,12 +65,12 @@ function AnchorJS(options) {
5365
// spaces with hyphens, truncate to 32 characters, and make toLowerCase.
5466
//
5567
// Example string: // '⚡⚡⚡ Unicode icons are cool--but they definitely don't belong in a URL fragment.'
56-
tidyText = roughText.replace(/[^\w\s-]/gi, '') // ' Unicode icons are cool--but they definitely dont belong in a URL fragment'
57-
.replace(/\s+/g, '-') // '-Unicode-icons-are-cool--but-they-definitely-dont-belong-in-a-URL-fragment'
58-
.replace(/-{2,}/g, '-') // '-Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL-fragment'
59-
.substring(0, 64) // '-Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL'
60-
.replace(/^-+|-+$/gm, '') // 'Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL'
61-
.toLowerCase(); // 'unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-url'
68+
tidyText = roughText.replace(/[^\w\s-]/gi, '') // ' Unicode icons are cool--but they definitely dont belong in a URL fragment'
69+
.replace(/\s+/g, '-') // '-Unicode-icons-are-cool--but-they-definitely-dont-belong-in-a-URL-fragment'
70+
.replace(/-{2,}/g, '-') // '-Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL-fragment'
71+
.substring(0, 64) // '-Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL'
72+
.replace(/^-+|-+$/gm, '') // 'Unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-URL'
73+
.toLowerCase(); // 'unicode-icons-are-cool-but-they-definitely-dont-belong-in-a-url'
6274

6375
// Compare our generated ID to existing IDs (and increment it if needed)
6476
// before we add it to the page.
@@ -109,8 +121,7 @@ function AnchorJS(options) {
109121
anchor.style.marginLeft = '-1em';
110122
anchor.style.paddingRight = '0.5em';
111123
elements[i].insertBefore(anchor, elements[i].firstChild);
112-
} else {
113-
// if the option provided is `right` (or anything else).
124+
} else { // if the option provided is `right` (or anything else).
114125
anchor.style.paddingLeft = '0.375em';
115126
elements[i].appendChild(anchor);
116127
}
@@ -119,7 +130,7 @@ function AnchorJS(options) {
119130
return this;
120131
};
121132

122-
this.remove = function (selector) {
133+
this.remove = function(selector) {
123134
var domAnchor,
124135
elements = document.querySelectorAll(selector);
125136
for (var i = 0; i < elements.length; i++) {
@@ -131,18 +142,36 @@ function AnchorJS(options) {
131142
return this;
132143
};
133144

134-
this._addBaselineStyles = function () {
145+
this._addBaselineStyles = function() {
135146
// We don't want to add global baseline styles if they've been added before.
136147
if (document.head.querySelector('style.anchorjs') !== null) {
137148
return;
138149
}
139150

140151
var style = document.createElement('style'),
141-
linkRule = ' .anchorjs-link {' + ' opacity: 0;' + ' text-decoration: none;' + ' -webkit-font-smoothing: antialiased;' + ' -moz-osx-font-smoothing: grayscale;' + ' }',
142-
hoverRule = ' *:hover > .anchorjs-link,' + ' .anchorjs-link:focus {' + ' opacity: 1;' + ' }',
143-
anchorjsLinkFontFace = ' @font-face {' + ' font-family: "anchorjs-icons";' + ' font-style: normal;' + ' font-weight: normal;' + // Icon from icomoon; 10px wide & 10px tall; 2 empty below & 4 above
144-
' src: url(data:application/x-font-ttf;charset=utf-8;base64,AAEAAAALAIAAAwAwT1MvMg8SBTUAAAC8AAAAYGNtYXAWi9QdAAABHAAAAFRnYXNwAAAAEAAAAXAAAAAIZ2x5Zgq29TcAAAF4AAABNGhlYWQEZM3pAAACrAAAADZoaGVhBhUDxgAAAuQAAAAkaG10eASAADEAAAMIAAAAFGxvY2EAKACuAAADHA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mAAMAAQQJAAMAHABZAAMAAQQJAAQAHADCAAMAAQQJAAUAFgA1AAMAAQQJAAYAHACDAAMAAQQJAAoANAD4YW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzVmVyc2lvbiAxLjAAVgBlAHIAcwBpAG8AbgAgADEALgAwYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzUmVndWxhcgBSAGUAZwB1AGwAYQByYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzRm9udCBnZW5lcmF0ZWQgYnkgSWNvTW9vbi4ARgBvAG4AdAAgAGcAZQBuAGUAcgBhAHQAZQBkACAAYgB5ACAASQBjAG8ATQBvAG8AbgAuAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==) format("truetype");' + ' }',
145-
pseudoElContent = ' [data-anchorjs-icon]::after {' + ' content: attr(data-anchorjs-icon);' + ' }',
152+
linkRule =
153+
' .anchorjs-link {' +
154+
' opacity: 0;' +
155+
' text-decoration: none;' +
156+
' -webkit-font-smoothing: antialiased;' +
157+
' -moz-osx-font-smoothing: grayscale;' +
158+
' }',
159+
hoverRule =
160+
' *:hover > .anchorjs-link,' +
161+
' .anchorjs-link:focus {' +
162+
' opacity: 1;' +
163+
' }',
164+
anchorjsLinkFontFace =
165+
' @font-face {' +
166+
' font-family: "anchorjs-icons";' +
167+
' font-style: normal;' +
168+
' font-weight: normal;' + // Icon from icomoon; 10px wide & 10px tall; 2 empty below & 4 above
169+
' src: url(data:application/x-font-ttf;charset=utf-8;base64,AAEAAAALAIAAAwAwT1MvMg8SBTUAAAC8AAAAYGNtYXAWi9QdAAABHAAAAFRnYXNwAAAAEAAAAXAAAAAIZ2x5Zgq29TcAAAF4AAABNGhlYWQEZM3pAAACrAAAADZoaGVh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gB1AAEAAAAAAAoAGgDeAAMAAQQJAAEAHAAOAAMAAQQJAAIADgCmAAMAAQQJAAMAHABZAAMAAQQJAAQAHADCAAMAAQQJAAUAFgA1AAMAAQQJAAYAHACDAAMAAQQJAAoANAD4YW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzVmVyc2lvbiAxLjAAVgBlAHIAcwBpAG8AbgAgADEALgAwYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzUmVndWxhcgBSAGUAZwB1AGwAYQByYW5jaG9yanMtaWNvbnMAYQBuAGMAaABvAHIAagBzAC0AaQBjAG8AbgBzRm9udCBnZW5lcmF0ZWQgYnkgSWNvTW9vbi4ARgBvAG4AdAAgAGcAZQBuAGUAcgBhAHQAZQBkACAAYgB5ACAASQBjAG8ATQBvAG8AbgAuAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==) format("truetype");' +
170+
' }',
171+
pseudoElContent =
172+
' [data-anchorjs-icon]::after {' +
173+
' content: attr(data-anchorjs-icon);' +
174+
' }',
146175
firstStyleEl;
147176

148177
style.className = 'anchorjs';
@@ -165,4 +194,4 @@ function AnchorJS(options) {
165194
};
166195
}
167196

168-
var anchors = new AnchorJS();
197+
var anchors = new AnchorJS();

0 commit comments

Comments
 (0)