dta_rapid 1.4.7 → 1.4.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_includes/lists/suggestion-search.html +3 -1
- data/_includes/scripts.html +1 -0
- data/assets/js/findIndexPolyfill.js +44 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c8ff39c88abb205b7260bf65f2d0707641719f50
|
4
|
+
data.tar.gz: 1b02fde3761ef82e66f7a00fe0453e66d5a15316
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f8ae5d3311a9f2fa6fccbc18146bad5e129a4bad3b6dacc9ac907d77043a10b65812c7d784d38103fcc3131f70f70e077d3c2779e9aa3a75e7a045d7d9566c77
|
7
|
+
data.tar.gz: 9cda3d0945f9223056b52b04db8e89cd0504b8a69819b74328b5f222ed4fee73ce91ccb37dcd395cab2b821e67747eb10a6e6dfc4d9780a1299048735318817a
|
@@ -12,7 +12,9 @@
|
|
12
12
|
<script type="text/javascript">
|
13
13
|
document.addEventListener("DOMContentLoaded", function(e) {
|
14
14
|
var filterDuplicateResults = function(matches) {
|
15
|
-
return matches.filter((match, pos, arr)
|
15
|
+
return matches.filter(function(match, pos, arr) {
|
16
|
+
return arr.findIndex(function(elm) { return elm.link === match.link }) === pos;
|
17
|
+
});
|
16
18
|
};
|
17
19
|
|
18
20
|
var customSearcher = function(data) {
|
data/_includes/scripts.html
CHANGED
@@ -0,0 +1,44 @@
|
|
1
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.findIndex
|
2
|
+
if (!Array.prototype.findIndex) {
|
3
|
+
Object.defineProperty(Array.prototype, 'findIndex', {
|
4
|
+
value: function(predicate) {
|
5
|
+
// 1. Let O be ? ToObject(this value).
|
6
|
+
if (this == null) {
|
7
|
+
throw new TypeError('"this" is null or not defined');
|
8
|
+
}
|
9
|
+
|
10
|
+
var o = Object(this);
|
11
|
+
|
12
|
+
// 2. Let len be ? ToLength(? Get(O, "length")).
|
13
|
+
var len = o.length >>> 0;
|
14
|
+
|
15
|
+
// 3. If IsCallable(predicate) is false, throw a TypeError exception.
|
16
|
+
if (typeof predicate !== 'function') {
|
17
|
+
throw new TypeError('predicate must be a function');
|
18
|
+
}
|
19
|
+
|
20
|
+
// 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
|
21
|
+
var thisArg = arguments[1];
|
22
|
+
|
23
|
+
// 5. Let k be 0.
|
24
|
+
var k = 0;
|
25
|
+
|
26
|
+
// 6. Repeat, while k < len
|
27
|
+
while (k < len) {
|
28
|
+
// a. Let Pk be ! ToString(k).
|
29
|
+
// b. Let kValue be ? Get(O, Pk).
|
30
|
+
// c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
|
31
|
+
// d. If testResult is true, return k.
|
32
|
+
var kValue = o[k];
|
33
|
+
if (predicate.call(thisArg, kValue, k, o)) {
|
34
|
+
return k;
|
35
|
+
}
|
36
|
+
// e. Increase k by 1.
|
37
|
+
k++;
|
38
|
+
}
|
39
|
+
|
40
|
+
// 7. Return -1.
|
41
|
+
return -1;
|
42
|
+
}
|
43
|
+
});
|
44
|
+
}
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dta_rapid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gareth Rogers
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2017-05-
|
13
|
+
date: 2017-05-30 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: jekyll
|
@@ -97,6 +97,7 @@ files:
|
|
97
97
|
- _layouts/full_width.html
|
98
98
|
- _layouts/homepage.html
|
99
99
|
- assets/css/style.min.css
|
100
|
+
- assets/js/findIndexPolyfill.js
|
100
101
|
- assets/js/vendor/jquery-3.1.1.min.js
|
101
102
|
- assets/js/vendor/list.min.js
|
102
103
|
- assets/js/vendor/main.js
|