jscrewit 2.30.0 → 2.33.1
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.
- package/Features.md +9 -3
- package/JScrewIt.html +1 -1
- package/api-doc/.nojekyll +1 -0
- package/api-doc/README.md +18 -19
- package/api-doc/interfaces/CustomFeature.md +1 -1
- package/api-doc/interfaces/ElementaryFeature.md +1 -1
- package/api-doc/interfaces/EncodeOptions.md +1 -1
- package/api-doc/interfaces/Feature.md +3 -2
- package/api-doc/interfaces/FeatureAll.md +121 -99
- package/api-doc/interfaces/FeatureConstructor.md +142 -112
- package/api-doc/interfaces/PredefinedFeature.md +1 -1
- package/lib/encode.d.ts +2 -2
- package/lib/feature-all.d.ts +45 -28
- package/lib/feature.d.ts +19 -20
- package/lib/jscrewit.js +1770 -2133
- package/lib/jscrewit.min.js +2 -2
- package/package.json +5 -1
- package/readme.md +2 -2
- package/ui/ui.js +1 -1
package/lib/jscrewit.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
// JScrewIt 2.
|
|
1
|
+
// JScrewIt 2.33.1 – https://jscrew.it
|
|
2
2
|
|
|
3
3
|
(function () {
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
6
|
var _Array = Array;
|
|
7
|
-
var _Array_isArray = _Array.isArray;
|
|
8
|
-
var _Array_prototype_every_call;
|
|
7
|
+
var _Array_isArray$1 = _Array.isArray;
|
|
9
8
|
var _Array_prototype_forEach_call;
|
|
10
9
|
var _Array_prototype_map_call;
|
|
11
10
|
var _Array_prototype_push_apply;
|
|
@@ -13,12 +12,12 @@
|
|
|
13
12
|
|
|
14
13
|
var _Date = Date;
|
|
15
14
|
|
|
16
|
-
var _Error = Error;
|
|
15
|
+
var _Error$1 = Error;
|
|
17
16
|
|
|
18
17
|
var _Function = Function;
|
|
19
18
|
|
|
20
19
|
var _JSON_parse = JSON.parse;
|
|
21
|
-
var _JSON_stringify = JSON.stringify;
|
|
20
|
+
var _JSON_stringify$1 = JSON.stringify;
|
|
22
21
|
|
|
23
22
|
var _Math_abs = Math.abs;
|
|
24
23
|
var _Math_max = Math.max;
|
|
@@ -26,53 +25,52 @@
|
|
|
26
25
|
var _Math_pow = Math.pow;
|
|
27
26
|
|
|
28
27
|
var _Object = Object;
|
|
29
|
-
var _Object_create = _Object.create;
|
|
30
|
-
var _Object_defineProperty = _Object.defineProperty;
|
|
31
|
-
var
|
|
32
|
-
var
|
|
33
|
-
var _Object_keys = _Object.keys;
|
|
28
|
+
var _Object_create$1 = _Object.create;
|
|
29
|
+
var _Object_defineProperty$1 = _Object.defineProperty;
|
|
30
|
+
var _Object_getOwnPropertyDescriptor$1 = _Object.getOwnPropertyDescriptor;
|
|
31
|
+
var _Object_keys$1 = _Object.keys;
|
|
34
32
|
|
|
35
33
|
var _RegExp = RegExp;
|
|
36
34
|
|
|
37
|
-
var _String = String;
|
|
35
|
+
var _String$1 = String;
|
|
38
36
|
|
|
39
37
|
var _SyntaxError = SyntaxError;
|
|
40
38
|
|
|
41
|
-
var _TypeError = TypeError;
|
|
39
|
+
var _TypeError$1 = TypeError;
|
|
42
40
|
|
|
43
41
|
var _parseInt = parseInt;
|
|
44
42
|
|
|
45
43
|
var _setTimeout = setTimeout;
|
|
46
44
|
|
|
47
|
-
function assignNoEnum(target, source)
|
|
45
|
+
function assignNoEnum$1(target, source)
|
|
48
46
|
{
|
|
49
|
-
var names = _Object_keys(source);
|
|
47
|
+
var names = _Object_keys$1(source);
|
|
50
48
|
names.forEach
|
|
51
49
|
(
|
|
52
50
|
function (name)
|
|
53
51
|
{
|
|
54
|
-
var descriptor = _Object_getOwnPropertyDescriptor(source, name);
|
|
52
|
+
var descriptor = _Object_getOwnPropertyDescriptor$1(source, name);
|
|
55
53
|
descriptor.enumerable = false;
|
|
56
|
-
_Object_defineProperty(target, name, descriptor);
|
|
54
|
+
_Object_defineProperty$1(target, name, descriptor);
|
|
57
55
|
}
|
|
58
56
|
);
|
|
59
57
|
return target;
|
|
60
58
|
}
|
|
61
59
|
|
|
62
|
-
var createEmpty = _Object_create.bind(null, null, undefined);
|
|
60
|
+
var createEmpty = _Object_create$1.bind(null, null, undefined);
|
|
63
61
|
|
|
64
|
-
function esToString(arg)
|
|
62
|
+
function esToString$1(arg)
|
|
65
63
|
{
|
|
66
64
|
if (typeof arg === 'symbol')
|
|
67
|
-
throw new _TypeError('Cannot convert a symbol to a string');
|
|
68
|
-
var str = _String(arg);
|
|
65
|
+
throw new _TypeError$1('Cannot convert a symbol to a string');
|
|
66
|
+
var str = _String$1(arg);
|
|
69
67
|
return str;
|
|
70
68
|
}
|
|
71
69
|
|
|
72
70
|
function noProto(obj)
|
|
73
71
|
{
|
|
74
72
|
var result = createEmpty();
|
|
75
|
-
_Object_keys(obj).forEach
|
|
73
|
+
_Object_keys$1(obj).forEach
|
|
76
74
|
(
|
|
77
75
|
function (name)
|
|
78
76
|
{
|
|
@@ -105,7 +103,7 @@
|
|
|
105
103
|
var _Function_prototype_apply = _Function_prototype.apply;
|
|
106
104
|
var _Function_prototype_call = _Function_prototype.call;
|
|
107
105
|
|
|
108
|
-
|
|
106
|
+
_Function_prototype_call.bind(_Array_prototype.every);
|
|
109
107
|
_Array_prototype_forEach_call = _Function_prototype_call.bind(_Array_prototype.forEach);
|
|
110
108
|
_Array_prototype_map_call = _Function_prototype_call.bind(_Array_prototype.map);
|
|
111
109
|
_Array_prototype_slice_call = _Function_prototype_call.bind(_Array_prototype.slice);
|
|
@@ -248,7 +246,18 @@
|
|
|
248
246
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
249
247
|
}
|
|
250
248
|
|
|
251
|
-
|
|
249
|
+
var __assign = function() {
|
|
250
|
+
__assign = Object.assign || function __assign(t) {
|
|
251
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
252
|
+
s = arguments[i];
|
|
253
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
254
|
+
}
|
|
255
|
+
return t;
|
|
256
|
+
};
|
|
257
|
+
return __assign.apply(this, arguments);
|
|
258
|
+
};
|
|
259
|
+
|
|
260
|
+
// ~feature-hub – https://github.com/fasttime/JScrewIt/tree/master/packages/~feature-hub
|
|
252
261
|
|
|
253
262
|
var BIN_POW_31 = 2147483648;
|
|
254
263
|
var BIN_POW_32 = 4294967296;
|
|
@@ -370,60 +379,514 @@
|
|
|
370
379
|
return MaskSet;
|
|
371
380
|
}(MaskIndex));
|
|
372
381
|
|
|
373
|
-
var
|
|
374
|
-
var
|
|
375
|
-
var
|
|
376
|
-
var
|
|
377
|
-
var
|
|
378
|
-
var
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
function
|
|
389
|
-
|
|
390
|
-
var
|
|
391
|
-
var
|
|
392
|
-
|
|
393
|
-
var
|
|
394
|
-
|
|
395
|
-
|
|
382
|
+
var _Array_isArray = Array.isArray;
|
|
383
|
+
var _Error = Error;
|
|
384
|
+
var _JSON_stringify = JSON.stringify;
|
|
385
|
+
var _Object_create = Object.create, _Object_defineProperty = Object.defineProperty, _Object_freeze = Object.freeze, _Object_getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor, _Object_keys = Object.keys;
|
|
386
|
+
var _String = String;
|
|
387
|
+
var _TypeError = TypeError;
|
|
388
|
+
function assignNoEnum(target, source) {
|
|
389
|
+
var names = _Object_keys(source);
|
|
390
|
+
for (var _i = 0, names_1 = names; _i < names_1.length; _i++) {
|
|
391
|
+
var name_1 = names_1[_i];
|
|
392
|
+
var descriptor = _Object_getOwnPropertyDescriptor(source, name_1);
|
|
393
|
+
descriptor.enumerable = false;
|
|
394
|
+
_Object_defineProperty(target, name_1, descriptor);
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
function createFeatureClass(featureInfos, formatEngineDescription) {
|
|
398
|
+
var ALL = createMap();
|
|
399
|
+
var DESCRIPTION_MAP = createMap();
|
|
400
|
+
var ELEMENTARY = [];
|
|
401
|
+
var ENGINE = [];
|
|
402
|
+
var FAMILIES = createMap();
|
|
403
|
+
var FEATURE_PROTOTYPE = Feature.prototype;
|
|
404
|
+
var INCOMPATIBLE_MASK_LIST = [];
|
|
405
|
+
var PRISTINE_ELEMENTARY;
|
|
406
|
+
function Feature() {
|
|
407
|
+
var features = [];
|
|
408
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
409
|
+
features[_i] = arguments[_i];
|
|
410
|
+
}
|
|
411
|
+
var mask = maskNew();
|
|
412
|
+
for (var _a = 0, features_1 = features; _a < features_1.length; _a++) {
|
|
413
|
+
var feature = features_1[_a];
|
|
414
|
+
var otherMask = validMaskFromArrayOrStringOrFeature(feature);
|
|
415
|
+
mask = maskUnion(mask, otherMask);
|
|
416
|
+
}
|
|
417
|
+
if (features.length > 1)
|
|
418
|
+
validateMask(mask);
|
|
419
|
+
var featureObj = this instanceof Feature ? this : _Object_create(FEATURE_PROTOTYPE);
|
|
420
|
+
initMask(featureObj, mask);
|
|
421
|
+
return featureObj;
|
|
422
|
+
}
|
|
423
|
+
function _fromMask(mask) {
|
|
424
|
+
if (isMaskCompatible(mask)) {
|
|
425
|
+
var includedMask = maskNew();
|
|
426
|
+
for (var _i = 0, ELEMENTARY_1 = ELEMENTARY; _i < ELEMENTARY_1.length; _i++) {
|
|
427
|
+
var featureMask = ELEMENTARY_1[_i].mask;
|
|
428
|
+
if (maskIncludes(mask, featureMask))
|
|
429
|
+
includedMask = maskUnion(includedMask, featureMask);
|
|
430
|
+
}
|
|
431
|
+
if (maskAreEqual(mask, includedMask)) {
|
|
432
|
+
var featureObj = featureFromMask(mask);
|
|
433
|
+
return featureObj;
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
return null;
|
|
437
|
+
}
|
|
438
|
+
function _getMask(feature) {
|
|
439
|
+
var mask = feature !== undefined ? validMaskFromArrayOrStringOrFeature(feature) : maskNew();
|
|
440
|
+
return mask;
|
|
441
|
+
}
|
|
442
|
+
function areCompatible() {
|
|
443
|
+
var arg0;
|
|
444
|
+
var features = arguments.length === 1 &&
|
|
445
|
+
_Array_isArray(arg0 = arguments[0]) ?
|
|
446
|
+
arg0 : arguments;
|
|
396
447
|
var mask = featureArrayLikeToMask(features);
|
|
397
|
-
compatible = isMaskCompatible(mask);
|
|
448
|
+
var compatible = isMaskCompatible(mask);
|
|
449
|
+
return compatible;
|
|
398
450
|
}
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
var mask;
|
|
407
|
-
var equal =
|
|
408
|
-
_Array_prototype_every_call
|
|
409
|
-
(
|
|
410
|
-
arguments,
|
|
411
|
-
function (arg, index)
|
|
412
|
-
{
|
|
451
|
+
function areEqual() {
|
|
452
|
+
var features = [];
|
|
453
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
454
|
+
features[_i] = arguments[_i];
|
|
455
|
+
}
|
|
456
|
+
var mask;
|
|
457
|
+
var equal = features.every(function (feature, index) {
|
|
413
458
|
var returnValue;
|
|
414
|
-
var otherMask = validMaskFromArrayOrStringOrFeature(
|
|
459
|
+
var otherMask = validMaskFromArrayOrStringOrFeature(feature);
|
|
415
460
|
if (index)
|
|
416
461
|
returnValue = maskAreEqual(otherMask, mask);
|
|
417
|
-
else
|
|
418
|
-
{
|
|
462
|
+
else {
|
|
419
463
|
mask = otherMask;
|
|
420
464
|
returnValue = true;
|
|
421
465
|
}
|
|
422
466
|
return returnValue;
|
|
467
|
+
});
|
|
468
|
+
return equal;
|
|
469
|
+
}
|
|
470
|
+
function commonOf() {
|
|
471
|
+
var features = [];
|
|
472
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
473
|
+
features[_i] = arguments[_i];
|
|
423
474
|
}
|
|
424
|
-
|
|
425
|
-
|
|
475
|
+
var featureObj;
|
|
476
|
+
if (features.length) {
|
|
477
|
+
var mask = void 0;
|
|
478
|
+
for (var _a = 0, features_2 = features; _a < features_2.length; _a++) {
|
|
479
|
+
var feature = features_2[_a];
|
|
480
|
+
var otherMask = validMaskFromArrayOrStringOrFeature(feature);
|
|
481
|
+
if (mask != null)
|
|
482
|
+
mask = maskIntersection(mask, otherMask);
|
|
483
|
+
else
|
|
484
|
+
mask = otherMask;
|
|
485
|
+
}
|
|
486
|
+
featureObj = featureFromMask(mask);
|
|
487
|
+
}
|
|
488
|
+
else
|
|
489
|
+
featureObj = null;
|
|
490
|
+
return featureObj;
|
|
491
|
+
}
|
|
492
|
+
function createFeature(name, mask, check, attributes, elementary) {
|
|
493
|
+
_Object_freeze(attributes);
|
|
494
|
+
var descriptors = { attributes: { value: attributes }, check: { value: check }, name: { value: name } };
|
|
495
|
+
if (elementary)
|
|
496
|
+
descriptors.elementary = { value: true };
|
|
497
|
+
var featureObj = _Object_create(FEATURE_PROTOTYPE, descriptors);
|
|
498
|
+
initMask(featureObj, mask);
|
|
499
|
+
return featureObj;
|
|
500
|
+
}
|
|
501
|
+
function descriptionFor(name) {
|
|
502
|
+
name = esToString(name);
|
|
503
|
+
if (!(name in DESCRIPTION_MAP))
|
|
504
|
+
throwUnknownFeatureError(name);
|
|
505
|
+
var description = DESCRIPTION_MAP[name];
|
|
506
|
+
return description;
|
|
507
|
+
}
|
|
508
|
+
function featureArrayLikeToMask(features) {
|
|
509
|
+
var mask = maskNew();
|
|
510
|
+
var length = features.length;
|
|
511
|
+
for (var index = 0; index < length; ++index) {
|
|
512
|
+
var feature = features[index];
|
|
513
|
+
var otherMask = maskFromStringOrFeature(feature);
|
|
514
|
+
mask = maskUnion(mask, otherMask);
|
|
515
|
+
}
|
|
516
|
+
return mask;
|
|
517
|
+
}
|
|
518
|
+
function featureFromMask(mask) {
|
|
519
|
+
var featureObj = _Object_create(FEATURE_PROTOTYPE);
|
|
520
|
+
initMask(featureObj, mask);
|
|
521
|
+
return featureObj;
|
|
522
|
+
}
|
|
523
|
+
/**
|
|
524
|
+
* Node.js custom inspection function.
|
|
525
|
+
* Set on `Feature.prototype` with name `"inspect"` for Node.js ≤ 8.6.x and with symbol
|
|
526
|
+
* `Symbol.for("nodejs.util.inspect.custom")` for Node.js ≥ 6.6.x.
|
|
527
|
+
*
|
|
528
|
+
* @see
|
|
529
|
+
* {@link https://nodejs.org/api/util.html#util_custom_inspection_functions_on_objects} for
|
|
530
|
+
* further information.
|
|
531
|
+
*/
|
|
532
|
+
// opts can be undefined in Node.js 0.10.0.
|
|
533
|
+
function inspect(depth, opts) {
|
|
534
|
+
var _a, _b;
|
|
535
|
+
var breakLength = (_a = opts === null || opts === void 0 ? void 0 : opts.breakLength) !== null && _a !== void 0 ? _a : 80;
|
|
536
|
+
var compact = (_b = opts === null || opts === void 0 ? void 0 : opts.compact) !== null && _b !== void 0 ? _b : true;
|
|
537
|
+
var name = this.name;
|
|
538
|
+
if (name === undefined)
|
|
539
|
+
name = joinParts(compact, '<', '', this.canonicalNames, ',', '>', breakLength - 3);
|
|
540
|
+
var parts = [name];
|
|
541
|
+
if (this.elementary)
|
|
542
|
+
parts.push('(elementary)');
|
|
543
|
+
if (this.check)
|
|
544
|
+
parts.push('(check)');
|
|
545
|
+
{
|
|
546
|
+
var attributes = this.attributes;
|
|
547
|
+
if (typeof attributes === 'object') {
|
|
548
|
+
var str_1 = utilInspect(__assign({}, attributes), opts);
|
|
549
|
+
parts.push(str_1);
|
|
550
|
+
}
|
|
551
|
+
}
|
|
552
|
+
var str = joinParts(compact, '[Feature', ' ', parts, '', ']', breakLength - 1);
|
|
553
|
+
return str;
|
|
554
|
+
}
|
|
555
|
+
function isMaskCompatible(mask) {
|
|
556
|
+
var compatible = INCOMPATIBLE_MASK_LIST.every(function (incompatibleMask) { return !maskIncludes(mask, incompatibleMask); });
|
|
557
|
+
return compatible;
|
|
558
|
+
}
|
|
559
|
+
function maskFromStringOrFeature(feature) {
|
|
560
|
+
var featureObj;
|
|
561
|
+
if (feature instanceof Feature)
|
|
562
|
+
featureObj = feature;
|
|
563
|
+
else {
|
|
564
|
+
var name_2 = esToString(feature);
|
|
565
|
+
if (!(name_2 in ALL))
|
|
566
|
+
throwUnknownFeatureError(name_2);
|
|
567
|
+
featureObj = ALL[name_2];
|
|
568
|
+
}
|
|
569
|
+
var mask = featureObj.mask;
|
|
570
|
+
return mask;
|
|
571
|
+
}
|
|
572
|
+
function validMaskFromArrayOrStringOrFeature(feature) {
|
|
573
|
+
var mask;
|
|
574
|
+
if (_Array_isArray(feature)) {
|
|
575
|
+
mask = featureArrayLikeToMask(feature);
|
|
576
|
+
if (feature.length > 1)
|
|
577
|
+
validateMask(mask);
|
|
578
|
+
}
|
|
579
|
+
else
|
|
580
|
+
mask = maskFromStringOrFeature(feature);
|
|
581
|
+
return mask;
|
|
582
|
+
}
|
|
583
|
+
function validateMask(mask) {
|
|
584
|
+
if (!isMaskCompatible(mask))
|
|
585
|
+
throw new _Error('Incompatible features');
|
|
586
|
+
}
|
|
587
|
+
var utilInspect;
|
|
588
|
+
try {
|
|
589
|
+
utilInspect = require('util').inspect;
|
|
590
|
+
}
|
|
591
|
+
catch (_a) { }
|
|
592
|
+
{
|
|
593
|
+
var protoSource = {
|
|
594
|
+
get canonicalNames() {
|
|
595
|
+
var mask = this.mask;
|
|
596
|
+
var names = [];
|
|
597
|
+
var includedMask = maskNew();
|
|
598
|
+
for (var index = PRISTINE_ELEMENTARY.length; index--;) {
|
|
599
|
+
var featureObj = PRISTINE_ELEMENTARY[index];
|
|
600
|
+
var featureMask = featureObj.mask;
|
|
601
|
+
if (maskIncludes(mask, featureMask) && !maskIncludes(includedMask, featureMask)) {
|
|
602
|
+
includedMask = maskUnion(includedMask, featureMask);
|
|
603
|
+
names.push(featureObj.name);
|
|
604
|
+
}
|
|
605
|
+
}
|
|
606
|
+
names.sort();
|
|
607
|
+
return names;
|
|
608
|
+
},
|
|
609
|
+
elementary: false,
|
|
610
|
+
get elementaryNames() {
|
|
611
|
+
var names = [];
|
|
612
|
+
var mask = this.mask;
|
|
613
|
+
for (var _i = 0, ELEMENTARY_2 = ELEMENTARY; _i < ELEMENTARY_2.length; _i++) {
|
|
614
|
+
var featureObj = ELEMENTARY_2[_i];
|
|
615
|
+
var included = maskIncludes(mask, featureObj.mask);
|
|
616
|
+
if (included)
|
|
617
|
+
names.push(featureObj.name);
|
|
618
|
+
}
|
|
619
|
+
return names;
|
|
620
|
+
},
|
|
621
|
+
includes: function () {
|
|
622
|
+
var features = [];
|
|
623
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
624
|
+
features[_i] = arguments[_i];
|
|
625
|
+
}
|
|
626
|
+
var mask = this.mask;
|
|
627
|
+
var included = features.every(function (feature) {
|
|
628
|
+
var otherMask = validMaskFromArrayOrStringOrFeature(feature);
|
|
629
|
+
var returnValue = maskIncludes(mask, otherMask);
|
|
630
|
+
return returnValue;
|
|
631
|
+
});
|
|
632
|
+
return included;
|
|
633
|
+
},
|
|
634
|
+
name: undefined,
|
|
635
|
+
toString: function () {
|
|
636
|
+
var _a;
|
|
637
|
+
var name = (_a = this.name) !== null && _a !== void 0 ? _a : "<" + this.canonicalNames.join(', ') + ">";
|
|
638
|
+
var str = "[Feature " + name + "]";
|
|
639
|
+
return str;
|
|
640
|
+
},
|
|
641
|
+
};
|
|
642
|
+
if (utilInspect)
|
|
643
|
+
protoSource.inspect = inspect;
|
|
644
|
+
assignNoEnum(FEATURE_PROTOTYPE, protoSource);
|
|
645
|
+
}
|
|
646
|
+
(function () {
|
|
647
|
+
var compareFeatureNames = function (feature1, feature2) {
|
|
648
|
+
return feature1.name < feature2.name ? -1 : 1;
|
|
649
|
+
};
|
|
650
|
+
function completeExclusions() {
|
|
651
|
+
var incompatibleMaskSet = new MaskSet();
|
|
652
|
+
for (var _i = 0, featureNames_1 = featureNames; _i < featureNames_1.length; _i++) {
|
|
653
|
+
var name_3 = featureNames_1[_i];
|
|
654
|
+
var excludes = featureInfos[name_3].excludes;
|
|
655
|
+
if (excludes) {
|
|
656
|
+
var mask = ALL[name_3].mask;
|
|
657
|
+
for (var _a = 0, excludes_1 = excludes; _a < excludes_1.length; _a++) {
|
|
658
|
+
var exclude = excludes_1[_a];
|
|
659
|
+
var excludeMask = completeFeature(exclude);
|
|
660
|
+
var incompatibleMask = maskUnion(mask, excludeMask);
|
|
661
|
+
if (!incompatibleMaskSet.has(incompatibleMask)) {
|
|
662
|
+
INCOMPATIBLE_MASK_LIST.push(incompatibleMask);
|
|
663
|
+
incompatibleMaskSet.add(incompatibleMask);
|
|
664
|
+
}
|
|
665
|
+
}
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
function completeFeature(name) {
|
|
670
|
+
var mask;
|
|
671
|
+
if (name in ALL)
|
|
672
|
+
(mask = ALL[name].mask);
|
|
673
|
+
else {
|
|
674
|
+
var info_1 = featureInfos[name];
|
|
675
|
+
var getInfoStringField = function (fieldName) {
|
|
676
|
+
return fieldName in info_1 ?
|
|
677
|
+
esToString(info_1[fieldName]) : undefined;
|
|
678
|
+
};
|
|
679
|
+
var description = getInfoStringField('description');
|
|
680
|
+
var featureObj = void 0;
|
|
681
|
+
if ('aliasFor' in info_1) {
|
|
682
|
+
var aliasFor = esToString(info_1.aliasFor);
|
|
683
|
+
mask = completeFeature(aliasFor);
|
|
684
|
+
featureObj = ALL[aliasFor];
|
|
685
|
+
if (description == null)
|
|
686
|
+
description = DESCRIPTION_MAP[aliasFor];
|
|
687
|
+
}
|
|
688
|
+
else {
|
|
689
|
+
var inherits = getInfoStringField('inherits');
|
|
690
|
+
if (inherits != null)
|
|
691
|
+
completeFeature(inherits);
|
|
692
|
+
var wrappedCheck = void 0;
|
|
693
|
+
var compatibilities = void 0;
|
|
694
|
+
var check = info_1.check;
|
|
695
|
+
if (check !== undefined) {
|
|
696
|
+
mask = maskNext(unionMask);
|
|
697
|
+
unionMask = maskUnion(unionMask, mask);
|
|
698
|
+
wrappedCheck = wrapCheck(check);
|
|
699
|
+
}
|
|
700
|
+
else {
|
|
701
|
+
mask = maskNew();
|
|
702
|
+
wrappedCheck = null;
|
|
703
|
+
}
|
|
704
|
+
{
|
|
705
|
+
var includes = info_1.includes;
|
|
706
|
+
var includeSet = includeSetMap[name] = createMap();
|
|
707
|
+
if (_Array_isArray(includes)) {
|
|
708
|
+
for (var _i = 0, includes_1 = includes; _i < includes_1.length; _i++) {
|
|
709
|
+
var include = includes_1[_i];
|
|
710
|
+
includeSet[include] = null;
|
|
711
|
+
}
|
|
712
|
+
}
|
|
713
|
+
else {
|
|
714
|
+
if (inherits != null) {
|
|
715
|
+
var inheritedIncludeSet = includeSetMap[inherits];
|
|
716
|
+
for (var include in inheritedIncludeSet)
|
|
717
|
+
includeSet[include] = null;
|
|
718
|
+
}
|
|
719
|
+
if (includes) {
|
|
720
|
+
var includeDiffNames = _Object_keys(includes);
|
|
721
|
+
for (var _a = 0, includeDiffNames_1 = includeDiffNames; _a < includeDiffNames_1.length; _a++) {
|
|
722
|
+
var include = includeDiffNames_1[_a];
|
|
723
|
+
if (includes[include])
|
|
724
|
+
includeSet[include] = null;
|
|
725
|
+
else
|
|
726
|
+
delete includeSet[include];
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
}
|
|
730
|
+
for (var include in includeSet) {
|
|
731
|
+
var includeMask = completeFeature(include);
|
|
732
|
+
mask = maskUnion(mask, includeMask);
|
|
733
|
+
}
|
|
734
|
+
}
|
|
735
|
+
if ('versions' in info_1) {
|
|
736
|
+
var families = info_1.families;
|
|
737
|
+
var versions_1 = info_1.versions;
|
|
738
|
+
if (inherits != null)
|
|
739
|
+
families !== null && families !== void 0 ? families : (families = familiesMap[inherits]);
|
|
740
|
+
familiesMap[name] = families;
|
|
741
|
+
var tag_1 = getInfoStringField('compatibilityTag');
|
|
742
|
+
var shortTag_1 = getInfoStringField('compatibilityShortTag');
|
|
743
|
+
compatibilities =
|
|
744
|
+
families.map(function (family, index) {
|
|
745
|
+
var _a;
|
|
746
|
+
family = esToString(family);
|
|
747
|
+
var versionInfo = versions_1[index];
|
|
748
|
+
var version;
|
|
749
|
+
if (_Array_isArray(versionInfo)) {
|
|
750
|
+
var length_1 = versionInfo.length;
|
|
751
|
+
var from = esToString(versionInfo[0]);
|
|
752
|
+
var to = length_1 < 2 ? undefined : esToString(versionInfo[length_1 - 1]);
|
|
753
|
+
var dense = versionInfo.length === 2;
|
|
754
|
+
version = _Object_freeze({ from: from, to: to, dense: dense });
|
|
755
|
+
}
|
|
756
|
+
else
|
|
757
|
+
version = esToString(versionInfo);
|
|
758
|
+
var compatibility = _Object_freeze({ family: family, featureName: name, version: version, tag: tag_1, shortTag: shortTag_1 });
|
|
759
|
+
var familyCompatibilities = (_a = FAMILIES[family]) !== null && _a !== void 0 ? _a : (FAMILIES[family] = []);
|
|
760
|
+
familyCompatibilities.push(compatibility);
|
|
761
|
+
return compatibility;
|
|
762
|
+
});
|
|
763
|
+
if (description == null)
|
|
764
|
+
description = formatEngineDescription === null || formatEngineDescription === void 0 ? void 0 : formatEngineDescription(compatibilities);
|
|
765
|
+
}
|
|
766
|
+
var attributes = createMap();
|
|
767
|
+
if (inherits != null) {
|
|
768
|
+
var inheritedAttributes = ALL[inherits].attributes;
|
|
769
|
+
for (var attributeName in inheritedAttributes)
|
|
770
|
+
attributes[attributeName] = inheritedAttributes[attributeName];
|
|
771
|
+
}
|
|
772
|
+
{
|
|
773
|
+
var infoAttributes = info_1.attributes;
|
|
774
|
+
if (infoAttributes !== undefined) {
|
|
775
|
+
var attributeNames = _Object_keys(infoAttributes);
|
|
776
|
+
for (var _b = 0, attributeNames_1 = attributeNames; _b < attributeNames_1.length; _b++) {
|
|
777
|
+
var attributeName = attributeNames_1[_b];
|
|
778
|
+
var attributeValue = infoAttributes[attributeName];
|
|
779
|
+
if (attributeValue !== undefined) {
|
|
780
|
+
attributes[attributeName] =
|
|
781
|
+
typeof attributeValue === 'string' ? attributeValue : null;
|
|
782
|
+
}
|
|
783
|
+
else
|
|
784
|
+
delete attributes[attributeName];
|
|
785
|
+
}
|
|
786
|
+
}
|
|
787
|
+
}
|
|
788
|
+
var elementary = wrappedCheck !== null && wrappedCheck !== void 0 ? wrappedCheck : info_1.excludes;
|
|
789
|
+
featureObj = createFeature(name, mask, wrappedCheck, attributes, elementary);
|
|
790
|
+
if (elementary)
|
|
791
|
+
ELEMENTARY.push(featureObj);
|
|
792
|
+
if (compatibilities)
|
|
793
|
+
ENGINE.push(featureObj);
|
|
794
|
+
}
|
|
795
|
+
ALL[name] = featureObj;
|
|
796
|
+
DESCRIPTION_MAP[name] = description;
|
|
797
|
+
}
|
|
798
|
+
return mask;
|
|
799
|
+
}
|
|
800
|
+
{
|
|
801
|
+
var constructorSource = {
|
|
802
|
+
ALL: ALL,
|
|
803
|
+
ELEMENTARY: ELEMENTARY,
|
|
804
|
+
ENGINE: ENGINE,
|
|
805
|
+
FAMILIES: FAMILIES,
|
|
806
|
+
_fromMask: _fromMask,
|
|
807
|
+
_getMask: _getMask,
|
|
808
|
+
areCompatible: areCompatible,
|
|
809
|
+
areEqual: areEqual,
|
|
810
|
+
commonOf: commonOf,
|
|
811
|
+
descriptionFor: descriptionFor,
|
|
812
|
+
};
|
|
813
|
+
assignNoEnum(Feature, constructorSource);
|
|
814
|
+
}
|
|
815
|
+
if (utilInspect) {
|
|
816
|
+
var inspectKey = utilInspect.custom;
|
|
817
|
+
if (inspectKey) {
|
|
818
|
+
_Object_defineProperty(FEATURE_PROTOTYPE, inspectKey, { configurable: true, value: inspect, writable: true });
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
var featureNames = _Object_keys(featureInfos);
|
|
822
|
+
var includeSetMap = createMap();
|
|
823
|
+
var familiesMap = createMap();
|
|
824
|
+
var unionMask = maskNew();
|
|
825
|
+
featureNames.forEach(completeFeature);
|
|
826
|
+
completeExclusions();
|
|
827
|
+
PRISTINE_ELEMENTARY = ELEMENTARY.slice();
|
|
828
|
+
ELEMENTARY.sort(compareFeatureNames);
|
|
829
|
+
_Object_freeze(ELEMENTARY);
|
|
830
|
+
ENGINE.sort(compareFeatureNames);
|
|
831
|
+
_Object_freeze(ENGINE);
|
|
832
|
+
_Object_freeze(ALL);
|
|
833
|
+
_Object_freeze(FAMILIES);
|
|
834
|
+
for (var family in FAMILIES)
|
|
835
|
+
_Object_freeze(FAMILIES[family]);
|
|
836
|
+
})();
|
|
837
|
+
return Feature;
|
|
838
|
+
}
|
|
839
|
+
var createMap = function () { return _Object_create(null); };
|
|
840
|
+
function esToString(name) {
|
|
841
|
+
if (typeof name === 'symbol')
|
|
842
|
+
throw new _TypeError('Cannot convert a symbol to a string');
|
|
843
|
+
var str = _String(name);
|
|
844
|
+
return str;
|
|
845
|
+
}
|
|
846
|
+
function featuresToMask(featureObjs) {
|
|
847
|
+
var mask = featureObjs.reduce(function (mask, featureObj) { return maskUnion(mask, featureObj.mask); }, maskNew());
|
|
848
|
+
return mask;
|
|
849
|
+
}
|
|
850
|
+
function indent(text) {
|
|
851
|
+
var returnValue = text.replace(/^/gm, ' ');
|
|
852
|
+
return returnValue;
|
|
853
|
+
}
|
|
854
|
+
function initMask(featureObj, mask) {
|
|
855
|
+
_Object_defineProperty(featureObj, 'mask', { value: mask });
|
|
856
|
+
}
|
|
857
|
+
function joinParts(compact, intro, preSeparator, parts, partSeparator, outro, maxLength) {
|
|
858
|
+
function isMultiline() {
|
|
859
|
+
var length = intro.length +
|
|
860
|
+
preSeparator.length +
|
|
861
|
+
(parts.length - 1) * (partSeparator.length + 1) +
|
|
862
|
+
outro.length;
|
|
863
|
+
for (var _i = 0, parts_1 = parts; _i < parts_1.length; _i++) {
|
|
864
|
+
var part = parts_1[_i];
|
|
865
|
+
if (~part.indexOf('\n'))
|
|
866
|
+
return true;
|
|
867
|
+
length += part.replace(/\x1b\[\d+m/g, '').length;
|
|
868
|
+
if (length > maxLength)
|
|
869
|
+
return true;
|
|
870
|
+
}
|
|
871
|
+
return false;
|
|
872
|
+
}
|
|
873
|
+
var str = parts.length && (!compact || isMultiline()) ?
|
|
874
|
+
intro + "\n" + indent(parts.join(partSeparator + "\n")) + "\n" + outro :
|
|
875
|
+
"" + intro + preSeparator + parts.join(partSeparator + " ") + outro;
|
|
876
|
+
return str;
|
|
877
|
+
}
|
|
878
|
+
function throwUnknownFeatureError(name) {
|
|
879
|
+
throw new _Error("Unknown feature " + _JSON_stringify(name));
|
|
426
880
|
}
|
|
881
|
+
function wrapCheck(check) {
|
|
882
|
+
var wrappedCheck = function () { return !!check(); };
|
|
883
|
+
return wrappedCheck;
|
|
884
|
+
}
|
|
885
|
+
|
|
886
|
+
// End of module ~feature-hub
|
|
887
|
+
|
|
888
|
+
var ELEMENTARY;
|
|
889
|
+
var Feature;
|
|
427
890
|
|
|
428
891
|
function checkLocaleNumeral(locale, number, regExp)
|
|
429
892
|
{
|
|
@@ -447,2147 +910,1303 @@
|
|
|
447
910
|
return available;
|
|
448
911
|
}
|
|
449
912
|
|
|
450
|
-
function
|
|
451
|
-
{
|
|
452
|
-
var returnValue;
|
|
453
|
-
if (arguments.length)
|
|
454
|
-
{
|
|
455
|
-
var mask;
|
|
456
|
-
_Array_prototype_forEach_call
|
|
457
|
-
(
|
|
458
|
-
arguments,
|
|
459
|
-
function (arg)
|
|
460
|
-
{
|
|
461
|
-
var otherMask = validMaskFromArrayOrStringOrFeature(arg);
|
|
462
|
-
if (mask != null)
|
|
463
|
-
mask = maskIntersection(mask, otherMask);
|
|
464
|
-
else
|
|
465
|
-
mask = otherMask;
|
|
466
|
-
}
|
|
467
|
-
);
|
|
468
|
-
returnValue = featureFromMask(mask);
|
|
469
|
-
}
|
|
470
|
-
else
|
|
471
|
-
returnValue = null;
|
|
472
|
-
return returnValue;
|
|
473
|
-
}
|
|
474
|
-
|
|
475
|
-
function descriptionFor(name)
|
|
913
|
+
function describeEngine(engine)
|
|
476
914
|
{
|
|
477
|
-
|
|
478
|
-
var description = DESCRIPTION_MAP[name];
|
|
479
|
-
if (description == null)
|
|
480
|
-
throw new _Error('Unknown feature ' + _JSON_stringify(name));
|
|
915
|
+
var description = 'Features available in ' + engine + '.';
|
|
481
916
|
return description;
|
|
482
917
|
}
|
|
483
918
|
|
|
484
|
-
function
|
|
485
|
-
{
|
|
486
|
-
var mask = maskNew();
|
|
487
|
-
_Array_prototype_forEach_call
|
|
488
|
-
(
|
|
489
|
-
arrayLike,
|
|
490
|
-
function (feature)
|
|
491
|
-
{
|
|
492
|
-
var otherMask = maskFromStringOrFeature(feature);
|
|
493
|
-
mask = maskUnion(mask, otherMask);
|
|
494
|
-
}
|
|
495
|
-
);
|
|
496
|
-
return mask;
|
|
497
|
-
}
|
|
498
|
-
|
|
499
|
-
function featureFromMask(mask)
|
|
500
|
-
{
|
|
501
|
-
var featureObj = _Object_create(FEATURE_PROTOTYPE);
|
|
502
|
-
initMask(featureObj, mask);
|
|
503
|
-
return featureObj;
|
|
504
|
-
}
|
|
505
|
-
|
|
506
|
-
function featuresToMask(featureObjs)
|
|
507
|
-
{
|
|
508
|
-
var mask = maskNew();
|
|
509
|
-
featureObjs.forEach
|
|
510
|
-
(
|
|
511
|
-
function (featureObj)
|
|
512
|
-
{
|
|
513
|
-
mask = maskUnion(mask, featureObj.mask);
|
|
514
|
-
}
|
|
515
|
-
);
|
|
516
|
-
return mask;
|
|
517
|
-
}
|
|
518
|
-
|
|
519
|
-
function initMask(featureObj, mask)
|
|
520
|
-
{
|
|
521
|
-
_Object_defineProperty(featureObj, 'mask', { value: mask });
|
|
522
|
-
}
|
|
523
|
-
|
|
524
|
-
/**
|
|
525
|
-
* Node.js custom inspection function.
|
|
526
|
-
* Set on `Feature.prototype` with name `"inspect"` for Node.js ≤ 8.6.x and with symbol
|
|
527
|
-
* `Symbol.for("nodejs.util.inspect.custom")` for Node.js ≥ 6.6.x.
|
|
528
|
-
*
|
|
529
|
-
* @function inspect
|
|
530
|
-
*
|
|
531
|
-
* @see
|
|
532
|
-
* {@link https://tiny.cc/j4wz9y|Custom inspection functions on Objects} for further information.
|
|
533
|
-
*/
|
|
534
|
-
function inspect(depth, opts)
|
|
535
|
-
{
|
|
536
|
-
var returnValue;
|
|
537
|
-
var str = this.toString();
|
|
538
|
-
if (opts !== undefined) // opts can be undefined in Node.js 0.10.0.
|
|
539
|
-
returnValue = opts.stylize(str, 'jscrewit-feature');
|
|
540
|
-
else
|
|
541
|
-
returnValue = str;
|
|
542
|
-
return returnValue;
|
|
543
|
-
}
|
|
544
|
-
|
|
545
|
-
function isExcludingAttribute(attributeCache, attributeName, featureObjs)
|
|
919
|
+
function isExcludingAttribute(restrictionCache, restrictionName, featureObjs)
|
|
546
920
|
{
|
|
547
|
-
var returnValue =
|
|
921
|
+
var returnValue = restrictionCache[restrictionName];
|
|
548
922
|
if (returnValue === undefined)
|
|
549
923
|
{
|
|
550
|
-
|
|
924
|
+
restrictionCache[restrictionName] =
|
|
551
925
|
returnValue =
|
|
552
926
|
featureObjs.some
|
|
553
927
|
(
|
|
554
928
|
function (featureObj)
|
|
555
929
|
{
|
|
556
|
-
|
|
930
|
+
var returnValue = restrictionName in featureObj.attributes;
|
|
931
|
+
return returnValue;
|
|
557
932
|
}
|
|
558
933
|
);
|
|
559
934
|
}
|
|
560
935
|
return returnValue;
|
|
561
936
|
}
|
|
562
937
|
|
|
563
|
-
function
|
|
938
|
+
function restrict(environment, engineFeatureObjs)
|
|
564
939
|
{
|
|
565
|
-
var
|
|
566
|
-
|
|
940
|
+
var restrictionCache = createEmpty();
|
|
941
|
+
var elementaryFeatureObjs =
|
|
942
|
+
ELEMENTARY.filter
|
|
567
943
|
(
|
|
568
|
-
function (
|
|
944
|
+
function (elementaryFeatureObj)
|
|
569
945
|
{
|
|
570
|
-
var
|
|
571
|
-
|
|
572
|
-
|
|
946
|
+
var included = this.includes(elementaryFeatureObj);
|
|
947
|
+
if (included)
|
|
948
|
+
{
|
|
949
|
+
var attributes = elementaryFeatureObj.attributes;
|
|
950
|
+
included =
|
|
951
|
+
!(
|
|
952
|
+
environment in attributes &&
|
|
953
|
+
(
|
|
954
|
+
engineFeatureObjs === undefined ||
|
|
955
|
+
isExcludingAttribute
|
|
956
|
+
(restrictionCache, attributes[environment], engineFeatureObjs)
|
|
957
|
+
)
|
|
958
|
+
);
|
|
959
|
+
}
|
|
960
|
+
return included;
|
|
961
|
+
},
|
|
962
|
+
this
|
|
573
963
|
);
|
|
574
|
-
|
|
964
|
+
var restrictedFeatureObj = Feature(elementaryFeatureObjs);
|
|
965
|
+
return restrictedFeatureObj;
|
|
575
966
|
}
|
|
576
967
|
|
|
577
|
-
|
|
968
|
+
var featureInfos =
|
|
578
969
|
{
|
|
579
|
-
|
|
580
|
-
if (arg instanceof Feature)
|
|
581
|
-
mask = arg.mask;
|
|
582
|
-
else
|
|
970
|
+
ANY_DOCUMENT:
|
|
583
971
|
{
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
}
|
|
590
|
-
return mask;
|
|
591
|
-
}
|
|
592
|
-
|
|
593
|
-
function validateMask(mask)
|
|
594
|
-
{
|
|
595
|
-
if (!isMaskCompatible(mask))
|
|
596
|
-
throw new _Error('Incompatible features');
|
|
597
|
-
}
|
|
598
|
-
|
|
599
|
-
function validMaskFromArguments(args)
|
|
600
|
-
{
|
|
601
|
-
var mask = maskNew();
|
|
602
|
-
var validationNeeded = 0;
|
|
603
|
-
_Array_prototype_forEach_call
|
|
604
|
-
(
|
|
605
|
-
args,
|
|
606
|
-
function (arg)
|
|
972
|
+
description:
|
|
973
|
+
'Existence of the global object document whose string representation starts with ' +
|
|
974
|
+
'"[object " and ends with "Document]".',
|
|
975
|
+
check:
|
|
976
|
+
function ()
|
|
607
977
|
{
|
|
608
|
-
var
|
|
609
|
-
|
|
978
|
+
var available =
|
|
979
|
+
typeof document === 'object' && /^\[object [\S\s]*Document]$/.test(document + '');
|
|
980
|
+
return available;
|
|
981
|
+
},
|
|
982
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
983
|
+
},
|
|
984
|
+
ANY_WINDOW:
|
|
985
|
+
{
|
|
986
|
+
description:
|
|
987
|
+
'Existence of the global object self whose string representation starts with "[object " ' +
|
|
988
|
+
'and ends with "Window]".',
|
|
989
|
+
check:
|
|
990
|
+
checkSelfFeature.bind
|
|
991
|
+
(
|
|
992
|
+
function (str)
|
|
610
993
|
{
|
|
611
|
-
|
|
612
|
-
|
|
994
|
+
var available = /^\[object [\S\s]*Window]$/.test(str);
|
|
995
|
+
return available;
|
|
613
996
|
}
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
validationNeeded |= args.length > 1;
|
|
620
|
-
if (validationNeeded)
|
|
621
|
-
validateMask(mask);
|
|
622
|
-
return mask;
|
|
623
|
-
}
|
|
624
|
-
|
|
625
|
-
function validMaskFromArrayOrStringOrFeature(arg)
|
|
626
|
-
{
|
|
627
|
-
var mask;
|
|
628
|
-
if (_Array_isArray(arg))
|
|
629
|
-
{
|
|
630
|
-
mask = featureArrayLikeToMask(arg);
|
|
631
|
-
if (arg.length > 1)
|
|
632
|
-
validateMask(mask);
|
|
633
|
-
}
|
|
634
|
-
else
|
|
635
|
-
mask = maskFromStringOrFeature(arg);
|
|
636
|
-
return mask;
|
|
637
|
-
}
|
|
638
|
-
|
|
639
|
-
function wrapCheck(check)
|
|
640
|
-
{
|
|
641
|
-
var returnValue =
|
|
642
|
-
function ()
|
|
997
|
+
),
|
|
998
|
+
includes: ['SELF_OBJ'],
|
|
999
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1000
|
+
},
|
|
1001
|
+
ARRAY_ITERATOR:
|
|
643
1002
|
{
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
1003
|
+
description:
|
|
1004
|
+
'The property that the string representation of Array.prototype.entries() starts with ' +
|
|
1005
|
+
'"[object Array" and ends with "]" at index 21 or 22.',
|
|
1006
|
+
check:
|
|
1007
|
+
function ()
|
|
1008
|
+
{
|
|
1009
|
+
var available =
|
|
1010
|
+
Array.prototype.entries && /^\[object Array[\S\s]{8,9}]$/.test([].entries());
|
|
1011
|
+
return available;
|
|
1012
|
+
},
|
|
1013
|
+
},
|
|
1014
|
+
ARROW:
|
|
653
1015
|
{
|
|
654
|
-
|
|
1016
|
+
description: 'Support for arrow functions.',
|
|
1017
|
+
check:
|
|
1018
|
+
function ()
|
|
655
1019
|
{
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
var included = maskIncludes(mask, featureObj.mask);
|
|
664
|
-
if (included)
|
|
665
|
-
{
|
|
666
|
-
var name = featureObj.name;
|
|
667
|
-
featureNameSet[name] = null;
|
|
668
|
-
var includes = INCLUDES_MAP[name];
|
|
669
|
-
_Array_prototype_push_apply(allIncludes, includes);
|
|
670
|
-
}
|
|
671
|
-
}
|
|
672
|
-
);
|
|
673
|
-
allIncludes.forEach
|
|
674
|
-
(
|
|
675
|
-
function (name)
|
|
676
|
-
{
|
|
677
|
-
delete featureNameSet[name];
|
|
678
|
-
}
|
|
679
|
-
);
|
|
680
|
-
var names = _Object_keys(featureNameSet).sort();
|
|
681
|
-
return names;
|
|
682
|
-
},
|
|
683
|
-
|
|
684
|
-
elementary: false,
|
|
685
|
-
|
|
686
|
-
get elementaryNames()
|
|
687
|
-
{
|
|
688
|
-
var names = [];
|
|
689
|
-
var mask = this.mask;
|
|
690
|
-
ELEMENTARY.forEach
|
|
691
|
-
(
|
|
692
|
-
function (featureObj)
|
|
693
|
-
{
|
|
694
|
-
var included = maskIncludes(mask, featureObj.mask);
|
|
695
|
-
if (included)
|
|
696
|
-
names.push(featureObj.name);
|
|
697
|
-
}
|
|
698
|
-
);
|
|
699
|
-
return names;
|
|
1020
|
+
try
|
|
1021
|
+
{
|
|
1022
|
+
Function('()=>{}')();
|
|
1023
|
+
return true;
|
|
1024
|
+
}
|
|
1025
|
+
catch (error)
|
|
1026
|
+
{ }
|
|
700
1027
|
},
|
|
701
|
-
|
|
702
|
-
|
|
1028
|
+
},
|
|
1029
|
+
AT:
|
|
1030
|
+
{
|
|
1031
|
+
description: 'Existence of the native function Array.prototype.at.',
|
|
1032
|
+
check:
|
|
703
1033
|
function ()
|
|
704
1034
|
{
|
|
705
|
-
var
|
|
706
|
-
|
|
707
|
-
_Array_prototype_every_call
|
|
708
|
-
(
|
|
709
|
-
arguments,
|
|
710
|
-
function (arg)
|
|
711
|
-
{
|
|
712
|
-
var otherMask = validMaskFromArrayOrStringOrFeature(arg);
|
|
713
|
-
var returnValue = maskIncludes(mask, otherMask);
|
|
714
|
-
return returnValue;
|
|
715
|
-
}
|
|
716
|
-
);
|
|
717
|
-
return included;
|
|
718
|
-
},
|
|
719
|
-
|
|
720
|
-
inspect: inspect,
|
|
721
|
-
|
|
722
|
-
name: undefined,
|
|
723
|
-
|
|
724
|
-
restrict:
|
|
725
|
-
function (environment, engineFeatureObjs)
|
|
726
|
-
{
|
|
727
|
-
var resultMask = maskNew();
|
|
728
|
-
var thisMask = this.mask;
|
|
729
|
-
var attributeCache = createEmpty();
|
|
730
|
-
ELEMENTARY.forEach
|
|
731
|
-
(
|
|
732
|
-
function (featureObj)
|
|
733
|
-
{
|
|
734
|
-
var otherMask = featureObj.mask;
|
|
735
|
-
var included = maskIncludes(thisMask, otherMask);
|
|
736
|
-
if (included)
|
|
737
|
-
{
|
|
738
|
-
var attributeValue = featureObj.attributes[environment];
|
|
739
|
-
if
|
|
740
|
-
(
|
|
741
|
-
attributeValue === undefined ||
|
|
742
|
-
engineFeatureObjs !== undefined &&
|
|
743
|
-
!isExcludingAttribute(attributeCache, attributeValue, engineFeatureObjs)
|
|
744
|
-
)
|
|
745
|
-
resultMask = maskUnion(resultMask, otherMask);
|
|
746
|
-
}
|
|
747
|
-
}
|
|
748
|
-
);
|
|
749
|
-
var returnValue = featureFromMask(resultMask);
|
|
750
|
-
return returnValue;
|
|
1035
|
+
var available = Array.prototype.at;
|
|
1036
|
+
return available;
|
|
751
1037
|
},
|
|
752
|
-
|
|
753
|
-
|
|
1038
|
+
},
|
|
1039
|
+
ATOB:
|
|
1040
|
+
{
|
|
1041
|
+
description: 'Existence of the global functions atob and btoa.',
|
|
1042
|
+
check:
|
|
754
1043
|
function ()
|
|
755
1044
|
{
|
|
756
|
-
var
|
|
757
|
-
|
|
758
|
-
name = '{' + this.canonicalNames.join(', ') + '}';
|
|
759
|
-
var str = '[Feature ' + name + ']';
|
|
760
|
-
return str;
|
|
1045
|
+
var available = typeof atob === 'function' && typeof btoa === 'function';
|
|
1046
|
+
return available;
|
|
761
1047
|
},
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
(function (featureInfos)
|
|
766
|
-
{
|
|
767
|
-
function completeExclusions()
|
|
768
|
-
{
|
|
769
|
-
var incompatibleMaskSet = new MaskSet();
|
|
770
|
-
featureNames.forEach
|
|
771
|
-
(
|
|
772
|
-
function (name)
|
|
773
|
-
{
|
|
774
|
-
var info = featureInfos[name];
|
|
775
|
-
var excludes = info.excludes;
|
|
776
|
-
if (excludes)
|
|
777
|
-
{
|
|
778
|
-
var featureObj = ALL[name];
|
|
779
|
-
var mask = featureObj.mask;
|
|
780
|
-
excludes.forEach
|
|
781
|
-
(
|
|
782
|
-
function (exclude)
|
|
783
|
-
{
|
|
784
|
-
var excludeMask = completeFeature(exclude);
|
|
785
|
-
var incompatibleMask = maskUnion(mask, excludeMask);
|
|
786
|
-
if (!incompatibleMaskSet.has(incompatibleMask))
|
|
787
|
-
{
|
|
788
|
-
INCOMPATIBLE_MASK_LIST.push(incompatibleMask);
|
|
789
|
-
incompatibleMaskSet.add(incompatibleMask);
|
|
790
|
-
}
|
|
791
|
-
}
|
|
792
|
-
);
|
|
793
|
-
}
|
|
794
|
-
}
|
|
795
|
-
);
|
|
796
|
-
}
|
|
797
|
-
|
|
798
|
-
function completeFeature(name)
|
|
799
|
-
{
|
|
800
|
-
var mask;
|
|
801
|
-
var featureObj = ALL[name];
|
|
802
|
-
if (featureObj)
|
|
803
|
-
mask = featureObj.mask;
|
|
804
|
-
else
|
|
805
|
-
{
|
|
806
|
-
var description;
|
|
807
|
-
var info = featureInfos[name];
|
|
808
|
-
var engine = info.engine;
|
|
809
|
-
if (engine == null)
|
|
810
|
-
description = info.description;
|
|
811
|
-
else
|
|
812
|
-
description = createEngineFeatureDescription(engine);
|
|
813
|
-
var aliasFor = info.aliasFor;
|
|
814
|
-
if (aliasFor != null)
|
|
815
|
-
{
|
|
816
|
-
mask = completeFeature(aliasFor);
|
|
817
|
-
featureObj = ALL[aliasFor];
|
|
818
|
-
if (description == null)
|
|
819
|
-
description = DESCRIPTION_MAP[aliasFor];
|
|
820
|
-
}
|
|
821
|
-
else
|
|
822
|
-
{
|
|
823
|
-
var check = info.check;
|
|
824
|
-
if (check)
|
|
825
|
-
{
|
|
826
|
-
mask = maskNext(unionMask);
|
|
827
|
-
unionMask = maskUnion(unionMask, mask);
|
|
828
|
-
if (check())
|
|
829
|
-
autoMask = maskUnion(autoMask, mask);
|
|
830
|
-
check = wrapCheck(check);
|
|
831
|
-
}
|
|
832
|
-
else
|
|
833
|
-
mask = maskNew();
|
|
834
|
-
var includes = INCLUDES_MAP[name] = info.includes || [];
|
|
835
|
-
includes.forEach
|
|
836
|
-
(
|
|
837
|
-
function (include)
|
|
838
|
-
{
|
|
839
|
-
var includeMask = completeFeature(include);
|
|
840
|
-
mask = maskUnion(mask, includeMask);
|
|
841
|
-
}
|
|
842
|
-
);
|
|
843
|
-
var elementary = check || info.excludes;
|
|
844
|
-
featureObj = createFeature(name, mask, check, engine, info.attributes, elementary);
|
|
845
|
-
if (elementary)
|
|
846
|
-
ELEMENTARY.push(featureObj);
|
|
847
|
-
}
|
|
848
|
-
registerFeature(name, description, featureObj);
|
|
849
|
-
}
|
|
850
|
-
return mask;
|
|
851
|
-
}
|
|
852
|
-
|
|
853
|
-
function createEngineFeatureDescription(engine)
|
|
854
|
-
{
|
|
855
|
-
var description = 'Features available in ' + engine + '.';
|
|
856
|
-
return description;
|
|
857
|
-
}
|
|
858
|
-
|
|
859
|
-
function createFeature(name, mask, check, engine, attributes, elementary)
|
|
860
|
-
{
|
|
861
|
-
attributes = _Object_freeze(attributes || { });
|
|
862
|
-
var descriptors =
|
|
863
|
-
{
|
|
864
|
-
attributes: { value: attributes },
|
|
865
|
-
check: { value: check },
|
|
866
|
-
engine: { value: engine },
|
|
867
|
-
name: { value: name },
|
|
868
|
-
};
|
|
869
|
-
if (elementary)
|
|
870
|
-
descriptors.elementary = { value: true };
|
|
871
|
-
var featureObj = _Object_create(FEATURE_PROTOTYPE, descriptors);
|
|
872
|
-
initMask(featureObj, mask);
|
|
873
|
-
return featureObj;
|
|
874
|
-
}
|
|
875
|
-
|
|
876
|
-
function registerFeature(name, description, featureObj)
|
|
877
|
-
{
|
|
878
|
-
var descriptor = { enumerable: true, value: featureObj };
|
|
879
|
-
_Object_defineProperty(Feature, name, descriptor);
|
|
880
|
-
ALL[name] = featureObj;
|
|
881
|
-
DESCRIPTION_MAP[name] = description;
|
|
882
|
-
}
|
|
883
|
-
|
|
884
|
-
var constructorSource =
|
|
885
|
-
{
|
|
886
|
-
ALL: ALL,
|
|
887
|
-
ELEMENTARY: ELEMENTARY,
|
|
888
|
-
areCompatible: areCompatible,
|
|
889
|
-
areEqual: areEqual,
|
|
890
|
-
commonOf: commonOf,
|
|
891
|
-
descriptionFor: descriptionFor,
|
|
892
|
-
};
|
|
893
|
-
assignNoEnum(Feature, constructorSource);
|
|
894
|
-
|
|
895
|
-
try
|
|
896
|
-
{
|
|
897
|
-
var inspectKey = require('util').inspect.custom;
|
|
898
|
-
}
|
|
899
|
-
catch (error)
|
|
900
|
-
{ }
|
|
901
|
-
if (inspectKey)
|
|
902
|
-
{
|
|
903
|
-
_Object_defineProperty
|
|
904
|
-
(FEATURE_PROTOTYPE, inspectKey, { configurable: true, value: inspect, writable: true });
|
|
905
|
-
}
|
|
906
|
-
|
|
907
|
-
var autoMask = maskNew();
|
|
908
|
-
var unionMask = maskNew();
|
|
909
|
-
|
|
910
|
-
var featureNames = _Object_keys(featureInfos);
|
|
911
|
-
featureNames.forEach(completeFeature);
|
|
912
|
-
completeExclusions();
|
|
913
|
-
ELEMENTARY.sort
|
|
914
|
-
(
|
|
915
|
-
function (feature1, feature2)
|
|
916
|
-
{
|
|
917
|
-
var returnValue = feature1.name < feature2.name ? -1 : 1;
|
|
918
|
-
return returnValue;
|
|
919
|
-
}
|
|
920
|
-
);
|
|
921
|
-
_Object_freeze(ELEMENTARY);
|
|
922
|
-
var autoFeatureObj = createFeature('AUTO', autoMask);
|
|
923
|
-
registerFeature('AUTO', 'All features available in the current engine.', autoFeatureObj);
|
|
924
|
-
_Object_freeze(ALL);
|
|
925
|
-
})
|
|
926
|
-
(
|
|
1048
|
+
attributes: { 'web-worker': 'old-safari-restriction' },
|
|
1049
|
+
},
|
|
1050
|
+
BARPROP:
|
|
927
1051
|
{
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
check:
|
|
934
|
-
function ()
|
|
935
|
-
{
|
|
936
|
-
var available =
|
|
937
|
-
typeof document === 'object' && /^\[object .*Document]$/.test(document + '');
|
|
938
|
-
return available;
|
|
939
|
-
},
|
|
940
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
941
|
-
},
|
|
942
|
-
ANY_WINDOW:
|
|
943
|
-
{
|
|
944
|
-
description:
|
|
945
|
-
'Existence of the global object self whose string representation starts with ' +
|
|
946
|
-
'"[object " and ends with "Window]".',
|
|
947
|
-
check:
|
|
948
|
-
checkSelfFeature.bind
|
|
949
|
-
(
|
|
950
|
-
function (str)
|
|
951
|
-
{
|
|
952
|
-
var available = /^\[object .*Window]$/.test(str);
|
|
953
|
-
return available;
|
|
954
|
-
}
|
|
955
|
-
),
|
|
956
|
-
includes: ['SELF_OBJ'],
|
|
957
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
958
|
-
},
|
|
959
|
-
ARRAY_ITERATOR:
|
|
960
|
-
{
|
|
961
|
-
description:
|
|
962
|
-
'The property that the string representation of Array.prototype.entries() starts ' +
|
|
963
|
-
'with "[object Array" and ends with "]" at index 21 or 22.',
|
|
964
|
-
check:
|
|
965
|
-
function ()
|
|
966
|
-
{
|
|
967
|
-
var available =
|
|
968
|
-
Array.prototype.entries && /^\[object Array.{8,9}]$/.test([].entries());
|
|
969
|
-
return available;
|
|
970
|
-
},
|
|
971
|
-
},
|
|
972
|
-
ARROW:
|
|
973
|
-
{
|
|
974
|
-
description: 'Support for arrow functions.',
|
|
975
|
-
check:
|
|
976
|
-
function ()
|
|
977
|
-
{
|
|
978
|
-
try
|
|
979
|
-
{
|
|
980
|
-
Function('()=>{}')();
|
|
981
|
-
return true;
|
|
982
|
-
}
|
|
983
|
-
catch (error)
|
|
984
|
-
{ }
|
|
985
|
-
},
|
|
986
|
-
},
|
|
987
|
-
AT:
|
|
988
|
-
{
|
|
989
|
-
description: 'Existence of the native function Array.prototype.at.',
|
|
990
|
-
check:
|
|
991
|
-
function ()
|
|
992
|
-
{
|
|
993
|
-
var available = Array.prototype.at;
|
|
994
|
-
return available;
|
|
995
|
-
},
|
|
996
|
-
},
|
|
997
|
-
ATOB:
|
|
998
|
-
{
|
|
999
|
-
description: 'Existence of the global functions atob and btoa.',
|
|
1000
|
-
check:
|
|
1001
|
-
function ()
|
|
1002
|
-
{
|
|
1003
|
-
var available = typeof atob === 'function' && typeof btoa === 'function';
|
|
1004
|
-
return available;
|
|
1005
|
-
},
|
|
1006
|
-
attributes: { 'web-worker': 'no-atob-in-web-worker' },
|
|
1007
|
-
},
|
|
1008
|
-
BARPROP:
|
|
1009
|
-
{
|
|
1010
|
-
description:
|
|
1011
|
-
'Existence of the global object statusbar having the string representation "[object ' +
|
|
1012
|
-
'BarProp]".',
|
|
1013
|
-
check:
|
|
1014
|
-
function ()
|
|
1015
|
-
{
|
|
1016
|
-
var available =
|
|
1017
|
-
typeof statusbar === 'object' && statusbar + '' === '[object BarProp]';
|
|
1018
|
-
return available;
|
|
1019
|
-
},
|
|
1020
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1021
|
-
},
|
|
1022
|
-
CAPITAL_HTML:
|
|
1023
|
-
{
|
|
1024
|
-
description:
|
|
1025
|
-
'The property that the various string methods returning HTML code such as ' +
|
|
1026
|
-
'String.prototype.big or String.prototype.link have both the tag name and attributes ' +
|
|
1027
|
-
'written in capital letters.',
|
|
1028
|
-
check:
|
|
1029
|
-
function ()
|
|
1030
|
-
{
|
|
1031
|
-
var available =
|
|
1032
|
-
''.big() === '<BIG></BIG>' &&
|
|
1033
|
-
''.fontcolor('') === '<FONT COLOR=""></FONT>' &&
|
|
1034
|
-
''.fontsize('') === '<FONT SIZE=""></FONT>' &&
|
|
1035
|
-
''.link('') === '<A HREF=""></A>' &&
|
|
1036
|
-
''.small() === '<SMALL></SMALL>' &&
|
|
1037
|
-
''.strike() === '<STRIKE></STRIKE>' &&
|
|
1038
|
-
''.sub() === '<SUB></SUB>' &&
|
|
1039
|
-
''.sup() === '<SUP></SUP>';
|
|
1040
|
-
return available;
|
|
1041
|
-
},
|
|
1042
|
-
},
|
|
1043
|
-
CONSOLE:
|
|
1044
|
-
{
|
|
1045
|
-
description:
|
|
1046
|
-
'Existence of the global object console having the string representation "[object ' +
|
|
1047
|
-
'Console]".\n' +
|
|
1048
|
-
'This feature may become unavailable when certain browser extensions are active.',
|
|
1049
|
-
check:
|
|
1050
|
-
function ()
|
|
1051
|
-
{
|
|
1052
|
-
var available = typeof console === 'object' && console + '' === '[object Console]';
|
|
1053
|
-
return available;
|
|
1054
|
-
},
|
|
1055
|
-
attributes: { 'web-worker': 'no-console-in-web-worker' },
|
|
1056
|
-
},
|
|
1057
|
-
DOCUMENT:
|
|
1052
|
+
description:
|
|
1053
|
+
'Existence of the global object statusbar having the string representation "[object ' +
|
|
1054
|
+
'BarProp]".',
|
|
1055
|
+
check:
|
|
1056
|
+
function ()
|
|
1058
1057
|
{
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
'Document]".',
|
|
1062
|
-
check:
|
|
1063
|
-
function ()
|
|
1064
|
-
{
|
|
1065
|
-
var available =
|
|
1066
|
-
typeof document === 'object' && document + '' === '[object Document]';
|
|
1067
|
-
return available;
|
|
1068
|
-
},
|
|
1069
|
-
includes: ['ANY_DOCUMENT'],
|
|
1070
|
-
excludes: ['HTMLDOCUMENT'],
|
|
1071
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1058
|
+
var available = typeof statusbar === 'object' && statusbar + '' === '[object BarProp]';
|
|
1059
|
+
return available;
|
|
1072
1060
|
},
|
|
1073
|
-
|
|
1061
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1062
|
+
},
|
|
1063
|
+
CAPITAL_HTML:
|
|
1064
|
+
{
|
|
1065
|
+
description:
|
|
1066
|
+
'The property that the various string methods returning HTML code such as ' +
|
|
1067
|
+
'String.prototype.big or String.prototype.link have both the tag name and attributes ' +
|
|
1068
|
+
'written in capital letters.',
|
|
1069
|
+
check:
|
|
1070
|
+
function ()
|
|
1074
1071
|
{
|
|
1075
|
-
|
|
1076
|
-
'
|
|
1077
|
-
'
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
(
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
}
|
|
1086
|
-
),
|
|
1087
|
-
includes: ['ANY_WINDOW'],
|
|
1088
|
-
excludes: ['WINDOW'],
|
|
1089
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1090
|
-
},
|
|
1091
|
-
ESC_HTML_ALL:
|
|
1092
|
-
{
|
|
1093
|
-
description:
|
|
1094
|
-
'The property that double quotation mark, less than and greater than characters in ' +
|
|
1095
|
-
'the argument of String.prototype.fontcolor are escaped into their respective HTML ' +
|
|
1096
|
-
'entities.',
|
|
1097
|
-
check:
|
|
1098
|
-
function ()
|
|
1099
|
-
{
|
|
1100
|
-
var available = ~''.fontcolor('"<>').indexOf('"<>');
|
|
1101
|
-
return available;
|
|
1102
|
-
},
|
|
1103
|
-
includes: ['ESC_HTML_QUOT'],
|
|
1104
|
-
excludes: ['ESC_HTML_QUOT_ONLY'],
|
|
1072
|
+
var available =
|
|
1073
|
+
''.big() === '<BIG></BIG>' &&
|
|
1074
|
+
''.fontcolor('') === '<FONT COLOR=""></FONT>' &&
|
|
1075
|
+
''.fontsize('') === '<FONT SIZE=""></FONT>' &&
|
|
1076
|
+
''.link('') === '<A HREF=""></A>' &&
|
|
1077
|
+
''.small() === '<SMALL></SMALL>' &&
|
|
1078
|
+
''.strike() === '<STRIKE></STRIKE>' &&
|
|
1079
|
+
''.sub() === '<SUB></SUB>' &&
|
|
1080
|
+
''.sup() === '<SUP></SUP>';
|
|
1081
|
+
return available;
|
|
1105
1082
|
},
|
|
1106
|
-
|
|
1083
|
+
},
|
|
1084
|
+
CONSOLE:
|
|
1085
|
+
{
|
|
1086
|
+
description:
|
|
1087
|
+
'Existence of the global object console having the string representation "[object ' +
|
|
1088
|
+
'Console]".\n' +
|
|
1089
|
+
'This feature may become unavailable when certain browser extensions are active.',
|
|
1090
|
+
check:
|
|
1091
|
+
function ()
|
|
1107
1092
|
{
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
'String.prototype.fontcolor are escaped as """.',
|
|
1111
|
-
check:
|
|
1112
|
-
function ()
|
|
1113
|
-
{
|
|
1114
|
-
var available = ~''.fontcolor('"').indexOf('"');
|
|
1115
|
-
return available;
|
|
1116
|
-
},
|
|
1093
|
+
var available = typeof console === 'object' && console + '' === '[object Console]';
|
|
1094
|
+
return available;
|
|
1117
1095
|
},
|
|
1118
|
-
|
|
1096
|
+
attributes: { 'web-worker': 'no-console-in-web-worker' },
|
|
1097
|
+
},
|
|
1098
|
+
DOCUMENT:
|
|
1099
|
+
{
|
|
1100
|
+
description:
|
|
1101
|
+
'Existence of the global object document having the string representation "[object ' +
|
|
1102
|
+
'Document]".',
|
|
1103
|
+
check:
|
|
1104
|
+
function ()
|
|
1119
1105
|
{
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
'argument of String.prototype.fontcolor are escaped into HTML entities.',
|
|
1123
|
-
check:
|
|
1124
|
-
function ()
|
|
1125
|
-
{
|
|
1126
|
-
var available = ~''.fontcolor('"<>').indexOf('"<>');
|
|
1127
|
-
return available;
|
|
1128
|
-
},
|
|
1129
|
-
includes: ['ESC_HTML_QUOT'],
|
|
1130
|
-
excludes: ['ESC_HTML_ALL'],
|
|
1106
|
+
var available = typeof document === 'object' && document + '' === '[object Document]';
|
|
1107
|
+
return available;
|
|
1131
1108
|
},
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1109
|
+
includes: ['ANY_DOCUMENT'],
|
|
1110
|
+
excludes: ['HTMLDOCUMENT'],
|
|
1111
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1112
|
+
},
|
|
1113
|
+
DOMWINDOW:
|
|
1114
|
+
{
|
|
1115
|
+
description:
|
|
1116
|
+
'Existence of the global object self having the string representation "[object ' +
|
|
1117
|
+
'DOMWindow]".',
|
|
1118
|
+
check:
|
|
1119
|
+
checkSelfFeature.bind
|
|
1120
|
+
(
|
|
1121
|
+
function (str)
|
|
1140
1122
|
{
|
|
1141
|
-
var available =
|
|
1123
|
+
var available = str === '[object DOMWindow]';
|
|
1142
1124
|
return available;
|
|
1143
|
-
}
|
|
1144
|
-
|
|
1145
|
-
|
|
1125
|
+
}
|
|
1126
|
+
),
|
|
1127
|
+
includes: ['ANY_WINDOW'],
|
|
1128
|
+
excludes: ['WINDOW'],
|
|
1129
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1130
|
+
},
|
|
1131
|
+
ESC_HTML_ALL:
|
|
1132
|
+
{
|
|
1133
|
+
description:
|
|
1134
|
+
'The property that double quotation mark, less than and greater than characters in the ' +
|
|
1135
|
+
'argument of String.prototype.fontcolor are escaped into their respective HTML entities.',
|
|
1136
|
+
check:
|
|
1137
|
+
function ()
|
|
1146
1138
|
{
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
'starting with a backslash to format slashes ("/") in their string representation.',
|
|
1150
|
-
check:
|
|
1151
|
-
function ()
|
|
1152
|
-
{
|
|
1153
|
-
var available = (RegExp('/') + '')[1] === '\\';
|
|
1154
|
-
return available;
|
|
1155
|
-
},
|
|
1156
|
-
},
|
|
1157
|
-
FF_SRC:
|
|
1158
|
-
{
|
|
1159
|
-
description:
|
|
1160
|
-
'A string representation of native functions typical for Firefox and Safari.\n' +
|
|
1161
|
-
'Remarkable traits are the lack of line feed characters at the beginning and at the ' +
|
|
1162
|
-
'end of the string and the presence of a line feed followed by four whitespaces ' +
|
|
1163
|
-
'("\\n ") before the "[native code]" sequence.',
|
|
1164
|
-
includes: ['NO_IE_SRC', 'NO_V8_SRC'],
|
|
1165
|
-
excludes: ['NO_FF_SRC'],
|
|
1139
|
+
var available = ~''.fontcolor('"<>').indexOf('"<>');
|
|
1140
|
+
return available;
|
|
1166
1141
|
},
|
|
1167
|
-
|
|
1142
|
+
includes: ['ESC_HTML_QUOT'],
|
|
1143
|
+
excludes: ['ESC_HTML_QUOT_ONLY'],
|
|
1144
|
+
},
|
|
1145
|
+
ESC_HTML_QUOT:
|
|
1146
|
+
{
|
|
1147
|
+
description:
|
|
1148
|
+
'The property that double quotation marks in the argument of String.prototype.fontcolor ' +
|
|
1149
|
+
'are escaped as """.',
|
|
1150
|
+
check:
|
|
1151
|
+
function ()
|
|
1168
1152
|
{
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
function ()
|
|
1172
|
-
{
|
|
1173
|
-
var available = Array.prototype.fill;
|
|
1174
|
-
return available;
|
|
1175
|
-
},
|
|
1153
|
+
var available = ~''.fontcolor('"').indexOf('"');
|
|
1154
|
+
return available;
|
|
1176
1155
|
},
|
|
1177
|
-
|
|
1156
|
+
},
|
|
1157
|
+
ESC_HTML_QUOT_ONLY:
|
|
1158
|
+
{
|
|
1159
|
+
description:
|
|
1160
|
+
'The property that only double quotation marks and no other characters in the argument ' +
|
|
1161
|
+
'of String.prototype.fontcolor are escaped into HTML entities.',
|
|
1162
|
+
check:
|
|
1163
|
+
function ()
|
|
1178
1164
|
{
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
function ()
|
|
1182
|
-
{
|
|
1183
|
-
var available = Array.prototype.flat;
|
|
1184
|
-
return available;
|
|
1185
|
-
},
|
|
1165
|
+
var available = ~''.fontcolor('"<>').indexOf('"<>');
|
|
1166
|
+
return available;
|
|
1186
1167
|
},
|
|
1187
|
-
|
|
1168
|
+
includes: ['ESC_HTML_QUOT'],
|
|
1169
|
+
excludes: ['ESC_HTML_ALL'],
|
|
1170
|
+
},
|
|
1171
|
+
ESC_REGEXP_LF:
|
|
1172
|
+
{
|
|
1173
|
+
description:
|
|
1174
|
+
'Having regular expressions created with the RegExp constructor use escape sequences ' +
|
|
1175
|
+
'starting with a backslash to format line feed characters ("\\n") in their string ' +
|
|
1176
|
+
'representation.',
|
|
1177
|
+
check:
|
|
1178
|
+
function ()
|
|
1188
1179
|
{
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
function ()
|
|
1192
|
-
{
|
|
1193
|
-
var available = String.fromCodePoint;
|
|
1194
|
-
return available;
|
|
1195
|
-
},
|
|
1180
|
+
var available = (RegExp('\n') + '')[1] === '\\';
|
|
1181
|
+
return available;
|
|
1196
1182
|
},
|
|
1197
|
-
|
|
1183
|
+
},
|
|
1184
|
+
ESC_REGEXP_SLASH:
|
|
1185
|
+
{
|
|
1186
|
+
description:
|
|
1187
|
+
'Having regular expressions created with the RegExp constructor use escape sequences ' +
|
|
1188
|
+
'starting with a backslash to format slashes ("/") in their string representation.',
|
|
1189
|
+
check:
|
|
1190
|
+
function ()
|
|
1198
1191
|
{
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
'index 19 is a line feed ("\\n").',
|
|
1202
|
-
check:
|
|
1203
|
-
function ()
|
|
1204
|
-
{
|
|
1205
|
-
var available = (Function() + '')[19] === '\n';
|
|
1206
|
-
return available;
|
|
1207
|
-
},
|
|
1192
|
+
var available = (RegExp('/') + '')[1] === '\\';
|
|
1193
|
+
return available;
|
|
1208
1194
|
},
|
|
1209
|
-
|
|
1195
|
+
},
|
|
1196
|
+
FF_SRC:
|
|
1197
|
+
{
|
|
1198
|
+
description:
|
|
1199
|
+
'A string representation of native functions typical for Firefox and Safari.\n' +
|
|
1200
|
+
'Remarkable traits are the lack of line feed characters at the beginning and at the end ' +
|
|
1201
|
+
'of the string and the presence of a line feed followed by four whitespaces ("\\n ") ' +
|
|
1202
|
+
'before the "[native code]" sequence.',
|
|
1203
|
+
includes: ['NO_IE_SRC', 'NO_V8_SRC'],
|
|
1204
|
+
excludes: ['NO_FF_SRC'],
|
|
1205
|
+
},
|
|
1206
|
+
FILL:
|
|
1207
|
+
{
|
|
1208
|
+
description: 'Existence of the native function Array.prototype.fill.',
|
|
1209
|
+
check:
|
|
1210
|
+
function ()
|
|
1210
1211
|
{
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
'index 22 is a line feed ("\\n").',
|
|
1214
|
-
check:
|
|
1215
|
-
function ()
|
|
1216
|
-
{
|
|
1217
|
-
var available = (Function() + '')[22] === '\n';
|
|
1218
|
-
return available;
|
|
1219
|
-
},
|
|
1212
|
+
var available = Array.prototype.fill;
|
|
1213
|
+
return available;
|
|
1220
1214
|
},
|
|
1221
|
-
|
|
1215
|
+
},
|
|
1216
|
+
FLAT:
|
|
1217
|
+
{
|
|
1218
|
+
description: 'Existence of the native function Array.prototype.flat.',
|
|
1219
|
+
check:
|
|
1220
|
+
function ()
|
|
1222
1221
|
{
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
function ()
|
|
1226
|
-
{
|
|
1227
|
-
try
|
|
1228
|
-
{
|
|
1229
|
-
Array.prototype.toString.call({ });
|
|
1230
|
-
return true;
|
|
1231
|
-
}
|
|
1232
|
-
catch (error)
|
|
1233
|
-
{ }
|
|
1234
|
-
},
|
|
1222
|
+
var available = Array.prototype.flat;
|
|
1223
|
+
return available;
|
|
1235
1224
|
},
|
|
1236
|
-
|
|
1225
|
+
},
|
|
1226
|
+
FROM_CODE_POINT:
|
|
1227
|
+
{
|
|
1228
|
+
description: 'Existence of the function String.fromCodePoint.',
|
|
1229
|
+
check:
|
|
1230
|
+
function ()
|
|
1237
1231
|
{
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
'invoked without a binding.',
|
|
1241
|
-
check:
|
|
1242
|
-
function ()
|
|
1243
|
-
{
|
|
1244
|
-
var getToString = Function('return toString');
|
|
1245
|
-
var available = getToString()() === '[object Undefined]';
|
|
1246
|
-
return available;
|
|
1247
|
-
},
|
|
1248
|
-
includes: ['OBJECT_UNDEFINED'],
|
|
1249
|
-
},
|
|
1250
|
-
GMT:
|
|
1251
|
-
{
|
|
1252
|
-
description:
|
|
1253
|
-
'Presence of the text "GMT" after the first 25 characters in the string returned by ' +
|
|
1254
|
-
'Date().\n' +
|
|
1255
|
-
'The string representation of dates is implementation dependent, but most engines ' +
|
|
1256
|
-
'use a similar format, making this feature available in all supported engines except ' +
|
|
1257
|
-
'Internet Explorer 9 and 10.',
|
|
1258
|
-
check:
|
|
1259
|
-
function ()
|
|
1260
|
-
{
|
|
1261
|
-
var available = /^.{25}GMT/.test(Date());
|
|
1262
|
-
return available;
|
|
1263
|
-
},
|
|
1232
|
+
var available = String.fromCodePoint;
|
|
1233
|
+
return available;
|
|
1264
1234
|
},
|
|
1265
|
-
|
|
1235
|
+
},
|
|
1236
|
+
FUNCTION_19_LF:
|
|
1237
|
+
{
|
|
1238
|
+
description:
|
|
1239
|
+
'A string representation of dynamically generated functions where the character at index ' +
|
|
1240
|
+
'19 is a line feed ("\\n").',
|
|
1241
|
+
check:
|
|
1242
|
+
function ()
|
|
1266
1243
|
{
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
'History]".',
|
|
1270
|
-
check:
|
|
1271
|
-
function ()
|
|
1272
|
-
{
|
|
1273
|
-
var available = typeof history === 'object' && history + '' === '[object History]';
|
|
1274
|
-
return available;
|
|
1275
|
-
},
|
|
1276
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1244
|
+
var available = (Function() + '')[19] === '\n';
|
|
1245
|
+
return available;
|
|
1277
1246
|
},
|
|
1278
|
-
|
|
1247
|
+
},
|
|
1248
|
+
FUNCTION_22_LF:
|
|
1249
|
+
{
|
|
1250
|
+
description:
|
|
1251
|
+
'A string representation of dynamically generated functions where the character at index ' +
|
|
1252
|
+
'22 is a line feed ("\\n").',
|
|
1253
|
+
check:
|
|
1254
|
+
function ()
|
|
1279
1255
|
{
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
'"function HTMLAudioElement".',
|
|
1283
|
-
check:
|
|
1284
|
-
function ()
|
|
1285
|
-
{
|
|
1286
|
-
var available =
|
|
1287
|
-
typeof Audio !== 'undefined' && /^function HTMLAudioElement/.test(Audio);
|
|
1288
|
-
return available;
|
|
1289
|
-
},
|
|
1290
|
-
includes: ['NO_IE_SRC'],
|
|
1291
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1256
|
+
var available = (Function() + '')[22] === '\n';
|
|
1257
|
+
return available;
|
|
1292
1258
|
},
|
|
1293
|
-
|
|
1259
|
+
},
|
|
1260
|
+
GENERIC_ARRAY_TO_STRING:
|
|
1261
|
+
{
|
|
1262
|
+
description: 'Ability to call Array.prototype.toString with a non-array binding.',
|
|
1263
|
+
check:
|
|
1264
|
+
function ()
|
|
1294
1265
|
{
|
|
1295
|
-
|
|
1296
|
-
'Existence of the global object document having the string representation "[object ' +
|
|
1297
|
-
'HTMLDocument]".',
|
|
1298
|
-
check:
|
|
1299
|
-
function ()
|
|
1300
|
-
{
|
|
1301
|
-
var available =
|
|
1302
|
-
typeof document === 'object' && document + '' === '[object HTMLDocument]';
|
|
1303
|
-
return available;
|
|
1304
|
-
},
|
|
1305
|
-
includes: ['ANY_DOCUMENT'],
|
|
1306
|
-
excludes: ['DOCUMENT'],
|
|
1307
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1308
|
-
},
|
|
1309
|
-
IE_SRC:
|
|
1310
|
-
{
|
|
1311
|
-
description:
|
|
1312
|
-
'A string representation of native functions typical for Internet Explorer.\n' +
|
|
1313
|
-
'Remarkable traits are the presence of a line feed character ("\\n") at the ' +
|
|
1314
|
-
'beginning and at the end of the string and a line feed followed by four whitespaces ' +
|
|
1315
|
-
'("\\n ") before the "[native code]" sequence.',
|
|
1316
|
-
includes: ['NO_FF_SRC', 'NO_V8_SRC'],
|
|
1317
|
-
excludes: ['NO_IE_SRC'],
|
|
1318
|
-
},
|
|
1319
|
-
INCR_CHAR:
|
|
1320
|
-
{
|
|
1321
|
-
description:
|
|
1322
|
-
'The ability to use unary increment operators with string characters, like in ( ' +
|
|
1323
|
-
'++"some string"[0] ): this will result in a TypeError in strict mode in ECMAScript ' +
|
|
1324
|
-
'compliant engines.',
|
|
1325
|
-
check:
|
|
1326
|
-
function ()
|
|
1266
|
+
try
|
|
1327
1267
|
{
|
|
1268
|
+
Array.prototype.toString.call({ });
|
|
1328
1269
|
return true;
|
|
1329
|
-
}
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
INTL:
|
|
1333
|
-
{
|
|
1334
|
-
description: 'Existence of the global object Intl.',
|
|
1335
|
-
check:
|
|
1336
|
-
function ()
|
|
1337
|
-
{
|
|
1338
|
-
var available = typeof Intl === 'object';
|
|
1339
|
-
return available;
|
|
1340
|
-
},
|
|
1341
|
-
},
|
|
1342
|
-
LOCALE_INFINITY:
|
|
1343
|
-
{
|
|
1344
|
-
description: 'Language sensitive string representation of Infinity as "∞".',
|
|
1345
|
-
check:
|
|
1346
|
-
function ()
|
|
1347
|
-
{
|
|
1348
|
-
var available = Infinity.toLocaleString() === '∞';
|
|
1349
|
-
return available;
|
|
1350
|
-
},
|
|
1351
|
-
},
|
|
1352
|
-
LOCALE_NUMERALS:
|
|
1353
|
-
{
|
|
1354
|
-
description:
|
|
1355
|
-
'Features shared by all engines capable of localized number formatting, including ' +
|
|
1356
|
-
'output of Arabic digits, the Arabic decimal separator "٫", the letters in the first ' +
|
|
1357
|
-
'word of the Arabic string representation of NaN ("ليس"), Persian digits and the ' +
|
|
1358
|
-
'Persian digit group separator "٬".',
|
|
1359
|
-
check:
|
|
1360
|
-
function ()
|
|
1361
|
-
{
|
|
1362
|
-
var available =
|
|
1363
|
-
Number.prototype.toLocaleString &&
|
|
1364
|
-
checkLocaleNumeral('ar', NaN, /^ليس/) &&
|
|
1365
|
-
checkLocaleNumeral('ar-td', 234567890.1, /^٢٣٤٬?٥٦٧٬?٨٩٠٫١/) &&
|
|
1366
|
-
checkLocaleNumeral('fa', 1234567890, /^۱٬۲۳۴٬۵۶۷٬۸۹۰/);
|
|
1367
|
-
return available;
|
|
1368
|
-
},
|
|
1369
|
-
},
|
|
1370
|
-
LOCALE_NUMERALS_EXT:
|
|
1371
|
-
{
|
|
1372
|
-
description:
|
|
1373
|
-
'Extended localized number formatting.\n' +
|
|
1374
|
-
'This includes all features of LOCALE_NUMERALS plus the output of the first three ' +
|
|
1375
|
-
'letters in the second word of the Arabic string representation of NaN ("رقم"), ' +
|
|
1376
|
-
'Bengali digits, the letters in the Russian string representation of NaN ("не\xa0' +
|
|
1377
|
-
'число") and the letters in the Persian string representation of NaN ("ناعدد").',
|
|
1378
|
-
check:
|
|
1379
|
-
function ()
|
|
1380
|
-
{
|
|
1381
|
-
var available =
|
|
1382
|
-
Number.prototype.toLocaleString &&
|
|
1383
|
-
checkLocaleNumeral('ar', NaN, /^ليس.رقم/) &&
|
|
1384
|
-
checkLocaleNumeral('ar-td', 234567890.1, /^٢٣٤٬?٥٦٧٬?٨٩٠٫١/) &&
|
|
1385
|
-
checkLocaleNumeral('bn', 1234567890, /^১,২৩,৪৫,৬৭,৮৯০/) &&
|
|
1386
|
-
checkLocaleNumeral('fa', 1234567890, /^۱٬۲۳۴٬۵۶۷٬۸۹۰/) &&
|
|
1387
|
-
checkLocaleNumeral('fa', NaN, /^ناعد/) &&
|
|
1388
|
-
checkLocaleNumeral('ru', NaN, /^не.число/);
|
|
1389
|
-
return available;
|
|
1390
|
-
},
|
|
1391
|
-
includes: ['LOCALE_NUMERALS'],
|
|
1392
|
-
},
|
|
1393
|
-
LOCATION:
|
|
1394
|
-
{
|
|
1395
|
-
description:
|
|
1396
|
-
'Existence of the global object location with the property that ' +
|
|
1397
|
-
'Object.prototype.toString.call(location) evaluates to a string that starts with ' +
|
|
1398
|
-
'"[object " and ends with "Location]".',
|
|
1399
|
-
check:
|
|
1400
|
-
function ()
|
|
1401
|
-
{
|
|
1402
|
-
var available =
|
|
1403
|
-
typeof location === 'object' &&
|
|
1404
|
-
/^\[object .*Location]$/.test(Object.prototype.toString.call(location));
|
|
1405
|
-
return available;
|
|
1406
|
-
},
|
|
1407
|
-
},
|
|
1408
|
-
NAME:
|
|
1409
|
-
{
|
|
1410
|
-
description: 'Existence of the name property for functions.',
|
|
1411
|
-
check:
|
|
1412
|
-
function ()
|
|
1413
|
-
{
|
|
1414
|
-
var available = 'name' in Function();
|
|
1415
|
-
return available;
|
|
1416
|
-
},
|
|
1417
|
-
},
|
|
1418
|
-
NODECONSTRUCTOR:
|
|
1419
|
-
{
|
|
1420
|
-
description:
|
|
1421
|
-
'Existence of the global object Node having the string representation "[object ' +
|
|
1422
|
-
'NodeConstructor]".',
|
|
1423
|
-
check:
|
|
1424
|
-
function ()
|
|
1425
|
-
{
|
|
1426
|
-
var available =
|
|
1427
|
-
typeof Node !== 'undefined' && Node + '' === '[object NodeConstructor]';
|
|
1428
|
-
return available;
|
|
1429
|
-
},
|
|
1430
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1431
|
-
},
|
|
1432
|
-
NO_FF_SRC:
|
|
1433
|
-
{
|
|
1434
|
-
description:
|
|
1435
|
-
'A string representation of native functions typical for V8 or for Internet Explorer ' +
|
|
1436
|
-
'but not for Firefox and Safari.',
|
|
1437
|
-
check:
|
|
1438
|
-
function ()
|
|
1439
|
-
{
|
|
1440
|
-
var available = /^(\n?)function Object\(\) \{\1 +\[native code]\s\}/.test(Object);
|
|
1441
|
-
return available;
|
|
1442
|
-
},
|
|
1443
|
-
excludes: ['FF_SRC'],
|
|
1444
|
-
},
|
|
1445
|
-
NO_IE_SRC:
|
|
1446
|
-
{
|
|
1447
|
-
description:
|
|
1448
|
-
'A string representation of native functions typical for most engines with the ' +
|
|
1449
|
-
'notable exception of Internet Explorer.\n' +
|
|
1450
|
-
'A remarkable trait of this feature is the lack of line feed characters at the ' +
|
|
1451
|
-
'beginning and at the end of the string.',
|
|
1452
|
-
check:
|
|
1453
|
-
function ()
|
|
1454
|
-
{
|
|
1455
|
-
var available = /^function Object\(\) \{(\n )? \[native code]\s\}/.test(Object);
|
|
1456
|
-
return available;
|
|
1457
|
-
},
|
|
1458
|
-
excludes: ['IE_SRC'],
|
|
1459
|
-
},
|
|
1460
|
-
NO_OLD_SAFARI_ARRAY_ITERATOR:
|
|
1461
|
-
{
|
|
1462
|
-
description:
|
|
1463
|
-
'The property that the string representation of Array.prototype.entries() evaluates ' +
|
|
1464
|
-
'to "[object Array Iterator]" and that Array.prototype.entries().constructor is the ' +
|
|
1465
|
-
'global function Object.',
|
|
1466
|
-
check:
|
|
1467
|
-
function ()
|
|
1468
|
-
{
|
|
1469
|
-
if (Array.prototype.entries)
|
|
1470
|
-
{
|
|
1471
|
-
var arrayIterator = [].entries();
|
|
1472
|
-
var available =
|
|
1473
|
-
arrayIterator + '' === '[object Array Iterator]' &&
|
|
1474
|
-
arrayIterator.constructor === Object;
|
|
1475
|
-
return available;
|
|
1476
|
-
}
|
|
1477
|
-
},
|
|
1478
|
-
includes: ['ARRAY_ITERATOR'],
|
|
1479
|
-
},
|
|
1480
|
-
NO_V8_SRC:
|
|
1481
|
-
{
|
|
1482
|
-
description:
|
|
1483
|
-
'A string representation of native functions typical for Firefox, Internet Explorer ' +
|
|
1484
|
-
'and Safari.\n' +
|
|
1485
|
-
'A most remarkable trait of this feature is the presence of a line feed followed by ' +
|
|
1486
|
-
'four whitespaces ("\\n ") before the "[native code]" sequence.',
|
|
1487
|
-
check:
|
|
1488
|
-
function ()
|
|
1489
|
-
{
|
|
1490
|
-
var available = /^\n?function Object\(\) \{\n \[native code]\s\}/.test(Object);
|
|
1491
|
-
return available;
|
|
1492
|
-
},
|
|
1493
|
-
excludes: ['V8_SRC'],
|
|
1494
|
-
},
|
|
1495
|
-
OBJECT_UNDEFINED:
|
|
1496
|
-
{
|
|
1497
|
-
description:
|
|
1498
|
-
'Having the function Object.prototype.toString return the string "[object ' +
|
|
1499
|
-
'Undefined]" when invoked without a binding.',
|
|
1500
|
-
check:
|
|
1501
|
-
function ()
|
|
1502
|
-
{
|
|
1503
|
-
var toString = Object.prototype.toString;
|
|
1504
|
-
var available = toString() === '[object Undefined]';
|
|
1505
|
-
return available;
|
|
1506
|
-
},
|
|
1507
|
-
includes: ['UNDEFINED'],
|
|
1508
|
-
},
|
|
1509
|
-
PLAIN_INTL:
|
|
1510
|
-
{
|
|
1511
|
-
description:
|
|
1512
|
-
'Existence of the global object Intl having the string representation "[object ' +
|
|
1513
|
-
'Object]"',
|
|
1514
|
-
check:
|
|
1515
|
-
function ()
|
|
1516
|
-
{
|
|
1517
|
-
var available = typeof Intl === 'object' && Intl + '' === '[object Object]';
|
|
1518
|
-
return available;
|
|
1519
|
-
},
|
|
1520
|
-
includes: ['INTL'],
|
|
1521
|
-
},
|
|
1522
|
-
REGEXP_STRING_ITERATOR:
|
|
1523
|
-
{
|
|
1524
|
-
description:
|
|
1525
|
-
'The property that the string representation of String.prototype.matchAll() ' +
|
|
1526
|
-
'evaluates to "[object RegExp String Iterator]".',
|
|
1527
|
-
check:
|
|
1528
|
-
function ()
|
|
1529
|
-
{
|
|
1530
|
-
var available =
|
|
1531
|
-
String.prototype.matchAll &&
|
|
1532
|
-
''.matchAll() + '' === '[object RegExp String Iterator]';
|
|
1533
|
-
return available;
|
|
1534
|
-
},
|
|
1535
|
-
},
|
|
1536
|
-
SELF: { aliasFor: 'ANY_WINDOW' },
|
|
1537
|
-
SELF_OBJ:
|
|
1538
|
-
{
|
|
1539
|
-
description:
|
|
1540
|
-
'Existence of the global object self whose string representation starts with ' +
|
|
1541
|
-
'"[object ".',
|
|
1542
|
-
check:
|
|
1543
|
-
checkSelfFeature.bind
|
|
1544
|
-
(
|
|
1545
|
-
function (str)
|
|
1546
|
-
{
|
|
1547
|
-
var available = /^\[object /.test(str);
|
|
1548
|
-
return available;
|
|
1549
|
-
}
|
|
1550
|
-
),
|
|
1551
|
-
attributes: { 'web-worker': 'safari-bug-21820506' },
|
|
1552
|
-
},
|
|
1553
|
-
SHORT_LOCALES:
|
|
1554
|
-
{
|
|
1555
|
-
description:
|
|
1556
|
-
'Support for the two-letter locale name "ar" to format decimal numbers as Arabic ' +
|
|
1557
|
-
'numerals.',
|
|
1558
|
-
check:
|
|
1559
|
-
function ()
|
|
1560
|
-
{
|
|
1561
|
-
var NUMBER = 9876430.125;
|
|
1562
|
-
|
|
1563
|
-
var localizedNumeral = NUMBER.toLocaleString('ar');
|
|
1564
|
-
var available =
|
|
1565
|
-
localizedNumeral === NUMBER.toLocaleString('ar-td') &&
|
|
1566
|
-
localizedNumeral !== NUMBER.toLocaleString('en');
|
|
1567
|
-
return available;
|
|
1568
|
-
},
|
|
1569
|
-
includes: ['LOCALE_NUMERALS'],
|
|
1570
|
-
},
|
|
1571
|
-
STATUS:
|
|
1572
|
-
{
|
|
1573
|
-
description: 'Existence of the global string status.',
|
|
1574
|
-
check:
|
|
1575
|
-
function ()
|
|
1576
|
-
{
|
|
1577
|
-
var available = typeof status === 'string';
|
|
1578
|
-
return available;
|
|
1579
|
-
},
|
|
1580
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1581
|
-
},
|
|
1582
|
-
UNDEFINED:
|
|
1583
|
-
{
|
|
1584
|
-
description:
|
|
1585
|
-
'The property that Object.prototype.toString.call() evaluates to "[object ' +
|
|
1586
|
-
'Undefined]".\n' +
|
|
1587
|
-
'This behavior is specified by ECMAScript, and is enforced by all engines except ' +
|
|
1588
|
-
'Android Browser versions prior to 4.1.2, where this feature is not available.',
|
|
1589
|
-
check:
|
|
1590
|
-
function ()
|
|
1591
|
-
{
|
|
1592
|
-
var available = Object.prototype.toString.call() === '[object Undefined]';
|
|
1593
|
-
return available;
|
|
1594
|
-
},
|
|
1595
|
-
},
|
|
1596
|
-
V8_SRC:
|
|
1597
|
-
{
|
|
1598
|
-
description:
|
|
1599
|
-
'A string representation of native functions typical for the V8 engine.\n' +
|
|
1600
|
-
'Remarkable traits are the lack of line feed characters at the beginning and at the ' +
|
|
1601
|
-
'end of the string and the presence of a single whitespace before the "[native ' +
|
|
1602
|
-
'code]" sequence.',
|
|
1603
|
-
includes: ['NO_FF_SRC', 'NO_IE_SRC'],
|
|
1604
|
-
excludes: ['NO_V8_SRC'],
|
|
1605
|
-
},
|
|
1606
|
-
WINDOW:
|
|
1607
|
-
{
|
|
1608
|
-
description:
|
|
1609
|
-
'Existence of the global object self having the string representation "[object ' +
|
|
1610
|
-
'Window]".',
|
|
1611
|
-
check:
|
|
1612
|
-
checkSelfFeature.bind
|
|
1613
|
-
(
|
|
1614
|
-
function (str)
|
|
1615
|
-
{
|
|
1616
|
-
var available = str === '[object Window]';
|
|
1617
|
-
return available;
|
|
1618
|
-
}
|
|
1619
|
-
),
|
|
1620
|
-
includes: ['ANY_WINDOW'],
|
|
1621
|
-
excludes: ['DOMWINDOW'],
|
|
1622
|
-
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1623
|
-
},
|
|
1624
|
-
|
|
1625
|
-
DEFAULT:
|
|
1626
|
-
{
|
|
1627
|
-
description:
|
|
1628
|
-
'Minimum feature level, compatible with all supported engines in all environments.',
|
|
1629
|
-
},
|
|
1630
|
-
BROWSER:
|
|
1631
|
-
{
|
|
1632
|
-
description:
|
|
1633
|
-
'Features available in all browsers.\n' +
|
|
1634
|
-
'No support for Node.js.',
|
|
1635
|
-
includes: ['ANY_DOCUMENT', 'ANY_WINDOW', 'HISTORY', 'INCR_CHAR', 'STATUS'],
|
|
1636
|
-
attributes:
|
|
1637
|
-
{
|
|
1638
|
-
'char-increment-restriction': null,
|
|
1639
|
-
'safari-bug-21820506': null,
|
|
1640
|
-
'web-worker-restriction': null,
|
|
1641
|
-
},
|
|
1642
|
-
},
|
|
1643
|
-
COMPACT:
|
|
1644
|
-
{
|
|
1645
|
-
description:
|
|
1646
|
-
'All new browsers\' features.\n' +
|
|
1647
|
-
'No support for Node.js and older browsers like Internet Explorer, Safari 9 or ' +
|
|
1648
|
-
'Android Browser.',
|
|
1649
|
-
includes:
|
|
1650
|
-
[
|
|
1651
|
-
'ARROW',
|
|
1652
|
-
'ATOB',
|
|
1653
|
-
'BARPROP',
|
|
1654
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1655
|
-
'ESC_REGEXP_LF',
|
|
1656
|
-
'ESC_REGEXP_SLASH',
|
|
1657
|
-
'FILL',
|
|
1658
|
-
'FLAT',
|
|
1659
|
-
'FROM_CODE_POINT',
|
|
1660
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1661
|
-
'GLOBAL_UNDEFINED',
|
|
1662
|
-
'GMT',
|
|
1663
|
-
'HISTORY',
|
|
1664
|
-
'HTMLDOCUMENT',
|
|
1665
|
-
'INCR_CHAR',
|
|
1666
|
-
'INTL',
|
|
1667
|
-
'LOCALE_INFINITY',
|
|
1668
|
-
'LOCALE_NUMERALS_EXT',
|
|
1669
|
-
'LOCATION',
|
|
1670
|
-
'NAME',
|
|
1671
|
-
'NO_IE_SRC',
|
|
1672
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1673
|
-
'REGEXP_STRING_ITERATOR',
|
|
1674
|
-
'STATUS',
|
|
1675
|
-
'WINDOW',
|
|
1676
|
-
],
|
|
1677
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1678
|
-
},
|
|
1679
|
-
ANDRO_4_0:
|
|
1680
|
-
{
|
|
1681
|
-
engine: 'Android Browser 4.0',
|
|
1682
|
-
includes:
|
|
1683
|
-
[
|
|
1684
|
-
'ATOB',
|
|
1685
|
-
'CONSOLE',
|
|
1686
|
-
'DOMWINDOW',
|
|
1687
|
-
'ESC_HTML_ALL',
|
|
1688
|
-
'FUNCTION_22_LF',
|
|
1689
|
-
'GMT',
|
|
1690
|
-
'HISTORY',
|
|
1691
|
-
'HTMLDOCUMENT',
|
|
1692
|
-
'INCR_CHAR',
|
|
1693
|
-
'LOCATION',
|
|
1694
|
-
'NAME',
|
|
1695
|
-
'STATUS',
|
|
1696
|
-
'V8_SRC',
|
|
1697
|
-
],
|
|
1698
|
-
},
|
|
1699
|
-
ANDRO_4_1:
|
|
1700
|
-
{
|
|
1701
|
-
engine: 'Android Browser 4.1 to 4.3',
|
|
1702
|
-
includes:
|
|
1703
|
-
[
|
|
1704
|
-
'ATOB',
|
|
1705
|
-
'CONSOLE',
|
|
1706
|
-
'DOMWINDOW',
|
|
1707
|
-
'ESC_HTML_ALL',
|
|
1708
|
-
'FUNCTION_22_LF',
|
|
1709
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1710
|
-
'GMT',
|
|
1711
|
-
'HISTORY',
|
|
1712
|
-
'HTMLDOCUMENT',
|
|
1713
|
-
'INCR_CHAR',
|
|
1714
|
-
'LOCATION',
|
|
1715
|
-
'NAME',
|
|
1716
|
-
'OBJECT_UNDEFINED',
|
|
1717
|
-
'STATUS',
|
|
1718
|
-
'V8_SRC',
|
|
1719
|
-
],
|
|
1270
|
+
}
|
|
1271
|
+
catch (error)
|
|
1272
|
+
{ }
|
|
1720
1273
|
},
|
|
1721
|
-
|
|
1274
|
+
},
|
|
1275
|
+
GLOBAL_UNDEFINED:
|
|
1276
|
+
{
|
|
1277
|
+
description:
|
|
1278
|
+
'Having the global function toString return the string "[object Undefined]" when invoked ' +
|
|
1279
|
+
'without a binding.',
|
|
1280
|
+
check:
|
|
1281
|
+
function ()
|
|
1722
1282
|
{
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
'ATOB',
|
|
1727
|
-
'BARPROP',
|
|
1728
|
-
'CONSOLE',
|
|
1729
|
-
'ESC_HTML_ALL',
|
|
1730
|
-
'FUNCTION_22_LF',
|
|
1731
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1732
|
-
'GMT',
|
|
1733
|
-
'HISTORY',
|
|
1734
|
-
'HTMLAUDIOELEMENT',
|
|
1735
|
-
'HTMLDOCUMENT',
|
|
1736
|
-
'INCR_CHAR',
|
|
1737
|
-
'LOCALE_INFINITY',
|
|
1738
|
-
'LOCALE_NUMERALS_EXT',
|
|
1739
|
-
'LOCATION',
|
|
1740
|
-
'NAME',
|
|
1741
|
-
'OBJECT_UNDEFINED',
|
|
1742
|
-
'PLAIN_INTL',
|
|
1743
|
-
'SHORT_LOCALES',
|
|
1744
|
-
'STATUS',
|
|
1745
|
-
'V8_SRC',
|
|
1746
|
-
'WINDOW',
|
|
1747
|
-
],
|
|
1748
|
-
attributes: { 'no-console-in-web-worker': null, 'web-worker-restriction': null },
|
|
1283
|
+
var getToString = Function('return toString');
|
|
1284
|
+
var available = getToString()() === '[object Undefined]';
|
|
1285
|
+
return available;
|
|
1749
1286
|
},
|
|
1750
|
-
|
|
1287
|
+
includes: ['OBJECT_UNDEFINED'],
|
|
1288
|
+
},
|
|
1289
|
+
GMT:
|
|
1290
|
+
{
|
|
1291
|
+
description:
|
|
1292
|
+
'Presence of the text "GMT" after the first 25 characters in the string returned by ' +
|
|
1293
|
+
'Date().\n' +
|
|
1294
|
+
'The string representation of dates is implementation dependent, but most engines use a ' +
|
|
1295
|
+
'similar format, making this feature available in all supported engines except Internet ' +
|
|
1296
|
+
'Explorer 9 and 10.',
|
|
1297
|
+
check:
|
|
1298
|
+
function ()
|
|
1751
1299
|
{
|
|
1752
|
-
|
|
1753
|
-
|
|
1300
|
+
var available = /^.{25}GMT/.test(Date());
|
|
1301
|
+
return available;
|
|
1754
1302
|
},
|
|
1755
|
-
|
|
1303
|
+
},
|
|
1304
|
+
HISTORY:
|
|
1305
|
+
{
|
|
1306
|
+
description:
|
|
1307
|
+
'Existence of the global object history having the string representation "[object ' +
|
|
1308
|
+
'History]".',
|
|
1309
|
+
check:
|
|
1310
|
+
function ()
|
|
1756
1311
|
{
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
[
|
|
1760
|
-
'ARROW',
|
|
1761
|
-
'ATOB',
|
|
1762
|
-
'BARPROP',
|
|
1763
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1764
|
-
'ESC_REGEXP_LF',
|
|
1765
|
-
'ESC_REGEXP_SLASH',
|
|
1766
|
-
'FILL',
|
|
1767
|
-
'FLAT',
|
|
1768
|
-
'FROM_CODE_POINT',
|
|
1769
|
-
'FUNCTION_19_LF',
|
|
1770
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1771
|
-
'GLOBAL_UNDEFINED',
|
|
1772
|
-
'GMT',
|
|
1773
|
-
'HISTORY',
|
|
1774
|
-
'HTMLDOCUMENT',
|
|
1775
|
-
'INCR_CHAR',
|
|
1776
|
-
'INTL',
|
|
1777
|
-
'LOCALE_INFINITY',
|
|
1778
|
-
'LOCALE_NUMERALS_EXT',
|
|
1779
|
-
'LOCATION',
|
|
1780
|
-
'NAME',
|
|
1781
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1782
|
-
'REGEXP_STRING_ITERATOR',
|
|
1783
|
-
'STATUS',
|
|
1784
|
-
'V8_SRC',
|
|
1785
|
-
'WINDOW',
|
|
1786
|
-
],
|
|
1787
|
-
attributes:
|
|
1788
|
-
{
|
|
1789
|
-
'char-increment-restriction': null,
|
|
1790
|
-
'unstable': null,
|
|
1791
|
-
'web-worker-restriction': null,
|
|
1792
|
-
},
|
|
1312
|
+
var available = typeof history === 'object' && history + '' === '[object History]';
|
|
1313
|
+
return available;
|
|
1793
1314
|
},
|
|
1794
|
-
|
|
1315
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1316
|
+
},
|
|
1317
|
+
HTMLAUDIOELEMENT:
|
|
1318
|
+
{
|
|
1319
|
+
description:
|
|
1320
|
+
'Existence of the global object Audio whose string representation starts with ' +
|
|
1321
|
+
'"function HTMLAudioElement".',
|
|
1322
|
+
check:
|
|
1323
|
+
function ()
|
|
1795
1324
|
{
|
|
1796
|
-
|
|
1797
|
-
|
|
1325
|
+
var available =
|
|
1326
|
+
typeof Audio !== 'undefined' && /^function HTMLAudioElement/.test(Audio);
|
|
1327
|
+
return available;
|
|
1798
1328
|
},
|
|
1799
|
-
|
|
1329
|
+
includes: ['NO_IE_SRC'],
|
|
1330
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1331
|
+
},
|
|
1332
|
+
HTMLDOCUMENT:
|
|
1333
|
+
{
|
|
1334
|
+
description:
|
|
1335
|
+
'Existence of the global object document having the string representation "[object ' +
|
|
1336
|
+
'HTMLDocument]".',
|
|
1337
|
+
check:
|
|
1338
|
+
function ()
|
|
1800
1339
|
{
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
'ARROW',
|
|
1805
|
-
'AT',
|
|
1806
|
-
'ATOB',
|
|
1807
|
-
'BARPROP',
|
|
1808
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1809
|
-
'ESC_REGEXP_LF',
|
|
1810
|
-
'ESC_REGEXP_SLASH',
|
|
1811
|
-
'FILL',
|
|
1812
|
-
'FLAT',
|
|
1813
|
-
'FROM_CODE_POINT',
|
|
1814
|
-
'FUNCTION_19_LF',
|
|
1815
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1816
|
-
'GLOBAL_UNDEFINED',
|
|
1817
|
-
'GMT',
|
|
1818
|
-
'HISTORY',
|
|
1819
|
-
'HTMLDOCUMENT',
|
|
1820
|
-
'INCR_CHAR',
|
|
1821
|
-
'INTL',
|
|
1822
|
-
'LOCALE_INFINITY',
|
|
1823
|
-
'LOCALE_NUMERALS_EXT',
|
|
1824
|
-
'LOCATION',
|
|
1825
|
-
'NAME',
|
|
1826
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1827
|
-
'REGEXP_STRING_ITERATOR',
|
|
1828
|
-
'STATUS',
|
|
1829
|
-
'V8_SRC',
|
|
1830
|
-
'WINDOW',
|
|
1831
|
-
],
|
|
1832
|
-
attributes:
|
|
1833
|
-
{
|
|
1834
|
-
'char-increment-restriction': null,
|
|
1835
|
-
'unstable': null,
|
|
1836
|
-
'web-worker-restriction': null,
|
|
1837
|
-
},
|
|
1340
|
+
var available =
|
|
1341
|
+
typeof document === 'object' && document + '' === '[object HTMLDocument]';
|
|
1342
|
+
return available;
|
|
1838
1343
|
},
|
|
1839
|
-
|
|
1344
|
+
includes: ['ANY_DOCUMENT'],
|
|
1345
|
+
excludes: ['DOCUMENT'],
|
|
1346
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1347
|
+
},
|
|
1348
|
+
IE_SRC:
|
|
1349
|
+
{
|
|
1350
|
+
description:
|
|
1351
|
+
'A string representation of native functions typical for Internet Explorer.\n' +
|
|
1352
|
+
'Remarkable traits are the presence of a line feed character ("\\n") at the beginning ' +
|
|
1353
|
+
'and at the end of the string and a line feed followed by four whitespaces ("\\n ") ' +
|
|
1354
|
+
'before the "[native code]" sequence.',
|
|
1355
|
+
includes: ['NO_FF_SRC', 'NO_V8_SRC'],
|
|
1356
|
+
excludes: ['NO_IE_SRC'],
|
|
1357
|
+
},
|
|
1358
|
+
INCR_CHAR:
|
|
1359
|
+
{
|
|
1360
|
+
description:
|
|
1361
|
+
'The ability to use unary increment operators with string characters, like in ( ++"some ' +
|
|
1362
|
+
'string"[0] ): this will result in a TypeError in strict mode in ECMAScript compliant ' +
|
|
1363
|
+
'engines.',
|
|
1364
|
+
check:
|
|
1365
|
+
function ()
|
|
1840
1366
|
{
|
|
1841
|
-
|
|
1842
|
-
aliasFor: 'FF_78',
|
|
1367
|
+
return true;
|
|
1843
1368
|
},
|
|
1844
|
-
|
|
1369
|
+
attributes: { 'forced-strict-mode': 'char-increment-restriction' },
|
|
1370
|
+
},
|
|
1371
|
+
INTL:
|
|
1372
|
+
{
|
|
1373
|
+
description: 'Existence of the global object Intl.',
|
|
1374
|
+
check:
|
|
1375
|
+
function ()
|
|
1845
1376
|
{
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
[
|
|
1849
|
-
'ARROW',
|
|
1850
|
-
'ATOB',
|
|
1851
|
-
'BARPROP',
|
|
1852
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1853
|
-
'ESC_REGEXP_LF',
|
|
1854
|
-
'ESC_REGEXP_SLASH',
|
|
1855
|
-
'FF_SRC',
|
|
1856
|
-
'FILL',
|
|
1857
|
-
'FLAT',
|
|
1858
|
-
'FROM_CODE_POINT',
|
|
1859
|
-
'FUNCTION_19_LF',
|
|
1860
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1861
|
-
'GLOBAL_UNDEFINED',
|
|
1862
|
-
'GMT',
|
|
1863
|
-
'HISTORY',
|
|
1864
|
-
'HTMLDOCUMENT',
|
|
1865
|
-
'INCR_CHAR',
|
|
1866
|
-
'LOCALE_INFINITY',
|
|
1867
|
-
'LOCALE_NUMERALS_EXT',
|
|
1868
|
-
'LOCATION',
|
|
1869
|
-
'NAME',
|
|
1870
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1871
|
-
'PLAIN_INTL',
|
|
1872
|
-
'REGEXP_STRING_ITERATOR',
|
|
1873
|
-
'SHORT_LOCALES',
|
|
1874
|
-
'STATUS',
|
|
1875
|
-
'WINDOW',
|
|
1876
|
-
],
|
|
1877
|
-
attributes:
|
|
1878
|
-
{
|
|
1879
|
-
'char-increment-restriction': null,
|
|
1880
|
-
'unstable': null,
|
|
1881
|
-
'web-worker-restriction': null,
|
|
1882
|
-
},
|
|
1377
|
+
var available = typeof Intl === 'object';
|
|
1378
|
+
return available;
|
|
1883
1379
|
},
|
|
1884
|
-
|
|
1380
|
+
},
|
|
1381
|
+
LOCALE_INFINITY:
|
|
1382
|
+
{
|
|
1383
|
+
description: 'Language sensitive string representation of Infinity as "∞".',
|
|
1384
|
+
check:
|
|
1385
|
+
function ()
|
|
1885
1386
|
{
|
|
1886
|
-
|
|
1887
|
-
|
|
1387
|
+
var available = Infinity.toLocaleString() === '∞';
|
|
1388
|
+
return available;
|
|
1888
1389
|
},
|
|
1889
|
-
|
|
1390
|
+
},
|
|
1391
|
+
LOCALE_NUMERALS:
|
|
1392
|
+
{
|
|
1393
|
+
description:
|
|
1394
|
+
'Features shared by all engines capable of localized number formatting, including output ' +
|
|
1395
|
+
'of Arabic digits, the Arabic decimal separator "٫", the letters in the first word of ' +
|
|
1396
|
+
'the Arabic string representation of NaN ("ليس"), Persian digits and the Persian digit ' +
|
|
1397
|
+
'group separator "٬".',
|
|
1398
|
+
check:
|
|
1399
|
+
function ()
|
|
1890
1400
|
{
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1898
|
-
'ESC_REGEXP_LF',
|
|
1899
|
-
'ESC_REGEXP_SLASH',
|
|
1900
|
-
'FF_SRC',
|
|
1901
|
-
'FILL',
|
|
1902
|
-
'FLAT',
|
|
1903
|
-
'FROM_CODE_POINT',
|
|
1904
|
-
'FUNCTION_19_LF',
|
|
1905
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1906
|
-
'GLOBAL_UNDEFINED',
|
|
1907
|
-
'GMT',
|
|
1908
|
-
'HISTORY',
|
|
1909
|
-
'HTMLDOCUMENT',
|
|
1910
|
-
'INCR_CHAR',
|
|
1911
|
-
'INTL',
|
|
1912
|
-
'LOCALE_INFINITY',
|
|
1913
|
-
'LOCALE_NUMERALS_EXT',
|
|
1914
|
-
'LOCATION',
|
|
1915
|
-
'NAME',
|
|
1916
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1917
|
-
'REGEXP_STRING_ITERATOR',
|
|
1918
|
-
'SHORT_LOCALES',
|
|
1919
|
-
'STATUS',
|
|
1920
|
-
'WINDOW',
|
|
1921
|
-
],
|
|
1922
|
-
attributes:
|
|
1923
|
-
{
|
|
1924
|
-
'char-increment-restriction': null,
|
|
1925
|
-
'unstable': null,
|
|
1926
|
-
'web-worker-restriction': null,
|
|
1927
|
-
},
|
|
1401
|
+
var available =
|
|
1402
|
+
Number.prototype.toLocaleString &&
|
|
1403
|
+
checkLocaleNumeral('ar', NaN, /^ليس/) &&
|
|
1404
|
+
checkLocaleNumeral('ar-td', 234567890.1, /^٢٣٤٬?٥٦٧٬?٨٩٠٫١/) &&
|
|
1405
|
+
checkLocaleNumeral('fa', 1234567890, /^۱٬۲۳۴٬۵۶۷٬۸۹۰/);
|
|
1406
|
+
return available;
|
|
1928
1407
|
},
|
|
1929
|
-
|
|
1408
|
+
},
|
|
1409
|
+
LOCALE_NUMERALS_EXT:
|
|
1410
|
+
{
|
|
1411
|
+
description:
|
|
1412
|
+
'Extended localized number formatting.\n' +
|
|
1413
|
+
'This includes all features of LOCALE_NUMERALS plus the output of the first three ' +
|
|
1414
|
+
'letters in the second word of the Arabic string representation of NaN ("رقم"), Bengali ' +
|
|
1415
|
+
'digits, the letters in the Russian string representation of NaN ("не\xa0число") and the ' +
|
|
1416
|
+
'letters in the Persian string representation of NaN ("ناعدد").',
|
|
1417
|
+
check:
|
|
1418
|
+
function ()
|
|
1930
1419
|
{
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1420
|
+
var available =
|
|
1421
|
+
Number.prototype.toLocaleString &&
|
|
1422
|
+
checkLocaleNumeral('ar', NaN, /^ليس.رقم/) &&
|
|
1423
|
+
checkLocaleNumeral('ar-td', 234567890.1, /^٢٣٤٬?٥٦٧٬?٨٩٠٫١/) &&
|
|
1424
|
+
checkLocaleNumeral('bn', 1234567890, /^১,২৩,৪৫,৬৭,৮৯০/) &&
|
|
1425
|
+
checkLocaleNumeral('fa', 1234567890, /^۱٬۲۳۴٬۵۶۷٬۸۹۰/) &&
|
|
1426
|
+
checkLocaleNumeral('fa', NaN, /^ناعد/) &&
|
|
1427
|
+
checkLocaleNumeral('ru', NaN, /^не.число/);
|
|
1428
|
+
return available;
|
|
1429
|
+
},
|
|
1430
|
+
includes: ['LOCALE_NUMERALS'],
|
|
1431
|
+
},
|
|
1432
|
+
LOCATION:
|
|
1433
|
+
{
|
|
1434
|
+
description:
|
|
1435
|
+
'Existence of the global object location with the property that ' +
|
|
1436
|
+
'Object.prototype.toString.call(location) evaluates to a string that starts with ' +
|
|
1437
|
+
'"[object " and ends with "Location]".',
|
|
1438
|
+
check:
|
|
1439
|
+
function ()
|
|
1935
1440
|
{
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
[
|
|
1939
|
-
|
|
1940
|
-
'AT',
|
|
1941
|
-
'ATOB',
|
|
1942
|
-
'BARPROP',
|
|
1943
|
-
'ESC_HTML_QUOT_ONLY',
|
|
1944
|
-
'ESC_REGEXP_LF',
|
|
1945
|
-
'ESC_REGEXP_SLASH',
|
|
1946
|
-
'FF_SRC',
|
|
1947
|
-
'FILL',
|
|
1948
|
-
'FLAT',
|
|
1949
|
-
'FROM_CODE_POINT',
|
|
1950
|
-
'FUNCTION_19_LF',
|
|
1951
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1952
|
-
'GLOBAL_UNDEFINED',
|
|
1953
|
-
'GMT',
|
|
1954
|
-
'HISTORY',
|
|
1955
|
-
'HTMLDOCUMENT',
|
|
1956
|
-
'INCR_CHAR',
|
|
1957
|
-
'INTL',
|
|
1958
|
-
'LOCALE_INFINITY',
|
|
1959
|
-
'LOCALE_NUMERALS_EXT',
|
|
1960
|
-
'LOCATION',
|
|
1961
|
-
'NAME',
|
|
1962
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1963
|
-
'REGEXP_STRING_ITERATOR',
|
|
1964
|
-
'SHORT_LOCALES',
|
|
1965
|
-
'STATUS',
|
|
1966
|
-
'WINDOW',
|
|
1967
|
-
],
|
|
1968
|
-
attributes:
|
|
1969
|
-
{
|
|
1970
|
-
'char-increment-restriction': null,
|
|
1971
|
-
'unstable': null,
|
|
1972
|
-
'web-worker-restriction': null,
|
|
1973
|
-
},
|
|
1441
|
+
var available =
|
|
1442
|
+
typeof location === 'object' &&
|
|
1443
|
+
/^\[object [\S\s]*Location]$/.test(Object.prototype.toString.call(location));
|
|
1444
|
+
return available;
|
|
1974
1445
|
},
|
|
1975
|
-
|
|
1446
|
+
},
|
|
1447
|
+
NAME:
|
|
1448
|
+
{
|
|
1449
|
+
description: 'Existence of the name property for functions.',
|
|
1450
|
+
check:
|
|
1451
|
+
function ()
|
|
1976
1452
|
{
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
[
|
|
1980
|
-
'CAPITAL_HTML',
|
|
1981
|
-
'DOCUMENT',
|
|
1982
|
-
'ESC_REGEXP_LF',
|
|
1983
|
-
'ESC_REGEXP_SLASH',
|
|
1984
|
-
'FUNCTION_22_LF',
|
|
1985
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
1986
|
-
'HISTORY',
|
|
1987
|
-
'IE_SRC',
|
|
1988
|
-
'INCR_CHAR',
|
|
1989
|
-
'STATUS',
|
|
1990
|
-
'UNDEFINED',
|
|
1991
|
-
'WINDOW',
|
|
1992
|
-
],
|
|
1453
|
+
var available = 'name' in Function();
|
|
1454
|
+
return available;
|
|
1993
1455
|
},
|
|
1994
|
-
|
|
1456
|
+
},
|
|
1457
|
+
NODECONSTRUCTOR:
|
|
1458
|
+
{
|
|
1459
|
+
description:
|
|
1460
|
+
'Existence of the global object Node having the string representation "[object ' +
|
|
1461
|
+
'NodeConstructor]".',
|
|
1462
|
+
check:
|
|
1463
|
+
function ()
|
|
1995
1464
|
{
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
[
|
|
1999
|
-
'ATOB',
|
|
2000
|
-
'CAPITAL_HTML',
|
|
2001
|
-
'CONSOLE',
|
|
2002
|
-
'DOCUMENT',
|
|
2003
|
-
'ESC_REGEXP_LF',
|
|
2004
|
-
'ESC_REGEXP_SLASH',
|
|
2005
|
-
'FUNCTION_22_LF',
|
|
2006
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2007
|
-
'HISTORY',
|
|
2008
|
-
'IE_SRC',
|
|
2009
|
-
'INCR_CHAR',
|
|
2010
|
-
'OBJECT_UNDEFINED',
|
|
2011
|
-
'STATUS',
|
|
2012
|
-
'WINDOW',
|
|
2013
|
-
],
|
|
2014
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1465
|
+
var available = typeof Node !== 'undefined' && Node + '' === '[object NodeConstructor]';
|
|
1466
|
+
return available;
|
|
2015
1467
|
},
|
|
2016
|
-
|
|
1468
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1469
|
+
},
|
|
1470
|
+
NO_FF_SRC:
|
|
1471
|
+
{
|
|
1472
|
+
description:
|
|
1473
|
+
'A string representation of native functions typical for V8 or for Internet Explorer but ' +
|
|
1474
|
+
'not for Firefox and Safari.',
|
|
1475
|
+
check:
|
|
1476
|
+
function ()
|
|
2017
1477
|
{
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
[
|
|
2021
|
-
'ATOB',
|
|
2022
|
-
'CAPITAL_HTML',
|
|
2023
|
-
'CONSOLE',
|
|
2024
|
-
'ESC_REGEXP_LF',
|
|
2025
|
-
'ESC_REGEXP_SLASH',
|
|
2026
|
-
'FUNCTION_22_LF',
|
|
2027
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2028
|
-
'GMT',
|
|
2029
|
-
'HISTORY',
|
|
2030
|
-
'HTMLDOCUMENT',
|
|
2031
|
-
'IE_SRC',
|
|
2032
|
-
'INCR_CHAR',
|
|
2033
|
-
'LOCALE_NUMERALS',
|
|
2034
|
-
'OBJECT_UNDEFINED',
|
|
2035
|
-
'PLAIN_INTL',
|
|
2036
|
-
'SHORT_LOCALES',
|
|
2037
|
-
'STATUS',
|
|
2038
|
-
'WINDOW',
|
|
2039
|
-
],
|
|
2040
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1478
|
+
var available = /^(\n?)function Object\(\) \{\1 +\[native code]\s\}/.test(Object);
|
|
1479
|
+
return available;
|
|
2041
1480
|
},
|
|
2042
|
-
|
|
1481
|
+
excludes: ['FF_SRC'],
|
|
1482
|
+
},
|
|
1483
|
+
NO_IE_SRC:
|
|
1484
|
+
{
|
|
1485
|
+
description:
|
|
1486
|
+
'A string representation of native functions typical for most engines with the notable ' +
|
|
1487
|
+
'exception of Internet Explorer.\n' +
|
|
1488
|
+
'A remarkable trait of this feature is the lack of line feed characters at the beginning ' +
|
|
1489
|
+
'and at the end of the string.',
|
|
1490
|
+
check:
|
|
1491
|
+
function ()
|
|
2043
1492
|
{
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
[
|
|
2047
|
-
'ATOB',
|
|
2048
|
-
'CAPITAL_HTML',
|
|
2049
|
-
'CONSOLE',
|
|
2050
|
-
'ESC_REGEXP_LF',
|
|
2051
|
-
'ESC_REGEXP_SLASH',
|
|
2052
|
-
'FUNCTION_22_LF',
|
|
2053
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2054
|
-
'GMT',
|
|
2055
|
-
'HISTORY',
|
|
2056
|
-
'HTMLDOCUMENT',
|
|
2057
|
-
'IE_SRC',
|
|
2058
|
-
'INCR_CHAR',
|
|
2059
|
-
'LOCALE_INFINITY',
|
|
2060
|
-
'LOCALE_NUMERALS_EXT',
|
|
2061
|
-
'OBJECT_UNDEFINED',
|
|
2062
|
-
'PLAIN_INTL',
|
|
2063
|
-
'SHORT_LOCALES',
|
|
2064
|
-
'STATUS',
|
|
2065
|
-
'WINDOW',
|
|
2066
|
-
],
|
|
2067
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1493
|
+
var available = /^function Object\(\) \{(\n )? \[native code]\s\}/.test(Object);
|
|
1494
|
+
return available;
|
|
2068
1495
|
},
|
|
2069
|
-
|
|
1496
|
+
excludes: ['IE_SRC'],
|
|
1497
|
+
},
|
|
1498
|
+
NO_OLD_SAFARI_ARRAY_ITERATOR:
|
|
1499
|
+
{
|
|
1500
|
+
description:
|
|
1501
|
+
'The property that the string representation of Array.prototype.entries() evaluates to ' +
|
|
1502
|
+
'"[object Array Iterator]" and that Array.prototype.entries().constructor is the global ' +
|
|
1503
|
+
'function Object.',
|
|
1504
|
+
check:
|
|
1505
|
+
function ()
|
|
2070
1506
|
{
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
'
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
'INCR_CHAR',
|
|
2080
|
-
'NAME',
|
|
2081
|
-
'V8_SRC',
|
|
2082
|
-
],
|
|
1507
|
+
if (Array.prototype.entries)
|
|
1508
|
+
{
|
|
1509
|
+
var arrayIterator = [].entries();
|
|
1510
|
+
var available =
|
|
1511
|
+
arrayIterator + '' === '[object Array Iterator]' &&
|
|
1512
|
+
arrayIterator.constructor === Object;
|
|
1513
|
+
return available;
|
|
1514
|
+
}
|
|
2083
1515
|
},
|
|
2084
|
-
|
|
1516
|
+
includes: ['ARRAY_ITERATOR'],
|
|
1517
|
+
},
|
|
1518
|
+
NO_V8_SRC:
|
|
1519
|
+
{
|
|
1520
|
+
description:
|
|
1521
|
+
'A string representation of native functions typical for Firefox, Internet Explorer and ' +
|
|
1522
|
+
'Safari.\n' +
|
|
1523
|
+
'A most remarkable trait of this feature is the presence of a line feed followed by four ' +
|
|
1524
|
+
'whitespaces ("\\n ") before the "[native code]" sequence.',
|
|
1525
|
+
check:
|
|
1526
|
+
function ()
|
|
2085
1527
|
{
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
[
|
|
2089
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2090
|
-
'FUNCTION_22_LF',
|
|
2091
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2092
|
-
'GLOBAL_UNDEFINED',
|
|
2093
|
-
'GMT',
|
|
2094
|
-
'INCR_CHAR',
|
|
2095
|
-
'LOCALE_INFINITY',
|
|
2096
|
-
'NAME',
|
|
2097
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2098
|
-
'PLAIN_INTL',
|
|
2099
|
-
'V8_SRC',
|
|
2100
|
-
],
|
|
1528
|
+
var available = /^\n?function Object\(\) \{\n \[native code]\s\}/.test(Object);
|
|
1529
|
+
return available;
|
|
2101
1530
|
},
|
|
2102
|
-
|
|
1531
|
+
excludes: ['V8_SRC'],
|
|
1532
|
+
},
|
|
1533
|
+
OBJECT_L_LOCATION_CTOR:
|
|
1534
|
+
{
|
|
1535
|
+
description:
|
|
1536
|
+
'Existence of the global function location.constructor whose string representation ' +
|
|
1537
|
+
'starts with "[object L"',
|
|
1538
|
+
check:
|
|
1539
|
+
function ()
|
|
2103
1540
|
{
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
'ARROW',
|
|
2108
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2109
|
-
'ESC_REGEXP_SLASH',
|
|
2110
|
-
'FILL',
|
|
2111
|
-
'FROM_CODE_POINT',
|
|
2112
|
-
'FUNCTION_22_LF',
|
|
2113
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2114
|
-
'GLOBAL_UNDEFINED',
|
|
2115
|
-
'GMT',
|
|
2116
|
-
'INCR_CHAR',
|
|
2117
|
-
'LOCALE_INFINITY',
|
|
2118
|
-
'NAME',
|
|
2119
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2120
|
-
'PLAIN_INTL',
|
|
2121
|
-
'V8_SRC',
|
|
2122
|
-
],
|
|
1541
|
+
var available =
|
|
1542
|
+
typeof location === 'object' && /^\[object L/.test(location.constructor);
|
|
1543
|
+
return available;
|
|
2123
1544
|
},
|
|
2124
|
-
|
|
1545
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1546
|
+
},
|
|
1547
|
+
OBJECT_UNDEFINED:
|
|
1548
|
+
{
|
|
1549
|
+
description:
|
|
1550
|
+
'Having the function Object.prototype.toString return the string "[object Undefined]" ' +
|
|
1551
|
+
'when invoked without a binding.',
|
|
1552
|
+
check:
|
|
1553
|
+
function ()
|
|
2125
1554
|
{
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
'ARROW',
|
|
2130
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2131
|
-
'ESC_REGEXP_SLASH',
|
|
2132
|
-
'FILL',
|
|
2133
|
-
'FROM_CODE_POINT',
|
|
2134
|
-
'FUNCTION_22_LF',
|
|
2135
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2136
|
-
'GLOBAL_UNDEFINED',
|
|
2137
|
-
'GMT',
|
|
2138
|
-
'INCR_CHAR',
|
|
2139
|
-
'LOCALE_INFINITY',
|
|
2140
|
-
'NAME',
|
|
2141
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2142
|
-
'PLAIN_INTL',
|
|
2143
|
-
'V8_SRC',
|
|
2144
|
-
],
|
|
2145
|
-
attributes: { 'char-increment-restriction': null },
|
|
1555
|
+
var toString = Object.prototype.toString;
|
|
1556
|
+
var available = toString() === '[object Undefined]';
|
|
1557
|
+
return available;
|
|
2146
1558
|
},
|
|
2147
|
-
|
|
1559
|
+
includes: ['UNDEFINED'],
|
|
1560
|
+
},
|
|
1561
|
+
OBJECT_W_CTOR:
|
|
1562
|
+
{
|
|
1563
|
+
description:
|
|
1564
|
+
'The property that the string representation of the global object constructor starts ' +
|
|
1565
|
+
'with "[object W"',
|
|
1566
|
+
check:
|
|
1567
|
+
function ()
|
|
2148
1568
|
{
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
[
|
|
2152
|
-
'ARROW',
|
|
2153
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2154
|
-
'ESC_REGEXP_SLASH',
|
|
2155
|
-
'FILL',
|
|
2156
|
-
'FROM_CODE_POINT',
|
|
2157
|
-
'FUNCTION_19_LF',
|
|
2158
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2159
|
-
'GLOBAL_UNDEFINED',
|
|
2160
|
-
'GMT',
|
|
2161
|
-
'INCR_CHAR',
|
|
2162
|
-
'LOCALE_INFINITY',
|
|
2163
|
-
'NAME',
|
|
2164
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2165
|
-
'PLAIN_INTL',
|
|
2166
|
-
'V8_SRC',
|
|
2167
|
-
],
|
|
2168
|
-
attributes: { 'char-increment-restriction': null },
|
|
1569
|
+
var available = /^\[object W/.test(constructor);
|
|
1570
|
+
return available;
|
|
2169
1571
|
},
|
|
2170
|
-
|
|
1572
|
+
attributes: { 'web-worker': 'old-safari-restriction' },
|
|
1573
|
+
},
|
|
1574
|
+
OLD_SAFARI_LOCATION_CTOR:
|
|
1575
|
+
{
|
|
1576
|
+
description:
|
|
1577
|
+
'Existence of the global object location.constructor whose string representation starts ' +
|
|
1578
|
+
'with "[object " and ends with "LocationConstructor]"',
|
|
1579
|
+
check:
|
|
1580
|
+
function ()
|
|
2171
1581
|
{
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
[
|
|
2175
|
-
|
|
2176
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2177
|
-
'ESC_REGEXP_SLASH',
|
|
2178
|
-
'FILL',
|
|
2179
|
-
'FLAT',
|
|
2180
|
-
'FROM_CODE_POINT',
|
|
2181
|
-
'FUNCTION_19_LF',
|
|
2182
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2183
|
-
'GLOBAL_UNDEFINED',
|
|
2184
|
-
'GMT',
|
|
2185
|
-
'INCR_CHAR',
|
|
2186
|
-
'LOCALE_INFINITY',
|
|
2187
|
-
'NAME',
|
|
2188
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2189
|
-
'PLAIN_INTL',
|
|
2190
|
-
'V8_SRC',
|
|
2191
|
-
],
|
|
2192
|
-
attributes: { 'char-increment-restriction': null },
|
|
1582
|
+
var available =
|
|
1583
|
+
typeof location === 'object' &&
|
|
1584
|
+
/^\[object [\S\s]*LocationConstructor]$/.test(location.constructor);
|
|
1585
|
+
return available;
|
|
2193
1586
|
},
|
|
2194
|
-
|
|
1587
|
+
},
|
|
1588
|
+
PLAIN_INTL:
|
|
1589
|
+
{
|
|
1590
|
+
description:
|
|
1591
|
+
'Existence of the global object Intl having the string representation "[object Object]"',
|
|
1592
|
+
check:
|
|
1593
|
+
function ()
|
|
2195
1594
|
{
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
[
|
|
2199
|
-
'ARROW',
|
|
2200
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2201
|
-
'ESC_REGEXP_LF',
|
|
2202
|
-
'ESC_REGEXP_SLASH',
|
|
2203
|
-
'FILL',
|
|
2204
|
-
'FLAT',
|
|
2205
|
-
'FROM_CODE_POINT',
|
|
2206
|
-
'FUNCTION_19_LF',
|
|
2207
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2208
|
-
'GLOBAL_UNDEFINED',
|
|
2209
|
-
'GMT',
|
|
2210
|
-
'INCR_CHAR',
|
|
2211
|
-
'LOCALE_INFINITY',
|
|
2212
|
-
'NAME',
|
|
2213
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2214
|
-
'PLAIN_INTL',
|
|
2215
|
-
'REGEXP_STRING_ITERATOR',
|
|
2216
|
-
'V8_SRC',
|
|
2217
|
-
],
|
|
2218
|
-
attributes: { 'char-increment-restriction': null },
|
|
1595
|
+
var available = typeof Intl === 'object' && Intl + '' === '[object Object]';
|
|
1596
|
+
return available;
|
|
2219
1597
|
},
|
|
2220
|
-
|
|
1598
|
+
includes: ['INTL'],
|
|
1599
|
+
},
|
|
1600
|
+
REGEXP_STRING_ITERATOR:
|
|
1601
|
+
{
|
|
1602
|
+
description:
|
|
1603
|
+
'The property that the string representation of String.prototype.matchAll() evaluates to ' +
|
|
1604
|
+
'"[object RegExp String Iterator]".',
|
|
1605
|
+
check:
|
|
1606
|
+
function ()
|
|
2221
1607
|
{
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
'ARROW',
|
|
2226
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2227
|
-
'ESC_REGEXP_LF',
|
|
2228
|
-
'ESC_REGEXP_SLASH',
|
|
2229
|
-
'FILL',
|
|
2230
|
-
'FLAT',
|
|
2231
|
-
'FROM_CODE_POINT',
|
|
2232
|
-
'FUNCTION_19_LF',
|
|
2233
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2234
|
-
'GLOBAL_UNDEFINED',
|
|
2235
|
-
'GMT',
|
|
2236
|
-
'INCR_CHAR',
|
|
2237
|
-
'LOCALE_INFINITY',
|
|
2238
|
-
'LOCALE_NUMERALS_EXT',
|
|
2239
|
-
'NAME',
|
|
2240
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2241
|
-
'PLAIN_INTL',
|
|
2242
|
-
'REGEXP_STRING_ITERATOR',
|
|
2243
|
-
'SHORT_LOCALES',
|
|
2244
|
-
'V8_SRC',
|
|
2245
|
-
],
|
|
2246
|
-
attributes: { 'char-increment-restriction': null },
|
|
1608
|
+
var available =
|
|
1609
|
+
String.prototype.matchAll && ''.matchAll() + '' === '[object RegExp String Iterator]';
|
|
1610
|
+
return available;
|
|
2247
1611
|
},
|
|
2248
|
-
|
|
1612
|
+
},
|
|
1613
|
+
SELF: { aliasFor: 'ANY_WINDOW' },
|
|
1614
|
+
SELF_OBJ:
|
|
1615
|
+
{
|
|
1616
|
+
description:
|
|
1617
|
+
'Existence of the global object self whose string representation starts with "[object ".',
|
|
1618
|
+
check:
|
|
1619
|
+
checkSelfFeature.bind
|
|
1620
|
+
(
|
|
1621
|
+
function (str)
|
|
1622
|
+
{
|
|
1623
|
+
var available = /^\[object /.test(str);
|
|
1624
|
+
return available;
|
|
1625
|
+
}
|
|
1626
|
+
),
|
|
1627
|
+
attributes: { 'web-worker': 'safari-bug-21820506' },
|
|
1628
|
+
},
|
|
1629
|
+
SHORT_LOCALES:
|
|
1630
|
+
{
|
|
1631
|
+
description:
|
|
1632
|
+
'Support for the two-letter locale name "ar" to format decimal numbers as Arabic numerals.',
|
|
1633
|
+
check:
|
|
1634
|
+
function ()
|
|
2249
1635
|
{
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
'FILL',
|
|
2258
|
-
'FLAT',
|
|
2259
|
-
'FROM_CODE_POINT',
|
|
2260
|
-
'FUNCTION_19_LF',
|
|
2261
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2262
|
-
'GLOBAL_UNDEFINED',
|
|
2263
|
-
'GMT',
|
|
2264
|
-
'INCR_CHAR',
|
|
2265
|
-
'INTL',
|
|
2266
|
-
'LOCALE_INFINITY',
|
|
2267
|
-
'LOCALE_NUMERALS_EXT',
|
|
2268
|
-
'NAME',
|
|
2269
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2270
|
-
'REGEXP_STRING_ITERATOR',
|
|
2271
|
-
'SHORT_LOCALES',
|
|
2272
|
-
'V8_SRC',
|
|
2273
|
-
],
|
|
2274
|
-
attributes: { 'char-increment-restriction': null },
|
|
1636
|
+
var NUMBER = 9876430.125;
|
|
1637
|
+
|
|
1638
|
+
var localizedNumeral = NUMBER.toLocaleString('ar');
|
|
1639
|
+
var available =
|
|
1640
|
+
localizedNumeral === NUMBER.toLocaleString('ar-td') &&
|
|
1641
|
+
localizedNumeral !== NUMBER.toLocaleString('en');
|
|
1642
|
+
return available;
|
|
2275
1643
|
},
|
|
2276
|
-
|
|
1644
|
+
includes: ['LOCALE_NUMERALS'],
|
|
1645
|
+
},
|
|
1646
|
+
STATUS:
|
|
1647
|
+
{
|
|
1648
|
+
description: 'Existence of the global string status.',
|
|
1649
|
+
check:
|
|
1650
|
+
function ()
|
|
2277
1651
|
{
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
[
|
|
2281
|
-
'ARROW',
|
|
2282
|
-
'ATOB',
|
|
2283
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2284
|
-
'ESC_REGEXP_LF',
|
|
2285
|
-
'ESC_REGEXP_SLASH',
|
|
2286
|
-
'FILL',
|
|
2287
|
-
'FLAT',
|
|
2288
|
-
'FROM_CODE_POINT',
|
|
2289
|
-
'FUNCTION_19_LF',
|
|
2290
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2291
|
-
'GLOBAL_UNDEFINED',
|
|
2292
|
-
'GMT',
|
|
2293
|
-
'INCR_CHAR',
|
|
2294
|
-
'INTL',
|
|
2295
|
-
'LOCALE_INFINITY',
|
|
2296
|
-
'LOCALE_NUMERALS_EXT',
|
|
2297
|
-
'NAME',
|
|
2298
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2299
|
-
'REGEXP_STRING_ITERATOR',
|
|
2300
|
-
'SHORT_LOCALES',
|
|
2301
|
-
'V8_SRC',
|
|
2302
|
-
],
|
|
2303
|
-
attributes: { 'char-increment-restriction': null },
|
|
1652
|
+
var available = typeof status === 'string';
|
|
1653
|
+
return available;
|
|
2304
1654
|
},
|
|
2305
|
-
|
|
1655
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1656
|
+
},
|
|
1657
|
+
UNDEFINED:
|
|
1658
|
+
{
|
|
1659
|
+
description:
|
|
1660
|
+
'The property that Object.prototype.toString.call() evaluates to "[object Undefined]".\n' +
|
|
1661
|
+
'This behavior is specified by ECMAScript, and is enforced by all engines except Android ' +
|
|
1662
|
+
'Browser versions prior to 4.1.2, where this feature is not available.',
|
|
1663
|
+
check:
|
|
1664
|
+
function ()
|
|
2306
1665
|
{
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
[
|
|
2310
|
-
'ATOB',
|
|
2311
|
-
'BARPROP',
|
|
2312
|
-
'CONSOLE',
|
|
2313
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2314
|
-
'ESC_REGEXP_LF',
|
|
2315
|
-
'ESC_REGEXP_SLASH',
|
|
2316
|
-
'FF_SRC',
|
|
2317
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2318
|
-
'GLOBAL_UNDEFINED',
|
|
2319
|
-
'GMT',
|
|
2320
|
-
'HISTORY',
|
|
2321
|
-
'HTMLDOCUMENT',
|
|
2322
|
-
'INCR_CHAR',
|
|
2323
|
-
'LOCATION',
|
|
2324
|
-
'NAME',
|
|
2325
|
-
'NODECONSTRUCTOR',
|
|
2326
|
-
'STATUS',
|
|
2327
|
-
'WINDOW',
|
|
2328
|
-
],
|
|
2329
|
-
attributes:
|
|
2330
|
-
{
|
|
2331
|
-
'char-increment-restriction': null,
|
|
2332
|
-
'no-atob-in-web-worker': null,
|
|
2333
|
-
'no-console-in-web-worker': null,
|
|
2334
|
-
'web-worker-restriction': null,
|
|
2335
|
-
},
|
|
1666
|
+
var available = Object.prototype.toString.call() === '[object Undefined]';
|
|
1667
|
+
return available;
|
|
2336
1668
|
},
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
'INCR_CHAR',
|
|
2357
|
-
'LOCATION',
|
|
2358
|
-
'NAME',
|
|
2359
|
-
'NODECONSTRUCTOR',
|
|
2360
|
-
'STATUS',
|
|
2361
|
-
'WINDOW',
|
|
2362
|
-
],
|
|
2363
|
-
attributes:
|
|
1669
|
+
},
|
|
1670
|
+
V8_SRC:
|
|
1671
|
+
{
|
|
1672
|
+
description:
|
|
1673
|
+
'A string representation of native functions typical for the V8 engine.\n' +
|
|
1674
|
+
'Remarkable traits are the lack of line feed characters at the beginning and at the end ' +
|
|
1675
|
+
'of the string and the presence of a single whitespace before the "[native code]" ' +
|
|
1676
|
+
'sequence.',
|
|
1677
|
+
includes: ['NO_FF_SRC', 'NO_IE_SRC'],
|
|
1678
|
+
excludes: ['NO_V8_SRC'],
|
|
1679
|
+
},
|
|
1680
|
+
WINDOW:
|
|
1681
|
+
{
|
|
1682
|
+
description:
|
|
1683
|
+
'Existence of the global object self having the string representation "[object Window]".',
|
|
1684
|
+
check:
|
|
1685
|
+
checkSelfFeature.bind
|
|
1686
|
+
(
|
|
1687
|
+
function (str)
|
|
2364
1688
|
{
|
|
2365
|
-
'
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
1689
|
+
var available = str === '[object Window]';
|
|
1690
|
+
return available;
|
|
1691
|
+
}
|
|
1692
|
+
),
|
|
1693
|
+
includes: ['ANY_WINDOW'],
|
|
1694
|
+
excludes: ['DOMWINDOW'],
|
|
1695
|
+
attributes: { 'web-worker': 'web-worker-restriction' },
|
|
1696
|
+
},
|
|
1697
|
+
|
|
1698
|
+
DEFAULT:
|
|
1699
|
+
{
|
|
1700
|
+
description:
|
|
1701
|
+
'Minimum feature level, compatible with all supported engines in all environments.',
|
|
1702
|
+
},
|
|
1703
|
+
BROWSER:
|
|
1704
|
+
{
|
|
1705
|
+
description:
|
|
1706
|
+
'Features available in all browsers.\n' +
|
|
1707
|
+
'No support for Node.js.',
|
|
1708
|
+
includes: ['ANY_DOCUMENT', 'ANY_WINDOW', 'HISTORY', 'INCR_CHAR', 'STATUS'],
|
|
1709
|
+
attributes:
|
|
2373
1710
|
{
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
'ATOB',
|
|
2378
|
-
'BARPROP',
|
|
2379
|
-
'CONSOLE',
|
|
2380
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2381
|
-
'ESC_REGEXP_LF',
|
|
2382
|
-
'ESC_REGEXP_SLASH',
|
|
2383
|
-
'FF_SRC',
|
|
2384
|
-
'FILL',
|
|
2385
|
-
'FROM_CODE_POINT',
|
|
2386
|
-
'FUNCTION_22_LF',
|
|
2387
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2388
|
-
'GLOBAL_UNDEFINED',
|
|
2389
|
-
'GMT',
|
|
2390
|
-
'HISTORY',
|
|
2391
|
-
'HTMLDOCUMENT',
|
|
2392
|
-
'INCR_CHAR',
|
|
2393
|
-
'LOCATION',
|
|
2394
|
-
'NAME',
|
|
2395
|
-
'NODECONSTRUCTOR',
|
|
2396
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2397
|
-
'STATUS',
|
|
2398
|
-
'WINDOW',
|
|
2399
|
-
],
|
|
2400
|
-
attributes:
|
|
2401
|
-
{
|
|
2402
|
-
'char-increment-restriction': null,
|
|
2403
|
-
'no-atob-in-web-worker': null,
|
|
2404
|
-
'safari-bug-21820506': null,
|
|
2405
|
-
'web-worker-restriction': null,
|
|
2406
|
-
},
|
|
1711
|
+
'char-increment-restriction': null,
|
|
1712
|
+
'safari-bug-21820506': null,
|
|
1713
|
+
'web-worker-restriction': null,
|
|
2407
1714
|
},
|
|
2408
|
-
|
|
1715
|
+
},
|
|
1716
|
+
COMPACT:
|
|
1717
|
+
{
|
|
1718
|
+
description:
|
|
1719
|
+
'All new browsers\' features.\n' +
|
|
1720
|
+
'No support for Node.js and older browsers like Internet Explorer, Safari 9 or Android ' +
|
|
1721
|
+
'Browser.',
|
|
1722
|
+
includes:
|
|
1723
|
+
[
|
|
1724
|
+
'ARROW',
|
|
1725
|
+
'ATOB',
|
|
1726
|
+
'BARPROP',
|
|
1727
|
+
'ESC_HTML_QUOT_ONLY',
|
|
1728
|
+
'ESC_REGEXP_LF',
|
|
1729
|
+
'ESC_REGEXP_SLASH',
|
|
1730
|
+
'FILL',
|
|
1731
|
+
'FLAT',
|
|
1732
|
+
'FROM_CODE_POINT',
|
|
1733
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
1734
|
+
'GLOBAL_UNDEFINED',
|
|
1735
|
+
'GMT',
|
|
1736
|
+
'HISTORY',
|
|
1737
|
+
'HTMLDOCUMENT',
|
|
1738
|
+
'INCR_CHAR',
|
|
1739
|
+
'INTL',
|
|
1740
|
+
'LOCALE_INFINITY',
|
|
1741
|
+
'LOCALE_NUMERALS_EXT',
|
|
1742
|
+
'LOCATION',
|
|
1743
|
+
'NAME',
|
|
1744
|
+
'NO_IE_SRC',
|
|
1745
|
+
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1746
|
+
'REGEXP_STRING_ITERATOR',
|
|
1747
|
+
'STATUS',
|
|
1748
|
+
'WINDOW',
|
|
1749
|
+
],
|
|
1750
|
+
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1751
|
+
},
|
|
1752
|
+
ANDRO_4_0:
|
|
1753
|
+
{
|
|
1754
|
+
families: ['Android Browser'],
|
|
1755
|
+
versions: ['4.0'],
|
|
1756
|
+
includes:
|
|
1757
|
+
[
|
|
1758
|
+
'ATOB',
|
|
1759
|
+
'CONSOLE',
|
|
1760
|
+
'DOMWINDOW',
|
|
1761
|
+
'ESC_HTML_ALL',
|
|
1762
|
+
'FUNCTION_22_LF',
|
|
1763
|
+
'GMT',
|
|
1764
|
+
'HISTORY',
|
|
1765
|
+
'HTMLDOCUMENT',
|
|
1766
|
+
'INCR_CHAR',
|
|
1767
|
+
'LOCATION',
|
|
1768
|
+
'NAME',
|
|
1769
|
+
'STATUS',
|
|
1770
|
+
'V8_SRC',
|
|
1771
|
+
],
|
|
1772
|
+
},
|
|
1773
|
+
ANDRO_4_1:
|
|
1774
|
+
{
|
|
1775
|
+
inherits: 'ANDRO_4_0',
|
|
1776
|
+
versions: [['4.1',, '4.3']],
|
|
1777
|
+
includes: { GENERIC_ARRAY_TO_STRING: true, OBJECT_UNDEFINED: true },
|
|
1778
|
+
},
|
|
1779
|
+
ANDRO_4_4:
|
|
1780
|
+
{
|
|
1781
|
+
inherits: 'ANDRO_4_1',
|
|
1782
|
+
versions: ['4.4'],
|
|
1783
|
+
includes:
|
|
2409
1784
|
{
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
'ESC_REGEXP_LF',
|
|
2419
|
-
'ESC_REGEXP_SLASH',
|
|
2420
|
-
'FF_SRC',
|
|
2421
|
-
'FILL',
|
|
2422
|
-
'FROM_CODE_POINT',
|
|
2423
|
-
'FUNCTION_22_LF',
|
|
2424
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2425
|
-
'GLOBAL_UNDEFINED',
|
|
2426
|
-
'GMT',
|
|
2427
|
-
'HISTORY',
|
|
2428
|
-
'HTMLDOCUMENT',
|
|
2429
|
-
'INCR_CHAR',
|
|
2430
|
-
'LOCALE_INFINITY',
|
|
2431
|
-
'LOCALE_NUMERALS_EXT',
|
|
2432
|
-
'LOCATION',
|
|
2433
|
-
'NAME',
|
|
2434
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2435
|
-
'PLAIN_INTL',
|
|
2436
|
-
'SHORT_LOCALES',
|
|
2437
|
-
'STATUS',
|
|
2438
|
-
'WINDOW',
|
|
2439
|
-
],
|
|
2440
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1785
|
+
BARPROP: true,
|
|
1786
|
+
DOMWINDOW: false,
|
|
1787
|
+
HTMLAUDIOELEMENT: true,
|
|
1788
|
+
LOCALE_INFINITY: true,
|
|
1789
|
+
LOCALE_NUMERALS_EXT: true,
|
|
1790
|
+
PLAIN_INTL: true,
|
|
1791
|
+
SHORT_LOCALES: true,
|
|
1792
|
+
WINDOW: true,
|
|
2441
1793
|
},
|
|
2442
|
-
|
|
1794
|
+
attributes: { 'no-console-in-web-worker': null, 'web-worker-restriction': null },
|
|
1795
|
+
},
|
|
1796
|
+
CHROME_PREV:
|
|
1797
|
+
{
|
|
1798
|
+
description: describeEngine('the previous to current versions of Chrome and Edge'),
|
|
1799
|
+
aliasFor: 'CHROME_92',
|
|
1800
|
+
},
|
|
1801
|
+
CHROME:
|
|
1802
|
+
{
|
|
1803
|
+
description: describeEngine('the current stable versions of Chrome, Edge and Opera'),
|
|
1804
|
+
aliasFor: 'CHROME_92',
|
|
1805
|
+
},
|
|
1806
|
+
CHROME_92:
|
|
1807
|
+
{
|
|
1808
|
+
families: ['Chrome', 'Edge', 'Opera'],
|
|
1809
|
+
versions: [['92'], ['92'], ['78']],
|
|
1810
|
+
includes:
|
|
1811
|
+
[
|
|
1812
|
+
'ARROW',
|
|
1813
|
+
'AT',
|
|
1814
|
+
'ATOB',
|
|
1815
|
+
'BARPROP',
|
|
1816
|
+
'ESC_HTML_QUOT_ONLY',
|
|
1817
|
+
'ESC_REGEXP_LF',
|
|
1818
|
+
'ESC_REGEXP_SLASH',
|
|
1819
|
+
'FILL',
|
|
1820
|
+
'FLAT',
|
|
1821
|
+
'FROM_CODE_POINT',
|
|
1822
|
+
'FUNCTION_19_LF',
|
|
1823
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
1824
|
+
'GLOBAL_UNDEFINED',
|
|
1825
|
+
'GMT',
|
|
1826
|
+
'HISTORY',
|
|
1827
|
+
'HTMLDOCUMENT',
|
|
1828
|
+
'INCR_CHAR',
|
|
1829
|
+
'INTL',
|
|
1830
|
+
'LOCALE_INFINITY',
|
|
1831
|
+
'LOCALE_NUMERALS_EXT',
|
|
1832
|
+
'LOCATION',
|
|
1833
|
+
'NAME',
|
|
1834
|
+
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1835
|
+
'REGEXP_STRING_ITERATOR',
|
|
1836
|
+
'STATUS',
|
|
1837
|
+
'V8_SRC',
|
|
1838
|
+
'WINDOW',
|
|
1839
|
+
],
|
|
1840
|
+
attributes:
|
|
1841
|
+
{ 'char-increment-restriction': null, 'unstable': null, 'web-worker-restriction': null },
|
|
1842
|
+
},
|
|
1843
|
+
FF_ESR:
|
|
1844
|
+
{
|
|
1845
|
+
description: describeEngine('the current version of Firefox ESR'),
|
|
1846
|
+
aliasFor: 'FF_78',
|
|
1847
|
+
},
|
|
1848
|
+
FF_78:
|
|
1849
|
+
{
|
|
1850
|
+
families: ['Firefox'],
|
|
1851
|
+
versions: [['78',, '82']],
|
|
1852
|
+
includes:
|
|
1853
|
+
[
|
|
1854
|
+
'ARROW',
|
|
1855
|
+
'ATOB',
|
|
1856
|
+
'BARPROP',
|
|
1857
|
+
'ESC_HTML_QUOT_ONLY',
|
|
1858
|
+
'ESC_REGEXP_LF',
|
|
1859
|
+
'ESC_REGEXP_SLASH',
|
|
1860
|
+
'FF_SRC',
|
|
1861
|
+
'FILL',
|
|
1862
|
+
'FLAT',
|
|
1863
|
+
'FROM_CODE_POINT',
|
|
1864
|
+
'FUNCTION_19_LF',
|
|
1865
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
1866
|
+
'GLOBAL_UNDEFINED',
|
|
1867
|
+
'GMT',
|
|
1868
|
+
'HISTORY',
|
|
1869
|
+
'HTMLDOCUMENT',
|
|
1870
|
+
'INCR_CHAR',
|
|
1871
|
+
'LOCALE_INFINITY',
|
|
1872
|
+
'LOCALE_NUMERALS_EXT',
|
|
1873
|
+
'LOCATION',
|
|
1874
|
+
'NAME',
|
|
1875
|
+
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
1876
|
+
'PLAIN_INTL',
|
|
1877
|
+
'REGEXP_STRING_ITERATOR',
|
|
1878
|
+
'SHORT_LOCALES',
|
|
1879
|
+
'STATUS',
|
|
1880
|
+
'WINDOW',
|
|
1881
|
+
],
|
|
1882
|
+
attributes:
|
|
1883
|
+
{ 'char-increment-restriction': null, 'unstable': null, 'web-worker-restriction': null },
|
|
1884
|
+
},
|
|
1885
|
+
FF_83:
|
|
1886
|
+
{
|
|
1887
|
+
inherits: 'FF_78',
|
|
1888
|
+
versions: [['83',, '89']],
|
|
1889
|
+
includes: { INTL: true, PLAIN_INTL: false },
|
|
1890
|
+
},
|
|
1891
|
+
FF_PREV:
|
|
1892
|
+
{
|
|
1893
|
+
description: describeEngine('the previous to current version of Firefox'),
|
|
1894
|
+
aliasFor: 'FF_90',
|
|
1895
|
+
},
|
|
1896
|
+
FF:
|
|
1897
|
+
{
|
|
1898
|
+
description: describeEngine('the current stable version of Firefox'),
|
|
1899
|
+
aliasFor: 'FF_90',
|
|
1900
|
+
},
|
|
1901
|
+
FF_90:
|
|
1902
|
+
{
|
|
1903
|
+
inherits: 'FF_83',
|
|
1904
|
+
versions: [['90']],
|
|
1905
|
+
includes: { AT: true },
|
|
1906
|
+
},
|
|
1907
|
+
IE_9:
|
|
1908
|
+
{
|
|
1909
|
+
families: ['Internet Explorer'],
|
|
1910
|
+
versions: ['9'],
|
|
1911
|
+
includes:
|
|
1912
|
+
[
|
|
1913
|
+
'CAPITAL_HTML',
|
|
1914
|
+
'DOCUMENT',
|
|
1915
|
+
'ESC_REGEXP_LF',
|
|
1916
|
+
'ESC_REGEXP_SLASH',
|
|
1917
|
+
'FUNCTION_22_LF',
|
|
1918
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
1919
|
+
'HISTORY',
|
|
1920
|
+
'IE_SRC',
|
|
1921
|
+
'INCR_CHAR',
|
|
1922
|
+
'OBJECT_L_LOCATION_CTOR',
|
|
1923
|
+
'OBJECT_W_CTOR',
|
|
1924
|
+
'STATUS',
|
|
1925
|
+
'UNDEFINED',
|
|
1926
|
+
'WINDOW',
|
|
1927
|
+
],
|
|
1928
|
+
},
|
|
1929
|
+
IE_10:
|
|
1930
|
+
{
|
|
1931
|
+
inherits: 'IE_9',
|
|
1932
|
+
versions: ['10'],
|
|
1933
|
+
includes: { ATOB: true, CONSOLE: true, OBJECT_UNDEFINED: true, UNDEFINED: false },
|
|
1934
|
+
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1935
|
+
},
|
|
1936
|
+
IE_11:
|
|
1937
|
+
{
|
|
1938
|
+
inherits: 'IE_10',
|
|
1939
|
+
versions: ['11'],
|
|
1940
|
+
includes:
|
|
2443
1941
|
{
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
'CONSOLE',
|
|
2451
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2452
|
-
'ESC_REGEXP_LF',
|
|
2453
|
-
'ESC_REGEXP_SLASH',
|
|
2454
|
-
'FF_SRC',
|
|
2455
|
-
'FILL',
|
|
2456
|
-
'FLAT',
|
|
2457
|
-
'FROM_CODE_POINT',
|
|
2458
|
-
'FUNCTION_22_LF',
|
|
2459
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2460
|
-
'GLOBAL_UNDEFINED',
|
|
2461
|
-
'GMT',
|
|
2462
|
-
'HISTORY',
|
|
2463
|
-
'HTMLDOCUMENT',
|
|
2464
|
-
'INCR_CHAR',
|
|
2465
|
-
'LOCALE_INFINITY',
|
|
2466
|
-
'LOCALE_NUMERALS_EXT',
|
|
2467
|
-
'LOCATION',
|
|
2468
|
-
'NAME',
|
|
2469
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2470
|
-
'PLAIN_INTL',
|
|
2471
|
-
'SHORT_LOCALES',
|
|
2472
|
-
'STATUS',
|
|
2473
|
-
'WINDOW',
|
|
2474
|
-
],
|
|
2475
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1942
|
+
DOCUMENT: false,
|
|
1943
|
+
GMT: true,
|
|
1944
|
+
HTMLDOCUMENT: true,
|
|
1945
|
+
LOCALE_NUMERALS: true,
|
|
1946
|
+
PLAIN_INTL: true,
|
|
1947
|
+
SHORT_LOCALES: true,
|
|
2476
1948
|
},
|
|
2477
|
-
|
|
1949
|
+
},
|
|
1950
|
+
IE_11_WIN_10:
|
|
1951
|
+
{
|
|
1952
|
+
inherits: 'IE_11',
|
|
1953
|
+
versions: ['11'],
|
|
1954
|
+
compatibilityTag: 'on Windows 10',
|
|
1955
|
+
compatibilityShortTag: 'W10',
|
|
1956
|
+
includes: { LOCALE_INFINITY: true, LOCALE_NUMERALS: false, LOCALE_NUMERALS_EXT: true },
|
|
1957
|
+
},
|
|
1958
|
+
NODE_0_10:
|
|
1959
|
+
{
|
|
1960
|
+
families: ['Node.js'],
|
|
1961
|
+
versions: ['0.10'],
|
|
1962
|
+
includes:
|
|
1963
|
+
[
|
|
1964
|
+
'ESC_HTML_ALL',
|
|
1965
|
+
'FUNCTION_22_LF',
|
|
1966
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
1967
|
+
'GLOBAL_UNDEFINED',
|
|
1968
|
+
'GMT',
|
|
1969
|
+
'INCR_CHAR',
|
|
1970
|
+
'NAME',
|
|
1971
|
+
'V8_SRC',
|
|
1972
|
+
],
|
|
1973
|
+
},
|
|
1974
|
+
NODE_0_12:
|
|
1975
|
+
{
|
|
1976
|
+
inherits: 'NODE_0_10',
|
|
1977
|
+
versions: ['0.12'],
|
|
1978
|
+
includes:
|
|
2478
1979
|
{
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
'BARPROP',
|
|
2485
|
-
'CONSOLE',
|
|
2486
|
-
'ESC_HTML_QUOT_ONLY',
|
|
2487
|
-
'ESC_REGEXP_LF',
|
|
2488
|
-
'ESC_REGEXP_SLASH',
|
|
2489
|
-
'FF_SRC',
|
|
2490
|
-
'FILL',
|
|
2491
|
-
'FLAT',
|
|
2492
|
-
'FROM_CODE_POINT',
|
|
2493
|
-
'FUNCTION_22_LF',
|
|
2494
|
-
'GENERIC_ARRAY_TO_STRING',
|
|
2495
|
-
'GLOBAL_UNDEFINED',
|
|
2496
|
-
'GMT',
|
|
2497
|
-
'HISTORY',
|
|
2498
|
-
'HTMLDOCUMENT',
|
|
2499
|
-
'INCR_CHAR',
|
|
2500
|
-
'LOCALE_INFINITY',
|
|
2501
|
-
'LOCALE_NUMERALS_EXT',
|
|
2502
|
-
'LOCATION',
|
|
2503
|
-
'NAME',
|
|
2504
|
-
'NO_OLD_SAFARI_ARRAY_ITERATOR',
|
|
2505
|
-
'PLAIN_INTL',
|
|
2506
|
-
'REGEXP_STRING_ITERATOR',
|
|
2507
|
-
'SHORT_LOCALES',
|
|
2508
|
-
'STATUS',
|
|
2509
|
-
'WINDOW',
|
|
2510
|
-
],
|
|
2511
|
-
attributes: { 'char-increment-restriction': null, 'web-worker-restriction': null },
|
|
1980
|
+
ESC_HTML_ALL: false,
|
|
1981
|
+
ESC_HTML_QUOT_ONLY: true,
|
|
1982
|
+
LOCALE_INFINITY: true,
|
|
1983
|
+
NO_OLD_SAFARI_ARRAY_ITERATOR: true,
|
|
1984
|
+
PLAIN_INTL: true,
|
|
2512
1985
|
},
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
1986
|
+
},
|
|
1987
|
+
NODE_4:
|
|
1988
|
+
{
|
|
1989
|
+
inherits: 'NODE_0_12',
|
|
1990
|
+
versions: ['4'],
|
|
1991
|
+
includes: { ARROW: true, ESC_REGEXP_SLASH: true, FILL: true, FROM_CODE_POINT: true },
|
|
1992
|
+
},
|
|
1993
|
+
NODE_5:
|
|
1994
|
+
{
|
|
1995
|
+
inherits: 'NODE_4',
|
|
1996
|
+
versions: [['5',, '9']],
|
|
1997
|
+
attributes: { 'char-increment-restriction': null },
|
|
1998
|
+
},
|
|
1999
|
+
NODE_10:
|
|
2000
|
+
{
|
|
2001
|
+
inherits: 'NODE_5',
|
|
2002
|
+
versions: ['10'],
|
|
2003
|
+
includes: { FUNCTION_19_LF: true, FUNCTION_22_LF: false },
|
|
2004
|
+
},
|
|
2005
|
+
NODE_11:
|
|
2006
|
+
{
|
|
2007
|
+
inherits: 'NODE_10',
|
|
2008
|
+
versions: ['11'],
|
|
2009
|
+
includes: { FLAT: true },
|
|
2010
|
+
},
|
|
2011
|
+
NODE_12:
|
|
2012
|
+
{
|
|
2013
|
+
inherits: 'NODE_11',
|
|
2014
|
+
versions: ['12'],
|
|
2015
|
+
includes: { ESC_REGEXP_LF: true, REGEXP_STRING_ITERATOR: true },
|
|
2016
|
+
},
|
|
2017
|
+
NODE_13:
|
|
2018
|
+
{
|
|
2019
|
+
inherits: 'NODE_12',
|
|
2020
|
+
versions: [['13', '14']],
|
|
2021
|
+
includes: { LOCALE_NUMERALS_EXT: true, SHORT_LOCALES: true },
|
|
2022
|
+
},
|
|
2023
|
+
NODE_15:
|
|
2024
|
+
{
|
|
2025
|
+
inherits: 'NODE_13',
|
|
2026
|
+
versions: ['15'],
|
|
2027
|
+
includes: { INTL: true, PLAIN_INTL: false },
|
|
2028
|
+
},
|
|
2029
|
+
NODE_16_0:
|
|
2030
|
+
{
|
|
2031
|
+
inherits: 'NODE_15',
|
|
2032
|
+
versions: [['16.0',, '16.5']],
|
|
2033
|
+
includes: { ATOB: true },
|
|
2034
|
+
},
|
|
2035
|
+
NODE_16_6:
|
|
2036
|
+
{
|
|
2037
|
+
inherits: 'NODE_16_0',
|
|
2038
|
+
versions: [['16.6']],
|
|
2039
|
+
includes: { AT: true },
|
|
2040
|
+
},
|
|
2041
|
+
SAFARI_7_0:
|
|
2042
|
+
{
|
|
2043
|
+
families: ['Safari'],
|
|
2044
|
+
versions: ['7.0'],
|
|
2045
|
+
includes:
|
|
2046
|
+
[
|
|
2047
|
+
'ATOB',
|
|
2048
|
+
'BARPROP',
|
|
2049
|
+
'CONSOLE',
|
|
2050
|
+
'ESC_HTML_QUOT_ONLY',
|
|
2051
|
+
'ESC_REGEXP_LF',
|
|
2052
|
+
'ESC_REGEXP_SLASH',
|
|
2053
|
+
'FF_SRC',
|
|
2054
|
+
'GENERIC_ARRAY_TO_STRING',
|
|
2055
|
+
'GLOBAL_UNDEFINED',
|
|
2056
|
+
'GMT',
|
|
2057
|
+
'HISTORY',
|
|
2058
|
+
'HTMLDOCUMENT',
|
|
2059
|
+
'INCR_CHAR',
|
|
2060
|
+
'LOCATION',
|
|
2061
|
+
'NAME',
|
|
2062
|
+
'NODECONSTRUCTOR',
|
|
2063
|
+
'OBJECT_L_LOCATION_CTOR',
|
|
2064
|
+
'OBJECT_W_CTOR',
|
|
2065
|
+
'OLD_SAFARI_LOCATION_CTOR',
|
|
2066
|
+
'STATUS',
|
|
2067
|
+
'WINDOW',
|
|
2068
|
+
],
|
|
2069
|
+
attributes:
|
|
2070
|
+
{
|
|
2071
|
+
'char-increment-restriction': null,
|
|
2072
|
+
'no-console-in-web-worker': null,
|
|
2073
|
+
'old-safari-restriction': null,
|
|
2074
|
+
'web-worker-restriction': null,
|
|
2548
2075
|
},
|
|
2549
|
-
|
|
2076
|
+
},
|
|
2077
|
+
SAFARI_7_1:
|
|
2078
|
+
{
|
|
2079
|
+
inherits: 'SAFARI_7_0',
|
|
2080
|
+
versions: [['7.1', '8']],
|
|
2081
|
+
includes: { ARRAY_ITERATOR: true, FILL: true },
|
|
2082
|
+
attributes: { 'no-console-in-web-worker': undefined, 'safari-bug-21820506': null },
|
|
2083
|
+
},
|
|
2084
|
+
SAFARI_9:
|
|
2085
|
+
{
|
|
2086
|
+
inherits: 'SAFARI_7_1',
|
|
2087
|
+
versions: ['9'],
|
|
2088
|
+
includes:
|
|
2550
2089
|
{
|
|
2551
|
-
|
|
2552
|
-
|
|
2090
|
+
ARRAY_ITERATOR: false,
|
|
2091
|
+
FROM_CODE_POINT: true,
|
|
2092
|
+
FUNCTION_22_LF: true,
|
|
2093
|
+
NO_OLD_SAFARI_ARRAY_ITERATOR: true,
|
|
2553
2094
|
},
|
|
2554
|
-
|
|
2095
|
+
},
|
|
2096
|
+
SAFARI_10:
|
|
2097
|
+
{
|
|
2098
|
+
inherits: 'SAFARI_9',
|
|
2099
|
+
versions: [['10', '11']],
|
|
2100
|
+
includes:
|
|
2555
2101
|
{
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
|
|
2576
|
-
|
|
2577
|
-
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
|
|
2582
|
-
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2102
|
+
ARROW: true,
|
|
2103
|
+
LOCALE_INFINITY: true,
|
|
2104
|
+
LOCALE_NUMERALS_EXT: true,
|
|
2105
|
+
NODECONSTRUCTOR: false,
|
|
2106
|
+
OBJECT_L_LOCATION_CTOR: false,
|
|
2107
|
+
OBJECT_W_CTOR: false,
|
|
2108
|
+
OLD_SAFARI_LOCATION_CTOR: false,
|
|
2109
|
+
PLAIN_INTL: true,
|
|
2110
|
+
SHORT_LOCALES: true,
|
|
2111
|
+
},
|
|
2112
|
+
attributes: { 'old-safari-restriction': undefined, 'safari-bug-21820506': undefined },
|
|
2113
|
+
},
|
|
2114
|
+
SAFARI_12:
|
|
2115
|
+
{
|
|
2116
|
+
inherits: 'SAFARI_10',
|
|
2117
|
+
versions: ['12'],
|
|
2118
|
+
includes: { FLAT: true },
|
|
2119
|
+
},
|
|
2120
|
+
SAFARI_13:
|
|
2121
|
+
{
|
|
2122
|
+
inherits: 'SAFARI_12',
|
|
2123
|
+
versions: [['13', '14.0.0']],
|
|
2124
|
+
includes: { REGEXP_STRING_ITERATOR: true },
|
|
2125
|
+
},
|
|
2126
|
+
SAFARI_14_0_1:
|
|
2127
|
+
{
|
|
2128
|
+
inherits: 'SAFARI_13',
|
|
2129
|
+
versions: [['14.0.1',, '14.0.3']],
|
|
2130
|
+
includes: { INTL: true, PLAIN_INTL: false },
|
|
2131
|
+
},
|
|
2132
|
+
SAFARI:
|
|
2133
|
+
{
|
|
2134
|
+
description: describeEngine('the current stable version of Safari'),
|
|
2135
|
+
aliasFor: 'SAFARI_14_1',
|
|
2136
|
+
},
|
|
2137
|
+
SAFARI_14_1:
|
|
2138
|
+
{
|
|
2139
|
+
inherits: 'SAFARI_14_0_1',
|
|
2140
|
+
versions: [['14.1']],
|
|
2141
|
+
includes: { CONSOLE: false },
|
|
2142
|
+
},
|
|
2143
|
+
};
|
|
2144
|
+
(function ()
|
|
2145
|
+
{
|
|
2146
|
+
function formatEngineDescription(compatibilities)
|
|
2147
|
+
{
|
|
2148
|
+
var appendix = '';
|
|
2149
|
+
var parts =
|
|
2150
|
+
compatibilities.map
|
|
2151
|
+
(
|
|
2152
|
+
function (compatibility)
|
|
2153
|
+
{
|
|
2154
|
+
var family = compatibility.family;
|
|
2155
|
+
var version = compatibility.version;
|
|
2156
|
+
var part = family;
|
|
2157
|
+
if (typeof version === 'string')
|
|
2158
|
+
part += ' ' + version;
|
|
2159
|
+
else
|
|
2160
|
+
{
|
|
2161
|
+
part += ' ' + version.from;
|
|
2162
|
+
var to = version.to;
|
|
2163
|
+
if (to != null)
|
|
2164
|
+
part += (version.dense ? ' and ' + family + ' ' : ' to ') + to;
|
|
2165
|
+
else
|
|
2166
|
+
appendix = ' or later';
|
|
2167
|
+
}
|
|
2168
|
+
var tag = compatibility.tag;
|
|
2169
|
+
if (tag != null)
|
|
2170
|
+
part += ' ' + tag;
|
|
2171
|
+
return part;
|
|
2172
|
+
}
|
|
2173
|
+
);
|
|
2174
|
+
var lastPart = parts.pop();
|
|
2175
|
+
var engine = (parts.length ? parts.join(', ') + ' and ' + lastPart : lastPart) + appendix;
|
|
2176
|
+
var description = describeEngine(engine);
|
|
2177
|
+
return description;
|
|
2589
2178
|
}
|
|
2590
|
-
|
|
2179
|
+
|
|
2180
|
+
var autoIncludes =
|
|
2181
|
+
_Object_keys$1(featureInfos).filter
|
|
2182
|
+
(
|
|
2183
|
+
function (featureName)
|
|
2184
|
+
{
|
|
2185
|
+
var featureInfo = featureInfos[featureName];
|
|
2186
|
+
var check = featureInfo.check;
|
|
2187
|
+
var returnValue = check && check();
|
|
2188
|
+
return returnValue;
|
|
2189
|
+
}
|
|
2190
|
+
);
|
|
2191
|
+
featureInfos.AUTO =
|
|
2192
|
+
{
|
|
2193
|
+
description: describeEngine('the current environment'),
|
|
2194
|
+
includes: autoIncludes,
|
|
2195
|
+
};
|
|
2196
|
+
Feature = createFeatureClass(featureInfos, formatEngineDescription);
|
|
2197
|
+
ELEMENTARY = Feature.ELEMENTARY;
|
|
2198
|
+
featureInfos = null;
|
|
2199
|
+
assignNoEnum$1(Feature.prototype, { restrict: restrict });
|
|
2200
|
+
var ALL = Feature.ALL;
|
|
2201
|
+
var descriptor = { enumerable: true };
|
|
2202
|
+
for (var featureName in ALL)
|
|
2203
|
+
{
|
|
2204
|
+
var featureObj = ALL[featureName];
|
|
2205
|
+
descriptor.value = featureObj;
|
|
2206
|
+
_Object_defineProperty$1(Feature, featureName, descriptor);
|
|
2207
|
+
}
|
|
2208
|
+
}
|
|
2209
|
+
)();
|
|
2591
2210
|
|
|
2592
2211
|
function callWithFeatures()
|
|
2593
2212
|
{
|
|
@@ -3070,7 +2689,9 @@
|
|
|
3070
2689
|
return replacement;
|
|
3071
2690
|
};
|
|
3072
2691
|
|
|
3073
|
-
|
|
2692
|
+
// End of module ~solution
|
|
2693
|
+
|
|
2694
|
+
assignNoEnum$1
|
|
3074
2695
|
(
|
|
3075
2696
|
AbstractSolution.prototype,
|
|
3076
2697
|
{
|
|
@@ -3082,7 +2703,7 @@
|
|
|
3082
2703
|
},
|
|
3083
2704
|
set appendLength(appendLength)
|
|
3084
2705
|
{
|
|
3085
|
-
_Object_defineProperty(this, 'appendLength', { enumerable: true, value: appendLength });
|
|
2706
|
+
_Object_defineProperty$1(this, 'appendLength', { enumerable: true, value: appendLength });
|
|
3086
2707
|
},
|
|
3087
2708
|
}
|
|
3088
2709
|
);
|
|
@@ -3470,7 +3091,10 @@
|
|
|
3470
3091
|
var NO_IE_SRC = Feature.NO_IE_SRC;
|
|
3471
3092
|
var NO_OLD_SAFARI_ARRAY_ITERATOR = Feature.NO_OLD_SAFARI_ARRAY_ITERATOR;
|
|
3472
3093
|
var NO_V8_SRC = Feature.NO_V8_SRC;
|
|
3094
|
+
var OBJECT_L_LOCATION_CTOR = Feature.OBJECT_L_LOCATION_CTOR;
|
|
3473
3095
|
var OBJECT_UNDEFINED = Feature.OBJECT_UNDEFINED;
|
|
3096
|
+
var OBJECT_W_CTOR = Feature.OBJECT_W_CTOR;
|
|
3097
|
+
var OLD_SAFARI_LOCATION_CTOR = Feature.OLD_SAFARI_LOCATION_CTOR;
|
|
3474
3098
|
var PLAIN_INTL = Feature.PLAIN_INTL;
|
|
3475
3099
|
var REGEXP_STRING_ITERATOR = Feature.REGEXP_STRING_ITERATOR;
|
|
3476
3100
|
var SELF_OBJ = Feature.SELF_OBJ;
|
|
@@ -3538,7 +3162,15 @@
|
|
|
3538
3162
|
{
|
|
3539
3163
|
var expr = '(' + number + ')[TO_LOCALE_STRING](' + locale + ')';
|
|
3540
3164
|
if (index != null)
|
|
3541
|
-
|
|
3165
|
+
{
|
|
3166
|
+
if (index > 4)
|
|
3167
|
+
{
|
|
3168
|
+
var paddingBlock = R_PADDINGS[10 - index];
|
|
3169
|
+
expr = '(' + paddingBlock + ' + ' + expr + ')[10]';
|
|
3170
|
+
}
|
|
3171
|
+
else
|
|
3172
|
+
expr += '[' + index + ']';
|
|
3173
|
+
}
|
|
3542
3174
|
var entry = define._callWithFeatures(expr, LOCALE_NUMERALS, arguments, 3);
|
|
3543
3175
|
return entry;
|
|
3544
3176
|
}
|
|
@@ -3576,7 +3208,7 @@
|
|
|
3576
3208
|
|
|
3577
3209
|
function useLocaleNumeralDigitDefinitions(locale, zeroCharCode)
|
|
3578
3210
|
{
|
|
3579
|
-
var fromCharCode = _String.fromCharCode;
|
|
3211
|
+
var fromCharCode = _String$1.fromCharCode;
|
|
3580
3212
|
for (var digit = 0; digit <= 9; ++digit)
|
|
3581
3213
|
{
|
|
3582
3214
|
var char = fromCharCode(zeroCharCode + digit);
|
|
@@ -3934,6 +3566,12 @@
|
|
|
3934
3566
|
},
|
|
3935
3567
|
LOCATION
|
|
3936
3568
|
),
|
|
3569
|
+
define('(RP_3_WA + LOCATION_CONSTRUCTOR)[11]', OBJECT_L_LOCATION_CTOR),
|
|
3570
|
+
define
|
|
3571
|
+
(
|
|
3572
|
+
'(LOCATION_CONSTRUCTOR + RP_0_S)[SLICE_OR_SUBSTR]("-20")[0]',
|
|
3573
|
+
OLD_SAFARI_LOCATION_CTOR
|
|
3574
|
+
),
|
|
3937
3575
|
define
|
|
3938
3576
|
(
|
|
3939
3577
|
{
|
|
@@ -3943,6 +3581,7 @@
|
|
|
3943
3581
|
AT,
|
|
3944
3582
|
LOCATION
|
|
3945
3583
|
),
|
|
3584
|
+
define('(LOCATION_CONSTRUCTOR + RP_0_S).at("-20")', AT, OLD_SAFARI_LOCATION_CTOR),
|
|
3946
3585
|
define
|
|
3947
3586
|
(
|
|
3948
3587
|
'[][TO_STRING].call(location)[SLICE_OR_SUBSTR]("-10")[1]',
|
|
@@ -4058,6 +3697,7 @@
|
|
|
4058
3697
|
define('(self + RP_4_A)[SLICE_OR_SUBSTR]("-11")[0]', ANY_WINDOW),
|
|
4059
3698
|
define('btoa(undefined)[1]', ATOB),
|
|
4060
3699
|
define('(RP_0_S + self)[11]', DOMWINDOW),
|
|
3700
|
+
define('(RP_3_WA + Function("return constructor")())[11]', OBJECT_W_CTOR),
|
|
4061
3701
|
define('(RP_3_WA + self)[11]', WINDOW),
|
|
4062
3702
|
define('(self + RP_4_A).at("-11")', ANY_WINDOW, AT),
|
|
4063
3703
|
defineCharDefault({ atob: false }),
|
|
@@ -4523,6 +4163,11 @@
|
|
|
4523
4163
|
define({ expr: '"ar-td"', solutionType: SolutionType.COMBINED_STRING }),
|
|
4524
4164
|
define({ expr: '"ar"', solutionType: SolutionType.COMBINED_STRING }, SHORT_LOCALES),
|
|
4525
4165
|
],
|
|
4166
|
+
LOCATION_CONSTRUCTOR:
|
|
4167
|
+
[
|
|
4168
|
+
define('Function("return location")().constructor', OBJECT_L_LOCATION_CTOR),
|
|
4169
|
+
define('Function("return location")().constructor', OLD_SAFARI_LOCATION_CTOR),
|
|
4170
|
+
],
|
|
4526
4171
|
PLAIN_OBJECT:
|
|
4527
4172
|
[
|
|
4528
4173
|
define('Function("return{}")()'),
|
|
@@ -5511,8 +5156,8 @@
|
|
|
5511
5156
|
while ('value' in unit && isUndecoratedUnit(unit))
|
|
5512
5157
|
{
|
|
5513
5158
|
var value = unit.value;
|
|
5514
|
-
if (!_Array_isArray(value))
|
|
5515
|
-
return value == null && inArray ? '' : _String(value);
|
|
5159
|
+
if (!_Array_isArray$1(value))
|
|
5160
|
+
return value == null && inArray ? '' : _String$1(value);
|
|
5516
5161
|
unit = value[0];
|
|
5517
5162
|
if (!unit)
|
|
5518
5163
|
return '';
|
|
@@ -5706,7 +5351,7 @@
|
|
|
5706
5351
|
this._length = -APPEND_LENGTH_OF_EMPTY;
|
|
5707
5352
|
}
|
|
5708
5353
|
|
|
5709
|
-
assignNoEnum
|
|
5354
|
+
assignNoEnum$1
|
|
5710
5355
|
(
|
|
5711
5356
|
ScrewBuffer.prototype,
|
|
5712
5357
|
{
|
|
@@ -5818,7 +5463,7 @@
|
|
|
5818
5463
|
function findBase64AlphabetDefinition(encoder, element)
|
|
5819
5464
|
{
|
|
5820
5465
|
var definition;
|
|
5821
|
-
if (_Array_isArray(element))
|
|
5466
|
+
if (_Array_isArray$1(element))
|
|
5822
5467
|
definition = encoder.findDefinition(element);
|
|
5823
5468
|
else
|
|
5824
5469
|
definition = element;
|
|
@@ -5852,7 +5497,7 @@
|
|
|
5852
5497
|
|
|
5853
5498
|
function replaceIndexer(index)
|
|
5854
5499
|
{
|
|
5855
|
-
var indexStr = _String(index);
|
|
5500
|
+
var indexStr = _String$1(index);
|
|
5856
5501
|
var replacement = '[' + replaceStaticString(indexStr) + ']';
|
|
5857
5502
|
return replacement;
|
|
5858
5503
|
}
|
|
@@ -5986,13 +5631,15 @@
|
|
|
5986
5631
|
var BOND_STRENGTH_WEAK = 1;
|
|
5987
5632
|
var BOND_STRENGTH_STRONG = 2;
|
|
5988
5633
|
|
|
5634
|
+
var featureFromMask = Feature._fromMask;
|
|
5635
|
+
|
|
5989
5636
|
/** @class Encoder */
|
|
5990
5637
|
|
|
5991
5638
|
function Encoder(mask)
|
|
5992
5639
|
{
|
|
5993
5640
|
this.mask = mask;
|
|
5994
|
-
this._charCache = _Object_create(STATIC_CHAR_CACHE);
|
|
5995
|
-
this._constCache = _Object_create(STATIC_CONST_CACHE);
|
|
5641
|
+
this._charCache = _Object_create$1(STATIC_CHAR_CACHE);
|
|
5642
|
+
this._constCache = _Object_create$1(STATIC_CONST_CACHE);
|
|
5996
5643
|
this._definitionCache = createEmpty();
|
|
5997
5644
|
this._optimizers = createEmpty();
|
|
5998
5645
|
this._stack = [];
|
|
@@ -6011,7 +5658,7 @@
|
|
|
6011
5658
|
var feature = featureFromMask(encoder.mask);
|
|
6012
5659
|
var message = 'Circular reference detected: ' + chain.join(' < ') + ' – ' + feature;
|
|
6013
5660
|
var error = new _SyntaxError(message);
|
|
6014
|
-
assignNoEnum(error, { chain: chain, feature: feature });
|
|
5661
|
+
assignNoEnum$1(error, { chain: chain, feature: feature });
|
|
6015
5662
|
throw error;
|
|
6016
5663
|
}
|
|
6017
5664
|
resolver.call(encoder);
|
|
@@ -6205,7 +5852,7 @@
|
|
|
6205
5852
|
APPEND_LENGTH_OF_DIGIT_0 * extraZeroCount +
|
|
6206
5853
|
APPEND_LENGTH_OF_SMALL_E +
|
|
6207
5854
|
APPEND_LENGTH_OF_MINUS +
|
|
6208
|
-
getMultiDigitLength(_String(-exp));
|
|
5855
|
+
getMultiDigitLength(_String$1(-exp));
|
|
6209
5856
|
if (extraLength < rivalExtraLength)
|
|
6210
5857
|
{
|
|
6211
5858
|
var str = mantissa + 'e' + exp;
|
|
@@ -6286,7 +5933,7 @@
|
|
|
6286
5933
|
var screwMode = bondStrength ? SCREW_AS_BONDED_STRING : SCREW_AS_STRING;
|
|
6287
5934
|
output = strReplacer(encoder, value, screwMode, unitIndices, maxLength);
|
|
6288
5935
|
}
|
|
6289
|
-
else if (_Array_isArray(value))
|
|
5936
|
+
else if (_Array_isArray$1(value))
|
|
6290
5937
|
{
|
|
6291
5938
|
if (value.length)
|
|
6292
5939
|
{
|
|
@@ -6321,7 +5968,7 @@
|
|
|
6321
5968
|
output = '(' + output + ')';
|
|
6322
5969
|
}
|
|
6323
5970
|
else
|
|
6324
|
-
output = replaceIdentifier(STATIC_ENCODER, _String(value), bondStrength);
|
|
5971
|
+
output = replaceIdentifier(STATIC_ENCODER, _String$1(value), bondStrength);
|
|
6325
5972
|
if (output.length > maxLength)
|
|
6326
5973
|
return;
|
|
6327
5974
|
}
|
|
@@ -6350,7 +5997,7 @@
|
|
|
6350
5997
|
(function ()
|
|
6351
5998
|
{
|
|
6352
5999
|
var matchSimpleAt;
|
|
6353
|
-
var pattern = _Object_keys(SIMPLE).join('|');
|
|
6000
|
+
var pattern = _Object_keys$1(SIMPLE).join('|');
|
|
6354
6001
|
var regExp = tryCreateRegExp(pattern, 'y');
|
|
6355
6002
|
if (regExp)
|
|
6356
6003
|
{
|
|
@@ -6380,7 +6027,7 @@
|
|
|
6380
6027
|
}
|
|
6381
6028
|
)();
|
|
6382
6029
|
|
|
6383
|
-
assignNoEnum
|
|
6030
|
+
assignNoEnum$1
|
|
6384
6031
|
(
|
|
6385
6032
|
Encoder.prototype,
|
|
6386
6033
|
{
|
|
@@ -6426,7 +6073,7 @@
|
|
|
6426
6073
|
function (length)
|
|
6427
6074
|
{
|
|
6428
6075
|
var paddingBlock = R_PADDINGS[length];
|
|
6429
|
-
if (paddingBlock
|
|
6076
|
+
if (paddingBlock)
|
|
6430
6077
|
return paddingBlock;
|
|
6431
6078
|
throwSyntaxError(this, 'Undefined regular padding block with length ' + length);
|
|
6432
6079
|
},
|
|
@@ -6523,7 +6170,7 @@
|
|
|
6523
6170
|
paddingBlock = padding.block;
|
|
6524
6171
|
shiftedIndex = padding.shiftedIndex;
|
|
6525
6172
|
}
|
|
6526
|
-
var fullExpr = '(' + paddingBlock + '+' + expr + ')[' + shiftedIndex + ']';
|
|
6173
|
+
var fullExpr = '(' + paddingBlock + ' + ' + expr + ')[' + shiftedIndex + ']';
|
|
6527
6174
|
var replacement = this.replaceExpr(fullExpr);
|
|
6528
6175
|
var solution = new SimpleSolution(char, replacement, SolutionType.STRING);
|
|
6529
6176
|
return solution;
|
|
@@ -6675,7 +6322,7 @@
|
|
|
6675
6322
|
if (!buffer.append(solution) || buffer.length > maxLength)
|
|
6676
6323
|
return;
|
|
6677
6324
|
}
|
|
6678
|
-
var replacement = _String(buffer);
|
|
6325
|
+
var replacement = _String$1(buffer);
|
|
6679
6326
|
if (!(replacement.length > maxLength))
|
|
6680
6327
|
return replacement;
|
|
6681
6328
|
},
|
|
@@ -6721,11 +6368,11 @@
|
|
|
6721
6368
|
callResolver
|
|
6722
6369
|
(
|
|
6723
6370
|
this,
|
|
6724
|
-
_JSON_stringify(char),
|
|
6371
|
+
_JSON_stringify$1(char),
|
|
6725
6372
|
function ()
|
|
6726
6373
|
{
|
|
6727
6374
|
var entries = CHARACTERS[char];
|
|
6728
|
-
if (!entries || _Array_isArray(entries))
|
|
6375
|
+
if (!entries || _Array_isArray$1(entries))
|
|
6729
6376
|
{
|
|
6730
6377
|
if (entries)
|
|
6731
6378
|
solution = findOptimalSolution(this, char, entries);
|
|
@@ -6759,7 +6406,7 @@
|
|
|
6759
6406
|
function ()
|
|
6760
6407
|
{
|
|
6761
6408
|
var entries = this.constantDefinitions[constant];
|
|
6762
|
-
if (_Array_isArray(entries))
|
|
6409
|
+
if (_Array_isArray$1(entries))
|
|
6763
6410
|
{
|
|
6764
6411
|
solution =
|
|
6765
6412
|
findOptimalSolution(this, constant, entries, SolutionType.OBJECT);
|
|
@@ -6936,7 +6583,7 @@
|
|
|
6936
6583
|
perfInfoList.inputLength = inputLength;
|
|
6937
6584
|
perfLog.push(perfInfoList);
|
|
6938
6585
|
var inputData = _Object(input);
|
|
6939
|
-
_Object_keys(options).forEach
|
|
6586
|
+
_Object_keys$1(options).forEach
|
|
6940
6587
|
(
|
|
6941
6588
|
function (optName)
|
|
6942
6589
|
{
|
|
@@ -7286,7 +6933,7 @@
|
|
|
7286
6933
|
.count++;
|
|
7287
6934
|
}
|
|
7288
6935
|
);
|
|
7289
|
-
var charList = _Object_keys(charMap);
|
|
6936
|
+
var charList = _Object_keys$1(charMap);
|
|
7290
6937
|
inputData.freqList =
|
|
7291
6938
|
freqList =
|
|
7292
6939
|
charList.map
|
|
@@ -7817,7 +7464,7 @@
|
|
|
7817
7464
|
}
|
|
7818
7465
|
)();
|
|
7819
7466
|
|
|
7820
|
-
assignNoEnum
|
|
7467
|
+
assignNoEnum$1
|
|
7821
7468
|
(
|
|
7822
7469
|
Encoder.prototype,
|
|
7823
7470
|
{
|
|
@@ -7903,7 +7550,7 @@
|
|
|
7903
7550
|
{
|
|
7904
7551
|
var separator = AMENDINGS[index];
|
|
7905
7552
|
var digit = firstDigit + index;
|
|
7906
|
-
var joiner = _String(digit);
|
|
7553
|
+
var joiner = _String$1(digit);
|
|
7907
7554
|
var substitution = { separator: separator, joiner: joiner };
|
|
7908
7555
|
substitutions.push(substitution);
|
|
7909
7556
|
}
|
|
@@ -7970,7 +7617,7 @@
|
|
|
7970
7617
|
perfInfo.perfLog = perfLog;
|
|
7971
7618
|
delete this.perfLog;
|
|
7972
7619
|
if (output == null)
|
|
7973
|
-
throw new _Error('Encoding failed');
|
|
7620
|
+
throw new _Error$1('Encoding failed');
|
|
7974
7621
|
return output;
|
|
7975
7622
|
},
|
|
7976
7623
|
|
|
@@ -8234,7 +7881,7 @@
|
|
|
8234
7881
|
);
|
|
8235
7882
|
|
|
8236
7883
|
var codePointOf =
|
|
8237
|
-
_String.prototype.codePointAt ?
|
|
7884
|
+
_String$1.prototype.codePointAt ?
|
|
8238
7885
|
function (char)
|
|
8239
7886
|
{
|
|
8240
7887
|
var codePoint = char.codePointAt();
|
|
@@ -8885,7 +8532,7 @@
|
|
|
8885
8532
|
return optimizerList;
|
|
8886
8533
|
}
|
|
8887
8534
|
|
|
8888
|
-
assignNoEnum
|
|
8535
|
+
assignNoEnum$1
|
|
8889
8536
|
(
|
|
8890
8537
|
Encoder.prototype,
|
|
8891
8538
|
{
|
|
@@ -8928,7 +8575,7 @@
|
|
|
8928
8575
|
|
|
8929
8576
|
function encode(input, options)
|
|
8930
8577
|
{
|
|
8931
|
-
input = esToString(input);
|
|
8578
|
+
input = esToString$1(input);
|
|
8932
8579
|
options = options || { };
|
|
8933
8580
|
var features = options.features;
|
|
8934
8581
|
var runAsData;
|
|
@@ -8955,7 +8602,7 @@
|
|
|
8955
8602
|
|
|
8956
8603
|
if (input === undefined)
|
|
8957
8604
|
return [wrapWithEval, STRATEGY_NAMES_BOTH];
|
|
8958
|
-
switch (_String(input))
|
|
8605
|
+
switch (_String$1(input))
|
|
8959
8606
|
{
|
|
8960
8607
|
case 'call':
|
|
8961
8608
|
return [wrapWithCall, STRATEGY_NAMES_TEXT];
|
|
@@ -8970,7 +8617,7 @@
|
|
|
8970
8617
|
case 'none':
|
|
8971
8618
|
return [, STRATEGY_NAMES_TEXT];
|
|
8972
8619
|
}
|
|
8973
|
-
throw new _Error('Invalid value for option ' + name);
|
|
8620
|
+
throw new _Error$1('Invalid value for option ' + name);
|
|
8974
8621
|
}
|
|
8975
8622
|
|
|
8976
8623
|
function flushEncoderCache()
|
|
@@ -8985,7 +8632,7 @@
|
|
|
8985
8632
|
|
|
8986
8633
|
function getEncoder(features)
|
|
8987
8634
|
{
|
|
8988
|
-
var mask =
|
|
8635
|
+
var mask = getFeatureMask(features);
|
|
8989
8636
|
var encoder = encoderCache.get(mask);
|
|
8990
8637
|
if (!encoder)
|
|
8991
8638
|
{
|
|
@@ -8997,15 +8644,9 @@
|
|
|
8997
8644
|
return encoder;
|
|
8998
8645
|
}
|
|
8999
8646
|
|
|
9000
|
-
function getValidFeatureMask(features)
|
|
9001
|
-
{
|
|
9002
|
-
var mask = features !== undefined ? validMaskFromArrayOrStringOrFeature(features) : maskNew();
|
|
9003
|
-
return mask;
|
|
9004
|
-
}
|
|
9005
|
-
|
|
9006
8647
|
function isEncoderInCache(features)
|
|
9007
8648
|
{
|
|
9008
|
-
var mask =
|
|
8649
|
+
var mask = getFeatureMask(features);
|
|
9009
8650
|
var returnValue = encoderCache.has(mask);
|
|
9010
8651
|
return returnValue;
|
|
9011
8652
|
}
|
|
@@ -9021,7 +8662,9 @@
|
|
|
9021
8662
|
timeout = _setTimeout(flushEncoderCache);
|
|
9022
8663
|
}
|
|
9023
8664
|
|
|
9024
|
-
var JScrewIt = assignNoEnum({ }, { Feature: Feature, encode: encode });
|
|
8665
|
+
var JScrewIt = assignNoEnum$1({ }, { Feature: Feature, encode: encode });
|
|
8666
|
+
|
|
8667
|
+
var getFeatureMask = Feature._getMask;
|
|
9025
8668
|
|
|
9026
8669
|
var _permanentCaching = false;
|
|
9027
8670
|
var encoderCache;
|
|
@@ -9030,7 +8673,7 @@
|
|
|
9030
8673
|
|
|
9031
8674
|
resetEncoderCache();
|
|
9032
8675
|
|
|
9033
|
-
assignNoEnum
|
|
8676
|
+
assignNoEnum$1
|
|
9034
8677
|
(
|
|
9035
8678
|
encode,
|
|
9036
8679
|
{
|
|
@@ -9067,7 +8710,7 @@
|
|
|
9067
8710
|
if (typeof obj === 'object')
|
|
9068
8711
|
{
|
|
9069
8712
|
var target = { };
|
|
9070
|
-
var names = _Object_keys(obj);
|
|
8713
|
+
var names = _Object_keys$1(obj);
|
|
9071
8714
|
names.forEach
|
|
9072
8715
|
(
|
|
9073
8716
|
function (name)
|
|
@@ -9086,7 +8729,7 @@
|
|
|
9086
8729
|
var outputEntries;
|
|
9087
8730
|
if (inputEntries)
|
|
9088
8731
|
{
|
|
9089
|
-
if (_Array_isArray(inputEntries))
|
|
8732
|
+
if (_Array_isArray$1(inputEntries))
|
|
9090
8733
|
outputEntries = inputEntries.map(clone);
|
|
9091
8734
|
else
|
|
9092
8735
|
outputEntries = [createEntryClone(inputEntries, EMPTY_MASK)];
|
|
@@ -9096,7 +8739,7 @@
|
|
|
9096
8739
|
|
|
9097
8740
|
function createEncoder(features)
|
|
9098
8741
|
{
|
|
9099
|
-
var mask =
|
|
8742
|
+
var mask = getFeatureMask(features);
|
|
9100
8743
|
var encoder = new Encoder(mask);
|
|
9101
8744
|
encoder.perfLog = [];
|
|
9102
8745
|
return encoder;
|
|
@@ -9109,12 +8752,6 @@
|
|
|
9109
8752
|
return entry;
|
|
9110
8753
|
}
|
|
9111
8754
|
|
|
9112
|
-
function createFeatureFromMask(mask)
|
|
9113
|
-
{
|
|
9114
|
-
var featureObj = isMaskCompatible(mask) ? featureFromMask(mask) : null;
|
|
9115
|
-
return featureObj;
|
|
9116
|
-
}
|
|
9117
|
-
|
|
9118
8755
|
function createScrewBuffer(screwMode, groupThreshold, optimizerList)
|
|
9119
8756
|
{
|
|
9120
8757
|
var buffer = new ScrewBuffer(screwMode, groupThreshold, optimizerList);
|
|
@@ -9123,12 +8760,12 @@
|
|
|
9123
8760
|
|
|
9124
8761
|
function defineConstant(encoder, constant, definition)
|
|
9125
8762
|
{
|
|
9126
|
-
constant = _String(constant);
|
|
8763
|
+
constant = _String$1(constant);
|
|
9127
8764
|
if (!/^[$A-Z_a-z][$\w]*$/.test(constant))
|
|
9128
|
-
throw new _SyntaxError('Invalid identifier ' + _JSON_stringify(constant));
|
|
8765
|
+
throw new _SyntaxError('Invalid identifier ' + _JSON_stringify$1(constant));
|
|
9129
8766
|
if (!encoder.hasOwnProperty('constantDefinitions'))
|
|
9130
|
-
encoder.constantDefinitions = _Object_create(CONSTANTS);
|
|
9131
|
-
var entries = [define(esToString(definition))];
|
|
8767
|
+
encoder.constantDefinitions = _Object_create$1(CONSTANTS);
|
|
8768
|
+
var entries = [define(esToString$1(definition))];
|
|
9132
8769
|
encoder.constantDefinitions[constant] = entries;
|
|
9133
8770
|
}
|
|
9134
8771
|
|
|
@@ -9140,7 +8777,7 @@
|
|
|
9140
8777
|
|
|
9141
8778
|
function getCharacters()
|
|
9142
8779
|
{
|
|
9143
|
-
var chars = _Object_keys(CHARACTERS).sort();
|
|
8780
|
+
var chars = _Object_keys$1(CHARACTERS).sort();
|
|
9144
8781
|
return chars;
|
|
9145
8782
|
}
|
|
9146
8783
|
|
|
@@ -9152,7 +8789,7 @@
|
|
|
9152
8789
|
|
|
9153
8790
|
function getComplexNames()
|
|
9154
8791
|
{
|
|
9155
|
-
var names = _Object_keys(COMPLEX).sort();
|
|
8792
|
+
var names = _Object_keys$1(COMPLEX).sort();
|
|
9156
8793
|
return names;
|
|
9157
8794
|
}
|
|
9158
8795
|
|
|
@@ -9164,7 +8801,7 @@
|
|
|
9164
8801
|
|
|
9165
8802
|
function getConstantNames()
|
|
9166
8803
|
{
|
|
9167
|
-
var names = _Object_keys(CONSTANTS).sort();
|
|
8804
|
+
var names = _Object_keys$1(CONSTANTS).sort();
|
|
9168
8805
|
return names;
|
|
9169
8806
|
}
|
|
9170
8807
|
|
|
@@ -9190,6 +8827,9 @@
|
|
|
9190
8827
|
ENTRIES['BASE64_ALPHABET_LO_4:1'] = BASE64_ALPHABET_LO_4[1];
|
|
9191
8828
|
ENTRIES['BASE64_ALPHABET_LO_4:3'] = BASE64_ALPHABET_LO_4[3];
|
|
9192
8829
|
|
|
8830
|
+
var featureFromMask = Feature._fromMask;
|
|
8831
|
+
var getFeatureMask = Feature._getMask;
|
|
8832
|
+
|
|
9193
8833
|
(function ()
|
|
9194
8834
|
{
|
|
9195
8835
|
function exposeEntries(name, entries)
|
|
@@ -9208,7 +8848,7 @@
|
|
|
9208
8848
|
)();
|
|
9209
8849
|
|
|
9210
8850
|
var debug =
|
|
9211
|
-
assignNoEnum
|
|
8851
|
+
assignNoEnum$1
|
|
9212
8852
|
(
|
|
9213
8853
|
{ },
|
|
9214
8854
|
{
|
|
@@ -9220,11 +8860,11 @@
|
|
|
9220
8860
|
calculateSolutionType: calculateSolutionType,
|
|
9221
8861
|
createClusteringPlan: createClusteringPlan,
|
|
9222
8862
|
createEncoder: createEncoder,
|
|
9223
|
-
createFeatureFromMask: createFeatureFromMask,
|
|
9224
8863
|
createFigurator: createFigurator,
|
|
9225
8864
|
createReindexMap: createReindexMap,
|
|
9226
8865
|
createScrewBuffer: createScrewBuffer,
|
|
9227
8866
|
defineConstant: defineConstant,
|
|
8867
|
+
featureFromMask: featureFromMask,
|
|
9228
8868
|
getCharacterEntries: getCharacterEntries,
|
|
9229
8869
|
getCharacters: getCharacters,
|
|
9230
8870
|
getComplexEntry: getComplexEntry,
|
|
@@ -9234,17 +8874,14 @@
|
|
|
9234
8874
|
getEntries: getEntries,
|
|
9235
8875
|
getStrategies: getStrategies,
|
|
9236
8876
|
isEncoderInCache: isEncoderInCache,
|
|
9237
|
-
maskAreEqual: maskAreEqual,
|
|
9238
8877
|
maskIncludes: maskIncludes,
|
|
9239
|
-
maskNew: maskNew,
|
|
9240
|
-
maskNext: maskNext,
|
|
9241
8878
|
maskUnion: maskUnion,
|
|
9242
8879
|
optimizeSolutions: optimizeSolutions,
|
|
9243
8880
|
trimJS: trimJS$1,
|
|
9244
8881
|
}
|
|
9245
8882
|
);
|
|
9246
8883
|
|
|
9247
|
-
assignNoEnum(JScrewIt, { debug: debug });
|
|
8884
|
+
assignNoEnum$1(JScrewIt, { debug: debug });
|
|
9248
8885
|
}
|
|
9249
8886
|
)();
|
|
9250
8887
|
}
|